Every repository with this icon (
Every repository with this icon (
| Description: | The Clientcide Javascript Libraries edit |
-
DatePicker bugs with %d/%m/%y format (Year 09)
0 comments Created 6 months ago by anutron -
Fupdate incorrectly handles multiple choices inputs
0 comments Created 6 months ago by anutron -
Async StickyWin.Ajax doesn't allow accessing result's dom
0 comments Created 6 months ago by anutron -
Element.get('inputValue') not returning a boolean on checkboxes
0 comments Created 6 months ago by anutron -
MultipleOpenAccordion refactor error w/possible fix
0 comments Created 6 months ago by anutron -
DatePicker - calendars don't pop up when showMoreThanOne=true
0 comments Created 6 months ago by anutron -
http://skitch.com/peterpunk/bp7ty/clientcide-datepicker-issue-with-march-09
Happens with ff3 and not Ie.
sample code:
this.date = new DatePicker(this.input, { 'onHide': this.calendarHide.bind(this), 'format': "%m/%d/%Y" }); this.date = new DatePicker(this.input, { 'onHide': this.calendarHide.bind(this) });Comments
-
I noted something odd going on in the
validateFieldmethod in theFormValidator.Tipsclass.Test case: create a multi text field form. Introduce multiple validations on some of the fields, and have at least 2 that have no "required" validations. My example had the following 5 text field validations:
- required validate-integer
- required minLength:10
- validate-url
- validate-url
- validate-url
I used all the default options on the instantiations of
FormValidator.TipsandFupdate.Prompt, specifying the minimum necessary arguments.I noticed when I setup a
Fupdate.Promptwith this form (after initializing theFormValidator.Tips) that if I failed the first field (enter alpha chars) and the second field (enter too few chars) then corrected the first field I could post the form even though the second field still was invalid. Another behavior was that if I had a correct integer entry in field one, a too short entry in field 2, then clicked around in fields 3 through 5 I could make the error tip go away on field 2, and post.I found the following changes to
FormValidator.Tipsin thevalidateFieldmethod solved this behavior...but it is likely not the most elegant. It also removed a JS error I saw in console from themsgs.getChildren().hide()line in this same method.Here's my sloppy but working changes:
validateField: function(field, force){ var advice = this.getAdvice(field); var anyVis = this.advices.some(function(a){ return a.visible; }); if (anyVis && this.options.serial) { if (advice && advice.visible) { var passed = this.parent(field, force); if (!field.hasClass('validation-failed')) advice.hide(); } return passed; } var msgs = field.retrieve('validationMsgs'); if (msgs) { var msgChildren = msgs.getChildren(); msgChildren.each(function (item,index) { item.hide(); }); } if (field.hasClass('validation-failed') || field.hasClass('warning')) if (advice) advice.show(); var passed = this.parent(field, force); if (this.options.serial && !passed) { var fields = this.element.getElements('.validation-failed, .warning'); if (fields.length) { fields.each(function(f, i) { var adv = this.getAdvice(f); if (adv) adv.hide(); }, this); passed = this.parent(field, force); } } return passed; },Comments
-
Weird DatePicker behavior with some dates
1 comment Created about 1 month ago by lucascorbeauxHi there,
As mentionned here http://github.com/anutron/clientcide/issuesearch?state=open&q=datepicker#issue/15 and here http://github.com/anutron/clientcide/issuesearch?state=open&q=datepicker#issue/26 some dates break the DatePicker.
I'm sure that's an issue, as you can reproduce the bug in the tutorial/demo section here :
http://www.clientcide.com/wiki/cnet-libraries/09-forms/02-datepickerTry to type any november date prior to 2009, like 2007-11-07, and all calendar's cases will be filled by the same number (28 for this example). Works the same way on FF or IE.
As the previous issues were posted several months ago, is there a chance to get an answer, or even an hint to fix the problem ourselves ?
Comments
rrehbeindoi
Tue Nov 10 10:50:11 -0800 2009
| link
The issue is with Daylights savings.
ie: Nov 1, 2009 to Nov 2nd, Daylights savings means Nov 1 + 24 hours of seconds gets you to Nov 1, 23:00. Because it sets the hour, Nov 1 23:00 becomes Nov 1, 00:00, and you end up repeating the date.Ended up adding a bit of code to fillCalendar method:
@@ -13629,13 +13629,15 @@ var DatePicker; }); document.id(this.rows[0].getElements('td')[1]).empty().adopt(monthyr); var atDate = startDate.clone(); + // deal with a daylight savings time issue, see: Nov 1st, 2009 + var incrementTime = Date.units.day() + (Date.units.hour() * 2); this.rows.each(function(row, i){ if (i < 2) return; row.getElements('td').each(function(td){ atDate.set('hours', hours); td.firstChild.data = atDate.getDate(); td.refDate = atDate.getTime(); - atDate.setTime(atDate.getTime() + Date.units.day()); + atDate.setTime(atDate.getTime() + incrementTime); }, this); -
StickyWin (2.2.0) allowMultiple: false has bug in mask
0 comments Created 9 days ago by jhancockI have two dialog: login and register. Each has a link to the
other. I never want them "stacked" or open at the same time: when I
open one, if another is open, I want it closed upon opening another.
In clientcide 2.1.0, I was able to get the desired effect by setting
id: to the same value. This no longer works and I've found 2.2.0 has
the allowMultiple option. So I set it to false. This mostly works
but has a bug in that as each window opens, the mask get applied over
the prior, so as I switch back and forth between login and register
multiple times, my background gets darker and darker. When I finally
close the dialog, I have to click the background once for each time a
dialog was opened to incrementally remove the masks.Comments
-
StickyWin (2.2.0) modalOptions: {hideOnClick: false} not working
1 comment Created 9 days ago by jhancockStickyWin (2.2.0) modalOptions: {hideOnClick: false} not working
the title says it all.
Comments
-
First ist that on the StickyWin destroy() handler, the mask is missing
class StickyWin
destroy: function(){
if (this.windowManager) this.windowManager.remove(this); if (this.win) this.win.destroy(); if (this.options.useIframeShim && this.shim) this.shim.destroy(); if (document.id('modalOverlay')) document.id('modalOverlay').destroy();// add this
if (this.mask) this.mask.destroy(); this.fireEvent('destroy'); }Comments











