jDownloadsownloads.com


Author Topic: Checked checkbox  (Read 171 times)

0 Members and 1 Guest are viewing this topic.

Offline HerKle

  • Newbie
  • *
  • Posts: 31
Checked checkbox
« on: 07.05.2019 11:42:03 »
  • Joomla 3.9.5
  • jDownloads 3.2.64
  • Layout template with checkboxes
Hi,
when bringing the checkbox to a mobile friendly size of 30px width+height, the checked version of the box looks distorted.
Where is this checkmark generated?
I would like to override it by an icon.
Thx for showing me the way!

Offline ColinM

  • Moderator
  • *
  • Posts: 3.883
Re: Checked checkbox
« Reply #1 on: 07.05.2019 12:12:14 »
Hi
The size of the 'tick' in a checkbox is controlled by your template - so cannot really assist.
How did you change the size for your mobile device?
Colin

Offline HerKle

  • Newbie
  • *
  • Posts: 31
Re: Checked checkbox
« Reply #2 on: 07.05.2019 13:04:28 »
Hi Colin,
this is made by simple css in the file components/com_jdownloads/assets/css/jdownloads_custom.css:
Code: [Select]
.jd_checkbox_file input[type="checkbox"] {
width: 30px;
height: 30px;
}
Nevertheless the checkmark can't be touched by the css, since it seems to be generated eg. in views/tmpl/category/default.php, line 845 in a javasript attribute:
Code: [Select]
onclick="istChecked(this.checked,'.$formid.');I just wonder where to find the place, where this is produced.

Offline ColinM

  • Moderator
  • *
  • Posts: 3.883
Re: Checked checkbox
« Reply #3 on: 08.05.2019 13:43:49 »
Hi
The CSS you quoted will just set the size of the space in which the checkbox is located
The typical code generated is
Code: [Select]
<input type="checkbox" id="cb1" name="cb_arr[]" value="74" onclick="istChecked(this.checked,3);">where 74 is the Download ID and the 1 in id="cb1" identifies which checkbox is being actioned so that the javascript knows which checkbox has been clicked. 
The tick box and the tick mark are I believe provided by the browser

This is not really a jD problem - if I could find a simple way to make a change then I would have gladly shown you but its complex and at the end of the day the clarity is down to device pixel resolution.
Sorry not able to help much
best wishesColin