X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Felements%2Fcheckbox-tristate.html;h=90966a5099260bc0da76ae666cb0c417d8a5e1a9;hp=4c26ed74ec86d79aaa9afe91525abecd956a6291;hb=949a80c148a8bbeeeec54c5a0be5d73b292423a5;hpb=f3e0ac2b009c4edd5692cb587ff709dac2223ebe diff --git a/httemplate/elements/checkbox-tristate.html b/httemplate/elements/checkbox-tristate.html index 4c26ed74e..90966a509 100644 --- a/httemplate/elements/checkbox-tristate.html +++ b/httemplate/elements/checkbox-tristate.html @@ -2,29 +2,54 @@ A tristate checkbox (with three values: true, false, and null). Internally, this creates a checkbox, coupled via javascript to a hidden field that actually contains the value. For now, the only values these -can have are 1, 0, and empty. Clicking the checkbox cycles between them. +can have are 1, -1, and empty. Clicking the checkbox cycles between them. + +For compatibility with regular checkboxes, empty is the false state and +-1 is the indeterminate state. + +Displaying these is a problem. "indeterminate" is a standard HTML5 attribute +but some browsers display it in unhelpful ways (e.g. Firefox slightly grays +the checkbox, approximately #dddddd), and checkboxes ignore nearly all CSS +styling. <%shared> my $init = 0; % if ( !$init ) { % $init = 1; +