Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added progress element + use webkit prefix for transform property

  • Loading branch information...
commit 0d0702bfc7ffc05849eca0efa40c2ec9c2558127 1 parent fba2c6e
@aFarkas authored
Showing with 2,259 additions and 267 deletions.
  1. +9 −9 demos/demos/webforms.html
  2. +10 −18 demos/js-webshim/dev/polyfiller.js
  3. +25 −16 demos/js-webshim/dev/shims/combos/1.js
  4. +27 −18 demos/js-webshim/dev/shims/combos/2.js
  5. +2 −2 demos/js-webshim/dev/shims/combos/3.js
  6. +2 −2 demos/js-webshim/dev/shims/combos/4.js
  7. +3 −3 demos/js-webshim/dev/shims/combos/5.js
  8. +3 −3 demos/js-webshim/dev/shims/combos/6.js
  9. +2 −2 demos/js-webshim/dev/shims/dom-extend.js
  10. +3 −3 demos/js-webshim/dev/shims/form-number-date-api.js
  11. +161 −40 demos/js-webshim/dev/shims/form-shim-extend.js
  12. +25 −16 demos/js-webshim/dev/shims/mediaelement-core.js
  13. +28 −1 demos/js-webshim/dev/shims/styles/scss/shim.scss
  14. +31 −1 demos/js-webshim/dev/shims/styles/shim.css
  15. +1 −1  demos/js-webshim/minified/polyfiller.js
  16. +1 −1  demos/js-webshim/minified/shims/combos/1.js
  17. +1 −1  demos/js-webshim/minified/shims/combos/2.js
  18. +1 −1  demos/js-webshim/minified/shims/combos/3.js
  19. +1 −1  demos/js-webshim/minified/shims/combos/4.js
  20. +1 −1  demos/js-webshim/minified/shims/combos/5.js
  21. +1 −1  demos/js-webshim/minified/shims/combos/6.js
  22. +949 −1 demos/js-webshim/minified/shims/dom-extend.js
  23. +3 −3 demos/js-webshim/minified/shims/form-number-date-api.js
  24. +1 −1  demos/js-webshim/minified/shims/form-shim-extend.js
  25. +627 −1 demos/js-webshim/minified/shims/mediaelement-core.js
  26. +28 −1 demos/js-webshim/minified/shims/styles/scss/shim.scss
  27. +1 −1  demos/js-webshim/minified/shims/styles/shim.css
  28. +1 −0  readme.md
  29. +16 −19 src/polyfiller.js
  30. +25 −16 src/shims/combos/1.js
  31. +27 −18 src/shims/combos/2.js
  32. +2 −2 src/shims/combos/3.js
  33. +2 −2 src/shims/combos/4.js
  34. +3 −3 src/shims/combos/5.js
  35. +3 −3 src/shims/combos/6.js
  36. +2 −2 src/shims/dom-extend.js
  37. +161 −40 src/shims/form-shim-extend.js
  38. +11 −11 src/shims/styles/config.rb
  39. +28 −1 src/shims/styles/scss/shim.scss
  40. +31 −1 src/shims/styles/shim.css
View
18 demos/demos/webforms.html
@@ -129,19 +129,19 @@
<h3>Implemented/fixed elements, attributes, properties, methods, events</h3>
<p><label><input type="checkbox" id="show-forms-ext" checked="checked" /> show/hide <code>forms-ext</code> features</label></p>
<ul>
- <li><strong>elements:</strong> <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#the-output-element">output</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#the-datalist-element">datalist*</a> (currently not for date, number<!--, datetime-local--> and range type)</li>
- <li><strong>types</strong>: <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#e-mail-state-(type=email)">email</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#url-state-(type=url)">url</a><span class="forms-ext-feature"><!--, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#local-date-and-time-state">datetime-local</a> -->, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#time-state-(type=time)">time</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#date-state-(type=date)">date</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/number-state.html#number-state-(type=number)">number</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/number-state.html#range-state-(type=range)">range</a></span></li>
+ <li><strong>elements:</strong> <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#the-output-element">output</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#the-datalist-element">datalist<sup>1</sup></a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#the-progress-element">progress</a></li>
+ <li><strong>types</strong>: <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#e-mail-state-(type=email)">email</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#url-state-(type=url)">url</a><span class="forms-ext-feature"><!--, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#local-date-and-time-state">datetime-local</a> -->, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#time-state-(type=time)">time</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#date-state-(type=date)">date</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/number-state.html#number-state-(type=number)">number</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#month-state-%28type=month%29">month<a/>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/number-state.html#range-state-(type=range)">range</a></span></li>
<li><strong>content attributes and properties (IDL attributes)</strong>: <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#attr-input-placeholder">placeholder</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#attr-input-list">list</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#attr-fe-autofocus">autofocus</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#attr-fs-novalidate">novalidate (noValidate)</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#attr-input-required">required</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#attr-input-pattern">pattern</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#attr-textarea-maxlength">maxlength</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#attr-fs-formnovalidate">formnovalidate (formNoValidate)</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#attr-fs-formaction">formaction (formAction)</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#attr-fs-formenctype">formenctype (formEnctype)</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#attr-fs-formmethod">formmethod (formMethod)</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#attr-fs-formtarget">formtarget (formTarget)</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#association-of-controls-and-forms">form attribute</a><span class="forms-ext-feature">, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#attr-input-step">step</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#attr-input-max">max</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#attr-input-min">min</a></span></li>
- <li><strong>properties/IDLs</strong>: <!-- <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#dom-datalist-options">options</a>,
-
-<a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#dom-input-selectedoption">selectedOption</a>,
--->
- <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-willvalidate">willValidate</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-validity">validity</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-validationmessage">validationMessage</a><span class="forms-ext-feature">, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#dom-input-valueasnumber">valueAsNumber</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#dom-input-valueasdate">valueAsDate</a></span></li>
- <li><strong>methods</strong>: <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-setcustomvalidity">setCustomValidity</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/forms.html#dom-form-checkvalidity">checkValidity</a></li>
+ <li><strong>properties/IDLs</strong>: <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#dom-datalist-options">options<sup>2</sup></a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#dom-input-selectedoption">selectedOption<sup>2</sup></a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#dom-progress-position">position</a>,
+ <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-willvalidate">willValidate</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-validity">validity</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-validationmessage">validationMessage</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#dom-progress-position">position</a><span class="forms-ext-feature">, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#dom-input-valueasnumber">valueAsNumber</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#dom-input-valueasdate">valueAsDate</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/forms.html#dom-lfe-labels">labels</a></span></li>
+ <li><strong>methods</strong>: <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-cva-setcustomvalidity">setCustomValidity</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/forms.html#dom-form-checkvalidity">checkValidity</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#dom-input-stepdown">stepUp/stepDown</a></li>
<li><strong>events</strong>: <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#constraint-validation">invalid</a>, <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#event-input-input">input</a></li>
<li><strong>Selectors</strong>: <a href="http://www.w3.org/TR/css3-ui/#pseudo-invalid">:invalid</a>, <a href="http://www.w3.org/TR/css3-ui/#pseudo-valid">:valid</a>, <a href="http://www.w3.org/TR/css3-ui/#pseudo-required">:required</a>, <a href="http://www.w3.org/TR/selectors4/#user-pseudos">:user-error</a> <!--, <a href="http://www.w3.org/TR/css3-ui/#pseudo-optional">:optional</a><span class="forms-ext-feature"><a href="http://www.w3.org/TR/css3-ui/#pseudo-in-range">, :in-range</a>, <a href="http://www.w3.org/TR/css3-ui/#pseudo-out-of-range">:out-of-range</a></span> -->(Not for CSS, only for JS, for CSS use selectors .user-sccuess, .user-error or [required] please look into the abstractions section)</li>
</ul>
- <p><small>* You need to wrap the datalist options in a select element (datalist > select > option)! / datalist can be also switched to the <code>forms-ext</code> feature using the lightweightDatalist option.</small></p>
+ <ul>
+ <li><small>1. You need to wrap the datalist options in a select element (datalist > select > option)! / datalist can be also switched to the <code>forms-ext</code> feature using the lightweightDatalist option.</small></li>
+ <li><small>2. Only if customDatalist option is set to true.</small></li>
+ </ul>
<h3>Options for the <code>forms</code> feature</h3>
<ul>
View
28 demos/js-webshim/dev/polyfiller.js
@@ -831,19 +831,17 @@
}
});
- if(window.swfobject){
- window.swfmini = window.swfobject;
- }
+
addModule('swfmini', {
test: function(){
- if(window.swfobject){
+ if(window.swfobject && !window.swfmini){
window.swfmini = window.swfobject;
}
return ('swfmini' in window);
},
c: [2, 1]
});
-
+ modules.swfmini.test();
/*
* polyfill-Modules
@@ -898,7 +896,7 @@
loadInit: function(){
var type = this.options.type;
var src;
- if(type && type.indexOf('flash') !== -1 && (!window.swfmini || swfmini.hasFlashPlayerVersion('9.0.0'))){
+ if(type && type.indexOf('flash') !== -1 && (!modules.swfmini.test() || swfmini.hasFlashPlayerVersion('9.0.0'))){
window.FlashCanvasOptions = window.FlashCanvasOptions || {};
flashCanvas = FlashCanvasOptions;
if(type == 'flash'){
@@ -963,7 +961,7 @@
});
if(Modernizr[formvalidation]){
- bugs.bustedValidity = bustedValidity = Modernizr.formattribute === false || !Modernizr.fieldsetdisabled || !('value' in document.createElement('output')) || !($('<input type="date" value="1488-12-11" />')[0].validity || {valid: true}).valid || !('required' in select) || (select.validity || {}).valid;
+ bugs.bustedValidity = bustedValidity = Modernizr.formattribute === false || !Modernizr.fieldsetdisabled || !('value' in document.createElement('progress')) || !('value' in document.createElement('output')) || !($('<input type="date" value="1488-12-11" />')[0].validity || {valid: true}).valid || !('required' in select) || (select.validity || {}).valid;
}
formExtend = Modernizr[formvalidation] && !bustedValidity ? 'form-native-extend' : 'form-shim-extend';
@@ -1059,16 +1057,9 @@
addPolyfill('form-number-date-ui', {
f: 'forms-ext',
test: function(){
- console.log(this.options.replaceUI)
- return modules['form-number-date-api'].test() && !this.options.replaceUI;
+ return !this.options.replaceUI && modules['form-number-date-api'].test();
},
d: ['forms', DOMSUPPORT, 'form-number-date-api', 'range-ui'],
- loadInit: function(){
-// loadList(['jquery-ui']);
-// if(modules['input-widgets'].src){
-// loadList(['input-widgets']);
-// }
- },
options: {
calculateWidth: true
// ,replaceUI: false
@@ -1115,8 +1106,10 @@
return false;
}
var options = this.options;
- var hasToPlay = options.hasToPlay;
- return !( (!window.swfmini || window.swfmini.hasFlashPlayerVersion('9.0.115')) && (options.preferFlash || (hasToPlay != 'any' && !Modernizr.video[hasToPlay] && !Modernizr.audio[hasToPlay])));
+ if(options.preferFlash && !modules.swfmini.test()){
+ options.preferFlash = false;
+ }
+ return !( options.preferFlash && window.swfmini.hasFlashPlayerVersion('9.0.115') );
};
var deps = ['swfmini', DOMSUPPORT];
@@ -1124,7 +1117,6 @@
f: 'mediaelement',
noAutoCallback: true,
options: {
- hasToPlay: 'any',
preferFlash: false,
player: 'jaris',
vars: {},
View
41 demos/js-webshim/dev/shims/combos/1.js
@@ -1244,31 +1244,40 @@ var swfmini = function() {
}
if(hasNative && !options.preferFlash){
+ var noSwitch = {
+ 1: 1,
+ 2: 1
+ };
var switchOptions = function(e){
+ var media;
var parent = e.target.parentNode;
- if(!options.preferFlash && ($(e.target).is('audio, video') || (parent && $('source:last', parent)[0] == e.target)) ){
- webshims.ready('DOM mediaelement', function(){
- if(hasSwf){
+ if(!options.preferFlash &&
+ ($(e.target).is('audio, video') || (parent && $('source:last', parent)[0] == e.target)) &&
+ (media = $(e.target).closest('audio, video')) && !noSwitch[media.prop('error')]
+ ){
+ $(function(){
+ if(hasSwf && !options.preferFlash){
loadSwf();
+ webshims.ready('WINDOWLOAD '+swfType, function(){
+ setTimeout(function(){
+ if(!options.preferFlash && webshims.mediaelement.createSWF && !media.is('.nonnative-api-active')){
+ options.preferFlash = true;
+ document.removeEventListener('error', switchOptions, true);
+ $('audio, video').mediaLoad();
+ webshims.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+e.target.src+" Mediaerror: "+ media.prop('error'));
+ }
+ }, 9);
+ });
+ } else{
+ document.removeEventListener('error', switchOptions, true);
}
- webshims.ready('WINDOWLOAD '+swfType, function(){
- setTimeout(function(){
- if(hasSwf && !options.preferFlash && webshims.mediaelement.createSWF && !$(e.target).closest('audio, video').is('.nonnative-api-active')){
- options.preferFlash = true;
- document.removeEventListener('error', switchOptions, true);
- $('audio, video').mediaLoad();
- webshims.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+e.target.src);
- } else if(!hasSwf){
- document.removeEventListener('error', switchOptions, true);
- }
- }, 20);
- });
});
}
};
document.addEventListener('error', switchOptions, true);
$('audio, video').each(function(){
- if(this.error){
+ var error = $.prop(this, 'error');
+ if(error && !noSwitch[error]){
switchOptions({target: this});
}
});
View
45 demos/js-webshim/dev/shims/combos/2.js
@@ -847,11 +847,11 @@ jQuery.webshims.register('dom-extend', function($, webshims, window, document, u
var ID = new Date().getTime();
return function(elem){
elem = $(elem);
- var id = elem.attr('id');
+ var id = elem.prop('id');
if(!id){
ID++;
id = 'ID-'+ ID;
- elem.attr('id', id);
+ elem.eq(0).prop('id', id);
}
return id;
};
@@ -2827,31 +2827,40 @@ jQuery.webshims.register('form-datalist', function($, webshims, window, document
}
if(hasNative && !options.preferFlash){
+ var noSwitch = {
+ 1: 1,
+ 2: 1
+ };
var switchOptions = function(e){
+ var media;
var parent = e.target.parentNode;
- if(!options.preferFlash && ($(e.target).is('audio, video') || (parent && $('source:last', parent)[0] == e.target)) ){
- webshims.ready('DOM mediaelement', function(){
- if(hasSwf){
+ if(!options.preferFlash &&
+ ($(e.target).is('audio, video') || (parent && $('source:last', parent)[0] == e.target)) &&
+ (media = $(e.target).closest('audio, video')) && !noSwitch[media.prop('error')]
+ ){
+ $(function(){
+ if(hasSwf && !options.preferFlash){
loadSwf();
+ webshims.ready('WINDOWLOAD '+swfType, function(){
+ setTimeout(function(){
+ if(!options.preferFlash && webshims.mediaelement.createSWF && !media.is('.nonnative-api-active')){
+ options.preferFlash = true;
+ document.removeEventListener('error', switchOptions, true);
+ $('audio, video').mediaLoad();
+ webshims.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+e.target.src+" Mediaerror: "+ media.prop('error'));
+ }
+ }, 9);
+ });
+ } else{
+ document.removeEventListener('error', switchOptions, true);
}
- webshims.ready('WINDOWLOAD '+swfType, function(){
- setTimeout(function(){
- if(hasSwf && !options.preferFlash && webshims.mediaelement.createSWF && !$(e.target).closest('audio, video').is('.nonnative-api-active')){
- options.preferFlash = true;
- document.removeEventListener('error', switchOptions, true);
- $('audio, video').mediaLoad();
- webshims.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+e.target.src);
- } else if(!hasSwf){
- document.removeEventListener('error', switchOptions, true);
- }
- }, 20);
- });
});
}
};
document.addEventListener('error', switchOptions, true);
$('audio, video').each(function(){
- if(this.error){
+ var error = $.prop(this, 'error');
+ if(error && !noSwitch[error]){
switchOptions({target: this});
}
});
View
4 demos/js-webshim/dev/shims/combos/3.js
@@ -341,11 +341,11 @@ jQuery.webshims.register('dom-extend', function($, webshims, window, document, u
var ID = new Date().getTime();
return function(elem){
elem = $(elem);
- var id = elem.attr('id');
+ var id = elem.prop('id');
if(!id){
ID++;
id = 'ID-'+ ID;
- elem.attr('id', id);
+ elem.eq(0).prop('id', id);
}
return id;
};
View
4 demos/js-webshim/dev/shims/combos/4.js
@@ -341,11 +341,11 @@ jQuery.webshims.register('dom-extend', function($, webshims, window, document, u
var ID = new Date().getTime();
return function(elem){
elem = $(elem);
- var id = elem.attr('id');
+ var id = elem.prop('id');
if(!id){
ID++;
id = 'ID-'+ ID;
- elem.attr('id', id);
+ elem.eq(0).prop('id', id);
}
return id;
};
View
6 demos/js-webshim/dev/shims/combos/5.js
@@ -743,13 +743,13 @@ jQuery.webshims.register('form-number-date-api', function($, webshims, window, d
webshims.defineNodeNamesProperty('button, input, keygen, meter, output, progress, select, textarea', 'labels', {
prop: {
get: function(){
- var parent;
+ if(this.type == 'hidden'){return null;}
var id = this.id;
var labels = $(this)
.closest('label')
.filter(function(){
- var hFor = this.htmlFor;
- return (!hFor || hFor == id);
+ var hFor = (this.attributes['for'] || {});
+ return (!hFor.specified || hFor.value == id);
})
;
View
6 demos/js-webshim/dev/shims/combos/6.js
@@ -743,13 +743,13 @@ jQuery.webshims.register('form-number-date-api', function($, webshims, window, d
webshims.defineNodeNamesProperty('button, input, keygen, meter, output, progress, select, textarea', 'labels', {
prop: {
get: function(){
- var parent;
+ if(this.type == 'hidden'){return null;}
var id = this.id;
var labels = $(this)
.closest('label')
.filter(function(){
- var hFor = this.htmlFor;
- return (!hFor || hFor == id);
+ var hFor = (this.attributes['for'] || {});
+ return (!hFor.specified || hFor.value == id);
})
;
View
4 demos/js-webshim/dev/shims/dom-extend.js
@@ -341,11 +341,11 @@ jQuery.webshims.register('dom-extend', function($, webshims, window, document, u
var ID = new Date().getTime();
return function(elem){
elem = $(elem);
- var id = elem.attr('id');
+ var id = elem.prop('id');
if(!id){
ID++;
id = 'ID-'+ ID;
- elem.attr('id', id);
+ elem.eq(0).prop('id', id);
}
return id;
};
View
6 demos/js-webshim/dev/shims/form-number-date-api.js
@@ -487,13 +487,13 @@ jQuery.webshims.register('form-number-date-api', function($, webshims, window, d
webshims.defineNodeNamesProperty('button, input, keygen, meter, output, progress, select, textarea', 'labels', {
prop: {
get: function(){
- var parent;
+ if(this.type == 'hidden'){return null;}
var id = this.id;
var labels = $(this)
.closest('label')
.filter(function(){
- var hFor = this.htmlFor;
- return (!hFor || hFor == id);
+ var hFor = (this.attributes['for'] || {});
+ return (!hFor.specified || hFor.value == id);
})
;
View
201 demos/js-webshim/dev/shims/form-shim-extend.js
@@ -881,9 +881,7 @@ if(!Modernizr.formattribute || !Modernizr.fieldsetdisabled){
$.removeData(form, 'webshimsAddedElements');
}
};
- var rCRLF = /\r?\n/g,
- rinput = /^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,
- rselectTextarea = /^(?:select|textarea)/i;
+
if(!Modernizr.formattribute){
webshims.defineNodeNamesProperty(['input', 'textarea', 'select', 'button', 'fieldset'], 'form', {
@@ -991,32 +989,161 @@ if(!Modernizr.formattribute || !Modernizr.fieldsetdisabled){
});
}
- $.fn.serializeArray = function() {
- return this.map(function(){
- var elements = $.prop(this, 'elements');
- return elements ? $.makeArray( elements ) : this;
- })
- .filter(function(){
- return this.name && !this.disabled &&
- ( this.checked || rselectTextarea.test( this.nodeName ) ||
- rinput.test( this.type ) );
- })
- .map(function( i, elem ){
- var val = $( this ).val();
-
- return val == null ?
- null :
- $.isArray( val ) ?
- $.map( val, function( val, i ){
- return { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
- }) :
- { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
- }).get();
- };
+ if(!$.fn.finish && parseFloat($.fn.jquery, 10) < 1.9){
+ var rCRLF = /\r?\n/g,
+ rinput = /^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,
+ rselectTextarea = /^(?:select|textarea)/i;
+ $.fn.serializeArray = function() {
+ return this.map(function(){
+ var elements = $.prop(this, 'elements');
+ return elements ? $.makeArray( elements ) : this;
+ })
+ .filter(function(){
+ return this.name && !this.disabled &&
+ ( this.checked || rselectTextarea.test( this.nodeName ) ||
+ rinput.test( this.type ) );
+ })
+ .map(function( i, elem ){
+ var val = $( this ).val();
+
+ return val == null ?
+ null :
+ $.isArray( val ) ?
+ $.map( val, function( val, i ){
+ return { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
+ }) :
+ { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
+ }).get();
+ };
+ }
})();
}
+ if($('<input />').prop('labels') == null){
+ webshims.defineNodeNamesProperty('button, input, keygen, meter, output, progress, select, textarea', 'labels', {
+ prop: {
+ get: function(){
+ if(this.type == 'hidden'){return null;}
+ var id = this.id;
+ var labels = $(this)
+ .closest('label')
+ .filter(function(){
+ var hFor = (this.attributes['for'] || {});
+ return (!hFor.specified || hFor.value == id);
+ })
+ ;
+
+ if(id) {
+ labels = labels.add('label[for="'+ id +'"]');
+ }
+ return labels.get();
+ },
+ writeable: false
+ }
+ });
+ }
+
+ if(!('value' in document.createElement('progress'))){
+ (function(){
+
+ var nan = parseInt('NaN', 10);
+
+ var updateProgress = function(progress){
+ var position;
+
+
+ position = $.prop(progress, 'position');
+
+ $.attr(progress, 'data-position', position);
+ $('> span', progress).css({width: (position < 0 ? 100 : position * 100) +'%'});
+ };
+ var desc = {
+ position: {
+ prop: {
+ get: function(){
+ var max;
+ var val = $.attr(this, 'value');
+ var ret = -1;
+ val = val ? (val * 1) : nan;
+ if(!isNaN(val)){
+ max = $.prop(this, 'max');
+ ret = Math.max(Math.min(val / max, 1), 0);
+ if(updateProgress.isInChange){
+ $.attr(this, 'aria-valuenow', ret * 100);
+ if(updateProgress.isInChange == 'max'){
+ $.attr(this, 'aria-valuemax', max);
+ }
+ } else {
+ $(this).removeAttr('aria-valuenow');
+ }
+ }
+ return ret;
+ },
+ writeable: false
+ }
+ }
+ };
+
+ $.each({value: 0, max: 1}, function(name, defValue){
+ desc[name] = {
+ attr: {
+ set: function(value){
+ var ret = desc[name].attr._supset.aplly(this, arguments);
+ updateProgress.isInChange = name;
+ updateProgress(this);
+ updateProgress.isInChange = false;
+ return ret;
+ }
+ },
+ prop: {
+ get: function(){
+ var max;
+ var ret = (desc[name].attr.get.apply(this) * 1);
+ if(ret < 0 || isNaN(ret)){
+ ret = defValue;
+ } else if(name == 'value'){
+ ret = Math.min(ret, $.prop(this, 'max'));
+ } else if(ret === 0){
+ ret = defValue;
+ }
+ return ret;
+ },
+ set: function(value){
+ return desc[name].attr._supset.call(this, value * 1);
+ }
+ }
+ };
+ });
+
+ webshims.createElement(
+ 'progress',
+ function(){
+ var labels = $(this)
+ .attr({role: 'progressbar', 'aria-valuemin': '0'})
+ .html('<span class="progress-value" />')
+ .jProp('labels')
+ .map(function(){
+ return webshims.getID(this);
+ })
+ .get()
+ ;
+ if(labels.length){
+ $.attr(this, 'aria-labelledby', labels.join(' '));
+ } else {
+ webshims.info("you should use label elements for your prgogress elements");
+ }
+
+ updateProgress.isInChange = 'max';
+ updateProgress(this);
+ updateProgress.isInChange = false;
+ },
+ desc
+ );
+
+ })();
+ }
+
try {
document.querySelector(':checked');
} catch(er){
@@ -1213,21 +1340,13 @@ try {
hidePlaceholder(elem, data, value);
}
},
+ hasLabel = function(elem){
+ elem = $(elem);
+ return !!(elem.prop('title') || elem.attr('aria-labelledby') || elem.attr('aria-label') || elem.jProp('labels').length);
+ },
createPlaceholder = function(elem){
elem = $(elem);
- var id = elem.prop('id'),
- hasLabel = !!(elem.prop('title') || elem.attr('aria-labelledby'))
- ;
- if(!hasLabel && id){
- hasLabel = !!( $('label[for="'+ id +'"]', elem[0].form)[0] );
- }
- if(!hasLabel){
- if(!id){
- id = $.webshims.getID(elem);
- }
- hasLabel = !!($('label #'+ id)[0]);
- }
- return $( hasLabel ? '<span class="placeholder-text"></span>' : '<label for="'+ id +'" class="placeholder-text"></label>');
+ return $( hasLabel(elem) ? '<span class="placeholder-text"></span>' : '<label for="'+ elem.prop('id') +'" class="placeholder-text"></label>');
},
pHolder = (function(){
var delReg = /\n|\r|\f|\t/g,
@@ -1442,7 +1561,7 @@ try {
if(elem.getAttribute('aria-live')){return;}
elem = $(elem);
var value = (elem.text() || '').trim();
- var id = elem.attr('id');
+ var id = elem.prop('id');
var htmlFor = elem.attr('for');
var shim = $('<input class="output-shim" type="text" disabled name="'+ (elem.attr('name') || '')+'" value="'+value+'" style="display: none !important;" />').insertAfter(elem);
var form = shim[0].form || doc;
@@ -1459,7 +1578,9 @@ try {
elem.attr({'aria-live': 'polite'});
if(id){
shim.attr('id', id);
- elem.attr('aria-labelledby', webshims.getID($('label[for="'+id+'"]', form)));
+ elem.attr('aria-labelledby', elem.jProp('labels').map(function(){
+ return webshims.getID(this);
+ }).join(' '));
}
if(htmlFor){
id = webshims.getID(elem);
View
41 demos/js-webshim/dev/shims/mediaelement-core.js
@@ -38,31 +38,40 @@
}
if(hasNative && !options.preferFlash){
+ var noSwitch = {
+ 1: 1,
+ 2: 1
+ };
var switchOptions = function(e){
+ var media;
var parent = e.target.parentNode;
- if(!options.preferFlash && ($(e.target).is('audio, video') || (parent && $('source:last', parent)[0] == e.target)) ){
- webshims.ready('DOM mediaelement', function(){
- if(hasSwf){
+ if(!options.preferFlash &&
+ ($(e.target).is('audio, video') || (parent && $('source:last', parent)[0] == e.target)) &&
+ (media = $(e.target).closest('audio, video')) && !noSwitch[media.prop('error')]
+ ){
+ $(function(){
+ if(hasSwf && !options.preferFlash){
loadSwf();
+ webshims.ready('WINDOWLOAD '+swfType, function(){
+ setTimeout(function(){
+ if(!options.preferFlash && webshims.mediaelement.createSWF && !media.is('.nonnative-api-active')){
+ options.preferFlash = true;
+ document.removeEventListener('error', switchOptions, true);
+ $('audio, video').mediaLoad();
+ webshims.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+e.target.src+" Mediaerror: "+ media.prop('error'));
+ }
+ }, 9);
+ });
+ } else{
+ document.removeEventListener('error', switchOptions, true);
}
- webshims.ready('WINDOWLOAD '+swfType, function(){
- setTimeout(function(){
- if(hasSwf && !options.preferFlash && webshims.mediaelement.createSWF && !$(e.target).closest('audio, video').is('.nonnative-api-active')){
- options.preferFlash = true;
- document.removeEventListener('error', switchOptions, true);
- $('audio, video').mediaLoad();
- webshims.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+e.target.src);
- } else if(!hasSwf){
- document.removeEventListener('error', switchOptions, true);
- }
- }, 20);
- });
});
}
};
document.addEventListener('error', switchOptions, true);
$('audio, video').each(function(){
- if(this.error){
+ var error = $.prop(this, 'error');
+ if(error && !noSwitch[error]){
switchOptions({target: this});
}
});
View
29 demos/js-webshim/dev/shims/styles/scss/shim.scss
@@ -105,7 +105,8 @@ mark {
.input-datetime-local,
.input-buttons,
.input-buttons *,
-.details-open-indicator {
+.details-open-indicator,
+progress span.progress-value {
margin: 0;
padding: 0;
border: none;
@@ -574,12 +575,14 @@ img.ui-datepicker-trigger {
opacity: 0;
padding: 11px 0 4px;
transform: translate(0, -100%);
+ -webkit-transform: translate(0, -100%);
transition: all 400ms ease-in-out;
}
.ws-popover.ws-po-visible .ws-po-outerbox {
opacity: 1;
+ -webkit-transform: translate(0, 0);
transform: translate(0, 0);
}
@@ -697,6 +700,30 @@ datalist {
z-index: 1000000000;
}
+progress {
+ position: relative;
+ display: inline-block;
+ width: 160px;
+ height: 16px;
+}
+progress[data-position] {
+ vertical-align: -0.2em;
+ border: 1px solid #ccc;
+ background: #e6e6e6;
+}
+progress * {
+ display: none !important;
+}
+progress span.progress-value {
+ position: absolute;
+ display: block !important;
+ top: 0;
+ left: 0;
+ bottom: 0;
+ height: 100%;
+ background: #0063a6;
+}
+
/* localStorage */
#swflocalstorageshim-wrapper {
View
32 demos/js-webshim/dev/shims/styles/shim.css
@@ -121,7 +121,8 @@ mark {
.input-datetime-local,
.input-buttons,
.input-buttons *,
-.details-open-indicator {
+.details-open-indicator,
+progress span.progress-value {
margin: 0;
padding: 0;
border: none;
@@ -656,11 +657,13 @@ img.ui-datepicker-trigger {
opacity: 0;
padding: 11px 0 4px;
transform: translate(0, -100%);
+ -webkit-transform: translate(0, -100%);
transition: all 400ms ease-in-out;
}
.ws-popover.ws-po-visible .ws-po-outerbox {
opacity: 1;
+ -webkit-transform: translate(0, 0);
transform: translate(0, 0);
}
@@ -789,6 +792,33 @@ datalist {
z-index: 1000000000;
}
+progress {
+ position: relative;
+ display: inline-block;
+ width: 160px;
+ height: 16px;
+}
+
+progress[data-position] {
+ vertical-align: -0.2em;
+ border: 1px solid #cccccc;
+ background: #e6e6e6;
+}
+
+progress * {
+ display: none !important;
+}
+
+progress span.progress-value {
+ position: absolute;
+ display: block !important;
+ top: 0;
+ left: 0;
+ bottom: 0;
+ height: 100%;
+ background: #0063a6;
+}
+
/* localStorage */
#swflocalstorageshim-wrapper {
position: absolute;
View
2  demos/js-webshim/minified/polyfiller.js
@@ -1 +1 @@
-(function(e){window.jQuery&&(e(jQuery),e=jQuery.noop),typeof define=="function"&&define.amd&&define.amd.jQuery&&define("polyfiller",["jquery"],e)})(function(e){"use strict";var t="dom-support",n=e(document.scripts||"script"),r=e.event.special,i=e([]),s=window.Modernizr,o=window.asyncWebshims,u=s.addTest,a=window.Object,f=window.html5||{},l=function(t,n){var r=!0;e.each(t.split(" "),function(e,t){t in s||(c.error("webshims needs Modernizr."+t+" to implement feature."),r=!1)}),r&&n&&n()};s.advancedObjectProperties=s.objectAccessor=s.ES5="create"in a&&"seal"in a,e.event.customEvent||(e.event.customEvent={});var c={version:"1.10.0dev",cfg:{useImportantStyles:!0,waitReady:!0,extendNative:!0,loadStyles:!0,disableShivMethods:!0,wspopover:{appendTo:"body",hideOnBlur:!0},basePath:function(){var t=n.filter('[src*="polyfiller.js"]'),r;return t=t[0]||t.end()[t.end().length-1],r=(e.support.hrefNormalized?t.src:t.getAttribute("src",4)).split("?")[0],r=r.slice(0,r.lastIndexOf("/")+1)+"shims/",r}()},bugs:{},modules:{},features:{},featureList:[],setOptions:function(t,n){typeof t=="string"&&n!==undefined?v[t]=e.isPlainObject(n)?e.extend(!0,v[t]||{},n):n:typeof t=="object"&&e.extend(!0,v,t)},addPolyfill:function(t,n){n=n||{};var r=n.f||t;m[r]||(m[r]=[],m[r].delayReady=0,c.featureList.push(r),v[r]={}),m[r].push(t),n.options=e.extend(v[r],n.options),x(t,n),n.methodNames&&e.each(n.methodNames,function(e,t){c.addMethodName(t)})},polyfill:function(){var t=function(n){var r=[],i=n,s;v.disableShivMethods&&(f.shivMethods=!1);var o=function(){e("html").removeClass("loading-polyfills long-loading-polyfills"),e(window).unbind(".lP"),clearTimeout(s)};e(window).on("load.lP error.lP",o),r.push("loading-polyfills"),s=setTimeout(function(){e("html").addClass("long-loading-polyfills")},400),v.waitReady&&e.isReady&&c.warn("Call webshims.polyfill before DOM-Ready or set waitReady to false."),y(n,o),v.useImportantStyles&&r.push("polyfill-important"),r[0]&&e("html").addClass(r.join(" ")),v.loadStyles&&E.loadCSS("styles/shim.css"),t=e.noop},n;return function(r){var i=[];r=r||c.featureList,typeof r=="string"&&(r=r.split(" ")),n||(n=e.inArray("forms",r)!==-1,!n&&e.inArray("forms-ext",r)!==-1&&(r.push("forms"),n=!0)),v.waitReady&&(e.readyWait++,y(r,function(){e.ready(!0)})),e.each(r,function(e,t){if(!m[t]){c.error("could not find webshims-feature (aborted): "+t),g(t,!0);return}t!==m[t][0]&&y(m[t],function(){g(t,!0)}),i=i.concat(m[t])}),t(r),S(i)}}(),reTest:function(){var t,n,i=function(i,s){var o=w[s],u=s+"Ready",a;o&&!o.loaded&&(o.test&&e.isFunction(o.test)?!o.test([]):!o.test)&&(r[u]&&delete r[u],a=m[o.f],a&&!n&&(a.delayReady++,y(s,function(){a.delayReady--,g(o.f,a.callReady)})),t.push(s))};return function(r,s){n=s,typeof r=="string"&&(r=r.split(" ")),t=[],e.each(r,i),S(t)}}(),isReady:function(t,n){if(m[t]&&m[t].delayReady>0)return n&&(m[t].callReady=!0),!1;t+="Ready";if(n){if(r[t]&&r[t].add)return!0;r[t]=e.extend(r[t]||{},{add:function(e){e.handler.call(this,t)}}),e(document).triggerHandler(t)}return!!r[t]&&!!r[t].add||!1},ready:function(t,n){var r=arguments[2],i=t;typeof t=="string"&&(t=t.split(" ")),r||(t=e.map(e.grep(t,function(e){return!g(e)}),function(e){return e+"Ready"}));if(!t.length){n(e,c,window,document);return}var s=t.shift(),o=function(){y(t,n,!0)};e(document).one(s,o)},capturingEvents:function(t,n){if(!document.addEventListener)return;typeof t=="string"&&(t=[t]),e.each(t,function(t,i){var s=function(t){return t=e.event.fix(t),n&&c.capturingEventPrevented&&c.capturingEventPrevented(t),e.event.dispatch.call(this,t)};r[i]=r[i]||{};if(r[i].setup||r[i].teardown)return;e.extend(r[i],{setup:function(){this.addEventListener(i,s,!0)},teardown:function(){this.removeEventListener(i,s,!0)}})})},register:function(t,n){var r=w[t];if(!r){c.error("can't find module: "+t);return}if(r.noAutoCallback){var i=function(){n(e,c,window,document,undefined,r.options),g(t,!0)};r.d&&r.d.length?y(r.d,i):i()}},c:{},loader:{addModule:function(t,n){w[t]=n,n.name=n.name||t,n.c||(n.c=[]),e.each(n.c,function(e,n){c.c[n]||(c.c[n]=[]),c.c[n].push(t)})},loadList:function(){var t=[],n=function(n,r){typeof r=="string"&&(r=[r]),e.merge(t,r),E.loadScript(n,!1,r)},r=function(n,r){if(g(n)||e.inArray(n,t)!=-1)return!0;var i=w[n],s=v[i.f||n]||{},o;return i?(o=i.test&&e.isFunction(i.test)?i.test(r):i.test,o?(g(n,!0),!0):!1):!0},i=function(t,n){if(t.d&&t.d.length){var i=function(t,i){!r(i,n)&&e.inArray(i,n)==-1&&n.push(i)};e.each(t.d,function(t,n){w[n]?i(t,n):m[n]&&(e.each(m[n],i),y(m[n],function(){g(n,!0)}))}),t.noAutoCallback||(t.noAutoCallback=!0)}};return function(s,o){var u,a=[],f,l,h,p=function(r,i){h=i,e.each(c.c[i],function(n,r){if(e.inArray(r,a)==-1||e.inArray(r,t)!=-1)return h=!1,!1});if(h)return n("combos/"+h,c.c[h]),!1};for(f=0;f<s.length;f++){u=w[s[f]];if(!u||r(u.name,s)){u||c.warn("could not find: "+s[f]);continue}u.css&&E.loadCSS(u.css),u.loadInit&&u.loadInit(),u.loaded=!0,i(u,s),a.push(u.name)}for(f=0,l=a.length;f<l;f++)h=!1,u=a[f],e.inArray(u,t)==-1&&(c.debug!="noCombo"&&e.each(w[u].c,p),h||n(w[u].src||u,u))}}(),makePath:function(e){return e.indexOf("//")!=-1||e.indexOf("/")===0?e:(e.indexOf(".")==-1&&(e+=".js"),v.addCacheBuster&&(e+=v.addCacheBuster),v.basePath+e)},loadCSS:function(){var t,n=[];return function(r){r=this.makePath(r);if(e.inArray(r,n)!=-1)return;t=t||e("link, style")[0]||e("script")[0],n.push(r),e('<link rel="stylesheet" />').insertBefore(t).attr({href:r})}}(),loadScript:function(){var t=[],n;return function(n,r,i){n=E.makePath(n);if(e.inArray(n,t)!=-1)return;var s=function(){s=null,r&&r(),i&&(typeof i=="string"&&(i=i.split(" ")),e.each(i,function(e,t){if(!w[t])return;w[t].afterLoad&&w[t].afterLoad(),g(w[t].noAutoCallback?t+"FileLoaded":t,!0)}))};t.push(n),window.require?require([n],s):window.sssl?sssl(n,s):window.yepnope?yepnope.injectJs(n,s):window.steal&&steal(n).then(s)}}()}};e.webshims=c;var h=location.protocol=="https:"?"https://":"http://",p=h+"ajax.googleapis.com/ajax/libs/",d=p+"jqueryui/1.8.24/",v=c.cfg,m=c.features,g=c.isReady,y=c.ready,b=c.addPolyfill,w=c.modules,E=c.loader,S=E.loadList,x=E.addModule,T=c.bugs,N=[],C={warn:1,error:1};c.addMethodName=function(t){t=t.split(":");var n=t[1];t.length==1?(n=t[0],t=t[0]):t=t[0],e.fn[t]=function(){return this.callProp(n,arguments)}},e.fn.callProp=function(t,n){var r;return n||(n=[]),this.each(function(){var i=e.prop(this,t);if(i&&i.apply){r=i.apply(this,n);if(r!==undefined)return!1}else c.warn(t+" is not a method of "+this)}),r!==undefined?r:this},c.activeLang=function(){var e=navigator.browserLanguage||navigator.language||"";return y("webshimLocalization",function(){c.activeLang(e)}),function(t){if(t)if(typeof t=="string")e=t;else if(typeof t=="object"){var n=arguments,r=this;y("webshimLocalization",function(){c.activeLang.apply(r,n)})}return e}}(),e.each(["log","error","warn","info"],function(e,t){c[t]=function(e){if((C[t]&&c.debug!==!1||c.debug)&&window.console&&console.log)return console[console[t]?t:"log"](e)}}),function(){e.isDOMReady=e.isReady;if(!e.isDOMReady){var t=e.ready;e.ready=function(n){return n!==!0&&!e.isDOMReady&&(document.body?(e.isDOMReady=!0,g("DOM",!0),e.ready=t):setTimeout(function(){e.ready(n)},13)),t.apply(this,arguments)},e.ready.promise=t.promise}else g("DOM",!0);e(function(){e.isDOMReady=!0,g("DOM",!0),setTimeout(function(){g("WINDOWLOAD",!0)},9999)}),e(window).load(function(){e.isDOMReady=!0,g("DOM",!0),g("WINDOWLOAD",!0)})}(),function(){var t=[];e.extend(c,{addReady:function(e){var n=function(t,n){c.ready("DOM",function(){e(t,n)})};t.push(n),n(document,i)},triggerDomUpdate:function(n){if(!n||!n.nodeType){n&&n.jquery&&n.each(function(){c.triggerDomUpdate(this)});return}var r=n.nodeType;if(r!=1&&r!=9)return;var s=n!==document?e(n):i;e.each(t,function(e,t){t(n,s)})}}),e.fn.htmlPolyfill=function(t){var n=e.fn.html.call(this,t);return n===this&&e.isDOMReady&&this.each(function(){this.nodeType==1&&c.triggerDomUpdate(this)}),n},e.fn.jProp=function(){return e(e.fn.prop.apply(this,arguments)||[])},e.each(["after","before","append","prepend","replaceWith"],function(t,n){e.fn[n+"Polyfill"]=function(t){return t=e(t),e.fn[n].call(this,t),e.isDOMReady&&t.each(function(){this.nodeType==1&&c.triggerDomUpdate(this)}),this}}),e.each(["insertAfter","insertBefore","appendTo","prependTo","replaceAll"],function(t,n){e.fn[n.replace(/[A-Z]/,function(e){return"Polyfill"+e})]=function(){return e.fn[n].apply(this,arguments),e.isDOMReady&&c.triggerDomUpdate(this),this}}),e.fn.updatePolyfill=function(){return e.isDOMReady&&c.triggerDomUpdate(this),this},e.each(["getNativeElement","getShadowElement","getShadowFocusElement"],function(t,n){e.fn[n]=function(){return this}})}(),function(){var t="defineProperty",n=a.prototype.hasOwnProperty,r=["configurable","enumerable","writable"],i=function(e){for(var t=0;t<3;t++)e[r[t]]===undefined&&(r[t]!=="writable"||e.value!==undefined)&&(e[r[t]]=!0)},s=function(e){if(e)for(var t in e)n.call(e,t)&&i(e[t])};a.create&&(c.objectCreate=function(t,n,r){s(n);var i=a.create(t,n);return r&&(i.options=e.extend(!0,{},i.options||{},r),r=i.options),i._create&&e.isFunction(i._create)&&i._create(r),i}),a[t]&&(c[t]=function(e,n,r){return i(r),a[t](e,n,r)}),a.defineProperties&&(c.defineProperties=function(e,t){return s(t),a.defineProperties(e,t)}),c.getOwnPropertyDescriptor=a.getOwnPropertyDescriptor,c.getPrototypeOf=a.getPrototypeOf}(),x("jquery-ui",{src:d+"jquery-ui.min.js",test:function(){return c.warn("deprecated module: "+this.name),!!e.widget&&!!e.Widget}}),x("input-widgets",{src:"",test:function(){return c.warn("deprecated module: "+this.name),!this.src||!e.widget||!!e.fn.datepicker&&!!e.fn.slider}}),window.swfobject&&(window.swfmini=window.swfobject),x("swfmini",{test:function(){return window.swfobject&&(window.swfmini=window.swfobject),"swfmini"in window},c:[2,1]}),b("es5",{test:!!s.ES5&&!!Function.prototype.bind,c:[]}),b("dom-extend",{f:t,noAutoCallback:!0,d:["es5"],c:[2,3,4]}),l("localstorage"),b("json-storage",{test:s.localstorage&&"sessionStorage"in window&&"JSON"in window,d:["swfmini"],noAutoCallback:!0,c:[]}),l("geolocation"),b("geolocation",{test:s.geolocation,options:{destroyWrite:!0},d:["json-storage"],c:[]}),l("canvas",function(){var n;b("canvas",{src:"excanvas",test:s.canvas,options:{type:"flash"},noAutoCallback:!0,loadInit:function(){var t=this.options.type,r;t&&t.indexOf("flash")!==-1&&(!window.swfmini||swfmini.hasFlashPlayerVersion("9.0.0"))&&(window.FlashCanvasOptions=window.FlashCanvasOptions||{},n=FlashCanvasOptions,t=="flash"?(e.extend(n,{swfPath:v.basePath+"FlashCanvas/"}),this.src="FlashCanvas/flashcanvas",r=n.swfPath+"flashcanvas.swf"):(e.extend(n,{swfPath:v.basePath+"FlashCanvasPro/"}),this.src="FlashCanvasPro/flashcanvas",r=n.swfPath+"flash10canvas.swf"))},afterLoad:function(){c.addReady(function(t,n){t==document&&window.G_vmlCanvasManager&&G_vmlCanvasManager.init_&&G_vmlCanvasManager.init_(document),e("canvas",t).add(n.filter("canvas")).each(function(){var e=this.getContext;!e&&window.G_vmlCanvasManager&&G_vmlCanvasManager.initElement(this)}),t==document&&g("canvas",!0)})},methodNames:["getContext"],d:[t]})}),l("input inputtypes",function(){var n=s.input,r=s.inputtypes,i="formvalidation",o=e('<select required="" name="a"><option disabled="" /></select>')[0],a=!1,f,l;u(i,function(){return!!n.required&&!!n.pattern}),u("fieldsetdisabled",function(){var t=e("<fieldset />")[0];return"elements"in t&&"disabled"in t}),s[i]&&(T.bustedValidity=a=s.formattribute===!1||!s.fieldsetdisabled||!("value"in document.createElement("output"))||!(e('<input type="date" value="1488-12-11" />')[0].validity||{valid:!0}).valid||!("required"in o)||(o.validity||{}).valid),f=s[i]&&!a?"form-native-extend":"form-shim-extend",u("styleableinputrange",function(){if(!r.range)return!1;var e=document.createElement("input");return e.setAttribute("type","range"),e.style.WebkitAppearance!==undefined}),c.formcfg=[],c.validationMessages=c.validityMessages=[],c.inputTypes={},b("form-core",{f:"forms",d:["es5"],options:{placeholderType:"value",langSrc:"i18n/formcfg-",messagePopover:{},datalistPopover:{constrainWidth:!0},availabeLangs:["ar","ch-ZN","el","es","fr","he","hi","hu","it","ja","nl","pt-PT","ru","sv"]},methodNames:["setCustomValidity","checkValidity"],c:[2,1,3]}),l=v.forms,b("form-native-extend",{f:"forms",test:function(t){return!s[i]||a||(w["form-number-date-api"].test()||e.inArray("form-number-date-api",t||[])==-1)&&!l.overrideMessages},d:["form-core",t,"form-message"],c:[6,5]}),b("form-shim-extend",{f:"forms",test:function(){return s[i]&&!a},d:["form-core",t],c:[]}),b("form-message",{f:"forms",test:function(e){return!(l.customMessages||!s[i]||T.validationMessage||a||!w[f].test(e))},d:[t],c:[3,4]}),b("form-number-date-api",{f:"forms-ext",options:{types:["range","date","time","number","month"]},test:function(t){var n=!0;return e.each(this.options.types,function(e,t){if(!r[t])return n=!1,!1}),n},methodNames:["stepUp","stepDown"],d:["forms",t],c:[6,5]}),e.webshims.loader.addModule("range-ui",{options:{},noAutoCallback:!0,c:[6,5]}),b("form-number-date-ui",{f:"forms-ext",test:function(){return console.log(this.options.replaceUI),w["form-number-date-api"].test()&&!this.options.replaceUI},d:["forms",t,"form-number-date-api","range-ui"],loadInit:function(){},options:{calculateWidth:!0},c:[6,5]}),b("form-datalist",{f:"forms",test:function(){return n.list&&!l.customDatalist},d:["form-core",t],c:[6,2]})}),"details"in s||u("details",function(){return"open"in document.createElement("details")}),b("details",{test:s.details,d:[t],options:{text:"Details"},c:[]}),l("audio video texttrackapi",function(){c.mediaelement={};var n=function(){if(!s.audio||!s.video)return!1;if(c.mediaelement.loadSwf)return!1;var e=this.options,t=e.hasToPlay;return!!window.swfmini&&!window.swfmini.hasFlashPlayerVersion("9.0.115")||!(e.preferFlash||t!="any"&&!s.video[t]&&!s.audio[t])},r=["swfmini",t];b("mediaelement-core",{f:"mediaelement",noAutoCallback:!0,options:{hasToPlay:"any",preferFlash:!1,player:"jaris",vars:{},params:{},attrs:{},changeSWF:e.noop},methodNames:["play","pause","canPlayType","mediaLoad:load"],d:["swfmini"],c:[2,1]}),b("mediaelement-swf",{f:"mediaelement",d:r,test:function(){return this.options.player!="jwplayer"?!0:n.apply(this,arguments)}}),b("mediaelement-jaris",{f:"mediaelement",d:r,test:function(){return this.options.player=="jwplayer"?!0:n.apply(this,arguments)},c:[]}),T.track=s.track&&(!s.texttrackapi||typeof (document.createElement("track").track||{}).mode!="string"),b("track",{options:{positionDisplay:!0,override:T.track},test:function(){return s.track&&!this.options.override&&!T.track},d:["mediaelement",t],methodNames:["addTextTrack"],c:[]}),x("track-ui",{d:["track"]})}),b("feature-dummy",{test:!0,loaded:!0,c:N}),n.filter("[data-polyfill-cfg]").each(function(){try{c.setOptions(e(this).data("polyfillCfg"))}catch(t){c.warn("error parsing polyfill cfg: "+t)}}).end().filter("[data-polyfill]").each(function(){c.polyfill(e.trim(e(this).data("polyfill")||""))}),o&&(o.cfg&&c.setOptions(o.cfg),o.lang&&c.activeLang(o.lang),"polyfill"in o&&c.polyfill(o.polyfill))});
+(function(e){window.jQuery&&(e(jQuery),e=jQuery.noop),typeof define=="function"&&define.amd&&define.amd.jQuery&&define("polyfiller",["jquery"],e)})(function(e){"use strict";var t="dom-support",n=e(document.scripts||"script"),r=e.event.special,i=e([]),s=window.Modernizr,o=window.asyncWebshims,u=s.addTest,a=window.Object,f=window.html5||{},l=function(t,n){var r=!0;e.each(t.split(" "),function(e,t){t in s||(c.error("webshims needs Modernizr."+t+" to implement feature."),r=!1)}),r&&n&&n()};s.advancedObjectProperties=s.objectAccessor=s.ES5="create"in a&&"seal"in a,e.event.customEvent||(e.event.customEvent={});var c={version:"1.10.0dev",cfg:{useImportantStyles:!0,waitReady:!0,extendNative:!0,loadStyles:!0,disableShivMethods:!0,wspopover:{appendTo:"body",hideOnBlur:!0},basePath:function(){var t=n.filter('[src*="polyfiller.js"]'),r;return t=t[0]||t.end()[t.end().length-1],r=(e.support.hrefNormalized?t.src:t.getAttribute("src",4)).split("?")[0],r=r.slice(0,r.lastIndexOf("/")+1)+"shims/",r}()},bugs:{},modules:{},features:{},featureList:[],setOptions:function(t,n){typeof t=="string"&&n!==undefined?v[t]=e.isPlainObject(n)?e.extend(!0,v[t]||{},n):n:typeof t=="object"&&e.extend(!0,v,t)},addPolyfill:function(t,n){n=n||{};var r=n.f||t;m[r]||(m[r]=[],m[r].delayReady=0,c.featureList.push(r),v[r]={}),m[r].push(t),n.options=e.extend(v[r],n.options),x(t,n),n.methodNames&&e.each(n.methodNames,function(e,t){c.addMethodName(t)})},polyfill:function(){var t=function(n){var r=[],i=n,s;v.disableShivMethods&&(f.shivMethods=!1);var o=function(){e("html").removeClass("loading-polyfills long-loading-polyfills"),e(window).unbind(".lP"),clearTimeout(s)};e(window).on("load.lP error.lP",o),r.push("loading-polyfills"),s=setTimeout(function(){e("html").addClass("long-loading-polyfills")},400),v.waitReady&&e.isReady&&c.warn("Call webshims.polyfill before DOM-Ready or set waitReady to false."),y(n,o),v.useImportantStyles&&r.push("polyfill-important"),r[0]&&e("html").addClass(r.join(" ")),v.loadStyles&&E.loadCSS("styles/shim.css"),t=e.noop},n;return function(r){var i=[];r=r||c.featureList,typeof r=="string"&&(r=r.split(" ")),n||(n=e.inArray("forms",r)!==-1,!n&&e.inArray("forms-ext",r)!==-1&&(r.push("forms"),n=!0)),v.waitReady&&(e.readyWait++,y(r,function(){e.ready(!0)})),e.each(r,function(e,t){if(!m[t]){c.error("could not find webshims-feature (aborted): "+t),g(t,!0);return}t!==m[t][0]&&y(m[t],function(){g(t,!0)}),i=i.concat(m[t])}),t(r),S(i)}}(),reTest:function(){var t,n,i=function(i,s){var o=w[s],u=s+"Ready",a;o&&!o.loaded&&(o.test&&e.isFunction(o.test)?!o.test([]):!o.test)&&(r[u]&&delete r[u],a=m[o.f],a&&!n&&(a.delayReady++,y(s,function(){a.delayReady--,g(o.f,a.callReady)})),t.push(s))};return function(r,s){n=s,typeof r=="string"&&(r=r.split(" ")),t=[],e.each(r,i),S(t)}}(),isReady:function(t,n){if(m[t]&&m[t].delayReady>0)return n&&(m[t].callReady=!0),!1;t+="Ready";if(n){if(r[t]&&r[t].add)return!0;r[t]=e.extend(r[t]||{},{add:function(e){e.handler.call(this,t)}}),e(document).triggerHandler(t)}return!!r[t]&&!!r[t].add||!1},ready:function(t,n){var r=arguments[2],i=t;typeof t=="string"&&(t=t.split(" ")),r||(t=e.map(e.grep(t,function(e){return!g(e)}),function(e){return e+"Ready"}));if(!t.length){n(e,c,window,document);return}var s=t.shift(),o=function(){y(t,n,!0)};e(document).one(s,o)},capturingEvents:function(t,n){if(!document.addEventListener)return;typeof t=="string"&&(t=[t]),e.each(t,function(t,i){var s=function(t){return t=e.event.fix(t),n&&c.capturingEventPrevented&&c.capturingEventPrevented(t),e.event.dispatch.call(this,t)};r[i]=r[i]||{};if(r[i].setup||r[i].teardown)return;e.extend(r[i],{setup:function(){this.addEventListener(i,s,!0)},teardown:function(){this.removeEventListener(i,s,!0)}})})},register:function(t,n){var r=w[t];if(!r){c.error("can't find module: "+t);return}if(r.noAutoCallback){var i=function(){n(e,c,window,document,undefined,r.options),g(t,!0)};r.d&&r.d.length?y(r.d,i):i()}},c:{},loader:{addModule:function(t,n){w[t]=n,n.name=n.name||t,n.c||(n.c=[]),e.each(n.c,function(e,n){c.c[n]||(c.c[n]=[]),c.c[n].push(t)})},loadList:function(){var t=[],n=function(n,r){typeof r=="string"&&(r=[r]),e.merge(t,r),E.loadScript(n,!1,r)},r=function(n,r){if(g(n)||e.inArray(n,t)!=-1)return!0;var i=w[n],s=v[i.f||n]||{},o;return i?(o=i.test&&e.isFunction(i.test)?i.test(r):i.test,o?(g(n,!0),!0):!1):!0},i=function(t,n){if(t.d&&t.d.length){var i=function(t,i){!r(i,n)&&e.inArray(i,n)==-1&&n.push(i)};e.each(t.d,function(t,n){w[n]?i(t,n):m[n]&&(e.each(m[n],i),y(m[n],function(){g(n,!0)}))}),t.noAutoCallback||(t.noAutoCallback=!0)}};return function(s,o){var u,a=[],f,l,h,p=function(r,i){h=i,e.each(c.c[i],function(n,r){if(e.inArray(r,a)==-1||e.inArray(r,t)!=-1)return h=!1,!1});if(h)return n("combos/"+h,c.c[h]),!1};for(f=0;f<s.length;f++){u=w[s[f]];if(!u||r(u.name,s)){u||c.warn("could not find: "+s[f]);continue}u.css&&E.loadCSS(u.css),u.loadInit&&u.loadInit(),u.loaded=!0,i(u,s),a.push(u.name)}for(f=0,l=a.length;f<l;f++)h=!1,u=a[f],e.inArray(u,t)==-1&&(c.debug!="noCombo"&&e.each(w[u].c,p),h||n(w[u].src||u,u))}}(),makePath:function(e){return e.indexOf("//")!=-1||e.indexOf("/")===0?e:(e.indexOf(".")==-1&&(e+=".js"),v.addCacheBuster&&(e+=v.addCacheBuster),v.basePath+e)},loadCSS:function(){var t,n=[];return function(r){r=this.makePath(r);if(e.inArray(r,n)!=-1)return;t=t||e("link, style")[0]||e("script")[0],n.push(r),e('<link rel="stylesheet" />').insertBefore(t).attr({href:r})}}(),loadScript:function(){var t=[],n;return function(n,r,i){n=E.makePath(n);if(e.inArray(n,t)!=-1)return;var s=function(){s=null,r&&r(),i&&(typeof i=="string"&&(i=i.split(" ")),e.each(i,function(e,t){if(!w[t])return;w[t].afterLoad&&w[t].afterLoad(),g(w[t].noAutoCallback?t+"FileLoaded":t,!0)}))};t.push(n),window.require?require([n],s):window.sssl?sssl(n,s):window.yepnope?yepnope.injectJs(n,s):window.steal&&steal(n).then(s)}}()}};e.webshims=c;var h=location.protocol=="https:"?"https://":"http://",p=h+"ajax.googleapis.com/ajax/libs/",d=p+"jqueryui/1.8.24/",v=c.cfg,m=c.features,g=c.isReady,y=c.ready,b=c.addPolyfill,w=c.modules,E=c.loader,S=E.loadList,x=E.addModule,T=c.bugs,N=[],C={warn:1,error:1};c.addMethodName=function(t){t=t.split(":");var n=t[1];t.length==1?(n=t[0],t=t[0]):t=t[0],e.fn[t]=function(){return this.callProp(n,arguments)}},e.fn.callProp=function(t,n){var r;return n||(n=[]),this.each(function(){var i=e.prop(this,t);if(i&&i.apply){r=i.apply(this,n);if(r!==undefined)return!1}else c.warn(t+" is not a method of "+this)}),r!==undefined?r:this},c.activeLang=function(){var e=navigator.browserLanguage||navigator.language||"";return y("webshimLocalization",function(){c.activeLang(e)}),function(t){if(t)if(typeof t=="string")e=t;else if(typeof t=="object"){var n=arguments,r=this;y("webshimLocalization",function(){c.activeLang.apply(r,n)})}return e}}(),e.each(["log","error","warn","info"],function(e,t){c[t]=function(e){if((C[t]&&c.debug!==!1||c.debug)&&window.console&&console.log)return console[console[t]?t:"log"](e)}}),function(){e.isDOMReady=e.isReady;if(!e.isDOMReady){var t=e.ready;e.ready=function(n){return n!==!0&&!e.isDOMReady&&(document.body?(e.isDOMReady=!0,g("DOM",!0),e.ready=t):setTimeout(function(){e.ready(n)},13)),t.apply(this,arguments)},e.ready.promise=t.promise}else g("DOM",!0);e(function(){e.isDOMReady=!0,g("DOM",!0),setTimeout(function(){g("WINDOWLOAD",!0)},9999)}),e(window).load(function(){e.isDOMReady=!0,g("DOM",!0),g("WINDOWLOAD",!0)})}(),function(){var t=[];e.extend(c,{addReady:function(e){var n=function(t,n){c.ready("DOM",function(){e(t,n)})};t.push(n),n(document,i)},triggerDomUpdate:function(n){if(!n||!n.nodeType){n&&n.jquery&&n.each(function(){c.triggerDomUpdate(this)});return}var r=n.nodeType;if(r!=1&&r!=9)return;var s=n!==document?e(n):i;e.each(t,function(e,t){t(n,s)})}}),e.fn.htmlPolyfill=function(t){var n=e.fn.html.call(this,t);return n===this&&e.isDOMReady&&this.each(function(){this.nodeType==1&&c.triggerDomUpdate(this)}),n},e.fn.jProp=function(){return e(e.fn.prop.apply(this,arguments)||[])},e.each(["after","before","append","prepend","replaceWith"],function(t,n){e.fn[n+"Polyfill"]=function(t){return t=e(t),e.fn[n].call(this,t),e.isDOMReady&&t.each(function(){this.nodeType==1&&c.triggerDomUpdate(this)}),this}}),e.each(["insertAfter","insertBefore","appendTo","prependTo","replaceAll"],function(t,n){e.fn[n.replace(/[A-Z]/,function(e){return"Polyfill"+e})]=function(){return e.fn[n].apply(this,arguments),e.isDOMReady&&c.triggerDomUpdate(this),this}}),e.fn.updatePolyfill=function(){return e.isDOMReady&&c.triggerDomUpdate(this),this},e.each(["getNativeElement","getShadowElement","getShadowFocusElement"],function(t,n){e.fn[n]=function(){return this}})}(),function(){var t="defineProperty",n=a.prototype.hasOwnProperty,r=["configurable","enumerable","writable"],i=function(e){for(var t=0;t<3;t++)e[r[t]]===undefined&&(r[t]!=="writable"||e.value!==undefined)&&(e[r[t]]=!0)},s=function(e){if(e)for(var t in e)n.call(e,t)&&i(e[t])};a.create&&(c.objectCreate=function(t,n,r){s(n);var i=a.create(t,n);return r&&(i.options=e.extend(!0,{},i.options||{},r),r=i.options),i._create&&e.isFunction(i._create)&&i._create(r),i}),a[t]&&(c[t]=function(e,n,r){return i(r),a[t](e,n,r)}),a.defineProperties&&(c.defineProperties=function(e,t){return s(t),a.defineProperties(e,t)}),c.getOwnPropertyDescriptor=a.getOwnPropertyDescriptor,c.getPrototypeOf=a.getPrototypeOf}(),x("jquery-ui",{src:d+"jquery-ui.min.js",test:function(){return c.warn("deprecated module: "+this.name),!!e.widget&&!!e.Widget}}),x("input-widgets",{src:"",test:function(){return c.warn("deprecated module: "+this.name),!this.src||!e.widget||!!e.fn.datepicker&&!!e.fn.slider}}),x("swfmini",{test:function(){return window.swfobject&&!window.swfmini&&(window.swfmini=window.swfobject),"swfmini"in window},c:[2,1]}),w.swfmini.test(),b("es5",{test:!!s.ES5&&!!Function.prototype.bind,c:[]}),b("dom-extend",{f:t,noAutoCallback:!0,d:["es5"],c:[2,3,4]}),l("localstorage"),b("json-storage",{test:s.localstorage&&"sessionStorage"in window&&"JSON"in window,d:["swfmini"],noAutoCallback:!0,c:[]}),l("geolocation"),b("geolocation",{test:s.geolocation,options:{destroyWrite:!0},d:["json-storage"],c:[]}),l("canvas",function(){var n;b("canvas",{src:"excanvas",test:s.canvas,options:{type:"flash"},noAutoCallback:!0,loadInit:function(){var t=this.options.type,r;t&&t.indexOf("flash")!==-1&&(!w.swfmini.test()||swfmini.hasFlashPlayerVersion("9.0.0"))&&(window.FlashCanvasOptions=window.FlashCanvasOptions||{},n=FlashCanvasOptions,t=="flash"?(e.extend(n,{swfPath:v.basePath+"FlashCanvas/"}),this.src="FlashCanvas/flashcanvas",r=n.swfPath+"flashcanvas.swf"):(e.extend(n,{swfPath:v.basePath+"FlashCanvasPro/"}),this.src="FlashCanvasPro/flashcanvas",r=n.swfPath+"flash10canvas.swf"))},afterLoad:function(){c.addReady(function(t,n){t==document&&window.G_vmlCanvasManager&&G_vmlCanvasManager.init_&&G_vmlCanvasManager.init_(document),e("canvas",t).add(n.filter("canvas")).each(function(){var e=this.getContext;!e&&window.G_vmlCanvasManager&&G_vmlCanvasManager.initElement(this)}),t==document&&g("canvas",!0)})},methodNames:["getContext"],d:[t]})}),l("input inputtypes",function(){var n=s.input,r=s.inputtypes,i="formvalidation",o=e('<select required="" name="a"><option disabled="" /></select>')[0],a=!1,f,l;u(i,function(){return!!n.required&&!!n.pattern}),u("fieldsetdisabled",function(){var t=e("<fieldset />")[0];return"elements"in t&&"disabled"in t}),s[i]&&(T.bustedValidity=a=s.formattribute===!1||!s.fieldsetdisabled||!("value"in document.createElement("progress"))||!("value"in document.createElement("output"))||!(e('<input type="date" value="1488-12-11" />')[0].validity||{valid:!0}).valid||!("required"in o)||(o.validity||{}).valid),f=s[i]&&!a?"form-native-extend":"form-shim-extend",u("styleableinputrange",function(){if(!r.range)return!1;var e=document.createElement("input");return e.setAttribute("type","range"),e.style.WebkitAppearance!==undefined}),c.formcfg=[],c.validationMessages=c.validityMessages=[],c.inputTypes={},b("form-core",{f:"forms",d:["es5"],options:{placeholderType:"value",langSrc:"i18n/formcfg-",messagePopover:{},datalistPopover:{constrainWidth:!0},availabeLangs:["ar","ch-ZN","el","es","fr","he","hi","hu","it","ja","nl","pt-PT","ru","sv"]},methodNames:["setCustomValidity","checkValidity"],c:[2,1,3]}),l=v.forms,b("form-native-extend",{f:"forms",test:function(t){return!s[i]||a||(w["form-number-date-api"].test()||e.inArray("form-number-date-api",t||[])==-1)&&!l.overrideMessages},d:["form-core",t,"form-message"],c:[6,5]}),b("form-shim-extend",{f:"forms",test:function(){return s[i]&&!a},d:["form-core",t],c:[]}),b("form-message",{f:"forms",test:function(e){return!(l.customMessages||!s[i]||T.validationMessage||a||!w[f].test(e))},d:[t],c:[3,4]}),b("form-number-date-api",{f:"forms-ext",options:{types:["range","date","time","number","month"]},test:function(t){var n=!0;return e.each(this.options.types,function(e,t){if(!r[t])return n=!1,!1}),n},methodNames:["stepUp","stepDown"],d:["forms",t],c:[6,5]}),e.webshims.loader.addModule("range-ui",{options:{},noAutoCallback:!0,c:[6,5]}),b("form-number-date-ui",{f:"forms-ext",test:function(){return!this.options.replaceUI&&w["form-number-date-api"].test()},d:["forms",t,"form-number-date-api","range-ui"],options:{calculateWidth:!0},c:[6,5]}),b("form-datalist",{f:"forms",test:function(){return n.list&&!l.customDatalist},d:["form-core",t],c:[6,2]})}),"details"in s||u("details",function(){return"open"in document.createElement("details")}),b("details",{test:s.details,d:[t],options:{text:"Details"},c:[]}),l("audio video texttrackapi",function(){c.mediaelement={};var n=function(){if(!s.audio||!s.video)return!1;if(c.mediaelement.loadSwf)return!1;var e=this.options;return e.preferFlash&&!w.swfmini.test()&&(e.preferFlash=!1),!e.preferFlash||!window.swfmini.hasFlashPlayerVersion("9.0.115")},r=["swfmini",t];b("mediaelement-core",{f:"mediaelement",noAutoCallback:!0,options:{preferFlash:!1,player:"jaris",vars:{},params:{},attrs:{},changeSWF:e.noop},methodNames:["play","pause","canPlayType","mediaLoad:load"],d:["swfmini"],c:[2,1]}),b("mediaelement-swf",{f:"mediaelement",d:r,test:function(){return this.options.player!="jwplayer"?!0:n.apply(this,arguments)}}),b("mediaelement-jaris",{f:"mediaelement",d:r,test:function(){return this.options.player=="jwplayer"?!0:n.apply(this,arguments)},c:[]}),T.track=s.track&&(!s.texttrackapi||typeof (document.createElement("track").track||{}).mode!="string"),b("track",{options:{positionDisplay:!0,override:T.track},test:function(){return s.track&&!this.options.override&&!T.track},d:["mediaelement",t],methodNames:["addTextTrack"],c:[]}),x("track-ui",{d:["track"]})}),b("feature-dummy",{test:!0,loaded:!0,c:N}),n.filter("[data-polyfill-cfg]").each(function(){try{c.setOptions(e(this).data("polyfillCfg"))}catch(t){c.warn("error parsing polyfill cfg: "+t)}}).end().filter("[data-polyfill]").each(function(){c.polyfill(e.trim(e(this).data("polyfill")||""))}),o&&(o.cfg&&c.setOptions(o.cfg),o.lang&&c.activeLang(o.lang),"polyfill"in o&&c.polyfill(o.polyfill))});
View
2  demos/js-webshim/minified/shims/combos/1.js
@@ -1 +1 @@
-var swfmini=function(){function S(){if(g)return;try{var e=u.getElementsByTagName("body")[0].appendChild(H("span"));e.parentNode.removeChild(e)}catch(t){return}g=!0;var n=l.length;for(var r=0;r<n;r++)l[r]()}function x(e){g?e():l[l.length]=e}function T(e){}function N(){f&&C()}function C(){var n=u.getElementsByTagName("body")[0],r=H(t);r.setAttribute("type",s);var i=n.appendChild(r);if(i){var o=0;(function(){if(typeof i.GetVariable!=e){var t=i.GetVariable("$version");t&&(t=t.split(" ")[1].split(","),E.pv=[parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10)])}else if(o<10){o++,setTimeout(arguments.callee,10);return}n.removeChild(r),i=null})()}}function k(n){var r=null,i=P(n);if(i&&i.nodeName=="OBJECT")if(typeof i.SetVariable!=e)r=i;else{var s=i.getElementsByTagName(t)[0];s&&(r=s)}return r}function L(e){if(E.ie&&E.win&&e.readyState!=4){var t=H("div");e.parentNode.insertBefore(t,e),t.parentNode.replaceChild(A(e),t),e.style.display="none",function(){e.readyState==4?e.parentNode.removeChild(e):setTimeout(arguments.callee,10)}()}else e.parentNode.replaceChild(A(e),e)}function A(e){var n=H("div");if(E.win&&E.ie)n.innerHTML=e.innerHTML;else{var r=e.getElementsByTagName(t)[0];if(r){var i=r.childNodes;if(i){var s=i.length;for(var o=0;o<s;o++)(i[o].nodeType!=1||i[o].nodeName!="PARAM")&&i[o].nodeType!=8&&n.appendChild(i[o].cloneNode(!0))}}}return n}function O(n,r,i){var o,u=P(i);if(E.wk&&E.wk<312)return o;if(u){typeof n.id==e&&(n.id=i);if(E.ie&&E.win){var a="";for(var f in n)n[f]!=Object.prototype[f]&&(f.toLowerCase()=="data"?r.movie=n[f]:f.toLowerCase()=="styleclass"?a+=' class="'+n[f]+'"':f.toLowerCase()!="classid"&&(a+=" "+f+'="'+n[f]+'"'));var l="";for(var h in r)r[h]!=Object.prototype[h]&&(l+='<param name="'+h+'" value="'+r[h]+'" />');u.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+a+">"+l+"</object>",c[c.length]=n.id,o=P(n.id)}else{var p=H(t);p.setAttribute("type",s);for(var d in n)n[d]!=Object.prototype[d]&&(d.toLowerCase()=="styleclass"?p.setAttribute("class",n[d]):d.toLowerCase()!="classid"&&p.setAttribute(d,n[d]));for(var v in r)r[v]!=Object.prototype[v]&&v.toLowerCase()!="movie"&&M(p,v,r[v]);u.parentNode.replaceChild(p,u),o=p}}return o}function M(e,t,n){var r=H("param");r.setAttribute("name",t),r.setAttribute("value",n),e.appendChild(r)}function _(e){var t=P(e);t&&t.nodeName=="OBJECT"&&(E.ie&&E.win?(t.style.display="none",function(){t.readyState==4?D(e):setTimeout(arguments.callee,10)}()):t.parentNode.removeChild(t))}function D(e){var t=P(e);if(t){for(var n in t)typeof t[n]=="function"&&(t[n]=null);t.parentNode.removeChild(t)}}function P(e){var t=null;try{t=u.getElementById(e)}catch(n){}return t}function H(e){return u.createElement(e)}function B(e,t,n){e.attachEvent(t,n),h[h.length]=[e,t,n]}function j(e){var t=E.pv,n=e.split(".");return n[0]=parseInt(n[0],10),n[1]=parseInt(n[1],10)||0,n[2]=parseInt(n[2],10)||0,t[0]>n[0]||t[0]==n[0]&&t[1]>n[1]||t[0]==n[0]&&t[1]==n[1]&&t[2]>=n[2]?!0:!1}function F(e,t){if(!w)return;var n,r=t?"visible":"hidden";g&&n&&P(e)&&(P(e).style.visibility=r)}function I(t){var n=/[\\\"<>\.;]/,r=n.exec(t)!=null;return r&&typeof encodeURIComponent!=e?encodeURIComponent(t):t}var e="undefined",t="object",n=jQuery.webshims,r="Shockwave Flash",i="ShockwaveFlash.ShockwaveFlash",s="application/x-shockwave-flash",o=window,u=document,a=navigator,f=!1,l=[N],c=[],h=[],p,d,v,m,g=!1,y,b,w=!0,E=function(){var n=typeof u.getElementById!=e&&typeof u.getElementsByTagName!=e&&typeof u.createElement!=e,l=a.userAgent.toLowerCase(),c=a.platform.toLowerCase(),h=c?/win/.test(c):/win/.test(l),p=c?/mac/.test(c):/mac/.test(l),d=/webkit/.test(l)?parseFloat(l.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):!1,v=!1,m=[0,0,0],g=null;if(typeof a.plugins!=e&&typeof a.plugins[r]==t)g=a.plugins[r].description,g&&(typeof a.mimeTypes==e||!a.mimeTypes[s]||!!a.mimeTypes[s].enabledPlugin)&&(f=!0,v=!1,g=g.replace(/^.*\s+(\S+\s+\S+$)/,"$1"),m[0]=parseInt(g.replace(/^(.*)\..*$/,"$1"),10),m[1]=parseInt(g.replace(/^.*\.(.*)\s.*$/,"$1"),10),m[2]=/[a-zA-Z]/.test(g)?parseInt(g.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0);else if(typeof o.ActiveXObject!=e)try{var y=new ActiveXObject(i);y&&(g=y.GetVariable("$version"),g&&(v=!0,g=g.split(" ")[1].split(","),m=[parseInt(g[0],10),parseInt(g[1],10),parseInt(g[2],10)]))}catch(b){}return{w3:n,pv:m,wk:d,ie:v,win:h,mac:p}}(),q=function(){E.ie&&E.win&&window.attachEvent&&window.attachEvent("onunload",function(){var e=h.length;for(var t=0;t<e;t++)h[t][0].detachEvent(h[t][1],h[t][2]);var n=c.length;for(var r=0;r<n;r++)_(c[r]);for(var i in E)E[i]=null;E=null;for(var s in swfmini)swfmini[s]=null;swfmini=null})}();return n.ready("DOM",S),{registerObject:function(){},getObjectById:function(e){if(E.w3)return k(e)},embedSWF:function(n,r,i,s,o,u,a,f,l,c){var h={success:!1,id:r};E.w3&&!(E.wk&&E.wk<312)&&n&&r&&i&&s&&o?(F(r,!1),x(function(){i+="",s+="";var u={};if(l&&typeof l===t)for(var p in l)u[p]=l[p];u.data=n,u.width=i,u.height=s;var d={};if(f&&typeof f===t)for(var v in f)d[v]=f[v];if(a&&typeof a===t)for(var m in a)typeof d.flashvars!=e?d.flashvars+="&"+m+"="+a[m]:d.flashvars=m+"="+a[m];if(j(o)){var g=O(u,d,r);u.id==r&&F(r,!0),h.success=!0,h.ref=g}else F(r,!0);c&&c(h)})):c&&c(h)},switchOffAutoHideShow:function(){w=!1},ua:E,getFlashPlayerVersion:function(){return{major:E.pv[0],minor:E.pv[1],release:E.pv[2]}},hasFlashPlayerVersion:j,createSWF:function(e,t,n){return E.w3?O(e,t,n):undefined},showExpressInstall:function(){},removeSWF:function(e){E.w3&&_(e)},createCSS:function(){},addDomLoadEvent:x,addLoadEvent:T,expressInstallCallback:function(){}}}();(function(e){"use strict";var t="webkitURL"in window,n=window.Modernizr,r=e.webshims,i=r.bugs,s=e('<form action="#" style="width: 1px; height: 1px; overflow: hidden;"><select name="b" required="" /><input required="" name="a" /></form>'),o=function(){if(s[0].querySelector)try{i.findRequired=!s[0].querySelector("select:required")}catch(e){i.findRequired=!1}},u=e("input",s).eq(0),a=function(e){r.loader.loadList(["dom-extend"]),r.ready("dom-extend",e)};i.findRequired=!1,i.validationMessage=!1,r.capturingEventPrevented=function(t){if(!t._isPolyfilled){var n=t.isDefaultPrevented,r=t.preventDefault;t.preventDefault=function(){return clearTimeout(e.data(t.target,t.type+"DefaultPrevented")),e.data(t.target,t.type+"DefaultPrevented",setTimeout(function(){e.removeData(t.target,t.type+"DefaultPrevented")},30)),r.apply(this,arguments)},t.isDefaultPrevented=function(){return!!(n.apply(this,arguments)||e.data(t.target,t.type+"DefaultPrevented")||!1)},t._isPolyfilled=!0}};if(!n.formvalidation||i.bustedValidity)o();else{r.capturingEvents(["input"]),r.capturingEvents(["invalid"],!0);if(window.opera||window.testGoodWithFix)s.appendTo("head"),o(),i.validationMessage=!u.prop("validationMessage"),r.reTest(["form-native-extend","form-message"]),s.remove(),e(function(){a(function(){var t=function(e){e.preventDefault()};["form","input","textarea","select"].forEach(function(n){var i=r.defineNodeNameProperty(n,"checkValidity",{prop:{value:function(){r.fromSubmit||e(this).on("invalid.checkvalidity",t),r.fromCheckValidity=!0;var n=i.prop._supvalue.apply(this,arguments);return r.fromSubmit||e(this).unbind("invalid.checkvalidity",t),r.fromCheckValidity=!1,n}}})})})});t&&!r.bugs.bustedValidity&&function(){var t=/^(?:textarea|input)$/i,n=!1;document.addEventListener("contextmenu",function(e){t.test(e.target.nodeName||"")&&(n=e.target.form)&&setTimeout(function(){n=!1},1)},!1),e(window).on("invalid",function(e){e.originalEvent&&n&&n==e.target.form&&(e.wrongWebkitInvalid=!0,e.stopImmediatePropagation())})}()}e.webshims.register("form-core",function(e,r,i,s,o,u){var a={checkbox:1,radio:1},f=e([]),l=r.bugs,c=function(t){t=e(t);var n,r,i=f;return t[0].type=="radio"&&(r=t.prop("form"),n=t[0].name,n?r?i=e(r[n]):i=e(s.getElementsByName(n)).filter(function(){return!e.prop(this,"form")}):i=t,i=i.filter('[type="radio"]')),i},h=r.getContentValidationMessage=function(t,n,r){var i=e(t).data("errormessage")||t.getAttribute("x-moz-errormessage")||"";return r&&i[r]&&(i=i[r]),typeof i=="object"&&(n=n||e.prop(t,"validity")||{valid:1},n.valid||e.each(n,function(e,t){if(t&&e!="valid"&&i[e])return i=i[e],!1})),typeof i=="object"&&(i=i.defaultMessage),i||""},p={number:1,range:1,date:1},d=function(t){var n=!1;return e(e.prop(t,"elements")).each(function(){n=e(this).is(":invalid");if(n)return!1}),n};e.extend(e.expr[":"],{"valid-element":function(t){return e.nodeName(t,"form")?!d(t):!!e.prop(t,"willValidate")&&!!m(t)},"invalid-element":function(t){return e.nodeName(t,"form")?d(t):!!e.prop(t,"willValidate")&&!m(t)},"required-element":function(t){return!!e.prop(t,"willValidate")&&!!e.prop(t,"required")},"user-error":function(t){return e.prop(t,"willValidate")&&e(t).hasClass("user-error")},"optional-element":function(t){return!!e.prop(t,"willValidate")&&e.prop(t,"required")===!1},"in-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!!(n&&!n.rangeOverflow&&!n.rangeUnderflow)},"out-of-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!(!n||!n.rangeOverflow&&!n.rangeUnderflow)}}),["valid","invalid","required","optional"].forEach(function(t){e.expr[":"][t]=e.expr.filters[t+"-element"]}),e.expr[":"].focus=function(e){try{var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())}catch(n){}return!1};var v=e.event.customEvent||{},m=function(t){return(e.prop(t,"validity")||{valid:1}).valid};(l.bustedValidity||l.findRequired)&&function(){var t=e.find,r=e.find.matchesSelector,i=/(\:valid|\:invalid|\:optional|\:required|\:in-range|\:out-of-range)(?=[\s\[\~\.\+\>\:\#*]|$)/ig,o=function(e){return e+"-element"};e.find=function(){var e=Array.prototype.slice,n=function(n){var r=arguments;return r=e.call(r,1,r.length),r.unshift(n.replace(i,o)),t.apply(this,r)};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}();if(!n.prefixed||n.prefixed("matchesSelector",s.documentElement))e.find.matchesSelector=function(e,t){return t=t.replace(i,o),r.call(this,e,t)}}();var g=e.prop,y={selectedIndex:1,value:1,checked:1,disabled:1,readonly:1};e.prop=function(t,n,r){var i=g.apply(this,arguments);return t&&"form"in t&&y[n]&&r!==o&&e(t).hasClass(E)&&m(t)&&(e(t).getShadowElement().removeClass(E),n=="checked"&&r&&c(t).not(t).removeClass(E).removeAttr("aria-invalid")),i};var b=function(t,n){var r;return e.each(t,function(t,i){if(i)return r=t=="customError"?e.prop(n,"validationMessage"):t,!1}),r},w=function(e){var t;try{t=s.activeElement.name===e}catch(n){}return t},E="user-error",S="user-success",x=function(t){var n,r;if(!t.target)return;n=e(t.target).getNativeElement()[0];if(n.type=="submit"||!e.prop(n,"willValidate"))return;r=e.data(n,"webshimsswitchvalidityclass");var i=function(){if(t.type=="focusout"&&n.type=="radio"&&w(n.name))return;var r=e.prop(n,"validity"),i=e(n).getShadowElement(),s,o,u,f,l;e(n).trigger("refreshCustomValidityRules"),r.valid?i.hasClass(S)||(s=S,o=E,f="changedvaliditystate",u="changedvalid",a[n.type]&&n.checked&&c(n).not(n).removeClass(o).addClass(s).removeAttr("aria-invalid"),e.removeData(n,"webshimsinvalidcause")):(l=b(r,n),e.data(n,"webshimsinvalidcause")!=l&&(e.data(n,"webshimsinvalidcause",l),f="changedvaliditystate"),i.hasClass(E)||(s=E,o=S,a[n.type]&&!n.checked&&c(n).not(n).removeClass(o).addClass(s),u="changedinvalid")),s&&(i.addClass(s).removeClass(o),setTimeout(function(){e(n).trigger(u)},0)),f&&setTimeout(function(){e(n).trigger(f)},0),e.removeData(t.target,"webshimsswitchvalidityclass")};r&&clearTimeout(r),t.type=="refreshvalidityui"?i():e.data(n,"webshimsswitchvalidityclass",setTimeout(i,9))};e(s).on(u.validityUIEvents||"focusout change refreshvalidityui",x),v.changedvaliditystate=!0,v.refreshCustomValidityRules=!0,v.changedvalid=!0,v.changedinvalid=!0,v.refreshvalidityui=!0,r.triggerInlineForm=function(t,n){e(t).trigger(n)},r.modules["form-core"].getGroupElements=c;var T=function(){r.scrollRoot=t||s.compatMode=="BackCompat"?e(s.body):e(s.documentElement)};T(),r.ready("DOM",T),r.getRelOffset=function(t,n){t=e(t);var r=e(n).offset(),i;return e.swap(e(t)[0],{visibility:"hidden",display:"inline-block",left:0,top:0},function(){i=t.offset()}),r.top-=i.top,r.left-=i.left,r},r.wsPopover={_create:function(){this.options=e.extend({},r.cfg.wspopover,this.options),this.id=r.wsPopover.id++,this.eventns=".wsoverlay"+this.id,this.timers={},this.element=e('<div class="ws-popover" tabindex="-1"><div class="ws-po-outerbox"><div class="ws-po-arrow"><div class="ws-po-arrowbox" /></div><div class="ws-po-box" /></div></div>'),this.contentElement=e(".ws-po-box",this.element),this.lastElement=e([]),this.bindElement(),this.options.prepareFor&&this.prepareFor(e(this.options.prepareFor).getNativeElement(),e(this.options.prepareFor).getShadowElement()),this.element.data("wspopover",this)},options:{},content:function(e){this.contentElement.html(e)},bindElement:function(){var e=this,t=function(){e.stopBlur=!1};this.element.on({mousedown:function(n){e.stopBlur=!0,e.timers.stopBlur=setTimeout(t,9)}})},isInElement:function(t,n){return t==n||e.contains(t,n)},show:function(t){if(this.isVisible)return;this.isVisible=!0,t=e(t).getNativeElement();var n=this,r=e(t).getShadowElement();this.clear(),this.element.removeClass("ws-po-visible").css("display","none"),this.options.prepareFor||this.prepareFor(t,r),this.position(r),n.timers.show=setTimeout(function(){n.element.css("display",""),n.timers.show=setTimeout(function(){n.element.addClass("ws-po-visible")},9)},9),e(s).on("focusin"+this.eventns+" mousedown"+this.eventns,function(e){n.options.hideOnBlur&&!n.stopBlur&&!n.isInElement(n.lastElement[0]||s.body,e.target)&&!n.isInElement(n.element[0],e.target)&&n.hide()}),e(i).on("resize"+this.eventns+" pospopover"+this.eventns,function(){clearTimeout(n.timers.repos),n.timers.repos=setTimeout(function(){n.position(r)},900)})},prepareFor:function(t,n){var r,i=e.extend({},this.options,e(t.prop("form")||[]).data("wspopover")||{},t.data("wspopover")),s=this;this.lastElement=e(t).getShadowFocusElement(),i.appendTo=="element"?this.element.insertAfter(t):this.element.appendTo(i.appendTo),this.element.attr({"data-class":t.prop("className"),"data-id":t.prop("id")}),this.element.css({width:i.constrainWidth?n.outerWidth():""}),i.hideOnBlur&&(r=function(e){s.stopBlur?e.stopImmediatePropagation():s.hide()},this.options.prepareFor?s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r).data("preparedpopover",s):s.timers.bindBlur=setTimeout(function(){s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r)},10)),this.prepared||(this.options.prepareFor&&this.element.css("display","none"),e.fn.bgIframe&&this.element.bgIframe()),this.prepared=!0},clear:function(){e(i).off(this.eventns),e(s).off(this.eventns),this.options.prepareFor||this.lastElement.off(this.eventns),this.stopBlur=!1,e.each(this.timers,function(e,t){clearTimeout(t)})},hide:function(){if(!this.isVisible)return;this.isVisible=!1;var t=this,n=function(){t.element.css("display","none").attr({"data-id":"","data-class":"",hidden:"hidden"}),clearTimeout(t.timers.forcehide)};this.clear(),this.element.removeClass("ws-po-visible"),e(i).on("resize"+this.eventns,n),t.timers.forcehide=setTimeout(n,999)},position:function(e){var t=r.getRelOffset(this.element.css({marginTop:0,marginLeft:0,marginRight:0,marginBottom:0}).removeAttr("hidden"),e);t.top+=e.outerHeight(),this.element.css({marginTop:"",marginLeft:"",marginRight:"",marginBottom:""}).css(t)}},r.wsPopover.id=0,r.validityAlert=function(){var t=!1,n=r.objectCreate(r.wsPopover,{},u.messagePopover),s=n.hide.bind(n);return n.element.addClass("validity-alert").attr({role:"alert"}),e.extend(n,{hideDelay:5e3,showFor:function(t,n,r,i){t=e(t).getNativeElement(),this.clear(),this.hide(),i||(this.getMessage(t,n),this.show(t),this.hideDelay&&(this.timers.delayedHide=setTimeout(s,this.hideDelay))),r||this.setFocus(t)},setFocus:function(t){var n=e(t).getShadowFocusElement(),s=r.scrollRoot.scrollTop(),o=n.offset().top-30,u;s>o&&(r.scrollRoot.animate({scrollTop:o-5},{queue:!1,duration:Math.max(Math.min(600,(s-o)*1.5),80)}),u=!0);try{n[0].focus()}catch(a){}u&&(r.scrollRoot.scrollTop(s),setTimeout(function(){r.scrollRoot.scrollTop(s)},0)),e(i).triggerHandler("pospopover"+this.eventns)},getMessage:function(e,t){t||(t=h(e[0])||e.prop("customValidationMessage")||e.prop("validationMessage")),t?n.contentElement.text(t):this.hide()}}),n}(),function(){var t,n=[],r,i;e(s).on("invalid",function(i){if(i.wrongWebkitInvalid)return;var o=e(i.target),u=o.getShadowElement();u.hasClass(E)||(u.addClass(E).removeClass(S),setTimeout(function(){e(i.target).trigger("changedinvalid").trigger("changedvaliditystate")},0));if(!t){t=e.Event("firstinvalid"),t.isInvalidUIPrevented=i.isDefaultPrevented;var a=e.Event("firstinvalidsystem");e(s).triggerHandler(a,{element:i.target,form:i.target.form,isInvalidUIPrevented:i.isDefaultPrevented}),o.trigger(t)}t&&t.isDefaultPrevented()&&i.preventDefault(),n.push(i.target),i.extraData="fix",clearTimeout(r),r=setTimeout(function(){var r={type:"lastinvalid",cancelable:!1,invalidlist:e(n)};t=!1,n=[],e(i.target).trigger(r,r)},9),o=null,u=null})}(),e.fn.getErrorMessage=function(){var t="",n=this[0];return n&&(t=h(n)||e.prop(n,"customValidationMessage")||e.prop(n,"validationMessage")),t},u.replaceValidationUI&&r.ready("DOM forms",function(){e(s).on("firstinvalid",function(t){t.isInvalidUIPrevented()||(t.preventDefault(),e.webshims.validityAlert.showFor(t.target))})})})})(jQuery),function(e,t,n){"use strict";var r=t.audio&&t.video,i=!1,s=n.bugs,o=function(){n.ready(a,function(){n.mediaelement.createSWF||(n.mediaelement.loadSwf=!0,n.reTest([a],r))})},u=n.cfg.mediaelement,a=u&&u.player=="jwplayer"?"mediaelement-swf":"mediaelement-jaris",f;if(!u){n.error("mediaelement wasn't implemented but loaded");return}if(r){var l=document.createElement("video");t.videoBuffered="buffered"in l,i="loop"in l,n.capturingEvents(["play","playing","waiting","paused","ended","durationchange","loadedmetadata","canplay","volumechange"]),t.videoBuffered||(n.addPolyfill("mediaelement-native-fix",{f:"mediaelement",test:t.videoBuffered,d:["dom-support"]}),n.reTest("mediaelement-native-fix"))}if(r&&!u.preferFlash){var c=function(t){var r=t.target.parentNode;!u.preferFlash&&(e(t.target).is("audio, video")||r&&e("source:last",r)[0]==t.target)&&n.ready("DOM mediaelement",function(){f&&o(),n.ready("WINDOWLOAD "+a,function(){setTimeout(function(){f&&!u.preferFlash&&n.mediaelement.createSWF&&!e(t.target).closest("audio, video").is(".nonnative-api-active")?(u.preferFlash=!0,document.removeEventListener("error",c,!0),e("audio, video").mediaLoad(),n.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+t.target.src)):f||document.removeEventListener("error",c,!0)},20)})})};document.addEventListener("error",c,!0),e("audio, video").each(function(){this.error&&c({target:this})})}t.track&&!s.track&&function(){s.track||(s.track=typeof e("<track />")[0].readyState!="number");if(!s.track)try{new TextTrackCue(2,3,"")}catch(t){s.track=!0}var r=n.cfg.track,i=function(t){e(t.target).filter("track").each(o)},o=function(){if(s.track||!r.override&&e.prop(this,"readyState")==3)r.override=!0,n.reTest("track"),document.removeEventListener("error",i,!0),this&&e.nodeName(this,"track")?n.error("track support was overwritten. Please check your vtt including your vtt mime-type"):n.info("track support was overwritten. due to bad browser support")},u=function(){document.addEventListener("error",i,!0),s.track?o():e("track").each(o)};r.override||(n.isReady("track")?u():e(u))}(),n.register("mediaelement-core",function(e,n,l,c,h){f=swfmini.hasFlashPlayerVersion("9.0.115"),e("html").addClass(f?"swf":"no-swf");var p=n.mediaelement;p.parseRtmp=function(e){var t=e.src.split("://"),r=t[1].split("/"),i,s,o;e.server=t[0]+"://"+r[0]+"/",e.streamId=[];for(i=1,s=r.length;i<s;i++)!o&&r[i].indexOf(":")!==-1&&(r[i]=r[i].split(":")[1],o=!0),o?e.streamId.push(r[i]):e.server+=r[i]+"/";e.streamId.length||n.error("Could not parse rtmp url"),e.streamId=e.streamId.join("/")};var d=function(t,n){t=e(t);var r={src:t.attr("src")||"",elem:t,srcProp:t.prop("src")},i;if(!r.src)return r;i=t.attr("data-server"),i!=null&&(r.server=i),i=t.attr("type"),i?(r.type=i,r.container=e.trim(i.split(";")[0])):(n||(n=t[0].nodeName.toLowerCase(),n=="source"&&(n=(t.closest("video, audio")[0]||{nodeName:"video"}).nodeName.toLowerCase())),r.server?(r.type=n+"/rtmp",r.container=n+"/rtmp"):(i=p.getTypeForSrc(r.src,n,r),i&&(r.type=i,r.container=i))),i=t.attr("media"),i&&(r.media=i);if(r.type=="audio/rtmp"||r.type=="video/rtmp")r.server?r.streamId=r.src:p.parseRtmp(r);return r},v=!f&&"postMessage"in l&&r,m=function(){if(m.loaded)return;m.loaded=!0,e(function(){n.loader.loadList(["track-ui"])})},g=function(){var t;return function(){if(t||!v)return;t=!0,n.loader.loadScript("https://www.youtube.com/player_api"),e(function(){n.polyfill("mediaelement-yt")})}}(),y=function(){f?o():g()};n.addPolyfill("mediaelement-yt",{test:!v,d:["dom-support"]}),p.mimeTypes={audio:{"audio/ogg":["ogg","oga","ogm"],'audio/ogg;codecs="opus"':"opus","audio/mpeg":["mp2","mp3","mpga","mpega"],"audio/mp4":["mp4","mpg4","m4r","m4a","m4p","m4b","aac"],"audio/wav":["wav"],"audio/3gpp":["3gp","3gpp"],"audio/webm":["webm"],"audio/fla":["flv","f4a","fla"],"application/x-mpegURL":["m3u8","m3u"]},video:{"video/ogg":["ogg","ogv","ogm"],"video/mpeg":["mpg","mpeg","mpe"],"video/mp4":["mp4","mpg4","m4v"],"video/quicktime":["mov","qt"],"video/x-msvideo":["avi"],"video/x-ms-asf":["asf","asx"],"video/flv":["flv","f4v"],"video/3gpp":["3gp","3gpp"],"video/webm":["webm"],"application/x-mpegURL":["m3u8","m3u"],"video/MP2T":["ts"]}},p.mimeTypes.source=e.extend({},p.mimeTypes.audio,p.mimeTypes.video),p.getTypeForSrc=function(t,n,r){if(t.indexOf("youtube.com/watch?")!=-1||t.indexOf("youtube.com/v/")!=-1)return"video/youtube";if(t.indexOf("rtmp")===0)return n+"/rtmp";t=t.split("?")[0].split("."),t=t[t.length-1];var i;return e.each(p.mimeTypes[n],function(e,n){if(n.indexOf(t)!==-1)return i=e,!1}),i},p.srces=function(t,n){t=e(t);if(!n){n=[];var r=t[0].nodeName.toLowerCase(),i=d(t,r);return i.src?n.push(i):e("source",t).each(function(){i=d(this,r),i.src&&n.push(i)}),n}t.removeAttr("src").removeAttr("type").find("source").remove(),e.isArray(n)||(n=[n]),n.forEach(function(e){var n=c.createElement("source");typeof e=="string"&&(e={src:e}),n.setAttribute("src",e.src),e.type&&n.setAttribute("type",e.type),e.media&&n.setAttribute("media",e.media),t.append(n)})},e.fn.loadMediaSrc=function(t,n){return this.each(function(){n!==h&&(e(this).removeAttr("poster"),n&&e.attr(this,"poster",n)),p.srces(this,t),e(this).mediaLoad()})},p.swfMimeTypes=["video/3gpp","video/x-msvideo","video/quicktime","video/x-m4v","video/mp4","video/m4p","video/x-flv","video/flv","audio/mpeg","audio/aac","audio/mp4","audio/x-m4a","audio/m4a","audio/mp3","audio/x-fla","audio/fla","youtube/flv","jwplayer/jwplayer","video/youtube","video/rtmp","audio/rtmp"],p.canThirdPlaySrces=function(t,n){var r="";if(f||v)t=e(t),n=n||p.srces(t),e.each(n,function(e,t){if(t.container&&t.src&&(f&&p.swfMimeTypes.indexOf(t.container)!=-1||v&&t.container=="video/youtube"))return r=t,!1});return r};var b={};p.canNativePlaySrces=function(t,n){var i="";if(r){t=e(t);var s=(t[0].nodeName||"").toLowerCase(),o=(b[s]||{prop:{_supvalue:!1}}).prop._supvalue||t[0].canPlayType;if(!o)return i;n=n||p.srces(t),e.each(n,function(e,n){if(n.type&&o.call(t[0],n.type))return i=n,!1})}return i},p.setError=function(t,r){r||(r="can't play sources"),e(t).pause().data("mediaerror",r),n.warn("mediaelementError: "+r),setTimeout(function(){e(t).data("mediaerror")&&e(t).trigger("mediaerror")},1)};var w=function(){var e;return function(t,r,i){e||m(),n.ready(f?a:"mediaelement-yt",function(){p.createSWF?p.createSWF(t,r,i):e||(e=!0,y(),w(t,r,i))}),!e&&v&&!p.createSWF&&g()}}(),E=function(e,t,n,r,i){var s;n||n!==!1&&t&&t.isActive=="third"?(s=p.canThirdPlaySrces(e,r),s?w(e,s,t):i?p.setError(e,!1):E(e,t,!1,r,!0)):(s=p.canNativePlaySrces(e,r),s?t&&t.isActive=="third"&&p.setActive(e,"html5",t):i?(p.setError(e,!1),t&&t.isActive=="third"&&p.setActive(e,"html5",t)):E(e,t,!0,r,!0))},S=/^(?:embed|object|datalist)$/i,x=function(t,r){var i=n.data(t,"mediaelementBase")||n.data(t,"mediaelementBase",{}),s=p.srces(t),o=t.parentNode;clearTimeout(i.loadTimer),e.data(t,"mediaerror",!1);if(!s.length||!o||o.nodeType!=1||S.test(o.nodeName||""))return;r=r||n.data(t,"mediaelement"),E(t,r,u.preferFlash||h,s)};e(c).on("ended",function(t){var r=n.data(t.target,"mediaelement");if(i&&(!r||r.isActive=="html5")&&!e.prop(t.target,"loop"))return;setTimeout(function(){if(e.prop(t.target,"paused")||!e.prop(t.target,"loop"))return;e(t.target).prop("currentTime",0).play()},1)}),n.ready("dom-support",function(){i||n.defineNodeNamesBooleanProperty(["audio","video"],"loop"),["audio","video"].forEach(function(t){var i=n.defineNodeNameProperty(t,"load",{prop:{value:function(){var e=n.data(this,"mediaelement");x(this,e),r&&(!e||e.isActive=="html5")&&i.prop._supvalue&&i.prop._supvalue.apply(this,arguments)}}});b[t]=n.defineNodeNameProperty(t,"canPlayType",{prop:{value:function(n){var i="";return r&&b[t].prop._supvalue&&(i=b[t].prop._supvalue.call(this,n),i=="no"&&(i="")),!i&&f&&(n=e.trim((n||"").split(";")[0]),p.swfMimeTypes.indexOf(n)!=-1&&(i="maybe")),i}}})}),n.onNodeNamesPropertyModify(["audio","video"],["src","poster"],{set:function(){var e=this,t=n.data(e,"mediaelementBase")||n.data(e,"mediaelementBase",{});clearTimeout(t.loadTimer),t.loadTimer=setTimeout(function(){x(e),e=null},9)}})});var T=function(){var t=function(){x(this);if(r){var t,n,i=this,s=function(){var t=e.prop(i,"buffered");if(!t)return;var n="";for(var r=0,s=t.length;r<s;r++)n+=t.end(r);return n},o=function(){var t=s();t!=n&&(n=t,e(i).triggerHandler("progress"))};e(this).on({"play loadstart progress":function(e){e.type=="progress"&&(n=s()),clearTimeout(t),t=setTimeout(o,999)},"emptied stalled mediaerror abort suspend":function(e){e.type=="emptied"&&(n=!1),clearTimeout(t)}})}},i=!1;n.ready("dom-support",function(){i=!0,n.addReady(function(n,r){var i=e("video, audio",n).add(r.filter("video, audio")).each(t);!m.loaded&&e("track",i).length&&m(),i=null})}),r&&!i&&n.addReady(function(t,n){i||e("video, audio",t).add(n.filter("video, audio")).each(function(){if(!p.canNativePlaySrces(this)||!m.loaded&&e("track",this).length)return y(),i=!0,!1})})};t.track&&!s.track&&n.defineProperty(TextTrack.prototype,"shimActiveCues",{get:function(){return this._shimActiveCues||this.activeCues}}),r?(n.isReady("mediaelement-core",!0),T(),n.ready("WINDOWLOAD mediaelement",y)):n.ready(a,T),n.ready("WINDOWLOAD mediaelement",m)})}(jQuery,Modernizr,jQuery.webshims);
+var swfmini=function(){function S(){if(g)return;try{var e=u.getElementsByTagName("body")[0].appendChild(H("span"));e.parentNode.removeChild(e)}catch(t){return}g=!0;var n=l.length;for(var r=0;r<n;r++)l[r]()}function x(e){g?e():l[l.length]=e}function T(e){}function N(){f&&C()}function C(){var n=u.getElementsByTagName("body")[0],r=H(t);r.setAttribute("type",s);var i=n.appendChild(r);if(i){var o=0;(function(){if(typeof i.GetVariable!=e){var t=i.GetVariable("$version");t&&(t=t.split(" ")[1].split(","),E.pv=[parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10)])}else if(o<10){o++,setTimeout(arguments.callee,10);return}n.removeChild(r),i=null})()}}function k(n){var r=null,i=P(n);if(i&&i.nodeName=="OBJECT")if(typeof i.SetVariable!=e)r=i;else{var s=i.getElementsByTagName(t)[0];s&&(r=s)}return r}function L(e){if(E.ie&&E.win&&e.readyState!=4){var t=H("div");e.parentNode.insertBefore(t,e),t.parentNode.replaceChild(A(e),t),e.style.display="none",function(){e.readyState==4?e.parentNode.removeChild(e):setTimeout(arguments.callee,10)}()}else e.parentNode.replaceChild(A(e),e)}function A(e){var n=H("div");if(E.win&&E.ie)n.innerHTML=e.innerHTML;else{var r=e.getElementsByTagName(t)[0];if(r){var i=r.childNodes;if(i){var s=i.length;for(var o=0;o<s;o++)(i[o].nodeType!=1||i[o].nodeName!="PARAM")&&i[o].nodeType!=8&&n.appendChild(i[o].cloneNode(!0))}}}return n}function O(n,r,i){var o,u=P(i);if(E.wk&&E.wk<312)return o;if(u){typeof n.id==e&&(n.id=i);if(E.ie&&E.win){var a="";for(var f in n)n[f]!=Object.prototype[f]&&(f.toLowerCase()=="data"?r.movie=n[f]:f.toLowerCase()=="styleclass"?a+=' class="'+n[f]+'"':f.toLowerCase()!="classid"&&(a+=" "+f+'="'+n[f]+'"'));var l="";for(var h in r)r[h]!=Object.prototype[h]&&(l+='<param name="'+h+'" value="'+r[h]+'" />');u.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+a+">"+l+"</object>",c[c.length]=n.id,o=P(n.id)}else{var p=H(t);p.setAttribute("type",s);for(var d in n)n[d]!=Object.prototype[d]&&(d.toLowerCase()=="styleclass"?p.setAttribute("class",n[d]):d.toLowerCase()!="classid"&&p.setAttribute(d,n[d]));for(var v in r)r[v]!=Object.prototype[v]&&v.toLowerCase()!="movie"&&M(p,v,r[v]);u.parentNode.replaceChild(p,u),o=p}}return o}function M(e,t,n){var r=H("param");r.setAttribute("name",t),r.setAttribute("value",n),e.appendChild(r)}function _(e){var t=P(e);t&&t.nodeName=="OBJECT"&&(E.ie&&E.win?(t.style.display="none",function(){t.readyState==4?D(e):setTimeout(arguments.callee,10)}()):t.parentNode.removeChild(t))}function D(e){var t=P(e);if(t){for(var n in t)typeof t[n]=="function"&&(t[n]=null);t.parentNode.removeChild(t)}}function P(e){var t=null;try{t=u.getElementById(e)}catch(n){}return t}function H(e){return u.createElement(e)}function B(e,t,n){e.attachEvent(t,n),h[h.length]=[e,t,n]}function j(e){var t=E.pv,n=e.split(".");return n[0]=parseInt(n[0],10),n[1]=parseInt(n[1],10)||0,n[2]=parseInt(n[2],10)||0,t[0]>n[0]||t[0]==n[0]&&t[1]>n[1]||t[0]==n[0]&&t[1]==n[1]&&t[2]>=n[2]?!0:!1}function F(e,t){if(!w)return;var n,r=t?"visible":"hidden";g&&n&&P(e)&&(P(e).style.visibility=r)}function I(t){var n=/[\\\"<>\.;]/,r=n.exec(t)!=null;return r&&typeof encodeURIComponent!=e?encodeURIComponent(t):t}var e="undefined",t="object",n=jQuery.webshims,r="Shockwave Flash",i="ShockwaveFlash.ShockwaveFlash",s="application/x-shockwave-flash",o=window,u=document,a=navigator,f=!1,l=[N],c=[],h=[],p,d,v,m,g=!1,y,b,w=!0,E=function(){var n=typeof u.getElementById!=e&&typeof u.getElementsByTagName!=e&&typeof u.createElement!=e,l=a.userAgent.toLowerCase(),c=a.platform.toLowerCase(),h=c?/win/.test(c):/win/.test(l),p=c?/mac/.test(c):/mac/.test(l),d=/webkit/.test(l)?parseFloat(l.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):!1,v=!1,m=[0,0,0],g=null;if(typeof a.plugins!=e&&typeof a.plugins[r]==t)g=a.plugins[r].description,g&&(typeof a.mimeTypes==e||!a.mimeTypes[s]||!!a.mimeTypes[s].enabledPlugin)&&(f=!0,v=!1,g=g.replace(/^.*\s+(\S+\s+\S+$)/,"$1"),m[0]=parseInt(g.replace(/^(.*)\..*$/,"$1"),10),m[1]=parseInt(g.replace(/^.*\.(.*)\s.*$/,"$1"),10),m[2]=/[a-zA-Z]/.test(g)?parseInt(g.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0);else if(typeof o.ActiveXObject!=e)try{var y=new ActiveXObject(i);y&&(g=y.GetVariable("$version"),g&&(v=!0,g=g.split(" ")[1].split(","),m=[parseInt(g[0],10),parseInt(g[1],10),parseInt(g[2],10)]))}catch(b){}return{w3:n,pv:m,wk:d,ie:v,win:h,mac:p}}(),q=function(){E.ie&&E.win&&window.attachEvent&&window.attachEvent("onunload",function(){var e=h.length;for(var t=0;t<e;t++)h[t][0].detachEvent(h[t][1],h[t][2]);var n=c.length;for(var r=0;r<n;r++)_(c[r]);for(var i in E)E[i]=null;E=null;for(var s in swfmini)swfmini[s]=null;swfmini=null})}();return n.ready("DOM",S),{registerObject:function(){},getObjectById:function(e){if(E.w3)return k(e)},embedSWF:function(n,r,i,s,o,u,a,f,l,c){var h={success:!1,id:r};E.w3&&!(E.wk&&E.wk<312)&&n&&r&&i&&s&&o?(F(r,!1),x(function(){i+="",s+="";var u={};if(l&&typeof l===t)for(var p in l)u[p]=l[p];u.data=n,u.width=i,u.height=s;var d={};if(f&&typeof f===t)for(var v in f)d[v]=f[v];if(a&&typeof a===t)for(var m in a)typeof d.flashvars!=e?d.flashvars+="&"+m+"="+a[m]:d.flashvars=m+"="+a[m];if(j(o)){var g=O(u,d,r);u.id==r&&F(r,!0),h.success=!0,h.ref=g}else F(r,!0);c&&c(h)})):c&&c(h)},switchOffAutoHideShow:function(){w=!1},ua:E,getFlashPlayerVersion:function(){return{major:E.pv[0],minor:E.pv[1],release:E.pv[2]}},hasFlashPlayerVersion:j,createSWF:function(e,t,n){return E.w3?O(e,t,n):undefined},showExpressInstall:function(){},removeSWF:function(e){E.w3&&_(e)},createCSS:function(){},addDomLoadEvent:x,addLoadEvent:T,expressInstallCallback:function(){}}}();(function(e){"use strict";var t="webkitURL"in window,n=window.Modernizr,r=e.webshims,i=r.bugs,s=e('<form action="#" style="width: 1px; height: 1px; overflow: hidden;"><select name="b" required="" /><input required="" name="a" /></form>'),o=function(){if(s[0].querySelector)try{i.findRequired=!s[0].querySelector("select:required")}catch(e){i.findRequired=!1}},u=e("input",s).eq(0),a=function(e){r.loader.loadList(["dom-extend"]),r.ready("dom-extend",e)};i.findRequired=!1,i.validationMessage=!1,r.capturingEventPrevented=function(t){if(!t._isPolyfilled){var n=t.isDefaultPrevented,r=t.preventDefault;t.preventDefault=function(){return clearTimeout(e.data(t.target,t.type+"DefaultPrevented")),e.data(t.target,t.type+"DefaultPrevented",setTimeout(function(){e.removeData(t.target,t.type+"DefaultPrevented")},30)),r.apply(this,arguments)},t.isDefaultPrevented=function(){return!!(n.apply(this,arguments)||e.data(t.target,t.type+"DefaultPrevented")||!1)},t._isPolyfilled=!0}};if(!n.formvalidation||i.bustedValidity)o();else{r.capturingEvents(["input"]),r.capturingEvents(["invalid"],!0);if(window.opera||window.testGoodWithFix)s.appendTo("head"),o(),i.validationMessage=!u.prop("validationMessage"),r.reTest(["form-native-extend","form-message"]),s.remove(),e(function(){a(function(){var t=function(e){e.preventDefault()};["form","input","textarea","select"].forEach(function(n){var i=r.defineNodeNameProperty(n,"checkValidity",{prop:{value:function(){r.fromSubmit||e(this).on("invalid.checkvalidity",t),r.fromCheckValidity=!0;var n=i.prop._supvalue.apply(this,arguments);return r.fromSubmit||e(this).unbind("invalid.checkvalidity",t),r.fromCheckValidity=!1,n}}})})})});t&&!r.bugs.bustedValidity&&function(){var t=/^(?:textarea|input)$/i,n=!1;document.addEventListener("contextmenu",function(e){t.test(e.target.nodeName||"")&&(n=e.target.form)&&setTimeout(function(){n=!1},1)},!1),e(window).on("invalid",function(e){e.originalEvent&&n&&n==e.target.form&&(e.wrongWebkitInvalid=!0,e.stopImmediatePropagation())})}()}e.webshims.register("form-core",function(e,r,i,s,o,u){var a={checkbox:1,radio:1},f=e([]),l=r.bugs,c=function(t){t=e(t);var n,r,i=f;return t[0].type=="radio"&&(r=t.prop("form"),n=t[0].name,n?r?i=e(r[n]):i=e(s.getElementsByName(n)).filter(function(){return!e.prop(this,"form")}):i=t,i=i.filter('[type="radio"]')),i},h=r.getContentValidationMessage=function(t,n,r){var i=e(t).data("errormessage")||t.getAttribute("x-moz-errormessage")||"";return r&&i[r]&&(i=i[r]),typeof i=="object"&&(n=n||e.prop(t,"validity")||{valid:1},n.valid||e.each(n,function(e,t){if(t&&e!="valid"&&i[e])return i=i[e],!1})),typeof i=="object"&&(i=i.defaultMessage),i||""},p={number:1,range:1,date:1},d=function(t){var n=!1;return e(e.prop(t,"elements")).each(function(){n=e(this).is(":invalid");if(n)return!1}),n};e.extend(e.expr[":"],{"valid-element":function(t){return e.nodeName(t,"form")?!d(t):!!e.prop(t,"willValidate")&&!!m(t)},"invalid-element":function(t){return e.nodeName(t,"form")?d(t):!!e.prop(t,"willValidate")&&!m(t)},"required-element":function(t){return!!e.prop(t,"willValidate")&&!!e.prop(t,"required")},"user-error":function(t){return e.prop(t,"willValidate")&&e(t).hasClass("user-error")},"optional-element":function(t){return!!e.prop(t,"willValidate")&&e.prop(t,"required")===!1},"in-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!!(n&&!n.rangeOverflow&&!n.rangeUnderflow)},"out-of-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!(!n||!n.rangeOverflow&&!n.rangeUnderflow)}}),["valid","invalid","required","optional"].forEach(function(t){e.expr[":"][t]=e.expr.filters[t+"-element"]}),e.expr[":"].focus=function(e){try{var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())}catch(n){}return!1};var v=e.event.customEvent||{},m=function(t){return(e.prop(t,"validity")||{valid:1}).valid};(l.bustedValidity||l.findRequired)&&function(){var t=e.find,r=e.find.matchesSelector,i=/(\:valid|\:invalid|\:optional|\:required|\:in-range|\:out-of-range)(?=[\s\[\~\.\+\>\:\#*]|$)/ig,o=function(e){return e+"-element"};e.find=function(){var e=Array.prototype.slice,n=function(n){var r=arguments;return r=e.call(r,1,r.length),r.unshift(n.replace(i,o)),t.apply(this,r)};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}();if(!n.prefixed||n.prefixed("matchesSelector",s.documentElement))e.find.matchesSelector=function(e,t){return t=t.replace(i,o),r.call(this,e,t)}}();var g=e.prop,y={selectedIndex:1,value:1,checked:1,disabled:1,readonly:1};e.prop=function(t,n,r){var i=g.apply(this,arguments);return t&&"form"in t&&y[n]&&r!==o&&e(t).hasClass(E)&&m(t)&&(e(t).getShadowElement().removeClass(E),n=="checked"&&r&&c(t).not(t).removeClass(E).removeAttr("aria-invalid")),i};var b=function(t,n){var r;return e.each(t,function(t,i){if(i)return r=t=="customError"?e.prop(n,"validationMessage"):t,!1}),r},w=function(e){var t;try{t=s.activeElement.name===e}catch(n){}return t},E="user-error",S="user-success",x=function(t){var n,r;if(!t.target)return;n=e(t.target).getNativeElement()[0];if(n.type=="submit"||!e.prop(n,"willValidate"))return;r=e.data(n,"webshimsswitchvalidityclass");var i=function(){if(t.type=="focusout"&&n.type=="radio"&&w(n.name))return;var r=e.prop(n,"validity"),i=e(n).getShadowElement(),s,o,u,f,l;e(n).trigger("refreshCustomValidityRules"),r.valid?i.hasClass(S)||(s=S,o=E,f="changedvaliditystate",u="changedvalid",a[n.type]&&n.checked&&c(n).not(n).removeClass(o).addClass(s).removeAttr("aria-invalid"),e.removeData(n,"webshimsinvalidcause")):(l=b(r,n),e.data(n,"webshimsinvalidcause")!=l&&(e.data(n,"webshimsinvalidcause",l),f="changedvaliditystate"),i.hasClass(E)||(s=E,o=S,a[n.type]&&!n.checked&&c(n).not(n).removeClass(o).addClass(s),u="changedinvalid")),s&&(i.addClass(s).removeClass(o),setTimeout(function(){e(n).trigger(u)},0)),f&&setTimeout(function(){e(n).trigger(f)},0),e.removeData(t.target,"webshimsswitchvalidityclass")};r&&clearTimeout(r),t.type=="refreshvalidityui"?i():e.data(n,"webshimsswitchvalidityclass",setTimeout(i,9))};e(s).on(u.validityUIEvents||"focusout change refreshvalidityui",x),v.changedvaliditystate=!0,v.refreshCustomValidityRules=!0,v.changedvalid=!0,v.changedinvalid=!0,v.refreshvalidityui=!0,r.triggerInlineForm=function(t,n){e(t).trigger(n)},r.modules["form-core"].getGroupElements=c;var T=function(){r.scrollRoot=t||s.compatMode=="BackCompat"?e(s.body):e(s.documentElement)};T(),r.ready("DOM",T),r.getRelOffset=function(t,n){t=e(t);var r=e(n).offset(),i;return e.swap(e(t)[0],{visibility:"hidden",display:"inline-block",left:0,top:0},function(){i=t.offset()}),r.top-=i.top,r.left-=i.left,r},r.wsPopover={_create:function(){this.options=e.extend({},r.cfg.wspopover,this.options),this.id=r.wsPopover.id++,this.eventns=".wsoverlay"+this.id,this.timers={},this.element=e('<div class="ws-popover" tabindex="-1"><div class="ws-po-outerbox"><div class="ws-po-arrow"><div class="ws-po-arrowbox" /></div><div class="ws-po-box" /></div></div>'),this.contentElement=e(".ws-po-box",this.element),this.lastElement=e([]),this.bindElement(),this.options.prepareFor&&this.prepareFor(e(this.options.prepareFor).getNativeElement(),e(this.options.prepareFor).getShadowElement()),this.element.data("wspopover",this)},options:{},content:function(e){this.contentElement.html(e)},bindElement:function(){var e=this,t=function(){e.stopBlur=!1};this.element.on({mousedown:function(n){e.stopBlur=!0,e.timers.stopBlur=setTimeout(t,9)}})},isInElement:function(t,n){return t==n||e.contains(t,n)},show:function(t){if(this.isVisible)return;this.isVisible=!0,t=e(t).getNativeElement();var n=this,r=e(t).getShadowElement();this.clear(),this.element.removeClass("ws-po-visible").css("display","none"),this.options.prepareFor||this.prepareFor(t,r),this.position(r),n.timers.show=setTimeout(function(){n.element.css("display",""),n.timers.show=setTimeout(function(){n.element.addClass("ws-po-visible")},9)},9),e(s).on("focusin"+this.eventns+" mousedown"+this.eventns,function(e){n.options.hideOnBlur&&!n.stopBlur&&!n.isInElement(n.lastElement[0]||s.body,e.target)&&!n.isInElement(n.element[0],e.target)&&n.hide()}),e(i).on("resize"+this.eventns+" pospopover"+this.eventns,function(){clearTimeout(n.timers.repos),n.timers.repos=setTimeout(function(){n.position(r)},900)})},prepareFor:function(t,n){var r,i=e.extend({},this.options,e(t.prop("form")||[]).data("wspopover")||{},t.data("wspopover")),s=this;this.lastElement=e(t).getShadowFocusElement(),i.appendTo=="element"?this.element.insertAfter(t):this.element.appendTo(i.appendTo),this.element.attr({"data-class":t.prop("className"),"data-id":t.prop("id")}),this.element.css({width:i.constrainWidth?n.outerWidth():""}),i.hideOnBlur&&(r=function(e){s.stopBlur?e.stopImmediatePropagation():s.hide()},this.options.prepareFor?s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r).data("preparedpopover",s):s.timers.bindBlur=setTimeout(function(){s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r)},10)),this.prepared||(this.options.prepareFor&&this.element.css("display","none"),e.fn.bgIframe&&this.element.bgIframe()),this.prepared=!0},clear:function(){e(i).off(this.eventns),e(s).off(this.eventns),this.options.prepareFor||this.lastElement.off(this.eventns),this.stopBlur=!1,e.each(this.timers,function(e,t){clearTimeout(t)})},hide:function(){if(!this.isVisible)return;this.isVisible=!1;var t=this,n=function(){t.element.css("display","none").attr({"data-id":"","data-class":"",hidden:"hidden"}),clearTimeout(t.timers.forcehide)};this.clear(),this.element.removeClass("ws-po-visible"),e(i).on("resize"+this.eventns,n),t.timers.forcehide=setTimeout(n,999)},position:function(e){var t=r.getRelOffset(this.element.css({marginTop:0,marginLeft:0,marginRight:0,marginBottom:0}).removeAttr("hidden"),e);t.top+=e.outerHeight(),this.element.css({marginTop:"",marginLeft:"",marginRight:"",marginBottom:""}).css(t)}},r.wsPopover.id=0,r.validityAlert=function(){var t=!1,n=r.objectCreate(r.wsPopover,{},u.messagePopover),s=n.hide.bind(n);return n.element.addClass("validity-alert").attr({role:"alert"}),e.extend(n,{hideDelay:5e3,showFor:function(t,n,r,i){t=e(t).getNativeElement(),this.clear(),this.hide(),i||(this.getMessage(t,n),this.show(t),this.hideDelay&&(this.timers.delayedHide=setTimeout(s,this.hideDelay))),r||this.setFocus(t)},setFocus:function(t){var n=e(t).getShadowFocusElement(),s=r.scrollRoot.scrollTop(),o=n.offset().top-30,u;s>o&&(r.scrollRoot.animate({scrollTop:o-5},{queue:!1,duration:Math.max(Math.min(600,(s-o)*1.5),80)}),u=!0);try{n[0].focus()}catch(a){}u&&(r.scrollRoot.scrollTop(s),setTimeout(function(){r.scrollRoot.scrollTop(s)},0)),e(i).triggerHandler("pospopover"+this.eventns)},getMessage:function(e,t){t||(t=h(e[0])||e.prop("customValidationMessage")||e.prop("validationMessage")),t?n.contentElement.text(t):this.hide()}}),n}(),function(){var t,n=[],r,i;e(s).on("invalid",function(i){if(i.wrongWebkitInvalid)return;var o=e(i.target),u=o.getShadowElement();u.hasClass(E)||(u.addClass(E).removeClass(S),setTimeout(function(){e(i.target).trigger("changedinvalid").trigger("changedvaliditystate")},0));if(!t){t=e.Event("firstinvalid"),t.isInvalidUIPrevented=i.isDefaultPrevented;var a=e.Event("firstinvalidsystem");e(s).triggerHandler(a,{element:i.target,form:i.target.form,isInvalidUIPrevented:i.isDefaultPrevented}),o.trigger(t)}t&&t.isDefaultPrevented()&&i.preventDefault(),n.push(i.target),i.extraData="fix",clearTimeout(r),r=setTimeout(function(){var r={type:"lastinvalid",cancelable:!1,invalidlist:e(n)};t=!1,n=[],e(i.target).trigger(r,r)},9),o=null,u=null})}(),e.fn.getErrorMessage=function(){var t="",n=this[0];return n&&(t=h(n)||e.prop(n,"customValidationMessage")||e.prop(n,"validationMessage")),t},u.replaceValidationUI&&r.ready("DOM forms",function(){e(s).on("firstinvalid",function(t){t.isInvalidUIPrevented()||(t.preventDefault(),e.webshims.validityAlert.showFor(t.target))})})})})(jQuery),function(e,t,n){"use strict";var r=t.audio&&t.video,i=!1,s=n.bugs,o=function(){n.ready(a,function(){n.mediaelement.createSWF||(n.mediaelement.loadSwf=!0,n.reTest([a],r))})},u=n.cfg.mediaelement,a=u&&u.player=="jwplayer"?"mediaelement-swf":"mediaelement-jaris",f;if(!u){n.error("mediaelement wasn't implemented but loaded");return}if(r){var l=document.createElement("video");t.videoBuffered="buffered"in l,i="loop"in l,n.capturingEvents(["play","playing","waiting","paused","ended","durationchange","loadedmetadata","canplay","volumechange"]),t.videoBuffered||(n.addPolyfill("mediaelement-native-fix",{f:"mediaelement",test:t.videoBuffered,d:["dom-support"]}),n.reTest("mediaelement-native-fix"))}if(r&&!u.preferFlash){var c={1:1,2:1},h=function(t){var r,i=t.target.parentNode;!u.preferFlash&&(e(t.target).is("audio, video")||i&&e("source:last",i)[0]==t.target)&&(r=e(t.target).closest("audio, video"))&&!c[r.prop("error")]&&e(function(){f&&!u.preferFlash?(o(),n.ready("WINDOWLOAD "+a,function(){setTimeout(function(){!u.preferFlash&&n.mediaelement.createSWF&&!r.is(".nonnative-api-active")&&(u.preferFlash=!0,document.removeEventListener("error",h,!0),e("audio, video").mediaLoad(),n.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+t.target.src+" Mediaerror: "+r.prop("error")))},9)})):document.removeEventListener("error",h,!0)})};document.addEventListener("error",h,!0),e("audio, video").each(function(){var t=e.prop(this,"error");t&&!c[t]&&h({target:this})})}t.track&&!s.track&&function(){s.track||(s.track=typeof e("<track />")[0].readyState!="number");if(!s.track)try{new TextTrackCue(2,3,"")}catch(t){s.track=!0}var r=n.cfg.track,i=function(t){e(t.target).filter("track").each(o)},o=function(){if(s.track||!r.override&&e.prop(this,"readyState")==3)r.override=!0,n.reTest("track"),document.removeEventListener("error",i,!0),this&&e.nodeName(this,"track")?n.error("track support was overwritten. Please check your vtt including your vtt mime-type"):n.info("track support was overwritten. due to bad browser support")},u=function(){document.addEventListener("error",i,!0),s.track?o():e("track").each(o)};r.override||(n.isReady("track")?u():e(u))}(),n.register("mediaelement-core",function(e,n,l,c,h){f=swfmini.hasFlashPlayerVersion("9.0.115"),e("html").addClass(f?"swf":"no-swf");var p=n.mediaelement;p.parseRtmp=function(e){var t=e.src.split("://"),r=t[1].split("/"),i,s,o;e.server=t[0]+"://"+r[0]+"/",e.streamId=[];for(i=1,s=r.length;i<s;i++)!o&&r[i].indexOf(":")!==-1&&(r[i]=r[i].split(":")[1],o=!0),o?e.streamId.push(r[i]):e.server+=r[i]+"/";e.streamId.length||n.error("Could not parse rtmp url"),e.streamId=e.streamId.join("/")};var d=function(t,n){t=e(t);var r={src:t.attr("src")||"",elem:t,srcProp:t.prop("src")},i;if(!r.src)return r;i=t.attr("data-server"),i!=null&&(r.server=i),i=t.attr("type"),i?(r.type=i,r.container=e.trim(i.split(";")[0])):(n||(n=t[0].nodeName.toLowerCase(),n=="source"&&(n=(t.closest("video, audio")[0]||{nodeName:"video"}).nodeName.toLowerCase())),r.server?(r.type=n+"/rtmp",r.container=n+"/rtmp"):(i=p.getTypeForSrc(r.src,n,r),i&&(r.type=i,r.container=i))),i=t.attr("media"),i&&(r.media=i);if(r.type=="audio/rtmp"||r.type=="video/rtmp")r.server?r.streamId=r.src:p.parseRtmp(r);return r},v=!f&&"postMessage"in l&&r,m=function(){if(m.loaded)return;m.loaded=!0,e(function(){n.loader.loadList(["track-ui"])})},g=function(){var t;return function(){if(t||!v)return;t=!0,n.loader.loadScript("https://www.youtube.com/player_api"),e(function(){n.polyfill("mediaelement-yt")})}}(),y=function(){f?o():g()};n.addPolyfill("mediaelement-yt",{test:!v,d:["dom-support"]}),p.mimeTypes={audio:{"audio/ogg":["ogg","oga","ogm"],'audio/ogg;codecs="opus"':"opus","audio/mpeg":["mp2","mp3","mpga","mpega"],"audio/mp4":["mp4","mpg4","m4r","m4a","m4p","m4b","aac"],"audio/wav":["wav"],"audio/3gpp":["3gp","3gpp"],"audio/webm":["webm"],"audio/fla":["flv","f4a","fla"],"application/x-mpegURL":["m3u8","m3u"]},video:{"video/ogg":["ogg","ogv","ogm"],"video/mpeg":["mpg","mpeg","mpe"],"video/mp4":["mp4","mpg4","m4v"],"video/quicktime":["mov","qt"],"video/x-msvideo":["avi"],"video/x-ms-asf":["asf","asx"],"video/flv":["flv","f4v"],"video/3gpp":["3gp","3gpp"],"video/webm":["webm"],"application/x-mpegURL":["m3u8","m3u"],"video/MP2T":["ts"]}},p.mimeTypes.source=e.extend({},p.mimeTypes.audio,p.mimeTypes.video),p.getTypeForSrc=function(t,n,r){if(t.indexOf("youtube.com/watch?")!=-1||t.indexOf("youtube.com/v/")!=-1)return"video/youtube";if(t.indexOf("rtmp")===0)return n+"/rtmp";t=t.split("?")[0].split("."),t=t[t.length-1];var i;return e.each(p.mimeTypes[n],function(e,n){if(n.indexOf(t)!==-1)return i=e,!1}),i},p.srces=function(t,n){t=e(t);if(!n){n=[];var r=t[0].nodeName.toLowerCase(),i=d(t,r);return i.src?n.push(i):e("source",t).each(function(){i=d(this,r),i.src&&n.push(i)}),n}t.removeAttr("src").removeAttr("type").find("source").remove(),e.isArray(n)||(n=[n]),n.forEach(function(e){var n=c.createElement("source");typeof e=="string"&&(e={src:e}),n.setAttribute("src",e.src),e.type&&n.setAttribute("type",e.type),e.media&&n.setAttribute("media",e.media),t.append(n)})},e.fn.loadMediaSrc=function(t,n){return this.each(function(){n!==h&&(e(this).removeAttr("poster"),n&&e.attr(this,"poster",n)),p.srces(this,t),e(this).mediaLoad()})},p.swfMimeTypes=["video/3gpp","video/x-msvideo","video/quicktime","video/x-m4v","video/mp4","video/m4p","video/x-flv","video/flv","audio/mpeg","audio/aac","audio/mp4","audio/x-m4a","audio/m4a","audio/mp3","audio/x-fla","audio/fla","youtube/flv","jwplayer/jwplayer","video/youtube","video/rtmp","audio/rtmp"],p.canThirdPlaySrces=function(t,n){var r="";if(f||v)t=e(t),n=n||p.srces(t),e.each(n,function(e,t){if(t.container&&t.src&&(f&&p.swfMimeTypes.indexOf(t.container)!=-1||v&&t.container=="video/youtube"))return r=t,!1});return r};var b={};p.canNativePlaySrces=function(t,n){var i="";if(r){t=e(t);var s=(t[0].nodeName||"").toLowerCase(),o=(b[s]||{prop:{_supvalue:!1}}).prop._supvalue||t[0].canPlayType;if(!o)return i;n=n||p.srces(t),e.each(n,function(e,n){if(n.type&&o.call(t[0],n.type))return i=n,!1})}return i},p.setError=function(t,r){r||(r="can't play sources"),e(t).pause().data("mediaerror",r),n.warn("mediaelementError: "+r),setTimeout(function(){e(t).data("mediaerror")&&e(t).trigger("mediaerror")},1)};var w=function(){var e;return function(t,r,i){e||m(),n.ready(f?a:"mediaelement-yt",function(){p.createSWF?p.createSWF(t,r,i):e||(e=!0,y(),w(t,r,i))}),!e&&v&&!p.createSWF&&g()}}(),E=function(e,t,n,r,i){var s;n||n!==!1&&t&&t.isActive=="third"?(s=p.canThirdPlaySrces(e,r),s?w(e,s,t):i?p.setError(e,!1):E(e,t,!1,r,!0)):(s=p.canNativePlaySrces(e,r),s?t&&t.isActive=="third"&&p.setActive(e,"html5",t):i?(p.setError(e,!1),t&&t.isActive=="third"&&p.setActive(e,"html5",t)):E(e,t,!0,r,!0))},S=/^(?:embed|object|datalist)$/i,x=function(t,r){var i=n.data(t,"mediaelementBase")||n.data(t,"mediaelementBase",{}),s=p.srces(t),o=t.parentNode;clearTimeout(i.loadTimer),e.data(t,"mediaerror",!1);if(!s.length||!o||o.nodeType!=1||S.test(o.nodeName||""))return;r=r||n.data(t,"mediaelement"),E(t,r,u.preferFlash||h,s)};e(c).on("ended",function(t){var r=n.data(t.target,"mediaelement");if(i&&(!r||r.isActive=="html5")&&!e.prop(t.target,"loop"))return;setTimeout(function(){if(e.prop(t.target,"paused")||!e.prop(t.target,"loop"))return;e(t.target).prop("currentTime",0).play()},1)}),n.ready("dom-support",function(){i||n.defineNodeNamesBooleanProperty(["audio","video"],"loop"),["audio","video"].forEach(function(t){var i=n.defineNodeNameProperty(t,"load",{prop:{value:function(){var e=n.data(this,"mediaelement");x(this,e),r&&(!e||e.isActive=="html5")&&i.prop._supvalue&&i.prop._supvalue.apply(this,arguments)}}});b[t]=n.defineNodeNameProperty(t,"canPlayType",{prop:{value:function(n){var i="";return r&&b[t].prop._supvalue&&(i=b[t].prop._supvalue.call(this,n),i=="no"&&(i="")),!i&&f&&(n=e.trim((n||"").split(";")[0]),p.swfMimeTypes.indexOf(n)!=-1&&(i="maybe")),i}}})}),n.onNodeNamesPropertyModify(["audio","video"],["src","poster"],{set:function(){var e=this,t=n.data(e,"mediaelementBase")||n.data(e,"mediaelementBase",{});clearTimeout(t.loadTimer),t.loadTimer=setTimeout(function(){x(e),e=null},9)}})});var T=function(){var t=function(){x(this);if(r){var t,n,i=this,s=function(){var t=e.prop(i,"buffered");if(!t)return;var n="";for(var r=0,s=t.length;r<s;r++)n+=t.end(r);return n},o=function(){var t=s();t!=n&&(n=t,e(i).triggerHandler("progress"))};e(this).on({"play loadstart progress":function(e){e.type=="progress"&&(n=s()),clearTimeout(t),t=setTimeout(o,999)},"emptied stalled mediaerror abort suspend":function(e){e.type=="emptied"&&(n=!1),clearTimeout(t)}})}},i=!1;n.ready("dom-support",function(){i=!0,n.addReady(function(n,r){var i=e("video, audio",n).add(r.filter("video, audio")).each(t);!m.loaded&&e("track",i).length&&m(),i=null})}),r&&!i&&n.addReady(function(t,n){i||e("video, audio",t).add(n.filter("video, audio")).each(function(){if(!p.canNativePlaySrces(this)||!m.loaded&&e("track",this).length)return y(),i=!0,!1})})};t.track&&!s.track&&n.defineProperty(TextTrack.prototype,"shimActiveCues",{get:function(){return this._shimActiveCues||this.activeCues}}),r?(n.isReady("mediaelement-core",!0),T(),n.ready("WINDOWLOAD mediaelement",y)):n.ready(a,T),n.ready("WINDOWLOAD mediaelement",m)})}(jQuery,Modernizr,jQuery.webshims);
View
2  demos/js-webshim/minified/shims/combos/2.js
@@ -1 +1 @@
-var swfmini=function(){function S(){if(g)return;try{var e=u.getElementsByTagName("body")[0].appendChild(H("span"));e.parentNode.removeChild(e)}catch(t){return}g=!0;var n=l.length;for(var r=0;r<n;r++)l[r]()}function x(e){g?e():l[l.length]=e}function T(e){}function N(){f&&C()}function C(){var n=u.getElementsByTagName("body")[0],r=H(t);r.setAttribute("type",s);var i=n.appendChild(r);if(i){var o=0;(function(){if(typeof i.GetVariable!=e){var t=i.GetVariable("$version");t&&(t=t.split(" ")[1].split(","),E.pv=[parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10)])}else if(o<10){o++,setTimeout(arguments.callee,10);return}n.removeChild(r),i=null})()}}function k(n){var r=null,i=P(n);if(i&&i.nodeName=="OBJECT")if(typeof i.SetVariable!=e)r=i;else{var s=i.getElementsByTagName(t)[0];s&&(r=s)}return r}function L(e){if(E.ie&&E.win&&e.readyState!=4){var t=H("div");e.parentNode.insertBefore(t,e),t.parentNode.replaceChild(A(e),t),e.style.display="none",function(){e.readyState==4?e.parentNode.removeChild(e):setTimeout(arguments.callee,10)}()}else e.parentNode.replaceChild(A(e),e)}function A(e){var n=H("div");if(E.win&&E.ie)n.innerHTML=e.innerHTML;else{var r=e.getElementsByTagName(t)[0];if(r){var i=r.childNodes;if(i){var s=i.length;for(var o=0;o<s;o++)(i[o].nodeType!=1||i[o].nodeName!="PARAM")&&i[o].nodeType!=8&&n.appendChild(i[o].cloneNode(!0))}}}return n}function O(n,r,i){var o,u=P(i);if(E.wk&&E.wk<312)return o;if(u){typeof n.id==e&&(n.id=i);if(E.ie&&E.win){var a="";for(var f in n)n[f]!=Object.prototype[f]&&(f.toLowerCase()=="data"?r.movie=n[f]:f.toLowerCase()=="styleclass"?a+=' class="'+n[f]+'"':f.toLowerCase()!="classid"&&(a+=" "+f+'="'+n[f]+'"'));var l="";for(var h in r)r[h]!=Object.prototype[h]&&(l+='<param name="'+h+'" value="'+r[h]+'" />');u.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+a+">"+l+"</object>",c[c.length]=n.id,o=P(n.id)}else{var p=H(t);p.setAttribute("type",s);for(var d in n)n[d]!=Object.prototype[d]&&(d.toLowerCase()=="styleclass"?p.setAttribute("class",n[d]):d.toLowerCase()!="classid"&&p.setAttribute(d,n[d]));for(var v in r)r[v]!=Object.prototype[v]&&v.toLowerCase()!="movie"&&M(p,v,r[v]);u.parentNode.replaceChild(p,u),o=p}}return o}function M(e,t,n){var r=H("param");r.setAttribute("name",t),r.setAttribute("value",n),e.appendChild(r)}function _(e){var t=P(e);t&&t.nodeName=="OBJECT"&&(E.ie&&E.win?(t.style.display="none",function(){t.readyState==4?D(e):setTimeout(arguments.callee,10)}()):t.parentNode.removeChild(t))}function D(e){var t=P(e);if(t){for(var n in t)typeof t[n]=="function"&&(t[n]=null);t.parentNode.removeChild(t)}}function P(e){var t=null;try{t=u.getElementById(e)}catch(n){}return t}function H(e){return u.createElement(e)}function B(e,t,n){e.attachEvent(t,n),h[h.length]=[e,t,n]}function j(e){var t=E.pv,n=e.split(".");return n[0]=parseInt(n[0],10),n[1]=parseInt(n[1],10)||0,n[2]=parseInt(n[2],10)||0,t[0]>n[0]||t[0]==n[0]&&t[1]>n[1]||t[0]==n[0]&&t[1]==n[1]&&t[2]>=n[2]?!0:!1}function F(e,t){if(!w)return;var n,r=t?"visible":"hidden";g&&n&&P(e)&&(P(e).style.visibility=r)}function I(t){var n=/[\\\"<>\.;]/,r=n.exec(t)!=null;return r&&typeof encodeURIComponent!=e?encodeURIComponent(t):t}var e="undefined",t="object",n=jQuery.webshims,r="Shockwave Flash",i="ShockwaveFlash.ShockwaveFlash",s="application/x-shockwave-flash",o=window,u=document,a=navigator,f=!1,l=[N],c=[],h=[],p,d,v,m,g=!1,y,b,w=!0,E=function(){var n=typeof u.getElementById!=e&&typeof u.getElementsByTagName!=e&&typeof u.createElement!=e,l=a.userAgent.toLowerCase(),c=a.platform.toLowerCase(),h=c?/win/.test(c):/win/.test(l),p=c?/mac/.test(c):/mac/.test(l),d=/webkit/.test(l)?parseFloat(l.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):!1,v=!1,m=[0,0,0],g=null;if(typeof a.plugins!=e&&typeof a.plugins[r]==t)g=a.plugins[r].description,g&&(typeof a.mimeTypes==e||!a.mimeTypes[s]||!!a.mimeTypes[s].enabledPlugin)&&(f=!0,v=!1,g=g.replace(/^.*\s+(\S+\s+\S+$)/,"$1"),m[0]=parseInt(g.replace(/^(.*)\..*$/,"$1"),10),m[1]=parseInt(g.replace(/^.*\.(.*)\s.*$/,"$1"),10),m[2]=/[a-zA-Z]/.test(g)?parseInt(g.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0);else if(typeof o.ActiveXObject!=e)try{var y=new ActiveXObject(i);y&&(g=y.GetVariable("$version"),g&&(v=!0,g=g.split(" ")[1].split(","),m=[parseInt(g[0],10),parseInt(g[1],10),parseInt(g[2],10)]))}catch(b){}return{w3:n,pv:m,wk:d,ie:v,win:h,mac:p}}(),q=function(){E.ie&&E.win&&window.attachEvent&&window.attachEvent("onunload",function(){var e=h.length;for(var t=0;t<e;t++)h[t][0].detachEvent(h[t][1],h[t][2]);var n=c.length;for(var r=0;r<n;r++)_(c[r]);for(var i in E)E[i]=null;E=null;for(var s in swfmini)swfmini[s]=null;swfmini=null})}();return n.ready("DOM",S),{registerObject:function(){},getObjectById:function(e){if(E.w3)return k(e)},embedSWF:function(n,r,i,s,o,u,a,f,l,c){var h={success:!1,id:r};E.w3&&!(E.wk&&E.wk<312)&&n&&r&&i&&s&&o?(F(r,!1),x(function(){i+="",s+="";var u={};if(l&&typeof l===t)for(var p in l)u[p]=l[p];u.data=n,u.width=i,u.height=s;var d={};if(f&&typeof f===t)for(var v in f)d[v]=f[v];if(a&&typeof a===t)for(var m in a)typeof d.flashvars!=e?d.flashvars+="&"+m+"="+a[m]:d.flashvars=m+"="+a[m];if(j(o)){var g=O(u,d,r);u.id==r&&F(r,!0),h.success=!0,h.ref=g}else F(r,!0);c&&c(h)})):c&&c(h)},switchOffAutoHideShow:function(){w=!1},ua:E,getFlashPlayerVersion:function(){return{major:E.pv[0],minor:E.pv[1],release:E.pv[2]}},hasFlashPlayerVersion:j,createSWF:function(e,t,n){return E.w3?O(e,t,n):undefined},showExpressInstall:function(){},removeSWF:function(e){E.w3&&_(e)},createCSS:function(){},addDomLoadEvent:x,addLoadEvent:T,expressInstallCallback:function(){}}}();jQuery.webshims.register("dom-extend",function(e,t,n,r,i){"use strict";var s=t.modules,o=/\s*,\s*/,u={},a={},f={},l={},c={},h=e.fn.val,p=function(t,n,r,i,s){return s?h.call(e(t)):h.call(e(t),r)};e.fn.val=function(t){var n=this[0];arguments.length&&t==null&&(t="");if(!arguments.length)return!n||n.nodeType!==1?h.call(this):e.prop(n,"value",t,"val",!0);if(e.isArray(t))return h.apply(this,arguments);var r=e.isFunction(t);return this.each(function(s){n=this;if(n.nodeType===1)if(r){var o=t.call(n,s,e.prop(n,"value",i,"val",!0));o==null&&(o=""),e.prop(n,"value",o,"val")}else e.prop(n,"value",t,"val")})},e.fn.onTrigger=function(e,t){return this.on(e,t).each(t)};var d="_webshimsLib"+Math.round(Math.random()*1e3),v=function(t,n,r){t=t.jquery?t[0]:t;if(!t)return r||{};var s=e.data(t,d);return r!==i&&(s||(s=e.data(t,d,{})),n&&(s[n]=r)),n?s&&s[n]:s};[{name:"getNativeElement",prop:"nativeElement"},{name:"getShadowElement",prop:"shadowElement"},{name:"getShadowFocusElement",prop:"shadowFocusElement"}].forEach(function(t){e.fn[t.name]=function(){return this.map(function(){var e=v(this,"shadowData");return e&&e[t.prop]||this})}}),["removeAttr","prop","attr"].forEach(function(n){u[n]=e[n],e[n]=function(t,r,s,o,l){var h=o=="val",d=h?p:u[n];if(!t||!a[r]||t.nodeType!==1||!h&&o&&n=="attr"&&e.attrFn[r])return d(t,r,s,o,l);var v=(t.nodeName||"").toLowerCase(),m=f[v],g=n!="attr"||s!==!1&&s!==null?n:"removeAttr",y,b,w;m||(m=f["*"]),m&&(m=m[r]),m&&(y=m[g]);if(y){r=="value"&&(b=y.isVal,y.isVal=h);if(g==="removeAttr")return y.value.call(t);if(s===i)return y.get?y.get.call(t):y.value;y.set&&(n=="attr"&&s===!0&&(s=r),w=y.set.call(t,s)),r=="value"&&(y.isVal=b)}else w=d(t,r,s,o,l);if((s!==i||g==="removeAttr")&&c[v]&&c[v][r]){var E;g=="removeAttr"?E=!1:g=="prop"?E=!!s:E=!0,c[v][r].forEach(function(e){(!e.only||(e.only=n=="prop")||e.only=="attr"&&n!="prop")&&e.call(t,s,E,h?"val":g,n)})}return w},l[n]=function(r,s,o){f[r]||(f[r]={}),f[r][s]||(f[r][s]={});var a=f[r][s][n],l=function(e,t,r){return t&&t[e]?t[e]:r&&r[e]?r[e]:n=="prop"&&s=="value"?function(e){var t=this;return o.isVal?p(t,s,e,!1,arguments.length===0):u[n](t,s,e)}:n=="prop"&&e=="value"&&o.value.apply?function(e){var t=u[n](this,s);return t&&t.apply&&(t=t.apply(this,arguments)),t}:function(e){return u[n](this,s,e)}};f[r][s][n]=o,o.value===i&&(o.set||(o.set=o.writeable?l("set",o,a):t.cfg.useStrict&&s=="prop"?function(){throw s+" is readonly on "+r}:e.noop),o.get||(o.get=l("get",o,a))),["value","get","set"].forEach(function(e){o[e]&&(o["_sup"+e]=l(e,a))})}});var m=function(){var e=t.getPrototypeOf(r.createElement("foobar")),n=Object.prototype.hasOwnProperty,i=Modernizr.advancedObjectProperties&&Modernizr.objectAccessor;return function(s,o,u){var a,f;if(i&&(a=r.createElement(s))&&(f=t.getPrototypeOf(a))&&e!==f&&(!a[o]||!n.call(a,o))){var l=a[o];u._supvalue=function(){return l&&l.apply?l.apply(this,arguments):l},f[o]=u.value}else u._supvalue=function(){var e=v(this,"propValue");return e&&e[o]&&e[o].apply?e[o].apply(this,arguments):e&&e[o]},g.extendValue(s,o,u.value);u.value._supvalue=u._supvalue}}(),g=function(){var n={};t.addReady(function(r,i){var s={},o=function(t){s[t]||(s[t]=e(r.getElementsByTagName(t)),i[0]&&e.nodeName(i[0],t)&&(s[t]=s[t].add(i)))};e.each(n,function(e,n){o(e);if(!n||!n.forEach){t.warn("Error: with "+e+"-property. methods: "+n);return}n.forEach(function(t){s[e].each(t)})}),s=null});var i,s=e([]),o=function(t,s){n[t]?n[t].push(s):n[t]=[s],e.isDOMReady&&(i||e(r.getElementsByTagName(t))).each(s)},u={};return{createTmpCache:function(t){return e.isDOMReady&&(i=i||e(r.getElementsByTagName(t))),i||s},flushTmpCache:function(){i=null},content:function(t,n){o(t,function(){var t=e.attr(this,n);t!=null&&e.attr(this,n,t)})},createElement:function(e,t){o(e,t)},extendValue:function(t,n,r){o(t,function(){e(this).each(function(){var e=v(this,"propValue",{});e[n]=this[n],this[n]=r})})}}}(),y=function(e,t){e.defaultValue===i&&(e.defaultValue=""),e.removeAttr||(e.removeAttr={value:function(){e[t||"prop"].set.call(this,e.defaultValue),e.removeAttr._supvalue.call(this)}}),e.attr||(e.attr={})};e.extend(t,{getID:function(){var t=(new Date).getTime();return function(n){n=e(n);var r=n.attr("id");return r||(t++,r="ID-"+t,n.attr("id",r)),r}}(),extendUNDEFProp:function(t,n){e.each(n,function(e,n){e in t||(t[e]=n)})},createPropDefault:y,data:v,moveToFirstEvent:function(t,n,r){var i=(e._data(t,"events")||{})[n],s;i&&i.length>1&&(s=i.pop(),r||(r="bind"),r=="bind"&&i.delegateCount?i.splice(i.delegateCount,0,s):i.unshift(s)),t=null},addShadowDom:function(){var i,s,o,u={init:!1,runs:0,test:function(){var e=u.getHeight(),t=u.getWidth();e!=u.height||t!=u.width?(u.height=e,u.width=t,u.handler({type:"docresize"}),u.runs++,u.runs<9&&setTimeout(u.test,90)):u.runs=0},handler:function(t){clearTimeout(i),i=setTimeout(function(){if(t.type=="resize"){var i=e(n).width(),a=e(n).width();if(a==s&&i==o)return;s=a,o=i,u.height=u.getHeight(),u.width=u.getWidth()}e(r).triggerHandler("updateshadowdom")},t.type=="resize"?50:9)},_create:function(){e.each({Height:"getHeight",Width:"getWidth"},function(e,t){var n=r.body,i=r.documentElement;u[t]=function(){return Math.max(n["scroll"+e],i["scroll"+e],n["offset"+e],i["offset"+e],i["client"+e])}})},start:function(){!this.init&&r.body&&(this.init=!0,this._create(),this.height=u.getHeight(),this.width=u.getWidth(),setInterval(this.test,600),e(this.test),t.ready("WINDOWLOAD",this.test),e(n).bind("resize",this.handler),function(){var t=e.fn.animate,n;e.fn.animate=function(){return clearTimeout(n),n=setTimeout(function(){u.test()},99),t.apply(this,arguments)}}())}};return t.docObserve=function(){t.ready("DOM",function(){u.start()})},function(n,r,i){i=i||{},n.jquery&&(n=n[0]),r.jquery&&(r=r[0]);var s=e.data(n,d)||e.data(n,d,{}),o=e.data(r,d)||e.data(r,d,{}),u={};i.shadowFocusElement?i.shadowFocusElement&&(i.shadowFocusElement.jquery&&(i.shadowFocusElement=i.shadowFocusElement[0]),u=e.data(i.shadowFocusElement,d)||e.data(i.shadowFocusElement,d,u)):i.shadowFocusElement=r,s.hasShadow=r,u.nativeElement=o.nativeElement=n,u.shadowData=o.shadowData=s.shadowData={nativeElement:n,shadowElement:r,shadowFocusElement:i.shadowFocusElement},i.shadowChilds&&i.shadowChilds.each(function(){v(this,"shadowData",o.shadowData)}),i.data&&(u.shadowData.data=o.shadowData.data=s.shadowData.data=i.data),i=null,t.docObserve()}}(),propTypes:{standard:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,""+t)},get:function(){return e.attr.get.call(this)||e.defaultValue}}},"boolean":function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){t?e.attr.set.call(this,""):e.removeAttr.value.call(this)},get:function(){return e.attr.get.call(this)!=null}}},src:function(){var t=r.createElement("a");return t.style.display="none",function(n,r){y(n);if(n.prop)return;n.prop={set:function(e){n.attr.set.call(this,e)},get:function(){var n=this.getAttribute(r),i;if(n==null)return"";t.setAttribute("href",n+"");if(!e.support.hrefNormalized){try{e(t).insertAfter(this),i=t.getAttribute("href",4)}catch(s){i=t.getAttribute("href",4)}e(t).detach()}return i||t.href}}}}(),enumarated:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,t)},get:function(){var t=(e.attr.get.call(this)||"").toLowerCase();if(!t||e.limitedTo.indexOf(t)==-1)t=e.defaultValue;return t}}}},reflectProperties:function(n,r){typeof r=="string"&&(r=r.split(o)),r.forEach(function(r){t.defineNodeNamesProperty(n,r,{prop:{set:function(t){e.attr(this,r,t)},get:function(){return e.attr(this,r)||""}}})})},defineNodeNameProperty:function(n,r,i){return a[r]=!0,i.reflect&&t.propTypes[i.propType||"standard"](i,r),["prop","attr","removeAttr"].forEach(function(s){var o=i[s];o&&(s==="prop"?o=e.extend({writeable:!0},o):o=e.extend({},o,{writeable:!0}),l[s](n,r,o),n!="*"&&t.cfg.extendNative&&s=="prop"&&o.value&&e.isFunction(o.value)&&m(n,r,o),i[s]=o)}),i.initAttr&&g.content(n,r),i},defineNodeNameProperties:function(e,n,r,i){var s;for(var o in n)!i&&n[o].initAttr&&g.createTmpCache(e),r&&(n[o][r]||(n[o][r]={},["value","set","get"].forEach(function(e){e in n[o]&&(n[o][r][e]=n[o][e],delete n[o][e])}))),n[o]=t.defineNodeNameProperty(e,o,n[o]);return i||g.flushTmpCache(),n},createElement:function(n,r,i){var s;return e.isFunction(r)&&(r={after:r}),g.createTmpCache(n),r.before&&g.createElement(n,r.before),i&&(s=t.defineNodeNameProperties(n,i,!1,!0)),r.after&&g.createElement(n,r.after),g.flushTmpCache(),s},onNodeNamesPropertyModify:function(t,n,r,i){typeof t=="string"&&(t=t.split(o)),e.isFunction(r)&&(r={set:r}),t.forEach(function(e){c[e]||(c[e]={}),typeof n=="string"&&(n=n.split(o)),r.initAttr&&g.createTmpCache(e),n.forEach(function(t){c[e][t]||(c[e][t]=[],a[t]=!0),r.set&&(i&&(r.set.only=i),c[e][t].push(r.set)),r.initAttr&&g.content(e,t)}),g.flushTmpCache()})},defineNodeNamesBooleanProperty:function(n,r,s){s||(s={}),e.isFunction(s)&&(s.set=s),t.defineNodeNamesProperty(n,r,{attr:{set:function(e){this.setAttribute(r,e),s.set&&s.set.call(this,!0)},get:function(){var e=this.getAttribute(r);return e==null?i:r}},removeAttr:{value:function(){this.removeAttribute(r),s.set&&s.set.call(this,!1)}},reflect:!0,propType:"boolean",initAttr:s.initAttr||!1})},contentAttr:function(e,t,n){if(!e.nodeName)return;var r;if(n===i)return r=e.attributes[t]||{},n=r.specified?r.value:null,n==null?i:n;typeof n=="boolean"?n?e.setAttribute(t,t):e.removeAttribute(t):e.setAttribute(t,n)},activeLang:function(){var n=[],r={},i,o,u=/:\/\/|^\.*\//,a=function(n,r,i){var s;return r&&i&&e.inArray(r,i.availabeLangs||[])!==-1?(n.loading=!0,s=i.langSrc,u.test(s)||(s=t.cfg.basePath+s),t.loader.loadScript(s+r+".js",function(){n.langObj[r]?(n.loading=!1,l(n,!0)):e(function(){n.langObj[r]&&l(n,!0),n.loading=!1})}),!0):!1},f=function(e){r[e]&&r[e].forEach(function(e){e.callback(i,o,"")})},l=function(e,t){if(e.activeLang!=i&&e.activeLang!==o){var n=s[e.module].options;e.langObj[i]||o&&e.langObj[o]?(e.activeLang=i,e.callback(e.langObj[i]||e.langObj[o],i),f(e.module)):!t&&!a(e,i,n)&&!a(e,o,n)&&e.langObj[""]&&e.activeLang!==""&&(e.activeLang="",e.callback(e.langObj[""],i),f(e.module))}},c=function(t){return typeof t=="string"&&t!==i?(i=t,o=i.split("-")[0],i==o&&(o=!1),e.each(n,function(e,t){l(t)})):typeof t=="object"&&(t.register?(r[t.register]||(r[t.register]=[]),r[t.register].push(t),t.callback(i,o,"")):(t.activeLang||(t.activeLang=""),n.push(t),l(t))),i};return c}()}),e.each({defineNodeNamesProperty:"defineNodeNameProperty",defineNodeNamesProperties:"defineNodeNameProperties",createElements:"createElement"},function(e,n){t[e]=function(e,r,i,s){typeof e=="string"&&(e=e.split(o));var u={};return e.forEach(function(e){u[e]=t[n](e,r,i,s)}),u}}),t.isReady("webshimLocalization",!0)}),function(e,t){if(!Modernizr.localstorage||"hidden"in t.createElement("a"))return;var n={article:"article",aside:"complementary",section:"region",nav:"navigation",address:"contentinfo"},r=function(e,t){var n=e.getAttribute("role");n||e.setAttribute("role",t)};e.webshims.addReady(function(i,s){e.each(n,function(t,n){var o=e(t,i).add(s.filter(t));for(var u=0,a=o.length;u<a;u++)r(o[u],n)});if(i===t){var o=t.getElementsByTagName("header")[0],u=t.getElementsByTagName("footer"),a=u.length;o&&!e(o).closest("section, article")[0]&&r(o,"banner");if(!a)return;var f=u[a-1];e(f).closest("section, article")[0]||r(f,"contentinfo")}})}(jQuery,document),function(e){"use strict";var t="webkitURL"in window,n=window.Modernizr,r=e.webshims,i=r.bugs,s=e('<form action="#" style="width: 1px; height: 1px; overflow: hidden;"><select name="b" required="" /><input required="" name="a" /></form>'),o=function(){if(s[0].querySelector)try{i.findRequired=!s[0].querySelector("select:required")}catch(e){i.findRequired=!1}},u=e("input",s).eq(0),a=function(e){r.loader.loadList(["dom-extend"]),r.ready("dom-extend",e)};i.findRequired=!1,i.validationMessage=!1,r.capturingEventPrevented=function(t){if(!t._isPolyfilled){var n=t.isDefaultPrevented,r=t.preventDefault;t.preventDefault=function(){return clearTimeout(e.data(t.target,t.type+"DefaultPrevented")),e.data(t.target,t.type+"DefaultPrevented",setTimeout(function(){e.removeData(t.target,t.type+"DefaultPrevented")},30)),r.apply(this,arguments)},t.isDefaultPrevented=function(){return!!(n.apply(this,arguments)||e.data(t.target,t.type+"DefaultPrevented")||!1)},t._isPolyfilled=!0}};if(!n.formvalidation||i.bustedValidity)o();else{r.capturingEvents(["input"]),r.capturingEvents(["invalid"],!0);if(window.opera||window.testGoodWithFix)s.appendTo("head"),o(),i.validationMessage=!u.prop("validationMessage"),r.reTest(["form-native-extend","form-message"]),s.remove(),e(function(){a(function(){var t=function(e){e.preventDefault()};["form","input","textarea","select"].forEach(function(n){var i=r.defineNodeNameProperty(n,"checkValidity",{prop:{value:function(){r.fromSubmit||e(this).on("invalid.checkvalidity",t),r.fromCheckValidity=!0;var n=i.prop._supvalue.apply(this,arguments);return r.fromSubmit||e(this).unbind("invalid.checkvalidity",t),r.fromCheckValidity=!1,n}}})})})});t&&!r.bugs.bustedValidity&&function(){var t=/^(?:textarea|input)$/i,n=!1;document.addEventListener("contextmenu",function(e){t.test(e.target.nodeName||"")&&(n=e.target.form)&&setTimeout(function(){n=!1},1)},!1),e(window).on("invalid",function(e){e.originalEvent&&n&&n==e.target.form&&(e.wrongWebkitInvalid=!0,e.stopImmediatePropagation())})}()}e.webshims.register("form-core",function(e,r,i,s,o,u){var a={checkbox:1,radio:1},f=e([]),l=r.bugs,c=function(t){t=e(t);var n,r,i=f;return t[0].type=="radio"&&(r=t.prop("form"),n=t[0].name,n?r?i=e(r[n]):i=e(s.getElementsByName(n)).filter(function(){return!e.prop(this,"form")}):i=t,i=i.filter('[type="radio"]')),i},h=r.getContentValidationMessage=function(t,n,r){var i=e(t).data("errormessage")||t.getAttribute("x-moz-errormessage")||"";return r&&i[r]&&(i=i[r]),typeof i=="object"&&(n=n||e.prop(t,"validity")||{valid:1},n.valid||e.each(n,function(e,t){if(t&&e!="valid"&&i[e])return i=i[e],!1})),typeof i=="object"&&(i=i.defaultMessage),i||""},p={number:1,range:1,date:1},d=function(t){var n=!1;return e(e.prop(t,"elements")).each(function(){n=e(this).is(":invalid");if(n)return!1}),n};e.extend(e.expr[":"],{"valid-element":function(t){return e.nodeName(t,"form")?!d(t):!!e.prop(t,"willValidate")&&!!m(t)},"invalid-element":function(t){return e.nodeName(t,"form")?d(t):!!e.prop(t,"willValidate")&&!m(t)},"required-element":function(t){return!!e.prop(t,"willValidate")&&!!e.prop(t,"required")},"user-error":function(t){return e.prop(t,"willValidate")&&e(t).hasClass("user-error")},"optional-element":function(t){return!!e.prop(t,"willValidate")&&e.prop(t,"required")===!1},"in-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!!(n&&!n.rangeOverflow&&!n.rangeUnderflow)},"out-of-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!(!n||!n.rangeOverflow&&!n.rangeUnderflow)}}),["valid","invalid","required","optional"].forEach(function(t){e.expr[":"][t]=e.expr.filters[t+"-element"]}),e.expr[":"].focus=function(e){try{var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())}catch(n){}return!1};var v=e.event.customEvent||{},m=function(t){return(e.prop(t,"validity")||{valid:1}).valid};(l.bustedValidity||l.findRequired)&&function(){var t=e.find,r=e.find.matchesSelector,i=/(\:valid|\:invalid|\:optional|\:required|\:in-range|\:out-of-range)(?=[\s\[\~\.\+\>\:\#*]|$)/ig,o=function(e){return e+"-element"};e.find=function(){var e=Array.prototype.slice,n=function(n){var r=arguments;return r=e.call(r,1,r.length),r.unshift(n.replace(i,o)),t.apply(this,r)};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}();if(!n.prefixed||n.prefixed("matchesSelector",s.documentElement))e.find.matchesSelector=function(e,t){return t=t.replace(i,o),r.call(this,e,t)}}();var g=e.prop,y={selectedIndex:1,value:1,checked:1,disabled:1,readonly:1};e.prop=function(t,n,r){var i=g.apply(this,arguments);return t&&"form"in t&&y[n]&&r!==o&&e(t).hasClass(E)&&m(t)&&(e(t).getShadowElement().removeClass(E),n=="checked"&&r&&c(t).not(t).removeClass(E).removeAttr("aria-invalid")),i};var b=function(t,n){var r;return e.each(t,function(t,i){if(i)return r=t=="customError"?e.prop(n,"validationMessage"):t,!1}),r},w=function(e){var t;try{t=s.activeElement.name===e}catch(n){}return t},E="user-error",S="user-success",x=function(t){var n,r;if(!t.target)return;n=e(t.target).getNativeElement()[0];if(n.type=="submit"||!e.prop(n,"willValidate"))return;r=e.data(n,"webshimsswitchvalidityclass");var i=function(){if(t.type=="focusout"&&n.type=="radio"&&w(n.name))return;var r=e.prop(n,"validity"),i=e(n).getShadowElement(),s,o,u,f,l;e(n).trigger("refreshCustomValidityRules"),r.valid?i.hasClass(S)||(s=S,o=E,f="changedvaliditystate",u="changedvalid",a[n.type]&&n.checked&&c(n).not(n).removeClass(o).addClass(s).removeAttr("aria-invalid"),e.removeData(n,"webshimsinvalidcause")):(l=b(r,n),e.data(n,"webshimsinvalidcause")!=l&&(e.data(n,"webshimsinvalidcause",l),f="changedvaliditystate"),i.hasClass(E)||(s=E,o=S,a[n.type]&&!n.checked&&c(n).not(n).removeClass(o).addClass(s),u="changedinvalid")),s&&(i.addClass(s).removeClass(o),setTimeout(function(){e(n).trigger(u)},0)),f&&setTimeout(function(){e(n).trigger(f)},0),e.removeData(t.target,"webshimsswitchvalidityclass")};r&&clearTimeout(r),t.type=="refreshvalidityui"?i():e.data(n,"webshimsswitchvalidityclass",setTimeout(i,9))};e(s).on(u.validityUIEvents||"focusout change refreshvalidityui",x),v.changedvaliditystate=!0,v.refreshCustomValidityRules=!0,v.changedvalid=!0,v.changedinvalid=!0,v.refreshvalidityui=!0,r.triggerInlineForm=function(t,n){e(t).trigger(n)},r.modules["form-core"].getGroupElements=c;var T=function(){r.scrollRoot=t||s.compatMode=="BackCompat"?e(s.body):e(s.documentElement)};T(),r.ready("DOM",T),r.getRelOffset=function(t,n){t=e(t);var r=e(n).offset(),i;return e.swap(e(t)[0],{visibility:"hidden",display:"inline-block",left:0,top:0},function(){i=t.offset()}),r.top-=i.top,r.left-=i.left,r},r.wsPopover={_create:function(){this.options=e.extend({},r.cfg.wspopover,this.options),this.id=r.wsPopover.id++,this.eventns=".wsoverlay"+this.id,this.timers={},this.element=e('<div class="ws-popover" tabindex="-1"><div class="ws-po-outerbox"><div class="ws-po-arrow"><div class="ws-po-arrowbox" /></div><div class="ws-po-box" /></div></div>'),this.contentElement=e(".ws-po-box",this.element),this.lastElement=e([]),this.bindElement(),this.options.prepareFor&&this.prepareFor(e(this.options.prepareFor).getNativeElement(),e(this.options.prepareFor).getShadowElement()),this.element.data("wspopover",this)},options:{},content:function(e){this.contentElement.html(e)},bindElement:function(){var e=this,t=function(){e.stopBlur=!1};this.element.on({mousedown:function(n){e.stopBlur=!0,e.timers.stopBlur=setTimeout(t,9)}})},isInElement:function(t,n){return t==n||e.contains(t,n)},show:function(t){if(this.isVisible)return;this.isVisible=!0,t=e(t).getNativeElement();var n=this,r=e(t).getShadowElement();this.clear(),this.element.removeClass("ws-po-visible").css("display","none"),this.options.prepareFor||this.prepareFor(t,r),this.position(r),n.timers.show=setTimeout(function(){n.element.css("display",""),n.timers.show=setTimeout(function(){n.element.addClass("ws-po-visible")},9)},9),e(s).on("focusin"+this.eventns+" mousedown"+this.eventns,function(e){n.options.hideOnBlur&&!n.stopBlur&&!n.isInElement(n.lastElement[0]||s.body,e.target)&&!n.isInElement(n.element[0],e.target)&&n.hide()}),e(i).on("resize"+this.eventns+" pospopover"+this.eventns,function(){clearTimeout(n.timers.repos),n.timers.repos=setTimeout(function(){n.position(r)},900)})},prepareFor:function(t,n){var r,i=e.extend({},this.options,e(t.prop("form")||[]).data("wspopover")||{},t.data("wspopover")),s=this;this.lastElement=e(t).getShadowFocusElement(),i.appendTo=="element"?this.element.insertAfter(t):this.element.appendTo(i.appendTo),this.element.attr({"data-class":t.prop("className"),"data-id":t.prop("id")}),this.element.css({width:i.constrainWidth?n.outerWidth():""}),i.hideOnBlur&&(r=function(e){s.stopBlur?e.stopImmediatePropagation():s.hide()},this.options.prepareFor?s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r).data("preparedpopover",s):s.timers.bindBlur=setTimeout(function(){s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r)},10)),this.prepared||(this.options.prepareFor&&this.element.css("display","none"),e.fn.bgIframe&&this.element.bgIframe()),this.prepared=!0},clear:function(){e(i).off(this.eventns),e(s).off(this.eventns),this.options.prepareFor||this.lastElement.off(this.eventns),this.stopBlur=!1,e.each(this.timers,function(e,t){clearTimeout(t)})},hide:function(){if(!this.isVisible)return;this.isVisible=!1;var t=this,n=function(){t.element.css("display","none").attr({"data-id":"","data-class":"",hidden:"hidden"}),clearTimeout(t.timers.forcehide)};this.clear(),this.element.removeClass("ws-po-visible"),e(i).on("resize"+this.eventns,n),t.timers.forcehide=setTimeout(n,999)},position:function(e){var t=r.getRelOffset(this.element.css({marginTop:0,marginLeft:0,marginRight:0,marginBottom:0}).removeAttr("hidden"),e);t.top+=e.outerHeight(),this.element.css({marginTop:"",marginLeft:"",marginRight:"",marginBottom:""}).css(t)}},r.wsPopover.id=0,r.validityAlert=function(){var t=!1,n=r.objectCreate(r.wsPopover,{},u.messagePopover),s=n.hide.bind(n);return n.element.addClass("validity-alert").attr({role:"alert"}),e.extend(n,{hideDelay:5e3,showFor:function(t,n,r,i){t=e(t).getNativeElement(),this.clear(),this.hide(),i||(this.getMessage(t,n),this.show(t),this.hideDelay&&(this.timers.delayedHide=setTimeout(s,this.hideDelay))),r||this.setFocus(t)},setFocus:function(t){var n=e(t).getShadowFocusElement(),s=r.scrollRoot.scrollTop(),o=n.offset().top-30,u;s>o&&(r.scrollRoot.animate({scrollTop:o-5},{queue:!1,duration:Math.max(Math.min(600,(s-o)*1.5),80)}),u=!0);try{n[0].focus()}catch(a){}u&&(r.scrollRoot.scrollTop(s),setTimeout(function(){r.scrollRoot.scrollTop(s)},0)),e(i).triggerHandler("pospopover"+this.eventns)},getMessage:function(e,t){t||(t=h(e[0])||e.prop("customValidationMessage")||e.prop("validationMessage")),t?n.contentElement.text(t):this.hide()}}),n}(),function(){var t,n=[],r,i;e(s).on("invalid",function(i){if(i.wrongWebkitInvalid)return;var o=e(i.target),u=o.getShadowElement();u.hasClass(E)||(u.addClass(E).removeClass(S),setTimeout(function(){e(i.target).trigger("changedinvalid").trigger("changedvaliditystate")},0));if(!t){t=e.Event("firstinvalid"),t.isInvalidUIPrevented=i.isDefaultPrevented;var a=e.Event("firstinvalidsystem");e(s).triggerHandler(a,{element:i.target,form:i.target.form,isInvalidUIPrevented:i.isDefaultPrevented}),o.trigger(t)}t&&t.isDefaultPrevented()&&i.preventDefault(),n.push(i.target),i.extraData="fix",clearTimeout(r),r=setTimeout(function(){var r={type:"lastinvalid",cancelable:!1,invalidlist:e(n)};t=!1,n=[],e(i.target).trigger(r,r)},9),o=null,u=null})}(),e.fn.getErrorMessage=function(){var t="",n=this[0];return n&&(t=h(n)||e.prop(n,"customValidationMessage")||e.prop(n,"validationMessage")),t},u.replaceValidationUI&&r.ready("DOM forms",function(){e(s).on("firstinvalid",function(t){t.isInvalidUIPrevented()||(t.preventDefault(),e.webshims.validityAlert.showFor(t.target))})})})}(jQuery),jQuery.webshims.register("form-datalist",function(e,t,n,r,i,s){"use strict";var o=r;t.propTypes.element=function(n){t.createPropDefault(n,"attr");if(n.prop)return;n.prop={get:function(){var t=n.attr.get.call(this);return t&&(t=r.getElementById(t),t&&n.propNodeName&&!e.nodeName(t,n.propNodeName)&&(t=null)),t||null},writeable:!1}},function(){var o=e.webshims.cfg.forms,u=Modernizr.input.list;if(u&&!o.customDatalist)return;var a=function(){u||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var n=this,r=e("select",n),i;return r[0]?i=r[0].options:(i=e("option",n).get(),i.length&&t.warn("you should wrap your option-elements for a datalist in a select element to support IE and other old browsers.")),i}}});var n={autocomplete:{attr:{get:function(){var t=this,n=e.data(t,"datalistWidget");return n?n._autocomplete:"autocomplete"in t?t.autocomplete:t.getAttribute("autocomplete")},set:function(t){var n=this,r=e.data(n,"datalistWidget");r?(r._autocomplete=t,t=="off"&&r.hideList()):"autocomplete"in n?n.autocomplete=t:n.setAttribute("autocomplete",t)}}}};o.customDatalist&&(!u||!("selectedOption"in e("<input />")[0]))&&(n.selectedOption={prop:{writeable:!1,get:function(){var t=this,n=e.prop(t,"list"),r=null,i,s;return n?(i=e.prop(t,"value"),i?(s=e.prop(n,"options"),s.length?(e.each(s,function(t,n){if(i==e.prop(n,"value"))return r=n,!1}),r):r):r):r}}}),u?((e("<datalist><select><option></option></select></datalist>").prop("options")||[]).length||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var t=this.options||[];if(!t.length){var n=this,r=e("select",n);r[0]&&r[0].options&&r[0].options.length&&(t=r[0].options)}return t}}}),n.list={attr:{get:function(){var n=t.contentAttr(this,"list");return n!=null?this.removeAttribute("list"):n=e.data(this,"datalistListAttr"),n==null?i:n},set:function(n){var r=this;e.data(r,"datalistListAttr",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"}):n.list={attr:{get:function(){var e=t.contentAttr(this,"list");return e==null?i:e},set:function(n){var r=this;t.contentAttr(r,"list",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"},t.defineNodeNameProperties("input",n),t.addReady(function(t,n){n.filter("datalist > select, datalist, datalist > option, datalist > select > option").closest("datalist").each(function(){var t=e.prop(this,"id");e(this).triggerHandler("updateDatalist")})})},f=0,l={submit:1,button:1,reset:1,hidden:1,range:1,date:1,month:1},c={},h=function(e){if(!e)return[];if(c[e])return c[e];var t;try{t=JSON.parse(localStorage.getItem("storedDatalistOptions"+e))}catch(n){}return c[e]=t||[],t||[]},p=function(e,t){if(!e)return;t=t||[];try{localStorage.setItem("storedDatalistOptions"+e,JSON.stringify(t))}catch(n){}},d=function(t){return t.textContent||t.innerText||e.text([t])||""},v={_create:function(r){if(l[e.prop(r.input,"type")]||l[e.attr(r.input,"type")])return;var i=r.datalist,u=e.data(r.input,"datalistWidget");if(i&&u&&u.datalist!==i){u.datalist=i,u.id=r.id,e(u.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(u,"_resetListCached")),u._resetListCached();return}if(!i){u&&u.destroy();return}if(u&&u.datalist===i)return;f++;var a=this;this.hideList=e.proxy(a,"hideList"),this.datalist=i,this.id=r.id,this.hasViewableData=!0,this._autocomplete=e.attr(r.input,"autocomplete"),e.data(r.input,"datalistWidget",this),this.popover=t.objectCreate(t.wsPopover,{},s.datalistPopover),this.shadowList=this.popover.element.addClass("datalist-polyfill"),this.index=-1,this.input=r.input,this.arrayOptions=[],this.shadowList.delegate("li","mouseenter.datalistWidget mousedown.datalistWidget click.datalistWidget",function(t){var n=e("li:not(.hidden-item)",a.shadowList),i=t.type=="mousedown"||t.type=="click";return a.markItem(n.index(t.currentTarget),i,n),t.type=="click"&&(a.hideList(),o.customDatalist&&e(r.input).trigger("datalistselect")),t.type!="mousedown"}),r.input.setAttribute("autocomplete","off"),e(r.input).attr({"aria-haspopup":"true"}).on({"input.datalistWidget":function(){a.triggeredByDatalist||(a.changedValue=!1,a.showHideOptions())},"keydown.datalistWidget":function(t){var n=t.keyCode,i,s;if(n==40&&!a.showList())return a.markItem(a.index+1,!0),!1;if(!a.popover.isVisible)return;if(n==38)return a.markItem(a.index-1,!0),!1;if(!t.shiftKey&&(n==33||n==36))return a.markItem(0,!0),!1;if(!t.shiftKey&&(n==34||n==35))return s=e("li:not(.hidden-item)",a.shadowList),a.markItem(s.length-1,!0,s),!1;if(n==13||n==27)return n==13&&(i=e("li.active-item:not(.hidden-item)",a.shadowList),a.changeValue(e("li.active-item:not(.hidden-item)",a.shadowList))),a.hideList(),o.customDatalist&&i&&i[0]&&e(r.input).trigger("datalistselect"),!1},"focus.datalistWidget":function(){e(this).hasClass("list-focus")&&a.showList()},"mousedown.datalistWidget":function(){e(this).is(":focus")&&a.showList()}}),e(this.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(this,"_resetListCached")),this._resetListCached(),r.input.form&&(r.input.name||r.input.id)&&e(r.input.form).on("submit.datalistWidget"+r.input.id,function(){if(!e(r.input).hasClass("no-datalist-cache")&&a._autocomplete!="off"){var t=e.prop(r.input,"value"),n=(r.input.name||r.input.id)+e.prop(r.input,"type");a.storedOptions||(a.storedOptions=h(n)),t&&a.storedOptions.indexOf(t)==-1&&(a.storedOptions.push(t),p(n,a.storedOptions))}}),e(n).on("unload.datalist"+this.id+" beforeunload.datalist"+this.id,function(){a.destroy()})},destroy:function(){var t=e.attr(this.input,"autocomplete");e(this.input).off(".datalistWidget").removeData("datalistWidget"),this.shadowList.remove(),e(r).off(".datalist"+this.id),e(n).off(".datalist"+this.id),this.input.form&&this.input.id&&e(this.input.form).off("submit.datalistWidget"+this.input.id),this.input.removeAttribute("aria-haspopup"),t===i?this.input.removeAttribute("autocomplete"):e(this.input).attr("autocomplete",t)},_resetListCached:function(e){var i=this,s;this.needsUpdate=!0,this.lastUpdatedValue=!1,this.lastUnfoundValue="",this.updateTimer||(n.QUnit||(s=e&&r.activeElement==i.input)?i.updateListOptions(s):t.ready("WINDOWLOAD",function(){i.updateTimer=setTimeout(function(){i.updateListOptions(),i=null,f=1},200+100*f)}))},maskHTML:function(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;")},updateListOptions:function(t){this.needsUpdate=!1,clearTimeout(this.updateTimer),this.updateTimer=!1,this.searchStart=o.customDatalist&&e(this.input).hasClass("search-start");var n=[],r=[],i=[],s,u,a,f,l,c;for(a=e.prop(this.datalist,"options"),f=0,l=a.length;f<l;f++){s=a[f];if(s.disabled)return;u={value:e(s).val()||"",text:e.trim(e.attr(s,"label")||d(s)),className:s.className||"",style:e.attr(s,"style")||""},u.text?u.text!=u.value&&(u.className+=" different-label-value"):u.text=u.value,r[f]=u.value,i[f]=u}this.storedOptions||(this.storedOptions=e(this.input).hasClass("no-datalist-cache")||this._autocomplete=="off"?[]:h((this.input.name||this.input.id)+e.prop(this.input,"type"))),this.storedOptions.forEach(function(e,t){r.indexOf(e)==-1&&i.push({value:e,text:e,className:"stored-suggest",style:""})});for(f=0,l=i.length;f<l;f++)c=i[f],n[f]='<li class="'+c.className+'" style="'+c.style+'" tabindex="-1" role="listitem"><span class="option-label">'+this.maskHTML(c.text,"label",c)+'</span> <span class="option-value">'+this.maskHTML(c.value,"value",c)+"</span></li>";this.arrayOptions=i,this.popover.contentElement.html('<div class="datalist-box"><ul role="list">'+n.join("\n")+"</ul></div>"),(t||this.popover.isVisible)&&this.showHideOptions()},showHideOptions:function(t){var n=e.prop(this.input,"value").toLowerCase();if(n===this.lastUpdatedValue||this.lastUnfoundValue&&n.indexOf(this.lastUnfoundValue)===0)return;this.lastUpdatedValue=n;var r=!1,i=this.searchStart,s=e("li",this.shadowList);n?this.arrayOptions.forEach(function(t,o){var u;"lowerText"in t||(t.text!=t.value?t.lowerText=t.value.toLowerCase()+t.text.toLowerCase():t.lowerText=t.text.toLowerCase()),u=t.lowerText.indexOf(n),u=i?!u:u!==-1,u?(e(s[o]).removeClass("hidden-item"),r=!0):e(s[o]).addClass("hidden-item")}):s.length&&(s.removeClass("hidden-item"),r=!0),this.hasViewableData=r,!t&&r&&this.showList(),r||(this.lastUnfoundValue=n,this.hideList())},showList:function(){if(this.popover.isVisible)return!1;this.needsUpdate&&this.updateListOptions(),this.showHideOptions(!0);if(!this.hasViewableData)return!1;var e=this;return e.shadowList.find("li.active-item").removeClass("active-item"),e.popover.show(this.input),!0},hideList:function(){if(!this.popover.isVisible)return!1;var n=this,r=function(t){n.changedValue&&e(n.input).trigger("change"),n.changedValue=!1};return this.popover.hide(),n.shadowList.removeClass("datalist-visible list-item-active"),n.index=-1,n.changedValue&&(n.triggeredByDatalist=!0,t.triggerInlineForm&&t.triggerInlineForm(n.input,"input"),e(n.input).is(":focus")?e(n.input).one("blur",r):r(),n.triggeredByDatalist=!1),!0},scrollIntoView:function(t){var n=e("ul",this.shadowList),r=e("div.datalist-box",this.shadowList),i=t.position(),s;i.top-=(parseInt(n.css("paddingTop"),10)||0)+(parseInt(n.css("marginTop"),10)||0)+(parseInt(n.css("borderTopWidth"),10)||0);if(i.top<0){r.scrollTop(r.scrollTop()+i.top-2);return}i.top+=t.outerHeight(),s=r.height(),i.top>s&&r.scrollTop(r.scrollTop()+(i.top-s)+2)},changeValue:function(t){if(!t[0])return;var n=e("span.option-value",t).text(),r=e.prop(this.input,"value");n!=r&&(e(this.input).prop("value",n).triggerHandler("updateInput"),this.changedValue=!0)},markItem:function(t,n,r){var i,s;r=r||e("li:not(.hidden-item)",this.shadowList);if(!r.length)return;t<0?t=r.length-1:t>=r.length&&(t=0),r.removeClass("active-item"),this.shadowList.addClass("list-item-active"),i=r.filter(":eq("+t+")").addClass("active-item"),n&&(this.changeValue(i),this.scrollIntoView(i)),this.index=t}};a()}()}),function(e,t,n){"use strict";var r=t.audio&&t.video,i=!1,s=n.bugs,o=function(){n.ready(a,function(){n.mediaelement.createSWF||(n.mediaelement.loadSwf=!0,n.reTest([a],r))})},u=n.cfg.mediaelement,a=u&&u.player=="jwplayer"?"mediaelement-swf":"mediaelement-jaris",f;if(!u){n.error("mediaelement wasn't implemented but loaded");return}if(r){var l=document.createElement("video");t.videoBuffered="buffered"in l,i="loop"in l,n.capturingEvents(["play","playing","waiting","paused","ended","durationchange","loadedmetadata","canplay","volumechange"]),t.videoBuffered||(n.addPolyfill("mediaelement-native-fix",{f:"mediaelement",test:t.videoBuffered,d:["dom-support"]}),n.reTest("mediaelement-native-fix"))}if(r&&!u.preferFlash){var c=function(t){var r=t.target.parentNode;!u.preferFlash&&(e(t.target).is("audio, video")||r&&e("source:last",r)[0]==t.target)&&n.ready("DOM mediaelement",function(){f&&o(),n.ready("WINDOWLOAD "+a,function(){setTimeout(function(){f&&!u.preferFlash&&n.mediaelement.createSWF&&!e(t.target).closest("audio, video").is(".nonnative-api-active")?(u.preferFlash=!0,document.removeEventListener("error",c,!0),e("audio, video").mediaLoad(),n.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+t.target.src)):f||document.removeEventListener("error",c,!0)},20)})})};document.addEventListener("error",c,!0),e("audio, video").each(function(){this.error&&c({target:this})})}t.track&&!s.track&&function(){s.track||(s.track=typeof e("<track />")[0].readyState!="number");if(!s.track)try{new TextTrackCue(2,3,"")}catch(t){s.track=!0}var r=n.cfg.track,i=function(t){e(t.target).filter("track").each(o)},o=function(){if(s.track||!r.override&&e.prop(this,"readyState")==3)r.override=!0,n.reTest("track"),document.removeEventListener("error",i,!0),this&&e.nodeName(this,"track")?n.error("track support was overwritten. Please check your vtt including your vtt mime-type"):n.info("track support was overwritten. due to bad browser support")},u=function(){document.addEventListener("error",i,!0),s.track?o():e("track").each(o)};r.override||(n.isReady("track")?u():e(u))}(),n.register("mediaelement-core",function(e,n,l,c,h){f=swfmini.hasFlashPlayerVersion("9.0.115"),e("html").addClass(f?"swf":"no-swf");var p=n.mediaelement;p.parseRtmp=function(e){var t=e.src.split("://"),r=t[1].split("/"),i,s,o;e.server=t[0]+"://"+r[0]+"/",e.streamId=[];for(i=1,s=r.length;i<s;i++)!o&&r[i].indexOf(":")!==-1&&(r[i]=r[i].split(":")[1],o=!0),o?e.streamId.push(r[i]):e.server+=r[i]+"/";e.streamId.length||n.error("Could not parse rtmp url"),e.streamId=e.streamId.join("/")};var d=function(t,n){t=e(t);var r={src:t.attr("src")||"",elem:t,srcProp:t.prop("src")},i;if(!r.src)return r;i=t.attr("data-server"),i!=null&&(r.server=i),i=t.attr("type"),i?(r.type=i,r.container=e.trim(i.split(";")[0])):(n||(n=t[0].nodeName.toLowerCase(),n=="source"&&(n=(t.closest("video, audio")[0]||{nodeName:"video"}).nodeName.toLowerCase())),r.server?(r.type=n+"/rtmp",r.container=n+"/rtmp"):(i=p.getTypeForSrc(r.src,n,r),i&&(r.type=i,r.container=i))),i=t.attr("media"),i&&(r.media=i);if(r.type=="audio/rtmp"||r.type=="video/rtmp")r.server?r.streamId=r.src:p.parseRtmp(r);return r},v=!f&&"postMessage"in l&&r,m=function(){if(m.loaded)return;m.loaded=!0,e(function(){n.loader.loadList(["track-ui"])})},g=function(){var t;return function(){if(t||!v)return;t=!0,n.loader.loadScript("https://www.youtube.com/player_api"),e(function(){n.polyfill("mediaelement-yt")})}}(),y=function(){f?o():g()};n.addPolyfill("mediaelement-yt",{test:!v,d:["dom-support"]}),p.mimeTypes={audio:{"audio/ogg":["ogg","oga","ogm"],'audio/ogg;codecs="opus"':"opus","audio/mpeg":["mp2","mp3","mpga","mpega"],"audio/mp4":["mp4","mpg4","m4r","m4a","m4p","m4b","aac"],"audio/wav":["wav"],"audio/3gpp":["3gp","3gpp"],"audio/webm":["webm"],"audio/fla":["flv","f4a","fla"],"application/x-mpegURL":["m3u8","m3u"]},video:{"video/ogg":["ogg","ogv","ogm"],"video/mpeg":["mpg","mpeg","mpe"],"video/mp4":["mp4","mpg4","m4v"],"video/quicktime":["mov","qt"],"video/x-msvideo":["avi"],"video/x-ms-asf":["asf","asx"],"video/flv":["flv","f4v"],"video/3gpp":["3gp","3gpp"],"video/webm":["webm"],"application/x-mpegURL":["m3u8","m3u"],"video/MP2T":["ts"]}},p.mimeTypes.source=e.extend({},p.mimeTypes.audio,p.mimeTypes.video),p.getTypeForSrc=function(t,n,r){if(t.indexOf("youtube.com/watch?")!=-1||t.indexOf("youtube.com/v/")!=-1)return"video/youtube";if(t.indexOf("rtmp")===0)return n+"/rtmp";t=t.split("?")[0].split("."),t=t[t.length-1];var i;return e.each(p.mimeTypes[n],function(e,n){if(n.indexOf(t)!==-1)return i=e,!1}),i},p.srces=function(t,n){t=e(t);if(!n){n=[];var r=t[0].nodeName.toLowerCase(),i=d(t,r);return i.src?n.push(i):e("source",t).each(function(){i=d(this,r),i.src&&n.push(i)}),n}t.removeAttr("src").removeAttr("type").find("source").remove(),e.isArray(n)||(n=[n]),n.forEach(function(e){var n=c.createElement("source");typeof e=="string"&&(e={src:e}),n.setAttribute("src",e.src),e.type&&n.setAttribute("type",e.type),e.media&&n.setAttribute("media",e.media),t.append(n)})},e.fn.loadMediaSrc=function(t,n){return this.each(function(){n!==h&&(e(this).removeAttr("poster"),n&&e.attr(this,"poster",n)),p.srces(this,t),e(this).mediaLoad()})},p.swfMimeTypes=["video/3gpp","video/x-msvideo","video/quicktime","video/x-m4v","video/mp4","video/m4p","video/x-flv","video/flv","audio/mpeg","audio/aac","audio/mp4","audio/x-m4a","audio/m4a","audio/mp3","audio/x-fla","audio/fla","youtube/flv","jwplayer/jwplayer","video/youtube","video/rtmp","audio/rtmp"],p.canThirdPlaySrces=function(t,n){var r="";if(f||v)t=e(t),n=n||p.srces(t),e.each(n,function(e,t){if(t.container&&t.src&&(f&&p.swfMimeTypes.indexOf(t.container)!=-1||v&&t.container=="video/youtube"))return r=t,!1});return r};var b={};p.canNativePlaySrces=function(t,n){var i="";if(r){t=e(t);var s=(t[0].nodeName||"").toLowerCase(),o=(b[s]||{prop:{_supvalue:!1}}).prop._supvalue||t[0].canPlayType;if(!o)return i;n=n||p.srces(t),e.each(n,function(e,n){if(n.type&&o.call(t[0],n.type))return i=n,!1})}return i},p.setError=function(t,r){r||(r="can't play sources"),e(t).pause().data("mediaerror",r),n.warn("mediaelementError: "+r),setTimeout(function(){e(t).data("mediaerror")&&e(t).trigger("mediaerror")},1)};var w=function(){var e;return function(t,r,i){e||m(),n.ready(f?a:"mediaelement-yt",function(){p.createSWF?p.createSWF(t,r,i):e||(e=!0,y(),w(t,r,i))}),!e&&v&&!p.createSWF&&g()}}(),E=function(e,t,n,r,i){var s;n||n!==!1&&t&&t.isActive=="third"?(s=p.canThirdPlaySrces(e,r),s?w(e,s,t):i?p.setError(e,!1):E(e,t,!1,r,!0)):(s=p.canNativePlaySrces(e,r),s?t&&t.isActive=="third"&&p.setActive(e,"html5",t):i?(p.setError(e,!1),t&&t.isActive=="third"&&p.setActive(e,"html5",t)):E(e,t,!0,r,!0))},S=/^(?:embed|object|datalist)$/i,x=function(t,r){var i=n.data(t,"mediaelementBase")||n.data(t,"mediaelementBase",{}),s=p.srces(t),o=t.parentNode;clearTimeout(i.loadTimer),e.data(t,"mediaerror",!1);if(!s.length||!o||o.nodeType!=1||S.test(o.nodeName||""))return;r=r||n.data(t,"mediaelement"),E(t,r,u.preferFlash||h,s)};e(c).on("ended",function(t){var r=n.data(t.target,"mediaelement");if(i&&(!r||r.isActive=="html5")&&!e.prop(t.target,"loop"))return;setTimeout(function(){if(e.prop(t.target,"paused")||!e.prop(t.target,"loop"))return;e(t.target).prop("currentTime",0).play()},1)}),n.ready("dom-support",function(){i||n.defineNodeNamesBooleanProperty(["audio","video"],"loop"),["audio","video"].forEach(function(t){var i=n.defineNodeNameProperty(t,"load",{prop:{value:function(){var e=n.data(this,"mediaelement");x(this,e),r&&(!e||e.isActive=="html5")&&i.prop._supvalue&&i.prop._supvalue.apply(this,arguments)}}});b[t]=n.defineNodeNameProperty(t,"canPlayType",{prop:{value:function(n){var i="";return r&&b[t].prop._supvalue&&(i=b[t].prop._supvalue.call(this,n),i=="no"&&(i="")),!i&&f&&(n=e.trim((n||"").split(";")[0]),p.swfMimeTypes.indexOf(n)!=-1&&(i="maybe")),i}}})}),n.onNodeNamesPropertyModify(["audio","video"],["src","poster"],{set:function(){var e=this,t=n.data(e,"mediaelementBase")||n.data(e,"mediaelementBase",{});clearTimeout(t.loadTimer),t.loadTimer=setTimeout(function(){x(e),e=null},9)}})});var T=function(){var t=function(){x(this);if(r){var t,n,i=this,s=function(){var t=e.prop(i,"buffered");if(!t)return;var n="";for(var r=0,s=t.length;r<s;r++)n+=t.end(r);return n},o=function(){var t=s();t!=n&&(n=t,e(i).triggerHandler("progress"))};e(this).on({"play loadstart progress":function(e){e.type=="progress"&&(n=s()),clearTimeout(t),t=setTimeout(o,999)},"emptied stalled mediaerror abort suspend":function(e){e.type=="emptied"&&(n=!1),clearTimeout(t)}})}},i=!1;n.ready("dom-support",function(){i=!0,n.addReady(function(n,r){var i=e("video, audio",n).add(r.filter("video, audio")).each(t);!m.loaded&&e("track",i).length&&m(),i=null})}),r&&!i&&n.addReady(function(t,n){i||e("video, audio",t).add(n.filter("video, audio")).each(function(){if(!p.canNativePlaySrces(this)||!m.loaded&&e("track",this).length)return y(),i=!0,!1})})};t.track&&!s.track&&n.defineProperty(TextTrack.prototype,"shimActiveCues",{get:function(){return this._shimActiveCues||this.activeCues}}),r?(n.isReady("mediaelement-core",!0),T(),n.ready("WINDOWLOAD mediaelement",y)):n.ready(a,T),n.ready("WINDOWLOAD mediaelement",m)})}(jQuery,Modernizr,jQuery.webshims);
+var swfmini=function(){function S(){if(g)return;try{var e=u.getElementsByTagName("body")[0].appendChild(H("span"));e.parentNode.removeChild(e)}catch(t){return}g=!0;var n=l.length;for(var r=0;r<n;r++)l[r]()}function x(e){g?e():l[l.length]=e}function T(e){}function N(){f&&C()}function C(){var n=u.getElementsByTagName("body")[0],r=H(t);r.setAttribute("type",s);var i=n.appendChild(r);if(i){var o=0;(function(){if(typeof i.GetVariable!=e){var t=i.GetVariable("$version");t&&(t=t.split(" ")[1].split(","),E.pv=[parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10)])}else if(o<10){o++,setTimeout(arguments.callee,10);return}n.removeChild(r),i=null})()}}function k(n){var r=null,i=P(n);if(i&&i.nodeName=="OBJECT")if(typeof i.SetVariable!=e)r=i;else{var s=i.getElementsByTagName(t)[0];s&&(r=s)}return r}function L(e){if(E.ie&&E.win&&e.readyState!=4){var t=H("div");e.parentNode.insertBefore(t,e),t.parentNode.replaceChild(A(e),t),e.style.display="none",function(){e.readyState==4?e.parentNode.removeChild(e):setTimeout(arguments.callee,10)}()}else e.parentNode.replaceChild(A(e),e)}function A(e){var n=H("div");if(E.win&&E.ie)n.innerHTML=e.innerHTML;else{var r=e.getElementsByTagName(t)[0];if(r){var i=r.childNodes;if(i){var s=i.length;for(var o=0;o<s;o++)(i[o].nodeType!=1||i[o].nodeName!="PARAM")&&i[o].nodeType!=8&&n.appendChild(i[o].cloneNode(!0))}}}return n}function O(n,r,i){var o,u=P(i);if(E.wk&&E.wk<312)return o;if(u){typeof n.id==e&&(n.id=i);if(E.ie&&E.win){var a="";for(var f in n)n[f]!=Object.prototype[f]&&(f.toLowerCase()=="data"?r.movie=n[f]:f.toLowerCase()=="styleclass"?a+=' class="'+n[f]+'"':f.toLowerCase()!="classid"&&(a+=" "+f+'="'+n[f]+'"'));var l="";for(var h in r)r[h]!=Object.prototype[h]&&(l+='<param name="'+h+'" value="'+r[h]+'" />');u.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+a+">"+l+"</object>",c[c.length]=n.id,o=P(n.id)}else{var p=H(t);p.setAttribute("type",s);for(var d in n)n[d]!=Object.prototype[d]&&(d.toLowerCase()=="styleclass"?p.setAttribute("class",n[d]):d.toLowerCase()!="classid"&&p.setAttribute(d,n[d]));for(var v in r)r[v]!=Object.prototype[v]&&v.toLowerCase()!="movie"&&M(p,v,r[v]);u.parentNode.replaceChild(p,u),o=p}}return o}function M(e,t,n){var r=H("param");r.setAttribute("name",t),r.setAttribute("value",n),e.appendChild(r)}function _(e){var t=P(e);t&&t.nodeName=="OBJECT"&&(E.ie&&E.win?(t.style.display="none",function(){t.readyState==4?D(e):setTimeout(arguments.callee,10)}()):t.parentNode.removeChild(t))}function D(e){var t=P(e);if(t){for(var n in t)typeof t[n]=="function"&&(t[n]=null);t.parentNode.removeChild(t)}}function P(e){var t=null;try{t=u.getElementById(e)}catch(n){}return t}function H(e){return u.createElement(e)}function B(e,t,n){e.attachEvent(t,n),h[h.length]=[e,t,n]}function j(e){var t=E.pv,n=e.split(".");return n[0]=parseInt(n[0],10),n[1]=parseInt(n[1],10)||0,n[2]=parseInt(n[2],10)||0,t[0]>n[0]||t[0]==n[0]&&t[1]>n[1]||t[0]==n[0]&&t[1]==n[1]&&t[2]>=n[2]?!0:!1}function F(e,t){if(!w)return;var n,r=t?"visible":"hidden";g&&n&&P(e)&&(P(e).style.visibility=r)}function I(t){var n=/[\\\"<>\.;]/,r=n.exec(t)!=null;return r&&typeof encodeURIComponent!=e?encodeURIComponent(t):t}var e="undefined",t="object",n=jQuery.webshims,r="Shockwave Flash",i="ShockwaveFlash.ShockwaveFlash",s="application/x-shockwave-flash",o=window,u=document,a=navigator,f=!1,l=[N],c=[],h=[],p,d,v,m,g=!1,y,b,w=!0,E=function(){var n=typeof u.getElementById!=e&&typeof u.getElementsByTagName!=e&&typeof u.createElement!=e,l=a.userAgent.toLowerCase(),c=a.platform.toLowerCase(),h=c?/win/.test(c):/win/.test(l),p=c?/mac/.test(c):/mac/.test(l),d=/webkit/.test(l)?parseFloat(l.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):!1,v=!1,m=[0,0,0],g=null;if(typeof a.plugins!=e&&typeof a.plugins[r]==t)g=a.plugins[r].description,g&&(typeof a.mimeTypes==e||!a.mimeTypes[s]||!!a.mimeTypes[s].enabledPlugin)&&(f=!0,v=!1,g=g.replace(/^.*\s+(\S+\s+\S+$)/,"$1"),m[0]=parseInt(g.replace(/^(.*)\..*$/,"$1"),10),m[1]=parseInt(g.replace(/^.*\.(.*)\s.*$/,"$1"),10),m[2]=/[a-zA-Z]/.test(g)?parseInt(g.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0);else if(typeof o.ActiveXObject!=e)try{var y=new ActiveXObject(i);y&&(g=y.GetVariable("$version"),g&&(v=!0,g=g.split(" ")[1].split(","),m=[parseInt(g[0],10),parseInt(g[1],10),parseInt(g[2],10)]))}catch(b){}return{w3:n,pv:m,wk:d,ie:v,win:h,mac:p}}(),q=function(){E.ie&&E.win&&window.attachEvent&&window.attachEvent("onunload",function(){var e=h.length;for(var t=0;t<e;t++)h[t][0].detachEvent(h[t][1],h[t][2]);var n=c.length;for(var r=0;r<n;r++)_(c[r]);for(var i in E)E[i]=null;E=null;for(var s in swfmini)swfmini[s]=null;swfmini=null})}();return n.ready("DOM",S),{registerObject:function(){},getObjectById:function(e){if(E.w3)return k(e)},embedSWF:function(n,r,i,s,o,u,a,f,l,c){var h={success:!1,id:r};E.w3&&!(E.wk&&E.wk<312)&&n&&r&&i&&s&&o?(F(r,!1),x(function(){i+="",s+="";var u={};if(l&&typeof l===t)for(var p in l)u[p]=l[p];u.data=n,u.width=i,u.height=s;var d={};if(f&&typeof f===t)for(var v in f)d[v]=f[v];if(a&&typeof a===t)for(var m in a)typeof d.flashvars!=e?d.flashvars+="&"+m+"="+a[m]:d.flashvars=m+"="+a[m];if(j(o)){var g=O(u,d,r);u.id==r&&F(r,!0),h.success=!0,h.ref=g}else F(r,!0);c&&c(h)})):c&&c(h)},switchOffAutoHideShow:function(){w=!1},ua:E,getFlashPlayerVersion:function(){return{major:E.pv[0],minor:E.pv[1],release:E.pv[2]}},hasFlashPlayerVersion:j,createSWF:function(e,t,n){return E.w3?O(e,t,n):undefined},showExpressInstall:function(){},removeSWF:function(e){E.w3&&_(e)},createCSS:function(){},addDomLoadEvent:x,addLoadEvent:T,expressInstallCallback:function(){}}}();jQuery.webshims.register("dom-extend",function(e,t,n,r,i){"use strict";var s=t.modules,o=/\s*,\s*/,u={},a={},f={},l={},c={},h=e.fn.val,p=function(t,n,r,i,s){return s?h.call(e(t)):h.call(e(t),r)};e.fn.val=function(t){var n=this[0];arguments.length&&t==null&&(t="");if(!arguments.length)return!n||n.nodeType!==1?h.call(this):e.prop(n,"value",t,"val",!0);if(e.isArray(t))return h.apply(this,arguments);var r=e.isFunction(t);return this.each(function(s){n=this;if(n.nodeType===1)if(r){var o=t.call(n,s,e.prop(n,"value",i,"val",!0));o==null&&(o=""),e.prop(n,"value",o,"val")}else e.prop(n,"value",t,"val")})},e.fn.onTrigger=function(e,t){return this.on(e,t).each(t)};var d="_webshimsLib"+Math.round(Math.random()*1e3),v=function(t,n,r){t=t.jquery?t[0]:t;if(!t)return r||{};var s=e.data(t,d);return r!==i&&(s||(s=e.data(t,d,{})),n&&(s[n]=r)),n?s&&s[n]:s};[{name:"getNativeElement",prop:"nativeElement"},{name:"getShadowElement",prop:"shadowElement"},{name:"getShadowFocusElement",prop:"shadowFocusElement"}].forEach(function(t){e.fn[t.name]=function(){return this.map(function(){var e=v(this,"shadowData");return e&&e[t.prop]||this})}}),["removeAttr","prop","attr"].forEach(function(n){u[n]=e[n],e[n]=function(t,r,s,o,l){var h=o=="val",d=h?p:u[n];if(!t||!a[r]||t.nodeType!==1||!h&&o&&n=="attr"&&e.attrFn[r])return d(t,r,s,o,l);var v=(t.nodeName||"").toLowerCase(),m=f[v],g=n!="attr"||s!==!1&&s!==null?n:"removeAttr",y,b,w;m||(m=f["*"]),m&&(m=m[r]),m&&(y=m[g]);if(y){r=="value"&&(b=y.isVal,y.isVal=h);if(g==="removeAttr")return y.value.call(t);if(s===i)return y.get?y.get.call(t):y.value;y.set&&(n=="attr"&&s===!0&&(s=r),w=y.set.call(t,s)),r=="value"&&(y.isVal=b)}else w=d(t,r,s,o,l);if((s!==i||g==="removeAttr")&&c[v]&&c[v][r]){var E;g=="removeAttr"?E=!1:g=="prop"?E=!!s:E=!0,c[v][r].forEach(function(e){(!e.only||(e.only=n=="prop")||e.only=="attr"&&n!="prop")&&e.call(t,s,E,h?"val":g,n)})}return w},l[n]=function(r,s,o){f[r]||(f[r]={}),f[r][s]||(f[r][s]={});var a=f[r][s][n],l=function(e,t,r){return t&&t[e]?t[e]:r&&r[e]?r[e]:n=="prop"&&s=="value"?function(e){var t=this;return o.isVal?p(t,s,e,!1,arguments.length===0):u[n](t,s,e)}:n=="prop"&&e=="value"&&o.value.apply?function(e){var t=u[n](this,s);return t&&t.apply&&(t=t.apply(this,arguments)),t}:function(e){return u[n](this,s,e)}};f[r][s][n]=o,o.value===i&&(o.set||(o.set=o.writeable?l("set",o,a):t.cfg.useStrict&&s=="prop"?function(){throw s+" is readonly on "+r}:e.noop),o.get||(o.get=l("get",o,a))),["value","get","set"].forEach(function(e){o[e]&&(o["_sup"+e]=l(e,a))})}});var m=function(){var e=t.getPrototypeOf(r.createElement("foobar")),n=Object.prototype.hasOwnProperty,i=Modernizr.advancedObjectProperties&&Modernizr.objectAccessor;return function(s,o,u){var a,f;if(i&&(a=r.createElement(s))&&(f=t.getPrototypeOf(a))&&e!==f&&(!a[o]||!n.call(a,o))){var l=a[o];u._supvalue=function(){return l&&l.apply?l.apply(this,arguments):l},f[o]=u.value}else u._supvalue=function(){var e=v(this,"propValue");return e&&e[o]&&e[o].apply?e[o].apply(this,arguments):e&&e[o]},g.extendValue(s,o,u.value);u.value._supvalue=u._supvalue}}(),g=function(){var n={};t.addReady(function(r,i){var s={},o=function(t){s[t]||(s[t]=e(r.getElementsByTagName(t)),i[0]&&e.nodeName(i[0],t)&&(s[t]=s[t].add(i)))};e.each(n,function(e,n){o(e);if(!n||!n.forEach){t.warn("Error: with "+e+"-property. methods: "+n);return}n.forEach(function(t){s[e].each(t)})}),s=null});var i,s=e([]),o=function(t,s){n[t]?n[t].push(s):n[t]=[s],e.isDOMReady&&(i||e(r.getElementsByTagName(t))).each(s)},u={};return{createTmpCache:function(t){return e.isDOMReady&&(i=i||e(r.getElementsByTagName(t))),i||s},flushTmpCache:function(){i=null},content:function(t,n){o(t,function(){var t=e.attr(this,n);t!=null&&e.attr(this,n,t)})},createElement:function(e,t){o(e,t)},extendValue:function(t,n,r){o(t,function(){e(this).each(function(){var e=v(this,"propValue",{});e[n]=this[n],this[n]=r})})}}}(),y=function(e,t){e.defaultValue===i&&(e.defaultValue=""),e.removeAttr||(e.removeAttr={value:function(){e[t||"prop"].set.call(this,e.defaultValue),e.removeAttr._supvalue.call(this)}}),e.attr||(e.attr={})};e.extend(t,{getID:function(){var t=(new Date).getTime();return function(n){n=e(n);var r=n.prop("id");return r||(t++,r="ID-"+t,n.eq(0).prop("id",r)),r}}(),extendUNDEFProp:function(t,n){e.each(n,function(e,n){e in t||(t[e]=n)})},createPropDefault:y,data:v,moveToFirstEvent:function(t,n,r){var i=(e._data(t,"events")||{})[n],s;i&&i.length>1&&(s=i.pop(),r||(r="bind"),r=="bind"&&i.delegateCount?i.splice(i.delegateCount,0,s):i.unshift(s)),t=null},addShadowDom:function(){var i,s,o,u={init:!1,runs:0,test:function(){var e=u.getHeight(),t=u.getWidth();e!=u.height||t!=u.width?(u.height=e,u.width=t,u.handler({type:"docresize"}),u.runs++,u.runs<9&&setTimeout(u.test,90)):u.runs=0},handler:function(t){clearTimeout(i),i=setTimeout(function(){if(t.type=="resize"){var i=e(n).width(),a=e(n).width();if(a==s&&i==o)return;s=a,o=i,u.height=u.getHeight(),u.width=u.getWidth()}e(r).triggerHandler("updateshadowdom")},t.type=="resize"?50:9)},_create:function(){e.each({Height:"getHeight",Width:"getWidth"},function(e,t){var n=r.body,i=r.documentElement;u[t]=function(){return Math.max(n["scroll"+e],i["scroll"+e],n["offset"+e],i["offset"+e],i["client"+e])}})},start:function(){!this.init&&r.body&&(this.init=!0,this._create(),this.height=u.getHeight(),this.width=u.getWidth(),setInterval(this.test,600),e(this.test),t.ready("WINDOWLOAD",this.test),e(n).bind("resize",this.handler),function(){var t=e.fn.animate,n;e.fn.animate=function(){return clearTimeout(n),n=setTimeout(function(){u.test()},99),t.apply(this,arguments)}}())}};return t.docObserve=function(){t.ready("DOM",function(){u.start()})},function(n,r,i){i=i||{},n.jquery&&(n=n[0]),r.jquery&&(r=r[0]);var s=e.data(n,d)||e.data(n,d,{}),o=e.data(r,d)||e.data(r,d,{}),u={};i.shadowFocusElement?i.shadowFocusElement&&(i.shadowFocusElement.jquery&&(i.shadowFocusElement=i.shadowFocusElement[0]),u=e.data(i.shadowFocusElement,d)||e.data(i.shadowFocusElement,d,u)):i.shadowFocusElement=r,s.hasShadow=r,u.nativeElement=o.nativeElement=n,u.shadowData=o.shadowData=s.shadowData={nativeElement:n,shadowElement:r,shadowFocusElement:i.shadowFocusElement},i.shadowChilds&&i.shadowChilds.each(function(){v(this,"shadowData",o.shadowData)}),i.data&&(u.shadowData.data=o.shadowData.data=s.shadowData.data=i.data),i=null,t.docObserve()}}(),propTypes:{standard:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,""+t)},get:function(){return e.attr.get.call(this)||e.defaultValue}}},"boolean":function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){t?e.attr.set.call(this,""):e.removeAttr.value.call(this)},get:function(){return e.attr.get.call(this)!=null}}},src:function(){var t=r.createElement("a");return t.style.display="none",function(n,r){y(n);if(n.prop)return;n.prop={set:function(e){n.attr.set.call(this,e)},get:function(){var n=this.getAttribute(r),i;if(n==null)return"";t.setAttribute("href",n+"");if(!e.support.hrefNormalized){try{e(t).insertAfter(this),i=t.getAttribute("href",4)}catch(s){i=t.getAttribute("href",4)}e(t).detach()}return i||t.href}}}}(),enumarated:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,t)},get:function(){var t=(e.attr.get.call(this)||"").toLowerCase();if(!t||e.limitedTo.indexOf(t)==-1)t=e.defaultValue;return t}}}},reflectProperties:function(n,r){typeof r=="string"&&(r=r.split(o)),r.forEach(function(r){t.defineNodeNamesProperty(n,r,{prop:{set:function(t){e.attr(this,r,t)},get:function(){return e.attr(this,r)||""}}})})},defineNodeNameProperty:function(n,r,i){return a[r]=!0,i.reflect&&t.propTypes[i.propType||"standard"](i,r),["prop","attr","removeAttr"].forEach(function(s){var o=i[s];o&&(s==="prop"?o=e.extend({writeable:!0},o):o=e.extend({},o,{writeable:!0}),l[s](n,r,o),n!="*"&&t.cfg.extendNative&&s=="prop"&&o.value&&e.isFunction(o.value)&&m(n,r,o),i[s]=o)}),i.initAttr&&g.content(n,r),i},defineNodeNameProperties:function(e,n,r,i){var s;for(var o in n)!i&&n[o].initAttr&&g.createTmpCache(e),r&&(n[o][r]||(n[o][r]={},["value","set","get"].forEach(function(e){e in n[o]&&(n[o][r][e]=n[o][e],delete n[o][e])}))),n[o]=t.defineNodeNameProperty(e,o,n[o]);return i||g.flushTmpCache(),n},createElement:function(n,r,i){var s;return e.isFunction(r)&&(r={after:r}),g.createTmpCache(n),r.before&&g.createElement(n,r.before),i&&(s=t.defineNodeNameProperties(n,i,!1,!0)),r.after&&g.createElement(n,r.after),g.flushTmpCache(),s},onNodeNamesPropertyModify:function(t,n,r,i){typeof t=="string"&&(t=t.split(o)),e.isFunction(r)&&(r={set:r}),t.forEach(function(e){c[e]||(c[e]={}),typeof n=="string"&&(n=n.split(o)),r.initAttr&&g.createTmpCache(e),n.forEach(function(t){c[e][t]||(c[e][t]=[],a[t]=!0),r.set&&(i&&(r.set.only=i),c[e][t].push(r.set)),r.initAttr&&g.content(e,t)}),g.flushTmpCache()})},defineNodeNamesBooleanProperty:function(n,r,s){s||(s={}),e.isFunction(s)&&(s.set=s),t.defineNodeNamesProperty(n,r,{attr:{set:function(e){this.setAttribute(r,e),s.set&&s.set.call(this,!0)},get:function(){var e=this.getAttribute(r);return e==null?i:r}},removeAttr:{value:function(){this.removeAttribute(r),s.set&&s.set.call(this,!1)}},reflect:!0,propType:"boolean",initAttr:s.initAttr||!1})},contentAttr:function(e,t,n){if(!e.nodeName)return;var r;if(n===i)return r=e.attributes[t]||{},n=r.specified?r.value:null,n==null?i:n;typeof n=="boolean"?n?e.setAttribute(t,t):e.removeAttribute(t):e.setAttribute(t,n)},activeLang:function(){var n=[],r={},i,o,u=/:\/\/|^\.*\//,a=function(n,r,i){var s;return r&&i&&e.inArray(r,i.availabeLangs||[])!==-1?(n.loading=!0,s=i.langSrc,u.test(s)||(s=t.cfg.basePath+s),t.loader.loadScript(s+r+".js",function(){n.langObj[r]?(n.loading=!1,l(n,!0)):e(function(){n.langObj[r]&&l(n,!0),n.loading=!1})}),!0):!1},f=function(e){r[e]&&r[e].forEach(function(e){e.callback(i,o,"")})},l=function(e,t){if(e.activeLang!=i&&e.activeLang!==o){var n=s[e.module].options;e.langObj[i]||o&&e.langObj[o]?(e.activeLang=i,e.callback(e.langObj[i]||e.langObj[o],i),f(e.module)):!t&&!a(e,i,n)&&!a(e,o,n)&&e.langObj[""]&&e.activeLang!==""&&(e.activeLang="",e.callback(e.langObj[""],i),f(e.module))}},c=function(t){return typeof t=="string"&&t!==i?(i=t,o=i.split("-")[0],i==o&&(o=!1),e.each(n,function(e,t){l(t)})):typeof t=="object"&&(t.register?(r[t.register]||(r[t.register]=[]),r[t.register].push(t),t.callback(i,o,"")):(t.activeLang||(t.activeLang=""),n.push(t),l(t))),i};return c}()}),e.each({defineNodeNamesProperty:"defineNodeNameProperty",defineNodeNamesProperties:"defineNodeNameProperties",createElements:"createElement"},function(e,n){t[e]=function(e,r,i,s){typeof e=="string"&&(e=e.split(o));var u={};return e.forEach(function(e){u[e]=t[n](e,r,i,s)}),u}}),t.isReady("webshimLocalization",!0)}),function(e,t){if(!Modernizr.localstorage||"hidden"in t.createElement("a"))return;var n={article:"article",aside:"complementary",section:"region",nav:"navigation",address:"contentinfo"},r=function(e,t){var n=e.getAttribute("role");n||e.setAttribute("role",t)};e.webshims.addReady(function(i,s){e.each(n,function(t,n){var o=e(t,i).add(s.filter(t));for(var u=0,a=o.length;u<a;u++)r(o[u],n)});if(i===t){var o=t.getElementsByTagName("header")[0],u=t.getElementsByTagName("footer"),a=u.length;o&&!e(o).closest("section, article")[0]&&r(o,"banner");if(!a)return;var f=u[a-1];e(f).closest("section, article")[0]||r(f,"contentinfo")}})}(jQuery,document),function(e){"use strict";var t="webkitURL"in window,n=window.Modernizr,r=e.webshims,i=r.bugs,s=e('<form action="#" style="width: 1px; height: 1px; overflow: hidden;"><select name="b" required="" /><input required="" name="a" /></form>'),o=function(){if(s[0].querySelector)try{i.findRequired=!s[0].querySelector("select:required")}catch(e){i.findRequired=!1}},u=e("input",s).eq(0),a=function(e){r.loader.loadList(["dom-extend"]),r.ready("dom-extend",e)};i.findRequired=!1,i.validationMessage=!1,r.capturingEventPrevented=function(t){if(!t._isPolyfilled){var n=t.isDefaultPrevented,r=t.preventDefault;t.preventDefault=function(){return clearTimeout(e.data(t.target,t.type+"DefaultPrevented")),e.data(t.target,t.type+"DefaultPrevented",setTimeout(function(){e.removeData(t.target,t.type+"DefaultPrevented")},30)),r.apply(this,arguments)},t.isDefaultPrevented=function(){return!!(n.apply(this,arguments)||e.data(t.target,t.type+"DefaultPrevented")||!1)},t._isPolyfilled=!0}};if(!n.formvalidation||i.bustedValidity)o();else{r.capturingEvents(["input"]),r.capturingEvents(["invalid"],!0);if(window.opera||window.testGoodWithFix)s.appendTo("head"),o(),i.validationMessage=!u.prop("validationMessage"),r.reTest(["form-native-extend","form-message"]),s.remove(),e(function(){a(function(){var t=function(e){e.preventDefault()};["form","input","textarea","select"].forEach(function(n){var i=r.defineNodeNameProperty(n,"checkValidity",{prop:{value:function(){r.fromSubmit||e(this).on("invalid.checkvalidity",t),r.fromCheckValidity=!0;var n=i.prop._supvalue.apply(this,arguments);return r.fromSubmit||e(this).unbind("invalid.checkvalidity",t),r.fromCheckValidity=!1,n}}})})})});t&&!r.bugs.bustedValidity&&function(){var t=/^(?:textarea|input)$/i,n=!1;document.addEventListener("contextmenu",function(e){t.test(e.target.nodeName||"")&&(n=e.target.form)&&setTimeout(function(){n=!1},1)},!1),e(window).on("invalid",function(e){e.originalEvent&&n&&n==e.target.form&&(e.wrongWebkitInvalid=!0,e.stopImmediatePropagation())})}()}e.webshims.register("form-core",function(e,r,i,s,o,u){var a={checkbox:1,radio:1},f=e([]),l=r.bugs,c=function(t){t=e(t);var n,r,i=f;return t[0].type=="radio"&&(r=t.prop("form"),n=t[0].name,n?r?i=e(r[n]):i=e(s.getElementsByName(n)).filter(function(){return!e.prop(this,"form")}):i=t,i=i.filter('[type="radio"]')),i},h=r.getContentValidationMessage=function(t,n,r){var i=e(t).data("errormessage")||t.getAttribute("x-moz-errormessage")||"";return r&&i[r]&&(i=i[r]),typeof i=="object"&&(n=n||e.prop(t,"validity")||{valid:1},n.valid||e.each(n,function(e,t){if(t&&e!="valid"&&i[e])return i=i[e],!1})),typeof i=="object"&&(i=i.defaultMessage),i||""},p={number:1,range:1,date:1},d=function(t){var n=!1;return e(e.prop(t,"elements")).each(function(){n=e(this).is(":invalid");if(n)return!1}),n};e.extend(e.expr[":"],{"valid-element":function(t){return e.nodeName(t,"form")?!d(t):!!e.prop(t,"willValidate")&&!!m(t)},"invalid-element":function(t){return e.nodeName(t,"form")?d(t):!!e.prop(t,"willValidate")&&!m(t)},"required-element":function(t){return!!e.prop(t,"willValidate")&&!!e.prop(t,"required")},"user-error":function(t){return e.prop(t,"willValidate")&&e(t).hasClass("user-error")},"optional-element":function(t){return!!e.prop(t,"willValidate")&&e.prop(t,"required")===!1},"in-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!!(n&&!n.rangeOverflow&&!n.rangeUnderflow)},"out-of-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!(!n||!n.rangeOverflow&&!n.rangeUnderflow)}}),["valid","invalid","required","optional"].forEach(function(t){e.expr[":"][t]=e.expr.filters[t+"-element"]}),e.expr[":"].focus=function(e){try{var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())}catch(n){}return!1};var v=e.event.customEvent||{},m=function(t){return(e.prop(t,"validity")||{valid:1}).valid};(l.bustedValidity||l.findRequired)&&function(){var t=e.find,r=e.find.matchesSelector,i=/(\:valid|\:invalid|\:optional|\:required|\:in-range|\:out-of-range)(?=[\s\[\~\.\+\>\:\#*]|$)/ig,o=function(e){return e+"-element"};e.find=function(){var e=Array.prototype.slice,n=function(n){var r=arguments;return r=e.call(r,1,r.length),r.unshift(n.replace(i,o)),t.apply(this,r)};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}();if(!n.prefixed||n.prefixed("matchesSelector",s.documentElement))e.find.matchesSelector=function(e,t){return t=t.replace(i,o),r.call(this,e,t)}}();var g=e.prop,y={selectedIndex:1,value:1,checked:1,disabled:1,readonly:1};e.prop=function(t,n,r){var i=g.apply(this,arguments);return t&&"form"in t&&y[n]&&r!==o&&e(t).hasClass(E)&&m(t)&&(e(t).getShadowElement().removeClass(E),n=="checked"&&r&&c(t).not(t).removeClass(E).removeAttr("aria-invalid")),i};var b=function(t,n){var r;return e.each(t,function(t,i){if(i)return r=t=="customError"?e.prop(n,"validationMessage"):t,!1}),r},w=function(e){var t;try{t=s.activeElement.name===e}catch(n){}return t},E="user-error",S="user-success",x=function(t){var n,r;if(!t.target)return;n=e(t.target).getNativeElement()[0];if(n.type=="submit"||!e.prop(n,"willValidate"))return;r=e.data(n,"webshimsswitchvalidityclass");var i=function(){if(t.type=="focusout"&&n.type=="radio"&&w(n.name))return;var r=e.prop(n,"validity"),i=e(n).getShadowElement(),s,o,u,f,l;e(n).trigger("refreshCustomValidityRules"),r.valid?i.hasClass(S)||(s=S,o=E,f="changedvaliditystate",u="changedvalid",a[n.type]&&n.checked&&c(n).not(n).removeClass(o).addClass(s).removeAttr("aria-invalid"),e.removeData(n,"webshimsinvalidcause")):(l=b(r,n),e.data(n,"webshimsinvalidcause")!=l&&(e.data(n,"webshimsinvalidcause",l),f="changedvaliditystate"),i.hasClass(E)||(s=E,o=S,a[n.type]&&!n.checked&&c(n).not(n).removeClass(o).addClass(s),u="changedinvalid")),s&&(i.addClass(s).removeClass(o),setTimeout(function(){e(n).trigger(u)},0)),f&&setTimeout(function(){e(n).trigger(f)},0),e.removeData(t.target,"webshimsswitchvalidityclass")};r&&clearTimeout(r),t.type=="refreshvalidityui"?i():e.data(n,"webshimsswitchvalidityclass",setTimeout(i,9))};e(s).on(u.validityUIEvents||"focusout change refreshvalidityui",x),v.changedvaliditystate=!0,v.refreshCustomValidityRules=!0,v.changedvalid=!0,v.changedinvalid=!0,v.refreshvalidityui=!0,r.triggerInlineForm=function(t,n){e(t).trigger(n)},r.modules["form-core"].getGroupElements=c;var T=function(){r.scrollRoot=t||s.compatMode=="BackCompat"?e(s.body):e(s.documentElement)};T(),r.ready("DOM",T),r.getRelOffset=function(t,n){t=e(t);var r=e(n).offset(),i;return e.swap(e(t)[0],{visibility:"hidden",display:"inline-block",left:0,top:0},function(){i=t.offset()}),r.top-=i.top,r.left-=i.left,r},r.wsPopover={_create:function(){this.options=e.extend({},r.cfg.wspopover,this.options),this.id=r.wsPopover.id++,this.eventns=".wsoverlay"+this.id,this.timers={},this.element=e('<div class="ws-popover" tabindex="-1"><div class="ws-po-outerbox"><div class="ws-po-arrow"><div class="ws-po-arrowbox" /></div><div class="ws-po-box" /></div></div>'),this.contentElement=e(".ws-po-box",this.element),this.lastElement=e([]),this.bindElement(),this.options.prepareFor&&this.prepareFor(e(this.options.prepareFor).getNativeElement(),e(this.options.prepareFor).getShadowElement()),this.element.data("wspopover",this)},options:{},content:function(e){this.contentElement.html(e)},bindElement:function(){var e=this,t=function(){e.stopBlur=!1};this.element.on({mousedown:function(n){e.stopBlur=!0,e.timers.stopBlur=setTimeout(t,9)}})},isInElement:function(t,n){return t==n||e.contains(t,n)},show:function(t){if(this.isVisible)return;this.isVisible=!0,t=e(t).getNativeElement();var n=this,r=e(t).getShadowElement();this.clear(),this.element.removeClass("ws-po-visible").css("display","none"),this.options.prepareFor||this.prepareFor(t,r),this.position(r),n.timers.show=setTimeout(function(){n.element.css("display",""),n.timers.show=setTimeout(function(){n.element.addClass("ws-po-visible")},9)},9),e(s).on("focusin"+this.eventns+" mousedown"+this.eventns,function(e){n.options.hideOnBlur&&!n.stopBlur&&!n.isInElement(n.lastElement[0]||s.body,e.target)&&!n.isInElement(n.element[0],e.target)&&n.hide()}),e(i).on("resize"+this.eventns+" pospopover"+this.eventns,function(){clearTimeout(n.timers.repos),n.timers.repos=setTimeout(function(){n.position(r)},900)})},prepareFor:function(t,n){var r,i=e.extend({},this.options,e(t.prop("form")||[]).data("wspopover")||{},t.data("wspopover")),s=this;this.lastElement=e(t).getShadowFocusElement(),i.appendTo=="element"?this.element.insertAfter(t):this.element.appendTo(i.appendTo),this.element.attr({"data-class":t.prop("className"),"data-id":t.prop("id")}),this.element.css({width:i.constrainWidth?n.outerWidth():""}),i.hideOnBlur&&(r=function(e){s.stopBlur?e.stopImmediatePropagation():s.hide()},this.options.prepareFor?s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r).data("preparedpopover",s):s.timers.bindBlur=setTimeout(function(){s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r)},10)),this.prepared||(this.options.prepareFor&&this.element.css("display","none"),e.fn.bgIframe&&this.element.bgIframe()),this.prepared=!0},clear:function(){e(i).off(this.eventns),e(s).off(this.eventns),this.options.prepareFor||this.lastElement.off(this.eventns),this.stopBlur=!1,e.each(this.timers,function(e,t){clearTimeout(t)})},hide:function(){if(!this.isVisible)return;this.isVisible=!1;var t=this,n=function(){t.element.css("display","none").attr({"data-id":"","data-class":"",hidden:"hidden"}),clearTimeout(t.timers.forcehide)};this.clear(),this.element.removeClass("ws-po-visible"),e(i).on("resize"+this.eventns,n),t.timers.forcehide=setTimeout(n,999)},position:function(e){var t=r.getRelOffset(this.element.css({marginTop:0,marginLeft:0,marginRight:0,marginBottom:0}).removeAttr("hidden"),e);t.top+=e.outerHeight(),this.element.css({marginTop:"",marginLeft:"",marginRight:"",marginBottom:""}).css(t)}},r.wsPopover.id=0,r.validityAlert=function(){var t=!1,n=r.objectCreate(r.wsPopover,{},u.messagePopover),s=n.hide.bind(n);return n.element.addClass("validity-alert").attr({role:"alert"}),e.extend(n,{hideDelay:5e3,showFor:function(t,n,r,i){t=e(t).getNativeElement(),this.clear(),this.hide(),i||(this.getMessage(t,n),this.show(t),this.hideDelay&&(this.timers.delayedHide=setTimeout(s,this.hideDelay))),r||this.setFocus(t)},setFocus:function(t){var n=e(t).getShadowFocusElement(),s=r.scrollRoot.scrollTop(),o=n.offset().top-30,u;s>o&&(r.scrollRoot.animate({scrollTop:o-5},{queue:!1,duration:Math.max(Math.min(600,(s-o)*1.5),80)}),u=!0);try{n[0].focus()}catch(a){}u&&(r.scrollRoot.scrollTop(s),setTimeout(function(){r.scrollRoot.scrollTop(s)},0)),e(i).triggerHandler("pospopover"+this.eventns)},getMessage:function(e,t){t||(t=h(e[0])||e.prop("customValidationMessage")||e.prop("validationMessage")),t?n.contentElement.text(t):this.hide()}}),n}(),function(){var t,n=[],r,i;e(s).on("invalid",function(i){if(i.wrongWebkitInvalid)return;var o=e(i.target),u=o.getShadowElement();u.hasClass(E)||(u.addClass(E).removeClass(S),setTimeout(function(){e(i.target).trigger("changedinvalid").trigger("changedvaliditystate")},0));if(!t){t=e.Event("firstinvalid"),t.isInvalidUIPrevented=i.isDefaultPrevented;var a=e.Event("firstinvalidsystem");e(s).triggerHandler(a,{element:i.target,form:i.target.form,isInvalidUIPrevented:i.isDefaultPrevented}),o.trigger(t)}t&&t.isDefaultPrevented()&&i.preventDefault(),n.push(i.target),i.extraData="fix",clearTimeout(r),r=setTimeout(function(){var r={type:"lastinvalid",cancelable:!1,invalidlist:e(n)};t=!1,n=[],e(i.target).trigger(r,r)},9),o=null,u=null})}(),e.fn.getErrorMessage=function(){var t="",n=this[0];return n&&(t=h(n)||e.prop(n,"customValidationMessage")||e.prop(n,"validationMessage")),t},u.replaceValidationUI&&r.ready("DOM forms",function(){e(s).on("firstinvalid",function(t){t.isInvalidUIPrevented()||(t.preventDefault(),e.webshims.validityAlert.showFor(t.target))})})})}(jQuery),jQuery.webshims.register("form-datalist",function(e,t,n,r,i,s){"use strict";var o=r;t.propTypes.element=function(n){t.createPropDefault(n,"attr");if(n.prop)return;n.prop={get:function(){var t=n.attr.get.call(this);return t&&(t=r.getElementById(t),t&&n.propNodeName&&!e.nodeName(t,n.propNodeName)&&(t=null)),t||null},writeable:!1}},function(){var o=e.webshims.cfg.forms,u=Modernizr.input.list;if(u&&!o.customDatalist)return;var a=function(){u||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var n=this,r=e("select",n),i;return r[0]?i=r[0].options:(i=e("option",n).get(),i.length&&t.warn("you should wrap your option-elements for a datalist in a select element to support IE and other old browsers.")),i}}});var n={autocomplete:{attr:{get:function(){var t=this,n=e.data(t,"datalistWidget");return n?n._autocomplete:"autocomplete"in t?t.autocomplete:t.getAttribute("autocomplete")},set:function(t){var n=this,r=e.data(n,"datalistWidget");r?(r._autocomplete=t,t=="off"&&r.hideList()):"autocomplete"in n?n.autocomplete=t:n.setAttribute("autocomplete",t)}}}};o.customDatalist&&(!u||!("selectedOption"in e("<input />")[0]))&&(n.selectedOption={prop:{writeable:!1,get:function(){var t=this,n=e.prop(t,"list"),r=null,i,s;return n?(i=e.prop(t,"value"),i?(s=e.prop(n,"options"),s.length?(e.each(s,function(t,n){if(i==e.prop(n,"value"))return r=n,!1}),r):r):r):r}}}),u?((e("<datalist><select><option></option></select></datalist>").prop("options")||[]).length||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var t=this.options||[];if(!t.length){var n=this,r=e("select",n);r[0]&&r[0].options&&r[0].options.length&&(t=r[0].options)}return t}}}),n.list={attr:{get:function(){var n=t.contentAttr(this,"list");return n!=null?this.removeAttribute("list"):n=e.data(this,"datalistListAttr"),n==null?i:n},set:function(n){var r=this;e.data(r,"datalistListAttr",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"}):n.list={attr:{get:function(){var e=t.contentAttr(this,"list");return e==null?i:e},set:function(n){var r=this;t.contentAttr(r,"list",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"},t.defineNodeNameProperties("input",n),t.addReady(function(t,n){n.filter("datalist > select, datalist, datalist > option, datalist > select > option").closest("datalist").each(function(){var t=e.prop(this,"id");e(this).triggerHandler("updateDatalist")})})},f=0,l={submit:1,button:1,reset:1,hidden:1,range:1,date:1,month:1},c={},h=function(e){if(!e)return[];if(c[e])return c[e];var t;try{t=JSON.parse(localStorage.getItem("storedDatalistOptions"+e))}catch(n){}return c[e]=t||[],t||[]},p=function(e,t){if(!e)return;t=t||[];try{localStorage.setItem("storedDatalistOptions"+e,JSON.stringify(t))}catch(n){}},d=function(t){return t.textContent||t.innerText||e.text([t])||""},v={_create:function(r){if(l[e.prop(r.input,"type")]||l[e.attr(r.input,"type")])return;var i=r.datalist,u=e.data(r.input,"datalistWidget");if(i&&u&&u.datalist!==i){u.datalist=i,u.id=r.id,e(u.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(u,"_resetListCached")),u._resetListCached();return}if(!i){u&&u.destroy();return}if(u&&u.datalist===i)return;f++;var a=this;this.hideList=e.proxy(a,"hideList"),this.datalist=i,this.id=r.id,this.hasViewableData=!0,this._autocomplete=e.attr(r.input,"autocomplete"),e.data(r.input,"datalistWidget",this),this.popover=t.objectCreate(t.wsPopover,{},s.datalistPopover),this.shadowList=this.popover.element.addClass("datalist-polyfill"),this.index=-1,this.input=r.input,this.arrayOptions=[],this.shadowList.delegate("li","mouseenter.datalistWidget mousedown.datalistWidget click.datalistWidget",function(t){var n=e("li:not(.hidden-item)",a.shadowList),i=t.type=="mousedown"||t.type=="click";return a.markItem(n.index(t.currentTarget),i,n),t.type=="click"&&(a.hideList(),o.customDatalist&&e(r.input).trigger("datalistselect")),t.type!="mousedown"}),r.input.setAttribute("autocomplete","off"),e(r.input).attr({"aria-haspopup":"true"}).on({"input.datalistWidget":function(){a.triggeredByDatalist||(a.changedValue=!1,a.showHideOptions())},"keydown.datalistWidget":function(t){var n=t.keyCode,i,s;if(n==40&&!a.showList())return a.markItem(a.index+1,!0),!1;if(!a.popover.isVisible)return;if(n==38)return a.markItem(a.index-1,!0),!1;if(!t.shiftKey&&(n==33||n==36))return a.markItem(0,!0),!1;if(!t.shiftKey&&(n==34||n==35))return s=e("li:not(.hidden-item)",a.shadowList),a.markItem(s.length-1,!0,s),!1;if(n==13||n==27)return n==13&&(i=e("li.active-item:not(.hidden-item)",a.shadowList),a.changeValue(e("li.active-item:not(.hidden-item)",a.shadowList))),a.hideList(),o.customDatalist&&i&&i[0]&&e(r.input).trigger("datalistselect"),!1},"focus.datalistWidget":function(){e(this).hasClass("list-focus")&&a.showList()},"mousedown.datalistWidget":function(){e(this).is(":focus")&&a.showList()}}),e(this.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(this,"_resetListCached")),this._resetListCached(),r.input.form&&(r.input.name||r.input.id)&&e(r.input.form).on("submit.datalistWidget"+r.input.id,function(){if(!e(r.input).hasClass("no-datalist-cache")&&a._autocomplete!="off"){var t=e.prop(r.input,"value"),n=(r.input.name||r.input.id)+e.prop(r.input,"type");a.storedOptions||(a.storedOptions=h(n)),t&&a.storedOptions.indexOf(t)==-1&&(a.storedOptions.push(t),p(n,a.storedOptions))}}),e(n).on("unload.datalist"+this.id+" beforeunload.datalist"+this.id,function(){a.destroy()})},destroy:function(){var t=e.attr(this.input,"autocomplete");e(this.input).off(".datalistWidget").removeData("datalistWidget"),this.shadowList.remove(),e(r).off(".datalist"+this.id),e(n).off(".datalist"+this.id),this.input.form&&this.input.id&&e(this.input.form).off("submit.datalistWidget"+this.input.id),this.input.removeAttribute("aria-haspopup"),t===i?this.input.removeAttribute("autocomplete"):e(this.input).attr("autocomplete",t)},_resetListCached:function(e){var i=this,s;this.needsUpdate=!0,this.lastUpdatedValue=!1,this.lastUnfoundValue="",this.updateTimer||(n.QUnit||(s=e&&r.activeElement==i.input)?i.updateListOptions(s):t.ready("WINDOWLOAD",function(){i.updateTimer=setTimeout(function(){i.updateListOptions(),i=null,f=1},200+100*f)}))},maskHTML:function(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;")},updateListOptions:function(t){this.needsUpdate=!1,clearTimeout(this.updateTimer),this.updateTimer=!1,this.searchStart=o.customDatalist&&e(this.input).hasClass("search-start");var n=[],r=[],i=[],s,u,a,f,l,c;for(a=e.prop(this.datalist,"options"),f=0,l=a.length;f<l;f++){s=a[f];if(s.disabled)return;u={value:e(s).val()||"",text:e.trim(e.attr(s,"label")||d(s)),className:s.className||"",style:e.attr(s,"style")||""},u.text?u.text!=u.value&&(u.className+=" different-label-value"):u.text=u.value,r[f]=u.value,i[f]=u}this.storedOptions||(this.storedOptions=e(this.input).hasClass("no-datalist-cache")||this._autocomplete=="off"?[]:h((this.input.name||this.input.id)+e.prop(this.input,"type"))),this.storedOptions.forEach(function(e,t){r.indexOf(e)==-1&&i.push({value:e,text:e,className:"stored-suggest",style:""})});for(f=0,l=i.length;f<l;f++)c=i[f],n[f]='<li class="'+c.className+'" style="'+c.style+'" tabindex="-1" role="listitem"><span class="option-label">'+this.maskHTML(c.text,"label",c)+'</span> <span class="option-value">'+this.maskHTML(c.value,"value",c)+"</span></li>";this.arrayOptions=i,this.popover.contentElement.html('<div class="datalist-box"><ul role="list">'+n.join("\n")+"</ul></div>"),(t||this.popover.isVisible)&&this.showHideOptions()},showHideOptions:function(t){var n=e.prop(this.input,"value").toLowerCase();if(n===this.lastUpdatedValue||this.lastUnfoundValue&&n.indexOf(this.lastUnfoundValue)===0)return;this.lastUpdatedValue=n;var r=!1,i=this.searchStart,s=e("li",this.shadowList);n?this.arrayOptions.forEach(function(t,o){var u;"lowerText"in t||(t.text!=t.value?t.lowerText=t.value.toLowerCase()+t.text.toLowerCase():t.lowerText=t.text.toLowerCase()),u=t.lowerText.indexOf(n),u=i?!u:u!==-1,u?(e(s[o]).removeClass("hidden-item"),r=!0):e(s[o]).addClass("hidden-item")}):s.length&&(s.removeClass("hidden-item"),r=!0),this.hasViewableData=r,!t&&r&&this.showList(),r||(this.lastUnfoundValue=n,this.hideList())},showList:function(){if(this.popover.isVisible)return!1;this.needsUpdate&&this.updateListOptions(),this.showHideOptions(!0);if(!this.hasViewableData)return!1;var e=this;return e.shadowList.find("li.active-item").removeClass("active-item"),e.popover.show(this.input),!0},hideList:function(){if(!this.popover.isVisible)return!1;var n=this,r=function(t){n.changedValue&&e(n.input).trigger("change"),n.changedValue=!1};return this.popover.hide(),n.shadowList.removeClass("datalist-visible list-item-active"),n.index=-1,n.changedValue&&(n.triggeredByDatalist=!0,t.triggerInlineForm&&t.triggerInlineForm(n.input,"input"),e(n.input).is(":focus")?e(n.input).one("blur",r):r(),n.triggeredByDatalist=!1),!0},scrollIntoView:function(t){var n=e("ul",this.shadowList),r=e("div.datalist-box",this.shadowList),i=t.position(),s;i.top-=(parseInt(n.css("paddingTop"),10)||0)+(parseInt(n.css("marginTop"),10)||0)+(parseInt(n.css("borderTopWidth"),10)||0);if(i.top<0){r.scrollTop(r.scrollTop()+i.top-2);return}i.top+=t.outerHeight(),s=r.height(),i.top>s&&r.scrollTop(r.scrollTop()+(i.top-s)+2)},changeValue:function(t){if(!t[0])return;var n=e("span.option-value",t).text(),r=e.prop(this.input,"value");n!=r&&(e(this.input).prop("value",n).triggerHandler("updateInput"),this.changedValue=!0)},markItem:function(t,n,r){var i,s;r=r||e("li:not(.hidden-item)",this.shadowList);if(!r.length)return;t<0?t=r.length-1:t>=r.length&&(t=0),r.removeClass("active-item"),this.shadowList.addClass("list-item-active"),i=r.filter(":eq("+t+")").addClass("active-item"),n&&(this.changeValue(i),this.scrollIntoView(i)),this.index=t}};a()}()}),function(e,t,n){"use strict";var r=t.audio&&t.video,i=!1,s=n.bugs,o=function(){n.ready(a,function(){n.mediaelement.createSWF||(n.mediaelement.loadSwf=!0,n.reTest([a],r))})},u=n.cfg.mediaelement,a=u&&u.player=="jwplayer"?"mediaelement-swf":"mediaelement-jaris",f;if(!u){n.error("mediaelement wasn't implemented but loaded");return}if(r){var l=document.createElement("video");t.videoBuffered="buffered"in l,i="loop"in l,n.capturingEvents(["play","playing","waiting","paused","ended","durationchange","loadedmetadata","canplay","volumechange"]),t.videoBuffered||(n.addPolyfill("mediaelement-native-fix",{f:"mediaelement",test:t.videoBuffered,d:["dom-support"]}),n.reTest("mediaelement-native-fix"))}if(r&&!u.preferFlash){var c={1:1,2:1},h=function(t){var r,i=t.target.parentNode;!u.preferFlash&&(e(t.target).is("audio, video")||i&&e("source:last",i)[0]==t.target)&&(r=e(t.target).closest("audio, video"))&&!c[r.prop("error")]&&e(function(){f&&!u.preferFlash?(o(),n.ready("WINDOWLOAD "+a,function(){setTimeout(function(){!u.preferFlash&&n.mediaelement.createSWF&&!r.is(".nonnative-api-active")&&(u.preferFlash=!0,document.removeEventListener("error",h,!0),e("audio, video").mediaLoad(),n.info("switching mediaelements option to 'preferFlash', due to an error with native player: "+t.target.src+" Mediaerror: "+r.prop("error")))},9)})):document.removeEventListener("error",h,!0)})};document.addEventListener("error",h,!0),e("audio, video").each(function(){var t=e.prop(this,"error");t&&!c[t]&&h({target:this})})}t.track&&!s.track&&function(){s.track||(s.track=typeof e("<track />")[0].readyState!="number");if(!s.track)try{new TextTrackCue(2,3,"")}catch(t){s.track=!0}var r=n.cfg.track,i=function(t){e(t.target).filter("track").each(o)},o=function(){if(s.track||!r.override&&e.prop(this,"readyState")==3)r.override=!0,n.reTest("track"),document.removeEventListener("error",i,!0),this&&e.nodeName(this,"track")?n.error("track support was overwritten. Please check your vtt including your vtt mime-type"):n.info("track support was overwritten. due to bad browser support")},u=function(){document.addEventListener("error",i,!0),s.track?o():e("track").each(o)};r.override||(n.isReady("track")?u():e(u))}(),n.register("mediaelement-core",function(e,n,l,c,h){f=swfmini.hasFlashPlayerVersion("9.0.115"),e("html").addClass(f?"swf":"no-swf");var p=n.mediaelement;p.parseRtmp=function(e){var t=e.src.split("://"),r=t[1].split("/"),i,s,o;e.server=t[0]+"://"+r[0]+"/",e.streamId=[];for(i=1,s=r.length;i<s;i++)!o&&r[i].indexOf(":")!==-1&&(r[i]=r[i].split(":")[1],o=!0),o?e.streamId.push(r[i]):e.server+=r[i]+"/";e.streamId.length||n.error("Could not parse rtmp url"),e.streamId=e.streamId.join("/")};var d=function(t,n){t=e(t);var r={src:t.attr("src")||"",elem:t,srcProp:t.prop("src")},i;if(!r.src)return r;i=t.attr("data-server"),i!=null&&(r.server=i),i=t.attr("type"),i?(r.type=i,r.container=e.trim(i.split(";")[0])):(n||(n=t[0].nodeName.toLowerCase(),n=="source"&&(n=(t.closest("video, audio")[0]||{nodeName:"video"}).nodeName.toLowerCase())),r.server?(r.type=n+"/rtmp",r.container=n+"/rtmp"):(i=p.getTypeForSrc(r.src,n,r),i&&(r.type=i,r.container=i))),i=t.attr("media"),i&&(r.media=i);if(r.type=="audio/rtmp"||r.type=="video/rtmp")r.server?r.streamId=r.src:p.parseRtmp(r);return r},v=!f&&"postMessage"in l&&r,m=function(){if(m.loaded)return;m.loaded=!0,e(function(){n.loader.loadList(["track-ui"])})},g=function(){var t;return function(){if(t||!v)return;t=!0,n.loader.loadScript("https://www.youtube.com/player_api"),e(function(){n.polyfill("mediaelement-yt")})}}(),y=function(){f?o():g()};n.addPolyfill("mediaelement-yt",{test:!v,d:["dom-support"]}),p.mimeTypes={audio:{"audio/ogg":["ogg","oga","ogm"],'audio/ogg;codecs="opus"':"opus","audio/mpeg":["mp2","mp3","mpga","mpega"],"audio/mp4":["mp4","mpg4","m4r","m4a","m4p","m4b","aac"],"audio/wav":["wav"],"audio/3gpp":["3gp","3gpp"],"audio/webm":["webm"],"audio/fla":["flv","f4a","fla"],"application/x-mpegURL":["m3u8","m3u"]},video:{"video/ogg":["ogg","ogv","ogm"],"video/mpeg":["mpg","mpeg","mpe"],"video/mp4":["mp4","mpg4","m4v"],"video/quicktime":["mov","qt"],"video/x-msvideo":["avi"],"video/x-ms-asf":["asf","asx"],"video/flv":["flv","f4v"],"video/3gpp":["3gp","3gpp"],"video/webm":["webm"],"application/x-mpegURL":["m3u8","m3u"],"video/MP2T":["ts"]}},p.mimeTypes.source=e.extend({},p.mimeTypes.audio,p.mimeTypes.video),p.getTypeForSrc=function(t,n,r){if(t.indexOf("youtube.com/watch?")!=-1||t.indexOf("youtube.com/v/")!=-1)return"video/youtube";if(t.indexOf("rtmp")===0)return n+"/rtmp";t=t.split("?")[0].split("."),t=t[t.length-1];var i;return e.each(p.mimeTypes[n],function(e,n){if(n.indexOf(t)!==-1)return i=e,!1}),i},p.srces=function(t,n){t=e(t);if(!n){n=[];var r=t[0].nodeName.toLowerCase(),i=d(t,r);return i.src?n.push(i):e("source",t).each(function(){i=d(this,r),i.src&&n.push(i)}),n}t.removeAttr("src").removeAttr("type").find("source").remove(),e.isArray(n)||(n=[n]),n.forEach(function(e){var n=c.createElement("source");typeof e=="string"&&(e={src:e}),n.setAttribute("src",e.src),e.type&&n.setAttribute("type",e.type),e.media&&n.setAttribute("media",e.media),t.append(n)})},e.fn.loadMediaSrc=function(t,n){return this.each(function(){n!==h&&(e(this).removeAttr("poster"),n&&e.attr(this,"poster",n)),p.srces(this,t),e(this).mediaLoad()})},p.swfMimeTypes=["video/3gpp","video/x-msvideo","video/quicktime","video/x-m4v","video/mp4","video/m4p","video/x-flv","video/flv","audio/mpeg","audio/aac","audio/mp4","audio/x-m4a","audio/m4a","audio/mp3","audio/x-fla","audio/fla","youtube/flv","jwplayer/jwplayer","video/youtube","video/rtmp","audio/rtmp"],p.canThirdPlaySrces=function(t,n){var r="";if(f||v)t=e(t),n=n||p.srces(t),e.each(n,function(e,t){if(t.container&&t.src&&(f&&p.swfMimeTypes.indexOf(t.container)!=-1||v&&t.container=="video/youtube"))return r=t,!1});return r};var b={};p.canNativePlaySrces=function(t,n){var i="";if(r){t=e(t);var s=(t[0].nodeName||"").toLowerCase(),o=(b[s]||{prop:{_supvalue:!1}}).prop._supvalue||t[0].canPlayType;if(!o)return i;n=n||p.srces(t),e.each(n,function(e,n){if(n.type&&o.call(t[0],n.type))return i=n,!1})}return i},p.setError=function(t,r){r||(r="can't play sources"),e(t).pause().data("mediaerror",r),n.warn("mediaelementError: "+r),setTimeout(function(){e(t).data("mediaerror")&&e(t).trigger("mediaerror")},1)};var w=function(){var e;return function(t,r,i){e||m(),n.ready(f?a:"mediaelement-yt",function(){p.createSWF?p.createSWF(t,r,i):e||(e=!0,y(),w(t,r,i))}),!e&&v&&!p.createSWF&&g()}}(),E=function(e,t,n,r,i){var s;n||n!==!1&&t&&t.isActive=="third"?(s=p.canThirdPlaySrces(e,r),s?w(e,s,t):i?p.setError(e,!1):E(e,t,!1,r,!0)):(s=p.canNativePlaySrces(e,r),s?t&&t.isActive=="third"&&p.setActive(e,"html5",t):i?(p.setError(e,!1),t&&t.isActive=="third"&&p.setActive(e,"html5",t)):E(e,t,!0,r,!0))},S=/^(?:embed|object|datalist)$/i,x=function(t,r){var i=n.data(t,"mediaelementBase")||n.data(t,"mediaelementBase",{}),s=p.srces(t),o=t.parentNode;clearTimeout(i.loadTimer),e.data(t,"mediaerror",!1);if(!s.length||!o||o.nodeType!=1||S.test(o.nodeName||""))return;r=r||n.data(t,"mediaelement"),E(t,r,u.preferFlash||h,s)};e(c).on("ended",function(t){var r=n.data(t.target,"mediaelement");if(i&&(!r||r.isActive=="html5")&&!e.prop(t.target,"loop"))return;setTimeout(function(){if(e.prop(t.target,"paused")||!e.prop(t.target,"loop"))return;e(t.target).prop("currentTime",0).play()},1)}),n.ready("dom-support",function(){i||n.defineNodeNamesBooleanProperty(["audio","video"],"loop"),["audio","video"].forEach(function(t){var i=n.defineNodeNameProperty(t,"load",{prop:{value:function(){var e=n.data(this,"mediaelement");x(this,e),r&&(!e||e.isActive=="html5")&&i.prop._supvalue&&i.prop._supvalue.apply(this,arguments)}}});b[t]=n.defineNodeNameProperty(t,"canPlayType",{prop:{value:function(n){var i="";return r&&b[t].prop._supvalue&&(i=b[t].prop._supvalue.call(this,n),i=="no"&&(i="")),!i&&f&&(n=e.trim((n||"").split(";")[0]),p.swfMimeTypes.indexOf(n)!=-1&&(i="maybe")),i}}})}),n.onNodeNamesPropertyModify(["audio","video"],["src","poster"],{set:function(){var e=this,t=n.data(e,"mediaelementBase")||n.data(e,"mediaelementBase",{});clearTimeout(t.loadTimer),t.loadTimer=setTimeout(function(){x(e),e=null},9)}})});var T=function(){var t=function(){x(this);if(r){var t,n,i=this,s=function(){var t=e.prop(i,"buffered");if(!t)return;var n="";for(var r=0,s=t.length;r<s;r++)n+=t.end(r);return n},o=function(){var t=s();t!=n&&(n=t,e(i).triggerHandler("progress"))};e(this).on({"play loadstart progress":function(e){e.type=="progress"&&(n=s()),clearTimeout(t),t=setTimeout(o,999)},"emptied stalled mediaerror abort suspend":function(e){e.type=="emptied"&&(n=!1),clearTimeout(t)}})}},i=!1;n.ready("dom-support",function(){i=!0,n.addReady(function(n,r){var i=e("video, audio",n).add(r.filter("video, audio")).each(t);!m.loaded&&e("track",i).length&&m(),i=null})}),r&&!i&&n.addReady(function(t,n){i||e("video, audio",t).add(n.filter("video, audio")).each(function(){if(!p.canNativePlaySrces(this)||!m.loaded&&e("track",this).length)return y(),i=!0,!1})})};t.track&&!s.track&&n.defineProperty(TextTrack.prototype,"shimActiveCues",{get:function(){return this._shimActiveCues||this.activeCues}}),r?(n.isReady("mediaelement-core",!0),T(),n.ready("WINDOWLOAD mediaelement",y)):n.ready(a,T),n.ready("WINDOWLOAD mediaelement",m)})}(jQuery,Modernizr,jQuery.webshims);
View
2  demos/js-webshim/minified/shims/combos/3.js
@@ -1 +1 @@
-jQuery.webshims.register("dom-extend",function(e,t,n,r,i){"use strict";var s=t.modules,o=/\s*,\s*/,u={},a={},f={},l={},c={},h=e.fn.val,p=function(t,n,r,i,s){return s?h.call(e(t)):h.call(e(t),r)};e.fn.val=function(t){var n=this[0];arguments.length&&t==null&&(t="");if(!arguments.length)return!n||n.nodeType!==1?h.call(this):e.prop(n,"value",t,"val",!0);if(e.isArray(t))return h.apply(this,arguments);var r=e.isFunction(t);return this.each(function(s){n=this;if(n.nodeType===1)if(r){var o=t.call(n,s,e.prop(n,"value",i,"val",!0));o==null&&(o=""),e.prop(n,"value",o,"val")}else e.prop(n,"value",t,"val")})},e.fn.onTrigger=function(e,t){return this.on(e,t).each(t)};var d="_webshimsLib"+Math.round(Math.random()*1e3),v=function(t,n,r){t=t.jquery?t[0]:t;if(!t)return r||{};var s=e.data(t,d);return r!==i&&(s||(s=e.data(t,d,{})),n&&(s[n]=r)),n?s&&s[n]:s};[{name:"getNativeElement",prop:"nativeElement"},{name:"getShadowElement",prop:"shadowElement"},{name:"getShadowFocusElement",prop:"shadowFocusElement"}].forEach(function(t){e.fn[t.name]=function(){return this.map(function(){var e=v(this,"shadowData");return e&&e[t.prop]||this})}}),["removeAttr","prop","attr"].forEach(function(n){u[n]=e[n],e[n]=function(t,r,s,o,l){var h=o=="val",d=h?p:u[n];if(!t||!a[r]||t.nodeType!==1||!h&&o&&n=="attr"&&e.attrFn[r])return d(t,r,s,o,l);var v=(t.nodeName||"").toLowerCase(),m=f[v],g=n!="attr"||s!==!1&&s!==null?n:"removeAttr",y,b,w;m||(m=f["*"]),m&&(m=m[r]),m&&(y=m[g]);if(y){r=="value"&&(b=y.isVal,y.isVal=h);if(g==="removeAttr")return y.value.call(t);if(s===i)return y.get?y.get.call(t):y.value;y.set&&(n=="attr"&&s===!0&&(s=r),w=y.set.call(t,s)),r=="value"&&(y.isVal=b)}else w=d(t,r,s,o,l);if((s!==i||g==="removeAttr")&&c[v]&&c[v][r]){var E;g=="removeAttr"?E=!1:g=="prop"?E=!!s:E=!0,c[v][r].forEach(function(e){(!e.only||(e.only=n=="prop")||e.only=="attr"&&n!="prop")&&e.call(t,s,E,h?"val":g,n)})}return w},l[n]=function(r,s,o){f[r]||(f[r]={}),f[r][s]||(f[r][s]={});var a=f[r][s][n],l=function(e,t,r){return t&&t[e]?t[e]:r&&r[e]?r[e]:n=="prop"&&s=="value"?function(e){var t=this;return o.isVal?p(t,s,e,!1,arguments.length===0):u[n](t,s,e)}:n=="prop"&&e=="value"&&o.value.apply?function(e){var t=u[n](this,s);return t&&t.apply&&(t=t.apply(this,arguments)),t}:function(e){return u[n](this,s,e)}};f[r][s][n]=o,o.value===i&&(o.set||(o.set=o.writeable?l("set",o,a):t.cfg.useStrict&&s=="prop"?function(){throw s+" is readonly on "+r}:e.noop),o.get||(o.get=l("get",o,a))),["value","get","set"].forEach(function(e){o[e]&&(o["_sup"+e]=l(e,a))})}});var m=function(){var e=t.getPrototypeOf(r.createElement("foobar")),n=Object.prototype.hasOwnProperty,i=Modernizr.advancedObjectProperties&&Modernizr.objectAccessor;return function(s,o,u){var a,f;if(i&&(a=r.createElement(s))&&(f=t.getPrototypeOf(a))&&e!==f&&(!a[o]||!n.call(a,o))){var l=a[o];u._supvalue=function(){return l&&l.apply?l.apply(this,arguments):l},f[o]=u.value}else u._supvalue=function(){var e=v(this,"propValue");return e&&e[o]&&e[o].apply?e[o].apply(this,arguments):e&&e[o]},g.extendValue(s,o,u.value);u.value._supvalue=u._supvalue}}(),g=function(){var n={};t.addReady(function(r,i){var s={},o=function(t){s[t]||(s[t]=e(r.getElementsByTagName(t)),i[0]&&e.nodeName(i[0],t)&&(s[t]=s[t].add(i)))};e.each(n,function(e,n){o(e);if(!n||!n.forEach){t.warn("Error: with "+e+"-property. methods: "+n);return}n.forEach(function(t){s[e].each(t)})}),s=null});var i,s=e([]),o=function(t,s){n[t]?n[t].push(s):n[t]=[s],e.isDOMReady&&(i||e(r.getElementsByTagName(t))).each(s)},u={};return{createTmpCache:function(t){return e.isDOMReady&&(i=i||e(r.getElementsByTagName(t))),i||s},flushTmpCache:function(){i=null},content:function(t,n){o(t,function(){var t=e.attr(this,n);t!=null&&e.attr(this,n,t)})},createElement:function(e,t){o(e,t)},extendValue:function(t,n,r){o(t,function(){e(this).each(function(){var e=v(this,"propValue",{});e[n]=this[n],this[n]=r})})}}}(),y=function(e,t){e.defaultValue===i&&(e.defaultValue=""),e.removeAttr||(e.removeAttr={value:function(){e[t||"prop"].set.call(this,e.defaultValue),e.removeAttr._supvalue.call(this)}}),e.attr||(e.attr={})};e.extend(t,{getID:function(){var t=(new Date).getTime();return function(n){n=e(n);var r=n.attr("id");return r||(t++,r="ID-"+t,n.attr("id",r)),r}}(),extendUNDEFProp:function(t,n){e.each(n,function(e,n){e in t||(t[e]=n)})},createPropDefault:y,data:v,moveToFirstEvent:function(t,n,r){var i=(e._data(t,"events")||{})[n],s;i&&i.length>1&&(s=i.pop(),r||(r="bind"),r=="bind"&&i.delegateCount?i.splice(i.delegateCount,0,s):i.unshift(s)),t=null},addShadowDom:function(){var i,s,o,u={init:!1,runs:0,test:function(){var e=u.getHeight(),t=u.getWidth();e!=u.height||t!=u.width?(u.height=e,u.width=t,u.handler({type:"docresize"}),u.runs++,u.runs<9&&setTimeout(u.test,90)):u.runs=0},handler:function(t){clearTimeout(i),i=setTimeout(function(){if(t.type=="resize"){var i=e(n).width(),a=e(n).width();if(a==s&&i==o)return;s=a,o=i,u.height=u.getHeight(),u.width=u.getWidth()}e(r).triggerHandler("updateshadowdom")},t.type=="resize"?50:9)},_create:function(){e.each({Height:"getHeight",Width:"getWidth"},function(e,t){var n=r.body,i=r.documentElement;u[t]=function(){return Math.max(n["scroll"+e],i["scroll"+e],n["offset"+e],i["offset"+e],i["client"+e])}})},start:function(){!this.init&&r.body&&(this.init=!0,this._create(),this.height=u.getHeight(),this.width=u.getWidth(),setInterval(this.test,600),e(this.test),t.ready("WINDOWLOAD",this.test),e(n).bind("resize",this.handler),function(){var t=e.fn.animate,n;e.fn.animate=function(){return clearTimeout(n),n=setTimeout(function(){u.test()},99),t.apply(this,arguments)}}())}};return t.docObserve=function(){t.ready("DOM",function(){u.start()})},function(n,r,i){i=i||{},n.jquery&&(n=n[0]),r.jquery&&(r=r[0]);var s=e.data(n,d)||e.data(n,d,{}),o=e.data(r,d)||e.data(r,d,{}),u={};i.shadowFocusElement?i.shadowFocusElement&&(i.shadowFocusElement.jquery&&(i.shadowFocusElement=i.shadowFocusElement[0]),u=e.data(i.shadowFocusElement,d)||e.data(i.shadowFocusElement,d,u)):i.shadowFocusElement=r,s.hasShadow=r,u.nativeElement=o.nativeElement=n,u.shadowData=o.shadowData=s.shadowData={nativeElement:n,shadowElement:r,shadowFocusElement:i.shadowFocusElement},i.shadowChilds&&i.shadowChilds.each(function(){v(this,"shadowData",o.shadowData)}),i.data&&(u.shadowData.data=o.shadowData.data=s.shadowData.data=i.data),i=null,t.docObserve()}}(),propTypes:{standard:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,""+t)},get:function(){return e.attr.get.call(this)||e.defaultValue}}},"boolean":function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){t?e.attr.set.call(this,""):e.removeAttr.value.call(this)},get:function(){return e.attr.get.call(this)!=null}}},src:function(){var t=r.createElement("a");return t.style.display="none",function(n,r){y(n);if(n.prop)return;n.prop={set:function(e){n.attr.set.call(this,e)},get:function(){var n=this.getAttribute(r),i;if(n==null)return"";t.setAttribute("href",n+"");if(!e.support.hrefNormalized){try{e(t).insertAfter(this),i=t.getAttribute("href",4)}catch(s){i=t.getAttribute("href",4)}e(t).detach()}return i||t.href}}}}(),enumarated:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,t)},get:function(){var t=(e.attr.get.call(this)||"").toLowerCase();if(!t||e.limitedTo.indexOf(t)==-1)t=e.defaultValue;return t}}}},reflectProperties:function(n,r){typeof r=="string"&&(r=r.split(o)),r.forEach(function(r){t.defineNodeNamesProperty(n,r,{prop:{set:function(t){e.attr(this,r,t)},get:function(){return e.attr(this,r)||""}}})})},defineNodeNameProperty:function(n,r,i){return a[r]=!0,i.reflect&&t.propTypes[i.propType||"standard"](i,r),["prop","attr","removeAttr"].forEach(function(s){var o=i[s];o&&(s==="prop"?o=e.extend({writeable:!0},o):o=e.extend({},o,{writeable:!0}),l[s](n,r,o),n!="*"&&t.cfg.extendNative&&s=="prop"&&o.value&&e.isFunction(o.value)&&m(n,r,o),i[s]=o)}),i.initAttr&&g.content(n,r),i},defineNodeNameProperties:function(e,n,r,i){var s;for(var o in n)!i&&n[o].initAttr&&g.createTmpCache(e),r&&(n[o][r]||(n[o][r]={},["value","set","get"].forEach(function(e){e in n[o]&&(n[o][r][e]=n[o][e],delete n[o][e])}))),n[o]=t.defineNodeNameProperty(e,o,n[o]);return i||g.flushTmpCache(),n},createElement:function(n,r,i){var s;return e.isFunction(r)&&(r={after:r}),g.createTmpCache(n),r.before&&g.createElement(n,r.before),i&&(s=t.defineNodeNameProperties(n,i,!1,!0)),r.after&&g.createElement(n,r.after),g.flushTmpCache(),s},onNodeNamesPropertyModify:function(t,n,r,i){typeof t=="string"&&(t=t.split(o)),e.isFunction(r)&&(r={set:r}),t.forEach(function(e){c[e]||(c[e]={}),typeof n=="string"&&(n=n.split(o)),r.initAttr&&g.createTmpCache(e),n.forEach(function(t){c[e][t]||(c[e][t]=[],a[t]=!0),r.set&&(i&&(r.set.only=i),c[e][t].push(r.set)),r.initAttr&&g.content(e,t)}),g.flushTmpCache()})},defineNodeNamesBooleanProperty:function(n,r,s){s||(s={}),e.isFunction(s)&&(s.set=s),t.defineNodeNamesProperty(n,r,{attr:{set:function(e){this.setAttribute(r,e),s.set&&s.set.call(this,!0)},get:function(){var e=this.getAttribute(r);return e==null?i:r}},removeAttr:{value:function(){this.removeAttribute(r),s.set&&s.set.call(this,!1)}},reflect:!0,propType:"boolean",initAttr:s.initAttr||!1})},contentAttr:function(e,t,n){if(!e.nodeName)return;var r;if(n===i)return r=e.attributes[t]||{},n=r.specified?r.value:null,n==null?i:n;typeof n=="boolean"?n?e.setAttribute(t,t):e.removeAttribute(t):e.setAttribute(t,n)},activeLang:function(){var n=[],r={},i,o,u=/:\/\/|^\.*\//,a=function(n,r,i){var s;return r&&i&&e.inArray(r,i.availabeLangs||[])!==-1?(n.loading=!0,s=i.langSrc,u.test(s)||(s=t.cfg.basePath+s),t.loader.loadScript(s+r+".js",function(){n.langObj[r]?(n.loading=!1,l(n,!0)):e(function(){n.langObj[r]&&l(n,!0),n.loading=!1})}),!0):!1},f=function(e){r[e]&&r[e].forEach(function(e){e.callback(i,o,"")})},l=function(e,t){if(e.activeLang!=i&&e.activeLang!==o){var n=s[e.module].options;e.langObj[i]||o&&e.langObj[o]?(e.activeLang=i,e.callback(e.langObj[i]||e.langObj[o],i),f(e.module)):!t&&!a(e,i,n)&&!a(e,o,n)&&e.langObj[""]&&e.activeLang!==""&&(e.activeLang="",e.callback(e.langObj[""],i),f(e.module))}},c=function(t){return typeof t=="string"&&t!==i?(i=t,o=i.split("-")[0],i==o&&(o=!1),e.each(n,function(e,t){l(t)})):typeof t=="object"&&(t.register?(r[t.register]||(r[t.register]=[]),r[t.register].push(t),t.callback(i,o,"")):(t.activeLang||(t.activeLang=""),n.push(t),l(t))),i};return c}()}),e.each({defineNodeNamesProperty:"defineNodeNameProperty",defineNodeNamesProperties:"defineNodeNameProperties",createElements:"createElement"},function(e,n){t[e]=function(e,r,i,s){typeof e=="string"&&(e=e.split(o));var u={};return e.forEach(function(e){u[e]=t[n](e,r,i,s)}),u}}),t.isReady("webshimLocalization",!0)}),function(e,t){if(!Modernizr.localstorage||"hidden"in t.createElement("a"))return;var n={article:"article",aside:"complementary",section:"region",nav:"navigation",address:"contentinfo"},r=function(e,t){var n=e.getAttribute("role");n||e.setAttribute("role",t)};e.webshims.addReady(function(i,s){e.each(n,function(t,n){var o=e(t,i).add(s.filter(t));for(var u=0,a=o.length;u<a;u++)r(o[u],n)});if(i===t){var o=t.getElementsByTagName("header")[0],u=t.getElementsByTagName("footer"),a=u.length;o&&!e(o).closest("section, article")[0]&&r(o,"banner");if(!a)return;var f=u[a-1];e(f).closest("section, article")[0]||r(f,"contentinfo")}})}(jQuery,document),function(e){"use strict";var t="webkitURL"in window,n=window.Modernizr,r=e.webshims,i=r.bugs,s=e('<form action="#" style="width: 1px; height: 1px; overflow: hidden;"><select name="b" required="" /><input required="" name="a" /></form>'),o=function(){if(s[0].querySelector)try{i.findRequired=!s[0].querySelector("select:required")}catch(e){i.findRequired=!1}},u=e("input",s).eq(0),a=function(e){r.loader.loadList(["dom-extend"]),r.ready("dom-extend",e)};i.findRequired=!1,i.validationMessage=!1,r.capturingEventPrevented=function(t){if(!t._isPolyfilled){var n=t.isDefaultPrevented,r=t.preventDefault;t.preventDefault=function(){return clearTimeout(e.data(t.target,t.type+"DefaultPrevented")),e.data(t.target,t.type+"DefaultPrevented",setTimeout(function(){e.removeData(t.target,t.type+"DefaultPrevented")},30)),r.apply(this,arguments)},t.isDefaultPrevented=function(){return!!(n.apply(this,arguments)||e.data(t.target,t.type+"DefaultPrevented")||!1)},t._isPolyfilled=!0}};if(!n.formvalidation||i.bustedValidity)o();else{r.capturingEvents(["input"]),r.capturingEvents(["invalid"],!0);if(window.opera||window.testGoodWithFix)s.appendTo("head"),o(),i.validationMessage=!u.prop("validationMessage"),r.reTest(["form-native-extend","form-message"]),s.remove(),e(function(){a(function(){var t=function(e){e.preventDefault()};["form","input","textarea","select"].forEach(function(n){var i=r.defineNodeNameProperty(n,"checkValidity",{prop:{value:function(){r.fromSubmit||e(this).on("invalid.checkvalidity",t),r.fromCheckValidity=!0;var n=i.prop._supvalue.apply(this,arguments);return r.fromSubmit||e(this).unbind("invalid.checkvalidity",t),r.fromCheckValidity=!1,n}}})})})});t&&!r.bugs.bustedValidity&&function(){var t=/^(?:textarea|input)$/i,n=!1;document.addEventListener("contextmenu",function(e){t.test(e.target.nodeName||"")&&(n=e.target.form)&&setTimeout(function(){n=!1},1)},!1),e(window).on("invalid",function(e){e.originalEvent&&n&&n==e.target.form&&(e.wrongWebkitInvalid=!0,e.stopImmediatePropagation())})}()}e.webshims.register("form-core",function(e,r,i,s,o,u){var a={checkbox:1,radio:1},f=e([]),l=r.bugs,c=function(t){t=e(t);var n,r,i=f;return t[0].type=="radio"&&(r=t.prop("form"),n=t[0].name,n?r?i=e(r[n]):i=e(s.getElementsByName(n)).filter(function(){return!e.prop(this,"form")}):i=t,i=i.filter('[type="radio"]')),i},h=r.getContentValidationMessage=function(t,n,r){var i=e(t).data("errormessage")||t.getAttribute("x-moz-errormessage")||"";return r&&i[r]&&(i=i[r]),typeof i=="object"&&(n=n||e.prop(t,"validity")||{valid:1},n.valid||e.each(n,function(e,t){if(t&&e!="valid"&&i[e])return i=i[e],!1})),typeof i=="object"&&(i=i.defaultMessage),i||""},p={number:1,range:1,date:1},d=function(t){var n=!1;return e(e.prop(t,"elements")).each(function(){n=e(this).is(":invalid");if(n)return!1}),n};e.extend(e.expr[":"],{"valid-element":function(t){return e.nodeName(t,"form")?!d(t):!!e.prop(t,"willValidate")&&!!m(t)},"invalid-element":function(t){return e.nodeName(t,"form")?d(t):!!e.prop(t,"willValidate")&&!m(t)},"required-element":function(t){return!!e.prop(t,"willValidate")&&!!e.prop(t,"required")},"user-error":function(t){return e.prop(t,"willValidate")&&e(t).hasClass("user-error")},"optional-element":function(t){return!!e.prop(t,"willValidate")&&e.prop(t,"required")===!1},"in-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!!(n&&!n.rangeOverflow&&!n.rangeUnderflow)},"out-of-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!(!n||!n.rangeOverflow&&!n.rangeUnderflow)}}),["valid","invalid","required","optional"].forEach(function(t){e.expr[":"][t]=e.expr.filters[t+"-element"]}),e.expr[":"].focus=function(e){try{var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())}catch(n){}return!1};var v=e.event.customEvent||{},m=function(t){return(e.prop(t,"validity")||{valid:1}).valid};(l.bustedValidity||l.findRequired)&&function(){var t=e.find,r=e.find.matchesSelector,i=/(\:valid|\:invalid|\:optional|\:required|\:in-range|\:out-of-range)(?=[\s\[\~\.\+\>\:\#*]|$)/ig,o=function(e){return e+"-element"};e.find=function(){var e=Array.prototype.slice,n=function(n){var r=arguments;return r=e.call(r,1,r.length),r.unshift(n.replace(i,o)),t.apply(this,r)};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}();if(!n.prefixed||n.prefixed("matchesSelector",s.documentElement))e.find.matchesSelector=function(e,t){return t=t.replace(i,o),r.call(this,e,t)}}();var g=e.prop,y={selectedIndex:1,value:1,checked:1,disabled:1,readonly:1};e.prop=function(t,n,r){var i=g.apply(this,arguments);return t&&"form"in t&&y[n]&&r!==o&&e(t).hasClass(E)&&m(t)&&(e(t).getShadowElement().removeClass(E),n=="checked"&&r&&c(t).not(t).removeClass(E).removeAttr("aria-invalid")),i};var b=function(t,n){var r;return e.each(t,function(t,i){if(i)return r=t=="customError"?e.prop(n,"validationMessage"):t,!1}),r},w=function(e){var t;try{t=s.activeElement.name===e}catch(n){}return t},E="user-error",S="user-success",x=function(t){var n,r;if(!t.target)return;n=e(t.target).getNativeElement()[0];if(n.type=="submit"||!e.prop(n,"willValidate"))return;r=e.data(n,"webshimsswitchvalidityclass");var i=function(){if(t.type=="focusout"&&n.type=="radio"&&w(n.name))return;var r=e.prop(n,"validity"),i=e(n).getShadowElement(),s,o,u,f,l;e(n).trigger("refreshCustomValidityRules"),r.valid?i.hasClass(S)||(s=S,o=E,f="changedvaliditystate",u="changedvalid",a[n.type]&&n.checked&&c(n).not(n).removeClass(o).addClass(s).removeAttr("aria-invalid"),e.removeData(n,"webshimsinvalidcause")):(l=b(r,n),e.data(n,"webshimsinvalidcause")!=l&&(e.data(n,"webshimsinvalidcause",l),f="changedvaliditystate"),i.hasClass(E)||(s=E,o=S,a[n.type]&&!n.checked&&c(n).not(n).removeClass(o).addClass(s),u="changedinvalid")),s&&(i.addClass(s).removeClass(o),setTimeout(function(){e(n).trigger(u)},0)),f&&setTimeout(function(){e(n).trigger(f)},0),e.removeData(t.target,"webshimsswitchvalidityclass")};r&&clearTimeout(r),t.type=="refreshvalidityui"?i():e.data(n,"webshimsswitchvalidityclass",setTimeout(i,9))};e(s).on(u.validityUIEvents||"focusout change refreshvalidityui",x),v.changedvaliditystate=!0,v.refreshCustomValidityRules=!0,v.changedvalid=!0,v.changedinvalid=!0,v.refreshvalidityui=!0,r.triggerInlineForm=function(t,n){e(t).trigger(n)},r.modules["form-core"].getGroupElements=c;var T=function(){r.scrollRoot=t||s.compatMode=="BackCompat"?e(s.body):e(s.documentElement)};T(),r.ready("DOM",T),r.getRelOffset=function(t,n){t=e(t);var r=e(n).offset(),i;return e.swap(e(t)[0],{visibility:"hidden",display:"inline-block",left:0,top:0},function(){i=t.offset()}),r.top-=i.top,r.left-=i.left,r},r.wsPopover={_create:function(){this.options=e.extend({},r.cfg.wspopover,this.options),this.id=r.wsPopover.id++,this.eventns=".wsoverlay"+this.id,this.timers={},this.element=e('<div class="ws-popover" tabindex="-1"><div class="ws-po-outerbox"><div class="ws-po-arrow"><div class="ws-po-arrowbox" /></div><div class="ws-po-box" /></div></div>'),this.contentElement=e(".ws-po-box",this.element),this.lastElement=e([]),this.bindElement(),this.options.prepareFor&&this.prepareFor(e(this.options.prepareFor).getNativeElement(),e(this.options.prepareFor).getShadowElement()),this.element.data("wspopover",this)},options:{},content:function(e){this.contentElement.html(e)},bindElement:function(){var e=this,t=function(){e.stopBlur=!1};this.element.on({mousedown:function(n){e.stopBlur=!0,e.timers.stopBlur=setTimeout(t,9)}})},isInElement:function(t,n){return t==n||e.contains(t,n)},show:function(t){if(this.isVisible)return;this.isVisible=!0,t=e(t).getNativeElement();var n=this,r=e(t).getShadowElement();this.clear(),this.element.removeClass("ws-po-visible").css("display","none"),this.options.prepareFor||this.prepareFor(t,r),this.position(r),n.timers.show=setTimeout(function(){n.element.css("display",""),n.timers.show=setTimeout(function(){n.element.addClass("ws-po-visible")},9)},9),e(s).on("focusin"+this.eventns+" mousedown"+this.eventns,function(e){n.options.hideOnBlur&&!n.stopBlur&&!n.isInElement(n.lastElement[0]||s.body,e.target)&&!n.isInElement(n.element[0],e.target)&&n.hide()}),e(i).on("resize"+this.eventns+" pospopover"+this.eventns,function(){clearTimeout(n.timers.repos),n.timers.repos=setTimeout(function(){n.position(r)},900)})},prepareFor:function(t,n){var r,i=e.extend({},this.options,e(t.prop("form")||[]).data("wspopover")||{},t.data("wspopover")),s=this;this.lastElement=e(t).getShadowFocusElement(),i.appendTo=="element"?this.element.insertAfter(t):this.element.appendTo(i.appendTo),this.element.attr({"data-class":t.prop("className"),"data-id":t.prop("id")}),this.element.css({width:i.constrainWidth?n.outerWidth():""}),i.hideOnBlur&&(r=function(e){s.stopBlur?e.stopImmediatePropagation():s.hide()},this.options.prepareFor?s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r).data("preparedpopover",s):s.timers.bindBlur=setTimeout(function(){s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r)},10)),this.prepared||(this.options.prepareFor&&this.element.css("display","none"),e.fn.bgIframe&&this.element.bgIframe()),this.prepared=!0},clear:function(){e(i).off(this.eventns),e(s).off(this.eventns),this.options.prepareFor||this.lastElement.off(this.eventns),this.stopBlur=!1,e.each(this.timers,function(e,t){clearTimeout(t)})},hide:function(){if(!this.isVisible)return;this.isVisible=!1;var t=this,n=function(){t.element.css("display","none").attr({"data-id":"","data-class":"",hidden:"hidden"}),clearTimeout(t.timers.forcehide)};this.clear(),this.element.removeClass("ws-po-visible"),e(i).on("resize"+this.eventns,n),t.timers.forcehide=setTimeout(n,999)},position:function(e){var t=r.getRelOffset(this.element.css({marginTop:0,marginLeft:0,marginRight:0,marginBottom:0}).removeAttr("hidden"),e);t.top+=e.outerHeight(),this.element.css({marginTop:"",marginLeft:"",marginRight:"",marginBottom:""}).css(t)}},r.wsPopover.id=0,r.validityAlert=function(){var t=!1,n=r.objectCreate(r.wsPopover,{},u.messagePopover),s=n.hide.bind(n);return n.element.addClass("validity-alert").attr({role:"alert"}),e.extend(n,{hideDelay:5e3,showFor:function(t,n,r,i){t=e(t).getNativeElement(),this.clear(),this.hide(),i||(this.getMessage(t,n),this.show(t),this.hideDelay&&(this.timers.delayedHide=setTimeout(s,this.hideDelay))),r||this.setFocus(t)},setFocus:function(t){var n=e(t).getShadowFocusElement(),s=r.scrollRoot.scrollTop(),o=n.offset().top-30,u;s>o&&(r.scrollRoot.animate({scrollTop:o-5},{queue:!1,duration:Math.max(Math.min(600,(s-o)*1.5),80)}),u=!0);try{n[0].focus()}catch(a){}u&&(r.scrollRoot.scrollTop(s),setTimeout(function(){r.scrollRoot.scrollTop(s)},0)),e(i).triggerHandler("pospopover"+this.eventns)},getMessage:function(e,t){t||(t=h(e[0])||e.prop("customValidationMessage")||e.prop("validationMessage")),t?n.contentElement.text(t):this.hide()}}),n}(),function(){var t,n=[],r,i;e(s).on("invalid",function(i){if(i.wrongWebkitInvalid)return;var o=e(i.target),u=o.getShadowElement();u.hasClass(E)||(u.addClass(E).removeClass(S),setTimeout(function(){e(i.target).trigger("changedinvalid").trigger("changedvaliditystate")},0));if(!t){t=e.Event("firstinvalid"),t.isInvalidUIPrevented=i.isDefaultPrevented;var a=e.Event("firstinvalidsystem");e(s).triggerHandler(a,{element:i.target,form:i.target.form,isInvalidUIPrevented:i.isDefaultPrevented}),o.trigger(t)}t&&t.isDefaultPrevented()&&i.preventDefault(),n.push(i.target),i.extraData="fix",clearTimeout(r),r=setTimeout(function(){var r={type:"lastinvalid",cancelable:!1,invalidlist:e(n)};t=!1,n=[],e(i.target).trigger(r,r)},9),o=null,u=null})}(),e.fn.getErrorMessage=function(){var t="",n=this[0];return n&&(t=h(n)||e.prop(n,"customValidationMessage")||e.prop(n,"validationMessage")),t},u.replaceValidationUI&&r.ready("DOM forms",function(){e(s).on("firstinvalid",function(t){t.isInvalidUIPrevented()||(t.preventDefault(),e.webshims.validityAlert.showFor(t.target))})})})}(jQuery),jQuery.webshims.register("form-message",function(e,t,n,r,i,s){"use strict";var o=t.validityMessages,u=s.overrideMessages||s.customMessages?["customValidationMessage"]:[];o.en=e.extend(!0,{typeMismatch:{email:"Please enter an email address.",url:"Please enter a URL.",number:"Please enter a number.",date:"Please enter a date.",time:"Please enter a time.",range:"Invalid input.","datetime-local":"Please enter a datetime."},rangeUnderflow:{defaultMessage:"Value must be greater than or equal to {%min}."},rangeOverflow:{defaultMessage:"Value must be less than or equal to {%max}."},stepMismatch:"Invalid input.",tooLong:"Please enter at most {%maxlength} character(s). You entered {%valueLen}.",patternMismatch:"Invalid input. {%title}",valueMissing:{defaultMessage:"Please fill out this field.",checkbox:"Please check this box if you want to proceed."}},o.en||o["en-US"]||{}),["select","radio"].forEach(function(e){typeof o["en"].valueMissing=="object"&&(o.en.valueMissing[e]="Please select an option.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeUnderflow=="object"&&(o.en.rangeUnderflow[e]="Value must be at or after {%min}.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeOverflow=="object"&&(o.en.rangeOverflow[e]="Value must be at or before {%max}.")}),o["en-US"]=o["en-US"]||o.en,o[""]=o[""]||o["en-US"],o.de=e.extend(!0,{typeMismatch:{email:"{%value} ist keine zul\u00e4ssige E-Mail-Adresse",url:"{%value} ist keine zul\u00e4ssige Webadresse",number:"{%value} ist keine Nummer!",date:"{%value} ist kein Datum",time:"{%value} ist keine Uhrzeit",range:"{%value} ist keine Nummer!","datetime-local":"{%value} ist kein Datum-Uhrzeit Format."},rangeUnderflow:{defaultMessage:"{%value} ist zu niedrig. {%min} ist der unterste Wert, den Sie benutzen k\u00f6nnen."},rangeOverflow:{defaultMessage:"{%value} ist zu hoch. {%max} ist der oberste Wert, den Sie benutzen k\u00f6nnen."},stepMismatch:"Der Wert {%value} ist in diesem Feld nicht zul\u00e4ssig. Hier sind nur bestimmte Werte zul\u00e4ssig. {%title}",tooLong:"Der eingegebene Text ist zu lang! Sie haben {%valueLen} Zeichen eingegeben, dabei sind {%maxlength} das Maximum.",patternMismatch:"{%value} hat f\u00fcr dieses Eingabefeld ein falsches Format! {%title}",valueMissing:{defaultMessage:"Bitte geben Sie einen Wert ein",checkbox:"Bitte aktivieren Sie das K\u00e4stchen"}},o.de||{}),["select","radio"].forEach(function(e){typeof o.de.valueMissing=="object"&&(o.de.valueMissing[e]="Bitte w\u00e4hlen Sie eine Option aus")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeUnderflow=="object"&&(o.de.rangeUnderflow[e]="{%value} ist zu fr\u00fch. {%min} ist die fr\u00fcheste Zeit, die Sie benutzen k\u00f6nnen.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeOverflow=="object"&&(o.de.rangeOverflow[e]="{%value} ist zu sp\u00e4t. {%max} ist die sp\u00e4teste Zeit, die Sie benutzen k\u00f6nnen.")});var a=o[""];t.createValidationMessage=function(n,r){var i=a[r];return i&&typeof i!="string"&&(i=i[e.prop(n,"type")]||i[(n.nodeName||"").toLowerCase()]||i.defaultMessage),i&&["value","min","max","title","maxlength","label"].forEach(function(s){if(i.indexOf("{%"+s)===-1)return;var o=(s=="label"?e.trim(e('label[for="'+n.id+'"]',n.form).text()).replace(/\*$|:$/,""):e.attr(n,s))||"";r=="patternMismatch"&&s=="title"&&!o&&t.error("no title for patternMismatch provided. Always add a title attribute."),i=i.replace("{%"+s+"}",o),"value"==s&&(i=i.replace("{%valueLen}",o.length))}),i||""},(t.bugs.validationMessage||!Modernizr.formvalidation||t.bugs.bustedValidity)&&u.push("validationMessage"),t.activeLang({langObj:o,module:"form-core",callback:function(e){a=e}}),u.forEach(function(n){t.defineNodeNamesProperty(["fieldset","output","button"],n,{prop:{value:"",writeable:!1}}),["input","select","textarea"].forEach(function(r){var i=t.defineNodeNameProperty(r,n,{prop:{get:function(){var n=this,r="";if(!e.prop(n,"willValidate"))return r;var s=e.prop(n,"validity")||{valid:1};if(s.valid)return r;r=t.getContentValidationMessage(n,s);if(r)return r;if(s.customError&&n.nodeName){r=Modernizr.formvalidation&&!t.bugs.bustedValidity&&i.prop._supget?i.prop._supget.call(n):t.data(n,"customvalidationMessage");if(r)return r}return e.each(s,function(e,i){if(e=="valid"||!i)return;r=t.createValidationMessage(n,e);if(r)return!1}),r||""},writeable:!1}})})})});
+jQuery.webshims.register("dom-extend",function(e,t,n,r,i){"use strict";var s=t.modules,o=/\s*,\s*/,u={},a={},f={},l={},c={},h=e.fn.val,p=function(t,n,r,i,s){return s?h.call(e(t)):h.call(e(t),r)};e.fn.val=function(t){var n=this[0];arguments.length&&t==null&&(t="");if(!arguments.length)return!n||n.nodeType!==1?h.call(this):e.prop(n,"value",t,"val",!0);if(e.isArray(t))return h.apply(this,arguments);var r=e.isFunction(t);return this.each(function(s){n=this;if(n.nodeType===1)if(r){var o=t.call(n,s,e.prop(n,"value",i,"val",!0));o==null&&(o=""),e.prop(n,"value",o,"val")}else e.prop(n,"value",t,"val")})},e.fn.onTrigger=function(e,t){return this.on(e,t).each(t)};var d="_webshimsLib"+Math.round(Math.random()*1e3),v=function(t,n,r){t=t.jquery?t[0]:t;if(!t)return r||{};var s=e.data(t,d);return r!==i&&(s||(s=e.data(t,d,{})),n&&(s[n]=r)),n?s&&s[n]:s};[{name:"getNativeElement",prop:"nativeElement"},{name:"getShadowElement",prop:"shadowElement"},{name:"getShadowFocusElement",prop:"shadowFocusElement"}].forEach(function(t){e.fn[t.name]=function(){return this.map(function(){var e=v(this,"shadowData");return e&&e[t.prop]||this})}}),["removeAttr","prop","attr"].forEach(function(n){u[n]=e[n],e[n]=function(t,r,s,o,l){var h=o=="val",d=h?p:u[n];if(!t||!a[r]||t.nodeType!==1||!h&&o&&n=="attr"&&e.attrFn[r])return d(t,r,s,o,l);var v=(t.nodeName||"").toLowerCase(),m=f[v],g=n!="attr"||s!==!1&&s!==null?n:"removeAttr",y,b,w;m||(m=f["*"]),m&&(m=m[r]),m&&(y=m[g]);if(y){r=="value"&&(b=y.isVal,y.isVal=h);if(g==="removeAttr")return y.value.call(t);if(s===i)return y.get?y.get.call(t):y.value;y.set&&(n=="attr"&&s===!0&&(s=r),w=y.set.call(t,s)),r=="value"&&(y.isVal=b)}else w=d(t,r,s,o,l);if((s!==i||g==="removeAttr")&&c[v]&&c[v][r]){var E;g=="removeAttr"?E=!1:g=="prop"?E=!!s:E=!0,c[v][r].forEach(function(e){(!e.only||(e.only=n=="prop")||e.only=="attr"&&n!="prop")&&e.call(t,s,E,h?"val":g,n)})}return w},l[n]=function(r,s,o){f[r]||(f[r]={}),f[r][s]||(f[r][s]={});var a=f[r][s][n],l=function(e,t,r){return t&&t[e]?t[e]:r&&r[e]?r[e]:n=="prop"&&s=="value"?function(e){var t=this;return o.isVal?p(t,s,e,!1,arguments.length===0):u[n](t,s,e)}:n=="prop"&&e=="value"&&o.value.apply?function(e){var t=u[n](this,s);return t&&t.apply&&(t=t.apply(this,arguments)),t}:function(e){return u[n](this,s,e)}};f[r][s][n]=o,o.value===i&&(o.set||(o.set=o.writeable?l("set",o,a):t.cfg.useStrict&&s=="prop"?function(){throw s+" is readonly on "+r}:e.noop),o.get||(o.get=l("get",o,a))),["value","get","set"].forEach(function(e){o[e]&&(o["_sup"+e]=l(e,a))})}});var m=function(){var e=t.getPrototypeOf(r.createElement("foobar")),n=Object.prototype.hasOwnProperty,i=Modernizr.advancedObjectProperties&&Modernizr.objectAccessor;return function(s,o,u){var a,f;if(i&&(a=r.createElement(s))&&(f=t.getPrototypeOf(a))&&e!==f&&(!a[o]||!n.call(a,o))){var l=a[o];u._supvalue=function(){return l&&l.apply?l.apply(this,arguments):l},f[o]=u.value}else u._supvalue=function(){var e=v(this,"propValue");return e&&e[o]&&e[o].apply?e[o].apply(this,arguments):e&&e[o]},g.extendValue(s,o,u.value);u.value._supvalue=u._supvalue}}(),g=function(){var n={};t.addReady(function(r,i){var s={},o=function(t){s[t]||(s[t]=e(r.getElementsByTagName(t)),i[0]&&e.nodeName(i[0],t)&&(s[t]=s[t].add(i)))};e.each(n,function(e,n){o(e);if(!n||!n.forEach){t.warn("Error: with "+e+"-property. methods: "+n);return}n.forEach(function(t){s[e].each(t)})}),s=null});var i,s=e([]),o=function(t,s){n[t]?n[t].push(s):n[t]=[s],e.isDOMReady&&(i||e(r.getElementsByTagName(t))).each(s)},u={};return{createTmpCache:function(t){return e.isDOMReady&&(i=i||e(r.getElementsByTagName(t))),i||s},flushTmpCache:function(){i=null},content:function(t,n){o(t,function(){var t=e.attr(this,n);t!=null&&e.attr(this,n,t)})},createElement:function(e,t){o(e,t)},extendValue:function(t,n,r){o(t,function(){e(this).each(function(){var e=v(this,"propValue",{});e[n]=this[n],this[n]=r})})}}}(),y=function(e,t){e.defaultValue===i&&(e.defaultValue=""),e.removeAttr||(e.removeAttr={value:function(){e[t||"prop"].set.call(this,e.defaultValue),e.removeAttr._supvalue.call(this)}}),e.attr||(e.attr={})};e.extend(t,{getID:function(){var t=(new Date).getTime();return function(n){n=e(n);var r=n.prop("id");return r||(t++,r="ID-"+t,n.eq(0).prop("id",r)),r}}(),extendUNDEFProp:function(t,n){e.each(n,function(e,n){e in t||(t[e]=n)})},createPropDefault:y,data:v,moveToFirstEvent:function(t,n,r){var i=(e._data(t,"events")||{})[n],s;i&&i.length>1&&(s=i.pop(),r||(r="bind"),r=="bind"&&i.delegateCount?i.splice(i.delegateCount,0,s):i.unshift(s)),t=null},addShadowDom:function(){var i,s,o,u={init:!1,runs:0,test:function(){var e=u.getHeight(),t=u.getWidth();e!=u.height||t!=u.width?(u.height=e,u.width=t,u.handler({type:"docresize"}),u.runs++,u.runs<9&&setTimeout(u.test,90)):u.runs=0},handler:function(t){clearTimeout(i),i=setTimeout(function(){if(t.type=="resize"){var i=e(n).width(),a=e(n).width();if(a==s&&i==o)return;s=a,o=i,u.height=u.getHeight(),u.width=u.getWidth()}e(r).triggerHandler("updateshadowdom")},t.type=="resize"?50:9)},_create:function(){e.each({Height:"getHeight",Width:"getWidth"},function(e,t){var n=r.body,i=r.documentElement;u[t]=function(){return Math.max(n["scroll"+e],i["scroll"+e],n["offset"+e],i["offset"+e],i["client"+e])}})},start:function(){!this.init&&r.body&&(this.init=!0,this._create(),this.height=u.getHeight(),this.width=u.getWidth(),setInterval(this.test,600),e(this.test),t.ready("WINDOWLOAD",this.test),e(n).bind("resize",this.handler),function(){var t=e.fn.animate,n;e.fn.animate=function(){return clearTimeout(n),n=setTimeout(function(){u.test()},99),t.apply(this,arguments)}}())}};return t.docObserve=function(){t.ready("DOM",function(){u.start()})},function(n,r,i){i=i||{},n.jquery&&(n=n[0]),r.jquery&&(r=r[0]);var s=e.data(n,d)||e.data(n,d,{}),o=e.data(r,d)||e.data(r,d,{}),u={};i.shadowFocusElement?i.shadowFocusElement&&(i.shadowFocusElement.jquery&&(i.shadowFocusElement=i.shadowFocusElement[0]),u=e.data(i.shadowFocusElement,d)||e.data(i.shadowFocusElement,d,u)):i.shadowFocusElement=r,s.hasShadow=r,u.nativeElement=o.nativeElement=n,u.shadowData=o.shadowData=s.shadowData={nativeElement:n,shadowElement:r,shadowFocusElement:i.shadowFocusElement},i.shadowChilds&&i.shadowChilds.each(function(){v(this,"shadowData",o.shadowData)}),i.data&&(u.shadowData.data=o.shadowData.data=s.shadowData.data=i.data),i=null,t.docObserve()}}(),propTypes:{standard:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,""+t)},get:function(){return e.attr.get.call(this)||e.defaultValue}}},"boolean":function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){t?e.attr.set.call(this,""):e.removeAttr.value.call(this)},get:function(){return e.attr.get.call(this)!=null}}},src:function(){var t=r.createElement("a");return t.style.display="none",function(n,r){y(n);if(n.prop)return;n.prop={set:function(e){n.attr.set.call(this,e)},get:function(){var n=this.getAttribute(r),i;if(n==null)return"";t.setAttribute("href",n+"");if(!e.support.hrefNormalized){try{e(t).insertAfter(this),i=t.getAttribute("href",4)}catch(s){i=t.getAttribute("href",4)}e(t).detach()}return i||t.href}}}}(),enumarated:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,t)},get:function(){var t=(e.attr.get.call(this)||"").toLowerCase();if(!t||e.limitedTo.indexOf(t)==-1)t=e.defaultValue;return t}}}},reflectProperties:function(n,r){typeof r=="string"&&(r=r.split(o)),r.forEach(function(r){t.defineNodeNamesProperty(n,r,{prop:{set:function(t){e.attr(this,r,t)},get:function(){return e.attr(this,r)||""}}})})},defineNodeNameProperty:function(n,r,i){return a[r]=!0,i.reflect&&t.propTypes[i.propType||"standard"](i,r),["prop","attr","removeAttr"].forEach(function(s){var o=i[s];o&&(s==="prop"?o=e.extend({writeable:!0},o):o=e.extend({},o,{writeable:!0}),l[s](n,r,o),n!="*"&&t.cfg.extendNative&&s=="prop"&&o.value&&e.isFunction(o.value)&&m(n,r,o),i[s]=o)}),i.initAttr&&g.content(n,r),i},defineNodeNameProperties:function(e,n,r,i){var s;for(var o in n)!i&&n[o].initAttr&&g.createTmpCache(e),r&&(n[o][r]||(n[o][r]={},["value","set","get"].forEach(function(e){e in n[o]&&(n[o][r][e]=n[o][e],delete n[o][e])}))),n[o]=t.defineNodeNameProperty(e,o,n[o]);return i||g.flushTmpCache(),n},createElement:function(n,r,i){var s;return e.isFunction(r)&&(r={after:r}),g.createTmpCache(n),r.before&&g.createElement(n,r.before),i&&(s=t.defineNodeNameProperties(n,i,!1,!0)),r.after&&g.createElement(n,r.after),g.flushTmpCache(),s},onNodeNamesPropertyModify:function(t,n,r,i){typeof t=="string"&&(t=t.split(o)),e.isFunction(r)&&(r={set:r}),t.forEach(function(e){c[e]||(c[e]={}),typeof n=="string"&&(n=n.split(o)),r.initAttr&&g.createTmpCache(e),n.forEach(function(t){c[e][t]||(c[e][t]=[],a[t]=!0),r.set&&(i&&(r.set.only=i),c[e][t].push(r.set)),r.initAttr&&g.content(e,t)}),g.flushTmpCache()})},defineNodeNamesBooleanProperty:function(n,r,s){s||(s={}),e.isFunction(s)&&(s.set=s),t.defineNodeNamesProperty(n,r,{attr:{set:function(e){this.setAttribute(r,e),s.set&&s.set.call(this,!0)},get:function(){var e=this.getAttribute(r);return e==null?i:r}},removeAttr:{value:function(){this.removeAttribute(r),s.set&&s.set.call(this,!1)}},reflect:!0,propType:"boolean",initAttr:s.initAttr||!1})},contentAttr:function(e,t,n){if(!e.nodeName)return;var r;if(n===i)return r=e.attributes[t]||{},n=r.specified?r.value:null,n==null?i:n;typeof n=="boolean"?n?e.setAttribute(t,t):e.removeAttribute(t):e.setAttribute(t,n)},activeLang:function(){var n=[],r={},i,o,u=/:\/\/|^\.*\//,a=function(n,r,i){var s;return r&&i&&e.inArray(r,i.availabeLangs||[])!==-1?(n.loading=!0,s=i.langSrc,u.test(s)||(s=t.cfg.basePath+s),t.loader.loadScript(s+r+".js",function(){n.langObj[r]?(n.loading=!1,l(n,!0)):e(function(){n.langObj[r]&&l(n,!0),n.loading=!1})}),!0):!1},f=function(e){r[e]&&r[e].forEach(function(e){e.callback(i,o,"")})},l=function(e,t){if(e.activeLang!=i&&e.activeLang!==o){var n=s[e.module].options;e.langObj[i]||o&&e.langObj[o]?(e.activeLang=i,e.callback(e.langObj[i]||e.langObj[o],i),f(e.module)):!t&&!a(e,i,n)&&!a(e,o,n)&&e.langObj[""]&&e.activeLang!==""&&(e.activeLang="",e.callback(e.langObj[""],i),f(e.module))}},c=function(t){return typeof t=="string"&&t!==i?(i=t,o=i.split("-")[0],i==o&&(o=!1),e.each(n,function(e,t){l(t)})):typeof t=="object"&&(t.register?(r[t.register]||(r[t.register]=[]),r[t.register].push(t),t.callback(i,o,"")):(t.activeLang||(t.activeLang=""),n.push(t),l(t))),i};return c}()}),e.each({defineNodeNamesProperty:"defineNodeNameProperty",defineNodeNamesProperties:"defineNodeNameProperties",createElements:"createElement"},function(e,n){t[e]=function(e,r,i,s){typeof e=="string"&&(e=e.split(o));var u={};return e.forEach(function(e){u[e]=t[n](e,r,i,s)}),u}}),t.isReady("webshimLocalization",!0)}),function(e,t){if(!Modernizr.localstorage||"hidden"in t.createElement("a"))return;var n={article:"article",aside:"complementary",section:"region",nav:"navigation",address:"contentinfo"},r=function(e,t){var n=e.getAttribute("role");n||e.setAttribute("role",t)};e.webshims.addReady(function(i,s){e.each(n,function(t,n){var o=e(t,i).add(s.filter(t));for(var u=0,a=o.length;u<a;u++)r(o[u],n)});if(i===t){var o=t.getElementsByTagName("header")[0],u=t.getElementsByTagName("footer"),a=u.length;o&&!e(o).closest("section, article")[0]&&r(o,"banner");if(!a)return;var f=u[a-1];e(f).closest("section, article")[0]||r(f,"contentinfo")}})}(jQuery,document),function(e){"use strict";var t="webkitURL"in window,n=window.Modernizr,r=e.webshims,i=r.bugs,s=e('<form action="#" style="width: 1px; height: 1px; overflow: hidden;"><select name="b" required="" /><input required="" name="a" /></form>'),o=function(){if(s[0].querySelector)try{i.findRequired=!s[0].querySelector("select:required")}catch(e){i.findRequired=!1}},u=e("input",s).eq(0),a=function(e){r.loader.loadList(["dom-extend"]),r.ready("dom-extend",e)};i.findRequired=!1,i.validationMessage=!1,r.capturingEventPrevented=function(t){if(!t._isPolyfilled){var n=t.isDefaultPrevented,r=t.preventDefault;t.preventDefault=function(){return clearTimeout(e.data(t.target,t.type+"DefaultPrevented")),e.data(t.target,t.type+"DefaultPrevented",setTimeout(function(){e.removeData(t.target,t.type+"DefaultPrevented")},30)),r.apply(this,arguments)},t.isDefaultPrevented=function(){return!!(n.apply(this,arguments)||e.data(t.target,t.type+"DefaultPrevented")||!1)},t._isPolyfilled=!0}};if(!n.formvalidation||i.bustedValidity)o();else{r.capturingEvents(["input"]),r.capturingEvents(["invalid"],!0);if(window.opera||window.testGoodWithFix)s.appendTo("head"),o(),i.validationMessage=!u.prop("validationMessage"),r.reTest(["form-native-extend","form-message"]),s.remove(),e(function(){a(function(){var t=function(e){e.preventDefault()};["form","input","textarea","select"].forEach(function(n){var i=r.defineNodeNameProperty(n,"checkValidity",{prop:{value:function(){r.fromSubmit||e(this).on("invalid.checkvalidity",t),r.fromCheckValidity=!0;var n=i.prop._supvalue.apply(this,arguments);return r.fromSubmit||e(this).unbind("invalid.checkvalidity",t),r.fromCheckValidity=!1,n}}})})})});t&&!r.bugs.bustedValidity&&function(){var t=/^(?:textarea|input)$/i,n=!1;document.addEventListener("contextmenu",function(e){t.test(e.target.nodeName||"")&&(n=e.target.form)&&setTimeout(function(){n=!1},1)},!1),e(window).on("invalid",function(e){e.originalEvent&&n&&n==e.target.form&&(e.wrongWebkitInvalid=!0,e.stopImmediatePropagation())})}()}e.webshims.register("form-core",function(e,r,i,s,o,u){var a={checkbox:1,radio:1},f=e([]),l=r.bugs,c=function(t){t=e(t);var n,r,i=f;return t[0].type=="radio"&&(r=t.prop("form"),n=t[0].name,n?r?i=e(r[n]):i=e(s.getElementsByName(n)).filter(function(){return!e.prop(this,"form")}):i=t,i=i.filter('[type="radio"]')),i},h=r.getContentValidationMessage=function(t,n,r){var i=e(t).data("errormessage")||t.getAttribute("x-moz-errormessage")||"";return r&&i[r]&&(i=i[r]),typeof i=="object"&&(n=n||e.prop(t,"validity")||{valid:1},n.valid||e.each(n,function(e,t){if(t&&e!="valid"&&i[e])return i=i[e],!1})),typeof i=="object"&&(i=i.defaultMessage),i||""},p={number:1,range:1,date:1},d=function(t){var n=!1;return e(e.prop(t,"elements")).each(function(){n=e(this).is(":invalid");if(n)return!1}),n};e.extend(e.expr[":"],{"valid-element":function(t){return e.nodeName(t,"form")?!d(t):!!e.prop(t,"willValidate")&&!!m(t)},"invalid-element":function(t){return e.nodeName(t,"form")?d(t):!!e.prop(t,"willValidate")&&!m(t)},"required-element":function(t){return!!e.prop(t,"willValidate")&&!!e.prop(t,"required")},"user-error":function(t){return e.prop(t,"willValidate")&&e(t).hasClass("user-error")},"optional-element":function(t){return!!e.prop(t,"willValidate")&&e.prop(t,"required")===!1},"in-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!!(n&&!n.rangeOverflow&&!n.rangeUnderflow)},"out-of-range":function(t){if(!p[e.prop(t,"type")]||!e.prop(t,"willValidate"))return!1;var n=e.prop(t,"validity");return!(!n||!n.rangeOverflow&&!n.rangeUnderflow)}}),["valid","invalid","required","optional"].forEach(function(t){e.expr[":"][t]=e.expr.filters[t+"-element"]}),e.expr[":"].focus=function(e){try{var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())}catch(n){}return!1};var v=e.event.customEvent||{},m=function(t){return(e.prop(t,"validity")||{valid:1}).valid};(l.bustedValidity||l.findRequired)&&function(){var t=e.find,r=e.find.matchesSelector,i=/(\:valid|\:invalid|\:optional|\:required|\:in-range|\:out-of-range)(?=[\s\[\~\.\+\>\:\#*]|$)/ig,o=function(e){return e+"-element"};e.find=function(){var e=Array.prototype.slice,n=function(n){var r=arguments;return r=e.call(r,1,r.length),r.unshift(n.replace(i,o)),t.apply(this,r)};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}();if(!n.prefixed||n.prefixed("matchesSelector",s.documentElement))e.find.matchesSelector=function(e,t){return t=t.replace(i,o),r.call(this,e,t)}}();var g=e.prop,y={selectedIndex:1,value:1,checked:1,disabled:1,readonly:1};e.prop=function(t,n,r){var i=g.apply(this,arguments);return t&&"form"in t&&y[n]&&r!==o&&e(t).hasClass(E)&&m(t)&&(e(t).getShadowElement().removeClass(E),n=="checked"&&r&&c(t).not(t).removeClass(E).removeAttr("aria-invalid")),i};var b=function(t,n){var r;return e.each(t,function(t,i){if(i)return r=t=="customError"?e.prop(n,"validationMessage"):t,!1}),r},w=function(e){var t;try{t=s.activeElement.name===e}catch(n){}return t},E="user-error",S="user-success",x=function(t){var n,r;if(!t.target)return;n=e(t.target).getNativeElement()[0];if(n.type=="submit"||!e.prop(n,"willValidate"))return;r=e.data(n,"webshimsswitchvalidityclass");var i=function(){if(t.type=="focusout"&&n.type=="radio"&&w(n.name))return;var r=e.prop(n,"validity"),i=e(n).getShadowElement(),s,o,u,f,l;e(n).trigger("refreshCustomValidityRules"),r.valid?i.hasClass(S)||(s=S,o=E,f="changedvaliditystate",u="changedvalid",a[n.type]&&n.checked&&c(n).not(n).removeClass(o).addClass(s).removeAttr("aria-invalid"),e.removeData(n,"webshimsinvalidcause")):(l=b(r,n),e.data(n,"webshimsinvalidcause")!=l&&(e.data(n,"webshimsinvalidcause",l),f="changedvaliditystate"),i.hasClass(E)||(s=E,o=S,a[n.type]&&!n.checked&&c(n).not(n).removeClass(o).addClass(s),u="changedinvalid")),s&&(i.addClass(s).removeClass(o),setTimeout(function(){e(n).trigger(u)},0)),f&&setTimeout(function(){e(n).trigger(f)},0),e.removeData(t.target,"webshimsswitchvalidityclass")};r&&clearTimeout(r),t.type=="refreshvalidityui"?i():e.data(n,"webshimsswitchvalidityclass",setTimeout(i,9))};e(s).on(u.validityUIEvents||"focusout change refreshvalidityui",x),v.changedvaliditystate=!0,v.refreshCustomValidityRules=!0,v.changedvalid=!0,v.changedinvalid=!0,v.refreshvalidityui=!0,r.triggerInlineForm=function(t,n){e(t).trigger(n)},r.modules["form-core"].getGroupElements=c;var T=function(){r.scrollRoot=t||s.compatMode=="BackCompat"?e(s.body):e(s.documentElement)};T(),r.ready("DOM",T),r.getRelOffset=function(t,n){t=e(t);var r=e(n).offset(),i;return e.swap(e(t)[0],{visibility:"hidden",display:"inline-block",left:0,top:0},function(){i=t.offset()}),r.top-=i.top,r.left-=i.left,r},r.wsPopover={_create:function(){this.options=e.extend({},r.cfg.wspopover,this.options),this.id=r.wsPopover.id++,this.eventns=".wsoverlay"+this.id,this.timers={},this.element=e('<div class="ws-popover" tabindex="-1"><div class="ws-po-outerbox"><div class="ws-po-arrow"><div class="ws-po-arrowbox" /></div><div class="ws-po-box" /></div></div>'),this.contentElement=e(".ws-po-box",this.element),this.lastElement=e([]),this.bindElement(),this.options.prepareFor&&this.prepareFor(e(this.options.prepareFor).getNativeElement(),e(this.options.prepareFor).getShadowElement()),this.element.data("wspopover",this)},options:{},content:function(e){this.contentElement.html(e)},bindElement:function(){var e=this,t=function(){e.stopBlur=!1};this.element.on({mousedown:function(n){e.stopBlur=!0,e.timers.stopBlur=setTimeout(t,9)}})},isInElement:function(t,n){return t==n||e.contains(t,n)},show:function(t){if(this.isVisible)return;this.isVisible=!0,t=e(t).getNativeElement();var n=this,r=e(t).getShadowElement();this.clear(),this.element.removeClass("ws-po-visible").css("display","none"),this.options.prepareFor||this.prepareFor(t,r),this.position(r),n.timers.show=setTimeout(function(){n.element.css("display",""),n.timers.show=setTimeout(function(){n.element.addClass("ws-po-visible")},9)},9),e(s).on("focusin"+this.eventns+" mousedown"+this.eventns,function(e){n.options.hideOnBlur&&!n.stopBlur&&!n.isInElement(n.lastElement[0]||s.body,e.target)&&!n.isInElement(n.element[0],e.target)&&n.hide()}),e(i).on("resize"+this.eventns+" pospopover"+this.eventns,function(){clearTimeout(n.timers.repos),n.timers.repos=setTimeout(function(){n.position(r)},900)})},prepareFor:function(t,n){var r,i=e.extend({},this.options,e(t.prop("form")||[]).data("wspopover")||{},t.data("wspopover")),s=this;this.lastElement=e(t).getShadowFocusElement(),i.appendTo=="element"?this.element.insertAfter(t):this.element.appendTo(i.appendTo),this.element.attr({"data-class":t.prop("className"),"data-id":t.prop("id")}),this.element.css({width:i.constrainWidth?n.outerWidth():""}),i.hideOnBlur&&(r=function(e){s.stopBlur?e.stopImmediatePropagation():s.hide()},this.options.prepareFor?s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r).data("preparedpopover",s):s.timers.bindBlur=setTimeout(function(){s.lastElement.on("focusout"+s.eventns+" blur"+s.eventns,r)},10)),this.prepared||(this.options.prepareFor&&this.element.css("display","none"),e.fn.bgIframe&&this.element.bgIframe()),this.prepared=!0},clear:function(){e(i).off(this.eventns),e(s).off(this.eventns),this.options.prepareFor||this.lastElement.off(this.eventns),this.stopBlur=!1,e.each(this.timers,function(e,t){clearTimeout(t)})},hide:function(){if(!this.isVisible)return;this.isVisible=!1;var t=this,n=function(){t.element.css("display","none").attr({"data-id":"","data-class":"",hidden:"hidden"}),clearTimeout(t.timers.forcehide)};this.clear(),this.element.removeClass("ws-po-visible"),e(i).on("resize"+this.eventns,n),t.timers.forcehide=setTimeout(n,999)},position:function(e){var t=r.getRelOffset(this.element.css({marginTop:0,marginLeft:0,marginRight:0,marginBottom:0}).removeAttr("hidden"),e);t.top+=e.outerHeight(),this.element.css({marginTop:"",marginLeft:"",marginRight:"",marginBottom:""}).css(t)}},r.wsPopover.id=0,r.validityAlert=function(){var t=!1,n=r.objectCreate(r.wsPopover,{},u.messagePopover),s=n.hide.bind(n);return n.element.addClass("validity-alert").attr({role:"alert"}),e.extend(n,{hideDelay:5e3,showFor:function(t,n,r,i){t=e(t).getNativeElement(),this.clear(),this.hide(),i||(this.getMessage(t,n),this.show(t),this.hideDelay&&(this.timers.delayedHide=setTimeout(s,this.hideDelay))),r||this.setFocus(t)},setFocus:function(t){var n=e(t).getShadowFocusElement(),s=r.scrollRoot.scrollTop(),o=n.offset().top-30,u;s>o&&(r.scrollRoot.animate({scrollTop:o-5},{queue:!1,duration:Math.max(Math.min(600,(s-o)*1.5),80)}),u=!0);try{n[0].focus()}catch(a){}u&&(r.scrollRoot.scrollTop(s),setTimeout(function(){r.scrollRoot.scrollTop(s)},0)),e(i).triggerHandler("pospopover"+this.eventns)},getMessage:function(e,t){t||(t=h(e[0])||e.prop("customValidationMessage")||e.prop("validationMessage")),t?n.contentElement.text(t):this.hide()}}),n}(),function(){var t,n=[],r,i;e(s).on("invalid",function(i){if(i.wrongWebkitInvalid)return;var o=e(i.target),u=o.getShadowElement();u.hasClass(E)||(u.addClass(E).removeClass(S),setTimeout(function(){e(i.target).trigger("changedinvalid").trigger("changedvaliditystate")},0));if(!t){t=e.Event("firstinvalid"),t.isInvalidUIPrevented=i.isDefaultPrevented;var a=e.Event("firstinvalidsystem");e(s).triggerHandler(a,{element:i.target,form:i.target.form,isInvalidUIPrevented:i.isDefaultPrevented}),o.trigger(t)}t&&t.isDefaultPrevented()&&i.preventDefault(),n.push(i.target),i.extraData="fix",clearTimeout(r),r=setTimeout(function(){var r={type:"lastinvalid",cancelable:!1,invalidlist:e(n)};t=!1,n=[],e(i.target).trigger(r,r)},9),o=null,u=null})}(),e.fn.getErrorMessage=function(){var t="",n=this[0];return n&&(t=h(n)||e.prop(n,"customValidationMessage")||e.prop(n,"validationMessage")),t},u.replaceValidationUI&&r.ready("DOM forms",function(){e(s).on("firstinvalid",function(t){t.isInvalidUIPrevented()||(t.preventDefault(),e.webshims.validityAlert.showFor(t.target))})})})}(jQuery),jQuery.webshims.register("form-message",function(e,t,n,r,i,s){"use strict";var o=t.validityMessages,u=s.overrideMessages||s.customMessages?["customValidationMessage"]:[];o.en=e.extend(!0,{typeMismatch:{email:"Please enter an email address.",url:"Please enter a URL.",number:"Please enter a number.",date:"Please enter a date.",time:"Please enter a time.",range:"Invalid input.","datetime-local":"Please enter a datetime."},rangeUnderflow:{defaultMessage:"Value must be greater than or equal to {%min}."},rangeOverflow:{defaultMessage:"Value must be less than or equal to {%max}."},stepMismatch:"Invalid input.",tooLong:"Please enter at most {%maxlength} character(s). You entered {%valueLen}.",patternMismatch:"Invalid input. {%title}",valueMissing:{defaultMessage:"Please fill out this field.",checkbox:"Please check this box if you want to proceed."}},o.en||o["en-US"]||{}),["select","radio"].forEach(function(e){typeof o["en"].valueMissing=="object"&&(o.en.valueMissing[e]="Please select an option.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeUnderflow=="object"&&(o.en.rangeUnderflow[e]="Value must be at or after {%min}.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeOverflow=="object"&&(o.en.rangeOverflow[e]="Value must be at or before {%max}.")}),o["en-US"]=o["en-US"]||o.en,o[""]=o[""]||o["en-US"],o.de=e.extend(!0,{typeMismatch:{email:"{%value} ist keine zul\u00e4ssige E-Mail-Adresse",url:"{%value} ist keine zul\u00e4ssige Webadresse",number:"{%value} ist keine Nummer!",date:"{%value} ist kein Datum",time:"{%value} ist keine Uhrzeit",range:"{%value} ist keine Nummer!","datetime-local":"{%value} ist kein Datum-Uhrzeit Format."},rangeUnderflow:{defaultMessage:"{%value} ist zu niedrig. {%min} ist der unterste Wert, den Sie benutzen k\u00f6nnen."},rangeOverflow:{defaultMessage:"{%value} ist zu hoch. {%max} ist der oberste Wert, den Sie benutzen k\u00f6nnen."},stepMismatch:"Der Wert {%value} ist in diesem Feld nicht zul\u00e4ssig. Hier sind nur bestimmte Werte zul\u00e4ssig. {%title}",tooLong:"Der eingegebene Text ist zu lang! Sie haben {%valueLen} Zeichen eingegeben, dabei sind {%maxlength} das Maximum.",patternMismatch:"{%value} hat f\u00fcr dieses Eingabefeld ein falsches Format! {%title}",valueMissing:{defaultMessage:"Bitte geben Sie einen Wert ein",checkbox:"Bitte aktivieren Sie das K\u00e4stchen"}},o.de||{}),["select","radio"].forEach(function(e){typeof o.de.valueMissing=="object"&&(o.de.valueMissing[e]="Bitte w\u00e4hlen Sie eine Option aus")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeUnderflow=="object"&&(o.de.rangeUnderflow[e]="{%value} ist zu fr\u00fch. {%min} ist die fr\u00fcheste Zeit, die Sie benutzen k\u00f6nnen.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeOverflow=="object"&&(o.de.rangeOverflow[e]="{%value} ist zu sp\u00e4t. {%max} ist die sp\u00e4teste Zeit, die Sie benutzen k\u00f6nnen.")});var a=o[""];t.createValidationMessage=function(n,r){var i=a[r];return i&&typeof i!="string"&&(i=i[e.prop(n,"type")]||i[(n.nodeName||"").toLowerCase()]||i.defaultMessage),i&&["value","min","max","title","maxlength","label"].forEach(function(s){if(i.indexOf("{%"+s)===-1)return;var o=(s=="label"?e.trim(e('label[for="'+n.id+'"]',n.form).text()).replace(/\*$|:$/,""):e.attr(n,s))||"";r=="patternMismatch"&&s=="title"&&!o&&t.error("no title for patternMismatch provided. Always add a title attribute."),i=i.replace("{%"+s+"}",o),"value"==s&&(i=i.replace("{%valueLen}",o.length))}),i||""},(t.bugs.validationMessage||!Modernizr.formvalidation||t.bugs.bustedValidity)&&u.push("validationMessage"),t.activeLang({langObj:o,module:"form-core",callback:function(e){a=e}}),u.forEach(function(n){t.defineNodeNamesProperty(["fieldset","output","button"],n,{prop:{value:"",writeable:!1}}),["input","select","textarea"].forEach(function(r){var i=t.defineNodeNameProperty(r,n,{prop:{get:function(){var n=this,r="";if(!e.prop(n,"willValidate"))return r;var s=e.prop(n,"validity")||{valid:1};if(s.valid)return r;r=t.getContentValidationMessage(n,s);if(r)return r;if(s.customError&&n.nodeName){r=Modernizr.formvalidation&&!t.bugs.bustedValidity&&i.prop._supget?i.prop._supget.call(n):t.data(n,"customvalidationMessage");if(r)return r}return e.each(s,function(e,i){if(e=="valid"||!i)return;r=t.createValidationMessage(n,e);if(r)return!1}),r||""},writeable:!1}})})})});
View
2  demos/js-webshim/minified/shims/combos/4.js
@@ -1 +1 @@
-jQuery.webshims.register("dom-extend",function(e,t,n,r,i){"use strict";var s=t.modules,o=/\s*,\s*/,u={},a={},f={},l={},c={},h=e.fn.val,p=function(t,n,r,i,s){return s?h.call(e(t)):h.call(e(t),r)};e.fn.val=function(t){var n=this[0];arguments.length&&t==null&&(t="");if(!arguments.length)return!n||n.nodeType!==1?h.call(this):e.prop(n,"value",t,"val",!0);if(e.isArray(t))return h.apply(this,arguments);var r=e.isFunction(t);return this.each(function(s){n=this;if(n.nodeType===1)if(r){var o=t.call(n,s,e.prop(n,"value",i,"val",!0));o==null&&(o=""),e.prop(n,"value",o,"val")}else e.prop(n,"value",t,"val")})},e.fn.onTrigger=function(e,t){return this.on(e,t).each(t)};var d="_webshimsLib"+Math.round(Math.random()*1e3),v=function(t,n,r){t=t.jquery?t[0]:t;if(!t)return r||{};var s=e.data(t,d);return r!==i&&(s||(s=e.data(t,d,{})),n&&(s[n]=r)),n?s&&s[n]:s};[{name:"getNativeElement",prop:"nativeElement"},{name:"getShadowElement",prop:"shadowElement"},{name:"getShadowFocusElement",prop:"shadowFocusElement"}].forEach(function(t){e.fn[t.name]=function(){return this.map(function(){var e=v(this,"shadowData");return e&&e[t.prop]||this})}}),["removeAttr","prop","attr"].forEach(function(n){u[n]=e[n],e[n]=function(t,r,s,o,l){var h=o=="val",d=h?p:u[n];if(!t||!a[r]||t.nodeType!==1||!h&&o&&n=="attr"&&e.attrFn[r])return d(t,r,s,o,l);var v=(t.nodeName||"").toLowerCase(),m=f[v],g=n!="attr"||s!==!1&&s!==null?n:"removeAttr",y,b,w;m||(m=f["*"]),m&&(m=m[r]),m&&(y=m[g]);if(y){r=="value"&&(b=y.isVal,y.isVal=h);if(g==="removeAttr")return y.value.call(t);if(s===i)return y.get?y.get.call(t):y.value;y.set&&(n=="attr"&&s===!0&&(s=r),w=y.set.call(t,s)),r=="value"&&(y.isVal=b)}else w=d(t,r,s,o,l);if((s!==i||g==="removeAttr")&&c[v]&&c[v][r]){var E;g=="removeAttr"?E=!1:g=="prop"?E=!!s:E=!0,c[v][r].forEach(function(e){(!e.only||(e.only=n=="prop")||e.only=="attr"&&n!="prop")&&e.call(t,s,E,h?"val":g,n)})}return w},l[n]=function(r,s,o){f[r]||(f[r]={}),f[r][s]||(f[r][s]={});var a=f[r][s][n],l=function(e,t,r){return t&&t[e]?t[e]:r&&r[e]?r[e]:n=="prop"&&s=="value"?function(e){var t=this;return o.isVal?p(t,s,e,!1,arguments.length===0):u[n](t,s,e)}:n=="prop"&&e=="value"&&o.value.apply?function(e){var t=u[n](this,s);return t&&t.apply&&(t=t.apply(this,arguments)),t}:function(e){return u[n](this,s,e)}};f[r][s][n]=o,o.value===i&&(o.set||(o.set=o.writeable?l("set",o,a):t.cfg.useStrict&&s=="prop"?function(){throw s+" is readonly on "+r}:e.noop),o.get||(o.get=l("get",o,a))),["value","get","set"].forEach(function(e){o[e]&&(o["_sup"+e]=l(e,a))})}});var m=function(){var e=t.getPrototypeOf(r.createElement("foobar")),n=Object.prototype.hasOwnProperty,i=Modernizr.advancedObjectProperties&&Modernizr.objectAccessor;return function(s,o,u){var a,f;if(i&&(a=r.createElement(s))&&(f=t.getPrototypeOf(a))&&e!==f&&(!a[o]||!n.call(a,o))){var l=a[o];u._supvalue=function(){return l&&l.apply?l.apply(this,arguments):l},f[o]=u.value}else u._supvalue=function(){var e=v(this,"propValue");return e&&e[o]&&e[o].apply?e[o].apply(this,arguments):e&&e[o]},g.extendValue(s,o,u.value);u.value._supvalue=u._supvalue}}(),g=function(){var n={};t.addReady(function(r,i){var s={},o=function(t){s[t]||(s[t]=e(r.getElementsByTagName(t)),i[0]&&e.nodeName(i[0],t)&&(s[t]=s[t].add(i)))};e.each(n,function(e,n){o(e);if(!n||!n.forEach){t.warn("Error: with "+e+"-property. methods: "+n);return}n.forEach(function(t){s[e].each(t)})}),s=null});var i,s=e([]),o=function(t,s){n[t]?n[t].push(s):n[t]=[s],e.isDOMReady&&(i||e(r.getElementsByTagName(t))).each(s)},u={};return{createTmpCache:function(t){return e.isDOMReady&&(i=i||e(r.getElementsByTagName(t))),i||s},flushTmpCache:function(){i=null},content:function(t,n){o(t,function(){var t=e.attr(this,n);t!=null&&e.attr(this,n,t)})},createElement:function(e,t){o(e,t)},extendValue:function(t,n,r){o(t,function(){e(this).each(function(){var e=v(this,"propValue",{});e[n]=this[n],this[n]=r})})}}}(),y=function(e,t){e.defaultValue===i&&(e.defaultValue=""),e.removeAttr||(e.removeAttr={value:function(){e[t||"prop"].set.call(this,e.defaultValue),e.removeAttr._supvalue.call(this)}}),e.attr||(e.attr={})};e.extend(t,{getID:function(){var t=(new Date).getTime();return function(n){n=e(n);var r=n.attr("id");return r||(t++,r="ID-"+t,n.attr("id",r)),r}}(),extendUNDEFProp:function(t,n){e.each(n,function(e,n){e in t||(t[e]=n)})},createPropDefault:y,data:v,moveToFirstEvent:function(t,n,r){var i=(e._data(t,"events")||{})[n],s;i&&i.length>1&&(s=i.pop(),r||(r="bind"),r=="bind"&&i.delegateCount?i.splice(i.delegateCount,0,s):i.unshift(s)),t=null},addShadowDom:function(){var i,s,o,u={init:!1,runs:0,test:function(){var e=u.getHeight(),t=u.getWidth();e!=u.height||t!=u.width?(u.height=e,u.width=t,u.handler({type:"docresize"}),u.runs++,u.runs<9&&setTimeout(u.test,90)):u.runs=0},handler:function(t){clearTimeout(i),i=setTimeout(function(){if(t.type=="resize"){var i=e(n).width(),a=e(n).width();if(a==s&&i==o)return;s=a,o=i,u.height=u.getHeight(),u.width=u.getWidth()}e(r).triggerHandler("updateshadowdom")},t.type=="resize"?50:9)},_create:function(){e.each({Height:"getHeight",Width:"getWidth"},function(e,t){var n=r.body,i=r.documentElement;u[t]=function(){return Math.max(n["scroll"+e],i["scroll"+e],n["offset"+e],i["offset"+e],i["client"+e])}})},start:function(){!this.init&&r.body&&(this.init=!0,this._create(),this.height=u.getHeight(),this.width=u.getWidth(),setInterval(this.test,600),e(this.test),t.ready("WINDOWLOAD",this.test),e(n).bind("resize",this.handler),function(){var t=e.fn.animate,n;e.fn.animate=function(){return clearTimeout(n),n=setTimeout(function(){u.test()},99),t.apply(this,arguments)}}())}};return t.docObserve=function(){t.ready("DOM",function(){u.start()})},function(n,r,i){i=i||{},n.jquery&&(n=n[0]),r.jquery&&(r=r[0]);var s=e.data(n,d)||e.data(n,d,{}),o=e.data(r,d)||e.data(r,d,{}),u={};i.shadowFocusElement?i.shadowFocusElement&&(i.shadowFocusElement.jquery&&(i.shadowFocusElement=i.shadowFocusElement[0]),u=e.data(i.shadowFocusElement,d)||e.data(i.shadowFocusElement,d,u)):i.shadowFocusElement=r,s.hasShadow=r,u.nativeElement=o.nativeElement=n,u.shadowData=o.shadowData=s.shadowData={nativeElement:n,shadowElement:r,shadowFocusElement:i.shadowFocusElement},i.shadowChilds&&i.shadowChilds.each(function(){v(this,"shadowData",o.shadowData)}),i.data&&(u.shadowData.data=o.shadowData.data=s.shadowData.data=i.data),i=null,t.docObserve()}}(),propTypes:{standard:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,""+t)},get:function(){return e.attr.get.call(this)||e.defaultValue}}},"boolean":function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){t?e.attr.set.call(this,""):e.removeAttr.value.call(this)},get:function(){return e.attr.get.call(this)!=null}}},src:function(){var t=r.createElement("a");return t.style.display="none",function(n,r){y(n);if(n.prop)return;n.prop={set:function(e){n.attr.set.call(this,e)},get:function(){var n=this.getAttribute(r),i;if(n==null)return"";t.setAttribute("href",n+"");if(!e.support.hrefNormalized){try{e(t).insertAfter(this),i=t.getAttribute("href",4)}catch(s){i=t.getAttribute("href",4)}e(t).detach()}return i||t.href}}}}(),enumarated:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,t)},get:function(){var t=(e.attr.get.call(this)||"").toLowerCase();if(!t||e.limitedTo.indexOf(t)==-1)t=e.defaultValue;return t}}}},reflectProperties:function(n,r){typeof r=="string"&&(r=r.split(o)),r.forEach(function(r){t.defineNodeNamesProperty(n,r,{prop:{set:function(t){e.attr(this,r,t)},get:function(){return e.attr(this,r)||""}}})})},defineNodeNameProperty:function(n,r,i){return a[r]=!0,i.reflect&&t.propTypes[i.propType||"standard"](i,r),["prop","attr","removeAttr"].forEach(function(s){var o=i[s];o&&(s==="prop"?o=e.extend({writeable:!0},o):o=e.extend({},o,{writeable:!0}),l[s](n,r,o),n!="*"&&t.cfg.extendNative&&s=="prop"&&o.value&&e.isFunction(o.value)&&m(n,r,o),i[s]=o)}),i.initAttr&&g.content(n,r),i},defineNodeNameProperties:function(e,n,r,i){var s;for(var o in n)!i&&n[o].initAttr&&g.createTmpCache(e),r&&(n[o][r]||(n[o][r]={},["value","set","get"].forEach(function(e){e in n[o]&&(n[o][r][e]=n[o][e],delete n[o][e])}))),n[o]=t.defineNodeNameProperty(e,o,n[o]);return i||g.flushTmpCache(),n},createElement:function(n,r,i){var s;return e.isFunction(r)&&(r={after:r}),g.createTmpCache(n),r.before&&g.createElement(n,r.before),i&&(s=t.defineNodeNameProperties(n,i,!1,!0)),r.after&&g.createElement(n,r.after),g.flushTmpCache(),s},onNodeNamesPropertyModify:function(t,n,r,i){typeof t=="string"&&(t=t.split(o)),e.isFunction(r)&&(r={set:r}),t.forEach(function(e){c[e]||(c[e]={}),typeof n=="string"&&(n=n.split(o)),r.initAttr&&g.createTmpCache(e),n.forEach(function(t){c[e][t]||(c[e][t]=[],a[t]=!0),r.set&&(i&&(r.set.only=i),c[e][t].push(r.set)),r.initAttr&&g.content(e,t)}),g.flushTmpCache()})},defineNodeNamesBooleanProperty:function(n,r,s){s||(s={}),e.isFunction(s)&&(s.set=s),t.defineNodeNamesProperty(n,r,{attr:{set:function(e){this.setAttribute(r,e),s.set&&s.set.call(this,!0)},get:function(){var e=this.getAttribute(r);return e==null?i:r}},removeAttr:{value:function(){this.removeAttribute(r),s.set&&s.set.call(this,!1)}},reflect:!0,propType:"boolean",initAttr:s.initAttr||!1})},contentAttr:function(e,t,n){if(!e.nodeName)return;var r;if(n===i)return r=e.attributes[t]||{},n=r.specified?r.value:null,n==null?i:n;typeof n=="boolean"?n?e.setAttribute(t,t):e.removeAttribute(t):e.setAttribute(t,n)},activeLang:function(){var n=[],r={},i,o,u=/:\/\/|^\.*\//,a=function(n,r,i){var s;return r&&i&&e.inArray(r,i.availabeLangs||[])!==-1?(n.loading=!0,s=i.langSrc,u.test(s)||(s=t.cfg.basePath+s),t.loader.loadScript(s+r+".js",function(){n.langObj[r]?(n.loading=!1,l(n,!0)):e(function(){n.langObj[r]&&l(n,!0),n.loading=!1})}),!0):!1},f=function(e){r[e]&&r[e].forEach(function(e){e.callback(i,o,"")})},l=function(e,t){if(e.activeLang!=i&&e.activeLang!==o){var n=s[e.module].options;e.langObj[i]||o&&e.langObj[o]?(e.activeLang=i,e.callback(e.langObj[i]||e.langObj[o],i),f(e.module)):!t&&!a(e,i,n)&&!a(e,o,n)&&e.langObj[""]&&e.activeLang!==""&&(e.activeLang="",e.callback(e.langObj[""],i),f(e.module))}},c=function(t){return typeof t=="string"&&t!==i?(i=t,o=i.split("-")[0],i==o&&(o=!1),e.each(n,function(e,t){l(t)})):typeof t=="object"&&(t.register?(r[t.register]||(r[t.register]=[]),r[t.register].push(t),t.callback(i,o,"")):(t.activeLang||(t.activeLang=""),n.push(t),l(t))),i};return c}()}),e.each({defineNodeNamesProperty:"defineNodeNameProperty",defineNodeNamesProperties:"defineNodeNameProperties",createElements:"createElement"},function(e,n){t[e]=function(e,r,i,s){typeof e=="string"&&(e=e.split(o));var u={};return e.forEach(function(e){u[e]=t[n](e,r,i,s)}),u}}),t.isReady("webshimLocalization",!0)}),function(e,t){if(!Modernizr.localstorage||"hidden"in t.createElement("a"))return;var n={article:"article",aside:"complementary",section:"region",nav:"navigation",address:"contentinfo"},r=function(e,t){var n=e.getAttribute("role");n||e.setAttribute("role",t)};e.webshims.addReady(function(i,s){e.each(n,function(t,n){var o=e(t,i).add(s.filter(t));for(var u=0,a=o.length;u<a;u++)r(o[u],n)});if(i===t){var o=t.getElementsByTagName("header")[0],u=t.getElementsByTagName("footer"),a=u.length;o&&!e(o).closest("section, article")[0]&&r(o,"banner");if(!a)return;var f=u[a-1];e(f).closest("section, article")[0]||r(f,"contentinfo")}})}(jQuery,document),jQuery.webshims.register("form-message",function(e,t,n,r,i,s){"use strict";var o=t.validityMessages,u=s.overrideMessages||s.customMessages?["customValidationMessage"]:[];o.en=e.extend(!0,{typeMismatch:{email:"Please enter an email address.",url:"Please enter a URL.",number:"Please enter a number.",date:"Please enter a date.",time:"Please enter a time.",range:"Invalid input.","datetime-local":"Please enter a datetime."},rangeUnderflow:{defaultMessage:"Value must be greater than or equal to {%min}."},rangeOverflow:{defaultMessage:"Value must be less than or equal to {%max}."},stepMismatch:"Invalid input.",tooLong:"Please enter at most {%maxlength} character(s). You entered {%valueLen}.",patternMismatch:"Invalid input. {%title}",valueMissing:{defaultMessage:"Please fill out this field.",checkbox:"Please check this box if you want to proceed."}},o.en||o["en-US"]||{}),["select","radio"].forEach(function(e){typeof o["en"].valueMissing=="object"&&(o.en.valueMissing[e]="Please select an option.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeUnderflow=="object"&&(o.en.rangeUnderflow[e]="Value must be at or after {%min}.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeOverflow=="object"&&(o.en.rangeOverflow[e]="Value must be at or before {%max}.")}),o["en-US"]=o["en-US"]||o.en,o[""]=o[""]||o["en-US"],o.de=e.extend(!0,{typeMismatch:{email:"{%value} ist keine zul\u00e4ssige E-Mail-Adresse",url:"{%value} ist keine zul\u00e4ssige Webadresse",number:"{%value} ist keine Nummer!",date:"{%value} ist kein Datum",time:"{%value} ist keine Uhrzeit",range:"{%value} ist keine Nummer!","datetime-local":"{%value} ist kein Datum-Uhrzeit Format."},rangeUnderflow:{defaultMessage:"{%value} ist zu niedrig. {%min} ist der unterste Wert, den Sie benutzen k\u00f6nnen."},rangeOverflow:{defaultMessage:"{%value} ist zu hoch. {%max} ist der oberste Wert, den Sie benutzen k\u00f6nnen."},stepMismatch:"Der Wert {%value} ist in diesem Feld nicht zul\u00e4ssig. Hier sind nur bestimmte Werte zul\u00e4ssig. {%title}",tooLong:"Der eingegebene Text ist zu lang! Sie haben {%valueLen} Zeichen eingegeben, dabei sind {%maxlength} das Maximum.",patternMismatch:"{%value} hat f\u00fcr dieses Eingabefeld ein falsches Format! {%title}",valueMissing:{defaultMessage:"Bitte geben Sie einen Wert ein",checkbox:"Bitte aktivieren Sie das K\u00e4stchen"}},o.de||{}),["select","radio"].forEach(function(e){typeof o.de.valueMissing=="object"&&(o.de.valueMissing[e]="Bitte w\u00e4hlen Sie eine Option aus")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeUnderflow=="object"&&(o.de.rangeUnderflow[e]="{%value} ist zu fr\u00fch. {%min} ist die fr\u00fcheste Zeit, die Sie benutzen k\u00f6nnen.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeOverflow=="object"&&(o.de.rangeOverflow[e]="{%value} ist zu sp\u00e4t. {%max} ist die sp\u00e4teste Zeit, die Sie benutzen k\u00f6nnen.")});var a=o[""];t.createValidationMessage=function(n,r){var i=a[r];return i&&typeof i!="string"&&(i=i[e.prop(n,"type")]||i[(n.nodeName||"").toLowerCase()]||i.defaultMessage),i&&["value","min","max","title","maxlength","label"].forEach(function(s){if(i.indexOf("{%"+s)===-1)return;var o=(s=="label"?e.trim(e('label[for="'+n.id+'"]',n.form).text()).replace(/\*$|:$/,""):e.attr(n,s))||"";r=="patternMismatch"&&s=="title"&&!o&&t.error("no title for patternMismatch provided. Always add a title attribute."),i=i.replace("{%"+s+"}",o),"value"==s&&(i=i.replace("{%valueLen}",o.length))}),i||""},(t.bugs.validationMessage||!Modernizr.formvalidation||t.bugs.bustedValidity)&&u.push("validationMessage"),t.activeLang({langObj:o,module:"form-core",callback:function(e){a=e}}),u.forEach(function(n){t.defineNodeNamesProperty(["fieldset","output","button"],n,{prop:{value:"",writeable:!1}}),["input","select","textarea"].forEach(function(r){var i=t.defineNodeNameProperty(r,n,{prop:{get:function(){var n=this,r="";if(!e.prop(n,"willValidate"))return r;var s=e.prop(n,"validity")||{valid:1};if(s.valid)return r;r=t.getContentValidationMessage(n,s);if(r)return r;if(s.customError&&n.nodeName){r=Modernizr.formvalidation&&!t.bugs.bustedValidity&&i.prop._supget?i.prop._supget.call(n):t.data(n,"customvalidationMessage");if(r)return r}return e.each(s,function(e,i){if(e=="valid"||!i)return;r=t.createValidationMessage(n,e);if(r)return!1}),r||""},writeable:!1}})})})});
+jQuery.webshims.register("dom-extend",function(e,t,n,r,i){"use strict";var s=t.modules,o=/\s*,\s*/,u={},a={},f={},l={},c={},h=e.fn.val,p=function(t,n,r,i,s){return s?h.call(e(t)):h.call(e(t),r)};e.fn.val=function(t){var n=this[0];arguments.length&&t==null&&(t="");if(!arguments.length)return!n||n.nodeType!==1?h.call(this):e.prop(n,"value",t,"val",!0);if(e.isArray(t))return h.apply(this,arguments);var r=e.isFunction(t);return this.each(function(s){n=this;if(n.nodeType===1)if(r){var o=t.call(n,s,e.prop(n,"value",i,"val",!0));o==null&&(o=""),e.prop(n,"value",o,"val")}else e.prop(n,"value",t,"val")})},e.fn.onTrigger=function(e,t){return this.on(e,t).each(t)};var d="_webshimsLib"+Math.round(Math.random()*1e3),v=function(t,n,r){t=t.jquery?t[0]:t;if(!t)return r||{};var s=e.data(t,d);return r!==i&&(s||(s=e.data(t,d,{})),n&&(s[n]=r)),n?s&&s[n]:s};[{name:"getNativeElement",prop:"nativeElement"},{name:"getShadowElement",prop:"shadowElement"},{name:"getShadowFocusElement",prop:"shadowFocusElement"}].forEach(function(t){e.fn[t.name]=function(){return this.map(function(){var e=v(this,"shadowData");return e&&e[t.prop]||this})}}),["removeAttr","prop","attr"].forEach(function(n){u[n]=e[n],e[n]=function(t,r,s,o,l){var h=o=="val",d=h?p:u[n];if(!t||!a[r]||t.nodeType!==1||!h&&o&&n=="attr"&&e.attrFn[r])return d(t,r,s,o,l);var v=(t.nodeName||"").toLowerCase(),m=f[v],g=n!="attr"||s!==!1&&s!==null?n:"removeAttr",y,b,w;m||(m=f["*"]),m&&(m=m[r]),m&&(y=m[g]);if(y){r=="value"&&(b=y.isVal,y.isVal=h);if(g==="removeAttr")return y.value.call(t);if(s===i)return y.get?y.get.call(t):y.value;y.set&&(n=="attr"&&s===!0&&(s=r),w=y.set.call(t,s)),r=="value"&&(y.isVal=b)}else w=d(t,r,s,o,l);if((s!==i||g==="removeAttr")&&c[v]&&c[v][r]){var E;g=="removeAttr"?E=!1:g=="prop"?E=!!s:E=!0,c[v][r].forEach(function(e){(!e.only||(e.only=n=="prop")||e.only=="attr"&&n!="prop")&&e.call(t,s,E,h?"val":g,n)})}return w},l[n]=function(r,s,o){f[r]||(f[r]={}),f[r][s]||(f[r][s]={});var a=f[r][s][n],l=function(e,t,r){return t&&t[e]?t[e]:r&&r[e]?r[e]:n=="prop"&&s=="value"?function(e){var t=this;return o.isVal?p(t,s,e,!1,arguments.length===0):u[n](t,s,e)}:n=="prop"&&e=="value"&&o.value.apply?function(e){var t=u[n](this,s);return t&&t.apply&&(t=t.apply(this,arguments)),t}:function(e){return u[n](this,s,e)}};f[r][s][n]=o,o.value===i&&(o.set||(o.set=o.writeable?l("set",o,a):t.cfg.useStrict&&s=="prop"?function(){throw s+" is readonly on "+r}:e.noop),o.get||(o.get=l("get",o,a))),["value","get","set"].forEach(function(e){o[e]&&(o["_sup"+e]=l(e,a))})}});var m=function(){var e=t.getPrototypeOf(r.createElement("foobar")),n=Object.prototype.hasOwnProperty,i=Modernizr.advancedObjectProperties&&Modernizr.objectAccessor;return function(s,o,u){var a,f;if(i&&(a=r.createElement(s))&&(f=t.getPrototypeOf(a))&&e!==f&&(!a[o]||!n.call(a,o))){var l=a[o];u._supvalue=function(){return l&&l.apply?l.apply(this,arguments):l},f[o]=u.value}else u._supvalue=function(){var e=v(this,"propValue");return e&&e[o]&&e[o].apply?e[o].apply(this,arguments):e&&e[o]},g.extendValue(s,o,u.value);u.value._supvalue=u._supvalue}}(),g=function(){var n={};t.addReady(function(r,i){var s={},o=function(t){s[t]||(s[t]=e(r.getElementsByTagName(t)),i[0]&&e.nodeName(i[0],t)&&(s[t]=s[t].add(i)))};e.each(n,function(e,n){o(e);if(!n||!n.forEach){t.warn("Error: with "+e+"-property. methods: "+n);return}n.forEach(function(t){s[e].each(t)})}),s=null});var i,s=e([]),o=function(t,s){n[t]?n[t].push(s):n[t]=[s],e.isDOMReady&&(i||e(r.getElementsByTagName(t))).each(s)},u={};return{createTmpCache:function(t){return e.isDOMReady&&(i=i||e(r.getElementsByTagName(t))),i||s},flushTmpCache:function(){i=null},content:function(t,n){o(t,function(){var t=e.attr(this,n);t!=null&&e.attr(this,n,t)})},createElement:function(e,t){o(e,t)},extendValue:function(t,n,r){o(t,function(){e(this).each(function(){var e=v(this,"propValue",{});e[n]=this[n],this[n]=r})})}}}(),y=function(e,t){e.defaultValue===i&&(e.defaultValue=""),e.removeAttr||(e.removeAttr={value:function(){e[t||"prop"].set.call(this,e.defaultValue),e.removeAttr._supvalue.call(this)}}),e.attr||(e.attr={})};e.extend(t,{getID:function(){var t=(new Date).getTime();return function(n){n=e(n);var r=n.prop("id");return r||(t++,r="ID-"+t,n.eq(0).prop("id",r)),r}}(),extendUNDEFProp:function(t,n){e.each(n,function(e,n){e in t||(t[e]=n)})},createPropDefault:y,data:v,moveToFirstEvent:function(t,n,r){var i=(e._data(t,"events")||{})[n],s;i&&i.length>1&&(s=i.pop(),r||(r="bind"),r=="bind"&&i.delegateCount?i.splice(i.delegateCount,0,s):i.unshift(s)),t=null},addShadowDom:function(){var i,s,o,u={init:!1,runs:0,test:function(){var e=u.getHeight(),t=u.getWidth();e!=u.height||t!=u.width?(u.height=e,u.width=t,u.handler({type:"docresize"}),u.runs++,u.runs<9&&setTimeout(u.test,90)):u.runs=0},handler:function(t){clearTimeout(i),i=setTimeout(function(){if(t.type=="resize"){var i=e(n).width(),a=e(n).width();if(a==s&&i==o)return;s=a,o=i,u.height=u.getHeight(),u.width=u.getWidth()}e(r).triggerHandler("updateshadowdom")},t.type=="resize"?50:9)},_create:function(){e.each({Height:"getHeight",Width:"getWidth"},function(e,t){var n=r.body,i=r.documentElement;u[t]=function(){return Math.max(n["scroll"+e],i["scroll"+e],n["offset"+e],i["offset"+e],i["client"+e])}})},start:function(){!this.init&&r.body&&(this.init=!0,this._create(),this.height=u.getHeight(),this.width=u.getWidth(),setInterval(this.test,600),e(this.test),t.ready("WINDOWLOAD",this.test),e(n).bind("resize",this.handler),function(){var t=e.fn.animate,n;e.fn.animate=function(){return clearTimeout(n),n=setTimeout(function(){u.test()},99),t.apply(this,arguments)}}())}};return t.docObserve=function(){t.ready("DOM",function(){u.start()})},function(n,r,i){i=i||{},n.jquery&&(n=n[0]),r.jquery&&(r=r[0]);var s=e.data(n,d)||e.data(n,d,{}),o=e.data(r,d)||e.data(r,d,{}),u={};i.shadowFocusElement?i.shadowFocusElement&&(i.shadowFocusElement.jquery&&(i.shadowFocusElement=i.shadowFocusElement[0]),u=e.data(i.shadowFocusElement,d)||e.data(i.shadowFocusElement,d,u)):i.shadowFocusElement=r,s.hasShadow=r,u.nativeElement=o.nativeElement=n,u.shadowData=o.shadowData=s.shadowData={nativeElement:n,shadowElement:r,shadowFocusElement:i.shadowFocusElement},i.shadowChilds&&i.shadowChilds.each(function(){v(this,"shadowData",o.shadowData)}),i.data&&(u.shadowData.data=o.shadowData.data=s.shadowData.data=i.data),i=null,t.docObserve()}}(),propTypes:{standard:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,""+t)},get:function(){return e.attr.get.call(this)||e.defaultValue}}},"boolean":function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){t?e.attr.set.call(this,""):e.removeAttr.value.call(this)},get:function(){return e.attr.get.call(this)!=null}}},src:function(){var t=r.createElement("a");return t.style.display="none",function(n,r){y(n);if(n.prop)return;n.prop={set:function(e){n.attr.set.call(this,e)},get:function(){var n=this.getAttribute(r),i;if(n==null)return"";t.setAttribute("href",n+"");if(!e.support.hrefNormalized){try{e(t).insertAfter(this),i=t.getAttribute("href",4)}catch(s){i=t.getAttribute("href",4)}e(t).detach()}return i||t.href}}}}(),enumarated:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,t)},get:function(){var t=(e.attr.get.call(this)||"").toLowerCase();if(!t||e.limitedTo.indexOf(t)==-1)t=e.defaultValue;return t}}}},reflectProperties:function(n,r){typeof r=="string"&&(r=r.split(o)),r.forEach(function(r){t.defineNodeNamesProperty(n,r,{prop:{set:function(t){e.attr(this,r,t)},get:function(){return e.attr(this,r)||""}}})})},defineNodeNameProperty:function(n,r,i){return a[r]=!0,i.reflect&&t.propTypes[i.propType||"standard"](i,r),["prop","attr","removeAttr"].forEach(function(s){var o=i[s];o&&(s==="prop"?o=e.extend({writeable:!0},o):o=e.extend({},o,{writeable:!0}),l[s](n,r,o),n!="*"&&t.cfg.extendNative&&s=="prop"&&o.value&&e.isFunction(o.value)&&m(n,r,o),i[s]=o)}),i.initAttr&&g.content(n,r),i},defineNodeNameProperties:function(e,n,r,i){var s;for(var o in n)!i&&n[o].initAttr&&g.createTmpCache(e),r&&(n[o][r]||(n[o][r]={},["value","set","get"].forEach(function(e){e in n[o]&&(n[o][r][e]=n[o][e],delete n[o][e])}))),n[o]=t.defineNodeNameProperty(e,o,n[o]);return i||g.flushTmpCache(),n},createElement:function(n,r,i){var s;return e.isFunction(r)&&(r={after:r}),g.createTmpCache(n),r.before&&g.createElement(n,r.before),i&&(s=t.defineNodeNameProperties(n,i,!1,!0)),r.after&&g.createElement(n,r.after),g.flushTmpCache(),s},onNodeNamesPropertyModify:function(t,n,r,i){typeof t=="string"&&(t=t.split(o)),e.isFunction(r)&&(r={set:r}),t.forEach(function(e){c[e]||(c[e]={}),typeof n=="string"&&(n=n.split(o)),r.initAttr&&g.createTmpCache(e),n.forEach(function(t){c[e][t]||(c[e][t]=[],a[t]=!0),r.set&&(i&&(r.set.only=i),c[e][t].push(r.set)),r.initAttr&&g.content(e,t)}),g.flushTmpCache()})},defineNodeNamesBooleanProperty:function(n,r,s){s||(s={}),e.isFunction(s)&&(s.set=s),t.defineNodeNamesProperty(n,r,{attr:{set:function(e){this.setAttribute(r,e),s.set&&s.set.call(this,!0)},get:function(){var e=this.getAttribute(r);return e==null?i:r}},removeAttr:{value:function(){this.removeAttribute(r),s.set&&s.set.call(this,!1)}},reflect:!0,propType:"boolean",initAttr:s.initAttr||!1})},contentAttr:function(e,t,n){if(!e.nodeName)return;var r;if(n===i)return r=e.attributes[t]||{},n=r.specified?r.value:null,n==null?i:n;typeof n=="boolean"?n?e.setAttribute(t,t):e.removeAttribute(t):e.setAttribute(t,n)},activeLang:function(){var n=[],r={},i,o,u=/:\/\/|^\.*\//,a=function(n,r,i){var s;return r&&i&&e.inArray(r,i.availabeLangs||[])!==-1?(n.loading=!0,s=i.langSrc,u.test(s)||(s=t.cfg.basePath+s),t.loader.loadScript(s+r+".js",function(){n.langObj[r]?(n.loading=!1,l(n,!0)):e(function(){n.langObj[r]&&l(n,!0),n.loading=!1})}),!0):!1},f=function(e){r[e]&&r[e].forEach(function(e){e.callback(i,o,"")})},l=function(e,t){if(e.activeLang!=i&&e.activeLang!==o){var n=s[e.module].options;e.langObj[i]||o&&e.langObj[o]?(e.activeLang=i,e.callback(e.langObj[i]||e.langObj[o],i),f(e.module)):!t&&!a(e,i,n)&&!a(e,o,n)&&e.langObj[""]&&e.activeLang!==""&&(e.activeLang="",e.callback(e.langObj[""],i),f(e.module))}},c=function(t){return typeof t=="string"&&t!==i?(i=t,o=i.split("-")[0],i==o&&(o=!1),e.each(n,function(e,t){l(t)})):typeof t=="object"&&(t.register?(r[t.register]||(r[t.register]=[]),r[t.register].push(t),t.callback(i,o,"")):(t.activeLang||(t.activeLang=""),n.push(t),l(t))),i};return c}()}),e.each({defineNodeNamesProperty:"defineNodeNameProperty",defineNodeNamesProperties:"defineNodeNameProperties",createElements:"createElement"},function(e,n){t[e]=function(e,r,i,s){typeof e=="string"&&(e=e.split(o));var u={};return e.forEach(function(e){u[e]=t[n](e,r,i,s)}),u}}),t.isReady("webshimLocalization",!0)}),function(e,t){if(!Modernizr.localstorage||"hidden"in t.createElement("a"))return;var n={article:"article",aside:"complementary",section:"region",nav:"navigation",address:"contentinfo"},r=function(e,t){var n=e.getAttribute("role");n||e.setAttribute("role",t)};e.webshims.addReady(function(i,s){e.each(n,function(t,n){var o=e(t,i).add(s.filter(t));for(var u=0,a=o.length;u<a;u++)r(o[u],n)});if(i===t){var o=t.getElementsByTagName("header")[0],u=t.getElementsByTagName("footer"),a=u.length;o&&!e(o).closest("section, article")[0]&&r(o,"banner");if(!a)return;var f=u[a-1];e(f).closest("section, article")[0]||r(f,"contentinfo")}})}(jQuery,document),jQuery.webshims.register("form-message",function(e,t,n,r,i,s){"use strict";var o=t.validityMessages,u=s.overrideMessages||s.customMessages?["customValidationMessage"]:[];o.en=e.extend(!0,{typeMismatch:{email:"Please enter an email address.",url:"Please enter a URL.",number:"Please enter a number.",date:"Please enter a date.",time:"Please enter a time.",range:"Invalid input.","datetime-local":"Please enter a datetime."},rangeUnderflow:{defaultMessage:"Value must be greater than or equal to {%min}."},rangeOverflow:{defaultMessage:"Value must be less than or equal to {%max}."},stepMismatch:"Invalid input.",tooLong:"Please enter at most {%maxlength} character(s). You entered {%valueLen}.",patternMismatch:"Invalid input. {%title}",valueMissing:{defaultMessage:"Please fill out this field.",checkbox:"Please check this box if you want to proceed."}},o.en||o["en-US"]||{}),["select","radio"].forEach(function(e){typeof o["en"].valueMissing=="object"&&(o.en.valueMissing[e]="Please select an option.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeUnderflow=="object"&&(o.en.rangeUnderflow[e]="Value must be at or after {%min}.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.en.rangeOverflow=="object"&&(o.en.rangeOverflow[e]="Value must be at or before {%max}.")}),o["en-US"]=o["en-US"]||o.en,o[""]=o[""]||o["en-US"],o.de=e.extend(!0,{typeMismatch:{email:"{%value} ist keine zul\u00e4ssige E-Mail-Adresse",url:"{%value} ist keine zul\u00e4ssige Webadresse",number:"{%value} ist keine Nummer!",date:"{%value} ist kein Datum",time:"{%value} ist keine Uhrzeit",range:"{%value} ist keine Nummer!","datetime-local":"{%value} ist kein Datum-Uhrzeit Format."},rangeUnderflow:{defaultMessage:"{%value} ist zu niedrig. {%min} ist der unterste Wert, den Sie benutzen k\u00f6nnen."},rangeOverflow:{defaultMessage:"{%value} ist zu hoch. {%max} ist der oberste Wert, den Sie benutzen k\u00f6nnen."},stepMismatch:"Der Wert {%value} ist in diesem Feld nicht zul\u00e4ssig. Hier sind nur bestimmte Werte zul\u00e4ssig. {%title}",tooLong:"Der eingegebene Text ist zu lang! Sie haben {%valueLen} Zeichen eingegeben, dabei sind {%maxlength} das Maximum.",patternMismatch:"{%value} hat f\u00fcr dieses Eingabefeld ein falsches Format! {%title}",valueMissing:{defaultMessage:"Bitte geben Sie einen Wert ein",checkbox:"Bitte aktivieren Sie das K\u00e4stchen"}},o.de||{}),["select","radio"].forEach(function(e){typeof o.de.valueMissing=="object"&&(o.de.valueMissing[e]="Bitte w\u00e4hlen Sie eine Option aus")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeUnderflow=="object"&&(o.de.rangeUnderflow[e]="{%value} ist zu fr\u00fch. {%min} ist die fr\u00fcheste Zeit, die Sie benutzen k\u00f6nnen.")}),["date","time","datetime-local","month"].forEach(function(e){typeof o.de.rangeOverflow=="object"&&(o.de.rangeOverflow[e]="{%value} ist zu sp\u00e4t. {%max} ist die sp\u00e4teste Zeit, die Sie benutzen k\u00f6nnen.")});var a=o[""];t.createValidationMessage=function(n,r){var i=a[r];return i&&typeof i!="string"&&(i=i[e.prop(n,"type")]||i[(n.nodeName||"").toLowerCase()]||i.defaultMessage),i&&["value","min","max","title","maxlength","label"].forEach(function(s){if(i.indexOf("{%"+s)===-1)return;var o=(s=="label"?e.trim(e('label[for="'+n.id+'"]',n.form).text()).replace(/\*$|:$/,""):e.attr(n,s))||"";r=="patternMismatch"&&s=="title"&&!o&&t.error("no title for patternMismatch provided. Always add a title attribute."),i=i.replace("{%"+s+"}",o),"value"==s&&(i=i.replace("{%valueLen}",o.length))}),i||""},(t.bugs.validationMessage||!Modernizr.formvalidation||t.bugs.bustedValidity)&&u.push("validationMessage"),t.activeLang({langObj:o,module:"form-core",callback:function(e){a=e}}),u.forEach(function(n){t.defineNodeNamesProperty(["fieldset","output","button"],n,{prop:{value:"",writeable:!1}}),["input","select","textarea"].forEach(function(r){var i=t.defineNodeNameProperty(r,n,{prop:{get:function(){var n=this,r="";if(!e.prop(n,"willValidate"))return r;var s=e.prop(n,"validity")||{valid:1};if(s.valid)return r;r=t.getContentValidationMessage(n,s);if(r)return r;if(s.customError&&n.nodeName){r=Modernizr.formvalidation&&!t.bugs.bustedValidity&&i.prop._supget?i.prop._supget.call(n):t.data(n,"customvalidationMessage");if(r)return r}return e.each(s,function(e,i){if(e=="valid"||!i)return;r=t.createValidationMessage(n,e);if(r)return!1}),r||""},writeable:!1}})})})});
View
2  demos/js-webshim/minified/shims/combos/5.js
@@ -1 +1 @@
-jQuery.webshims.register("form-native-extend",function(e,t,n,r,i,s){"use strict";var o=n.Modernizr,u=o.inputtypes;if(!o.formvalidation||t.bugs.bustedValidity)return;var a=t.inputTypes,f={};t.addInputType=function(e,t){a[e]=t},t.addValidityRule=function(e,t){f[e]=t},t.addValidityRule("typeMismatch",function(e,t,n,r){if(t==="")return!1;var i=r.typeMismatch;return"type"in n||(n.type=(e[0].getAttribute("type")||"").toLowerCase()),a[n.type]&&a[n.type].mismatch&&(i=a[n.type].mismatch(t,e)),i});var l=s.overrideMessages,c=!u.number||!u.time||!u.range||l,h=["customError","typeMismatch","rangeUnderflow","rangeOverflow","stepMismatch","tooLong","patternMismatch","valueMissing","valid"],p=l?["value","checked"]:["value"],d=[],v=function(t,n){if(!t)return;var i=(t.getAttribute&&t.getAttribute("type")||t.type||"").toLowerCase();if(!l&&!a[i])return;l&&!n&&i=="radio"&&t.name?e(r.getElementsByName(t.name)).each(function(){e.prop(this,"validity")}):e.prop(t,"validity")},m={};["input","textarea","select"].forEach(function(n){var r=t.defineNodeNameProperty(n,"setCustomValidity",{prop:{value:function(i){i+="";var s=n=="input"?e(this).getNativeElement()[0]:this;r.prop._supvalue.call(s,i),t.bugs.validationMessage&&t.data(s,"customvalidationMessage",i),c&&(t.data(s,"hasCustomError",!!i),v(s))}}});m[n]=r.prop._supvalue});if(c||l)p.push("min"),p.push("max"),p.push("step"),d.push("input");l&&(p.push("required"),p.push("pattern"),d.push("select"),d.push("textarea"));if(c){var g;d.forEach(function(n){var r=t.defineNodeNameProperty(n,"validity",{prop:{get:function(){if(g)return;var i=n=="input"?e(this).getNativeElement()[0]:this,s=r.prop._supget.call(i);if(!s)return s;var o={};h.forEach(function(e){o[e]=s[e]});if(!e.prop(i,"willValidate"))return o;g=!0;var u=e(i),c={type:(i.getAttribute&&i.getAttribute("type")||"").toLowerCase(),nodeName:(i.nodeName||"").toLowerCase()},p=u.val(),d=!!t.data(i,"hasCustomError"),v;g=!1,o.customError=d;if(o.valid&&o.customError)o.valid=!1;else if(!o.valid){var y=!0;e.each(o,function(e,t){if(t)return y=!1,!1}),y&&(o.valid=!0)}return e.each(f,function(e,r){o[e]=r(u,p,c,o),o[e]&&(o.valid||!v)&&(l||a[c.type]&&a[c.type].mismatch)&&(m[n].call(i,t.createValidationMessage(i,e)),o.valid=!1,v=!0)}),o.valid?(m[n].call(i,""),t.data(i,"hasCustomError",!1)):l&&!v&&!d&&e.each(o,function(e,r){if(e!=="valid"&&r)return m[n].call(i,t.createValidationMessage(i,e)),!1}),o},writeable:!1}})}),p.forEach(function(e){t.onNodeNamesPropertyModify(d,e,function(e){v(this)})});if(r.addEventListener){var y,b=function(t){if(!("form"in t.target))return;var n=t.target.form;clearTimeout(y),v(t.target),n&&l&&e("input",n).each(function(){this.type=="password"&&v(this)})};r.addEventListener("change",b,!0),l&&(r.addEventListener("blur",b,!0),r.addEventListener("keydown",function(e){if(e.keyCode!=13)return;b(e)},!0)),r.addEventListener("input",function(e){clearTimeout(y),y=setTimeout(function(){v(e.target)},290)},!0)}var w=d.join(",");t.addReady(function(t,n){e(w,t).add(n.filter(w)).each(function(){e.prop(this,"validity")})}),l&&t.ready("DOM form-message",function(){t.activeLang({register:"form-core",callback:function(){e("input, select, textarea").getNativeElement().each(function(){if(t.data(this,"hasCustomError"))return;var n=this,r=e.prop(n,"validity")||{valid:!0},i;if(r.valid)return;i=(n.nodeName||"").toLowerCase(),e.each(r,function(e,r){if(e!=="valid"&&r)return m[i].call(n,t.createValidationMessage(n,e)),!1})})}})})}t.defineNodeNameProperty("input","type",{prop:{get:function(){var e=this,n=(e.getAttribute("type")||"").toLowerCase();return t.inputTypes[n]?n:e.type}}})}),jQuery.webshims.register("form-number-date-api",function(e,t,n,r,i){"use strict";t.getStep||(t.getStep=function(t,n){var r=e.attr(t,"step");return r==="any"?r:(n=n||l(t),!u[n]||!u[n].step?r:(r=y.number.asNumber(r),(!isNaN(r)&&r>0?r:u[n].step)*(u[n].stepScaleFactor||1)))}),t.addMinMaxNumberToCache||(t.addMinMaxNumberToCache=function(e,t,n){e+"AsNumber"in n||(n[e+"AsNumber"]=u[n.type].asNumber(t.attr(e)),isNaN(n[e+"AsNumber"])&&e+"Default"in u[n.type]&&(n[e+"AsNumber"]=u[n.type][e+"Default"]))});var s=parseInt("NaN",10),o=r,u=t.inputTypes,a=function(e){return typeof e=="number"||e&&e==e*1},f=function(t){return e('<input type="'+t+'" />').prop("type")===t},l=function(e){return(e.getAttribute("type")||"").toLowerCase()},c=function(e){var t=e*1;return e&&(t==e||e=="0"+t)},h=t.addMinMaxNumberToCache,p=function(e,t){e=""+e,t-=e.length;for(var n=0;n<t;n++)e="0"+e;return e},d=1e-7,v=t.bugs.bustedValidity;t.addValidityRule("stepMismatch",function(e,n,r,i){if(n==="")return!1;"type"in r||(r.type=l(e[0]));var s=(i||{}).stepMismatch||!1,o;if(u[r.type]&&u[r.type].step){"step"in r||(r.step=t.getStep(e[0],r.type));if(r.step=="any")return!1;"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h("min",e,r),o=r.minAsNumber,isNaN(o)&&(o=u[r.type].stepBase||0),s=Math.abs((r.valueAsNumber-o)%r.step),s=!(s<=d||Math.abs(s-r.step)<=d)}return s}),[{name:"rangeOverflow",attr:"max",factor:1},{name:"rangeUnderflow",attr:"min",factor:-1}].forEach(function(e,n){t.addValidityRule(e.name,function(t,n,r,i){var s=(i||{})[e.name]||!1;if(n==="")return s;"type"in r||(r.type=l(t[0]));if(u[r.type]&&u[r.type].asNumber){"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h(e.attr,t,r);if(isNaN(r[e.attr+"AsNumber"]))return s;s=r[e.attr+"AsNumber"]*e.factor<r.valueAsNumber*e.factor-d}return s})}),t.reflectProperties(["input"],["max","min","step"]);var m=t.defineNodeNameProperty("input","valueAsNumber",{prop:{get:function(){var t=this,n=l(t),r=u[n]&&u[n].asNumber?u[n].asNumber(e.prop(t,"value")):m.prop._supget&&m.prop._supget.apply(t,arguments);return r==null&&(r=s),r},set:function(n){var r=this,i=l(r);if(u[i]&&u[i].numberToString){if(isNaN(n)){e.prop(r,"value","");return}var s=u[i].numberToString(n);s!==!1?e.prop(r,"value",s):t.error("INVALID_STATE_ERR: DOM Exception 11")}else m.prop._supset&&m.prop._supset.apply(r,arguments)}}}),g=t.defineNodeNameProperty("input","valueAsDate",{prop:{get:function(){var t=this,n=l(t);return u[n]&&u[n].asDate&&!u[n].noAsDate?u[n].asDate(e.prop(t,"value")):g.prop._supget&&g.prop._supget.call(t)||null},set:function(n){var r=this,i=l(r);if(!(u[i]&&u[i].dateToString&&!u[i].noAsDate))return g.prop._supset&&g.prop._supset.apply(r,arguments)||null;if(n===null)return e.prop(r,"value",""),"";var s=u[i].dateToString(n);if(s!==!1)return e.prop(r,"value",s),s;t.error("INVALID_STATE_ERR: DOM Exception 11")}}});e.each({stepUp:1,stepDown:-1},function(n,r){var i=t.defineNodeNameProperty("input",n,{prop:{value:function(n){var s,o,a,f,c,h,p=l(this);if(!u[p]||!u[p].asNumber){if(i.prop&&i.prop.value)return i.prop.value.apply(this,arguments);throw t.info("no step method for type: "+p),"invalid state error"}h={type:p},n||(n=1,t.info("you should always use a factor for stepUp/stepDown")),n*=r,o=e.prop(this,"valueAsNumber");if(isNaN(o))throw t.info("valueAsNumber is NaN can't apply stepUp/stepDown "),"invalid state error";s=t.getStep(this,p);if(s=="any")throw t.info("step is 'any' can't apply stepUp/stepDown"),"invalid state error";t.addMinMaxNumberToCache("min",e(this),h),t.addMinMaxNumberToCache("max",e(this),h),s*=n,o+=s,f=(o-(h.minAsNumber||0))%s,f&&Math.abs(f)>d&&(c=o-f,c+=f>0?s:-s,o=c.toFixed(5)*1);if(!isNaN(h.maxAsNumber)&&o>h.maxAsNumber||!isNaN(h.minAsNumber)&&o<h.minAsNumber)throw t.info("max/min overflow can't apply stepUp/stepDown"),"invalid state error";a?e.prop(this,"valueAsDate",a):e.prop(this,"valueAsNumber",o)}}})});var y={number:{mismatch:function(e){return!a(e)},step:1,stepScaleFactor:1,asNumber:function(e){return a(e)?e*1:s},numberToString:function(e){return a(e)?e:!1}},range:{minDefault:0,maxDefault:100},date:{mismatch:function(e){if(!e||!e.split||!/\d$/.test(e))return!0;var t,n=e.split(/\u002D/);if(n.length!==3)return!0;var r=!1;if(n[0].length!==4||n[1].length!=2||n[1]>12||n[2].length!=2||n[2]>33)r=!0;else for(t=0;t<3;t++)if(!c(n[0])){r=!0;break}return r||e!==this.dateToString(this.asDate(e,!0))},step:1,stepScaleFactor:864e5,asDate:function(e,t){return!t&&this.mismatch(e)?null:new Date(this.asNumber(e,!0))},asNumber:function(e,t){var n=s;if(t||!this.mismatch(e))e=e.split(/\u002D/),n=Date.UTC(e[0],e[1]-1,e[2]);return n},numberToString:function(e){return a(e)?this.dateToString(new Date(e*1)):!1},dateToString:function(e){return e&&e.getFullYear?e.getUTCFullYear()+"-"+p(e.getUTCMonth()+1,2)+"-"+p(e.getUTCDate(),2):!1}},time:{mismatch:function(t,n){if(!t||!t.split||!/\d$/.test(t))return!0;t=t.split(/\u003A/);if(t.length<2||t.length>3)return!0;var r=!1,i;return t[2]&&(t[2]=t[2].split(/\u002E/),i=parseInt(t[2][1],10),t[2]=t[2][0]),e.each(t,function(e,t){if(!c(t)||t.length!==2)return r=!0,!1}),r?!0:t[0]>23||t[0]<0||t[1]>59||t[1]<0?!0:t[2]&&(t[2]>59||t[2]<0)?!0:i&&isNaN(i)?!0:(i&&(i<100?i*=100:i<10&&(i*=10)),n===!0?[t,i]:!1)},step:60,stepBase:0,stepScaleFactor:1e3,asDate:function(e){return e=new Date(this.asNumber(e)),isNaN(e)?null:e},asNumber:function(e){var t=s;return e=this.mismatch(e,!0),e!==!0&&(t=Date.UTC("1970",0,1,e[0][0],e[0][1],e[0][2]||0),e[1]&&(t+=e[1])),t},dateToString:function(e){if(e&&e.getUTCHours){var t=p(e.getUTCHours(),2)+":"+p(e.getUTCMinutes(),2),n=e.getSeconds();return n!="0"&&(t+=":"+p(n,2)),n=e.getUTCMilliseconds(),n!="0"&&(t+="."+p(n,3)),t}return!1}},month:{mismatch:function(e){return y.date.mismatch(e+"-01")},step:1,stepScaleFactor:!1,asDate:function(e){return new Date(y.date.asNumber(e+"-01"))},asNumber:function(e){var t=s;return e&&!this.mismatch(e)&&(e=e.split(/\u002D/),e[0]=e[0]*1-1970,e[1]=e[1]*1-1,t=e[0]*12+e[1]),t},numberToString:function(e){var t,n=!1;return a(e)&&(t=e%12,e=(e-t)/12+1970,t+=1,t<1&&(e-=1,t+=12),n=p(e,4)+"-"+p(t,2)),n},dateToString:function(e){if(e&&e.getUTCHours){var t=y.date.dateToString(e);return t.split&&(t=t.split(/\u002D/))?t[0]+"-"+t[1]:!1}return!1}}};if(v||!f("range")||!f("time"))y.range=e.extend({},y.number,y.range),y.time=e.extend({},y.date,y.time),y.month=e.extend({},y.date,y.month);["number","month","range","date","time"].forEach(function(e){(v||!f(e))&&t.addInputType(e,y[e])}),e("<input />").prop("labels")==null&&t.defineNodeNamesProperty("button, input, keygen, meter, output, progress, select, textarea","labels",{prop:{get:function(){var t,n=this.id,r=e(this).closest("label").filter(function(){var e=this.htmlFor;return!e||e==n});return n&&(r=r.add('label[for="'+n+'"]')),r.get()},writeable:!1}})}),function(e){var t=0,n=function(e){return typeof e=="number"||e&&e==e*1},r=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex"],s={_create:function(){var t;this.element.addClass("ws-range").attr({role:"slider"}).html('<span class="ws-range-min" /><span class="ws-range-rail"><span class="ws-range-thumb" /></span>'),this.trail=e(".ws-range-rail",this.element),this.range=e(".ws-range-min",this.element),this.thumb=e(".ws-range-thumb",this.trail),this.dirs=this.element.innerHeight()>this.element.innerWidth()?{mouse:"pageY",pos:"top",range:"height",outerWidth:"outerHeight"}:{mouse:"pageX",pos:"left",range:"width",outerWidth:"outerWidth"},this.updateMetrics(),this.orig=this.options.orig;for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);this.value=this._value,this.value(this.options.value),this.list(this.options.options),this.element.data("rangeUi",this),this.addBindings(),this._init=!0},value:e.noop,_value:function(e,t,n){var r,i=e,s={},o={};!t&&parseFloat(e,10)!=e&&(e=this.options.min+(this.options.max-this.options.min)/2),t||(e=this.normalizeVal(e)),r=100*((e-this.options.min)/(this.options.max-this.options.min)),this.options.value=e,this.thumb.stop(),this.range.stop(),s[this.dirs.pos]=r+"%",o[this.dirs.range]=r+"%",n?(this.thumb.animate(s,{animate:this.options.animate}),this.range.animate(o,{animate:this.options.animate})):(this.thumb.css(s),this.range.css(o)),this.orig&&(i!=e||!this._init&&this.orig.value!=e)&&this.options._change(e),this.element.attr({"aria-valuenow":this.options.value,"aria-valuetext":this.options.options[this.options.value]||this.options.value})},list:function(t){var r=this.options,i=r.min,s=r.max,o=this.trail;r.options=t||{},this.element.attr({"aria-valuetext":r.options[r.value]||r.value}),e(".ws-range-ticks",o).remove(),e.each(r.options,function(e,t){if(!n(e)||e<i||e>s)return;var u=100*((e-i)/(s-i)),a=r.showLabels?' title="'+t+'"':"";o.append('<span class="ws-range-ticks"'+a+' style="'+this.dirs.pos+": "+u+'%;" />')})},readonly:function(e){e=!!e,this.options.readonly=e,this.element.attr("aria-readonly",""+e)},disabled:function(e){e=!!e,this.options.disabled=e,e?this.element.attr({tabindex:-1,"aria-disbaled":"true"}):this.element.attr({tabindex:this.options.tabindex,"aria-disbaled":"false"})},tabindex:function(e){this.options.tabindex=e,this.options.disabled||this.element.attr({tabindex:e})},title:function(e){this.element.prop("title",e)},min:function(e){this.options.min=r(e,0),this.value(this.options.value,!0)},max:function(e){this.options.max=r(e,100),this.value(this.options.value,!0)},step:function(e){this.options.step=e=="any"?"any":r(e,1),this.value(this.options.value)},normalizeVal:function(e){var t,n,r,i=this.options;return e<=i.min?e=i.min:e>=i.max?e=i.max:i.step!="any"&&(r=i.step,t=(e-i.min)%r,n=e-t,Math.abs(t)*2>=r&&(n+=t>0?r:-r),e=n.toFixed(5)*1),e},doStep:function(e){var t=r(this.options.step,1);this.options.step=="any"&&(t=Math.min(t,(this.options.max-this.options.min)/10)),this.value(this.options.value+t*e)},getStepedValueFromPos:function(e){var t,n,r,i;return e<=0?t=this.options.min:e>100?t=this.options.max:(t=(this.options.max-this.options.min)*(e/100)+this.options.min,i=this.options.step,i!="any"&&(n=(t-this.options.min)%i,r=t-n,Math.abs(n)*2>=i&&(r+=n>0?i:-i),t=r.toFixed(5)*1)),t},addBindings:function(){var t,n,r,i=this,s=this.options,o=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},i.orig&&e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),u=function(e,r){var u=i.getStepedValueFromPos((e[i.dirs.mouse]-t)*n);u!=s.value&&(i.value(u,!1,r),o.call("input",u))},a=function(t){t&&t.type=="mouseup"&&(o.call("input",s.value),o.call("change",s.value)),i.element.removeClass("ws-active"),e(document).off("mousemove",u).off("mouseup",a)},f=function(r){r.preventDefault(),e(document).off("mousemove",u).off("mouseup",a);if(!s.readonly&&!s.disabled){t=i.element.focus().addClass("ws-active").offset(),n=i.element.width();if(!n||!t)return;t=t[i.dirs.pos],n=100/(n-(i.thumb[i.dirs.outerWidth]()||2)/2),u(r,i.options.animate),e(document).on({mouseup:a,mousemove:u}),r.stopPropagation()}};o.init("input",s.value,this.options.input),o.init("change",s.value,this.options.change),this.element.on({mousedown:f,focus:function(e){s.disabled||(o.init("input",s.value),o.init("change",s.value),i.element.addClass("ws-focus")),r=!0},blur:function(e){i.element.removeClass("ws-focus ws-active"),r=!1,o.init("input",s.value),o.call("change",s.value)},keyup:function(){i.element.removeClass("ws-active"),o.call("input",s.value),o.call("change",s.value)},mousewheel:function(e,t){t&&r&&!s.readonly&&!s.disabled&&(i.doStep(t),e.preventDefault(),o.call("input",s.value))},keypress:function(e){var t=!0,n=e.keyCode;!s.readonly&&!s.disabled&&(n==39||n==38?i.doStep(1):n==37||n==40?i.doStep(-1):n==33?i.doStep(10):n==34?i.doStep(-10):n==36?i.value(i.options.max):n==35?i.value(i.options.min):t=!1,t&&(i.element.addClass("ws-active"),o.call("input",s.value),e.preventDefault()))}}),this.thumb.on({mousedown:f})},updateMetrics:function(){}};e.fn.rangeUI=function(t){return t=e.extend({readonly:!1,disabled:!1,tabindex:0,min:0,step:1,max:100,value:50,input:e.noop,change:e.noop,_change:e.noop,showLabels:!0},t),this.each(function(){e.webshims.objectCreate(s,{element:{value:e(this)}},t)})},jQuery.webshims.isReady("range-ui",!0)}(jQuery),jQuery.webshims.register("form-number-date-ui",function(e,t,n,r,i,s){"use strict";var o,u=function(e){return e?(e+="",e.length==1?"0"+e:e):""};(function(){var t=e.webshims.formcfg;t.de={numberFormat:{",":".",".":","},timeSigns:":. ",numberSigns:",",dateSigns:".",dFormat:".",patterns:{d:"dd.mm.yy"},date:{close:"schlie\u00dfen",prevText:"zur\u00fcck",nextText:"Vor",currentText:"heute",monthNames:["Januar","Februar","M\u00e4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],monthNamesShort:["Jan","Feb","M\u00e4r","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],dayNames:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],dayNamesShort:["So","Mo","Di","Mi","Do","Fr","Sa"],dayNamesMin:["So","Mo","Di","Mi","Do","Fr","Sa"],weekHeader:"KW",firstDay:1,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t.en={numberFormat:{".":".",",":","},numberSigns:".",dateSigns:"/",timeSigns:":. ",dFormat:"/",patterns:{d:"mm/dd/yy"},date:{closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t["en-US"]=t["en-US"]||t.en,t[""]=t[""]||t["en-US"],o=t[""];var n=function(t){if(!t.date.monthkeys){var n=function(e,n){var r,i=e+1;r=i<10?"0"+i:""+i,t.date.monthkeys[i]=r,t.date.monthkeys[n]=r};t.date.monthkeys={},e.each(t.date.monthNames,n),e.each(t.date.monthNamesShort,n)}};n(o),e.webshims.ready("dom-extend",function(){e.webshims.activeLang({register:"form-core",callback:function(){e.each(arguments,function(i,s){if(t[s])return o=t[s],n(o),e(r).triggerHandler("wslocalechange"),!1})}})})})(),function(){var t=function(t){e(this)[t.type=="mousepressstart"?"addClass":"removeClass"]("mousepress-ui")},n=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex","placeholder","value"],s=function(t){if(!o.patterns[t+"Obj"]){var n={};e.each(o.patterns[t].split(o[t+"Format"]),function(e,t){n[t]=e}),o.patterns[t+"Obj"]=n}},a={number:function(e){return(e+"").replace(/\,/g,"").replace(/\./,o.numberFormat["."])},time:function(e){return e},month:function(e,t){var n,r=e.split("-");return r[0]&&r[1]&&(n=o.date[t.monthNames]||o.date.monthNames,r[1]=n[r[1]*1-1],r[1]&&(e=o.date.showMonthAfterYear?r.join(" "):r[1]+" "+r[0])),e},date:function(e){var t=(e+"").split("-");return t[2]&&t[1]&&t[0]&&(e=o.patterns.d.replace("yy",t[0]||""),e=e.replace("mm",t[1]||""),e=e.replace("dd",t[2]||"")),e}},f={number:function(e){return(e+"").replace(o.numberFormat[","],"").replace(o.numberFormat["."],".")},time:function(e){return e},month:function(e){var t=e.trim().split(/[\s-\/\\]+/);return t.length==2&&(t[0]=o.date.monthkeys[t[0]]||t[0],t[1]=o.date.monthkeys[t[1]]||t[1],t[1].length==2?e=t[0]+"-"+t[1]:t[0].length==2&&(e=t[1]+"-"+t[0])),e},date:function(e){s("d");var t,n=o.patterns.dObj;return e=e.split(o.dFormat),e.length==3?[u(e[n.yy]),u(e[n.mm]),u(e[n.dd])].join("-"):""}},l={number:{step:1},time:{step:60},month:{step:1,start:new Date((new Date).getFullYear(),0,1)},date:{step:1,start:new Date((new Date).getFullYear(),0,1)}},c=function(){var t={};return function(n){var r;return t[n]||(r=e('<input type="'+n+'" />'),t[n]=function(e){var t=typeof e=="object"?"valueAsDate":"value";return r.prop(t,e).prop("valueAsNumber")}),t[n]}}();l.range=l.number;var h={_create:function(){var t;this.type=this.options.type,this.orig=this.options.orig,this.elemHelper=e('<input type="'+this.type+'" />'),this.asNumber=c(this.type),this.buttonWrapper=e('<span class="input-buttons '+this.type+'-input-buttons"><span unselectable="on" class="step-controls"><span class="step-up"></span><span class="step-down"></span></span></span>').insertAfter(this.element),typeof l[this.type].start=="object"&&(l[this.type].start=this.asNumber(l[this.type].start));for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);var n=this.element.attr("autocomplete","off").data("wsspinner",this);this.addBindings(),this._init=!0},parseValue:function(e){return f[this.type](e)},formatValue:function(e){return a[this.type](e,this.options)},placeholder:function(e){var t;this.options.placeholder=e,this.type=="date"&&(t=(e||"").split("-"),t.length==3&&(this.options.placeholder=o.patterns.d.replace("yy",t[0]).replace("mm",t[1]).replace("dd",t[2]))),this.element.prop("placeholder",this.options.placeholder)},addZero:u,_setStartInRange:function(){var e=l[this.type].start||0;!isNaN(this.minAsNumber)&&e<this.minAsNumber?e=this.minAsNumber:!isNaN(this.maxAsNumber)&&e>this.maxAsNumber&&(e=this.maxAsNumber),this.elemHelper.prop("valueAsNumber",e).prop("value"),this.options.defValue=this.elemHelper.prop("value")},value:function(e){this.valueAsNumber=this.asNumber(e),this.options.value=e,isNaN(this.valueAsNumber)?this._setStartInRange():this.elemHelper.prop("value",e),this.element.prop("value",a[this.type](e,this.options))},list:function(e){this.options.options=e||{}},readonly:function(e){this.options.readonly=!!e,this.element.prop("readonly",this.options.readonly),(this.options.readonly||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-readonly")},disabled:function(e){this.options.disabled=!!e,this.element.prop("disabled",this.options.disabled),(this.options.disabled||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-disabled")},tabindex:function(e){this.options.tabindex=e,this.element.prop("tabindex",this.options.tabindex)},title:function(e){this.options.title=e,this.element.prop("tabindex",this.options.title)},min:function(e){this.elemHelper.prop("min",e),this.minAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},max:function(e){this.elemHelper.prop("max",e),this.maxAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},step:function(e){var t=l[this.type];this.elemHelper.prop("step",n(e,t.step))},addBindings:function(){var n,i=this,s=this.options,u=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e]&&t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),a={},l=function(e){if(l.prevent)return e.preventDefault(),i.element.focus(),e.stopImmediatePropagation(),!0},c=function(){return!s.disabled&&!n&&i.element[0].focus(),l.set(),!1};l.set=function(){var e,t=function(){l.prevent=!1};return function(){clearTimeout(e),l.prevent=!0,setTimeout(t,9)}}(),["stepUp","stepDown"].forEach(function(e){a[e]=function(t){if(!s.disabled&&!s.readonly){n||c();var r=!1;t||(t=1);try{i.elemHelper[e](t),r=i.elemHelper.prop("value"),i.value(r),u.call("input",r)}catch(o){}return r}}}),this.buttonWrapper.on("mousedown",c),this.setChange=function(e){i.value(e),u.call("input",e),u.call("change",e)},this.element.on({blur:function(t){!l(t)&&!s.disabled&&!s.readonly&&(u.call("input",e.prop(i.orig,"value")),u.call("change",e.prop(i.orig,"value")),l.prevent||(n=!1))},focus:function(){u.init("input",e.prop(i.orig,"value"),i.options.input),u.init("change",e.prop(i.orig,"value"),i.options.change),n=!0},change:function(){var t=f[i.type](e.prop(this,"value"));e.prop(i.orig,"value",t),u.call("input",t),u.call("change",t)},mousewheel:function(e,t){t&&n&&!s.disabled&&(a[t>0?"stepUp":"stepDown"](),e.preventDefault())},keypress:function(e){var t,n=!0,r=e.keyCode;r==38?a.stepUp():r==40?a.stepDown():!e.ctrlKey&&!e.metaKey&&o[i.type+"Signs"]?(t=String.fromCharCode(e.charCode==null?r:e.charCode),n=!(t<" "||(o[i.type+"Signs"]+"0123456789").indexOf(t)>-1)):n=!1,n&&e.preventDefault()}}),e(r).on("wslocalechange",function(){i.value(i.options.value)}),e(".step-up",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepUp()}}),e(".step-down",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepDown()}})}};e.fn.spinbtnUI=function(t){return t=e.extend({monthNames:"monthNamesShort",size:1,startAt:0,selectNav:!1,openOnFocus:!1},t),this.each(function(){e.webshims.objectCreate(h,{element:{value:e(this)}},t)})}}(),function(){var n={},i={},s=function(e){return[e.getFullYear(),u(e.getMonth()+1),u(e.getDate())]};n.getYearList=function(e,t){var r,i,s,o,u,a,f;e=e[0]*1;var l=t.options.size||1,c=e%(12*l),h=e-c,p=t.options.max.split("-"),d=t.options.min.split("-"),v=0,m="";for(r=0;r<l;r++){r?h+=12:a=n.isInRange([h-1],p,d)?{"data-action":"setYearList",value:h-1}:!1,m+='<div class="year-list"><h3>'+h+" - "+(h+11)+"</h3>",u=[];for(i=0;i<12;i++)s=h+i,n.isInRange([s],p,d)?(o="",v++):o=' disabled="disabled"',u.push('<li><button type="button"'+o+'" data-action="setMonthList" value="'+s+'">'+s+"</button></li>");r==l-1&&(f=n.isInRange([s+1],p,d)?{"data-action":"setYearList",value:s+1}:!1),m+='<ul class="year-list">'+u.join("")+"</ul></div>"}return{enabled:v,main:m,next:f,prev:a}},n.getMonthList=function(e,t){var r,i,s,u,a,f,l,c,h,p=t.options.size||1,d=t.options.max.split("-"),v=t.options.min.split("-"),m=0,g="";e=e[0]-Math.floor((p-1)/2);for(r=0;r<p;r++){r?e++:c=n.isInRange([e-1],d,v)?{"data-action":"setMonthList",value:e-1}:!1,r==p-1&&(h=n.isInRange([e+1],d,v)?{"data-action":"setMonthList",value:e+1}:!1),f=[],!n.isInRange([e,"01"],d,v)&&!n.isInRange([e,"12"],d,v)?(a=' disabled="disabled"',l=!0):(l=!1,a=""),g+='<div class="month-list">',g+=t.options.selectNav?'<select data-action="setMonthList">'+n.createYearSelect(e,d,v).join("")+"</select>":'<button data-action="setYearList"'+a+' value="'+e+'">'+e+"</button>";for(i=0;i<12;i++)u=o.date.monthkeys[i+1],s=o.date.monthNames[i],l||!n.isInRange([e,u],d,v)?a=' disabled="disabled"':(a="",m++),f.push('<li><button type="button"'+a+'" data-action="'+(t.type=="month"?"changeInput":"setDayList")+'" value="'+e+"-"+u+'">'+s+"</button></li>");g+="<ul>"+f.join("")+"</ul></div>"}return{enabled:m,main:g,prev:c,next:h}},n.getDayList=function(e,t){var r,i,u,a,f,l,c,h,p,d,v,m,g,y,b,w,E,S,x=t.options.size||1,T=t.options.max.split("-"),N=t.options.min.split("-"),C=o.date[t.options.monthNames]||o.date.monthNames,k=0,L=[],A=new Date(e[0],e[1]-1,1);A.setMonth(A.getMonth()-Math.floor((x-1)/2));for(r=0;r<x;r++){m=A.getMonth(),r||(S=new Date(A.getTime()),S.setDate(-1),b=s(S),p=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1),b=s(A),L.push('<div class="day-list">'),t.options.selectNav?(w=['<select data-action="setDayList">'+n.createMonthSelect(b,T,N,C).join("")+"</select>",'<select data-action="setDayList">'+n.createYearSelect(b[0],T,N,"-"+b[1]).join("")+"</select>"],o.date.showMonthAfterYear&&w.reverse(),L.push(w.join(" "))):(w=[C[b[1]*1-1],b[0]],o.date.showMonthAfterYear&&w.reverse(),L.push('<button data-action="setMonthList" value="'+b[0]+"-"+b[1]+'">'+w.join(" ")+"</button>")),L.push("<table><tr>");for(u=1;u<o.date.dayNamesShort.length;u++)L.push("<th>"+o.date.dayNamesShort[u]+"</th>");L.push("<th>"+o.date.dayNamesShort[0]+"</th>"),L.push("</tr><tr>");for(i=0;i<46;i++){v=i&&!(i%7),g=A.getMonth(),y=m!=g;if(v&&y){L.push("</tr>");break}v&&L.push("</tr><tr>"),i||(a=A.getDay()-1,a>-1&&a<6&&A.setDate(A.getDate()-a),g=A.getMonth(),y=m!=g),b=s(A),E='<td><button data-action="changeInput" value="'+b.join("-")+'"',y&&(E+=' data-othermonth=""'),n.isInRange(b,T,N)||(E+=' disabled=""'),L.push(E+">"+A.getDate()+"</button></td>"),A.setDate(A.getDate()+1)}L.push("</table></div>"),r==x-1&&(b=s(A),b[2]=1,d=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1)}return{enabled:9,main:L.join(""),prev:p,next:d}},n.isInRange=function(e,t,n){var r,i=!0;for(r=0;r<e.length;r++){if(n[r]&&n[r]>e[r]){i=!1;break}if(!n[r]||n[r]!=e[r])break}if(i)for(r=0;r<e.length;r++){if(t[r]&&t[r]<e[r]){i=!1;break}if(!t[r]||t[r]!=e[r])break}return i},n.createMonthSelect=function(e,t,r,i){i||(i=o.date.monthNames);var s,a=0,f=[],l=e[1]-1;for(;a<i.length;a++)s=l==a?' selected=""':"",(s||n.isInRange([e[0],a+1],t,r))&&f.push('<option value="'+e[0]+"-"+u(a+1)+'"'+s+">"+i[a]+"</option>");return f},n.createYearSelect=function(e,t,r,i){var s,o=!0,u=!0,a=['<option selected="">'+e+"</option>"],f=0;i||(i="");while(f<8&&(o||u))f++,s=e-f,o&&n.isInRange([s],t,r)?a.unshift('<option value="'+(s+i)+'">'+s+"</option>"):o=!1,s=e+f,u&&n.isInRange([s],t,r)?a.push('<option value="'+(s+i)+'">'+s+"</option>"):u=!1;return a};var a={changeInput:function(e,t,n){n.setChange(e),t.hide()}};(function(){var t=function(e){return"get"+e+"List"},r={date:"Day",week:"Day",month:"Month"};e.each({setYearList:["Year","Month","Day"],setMonthList:["Month","Day"],setDayList:["Day"]},function(i,s){var o=s.map(t);a[i]=function(t,i,u,a){var f=t.split("-");a||(a=0),e.each(o,function(e,t){if(e>=a){var o=n[t](f,u);if(f.length<2||o.enabled>1||r[u.type]===s[e])return i.bodyElement.html(o.main),o.prev?i.prevElement.attr(o.prev).prop({disabled:!1}):i.prevElement.removeAttr("data-action").prop({disabled:!0}),o.next?i.nextElement.attr(o.next).prop({disabled:!1}):i.nextElement.removeAttr("data-action").prop({disabled:!0}),!1}})}})})(),n.commonInit=function(t,n){t.list=function(r){var i=this.options,s=[];i.options=r||{},e("div.ws-options",n.contentElement).remove(),e.each(i.options,function(e,n){s.push('<li><button value="'+e+'" data-action="changeInput">'+(n||t.formatValue(e))+"</button></li>")}),s.length&&n.contentElement.append('<div class="ws-options"><ul>'+s.join("")+"</ul></div>")},n.contentElement.html('<button class="ws-prev"></button><button class="ws-next"></button><div class="ws-picker-body"></div>'),n.nextElement=e("button.ws-next",n.contentElement),n.prevElement=e("button.ws-prev",n.contentElement),n.bodyElement=e("div.ws-picker-body",n.contentElement),e(r).onTrigger("wslocalechange",function(){n.nextElement.text(o.date.nextText),n.prevElement.text(o.date.prevText)}),t.list(t.options.options)},n.month=function(r){var i=t.objectCreate(t.wsPopover,{},{prepareFor:r.element}),s=e('<span class="popover-opener" />').appendTo(r.buttonWrapper),o=r.options,u=!1,f=function(){var n=e(this).attr("data-action");return a[n]?a[n](e(this).val(),i,r):t.warn("no action for "+n),!1},l=function(){!o.disabled&&!o.readonly&&(u||(n.commonInit(r,i),a.setYearList(o.value||o.defValue,i,r,r.options.startAt)),u=!0,i.show(r.element))};i.element.addClass(r.type+"-popover"),i.contentElement.on("click","button[data-action]",f).on("change","select[data-action]",f),s.on("mousedown",l),r.element.on({focus:function(){r.options.openOnFocus&&l()},mousedown:function(){r.element.is(":focus")&&l()}})},n.date=n.month,t.picker=n}(),function(){var n=Modernizr.inputtypes,i,o={},u=["disabled","readonly","value","min","max","step","title","placeholder"],a=["tabindex","data-placeholder"],f=function(e){};e.each(u.concat(a),function(e,n){var r=n.replace(/^data\-/,"");t.onNodeNamesPropertyModify("input",n,function(e){if(!i){var n=t.data(this,"shadowData");n&&n.data&&n.nativeElement===this&&n.data[r]&&n.data[r](e)}})});var l=function(){return function(t,n){o[t]=n,n.attrs=e.merge([],a,n.attrs),n.props=e.merge([],u,n.props)}}(),c=function(t,n){var r=e.prop(t,"list"),i={},s,o;return r&&e("option",r).each(function(){i[e.prop(this,"value")]=e.prop(this,"label")}),n&&(o=function(){n.shim&&(clearTimeout(s),s=setTimeout(function(){n.shim.list(c(t))},9))},e(r).on("updateDatalist",o),e(t).on("listdatalistchange",o)),i},h=function(e){e.stopImmediatePropagation(e)},p=function(){return e.css(this,"display")!="none"},d=function(t){var n,i=function(){e.style(t.orig,"display","");var r=.6;if(!n||t.orig.offsetWidth)t.element.css({marginLeft:e.css(t.orig,"marginLeft"),marginRight:e.css(t.orig,"marginRight")}),t.buttonWrapper&&(t.element.css({paddingRight:""}),(parseInt(t.buttonWrapper.css("marginLeft"),10)||0)<0?t.element.css({paddingRight:""}).css({paddingRight:(parseInt(t.element.css("paddingRight"),10)||0)+t.buttonWrapper.outerWidth()}):r=t.buttonWrapper.outerWidth(!0)+.6),t.element.outerWidth(e(t.orig).outerWidth()-r);n=!0,e.style(t.orig,"display","none")};e(r).onTrigger("updateshadowdom",i)},v=function(){var n=e.prop(this,"type"),r,f,l,p,v;if(o[n]){l={},p=n,f=e.extend({},s[n],e(e.prop(this,"form")).data(n)||{},e(this).data(n)||{},{orig:this,type:n,options:c(this,l),input:function(e){f._change(e,"input")},change:function(e){f._change(e,"change")},_change:function(t,n){i=!0,e.prop(f.orig,"value",t),i=!1,n&&e(f.orig).trigger(n)}});for(r=0;r<u.length;r++)f[u[r]]=e.prop(this,u[r]);for(r=0;r<a.length;r++)p=a[r].replace(/^data\-/,""),f[p]||(f[p]=e.attr(this,a[r]));l.shim=o[n]._create(f),t.addShadowDom(this,l.shim.element,{data:l.shim||{}}),e(this).on("change",function(t){!i&&t.originalEvent&&l.shim.value(e.prop(this,"value"))}),l.shim.element.on("change input",h),l.shim.element.on("focusin focusout",function(t){t.stopImmediatePropagation(t),e(f.orig).trigger(t)}),l.shim.element.on("focus blur",function(t){t.stopImmediatePropagation(t),e(f.orig).triggerHandler(t)}),v=f.calculateWidth!=null?f.calculateWidth:s.calculateWidth,v&&d(l.shim),e(this).css({display:"none"})}};(!n.range||s.replaceUI)&&l("range",{_create:function(t,n){return e("<span />").insertAfter(t.orig).rangeUI(t).data("rangeUi")}}),["number","time","month","date"].forEach(function(r){(!n[r]||s.replaceUI)&&l(r,{_create:function(n,i){var s=e('<input class="ws-'+r+'" type="text" />').insertAfter(n.orig).spinbtnUI(n).data("wsspinner");return t.picker&&t.picker[r]&&t.picker[r](s),s.buttonWrapper.addClass("input-button-size-"+s.buttonWrapper.children().filter(p).length),s}})}),t.addReady(function(t,n){e("input",t).add(n.filter("input")).each(v)})}()});
+jQuery.webshims.register("form-native-extend",function(e,t,n,r,i,s){"use strict";var o=n.Modernizr,u=o.inputtypes;if(!o.formvalidation||t.bugs.bustedValidity)return;var a=t.inputTypes,f={};t.addInputType=function(e,t){a[e]=t},t.addValidityRule=function(e,t){f[e]=t},t.addValidityRule("typeMismatch",function(e,t,n,r){if(t==="")return!1;var i=r.typeMismatch;return"type"in n||(n.type=(e[0].getAttribute("type")||"").toLowerCase()),a[n.type]&&a[n.type].mismatch&&(i=a[n.type].mismatch(t,e)),i});var l=s.overrideMessages,c=!u.number||!u.time||!u.range||l,h=["customError","typeMismatch","rangeUnderflow","rangeOverflow","stepMismatch","tooLong","patternMismatch","valueMissing","valid"],p=l?["value","checked"]:["value"],d=[],v=function(t,n){if(!t)return;var i=(t.getAttribute&&t.getAttribute("type")||t.type||"").toLowerCase();if(!l&&!a[i])return;l&&!n&&i=="radio"&&t.name?e(r.getElementsByName(t.name)).each(function(){e.prop(this,"validity")}):e.prop(t,"validity")},m={};["input","textarea","select"].forEach(function(n){var r=t.defineNodeNameProperty(n,"setCustomValidity",{prop:{value:function(i){i+="";var s=n=="input"?e(this).getNativeElement()[0]:this;r.prop._supvalue.call(s,i),t.bugs.validationMessage&&t.data(s,"customvalidationMessage",i),c&&(t.data(s,"hasCustomError",!!i),v(s))}}});m[n]=r.prop._supvalue});if(c||l)p.push("min"),p.push("max"),p.push("step"),d.push("input");l&&(p.push("required"),p.push("pattern"),d.push("select"),d.push("textarea"));if(c){var g;d.forEach(function(n){var r=t.defineNodeNameProperty(n,"validity",{prop:{get:function(){if(g)return;var i=n=="input"?e(this).getNativeElement()[0]:this,s=r.prop._supget.call(i);if(!s)return s;var o={};h.forEach(function(e){o[e]=s[e]});if(!e.prop(i,"willValidate"))return o;g=!0;var u=e(i),c={type:(i.getAttribute&&i.getAttribute("type")||"").toLowerCase(),nodeName:(i.nodeName||"").toLowerCase()},p=u.val(),d=!!t.data(i,"hasCustomError"),v;g=!1,o.customError=d;if(o.valid&&o.customError)o.valid=!1;else if(!o.valid){var y=!0;e.each(o,function(e,t){if(t)return y=!1,!1}),y&&(o.valid=!0)}return e.each(f,function(e,r){o[e]=r(u,p,c,o),o[e]&&(o.valid||!v)&&(l||a[c.type]&&a[c.type].mismatch)&&(m[n].call(i,t.createValidationMessage(i,e)),o.valid=!1,v=!0)}),o.valid?(m[n].call(i,""),t.data(i,"hasCustomError",!1)):l&&!v&&!d&&e.each(o,function(e,r){if(e!=="valid"&&r)return m[n].call(i,t.createValidationMessage(i,e)),!1}),o},writeable:!1}})}),p.forEach(function(e){t.onNodeNamesPropertyModify(d,e,function(e){v(this)})});if(r.addEventListener){var y,b=function(t){if(!("form"in t.target))return;var n=t.target.form;clearTimeout(y),v(t.target),n&&l&&e("input",n).each(function(){this.type=="password"&&v(this)})};r.addEventListener("change",b,!0),l&&(r.addEventListener("blur",b,!0),r.addEventListener("keydown",function(e){if(e.keyCode!=13)return;b(e)},!0)),r.addEventListener("input",function(e){clearTimeout(y),y=setTimeout(function(){v(e.target)},290)},!0)}var w=d.join(",");t.addReady(function(t,n){e(w,t).add(n.filter(w)).each(function(){e.prop(this,"validity")})}),l&&t.ready("DOM form-message",function(){t.activeLang({register:"form-core",callback:function(){e("input, select, textarea").getNativeElement().each(function(){if(t.data(this,"hasCustomError"))return;var n=this,r=e.prop(n,"validity")||{valid:!0},i;if(r.valid)return;i=(n.nodeName||"").toLowerCase(),e.each(r,function(e,r){if(e!=="valid"&&r)return m[i].call(n,t.createValidationMessage(n,e)),!1})})}})})}t.defineNodeNameProperty("input","type",{prop:{get:function(){var e=this,n=(e.getAttribute("type")||"").toLowerCase();return t.inputTypes[n]?n:e.type}}})}),jQuery.webshims.register("form-number-date-api",function(e,t,n,r,i){"use strict";t.getStep||(t.getStep=function(t,n){var r=e.attr(t,"step");return r==="any"?r:(n=n||l(t),!u[n]||!u[n].step?r:(r=y.number.asNumber(r),(!isNaN(r)&&r>0?r:u[n].step)*(u[n].stepScaleFactor||1)))}),t.addMinMaxNumberToCache||(t.addMinMaxNumberToCache=function(e,t,n){e+"AsNumber"in n||(n[e+"AsNumber"]=u[n.type].asNumber(t.attr(e)),isNaN(n[e+"AsNumber"])&&e+"Default"in u[n.type]&&(n[e+"AsNumber"]=u[n.type][e+"Default"]))});var s=parseInt("NaN",10),o=r,u=t.inputTypes,a=function(e){return typeof e=="number"||e&&e==e*1},f=function(t){return e('<input type="'+t+'" />').prop("type")===t},l=function(e){return(e.getAttribute("type")||"").toLowerCase()},c=function(e){var t=e*1;return e&&(t==e||e=="0"+t)},h=t.addMinMaxNumberToCache,p=function(e,t){e=""+e,t-=e.length;for(var n=0;n<t;n++)e="0"+e;return e},d=1e-7,v=t.bugs.bustedValidity;t.addValidityRule("stepMismatch",function(e,n,r,i){if(n==="")return!1;"type"in r||(r.type=l(e[0]));var s=(i||{}).stepMismatch||!1,o;if(u[r.type]&&u[r.type].step){"step"in r||(r.step=t.getStep(e[0],r.type));if(r.step=="any")return!1;"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h("min",e,r),o=r.minAsNumber,isNaN(o)&&(o=u[r.type].stepBase||0),s=Math.abs((r.valueAsNumber-o)%r.step),s=!(s<=d||Math.abs(s-r.step)<=d)}return s}),[{name:"rangeOverflow",attr:"max",factor:1},{name:"rangeUnderflow",attr:"min",factor:-1}].forEach(function(e,n){t.addValidityRule(e.name,function(t,n,r,i){var s=(i||{})[e.name]||!1;if(n==="")return s;"type"in r||(r.type=l(t[0]));if(u[r.type]&&u[r.type].asNumber){"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h(e.attr,t,r);if(isNaN(r[e.attr+"AsNumber"]))return s;s=r[e.attr+"AsNumber"]*e.factor<r.valueAsNumber*e.factor-d}return s})}),t.reflectProperties(["input"],["max","min","step"]);var m=t.defineNodeNameProperty("input","valueAsNumber",{prop:{get:function(){var t=this,n=l(t),r=u[n]&&u[n].asNumber?u[n].asNumber(e.prop(t,"value")):m.prop._supget&&m.prop._supget.apply(t,arguments);return r==null&&(r=s),r},set:function(n){var r=this,i=l(r);if(u[i]&&u[i].numberToString){if(isNaN(n)){e.prop(r,"value","");return}var s=u[i].numberToString(n);s!==!1?e.prop(r,"value",s):t.error("INVALID_STATE_ERR: DOM Exception 11")}else m.prop._supset&&m.prop._supset.apply(r,arguments)}}}),g=t.defineNodeNameProperty("input","valueAsDate",{prop:{get:function(){var t=this,n=l(t);return u[n]&&u[n].asDate&&!u[n].noAsDate?u[n].asDate(e.prop(t,"value")):g.prop._supget&&g.prop._supget.call(t)||null},set:function(n){var r=this,i=l(r);if(!(u[i]&&u[i].dateToString&&!u[i].noAsDate))return g.prop._supset&&g.prop._supset.apply(r,arguments)||null;if(n===null)return e.prop(r,"value",""),"";var s=u[i].dateToString(n);if(s!==!1)return e.prop(r,"value",s),s;t.error("INVALID_STATE_ERR: DOM Exception 11")}}});e.each({stepUp:1,stepDown:-1},function(n,r){var i=t.defineNodeNameProperty("input",n,{prop:{value:function(n){var s,o,a,f,c,h,p=l(this);if(!u[p]||!u[p].asNumber){if(i.prop&&i.prop.value)return i.prop.value.apply(this,arguments);throw t.info("no step method for type: "+p),"invalid state error"}h={type:p},n||(n=1,t.info("you should always use a factor for stepUp/stepDown")),n*=r,o=e.prop(this,"valueAsNumber");if(isNaN(o))throw t.info("valueAsNumber is NaN can't apply stepUp/stepDown "),"invalid state error";s=t.getStep(this,p);if(s=="any")throw t.info("step is 'any' can't apply stepUp/stepDown"),"invalid state error";t.addMinMaxNumberToCache("min",e(this),h),t.addMinMaxNumberToCache("max",e(this),h),s*=n,o+=s,f=(o-(h.minAsNumber||0))%s,f&&Math.abs(f)>d&&(c=o-f,c+=f>0?s:-s,o=c.toFixed(5)*1);if(!isNaN(h.maxAsNumber)&&o>h.maxAsNumber||!isNaN(h.minAsNumber)&&o<h.minAsNumber)throw t.info("max/min overflow can't apply stepUp/stepDown"),"invalid state error";a?e.prop(this,"valueAsDate",a):e.prop(this,"valueAsNumber",o)}}})});var y={number:{mismatch:function(e){return!a(e)},step:1,stepScaleFactor:1,asNumber:function(e){return a(e)?e*1:s},numberToString:function(e){return a(e)?e:!1}},range:{minDefault:0,maxDefault:100},date:{mismatch:function(e){if(!e||!e.split||!/\d$/.test(e))return!0;var t,n=e.split(/\u002D/);if(n.length!==3)return!0;var r=!1;if(n[0].length!==4||n[1].length!=2||n[1]>12||n[2].length!=2||n[2]>33)r=!0;else for(t=0;t<3;t++)if(!c(n[0])){r=!0;break}return r||e!==this.dateToString(this.asDate(e,!0))},step:1,stepScaleFactor:864e5,asDate:function(e,t){return!t&&this.mismatch(e)?null:new Date(this.asNumber(e,!0))},asNumber:function(e,t){var n=s;if(t||!this.mismatch(e))e=e.split(/\u002D/),n=Date.UTC(e[0],e[1]-1,e[2]);return n},numberToString:function(e){return a(e)?this.dateToString(new Date(e*1)):!1},dateToString:function(e){return e&&e.getFullYear?e.getUTCFullYear()+"-"+p(e.getUTCMonth()+1,2)+"-"+p(e.getUTCDate(),2):!1}},time:{mismatch:function(t,n){if(!t||!t.split||!/\d$/.test(t))return!0;t=t.split(/\u003A/);if(t.length<2||t.length>3)return!0;var r=!1,i;return t[2]&&(t[2]=t[2].split(/\u002E/),i=parseInt(t[2][1],10),t[2]=t[2][0]),e.each(t,function(e,t){if(!c(t)||t.length!==2)return r=!0,!1}),r?!0:t[0]>23||t[0]<0||t[1]>59||t[1]<0?!0:t[2]&&(t[2]>59||t[2]<0)?!0:i&&isNaN(i)?!0:(i&&(i<100?i*=100:i<10&&(i*=10)),n===!0?[t,i]:!1)},step:60,stepBase:0,stepScaleFactor:1e3,asDate:function(e){return e=new Date(this.asNumber(e)),isNaN(e)?null:e},asNumber:function(e){var t=s;return e=this.mismatch(e,!0),e!==!0&&(t=Date.UTC("1970",0,1,e[0][0],e[0][1],e[0][2]||0),e[1]&&(t+=e[1])),t},dateToString:function(e){if(e&&e.getUTCHours){var t=p(e.getUTCHours(),2)+":"+p(e.getUTCMinutes(),2),n=e.getSeconds();return n!="0"&&(t+=":"+p(n,2)),n=e.getUTCMilliseconds(),n!="0"&&(t+="."+p(n,3)),t}return!1}},month:{mismatch:function(e){return y.date.mismatch(e+"-01")},step:1,stepScaleFactor:!1,asDate:function(e){return new Date(y.date.asNumber(e+"-01"))},asNumber:function(e){var t=s;return e&&!this.mismatch(e)&&(e=e.split(/\u002D/),e[0]=e[0]*1-1970,e[1]=e[1]*1-1,t=e[0]*12+e[1]),t},numberToString:function(e){var t,n=!1;return a(e)&&(t=e%12,e=(e-t)/12+1970,t+=1,t<1&&(e-=1,t+=12),n=p(e,4)+"-"+p(t,2)),n},dateToString:function(e){if(e&&e.getUTCHours){var t=y.date.dateToString(e);return t.split&&(t=t.split(/\u002D/))?t[0]+"-"+t[1]:!1}return!1}}};if(v||!f("range")||!f("time"))y.range=e.extend({},y.number,y.range),y.time=e.extend({},y.date,y.time),y.month=e.extend({},y.date,y.month);["number","month","range","date","time"].forEach(function(e){(v||!f(e))&&t.addInputType(e,y[e])}),e("<input />").prop("labels")==null&&t.defineNodeNamesProperty("button, input, keygen, meter, output, progress, select, textarea","labels",{prop:{get:function(){if(this.type=="hidden")return null;var t=this.id,n=e(this).closest("label").filter(function(){var e=this.attributes["for"]||{};return!e.specified||e.value==t});return t&&(n=n.add('label[for="'+t+'"]')),n.get()},writeable:!1}})}),function(e){var t=0,n=function(e){return typeof e=="number"||e&&e==e*1},r=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex"],s={_create:function(){var t;this.element.addClass("ws-range").attr({role:"slider"}).html('<span class="ws-range-min" /><span class="ws-range-rail"><span class="ws-range-thumb" /></span>'),this.trail=e(".ws-range-rail",this.element),this.range=e(".ws-range-min",this.element),this.thumb=e(".ws-range-thumb",this.trail),this.dirs=this.element.innerHeight()>this.element.innerWidth()?{mouse:"pageY",pos:"top",range:"height",outerWidth:"outerHeight"}:{mouse:"pageX",pos:"left",range:"width",outerWidth:"outerWidth"},this.updateMetrics(),this.orig=this.options.orig;for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);this.value=this._value,this.value(this.options.value),this.list(this.options.options),this.element.data("rangeUi",this),this.addBindings(),this._init=!0},value:e.noop,_value:function(e,t,n){var r,i=e,s={},o={};!t&&parseFloat(e,10)!=e&&(e=this.options.min+(this.options.max-this.options.min)/2),t||(e=this.normalizeVal(e)),r=100*((e-this.options.min)/(this.options.max-this.options.min)),this.options.value=e,this.thumb.stop(),this.range.stop(),s[this.dirs.pos]=r+"%",o[this.dirs.range]=r+"%",n?(this.thumb.animate(s,{animate:this.options.animate}),this.range.animate(o,{animate:this.options.animate})):(this.thumb.css(s),this.range.css(o)),this.orig&&(i!=e||!this._init&&this.orig.value!=e)&&this.options._change(e),this.element.attr({"aria-valuenow":this.options.value,"aria-valuetext":this.options.options[this.options.value]||this.options.value})},list:function(t){var r=this.options,i=r.min,s=r.max,o=this.trail;r.options=t||{},this.element.attr({"aria-valuetext":r.options[r.value]||r.value}),e(".ws-range-ticks",o).remove(),e.each(r.options,function(e,t){if(!n(e)||e<i||e>s)return;var u=100*((e-i)/(s-i)),a=r.showLabels?' title="'+t+'"':"";o.append('<span class="ws-range-ticks"'+a+' style="'+this.dirs.pos+": "+u+'%;" />')})},readonly:function(e){e=!!e,this.options.readonly=e,this.element.attr("aria-readonly",""+e)},disabled:function(e){e=!!e,this.options.disabled=e,e?this.element.attr({tabindex:-1,"aria-disbaled":"true"}):this.element.attr({tabindex:this.options.tabindex,"aria-disbaled":"false"})},tabindex:function(e){this.options.tabindex=e,this.options.disabled||this.element.attr({tabindex:e})},title:function(e){this.element.prop("title",e)},min:function(e){this.options.min=r(e,0),this.value(this.options.value,!0)},max:function(e){this.options.max=r(e,100),this.value(this.options.value,!0)},step:function(e){this.options.step=e=="any"?"any":r(e,1),this.value(this.options.value)},normalizeVal:function(e){var t,n,r,i=this.options;return e<=i.min?e=i.min:e>=i.max?e=i.max:i.step!="any"&&(r=i.step,t=(e-i.min)%r,n=e-t,Math.abs(t)*2>=r&&(n+=t>0?r:-r),e=n.toFixed(5)*1),e},doStep:function(e){var t=r(this.options.step,1);this.options.step=="any"&&(t=Math.min(t,(this.options.max-this.options.min)/10)),this.value(this.options.value+t*e)},getStepedValueFromPos:function(e){var t,n,r,i;return e<=0?t=this.options.min:e>100?t=this.options.max:(t=(this.options.max-this.options.min)*(e/100)+this.options.min,i=this.options.step,i!="any"&&(n=(t-this.options.min)%i,r=t-n,Math.abs(n)*2>=i&&(r+=n>0?i:-i),t=r.toFixed(5)*1)),t},addBindings:function(){var t,n,r,i=this,s=this.options,o=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},i.orig&&e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),u=function(e,r){var u=i.getStepedValueFromPos((e[i.dirs.mouse]-t)*n);u!=s.value&&(i.value(u,!1,r),o.call("input",u))},a=function(t){t&&t.type=="mouseup"&&(o.call("input",s.value),o.call("change",s.value)),i.element.removeClass("ws-active"),e(document).off("mousemove",u).off("mouseup",a)},f=function(r){r.preventDefault(),e(document).off("mousemove",u).off("mouseup",a);if(!s.readonly&&!s.disabled){t=i.element.focus().addClass("ws-active").offset(),n=i.element.width();if(!n||!t)return;t=t[i.dirs.pos],n=100/(n-(i.thumb[i.dirs.outerWidth]()||2)/2),u(r,i.options.animate),e(document).on({mouseup:a,mousemove:u}),r.stopPropagation()}};o.init("input",s.value,this.options.input),o.init("change",s.value,this.options.change),this.element.on({mousedown:f,focus:function(e){s.disabled||(o.init("input",s.value),o.init("change",s.value),i.element.addClass("ws-focus")),r=!0},blur:function(e){i.element.removeClass("ws-focus ws-active"),r=!1,o.init("input",s.value),o.call("change",s.value)},keyup:function(){i.element.removeClass("ws-active"),o.call("input",s.value),o.call("change",s.value)},mousewheel:function(e,t){t&&r&&!s.readonly&&!s.disabled&&(i.doStep(t),e.preventDefault(),o.call("input",s.value))},keypress:function(e){var t=!0,n=e.keyCode;!s.readonly&&!s.disabled&&(n==39||n==38?i.doStep(1):n==37||n==40?i.doStep(-1):n==33?i.doStep(10):n==34?i.doStep(-10):n==36?i.value(i.options.max):n==35?i.value(i.options.min):t=!1,t&&(i.element.addClass("ws-active"),o.call("input",s.value),e.preventDefault()))}}),this.thumb.on({mousedown:f})},updateMetrics:function(){}};e.fn.rangeUI=function(t){return t=e.extend({readonly:!1,disabled:!1,tabindex:0,min:0,step:1,max:100,value:50,input:e.noop,change:e.noop,_change:e.noop,showLabels:!0},t),this.each(function(){e.webshims.objectCreate(s,{element:{value:e(this)}},t)})},jQuery.webshims.isReady("range-ui",!0)}(jQuery),jQuery.webshims.register("form-number-date-ui",function(e,t,n,r,i,s){"use strict";var o,u=function(e){return e?(e+="",e.length==1?"0"+e:e):""};(function(){var t=e.webshims.formcfg;t.de={numberFormat:{",":".",".":","},timeSigns:":. ",numberSigns:",",dateSigns:".",dFormat:".",patterns:{d:"dd.mm.yy"},date:{close:"schlie\u00dfen",prevText:"zur\u00fcck",nextText:"Vor",currentText:"heute",monthNames:["Januar","Februar","M\u00e4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],monthNamesShort:["Jan","Feb","M\u00e4r","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],dayNames:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],dayNamesShort:["So","Mo","Di","Mi","Do","Fr","Sa"],dayNamesMin:["So","Mo","Di","Mi","Do","Fr","Sa"],weekHeader:"KW",firstDay:1,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t.en={numberFormat:{".":".",",":","},numberSigns:".",dateSigns:"/",timeSigns:":. ",dFormat:"/",patterns:{d:"mm/dd/yy"},date:{closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t["en-US"]=t["en-US"]||t.en,t[""]=t[""]||t["en-US"],o=t[""];var n=function(t){if(!t.date.monthkeys){var n=function(e,n){var r,i=e+1;r=i<10?"0"+i:""+i,t.date.monthkeys[i]=r,t.date.monthkeys[n]=r};t.date.monthkeys={},e.each(t.date.monthNames,n),e.each(t.date.monthNamesShort,n)}};n(o),e.webshims.ready("dom-extend",function(){e.webshims.activeLang({register:"form-core",callback:function(){e.each(arguments,function(i,s){if(t[s])return o=t[s],n(o),e(r).triggerHandler("wslocalechange"),!1})}})})})(),function(){var t=function(t){e(this)[t.type=="mousepressstart"?"addClass":"removeClass"]("mousepress-ui")},n=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex","placeholder","value"],s=function(t){if(!o.patterns[t+"Obj"]){var n={};e.each(o.patterns[t].split(o[t+"Format"]),function(e,t){n[t]=e}),o.patterns[t+"Obj"]=n}},a={number:function(e){return(e+"").replace(/\,/g,"").replace(/\./,o.numberFormat["."])},time:function(e){return e},month:function(e,t){var n,r=e.split("-");return r[0]&&r[1]&&(n=o.date[t.monthNames]||o.date.monthNames,r[1]=n[r[1]*1-1],r[1]&&(e=o.date.showMonthAfterYear?r.join(" "):r[1]+" "+r[0])),e},date:function(e){var t=(e+"").split("-");return t[2]&&t[1]&&t[0]&&(e=o.patterns.d.replace("yy",t[0]||""),e=e.replace("mm",t[1]||""),e=e.replace("dd",t[2]||"")),e}},f={number:function(e){return(e+"").replace(o.numberFormat[","],"").replace(o.numberFormat["."],".")},time:function(e){return e},month:function(e){var t=e.trim().split(/[\s-\/\\]+/);return t.length==2&&(t[0]=o.date.monthkeys[t[0]]||t[0],t[1]=o.date.monthkeys[t[1]]||t[1],t[1].length==2?e=t[0]+"-"+t[1]:t[0].length==2&&(e=t[1]+"-"+t[0])),e},date:function(e){s("d");var t,n=o.patterns.dObj;return e=e.split(o.dFormat),e.length==3?[u(e[n.yy]),u(e[n.mm]),u(e[n.dd])].join("-"):""}},l={number:{step:1},time:{step:60},month:{step:1,start:new Date((new Date).getFullYear(),0,1)},date:{step:1,start:new Date((new Date).getFullYear(),0,1)}},c=function(){var t={};return function(n){var r;return t[n]||(r=e('<input type="'+n+'" />'),t[n]=function(e){var t=typeof e=="object"?"valueAsDate":"value";return r.prop(t,e).prop("valueAsNumber")}),t[n]}}();l.range=l.number;var h={_create:function(){var t;this.type=this.options.type,this.orig=this.options.orig,this.elemHelper=e('<input type="'+this.type+'" />'),this.asNumber=c(this.type),this.buttonWrapper=e('<span class="input-buttons '+this.type+'-input-buttons"><span unselectable="on" class="step-controls"><span class="step-up"></span><span class="step-down"></span></span></span>').insertAfter(this.element),typeof l[this.type].start=="object"&&(l[this.type].start=this.asNumber(l[this.type].start));for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);var n=this.element.attr("autocomplete","off").data("wsspinner",this);this.addBindings(),this._init=!0},parseValue:function(e){return f[this.type](e)},formatValue:function(e){return a[this.type](e,this.options)},placeholder:function(e){var t;this.options.placeholder=e,this.type=="date"&&(t=(e||"").split("-"),t.length==3&&(this.options.placeholder=o.patterns.d.replace("yy",t[0]).replace("mm",t[1]).replace("dd",t[2]))),this.element.prop("placeholder",this.options.placeholder)},addZero:u,_setStartInRange:function(){var e=l[this.type].start||0;!isNaN(this.minAsNumber)&&e<this.minAsNumber?e=this.minAsNumber:!isNaN(this.maxAsNumber)&&e>this.maxAsNumber&&(e=this.maxAsNumber),this.elemHelper.prop("valueAsNumber",e).prop("value"),this.options.defValue=this.elemHelper.prop("value")},value:function(e){this.valueAsNumber=this.asNumber(e),this.options.value=e,isNaN(this.valueAsNumber)?this._setStartInRange():this.elemHelper.prop("value",e),this.element.prop("value",a[this.type](e,this.options))},list:function(e){this.options.options=e||{}},readonly:function(e){this.options.readonly=!!e,this.element.prop("readonly",this.options.readonly),(this.options.readonly||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-readonly")},disabled:function(e){this.options.disabled=!!e,this.element.prop("disabled",this.options.disabled),(this.options.disabled||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-disabled")},tabindex:function(e){this.options.tabindex=e,this.element.prop("tabindex",this.options.tabindex)},title:function(e){this.options.title=e,this.element.prop("tabindex",this.options.title)},min:function(e){this.elemHelper.prop("min",e),this.minAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},max:function(e){this.elemHelper.prop("max",e),this.maxAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},step:function(e){var t=l[this.type];this.elemHelper.prop("step",n(e,t.step))},addBindings:function(){var n,i=this,s=this.options,u=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e]&&t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),a={},l=function(e){if(l.prevent)return e.preventDefault(),i.element.focus(),e.stopImmediatePropagation(),!0},c=function(){return!s.disabled&&!n&&i.element[0].focus(),l.set(),!1};l.set=function(){var e,t=function(){l.prevent=!1};return function(){clearTimeout(e),l.prevent=!0,setTimeout(t,9)}}(),["stepUp","stepDown"].forEach(function(e){a[e]=function(t){if(!s.disabled&&!s.readonly){n||c();var r=!1;t||(t=1);try{i.elemHelper[e](t),r=i.elemHelper.prop("value"),i.value(r),u.call("input",r)}catch(o){}return r}}}),this.buttonWrapper.on("mousedown",c),this.setChange=function(e){i.value(e),u.call("input",e),u.call("change",e)},this.element.on({blur:function(t){!l(t)&&!s.disabled&&!s.readonly&&(u.call("input",e.prop(i.orig,"value")),u.call("change",e.prop(i.orig,"value")),l.prevent||(n=!1))},focus:function(){u.init("input",e.prop(i.orig,"value"),i.options.input),u.init("change",e.prop(i.orig,"value"),i.options.change),n=!0},change:function(){var t=f[i.type](e.prop(this,"value"));e.prop(i.orig,"value",t),u.call("input",t),u.call("change",t)},mousewheel:function(e,t){t&&n&&!s.disabled&&(a[t>0?"stepUp":"stepDown"](),e.preventDefault())},keypress:function(e){var t,n=!0,r=e.keyCode;r==38?a.stepUp():r==40?a.stepDown():!e.ctrlKey&&!e.metaKey&&o[i.type+"Signs"]?(t=String.fromCharCode(e.charCode==null?r:e.charCode),n=!(t<" "||(o[i.type+"Signs"]+"0123456789").indexOf(t)>-1)):n=!1,n&&e.preventDefault()}}),e(r).on("wslocalechange",function(){i.value(i.options.value)}),e(".step-up",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepUp()}}),e(".step-down",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepDown()}})}};e.fn.spinbtnUI=function(t){return t=e.extend({monthNames:"monthNamesShort",size:1,startAt:0,selectNav:!1,openOnFocus:!1},t),this.each(function(){e.webshims.objectCreate(h,{element:{value:e(this)}},t)})}}(),function(){var n={},i={},s=function(e){return[e.getFullYear(),u(e.getMonth()+1),u(e.getDate())]};n.getYearList=function(e,t){var r,i,s,o,u,a,f;e=e[0]*1;var l=t.options.size||1,c=e%(12*l),h=e-c,p=t.options.max.split("-"),d=t.options.min.split("-"),v=0,m="";for(r=0;r<l;r++){r?h+=12:a=n.isInRange([h-1],p,d)?{"data-action":"setYearList",value:h-1}:!1,m+='<div class="year-list"><h3>'+h+" - "+(h+11)+"</h3>",u=[];for(i=0;i<12;i++)s=h+i,n.isInRange([s],p,d)?(o="",v++):o=' disabled="disabled"',u.push('<li><button type="button"'+o+'" data-action="setMonthList" value="'+s+'">'+s+"</button></li>");r==l-1&&(f=n.isInRange([s+1],p,d)?{"data-action":"setYearList",value:s+1}:!1),m+='<ul class="year-list">'+u.join("")+"</ul></div>"}return{enabled:v,main:m,next:f,prev:a}},n.getMonthList=function(e,t){var r,i,s,u,a,f,l,c,h,p=t.options.size||1,d=t.options.max.split("-"),v=t.options.min.split("-"),m=0,g="";e=e[0]-Math.floor((p-1)/2);for(r=0;r<p;r++){r?e++:c=n.isInRange([e-1],d,v)?{"data-action":"setMonthList",value:e-1}:!1,r==p-1&&(h=n.isInRange([e+1],d,v)?{"data-action":"setMonthList",value:e+1}:!1),f=[],!n.isInRange([e,"01"],d,v)&&!n.isInRange([e,"12"],d,v)?(a=' disabled="disabled"',l=!0):(l=!1,a=""),g+='<div class="month-list">',g+=t.options.selectNav?'<select data-action="setMonthList">'+n.createYearSelect(e,d,v).join("")+"</select>":'<button data-action="setYearList"'+a+' value="'+e+'">'+e+"</button>";for(i=0;i<12;i++)u=o.date.monthkeys[i+1],s=o.date.monthNames[i],l||!n.isInRange([e,u],d,v)?a=' disabled="disabled"':(a="",m++),f.push('<li><button type="button"'+a+'" data-action="'+(t.type=="month"?"changeInput":"setDayList")+'" value="'+e+"-"+u+'">'+s+"</button></li>");g+="<ul>"+f.join("")+"</ul></div>"}return{enabled:m,main:g,prev:c,next:h}},n.getDayList=function(e,t){var r,i,u,a,f,l,c,h,p,d,v,m,g,y,b,w,E,S,x=t.options.size||1,T=t.options.max.split("-"),N=t.options.min.split("-"),C=o.date[t.options.monthNames]||o.date.monthNames,k=0,L=[],A=new Date(e[0],e[1]-1,1);A.setMonth(A.getMonth()-Math.floor((x-1)/2));for(r=0;r<x;r++){m=A.getMonth(),r||(S=new Date(A.getTime()),S.setDate(-1),b=s(S),p=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1),b=s(A),L.push('<div class="day-list">'),t.options.selectNav?(w=['<select data-action="setDayList">'+n.createMonthSelect(b,T,N,C).join("")+"</select>",'<select data-action="setDayList">'+n.createYearSelect(b[0],T,N,"-"+b[1]).join("")+"</select>"],o.date.showMonthAfterYear&&w.reverse(),L.push(w.join(" "))):(w=[C[b[1]*1-1],b[0]],o.date.showMonthAfterYear&&w.reverse(),L.push('<button data-action="setMonthList" value="'+b[0]+"-"+b[1]+'">'+w.join(" ")+"</button>")),L.push("<table><tr>");for(u=1;u<o.date.dayNamesShort.length;u++)L.push("<th>"+o.date.dayNamesShort[u]+"</th>");L.push("<th>"+o.date.dayNamesShort[0]+"</th>"),L.push("</tr><tr>");for(i=0;i<46;i++){v=i&&!(i%7),g=A.getMonth(),y=m!=g;if(v&&y){L.push("</tr>");break}v&&L.push("</tr><tr>"),i||(a=A.getDay()-1,a>-1&&a<6&&A.setDate(A.getDate()-a),g=A.getMonth(),y=m!=g),b=s(A),E='<td><button data-action="changeInput" value="'+b.join("-")+'"',y&&(E+=' data-othermonth=""'),n.isInRange(b,T,N)||(E+=' disabled=""'),L.push(E+">"+A.getDate()+"</button></td>"),A.setDate(A.getDate()+1)}L.push("</table></div>"),r==x-1&&(b=s(A),b[2]=1,d=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1)}return{enabled:9,main:L.join(""),prev:p,next:d}},n.isInRange=function(e,t,n){var r,i=!0;for(r=0;r<e.length;r++){if(n[r]&&n[r]>e[r]){i=!1;break}if(!n[r]||n[r]!=e[r])break}if(i)for(r=0;r<e.length;r++){if(t[r]&&t[r]<e[r]){i=!1;break}if(!t[r]||t[r]!=e[r])break}return i},n.createMonthSelect=function(e,t,r,i){i||(i=o.date.monthNames);var s,a=0,f=[],l=e[1]-1;for(;a<i.length;a++)s=l==a?' selected=""':"",(s||n.isInRange([e[0],a+1],t,r))&&f.push('<option value="'+e[0]+"-"+u(a+1)+'"'+s+">"+i[a]+"</option>");return f},n.createYearSelect=function(e,t,r,i){var s,o=!0,u=!0,a=['<option selected="">'+e+"</option>"],f=0;i||(i="");while(f<8&&(o||u))f++,s=e-f,o&&n.isInRange([s],t,r)?a.unshift('<option value="'+(s+i)+'">'+s+"</option>"):o=!1,s=e+f,u&&n.isInRange([s],t,r)?a.push('<option value="'+(s+i)+'">'+s+"</option>"):u=!1;return a};var a={changeInput:function(e,t,n){n.setChange(e),t.hide()}};(function(){var t=function(e){return"get"+e+"List"},r={date:"Day",week:"Day",month:"Month"};e.each({setYearList:["Year","Month","Day"],setMonthList:["Month","Day"],setDayList:["Day"]},function(i,s){var o=s.map(t);a[i]=function(t,i,u,a){var f=t.split("-");a||(a=0),e.each(o,function(e,t){if(e>=a){var o=n[t](f,u);if(f.length<2||o.enabled>1||r[u.type]===s[e])return i.bodyElement.html(o.main),o.prev?i.prevElement.attr(o.prev).prop({disabled:!1}):i.prevElement.removeAttr("data-action").prop({disabled:!0}),o.next?i.nextElement.attr(o.next).prop({disabled:!1}):i.nextElement.removeAttr("data-action").prop({disabled:!0}),!1}})}})})(),n.commonInit=function(t,n){t.list=function(r){var i=this.options,s=[];i.options=r||{},e("div.ws-options",n.contentElement).remove(),e.each(i.options,function(e,n){s.push('<li><button value="'+e+'" data-action="changeInput">'+(n||t.formatValue(e))+"</button></li>")}),s.length&&n.contentElement.append('<div class="ws-options"><ul>'+s.join("")+"</ul></div>")},n.contentElement.html('<button class="ws-prev"></button><button class="ws-next"></button><div class="ws-picker-body"></div>'),n.nextElement=e("button.ws-next",n.contentElement),n.prevElement=e("button.ws-prev",n.contentElement),n.bodyElement=e("div.ws-picker-body",n.contentElement),e(r).onTrigger("wslocalechange",function(){n.nextElement.text(o.date.nextText),n.prevElement.text(o.date.prevText)}),t.list(t.options.options)},n.month=function(r){var i=t.objectCreate(t.wsPopover,{},{prepareFor:r.element}),s=e('<span class="popover-opener" />').appendTo(r.buttonWrapper),o=r.options,u=!1,f=function(){var n=e(this).attr("data-action");return a[n]?a[n](e(this).val(),i,r):t.warn("no action for "+n),!1},l=function(){!o.disabled&&!o.readonly&&(u||(n.commonInit(r,i),a.setYearList(o.value||o.defValue,i,r,r.options.startAt)),u=!0,i.show(r.element))};i.element.addClass(r.type+"-popover"),i.contentElement.on("click","button[data-action]",f).on("change","select[data-action]",f),s.on("mousedown",l),r.element.on({focus:function(){r.options.openOnFocus&&l()},mousedown:function(){r.element.is(":focus")&&l()}})},n.date=n.month,t.picker=n}(),function(){var n=Modernizr.inputtypes,i,o={},u=["disabled","readonly","value","min","max","step","title","placeholder"],a=["tabindex","data-placeholder"],f=function(e){};e.each(u.concat(a),function(e,n){var r=n.replace(/^data\-/,"");t.onNodeNamesPropertyModify("input",n,function(e){if(!i){var n=t.data(this,"shadowData");n&&n.data&&n.nativeElement===this&&n.data[r]&&n.data[r](e)}})});var l=function(){return function(t,n){o[t]=n,n.attrs=e.merge([],a,n.attrs),n.props=e.merge([],u,n.props)}}(),c=function(t,n){var r=e.prop(t,"list"),i={},s,o;return r&&e("option",r).each(function(){i[e.prop(this,"value")]=e.prop(this,"label")}),n&&(o=function(){n.shim&&(clearTimeout(s),s=setTimeout(function(){n.shim.list(c(t))},9))},e(r).on("updateDatalist",o),e(t).on("listdatalistchange",o)),i},h=function(e){e.stopImmediatePropagation(e)},p=function(){return e.css(this,"display")!="none"},d=function(t){var n,i=function(){e.style(t.orig,"display","");var r=.6;if(!n||t.orig.offsetWidth)t.element.css({marginLeft:e.css(t.orig,"marginLeft"),marginRight:e.css(t.orig,"marginRight")}),t.buttonWrapper&&(t.element.css({paddingRight:""}),(parseInt(t.buttonWrapper.css("marginLeft"),10)||0)<0?t.element.css({paddingRight:""}).css({paddingRight:(parseInt(t.element.css("paddingRight"),10)||0)+t.buttonWrapper.outerWidth()}):r=t.buttonWrapper.outerWidth(!0)+.6),t.element.outerWidth(e(t.orig).outerWidth()-r);n=!0,e.style(t.orig,"display","none")};e(r).onTrigger("updateshadowdom",i)},v=function(){var n=e.prop(this,"type"),r,f,l,p,v;if(o[n]){l={},p=n,f=e.extend({},s[n],e(e.prop(this,"form")).data(n)||{},e(this).data(n)||{},{orig:this,type:n,options:c(this,l),input:function(e){f._change(e,"input")},change:function(e){f._change(e,"change")},_change:function(t,n){i=!0,e.prop(f.orig,"value",t),i=!1,n&&e(f.orig).trigger(n)}});for(r=0;r<u.length;r++)f[u[r]]=e.prop(this,u[r]);for(r=0;r<a.length;r++)p=a[r].replace(/^data\-/,""),f[p]||(f[p]=e.attr(this,a[r]));l.shim=o[n]._create(f),t.addShadowDom(this,l.shim.element,{data:l.shim||{}}),e(this).on("change",function(t){!i&&t.originalEvent&&l.shim.value(e.prop(this,"value"))}),l.shim.element.on("change input",h),l.shim.element.on("focusin focusout",function(t){t.stopImmediatePropagation(t),e(f.orig).trigger(t)}),l.shim.element.on("focus blur",function(t){t.stopImmediatePropagation(t),e(f.orig).triggerHandler(t)}),v=f.calculateWidth!=null?f.calculateWidth:s.calculateWidth,v&&d(l.shim),e(this).css({display:"none"})}};(!n.range||s.replaceUI)&&l("range",{_create:function(t,n){return e("<span />").insertAfter(t.orig).rangeUI(t).data("rangeUi")}}),["number","time","month","date"].forEach(function(r){(!n[r]||s.replaceUI)&&l(r,{_create:function(n,i){var s=e('<input class="ws-'+r+'" type="text" />').insertAfter(n.orig).spinbtnUI(n).data("wsspinner");return t.picker&&t.picker[r]&&t.picker[r](s),s.buttonWrapper.addClass("input-button-size-"+s.buttonWrapper.children().filter(p).length),s}})}),t.addReady(function(t,n){e("input",t).add(n.filter("input")).each(v)})}()});
View
2  demos/js-webshim/minified/shims/combos/6.js
@@ -1 +1 @@
-jQuery.webshims.register("form-native-extend",function(e,t,n,r,i,s){"use strict";var o=n.Modernizr,u=o.inputtypes;if(!o.formvalidation||t.bugs.bustedValidity)return;var a=t.inputTypes,f={};t.addInputType=function(e,t){a[e]=t},t.addValidityRule=function(e,t){f[e]=t},t.addValidityRule("typeMismatch",function(e,t,n,r){if(t==="")return!1;var i=r.typeMismatch;return"type"in n||(n.type=(e[0].getAttribute("type")||"").toLowerCase()),a[n.type]&&a[n.type].mismatch&&(i=a[n.type].mismatch(t,e)),i});var l=s.overrideMessages,c=!u.number||!u.time||!u.range||l,h=["customError","typeMismatch","rangeUnderflow","rangeOverflow","stepMismatch","tooLong","patternMismatch","valueMissing","valid"],p=l?["value","checked"]:["value"],d=[],v=function(t,n){if(!t)return;var i=(t.getAttribute&&t.getAttribute("type")||t.type||"").toLowerCase();if(!l&&!a[i])return;l&&!n&&i=="radio"&&t.name?e(r.getElementsByName(t.name)).each(function(){e.prop(this,"validity")}):e.prop(t,"validity")},m={};["input","textarea","select"].forEach(function(n){var r=t.defineNodeNameProperty(n,"setCustomValidity",{prop:{value:function(i){i+="";var s=n=="input"?e(this).getNativeElement()[0]:this;r.prop._supvalue.call(s,i),t.bugs.validationMessage&&t.data(s,"customvalidationMessage",i),c&&(t.data(s,"hasCustomError",!!i),v(s))}}});m[n]=r.prop._supvalue});if(c||l)p.push("min"),p.push("max"),p.push("step"),d.push("input");l&&(p.push("required"),p.push("pattern"),d.push("select"),d.push("textarea"));if(c){var g;d.forEach(function(n){var r=t.defineNodeNameProperty(n,"validity",{prop:{get:function(){if(g)return;var i=n=="input"?e(this).getNativeElement()[0]:this,s=r.prop._supget.call(i);if(!s)return s;var o={};h.forEach(function(e){o[e]=s[e]});if(!e.prop(i,"willValidate"))return o;g=!0;var u=e(i),c={type:(i.getAttribute&&i.getAttribute("type")||"").toLowerCase(),nodeName:(i.nodeName||"").toLowerCase()},p=u.val(),d=!!t.data(i,"hasCustomError"),v;g=!1,o.customError=d;if(o.valid&&o.customError)o.valid=!1;else if(!o.valid){var y=!0;e.each(o,function(e,t){if(t)return y=!1,!1}),y&&(o.valid=!0)}return e.each(f,function(e,r){o[e]=r(u,p,c,o),o[e]&&(o.valid||!v)&&(l||a[c.type]&&a[c.type].mismatch)&&(m[n].call(i,t.createValidationMessage(i,e)),o.valid=!1,v=!0)}),o.valid?(m[n].call(i,""),t.data(i,"hasCustomError",!1)):l&&!v&&!d&&e.each(o,function(e,r){if(e!=="valid"&&r)return m[n].call(i,t.createValidationMessage(i,e)),!1}),o},writeable:!1}})}),p.forEach(function(e){t.onNodeNamesPropertyModify(d,e,function(e){v(this)})});if(r.addEventListener){var y,b=function(t){if(!("form"in t.target))return;var n=t.target.form;clearTimeout(y),v(t.target),n&&l&&e("input",n).each(function(){this.type=="password"&&v(this)})};r.addEventListener("change",b,!0),l&&(r.addEventListener("blur",b,!0),r.addEventListener("keydown",function(e){if(e.keyCode!=13)return;b(e)},!0)),r.addEventListener("input",function(e){clearTimeout(y),y=setTimeout(function(){v(e.target)},290)},!0)}var w=d.join(",");t.addReady(function(t,n){e(w,t).add(n.filter(w)).each(function(){e.prop(this,"validity")})}),l&&t.ready("DOM form-message",function(){t.activeLang({register:"form-core",callback:function(){e("input, select, textarea").getNativeElement().each(function(){if(t.data(this,"hasCustomError"))return;var n=this,r=e.prop(n,"validity")||{valid:!0},i;if(r.valid)return;i=(n.nodeName||"").toLowerCase(),e.each(r,function(e,r){if(e!=="valid"&&r)return m[i].call(n,t.createValidationMessage(n,e)),!1})})}})})}t.defineNodeNameProperty("input","type",{prop:{get:function(){var e=this,n=(e.getAttribute("type")||"").toLowerCase();return t.inputTypes[n]?n:e.type}}})}),jQuery.webshims.register("form-number-date-api",function(e,t,n,r,i){"use strict";t.getStep||(t.getStep=function(t,n){var r=e.attr(t,"step");return r==="any"?r:(n=n||l(t),!u[n]||!u[n].step?r:(r=y.number.asNumber(r),(!isNaN(r)&&r>0?r:u[n].step)*(u[n].stepScaleFactor||1)))}),t.addMinMaxNumberToCache||(t.addMinMaxNumberToCache=function(e,t,n){e+"AsNumber"in n||(n[e+"AsNumber"]=u[n.type].asNumber(t.attr(e)),isNaN(n[e+"AsNumber"])&&e+"Default"in u[n.type]&&(n[e+"AsNumber"]=u[n.type][e+"Default"]))});var s=parseInt("NaN",10),o=r,u=t.inputTypes,a=function(e){return typeof e=="number"||e&&e==e*1},f=function(t){return e('<input type="'+t+'" />').prop("type")===t},l=function(e){return(e.getAttribute("type")||"").toLowerCase()},c=function(e){var t=e*1;return e&&(t==e||e=="0"+t)},h=t.addMinMaxNumberToCache,p=function(e,t){e=""+e,t-=e.length;for(var n=0;n<t;n++)e="0"+e;return e},d=1e-7,v=t.bugs.bustedValidity;t.addValidityRule("stepMismatch",function(e,n,r,i){if(n==="")return!1;"type"in r||(r.type=l(e[0]));var s=(i||{}).stepMismatch||!1,o;if(u[r.type]&&u[r.type].step){"step"in r||(r.step=t.getStep(e[0],r.type));if(r.step=="any")return!1;"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h("min",e,r),o=r.minAsNumber,isNaN(o)&&(o=u[r.type].stepBase||0),s=Math.abs((r.valueAsNumber-o)%r.step),s=!(s<=d||Math.abs(s-r.step)<=d)}return s}),[{name:"rangeOverflow",attr:"max",factor:1},{name:"rangeUnderflow",attr:"min",factor:-1}].forEach(function(e,n){t.addValidityRule(e.name,function(t,n,r,i){var s=(i||{})[e.name]||!1;if(n==="")return s;"type"in r||(r.type=l(t[0]));if(u[r.type]&&u[r.type].asNumber){"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h(e.attr,t,r);if(isNaN(r[e.attr+"AsNumber"]))return s;s=r[e.attr+"AsNumber"]*e.factor<r.valueAsNumber*e.factor-d}return s})}),t.reflectProperties(["input"],["max","min","step"]);var m=t.defineNodeNameProperty("input","valueAsNumber",{prop:{get:function(){var t=this,n=l(t),r=u[n]&&u[n].asNumber?u[n].asNumber(e.prop(t,"value")):m.prop._supget&&m.prop._supget.apply(t,arguments);return r==null&&(r=s),r},set:function(n){var r=this,i=l(r);if(u[i]&&u[i].numberToString){if(isNaN(n)){e.prop(r,"value","");return}var s=u[i].numberToString(n);s!==!1?e.prop(r,"value",s):t.error("INVALID_STATE_ERR: DOM Exception 11")}else m.prop._supset&&m.prop._supset.apply(r,arguments)}}}),g=t.defineNodeNameProperty("input","valueAsDate",{prop:{get:function(){var t=this,n=l(t);return u[n]&&u[n].asDate&&!u[n].noAsDate?u[n].asDate(e.prop(t,"value")):g.prop._supget&&g.prop._supget.call(t)||null},set:function(n){var r=this,i=l(r);if(!(u[i]&&u[i].dateToString&&!u[i].noAsDate))return g.prop._supset&&g.prop._supset.apply(r,arguments)||null;if(n===null)return e.prop(r,"value",""),"";var s=u[i].dateToString(n);if(s!==!1)return e.prop(r,"value",s),s;t.error("INVALID_STATE_ERR: DOM Exception 11")}}});e.each({stepUp:1,stepDown:-1},function(n,r){var i=t.defineNodeNameProperty("input",n,{prop:{value:function(n){var s,o,a,f,c,h,p=l(this);if(!u[p]||!u[p].asNumber){if(i.prop&&i.prop.value)return i.prop.value.apply(this,arguments);throw t.info("no step method for type: "+p),"invalid state error"}h={type:p},n||(n=1,t.info("you should always use a factor for stepUp/stepDown")),n*=r,o=e.prop(this,"valueAsNumber");if(isNaN(o))throw t.info("valueAsNumber is NaN can't apply stepUp/stepDown "),"invalid state error";s=t.getStep(this,p);if(s=="any")throw t.info("step is 'any' can't apply stepUp/stepDown"),"invalid state error";t.addMinMaxNumberToCache("min",e(this),h),t.addMinMaxNumberToCache("max",e(this),h),s*=n,o+=s,f=(o-(h.minAsNumber||0))%s,f&&Math.abs(f)>d&&(c=o-f,c+=f>0?s:-s,o=c.toFixed(5)*1);if(!isNaN(h.maxAsNumber)&&o>h.maxAsNumber||!isNaN(h.minAsNumber)&&o<h.minAsNumber)throw t.info("max/min overflow can't apply stepUp/stepDown"),"invalid state error";a?e.prop(this,"valueAsDate",a):e.prop(this,"valueAsNumber",o)}}})});var y={number:{mismatch:function(e){return!a(e)},step:1,stepScaleFactor:1,asNumber:function(e){return a(e)?e*1:s},numberToString:function(e){return a(e)?e:!1}},range:{minDefault:0,maxDefault:100},date:{mismatch:function(e){if(!e||!e.split||!/\d$/.test(e))return!0;var t,n=e.split(/\u002D/);if(n.length!==3)return!0;var r=!1;if(n[0].length!==4||n[1].length!=2||n[1]>12||n[2].length!=2||n[2]>33)r=!0;else for(t=0;t<3;t++)if(!c(n[0])){r=!0;break}return r||e!==this.dateToString(this.asDate(e,!0))},step:1,stepScaleFactor:864e5,asDate:function(e,t){return!t&&this.mismatch(e)?null:new Date(this.asNumber(e,!0))},asNumber:function(e,t){var n=s;if(t||!this.mismatch(e))e=e.split(/\u002D/),n=Date.UTC(e[0],e[1]-1,e[2]);return n},numberToString:function(e){return a(e)?this.dateToString(new Date(e*1)):!1},dateToString:function(e){return e&&e.getFullYear?e.getUTCFullYear()+"-"+p(e.getUTCMonth()+1,2)+"-"+p(e.getUTCDate(),2):!1}},time:{mismatch:function(t,n){if(!t||!t.split||!/\d$/.test(t))return!0;t=t.split(/\u003A/);if(t.length<2||t.length>3)return!0;var r=!1,i;return t[2]&&(t[2]=t[2].split(/\u002E/),i=parseInt(t[2][1],10),t[2]=t[2][0]),e.each(t,function(e,t){if(!c(t)||t.length!==2)return r=!0,!1}),r?!0:t[0]>23||t[0]<0||t[1]>59||t[1]<0?!0:t[2]&&(t[2]>59||t[2]<0)?!0:i&&isNaN(i)?!0:(i&&(i<100?i*=100:i<10&&(i*=10)),n===!0?[t,i]:!1)},step:60,stepBase:0,stepScaleFactor:1e3,asDate:function(e){return e=new Date(this.asNumber(e)),isNaN(e)?null:e},asNumber:function(e){var t=s;return e=this.mismatch(e,!0),e!==!0&&(t=Date.UTC("1970",0,1,e[0][0],e[0][1],e[0][2]||0),e[1]&&(t+=e[1])),t},dateToString:function(e){if(e&&e.getUTCHours){var t=p(e.getUTCHours(),2)+":"+p(e.getUTCMinutes(),2),n=e.getSeconds();return n!="0"&&(t+=":"+p(n,2)),n=e.getUTCMilliseconds(),n!="0"&&(t+="."+p(n,3)),t}return!1}},month:{mismatch:function(e){return y.date.mismatch(e+"-01")},step:1,stepScaleFactor:!1,asDate:function(e){return new Date(y.date.asNumber(e+"-01"))},asNumber:function(e){var t=s;return e&&!this.mismatch(e)&&(e=e.split(/\u002D/),e[0]=e[0]*1-1970,e[1]=e[1]*1-1,t=e[0]*12+e[1]),t},numberToString:function(e){var t,n=!1;return a(e)&&(t=e%12,e=(e-t)/12+1970,t+=1,t<1&&(e-=1,t+=12),n=p(e,4)+"-"+p(t,2)),n},dateToString:function(e){if(e&&e.getUTCHours){var t=y.date.dateToString(e);return t.split&&(t=t.split(/\u002D/))?t[0]+"-"+t[1]:!1}return!1}}};if(v||!f("range")||!f("time"))y.range=e.extend({},y.number,y.range),y.time=e.extend({},y.date,y.time),y.month=e.extend({},y.date,y.month);["number","month","range","date","time"].forEach(function(e){(v||!f(e))&&t.addInputType(e,y[e])}),e("<input />").prop("labels")==null&&t.defineNodeNamesProperty("button, input, keygen, meter, output, progress, select, textarea","labels",{prop:{get:function(){var t,n=this.id,r=e(this).closest("label").filter(function(){var e=this.htmlFor;return!e||e==n});return n&&(r=r.add('label[for="'+n+'"]')),r.get()},writeable:!1}})}),function(e){var t=0,n=function(e){return typeof e=="number"||e&&e==e*1},r=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex"],s={_create:function(){var t;this.element.addClass("ws-range").attr({role:"slider"}).html('<span class="ws-range-min" /><span class="ws-range-rail"><span class="ws-range-thumb" /></span>'),this.trail=e(".ws-range-rail",this.element),this.range=e(".ws-range-min",this.element),this.thumb=e(".ws-range-thumb",this.trail),this.dirs=this.element.innerHeight()>this.element.innerWidth()?{mouse:"pageY",pos:"top",range:"height",outerWidth:"outerHeight"}:{mouse:"pageX",pos:"left",range:"width",outerWidth:"outerWidth"},this.updateMetrics(),this.orig=this.options.orig;for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);this.value=this._value,this.value(this.options.value),this.list(this.options.options),this.element.data("rangeUi",this),this.addBindings(),this._init=!0},value:e.noop,_value:function(e,t,n){var r,i=e,s={},o={};!t&&parseFloat(e,10)!=e&&(e=this.options.min+(this.options.max-this.options.min)/2),t||(e=this.normalizeVal(e)),r=100*((e-this.options.min)/(this.options.max-this.options.min)),this.options.value=e,this.thumb.stop(),this.range.stop(),s[this.dirs.pos]=r+"%",o[this.dirs.range]=r+"%",n?(this.thumb.animate(s,{animate:this.options.animate}),this.range.animate(o,{animate:this.options.animate})):(this.thumb.css(s),this.range.css(o)),this.orig&&(i!=e||!this._init&&this.orig.value!=e)&&this.options._change(e),this.element.attr({"aria-valuenow":this.options.value,"aria-valuetext":this.options.options[this.options.value]||this.options.value})},list:function(t){var r=this.options,i=r.min,s=r.max,o=this.trail;r.options=t||{},this.element.attr({"aria-valuetext":r.options[r.value]||r.value}),e(".ws-range-ticks",o).remove(),e.each(r.options,function(e,t){if(!n(e)||e<i||e>s)return;var u=100*((e-i)/(s-i)),a=r.showLabels?' title="'+t+'"':"";o.append('<span class="ws-range-ticks"'+a+' style="'+this.dirs.pos+": "+u+'%;" />')})},readonly:function(e){e=!!e,this.options.readonly=e,this.element.attr("aria-readonly",""+e)},disabled:function(e){e=!!e,this.options.disabled=e,e?this.element.attr({tabindex:-1,"aria-disbaled":"true"}):this.element.attr({tabindex:this.options.tabindex,"aria-disbaled":"false"})},tabindex:function(e){this.options.tabindex=e,this.options.disabled||this.element.attr({tabindex:e})},title:function(e){this.element.prop("title",e)},min:function(e){this.options.min=r(e,0),this.value(this.options.value,!0)},max:function(e){this.options.max=r(e,100),this.value(this.options.value,!0)},step:function(e){this.options.step=e=="any"?"any":r(e,1),this.value(this.options.value)},normalizeVal:function(e){var t,n,r,i=this.options;return e<=i.min?e=i.min:e>=i.max?e=i.max:i.step!="any"&&(r=i.step,t=(e-i.min)%r,n=e-t,Math.abs(t)*2>=r&&(n+=t>0?r:-r),e=n.toFixed(5)*1),e},doStep:function(e){var t=r(this.options.step,1);this.options.step=="any"&&(t=Math.min(t,(this.options.max-this.options.min)/10)),this.value(this.options.value+t*e)},getStepedValueFromPos:function(e){var t,n,r,i;return e<=0?t=this.options.min:e>100?t=this.options.max:(t=(this.options.max-this.options.min)*(e/100)+this.options.min,i=this.options.step,i!="any"&&(n=(t-this.options.min)%i,r=t-n,Math.abs(n)*2>=i&&(r+=n>0?i:-i),t=r.toFixed(5)*1)),t},addBindings:function(){var t,n,r,i=this,s=this.options,o=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},i.orig&&e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),u=function(e,r){var u=i.getStepedValueFromPos((e[i.dirs.mouse]-t)*n);u!=s.value&&(i.value(u,!1,r),o.call("input",u))},a=function(t){t&&t.type=="mouseup"&&(o.call("input",s.value),o.call("change",s.value)),i.element.removeClass("ws-active"),e(document).off("mousemove",u).off("mouseup",a)},f=function(r){r.preventDefault(),e(document).off("mousemove",u).off("mouseup",a);if(!s.readonly&&!s.disabled){t=i.element.focus().addClass("ws-active").offset(),n=i.element.width();if(!n||!t)return;t=t[i.dirs.pos],n=100/(n-(i.thumb[i.dirs.outerWidth]()||2)/2),u(r,i.options.animate),e(document).on({mouseup:a,mousemove:u}),r.stopPropagation()}};o.init("input",s.value,this.options.input),o.init("change",s.value,this.options.change),this.element.on({mousedown:f,focus:function(e){s.disabled||(o.init("input",s.value),o.init("change",s.value),i.element.addClass("ws-focus")),r=!0},blur:function(e){i.element.removeClass("ws-focus ws-active"),r=!1,o.init("input",s.value),o.call("change",s.value)},keyup:function(){i.element.removeClass("ws-active"),o.call("input",s.value),o.call("change",s.value)},mousewheel:function(e,t){t&&r&&!s.readonly&&!s.disabled&&(i.doStep(t),e.preventDefault(),o.call("input",s.value))},keypress:function(e){var t=!0,n=e.keyCode;!s.readonly&&!s.disabled&&(n==39||n==38?i.doStep(1):n==37||n==40?i.doStep(-1):n==33?i.doStep(10):n==34?i.doStep(-10):n==36?i.value(i.options.max):n==35?i.value(i.options.min):t=!1,t&&(i.element.addClass("ws-active"),o.call("input",s.value),e.preventDefault()))}}),this.thumb.on({mousedown:f})},updateMetrics:function(){}};e.fn.rangeUI=function(t){return t=e.extend({readonly:!1,disabled:!1,tabindex:0,min:0,step:1,max:100,value:50,input:e.noop,change:e.noop,_change:e.noop,showLabels:!0},t),this.each(function(){e.webshims.objectCreate(s,{element:{value:e(this)}},t)})},jQuery.webshims.isReady("range-ui",!0)}(jQuery),jQuery.webshims.register("form-number-date-ui",function(e,t,n,r,i,s){"use strict";var o,u=function(e){return e?(e+="",e.length==1?"0"+e:e):""};(function(){var t=e.webshims.formcfg;t.de={numberFormat:{",":".",".":","},timeSigns:":. ",numberSigns:",",dateSigns:".",dFormat:".",patterns:{d:"dd.mm.yy"},date:{close:"schlie\u00dfen",prevText:"zur\u00fcck",nextText:"Vor",currentText:"heute",monthNames:["Januar","Februar","M\u00e4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],monthNamesShort:["Jan","Feb","M\u00e4r","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],dayNames:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],dayNamesShort:["So","Mo","Di","Mi","Do","Fr","Sa"],dayNamesMin:["So","Mo","Di","Mi","Do","Fr","Sa"],weekHeader:"KW",firstDay:1,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t.en={numberFormat:{".":".",",":","},numberSigns:".",dateSigns:"/",timeSigns:":. ",dFormat:"/",patterns:{d:"mm/dd/yy"},date:{closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t["en-US"]=t["en-US"]||t.en,t[""]=t[""]||t["en-US"],o=t[""];var n=function(t){if(!t.date.monthkeys){var n=function(e,n){var r,i=e+1;r=i<10?"0"+i:""+i,t.date.monthkeys[i]=r,t.date.monthkeys[n]=r};t.date.monthkeys={},e.each(t.date.monthNames,n),e.each(t.date.monthNamesShort,n)}};n(o),e.webshims.ready("dom-extend",function(){e.webshims.activeLang({register:"form-core",callback:function(){e.each(arguments,function(i,s){if(t[s])return o=t[s],n(o),e(r).triggerHandler("wslocalechange"),!1})}})})})(),function(){var t=function(t){e(this)[t.type=="mousepressstart"?"addClass":"removeClass"]("mousepress-ui")},n=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex","placeholder","value"],s=function(t){if(!o.patterns[t+"Obj"]){var n={};e.each(o.patterns[t].split(o[t+"Format"]),function(e,t){n[t]=e}),o.patterns[t+"Obj"]=n}},a={number:function(e){return(e+"").replace(/\,/g,"").replace(/\./,o.numberFormat["."])},time:function(e){return e},month:function(e,t){var n,r=e.split("-");return r[0]&&r[1]&&(n=o.date[t.monthNames]||o.date.monthNames,r[1]=n[r[1]*1-1],r[1]&&(e=o.date.showMonthAfterYear?r.join(" "):r[1]+" "+r[0])),e},date:function(e){var t=(e+"").split("-");return t[2]&&t[1]&&t[0]&&(e=o.patterns.d.replace("yy",t[0]||""),e=e.replace("mm",t[1]||""),e=e.replace("dd",t[2]||"")),e}},f={number:function(e){return(e+"").replace(o.numberFormat[","],"").replace(o.numberFormat["."],".")},time:function(e){return e},month:function(e){var t=e.trim().split(/[\s-\/\\]+/);return t.length==2&&(t[0]=o.date.monthkeys[t[0]]||t[0],t[1]=o.date.monthkeys[t[1]]||t[1],t[1].length==2?e=t[0]+"-"+t[1]:t[0].length==2&&(e=t[1]+"-"+t[0])),e},date:function(e){s("d");var t,n=o.patterns.dObj;return e=e.split(o.dFormat),e.length==3?[u(e[n.yy]),u(e[n.mm]),u(e[n.dd])].join("-"):""}},l={number:{step:1},time:{step:60},month:{step:1,start:new Date((new Date).getFullYear(),0,1)},date:{step:1,start:new Date((new Date).getFullYear(),0,1)}},c=function(){var t={};return function(n){var r;return t[n]||(r=e('<input type="'+n+'" />'),t[n]=function(e){var t=typeof e=="object"?"valueAsDate":"value";return r.prop(t,e).prop("valueAsNumber")}),t[n]}}();l.range=l.number;var h={_create:function(){var t;this.type=this.options.type,this.orig=this.options.orig,this.elemHelper=e('<input type="'+this.type+'" />'),this.asNumber=c(this.type),this.buttonWrapper=e('<span class="input-buttons '+this.type+'-input-buttons"><span unselectable="on" class="step-controls"><span class="step-up"></span><span class="step-down"></span></span></span>').insertAfter(this.element),typeof l[this.type].start=="object"&&(l[this.type].start=this.asNumber(l[this.type].start));for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);var n=this.element.attr("autocomplete","off").data("wsspinner",this);this.addBindings(),this._init=!0},parseValue:function(e){return f[this.type](e)},formatValue:function(e){return a[this.type](e,this.options)},placeholder:function(e){var t;this.options.placeholder=e,this.type=="date"&&(t=(e||"").split("-"),t.length==3&&(this.options.placeholder=o.patterns.d.replace("yy",t[0]).replace("mm",t[1]).replace("dd",t[2]))),this.element.prop("placeholder",this.options.placeholder)},addZero:u,_setStartInRange:function(){var e=l[this.type].start||0;!isNaN(this.minAsNumber)&&e<this.minAsNumber?e=this.minAsNumber:!isNaN(this.maxAsNumber)&&e>this.maxAsNumber&&(e=this.maxAsNumber),this.elemHelper.prop("valueAsNumber",e).prop("value"),this.options.defValue=this.elemHelper.prop("value")},value:function(e){this.valueAsNumber=this.asNumber(e),this.options.value=e,isNaN(this.valueAsNumber)?this._setStartInRange():this.elemHelper.prop("value",e),this.element.prop("value",a[this.type](e,this.options))},list:function(e){this.options.options=e||{}},readonly:function(e){this.options.readonly=!!e,this.element.prop("readonly",this.options.readonly),(this.options.readonly||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-readonly")},disabled:function(e){this.options.disabled=!!e,this.element.prop("disabled",this.options.disabled),(this.options.disabled||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-disabled")},tabindex:function(e){this.options.tabindex=e,this.element.prop("tabindex",this.options.tabindex)},title:function(e){this.options.title=e,this.element.prop("tabindex",this.options.title)},min:function(e){this.elemHelper.prop("min",e),this.minAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},max:function(e){this.elemHelper.prop("max",e),this.maxAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},step:function(e){var t=l[this.type];this.elemHelper.prop("step",n(e,t.step))},addBindings:function(){var n,i=this,s=this.options,u=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e]&&t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),a={},l=function(e){if(l.prevent)return e.preventDefault(),i.element.focus(),e.stopImmediatePropagation(),!0},c=function(){return!s.disabled&&!n&&i.element[0].focus(),l.set(),!1};l.set=function(){var e,t=function(){l.prevent=!1};return function(){clearTimeout(e),l.prevent=!0,setTimeout(t,9)}}(),["stepUp","stepDown"].forEach(function(e){a[e]=function(t){if(!s.disabled&&!s.readonly){n||c();var r=!1;t||(t=1);try{i.elemHelper[e](t),r=i.elemHelper.prop("value"),i.value(r),u.call("input",r)}catch(o){}return r}}}),this.buttonWrapper.on("mousedown",c),this.setChange=function(e){i.value(e),u.call("input",e),u.call("change",e)},this.element.on({blur:function(t){!l(t)&&!s.disabled&&!s.readonly&&(u.call("input",e.prop(i.orig,"value")),u.call("change",e.prop(i.orig,"value")),l.prevent||(n=!1))},focus:function(){u.init("input",e.prop(i.orig,"value"),i.options.input),u.init("change",e.prop(i.orig,"value"),i.options.change),n=!0},change:function(){var t=f[i.type](e.prop(this,"value"));e.prop(i.orig,"value",t),u.call("input",t),u.call("change",t)},mousewheel:function(e,t){t&&n&&!s.disabled&&(a[t>0?"stepUp":"stepDown"](),e.preventDefault())},keypress:function(e){var t,n=!0,r=e.keyCode;r==38?a.stepUp():r==40?a.stepDown():!e.ctrlKey&&!e.metaKey&&o[i.type+"Signs"]?(t=String.fromCharCode(e.charCode==null?r:e.charCode),n=!(t<" "||(o[i.type+"Signs"]+"0123456789").indexOf(t)>-1)):n=!1,n&&e.preventDefault()}}),e(r).on("wslocalechange",function(){i.value(i.options.value)}),e(".step-up",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepUp()}}),e(".step-down",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepDown()}})}};e.fn.spinbtnUI=function(t){return t=e.extend({monthNames:"monthNamesShort",size:1,startAt:0,selectNav:!1,openOnFocus:!1},t),this.each(function(){e.webshims.objectCreate(h,{element:{value:e(this)}},t)})}}(),function(){var n={},i={},s=function(e){return[e.getFullYear(),u(e.getMonth()+1),u(e.getDate())]};n.getYearList=function(e,t){var r,i,s,o,u,a,f;e=e[0]*1;var l=t.options.size||1,c=e%(12*l),h=e-c,p=t.options.max.split("-"),d=t.options.min.split("-"),v=0,m="";for(r=0;r<l;r++){r?h+=12:a=n.isInRange([h-1],p,d)?{"data-action":"setYearList",value:h-1}:!1,m+='<div class="year-list"><h3>'+h+" - "+(h+11)+"</h3>",u=[];for(i=0;i<12;i++)s=h+i,n.isInRange([s],p,d)?(o="",v++):o=' disabled="disabled"',u.push('<li><button type="button"'+o+'" data-action="setMonthList" value="'+s+'">'+s+"</button></li>");r==l-1&&(f=n.isInRange([s+1],p,d)?{"data-action":"setYearList",value:s+1}:!1),m+='<ul class="year-list">'+u.join("")+"</ul></div>"}return{enabled:v,main:m,next:f,prev:a}},n.getMonthList=function(e,t){var r,i,s,u,a,f,l,c,h,p=t.options.size||1,d=t.options.max.split("-"),v=t.options.min.split("-"),m=0,g="";e=e[0]-Math.floor((p-1)/2);for(r=0;r<p;r++){r?e++:c=n.isInRange([e-1],d,v)?{"data-action":"setMonthList",value:e-1}:!1,r==p-1&&(h=n.isInRange([e+1],d,v)?{"data-action":"setMonthList",value:e+1}:!1),f=[],!n.isInRange([e,"01"],d,v)&&!n.isInRange([e,"12"],d,v)?(a=' disabled="disabled"',l=!0):(l=!1,a=""),g+='<div class="month-list">',g+=t.options.selectNav?'<select data-action="setMonthList">'+n.createYearSelect(e,d,v).join("")+"</select>":'<button data-action="setYearList"'+a+' value="'+e+'">'+e+"</button>";for(i=0;i<12;i++)u=o.date.monthkeys[i+1],s=o.date.monthNames[i],l||!n.isInRange([e,u],d,v)?a=' disabled="disabled"':(a="",m++),f.push('<li><button type="button"'+a+'" data-action="'+(t.type=="month"?"changeInput":"setDayList")+'" value="'+e+"-"+u+'">'+s+"</button></li>");g+="<ul>"+f.join("")+"</ul></div>"}return{enabled:m,main:g,prev:c,next:h}},n.getDayList=function(e,t){var r,i,u,a,f,l,c,h,p,d,v,m,g,y,b,w,E,S,x=t.options.size||1,T=t.options.max.split("-"),N=t.options.min.split("-"),C=o.date[t.options.monthNames]||o.date.monthNames,k=0,L=[],A=new Date(e[0],e[1]-1,1);A.setMonth(A.getMonth()-Math.floor((x-1)/2));for(r=0;r<x;r++){m=A.getMonth(),r||(S=new Date(A.getTime()),S.setDate(-1),b=s(S),p=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1),b=s(A),L.push('<div class="day-list">'),t.options.selectNav?(w=['<select data-action="setDayList">'+n.createMonthSelect(b,T,N,C).join("")+"</select>",'<select data-action="setDayList">'+n.createYearSelect(b[0],T,N,"-"+b[1]).join("")+"</select>"],o.date.showMonthAfterYear&&w.reverse(),L.push(w.join(" "))):(w=[C[b[1]*1-1],b[0]],o.date.showMonthAfterYear&&w.reverse(),L.push('<button data-action="setMonthList" value="'+b[0]+"-"+b[1]+'">'+w.join(" ")+"</button>")),L.push("<table><tr>");for(u=1;u<o.date.dayNamesShort.length;u++)L.push("<th>"+o.date.dayNamesShort[u]+"</th>");L.push("<th>"+o.date.dayNamesShort[0]+"</th>"),L.push("</tr><tr>");for(i=0;i<46;i++){v=i&&!(i%7),g=A.getMonth(),y=m!=g;if(v&&y){L.push("</tr>");break}v&&L.push("</tr><tr>"),i||(a=A.getDay()-1,a>-1&&a<6&&A.setDate(A.getDate()-a),g=A.getMonth(),y=m!=g),b=s(A),E='<td><button data-action="changeInput" value="'+b.join("-")+'"',y&&(E+=' data-othermonth=""'),n.isInRange(b,T,N)||(E+=' disabled=""'),L.push(E+">"+A.getDate()+"</button></td>"),A.setDate(A.getDate()+1)}L.push("</table></div>"),r==x-1&&(b=s(A),b[2]=1,d=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1)}return{enabled:9,main:L.join(""),prev:p,next:d}},n.isInRange=function(e,t,n){var r,i=!0;for(r=0;r<e.length;r++){if(n[r]&&n[r]>e[r]){i=!1;break}if(!n[r]||n[r]!=e[r])break}if(i)for(r=0;r<e.length;r++){if(t[r]&&t[r]<e[r]){i=!1;break}if(!t[r]||t[r]!=e[r])break}return i},n.createMonthSelect=function(e,t,r,i){i||(i=o.date.monthNames);var s,a=0,f=[],l=e[1]-1;for(;a<i.length;a++)s=l==a?' selected=""':"",(s||n.isInRange([e[0],a+1],t,r))&&f.push('<option value="'+e[0]+"-"+u(a+1)+'"'+s+">"+i[a]+"</option>");return f},n.createYearSelect=function(e,t,r,i){var s,o=!0,u=!0,a=['<option selected="">'+e+"</option>"],f=0;i||(i="");while(f<8&&(o||u))f++,s=e-f,o&&n.isInRange([s],t,r)?a.unshift('<option value="'+(s+i)+'">'+s+"</option>"):o=!1,s=e+f,u&&n.isInRange([s],t,r)?a.push('<option value="'+(s+i)+'">'+s+"</option>"):u=!1;return a};var a={changeInput:function(e,t,n){n.setChange(e),t.hide()}};(function(){var t=function(e){return"get"+e+"List"},r={date:"Day",week:"Day",month:"Month"};e.each({setYearList:["Year","Month","Day"],setMonthList:["Month","Day"],setDayList:["Day"]},function(i,s){var o=s.map(t);a[i]=function(t,i,u,a){var f=t.split("-");a||(a=0),e.each(o,function(e,t){if(e>=a){var o=n[t](f,u);if(f.length<2||o.enabled>1||r[u.type]===s[e])return i.bodyElement.html(o.main),o.prev?i.prevElement.attr(o.prev).prop({disabled:!1}):i.prevElement.removeAttr("data-action").prop({disabled:!0}),o.next?i.nextElement.attr(o.next).prop({disabled:!1}):i.nextElement.removeAttr("data-action").prop({disabled:!0}),!1}})}})})(),n.commonInit=function(t,n){t.list=function(r){var i=this.options,s=[];i.options=r||{},e("div.ws-options",n.contentElement).remove(),e.each(i.options,function(e,n){s.push('<li><button value="'+e+'" data-action="changeInput">'+(n||t.formatValue(e))+"</button></li>")}),s.length&&n.contentElement.append('<div class="ws-options"><ul>'+s.join("")+"</ul></div>")},n.contentElement.html('<button class="ws-prev"></button><button class="ws-next"></button><div class="ws-picker-body"></div>'),n.nextElement=e("button.ws-next",n.contentElement),n.prevElement=e("button.ws-prev",n.contentElement),n.bodyElement=e("div.ws-picker-body",n.contentElement),e(r).onTrigger("wslocalechange",function(){n.nextElement.text(o.date.nextText),n.prevElement.text(o.date.prevText)}),t.list(t.options.options)},n.month=function(r){var i=t.objectCreate(t.wsPopover,{},{prepareFor:r.element}),s=e('<span class="popover-opener" />').appendTo(r.buttonWrapper),o=r.options,u=!1,f=function(){var n=e(this).attr("data-action");return a[n]?a[n](e(this).val(),i,r):t.warn("no action for "+n),!1},l=function(){!o.disabled&&!o.readonly&&(u||(n.commonInit(r,i),a.setYearList(o.value||o.defValue,i,r,r.options.startAt)),u=!0,i.show(r.element))};i.element.addClass(r.type+"-popover"),i.contentElement.on("click","button[data-action]",f).on("change","select[data-action]",f),s.on("mousedown",l),r.element.on({focus:function(){r.options.openOnFocus&&l()},mousedown:function(){r.element.is(":focus")&&l()}})},n.date=n.month,t.picker=n}(),function(){var n=Modernizr.inputtypes,i,o={},u=["disabled","readonly","value","min","max","step","title","placeholder"],a=["tabindex","data-placeholder"],f=function(e){};e.each(u.concat(a),function(e,n){var r=n.replace(/^data\-/,"");t.onNodeNamesPropertyModify("input",n,function(e){if(!i){var n=t.data(this,"shadowData");n&&n.data&&n.nativeElement===this&&n.data[r]&&n.data[r](e)}})});var l=function(){return function(t,n){o[t]=n,n.attrs=e.merge([],a,n.attrs),n.props=e.merge([],u,n.props)}}(),c=function(t,n){var r=e.prop(t,"list"),i={},s,o;return r&&e("option",r).each(function(){i[e.prop(this,"value")]=e.prop(this,"label")}),n&&(o=function(){n.shim&&(clearTimeout(s),s=setTimeout(function(){n.shim.list(c(t))},9))},e(r).on("updateDatalist",o),e(t).on("listdatalistchange",o)),i},h=function(e){e.stopImmediatePropagation(e)},p=function(){return e.css(this,"display")!="none"},d=function(t){var n,i=function(){e.style(t.orig,"display","");var r=.6;if(!n||t.orig.offsetWidth)t.element.css({marginLeft:e.css(t.orig,"marginLeft"),marginRight:e.css(t.orig,"marginRight")}),t.buttonWrapper&&(t.element.css({paddingRight:""}),(parseInt(t.buttonWrapper.css("marginLeft"),10)||0)<0?t.element.css({paddingRight:""}).css({paddingRight:(parseInt(t.element.css("paddingRight"),10)||0)+t.buttonWrapper.outerWidth()}):r=t.buttonWrapper.outerWidth(!0)+.6),t.element.outerWidth(e(t.orig).outerWidth()-r);n=!0,e.style(t.orig,"display","none")};e(r).onTrigger("updateshadowdom",i)},v=function(){var n=e.prop(this,"type"),r,f,l,p,v;if(o[n]){l={},p=n,f=e.extend({},s[n],e(e.prop(this,"form")).data(n)||{},e(this).data(n)||{},{orig:this,type:n,options:c(this,l),input:function(e){f._change(e,"input")},change:function(e){f._change(e,"change")},_change:function(t,n){i=!0,e.prop(f.orig,"value",t),i=!1,n&&e(f.orig).trigger(n)}});for(r=0;r<u.length;r++)f[u[r]]=e.prop(this,u[r]);for(r=0;r<a.length;r++)p=a[r].replace(/^data\-/,""),f[p]||(f[p]=e.attr(this,a[r]));l.shim=o[n]._create(f),t.addShadowDom(this,l.shim.element,{data:l.shim||{}}),e(this).on("change",function(t){!i&&t.originalEvent&&l.shim.value(e.prop(this,"value"))}),l.shim.element.on("change input",h),l.shim.element.on("focusin focusout",function(t){t.stopImmediatePropagation(t),e(f.orig).trigger(t)}),l.shim.element.on("focus blur",function(t){t.stopImmediatePropagation(t),e(f.orig).triggerHandler(t)}),v=f.calculateWidth!=null?f.calculateWidth:s.calculateWidth,v&&d(l.shim),e(this).css({display:"none"})}};(!n.range||s.replaceUI)&&l("range",{_create:function(t,n){return e("<span />").insertAfter(t.orig).rangeUI(t).data("rangeUi")}}),["number","time","month","date"].forEach(function(r){(!n[r]||s.replaceUI)&&l(r,{_create:function(n,i){var s=e('<input class="ws-'+r+'" type="text" />').insertAfter(n.orig).spinbtnUI(n).data("wsspinner");return t.picker&&t.picker[r]&&t.picker[r](s),s.buttonWrapper.addClass("input-button-size-"+s.buttonWrapper.children().filter(p).length),s}})}),t.addReady(function(t,n){e("input",t).add(n.filter("input")).each(v)})}()}),jQuery.webshims.register("form-datalist",function(e,t,n,r,i,s){"use strict";var o=r;t.propTypes.element=function(n){t.createPropDefault(n,"attr");if(n.prop)return;n.prop={get:function(){var t=n.attr.get.call(this);return t&&(t=r.getElementById(t),t&&n.propNodeName&&!e.nodeName(t,n.propNodeName)&&(t=null)),t||null},writeable:!1}},function(){var o=e.webshims.cfg.forms,u=Modernizr.input.list;if(u&&!o.customDatalist)return;var a=function(){u||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var n=this,r=e("select",n),i;return r[0]?i=r[0].options:(i=e("option",n).get(),i.length&&t.warn("you should wrap your option-elements for a datalist in a select element to support IE and other old browsers.")),i}}});var n={autocomplete:{attr:{get:function(){var t=this,n=e.data(t,"datalistWidget");return n?n._autocomplete:"autocomplete"in t?t.autocomplete:t.getAttribute("autocomplete")},set:function(t){var n=this,r=e.data(n,"datalistWidget");r?(r._autocomplete=t,t=="off"&&r.hideList()):"autocomplete"in n?n.autocomplete=t:n.setAttribute("autocomplete",t)}}}};o.customDatalist&&(!u||!("selectedOption"in e("<input />")[0]))&&(n.selectedOption={prop:{writeable:!1,get:function(){var t=this,n=e.prop(t,"list"),r=null,i,s;return n?(i=e.prop(t,"value"),i?(s=e.prop(n,"options"),s.length?(e.each(s,function(t,n){if(i==e.prop(n,"value"))return r=n,!1}),r):r):r):r}}}),u?((e("<datalist><select><option></option></select></datalist>").prop("options")||[]).length||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var t=this.options||[];if(!t.length){var n=this,r=e("select",n);r[0]&&r[0].options&&r[0].options.length&&(t=r[0].options)}return t}}}),n.list={attr:{get:function(){var n=t.contentAttr(this,"list");return n!=null?this.removeAttribute("list"):n=e.data(this,"datalistListAttr"),n==null?i:n},set:function(n){var r=this;e.data(r,"datalistListAttr",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"}):n.list={attr:{get:function(){var e=t.contentAttr(this,"list");return e==null?i:e},set:function(n){var r=this;t.contentAttr(r,"list",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"},t.defineNodeNameProperties("input",n),t.addReady(function(t,n){n.filter("datalist > select, datalist, datalist > option, datalist > select > option").closest("datalist").each(function(){var t=e.prop(this,"id");e(this).triggerHandler("updateDatalist")})})},f=0,l={submit:1,button:1,reset:1,hidden:1,range:1,date:1,month:1},c={},h=function(e){if(!e)return[];if(c[e])return c[e];var t;try{t=JSON.parse(localStorage.getItem("storedDatalistOptions"+e))}catch(n){}return c[e]=t||[],t||[]},p=function(e,t){if(!e)return;t=t||[];try{localStorage.setItem("storedDatalistOptions"+e,JSON.stringify(t))}catch(n){}},d=function(t){return t.textContent||t.innerText||e.text([t])||""},v={_create:function(r){if(l[e.prop(r.input,"type")]||l[e.attr(r.input,"type")])return;var i=r.datalist,u=e.data(r.input,"datalistWidget");if(i&&u&&u.datalist!==i){u.datalist=i,u.id=r.id,e(u.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(u,"_resetListCached")),u._resetListCached();return}if(!i){u&&u.destroy();return}if(u&&u.datalist===i)return;f++;var a=this;this.hideList=e.proxy(a,"hideList"),this.datalist=i,this.id=r.id,this.hasViewableData=!0,this._autocomplete=e.attr(r.input,"autocomplete"),e.data(r.input,"datalistWidget",this),this.popover=t.objectCreate(t.wsPopover,{},s.datalistPopover),this.shadowList=this.popover.element.addClass("datalist-polyfill"),this.index=-1,this.input=r.input,this.arrayOptions=[],this.shadowList.delegate("li","mouseenter.datalistWidget mousedown.datalistWidget click.datalistWidget",function(t){var n=e("li:not(.hidden-item)",a.shadowList),i=t.type=="mousedown"||t.type=="click";return a.markItem(n.index(t.currentTarget),i,n),t.type=="click"&&(a.hideList(),o.customDatalist&&e(r.input).trigger("datalistselect")),t.type!="mousedown"}),r.input.setAttribute("autocomplete","off"),e(r.input).attr({"aria-haspopup":"true"}).on({"input.datalistWidget":function(){a.triggeredByDatalist||(a.changedValue=!1,a.showHideOptions())},"keydown.datalistWidget":function(t){var n=t.keyCode,i,s;if(n==40&&!a.showList())return a.markItem(a.index+1,!0),!1;if(!a.popover.isVisible)return;if(n==38)return a.markItem(a.index-1,!0),!1;if(!t.shiftKey&&(n==33||n==36))return a.markItem(0,!0),!1;if(!t.shiftKey&&(n==34||n==35))return s=e("li:not(.hidden-item)",a.shadowList),a.markItem(s.length-1,!0,s),!1;if(n==13||n==27)return n==13&&(i=e("li.active-item:not(.hidden-item)",a.shadowList),a.changeValue(e("li.active-item:not(.hidden-item)",a.shadowList))),a.hideList(),o.customDatalist&&i&&i[0]&&e(r.input).trigger("datalistselect"),!1},"focus.datalistWidget":function(){e(this).hasClass("list-focus")&&a.showList()},"mousedown.datalistWidget":function(){e(this).is(":focus")&&a.showList()}}),e(this.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(this,"_resetListCached")),this._resetListCached(),r.input.form&&(r.input.name||r.input.id)&&e(r.input.form).on("submit.datalistWidget"+r.input.id,function(){if(!e(r.input).hasClass("no-datalist-cache")&&a._autocomplete!="off"){var t=e.prop(r.input,"value"),n=(r.input.name||r.input.id)+e.prop(r.input,"type");a.storedOptions||(a.storedOptions=h(n)),t&&a.storedOptions.indexOf(t)==-1&&(a.storedOptions.push(t),p(n,a.storedOptions))}}),e(n).on("unload.datalist"+this.id+" beforeunload.datalist"+this.id,function(){a.destroy()})},destroy:function(){var t=e.attr(this.input,"autocomplete");e(this.input).off(".datalistWidget").removeData("datalistWidget"),this.shadowList.remove(),e(r).off(".datalist"+this.id),e(n).off(".datalist"+this.id),this.input.form&&this.input.id&&e(this.input.form).off("submit.datalistWidget"+this.input.id),this.input.removeAttribute("aria-haspopup"),t===i?this.input.removeAttribute("autocomplete"):e(this.input).attr("autocomplete",t)},_resetListCached:function(e){var i=this,s;this.needsUpdate=!0,this.lastUpdatedValue=!1,this.lastUnfoundValue="",this.updateTimer||(n.QUnit||(s=e&&r.activeElement==i.input)?i.updateListOptions(s):t.ready("WINDOWLOAD",function(){i.updateTimer=setTimeout(function(){i.updateListOptions(),i=null,f=1},200+100*f)}))},maskHTML:function(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;")},updateListOptions:function(t){this.needsUpdate=!1,clearTimeout(this.updateTimer),this.updateTimer=!1,this.searchStart=o.customDatalist&&e(this.input).hasClass("search-start");var n=[],r=[],i=[],s,u,a,f,l,c;for(a=e.prop(this.datalist,"options"),f=0,l=a.length;f<l;f++){s=a[f];if(s.disabled)return;u={value:e(s).val()||"",text:e.trim(e.attr(s,"label")||d(s)),className:s.className||"",style:e.attr(s,"style")||""},u.text?u.text!=u.value&&(u.className+=" different-label-value"):u.text=u.value,r[f]=u.value,i[f]=u}this.storedOptions||(this.storedOptions=e(this.input).hasClass("no-datalist-cache")||this._autocomplete=="off"?[]:h((this.input.name||this.input.id)+e.prop(this.input,"type"))),this.storedOptions.forEach(function(e,t){r.indexOf(e)==-1&&i.push({value:e,text:e,className:"stored-suggest",style:""})});for(f=0,l=i.length;f<l;f++)c=i[f],n[f]='<li class="'+c.className+'" style="'+c.style+'" tabindex="-1" role="listitem"><span class="option-label">'+this.maskHTML(c.text,"label",c)+'</span> <span class="option-value">'+this.maskHTML(c.value,"value",c)+"</span></li>";this.arrayOptions=i,this.popover.contentElement.html('<div class="datalist-box"><ul role="list">'+n.join("\n")+"</ul></div>"),(t||this.popover.isVisible)&&this.showHideOptions()},showHideOptions:function(t){var n=e.prop(this.input,"value").toLowerCase();if(n===this.lastUpdatedValue||this.lastUnfoundValue&&n.indexOf(this.lastUnfoundValue)===0)return;this.lastUpdatedValue=n;var r=!1,i=this.searchStart,s=e("li",this.shadowList);n?this.arrayOptions.forEach(function(t,o){var u;"lowerText"in t||(t.text!=t.value?t.lowerText=t.value.toLowerCase()+t.text.toLowerCase():t.lowerText=t.text.toLowerCase()),u=t.lowerText.indexOf(n),u=i?!u:u!==-1,u?(e(s[o]).removeClass("hidden-item"),r=!0):e(s[o]).addClass("hidden-item")}):s.length&&(s.removeClass("hidden-item"),r=!0),this.hasViewableData=r,!t&&r&&this.showList(),r||(this.lastUnfoundValue=n,this.hideList())},showList:function(){if(this.popover.isVisible)return!1;this.needsUpdate&&this.updateListOptions(),this.showHideOptions(!0);if(!this.hasViewableData)return!1;var e=this;return e.shadowList.find("li.active-item").removeClass("active-item"),e.popover.show(this.input),!0},hideList:function(){if(!this.popover.isVisible)return!1;var n=this,r=function(t){n.changedValue&&e(n.input).trigger("change"),n.changedValue=!1};return this.popover.hide(),n.shadowList.removeClass("datalist-visible list-item-active"),n.index=-1,n.changedValue&&(n.triggeredByDatalist=!0,t.triggerInlineForm&&t.triggerInlineForm(n.input,"input"),e(n.input).is(":focus")?e(n.input).one("blur",r):r(),n.triggeredByDatalist=!1),!0},scrollIntoView:function(t){var n=e("ul",this.shadowList),r=e("div.datalist-box",this.shadowList),i=t.position(),s;i.top-=(parseInt(n.css("paddingTop"),10)||0)+(parseInt(n.css("marginTop"),10)||0)+(parseInt(n.css("borderTopWidth"),10)||0);if(i.top<0){r.scrollTop(r.scrollTop()+i.top-2);return}i.top+=t.outerHeight(),s=r.height(),i.top>s&&r.scrollTop(r.scrollTop()+(i.top-s)+2)},changeValue:function(t){if(!t[0])return;var n=e("span.option-value",t).text(),r=e.prop(this.input,"value");n!=r&&(e(this.input).prop("value",n).triggerHandler("updateInput"),this.changedValue=!0)},markItem:function(t,n,r){var i,s;r=r||e("li:not(.hidden-item)",this.shadowList);if(!r.length)return;t<0?t=r.length-1:t>=r.length&&(t=0),r.removeClass("active-item"),this.shadowList.addClass("list-item-active"),i=r.filter(":eq("+t+")").addClass("active-item"),n&&(this.changeValue(i),this.scrollIntoView(i)),this.index=t}};a()}()});
+jQuery.webshims.register("form-native-extend",function(e,t,n,r,i,s){"use strict";var o=n.Modernizr,u=o.inputtypes;if(!o.formvalidation||t.bugs.bustedValidity)return;var a=t.inputTypes,f={};t.addInputType=function(e,t){a[e]=t},t.addValidityRule=function(e,t){f[e]=t},t.addValidityRule("typeMismatch",function(e,t,n,r){if(t==="")return!1;var i=r.typeMismatch;return"type"in n||(n.type=(e[0].getAttribute("type")||"").toLowerCase()),a[n.type]&&a[n.type].mismatch&&(i=a[n.type].mismatch(t,e)),i});var l=s.overrideMessages,c=!u.number||!u.time||!u.range||l,h=["customError","typeMismatch","rangeUnderflow","rangeOverflow","stepMismatch","tooLong","patternMismatch","valueMissing","valid"],p=l?["value","checked"]:["value"],d=[],v=function(t,n){if(!t)return;var i=(t.getAttribute&&t.getAttribute("type")||t.type||"").toLowerCase();if(!l&&!a[i])return;l&&!n&&i=="radio"&&t.name?e(r.getElementsByName(t.name)).each(function(){e.prop(this,"validity")}):e.prop(t,"validity")},m={};["input","textarea","select"].forEach(function(n){var r=t.defineNodeNameProperty(n,"setCustomValidity",{prop:{value:function(i){i+="";var s=n=="input"?e(this).getNativeElement()[0]:this;r.prop._supvalue.call(s,i),t.bugs.validationMessage&&t.data(s,"customvalidationMessage",i),c&&(t.data(s,"hasCustomError",!!i),v(s))}}});m[n]=r.prop._supvalue});if(c||l)p.push("min"),p.push("max"),p.push("step"),d.push("input");l&&(p.push("required"),p.push("pattern"),d.push("select"),d.push("textarea"));if(c){var g;d.forEach(function(n){var r=t.defineNodeNameProperty(n,"validity",{prop:{get:function(){if(g)return;var i=n=="input"?e(this).getNativeElement()[0]:this,s=r.prop._supget.call(i);if(!s)return s;var o={};h.forEach(function(e){o[e]=s[e]});if(!e.prop(i,"willValidate"))return o;g=!0;var u=e(i),c={type:(i.getAttribute&&i.getAttribute("type")||"").toLowerCase(),nodeName:(i.nodeName||"").toLowerCase()},p=u.val(),d=!!t.data(i,"hasCustomError"),v;g=!1,o.customError=d;if(o.valid&&o.customError)o.valid=!1;else if(!o.valid){var y=!0;e.each(o,function(e,t){if(t)return y=!1,!1}),y&&(o.valid=!0)}return e.each(f,function(e,r){o[e]=r(u,p,c,o),o[e]&&(o.valid||!v)&&(l||a[c.type]&&a[c.type].mismatch)&&(m[n].call(i,t.createValidationMessage(i,e)),o.valid=!1,v=!0)}),o.valid?(m[n].call(i,""),t.data(i,"hasCustomError",!1)):l&&!v&&!d&&e.each(o,function(e,r){if(e!=="valid"&&r)return m[n].call(i,t.createValidationMessage(i,e)),!1}),o},writeable:!1}})}),p.forEach(function(e){t.onNodeNamesPropertyModify(d,e,function(e){v(this)})});if(r.addEventListener){var y,b=function(t){if(!("form"in t.target))return;var n=t.target.form;clearTimeout(y),v(t.target),n&&l&&e("input",n).each(function(){this.type=="password"&&v(this)})};r.addEventListener("change",b,!0),l&&(r.addEventListener("blur",b,!0),r.addEventListener("keydown",function(e){if(e.keyCode!=13)return;b(e)},!0)),r.addEventListener("input",function(e){clearTimeout(y),y=setTimeout(function(){v(e.target)},290)},!0)}var w=d.join(",");t.addReady(function(t,n){e(w,t).add(n.filter(w)).each(function(){e.prop(this,"validity")})}),l&&t.ready("DOM form-message",function(){t.activeLang({register:"form-core",callback:function(){e("input, select, textarea").getNativeElement().each(function(){if(t.data(this,"hasCustomError"))return;var n=this,r=e.prop(n,"validity")||{valid:!0},i;if(r.valid)return;i=(n.nodeName||"").toLowerCase(),e.each(r,function(e,r){if(e!=="valid"&&r)return m[i].call(n,t.createValidationMessage(n,e)),!1})})}})})}t.defineNodeNameProperty("input","type",{prop:{get:function(){var e=this,n=(e.getAttribute("type")||"").toLowerCase();return t.inputTypes[n]?n:e.type}}})}),jQuery.webshims.register("form-number-date-api",function(e,t,n,r,i){"use strict";t.getStep||(t.getStep=function(t,n){var r=e.attr(t,"step");return r==="any"?r:(n=n||l(t),!u[n]||!u[n].step?r:(r=y.number.asNumber(r),(!isNaN(r)&&r>0?r:u[n].step)*(u[n].stepScaleFactor||1)))}),t.addMinMaxNumberToCache||(t.addMinMaxNumberToCache=function(e,t,n){e+"AsNumber"in n||(n[e+"AsNumber"]=u[n.type].asNumber(t.attr(e)),isNaN(n[e+"AsNumber"])&&e+"Default"in u[n.type]&&(n[e+"AsNumber"]=u[n.type][e+"Default"]))});var s=parseInt("NaN",10),o=r,u=t.inputTypes,a=function(e){return typeof e=="number"||e&&e==e*1},f=function(t){return e('<input type="'+t+'" />').prop("type")===t},l=function(e){return(e.getAttribute("type")||"").toLowerCase()},c=function(e){var t=e*1;return e&&(t==e||e=="0"+t)},h=t.addMinMaxNumberToCache,p=function(e,t){e=""+e,t-=e.length;for(var n=0;n<t;n++)e="0"+e;return e},d=1e-7,v=t.bugs.bustedValidity;t.addValidityRule("stepMismatch",function(e,n,r,i){if(n==="")return!1;"type"in r||(r.type=l(e[0]));var s=(i||{}).stepMismatch||!1,o;if(u[r.type]&&u[r.type].step){"step"in r||(r.step=t.getStep(e[0],r.type));if(r.step=="any")return!1;"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h("min",e,r),o=r.minAsNumber,isNaN(o)&&(o=u[r.type].stepBase||0),s=Math.abs((r.valueAsNumber-o)%r.step),s=!(s<=d||Math.abs(s-r.step)<=d)}return s}),[{name:"rangeOverflow",attr:"max",factor:1},{name:"rangeUnderflow",attr:"min",factor:-1}].forEach(function(e,n){t.addValidityRule(e.name,function(t,n,r,i){var s=(i||{})[e.name]||!1;if(n==="")return s;"type"in r||(r.type=l(t[0]));if(u[r.type]&&u[r.type].asNumber){"valueAsNumber"in r||(r.valueAsNumber=u[r.type].asNumber(n));if(isNaN(r.valueAsNumber))return!1;h(e.attr,t,r);if(isNaN(r[e.attr+"AsNumber"]))return s;s=r[e.attr+"AsNumber"]*e.factor<r.valueAsNumber*e.factor-d}return s})}),t.reflectProperties(["input"],["max","min","step"]);var m=t.defineNodeNameProperty("input","valueAsNumber",{prop:{get:function(){var t=this,n=l(t),r=u[n]&&u[n].asNumber?u[n].asNumber(e.prop(t,"value")):m.prop._supget&&m.prop._supget.apply(t,arguments);return r==null&&(r=s),r},set:function(n){var r=this,i=l(r);if(u[i]&&u[i].numberToString){if(isNaN(n)){e.prop(r,"value","");return}var s=u[i].numberToString(n);s!==!1?e.prop(r,"value",s):t.error("INVALID_STATE_ERR: DOM Exception 11")}else m.prop._supset&&m.prop._supset.apply(r,arguments)}}}),g=t.defineNodeNameProperty("input","valueAsDate",{prop:{get:function(){var t=this,n=l(t);return u[n]&&u[n].asDate&&!u[n].noAsDate?u[n].asDate(e.prop(t,"value")):g.prop._supget&&g.prop._supget.call(t)||null},set:function(n){var r=this,i=l(r);if(!(u[i]&&u[i].dateToString&&!u[i].noAsDate))return g.prop._supset&&g.prop._supset.apply(r,arguments)||null;if(n===null)return e.prop(r,"value",""),"";var s=u[i].dateToString(n);if(s!==!1)return e.prop(r,"value",s),s;t.error("INVALID_STATE_ERR: DOM Exception 11")}}});e.each({stepUp:1,stepDown:-1},function(n,r){var i=t.defineNodeNameProperty("input",n,{prop:{value:function(n){var s,o,a,f,c,h,p=l(this);if(!u[p]||!u[p].asNumber){if(i.prop&&i.prop.value)return i.prop.value.apply(this,arguments);throw t.info("no step method for type: "+p),"invalid state error"}h={type:p},n||(n=1,t.info("you should always use a factor for stepUp/stepDown")),n*=r,o=e.prop(this,"valueAsNumber");if(isNaN(o))throw t.info("valueAsNumber is NaN can't apply stepUp/stepDown "),"invalid state error";s=t.getStep(this,p);if(s=="any")throw t.info("step is 'any' can't apply stepUp/stepDown"),"invalid state error";t.addMinMaxNumberToCache("min",e(this),h),t.addMinMaxNumberToCache("max",e(this),h),s*=n,o+=s,f=(o-(h.minAsNumber||0))%s,f&&Math.abs(f)>d&&(c=o-f,c+=f>0?s:-s,o=c.toFixed(5)*1);if(!isNaN(h.maxAsNumber)&&o>h.maxAsNumber||!isNaN(h.minAsNumber)&&o<h.minAsNumber)throw t.info("max/min overflow can't apply stepUp/stepDown"),"invalid state error";a?e.prop(this,"valueAsDate",a):e.prop(this,"valueAsNumber",o)}}})});var y={number:{mismatch:function(e){return!a(e)},step:1,stepScaleFactor:1,asNumber:function(e){return a(e)?e*1:s},numberToString:function(e){return a(e)?e:!1}},range:{minDefault:0,maxDefault:100},date:{mismatch:function(e){if(!e||!e.split||!/\d$/.test(e))return!0;var t,n=e.split(/\u002D/);if(n.length!==3)return!0;var r=!1;if(n[0].length!==4||n[1].length!=2||n[1]>12||n[2].length!=2||n[2]>33)r=!0;else for(t=0;t<3;t++)if(!c(n[0])){r=!0;break}return r||e!==this.dateToString(this.asDate(e,!0))},step:1,stepScaleFactor:864e5,asDate:function(e,t){return!t&&this.mismatch(e)?null:new Date(this.asNumber(e,!0))},asNumber:function(e,t){var n=s;if(t||!this.mismatch(e))e=e.split(/\u002D/),n=Date.UTC(e[0],e[1]-1,e[2]);return n},numberToString:function(e){return a(e)?this.dateToString(new Date(e*1)):!1},dateToString:function(e){return e&&e.getFullYear?e.getUTCFullYear()+"-"+p(e.getUTCMonth()+1,2)+"-"+p(e.getUTCDate(),2):!1}},time:{mismatch:function(t,n){if(!t||!t.split||!/\d$/.test(t))return!0;t=t.split(/\u003A/);if(t.length<2||t.length>3)return!0;var r=!1,i;return t[2]&&(t[2]=t[2].split(/\u002E/),i=parseInt(t[2][1],10),t[2]=t[2][0]),e.each(t,function(e,t){if(!c(t)||t.length!==2)return r=!0,!1}),r?!0:t[0]>23||t[0]<0||t[1]>59||t[1]<0?!0:t[2]&&(t[2]>59||t[2]<0)?!0:i&&isNaN(i)?!0:(i&&(i<100?i*=100:i<10&&(i*=10)),n===!0?[t,i]:!1)},step:60,stepBase:0,stepScaleFactor:1e3,asDate:function(e){return e=new Date(this.asNumber(e)),isNaN(e)?null:e},asNumber:function(e){var t=s;return e=this.mismatch(e,!0),e!==!0&&(t=Date.UTC("1970",0,1,e[0][0],e[0][1],e[0][2]||0),e[1]&&(t+=e[1])),t},dateToString:function(e){if(e&&e.getUTCHours){var t=p(e.getUTCHours(),2)+":"+p(e.getUTCMinutes(),2),n=e.getSeconds();return n!="0"&&(t+=":"+p(n,2)),n=e.getUTCMilliseconds(),n!="0"&&(t+="."+p(n,3)),t}return!1}},month:{mismatch:function(e){return y.date.mismatch(e+"-01")},step:1,stepScaleFactor:!1,asDate:function(e){return new Date(y.date.asNumber(e+"-01"))},asNumber:function(e){var t=s;return e&&!this.mismatch(e)&&(e=e.split(/\u002D/),e[0]=e[0]*1-1970,e[1]=e[1]*1-1,t=e[0]*12+e[1]),t},numberToString:function(e){var t,n=!1;return a(e)&&(t=e%12,e=(e-t)/12+1970,t+=1,t<1&&(e-=1,t+=12),n=p(e,4)+"-"+p(t,2)),n},dateToString:function(e){if(e&&e.getUTCHours){var t=y.date.dateToString(e);return t.split&&(t=t.split(/\u002D/))?t[0]+"-"+t[1]:!1}return!1}}};if(v||!f("range")||!f("time"))y.range=e.extend({},y.number,y.range),y.time=e.extend({},y.date,y.time),y.month=e.extend({},y.date,y.month);["number","month","range","date","time"].forEach(function(e){(v||!f(e))&&t.addInputType(e,y[e])}),e("<input />").prop("labels")==null&&t.defineNodeNamesProperty("button, input, keygen, meter, output, progress, select, textarea","labels",{prop:{get:function(){if(this.type=="hidden")return null;var t=this.id,n=e(this).closest("label").filter(function(){var e=this.attributes["for"]||{};return!e.specified||e.value==t});return t&&(n=n.add('label[for="'+t+'"]')),n.get()},writeable:!1}})}),function(e){var t=0,n=function(e){return typeof e=="number"||e&&e==e*1},r=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex"],s={_create:function(){var t;this.element.addClass("ws-range").attr({role:"slider"}).html('<span class="ws-range-min" /><span class="ws-range-rail"><span class="ws-range-thumb" /></span>'),this.trail=e(".ws-range-rail",this.element),this.range=e(".ws-range-min",this.element),this.thumb=e(".ws-range-thumb",this.trail),this.dirs=this.element.innerHeight()>this.element.innerWidth()?{mouse:"pageY",pos:"top",range:"height",outerWidth:"outerHeight"}:{mouse:"pageX",pos:"left",range:"width",outerWidth:"outerWidth"},this.updateMetrics(),this.orig=this.options.orig;for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);this.value=this._value,this.value(this.options.value),this.list(this.options.options),this.element.data("rangeUi",this),this.addBindings(),this._init=!0},value:e.noop,_value:function(e,t,n){var r,i=e,s={},o={};!t&&parseFloat(e,10)!=e&&(e=this.options.min+(this.options.max-this.options.min)/2),t||(e=this.normalizeVal(e)),r=100*((e-this.options.min)/(this.options.max-this.options.min)),this.options.value=e,this.thumb.stop(),this.range.stop(),s[this.dirs.pos]=r+"%",o[this.dirs.range]=r+"%",n?(this.thumb.animate(s,{animate:this.options.animate}),this.range.animate(o,{animate:this.options.animate})):(this.thumb.css(s),this.range.css(o)),this.orig&&(i!=e||!this._init&&this.orig.value!=e)&&this.options._change(e),this.element.attr({"aria-valuenow":this.options.value,"aria-valuetext":this.options.options[this.options.value]||this.options.value})},list:function(t){var r=this.options,i=r.min,s=r.max,o=this.trail;r.options=t||{},this.element.attr({"aria-valuetext":r.options[r.value]||r.value}),e(".ws-range-ticks",o).remove(),e.each(r.options,function(e,t){if(!n(e)||e<i||e>s)return;var u=100*((e-i)/(s-i)),a=r.showLabels?' title="'+t+'"':"";o.append('<span class="ws-range-ticks"'+a+' style="'+this.dirs.pos+": "+u+'%;" />')})},readonly:function(e){e=!!e,this.options.readonly=e,this.element.attr("aria-readonly",""+e)},disabled:function(e){e=!!e,this.options.disabled=e,e?this.element.attr({tabindex:-1,"aria-disbaled":"true"}):this.element.attr({tabindex:this.options.tabindex,"aria-disbaled":"false"})},tabindex:function(e){this.options.tabindex=e,this.options.disabled||this.element.attr({tabindex:e})},title:function(e){this.element.prop("title",e)},min:function(e){this.options.min=r(e,0),this.value(this.options.value,!0)},max:function(e){this.options.max=r(e,100),this.value(this.options.value,!0)},step:function(e){this.options.step=e=="any"?"any":r(e,1),this.value(this.options.value)},normalizeVal:function(e){var t,n,r,i=this.options;return e<=i.min?e=i.min:e>=i.max?e=i.max:i.step!="any"&&(r=i.step,t=(e-i.min)%r,n=e-t,Math.abs(t)*2>=r&&(n+=t>0?r:-r),e=n.toFixed(5)*1),e},doStep:function(e){var t=r(this.options.step,1);this.options.step=="any"&&(t=Math.min(t,(this.options.max-this.options.min)/10)),this.value(this.options.value+t*e)},getStepedValueFromPos:function(e){var t,n,r,i;return e<=0?t=this.options.min:e>100?t=this.options.max:(t=(this.options.max-this.options.min)*(e/100)+this.options.min,i=this.options.step,i!="any"&&(n=(t-this.options.min)%i,r=t-n,Math.abs(n)*2>=i&&(r+=n>0?i:-i),t=r.toFixed(5)*1)),t},addBindings:function(){var t,n,r,i=this,s=this.options,o=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},i.orig&&e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),u=function(e,r){var u=i.getStepedValueFromPos((e[i.dirs.mouse]-t)*n);u!=s.value&&(i.value(u,!1,r),o.call("input",u))},a=function(t){t&&t.type=="mouseup"&&(o.call("input",s.value),o.call("change",s.value)),i.element.removeClass("ws-active"),e(document).off("mousemove",u).off("mouseup",a)},f=function(r){r.preventDefault(),e(document).off("mousemove",u).off("mouseup",a);if(!s.readonly&&!s.disabled){t=i.element.focus().addClass("ws-active").offset(),n=i.element.width();if(!n||!t)return;t=t[i.dirs.pos],n=100/(n-(i.thumb[i.dirs.outerWidth]()||2)/2),u(r,i.options.animate),e(document).on({mouseup:a,mousemove:u}),r.stopPropagation()}};o.init("input",s.value,this.options.input),o.init("change",s.value,this.options.change),this.element.on({mousedown:f,focus:function(e){s.disabled||(o.init("input",s.value),o.init("change",s.value),i.element.addClass("ws-focus")),r=!0},blur:function(e){i.element.removeClass("ws-focus ws-active"),r=!1,o.init("input",s.value),o.call("change",s.value)},keyup:function(){i.element.removeClass("ws-active"),o.call("input",s.value),o.call("change",s.value)},mousewheel:function(e,t){t&&r&&!s.readonly&&!s.disabled&&(i.doStep(t),e.preventDefault(),o.call("input",s.value))},keypress:function(e){var t=!0,n=e.keyCode;!s.readonly&&!s.disabled&&(n==39||n==38?i.doStep(1):n==37||n==40?i.doStep(-1):n==33?i.doStep(10):n==34?i.doStep(-10):n==36?i.value(i.options.max):n==35?i.value(i.options.min):t=!1,t&&(i.element.addClass("ws-active"),o.call("input",s.value),e.preventDefault()))}}),this.thumb.on({mousedown:f})},updateMetrics:function(){}};e.fn.rangeUI=function(t){return t=e.extend({readonly:!1,disabled:!1,tabindex:0,min:0,step:1,max:100,value:50,input:e.noop,change:e.noop,_change:e.noop,showLabels:!0},t),this.each(function(){e.webshims.objectCreate(s,{element:{value:e(this)}},t)})},jQuery.webshims.isReady("range-ui",!0)}(jQuery),jQuery.webshims.register("form-number-date-ui",function(e,t,n,r,i,s){"use strict";var o,u=function(e){return e?(e+="",e.length==1?"0"+e:e):""};(function(){var t=e.webshims.formcfg;t.de={numberFormat:{",":".",".":","},timeSigns:":. ",numberSigns:",",dateSigns:".",dFormat:".",patterns:{d:"dd.mm.yy"},date:{close:"schlie\u00dfen",prevText:"zur\u00fcck",nextText:"Vor",currentText:"heute",monthNames:["Januar","Februar","M\u00e4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],monthNamesShort:["Jan","Feb","M\u00e4r","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],dayNames:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],dayNamesShort:["So","Mo","Di","Mi","Do","Fr","Sa"],dayNamesMin:["So","Mo","Di","Mi","Do","Fr","Sa"],weekHeader:"KW",firstDay:1,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t.en={numberFormat:{".":".",",":","},numberSigns:".",dateSigns:"/",timeSigns:":. ",dFormat:"/",patterns:{d:"mm/dd/yy"},date:{closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""}},t["en-US"]=t["en-US"]||t.en,t[""]=t[""]||t["en-US"],o=t[""];var n=function(t){if(!t.date.monthkeys){var n=function(e,n){var r,i=e+1;r=i<10?"0"+i:""+i,t.date.monthkeys[i]=r,t.date.monthkeys[n]=r};t.date.monthkeys={},e.each(t.date.monthNames,n),e.each(t.date.monthNamesShort,n)}};n(o),e.webshims.ready("dom-extend",function(){e.webshims.activeLang({register:"form-core",callback:function(){e.each(arguments,function(i,s){if(t[s])return o=t[s],n(o),e(r).triggerHandler("wslocalechange"),!1})}})})})(),function(){var t=function(t){e(this)[t.type=="mousepressstart"?"addClass":"removeClass"]("mousepress-ui")},n=function(e,t){return typeof e=="number"||e&&e==e*1?e*1:t},i=["step","min","max","readonly","title","disabled","tabindex","placeholder","value"],s=function(t){if(!o.patterns[t+"Obj"]){var n={};e.each(o.patterns[t].split(o[t+"Format"]),function(e,t){n[t]=e}),o.patterns[t+"Obj"]=n}},a={number:function(e){return(e+"").replace(/\,/g,"").replace(/\./,o.numberFormat["."])},time:function(e){return e},month:function(e,t){var n,r=e.split("-");return r[0]&&r[1]&&(n=o.date[t.monthNames]||o.date.monthNames,r[1]=n[r[1]*1-1],r[1]&&(e=o.date.showMonthAfterYear?r.join(" "):r[1]+" "+r[0])),e},date:function(e){var t=(e+"").split("-");return t[2]&&t[1]&&t[0]&&(e=o.patterns.d.replace("yy",t[0]||""),e=e.replace("mm",t[1]||""),e=e.replace("dd",t[2]||"")),e}},f={number:function(e){return(e+"").replace(o.numberFormat[","],"").replace(o.numberFormat["."],".")},time:function(e){return e},month:function(e){var t=e.trim().split(/[\s-\/\\]+/);return t.length==2&&(t[0]=o.date.monthkeys[t[0]]||t[0],t[1]=o.date.monthkeys[t[1]]||t[1],t[1].length==2?e=t[0]+"-"+t[1]:t[0].length==2&&(e=t[1]+"-"+t[0])),e},date:function(e){s("d");var t,n=o.patterns.dObj;return e=e.split(o.dFormat),e.length==3?[u(e[n.yy]),u(e[n.mm]),u(e[n.dd])].join("-"):""}},l={number:{step:1},time:{step:60},month:{step:1,start:new Date((new Date).getFullYear(),0,1)},date:{step:1,start:new Date((new Date).getFullYear(),0,1)}},c=function(){var t={};return function(n){var r;return t[n]||(r=e('<input type="'+n+'" />'),t[n]=function(e){var t=typeof e=="object"?"valueAsDate":"value";return r.prop(t,e).prop("valueAsNumber")}),t[n]}}();l.range=l.number;var h={_create:function(){var t;this.type=this.options.type,this.orig=this.options.orig,this.elemHelper=e('<input type="'+this.type+'" />'),this.asNumber=c(this.type),this.buttonWrapper=e('<span class="input-buttons '+this.type+'-input-buttons"><span unselectable="on" class="step-controls"><span class="step-up"></span><span class="step-down"></span></span></span>').insertAfter(this.element),typeof l[this.type].start=="object"&&(l[this.type].start=this.asNumber(l[this.type].start));for(t=0;t<i.length;t++)this[i[t]](this.options[i[t]]);var n=this.element.attr("autocomplete","off").data("wsspinner",this);this.addBindings(),this._init=!0},parseValue:function(e){return f[this.type](e)},formatValue:function(e){return a[this.type](e,this.options)},placeholder:function(e){var t;this.options.placeholder=e,this.type=="date"&&(t=(e||"").split("-"),t.length==3&&(this.options.placeholder=o.patterns.d.replace("yy",t[0]).replace("mm",t[1]).replace("dd",t[2]))),this.element.prop("placeholder",this.options.placeholder)},addZero:u,_setStartInRange:function(){var e=l[this.type].start||0;!isNaN(this.minAsNumber)&&e<this.minAsNumber?e=this.minAsNumber:!isNaN(this.maxAsNumber)&&e>this.maxAsNumber&&(e=this.maxAsNumber),this.elemHelper.prop("valueAsNumber",e).prop("value"),this.options.defValue=this.elemHelper.prop("value")},value:function(e){this.valueAsNumber=this.asNumber(e),this.options.value=e,isNaN(this.valueAsNumber)?this._setStartInRange():this.elemHelper.prop("value",e),this.element.prop("value",a[this.type](e,this.options))},list:function(e){this.options.options=e||{}},readonly:function(e){this.options.readonly=!!e,this.element.prop("readonly",this.options.readonly),(this.options.readonly||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-readonly")},disabled:function(e){this.options.disabled=!!e,this.element.prop("disabled",this.options.disabled),(this.options.disabled||this._init)&&this.buttonWrapper[this.options.readonly?"addClass":"removeClass"]("ws-disabled")},tabindex:function(e){this.options.tabindex=e,this.element.prop("tabindex",this.options.tabindex)},title:function(e){this.options.title=e,this.element.prop("tabindex",this.options.title)},min:function(e){this.elemHelper.prop("min",e),this.minAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},max:function(e){this.elemHelper.prop("max",e),this.maxAsNumber=this.asNumber(e),this.valueAsNumber!=null&&isNaN(this.valueAsNumber)&&this._setStartInRange()},step:function(e){var t=l[this.type];this.elemHelper.prop("step",n(e,t.step))},addBindings:function(){var n,i=this,s=this.options,u=function(){var t={};return{init:function(n,r,s){t[n]||(t[n]={fn:s},e(i.orig).on(n,function(){t[n].val=e.prop(i.orig,"value")})),t[n].val=r},call:function(e,n){t[e]&&t[e].val!=n&&(clearTimeout(t[e].timer),t[e].val=n,t[e].timer=setTimeout(function(){t[e].fn(n,i)},0))}}}(),a={},l=function(e){if(l.prevent)return e.preventDefault(),i.element.focus(),e.stopImmediatePropagation(),!0},c=function(){return!s.disabled&&!n&&i.element[0].focus(),l.set(),!1};l.set=function(){var e,t=function(){l.prevent=!1};return function(){clearTimeout(e),l.prevent=!0,setTimeout(t,9)}}(),["stepUp","stepDown"].forEach(function(e){a[e]=function(t){if(!s.disabled&&!s.readonly){n||c();var r=!1;t||(t=1);try{i.elemHelper[e](t),r=i.elemHelper.prop("value"),i.value(r),u.call("input",r)}catch(o){}return r}}}),this.buttonWrapper.on("mousedown",c),this.setChange=function(e){i.value(e),u.call("input",e),u.call("change",e)},this.element.on({blur:function(t){!l(t)&&!s.disabled&&!s.readonly&&(u.call("input",e.prop(i.orig,"value")),u.call("change",e.prop(i.orig,"value")),l.prevent||(n=!1))},focus:function(){u.init("input",e.prop(i.orig,"value"),i.options.input),u.init("change",e.prop(i.orig,"value"),i.options.change),n=!0},change:function(){var t=f[i.type](e.prop(this,"value"));e.prop(i.orig,"value",t),u.call("input",t),u.call("change",t)},mousewheel:function(e,t){t&&n&&!s.disabled&&(a[t>0?"stepUp":"stepDown"](),e.preventDefault())},keypress:function(e){var t,n=!0,r=e.keyCode;r==38?a.stepUp():r==40?a.stepDown():!e.ctrlKey&&!e.metaKey&&o[i.type+"Signs"]?(t=String.fromCharCode(e.charCode==null?r:e.charCode),n=!(t<" "||(o[i.type+"Signs"]+"0123456789").indexOf(t)>-1)):n=!1,n&&e.preventDefault()}}),e(r).on("wslocalechange",function(){i.value(i.options.value)}),e(".step-up",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepUp()}}),e(".step-down",this.buttonWrapper).on({"mousepressstart mousepressend":t,"mousedown mousepress":function(e){a.stepDown()}})}};e.fn.spinbtnUI=function(t){return t=e.extend({monthNames:"monthNamesShort",size:1,startAt:0,selectNav:!1,openOnFocus:!1},t),this.each(function(){e.webshims.objectCreate(h,{element:{value:e(this)}},t)})}}(),function(){var n={},i={},s=function(e){return[e.getFullYear(),u(e.getMonth()+1),u(e.getDate())]};n.getYearList=function(e,t){var r,i,s,o,u,a,f;e=e[0]*1;var l=t.options.size||1,c=e%(12*l),h=e-c,p=t.options.max.split("-"),d=t.options.min.split("-"),v=0,m="";for(r=0;r<l;r++){r?h+=12:a=n.isInRange([h-1],p,d)?{"data-action":"setYearList",value:h-1}:!1,m+='<div class="year-list"><h3>'+h+" - "+(h+11)+"</h3>",u=[];for(i=0;i<12;i++)s=h+i,n.isInRange([s],p,d)?(o="",v++):o=' disabled="disabled"',u.push('<li><button type="button"'+o+'" data-action="setMonthList" value="'+s+'">'+s+"</button></li>");r==l-1&&(f=n.isInRange([s+1],p,d)?{"data-action":"setYearList",value:s+1}:!1),m+='<ul class="year-list">'+u.join("")+"</ul></div>"}return{enabled:v,main:m,next:f,prev:a}},n.getMonthList=function(e,t){var r,i,s,u,a,f,l,c,h,p=t.options.size||1,d=t.options.max.split("-"),v=t.options.min.split("-"),m=0,g="";e=e[0]-Math.floor((p-1)/2);for(r=0;r<p;r++){r?e++:c=n.isInRange([e-1],d,v)?{"data-action":"setMonthList",value:e-1}:!1,r==p-1&&(h=n.isInRange([e+1],d,v)?{"data-action":"setMonthList",value:e+1}:!1),f=[],!n.isInRange([e,"01"],d,v)&&!n.isInRange([e,"12"],d,v)?(a=' disabled="disabled"',l=!0):(l=!1,a=""),g+='<div class="month-list">',g+=t.options.selectNav?'<select data-action="setMonthList">'+n.createYearSelect(e,d,v).join("")+"</select>":'<button data-action="setYearList"'+a+' value="'+e+'">'+e+"</button>";for(i=0;i<12;i++)u=o.date.monthkeys[i+1],s=o.date.monthNames[i],l||!n.isInRange([e,u],d,v)?a=' disabled="disabled"':(a="",m++),f.push('<li><button type="button"'+a+'" data-action="'+(t.type=="month"?"changeInput":"setDayList")+'" value="'+e+"-"+u+'">'+s+"</button></li>");g+="<ul>"+f.join("")+"</ul></div>"}return{enabled:m,main:g,prev:c,next:h}},n.getDayList=function(e,t){var r,i,u,a,f,l,c,h,p,d,v,m,g,y,b,w,E,S,x=t.options.size||1,T=t.options.max.split("-"),N=t.options.min.split("-"),C=o.date[t.options.monthNames]||o.date.monthNames,k=0,L=[],A=new Date(e[0],e[1]-1,1);A.setMonth(A.getMonth()-Math.floor((x-1)/2));for(r=0;r<x;r++){m=A.getMonth(),r||(S=new Date(A.getTime()),S.setDate(-1),b=s(S),p=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1),b=s(A),L.push('<div class="day-list">'),t.options.selectNav?(w=['<select data-action="setDayList">'+n.createMonthSelect(b,T,N,C).join("")+"</select>",'<select data-action="setDayList">'+n.createYearSelect(b[0],T,N,"-"+b[1]).join("")+"</select>"],o.date.showMonthAfterYear&&w.reverse(),L.push(w.join(" "))):(w=[C[b[1]*1-1],b[0]],o.date.showMonthAfterYear&&w.reverse(),L.push('<button data-action="setMonthList" value="'+b[0]+"-"+b[1]+'">'+w.join(" ")+"</button>")),L.push("<table><tr>");for(u=1;u<o.date.dayNamesShort.length;u++)L.push("<th>"+o.date.dayNamesShort[u]+"</th>");L.push("<th>"+o.date.dayNamesShort[0]+"</th>"),L.push("</tr><tr>");for(i=0;i<46;i++){v=i&&!(i%7),g=A.getMonth(),y=m!=g;if(v&&y){L.push("</tr>");break}v&&L.push("</tr><tr>"),i||(a=A.getDay()-1,a>-1&&a<6&&A.setDate(A.getDate()-a),g=A.getMonth(),y=m!=g),b=s(A),E='<td><button data-action="changeInput" value="'+b.join("-")+'"',y&&(E+=' data-othermonth=""'),n.isInRange(b,T,N)||(E+=' disabled=""'),L.push(E+">"+A.getDate()+"</button></td>"),A.setDate(A.getDate()+1)}L.push("</table></div>"),r==x-1&&(b=s(A),b[2]=1,d=n.isInRange(b,T,N)?{"data-action":"setDayList",value:b[0]+"-"+b[1]}:!1)}return{enabled:9,main:L.join(""),prev:p,next:d}},n.isInRange=function(e,t,n){var r,i=!0;for(r=0;r<e.length;r++){if(n[r]&&n[r]>e[r]){i=!1;break}if(!n[r]||n[r]!=e[r])break}if(i)for(r=0;r<e.length;r++){if(t[r]&&t[r]<e[r]){i=!1;break}if(!t[r]||t[r]!=e[r])break}return i},n.createMonthSelect=function(e,t,r,i){i||(i=o.date.monthNames);var s,a=0,f=[],l=e[1]-1;for(;a<i.length;a++)s=l==a?' selected=""':"",(s||n.isInRange([e[0],a+1],t,r))&&f.push('<option value="'+e[0]+"-"+u(a+1)+'"'+s+">"+i[a]+"</option>");return f},n.createYearSelect=function(e,t,r,i){var s,o=!0,u=!0,a=['<option selected="">'+e+"</option>"],f=0;i||(i="");while(f<8&&(o||u))f++,s=e-f,o&&n.isInRange([s],t,r)?a.unshift('<option value="'+(s+i)+'">'+s+"</option>"):o=!1,s=e+f,u&&n.isInRange([s],t,r)?a.push('<option value="'+(s+i)+'">'+s+"</option>"):u=!1;return a};var a={changeInput:function(e,t,n){n.setChange(e),t.hide()}};(function(){var t=function(e){return"get"+e+"List"},r={date:"Day",week:"Day",month:"Month"};e.each({setYearList:["Year","Month","Day"],setMonthList:["Month","Day"],setDayList:["Day"]},function(i,s){var o=s.map(t);a[i]=function(t,i,u,a){var f=t.split("-");a||(a=0),e.each(o,function(e,t){if(e>=a){var o=n[t](f,u);if(f.length<2||o.enabled>1||r[u.type]===s[e])return i.bodyElement.html(o.main),o.prev?i.prevElement.attr(o.prev).prop({disabled:!1}):i.prevElement.removeAttr("data-action").prop({disabled:!0}),o.next?i.nextElement.attr(o.next).prop({disabled:!1}):i.nextElement.removeAttr("data-action").prop({disabled:!0}),!1}})}})})(),n.commonInit=function(t,n){t.list=function(r){var i=this.options,s=[];i.options=r||{},e("div.ws-options",n.contentElement).remove(),e.each(i.options,function(e,n){s.push('<li><button value="'+e+'" data-action="changeInput">'+(n||t.formatValue(e))+"</button></li>")}),s.length&&n.contentElement.append('<div class="ws-options"><ul>'+s.join("")+"</ul></div>")},n.contentElement.html('<button class="ws-prev"></button><button class="ws-next"></button><div class="ws-picker-body"></div>'),n.nextElement=e("button.ws-next",n.contentElement),n.prevElement=e("button.ws-prev",n.contentElement),n.bodyElement=e("div.ws-picker-body",n.contentElement),e(r).onTrigger("wslocalechange",function(){n.nextElement.text(o.date.nextText),n.prevElement.text(o.date.prevText)}),t.list(t.options.options)},n.month=function(r){var i=t.objectCreate(t.wsPopover,{},{prepareFor:r.element}),s=e('<span class="popover-opener" />').appendTo(r.buttonWrapper),o=r.options,u=!1,f=function(){var n=e(this).attr("data-action");return a[n]?a[n](e(this).val(),i,r):t.warn("no action for "+n),!1},l=function(){!o.disabled&&!o.readonly&&(u||(n.commonInit(r,i),a.setYearList(o.value||o.defValue,i,r,r.options.startAt)),u=!0,i.show(r.element))};i.element.addClass(r.type+"-popover"),i.contentElement.on("click","button[data-action]",f).on("change","select[data-action]",f),s.on("mousedown",l),r.element.on({focus:function(){r.options.openOnFocus&&l()},mousedown:function(){r.element.is(":focus")&&l()}})},n.date=n.month,t.picker=n}(),function(){var n=Modernizr.inputtypes,i,o={},u=["disabled","readonly","value","min","max","step","title","placeholder"],a=["tabindex","data-placeholder"],f=function(e){};e.each(u.concat(a),function(e,n){var r=n.replace(/^data\-/,"");t.onNodeNamesPropertyModify("input",n,function(e){if(!i){var n=t.data(this,"shadowData");n&&n.data&&n.nativeElement===this&&n.data[r]&&n.data[r](e)}})});var l=function(){return function(t,n){o[t]=n,n.attrs=e.merge([],a,n.attrs),n.props=e.merge([],u,n.props)}}(),c=function(t,n){var r=e.prop(t,"list"),i={},s,o;return r&&e("option",r).each(function(){i[e.prop(this,"value")]=e.prop(this,"label")}),n&&(o=function(){n.shim&&(clearTimeout(s),s=setTimeout(function(){n.shim.list(c(t))},9))},e(r).on("updateDatalist",o),e(t).on("listdatalistchange",o)),i},h=function(e){e.stopImmediatePropagation(e)},p=function(){return e.css(this,"display")!="none"},d=function(t){var n,i=function(){e.style(t.orig,"display","");var r=.6;if(!n||t.orig.offsetWidth)t.element.css({marginLeft:e.css(t.orig,"marginLeft"),marginRight:e.css(t.orig,"marginRight")}),t.buttonWrapper&&(t.element.css({paddingRight:""}),(parseInt(t.buttonWrapper.css("marginLeft"),10)||0)<0?t.element.css({paddingRight:""}).css({paddingRight:(parseInt(t.element.css("paddingRight"),10)||0)+t.buttonWrapper.outerWidth()}):r=t.buttonWrapper.outerWidth(!0)+.6),t.element.outerWidth(e(t.orig).outerWidth()-r);n=!0,e.style(t.orig,"display","none")};e(r).onTrigger("updateshadowdom",i)},v=function(){var n=e.prop(this,"type"),r,f,l,p,v;if(o[n]){l={},p=n,f=e.extend({},s[n],e(e.prop(this,"form")).data(n)||{},e(this).data(n)||{},{orig:this,type:n,options:c(this,l),input:function(e){f._change(e,"input")},change:function(e){f._change(e,"change")},_change:function(t,n){i=!0,e.prop(f.orig,"value",t),i=!1,n&&e(f.orig).trigger(n)}});for(r=0;r<u.length;r++)f[u[r]]=e.prop(this,u[r]);for(r=0;r<a.length;r++)p=a[r].replace(/^data\-/,""),f[p]||(f[p]=e.attr(this,a[r]));l.shim=o[n]._create(f),t.addShadowDom(this,l.shim.element,{data:l.shim||{}}),e(this).on("change",function(t){!i&&t.originalEvent&&l.shim.value(e.prop(this,"value"))}),l.shim.element.on("change input",h),l.shim.element.on("focusin focusout",function(t){t.stopImmediatePropagation(t),e(f.orig).trigger(t)}),l.shim.element.on("focus blur",function(t){t.stopImmediatePropagation(t),e(f.orig).triggerHandler(t)}),v=f.calculateWidth!=null?f.calculateWidth:s.calculateWidth,v&&d(l.shim),e(this).css({display:"none"})}};(!n.range||s.replaceUI)&&l("range",{_create:function(t,n){return e("<span />").insertAfter(t.orig).rangeUI(t).data("rangeUi")}}),["number","time","month","date"].forEach(function(r){(!n[r]||s.replaceUI)&&l(r,{_create:function(n,i){var s=e('<input class="ws-'+r+'" type="text" />').insertAfter(n.orig).spinbtnUI(n).data("wsspinner");return t.picker&&t.picker[r]&&t.picker[r](s),s.buttonWrapper.addClass("input-button-size-"+s.buttonWrapper.children().filter(p).length),s}})}),t.addReady(function(t,n){e("input",t).add(n.filter("input")).each(v)})}()}),jQuery.webshims.register("form-datalist",function(e,t,n,r,i,s){"use strict";var o=r;t.propTypes.element=function(n){t.createPropDefault(n,"attr");if(n.prop)return;n.prop={get:function(){var t=n.attr.get.call(this);return t&&(t=r.getElementById(t),t&&n.propNodeName&&!e.nodeName(t,n.propNodeName)&&(t=null)),t||null},writeable:!1}},function(){var o=e.webshims.cfg.forms,u=Modernizr.input.list;if(u&&!o.customDatalist)return;var a=function(){u||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var n=this,r=e("select",n),i;return r[0]?i=r[0].options:(i=e("option",n).get(),i.length&&t.warn("you should wrap your option-elements for a datalist in a select element to support IE and other old browsers.")),i}}});var n={autocomplete:{attr:{get:function(){var t=this,n=e.data(t,"datalistWidget");return n?n._autocomplete:"autocomplete"in t?t.autocomplete:t.getAttribute("autocomplete")},set:function(t){var n=this,r=e.data(n,"datalistWidget");r?(r._autocomplete=t,t=="off"&&r.hideList()):"autocomplete"in n?n.autocomplete=t:n.setAttribute("autocomplete",t)}}}};o.customDatalist&&(!u||!("selectedOption"in e("<input />")[0]))&&(n.selectedOption={prop:{writeable:!1,get:function(){var t=this,n=e.prop(t,"list"),r=null,i,s;return n?(i=e.prop(t,"value"),i?(s=e.prop(n,"options"),s.length?(e.each(s,function(t,n){if(i==e.prop(n,"value"))return r=n,!1}),r):r):r):r}}}),u?((e("<datalist><select><option></option></select></datalist>").prop("options")||[]).length||t.defineNodeNameProperty("datalist","options",{prop:{writeable:!1,get:function(){var t=this.options||[];if(!t.length){var n=this,r=e("select",n);r[0]&&r[0].options&&r[0].options.length&&(t=r[0].options)}return t}}}),n.list={attr:{get:function(){var n=t.contentAttr(this,"list");return n!=null?this.removeAttribute("list"):n=e.data(this,"datalistListAttr"),n==null?i:n},set:function(n){var r=this;e.data(r,"datalistListAttr",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"}):n.list={attr:{get:function(){var e=t.contentAttr(this,"list");return e==null?i:e},set:function(n){var r=this;t.contentAttr(r,"list",n),t.objectCreate(v,i,{input:r,id:n,datalist:e.prop(r,"list")}),e(r).triggerHandler("listdatalistchange")}},initAttr:!0,reflect:!0,propType:"element",propNodeName:"datalist"},t.defineNodeNameProperties("input",n),t.addReady(function(t,n){n.filter("datalist > select, datalist, datalist > option, datalist > select > option").closest("datalist").each(function(){var t=e.prop(this,"id");e(this).triggerHandler("updateDatalist")})})},f=0,l={submit:1,button:1,reset:1,hidden:1,range:1,date:1,month:1},c={},h=function(e){if(!e)return[];if(c[e])return c[e];var t;try{t=JSON.parse(localStorage.getItem("storedDatalistOptions"+e))}catch(n){}return c[e]=t||[],t||[]},p=function(e,t){if(!e)return;t=t||[];try{localStorage.setItem("storedDatalistOptions"+e,JSON.stringify(t))}catch(n){}},d=function(t){return t.textContent||t.innerText||e.text([t])||""},v={_create:function(r){if(l[e.prop(r.input,"type")]||l[e.attr(r.input,"type")])return;var i=r.datalist,u=e.data(r.input,"datalistWidget");if(i&&u&&u.datalist!==i){u.datalist=i,u.id=r.id,e(u.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(u,"_resetListCached")),u._resetListCached();return}if(!i){u&&u.destroy();return}if(u&&u.datalist===i)return;f++;var a=this;this.hideList=e.proxy(a,"hideList"),this.datalist=i,this.id=r.id,this.hasViewableData=!0,this._autocomplete=e.attr(r.input,"autocomplete"),e.data(r.input,"datalistWidget",this),this.popover=t.objectCreate(t.wsPopover,{},s.datalistPopover),this.shadowList=this.popover.element.addClass("datalist-polyfill"),this.index=-1,this.input=r.input,this.arrayOptions=[],this.shadowList.delegate("li","mouseenter.datalistWidget mousedown.datalistWidget click.datalistWidget",function(t){var n=e("li:not(.hidden-item)",a.shadowList),i=t.type=="mousedown"||t.type=="click";return a.markItem(n.index(t.currentTarget),i,n),t.type=="click"&&(a.hideList(),o.customDatalist&&e(r.input).trigger("datalistselect")),t.type!="mousedown"}),r.input.setAttribute("autocomplete","off"),e(r.input).attr({"aria-haspopup":"true"}).on({"input.datalistWidget":function(){a.triggeredByDatalist||(a.changedValue=!1,a.showHideOptions())},"keydown.datalistWidget":function(t){var n=t.keyCode,i,s;if(n==40&&!a.showList())return a.markItem(a.index+1,!0),!1;if(!a.popover.isVisible)return;if(n==38)return a.markItem(a.index-1,!0),!1;if(!t.shiftKey&&(n==33||n==36))return a.markItem(0,!0),!1;if(!t.shiftKey&&(n==34||n==35))return s=e("li:not(.hidden-item)",a.shadowList),a.markItem(s.length-1,!0,s),!1;if(n==13||n==27)return n==13&&(i=e("li.active-item:not(.hidden-item)",a.shadowList),a.changeValue(e("li.active-item:not(.hidden-item)",a.shadowList))),a.hideList(),o.customDatalist&&i&&i[0]&&e(r.input).trigger("datalistselect"),!1},"focus.datalistWidget":function(){e(this).hasClass("list-focus")&&a.showList()},"mousedown.datalistWidget":function(){e(this).is(":focus")&&a.showList()}}),e(this.datalist).off("updateDatalist.datalistWidget").on("updateDatalist.datalistWidget",e.proxy(this,"_resetListCached")),this._resetListCached(),r.input.form&&(r.input.name||r.input.id)&&e(r.input.form).on("submit.datalistWidget"+r.input.id,function(){if(!e(r.input).hasClass("no-datalist-cache")&&a._autocomplete!="off"){var t=e.prop(r.input,"value"),n=(r.input.name||r.input.id)+e.prop(r.input,"type");a.storedOptions||(a.storedOptions=h(n)),t&&a.storedOptions.indexOf(t)==-1&&(a.storedOptions.push(t),p(n,a.storedOptions))}}),e(n).on("unload.datalist"+this.id+" beforeunload.datalist"+this.id,function(){a.destroy()})},destroy:function(){var t=e.attr(this.input,"autocomplete");e(this.input).off(".datalistWidget").removeData("datalistWidget"),this.shadowList.remove(),e(r).off(".datalist"+this.id),e(n).off(".datalist"+this.id),this.input.form&&this.input.id&&e(this.input.form).off("submit.datalistWidget"+this.input.id),this.input.removeAttribute("aria-haspopup"),t===i?this.input.removeAttribute("autocomplete"):e(this.input).attr("autocomplete",t)},_resetListCached:function(e){var i=this,s;this.needsUpdate=!0,this.lastUpdatedValue=!1,this.lastUnfoundValue="",this.updateTimer||(n.QUnit||(s=e&&r.activeElement==i.input)?i.updateListOptions(s):t.ready("WINDOWLOAD",function(){i.updateTimer=setTimeout(function(){i.updateListOptions(),i=null,f=1},200+100*f)}))},maskHTML:function(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;")},updateListOptions:function(t){this.needsUpdate=!1,clearTimeout(this.updateTimer),this.updateTimer=!1,this.searchStart=o.customDatalist&&e(this.input).hasClass("search-start");var n=[],r=[],i=[],s,u,a,f,l,c;for(a=e.prop(this.datalist,"options"),f=0,l=a.length;f<l;f++){s=a[f];if(s.disabled)return;u={value:e(s).val()||"",text:e.trim(e.attr(s,"label")||d(s)),className:s.className||"",style:e.attr(s,"style")||""},u.text?u.text!=u.value&&(u.className+=" different-label-value"):u.text=u.value,r[f]=u.value,i[f]=u}this.storedOptions||(this.storedOptions=e(this.input).hasClass("no-datalist-cache")||this._autocomplete=="off"?[]:h((this.input.name||this.input.id)+e.prop(this.input,"type"))),this.storedOptions.forEach(function(e,t){r.indexOf(e)==-1&&i.push({value:e,text:e,className:"stored-suggest",style:""})});for(f=0,l=i.length;f<l;f++)c=i[f],n[f]='<li class="'+c.className+'" style="'+c.style+'" tabindex="-1" role="listitem"><span class="option-label">'+this.maskHTML(c.text,"label",c)+'</span> <span class="option-value">'+this.maskHTML(c.value,"value",c)+"</span></li>";this.arrayOptions=i,this.popover.contentElement.html('<div class="datalist-box"><ul role="list">'+n.join("\n")+"</ul></div>"),(t||this.popover.isVisible)&&this.showHideOptions()},showHideOptions:function(t){var n=e.prop(this.input,"value").toLowerCase();if(n===this.lastUpdatedValue||this.lastUnfoundValue&&n.indexOf(this.lastUnfoundValue)===0)return;this.lastUpdatedValue=n;var r=!1,i=this.searchStart,s=e("li",this.shadowList);n?this.arrayOptions.forEach(function(t,o){var u;"lowerText"in t||(t.text!=t.value?t.lowerText=t.value.toLowerCase()+t.text.toLowerCase():t.lowerText=t.text.toLowerCase()),u=t.lowerText.indexOf(n),u=i?!u:u!==-1,u?(e(s[o]).removeClass("hidden-item"),r=!0):e(s[o]).addClass("hidden-item")}):s.length&&(s.removeClass("hidden-item"),r=!0),this.hasViewableData=r,!t&&r&&this.showList(),r||(this.lastUnfoundValue=n,this.hideList())},showList:function(){if(this.popover.isVisible)return!1;this.needsUpdate&&this.updateListOptions(),this.showHideOptions(!0);if(!this.hasViewableData)return!1;var e=this;return e.shadowList.find("li.active-item").removeClass("active-item"),e.popover.show(this.input),!0},hideList:function(){if(!this.popover.isVisible)return!1;var n=this,r=function(t){n.changedValue&&e(n.input).trigger("change"),n.changedValue=!1};return this.popover.hide(),n.shadowList.removeClass("datalist-visible list-item-active"),n.index=-1,n.changedValue&&(n.triggeredByDatalist=!0,t.triggerInlineForm&&t.triggerInlineForm(n.input,"input"),e(n.input).is(":focus")?e(n.input).one("blur",r):r(),n.triggeredByDatalist=!1),!0},scrollIntoView:function(t){var n=e("ul",this.shadowList),r=e("div.datalist-box",this.shadowList),i=t.position(),s;i.top-=(parseInt(n.css("paddingTop"),10)||0)+(parseInt(n.css("marginTop"),10)||0)+(parseInt(n.css("borderTopWidth"),10)||0);if(i.top<0){r.scrollTop(r.scrollTop()+i.top-2);return}i.top+=t.outerHeight(),s=r.height(),i.top>s&&r.scrollTop(r.scrollTop()+(i.top-s)+2)},changeValue:function(t){if(!t[0])return;var n=e("span.option-value",t).text(),r=e.prop(this.input,"value");n!=r&&(e(this.input).prop("value",n).triggerHandler("updateInput"),this.changedValue=!0)},markItem:function(t,n,r){var i,s;r=r||e("li:not(.hidden-item)",this.shadowList);if(!r.length)return;t<0?t=r.length-1:t>=r.length&&(t=0),r.removeClass("active-item"),this.shadowList.addClass("list-item-active"),i=r.filter(":eq("+t+")").addClass("active-item"),n&&(this.changeValue(i),this.scrollIntoView(i)),this.index=t}};a()}()});
View
950 demos/js-webshim/minified/shims/dom-extend.js
@@ -1 +1,949 @@
-jQuery.webshims.register("dom-extend",function(e,t,n,r,i){"use strict";var s=t.modules,o=/\s*,\s*/,u={},a={},f={},l={},c={},h=e.fn.val,p=function(t,n,r,i,s){return s?h.call(e(t)):h.call(e(t),r)};e.fn.val=function(t){var n=this[0];arguments.length&&t==null&&(t="");if(!arguments.length)return!n||n.nodeType!==1?h.call(this):e.prop(n,"value",t,"val",!0);if(e.isArray(t))return h.apply(this,arguments);var r=e.isFunction(t);return this.each(function(s){n=this;if(n.nodeType===1)if(r){var o=t.call(n,s,e.prop(n,"value",i,"val",!0));o==null&&(o=""),e.prop(n,"value",o,"val")}else e.prop(n,"value",t,"val")})},e.fn.onTrigger=function(e,t){return this.on(e,t).each(t)};var d="_webshimsLib"+Math.round(Math.random()*1e3),v=function(t,n,r){t=t.jquery?t[0]:t;if(!t)return r||{};var s=e.data(t,d);return r!==i&&(s||(s=e.data(t,d,{})),n&&(s[n]=r)),n?s&&s[n]:s};[{name:"getNativeElement",prop:"nativeElement"},{name:"getShadowElement",prop:"shadowElement"},{name:"getShadowFocusElement",prop:"shadowFocusElement"}].forEach(function(t){e.fn[t.name]=function(){return this.map(function(){var e=v(this,"shadowData");return e&&e[t.prop]||this})}}),["removeAttr","prop","attr"].forEach(function(n){u[n]=e[n],e[n]=function(t,r,s,o,l){var h=o=="val",d=h?p:u[n];if(!t||!a[r]||t.nodeType!==1||!h&&o&&n=="attr"&&e.attrFn[r])return d(t,r,s,o,l);var v=(t.nodeName||"").toLowerCase(),m=f[v],g=n!="attr"||s!==!1&&s!==null?n:"removeAttr",y,b,w;m||(m=f["*"]),m&&(m=m[r]),m&&(y=m[g]);if(y){r=="value"&&(b=y.isVal,y.isVal=h);if(g==="removeAttr")return y.value.call(t);if(s===i)return y.get?y.get.call(t):y.value;y.set&&(n=="attr"&&s===!0&&(s=r),w=y.set.call(t,s)),r=="value"&&(y.isVal=b)}else w=d(t,r,s,o,l);if((s!==i||g==="removeAttr")&&c[v]&&c[v][r]){var E;g=="removeAttr"?E=!1:g=="prop"?E=!!s:E=!0,c[v][r].forEach(function(e){(!e.only||(e.only=n=="prop")||e.only=="attr"&&n!="prop")&&e.call(t,s,E,h?"val":g,n)})}return w},l[n]=function(r,s,o){f[r]||(f[r]={}),f[r][s]||(f[r][s]={});var a=f[r][s][n],l=function(e,t,r){return t&&t[e]?t[e]:r&&r[e]?r[e]:n=="prop"&&s=="value"?function(e){var t=this;return o.isVal?p(t,s,e,!1,arguments.length===0):u[n](t,s,e)}:n=="prop"&&e=="value"&&o.value.apply?function(e){var t=u[n](this,s);return t&&t.apply&&(t=t.apply(this,arguments)),t}:function(e){return u[n](this,s,e)}};f[r][s][n]=o,o.value===i&&(o.set||(o.set=o.writeable?l("set",o,a):t.cfg.useStrict&&s=="prop"?function(){throw s+" is readonly on "+r}:e.noop),o.get||(o.get=l("get",o,a))),["value","get","set"].forEach(function(e){o[e]&&(o["_sup"+e]=l(e,a))})}});var m=function(){var e=t.getPrototypeOf(r.createElement("foobar")),n=Object.prototype.hasOwnProperty,i=Modernizr.advancedObjectProperties&&Modernizr.objectAccessor;return function(s,o,u){var a,f;if(i&&(a=r.createElement(s))&&(f=t.getPrototypeOf(a))&&e!==f&&(!a[o]||!n.call(a,o))){var l=a[o];u._supvalue=function(){return l&&l.apply?l.apply(this,arguments):l},f[o]=u.value}else u._supvalue=function(){var e=v(this,"propValue");return e&&e[o]&&e[o].apply?e[o].apply(this,arguments):e&&e[o]},g.extendValue(s,o,u.value);u.value._supvalue=u._supvalue}}(),g=function(){var n={};t.addReady(function(r,i){var s={},o=function(t){s[t]||(s[t]=e(r.getElementsByTagName(t)),i[0]&&e.nodeName(i[0],t)&&(s[t]=s[t].add(i)))};e.each(n,function(e,n){o(e);if(!n||!n.forEach){t.warn("Error: with "+e+"-property. methods: "+n);return}n.forEach(function(t){s[e].each(t)})}),s=null});var i,s=e([]),o=function(t,s){n[t]?n[t].push(s):n[t]=[s],e.isDOMReady&&(i||e(r.getElementsByTagName(t))).each(s)},u={};return{createTmpCache:function(t){return e.isDOMReady&&(i=i||e(r.getElementsByTagName(t))),i||s},flushTmpCache:function(){i=null},content:function(t,n){o(t,function(){var t=e.attr(this,n);t!=null&&e.attr(this,n,t)})},createElement:function(e,t){o(e,t)},extendValue:function(t,n,r){o(t,function(){e(this).each(function(){var e=v(this,"propValue",{});e[n]=this[n],this[n]=r})})}}}(),y=function(e,t){e.defaultValue===i&&(e.defaultValue=""),e.removeAttr||(e.removeAttr={value:function(){e[t||"prop"].set.call(this,e.defaultValue),e.removeAttr._supvalue.call(this)}}),e.attr||(e.attr={})};e.extend(t,{getID:function(){var t=(new Date).getTime();return function(n){n=e(n);var r=n.attr("id");return r||(t++,r="ID-"+t,n.attr("id",r)),r}}(),extendUNDEFProp:function(t,n){e.each(n,function(e,n){e in t||(t[e]=n)})},createPropDefault:y,data:v,moveToFirstEvent:function(t,n,r){var i=(e._data(t,"events")||{})[n],s;i&&i.length>1&&(s=i.pop(),r||(r="bind"),r=="bind"&&i.delegateCount?i.splice(i.delegateCount,0,s):i.unshift(s)),t=null},addShadowDom:function(){var i,s,o,u={init:!1,runs:0,test:function(){var e=u.getHeight(),t=u.getWidth();e!=u.height||t!=u.width?(u.height=e,u.width=t,u.handler({type:"docresize"}),u.runs++,u.runs<9&&setTimeout(u.test,90)):u.runs=0},handler:function(t){clearTimeout(i),i=setTimeout(function(){if(t.type=="resize"){var i=e(n).width(),a=e(n).width();if(a==s&&i==o)return;s=a,o=i,u.height=u.getHeight(),u.width=u.getWidth()}e(r).triggerHandler("updateshadowdom")},t.type=="resize"?50:9)},_create:function(){e.each({Height:"getHeight",Width:"getWidth"},function(e,t){var n=r.body,i=r.documentElement;u[t]=function(){return Math.max(n["scroll"+e],i["scroll"+e],n["offset"+e],i["offset"+e],i["client"+e])}})},start:function(){!this.init&&r.body&&(this.init=!0,this._create(),this.height=u.getHeight(),this.width=u.getWidth(),setInterval(this.test,600),e(this.test),t.ready("WINDOWLOAD",this.test),e(n).bind("resize",this.handler),function(){var t=e.fn.animate,n;e.fn.animate=function(){return clearTimeout(n),n=setTimeout(function(){u.test()},99),t.apply(this,arguments)}}())}};return t.docObserve=function(){t.ready("DOM",function(){u.start()})},function(n,r,i){i=i||{},n.jquery&&(n=n[0]),r.jquery&&(r=r[0]);var s=e.data(n,d)||e.data(n,d,{}),o=e.data(r,d)||e.data(r,d,{}),u={};i.shadowFocusElement?i.shadowFocusElement&&(i.shadowFocusElement.jquery&&(i.shadowFocusElement=i.shadowFocusElement[0]),u=e.data(i.shadowFocusElement,d)||e.data(i.shadowFocusElement,d,u)):i.shadowFocusElement=r,s.hasShadow=r,u.nativeElement=o.nativeElement=n,u.shadowData=o.shadowData=s.shadowData={nativeElement:n,shadowElement:r,shadowFocusElement:i.shadowFocusElement},i.shadowChilds&&i.shadowChilds.each(function(){v(this,"shadowData",o.shadowData)}),i.data&&(u.shadowData.data=o.shadowData.data=s.shadowData.data=i.data),i=null,t.docObserve()}}(),propTypes:{standard:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,""+t)},get:function(){return e.attr.get.call(this)||e.defaultValue}}},"boolean":function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){t?e.attr.set.call(this,""):e.removeAttr.value.call(this)},get:function(){return e.attr.get.call(this)!=null}}},src:function(){var t=r.createElement("a");return t.style.display="none",function(n,r){y(n);if(n.prop)return;n.prop={set:function(e){n.attr.set.call(this,e)},get:function(){var n=this.getAttribute(r),i;if(n==null)return"";t.setAttribute("href",n+"");if(!e.support.hrefNormalized){try{e(t).insertAfter(this),i=t.getAttribute("href",4)}catch(s){i=t.getAttribute("href",4)}e(t).detach()}return i||t.href}}}}(),enumarated:function(e,t){y(e);if(e.prop)return;e.prop={set:function(t){e.attr.set.call(this,t)},get:function(){var t=(e.attr.get.call(this)||"").toLowerCase();if(!t||e.limitedTo.indexOf(t)==-1)t=e.defaultValue;return t}}}},reflectProperties:function(n,r){typeof r=="string"&&(r=r.split(o)),r.forEach(function(r){t.defineNodeNamesProperty(n,r,{prop:{set:function(t){e.attr(this,r,t)},get:function(){return e.attr(this,r)||""}}})})},defineNodeNameProperty:function(n,r,i){return a[r]=!0,i.reflect&&t.propTypes[i.propType||"standard"](i,r),["prop","attr","removeAttr"].forEach(function(s){var o=i[s];o&&(s==="prop"?o=e.extend({writeable:!0},o):o=e.extend({},o,{writeable:!0}),l[s](n,r,o),n!="*"&&t.cfg.extendNative&&s=="prop"&&o.value&&e.isFunction(o.value)&&m(n,r,o),i[s]=o)}),i.initAttr&&g.content(n,r),i},defineNodeNameProperties:function(e,n,r,i){var s;for(var o in n)!i&&n[o].initAttr&&g.createTmpCache(e),r&&(n[o][r]||(n[o][r]={},["value","set","get"].forEach(function(e){e in n[o]&&(n[o][r][e]=n[o][e],delete n[o][e])}))),n[o]=t.defineNodeNameProperty(e,o,n[o]);return i||g.flushTmpCache(),n},createElement:function(n,r,i){var s;return e.isFunction(r)&&(r={after:r}),g.createTmpCache(n),r.before&&g.createElement(n,r.before),i&&(s=t.defineNodeNameProperties(n,i,!1,!0)),r.after&&g.createElement(n,r.after),g.flushTmpCache(),s},onNodeNamesPropertyModify:function(t,n,r,i){typeof t=="string"&&(t=t.split(o)),e.isFunction(r)&&(r={set:r}),t.forEach(function(e){c[e]||(c[e]={}),typeof n=="string"&&(n=n.split(o)),r.initAttr&&g.createTmpCache(e),n.forEach(function(t){c[e][t]||(c[e][t]=[],a[t]=!0),r.set&&(i&&(r.set.only=i),c[e][t].push(r.set)),r.initAttr&&g.content(e,t)}),g.flushTmpCache()})},defineNodeNamesBooleanProperty:function(n,r,s){s||(s={}),e.isFunction(s)&&(s.set=s),t.defineNodeNamesProperty(n,r,{attr:{set:function(e){this.setAttribute(r,e),s.set&&s.set.call(this,!0)},get:function(){var e=this.getAttribute(r);return e==null?i:r}},removeAttr:{value:function(){this.removeAttribute(r),s.set&&s.set.call(this,!1)}},reflect:!0,propType:"boolean",initAttr:s.initAttr||!1})},contentAttr:function(e,t,n){if(!e.nodeName)return;var r;if(n===i)return r=e.attributes[t]||{},n=r.specified?r.value:null,n==null?i:n;typeof n=="boolean"?n?e.setAttribute(t,t):e.removeAttribute(t):e.setAttribute(t,n)},activeLang:function(){var n=[],r={},i,o,u=/:\/\/|^\.*\//,a=function(n,r,i){var s;return r&&i&&e.inArray(r,i.availabeLangs||[])!==-1?(n.loading=!0,s=i.langSrc,u.test(s)||(s=t.cfg.basePath+s),t.loader.loadScript(s+r+".js",function(){n.langObj[r]?(n.loading=!1,l(n,!0)):e(function(){n.langObj[r]&&l(n,!0),n.loading=!1})}),!0):!1},f=function(e){r[e]&&r[e].forEach(function(e){e.callback(i,o,"")})},l=function(e,t){if(e.activeLang!=i&&e.activeLang!==o){var n=s[e.module].options;e.langObj[i]||o&&e.langObj[o]?(e.activeLang=i,e.callback(e.langObj[i]||e.langObj[o],i),f(e.module)):!t&&!a(e,i,n)&&!a(e,o,n)&&e.langObj[""]&&e.activeLang!==""&&(e.activeLang="",e.callback(e.langObj[""],i),f(e.module))}},c=function(t){return typeof t=="string"&&t!==i?(i=t,o=i.split("-")[0],i==o&&(o=!1),e.each(n,function(e,t){l(t)})):typeof t=="object"&&(t.register?(r[t.register]||(r[t.register]=[]),r[t.register].push(t),t.callback(i,o,"")):(t.activeLang||(t.activeLang=""),n.push(t),l(t))),i};return c}()}),e.each({defineNodeNamesProperty:"defineNodeNameProperty",defineNodeNamesProperties:"defineNodeNameProperties",createElements:"createElement"},function(e,n){t[e]=function(e,r,i,s){typeof e=="string"&&(e=e.split(o));var u={};return e.forEach(function(e){u[e]=t[n](e,r,i,s)}),u}}),t.isReady("webshimLocalization",!0)}),function(e,t){if(!Modernizr.localstorage||"hidden"in t.createElement("a"))return;var n={article:"article",aside:"complementary",section:"region",nav:"navigation",address:"contentinfo"},r=function(e,t){var n=e.getAttribute("role");n||e.setAttribute("role",t)};e.webshims.addReady(function(i,s){e.each(n,function(t,n){var o=e(t,i).add(s.filter(t));for(var u=0,a=o.length;u<a;u++)r(o[u],n)});if(i===t){var o=t.getElementsByTagName("header")[0],u=t.getElementsByTagName("footer"),a=u.length;o&&!e(o).closest("section, article")[0]&&r(o,"banner");if(!a)return;var f=u[a-1];e(f).closest("section, article")[0]||r(f,"contentinfo")}})}(jQuery,document);
+//DOM-Extension helper
+jQuery.webshims.register('dom-extend', function($, webshims, window, document, undefined){
+ "use strict";
+ //shortcus
+ var modules = webshims.modules;
+ var listReg = /\s*,\s*/;
+
+ //proxying attribute
+ var olds = {};
+ var havePolyfill = {};
+ var extendedProps = {};
+ var extendQ = {};
+ var modifyProps = {};
+
+ var oldVal = $.fn.val;
+ var singleVal = function(elem, name, val, pass, _argless){
+ return (_argless) ? oldVal.call($(elem)) : oldVal.call($(elem), val);
+ };
+ $.fn.val = function(val){
+ var elem = this[0];
+ if(arguments.length && val == null){
+ val = '';
+ }
+ if(!arguments.length){
+ if(!elem || elem.nodeType !== 1){return oldVal.call(this);}
+ return $.prop(elem, 'value', val, 'val', true);
+ }
+ if($.isArray(val)){
+ return oldVal.apply(this, arguments);
+ }
+ var isFunction = $.isFunction(val);
+ return this.each(function(i){
+ elem = this;
+ if(elem.nodeType === 1){
+ if(isFunction){
+ var genVal = val.call( elem, i, $.prop(elem, 'value', undefined, 'val', true));
+ if(genVal == null){
+ genVal = '';
+ }
+ $.prop(elem, 'value', genVal, 'val') ;
+ } else {
+ $.prop(elem, 'value', val, 'val');
+ }
+ }
+ });
+ };
+ $.fn.onTrigger = function(evt, fn){
+ return this.on(evt, fn).each(fn);
+ };
+
+ var dataID = '_webshimsLib'+ (Math.round(Math.random() * 1000));
+ var elementData = function(elem, key, val){
+ elem = elem.jquery ? elem[0] : elem;
+ if(!elem){return val || {};}
+ var data = $.data(elem, dataID);
+ if(val !== undefined){
+ if(!data){