webshims-rails 1.15.5 → 1.15.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGES.md +3 -0
- data/lib/webshims-rails/version.rb +2 -2
- data/readme.textile +2 -5
- data/vendor/assets/javascripts/webshims/polyfiller.js +1 -1
- data/vendor/assets/javascripts/webshims/shims/combos/10.js +37 -32
- data/vendor/assets/javascripts/webshims/shims/combos/11.js +36 -31
- data/vendor/assets/javascripts/webshims/shims/combos/17.js +37 -32
- data/vendor/assets/javascripts/webshims/shims/combos/18.js +273 -291
- data/vendor/assets/javascripts/webshims/shims/combos/5.js +38 -33
- data/vendor/assets/javascripts/webshims/shims/combos/6.js +39 -34
- data/vendor/assets/javascripts/webshims/shims/combos/9.js +38 -33
- data/vendor/assets/javascripts/webshims/shims/form-number-date-ui.js +35 -30
- data/vendor/assets/javascripts/webshims/shims/form-validation.js +1 -1
- data/vendor/assets/javascripts/webshims/shims/form-validators.js +2 -2
- data/vendor/assets/javascripts/webshims/shims/i18n/formcfg-fr.js +4 -4
- data/vendor/assets/javascripts/webshims/shims/i18n/formcfg-nl.js +47 -47
- data/vendor/assets/javascripts/webshims/shims/picture.js +272 -289
- metadata +3 -2
@@ -209,7 +209,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
209
209
|
|
210
210
|
|
211
211
|
});
|
212
|
-
|
212
|
+
webshims.register('form-number-date-api', function ($, webshims, window, document, undefined, options) {
|
213
213
|
"use strict";
|
214
214
|
if(!webshims.addInputType){
|
215
215
|
webshims.error("you can not call forms-ext feature after calling forms feature. call both at once instead: $.webshims.polyfill('forms forms-ext')");
|
@@ -825,7 +825,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
825
825
|
}
|
826
826
|
|
827
827
|
});
|
828
|
-
|
828
|
+
(function ($) {
|
829
829
|
"use strict";
|
830
830
|
|
831
831
|
var isNumber = function(string){
|
@@ -1445,7 +1445,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
1445
1445
|
webshims.isReady('range-ui', true);
|
1446
1446
|
}
|
1447
1447
|
})(window.webshims ? webshims.$ : jQuery);
|
1448
|
-
|
1448
|
+
webshims.register('form-number-date-ui', function ($, webshims, window, document, undefined, options) {
|
1449
1449
|
"use strict";
|
1450
1450
|
var curCfg;
|
1451
1451
|
var formcfg = webshims.formcfg;
|
@@ -2010,9 +2010,9 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2010
2010
|
return val;
|
2011
2011
|
},
|
2012
2012
|
month: function(val, opts, noCorrect){
|
2013
|
-
|
2014
|
-
var p = (!opts.splitInput) ? val.trim().split(
|
2015
|
-
|
2013
|
+
var regSplit = opts.monthNames == 'monthNamesShort' ? /[\s-\/\\]+/ : /[\.\s-\/\\]+/;
|
2014
|
+
var p = (!opts.splitInput) ? val.trim().split(regSplit) : val;
|
2015
|
+
|
2016
2016
|
if(p.length == 2 && p[0] && p[1]){
|
2017
2017
|
p[0] = !noCorrect && curCfg.date.monthkeys[p[0]] || p[0];
|
2018
2018
|
p[1] = !noCorrect && curCfg.date.monthkeys[p[1]] || p[1];
|
@@ -2484,34 +2484,35 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2484
2484
|
var isValue = name == 'value';
|
2485
2485
|
spinBtnProto[name] = function(val, force, isLive){
|
2486
2486
|
var selectionEnd;
|
2487
|
-
if(
|
2488
|
-
|
2489
|
-
|
2490
|
-
|
2491
|
-
|
2487
|
+
if(!this._init || force || val || this.options[name] !== val){
|
2488
|
+
if(isValue){
|
2489
|
+
this._beforeValue(val);
|
2490
|
+
} else {
|
2491
|
+
this.elemHelper.prop(name, val);
|
2492
|
+
}
|
2492
2493
|
|
2493
|
-
|
2494
|
-
|
2495
|
-
|
2496
|
-
|
2497
|
-
|
2498
|
-
|
2499
|
-
|
2500
|
-
|
2494
|
+
val = formatVal[this.type](val, this.options);
|
2495
|
+
if(this.options.splitInput){
|
2496
|
+
$.each(this.splits, function(i, elem){
|
2497
|
+
if(!(name in elem) && !isValue && $.nodeName(elem, 'select')){
|
2498
|
+
$('option[value="'+ val[i] +'"]', elem).prop('defaultSelected', true);
|
2499
|
+
} else {
|
2500
|
+
$.prop(elem, name, val[i]);
|
2501
|
+
}
|
2502
|
+
});
|
2503
|
+
} else {
|
2504
|
+
val = this.toFixed(val);
|
2505
|
+
if(isLive && this._getSelectionEnd){
|
2506
|
+
selectionEnd = this._getSelectionEnd(val);
|
2507
|
+
}
|
2508
|
+
this.element.prop(name, val);
|
2509
|
+
if(selectionEnd != null){
|
2510
|
+
this.element.prop('selectionEnd', selectionEnd);
|
2501
2511
|
}
|
2502
|
-
});
|
2503
|
-
} else {
|
2504
|
-
val = this.toFixed(val);
|
2505
|
-
if(isLive && this._getSelectionEnd){
|
2506
|
-
selectionEnd = this._getSelectionEnd(val);
|
2507
|
-
}
|
2508
|
-
this.element.prop(name, val);
|
2509
|
-
if(selectionEnd != null){
|
2510
|
-
this.element.prop('selectionEnd', selectionEnd);
|
2511
2512
|
}
|
2513
|
+
this._propertyChange(name);
|
2514
|
+
this.mirrorValidity();
|
2512
2515
|
}
|
2513
|
-
this._propertyChange(name);
|
2514
|
-
this.mirrorValidity();
|
2515
2516
|
};
|
2516
2517
|
});
|
2517
2518
|
|
@@ -2861,7 +2862,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2861
2862
|
} else {
|
2862
2863
|
popover.hide();
|
2863
2864
|
}
|
2864
|
-
}
|
2865
|
+
};
|
2865
2866
|
|
2866
2867
|
|
2867
2868
|
options.containerElements.push(popover.element[0]);
|
@@ -2967,7 +2968,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2967
2968
|
popover.activeElement.focus();
|
2968
2969
|
}, 4);
|
2969
2970
|
}
|
2970
|
-
if(data.element.is(':focus')
|
2971
|
+
if(data.element.is(':focus') && !$.nodeName(e.target, 'select')){
|
2971
2972
|
popover.openedByFocus = options.buttonOnly ? false : !options.noInput;
|
2972
2973
|
show();
|
2973
2974
|
}
|
@@ -3284,7 +3285,11 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
3284
3285
|
$(data.shim.options.containerElements)
|
3285
3286
|
.on({
|
3286
3287
|
'focusin focus focusout blur': function(e){
|
3287
|
-
e.
|
3288
|
+
if(e.type == 'focus'){
|
3289
|
+
e.stopPropagation();
|
3290
|
+
} else {
|
3291
|
+
e.stopImmediatePropagation();
|
3292
|
+
}
|
3288
3293
|
hasFocus = has[e.type];
|
3289
3294
|
clearTimeout(timer);
|
3290
3295
|
timer = setTimeout(function(){
|
@@ -209,7 +209,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
209
209
|
|
210
210
|
|
211
211
|
});
|
212
|
-
|
212
|
+
webshims.register('form-number-date-api', function ($, webshims, window, document, undefined, options) {
|
213
213
|
"use strict";
|
214
214
|
if(!webshims.addInputType){
|
215
215
|
webshims.error("you can not call forms-ext feature after calling forms feature. call both at once instead: $.webshims.polyfill('forms forms-ext')");
|
@@ -825,7 +825,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
825
825
|
}
|
826
826
|
|
827
827
|
});
|
828
|
-
|
828
|
+
(function ($) {
|
829
829
|
"use strict";
|
830
830
|
|
831
831
|
var isNumber = function(string){
|
@@ -1445,7 +1445,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
1445
1445
|
webshims.isReady('range-ui', true);
|
1446
1446
|
}
|
1447
1447
|
})(window.webshims ? webshims.$ : jQuery);
|
1448
|
-
|
1448
|
+
webshims.register('form-number-date-ui', function ($, webshims, window, document, undefined, options) {
|
1449
1449
|
"use strict";
|
1450
1450
|
var curCfg;
|
1451
1451
|
var formcfg = webshims.formcfg;
|
@@ -2010,9 +2010,9 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2010
2010
|
return val;
|
2011
2011
|
},
|
2012
2012
|
month: function(val, opts, noCorrect){
|
2013
|
-
|
2014
|
-
var p = (!opts.splitInput) ? val.trim().split(
|
2015
|
-
|
2013
|
+
var regSplit = opts.monthNames == 'monthNamesShort' ? /[\s-\/\\]+/ : /[\.\s-\/\\]+/;
|
2014
|
+
var p = (!opts.splitInput) ? val.trim().split(regSplit) : val;
|
2015
|
+
|
2016
2016
|
if(p.length == 2 && p[0] && p[1]){
|
2017
2017
|
p[0] = !noCorrect && curCfg.date.monthkeys[p[0]] || p[0];
|
2018
2018
|
p[1] = !noCorrect && curCfg.date.monthkeys[p[1]] || p[1];
|
@@ -2484,34 +2484,35 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2484
2484
|
var isValue = name == 'value';
|
2485
2485
|
spinBtnProto[name] = function(val, force, isLive){
|
2486
2486
|
var selectionEnd;
|
2487
|
-
if(
|
2488
|
-
|
2489
|
-
|
2490
|
-
|
2491
|
-
|
2487
|
+
if(!this._init || force || val || this.options[name] !== val){
|
2488
|
+
if(isValue){
|
2489
|
+
this._beforeValue(val);
|
2490
|
+
} else {
|
2491
|
+
this.elemHelper.prop(name, val);
|
2492
|
+
}
|
2492
2493
|
|
2493
|
-
|
2494
|
-
|
2495
|
-
|
2496
|
-
|
2497
|
-
|
2498
|
-
|
2499
|
-
|
2500
|
-
|
2494
|
+
val = formatVal[this.type](val, this.options);
|
2495
|
+
if(this.options.splitInput){
|
2496
|
+
$.each(this.splits, function(i, elem){
|
2497
|
+
if(!(name in elem) && !isValue && $.nodeName(elem, 'select')){
|
2498
|
+
$('option[value="'+ val[i] +'"]', elem).prop('defaultSelected', true);
|
2499
|
+
} else {
|
2500
|
+
$.prop(elem, name, val[i]);
|
2501
|
+
}
|
2502
|
+
});
|
2503
|
+
} else {
|
2504
|
+
val = this.toFixed(val);
|
2505
|
+
if(isLive && this._getSelectionEnd){
|
2506
|
+
selectionEnd = this._getSelectionEnd(val);
|
2507
|
+
}
|
2508
|
+
this.element.prop(name, val);
|
2509
|
+
if(selectionEnd != null){
|
2510
|
+
this.element.prop('selectionEnd', selectionEnd);
|
2501
2511
|
}
|
2502
|
-
});
|
2503
|
-
} else {
|
2504
|
-
val = this.toFixed(val);
|
2505
|
-
if(isLive && this._getSelectionEnd){
|
2506
|
-
selectionEnd = this._getSelectionEnd(val);
|
2507
|
-
}
|
2508
|
-
this.element.prop(name, val);
|
2509
|
-
if(selectionEnd != null){
|
2510
|
-
this.element.prop('selectionEnd', selectionEnd);
|
2511
2512
|
}
|
2513
|
+
this._propertyChange(name);
|
2514
|
+
this.mirrorValidity();
|
2512
2515
|
}
|
2513
|
-
this._propertyChange(name);
|
2514
|
-
this.mirrorValidity();
|
2515
2516
|
};
|
2516
2517
|
});
|
2517
2518
|
|
@@ -2861,7 +2862,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2861
2862
|
} else {
|
2862
2863
|
popover.hide();
|
2863
2864
|
}
|
2864
|
-
}
|
2865
|
+
};
|
2865
2866
|
|
2866
2867
|
|
2867
2868
|
options.containerElements.push(popover.element[0]);
|
@@ -2967,7 +2968,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
2967
2968
|
popover.activeElement.focus();
|
2968
2969
|
}, 4);
|
2969
2970
|
}
|
2970
|
-
if(data.element.is(':focus')
|
2971
|
+
if(data.element.is(':focus') && !$.nodeName(e.target, 'select')){
|
2971
2972
|
popover.openedByFocus = options.buttonOnly ? false : !options.noInput;
|
2972
2973
|
show();
|
2973
2974
|
}
|
@@ -3284,7 +3285,11 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
3284
3285
|
$(data.shim.options.containerElements)
|
3285
3286
|
.on({
|
3286
3287
|
'focusin focus focusout blur': function(e){
|
3287
|
-
e.
|
3288
|
+
if(e.type == 'focus'){
|
3289
|
+
e.stopPropagation();
|
3290
|
+
} else {
|
3291
|
+
e.stopImmediatePropagation();
|
3292
|
+
}
|
3288
3293
|
hasFocus = has[e.type];
|
3289
3294
|
clearTimeout(timer);
|
3290
3295
|
timer = setTimeout(function(){
|
@@ -3449,7 +3454,7 @@ webshims.register('form-native-extend', function($, webshims, window, doc, undef
|
|
3449
3454
|
})();
|
3450
3455
|
});
|
3451
3456
|
|
3452
|
-
|
3457
|
+
webshims.register('form-datalist', function ($, webshims, window, document, undefined, options) {
|
3453
3458
|
"use strict";
|
3454
3459
|
var lazyLoad = function(name){
|
3455
3460
|
if(!name || typeof name != 'string'){
|
@@ -1234,7 +1234,7 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
1234
1234
|
|
1235
1235
|
})();
|
1236
1236
|
});
|
1237
|
-
|
1237
|
+
(function ($) {
|
1238
1238
|
"use strict";
|
1239
1239
|
|
1240
1240
|
var isNumber = function(string){
|
@@ -1854,7 +1854,7 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
1854
1854
|
webshims.isReady('range-ui', true);
|
1855
1855
|
}
|
1856
1856
|
})(window.webshims ? webshims.$ : jQuery);
|
1857
|
-
|
1857
|
+
webshims.register('form-number-date-ui', function ($, webshims, window, document, undefined, options) {
|
1858
1858
|
"use strict";
|
1859
1859
|
var curCfg;
|
1860
1860
|
var formcfg = webshims.formcfg;
|
@@ -2419,9 +2419,9 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
2419
2419
|
return val;
|
2420
2420
|
},
|
2421
2421
|
month: function(val, opts, noCorrect){
|
2422
|
-
|
2423
|
-
var p = (!opts.splitInput) ? val.trim().split(
|
2424
|
-
|
2422
|
+
var regSplit = opts.monthNames == 'monthNamesShort' ? /[\s-\/\\]+/ : /[\.\s-\/\\]+/;
|
2423
|
+
var p = (!opts.splitInput) ? val.trim().split(regSplit) : val;
|
2424
|
+
|
2425
2425
|
if(p.length == 2 && p[0] && p[1]){
|
2426
2426
|
p[0] = !noCorrect && curCfg.date.monthkeys[p[0]] || p[0];
|
2427
2427
|
p[1] = !noCorrect && curCfg.date.monthkeys[p[1]] || p[1];
|
@@ -2893,34 +2893,35 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
2893
2893
|
var isValue = name == 'value';
|
2894
2894
|
spinBtnProto[name] = function(val, force, isLive){
|
2895
2895
|
var selectionEnd;
|
2896
|
-
if(
|
2897
|
-
|
2898
|
-
|
2899
|
-
|
2900
|
-
|
2896
|
+
if(!this._init || force || val || this.options[name] !== val){
|
2897
|
+
if(isValue){
|
2898
|
+
this._beforeValue(val);
|
2899
|
+
} else {
|
2900
|
+
this.elemHelper.prop(name, val);
|
2901
|
+
}
|
2901
2902
|
|
2902
|
-
|
2903
|
-
|
2904
|
-
|
2905
|
-
|
2906
|
-
|
2907
|
-
|
2908
|
-
|
2909
|
-
|
2903
|
+
val = formatVal[this.type](val, this.options);
|
2904
|
+
if(this.options.splitInput){
|
2905
|
+
$.each(this.splits, function(i, elem){
|
2906
|
+
if(!(name in elem) && !isValue && $.nodeName(elem, 'select')){
|
2907
|
+
$('option[value="'+ val[i] +'"]', elem).prop('defaultSelected', true);
|
2908
|
+
} else {
|
2909
|
+
$.prop(elem, name, val[i]);
|
2910
|
+
}
|
2911
|
+
});
|
2912
|
+
} else {
|
2913
|
+
val = this.toFixed(val);
|
2914
|
+
if(isLive && this._getSelectionEnd){
|
2915
|
+
selectionEnd = this._getSelectionEnd(val);
|
2916
|
+
}
|
2917
|
+
this.element.prop(name, val);
|
2918
|
+
if(selectionEnd != null){
|
2919
|
+
this.element.prop('selectionEnd', selectionEnd);
|
2910
2920
|
}
|
2911
|
-
});
|
2912
|
-
} else {
|
2913
|
-
val = this.toFixed(val);
|
2914
|
-
if(isLive && this._getSelectionEnd){
|
2915
|
-
selectionEnd = this._getSelectionEnd(val);
|
2916
|
-
}
|
2917
|
-
this.element.prop(name, val);
|
2918
|
-
if(selectionEnd != null){
|
2919
|
-
this.element.prop('selectionEnd', selectionEnd);
|
2920
2921
|
}
|
2922
|
+
this._propertyChange(name);
|
2923
|
+
this.mirrorValidity();
|
2921
2924
|
}
|
2922
|
-
this._propertyChange(name);
|
2923
|
-
this.mirrorValidity();
|
2924
2925
|
};
|
2925
2926
|
});
|
2926
2927
|
|
@@ -3270,7 +3271,7 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
3270
3271
|
} else {
|
3271
3272
|
popover.hide();
|
3272
3273
|
}
|
3273
|
-
}
|
3274
|
+
};
|
3274
3275
|
|
3275
3276
|
|
3276
3277
|
options.containerElements.push(popover.element[0]);
|
@@ -3376,7 +3377,7 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
3376
3377
|
popover.activeElement.focus();
|
3377
3378
|
}, 4);
|
3378
3379
|
}
|
3379
|
-
if(data.element.is(':focus')
|
3380
|
+
if(data.element.is(':focus') && !$.nodeName(e.target, 'select')){
|
3380
3381
|
popover.openedByFocus = options.buttonOnly ? false : !options.noInput;
|
3381
3382
|
show();
|
3382
3383
|
}
|
@@ -3693,7 +3694,11 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
3693
3694
|
$(data.shim.options.containerElements)
|
3694
3695
|
.on({
|
3695
3696
|
'focusin focus focusout blur': function(e){
|
3696
|
-
e.
|
3697
|
+
if(e.type == 'focus'){
|
3698
|
+
e.stopPropagation();
|
3699
|
+
} else {
|
3700
|
+
e.stopImmediatePropagation();
|
3701
|
+
}
|
3697
3702
|
hasFocus = has[e.type];
|
3698
3703
|
clearTimeout(timer);
|
3699
3704
|
timer = setTimeout(function(){
|
@@ -3858,7 +3863,7 @@ webshims.register('dom-extend', function($, webshims, window, document, undefine
|
|
3858
3863
|
})();
|
3859
3864
|
});
|
3860
3865
|
|
3861
|
-
|
3866
|
+
webshims.register('form-datalist', function ($, webshims, window, document, undefined, options) {
|
3862
3867
|
"use strict";
|
3863
3868
|
var lazyLoad = function(name){
|
3864
3869
|
if(!name || typeof name != 'string'){
|
@@ -563,9 +563,9 @@ webshims.register('form-number-date-ui', function($, webshims, window, document,
|
|
563
563
|
return val;
|
564
564
|
},
|
565
565
|
month: function(val, opts, noCorrect){
|
566
|
-
|
567
|
-
var p = (!opts.splitInput) ? val.trim().split(
|
568
|
-
|
566
|
+
var regSplit = opts.monthNames == 'monthNamesShort' ? /[\s-\/\\]+/ : /[\.\s-\/\\]+/;
|
567
|
+
var p = (!opts.splitInput) ? val.trim().split(regSplit) : val;
|
568
|
+
|
569
569
|
if(p.length == 2 && p[0] && p[1]){
|
570
570
|
p[0] = !noCorrect && curCfg.date.monthkeys[p[0]] || p[0];
|
571
571
|
p[1] = !noCorrect && curCfg.date.monthkeys[p[1]] || p[1];
|
@@ -1037,34 +1037,35 @@ webshims.register('form-number-date-ui', function($, webshims, window, document,
|
|
1037
1037
|
var isValue = name == 'value';
|
1038
1038
|
spinBtnProto[name] = function(val, force, isLive){
|
1039
1039
|
var selectionEnd;
|
1040
|
-
if(
|
1041
|
-
|
1042
|
-
|
1043
|
-
|
1044
|
-
|
1040
|
+
if(!this._init || force || val || this.options[name] !== val){
|
1041
|
+
if(isValue){
|
1042
|
+
this._beforeValue(val);
|
1043
|
+
} else {
|
1044
|
+
this.elemHelper.prop(name, val);
|
1045
|
+
}
|
1045
1046
|
|
1046
|
-
|
1047
|
-
|
1048
|
-
|
1049
|
-
|
1050
|
-
|
1051
|
-
|
1052
|
-
|
1053
|
-
|
1047
|
+
val = formatVal[this.type](val, this.options);
|
1048
|
+
if(this.options.splitInput){
|
1049
|
+
$.each(this.splits, function(i, elem){
|
1050
|
+
if(!(name in elem) && !isValue && $.nodeName(elem, 'select')){
|
1051
|
+
$('option[value="'+ val[i] +'"]', elem).prop('defaultSelected', true);
|
1052
|
+
} else {
|
1053
|
+
$.prop(elem, name, val[i]);
|
1054
|
+
}
|
1055
|
+
});
|
1056
|
+
} else {
|
1057
|
+
val = this.toFixed(val);
|
1058
|
+
if(isLive && this._getSelectionEnd){
|
1059
|
+
selectionEnd = this._getSelectionEnd(val);
|
1060
|
+
}
|
1061
|
+
this.element.prop(name, val);
|
1062
|
+
if(selectionEnd != null){
|
1063
|
+
this.element.prop('selectionEnd', selectionEnd);
|
1054
1064
|
}
|
1055
|
-
});
|
1056
|
-
} else {
|
1057
|
-
val = this.toFixed(val);
|
1058
|
-
if(isLive && this._getSelectionEnd){
|
1059
|
-
selectionEnd = this._getSelectionEnd(val);
|
1060
|
-
}
|
1061
|
-
this.element.prop(name, val);
|
1062
|
-
if(selectionEnd != null){
|
1063
|
-
this.element.prop('selectionEnd', selectionEnd);
|
1064
1065
|
}
|
1066
|
+
this._propertyChange(name);
|
1067
|
+
this.mirrorValidity();
|
1065
1068
|
}
|
1066
|
-
this._propertyChange(name);
|
1067
|
-
this.mirrorValidity();
|
1068
1069
|
};
|
1069
1070
|
});
|
1070
1071
|
|
@@ -1414,7 +1415,7 @@ webshims.register('form-number-date-ui', function($, webshims, window, document,
|
|
1414
1415
|
} else {
|
1415
1416
|
popover.hide();
|
1416
1417
|
}
|
1417
|
-
}
|
1418
|
+
};
|
1418
1419
|
|
1419
1420
|
|
1420
1421
|
options.containerElements.push(popover.element[0]);
|
@@ -1520,7 +1521,7 @@ webshims.register('form-number-date-ui', function($, webshims, window, document,
|
|
1520
1521
|
popover.activeElement.focus();
|
1521
1522
|
}, 4);
|
1522
1523
|
}
|
1523
|
-
if(data.element.is(':focus')
|
1524
|
+
if(data.element.is(':focus') && !$.nodeName(e.target, 'select')){
|
1524
1525
|
popover.openedByFocus = options.buttonOnly ? false : !options.noInput;
|
1525
1526
|
show();
|
1526
1527
|
}
|
@@ -1837,7 +1838,11 @@ webshims.register('form-number-date-ui', function($, webshims, window, document,
|
|
1837
1838
|
$(data.shim.options.containerElements)
|
1838
1839
|
.on({
|
1839
1840
|
'focusin focus focusout blur': function(e){
|
1840
|
-
e.
|
1841
|
+
if(e.type == 'focus'){
|
1842
|
+
e.stopPropagation();
|
1843
|
+
} else {
|
1844
|
+
e.stopImmediatePropagation();
|
1845
|
+
}
|
1841
1846
|
hasFocus = has[e.type];
|
1842
1847
|
clearTimeout(timer);
|
1843
1848
|
timer = setTimeout(function(){
|
@@ -643,7 +643,7 @@ webshims.register('form-validation', function($, webshims, window, document, und
|
|
643
643
|
var errorBox = $('.'+errorBoxClass, fieldWrapper);
|
644
644
|
|
645
645
|
if(!errorBox.length){
|
646
|
-
errorBox = $('<'+errorBoxWrapper+' class="'+ errorBoxClass +'" hidden="hidden" style="display: none;"
|
646
|
+
errorBox = $('<'+errorBoxWrapper+' class="'+ errorBoxClass +'" hidden="hidden" style="display: none;" />');
|
647
647
|
fieldWrapper.append(errorBox);
|
648
648
|
}
|
649
649
|
if(!errorBox.prop('id')){
|
@@ -252,8 +252,8 @@ webshims.ready('form-validation', function(){
|
|
252
252
|
(function(){
|
253
253
|
var formCFG = webshims.cfg.forms;
|
254
254
|
var addCustomValidityRule = webshims.addCustomValidityRule;
|
255
|
-
var getId = function(name){
|
256
|
-
return document.getElementById(name) || document.getElementsByName(name);
|
255
|
+
var getId = function(i, name){
|
256
|
+
return document.getElementById(name) || document.getElementsByName(name)[0];
|
257
257
|
};
|
258
258
|
|
259
259
|
addCustomValidityRule('partialPattern', function(elem, val, pattern){
|
@@ -62,12 +62,12 @@ webshims.formcfg.fr = {
|
|
62
62
|
currentText: 'Aujourd\'hui',
|
63
63
|
monthNames: ['Janvier','Février','Mars','Avril','Mai','Juin',
|
64
64
|
'Juillet','Août','Septembre','Octobre','Novembre','Décembre'],
|
65
|
-
monthNamesShort: ['Janv
|
66
|
-
'Juil
|
65
|
+
monthNamesShort: ['Janv','Févr','Mars','Avril','Mai','Juin',
|
66
|
+
'Juil','Août','Sept','Oct','Nov','Déc'],
|
67
67
|
dayNames: ['Dimanche','Lundi','Mardi','Mercredi','Jeudi','Vendredi','Samedi'],
|
68
|
-
dayNamesShort: ['Dim
|
68
|
+
dayNamesShort: ['Dim','Lun','Mar','Mer','Jeu','Ven','Sam'],
|
69
69
|
dayNamesMin: ['D','L','M','M','J','V','S'],
|
70
|
-
weekHeader: 'Sem
|
70
|
+
weekHeader: 'Sem',
|
71
71
|
firstDay: 1,
|
72
72
|
isRTL: false,
|
73
73
|
showMonthAfterYear: false,
|
@@ -28,8 +28,8 @@ webshims.validityMessages.nl = {
|
|
28
28
|
"month": "Maand moet op of voor {%max} zijn."
|
29
29
|
},
|
30
30
|
"stepMismatch": "Ongeldige invoer.",
|
31
|
-
"tooLong": "Voer maximaal {%
|
32
|
-
"tooShort": "Voer minimaal {%
|
31
|
+
"tooLong": "Voer maximaal {%maxlength} karakter(s) in. {%valueLen} is te lang.",
|
32
|
+
"tooShort": "Voer minimaal {%minlength} karakter(s) in. {%valueLen} is te kort.",
|
33
33
|
"patternMismatch": "Voer een waarde in met de gevraagde opmaak: {%title}.",
|
34
34
|
"valueMissing": {
|
35
35
|
"defaultMessage": "Vul dit veld in.",
|
@@ -63,59 +63,59 @@ webshims.formcfg.nl = {
|
|
63
63
|
"nextText": "Volgende",
|
64
64
|
"currentText": "Vandaag",
|
65
65
|
"monthNames": [
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
66
|
+
"januari",
|
67
|
+
"februari",
|
68
|
+
"maart",
|
69
|
+
"april",
|
70
|
+
"mei",
|
71
|
+
"juni",
|
72
|
+
"juli",
|
73
|
+
"augustus",
|
74
|
+
"september",
|
75
|
+
"oktober",
|
76
|
+
"november",
|
77
|
+
"december"
|
78
78
|
],
|
79
79
|
"monthNamesShort": [
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
80
|
+
"jan",
|
81
|
+
"feb",
|
82
|
+
"mrt",
|
83
|
+
"apr",
|
84
|
+
"mei",
|
85
|
+
"jun",
|
86
|
+
"jul",
|
87
|
+
"aug",
|
88
|
+
"sep",
|
89
|
+
"okt",
|
90
|
+
"nov",
|
91
|
+
"dec"
|
92
92
|
],
|
93
93
|
"dayNames": [
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
94
|
+
"zondag",
|
95
|
+
"maandag",
|
96
|
+
"dinsdag",
|
97
|
+
"woensdag",
|
98
|
+
"donderdag",
|
99
|
+
"vrijdag",
|
100
|
+
"zaterdag"
|
101
101
|
],
|
102
102
|
"dayNamesShort": [
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
103
|
+
"zon",
|
104
|
+
"maa",
|
105
|
+
"din",
|
106
|
+
"woe",
|
107
|
+
"don",
|
108
|
+
"vri",
|
109
|
+
"zat"
|
110
110
|
],
|
111
111
|
"dayNamesMin": [
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
112
|
+
"zo",
|
113
|
+
"ma",
|
114
|
+
"di",
|
115
|
+
"wo",
|
116
|
+
"do",
|
117
|
+
"vr",
|
118
|
+
"za"
|
119
119
|
],
|
120
120
|
"weekHeader": "Wk",
|
121
121
|
"firstDay": 1,
|