From 7cc7910df63d19e7ebc67bb1156437f0559712d7 Mon Sep 17 00:00:00 2001 From: Lars Henrik Mai Date: Sun, 21 Sep 2014 12:25:47 +0200 Subject: add foundation via bower --- source/bower_components/modernizr/.bower.json | 14 + source/bower_components/modernizr/.editorconfig | 10 + source/bower_components/modernizr/.gitignore | 2 + source/bower_components/modernizr/.travis.yml | 6 + .../modernizr/feature-detects/a-download.js | 8 + .../feature-detects/audio-audiodata-api.js | 4 + .../feature-detects/audio-webaudio-api.js | 4 + .../modernizr/feature-detects/battery-api.js | 8 + .../modernizr/feature-detects/battery-level.js | 11 + .../modernizr/feature-detects/blob-constructor.js | 10 + .../feature-detects/canvas-todataurl-type.js | 28 + .../modernizr/feature-detects/contenteditable.js | 9 + .../feature-detects/contentsecuritypolicy.js | 10 + .../modernizr/feature-detects/contextmenu.js | 11 + .../modernizr/feature-detects/cookies.js | 15 + .../modernizr/feature-detects/cors.js | 3 + .../css-backgroundposition-shorthand.js | 19 + .../feature-detects/css-backgroundposition-xy.js | 15 + .../feature-detects/css-backgroundrepeat.js | 31 + .../feature-detects/css-backgroundsizecover.js | 10 + .../modernizr/feature-detects/css-boxsizing.js | 9 + .../modernizr/feature-detects/css-calc.js | 12 + .../feature-detects/css-cubicbezierrange.js | 8 + .../modernizr/feature-detects/css-displayrunin.js | 18 + .../modernizr/feature-detects/css-displaytable.js | 27 + .../modernizr/feature-detects/css-filters.js | 7 + .../modernizr/feature-detects/css-hyphens.js | 205 + .../modernizr/feature-detects/css-lastchild.js | 11 + .../modernizr/feature-detects/css-mask.js | 12 + .../modernizr/feature-detects/css-mediaqueries.js | 3 + .../modernizr/feature-detects/css-objectfit.js | 6 + .../feature-detects/css-overflow-scrolling.js | 9 + .../modernizr/feature-detects/css-pointerevents.js | 25 + .../feature-detects/css-positionsticky.js | 13 + .../modernizr/feature-detects/css-regions.js | 55 + .../modernizr/feature-detects/css-remunit.js | 19 + .../modernizr/feature-detects/css-resize.js | 8 + .../modernizr/feature-detects/css-scrollbars.js | 19 + .../modernizr/feature-detects/css-shapes.js | 4 + .../modernizr/feature-detects/css-subpixelfont.js | 23 + .../modernizr/feature-detects/css-supports.js | 6 + .../modernizr/feature-detects/css-userselect.js | 10 + .../modernizr/feature-detects/css-vhunit.js | 14 + .../modernizr/feature-detects/css-vmaxunit.js | 14 + .../modernizr/feature-detects/css-vminunit.js | 14 + .../modernizr/feature-detects/css-vwunit.js | 14 + .../feature-detects/custom-protocol-handler.js | 10 + .../modernizr/feature-detects/dart.js | 6 + .../modernizr/feature-detects/dataview-api.js | 4 + .../modernizr/feature-detects/dom-classlist.js | 4 + .../feature-detects/dom-createElement-attrs.js | 11 + .../modernizr/feature-detects/dom-dataset.js | 9 + .../modernizr/feature-detects/dom-microdata.js | 4 + .../modernizr/feature-detects/elem-datalist.js | 12 + .../modernizr/feature-detects/elem-details.js | 25 + .../modernizr/feature-detects/elem-output.js | 4 + .../feature-detects/elem-progress-meter.js | 11 + .../modernizr/feature-detects/elem-ruby.js | 53 + .../modernizr/feature-detects/elem-time.js | 4 + .../modernizr/feature-detects/elem-track.js | 11 + .../modernizr/feature-detects/emoji.js | 11 + .../modernizr/feature-detects/es5-strictmode.js | 7 + .../event-deviceorientation-motion.js | 11 + .../modernizr/feature-detects/exif-orientation.js | 32 + .../modernizr/feature-detects/file-api.js | 12 + .../modernizr/feature-detects/file-filesystem.js | 9 + .../modernizr/feature-detects/forms-fileinput.js | 13 + .../feature-detects/forms-formattribute.js | 29 + .../feature-detects/forms-inputnumber-l10n.js | 32 + .../modernizr/feature-detects/forms-placeholder.js | 10 + .../modernizr/feature-detects/forms-speechinput.js | 19 + .../modernizr/feature-detects/forms-validation.js | 62 + .../modernizr/feature-detects/fullscreen-api.js | 10 + .../modernizr/feature-detects/gamepad.js | 12 + .../modernizr/feature-detects/getusermedia.js | 5 + .../modernizr/feature-detects/ie8compat.js | 12 + .../modernizr/feature-detects/iframe-sandbox.js | 5 + .../modernizr/feature-detects/iframe-seamless.js | 5 + .../modernizr/feature-detects/iframe-srcdoc.js | 5 + .../modernizr/feature-detects/img-apng.js | 26 + .../modernizr/feature-detects/img-webp.js | 20 + .../modernizr/feature-detects/json.js | 7 + .../modernizr/feature-detects/lists-reversed.js | 6 + .../modernizr/feature-detects/mathml.js | 23 + .../feature-detects/network-connection.js | 22 + .../feature-detects/network-eventsource.js | 5 + .../modernizr/feature-detects/network-xhr2.js | 13 + .../modernizr/feature-detects/notification.js | 10 + .../modernizr/feature-detects/performance.js | 5 + .../modernizr/feature-detects/pointerlock-api.js | 4 + .../feature-detects/quota-management-api.js | 11 + .../feature-detects/requestanimationframe.js | 7 + .../modernizr/feature-detects/script-async.js | 3 + .../modernizr/feature-detects/script-defer.js | 3 + .../modernizr/feature-detects/style-scoped.js | 6 + .../modernizr/feature-detects/svg-filters.js | 13 + .../modernizr/feature-detects/unicode.js | 32 + .../modernizr/feature-detects/url-data-uri.js | 26 + .../modernizr/feature-detects/userdata.js | 7 + .../modernizr/feature-detects/vibration.js | 4 + .../modernizr/feature-detects/web-intents.js | 6 + .../modernizr/feature-detects/webgl-extensions.js | 42 + .../modernizr/feature-detects/websockets-binary.js | 20 + .../modernizr/feature-detects/window-framed.js | 8 + .../feature-detects/workers-blobworkers.js | 66 + .../feature-detects/workers-dataworkers.js | 34 + .../feature-detects/workers-sharedworkers.js | 3 + source/bower_components/modernizr/grunt.js | 69 + .../modernizr/media/Modernizr 2 Logo.ai | 291 + .../modernizr/media/Modernizr 2 Logo.eps | Bin 0 -> 350902 bytes .../modernizr/media/Modernizr 2 Logo.pdf | 291 + .../modernizr/media/Modernizr 2 Logo.png | Bin 0 -> 14823 bytes .../modernizr/media/Modernizr 2 Logo.svg | 35 + source/bower_components/modernizr/modernizr.js | 1406 +++ source/bower_components/modernizr/readme.md | 28 + source/bower_components/modernizr/test/basic.html | 65 + .../bower_components/modernizr/test/caniuse.html | 1451 +++ .../test/caniuse_files/Windsong-webfont.eot | Bin 0 -> 40166 bytes .../test/caniuse_files/Windsong-webfont.otf | Bin 0 -> 78680 bytes .../test/caniuse_files/Windsong-webfont.svg | 147 + .../test/caniuse_files/Windsong-webfont.ttf | Bin 0 -> 39936 bytes .../test/caniuse_files/Windsong-webfont.woff | Bin 0 -> 27284 bytes .../modernizr/test/caniuse_files/alpha.png | Bin 0 -> 163 bytes .../modernizr/test/caniuse_files/apng_test.png | Bin 0 -> 195 bytes .../modernizr/test/caniuse_files/before-after.png | Bin 0 -> 452 bytes .../test/caniuse_files/form_validation.html | 15 + .../modernizr/test/caniuse_files/ga.js | 43 + .../modernizr/test/caniuse_files/green5x5.png | Bin 0 -> 72 bytes .../modernizr/test/caniuse_files/hashchange.html | 16 + .../modernizr/test/caniuse_files/jquery.min.js | 18 + .../modernizr/test/caniuse_files/mathml.html | 120 + .../modernizr/test/caniuse_files/mathml_ref.png | Bin 0 -> 3140 bytes .../test/caniuse_files/modernizr-1.7.min.js | 2 + .../test/caniuse_files/png_alpha_result.png | Bin 0 -> 214 bytes .../modernizr/test/caniuse_files/pushstate.html | 40 + .../modernizr/test/caniuse_files/red30x30.png | Bin 0 -> 93 bytes .../modernizr/test/caniuse_files/ruby.png | Bin 0 -> 1339 bytes .../modernizr/test/caniuse_files/stroked-text.png | Bin 0 -> 1291 bytes .../modernizr/test/caniuse_files/style.css | 168 + .../modernizr/test/caniuse_files/svg-html-blur.png | Bin 0 -> 1232 bytes .../modernizr/test/caniuse_files/svg-img.svg | 5 + .../modernizr/test/caniuse_files/svg-img.svg.1 | 5 + .../modernizr/test/caniuse_files/svg_blur.png | Bin 0 -> 3742 bytes .../modernizr/test/caniuse_files/table.png | Bin 0 -> 2519 bytes .../modernizr/test/caniuse_files/text-shadow1.png | Bin 0 -> 796 bytes .../modernizr/test/caniuse_files/text-shadow2.png | Bin 0 -> 1680 bytes .../modernizr/test/caniuse_files/windsong_font.png | Bin 0 -> 1339 bytes .../modernizr/test/caniuse_files/xhtml.html | 14 + source/bower_components/modernizr/test/index.html | 104 + .../bower_components/modernizr/test/js/basic.html | 65 + .../bower_components/modernizr/test/js/dumpdata.js | 75 + .../modernizr/test/js/lib/detect-global.js | 153 + .../modernizr/test/js/lib/jquery-1.7b2.js | 9279 ++++++++++++++++++++ .../modernizr/test/js/lib/jsonselect.js | 279 + .../modernizr/test/js/lib/polyfills.js | 96 + .../modernizr/test/js/lib/uaparser.js | 215 + source/bower_components/modernizr/test/js/setup.js | 44 + .../modernizr/test/js/unit-caniuse.js | 191 + source/bower_components/modernizr/test/js/unit.js | 669 ++ .../modernizr/test/qunit/qunit.css | 231 + .../bower_components/modernizr/test/qunit/qunit.js | 1932 ++++ .../modernizr/test/qunit/run-qunit.js | 72 + 162 files changed, 19328 insertions(+) create mode 100644 source/bower_components/modernizr/.bower.json create mode 100644 source/bower_components/modernizr/.editorconfig create mode 100644 source/bower_components/modernizr/.gitignore create mode 100644 source/bower_components/modernizr/.travis.yml create mode 100644 source/bower_components/modernizr/feature-detects/a-download.js create mode 100644 source/bower_components/modernizr/feature-detects/audio-audiodata-api.js create mode 100644 source/bower_components/modernizr/feature-detects/audio-webaudio-api.js create mode 100644 source/bower_components/modernizr/feature-detects/battery-api.js create mode 100644 source/bower_components/modernizr/feature-detects/battery-level.js create mode 100644 source/bower_components/modernizr/feature-detects/blob-constructor.js create mode 100644 source/bower_components/modernizr/feature-detects/canvas-todataurl-type.js create mode 100644 source/bower_components/modernizr/feature-detects/contenteditable.js create mode 100644 source/bower_components/modernizr/feature-detects/contentsecuritypolicy.js create mode 100644 source/bower_components/modernizr/feature-detects/contextmenu.js create mode 100644 source/bower_components/modernizr/feature-detects/cookies.js create mode 100644 source/bower_components/modernizr/feature-detects/cors.js create mode 100644 source/bower_components/modernizr/feature-detects/css-backgroundposition-shorthand.js create mode 100644 source/bower_components/modernizr/feature-detects/css-backgroundposition-xy.js create mode 100644 source/bower_components/modernizr/feature-detects/css-backgroundrepeat.js create mode 100644 source/bower_components/modernizr/feature-detects/css-backgroundsizecover.js create mode 100644 source/bower_components/modernizr/feature-detects/css-boxsizing.js create mode 100644 source/bower_components/modernizr/feature-detects/css-calc.js create mode 100644 source/bower_components/modernizr/feature-detects/css-cubicbezierrange.js create mode 100644 source/bower_components/modernizr/feature-detects/css-displayrunin.js create mode 100644 source/bower_components/modernizr/feature-detects/css-displaytable.js create mode 100644 source/bower_components/modernizr/feature-detects/css-filters.js create mode 100644 source/bower_components/modernizr/feature-detects/css-hyphens.js create mode 100644 source/bower_components/modernizr/feature-detects/css-lastchild.js create mode 100644 source/bower_components/modernizr/feature-detects/css-mask.js create mode 100644 source/bower_components/modernizr/feature-detects/css-mediaqueries.js create mode 100644 source/bower_components/modernizr/feature-detects/css-objectfit.js create mode 100644 source/bower_components/modernizr/feature-detects/css-overflow-scrolling.js create mode 100644 source/bower_components/modernizr/feature-detects/css-pointerevents.js create mode 100644 source/bower_components/modernizr/feature-detects/css-positionsticky.js create mode 100644 source/bower_components/modernizr/feature-detects/css-regions.js create mode 100644 source/bower_components/modernizr/feature-detects/css-remunit.js create mode 100644 source/bower_components/modernizr/feature-detects/css-resize.js create mode 100644 source/bower_components/modernizr/feature-detects/css-scrollbars.js create mode 100644 source/bower_components/modernizr/feature-detects/css-shapes.js create mode 100644 source/bower_components/modernizr/feature-detects/css-subpixelfont.js create mode 100644 source/bower_components/modernizr/feature-detects/css-supports.js create mode 100644 source/bower_components/modernizr/feature-detects/css-userselect.js create mode 100644 source/bower_components/modernizr/feature-detects/css-vhunit.js create mode 100644 source/bower_components/modernizr/feature-detects/css-vmaxunit.js create mode 100644 source/bower_components/modernizr/feature-detects/css-vminunit.js create mode 100644 source/bower_components/modernizr/feature-detects/css-vwunit.js create mode 100644 source/bower_components/modernizr/feature-detects/custom-protocol-handler.js create mode 100644 source/bower_components/modernizr/feature-detects/dart.js create mode 100644 source/bower_components/modernizr/feature-detects/dataview-api.js create mode 100644 source/bower_components/modernizr/feature-detects/dom-classlist.js create mode 100644 source/bower_components/modernizr/feature-detects/dom-createElement-attrs.js create mode 100644 source/bower_components/modernizr/feature-detects/dom-dataset.js create mode 100644 source/bower_components/modernizr/feature-detects/dom-microdata.js create mode 100644 source/bower_components/modernizr/feature-detects/elem-datalist.js create mode 100644 source/bower_components/modernizr/feature-detects/elem-details.js create mode 100644 source/bower_components/modernizr/feature-detects/elem-output.js create mode 100644 source/bower_components/modernizr/feature-detects/elem-progress-meter.js create mode 100644 source/bower_components/modernizr/feature-detects/elem-ruby.js create mode 100644 source/bower_components/modernizr/feature-detects/elem-time.js create mode 100644 source/bower_components/modernizr/feature-detects/elem-track.js create mode 100644 source/bower_components/modernizr/feature-detects/emoji.js create mode 100644 source/bower_components/modernizr/feature-detects/es5-strictmode.js create mode 100644 source/bower_components/modernizr/feature-detects/event-deviceorientation-motion.js create mode 100644 source/bower_components/modernizr/feature-detects/exif-orientation.js create mode 100644 source/bower_components/modernizr/feature-detects/file-api.js create mode 100644 source/bower_components/modernizr/feature-detects/file-filesystem.js create mode 100644 source/bower_components/modernizr/feature-detects/forms-fileinput.js create mode 100644 source/bower_components/modernizr/feature-detects/forms-formattribute.js create mode 100644 source/bower_components/modernizr/feature-detects/forms-inputnumber-l10n.js create mode 100644 source/bower_components/modernizr/feature-detects/forms-placeholder.js create mode 100644 source/bower_components/modernizr/feature-detects/forms-speechinput.js create mode 100644 source/bower_components/modernizr/feature-detects/forms-validation.js create mode 100644 source/bower_components/modernizr/feature-detects/fullscreen-api.js create mode 100644 source/bower_components/modernizr/feature-detects/gamepad.js create mode 100644 source/bower_components/modernizr/feature-detects/getusermedia.js create mode 100644 source/bower_components/modernizr/feature-detects/ie8compat.js create mode 100644 source/bower_components/modernizr/feature-detects/iframe-sandbox.js create mode 100644 source/bower_components/modernizr/feature-detects/iframe-seamless.js create mode 100644 source/bower_components/modernizr/feature-detects/iframe-srcdoc.js create mode 100644 source/bower_components/modernizr/feature-detects/img-apng.js create mode 100644 source/bower_components/modernizr/feature-detects/img-webp.js create mode 100644 source/bower_components/modernizr/feature-detects/json.js create mode 100644 source/bower_components/modernizr/feature-detects/lists-reversed.js create mode 100644 source/bower_components/modernizr/feature-detects/mathml.js create mode 100644 source/bower_components/modernizr/feature-detects/network-connection.js create mode 100644 source/bower_components/modernizr/feature-detects/network-eventsource.js create mode 100644 source/bower_components/modernizr/feature-detects/network-xhr2.js create mode 100644 source/bower_components/modernizr/feature-detects/notification.js create mode 100644 source/bower_components/modernizr/feature-detects/performance.js create mode 100644 source/bower_components/modernizr/feature-detects/pointerlock-api.js create mode 100644 source/bower_components/modernizr/feature-detects/quota-management-api.js create mode 100644 source/bower_components/modernizr/feature-detects/requestanimationframe.js create mode 100644 source/bower_components/modernizr/feature-detects/script-async.js create mode 100644 source/bower_components/modernizr/feature-detects/script-defer.js create mode 100644 source/bower_components/modernizr/feature-detects/style-scoped.js create mode 100644 source/bower_components/modernizr/feature-detects/svg-filters.js create mode 100644 source/bower_components/modernizr/feature-detects/unicode.js create mode 100644 source/bower_components/modernizr/feature-detects/url-data-uri.js create mode 100644 source/bower_components/modernizr/feature-detects/userdata.js create mode 100644 source/bower_components/modernizr/feature-detects/vibration.js create mode 100644 source/bower_components/modernizr/feature-detects/web-intents.js create mode 100644 source/bower_components/modernizr/feature-detects/webgl-extensions.js create mode 100644 source/bower_components/modernizr/feature-detects/websockets-binary.js create mode 100644 source/bower_components/modernizr/feature-detects/window-framed.js create mode 100644 source/bower_components/modernizr/feature-detects/workers-blobworkers.js create mode 100644 source/bower_components/modernizr/feature-detects/workers-dataworkers.js create mode 100644 source/bower_components/modernizr/feature-detects/workers-sharedworkers.js create mode 100644 source/bower_components/modernizr/grunt.js create mode 100644 source/bower_components/modernizr/media/Modernizr 2 Logo.ai create mode 100644 source/bower_components/modernizr/media/Modernizr 2 Logo.eps create mode 100644 source/bower_components/modernizr/media/Modernizr 2 Logo.pdf create mode 100644 source/bower_components/modernizr/media/Modernizr 2 Logo.png create mode 100644 source/bower_components/modernizr/media/Modernizr 2 Logo.svg create mode 100644 source/bower_components/modernizr/modernizr.js create mode 100644 source/bower_components/modernizr/readme.md create mode 100644 source/bower_components/modernizr/test/basic.html create mode 100644 source/bower_components/modernizr/test/caniuse.html create mode 100644 source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.eot create mode 100644 source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.otf create mode 100644 source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.svg create mode 100644 source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.ttf create mode 100644 source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.woff create mode 100644 source/bower_components/modernizr/test/caniuse_files/alpha.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/apng_test.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/before-after.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/form_validation.html create mode 100644 source/bower_components/modernizr/test/caniuse_files/ga.js create mode 100644 source/bower_components/modernizr/test/caniuse_files/green5x5.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/hashchange.html create mode 100644 source/bower_components/modernizr/test/caniuse_files/jquery.min.js create mode 100644 source/bower_components/modernizr/test/caniuse_files/mathml.html create mode 100644 source/bower_components/modernizr/test/caniuse_files/mathml_ref.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/modernizr-1.7.min.js create mode 100644 source/bower_components/modernizr/test/caniuse_files/png_alpha_result.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/pushstate.html create mode 100644 source/bower_components/modernizr/test/caniuse_files/red30x30.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/ruby.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/stroked-text.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/style.css create mode 100644 source/bower_components/modernizr/test/caniuse_files/svg-html-blur.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/svg-img.svg create mode 100644 source/bower_components/modernizr/test/caniuse_files/svg-img.svg.1 create mode 100644 source/bower_components/modernizr/test/caniuse_files/svg_blur.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/table.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/text-shadow1.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/text-shadow2.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/windsong_font.png create mode 100644 source/bower_components/modernizr/test/caniuse_files/xhtml.html create mode 100644 source/bower_components/modernizr/test/index.html create mode 100644 source/bower_components/modernizr/test/js/basic.html create mode 100644 source/bower_components/modernizr/test/js/dumpdata.js create mode 100644 source/bower_components/modernizr/test/js/lib/detect-global.js create mode 100644 source/bower_components/modernizr/test/js/lib/jquery-1.7b2.js create mode 100644 source/bower_components/modernizr/test/js/lib/jsonselect.js create mode 100644 source/bower_components/modernizr/test/js/lib/polyfills.js create mode 100644 source/bower_components/modernizr/test/js/lib/uaparser.js create mode 100644 source/bower_components/modernizr/test/js/setup.js create mode 100644 source/bower_components/modernizr/test/js/unit-caniuse.js create mode 100644 source/bower_components/modernizr/test/js/unit.js create mode 100644 source/bower_components/modernizr/test/qunit/qunit.css create mode 100644 source/bower_components/modernizr/test/qunit/qunit.js create mode 100644 source/bower_components/modernizr/test/qunit/run-qunit.js (limited to 'source/bower_components/modernizr') diff --git a/source/bower_components/modernizr/.bower.json b/source/bower_components/modernizr/.bower.json new file mode 100644 index 0000000..82c9f4d --- /dev/null +++ b/source/bower_components/modernizr/.bower.json @@ -0,0 +1,14 @@ +{ + "name": "modernizr", + "homepage": "https://github.com/Modernizr/Modernizr", + "version": "2.8.3", + "_release": "2.8.3", + "_resolution": { + "type": "version", + "tag": "v2.8.3", + "commit": "d6bb30c0f12ebb3ddd01e90b0bf435e1c34e6f11" + }, + "_source": "git://github.com/Modernizr/Modernizr.git", + "_target": ">= 2.7.2", + "_originalSource": "modernizr" +} \ No newline at end of file diff --git a/source/bower_components/modernizr/.editorconfig b/source/bower_components/modernizr/.editorconfig new file mode 100644 index 0000000..0f09989 --- /dev/null +++ b/source/bower_components/modernizr/.editorconfig @@ -0,0 +1,10 @@ +# editorconfig.org +root = true + +[*] +indent_style = space +indent_size = 2 +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true diff --git a/source/bower_components/modernizr/.gitignore b/source/bower_components/modernizr/.gitignore new file mode 100644 index 0000000..9c4d3b4 --- /dev/null +++ b/source/bower_components/modernizr/.gitignore @@ -0,0 +1,2 @@ +modernizr.min.js +.DS_Store \ No newline at end of file diff --git a/source/bower_components/modernizr/.travis.yml b/source/bower_components/modernizr/.travis.yml new file mode 100644 index 0000000..1a0d9c0 --- /dev/null +++ b/source/bower_components/modernizr/.travis.yml @@ -0,0 +1,6 @@ +language: node_js +node_js: + - 0.8 +before_script: + - npm install grunt +script: grunt travis --verbose \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/a-download.js b/source/bower_components/modernizr/feature-detects/a-download.js new file mode 100644 index 0000000..559fadd --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/a-download.js @@ -0,0 +1,8 @@ + +// a[download] attribute +// When used on an , this attribute signifies that the resource it +// points to should be downloaded by the browser rather than navigating to it. +// http://developers.whatwg.org/links.html#downloading-resources +// By Addy Osmani + +Modernizr.addTest('adownload', 'download' in document.createElement('a')); diff --git a/source/bower_components/modernizr/feature-detects/audio-audiodata-api.js b/source/bower_components/modernizr/feature-detects/audio-audiodata-api.js new file mode 100644 index 0000000..bfcd9fe --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/audio-audiodata-api.js @@ -0,0 +1,4 @@ +// Mozilla Audio Data API +// https://wiki.mozilla.org/Audio_Data_API +// by Addy Osmani +Modernizr.addTest('audiodata', !!(window.Audio)); diff --git a/source/bower_components/modernizr/feature-detects/audio-webaudio-api.js b/source/bower_components/modernizr/feature-detects/audio-webaudio-api.js new file mode 100644 index 0000000..46d3c63 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/audio-webaudio-api.js @@ -0,0 +1,4 @@ +// Web Audio API +// https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html +// By Addy Osmani +Modernizr.addTest('webaudio', !!(window.webkitAudioContext || window.AudioContext)); diff --git a/source/bower_components/modernizr/feature-detects/battery-api.js b/source/bower_components/modernizr/feature-detects/battery-api.js new file mode 100644 index 0000000..4177e8f --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/battery-api.js @@ -0,0 +1,8 @@ + +// Battery API +// https://developer.mozilla.org/en/DOM/window.navigator.mozBattery +// By: Paul Sayre + +Modernizr.addTest('battery', + !!Modernizr.prefixed('battery', navigator) +); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/battery-level.js b/source/bower_components/modernizr/feature-detects/battery-level.js new file mode 100644 index 0000000..07f9575 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/battery-level.js @@ -0,0 +1,11 @@ + +// Low Battery Level +// Enable a developer to remove CPU intensive CSS/JS when battery is low +// developer.mozilla.org/en/DOM/window.navigator.mozBattery +// By: Paul Sayre + +Modernizr.addTest('lowbattery', function () { + var minLevel = 0.20, + battery = Modernizr.prefixed('battery', navigator); + return !!(battery && !battery.charging && battery.level <= minLevel); +}); diff --git a/source/bower_components/modernizr/feature-detects/blob-constructor.js b/source/bower_components/modernizr/feature-detects/blob-constructor.js new file mode 100644 index 0000000..f10bd7b --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/blob-constructor.js @@ -0,0 +1,10 @@ +// Blob constructor +// http://dev.w3.org/2006/webapi/FileAPI/#constructorBlob + +Modernizr.addTest('blobconstructor', function () { + try { + return !!new Blob(); + } catch (e) { + return false; + } +}); diff --git a/source/bower_components/modernizr/feature-detects/canvas-todataurl-type.js b/source/bower_components/modernizr/feature-detects/canvas-todataurl-type.js new file mode 100644 index 0000000..bf8f2e3 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/canvas-todataurl-type.js @@ -0,0 +1,28 @@ +// canvas.toDataURL type support +// http://www.w3.org/TR/html5/the-canvas-element.html#dom-canvas-todataurl + +// This test is asynchronous. Watch out. + +(function () { + + if (!Modernizr.canvas) { + return false; + } + + var image = new Image(), + canvas = document.createElement('canvas'), + ctx = canvas.getContext('2d'); + + image.onload = function() { + ctx.drawImage(image, 0, 0); + + Modernizr.addTest('todataurljpeg', function() { + return canvas.toDataURL('image/jpeg').indexOf('data:image/jpeg') === 0; + }); + Modernizr.addTest('todataurlwebp', function() { + return canvas.toDataURL('image/webp').indexOf('data:image/webp') === 0; + }); + }; + + image.src = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAACklEQVR4nGMAAQAABQABDQottAAAAABJRU5ErkJggg=='; +}()); diff --git a/source/bower_components/modernizr/feature-detects/contenteditable.js b/source/bower_components/modernizr/feature-detects/contenteditable.js new file mode 100644 index 0000000..6543666 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/contenteditable.js @@ -0,0 +1,9 @@ +// contentEditable +// http://www.whatwg.org/specs/web-apps/current-work/multipage/editing.html#contenteditable + +// this is known to false positive in some mobile browsers +// here is a whitelist of verified working browsers: +// https://github.com/NielsLeenheer/html5test/blob/549f6eac866aa861d9649a0707ff2c0157895706/scripts/engine.js#L2083 + +Modernizr.addTest('contenteditable', + 'contentEditable' in document.documentElement); diff --git a/source/bower_components/modernizr/feature-detects/contentsecuritypolicy.js b/source/bower_components/modernizr/feature-detects/contentsecuritypolicy.js new file mode 100644 index 0000000..a95e45a --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/contentsecuritypolicy.js @@ -0,0 +1,10 @@ +// Test for (experimental) Content Security Policy 1.1 support. +// +// This feature is still quite experimental, but is available now in Chrome 22. +// If the `SecurityPolicy` property is available, you can be sure the browser +// supports CSP. If it's not available, the browser still might support an +// earlier version of the CSP spec. +// +// Editor's Draft: https://dvcs.w3.org/hg/content-security-policy/raw-file/tip/csp-specification.dev.html + +Modernizr.addTest('contentsecuritypolicy', ('securityPolicy' in document || 'SecurityPolicy' in document)); diff --git a/source/bower_components/modernizr/feature-detects/contextmenu.js b/source/bower_components/modernizr/feature-detects/contextmenu.js new file mode 100644 index 0000000..dd8182f --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/contextmenu.js @@ -0,0 +1,11 @@ +// http://www.w3.org/TR/html5/interactive-elements.html#context-menus +// Demo at http://thewebrocks.com/demos/context-menu/ +Modernizr.addTest( + 'contextmenu', + ('contextMenu' in document.documentElement && 'HTMLMenuItemElement' in window) +); + + + + + diff --git a/source/bower_components/modernizr/feature-detects/cookies.js b/source/bower_components/modernizr/feature-detects/cookies.js new file mode 100644 index 0000000..6a2f9d4 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/cookies.js @@ -0,0 +1,15 @@ + +// by tauren +// https://github.com/Modernizr/Modernizr/issues/191 + +Modernizr.addTest('cookies', function () { + // Quick test if browser has cookieEnabled host property + if (navigator.cookieEnabled) return true; + // Create cookie + document.cookie = "cookietest=1"; + var ret = document.cookie.indexOf("cookietest=") != -1; + // Delete cookie + document.cookie = "cookietest=1; expires=Thu, 01-Jan-1970 00:00:01 GMT"; + return ret; +}); + diff --git a/source/bower_components/modernizr/feature-detects/cors.js b/source/bower_components/modernizr/feature-detects/cors.js new file mode 100644 index 0000000..286d717 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/cors.js @@ -0,0 +1,3 @@ +// cors +// By Theodoor van Donge +Modernizr.addTest('cors', !!(window.XMLHttpRequest && 'withCredentials' in new XMLHttpRequest())); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-backgroundposition-shorthand.js b/source/bower_components/modernizr/feature-detects/css-backgroundposition-shorthand.js new file mode 100644 index 0000000..ce016e1 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-backgroundposition-shorthand.js @@ -0,0 +1,19 @@ +/* + https://developer.mozilla.org/en/CSS/background-position + http://www.w3.org/TR/css3-background/#background-position + + Example: http://jsfiddle.net/Blink/bBXvt/ +*/ + +(function() { + + var elem = document.createElement('a'), + eStyle = elem.style, + val = "right 10px bottom 10px"; + + Modernizr.addTest('bgpositionshorthand', function(){ + eStyle.cssText = "background-position: " + val + ";"; + return (eStyle.backgroundPosition === val); + }); + +}()); diff --git a/source/bower_components/modernizr/feature-detects/css-backgroundposition-xy.js b/source/bower_components/modernizr/feature-detects/css-backgroundposition-xy.js new file mode 100644 index 0000000..d52d600 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-backgroundposition-xy.js @@ -0,0 +1,15 @@ +/* + Allan Lei https://github.com/allanlei + + Check adapted from https://github.com/brandonaaron/jquery-cssHooks/blob/master/bgpos.js + + Test: http://jsfiddle.net/allanlei/R8AYS/ +*/ +Modernizr.addTest('bgpositionxy', function() { + return Modernizr.testStyles('#modernizr {background-position: 3px 5px;}', function(elem) { + var cssStyleDeclaration = window.getComputedStyle ? getComputedStyle(elem, null) : elem.currentStyle; + var xSupport = (cssStyleDeclaration.backgroundPositionX == '3px') || (cssStyleDeclaration['background-position-x'] == '3px'); + var ySupport = (cssStyleDeclaration.backgroundPositionY == '5px') || (cssStyleDeclaration['background-position-y'] == '5px'); + return xSupport && ySupport; + }); +}); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-backgroundrepeat.js b/source/bower_components/modernizr/feature-detects/css-backgroundrepeat.js new file mode 100644 index 0000000..365447c --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-backgroundrepeat.js @@ -0,0 +1,31 @@ +// developer.mozilla.org/en/CSS/background-repeat + +// test page: jsbin.com/uzesun/ +// http://jsfiddle.net/ryanseddon/yMLTQ/6/ + +(function(){ + + +function getBgRepeatValue(elem){ + return (window.getComputedStyle ? + getComputedStyle(elem, null).getPropertyValue('background') : + elem.currentStyle['background']); +} + + +Modernizr.testStyles(' #modernizr { background-repeat: round; } ', function(elem, rule){ + + Modernizr.addTest('bgrepeatround', getBgRepeatValue(elem) == 'round'); + +}); + + + +Modernizr.testStyles(' #modernizr { background-repeat: space; } ', function(elem, rule){ + + Modernizr.addTest('bgrepeatspace', getBgRepeatValue(elem) == 'space'); + +}); + + +})(); diff --git a/source/bower_components/modernizr/feature-detects/css-backgroundsizecover.js b/source/bower_components/modernizr/feature-detects/css-backgroundsizecover.js new file mode 100644 index 0000000..dd7e51b --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-backgroundsizecover.js @@ -0,0 +1,10 @@ + +// developer.mozilla.org/en/CSS/background-size + +Modernizr.testStyles( '#modernizr{background-size:cover}', function( elem ) { + var style = window.getComputedStyle ? + window.getComputedStyle( elem, null ) + : elem.currentStyle; + + Modernizr.addTest( 'bgsizecover', style.backgroundSize == 'cover' ); +}); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-boxsizing.js b/source/bower_components/modernizr/feature-detects/css-boxsizing.js new file mode 100644 index 0000000..ab90913 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-boxsizing.js @@ -0,0 +1,9 @@ + +// developer.mozilla.org/en/CSS/box-sizing +// github.com/Modernizr/Modernizr/issues/248 + +Modernizr.addTest("boxsizing",function(){ + return Modernizr.testAllProps("boxSizing") && (document.documentMode === undefined || document.documentMode > 7); +}); + + diff --git a/source/bower_components/modernizr/feature-detects/css-calc.js b/source/bower_components/modernizr/feature-detects/css-calc.js new file mode 100644 index 0000000..bb5b7e9 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-calc.js @@ -0,0 +1,12 @@ +// Method of allowing calculated values for length units, i.e. width: calc(100%-3em) http://caniuse.com/#search=calc +// By @calvein + +Modernizr.addTest('csscalc', function() { + var prop = 'width:'; + var value = 'calc(10px);'; + var el = document.createElement('div'); + + el.style.cssText = prop + Modernizr._prefixes.join(value + prop); + + return !!el.style.length; +}); diff --git a/source/bower_components/modernizr/feature-detects/css-cubicbezierrange.js b/source/bower_components/modernizr/feature-detects/css-cubicbezierrange.js new file mode 100644 index 0000000..28e72aa --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-cubicbezierrange.js @@ -0,0 +1,8 @@ +// cubic-bezier values can't be > 1 for Webkit until bug #45761 (https://bugs.webkit.org/show_bug.cgi?id=45761) is fixed +// By @calvein + +Modernizr.addTest('cubicbezierrange', function() { + var el = document.createElement('div'); + el.style.cssText = Modernizr._prefixes.join('transition-timing-function' + ':cubic-bezier(1,0,0,1.1); '); + return !!el.style.length; +}); diff --git a/source/bower_components/modernizr/feature-detects/css-displayrunin.js b/source/bower_components/modernizr/feature-detects/css-displayrunin.js new file mode 100644 index 0000000..01eddb7 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-displayrunin.js @@ -0,0 +1,18 @@ + +// by alanhogan + +// https://github.com/Modernizr/Modernizr/issues/198 +// http://css-tricks.com/596-run-in/ + + + +Modernizr.testStyles(' #modernizr { display: run-in; } ', function(elem, rule){ + + var ret = (window.getComputedStyle ? + getComputedStyle(elem, null).getPropertyValue('display') : + elem.currentStyle['display']); + + Modernizr.addTest('display-runin', ret == 'run-in'); + +}); + diff --git a/source/bower_components/modernizr/feature-detects/css-displaytable.js b/source/bower_components/modernizr/feature-detects/css-displaytable.js new file mode 100644 index 0000000..bc0a67c --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-displaytable.js @@ -0,0 +1,27 @@ +// display: table and table-cell test. (both are tested under one name "table-cell" ) +// By @scottjehl + +// all additional table display values are here: http://pastebin.com/Gk9PeVaQ though Scott has seen some IE false positives with that sort of weak detection. +// more testing neccessary perhaps. + +Modernizr.addTest( "display-table",function(){ + + var doc = window.document, + docElem = doc.documentElement, + parent = doc.createElement( "div" ), + child = doc.createElement( "div" ), + childb = doc.createElement( "div" ), + ret; + + parent.style.cssText = "display: table"; + child.style.cssText = childb.style.cssText = "display: table-cell; padding: 10px"; + + parent.appendChild( child ); + parent.appendChild( childb ); + docElem.insertBefore( parent, docElem.firstChild ); + + ret = child.offsetLeft < childb.offsetLeft; + docElem.removeChild(parent); + return ret; +}); + diff --git a/source/bower_components/modernizr/feature-detects/css-filters.js b/source/bower_components/modernizr/feature-detects/css-filters.js new file mode 100644 index 0000000..aec4fad --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-filters.js @@ -0,0 +1,7 @@ +// https://github.com/Modernizr/Modernizr/issues/615 +// documentMode is needed for false positives in oldIE, please see issue above +Modernizr.addTest('cssfilters', function() { + var el = document.createElement('div'); + el.style.cssText = Modernizr._prefixes.join('filter' + ':blur(2px); '); + return !!el.style.length && ((document.documentMode === undefined || document.documentMode > 9)); +}); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-hyphens.js b/source/bower_components/modernizr/feature-detects/css-hyphens.js new file mode 100644 index 0000000..8215dd5 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-hyphens.js @@ -0,0 +1,205 @@ +/* see http://davidnewton.ca/the-current-state-of-hyphenation-on-the-web + http://davidnewton.ca/demos/hyphenation/test.html + + +There are three tests: + 1. csshyphens - tests hyphens:auto actually adds hyphens to text + 2. softhyphens - tests that ­ does its job + 3. softhyphensfind - tests that in-browser Find functionality still works correctly with ­ + +These tests currently require document.body to be present + +Hyphenation is language specific, sometimes. + See for more details: http://code.google.com/p/hyphenator/source/diff?spec=svn975&r=975&format=side&path=/trunk/Hyphenator.js#sc_svn975_313 + +If loading Hyphenator.js via Modernizr.load, be cautious of issue 158: http://code.google.com/p/hyphenator/issues/detail?id=158 + +More details at https://github.com/Modernizr/Modernizr/issues/312 + +*/ + +(function() { + + if (!document.body){ + window.console && console.warn('document.body doesn\'t exist. Modernizr hyphens test needs it.'); + return; + } + + // functional test of adding hyphens:auto + function test_hyphens_css() { + try { + /* create a div container and a span within that + * these have to be appended to document.body, otherwise some browsers can give false negative */ + var div = document.createElement('div'), + span = document.createElement('span'), + divStyle = div.style, + spanHeight = 0, + spanWidth = 0, + result = false, + firstChild = document.body.firstElementChild || document.body.firstChild; + + div.appendChild(span); + span.innerHTML = 'Bacon ipsum dolor sit amet jerky velit in culpa hamburger et. Laborum dolor proident, enim dolore duis commodo et strip steak. Salami anim et, veniam consectetur dolore qui tenderloin jowl velit sirloin. Et ad culpa, fatback cillum jowl ball tip ham hock nulla short ribs pariatur aute. Pig pancetta ham bresaola, ut boudin nostrud commodo flank esse cow tongue culpa. Pork belly bresaola enim pig, ea consectetur nisi. Fugiat officia turkey, ea cow jowl pariatur ullamco proident do laborum velit sausage. Magna biltong sint tri-tip commodo sed bacon, esse proident aliquip. Ullamco ham sint fugiat, velit in enim sed mollit nulla cow ut adipisicing nostrud consectetur. Proident dolore beef ribs, laborum nostrud meatball ea laboris rump cupidatat labore culpa. Shankle minim beef, velit sint cupidatat fugiat tenderloin pig et ball tip. Ut cow fatback salami, bacon ball tip et in shank strip steak bresaola. In ut pork belly sed mollit tri-tip magna culpa veniam, short ribs qui in andouille ham consequat. Dolore bacon t-bone, velit short ribs enim strip steak nulla. Voluptate labore ut, biltong swine irure jerky. Cupidatat excepteur aliquip salami dolore. Ball tip strip steak in pork dolor. Ad in esse biltong. Dolore tenderloin exercitation ad pork loin t-bone, dolore in chicken ball tip qui pig. Ut culpa tongue, sint ribeye dolore ex shank voluptate hamburger. Jowl et tempor, boudin pork chop labore ham hock drumstick consectetur tri-tip elit swine meatball chicken ground round. Proident shankle mollit dolore. Shoulder ut duis t-bone quis reprehenderit. Meatloaf dolore minim strip steak, laboris ea aute bacon beef ribs elit shank in veniam drumstick qui. Ex laboris meatball cow tongue pork belly. Ea ball tip reprehenderit pig, sed fatback boudin dolore flank aliquip laboris eu quis. Beef ribs duis beef, cow corned beef adipisicing commodo nisi deserunt exercitation. Cillum dolor t-bone spare ribs, ham hock est sirloin. Brisket irure meatloaf in, boudin pork belly sirloin ball tip. Sirloin sint irure nisi nostrud aliqua. Nostrud nulla aute, enim officia culpa ham hock. Aliqua reprehenderit dolore sunt nostrud sausage, ea boudin pork loin ut t-bone ham tempor. Tri-tip et pancetta drumstick laborum. Ham hock magna do nostrud in proident. Ex ground round fatback, venison non ribeye in.'; + + document.body.insertBefore(div, firstChild); + + /* get size of unhyphenated text */ + divStyle.cssText = 'position:absolute;top:0;left:0;width:5em;text-align:justify;text-justification:newspaper;'; + spanHeight = span.offsetHeight; + spanWidth = span.offsetWidth; + + /* compare size with hyphenated text */ + divStyle.cssText = 'position:absolute;top:0;left:0;width:5em;text-align:justify;'+ + 'text-justification:newspaper;'+ + Modernizr._prefixes.join('hyphens:auto; '); + + result = (span.offsetHeight != spanHeight || span.offsetWidth != spanWidth); + + /* results and cleanup */ + document.body.removeChild(div); + div.removeChild(span); + + return result; + } catch(e) { + return false; + } + } + + // for the softhyphens test + function test_hyphens(delimiter, testWidth) { + try { + /* create a div container and a span within that + * these have to be appended to document.body, otherwise some browsers can give false negative */ + var div = document.createElement('div'), + span = document.createElement('span'), + divStyle = div.style, + spanSize = 0, + result = false, + result1 = false, + result2 = false, + firstChild = document.body.firstElementChild || document.body.firstChild; + + divStyle.cssText = 'position:absolute;top:0;left:0;overflow:visible;width:1.25em;'; + div.appendChild(span); + document.body.insertBefore(div, firstChild); + + + /* get height of unwrapped text */ + span.innerHTML = 'mm'; + spanSize = span.offsetHeight; + + /* compare height w/ delimiter, to see if it wraps to new line */ + span.innerHTML = 'm' + delimiter + 'm'; + result1 = (span.offsetHeight > spanSize); + + /* if we're testing the width too (i.e. for soft-hyphen, not zws), + * this is because tested Blackberry devices will wrap the text but not display the hyphen */ + if (testWidth) { + /* get width of wrapped, non-hyphenated text */ + span.innerHTML = 'm
m'; + spanSize = span.offsetWidth; + + /* compare width w/ wrapped w/ delimiter to see if hyphen is present */ + span.innerHTML = 'm' + delimiter + 'm'; + result2 = (span.offsetWidth > spanSize); + } else { + result2 = true; + } + + /* results and cleanup */ + if (result1 === true && result2 === true) { result = true; } + document.body.removeChild(div); + div.removeChild(span); + + return result; + } catch(e) { + return false; + } + } + + // testing if in-browser Find functionality will work on hyphenated text + function test_hyphens_find(delimiter) { + try { + /* create a dummy input for resetting selection location, and a div container + * these have to be appended to document.body, otherwise some browsers can give false negative + * div container gets the doubled testword, separated by the delimiter + * Note: giving a width to div gives false positive in iOS Safari */ + var dummy = document.createElement('input'), + div = document.createElement('div'), + testword = 'lebowski', + result = false, + textrange, + firstChild = document.body.firstElementChild || document.body.firstChild; + + div.innerHTML = testword + delimiter + testword; + + document.body.insertBefore(div, firstChild); + document.body.insertBefore(dummy, div); + + + /* reset the selection to the dummy input element, i.e. BEFORE the div container + * stackoverflow.com/questions/499126/jquery-set-cursor-position-in-text-area */ + if (dummy.setSelectionRange) { + dummy.focus(); + dummy.setSelectionRange(0,0); + } else if (dummy.createTextRange) { + textrange = dummy.createTextRange(); + textrange.collapse(true); + textrange.moveEnd('character', 0); + textrange.moveStart('character', 0); + textrange.select(); + } + + /* try to find the doubled testword, without the delimiter */ + if (window.find) { + result = window.find(testword + testword); + } else { + try { + textrange = window.self.document.body.createTextRange(); + result = textrange.findText(testword + testword); + } catch(e) { + result = false; + } + } + + document.body.removeChild(div); + document.body.removeChild(dummy); + + return result; + } catch(e) { + return false; + } + } + + Modernizr.addTest("csshyphens", function() { + + if (!Modernizr.testAllProps('hyphens')) return false; + + /* Chrome lies about its hyphens support so we need a more robust test + crbug.com/107111 + */ + try { + return test_hyphens_css(); + } catch(e) { + return false; + } + }); + + Modernizr.addTest("softhyphens", function() { + try { + // use numeric entity instead of ­ in case it's XHTML + return test_hyphens('­', true) && test_hyphens('​', false); + } catch(e) { + return false; + } + }); + + Modernizr.addTest("softhyphensfind", function() { + try { + return test_hyphens_find('­') && test_hyphens_find('​'); + } catch(e) { + return false; + } + }); + +})(); diff --git a/source/bower_components/modernizr/feature-detects/css-lastchild.js b/source/bower_components/modernizr/feature-detects/css-lastchild.js new file mode 100644 index 0000000..3e51516 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-lastchild.js @@ -0,0 +1,11 @@ +// last-child pseudo selector +// https://github.com/Modernizr/Modernizr/pull/304 + + +Modernizr.addTest('lastchild', function(){ + + return Modernizr.testStyles("#modernizr div {width:100px} #modernizr :last-child{width:200px;display:block}", function (elem) { + return elem.lastChild.offsetWidth > elem.firstChild.offsetWidth; + }, 2); + +}); diff --git a/source/bower_components/modernizr/feature-detects/css-mask.js b/source/bower_components/modernizr/feature-detects/css-mask.js new file mode 100644 index 0000000..2f6f28a --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-mask.js @@ -0,0 +1,12 @@ +// this tests passes for webkit's proprietary `-webkit-mask` feature +// www.webkit.org/blog/181/css-masks/ +// developer.apple.com/library/safari/#documentation/InternetWeb/Conceptual/SafariVisualEffectsProgGuide/Masks/Masks.html + +// it does not pass mozilla's implementation of `mask` for SVG + +// developer.mozilla.org/en/CSS/mask +// developer.mozilla.org/En/Applying_SVG_effects_to_HTML_content + +// Can combine with clippaths for awesomeness: http://generic.cx/for/webkit/test.html + +Modernizr.addTest('cssmask', Modernizr.testAllProps('maskRepeat')); diff --git a/source/bower_components/modernizr/feature-detects/css-mediaqueries.js b/source/bower_components/modernizr/feature-detects/css-mediaqueries.js new file mode 100644 index 0000000..e0e2c50 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-mediaqueries.js @@ -0,0 +1,3 @@ + + +Modernizr.addTest('mediaqueries', Modernizr.mq('only all')); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-objectfit.js b/source/bower_components/modernizr/feature-detects/css-objectfit.js new file mode 100644 index 0000000..3daecde --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-objectfit.js @@ -0,0 +1,6 @@ + +// dev.opera.com/articles/view/css3-object-fit-object-position/ + +Modernizr.addTest('object-fit', + !!Modernizr.prefixed('objectFit') +); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-overflow-scrolling.js b/source/bower_components/modernizr/feature-detects/css-overflow-scrolling.js new file mode 100644 index 0000000..364e71d --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-overflow-scrolling.js @@ -0,0 +1,9 @@ + +// johanbrook.com/browsers/native-momentum-scrolling-ios-5/ +// introduced in iOS5b2. Possible API may change... + +Modernizr.addTest("overflowscrolling",function(){ + return Modernizr.testAllProps("overflowScrolling"); +}); + + diff --git a/source/bower_components/modernizr/feature-detects/css-pointerevents.js b/source/bower_components/modernizr/feature-detects/css-pointerevents.js new file mode 100644 index 0000000..f18a5c1 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-pointerevents.js @@ -0,0 +1,25 @@ + +// developer.mozilla.org/en/CSS/pointer-events + +// Test and project pages: +// ausi.github.com/Feature-detection-technique-for-pointer-events/ +// github.com/ausi/Feature-detection-technique-for-pointer-events/wiki +// github.com/Modernizr/Modernizr/issues/80 + + +Modernizr.addTest('pointerevents', function(){ + var element = document.createElement('x'), + documentElement = document.documentElement, + getComputedStyle = window.getComputedStyle, + supports; + if(!('pointerEvents' in element.style)){ + return false; + } + element.style.pointerEvents = 'auto'; + element.style.pointerEvents = 'x'; + documentElement.appendChild(element); + supports = getComputedStyle && + getComputedStyle(element, '').pointerEvents === 'auto'; + documentElement.removeChild(element); + return !!supports; +}); diff --git a/source/bower_components/modernizr/feature-detects/css-positionsticky.js b/source/bower_components/modernizr/feature-detects/css-positionsticky.js new file mode 100644 index 0000000..43a19ec --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-positionsticky.js @@ -0,0 +1,13 @@ +// Sticky positioning - constrains an element to be positioned inside the +// intersection of its container box, and the viewport. +Modernizr.addTest('csspositionsticky', function () { + + var prop = 'position:'; + var value = 'sticky'; + var el = document.createElement('modernizr'); + var mStyle = el.style; + + mStyle.cssText = prop + Modernizr._prefixes.join(value + ';' + prop).slice(0, -prop.length); + + return mStyle.position.indexOf(value) !== -1; +}); diff --git a/source/bower_components/modernizr/feature-detects/css-regions.js b/source/bower_components/modernizr/feature-detects/css-regions.js new file mode 100644 index 0000000..c8995c3 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-regions.js @@ -0,0 +1,55 @@ +// CSS Regions +// http://www.w3.org/TR/css3-regions/ +// By: Mihai Balan + +// We start with a CSS parser test then we check page geometry to see if it's affected by regions +// Later we might be able to retire the second part, as WebKit builds with the false positives die out + +Modernizr.addTest('regions', function() { + + /* Get the 'flowFrom' property name available in the browser. Either default or vendor prefixed. + If the property name can't be found we'll get Boolean 'false' and fail quickly */ + var flowFromProperty = Modernizr.prefixed("flowFrom"), + flowIntoProperty = Modernizr.prefixed("flowInto"); + + if (!flowFromProperty || !flowIntoProperty){ + return false; + } + + /* If CSS parsing is there, try to determine if regions actually work. */ + var container = document.createElement('div'), + content = document.createElement('div'), + region = document.createElement('div'), + + /* we create a random, unlikely to be generated flow number to make sure we don't + clash with anything more vanilla, like 'flow', or 'article', or 'f1' */ + flowName = 'modernizr_flow_for_regions_check'; + + /* First create a div with two adjacent divs inside it. The first will be the + content, the second will be the region. To be able to distinguish between the two, + we'll give the region a particular padding */ + content.innerText = 'M'; + container.style.cssText = 'top: 150px; left: 150px; padding: 0px;'; + region.style.cssText = 'width: 50px; height: 50px; padding: 42px;'; + + region.style[flowFromProperty] = flowName; + container.appendChild(content); + container.appendChild(region); + document.documentElement.appendChild(container); + + /* Now compute the bounding client rect, before and after attempting to flow the + content div in the region div. If regions are enabled, the after bounding rect + should reflect the padding of the region div.*/ + var flowedRect, delta, + plainRect = content.getBoundingClientRect(); + + + content.style[flowIntoProperty] = flowName; + flowedRect = content.getBoundingClientRect(); + + delta = flowedRect.left - plainRect.left; + document.documentElement.removeChild(container); + content = region = container = undefined; + + return (delta == 42); +}); diff --git a/source/bower_components/modernizr/feature-detects/css-remunit.js b/source/bower_components/modernizr/feature-detects/css-remunit.js new file mode 100644 index 0000000..38e15b8 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-remunit.js @@ -0,0 +1,19 @@ + +// test by github.com/nsfmc + +// "The 'rem' unit ('root em') is relative to the computed +// value of the 'font-size' value of the root element." +// http://www.w3.org/TR/css3-values/#relative0 +// you can test by checking if the prop was ditched + +// http://snook.ca/archives/html_and_css/font-size-with-rem + +Modernizr.addTest('cssremunit', function(){ + + var div = document.createElement('div'); + try { + div.style.fontSize = '3rem'; + } catch(er){} + return (/rem/).test(div.style.fontSize); + +}); diff --git a/source/bower_components/modernizr/feature-detects/css-resize.js b/source/bower_components/modernizr/feature-detects/css-resize.js new file mode 100644 index 0000000..fff99ba --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-resize.js @@ -0,0 +1,8 @@ + +// Test for CSS 3 UI "resize" property +// http://www.w3.org/TR/css3-ui/#resize +// https://developer.mozilla.org/en/CSS/resize + +Modernizr.addTest('cssresize', Modernizr.testAllProps('resize')); + + diff --git a/source/bower_components/modernizr/feature-detects/css-scrollbars.js b/source/bower_components/modernizr/feature-detects/css-scrollbars.js new file mode 100644 index 0000000..f26de9f --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-scrollbars.js @@ -0,0 +1,19 @@ +// Stylable scrollbars detection +Modernizr.addTest('cssscrollbar', function() { + + var bool, + + styles = "#modernizr{overflow: scroll; width: 40px }#" + + Modernizr._prefixes + .join("scrollbar{width:0px}"+' #modernizr::') + .split('#') + .slice(1) + .join('#') + "scrollbar{width:0px}"; + + Modernizr.testStyles(styles, function(node) { + bool = 'scrollWidth' in node && node.scrollWidth == 40; + }); + + return bool; + +}); diff --git a/source/bower_components/modernizr/feature-detects/css-shapes.js b/source/bower_components/modernizr/feature-detects/css-shapes.js new file mode 100644 index 0000000..2801165 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-shapes.js @@ -0,0 +1,4 @@ + +// http://html.adobe.com/webplatform/layout/shapes + +Modernizr.addTest('shapes', Modernizr.testAllProps('shapeOutside', 'content-box', true)); diff --git a/source/bower_components/modernizr/feature-detects/css-subpixelfont.js b/source/bower_components/modernizr/feature-detects/css-subpixelfont.js new file mode 100644 index 0000000..57a11b0 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-subpixelfont.js @@ -0,0 +1,23 @@ +/* + * Test for SubPixel Font Rendering + * (to infer if GDI or DirectWrite is used on Windows) + * Authors: @derSchepp, @gerritvanaaken, @rodneyrehm, @yatil, @ryanseddon + * Web: https://github.com/gerritvanaaken/subpixeldetect + */ +Modernizr.addTest('subpixelfont', function() { + var bool, + styles = "#modernizr{position: absolute; top: -10em; visibility:hidden; font: normal 10px arial;}#subpixel{float: left; font-size: 33.3333%;}"; + + // see https://github.com/Modernizr/Modernizr/blob/master/modernizr.js#L97 + Modernizr.testStyles(styles, function(elem) { + var subpixel = elem.firstChild; + + subpixel.innerHTML = 'This is a text written in Arial'; + + bool = window.getComputedStyle ? + window.getComputedStyle(subpixel, null).getPropertyValue("width") !== '44px' + : false; + }, 1, ['subpixel']); + + return bool; +}); diff --git a/source/bower_components/modernizr/feature-detects/css-supports.js b/source/bower_components/modernizr/feature-detects/css-supports.js new file mode 100644 index 0000000..24d26d4 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-supports.js @@ -0,0 +1,6 @@ +// http://dev.w3.org/csswg/css3-conditional/#at-supports +// github.com/Modernizr/Modernizr/issues/648 +// Relies on the fact that a browser vendor should expose the CSSSupportsRule interface +// http://dev.w3.org/csswg/css3-conditional/#the-csssupportsrule-interface + +Modernizr.addTest("supports","CSSSupportsRule" in window); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-userselect.js b/source/bower_components/modernizr/feature-detects/css-userselect.js new file mode 100644 index 0000000..062ee90 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-userselect.js @@ -0,0 +1,10 @@ +// -moz-user-select:none test. + +// by ryan seddon +//https://github.com/Modernizr/Modernizr/issues/250 + + +Modernizr.addTest("userselect",function(){ + return Modernizr.testAllProps("user-select"); +}); + diff --git a/source/bower_components/modernizr/feature-detects/css-vhunit.js b/source/bower_components/modernizr/feature-detects/css-vhunit.js new file mode 100644 index 0000000..9de2b64 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-vhunit.js @@ -0,0 +1,14 @@ +// https://github.com/Modernizr/Modernizr/issues/572 +// Similar to http://jsfiddle.net/FWeinb/etnYC/ +Modernizr.addTest('cssvhunit', function() { + var bool; + Modernizr.testStyles("#modernizr { height: 50vh; }", function(elem, rule) { + var height = parseInt(window.innerHeight/2,10), + compStyle = parseInt((window.getComputedStyle ? + getComputedStyle(elem, null) : + elem.currentStyle)["height"],10); + + bool= (compStyle == height); + }); + return bool; +}); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-vmaxunit.js b/source/bower_components/modernizr/feature-detects/css-vmaxunit.js new file mode 100644 index 0000000..142346b --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-vmaxunit.js @@ -0,0 +1,14 @@ +// https://github.com/Modernizr/Modernizr/issues/572 +// http://jsfiddle.net/glsee/JDsWQ/4/ +Modernizr.addTest('cssvmaxunit', function(){ + var bool; + Modernizr.testStyles("#modernizr { width: 50vmax; }", function(elem, rule) { + var one_vw = window.innerWidth/100, + one_vh = window.innerHeight/100, + compWidth = parseInt((window.getComputedStyle ? + getComputedStyle(elem, null) : + elem.currentStyle)['width'],10); + bool = ( parseInt(Math.max(one_vw, one_vh)*50,10) == compWidth ); + }); + return bool; +}); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/css-vminunit.js b/source/bower_components/modernizr/feature-detects/css-vminunit.js new file mode 100644 index 0000000..e6b9881 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-vminunit.js @@ -0,0 +1,14 @@ +// https://github.com/Modernizr/Modernizr/issues/572 +// http://jsfiddle.net/glsee/JRmdq/8/ +Modernizr.addTest('cssvminunit', function(){ + var bool; + Modernizr.testStyles("#modernizr { width: 50vmin; }", function(elem, rule) { + var one_vw = window.innerWidth/100, + one_vh = window.innerHeight/100, + compWidth = parseInt((window.getComputedStyle ? + getComputedStyle(elem, null) : + elem.currentStyle)['width'],10); + bool = ( parseInt(Math.min(one_vw, one_vh)*50,10) == compWidth ); + }); + return bool; +}); diff --git a/source/bower_components/modernizr/feature-detects/css-vwunit.js b/source/bower_components/modernizr/feature-detects/css-vwunit.js new file mode 100644 index 0000000..28f8ca2 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/css-vwunit.js @@ -0,0 +1,14 @@ +// https://github.com/Modernizr/Modernizr/issues/572 +// http://jsfiddle.net/FWeinb/etnYC/ +Modernizr.addTest('cssvwunit', function(){ + var bool; + Modernizr.testStyles("#modernizr { width: 50vw; }", function(elem, rule) { + var width = parseInt(window.innerWidth/2,10), + compStyle = parseInt((window.getComputedStyle ? + getComputedStyle(elem, null) : + elem.currentStyle)["width"],10); + + bool= (compStyle == width); + }); + return bool; +}); diff --git a/source/bower_components/modernizr/feature-detects/custom-protocol-handler.js b/source/bower_components/modernizr/feature-detects/custom-protocol-handler.js new file mode 100644 index 0000000..2534189 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/custom-protocol-handler.js @@ -0,0 +1,10 @@ +/* + Custom protocol handler support + http://developers.whatwg.org/timers.html#custom-handlers + + Added by @benschwarz +*/ + +Modernizr.addTest('customprotocolhandler', function () { + return !!navigator.registerProtocolHandler; +}); diff --git a/source/bower_components/modernizr/feature-detects/dart.js b/source/bower_components/modernizr/feature-detects/dart.js new file mode 100644 index 0000000..9a8bc82 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/dart.js @@ -0,0 +1,6 @@ +// Dart +// By Theodoor van Donge + +// https://chromiumcodereview.appspot.com/9232049/ + +Modernizr.addTest('dart', !!Modernizr.prefixed('startDart', navigator)); diff --git a/source/bower_components/modernizr/feature-detects/dataview-api.js b/source/bower_components/modernizr/feature-detects/dataview-api.js new file mode 100644 index 0000000..249bfff --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/dataview-api.js @@ -0,0 +1,4 @@ +// DataView +// https://developer.mozilla.org/en/JavaScript_typed_arrays/DataView +// By Addy Osmani +Modernizr.addTest('dataview', (typeof DataView !== 'undefined' && 'getFloat64' in DataView.prototype)); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/dom-classlist.js b/source/bower_components/modernizr/feature-detects/dom-classlist.js new file mode 100644 index 0000000..c227057 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/dom-classlist.js @@ -0,0 +1,4 @@ +// classList +// https://developer.mozilla.org/en/DOM/element.classList +// By Addy Osmani +Modernizr.addTest('classlist', 'classList' in document.documentElement); diff --git a/source/bower_components/modernizr/feature-detects/dom-createElement-attrs.js b/source/bower_components/modernizr/feature-detects/dom-createElement-attrs.js new file mode 100644 index 0000000..d9a3b11 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/dom-createElement-attrs.js @@ -0,0 +1,11 @@ +// by james a rosen. +// https://github.com/Modernizr/Modernizr/issues/258 + +Modernizr.addTest('createelement-attrs', function() { + try { + return document.createElement("").getAttribute('name') == 'test'; + } catch(e) { + return false; + } +}); + diff --git a/source/bower_components/modernizr/feature-detects/dom-dataset.js b/source/bower_components/modernizr/feature-detects/dom-dataset.js new file mode 100644 index 0000000..810ff50 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/dom-dataset.js @@ -0,0 +1,9 @@ + +// dataset API for data-* attributes +// test by @phiggins42 + +Modernizr.addTest('dataset', function(){ + var n = document.createElement("div"); + n.setAttribute("data-a-b", "c"); + return !!(n.dataset && n.dataset.aB === "c"); +}); diff --git a/source/bower_components/modernizr/feature-detects/dom-microdata.js b/source/bower_components/modernizr/feature-detects/dom-microdata.js new file mode 100644 index 0000000..ab0a5d6 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/dom-microdata.js @@ -0,0 +1,4 @@ +// Microdata support +// http://www.w3.org/TR/html5/microdata.html +// By Addy Osmani +Modernizr.addTest('microdata', !!(document['getItems'])); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/elem-datalist.js b/source/bower_components/modernizr/feature-detects/elem-datalist.js new file mode 100644 index 0000000..4bcdc1f --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/elem-datalist.js @@ -0,0 +1,12 @@ + + +// lol. we already have a test for datalist built in! silly you. + + +// Helpful links while you're here, though.. + +// http://css-tricks.com/15346-relevant-dropdowns-polyfill-for-datalist/ +// http://miketaylr.com/test/datalist.html +// http://miketaylr.com/code/datalist.html + +Modernizr.addTest('datalistelem', Modernizr.input.list ); diff --git a/source/bower_components/modernizr/feature-detects/elem-details.js b/source/bower_components/modernizr/feature-detects/elem-details.js new file mode 100644 index 0000000..90501f1 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/elem-details.js @@ -0,0 +1,25 @@ +// By @mathias, based on http://mths.be/axh +Modernizr.addTest('details', function() { + var doc = document, + el = doc.createElement('details'), + fake, + root, + diff; + if (!('open' in el)) { // return early if possible; thanks @aFarkas! + return false; + } + root = doc.body || (function() { + var de = doc.documentElement; + fake = true; + return de.insertBefore(doc.createElement('body'), de.firstElementChild || de.firstChild); + }()); + el.innerHTML = 'ab'; + el.style.display = 'block'; + root.appendChild(el); + diff = el.offsetHeight; + el.open = true; + diff = diff != el.offsetHeight; + root.removeChild(el); + fake && root.parentNode.removeChild(root); + return diff; +}); \ No newline at end of file diff --git a/source/bower_components/modernizr/feature-detects/elem-output.js b/source/bower_components/modernizr/feature-detects/elem-output.js new file mode 100644 index 0000000..54276b2 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/elem-output.js @@ -0,0 +1,4 @@ +// +// http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#the-output-element +// by Addy Osmani +Modernizr.addTest('outputelem', 'value' in document.createElement('output')); diff --git a/source/bower_components/modernizr/feature-detects/elem-progress-meter.js b/source/bower_components/modernizr/feature-detects/elem-progress-meter.js new file mode 100644 index 0000000..cfa4bdf --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/elem-progress-meter.js @@ -0,0 +1,11 @@ +//By Stefan Wallin + +//tests for progressbar-support. All browsers that don't support progressbar returns undefined =) +Modernizr.addTest("progressbar",function(){ + return document.createElement('progress').max !== undefined; +}); + +//tests for meter-support. All browsers that don't support meters returns undefined =) +Modernizr.addTest("meter",function(){ + return document.createElement('meter').max !== undefined; +}); diff --git a/source/bower_components/modernizr/feature-detects/elem-ruby.js b/source/bower_components/modernizr/feature-detects/elem-ruby.js new file mode 100644 index 0000000..dbb978f --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/elem-ruby.js @@ -0,0 +1,53 @@ +// Browser support test for the HTML5 , and elements +// http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-ruby-element +// +// by @alrra + +Modernizr.addTest('ruby', function () { + + var ruby = document.createElement('ruby'), + rt = document.createElement('rt'), + rp = document.createElement('rp'), + docElement = document.documentElement, + displayStyleProperty = 'display', + fontSizeStyleProperty = 'fontSize'; // 'fontSize' - because it`s only used for IE6 and IE7 + + ruby.appendChild(rp); + ruby.appendChild(rt); + docElement.appendChild(ruby); + + // browsers that support hide the via "display:none" + if ( getStyle(rp, displayStyleProperty) == 'none' || // for non-IE browsers + // but in IE browsers has "display:inline" so, the test needs other conditions: + getStyle(ruby, displayStyleProperty) == 'ruby' && getStyle(rt, displayStyleProperty) == 'ruby-text' || // for IE8 & IE9 + getStyle(rp, fontSizeStyleProperty) == '6pt' && getStyle(rt, fontSizeStyleProperty) == '6pt' ) { // for IE6 & IE7 + + cleanUp(); + return true; + + } else { + cleanUp(); + return false; + } + + function getStyle( element, styleProperty ) { + var result; + + if ( window.getComputedStyle ) { // for non-IE browsers + result = document.defaultView.getComputedStyle(element,null).getPropertyValue(styleProperty); + } else if ( element.currentStyle ) { // for IE + result = element.currentStyle[styleProperty]; + } + + return result; + } + + function cleanUp() { + docElement.removeChild(ruby); + // the removed child node still exists in memory, so ... + ruby = null; + rt = null; + rp = null; + } + +}); diff --git a/source/bower_components/modernizr/feature-detects/elem-time.js b/source/bower_components/modernizr/feature-detects/elem-time.js new file mode 100644 index 0000000..fc88606 --- /dev/null +++ b/source/bower_components/modernizr/feature-detects/elem-time.js @@ -0,0 +1,4 @@ +//

The When can I use... test suite... (originally from tests.caniuse.com)

+
+

This is a basic test suite of various web technologies for the When Can I Use website.

+

It is used to quickly test basic support for features in upcoming browsers, rather than any full support of the feature's specification.

+

Results on this page generally match the results as they appear on the When Can I Use site, but may not always due to a variety of circumstances (test may pass but support is actually buggy, not tested well enough, has alternative method, etc).

+ +

Four different types of tests are used:

+
+
Auto
+
Automated JS-based tests. (m) means Modernizr is used.
+ +
Visual
+
Requires visual confirmation/comparison to confirm
+ +
Visual-square
+
Test must create a 30x30px green (lime) square
+ +
Interactive
+
Requires interaction to confirm support
+
+ +

If you are interested in contributing tests you can contact me at: when (at) caniuse (dotcom).

+ +
+ + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Tests
Featurechr13Tests

Toolbar/context menu

[Table] [Single feat]
  + +

Audio element

[Table] [Single feat]
  +

Auto

document.createElement('audio').canPlayType
+ +

Interact

+
Audio element with 6 different sources (with MIME set)
+ +

Interact

+ +
Audio element with 6 different sources (no MIME set)
+ +

CSS3 Background-image options

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "backgroundsize"
+ +

Visual-square

+
+
+
background-clip: content-box;
+ +

Visual-square

+
+
+
background-origin: content-box;
+ +

Visual-square

+
background-size: 30px 30px;
+ +

CSS3 Border images

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "borderimage"
+ +

Visual-square

Separate properties: +border-image-source: url(caniuse_files/green5x5.png); +border-image-slice: 2;
+ +

Visual-square

Shorthand syntax: border-image: url(caniuse_files/green5x5.png) 2;
+ +

CSS3 Border-radius (rounded corners)

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "borderradius"
+ +

Visual-square

+
+
+
+ +

Canvas (basic support)

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "canvas"
+ +

Visual-square

+ +
Draw rect on canvas using fillStyle and fillRect
+ +

classList (DOMTokenList )

[Table] [Single feat]
  +

Auto

"classList" in document.body
+ +

Visual-square

+
+ +

Cross-Origin Resource Sharing

[Table] [Single feat]
  +

Auto

Instant XHR request on page that should permit it.
+ +

CSS3 Animation

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "cssanimations"
+ +

Visual-square

+ +
animation: staylime 60s infinite; + +@keyframes staylime { + from { background-color: lime; } + to { background-color: lime; } + }
+ +

CSS3 Box-shadow

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "boxshadow"
+ +

Visual-square

+
Must be greenish, may not be entirely lime depending on the implementation.
+ +

CSS position:fixed

[Table] [Single feat]
  + +

Interact

Test here
+ +

CSS Gradients

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "cssgradients"
+ +

Visual-square

linear-gradient(lime, lime);
+ +

Visual-square

radial-gradient(lime, lime)
+ +

CSS3 Opacity

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "opacity"
+ +

Visual-square

+
+
+
Test for opacity: 0
+ +

CSS3 Text-shadow

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "textshadow"
+ +

Visual

+ +
A
+ +
font-size: 25px; +color: white; +text-shadow: 25px 0 3px lime; position: relative; +left: -25px;
+ +

Visual

+
A
+
+
Multiple shadow test
+ +

CSS3 Transitions

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "csstransitions"
+ +

Interact

+
+
+

Green square must (briefly) appear on hover

5 second transition from left to right using cubic-bezier(0, 1, 1, 0);
+ +

CSS3 Colors

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "hsla"
+ +

Visual-square

+ +

Visual-square

+ +

dataset & data-* attributes

[Table] [Single feat]
  +

Auto

Test for 'dataset' in document.body and getting the correct value returned from a data-foo attribute.
+ +

Interact

Test here
+ +

Details & Summary elements

[Table] [Single feat]
  +

Auto

+ +

Interact

+ (summary button) +

(detail contents)

+

"(detail contents)" should be visible ONLY after clicking summary

Basic details element with summary and paragraph as children.
+ +

Server-sent DOM events

[Table] [Single feat]
  +

Auto

+ +

File API

[Table] [Single feat]
  +

Auto

+ +

Flexible Box Layout Module

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "flexbox"
+ +

@font-face Web fonts

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "fontface"
+ +

Geolocation

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "geolocation"
+ +

Auto

Test for getCurrentPosition, watchPosition and clearWatch in navigator.geolocation
+ +

Interact

+

Must provide LAT and LON info (may need to give permission first)

Test for navigator.geolocation.getCurrentPosition on which position.coords.latitude and position.coords.longitude are expected.
+ +

getElementsByClassName

[Table] [Single feat]
  +

Auto

+ +

Visual-square

+
+
+
+
+
+
Test if two divs were correctly retrieved using getElementsByClassName
+ +

Hashchange event

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "hashchange"
+ +

Visual-square

iframe with addEventListener('hashchange', function() { + document.body.style.background = 'lime'; +}, false); +
+ +

Session history management

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "history"
+ +

Auto

Test if history.pushState was successful
+ +

IndexedDB

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "indexeddb"
+ +

JSON parsing

[Table] [Single feat]
  +

Auto

+ +

Auto

Create a JS object, convert to JSON string, convert back to object and compare.
+ +

CSS3 Multiple backgrounds

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "multiplebgs"
+ +

Visual-square

background-repeat: repeat-x; +background-image: url(caniuse_files/green5x5.png), url(caniuse_files/green5x5.png), url(caniuse_files/green5x5.png), url(caniuse_files/green5x5.png), url(caniuse_files/green5x5.png), url(caniuse_files/green5x5.png); +background-position: 0 0, 0 5px, 0 10px, 0 15px, 0 20px, 0 25px;
+ +

CSS3 Multiple column layout

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "csscolumns"
+ +

Visual-square

+
+
+
+
column-width: 15px; +column-gap: 0;
+ +

Web Storage - name/value pairs

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "localstorage"
+ +

Auto

Test if getItem, setItem and removeItem work.
+ +

Web Notifications

[Table] [Single feat]
  +

Auto

+ +

Offline web applications

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "applicationcache"
+ +

querySelector/querySelectorAll

[Table] [Single feat]
  +

Auto

+ +

Auto

+
+
+
+
+
querySelector test on selector '[data-foo=bar] + *'
+ +

Auto

+
+
+
+
+
querySelectorAll test on selector '[data-foo=bar] + *'
+ +

SVG (basic support)

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "svg"
+ +

Visual-square

SVG fail +
SVG in <object>
+ +

SVG effects for HTML

[Table] [Single feat]
  + +

Visual

SVG fail +

Text must appear blurry

SVG with feGaussianBlur filter on foreignObject
+ +

Inline SVG in HTML5

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "inlinesvg"
+ +

Visual-square

+ + +
+ +

SVG SMIL animation

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "smil"
+ +

Visual-square

SVG fail +
SVG with animate element inside a rect
+ +

Touch events

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "touch"
+ +

CSS3 Transforms

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "csstransforms"
+ +

Visual-square

+
+
+
transform: translate(30px);
+ +

CSS3 3D Transforms

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "csstransforms3d"
+ +

Visual-square

+
+
+
Parent: +perspective: 600; +perspective-origin: 0 200px; + +Child: + +transform: translate3d(-234px, 0, 0) rotate3d(0, 1, 0, -70deg);
+ +

Video element

[Table] [Single feat]
  +

Auto

+ +

Interact

Video with controls and all three formats available.
+ +

Interact

Video with controls and all three formats available (with MIME).
+ +

Web Sockets

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "websockets"
+ +

Web Workers

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "webworkers"
+ +

Auto

Create a new Worker using new Worker('worker.js'); + +Then, test postMessage and onmessage event.
+ +

Cross-document messaging

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "postmessage"
+ +

XMLHttpRequest 2

[Table] [Single feat]
  +

Auto

+ +

XHTML served as application/xhtml+xml

[Table] [Single feat]
  +

Auto

+ +

CSS Generated content

[Table] [Single feat]
  +

Visual

+-
Element with CSS: +#gencontent:before { + content: 'A'; +} +#gencontent:after { + content: 'Z'; +}
+ +

CSS Table display

[Table] [Single feat]
  +

Visual

+
+
+
+
topleft
+
topright
+
+
+
bottomleft
+
bottomright
+
+
+

Should be 2x2 table

+ +

HTML5 form features

[Table] [Single feat]
  +

Visual




date/time/range/number widgets

+ +

MathML

[Table] [Single feat]
  +

Visual

+ +

PNG alpha transparency

[Table] [Single feat]
  +

Visual

+ +

Ruby annotation

[Table] [Single feat]
  +

Visual

+
+(bottom1)(top1)(bottom2)(top2) +

Elements should be stacked on top of each other

+ +

SVG filters

[Table] [Single feat]
  +

Visual

+ object SVG not supported + +
+ +

Visual-square

SVG fail +

Must be green (not lime)

SVG with <feColorMatrix type="hueRotate" values="120"/>
+ +

Visual-square

SVG fail +
SVG with <feFlood flood-color="lime"/>
+ +

CSS3 Word-wrap

[Table] [Single feat]
  +

Visual

+
abcdefghijklmnopqrstuvwxyz
+ + +

Text should wrap

+ +

Visual

+ +
abcdefghijklmnopqrstuvwxyz
+

Text should overflow box

+ +

Visual-square

+
abcdefghijklmnop
+
+
word-wrap: break-word;
+ +

calc() as CSS unit value

[Table] [Single feat]
  +

Visual-square

+
+
width: calc(10px + 20px);
+ +

Visual-square

+
+
height: calc(60px - 100%); +width: calc((100% / 2) + 15px - 0.5em); +border-right: calc(0.5em) solid lime;
+ +

CSS Grid Layout

[Table] [Single feat]
  +

Visual-square

+ +
+
+
+
+
+ +
Grid with two columns, two rows and three elements taking up space.
+ +

CSS3 Media Queries

[Table] [Single feat]
  +

Visual-square

+ +
+
+
+
+ +

CSS 2.1 selectors

[Table] [Single feat]
  +

Visual-square

+
+
+
+
Test for child ( > )selector
+ +

Visual-square

+
+
+
Adjacent sibling selector test ( + )
+ +

Visual-square

+
Attribute selector ( [role="none"] )
+ +

CSS3 Box-sizing

[Table] [Single feat]
  +

Visual-square

+
+
+ +

Data URLs

[Table] [Single feat]
  +

Visual-square

div with data URL as background image
+ +

New semantic elements

[Table] [Single feat]
  +

Visual-square

+ +
+
+
+ +
+
+
+ +
section, article, aside, hgroup, header, footer, nav tested for default "block" style.
+ +

CSS inline-block

[Table] [Single feat]
  +

Visual-square

+ +

CSS min/max-width/height

[Table] [Single feat]
  +

Visual-square

+ +

Visual-square

+ +

Visual-square

+ +

Visual-square

+ +

CSS3 object-fit/object-position

[Table] [Single feat]
  +

Visual-square

+ +
+ +
object-fit: contain
+ +

Visual-square

+ +
+ +
+
object-position: 30px 30px;
+ +

rem (root em) units

[Table] [Single feat]
  +

Visual-square

+ A +
span with single character and font-size: 5rem;
+ +

SVG in CSS backgrounds

[Table] [Single feat]
  +

Visual-square

+ +
+ +

SVG in HTML img element

[Table] [Single feat]
  +

Visual-square

+ +

contenteditable attribute (basic support)

[Table] [Single feat]
  +

Interact

+

This element should be editable.

+
Div element with attribute contenteditable="true"
+ +

CSS3 selectors

[Table] [Single feat]
  +

Interact

Test here
+ +

Drag and Drop

[Table] [Single feat]
  +

Interact

Test here
+ +

WAI-ARIA Accessibility features

[Table] [Single feat]
  + +

Text API for Canvas

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "canvastext"
+ +

WebGL - 3D Canvas graphics

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "webgl"
+ +

Visual-square

+ +
+ +

SVG fonts

[Table] [Single feat]
  +

Visual

+

Windsong font

+
+ +

TTF/OTF - TrueType and OpenType font support

[Table] [Single feat]
  +

Visual

+

Windsong font

+
OTF font test
+ +

Visual

+

Windsong font

+
TTF font test
+ +

WOFF - Web Open Font Format

[Table] [Single feat]
  +

Visual

+

Windsong font

+
+ +

Progress & Meter

[Table] [Single feat]
  +

Visual

+fail +fail +

Progress and meter widgets at 50%

+ +

Datalist element

[Table] [Single feat]
  +

Interact

+ + + + +

Show "foo" and "foobar" as options when "f" is entered

+ +

Form validation

[Table] [Single feat]
  +

Interact

Form should show warning and NOT submit

+ +

MPEG-4/H.264 video format

[Table] [Single feat]
  +

Auto

+ +

Interact

Video, no MIME, no type attribute.
+ +

Interact

Video with source element
+ +

Interact

Video with source element and MIME set
+ +

Ogg/Theora video format

[Table] [Single feat]
  +

Auto

+ +

Interact

Video, no MIME, no type attribute.
+ +

Interact

Video with source element and MIME set
+ +

Interact

Video with source element
+ +

WebM/VP8 video format

[Table] [Single feat]
  +

Auto

+ +

Interact

Video, no MIME, no type attribute.
+ +

Interact

Video with source element
+ +

Interact

Video with source element and MIME set
+ +

Animated PNG (APNG) [unoff]

[Table] [Single feat]
  +

Auto

Test for second frame using Canvas element
+ +

Visual

Must animate

+ +

CSS Canvas Drawings [unoff]

[Table] [Single feat]
 -pre- +

Auto

'getCSSCanvasContext' in document
+ +

CSS Reflections [unoff]

[Table] [Single feat]
 -pre- +

Auto (m)

Modernizr test for: "cssreflections"
+ + +

Visual-square

+ +
+
+ +
+ + +

Web SQL Database [unoff]

[Table] [Single feat]
  +

Auto (m)

Modernizr test for: "websqldatabase"
+ +

Stream API [unoff]

[Table] [Single feat]
  +

Auto

Test for "getUserMedia" in navigator object
+ +

CSS Masks [unoff]

[Table] [Single feat]
 -pre- +

Visual

+
+ +
mask-image: url(caniuse_files/alpha.png);
+ +

CSS3 Text-overflow [unoff]

[Table] [Single feat]
  +

Visual

+ +
+abcdefghijklmnopqrstuvwxyz +

Should end with ellipsis

text-overflow: ellipsis;
+ +

CSS text-stroke [unoff]

[Table] [Single feat]
 -pre- +

Visual

+ +
+green stroked text +
text-stroke: 2px lime;
+ +

EOT - Embedded OpenType fonts [unoff]

[Table] [Single feat]
  +

Visual

+

Windsong font

+
+ +

XHTML+SMIL animation [unoff]

[Table] [Single feat]
  + +
+

Most tests by Alexis Deveria, additional contributions by Paul Irish

+ + + \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.eot b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.eot new file mode 100644 index 0000000..768d053 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.eot differ diff --git a/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.otf b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.otf new file mode 100644 index 0000000..369e640 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.otf differ diff --git a/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.svg b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.svg new file mode 100644 index 0000000..b200eb5 --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.svg @@ -0,0 +1,147 @@ + + + + +This is a custom SVG webfont generated by Font Squirrel. +Copyright : Bright Ideas Magazine + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.ttf b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.ttf new file mode 100644 index 0000000..4d34192 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.ttf differ diff --git a/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.woff b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.woff new file mode 100644 index 0000000..1aa47d4 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/Windsong-webfont.woff differ diff --git a/source/bower_components/modernizr/test/caniuse_files/alpha.png b/source/bower_components/modernizr/test/caniuse_files/alpha.png new file mode 100644 index 0000000..b7a0f35 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/alpha.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/apng_test.png b/source/bower_components/modernizr/test/caniuse_files/apng_test.png new file mode 100644 index 0000000..f359d3c Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/apng_test.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/before-after.png b/source/bower_components/modernizr/test/caniuse_files/before-after.png new file mode 100644 index 0000000..7a94c4b Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/before-after.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/form_validation.html b/source/bower_components/modernizr/test/caniuse_files/form_validation.html new file mode 100644 index 0000000..e7a060c --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/form_validation.html @@ -0,0 +1,15 @@ + + + + +
+ + + + +
+ \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/ga.js b/source/bower_components/modernizr/test/caniuse_files/ga.js new file mode 100644 index 0000000..76a01b0 --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/ga.js @@ -0,0 +1,43 @@ +(function(){var k=void 0,aa=encodeURIComponent,l=String,o=Math,ba="push",ca="cookie",p="charAt",q="indexOf",da="getTime",r="toString",t="window",v="length",w="document",x="split",y="location",ea="protocol",fa="href",z="substring",A="join",C="toLowerCase";var ga="_gat",ha="_gaq",ia="4.9.4",ja="_gaUserPrefs",ka="ioo",D="&",E="=",F="__utma=",H="__utmb=",la="__utmc=",ma="__utmk=",I="__utmv=",J="__utmz=",na="__utmx=",oa="GASO=";var pa=function(){var d=this,f=[],b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_";d.set=function(b){f[b]=!0};d.Sc=function(){for(var d=[],e=0;e=0};b.Xc=function(){return b.Jb("Firefox")&&![].reduce};b.Vc=function(){return L[t][ja]};b.Gc=function(){return L[t].external};b.Hc=function(){return L[t].performance||L[t].webkitPerformance};b.Ic=function(){return L[t].top==L[t]};b.Ya=function(b){var e=L[t]&&L[t].gaGlobal;if(b&&!e)e={},L[t].gaGlobal=e;return e};b.ec=function(b){L[w][y].href=b};b.qb= +function(d){if(!d||!b.Jb("Firefox"))return d;for(var d=d.replace(/\n|\r/g," "),e=0,f=d[v];e-1&&(b=d[q](b,e),b<0&&(b=d[v]),h=d[z](e+f[q](E)+1,b)));return h},xa=function(d){var f=!1,b=0,h,e;if(!M(d)){f= +!0;for(h=0;h-1)}return f},P=function(d,f){var b=aa;return b instanceof Function?f?encodeURI(d):b(d):(K(68),escape(d))},Q=function(d,f){var b=decodeURIComponent,h,d=d[x]("+")[A](" ");if(b instanceof Function)try{h=f?decodeURI(d):b(d)}catch(e){K(17),h=unescape(d)}else K(68),h=unescape(d);return h},R=function(d,f){return d[q](f)>-1}; +function ya(d){if(!d||""==d)return"";for(;d[p](0)[v]>0&&" \n\r\t"[q](d[p](0))>-1;)d=d[z](1);for(;d[p](d[v]-1)[v]>0&&" \n\r\t"[q](d[p](d[v]-1))>-1;)d=d[z](0,d[v]-1);return d}var T=function(d,f){d[ba]||K(94);d[d[v]]=f},za=function(d){var f=1,b=0,h;if(!M(d)){f=0;for(h=d[v]-1;h>=0;h--)b=d.charCodeAt(h),f=(f<<6&268435455)+b+(b<<14),b=f&266338304,f=b!=0?f^b>>21:f}return f},Aa=function(){return o.round(o.random()*2147483647)},Ba=function(){};var Ca=function(d,f){this.ib=d;this.jb=f},Da=function(){function d(b){for(var d=[],b=b[x](","),e,f=0;f0&&(i=i[x]("^")[0]);b=i[x](":");i=b[1];d=parseInt(b[0],10);!j&&d0?h(b):"";m.o&&(c=e.Oc(L[w][ca],a,m.o,c,b),a="2"+a,j=b>0?h(m.s):"");a+=c;a=L.qb(a);a[v]>2E3&&(K(69),a=a[z](0,2E3));j=a+"; path="+m.f+"; "+j+e.hb();if(!V.pb())L[w].cookie=j};e.Oc=function(a,c,d,j,i){var g="",i=i||m.s,j=b([j,e.m+i*1],d),g=N(a,"2"+c,";");if(!M(g))return a=b(f(a,c,d,!0),d),g=g[x](a)[A](""),g=j+g;return j};e.hb=function(){return M(m.b)?"":"domain="+ +m.b+";"}};var Fa=function(d){function f(a){a=ua(a)?a[A]("."):"";return M(a)?"-":a}function b(a,c){var n=[],b;if(!M(a)&&(n=a[x]("."),c))for(b=0;b')}catch(m){e=h.createElement("iframe"),e.name=f}e.height="0";e.width="0";e.style.display="none";e.style.visibility="hidden";var g=h[y], +g=g[ea]+"//"+g.host+"/favicon.ico",g=Ga+"u/post_iframe.html#"+aa(g),a=function(){e.src="";e.parentNode&&e.parentNode.removeChild(e)};ta(L[t],"beforeunload",a);var c=!1,u=0,j=function(){if(!c){try{if(u>9||e.contentWindow[y].host==h[y].host){c=!0;a();var d=L[t],g="beforeunload",n=a;d.removeEventListener?d.removeEventListener(g,n,!1):d.detachEvent&&d.detachEvent("on"+g,n);b&&b();return}}catch(f){}u++;L.setTimeout(j,200)}};ta(e,"load",j);h.body.appendChild(e);e.src=g}else L.setTimeout(function(){d.Ob(f, +b)},100)}};var Ka=function(d){var f=this,b=d,h=new Fa(b),e=null,m=!V.pb(),g=function(){};f.Uc=function(){return"https:"==L[w][y][ea]?"https://ssl.google-analytics.com/__utm.gif":"http://www.google-analytics.com/__utm.gif"};f.A=function(a,c,d,j,i,s){e||(e=new Ja);var n=b.B,O=L[w][y];h.Z(d);var B=h.z()[x](".");if(B[1]<500||j){if(i){var S=(new Date)[da](),X;X=(S-B[3])*(b.Ac/1E3);X>=1&&(B[2]=o.min(o.floor(B[2]*1+X),b.zc),B[3]=S)}if(j||!i||B[2]>=1){!j&&i&&(B[2]=B[2]*1-1);j=B[1]*1+1;B[1]=j;i="utmwv="+ia;S="&utms="+ +j;X="&utmn="+Aa();j=i+"e"+S+X;a=i+S+X+(M(O.hostname)?"":"&utmhn="+P(O.hostname))+(b.L==100?"":"&utmsp="+P(b.L))+a;if(0==n||2==n)O=2==n?g:s||g,m&&e.Bb(b.ga,a,j,O,!0);if(1==n||2==n)c="&utmac="+c,j+=c,a+=c+"&utmcc="+f.Tc(d),V.Ab&&(d="&aip=1",j+=d,a+=d),a+="&utmu="+qa.Sc(),m&&e.Bb(f.Uc(),a,j,s)}}h.$(B[A]("."));h.aa()};f.Tc=function(a){for(var c=[],b=[F,J,I,na],d=h.g(),i,g=0;g0)for(b=0;b0;)d+=a--^c++;return za(d)}};var Z=function(d,f,b,h){function e(a){var c="",c=a[x]("://")[1][C]();R(c,"/")&&(c=c[x]("/")[0]);return c}var m=h,g=this;g.a=d;g.ob=f;g.m=b;g.mb=function(a){var c=g.ua();return new Z.v(N(a,m.Ea+E,D),N(a,m.Ha+E,D),N(a,m.Ja+E,D),g.R(a,m.Ca,"(not set)"),g.R(a,m.Fa,"(not set)"),g.R(a,m.Ia,c&&!M(c.G)?Q(c.G):k),g.R(a,m.Da,k),N(a,m.vc+E,D))};g.nb=function(a){var c=e(a),b;b=a;var d="";b=b[x]("://")[1][C]();R(b,"/")&&(b=b[x]("/")[1],R(b,"?")&&(d=b[x]("?")[0]));b=d;if(R(c,"google")&&(a=a[x]("?")[A](D),R(a,D+ +m.xc+E)&&b==m.wc))return!0;return!1};g.ua=function(){var a,c=g.ob,b,d=m.J;if(!M(c)&&"0"!=c&&R(c,"://")&&!g.nb(c)){a=e(c);for(var i=0;i9?h[z](n+1)*1:0,f++,h=0==h?1:h,a.ra([B,g.m,h,f,e.H()][A](".")),a.sa()}}}}; +Z.v=function(d,f,b,h,e,m,g,a){var c=this;c.q=d;c.Q=f;c.ya=b;c.n=h;c.P=e;c.G=m;c.Gb=g;c.xa=a;c.H=function(){var a=[],b=[["cid",c.q],["csr",c.Q],["gclid",c.ya],["ccn",c.n],["cmd",c.P],["ctr",c.G],["cct",c.Gb],["dclid",c.xa]],d,e;if(c.fb())for(d=0;d0&&b<=a.Ta){var f=P(c),h=P(d);f[v]+h[v]<=64&&(e.r[b]=[c,d,g],e.T(),n=!0)}return n};e.Zb=function(a){if((a=e.r[a])&&1===a[2])return a[1]};e.Yb=function(a){var b=e.r;b[a]&&(delete b[a],e.T())};e.Pc=function(){c.t(8);c.t(9);c.t(11);var a=e.r,b,d;for(d in a)if(b=a[d])c.j(8,d,b[0]),c.j(9,d,b[1]),(b=b[2])&&3!=b&&c.j(11,d,""+b)}};var Na=function(){function d(a,b,c,d){k==g[a]&&(g[a]={});k==g[a][b]&&(g[a][b]=[]);g[a][b][c]=d}function f(a,b,c){if(k!=g[a]&&k!=g[a][b])return g[a][b][c]}function b(a,b){if(k!=g[a]&&k!=g[a][b]){g[a][b]=k;var c=!0,d;for(d=0;d0?b+"00":"0"};b.sb=function(){var d=b.Kc();if(d==k||isNaN(d))return!1;if(d<=0)return!0;if(d>2147483648)return!1; +var a=b.rb;a.t(14);a.ia(14);var c=b.Jc(d);a.j(14,1,c)&&a.ja(14,1,d)&&b.Lc();h&&h.isValidLoadTime!=k&&h.setPageReadyTime();return!1};b.Wa=function(){if(!b.Mc())return!1;if(!L.Ic())return!1;b.sb()&&ta(L[t],"load",b.sb,!1);return!0}};var $=function(){};$.Zc=function(d){var f="gaso=",b=L[w][y].hash;d=b&&1==b[q](f)?N(b,f,D):(b=L[t].name)&&0<=b[q](f)?N(b,f,D):N(d.g(),oa,";");return d};$.ad=function(d,f){var b=(f||"www")+".google.com",b="https://"+b+"/analytics/reporting/overlay_js?gaso="+d+D+Aa(),h="_gasojs",e=L[w].createElement("script");e.type="text/javascript";e.src=b;if(h)e.id=h;(L[w].getElementsByTagName("head")[0]||L[w].getElementsByTagName("body")[0]).appendChild(e)}; +$.load=function(d,f){if(!$.$c){var b=$.Zc(f),h=b&&b.match(/^(?:\|([-0-9a-z.]{1,30})\|)?([-.\w]{10,1200})$/i);if(h)f.Dc(b),f.Ec(),V._gasoDomain=d.b,V._gasoCPath=d.f,$.ad(h[2],h[1]);$.$c=!0}};var Qa=function(d,f,b){function h(){if("auto"==j.b){var a=L[w].domain;"www."==a[z](0,4)&&(a=a[z](4));j.b=a}j.b=j.b[C]()}function e(){h();var a=j.b,b=a[q]("www.google.")*a[q](".google.")*a[q]("google.");return b||"/"!=j.f||a[q]("google.org")>-1}function m(b,c,d){if(M(b)||M(c)||M(d))return"-";b=N(b,F+a.a+".",c);M(b)||(b=b[x]("."),b[5]=""+(b[5]?b[5]*1+1:1),b[3]=b[4],b[4]=d,b=b[A]("."));return b}function g(){return"file:"!=L[w][y][ea]&&e()}var a=this,c=sa(a),u=k,j=new Da,i=!1,s=k;a.n=d;a.m=o.round((new Date)[da]()/ +1E3);a.p=f||"UA-XXXXX-X";a.ab=L[w].referrer;a.oa=k;a.d=k;a.F=!1;a.O=k;a.e=k;a.bb=k;a.pa=k;a.a=k;a.k=k;j.o=b?P(b):k;a.eb=!1;a.mc=function(){return Aa()^a.O.cc()&2147483647};a.lc=function(){if(!j.b||""==j.b||"none"==j.b)return j.b="",1;h();return j.Ua?za(j.b):1};a.kc=function(a,b){if(M(a))a="-";else{b+=j.f&&"/"!=j.f?j.f:"";var c=a[q](b),a=c>=0&&c<=8?"0":"["==a[p](0)&&"]"==a[p](a[v]-1)?"-":a}return a};a.na=function(b){var c="";c+=j.ka?a.O.dc():"";c+=j.la&&!M(L[w].title)?"&utmdt="+P(L[w].title):"";var d; +d=L.Ya(!0);if(!d.hid)d.hid=Aa();d=d.hid;c+="&utmhid="+d+"&utmr="+P(l(a.oa))+"&utmp="+P(a.pc(b));return c};a.pc=function(a){var b=L[w][y];a&&K(13);return a=k!=a&&""!=a?P(a,!0):P(b.pathname+b.search,!0)};a.uc=function(b){if(a.D()){var c="";a.e!=k&&a.e.C()[v]>0&&(c+="&utme="+P(a.e.C()));c+=a.na(b);u.A(c,a.p,a.a)}};a.jc=function(){var b=new Fa(j);return b.Z(a.a)?b.Tb():k};a.cb=c("_getLinkerUrl",52,function(b,c){var d=b[x]("#"),e=b,f=a.jc();if(f)if(c&&1>=d[v])e+="#"+f;else if(!c||1>=d[v])1>=d[v]?e+=(R(b, +"?")?D:"?")+f:e=d[0]+(R(b,"?")?D:"?")+f+"#"+d[1];return e});a.nc=function(){var b=a.m,c=a.k,d=c.g(),e=a.a+"",f=L.Ya(),g,h=R(d,F+e+"."),i=R(d,H+e),u=R(d,la+e),s,G=[],Y="",Ia=!1,d=M(d)?"":d;if(j.w&&!a.eb){g=L[w][y]&&L[w][y].hash?L[w][y][fa][z](L[w][y][fa][q]("#")):"";j.U&&!M(g)&&(Y=g+D);Y+=L[w][y].search;if(!M(Y)&&R(Y,F))c.Sb(Y),c.Ba()||c.Qb(),s=c.ba(),a.eb=!0;g=c.ea;var va=c.Pa,U=c.Sa;M(g())||(va(Q(g())),R(g(),";")||U());g=c.da;va=c.X;U=c.Y;M(g())||(va(g()),R(g(),";")||U())}M(s)?h?(s=!i||!u)?(s=m(d, +";",l(b)),a.F=!0):(s=N(d,F+e+".",";"),G=N(d,H+e,";")[x](".")):(s=[e,a.mc(),b,b,b,1][A]("."),Ia=a.F=!0):M(c.z())||M(c.ca())?(s=m(Y,D,l(b)),a.F=!0):(G=c.z()[x]("."),e=G[0]);s=s[x](".");L[t]&&f&&f.dh==e&&!j.o&&(s[4]=f.sid?f.sid:s[4],Ia&&(s[3]=f.sid?f.sid:s[4],f.vid&&(b=f.vid[x]("."),s[1]=b[0],s[2]=b[1])));c.Na(s[A]("."));G[0]=e;G[1]=G[1]?G[1]:0;G[2]=k!=G[2]?G[2]:j.Wb;G[3]=G[3]?G[3]:s[4];c.$(G[A]("."));c.Oa(e);M(c.Rb())||c.fa(c.K());c.Qa();c.aa();c.Ra()};a.oc=function(){u=new Ka(j)};a.getName=c("_getName", +58,function(){return a.n});a.c=c("_initData",2,function(){var b;if(!i){if(!a.O)a.O=new La(j.ma);a.a=a.lc();a.k=new Fa(j);a.e=new Na;s=new Ma(j,l(a.a),a.k,a.e);a.oc()}if(g()){if(!i)a.oa=a.kc(a.ab,L[w].domain),b=new Z(l(a.a),a.oa,a.m,j);a.nc(b);s.$b()}if(!i)g()&&b.Pb(a.k,a.F),a.bb=new Na,$.load(j,a.k),i=!0});a.Xa=c("_visitCode",54,function(){a.c();var b=N(a.k.g(),F+a.a+".",";"),b=b[x](".");return b[v]<4?"":b[1]});a.qd=c("_cookiePathCopy",30,function(b){a.c();a.k&&a.k.Ub(a.a,b)});a.D=function(){return a.Xa()% +1E40&&(f=g[z](0,a),g=g[z](a+1));var c=f==ga?V:f==ha?Sa:V.Hb(f);c[g].apply(c,b[e].slice(1))}}catch(u){d++}return d}};var V=new Ra;var Ua=L[t][ga];Ua&&typeof Ua._getTracker=="function"?V=Ua:L[t][ga]=V;var Sa=new Ta;a:{var Va=L[t][ha],Wa=!1;if(Va&&typeof Va[ba]=="function"&&(Wa=ua(Va),!Wa))break a;L[t][ha]=Sa;Wa&&Sa[ba].apply(Sa,Va)};})(); diff --git a/source/bower_components/modernizr/test/caniuse_files/green5x5.png b/source/bower_components/modernizr/test/caniuse_files/green5x5.png new file mode 100644 index 0000000..1825547 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/green5x5.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/hashchange.html b/source/bower_components/modernizr/test/caniuse_files/hashchange.html new file mode 100644 index 0000000..ad95f69 --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/hashchange.html @@ -0,0 +1,16 @@ + + + + + hashchange test + + + + + diff --git a/source/bower_components/modernizr/test/caniuse_files/jquery.min.js b/source/bower_components/modernizr/test/caniuse_files/jquery.min.js new file mode 100644 index 0000000..b2ac174 --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/jquery.min.js @@ -0,0 +1,18 @@ +/*! + * jQuery JavaScript Library v1.6.1 + * http://jquery.com/ + * + * Copyright 2011, John Resig + * Dual licensed under the MIT or GPL Version 2 licenses. + * http://jquery.org/license + * + * Includes Sizzle.js + * http://sizzlejs.com/ + * Copyright 2011, The Dojo Foundation + * Released under the MIT, BSD, and GPL Licenses. + * + * Date: Thu May 12 15:04:36 2011 -0400 + */ +(function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cv(a){if(!cj[a]){var b=f("<"+a+">").appendTo("body"),d=b.css("display");b.remove();if(d==="none"||d===""){ck||(ck=c.createElement("iframe"),ck.frameBorder=ck.width=ck.height=0),c.body.appendChild(ck);if(!cl||!ck.createElement)cl=(ck.contentWindow||ck.contentDocument).document,cl.write("");b=cl.createElement(a),cl.body.appendChild(b),d=f.css(b,"display"),c.body.removeChild(ck)}cj[a]=d}return cj[a]}function cu(a,b){var c={};f.each(cp.concat.apply([],cp.slice(0,b)),function(){c[this]=a});return c}function ct(){cq=b}function cs(){setTimeout(ct,0);return cq=f.now()}function ci(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ch(){try{return new a.XMLHttpRequest}catch(b){}}function cb(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g=0===c})}function W(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function O(a,b){return(a&&a!=="*"?a+".":"")+b.replace(A,"`").replace(B,"&")}function N(a){var b,c,d,e,g,h,i,j,k,l,m,n,o,p=[],q=[],r=f._data(this,"events");if(!(a.liveFired===this||!r||!r.live||a.target.disabled||a.button&&a.type==="click")){a.namespace&&(n=new RegExp("(^|\\.)"+a.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)")),a.liveFired=this;var s=r.live.slice(0);for(i=0;ic)break;a.currentTarget=e.elem,a.data=e.handleObj.data,a.handleObj=e.handleObj,o=e.handleObj.origHandler.apply(e.elem,arguments);if(o===!1||a.isPropagationStopped()){c=e.level,o===!1&&(b=!1);if(a.isImmediatePropagationStopped())break}}return b}}function L(a,c,d){var e=f.extend({},d[0]);e.type=a,e.originalEvent={},e.liveFired=b,f.event.handle.call(c,e),e.isDefaultPrevented()&&d[0].preventDefault()}function F(){return!0}function E(){return!1}function m(a,c,d){var e=c+"defer",g=c+"queue",h=c+"mark",i=f.data(a,e,b,!0);i&&(d==="queue"||!f.data(a,g,b,!0))&&(d==="mark"||!f.data(a,h,b,!0))&&setTimeout(function(){!f.data(a,g,b,!0)&&!f.data(a,h,b,!0)&&(f.removeData(a,e,!0),i.resolve())},0)}function l(a){for(var b in a)if(b!=="toJSON")return!1;return!0}function k(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(j,"$1-$2").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNaN(d)?i.test(d)?f.parseJSON(d):d:parseFloat(d)}catch(g){}f.data(a,c,d)}else d=b}return d}var c=a.document,d=a.navigator,e=a.location,f=function(){function H(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(H,1);return}e.ready()}}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/\d/,n=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,o=/^[\],:{}\s]*$/,p=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,q=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,r=/(?:^|:|,)(?:\s*\[)+/g,s=/(webkit)[ \/]([\w.]+)/,t=/(opera)(?:.*version)?[ \/]([\w.]+)/,u=/(msie) ([\w.]+)/,v=/(mozilla)(?:.*? rv:([\w.]+))?/,w=d.userAgent,x,y,z,A=Object.prototype.toString,B=Object.prototype.hasOwnProperty,C=Array.prototype.push,D=Array.prototype.slice,E=String.prototype.trim,F=Array.prototype.indexOf,G={};e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType){this.context=this[0]=a,this.length=1;return this}if(a==="body"&&!d&&c.body){this.context=c,this[0]=c.body,this.selector=a,this.length=1;return this}if(typeof a=="string"){a.charAt(0)!=="<"||a.charAt(a.length-1)!==">"||a.length<3?g=i.exec(a):g=[null,a,null];if(g&&(g[1]||!d)){if(g[1]){d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=n.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes);return e.merge(this,a)}h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}this.context=c,this.selector=a;return this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}if(e.isFunction(a))return f.ready(a);a.selector!==b&&(this.selector=a.selector,this.context=a.context);return e.makeArray(a,this)},selector:"",jquery:"1.6.1",length:0,size:function(){return this.length},toArray:function(){return D.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();e.isArray(a)?C.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")");return d},each:function(a,b){return e.each(this,a,b)},ready:function(a){e.bindReady(),y.done(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(D.apply(this,arguments),"slice",D.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:C,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j0)return;y.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!y){y=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",z,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",z),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&H()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a&&typeof a=="object"&&"setInterval"in a},isNaN:function(a){return a==null||!m.test(a)||isNaN(a)},type:function(a){return a==null?String(a):G[A.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;if(a.constructor&&!B.call(a,"constructor")&&!B.call(a.constructor.prototype,"isPrototypeOf"))return!1;var c;for(c in a);return c===b||B.call(a,c)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw a},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(o.test(b.replace(p,"@").replace(q,"]").replace(r,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(b,c,d){a.DOMParser?(d=new DOMParser,c=d.parseFromString(b,"text/xml")):(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b)),d=c.documentElement,(!d||!d.nodeName||d.nodeName==="parsererror")&&e.error("Invalid XML: "+b);return c},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i1?h.call(arguments,0):c,--e||g.resolveWith(g,h.call(b,0))}}var b=arguments,c=0,d=b.length,e=d,g=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred();if(d>1){for(;c
a",d=a.getElementsByTagName("*"),e=a.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};f=c.createElement("select"),g=f.appendChild(c.createElement("option")),h=a.getElementsByTagName("input")[0],j={leadingWhitespace:a.firstChild.nodeType===3,tbody:!a.getElementsByTagName("tbody").length,htmlSerialize:!!a.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55$/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:h.value==="on",optSelected:g.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},h.checked=!0,j.noCloneChecked=h.cloneNode(!0).checked,f.disabled=!0,j.optDisabled=!g.disabled;try{delete a.test}catch(s){j.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function b(){j.noCloneEvent=!1,a.detachEvent("onclick",b)}),a.cloneNode(!0).fireEvent("onclick")),h=c.createElement("input"),h.value="t",h.setAttribute("type","radio"),j.radioValue=h.value==="t",h.setAttribute("checked","checked"),a.appendChild(h),k=c.createDocumentFragment(),k.appendChild(a.firstChild),j.checkClone=k.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",l=c.createElement("body"),m={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"};for(q in m)l.style[q]=m[q];l.appendChild(a),b.insertBefore(l,b.firstChild),j.appendChecked=h.checked,j.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,j.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="
",j.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="
t
",n=a.getElementsByTagName("td"),r=n[0].offsetHeight===0,n[0].style.display="",n[1].style.display="none",j.reliableHiddenOffsets=r&&n[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(i=c.createElement("div"),i.style.width="0",i.style.marginRight="0",a.appendChild(i),j.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(i,null)||{marginRight:0}).marginRight,10)||0)===0),l.innerHTML="",b.removeChild(l);if(a.attachEvent)for(q in{submit:1,change:1,focusin:1})p="on"+q,r=p in a,r||(a.setAttribute(p,"return;"),r=typeof a[p]=="function"),j[q+"Bubbles"]=r;return j}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([a-z])([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){a=a.nodeType?f.cache[a[f.expando]]:a[f.expando];return!!a&&!l(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g=f.expando,h=typeof c=="string",i,j=a.nodeType,k=j?f.cache:a,l=j?a[f.expando]:a[f.expando]&&f.expando;if((!l||e&&l&&!k[l][g])&&h&&d===b)return;l||(j?a[f.expando]=l=++f.uuid:l=f.expando),k[l]||(k[l]={},j||(k[l].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?k[l][g]=f.extend(k[l][g],c):k[l]=f.extend(k[l],c);i=k[l],e&&(i[g]||(i[g]={}),i=i[g]),d!==b&&(i[f.camelCase(c)]=d);if(c==="events"&&!i[c])return i[g]&&i[g].events;return h?i[f.camelCase(c)]:i}},removeData:function(b,c,d){if(!!f.acceptData(b)){var e=f.expando,g=b.nodeType,h=g?f.cache:b,i=g?b[f.expando]:f.expando;if(!h[i])return;if(c){var j=d?h[i][e]:h[i];if(j){delete j[c];if(!l(j))return}}if(d){delete h[i][e];if(!l(h[i]))return}var k=h[i][e];f.support.deleteExpando||h!=a?delete h[i]:h[i]=null,k?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=k):g&&(f.support.deleteExpando?delete b[f.expando]:b.removeAttribute?b.removeAttribute(f.expando):b[f.expando]=null)}},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d=null;if(typeof a=="undefined"){if(this.length){d=f.data(this[0]);if(this[0].nodeType===1){var e=this[0].attributes,g;for(var h=0,i=e.length;h-1)return!0;return!1},val:function(a){var c,d,e=this[0];if(!arguments.length){if(e){c=f.valHooks[e.nodeName.toLowerCase()]||f.valHooks[e.type];if(c&&"get"in c&&(d=c.get(e,"value"))!==b)return d;return(e.value||"").replace(p,"")}return b}var g=f.isFunction(a);return this.each(function(d){var e=f(this),h;if(this.nodeType===1){g?h=a.call(this,d,e.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.nodeName.toLowerCase()]||f.valHooks[this.type];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c=a.selectedIndex,d=[],e=a.options,g=a.type==="select-one";if(c<0)return null;for(var h=g?c:0,i=g?c+1:e.length;h=0}),c.length||(a.selectedIndex=-1);return c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attrFix:{tabindex:"tabIndex"},attr:function(a,c,d,e){var g=a.nodeType;if(!a||g===3||g===8||g===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);if(!("getAttribute"in a))return f.prop(a,c,d);var h,i,j=g!==1||!f.isXMLDoc(a);c=j&&f.attrFix[c]||c,i=f.attrHooks[c],i||(!t.test(c)||typeof d!="boolean"&&d!==b&&d.toLowerCase()!==c.toLowerCase()?v&&(f.nodeName(a,"form")||u.test(c))&&(i=v):i=w);if(d!==b){if(d===null){f.removeAttr(a,c);return b}if(i&&"set"in i&&j&&(h=i.set(a,d,c))!==b)return h;a.setAttribute(c,""+d);return d}if(i&&"get"in i&&j)return i.get(a,c);h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){var c;a.nodeType===1&&(b=f.attrFix[b]||b,f.support.getSetAttribute?a.removeAttribute(b):(f.attr(a,b,""),a.removeAttributeNode(a.getAttributeNode(b))),t.test(b)&&(c=f.propFix[b]||b)in a&&(a[c]=!1))},attrHooks:{type:{set:function(a,b){if(q.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.value;a.setAttribute("type",b),c&&(a.value=c);return b}}},tabIndex:{get:function(a){var c=a.getAttributeNode("tabIndex");return c&&c.specified?parseInt(c.value,10):r.test(a.nodeName)||s.test(a.nodeName)&&a.href?0:b}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e=a.nodeType;if(!a||e===3||e===8||e===2)return b;var g,h,i=e!==1||!f.isXMLDoc(a);c=i&&f.propFix[c]||c,h=f.propHooks[c];return d!==b?h&&"set"in h&&(g=h.set(a,d,c))!==b?g:a[c]=d:h&&"get"in h&&(g=h.get(a,c))!==b?g:a[c]},propHooks:{}}),w={get:function(a,c){return a[f.propFix[c]||c]?c.toLowerCase():b},set:function(a,b,c){var d;b===!1?f.removeAttr(a,c):(d=f.propFix[c]||c,d in a&&(a[d]=b),a.setAttribute(c,c.toLowerCase()));return c}},f.attrHooks.value={get:function(a,b){if(v&&f.nodeName(a,"button"))return v.get(a,b);return a.value},set:function(a,b,c){if(v&&f.nodeName(a,"button"))return v.set(a,b,c);a.value=b}},f.support.getSetAttribute||(f.attrFix=f.propFix,v=f.attrHooks.name=f.valHooks.button={get:function(a,c){var d;d=a.getAttributeNode(c);return d&&d.nodeValue!==""?d.nodeValue:b},set:function(a,b,c){var d=a.getAttributeNode(c);if(d){d.nodeValue=b;return b}}},f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c===""){a.setAttribute(b,"auto");return c}}})})),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}})),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var x=Object.prototype.hasOwnProperty,y=/\.(.*)$/,z=/^(?:textarea|input|select)$/i,A=/\./g,B=/ /g,C=/[^\w\s.|`]/g,D=function(a){return a.replace(C,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=E;else if(!d)return;var g,h;d.handler&&(g=d,d=g.handler),d.guid||(d.guid=f.guid++);var i=f._data(a);if(!i)return;var j=i.events,k=i.handle;j||(i.events=j={}),k||(i.handle=k=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.handle.apply(k.elem,arguments):b}),k.elem=a,c=c.split(" ");var l,m=0,n;while(l=c[m++]){h=g?f.extend({},g):{handler:d,data:e},l.indexOf(".")>-1?(n=l.split("."),l=n.shift(),h.namespace=n.slice(0).sort().join(".")):(n=[],h.namespace=""),h.type=l,h.guid||(h.guid=d.guid);var o=j[l],p=f.event.special[l]||{};if(!o){o=j[l]=[];if(!p.setup||p.setup.call(a,e,n,k)===!1)a.addEventListener?a.addEventListener(l,k,!1):a.attachEvent&&a.attachEvent("on"+l,k)}p.add&&(p.add.call(a,h),h.handler.guid||(h.handler.guid=d.guid)),o.push(h),f.event.global[l]=!0}a=null}},global:{},remove:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){d===!1&&(d=E);var g,h,i,j,k=0,l,m,n,o,p,q,r,s=f.hasData(a)&&f._data(a),t=s&&s.events;if(!s||!t)return;c&&c.type&&(d=c.handler,c=c.type);if(!c||typeof c=="string"&&c.charAt(0)==="."){c=c||"";for(h in t)f.event.remove(a,h+c);return}c=c.split(" ");while(h=c[k++]){r=h,q=null,l=h.indexOf(".")<0,m=[],l||(m=h.split("."),h=m.shift(),n=new RegExp("(^|\\.)"+f.map(m.slice(0).sort(),D).join("\\.(?:.*\\.)?")+"(\\.|$)")),p=t[h];if(!p)continue;if(!d){for(j=0;j=0&&(h=h.slice(0,-1),j=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if(!!e&&!f.event.customEvent[h]||!!f.event.global[h]){c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.exclusive=j,c.namespace=i.join("."),c.namespace_re=new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)");if(g||!e)c.preventDefault(),c.stopPropagation();if(!e){f.each(f.cache,function(){var a=f.expando,b=this[a];b&&b.events&&b.events[h]&&f.event.trigger(c,d,b.handle.elem +)});return}if(e.nodeType===3||e.nodeType===8)return;c.result=b,c.target=e,d=d?f.makeArray(d):[],d.unshift(c);var k=e,l=h.indexOf(":")<0?"on"+h:"";do{var m=f._data(k,"handle");c.currentTarget=k,m&&m.apply(k,d),l&&f.acceptData(k)&&k[l]&&k[l].apply(k,d)===!1&&(c.result=!1,c.preventDefault()),k=k.parentNode||k.ownerDocument||k===c.target.ownerDocument&&a}while(k&&!c.isPropagationStopped());if(!c.isDefaultPrevented()){var n,o=f.event.special[h]||{};if((!o._default||o._default.call(e.ownerDocument,c)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)){try{l&&e[h]&&(n=e[l],n&&(e[l]=null),f.event.triggered=h,e[h]())}catch(p){}n&&(e[l]=n),f.event.triggered=b}}return c.result}},handle:function(c){c=f.event.fix(c||a.event);var d=((f._data(this,"events")||{})[c.type]||[]).slice(0),e=!c.exclusive&&!c.namespace,g=Array.prototype.slice.call(arguments,0);g[0]=c,c.currentTarget=this;for(var h=0,i=d.length;h-1?f.map(a.options,function(a){return a.selected}).join("-"):"":f.nodeName(a,"select")&&(c=a.selectedIndex);return c},K=function(c){var d=c.target,e,g;if(!!z.test(d.nodeName)&&!d.readOnly){e=f._data(d,"_change_data"),g=J(d),(c.type!=="focusout"||d.type!=="radio")&&f._data(d,"_change_data",g);if(e===b||g===e)return;if(e!=null||g)c.type="change",c.liveFired=b,f.event.trigger(c,arguments[1],d)}};f.event.special.change={filters:{focusout:K,beforedeactivate:K,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&K.call(this,a)},keydown:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(a.keyCode===13&&!f.nodeName(b,"textarea")||a.keyCode===32&&(c==="checkbox"||c==="radio")||c==="select-multiple")&&K.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",J(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in I)f.event.add(this,c+".specialChange",I[c]);return z.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return z.test(this.nodeName)}},I=f.event.special.change.filters,I.focus=I.beforeactivate}f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){function e(a){var c=f.event.fix(a);c.type=b,c.originalEvent={},f.event.trigger(c,null,c.target),c.isDefaultPrevented()&&a.preventDefault()}var d=0;f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.each(["bind","one"],function(a,c){f.fn[c]=function(a,d,e){var g;if(typeof a=="object"){for(var h in a)this[c](h,d,a[h],e);return this}if(arguments.length===2||d===!1)e=d,d=b;c==="one"?(g=function(a){f(this).unbind(a,g);return e.apply(this,arguments)},g.guid=e.guid||f.guid++):g=e;if(a==="unload"&&c!=="one")this.one(a,d,e);else for(var i=0,j=this.length;i0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0)}),function(){function u(a,b,c,d,e,f){for(var g=0,h=d.length;g0){j=i;break}}i=i[a]}d[g]=j}}}function t(a,b,c,d,e,f){for(var g=0,h=d.length;g+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d=0,e=Object.prototype.toString,g=!1,h=!0,i=/\\/g,j=/\W/;[0,0].sort(function(){h=!1;return 0});var k=function(b,d,f,g){f=f||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return f;var i,j,n,o,q,r,s,t,u=!0,w=k.isXML(d),x=[],y=b;do{a.exec(""),i=a.exec(y);if(i){y=i[3],x.push(i[1]);if(i[2]){o=i[3];break}}}while(i);if(x.length>1&&m.exec(b))if(x.length===2&&l.relative[x[0]])j=v(x[0]+x[1],d);else{j=l.relative[x[0]]?[d]:k(x.shift(),d);while(x.length)b=x.shift(),l.relative[b]&&(b+=x.shift()),j=v(b,j)}else{!g&&x.length>1&&d.nodeType===9&&!w&&l.match.ID.test(x[0])&&!l.match.ID.test(x[x.length-1])&&(q=k.find(x.shift(),d,w),d=q.expr?k.filter(q.expr,q.set)[0]:q.set[0]);if(d){q=g?{expr:x.pop(),set:p(g)}:k.find(x.pop(),x.length===1&&(x[0]==="~"||x[0]==="+")&&d.parentNode?d.parentNode:d,w),j=q.expr?k.filter(q.expr,q.set):q.set,x.length>0?n=p(j):u=!1;while(x.length)r=x.pop(),s=r,l.relative[r]?s=x.pop():r="",s==null&&(s=d),l.relative[r](n,s,w)}else n=x=[]}n||(n=j),n||k.error(r||b);if(e.call(n)==="[object Array]")if(!u)f.push.apply(f,n);else if(d&&d.nodeType===1)for(t=0;n[t]!=null;t++)n[t]&&(n[t]===!0||n[t].nodeType===1&&k.contains(d,n[t]))&&f.push(j[t]);else for(t=0;n[t]!=null;t++)n[t]&&n[t].nodeType===1&&f.push(j[t]);else p(n,f);o&&(k(o,h,f,g),k.uniqueSort(f));return f};k.uniqueSort=function(a){if(r){g=h,a.sort(r);if(g)for(var b=1;b0},k.find=function(a,b,c){var d;if(!a)return[];for(var e=0,f=l.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!j.test(b)){b=b.toLowerCase();for(;e=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(i,"")},TAG:function(a,b){return a[1].replace(i,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||k.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&k.error(a[0]);a[0]=d++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(i,"");!f&&l.attrMap[g]&&(a[1]=l.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(i,""),a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not")if((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))b[3]=k(b[3],null,null,c);else{var g=k.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(l.match.POS.test(b[0])||l.match.CHILD.test(b[0]))return!0;return b},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){a.parentNode&&a.parentNode.selectedIndex;return a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!k(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return bc[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=l.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||k.getText([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=l.attrHandle[c]?l.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=l.setFilters[e];if(f)return f(a,c,b,d)}}},m=l.match.POS,n=function(a,b){return"\\"+(b-0+1)};for(var o in l.match)l.match[o]=new RegExp(l.match[o].source+/(?![^\[]*\])(?![^\(]*\))/.source),l.leftMatch[o]=new RegExp(/(^(?:.|\r|\n)*?)/.source+l.match[o].source.replace(/\\(\d+)/g,n));var p=function(a,b){a=Array.prototype.slice.call(a,0);if(b){b.push.apply(b,a);return b}return a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(q){p=function(a,b){var c=0,d=b||[];if(e.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var f=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(l.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},l.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(l.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(l.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=k,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){k=function(b,e,f,g){e=e||c;if(!g&&!k.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return p(e.getElementsByTagName(b),f);if(h[2]&&l.find.CLASS&&e.getElementsByClassName)return p(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return p([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return p([],f);if(i.id===h[3])return p([i],f)}try{return p(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var m=e,n=e.getAttribute("id"),o=n||d,q=e.parentNode,r=/^\s*[+~]/.test(b);n?o=o.replace(/'/g,"\\$&"):e.setAttribute("id",o),r&&q&&(e=e.parentNode);try{if(!r||q)return p(e.querySelectorAll("[id='"+o+"'] "+b),f)}catch(s){}finally{n||m.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)k[e]=a[e];b=null}}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}k.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!k.isXML(a))try{if(e||!l.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return k(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="
";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;l.order.splice(1,0,"CLASS"),l.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?k.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?k.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:k.contains=function(){return!1},k.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var v=function(a,b){var c,d=[],e="",f=b.nodeType?[b]:b;while(c=l.match.PSEUDO.exec(a))e+=c[0],a=a.replace(l.match.PSEUDO,"");a=l.relative[a]?a+"*":a;for(var g=0,h=f.length;g0)for(h=g;h0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h,i,j={},k=1;if(g&&a.length){for(d=0,e=a.length;d-1:f(g).is(h))&&c.push({selector:i,elem:g,level:k});g=g.parentNode,k++}}return c}var l=U.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}c=c.length>1?f.unique(c):c;return this.pushStack(c,"closest",a)},index:function(a){if(!a||typeof a=="string")return f.inArray(this[0],a?f(a):this.parent().children());return f.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(W(c[0])||W(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling(a.parentNode.firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c),g=T.call(arguments);P.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!V[a]?f.unique(e):e,(this.length>1||R.test(d))&&Q.test(a)&&(e=e.reverse());return this.pushStack(e,a,g.join(","))}}),f.extend({filter:function(a,b,c){c&&(a=":not("+a+")");return b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var Y=/ jQuery\d+="(?:\d+|null)"/g,Z=/^\s+/,$=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,_=/<([\w:]+)/,ba=/",""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]};bg.optgroup=bg.option,bg.tbody=bg.tfoot=bg.colgroup=bg.caption=bg.thead,bg.th=bg.td,f.support.htmlSerialize||(bg._default=[1,"div
","
"]),f.fn.extend({text:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.text(a.call(this,b,c.text()))});if(typeof a!="object"&&a!==b)return this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a));return f.text(this)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapInner(a.call(this,b))});return this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){f(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,f(arguments[0]).toArray());return a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){a=a==null?!1:a,b=b==null?a:b;return this.map(function(){return f.clone(this,a,b)})},html:function(a){if(a===b)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(Y,""):null;if(typeof a=="string"&&!bc.test(a)&&(f.support.leadingWhitespace||!Z.test(a))&&!bg[(_.exec(a)||["",""])[1].toLowerCase()]){a=a.replace($,"<$1>");try{for(var c=0,d=this.length;c1&&l0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d=a.cloneNode(!0),e,g,h;if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bj(a,d),e=bk(a),g=bk(d);for(h=0;e[h];++h)bj(e[h],g[h])}if(b){bi(a,d);if(c){e=bk(a),g=bk(d);for(h=0;e[h];++h)bi(e[h],g[h])}}return d},clean:function(a,b,d,e){var g;b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument|| +b[0]&&b[0].ownerDocument||c);var h=[],i;for(var j=0,k;(k=a[j])!=null;j++){typeof k=="number"&&(k+="");if(!k)continue;if(typeof k=="string")if(!bb.test(k))k=b.createTextNode(k);else{k=k.replace($,"<$1>");var l=(_.exec(k)||["",""])[1].toLowerCase(),m=bg[l]||bg._default,n=m[0],o=b.createElement("div");o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=ba.test(k),q=l==="table"&&!p?o.firstChild&&o.firstChild.childNodes:m[1]===""&&!p?o.childNodes:[];for(i=q.length-1;i>=0;--i)f.nodeName(q[i],"tbody")&&!q[i].childNodes.length&&q[i].parentNode.removeChild(q[i])}!f.support.leadingWhitespace&&Z.test(k)&&o.insertBefore(b.createTextNode(Z.exec(k)[0]),o.firstChild),k=o.childNodes}var r;if(!f.support.appendChecked)if(k[0]&&typeof (r=k.length)=="number")for(i=0;i=0)return b+"px"}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return bp.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle;c.zoom=1;var e=f.isNaN(b)?"":"alpha(opacity="+b*100+")",g=d&&d.filter||c.filter||"";c.filter=bo.test(g)?g.replace(bo,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){var c;f.swap(a,{display:"inline-block"},function(){b?c=bz(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bA=function(a,c){var d,e,g;c=c.replace(br,"-$1").toLowerCase();if(!(e=a.ownerDocument.defaultView))return b;if(g=e.getComputedStyle(a,null))d=g.getPropertyValue(c),d===""&&!f.contains(a.ownerDocument.documentElement,a)&&(d=f.style(a,c));return d}),c.documentElement.currentStyle&&(bB=function(a,b){var c,d=a.currentStyle&&a.currentStyle[b],e=a.runtimeStyle&&a.runtimeStyle[b],f=a.style;!bs.test(d)&&bt.test(d)&&(c=f.left,e&&(a.runtimeStyle.left=a.currentStyle.left),f.left=b==="fontSize"?"1em":d||0,d=f.pixelLeft+"px",f.left=c,e&&(a.runtimeStyle.left=e));return d===""?"auto":d}),bz=bA||bB,f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bE=/%20/g,bF=/\[\]$/,bG=/\r?\n/g,bH=/#.*$/,bI=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bJ=/^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bK=/^(?:about|app|app\-storage|.+\-extension|file|widget):$/,bL=/^(?:GET|HEAD)$/,bM=/^\/\//,bN=/\?/,bO=/)<[^<]*)*<\/script>/gi,bP=/^(?:select|textarea)/i,bQ=/\s+/,bR=/([?&])_=[^&]*/,bS=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bT=f.fn.load,bU={},bV={},bW,bX;try{bW=e.href}catch(bY){bW=c.createElement("a"),bW.href="",bW=bW.href}bX=bS.exec(bW.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bT)return bT.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("
").append(c.replace(bO,"")).find(g):c)),d&&i.each(d,[c,b,a])}});return this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||bP.test(this.nodeName)||bJ.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(bG,"\r\n")}}):{name:b.name,value:c.replace(bG,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.bind(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){f.isFunction(d)&&(g=g||e,e=d,d=b);return f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){b?f.extend(!0,a,f.ajaxSettings,b):(b=a,a=f.extend(!0,f.ajaxSettings,b));for(var c in{context:1,url:1})c in b?a[c]=b[c]:c in f.ajaxSettings&&(a[c]=f.ajaxSettings[c]);return a},ajaxSettings:{url:bW,isLocal:bK.test(bX[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":"*/*"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML}},ajaxPrefilter:bZ(bU),ajaxTransport:bZ(bV),ajax:function(a,c){function w(a,c,l,m){if(s!==2){s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a?4:0;var o,r,u,w=l?ca(d,v,l):b,x,y;if(a>=200&&a<300||a===304){if(d.ifModified){if(x=v.getResponseHeader("Last-Modified"))f.lastModified[k]=x;if(y=v.getResponseHeader("Etag"))f.etag[k]=y}if(a===304)c="notmodified",o=!0;else try{r=cb(d,w),c="success",o=!0}catch(z){c="parsererror",u=z}}else{u=c;if(!c||a)c="error",a<0&&(a=0)}v.status=a,v.statusText=c,o?h.resolveWith(e,[r,c,v]):h.rejectWith(e,[v,c,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.resolveWith(e,[v,c]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f._Deferred(),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=bI.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){s||(d.mimeType=a);return this},abort:function(a){a=a||"abort",p&&p.abort(a),w(0,a);return this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.done,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(bH,"").replace(bM,bX[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bQ),d.crossDomain==null&&(r=bS.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bX[1]&&r[2]==bX[2]&&(r[3]||(r[1]==="http:"?80:443))==(bX[3]||(bX[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),b$(bU,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bL.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bN.test(d.url)?"&":"?")+d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bR,"$1_="+x);d.url=y+(y===d.url?(bN.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", */*; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(d.beforeSend&&(d.beforeSend.call(e,v,d)===!1||s===2)){v.abort();return!1}for(u in{success:1,error:1,complete:1})v[u](d[u]);p=b$(bV,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){status<2?w(-1,z):f.error(z)}}return v},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)b_(g,a[g],c,e);return d.join("&").replace(bE,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cc=f.now(),cd=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cc++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=b.contentType==="application/x-www-form-urlencoded"&&typeof b.data=="string";if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(cd.test(b.url)||e&&cd.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";b.jsonp!==!1&&(j=j.replace(cd,l),b.url===j&&(e&&(k=k.replace(cd,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){g||f.error(h+" was not called");return g[0]},b.dataTypes[0]="json";return"script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){f.globalEval(a);return a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var ce=a.ActiveXObject?function(){for(var a in cg)cg[a](0,1)}:!1,cf=0,cg;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ch()||ci()}:ch,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,ce&&delete cg[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n),m.text=h.responseText;try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++cf,ce&&(cg||(cg={},f(a).unload(ce)),cg[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cj={},ck,cl,cm=/^(?:toggle|show|hide)$/,cn=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,co,cp=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cq,cr=a.webkitRequestAnimationFrame||a.mozRequestAnimationFrame||a.oRequestAnimationFrame;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cu("show",3),a,b,c);for(var g=0,h=this.length;g=e.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),e.animatedProperties[this.prop]=!0;for(g in e.animatedProperties)e.animatedProperties[g]!==!0&&(c=!1);if(c){e.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){d.style["overflow"+b]=e.overflow[a]}),e.hide&&f(d).hide();if(e.hide||e.show)for(var i in e.animatedProperties)f.style(d,i,e.orig[i]);e.complete.call(d)}return!1}e.duration==Infinity?this.now=b:(h=b-this.startTime,this.state=h/e.duration,this.pos=f.easing[e.animatedProperties[this.prop]](this.state,h,0,1,e.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){for(var a=f.timers,b=0;b
";f.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"}),b.innerHTML=j,a.insertBefore(b,a.firstChild),d=b.firstChild,e=d.firstChild,h=d.nextSibling.firstChild.firstChild,this.doesNotAddBorder=e.offsetTop!==5,this.doesAddBorderForTableAndCells=h.offsetTop===5,e.style.position="fixed",e.style.top="20px",this.supportsFixedPosition=e.offsetTop===20||e.offsetTop===15,e.style.position=e.style.top="",d.style.overflow="hidden",d.style.position="relative",this.subtractsBorderForOverflowNotVisible=e.offsetTop===-5,this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==i,a.removeChild(b),f.offset.initialize=f.noop},bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;f.offset.initialize(),f.offset.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat(f.css(a,"marginTop"))||0,c+=parseFloat(f.css(a,"marginLeft"))||0);return{top:b,left:c}},setOffset:function(a,b,c){var d=f.css(a,"position");d==="static"&&(a.style.position="relative");var e=f(a),g=e.offset(),h=f.css(a,"top"),i=f.css(a,"left"),j=(d==="absolute"||d==="fixed")&&f.inArray("auto",[h,i])>-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=cx.test(b[0].nodeName)?{top:0,left:0}:b.offset();c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0;return{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!cx.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each(["Left","Top"],function(a,c){var d="scroll"+c;f.fn[d]=function(c){var e,g;if(c===b){e=this[0];if(!e)return null;g=cy(e);return g?"pageXOffset"in g?g[a?"pageYOffset":"pageXOffset"]:f.support.boxModel&&g.document.documentElement[d]||g.document.body[d]:e[d]}return this.each(function(){g=cy(this),g?g.scrollTo(a?f(g).scrollLeft():c,a?c:f(g).scrollTop()):this[d]=c})}}),f.each(["Height","Width"],function(a,c){var d=c.toLowerCase();f.fn["inner"+c]=function(){return this[0]?parseFloat(f.css(this[0],d,"padding")):null},f.fn["outer"+c]=function(a){return this[0]?parseFloat(f.css(this[0],d,a?"margin":"border")):null},f.fn[d]=function(a){var e=this[0];if(!e)return a==null?null:this;if(f.isFunction(a))return this.each(function(b){var c=f(this);c[d](a.call(this,b,c[d]()))});if(f.isWindow(e)){var g=e.document.documentElement["client"+c];return e.document.compatMode==="CSS1Compat"&&g||e.document.body["client"+c]||g}if(e.nodeType===9)return Math.max(e.documentElement["client"+c],e.body["scroll"+c],e.documentElement["scroll"+c],e.body["offset"+c],e.documentElement["offset"+c]);if(a===b){var h=f.css(e,d),i=parseFloat(h);return f.isNaN(i)?h:i}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f})(window); \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/mathml.html b/source/bower_components/modernizr/test/caniuse_files/mathml.html new file mode 100644 index 0000000..8203884 --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/mathml.html @@ -0,0 +1,120 @@ + + + + + Untitled + + + + + k + = + + + + + + + 2 + + z + + + + + x + 2 + + + + + + + + 2 + + z + + + + + y + 2 + + + + - + + + ( + + + + + 2 + + z + + + + x + + y + + + ) + + 2 + + + + + + ( + 1 + + + + + ( + + + + z + + + + x + + + ) + + 2 + + + + + + ( + + + + z + + + + y + + + ) + + 2 + + ) + + 2 + + + + + + + \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/mathml_ref.png b/source/bower_components/modernizr/test/caniuse_files/mathml_ref.png new file mode 100644 index 0000000..1633e58 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/mathml_ref.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/modernizr-1.7.min.js b/source/bower_components/modernizr/test/caniuse_files/modernizr-1.7.min.js new file mode 100644 index 0000000..6f54850 --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/modernizr-1.7.min.js @@ -0,0 +1,2 @@ +// Modernizr v1.7 www.modernizr.com +window.Modernizr=function(a,b,c){function G(){e.input=function(a){for(var b=0,c=a.length;b7)},r.history=function(){return !!(a.history&&history.pushState)},r.draganddrop=function(){return x("dragstart")&&x("drop")},r.websockets=function(){return"WebSocket"in a},r.rgba=function(){A("background-color:rgba(150,255,150,.5)");return D(k.backgroundColor,"rgba")},r.hsla=function(){A("background-color:hsla(120,40%,100%,.5)");return D(k.backgroundColor,"rgba")||D(k.backgroundColor,"hsla")},r.multiplebgs=function(){A("background:url(//:),url(//:),red url(//:)");return(new RegExp("(url\\s*\\(.*?){3}")).test(k.background)},r.backgroundsize=function(){return F("backgroundSize")},r.borderimage=function(){return F("borderImage")},r.borderradius=function(){return F("borderRadius","",function(a){return D(a,"orderRadius")})},r.boxshadow=function(){return F("boxShadow")},r.textshadow=function(){return b.createElement("div").style.textShadow===""},r.opacity=function(){B("opacity:.55");return/^0.55$/.test(k.opacity)},r.cssanimations=function(){return F("animationName")},r.csscolumns=function(){return F("columnCount")},r.cssgradients=function(){var a="background-image:",b="gradient(linear,left top,right bottom,from(#9f9),to(white));",c="linear-gradient(left top,#9f9, white);";A((a+o.join(b+a)+o.join(c+a)).slice(0,-a.length));return D(k.backgroundImage,"gradient")},r.cssreflections=function(){return F("boxReflect")},r.csstransforms=function(){return!!E(["transformProperty","WebkitTransform","MozTransform","OTransform","msTransform"])},r.csstransforms3d=function(){var a=!!E(["perspectiveProperty","WebkitPerspective","MozPerspective","OPerspective","msPerspective"]);a&&"webkitPerspective"in g.style&&(a=w("@media ("+o.join("transform-3d),(")+"modernizr)"));return a},r.csstransitions=function(){return F("transitionProperty")},r.fontface=function(){var a,c,d=h||g,e=b.createElement("style"),f=b.implementation||{hasFeature:function(){return!1}};e.type="text/css",d.insertBefore(e,d.firstChild),a=e.sheet||e.styleSheet;var i=f.hasFeature("CSS2","")?function(b){if(!a||!b)return!1;var c=!1;try{a.insertRule(b,0),c=/src/i.test(a.cssRules[0].cssText),a.deleteRule(a.cssRules.length-1)}catch(d){}return c}:function(b){if(!a||!b)return!1;a.cssText=b;return a.cssText.length!==0&&/src/i.test(a.cssText)&&a.cssText.replace(/\r+|\n+/g,"").indexOf(b.split(" ")[0])===0};c=i('@font-face { font-family: "font"; src: url(data:,); }'),d.removeChild(e);return c},r.video=function(){var a=b.createElement("video"),c=!!a.canPlayType;if(c){c=new Boolean(c),c.ogg=a.canPlayType('video/ogg; codecs="theora"');var d='video/mp4; codecs="avc1.42E01E';c.h264=a.canPlayType(d+'"')||a.canPlayType(d+', mp4a.40.2"'),c.webm=a.canPlayType('video/webm; codecs="vp8, vorbis"')}return c},r.audio=function(){var a=b.createElement("audio"),c=!!a.canPlayType;c&&(c=new Boolean(c),c.ogg=a.canPlayType('audio/ogg; codecs="vorbis"'),c.mp3=a.canPlayType("audio/mpeg;"),c.wav=a.canPlayType('audio/wav; codecs="1"'),c.m4a=a.canPlayType("audio/x-m4a;")||a.canPlayType("audio/aac;"));return c},r.localstorage=function(){try{return!!localStorage.getItem}catch(a){return!1}},r.sessionstorage=function(){try{return!!sessionStorage.getItem}catch(a){return!1}},r.webWorkers=function(){return!!a.Worker},r.applicationcache=function(){return!!a.applicationCache},r.svg=function(){return!!b.createElementNS&&!!b.createElementNS(q.svg,"svg").createSVGRect},r.inlinesvg=function(){var a=b.createElement("div");a.innerHTML="";return(a.firstChild&&a.firstChild.namespaceURI)==q.svg},r.smil=function(){return!!b.createElementNS&&/SVG/.test(n.call(b.createElementNS(q.svg,"animate")))},r.svgclippaths=function(){return!!b.createElementNS&&/SVG/.test(n.call(b.createElementNS(q.svg,"clipPath")))};for(var H in r)z(r,H)&&(v=H.toLowerCase(),e[v]=r[H](),u.push((e[v]?"":"no-")+v));e.input||G(),e.crosswindowmessaging=e.postmessage,e.historymanagement=e.history,e.addTest=function(a,b){a=a.toLowerCase();if(!e[a]){b=!!b(),g.className+=" "+(b?"":"no-")+a,e[a]=b;return e}},A(""),j=l=null,f&&a.attachEvent&&function(){var a=b.createElement("div");a.innerHTML="";return a.childNodes.length!==1}()&&function(a,b){function p(a,b){var c=-1,d=a.length,e,f=[];while(++c + + + + popstate event test + + + + + + + diff --git a/source/bower_components/modernizr/test/caniuse_files/red30x30.png b/source/bower_components/modernizr/test/caniuse_files/red30x30.png new file mode 100644 index 0000000..561c8d2 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/red30x30.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/ruby.png b/source/bower_components/modernizr/test/caniuse_files/ruby.png new file mode 100644 index 0000000..4fe06dd Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/ruby.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/stroked-text.png b/source/bower_components/modernizr/test/caniuse_files/stroked-text.png new file mode 100644 index 0000000..e75890f Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/stroked-text.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/style.css b/source/bower_components/modernizr/test/caniuse_files/style.css new file mode 100644 index 0000000..d90731b --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/style.css @@ -0,0 +1,168 @@ +body { + font-family: "Lucida Grande", Lucida, Verdana, sans-serif; + font-size: 12px; +} + +a { + text-decoration: none; +} +a:hover { + text-decoration: underline; +} + +table, tr, th, td { + border: 1px solid #AAA; +} + +table { + margin-top: 1em; + width: 100%; +} + +tbody th { + text-align: left; + font-size: 14px; + width: 200px; +} + +th h3 { + margin: 3px; + font-size: 12px; +} + +th span.links { + font-size: 10px; +} + +dt { + font-weight: bold; +} + +tr:hover > th, +tr:hover > td + td { background-color: #FFC; } + +div.test_wrap { + display: -moz-inline-stack; + display: inline-block; + border: 1px solid #CCC; + text-align: center; + vertical-align: top; + min-height: 50px; + margin-right: 5px; + background: white; + position: relative; +} + +div.test_wrap h3 { + text-align: center; + margin: 2px; + font-size: 10px; +} + +div.auto { + display: -moz-inline-stack; + display: inline-block; + border: 1px solid; + width: 30px; + height: 30px; +} + +div.square { + display: -moz-inline-stack; + display: inline-block; + border: 1px solid; + width: 30px; + height: 30px; + background: red; +} + +div.info { + display: none; + position: absolute; + top: 100%; + z-index: 2; + left: 0; + background: white; + padding: 2px; + min-width: 300px; + border: 1px solid; + text-align: left; +} + +div.test_wrap:hover > div.info { + display: block; +} + + +div.vis_test { + display: -moz-inline-stack; + display: inline-block; +} + +div.vis_ref { + display: -moz-inline-stack; + display: inline-block; + border-left: 1px dashed black; + margin-left: 5px; + padding-left: 5px; + vertical-align: top; +} + +p.condition { + font-style: italic; + margin: 2px; + clear: both; +} + +.pass { + background: lime; +} + +.fail { + background: red; +} + +.partial { + background: yellow; +} + +.unknown { + background: #aaa; +} + +.current span { + border-radius: 6px; + -moz-border-radius: 6px; + background: none repeat scroll 0 0 #E6EA69; + color: black; + float: right; + font-size: 8px; + padding: 0 1px; +} + +#intro, #options { + width: 400px; + background: #EEE; + border-radius: 10px; + padding: 5px 10px; + margin: 10px; + float: left; +} + +#intro dt::after { + content: ':'; +} + +#intro dd { + margin-bottom: 1em; +} + +#opt_submit { + display: block; + margin: 10px; +} + +#options label { + display: block; + margin: 5px; +} \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/svg-html-blur.png b/source/bower_components/modernizr/test/caniuse_files/svg-html-blur.png new file mode 100644 index 0000000..549b297 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/svg-html-blur.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/svg-img.svg b/source/bower_components/modernizr/test/caniuse_files/svg-img.svg new file mode 100644 index 0000000..c0a867f --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/svg-img.svg @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/svg-img.svg.1 b/source/bower_components/modernizr/test/caniuse_files/svg-img.svg.1 new file mode 100644 index 0000000..c0a867f --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/svg-img.svg.1 @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/source/bower_components/modernizr/test/caniuse_files/svg_blur.png b/source/bower_components/modernizr/test/caniuse_files/svg_blur.png new file mode 100644 index 0000000..17cb6e3 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/svg_blur.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/table.png b/source/bower_components/modernizr/test/caniuse_files/table.png new file mode 100644 index 0000000..e9b9b9d Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/table.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/text-shadow1.png b/source/bower_components/modernizr/test/caniuse_files/text-shadow1.png new file mode 100644 index 0000000..47b3cea Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/text-shadow1.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/text-shadow2.png b/source/bower_components/modernizr/test/caniuse_files/text-shadow2.png new file mode 100644 index 0000000..f335189 Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/text-shadow2.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/windsong_font.png b/source/bower_components/modernizr/test/caniuse_files/windsong_font.png new file mode 100644 index 0000000..b983d2a Binary files /dev/null and b/source/bower_components/modernizr/test/caniuse_files/windsong_font.png differ diff --git a/source/bower_components/modernizr/test/caniuse_files/xhtml.html b/source/bower_components/modernizr/test/caniuse_files/xhtml.html new file mode 100644 index 0000000..af4be89 --- /dev/null +++ b/source/bower_components/modernizr/test/caniuse_files/xhtml.html @@ -0,0 +1,14 @@ + + + + + Untitled + +

true

+ + + \ No newline at end of file diff --git a/source/bower_components/modernizr/test/index.html b/source/bower_components/modernizr/test/index.html new file mode 100644 index 0000000..587f0c8 --- /dev/null +++ b/source/bower_components/modernizr/test/index.html @@ -0,0 +1,104 @@ + + + + + Modernizr Test Suite + + + + + + + + + + + + + + + + + + + + + + + + +

Modernizr Test Suite

+

+
+

+ +
    + +
    +
    + + +
    + +
    + + + + +
    JSON.stringify(Modernizr)
    + + Show the Ref Tests from Caniuse and Modernizr + + + + + + + + diff --git a/source/bower_components/modernizr/test/js/basic.html b/source/bower_components/modernizr/test/js/basic.html new file mode 100644 index 0000000..9f378a9 --- /dev/null +++ b/source/bower_components/modernizr/test/js/basic.html @@ -0,0 +1,65 @@ + + + + + Modernizr Test Suite + + + + + + + + + + + + + + + + + + +

    Modernizr Test Suite

    +

    +
    +

    + +
      + +
      +
      + + +
      + +
      + + + + diff --git a/source/bower_components/modernizr/test/js/dumpdata.js b/source/bower_components/modernizr/test/js/dumpdata.js new file mode 100644 index 0000000..43c667b --- /dev/null +++ b/source/bower_components/modernizr/test/js/dumpdata.js @@ -0,0 +1,75 @@ +function dumpModernizr(){ + var str = ''; + dumpModernizr.old = dumpModernizr.old || {}; + + for (var prop in Modernizr) { + + // skip previously done ones. + if (dumpModernizr.old[prop]) continue; + else dumpModernizr.old[prop] = true; + + if (typeof Modernizr[prop] === 'function') continue; + // skip unit test items + if (/^test/.test(prop)) continue; + + if (~TEST.inputs.indexOf(prop)) { + str += '
    1. '+prop+'{}
        '; + for (var field in Modernizr[prop]) { + str += '
      • ' + field + ': ' + Modernizr[prop][field] + '
      • '; + } + str += '
    2. '; + } else { + str += '
    3. ' + prop + ': ' + Modernizr[prop] + '
    4. '; + } + } + return str; +} + + +function grabFeatDetects(){ + // thx github.js + $.getScript('https://api.github.com/repos/Modernizr/Modernizr/git/trees/master?recursive=1&callback=processTree'); +} + + +function processTree(data){ + var filenames = []; + + for (var i = 0; i < data.data.tree.length; i++){ + var file = data.data.tree[i]; + var match = file.path.match(/^feature-detects\/(.*)/); + if (!match) continue; + + var relpath = location.host == "modernizr.github.com" ? + '../modernizr-git/' : '../'; + + filenames.push(relpath + match[0]); + } + + var jqxhrs = filenames.map(function(filename){ + return jQuery.getScript(filename); + }); + + jQuery.when.apply(jQuery, jqxhrs).done(resultsToDOM); + +} + +function resultsToDOM(){ + + var modOutput = document.createElement('div'), + ref = document.getElementById('qunit-testresult') || document.getElementById('qunit-tests'); + + modOutput.className = 'output'; + modOutput.innerHTML = dumpModernizr(); + + ref.parentNode.insertBefore(modOutput, ref); + + // Modernizr object as text + document.getElementsByTagName('textarea')[0].innerHTML = JSON.stringify(Modernizr); + +} + +/* uno */ resultsToDOM(); +/* dos */ grabFeatDetects(); +/* tres */ setTimeout(resultsToDOM, 5e3); +/* quatro */ setTimeout(resultsToDOM, 15e3); diff --git a/source/bower_components/modernizr/test/js/lib/detect-global.js b/source/bower_components/modernizr/test/js/lib/detect-global.js new file mode 100644 index 0000000..48b4ac2 --- /dev/null +++ b/source/bower_components/modernizr/test/js/lib/detect-global.js @@ -0,0 +1,153 @@ +// https://github.com/kangax/detect-global + +// tweaked to run without a UI. + +(function () { + function getPropertyDescriptors(object) { + var props = { }; + for (var prop in object) { + + // nerfing for firefox who goes crazy over some objects like sessionStorage + try { + + props[prop] = { + type: typeof object[prop], + value: object[prop] + }; + + } catch(e){ + props[prop] = {}; + } + } + return props; + } + + function getCleanWindow() { + var elIframe = document.createElement('iframe'); + elIframe.style.display = 'none'; + + var ref = document.getElementsByTagName('script')[0]; + ref.parentNode.insertBefore(elIframe, ref); + + elIframe.src = 'about:blank'; + return elIframe.contentWindow; + } + + function appendControl(el, name) { + var elCheckbox = document.createElement('input'); + elCheckbox.type = 'checkbox'; + elCheckbox.checked = true; + elCheckbox.id = '__' + name; + + var elLabel = document.createElement('label'); + elLabel.htmlFor = '__' + name; + elLabel.innerHTML = 'Exclude ' + name + ' properties?'; + elLabel.style.marginLeft = '0.5em'; + + var elWrapper = document.createElement('p'); + elWrapper.style.marginBottom = '0.5em'; + + elWrapper.appendChild(elCheckbox); + elWrapper.appendChild(elLabel); + + el.appendChild(elWrapper); + } + + function appendAnalyze(el) { + var elAnalyze = document.createElement('button'); + elAnalyze.id = '__analyze'; + elAnalyze.innerHTML = 'Analyze'; + elAnalyze.style.marginTop = '1em'; + el.appendChild(elAnalyze); + } + + function appendCancel(el) { + var elCancel = document.createElement('a'); + elCancel.href = '#'; + elCancel.innerHTML = 'Cancel'; + elCancel.style.cssText = 'color:#eee;margin-left:0.5em;'; + elCancel.onclick = function() { + el.parentNode.removeChild(el); + return false; + }; + el.appendChild(elCancel); + } + + function initConfigPopup() { + var el = document.createElement('div'); + + el.style.cssText = 'position:fixed; left:10px; top:10px; width:300px; background:rgba(50,50,50,0.9);' + + '-moz-border-radius:10px; padding:1em; color: #eee; text-align: left;' + + 'font-family: "Helvetica Neue", Verdana, Arial, sans serif; z-index: 99999;'; + + for (var prop in propSets) { + appendControl(el, prop); + } + + appendAnalyze(el); + appendCancel(el); + + var ref = document.getElementsByTagName('script')[0]; + ref.parentNode.insertBefore(el, ref); + } + + function getPropsCount(object) { + var count = 0; + for (var prop in object) { + count++; + } + return count; + } + + function shouldDeleteProperty(propToCheck) { + for (var prop in propSets) { + var elCheckbox = document.getElementById('__' + prop); + var isPropInSet = propSets[prop].indexOf(propToCheck) > -1; + if (isPropInSet && (elCheckbox ? elCheckbox.checked : true) ) { + return true; + } + } + } + + function analyze() { + var global = (function(){ return this; })(), + globalProps = getPropertyDescriptors(global), + cleanWindow = getCleanWindow(); + + for (var prop in cleanWindow) { + if (globalProps[prop]) { + delete globalProps[prop]; + } + } + for (var prop in globalProps) { + if (shouldDeleteProperty(prop)) { + delete globalProps[prop]; + } + } + + window.__globalsCount = getPropsCount(globalProps); + window.__globals = globalProps; + + window.console && console.log('Total number of global properties: ' + __globalsCount); + window.console && console.dir(__globals); + } + + var propSets = { + 'Prototype': '$$ $A $F $H $R $break $continue $w Abstract Ajax Class Enumerable Element Field Form ' + + 'Hash Insertion ObjectRange PeriodicalExecuter Position Prototype Selector Template Toggle Try'.split(' '), + + 'Scriptaculous': 'Autocompleter Builder Control Draggable Draggables Droppables Effect Sortable SortableObserver Sound Scriptaculous'.split(' '), + 'Firebug': 'loadFirebugConsole console _getFirebugConsoleElement _FirebugConsole _FirebugCommandLine _firebug'.split(' '), + 'Mozilla': 'Components XPCNativeWrapper XPCSafeJSObjectWrapper getInterface netscape GetWeakReference GeckoActiveXObject'.split(' '), + 'GoogleAnalytics': 'gaJsHost gaGlobal _gat _gaq pageTracker'.split(' '), + 'lazyGlobals': 'onhashchange'.split(' ') + }; + + // initConfigPopup(); // disable because we're going UI-less. + + var analyzeElem = document.getElementById('__analyze'); + analyzeElem && (analyzeElem.onclick = analyze); + + analyze(); // and assign total added globals to window.__globalsCount + +})(); \ No newline at end of file diff --git a/source/bower_components/modernizr/test/js/lib/jquery-1.7b2.js b/source/bower_components/modernizr/test/js/lib/jquery-1.7b2.js new file mode 100644 index 0000000..98c6d0d --- /dev/null +++ b/source/bower_components/modernizr/test/js/lib/jquery-1.7b2.js @@ -0,0 +1,9279 @@ +/*! + * jQuery JavaScript Library v1.7b2 + * http://jquery.com/ + * + * Copyright 2011, John Resig + * Dual licensed under the MIT or GPL Version 2 licenses. + * http://jquery.org/license + * + * Includes Sizzle.js + * http://sizzlejs.com/ + * Copyright 2011, The Dojo Foundation + * Released under the MIT, BSD, and GPL Licenses. + * + * Date: Thu Oct 13 21:12:55 2011 -0400 + */ +(function( window, undefined ) { + +// Use the correct document accordingly with window argument (sandbox) +var document = window.document, + navigator = window.navigator, + location = window.location; +var jQuery = (function() { + +// Define a local copy of jQuery +var jQuery = function( selector, context ) { + // The jQuery object is actually just the init constructor 'enhanced' + return new jQuery.fn.init( selector, context, rootjQuery ); + }, + + // Map over jQuery in case of overwrite + _jQuery = window.jQuery, + + // Map over the $ in case of overwrite + _$ = window.$, + + // A central reference to the root jQuery(document) + rootjQuery, + + // A simple way to check for HTML strings or ID strings + // Prioritize #id over to avoid XSS via location.hash (#9521) + quickExpr = /^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/, + + // Check if a string has a non-whitespace character in it + rnotwhite = /\S/, + + // Used for trimming whitespace + trimLeft = /^\s+/, + trimRight = /\s+$/, + + // Check for digits + rdigit = /\d/, + + // Match a standalone tag + rsingleTag = /^<(\w+)\s*\/?>(?:<\/\1>)?$/, + + // JSON RegExp + rvalidchars = /^[\],:{}\s]*$/, + rvalidescape = /\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g, + rvalidtokens = /"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g, + rvalidbraces = /(?:^|:|,)(?:\s*\[)+/g, + + // Useragent RegExp + rwebkit = /(webkit)[ \/]([\w.]+)/, + ropera = /(opera)(?:.*version)?[ \/]([\w.]+)/, + rmsie = /(msie) ([\w.]+)/, + rmozilla = /(mozilla)(?:.*? rv:([\w.]+))?/, + + // Matches dashed string for camelizing + rdashAlpha = /-([a-z]|[0-9])/ig, + rmsPrefix = /^-ms-/, + + // Used by jQuery.camelCase as callback to replace() + fcamelCase = function( all, letter ) { + return ( letter + "" ).toUpperCase(); + }, + + // Keep a UserAgent string for use with jQuery.browser + userAgent = navigator.userAgent, + + // For matching the engine and version of the browser + browserMatch, + + // The deferred used on DOM ready + readyList, + + // The ready event handler + DOMContentLoaded, + + // Save a reference to some core methods + toString = Object.prototype.toString, + hasOwn = Object.prototype.hasOwnProperty, + push = Array.prototype.push, + slice = Array.prototype.slice, + trim = String.prototype.trim, + indexOf = Array.prototype.indexOf, + + // [[Class]] -> type pairs + class2type = {}; + +jQuery.fn = jQuery.prototype = { + constructor: jQuery, + init: function( selector, context, rootjQuery ) { + var match, elem, ret, doc; + + // Handle $(""), $(null), or $(undefined) + if ( !selector ) { + return this; + } + + // Handle $(DOMElement) + if ( selector.nodeType ) { + this.context = this[0] = selector; + this.length = 1; + return this; + } + + // The body element only exists once, optimize finding it + if ( selector === "body" && !context && document.body ) { + this.context = document; + this[0] = document.body; + this.selector = selector; + this.length = 1; + return this; + } + + // Handle HTML strings + if ( typeof selector === "string" ) { + // Are we dealing with HTML string or an ID? + if ( selector.charAt(0) === "<" && selector.charAt( selector.length - 1 ) === ">" && selector.length >= 3 ) { + // Assume that strings that start and end with <> are HTML and skip the regex check + match = [ null, selector, null ]; + + } else { + match = quickExpr.exec( selector ); + } + + // Verify a match, and that no context was specified for #id + if ( match && (match[1] || !context) ) { + + // HANDLE: $(html) -> $(array) + if ( match[1] ) { + context = context instanceof jQuery ? context[0] : context; + doc = (context ? context.ownerDocument || context : document); + + // If a single string is passed in and it's a single tag + // just do a createElement and skip the rest + ret = rsingleTag.exec( selector ); + + if ( ret ) { + if ( jQuery.isPlainObject( context ) ) { + selector = [ document.createElement( ret[1] ) ]; + jQuery.fn.attr.call( selector, context, true ); + + } else { + selector = [ doc.createElement( ret[1] ) ]; + } + + } else { + ret = jQuery.buildFragment( [ match[1] ], [ doc ] ); + selector = (ret.cacheable ? jQuery.clone(ret.fragment) : ret.fragment).childNodes; + } + + return jQuery.merge( this, selector ); + + // HANDLE: $("#id") + } else { + elem = document.getElementById( match[2] ); + + // Check parentNode to catch when Blackberry 4.6 returns + // nodes that are no longer in the document #6963 + if ( elem && elem.parentNode ) { + // Handle the case where IE and Opera return items + // by name instead of ID + if ( elem.id !== match[2] ) { + return rootjQuery.find( selector ); + } + + // Otherwise, we inject the element directly into the jQuery object + this.length = 1; + this[0] = elem; + } + + this.context = document; + this.selector = selector; + return this; + } + + // HANDLE: $(expr, $(...)) + } else if ( !context || context.jquery ) { + return (context || rootjQuery).find( selector ); + + // HANDLE: $(expr, context) + // (which is just equivalent to: $(context).find(expr) + } else { + return this.constructor( context ).find( selector ); + } + + // HANDLE: $(function) + // Shortcut for document ready + } else if ( jQuery.isFunction( selector ) ) { + return rootjQuery.ready( selector ); + } + + if (selector.selector !== undefined) { + this.selector = selector.selector; + this.context = selector.context; + } + + return jQuery.makeArray( selector, this ); + }, + + // Start with an empty selector + selector: "", + + // The current version of jQuery being used + jquery: "1.7b2", + + // The default length of a jQuery object is 0 + length: 0, + + // The number of elements contained in the matched element set + size: function() { + return this.length; + }, + + toArray: function() { + return slice.call( this, 0 ); + }, + + // Get the Nth element in the matched element set OR + // Get the whole matched element set as a clean array + get: function( num ) { + return num == null ? + + // Return a 'clean' array + this.toArray() : + + // Return just the object + ( num < 0 ? this[ this.length + num ] : this[ num ] ); + }, + + // Take an array of elements and push it onto the stack + // (returning the new matched element set) + pushStack: function( elems, name, selector ) { + // Build a new jQuery matched element set + var ret = this.constructor(); + + if ( jQuery.isArray( elems ) ) { + push.apply( ret, elems ); + + } else { + jQuery.merge( ret, elems ); + } + + // Add the old object onto the stack (as a reference) + ret.prevObject = this; + + ret.context = this.context; + + if ( name === "find" ) { + ret.selector = this.selector + (this.selector ? " " : "") + selector; + } else if ( name ) { + ret.selector = this.selector + "." + name + "(" + selector + ")"; + } + + // Return the newly-formed element set + return ret; + }, + + // Execute a callback for every element in the matched set. + // (You can seed the arguments with an array of args, but this is + // only used internally.) + each: function( callback, args ) { + return jQuery.each( this, callback, args ); + }, + + ready: function( fn ) { + // Attach the listeners + jQuery.bindReady(); + + // Add the callback + readyList.add( fn ); + + return this; + }, + + eq: function( i ) { + return i === -1 ? + this.slice( i ) : + this.slice( i, +i + 1 ); + }, + + first: function() { + return this.eq( 0 ); + }, + + last: function() { + return this.eq( -1 ); + }, + + slice: function() { + return this.pushStack( slice.apply( this, arguments ), + "slice", slice.call(arguments).join(",") ); + }, + + map: function( callback ) { + return this.pushStack( jQuery.map(this, function( elem, i ) { + return callback.call( elem, i, elem ); + })); + }, + + end: function() { + return this.prevObject || this.constructor(null); + }, + + // For internal use only. + // Behaves like an Array's method, not like a jQuery method. + push: push, + sort: [].sort, + splice: [].splice +}; + +// Give the init function the jQuery prototype for later instantiation +jQuery.fn.init.prototype = jQuery.fn; + +jQuery.extend = jQuery.fn.extend = function() { + var options, name, src, copy, copyIsArray, clone, + target = arguments[0] || {}, + i = 1, + length = arguments.length, + deep = false; + + // Handle a deep copy situation + if ( typeof target === "boolean" ) { + deep = target; + target = arguments[1] || {}; + // skip the boolean and the target + i = 2; + } + + // Handle case when target is a string or something (possible in deep copy) + if ( typeof target !== "object" && !jQuery.isFunction(target) ) { + target = {}; + } + + // extend jQuery itself if only one argument is passed + if ( length === i ) { + target = this; + --i; + } + + for ( ; i < length; i++ ) { + // Only deal with non-null/undefined values + if ( (options = arguments[ i ]) != null ) { + // Extend the base object + for ( name in options ) { + src = target[ name ]; + copy = options[ name ]; + + // Prevent never-ending loop + if ( target === copy ) { + continue; + } + + // Recurse if we're merging plain objects or arrays + if ( deep && copy && ( jQuery.isPlainObject(copy) || (copyIsArray = jQuery.isArray(copy)) ) ) { + if ( copyIsArray ) { + copyIsArray = false; + clone = src && jQuery.isArray(src) ? src : []; + + } else { + clone = src && jQuery.isPlainObject(src) ? src : {}; + } + + // Never move original objects, clone them + target[ name ] = jQuery.extend( deep, clone, copy ); + + // Don't bring in undefined values + } else if ( copy !== undefined ) { + target[ name ] = copy; + } + } + } + } + + // Return the modified object + return target; +}; + +jQuery.extend({ + noConflict: function( deep ) { + if ( window.$ === jQuery ) { + window.$ = _$; + } + + if ( deep && window.jQuery === jQuery ) { + window.jQuery = _jQuery; + } + + return jQuery; + }, + + // Is the DOM ready to be used? Set to true once it occurs. + isReady: false, + + // A counter to track how many items to wait for before + // the ready event fires. See #6781 + readyWait: 1, + + // Hold (or release) the ready event + holdReady: function( hold ) { + if ( hold ) { + jQuery.readyWait++; + } else { + jQuery.ready( true ); + } + }, + + // Handle when the DOM is ready + ready: function( wait ) { + // Either a released hold or an DOMready/load event and not yet ready + if ( (wait === true && !--jQuery.readyWait) || (wait !== true && !jQuery.isReady) ) { + // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443). + if ( !document.body ) { + return setTimeout( jQuery.ready, 1 ); + } + + // Remember that the DOM is ready + jQuery.isReady = true; + + // If a normal DOM Ready event fired, decrement, and wait if need be + if ( wait !== true && --jQuery.readyWait > 0 ) { + return; + } + + // If there are functions bound, to execute + readyList.fireWith( document, [ jQuery ] ); + + // Trigger any bound ready events + if ( jQuery.fn.trigger ) { + jQuery( document ).trigger( "ready" ).unbind( "ready" ); + } + } + }, + + bindReady: function() { + if ( readyList ) { + return; + } + + readyList = jQuery.Callbacks( "once memory" ); + + // Catch cases where $(document).ready() is called after the + // browser event has already occurred. + if ( document.readyState === "complete" ) { + // Handle it asynchronously to allow scripts the opportunity to delay ready + return setTimeout( jQuery.ready, 1 ); + } + + // Mozilla, Opera and webkit nightlies currently support this event + if ( document.addEventListener ) { + // Use the handy event callback + document.addEventListener( "DOMContentLoaded", DOMContentLoaded, false ); + + // A fallback to window.onload, that will always work + window.addEventListener( "load", jQuery.ready, false ); + + // If IE event model is used + } else if ( document.attachEvent ) { + // ensure firing before onload, + // maybe late but safe also for iframes + document.attachEvent( "onreadystatechange", DOMContentLoaded ); + + // A fallback to window.onload, that will always work + window.attachEvent( "onload", jQuery.ready ); + + // If IE and not a frame + // continually check to see if the document is ready + var toplevel = false; + + try { + toplevel = window.frameElement == null; + } catch(e) {} + + if ( document.documentElement.doScroll && toplevel ) { + doScrollCheck(); + } + } + }, + + // See test/unit/core.js for details concerning isFunction. + // Since version 1.3, DOM methods and functions like alert + // aren't supported. They return false on IE (#2968). + isFunction: function( obj ) { + return jQuery.type(obj) === "function"; + }, + + isArray: Array.isArray || function( obj ) { + return jQuery.type(obj) === "array"; + }, + + // A crude way of determining if an object is a window + isWindow: function( obj ) { + return obj && typeof obj === "object" && "setInterval" in obj; + }, + + isNumeric: function( obj ) { + return obj != null && rdigit.test( obj ) && !isNaN( obj ); + }, + + type: function( obj ) { + return obj == null ? + String( obj ) : + class2type[ toString.call(obj) ] || "object"; + }, + + isPlainObject: function( obj ) { + // Must be an Object. + // Because of IE, we also have to check the presence of the constructor property. + // Make sure that DOM nodes and window objects don't pass through, as well + if ( !obj || jQuery.type(obj) !== "object" || obj.nodeType || jQuery.isWindow( obj ) ) { + return false; + } + + try { + // Not own constructor property must be Object + if ( obj.constructor && + !hasOwn.call(obj, "constructor") && + !hasOwn.call(obj.constructor.prototype, "isPrototypeOf") ) { + return false; + } + } catch ( e ) { + // IE8,9 Will throw exceptions on certain host objects #9897 + return false; + } + + // Own properties are enumerated firstly, so to speed up, + // if last one is own, then all properties are own. + + var key; + for ( key in obj ) {} + + return key === undefined || hasOwn.call( obj, key ); + }, + + isEmptyObject: function( obj ) { + for ( var name in obj ) { + return false; + } + return true; + }, + + error: function( msg ) { + throw msg; + }, + + parseJSON: function( data ) { + if ( typeof data !== "string" || !data ) { + return null; + } + + // Make sure leading/trailing whitespace is removed (IE can't handle it) + data = jQuery.trim( data ); + + // Attempt to parse using the native JSON parser first + if ( window.JSON && window.JSON.parse ) { + return window.JSON.parse( data ); + } + + // Make sure the incoming data is actual JSON + // Logic borrowed from http://json.org/json2.js + if ( rvalidchars.test( data.replace( rvalidescape, "@" ) + .replace( rvalidtokens, "]" ) + .replace( rvalidbraces, "")) ) { + + return (new Function( "return " + data ))(); + + } + jQuery.error( "Invalid JSON: " + data ); + }, + + // Cross-browser xml parsing + parseXML: function( data ) { + var xml, tmp; + try { + if ( window.DOMParser ) { // Standard + tmp = new DOMParser(); + xml = tmp.parseFromString( data , "text/xml" ); + } else { // IE + xml = new ActiveXObject( "Microsoft.XMLDOM" ); + xml.async = "false"; + xml.loadXML( data ); + } + } catch( e ) { + xml = undefined; + } + if ( !xml || !xml.documentElement || xml.getElementsByTagName( "parsererror" ).length ) { + jQuery.error( "Invalid XML: " + data ); + } + return xml; + }, + + noop: function() {}, + + // Evaluates a script in a global context + // Workarounds based on findings by Jim Driscoll + // http://weblogs.java.net/blog/driscoll/archive/2009/09/08/eval-javascript-global-context + globalEval: function( data ) { + if ( data && rnotwhite.test( data ) ) { + // We use execScript on Internet Explorer + // We use an anonymous function so that context is window + // rather than jQuery in Firefox + ( window.execScript || function( data ) { + window[ "eval" ].call( window, data ); + } )( data ); + } + }, + + // Convert dashed to camelCase; used by the css and data modules + // Microsoft forgot to hump their vendor prefix (#9572) + camelCase: function( string ) { + return string.replace( rmsPrefix, "ms-" ).replace( rdashAlpha, fcamelCase ); + }, + + nodeName: function( elem, name ) { + return elem.nodeName && elem.nodeName.toUpperCase() === name.toUpperCase(); + }, + + // args is for internal usage only + each: function( object, callback, args ) { + var name, i = 0, + length = object.length, + isObj = length === undefined || jQuery.isFunction( object ); + + if ( args ) { + if ( isObj ) { + for ( name in object ) { + if ( callback.apply( object[ name ], args ) === false ) { + break; + } + } + } else { + for ( ; i < length; ) { + if ( callback.apply( object[ i++ ], args ) === false ) { + break; + } + } + } + + // A special, fast, case for the most common use of each + } else { + if ( isObj ) { + for ( name in object ) { + if ( callback.call( object[ name ], name, object[ name ] ) === false ) { + break; + } + } + } else { + for ( ; i < length; ) { + if ( callback.call( object[ i ], i, object[ i++ ] ) === false ) { + break; + } + } + } + } + + return object; + }, + + // Use native String.trim function wherever possible + trim: trim ? + function( text ) { + return text == null ? + "" : + trim.call( text ); + } : + + // Otherwise use our own trimming functionality + function( text ) { + return text == null ? + "" : + text.toString().replace( trimLeft, "" ).replace( trimRight, "" ); + }, + + // results is for internal usage only + makeArray: function( array, results ) { + var ret = results || []; + + if ( array != null ) { + // The window, strings (and functions) also have 'length' + // The extra typeof function check is to prevent crashes + // in Safari 2 (See: #3039) + // Tweaked logic slightly to handle Blackberry 4.7 RegExp issues #6930 + var type = jQuery.type( array ); + + if ( array.length == null || type === "string" || type === "function" || type === "regexp" || jQuery.isWindow( array ) ) { + push.call( ret, array ); + } else { + jQuery.merge( ret, array ); + } + } + + return ret; + }, + + inArray: function( elem, array, i ) { + var len; + + if ( array ) { + if ( indexOf ) { + return indexOf.call( array, elem, i ); + } + + len = array.length; + i = i ? i < 0 ? Math.max( 0, len + i ) : i : 0; + + for ( ; i < len; i++ ) { + // Skip accessing in sparse arrays + if ( i in array && array[ i ] === elem ) { + return i; + } + } + } + + return -1; + }, + + merge: function( first, second ) { + var i = first.length, + j = 0; + + if ( typeof second.length === "number" ) { + for ( var l = second.length; j < l; j++ ) { + first[ i++ ] = second[ j ]; + } + + } else { + while ( second[j] !== undefined ) { + first[ i++ ] = second[ j++ ]; + } + } + + first.length = i; + + return first; + }, + + grep: function( elems, callback, inv ) { + var ret = [], retVal; + inv = !!inv; + + // Go through the array, only saving the items + // that pass the validator function + for ( var i = 0, length = elems.length; i < length; i++ ) { + retVal = !!callback( elems[ i ], i ); + if ( inv !== retVal ) { + ret.push( elems[ i ] ); + } + } + + return ret; + }, + + // arg is for internal usage only + map: function( elems, callback, arg ) { + var value, key, ret = [], + i = 0, + length = elems.length, + // jquery objects are treated as arrays + isArray = elems instanceof jQuery || length !== undefined && typeof length === "number" && ( ( length > 0 && elems[ 0 ] && elems[ length -1 ] ) || length === 0 || jQuery.isArray( elems ) ) ; + + // Go through the array, translating each of the items to their + if ( isArray ) { + for ( ; i < length; i++ ) { + value = callback( elems[ i ], i, arg ); + + if ( value != null ) { + ret[ ret.length ] = value; + } + } + + // Go through every key on the object, + } else { + for ( key in elems ) { + value = callback( elems[ key ], key, arg ); + + if ( value != null ) { + ret[ ret.length ] = value; + } + } + } + + // Flatten any nested arrays + return ret.concat.apply( [], ret ); + }, + + // A global GUID counter for objects + guid: 1, + + // Bind a function to a context, optionally partially applying any + // arguments. + proxy: function( fn, context ) { + if ( typeof context === "string" ) { + var tmp = fn[ context ]; + context = fn; + fn = tmp; + } + + // Quick check to determine if target is callable, in the spec + // this throws a TypeError, but we will just return undefined. + if ( !jQuery.isFunction( fn ) ) { + return undefined; + } + + // Simulated bind + var args = slice.call( arguments, 2 ), + proxy = function() { + return fn.apply( context, args.concat( slice.call( arguments ) ) ); + }; + + // Set the guid of unique handler to the same of original handler, so it can be removed + proxy.guid = fn.guid = fn.guid || proxy.guid || jQuery.guid++; + + return proxy; + }, + + // Mutifunctional method to get and set values to a collection + // The value/s can optionally be executed if it's a function + access: function( elems, key, value, exec, fn, pass ) { + var length = elems.length; + + // Setting many attributes + if ( typeof key === "object" ) { + for ( var k in key ) { + jQuery.access( elems, k, key[k], exec, fn, value ); + } + return elems; + } + + // Setting one attribute + if ( value !== undefined ) { + // Optionally, function values get executed if exec is true + exec = !pass && exec && jQuery.isFunction(value); + + for ( var i = 0; i < length; i++ ) { + fn( elems[i], key, exec ? value.call( elems[i], i, fn( elems[i], key ) ) : value, pass ); + } + + return elems; + } + + // Getting an attribute + return length ? fn( elems[0], key ) : undefined; + }, + + now: function() { + return (new Date()).getTime(); + }, + + // Use of jQuery.browser is frowned upon. + // More details: http://docs.jquery.com/Utilities/jQuery.browser + uaMatch: function( ua ) { + ua = ua.toLowerCase(); + + var match = rwebkit.exec( ua ) || + ropera.exec( ua ) || + rmsie.exec( ua ) || + ua.indexOf("compatible") < 0 && rmozilla.exec( ua ) || + []; + + return { browser: match[1] || "", version: match[2] || "0" }; + }, + + sub: function() { + function jQuerySub( selector, context ) { + return new jQuerySub.fn.init( selector, context ); + } + jQuery.extend( true, jQuerySub, this ); + jQuerySub.superclass = this; + jQuerySub.fn = jQuerySub.prototype = this(); + jQuerySub.fn.constructor = jQuerySub; + jQuerySub.sub = this.sub; + jQuerySub.fn.init = function init( selector, context ) { + if ( context && context instanceof jQuery && !(context instanceof jQuerySub) ) { + context = jQuerySub( context ); + } + + return jQuery.fn.init.call( this, selector, context, rootjQuerySub ); + }; + jQuerySub.fn.init.prototype = jQuerySub.fn; + var rootjQuerySub = jQuerySub(document); + return jQuerySub; + }, + + browser: {} +}); + +// Populate the class2type map +jQuery.each("Boolean Number String Function Array Date RegExp Object".split(" "), function(i, name) { + class2type[ "[object " + name + "]" ] = name.toLowerCase(); +}); + +browserMatch = jQuery.uaMatch( userAgent ); +if ( browserMatch.browser ) { + jQuery.browser[ browserMatch.browser ] = true; + jQuery.browser.version = browserMatch.version; +} + +// Deprecated, use jQuery.browser.webkit instead +if ( jQuery.browser.webkit ) { + jQuery.browser.safari = true; +} + +// IE doesn't match non-breaking spaces with \s +if ( rnotwhite.test( "\xA0" ) ) { + trimLeft = /^[\s\xA0]+/; + trimRight = /[\s\xA0]+$/; +} + +// All jQuery objects should point back to these +rootjQuery = jQuery(document); + +// Cleanup functions for the document ready method +if ( document.addEventListener ) { + DOMContentLoaded = function() { + document.removeEventListener( "DOMContentLoaded", DOMContentLoaded, false ); + jQuery.ready(); + }; + +} else if ( document.attachEvent ) { + DOMContentLoaded = function() { + // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443). + if ( document.readyState === "complete" ) { + document.detachEvent( "onreadystatechange", DOMContentLoaded ); + jQuery.ready(); + } + }; +} + +// The DOM ready check for Internet Explorer +function doScrollCheck() { + if ( jQuery.isReady ) { + return; + } + + try { + // If IE is used, use the trick by Diego Perini + // http://javascript.nwbox.com/IEContentLoaded/ + document.documentElement.doScroll("left"); + } catch(e) { + setTimeout( doScrollCheck, 1 ); + return; + } + + // and execute any waiting functions + jQuery.ready(); +} + +// Expose jQuery as an AMD module, but only for AMD loaders that +// understand the issues with loading multiple versions of jQuery +// in a page that all might call define(). The loader will indicate +// they have special allowances for multiple jQuery versions by +// specifying define.amd.jQuery = true. Register as a named module, +// since jQuery can be concatenated with other files that may use define, +// but not use a proper concatenation script that understands anonymous +// AMD modules. A named AMD is safest and most robust way to register. +// Lowercase jquery is used because AMD module names are derived from +// file names, and jQuery is normally delivered in a lowercase file name. +if ( typeof define === "function" && define.amd && define.amd.jQuery ) { + define( "jquery", [], function () { return jQuery; } ); +} + +return jQuery; + +})(); + + +// String to Object flags format cache +var flagsCache = {}; + +// Convert String-formatted flags into Object-formatted ones and store in cache +function createFlags( flags ) { + var object = flagsCache[ flags ] = {}, + i, length; + flags = flags.split( /\s+/ ); + for ( i = 0, length = flags.length; i < length; i++ ) { + object[ flags[i] ] = true; + } + return object; +} + +/* + * Create a callback list using the following parameters: + * + * flags: an optional list of space-separated flags that will change how + * the callback list behaves + * + * By default a callback list will act like an event callback list and can be + * "fired" multiple times. + * + * Possible flags: + * + * once: will ensure the callback list can only be fired once (like a Deferred) + * + * memory: will keep track of previous values and will call any callback added + * after the list has been fired right away with the latest "memorized" + * values (like a Deferred) + * + * unique: will ensure a callback can only be added once (no duplicate in the list) + * + * stopOnFalse: interrupt callings when a callback returns false + * + */ +jQuery.Callbacks = function( flags ) { + + // Convert flags from String-formatted to Object-formatted + // (we check in cache first) + flags = flags ? ( flagsCache[ flags ] || createFlags( flags ) ) : {}; + + var // Actual callback list + list = [], + // Stack of fire calls for repeatable lists + stack = [], + // Last fire value (for non-forgettable lists) + memory, + // Flag to know if list is currently firing + firing, + // First callback to fire (used internally by add and fireWith) + firingStart, + // End of the loop when firing + firingLength, + // Index of currently firing callback (modified by remove if needed) + firingIndex, + // Add one or several callbacks to the list + add = function( args ) { + var i, + length, + elem, + type, + actual; + for ( i = 0, length = args.length; i < length; i++ ) { + elem = args[ i ]; + type = jQuery.type( elem ); + if ( type === "array" ) { + // Inspect recursively + add( elem ); + } else if ( type === "function" ) { + // Add if not in unique mode and callback is not in + if ( !flags.unique || !self.has( elem ) ) { + list.push( elem ); + } + } + } + }, + // Fire callbacks + fire = function( context, args ) { + args = args || []; + memory = !flags.memory || [ context, args ]; + firing = true; + firingIndex = firingStart || 0; + firingStart = 0; + firingLength = list.length; + for ( ; list && firingIndex < firingLength; firingIndex++ ) { + if ( list[ firingIndex ].apply( context, args ) === false && flags.stopOnFalse ) { + memory = true; // Mark as halted + break; + } + } + firing = false; + if ( list ) { + if ( !flags.once ) { + if ( stack && stack.length ) { + memory = stack.shift(); + self.fireWith( memory[ 0 ], memory[ 1 ] ); + } + } else if ( memory === true ) { + self.disable(); + } else { + list = []; + } + } + }, + // Actual Callbacks object + self = { + // Add a callback or a collection of callbacks to the list + add: function() { + if ( list ) { + var length = list.length; + add( arguments ); + // Do we need to add the callbacks to the + // current firing batch? + if ( firing ) { + firingLength = list.length; + // With memory, if we're not firing then + // we should call right away, unless previous + // firing was halted (stopOnFalse) + } else if ( memory && memory !== true ) { + firingStart = length; + fire( memory[ 0 ], memory[ 1 ] ); + } + } + return this; + }, + // Remove a callback from the list + remove: function() { + if ( list ) { + var args = arguments, + argIndex = 0, + argLength = args.length; + for ( ; argIndex < argLength ; argIndex++ ) { + for ( var i = 0; i < list.length; i++ ) { + if ( args[ argIndex ] === list[ i ] ) { + // Handle firingIndex and firingLength + if ( firing ) { + if ( i <= firingLength ) { + firingLength--; + if ( i <= firingIndex ) { + firingIndex--; + } + } + } + // Remove the element + list.splice( i--, 1 ); + // If we have some unicity property then + // we only need to do this once + if ( flags.unique ) { + break; + } + } + } + } + } + return this; + }, + // Control if a given callback is in the list + has: function( fn ) { + if ( list ) { + var i = 0, + length = list.length; + for ( ; i < length; i++ ) { + if ( fn === list[ i ] ) { + return true; + } + } + } + return false; + }, + // Remove all callbacks from the list + empty: function() { + list = []; + return this; + }, + // Have the list do nothing anymore + disable: function() { + list = stack = memory = undefined; + return this; + }, + // Is it disabled? + disabled: function() { + return !list; + }, + // Lock the list in its current state + lock: function() { + stack = undefined; + if ( !memory || memory === true ) { + self.disable(); + } + return this; + }, + // Is it locked? + locked: function() { + return !stack; + }, + // Call all callbacks with the given context and arguments + fireWith: function( context, args ) { + if ( stack ) { + if ( firing ) { + if ( !flags.once ) { + stack.push( [ context, args ] ); + } + } else if ( !( flags.once && memory ) ) { + fire( context, args ); + } + } + return this; + }, + // Call all the callbacks with the given arguments + fire: function() { + self.fireWith( this, arguments ); + return this; + }, + // To know if the callbacks have already been called at least once + fired: function() { + return !!memory; + } + }; + + return self; +}; + + + + +var // Static reference to slice + sliceDeferred = [].slice; + +jQuery.extend({ + + Deferred: function( func ) { + var doneList = jQuery.Callbacks( "once memory" ), + failList = jQuery.Callbacks( "once memory" ), + progressList = jQuery.Callbacks( "memory" ), + state = "pending", + lists = { + resolve: doneList, + reject: failList, + notify: progressList + }, + promise = { + done: doneList.add, + fail: failList.add, + progress: progressList.add, + + state: function() { + return state; + }, + + // Deprecated + isResolved: doneList.fired, + isRejected: failList.fired, + + then: function( doneCallbacks, failCallbacks, progressCallbacks ) { + deferred.done( doneCallbacks ).fail( failCallbacks ).progress( progressCallbacks ); + return this; + }, + always: function() { + return deferred.done.apply( deferred, arguments ).fail.apply( deferred, arguments ); + }, + pipe: function( fnDone, fnFail, fnProgress ) { + return jQuery.Deferred(function( newDefer ) { + jQuery.each( { + done: [ fnDone, "resolve" ], + fail: [ fnFail, "reject" ], + progress: [ fnProgress, "notify" ] + }, function( handler, data ) { + var fn = data[ 0 ], + action = data[ 1 ], + returned; + if ( jQuery.isFunction( fn ) ) { + deferred[ handler ](function() { + returned = fn.apply( this, arguments ); + if ( returned && jQuery.isFunction( returned.promise ) ) { + returned.promise().then( newDefer.resolve, newDefer.reject, newDefer.notify ); + } else { + newDefer[ action + "With" ]( this === deferred ? newDefer : this, [ returned ] ); + } + }); + } else { + deferred[ handler ]( newDefer[ action ] ); + } + }); + }).promise(); + }, + // Get a promise for this deferred + // If obj is provided, the promise aspect is added to the object + promise: function( obj ) { + if ( obj == null ) { + obj = promise; + } else { + for( var key in promise ) { + obj[ key ] = promise[ key ]; + } + } + return obj; + } + }, + deferred = promise.promise({}), + key; + + for ( key in lists ) { + deferred[ key ] = lists[ key ].fire; + deferred[ key + "With" ] = lists[ key ].fireWith; + } + + // Handle state + deferred.done( function() { + state = "resolved"; + }, failList.disable, progressList.lock ).fail( function() { + state = "rejected"; + }, doneList.disable, progressList.lock ); + + // Call given func if any + if ( func ) { + func.call( deferred, deferred ); + } + + // All done! + return deferred; + }, + + // Deferred helper + when: function( firstParam ) { + var args = sliceDeferred.call( arguments, 0 ), + i = 0, + length = args.length, + pValues = new Array( length ), + count = length, + pCount = length, + deferred = length <= 1 && firstParam && jQuery.isFunction( firstParam.promise ) ? + firstParam : + jQuery.Deferred(), + promise = deferred.promise(); + function resolveFunc( i ) { + return function( value ) { + args[ i ] = arguments.length > 1 ? sliceDeferred.call( arguments, 0 ) : value; + if ( !( --count ) ) { + deferred.resolveWith( deferred, args ); + } + }; + } + function progressFunc( i ) { + return function( value ) { + pValues[ i ] = arguments.length > 1 ? sliceDeferred.call( arguments, 0 ) : value; + deferred.notifyWith( promise, pValues ); + }; + } + if ( length > 1 ) { + for( ; i < length; i++ ) { + if ( args[ i ] && args[ i ].promise && jQuery.isFunction( args[ i ].promise ) ) { + args[ i ].promise().then( resolveFunc(i), deferred.reject, progressFunc(i) ); + } else { + --count; + } + } + if ( !count ) { + deferred.resolveWith( deferred, args ); + } + } else if ( deferred !== firstParam ) { + deferred.resolveWith( deferred, length ? [ firstParam ] : [] ); + } + return promise; + } +}); + + + + +jQuery.support = (function() { + + var div = document.createElement( "div" ), + documentElement = document.documentElement, + all, + a, + select, + opt, + input, + marginDiv, + support, + fragment, + body, + testElementParent, + testElement, + testElementStyle, + tds, + events, + eventName, + i, + isSupported, + offsetSupport; + + // Preliminary tests + div.setAttribute("className", "t"); + div.innerHTML = "
      a"; + + + all = div.getElementsByTagName( "*" ); + a = div.getElementsByTagName( "a" )[ 0 ]; + + // Can't get basic test support + if ( !all || !all.length || !a ) { + return {}; + } + + // First batch of supports tests + select = document.createElement( "select" ); + opt = select.appendChild( document.createElement("option") ); + input = div.getElementsByTagName( "input" )[ 0 ]; + + support = { + // IE strips leading whitespace when .innerHTML is used + leadingWhitespace: ( div.firstChild.nodeType === 3 ), + + // Make sure that tbody elements aren't automatically inserted + // IE will insert them into empty tables + tbody: !div.getElementsByTagName( "tbody" ).length, + + // Make sure that link elements get serialized correctly by innerHTML + // This requires a wrapper element in IE + htmlSerialize: !!div.getElementsByTagName( "link" ).length, + + // Get the style information from getAttribute + // (IE uses .cssText instead) + style: /top/.test( a.getAttribute("style") ), + + // Make sure that URLs aren't manipulated + // (IE normalizes it by default) + hrefNormalized: ( a.getAttribute( "href" ) === "/a" ), + + // Make sure that element opacity exists + // (IE uses filter instead) + // Use a regex to work around a WebKit issue. See #5145 + opacity: /^0.55/.test( a.style.opacity ), + + // Verify style float existence + // (IE uses styleFloat instead of cssFloat) + cssFloat: !!a.style.cssFloat, + + // Make sure unknown elements (like HTML5 elems) are handled appropriately + unknownElems: !!div.getElementsByTagName( "nav" ).length, + + // Make sure that if no value is specified for a checkbox + // that it defaults to "on". + // (WebKit defaults to "" instead) + checkOn: ( input.value === "on" ), + + // Make sure that a selected-by-default option has a working selected property. + // (WebKit defaults to false instead of true, IE too, if it's in an optgroup) + optSelected: opt.selected, + + // Test setAttribute on camelCase class. If it works, we need attrFixes when doing get/setAttribute (ie6/7) + getSetAttribute: div.className !== "t", + + // Will be defined later + submitBubbles: true, + changeBubbles: true, + focusinBubbles: false, + deleteExpando: true, + noCloneEvent: true, + inlineBlockNeedsLayout: false, + shrinkWrapBlocks: false, + reliableMarginRight: true + }; + + // Make sure checked status is properly cloned + input.checked = true; + support.noCloneChecked = input.cloneNode( true ).checked; + + // Make sure that the options inside disabled selects aren't marked as disabled + // (WebKit marks them as disabled) + select.disabled = true; + support.optDisabled = !opt.disabled; + + // Test to see if it's possible to delete an expando from an element + // Fails in Internet Explorer + try { + delete div.test; + } catch( e ) { + support.deleteExpando = false; + } + + if ( !div.addEventListener && div.attachEvent && div.fireEvent ) { + div.attachEvent( "onclick", function() { + // Cloning a node shouldn't copy over any + // bound event handlers (IE does this) + support.noCloneEvent = false; + }); + div.cloneNode( true ).fireEvent( "onclick" ); + } + + // Check if a radio maintains its value + // after being appended to the DOM + input = document.createElement("input"); + input.value = "t"; + input.setAttribute("type", "radio"); + support.radioValue = input.value === "t"; + + input.setAttribute("checked", "checked"); + div.appendChild( input ); + fragment = document.createDocumentFragment(); + fragment.appendChild( div.firstChild ); + + // WebKit doesn't clone checked state correctly in fragments + support.checkClone = fragment.cloneNode( true ).cloneNode( true ).lastChild.checked; + + div.innerHTML = ""; + + // Figure out if the W3C box model works as expected + div.style.width = div.style.paddingLeft = "1px"; + + // We don't want to do body-related feature tests on frameset + // documents, which lack a body. So we use + // document.getElementsByTagName("body")[0], which is undefined in + // frameset documents, while document.body isn’t. (7398) + body = document.getElementsByTagName("body")[ 0 ]; + // We use our own, invisible, body unless the body is already present + // in which case we use a div (#9239) + testElement = document.createElement( body ? "div" : "body" ); + testElementStyle = { + visibility: "hidden", + width: 0, + height: 0, + border: 0, + margin: 0, + background: "none" + }; + if ( body ) { + jQuery.extend( testElementStyle, { + position: "absolute", + left: "-999px", + top: "-999px" + }); + } + for ( i in testElementStyle ) { + testElement.style[ i ] = testElementStyle[ i ]; + } + testElement.appendChild( div ); + testElementParent = body || documentElement; + testElementParent.insertBefore( testElement, testElementParent.firstChild ); + + // Check if a disconnected checkbox will retain its checked + // value of true after appended to the DOM (IE6/7) + support.appendChecked = input.checked; + + support.boxModel = div.offsetWidth === 2; + + if ( "zoom" in div.style ) { + // Check if natively block-level elements act like inline-block + // elements when setting their display to 'inline' and giving + // them layout + // (IE < 8 does this) + div.style.display = "inline"; + div.style.zoom = 1; + support.inlineBlockNeedsLayout = ( div.offsetWidth === 2 ); + + // Check if elements with layout shrink-wrap their children + // (IE 6 does this) + div.style.display = ""; + div.innerHTML = "
      "; + support.shrinkWrapBlocks = ( div.offsetWidth !== 2 ); + } + + div.innerHTML = "
      t
      "; + tds = div.getElementsByTagName( "td" ); + + // Check if table cells still have offsetWidth/Height when they are set + // to display:none and there are still other visible table cells in a + // table row; if so, offsetWidth/Height are not reliable for use when + // determining if an element has been hidden directly using + // display:none (it is still safe to use offsets if a parent element is + // hidden; don safety goggles and see bug #4512 for more information). + // (only IE 8 fails this test) + isSupported = ( tds[ 0 ].offsetHeight === 0 ); + + tds[ 0 ].style.display = ""; + tds[ 1 ].style.display = "none"; + + // Check if empty table cells still have offsetWidth/Height + // (IE < 8 fail this test) + support.reliableHiddenOffsets = isSupported && ( tds[ 0 ].offsetHeight === 0 ); + div.innerHTML = ""; + + // Check if div with explicit width and no margin-right incorrectly + // gets computed margin-right based on width of container. For more + // info see bug #3333 + // Fails in WebKit before Feb 2011 nightlies + // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right + if ( document.defaultView && document.defaultView.getComputedStyle ) { + marginDiv = document.createElement( "div" ); + marginDiv.style.width = "0"; + marginDiv.style.marginRight = "0"; + div.appendChild( marginDiv ); + support.reliableMarginRight = + ( parseInt( ( document.defaultView.getComputedStyle( marginDiv, null ) || { marginRight: 0 } ).marginRight, 10 ) || 0 ) === 0; + } + + // Remove the body element we added + testElement.innerHTML = ""; + + // Technique from Juriy Zaytsev + // http://perfectionkills.com/detecting-event-support-without-browser-sniffing/ + // We only care about the case where non-standard event systems + // are used, namely in IE. Short-circuiting here helps us to + // avoid an eval call (in setAttribute) which can cause CSP + // to go haywire. See: https://developer.mozilla.org/en/Security/CSP + if ( div.attachEvent ) { + for( i in { + submit: 1, + change: 1, + focusin: 1 + } ) { + eventName = "on" + i; + isSupported = ( eventName in div ); + if ( !isSupported ) { + div.setAttribute( eventName, "return;" ); + isSupported = ( typeof div[ eventName ] === "function" ); + } + support[ i + "Bubbles" ] = isSupported; + } + } + + // Determine fixed-position support early + testElement.style.position = "static"; + testElement.style.top = "0px"; + testElement.style.marginTop = "1px"; + offsetSupport = (function( body, container ) { + + var outer, inner, table, td, supports, + bodyMarginTop = parseFloat( body.style.marginTop ) || 0, + ptlm = "position:absolute;top:0;left:0;width:1px;height:1px;margin:0;", + style = "style='" + ptlm + "border:5px solid #000;padding:0;'", + html = "
      " + + "" + + "
      "; + + container.style.cssText = ptlm + "border:0;visibility:hidden"; + + container.innerHTML = html; + body.insertBefore( container, body.firstChild ); + outer = container.firstChild; + inner = outer.firstChild; + td = outer.nextSibling.firstChild.firstChild; + + supports = { + doesNotAddBorder: (inner.offsetTop !== 5), + doesAddBorderForTableAndCells: (td.offsetTop === 5) + }; + + inner.style.position = "fixed"; + inner.style.top = "20px"; + + // safari subtracts parent border width here which is 5px + supports.supportsFixedPosition = (inner.offsetTop === 20 || inner.offsetTop === 15); + inner.style.position = inner.style.top = ""; + + outer.style.overflow = "hidden"; + outer.style.position = "relative"; + + supports.subtractsBorderForOverflowNotVisible = (inner.offsetTop === -5); + supports.doesNotIncludeMarginInBodyOffset = (body.offsetTop !== bodyMarginTop); + + return supports; + + })( testElement, div ); + + jQuery.extend( support, offsetSupport ); + testElementParent.removeChild( testElement ); + + // Null connected elements to avoid leaks in IE + testElement = fragment = select = opt = body = marginDiv = div = input = null; + + return support; +})(); + +// Keep track of boxModel +jQuery.boxModel = jQuery.support.boxModel; + + + + +var rbrace = /^(?:\{.*\}|\[.*\])$/, + rmultiDash = /([A-Z])/g; + +jQuery.extend({ + cache: {}, + + // Please use with caution + uuid: 0, + + // Unique for each copy of jQuery on the page + // Non-digits removed to match rinlinejQuery + expando: "jQuery" + ( jQuery.fn.jquery + Math.random() ).replace( /\D/g, "" ), + + // The following elements throw uncatchable exceptions if you + // attempt to add expando properties to them. + noData: { + "embed": true, + // Ban all objects except for Flash (which handle expandos) + "object": "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000", + "applet": true + }, + + hasData: function( elem ) { + elem = elem.nodeType ? jQuery.cache[ elem[jQuery.expando] ] : elem[ jQuery.expando ]; + return !!elem && !isEmptyDataObject( elem ); + }, + + data: function( elem, name, data, pvt /* Internal Use Only */ ) { + if ( !jQuery.acceptData( elem ) ) { + return; + } + + var thisCache, ret, + internalKey = jQuery.expando, + getByName = typeof name === "string", + + // We have to handle DOM nodes and JS objects differently because IE6-7 + // can't GC object references properly across the DOM-JS boundary + isNode = elem.nodeType, + + // Only DOM nodes need the global jQuery cache; JS object data is + // attached directly to the object so GC can occur automatically + cache = isNode ? jQuery.cache : elem, + + // Only defining an ID for JS objects if its cache already exists allows + // the code to shortcut on the same path as a DOM node with no cache + id = isNode ? elem[ jQuery.expando ] : elem[ jQuery.expando ] && jQuery.expando; + + // Avoid doing any more work than we need to when trying to get data on an + // object that has no data at all + if ( (!id || !cache[id] || (!pvt && !cache[id].data)) && getByName && data === undefined ) { + return; + } + + if ( !id ) { + // Only DOM nodes need a new unique ID for each element since their data + // ends up in the global cache + if ( isNode ) { + elem[ jQuery.expando ] = id = ++jQuery.uuid; + } else { + id = jQuery.expando; + } + } + + if ( !cache[ id ] ) { + cache[ id ] = {}; + + // Avoids exposing jQuery metadata on plain JS objects when the object + // is serialized using JSON.stringify + if ( !isNode ) { + cache[ id ].toJSON = jQuery.noop; + } + } + + // An object can be passed to jQuery.data instead of a key/value pair; this gets + // shallow copied over onto the existing cache + if ( typeof name === "object" || typeof name === "function" ) { + if ( pvt ) { + cache[ id ] = jQuery.extend( cache[ id ], name ); + } else { + cache[ id ].data = jQuery.extend( cache[ id ].data, name ); + } + } + + thisCache = cache[ id ]; + + // jQuery data() is stored in a separate object inside the object's internal data + // cache in order to avoid key collisions between internal data and user-defined + // data. + if ( !pvt ) { + if ( !thisCache.data ) { + thisCache.data = {}; + } + + thisCache = thisCache.data; + } + + if ( data !== undefined ) { + thisCache[ jQuery.camelCase( name ) ] = data; + } + + // TODO: This is a hack for 1.5 ONLY. It will be removed in 1.6. Users should + // not attempt to inspect the internal events object using jQuery.data, as this + // internal data object is undocumented and subject to change. + if ( name === "events" && !thisCache[name] ) { + return thisCache[ internalKey ] && thisCache[ internalKey ].events; + } + + // Check for both converted-to-camel and non-converted data property names + // If a data property was specified + if ( getByName ) { + + // First Try to find as-is property data + ret = thisCache[ name ]; + + // Test for null|undefined property data + if ( ret == null ) { + + // Try to find the camelCased property + ret = thisCache[ jQuery.camelCase( name ) ]; + } + } else { + ret = thisCache; + } + + return ret; + }, + + removeData: function( elem, name, pvt /* Internal Use Only */ ) { + if ( !jQuery.acceptData( elem ) ) { + return; + } + + var thisCache, i, l, + + // Reference to internal data cache key + internalKey = jQuery.expando, + + isNode = elem.nodeType, + + // See jQuery.data for more information + cache = isNode ? jQuery.cache : elem, + + // See jQuery.data for more information + id = isNode ? elem[ jQuery.expando ] : jQuery.expando; + + // If there is already no cache entry for this object, there is no + // purpose in continuing + if ( !cache[ id ] ) { + return; + } + + if ( name ) { + + thisCache = pvt ? cache[ id ] : cache[ id ].data; + + if ( thisCache ) { + + // Support space separated names + if ( jQuery.isArray( name ) ) { + name = name; + } else if ( name in thisCache ) { + name = [ name ]; + } else { + + // split the camel cased version by spaces + name = jQuery.camelCase( name ); + if ( name in thisCache ) { + name = [ name ]; + } else { + name = name.split( " " ); + } + } + + for ( i = 0, l = name.length; i < l; i++ ) { + delete thisCache[ name[i] ]; + } + + // If there is no data left in the cache, we want to continue + // and let the cache object itself get destroyed + if ( !( pvt ? isEmptyDataObject : jQuery.isEmptyObject )( thisCache ) ) { + return; + } + } + } + + // See jQuery.data for more information + if ( !pvt ) { + delete cache[ id ].data; + + // Don't destroy the parent cache unless the internal data object + // had been the only thing left in it + if ( !isEmptyDataObject(cache[ id ]) ) { + return; + } + } + + // Browsers that fail expando deletion also refuse to delete expandos on + // the window, but it will allow it on all other JS objects; other browsers + // don't care + // Ensure that `cache` is not a window object #10080 + if ( jQuery.support.deleteExpando || !cache.setInterval ) { + delete cache[ id ]; + } else { + cache[ id ] = null; + } + + // We destroyed the cache and need to eliminate the expando on the node to avoid + // false lookups in the cache for entries that no longer exist + if ( isNode ) { + // IE does not allow us to delete expando properties from nodes, + // nor does it have a removeAttribute function on Document nodes; + // we must handle all of these cases + if ( jQuery.support.deleteExpando ) { + delete elem[ jQuery.expando ]; + } else if ( elem.removeAttribute ) { + elem.removeAttribute( jQuery.expando ); + } else { + elem[ jQuery.expando ] = null; + } + } + }, + + // For internal use only. + _data: function( elem, name, data ) { + return jQuery.data( elem, name, data, true ); + }, + + // A method for determining if a DOM node can handle the data expando + acceptData: function( elem ) { + if ( elem.nodeName ) { + var match = jQuery.noData[ elem.nodeName.toLowerCase() ]; + + if ( match ) { + return !(match === true || elem.getAttribute("classid") !== match); + } + } + + return true; + } +}); + +jQuery.fn.extend({ + data: function( key, value ) { + var parts, attr, name, + data = null; + + if ( typeof key === "undefined" ) { + if ( this.length ) { + data = jQuery.data( this[0] ); + + if ( this[0].nodeType === 1 && !jQuery._data( this[0], "parsedAttrs" ) ) { + attr = this[0].attributes; + for ( var i = 0, l = attr.length; i < l; i++ ) { + name = attr[i].name; + + if ( name.indexOf( "data-" ) === 0 ) { + name = jQuery.camelCase( name.substring(5) ); + + dataAttr( this[0], name, data[ name ] ); + } + } + jQuery._data( this[0], "parsedAttrs", true ); + } + } + + return data; + + } else if ( typeof key === "object" ) { + return this.each(function() { + jQuery.data( this, key ); + }); + } + + parts = key.split("."); + parts[1] = parts[1] ? "." + parts[1] : ""; + + if ( value === undefined ) { + data = this.triggerHandler("getData" + parts[1] + "!", [parts[0]]); + + // Try to fetch any internally stored data first + if ( data === undefined && this.length ) { + data = jQuery.data( this[0], key ); + data = dataAttr( this[0], key, data ); + } + + return data === undefined && parts[1] ? + this.data( parts[0] ) : + data; + + } else { + return this.each(function() { + var $this = jQuery( this ), + args = [ parts[0], value ]; + + $this.triggerHandler( "setData" + parts[1] + "!", args ); + jQuery.data( this, key, value ); + $this.triggerHandler( "changeData" + parts[1] + "!", args ); + }); + } + }, + + removeData: function( key ) { + return this.each(function() { + jQuery.removeData( this, key ); + }); + } +}); + +function dataAttr( elem, key, data ) { + // If nothing was found internally, try to fetch any + // data from the HTML5 data-* attribute + if ( data === undefined && elem.nodeType === 1 ) { + + var name = "data-" + key.replace( rmultiDash, "-$1" ).toLowerCase(); + + data = elem.getAttribute( name ); + + if ( typeof data === "string" ) { + try { + data = data === "true" ? true : + data === "false" ? false : + data === "null" ? null : + jQuery.isNumeric( data ) ? parseFloat( data ) : + rbrace.test( data ) ? jQuery.parseJSON( data ) : + data; + } catch( e ) {} + + // Make sure we set the data so it isn't changed later + jQuery.data( elem, key, data ); + + } else { + data = undefined; + } + } + + return data; +} + +// checks a cache object for emptiness +function isEmptyDataObject( obj ) { + for ( var name in obj ) { + + // if the public data object is empty, the private is still empty + if ( name === "data" && jQuery.isEmptyObject( obj[name] ) ) { + continue; + } + if ( name !== "toJSON" ) { + return false; + } + } + + return true; +} + + + + +function handleQueueMarkDefer( elem, type, src ) { + var deferDataKey = type + "defer", + queueDataKey = type + "queue", + markDataKey = type + "mark", + defer = jQuery._data( elem, deferDataKey ); + if ( defer && + ( src === "queue" || !jQuery._data(elem, queueDataKey) ) && + ( src === "mark" || !jQuery._data(elem, markDataKey) ) ) { + // Give room for hard-coded callbacks to fire first + // and eventually mark/queue something else on the element + setTimeout( function() { + if ( !jQuery._data( elem, queueDataKey ) && + !jQuery._data( elem, markDataKey ) ) { + jQuery.removeData( elem, deferDataKey, true ); + defer.fire(); + } + }, 0 ); + } +} + +jQuery.extend({ + + _mark: function( elem, type ) { + if ( elem ) { + type = (type || "fx") + "mark"; + jQuery._data( elem, type, (jQuery._data( elem, type ) || 0) + 1 ); + } + }, + + _unmark: function( force, elem, type ) { + if ( force !== true ) { + type = elem; + elem = force; + force = false; + } + if ( elem ) { + type = type || "fx"; + var key = type + "mark", + count = force ? 0 : ( (jQuery._data( elem, key ) || 1) - 1 ); + if ( count ) { + jQuery._data( elem, key, count ); + } else { + jQuery.removeData( elem, key, true ); + handleQueueMarkDefer( elem, type, "mark" ); + } + } + }, + + queue: function( elem, type, data ) { + var q; + if ( elem ) { + type = (type || "fx") + "queue"; + q = jQuery._data( elem, type ); + + // Speed up dequeue by getting out quickly if this is just a lookup + if ( data ) { + if ( !q || jQuery.isArray(data) ) { + q = jQuery._data( elem, type, jQuery.makeArray(data) ); + } else { + q.push( data ); + } + } + return q || []; + } + }, + + dequeue: function( elem, type ) { + type = type || "fx"; + + var queue = jQuery.queue( elem, type ), + fn = queue.shift(), + runner = {}; + + // If the fx queue is dequeued, always remove the progress sentinel + if ( fn === "inprogress" ) { + fn = queue.shift(); + } + + if ( fn ) { + // Add a progress sentinel to prevent the fx queue from being + // automatically dequeued + if ( type === "fx" ) { + queue.unshift( "inprogress" ); + } + + jQuery._data( elem, type + ".run", runner ); + fn.call( elem, function() { + jQuery.dequeue( elem, type ); + }, runner ); + } + + if ( !queue.length ) { + jQuery.removeData( elem, type + "queue " + type + ".run", true ); + handleQueueMarkDefer( elem, type, "queue" ); + } + } +}); + +jQuery.fn.extend({ + queue: function( type, data ) { + if ( typeof type !== "string" ) { + data = type; + type = "fx"; + } + + if ( data === undefined ) { + return jQuery.queue( this[0], type ); + } + return this.each(function() { + var queue = jQuery.queue( this, type, data ); + + if ( type === "fx" && queue[0] !== "inprogress" ) { + jQuery.dequeue( this, type ); + } + }); + }, + dequeue: function( type ) { + return this.each(function() { + jQuery.dequeue( this, type ); + }); + }, + // Based off of the plugin by Clint Helfers, with permission. + // http://blindsignals.com/index.php/2009/07/jquery-delay/ + delay: function( time, type ) { + time = jQuery.fx ? jQuery.fx.speeds[ time ] || time : time; + type = type || "fx"; + + return this.queue( type, function( next, runner ) { + var timeout = setTimeout( next, time ); + runner.stop = function() { + clearTimeout( timeout ); + }; + }); + }, + clearQueue: function( type ) { + return this.queue( type || "fx", [] ); + }, + // Get a promise resolved when queues of a certain type + // are emptied (fx is the type by default) + promise: function( type, object ) { + if ( typeof type !== "string" ) { + object = type; + type = undefined; + } + type = type || "fx"; + var defer = jQuery.Deferred(), + elements = this, + i = elements.length, + count = 1, + deferDataKey = type + "defer", + queueDataKey = type + "queue", + markDataKey = type + "mark", + tmp; + function resolve() { + if ( !( --count ) ) { + defer.resolveWith( elements, [ elements ] ); + } + } + while( i-- ) { + if (( tmp = jQuery.data( elements[ i ], deferDataKey, undefined, true ) || + ( jQuery.data( elements[ i ], queueDataKey, undefined, true ) || + jQuery.data( elements[ i ], markDataKey, undefined, true ) ) && + jQuery.data( elements[ i ], deferDataKey, jQuery.Callbacks( "once memory" ), true ) )) { + count++; + tmp.add( resolve ); + } + } + resolve(); + return defer.promise(); + } +}); + + + + +var rclass = /[\n\t\r]/g, + rspace = /\s+/, + rreturn = /\r/g, + rtype = /^(?:button|input)$/i, + rfocusable = /^(?:button|input|object|select|textarea)$/i, + rclickable = /^a(?:rea)?$/i, + rboolean = /^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i, + nodeHook, boolHook, fixSpecified; + +jQuery.fn.extend({ + attr: function( name, value ) { + return jQuery.access( this, name, value, true, jQuery.attr ); + }, + + removeAttr: function( name ) { + return this.each(function() { + jQuery.removeAttr( this, name ); + }); + }, + + prop: function( name, value ) { + return jQuery.access( this, name, value, true, jQuery.prop ); + }, + + removeProp: function( name ) { + name = jQuery.propFix[ name ] || name; + return this.each(function() { + // try/catch handles cases where IE balks (such as removing a property on window) + try { + this[ name ] = undefined; + delete this[ name ]; + } catch( e ) {} + }); + }, + + addClass: function( value ) { + var classNames, i, l, elem, + setClass, c, cl; + + if ( jQuery.isFunction( value ) ) { + return this.each(function( j ) { + jQuery( this ).addClass( value.call(this, j, this.className) ); + }); + } + + if ( value && typeof value === "string" ) { + classNames = value.split( rspace ); + + for ( i = 0, l = this.length; i < l; i++ ) { + elem = this[ i ]; + + if ( elem.nodeType === 1 ) { + if ( !elem.className && classNames.length === 1 ) { + elem.className = value; + + } else { + setClass = " " + elem.className + " "; + + for ( c = 0, cl = classNames.length; c < cl; c++ ) { + if ( !~setClass.indexOf( " " + classNames[ c ] + " " ) ) { + setClass += classNames[ c ] + " "; + } + } + elem.className = jQuery.trim( setClass ); + } + } + } + } + + return this; + }, + + removeClass: function( value ) { + var classNames, i, l, elem, className, c, cl; + + if ( jQuery.isFunction( value ) ) { + return this.each(function( j ) { + jQuery( this ).removeClass( value.call(this, j, this.className) ); + }); + } + + if ( (value && typeof value === "string") || value === undefined ) { + classNames = (value || "").split( rspace ); + + for ( i = 0, l = this.length; i < l; i++ ) { + elem = this[ i ]; + + if ( elem.nodeType === 1 && elem.className ) { + if ( value ) { + className = (" " + elem.className + " ").replace( rclass, " " ); + for ( c = 0, cl = classNames.length; c < cl; c++ ) { + className = className.replace(" " + classNames[ c ] + " ", " "); + } + elem.className = jQuery.trim( className ); + + } else { + elem.className = ""; + } + } + } + } + + return this; + }, + + toggleClass: function( value, stateVal ) { + var type = typeof value, + isBool = typeof stateVal === "boolean"; + + if ( jQuery.isFunction( value ) ) { + return this.each(function( i ) { + jQuery( this ).toggleClass( value.call(this, i, this.className, stateVal), stateVal ); + }); + } + + return this.each(function() { + if ( type === "string" ) { + // toggle individual class names + var className, + i = 0, + self = jQuery( this ), + state = stateVal, + classNames = value.split( rspace ); + + while ( (className = classNames[ i++ ]) ) { + // check each className given, space seperated list + state = isBool ? state : !self.hasClass( className ); + self[ state ? "addClass" : "removeClass" ]( className ); + } + + } else if ( type === "undefined" || type === "boolean" ) { + if ( this.className ) { + // store className if set + jQuery._data( this, "__className__", this.className ); + } + + // toggle whole className + this.className = this.className || value === false ? "" : jQuery._data( this, "__className__" ) || ""; + } + }); + }, + + hasClass: function( selector ) { + var className = " " + selector + " "; + for ( var i = 0, l = this.length; i < l; i++ ) { + if ( this[i].nodeType === 1 && (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) > -1 ) { + return true; + } + } + + return false; + }, + + val: function( value ) { + var hooks, ret, + elem = this[0]; + + if ( !arguments.length ) { + if ( elem ) { + hooks = jQuery.valHooks[ elem.nodeName.toLowerCase() ] || jQuery.valHooks[ elem.type ]; + + if ( hooks && "get" in hooks && (ret = hooks.get( elem, "value" )) !== undefined ) { + return ret; + } + + ret = elem.value; + + return typeof ret === "string" ? + // handle most common string cases + ret.replace(rreturn, "") : + // handle cases where value is null/undef or number + ret == null ? "" : ret; + } + + return undefined; + } + + var isFunction = jQuery.isFunction( value ); + + return this.each(function( i ) { + var self = jQuery(this), val; + + if ( this.nodeType !== 1 ) { + return; + } + + if ( isFunction ) { + val = value.call( this, i, self.val() ); + } else { + val = value; + } + + // Treat null/undefined as ""; convert numbers to string + if ( val == null ) { + val = ""; + } else if ( typeof val === "number" ) { + val += ""; + } else if ( jQuery.isArray( val ) ) { + val = jQuery.map(val, function ( value ) { + return value == null ? "" : value + ""; + }); + } + + hooks = jQuery.valHooks[ this.nodeName.toLowerCase() ] || jQuery.valHooks[ this.type ]; + + // If set returns undefined, fall back to normal setting + if ( !hooks || !("set" in hooks) || hooks.set( this, val, "value" ) === undefined ) { + this.value = val; + } + }); + } +}); + +jQuery.extend({ + valHooks: { + option: { + get: function( elem ) { + // attributes.value is undefined in Blackberry 4.7 but + // uses .value. See #6932 + var val = elem.attributes.value; + return !val || val.specified ? elem.value : elem.text; + } + }, + select: { + get: function( elem ) { + var value, + index = elem.selectedIndex, + values = [], + options = elem.options, + one = elem.type === "select-one"; + + // Nothing was selected + if ( index < 0 ) { + return null; + } + + // Loop through all the selected options + for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i < max; i++ ) { + var option = options[ i ]; + + // Don't return options that are disabled or in a disabled optgroup + if ( option.selected && (jQuery.support.optDisabled ? !option.disabled : option.getAttribute("disabled") === null) && + (!option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" )) ) { + + // Get the specific value for the option + value = jQuery( option ).val(); + + // We don't need an array for one selects + if ( one ) { + return value; + } + + // Multi-Selects return an array + values.push( value ); + } + } + + // Fixes Bug #2551 -- select.val() broken in IE after form.reset() + if ( one && !values.length && options.length ) { + return jQuery( options[ index ] ).val(); + } + + return values; + }, + + set: function( elem, value ) { + var values = jQuery.makeArray( value ); + + jQuery(elem).find("option").each(function() { + this.selected = jQuery.inArray( jQuery(this).val(), values ) >= 0; + }); + + if ( !values.length ) { + elem.selectedIndex = -1; + } + return values; + } + } + }, + + attrFn: { + val: true, + css: true, + html: true, + text: true, + data: true, + width: true, + height: true, + offset: true + }, + + attr: function( elem, name, value, pass ) { + var nType = elem.nodeType; + + // don't get/set attributes on text, comment and attribute nodes + if ( !elem || nType === 3 || nType === 8 || nType === 2 ) { + return undefined; + } + + if ( pass && name in jQuery.attrFn ) { + return jQuery( elem )[ name ]( value ); + } + + // Fallback to prop when attributes are not supported + if ( !("getAttribute" in elem) ) { + return jQuery.prop( elem, name, value ); + } + + var ret, hooks, + notxml = nType !== 1 || !jQuery.isXMLDoc( elem ); + + // Normalize the name if needed + if ( notxml ) { + name = name.toLowerCase(); + hooks = jQuery.attrHooks[ name ] || (rboolean.test( name ) ? boolHook : nodeHook); + } + + if ( value !== undefined ) { + + if ( value === null ) { + jQuery.removeAttr( elem, name ); + return undefined; + + } else if ( hooks && "set" in hooks && notxml && (ret = hooks.set( elem, value, name )) !== undefined ) { + return ret; + + } else { + elem.setAttribute( name, "" + value ); + return value; + } + + } else if ( hooks && "get" in hooks && notxml && (ret = hooks.get( elem, name )) !== null ) { + return ret; + + } else { + + ret = elem.getAttribute( name ); + + // Non-existent attributes return null, we normalize to undefined + return ret === null ? + undefined : + ret; + } + }, + + removeAttr: function( elem, value ) { + var propName, attrNames, name, l, + i = 0; + + if ( elem.nodeType === 1 ) { + attrNames = (value || "").split( rspace ); + l = attrNames.length; + + for ( ; i < l; i++ ) { + name = attrNames[ i ].toLowerCase(); + + // See #9699 for explanation of this approach (setting first, then removal) + jQuery.attr( elem, name, "" ); + elem.removeAttribute( name ); + + // Set corresponding property to false for boolean attributes + if ( rboolean.test( name ) && (propName = jQuery.propFix[ name ] || name) in elem ) { + elem[ propName ] = false; + } + } + } + }, + + attrHooks: { + type: { + set: function( elem, value ) { + // We can't allow the type property to be changed (since it causes problems in IE) + if ( rtype.test( elem.nodeName ) && elem.parentNode ) { + jQuery.error( "type property can't be changed" ); + } else if ( !jQuery.support.radioValue && value === "radio" && jQuery.nodeName(elem, "input") ) { + // Setting the type on a radio button after the value resets the value in IE6-9 + // Reset value to it's default in case type is set after value + // This is for element creation + var val = elem.value; + elem.setAttribute( "type", value ); + if ( val ) { + elem.value = val; + } + return value; + } + } + }, + // Use the value property for back compat + // Use the nodeHook for button elements in IE6/7 (#1954) + value: { + get: function( elem, name ) { + if ( nodeHook && jQuery.nodeName( elem, "button" ) ) { + return nodeHook.get( elem, name ); + } + return name in elem ? + elem.value : + null; + }, + set: function( elem, value, name ) { + if ( nodeHook && jQuery.nodeName( elem, "button" ) ) { + return nodeHook.set( elem, value, name ); + } + // Does not return so that setAttribute is also used + elem.value = value; + } + } + }, + + propFix: { + tabindex: "tabIndex", + readonly: "readOnly", + "for": "htmlFor", + "class": "className", + maxlength: "maxLength", + cellspacing: "cellSpacing", + cellpadding: "cellPadding", + rowspan: "rowSpan", + colspan: "colSpan", + usemap: "useMap", + frameborder: "frameBorder", + contenteditable: "contentEditable" + }, + + prop: function( elem, name, value ) { + var nType = elem.nodeType; + + // don't get/set properties on text, comment and attribute nodes + if ( !elem || nType === 3 || nType === 8 || nType === 2 ) { + return undefined; + } + + var ret, hooks, + notxml = nType !== 1 || !jQuery.isXMLDoc( elem ); + + if ( notxml ) { + // Fix name and attach hooks + name = jQuery.propFix[ name ] || name; + hooks = jQuery.propHooks[ name ]; + } + + if ( value !== undefined ) { + if ( hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ) { + return ret; + + } else { + return (elem[ name ] = value); + } + + } else { + if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== null ) { + return ret; + + } else { + return elem[ name ]; + } + } + }, + + propHooks: { + tabIndex: { + get: function( elem ) { + // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set + // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/ + var attributeNode = elem.getAttributeNode("tabindex"); + + return attributeNode && attributeNode.specified ? + parseInt( attributeNode.value, 10 ) : + rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ? + 0 : + undefined; + } + } + } +}); + +// Add the tabIndex propHook to attrHooks for back-compat (different case is intentional) +jQuery.attrHooks.tabindex = jQuery.propHooks.tabIndex; + +// Hook for boolean attributes +boolHook = { + get: function( elem, name ) { + // Align boolean attributes with corresponding properties + // Fall back to attribute presence where some booleans are not supported + var attrNode, + property = jQuery.prop( elem, name ); + return property === true || typeof property !== "boolean" && ( attrNode = elem.getAttributeNode(name) ) && attrNode.nodeValue !== false ? + name.toLowerCase() : + undefined; + }, + set: function( elem, value, name ) { + var propName; + if ( value === false ) { + // Remove boolean attributes when set to false + jQuery.removeAttr( elem, name ); + } else { + // value is true since we know at this point it's type boolean and not false + // Set boolean attributes to the same name and set the DOM property + propName = jQuery.propFix[ name ] || name; + if ( propName in elem ) { + // Only set the IDL specifically if it already exists on the element + elem[ propName ] = true; + } + + elem.setAttribute( name, name.toLowerCase() ); + } + return name; + } +}; + +// IE6/7 do not support getting/setting some attributes with get/setAttribute +if ( !jQuery.support.getSetAttribute ) { + + fixSpecified = { + name: true, + id: true + }; + + // Use this for any attribute in IE6/7 + // This fixes almost every IE6/7 issue + nodeHook = jQuery.valHooks.button = { + get: function( elem, name ) { + var ret; + ret = elem.getAttributeNode( name ); + return ret && (fixSpecified[ name ] ? ret.nodeValue !== "" : ret.specified) ? + ret.nodeValue : + undefined; + }, + set: function( elem, value, name ) { + // Set the existing or create a new attribute node + var ret = elem.getAttributeNode( name ); + if ( !ret ) { + ret = document.createAttribute( name ); + elem.setAttributeNode( ret ); + } + return (ret.nodeValue = value + ""); + } + }; + + // Apply the nodeHook to tabindex + jQuery.attrHooks.tabindex.set = nodeHook.set; + + // Set width and height to auto instead of 0 on empty string( Bug #8150 ) + // This is for removals + jQuery.each([ "width", "height" ], function( i, name ) { + jQuery.attrHooks[ name ] = jQuery.extend( jQuery.attrHooks[ name ], { + set: function( elem, value ) { + if ( value === "" ) { + elem.setAttribute( name, "auto" ); + return value; + } + } + }); + }); + + // Set contenteditable to false on removals(#10429) + // Setting to empty string throws an error as an invalid value + jQuery.attrHooks.contenteditable = { + get: nodeHook.get, + set: function( elem, value, name ) { + if ( value === "" ) { + value = "false"; + } + nodeHook.set( elem, value, name ); + } + }; +} + + +// Some attributes require a special call on IE +if ( !jQuery.support.hrefNormalized ) { + jQuery.each([ "href", "src", "width", "height" ], function( i, name ) { + jQuery.attrHooks[ name ] = jQuery.extend( jQuery.attrHooks[ name ], { + get: function( elem ) { + var ret = elem.getAttribute( name, 2 ); + return ret === null ? undefined : ret; + } + }); + }); +} + +if ( !jQuery.support.style ) { + jQuery.attrHooks.style = { + get: function( elem ) { + // Return undefined in the case of empty string + // Normalize to lowercase since IE uppercases css property names + return elem.style.cssText.toLowerCase() || undefined; + }, + set: function( elem, value ) { + return (elem.style.cssText = "" + value); + } + }; +} + +// Safari mis-reports the default selected property of an option +// Accessing the parent's selectedIndex property fixes it +if ( !jQuery.support.optSelected ) { + jQuery.propHooks.selected = jQuery.extend( jQuery.propHooks.selected, { + get: function( elem ) { + var parent = elem.parentNode; + + if ( parent ) { + parent.selectedIndex; + + // Make sure that it also works with optgroups, see #5701 + if ( parent.parentNode ) { + parent.parentNode.selectedIndex; + } + } + return null; + } + }); +} + +// Radios and checkboxes getter/setter +if ( !jQuery.support.checkOn ) { + jQuery.each([ "radio", "checkbox" ], function() { + jQuery.valHooks[ this ] = { + get: function( elem ) { + // Handle the case where in Webkit "" is returned instead of "on" if a value isn't specified + return elem.getAttribute("value") === null ? "on" : elem.value; + } + }; + }); +} +jQuery.each([ "radio", "checkbox" ], function() { + jQuery.valHooks[ this ] = jQuery.extend( jQuery.valHooks[ this ], { + set: function( elem, value ) { + if ( jQuery.isArray( value ) ) { + return (elem.checked = jQuery.inArray( jQuery(elem).val(), value ) >= 0); + } + } + }); +}); + + + + +var rnamespaces = /\.(.*)$/, + rformElems = /^(?:textarea|input|select)$/i, + rperiod = /\./g, + rspaces = / /g, + rescape = /[^\w\s.|`]/g, + rtypenamespace = /^([^\.]*)?(?:\.(.+))?$/, + rhoverHack = /\bhover(\.\S+)?/, + rkeyEvent = /^key/, + rmouseEvent = /^(?:mouse|contextmenu)|click/, + rquickIs = /^([\w\-]+)?(?:#([\w\-]+))?(?:\.([\w\-]+))?(?:\[([\w+\-]+)=["']?([\w\-]*)["']?\])?$/, + quickParse = function( selector ) { + var quick = rquickIs.exec( selector ); + if ( quick ) { + // 0 1 2 3 4 5 + // [ _, tag, id, class, attrName, attrValue ] + quick[1] = ( quick[1] || "" ).toLowerCase(); + quick[3] = quick[3] && new RegExp( "\\b" + quick[3] + "\\b" ); + } + return quick; + }, + quickIs = function( elem, m ) { + return ( + (!m[1] || elem.nodeName.toLowerCase() === m[1]) && + (!m[2] || elem.id === m[2]) && + (!m[3] || m[3].test( elem.className )) && + (!m[4] || elem.getAttribute( m[4] ) == m[5]) + ); + }; + +/* + * Helper functions for managing events -- not part of the public interface. + * Props to Dean Edwards' addEvent library for many of the ideas. + */ +jQuery.event = { + + add: function( elem, types, handler, data, selector ) { + + var elemData, eventHandle, events, + t, tns, type, namespaces, handleObj, + handleObjIn, quick, handlers, special; + + // Don't attach events to noData or text/comment nodes (allow plain objects tho) + if ( elem.nodeType === 3 || elem.nodeType === 8 || !types || !handler || !(elemData = jQuery._data( elem )) ) { + return; + } + + // Caller can pass in an object of custom data in lieu of the handler + if ( handler.handler ) { + handleObjIn = handler; + handler = handleObjIn.handler; + } + + // Make sure that the handler has a unique ID, used to find/remove it later + if ( !handler.guid ) { + handler.guid = jQuery.guid++; + } + + // Init the element's event structure and main handler, if this is the first + events = elemData.events; + if ( !events ) { + elemData.events = events = {}; + } + eventHandle = elemData.handle; + if ( !eventHandle ) { + elemData.handle = eventHandle = function( e ) { + // Discard the second event of a jQuery.event.trigger() and + // when an event is called after a page has unloaded + return typeof jQuery !== "undefined" && (!e || jQuery.event.triggered !== e.type) ? + jQuery.event.handle.apply( eventHandle.elem, arguments ) : + undefined; + }; + // Add elem as a property of the handle fn to prevent a memory leak with IE non-native events + eventHandle.elem = elem; + } + + // Handle multiple events separated by a space + // jQuery(...).bind("mouseover mouseout", fn); + types = types.replace( rhoverHack, "mouseover$1 mouseout$1" ).split( " " ); + for ( t = 0; t < types.length; t++ ) { + + tns = rtypenamespace.exec( types[t] ) || []; + type = tns[1]; + namespaces = (tns[2] || "").split( "." ).sort(); + + // If event changes its type, use the special event handlers for the changed type + special = jQuery.event.special[ type ] || {}; + + // If selector defined, determine special event api type, otherwise given type + type = ( selector ? special.delegateType : special.bindType ) || type; + + // Update special based on newly reset type + special = jQuery.event.special[ type ] || {}; + + // handleObj is passed to all event handlers + handleObj = jQuery.extend({ + type: type, + origType: tns[1], + data: data, + handler: handler, + guid: handler.guid, + selector: selector, + namespace: namespaces.join(".") + }, handleObjIn ); + + // Delegated event; pre-analyze selector so it's processed quickly on event dispatch + if ( selector ) { + handleObj.quick = quickParse( selector ); + if ( !handleObj.quick && jQuery.expr.match.POS.test( selector ) ) { + handleObj.isPositional = true; + } + } + + // Init the event handler queue if we're the first + handlers = events[ type ]; + if ( !handlers ) { + handlers = events[ type ] = []; + handlers.delegateCount = 0; + + // Only use addEventListener/attachEvent if the special events handler returns false + if ( !special.setup || special.setup.call( elem, data, namespaces, eventHandle ) === false ) { + // Bind the global event handler to the element + if ( elem.addEventListener ) { + elem.addEventListener( type, eventHandle, false ); + + } else if ( elem.attachEvent ) { + elem.attachEvent( "on" + type, eventHandle ); + } + } + } + + if ( special.add ) { + special.add.call( elem, handleObj ); + + if ( !handleObj.handler.guid ) { + handleObj.handler.guid = handler.guid; + } + } + + // Add to the element's handler list, delegates in front + if ( selector ) { + handlers.splice( handlers.delegateCount++, 0, handleObj ); + } else { + handlers.push( handleObj ); + } + + // Keep track of which events have ever been used, for event optimization + jQuery.event.global[ type ] = true; + } + + // Nullify elem to prevent memory leaks in IE + elem = null; + }, + + global: {}, + + // Detach an event or set of events from an element + remove: function( elem, types, handler, selector ) { + + var elemData = jQuery.hasData( elem ) && jQuery._data( elem ), + t, tns, type, namespaces, origCount, + j, events, special, handle, eventType, handleObj; + + if ( !elemData || !(events = elemData.events) ) { + return; + } + + // For removal, types can be an Event object + if ( types && types.type && types.handler ) { + handler = types.handler; + types = types.type; + selector = types.selector; + } + + // Once for each type.namespace in types; type may be omitted + types = (types || "").replace( rhoverHack, "mouseover$1 mouseout$1" ).split(" "); + for ( t = 0; t < types.length; t++ ) { + tns = rtypenamespace.exec( types[t] ) || []; + type = tns[1]; + namespaces = tns[2]; + + // Unbind all events (on this namespace, if provided) for the element + if ( !type ) { + namespaces = namespaces? "." + namespaces : ""; + for ( j in events ) { + jQuery.event.remove( elem, j + namespaces, handler, selector ); + } + return; + } + + special = jQuery.event.special[ type ] || {}; + type = ( selector? special.delegateType : special.bindType ) || type; + eventType = events[ type ] || []; + origCount = eventType.length; + namespaces = namespaces ? new RegExp("(^|\\.)" + namespaces.split(".").sort().join("\\.(?:.*\\.)?") + "(\\.|$)") : null; + + // Only need to loop for special events or selective removal + if ( handler || namespaces || selector || special.remove ) { + for ( j = 0; j < eventType.length; j++ ) { + handleObj = eventType[ j ]; + + if ( !handler || handler.guid === handleObj.guid ) { + if ( !namespaces || namespaces.test( handleObj.namespace ) ) { + if ( !selector || selector === handleObj.selector || selector === "**" && handleObj.selector ) { + eventType.splice( j--, 1 ); + + if ( handleObj.selector ) { + eventType.delegateCount--; + } + if ( special.remove ) { + special.remove.call( elem, handleObj ); + } + } + } + } + } + } else { + // Removing all events + eventType.length = 0; + } + + // Remove generic event handler if we removed something and no more handlers exist + // (avoids potential for endless recursion during removal of special event handlers) + if ( eventType.length === 0 && origCount !== eventType.length ) { + if ( !special.teardown || special.teardown.call( elem, namespaces ) === false ) { + jQuery.removeEvent( elem, type, elemData.handle ); + } + + delete events[ type ]; + } + } + + // Remove the expando if it's no longer used + if ( jQuery.isEmptyObject( events ) ) { + handle = elemData.handle; + if ( handle ) { + handle.elem = null; + } + + // removeData also checks for emptiness and clears the expando if empty + // so use it instead of delete + jQuery.removeData( elem, [ "events", "handle" ], true ); + } + }, + + // Events that are safe to short-circuit if no handlers are attached. + // Native DOM events should not be added, they may have inline handlers. + customEvent: { + "getData": true, + "setData": true, + "changeData": true + }, + + trigger: function( event, data, elem, onlyHandlers ) { + // Don't do events on text and comment nodes + if ( elem && (elem.nodeType === 3 || elem.nodeType === 8) ) { + return; + } + + // Event object or event type + var type = event.type || event, + namespaces = [], + cache, exclusive, i, cur, old, ontype, special, handle, eventPath, bubbleType; + + if ( type.indexOf( "!" ) >= 0 ) { + // Exclusive events trigger only for the exact event (no namespaces) + type = type.slice(0, -1); + exclusive = true; + } + + if ( type.indexOf( "." ) >= 0 ) { + // Namespaced trigger; create a regexp to match event type in handle() + namespaces = type.split("."); + type = namespaces.shift(); + namespaces.sort(); + } + + if ( (!elem || jQuery.event.customEvent[ type ]) && !jQuery.event.global[ type ] ) { + // No jQuery handlers for this event type, and it can't have inline handlers + return; + } + + // Caller can pass in an Event, Object, or just an event type string + event = typeof event === "object" ? + // jQuery.Event object + event[ jQuery.expando ] ? event : + // Object literal + new jQuery.Event( type, event ) : + // Just the event type (string) + new jQuery.Event( type ); + + event.type = type; + event.isTrigger = true; + event.exclusive = exclusive; + event.namespace = namespaces.join( "." ); + event.namespace_re = event.namespace? new RegExp("(^|\\.)" + namespaces.join("\\.(?:.*\\.)?") + "(\\.|$)") : null; + ontype = type.indexOf( ":" ) < 0 ? "on" + type : ""; + + // triggerHandler() and global events don't bubble or run the default action + if ( onlyHandlers || !elem ) { + event.preventDefault(); + } + + // Handle a global trigger + if ( !elem ) { + + // TODO: Stop taunting the data cache; remove global events and always attach to document + cache = jQuery.cache; + event.stopPropagation(); + for ( i in cache ) { + if ( cache[ i ].events && cache[ i ].events[ type ] ) { + jQuery.event.trigger( event, data, cache[ i ].handle.elem ); + } + } + return; + } + + // Clean up the event in case it is being reused + event.result = undefined; + if ( !event.target ) { + event.target = elem; + } + + // Clone any incoming data and prepend the event, creating the handler arg list + data = data != null ? jQuery.makeArray( data ) : []; + data.unshift( event ); + + // Allow special events to draw outside the lines + special = jQuery.event.special[ type ] || {}; + if ( special.trigger && special.trigger.apply( elem, data ) === false ) { + return; + } + + // Determine event propagation path in advance, per W3C events spec (#9951) + // Bubble up to document, then to window; watch for a global ownerDocument var (#9724) + eventPath = [[ elem, special.bindType || type ]]; + if ( !onlyHandlers && !special.noBubble && !jQuery.isWindow( elem ) ) { + + bubbleType = special.delegateType || type; + old = null; + for ( cur = elem.parentNode; cur; cur = cur.parentNode ) { + eventPath.push([ cur, bubbleType ]); + old = cur; + } + + // Only add window if we got to document (e.g., not plain obj or detached DOM) + if ( old && old === elem.ownerDocument ) { + eventPath.push([ old.defaultView || old.parentWindow || window, bubbleType ]); + } + } + + // Fire handlers on the event path + for ( i = 0; i < eventPath.length; i++ ) { + + cur = eventPath[i][0]; + event.type = eventPath[i][1]; + + handle = (jQuery._data( cur, "events" ) || {})[ event.type ] && jQuery._data( cur, "handle" ); + if ( handle ) { + handle.apply( cur, data ); + } + handle = ontype && cur[ ontype ]; + if ( handle && jQuery.acceptData( cur ) ) { + handle.apply( cur, data ); + } + + if ( event.isPropagationStopped() ) { + break; + } + } + event.type = type; + + // If nobody prevented the default action, do it now + if ( !event.isDefaultPrevented() ) { + + if ( (!special._default || special._default.call( elem.ownerDocument, event, data ) === false) && + !(type === "click" && jQuery.nodeName( elem, "a" )) && jQuery.acceptData( elem ) ) { + + // Call a native DOM method on the target with the same name name as the event. + // Can't use an .isFunction() check here because IE6/7 fails that test. + // Don't do default actions on window, that's where global variables be (#6170) + // IE<9 dies on focus/blur to hidden element (#1486) + if ( ontype && elem[ type ] && ((type !== "focus" && type !== "blur") || event.target.offsetWidth !== 0) && !jQuery.isWindow( elem ) ) { + + // Don't re-trigger an onFOO event when we call its FOO() method + old = elem[ ontype ]; + + if ( old ) { + elem[ ontype ] = null; + } + + // Prevent re-triggering of the same event, since we already bubbled it above + jQuery.event.triggered = type; + elem[ type ](); + jQuery.event.triggered = undefined; + + if ( old ) { + elem[ ontype ] = old; + } + } + } + } + + return event.result; + }, + + handle: function( event ) { + + // Make a writable jQuery.Event from the native event object + event = jQuery.event.fix( event || window.event ); + + var handlers = ((jQuery._data( this, "events" ) || {})[ event.type ] || []), + delegateCount = handlers.delegateCount, + args = [].slice.call( arguments, 0 ), + handlerQueue = [], + i, cur, selMatch, matches, handleObj, sel, hit, related; + + // Use the fix-ed jQuery.Event rather than the (read-only) native event + args[0] = event; + + // Determine handlers that should run if there are delegated events + // Avoid disabled elements in IE (#6911) and non-left-click bubbling in Firefox (#3861) + if ( delegateCount && !event.target.disabled && !(event.button && event.type === "click") ) { + + for ( cur = event.target; cur != this; cur = cur.parentNode || this ) { + selMatch = {}; + matches = []; + for ( i = 0; i < delegateCount; i++ ) { + handleObj = handlers[ i ]; + sel = handleObj.selector; + hit = selMatch[ sel ]; + + if ( handleObj.isPositional ) { + // Since .is() does not work for positionals; see http://jsfiddle.net/eJ4yd/3/ + hit = ( hit || (selMatch[ sel ] = jQuery( sel )) ).index( cur ) >= 0; + } else if ( hit === undefined ) { + hit = selMatch[ sel ] = ( handleObj.quick ? quickIs( cur, handleObj.quick ) : jQuery( cur ).is( sel ) ); + } + if ( hit ) { + matches.push( handleObj ); + } + } + if ( matches.length ) { + handlerQueue.push({ elem: cur, matches: matches }); + } + } + } + + // Copy the remaining (bound) handlers in case they're changed + handlers = handlers.slice( delegateCount ); + + // Run delegates first; they may want to stop propagation beneath us + event.delegateTarget = this; + for ( i = 0; i < handlerQueue.length && !event.isPropagationStopped(); i++ ) { + matched = handlerQueue[ i ]; + dispatch( matched.elem, event, matched.matches, args ); + } + delete event.delegateTarget; + + // Run non-delegated handlers for this level + if ( handlers.length ) { + dispatch( this, event, handlers, args ); + } + + return event.result; + }, + + // Includes some event props shared by KeyEvent and MouseEvent + // *** attrChange attrName relatedNode srcElement are not normalized, non-W3C, deprecated, will be removed in 1.8 *** + props: "attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "), + + fixHooks: {}, + + keyHooks: { + props: "char charCode key keyCode".split(" "), + filter: function( event, original ) { + + // Add which for key events + if ( event.which == null ) { + event.which = original.charCode != null ? original.charCode : original.keyCode; + } + + return event; + } + }, + + mouseHooks: { + props: "button buttons clientX clientY fromElement layerX layerY offsetX offsetY pageX pageY screenX screenY toElement wheelDelta".split(" "), + filter: function( event, original ) { + var eventDoc, doc, body, + button = original.button, + fromElement = original.fromElement; + + // Calculate pageX/Y if missing and clientX/Y available + if ( event.pageX == null && original.clientX != null ) { + eventDoc = event.target.ownerDocument || document; + doc = eventDoc.documentElement; + body = eventDoc.body; + + event.pageX = original.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0); + event.pageY = original.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0); + } + + // Add relatedTarget, if necessary + if ( !event.relatedTarget && fromElement ) { + event.relatedTarget = fromElement === event.target ? original.toElement : fromElement; + } + + // Add which for click: 1 === left; 2 === middle; 3 === right + // Note: button is not normalized, so don't use it + if ( !event.which && button !== undefined ) { + event.which = ( button & 1 ? 1 : ( button & 2 ? 3 : ( button & 4 ? 2 : 0 ) ) ); + } + + return event; + } + }, + + fix: function( event ) { + if ( event[ jQuery.expando ] ) { + return event; + } + + // Create a writable copy of the event object and normalize some properties + var i, prop, + originalEvent = event, + fixHook = jQuery.event.fixHooks[ event.type ] || {}, + copy = fixHook.props ? this.props.concat( fixHook.props ) : this.props; + + event = jQuery.Event( originalEvent ); + + for ( i = copy.length; i; ) { + prop = copy[ --i ]; + event[ prop ] = originalEvent[ prop ]; + } + + // Fix target property, if necessary (#1925, IE 6/7/8 & Safari2) + if ( !event.target ) { + event.target = originalEvent.srcElement || document; + } + + // Target should not be a text node (#504, Safari) + if ( event.target.nodeType === 3 ) { + event.target = event.target.parentNode; + } + + // For mouse/key events; add metaKey if it's not there (#3368, IE6/7/8) + if ( event.metaKey === undefined ) { + event.metaKey = event.ctrlKey; + } + + return fixHook.filter? fixHook.filter( event, originalEvent ) : event; + }, + + special: { + ready: { + // Make sure the ready event is setup + setup: jQuery.bindReady + }, + + focus: { + delegateType: "focusin", + noBubble: true + }, + blur: { + delegateType: "focusout", + noBubble: true + }, + + beforeunload: { + setup: function( data, namespaces, eventHandle ) { + // We only want to do this special case on windows + if ( jQuery.isWindow( this ) ) { + this.onbeforeunload = eventHandle; + } + }, + + teardown: function( namespaces, eventHandle ) { + if ( this.onbeforeunload === eventHandle ) { + this.onbeforeunload = null; + } + } + } + }, + + simulate: function( type, elem, event, bubble ) { + // Piggyback on a donor event to simulate a different one. + // Fake originalEvent to avoid donor's stopPropagation, but if the + // simulated event prevents default then we do the same on the donor. + var e = jQuery.extend( + new jQuery.Event(), + event, + { type: type, + isSimulated: true, + originalEvent: {} + } + ); + if ( bubble ) { + jQuery.event.trigger( e, null, elem ); + } else { + jQuery.event.handle.call( elem, e ); + } + if ( e.isDefaultPrevented() ) { + event.preventDefault(); + } + } +}; + +// Run jQuery handler functions; called from jQuery.event.handle +function dispatch( target, event, handlers, args ) { + var run_all = !event.exclusive && !event.namespace, + specialHandle = ( jQuery.event.special[ event.type ] || {} ).handle, + j, handleObj, ret; + + event.currentTarget = target; + for ( j = 0; j < handlers.length && !event.isImmediatePropagationStopped(); j++ ) { + handleObj = handlers[ j ]; + + // Triggered event must either 1) be non-exclusive and have no namespace, or + // 2) have namespace(s) a subset or equal to those in the bound event (both can have no namespace). + if ( run_all || (!event.namespace && !handleObj.namespace) || event.namespace_re && event.namespace_re.test( handleObj.namespace ) ) { + + // Pass in a reference to the handler function itself + // So that we can later remove it + event.handler = handleObj.handler; + event.data = handleObj.data; + event.handleObj = handleObj; + + ret = ( specialHandle || handleObj.handler ).apply( target, args ); + + if ( ret !== undefined ) { + event.result = ret; + if ( ret === false ) { + event.preventDefault(); + event.stopPropagation(); + } + } + } + } +} + +jQuery.removeEvent = document.removeEventListener ? + function( elem, type, handle ) { + if ( elem.removeEventListener ) { + elem.removeEventListener( type, handle, false ); + } + } : + function( elem, type, handle ) { + if ( elem.detachEvent ) { + elem.detachEvent( "on" + type, handle ); + } + }; + +jQuery.Event = function( src, props ) { + // Allow instantiation without the 'new' keyword + if ( !(this instanceof jQuery.Event) ) { + return new jQuery.Event( src, props ); + } + + // Event object + if ( src && src.type ) { + this.originalEvent = src; + this.type = src.type; + + // Events bubbling up the document may have been marked as prevented + // by a handler lower down the tree; reflect the correct value. + this.isDefaultPrevented = ( src.defaultPrevented || src.returnValue === false || + src.getPreventDefault && src.getPreventDefault() ) ? returnTrue : returnFalse; + + // Event type + } else { + this.type = src; + } + + // Put explicitly provided properties onto the event object + if ( props ) { + jQuery.extend( this, props ); + } + + // Create a timestamp if incoming event doesn't have one + this.timeStamp = src && src.timeStamp || jQuery.now(); + + // Mark it as fixed + this[ jQuery.expando ] = true; +}; + +function returnFalse() { + return false; +} +function returnTrue() { + return true; +} + +// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding +// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html +jQuery.Event.prototype = { + preventDefault: function() { + this.isDefaultPrevented = returnTrue; + + var e = this.originalEvent; + if ( !e ) { + return; + } + + // if preventDefault exists run it on the original event + if ( e.preventDefault ) { + e.preventDefault(); + + // otherwise set the returnValue property of the original event to false (IE) + } else { + e.returnValue = false; + } + }, + stopPropagation: function() { + this.isPropagationStopped = returnTrue; + + var e = this.originalEvent; + if ( !e ) { + return; + } + // if stopPropagation exists run it on the original event + if ( e.stopPropagation ) { + e.stopPropagation(); + } + // otherwise set the cancelBubble property of the original event to true (IE) + e.cancelBubble = true; + }, + stopImmediatePropagation: function() { + this.isImmediatePropagationStopped = returnTrue; + this.stopPropagation(); + }, + isDefaultPrevented: returnFalse, + isPropagationStopped: returnFalse, + isImmediatePropagationStopped: returnFalse +}; + +// Create mouseenter/leave events using mouseover/out and event-time checks +jQuery.each({ + mouseenter: "mouseover", + mouseleave: "mouseout" +}, function( orig, fix ) { + jQuery.event.special[ orig ] = jQuery.event.special[ fix ] = { + delegateType: fix, + bindType: fix, + + handle: function( event ) { + var target = this, + related = event.relatedTarget, + handleObj = event.handleObj, + selector = handleObj.selector, + oldType, ret; + + // For a real mouseover/out, always call the handler; for + // mousenter/leave call the handler if related is outside the target. + // NB: No relatedTarget if the mouse left/entered the browser window + if ( !related || handleObj.origType === event.type || (related !== target && !jQuery.contains( target, related )) ) { + oldType = event.type; + event.type = handleObj.origType; + ret = handleObj.handler.apply( this, arguments ); + event.type = oldType; + } + return ret; + } + }; +}); + +// IE submit delegation +if ( !jQuery.support.submitBubbles ) { + + jQuery.event.special.submit = { + setup: function() { + // Only need this for delegated form submit events + if ( jQuery.nodeName( this, "form" ) ) { + return false; + } + + // Lazy-add a submit handler when a descendant form may potentially be submitted + jQuery.event.add( this, "click._submit keypress._submit", function( e ) { + // Node name check avoids a VML-related crash in IE (#9807) + var elem = e.target, + form = jQuery.nodeName( elem, "input" ) || jQuery.nodeName( elem, "button" ) ? elem.form : undefined; + if ( form && !form._submit_attached ) { + jQuery.event.add( form, "submit._submit", function( event ) { + // Form was submitted, bubble the event up the tree + if ( this.parentNode ) { + jQuery.event.simulate( "submit", this.parentNode, event, true ); + } + }); + form._submit_attached = true; + } + }); + // return undefined since we don't need an event listener + }, + + teardown: function() { + // Only need this for delegated form submit events + if ( jQuery.nodeName( this, "form" ) ) { + return false; + } + + // Remove delegated handlers; cleanData eventually reaps submit handlers attached above + jQuery.event.remove( this, "._submit" ); + } + }; +} + +// IE change delegation and checkbox/radio fix +if ( !jQuery.support.changeBubbles ) { + + jQuery.event.special.change = { + + setup: function() { + + if ( rformElems.test( this.nodeName ) ) { + // IE doesn't fire change on a check/radio until blur; trigger it on click + // after a propertychange. Eat the blur-change in special.change.handle. + // This still fires onchange a second time for check/radio after blur. + if ( this.type === "checkbox" || this.type === "radio" ) { + jQuery.event.add( this, "propertychange._change", function( event ) { + if ( event.originalEvent.propertyName === "checked" ) { + this._just_changed = true; + } + }); + jQuery.event.add( this, "click._change", function( event ) { + if ( this._just_changed ) { + this._just_changed = false; + jQuery.event.simulate( "change", this, event, true ); + } + }); + } + return false; + } + // Delegated event; lazy-add a change handler on descendant inputs + jQuery.event.add( this, "beforeactivate._change", function( e ) { + var elem = e.target; + + if ( rformElems.test( elem.nodeName ) && !elem._change_attached ) { + jQuery.event.add( elem, "change._change", function( event ) { + if ( this.parentNode && !event.isSimulated ) { + jQuery.event.simulate( "change", this.parentNode, event, true ); + } + }); + elem._change_attached = true; + } + }); + }, + + handle: function( event ) { + var elem = event.target; + + // Swallow native change events from checkbox/radio, we already triggered them above + if ( this !== elem || event.isSimulated || event.isTrigger || (elem.type !== "radio" && elem.type !== "checkbox") ) { + return event.handleObj.handler.apply( this, arguments ); + } + }, + + teardown: function() { + jQuery.event.remove( this, "._change" ); + + return rformElems.test( this.nodeName ); + } + }; +} + +// Create "bubbling" focus and blur events +if ( !jQuery.support.focusinBubbles ) { + jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) { + + // Attach a single capturing handler while someone wants focusin/focusout + var attaches = 0, + handler = function( event ) { + jQuery.event.simulate( fix, event.target, jQuery.event.fix( event ), true ); + }; + + jQuery.event.special[ fix ] = { + setup: function() { + if ( attaches++ === 0 ) { + document.addEventListener( orig, handler, true ); + } + }, + teardown: function() { + if ( --attaches === 0 ) { + document.removeEventListener( orig, handler, true ); + } + } + }; + }); +} + +jQuery.fn.extend({ + + on: function( types, selector, data, fn, /*INTERNAL*/ one ) { + var origFn, type; + + // Types can be a map of types/handlers + if ( typeof types === "object" ) { + // ( types-Object, selector, data ) + if ( typeof selector !== "string" ) { + // ( types-Object, data ) + data = selector; + selector = undefined; + } + for ( type in types ) { + this.on( type, selector, data, types[ type ], one ); + } + return this; + } + + if ( data == null && fn == null ) { + // ( types, fn ) + fn = selector; + data = selector = undefined; + } else if ( fn == null ) { + if ( typeof selector === "string" ) { + // ( types, selector, fn ) + fn = data; + data = undefined; + } else { + // ( types, data, fn ) + fn = data; + data = selector; + selector = undefined; + } + } + if ( fn === false ) { + fn = returnFalse; + } else if ( !fn ) { + return this; + } + + if ( one === 1 ) { + origFn = fn; + fn = function( event ) { + jQuery.event.remove( event.delegateTarget || this, event ); + return origFn.apply( this, arguments ); + }; + // Use same guid so caller can remove using origFn + fn.guid = origFn.guid || ( origFn.guid = jQuery.guid++ ); + } + return this.each( function() { + jQuery.event.add( this, types, fn, data, selector ); + }); + }, + one: function( types, selector, data, fn ) { + return this.on.call( this, types, selector, data, fn, 1 ); + }, + off: function( types, selector, fn ) { + if ( types && types.preventDefault ) { + // ( event ) native or jQuery.Event + return this.off( types.type, types.handler, types.selector ); + } + if ( typeof types === "object" ) { + // ( types-object [, selector] ) + for ( var type in types ) { + this.off( type, selector, types[ type ] ); + } + return this; + } + if ( selector === false || typeof selector === "function" ) { + // ( types [, fn] ) + fn = selector; + selector = undefined; + } + if ( fn === false ) { + fn = returnFalse; + } + return this.each(function() { + jQuery.event.remove( this, types, fn, selector ); + }); + }, + + bind: function( types, data, fn ) { + return this.on( types, null, data, fn ); + }, + unbind: function( types, fn ) { + return this.off( types, null, fn ); + }, + + live: function( types, data, fn ) { + jQuery( this.context ).on( types, this.selector, data, fn ); + return this; + }, + die: function( types, fn ) { + jQuery( this.context ).off( types, this.selector || "**", fn ); + return this; + }, + + delegate: function( selector, types, data, fn ) { + return this.on( types, selector, data, fn ); + }, + undelegate: function( selector, types, fn ) { + // ( namespace ) or ( selector, types [, fn] ) + return arguments.length == 1? this.off( selector, "**" ) : this.off( types, selector, fn ); + }, + + trigger: function( type, data ) { + return this.each(function() { + jQuery.event.trigger( type, data, this ); + }); + }, + triggerHandler: function( type, data ) { + if ( this[0] ) { + return jQuery.event.trigger( type, data, this[0], true ); + } + }, + + toggle: function( fn ) { + // Save reference to arguments for access in closure + var args = arguments, + guid = fn.guid || jQuery.guid++, + i = 0, + toggler = function( event ) { + // Figure out which function to execute + var lastToggle = ( jQuery._data( this, "lastToggle" + fn.guid ) || 0 ) % i; + jQuery._data( this, "lastToggle" + fn.guid, lastToggle + 1 ); + + // Make sure that clicks stop + event.preventDefault(); + + // and execute the function + return args[ lastToggle ].apply( this, arguments ) || false; + }; + + // link all the functions, so any of them can unbind this click handler + toggler.guid = guid; + while ( i < args.length ) { + args[ i++ ].guid = guid; + } + + return this.click( toggler ); + }, + + hover: function( fnOver, fnOut ) { + return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver ); + } +}); + +jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " + + "mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " + + "change select submit keydown keypress keyup error contextmenu").split(" "), function( i, name ) { + + // Handle event binding + jQuery.fn[ name ] = function( data, fn ) { + if ( fn == null ) { + fn = data; + data = null; + } + + return arguments.length > 0 ? + this.bind( name, data, fn ) : + this.trigger( name ); + }; + + if ( jQuery.attrFn ) { + jQuery.attrFn[ name ] = true; + } + + if ( rkeyEvent.test( name ) ) { + jQuery.event.fixHooks[ name ] = jQuery.event.keyHooks; + } + + if ( rmouseEvent.test( name ) ) { + jQuery.event.fixHooks[ name ] = jQuery.event.mouseHooks; + } +}); + + + +/*! + * Sizzle CSS Selector Engine + * Copyright 2011, The Dojo Foundation + * Released under the MIT, BSD, and GPL Licenses. + * More information: http://sizzlejs.com/ + */ +(function(){ + +var chunker = /((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g, + expando = "sizcache" + (Math.random() + '').replace('.', ''), + done = 0, + toString = Object.prototype.toString, + hasDuplicate = false, + baseHasDuplicate = true, + rBackslash = /\\/g, + rReturn = /\r\n/g, + rNonWord = /\W/; + +// Here we check if the JavaScript engine is using some sort of +// optimization where it does not always call our comparision +// function. If that is the case, discard the hasDuplicate value. +// Thus far that includes Google Chrome. +[0, 0].sort(function() { + baseHasDuplicate = false; + return 0; +}); + +var Sizzle = function( selector, context, results, seed ) { + results = results || []; + context = context || document; + + var origContext = context; + + if ( context.nodeType !== 1 && context.nodeType !== 9 ) { + return []; + } + + if ( !selector || typeof selector !== "string" ) { + return results; + } + + var m, set, checkSet, extra, ret, cur, pop, i, + prune = true, + contextXML = Sizzle.isXML( context ), + parts = [], + soFar = selector; + + // Reset the position of the chunker regexp (start from head) + do { + chunker.exec( "" ); + m = chunker.exec( soFar ); + + if ( m ) { + soFar = m[3]; + + parts.push( m[1] ); + + if ( m[2] ) { + extra = m[3]; + break; + } + } + } while ( m ); + + if ( parts.length > 1 && origPOS.exec( selector ) ) { + + if ( parts.length === 2 && Expr.relative[ parts[0] ] ) { + set = posProcess( parts[0] + parts[1], context, seed ); + + } else { + set = Expr.relative[ parts[0] ] ? + [ context ] : + Sizzle( parts.shift(), context ); + + while ( parts.length ) { + selector = parts.shift(); + + if ( Expr.relative[ selector ] ) { + selector += parts.shift(); + } + + set = posProcess( selector, set, seed ); + } + } + + } else { + // Take a shortcut and set the context if the root selector is an ID + // (but not if it'll be faster if the inner selector is an ID) + if ( !seed && parts.length > 1 && context.nodeType === 9 && !contextXML && + Expr.match.ID.test(parts[0]) && !Expr.match.ID.test(parts[parts.length - 1]) ) { + + ret = Sizzle.find( parts.shift(), context, contextXML ); + context = ret.expr ? + Sizzle.filter( ret.expr, ret.set )[0] : + ret.set[0]; + } + + if ( context ) { + ret = seed ? + { expr: parts.pop(), set: makeArray(seed) } : + Sizzle.find( parts.pop(), parts.length === 1 && (parts[0] === "~" || parts[0] === "+") && context.parentNode ? context.parentNode : context, contextXML ); + + set = ret.expr ? + Sizzle.filter( ret.expr, ret.set ) : + ret.set; + + if ( parts.length > 0 ) { + checkSet = makeArray( set ); + + } else { + prune = false; + } + + while ( parts.length ) { + cur = parts.pop(); + pop = cur; + + if ( !Expr.relative[ cur ] ) { + cur = ""; + } else { + pop = parts.pop(); + } + + if ( pop == null ) { + pop = context; + } + + Expr.relative[ cur ]( checkSet, pop, contextXML ); + } + + } else { + checkSet = parts = []; + } + } + + if ( !checkSet ) { + checkSet = set; + } + + if ( !checkSet ) { + Sizzle.error( cur || selector ); + } + + if ( toString.call(checkSet) === "[object Array]" ) { + if ( !prune ) { + results.push.apply( results, checkSet ); + + } else if ( context && context.nodeType === 1 ) { + for ( i = 0; checkSet[i] != null; i++ ) { + if ( checkSet[i] && (checkSet[i] === true || checkSet[i].nodeType === 1 && Sizzle.contains(context, checkSet[i])) ) { + results.push( set[i] ); + } + } + + } else { + for ( i = 0; checkSet[i] != null; i++ ) { + if ( checkSet[i] && checkSet[i].nodeType === 1 ) { + results.push( set[i] ); + } + } + } + + } else { + makeArray( checkSet, results ); + } + + if ( extra ) { + Sizzle( extra, origContext, results, seed ); + Sizzle.uniqueSort( results ); + } + + return results; +}; + +Sizzle.uniqueSort = function( results ) { + if ( sortOrder ) { + hasDuplicate = baseHasDuplicate; + results.sort( sortOrder ); + + if ( hasDuplicate ) { + for ( var i = 1; i < results.length; i++ ) { + if ( results[i] === results[ i - 1 ] ) { + results.splice( i--, 1 ); + } + } + } + } + + return results; +}; + +Sizzle.matches = function( expr, set ) { + return Sizzle( expr, null, null, set ); +}; + +Sizzle.matchesSelector = function( node, expr ) { + return Sizzle( expr, null, null, [node] ).length > 0; +}; + +Sizzle.find = function( expr, context, isXML ) { + var set, i, len, match, type, left; + + if ( !expr ) { + return []; + } + + for ( i = 0, len = Expr.order.length; i < len; i++ ) { + type = Expr.order[i]; + + if ( (match = Expr.leftMatch[ type ].exec( expr )) ) { + left = match[1]; + match.splice( 1, 1 ); + + if ( left.substr( left.length - 1 ) !== "\\" ) { + match[1] = (match[1] || "").replace( rBackslash, "" ); + set = Expr.find[ type ]( match, context, isXML ); + + if ( set != null ) { + expr = expr.replace( Expr.match[ type ], "" ); + break; + } + } + } + } + + if ( !set ) { + set = typeof context.getElementsByTagName !== "undefined" ? + context.getElementsByTagName( "*" ) : + []; + } + + return { set: set, expr: expr }; +}; + +Sizzle.filter = function( expr, set, inplace, not ) { + var match, anyFound, + type, found, item, filter, left, + i, pass, + old = expr, + result = [], + curLoop = set, + isXMLFilter = set && set[0] && Sizzle.isXML( set[0] ); + + while ( expr && set.length ) { + for ( type in Expr.filter ) { + if ( (match = Expr.leftMatch[ type ].exec( expr )) != null && match[2] ) { + filter = Expr.filter[ type ]; + left = match[1]; + + anyFound = false; + + match.splice(1,1); + + if ( left.substr( left.length - 1 ) === "\\" ) { + continue; + } + + if ( curLoop === result ) { + result = []; + } + + if ( Expr.preFilter[ type ] ) { + match = Expr.preFilter[ type ]( match, curLoop, inplace, result, not, isXMLFilter ); + + if ( !match ) { + anyFound = found = true; + + } else if ( match === true ) { + continue; + } + } + + if ( match ) { + for ( i = 0; (item = curLoop[i]) != null; i++ ) { + if ( item ) { + found = filter( item, match, i, curLoop ); + pass = not ^ found; + + if ( inplace && found != null ) { + if ( pass ) { + anyFound = true; + + } else { + curLoop[i] = false; + } + + } else if ( pass ) { + result.push( item ); + anyFound = true; + } + } + } + } + + if ( found !== undefined ) { + if ( !inplace ) { + curLoop = result; + } + + expr = expr.replace( Expr.match[ type ], "" ); + + if ( !anyFound ) { + return []; + } + + break; + } + } + } + + // Improper expression + if ( expr === old ) { + if ( anyFound == null ) { + Sizzle.error( expr ); + + } else { + break; + } + } + + old = expr; + } + + return curLoop; +}; + +Sizzle.error = function( msg ) { + throw "Syntax error, unrecognized expression: " + msg; +}; + +/** + * Utility function for retreiving the text value of an array of DOM nodes + * @param {Array|Element} elem + */ +var getText = Sizzle.getText = function( elem ) { + var i, node, + nodeType = elem.nodeType, + ret = ""; + + if ( nodeType ) { + if ( nodeType === 1 ) { + // Use textContent || innerText for elements + if ( typeof elem.textContent === 'string' ) { + return elem.textContent; + } else if ( typeof elem.innerText === 'string' ) { + // Replace IE's carriage returns + return elem.innerText.replace( rReturn, '' ); + } else { + // Traverse it's children + for ( elem = elem.firstChild; elem; elem = elem.nextSibling) { + ret += getText( elem ); + } + } + } else if ( nodeType === 3 || nodeType === 4 ) { + return elem.nodeValue; + } + } else { + + // If no nodeType, this is expected to be an array + for ( i = 0; (node = elem[i]); i++ ) { + // Do not traverse comment nodes + if ( node.nodeType !== 8 ) { + ret += getText( node ); + } + } + } + return ret; +}; + +var Expr = Sizzle.selectors = { + order: [ "ID", "NAME", "TAG" ], + + match: { + ID: /#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/, + CLASS: /\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/, + NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/, + ATTR: /\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/, + TAG: /^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/, + CHILD: /:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/, + POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/, + PSEUDO: /:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/ + }, + + leftMatch: {}, + + attrMap: { + "class": "className", + "for": "htmlFor" + }, + + attrHandle: { + href: function( elem ) { + return elem.getAttribute( "href" ); + }, + type: function( elem ) { + return elem.getAttribute( "type" ); + } + }, + + relative: { + "+": function(checkSet, part){ + var isPartStr = typeof part === "string", + isTag = isPartStr && !rNonWord.test( part ), + isPartStrNotTag = isPartStr && !isTag; + + if ( isTag ) { + part = part.toLowerCase(); + } + + for ( var i = 0, l = checkSet.length, elem; i < l; i++ ) { + if ( (elem = checkSet[i]) ) { + while ( (elem = elem.previousSibling) && elem.nodeType !== 1 ) {} + + checkSet[i] = isPartStrNotTag || elem && elem.nodeName.toLowerCase() === part ? + elem || false : + elem === part; + } + } + + if ( isPartStrNotTag ) { + Sizzle.filter( part, checkSet, true ); + } + }, + + ">": function( checkSet, part ) { + var elem, + isPartStr = typeof part === "string", + i = 0, + l = checkSet.length; + + if ( isPartStr && !rNonWord.test( part ) ) { + part = part.toLowerCase(); + + for ( ; i < l; i++ ) { + elem = checkSet[i]; + + if ( elem ) { + var parent = elem.parentNode; + checkSet[i] = parent.nodeName.toLowerCase() === part ? parent : false; + } + } + + } else { + for ( ; i < l; i++ ) { + elem = checkSet[i]; + + if ( elem ) { + checkSet[i] = isPartStr ? + elem.parentNode : + elem.parentNode === part; + } + } + + if ( isPartStr ) { + Sizzle.filter( part, checkSet, true ); + } + } + }, + + "": function(checkSet, part, isXML){ + var nodeCheck, + doneName = done++, + checkFn = dirCheck; + + if ( typeof part === "string" && !rNonWord.test( part ) ) { + part = part.toLowerCase(); + nodeCheck = part; + checkFn = dirNodeCheck; + } + + checkFn( "parentNode", part, doneName, checkSet, nodeCheck, isXML ); + }, + + "~": function( checkSet, part, isXML ) { + var nodeCheck, + doneName = done++, + checkFn = dirCheck; + + if ( typeof part === "string" && !rNonWord.test( part ) ) { + part = part.toLowerCase(); + nodeCheck = part; + checkFn = dirNodeCheck; + } + + checkFn( "previousSibling", part, doneName, checkSet, nodeCheck, isXML ); + } + }, + + find: { + ID: function( match, context, isXML ) { + if ( typeof context.getElementById !== "undefined" && !isXML ) { + var m = context.getElementById(match[1]); + // Check parentNode to catch when Blackberry 4.6 returns + // nodes that are no longer in the document #6963 + return m && m.parentNode ? [m] : []; + } + }, + + NAME: function( match, context ) { + if ( typeof context.getElementsByName !== "undefined" ) { + var ret = [], + results = context.getElementsByName( match[1] ); + + for ( var i = 0, l = results.length; i < l; i++ ) { + if ( results[i].getAttribute("name") === match[1] ) { + ret.push( results[i] ); + } + } + + return ret.length === 0 ? null : ret; + } + }, + + TAG: function( match, context ) { + if ( typeof context.getElementsByTagName !== "undefined" ) { + return context.getElementsByTagName( match[1] ); + } + } + }, + preFilter: { + CLASS: function( match, curLoop, inplace, result, not, isXML ) { + match = " " + match[1].replace( rBackslash, "" ) + " "; + + if ( isXML ) { + return match; + } + + for ( var i = 0, elem; (elem = curLoop[i]) != null; i++ ) { + if ( elem ) { + if ( not ^ (elem.className && (" " + elem.className + " ").replace(/[\t\n\r]/g, " ").indexOf(match) >= 0) ) { + if ( !inplace ) { + result.push( elem ); + } + + } else if ( inplace ) { + curLoop[i] = false; + } + } + } + + return false; + }, + + ID: function( match ) { + return match[1].replace( rBackslash, "" ); + }, + + TAG: function( match, curLoop ) { + return match[1].replace( rBackslash, "" ).toLowerCase(); + }, + + CHILD: function( match ) { + if ( match[1] === "nth" ) { + if ( !match[2] ) { + Sizzle.error( match[0] ); + } + + match[2] = match[2].replace(/^\+|\s*/g, ''); + + // parse equations like 'even', 'odd', '5', '2n', '3n+2', '4n-1', '-n+6' + var test = /(-?)(\d*)(?:n([+\-]?\d*))?/.exec( + match[2] === "even" && "2n" || match[2] === "odd" && "2n+1" || + !/\D/.test( match[2] ) && "0n+" + match[2] || match[2]); + + // calculate the numbers (first)n+(last) including if they are negative + match[2] = (test[1] + (test[2] || 1)) - 0; + match[3] = test[3] - 0; + } + else if ( match[2] ) { + Sizzle.error( match[0] ); + } + + // TODO: Move to normal caching system + match[0] = done++; + + return match; + }, + + ATTR: function( match, curLoop, inplace, result, not, isXML ) { + var name = match[1] = match[1].replace( rBackslash, "" ); + + if ( !isXML && Expr.attrMap[name] ) { + match[1] = Expr.attrMap[name]; + } + + // Handle if an un-quoted value was used + match[4] = ( match[4] || match[5] || "" ).replace( rBackslash, "" ); + + if ( match[2] === "~=" ) { + match[4] = " " + match[4] + " "; + } + + return match; + }, + + PSEUDO: function( match, curLoop, inplace, result, not ) { + if ( match[1] === "not" ) { + // If we're dealing with a complex expression, or a simple one + if ( ( chunker.exec(match[3]) || "" ).length > 1 || /^\w/.test(match[3]) ) { + match[3] = Sizzle(match[3], null, null, curLoop); + + } else { + var ret = Sizzle.filter(match[3], curLoop, inplace, true ^ not); + + if ( !inplace ) { + result.push.apply( result, ret ); + } + + return false; + } + + } else if ( Expr.match.POS.test( match[0] ) || Expr.match.CHILD.test( match[0] ) ) { + return true; + } + + return match; + }, + + POS: function( match ) { + match.unshift( true ); + + return match; + } + }, + + filters: { + enabled: function( elem ) { + return elem.disabled === false && elem.type !== "hidden"; + }, + + disabled: function( elem ) { + return elem.disabled === true; + }, + + checked: function( elem ) { + return elem.checked === true; + }, + + selected: function( elem ) { + // Accessing this property makes selected-by-default + // options in Safari work properly + if ( elem.parentNode ) { + elem.parentNode.selectedIndex; + } + + return elem.selected === true; + }, + + parent: function( elem ) { + return !!elem.firstChild; + }, + + empty: function( elem ) { + return !elem.firstChild; + }, + + has: function( elem, i, match ) { + return !!Sizzle( match[3], elem ).length; + }, + + header: function( elem ) { + return (/h\d/i).test( elem.nodeName ); + }, + + text: function( elem ) { + var attr = elem.getAttribute( "type" ), type = elem.type; + // IE6 and 7 will map elem.type to 'text' for new HTML5 types (search, etc) + // use getAttribute instead to test this case + return elem.nodeName.toLowerCase() === "input" && "text" === type && ( attr === type || attr === null ); + }, + + radio: function( elem ) { + return elem.nodeName.toLowerCase() === "input" && "radio" === elem.type; + }, + + checkbox: function( elem ) { + return elem.nodeName.toLowerCase() === "input" && "checkbox" === elem.type; + }, + + file: function( elem ) { + return elem.nodeName.toLowerCase() === "input" && "file" === elem.type; + }, + + password: function( elem ) { + return elem.nodeName.toLowerCase() === "input" && "password" === elem.type; + }, + + submit: function( elem ) { + var name = elem.nodeName.toLowerCase(); + return (name === "input" || name === "button") && "submit" === elem.type; + }, + + image: function( elem ) { + return elem.nodeName.toLowerCase() === "input" && "image" === elem.type; + }, + + reset: function( elem ) { + var name = elem.nodeName.toLowerCase(); + return (name === "input" || name === "button") && "reset" === elem.type; + }, + + button: function( elem ) { + var name = elem.nodeName.toLowerCase(); + return name === "input" && "button" === elem.type || name === "button"; + }, + + input: function( elem ) { + return (/input|select|textarea|button/i).test( elem.nodeName ); + }, + + focus: function( elem ) { + return elem === elem.ownerDocument.activeElement; + } + }, + setFilters: { + first: function( elem, i ) { + return i === 0; + }, + + last: function( elem, i, match, array ) { + return i === array.length - 1; + }, + + even: function( elem, i ) { + return i % 2 === 0; + }, + + odd: function( elem, i ) { + return i % 2 === 1; + }, + + lt: function( elem, i, match ) { + return i < match[3] - 0; + }, + + gt: function( elem, i, match ) { + return i > match[3] - 0; + }, + + nth: function( elem, i, match ) { + return match[3] - 0 === i; + }, + + eq: function( elem, i, match ) { + return match[3] - 0 === i; + } + }, + filter: { + PSEUDO: function( elem, match, i, array ) { + var name = match[1], + filter = Expr.filters[ name ]; + + if ( filter ) { + return filter( elem, i, match, array ); + + } else if ( name === "contains" ) { + return (elem.textContent || elem.innerText || getText([ elem ]) || "").indexOf(match[3]) >= 0; + + } else if ( name === "not" ) { + var not = match[3]; + + for ( var j = 0, l = not.length; j < l; j++ ) { + if ( not[j] === elem ) { + return false; + } + } + + return true; + + } else { + Sizzle.error( name ); + } + }, + + CHILD: function( elem, match ) { + var first, last, + doneName, parent, cache, + count, diff, + type = match[1], + node = elem; + + switch ( type ) { + case "only": + case "first": + while ( (node = node.previousSibling) ) { + if ( node.nodeType === 1 ) { + return false; + } + } + + if ( type === "first" ) { + return true; + } + + node = elem; + + case "last": + while ( (node = node.nextSibling) ) { + if ( node.nodeType === 1 ) { + return false; + } + } + + return true; + + case "nth": + first = match[2]; + last = match[3]; + + if ( first === 1 && last === 0 ) { + return true; + } + + doneName = match[0]; + parent = elem.parentNode; + + if ( parent && (parent[ expando ] !== doneName || !elem.nodeIndex) ) { + count = 0; + + for ( node = parent.firstChild; node; node = node.nextSibling ) { + if ( node.nodeType === 1 ) { + node.nodeIndex = ++count; + } + } + + parent[ expando ] = doneName; + } + + diff = elem.nodeIndex - last; + + if ( first === 0 ) { + return diff === 0; + + } else { + return ( diff % first === 0 && diff / first >= 0 ); + } + } + }, + + ID: function( elem, match ) { + return elem.nodeType === 1 && elem.getAttribute("id") === match; + }, + + TAG: function( elem, match ) { + return (match === "*" && elem.nodeType === 1) || !!elem.nodeName && elem.nodeName.toLowerCase() === match; + }, + + CLASS: function( elem, match ) { + return (" " + (elem.className || elem.getAttribute("class")) + " ") + .indexOf( match ) > -1; + }, + + ATTR: function( elem, match ) { + var name = match[1], + result = Sizzle.attr ? + Sizzle.attr( elem, name ) : + Expr.attrHandle[ name ] ? + Expr.attrHandle[ name ]( elem ) : + elem[ name ] != null ? + elem[ name ] : + elem.getAttribute( name ), + value = result + "", + type = match[2], + check = match[4]; + + return result == null ? + type === "!=" : + !type && Sizzle.attr ? + result != null : + type === "=" ? + value === check : + type === "*=" ? + value.indexOf(check) >= 0 : + type === "~=" ? + (" " + value + " ").indexOf(check) >= 0 : + !check ? + value && result !== false : + type === "!=" ? + value !== check : + type === "^=" ? + value.indexOf(check) === 0 : + type === "$=" ? + value.substr(value.length - check.length) === check : + type === "|=" ? + value === check || value.substr(0, check.length + 1) === check + "-" : + false; + }, + + POS: function( elem, match, i, array ) { + var name = match[2], + filter = Expr.setFilters[ name ]; + + if ( filter ) { + return filter( elem, i, match, array ); + } + } + } +}; + +var origPOS = Expr.match.POS, + fescape = function(all, num){ + return "\\" + (num - 0 + 1); + }; + +for ( var type in Expr.match ) { + Expr.match[ type ] = new RegExp( Expr.match[ type ].source + (/(?![^\[]*\])(?![^\(]*\))/.source) ); + Expr.leftMatch[ type ] = new RegExp( /(^(?:.|\r|\n)*?)/.source + Expr.match[ type ].source.replace(/\\(\d+)/g, fescape) ); +} + +var makeArray = function( array, results ) { + array = Array.prototype.slice.call( array, 0 ); + + if ( results ) { + results.push.apply( results, array ); + return results; + } + + return array; +}; + +// Perform a simple check to determine if the browser is capable of +// converting a NodeList to an array using builtin methods. +// Also verifies that the returned array holds DOM nodes +// (which is not the case in the Blackberry browser) +try { + Array.prototype.slice.call( document.documentElement.childNodes, 0 )[0].nodeType; + +// Provide a fallback method if it does not work +} catch( e ) { + makeArray = function( array, results ) { + var i = 0, + ret = results || []; + + if ( toString.call(array) === "[object Array]" ) { + Array.prototype.push.apply( ret, array ); + + } else { + if ( typeof array.length === "number" ) { + for ( var l = array.length; i < l; i++ ) { + ret.push( array[i] ); + } + + } else { + for ( ; array[i]; i++ ) { + ret.push( array[i] ); + } + } + } + + return ret; + }; +} + +var sortOrder, siblingCheck; + +if ( document.documentElement.compareDocumentPosition ) { + sortOrder = function( a, b ) { + if ( a === b ) { + hasDuplicate = true; + return 0; + } + + if ( !a.compareDocumentPosition || !b.compareDocumentPosition ) { + return a.compareDocumentPosition ? -1 : 1; + } + + return a.compareDocumentPosition(b) & 4 ? -1 : 1; + }; + +} else { + sortOrder = function( a, b ) { + // The nodes are identical, we can exit early + if ( a === b ) { + hasDuplicate = true; + return 0; + + // Fallback to using sourceIndex (in IE) if it's available on both nodes + } else if ( a.sourceIndex && b.sourceIndex ) { + return a.sourceIndex - b.sourceIndex; + } + + var al, bl, + ap = [], + bp = [], + aup = a.parentNode, + bup = b.parentNode, + cur = aup; + + // If the nodes are siblings (or identical) we can do a quick check + if ( aup === bup ) { + return siblingCheck( a, b ); + + // If no parents were found then the nodes are disconnected + } else if ( !aup ) { + return -1; + + } else if ( !bup ) { + return 1; + } + + // Otherwise they're somewhere else in the tree so we need + // to build up a full list of the parentNodes for comparison + while ( cur ) { + ap.unshift( cur ); + cur = cur.parentNode; + } + + cur = bup; + + while ( cur ) { + bp.unshift( cur ); + cur = cur.parentNode; + } + + al = ap.length; + bl = bp.length; + + // Start walking down the tree looking for a discrepancy + for ( var i = 0; i < al && i < bl; i++ ) { + if ( ap[i] !== bp[i] ) { + return siblingCheck( ap[i], bp[i] ); + } + } + + // We ended someplace up the tree so do a sibling check + return i === al ? + siblingCheck( a, bp[i], -1 ) : + siblingCheck( ap[i], b, 1 ); + }; + + siblingCheck = function( a, b, ret ) { + if ( a === b ) { + return ret; + } + + var cur = a.nextSibling; + + while ( cur ) { + if ( cur === b ) { + return -1; + } + + cur = cur.nextSibling; + } + + return 1; + }; +} + +// Check to see if the browser returns elements by name when +// querying by getElementById (and provide a workaround) +(function(){ + // We're going to inject a fake input element with a specified name + var form = document.createElement("div"), + id = "script" + (new Date()).getTime(), + root = document.documentElement; + + form.innerHTML = ""; + + // Inject it into the root element, check its status, and remove it quickly + root.insertBefore( form, root.firstChild ); + + // The workaround has to do additional checks after a getElementById + // Which slows things down for other browsers (hence the branching) + if ( document.getElementById( id ) ) { + Expr.find.ID = function( match, context, isXML ) { + if ( typeof context.getElementById !== "undefined" && !isXML ) { + var m = context.getElementById(match[1]); + + return m ? + m.id === match[1] || typeof m.getAttributeNode !== "undefined" && m.getAttributeNode("id").nodeValue === match[1] ? + [m] : + undefined : + []; + } + }; + + Expr.filter.ID = function( elem, match ) { + var node = typeof elem.getAttributeNode !== "undefined" && elem.getAttributeNode("id"); + + return elem.nodeType === 1 && node && node.nodeValue === match; + }; + } + + root.removeChild( form ); + + // release memory in IE + root = form = null; +})(); + +(function(){ + // Check to see if the browser returns only elements + // when doing getElementsByTagName("*") + + // Create a fake element + var div = document.createElement("div"); + div.appendChild( document.createComment("") ); + + // Make sure no comments are found + if ( div.getElementsByTagName("*").length > 0 ) { + Expr.find.TAG = function( match, context ) { + var results = context.getElementsByTagName( match[1] ); + + // Filter out possible comments + if ( match[1] === "*" ) { + var tmp = []; + + for ( var i = 0; results[i]; i++ ) { + if ( results[i].nodeType === 1 ) { + tmp.push( results[i] ); + } + } + + results = tmp; + } + + return results; + }; + } + + // Check to see if an attribute returns normalized href attributes + div.innerHTML = ""; + + if ( div.firstChild && typeof div.firstChild.getAttribute !== "undefined" && + div.firstChild.getAttribute("href") !== "#" ) { + + Expr.attrHandle.href = function( elem ) { + return elem.getAttribute( "href", 2 ); + }; + } + + // release memory in IE + div = null; +})(); + +if ( document.querySelectorAll ) { + (function(){ + var oldSizzle = Sizzle, + div = document.createElement("div"), + id = "__sizzle__"; + + div.innerHTML = "

      "; + + // Safari can't handle uppercase or unicode characters when + // in quirks mode. + if ( div.querySelectorAll && div.querySelectorAll(".TEST").length === 0 ) { + return; + } + + Sizzle = function( query, context, extra, seed ) { + context = context || document; + + // Only use querySelectorAll on non-XML documents + // (ID selectors don't work in non-HTML documents) + if ( !seed && !Sizzle.isXML(context) ) { + // See if we find a selector to speed up + var match = /^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec( query ); + + if ( match && (context.nodeType === 1 || context.nodeType === 9) ) { + // Speed-up: Sizzle("TAG") + if ( match[1] ) { + return makeArray( context.getElementsByTagName( query ), extra ); + + // Speed-up: Sizzle(".CLASS") + } else if ( match[2] && Expr.find.CLASS && context.getElementsByClassName ) { + return makeArray( context.getElementsByClassName( match[2] ), extra ); + } + } + + if ( context.nodeType === 9 ) { + // Speed-up: Sizzle("body") + // The body element only exists once, optimize finding it + if ( query === "body" && context.body ) { + return makeArray( [ context.body ], extra ); + + // Speed-up: Sizzle("#ID") + } else if ( match && match[3] ) { + var elem = context.getElementById( match[3] ); + + // Check parentNode to catch when Blackberry 4.6 returns + // nodes that are no longer in the document #6963 + if ( elem && elem.parentNode ) { + // Handle the case where IE and Opera return items + // by name instead of ID + if ( elem.id === match[3] ) { + return makeArray( [ elem ], extra ); + } + + } else { + return makeArray( [], extra ); + } + } + + try { + return makeArray( context.querySelectorAll(query), extra ); + } catch(qsaError) {} + + // qSA works strangely on Element-rooted queries + // We can work around this by specifying an extra ID on the root + // and working up from there (Thanks to Andrew Dupont for the technique) + // IE 8 doesn't work on object elements + } else if ( context.nodeType === 1 && context.nodeName.toLowerCase() !== "object" ) { + var oldContext = context, + old = context.getAttribute( "id" ), + nid = old || id, + hasParent = context.parentNode, + relativeHierarchySelector = /^\s*[+~]/.test( query ); + + if ( !old ) { + context.setAttribute( "id", nid ); + } else { + nid = nid.replace( /'/g, "\\$&" ); + } + if ( relativeHierarchySelector && hasParent ) { + context = context.parentNode; + } + + try { + if ( !relativeHierarchySelector || hasParent ) { + return makeArray( context.querySelectorAll( "[id='" + nid + "'] " + query ), extra ); + } + + } catch(pseudoError) { + } finally { + if ( !old ) { + oldContext.removeAttribute( "id" ); + } + } + } + } + + return oldSizzle(query, context, extra, seed); + }; + + for ( var prop in oldSizzle ) { + Sizzle[ prop ] = oldSizzle[ prop ]; + } + + // release memory in IE + div = null; + })(); +} + +(function(){ + var html = document.documentElement, + matches = html.matchesSelector || html.mozMatchesSelector || html.webkitMatchesSelector || html.msMatchesSelector; + + if ( matches ) { + // Check to see if it's possible to do matchesSelector + // on a disconnected node (IE 9 fails this) + var disconnectedMatch = !matches.call( document.createElement( "div" ), "div" ), + pseudoWorks = false; + + try { + // This should fail with an exception + // Gecko does not error, returns false instead + matches.call( document.documentElement, "[test!='']:sizzle" ); + + } catch( pseudoError ) { + pseudoWorks = true; + } + + Sizzle.matchesSelector = function( node, expr ) { + // Make sure that attribute selectors are quoted + expr = expr.replace(/\=\s*([^'"\]]*)\s*\]/g, "='$1']"); + + if ( !Sizzle.isXML( node ) ) { + try { + if ( pseudoWorks || !Expr.match.PSEUDO.test( expr ) && !/!=/.test( expr ) ) { + var ret = matches.call( node, expr ); + + // IE 9's matchesSelector returns false on disconnected nodes + if ( ret || !disconnectedMatch || + // As well, disconnected nodes are said to be in a document + // fragment in IE 9, so check for that + node.document && node.document.nodeType !== 11 ) { + return ret; + } + } + } catch(e) {} + } + + return Sizzle(expr, null, null, [node]).length > 0; + }; + } +})(); + +(function(){ + var div = document.createElement("div"); + + div.innerHTML = "
      "; + + // Opera can't find a second classname (in 9.6) + // Also, make sure that getElementsByClassName actually exists + if ( !div.getElementsByClassName || div.getElementsByClassName("e").length === 0 ) { + return; + } + + // Safari caches class attributes, doesn't catch changes (in 3.2) + div.lastChild.className = "e"; + + if ( div.getElementsByClassName("e").length === 1 ) { + return; + } + + Expr.order.splice(1, 0, "CLASS"); + Expr.find.CLASS = function( match, context, isXML ) { + if ( typeof context.getElementsByClassName !== "undefined" && !isXML ) { + return context.getElementsByClassName(match[1]); + } + }; + + // release memory in IE + div = null; +})(); + +function dirNodeCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) { + for ( var i = 0, l = checkSet.length; i < l; i++ ) { + var elem = checkSet[i]; + + if ( elem ) { + var match = false; + + elem = elem[dir]; + + while ( elem ) { + if ( elem[ expando ] === doneName ) { + match = checkSet[elem.sizset]; + break; + } + + if ( elem.nodeType === 1 && !isXML ){ + elem[ expando ] = doneName; + elem.sizset = i; + } + + if ( elem.nodeName.toLowerCase() === cur ) { + match = elem; + break; + } + + elem = elem[dir]; + } + + checkSet[i] = match; + } + } +} + +function dirCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) { + for ( var i = 0, l = checkSet.length; i < l; i++ ) { + var elem = checkSet[i]; + + if ( elem ) { + var match = false; + + elem = elem[dir]; + + while ( elem ) { + if ( elem[ expando ] === doneName ) { + match = checkSet[elem.sizset]; + break; + } + + if ( elem.nodeType === 1 ) { + if ( !isXML ) { + elem[ expando ] = doneName; + elem.sizset = i; + } + + if ( typeof cur !== "string" ) { + if ( elem === cur ) { + match = true; + break; + } + + } else if ( Sizzle.filter( cur, [elem] ).length > 0 ) { + match = elem; + break; + } + } + + elem = elem[dir]; + } + + checkSet[i] = match; + } + } +} + +if ( document.documentElement.contains ) { + Sizzle.contains = function( a, b ) { + return a !== b && (a.contains ? a.contains(b) : true); + }; + +} else if ( document.documentElement.compareDocumentPosition ) { + Sizzle.contains = function( a, b ) { + return !!(a.compareDocumentPosition(b) & 16); + }; + +} else { + Sizzle.contains = function() { + return false; + }; +} + +Sizzle.isXML = function( elem ) { + // documentElement is verified for cases where it doesn't yet exist + // (such as loading iframes in IE - #4833) + var documentElement = (elem ? elem.ownerDocument || elem : 0).documentElement; + + return documentElement ? documentElement.nodeName !== "HTML" : false; +}; + +var posProcess = function( selector, context, seed ) { + var match, + tmpSet = [], + later = "", + root = context.nodeType ? [context] : context; + + // Position selectors must be done after the filter + // And so must :not(positional) so we move all PSEUDOs to the end + while ( (match = Expr.match.PSEUDO.exec( selector )) ) { + later += match[0]; + selector = selector.replace( Expr.match.PSEUDO, "" ); + } + + selector = Expr.relative[selector] ? selector + "*" : selector; + + for ( var i = 0, l = root.length; i < l; i++ ) { + Sizzle( selector, root[i], tmpSet, seed ); + } + + return Sizzle.filter( later, tmpSet ); +}; + +// EXPOSE +// Override sizzle attribute retrieval +Sizzle.attr = jQuery.attr; +Sizzle.selectors.attrMap = {}; +jQuery.find = Sizzle; +jQuery.expr = Sizzle.selectors; +jQuery.expr[":"] = jQuery.expr.filters; +jQuery.unique = Sizzle.uniqueSort; +jQuery.text = Sizzle.getText; +jQuery.isXMLDoc = Sizzle.isXML; +jQuery.contains = Sizzle.contains; + + +})(); + + +var runtil = /Until$/, + rparentsprev = /^(?:parents|prevUntil|prevAll)/, + // Note: This RegExp should be improved, or likely pulled from Sizzle + rmultiselector = /,/, + isSimple = /^.[^:#\[\.,]*$/, + slice = Array.prototype.slice, + POS = jQuery.expr.match.POS, + // methods guaranteed to produce a unique set when starting from a unique set + guaranteedUnique = { + children: true, + contents: true, + next: true, + prev: true + }; + +jQuery.fn.extend({ + find: function( selector ) { + var self = this, + i, l; + + if ( typeof selector !== "string" ) { + return jQuery( selector ).filter(function() { + for ( i = 0, l = self.length; i < l; i++ ) { + if ( jQuery.contains( self[ i ], this ) ) { + return true; + } + } + }); + } + + var ret = this.pushStack( "", "find", selector ), + length, n, r; + + for ( i = 0, l = this.length; i < l; i++ ) { + length = ret.length; + jQuery.find( selector, this[i], ret ); + + if ( i > 0 ) { + // Make sure that the results are unique + for ( n = length; n < ret.length; n++ ) { + for ( r = 0; r < length; r++ ) { + if ( ret[r] === ret[n] ) { + ret.splice(n--, 1); + break; + } + } + } + } + } + + return ret; + }, + + has: function( target ) { + var targets = jQuery( target ); + return this.filter(function() { + for ( var i = 0, l = targets.length; i < l; i++ ) { + if ( jQuery.contains( this, targets[i] ) ) { + return true; + } + } + }); + }, + + not: function( selector ) { + return this.pushStack( winnow(this, selector, false), "not", selector); + }, + + filter: function( selector ) { + return this.pushStack( winnow(this, selector, true), "filter", selector ); + }, + + is: function( selector ) { + return !!selector && ( + typeof selector === "string" ? + // If this is a positional selector, check membership in the returned set + // so $("p:first").is("p:last") won't return true for a doc with two "p". + POS.test( selector ) ? + jQuery( selector, this.context ).index( this[0] ) >= 0 : + jQuery.filter( selector, this ).length > 0 : + this.filter( selector ).length > 0 ); + }, + + closest: function( selectors, context ) { + var ret = [], i, l, cur = this[0]; + + // Array (deprecated as of jQuery 1.7) + if ( jQuery.isArray( selectors ) ) { + var level = 1; + + while ( cur && cur.ownerDocument && cur !== context ) { + for ( i = 0; i < selectors.length; i++ ) { + + if ( jQuery( cur ).is( selectors[ i ] ) ) { + ret.push({ selector: selectors[ i ], elem: cur, level: level }); + } + } + + cur = cur.parentNode; + level++; + } + + return ret; + } + + // String + var pos = POS.test( selectors ) || typeof selectors !== "string" ? + jQuery( selectors, context || this.context ) : + 0; + + for ( i = 0, l = this.length; i < l; i++ ) { + cur = this[i]; + + while ( cur ) { + if ( pos ? pos.index(cur) > -1 : jQuery.find.matchesSelector(cur, selectors) ) { + ret.push( cur ); + break; + + } else { + cur = cur.parentNode; + if ( !cur || !cur.ownerDocument || cur === context || cur.nodeType === 11 ) { + break; + } + } + } + } + + ret = ret.length > 1 ? jQuery.unique( ret ) : ret; + + return this.pushStack( ret, "closest", selectors ); + }, + + // Determine the position of an element within + // the matched set of elements + index: function( elem ) { + + // No argument, return index in parent + if ( !elem ) { + return ( this[0] && this[0].parentNode ) ? this.prevAll().length : -1; + } + + // index in selector + if ( typeof elem === "string" ) { + return jQuery.inArray( this[0], jQuery( elem ) ); + } + + // Locate the position of the desired element + return jQuery.inArray( + // If it receives a jQuery object, the first element is used + elem.jquery ? elem[0] : elem, this ); + }, + + add: function( selector, context ) { + var set = typeof selector === "string" ? + jQuery( selector, context ) : + jQuery.makeArray( selector && selector.nodeType ? [ selector ] : selector ), + all = jQuery.merge( this.get(), set ); + + return this.pushStack( isDisconnected( set[0] ) || isDisconnected( all[0] ) ? + all : + jQuery.unique( all ) ); + }, + + andSelf: function() { + return this.add( this.prevObject ); + } +}); + +// A painfully simple check to see if an element is disconnected +// from a document (should be improved, where feasible). +function isDisconnected( node ) { + return !node || !node.parentNode || node.parentNode.nodeType === 11; +} + +jQuery.each({ + parent: function( elem ) { + var parent = elem.parentNode; + return parent && parent.nodeType !== 11 ? parent : null; + }, + parents: function( elem ) { + return jQuery.dir( elem, "parentNode" ); + }, + parentsUntil: function( elem, i, until ) { + return jQuery.dir( elem, "parentNode", until ); + }, + next: function( elem ) { + return jQuery.nth( elem, 2, "nextSibling" ); + }, + prev: function( elem ) { + return jQuery.nth( elem, 2, "previousSibling" ); + }, + nextAll: function( elem ) { + return jQuery.dir( elem, "nextSibling" ); + }, + prevAll: function( elem ) { + return jQuery.dir( elem, "previousSibling" ); + }, + nextUntil: function( elem, i, until ) { + return jQuery.dir( elem, "nextSibling", until ); + }, + prevUntil: function( elem, i, until ) { + return jQuery.dir( elem, "previousSibling", until ); + }, + siblings: function( elem ) { + return jQuery.sibling( elem.parentNode.firstChild, elem ); + }, + children: function( elem ) { + return jQuery.sibling( elem.firstChild ); + }, + contents: function( elem ) { + return jQuery.nodeName( elem, "iframe" ) ? + elem.contentDocument || elem.contentWindow.document : + jQuery.makeArray( elem.childNodes ); + } +}, function( name, fn ) { + jQuery.fn[ name ] = function( until, selector ) { + var ret = jQuery.map( this, fn, until ), + // The variable 'args' was introduced in + // https://github.com/jquery/jquery/commit/52a0238 + // to work around a bug in Chrome 10 (Dev) and should be removed when the bug is fixed. + // http://code.google.com/p/v8/issues/detail?id=1050 + args = slice.call(arguments); + + if ( !runtil.test( name ) ) { + selector = until; + } + + if ( selector && typeof selector === "string" ) { + ret = jQuery.filter( selector, ret ); + } + + ret = this.length > 1 && !guaranteedUnique[ name ] ? jQuery.unique( ret ) : ret; + + if ( (this.length > 1 || rmultiselector.test( selector )) && rparentsprev.test( name ) ) { + ret = ret.reverse(); + } + + return this.pushStack( ret, name, args.join(",") ); + }; +}); + +jQuery.extend({ + filter: function( expr, elems, not ) { + if ( not ) { + expr = ":not(" + expr + ")"; + } + + return elems.length === 1 ? + jQuery.find.matchesSelector(elems[0], expr) ? [ elems[0] ] : [] : + jQuery.find.matches(expr, elems); + }, + + dir: function( elem, dir, until ) { + var matched = [], + cur = elem[ dir ]; + + while ( cur && cur.nodeType !== 9 && (until === undefined || cur.nodeType !== 1 || !jQuery( cur ).is( until )) ) { + if ( cur.nodeType === 1 ) { + matched.push( cur ); + } + cur = cur[dir]; + } + return matched; + }, + + nth: function( cur, result, dir, elem ) { + result = result || 1; + var num = 0; + + for ( ; cur; cur = cur[dir] ) { + if ( cur.nodeType === 1 && ++num === result ) { + break; + } + } + + return cur; + }, + + sibling: function( n, elem ) { + var r = []; + + for ( ; n; n = n.nextSibling ) { + if ( n.nodeType === 1 && n !== elem ) { + r.push( n ); + } + } + + return r; + } +}); + +// Implement the identical functionality for filter and not +function winnow( elements, qualifier, keep ) { + + // Can't pass null or undefined to indexOf in Firefox 4 + // Set to 0 to skip string check + qualifier = qualifier || 0; + + if ( jQuery.isFunction( qualifier ) ) { + return jQuery.grep(elements, function( elem, i ) { + var retVal = !!qualifier.call( elem, i, elem ); + return retVal === keep; + }); + + } else if ( qualifier.nodeType ) { + return jQuery.grep(elements, function( elem, i ) { + return (elem === qualifier) === keep; + }); + + } else if ( typeof qualifier === "string" ) { + var filtered = jQuery.grep(elements, function( elem ) { + return elem.nodeType === 1; + }); + + if ( isSimple.test( qualifier ) ) { + return jQuery.filter(qualifier, filtered, !keep); + } else { + qualifier = jQuery.filter( qualifier, filtered ); + } + } + + return jQuery.grep(elements, function( elem, i ) { + return (jQuery.inArray( elem, qualifier ) >= 0) === keep; + }); +} + + + + +function createSafeFragment( document ) { + var nodeNames = ( + "abbr article aside audio canvas datalist details figcaption figure footer " + + "header hgroup mark meter nav output progress section summary time video" + ).split( " " ), + safeFrag = document.createDocumentFragment(); + + if ( safeFrag.createElement ) { + while ( nodeNames.length ) { + safeFrag.createElement( + nodeNames.pop() + ); + } + } + return safeFrag; +} + +var rinlinejQuery = / jQuery\d+="(?:\d+|null)"/g, + rleadingWhitespace = /^\s+/, + rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig, + rtagName = /<([\w:]+)/, + rtbody = /", "" ], + legend: [ 1, "
      ", "
      " ], + thead: [ 1, "", "
      " ], + tr: [ 2, "", "
      " ], + td: [ 3, "", "
      " ], + col: [ 2, "", "
      " ], + area: [ 1, "", "" ], + _default: [ 0, "", "" ] + }, + safeFragment = createSafeFragment( document ); + +wrapMap.optgroup = wrapMap.option; +wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead; +wrapMap.th = wrapMap.td; + +// IE can't serialize and