From bbb17fc14bc95c4a8f6fcba5706319af2d38677a Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Wed, 24 Aug 2011 12:17:35 +0800 Subject: [PATCH 001/169] Fixing jQuery not loading if running intro deck from file:// --- introduction/index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/introduction/index.html b/introduction/index.html index 9a06cdb8..59ccfe89 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -200,8 +200,8 @@

Digging Deeper

# - - + + From 46d52ce5f6776c1c7b0869e6a65c7a6b55ca3571 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Wed, 24 Aug 2011 17:02:49 +0800 Subject: [PATCH 002/169] Even more foolproof print css additions --- core/deck.core.css | 4 ++++ core/deck.core.scss | 13 ++++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/core/deck.core.css b/core/deck.core.css index 6fe75192..1c268cb6 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -301,6 +301,9 @@ body.deck-container { -ms-filter: none !important; -webkit-box-reflect: none !important; -moz-box-reflect: none !important; + -webkit-box-shadow: none !important; + -moz-box-shadow: none !important; + box-shadow: none !important; } * :before, * :after { display: none !important; @@ -376,6 +379,7 @@ body.deck-container { .deck-container { width: 100% !important; + height: auto !important; padding: 0 !important; display: block !important; } diff --git a/core/deck.core.scss b/core/deck.core.scss index d392ecdc..8dbcf0d0 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -362,7 +362,17 @@ body.deck-container { @media print { - * { background: transparent !important; color: black !important; text-shadow: none !important; filter:none !important; -ms-filter: none !important; -webkit-box-reflect:none !important; -moz-box-reflect:none !important; + * { + background: transparent !important; + color: black !important; + text-shadow: none !important; + filter:none !important; + -ms-filter: none !important; + -webkit-box-reflect:none !important; + -moz-box-reflect:none !important; + -webkit-box-shadow:none !important; + -moz-box-shadow:none !important; + box-shadow:none !important; :before, :after { display:none !important; @@ -406,6 +416,7 @@ body.deck-container { .deck-container { width:100% !important; + height:auto !important; padding:0 !important; display:block !important; } From 874b32b85b49bbdc402b88049feaafa874b27e58 Mon Sep 17 00:00:00 2001 From: Jon Buckley Date: Thu, 25 Aug 2011 14:59:31 -0400 Subject: [PATCH 003/169] Add touch event support for swiping between slides and showing the slide menu --- core/deck.core.js | 37 ++++++++++++++++++++++++++++++++++++ extensions/menu/deck.menu.js | 9 +++++++++ 2 files changed, 46 insertions(+) diff --git a/core/deck.core.js b/core/deck.core.js index e777ba38..e1f529cb 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -163,6 +163,43 @@ that use the API provided by core. } }); + /* Bind touch events for swiping between slides on touch devices */ + var startTouch; + $[deck]('getContainer').bind('touchstart', function(t) { + if (!startTouch) { + var touch = t.originalEvent.targetTouches[0]; + startTouch = {identifier: touch.identifier, + screenX: touch.screenX, + screenY: touch.screenY}; + } + }); + $[deck]('getContainer').bind('touchmove', function(t) { + t.preventDefault(); + var tar = t.originalEvent.changedTouches; + for (var i = 0; i < tar.length; i++) { + var touch = tar[i]; + if (startTouch && touch.identifier === startTouch.identifier) { + if (touch.screenX - startTouch.screenX > 100 || touch.screenY - startTouch.screenY > 100) { + $[deck]('prev'); + startTouch = undefined; + } else if (touch.screenX - startTouch.screenX < -100 || touch.screenY - startTouch.screenY < -100) { + $[deck]('next'); + startTouch = undefined; + } + } + } + + }); + $[deck]('getContainer').bind('touchend', function(t) { + var tar = t.originalEvent.changedTouches; + for (var i = 0; i < tar.length; i++) { + var touch = tar[i]; + if (startTouch && touch.identifier === startTouch.identifier) { + startTouch = undefined; + } + } + }); + /* Kick iframe videos, which dont like to redraw w/ transforms. Remove this if Webkit ever fixes it. diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 0e7309ff..91143c2d 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -73,6 +73,15 @@ on the deck container. $[deck]('toggleMenu'); } }); + + var touchEndTime; + $[deck]('getContainer').bind('touchend', function(t) { + if (Date.now() - touchEndTime < 400) { + $[deck]('toggleMenu'); + } + touchEndTime = Date.now(); + t.preventDefault(); + }); }) .bind('deck.change', function(e, from, to) { var container = $[deck]('getContainer'); From 6d6b8c2caaa623943011a56dc691935fa9db88ba Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 11:30:16 +0800 Subject: [PATCH 004/169] Amending jbuck's changes for style --- core/deck.core.js | 55 ++++++++++++++++++++---------------- extensions/menu/deck.menu.js | 25 ++++++++++++---- 2 files changed, 50 insertions(+), 30 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index e1f529cb..bcf80f9a 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -133,9 +133,15 @@ that use the API provided by core. ]); */ init: function(elements, opts) { + var startTouch, + $c, + tolerance; + options = $.extend(true, {}, $[deck].defaults, opts); slides = []; current = 0; + $c = $[deck]('getContainer'); + tolerance = options.touch.swipeTolerance; // Fill slides array depending on parameter type if ($.isArray(elements)) { @@ -164,40 +170,33 @@ that use the API provided by core. }); /* Bind touch events for swiping between slides on touch devices */ - var startTouch; - $[deck]('getContainer').bind('touchstart', function(t) { + $c.unbind('touchstart.deck').bind('touchstart.deck', function(e) { if (!startTouch) { - var touch = t.originalEvent.targetTouches[0]; - startTouch = {identifier: touch.identifier, - screenX: touch.screenX, - screenY: touch.screenY}; + startTouch = $.extend({}, e.originalEvent.targetTouches[0]); } - }); - $[deck]('getContainer').bind('touchmove', function(t) { - t.preventDefault(); - var tar = t.originalEvent.changedTouches; - for (var i = 0; i < tar.length; i++) { - var touch = tar[i]; - if (startTouch && touch.identifier === startTouch.identifier) { - if (touch.screenX - startTouch.screenX > 100 || touch.screenY - startTouch.screenY > 100) { + }) + .unbind('touchmove.deck').bind('touchmove.deck', function(e) { + $.each(e.originalEvent.changedTouches, function(i, t) { + if (startTouch && t.identifier === startTouch.identifier) { + if (t.screenX - startTouch.screenX > tolerance || t.screenY - startTouch.screenY > tolerance) { $[deck]('prev'); startTouch = undefined; - } else if (touch.screenX - startTouch.screenX < -100 || touch.screenY - startTouch.screenY < -100) { + } + else if (t.screenX - startTouch.screenX < -1 * tolerance || t.screenY - startTouch.screenY < -1 * tolerance) { $[deck]('next'); startTouch = undefined; } + return false; } - } - - }); - $[deck]('getContainer').bind('touchend', function(t) { - var tar = t.originalEvent.changedTouches; - for (var i = 0; i < tar.length; i++) { - var touch = tar[i]; - if (startTouch && touch.identifier === startTouch.identifier) { + }); + e.preventDefault(); + }) + .unbind('touchend.deck').bind('touchend.deck', function(t) { + $.each(t.originalEvent.changedTouches, function(i, t) { + if (startTouch && t.identifier === startTouch.identifier) { startTouch = undefined; } - } + }); }); /* @@ -373,6 +372,10 @@ that use the API provided by core. options.keys.previous The numeric keycode used to go to the previous slide. + + options.touch.swipeTolerance + The number of pixels the users finger must travel to produce a swipe + gesture. */ $[deck].defaults = { classes: { @@ -392,6 +395,10 @@ that use the API provided by core. keys: { next: 39, // right arrow key previous: 37 // left arrow key + }, + + touch: { + swipeTolerance: 100 } }; diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 91143c2d..851c12fa 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -23,6 +23,10 @@ on the deck container. options.keys.menu The numeric keycode used to toggle between showing and hiding the slide menu. + + options.touch.doubletapWindow + Two consecutive touch events within this number of milliseconds will + be considered a double tap, and will toggle the menu on touch devices. */ $.extend(true, $[deck].defaults, { classes: { @@ -31,6 +35,10 @@ on the deck container. keys: { menu: 77 // m + }, + + touch: { + doubletapWindow: 400 } }); @@ -67,20 +75,25 @@ on the deck container. }); $d.bind('deck.init', function() { + var opts = $[deck]('getOptions'), + touchEndTime = 0; + // Bind key events $d.bind('keydown.deck', function(e) { - if (e.which == $[deck]('getOptions').keys.menu) { + if (e.which == opts.keys.menu) { $[deck]('toggleMenu'); } }); - var touchEndTime; - $[deck]('getContainer').bind('touchend', function(t) { - if (Date.now() - touchEndTime < 400) { + // Double tap to toggle slide menu for touch devices + $[deck]('getContainer').bind('touchend.deck', function(e) { + var now = Date.now(); + + if (now - touchEndTime < opts.touch.doubletapWindow) { $[deck]('toggleMenu'); } - touchEndTime = Date.now(); - t.preventDefault(); + touchEndTime = now; + e.preventDefault(); }); }) .bind('deck.change', function(e, from, to) { From eba8fb54bc246da435b8ef8de554610c30e0127c Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 12:03:13 +0800 Subject: [PATCH 005/169] Removing scalability on intro deck for now --- core/deck.core.html | 2 +- introduction/index.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/deck.core.html b/core/deck.core.html index 15cf588d..bc6f519b 100644 --- a/core/deck.core.html +++ b/core/deck.core.html @@ -3,7 +3,7 @@ Codestin Search App - + diff --git a/introduction/index.html b/introduction/index.html index 59ccfe89..39241a04 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -11,7 +11,7 @@ - + From 6d24a21870c5ba287399ce990611e0f23503faea Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 12:09:37 +0800 Subject: [PATCH 006/169] Reducing default swipe tolerance --- core/deck.core.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/deck.core.js b/core/deck.core.js index bcf80f9a..8e5c6109 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -398,7 +398,7 @@ that use the API provided by core. }, touch: { - swipeTolerance: 100 + swipeTolerance: 60 } }; From 8b997bcb631e9f3aa063489b252358b5b5492ab1 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 12:22:39 +0800 Subject: [PATCH 007/169] Add checks to menu double tap so it doesn't fire if the user swipes fast --- extensions/menu/deck.menu.js | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 851c12fa..a9087f6a 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -76,7 +76,8 @@ on the deck container. $d.bind('deck.init', function() { var opts = $[deck]('getOptions'), - touchEndTime = 0; + touchEndTime = 0, + currentSlide; // Bind key events $d.bind('keydown.deck', function(e) { @@ -86,14 +87,20 @@ on the deck container. }); // Double tap to toggle slide menu for touch devices - $[deck]('getContainer').bind('touchend.deck', function(e) { + $[deck]('getContainer').bind('touchstart.deck', function(e) { + currentSlide = $[deck]('getSlide'); + }) + .bind('touchend.deck', function(e) { var now = Date.now(); + // Ignore this touch event if it caused a nav change (swipe) + if (currentSlide !== $[deck]('getSlide')) return; + if (now - touchEndTime < opts.touch.doubletapWindow) { $[deck]('toggleMenu'); + e.preventDefault(); } touchEndTime = now; - e.preventDefault(); }); }) .bind('deck.change', function(e, from, to) { From 8973f94bfdecd323a0e4d56e57be7721ba5e84cf Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 12:31:26 +0800 Subject: [PATCH 008/169] Remove nav buttons on touch devices in favor of swipes --- extensions/navigation/deck.navigation.css | 3 +-- extensions/navigation/deck.navigation.scss | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/extensions/navigation/deck.navigation.css b/extensions/navigation/deck.navigation.css index d7a52dcf..596fcbac 100644 --- a/extensions/navigation/deck.navigation.css +++ b/extensions/navigation/deck.navigation.css @@ -21,8 +21,7 @@ border-radius: 16px; } .touch .deck-container .deck-prev-link, .touch .deck-container .deck-next-link { - display: block; - -webkit-tap-highlight-color: rgba(0, 0, 0, 0); + display: none; } .deck-container .deck-prev-link:hover, .deck-container .deck-prev-link:focus, .deck-container .deck-prev-link:active, .deck-container .deck-prev-link:visited, .deck-container .deck-next-link:hover, .deck-container .deck-next-link:focus, .deck-container .deck-next-link:active, .deck-container .deck-next-link:visited { color: #fff; diff --git a/extensions/navigation/deck.navigation.scss b/extensions/navigation/deck.navigation.scss index 2416ebe9..4d53a2e7 100755 --- a/extensions/navigation/deck.navigation.scss +++ b/extensions/navigation/deck.navigation.scss @@ -27,8 +27,7 @@ } .touch & { - display:block; - -webkit-tap-highlight-color:rgba(0,0,0,0); + display:none; } &:hover, &:focus, &:active, &:visited { From 4e5146c278693c2d8a2f169d2444b50567791418 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 13:14:12 +0800 Subject: [PATCH 009/169] Update readme for print and contributors --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index 1dc445e9..dc64e7a1 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,16 @@ Unit tests are written with [Jasmine](http://pivotal.github.com/jasmine/) and [j deck.js has been tested with jQuery 1.6+ and works in IE7+, Chrome, FF, Safari, and Opera. The more capable browsers receive greater enhancements, but a basic cutaway slideshow will work for all browsers listed above. Please don't give your presentations in IE6. +## Printing + +Core includes stripped down black and white print styles for the standard slide template that is suitable for handouts. + +## Awesome People + +Big thanks to the folks who have contributed code to the project: + +- [jbuck](https://github.com/jbuck) - Touch controls. + ## License Copyright (c) 2011 Caleb Troughton From c88c250d6c1313c2437d51d44d1f2b18b6dbb9fa Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 13:21:27 +0800 Subject: [PATCH 010/169] Updating In-The-Works --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index dc64e7a1..fe6b1c4f 100644 --- a/README.md +++ b/README.md @@ -35,4 +35,4 @@ Dual licensed under the [MIT license](https://github.com/imakewebthings/deck.js/ ## In the Works -- Add touch gesture controls to certain modules. \ No newline at end of file +- Auto resizing of slides to the browser size. \ No newline at end of file From a89ed6ec7cba50dd1f2f9b47594f918ab0575a1f Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 14:17:49 +0800 Subject: [PATCH 011/169] Really remove nav buttons on touch devices this time (on hover) --- extensions/navigation/deck.navigation.css | 5 +---- extensions/navigation/deck.navigation.scss | 6 +----- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/extensions/navigation/deck.navigation.css b/extensions/navigation/deck.navigation.css index 596fcbac..e1ebad8b 100644 --- a/extensions/navigation/deck.navigation.css +++ b/extensions/navigation/deck.navigation.css @@ -20,9 +20,6 @@ -moz-border-radius: 16px; border-radius: 16px; } -.touch .deck-container .deck-prev-link, .touch .deck-container .deck-next-link { - display: none; -} .deck-container .deck-prev-link:hover, .deck-container .deck-prev-link:focus, .deck-container .deck-prev-link:active, .deck-container .deck-prev-link:visited, .deck-container .deck-next-link:hover, .deck-container .deck-next-link:focus, .deck-container .deck-next-link:active, .deck-container .deck-next-link:visited { color: #fff; } @@ -35,7 +32,7 @@ .deck-container:hover .deck-prev-link, .deck-container:hover .deck-next-link { display: block; } -.deck-container:hover .deck-prev-link.deck-nav-disabled, .deck-container:hover .deck-next-link.deck-nav-disabled { +.deck-container:hover .deck-prev-link.deck-nav-disabled, .touch .deck-container:hover .deck-prev-link, .deck-container:hover .deck-next-link.deck-nav-disabled, .touch .deck-container:hover .deck-next-link { display: none; } diff --git a/extensions/navigation/deck.navigation.scss b/extensions/navigation/deck.navigation.scss index 4d53a2e7..815602ff 100755 --- a/extensions/navigation/deck.navigation.scss +++ b/extensions/navigation/deck.navigation.scss @@ -25,10 +25,6 @@ .borderradius & { @include border-radius(16px); } - - .touch & { - display:none; - } &:hover, &:focus, &:active, &:visited { color:#fff; @@ -46,7 +42,7 @@ &:hover .deck-prev-link, &:hover .deck-next-link { display:block; - &.deck-nav-disabled { + &.deck-nav-disabled, .touch & { display:none; } } From 2dbbc31e5ed58cbd9320448b5f86ebea38f8c82b Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 27 Aug 2011 11:29:32 +0800 Subject: [PATCH 012/169] Unload iframe sources when navigating away from a slide as a patch to #16 --- core/deck.core.js | 37 +++++++++++++++++++++---- themes/transition/horizontal-slide.css | 17 ++++-------- themes/transition/horizontal-slide.scss | 14 ++++++---- themes/transition/vertical-slide.css | 17 ++++-------- themes/transition/vertical-slide.scss | 14 ++++++---- 5 files changed, 60 insertions(+), 39 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index 8e5c6109..7ee27daf 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -204,12 +204,14 @@ that use the API provided by core. Remove this if Webkit ever fixes it. */ $.each(slides, function(i, $el) { - $el.unbind('webkitTransitionEnd').bind('webkitTransitionEnd', + $el.unbind('webkitTransitionEnd.deck').bind('webkitTransitionEnd.deck', function(event) { - var embeds = $(this).find('iframe').css('opacity', 0); - window.setTimeout(function() { - embeds.css('opacity', 1); - }, 100); + if ($el.hasClass($[deck]('getOptions').classes.current)) { + var embeds = $(this).find('iframe').css('opacity', 0); + window.setTimeout(function() { + embeds.css('opacity', 1); + }, 100); + } }); }); @@ -405,4 +407,29 @@ that use the API provided by core. $d.ready(function() { $('html').addClass('ready'); }); + + /* + FF + Transforms + Flash video don't get along... + Firefox will reload and start playing certain videos after a + transform. Blanking the src when a previously shown slide goes out + of view prevents this. + */ + $d.bind('deck.change', function(e, from, to) { + var oldFrames = $[deck]('getSlide', from).find('iframe'), + newFrames = $[deck]('getSlide', to).find('iframe'); + + oldFrames.each(function() { + var $this = $(this); + $this.data('deck-src', $this.attr('src')).attr('src', ''); + }); + + newFrames.each(function() { + var $this = $(this), + originalSrc = $this.data('deck-src'); + + if (originalSrc) { + $this.attr('src', originalSrc); + } + }); + }); })(jQuery, 'deck', document); \ No newline at end of file diff --git a/themes/transition/horizontal-slide.css b/themes/transition/horizontal-slide.css index 6015d305..a768d615 100644 --- a/themes/transition/horizontal-slide.css +++ b/themes/transition/horizontal-slide.css @@ -28,13 +28,6 @@ -o-transition: -o-transform 500ms ease-in-out, opacity 500ms ease-in-out; transition: -webkit-transform 500ms ease-in-out, opacity 500ms ease-in-out; } -.csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-before, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-previous, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-current { - -webkit-transform: translate3d(0, 0, 0); - -moz-transform: translate(0, 0); - -ms-transform: translate(0, 0); - -o-transform: translate(0, 0); - transform: translate3d(0, 0, 0); -} .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-next, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-after { visibility: visible; -webkit-transform: translate3d(200%, 0, 0); @@ -78,9 +71,9 @@ visibility: visible; } .csstransitions.csstransforms .deck-container:not(.deck-menu) > .deck-child-current { - -webkit-transform: translate3d(0, 0, 0); - -moz-transform: translate(0, 0); - -ms-transform: translate(0, 0); - -o-transform: translate(0, 0); - transform: translate3d(0, 0, 0); + -webkit-transform: none; + -moz-transform: none; + -ms-transform: none; + -o-transform: none; + transform: none; } diff --git a/themes/transition/horizontal-slide.scss b/themes/transition/horizontal-slide.scss index 58d322ea..90a30a09 100644 --- a/themes/transition/horizontal-slide.scss +++ b/themes/transition/horizontal-slide.scss @@ -14,6 +14,14 @@ transition:$prop $duration $easing $delay; } +@mixin transform($val) { + -webkit-transform:$val; + -moz-transform:$val; + -ms-transform:$val; + -o-transform:$val; + transform:$val; +} + .csstransitions.csstransforms { overflow-x:hidden; @@ -47,10 +55,6 @@ transition:-webkit-transform 500ms ease-in-out, opacity 500ms ease-in-out; } - .deck-before, .deck-previous, .deck-current { - @include translate; - } - .deck-next, .deck-after { visibility:visible; @include translate(200%); @@ -84,7 +88,7 @@ } > .deck-child-current { - @include translate; + @include transform(none); } } } \ No newline at end of file diff --git a/themes/transition/vertical-slide.css b/themes/transition/vertical-slide.css index 6e3787ad..f9c02ec0 100644 --- a/themes/transition/vertical-slide.css +++ b/themes/transition/vertical-slide.css @@ -28,13 +28,6 @@ -o-transition: -o-transform 500ms ease-in-out, opacity 500ms ease-in-out; transition: -webkit-transform 500ms ease-in-out, opacity 500ms ease-in-out; } -.csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-before, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-previous, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-current { - -webkit-transform: translate3d(0, 0, 0); - -moz-transform: translate(0, 0); - -ms-transform: translate(0, 0); - -o-transform: translate(0, 0); - transform: translate3d(0, 0, 0); -} .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-next, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-after { visibility: visible; -webkit-transform: translate3d(0, 1600px, 0); @@ -78,11 +71,11 @@ visibility: visible; } .csstransitions.csstransforms .deck-container:not(.deck-menu) > .deck-child-current { - -webkit-transform: translate3d(0, 0, 0); - -moz-transform: translate(0, 0); - -ms-transform: translate(0, 0); - -o-transform: translate(0, 0); - transform: translate3d(0, 0, 0); + -webkit-transform: none; + -moz-transform: none; + -ms-transform: none; + -o-transform: none; + transform: none; } .csstransitions.csstransforms .deck-prev-link { left: auto; diff --git a/themes/transition/vertical-slide.scss b/themes/transition/vertical-slide.scss index 20cf041e..7277316e 100644 --- a/themes/transition/vertical-slide.scss +++ b/themes/transition/vertical-slide.scss @@ -22,6 +22,14 @@ transition:$prop $duration $easing $delay; } +@mixin transform($val) { + -webkit-transform:$val; + -moz-transform:$val; + -ms-transform:$val; + -o-transform:$val; + transform:$val; +} + .csstransitions.csstransforms { .deck-container { overflow-y:hidden; @@ -57,10 +65,6 @@ transition:-webkit-transform 500ms ease-in-out, opacity 500ms ease-in-out; } - .deck-before, .deck-previous, .deck-current { - @include translate; - } - .deck-next, .deck-after { visibility:visible; @include translate(0, 1600px); @@ -94,7 +98,7 @@ } > .deck-child-current { - @include translate; + @include transform(none); } } From 88b72478e5aff72b51bd95c36f5d33d493b2c8a0 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 10:13:05 +0800 Subject: [PATCH 013/169] Adding empty scale --- extensions/scale/deck.scale.js | 38 ++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 extensions/scale/deck.scale.js diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js new file mode 100644 index 00000000..b718e899 --- /dev/null +++ b/extensions/scale/deck.scale.js @@ -0,0 +1,38 @@ +/*! +Deck JS - deck.scale - v1.0 +Copyright (c) 2011 Caleb Troughton +Dual licensed under the MIT license and GPL license. +https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt +https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt +*/ + +/* + +*/ +(function($, deck, undefined) { + var $d = $(document); + + /* + Extends defaults/options. + + options.classes.menu + This class is added to the deck container when showing the slide menu. + + options.keys.menu + The numeric keycode used to toggle between showing and hiding the slide + menu. + */ + $.extend(true, $[deck].defaults, { + + }); + + + + $d.bind('deck.init', function() { + + }) + .bind('deck.change', function(e, from, to) { + + }); +})(jQuery, 'deck'); + From 88109bec4187450ef6f55f11f00a41db36873278 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 26 Aug 2011 22:09:03 +0800 Subject: [PATCH 014/169] First rough take at scaling --- extensions/scale/deck.scale.css | 7 +++ extensions/scale/deck.scale.js | 74 ++++++++++++++++++++++++++------ extensions/scale/deck.scale.scss | 7 +++ introduction/index.html | 2 + 4 files changed, 77 insertions(+), 13 deletions(-) create mode 100644 extensions/scale/deck.scale.css create mode 100644 extensions/scale/deck.scale.scss diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css new file mode 100644 index 00000000..4e396cfe --- /dev/null +++ b/extensions/scale/deck.scale.css @@ -0,0 +1,7 @@ +.deck-container.deck-scale { + -webkit-transform-origin: 50% 0; + -moz-transform-origin: 50% 0; + -o-transform-origin: 50% 0; + -ms-transform-origin: 50% 0; + transform-origin: 50% 0; +} diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index b718e899..510e6cf5 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -9,30 +9,78 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt /* */ -(function($, deck, undefined) { - var $d = $(document); +(function($, deck, window, undefined) { + var $d = $(document), + $w = $(window), + baseHeight, + didResize, + scaleDeck = function() { + var obh = $[deck]('getOptions').baseHeight, + container = $[deck]('getContainer'), + height = $w.height(), + slides = $[deck]('getSlides'), + scale; + + // Use tallest slide as base height if not set manually + baseHeight = obh ? obh : (function() { + var greatest = 0; + + $.each(slides, function(i, $slide) { + greatest = Math.max(greatest, $slide.outerHeight()); + }); + + return greatest; + })(); + + scale = height / baseHeight; + + if (!$[deck]('getOptions').scaleUp && scale > 1) { + scale = 1; + } + + $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { + container.css(prefix + 'Transform', 'scale(' + scale + ')'); + }); + }; + /* Extends defaults/options. - options.classes.menu - This class is added to the deck container when showing the slide menu. - options.keys.menu - The numeric keycode used to toggle between showing and hiding the slide - menu. */ $.extend(true, $[deck].defaults, { - + classes: { + scale: 'deck-scale' + }, + baseHeight: 0, + scaleThrottle: 500, + scaleUp: false }); - - $d.bind('deck.init', function() { + // Only care about scaling non-embedded presentations + if (!$[deck]('getContainer').is('body')) return; - }) - .bind('deck.change', function(e, from, to) { + $[deck]('getContainer').addClass($[deck]('getOptions').classes.scale); + // Throttle scaling on resize + $w.unbind('resize.deckscale').bind('resize.deckscale', function() { + if (!didResize) { + didResize = true; + window.setTimeout(function() { + scaleDeck(); + didResize = false; + }, $[deck]('getOptions').scaleThrottle); + } + }) + // Scale once on load, in case images or something change layout + .unbind('load.deckscale').bind('load.deckscale', scaleDeck); + + // Scale once on init + scaleDeck(); }); -})(jQuery, 'deck'); + + // Scale again on load, in case images or anything else changed layout +})(jQuery, 'deck', this); diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss new file mode 100644 index 00000000..97afe7cd --- /dev/null +++ b/extensions/scale/deck.scale.scss @@ -0,0 +1,7 @@ +.deck-container.deck-scale { + -webkit-transform-origin: 50% 0; + -moz-transform-origin: 50% 0; + -o-transform-origin: 50% 0; + -ms-transform-origin: 50% 0; + transform-origin: 50% 0; +} \ No newline at end of file diff --git a/introduction/index.html b/introduction/index.html index 39241a04..13e1f42e 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -20,6 +20,7 @@ + @@ -210,6 +211,7 @@

Digging Deeper

+ From 33a43692d435ae780c9f2a5fc7fa8e27a8a25388 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 27 Aug 2011 16:59:22 +0800 Subject: [PATCH 015/169] Add scale tests --- test/index.html | 3 ++- test/spec.scale.js | 58 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 60 insertions(+), 1 deletion(-) create mode 100644 test/spec.scale.js diff --git a/test/index.html b/test/index.html index 137b07e5..ddd265b1 100644 --- a/test/index.html +++ b/test/index.html @@ -17,6 +17,7 @@ + @@ -25,8 +26,8 @@ - + diff --git a/test/spec.scale.js b/test/spec.scale.js new file mode 100644 index 00000000..f62e38c1 --- /dev/null +++ b/test/spec.scale.js @@ -0,0 +1,58 @@ +describe('Deck JS Status Indicator', function() { + beforeEach(function() { + loadFixtures('standard.html'); + if (Modernizr.history) { + history.replaceState({}, "", "#") + } + else { + window.location.hash = '#'; + } + $.deck('.slide'); + }); + + describe('initial settings', function() { + it('should start with the scale class applied', function() { + expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); + }); + }); + + describe('removeScale()', function() { + it('should remove the scale class from the container', function() { + $.deck('removeScale'); + expect($.deck('getContainer').not.toHaveClass(defaults.classes.scale)); + }); + }); + + describe('scale()', function() { + it('should add the scale class to the container', function() { + $.deck('removeScale'); + $.deck('scale'); + expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); + }); + }); + + describe('toggleScale()', function() { + it('should toggle between adding and removing the scale class', function() { + $.deck('toggleScale'); + expect($.deck('getContainer').not.toHaveClass(defaults.classes.scale)); + $.deck('toggleScale'); + expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); + }); + }); + + describe('key bindings', function() { + var e; + + beforeEach(function() { + e = jQuery.Event('keydown.deck'); + }); + + it('should toggle scaling if the specified key is pressed', function() { + e.which = 83; // s + $d.trigger(e); + expect($.deck('getContainer').not.toHaveClass(defaults.classes.scale)); + $d.trigger(e); + expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); + }); + }); +}); \ No newline at end of file From c2ed09d3f056ac43ac07591f473f2a661c260e65 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 27 Aug 2011 21:51:41 +0800 Subject: [PATCH 016/169] Working version of deck.scale --- extensions/scale/deck.scale.css | 3 +- extensions/scale/deck.scale.js | 94 ++++++++++++++++++++------------ extensions/scale/deck.scale.scss | 3 +- introduction/index.html | 2 - test/spec.scale.js | 23 ++++---- 5 files changed, 75 insertions(+), 50 deletions(-) diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index 4e396cfe..7695988d 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -1,4 +1,5 @@ -.deck-container.deck-scale { +.csstransforms .deck-container.deck-scale { + width: auto; -webkit-transform-origin: 50% 0; -moz-transform-origin: 50% 0; -o-transform-origin: 50% 0; diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index 510e6cf5..0e0571ab 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -13,34 +13,37 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt var $d = $(document), $w = $(window), baseHeight, - didResize, + timer, // Timeout id for debouncing scaleDeck = function() { var obh = $[deck]('getOptions').baseHeight, - container = $[deck]('getContainer'), + $container = $[deck]('getContainer'), height = $w.height(), slides = $[deck]('getSlides'), - scale; + scale, + transform; - // Use tallest slide as base height if not set manually - baseHeight = obh ? obh : (function() { - var greatest = 0; - - $.each(slides, function(i, $slide) { - greatest = Math.max(greatest, $slide.outerHeight()); - }); - - return greatest; - })(); - - scale = height / baseHeight; - - if (!$[deck]('getOptions').scaleUp && scale > 1) { + if (!$container.hasClass($[deck]('getOptions').classes.scale)) { scale = 1; } + else { + // Use tallest slide as base height if not set manually + baseHeight = obh ? obh : (function() { + var greatest = 0; + + $.each(slides, function(i, $slide) { + greatest = Math.max(greatest, $slide.outerHeight()); + }); + + return greatest; + })(); + + scale = height / baseHeight; + } + transform = scale >= 1 ? 'none' : 'scale(' + scale + ')'; $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { - container.css(prefix + 'Transform', 'scale(' + scale + ')'); + $container.css(prefix + 'Transform', transform); }); }; @@ -53,34 +56,57 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt classes: { scale: 'deck-scale' }, - baseHeight: 0, - scaleThrottle: 500, - scaleUp: false + + keys: { + scale: 83 // s + }, + + baseHeight: null, + scaleDebounce: 200 + }); + + $[deck]('extend', 'removeScale', function() { + $[deck]('getContainer').removeClass($[deck]('getOptions').classes.scale); + scaleDeck(); + }); + + $[deck]('extend', 'scale', function() { + $[deck]('getContainer').addClass($[deck]('getOptions').classes.scale); + scaleDeck(); + }); + + $[deck]('extend', 'toggleScale', function() { + var $c = $[deck]('getContainer'); + $[deck]($c.hasClass($[deck]('getOptions').classes.scale) ? + 'removeScale' : 'scale'); }); $d.bind('deck.init', function() { - // Only care about scaling non-embedded presentations - if (!$[deck]('getContainer').is('body')) return; + var opts = $[deck]('getOptions'); - $[deck]('getContainer').addClass($[deck]('getOptions').classes.scale); + // Only care about scaling in modern browsers + if (!Modernizr.csstransforms) return; - // Throttle scaling on resize + // Scaling enabled at start + $[deck]('getContainer').addClass(opts.classes.scale); + + // Debounce the resize scaling $w.unbind('resize.deckscale').bind('resize.deckscale', function() { - if (!didResize) { - didResize = true; - window.setTimeout(function() { - scaleDeck(); - didResize = false; - }, $[deck]('getOptions').scaleThrottle); - } + window.clearTimeout(timer); + timer = window.setTimeout(scaleDeck, opts.scaleDebounce); }) // Scale once on load, in case images or something change layout .unbind('load.deckscale').bind('load.deckscale', scaleDeck); + // Bind key events + $d.unbind('keydown.deckscale').bind('keydown.deckscale', function(e) { + if (e.which === opts.keys.scale) { + $[deck]('toggleScale'); + } + }); + // Scale once on init scaleDeck(); }); - - // Scale again on load, in case images or anything else changed layout })(jQuery, 'deck', this); diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index 97afe7cd..94d8ccb6 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -1,4 +1,5 @@ -.deck-container.deck-scale { +.csstransforms .deck-container.deck-scale { + width:auto; -webkit-transform-origin: 50% 0; -moz-transform-origin: 50% 0; -o-transform-origin: 50% 0; diff --git a/introduction/index.html b/introduction/index.html index 13e1f42e..39241a04 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -20,7 +20,6 @@ - @@ -211,7 +210,6 @@

Digging Deeper

- diff --git a/test/spec.scale.js b/test/spec.scale.js index f62e38c1..44cd7233 100644 --- a/test/spec.scale.js +++ b/test/spec.scale.js @@ -10,16 +10,14 @@ describe('Deck JS Status Indicator', function() { $.deck('.slide'); }); - describe('initial settings', function() { - it('should start with the scale class applied', function() { - expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); - }); + it('should start with scaling enabled', function() { + expect($.deck('getContainer')).toHaveClass(defaults.classes.scale); }); describe('removeScale()', function() { it('should remove the scale class from the container', function() { $.deck('removeScale'); - expect($.deck('getContainer').not.toHaveClass(defaults.classes.scale)); + expect($.deck('getContainer')).not.toHaveClass(defaults.classes.scale); }); }); @@ -27,32 +25,33 @@ describe('Deck JS Status Indicator', function() { it('should add the scale class to the container', function() { $.deck('removeScale'); $.deck('scale'); - expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); + expect($.deck('getContainer')).toHaveClass(defaults.classes.scale); }); }); describe('toggleScale()', function() { it('should toggle between adding and removing the scale class', function() { $.deck('toggleScale'); - expect($.deck('getContainer').not.toHaveClass(defaults.classes.scale)); + expect($.deck('getContainer')).not.toHaveClass(defaults.classes.scale); $.deck('toggleScale'); - expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); + expect($.deck('getContainer')).toHaveClass(defaults.classes.scale); }); }); describe('key bindings', function() { - var e; + var e, + $d = $(document); beforeEach(function() { - e = jQuery.Event('keydown.deck'); + e = jQuery.Event('keydown.deckscale'); }); it('should toggle scaling if the specified key is pressed', function() { e.which = 83; // s $d.trigger(e); - expect($.deck('getContainer').not.toHaveClass(defaults.classes.scale)); + expect($.deck('getContainer')).not.toHaveClass(defaults.classes.scale); $d.trigger(e); - expect($.deck('getContainer').toHaveClass(defaults.classes.scale)); + expect($.deck('getContainer')).toHaveClass(defaults.classes.scale); }); }); }); \ No newline at end of file From 5dbec4501489edc8ae5f99e99d8049e28f65c4e4 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sun, 28 Aug 2011 15:22:08 +0800 Subject: [PATCH 017/169] Update inline documentation --- extensions/scale/deck.scale.js | 50 +++++++++++++++++++++++++++++++--- 1 file changed, 46 insertions(+), 4 deletions(-) diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index 0e0571ab..f73812c1 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -7,14 +7,25 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt */ /* +This module adds automatic scaling to the deck. It should only be used on +standalone decks where the body is the deck container. Slides are scaled down +using CSS transforms to fit within the browser window. If the browser window +is big enough to hold the slides without scaling, no scaling occurs. The user +can disable and enable scaling with a keyboard shortcut. +Note: CSS transforms make Flash videos render incorrectly. Presenters that +need to use video will want to disable scaling to play them. HTML5 video +works fine. */ (function($, deck, window, undefined) { var $d = $(document), $w = $(window), - baseHeight, + baseHeight, // Value to scale against timer, // Timeout id for debouncing + /* + Internal function to do all the dirty work of scaling the deck container. + */ scaleDeck = function() { var obh = $[deck]('getOptions').baseHeight, $container = $[deck]('getContainer'), @@ -23,6 +34,7 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt scale, transform; + // Don't scale if scaling disabled if (!$container.hasClass($[deck]('getOptions').classes.scale)) { scale = 1; } @@ -41,6 +53,7 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt scale = height / baseHeight; } + // Scale, but don't scale up transform = scale >= 1 ? 'none' : 'scale(' + scale + ')'; $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { $container.css(prefix + 'Transform', transform); @@ -50,6 +63,23 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt /* Extends defaults/options. + options.classes.scale + This class is added to the deck container when scaling is enabled. + It is enabled by default when the module is included. + + options.keys.scale + The numeric keycode used to toggle enabling and disabling scaling. + + options.baseHeight + When baseheight is falsy, as it is by default, the deck is scaled + in proportion to the height of the slides. You may instead specify + a height, and the deck will be scaled against this height regardless + of the actual content height. + + options.scaleDebounce + Scaling on the browser resize event is debounced. This number is the + threshold in milliseconds. You can learn more about debouncing here: + http://unscriptable.com/index.php/2009/03/20/debouncing-javascript-methods/ */ $.extend(true, $[deck].defaults, { @@ -65,16 +95,31 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt scaleDebounce: 200 }); + /* + jQuery.deck('removeScale') + + Disables scaling and removes the scale class from the deck container. + */ $[deck]('extend', 'removeScale', function() { $[deck]('getContainer').removeClass($[deck]('getOptions').classes.scale); scaleDeck(); }); + /* + jQuery.deck('scale') + + Enables scaling and adds the scale class to the deck container. + */ $[deck]('extend', 'scale', function() { $[deck]('getContainer').addClass($[deck]('getOptions').classes.scale); scaleDeck(); }); + /* + jQuery.deck('toggleScale') + + Toggles between enabling and disabling scaling. + */ $[deck]('extend', 'toggleScale', function() { var $c = $[deck]('getContainer'); $[deck]($c.hasClass($[deck]('getOptions').classes.scale) ? @@ -84,9 +129,6 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt $d.bind('deck.init', function() { var opts = $[deck]('getOptions'); - // Only care about scaling in modern browsers - if (!Modernizr.csstransforms) return; - // Scaling enabled at start $[deck]('getContainer').addClass(opts.classes.scale); From f33a497ca5de5be2485836c581a49bca9bc974d7 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 15:43:43 +0800 Subject: [PATCH 018/169] Changing scale method names to something more accurate --- extensions/scale/deck.scale.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index f73812c1..a974c36e 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -96,21 +96,21 @@ works fine. }); /* - jQuery.deck('removeScale') + jQuery.deck('disableScale') Disables scaling and removes the scale class from the deck container. */ - $[deck]('extend', 'removeScale', function() { + $[deck]('extend', 'disableScale', function() { $[deck]('getContainer').removeClass($[deck]('getOptions').classes.scale); scaleDeck(); }); /* - jQuery.deck('scale') + jQuery.deck('enableScale') Enables scaling and adds the scale class to the deck container. */ - $[deck]('extend', 'scale', function() { + $[deck]('extend', 'enableScale', function() { $[deck]('getContainer').addClass($[deck]('getOptions').classes.scale); scaleDeck(); }); @@ -123,7 +123,7 @@ works fine. $[deck]('extend', 'toggleScale', function() { var $c = $[deck]('getContainer'); $[deck]($c.hasClass($[deck]('getOptions').classes.scale) ? - 'removeScale' : 'scale'); + 'disableScale' : 'enableScale'); }); $d.bind('deck.init', function() { From dad3f134375c6a5f1137c9b9f6251933872b2b0d Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 16:05:52 +0800 Subject: [PATCH 019/169] Update tests with new method names --- test/spec.scale.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test/spec.scale.js b/test/spec.scale.js index 44cd7233..0976ba18 100644 --- a/test/spec.scale.js +++ b/test/spec.scale.js @@ -14,17 +14,17 @@ describe('Deck JS Status Indicator', function() { expect($.deck('getContainer')).toHaveClass(defaults.classes.scale); }); - describe('removeScale()', function() { + describe('disableScale()', function() { it('should remove the scale class from the container', function() { - $.deck('removeScale'); + $.deck('disableScale'); expect($.deck('getContainer')).not.toHaveClass(defaults.classes.scale); }); }); - describe('scale()', function() { + describe('enableScale()', function() { it('should add the scale class to the container', function() { - $.deck('removeScale'); - $.deck('scale'); + $.deck('disableScale'); + $.deck('enableScale'); expect($.deck('getContainer')).toHaveClass(defaults.classes.scale); }); }); From 4e7369ed15693e7d44a959084cf1cbb6f22e87d0 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 16:30:49 +0800 Subject: [PATCH 020/169] Updating intro deck for touch controls and some rewording --- introduction/index.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/introduction/index.html b/introduction/index.html index 39241a04..54fa2a06 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -105,7 +105,7 @@

Transition Themes

Extensions

-

Core gives you basic slide functionality with left and right arrow navigation, but you may want more. This deck includes all of them, so feel free to play around.

+

Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here the ones included in this deck:

  • @@ -117,11 +117,11 @@

    Extensions

  • - deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. + deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. Touch devices can double-tap the deck to switch between views.
  • - deck.navigation: Adds clickable left and right buttons for the less keyboard inclined. + deck.navigation: Adds clickable left and right buttons for the less keyboard inclined.
  • @@ -129,7 +129,7 @@

    Extensions

-

Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files.

+

Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

From 1ea58e534e48a637c5fdd4859e6098463124d4cc Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 16:34:30 +0800 Subject: [PATCH 021/169] Typo --- introduction/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/introduction/index.html b/introduction/index.html index 54fa2a06..f6382958 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -105,7 +105,7 @@

Transition Themes

Extensions

-

Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here the ones included in this deck:

+

Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

  • From 9bf485aeb9123d7b80fdbbb99f97961f48f03da8 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 16:59:49 +0800 Subject: [PATCH 022/169] Removing In-The-Works --- README.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/README.md b/README.md index fe6b1c4f..d9f8fed2 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,3 @@ Big thanks to the folks who have contributed code to the project: Copyright (c) 2011 Caleb Troughton Dual licensed under the [MIT license](https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt) and [GPL license](https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt). - -## In the Works - -- Auto resizing of slides to the browser size. \ No newline at end of file From 62123e70e69546b60d38d16dfcd73fc0b0cdde23 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 20:54:18 +0800 Subject: [PATCH 023/169] #18: Add safety check for e.originalEvent inside hashchange --- extensions/hash/deck.hash.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/hash/deck.hash.js b/extensions/hash/deck.hash.js index 24bab755..690a56d6 100644 --- a/extensions/hash/deck.hash.js +++ b/extensions/hash/deck.hash.js @@ -100,7 +100,7 @@ the hashPrefix option. /* Deals with internal links in modern browsers */ $window.bind('hashchange.deck', function(e) { - if (e.originalEvent.newURL) { + if (e.originalEvent && e.originalEvent.newURL) { goByHash(e.originalEvent.newURL); } else { From a604db73545f9337c79e2da3d83cab34ebe5eca8 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 22:56:34 +0800 Subject: [PATCH 024/169] Fixes #3: Update nav links with fragment ids if they exist --- extensions/navigation/deck.navigation.js | 23 +++++++++++++++++------ test/spec.navigation.js | 8 ++++++++ 2 files changed, 25 insertions(+), 6 deletions(-) diff --git a/extensions/navigation/deck.navigation.js b/extensions/navigation/deck.navigation.js index b2c81099..69fe979a 100644 --- a/extensions/navigation/deck.navigation.js +++ b/extensions/navigation/deck.navigation.js @@ -40,7 +40,9 @@ This module adds clickable previous and next links to the deck. }); $d.bind('deck.init', function() { - var opts = $[deck]('getOptions'); + var opts = $[deck]('getOptions'), + nextSlide = $[deck]('getSlide', 1), + nextId = nextSlide ? nextSlide.attr('id') : undefined; // Setup prev/next link events $(opts.selectors.previousLink) @@ -57,16 +59,25 @@ This module adds clickable previous and next links to the deck. e.preventDefault(); }); - // Start on first slide, previous link is disabled + // Start on first slide, previous link is disabled, set next link href $(opts.selectors.previousLink).addClass(opts.classes.navDisabled); + $(opts.selectors.nextLink).attr('href', '#' + (nextId ? nextId : '')); }) - /* Update disabled states on deck change if last/first slide */ + /* Updates link hrefs, and disabled states if last/first slide */ .bind('deck.change', function(e, from, to) { var opts = $[deck]('getOptions'), - last = $[deck]('getSlides').length - 1; + last = $[deck]('getSlides').length - 1, + prevSlide = $[deck]('getSlide', to - 1), + nextSlide = $[deck]('getSlide', to + 1), + prevId = prevSlide ? prevSlide.attr('id') : undefined; + nextId = nextSlide ? nextSlide.attr('id') : undefined; - $(opts.selectors.previousLink).toggleClass(opts.classes.navDisabled, !to); - $(opts.selectors.nextLink).toggleClass(opts.classes.navDisabled, to == last); + $(opts.selectors.previousLink) + .toggleClass(opts.classes.navDisabled, !to) + .attr('href', '#' + (prevId ? prevId : '')); + $(opts.selectors.nextLink) + .toggleClass(opts.classes.navDisabled, to == last) + .attr('href', '#' + (nextId ? nextId : '')); }); })(jQuery, 'deck'); diff --git a/test/spec.navigation.js b/test/spec.navigation.js index 62321415..aef6f74b 100644 --- a/test/spec.navigation.js +++ b/test/spec.navigation.js @@ -34,4 +34,12 @@ describe('Deck JS Navigation Buttons', function() { $.deck('go', $.deck('getSlides').length - 1); expect($(defaults.selectors.nextLink)).toHaveClass(defaults.classes.navDisabled); }); + + it('should update the links hrefs with real fragment ids', function() { + expect($(defaults.selectors.previousLink)).toHaveAttr('href', '#'); + expect($(defaults.selectors.nextLink)).toHaveAttr('href', '#custom-id'); + $.deck('go', 2); + expect($(defaults.selectors.previousLink)).toHaveAttr('href', '#custom-id'); + expect($(defaults.selectors.nextLink)).toHaveAttr('href', '#slide-3'); + }); }); \ No newline at end of file From bb1f32bc2e40646dcc9c03f43bed7f1497468523 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 29 Aug 2011 23:16:13 +0800 Subject: [PATCH 025/169] Closes #17: Native event namespaces for each extension module --- core/deck.core.js | 2 +- extensions/goto/deck.goto.js | 8 ++++---- extensions/hash/deck.hash.js | 4 ++-- extensions/menu/deck.menu.js | 8 ++++---- extensions/navigation/deck.navigation.js | 10 +++++----- test/spec.goto.js | 2 +- test/spec.menu.js | 2 +- 7 files changed, 18 insertions(+), 18 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index 7ee27daf..a8c625f8 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -43,7 +43,7 @@ that use the API provided by core. $.deck.defaults.keys.myExtensionKeycode = 70; // 'h' $d.bind('deck.init', function() { $d.bind('keydown.deck', function(event) { - if (event.which == $.deck.getOptions().keys.myExtensionKeycode) { + if (event.which === $.deck.getOptions().keys.myExtensionKeycode) { // Rock out } }); diff --git a/extensions/goto/deck.goto.js b/extensions/goto/deck.goto.js index f9486288..2d71feb3 100644 --- a/extensions/goto/deck.goto.js +++ b/extensions/goto/deck.goto.js @@ -83,8 +83,8 @@ the deck container. $d.bind('deck.init', function() { // Bind key events - $d.bind('keydown.deck', function(e) { - if (e.which == $[deck]('getOptions').keys.goto) { + $d.unbind('keydown.deckgoto').bind('keydown.deckgoto', function(e) { + if (e.which === $[deck]('getOptions').keys.goto) { e.preventDefault(); $[deck]('toggleGoTo'); } @@ -92,8 +92,8 @@ the deck container. // Process form submittal, go to the slide entered $($[deck]('getOptions').selectors.gotoForm) - .unbind('submit.deck') - .bind('submit.deck', function(e) { + .unbind('submit.deckgoto') + .bind('submit.deckgoto', function(e) { var $field = ($($[deck]('getOptions').selectors.gotoInput)), i = parseInt($field.val(), 10); diff --git a/extensions/hash/deck.hash.js b/extensions/hash/deck.hash.js index 690a56d6..8b2ca456 100644 --- a/extensions/hash/deck.hash.js +++ b/extensions/hash/deck.hash.js @@ -83,7 +83,7 @@ the hashPrefix option. if (!Modernizr.hashchange) { /* Set up internal links using click for the poor browsers without a hashchange event. */ - $internals.bind('click.deck', function(e) { + $internals.unbind('click.deckhash').bind('click.deckhash', function(e) { goByHash($(this).attr('href')); }); } @@ -99,7 +99,7 @@ the hashPrefix option. }); /* Deals with internal links in modern browsers */ - $window.bind('hashchange.deck', function(e) { + $window.bind('hashchange.deckhash', function(e) { if (e.originalEvent && e.originalEvent.newURL) { goByHash(e.originalEvent.newURL); } diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index a9087f6a..ddacfb5b 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -80,17 +80,17 @@ on the deck container. currentSlide; // Bind key events - $d.bind('keydown.deck', function(e) { - if (e.which == opts.keys.menu) { + $d.unbind('keydown.deckmenu').bind('keydown.deckmenu', function(e) { + if (e.which === opts.keys.menu) { $[deck]('toggleMenu'); } }); // Double tap to toggle slide menu for touch devices - $[deck]('getContainer').bind('touchstart.deck', function(e) { + $[deck]('getContainer').unbind('touchstart.deckmenu').bind('touchstart.deckmenu', function(e) { currentSlide = $[deck]('getSlide'); }) - .bind('touchend.deck', function(e) { + .unbind('touchend.deckmenu').bind('touchend.deckmenu', function(e) { var now = Date.now(); // Ignore this touch event if it caused a nav change (swipe) diff --git a/extensions/navigation/deck.navigation.js b/extensions/navigation/deck.navigation.js index 69fe979a..b4f95b8d 100644 --- a/extensions/navigation/deck.navigation.js +++ b/extensions/navigation/deck.navigation.js @@ -46,15 +46,15 @@ This module adds clickable previous and next links to the deck. // Setup prev/next link events $(opts.selectors.previousLink) - .unbind('click.deck') - .bind('click.deck', function(e) { + .unbind('click.decknavigation') + .bind('click.decknavigation', function(e) { $[deck]('prev'); e.preventDefault(); }); $(opts.selectors.nextLink) - .unbind('click.deck') - .bind('click.deck', function(e) { + .unbind('click.decknavigation') + .bind('click.decknavigation', function(e) { $[deck]('next'); e.preventDefault(); }); @@ -76,7 +76,7 @@ This module adds clickable previous and next links to the deck. .toggleClass(opts.classes.navDisabled, !to) .attr('href', '#' + (prevId ? prevId : '')); $(opts.selectors.nextLink) - .toggleClass(opts.classes.navDisabled, to == last) + .toggleClass(opts.classes.navDisabled, to === last) .attr('href', '#' + (nextId ? nextId : '')); }); })(jQuery, 'deck'); diff --git a/test/spec.goto.js b/test/spec.goto.js index 48358e71..a65c9273 100644 --- a/test/spec.goto.js +++ b/test/spec.goto.js @@ -93,7 +93,7 @@ describe('Deck JS Quick Go-To', function() { var e; beforeEach(function() { - e = jQuery.Event('keydown.deck'); + e = jQuery.Event('keydown.deckgoto'); }); it('should toggle the go-to helper if the specified key is pressed', function() { diff --git a/test/spec.menu.js b/test/spec.menu.js index 6a454d39..79e38485 100644 --- a/test/spec.menu.js +++ b/test/spec.menu.js @@ -42,7 +42,7 @@ describe('Deck JS Menu', function() { var e; beforeEach(function() { - e = jQuery.Event('keydown.deck'); + e = jQuery.Event('keydown.deckmenu'); }); it('should toggle the menu if the specified key is pressed', function() { From 52c1f919f39c5a100897b66ccf28e7b134b56e2d Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 30 Aug 2011 09:47:39 +0800 Subject: [PATCH 026/169] Ensure container scroll offsets initialize at 0 for #19 --- core/deck.core.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/deck.core.js b/core/deck.core.js index a8c625f8..01448eb1 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -197,7 +197,8 @@ that use the API provided by core. startTouch = undefined; } }); - }); + }) + .scrollLeft(0).scrollTop(0); /* Kick iframe videos, which dont like to redraw w/ transforms. From e7c9ed4d46ac35904855c36bfdb5cc9e541516ca Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 30 Aug 2011 12:15:28 +0800 Subject: [PATCH 027/169] #10: Let keys accept arrays of keys --- core/deck.core.js | 16 +++++++--------- extensions/goto/deck.goto.js | 4 +++- extensions/menu/deck.menu.js | 2 +- extensions/scale/deck.scale.js | 2 +- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index 01448eb1..af500732 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -157,15 +157,13 @@ that use the API provided by core. /* Remove any previous bindings, and rebind key events */ $d.unbind('keydown.deck').bind('keydown.deck', function(e) { - switch (e.which) { - case options.keys.next: - methods.next(); - e.preventDefault(); - break; - case options.keys.previous: - methods.prev(); - e.preventDefault(); - break; + if (e.which === options.keys.next || $.inArray(e.which, options.keys.next) > -1) { + methods.next(); + e.preventDefault(); + } + else if (e.which === options.keys.previous || $.inArray(e.which, options.keys.previous) > -1) { + methods.prev(); + e.preventDefault(); } }); diff --git a/extensions/goto/deck.goto.js b/extensions/goto/deck.goto.js index 2d71feb3..20427d02 100644 --- a/extensions/goto/deck.goto.js +++ b/extensions/goto/deck.goto.js @@ -84,7 +84,9 @@ the deck container. $d.bind('deck.init', function() { // Bind key events $d.unbind('keydown.deckgoto').bind('keydown.deckgoto', function(e) { - if (e.which === $[deck]('getOptions').keys.goto) { + var key = $[deck]('getOptions').keys.goto; + + if (e.which === key ||$.inArray(e.which, key) > -1) { e.preventDefault(); $[deck]('toggleGoTo'); } diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index ddacfb5b..77541685 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -81,7 +81,7 @@ on the deck container. // Bind key events $d.unbind('keydown.deckmenu').bind('keydown.deckmenu', function(e) { - if (e.which === opts.keys.menu) { + if (e.which === opts.keys.menu || $.inArray(e.which, opts.keys.menu) > -1) { $[deck]('toggleMenu'); } }); diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index a974c36e..ffa7101f 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -142,7 +142,7 @@ works fine. // Bind key events $d.unbind('keydown.deckscale').bind('keydown.deckscale', function(e) { - if (e.which === opts.keys.scale) { + if (e.which === opts.keys.scale || $.inArray(e.which, opts.keys.scale) > -1) { $[deck]('toggleScale'); } }); From b2bec2779c60a62173d865596324113becb96906 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 30 Aug 2011 12:55:56 +0800 Subject: [PATCH 028/169] #10: Change next/prev defaults to an array of common controls --- core/deck.core.js | 6 ++++-- extensions/goto/deck.goto.js | 6 ++++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index af500732..55d28ba3 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -394,8 +394,10 @@ that use the API provided by core. }, keys: { - next: 39, // right arrow key - previous: 37 // left arrow key + // enter, space, page down, right arrow, down arrow, + next: [13, 32, 34, 39, 40], + // backspace, page up, left arrow, up arrow + previous: [8, 33, 37, 38] }, touch: { diff --git a/extensions/goto/deck.goto.js b/extensions/goto/deck.goto.js index 20427d02..702c0576 100644 --- a/extensions/goto/deck.goto.js +++ b/extensions/goto/deck.goto.js @@ -107,6 +107,12 @@ the deck container. e.preventDefault(); }); + + $($[deck]('getOptions').selectors.gotoInput) + .unbind('keydown.deckgoto') + .bind('keydown.deckgoto', function(e) { + e.stopPropagation(); + }); }); })(jQuery, 'deck'); From 8ecc5ed7c90ddb1075951b3461b5208512360477 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 30 Aug 2011 16:56:45 +0800 Subject: [PATCH 029/169] Document blue background chrome bug in README --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index d9f8fed2..dfbe8842 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,14 @@ Unit tests are written with [Jasmine](http://pivotal.github.com/jasmine/) and [j deck.js has been tested with jQuery 1.6+ and works in IE7+, Chrome, FF, Safari, and Opera. The more capable browsers receive greater enhancements, but a basic cutaway slideshow will work for all browsers listed above. Please don't give your presentations in IE6. +## Known Bug(s) + +There is an issue with certain builds of Chrome that result in a solid blue background and generally broken decks. This is a bug in Chrome ([Issue 91518](http://code.google.com/p/chromium/issues/detail?id=91518)) that stems from hardware acceleration of 3d transforms. Current workarounds: + +- Use a different browser. This problem doesn't exist in Safari, FF, Opera. +- Disable hardware compositing by setting `--disable-accelerated-compositing` in the Chrome loading options +- Replace instances of `translate3d` with `translate` in the CSS of your decks (though this will slow down performance on iOS devices and Safari.) + ## Printing Core includes stripped down black and white print styles for the standard slide template that is suitable for handouts. From 4e28b1e511ef0e8ecd84a1f5d0dfc2f883e4e980 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Wed, 31 Aug 2011 16:21:37 +0800 Subject: [PATCH 030/169] #15: Click selection of slides from menu --- extensions/menu/deck.menu.css | 3 ++- extensions/menu/deck.menu.js | 13 +++++++++++++ extensions/menu/deck.menu.scss | 3 ++- themes/style/neon.css | 9 +++++++++ themes/style/neon.scss | 11 +++++++++++ themes/style/swiss.css | 2 +- themes/style/swiss.scss | 2 +- themes/style/web-2.0.css | 2 +- themes/style/web-2.0.scss | 2 +- 9 files changed, 41 insertions(+), 6 deletions(-) diff --git a/extensions/menu/deck.menu.css b/extensions/menu/deck.menu.css index 2a4470b6..58c5c398 100644 --- a/extensions/menu/deck.menu.css +++ b/extensions/menu/deck.menu.css @@ -14,10 +14,11 @@ left: 0; top: 0; visibility: visible; + cursor: pointer; } .deck-menu iframe, .deck-menu img, .deck-menu video { max-width: 100%; } -.deck-menu .deck-current { +.deck-menu .deck-current, .no-touch .deck-menu .slide:hover { background: #ddf; } diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 77541685..73f3c17d 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -102,9 +102,22 @@ on the deck container. } touchEndTime = now; }); + + // Selecting slides from the menu + $.each($[deck]('getSlides'), function(i, $s) { + $s.unbind('click.deckmenu').bind('click.deckmenu', function(e) { + if (!$[deck]('getContainer').hasClass(opts.classes.menu)) return; + + $[deck]('go', i); + $[deck]('hideMenu'); + e.stopPropagation(); + e.preventDefault(); + }); + }); }) .bind('deck.change', function(e, from, to) { var container = $[deck]('getContainer'); + if (container.hasClass($[deck]('getOptions').classes.menu)) { container.scrollTop($[deck]('getSlide', to).offset().top); } diff --git a/extensions/menu/deck.menu.scss b/extensions/menu/deck.menu.scss index 6b63d263..bc6e6212 100755 --- a/extensions/menu/deck.menu.scss +++ b/extensions/menu/deck.menu.scss @@ -16,13 +16,14 @@ left:0; top:0; visibility:visible; + cursor:pointer; } iframe, img, video { max-width:100%; } - .deck-current { + .deck-current, .no-touch & .slide:hover { background:#ddf; } } \ No newline at end of file diff --git a/themes/style/neon.css b/themes/style/neon.css index 002ca0ed..c652dea9 100644 --- a/themes/style/neon.css +++ b/themes/style/neon.css @@ -103,3 +103,12 @@ -moz-box-shadow: 0 0 20px #f0a, 0 0 5px #fff; box-shadow: 0 0 20px #f0a, 0 0 5px #fff; } +.no-touch .deck-container.deck-menu .slide:hover { + background: #444; +} +.no-touch.boxshadow .deck-container.deck-menu .slide:hover { + background: #000; + -webkit-box-shadow: 0 0 20px #f0a, 0 0 5px #fff; + -moz-box-shadow: 0 0 20px #f0a, 0 0 5px #fff; + box-shadow: 0 0 20px #f0a, 0 0 5px #fff; +} diff --git a/themes/style/neon.scss b/themes/style/neon.scss index 109d4c64..5a35b751 100644 --- a/themes/style/neon.scss +++ b/themes/style/neon.scss @@ -124,5 +124,16 @@ box-shadow:0 0 20px #f0a, 0 0 5px #fff; } } + + .no-touch & .slide:hover { + background:#444; + } + + .no-touch.boxshadow & .slide:hover { + background:#000; + -webkit-box-shadow:0 0 20px #f0a, 0 0 5px #fff; + -moz-box-shadow:0 0 20px #f0a, 0 0 5px #fff; + box-shadow:0 0 20px #f0a, 0 0 5px #fff; + } } } diff --git a/themes/style/swiss.css b/themes/style/swiss.css index 0ae8d61e..54392974 100644 --- a/themes/style/swiss.css +++ b/themes/style/swiss.css @@ -70,6 +70,6 @@ .deck-container.deck-menu .slide { background: #eee; } -.deck-container.deck-menu .deck-current { +.deck-container.deck-menu .deck-current, .no-touch .deck-container.deck-menu .slide:hover { background: #ddf; } diff --git a/themes/style/swiss.scss b/themes/style/swiss.scss index 10ccc510..f3ecffca 100644 --- a/themes/style/swiss.scss +++ b/themes/style/swiss.scss @@ -84,7 +84,7 @@ background:#eee; } - .deck-current { + .deck-current, .no-touch & .slide:hover { background:#ddf; } } diff --git a/themes/style/web-2.0.css b/themes/style/web-2.0.css index 1afecae4..a5da81a2 100644 --- a/themes/style/web-2.0.css +++ b/themes/style/web-2.0.css @@ -170,7 +170,7 @@ .rgba .deck-container.deck-menu .slide { background: rgba(0, 0, 0, 0.1); } -.deck-container.deck-menu .slide.deck-current, .rgba .deck-container.deck-menu .slide.deck-current { +.deck-container.deck-menu .slide.deck-current, .rgba .deck-container.deck-menu .slide.deck-current, .no-touch .deck-container.deck-menu .slide:hover { background: #fff; } .deck-container .goto-form { diff --git a/themes/style/web-2.0.scss b/themes/style/web-2.0.scss index a847c98c..de417f16 100644 --- a/themes/style/web-2.0.scss +++ b/themes/style/web-2.0.scss @@ -192,7 +192,7 @@ background:rgba(0,0,0,.1); } - &.deck-current, .rgba &.deck-current { + &.deck-current, .rgba &.deck-current, .no-touch &:hover { background:#fff; } } From 1c410677173df8d8f1674d1b9ae5155265303001 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Wed, 31 Aug 2011 16:44:40 +0800 Subject: [PATCH 031/169] Preserve menu margins for scrolling while in scale mode --- extensions/scale/deck.scale.css | 8 ++++++++ extensions/scale/deck.scale.scss | 9 +++++++++ 2 files changed, 17 insertions(+) diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index 7695988d..ce1d088f 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -6,3 +6,11 @@ -ms-transform-origin: 50% 0; transform-origin: 50% 0; } +.csstransforms .deck-container.deck-scale.deck-menu { + width: 70%; + -webkit-transform: none !important; + -moz-transform: none !important; + -o-transform: none !important; + -ms-transform: none !important; + transform: none !important; +} diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index 94d8ccb6..4b39f11e 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -5,4 +5,13 @@ -o-transform-origin: 50% 0; -ms-transform-origin: 50% 0; transform-origin: 50% 0; + + &.deck-menu { + width:70%; + -webkit-transform:none !important; + -moz-transform:none !important; + -o-transform:none !important; + -ms-transform:none !important; + transform:none !important; + } } \ No newline at end of file From 0c6f85fff7b551830f201eaba70fcf4349724578 Mon Sep 17 00:00:00 2001 From: Daniel Knittl-Frank Date: Wed, 31 Aug 2011 15:03:16 +0200 Subject: [PATCH 032/169] Prevent default in menu extension key code Signed-off-by: Daniel Knittl-Frank --- extensions/menu/deck.menu.js | 1 + 1 file changed, 1 insertion(+) diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 73f3c17d..26b9f697 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -83,6 +83,7 @@ on the deck container. $d.unbind('keydown.deckmenu').bind('keydown.deckmenu', function(e) { if (e.which === opts.keys.menu || $.inArray(e.which, opts.keys.menu) > -1) { $[deck]('toggleMenu'); + e.preventDefault(); } }); From 58c274621dc1d7c4e869dd70993c4e6a69d52ecd Mon Sep 17 00:00:00 2001 From: Daniel Knittl-Frank Date: Thu, 1 Sep 2011 10:01:30 +0200 Subject: [PATCH 033/169] Prevent default event handling in scale extension --- extensions/scale/deck.scale.js | 1 + 1 file changed, 1 insertion(+) diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index ffa7101f..b0db9c35 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -144,6 +144,7 @@ works fine. $d.unbind('keydown.deckscale').bind('keydown.deckscale', function(e) { if (e.which === opts.keys.scale || $.inArray(e.which, opts.keys.scale) > -1) { $[deck]('toggleScale'); + e.preventDefault(); } }); From bb4870a5e4f98f10e63413561ed8b69ffa9179c2 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 1 Sep 2011 21:12:18 +0800 Subject: [PATCH 034/169] #20: Short circuit transitions on init with a display:none loading class --- core/deck.core.css | 3 +++ core/deck.core.js | 15 +++++++++++++++ core/deck.core.scss | 4 ++++ 3 files changed, 22 insertions(+) diff --git a/core/deck.core.css b/core/deck.core.css index 1c268cb6..29ab0d04 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -248,6 +248,9 @@ html { padding: .25em 0; vertical-align: middle; } +.deck-container.deck-loading { + display: none; +} .slide { width: auto; diff --git a/core/deck.core.js b/core/deck.core.js index 55d28ba3..b13a3904 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -143,6 +143,9 @@ that use the API provided by core. $c = $[deck]('getContainer'); tolerance = options.touch.swipeTolerance; + // Hide the deck while states are being applied to kill transitions + $c.addClass(options.classes.loading); + // Fill slides array depending on parameter type if ($.isArray(elements)) { $.each(elements, function(i, e) { @@ -215,6 +218,9 @@ that use the API provided by core. }); updateStates(); + + // Show deck again now that slides are in place + $c.removeClass(options.classes.loading); $d.trigger(events.initialize); }, @@ -350,6 +356,14 @@ that use the API provided by core. options.classes.current This class is added to the current slide. + options.classes.loading + This class is applied to the deck container during loading phases and is + primarily used as a way to short circuit transitions between states + where such transitions are distracting or unwanted. For example, this + class is applied during deck initialization and then removed to prevent + all the slides from appearing stacked and transitioning into place + on load. + options.classes.next This class is added to the slide immediately following the 'current' slide. @@ -384,6 +398,7 @@ that use the API provided by core. before: 'deck-before', childCurrent: 'deck-child-current', current: 'deck-current', + loading: 'deck-loading', next: 'deck-next', onPrefix: 'on-slide-', previous: 'deck-previous' diff --git a/core/deck.core.scss b/core/deck.core.scss index 8dbcf0d0..ed82964e 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -306,6 +306,10 @@ html { padding:.25em 0; vertical-align:middle; } + + &.deck-loading { + display:none; + } } .slide { From 5d82bd483157ffc68bd7b45c8d9bad964afc4361 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 9 Sep 2011 10:17:58 +0800 Subject: [PATCH 035/169] Add Extensions section to README --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index dfbe8842..d73e637a 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,13 @@ A JavaScript library for building modern HTML presentations. deck.js is flexible Check out the [documentation page](http://imakewebthings.github.com/deck.js/docs) for more information on the methods, events, and options available in core and all the included extensions. A sample standard slide deck is included in the package under the `introduction` folder. You can also [view that sample deck](http://imakewebthings.github.com/deck.js/introduction) online to play with the available style and transition themes. +## More Extensions + +Here are some useful extensions others have written for deck.js. If you have an extension, please send me a link and I'll add it to this list. + +- [deck.js-codemirror](https://github.com/iros/deck.js-codemirror) by [iros](https://github.com/iros): Integrates [codemirror](http://codemirror.net/) into deck.js, giving you editable, executable, syntax highlighted code snippets right inside your slides. +- [deck.remote.js](https://github.com/seppo0010/deck.remote.js) by [seppo0010](https://github.com/seppo0010): Uses node.js to give speakers a remote view to control slides, keep notes, and preview previous+next slides. + ## Tests & Support Unit tests are written with [Jasmine](http://pivotal.github.com/jasmine/) and [jasmine-jquery](https://github.com/velesin/jasmine-jquery). You can [run them here](http://imakewebthings.github.com/deck.js/test). From cfcc3dea767cdcab82f2e1284df6711a1bdb75d2 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 13 Sep 2011 08:40:31 +0800 Subject: [PATCH 036/169] #Fixes #25: Reset pointer events to auto on nested slide parent --- themes/transition/fade.css | 1 + themes/transition/fade.scss | 1 + 2 files changed, 2 insertions(+) diff --git a/themes/transition/fade.css b/themes/transition/fade.css index ac4e1c70..f3793f31 100644 --- a/themes/transition/fade.css +++ b/themes/transition/fade.css @@ -37,6 +37,7 @@ .csstransitions.csstransforms .deck-container:not(.deck-menu) > .deck-child-current { opacity: 1; visibility: visible; + pointer-events: auto; } .csstransitions.csstransforms .deck-container:not(.deck-menu) > .deck-child-current .deck-next, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .deck-child-current .deck-after { visibility: hidden; diff --git a/themes/transition/fade.scss b/themes/transition/fade.scss index 5f0dc493..c5af7e7f 100644 --- a/themes/transition/fade.scss +++ b/themes/transition/fade.scss @@ -60,6 +60,7 @@ > .deck-child-current { opacity:1; visibility:visible; + pointer-events:auto; .deck-next, .deck-after { visibility:hidden; From 57c92b2af3c98e3f8042d3f07be21757e5429438 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Wed, 14 Sep 2011 23:38:52 +0800 Subject: [PATCH 037/169] Fixes #28: Stop propagation of key events from editable elements within slides --- core/deck.core.js | 10 ++++++++-- test/fixtures/standard.html | 2 +- test/spec.core.js | 7 +++++++ 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index b13a3904..1000a808 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -135,7 +135,10 @@ that use the API provided by core. init: function(elements, opts) { var startTouch, $c, - tolerance; + tolerance, + esp = function(e) { + e.stopPropagation(); + }; options = $.extend(true, {}, $[deck].defaults, opts); slides = []; @@ -199,7 +202,10 @@ that use the API provided by core. } }); }) - .scrollLeft(0).scrollTop(0); + .scrollLeft(0).scrollTop(0) + /* Stop propagation of key events within editable elements of slides */ + .undelegate('input, textarea, select, button, meter, progress, [contentEditable]', 'keydown', esp) + .delegate('input, textarea, select, button, meter, progress, [contentEditable]', 'keydown', esp); /* Kick iframe videos, which dont like to redraw w/ transforms. diff --git a/test/fixtures/standard.html b/test/fixtures/standard.html index d859587f..1adc57f9 100644 --- a/test/fixtures/standard.html +++ b/test/fixtures/standard.html @@ -29,7 +29,7 @@
-
+
diff --git a/test/spec.core.js b/test/spec.core.js index 15613ea7..f89e66c7 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -224,6 +224,13 @@ describe('Deck JS', function() { $d.trigger(e); expect($.deck('getSlide')).toHaveClass('alt-slide1'); }); + + it('should not trigger events that originate within editable elements', function() { + e = jQuery.Event('keydown'); + e.which = 87; + $('.alt-slide1 input').trigger(e); + expect($.deck('getSlide')).toHaveClass('alt-slide1'); + }); }); }); From f5afdbfbf76389c2c2e1a8396f2c6249b1ec508d Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 19 Sep 2011 11:44:05 +0800 Subject: [PATCH 038/169] Update Related Projects --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d73e637a..c9c4dc34 100644 --- a/README.md +++ b/README.md @@ -11,12 +11,14 @@ A JavaScript library for building modern HTML presentations. deck.js is flexible Check out the [documentation page](http://imakewebthings.github.com/deck.js/docs) for more information on the methods, events, and options available in core and all the included extensions. A sample standard slide deck is included in the package under the `introduction` folder. You can also [view that sample deck](http://imakewebthings.github.com/deck.js/introduction) online to play with the available style and transition themes. -## More Extensions +## More Extensions and Related Projects -Here are some useful extensions others have written for deck.js. If you have an extension, please send me a link and I'll add it to this list. +If you have an extension, theme, or project related to or using deck.js, please send me a link and I'll add it to this list. - [deck.js-codemirror](https://github.com/iros/deck.js-codemirror) by [iros](https://github.com/iros): Integrates [codemirror](http://codemirror.net/) into deck.js, giving you editable, executable, syntax highlighted code snippets right inside your slides. - [deck.remote.js](https://github.com/seppo0010/deck.remote.js) by [seppo0010](https://github.com/seppo0010): Uses node.js to give speakers a remote view to control slides, keep notes, and preview previous+next slides. +- [deckjs-remote](https://github.com/chrisjaure/deckjs-remote) by [chrisjaure](https://github.com/chrisjaure): Control your deck remotely through a node.js service. Presenters can use the service publicly available at http://deckjs-remote.no.de or host it themselves. +- [deckem](https://github.com/DamonOehlman/deckem) by [DamonOehlman](https://github.com/DamonOehlman): [Jade](http://jade-lang.com/) templating for deck.js. ## Tests & Support From 42b4d44190785b943ce9df7cb4de5ddb42d6f0ae Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 19 Sep 2011 11:45:34 +0800 Subject: [PATCH 039/169] Reword --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c9c4dc34..4ab531bc 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ If you have an extension, theme, or project related to or using deck.js, please - [deck.js-codemirror](https://github.com/iros/deck.js-codemirror) by [iros](https://github.com/iros): Integrates [codemirror](http://codemirror.net/) into deck.js, giving you editable, executable, syntax highlighted code snippets right inside your slides. - [deck.remote.js](https://github.com/seppo0010/deck.remote.js) by [seppo0010](https://github.com/seppo0010): Uses node.js to give speakers a remote view to control slides, keep notes, and preview previous+next slides. -- [deckjs-remote](https://github.com/chrisjaure/deckjs-remote) by [chrisjaure](https://github.com/chrisjaure): Control your deck remotely through a node.js service. Presenters can use the service publicly available at http://deckjs-remote.no.de or host it themselves. +- [deckjs-remote](https://github.com/chrisjaure/deckjs-remote) by [chrisjaure](https://github.com/chrisjaure): Control your deck remotely through a node.js service. Presenters can use the [publicly available service](http://deckjs-remote.no.de) or host it themselves. - [deckem](https://github.com/DamonOehlman/deckem) by [DamonOehlman](https://github.com/DamonOehlman): [Jade](http://jade-lang.com/) templating for deck.js. ## Tests & Support From 8c1af3e28183e87cc4147b7dcdee726f15e73a45 Mon Sep 17 00:00:00 2001 From: Doug Ireton Date: Wed, 21 Sep 2011 21:14:34 -0700 Subject: [PATCH 040/169] Add local jQuery lib for offline use --- introduction/index.html | 6 ++++-- jquery-1.6.4.min.js | 4 ++++ 2 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 jquery-1.6.4.min.js diff --git a/introduction/index.html b/introduction/index.html index f6382958..6519a611 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -200,8 +200,10 @@

Digging Deeper

# - - + + + + diff --git a/jquery-1.6.4.min.js b/jquery-1.6.4.min.js new file mode 100644 index 00000000..628ed9b3 --- /dev/null +++ b/jquery-1.6.4.min.js @@ -0,0 +1,4 @@ +/*! jQuery v1.6.4 http://jquery.com/ | http://jquery.org/license */ +(function(a,b){function cu(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cr(a){if(!cg[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){ch||(ch=c.createElement("iframe"),ch.frameBorder=ch.width=ch.height=0),b.appendChild(ch);if(!ci||!ch.createElement)ci=(ch.contentWindow||ch.contentDocument).document,ci.write((c.compatMode==="CSS1Compat"?"":"")+""),ci.close();d=ci.createElement(a),ci.body.appendChild(d),e=f.css(d,"display"),b.removeChild(ch)}cg[a]=e}return cg[a]}function cq(a,b){var c={};f.each(cm.concat.apply([],cm.slice(0,b)),function(){c[this]=a});return c}function cp(){cn=b}function co(){setTimeout(cp,0);return cn=f.now()}function cf(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ce(){try{return new a.XMLHttpRequest}catch(b){}}function b$(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;g0){c!=="border"&&f.each(e,function(){c||(d-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?d+=parseFloat(f.css(a,c+this))||0:d-=parseFloat(f.css(a,"border"+this+"Width"))||0});return d+"px"}d=bv(a,b,b);if(d<0||d==null)d=a.style[b]||0;d=parseFloat(d)||0,c&&f.each(e,function(){d+=parseFloat(f.css(a,"padding"+this))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+this+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+this))||0)});return d+"px"}function bl(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(bd,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bk(a){f.nodeName(a,"input")?bj(a):"getElementsByTagName"in a&&f.grep(a.getElementsByTagName("input"),bj)}function bj(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bi(a){return"getElementsByTagName"in a?a.getElementsByTagName("*"):"querySelectorAll"in a?a.querySelectorAll("*"):[]}function bh(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bg(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c=f.expando,d=f.data(a),e=f.data(b,d);if(d=d[c]){var g=d.events;e=e[c]=f.extend({},d);if(g){delete e.handle,e.events={};for(var h in g)for(var i=0,j=g[h].length;i=0===c})}function U(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function M(a,b){return(a&&a!=="*"?a+".":"")+b.replace(y,"`").replace(z,"&")}function L(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 J(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 D(){return!0}function C(){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").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 K(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(K,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=/-([a-z]|[0-9])/ig,x=/^-ms-/,y=function(a,b){return(b+"").toUpperCase()},z=d.userAgent,A,B,C,D=Object.prototype.toString,E=Object.prototype.hasOwnProperty,F=Array.prototype.push,G=Array.prototype.slice,H=String.prototype.trim,I=Array.prototype.indexOf,J={};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.4",length:0,size:function(){return this.length},toArray:function(){return G.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)?F.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(),B.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(G.apply(this,arguments),"slice",G.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:F,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;B.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!B){B=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",C,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",C),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&K()}}},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):J[D.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!E.call(a,"constructor")&&!E.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||E.call(a,d)},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(c){var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(x,"ms-").replace(w,y)},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{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=a.getElementsByTagName("input")[0],k={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:i.value==="on",optSelected:h.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,k.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,k.optDisabled=!h.disabled;try{delete a.test}catch(v){k.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function(){k.noCloneEvent=!1}),a.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),k.radioValue=i.value==="t",i.setAttribute("checked","checked"),a.appendChild(i),l=c.createDocumentFragment(),l.appendChild(a.firstChild),k.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",m=c.getElementsByTagName("body")[0],o=c.createElement(m?"div":"body"),p={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"},m&&f.extend(p,{position:"absolute",left:"-1000px",top:"-1000px"});for(t in p)o.style[t]=p[t];o.appendChild(a),n=m||b,n.insertBefore(o,n.firstChild),k.appendChecked=i.checked,k.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,k.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="
",k.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="
t
",q=a.getElementsByTagName("td"),u=q[0].offsetHeight===0,q[0].style.display="",q[1].style.display="none",k.reliableHiddenOffsets=u&&q[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",a.appendChild(j),k.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0),o.innerHTML="",n.removeChild(o);if(a.attachEvent)for(t in{submit:1,change:1,focusin:1})s="on"+t,u=s in a,u||(a.setAttribute(s,"return;"),u=typeof a[s]=="function"),k[t+"Bubbles"]=u;o=l=g=h=m=j=a=i=null;return k}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([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,h,i=f.expando,j=typeof c=="string",k=a.nodeType,l=k?f.cache:a,m=k?a[f.expando]:a[f.expando]&&f.expando;if((!m||e&&m&&l[m]&&!l[m][i])&&j&&d===b)return;m||(k?a[f.expando]=m=++f.uuid:m=f.expando),l[m]||(l[m]={},k||(l[m].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?l[m][i]=f.extend(l[m][i],c):l[m]=f.extend(l[m],c);g=l[m],e&&(g[i]||(g[i]={}),g=g[i]),d!==b&&(g[f.camelCase(c)]=d);if(c==="events"&&!g[c])return g[i]&&g[i].events;j?(h=g[c],h==null&&(h=g[f.camelCase(c)])):h=g;return h}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e=f.expando,g=a.nodeType,h=g?f.cache:a,i=g?a[f.expando]:f.expando;if(!h[i])return;if(b){d=c?h[i][e]:h[i];if(d){d[b]||(b=f.camelCase(b)),delete d[b];if(!l(d))return}}if(c){delete h[i][e];if(!l(h[i]))return}var j=h[i][e];f.support.deleteExpando||!h.setInterval?delete h[i]:h[i]=null,j?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=j):g&&(f.support.deleteExpando?delete a[f.expando]:a.removeAttribute?a.removeAttribute(f.expando):a[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;d=e.value;return typeof d=="string"?d.replace(p,""):d==null?"":d}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);j&&(c=f.attrFix[c]||c,i=f.attrHooks[c],i||(t.test(c)?i=v:u&&(i=u)));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&&(h=i.get(a,c))!==null)return h;h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){var c;a.nodeType===1&&(b=f.attrFix[b]||b,f.attr(a,b,""),a.removeAttribute(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}}},value:{get:function(a,b){if(u&&f.nodeName(a,"button"))return u.get(a,b);return b in a?a.value:null},set:function(a,b,c){if(u&&f.nodeName(a,"button"))return u.set(a,b,c);a.value=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);i&&(c=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))!==null?g:a[c]},propHooks:{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}}}}),f.attrHooks.tabIndex=f.propHooks.tabIndex,v={get:function(a,c){var d;return f.prop(a,c)===!0||(d=a.getAttributeNode(c))&&d.nodeValue!==!1?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]=!0),a.setAttribute(c,c.toLowerCase()));return c}},f.support.getSetAttribute||(u=f.valHooks.button={get:function(a,c){var d;d=a.getAttributeNode(c);return d&&d.nodeValue!==""?d.nodeValue:b},set:function(a,b,d){var e=a.getAttributeNode(d);e||(e=c.createAttribute(d),a.setAttributeNode(e));return e.nodeValue=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);return null}})),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 w=/\.(.*)$/,x=/^(?:textarea|input|select)$/i,y=/\./g,z=/ /g,A=/[^\w\s.|`]/g,B=function(a){return a.replace(A,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=C;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=C);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(),B).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!=null?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},I=function(c){var d=c.target,e,g;if(!!x.test(d.nodeName)&&!d.readOnly){e=f._data(d,"_change_data"),g=H(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:I,beforedeactivate:I,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&I.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")&&I.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",H(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in G)f.event.add(this,c+".specialChange",G[c]);return x.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return x.test(this.nodeName)}},G=f.event.special.change.filters,G.focus=G.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=S.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)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));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(U(c[0])||U(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=R.call(arguments);N.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!T[a]?f.unique(e):e,(this.length>1||P.test(d))&&O.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 W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/",""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]};be.optgroup=be.option,be.tbody=be.tfoot=be.colgroup=be.caption=be.thead,be.th=be.td,f.support.htmlSerialize||(be._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(W,""):null;if(typeof a=="string"&&!ba.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!be[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$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)){bh(a,d),e=bi(a),g=bi(d);for(h=0;e[h];++h)g[h]&&bh(e[h],g[h])}if(b){bg(a,d);if(c){e=bi(a),g=bi(d);for(h=0;e[h];++h)bg(e[h],g[h])}}e=g=null;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(!_.test(k))k=b.createTextNode(k);else{k=k.replace(Y,"<$1>");var l=(Z.exec(k)||["",""])[1].toLowerCase(),m=be[l]||be._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=$.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&&X.test(k)&&o.insertBefore(b.createTextNode(X.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 bn.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,e=f.isNaN(b)?"":"alpha(opacity="+b*100+")",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bm,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bm.test(g)?g.replace(bm,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=bv(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bw=function(a,c){var d,e,g;c=c.replace(bo,"-$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&&(bx=function(a,b){var c,d=a.currentStyle&&a.currentStyle[b],e=a.runtimeStyle&&a.runtimeStyle[b],f=a.style;!bp.test(d)&&bq.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}),bv=bw||bx,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 bz=/%20/g,bA=/\[\]$/,bB=/\r?\n/g,bC=/#.*$/,bD=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bE=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bF=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bG=/^(?:GET|HEAD)$/,bH=/^\/\//,bI=/\?/,bJ=/)<[^<]*)*<\/script>/gi,bK=/^(?:select|textarea)/i,bL=/\s+/,bM=/([?&])_=[^&]*/,bN=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bO=f.fn.load,bP={},bQ={},bR,bS,bT=["*/"]+["*"];try{bR=e.href}catch(bU){bR=c.createElement("a"),bR.href="",bR=bR.href}bS=bN.exec(bR.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bO)return bO.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(bJ,"")).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||bK.test(this.nodeName)||bE.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(bB,"\r\n")}}):{name:b.name,value:c.replace(bB,"\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?bX(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),bX(a,b);return a},ajaxSettings:{url:bR,isLocal:bF.test(bS[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","*":bT},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},flatOptions:{context:!0,url:!0}},ajaxPrefilter:bV(bP),ajaxTransport:bV(bQ),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>0?4:0;var o,r,u,w=c,x=l?bZ(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=b$(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.resolveWith(e,[v,w]),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=bD.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(bC,"").replace(bH,bS[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bL),d.crossDomain==null&&(r=bN.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bS[1]&&r[2]==bS[2]&&(r[3]||(r[1]==="http:"?80:443))==(bS[3]||(bS[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),bW(bP,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bG.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bI.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bM,"$1_="+x);d.url=y+(y===d.url?(bI.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]!=="*"?", "+bT+"; 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=bW(bQ,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){s<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)bY(g,a[g],c,e);return d.join("&").replace(bz,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var b_=f.now(),ca=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+b_++}}),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&&(ca.test(b.url)||e&&ca.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(ca,l),b.url===j&&(e&&(k=k.replace(ca,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 cb=a.ActiveXObject?function(){for(var a in cd)cd[a](0,1)}:!1,cc=0,cd;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ce()||cf()}:ce,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,cb&&delete cd[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=++cc,cb&&(cd||(cd={},f(a).unload(cb)),cd[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cg={},ch,ci,cj=/^(?:toggle|show|hide)$/,ck=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cl,cm=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cn;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cq("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=ct.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&&!ct.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=cu(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=cu(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(){var a=this[0];return a&&a.style?parseFloat(f.css(a,d,"padding")):null},f.fn["outer"+c]=function(a){var b=this[0];return b&&b.style?parseFloat(f.css(b,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],h=e.document.body;return e.document.compatMode==="CSS1Compat"&&g||h&&h["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 i=f.css(e,d),j=parseFloat(i);return f.isNaN(j)?i:j}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f})(window); \ No newline at end of file From dda6b9ec7d385fe928a1ce512f06e0ea09963ac9 Mon Sep 17 00:00:00 2001 From: Doug Ireton Date: Wed, 21 Sep 2011 21:29:18 -0700 Subject: [PATCH 041/169] Make HTML markup more semantic. Change slide
s to
s. --- introduction/index.html | 48 ++++++++++++++++++++--------------------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/introduction/index.html b/introduction/index.html index f6382958..d65031ce 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -53,11 +53,11 @@

Themes

-
+

Getting Started with deck.js

-
+ -
+

How to Make a Deck

  1. @@ -73,12 +73,12 @@

    Include Extensions

    Add extra functionality to your deck, or leave it stripped down.

-
+ -
+

The Markup

Slides are just HTML elements with a class of slide.

-
<div class="slide">
+	
<section class="slide">
    <h2>How to Make a Deck</h2>
    <ol>
       <li>
@@ -91,19 +91,19 @@ 

The Markup

</li> … </ol> -</div>
-
+</section> + -
+

Style Themes

Customizes the colors, typography, and layout of slide content.

<link rel="stylesheet" href="/path/to/css/style-theme.css">

Transition Themes

Defines transitions between slides using CSS3 transitions. Less capable browsers fall back to cutaways. But you aren’t using those browsers to give your presentations, are you…

<link rel="stylesheet" href="/path/to/css/transition-theme.css">
-
+ -
+

Extensions

Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

@@ -130,12 +130,12 @@

Extensions

Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

-
+ -
+

Nested Slides

That last slide had a few steps. To create substeps in slides, just nest them:

-
<div class="slide">
+	
<section class="slide">
   <h2>Extensions</h2>
   <p>Core gives you basic slide functionality...</p>		
   <ul>
@@ -147,16 +147,16 @@ 

Nested Slides

<li class="slide">...</li> <li class="slide">...</li> </ul> -</div>
-
+</section> + -
+

Other Elements: Images

Kitties
<img src="http://placekitten.com/600/375" alt="Kitties">
-
+ -
+

Other Elements: Blockquotes

Food is an important part of a balanced diet.

@@ -166,22 +166,22 @@

Other Elements: Blockquotes

<p>Food is an important part of a balanced diet.</p> <p><cite>Fran Lebowitz</cite></p> </blockquote> -
+ -
+

Other Elements: Video Embeds

Embed videos from your favorite online video service or with an HTML5 video element.

<iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
-
+ -
+

Digging Deeper

If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

-
+ From a2182964eef4f84e9e9a17d9282bb32fab74a27e Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 23 Sep 2011 01:28:26 +0800 Subject: [PATCH 042/169] Add more extensions to README list --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 4ab531bc..644bce8f 100644 --- a/README.md +++ b/README.md @@ -19,6 +19,8 @@ If you have an extension, theme, or project related to or using deck.js, please - [deck.remote.js](https://github.com/seppo0010/deck.remote.js) by [seppo0010](https://github.com/seppo0010): Uses node.js to give speakers a remote view to control slides, keep notes, and preview previous+next slides. - [deckjs-remote](https://github.com/chrisjaure/deckjs-remote) by [chrisjaure](https://github.com/chrisjaure): Control your deck remotely through a node.js service. Presenters can use the [publicly available service](http://deckjs-remote.no.de) or host it themselves. - [deckem](https://github.com/DamonOehlman/deckem) by [DamonOehlman](https://github.com/DamonOehlman): [Jade](http://jade-lang.com/) templating for deck.js. +- [markdown2deckjs](https://github.com/ulf/markdown2deckjs) by [ulf](https://github.com/ulf): Write your slides in Markdown and convert them into a full working deck. +- [deck.gotonumkey.js](https://github.com/KingHenne/deck.gotonumkey.js) by [KingHenne](https://github.com/KingHenne): A small extension that lets you jump to any slide by pressing the corresponding number key(s). ## Tests & Support From 7e6a7a0014ec714874fc292c389720fae401a91e Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 23 Sep 2011 01:30:20 +0800 Subject: [PATCH 043/169] Move wording in README for jQuery inclusion --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 644bce8f..0193355c 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,10 @@ A JavaScript library for building modern HTML presentations. deck.js is flexible enough to let advanced CSS and JavaScript authors craft highly customized decks, but also provides templates and themes for the HTML novice to build a standard slideshow. -## Dependencies +## Dependencies (included in this repository) - [jQuery](http://jquery.com) -- [Modernizr](http://modernizr.com) (included in this repository) +- [Modernizr](http://modernizr.com) ## Documentation From d5a096679250a389978aff5bf36a075c8b5bf9f0 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 23 Sep 2011 11:29:35 +0800 Subject: [PATCH 044/169] Set scroll values to 0 with hash navigation, Fixes #33 --- extensions/hash/deck.hash.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/extensions/hash/deck.hash.js b/extensions/hash/deck.hash.js index 8b2ca456..c2200ee7 100644 --- a/extensions/hash/deck.hash.js +++ b/extensions/hash/deck.hash.js @@ -35,6 +35,9 @@ the hashPrefix option. return false; } }); + + // If we don't set these to 0 the container scrolls due to hashchange + $[deck]('getContainer').scrollLeft(0).scrollTop(0); }; /* From ca15fd4008338a803228fbe4ae71a93763e498a7 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 23 Sep 2011 12:47:10 +0800 Subject: [PATCH 045/169] Change deck.core snippet to use section tag --- core/deck.core.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/deck.core.html b/core/deck.core.html index bc6f519b..03fd8d29 100644 --- a/core/deck.core.html +++ b/core/deck.core.html @@ -16,9 +16,9 @@ -
+
-
+ From 423608a0b89222fb1f7fbfb3bf9a5f6485eeb80c Mon Sep 17 00:00:00 2001 From: Pascal Rettig Date: Sun, 25 Sep 2011 22:15:43 -0400 Subject: [PATCH 046/169] Added exception for iframes without srcs --- core/deck.core.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index 1000a808..0e72ef2b 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -441,8 +441,11 @@ that use the API provided by core. newFrames = $[deck]('getSlide', to).find('iframe'); oldFrames.each(function() { - var $this = $(this); - $this.data('deck-src', $this.attr('src')).attr('src', ''); + var $this = $(this); + var curSrc = $this.attr('src'); + if(curSrc) { + $this.data('deck-src', curSrc).attr('src', ''); + } }); newFrames.each(function() { @@ -454,4 +457,4 @@ that use the API provided by core. } }); }); -})(jQuery, 'deck', document); \ No newline at end of file +})(jQuery, 'deck', document); From 4b7fe3358d32a8ba1b158295d0d2e724293db903 Mon Sep 17 00:00:00 2001 From: Pascal Rettig Date: Sun, 25 Sep 2011 22:15:56 -0400 Subject: [PATCH 047/169] Added tests --- test/fixtures/iframe_simple.html | 10 +++++++ test/fixtures/iframes.html | 32 +++++++++++++++++++++ test/spec.core.js | 49 +++++++++++++++++++++++++++++++- 3 files changed, 90 insertions(+), 1 deletion(-) create mode 100644 test/fixtures/iframe_simple.html create mode 100644 test/fixtures/iframes.html diff --git a/test/fixtures/iframe_simple.html b/test/fixtures/iframe_simple.html new file mode 100644 index 00000000..a64e9c0a --- /dev/null +++ b/test/fixtures/iframe_simple.html @@ -0,0 +1,10 @@ + + + + + Codestin Search App + + +Simple Iframe + + diff --git a/test/fixtures/iframes.html b/test/fixtures/iframes.html new file mode 100644 index 00000000..ccbd179e --- /dev/null +++ b/test/fixtures/iframes.html @@ -0,0 +1,32 @@ +
+
+ +
+
+ +
+ +
+ +
+ +
+ +
+ +
+ +
+ +

+ + / + +

+ +
+ + + +
+
diff --git a/test/spec.core.js b/test/spec.core.js index f89e66c7..a468fced 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -337,4 +337,51 @@ describe('Deck JS', function() { expect($('.slide4').not('.slide6')).not.toHaveClass(defaults.classes.next); }); }); -}); \ No newline at end of file + + describe('iframes', function() { + beforeEach(function() { + loadFixtures('iframes.html'); + if (Modernizr.history) { + history.replaceState({}, "", "#") + } + $.deck([ + '.slide1', + '.slide2', + '.slide3', + '.slide4', + '.slide5', + '.slide6', + '.slide7', + '.slide8', + '.slide9', + '.slide10', + ]); + + }); + + it('should support remove and return iframe srcs', function() { + $.deck('go', 4); + expect($.deck('getSlide').find('iframe').attr('src')).toEqual('iframe_simple.html'); + $.deck('next'); + expect($('.slide5').find('iframe').attr('src')).toEqual(''); + + $.deck('prev'); + expect($('.slide5').find('iframe').attr('src')).toEqual('iframe_simple.html'); + + }); + + + it('should support iframes without sources', function() { + $.deck('go', 5); + expect($.deck('getSlide')).toHaveClass('slide6'); + expect($.deck('getSlide').find('iframe').attr('src')).toBeUndefined(); + $.deck('next'); + expect($.deck('getSlide')).toHaveClass('slide7'); + }); + + + }); + + + +}); From 77a6da57271a18cefd40f2731f467c07eb5ad58d Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 26 Sep 2011 11:38:46 +0800 Subject: [PATCH 048/169] Test cleanup --- core/deck.core.js | 11 ++++++----- test/spec.core.js | 40 +++++++++++++++------------------------- 2 files changed, 21 insertions(+), 30 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index 0e72ef2b..f91d3c93 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -441,11 +441,12 @@ that use the API provided by core. newFrames = $[deck]('getSlide', to).find('iframe'); oldFrames.each(function() { - var $this = $(this); - var curSrc = $this.attr('src'); - if(curSrc) { - $this.data('deck-src', curSrc).attr('src', ''); - } + var $this = $(this), + curSrc = $this.attr('src'); + + if(curSrc) { + $this.data('deck-src', curSrc).attr('src', ''); + } }); newFrames.each(function() { diff --git a/test/spec.core.js b/test/spec.core.js index a468fced..03b31e33 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -359,29 +359,19 @@ describe('Deck JS', function() { }); - it('should support remove and return iframe srcs', function() { - $.deck('go', 4); - expect($.deck('getSlide').find('iframe').attr('src')).toEqual('iframe_simple.html'); - $.deck('next'); - expect($('.slide5').find('iframe').attr('src')).toEqual(''); - - $.deck('prev'); - expect($('.slide5').find('iframe').attr('src')).toEqual('iframe_simple.html'); - - }); - - - it('should support iframes without sources', function() { - $.deck('go', 5); - expect($.deck('getSlide')).toHaveClass('slide6'); - expect($.deck('getSlide').find('iframe').attr('src')).toBeUndefined(); - $.deck('next'); - expect($.deck('getSlide')).toHaveClass('slide7'); - }); - - - }); - - - + it('should remove/restore iframe sources when leaving/entering a slide', function() { + $.deck('go', 4); + expect($.deck('getSlide').find('iframe').attr('src')).toEqual('iframe_simple.html'); + $.deck('next'); + expect($('.slide5').find('iframe').attr('src')).toEqual(''); + $.deck('prev'); + expect($('.slide5').find('iframe').attr('src')).toEqual('iframe_simple.html'); + }); + + it('should not store blank iframe sources', function() { + $.deck('go', 6); + $.deck('next'); + expect($.deck('getSlide').find('iframe').data('src')).toBeUndefined(); + }); + }); }); From 0e4fd579af2340d488bf77db0fa194eab8c242b2 Mon Sep 17 00:00:00 2001 From: Caleb Troughton Date: Tue, 27 Sep 2011 09:47:45 +0800 Subject: [PATCH 049/169] Update related projects to point to wiki --- README.md | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 0193355c..103739e5 100644 --- a/README.md +++ b/README.md @@ -11,16 +11,9 @@ A JavaScript library for building modern HTML presentations. deck.js is flexible Check out the [documentation page](http://imakewebthings.github.com/deck.js/docs) for more information on the methods, events, and options available in core and all the included extensions. A sample standard slide deck is included in the package under the `introduction` folder. You can also [view that sample deck](http://imakewebthings.github.com/deck.js/introduction) online to play with the available style and transition themes. -## More Extensions and Related Projects +## Extensions, Themes, and Related Projects -If you have an extension, theme, or project related to or using deck.js, please send me a link and I'll add it to this list. - -- [deck.js-codemirror](https://github.com/iros/deck.js-codemirror) by [iros](https://github.com/iros): Integrates [codemirror](http://codemirror.net/) into deck.js, giving you editable, executable, syntax highlighted code snippets right inside your slides. -- [deck.remote.js](https://github.com/seppo0010/deck.remote.js) by [seppo0010](https://github.com/seppo0010): Uses node.js to give speakers a remote view to control slides, keep notes, and preview previous+next slides. -- [deckjs-remote](https://github.com/chrisjaure/deckjs-remote) by [chrisjaure](https://github.com/chrisjaure): Control your deck remotely through a node.js service. Presenters can use the [publicly available service](http://deckjs-remote.no.de) or host it themselves. -- [deckem](https://github.com/DamonOehlman/deckem) by [DamonOehlman](https://github.com/DamonOehlman): [Jade](http://jade-lang.com/) templating for deck.js. -- [markdown2deckjs](https://github.com/ulf/markdown2deckjs) by [ulf](https://github.com/ulf): Write your slides in Markdown and convert them into a full working deck. -- [deck.gotonumkey.js](https://github.com/KingHenne/deck.gotonumkey.js) by [KingHenne](https://github.com/KingHenne): A small extension that lets you jump to any slide by pressing the corresponding number key(s). +Take a look at [the wiki](https://github.com/imakewebthings/deck.js/wiki) for lists of extensions, themes, and other related goodies. If you have a publicly available project of your own, feel free to add to the list. ## Tests & Support From d20874bab5a86ebc95b1f250a2ba5d59aefe28a2 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 8 Oct 2011 13:01:02 +0800 Subject: [PATCH 050/169] Add id-specific container state class to hash module, closes #36 --- extensions/hash/deck.hash.js | 22 +++++++++++++++++----- test/spec.hash.js | 12 ++++++++++++ 2 files changed, 29 insertions(+), 5 deletions(-) diff --git a/extensions/hash/deck.hash.js b/extensions/hash/deck.hash.js index c2200ee7..8bc39ffd 100644 --- a/extensions/hash/deck.hash.js +++ b/extensions/hash/deck.hash.js @@ -12,7 +12,9 @@ to slides within decks, and updates the address bar with the hash as the user moves through the deck. A permalink anchor is also updated. Standard themes hide this link in browsers that support the History API, and show it for those that do not. Slides that do not have an id are assigned one according to -the hashPrefix option. +the hashPrefix option. In addition to the on-slide container state class +kept by core, this module adds an on-slide state class that uses the id of each +slide. */ (function ($, deck, window, undefined) { var $d = $(document), @@ -62,6 +64,7 @@ the hashPrefix option. $d.bind('deck.init', function() { + var opts = $[deck]('getOptions'); $internals = $(); $.each($[deck]('getSlides'), function(i, $el) { @@ -69,7 +72,7 @@ the hashPrefix option. /* Hand out ids to the unfortunate slides born without them */ if (!$el.attr('id')) { - $el.attr('id', $[deck]('getOptions').hashPrefix + i); + $el.attr('id', opts.hashPrefix + i); } hash ='#' + $el.attr('id'); @@ -90,12 +93,21 @@ the hashPrefix option. goByHash($(this).attr('href')); }); } + + /* Set up first id container state class */ + $[deck]('getContainer').addClass(opts.classes.onPrefix + $[deck]('getSlide').attr('id')); }) - /* Update permalink and address bar on a slide change */ + /* Update permalink, address bar, and state class on a slide change */ .bind('deck.change', function(e, from, to) { - var hash = '#' + $[deck]('getSlide', to).attr('id'); + var hash = '#' + $[deck]('getSlide', to).attr('id'), + opts = $[deck]('getOptions'), + osp = opts.classes.onPrefix, + $c = $[deck]('getContainer'); + + $c.removeClass(osp + $[deck]('getSlide', from).attr('id')); + $c.addClass(osp + $[deck]('getSlide', to).attr('id')); - $($[deck]('getOptions').selectors.hashLink).attr('href', hash); + $(opts.selectors.hashLink).attr('href', hash); if (Modernizr.history) { window.history.replaceState({}, "", hash); } diff --git a/test/spec.hash.js b/test/spec.hash.js index 57b4016f..62a10f68 100644 --- a/test/spec.hash.js +++ b/test/spec.hash.js @@ -17,6 +17,18 @@ describe('Deck JS Hash Extension', function() { }); }); + it('should update container with a state class including the slide id', function() { + var $c = $.deck('getContainer'), + osp = defaults.classes.onPrefix; + + expect($c).toHaveClass(osp + $.deck('getSlide', 0).attr('id')); + $.deck('next'); + expect($c).toHaveClass(osp + $.deck('getSlide', 1).attr('id')); + $.deck('next'); + expect($c).not.toHaveClass(osp + $.deck('getSlide', 1).attr('id')); + expect($c).toHaveClass(osp + $.deck('getSlide', 2).attr('id')); + }); + it('should update the href on slide change', function() { var $hashLink = $(defaults.selectors.hashLink); $.deck('go', 3); From d327e2046e740d704648b77056d9977591c08b37 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 8 Oct 2011 13:03:50 +0800 Subject: [PATCH 051/169] Remove references to versioning --- core/deck.core.js | 2 +- extensions/goto/deck.goto.js | 2 +- extensions/hash/deck.hash.js | 2 +- extensions/menu/deck.menu.js | 2 +- extensions/navigation/deck.navigation.js | 2 +- extensions/scale/deck.scale.js | 2 +- extensions/status/deck.status.js | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index f91d3c93..4922dd44 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -1,5 +1,5 @@ /*! -Deck JS - deck.core - v1.0 +Deck JS - deck.core Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt diff --git a/extensions/goto/deck.goto.js b/extensions/goto/deck.goto.js index 702c0576..10c570fd 100644 --- a/extensions/goto/deck.goto.js +++ b/extensions/goto/deck.goto.js @@ -1,5 +1,5 @@ /*! -Deck JS - deck.goto - v1.0 +Deck JS - deck.goto Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt diff --git a/extensions/hash/deck.hash.js b/extensions/hash/deck.hash.js index 8bc39ffd..96c5caac 100644 --- a/extensions/hash/deck.hash.js +++ b/extensions/hash/deck.hash.js @@ -1,5 +1,5 @@ /*! -Deck JS - deck.hash - v1.0 +Deck JS - deck.hash Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 26b9f697..75164eb7 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -1,5 +1,5 @@ /*! -Deck JS - deck.menu - v1.0 +Deck JS - deck.menu Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt diff --git a/extensions/navigation/deck.navigation.js b/extensions/navigation/deck.navigation.js index b4f95b8d..4649fc8f 100644 --- a/extensions/navigation/deck.navigation.js +++ b/extensions/navigation/deck.navigation.js @@ -1,5 +1,5 @@ /*! -Deck JS - deck.navigation - v1.0 +Deck JS - deck.navigation Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index b0db9c35..e29366e9 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -1,5 +1,5 @@ /*! -Deck JS - deck.scale - v1.0 +Deck JS - deck.scale Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt diff --git a/extensions/status/deck.status.js b/extensions/status/deck.status.js index 0ed90a0b..2a605f34 100644 --- a/extensions/status/deck.status.js +++ b/extensions/status/deck.status.js @@ -1,5 +1,5 @@ /*! -Deck JS - deck.status - v1.0 +Deck JS - deck.status Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt From dd22fe82197dd5d179f5f92911009a38ef426d1b Mon Sep 17 00:00:00 2001 From: Daniel Knittl-Frank Date: Sat, 8 Oct 2011 03:14:00 +0200 Subject: [PATCH 052/169] Show all slides when printing a presentation. Explicitly set opacity to 1 for printers Signed-off-by: Daniel Knittl-Frank --- core/deck.core.css | 1 + core/deck.core.scss | 1 + 2 files changed, 2 insertions(+) diff --git a/core/deck.core.css b/core/deck.core.css index 29ab0d04..421d6128 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -364,6 +364,7 @@ body.deck-container { -o-transform: none !important; -ms-transform: none !important; transform: none !important; + opacity:1 !important; } h1 { diff --git a/core/deck.core.scss b/core/deck.core.scss index ed82964e..9d19affb 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -402,6 +402,7 @@ body.deck-container { -o-transform:none !important; -ms-transform:none !important; transform:none !important; + opacity:1 !important; } h1 { From af024461bb7794eb000c674b1a65a124acf9af77 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 17 Oct 2011 14:40:06 +0800 Subject: [PATCH 053/169] Fix (in part) pseudoelement shadows on slides --- core/deck.core.css | 2 +- themes/style/web-2.0.css | 2 ++ themes/style/web-2.0.scss | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/core/deck.core.css b/core/deck.core.css index 421d6128..130665b3 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -364,7 +364,7 @@ body.deck-container { -o-transform: none !important; -ms-transform: none !important; transform: none !important; - opacity:1 !important; + opacity: 1 !important; } h1 { diff --git a/themes/style/web-2.0.css b/themes/style/web-2.0.css index a5da81a2..e9f3b6bf 100644 --- a/themes/style/web-2.0.css +++ b/themes/style/web-2.0.css @@ -42,6 +42,7 @@ border-color: #cde; background: #fff; position: relative; + z-index: auto; /* http://nicolasgallagher.com/css-drop-shadows-without-images/ */ } .borderradius .deck-container pre { @@ -88,6 +89,7 @@ background: #fff; position: relative; border: 1px solid #cde; + z-index: auto; } .borderradius .deck-container blockquote { -webkit-border-radius: 5px; diff --git a/themes/style/web-2.0.scss b/themes/style/web-2.0.scss index de417f16..8f6a10eb 100644 --- a/themes/style/web-2.0.scss +++ b/themes/style/web-2.0.scss @@ -62,6 +62,7 @@ border-color:#cde; background:#fff; position:relative; + z-index:auto; .borderradius & { @include border-radius(5px); @@ -104,6 +105,7 @@ background:#fff; position:relative; border:1px solid #cde; + z-index:auto; .borderradius & { @include border-radius(5px); From f25a8d448324794e75ffa408a3b6f82d4457b076 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 17 Oct 2011 23:20:53 +0800 Subject: [PATCH 054/169] Change test suite to reference local jQuery --- test/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/index.html b/test/index.html index ddd265b1..f5f8474b 100644 --- a/test/index.html +++ b/test/index.html @@ -7,7 +7,7 @@ - + From ecc71cef4b68613f226d4d257a4d025313fd443f Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 17 Oct 2011 23:27:48 +0800 Subject: [PATCH 055/169] #38: Add option to ignore nested slides in deck.status --- extensions/status/deck.status.js | 49 +++++++++++++++++++++++++++++--- test/fixtures/nesteds.html | 36 +++++++++++++++++++++++ test/spec.status.js | 30 +++++++++++++++++++ 3 files changed, 111 insertions(+), 4 deletions(-) create mode 100644 test/fixtures/nesteds.html diff --git a/extensions/status/deck.status.js b/extensions/status/deck.status.js index 2a605f34..2cfaee53 100644 --- a/extensions/status/deck.status.js +++ b/extensions/status/deck.status.js @@ -20,23 +20,64 @@ This module adds a (current)/(total) style status indicator to the deck. options.selectors.statusTotal The element matching this selector displays the total number of slides. + + options.countNested + If false, only top level slides will be counted in the current and + total numbers. */ $.extend(true, $[deck].defaults, { selectors: { statusCurrent: '.deck-status-current', statusTotal: '.deck-status-total' - } + }, + + countNested: true }); $d.bind('deck.init', function() { + var opts = $[deck]('getOptions'); + // Start on first slide - $($[deck]('getOptions').selectors.statusCurrent).text(1); + $(opts.selectors.statusCurrent).text(1); // Set total slides once - $($[deck]('getOptions').selectors.statusTotal).text($[deck]('getSlides').length); + if (opts.countNested) { + $(opts.selectors.statusTotal).text($[deck]('getSlides').length); + } + else { + /* Determine root slides by checking each slide's ancestor tree for + any of the slide classes. */ + var rootIndex = 1, + slideTest = $.map([ + opts.classes.before, + opts.classes.previous, + opts.classes.current, + opts.classes.next, + opts.classes.after + ], function(el, i) { + return '.' + el; + }).join(', '); + + /* Store the 'real' root slide number for use during slide changes. */ + $.each($[deck]('getSlides'), function(i, $el) { + var $parentSlides = $el.parentsUntil(opts.selectors.container, slideTest); + + $el.data('rootSlide', $parentSlides.length ? + $parentSlides.last().data('rootSlide') : + rootIndex++ + ); + }); + + $(opts.selectors.statusTotal).text(rootIndex - 1); + } }) /* Update current slide number with each change event */ .bind('deck.change', function(e, from, to) { - $($[deck]('getOptions').selectors.statusCurrent).text(to + 1); + var opts = $[deck]('getOptions'); + + $(opts.selectors.statusCurrent).text(opts.countNested ? + to + 1 : + $[deck]('getSlide', to).data('rootSlide') + ); }); })(jQuery, 'deck'); diff --git a/test/fixtures/nesteds.html b/test/fixtures/nesteds.html new file mode 100644 index 00000000..4c43b26a --- /dev/null +++ b/test/fixtures/nesteds.html @@ -0,0 +1,36 @@ +
+
+
+ +
+
+ +
+
+
+
+
+
+
+
+
+
+ +
+
+ +
+
+ +

+ + / + +

+ +
+ + + +
+
\ No newline at end of file diff --git a/test/spec.status.js b/test/spec.status.js index fdfd7ade..dd116723 100644 --- a/test/spec.status.js +++ b/test/spec.status.js @@ -22,4 +22,34 @@ describe('Deck JS Status Indicator', function() { $.deck('go', 2); expect($(defaults.selectors.statusCurrent)).toHaveText('3'); }); +}); + +describe('countNested false indicator', function() { + beforeEach(function() { + loadFixtures('nesteds.html'); + if (Modernizr.history) { + history.replaceState({}, "", "#") + } + else { + window.location.hash = '#'; + } + $.deck('.slide', { + countNested: false + }); + }); + + it('should ignore nested slides in the total', function() { + expect($(defaults.selectors.statusTotal)).toHaveText('5'); + }); + + it('should update to the root slide number when nested becomes active', function() { + $.deck('go', 10); + expect($(defaults.selectors.statusCurrent)).toHaveText('4'); + $.deck('prev'); + expect($(defaults.selectors.statusCurrent)).toHaveText('3'); + $.deck('go', 3); + expect($(defaults.selectors.statusCurrent)).toHaveText('3'); + $.deck('go', 1); + expect($(defaults.selectors.statusCurrent)).toHaveText('2'); + }); }); \ No newline at end of file From 8d8282bf9b50e715dcbbf93e4fa5966f470b7eda Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 17 Oct 2011 23:29:11 +0800 Subject: [PATCH 056/169] Fix 404 in test suite --- test/fixtures/iframes.html | 2 +- test/spec.core.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/fixtures/iframes.html b/test/fixtures/iframes.html index ccbd179e..016665ee 100644 --- a/test/fixtures/iframes.html +++ b/test/fixtures/iframes.html @@ -5,7 +5,7 @@
- +
diff --git a/test/spec.core.js b/test/spec.core.js index 03b31e33..bcb37a48 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -361,11 +361,11 @@ describe('Deck JS', function() { it('should remove/restore iframe sources when leaving/entering a slide', function() { $.deck('go', 4); - expect($.deck('getSlide').find('iframe').attr('src')).toEqual('iframe_simple.html'); + expect($.deck('getSlide').find('iframe').attr('src')).toEqual('fixtures/iframe_simple.html'); $.deck('next'); expect($('.slide5').find('iframe').attr('src')).toEqual(''); $.deck('prev'); - expect($('.slide5').find('iframe').attr('src')).toEqual('iframe_simple.html'); + expect($('.slide5').find('iframe').attr('src')).toEqual('fixtures/iframe_simple.html'); }); it('should not store blank iframe sources', function() { From 349d3544f7649b3530af115f5a07157aef16b3dc Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 18 Oct 2011 23:36:52 +0800 Subject: [PATCH 057/169] Change h1 centering from 3d transform to 2d, closes #42 --- core/deck.core.css | 7 ++----- core/deck.core.scss | 4 ++-- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/core/deck.core.css b/core/deck.core.css index 130665b3..62a4ec36 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -191,11 +191,11 @@ html { left: 0; right: 0; top: 50%; - -webkit-transform: translate3d(0, -50%, 0); + -webkit-transform: translate(0, -50%); -moz-transform: translate(0, -50%); -ms-transform: translate(0, -50%); -o-transform: translate(0, -50%); - transform: translate3d(0, -50%, 0); + transform: translate(0, -50%); } .deck-container h2 { font-size: 2.25em; @@ -289,12 +289,9 @@ body.deck-container { overflow: visible; } -@media all and (orientation:portrait) {} -@media all and (orientation:landscape) {} @media screen and (max-device-width: 480px) { /* html { -webkit-text-size-adjust:none; -ms-text-size-adjust:none; } */ } - @media print { * { background: transparent !important; diff --git a/core/deck.core.scss b/core/deck.core.scss index 9d19affb..1c639101 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -237,11 +237,11 @@ html { left:0; right:0; top:50%; - -webkit-transform:translate3d(0, -50%, 0); + -webkit-transform:translate(0, -50%); -moz-transform:translate(0, -50%); -ms-transform:translate(0, -50%); -o-transform:translate(0, -50%); - transform:translate3d(0, -50%, 0); + transform:translate(0, -50%); } } From f88830503fde5ddba0a40f4a4e06ad1261afe408 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 22 Oct 2011 15:35:50 +0800 Subject: [PATCH 058/169] Cache container --- core/deck.core.js | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index 4922dd44..4026d185 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -18,6 +18,7 @@ that use the API provided by core. (function($, deck, document, undefined) { var slides, // Array of all the uh, slides... current, // Array index of the current slide + $container, // Keeping this cached events = { /* @@ -62,7 +63,6 @@ that use the API provided by core. updateStates = function() { var oc = options.classes, osc = options.selectors.container, - $container = $(osc), old = $container.data('onSlide'), $all = $(); @@ -134,7 +134,6 @@ that use the API provided by core. */ init: function(elements, opts) { var startTouch, - $c, tolerance, esp = function(e) { e.stopPropagation(); @@ -143,11 +142,11 @@ that use the API provided by core. options = $.extend(true, {}, $[deck].defaults, opts); slides = []; current = 0; - $c = $[deck]('getContainer'); + $container = $(options.selectors.container); tolerance = options.touch.swipeTolerance; // Hide the deck while states are being applied to kill transitions - $c.addClass(options.classes.loading); + $container.addClass(options.classes.loading); // Fill slides array depending on parameter type if ($.isArray(elements)) { @@ -174,7 +173,7 @@ that use the API provided by core. }); /* Bind touch events for swiping between slides on touch devices */ - $c.unbind('touchstart.deck').bind('touchstart.deck', function(e) { + $container.unbind('touchstart.deck').bind('touchstart.deck', function(e) { if (!startTouch) { startTouch = $.extend({}, e.originalEvent.targetTouches[0]); } @@ -226,7 +225,7 @@ that use the API provided by core. updateStates(); // Show deck again now that slides are in place - $c.removeClass(options.classes.loading); + $container.removeClass(options.classes.loading); $d.trigger(events.initialize); }, @@ -297,7 +296,7 @@ that use the API provided by core. container option. */ getContainer: function() { - return $(options.selectors.container); + return $container; }, /* From c12e68771a0eb1032cf084c954da979991ed89d6 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 22 Oct 2011 20:20:40 +0800 Subject: [PATCH 059/169] Detach container during menu toggles, giant perf improvement in short circuiting transitions --- extensions/menu/deck.menu.js | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 75164eb7..2740dbc8 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -49,8 +49,13 @@ on the deck container. to the deck container. */ $[deck]('extend', 'showMenu', function() { - $[deck]('getContainer').addClass($[deck]('getOptions').classes.menu); - $[deck]('getContainer').scrollTop($[deck]('getSlide').offset().top); + var $c = $[deck]('getContainer'), + $placeholder = $('<' + $c.get(0).tagName + '>'); + + $c.replaceWith($placeholder); + $c.addClass($[deck]('getOptions').classes.menu); + $placeholder.replaceWith($c); + $c.scrollTop($[deck]('getSlide').offset().top); }); /* @@ -60,8 +65,13 @@ on the deck container. option from the deck container. */ $[deck]('extend', 'hideMenu', function() { - $[deck]('getContainer').removeClass($[deck]('getOptions').classes.menu); - $[deck]('getContainer').scrollTop(0); + var $c = $[deck]('getContainer'), + $placeholder = $('<' + $c.get(0).tagName + '>'); + + $c.replaceWith($placeholder); + $c.removeClass($[deck]('getOptions').classes.menu); + $placeholder.replaceWith($c); + $c.scrollTop(0); }); /* From 40db993adedb1ea63b7df97cce28abc8b41ecdb3 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sun, 23 Oct 2011 13:28:30 +0800 Subject: [PATCH 060/169] Better scaling styles for menu on browsers that support transforms --- extensions/menu/deck.menu.css | 38 ++++++++++++++++++++------ extensions/menu/deck.menu.js | 42 ++++++++++++++++++++++++++-- extensions/menu/deck.menu.scss | 50 ++++++++++++++++++++++++++-------- 3 files changed, 109 insertions(+), 21 deletions(-) diff --git a/extensions/menu/deck.menu.css b/extensions/menu/deck.menu.css index 58c5c398..2c11d7cd 100644 --- a/extensions/menu/deck.menu.css +++ b/extensions/menu/deck.menu.css @@ -1,4 +1,12 @@ -.deck-menu > .slide { +.deck-menu .slide { + background: #eee; + position: relative; + left: 0; + top: 0; + visibility: visible; + cursor: pointer; +} +.no-csstransforms .deck-menu > .slide { float: left; width: 22%; height: 22%; @@ -8,13 +16,24 @@ overflow: hidden; padding: 0 0.5%; } -.deck-menu .slide { - background: #eee; - position: relative; - left: 0; - top: 0; - visibility: visible; - cursor: pointer; +.csstransforms .deck-menu > .slide { + -webkit-transform: scale(0.22); + -moz-transform: scale(0.22); + -o-transform: scale(0.22); + -ms-transform: scale(0.22); + transform: scale(0.22); + -webkit-transform-origin: 0 0; + -moz-transform-origin: 0 0; + -o-transform-origin: 0 0; + -ms-transform-origin: 0 0; + transform-origin: 0 0; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + width: 100%; + height: 100%; + overflow: hidden; + padding: 0 48px; } .deck-menu iframe, .deck-menu img, .deck-menu video { max-width: 100%; @@ -22,3 +41,6 @@ .deck-menu .deck-current, .no-touch .deck-menu .slide:hover { background: #ddf; } +.deck-menu.deck-container:hover .deck-prev-link, .deck-menu.deck-container:hover .deck-next-link { + display: none; +} diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index 2740dbc8..c197be0f 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -12,7 +12,8 @@ slides in the deck. The deck menu state is indicated by the presence of a class on the deck container. */ (function($, deck, undefined) { - var $d = $(document); + var $d = $(document), + rootSlides; /* Extends defaults/options. @@ -53,7 +54,19 @@ on the deck container. $placeholder = $('<' + $c.get(0).tagName + '>'); $c.replaceWith($placeholder); + $c.addClass($[deck]('getOptions').classes.menu); + if (Modernizr.csstransforms) { + $.each(rootSlides, function(i, $slide) { + $slide.data('oldStyle', $slide.attr('style')); + $slide.css({ + 'position': 'absolute', + 'left': ((i % 4) * 25) + '%', + 'top': (Math.floor(i / 4) * 25) + '%' + }); + }); + } + $placeholder.replaceWith($c); $c.scrollTop($[deck]('getSlide').offset().top); }); @@ -69,7 +82,16 @@ on the deck container. $placeholder = $('<' + $c.get(0).tagName + '>'); $c.replaceWith($placeholder); + $c.removeClass($[deck]('getOptions').classes.menu); + if (Modernizr.csstransforms) { + $.each(rootSlides, function(i, $slide) { + var oldStyle = $slide.data('oldStyle'); + + $slide.attr('style', oldStyle ? oldStyle : ''); + }); + } + $placeholder.replaceWith($c); $c.scrollTop(0); }); @@ -87,7 +109,23 @@ on the deck container. $d.bind('deck.init', function() { var opts = $[deck]('getOptions'), touchEndTime = 0, - currentSlide; + currentSlide, + slideTest = $.map([ + opts.classes.before, + opts.classes.previous, + opts.classes.current, + opts.classes.next, + opts.classes.after + ], function(el, i) { + return '.' + el; + }).join(', '); + + rootSlides = []; + $.each($[deck]('getSlides'), function(i, $el) { + if (!$el.parentsUntil(opts.selectors.container, slideTest).length) { + rootSlides.push($el); + } + }); // Bind key events $d.unbind('keydown.deckmenu').bind('keydown.deckmenu', function(e) { diff --git a/extensions/menu/deck.menu.scss b/extensions/menu/deck.menu.scss index bc6e6212..0b64464f 100755 --- a/extensions/menu/deck.menu.scss +++ b/extensions/menu/deck.menu.scss @@ -1,15 +1,4 @@ .deck-menu { - > .slide { - float:left; - width:22%; - height:22%; - min-height:0; - margin:1%; - font-size:0.22em; - overflow:hidden; - padding:0 0.5%; - } - .slide { background:#eee; position:relative; @@ -19,6 +8,39 @@ cursor:pointer; } + > .slide { + .no-csstransforms & { + float:left; + width:22%; + height:22%; + min-height:0; + margin:1%; + font-size:0.22em; + overflow:hidden; + padding:0 0.5%; + } + + .csstransforms & { + -webkit-transform:scale(.22); + -moz-transform:scale(.22); + -o-transform:scale(.22); + -ms-transform:scale(.22); + transform:scale(.22); + -webkit-transform-origin:0 0; + -moz-transform-origin:0 0; + -o-transform-origin:0 0; + -ms-transform-origin:0 0; + transform-origin:0 0; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + width:100%; + height:100%; + overflow:hidden; + padding:0 48px; + } + } + iframe, img, video { max-width:100%; } @@ -26,4 +48,10 @@ .deck-current, .no-touch & .slide:hover { background:#ddf; } + + &.deck-container:hover { + .deck-prev-link, .deck-next-link { + display:none; + } + } } \ No newline at end of file From c8ecb246177c75bd2bdce6344ded44d16bee316d Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sun, 23 Oct 2011 13:38:32 +0800 Subject: [PATCH 061/169] Code cleanup --- extensions/menu/deck.menu.js | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index c197be0f..fc94da09 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -13,7 +13,8 @@ on the deck container. */ (function($, deck, undefined) { var $d = $(document), - rootSlides; + rootSlides, // Array of top level slides + $placeholder; // Holds the place of the deck container during detachment /* Extends defaults/options. @@ -50,12 +51,14 @@ on the deck container. to the deck container. */ $[deck]('extend', 'showMenu', function() { - var $c = $[deck]('getContainer'), - $placeholder = $('<' + $c.get(0).tagName + '>'); + var $c = $[deck]('getContainer'); + // Detaching for this big style change for performance (no transitions!) $c.replaceWith($placeholder); - $c.addClass($[deck]('getOptions').classes.menu); + + /* Forced to do this in JS until CSS learns second-grade math. Save old + style value for restoration when menu is hidden. */ if (Modernizr.csstransforms) { $.each(rootSlides, function(i, $slide) { $slide.data('oldStyle', $slide.attr('style')); @@ -78,12 +81,12 @@ on the deck container. option from the deck container. */ $[deck]('extend', 'hideMenu', function() { - var $c = $[deck]('getContainer'), - $placeholder = $('<' + $c.get(0).tagName + '>'); + var $c = $[deck]('getContainer'); $c.replaceWith($placeholder); - $c.removeClass($[deck]('getOptions').classes.menu); + + /* Restore old style value */ if (Modernizr.csstransforms) { $.each(rootSlides, function(i, $slide) { var oldStyle = $slide.data('oldStyle'); @@ -120,6 +123,10 @@ on the deck container. return '.' + el; }).join(', '); + // Create placeholder element + $placeholder = $('<' + $[deck]('getContainer').get(0).tagName + '>'); + + // Build top level slides array rootSlides = []; $.each($[deck]('getSlides'), function(i, $el) { if (!$el.parentsUntil(opts.selectors.container, slideTest).length) { From 14ec24ad4abd5a7d8ed6a1ac45796b059e09db51 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sun, 23 Oct 2011 16:26:51 +0800 Subject: [PATCH 062/169] Fixes #41: Implement Nicolas Gallagher's fix for transformed elements with pseudo shadows --- themes/style/web-2.0.css | 25 +++++++++++++++++++++++-- themes/style/web-2.0.scss | 26 ++++++++++++++++++++++++-- 2 files changed, 47 insertions(+), 4 deletions(-) diff --git a/themes/style/web-2.0.css b/themes/style/web-2.0.css index e9f3b6bf..e6803bd3 100644 --- a/themes/style/web-2.0.css +++ b/themes/style/web-2.0.css @@ -1,3 +1,4 @@ +@charset "UTF-8"; .deck-container { font-family: "Gill Sans", "Gill Sans MT", Calibri, sans-serif; font-size: 1.25em; @@ -50,10 +51,20 @@ -moz-border-radius: 5px; border-radius: 5px; } -.csstransforms.boxshadow .deck-container pre:before, .csstransforms.boxshadow .deck-container pre:after { +.csstransforms.boxshadow .deck-container pre > :first-child:before { content: ""; position: absolute; z-index: -1; + background: #fff; + top: 0; + bottom: 0; + left: 0; + right: 0; +} +.csstransforms.boxshadow .deck-container pre:before, .csstransforms.boxshadow .deck-container pre:after { + content: ""; + position: absolute; + z-index: -2; bottom: 15px; width: 50%; height: 20%; @@ -96,10 +107,20 @@ -moz-border-radius: 5px; border-radius: 5px; } -.boxshadow .deck-container blockquote:after { +.boxshadow .deck-container blockquote > :first-child:before { content: ""; position: absolute; z-index: -1; + background: #fff; + top: 0; + bottom: 0; + left: 0; + right: 0; +} +.boxshadow .deck-container blockquote:after { + content: ""; + position: absolute; + z-index: -2; top: 10px; bottom: 10px; left: 0; diff --git a/themes/style/web-2.0.scss b/themes/style/web-2.0.scss index 8f6a10eb..39a22bce 100644 --- a/themes/style/web-2.0.scss +++ b/themes/style/web-2.0.scss @@ -70,10 +70,21 @@ /* http://nicolasgallagher.com/css-drop-shadows-without-images/ */ .csstransforms.boxshadow & { - &:before, &:after { + > :first-child:before { content:""; position:absolute; z-index:-1; + background:#fff; + top:0; + bottom:0; + left:0; + right:0; + } + + &:before, &:after { + content:""; + position:absolute; + z-index:-2; bottom:15px; width:50%; height:20%; @@ -112,10 +123,21 @@ } .boxshadow & { - &:after { + > :first-child:before { content:""; position:absolute; z-index:-1; + background:#fff; + top:0; + bottom:0; + left:0; + right:0; + } + + &:after { + content:""; + position:absolute; + z-index:-2; top: 10px; bottom: 10px; left: 0; From 912ffb634dca24061f47763531970ac961798d3d Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sun, 23 Oct 2011 17:56:09 +0800 Subject: [PATCH 063/169] Store assigned ids and compare to ids on init to determine need for reassignment, fixes #44 --- extensions/hash/deck.hash.js | 3 ++- test/spec.hash.js | 9 +++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/extensions/hash/deck.hash.js b/extensions/hash/deck.hash.js index 96c5caac..d67f343f 100644 --- a/extensions/hash/deck.hash.js +++ b/extensions/hash/deck.hash.js @@ -71,8 +71,9 @@ slide. var hash; /* Hand out ids to the unfortunate slides born without them */ - if (!$el.attr('id')) { + if (!$el.attr('id') || $el.data('deckAssignedId') === $el.attr('id')) { $el.attr('id', opts.hashPrefix + i); + $el.data('deckAssignedId', opts.hashPrefix + i); } hash ='#' + $el.attr('id'); diff --git a/test/spec.hash.js b/test/spec.hash.js index 62a10f68..fa7bcabd 100644 --- a/test/spec.hash.js +++ b/test/spec.hash.js @@ -17,6 +17,15 @@ describe('Deck JS Hash Extension', function() { }); }); + it('should reassign ids on reinitialization', function() { + var $firstSlide = $.deck('getSlide', 0), + firstID = $firstSlide.attr('id'); + + $firstSlide.before('
'); + $.deck('.slide'); + expect($firstSlide).not.toHaveId(firstID); + }); + it('should update container with a state class including the slide id', function() { var $c = $.deck('getContainer'), osp = defaults.classes.onPrefix; From 71d603a38271104f3394b2ae3ecbc55483398ec3 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 25 Oct 2011 15:32:13 +0800 Subject: [PATCH 064/169] Adjust menu margins --- extensions/menu/deck.menu.css | 1 + extensions/menu/deck.menu.scss | 1 + 2 files changed, 2 insertions(+) diff --git a/extensions/menu/deck.menu.css b/extensions/menu/deck.menu.css index 2c11d7cd..3e885490 100644 --- a/extensions/menu/deck.menu.css +++ b/extensions/menu/deck.menu.css @@ -34,6 +34,7 @@ height: 100%; overflow: hidden; padding: 0 48px; + margin: 12px; } .deck-menu iframe, .deck-menu img, .deck-menu video { max-width: 100%; diff --git a/extensions/menu/deck.menu.scss b/extensions/menu/deck.menu.scss index 0b64464f..86385c49 100755 --- a/extensions/menu/deck.menu.scss +++ b/extensions/menu/deck.menu.scss @@ -38,6 +38,7 @@ height:100%; overflow:hidden; padding:0 48px; + margin:12px; } } From a68f7e2e1b29af47cc253203eb692cdc355db9c1 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 25 Oct 2011 15:55:31 +0800 Subject: [PATCH 065/169] Add beforeInit event --- core/deck.core.js | 10 ++++++++++ test/spec.core.js | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+) diff --git a/core/deck.core.js b/core/deck.core.js index 4026d185..fbac1a87 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -33,6 +33,13 @@ that use the API provided by core. */ change: 'deck.change', + /* + This event fires at the beginning of deck initialization, after the options + are set but before the slides array is created. This event makes a good hook + for preprocessing extensions looking to modify the deck. + */ + beforeInitialize: 'deck.beforeInit', + /* This event fires at the end of deck initialization. Extensions should implement any code that relies on user extensible options (key bindings, @@ -145,6 +152,9 @@ that use the API provided by core. $container = $(options.selectors.container); tolerance = options.touch.swipeTolerance; + // Pre init event for preprocessing hooks + $d.trigger(events.beforeInitialize); + // Hide the deck while states are being applied to kill transitions $container.addClass(options.classes.loading); diff --git a/test/spec.core.js b/test/spec.core.js index bcb37a48..a4f3b5ac 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -238,6 +238,8 @@ describe('Deck JS', function() { var $d = $(document); beforeEach(function() { + spyOnEvent($d, 'deck.init'); + spyOnEvent($d, 'deck.beforeInit'); $.deck('.slide'); $.deck('go', 1); spyOnEvent($d, 'deck.change'); @@ -270,6 +272,38 @@ describe('Deck JS', function() { $d.unbind('deck.change', f); }); }); + + describe('deck.init', function() { + it('should fire on deck initialization', function() { + expect('deck.init').toHaveBeenTriggeredOn($d); + }); + + it('should have already populated the slides array', function() { + var f = function() { + expect($.deck('getSlides').length).toBeGreaterThan(0); + }; + + $d.bind('deck.init', f); + $.deck('.slide'); + $d.unbind('deck.init', f); + }); + }); + + describe('deck.beforeInit', function() { + it('should fire on deck initialization', function() { + expect('deck.beforeInit').toHaveBeenTriggeredOn($d); + }); + + it('should have not populated the slides array', function() { + var f = function() { + expect($.deck('getSlides').length).toEqual(0); + }; + + $d.bind('deck.beforeInit', f); + $.deck('.slide'); + $d.unbind('deck.beforeInit', f); + }); + }); }); }); From 75a07a7aa8c8818614e47f2006dd8e2bcd609796 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 25 Oct 2011 16:42:39 +0800 Subject: [PATCH 066/169] Make deck.change preventable, closes #48 --- core/deck.core.js | 13 +++++++++---- test/spec.core.js | 7 +++++++ 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index fbac1a87..f26d58a4 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -25,7 +25,8 @@ that use the API provided by core. This event fires whenever the current slide changes, whether by way of next, prev, or go. The callback function is passed two parameters, from and to, equal to the indices of the old slide and the new slide - respectively. + respectively. If preventDefault is called on the event within this handler + the slide change does not occur. $(document).bind('deck.change', function(event, from, to) { alert('Moving from slide ' + from + ' to ' + to); @@ -249,11 +250,15 @@ that use the API provided by core. or not a number the call is ignored. */ go: function(index) { + var e = $.Event(events.change); + if (typeof index != 'number' || index < 0 || index >= slides.length) return; - $d.trigger(events.change, [current, index]); - current = index; - updateStates(); + $d.trigger(e, [current, index]); + if (!e.isDefaultPrevented()) { + current = index; + updateStates(); + } }, /* diff --git a/test/spec.core.js b/test/spec.core.js index a4f3b5ac..e6ac1da0 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -271,6 +271,13 @@ describe('Deck JS', function() { $.deck('go', 3); $d.unbind('deck.change', f); }); + + it('should not change slides if default prevented', function() { + $d.bind('deck.change', false); + $.deck('go', 3); + expect($.deck('getSlide')).toEqual($.deck('getSlide', 1)); + $d.unbind('deck.change', false); + }); }); describe('deck.init', function() { From 0204c7310e6cd8c1604b305617060b8bb539cbeb Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 25 Oct 2011 17:10:21 +0800 Subject: [PATCH 067/169] Refactor base styles to apply to slides insted of container --- core/deck.core.css | 48 +++---- core/deck.core.scss | 24 ++-- themes/style/neon.css | 26 ++-- themes/style/neon.scss | 116 ++++++++--------- themes/style/swiss.css | 24 ++-- themes/style/swiss.scss | 90 ++++++------- themes/style/web-2.0.css | 51 ++++---- themes/style/web-2.0.scss | 268 +++++++++++++++++++------------------- 8 files changed, 320 insertions(+), 327 deletions(-) diff --git a/core/deck.core.css b/core/deck.core.css index 62a4ec36..e7a7214e 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -139,10 +139,10 @@ html { .deck-container input[type="checkbox"] { vertical-align: bottom; } -.deck-container .ie7 input[type="checkbox"] { +.ie7 .deck-container input[type="checkbox"] { vertical-align: baseline; } -.deck-container .ie6 input { +.ie6 .deck-container input { vertical-align: text-bottom; } .deck-container label, .deck-container input[type="button"], .deck-container input[type="submit"], .deck-container input[type="image"], .deck-container button { @@ -179,13 +179,22 @@ html { .deck-container a:link { -webkit-tap-highlight-color: #fff; } -.deck-container h1 { +.deck-container.deck-loading { + display: none; +} + +.slide { + width: auto; + min-height: 100%; + position: relative; +} +.slide h1 { font-size: 4.5em; font-weight: bold; text-align: center; padding-top: 1em; } -.csstransforms .deck-container h1 { +.csstransforms .slide h1 { padding: 0 48px; position: absolute; left: 0; @@ -197,66 +206,57 @@ html { -o-transform: translate(0, -50%); transform: translate(0, -50%); } -.deck-container h2 { +.slide h2 { font-size: 2.25em; font-weight: bold; padding-top: .5em; margin: 0 0 .66666em 0; border-bottom: 3px solid #888; } -.deck-container h3 { +.slide h3 { font-size: 1.4375em; font-weight: bold; margin-bottom: .30435em; } -.deck-container h4 { +.slide h4 { font-size: 1.25em; font-weight: bold; margin-bottom: .25em; } -.deck-container h5 { +.slide h5 { font-size: 1.125em; font-weight: bold; margin-bottom: .2222em; } -.deck-container h6 { +.slide h6 { font-size: 1em; font-weight: bold; } -.deck-container img, .deck-container iframe, .deck-container video { +.slide img, .slide iframe, .slide video { display: block; max-width: 100%; } -.deck-container video, .deck-container iframe, .deck-container img { +.slide video, .slide iframe, .slide img { display: block; margin: 0 auto; } -.deck-container p, .deck-container blockquote, .deck-container iframe, .deck-container img, .deck-container ul, .deck-container ol, .deck-container pre, .deck-container video { +.slide p, .slide blockquote, .slide iframe, .slide img, .slide ul, .slide ol, .slide pre, .slide video { margin-bottom: 1em; } -.deck-container pre { +.slide pre { white-space: pre; white-space: pre-wrap; word-wrap: break-word; padding: 1em; border: 1px solid #888; } -.deck-container em { +.slide em { font-style: italic; } -.deck-container li { +.slide li { padding: .25em 0; vertical-align: middle; } -.deck-container.deck-loading { - display: none; -} - -.slide { - width: auto; - min-height: 100%; - position: relative; -} .deck-before, .deck-previous, .deck-next, .deck-after { position: absolute; diff --git a/core/deck.core.scss b/core/deck.core.scss index 1c639101..872ebde8 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -171,11 +171,11 @@ html { vertical-align:bottom; } - .ie7 input[type="checkbox"] { + .ie7 & input[type="checkbox"] { vertical-align:baseline; } - .ie6 input { + .ie6 & input { vertical-align:text-bottom; } @@ -224,7 +224,17 @@ html { } } /* End HTML5 Boilerplate adaptations */ + + &.deck-loading { + display:none; + } +} +.slide { + width:auto; + min-height:100%; + position:relative; + h1 { font-size:4.5em; font-weight:bold; @@ -306,16 +316,6 @@ html { padding:.25em 0; vertical-align:middle; } - - &.deck-loading { - display:none; - } -} - -.slide { - width:auto; - min-height:100%; - position:relative; } .deck-before, .deck-previous, .deck-next, .deck-after { diff --git a/themes/style/neon.css b/themes/style/neon.css index c652dea9..37b604c5 100644 --- a/themes/style/neon.css +++ b/themes/style/neon.css @@ -7,13 +7,13 @@ .deck-container .slide { background: #000; } -.deck-container h1 { +.deck-container .slide h1 { color: #0af; font-weight: normal; font-weight: 100; text-shadow: 0 0 50px #0af, 0 0 3px #fff; } -.deck-container h2 { +.deck-container .slide h2 { color: #af0; border-bottom-color: #ccc; font-weight: normal; @@ -21,31 +21,31 @@ text-shadow: 0 0 15px #af0, 0 0 2px #fff; border-bottom: 1px solid #333; } -.deck-container h3 { +.deck-container .slide h3 { color: #fff; font-weight: normal; font-weight: 100; text-shadow: 0 0 10px #fff, 0 0 2px #fff; } -.deck-container pre { +.deck-container .slide pre { border-color: #333; } -.deck-container pre code { +.deck-container .slide pre code { color: #fff; } -.deck-container code { +.deck-container .slide code { color: #f0a; } -.deck-container blockquote { +.deck-container .slide blockquote { font-size: 2em; padding: 1em 2em; color: #fff; border-left: 5px solid #fff; } -.deck-container blockquote p { +.deck-container .slide blockquote p { margin: 0; } -.deck-container blockquote cite { +.deck-container .slide blockquote cite { font-size: .5em; font-style: normal; font-weight: normal; @@ -53,17 +53,17 @@ color: #aaa; text-shadow: 0 0 15px #fff, 0 0 2px #fff; } -.deck-container ::-moz-selection { +.deck-container .slide ::-moz-selection { background: #a0f; } -.deck-container ::selection { +.deck-container .slide ::selection { background: #a0f; } -.deck-container a, .deck-container a:hover, .deck-container a:focus, .deck-container a:active, .deck-container a:visited { +.deck-container .slide a, .deck-container .slide a:hover, .deck-container .slide a:focus, .deck-container .slide a:active, .deck-container .slide a:visited { color: #f0a; text-decoration: none; } -.deck-container a:hover, .deck-container a:focus { +.deck-container .slide a:hover, .deck-container .slide a:focus { text-decoration: underline; } .deck-container .deck-prev-link, .deck-container .deck-next-link { diff --git a/themes/style/neon.scss b/themes/style/neon.scss index 5a35b751..01b207f3 100644 --- a/themes/style/neon.scss +++ b/themes/style/neon.scss @@ -6,74 +6,74 @@ .slide { background:#000; - } - - h1 { - color:#0af; - font-weight:normal; - font-weight:100; - text-shadow:0 0 50px #0af, 0 0 3px #fff; - } - - h2 { - color:#af0; - border-bottom-color:#ccc; - font-weight:normal; - font-weight:100; - text-shadow:0 0 15px #af0, 0 0 2px #fff; - border-bottom:1px solid #333; - } - - h3 { - color:#fff; - font-weight:normal; - font-weight:100; - text-shadow:0 0 10px #fff, 0 0 2px #fff; - } - - pre { - border-color:#333; - code { - color:#fff; + h1 { + color:#0af; + font-weight:normal; + font-weight:100; + text-shadow:0 0 50px #0af, 0 0 3px #fff; } - } - - code { - color:#f0a; - } - - blockquote { - font-size:2em; - padding:1em 2em; - color:#fff; - border-left:5px solid #fff; - p { - margin:0; + h2 { + color:#af0; + border-bottom-color:#ccc; + font-weight:normal; + font-weight:100; + text-shadow:0 0 15px #af0, 0 0 2px #fff; + border-bottom:1px solid #333; } - cite { - font-size:.5em; - font-style:normal; + h3 { + color:#fff; font-weight:normal; font-weight:100; - color:#aaa; - text-shadow:0 0 15px #fff, 0 0 2px #fff; + text-shadow:0 0 10px #fff, 0 0 2px #fff; } - } - - ::-moz-selection{ background:#a0f; } - ::selection { background:#a0f; } - - a { - &, &:hover, &:focus, &:active, &:visited { + + pre { + border-color:#333; + + code { + color:#fff; + } + } + + code { color:#f0a; - text-decoration:none; } - - &:hover, &:focus { - text-decoration:underline; + + blockquote { + font-size:2em; + padding:1em 2em; + color:#fff; + border-left:5px solid #fff; + + p { + margin:0; + } + + cite { + font-size:.5em; + font-style:normal; + font-weight:normal; + font-weight:100; + color:#aaa; + text-shadow:0 0 15px #fff, 0 0 2px #fff; + } + } + + ::-moz-selection{ background:#a0f; } + ::selection { background:#a0f; } + + a { + &, &:hover, &:focus, &:active, &:visited { + color:#f0a; + text-decoration:none; + } + + &:hover, &:focus { + text-decoration:underline; + } } } diff --git a/themes/style/swiss.css b/themes/style/swiss.css index 54392974..e34b2b38 100644 --- a/themes/style/swiss.css +++ b/themes/style/swiss.css @@ -6,51 +6,51 @@ .deck-container .slide { background: #fff; } -.deck-container h1 { +.deck-container .slide h1 { color: #000; } -.deck-container h2 { +.deck-container .slide h2 { color: #c00; border-bottom-color: #ccc; } -.deck-container h3 { +.deck-container .slide h3 { color: #888; } -.deck-container pre { +.deck-container .slide pre { border-color: #ccc; } -.deck-container code { +.deck-container .slide code { color: #888; } -.deck-container blockquote { +.deck-container .slide blockquote { font-size: 2em; font-style: italic; padding: 1em 2em; color: #000; border-left: 5px solid #ccc; } -.deck-container blockquote p { +.deck-container .slide blockquote p { margin: 0; } -.deck-container blockquote cite { +.deck-container .slide blockquote cite { font-size: .5em; font-style: normal; font-weight: bold; color: #888; } -.deck-container ::-moz-selection { +.deck-container .slide ::-moz-selection { background: #c00; color: #fff; } -.deck-container ::selection { +.deck-container .slide ::selection { background: #c00; color: #fff; } -.deck-container a, .deck-container a:hover, .deck-container a:focus, .deck-container a:active, .deck-container a:visited { +.deck-container .slide a, .deck-container .slide a:hover, .deck-container .slide a:focus, .deck-container .slide a:active, .deck-container .slide a:visited { color: #c00; text-decoration: none; } -.deck-container a:hover, .deck-container a:focus { +.deck-container .slide a:hover, .deck-container .slide a:focus { text-decoration: underline; } .deck-container .deck-prev-link, .deck-container .deck-next-link { diff --git a/themes/style/swiss.scss b/themes/style/swiss.scss index f3ecffca..a60bc4ac 100644 --- a/themes/style/swiss.scss +++ b/themes/style/swiss.scss @@ -5,59 +5,59 @@ .slide { background:#fff; - } - - h1 { - color:#000; - } - - h2 { - color:#c00; - border-bottom-color:#ccc; - } - - h3 { - color:#888; - } - - pre { - border-color:#ccc; - } + + h1 { + color:#000; + } - code { - color:#888; - } + h2 { + color:#c00; + border-bottom-color:#ccc; + } - blockquote { - font-size:2em; - font-style:italic; - padding:1em 2em; - color:#000; - border-left:5px solid #ccc; + h3 { + color:#888; + } - p { - margin:0; + pre { + border-color:#ccc; } - cite { - font-size:.5em; - font-style:normal; - font-weight:bold; + code { color:#888; } - } - - ::-moz-selection{ background:#c00; color:#fff; } - ::selection { background:#c00; color:#fff; } - - a { - &, &:hover, &:focus, &:active, &:visited { - color:#c00; - text-decoration:none; + + blockquote { + font-size:2em; + font-style:italic; + padding:1em 2em; + color:#000; + border-left:5px solid #ccc; + + p { + margin:0; + } + + cite { + font-size:.5em; + font-style:normal; + font-weight:bold; + color:#888; + } } - - &:hover, &:focus { - text-decoration:underline; + + ::-moz-selection{ background:#c00; color:#fff; } + ::selection { background:#c00; color:#fff; } + + a { + &, &:hover, &:focus, &:active, &:visited { + color:#c00; + text-decoration:none; + } + + &:hover, &:focus { + text-decoration:underline; + } } } diff --git a/themes/style/web-2.0.css b/themes/style/web-2.0.css index e6803bd3..9e2cc300 100644 --- a/themes/style/web-2.0.css +++ b/themes/style/web-2.0.css @@ -21,37 +21,37 @@ .deck-container > .slide { text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.5); } -.deck-container h1, .deck-container h2, .deck-container h3, .deck-container h4, .deck-container h5, .deck-container h6 { +.deck-container .slide h1, .deck-container .slide h2, .deck-container .slide h3, .deck-container .slide h4, .deck-container .slide h5, .deck-container .slide h6 { font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; } -.deck-container h1 { +.deck-container .slide h1 { color: #08455f; } -.deck-container h2 { +.deck-container .slide h2 { color: #0b7495; border-bottom: 0; } -.cssreflections .deck-container h2 { +.cssreflections .deck-container .slide h2 { line-height: 1; -webkit-box-reflect: below -0.556em -webkit-gradient(linear, left top, left bottom, from(transparent), color-stop(0.3, transparent), color-stop(0.7, rgba(255, 255, 255, 0.1)), to(transparent)); -moz-box-reflect: below -0.556em -moz-linear-gradient(top, transparent 0%, transparent 30%, rgba(255, 255, 255, 0.3) 100%); } -.deck-container h3 { +.deck-container .slide h3 { color: #000; } -.deck-container pre { +.deck-container .slide pre { border-color: #cde; background: #fff; position: relative; z-index: auto; /* http://nicolasgallagher.com/css-drop-shadows-without-images/ */ } -.borderradius .deck-container pre { +.borderradius .deck-container .slide pre { -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px; } -.csstransforms.boxshadow .deck-container pre > :first-child:before { +.csstransforms.boxshadow .deck-container .slide pre > :first-child:before { content: ""; position: absolute; z-index: -1; @@ -61,7 +61,7 @@ left: 0; right: 0; } -.csstransforms.boxshadow .deck-container pre:before, .csstransforms.boxshadow .deck-container pre:after { +.csstransforms.boxshadow .deck-container .slide pre:before, .csstransforms.boxshadow .deck-container .slide pre:after { content: ""; position: absolute; z-index: -2; @@ -73,7 +73,7 @@ -moz-box-shadow: 0 15px 10px rgba(0, 0, 0, 0.7); box-shadow: 0 15px 10px rgba(0, 0, 0, 0.7); } -.csstransforms.boxshadow .deck-container pre:before { +.csstransforms.boxshadow .deck-container .slide pre:before { left: 10px; -webkit-transform: rotate(-3deg); -moz-transform: rotate(-3deg); @@ -81,7 +81,7 @@ -o-transform: rotate(-3deg); transform: rotate(-3deg); } -.csstransforms.boxshadow .deck-container pre:after { +.csstransforms.boxshadow .deck-container .slide pre:after { right: 10px; -webkit-transform: rotate(3deg); -moz-transform: rotate(3deg); @@ -89,10 +89,10 @@ -o-transform: rotate(3deg); transform: rotate(3deg); } -.deck-container code { +.deck-container .slide code { color: #789; } -.deck-container blockquote { +.deck-container .slide blockquote { font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; font-size: 2em; padding: 1em 2em .5em 2em; @@ -102,12 +102,12 @@ border: 1px solid #cde; z-index: auto; } -.borderradius .deck-container blockquote { +.borderradius .deck-container .slide blockquote { -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px; } -.boxshadow .deck-container blockquote > :first-child:before { +.boxshadow .deck-container .slide blockquote > :first-child:before { content: ""; position: absolute; z-index: -1; @@ -117,7 +117,7 @@ left: 0; right: 0; } -.boxshadow .deck-container blockquote:after { +.boxshadow .deck-container .slide blockquote:after { content: ""; position: absolute; z-index: -2; @@ -131,16 +131,16 @@ -moz-box-shadow: 0 0 15px rgba(0, 0, 0, 0.6); box-shadow: 0 0 15px rgba(0, 0, 0, 0.6); } -.deck-container blockquote p { +.deck-container .slide blockquote p { margin: 0; } -.deck-container blockquote cite { +.deck-container .slide blockquote cite { font-size: .5em; font-style: normal; font-weight: bold; color: #888; } -.deck-container blockquote:before { +.deck-container .slide blockquote:before { content: "“"; position: absolute; top: 0; @@ -150,24 +150,19 @@ color: #ccf0f0; z-index: 1; } -.deck-container .borderradius img { - -webkit-border-radius: 5px; - -moz-border-radius: 5px; - border-radius: 5px; -} -.deck-container ::-moz-selection { +.deck-container .slide ::-moz-selection { background: #08455f; color: #fff; } -.deck-container ::selection { +.deck-container .slide ::selection { background: #08455f; color: #fff; } -.deck-container a, .deck-container a:hover, .deck-container a:focus, .deck-container a:active, .deck-container a:visited { +.deck-container .slide a, .deck-container .slide a:hover, .deck-container .slide a:focus, .deck-container .slide a:active, .deck-container .slide a:visited { color: #599; text-decoration: none; } -.deck-container a:hover, .deck-container a:focus { +.deck-container .slide a:hover, .deck-container .slide a:focus { text-decoration: underline; } .deck-container .deck-prev-link, .deck-container .deck-next-link { diff --git a/themes/style/web-2.0.scss b/themes/style/web-2.0.scss index 39a22bce..406d8ee4 100644 --- a/themes/style/web-2.0.scss +++ b/themes/style/web-2.0.scss @@ -35,168 +35,166 @@ text-shadow:1px 1px 1px rgba(255,255,255,.5); } - h1, h2, h3, h4, h5, h6 { - font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; - } - - h1 { - color:#08455f; - } + .slide { + h1, h2, h3, h4, h5, h6 { + font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; + } - h2 { - color:#0b7495; - border-bottom:0; - - .cssreflections & { - line-height:1; - -webkit-box-reflect:below -0.5555em -webkit-gradient(linear, left top, left bottom, from(transparent), color-stop(0.3, transparent), color-stop(0.7, rgba(255,255,255,.1)), to(transparent)); - -moz-box-reflect:below -0.5555em -moz-linear-gradient(top, transparent 0%, transparent 30%, rgba(255,255,255,.3) 100%); + h1 { + color:#08455f; } - } - h3 { - color:#000; - } + h2 { + color:#0b7495; + border-bottom:0; - pre { - border-color:#cde; - background:#fff; - position:relative; - z-index:auto; - - .borderradius & { - @include border-radius(5px); + .cssreflections & { + line-height:1; + -webkit-box-reflect:below -0.5555em -webkit-gradient(linear, left top, left bottom, from(transparent), color-stop(0.3, transparent), color-stop(0.7, rgba(255,255,255,.1)), to(transparent)); + -moz-box-reflect:below -0.5555em -moz-linear-gradient(top, transparent 0%, transparent 30%, rgba(255,255,255,.3) 100%); + } } - - /* http://nicolasgallagher.com/css-drop-shadows-without-images/ */ - .csstransforms.boxshadow & { - > :first-child:before { - content:""; - position:absolute; - z-index:-1; - background:#fff; - top:0; - bottom:0; - left:0; - right:0; + + h3 { + color:#000; + } + + pre { + border-color:#cde; + background:#fff; + position:relative; + z-index:auto; + + .borderradius & { + @include border-radius(5px); } - - &:before, &:after { - content:""; - position:absolute; - z-index:-2; - bottom:15px; - width:50%; - height:20%; - max-width:300px; - @include box-shadow(0, 15px, 10px, rgba(0, 0, 0, 0.7)); + + /* http://nicolasgallagher.com/css-drop-shadows-without-images/ */ + .csstransforms.boxshadow & { + > :first-child:before { + content:""; + position:absolute; + z-index:-1; + background:#fff; + top:0; + bottom:0; + left:0; + right:0; + } + + &:before, &:after { + content:""; + position:absolute; + z-index:-2; + bottom:15px; + width:50%; + height:20%; + max-width:300px; + @include box-shadow(0, 15px, 10px, rgba(0, 0, 0, 0.7)); + } + + &:before { + left:10px; + @include rotate(-3deg); + } + + &:after { + right:10px; + @include rotate(3deg); + } } - - &:before { - left:10px; - @include rotate(-3deg); + } + + code { + color:#789; + } + + blockquote { + font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; + font-size:2em; + padding:1em 2em .5em 2em; + color:#000; + background:#fff; + position:relative; + border:1px solid #cde; + z-index:auto; + + .borderradius & { + @include border-radius(5px); } - - &:after { - right:10px; - @include rotate(3deg); + + .boxshadow & { + > :first-child:before { + content:""; + position:absolute; + z-index:-1; + background:#fff; + top:0; + bottom:0; + left:0; + right:0; + } + + &:after { + content:""; + position:absolute; + z-index:-2; + top: 10px; + bottom: 10px; + left: 0; + right: 50%; + -moz-border-radius: 10px / 100px; + border-radius: 10px / 100px; + @include box-shadow(0, 0, 15px, rgba(0,0,0,0.6)); + } } - } - } - code { - color:#789; - } + p { + margin:0; + } - blockquote { - font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; - font-size:2em; - padding:1em 2em .5em 2em; - color:#000; - background:#fff; - position:relative; - border:1px solid #cde; - z-index:auto; - - .borderradius & { - @include border-radius(5px); - } - - .boxshadow & { - > :first-child:before { - content:""; + cite { + font-size:.5em; + font-style:normal; + font-weight:bold; + color:#888; + } + + &:before { + content:"“"; position:absolute; - z-index:-1; - background:#fff; top:0; - bottom:0; left:0; - right:0; - } - - &:after { - content:""; - position:absolute; - z-index:-2; - top: 10px; - bottom: 10px; - left: 0; - right: 50%; - -moz-border-radius: 10px / 100px; - border-radius: 10px / 100px; - @include box-shadow(0, 0, 15px, rgba(0,0,0,0.6)); + font-size:5em; + line-height:1; + color:#ccf0f0; + z-index:1; } } - p { - margin:0; - } + ::-moz-selection{ background:#08455f; color:#fff; } + ::selection { background:#08455f; color:#fff; } - cite { - font-size:.5em; - font-style:normal; - font-weight:bold; - color:#888; - } - - &:before { - content:"“"; - position:absolute; - top:0; - left:0; - font-size:5em; - line-height:1; - color:#ccf0f0; - z-index:1; - } - } - - .borderradius img { - @include border-radius(5px); - } - - ::-moz-selection{ background:#08455f; color:#fff; } - ::selection { background:#08455f; color:#fff; } - - a { - &, &:hover, &:focus, &:active, &:visited { - color:#599; - text-decoration:none; - } - - &:hover, &:focus { - text-decoration:underline; + a { + &, &:hover, &:focus, &:active, &:visited { + color:#599; + text-decoration:none; + } + + &:hover, &:focus { + text-decoration:underline; + } } } .deck-prev-link, .deck-next-link { background:#fff; opacity:0.5; - + &, &:hover, &:focus, &:active, &:visited { color:#599; } - + &:hover, &:focus { opacity:1; text-decoration:none; From 5734c4264c9248197d6f3f41b9df1a97f6f30533 Mon Sep 17 00:00:00 2001 From: awirick Date: Wed, 26 Oct 2011 10:47:44 -0500 Subject: [PATCH 068/169] changed status to position fixed to handle vertical scrollbar on slides. --- extensions/status/deck.status.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/status/deck.status.css b/extensions/status/deck.status.css index 259aa445..eeb6ad55 100644 --- a/extensions/status/deck.status.css +++ b/extensions/status/deck.status.css @@ -1,5 +1,5 @@ .deck-container .deck-status { - position: absolute; + position: fixed; bottom: 10px; right: 5px; color: #888; From 71bb06974bbe8ad0ac37da1ec5ad2596ac2e7dc4 Mon Sep 17 00:00:00 2001 From: awirick Date: Wed, 26 Oct 2011 15:08:45 -0500 Subject: [PATCH 069/169] moved fixed status position to only be when deck container is entire body of the document. --- extensions/status/deck.status.css | 6 +++++- extensions/status/deck.status.scss | 8 +++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/extensions/status/deck.status.css b/extensions/status/deck.status.css index eeb6ad55..17d55ad0 100644 --- a/extensions/status/deck.status.css +++ b/extensions/status/deck.status.css @@ -1,5 +1,5 @@ .deck-container .deck-status { - position: fixed; + position: absolute; bottom: 10px; right: 5px; color: #888; @@ -7,6 +7,10 @@ margin: 0; } +body.deck-container .deck-status { + position: fixed; +} + @media print { .deck-status { display: none; diff --git a/extensions/status/deck.status.scss b/extensions/status/deck.status.scss index e5e0edd6..d57af24b 100755 --- a/extensions/status/deck.status.scss +++ b/extensions/status/deck.status.scss @@ -9,8 +9,14 @@ } } +body.deck-container { + .deck-status { + position:fixed; + } +} + @media print { .deck-status { display:none; } -} \ No newline at end of file +} From 9f9bb0ee6e2dab398e54b5cc94a2e015844654a6 Mon Sep 17 00:00:00 2001 From: Caleb Troughton Date: Fri, 28 Oct 2011 15:11:26 +0800 Subject: [PATCH 070/169] Update README.md --- README.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 103739e5..613813fe 100644 --- a/README.md +++ b/README.md @@ -33,11 +33,13 @@ There is an issue with certain builds of Chrome that result in a solid blue back Core includes stripped down black and white print styles for the standard slide template that is suitable for handouts. -## Awesome People +## Awesome Contributors -Big thanks to the folks who have contributed code to the project: - -- [jbuck](https://github.com/jbuck) - Touch controls. +- [jbuck](https://github.com/jbuck) +- [cykod](https://github.com/cykod) +- [dougireton](https://github.com/dougireton) +- [awirick](https://github.com/awirick) +- Daniel Knittl-Frank ## License From e3d877601b273cc16ef6850b4e118d2a6d9f4b96 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Mon, 31 Oct 2011 23:18:50 +0800 Subject: [PATCH 071/169] Don't completely screw extensions when deck.change is prevented --- core/deck.core.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/core/deck.core.js b/core/deck.core.js index f26d58a4..70b89a43 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -255,7 +255,11 @@ that use the API provided by core. if (typeof index != 'number' || index < 0 || index >= slides.length) return; $d.trigger(e, [current, index]); - if (!e.isDefaultPrevented()) { + if (e.isDefaultPrevented()) { + /* Trigger the event again and undo the damage done by extensions. */ + $d.trigger(events.change, [index, current]); + } + else { current = index; updateStates(); } From 84b3ff39402eccd8a8a26f95f3c935c5d33c34b6 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 1 Nov 2011 16:43:31 +0800 Subject: [PATCH 072/169] Put checks in on init to deal with empty decks, fixes #51 --- core/deck.core.js | 4 +++- extensions/hash/deck.hash.js | 9 ++++++--- test/fixtures/empty.html | 19 +++++++++++++++++++ test/spec.core.js | 11 +++++++++++ 4 files changed, 39 insertions(+), 4 deletions(-) create mode 100644 test/fixtures/empty.html diff --git a/core/deck.core.js b/core/deck.core.js index 70b89a43..67b5572e 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -233,7 +233,9 @@ that use the API provided by core. }); }); - updateStates(); + if (slides.length) { + updateStates(); + } // Show deck again now that slides are in place $container.removeClass(options.classes.loading); diff --git a/extensions/hash/deck.hash.js b/extensions/hash/deck.hash.js index d67f343f..a4cb7f70 100644 --- a/extensions/hash/deck.hash.js +++ b/extensions/hash/deck.hash.js @@ -65,9 +65,10 @@ slide. $d.bind('deck.init', function() { var opts = $[deck]('getOptions'); - $internals = $(); + $internals = $(), + slides = $[deck]('getSlides'); - $.each($[deck]('getSlides'), function(i, $el) { + $.each(slides, function(i, $el) { var hash; /* Hand out ids to the unfortunate slides born without them */ @@ -96,7 +97,9 @@ slide. } /* Set up first id container state class */ - $[deck]('getContainer').addClass(opts.classes.onPrefix + $[deck]('getSlide').attr('id')); + if (slides.length) { + $[deck]('getContainer').addClass(opts.classes.onPrefix + $[deck]('getSlide').attr('id')); + }; }) /* Update permalink, address bar, and state class on a slide change */ .bind('deck.change', function(e, from, to) { diff --git a/test/fixtures/empty.html b/test/fixtures/empty.html new file mode 100644 index 00000000..d669ac59 --- /dev/null +++ b/test/fixtures/empty.html @@ -0,0 +1,19 @@ +
+ Previous + Next + +

+ + / + +

+ +
+ + + +
+ + # + Internal Test Link +
\ No newline at end of file diff --git a/test/spec.core.js b/test/spec.core.js index e6ac1da0..0d527416 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -415,4 +415,15 @@ describe('Deck JS', function() { expect($.deck('getSlide').find('iframe').data('src')).toBeUndefined(); }); }); + + describe('empty deck', function() { + beforeEach(function() { + loadFixtures('empty.html'); + $.deck('.slide'); + }); + + describe('getSlide()', function() { + it('should not error on init', $.noop); + }); + }); }); From 025ed343b3695d4f7aeb2009a2eaa9c693a7049c Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 1 Nov 2011 18:51:32 +0800 Subject: [PATCH 073/169] Fix broken menu events that came with replaceWith --- extensions/menu/deck.menu.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/extensions/menu/deck.menu.js b/extensions/menu/deck.menu.js index fc94da09..9534cea1 100644 --- a/extensions/menu/deck.menu.js +++ b/extensions/menu/deck.menu.js @@ -13,8 +13,7 @@ on the deck container. */ (function($, deck, undefined) { var $d = $(document), - rootSlides, // Array of top level slides - $placeholder; // Holds the place of the deck container during detachment + rootSlides; // Array of top level slides /* Extends defaults/options. @@ -54,7 +53,8 @@ on the deck container. var $c = $[deck]('getContainer'); // Detaching for this big style change for performance (no transitions!) - $c.replaceWith($placeholder); + $c.after($placeholder); + $c.detach(); $c.addClass($[deck]('getOptions').classes.menu); /* Forced to do this in JS until CSS learns second-grade math. Save old @@ -83,7 +83,8 @@ on the deck container. $[deck]('extend', 'hideMenu', function() { var $c = $[deck]('getContainer'); - $c.replaceWith($placeholder); + $c.after($placeholder); + $c.detach(); $c.removeClass($[deck]('getOptions').classes.menu); /* Restore old style value */ @@ -124,7 +125,7 @@ on the deck container. }).join(', '); // Create placeholder element - $placeholder = $('<' + $[deck]('getContainer').get(0).tagName + '>'); + $placeholder = $('
'); // Build top level slides array rootSlides = []; From 5037d04958ed4304070058dbe06b63fdd928c4e0 Mon Sep 17 00:00:00 2001 From: Daniel Knittl-Frank Date: Mon, 17 Oct 2011 09:35:32 +0200 Subject: [PATCH 074/169] Apply css transformations to hgroup elements. Allow users to write 'sub headings' (useful on title slides).

transformations are reset and
is shifted instead to the vertical center of the slide. Signed-off-by: Daniel Knittl-Frank --- core/deck.core.css | 13 +++++++++++++ core/deck.core.scss | 13 +++++++++++++ 2 files changed, 26 insertions(+) diff --git a/core/deck.core.css b/core/deck.core.css index e7a7214e..ab786361 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -190,10 +190,14 @@ html { } .slide h1 { font-size: 4.5em; +} +.deck-container hgroup, +.deck-container h1 { font-weight: bold; text-align: center; padding-top: 1em; } +.csstransforms .slide hgroup, .csstransforms .slide h1 { padding: 0 48px; position: absolute; @@ -206,6 +210,15 @@ html { -o-transform: translate(0, -50%); transform: translate(0, -50%); } +.csstransforms .slide hgroup h1 { + position:relative; + top:auto; + -webkit-transform: none; + -moz-transform: none; + -ms-transform: none; + -o-transform: none; + transform: none; +} .slide h2 { font-size: 2.25em; font-weight: bold; diff --git a/core/deck.core.scss b/core/deck.core.scss index 872ebde8..cdf8a413 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -237,6 +237,9 @@ html { h1 { font-size:4.5em; + } + + hgroup, h1 { font-weight:bold; text-align:center; padding-top:1em; @@ -255,6 +258,16 @@ html { } } + hgroup h1 { + position:relative; + top:auto; + -webkit-transform: none; + -moz-transform: none; + -ms-transform: none; + -o-transform: none; + transform: none; + } + h2 { font-size:2.25em; font-weight:bold; From 5dd1b7d9c8853556e8affb6e838b1e2433a8972b Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 5 Nov 2011 12:30:46 +0800 Subject: [PATCH 075/169] Update jQuery to 1.7 + adjust for deprecations --- extensions/goto/deck.goto.js | 2 +- introduction/index.html | 4 ++-- jquery-1.6.4.min.js | 4 ---- jquery-1.7.min.js | 4 ++++ test/index.html | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) delete mode 100644 jquery-1.6.4.min.js create mode 100644 jquery-1.7.min.js diff --git a/extensions/goto/deck.goto.js b/extensions/goto/deck.goto.js index 10c570fd..78e368f4 100644 --- a/extensions/goto/deck.goto.js +++ b/extensions/goto/deck.goto.js @@ -99,7 +99,7 @@ the deck container. var $field = ($($[deck]('getOptions').selectors.gotoInput)), i = parseInt($field.val(), 10); - if (!($.isNaN(i) || i < 1 || i > $[deck]('getSlides').length)) { + if (!(isNaN(i) || i < 1 || i > $[deck]('getSlides').length)) { $[deck]('go', i - 1); $[deck]('hideGoTo'); $field.val(''); diff --git a/introduction/index.html b/introduction/index.html index fefd9084..e69ec0c4 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -202,8 +202,8 @@

Digging Deeper

- - + + diff --git a/jquery-1.6.4.min.js b/jquery-1.6.4.min.js deleted file mode 100644 index 628ed9b3..00000000 --- a/jquery-1.6.4.min.js +++ /dev/null @@ -1,4 +0,0 @@ -/*! jQuery v1.6.4 http://jquery.com/ | http://jquery.org/license */ -(function(a,b){function cu(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cr(a){if(!cg[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){ch||(ch=c.createElement("iframe"),ch.frameBorder=ch.width=ch.height=0),b.appendChild(ch);if(!ci||!ch.createElement)ci=(ch.contentWindow||ch.contentDocument).document,ci.write((c.compatMode==="CSS1Compat"?"":"")+""),ci.close();d=ci.createElement(a),ci.body.appendChild(d),e=f.css(d,"display"),b.removeChild(ch)}cg[a]=e}return cg[a]}function cq(a,b){var c={};f.each(cm.concat.apply([],cm.slice(0,b)),function(){c[this]=a});return c}function cp(){cn=b}function co(){setTimeout(cp,0);return cn=f.now()}function cf(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ce(){try{return new a.XMLHttpRequest}catch(b){}}function b$(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;g0){c!=="border"&&f.each(e,function(){c||(d-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?d+=parseFloat(f.css(a,c+this))||0:d-=parseFloat(f.css(a,"border"+this+"Width"))||0});return d+"px"}d=bv(a,b,b);if(d<0||d==null)d=a.style[b]||0;d=parseFloat(d)||0,c&&f.each(e,function(){d+=parseFloat(f.css(a,"padding"+this))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+this+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+this))||0)});return d+"px"}function bl(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(bd,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bk(a){f.nodeName(a,"input")?bj(a):"getElementsByTagName"in a&&f.grep(a.getElementsByTagName("input"),bj)}function bj(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bi(a){return"getElementsByTagName"in a?a.getElementsByTagName("*"):"querySelectorAll"in a?a.querySelectorAll("*"):[]}function bh(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bg(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c=f.expando,d=f.data(a),e=f.data(b,d);if(d=d[c]){var g=d.events;e=e[c]=f.extend({},d);if(g){delete e.handle,e.events={};for(var h in g)for(var i=0,j=g[h].length;i=0===c})}function U(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function M(a,b){return(a&&a!=="*"?a+".":"")+b.replace(y,"`").replace(z,"&")}function L(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 J(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 D(){return!0}function C(){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").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 K(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(K,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=/-([a-z]|[0-9])/ig,x=/^-ms-/,y=function(a,b){return(b+"").toUpperCase()},z=d.userAgent,A,B,C,D=Object.prototype.toString,E=Object.prototype.hasOwnProperty,F=Array.prototype.push,G=Array.prototype.slice,H=String.prototype.trim,I=Array.prototype.indexOf,J={};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.4",length:0,size:function(){return this.length},toArray:function(){return G.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)?F.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(),B.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(G.apply(this,arguments),"slice",G.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:F,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;B.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!B){B=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",C,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",C),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&K()}}},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):J[D.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!E.call(a,"constructor")&&!E.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||E.call(a,d)},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(c){var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(x,"ms-").replace(w,y)},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{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=a.getElementsByTagName("input")[0],k={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:i.value==="on",optSelected:h.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,k.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,k.optDisabled=!h.disabled;try{delete a.test}catch(v){k.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function(){k.noCloneEvent=!1}),a.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),k.radioValue=i.value==="t",i.setAttribute("checked","checked"),a.appendChild(i),l=c.createDocumentFragment(),l.appendChild(a.firstChild),k.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",m=c.getElementsByTagName("body")[0],o=c.createElement(m?"div":"body"),p={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"},m&&f.extend(p,{position:"absolute",left:"-1000px",top:"-1000px"});for(t in p)o.style[t]=p[t];o.appendChild(a),n=m||b,n.insertBefore(o,n.firstChild),k.appendChecked=i.checked,k.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,k.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="
",k.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="
t
",q=a.getElementsByTagName("td"),u=q[0].offsetHeight===0,q[0].style.display="",q[1].style.display="none",k.reliableHiddenOffsets=u&&q[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",a.appendChild(j),k.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0),o.innerHTML="",n.removeChild(o);if(a.attachEvent)for(t in{submit:1,change:1,focusin:1})s="on"+t,u=s in a,u||(a.setAttribute(s,"return;"),u=typeof a[s]=="function"),k[t+"Bubbles"]=u;o=l=g=h=m=j=a=i=null;return k}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([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,h,i=f.expando,j=typeof c=="string",k=a.nodeType,l=k?f.cache:a,m=k?a[f.expando]:a[f.expando]&&f.expando;if((!m||e&&m&&l[m]&&!l[m][i])&&j&&d===b)return;m||(k?a[f.expando]=m=++f.uuid:m=f.expando),l[m]||(l[m]={},k||(l[m].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?l[m][i]=f.extend(l[m][i],c):l[m]=f.extend(l[m],c);g=l[m],e&&(g[i]||(g[i]={}),g=g[i]),d!==b&&(g[f.camelCase(c)]=d);if(c==="events"&&!g[c])return g[i]&&g[i].events;j?(h=g[c],h==null&&(h=g[f.camelCase(c)])):h=g;return h}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e=f.expando,g=a.nodeType,h=g?f.cache:a,i=g?a[f.expando]:f.expando;if(!h[i])return;if(b){d=c?h[i][e]:h[i];if(d){d[b]||(b=f.camelCase(b)),delete d[b];if(!l(d))return}}if(c){delete h[i][e];if(!l(h[i]))return}var j=h[i][e];f.support.deleteExpando||!h.setInterval?delete h[i]:h[i]=null,j?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=j):g&&(f.support.deleteExpando?delete a[f.expando]:a.removeAttribute?a.removeAttribute(f.expando):a[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;d=e.value;return typeof d=="string"?d.replace(p,""):d==null?"":d}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);j&&(c=f.attrFix[c]||c,i=f.attrHooks[c],i||(t.test(c)?i=v:u&&(i=u)));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&&(h=i.get(a,c))!==null)return h;h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){var c;a.nodeType===1&&(b=f.attrFix[b]||b,f.attr(a,b,""),a.removeAttribute(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}}},value:{get:function(a,b){if(u&&f.nodeName(a,"button"))return u.get(a,b);return b in a?a.value:null},set:function(a,b,c){if(u&&f.nodeName(a,"button"))return u.set(a,b,c);a.value=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);i&&(c=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))!==null?g:a[c]},propHooks:{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}}}}),f.attrHooks.tabIndex=f.propHooks.tabIndex,v={get:function(a,c){var d;return f.prop(a,c)===!0||(d=a.getAttributeNode(c))&&d.nodeValue!==!1?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]=!0),a.setAttribute(c,c.toLowerCase()));return c}},f.support.getSetAttribute||(u=f.valHooks.button={get:function(a,c){var d;d=a.getAttributeNode(c);return d&&d.nodeValue!==""?d.nodeValue:b},set:function(a,b,d){var e=a.getAttributeNode(d);e||(e=c.createAttribute(d),a.setAttributeNode(e));return e.nodeValue=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);return null}})),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 w=/\.(.*)$/,x=/^(?:textarea|input|select)$/i,y=/\./g,z=/ /g,A=/[^\w\s.|`]/g,B=function(a){return a.replace(A,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=C;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=C);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(),B).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!=null?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},I=function(c){var d=c.target,e,g;if(!!x.test(d.nodeName)&&!d.readOnly){e=f._data(d,"_change_data"),g=H(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:I,beforedeactivate:I,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&I.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")&&I.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",H(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in G)f.event.add(this,c+".specialChange",G[c]);return x.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return x.test(this.nodeName)}},G=f.event.special.change.filters,G.focus=G.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=S.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)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));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(U(c[0])||U(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=R.call(arguments);N.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!T[a]?f.unique(e):e,(this.length>1||P.test(d))&&O.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 W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/",""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]};be.optgroup=be.option,be.tbody=be.tfoot=be.colgroup=be.caption=be.thead,be.th=be.td,f.support.htmlSerialize||(be._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(W,""):null;if(typeof a=="string"&&!ba.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!be[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$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)){bh(a,d),e=bi(a),g=bi(d);for(h=0;e[h];++h)g[h]&&bh(e[h],g[h])}if(b){bg(a,d);if(c){e=bi(a),g=bi(d);for(h=0;e[h];++h)bg(e[h],g[h])}}e=g=null;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(!_.test(k))k=b.createTextNode(k);else{k=k.replace(Y,"<$1>");var l=(Z.exec(k)||["",""])[1].toLowerCase(),m=be[l]||be._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=$.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&&X.test(k)&&o.insertBefore(b.createTextNode(X.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 bn.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,e=f.isNaN(b)?"":"alpha(opacity="+b*100+")",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bm,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bm.test(g)?g.replace(bm,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=bv(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bw=function(a,c){var d,e,g;c=c.replace(bo,"-$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&&(bx=function(a,b){var c,d=a.currentStyle&&a.currentStyle[b],e=a.runtimeStyle&&a.runtimeStyle[b],f=a.style;!bp.test(d)&&bq.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}),bv=bw||bx,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 bz=/%20/g,bA=/\[\]$/,bB=/\r?\n/g,bC=/#.*$/,bD=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bE=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bF=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bG=/^(?:GET|HEAD)$/,bH=/^\/\//,bI=/\?/,bJ=/)<[^<]*)*<\/script>/gi,bK=/^(?:select|textarea)/i,bL=/\s+/,bM=/([?&])_=[^&]*/,bN=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bO=f.fn.load,bP={},bQ={},bR,bS,bT=["*/"]+["*"];try{bR=e.href}catch(bU){bR=c.createElement("a"),bR.href="",bR=bR.href}bS=bN.exec(bR.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bO)return bO.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(bJ,"")).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||bK.test(this.nodeName)||bE.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(bB,"\r\n")}}):{name:b.name,value:c.replace(bB,"\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?bX(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),bX(a,b);return a},ajaxSettings:{url:bR,isLocal:bF.test(bS[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","*":bT},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},flatOptions:{context:!0,url:!0}},ajaxPrefilter:bV(bP),ajaxTransport:bV(bQ),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>0?4:0;var o,r,u,w=c,x=l?bZ(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=b$(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.resolveWith(e,[v,w]),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=bD.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(bC,"").replace(bH,bS[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bL),d.crossDomain==null&&(r=bN.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bS[1]&&r[2]==bS[2]&&(r[3]||(r[1]==="http:"?80:443))==(bS[3]||(bS[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),bW(bP,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bG.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bI.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bM,"$1_="+x);d.url=y+(y===d.url?(bI.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]!=="*"?", "+bT+"; 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=bW(bQ,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){s<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)bY(g,a[g],c,e);return d.join("&").replace(bz,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var b_=f.now(),ca=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+b_++}}),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&&(ca.test(b.url)||e&&ca.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(ca,l),b.url===j&&(e&&(k=k.replace(ca,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 cb=a.ActiveXObject?function(){for(var a in cd)cd[a](0,1)}:!1,cc=0,cd;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ce()||cf()}:ce,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,cb&&delete cd[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=++cc,cb&&(cd||(cd={},f(a).unload(cb)),cd[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cg={},ch,ci,cj=/^(?:toggle|show|hide)$/,ck=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cl,cm=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cn;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cq("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=ct.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&&!ct.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=cu(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=cu(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(){var a=this[0];return a&&a.style?parseFloat(f.css(a,d,"padding")):null},f.fn["outer"+c]=function(a){var b=this[0];return b&&b.style?parseFloat(f.css(b,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],h=e.document.body;return e.document.compatMode==="CSS1Compat"&&g||h&&h["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 i=f.css(e,d),j=parseFloat(i);return f.isNaN(j)?i:j}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f})(window); \ No newline at end of file diff --git a/jquery-1.7.min.js b/jquery-1.7.min.js new file mode 100644 index 00000000..3ca5e0f5 --- /dev/null +++ b/jquery-1.7.min.js @@ -0,0 +1,4 @@ +/*! jQuery v1.7 jquery.com | jquery.org/license */ +(function(a,b){function cA(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cx(a){if(!cm[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){cn||(cn=c.createElement("iframe"),cn.frameBorder=cn.width=cn.height=0),b.appendChild(cn);if(!co||!cn.createElement)co=(cn.contentWindow||cn.contentDocument).document,co.write((c.compatMode==="CSS1Compat"?"":"")+""),co.close();d=co.createElement(a),co.body.appendChild(d),e=f.css(d,"display"),b.removeChild(cn)}cm[a]=e}return cm[a]}function cw(a,b){var c={};f.each(cs.concat.apply([],cs.slice(0,b)),function(){c[this]=a});return c}function cv(){ct=b}function cu(){setTimeout(cv,0);return ct=f.now()}function cl(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ck(){try{return new a.XMLHttpRequest}catch(b){}}function ce(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;g0){c!=="border"&&f.each(e,function(){c||(d-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?d+=parseFloat(f.css(a,c+this))||0:d-=parseFloat(f.css(a,"border"+this+"Width"))||0});return d+"px"}d=bB(a,b,b);if(d<0||d==null)d=a.style[b]||0;d=parseFloat(d)||0,c&&f.each(e,function(){d+=parseFloat(f.css(a,"padding"+this))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+this+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+this))||0)});return d+"px"}function br(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(bi,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bq(a){var b=(a.nodeName||"").toLowerCase();b==="input"?bp(a):b!=="script"&&typeof a.getElementsByTagName!="undefined"&&f.grep(a.getElementsByTagName("input"),bp)}function bp(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bo(a){return typeof a.getElementsByTagName!="undefined"?a.getElementsByTagName("*"):typeof a.querySelectorAll!="undefined"?a.querySelectorAll("*"):[]}function bn(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bm(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c,d,e,g=f._data(a),h=f._data(b,g),i=g.events;if(i){delete h.handle,h.events={};for(c in i)for(d=0,e=i[c].length;d=0===c})}function V(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function N(){return!0}function M(){return!1}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?parseFloat(d):j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c)[^>]*$|#([\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=/-([a-z]|[0-9])/ig,x=/^-ms-/,y=function(a,b){return(b+"").toUpperCase()},z=d.userAgent,A,B,C,D=Object.prototype.toString,E=Object.prototype.hasOwnProperty,F=Array.prototype.push,G=Array.prototype.slice,H=String.prototype.trim,I=Array.prototype.indexOf,J={};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.7",length:0,size:function(){return this.length},toArray:function(){return G.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)?F.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(),B.add(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(G.apply(this,arguments),"slice",G.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:F,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;B.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!B){B=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",C,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",C),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&K()}}},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},isNumeric:function(a){return a!=null&&m.test(a)&&!isNaN(a)},type:function(a){return a==null?String(a):J[D.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!E.call(a,"constructor")&&!E.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||E.call(a,d)},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(c){var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(x,"ms-").replace(w,y)},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?i.call(arguments,0):b,j.notifyWith(k,e)}}function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}var b=i.call(arguments,0),c=0,d=b.length,e=Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c
a",d=a.getElementsByTagName("*"),e=a.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=a.getElementsByTagName("input")[0],k={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,unknownElems:!!a.getElementsByTagName("nav").length,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:a.className!=="t",enctype:!!c.createElement("form").enctype,submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,k.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,k.optDisabled=!h.disabled;try{delete a.test}catch(v){k.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function(){k.noCloneEvent=!1}),a.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),k.radioValue=i.value==="t",i.setAttribute("checked","checked"),a.appendChild(i),l=c.createDocumentFragment(),l.appendChild(a.lastChild),k.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",m=c.getElementsByTagName("body")[0],o=c.createElement(m?"div":"body"),p={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"},m&&f.extend(p,{position:"absolute",left:"-999px",top:"-999px"});for(t in p)o.style[t]=p[t];o.appendChild(a),n=m||b,n.insertBefore(o,n.firstChild),k.appendChecked=i.checked,k.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,k.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="
",k.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="
t
",q=a.getElementsByTagName("td"),u=q[0].offsetHeight===0,q[0].style.display="",q[1].style.display="none",k.reliableHiddenOffsets=u&&q[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",a.appendChild(j),k.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0);if(a.attachEvent)for(t in{submit:1,change:1,focusin:1})s="on"+t,u=s in a,u||(a.setAttribute(s,"return;"),u=typeof a[s]=="function"),k[t+"Bubbles"]=u;f(function(){var a,b,d,e,g,h,i=1,j="position:absolute;top:0;left:0;width:1px;height:1px;margin:0;",l="visibility:hidden;border:0;",n="style='"+j+"border:5px solid #000;padding:0;'",p="
"+""+"
";m=c.getElementsByTagName("body")[0];!m||(a=c.createElement("div"),a.style.cssText=l+"width:0;height:0;position:static;top:0;margin-top:"+i+"px",m.insertBefore(a,m.firstChild),o=c.createElement("div"),o.style.cssText=j+l,o.innerHTML=p,a.appendChild(o),b=o.firstChild,d=b.firstChild,g=b.nextSibling.firstChild.firstChild,h={doesNotAddBorder:d.offsetTop!==5,doesAddBorderForTableAndCells:g.offsetTop===5},d.style.position="fixed",d.style.top="20px",h.fixedPosition=d.offsetTop===20||d.offsetTop===15,d.style.position=d.style.top="",b.style.overflow="hidden",b.style.position="relative",h.subtractsBorderForOverflowNotVisible=d.offsetTop===-5,h.doesNotIncludeMarginInBodyOffset=m.offsetTop!==i,m.removeChild(a),o=a=null,f.extend(k,h))}),o.innerHTML="",n.removeChild(o),o=l=g=h=m=j=a=i=null;return k}(),f.boxModel=f.support.boxModel;var j=/^(?:\{.*\}|\[.*\])$/,k=/([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&&!m(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[f.expando]:a[f.expando]&&f.expando,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[f.expando]=n=++f.uuid:n=f.expando),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d);if(o&&!h[c])return g.events;k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h;return i}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[f.expando]:f.expando;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)?b=b:b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" "));for(e=0,g=b.length;e-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];if(!arguments.length){if(g){c=f.valHooks[g.nodeName.toLowerCase()]||f.valHooks[g.type];if(c&&"get"in c&&(d=c.get(g,"value"))!==b)return d;d=g.value;return typeof d=="string"?d.replace(q,""):d==null?"":d}return b}e=f.isFunction(a);return this.each(function(d){var g=f(this),h;if(this.nodeType===1){e?h=a.call(this,d,g.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,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;c=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},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!a||j===3||j===8||j===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);if(!("getAttribute"in a))return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return b}if(h&&"set"in h&&i&&(g=h.set(a,d,c))!==b)return g;a.setAttribute(c,""+d);return d}if(h&&"get"in h&&i&&(g=h.get(a,c))!==null)return g;g=a.getAttribute(c);return g===null?b:g},removeAttr:function(a,b){var c,d,e,g,h=0;if(a.nodeType===1){d=(b||"").split(p),g=d.length;for(;h=0}})});var z=/\.(.*)$/,A=/^(?:textarea|input|select)$/i,B=/\./g,C=/ /g,D=/[^\w\s.|`]/g,E=/^([^\.]*)?(?:\.(.+))?$/,F=/\bhover(\.\S+)?/,G=/^key/,H=/^(?:mouse|contextmenu)|click/,I=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,J=function(a){var b=I.exec(a);b&& +(b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)"));return b},K=function(a,b){return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||a.id===b[2])&&(!b[3]||b[3].test(a.className))},L=function(a){return f.event.special.hover?a:a.replace(F,"mouseenter$1 mouseleave$1")};f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(!(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))){d.handler&&(p=d,d=p.handler),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.dispatch.apply(i.elem,arguments):b},i.elem=a),c=L(c).split(" ");for(k=0;k=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"",(g||!e)&&c.preventDefault();if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,n=null;for(m=e.parentNode;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;l=0:t===b&&(t=o[s]=r.quick?K(m,r.quick):f(m).is(s)),t&&q.push(r);q.length&&j.push({elem:m,matches:q})}d.length>e&&j.push({elem:this,matches:d.slice(e)});for(k=0;k0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),G.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),H.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function x(a,b,c,e,f,g){for(var h=0,i=e.length;h0){k=j;break}}j=j[a]}e[h]=k}}}function w(a,b,c,e,f,g){for(var h=0,i=e.length;h+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){i=!1;return 0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length===1&&(w[0]==="~"||w[0]==="+")&&d.parentNode?d.parentNode:d,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);l&&(m(l,h,e,f),m.uniqueSort(e));return e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.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(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.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]&&m.error(a[0]);a[0]=e++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),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]=m(b[3],null,null,c);else{var g=m.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(o.match.POS.test(b[0])||o.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!!m(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=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([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&&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=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null: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=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));var s=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(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.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:[]}},o.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&&(o.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")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[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}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.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 m(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;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h0)for(h=g;h=0:f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h=1;while(g&&g.ownerDocument&&g!==b){for(d=0;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)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));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(V(c[0])||V(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=S.call(arguments);O.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!U[a]?f.unique(e):e,(this.length>1||Q.test(d))&&P.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="abbr article aside audio canvas datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video",Z=/ jQuery\d+="(?:\d+|null)"/g,$=/^\s+/,_=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,ba=/<([\w:]+)/,bb=/",""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]},bk=X(c);bj.optgroup=bj.option,bj.tbody=bj.tfoot=bj.colgroup=bj.caption=bj.thead,bj.th=bj.td,f.support.htmlSerialize||(bj._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(Z,""):null;if(typeof a=="string"&&!bd.test(a)&&(f.support.leadingWhitespace||!$.test(a))&&!bj[(ba.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)){bn(a,d),e=bo(a),g=bo(d);for(h=0;e[h];++h)g[h]&&bn(e[h],g[h])}if(b){bm(a,d);if(c){e=bo(a),g=bo(d);for(h=0;e[h];++h)bm(e[h],g[h])}}e=g=null;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(!bc.test(k))k=b.createTextNode(k);else{k=k.replace(_,"<$1>");var l=(ba.exec(k)||["",""])[1].toLowerCase(),m=bj[l]||bj._default,n=m[0],o=b.createElement("div");b===c?bk.appendChild(o):X(b).appendChild(o),o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=bb.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&&$.test(k)&&o.insertBefore(b.createTextNode($.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 bt.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,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bs,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bs.test(g)?g.replace(bs,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=bB(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bC=function(a,c){var d,e,g;c=c.replace(bu,"-$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&&(bD=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;f===null&&g&&(e=g[b])&&(f=e),!bv.test(f)&&bw.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f||0,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d));return f===""?"auto":f}),bB=bC||bD,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&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bF=/%20/g,bG=/\[\]$/,bH=/\r?\n/g,bI=/#.*$/,bJ=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bK=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bL=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bM=/^(?:GET|HEAD)$/,bN=/^\/\//,bO=/\?/,bP=/)<[^<]*)*<\/script>/gi,bQ=/^(?:select|textarea)/i,bR=/\s+/,bS=/([?&])_=[^&]*/,bT=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bU=f.fn.load,bV={},bW={},bX,bY,bZ=["*/"]+["*"];try{bX=e.href}catch(b$){bX=c.createElement("a"),bX.href="",bX=bX.href}bY=bT.exec(bX.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bU)return bU.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(bP,"")).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||bQ.test(this.nodeName)||bK.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(bH,"\r\n")}}):{name:b.name,value:c.replace(bH,"\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?cb(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),cb(a,b);return a},ajaxSettings:{url:bX,isLocal:bL.test(bY[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","*":bZ},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},flatOptions:{context:!0,url:!0}},ajaxPrefilter:b_(bV),ajaxTransport:b_(bW),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>0?4:0;var o,r,u,w=c,x=l?cd(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=ce(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),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.Callbacks("once memory"),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=bJ.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.add,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(bI,"").replace(bN,bY[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bR),d.crossDomain==null&&(r=bT.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bY[1]&&r[2]==bY[2]&&(r[3]||(r[1]==="http:"?80:443))==(bY[3]||(bY[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),ca(bV,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bM.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bO.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bS,"$1_="+x);d.url=y+(y===d.url?(bO.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]!=="*"?", "+bZ+"; 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=ca(bW,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){s<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)cc(g,a[g],c,e);return d.join("&").replace(bF,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cf=f.now(),cg=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cf++}}),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&&(cg.test(b.url)||e&&cg.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(cg,l),b.url===j&&(e&&(k=k.replace(cg,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 ch=a.ActiveXObject?function(){for(var a in cj)cj[a](0,1)}:!1,ci=0,cj;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ck()||cl()}:ck,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,ch&&delete cj[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=++ci,ch&&(cj||(cj={},f(a).unload(ch)),cj[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cm={},cn,co,cp=/^(?:toggle|show|hide)$/,cq=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cr,cs=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],ct;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cw("show",3),a,b,c);for(var g=0,h=this.length;g=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c-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=cz.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&&!cz.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=cA(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=cA(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(){var a=this[0];return a?a.style?parseFloat(f.css(a,d,"padding")):this[d]():null},f.fn["outer"+c]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,d,a?"margin":"border")):this[d]():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],h=e.document.body;return e.document.compatMode==="CSS1Compat"&&g||h&&h["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 i=f.css(e,d),j=parseFloat(i);return f.isNumeric(j)?j: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/test/index.html b/test/index.html index f5f8474b..a41e6998 100644 --- a/test/index.html +++ b/test/index.html @@ -7,7 +7,7 @@ - + From 546feec10c92525b905ef7200acc0c7f568b4ae6 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 5 Nov 2011 13:15:05 +0800 Subject: [PATCH 076/169] Comment rewording --- introduction/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/introduction/index.html b/introduction/index.html index e69ec0c4..29154184 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -201,7 +201,7 @@

Digging Deeper

# - + From 7f150a7e9ebe10e03de9f7d6c70829bd6c1f18df Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 5 Nov 2011 14:57:12 +0800 Subject: [PATCH 077/169] Extend .go to accept slide ids --- core/deck.core.js | 35 ++++++++++++++++++++++++++--------- test/spec.core.js | 11 ++++++++--- 2 files changed, 34 insertions(+), 12 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index 67b5572e..6fbeb5ce 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -245,24 +245,41 @@ that use the API provided by core. /* jQuery.deck('go', index) - index: integer + index: integer | string - Moves to the slide at the specified index. Index is 0-based, so - $.deck('go', 0); will move to the first slide. If index is out of bounds - or not a number the call is ignored. + Moves to the slide at the specified index if index is a number. Index is + 0-based, so $.deck('go', 0); will move to the first slide. If index is a + string this will move to the slide with the specified id. If index is out + of bounds or doesn't match a slide id the call is ignored. */ go: function(index) { - var e = $.Event(events.change); + var e = $.Event(events.change), + ndx; - if (typeof index != 'number' || index < 0 || index >= slides.length) return; + /* Number index, easy. */ + if (typeof index === 'number' && index >= 0 && index < slides.length) { + ndx = index; + } + /* Id string index, search for it and set integer index */ + else if (typeof index === 'string') { + $.each(slides, function(i, $slide) { + if ($slide.attr('id') === index) { + ndx = i; + return false; + } + }); + }; + + /* Out of bounds, id doesn't exist, illegal input, eject */ + if (typeof ndx === 'undefined') return; - $d.trigger(e, [current, index]); + $d.trigger(e, [current, ndx]); if (e.isDefaultPrevented()) { /* Trigger the event again and undo the damage done by extensions. */ - $d.trigger(events.change, [index, current]); + $d.trigger(events.change, [ndx, current]); } else { - current = index; + current = ndx; updateStates(); } }, diff --git a/test/spec.core.js b/test/spec.core.js index 0d527416..8ac4bed8 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -42,15 +42,20 @@ describe('Deck JS', function() { expect($.deck('getSlide')).toHaveClass('slide4'); }); - it('should go nowhere if i is NaN', function() { - $.deck('go', 'foobar'); - expect($.deck('getSlide')).toHaveClass('slide1'); + it('should go to the slide with specified id', function() { + $.deck('go', 'custom-id'); + expect($.deck('getSlide')).toHaveId('custom-id'); }); it('should go nowhere if i is out of bounds', function() { $.deck('go', 5); expect($.deck('getSlide')).toHaveClass('slide1'); }); + + it('should go nowhere if id does not exist', function() { + $.deck('go', 'i-dont-exist'); + expect($.deck('getSlide')).toHaveClass('slide1'); + }); }); describe('next()', function() { From 1b55cd8e487d5433b3e8abaf7e214a75fca50c89 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 5 Nov 2011 17:06:26 +0800 Subject: [PATCH 078/169] Update goto form to accept ids + add datalist --- extensions/goto/deck.goto.css | 4 +-- extensions/goto/deck.goto.html | 3 ++- extensions/goto/deck.goto.js | 46 +++++++++++++++++++++++----------- extensions/goto/deck.goto.scss | 4 +-- introduction/index.html | 5 ++-- test/fixtures/standard.html | 3 ++- test/index.html | 2 +- test/spec.goto.js | 26 +++++++++++++------ 8 files changed, 62 insertions(+), 31 deletions(-) diff --git a/extensions/goto/deck.goto.css b/extensions/goto/deck.goto.css index 4d04dd29..108e4f9c 100644 --- a/extensions/goto/deck.goto.css +++ b/extensions/goto/deck.goto.css @@ -4,7 +4,7 @@ bottom: 10px; left: 50%; height: 1.75em; - margin: 0 0 0 -7.125em; + margin: 0 0 0 -9.125em; line-height: 1.75em; padding: 0.625em; display: none; @@ -29,7 +29,7 @@ } #goto-slide { - width: 4.375em; + width: 8.375em; margin: 0 0.625em; height: 1.4375em; } diff --git a/extensions/goto/deck.goto.html b/extensions/goto/deck.goto.html index da960669..e3b6a186 100644 --- a/extensions/goto/deck.goto.html +++ b/extensions/goto/deck.goto.html @@ -1,6 +1,7 @@
- + + \ No newline at end of file diff --git a/extensions/goto/deck.goto.js b/extensions/goto/deck.goto.js index 78e368f4..21ec43ce 100644 --- a/extensions/goto/deck.goto.js +++ b/extensions/goto/deck.goto.js @@ -8,7 +8,7 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt /* This module adds the necessary methods and key bindings to show and hide a form -for jumping to any slide number in the deck (and processes that form +for jumping to any slide number/id in the deck (and processes that form accordingly). The form-showing state is indicated by the presence of a class on the deck container. */ @@ -22,18 +22,23 @@ the deck container. This class is added to the deck container when showing the Go To Slide form. + options.selectors.gotoDatalist + The element that matches this selector is the datalist element that will + be populated with options for each of the slide ids. In browsers that + support the datalist element, this provides a drop list of slide ids to + aid the user in selecting a slide. + options.selectors.gotoForm The element that matches this selector is the form that is submitted - when a user hits enter after typing a slide number in the gotoInput + when a user hits enter after typing a slide number/id in the gotoInput element. options.selectors.gotoInput The element that matches this selector is the text input field for - entering a slide number in the Go To Slide form. + entering a slide number/id in the Go To Slide form. options.keys.goto - The numeric keycode used to toggle between showing and hiding the Go To - Slide form. + The numeric keycode used to show the Go To Slide form. */ $.extend(true, $[deck].defaults, { classes: { @@ -41,6 +46,7 @@ the deck container. }, selectors: { + gotoDatalist: '#goto-datalist', gotoForm: '.goto-form', gotoInput: '#goto-slide' }, @@ -68,8 +74,8 @@ the deck container. option from the deck container. */ $[deck]('extend', 'hideGoTo', function() { - $[deck]('getContainer').removeClass($[deck]('getOptions').classes.goto); $($[deck]('getOptions').selectors.gotoInput).blur(); + $[deck]('getContainer').removeClass($[deck]('getOptions').classes.goto); }); /* @@ -82,33 +88,43 @@ the deck container. }); $d.bind('deck.init', function() { + var opts = $[deck]('getOptions'), + $datalist = $(opts.selectors.gotoDatalist); + // Bind key events $d.unbind('keydown.deckgoto').bind('keydown.deckgoto', function(e) { var key = $[deck]('getOptions').keys.goto; - if (e.which === key ||$.inArray(e.which, key) > -1) { + if (e.which === key || $.inArray(e.which, key) > -1) { e.preventDefault(); $[deck]('toggleGoTo'); } }); + /* Populate datalist */ + $.each($[deck]('getSlides'), function(i, $slide) { + var id = $slide.attr('id'); + + if (id) { + $datalist.append('
-
+
diff --git a/test/spec.goto.js b/test/spec.goto.js index b96bdc68..f78017eb 100644 --- a/test/spec.goto.js +++ b/test/spec.goto.js @@ -116,4 +116,18 @@ describe('Deck JS Quick Go-To', function() { expect($(defaults.selectors.container)).not.toHaveClass(defaults.classes.goto); }); }); + + describe('countNested false', function() { + it('should ignore nested slides when given a slide number', function() { + loadFixtures('nesteds.html'); + $.deck('.slide', { + countNested: false + }); + + $.deck('showGoTo'); + $(defaults.selectors.gotoInput).val('4'); + $(defaults.selectors.gotoForm).submit(); + expect($.deck('getSlide')).toHaveId('after'); + }); + }); }); \ No newline at end of file From 6118e3357a476e9831b4354582cf7d5c86167982 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Wed, 11 Jan 2012 13:24:38 -0800 Subject: [PATCH 088/169] Fix case for #58 where slide number entered is higher than countNested total but in legal range of actual slide count --- extensions/goto/deck.goto.js | 1 + test/spec.goto.js | 15 ++++++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/extensions/goto/deck.goto.js b/extensions/goto/deck.goto.js index ad79f825..eedba10b 100644 --- a/extensions/goto/deck.goto.js +++ b/extensions/goto/deck.goto.js @@ -143,6 +143,7 @@ the deck container. ndx = parseInt($field.val(), 10); if (!$[deck]('getOptions').countNested) { + if (ndx >= rootCounter) return false; $.each($[deck]('getSlides'), function(i, $slide) { if ($slide.data('rootIndex') === ndx) { ndx = i + 1; diff --git a/test/spec.goto.js b/test/spec.goto.js index f78017eb..391d80c7 100644 --- a/test/spec.goto.js +++ b/test/spec.goto.js @@ -118,16 +118,25 @@ describe('Deck JS Quick Go-To', function() { }); describe('countNested false', function() { - it('should ignore nested slides when given a slide number', function() { - loadFixtures('nesteds.html'); + beforeEach(function() { + loadFixtures('nesteds.html'); $.deck('.slide', { countNested: false }); - $.deck('showGoTo'); + }); + + it('should ignore nested slides when given a slide number', function() { $(defaults.selectors.gotoInput).val('4'); $(defaults.selectors.gotoForm).submit(); expect($.deck('getSlide')).toHaveId('after'); }); + + it('should respect top side of new slide range', function() { + $.deck('go', 0); + $(defaults.selectors.gotoInput).val('6'); + $(defaults.selectors.gotoForm).submit(); + expect($.deck('getSlide')).toHaveId('slide-0'); + }); }); }); \ No newline at end of file From 927f6e4b1b4fb594d1393190716cc998e456b732 Mon Sep 17 00:00:00 2001 From: Alex Chaffee Date: Mon, 16 Jan 2012 13:26:07 -0800 Subject: [PATCH 089/169] scale extension scales each slide separately --- extensions/scale/deck.scale.css | 26 +++++------ extensions/scale/deck.scale.js | 75 ++++++++++++++++---------------- extensions/scale/deck.scale.scss | 14 +++--- 3 files changed, 59 insertions(+), 56 deletions(-) diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index ce1d088f..a8b4a943 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -1,16 +1,16 @@ -.csstransforms .deck-container.deck-scale { - width: auto; - -webkit-transform-origin: 50% 0; - -moz-transform-origin: 50% 0; - -o-transform-origin: 50% 0; - -ms-transform-origin: 50% 0; - transform-origin: 50% 0; +.csstransforms .deck-container.deck-scale section.slide { + width:auto; + -webkit-transform-origin: 50% 0; + -moz-transform-origin: 50% 0; + -o-transform-origin: 50% 0; + -ms-transform-origin: 50% 0; + transform-origin: 50% 0; } .csstransforms .deck-container.deck-scale.deck-menu { - width: 70%; - -webkit-transform: none !important; - -moz-transform: none !important; - -o-transform: none !important; - -ms-transform: none !important; - transform: none !important; + width:70%; + -webkit-transform:none !important; + -moz-transform:none !important; + -o-transform:none !important; + -ms-transform:none !important; + transform:none !important; } diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index e29366e9..74dc463c 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -22,7 +22,7 @@ works fine. $w = $(window), baseHeight, // Value to scale against timer, // Timeout id for debouncing - + /* Internal function to do all the dirty work of scaling the deck container. */ @@ -33,105 +33,106 @@ works fine. slides = $[deck]('getSlides'), scale, transform; - + // Don't scale if scaling disabled if (!$container.hasClass($[deck]('getOptions').classes.scale)) { scale = 1; } else { - // Use tallest slide as base height if not set manually + // Use window height as base height if not set manually baseHeight = obh ? obh : (function() { - var greatest = 0; - - $.each(slides, function(i, $slide) { - greatest = Math.max(greatest, $slide.outerHeight()); - }); - - return greatest; + var slop = 40; /* for padding */ + var windowHeight = $(window).height(); + return windowHeight - slop; })(); - - scale = height / baseHeight; } - - // Scale, but don't scale up - transform = scale >= 1 ? 'none' : 'scale(' + scale + ')'; - $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { - $container.css(prefix + 'Transform', transform); - }); - }; + + // Scale each slide down if necessary (but don't scale up) + $.each(slides, function(i, $slide) { + var slideHeight = $slide.innerHeight(); + var scale = baseHeight / slideHeight; + + if (scale < 1) { + transform = 'scale(' + scale + ')'; + $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { + $slide.css(prefix + 'Transform', transform); + }); + } + }); + } /* Extends defaults/options. - + options.classes.scale This class is added to the deck container when scaling is enabled. It is enabled by default when the module is included. - + options.keys.scale The numeric keycode used to toggle enabling and disabling scaling. - + options.baseHeight When baseheight is falsy, as it is by default, the deck is scaled in proportion to the height of the slides. You may instead specify a height, and the deck will be scaled against this height regardless of the actual content height. - + options.scaleDebounce Scaling on the browser resize event is debounced. This number is the threshold in milliseconds. You can learn more about debouncing here: http://unscriptable.com/index.php/2009/03/20/debouncing-javascript-methods/ - + */ $.extend(true, $[deck].defaults, { classes: { scale: 'deck-scale' }, - + keys: { scale: 83 // s }, - + baseHeight: null, scaleDebounce: 200 }); - + /* jQuery.deck('disableScale') - + Disables scaling and removes the scale class from the deck container. */ $[deck]('extend', 'disableScale', function() { $[deck]('getContainer').removeClass($[deck]('getOptions').classes.scale); scaleDeck(); }); - + /* jQuery.deck('enableScale') - + Enables scaling and adds the scale class to the deck container. */ $[deck]('extend', 'enableScale', function() { $[deck]('getContainer').addClass($[deck]('getOptions').classes.scale); scaleDeck(); }); - + /* jQuery.deck('toggleScale') - + Toggles between enabling and disabling scaling. */ $[deck]('extend', 'toggleScale', function() { var $c = $[deck]('getContainer'); $[deck]($c.hasClass($[deck]('getOptions').classes.scale) ? - 'disableScale' : 'enableScale'); + 'disableScale' : 'enableScale'); }); $d.bind('deck.init', function() { var opts = $[deck]('getOptions'); - + // Scaling enabled at start $[deck]('getContainer').addClass(opts.classes.scale); - + // Debounce the resize scaling $w.unbind('resize.deckscale').bind('resize.deckscale', function() { window.clearTimeout(timer); @@ -139,7 +140,7 @@ works fine. }) // Scale once on load, in case images or something change layout .unbind('load.deckscale').bind('load.deckscale', scaleDeck); - + // Bind key events $d.unbind('keydown.deckscale').bind('keydown.deckscale', function(e) { if (e.which === opts.keys.scale || $.inArray(e.which, opts.keys.scale) > -1) { @@ -147,7 +148,7 @@ works fine. e.preventDefault(); } }); - + // Scale once on init scaleDeck(); }); diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index 4b39f11e..e96d60c8 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -1,10 +1,12 @@ .csstransforms .deck-container.deck-scale { - width:auto; - -webkit-transform-origin: 50% 0; - -moz-transform-origin: 50% 0; - -o-transform-origin: 50% 0; - -ms-transform-origin: 50% 0; - transform-origin: 50% 0; + section.slide { + width:auto; + -webkit-transform-origin: 50% 0; + -moz-transform-origin: 50% 0; + -o-transform-origin: 50% 0; + -ms-transform-origin: 50% 0; + transform-origin: 50% 0; + } &.deck-menu { width:70%; From 7bde446f83409509896085187cd8cd77a538b8ac Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 28 Jan 2012 15:40:49 +0800 Subject: [PATCH 090/169] Fix menu + scale and move slop to CSS --- extensions/menu/deck.menu.css | 10 +++++----- extensions/menu/deck.menu.scss | 10 +++++----- extensions/scale/deck.scale.css | 26 +++++++++++--------------- extensions/scale/deck.scale.js | 4 +--- extensions/scale/deck.scale.scss | 17 ++++++----------- 5 files changed, 28 insertions(+), 39 deletions(-) diff --git a/extensions/menu/deck.menu.css b/extensions/menu/deck.menu.css index 3e885490..c664a3f8 100644 --- a/extensions/menu/deck.menu.css +++ b/extensions/menu/deck.menu.css @@ -17,11 +17,11 @@ padding: 0 0.5%; } .csstransforms .deck-menu > .slide { - -webkit-transform: scale(0.22); - -moz-transform: scale(0.22); - -o-transform: scale(0.22); - -ms-transform: scale(0.22); - transform: scale(0.22); + -webkit-transform: scale(0.22) !important; + -moz-transform: scale(0.22) !important; + -o-transform: scale(0.22) !important; + -ms-transform: scale(0.22) !important; + transform: scale(0.22) !important; -webkit-transform-origin: 0 0; -moz-transform-origin: 0 0; -o-transform-origin: 0 0; diff --git a/extensions/menu/deck.menu.scss b/extensions/menu/deck.menu.scss index 86385c49..0bd576d7 100755 --- a/extensions/menu/deck.menu.scss +++ b/extensions/menu/deck.menu.scss @@ -21,11 +21,11 @@ } .csstransforms & { - -webkit-transform:scale(.22); - -moz-transform:scale(.22); - -o-transform:scale(.22); - -ms-transform:scale(.22); - transform:scale(.22); + -webkit-transform:scale(.22) !important; + -moz-transform:scale(.22) !important; + -o-transform:scale(.22) !important; + -ms-transform:scale(.22) !important; + transform:scale(.22) !important; -webkit-transform-origin:0 0; -moz-transform-origin:0 0; -o-transform-origin:0 0; diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index a8b4a943..806b1e38 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -1,16 +1,12 @@ -.csstransforms .deck-container.deck-scale section.slide { - width:auto; - -webkit-transform-origin: 50% 0; - -moz-transform-origin: 50% 0; - -o-transform-origin: 50% 0; - -ms-transform-origin: 50% 0; - transform-origin: 50% 0; -} -.csstransforms .deck-container.deck-scale.deck-menu { - width:70%; - -webkit-transform:none !important; - -moz-transform:none !important; - -o-transform:none !important; - -ms-transform:none !important; - transform:none !important; +.csstransforms .deck-container.deck-scale:not(.deck-menu) section.slide { + -webkit-box-sizing: padding-box; + -moz-box-sizing: padding-box; + box-sizing: padding-box; + width: 100%; + padding-bottom: 20px; + -webkit-transform-origin: 50% 0; + -moz-transform-origin: 50% 0; + -o-transform-origin: 50% 0; + -ms-transform-origin: 50% 0; + transform-origin: 50% 0; } diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index 74dc463c..0c2eb6b6 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -41,9 +41,7 @@ works fine. else { // Use window height as base height if not set manually baseHeight = obh ? obh : (function() { - var slop = 40; /* for padding */ - var windowHeight = $(window).height(); - return windowHeight - slop; + return $(window).height(); })(); } diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index e96d60c8..c07f9359 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -1,19 +1,14 @@ -.csstransforms .deck-container.deck-scale { +.csstransforms .deck-container.deck-scale:not(.deck-menu) { section.slide { - width:auto; + -webkit-box-sizing: padding-box; + -moz-box-sizing: padding-box; + box-sizing: padding-box; + width:100%; + padding-bottom:20px; -webkit-transform-origin: 50% 0; -moz-transform-origin: 50% 0; -o-transform-origin: 50% 0; -ms-transform-origin: 50% 0; transform-origin: 50% 0; } - - &.deck-menu { - width:70%; - -webkit-transform:none !important; - -moz-transform:none !important; - -o-transform:none !important; - -ms-transform:none !important; - transform:none !important; - } } \ No newline at end of file From 27fcc87511a188cf62206e3380671d32a5996cc5 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 28 Jan 2012 15:56:29 +0800 Subject: [PATCH 091/169] Remove section specific tag from scale CSS --- extensions/scale/deck.scale.css | 2 +- extensions/scale/deck.scale.scss | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index 806b1e38..a5697300 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -1,4 +1,4 @@ -.csstransforms .deck-container.deck-scale:not(.deck-menu) section.slide { +.csstransforms .deck-container.deck-scale:not(.deck-menu) > .slide { -webkit-box-sizing: padding-box; -moz-box-sizing: padding-box; box-sizing: padding-box; diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index c07f9359..49ce32a5 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -1,5 +1,5 @@ .csstransforms .deck-container.deck-scale:not(.deck-menu) { - section.slide { + > .slide { -webkit-box-sizing: padding-box; -moz-box-sizing: padding-box; box-sizing: padding-box; From b206d9f223623918a62ed3df6763f5cd2ca1527c Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 28 Jan 2012 17:55:11 +0800 Subject: [PATCH 092/169] Switch scale to use a wrapping element around slide content --- extensions/scale/deck.scale.css | 13 +++++ extensions/scale/deck.scale.js | 87 ++++++++++++++++++++------------ extensions/scale/deck.scale.scss | 29 ++++++++--- 3 files changed, 89 insertions(+), 40 deletions(-) diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index a5697300..cf0b69ce 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -1,12 +1,25 @@ +.csstransforms .deck-container.deck-scale:not(.deck-menu) { + overflow: hidden; +} .csstransforms .deck-container.deck-scale:not(.deck-menu) > .slide { -webkit-box-sizing: padding-box; -moz-box-sizing: padding-box; box-sizing: padding-box; width: 100%; padding-bottom: 20px; +} +.csstransforms .deck-container.deck-scale:not(.deck-menu) > .slide > .deck-slide-scaler { -webkit-transform-origin: 50% 0; -moz-transform-origin: 50% 0; -o-transform-origin: 50% 0; -ms-transform-origin: 50% 0; transform-origin: 50% 0; } + +.csstransforms .deck-container.deck-menu .deck-slide-scaler { + -webkit-transform: none !important; + -moz-transform: none !important; + -o-transform: none !important; + -ms-transform: none !important; + transform: none !important; +} diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index 0c2eb6b6..630d92a8 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -1,6 +1,6 @@ /*! Deck JS - deck.scale -Copyright (c) 2011 Caleb Troughton +Copyright (c) 2011-2012 Caleb Troughton Dual licensed under the MIT license and GPL license. https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt @@ -22,42 +22,45 @@ works fine. $w = $(window), baseHeight, // Value to scale against timer, // Timeout id for debouncing + rootSlides, /* Internal function to do all the dirty work of scaling the deck container. */ scaleDeck = function() { - var obh = $[deck]('getOptions').baseHeight, + var opts = $[deck]('getOptions'), + obh = opts.baseHeight, $container = $[deck]('getContainer'), height = $w.height(), slides = $[deck]('getSlides'), scale, transform; - - // Don't scale if scaling disabled - if (!$container.hasClass($[deck]('getOptions').classes.scale)) { - scale = 1; - } - else { - // Use window height as base height if not set manually - baseHeight = obh ? obh : (function() { - return $(window).height(); - })(); - } + + // Use window height as base height if not set manually + baseHeight = obh ? obh : (function() { + return $(window).height(); + })(); // Scale each slide down if necessary (but don't scale up) - $.each(slides, function(i, $slide) { - var slideHeight = $slide.innerHeight(); - var scale = baseHeight / slideHeight; - - if (scale < 1) { - transform = 'scale(' + scale + ')'; - $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { - $slide.css(prefix + 'Transform', transform); - }); - } - }); - } + $.each(rootSlides, function(i, $slide) { + var slideHeight = $slide.innerHeight(), + $scaler = $slide.find('.' + opts.classes.scaleSlideWrapper); + + // Dont scale if scaling is disabled + scale = $container.hasClass(opts.classes.scale) ? + baseHeight / slideHeight : + 1; + + $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { + if (scale === 1) { + $scaler.css(prefix + 'Transform', ''); + } + else { + $scaler.css(prefix + 'Transform', 'scale(' + scale + ')'); + } + }); + }); + } /* Extends defaults/options. @@ -83,7 +86,8 @@ works fine. */ $.extend(true, $[deck].defaults, { classes: { - scale: 'deck-scale' + scale: 'deck-scale', + scaleSlideWrapper: 'deck-slide-scaler' }, keys: { @@ -126,10 +130,29 @@ works fine. }); $d.bind('deck.init', function() { - var opts = $[deck]('getOptions'); - - // Scaling enabled at start - $[deck]('getContainer').addClass(opts.classes.scale); + var opts = $[deck]('getOptions'), + slideTest = $.map([ + opts.classes.before, + opts.classes.previous, + opts.classes.current, + opts.classes.next, + opts.classes.after + ], function(el, i) { + return '.' + el; + }).join(', '); + + // Build top level slides array + rootSlides = []; + $.each($[deck]('getSlides'), function(i, $el) { + if (!$el.parentsUntil(opts.selectors.container, slideTest).length) { + rootSlides.push($el); + } + }); + + // Use a wrapper on each slide to handle content scaling + $.each(rootSlides, function(i, $slide) { + $slide.children().wrapAll('
'); + }); // Debounce the resize scaling $w.unbind('resize.deckscale').bind('resize.deckscale', function() { @@ -147,8 +170,8 @@ works fine. } }); - // Scale once on init - scaleDeck(); + // Enable scale on init + $[deck]('enableScale'); }); })(jQuery, 'deck', this); diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index 49ce32a5..d15902a8 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -1,14 +1,27 @@ .csstransforms .deck-container.deck-scale:not(.deck-menu) { + overflow:hidden; + > .slide { - -webkit-box-sizing: padding-box; - -moz-box-sizing: padding-box; - box-sizing: padding-box; + -webkit-box-sizing: padding-box; + -moz-box-sizing: padding-box; + box-sizing: padding-box; width:100%; padding-bottom:20px; - -webkit-transform-origin: 50% 0; - -moz-transform-origin: 50% 0; - -o-transform-origin: 50% 0; - -ms-transform-origin: 50% 0; - transform-origin: 50% 0; + + > .deck-slide-scaler { + -webkit-transform-origin: 50% 0; + -moz-transform-origin: 50% 0; + -o-transform-origin: 50% 0; + -ms-transform-origin: 50% 0; + transform-origin: 50% 0; + } } +} + +.csstransforms .deck-container.deck-menu .deck-slide-scaler { + -webkit-transform:none !important; + -moz-transform:none !important; + -o-transform:none !important; + -ms-transform:none !important; + transform:none !important; } \ No newline at end of file From a6d5efc454e7b825828fc6c8b53e2b3d14b3bd6f Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 28 Jan 2012 18:26:39 +0800 Subject: [PATCH 093/169] Cleanup, docs, make container default baseHeight --- extensions/scale/deck.scale.js | 32 +++++++++++++------------------- 1 file changed, 13 insertions(+), 19 deletions(-) diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index 630d92a8..78c0f457 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -7,14 +7,14 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt */ /* -This module adds automatic scaling to the deck. It should only be used on +This module adds automatic scaling to the deck. It is designed to be used on standalone decks where the body is the deck container. Slides are scaled down using CSS transforms to fit within the browser window. If the browser window is big enough to hold the slides without scaling, no scaling occurs. The user can disable and enable scaling with a keyboard shortcut. -Note: CSS transforms make Flash videos render incorrectly. Presenters that -need to use video will want to disable scaling to play them. HTML5 video +Note: CSS transforms may make Flash videos render incorrectly. Presenters +that need to use video may want to disable scaling to play them. HTML5 video works fine. */ (function($, deck, window, undefined) { @@ -25,28 +25,18 @@ works fine. rootSlides, /* - Internal function to do all the dirty work of scaling the deck container. + Internal function to do all the dirty work of scaling the slides. */ scaleDeck = function() { var opts = $[deck]('getOptions'), obh = opts.baseHeight, $container = $[deck]('getContainer'), - height = $w.height(), - slides = $[deck]('getSlides'), - scale, - transform; - - // Use window height as base height if not set manually - baseHeight = obh ? obh : (function() { - return $(window).height(); - })(); + baseHeight = obh ? obh : $container.height(); // Scale each slide down if necessary (but don't scale up) $.each(rootSlides, function(i, $slide) { var slideHeight = $slide.innerHeight(), - $scaler = $slide.find('.' + opts.classes.scaleSlideWrapper); - - // Dont scale if scaling is disabled + $scaler = $slide.find('.' + opts.classes.scaleSlideWrapper), scale = $container.hasClass(opts.classes.scale) ? baseHeight / slideHeight : 1; @@ -68,15 +58,19 @@ works fine. options.classes.scale This class is added to the deck container when scaling is enabled. It is enabled by default when the module is included. + + options.classes.scaleSlideWrapper + Scaling is done using a wrapper around the contents of each slide. This + class is applied to that wrapper. options.keys.scale The numeric keycode used to toggle enabling and disabling scaling. options.baseHeight When baseheight is falsy, as it is by default, the deck is scaled - in proportion to the height of the slides. You may instead specify - a height, and the deck will be scaled against this height regardless - of the actual content height. + in proportion to the height of the deck container. You may instead specify + a height and the deck will be scaled against this height regardless + of the container height. options.scaleDebounce Scaling on the browser resize event is debounced. This number is the From d9b6d816b708b1e67c7dd7b4edcdac221d64a5f6 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 2 Feb 2012 15:37:35 +0800 Subject: [PATCH 094/169] Simplify packaged introduction deck, closes #64 --- introduction/index.html | 48 ++++++++++---------------- introduction/introduction.css | 55 ------------------------------ introduction/introduction.js | 13 ------- introduction/introduction.scss | 62 ---------------------------------- 4 files changed, 18 insertions(+), 160 deletions(-) delete mode 100644 introduction/introduction.css delete mode 100644 introduction/introduction.js delete mode 100755 introduction/introduction.scss diff --git a/introduction/index.html b/introduction/index.html index 0c4715a4..d0fc96c9 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -21,38 +21,18 @@ - - - + + - - + + -
-

Themes

- - - - - - -
- +

Getting Started with deck.js

@@ -183,15 +163,18 @@

Digging Deeper

If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

+ +

/

+
@@ -199,12 +182,13 @@

Digging Deeper

+ # - - - + + + @@ -214,8 +198,12 @@

Digging Deeper

- - + + diff --git a/introduction/introduction.css b/introduction/introduction.css deleted file mode 100644 index eaf13ca0..00000000 --- a/introduction/introduction.css +++ /dev/null @@ -1,55 +0,0 @@ -.deck-container .theme-menu { - display: none; - position: fixed; - z-index: 3; - bottom: 10px; - left: 10px; - height: 20px; - line-height: 20px; - padding: 5px; - border: 1px solid #ddd; - -webkit-border-radius: 5px; - -moz-border-radius: 5px; - border-radius: 5px; - overflow: hidden; - background: #fff; - font-family: sans-serif; - color: #888; -} -.js .deck-container .theme-menu { - display: block; -} -.deck-container .theme-menu h2 { - float: left; - font-size: 20px; - border: 0; - padding: 5px 10px; - margin: 0; - height: 20px; - position: relative; - top: -5px; - left: -5px; - background: #ccc; - color: #444; - text-shadow: none; - font-family: sans-serif; - font-weight: bold; -} -.deck-container .theme-menu label { - float: left; - display: block; - font-size: 12px; - vertical-align: baseline; - margin: 0 4px 0 15px; -} -.deck-container .theme-menu select { - float: left; - display: block; - font-size: 14px; -} - -@media print { - .theme-menu { - display: none !important; - } -} diff --git a/introduction/introduction.js b/introduction/introduction.js deleted file mode 100644 index df37aeb3..00000000 --- a/introduction/introduction.js +++ /dev/null @@ -1,13 +0,0 @@ -$(function() { - // Deck initialization - $.deck('.slide'); - - $('#style-themes').change(function() { - $('#style-theme-link').attr('href', $(this).val()); - }); - - $('#transition-themes').change(function() { - $('#transition-theme-link').attr('href', $(this).val()); - }); -}); - diff --git a/introduction/introduction.scss b/introduction/introduction.scss deleted file mode 100755 index 94325b15..00000000 --- a/introduction/introduction.scss +++ /dev/null @@ -1,62 +0,0 @@ -.deck-container { - .theme-menu { - display:none; - position:fixed; - z-index:3; - bottom:10px; - left:10px; - height:20px; - line-height:20px; - padding:5px; - border:1px solid #ddd; - -webkit-border-radius:5px; - -moz-border-radius:5px; - border-radius:5px; - overflow:hidden; - background:#fff; - font-family:sans-serif; - color:#888; - - .js & { - display:block; - } - - h2 { - float:left; - font-size:20px; - border:0; - padding:5px 10px; - margin:0; - height:20px; - position:relative; - top:-5px; - left:-5px; - background:#ccc; - color:#444; - text-shadow:none; - font-family:sans-serif; - font-weight:bold; - } - - label { - float:left; - display:block; - font-size:12px; - vertical-align:baseline; - margin:0 4px 0 15px; - } - - select { - float:left; - display:block; - font-size:14px; - } - } -} - -@media print { - .theme-menu { - display:none !important; - } -} - From 28431921848353430bc7df016e44f0f8d4cda70e Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 2 Feb 2012 16:46:40 +0800 Subject: [PATCH 095/169] Move nested opacity style to style themes, closes #63 --- themes/style/neon.css | 3 +++ themes/style/neon.scss | 6 ++++++ themes/style/swiss.css | 3 +++ themes/style/swiss.scss | 6 ++++++ themes/style/web-2.0.css | 3 +++ themes/style/web-2.0.scss | 4 ++++ themes/transition/fade.css | 3 --- themes/transition/fade.scss | 4 ---- themes/transition/horizontal-slide.css | 3 --- themes/transition/horizontal-slide.scss | 4 ---- themes/transition/vertical-slide.css | 3 --- themes/transition/vertical-slide.scss | 4 ---- 12 files changed, 25 insertions(+), 21 deletions(-) diff --git a/themes/style/neon.css b/themes/style/neon.css index 37b604c5..728085eb 100644 --- a/themes/style/neon.css +++ b/themes/style/neon.css @@ -81,6 +81,9 @@ -moz-box-shadow: 0 0 20px #f0a, 0 0 5px #fff; box-shadow: 0 0 20px #f0a, 0 0 5px #fff; } +.deck-container > .slide .deck-before, .deck-container > .slide .deck-previous { + opacity: 0.4; +} .deck-container .deck-status { font-size: 0.6666em; } diff --git a/themes/style/neon.scss b/themes/style/neon.scss index 01b207f3..06d10d37 100644 --- a/themes/style/neon.scss +++ b/themes/style/neon.scss @@ -96,6 +96,12 @@ } } + > .slide { + .deck-before, .deck-previous { + opacity:0.4; + } + } + .deck-status { font-size:0.6666em; } diff --git a/themes/style/swiss.css b/themes/style/swiss.css index e34b2b38..12b198b1 100644 --- a/themes/style/swiss.css +++ b/themes/style/swiss.css @@ -53,6 +53,9 @@ .deck-container .slide a:hover, .deck-container .slide a:focus { text-decoration: underline; } +.deck-container > .slide .deck-before, .deck-container > .slide .deck-previous { + opacity: 0.4; +} .deck-container .deck-prev-link, .deck-container .deck-next-link { background: #ccc; font-family: serif; diff --git a/themes/style/swiss.scss b/themes/style/swiss.scss index a60bc4ac..7a6511bc 100644 --- a/themes/style/swiss.scss +++ b/themes/style/swiss.scss @@ -61,6 +61,12 @@ } } + > .slide { + .deck-before, .deck-previous { + opacity:0.4; + } + } + .deck-prev-link, .deck-next-link { background:#ccc; font-family:serif; // sans-serif arrows x-browser fail diff --git a/themes/style/web-2.0.css b/themes/style/web-2.0.css index 9e2cc300..7a77c0c7 100644 --- a/themes/style/web-2.0.css +++ b/themes/style/web-2.0.css @@ -21,6 +21,9 @@ .deck-container > .slide { text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.5); } +.deck-container > .slide .deck-before, .deck-container > .slide .deck-previous { + opacity: 0.4; +} .deck-container .slide h1, .deck-container .slide h2, .deck-container .slide h3, .deck-container .slide h4, .deck-container .slide h5, .deck-container .slide h6 { font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; } diff --git a/themes/style/web-2.0.scss b/themes/style/web-2.0.scss index 406d8ee4..0566be8a 100644 --- a/themes/style/web-2.0.scss +++ b/themes/style/web-2.0.scss @@ -33,6 +33,10 @@ > .slide { text-shadow:1px 1px 1px rgba(255,255,255,.5); + + .deck-before, .deck-previous { + opacity:0.4; + } } .slide { diff --git a/themes/transition/fade.css b/themes/transition/fade.css index f3793f31..cbd29997 100644 --- a/themes/transition/fade.css +++ b/themes/transition/fade.css @@ -21,9 +21,6 @@ top: 0; opacity: 0; } -.csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-before, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-previous { - opacity: 0.4; -} .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-current { opacity: 1; } diff --git a/themes/transition/fade.scss b/themes/transition/fade.scss index c5af7e7f..7df3b7fb 100644 --- a/themes/transition/fade.scss +++ b/themes/transition/fade.scss @@ -37,10 +37,6 @@ opacity:0; } - .deck-before, .deck-previous { - opacity:0.4; - } - .deck-current { opacity:1; } diff --git a/themes/transition/horizontal-slide.css b/themes/transition/horizontal-slide.css index a768d615..4a4c6adf 100644 --- a/themes/transition/horizontal-slide.css +++ b/themes/transition/horizontal-slide.css @@ -36,9 +36,6 @@ -o-transform: translate(200%, 0); transform: translate3d(200%, 0, 0); } -.csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-before, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-previous { - opacity: 0.4; -} .csstransitions.csstransforms .deck-container:not(.deck-menu) > .deck-previous { -webkit-transform: translate3d(-200%, 0, 0); -moz-transform: translate(-200%, 0); diff --git a/themes/transition/horizontal-slide.scss b/themes/transition/horizontal-slide.scss index 90a30a09..c260bbc6 100644 --- a/themes/transition/horizontal-slide.scss +++ b/themes/transition/horizontal-slide.scss @@ -59,10 +59,6 @@ visibility:visible; @include translate(200%); } - - .deck-before, .deck-previous { - opacity:0.4; - } } > .deck-previous { diff --git a/themes/transition/vertical-slide.css b/themes/transition/vertical-slide.css index f9c02ec0..7f87092b 100644 --- a/themes/transition/vertical-slide.css +++ b/themes/transition/vertical-slide.css @@ -36,9 +36,6 @@ -o-transform: translate(0, 1600px); transform: translate3d(0, 1600px, 0); } -.csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-before, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-previous { - opacity: 0.4; -} .csstransitions.csstransforms .deck-container:not(.deck-menu) > .deck-previous { -webkit-transform: translate3d(0, -200%, 0); -moz-transform: translate(0, -200%); diff --git a/themes/transition/vertical-slide.scss b/themes/transition/vertical-slide.scss index 7277316e..c6892c35 100644 --- a/themes/transition/vertical-slide.scss +++ b/themes/transition/vertical-slide.scss @@ -69,10 +69,6 @@ visibility:visible; @include translate(0, 1600px); } - - .deck-before, .deck-previous { - opacity:0.4; - } } > .deck-previous { From f7b44a4095249adbd0c53a41695a22b883afc6cf Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 11 Feb 2012 14:30:37 +0800 Subject: [PATCH 096/169] Update comments and README for scaling changes --- README.md | 1 + extensions/scale/deck.scale.js | 7 +++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 209ebf77..bcbbc486 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,7 @@ Core includes stripped down black and white print styles for the standard slide - [dougireton](https://github.com/dougireton) - [awirick](https://github.com/awirick) - Daniel Knittl-Frank +- [alexch](https://github.com/alexch) If you would like to contribute a patch to deck.js please do as much as you can of the following: diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index 78c0f457..ca897ffd 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -7,10 +7,9 @@ https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt */ /* -This module adds automatic scaling to the deck. It is designed to be used on -standalone decks where the body is the deck container. Slides are scaled down -using CSS transforms to fit within the browser window. If the browser window -is big enough to hold the slides without scaling, no scaling occurs. The user +This module adds automatic scaling to the deck. Slides are scaled down +using CSS transforms to fit within the deck container. If the container is +big enough to hold the slides without scaling, no scaling occurs. The user can disable and enable scaling with a keyboard shortcut. Note: CSS transforms may make Flash videos render incorrectly. Presenters From 0e12e1d0d2a85a572a80f28ceb6a08bbaf5233df Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 11 Feb 2012 14:48:31 +0800 Subject: [PATCH 097/169] Missed the baseHeight comment update --- extensions/scale/deck.scale.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index ca897ffd..14feb1ac 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -66,10 +66,10 @@ works fine. The numeric keycode used to toggle enabling and disabling scaling. options.baseHeight - When baseheight is falsy, as it is by default, the deck is scaled - in proportion to the height of the deck container. You may instead specify - a height and the deck will be scaled against this height regardless - of the container height. + When baseHeight is falsy, as it is by default, the deck is scaled in + proportion to the height of the deck container. You may instead specify + a height as a number of px, and slides will be scaled against this + height regardless of the container size. options.scaleDebounce Scaling on the browser resize event is debounced. This number is the From 227b6b7cc434bbc9fc96f67e8c24a76cf7b1d1b4 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 11 Feb 2012 14:57:34 +0800 Subject: [PATCH 098/169] Fix opacity 0 bug in nested slides for fade transition --- themes/transition/fade.css | 2 ++ themes/transition/fade.scss | 3 +++ 2 files changed, 5 insertions(+) diff --git a/themes/transition/fade.css b/themes/transition/fade.css index cbd29997..3c3fa2db 100644 --- a/themes/transition/fade.css +++ b/themes/transition/fade.css @@ -19,6 +19,8 @@ position: relative; left: 0; top: 0; +} +.csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-next, .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-after { opacity: 0; } .csstransitions.csstransforms .deck-container:not(.deck-menu) > .slide .deck-current { diff --git a/themes/transition/fade.scss b/themes/transition/fade.scss index 7df3b7fb..76126292 100644 --- a/themes/transition/fade.scss +++ b/themes/transition/fade.scss @@ -34,6 +34,9 @@ position:relative; left:0; top:0; + } + + .deck-next, .deck-after { opacity:0; } From c77cfb7148114873bc9b682ba73288c5275b6175 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Tue, 6 Mar 2012 21:50:02 +0800 Subject: [PATCH 099/169] Fix opacity in style themes for double nested slides, closes #70 --- themes/style/neon.css | 6 ++++++ themes/style/neon.scss | 10 ++++++++++ themes/style/swiss.css | 6 ++++++ themes/style/swiss.scss | 10 ++++++++++ themes/style/web-2.0.css | 6 ++++++ themes/style/web-2.0.scss | 10 ++++++++++ 6 files changed, 48 insertions(+) diff --git a/themes/style/neon.css b/themes/style/neon.css index 728085eb..5598b55f 100644 --- a/themes/style/neon.css +++ b/themes/style/neon.css @@ -84,6 +84,12 @@ .deck-container > .slide .deck-before, .deck-container > .slide .deck-previous { opacity: 0.4; } +.deck-container > .slide .deck-before:not(.deck-child-current) .deck-before, .deck-container > .slide .deck-before:not(.deck-child-current) .deck-previous, .deck-container > .slide .deck-previous:not(.deck-child-current) .deck-before, .deck-container > .slide .deck-previous:not(.deck-child-current) .deck-previous { + opacity: 1; +} +.deck-container > .slide .deck-child-current { + opacity: 1; +} .deck-container .deck-status { font-size: 0.6666em; } diff --git a/themes/style/neon.scss b/themes/style/neon.scss index 06d10d37..eb30ef0c 100644 --- a/themes/style/neon.scss +++ b/themes/style/neon.scss @@ -99,6 +99,16 @@ > .slide { .deck-before, .deck-previous { opacity:0.4; + + &:not(.deck-child-current) { + .deck-before, .deck-previous { + opacity:1; + } + } + } + + .deck-child-current { + opacity:1; } } diff --git a/themes/style/swiss.css b/themes/style/swiss.css index 12b198b1..8598ae29 100644 --- a/themes/style/swiss.css +++ b/themes/style/swiss.css @@ -56,6 +56,12 @@ .deck-container > .slide .deck-before, .deck-container > .slide .deck-previous { opacity: 0.4; } +.deck-container > .slide .deck-before:not(.deck-child-current) .deck-before, .deck-container > .slide .deck-before:not(.deck-child-current) .deck-previous, .deck-container > .slide .deck-previous:not(.deck-child-current) .deck-before, .deck-container > .slide .deck-previous:not(.deck-child-current) .deck-previous { + opacity: 1; +} +.deck-container > .slide .deck-child-current { + opacity: 1; +} .deck-container .deck-prev-link, .deck-container .deck-next-link { background: #ccc; font-family: serif; diff --git a/themes/style/swiss.scss b/themes/style/swiss.scss index 7a6511bc..15be1643 100644 --- a/themes/style/swiss.scss +++ b/themes/style/swiss.scss @@ -64,6 +64,16 @@ > .slide { .deck-before, .deck-previous { opacity:0.4; + + &:not(.deck-child-current) { + .deck-before, .deck-previous { + opacity:1; + } + } + } + + .deck-child-current { + opacity:1; } } diff --git a/themes/style/web-2.0.css b/themes/style/web-2.0.css index 7a77c0c7..5fbca31b 100644 --- a/themes/style/web-2.0.css +++ b/themes/style/web-2.0.css @@ -24,6 +24,12 @@ .deck-container > .slide .deck-before, .deck-container > .slide .deck-previous { opacity: 0.4; } +.deck-container > .slide .deck-before:not(.deck-child-current) .deck-before, .deck-container > .slide .deck-before:not(.deck-child-current) .deck-previous, .deck-container > .slide .deck-previous:not(.deck-child-current) .deck-before, .deck-container > .slide .deck-previous:not(.deck-child-current) .deck-previous { + opacity: 1; +} +.deck-container > .slide .deck-child-current { + opacity: 1; +} .deck-container .slide h1, .deck-container .slide h2, .deck-container .slide h3, .deck-container .slide h4, .deck-container .slide h5, .deck-container .slide h6 { font-family: "Hoefler Text", Constantia, Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif; } diff --git a/themes/style/web-2.0.scss b/themes/style/web-2.0.scss index 0566be8a..f5ac86dc 100644 --- a/themes/style/web-2.0.scss +++ b/themes/style/web-2.0.scss @@ -36,6 +36,16 @@ .deck-before, .deck-previous { opacity:0.4; + + &:not(.deck-child-current) { + .deck-before, .deck-previous { + opacity:1; + } + } + } + + .deck-child-current { + opacity:1; } } From 4f6fb4c18f65d1b3dcfde902f7ac6d35346e4b2f Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Wed, 28 Mar 2012 12:06:49 +0800 Subject: [PATCH 100/169] Make slides full width, set some overflows, closes #72 --- README.md | 2 ++ core/deck.core.css | 10 +++++----- core/deck.core.scss | 10 +++++----- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index bcbbc486..d6184a56 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,8 @@ There is an issue with certain builds of Chrome that result in a solid blue back - Disable hardware compositing by setting `--disable-accelerated-compositing` in the Chrome loading options - Replace instances of `translate3d` with `translate` in the CSS of your decks (though this will slow down performance on iOS devices and Safari.) +Firefox contains a bug that allows users to scroll horizontally using the trackpad despite `overflow-x:hidden`. ([Bug 664275](https://bugzilla.mozilla.org/show_bug.cgi?id=664275) and [Bug 325942](https://bugzilla.mozilla.org/show_bug.cgi?id=325942).) If anyone knows of any workarounds to this issue please contact me. + ## Printing Core includes stripped down black and white print styles for the standard slide template that is suitable for handouts. diff --git a/core/deck.core.css b/core/deck.core.css index 92fd1434..7db99acb 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -2,10 +2,13 @@ html { height: 100%; } +body.deck-container { + overflow-y: auto; +} + .deck-container { position: relative; height: 100%; - width: 70%; margin: 0 auto; padding: 0 48px; font-size: 16px; @@ -22,6 +25,7 @@ html { } .touch .deck-container { -webkit-text-size-adjust: none; + -moz-text-size-adjust: none; } .deck-container div, .deck-container span, .deck-container object, .deck-container iframe, .deck-container h1, .deck-container h2, .deck-container h3, .deck-container h4, .deck-container h5, .deck-container h6, .deck-container p, .deck-container blockquote, .deck-container pre, @@ -298,10 +302,6 @@ html { visibility: visible; } -body.deck-container { - overflow: visible; -} - @media screen and (max-device-width: 480px) { /* html { -webkit-text-size-adjust:none; -ms-text-size-adjust:none; } */ } diff --git a/core/deck.core.scss b/core/deck.core.scss index e03ca316..8c05dbb2 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -2,10 +2,13 @@ html { height:100%; } +body.deck-container { + overflow-y:auto; +} + .deck-container { position:relative; height:100%; - width:70%; margin:0 auto; padding:0 48px; font-size:16px; @@ -22,6 +25,7 @@ html { .touch & { -webkit-text-size-adjust:none; + -moz-text-size-adjust:none; } /* Resets and base styles from HTML5 Boilerplate */ @@ -362,10 +366,6 @@ html { } } -body.deck-container { - overflow:visible; -} - @media all and (orientation:portrait) { } From 4ed8c60ba524811a87cca1e947769ec5eda837e5 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 14 Apr 2012 12:41:47 +0800 Subject: [PATCH 101/169] Add scale extension to introduction --- introduction/index.html | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/introduction/index.html b/introduction/index.html index d0fc96c9..9d4d11f2 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -20,6 +20,7 @@ + @@ -107,6 +108,10 @@

Extensions

  • deck.status: Adds a page number indicator. (current/total)
  • + +
  • + deck.scale: Scales each slide to fit within the deck container using CSS Transforms for those browsers that support them. +
  • Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    @@ -197,6 +202,7 @@

    Digging Deeper

    + - - - -
    -

    Getting Started with deck.js

    -
    - -
    -

    How to Make a Deck

    -
      -
    1. -

      Write Slides

      -

      Slide content is simple HTML.

      -
    2. -
    3. -

      Choose Themes

      -

      One for slide styles and one for deck transitions.

      -
    4. -
    5. -

      Include Extensions

      -

      Add extra functionality to your deck, or leave it stripped down.

      -
    6. -
    -
    - -
    -

    The Markup

    -

    Slides are just HTML elements with a class of slide.

    -
    <section class="slide">
    -   <h2>How to Make a Deck</h2>
    -   <ol>
    -      <li>
    -         <h3>Write Slides</h3>
    -         <p>Slide content is simple HTML.</p>
    -      </li>
    -      <li>
    -         <h3>Choose Themes</h3>
    -         <p>One for slide styles and one for deck transitions.</p>
    -      </li>
    -      …
    -   </ol>
    -</section>
    -
    - -
    -

    Style Themes

    -

    Customizes the colors, typography, and layout of slide content.

    -
    <link rel="stylesheet" href="/path/to/css/style-theme.css">
    -

    Transition Themes

    -

    Defines transitions between slides using CSS3 transitions. Less capable browsers fall back to cutaways. But you aren’t using those browsers to give your presentations, are you…

    -
    <link rel="stylesheet" href="/path/to/css/transition-theme.css">
    -
    - -
    -

    Extensions

    -

    Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

    - -
      -
    • - deck.goto: Adds a shortcut key to jump to any slide number. Hit g, type in the slide number, and hit enter. -
    • - -
    • - deck.hash: Enables internal linking within slides, deep linking to individual slides, and updates the address bar & a permalink anchor with each slide change. -
    • - -
    • - deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. Touch devices can double-tap the deck to switch between views. -
    • - -
    • - deck.navigation: Adds clickable left and right buttons for the less keyboard inclined. -
    • - -
    • - deck.status: Adds a page number indicator. (current/total) -
    • - -
    • - deck.scale: Scales each slide to fit within the deck container using CSS Transforms for those browsers that support them. -
    • -
    - -

    Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    -
    + -
    -

    Nested Slides

    -

    That last slide had a few steps. To create substeps in slides, just nest them:

    -
    <section class="slide">
    +
    + +
    + +
    +
    +

    Getting Started with deck.js

    +
    + +
    +

    How to Make a Deck

    +
      +
    1. +

      Write Slides

      +

      Slide content is simple HTML.

      +
    2. +
    3. +

      Choose Themes

      +

      One for slide styles and one for deck transitions.

      +
    4. +
    5. +

      Include Extensions

      +

      Add extra functionality to your deck, or leave it stripped down.

      +
    6. +
    +
    + +
    +

    The Markup

    +

    Slides are just HTML elements with a class of slide.

    +
    <section class="slide">
    +  <h2>How to Make a Deck</h2>
    +  <ol>
    +    <li>
    +      <h3>Write Slides</h3>
    +      <p>Slide content is simple HTML.</p>
    +    </li>
    +    <li>
    +      <h3>Choose Themes</h3>
    +      <p>One for slide styles and one for deck transitions.</p>
    +    </li>
    +    …
    +  </ol>
    +</section>
    +
    + +
    +

    Style Themes

    +

    Customizes the colors, typography, and layout of slide content.

    +
    <link rel="stylesheet" href="/path/to/css/style-theme.css">
    +

    Transition Themes

    +

    Defines transitions between slides using CSS3 transitions. Less capable browsers fall back to cutaways. But you aren’t using those browsers to give your presentations, are you…

    +
    <link rel="stylesheet" href="/path/to/css/transition-theme.css">
    +
    + +
    +

    Extensions

    +

    Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

    + +
      +
    • + deck.goto: Adds a shortcut key to jump to any slide number. Hit g, type in the slide number, and hit enter. +
    • + +
    • + deck.hash: Enables internal linking within slides, deep linking to individual slides, and updates the address bar & a permalink anchor with each slide change. +
    • + +
    • + deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. Touch devices can double-tap the deck to switch between views. +
    • + +
    • + deck.navigation: Adds clickable left and right buttons for the less keyboard inclined. +
    • + +
    • + deck.status: Adds a page number indicator. (current/total) +
    • +
    + +

    Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    +
    + +
    +

    Nested Slides

    +

    That last slide had a few steps. To create substeps in slides, just nest them:

    +
    <section class="slide">
       <h2>Extensions</h2>
       <p>Core gives you basic slide functionality...</p>		
       <ul>
    @@ -133,63 +160,63 @@ 

    Nested Slides

    <li class="slide">...</li> </ul> </section>
    -
    - -
    -

    Other Elements: Images

    - Kitties -
    <img src="http://placekitten.com/600/375" alt="Kitties">
    -
    - -
    -

    Other Elements: Blockquotes

    -
    -

    Food is an important part of a balanced diet.

    -

    Fran Lebowitz

    -
    -
    <blockquote cite="http://example.org">
    +	
    + +
    +

    Other Elements: Images

    + Kitties +
    <img src="http://placekitten.com/600/375" alt="Kitties">
    +
    + +
    +

    Other Elements: Blockquotes

    +
    +

    Food is an important part of a balanced diet.

    +

    Fran Lebowitz

    +
    +
    <blockquote cite="http://example.org">
       <p>Food is an important part of a balanced diet.</p>
       <p><cite>Fran Lebowitz</cite></p>
     </blockquote>
    -
    +
    -
    -

    Other Elements: Video Embeds

    -

    Embed videos from your favorite online video service or with an HTML5 video element.

    - - +
    +

    Other Elements: Video Embeds

    +

    Embed videos using embed codes from your favorite online video service or with an HTML5 video element.

    + + + +
    <iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
    +
    + +
    +

    Digging Deeper

    +

    If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

    +
    + + + + +

    + + / + +

    + +
    + + + + + -
    <iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
    -
    - -
    -

    Digging Deeper

    -

    If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

    -
    - - - - - - -

    - - / - -

    - - -
    - - - - - - - -# + # + + @@ -202,14 +229,9 @@

    Digging Deeper

    - - - - + + + From c4430d3c1c973ae7fe38bdfab2afd833fbe6054d Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 13 Jul 2012 21:13:15 +0800 Subject: [PATCH 114/169] Woops 2: The Search for Curly's Gold --- introduction/index.html | 326 +++++++++++++++++++--------------------- 1 file changed, 152 insertions(+), 174 deletions(-) diff --git a/introduction/index.html b/introduction/index.html index 4bce5fc6..9d4d11f2 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -20,134 +20,107 @@ + - - - + + - - - + + - - -
    - -
    - -
    -
    -

    Getting Started with deck.js

    -
    - -
    -

    How to Make a Deck

    -
      -
    1. -

      Write Slides

      -

      Slide content is simple HTML.

      -
    2. -
    3. -

      Choose Themes

      -

      One for slide styles and one for deck transitions.

      -
    4. -
    5. -

      Include Extensions

      -

      Add extra functionality to your deck, or leave it stripped down.

      -
    6. -
    -
    - -
    -

    The Markup

    -

    Slides are just HTML elements with a class of slide.

    -
    <section class="slide">
    -  <h2>How to Make a Deck</h2>
    -  <ol>
    -    <li>
    -      <h3>Write Slides</h3>
    -      <p>Slide content is simple HTML.</p>
    -    </li>
    -    <li>
    -      <h3>Choose Themes</h3>
    -      <p>One for slide styles and one for deck transitions.</p>
    -    </li>
    -    …
    -  </ol>
    +
    +
    +
    +
    +

    Getting Started with deck.js

    +
    + +
    +

    How to Make a Deck

    +
      +
    1. +

      Write Slides

      +

      Slide content is simple HTML.

      +
    2. +
    3. +

      Choose Themes

      +

      One for slide styles and one for deck transitions.

      +
    4. +
    5. +

      Include Extensions

      +

      Add extra functionality to your deck, or leave it stripped down.

      +
    6. +
    +
    + +
    +

    The Markup

    +

    Slides are just HTML elements with a class of slide.

    +
    <section class="slide">
    +   <h2>How to Make a Deck</h2>
    +   <ol>
    +      <li>
    +         <h3>Write Slides</h3>
    +         <p>Slide content is simple HTML.</p>
    +      </li>
    +      <li>
    +         <h3>Choose Themes</h3>
    +         <p>One for slide styles and one for deck transitions.</p>
    +      </li>
    +      …
    +   </ol>
     </section>
    -
    - -
    -

    Style Themes

    -

    Customizes the colors, typography, and layout of slide content.

    -
    <link rel="stylesheet" href="/path/to/css/style-theme.css">
    -

    Transition Themes

    -

    Defines transitions between slides using CSS3 transitions. Less capable browsers fall back to cutaways. But you aren’t using those browsers to give your presentations, are you…

    -
    <link rel="stylesheet" href="/path/to/css/transition-theme.css">
    -
    - -
    -

    Extensions

    -

    Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

    - -
      -
    • - deck.goto: Adds a shortcut key to jump to any slide number. Hit g, type in the slide number, and hit enter. -
    • - -
    • - deck.hash: Enables internal linking within slides, deep linking to individual slides, and updates the address bar & a permalink anchor with each slide change. -
    • - -
    • - deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. Touch devices can double-tap the deck to switch between views. -
    • - -
    • - deck.navigation: Adds clickable left and right buttons for the less keyboard inclined. -
    • - -
    • - deck.status: Adds a page number indicator. (current/total) -
    • -
    - -

    Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    -
    - -
    -

    Nested Slides

    -

    That last slide had a few steps. To create substeps in slides, just nest them:

    -
    <section class="slide">
    +
    + +
    +

    Style Themes

    +

    Customizes the colors, typography, and layout of slide content.

    +
    <link rel="stylesheet" href="/path/to/css/style-theme.css">
    +

    Transition Themes

    +

    Defines transitions between slides using CSS3 transitions. Less capable browsers fall back to cutaways. But you aren’t using those browsers to give your presentations, are you…

    +
    <link rel="stylesheet" href="/path/to/css/transition-theme.css">
    +
    + +
    +

    Extensions

    +

    Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

    + +
      +
    • + deck.goto: Adds a shortcut key to jump to any slide number. Hit g, type in the slide number, and hit enter. +
    • + +
    • + deck.hash: Enables internal linking within slides, deep linking to individual slides, and updates the address bar & a permalink anchor with each slide change. +
    • + +
    • + deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. Touch devices can double-tap the deck to switch between views. +
    • + +
    • + deck.navigation: Adds clickable left and right buttons for the less keyboard inclined. +
    • + +
    • + deck.status: Adds a page number indicator. (current/total) +
    • + +
    • + deck.scale: Scales each slide to fit within the deck container using CSS Transforms for those browsers that support them. +
    • +
    + +

    Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    +
    + +
    +

    Nested Slides

    +

    That last slide had a few steps. To create substeps in slides, just nest them:

    +
    <section class="slide">
       <h2>Extensions</h2>
       <p>Core gives you basic slide functionality...</p>		
       <ul>
    @@ -160,63 +133,63 @@ 

    Nested Slides

    <li class="slide">...</li> </ul> </section>
    -
    - -
    -

    Other Elements: Images

    - Kitties -
    <img src="http://placekitten.com/600/375" alt="Kitties">
    -
    - -
    -

    Other Elements: Blockquotes

    -
    -

    Food is an important part of a balanced diet.

    -

    Fran Lebowitz

    -
    -
    <blockquote cite="http://example.org">
    +
    + +
    +

    Other Elements: Images

    + Kitties +
    <img src="http://placekitten.com/600/375" alt="Kitties">
    +
    + +
    +

    Other Elements: Blockquotes

    +
    +

    Food is an important part of a balanced diet.

    +

    Fran Lebowitz

    +
    +
    <blockquote cite="http://example.org">
       <p>Food is an important part of a balanced diet.</p>
       <p><cite>Fran Lebowitz</cite></p>
     </blockquote>
    -
    +
    -
    -

    Other Elements: Video Embeds

    -

    Embed videos using embed codes from your favorite online video service or with an HTML5 video element.

    - - - -
    <iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
    -
    - -
    -

    Digging Deeper

    -

    If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

    -
    - - - - -

    - - / - -

    - -
    - - - - - +
    +

    Other Elements: Video Embeds

    +

    Embed videos from your favorite online video service or with an HTML5 video element.

    + + - # -
    +
    <iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
    + + +
    +

    Digging Deeper

    +

    If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

    +
    + + + + + + +

    + + / + +

    + + +
    + + + + + + + +# - @@ -229,9 +202,14 @@

    Digging Deeper

    - - - + + + + From 5808a3c8d7eceb9e4a82b5d16cc5027cdd4731df Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 21 Jul 2012 10:20:16 +0800 Subject: [PATCH 115/169] Create a better boilerplate for people to use as a starting point --- README.md | 12 ++++-- boilerplate.html | 96 +++++++++++++++++++++++++++++++++++++++++++++ core/deck.core.html | 39 ------------------ 3 files changed, 104 insertions(+), 43 deletions(-) create mode 100644 boilerplate.html delete mode 100644 core/deck.core.html diff --git a/README.md b/README.md index d6184a56..0f6a96e5 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,9 @@ A JavaScript library for building modern HTML presentations. deck.js is flexible enough to let advanced CSS and JavaScript authors craft highly customized decks, but also provides templates and themes for the HTML novice to build a standard slideshow. -## Dependencies (included in this repository) +## Quick Start -- [jQuery](http://jquery.com) -- [Modernizr](http://modernizr.com) +This repository includes a `boilerplate.html` as a starting point, with all the extensions included. Just [download it](https://github.com/imakewebthings/deck.js/zipball/stable), open `boilerplate.html`, and start editing your slides. ## Documentation @@ -15,6 +14,11 @@ Check out the [documentation page](http://imakewebthings.github.com/deck.js/docs Take a look at [the wiki](https://github.com/imakewebthings/deck.js/wiki) for lists of extensions, themes, and other related goodies. If you have a publicly available project of your own, feel free to add to the list. +## Dependencies (included in this repository) + +- [jQuery](http://jquery.com) +- [Modernizr](http://modernizr.com) + ## Tests & Support Unit tests are written with [Jasmine](http://pivotal.github.com/jasmine/) and [jasmine-jquery](https://github.com/velesin/jasmine-jquery). You can [run them here](http://imakewebthings.github.com/deck.js/test). @@ -55,6 +59,6 @@ If you would like to contribute a patch to deck.js please do as much as you can ## License -Copyright (c) 2011 Caleb Troughton +Copyright (c) 2011-2012 Caleb Troughton Dual licensed under the [MIT license](https://github.com/imakewebthings/deck.js/blob/master/MIT-license.txt) and [GPL license](https://github.com/imakewebthings/deck.js/blob/master/GPL-license.txt). diff --git a/boilerplate.html b/boilerplate.html new file mode 100644 index 00000000..5919b0cb --- /dev/null +++ b/boilerplate.html @@ -0,0 +1,96 @@ + + + + + + + + Codestin Search App + + + + + + + + + + + + + + + + + + + + + + + + + +
    +

    Slide

    +
    + +
    +

    Content

    +
    + +
    +

    Here

    +
    + + + + + + + + + + + +

    + + / + +

    + + +
    + + + + + + + +# + + + + + + + + + + + + + + + + + + + + + diff --git a/core/deck.core.html b/core/deck.core.html deleted file mode 100644 index 03fd8d29..00000000 --- a/core/deck.core.html +++ /dev/null @@ -1,39 +0,0 @@ - - - - - Codestin Search App - - - - - - - - - - - - - -
    - -
    - - - - - - - - - - - - - - From 50ab2f4c7b0d780dea41c4bb9a6f18dc0be823e5 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 21 Jul 2012 10:28:18 +0800 Subject: [PATCH 116/169] Adding basic reset properties to body+html to reduce friction when BODY is not deck container --- core/deck.core.css | 4 +++- core/deck.core.scss | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/core/deck.core.css b/core/deck.core.css index a188b28f..823af0ff 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -1,5 +1,7 @@ -html { +html, body { height: 100%; + padding: 0; + margin: 0; } body.deck-container { diff --git a/core/deck.core.scss b/core/deck.core.scss index 8deaca91..67210500 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -1,5 +1,7 @@ -html { +html, body { height:100%; + padding:0; + margin:0; } body.deck-container { From 069f63294abe8c2bfd0e3c9b34d26090802c4f46 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Sat, 21 Jul 2012 10:34:00 +0800 Subject: [PATCH 117/169] Update jQuery to 1.7.2 --- boilerplate.html | 2 +- introduction/index.html | 4 ++-- jquery-1.7.2.min.js | 4 ++++ jquery-1.7.min.js | 4 ---- test/index.html | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) create mode 100644 jquery-1.7.2.min.js delete mode 100644 jquery-1.7.min.js diff --git a/boilerplate.html b/boilerplate.html index 5919b0cb..9b76d948 100644 --- a/boilerplate.html +++ b/boilerplate.html @@ -74,7 +74,7 @@

    Here

    - + diff --git a/introduction/index.html b/introduction/index.html index 9d4d11f2..71d7c044 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -192,8 +192,8 @@

    Digging Deeper

    - - + + diff --git a/jquery-1.7.2.min.js b/jquery-1.7.2.min.js new file mode 100644 index 00000000..93adea19 --- /dev/null +++ b/jquery-1.7.2.min.js @@ -0,0 +1,4 @@ +/*! jQuery v1.7.2 jquery.com | jquery.org/license */ +(function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cu(a){if(!cj[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){ck||(ck=c.createElement("iframe"),ck.frameBorder=ck.width=ck.height=0),b.appendChild(ck);if(!cl||!ck.createElement)cl=(ck.contentWindow||ck.contentDocument).document,cl.write((f.support.boxModel?"":"")+""),cl.close();d=cl.createElement(a),cl.body.appendChild(d),e=f.css(d,"display"),b.removeChild(ck)}cj[a]=e}return cj[a]}function ct(a,b){var c={};f.each(cp.concat.apply([],cp.slice(0,b)),function(){c[this]=a});return c}function cs(){cq=b}function cr(){setTimeout(cs,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;g0){if(c!=="border")for(;e=0===c})}function S(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function K(){return!0}function J(){return!1}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?+d:j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,n=/^[\],:{}\s]*$/,o=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,p=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,q=/(?:^|:|,)(?:\s*\[)+/g,r=/(webkit)[ \/]([\w.]+)/,s=/(opera)(?:.*version)?[ \/]([\w.]+)/,t=/(msie) ([\w.]+)/,u=/(mozilla)(?:.*? rv:([\w.]+))?/,v=/-([a-z]|[0-9])/ig,w=/^-ms-/,x=function(a,b){return(b+"").toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};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=m.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.7.2",length:0,size:function(){return this.length},toArray:function(){return F.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)?E.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(),A.add(a);return this},eq:function(a){a=+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(F.apply(this,arguments),"slice",F.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:E,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;A.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").off("ready")}},bindReady:function(){if(!A){A=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a!=null&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||D.call(a,d)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw new Error(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(n.test(b.replace(o,"@").replace(p,"]").replace(q,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(c){if(typeof c!="string"||!c)return null;var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,"ms-").replace(v,x)},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?i.call(arguments,0):b,j.notifyWith(k,e)}}function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}var b=i.call(arguments,0),c=0,d=b.length,e=Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c
    a",d=p.getElementsByTagName("*"),e=p.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=p.getElementsByTagName("input")[0],b={leadingWhitespace:p.firstChild.nodeType===3,tbody:!p.getElementsByTagName("tbody").length,htmlSerialize:!!p.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:i.value==="on",optSelected:h.selected,getSetAttribute:p.className!=="t",enctype:!!c.createElement("form").enctype,html5Clone:c.createElement("nav").cloneNode(!0).outerHTML!=="<:nav>",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,pixelMargin:!0},f.boxModel=b.boxModel=c.compatMode==="CSS1Compat",i.checked=!0,b.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,b.optDisabled=!h.disabled;try{delete p.test}catch(r){b.deleteExpando=!1}!p.addEventListener&&p.attachEvent&&p.fireEvent&&(p.attachEvent("onclick",function(){b.noCloneEvent=!1}),p.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),b.radioValue=i.value==="t",i.setAttribute("checked","checked"),i.setAttribute("name","t"),p.appendChild(i),j=c.createDocumentFragment(),j.appendChild(p.lastChild),b.checkClone=j.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=i.checked,j.removeChild(i),j.appendChild(p);if(p.attachEvent)for(n in{submit:1,change:1,focusin:1})m="on"+n,o=m in p,o||(p.setAttribute(m,"return;"),o=typeof p[m]=="function"),b[n+"Bubbles"]=o;j.removeChild(p),j=g=h=p=i=null,f(function(){var d,e,g,h,i,j,l,m,n,q,r,s,t,u=c.getElementsByTagName("body")[0];!u||(m=1,t="padding:0;margin:0;border:",r="position:absolute;top:0;left:0;width:1px;height:1px;",s=t+"0;visibility:hidden;",n="style='"+r+t+"5px solid #000;",q="
    "+""+"
    ",d=c.createElement("div"),d.style.cssText=s+"width:0;height:0;position:static;top:0;margin-top:"+m+"px",u.insertBefore(d,u.firstChild),p=c.createElement("div"),d.appendChild(p),p.innerHTML="
    t
    ",k=p.getElementsByTagName("td"),o=k[0].offsetHeight===0,k[0].style.display="",k[1].style.display="none",b.reliableHiddenOffsets=o&&k[0].offsetHeight===0,a.getComputedStyle&&(p.innerHTML="",l=c.createElement("div"),l.style.width="0",l.style.marginRight="0",p.style.width="2px",p.appendChild(l),b.reliableMarginRight=(parseInt((a.getComputedStyle(l,null)||{marginRight:0}).marginRight,10)||0)===0),typeof p.style.zoom!="undefined"&&(p.innerHTML="",p.style.width=p.style.padding="1px",p.style.border=0,p.style.overflow="hidden",p.style.display="inline",p.style.zoom=1,b.inlineBlockNeedsLayout=p.offsetWidth===3,p.style.display="block",p.style.overflow="visible",p.innerHTML="
    ",b.shrinkWrapBlocks=p.offsetWidth!==3),p.style.cssText=r+s,p.innerHTML=q,e=p.firstChild,g=e.firstChild,i=e.nextSibling.firstChild.firstChild,j={doesNotAddBorder:g.offsetTop!==5,doesAddBorderForTableAndCells:i.offsetTop===5},g.style.position="fixed",g.style.top="20px",j.fixedPosition=g.offsetTop===20||g.offsetTop===15,g.style.position=g.style.top="",e.style.overflow="hidden",e.style.position="relative",j.subtractsBorderForOverflowNotVisible=g.offsetTop===-5,j.doesNotIncludeMarginInBodyOffset=u.offsetTop!==m,a.getComputedStyle&&(p.style.marginTop="1%",b.pixelMargin=(a.getComputedStyle(p,null)||{marginTop:0}).marginTop!=="1%"),typeof d.style.zoom!="undefined"&&(d.style.zoom=1),u.removeChild(d),l=p=d=null,f.extend(b,j))});return b}();var j=/^(?:\{.*\}|\[.*\])$/,k=/([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&&!m(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[j]:a[j]&&j,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[j]=n=++f.uuid:n=j),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d);if(o&&!h[c])return g.events;k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h;return i}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[h]:h;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)||(b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" ")));for(e=0,g=b.length;e1,null,!1)},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,b){a&&(b=(b||"fx")+"mark",f._data(a,b,(f._data(a,b)||0)+1))},_unmark:function(a,b,c){a!==!0&&(c=b,b=a,a=!1);if(b){c=c||"fx";var d=c+"mark",e=a?0:(f._data(b,d)||1)-1;e?f._data(b,d,e):(f.removeData(b,d,!0),n(b,c,"mark"))}},queue:function(a,b,c){var d;if(a){b=(b||"fx")+"queue",d=f._data(a,b),c&&(!d||f.isArray(c)?d=f._data(a,b,f.makeArray(c)):d.push(c));return d||[]}},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e={};d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),f._data(a,b+".run",e),d.call(a,function(){f.dequeue(a,b)},e)),c.length||(f.removeData(a,b+"queue "+b+".run",!0),n(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){var d=2;typeof a!="string"&&(c=a,a="fx",d--);if(arguments.length1)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,f.prop,a,b,arguments.length>1)},removeProp:function(a){a=f.propFix[a]||a;return this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,g,h,i;if(f.isFunction(a))return this.each(function(b){f(this).addClass(a.call(this,b,this.className))});if(a&&typeof a=="string"){b=a.split(p);for(c=0,d=this.length;c-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];{if(!!arguments.length){e=f.isFunction(a);return this.each(function(d){var g=f(this),h;if(this.nodeType===1){e?h=a.call(this,d,g.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.type]||f.valHooks[this.nodeName.toLowerCase()];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}if(g){c=f.valHooks[g.type]||f.valHooks[g.nodeName.toLowerCase()];if(c&&"get"in c&&(d=c.get(g,"value"))!==b)return d;d=g.value;return typeof d=="string"?d.replace(q,""):d==null?"":d}}}}),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,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;c=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},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!!a&&j!==3&&j!==8&&j!==2){if(e&&c in f.attrFn)return f(a)[c](d);if(typeof a.getAttribute=="undefined")return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return}if(h&&"set"in h&&i&&(g=h.set(a,d,c))!==b)return g;a.setAttribute(c,""+d);return d}if(h&&"get"in h&&i&&(g=h.get(a,c))!==null)return g;g=a.getAttribute(c);return g===null?b:g}},removeAttr:function(a,b){var c,d,e,g,h,i=0;if(b&&a.nodeType===1){d=b.toLowerCase().split(p),g=d.length;for(;i=0}})});var z=/^(?:textarea|input|select)$/i,A=/^([^\.]*)?(?:\.(.+))?$/,B=/(?:^|\s)hover(\.\S+)?\b/,C=/^key/,D=/^(?:mouse|contextmenu)|click/,E=/^(?:focusinfocus|focusoutblur)$/,F=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,G=function( +a){var b=F.exec(a);b&&(b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)"));return b},H=function(a,b){var c=a.attributes||{};return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||(c.id||{}).value===b[2])&&(!b[3]||b[3].test((c["class"]||{}).value))},I=function(a){return f.event.special.hover?a:a.replace(B,"mouseenter$1 mouseleave$1")};f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(!(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))){d.handler&&(p=d,d=p.handler,g=p.selector),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.dispatch.apply(i.elem,arguments):b},i.elem=a),c=f.trim(I(c)).split(" ");for(k=0;k=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"";if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,m=E.test(s+h)?e:e.parentNode,n=null;for(;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;le&&j.push({elem:this,matches:d.slice(e)});for(k=0;k0?this.on(b,null,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),C.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),D.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function x(a,b,c,e,f,g){for(var h=0,i=e.length;h0){k=j;break}}j=j[a]}e[h]=k}}}function w(a,b,c,e,f,g){for(var h=0,i=e.length;h+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){i=!1;return 0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length===1&&(w[0]==="~"||w[0]==="+")&&d.parentNode?d.parentNode:d,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);l&&(m(l,h,e,f),m.uniqueSort(e));return e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.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(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.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]&&m.error(a[0]);a[0]=e++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),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]=m(b[3],null,null,c);else{var g=m.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(o.match.POS.test(b[0])||o.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!!m(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=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([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&&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=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null: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=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));o.match.globalPOS=p;var s=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(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.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:[]}},o.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&&(o.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")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

    ";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[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}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.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 m(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;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h0)for(h=g;h=0:f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h=1;while(g&&g.ownerDocument&&g!==b){for(d=0;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)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));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(S(c[0])||S(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);L.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!R[a]?f.unique(e):e,(this.length>1||N.test(d))&&M.test(a)&&(e=e.reverse());return this.pushStack(e,a,P.call(arguments).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 V="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/]","i"),bd=/checked\s*(?:[^=]|=\s*.checked.)/i,be=/\/(java|ecma)script/i,bf=/^\s*",""],legend:[1,"
    ","
    "],thead:[1,"","
    "],tr:[2,"","
    "],td:[3,"","
    "],col:[2,"","
    "],area:[1,"",""],_default:[0,"",""]},bh=U(c);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){return f.access(this,function(a){return a===b?f.text(this):this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a))},null,a,arguments.length)},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){var b=f.isFunction(a);return this.each(function(c){f(this).wrapAll(b?a.call(this,c):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 +.clean(arguments);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.clean(arguments));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){return f.access(this,function(a){var c=this[0]||{},d=0,e=this.length;if(a===b)return c.nodeType===1?c.innerHTML.replace(W,""):null;if(typeof a=="string"&&!ba.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!bg[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$1>");try{for(;d1&&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,e,g,h=f.support.html5Clone||f.isXMLDoc(a)||!bc.test("<"+a.nodeName+">")?a.cloneNode(!0):bo(a);if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bk(a,h),d=bl(a),e=bl(h);for(g=0;d[g];++g)e[g]&&bk(d[g],e[g])}if(b){bj(a,h);if(c){d=bl(a),e=bl(h);for(g=0;d[g];++g)bj(d[g],e[g])}}d=e=null;return h},clean:function(a,b,d,e){var g,h,i,j=[];b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);for(var k=0,l;(l=a[k])!=null;k++){typeof l=="number"&&(l+="");if(!l)continue;if(typeof l=="string")if(!_.test(l))l=b.createTextNode(l);else{l=l.replace(Y,"<$1>");var m=(Z.exec(l)||["",""])[1].toLowerCase(),n=bg[m]||bg._default,o=n[0],p=b.createElement("div"),q=bh.childNodes,r;b===c?bh.appendChild(p):U(b).appendChild(p),p.innerHTML=n[1]+l+n[2];while(o--)p=p.lastChild;if(!f.support.tbody){var s=$.test(l),t=m==="table"&&!s?p.firstChild&&p.firstChild.childNodes:n[1]===""&&!s?p.childNodes:[];for(i=t.length-1;i>=0;--i)f.nodeName(t[i],"tbody")&&!t[i].childNodes.length&&t[i].parentNode.removeChild(t[i])}!f.support.leadingWhitespace&&X.test(l)&&p.insertBefore(b.createTextNode(X.exec(l)[0]),p.firstChild),l=p.childNodes,p&&(p.parentNode.removeChild(p),q.length>0&&(r=q[q.length-1],r&&r.parentNode&&r.parentNode.removeChild(r)))}var u;if(!f.support.appendChecked)if(l[0]&&typeof (u=l.length)=="number")for(i=0;i1)},f.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=by(a,"opacity");return c===""?"1":c}return a.style.opacity}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":f.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!!a&&a.nodeType!==3&&a.nodeType!==8&&!!a.style){var g,h,i=f.camelCase(c),j=a.style,k=f.cssHooks[i];c=f.cssProps[i]||i;if(d===b){if(k&&"get"in k&&(g=k.get(a,!1,e))!==b)return g;return j[c]}h=typeof d,h==="string"&&(g=bu.exec(d))&&(d=+(g[1]+1)*+g[2]+parseFloat(f.css(a,c)),h="number");if(d==null||h==="number"&&isNaN(d))return;h==="number"&&!f.cssNumber[i]&&(d+="px");if(!k||!("set"in k)||(d=k.set(a,d))!==b)try{j[c]=d}catch(l){}}},css:function(a,c,d){var e,g;c=f.camelCase(c),g=f.cssHooks[c],c=f.cssProps[c]||c,c==="cssFloat"&&(c="float");if(g&&"get"in g&&(e=g.get(a,!0,d))!==b)return e;if(by)return by(a,c)},swap:function(a,b,c){var d={},e,f;for(f in b)d[f]=a.style[f],a.style[f]=b[f];e=c.call(a);for(f in b)a.style[f]=d[f];return e}}),f.curCSS=f.css,c.defaultView&&c.defaultView.getComputedStyle&&(bz=function(a,b){var c,d,e,g,h=a.style;b=b.replace(br,"-$1").toLowerCase(),(d=a.ownerDocument.defaultView)&&(e=d.getComputedStyle(a,null))&&(c=e.getPropertyValue(b),c===""&&!f.contains(a.ownerDocument.documentElement,a)&&(c=f.style(a,b))),!f.support.pixelMargin&&e&&bv.test(b)&&bt.test(c)&&(g=h.width,h.width=c,c=e.width,h.width=g);return c}),c.documentElement.currentStyle&&(bA=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;f==null&&g&&(e=g[b])&&(f=e),bt.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d));return f===""?"auto":f}),by=bz||bA,f.each(["height","width"],function(a,b){f.cssHooks[b]={get:function(a,c,d){if(c)return a.offsetWidth!==0?bB(a,b,d):f.swap(a,bw,function(){return bB(a,b,d)})},set:function(a,b){return bs.test(b)?b+"px":b}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return bq.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,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bp,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bp.test(g)?g.replace(bp,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){return f.swap(a,{display:"inline-block"},function(){return b?by(a,"margin-right"):a.style.marginRight})}})}),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&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)}),f.each({margin:"",padding:"",border:"Width"},function(a,b){f.cssHooks[a+b]={expand:function(c){var d,e=typeof c=="string"?c.split(" "):[c],f={};for(d=0;d<4;d++)f[a+bx[d]+b]=e[d]||e[d-2]||e[0];return f}}});var bC=/%20/g,bD=/\[\]$/,bE=/\r?\n/g,bF=/#.*$/,bG=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bH=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bI=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bJ=/^(?:GET|HEAD)$/,bK=/^\/\//,bL=/\?/,bM=/)<[^<]*)*<\/script>/gi,bN=/^(?:select|textarea)/i,bO=/\s+/,bP=/([?&])_=[^&]*/,bQ=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bR=f.fn.load,bS={},bT={},bU,bV,bW=["*/"]+["*"];try{bU=e.href}catch(bX){bU=c.createElement("a"),bU.href="",bU=bU.href}bV=bQ.exec(bU.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bR)return bR.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(bM,"")).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||bN.test(this.nodeName)||bH.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(bE,"\r\n")}}):{name:b.name,value:c.replace(bE,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.on(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?b$(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),b$(a,b);return a},ajaxSettings:{url:bU,isLocal:bI.test(bV[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":bW},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},flatOptions:{context:!0,url:!0}},ajaxPrefilter:bY(bS),ajaxTransport:bY(bT),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>0?4:0;var o,r,u,w=c,x=l?ca(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=cb(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),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.Callbacks("once memory"),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=bG.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.add,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(bF,"").replace(bK,bV[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bO),d.crossDomain==null&&(r=bQ.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bV[1]&&r[2]==bV[2]&&(r[3]||(r[1]==="http:"?80:443))==(bV[3]||(bV[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),bZ(bS,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bJ.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bL.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bP,"$1_="+x);d.url=y+(y===d.url?(bL.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]!=="*"?", "+bW+"; 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=bZ(bT,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){if(s<2)w(-1,z);else throw 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(bC,"+")}}),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=typeof b.data=="string"&&/^application\/x\-www\-form\-urlencoded/.test(b.contentType);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);try{m.text=h.responseText}catch(a){}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;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(ct("show",3),a,b,c);for(var g=0,h=this.length;g=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c-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({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,c){var d=/Y/.test(c);f.fn[a]=function(e){return f.access(this,function(a,e,g){var h=cy(a);if(g===b)return h?c in h?h[c]:f.support.boxModel&&h.document.documentElement[e]||h.document.body[e]:a[e];h?h.scrollTo(d?f(h).scrollLeft():g,d?g:f(h).scrollTop()):a[e]=g},a,e,arguments.length,null)}}),f.each({Height:"height",Width:"width"},function(a,c){var d="client"+a,e="scroll"+a,g="offset"+a;f.fn["inner"+a]=function(){var a=this[0];return a?a.style?parseFloat(f.css(a,c,"padding")):this[c]():null},f.fn["outer"+a]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,c,a?"margin":"border")):this[c]():null},f.fn[c]=function(a){return f.access(this,function(a,c,h){var i,j,k,l;if(f.isWindow(a)){i=a.document,j=i.documentElement[d];return f.support.boxModel&&j||i.body&&i.body[d]||j}if(a.nodeType===9){i=a.documentElement;if(i[d]>=i[e])return i[d];return Math.max(a.body[e],i[e],a.body[g],i[g])}if(h===b){k=f.css(a,c),l=parseFloat(k);return f.isNumeric(l)?l:k}f(a).css(c,h)},c,a,arguments.length,null)}}),a.jQuery=a.$=f,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return f})})(window); \ No newline at end of file diff --git a/jquery-1.7.min.js b/jquery-1.7.min.js deleted file mode 100644 index 3ca5e0f5..00000000 --- a/jquery-1.7.min.js +++ /dev/null @@ -1,4 +0,0 @@ -/*! jQuery v1.7 jquery.com | jquery.org/license */ -(function(a,b){function cA(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cx(a){if(!cm[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){cn||(cn=c.createElement("iframe"),cn.frameBorder=cn.width=cn.height=0),b.appendChild(cn);if(!co||!cn.createElement)co=(cn.contentWindow||cn.contentDocument).document,co.write((c.compatMode==="CSS1Compat"?"":"")+""),co.close();d=co.createElement(a),co.body.appendChild(d),e=f.css(d,"display"),b.removeChild(cn)}cm[a]=e}return cm[a]}function cw(a,b){var c={};f.each(cs.concat.apply([],cs.slice(0,b)),function(){c[this]=a});return c}function cv(){ct=b}function cu(){setTimeout(cv,0);return ct=f.now()}function cl(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ck(){try{return new a.XMLHttpRequest}catch(b){}}function ce(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;g0){c!=="border"&&f.each(e,function(){c||(d-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?d+=parseFloat(f.css(a,c+this))||0:d-=parseFloat(f.css(a,"border"+this+"Width"))||0});return d+"px"}d=bB(a,b,b);if(d<0||d==null)d=a.style[b]||0;d=parseFloat(d)||0,c&&f.each(e,function(){d+=parseFloat(f.css(a,"padding"+this))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+this+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+this))||0)});return d+"px"}function br(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(bi,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bq(a){var b=(a.nodeName||"").toLowerCase();b==="input"?bp(a):b!=="script"&&typeof a.getElementsByTagName!="undefined"&&f.grep(a.getElementsByTagName("input"),bp)}function bp(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bo(a){return typeof a.getElementsByTagName!="undefined"?a.getElementsByTagName("*"):typeof a.querySelectorAll!="undefined"?a.querySelectorAll("*"):[]}function bn(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bm(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c,d,e,g=f._data(a),h=f._data(b,g),i=g.events;if(i){delete h.handle,h.events={};for(c in i)for(d=0,e=i[c].length;d=0===c})}function V(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function N(){return!0}function M(){return!1}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?parseFloat(d):j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c)[^>]*$|#([\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=/-([a-z]|[0-9])/ig,x=/^-ms-/,y=function(a,b){return(b+"").toUpperCase()},z=d.userAgent,A,B,C,D=Object.prototype.toString,E=Object.prototype.hasOwnProperty,F=Array.prototype.push,G=Array.prototype.slice,H=String.prototype.trim,I=Array.prototype.indexOf,J={};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.7",length:0,size:function(){return this.length},toArray:function(){return G.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)?F.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(),B.add(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(G.apply(this,arguments),"slice",G.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:F,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;B.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!B){B=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",C,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",C),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&K()}}},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},isNumeric:function(a){return a!=null&&m.test(a)&&!isNaN(a)},type:function(a){return a==null?String(a):J[D.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!E.call(a,"constructor")&&!E.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||E.call(a,d)},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(c){var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(x,"ms-").replace(w,y)},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?i.call(arguments,0):b,j.notifyWith(k,e)}}function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}var b=i.call(arguments,0),c=0,d=b.length,e=Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c
    a",d=a.getElementsByTagName("*"),e=a.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=a.getElementsByTagName("input")[0],k={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,unknownElems:!!a.getElementsByTagName("nav").length,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:a.className!=="t",enctype:!!c.createElement("form").enctype,submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,k.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,k.optDisabled=!h.disabled;try{delete a.test}catch(v){k.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function(){k.noCloneEvent=!1}),a.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),k.radioValue=i.value==="t",i.setAttribute("checked","checked"),a.appendChild(i),l=c.createDocumentFragment(),l.appendChild(a.lastChild),k.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",m=c.getElementsByTagName("body")[0],o=c.createElement(m?"div":"body"),p={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"},m&&f.extend(p,{position:"absolute",left:"-999px",top:"-999px"});for(t in p)o.style[t]=p[t];o.appendChild(a),n=m||b,n.insertBefore(o,n.firstChild),k.appendChecked=i.checked,k.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,k.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="
    ",k.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="
    t
    ",q=a.getElementsByTagName("td"),u=q[0].offsetHeight===0,q[0].style.display="",q[1].style.display="none",k.reliableHiddenOffsets=u&&q[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",a.appendChild(j),k.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0);if(a.attachEvent)for(t in{submit:1,change:1,focusin:1})s="on"+t,u=s in a,u||(a.setAttribute(s,"return;"),u=typeof a[s]=="function"),k[t+"Bubbles"]=u;f(function(){var a,b,d,e,g,h,i=1,j="position:absolute;top:0;left:0;width:1px;height:1px;margin:0;",l="visibility:hidden;border:0;",n="style='"+j+"border:5px solid #000;padding:0;'",p="
    "+""+"
    ";m=c.getElementsByTagName("body")[0];!m||(a=c.createElement("div"),a.style.cssText=l+"width:0;height:0;position:static;top:0;margin-top:"+i+"px",m.insertBefore(a,m.firstChild),o=c.createElement("div"),o.style.cssText=j+l,o.innerHTML=p,a.appendChild(o),b=o.firstChild,d=b.firstChild,g=b.nextSibling.firstChild.firstChild,h={doesNotAddBorder:d.offsetTop!==5,doesAddBorderForTableAndCells:g.offsetTop===5},d.style.position="fixed",d.style.top="20px",h.fixedPosition=d.offsetTop===20||d.offsetTop===15,d.style.position=d.style.top="",b.style.overflow="hidden",b.style.position="relative",h.subtractsBorderForOverflowNotVisible=d.offsetTop===-5,h.doesNotIncludeMarginInBodyOffset=m.offsetTop!==i,m.removeChild(a),o=a=null,f.extend(k,h))}),o.innerHTML="",n.removeChild(o),o=l=g=h=m=j=a=i=null;return k}(),f.boxModel=f.support.boxModel;var j=/^(?:\{.*\}|\[.*\])$/,k=/([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&&!m(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[f.expando]:a[f.expando]&&f.expando,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[f.expando]=n=++f.uuid:n=f.expando),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d);if(o&&!h[c])return g.events;k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h;return i}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[f.expando]:f.expando;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)?b=b:b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" "));for(e=0,g=b.length;e-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];if(!arguments.length){if(g){c=f.valHooks[g.nodeName.toLowerCase()]||f.valHooks[g.type];if(c&&"get"in c&&(d=c.get(g,"value"))!==b)return d;d=g.value;return typeof d=="string"?d.replace(q,""):d==null?"":d}return b}e=f.isFunction(a);return this.each(function(d){var g=f(this),h;if(this.nodeType===1){e?h=a.call(this,d,g.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,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;c=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},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!a||j===3||j===8||j===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);if(!("getAttribute"in a))return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return b}if(h&&"set"in h&&i&&(g=h.set(a,d,c))!==b)return g;a.setAttribute(c,""+d);return d}if(h&&"get"in h&&i&&(g=h.get(a,c))!==null)return g;g=a.getAttribute(c);return g===null?b:g},removeAttr:function(a,b){var c,d,e,g,h=0;if(a.nodeType===1){d=(b||"").split(p),g=d.length;for(;h=0}})});var z=/\.(.*)$/,A=/^(?:textarea|input|select)$/i,B=/\./g,C=/ /g,D=/[^\w\s.|`]/g,E=/^([^\.]*)?(?:\.(.+))?$/,F=/\bhover(\.\S+)?/,G=/^key/,H=/^(?:mouse|contextmenu)|click/,I=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,J=function(a){var b=I.exec(a);b&& -(b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)"));return b},K=function(a,b){return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||a.id===b[2])&&(!b[3]||b[3].test(a.className))},L=function(a){return f.event.special.hover?a:a.replace(F,"mouseenter$1 mouseleave$1")};f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(!(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))){d.handler&&(p=d,d=p.handler),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.dispatch.apply(i.elem,arguments):b},i.elem=a),c=L(c).split(" ");for(k=0;k=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"",(g||!e)&&c.preventDefault();if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,n=null;for(m=e.parentNode;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;l=0:t===b&&(t=o[s]=r.quick?K(m,r.quick):f(m).is(s)),t&&q.push(r);q.length&&j.push({elem:m,matches:q})}d.length>e&&j.push({elem:this,matches:d.slice(e)});for(k=0;k0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),G.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),H.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function x(a,b,c,e,f,g){for(var h=0,i=e.length;h0){k=j;break}}j=j[a]}e[h]=k}}}function w(a,b,c,e,f,g){for(var h=0,i=e.length;h+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){i=!1;return 0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length===1&&(w[0]==="~"||w[0]==="+")&&d.parentNode?d.parentNode:d,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);l&&(m(l,h,e,f),m.uniqueSort(e));return e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.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(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.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]&&m.error(a[0]);a[0]=e++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),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]=m(b[3],null,null,c);else{var g=m.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(o.match.POS.test(b[0])||o.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!!m(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=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([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&&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=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null: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=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));var s=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(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.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:[]}},o.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&&(o.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")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

    ";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[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}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.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 m(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;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h0)for(h=g;h=0:f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h=1;while(g&&g.ownerDocument&&g!==b){for(d=0;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)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));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(V(c[0])||V(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=S.call(arguments);O.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!U[a]?f.unique(e):e,(this.length>1||Q.test(d))&&P.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="abbr article aside audio canvas datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video",Z=/ jQuery\d+="(?:\d+|null)"/g,$=/^\s+/,_=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,ba=/<([\w:]+)/,bb=/",""],legend:[1,"
    ","
    "],thead:[1,"","
    "],tr:[2,"","
    "],td:[3,"","
    "],col:[2,"","
    "],area:[1,"",""],_default:[0,"",""]},bk=X(c);bj.optgroup=bj.option,bj.tbody=bj.tfoot=bj.colgroup=bj.caption=bj.thead,bj.th=bj.td,f.support.htmlSerialize||(bj._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(Z,""):null;if(typeof a=="string"&&!bd.test(a)&&(f.support.leadingWhitespace||!$.test(a))&&!bj[(ba.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)){bn(a,d),e=bo(a),g=bo(d);for(h=0;e[h];++h)g[h]&&bn(e[h],g[h])}if(b){bm(a,d);if(c){e=bo(a),g=bo(d);for(h=0;e[h];++h)bm(e[h],g[h])}}e=g=null;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(!bc.test(k))k=b.createTextNode(k);else{k=k.replace(_,"<$1>");var l=(ba.exec(k)||["",""])[1].toLowerCase(),m=bj[l]||bj._default,n=m[0],o=b.createElement("div");b===c?bk.appendChild(o):X(b).appendChild(o),o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=bb.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&&$.test(k)&&o.insertBefore(b.createTextNode($.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 bt.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,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bs,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bs.test(g)?g.replace(bs,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=bB(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bC=function(a,c){var d,e,g;c=c.replace(bu,"-$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&&(bD=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;f===null&&g&&(e=g[b])&&(f=e),!bv.test(f)&&bw.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f||0,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d));return f===""?"auto":f}),bB=bC||bD,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&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bF=/%20/g,bG=/\[\]$/,bH=/\r?\n/g,bI=/#.*$/,bJ=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bK=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bL=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bM=/^(?:GET|HEAD)$/,bN=/^\/\//,bO=/\?/,bP=/)<[^<]*)*<\/script>/gi,bQ=/^(?:select|textarea)/i,bR=/\s+/,bS=/([?&])_=[^&]*/,bT=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bU=f.fn.load,bV={},bW={},bX,bY,bZ=["*/"]+["*"];try{bX=e.href}catch(b$){bX=c.createElement("a"),bX.href="",bX=bX.href}bY=bT.exec(bX.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bU)return bU.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(bP,"")).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||bQ.test(this.nodeName)||bK.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(bH,"\r\n")}}):{name:b.name,value:c.replace(bH,"\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?cb(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),cb(a,b);return a},ajaxSettings:{url:bX,isLocal:bL.test(bY[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","*":bZ},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},flatOptions:{context:!0,url:!0}},ajaxPrefilter:b_(bV),ajaxTransport:b_(bW),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>0?4:0;var o,r,u,w=c,x=l?cd(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=ce(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),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.Callbacks("once memory"),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=bJ.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.add,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(bI,"").replace(bN,bY[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bR),d.crossDomain==null&&(r=bT.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bY[1]&&r[2]==bY[2]&&(r[3]||(r[1]==="http:"?80:443))==(bY[3]||(bY[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),ca(bV,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bM.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bO.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bS,"$1_="+x);d.url=y+(y===d.url?(bO.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]!=="*"?", "+bZ+"; 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=ca(bW,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){s<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)cc(g,a[g],c,e);return d.join("&").replace(bF,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cf=f.now(),cg=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cf++}}),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&&(cg.test(b.url)||e&&cg.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(cg,l),b.url===j&&(e&&(k=k.replace(cg,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 ch=a.ActiveXObject?function(){for(var a in cj)cj[a](0,1)}:!1,ci=0,cj;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ck()||cl()}:ck,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,ch&&delete cj[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=++ci,ch&&(cj||(cj={},f(a).unload(ch)),cj[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cm={},cn,co,cp=/^(?:toggle|show|hide)$/,cq=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cr,cs=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],ct;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cw("show",3),a,b,c);for(var g=0,h=this.length;g=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c-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=cz.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&&!cz.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=cA(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=cA(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(){var a=this[0];return a?a.style?parseFloat(f.css(a,d,"padding")):this[d]():null},f.fn["outer"+c]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,d,a?"margin":"border")):this[d]():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],h=e.document.body;return e.document.compatMode==="CSS1Compat"&&g||h&&h["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 i=f.css(e,d),j=parseFloat(i);return f.isNumeric(j)?j: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/test/index.html b/test/index.html index baf331fc..8a7ff2fd 100644 --- a/test/index.html +++ b/test/index.html @@ -7,7 +7,7 @@ - + From c4fd50d8a4da24e1d198a755c8d30d8640f889a7 Mon Sep 17 00:00:00 2001 From: Shawphy Date: Wed, 22 Aug 2012 01:28:32 +0800 Subject: [PATCH 118/169] fix the path of JS files in boilerplate.html --- boilerplate.html | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/boilerplate.html b/boilerplate.html index 9b76d948..88d9ea32 100644 --- a/boilerplate.html +++ b/boilerplate.html @@ -78,13 +78,13 @@

    Here

    - - - - - - - + + + + + + + diff --git a/core/deck.core.css b/core/deck.core.css index 26d58e86..fa4c3717 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -62,101 +62,3 @@ body.deck-container { .deck-child-current .deck-previous, .deck-child-current .deck-before, .deck-child-current .deck-current { visibility: visible; } - -@media print { - * { - background: transparent !important; - color: black !important; - text-shadow: none !important; - filter: none !important; - -ms-filter: none !important; - -webkit-box-reflect: none !important; - -moz-box-reflect: none !important; - -webkit-box-shadow: none !important; - -moz-box-shadow: none !important; - box-shadow: none !important; - } - * :before, * :after { - display: none !important; - } - - a, a:visited { - color: #444 !important; - text-decoration: underline; - } - - a[href]:after { - content: " (" attr(href) ")"; - } - - abbr[title]:after { - content: " (" attr(title) ")"; - } - - .ir a:after, a[href^="javascript:"]:after, a[href^="#"]:after { - content: ""; - } - - pre, blockquote { - border: 1px solid #999; - page-break-inside: avoid; - } - - thead { - display: table-header-group; - } - - tr, img { - page-break-inside: avoid; - } - - @page { - margin: 0.5cm; -} - - p, h2, h3 { - orphans: 3; - widows: 3; - } - - h2, h3 { - page-break-after: avoid; - } - - .slide { - position: static !important; - visibility: visible !important; - display: block !important; - -webkit-transform: none !important; - -moz-transform: none !important; - -o-transform: none !important; - -ms-transform: none !important; - transform: none !important; - opacity: 1 !important; - } - - h1, .vcenter { - -webkit-transform: none !important; - -moz-transform: none !important; - -o-transform: none !important; - -ms-transform: none !important; - transform: none !important; - padding: 0 !important; - position: static !important; - } - - .deck-container > .slide { - page-break-after: always; - } - - .deck-container { - width: 100% !important; - height: auto !important; - padding: 0 !important; - display: block !important; - } - - script { - display: none; - } -} diff --git a/core/deck.core.scss b/core/deck.core.scss index 5ee2282f..cfa2d9d3 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -66,70 +66,4 @@ body.deck-container { .deck-previous, .deck-before, .deck-current { visibility:visible; } -} - -@media print { - * { - background: transparent !important; - color: black !important; - text-shadow: none !important; - filter:none !important; - -ms-filter: none !important; - -webkit-box-reflect:none !important; - -moz-box-reflect:none !important; - -webkit-box-shadow:none !important; - -moz-box-shadow:none !important; - box-shadow:none !important; - - :before, :after { - display:none !important; - } -} - a, a:visited { color: #444 !important; text-decoration: underline; } - a[href]:after { content: " (" attr(href) ")"; } - abbr[title]:after { content: " (" attr(title) ")"; } - .ir a:after, a[href^="javascript:"]:after, a[href^="#"]:after { content: ""; } - pre, blockquote { border: 1px solid #999; page-break-inside: avoid; } - thead { display: table-header-group; } - tr, img { page-break-inside: avoid; } - @page { margin: 0.5cm; } - p, h2, h3 { orphans: 3; widows: 3; } - h2, h3{ page-break-after: avoid; } - - .slide { - position:static !important; - visibility:visible !important; - display:block !important; - -webkit-transform:none !important; - -moz-transform:none !important; - -o-transform:none !important; - -ms-transform:none !important; - transform:none !important; - opacity:1 !important; - } - - h1, .vcenter { - -webkit-transform:none !important; - -moz-transform:none !important; - -o-transform:none !important; - -ms-transform:none !important; - transform:none !important; - padding:0 !important; - position:static !important; - } - - .deck-container > .slide { - page-break-after: always; - } - - .deck-container { - width:100% !important; - height:auto !important; - padding:0 !important; - display:block !important; - } - - script { - display:none; - } -} +} \ No newline at end of file diff --git a/core/print.css b/core/print.css new file mode 100644 index 00000000..0230f4c1 --- /dev/null +++ b/core/print.css @@ -0,0 +1,25 @@ +body { + font-size: 18pt; +} + +h1 { + font-size: 48pt; +} + +h2 { + font-size: 36pt; +} + +h3 { + font-size: 28pt; +} + +pre { + border: 1px solid #000; + padding: 10px; + white-space: pre-wrap; +} + +.deck-container > .slide { + page-break-after: always; +} diff --git a/core/print.scss b/core/print.scss new file mode 100644 index 00000000..02acd4bf --- /dev/null +++ b/core/print.scss @@ -0,0 +1,14 @@ +body { font-size:18pt; } +h1 { font-size:48pt; } +h2 { font-size:36pt; } +h3 { font-size:28pt; } + +pre { + border:1px solid #000; + padding:10px; + white-space:pre-wrap; +} + +.deck-container > .slide { + page-break-after: always; +} diff --git a/introduction/index.html b/introduction/index.html index 71d7c044..135d6787 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -6,28 +6,31 @@ - + Codestin Search App - + - + - - - - - - - - + + + + + + + + - - + + - - + + + + + @@ -87,12 +90,12 @@

    Transition Themes

    Extensions

    Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

    - +
    • deck.goto: Adds a shortcut key to jump to any slide number. Hit g, type in the slide number, and hit enter.
    • - +
    • deck.hash: Enables internal linking within slides, deep linking to individual slides, and updates the address bar & a permalink anchor with each slide change.
    • @@ -113,7 +116,7 @@

      Extensions

      deck.scale: Scales each slide to fit within the deck container using CSS Transforms for those browsers that support them.
    - +

    Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    @@ -122,13 +125,13 @@

    Nested Slides

    That last slide had a few steps. To create substeps in slides, just nest them:

    <section class="slide">
       <h2>Extensions</h2>
    -  <p>Core gives you basic slide functionality...</p>		
    +  <p>Core gives you basic slide functionality...</p>
       <ul>
          <li class="slide">
             <h3>deck.goto</h3>
             <p>Adds a shortcut key to jump to any slide number...</p>
          </li>
    -     <li class="slide">...</li>	
    +     <li class="slide">...</li>
          <li class="slide">...</li>
          <li class="slide">...</li>
       </ul>
    @@ -157,9 +160,9 @@ 

    Other Elements: Blockquotes

    Other Elements: Video Embeds

    Embed videos from your favorite online video service or with an HTML5 video element.

    - + - +
    <iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
    From 35dba7dc96cd39306af538151235d161ce86dbf7 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 7 Nov 2013 11:50:50 -0800 Subject: [PATCH 133/169] Bring attention to the boilerplate in the intro deck, #133 --- introduction/index.html | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/introduction/index.html b/introduction/index.html index 135d6787..edadf881 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -59,6 +59,11 @@

    Include Extensions

    +
    +

    Quick Start

    +

    When you download deck.js, it will include a file named boilerplate.html. You can immediately start editing slides in this page and viewing them in your web browser. Later on, when you are comfortable customizing the deck, you can edit the various pieces of the boilerplate or make your own to suit your needs.

    +
    +

    The Markup

    Slides are just HTML elements with a class of slide.

    From df65f55821378267b1e1407811fbebf3820abbd0 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 7 Nov 2013 14:15:21 -0800 Subject: [PATCH 134/169] Fix #115, end use of body as deck container --- boilerplate.html | 68 +++---- core/deck.core.css | 6 +- core/deck.core.scss | 6 +- extensions/scale/deck.scale.css | 3 + extensions/scale/deck.scale.scss | 4 +- introduction/index.html | 329 ++++++++++++++++--------------- 6 files changed, 207 insertions(+), 209 deletions(-) diff --git a/boilerplate.html b/boilerplate.html index e16b14af..44c53645 100644 --- a/boilerplate.html +++ b/boilerplate.html @@ -30,51 +30,51 @@ - + +
    - + -
    -

    Slide

    -
    +
    +

    Slide

    +
    -
    -

    Content

    -
    +
    +

    Content

    +
    -
    -

    Here

    -
    +
    +

    Here

    +
    - + + - + + + - - - + +

    + + / + +

    - -

    - - / - -

    + +
    + + + + + - -
    - - - - - - - -# - - + + # + +
    diff --git a/core/deck.core.css b/core/deck.core.css index fa4c3717..da619cb0 100644 --- a/core/deck.core.css +++ b/core/deck.core.css @@ -4,16 +4,12 @@ html, body { margin: 0; } -body.deck-container { - overflow-y: auto; - position: static; -} - .deck-container { position: relative; min-height: 100%; margin: 0 auto; overflow: hidden; + overflow-y: auto; } .js .deck-container { visibility: hidden; diff --git a/core/deck.core.scss b/core/deck.core.scss index cfa2d9d3..a7e12ffa 100755 --- a/core/deck.core.scss +++ b/core/deck.core.scss @@ -4,16 +4,12 @@ html, body { margin:0; } -body.deck-container { - overflow-y:auto; - position:static; -} - .deck-container { position:relative; min-height:100%; margin:0 auto; overflow:hidden; + overflow-y:auto; .js & { visibility:hidden; diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index d6a4eb0b..b02ed1ad 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -4,6 +4,9 @@ using the scale extension. */ overflow: hidden; } +.csstransforms .deck-container.deck-scale:not(.deck-menu) { + overflow: hidden; +} .csstransforms .deck-container.deck-scale:not(.deck-menu) > .slide { -webkit-box-sizing: padding-box; -moz-box-sizing: padding-box; diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index 2fa08516..9368dd63 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -5,13 +5,15 @@ using the scale extension. */ } .csstransforms .deck-container.deck-scale:not(.deck-menu) { + overflow:hidden; + > .slide { -webkit-box-sizing: padding-box; -moz-box-sizing: padding-box; box-sizing: padding-box; width:100%; padding-bottom:20px; - + > .deck-slide-scaler { -webkit-transform-origin: 50% 0; -moz-transform-origin: 50% 0; diff --git a/introduction/index.html b/introduction/index.html index edadf881..18a2d1f7 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -34,170 +34,171 @@ - - - -
    -

    Getting Started with deck.js

    -
    - -
    -

    How to Make a Deck

    -
      -
    1. -

      Write Slides

      -

      Slide content is simple HTML.

      -
    2. -
    3. -

      Choose Themes

      -

      One for slide styles and one for deck transitions.

      -
    4. -
    5. -

      Include Extensions

      -

      Add extra functionality to your deck, or leave it stripped down.

      -
    6. -
    -
    - -
    -

    Quick Start

    -

    When you download deck.js, it will include a file named boilerplate.html. You can immediately start editing slides in this page and viewing them in your web browser. Later on, when you are comfortable customizing the deck, you can edit the various pieces of the boilerplate or make your own to suit your needs.

    -
    - -
    -

    The Markup

    -

    Slides are just HTML elements with a class of slide.

    -
    <section class="slide">
    -   <h2>How to Make a Deck</h2>
    -   <ol>
    -      <li>
    -         <h3>Write Slides</h3>
    -         <p>Slide content is simple HTML.</p>
    -      </li>
    -      <li>
    -         <h3>Choose Themes</h3>
    -         <p>One for slide styles and one for deck transitions.</p>
    -      </li>
    -      …
    -   </ol>
    -</section>
    -
    - -
    -

    Style Themes

    -

    Customizes the colors, typography, and layout of slide content.

    -
    <link rel="stylesheet" href="/path/to/css/style-theme.css">
    -

    Transition Themes

    -

    Defines transitions between slides using CSS3 transitions. Less capable browsers fall back to cutaways. But you aren’t using those browsers to give your presentations, are you…

    -
    <link rel="stylesheet" href="/path/to/css/transition-theme.css">
    -
    - -
    -

    Extensions

    -

    Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

    - -
      -
    • - deck.goto: Adds a shortcut key to jump to any slide number. Hit g, type in the slide number, and hit enter. -
    • - -
    • - deck.hash: Enables internal linking within slides, deep linking to individual slides, and updates the address bar & a permalink anchor with each slide change. -
    • - -
    • - deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. Touch devices can double-tap the deck to switch between views. -
    • - -
    • - deck.navigation: Adds clickable left and right buttons for the less keyboard inclined. -
    • - -
    • - deck.status: Adds a page number indicator. (current/total) -
    • - -
    • - deck.scale: Scales each slide to fit within the deck container using CSS Transforms for those browsers that support them. -
    • -
    - -

    Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    -
    - -
    -

    Nested Slides

    -

    That last slide had a few steps. To create substeps in slides, just nest them:

    -
    <section class="slide">
    -  <h2>Extensions</h2>
    -  <p>Core gives you basic slide functionality...</p>
    -  <ul>
    -     <li class="slide">
    -        <h3>deck.goto</h3>
    -        <p>Adds a shortcut key to jump to any slide number...</p>
    -     </li>
    -     <li class="slide">...</li>
    -     <li class="slide">...</li>
    -     <li class="slide">...</li>
    -  </ul>
    -</section>
    -
    - -
    -

    Other Elements: Images

    - Kitties -
    <img src="http://placekitten.com/600/375" alt="Kitties">
    -
    - -
    -

    Other Elements: Blockquotes

    -
    -

    Food is an important part of a balanced diet.

    -

    Fran Lebowitz

    -
    -
    <blockquote cite="http://example.org">
    -  <p>Food is an important part of a balanced diet.</p>
    -  <p><cite>Fran Lebowitz</cite></p>
    -</blockquote>
    -
    - - -
    -

    Other Elements: Video Embeds

    -

    Embed videos from your favorite online video service or with an HTML5 video element.

    - - - -
    <iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
    -
    - -
    -

    Digging Deeper

    -

    If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

    -
    - - - - - - -

    - - / - -

    - - -
    - - - - - - - -# - + +
    + + +
    +

    Getting Started with deck.js

    +
    + +
    +

    How to Make a Deck

    +
      +
    1. +

      Write Slides

      +

      Slide content is simple HTML.

      +
    2. +
    3. +

      Choose Themes

      +

      One for slide styles and one for deck transitions.

      +
    4. +
    5. +

      Include Extensions

      +

      Add extra functionality to your deck, or leave it stripped down.

      +
    6. +
    +
    + +
    +

    Quick Start

    +

    When you download deck.js, it will include a file named boilerplate.html. You can immediately start editing slides in this page and viewing them in your web browser. Later on, when you are comfortable customizing the deck, you can edit the various pieces of the boilerplate or make your own to suit your needs.

    +
    + +
    +

    The Markup

    +

    Slides are just HTML elements with a class of slide.

    +
    <section class="slide">
    +       <h2>How to Make a Deck</h2>
    +       <ol>
    +          <li>
    +             <h3>Write Slides</h3>
    +             <p>Slide content is simple HTML.</p>
    +          </li>
    +          <li>
    +             <h3>Choose Themes</h3>
    +             <p>One for slide styles and one for deck transitions.</p>
    +          </li>
    +          …
    +       </ol>
    +    </section>
    +
    + +
    +

    Style Themes

    +

    Customizes the colors, typography, and layout of slide content.

    +
    <link rel="stylesheet" href="/path/to/css/style-theme.css">
    +

    Transition Themes

    +

    Defines transitions between slides using CSS3 transitions. Less capable browsers fall back to cutaways. But you aren’t using those browsers to give your presentations, are you…

    +
    <link rel="stylesheet" href="/path/to/css/transition-theme.css">
    +
    + +
    +

    Extensions

    +

    Core gives you basic slide functionality with left and right arrow navigation, but you may want more. Here are the ones included in this deck:

    + +
      +
    • + deck.goto: Adds a shortcut key to jump to any slide number. Hit g, type in the slide number, and hit enter. +
    • + +
    • + deck.hash: Enables internal linking within slides, deep linking to individual slides, and updates the address bar & a permalink anchor with each slide change. +
    • + +
    • + deck.menu: Adds a menu view, letting you see all slides in a grid. Hit m to toggle to menu view, continue navigating your deck, and hit m to return to normal view. Touch devices can double-tap the deck to switch between views. +
    • + +
    • + deck.navigation: Adds clickable left and right buttons for the less keyboard inclined. +
    • + +
    • + deck.status: Adds a page number indicator. (current/total) +
    • + +
    • + deck.scale: Scales each slide to fit within the deck container using CSS Transforms for those browsers that support them. +
    • +
    + +

    Each extension folder in the download package contains the necessary JavaScript, CSS, and HTML files. For a complete list of extension modules included in deck.js, check out the documentation.

    +
    + +
    +

    Nested Slides

    +

    That last slide had a few steps. To create substeps in slides, just nest them:

    +
    <section class="slide">
    +      <h2>Extensions</h2>
    +      <p>Core gives you basic slide functionality...</p>
    +      <ul>
    +         <li class="slide">
    +            <h3>deck.goto</h3>
    +            <p>Adds a shortcut key to jump to any slide number...</p>
    +         </li>
    +         <li class="slide">...</li>
    +         <li class="slide">...</li>
    +         <li class="slide">...</li>
    +      </ul>
    +    </section>
    +
    + +
    +

    Other Elements: Images

    + Kitties +
    <img src="http://placekitten.com/600/375" alt="Kitties">
    +
    + +
    +

    Other Elements: Blockquotes

    +
    +

    Food is an important part of a balanced diet.

    +

    Fran Lebowitz

    +
    +
    <blockquote cite="http://example.org">
    +      <p>Food is an important part of a balanced diet.</p>
    +      <p><cite>Fran Lebowitz</cite></p>
    +    </blockquote>
    +
    + + +
    +

    Other Elements: Video Embeds

    +

    Embed videos from your favorite online video service or with an HTML5 video element.

    + + + +
    <iframe src="http://player.vimeo.com/video/1063136?title=0&amp;byline=0&amp;portrait=0" width="400" height="225" frameborder="0"></iframe>
    +
    + +
    +

    Digging Deeper

    +

    If you want to learn about making your own themes, extending deck.js, and more, check out the documentation.

    +
    + + + + + + +

    + + / + +

    + + +
    + + + + + + + + # +
    From 08e5d1e0e187c853f13e964049ff010e4087d8ed Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 7 Nov 2013 14:32:34 -0800 Subject: [PATCH 135/169] Clean up tests for removed iframe hack and deferred hash goto call --- test/fixtures/iframe_simple.html | 10 ---- test/fixtures/iframes.html | 32 ------------- test/spec.core.js | 79 +++++++++----------------------- test/spec.hash.js | 28 +++++------ test/spec.navigation.js | 16 ++++--- test/spec.status.js | 14 +++--- 6 files changed, 53 insertions(+), 126 deletions(-) delete mode 100644 test/fixtures/iframe_simple.html delete mode 100644 test/fixtures/iframes.html diff --git a/test/fixtures/iframe_simple.html b/test/fixtures/iframe_simple.html deleted file mode 100644 index a64e9c0a..00000000 --- a/test/fixtures/iframe_simple.html +++ /dev/null @@ -1,10 +0,0 @@ - - - - - Codestin Search App - - -Simple Iframe - - diff --git a/test/fixtures/iframes.html b/test/fixtures/iframes.html deleted file mode 100644 index 016665ee..00000000 --- a/test/fixtures/iframes.html +++ /dev/null @@ -1,32 +0,0 @@ -
    -
    - -
    -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -

    - - / - -

    - -
    - - - - -
    diff --git a/test/spec.core.js b/test/spec.core.js index 9c7866af..6298724f 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -51,7 +51,7 @@ describe('Deck JS', function() { $.deck('go', 5); expect($.deck('getSlide')).toHaveClass('slide1'); }); - + it('should go nowhere if id does not exist', function() { $.deck('go', 'i-dont-exist'); expect($.deck('getSlide')).toHaveClass('slide1'); @@ -123,13 +123,13 @@ describe('Deck JS', function() { expect(slides).toEqual(expectation); }); }); - + describe('getContainer()', function() { it('should return a jQuery object with the container element(s)', function() { expect($.deck('getContainer')).toBe(defaults.selectors.container); }); }); - + describe('getOptions()', function() { it('should return the current options object', function() { expect($.deck('getOptions')).toEqual(defaults); @@ -229,7 +229,7 @@ describe('Deck JS', function() { $d.trigger(e); expect($.deck('getSlide')).toHaveClass('alt-slide1'); }); - + it('should not trigger events that originate within editable elements', function() { var $outside = $('').appendTo('body'); e = jQuery.Event('keydown'); @@ -273,12 +273,12 @@ describe('Deck JS', function() { expect(from).toEqual(1); expect(to).toEqual(3); }; - + $d.bind('deck.change', f); $.deck('go', 3); $d.unbind('deck.change', f); }); - + it('should not change slides if default prevented', function() { $d.bind('deck.change', false); $.deck('go', 3); @@ -286,33 +286,33 @@ describe('Deck JS', function() { $d.unbind('deck.change', false); }); }); - + describe('deck.init', function() { it('should fire on deck initialization', function() { expect('deck.init').toHaveBeenTriggeredOn($d); }); - + it('should have already populated the slides array', function() { var f = function() { expect($.deck('getSlides').length).toBeGreaterThan(0); }; - + $d.bind('deck.init', f); $.deck('.slide'); $d.unbind('deck.init', f); }); }); - + describe('deck.beforeInit', function() { it('should fire on deck initialization', function() { expect('deck.beforeInit').toHaveBeenTriggeredOn($d); }); - + it('should have not populated the slides array', function() { var f = function() { expect($.deck('getSlides').length).toEqual(0); }; - + $d.bind('deck.beforeInit', f); $.deck('.slide'); $d.unbind('deck.beforeInit', f); @@ -320,7 +320,7 @@ describe('Deck JS', function() { }); }); }); - + describe('complex html structure', function() { beforeEach(function() { loadFixtures('complex.html'); @@ -341,43 +341,43 @@ describe('Deck JS', function() { ]); $.deck('go', 2); }); - + describe('compound state classes', function() { it('should apply current class', function() { $('.slide3').each(function(i, el) { expect($(el)).toHaveClass(defaults.classes.current); }); }); - + it('should apply previous class', function() { $('.slide2').each(function(i, el) { expect($(el)).toHaveClass(defaults.classes.previous); }); }); - + it('should apply next class', function() { $('.slide4').each(function(i, el) { expect($(el)).toHaveClass(defaults.classes.next); }); }); - + it('should apply before class', function() { $('.slide1').each(function(i, el) { expect($(el)).toHaveClass(defaults.classes.before); }); }); - + it('should apply after class', function() { $('.slide5, .slide6, .slide7, .slide8, .slide9, .slide10').each(function(i, el) { expect($(el)).toHaveClass(defaults.classes.after); }); }); - + it('should apply child-current class', function() { expect($('.slide2').not('.slide10')).toHaveClass(defaults.classes.childCurrent); }); }); - + it('should remove old state classes', function() { $.deck('go', 4); expect($('.slide3').not('.slide5')).not.toHaveClass(defaults.classes.current); @@ -386,49 +386,12 @@ describe('Deck JS', function() { }); }); - describe('iframes', function() { - beforeEach(function() { - loadFixtures('iframes.html'); - if (Modernizr.history) { - history.replaceState({}, "", "#") - } - $.deck([ - '.slide1', - '.slide2', - '.slide3', - '.slide4', - '.slide5', - '.slide6', - '.slide7', - '.slide8', - '.slide9', - '.slide10', - ]); - - }); - - it('should remove/restore iframe sources when leaving/entering a slide', function() { - $.deck('go', 4); - expect($.deck('getSlide').find('iframe').attr('src')).toEqual('fixtures/iframe_simple.html'); - $.deck('next'); - expect($('.slide5').find('iframe').attr('src')).toEqual(''); - $.deck('prev'); - expect($('.slide5').find('iframe').attr('src')).toEqual('fixtures/iframe_simple.html'); - }); - - it('should not store blank iframe sources', function() { - $.deck('go', 6); - $.deck('next'); - expect($.deck('getSlide').find('iframe').data('src')).toBeUndefined(); - }); - }); - describe('empty deck', function() { beforeEach(function() { loadFixtures('empty.html'); $.deck('.slide'); }); - + describe('getSlide()', function() { it('should not error on init', $.noop); }); diff --git a/test/spec.hash.js b/test/spec.hash.js index c1faafd2..c1746fe9 100644 --- a/test/spec.hash.js +++ b/test/spec.hash.js @@ -9,27 +9,27 @@ describe('Deck JS Hash Extension', function() { } $.deck('.slide'); }); - + it('should assign ids to slides that do not have them', function() { var slides = $.deck('getSlides'); $.each(slides, function(i, $e) { expect($e.attr('id')).toBeTruthy(); }); }); - + it('should reassign ids on reinitialization', function() { var $firstSlide = $.deck('getSlide', 0), firstID = $firstSlide.attr('id'); - + $firstSlide.before('
    '); $.deck('.slide'); expect($firstSlide).not.toHaveId(firstID); }); - + it('should update container with a state class including the slide id', function() { var $c = $.deck('getContainer'), osp = defaults.classes.onPrefix; - + expect($c).toHaveClass(osp + $.deck('getSlide', 0).attr('id')); $.deck('next'); expect($c).toHaveClass(osp + $.deck('getSlide', 1).attr('id')); @@ -37,43 +37,45 @@ describe('Deck JS Hash Extension', function() { expect($c).not.toHaveClass(osp + $.deck('getSlide', 1).attr('id')); expect($c).toHaveClass(osp + $.deck('getSlide', 2).attr('id')); }); - + it('should update the href on slide change', function() { var $hashLink = $(defaults.selectors.hashLink); $.deck('go', 3); expect($hashLink.attr('href')).toMatch('#slide-3'); }); - + it('should use existing ids if they exist', function() { var $hashLink = $(defaults.selectors.hashLink); $.deck('go', 1); expect($hashLink.attr('href')).toMatch('#custom-id'); }); - + it('should update the URL on slide change (if supported)', function() { if (Modernizr.history) { $.deck('go', 3); expect(window.location.hash).toEqual('#slide-3'); } }); - + it('should deep link to slide on deck init', function() { window.location.hash = "#slide-3"; $.deck('.slide'); - expect($.deck('getSlide')).toHaveId('slide-3'); + waitsFor(function() { + return $.deck('getSlide').attr('id') === 'slide-3'; + }); }); - + it('should follow internal hash links using hashchange (if supported)', function() { if (Modernizr.hashchange) { window.location.hash = "#slide-3"; - + // Hashchange event doesn't fire right when the hash changes? waitsFor(function() { return $.deck('getSlide').attr('id') === 'slide-3'; }, 'hash to change to slide-3', 2000); } }); - + it('should follow internal hash links on click', function() { /* Triggered clicks dont generate hashchanges, so until I find a way to do this in an automated fashion, needs to be hand tested. */ diff --git a/test/spec.navigation.js b/test/spec.navigation.js index 46f6f210..91025184 100644 --- a/test/spec.navigation.js +++ b/test/spec.navigation.js @@ -9,18 +9,18 @@ describe('Deck JS Navigation Buttons', function() { } $.deck('.slide'); }); - + it('should go to the next slide if next link is clicked', function() { $(defaults.selectors.nextLink).click(); expect($.deck('getSlide')).toHaveClass('slide2'); }); - + it('should go to the previous slide if previous link is clicked', function() { $.deck('go', 2); $(defaults.selectors.previousLink).click(); expect($.deck('getSlide')).toHaveClass('slide2'); }); - + it('should add the disabled class to the previous link if on first slide', function() { expect($(defaults.selectors.previousLink)).toHaveClass(defaults.classes.navDisabled); $(defaults.selectors.nextLink).click(); @@ -28,19 +28,21 @@ describe('Deck JS Navigation Buttons', function() { $(defaults.selectors.previousLink).click(); expect($(defaults.selectors.previousLink)).toHaveClass(defaults.classes.navDisabled); }); - + it('should add the disabled class to the next link if on last slide', function() { expect($(defaults.selectors.nextLink)).not.toHaveClass(defaults.classes.navDisabled); $.deck('go', $.deck('getSlides').length - 1); expect($(defaults.selectors.nextLink)).toHaveClass(defaults.classes.navDisabled); }); - + it('should not start disabled if deck initialized in the middle', function() { $.deck('go', 2); $.deck('.slide'); - expect($(defaults.selectors.previousLink)).not.toHaveClass(defaults.classes.navDisabled); + waitsFor(function() { + return !$(defaults.selectors.previousLink).hasClass(defaults.classes.navDisabled); + }); }); - + it('should update the links hrefs with real fragment ids', function() { expect($(defaults.selectors.previousLink).attr('href')).toMatch(/#$/); expect($(defaults.selectors.nextLink).attr('href')).toMatch('#custom-id'); diff --git a/test/spec.status.js b/test/spec.status.js index fe0e0153..da7a6bfb 100644 --- a/test/spec.status.js +++ b/test/spec.status.js @@ -9,18 +9,20 @@ describe('Deck JS Status Indicator', function() { } $.deck('.slide'); }); - + it('should show the correct total number of slides', function() { expect($(defaults.selectors.statusTotal)).toHaveText($.deck('getSlides').length); }); - + it('should start at the right current slide', function() { expect($(defaults.selectors.statusCurrent)).toHaveText(1); $.deck('go', 2); $.deck('.slide'); - expect($(defaults.selectors.statusCurrent)).toHaveText(3); + waitsFor(function() { + return $(defaults.selectors.statusCurrent).text() === '3'; + }); }); - + it('should update to the correct number on slide change', function() { $.deck('go', 2); expect($(defaults.selectors.statusCurrent)).toHaveText('3'); @@ -40,11 +42,11 @@ describe('countNested false indicator', function() { countNested: false }); }); - + it('should ignore nested slides in the total', function() { expect($(defaults.selectors.statusTotal)).toHaveText('5'); }); - + it('should update to the root slide number when nested becomes active', function() { $.deck('go', 10); expect($(defaults.selectors.statusCurrent)).toHaveText('4'); From a06d0977a4f943e92cba5f904d26ae6e14163a29 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 7 Nov 2013 15:11:33 -0800 Subject: [PATCH 136/169] Remove complex test cases --- test/fixtures/complex.html | 24 -------------- test/spec.core.js | 65 -------------------------------------- 2 files changed, 89 deletions(-) delete mode 100644 test/fixtures/complex.html diff --git a/test/fixtures/complex.html b/test/fixtures/complex.html deleted file mode 100644 index 00f8d6f2..00000000 --- a/test/fixtures/complex.html +++ /dev/null @@ -1,24 +0,0 @@ -
    -
    - -
    -
    -
    -
    - -
    - -
    - -

    - - / - -

    - -
    - - - - -
    \ No newline at end of file diff --git a/test/spec.core.js b/test/spec.core.js index 6298724f..1d45d80f 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -321,71 +321,6 @@ describe('Deck JS', function() { }); }); - describe('complex html structure', function() { - beforeEach(function() { - loadFixtures('complex.html'); - if (Modernizr.history) { - history.replaceState({}, "", "#") - } - $.deck([ - '.slide1', - '.slide2', - '.slide3', - '.slide4', - '.slide5', - '.slide6', - '.slide7', - '.slide8', - '.slide9', - '.slide10', - ]); - $.deck('go', 2); - }); - - describe('compound state classes', function() { - it('should apply current class', function() { - $('.slide3').each(function(i, el) { - expect($(el)).toHaveClass(defaults.classes.current); - }); - }); - - it('should apply previous class', function() { - $('.slide2').each(function(i, el) { - expect($(el)).toHaveClass(defaults.classes.previous); - }); - }); - - it('should apply next class', function() { - $('.slide4').each(function(i, el) { - expect($(el)).toHaveClass(defaults.classes.next); - }); - }); - - it('should apply before class', function() { - $('.slide1').each(function(i, el) { - expect($(el)).toHaveClass(defaults.classes.before); - }); - }); - - it('should apply after class', function() { - $('.slide5, .slide6, .slide7, .slide8, .slide9, .slide10').each(function(i, el) { - expect($(el)).toHaveClass(defaults.classes.after); - }); - }); - - it('should apply child-current class', function() { - expect($('.slide2').not('.slide10')).toHaveClass(defaults.classes.childCurrent); - }); - }); - - it('should remove old state classes', function() { - $.deck('go', 4); - expect($('.slide3').not('.slide5')).not.toHaveClass(defaults.classes.current); - expect($('.slide2').not('.slide4')).not.toHaveClass(defaults.classes.previous); - expect($('.slide4').not('.slide6')).not.toHaveClass(defaults.classes.next); - }); - }); - describe('empty deck', function() { beforeEach(function() { loadFixtures('empty.html'); From afef203238eeffc713b170a1c8e8f5f22f9dff8e Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Thu, 7 Nov 2013 15:12:21 -0800 Subject: [PATCH 137/169] Implement beforeChange event, #83 --- core/deck.core.js | 20 ++++++++++++++------ test/spec.core.js | 6 +++--- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/core/deck.core.js b/core/deck.core.js index af55560c..8e1b928f 100644 --- a/core/deck.core.js +++ b/core/deck.core.js @@ -21,6 +21,15 @@ that use the API provided by core. $container, // Keeping this cached events = { + /* + This event fires at the beginning of a slide change, before the actual + change occurs. Its purpose is to give extension authors a way to prevent + the slide change from occuring. This is done by calling preventDefault + on the event object within this event. If that is done, the deck.change + event will never be fired and the slide will not change. + */ + beforeChange: 'deck.beforeChange', + /* This event fires whenever the current slide changes, whether by way of next, prev, or go. The callback function is passed two parameters, from @@ -253,7 +262,7 @@ that use the API provided by core. of bounds or doesn't match a slide id the call is ignored. */ go: function(index) { - var e = $.Event(events.change), + var e = $.Event(events.beforeChange), ndx; /* Number index, easy. */ @@ -273,12 +282,11 @@ that use the API provided by core. /* Out of bounds, id doesn't exist, illegal input, eject */ if (typeof ndx === 'undefined') return; + /* Trigger beforeChange. If nothing prevents the change, trigger + the slide change. */ $d.trigger(e, [current, ndx]); - if (e.isDefaultPrevented()) { - /* Trigger the event again and undo the damage done by extensions. */ - $d.trigger(events.change, [ndx, current]); - } - else { + if (!e.isDefaultPrevented()) { + $d.trigger(events.change, [current, ndx]); current = ndx; updateStates(); } diff --git a/test/spec.core.js b/test/spec.core.js index 1d45d80f..8b0bafc5 100755 --- a/test/spec.core.js +++ b/test/spec.core.js @@ -279,11 +279,11 @@ describe('Deck JS', function() { $d.unbind('deck.change', f); }); - it('should not change slides if default prevented', function() { - $d.bind('deck.change', false); + it('should not fire if default prevented in beforeChange', function() { + $d.bind('deck.beforeChange', false); $.deck('go', 3); expect($.deck('getSlide')).toEqual($.deck('getSlide', 1)); - $d.unbind('deck.change', false); + $d.unbind('deck.beforeChange', false); }); }); From 0ddb1b25d0fe0379d552bd326f647912790d15a9 Mon Sep 17 00:00:00 2001 From: imakewebthings Date: Fri, 8 Nov 2013 11:12:21 -0800 Subject: [PATCH 138/169] CSS cruft cleanup, update jQuery --- boilerplate.html | 2 +- extensions/goto/deck.goto.css | 13 ++-- extensions/goto/deck.goto.scss | 57 ++++++++--------- extensions/hash/deck.hash.css | 2 +- extensions/hash/deck.hash.scss | 18 +++--- extensions/menu/deck.menu.css | 5 -- extensions/menu/deck.menu.scss | 5 -- extensions/navigation/deck.navigation.css | 15 ++--- extensions/navigation/deck.navigation.scss | 74 +++++++++------------- extensions/scale/deck.scale.css | 5 -- extensions/scale/deck.scale.js | 22 +++---- extensions/scale/deck.scale.scss | 5 -- extensions/status/deck.status.css | 4 +- extensions/status/deck.status.scss | 22 +++---- introduction/index.html | 4 +- jquery-1.7.2.min.js | 4 -- jquery.min.js | 6 ++ 17 files changed, 105 insertions(+), 158 deletions(-) delete mode 100644 jquery-1.7.2.min.js create mode 100644 jquery.min.js diff --git a/boilerplate.html b/boilerplate.html index 44c53645..35f9557f 100644 --- a/boilerplate.html +++ b/boilerplate.html @@ -77,7 +77,7 @@

    Here

    - + diff --git a/extensions/goto/deck.goto.css b/extensions/goto/deck.goto.css index 108e4f9c..935574a1 100644 --- a/extensions/goto/deck.goto.css +++ b/extensions/goto/deck.goto.css @@ -1,4 +1,4 @@ -.deck-container .goto-form { +.goto-form { position: absolute; z-index: 3; bottom: 10px; @@ -10,20 +10,15 @@ display: none; background: #ccc; overflow: hidden; -} -.borderradius .deck-container .goto-form { - -webkit-border-radius: 10px; - -moz-border-radius: 10px; border-radius: 10px; } -.deck-container .goto-form label { +.goto-form label { font-weight: bold; } -.deck-container .goto-form label, .deck-container .goto-form input { +.goto-form label, .goto-form input { display: inline-block; font-family: inherit; } - .deck-goto .goto-form { display: block; } @@ -36,6 +31,6 @@ @media print { .goto-form, #goto-slide { - display: none !important; + display: none; } } diff --git a/extensions/goto/deck.goto.scss b/extensions/goto/deck.goto.scss index 9170d5d7..83007c7d 100755 --- a/extensions/goto/deck.goto.scss +++ b/extensions/goto/deck.goto.scss @@ -1,36 +1,29 @@ -.deck-container { - .goto-form { - position:absolute; - z-index:3; - bottom:10px; - left:50%; - height:1.75em; - margin:0 0 0 -9.125em; - line-height:1.75em; - padding:0.625em; - display:none; - background:#ccc; - overflow:hidden; - - .borderradius & { - -webkit-border-radius:10px; - -moz-border-radius:10px; - border-radius:10px; - } - - label { - font-weight:bold; - } - - label, input { - display:inline-block; - font-family:inherit; - } +.goto-form { + position:absolute; + z-index:3; + bottom:10px; + left:50%; + height:1.75em; + margin:0 0 0 -9.125em; + line-height:1.75em; + padding:0.625em; + display:none; + background:#ccc; + overflow:hidden; + border-radius:10px; + + label { + font-weight:bold; } -} -.deck-goto .goto-form { - display:block; + label, input { + display:inline-block; + font-family:inherit; + } + + .deck-goto & { + display:block; + } } #goto-slide { @@ -41,6 +34,6 @@ @media print { .goto-form, #goto-slide { - display:none !important; + display:none; } } \ No newline at end of file diff --git a/extensions/hash/deck.hash.css b/extensions/hash/deck.hash.css index 28f07326..6fd564b9 100644 --- a/extensions/hash/deck.hash.css +++ b/extensions/hash/deck.hash.css @@ -1,4 +1,4 @@ -.deck-container .deck-permalink { +.deck-permalink { display: none; position: absolute; z-index: 4; diff --git a/extensions/hash/deck.hash.scss b/extensions/hash/deck.hash.scss index 03b412d7..6a023596 100644 --- a/extensions/hash/deck.hash.scss +++ b/extensions/hash/deck.hash.scss @@ -1,13 +1,11 @@ -.deck-container { - .deck-permalink { - display:none; - position:absolute; - z-index:4; - bottom:30px; - right:0; - width:48px; - text-align:center; - } +.deck-permalink { + display:none; + position:absolute; + z-index:4; + bottom:30px; + right:0; + width:48px; + text-align:center; } .no-history .deck-container:hover .deck-permalink { diff --git a/extensions/menu/deck.menu.css b/extensions/menu/deck.menu.css index 5eecb39a..0d628e07 100644 --- a/extensions/menu/deck.menu.css +++ b/extensions/menu/deck.menu.css @@ -22,16 +22,11 @@ } .csstransforms .deck-menu > .slide { -webkit-transform: scale(0.22) !important; - -moz-transform: scale(0.22) !important; - -o-transform: scale(0.22) !important; -ms-transform: scale(0.22) !important; transform: scale(0.22) !important; -webkit-transform-origin: 0 0; - -moz-transform-origin: 0 0; - -o-transform-origin: 0 0; -ms-transform-origin: 0 0; transform-origin: 0 0; - -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; width: 100%; diff --git a/extensions/menu/deck.menu.scss b/extensions/menu/deck.menu.scss index e3bda7bb..7cbae262 100755 --- a/extensions/menu/deck.menu.scss +++ b/extensions/menu/deck.menu.scss @@ -26,16 +26,11 @@ .csstransforms & { -webkit-transform:scale(.22) !important; - -moz-transform:scale(.22) !important; - -o-transform:scale(.22) !important; -ms-transform:scale(.22) !important; transform:scale(.22) !important; -webkit-transform-origin:0 0; - -moz-transform-origin:0 0; - -o-transform-origin:0 0; -ms-transform-origin:0 0; transform-origin:0 0; - -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; width:100%; diff --git a/extensions/navigation/deck.navigation.css b/extensions/navigation/deck.navigation.css index e1ebad8b..02ff7188 100644 --- a/extensions/navigation/deck.navigation.css +++ b/extensions/navigation/deck.navigation.css @@ -1,4 +1,4 @@ -.deck-container .deck-prev-link, .deck-container .deck-next-link { +.deck-prev-link, .deck-next-link { display: none; position: absolute; z-index: 3; @@ -14,21 +14,20 @@ text-decoration: none; color: #fff; background: #888; -} -.borderradius .deck-container .deck-prev-link, .borderradius .deck-container .deck-next-link { - -webkit-border-radius: 16px; - -moz-border-radius: 16px; border-radius: 16px; } -.deck-container .deck-prev-link:hover, .deck-container .deck-prev-link:focus, .deck-container .deck-prev-link:active, .deck-container .deck-prev-link:visited, .deck-container .deck-next-link:hover, .deck-container .deck-next-link:focus, .deck-container .deck-next-link:active, .deck-container .deck-next-link:visited { +.deck-prev-link:hover, .deck-prev-link:focus, .deck-prev-link:active, .deck-prev-link:visited, .deck-next-link:hover, .deck-next-link:focus, .deck-next-link:active, .deck-next-link:visited { color: #fff; } -.deck-container .deck-prev-link { + +.deck-prev-link { left: 8px; } -.deck-container .deck-next-link { + +.deck-next-link { right: 8px; } + .deck-container:hover .deck-prev-link, .deck-container:hover .deck-next-link { display: block; } diff --git a/extensions/navigation/deck.navigation.scss b/extensions/navigation/deck.navigation.scss index 815602ff..d7bd42e9 100755 --- a/extensions/navigation/deck.navigation.scss +++ b/extensions/navigation/deck.navigation.scss @@ -1,54 +1,42 @@ -@mixin border-radius($r) { - -webkit-border-radius:$r; - -moz-border-radius:$r; - border-radius:$r; -} - -.deck-container { - .deck-prev-link, .deck-next-link { - display:none; - position:absolute; - z-index:3; - top:50%; - width:32px; - height:32px; - margin-top:-16px; - font-size:20px; - font-weight:bold; - line-height:32px; - vertical-align:middle; - text-align:center; - text-decoration:none; +.deck-prev-link, .deck-next-link { + display:none; + position:absolute; + z-index:3; + top:50%; + width:32px; + height:32px; + margin-top:-16px; + font-size:20px; + font-weight:bold; + line-height:32px; + vertical-align:middle; + text-align:center; + text-decoration:none; + color:#fff; + background:#888; + border-radius:16px; + + &:hover, &:focus, &:active, &:visited { color:#fff; - background:#888; - - .borderradius & { - @include border-radius(16px); - } - - &:hover, &:focus, &:active, &:visited { - color:#fff; - } } +} - .deck-prev-link { - left:8px; - } +.deck-prev-link { + left:8px; +} - .deck-next-link { - right:8px; - } - - &:hover .deck-prev-link, &:hover .deck-next-link { - display:block; +.deck-next-link { + right:8px; +} - &.deck-nav-disabled, .touch & { - display:none; - } +.deck-container:hover .deck-prev-link, .deck-container:hover .deck-next-link { + display:block; + + &.deck-nav-disabled, .touch & { + display:none; } } - @media print { .deck-prev-link, .deck-next-link { display:none !important; diff --git a/extensions/scale/deck.scale.css b/extensions/scale/deck.scale.css index b02ed1ad..3b4218d8 100644 --- a/extensions/scale/deck.scale.css +++ b/extensions/scale/deck.scale.css @@ -8,7 +8,6 @@ using the scale extension. */ overflow: hidden; } .csstransforms .deck-container.deck-scale:not(.deck-menu) > .slide { - -webkit-box-sizing: padding-box; -moz-box-sizing: padding-box; box-sizing: padding-box; width: 100%; @@ -16,16 +15,12 @@ using the scale extension. */ } .csstransforms .deck-container.deck-scale:not(.deck-menu) > .slide > .deck-slide-scaler { -webkit-transform-origin: 50% 0; - -moz-transform-origin: 50% 0; - -o-transform-origin: 50% 0; -ms-transform-origin: 50% 0; transform-origin: 50% 0; } .csstransforms .deck-container.deck-menu .deck-slide-scaler { -webkit-transform: none !important; - -moz-transform: none !important; - -o-transform: none !important; -ms-transform: none !important; transform: none !important; } diff --git a/extensions/scale/deck.scale.js b/extensions/scale/deck.scale.js index 14feb1ac..e4db9d77 100644 --- a/extensions/scale/deck.scale.js +++ b/extensions/scale/deck.scale.js @@ -39,15 +39,13 @@ works fine. scale = $container.hasClass(opts.classes.scale) ? baseHeight / slideHeight : 1; - - $.each('Webkit Moz O ms Khtml'.split(' '), function(i, prefix) { - if (scale === 1) { - $scaler.css(prefix + 'Transform', ''); - } - else { - $scaler.css(prefix + 'Transform', 'scale(' + scale + ')'); - } - }); + + if (scale === 1) { + $scaler.css('transform', ''); + } + else { + $scaler.css('transform', 'scale(' + scale + ')'); + } }); } @@ -57,7 +55,7 @@ works fine. options.classes.scale This class is added to the deck container when scaling is enabled. It is enabled by default when the module is included. - + options.classes.scaleSlideWrapper Scaling is done using a wrapper around the contents of each slide. This class is applied to that wrapper. @@ -133,7 +131,7 @@ works fine. ], function(el, i) { return '.' + el; }).join(', '); - + // Build top level slides array rootSlides = []; $.each($[deck]('getSlides'), function(i, $el) { @@ -141,7 +139,7 @@ works fine. rootSlides.push($el); } }); - + // Use a wrapper on each slide to handle content scaling $.each(rootSlides, function(i, $slide) { $slide.children().wrapAll('
    '); diff --git a/extensions/scale/deck.scale.scss b/extensions/scale/deck.scale.scss index 9368dd63..c9c425fa 100644 --- a/extensions/scale/deck.scale.scss +++ b/extensions/scale/deck.scale.scss @@ -8,7 +8,6 @@ using the scale extension. */ overflow:hidden; > .slide { - -webkit-box-sizing: padding-box; -moz-box-sizing: padding-box; box-sizing: padding-box; width:100%; @@ -16,8 +15,6 @@ using the scale extension. */ > .deck-slide-scaler { -webkit-transform-origin: 50% 0; - -moz-transform-origin: 50% 0; - -o-transform-origin: 50% 0; -ms-transform-origin: 50% 0; transform-origin: 50% 0; } @@ -26,8 +23,6 @@ using the scale extension. */ .csstransforms .deck-container.deck-menu .deck-slide-scaler { -webkit-transform:none !important; - -moz-transform:none !important; - -o-transform:none !important; -ms-transform:none !important; transform:none !important; } \ No newline at end of file diff --git a/extensions/status/deck.status.css b/extensions/status/deck.status.css index 17d55ad0..b2736464 100644 --- a/extensions/status/deck.status.css +++ b/extensions/status/deck.status.css @@ -1,4 +1,4 @@ -.deck-container .deck-status { +.deck-status { position: absolute; bottom: 10px; right: 5px; @@ -7,7 +7,7 @@ margin: 0; } -body.deck-container .deck-status { +body > .deck-container .deck-status { position: fixed; } diff --git a/extensions/status/deck.status.scss b/extensions/status/deck.status.scss index d57af24b..5a4ea84f 100755 --- a/extensions/status/deck.status.scss +++ b/extensions/status/deck.status.scss @@ -1,18 +1,14 @@ -.deck-container { - .deck-status { - position:absolute; - bottom:10px; - right:5px; - color:#888; - z-index:3; - margin:0; - } +.deck-status { + position:absolute; + bottom:10px; + right:5px; + color:#888; + z-index:3; + margin:0; } -body.deck-container { - .deck-status { - position:fixed; - } +body > .deck-container .deck-status { + position:fixed; } @media print { diff --git a/introduction/index.html b/introduction/index.html index 18a2d1f7..154506ab 100644 --- a/introduction/index.html +++ b/introduction/index.html @@ -200,9 +200,7 @@

    Digging Deeper

    #
    - - - + diff --git a/jquery-1.7.2.min.js b/jquery-1.7.2.min.js deleted file mode 100644 index 93adea19..00000000 --- a/jquery-1.7.2.min.js +++ /dev/null @@ -1,4 +0,0 @@ -/*! jQuery v1.7.2 jquery.com | jquery.org/license */ -(function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cu(a){if(!cj[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){ck||(ck=c.createElement("iframe"),ck.frameBorder=ck.width=ck.height=0),b.appendChild(ck);if(!cl||!ck.createElement)cl=(ck.contentWindow||ck.contentDocument).document,cl.write((f.support.boxModel?"":"")+""),cl.close();d=cl.createElement(a),cl.body.appendChild(d),e=f.css(d,"display"),b.removeChild(ck)}cj[a]=e}return cj[a]}function ct(a,b){var c={};f.each(cp.concat.apply([],cp.slice(0,b)),function(){c[this]=a});return c}function cs(){cq=b}function cr(){setTimeout(cs,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;g0){if(c!=="border")for(;e=0===c})}function S(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function K(){return!0}function J(){return!1}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?+d:j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,n=/^[\],:{}\s]*$/,o=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,p=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,q=/(?:^|:|,)(?:\s*\[)+/g,r=/(webkit)[ \/]([\w.]+)/,s=/(opera)(?:.*version)?[ \/]([\w.]+)/,t=/(msie) ([\w.]+)/,u=/(mozilla)(?:.*? rv:([\w.]+))?/,v=/-([a-z]|[0-9])/ig,w=/^-ms-/,x=function(a,b){return(b+"").toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};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=m.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.7.2",length:0,size:function(){return this.length},toArray:function(){return F.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)?E.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(),A.add(a);return this},eq:function(a){a=+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(F.apply(this,arguments),"slice",F.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:E,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;A.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").off("ready")}},bindReady:function(){if(!A){A=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a!=null&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||D.call(a,d)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw new Error(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(n.test(b.replace(o,"@").replace(p,"]").replace(q,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(c){if(typeof c!="string"||!c)return null;var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,"ms-").replace(v,x)},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?i.call(arguments,0):b,j.notifyWith(k,e)}}function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}var b=i.call(arguments,0),c=0,d=b.length,e=Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c
    a",d=p.getElementsByTagName("*"),e=p.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=p.getElementsByTagName("input")[0],b={leadingWhitespace:p.firstChild.nodeType===3,tbody:!p.getElementsByTagName("tbody").length,htmlSerialize:!!p.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:i.value==="on",optSelected:h.selected,getSetAttribute:p.className!=="t",enctype:!!c.createElement("form").enctype,html5Clone:c.createElement("nav").cloneNode(!0).outerHTML!=="<:nav>",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,pixelMargin:!0},f.boxModel=b.boxModel=c.compatMode==="CSS1Compat",i.checked=!0,b.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,b.optDisabled=!h.disabled;try{delete p.test}catch(r){b.deleteExpando=!1}!p.addEventListener&&p.attachEvent&&p.fireEvent&&(p.attachEvent("onclick",function(){b.noCloneEvent=!1}),p.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),b.radioValue=i.value==="t",i.setAttribute("checked","checked"),i.setAttribute("name","t"),p.appendChild(i),j=c.createDocumentFragment(),j.appendChild(p.lastChild),b.checkClone=j.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=i.checked,j.removeChild(i),j.appendChild(p);if(p.attachEvent)for(n in{submit:1,change:1,focusin:1})m="on"+n,o=m in p,o||(p.setAttribute(m,"return;"),o=typeof p[m]=="function"),b[n+"Bubbles"]=o;j.removeChild(p),j=g=h=p=i=null,f(function(){var d,e,g,h,i,j,l,m,n,q,r,s,t,u=c.getElementsByTagName("body")[0];!u||(m=1,t="padding:0;margin:0;border:",r="position:absolute;top:0;left:0;width:1px;height:1px;",s=t+"0;visibility:hidden;",n="style='"+r+t+"5px solid #000;",q="
    "+""+"
    ",d=c.createElement("div"),d.style.cssText=s+"width:0;height:0;position:static;top:0;margin-top:"+m+"px",u.insertBefore(d,u.firstChild),p=c.createElement("div"),d.appendChild(p),p.innerHTML="
    t
    ",k=p.getElementsByTagName("td"),o=k[0].offsetHeight===0,k[0].style.display="",k[1].style.display="none",b.reliableHiddenOffsets=o&&k[0].offsetHeight===0,a.getComputedStyle&&(p.innerHTML="",l=c.createElement("div"),l.style.width="0",l.style.marginRight="0",p.style.width="2px",p.appendChild(l),b.reliableMarginRight=(parseInt((a.getComputedStyle(l,null)||{marginRight:0}).marginRight,10)||0)===0),typeof p.style.zoom!="undefined"&&(p.innerHTML="",p.style.width=p.style.padding="1px",p.style.border=0,p.style.overflow="hidden",p.style.display="inline",p.style.zoom=1,b.inlineBlockNeedsLayout=p.offsetWidth===3,p.style.display="block",p.style.overflow="visible",p.innerHTML="
    ",b.shrinkWrapBlocks=p.offsetWidth!==3),p.style.cssText=r+s,p.innerHTML=q,e=p.firstChild,g=e.firstChild,i=e.nextSibling.firstChild.firstChild,j={doesNotAddBorder:g.offsetTop!==5,doesAddBorderForTableAndCells:i.offsetTop===5},g.style.position="fixed",g.style.top="20px",j.fixedPosition=g.offsetTop===20||g.offsetTop===15,g.style.position=g.style.top="",e.style.overflow="hidden",e.style.position="relative",j.subtractsBorderForOverflowNotVisible=g.offsetTop===-5,j.doesNotIncludeMarginInBodyOffset=u.offsetTop!==m,a.getComputedStyle&&(p.style.marginTop="1%",b.pixelMargin=(a.getComputedStyle(p,null)||{marginTop:0}).marginTop!=="1%"),typeof d.style.zoom!="undefined"&&(d.style.zoom=1),u.removeChild(d),l=p=d=null,f.extend(b,j))});return b}();var j=/^(?:\{.*\}|\[.*\])$/,k=/([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&&!m(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[j]:a[j]&&j,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[j]=n=++f.uuid:n=j),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d);if(o&&!h[c])return g.events;k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h;return i}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[h]:h;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)||(b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" ")));for(e=0,g=b.length;e1,null,!1)},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,b){a&&(b=(b||"fx")+"mark",f._data(a,b,(f._data(a,b)||0)+1))},_unmark:function(a,b,c){a!==!0&&(c=b,b=a,a=!1);if(b){c=c||"fx";var d=c+"mark",e=a?0:(f._data(b,d)||1)-1;e?f._data(b,d,e):(f.removeData(b,d,!0),n(b,c,"mark"))}},queue:function(a,b,c){var d;if(a){b=(b||"fx")+"queue",d=f._data(a,b),c&&(!d||f.isArray(c)?d=f._data(a,b,f.makeArray(c)):d.push(c));return d||[]}},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e={};d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),f._data(a,b+".run",e),d.call(a,function(){f.dequeue(a,b)},e)),c.length||(f.removeData(a,b+"queue "+b+".run",!0),n(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){var d=2;typeof a!="string"&&(c=a,a="fx",d--);if(arguments.length1)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,f.prop,a,b,arguments.length>1)},removeProp:function(a){a=f.propFix[a]||a;return this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,g,h,i;if(f.isFunction(a))return this.each(function(b){f(this).addClass(a.call(this,b,this.className))});if(a&&typeof a=="string"){b=a.split(p);for(c=0,d=this.length;c-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];{if(!!arguments.length){e=f.isFunction(a);return this.each(function(d){var g=f(this),h;if(this.nodeType===1){e?h=a.call(this,d,g.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.type]||f.valHooks[this.nodeName.toLowerCase()];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}if(g){c=f.valHooks[g.type]||f.valHooks[g.nodeName.toLowerCase()];if(c&&"get"in c&&(d=c.get(g,"value"))!==b)return d;d=g.value;return typeof d=="string"?d.replace(q,""):d==null?"":d}}}}),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,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;c=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},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!!a&&j!==3&&j!==8&&j!==2){if(e&&c in f.attrFn)return f(a)[c](d);if(typeof a.getAttribute=="undefined")return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return}if(h&&"set"in h&&i&&(g=h.set(a,d,c))!==b)return g;a.setAttribute(c,""+d);return d}if(h&&"get"in h&&i&&(g=h.get(a,c))!==null)return g;g=a.getAttribute(c);return g===null?b:g}},removeAttr:function(a,b){var c,d,e,g,h,i=0;if(b&&a.nodeType===1){d=b.toLowerCase().split(p),g=d.length;for(;i=0}})});var z=/^(?:textarea|input|select)$/i,A=/^([^\.]*)?(?:\.(.+))?$/,B=/(?:^|\s)hover(\.\S+)?\b/,C=/^key/,D=/^(?:mouse|contextmenu)|click/,E=/^(?:focusinfocus|focusoutblur)$/,F=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,G=function( -a){var b=F.exec(a);b&&(b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)"));return b},H=function(a,b){var c=a.attributes||{};return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||(c.id||{}).value===b[2])&&(!b[3]||b[3].test((c["class"]||{}).value))},I=function(a){return f.event.special.hover?a:a.replace(B,"mouseenter$1 mouseleave$1")};f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(!(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))){d.handler&&(p=d,d=p.handler,g=p.selector),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.dispatch.apply(i.elem,arguments):b},i.elem=a),c=f.trim(I(c)).split(" ");for(k=0;k=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"";if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,m=E.test(s+h)?e:e.parentNode,n=null;for(;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;le&&j.push({elem:this,matches:d.slice(e)});for(k=0;k0?this.on(b,null,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),C.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),D.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function x(a,b,c,e,f,g){for(var h=0,i=e.length;h0){k=j;break}}j=j[a]}e[h]=k}}}function w(a,b,c,e,f,g){for(var h=0,i=e.length;h+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){i=!1;return 0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length===1&&(w[0]==="~"||w[0]==="+")&&d.parentNode?d.parentNode:d,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);l&&(m(l,h,e,f),m.uniqueSort(e));return e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.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(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.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]&&m.error(a[0]);a[0]=e++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),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]=m(b[3],null,null,c);else{var g=m.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(o.match.POS.test(b[0])||o.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!!m(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=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([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&&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=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null: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=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));o.match.globalPOS=p;var s=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(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.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:[]}},o.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&&(o.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")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

    ";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[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}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.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 m(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;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h0)for(h=g;h=0:f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h=1;while(g&&g.ownerDocument&&g!==b){for(d=0;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)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));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(S(c[0])||S(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);L.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!R[a]?f.unique(e):e,(this.length>1||N.test(d))&&M.test(a)&&(e=e.reverse());return this.pushStack(e,a,P.call(arguments).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 V="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/]","i"),bd=/checked\s*(?:[^=]|=\s*.checked.)/i,be=/\/(java|ecma)script/i,bf=/^\s*",""],legend:[1,"
    ","
    "],thead:[1,"","
    "],tr:[2,"","
    "],td:[3,"","
    "],col:[2,"","
    "],area:[1,"",""],_default:[0,"",""]},bh=U(c);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){return f.access(this,function(a){return a===b?f.text(this):this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a))},null,a,arguments.length)},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){var b=f.isFunction(a);return this.each(function(c){f(this).wrapAll(b?a.call(this,c):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 -.clean(arguments);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.clean(arguments));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){return f.access(this,function(a){var c=this[0]||{},d=0,e=this.length;if(a===b)return c.nodeType===1?c.innerHTML.replace(W,""):null;if(typeof a=="string"&&!ba.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!bg[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$1>");try{for(;d1&&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,e,g,h=f.support.html5Clone||f.isXMLDoc(a)||!bc.test("<"+a.nodeName+">")?a.cloneNode(!0):bo(a);if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bk(a,h),d=bl(a),e=bl(h);for(g=0;d[g];++g)e[g]&&bk(d[g],e[g])}if(b){bj(a,h);if(c){d=bl(a),e=bl(h);for(g=0;d[g];++g)bj(d[g],e[g])}}d=e=null;return h},clean:function(a,b,d,e){var g,h,i,j=[];b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);for(var k=0,l;(l=a[k])!=null;k++){typeof l=="number"&&(l+="");if(!l)continue;if(typeof l=="string")if(!_.test(l))l=b.createTextNode(l);else{l=l.replace(Y,"<$1>");var m=(Z.exec(l)||["",""])[1].toLowerCase(),n=bg[m]||bg._default,o=n[0],p=b.createElement("div"),q=bh.childNodes,r;b===c?bh.appendChild(p):U(b).appendChild(p),p.innerHTML=n[1]+l+n[2];while(o--)p=p.lastChild;if(!f.support.tbody){var s=$.test(l),t=m==="table"&&!s?p.firstChild&&p.firstChild.childNodes:n[1]===""&&!s?p.childNodes:[];for(i=t.length-1;i>=0;--i)f.nodeName(t[i],"tbody")&&!t[i].childNodes.length&&t[i].parentNode.removeChild(t[i])}!f.support.leadingWhitespace&&X.test(l)&&p.insertBefore(b.createTextNode(X.exec(l)[0]),p.firstChild),l=p.childNodes,p&&(p.parentNode.removeChild(p),q.length>0&&(r=q[q.length-1],r&&r.parentNode&&r.parentNode.removeChild(r)))}var u;if(!f.support.appendChecked)if(l[0]&&typeof (u=l.length)=="number")for(i=0;i1)},f.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=by(a,"opacity");return c===""?"1":c}return a.style.opacity}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":f.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!!a&&a.nodeType!==3&&a.nodeType!==8&&!!a.style){var g,h,i=f.camelCase(c),j=a.style,k=f.cssHooks[i];c=f.cssProps[i]||i;if(d===b){if(k&&"get"in k&&(g=k.get(a,!1,e))!==b)return g;return j[c]}h=typeof d,h==="string"&&(g=bu.exec(d))&&(d=+(g[1]+1)*+g[2]+parseFloat(f.css(a,c)),h="number");if(d==null||h==="number"&&isNaN(d))return;h==="number"&&!f.cssNumber[i]&&(d+="px");if(!k||!("set"in k)||(d=k.set(a,d))!==b)try{j[c]=d}catch(l){}}},css:function(a,c,d){var e,g;c=f.camelCase(c),g=f.cssHooks[c],c=f.cssProps[c]||c,c==="cssFloat"&&(c="float");if(g&&"get"in g&&(e=g.get(a,!0,d))!==b)return e;if(by)return by(a,c)},swap:function(a,b,c){var d={},e,f;for(f in b)d[f]=a.style[f],a.style[f]=b[f];e=c.call(a);for(f in b)a.style[f]=d[f];return e}}),f.curCSS=f.css,c.defaultView&&c.defaultView.getComputedStyle&&(bz=function(a,b){var c,d,e,g,h=a.style;b=b.replace(br,"-$1").toLowerCase(),(d=a.ownerDocument.defaultView)&&(e=d.getComputedStyle(a,null))&&(c=e.getPropertyValue(b),c===""&&!f.contains(a.ownerDocument.documentElement,a)&&(c=f.style(a,b))),!f.support.pixelMargin&&e&&bv.test(b)&&bt.test(c)&&(g=h.width,h.width=c,c=e.width,h.width=g);return c}),c.documentElement.currentStyle&&(bA=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;f==null&&g&&(e=g[b])&&(f=e),bt.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d));return f===""?"auto":f}),by=bz||bA,f.each(["height","width"],function(a,b){f.cssHooks[b]={get:function(a,c,d){if(c)return a.offsetWidth!==0?bB(a,b,d):f.swap(a,bw,function(){return bB(a,b,d)})},set:function(a,b){return bs.test(b)?b+"px":b}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return bq.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,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bp,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bp.test(g)?g.replace(bp,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){return f.swap(a,{display:"inline-block"},function(){return b?by(a,"margin-right"):a.style.marginRight})}})}),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&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)}),f.each({margin:"",padding:"",border:"Width"},function(a,b){f.cssHooks[a+b]={expand:function(c){var d,e=typeof c=="string"?c.split(" "):[c],f={};for(d=0;d<4;d++)f[a+bx[d]+b]=e[d]||e[d-2]||e[0];return f}}});var bC=/%20/g,bD=/\[\]$/,bE=/\r?\n/g,bF=/#.*$/,bG=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bH=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bI=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bJ=/^(?:GET|HEAD)$/,bK=/^\/\//,bL=/\?/,bM=/)<[^<]*)*<\/script>/gi,bN=/^(?:select|textarea)/i,bO=/\s+/,bP=/([?&])_=[^&]*/,bQ=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bR=f.fn.load,bS={},bT={},bU,bV,bW=["*/"]+["*"];try{bU=e.href}catch(bX){bU=c.createElement("a"),bU.href="",bU=bU.href}bV=bQ.exec(bU.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bR)return bR.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(bM,"")).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||bN.test(this.nodeName)||bH.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(bE,"\r\n")}}):{name:b.name,value:c.replace(bE,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.on(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?b$(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),b$(a,b);return a},ajaxSettings:{url:bU,isLocal:bI.test(bV[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":bW},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},flatOptions:{context:!0,url:!0}},ajaxPrefilter:bY(bS),ajaxTransport:bY(bT),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>0?4:0;var o,r,u,w=c,x=l?ca(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=cb(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),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.Callbacks("once memory"),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=bG.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.add,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(bF,"").replace(bK,bV[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bO),d.crossDomain==null&&(r=bQ.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bV[1]&&r[2]==bV[2]&&(r[3]||(r[1]==="http:"?80:443))==(bV[3]||(bV[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),bZ(bS,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bJ.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bL.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bP,"$1_="+x);d.url=y+(y===d.url?(bL.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]!=="*"?", "+bW+"; 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=bZ(bT,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){if(s<2)w(-1,z);else throw 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(bC,"+")}}),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=typeof b.data=="string"&&/^application\/x\-www\-form\-urlencoded/.test(b.contentType);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);try{m.text=h.responseText}catch(a){}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;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(ct("show",3),a,b,c);for(var g=0,h=this.length;g=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c-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({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,c){var d=/Y/.test(c);f.fn[a]=function(e){return f.access(this,function(a,e,g){var h=cy(a);if(g===b)return h?c in h?h[c]:f.support.boxModel&&h.document.documentElement[e]||h.document.body[e]:a[e];h?h.scrollTo(d?f(h).scrollLeft():g,d?g:f(h).scrollTop()):a[e]=g},a,e,arguments.length,null)}}),f.each({Height:"height",Width:"width"},function(a,c){var d="client"+a,e="scroll"+a,g="offset"+a;f.fn["inner"+a]=function(){var a=this[0];return a?a.style?parseFloat(f.css(a,c,"padding")):this[c]():null},f.fn["outer"+a]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,c,a?"margin":"border")):this[c]():null},f.fn[c]=function(a){return f.access(this,function(a,c,h){var i,j,k,l;if(f.isWindow(a)){i=a.document,j=i.documentElement[d];return f.support.boxModel&&j||i.body&&i.body[d]||j}if(a.nodeType===9){i=a.documentElement;if(i[d]>=i[e])return i[d];return Math.max(a.body[e],i[e],a.body[g],i[g])}if(h===b){k=f.css(a,c),l=parseFloat(k);return f.isNumeric(l)?l:k}f(a).css(c,h)},c,a,arguments.length,null)}}),a.jQuery=a.$=f,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return f})})(window); \ No newline at end of file diff --git a/jquery.min.js b/jquery.min.js new file mode 100644 index 00000000..76d21a46 --- /dev/null +++ b/jquery.min.js @@ -0,0 +1,6 @@ +/*! jQuery v1.10.2 | (c) 2005, 2013 jQuery Foundation, Inc. | jquery.org/license +//@ sourceMappingURL=jquery-1.10.2.min.map +*/ +(function(e,t){var n,r,i=typeof t,o=e.location,a=e.document,s=a.documentElement,l=e.jQuery,u=e.$,c={},p=[],f="1.10.2",d=p.concat,h=p.push,g=p.slice,m=p.indexOf,y=c.toString,v=c.hasOwnProperty,b=f.trim,x=function(e,t){return new x.fn.init(e,t,r)},w=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,T=/\S+/g,C=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,N=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,k=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,E=/^[\],:{}\s]*$/,S=/(?:^|:|,)(?:\s*\[)+/g,A=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,j=/"[^"\\\r\n]*"|true|false|null|-?(?:\d+\.|)\d+(?:[eE][+-]?\d+|)/g,D=/^-ms-/,L=/-([\da-z])/gi,H=function(e,t){return t.toUpperCase()},q=function(e){(a.addEventListener||"load"===e.type||"complete"===a.readyState)&&(_(),x.ready())},_=function(){a.addEventListener?(a.removeEventListener("DOMContentLoaded",q,!1),e.removeEventListener("load",q,!1)):(a.detachEvent("onreadystatechange",q),e.detachEvent("onload",q))};x.fn=x.prototype={jquery:f,constructor:x,init:function(e,n,r){var i,o;if(!e)return this;if("string"==typeof e){if(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:N.exec(e),!i||!i[1]&&n)return!n||n.jquery?(n||r).find(e):this.constructor(n).find(e);if(i[1]){if(n=n instanceof x?n[0]:n,x.merge(this,x.parseHTML(i[1],n&&n.nodeType?n.ownerDocument||n:a,!0)),k.test(i[1])&&x.isPlainObject(n))for(i in n)x.isFunction(this[i])?this[i](n[i]):this.attr(i,n[i]);return this}if(o=a.getElementById(i[2]),o&&o.parentNode){if(o.id!==i[2])return r.find(e);this.length=1,this[0]=o}return this.context=a,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):x.isFunction(e)?r.ready(e):(e.selector!==t&&(this.selector=e.selector,this.context=e.context),x.makeArray(e,this))},selector:"",length:0,toArray:function(){return g.call(this)},get:function(e){return null==e?this.toArray():0>e?this[this.length+e]:this[e]},pushStack:function(e){var t=x.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return x.each(this,e,t)},ready:function(e){return x.ready.promise().done(e),this},slice:function(){return this.pushStack(g.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},map:function(e){return this.pushStack(x.map(this,function(t,n){return e.call(t,n,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:h,sort:[].sort,splice:[].splice},x.fn.init.prototype=x.fn,x.extend=x.fn.extend=function(){var e,n,r,i,o,a,s=arguments[0]||{},l=1,u=arguments.length,c=!1;for("boolean"==typeof s&&(c=s,s=arguments[1]||{},l=2),"object"==typeof s||x.isFunction(s)||(s={}),u===l&&(s=this,--l);u>l;l++)if(null!=(o=arguments[l]))for(i in o)e=s[i],r=o[i],s!==r&&(c&&r&&(x.isPlainObject(r)||(n=x.isArray(r)))?(n?(n=!1,a=e&&x.isArray(e)?e:[]):a=e&&x.isPlainObject(e)?e:{},s[i]=x.extend(c,a,r)):r!==t&&(s[i]=r));return s},x.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),noConflict:function(t){return e.$===x&&(e.$=u),t&&e.jQuery===x&&(e.jQuery=l),x},isReady:!1,readyWait:1,holdReady:function(e){e?x.readyWait++:x.ready(!0)},ready:function(e){if(e===!0?!--x.readyWait:!x.isReady){if(!a.body)return setTimeout(x.ready);x.isReady=!0,e!==!0&&--x.readyWait>0||(n.resolveWith(a,[x]),x.fn.trigger&&x(a).trigger("ready").off("ready"))}},isFunction:function(e){return"function"===x.type(e)},isArray:Array.isArray||function(e){return"array"===x.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?c[y.call(e)]||"object":typeof e},isPlainObject:function(e){var n;if(!e||"object"!==x.type(e)||e.nodeType||x.isWindow(e))return!1;try{if(e.constructor&&!v.call(e,"constructor")&&!v.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(r){return!1}if(x.support.ownLast)for(n in e)return v.call(e,n);for(n in e);return n===t||v.call(e,n)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},error:function(e){throw Error(e)},parseHTML:function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||a;var r=k.exec(e),i=!n&&[];return r?[t.createElement(r[1])]:(r=x.buildFragment([e],t,i),i&&x(i).remove(),x.merge([],r.childNodes))},parseJSON:function(n){return e.JSON&&e.JSON.parse?e.JSON.parse(n):null===n?n:"string"==typeof n&&(n=x.trim(n),n&&E.test(n.replace(A,"@").replace(j,"]").replace(S,"")))?Function("return "+n)():(x.error("Invalid JSON: "+n),t)},parseXML:function(n){var r,i;if(!n||"string"!=typeof n)return null;try{e.DOMParser?(i=new DOMParser,r=i.parseFromString(n,"text/xml")):(r=new ActiveXObject("Microsoft.XMLDOM"),r.async="false",r.loadXML(n))}catch(o){r=t}return r&&r.documentElement&&!r.getElementsByTagName("parsererror").length||x.error("Invalid XML: "+n),r},noop:function(){},globalEval:function(t){t&&x.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(D,"ms-").replace(L,H)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,n){var r,i=0,o=e.length,a=M(e);if(n){if(a){for(;o>i;i++)if(r=t.apply(e[i],n),r===!1)break}else for(i in e)if(r=t.apply(e[i],n),r===!1)break}else if(a){for(;o>i;i++)if(r=t.call(e[i],i,e[i]),r===!1)break}else for(i in e)if(r=t.call(e[i],i,e[i]),r===!1)break;return e},trim:b&&!b.call("\ufeff\u00a0")?function(e){return null==e?"":b.call(e)}:function(e){return null==e?"":(e+"").replace(C,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(M(Object(e))?x.merge(n,"string"==typeof e?[e]:e):h.call(n,e)),n},inArray:function(e,t,n){var r;if(t){if(m)return m.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,n){var r=n.length,i=e.length,o=0;if("number"==typeof r)for(;r>o;o++)e[i++]=n[o];else while(n[o]!==t)e[i++]=n[o++];return e.length=i,e},grep:function(e,t,n){var r,i=[],o=0,a=e.length;for(n=!!n;a>o;o++)r=!!t(e[o],o),n!==r&&i.push(e[o]);return i},map:function(e,t,n){var r,i=0,o=e.length,a=M(e),s=[];if(a)for(;o>i;i++)r=t(e[i],i,n),null!=r&&(s[s.length]=r);else for(i in e)r=t(e[i],i,n),null!=r&&(s[s.length]=r);return d.apply([],s)},guid:1,proxy:function(e,n){var r,i,o;return"string"==typeof n&&(o=e[n],n=e,e=o),x.isFunction(e)?(r=g.call(arguments,2),i=function(){return e.apply(n||this,r.concat(g.call(arguments)))},i.guid=e.guid=e.guid||x.guid++,i):t},access:function(e,n,r,i,o,a,s){var l=0,u=e.length,c=null==r;if("object"===x.type(r)){o=!0;for(l in r)x.access(e,n,l,r[l],!0,a,s)}else if(i!==t&&(o=!0,x.isFunction(i)||(s=!0),c&&(s?(n.call(e,i),n=null):(c=n,n=function(e,t,n){return c.call(x(e),n)})),n))for(;u>l;l++)n(e[l],r,s?i:i.call(e[l],l,n(e[l],r)));return o?e:c?n.call(e):u?n(e[0],r):a},now:function(){return(new Date).getTime()},swap:function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i}}),x.ready.promise=function(t){if(!n)if(n=x.Deferred(),"complete"===a.readyState)setTimeout(x.ready);else if(a.addEventListener)a.addEventListener("DOMContentLoaded",q,!1),e.addEventListener("load",q,!1);else{a.attachEvent("onreadystatechange",q),e.attachEvent("onload",q);var r=!1;try{r=null==e.frameElement&&a.documentElement}catch(i){}r&&r.doScroll&&function o(){if(!x.isReady){try{r.doScroll("left")}catch(e){return setTimeout(o,50)}_(),x.ready()}}()}return n.promise(t)},x.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){c["[object "+t+"]"]=t.toLowerCase()});function M(e){var t=e.length,n=x.type(e);return x.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||"function"!==n&&(0===t||"number"==typeof t&&t>0&&t-1 in e)}r=x(a),function(e,t){var n,r,i,o,a,s,l,u,c,p,f,d,h,g,m,y,v,b="sizzle"+-new Date,w=e.document,T=0,C=0,N=st(),k=st(),E=st(),S=!1,A=function(e,t){return e===t?(S=!0,0):0},j=typeof t,D=1<<31,L={}.hasOwnProperty,H=[],q=H.pop,_=H.push,M=H.push,O=H.slice,F=H.indexOf||function(e){var t=0,n=this.length;for(;n>t;t++)if(this[t]===e)return t;return-1},B="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",P="[\\x20\\t\\r\\n\\f]",R="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",W=R.replace("w","w#"),$="\\["+P+"*("+R+")"+P+"*(?:([*^$|!~]?=)"+P+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+W+")|)|)"+P+"*\\]",I=":("+R+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+$.replace(3,8)+")*)|.*)\\)|)",z=RegExp("^"+P+"+|((?:^|[^\\\\])(?:\\\\.)*)"+P+"+$","g"),X=RegExp("^"+P+"*,"+P+"*"),U=RegExp("^"+P+"*([>+~]|"+P+")"+P+"*"),V=RegExp(P+"*[+~]"),Y=RegExp("="+P+"*([^\\]'\"]*)"+P+"*\\]","g"),J=RegExp(I),G=RegExp("^"+W+"$"),Q={ID:RegExp("^#("+R+")"),CLASS:RegExp("^\\.("+R+")"),TAG:RegExp("^("+R.replace("w","w*")+")"),ATTR:RegExp("^"+$),PSEUDO:RegExp("^"+I),CHILD:RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+P+"*(even|odd|(([+-]|)(\\d*)n|)"+P+"*(?:([+-]|)"+P+"*(\\d+)|))"+P+"*\\)|)","i"),bool:RegExp("^(?:"+B+")$","i"),needsContext:RegExp("^"+P+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+P+"*((?:-\\d)?\\d*)"+P+"*\\)|)(?=[^-]|$)","i")},K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,et=/^(?:input|select|textarea|button)$/i,tt=/^h\d$/i,nt=/'|\\/g,rt=RegExp("\\\\([\\da-f]{1,6}"+P+"?|("+P+")|.)","ig"),it=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:0>r?String.fromCharCode(r+65536):String.fromCharCode(55296|r>>10,56320|1023&r)};try{M.apply(H=O.call(w.childNodes),w.childNodes),H[w.childNodes.length].nodeType}catch(ot){M={apply:H.length?function(e,t){_.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function at(e,t,n,i){var o,a,s,l,u,c,d,m,y,x;if((t?t.ownerDocument||t:w)!==f&&p(t),t=t||f,n=n||[],!e||"string"!=typeof e)return n;if(1!==(l=t.nodeType)&&9!==l)return[];if(h&&!i){if(o=Z.exec(e))if(s=o[1]){if(9===l){if(a=t.getElementById(s),!a||!a.parentNode)return n;if(a.id===s)return n.push(a),n}else if(t.ownerDocument&&(a=t.ownerDocument.getElementById(s))&&v(t,a)&&a.id===s)return n.push(a),n}else{if(o[2])return M.apply(n,t.getElementsByTagName(e)),n;if((s=o[3])&&r.getElementsByClassName&&t.getElementsByClassName)return M.apply(n,t.getElementsByClassName(s)),n}if(r.qsa&&(!g||!g.test(e))){if(m=d=b,y=t,x=9===l&&e,1===l&&"object"!==t.nodeName.toLowerCase()){c=mt(e),(d=t.getAttribute("id"))?m=d.replace(nt,"\\$&"):t.setAttribute("id",m),m="[id='"+m+"'] ",u=c.length;while(u--)c[u]=m+yt(c[u]);y=V.test(e)&&t.parentNode||t,x=c.join(",")}if(x)try{return M.apply(n,y.querySelectorAll(x)),n}catch(T){}finally{d||t.removeAttribute("id")}}}return kt(e.replace(z,"$1"),t,n,i)}function st(){var e=[];function t(n,r){return e.push(n+=" ")>o.cacheLength&&delete t[e.shift()],t[n]=r}return t}function lt(e){return e[b]=!0,e}function ut(e){var t=f.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function ct(e,t){var n=e.split("|"),r=e.length;while(r--)o.attrHandle[n[r]]=t}function pt(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||D)-(~e.sourceIndex||D);if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function ft(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function dt(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function ht(e){return lt(function(t){return t=+t,lt(function(n,r){var i,o=e([],n.length,t),a=o.length;while(a--)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}s=at.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},r=at.support={},p=at.setDocument=function(e){var n=e?e.ownerDocument||e:w,i=n.defaultView;return n!==f&&9===n.nodeType&&n.documentElement?(f=n,d=n.documentElement,h=!s(n),i&&i.attachEvent&&i!==i.top&&i.attachEvent("onbeforeunload",function(){p()}),r.attributes=ut(function(e){return e.className="i",!e.getAttribute("className")}),r.getElementsByTagName=ut(function(e){return e.appendChild(n.createComment("")),!e.getElementsByTagName("*").length}),r.getElementsByClassName=ut(function(e){return e.innerHTML="
    ",e.firstChild.className="i",2===e.getElementsByClassName("i").length}),r.getById=ut(function(e){return d.appendChild(e).id=b,!n.getElementsByName||!n.getElementsByName(b).length}),r.getById?(o.find.ID=function(e,t){if(typeof t.getElementById!==j&&h){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){return e.getAttribute("id")===t}}):(delete o.find.ID,o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){var n=typeof e.getAttributeNode!==j&&e.getAttributeNode("id");return n&&n.value===t}}),o.find.TAG=r.getElementsByTagName?function(e,n){return typeof n.getElementsByTagName!==j?n.getElementsByTagName(e):t}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},o.find.CLASS=r.getElementsByClassName&&function(e,n){return typeof n.getElementsByClassName!==j&&h?n.getElementsByClassName(e):t},m=[],g=[],(r.qsa=K.test(n.querySelectorAll))&&(ut(function(e){e.innerHTML="",e.querySelectorAll("[selected]").length||g.push("\\["+P+"*(?:value|"+B+")"),e.querySelectorAll(":checked").length||g.push(":checked")}),ut(function(e){var t=n.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("t",""),e.querySelectorAll("[t^='']").length&&g.push("[*^$]="+P+"*(?:''|\"\")"),e.querySelectorAll(":enabled").length||g.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),g.push(",.*:")})),(r.matchesSelector=K.test(y=d.webkitMatchesSelector||d.mozMatchesSelector||d.oMatchesSelector||d.msMatchesSelector))&&ut(function(e){r.disconnectedMatch=y.call(e,"div"),y.call(e,"[s!='']:x"),m.push("!=",I)}),g=g.length&&RegExp(g.join("|")),m=m.length&&RegExp(m.join("|")),v=K.test(d.contains)||d.compareDocumentPosition?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},A=d.compareDocumentPosition?function(e,t){if(e===t)return S=!0,0;var i=t.compareDocumentPosition&&e.compareDocumentPosition&&e.compareDocumentPosition(t);return i?1&i||!r.sortDetached&&t.compareDocumentPosition(e)===i?e===n||v(w,e)?-1:t===n||v(w,t)?1:c?F.call(c,e)-F.call(c,t):0:4&i?-1:1:e.compareDocumentPosition?-1:1}:function(e,t){var r,i=0,o=e.parentNode,a=t.parentNode,s=[e],l=[t];if(e===t)return S=!0,0;if(!o||!a)return e===n?-1:t===n?1:o?-1:a?1:c?F.call(c,e)-F.call(c,t):0;if(o===a)return pt(e,t);r=e;while(r=r.parentNode)s.unshift(r);r=t;while(r=r.parentNode)l.unshift(r);while(s[i]===l[i])i++;return i?pt(s[i],l[i]):s[i]===w?-1:l[i]===w?1:0},n):f},at.matches=function(e,t){return at(e,null,null,t)},at.matchesSelector=function(e,t){if((e.ownerDocument||e)!==f&&p(e),t=t.replace(Y,"='$1']"),!(!r.matchesSelector||!h||m&&m.test(t)||g&&g.test(t)))try{var n=y.call(e,t);if(n||r.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(i){}return at(t,f,null,[e]).length>0},at.contains=function(e,t){return(e.ownerDocument||e)!==f&&p(e),v(e,t)},at.attr=function(e,n){(e.ownerDocument||e)!==f&&p(e);var i=o.attrHandle[n.toLowerCase()],a=i&&L.call(o.attrHandle,n.toLowerCase())?i(e,n,!h):t;return a===t?r.attributes||!h?e.getAttribute(n):(a=e.getAttributeNode(n))&&a.specified?a.value:null:a},at.error=function(e){throw Error("Syntax error, unrecognized expression: "+e)},at.uniqueSort=function(e){var t,n=[],i=0,o=0;if(S=!r.detectDuplicates,c=!r.sortStable&&e.slice(0),e.sort(A),S){while(t=e[o++])t===e[o]&&(i=n.push(o));while(i--)e.splice(n[i],1)}return e},a=at.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=a(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r];r++)n+=a(t);return n},o=at.selectors={cacheLength:50,createPseudo:lt,match:Q,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(rt,it),e[3]=(e[4]||e[5]||"").replace(rt,it),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||at.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&at.error(e[0]),e},PSEUDO:function(e){var n,r=!e[5]&&e[2];return Q.CHILD.test(e[0])?null:(e[3]&&e[4]!==t?e[2]=e[4]:r&&J.test(r)&&(n=mt(r,!0))&&(n=r.indexOf(")",r.length-n)-r.length)&&(e[0]=e[0].slice(0,n),e[2]=r.slice(0,n)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(rt,it).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=N[e+" "];return t||(t=RegExp("(^|"+P+")"+e+"("+P+"|$)"))&&N(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==j&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var i=at.attr(r,e);return null==i?"!="===t:t?(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i+" ").indexOf(n)>-1:"|="===t?i===n||i.slice(0,n.length+1)===n+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,l){var u,c,p,f,d,h,g=o!==a?"nextSibling":"previousSibling",m=t.parentNode,y=s&&t.nodeName.toLowerCase(),v=!l&&!s;if(m){if(o){while(g){p=t;while(p=p[g])if(s?p.nodeName.toLowerCase()===y:1===p.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?m.firstChild:m.lastChild],a&&v){c=m[b]||(m[b]={}),u=c[e]||[],d=u[0]===T&&u[1],f=u[0]===T&&u[2],p=d&&m.childNodes[d];while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if(1===p.nodeType&&++f&&p===t){c[e]=[T,d,f];break}}else if(v&&(u=(t[b]||(t[b]={}))[e])&&u[0]===T)f=u[1];else while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if((s?p.nodeName.toLowerCase()===y:1===p.nodeType)&&++f&&(v&&((p[b]||(p[b]={}))[e]=[T,f]),p===t))break;return f-=i,f===r||0===f%r&&f/r>=0}}},PSEUDO:function(e,t){var n,r=o.pseudos[e]||o.setFilters[e.toLowerCase()]||at.error("unsupported pseudo: "+e);return r[b]?r(t):r.length>1?(n=[e,e,"",t],o.setFilters.hasOwnProperty(e.toLowerCase())?lt(function(e,n){var i,o=r(e,t),a=o.length;while(a--)i=F.call(e,o[a]),e[i]=!(n[i]=o[a])}):function(e){return r(e,0,n)}):r}},pseudos:{not:lt(function(e){var t=[],n=[],r=l(e.replace(z,"$1"));return r[b]?lt(function(e,t,n,i){var o,a=r(e,null,i,[]),s=e.length;while(s--)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),!n.pop()}}),has:lt(function(e){return function(t){return at(e,t).length>0}}),contains:lt(function(e){return function(t){return(t.textContent||t.innerText||a(t)).indexOf(e)>-1}}),lang:lt(function(e){return G.test(e||"")||at.error("unsupported lang: "+e),e=e.replace(rt,it).toLowerCase(),function(t){var n;do if(n=h?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===d},focus:function(e){return e===f.activeElement&&(!f.hasFocus||f.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeName>"@"||3===e.nodeType||4===e.nodeType)return!1;return!0},parent:function(e){return!o.pseudos.empty(e)},header:function(e){return tt.test(e.nodeName)},input:function(e){return et.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||t.toLowerCase()===e.type)},first:ht(function(){return[0]}),last:ht(function(e,t){return[t-1]}),eq:ht(function(e,t,n){return[0>n?n+t:n]}),even:ht(function(e,t){var n=0;for(;t>n;n+=2)e.push(n);return e}),odd:ht(function(e,t){var n=1;for(;t>n;n+=2)e.push(n);return e}),lt:ht(function(e,t,n){var r=0>n?n+t:n;for(;--r>=0;)e.push(r);return e}),gt:ht(function(e,t,n){var r=0>n?n+t:n;for(;t>++r;)e.push(r);return e})}},o.pseudos.nth=o.pseudos.eq;for(n in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})o.pseudos[n]=ft(n);for(n in{submit:!0,reset:!0})o.pseudos[n]=dt(n);function gt(){}gt.prototype=o.filters=o.pseudos,o.setFilters=new gt;function mt(e,t){var n,r,i,a,s,l,u,c=k[e+" "];if(c)return t?0:c.slice(0);s=e,l=[],u=o.preFilter;while(s){(!n||(r=X.exec(s)))&&(r&&(s=s.slice(r[0].length)||s),l.push(i=[])),n=!1,(r=U.exec(s))&&(n=r.shift(),i.push({value:n,type:r[0].replace(z," ")}),s=s.slice(n.length));for(a in o.filter)!(r=Q[a].exec(s))||u[a]&&!(r=u[a](r))||(n=r.shift(),i.push({value:n,type:a,matches:r}),s=s.slice(n.length));if(!n)break}return t?s.length:s?at.error(e):k(e,l).slice(0)}function yt(e){var t=0,n=e.length,r="";for(;n>t;t++)r+=e[t].value;return r}function vt(e,t,n){var r=t.dir,o=n&&"parentNode"===r,a=C++;return t.first?function(t,n,i){while(t=t[r])if(1===t.nodeType||o)return e(t,n,i)}:function(t,n,s){var l,u,c,p=T+" "+a;if(s){while(t=t[r])if((1===t.nodeType||o)&&e(t,n,s))return!0}else while(t=t[r])if(1===t.nodeType||o)if(c=t[b]||(t[b]={}),(u=c[r])&&u[0]===p){if((l=u[1])===!0||l===i)return l===!0}else if(u=c[r]=[p],u[1]=e(t,n,s)||i,u[1]===!0)return!0}}function bt(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function xt(e,t,n,r,i){var o,a=[],s=0,l=e.length,u=null!=t;for(;l>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),u&&t.push(s));return a}function wt(e,t,n,r,i,o){return r&&!r[b]&&(r=wt(r)),i&&!i[b]&&(i=wt(i,o)),lt(function(o,a,s,l){var u,c,p,f=[],d=[],h=a.length,g=o||Nt(t||"*",s.nodeType?[s]:s,[]),m=!e||!o&&t?g:xt(g,f,e,s,l),y=n?i||(o?e:h||r)?[]:a:m;if(n&&n(m,y,s,l),r){u=xt(y,d),r(u,[],s,l),c=u.length;while(c--)(p=u[c])&&(y[d[c]]=!(m[d[c]]=p))}if(o){if(i||e){if(i){u=[],c=y.length;while(c--)(p=y[c])&&u.push(m[c]=p);i(null,y=[],u,l)}c=y.length;while(c--)(p=y[c])&&(u=i?F.call(o,p):f[c])>-1&&(o[u]=!(a[u]=p))}}else y=xt(y===a?y.splice(h,y.length):y),i?i(null,a,y,l):M.apply(a,y)})}function Tt(e){var t,n,r,i=e.length,a=o.relative[e[0].type],s=a||o.relative[" "],l=a?1:0,c=vt(function(e){return e===t},s,!0),p=vt(function(e){return F.call(t,e)>-1},s,!0),f=[function(e,n,r){return!a&&(r||n!==u)||((t=n).nodeType?c(e,n,r):p(e,n,r))}];for(;i>l;l++)if(n=o.relative[e[l].type])f=[vt(bt(f),n)];else{if(n=o.filter[e[l].type].apply(null,e[l].matches),n[b]){for(r=++l;i>r;r++)if(o.relative[e[r].type])break;return wt(l>1&&bt(f),l>1&&yt(e.slice(0,l-1).concat({value:" "===e[l-2].type?"*":""})).replace(z,"$1"),n,r>l&&Tt(e.slice(l,r)),i>r&&Tt(e=e.slice(r)),i>r&&yt(e))}f.push(n)}return bt(f)}function Ct(e,t){var n=0,r=t.length>0,a=e.length>0,s=function(s,l,c,p,d){var h,g,m,y=[],v=0,b="0",x=s&&[],w=null!=d,C=u,N=s||a&&o.find.TAG("*",d&&l.parentNode||l),k=T+=null==C?1:Math.random()||.1;for(w&&(u=l!==f&&l,i=n);null!=(h=N[b]);b++){if(a&&h){g=0;while(m=e[g++])if(m(h,l,c)){p.push(h);break}w&&(T=k,i=++n)}r&&((h=!m&&h)&&v--,s&&x.push(h))}if(v+=b,r&&b!==v){g=0;while(m=t[g++])m(x,y,l,c);if(s){if(v>0)while(b--)x[b]||y[b]||(y[b]=q.call(p));y=xt(y)}M.apply(p,y),w&&!s&&y.length>0&&v+t.length>1&&at.uniqueSort(p)}return w&&(T=k,u=C),x};return r?lt(s):s}l=at.compile=function(e,t){var n,r=[],i=[],o=E[e+" "];if(!o){t||(t=mt(e)),n=t.length;while(n--)o=Tt(t[n]),o[b]?r.push(o):i.push(o);o=E(e,Ct(i,r))}return o};function Nt(e,t,n){var r=0,i=t.length;for(;i>r;r++)at(e,t[r],n);return n}function kt(e,t,n,i){var a,s,u,c,p,f=mt(e);if(!i&&1===f.length){if(s=f[0]=f[0].slice(0),s.length>2&&"ID"===(u=s[0]).type&&r.getById&&9===t.nodeType&&h&&o.relative[s[1].type]){if(t=(o.find.ID(u.matches[0].replace(rt,it),t)||[])[0],!t)return n;e=e.slice(s.shift().value.length)}a=Q.needsContext.test(e)?0:s.length;while(a--){if(u=s[a],o.relative[c=u.type])break;if((p=o.find[c])&&(i=p(u.matches[0].replace(rt,it),V.test(s[0].type)&&t.parentNode||t))){if(s.splice(a,1),e=i.length&&yt(s),!e)return M.apply(n,i),n;break}}}return l(e,f)(i,t,!h,n,V.test(e)),n}r.sortStable=b.split("").sort(A).join("")===b,r.detectDuplicates=S,p(),r.sortDetached=ut(function(e){return 1&e.compareDocumentPosition(f.createElement("div"))}),ut(function(e){return e.innerHTML="","#"===e.firstChild.getAttribute("href")})||ct("type|href|height|width",function(e,n,r){return r?t:e.getAttribute(n,"type"===n.toLowerCase()?1:2)}),r.attributes&&ut(function(e){return e.innerHTML="",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||ct("value",function(e,n,r){return r||"input"!==e.nodeName.toLowerCase()?t:e.defaultValue}),ut(function(e){return null==e.getAttribute("disabled")})||ct(B,function(e,n,r){var i;return r?t:(i=e.getAttributeNode(n))&&i.specified?i.value:e[n]===!0?n.toLowerCase():null}),x.find=at,x.expr=at.selectors,x.expr[":"]=x.expr.pseudos,x.unique=at.uniqueSort,x.text=at.getText,x.isXMLDoc=at.isXML,x.contains=at.contains}(e);var O={};function F(e){var t=O[e]={};return x.each(e.match(T)||[],function(e,n){t[n]=!0}),t}x.Callbacks=function(e){e="string"==typeof e?O[e]||F(e):x.extend({},e);var n,r,i,o,a,s,l=[],u=!e.once&&[],c=function(t){for(r=e.memory&&t,i=!0,a=s||0,s=0,o=l.length,n=!0;l&&o>a;a++)if(l[a].apply(t[0],t[1])===!1&&e.stopOnFalse){r=!1;break}n=!1,l&&(u?u.length&&c(u.shift()):r?l=[]:p.disable())},p={add:function(){if(l){var t=l.length;(function i(t){x.each(t,function(t,n){var r=x.type(n);"function"===r?e.unique&&p.has(n)||l.push(n):n&&n.length&&"string"!==r&&i(n)})})(arguments),n?o=l.length:r&&(s=t,c(r))}return this},remove:function(){return l&&x.each(arguments,function(e,t){var r;while((r=x.inArray(t,l,r))>-1)l.splice(r,1),n&&(o>=r&&o--,a>=r&&a--)}),this},has:function(e){return e?x.inArray(e,l)>-1:!(!l||!l.length)},empty:function(){return l=[],o=0,this},disable:function(){return l=u=r=t,this},disabled:function(){return!l},lock:function(){return u=t,r||p.disable(),this},locked:function(){return!u},fireWith:function(e,t){return!l||i&&!u||(t=t||[],t=[e,t.slice?t.slice():t],n?u.push(t):c(t)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p},x.extend({Deferred:function(e){var t=[["resolve","done",x.Callbacks("once memory"),"resolved"],["reject","fail",x.Callbacks("once memory"),"rejected"],["notify","progress",x.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return x.Deferred(function(n){x.each(t,function(t,o){var a=o[0],s=x.isFunction(e[t])&&e[t];i[o[1]](function(){var e=s&&s.apply(this,arguments);e&&x.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[a+"With"](this===r?n.promise():this,s?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?x.extend(e,r):r}},i={};return r.pipe=r.then,x.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=g.call(arguments),r=n.length,i=1!==r||e&&x.isFunction(e.promise)?r:0,o=1===i?e:x.Deferred(),a=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?g.call(arguments):r,n===s?o.notifyWith(t,n):--i||o.resolveWith(t,n)}},s,l,u;if(r>1)for(s=Array(r),l=Array(r),u=Array(r);r>t;t++)n[t]&&x.isFunction(n[t].promise)?n[t].promise().done(a(t,u,n)).fail(o.reject).progress(a(t,l,s)):--i;return i||o.resolveWith(u,n),o.promise()}}),x.support=function(t){var n,r,o,s,l,u,c,p,f,d=a.createElement("div");if(d.setAttribute("className","t"),d.innerHTML="
    a",n=d.getElementsByTagName("*")||[],r=d.getElementsByTagName("a")[0],!r||!r.style||!n.length)return t;s=a.createElement("select"),u=s.appendChild(a.createElement("option")),o=d.getElementsByTagName("input")[0],r.style.cssText="top:1px;float:left;opacity:.5",t.getSetAttribute="t"!==d.className,t.leadingWhitespace=3===d.firstChild.nodeType,t.tbody=!d.getElementsByTagName("tbody").length,t.htmlSerialize=!!d.getElementsByTagName("link").length,t.style=/top/.test(r.getAttribute("style")),t.hrefNormalized="/a"===r.getAttribute("href"),t.opacity=/^0.5/.test(r.style.opacity),t.cssFloat=!!r.style.cssFloat,t.checkOn=!!o.value,t.optSelected=u.selected,t.enctype=!!a.createElement("form").enctype,t.html5Clone="<:nav>"!==a.createElement("nav").cloneNode(!0).outerHTML,t.inlineBlockNeedsLayout=!1,t.shrinkWrapBlocks=!1,t.pixelPosition=!1,t.deleteExpando=!0,t.noCloneEvent=!0,t.reliableMarginRight=!0,t.boxSizingReliable=!0,o.checked=!0,t.noCloneChecked=o.cloneNode(!0).checked,s.disabled=!0,t.optDisabled=!u.disabled;try{delete d.test}catch(h){t.deleteExpando=!1}o=a.createElement("input"),o.setAttribute("value",""),t.input=""===o.getAttribute("value"),o.value="t",o.setAttribute("type","radio"),t.radioValue="t"===o.value,o.setAttribute("checked","t"),o.setAttribute("name","t"),l=a.createDocumentFragment(),l.appendChild(o),t.appendChecked=o.checked,t.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,d.attachEvent&&(d.attachEvent("onclick",function(){t.noCloneEvent=!1}),d.cloneNode(!0).click());for(f in{submit:!0,change:!0,focusin:!0})d.setAttribute(c="on"+f,"t"),t[f+"Bubbles"]=c in e||d.attributes[c].expando===!1;d.style.backgroundClip="content-box",d.cloneNode(!0).style.backgroundClip="",t.clearCloneStyle="content-box"===d.style.backgroundClip;for(f in x(t))break;return t.ownLast="0"!==f,x(function(){var n,r,o,s="padding:0;margin:0;border:0;display:block;box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;",l=a.getElementsByTagName("body")[0];l&&(n=a.createElement("div"),n.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",l.appendChild(n).appendChild(d),d.innerHTML="
    t
    ",o=d.getElementsByTagName("td"),o[0].style.cssText="padding:0;margin:0;border:0;display:none",p=0===o[0].offsetHeight,o[0].style.display="",o[1].style.display="none",t.reliableHiddenOffsets=p&&0===o[0].offsetHeight,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",x.swap(l,null!=l.style.zoom?{zoom:1}:{},function(){t.boxSizing=4===d.offsetWidth}),e.getComputedStyle&&(t.pixelPosition="1%"!==(e.getComputedStyle(d,null)||{}).top,t.boxSizingReliable="4px"===(e.getComputedStyle(d,null)||{width:"4px"}).width,r=d.appendChild(a.createElement("div")),r.style.cssText=d.style.cssText=s,r.style.marginRight=r.style.width="0",d.style.width="1px",t.reliableMarginRight=!parseFloat((e.getComputedStyle(r,null)||{}).marginRight)),typeof d.style.zoom!==i&&(d.innerHTML="",d.style.cssText=s+"width:1px;padding:1px;display:inline;zoom:1",t.inlineBlockNeedsLayout=3===d.offsetWidth,d.style.display="block",d.innerHTML="
    ",d.firstChild.style.width="5px",t.shrinkWrapBlocks=3!==d.offsetWidth,t.inlineBlockNeedsLayout&&(l.style.zoom=1)),l.removeChild(n),n=d=o=r=null)}),n=s=l=u=r=o=null,t +}({});var B=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,P=/([A-Z])/g;function R(e,n,r,i){if(x.acceptData(e)){var o,a,s=x.expando,l=e.nodeType,u=l?x.cache:e,c=l?e[s]:e[s]&&s;if(c&&u[c]&&(i||u[c].data)||r!==t||"string"!=typeof n)return c||(c=l?e[s]=p.pop()||x.guid++:s),u[c]||(u[c]=l?{}:{toJSON:x.noop}),("object"==typeof n||"function"==typeof n)&&(i?u[c]=x.extend(u[c],n):u[c].data=x.extend(u[c].data,n)),a=u[c],i||(a.data||(a.data={}),a=a.data),r!==t&&(a[x.camelCase(n)]=r),"string"==typeof n?(o=a[n],null==o&&(o=a[x.camelCase(n)])):o=a,o}}function W(e,t,n){if(x.acceptData(e)){var r,i,o=e.nodeType,a=o?x.cache:e,s=o?e[x.expando]:x.expando;if(a[s]){if(t&&(r=n?a[s]:a[s].data)){x.isArray(t)?t=t.concat(x.map(t,x.camelCase)):t in r?t=[t]:(t=x.camelCase(t),t=t in r?[t]:t.split(" ")),i=t.length;while(i--)delete r[t[i]];if(n?!I(r):!x.isEmptyObject(r))return}(n||(delete a[s].data,I(a[s])))&&(o?x.cleanData([e],!0):x.support.deleteExpando||a!=a.window?delete a[s]:a[s]=null)}}}x.extend({cache:{},noData:{applet:!0,embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return e=e.nodeType?x.cache[e[x.expando]]:e[x.expando],!!e&&!I(e)},data:function(e,t,n){return R(e,t,n)},removeData:function(e,t){return W(e,t)},_data:function(e,t,n){return R(e,t,n,!0)},_removeData:function(e,t){return W(e,t,!0)},acceptData:function(e){if(e.nodeType&&1!==e.nodeType&&9!==e.nodeType)return!1;var t=e.nodeName&&x.noData[e.nodeName.toLowerCase()];return!t||t!==!0&&e.getAttribute("classid")===t}}),x.fn.extend({data:function(e,n){var r,i,o=null,a=0,s=this[0];if(e===t){if(this.length&&(o=x.data(s),1===s.nodeType&&!x._data(s,"parsedAttrs"))){for(r=s.attributes;r.length>a;a++)i=r[a].name,0===i.indexOf("data-")&&(i=x.camelCase(i.slice(5)),$(s,i,o[i]));x._data(s,"parsedAttrs",!0)}return o}return"object"==typeof e?this.each(function(){x.data(this,e)}):arguments.length>1?this.each(function(){x.data(this,e,n)}):s?$(s,e,x.data(s,e)):null},removeData:function(e){return this.each(function(){x.removeData(this,e)})}});function $(e,n,r){if(r===t&&1===e.nodeType){var i="data-"+n.replace(P,"-$1").toLowerCase();if(r=e.getAttribute(i),"string"==typeof r){try{r="true"===r?!0:"false"===r?!1:"null"===r?null:+r+""===r?+r:B.test(r)?x.parseJSON(r):r}catch(o){}x.data(e,n,r)}else r=t}return r}function I(e){var t;for(t in e)if(("data"!==t||!x.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}x.extend({queue:function(e,n,r){var i;return e?(n=(n||"fx")+"queue",i=x._data(e,n),r&&(!i||x.isArray(r)?i=x._data(e,n,x.makeArray(r)):i.push(r)),i||[]):t},dequeue:function(e,t){t=t||"fx";var n=x.queue(e,t),r=n.length,i=n.shift(),o=x._queueHooks(e,t),a=function(){x.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return x._data(e,n)||x._data(e,n,{empty:x.Callbacks("once memory").add(function(){x._removeData(e,t+"queue"),x._removeData(e,n)})})}}),x.fn.extend({queue:function(e,n){var r=2;return"string"!=typeof e&&(n=e,e="fx",r--),r>arguments.length?x.queue(this[0],e):n===t?this:this.each(function(){var t=x.queue(this,e,n);x._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&x.dequeue(this,e)})},dequeue:function(e){return this.each(function(){x.dequeue(this,e)})},delay:function(e,t){return e=x.fx?x.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,n){var r,i=1,o=x.Deferred(),a=this,s=this.length,l=function(){--i||o.resolveWith(a,[a])};"string"!=typeof e&&(n=e,e=t),e=e||"fx";while(s--)r=x._data(a[s],e+"queueHooks"),r&&r.empty&&(i++,r.empty.add(l));return l(),o.promise(n)}});var z,X,U=/[\t\r\n\f]/g,V=/\r/g,Y=/^(?:input|select|textarea|button|object)$/i,J=/^(?:a|area)$/i,G=/^(?:checked|selected)$/i,Q=x.support.getSetAttribute,K=x.support.input;x.fn.extend({attr:function(e,t){return x.access(this,x.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){x.removeAttr(this,e)})},prop:function(e,t){return x.access(this,x.prop,e,t,arguments.length>1)},removeProp:function(e){return e=x.propFix[e]||e,this.each(function(){try{this[e]=t,delete this[e]}catch(n){}})},addClass:function(e){var t,n,r,i,o,a=0,s=this.length,l="string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).addClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):" ")){o=0;while(i=t[o++])0>r.indexOf(" "+i+" ")&&(r+=i+" ");n.className=x.trim(r)}return this},removeClass:function(e){var t,n,r,i,o,a=0,s=this.length,l=0===arguments.length||"string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).removeClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):"")){o=0;while(i=t[o++])while(r.indexOf(" "+i+" ")>=0)r=r.replace(" "+i+" "," ");n.className=e?x.trim(r):""}return this},toggleClass:function(e,t){var n=typeof e;return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):x.isFunction(e)?this.each(function(n){x(this).toggleClass(e.call(this,n,this.className,t),t)}):this.each(function(){if("string"===n){var t,r=0,o=x(this),a=e.match(T)||[];while(t=a[r++])o.hasClass(t)?o.removeClass(t):o.addClass(t)}else(n===i||"boolean"===n)&&(this.className&&x._data(this,"__className__",this.className),this.className=this.className||e===!1?"":x._data(this,"__className__")||"")})},hasClass:function(e){var t=" "+e+" ",n=0,r=this.length;for(;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(U," ").indexOf(t)>=0)return!0;return!1},val:function(e){var n,r,i,o=this[0];{if(arguments.length)return i=x.isFunction(e),this.each(function(n){var o;1===this.nodeType&&(o=i?e.call(this,n,x(this).val()):e,null==o?o="":"number"==typeof o?o+="":x.isArray(o)&&(o=x.map(o,function(e){return null==e?"":e+""})),r=x.valHooks[this.type]||x.valHooks[this.nodeName.toLowerCase()],r&&"set"in r&&r.set(this,o,"value")!==t||(this.value=o))});if(o)return r=x.valHooks[o.type]||x.valHooks[o.nodeName.toLowerCase()],r&&"get"in r&&(n=r.get(o,"value"))!==t?n:(n=o.value,"string"==typeof n?n.replace(V,""):null==n?"":n)}}}),x.extend({valHooks:{option:{get:function(e){var t=x.find.attr(e,"value");return null!=t?t:e.text}},select:{get:function(e){var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,l=0>i?s:o?i:0;for(;s>l;l++)if(n=r[l],!(!n.selected&&l!==i||(x.support.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&x.nodeName(n.parentNode,"optgroup"))){if(t=x(n).val(),o)return t;a.push(t)}return a},set:function(e,t){var n,r,i=e.options,o=x.makeArray(t),a=i.length;while(a--)r=i[a],(r.selected=x.inArray(x(r).val(),o)>=0)&&(n=!0);return n||(e.selectedIndex=-1),o}}},attr:function(e,n,r){var o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return typeof e.getAttribute===i?x.prop(e,n,r):(1===s&&x.isXMLDoc(e)||(n=n.toLowerCase(),o=x.attrHooks[n]||(x.expr.match.bool.test(n)?X:z)),r===t?o&&"get"in o&&null!==(a=o.get(e,n))?a:(a=x.find.attr(e,n),null==a?t:a):null!==r?o&&"set"in o&&(a=o.set(e,r,n))!==t?a:(e.setAttribute(n,r+""),r):(x.removeAttr(e,n),t))},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(T);if(o&&1===e.nodeType)while(n=o[i++])r=x.propFix[n]||n,x.expr.match.bool.test(n)?K&&Q||!G.test(n)?e[r]=!1:e[x.camelCase("default-"+n)]=e[r]=!1:x.attr(e,n,""),e.removeAttribute(Q?n:r)},attrHooks:{type:{set:function(e,t){if(!x.support.radioValue&&"radio"===t&&x.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},propFix:{"for":"htmlFor","class":"className"},prop:function(e,n,r){var i,o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return a=1!==s||!x.isXMLDoc(e),a&&(n=x.propFix[n]||n,o=x.propHooks[n]),r!==t?o&&"set"in o&&(i=o.set(e,r,n))!==t?i:e[n]=r:o&&"get"in o&&null!==(i=o.get(e,n))?i:e[n]},propHooks:{tabIndex:{get:function(e){var t=x.find.attr(e,"tabindex");return t?parseInt(t,10):Y.test(e.nodeName)||J.test(e.nodeName)&&e.href?0:-1}}}}),X={set:function(e,t,n){return t===!1?x.removeAttr(e,n):K&&Q||!G.test(n)?e.setAttribute(!Q&&x.propFix[n]||n,n):e[x.camelCase("default-"+n)]=e[n]=!0,n}},x.each(x.expr.match.bool.source.match(/\w+/g),function(e,n){var r=x.expr.attrHandle[n]||x.find.attr;x.expr.attrHandle[n]=K&&Q||!G.test(n)?function(e,n,i){var o=x.expr.attrHandle[n],a=i?t:(x.expr.attrHandle[n]=t)!=r(e,n,i)?n.toLowerCase():null;return x.expr.attrHandle[n]=o,a}:function(e,n,r){return r?t:e[x.camelCase("default-"+n)]?n.toLowerCase():null}}),K&&Q||(x.attrHooks.value={set:function(e,n,r){return x.nodeName(e,"input")?(e.defaultValue=n,t):z&&z.set(e,n,r)}}),Q||(z={set:function(e,n,r){var i=e.getAttributeNode(r);return i||e.setAttributeNode(i=e.ownerDocument.createAttribute(r)),i.value=n+="","value"===r||n===e.getAttribute(r)?n:t}},x.expr.attrHandle.id=x.expr.attrHandle.name=x.expr.attrHandle.coords=function(e,n,r){var i;return r?t:(i=e.getAttributeNode(n))&&""!==i.value?i.value:null},x.valHooks.button={get:function(e,n){var r=e.getAttributeNode(n);return r&&r.specified?r.value:t},set:z.set},x.attrHooks.contenteditable={set:function(e,t,n){z.set(e,""===t?!1:t,n)}},x.each(["width","height"],function(e,n){x.attrHooks[n]={set:function(e,r){return""===r?(e.setAttribute(n,"auto"),r):t}}})),x.support.hrefNormalized||x.each(["href","src"],function(e,t){x.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),x.support.style||(x.attrHooks.style={get:function(e){return e.style.cssText||t},set:function(e,t){return e.style.cssText=t+""}}),x.support.optSelected||(x.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}}),x.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){x.propFix[this.toLowerCase()]=this}),x.support.enctype||(x.propFix.enctype="encoding"),x.each(["radio","checkbox"],function(){x.valHooks[this]={set:function(e,n){return x.isArray(n)?e.checked=x.inArray(x(e).val(),n)>=0:t}},x.support.checkOn||(x.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Z=/^(?:input|select|textarea)$/i,et=/^key/,tt=/^(?:mouse|contextmenu)|click/,nt=/^(?:focusinfocus|focusoutblur)$/,rt=/^([^.]*)(?:\.(.+)|)$/;function it(){return!0}function ot(){return!1}function at(){try{return a.activeElement}catch(e){}}x.event={global:{},add:function(e,n,r,o,a){var s,l,u,c,p,f,d,h,g,m,y,v=x._data(e);if(v){r.handler&&(c=r,r=c.handler,a=c.selector),r.guid||(r.guid=x.guid++),(l=v.events)||(l=v.events={}),(f=v.handle)||(f=v.handle=function(e){return typeof x===i||e&&x.event.triggered===e.type?t:x.event.dispatch.apply(f.elem,arguments)},f.elem=e),n=(n||"").match(T)||[""],u=n.length;while(u--)s=rt.exec(n[u])||[],g=y=s[1],m=(s[2]||"").split(".").sort(),g&&(p=x.event.special[g]||{},g=(a?p.delegateType:p.bindType)||g,p=x.event.special[g]||{},d=x.extend({type:g,origType:y,data:o,handler:r,guid:r.guid,selector:a,needsContext:a&&x.expr.match.needsContext.test(a),namespace:m.join(".")},c),(h=l[g])||(h=l[g]=[],h.delegateCount=0,p.setup&&p.setup.call(e,o,m,f)!==!1||(e.addEventListener?e.addEventListener(g,f,!1):e.attachEvent&&e.attachEvent("on"+g,f))),p.add&&(p.add.call(e,d),d.handler.guid||(d.handler.guid=r.guid)),a?h.splice(h.delegateCount++,0,d):h.push(d),x.event.global[g]=!0);e=null}},remove:function(e,t,n,r,i){var o,a,s,l,u,c,p,f,d,h,g,m=x.hasData(e)&&x._data(e);if(m&&(c=m.events)){t=(t||"").match(T)||[""],u=t.length;while(u--)if(s=rt.exec(t[u])||[],d=g=s[1],h=(s[2]||"").split(".").sort(),d){p=x.event.special[d]||{},d=(r?p.delegateType:p.bindType)||d,f=c[d]||[],s=s[2]&&RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=o=f.length;while(o--)a=f[o],!i&&g!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,p.remove&&p.remove.call(e,a));l&&!f.length&&(p.teardown&&p.teardown.call(e,h,m.handle)!==!1||x.removeEvent(e,d,m.handle),delete c[d])}else for(d in c)x.event.remove(e,d+t[u],n,r,!0);x.isEmptyObject(c)&&(delete m.handle,x._removeData(e,"events"))}},trigger:function(n,r,i,o){var s,l,u,c,p,f,d,h=[i||a],g=v.call(n,"type")?n.type:n,m=v.call(n,"namespace")?n.namespace.split("."):[];if(u=f=i=i||a,3!==i.nodeType&&8!==i.nodeType&&!nt.test(g+x.event.triggered)&&(g.indexOf(".")>=0&&(m=g.split("."),g=m.shift(),m.sort()),l=0>g.indexOf(":")&&"on"+g,n=n[x.expando]?n:new x.Event(g,"object"==typeof n&&n),n.isTrigger=o?2:3,n.namespace=m.join("."),n.namespace_re=n.namespace?RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,n.result=t,n.target||(n.target=i),r=null==r?[n]:x.makeArray(r,[n]),p=x.event.special[g]||{},o||!p.trigger||p.trigger.apply(i,r)!==!1)){if(!o&&!p.noBubble&&!x.isWindow(i)){for(c=p.delegateType||g,nt.test(c+g)||(u=u.parentNode);u;u=u.parentNode)h.push(u),f=u;f===(i.ownerDocument||a)&&h.push(f.defaultView||f.parentWindow||e)}d=0;while((u=h[d++])&&!n.isPropagationStopped())n.type=d>1?c:p.bindType||g,s=(x._data(u,"events")||{})[n.type]&&x._data(u,"handle"),s&&s.apply(u,r),s=l&&u[l],s&&x.acceptData(u)&&s.apply&&s.apply(u,r)===!1&&n.preventDefault();if(n.type=g,!o&&!n.isDefaultPrevented()&&(!p._default||p._default.apply(h.pop(),r)===!1)&&x.acceptData(i)&&l&&i[g]&&!x.isWindow(i)){f=i[l],f&&(i[l]=null),x.event.triggered=g;try{i[g]()}catch(y){}x.event.triggered=t,f&&(i[l]=f)}return n.result}},dispatch:function(e){e=x.event.fix(e);var n,r,i,o,a,s=[],l=g.call(arguments),u=(x._data(this,"events")||{})[e.type]||[],c=x.event.special[e.type]||{};if(l[0]=e,e.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,e)!==!1){s=x.event.handlers.call(this,e,u),n=0;while((o=s[n++])&&!e.isPropagationStopped()){e.currentTarget=o.elem,a=0;while((i=o.handlers[a++])&&!e.isImmediatePropagationStopped())(!e.namespace_re||e.namespace_re.test(i.namespace))&&(e.handleObj=i,e.data=i.data,r=((x.event.special[i.origType]||{}).handle||i.handler).apply(o.elem,l),r!==t&&(e.result=r)===!1&&(e.preventDefault(),e.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,n){var r,i,o,a,s=[],l=n.delegateCount,u=e.target;if(l&&u.nodeType&&(!e.button||"click"!==e.type))for(;u!=this;u=u.parentNode||this)if(1===u.nodeType&&(u.disabled!==!0||"click"!==e.type)){for(o=[],a=0;l>a;a++)i=n[a],r=i.selector+" ",o[r]===t&&(o[r]=i.needsContext?x(r,this).index(u)>=0:x.find(r,this,null,[u]).length),o[r]&&o.push(i);o.length&&s.push({elem:u,handlers:o})}return n.length>l&&s.push({elem:this,handlers:n.slice(l)}),s},fix:function(e){if(e[x.expando])return e;var t,n,r,i=e.type,o=e,s=this.fixHooks[i];s||(this.fixHooks[i]=s=tt.test(i)?this.mouseHooks:et.test(i)?this.keyHooks:{}),r=s.props?this.props.concat(s.props):this.props,e=new x.Event(o),t=r.length;while(t--)n=r[t],e[n]=o[n];return e.target||(e.target=o.srcElement||a),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,o):e},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,n){var r,i,o,s=n.button,l=n.fromElement;return null==e.pageX&&null!=n.clientX&&(i=e.target.ownerDocument||a,o=i.documentElement,r=i.body,e.pageX=n.clientX+(o&&o.scrollLeft||r&&r.scrollLeft||0)-(o&&o.clientLeft||r&&r.clientLeft||0),e.pageY=n.clientY+(o&&o.scrollTop||r&&r.scrollTop||0)-(o&&o.clientTop||r&&r.clientTop||0)),!e.relatedTarget&&l&&(e.relatedTarget=l===e.target?n.toElement:l),e.which||s===t||(e.which=1&s?1:2&s?3:4&s?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==at()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===at()&&this.blur?(this.blur(),!1):t},delegateType:"focusout"},click:{trigger:function(){return x.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):t},_default:function(e){return x.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){e.result!==t&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,r){var i=x.extend(new x.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?x.event.trigger(i,null,t):x.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},x.removeEvent=a.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]===i&&(e[r]=null),e.detachEvent(r,n))},x.Event=function(e,n){return this instanceof x.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.returnValue===!1||e.getPreventDefault&&e.getPreventDefault()?it:ot):this.type=e,n&&x.extend(this,n),this.timeStamp=e&&e.timeStamp||x.now(),this[x.expando]=!0,t):new x.Event(e,n)},x.Event.prototype={isDefaultPrevented:ot,isPropagationStopped:ot,isImmediatePropagationStopped:ot,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=it,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=it,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=it,this.stopPropagation()}},x.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(e,t){x.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return(!i||i!==r&&!x.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),x.support.submitBubbles||(x.event.special.submit={setup:function(){return x.nodeName(this,"form")?!1:(x.event.add(this,"click._submit keypress._submit",function(e){var n=e.target,r=x.nodeName(n,"input")||x.nodeName(n,"button")?n.form:t;r&&!x._data(r,"submitBubbles")&&(x.event.add(r,"submit._submit",function(e){e._submit_bubble=!0}),x._data(r,"submitBubbles",!0))}),t)},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&x.event.simulate("submit",this.parentNode,e,!0))},teardown:function(){return x.nodeName(this,"form")?!1:(x.event.remove(this,"._submit"),t)}}),x.support.changeBubbles||(x.event.special.change={setup:function(){return Z.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(x.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),x.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),x.event.simulate("change",this,e,!0)})),!1):(x.event.add(this,"beforeactivate._change",function(e){var t=e.target;Z.test(t.nodeName)&&!x._data(t,"changeBubbles")&&(x.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||x.event.simulate("change",this.parentNode,e,!0)}),x._data(t,"changeBubbles",!0))}),t)},handle:function(e){var n=e.target;return this!==n||e.isSimulated||e.isTrigger||"radio"!==n.type&&"checkbox"!==n.type?e.handleObj.handler.apply(this,arguments):t},teardown:function(){return x.event.remove(this,"._change"),!Z.test(this.nodeName)}}),x.support.focusinBubbles||x.each({focus:"focusin",blur:"focusout"},function(e,t){var n=0,r=function(e){x.event.simulate(t,e.target,x.event.fix(e),!0)};x.event.special[t]={setup:function(){0===n++&&a.addEventListener(e,r,!0)},teardown:function(){0===--n&&a.removeEventListener(e,r,!0)}}}),x.fn.extend({on:function(e,n,r,i,o){var a,s;if("object"==typeof e){"string"!=typeof n&&(r=r||n,n=t);for(a in e)this.on(a,n,r,e[a],o);return this}if(null==r&&null==i?(i=n,r=n=t):null==i&&("string"==typeof n?(i=r,r=t):(i=r,r=n,n=t)),i===!1)i=ot;else if(!i)return this;return 1===o&&(s=i,i=function(e){return x().off(e),s.apply(this,arguments)},i.guid=s.guid||(s.guid=x.guid++)),this.each(function(){x.event.add(this,e,i,r,n)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,n,r){var i,o;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,x(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof e){for(o in e)this.off(o,n,e[o]);return this}return(n===!1||"function"==typeof n)&&(r=n,n=t),r===!1&&(r=ot),this.each(function(){x.event.remove(this,e,r,n)})},trigger:function(e,t){return this.each(function(){x.event.trigger(e,t,this)})},triggerHandler:function(e,n){var r=this[0];return r?x.event.trigger(e,n,r,!0):t}});var st=/^.[^:#\[\.,]*$/,lt=/^(?:parents|prev(?:Until|All))/,ut=x.expr.match.needsContext,ct={children:!0,contents:!0,next:!0,prev:!0};x.fn.extend({find:function(e){var t,n=[],r=this,i=r.length;if("string"!=typeof e)return this.pushStack(x(e).filter(function(){for(t=0;i>t;t++)if(x.contains(r[t],this))return!0}));for(t=0;i>t;t++)x.find(e,r[t],n);return n=this.pushStack(i>1?x.unique(n):n),n.selector=this.selector?this.selector+" "+e:e,n},has:function(e){var t,n=x(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(x.contains(this,n[t]))return!0})},not:function(e){return this.pushStack(ft(this,e||[],!0))},filter:function(e){return this.pushStack(ft(this,e||[],!1))},is:function(e){return!!ft(this,"string"==typeof e&&ut.test(e)?x(e):e||[],!1).length},closest:function(e,t){var n,r=0,i=this.length,o=[],a=ut.test(e)||"string"!=typeof e?x(e,t||this.context):0;for(;i>r;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(11>n.nodeType&&(a?a.index(n)>-1:1===n.nodeType&&x.find.matchesSelector(n,e))){n=o.push(n);break}return this.pushStack(o.length>1?x.unique(o):o)},index:function(e){return e?"string"==typeof e?x.inArray(this[0],x(e)):x.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){var n="string"==typeof e?x(e,t):x.makeArray(e&&e.nodeType?[e]:e),r=x.merge(this.get(),n);return this.pushStack(x.unique(r))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}});function pt(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}x.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return x.dir(e,"parentNode")},parentsUntil:function(e,t,n){return x.dir(e,"parentNode",n)},next:function(e){return pt(e,"nextSibling")},prev:function(e){return pt(e,"previousSibling")},nextAll:function(e){return x.dir(e,"nextSibling")},prevAll:function(e){return x.dir(e,"previousSibling")},nextUntil:function(e,t,n){return x.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return x.dir(e,"previousSibling",n)},siblings:function(e){return x.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return x.sibling(e.firstChild)},contents:function(e){return x.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:x.merge([],e.childNodes)}},function(e,t){x.fn[e]=function(n,r){var i=x.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=x.filter(r,i)),this.length>1&&(ct[e]||(i=x.unique(i)),lt.test(e)&&(i=i.reverse())),this.pushStack(i)}}),x.extend({filter:function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?x.find.matchesSelector(r,e)?[r]:[]:x.find.matches(e,x.grep(t,function(e){return 1===e.nodeType}))},dir:function(e,n,r){var i=[],o=e[n];while(o&&9!==o.nodeType&&(r===t||1!==o.nodeType||!x(o).is(r)))1===o.nodeType&&i.push(o),o=o[n];return i},sibling:function(e,t){var n=[];for(;e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}});function ft(e,t,n){if(x.isFunction(t))return x.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return x.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(st.test(t))return x.filter(t,e,n);t=x.filter(t,e)}return x.grep(e,function(e){return x.inArray(e,t)>=0!==n})}function dt(e){var t=ht.split("|"),n=e.createDocumentFragment();if(n.createElement)while(t.length)n.createElement(t.pop());return n}var ht="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",gt=/ jQuery\d+="(?:null|\d+)"/g,mt=RegExp("<(?:"+ht+")[\\s/>]","i"),yt=/^\s+/,vt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bt=/<([\w:]+)/,xt=/\s*$/g,At={option:[1,""],legend:[1,"
    ","
    "],area:[1,"",""],param:[1,"",""],thead:[1,"","
    "],tr:[2,"","
    "],col:[2,"","
    "],td:[3,"","
    "],_default:x.support.htmlSerialize?[0,"",""]:[1,"X
    ","
    "]},jt=dt(a),Dt=jt.appendChild(a.createElement("div"));At.optgroup=At.option,At.tbody=At.tfoot=At.colgroup=At.caption=At.thead,At.th=At.td,x.fn.extend({text:function(e){return x.access(this,function(e){return e===t?x.text(this):this.empty().append((this[0]&&this[0].ownerDocument||a).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){var n,r=e?x.filter(e,this):this,i=0;for(;null!=(n=r[i]);i++)t||1!==n.nodeType||x.cleanData(Ft(n)),n.parentNode&&(t&&x.contains(n.ownerDocument,n)&&_t(Ft(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){var e,t=0;for(;null!=(e=this[t]);t++){1===e.nodeType&&x.cleanData(Ft(e,!1));while(e.firstChild)e.removeChild(e.firstChild);e.options&&x.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return x.clone(this,e,t)})},html:function(e){return x.access(this,function(e){var n=this[0]||{},r=0,i=this.length;if(e===t)return 1===n.nodeType?n.innerHTML.replace(gt,""):t;if(!("string"!=typeof e||Tt.test(e)||!x.support.htmlSerialize&&mt.test(e)||!x.support.leadingWhitespace&&yt.test(e)||At[(bt.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(vt,"<$1>");try{for(;i>r;r++)n=this[r]||{},1===n.nodeType&&(x.cleanData(Ft(n,!1)),n.innerHTML=e);n=0}catch(o){}}n&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=x.map(this,function(e){return[e.nextSibling,e.parentNode]}),t=0;return this.domManip(arguments,function(n){var r=e[t++],i=e[t++];i&&(r&&r.parentNode!==i&&(r=this.nextSibling),x(this).remove(),i.insertBefore(n,r))},!0),t?this:this.remove()},detach:function(e){return this.remove(e,!0)},domManip:function(e,t,n){e=d.apply([],e);var r,i,o,a,s,l,u=0,c=this.length,p=this,f=c-1,h=e[0],g=x.isFunction(h);if(g||!(1>=c||"string"!=typeof h||x.support.checkClone)&&Nt.test(h))return this.each(function(r){var i=p.eq(r);g&&(e[0]=h.call(this,r,i.html())),i.domManip(e,t,n)});if(c&&(l=x.buildFragment(e,this[0].ownerDocument,!1,!n&&this),r=l.firstChild,1===l.childNodes.length&&(l=r),r)){for(a=x.map(Ft(l,"script"),Ht),o=a.length;c>u;u++)i=l,u!==f&&(i=x.clone(i,!0,!0),o&&x.merge(a,Ft(i,"script"))),t.call(this[u],i,u);if(o)for(s=a[a.length-1].ownerDocument,x.map(a,qt),u=0;o>u;u++)i=a[u],kt.test(i.type||"")&&!x._data(i,"globalEval")&&x.contains(s,i)&&(i.src?x._evalUrl(i.src):x.globalEval((i.text||i.textContent||i.innerHTML||"").replace(St,"")));l=r=null}return this}});function Lt(e,t){return x.nodeName(e,"table")&&x.nodeName(1===t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function Ht(e){return e.type=(null!==x.find.attr(e,"type"))+"/"+e.type,e}function qt(e){var t=Et.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function _t(e,t){var n,r=0;for(;null!=(n=e[r]);r++)x._data(n,"globalEval",!t||x._data(t[r],"globalEval"))}function Mt(e,t){if(1===t.nodeType&&x.hasData(e)){var n,r,i,o=x._data(e),a=x._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)x.event.add(t,n,s[n][r])}a.data&&(a.data=x.extend({},a.data))}}function Ot(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!x.support.noCloneEvent&&t[x.expando]){i=x._data(t);for(r in i.events)x.removeEvent(t,r,i.handle);t.removeAttribute(x.expando)}"script"===n&&t.text!==e.text?(Ht(t).text=e.text,qt(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),x.support.html5Clone&&e.innerHTML&&!x.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&Ct.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}x.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){x.fn[e]=function(e){var n,r=0,i=[],o=x(e),a=o.length-1;for(;a>=r;r++)n=r===a?this:this.clone(!0),x(o[r])[t](n),h.apply(i,n.get());return this.pushStack(i)}});function Ft(e,n){var r,o,a=0,s=typeof e.getElementsByTagName!==i?e.getElementsByTagName(n||"*"):typeof e.querySelectorAll!==i?e.querySelectorAll(n||"*"):t;if(!s)for(s=[],r=e.childNodes||e;null!=(o=r[a]);a++)!n||x.nodeName(o,n)?s.push(o):x.merge(s,Ft(o,n));return n===t||n&&x.nodeName(e,n)?x.merge([e],s):s}function Bt(e){Ct.test(e.type)&&(e.defaultChecked=e.checked)}x.extend({clone:function(e,t,n){var r,i,o,a,s,l=x.contains(e.ownerDocument,e);if(x.support.html5Clone||x.isXMLDoc(e)||!mt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Dt.innerHTML=e.outerHTML,Dt.removeChild(o=Dt.firstChild)),!(x.support.noCloneEvent&&x.support.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||x.isXMLDoc(e)))for(r=Ft(o),s=Ft(e),a=0;null!=(i=s[a]);++a)r[a]&&Ot(i,r[a]);if(t)if(n)for(s=s||Ft(e),r=r||Ft(o),a=0;null!=(i=s[a]);a++)Mt(i,r[a]);else Mt(e,o);return r=Ft(o,"script"),r.length>0&&_t(r,!l&&Ft(e,"script")),r=s=i=null,o},buildFragment:function(e,t,n,r){var i,o,a,s,l,u,c,p=e.length,f=dt(t),d=[],h=0;for(;p>h;h++)if(o=e[h],o||0===o)if("object"===x.type(o))x.merge(d,o.nodeType?[o]:o);else if(wt.test(o)){s=s||f.appendChild(t.createElement("div")),l=(bt.exec(o)||["",""])[1].toLowerCase(),c=At[l]||At._default,s.innerHTML=c[1]+o.replace(vt,"<$1>")+c[2],i=c[0];while(i--)s=s.lastChild;if(!x.support.leadingWhitespace&&yt.test(o)&&d.push(t.createTextNode(yt.exec(o)[0])),!x.support.tbody){o="table"!==l||xt.test(o)?""!==c[1]||xt.test(o)?0:s:s.firstChild,i=o&&o.childNodes.length;while(i--)x.nodeName(u=o.childNodes[i],"tbody")&&!u.childNodes.length&&o.removeChild(u)}x.merge(d,s.childNodes),s.textContent="";while(s.firstChild)s.removeChild(s.firstChild);s=f.lastChild}else d.push(t.createTextNode(o));s&&f.removeChild(s),x.support.appendChecked||x.grep(Ft(d,"input"),Bt),h=0;while(o=d[h++])if((!r||-1===x.inArray(o,r))&&(a=x.contains(o.ownerDocument,o),s=Ft(f.appendChild(o),"script"),a&&_t(s),n)){i=0;while(o=s[i++])kt.test(o.type||"")&&n.push(o)}return s=null,f},cleanData:function(e,t){var n,r,o,a,s=0,l=x.expando,u=x.cache,c=x.support.deleteExpando,f=x.event.special;for(;null!=(n=e[s]);s++)if((t||x.acceptData(n))&&(o=n[l],a=o&&u[o])){if(a.events)for(r in a.events)f[r]?x.event.remove(n,r):x.removeEvent(n,r,a.handle); +u[o]&&(delete u[o],c?delete n[l]:typeof n.removeAttribute!==i?n.removeAttribute(l):n[l]=null,p.push(o))}},_evalUrl:function(e){return x.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})}}),x.fn.extend({wrapAll:function(e){if(x.isFunction(e))return this.each(function(t){x(this).wrapAll(e.call(this,t))});if(this[0]){var t=x(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstChild&&1===e.firstChild.nodeType)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return x.isFunction(e)?this.each(function(t){x(this).wrapInner(e.call(this,t))}):this.each(function(){var t=x(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=x.isFunction(e);return this.each(function(n){x(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){x.nodeName(this,"body")||x(this).replaceWith(this.childNodes)}).end()}});var Pt,Rt,Wt,$t=/alpha\([^)]*\)/i,It=/opacity\s*=\s*([^)]*)/,zt=/^(top|right|bottom|left)$/,Xt=/^(none|table(?!-c[ea]).+)/,Ut=/^margin/,Vt=RegExp("^("+w+")(.*)$","i"),Yt=RegExp("^("+w+")(?!px)[a-z%]+$","i"),Jt=RegExp("^([+-])=("+w+")","i"),Gt={BODY:"block"},Qt={position:"absolute",visibility:"hidden",display:"block"},Kt={letterSpacing:0,fontWeight:400},Zt=["Top","Right","Bottom","Left"],en=["Webkit","O","Moz","ms"];function tn(e,t){if(t in e)return t;var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=en.length;while(i--)if(t=en[i]+n,t in e)return t;return r}function nn(e,t){return e=t||e,"none"===x.css(e,"display")||!x.contains(e.ownerDocument,e)}function rn(e,t){var n,r,i,o=[],a=0,s=e.length;for(;s>a;a++)r=e[a],r.style&&(o[a]=x._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&nn(r)&&(o[a]=x._data(r,"olddisplay",ln(r.nodeName)))):o[a]||(i=nn(r),(n&&"none"!==n||!i)&&x._data(r,"olddisplay",i?n:x.css(r,"display"))));for(a=0;s>a;a++)r=e[a],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}x.fn.extend({css:function(e,n){return x.access(this,function(e,n,r){var i,o,a={},s=0;if(x.isArray(n)){for(o=Rt(e),i=n.length;i>s;s++)a[n[s]]=x.css(e,n[s],!1,o);return a}return r!==t?x.style(e,n,r):x.css(e,n)},e,n,arguments.length>1)},show:function(){return rn(this,!0)},hide:function(){return rn(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){nn(this)?x(this).show():x(this).hide()})}}),x.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Wt(e,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":x.support.cssFloat?"cssFloat":"styleFloat"},style:function(e,n,r,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,a,s,l=x.camelCase(n),u=e.style;if(n=x.cssProps[l]||(x.cssProps[l]=tn(u,l)),s=x.cssHooks[n]||x.cssHooks[l],r===t)return s&&"get"in s&&(o=s.get(e,!1,i))!==t?o:u[n];if(a=typeof r,"string"===a&&(o=Jt.exec(r))&&(r=(o[1]+1)*o[2]+parseFloat(x.css(e,n)),a="number"),!(null==r||"number"===a&&isNaN(r)||("number"!==a||x.cssNumber[l]||(r+="px"),x.support.clearCloneStyle||""!==r||0!==n.indexOf("background")||(u[n]="inherit"),s&&"set"in s&&(r=s.set(e,r,i))===t)))try{u[n]=r}catch(c){}}},css:function(e,n,r,i){var o,a,s,l=x.camelCase(n);return n=x.cssProps[l]||(x.cssProps[l]=tn(e.style,l)),s=x.cssHooks[n]||x.cssHooks[l],s&&"get"in s&&(a=s.get(e,!0,r)),a===t&&(a=Wt(e,n,i)),"normal"===a&&n in Kt&&(a=Kt[n]),""===r||r?(o=parseFloat(a),r===!0||x.isNumeric(o)?o||0:a):a}}),e.getComputedStyle?(Rt=function(t){return e.getComputedStyle(t,null)},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s.getPropertyValue(n)||s[n]:t,u=e.style;return s&&(""!==l||x.contains(e.ownerDocument,e)||(l=x.style(e,n)),Yt.test(l)&&Ut.test(n)&&(i=u.width,o=u.minWidth,a=u.maxWidth,u.minWidth=u.maxWidth=u.width=l,l=s.width,u.width=i,u.minWidth=o,u.maxWidth=a)),l}):a.documentElement.currentStyle&&(Rt=function(e){return e.currentStyle},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s[n]:t,u=e.style;return null==l&&u&&u[n]&&(l=u[n]),Yt.test(l)&&!zt.test(n)&&(i=u.left,o=e.runtimeStyle,a=o&&o.left,a&&(o.left=e.currentStyle.left),u.left="fontSize"===n?"1em":l,l=u.pixelLeft+"px",u.left=i,a&&(o.left=a)),""===l?"auto":l});function on(e,t,n){var r=Vt.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function an(e,t,n,r,i){var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;for(;4>o;o+=2)"margin"===n&&(a+=x.css(e,n+Zt[o],!0,i)),r?("content"===n&&(a-=x.css(e,"padding"+Zt[o],!0,i)),"margin"!==n&&(a-=x.css(e,"border"+Zt[o]+"Width",!0,i))):(a+=x.css(e,"padding"+Zt[o],!0,i),"padding"!==n&&(a+=x.css(e,"border"+Zt[o]+"Width",!0,i)));return a}function sn(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=Rt(e),a=x.support.boxSizing&&"border-box"===x.css(e,"boxSizing",!1,o);if(0>=i||null==i){if(i=Wt(e,t,o),(0>i||null==i)&&(i=e.style[t]),Yt.test(i))return i;r=a&&(x.support.boxSizingReliable||i===e.style[t]),i=parseFloat(i)||0}return i+an(e,t,n||(a?"border":"content"),r,o)+"px"}function ln(e){var t=a,n=Gt[e];return n||(n=un(e,t),"none"!==n&&n||(Pt=(Pt||x("