Over the weekend I made a few changes to my Field & Calculations plug-ins. One big change is I moved the plug-ins to the jQuery SVN repository. This should help people to find the plug-ins and will provide an easy way to stay on top of the changes.
The biggest overall change to the Field Plug-in is the addition of callbacks to the a few of the methods, especially the createCheckboxRange. This allows you to do something like change the background color of the checkbox's row. I also added a default setting (checkboxRangeKeyBinding) which allows you to configure which keyboard event triggers the range selection. This still defaults to the [SHIFT] key, but I can see where you might want to change this binding in certain situations.
The changes I made to the Calculation Plug-in should make it even easier to implement. I altered the sum() and avg() methods so that you can now create bindings to easily update the page. Previously, the methods only performed the calculations, so you had to write your own binding calls. Now if you want to update the element #totalSum whenever the user changes a value in a field beginning with the keyword "sum", you can do: $("input[@name^=sum]").sum("keyup", "#totalSum");
Here's a list of the changes that I've made in the past few days:
Comments for this entry have been disabled.