From 6d47f2e58220d125f0fe46bdf5dea82d94edd83f Mon Sep 17 00:00:00 2001 From: Aaron Newton Date: Thu, 29 Aug 2013 14:53:52 -0700 Subject: [PATCH] Bootstrap 3.0 support * new class: Bootstrap.Affix and the associated behavior * Popovers (and tooltips if you like) can now have their 'trigger' option set to 'click' which allows you to show them on click instead of mouseover if you like. * Delegator.BS.ShowPopup now allows you to just use a #href reference to the id of the popup to show. * Dropdown now allows for you to have its behavior on the Dropdown itself instead of a container. * Bootstrap.Popup now expects that the layout matches Bootstrap 3. *This is a breaking change* but compatibility has been left in place for Bootstrap 2. For this to work, you must set `Bootstrap.version = 2` in your code. * Bootstrap.Popover's offset defaults are now zero unless `Bootstrap.version` == 2 --- Docs/Behaviors/Behavior.BS.Affix.md | 22 + Docs/UI/Bootstrap.Affix.md | 91 + Docs/UI/Bootstrap.Tooltip.md | 2 +- Examples/.DS_Store | Bin 6148 -> 0 bytes Examples/img/glyphicons-halflings-white.png | Bin 8777 -> 0 bytes Examples/index.html | 2149 ++-- Examples/index_files/bootstrap.css | 8638 +++++++++---- .../{mootools_and_boostrap.js => build.js} | 10652 +++++++++------- Examples/index_files/docs.css | 1550 ++- Examples/index_files/grid-18px.png | Bin 1118 -> 0 bytes .../index_files/{jquery.js => jquery.min.js} | 0 Examples/index_files/minibuttons.css | 69 - Examples/index_files/reset.css | 100 + Examples/index_files/shared.css | 13 + Examples/index_files/tests.css | 168 + Source/Behaviors/Behavior.BS.Affix.js | 42 + Source/Behaviors/Behavior.BS.Popover.js | 8 +- .../Delegator.BS.ShowPopup.js | 5 +- Source/UI/Bootstrap.Affix.js | 125 + Source/UI/Bootstrap.Dropdown.js | 4 +- Source/UI/Bootstrap.Popover.js | 2 +- Source/UI/Bootstrap.Popup.js | 21 +- Source/UI/Bootstrap.Tooltip.js | 15 +- Source/UI/Bootstrap.js | 4 +- Tests/Interactive/Bootstrap.mako | 2149 ++-- Tests/Interactive/_assets/.DS_Store | Bin 6148 -> 0 bytes .../_assets/bootstrap-responsive.css | 567 - Tests/Interactive/_assets/bootstrap.css | 3363 ----- Tests/Interactive/_assets/css/bootstrap.css | 6805 ++++++++++ .../Interactive/_assets/css/bootstrap.min.css | 845 ++ Tests/Interactive/_assets/css/docs.css | 1084 ++ .../_assets/css/pygments-manni.css | 66 + Tests/Interactive/_assets/docs.css | 772 -- .../fonts/glyphicons-halflings-regular.eot | Bin 0 -> 25271 bytes .../fonts/glyphicons-halflings-regular.svg | 228 + .../fonts/glyphicons-halflings-regular.ttf | Bin 0 -> 39816 bytes .../fonts/glyphicons-halflings-regular.woff | Bin 0 -> 30354 bytes .../_assets/glyphicons-halflings-white.png | Bin 4352 -> 0 bytes .../_assets/glyphicons-halflings.png | Bin 4352 -> 0 bytes Tests/Interactive/_assets/grid-18px.png | Bin 1118 -> 0 bytes Tests/Interactive/_assets/html5shiv.js | 8 + Tests/Interactive/_assets/respond.min.js | 6 + Tests/Specs/Source/Behavior.BS.Affix.js | 42 + Tests/Specs/package.yml | 1 + package.yml | 4 +- 45 files changed, 25207 insertions(+), 14413 deletions(-) create mode 100644 Docs/Behaviors/Behavior.BS.Affix.md create mode 100644 Docs/UI/Bootstrap.Affix.md delete mode 100644 Examples/.DS_Store delete mode 100644 Examples/img/glyphicons-halflings-white.png rename Examples/index_files/{mootools_and_boostrap.js => build.js} (85%) delete mode 100644 Examples/index_files/grid-18px.png rename Examples/index_files/{jquery.js => jquery.min.js} (100%) delete mode 100644 Examples/index_files/minibuttons.css create mode 100644 Examples/index_files/reset.css create mode 100644 Examples/index_files/shared.css create mode 100644 Examples/index_files/tests.css create mode 100644 Source/Behaviors/Behavior.BS.Affix.js rename Source/{UI => Behaviors}/Delegator.BS.ShowPopup.js (74%) create mode 100644 Source/UI/Bootstrap.Affix.js delete mode 100644 Tests/Interactive/_assets/.DS_Store delete mode 100644 Tests/Interactive/_assets/bootstrap-responsive.css delete mode 100644 Tests/Interactive/_assets/bootstrap.css create mode 100755 Tests/Interactive/_assets/css/bootstrap.css create mode 100755 Tests/Interactive/_assets/css/bootstrap.min.css create mode 100644 Tests/Interactive/_assets/css/docs.css create mode 100644 Tests/Interactive/_assets/css/pygments-manni.css delete mode 100644 Tests/Interactive/_assets/docs.css create mode 100755 Tests/Interactive/_assets/fonts/glyphicons-halflings-regular.eot create mode 100755 Tests/Interactive/_assets/fonts/glyphicons-halflings-regular.svg create mode 100755 Tests/Interactive/_assets/fonts/glyphicons-halflings-regular.ttf create mode 100755 Tests/Interactive/_assets/fonts/glyphicons-halflings-regular.woff delete mode 100644 Tests/Interactive/_assets/glyphicons-halflings-white.png delete mode 100644 Tests/Interactive/_assets/glyphicons-halflings.png delete mode 100644 Tests/Interactive/_assets/grid-18px.png create mode 100644 Tests/Interactive/_assets/html5shiv.js create mode 100644 Tests/Interactive/_assets/respond.min.js create mode 100644 Tests/Specs/Source/Behavior.BS.Affix.js diff --git a/Docs/Behaviors/Behavior.BS.Affix.md b/Docs/Behaviors/Behavior.BS.Affix.md new file mode 100644 index 0000000..422a223 --- /dev/null +++ b/Docs/Behaviors/Behavior.BS.Affix.md @@ -0,0 +1,22 @@ +Behavior Filter: Behavior.BS.Affix +=================================== + +A behavior filter to instantiate [Bootstrap](http://twitter.github.com/bootstrap/#affix) Affix functionality. + +### Demo / Fancy Docs + +[http://anutron.github.com/mootools-bootstrap/#affix](http://anutron.github.com/mootools-bootstrap/#affix) + + +### Example + + I stick around! + +### Options + +* top - (*number*) The distance from the top that the user must scroll before the affix class is added and the affix-top class is removed. Defaults to 0. +* bottom - (*number*) The distance from the top that the user must scroll before the affix class is removed and the affix-bottom class is added. Specify a negative number to have it measure from the bottom of the window height. +* classNames - (*object*) The class names to apply in the various states. Defaults to `top: "affix-top", bottom: "affix-bottom", affixed: "affix"`. These should be defined in your CSS as you like. You can also manually affix location for the element using the events listed below. diff --git a/Docs/UI/Bootstrap.Affix.md b/Docs/UI/Bootstrap.Affix.md new file mode 100644 index 0000000..9c6502f --- /dev/null +++ b/Docs/UI/Bootstrap.Affix.md @@ -0,0 +1,91 @@ +Class: Bootstrap.Affix {#Bootstrap-Affix} +============================= + +Implements the basic functionality of [Bootstrap](http://anutron.github.com/mootools-bootstrap/#tooltip) Affix which adds a class to an element when it is above, in, and below a given scroll range. + +### Implements + +- [Options][] +- [Events][] + +Bootstrap.Affix Method: constructor +----------------------------- + +### Syntax + + new Bootstrap.Affix(element[, options]); + +### Arguments + +1. element - (*mixed*) A string of the id for an Element or an Element that should be changed when the window scrolls. +2. options - (*object*, optional) a key/value object of options + +### Options + +* top - (*number*) The distance from the top that the user must scroll before the affix class is added and the affix-top class is removed. Defaults to 0. +* bottom - (*number*) The distance from the top that the user must scroll before the affix class is removed and the affix-bottom class is added. Specify a negative number to have it measure from the bottom of the window height. +* classNames - (*object*) The class names to apply in the various states. Defaults to `top: "affix-top", bottom: "affix-bottom", affixed: "affix"`. These should be defined in your CSS as you like. You can also manually affix location for the element using the events listed below. + +### Events + +* pin - (*function*) Fired when the element is below the top and above the bottom (i.e. it is within the scroll boundaries). +* unPin - (*function*) Fired when the element is out of scroll range. If it is below the bottom of the range, this event is passed a boolean `true`. + +Bootstrap.Affix Method: attach {#Bootstrap-Affix:attach} +------------------------------------------------ + +Attach scroll listeners (enable the instance). + +### Syntax + + myAffix.attach(); + +### Returns + +* (*object*) This Bootstrap.Affix instance. + +Bootstrap.Affix Method: detach {#Bootstrap-Affix:detach} +------------------------------------------------ + +Detaches the scroll listeners (disables the instance). + +### Syntax + + myAffix.detach(); + +### Returns + +* (*object*) This Bootstrap.Affix instance. + +Bootstrap.Affix Method: pin {#Bootstrap-Affix:pin} +------------------------------------------------ + +Fires the pin event and adds the pinned-state class. + +### Syntax + + myAffix.pin(); + +### Returns + +* (*object*) This Bootstrap.Affix instance. + +Bootstrap.Affix Method: unpin {#Bootstrap-Affix:unpin} +------------------------------------------------ + +Fires the unPin event and adds the unpinned-state class. + +### Syntax + + myAffix.unpin([isBottom]); + +### Arguments + +1. isBottom - (*boolean*) if `true` adds the bottom-state class. Otherwise the top. + +### Returns + +* (*object*) This Bootstrap.Affix instance. + +[Options]: http;//mootools.net/core/Class/Class.Extras#Options +[Events]: http;//mootools.net/core/Class/Class.Extras#Events \ No newline at end of file diff --git a/Docs/UI/Bootstrap.Tooltip.md b/Docs/UI/Bootstrap.Tooltip.md index 80f93cd..9a13309 100644 --- a/Docs/UI/Bootstrap.Tooltip.md +++ b/Docs/UI/Bootstrap.Tooltip.md @@ -34,7 +34,7 @@ Bootstrap.Tooltip Method: constructor * override - (*string*) The tip value used instead of the `title` value of the target element. * offset - (*number* or *object*) The offset of the tip. If a number, will be used for the y offset for `top` and `bottom` located tips, x for `left` and `right` located tips. If an object, should contain `.y` and/or `.x` numerical values. Defaults to `0`. * title - (*string*) The element property to use for the tip value. Defaults to `title`. -* trigger - (*string*) The event type to attach to the target element to show the tip. Choose from `hover`, `focus`, or `manual`. +* trigger - (*string*) The event type to attach to the target element to show the tip. Choose from `hover`, `focus`, `click`, or 'manual'. * onOverflow - (*boolean*) Only show the tip if the element's content is overflown (i.e. it's scroll-height or scroll-width is greater than the height or width of the element). Defaults to `false`. * getContent - (*function*) A function that returns the tip value. By default, it retrieves the value of the `title` option from the target element. diff --git a/Examples/.DS_Store b/Examples/.DS_Store deleted file mode 100644 index e4f916ec8a208e02c905d21aef01e42d216d5815..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHK%}T>S5T0$Trc|L9L2rxaB8`Q5@eo18&e^qh2dfZ%|1nFW2~4f`)3vm`knr096V4 YB^ij0!CWJHQ20kc(ZB;U@T&}b0A@=|?*IS* diff --git a/Examples/img/glyphicons-halflings-white.png b/Examples/img/glyphicons-halflings-white.png deleted file mode 100644 index 3bf6484a29d8da269f9bc874b25493a45fae3bae..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 8777 zcmZvC1yGz#v+m*$LXcp=A$ZWB0fL7wNbp_U*$~{_gL`my3oP#L!5tQYy99Ta`+g_q zKlj|KJ2f@c)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6Av2wyZTG!E2KSW2* zGRLQkQU;Oz##ie-Z4fI)WSRxn$(ZcD;TL+;^r=a4(G~H3ZhK$lSXZj?cvyY8%d9JM zzc3#pD^W_QnWy#rx#;c&N@sqHhrnHRmj#i;s%zLm6SE(n&BWpd&f7>XnjV}OlZntI70fq%8~9<7 zMYaw`E-rp49-oC1N_uZTo)Cu%RR2QWdHpzQIcNsoDp`3xfP+`gI?tVQZ4X={qU?(n zV>0ASES^Xuc;9JBji{)RnFL(Lez;8XbB1uWaMp@p?7xhXk6V#!6B@aP4Rz7-K%a>i z?fvf}va_DGUXlI#4--`A3qK7J?-HwnG7O~H2;zR~RLW)_^#La!=}+>KW#anZ{|^D3 B7G?kd diff --git a/Examples/index.html b/Examples/index.html index b5d82a6..8b6e450 100644 --- a/Examples/index.html +++ b/Examples/index.html @@ -1,953 +1,1370 @@ - - - - - Bootstrap, from Twitter - - - - - - - - - - - - - - - - - - - - - - Fork me on GitHub - - - \ No newline at end of file diff --git a/Examples/index_files/bootstrap.css b/Examples/index_files/bootstrap.css index 7babce5..bbda4ee 100644 --- a/Examples/index_files/bootstrap.css +++ b/Examples/index_files/bootstrap.css @@ -1,12 +1,15 @@ /*! - * Bootstrap v2.0.0 + * Bootstrap v3.0.0 * - * Copyright 2012 Twitter, Inc + * Copyright 2013 Twitter, Inc * Licensed under the Apache License v2.0 * http://www.apache.org/licenses/LICENSE-2.0 * - * Designed and built with all the love in the world @twitter by @mdo and @fat. + * Designed and built with all the love in the world by @mdo and @fat. */ + +/*! normalize.css v2.1.0 | MIT License | git.io/normalize */ + article, aside, details, @@ -15,3349 +18,6788 @@ figure, footer, header, hgroup, +main, nav, -section { +section, +summary { display: block; } -audio, canvas, video { + +audio, +canvas, +video { display: inline-block; - *display: inline; - *zoom: 1; } + audio:not([controls]) { display: none; + height: 0; +} + +[hidden] { + display: none; } + html { - font-size: 100%; + font-family: sans-serif; -webkit-text-size-adjust: 100%; - -ms-text-size-adjust: 100%; + -ms-text-size-adjust: 100%; +} + +body { + margin: 0; } + a:focus { outline: thin dotted; - outline: 5px auto -webkit-focus-ring-color; - outline-offset: -2px; } -a:hover, a:active { + +a:active, +a:hover { outline: 0; } -sub, sup { + +h1 { + margin: 0.67em 0; + font-size: 2em; +} + +abbr[title] { + border-bottom: 1px dotted; +} + +b, +strong { + font-weight: bold; +} + +dfn { + font-style: italic; +} + +hr { + height: 0; + -moz-box-sizing: content-box; + box-sizing: content-box; +} + +mark { + color: #000; + background: #ff0; +} + +code, +kbd, +pre, +samp { + font-family: monospace, serif; + font-size: 1em; +} + +pre { + white-space: pre-wrap; +} + +q { + quotes: "\201C" "\201D" "\2018" "\2019"; +} + +small { + font-size: 80%; +} + +sub, +sup { position: relative; font-size: 75%; line-height: 0; vertical-align: baseline; } + sup { top: -0.5em; } + sub { bottom: -0.25em; } + img { - max-width: 100%; - height: auto; border: 0; - -ms-interpolation-mode: bicubic; } + +svg:not(:root) { + overflow: hidden; +} + +figure { + margin: 0; +} + +fieldset { + padding: 0.35em 0.625em 0.75em; + margin: 0 2px; + border: 1px solid #c0c0c0; +} + +legend { + padding: 0; + border: 0; +} + button, input, select, textarea { margin: 0; + font-family: inherit; font-size: 100%; - vertical-align: middle; } -button, input { - *overflow: visible; + +button, +input { line-height: normal; } -button::-moz-focus-inner, input::-moz-focus-inner { - padding: 0; - border: 0; + +button, +select { + text-transform: none; } + button, -input[type="button"], +html input[type="button"], input[type="reset"], input[type="submit"] { cursor: pointer; -webkit-appearance: button; } + +button[disabled], +html input[disabled] { + cursor: default; +} + +input[type="checkbox"], +input[type="radio"] { + padding: 0; + box-sizing: border-box; +} + input[type="search"] { - -webkit-appearance: textfield; -webkit-box-sizing: content-box; - -moz-box-sizing: content-box; - box-sizing: content-box; + -moz-box-sizing: content-box; + box-sizing: content-box; + -webkit-appearance: textfield; } -input[type="search"]::-webkit-search-decoration, input[type="search"]::-webkit-search-cancel-button { + +input[type="search"]::-webkit-search-cancel-button, +input[type="search"]::-webkit-search-decoration { -webkit-appearance: none; } + +button::-moz-focus-inner, +input::-moz-focus-inner { + padding: 0; + border: 0; +} + textarea { overflow: auto; vertical-align: top; } + +table { + border-collapse: collapse; + border-spacing: 0; +} + +@media print { + * { + color: #000 !important; + text-shadow: none !important; + background: transparent !important; + box-shadow: none !important; + } + a, + a:visited { + 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; + } + img { + max-width: 100% !important; + } + @page { + margin: 2cm .5cm; + } + p, + h2, + h3 { + orphans: 3; + widows: 3; + } + h2, + h3 { + page-break-after: avoid; + } + .navbar { + display: none; + } + .table td, + .table th { + background-color: #fff !important; + } + .btn > .caret, + .dropup > .btn > .caret { + border-top-color: #000 !important; + } + .label { + border: 1px solid #000; + } + .table { + border-collapse: collapse !important; + } + .table-bordered th, + .table-bordered td { + border: 1px solid #ddd !important; + } +} + +*, +*:before, +*:after { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +html { + font-size: 62.5%; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); +} + body { - margin: 0; font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; - font-size: 13px; - line-height: 18px; + font-size: 14px; + line-height: 1.428571429; color: #333333; background-color: #ffffff; } + +input, +button, +select, +textarea { + font-family: inherit; + font-size: inherit; + line-height: inherit; +} + +button, +input, +select[multiple], +textarea { + background-image: none; +} + a { - color: #0088cc; + color: #428bca; text-decoration: none; } -a:hover { - color: #005580; + +a:hover, +a:focus { + color: #2a6496; text-decoration: underline; } -.row { - margin-left: -20px; - *zoom: 1; -} -.row:before, .row:after { - display: table; - content: ""; + +a:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; } -.row:after { - clear: both; + +img { + vertical-align: middle; } -[class*="span"] { - float: left; - margin-left: 20px; + +.img-responsive { + display: block; + height: auto; + max-width: 100%; } -.span1 { - width: 60px; + +.img-rounded { + border-radius: 6px; } -.span2 { - width: 140px; + +.img-thumbnail { + display: inline-block; + height: auto; + max-width: 100%; + padding: 4px; + line-height: 1.428571429; + background-color: #ffffff; + border: 1px solid #dddddd; + border-radius: 4px; + -webkit-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; } -.span3 { - width: 220px; + +.img-circle { + border-radius: 50%; } -.span4 { - width: 300px; + +hr { + margin-top: 20px; + margin-bottom: 20px; + border: 0; + border-top: 1px solid #eeeeee; } -.span5 { - width: 380px; + +.sr-only { + position: absolute; + width: 1px; + height: 1px; + padding: 0; + margin: -1px; + overflow: hidden; + clip: rect(0 0 0 0); + border: 0; } -.span6 { - width: 460px; + +p { + margin: 0 0 10px; } -.span7 { - width: 540px; + +.lead { + margin-bottom: 20px; + font-size: 16.099999999999998px; + font-weight: 200; + line-height: 1.4; } -.span8 { - width: 620px; + +@media (min-width: 768px) { + .lead { + font-size: 21px; + } } -.span9 { - width: 700px; + +small { + font-size: 85%; } -.span10 { - width: 780px; + +cite { + font-style: normal; } -.span11 { - width: 860px; + +.text-muted { + color: #999999; } -.span12, .container { - width: 940px; + +.text-primary { + color: #428bca; } -.offset1 { - margin-left: 100px; + +.text-warning { + color: #c09853; } -.offset2 { - margin-left: 180px; + +.text-danger { + color: #b94a48; } -.offset3 { - margin-left: 260px; + +.text-success { + color: #468847; } -.offset4 { - margin-left: 340px; + +.text-info { + color: #3a87ad; } -.offset5 { - margin-left: 420px; + +.text-left { + text-align: left; } -.offset6 { - margin-left: 500px; + +.text-right { + text-align: right; } -.offset7 { - margin-left: 580px; + +.text-center { + text-align: center; } -.offset8 { - margin-left: 660px; + +h1, +h2, +h3, +h4, +h5, +h6, +.h1, +.h2, +.h3, +.h4, +.h5, +.h6 { + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-weight: 500; + line-height: 1.1; } -.offset9 { - margin-left: 740px; + +h1 small, +h2 small, +h3 small, +h4 small, +h5 small, +h6 small, +.h1 small, +.h2 small, +.h3 small, +.h4 small, +.h5 small, +.h6 small { + font-weight: normal; + line-height: 1; + color: #999999; } -.offset10 { - margin-left: 820px; + +h1, +h2, +h3 { + margin-top: 20px; + margin-bottom: 10px; } -.offset11 { - margin-left: 900px; + +h4, +h5, +h6 { + margin-top: 10px; + margin-bottom: 10px; } -.row-fluid { - width: 100%; - *zoom: 1; + +h1, +.h1 { + font-size: 36px; } -.row-fluid:before, .row-fluid:after { - display: table; - content: ""; + +h2, +.h2 { + font-size: 30px; } -.row-fluid:after { - clear: both; + +h3, +.h3 { + font-size: 24px; } -.row-fluid > [class*="span"] { - float: left; - margin-left: 2.127659574%; -} -.row-fluid > [class*="span"]:first-child { - margin-left: 0; -} -.row-fluid .span1 { - width: 6.382978723%; -} -.row-fluid .span2 { - width: 14.89361702%; -} -.row-fluid .span3 { - width: 23.404255317%; -} -.row-fluid .span4 { - width: 31.914893614%; -} -.row-fluid .span5 { - width: 40.425531911%; -} -.row-fluid .span6 { - width: 48.93617020799999%; -} -.row-fluid .span7 { - width: 57.446808505%; -} -.row-fluid .span8 { - width: 65.95744680199999%; -} -.row-fluid .span9 { - width: 74.468085099%; -} -.row-fluid .span10 { - width: 82.97872339599999%; -} -.row-fluid .span11 { - width: 91.489361693%; -} -.row-fluid .span12 { - width: 99.99999998999999%; -} -.container { - width: 940px; - margin-left: auto; - margin-right: auto; - *zoom: 1; -} -.container:before, .container:after { - display: table; - content: ""; -} -.container:after { - clear: both; -} -.container-fluid { - padding-left: 20px; - padding-right: 20px; - *zoom: 1; -} -.container-fluid:before, .container-fluid:after { - display: table; - content: ""; -} -.container-fluid:after { - clear: both; -} -p { - margin: 0 0 9px; - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; - font-size: 13px; - line-height: 18px; -} -p small { - font-size: 11px; - color: #999999; -} -.lead { - margin-bottom: 18px; - font-size: 20px; - font-weight: 200; - line-height: 27px; -} -h1, -h2, -h3, + h4, -h5, -h6 { - margin: 0; - font-weight: bold; - color: #333333; - text-rendering: optimizelegibility; -} -h1 small, -h2 small, -h3 small, -h4 small, -h5 small, -h6 small { - font-weight: normal; - color: #999999; +.h4 { + font-size: 18px; } -h1 { - font-size: 30px; - line-height: 36px; + +h5, +.h5 { + font-size: 14px; } -h1 small { - font-size: 18px; + +h6, +.h6 { + font-size: 12px; } -h2 { + +h1 small, +.h1 small { font-size: 24px; - line-height: 36px; -} -h2 small { - font-size: 18px; } -h3 { - line-height: 27px; + +h2 small, +.h2 small { font-size: 18px; } -h3 small { - font-size: 14px; -} -h4, h5, h6 { - line-height: 18px; -} -h4 { + +h3 small, +.h3 small, +h4 small, +.h4 small { font-size: 14px; } -h4 small { - font-size: 12px; -} -h5 { - font-size: 12px; -} -h6 { - font-size: 11px; - color: #999999; - text-transform: uppercase; -} + .page-header { - padding-bottom: 17px; - margin: 18px 0; + padding-bottom: 9px; + margin: 40px 0 20px; border-bottom: 1px solid #eeeeee; } -.page-header h1 { - line-height: 1; -} -ul, ol { - padding: 0; - margin: 0 0 9px 25px; + +ul, +ol { + margin-top: 0; + margin-bottom: 10px; } + ul ul, +ol ul, ul ol, -ol ol, -ol ul { +ol ol { margin-bottom: 0; } -ul { - list-style: disc; -} -ol { - list-style: decimal; -} -li { - line-height: 18px; + +.list-unstyled { + padding-left: 0; + list-style: none; } -ul.unstyled { - margin-left: 0; + +.list-inline { + padding-left: 0; list-style: none; } + +.list-inline > li { + display: inline-block; + padding-right: 5px; + padding-left: 5px; +} + dl { - margin-bottom: 18px; + margin-bottom: 20px; } -dt, dd { - line-height: 18px; + +dt, +dd { + line-height: 1.428571429; } + dt { font-weight: bold; } + dd { - margin-left: 9px; -} -hr { - margin: 18px 0; - border: 0; - border-top: 1px solid #e5e5e5; - border-bottom: 1px solid #ffffff; -} -strong { - font-weight: bold; + margin-left: 0; } -em { - font-style: italic; + +@media (min-width: 768px) { + .dl-horizontal dt { + float: left; + width: 160px; + overflow: hidden; + clear: left; + text-align: right; + text-overflow: ellipsis; + white-space: nowrap; + } + .dl-horizontal dd { + margin-left: 180px; + } + .dl-horizontal dd:before, + .dl-horizontal dd:after { + display: table; + content: " "; + } + .dl-horizontal dd:after { + clear: both; + } + .dl-horizontal dd:before, + .dl-horizontal dd:after { + display: table; + content: " "; + } + .dl-horizontal dd:after { + clear: both; + } } -.muted { - color: #999999; + +abbr[title], +abbr[data-original-title] { + cursor: help; + border-bottom: 1px dotted #999999; } -abbr { + +abbr.initialism { font-size: 90%; text-transform: uppercase; - border-bottom: 1px dotted #ddd; - cursor: help; } + blockquote { - padding: 0 0 0 15px; - margin: 0 0 18px; + padding: 10px 20px; + margin: 0 0 20px; border-left: 5px solid #eeeeee; } + blockquote p { - margin-bottom: 0; - font-size: 16px; + font-size: 17.5px; font-weight: 300; - line-height: 22.5px; + line-height: 1.25; +} + +blockquote p:last-child { + margin-bottom: 0; } + blockquote small { display: block; - line-height: 18px; + line-height: 1.428571429; color: #999999; } + blockquote small:before { content: '\2014 \00A0'; } + blockquote.pull-right { - float: right; - padding-left: 0; padding-right: 15px; - border-left: 0; + padding-left: 0; border-right: 5px solid #eeeeee; + border-left: 0; } -blockquote.pull-right p, blockquote.pull-right small { + +blockquote.pull-right p, +blockquote.pull-right small { text-align: right; } + +blockquote.pull-right small:before { + content: ''; +} + +blockquote.pull-right small:after { + content: '\00A0 \2014'; +} + q:before, q:after, blockquote:before, blockquote:after { content: ""; } + address { display: block; - margin-bottom: 18px; - line-height: 18px; - font-style: normal; -} -small { - font-size: 100%; -} -cite { + margin-bottom: 20px; font-style: normal; + line-height: 1.428571429; } -code, pre { - padding: 0 3px 2px; - font-family: Menlo, Monaco, "Courier New", monospace; - font-size: 12px; - color: #333333; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; + +code, +pre { + font-family: Monaco, Menlo, Consolas, "Courier New", monospace; } + code { - padding: 3px 4px; - color: #d14; - background-color: #f7f7f9; - border: 1px solid #e1e1e8; + padding: 2px 4px; + font-size: 90%; + color: #c7254e; + white-space: nowrap; + background-color: #f9f2f4; + border-radius: 4px; } + pre { display: block; - padding: 8.5px; - margin: 0 0 9px; - font-size: 12px; - line-height: 18px; + padding: 9.5px; + margin: 0 0 10px; + font-size: 13px; + line-height: 1.428571429; + color: #333333; + word-break: break-all; + word-wrap: break-word; background-color: #f5f5f5; - border: 1px solid #ccc; - border: 1px solid rgba(0, 0, 0, 0.15); - -webkit-border-radius: 4px; - -moz-border-radius: 4px; + border: 1px solid #cccccc; border-radius: 4px; - white-space: pre; - white-space: pre-wrap; - word-break: break-all; } + pre.prettyprint { - margin-bottom: 18px; + margin-bottom: 20px; } + pre code { padding: 0; + font-size: inherit; + color: inherit; + white-space: pre-wrap; background-color: transparent; -} -form { - margin: 0 0 18px; -} -fieldset { - padding: 0; - margin: 0; - border: 0; -} -legend { - display: block; - width: 100%; - padding: 0; - margin-bottom: 27px; - font-size: 19.5px; - line-height: 36px; - color: #333333; border: 0; - border-bottom: 1px solid #eee; } -label, -input, -button, -select, -textarea { - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; - font-size: 13px; - font-weight: normal; - line-height: 18px; + +.pre-scrollable { + max-height: 340px; + overflow-y: scroll; } -label { - display: block; - margin-bottom: 5px; - color: #333333; + +.container { + padding-right: 15px; + padding-left: 15px; + margin-right: auto; + margin-left: auto; } -input, -textarea, -select, -.uneditable-input { - display: inline-block; - width: 210px; - height: 18px; - padding: 4px; - margin-bottom: 9px; - font-size: 13px; - line-height: 18px; - color: #555555; - border: 1px solid #ccc; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; + +.container:before, +.container:after { + display: table; + content: " "; } -.uneditable-textarea { - width: auto; - height: auto; + +.container:after { + clear: both; } -label input, label textarea, label select { - display: block; + +.container:before, +.container:after { + display: table; + content: " "; } -input[type="image"], input[type="checkbox"], input[type="radio"] { - width: auto; - height: auto; - padding: 0; - margin: 3px 0; - *margin-top: 0; - /* IE7 */ - line-height: normal; - border: 0; - cursor: pointer; - border-radius: 0 \0/; +.container:after { + clear: both; } -input[type="file"] { - padding: initial; - line-height: initial; - border: initial; - background-color: #ffffff; - background-color: initial; + +.row { + margin-right: -15px; + margin-left: -15px; +} + +.row:before, +.row:after { + display: table; + content: " "; +} + +.row:after { + clear: both; +} + +.row:before, +.row:after { + display: table; + content: " "; +} + +.row:after { + clear: both; +} + +.col-xs-1, +.col-xs-2, +.col-xs-3, +.col-xs-4, +.col-xs-5, +.col-xs-6, +.col-xs-7, +.col-xs-8, +.col-xs-9, +.col-xs-10, +.col-xs-11, +.col-xs-12, +.col-sm-1, +.col-sm-2, +.col-sm-3, +.col-sm-4, +.col-sm-5, +.col-sm-6, +.col-sm-7, +.col-sm-8, +.col-sm-9, +.col-sm-10, +.col-sm-11, +.col-sm-12, +.col-md-1, +.col-md-2, +.col-md-3, +.col-md-4, +.col-md-5, +.col-md-6, +.col-md-7, +.col-md-8, +.col-md-9, +.col-md-10, +.col-md-11, +.col-md-12, +.col-lg-1, +.col-lg-2, +.col-lg-3, +.col-lg-4, +.col-lg-5, +.col-lg-6, +.col-lg-7, +.col-lg-8, +.col-lg-9, +.col-lg-10, +.col-lg-11, +.col-lg-12 { + position: relative; + min-height: 1px; + padding-right: 15px; + padding-left: 15px; +} + +.col-xs-1, +.col-xs-2, +.col-xs-3, +.col-xs-4, +.col-xs-5, +.col-xs-6, +.col-xs-7, +.col-xs-8, +.col-xs-9, +.col-xs-10, +.col-xs-11 { + float: left; +} + +.col-xs-1 { + width: 8.333333333333332%; +} + +.col-xs-2 { + width: 16.666666666666664%; +} + +.col-xs-3 { + width: 25%; +} + +.col-xs-4 { + width: 33.33333333333333%; +} + +.col-xs-5 { + width: 41.66666666666667%; +} + +.col-xs-6 { + width: 50%; +} + +.col-xs-7 { + width: 58.333333333333336%; +} + +.col-xs-8 { + width: 66.66666666666666%; +} + +.col-xs-9 { + width: 75%; +} + +.col-xs-10 { + width: 83.33333333333334%; +} + +.col-xs-11 { + width: 91.66666666666666%; +} + +.col-xs-12 { + width: 100%; +} + +@media (min-width: 768px) { + .container { + max-width: 750px; + } + .col-sm-1, + .col-sm-2, + .col-sm-3, + .col-sm-4, + .col-sm-5, + .col-sm-6, + .col-sm-7, + .col-sm-8, + .col-sm-9, + .col-sm-10, + .col-sm-11 { + float: left; + } + .col-sm-1 { + width: 8.333333333333332%; + } + .col-sm-2 { + width: 16.666666666666664%; + } + .col-sm-3 { + width: 25%; + } + .col-sm-4 { + width: 33.33333333333333%; + } + .col-sm-5 { + width: 41.66666666666667%; + } + .col-sm-6 { + width: 50%; + } + .col-sm-7 { + width: 58.333333333333336%; + } + .col-sm-8 { + width: 66.66666666666666%; + } + .col-sm-9 { + width: 75%; + } + .col-sm-10 { + width: 83.33333333333334%; + } + .col-sm-11 { + width: 91.66666666666666%; + } + .col-sm-12 { + width: 100%; + } + .col-sm-push-1 { + left: 8.333333333333332%; + } + .col-sm-push-2 { + left: 16.666666666666664%; + } + .col-sm-push-3 { + left: 25%; + } + .col-sm-push-4 { + left: 33.33333333333333%; + } + .col-sm-push-5 { + left: 41.66666666666667%; + } + .col-sm-push-6 { + left: 50%; + } + .col-sm-push-7 { + left: 58.333333333333336%; + } + .col-sm-push-8 { + left: 66.66666666666666%; + } + .col-sm-push-9 { + left: 75%; + } + .col-sm-push-10 { + left: 83.33333333333334%; + } + .col-sm-push-11 { + left: 91.66666666666666%; + } + .col-sm-pull-1 { + right: 8.333333333333332%; + } + .col-sm-pull-2 { + right: 16.666666666666664%; + } + .col-sm-pull-3 { + right: 25%; + } + .col-sm-pull-4 { + right: 33.33333333333333%; + } + .col-sm-pull-5 { + right: 41.66666666666667%; + } + .col-sm-pull-6 { + right: 50%; + } + .col-sm-pull-7 { + right: 58.333333333333336%; + } + .col-sm-pull-8 { + right: 66.66666666666666%; + } + .col-sm-pull-9 { + right: 75%; + } + .col-sm-pull-10 { + right: 83.33333333333334%; + } + .col-sm-pull-11 { + right: 91.66666666666666%; + } + .col-sm-offset-1 { + margin-left: 8.333333333333332%; + } + .col-sm-offset-2 { + margin-left: 16.666666666666664%; + } + .col-sm-offset-3 { + margin-left: 25%; + } + .col-sm-offset-4 { + margin-left: 33.33333333333333%; + } + .col-sm-offset-5 { + margin-left: 41.66666666666667%; + } + .col-sm-offset-6 { + margin-left: 50%; + } + .col-sm-offset-7 { + margin-left: 58.333333333333336%; + } + .col-sm-offset-8 { + margin-left: 66.66666666666666%; + } + .col-sm-offset-9 { + margin-left: 75%; + } + .col-sm-offset-10 { + margin-left: 83.33333333333334%; + } + .col-sm-offset-11 { + margin-left: 91.66666666666666%; + } +} + +@media (min-width: 992px) { + .container { + max-width: 970px; + } + .col-md-1, + .col-md-2, + .col-md-3, + .col-md-4, + .col-md-5, + .col-md-6, + .col-md-7, + .col-md-8, + .col-md-9, + .col-md-10, + .col-md-11 { + float: left; + } + .col-md-1 { + width: 8.333333333333332%; + } + .col-md-2 { + width: 16.666666666666664%; + } + .col-md-3 { + width: 25%; + } + .col-md-4 { + width: 33.33333333333333%; + } + .col-md-5 { + width: 41.66666666666667%; + } + .col-md-6 { + width: 50%; + } + .col-md-7 { + width: 58.333333333333336%; + } + .col-md-8 { + width: 66.66666666666666%; + } + .col-md-9 { + width: 75%; + } + .col-md-10 { + width: 83.33333333333334%; + } + .col-md-11 { + width: 91.66666666666666%; + } + .col-md-12 { + width: 100%; + } + .col-md-push-0 { + left: auto; + } + .col-md-push-1 { + left: 8.333333333333332%; + } + .col-md-push-2 { + left: 16.666666666666664%; + } + .col-md-push-3 { + left: 25%; + } + .col-md-push-4 { + left: 33.33333333333333%; + } + .col-md-push-5 { + left: 41.66666666666667%; + } + .col-md-push-6 { + left: 50%; + } + .col-md-push-7 { + left: 58.333333333333336%; + } + .col-md-push-8 { + left: 66.66666666666666%; + } + .col-md-push-9 { + left: 75%; + } + .col-md-push-10 { + left: 83.33333333333334%; + } + .col-md-push-11 { + left: 91.66666666666666%; + } + .col-md-pull-0 { + right: auto; + } + .col-md-pull-1 { + right: 8.333333333333332%; + } + .col-md-pull-2 { + right: 16.666666666666664%; + } + .col-md-pull-3 { + right: 25%; + } + .col-md-pull-4 { + right: 33.33333333333333%; + } + .col-md-pull-5 { + right: 41.66666666666667%; + } + .col-md-pull-6 { + right: 50%; + } + .col-md-pull-7 { + right: 58.333333333333336%; + } + .col-md-pull-8 { + right: 66.66666666666666%; + } + .col-md-pull-9 { + right: 75%; + } + .col-md-pull-10 { + right: 83.33333333333334%; + } + .col-md-pull-11 { + right: 91.66666666666666%; + } + .col-md-offset-0 { + margin-left: 0; + } + .col-md-offset-1 { + margin-left: 8.333333333333332%; + } + .col-md-offset-2 { + margin-left: 16.666666666666664%; + } + .col-md-offset-3 { + margin-left: 25%; + } + .col-md-offset-4 { + margin-left: 33.33333333333333%; + } + .col-md-offset-5 { + margin-left: 41.66666666666667%; + } + .col-md-offset-6 { + margin-left: 50%; + } + .col-md-offset-7 { + margin-left: 58.333333333333336%; + } + .col-md-offset-8 { + margin-left: 66.66666666666666%; + } + .col-md-offset-9 { + margin-left: 75%; + } + .col-md-offset-10 { + margin-left: 83.33333333333334%; + } + .col-md-offset-11 { + margin-left: 91.66666666666666%; + } +} + +@media (min-width: 1200px) { + .container { + max-width: 1170px; + } + .col-lg-1, + .col-lg-2, + .col-lg-3, + .col-lg-4, + .col-lg-5, + .col-lg-6, + .col-lg-7, + .col-lg-8, + .col-lg-9, + .col-lg-10, + .col-lg-11 { + float: left; + } + .col-lg-1 { + width: 8.333333333333332%; + } + .col-lg-2 { + width: 16.666666666666664%; + } + .col-lg-3 { + width: 25%; + } + .col-lg-4 { + width: 33.33333333333333%; + } + .col-lg-5 { + width: 41.66666666666667%; + } + .col-lg-6 { + width: 50%; + } + .col-lg-7 { + width: 58.333333333333336%; + } + .col-lg-8 { + width: 66.66666666666666%; + } + .col-lg-9 { + width: 75%; + } + .col-lg-10 { + width: 83.33333333333334%; + } + .col-lg-11 { + width: 91.66666666666666%; + } + .col-lg-12 { + width: 100%; + } + .col-lg-push-0 { + left: auto; + } + .col-lg-push-1 { + left: 8.333333333333332%; + } + .col-lg-push-2 { + left: 16.666666666666664%; + } + .col-lg-push-3 { + left: 25%; + } + .col-lg-push-4 { + left: 33.33333333333333%; + } + .col-lg-push-5 { + left: 41.66666666666667%; + } + .col-lg-push-6 { + left: 50%; + } + .col-lg-push-7 { + left: 58.333333333333336%; + } + .col-lg-push-8 { + left: 66.66666666666666%; + } + .col-lg-push-9 { + left: 75%; + } + .col-lg-push-10 { + left: 83.33333333333334%; + } + .col-lg-push-11 { + left: 91.66666666666666%; + } + .col-lg-pull-0 { + right: auto; + } + .col-lg-pull-1 { + right: 8.333333333333332%; + } + .col-lg-pull-2 { + right: 16.666666666666664%; + } + .col-lg-pull-3 { + right: 25%; + } + .col-lg-pull-4 { + right: 33.33333333333333%; + } + .col-lg-pull-5 { + right: 41.66666666666667%; + } + .col-lg-pull-6 { + right: 50%; + } + .col-lg-pull-7 { + right: 58.333333333333336%; + } + .col-lg-pull-8 { + right: 66.66666666666666%; + } + .col-lg-pull-9 { + right: 75%; + } + .col-lg-pull-10 { + right: 83.33333333333334%; + } + .col-lg-pull-11 { + right: 91.66666666666666%; + } + .col-lg-offset-0 { + margin-left: 0; + } + .col-lg-offset-1 { + margin-left: 8.333333333333332%; + } + .col-lg-offset-2 { + margin-left: 16.666666666666664%; + } + .col-lg-offset-3 { + margin-left: 25%; + } + .col-lg-offset-4 { + margin-left: 33.33333333333333%; + } + .col-lg-offset-5 { + margin-left: 41.66666666666667%; + } + .col-lg-offset-6 { + margin-left: 50%; + } + .col-lg-offset-7 { + margin-left: 58.333333333333336%; + } + .col-lg-offset-8 { + margin-left: 66.66666666666666%; + } + .col-lg-offset-9 { + margin-left: 75%; + } + .col-lg-offset-10 { + margin-left: 83.33333333333334%; + } + .col-lg-offset-11 { + margin-left: 91.66666666666666%; + } +} + +table { + max-width: 100%; + background-color: transparent; +} + +th { + text-align: left; +} + +.table { + width: 100%; + margin-bottom: 20px; +} + +.table thead > tr > th, +.table tbody > tr > th, +.table tfoot > tr > th, +.table thead > tr > td, +.table tbody > tr > td, +.table tfoot > tr > td { + padding: 8px; + line-height: 1.428571429; + vertical-align: top; + border-top: 1px solid #dddddd; +} + +.table thead > tr > th { + vertical-align: bottom; + border-bottom: 2px solid #dddddd; +} + +.table caption + thead tr:first-child th, +.table colgroup + thead tr:first-child th, +.table thead:first-child tr:first-child th, +.table caption + thead tr:first-child td, +.table colgroup + thead tr:first-child td, +.table thead:first-child tr:first-child td { + border-top: 0; +} + +.table tbody + tbody { + border-top: 2px solid #dddddd; +} + +.table .table { + background-color: #ffffff; +} + +.table-condensed thead > tr > th, +.table-condensed tbody > tr > th, +.table-condensed tfoot > tr > th, +.table-condensed thead > tr > td, +.table-condensed tbody > tr > td, +.table-condensed tfoot > tr > td { + padding: 5px; +} + +.table-bordered { + border: 1px solid #dddddd; +} + +.table-bordered > thead > tr > th, +.table-bordered > tbody > tr > th, +.table-bordered > tfoot > tr > th, +.table-bordered > thead > tr > td, +.table-bordered > tbody > tr > td, +.table-bordered > tfoot > tr > td { + border: 1px solid #dddddd; +} + +.table-bordered > thead > tr > th, +.table-bordered > thead > tr > td { + border-bottom-width: 2px; +} + +.table-striped > tbody > tr:nth-child(odd) > td, +.table-striped > tbody > tr:nth-child(odd) > th { + background-color: #f9f9f9; +} + +.table-hover > tbody > tr:hover > td, +.table-hover > tbody > tr:hover > th { + background-color: #f5f5f5; +} + +table col[class*="col-"] { + display: table-column; + float: none; +} + +table td[class*="col-"], +table th[class*="col-"] { + display: table-cell; + float: none; +} + +.table > thead > tr > td.active, +.table > tbody > tr > td.active, +.table > tfoot > tr > td.active, +.table > thead > tr > th.active, +.table > tbody > tr > th.active, +.table > tfoot > tr > th.active, +.table > thead > tr.active > td, +.table > tbody > tr.active > td, +.table > tfoot > tr.active > td, +.table > thead > tr.active > th, +.table > tbody > tr.active > th, +.table > tfoot > tr.active > th { + background-color: #f5f5f5; +} + +.table > thead > tr > td.success, +.table > tbody > tr > td.success, +.table > tfoot > tr > td.success, +.table > thead > tr > th.success, +.table > tbody > tr > th.success, +.table > tfoot > tr > th.success, +.table > thead > tr.success > td, +.table > tbody > tr.success > td, +.table > tfoot > tr.success > td, +.table > thead > tr.success > th, +.table > tbody > tr.success > th, +.table > tfoot > tr.success > th { + background-color: #dff0d8; + border-color: #d6e9c6; +} + +.table-hover > tbody > tr > td.success:hover, +.table-hover > tbody > tr > th.success:hover, +.table-hover > tbody > tr.success:hover > td { + background-color: #d0e9c6; + border-color: #c9e2b3; +} + +.table > thead > tr > td.danger, +.table > tbody > tr > td.danger, +.table > tfoot > tr > td.danger, +.table > thead > tr > th.danger, +.table > tbody > tr > th.danger, +.table > tfoot > tr > th.danger, +.table > thead > tr.danger > td, +.table > tbody > tr.danger > td, +.table > tfoot > tr.danger > td, +.table > thead > tr.danger > th, +.table > tbody > tr.danger > th, +.table > tfoot > tr.danger > th { + background-color: #f2dede; + border-color: #eed3d7; +} + +.table-hover > tbody > tr > td.danger:hover, +.table-hover > tbody > tr > th.danger:hover, +.table-hover > tbody > tr.danger:hover > td { + background-color: #ebcccc; + border-color: #e6c1c7; +} + +.table > thead > tr > td.warning, +.table > tbody > tr > td.warning, +.table > tfoot > tr > td.warning, +.table > thead > tr > th.warning, +.table > tbody > tr > th.warning, +.table > tfoot > tr > th.warning, +.table > thead > tr.warning > td, +.table > tbody > tr.warning > td, +.table > tfoot > tr.warning > td, +.table > thead > tr.warning > th, +.table > tbody > tr.warning > th, +.table > tfoot > tr.warning > th { + background-color: #fcf8e3; + border-color: #fbeed5; +} + +.table-hover > tbody > tr > td.warning:hover, +.table-hover > tbody > tr > th.warning:hover, +.table-hover > tbody > tr.warning:hover > td { + background-color: #faf2cc; + border-color: #f8e5be; +} + +@media (max-width: 768px) { + .table-responsive { + width: 100%; + margin-bottom: 15px; + overflow-x: scroll; + overflow-y: hidden; + border: 1px solid #dddddd; + } + .table-responsive > .table { + margin-bottom: 0; + background-color: #fff; + } + .table-responsive > .table > thead > tr > th, + .table-responsive > .table > tbody > tr > th, + .table-responsive > .table > tfoot > tr > th, + .table-responsive > .table > thead > tr > td, + .table-responsive > .table > tbody > tr > td, + .table-responsive > .table > tfoot > tr > td { + white-space: nowrap; + } + .table-responsive > .table-bordered { + border: 0; + } + .table-responsive > .table-bordered > thead > tr > th:first-child, + .table-responsive > .table-bordered > tbody > tr > th:first-child, + .table-responsive > .table-bordered > tfoot > tr > th:first-child, + .table-responsive > .table-bordered > thead > tr > td:first-child, + .table-responsive > .table-bordered > tbody > tr > td:first-child, + .table-responsive > .table-bordered > tfoot > tr > td:first-child { + border-left: 0; + } + .table-responsive > .table-bordered > thead > tr > th:last-child, + .table-responsive > .table-bordered > tbody > tr > th:last-child, + .table-responsive > .table-bordered > tfoot > tr > th:last-child, + .table-responsive > .table-bordered > thead > tr > td:last-child, + .table-responsive > .table-bordered > tbody > tr > td:last-child, + .table-responsive > .table-bordered > tfoot > tr > td:last-child { + border-right: 0; + } + .table-responsive > .table-bordered > thead > tr:last-child > th, + .table-responsive > .table-bordered > tbody > tr:last-child > th, + .table-responsive > .table-bordered > tfoot > tr:last-child > th, + .table-responsive > .table-bordered > thead > tr:last-child > td, + .table-responsive > .table-bordered > tbody > tr:last-child > td, + .table-responsive > .table-bordered > tfoot > tr:last-child > td { + border-bottom: 0; + } +} + +fieldset { + padding: 0; + margin: 0; + border: 0; +} + +legend { + display: block; + width: 100%; + padding: 0; + margin-bottom: 20px; + font-size: 21px; + line-height: inherit; + color: #333333; + border: 0; + border-bottom: 1px solid #e5e5e5; +} + +label { + display: inline-block; + margin-bottom: 5px; + font-weight: bold; +} + +input[type="search"] { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +input[type="radio"], +input[type="checkbox"] { + margin: 4px 0 0; + margin-top: 1px \9; + /* IE8-9 */ + + line-height: normal; +} + +input[type="file"] { + display: block; +} + +select[multiple], +select[size] { + height: auto; +} + +select optgroup { + font-family: inherit; + font-size: inherit; + font-style: inherit; +} + +input[type="file"]:focus, +input[type="radio"]:focus, +input[type="checkbox"]:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +input[type="number"]::-webkit-outer-spin-button, +input[type="number"]::-webkit-inner-spin-button { + height: auto; +} + +.form-control:-moz-placeholder { + color: #999999; +} + +.form-control::-moz-placeholder { + color: #999999; +} + +.form-control:-ms-input-placeholder { + color: #999999; +} + +.form-control::-webkit-input-placeholder { + color: #999999; +} + +.form-control { + display: block; + width: 100%; + height: 34px; + padding: 6px 12px; + font-size: 14px; + line-height: 1.428571429; + color: #555555; + vertical-align: middle; + background-color: #ffffff; + border: 1px solid #cccccc; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -webkit-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s; + transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s; +} + +.form-control:focus { + border-color: #66afe9; + outline: 0; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6); +} + +.form-control[disabled], +.form-control[readonly], +fieldset[disabled] .form-control { + cursor: not-allowed; + background-color: #eeeeee; +} + +textarea.form-control { + height: auto; +} + +.form-group { + margin-bottom: 15px; +} + +.radio, +.checkbox { + display: block; + min-height: 20px; + padding-left: 20px; + margin-top: 10px; + margin-bottom: 10px; + vertical-align: middle; +} + +.radio label, +.checkbox label { + display: inline; + margin-bottom: 0; + font-weight: normal; + cursor: pointer; +} + +.radio input[type="radio"], +.radio-inline input[type="radio"], +.checkbox input[type="checkbox"], +.checkbox-inline input[type="checkbox"] { + float: left; + margin-left: -20px; +} + +.radio + .radio, +.checkbox + .checkbox { + margin-top: -5px; +} + +.radio-inline, +.checkbox-inline { + display: inline-block; + padding-left: 20px; + margin-bottom: 0; + font-weight: normal; + vertical-align: middle; + cursor: pointer; +} + +.radio-inline + .radio-inline, +.checkbox-inline + .checkbox-inline { + margin-top: 0; + margin-left: 10px; +} + +input[type="radio"][disabled], +input[type="checkbox"][disabled], +.radio[disabled], +.radio-inline[disabled], +.checkbox[disabled], +.checkbox-inline[disabled], +fieldset[disabled] input[type="radio"], +fieldset[disabled] input[type="checkbox"], +fieldset[disabled] .radio, +fieldset[disabled] .radio-inline, +fieldset[disabled] .checkbox, +fieldset[disabled] .checkbox-inline { + cursor: not-allowed; +} + +.input-sm { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; +} + +select.input-sm { + height: 30px; + line-height: 30px; +} + +textarea.input-sm { + height: auto; +} + +.input-lg { + height: 45px; + padding: 10px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; +} + +select.input-lg { + height: 45px; + line-height: 45px; +} + +textarea.input-lg { + height: auto; +} + +.has-warning .help-block, +.has-warning .control-label { + color: #c09853; +} + +.has-warning .form-control { + border-color: #c09853; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.has-warning .form-control:focus { + border-color: #a47e3c; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; +} + +.has-warning .input-group-addon { + color: #c09853; + background-color: #fcf8e3; + border-color: #c09853; +} + +.has-error .help-block, +.has-error .control-label { + color: #b94a48; +} + +.has-error .form-control { + border-color: #b94a48; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.has-error .form-control:focus { + border-color: #953b39; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; +} + +.has-error .input-group-addon { + color: #b94a48; + background-color: #f2dede; + border-color: #b94a48; +} + +.has-success .help-block, +.has-success .control-label { + color: #468847; +} + +.has-success .form-control { + border-color: #468847; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.has-success .form-control:focus { + border-color: #356635; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; +} + +.has-success .input-group-addon { + color: #468847; + background-color: #dff0d8; + border-color: #468847; +} + +.form-control-static { + padding-top: 7px; + margin-bottom: 0; +} + +.help-block { + display: block; + margin-top: 5px; + margin-bottom: 10px; + color: #737373; +} + +@media (min-width: 768px) { + .form-inline .form-group { + display: inline-block; + margin-bottom: 0; + vertical-align: middle; + } + .form-inline .form-control { + display: inline-block; + } + .form-inline .radio, + .form-inline .checkbox { + display: inline-block; + padding-left: 0; + margin-top: 0; + margin-bottom: 0; + } + .form-inline .radio input[type="radio"], + .form-inline .checkbox input[type="checkbox"] { + float: none; + margin-left: 0; + } +} + +.form-horizontal .control-label, +.form-horizontal .radio, +.form-horizontal .checkbox, +.form-horizontal .radio-inline, +.form-horizontal .checkbox-inline { + padding-top: 7px; + margin-top: 0; + margin-bottom: 0; +} + +.form-horizontal .form-group { + margin-right: -15px; + margin-left: -15px; +} + +.form-horizontal .form-group:before, +.form-horizontal .form-group:after { + display: table; + content: " "; +} + +.form-horizontal .form-group:after { + clear: both; +} + +.form-horizontal .form-group:before, +.form-horizontal .form-group:after { + display: table; + content: " "; +} + +.form-horizontal .form-group:after { + clear: both; +} + +@media (min-width: 768px) { + .form-horizontal .control-label { + text-align: right; + } +} + +.btn { + display: inline-block; + padding: 6px 12px; + margin-bottom: 0; + font-size: 14px; + font-weight: normal; + line-height: 1.428571429; + text-align: center; + white-space: nowrap; + vertical-align: middle; + cursor: pointer; + border: 1px solid transparent; + border-radius: 4px; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + -o-user-select: none; + user-select: none; +} + +.btn:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +.btn:hover, +.btn:focus { + color: #333333; + text-decoration: none; +} + +.btn:active, +.btn.active { + background-image: none; + outline: 0; + -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); +} + +.btn.disabled, +.btn[disabled], +fieldset[disabled] .btn { + pointer-events: none; + cursor: not-allowed; + opacity: 0.65; + filter: alpha(opacity=65); + -webkit-box-shadow: none; + box-shadow: none; +} + +.btn-default { + color: #333333; + background-color: #ffffff; + border-color: #cccccc; +} + +.btn-default:hover, +.btn-default:focus, +.btn-default:active, +.btn-default.active, +.open .dropdown-toggle.btn-default { + color: #333333; + background-color: #ebebeb; + border-color: #adadad; +} + +.btn-default:active, +.btn-default.active, +.open .dropdown-toggle.btn-default { + background-image: none; +} + +.btn-default.disabled, +.btn-default[disabled], +fieldset[disabled] .btn-default, +.btn-default.disabled:hover, +.btn-default[disabled]:hover, +fieldset[disabled] .btn-default:hover, +.btn-default.disabled:focus, +.btn-default[disabled]:focus, +fieldset[disabled] .btn-default:focus, +.btn-default.disabled:active, +.btn-default[disabled]:active, +fieldset[disabled] .btn-default:active, +.btn-default.disabled.active, +.btn-default[disabled].active, +fieldset[disabled] .btn-default.active { + background-color: #ffffff; + border-color: #cccccc; +} + +.btn-primary { + color: #ffffff; + background-color: #428bca; + border-color: #357ebd; +} + +.btn-primary:hover, +.btn-primary:focus, +.btn-primary:active, +.btn-primary.active, +.open .dropdown-toggle.btn-primary { + color: #ffffff; + background-color: #3276b1; + border-color: #285e8e; +} + +.btn-primary:active, +.btn-primary.active, +.open .dropdown-toggle.btn-primary { + background-image: none; +} + +.btn-primary.disabled, +.btn-primary[disabled], +fieldset[disabled] .btn-primary, +.btn-primary.disabled:hover, +.btn-primary[disabled]:hover, +fieldset[disabled] .btn-primary:hover, +.btn-primary.disabled:focus, +.btn-primary[disabled]:focus, +fieldset[disabled] .btn-primary:focus, +.btn-primary.disabled:active, +.btn-primary[disabled]:active, +fieldset[disabled] .btn-primary:active, +.btn-primary.disabled.active, +.btn-primary[disabled].active, +fieldset[disabled] .btn-primary.active { + background-color: #428bca; + border-color: #357ebd; +} + +.btn-warning { + color: #ffffff; + background-color: #f0ad4e; + border-color: #eea236; +} + +.btn-warning:hover, +.btn-warning:focus, +.btn-warning:active, +.btn-warning.active, +.open .dropdown-toggle.btn-warning { + color: #ffffff; + background-color: #ed9c28; + border-color: #d58512; +} + +.btn-warning:active, +.btn-warning.active, +.open .dropdown-toggle.btn-warning { + background-image: none; +} + +.btn-warning.disabled, +.btn-warning[disabled], +fieldset[disabled] .btn-warning, +.btn-warning.disabled:hover, +.btn-warning[disabled]:hover, +fieldset[disabled] .btn-warning:hover, +.btn-warning.disabled:focus, +.btn-warning[disabled]:focus, +fieldset[disabled] .btn-warning:focus, +.btn-warning.disabled:active, +.btn-warning[disabled]:active, +fieldset[disabled] .btn-warning:active, +.btn-warning.disabled.active, +.btn-warning[disabled].active, +fieldset[disabled] .btn-warning.active { + background-color: #f0ad4e; + border-color: #eea236; +} + +.btn-danger { + color: #ffffff; + background-color: #d9534f; + border-color: #d43f3a; +} + +.btn-danger:hover, +.btn-danger:focus, +.btn-danger:active, +.btn-danger.active, +.open .dropdown-toggle.btn-danger { + color: #ffffff; + background-color: #d2322d; + border-color: #ac2925; +} + +.btn-danger:active, +.btn-danger.active, +.open .dropdown-toggle.btn-danger { + background-image: none; +} + +.btn-danger.disabled, +.btn-danger[disabled], +fieldset[disabled] .btn-danger, +.btn-danger.disabled:hover, +.btn-danger[disabled]:hover, +fieldset[disabled] .btn-danger:hover, +.btn-danger.disabled:focus, +.btn-danger[disabled]:focus, +fieldset[disabled] .btn-danger:focus, +.btn-danger.disabled:active, +.btn-danger[disabled]:active, +fieldset[disabled] .btn-danger:active, +.btn-danger.disabled.active, +.btn-danger[disabled].active, +fieldset[disabled] .btn-danger.active { + background-color: #d9534f; + border-color: #d43f3a; +} + +.btn-success { + color: #ffffff; + background-color: #5cb85c; + border-color: #4cae4c; +} + +.btn-success:hover, +.btn-success:focus, +.btn-success:active, +.btn-success.active, +.open .dropdown-toggle.btn-success { + color: #ffffff; + background-color: #47a447; + border-color: #398439; +} + +.btn-success:active, +.btn-success.active, +.open .dropdown-toggle.btn-success { + background-image: none; +} + +.btn-success.disabled, +.btn-success[disabled], +fieldset[disabled] .btn-success, +.btn-success.disabled:hover, +.btn-success[disabled]:hover, +fieldset[disabled] .btn-success:hover, +.btn-success.disabled:focus, +.btn-success[disabled]:focus, +fieldset[disabled] .btn-success:focus, +.btn-success.disabled:active, +.btn-success[disabled]:active, +fieldset[disabled] .btn-success:active, +.btn-success.disabled.active, +.btn-success[disabled].active, +fieldset[disabled] .btn-success.active { + background-color: #5cb85c; + border-color: #4cae4c; +} + +.btn-info { + color: #ffffff; + background-color: #5bc0de; + border-color: #46b8da; +} + +.btn-info:hover, +.btn-info:focus, +.btn-info:active, +.btn-info.active, +.open .dropdown-toggle.btn-info { + color: #ffffff; + background-color: #39b3d7; + border-color: #269abc; +} + +.btn-info:active, +.btn-info.active, +.open .dropdown-toggle.btn-info { + background-image: none; +} + +.btn-info.disabled, +.btn-info[disabled], +fieldset[disabled] .btn-info, +.btn-info.disabled:hover, +.btn-info[disabled]:hover, +fieldset[disabled] .btn-info:hover, +.btn-info.disabled:focus, +.btn-info[disabled]:focus, +fieldset[disabled] .btn-info:focus, +.btn-info.disabled:active, +.btn-info[disabled]:active, +fieldset[disabled] .btn-info:active, +.btn-info.disabled.active, +.btn-info[disabled].active, +fieldset[disabled] .btn-info.active { + background-color: #5bc0de; + border-color: #46b8da; +} + +.btn-link { + font-weight: normal; + color: #428bca; + cursor: pointer; + border-radius: 0; +} + +.btn-link, +.btn-link:active, +.btn-link[disabled], +fieldset[disabled] .btn-link { + background-color: transparent; -webkit-box-shadow: none; - -moz-box-shadow: none; - box-shadow: none; + box-shadow: none; +} + +.btn-link, +.btn-link:hover, +.btn-link:focus, +.btn-link:active { + border-color: transparent; +} + +.btn-link:hover, +.btn-link:focus { + color: #2a6496; + text-decoration: underline; + background-color: transparent; +} + +.btn-link[disabled]:hover, +fieldset[disabled] .btn-link:hover, +.btn-link[disabled]:focus, +fieldset[disabled] .btn-link:focus { + color: #999999; + text-decoration: none; +} + +.btn-lg { + padding: 10px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; +} + +.btn-sm, +.btn-xs { + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; +} + +.btn-xs { + padding: 1px 5px; +} + +.btn-block { + display: block; + width: 100%; + padding-right: 0; + padding-left: 0; +} + +.btn-block + .btn-block { + margin-top: 5px; +} + +input[type="submit"].btn-block, +input[type="reset"].btn-block, +input[type="button"].btn-block { + width: 100%; +} + +.fade { + opacity: 0; + -webkit-transition: opacity 0.15s linear; + transition: opacity 0.15s linear; +} + +.fade.in { + opacity: 1; +} + +.collapse { + display: none; +} + +.collapse.in { + display: block; +} + +.collapsing { + position: relative; + height: 0; + overflow: hidden; + -webkit-transition: height 0.35s ease; + transition: height 0.35s ease; +} + +@font-face { + font-family: 'Glyphicons Halflings'; + src: url('../fonts/glyphicons-halflings-regular.eot'); + src: url('../fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('../fonts/glyphicons-halflings-regular.woff') format('woff'), url('../fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('../fonts/glyphicons-halflings-regular.svg#glyphicons-halflingsregular') format('svg'); +} + +.glyphicon { + position: relative; + top: 1px; + display: inline-block; + font-family: 'Glyphicons Halflings'; + -webkit-font-smoothing: antialiased; + font-style: normal; + font-weight: normal; + line-height: 1; +} + +.glyphicon-asterisk:before { + content: "\2a"; +} + +.glyphicon-plus:before { + content: "\2b"; +} + +.glyphicon-euro:before { + content: "\20ac"; +} + +.glyphicon-minus:before { + content: "\2212"; +} + +.glyphicon-cloud:before { + content: "\2601"; +} + +.glyphicon-envelope:before { + content: "\2709"; +} + +.glyphicon-pencil:before { + content: "\270f"; +} + +.glyphicon-glass:before { + content: "\e001"; +} + +.glyphicon-music:before { + content: "\e002"; +} + +.glyphicon-search:before { + content: "\e003"; +} + +.glyphicon-heart:before { + content: "\e005"; +} + +.glyphicon-star:before { + content: "\e006"; +} + +.glyphicon-star-empty:before { + content: "\e007"; +} + +.glyphicon-user:before { + content: "\e008"; +} + +.glyphicon-film:before { + content: "\e009"; +} + +.glyphicon-th-large:before { + content: "\e010"; +} + +.glyphicon-th:before { + content: "\e011"; +} + +.glyphicon-th-list:before { + content: "\e012"; +} + +.glyphicon-ok:before { + content: "\e013"; +} + +.glyphicon-remove:before { + content: "\e014"; +} + +.glyphicon-zoom-in:before { + content: "\e015"; +} + +.glyphicon-zoom-out:before { + content: "\e016"; +} + +.glyphicon-off:before { + content: "\e017"; +} + +.glyphicon-signal:before { + content: "\e018"; +} + +.glyphicon-cog:before { + content: "\e019"; +} + +.glyphicon-trash:before { + content: "\e020"; +} + +.glyphicon-home:before { + content: "\e021"; +} + +.glyphicon-file:before { + content: "\e022"; +} + +.glyphicon-time:before { + content: "\e023"; +} + +.glyphicon-road:before { + content: "\e024"; +} + +.glyphicon-download-alt:before { + content: "\e025"; +} + +.glyphicon-download:before { + content: "\e026"; +} + +.glyphicon-upload:before { + content: "\e027"; +} + +.glyphicon-inbox:before { + content: "\e028"; +} + +.glyphicon-play-circle:before { + content: "\e029"; +} + +.glyphicon-repeat:before { + content: "\e030"; +} + +.glyphicon-refresh:before { + content: "\e031"; +} + +.glyphicon-list-alt:before { + content: "\e032"; +} + +.glyphicon-flag:before { + content: "\e034"; +} + +.glyphicon-headphones:before { + content: "\e035"; +} + +.glyphicon-volume-off:before { + content: "\e036"; +} + +.glyphicon-volume-down:before { + content: "\e037"; +} + +.glyphicon-volume-up:before { + content: "\e038"; +} + +.glyphicon-qrcode:before { + content: "\e039"; +} + +.glyphicon-barcode:before { + content: "\e040"; +} + +.glyphicon-tag:before { + content: "\e041"; +} + +.glyphicon-tags:before { + content: "\e042"; +} + +.glyphicon-book:before { + content: "\e043"; +} + +.glyphicon-print:before { + content: "\e045"; +} + +.glyphicon-font:before { + content: "\e047"; +} + +.glyphicon-bold:before { + content: "\e048"; +} + +.glyphicon-italic:before { + content: "\e049"; +} + +.glyphicon-text-height:before { + content: "\e050"; +} + +.glyphicon-text-width:before { + content: "\e051"; +} + +.glyphicon-align-left:before { + content: "\e052"; +} + +.glyphicon-align-center:before { + content: "\e053"; +} + +.glyphicon-align-right:before { + content: "\e054"; +} + +.glyphicon-align-justify:before { + content: "\e055"; +} + +.glyphicon-list:before { + content: "\e056"; +} + +.glyphicon-indent-left:before { + content: "\e057"; +} + +.glyphicon-indent-right:before { + content: "\e058"; +} + +.glyphicon-facetime-video:before { + content: "\e059"; +} + +.glyphicon-picture:before { + content: "\e060"; +} + +.glyphicon-map-marker:before { + content: "\e062"; +} + +.glyphicon-adjust:before { + content: "\e063"; +} + +.glyphicon-tint:before { + content: "\e064"; +} + +.glyphicon-edit:before { + content: "\e065"; +} + +.glyphicon-share:before { + content: "\e066"; +} + +.glyphicon-check:before { + content: "\e067"; +} + +.glyphicon-move:before { + content: "\e068"; +} + +.glyphicon-step-backward:before { + content: "\e069"; +} + +.glyphicon-fast-backward:before { + content: "\e070"; +} + +.glyphicon-backward:before { + content: "\e071"; +} + +.glyphicon-play:before { + content: "\e072"; +} + +.glyphicon-pause:before { + content: "\e073"; +} + +.glyphicon-stop:before { + content: "\e074"; +} + +.glyphicon-forward:before { + content: "\e075"; +} + +.glyphicon-fast-forward:before { + content: "\e076"; +} + +.glyphicon-step-forward:before { + content: "\e077"; +} + +.glyphicon-eject:before { + content: "\e078"; +} + +.glyphicon-chevron-left:before { + content: "\e079"; +} + +.glyphicon-chevron-right:before { + content: "\e080"; +} + +.glyphicon-plus-sign:before { + content: "\e081"; +} + +.glyphicon-minus-sign:before { + content: "\e082"; +} + +.glyphicon-remove-sign:before { + content: "\e083"; +} + +.glyphicon-ok-sign:before { + content: "\e084"; +} + +.glyphicon-question-sign:before { + content: "\e085"; +} + +.glyphicon-info-sign:before { + content: "\e086"; +} + +.glyphicon-screenshot:before { + content: "\e087"; +} + +.glyphicon-remove-circle:before { + content: "\e088"; +} + +.glyphicon-ok-circle:before { + content: "\e089"; +} + +.glyphicon-ban-circle:before { + content: "\e090"; +} + +.glyphicon-arrow-left:before { + content: "\e091"; +} + +.glyphicon-arrow-right:before { + content: "\e092"; +} + +.glyphicon-arrow-up:before { + content: "\e093"; +} + +.glyphicon-arrow-down:before { + content: "\e094"; +} + +.glyphicon-share-alt:before { + content: "\e095"; +} + +.glyphicon-resize-full:before { + content: "\e096"; +} + +.glyphicon-resize-small:before { + content: "\e097"; +} + +.glyphicon-exclamation-sign:before { + content: "\e101"; +} + +.glyphicon-gift:before { + content: "\e102"; +} + +.glyphicon-leaf:before { + content: "\e103"; +} + +.glyphicon-eye-open:before { + content: "\e105"; +} + +.glyphicon-eye-close:before { + content: "\e106"; +} + +.glyphicon-warning-sign:before { + content: "\e107"; +} + +.glyphicon-plane:before { + content: "\e108"; +} + +.glyphicon-random:before { + content: "\e110"; +} + +.glyphicon-comment:before { + content: "\e111"; +} + +.glyphicon-magnet:before { + content: "\e112"; +} + +.glyphicon-chevron-up:before { + content: "\e113"; +} + +.glyphicon-chevron-down:before { + content: "\e114"; +} + +.glyphicon-retweet:before { + content: "\e115"; +} + +.glyphicon-shopping-cart:before { + content: "\e116"; +} + +.glyphicon-folder-close:before { + content: "\e117"; +} + +.glyphicon-folder-open:before { + content: "\e118"; +} + +.glyphicon-resize-vertical:before { + content: "\e119"; +} + +.glyphicon-resize-horizontal:before { + content: "\e120"; +} + +.glyphicon-hdd:before { + content: "\e121"; +} + +.glyphicon-bullhorn:before { + content: "\e122"; +} + +.glyphicon-certificate:before { + content: "\e124"; +} + +.glyphicon-thumbs-up:before { + content: "\e125"; +} + +.glyphicon-thumbs-down:before { + content: "\e126"; +} + +.glyphicon-hand-right:before { + content: "\e127"; +} + +.glyphicon-hand-left:before { + content: "\e128"; +} + +.glyphicon-hand-up:before { + content: "\e129"; +} + +.glyphicon-hand-down:before { + content: "\e130"; +} + +.glyphicon-circle-arrow-right:before { + content: "\e131"; +} + +.glyphicon-circle-arrow-left:before { + content: "\e132"; +} + +.glyphicon-circle-arrow-up:before { + content: "\e133"; +} + +.glyphicon-circle-arrow-down:before { + content: "\e134"; +} + +.glyphicon-globe:before { + content: "\e135"; +} + +.glyphicon-tasks:before { + content: "\e137"; +} + +.glyphicon-filter:before { + content: "\e138"; +} + +.glyphicon-fullscreen:before { + content: "\e140"; +} + +.glyphicon-dashboard:before { + content: "\e141"; +} + +.glyphicon-heart-empty:before { + content: "\e143"; +} + +.glyphicon-link:before { + content: "\e144"; +} + +.glyphicon-phone:before { + content: "\e145"; +} + +.glyphicon-usd:before { + content: "\e148"; +} + +.glyphicon-gbp:before { + content: "\e149"; +} + +.glyphicon-sort:before { + content: "\e150"; +} + +.glyphicon-sort-by-alphabet:before { + content: "\e151"; +} + +.glyphicon-sort-by-alphabet-alt:before { + content: "\e152"; +} + +.glyphicon-sort-by-order:before { + content: "\e153"; +} + +.glyphicon-sort-by-order-alt:before { + content: "\e154"; +} + +.glyphicon-sort-by-attributes:before { + content: "\e155"; +} + +.glyphicon-sort-by-attributes-alt:before { + content: "\e156"; +} + +.glyphicon-unchecked:before { + content: "\e157"; +} + +.glyphicon-expand:before { + content: "\e158"; +} + +.glyphicon-collapse-down:before { + content: "\e159"; +} + +.glyphicon-collapse-up:before { + content: "\e160"; +} + +.glyphicon-log-in:before { + content: "\e161"; +} + +.glyphicon-flash:before { + content: "\e162"; +} + +.glyphicon-log-out:before { + content: "\e163"; +} + +.glyphicon-new-window:before { + content: "\e164"; +} + +.glyphicon-record:before { + content: "\e165"; +} + +.glyphicon-save:before { + content: "\e166"; +} + +.glyphicon-open:before { + content: "\e167"; +} + +.glyphicon-saved:before { + content: "\e168"; +} + +.glyphicon-import:before { + content: "\e169"; +} + +.glyphicon-export:before { + content: "\e170"; +} + +.glyphicon-send:before { + content: "\e171"; +} + +.glyphicon-floppy-disk:before { + content: "\e172"; +} + +.glyphicon-floppy-saved:before { + content: "\e173"; +} + +.glyphicon-floppy-remove:before { + content: "\e174"; +} + +.glyphicon-floppy-save:before { + content: "\e175"; +} + +.glyphicon-floppy-open:before { + content: "\e176"; +} + +.glyphicon-credit-card:before { + content: "\e177"; +} + +.glyphicon-transfer:before { + content: "\e178"; +} + +.glyphicon-cutlery:before { + content: "\e179"; +} + +.glyphicon-header:before { + content: "\e180"; +} + +.glyphicon-compressed:before { + content: "\e181"; +} + +.glyphicon-earphone:before { + content: "\e182"; +} + +.glyphicon-phone-alt:before { + content: "\e183"; +} + +.glyphicon-tower:before { + content: "\e184"; +} + +.glyphicon-stats:before { + content: "\e185"; +} + +.glyphicon-sd-video:before { + content: "\e186"; +} + +.glyphicon-hd-video:before { + content: "\e187"; +} + +.glyphicon-subtitles:before { + content: "\e188"; +} + +.glyphicon-sound-stereo:before { + content: "\e189"; +} + +.glyphicon-sound-dolby:before { + content: "\e190"; } -input[type="button"], input[type="reset"], input[type="submit"] { - width: auto; - height: auto; + +.glyphicon-sound-5-1:before { + content: "\e191"; } -select, input[type="file"] { - height: 28px; - /* In IE7, the height of the select element cannot be changed by height, only font-size */ - *margin-top: 4px; - /* For IE7, add top margin to align select with labels */ +.glyphicon-sound-6-1:before { + content: "\e192"; +} - line-height: 28px; +.glyphicon-sound-7-1:before { + content: "\e193"; } -select { - width: 220px; - background-color: #ffffff; + +.glyphicon-copyright-mark:before { + content: "\e194"; } -select[multiple], select[size] { - height: auto; + +.glyphicon-registration-mark:before { + content: "\e195"; } -input[type="image"] { - -webkit-box-shadow: none; - -moz-box-shadow: none; - box-shadow: none; + +.glyphicon-cloud-download:before { + content: "\e197"; } -textarea { - height: auto; + +.glyphicon-cloud-upload:before { + content: "\e198"; } -input[type="hidden"] { - display: none; + +.glyphicon-tree-conifer:before { + content: "\e199"; } -.radio, .checkbox { - padding-left: 18px; + +.glyphicon-tree-deciduous:before { + content: "\e200"; } -.radio input[type="radio"], .checkbox input[type="checkbox"] { - float: left; - margin-left: -18px; + +.glyphicon-briefcase:before { + content: "\1f4bc"; +} + +.glyphicon-calendar:before { + content: "\1f4c5"; +} + +.glyphicon-pushpin:before { + content: "\1f4cc"; +} + +.glyphicon-paperclip:before { + content: "\1f4ce"; +} + +.glyphicon-camera:before { + content: "\1f4f7"; +} + +.glyphicon-lock:before { + content: "\1f512"; +} + +.glyphicon-bell:before { + content: "\1f514"; +} + +.glyphicon-bookmark:before { + content: "\1f516"; +} + +.glyphicon-fire:before { + content: "\1f525"; } -.controls > .radio:first-child, .controls > .checkbox:first-child { - padding-top: 5px; + +.glyphicon-wrench:before { + content: "\1f527"; } -.radio.inline, .checkbox.inline { + +.caret { display: inline-block; - margin-bottom: 0; + width: 0; + height: 0; + margin-left: 2px; vertical-align: middle; + border-top: 4px solid #000000; + border-right: 4px solid transparent; + border-bottom: 0 dotted; + border-left: 4px solid transparent; + content: ""; } -.radio.inline + .radio.inline, .checkbox.inline + .checkbox.inline { - margin-left: 10px; + +.dropdown { + position: relative; } -.controls > .radio.inline:first-child, .controls > .checkbox.inline:first-child { - padding-top: 0; + +.dropdown-toggle:focus { + outline: 0; } -input, textarea { - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -webkit-transition: border linear 0.2s, box-shadow linear 0.2s; - -moz-transition: border linear 0.2s, box-shadow linear 0.2s; - -ms-transition: border linear 0.2s, box-shadow linear 0.2s; - -o-transition: border linear 0.2s, box-shadow linear 0.2s; - transition: border linear 0.2s, box-shadow linear 0.2s; -} -input:focus, textarea:focus { - border-color: rgba(82, 168, 236, 0.8); - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); + +.dropdown-menu { + position: absolute; + top: 100%; + left: 0; + z-index: 1000; + display: none; + float: left; + min-width: 160px; + padding: 5px 0; + margin: 2px 0 0; + font-size: 14px; + list-style: none; + background-color: #ffffff; + border: 1px solid #cccccc; + border: 1px solid rgba(0, 0, 0, 0.15); + border-radius: 4px; + -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); + box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); + background-clip: padding-box; +} + +.dropdown-menu.pull-right { + right: 0; + left: auto; +} + +.dropdown-menu .divider { + height: 1px; + margin: 9px 0; + overflow: hidden; + background-color: #e5e5e5; +} + +.dropdown-menu > li > a { + display: block; + padding: 3px 20px; + clear: both; + font-weight: normal; + line-height: 1.428571429; + color: #333333; + white-space: nowrap; +} + +.dropdown-menu > li > a:hover, +.dropdown-menu > li > a:focus { + color: #ffffff; + text-decoration: none; + background-color: #428bca; +} + +.dropdown-menu > .active > a, +.dropdown-menu > .active > a:hover, +.dropdown-menu > .active > a:focus { + color: #ffffff; + text-decoration: none; + background-color: #428bca; outline: 0; - outline: thin dotted \9; - /* IE6-8 */ +} +.dropdown-menu > .disabled > a, +.dropdown-menu > .disabled > a:hover, +.dropdown-menu > .disabled > a:focus { + color: #999999; } -input[type="file"]:focus, input[type="checkbox"]:focus, select:focus { - -webkit-box-shadow: none; - -moz-box-shadow: none; - box-shadow: none; - outline: thin dotted; - outline: 5px auto -webkit-focus-ring-color; - outline-offset: -2px; + +.dropdown-menu > .disabled > a:hover, +.dropdown-menu > .disabled > a:focus { + text-decoration: none; + cursor: not-allowed; + background-color: transparent; + background-image: none; + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); } -.input-mini { - width: 60px; + +.open > .dropdown-menu { + display: block; } -.input-small { - width: 90px; + +.open > a { + outline: 0; } -.input-medium { - width: 150px; + +.dropdown-header { + display: block; + padding: 3px 20px; + font-size: 12px; + line-height: 1.428571429; + color: #999999; } -.input-large { - width: 210px; + +.dropdown-backdrop { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 990; } -.input-xlarge { - width: 270px; + +.pull-right > .dropdown-menu { + right: 0; + left: auto; } -.input-xxlarge { - width: 530px; + +.dropup .caret, +.navbar-fixed-bottom .dropdown .caret { + border-top: 0 dotted; + border-bottom: 4px solid #000000; + content: ""; } -input[class*="span"], -select[class*="span"], -textarea[class*="span"], -.uneditable-input { - float: none; + +.dropup .dropdown-menu, +.navbar-fixed-bottom .dropdown .dropdown-menu { + top: auto; + bottom: 100%; + margin-bottom: 1px; +} + +@media (min-width: 768px) { + .navbar-right .dropdown-menu { + right: 0; + left: auto; + } +} + +.btn-default .caret { + border-top-color: #333333; +} + +.btn-primary .caret, +.btn-success .caret, +.btn-warning .caret, +.btn-danger .caret, +.btn-info .caret { + border-top-color: #fff; +} + +.dropup .btn-default .caret { + border-bottom-color: #333333; +} + +.dropup .btn-primary .caret, +.dropup .btn-success .caret, +.dropup .btn-warning .caret, +.dropup .btn-danger .caret, +.dropup .btn-info .caret { + border-bottom-color: #fff; +} + +.btn-group, +.btn-group-vertical { + position: relative; + display: inline-block; + vertical-align: middle; +} + +.btn-group > .btn, +.btn-group-vertical > .btn { + position: relative; + float: left; +} + +.btn-group > .btn:hover, +.btn-group-vertical > .btn:hover, +.btn-group > .btn:focus, +.btn-group-vertical > .btn:focus, +.btn-group > .btn:active, +.btn-group-vertical > .btn:active, +.btn-group > .btn.active, +.btn-group-vertical > .btn.active { + z-index: 2; +} + +.btn-group > .btn:focus, +.btn-group-vertical > .btn:focus { + outline: none; +} + +.btn-group .btn + .btn, +.btn-group .btn + .btn-group, +.btn-group .btn-group + .btn, +.btn-group .btn-group + .btn-group { + margin-left: -1px; +} + +.btn-toolbar:before, +.btn-toolbar:after { + display: table; + content: " "; +} + +.btn-toolbar:after { + clear: both; +} + +.btn-toolbar:before, +.btn-toolbar:after { + display: table; + content: " "; +} + +.btn-toolbar:after { + clear: both; +} + +.btn-toolbar .btn-group { + float: left; +} + +.btn-toolbar > .btn + .btn, +.btn-toolbar > .btn-group + .btn, +.btn-toolbar > .btn + .btn-group, +.btn-toolbar > .btn-group + .btn-group { + margin-left: 5px; +} + +.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) { + border-radius: 0; +} + +.btn-group > .btn:first-child { margin-left: 0; } -input.span1, textarea.span1, .uneditable-input.span1 { - width: 50px; + +.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; +} + +.btn-group > .btn:last-child:not(:first-child), +.btn-group > .dropdown-toggle:not(:first-child) { + border-bottom-left-radius: 0; + border-top-left-radius: 0; +} + +.btn-group > .btn-group { + float: left; +} + +.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn { + border-radius: 0; +} + +.btn-group > .btn-group:first-child > .btn:last-child, +.btn-group > .btn-group:first-child > .dropdown-toggle { + border-top-right-radius: 0; + border-bottom-right-radius: 0; } -input.span2, textarea.span2, .uneditable-input.span2 { - width: 130px; + +.btn-group > .btn-group:last-child > .btn:first-child { + border-bottom-left-radius: 0; + border-top-left-radius: 0; } -input.span3, textarea.span3, .uneditable-input.span3 { - width: 210px; + +.btn-group .dropdown-toggle:active, +.btn-group.open .dropdown-toggle { + outline: 0; } -input.span4, textarea.span4, .uneditable-input.span4 { - width: 290px; + +.btn-group-xs > .btn { + padding: 5px 10px; + padding: 1px 5px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } -input.span5, textarea.span5, .uneditable-input.span5 { - width: 370px; + +.btn-group-sm > .btn { + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } -input.span6, textarea.span6, .uneditable-input.span6 { - width: 450px; + +.btn-group-lg > .btn { + padding: 10px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; } -input.span7, textarea.span7, .uneditable-input.span7 { - width: 530px; + +.btn-group > .btn + .dropdown-toggle { + padding-right: 8px; + padding-left: 8px; } -input.span8, textarea.span8, .uneditable-input.span8 { - width: 610px; + +.btn-group > .btn-lg + .dropdown-toggle { + padding-right: 12px; + padding-left: 12px; } -input.span9, textarea.span9, .uneditable-input.span9 { - width: 690px; + +.btn-group.open .dropdown-toggle { + -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); } -input.span10, textarea.span10, .uneditable-input.span10 { - width: 770px; + +.btn .caret { + margin-left: 0; } -input.span11, textarea.span11, .uneditable-input.span11 { - width: 850px; + +.btn-lg .caret { + border-width: 5px 5px 0; + border-bottom-width: 0; } -input.span12, textarea.span12, .uneditable-input.span12 { - width: 930px; + +.dropup .btn-lg .caret { + border-width: 0 5px 5px; } -input[disabled], -select[disabled], -textarea[disabled], -input[readonly], -select[readonly], -textarea[readonly] { - background-color: #f5f5f5; - border-color: #ddd; - cursor: not-allowed; + +.btn-group-vertical > .btn, +.btn-group-vertical > .btn-group { + display: block; + float: none; + width: 100%; + max-width: 100%; } -.control-group.warning > label, .control-group.warning .help-block, .control-group.warning .help-inline { - color: #c09853; + +.btn-group-vertical > .btn-group:before, +.btn-group-vertical > .btn-group:after { + display: table; + content: " "; } -.control-group.warning input, .control-group.warning select, .control-group.warning textarea { - color: #c09853; - border-color: #c09853; + +.btn-group-vertical > .btn-group:after { + clear: both; } -.control-group.warning input:focus, .control-group.warning select:focus, .control-group.warning textarea:focus { - border-color: #a47e3c; - -webkit-box-shadow: 0 0 6px #dbc59e; - -moz-box-shadow: 0 0 6px #dbc59e; - box-shadow: 0 0 6px #dbc59e; + +.btn-group-vertical > .btn-group:before, +.btn-group-vertical > .btn-group:after { + display: table; + content: " "; } -.control-group.warning .input-prepend .add-on, .control-group.warning .input-append .add-on { - color: #c09853; - background-color: #fcf8e3; - border-color: #c09853; + +.btn-group-vertical > .btn-group:after { + clear: both; +} + +.btn-group-vertical > .btn-group > .btn { + float: none; +} + +.btn-group-vertical > .btn + .btn, +.btn-group-vertical > .btn + .btn-group, +.btn-group-vertical > .btn-group + .btn, +.btn-group-vertical > .btn-group + .btn-group { + margin-top: -1px; + margin-left: 0; +} + +.btn-group-vertical > .btn:not(:first-child):not(:last-child) { + border-radius: 0; +} + +.btn-group-vertical > .btn:first-child:not(:last-child) { + border-top-right-radius: 4px; + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; } -.control-group.error > label, .control-group.error .help-block, .control-group.error .help-inline { - color: #b94a48; + +.btn-group-vertical > .btn:last-child:not(:first-child) { + border-top-right-radius: 0; + border-bottom-left-radius: 4px; + border-top-left-radius: 0; } -.control-group.error input, .control-group.error select, .control-group.error textarea { - color: #b94a48; - border-color: #b94a48; + +.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn { + border-radius: 0; } -.control-group.error input:focus, .control-group.error select:focus, .control-group.error textarea:focus { - border-color: #953b39; - -webkit-box-shadow: 0 0 6px #d59392; - -moz-box-shadow: 0 0 6px #d59392; - box-shadow: 0 0 6px #d59392; + +.btn-group-vertical > .btn-group:first-child > .btn:last-child, +.btn-group-vertical > .btn-group:first-child > .dropdown-toggle { + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; } -.control-group.error .input-prepend .add-on, .control-group.error .input-append .add-on { - color: #b94a48; - background-color: #f2dede; - border-color: #b94a48; + +.btn-group-vertical > .btn-group:last-child > .btn:first-child { + border-top-right-radius: 0; + border-top-left-radius: 0; } -.control-group.success > label, .control-group.success .help-block, .control-group.success .help-inline { - color: #468847; + +.btn-group-justified { + display: table; + width: 100%; + border-collapse: separate; + table-layout: fixed; } -.control-group.success input, .control-group.success select, .control-group.success textarea { - color: #468847; - border-color: #468847; + +.btn-group-justified .btn { + display: table-cell; + float: none; + width: 1%; } -.control-group.success input:focus, .control-group.success select:focus, .control-group.success textarea:focus { - border-color: #356635; - -webkit-box-shadow: 0 0 6px #7aba7b; - -moz-box-shadow: 0 0 6px #7aba7b; - box-shadow: 0 0 6px #7aba7b; + +[data-toggle="buttons"] > .btn > input[type="radio"], +[data-toggle="buttons"] > .btn > input[type="checkbox"] { + display: none; } -.control-group.success .input-prepend .add-on, .control-group.success .input-append .add-on { - color: #468847; - background-color: #dff0d8; - border-color: #468847; + +.input-group { + position: relative; + display: table; + border-collapse: separate; } -input:focus:required:invalid, textarea:focus:required:invalid, select:focus:required:invalid { - color: #b94a48; - border-color: #ee5f5b; -} -input:focus:required:invalid:focus, textarea:focus:required:invalid:focus, select:focus:required:invalid:focus { - border-color: #e9322d; - -webkit-box-shadow: 0 0 6px #f8b9b7; - -moz-box-shadow: 0 0 6px #f8b9b7; - box-shadow: 0 0 6px #f8b9b7; -} -.form-actions { - padding: 17px 20px 18px; - margin-top: 18px; - margin-bottom: 18px; - background-color: #f5f5f5; - border-top: 1px solid #ddd; + +.input-group.col { + float: none; + padding-right: 0; + padding-left: 0; } -.uneditable-input { - display: block; - background-color: #ffffff; - border-color: #eee; - -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); - -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); - box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); - cursor: not-allowed; + +.input-group .form-control { + width: 100%; + margin-bottom: 0; } -:-moz-placeholder { - color: #999999; + +.input-group-lg > .form-control, +.input-group-lg > .input-group-addon, +.input-group-lg > .input-group-btn > .btn { + height: 45px; + padding: 10px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; } -::-webkit-input-placeholder { - color: #999999; + +select.input-group-lg > .form-control, +select.input-group-lg > .input-group-addon, +select.input-group-lg > .input-group-btn > .btn { + height: 45px; + line-height: 45px; } -.help-block { - margin-top: 5px; - margin-bottom: 0; - color: #999999; + +textarea.input-group-lg > .form-control, +textarea.input-group-lg > .input-group-addon, +textarea.input-group-lg > .input-group-btn > .btn { + height: auto; } -.help-inline { - display: inline-block; - *display: inline; - /* IE7 inline-block hack */ - *zoom: 1; - margin-bottom: 9px; - vertical-align: middle; - padding-left: 5px; +.input-group-sm > .form-control, +.input-group-sm > .input-group-addon, +.input-group-sm > .input-group-btn > .btn { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } -.input-prepend, .input-append { - margin-bottom: 5px; - *zoom: 1; + +select.input-group-sm > .form-control, +select.input-group-sm > .input-group-addon, +select.input-group-sm > .input-group-btn > .btn { + height: 30px; + line-height: 30px; } -.input-prepend:before, -.input-append:before, -.input-prepend:after, -.input-append:after { - display: table; - content: ""; + +textarea.input-group-sm > .form-control, +textarea.input-group-sm > .input-group-addon, +textarea.input-group-sm > .input-group-btn > .btn { + height: auto; } -.input-prepend:after, .input-append:after { - clear: both; + +.input-group-addon, +.input-group-btn, +.input-group .form-control { + display: table-cell; } -.input-prepend input, -.input-append input, -.input-prepend .uneditable-input, -.input-append .uneditable-input { - -webkit-border-radius: 0 3px 3px 0; - -moz-border-radius: 0 3px 3px 0; - border-radius: 0 3px 3px 0; -} -.input-prepend input:focus, -.input-append input:focus, -.input-prepend .uneditable-input:focus, -.input-append .uneditable-input:focus { - position: relative; - z-index: 2; + +.input-group-addon:not(:first-child):not(:last-child), +.input-group-btn:not(:first-child):not(:last-child), +.input-group .form-control:not(:first-child):not(:last-child) { + border-radius: 0; } -.input-prepend .uneditable-input, .input-append .uneditable-input { - border-left-color: #ccc; + +.input-group-addon, +.input-group-btn { + width: 1%; + white-space: nowrap; + vertical-align: middle; } -.input-prepend .add-on, .input-append .add-on { - float: left; - display: block; - width: auto; - min-width: 16px; - height: 18px; - margin-right: -1px; - padding: 4px 5px; + +.input-group-addon { + padding: 6px 12px; + font-size: 14px; font-weight: normal; - line-height: 18px; - color: #999999; + line-height: 1; text-align: center; - text-shadow: 0 1px 0 #ffffff; - background-color: #f5f5f5; - border: 1px solid #ccc; - -webkit-border-radius: 3px 0 0 3px; - -moz-border-radius: 3px 0 0 3px; - border-radius: 3px 0 0 3px; -} -.input-prepend .active, .input-append .active { - background-color: #a9dba9; - border-color: #46a546; + background-color: #eeeeee; + border: 1px solid #cccccc; + border-radius: 4px; } -.input-prepend .add-on { - *margin-top: 1px; - /* IE6-7 */ +.input-group-addon.input-sm { + padding: 5px 10px; + font-size: 12px; + border-radius: 3px; } -.input-append input, .input-append .uneditable-input { - float: left; - -webkit-border-radius: 3px 0 0 3px; - -moz-border-radius: 3px 0 0 3px; - border-radius: 3px 0 0 3px; + +.input-group-addon.input-lg { + padding: 10px 16px; + font-size: 18px; + border-radius: 6px; } -.input-append .uneditable-input { - border-right-color: #ccc; + +.input-group-addon input[type="radio"], +.input-group-addon input[type="checkbox"] { + margin-top: 0; } -.input-append .add-on { - margin-right: 0; - margin-left: -1px; - -webkit-border-radius: 0 3px 3px 0; - -moz-border-radius: 0 3px 3px 0; - border-radius: 0 3px 3px 0; + +.input-group .form-control:first-child, +.input-group-addon:first-child, +.input-group-btn:first-child > .btn, +.input-group-btn:first-child > .dropdown-toggle, +.input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; } -.input-append input:first-child { - *margin-left: -160px; + +.input-group-addon:first-child { + border-right: 0; } -.input-append input:first-child + .add-on { - *margin-left: -21px; + +.input-group .form-control:last-child, +.input-group-addon:last-child, +.input-group-btn:last-child > .btn, +.input-group-btn:last-child > .dropdown-toggle, +.input-group-btn:first-child > .btn:not(:first-child) { + border-bottom-left-radius: 0; + border-top-left-radius: 0; } -.search-query { - padding-left: 14px; - padding-right: 14px; - margin-bottom: 0; - -webkit-border-radius: 14px; - -moz-border-radius: 14px; - border-radius: 14px; -} -.form-search input, -.form-inline input, -.form-horizontal input, -.form-search textarea, -.form-inline textarea, -.form-horizontal textarea, -.form-search select, -.form-inline select, -.form-horizontal select, -.form-search .help-inline, -.form-inline .help-inline, -.form-horizontal .help-inline, -.form-search .uneditable-input, -.form-inline .uneditable-input, -.form-horizontal .uneditable-input { - display: inline-block; - margin-bottom: 0; + +.input-group-addon:last-child { + border-left: 0; } -.form-search label, -.form-inline label, -.form-search .input-append, -.form-inline .input-append, -.form-search .input-prepend, -.form-inline .input-prepend { - display: inline-block; + +.input-group-btn { + position: relative; + white-space: nowrap; } -.form-search .input-append .add-on, -.form-inline .input-prepend .add-on, -.form-search .input-append .add-on, -.form-inline .input-prepend .add-on { - vertical-align: middle; + +.input-group-btn > .btn { + position: relative; } -.control-group { - margin-bottom: 9px; + +.input-group-btn > .btn + .btn { + margin-left: -4px; } -.form-horizontal legend + .control-group { - margin-top: 18px; - -webkit-margin-top-collapse: separate; + +.input-group-btn > .btn:hover, +.input-group-btn > .btn:active { + z-index: 2; } -.form-horizontal .control-group { - margin-bottom: 18px; - *zoom: 1; + +.nav { + padding-left: 0; + margin-bottom: 0; + list-style: none; } -.form-horizontal .control-group:before, .form-horizontal .control-group:after { + +.nav:before, +.nav:after { display: table; - content: ""; + content: " "; } -.form-horizontal .control-group:after { + +.nav:after { clear: both; } -.form-horizontal .control-group > label { - float: left; - width: 140px; - padding-top: 5px; - text-align: right; -} -.form-horizontal .controls { - margin-left: 160px; -} -.form-horizontal .form-actions { - padding-left: 160px; -} -table { - max-width: 100%; - border-collapse: collapse; - border-spacing: 0; -} -.table { - width: 100%; - margin-bottom: 18px; + +.nav:before, +.nav:after { + display: table; + content: " "; } -.table th, .table td { - padding: 8px; - line-height: 18px; - text-align: left; - border-top: 1px solid #ddd; + +.nav:after { + clear: both; } -.table th { - font-weight: bold; - vertical-align: bottom; + +.nav > li { + position: relative; + display: block; } -.table td { - vertical-align: top; + +.nav > li > a { + position: relative; + display: block; + padding: 10px 15px; } -.table thead:first-child tr th, .table thead:first-child tr td { - border-top: 0; + +.nav > li > a:hover, +.nav > li > a:focus { + text-decoration: none; + background-color: #eeeeee; } -.table tbody + tbody { - border-top: 2px solid #ddd; + +.nav > li.disabled > a { + color: #999999; } -.table-condensed th, .table-condensed td { - padding: 4px 5px; + +.nav > li.disabled > a:hover, +.nav > li.disabled > a:focus { + color: #999999; + text-decoration: none; + cursor: not-allowed; + background-color: transparent; } -.table-bordered { - border: 1px solid #ddd; - border-collapse: separate; - *border-collapse: collapsed; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; + +.nav .open > a, +.nav .open > a:hover, +.nav .open > a:focus { + background-color: #eeeeee; + border-color: #428bca; } -.table-bordered th + th, -.table-bordered td + td, -.table-bordered th + td, -.table-bordered td + th { - border-left: 1px solid #ddd; + +.nav .nav-divider { + height: 1px; + margin: 9px 0; + overflow: hidden; + background-color: #e5e5e5; } -.table-bordered thead:first-child tr:first-child th, .table-bordered tbody:first-child tr:first-child th, .table-bordered tbody:first-child tr:first-child td { - border-top: 0; + +.nav > li > a > img { + max-width: none; } -.table-bordered thead:first-child tr:first-child th:first-child, .table-bordered tbody:first-child tr:first-child td:first-child { - -webkit-border-radius: 4px 0 0 0; - -moz-border-radius: 4px 0 0 0; - border-radius: 4px 0 0 0; + +.nav-tabs { + border-bottom: 1px solid #dddddd; } -.table-bordered thead:first-child tr:first-child th:last-child, .table-bordered tbody:first-child tr:first-child td:last-child { - -webkit-border-radius: 0 4px 0 0; - -moz-border-radius: 0 4px 0 0; - border-radius: 0 4px 0 0; + +.nav-tabs > li { + float: left; + margin-bottom: -1px; } -.table-bordered thead:last-child tr:last-child th:first-child, .table-bordered tbody:last-child tr:last-child td:first-child { - -webkit-border-radius: 0 0 0 4px; - -moz-border-radius: 0 0 0 4px; - border-radius: 0 0 0 4px; + +.nav-tabs > li > a { + margin-right: 2px; + line-height: 1.428571429; + border: 1px solid transparent; + border-radius: 4px 4px 0 0; } -.table-bordered thead:last-child tr:last-child th:last-child, .table-bordered tbody:last-child tr:last-child td:last-child { - -webkit-border-radius: 0 0 4px 0; - -moz-border-radius: 0 0 4px 0; - border-radius: 0 0 4px 0; + +.nav-tabs > li > a:hover { + border-color: #eeeeee #eeeeee #dddddd; } -.table-striped tbody tr:nth-child(odd) td, .table-striped tbody tr:nth-child(odd) th { - background-color: #f9f9f9; + +.nav-tabs > li.active > a, +.nav-tabs > li.active > a:hover, +.nav-tabs > li.active > a:focus { + color: #555555; + cursor: default; + background-color: #ffffff; + border: 1px solid #dddddd; + border-bottom-color: transparent; } -table .span1 { - float: none; - width: 44px; - margin-left: 0; + +.nav-tabs.nav-justified { + width: 100%; + border-bottom: 0; } -table .span2 { + +.nav-tabs.nav-justified > li { float: none; - width: 124px; - margin-left: 0; } -table .span3 { - float: none; - width: 204px; - margin-left: 0; + +.nav-tabs.nav-justified > li > a { + text-align: center; } -table .span4 { - float: none; - width: 284px; - margin-left: 0; + +@media (min-width: 768px) { + .nav-tabs.nav-justified > li { + display: table-cell; + width: 1%; + } } -table .span5 { - float: none; - width: 364px; - margin-left: 0; + +.nav-tabs.nav-justified > li > a { + margin-right: 0; + border-bottom: 1px solid #dddddd; } -table .span6 { - float: none; - width: 444px; - margin-left: 0; + +.nav-tabs.nav-justified > .active > a { + border-bottom-color: #ffffff; } -table .span7 { - float: none; - width: 524px; - margin-left: 0; + +.nav-pills > li { + float: left; } -table .span8 { - float: none; - width: 604px; - margin-left: 0; + +.nav-pills > li > a { + border-radius: 5px; } -table .span9 { - float: none; - width: 684px; - margin-left: 0; + +.nav-pills > li + li { + margin-left: 2px; } -table .span10 { - float: none; - width: 764px; - margin-left: 0; + +.nav-pills > li.active > a, +.nav-pills > li.active > a:hover, +.nav-pills > li.active > a:focus { + color: #ffffff; + background-color: #428bca; } -table .span11 { + +.nav-stacked > li { float: none; - width: 844px; - margin-left: 0; } -table .span12 { - float: none; - width: 924px; + +.nav-stacked > li + li { + margin-top: 2px; margin-left: 0; } -[class^="icon-"] { - display: inline-block; - width: 14px; - height: 14px; - vertical-align: text-top; - background-image: url(../img/glyphicons-halflings.png); - background-position: 14px 14px; - background-repeat: no-repeat; - *margin-right: .3em; + +.nav-justified { + width: 100%; } -[class^="icon-"]:last-child { - *margin-left: 0; + +.nav-justified > li { + float: none; } -.icon-white { - background-image: url(../img/glyphicons-halflings-white.png); + +.nav-justified > li > a { + text-align: center; } -.icon-glass { - background-position: 0 0; + +@media (min-width: 768px) { + .nav-justified > li { + display: table-cell; + width: 1%; + } } -.icon-music { - background-position: -24px 0; + +.nav-tabs-justified { + border-bottom: 0; } -.icon-search { - background-position: -48px 0; + +.nav-tabs-justified > li > a { + margin-right: 0; + border-bottom: 1px solid #dddddd; } -.icon-envelope { - background-position: -72px 0; + +.nav-tabs-justified > .active > a { + border-bottom-color: #ffffff; } -.icon-heart { - background-position: -96px 0; + +.tabbable:before, +.tabbable:after { + display: table; + content: " "; } -.icon-star { - background-position: -120px 0; + +.tabbable:after { + clear: both; } -.icon-star-empty { - background-position: -144px 0; + +.tabbable:before, +.tabbable:after { + display: table; + content: " "; } -.icon-user { - background-position: -168px 0; + +.tabbable:after { + clear: both; } -.icon-film { - background-position: -192px 0; + +.tab-content > .tab-pane, +.pill-content > .pill-pane { + display: none; } -.icon-th-large { - background-position: -216px 0; + +.tab-content > .active, +.pill-content > .active { + display: block; } -.icon-th { - background-position: -240px 0; + +.nav .caret { + border-top-color: #428bca; + border-bottom-color: #428bca; } -.icon-th-list { - background-position: -264px 0; + +.nav a:hover .caret { + border-top-color: #2a6496; + border-bottom-color: #2a6496; } -.icon-ok { - background-position: -288px 0; + +.nav-tabs .dropdown-menu { + margin-top: -1px; + border-top-right-radius: 0; + border-top-left-radius: 0; } -.icon-remove { - background-position: -312px 0; + +.navbar { + position: relative; + z-index: 1000; + min-height: 50px; + margin-bottom: 20px; + border: 1px solid transparent; } -.icon-zoom-in { - background-position: -336px 0; + +.navbar:before, +.navbar:after { + display: table; + content: " "; } -.icon-zoom-out { - background-position: -360px 0; + +.navbar:after { + clear: both; } -.icon-off { - background-position: -384px 0; + +.navbar:before, +.navbar:after { + display: table; + content: " "; } -.icon-signal { - background-position: -408px 0; + +.navbar:after { + clear: both; } -.icon-cog { - background-position: -432px 0; + +@media (min-width: 768px) { + .navbar { + border-radius: 4px; + } } -.icon-trash { - background-position: -456px 0; + +.navbar-header:before, +.navbar-header:after { + display: table; + content: " "; } -.icon-home { - background-position: 0 -24px; + +.navbar-header:after { + clear: both; } -.icon-file { - background-position: -24px -24px; + +.navbar-header:before, +.navbar-header:after { + display: table; + content: " "; } -.icon-time { - background-position: -48px -24px; + +.navbar-header:after { + clear: both; } -.icon-road { - background-position: -72px -24px; + +@media (min-width: 768px) { + .navbar-header { + float: left; + } } -.icon-download-alt { - background-position: -96px -24px; + +.navbar-collapse { + max-height: 340px; + padding-right: 15px; + padding-left: 15px; + overflow-x: visible; + border-top: 1px solid transparent; + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1); + -webkit-overflow-scrolling: touch; } -.icon-download { - background-position: -120px -24px; + +.navbar-collapse:before, +.navbar-collapse:after { + display: table; + content: " "; } -.icon-upload { - background-position: -144px -24px; + +.navbar-collapse:after { + clear: both; } -.icon-inbox { - background-position: -168px -24px; + +.navbar-collapse:before, +.navbar-collapse:after { + display: table; + content: " "; } -.icon-play-circle { - background-position: -192px -24px; + +.navbar-collapse:after { + clear: both; } -.icon-repeat { - background-position: -216px -24px; + +.navbar-collapse.in { + overflow-y: auto; } -.icon-refresh { - background-position: -240px -24px; + +@media (min-width: 768px) { + .navbar-collapse { + width: auto; + border-top: 0; + box-shadow: none; + } + .navbar-collapse.collapse { + display: block !important; + height: auto !important; + padding-bottom: 0; + overflow: visible !important; + } + .navbar-collapse.in { + overflow-y: visible; + } + .navbar-collapse .navbar-nav.navbar-left:first-child { + margin-left: -15px; + } + .navbar-collapse .navbar-nav.navbar-right:last-child { + margin-right: -15px; + } + .navbar-collapse .navbar-text:last-child { + margin-right: 0; + } } -.icon-list-alt { - background-position: -264px -24px; + +.container > .navbar-header, +.container > .navbar-collapse { + margin-right: -15px; + margin-left: -15px; } -.icon-lock { - background-position: -287px -24px; + +@media (min-width: 768px) { + .container > .navbar-header, + .container > .navbar-collapse { + margin-right: 0; + margin-left: 0; + } } -.icon-flag { - background-position: -312px -24px; + +.navbar-static-top { + border-width: 0 0 1px; } -.icon-headphones { - background-position: -336px -24px; + +@media (min-width: 768px) { + .navbar-static-top { + border-radius: 0; + } } -.icon-volume-off { - background-position: -360px -24px; + +.navbar-fixed-top, +.navbar-fixed-bottom { + position: fixed; + right: 0; + left: 0; + border-width: 0 0 1px; } -.icon-volume-down { - background-position: -384px -24px; + +@media (min-width: 768px) { + .navbar-fixed-top, + .navbar-fixed-bottom { + border-radius: 0; + } } -.icon-volume-up { - background-position: -408px -24px; + +.navbar-fixed-top { + top: 0; + z-index: 1030; } -.icon-qrcode { - background-position: -432px -24px; + +.navbar-fixed-bottom { + bottom: 0; + margin-bottom: 0; } -.icon-barcode { - background-position: -456px -24px; + +.navbar-brand { + float: left; + padding: 15px 15px; + font-size: 18px; + line-height: 20px; } -.icon-tag { - background-position: 0 -48px; + +.navbar-brand:hover, +.navbar-brand:focus { + text-decoration: none; } -.icon-tags { - background-position: -25px -48px; + +@media (min-width: 768px) { + .navbar > .container .navbar-brand { + margin-left: -15px; + } } -.icon-book { - background-position: -48px -48px; + +.navbar-toggle { + position: relative; + float: right; + padding: 9px 10px; + margin-top: 8px; + margin-right: 15px; + margin-bottom: 8px; + background-color: transparent; + border: 1px solid transparent; + border-radius: 4px; } -.icon-bookmark { - background-position: -72px -48px; + +.navbar-toggle .icon-bar { + display: block; + width: 22px; + height: 2px; + border-radius: 1px; } -.icon-print { - background-position: -96px -48px; + +.navbar-toggle .icon-bar + .icon-bar { + margin-top: 4px; } -.icon-camera { - background-position: -120px -48px; + +@media (min-width: 768px) { + .navbar-toggle { + display: none; + } } -.icon-font { - background-position: -144px -48px; + +.navbar-nav { + margin: 7.5px -15px; } -.icon-bold { - background-position: -167px -48px; + +.navbar-nav > li > a { + padding-top: 10px; + padding-bottom: 10px; + line-height: 20px; } -.icon-italic { - background-position: -192px -48px; + +@media (max-width: 767px) { + .navbar-nav .open .dropdown-menu { + position: static; + float: none; + width: auto; + margin-top: 0; + background-color: transparent; + border: 0; + box-shadow: none; + } + .navbar-nav .open .dropdown-menu > li > a, + .navbar-nav .open .dropdown-menu .dropdown-header { + padding: 5px 15px 5px 25px; + } + .navbar-nav .open .dropdown-menu > li > a { + line-height: 20px; + } + .navbar-nav .open .dropdown-menu > li > a:hover, + .navbar-nav .open .dropdown-menu > li > a:focus { + background-image: none; + } } -.icon-text-height { - background-position: -216px -48px; + +@media (min-width: 768px) { + .navbar-nav { + float: left; + margin: 0; + } + .navbar-nav > li { + float: left; + } + .navbar-nav > li > a { + padding-top: 15px; + padding-bottom: 15px; + } } -.icon-text-width { - background-position: -240px -48px; + +@media (min-width: 768px) { + .navbar-left { + float: left !important; + } + .navbar-right { + float: right !important; + } } -.icon-align-left { - background-position: -264px -48px; + +.navbar-form { + padding: 10px 15px; + margin-top: 8px; + margin-right: -15px; + margin-bottom: 8px; + margin-left: -15px; + border-top: 1px solid transparent; + border-bottom: 1px solid transparent; + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); } -.icon-align-center { - background-position: -288px -48px; + +@media (min-width: 768px) { + .navbar-form .form-group { + display: inline-block; + margin-bottom: 0; + vertical-align: middle; + } + .navbar-form .form-control { + display: inline-block; + } + .navbar-form .radio, + .navbar-form .checkbox { + display: inline-block; + padding-left: 0; + margin-top: 0; + margin-bottom: 0; + } + .navbar-form .radio input[type="radio"], + .navbar-form .checkbox input[type="checkbox"] { + float: none; + margin-left: 0; + } } -.icon-align-right { - background-position: -312px -48px; + +@media (max-width: 767px) { + .navbar-form .form-group { + margin-bottom: 5px; + } } -.icon-align-justify { - background-position: -336px -48px; + +@media (min-width: 768px) { + .navbar-form { + width: auto; + padding-top: 0; + padding-bottom: 0; + margin-right: 0; + margin-left: 0; + border: 0; + -webkit-box-shadow: none; + box-shadow: none; + } } -.icon-list { - background-position: -360px -48px; + +.navbar-nav > li > .dropdown-menu { + margin-top: 0; + border-top-right-radius: 0; + border-top-left-radius: 0; } -.icon-indent-left { - background-position: -384px -48px; + +.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu { + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; } -.icon-indent-right { - background-position: -408px -48px; + +.navbar-nav.pull-right > li > .dropdown-menu, +.navbar-nav > li > .dropdown-menu.pull-right { + right: 0; + left: auto; } -.icon-facetime-video { - background-position: -432px -48px; + +.navbar-btn { + margin-top: 8px; + margin-bottom: 8px; } -.icon-picture { - background-position: -456px -48px; + +.navbar-text { + float: left; + margin-top: 15px; + margin-bottom: 15px; } -.icon-pencil { - background-position: 0 -72px; + +@media (min-width: 768px) { + .navbar-text { + margin-right: 15px; + margin-left: 15px; + } } -.icon-map-marker { - background-position: -24px -72px; + +.navbar-default { + background-color: #f8f8f8; + border-color: #e7e7e7; } -.icon-adjust { - background-position: -48px -72px; + +.navbar-default .navbar-brand { + color: #777777; } -.icon-tint { - background-position: -72px -72px; + +.navbar-default .navbar-brand:hover, +.navbar-default .navbar-brand:focus { + color: #5e5e5e; + background-color: transparent; } -.icon-edit { - background-position: -96px -72px; + +.navbar-default .navbar-text { + color: #777777; } -.icon-share { - background-position: -120px -72px; + +.navbar-default .navbar-nav > li > a { + color: #777777; } -.icon-check { - background-position: -144px -72px; + +.navbar-default .navbar-nav > li > a:hover, +.navbar-default .navbar-nav > li > a:focus { + color: #333333; + background-color: transparent; } -.icon-move { - background-position: -168px -72px; + +.navbar-default .navbar-nav > .active > a, +.navbar-default .navbar-nav > .active > a:hover, +.navbar-default .navbar-nav > .active > a:focus { + color: #555555; + background-color: #e7e7e7; } -.icon-step-backward { - background-position: -192px -72px; + +.navbar-default .navbar-nav > .disabled > a, +.navbar-default .navbar-nav > .disabled > a:hover, +.navbar-default .navbar-nav > .disabled > a:focus { + color: #cccccc; + background-color: transparent; } -.icon-fast-backward { - background-position: -216px -72px; + +.navbar-default .navbar-toggle { + border-color: #dddddd; } -.icon-backward { - background-position: -240px -72px; + +.navbar-default .navbar-toggle:hover, +.navbar-default .navbar-toggle:focus { + background-color: #dddddd; } -.icon-play { - background-position: -264px -72px; + +.navbar-default .navbar-toggle .icon-bar { + background-color: #cccccc; } -.icon-pause { - background-position: -288px -72px; + +.navbar-default .navbar-collapse, +.navbar-default .navbar-form { + border-color: #e6e6e6; } -.icon-stop { - background-position: -312px -72px; + +.navbar-default .navbar-nav > .dropdown > a:hover .caret, +.navbar-default .navbar-nav > .dropdown > a:focus .caret { + border-top-color: #333333; + border-bottom-color: #333333; } -.icon-forward { - background-position: -336px -72px; + +.navbar-default .navbar-nav > .open > a, +.navbar-default .navbar-nav > .open > a:hover, +.navbar-default .navbar-nav > .open > a:focus { + color: #555555; + background-color: #e7e7e7; } -.icon-fast-forward { - background-position: -360px -72px; + +.navbar-default .navbar-nav > .open > a .caret, +.navbar-default .navbar-nav > .open > a:hover .caret, +.navbar-default .navbar-nav > .open > a:focus .caret { + border-top-color: #555555; + border-bottom-color: #555555; } -.icon-step-forward { - background-position: -384px -72px; + +.navbar-default .navbar-nav > .dropdown > a .caret { + border-top-color: #777777; + border-bottom-color: #777777; } -.icon-eject { - background-position: -408px -72px; + +@media (max-width: 767px) { + .navbar-default .navbar-nav .open .dropdown-menu > li > a { + color: #777777; + } + .navbar-default .navbar-nav .open .dropdown-menu > li > a:hover, + .navbar-default .navbar-nav .open .dropdown-menu > li > a:focus { + color: #333333; + background-color: transparent; + } + .navbar-default .navbar-nav .open .dropdown-menu > .active > a, + .navbar-default .navbar-nav .open .dropdown-menu > .active > a:hover, + .navbar-default .navbar-nav .open .dropdown-menu > .active > a:focus { + color: #555555; + background-color: #e7e7e7; + } + .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a, + .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:hover, + .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:focus { + color: #cccccc; + background-color: transparent; + } } -.icon-chevron-left { - background-position: -432px -72px; + +.navbar-default .navbar-link { + color: #777777; } -.icon-chevron-right { - background-position: -456px -72px; + +.navbar-default .navbar-link:hover { + color: #333333; } -.icon-plus-sign { - background-position: 0 -96px; + +.navbar-inverse { + background-color: #222222; + border-color: #080808; } -.icon-minus-sign { - background-position: -24px -96px; + +.navbar-inverse .navbar-brand { + color: #999999; } -.icon-remove-sign { - background-position: -48px -96px; + +.navbar-inverse .navbar-brand:hover, +.navbar-inverse .navbar-brand:focus { + color: #ffffff; + background-color: transparent; } -.icon-ok-sign { - background-position: -72px -96px; + +.navbar-inverse .navbar-text { + color: #999999; } -.icon-question-sign { - background-position: -96px -96px; + +.navbar-inverse .navbar-nav > li > a { + color: #999999; } -.icon-info-sign { - background-position: -120px -96px; + +.navbar-inverse .navbar-nav > li > a:hover, +.navbar-inverse .navbar-nav > li > a:focus { + color: #ffffff; + background-color: transparent; } -.icon-screenshot { - background-position: -144px -96px; + +.navbar-inverse .navbar-nav > .active > a, +.navbar-inverse .navbar-nav > .active > a:hover, +.navbar-inverse .navbar-nav > .active > a:focus { + color: #ffffff; + background-color: #080808; } -.icon-remove-circle { - background-position: -168px -96px; + +.navbar-inverse .navbar-nav > .disabled > a, +.navbar-inverse .navbar-nav > .disabled > a:hover, +.navbar-inverse .navbar-nav > .disabled > a:focus { + color: #444444; + background-color: transparent; } -.icon-ok-circle { - background-position: -192px -96px; + +.navbar-inverse .navbar-toggle { + border-color: #333333; } -.icon-ban-circle { - background-position: -216px -96px; + +.navbar-inverse .navbar-toggle:hover, +.navbar-inverse .navbar-toggle:focus { + background-color: #333333; } -.icon-arrow-left { - background-position: -240px -96px; + +.navbar-inverse .navbar-toggle .icon-bar { + background-color: #ffffff; } -.icon-arrow-right { - background-position: -264px -96px; + +.navbar-inverse .navbar-collapse, +.navbar-inverse .navbar-form { + border-color: #101010; } -.icon-arrow-up { - background-position: -289px -96px; + +.navbar-inverse .navbar-nav > .open > a, +.navbar-inverse .navbar-nav > .open > a:hover, +.navbar-inverse .navbar-nav > .open > a:focus { + color: #ffffff; + background-color: #080808; } -.icon-arrow-down { - background-position: -312px -96px; + +.navbar-inverse .navbar-nav > .dropdown > a:hover .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; } -.icon-share-alt { - background-position: -336px -96px; + +.navbar-inverse .navbar-nav > .dropdown > a .caret { + border-top-color: #999999; + border-bottom-color: #999999; } -.icon-resize-full { - background-position: -360px -96px; + +.navbar-inverse .navbar-nav > .open > a .caret, +.navbar-inverse .navbar-nav > .open > a:hover .caret, +.navbar-inverse .navbar-nav > .open > a:focus .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; } -.icon-resize-small { - background-position: -384px -96px; + +@media (max-width: 767px) { + .navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header { + border-color: #080808; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a { + color: #999999; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:hover, + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:focus { + color: #ffffff; + background-color: transparent; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a, + .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover, + .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus { + color: #ffffff; + background-color: #080808; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a, + .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:hover, + .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:focus { + color: #444444; + background-color: transparent; + } } -.icon-plus { - background-position: -408px -96px; + +.navbar-inverse .navbar-link { + color: #999999; } -.icon-minus { - background-position: -433px -96px; + +.navbar-inverse .navbar-link:hover { + color: #ffffff; } -.icon-asterisk { - background-position: -456px -96px; + +.breadcrumb { + padding: 8px 15px; + margin-bottom: 20px; + list-style: none; + background-color: #f5f5f5; + border-radius: 4px; } -.icon-exclamation-sign { - background-position: 0 -120px; + +.breadcrumb > li { + display: inline-block; } -.icon-gift { - background-position: -24px -120px; + +.breadcrumb > li + li:before { + padding: 0 5px; + color: #cccccc; + content: "/\00a0"; } -.icon-leaf { - background-position: -48px -120px; + +.breadcrumb > .active { + color: #999999; } -.icon-fire { - background-position: -72px -120px; + +.pagination { + display: inline-block; + padding-left: 0; + margin: 20px 0; + border-radius: 4px; } -.icon-eye-open { - background-position: -96px -120px; + +.pagination > li { + display: inline; } -.icon-eye-close { - background-position: -120px -120px; + +.pagination > li > a, +.pagination > li > span { + position: relative; + float: left; + padding: 6px 12px; + margin-left: -1px; + line-height: 1.428571429; + text-decoration: none; + background-color: #ffffff; + border: 1px solid #dddddd; } -.icon-warning-sign { - background-position: -144px -120px; + +.pagination > li:first-child > a, +.pagination > li:first-child > span { + margin-left: 0; + border-bottom-left-radius: 4px; + border-top-left-radius: 4px; } -.icon-plane { - background-position: -168px -120px; + +.pagination > li:last-child > a, +.pagination > li:last-child > span { + border-top-right-radius: 4px; + border-bottom-right-radius: 4px; } -.icon-calendar { - background-position: -192px -120px; + +.pagination > li > a:hover, +.pagination > li > span:hover, +.pagination > li > a:focus, +.pagination > li > span:focus { + background-color: #eeeeee; } -.icon-random { - background-position: -216px -120px; + +.pagination > .active > a, +.pagination > .active > span, +.pagination > .active > a:hover, +.pagination > .active > span:hover, +.pagination > .active > a:focus, +.pagination > .active > span:focus { + z-index: 2; + color: #ffffff; + cursor: default; + background-color: #428bca; + border-color: #428bca; } -.icon-comment { - background-position: -240px -120px; + +.pagination > .disabled > span, +.pagination > .disabled > a, +.pagination > .disabled > a:hover, +.pagination > .disabled > a:focus { + color: #999999; + cursor: not-allowed; + background-color: #ffffff; + border-color: #dddddd; } -.icon-magnet { - background-position: -264px -120px; + +.pagination-lg > li > a, +.pagination-lg > li > span { + padding: 10px 16px; + font-size: 18px; } -.icon-chevron-up { - background-position: -288px -120px; + +.pagination-lg > li:first-child > a, +.pagination-lg > li:first-child > span { + border-bottom-left-radius: 6px; + border-top-left-radius: 6px; } -.icon-chevron-down { - background-position: -313px -119px; + +.pagination-lg > li:last-child > a, +.pagination-lg > li:last-child > span { + border-top-right-radius: 6px; + border-bottom-right-radius: 6px; } -.icon-retweet { - background-position: -336px -120px; + +.pagination-sm > li > a, +.pagination-sm > li > span { + padding: 5px 10px; + font-size: 12px; } -.icon-shopping-cart { - background-position: -360px -120px; + +.pagination-sm > li:first-child > a, +.pagination-sm > li:first-child > span { + border-bottom-left-radius: 3px; + border-top-left-radius: 3px; } -.icon-folder-close { - background-position: -384px -120px; + +.pagination-sm > li:last-child > a, +.pagination-sm > li:last-child > span { + border-top-right-radius: 3px; + border-bottom-right-radius: 3px; } -.icon-folder-open { - background-position: -408px -120px; + +.pager { + padding-left: 0; + margin: 20px 0; + text-align: center; + list-style: none; } -.icon-resize-vertical { - background-position: -432px -119px; + +.pager:before, +.pager:after { + display: table; + content: " "; } -.icon-resize-horizontal { - background-position: -456px -118px; + +.pager:after { + clear: both; } -.dropdown { - position: relative; + +.pager:before, +.pager:after { + display: table; + content: " "; } -.dropdown-toggle { - *margin-bottom: -3px; + +.pager:after { + clear: both; } -.dropdown-toggle:active, .open .dropdown-toggle { - outline: 0; + +.pager li { + display: inline; } -.caret { + +.pager li > a, +.pager li > span { display: inline-block; - width: 0; - height: 0; - text-indent: -99999px; - *text-indent: 0; - vertical-align: top; - border-left: 4px solid transparent; - border-right: 4px solid transparent; - border-top: 4px solid #000000; - opacity: 0.3; - filter: alpha(opacity=30); - content: "\2193"; + padding: 5px 14px; + background-color: #ffffff; + border: 1px solid #dddddd; + border-radius: 15px; } -.dropdown .caret { - margin-top: 8px; - margin-left: 2px; + +.pager li > a:hover, +.pager li > a:focus { + text-decoration: none; + background-color: #eeeeee; } -.dropdown:hover .caret, .open.dropdown .caret { - opacity: 1; - filter: alpha(opacity=100); + +.pager .next > a, +.pager .next > span { + float: right; } -.dropdown-menu { - position: absolute; - top: 100%; - left: 0; - z-index: 1000; + +.pager .previous > a, +.pager .previous > span { float: left; - display: none; - min-width: 160px; - max-width: 220px; - _width: 160px; - padding: 4px 0; - margin: 0; - list-style: none; - background-color: #ffffff; - border-color: #ccc; - border-color: rgba(0, 0, 0, 0.2); - border-style: solid; - border-width: 1px; - -webkit-border-radius: 0 0 5px 5px; - -moz-border-radius: 0 0 5px 5px; - border-radius: 0 0 5px 5px; - -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - -moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - -webkit-background-clip: padding-box; - -moz-background-clip: padding; - background-clip: padding-box; - *border-right-width: 2px; - *border-bottom-width: 2px; -} -.dropdown-menu.bottom-up { - top: auto; - bottom: 100%; - margin-bottom: 2px; } -.dropdown-menu .divider { - height: 1px; - margin: 5px 1px; - overflow: hidden; - background-color: #e5e5e5; - border-bottom: 1px solid #ffffff; - *width: 100%; - *margin: -5px 0 5px; + +.pager .disabled > a, +.pager .disabled > a:hover, +.pager .disabled > a:focus, +.pager .disabled > span { + color: #999999; + cursor: not-allowed; + background-color: #ffffff; } -.dropdown-menu a { - display: block; - padding: 3px 15px; - clear: both; - font-weight: normal; - line-height: 18px; - color: #555555; + +.label { + display: inline; + padding: .2em .6em .3em; + font-size: 75%; + font-weight: bold; + line-height: 1; + color: #ffffff; + text-align: center; white-space: nowrap; + vertical-align: baseline; + border-radius: .25em; } -.dropdown-menu li > a:hover, .dropdown-menu .active > a, .dropdown-menu .active > a:hover { + +.label[href]:hover, +.label[href]:focus { color: #ffffff; text-decoration: none; - background-color: #0088cc; + cursor: pointer; } -.dropdown.open { - *z-index: 1000; + +.label:empty { + display: none; } -.dropdown.open .dropdown-toggle { - color: #ffffff; - background: #ccc; - background: rgba(0, 0, 0, 0.3); + +.label-default { + background-color: #999999; } -.dropdown.open .dropdown-menu { - display: block; + +.label-default[href]:hover, +.label-default[href]:focus { + background-color: #808080; } -.typeahead { - margin-top: 2px; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; + +.label-primary { + background-color: #428bca; } -.well { - min-height: 20px; - padding: 19px; - margin-bottom: 20px; - background-color: #f5f5f5; - border: 1px solid #eee; - border: 1px solid rgba(0, 0, 0, 0.05); - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); + +.label-primary[href]:hover, +.label-primary[href]:focus { + background-color: #3071a9; } -.well blockquote { - border-color: #ddd; - border-color: rgba(0, 0, 0, 0.15); + +.label-success { + background-color: #5cb85c; } -.fade { - -webkit-transition: opacity 0.15s linear; - -moz-transition: opacity 0.15s linear; - -ms-transition: opacity 0.15s linear; - -o-transition: opacity 0.15s linear; - transition: opacity 0.15s linear; - opacity: 0; + +.label-success[href]:hover, +.label-success[href]:focus { + background-color: #449d44; } -.fade.in { - opacity: 1; + +.label-info { + background-color: #5bc0de; } -.collapse { - -webkit-transition: height 0.35s ease; - -moz-transition: height 0.35s ease; - -ms-transition: height 0.35s ease; - -o-transition: height 0.35s ease; - transition: height 0.35s ease; - position: relative; - overflow: hidden; - height: 0; + +.label-info[href]:hover, +.label-info[href]:focus { + background-color: #31b0d5; } -.collapse.in { - height: auto; + +.label-warning { + background-color: #f0ad4e; } -.close { - float: right; - font-size: 20px; - font-weight: bold; - line-height: 18px; - color: #000000; - text-shadow: 0 1px 0 #ffffff; - opacity: 0.2; - filter: alpha(opacity=20); + +.label-warning[href]:hover, +.label-warning[href]:focus { + background-color: #ec971f; } -.close:hover { - color: #000000; - text-decoration: none; - opacity: 0.4; - filter: alpha(opacity=40); - cursor: pointer; + +.label-danger { + background-color: #d9534f; } -.btn { + +.label-danger[href]:hover, +.label-danger[href]:focus { + background-color: #c9302c; +} + +.badge { display: inline-block; - padding: 4px 10px 4px; - font-size: 13px; - line-height: 18px; - color: #333333; + min-width: 10px; + padding: 3px 7px; + font-size: 12px; + font-weight: bold; + line-height: 1; + color: #ffffff; text-align: center; - text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75); - background-color: #fafafa; - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), color-stop(25%, #ffffff), to(#e6e6e6)); - background-image: -webkit-linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); - background-image: -moz-linear-gradient(top, #ffffff, #ffffff 25%, #e6e6e6); - background-image: -ms-linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); - background-image: -o-linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); - background-image: linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); - background-repeat: no-repeat; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#e6e6e6', GradientType=0); - border: 1px solid #ccc; - border-bottom-color: #bbb; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - cursor: pointer; - *margin-left: .3em; + white-space: nowrap; + vertical-align: baseline; + background-color: #999999; + border-radius: 10px; } -.btn:first-child { - *margin-left: 0; + +.badge:empty { + display: none; } -.btn:hover { - color: #333333; + +a.badge:hover, +a.badge:focus { + color: #ffffff; text-decoration: none; - background-color: #e6e6e6; - background-position: 0 -15px; - -webkit-transition: background-position 0.1s linear; - -moz-transition: background-position 0.1s linear; - -ms-transition: background-position 0.1s linear; - -o-transition: background-position 0.1s linear; - transition: background-position 0.1s linear; + cursor: pointer; } -.btn:focus { - outline: thin dotted; - outline: 5px auto -webkit-focus-ring-color; - outline-offset: -2px; + +.btn .badge { + position: relative; + top: -1px; } -.btn.active, .btn:active { - background-image: none; - -webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - background-color: #e6e6e6; - background-color: #d9d9d9 \9; - color: rgba(0, 0, 0, 0.5); - outline: 0; + +a.list-group-item.active > .badge, +.nav-pills > .active > a > .badge { + color: #428bca; + background-color: #ffffff; } -.btn.disabled, .btn[disabled] { - cursor: default; - background-image: none; - background-color: #e6e6e6; - opacity: 0.65; - filter: alpha(opacity=65); - -webkit-box-shadow: none; - -moz-box-shadow: none; - box-shadow: none; + +.nav-pills > li > a > .badge { + margin-left: 3px; } -.btn-large { - padding: 9px 14px; - font-size: 15px; - line-height: normal; - -webkit-border-radius: 5px; - -moz-border-radius: 5px; - border-radius: 5px; + +.jumbotron { + padding: 30px; + margin-bottom: 30px; + font-size: 21px; + font-weight: 200; + line-height: 2.1428571435; + color: inherit; + background-color: #eeeeee; } -.btn-large .icon { - margin-top: 1px; + +.jumbotron h1 { + line-height: 1; + color: inherit; } -.btn-small { - padding: 5px 9px; - font-size: 11px; - line-height: 16px; + +.jumbotron p { + line-height: 1.4; } -.btn-small .icon { - margin-top: -1px; + +.container .jumbotron { + border-radius: 6px; } -.btn-primary, -.btn-primary:hover, -.btn-warning, -.btn-warning:hover, -.btn-danger, -.btn-danger:hover, -.btn-success, -.btn-success:hover, -.btn-info, -.btn-info:hover { - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - color: #ffffff; + +@media screen and (min-width: 768px) { + .jumbotron { + padding-top: 48px; + padding-bottom: 48px; + } + .container .jumbotron { + padding-right: 60px; + padding-left: 60px; + } + .jumbotron h1 { + font-size: 63px; + } } -.btn-primary.active, -.btn-warning.active, -.btn-danger.active, -.btn-success.active, -.btn-info.active { - color: rgba(255, 255, 255, 0.75); + +.thumbnail { + display: inline-block; + display: block; + height: auto; + max-width: 100%; + padding: 4px; + line-height: 1.428571429; + background-color: #ffffff; + border: 1px solid #dddddd; + border-radius: 4px; + -webkit-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; } -.btn-primary { - background-color: #006dcc; - background-image: -moz-linear-gradient(top, #0088cc, #0044cc); - background-image: -ms-linear-gradient(top, #0088cc, #0044cc); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc)); - background-image: -webkit-linear-gradient(top, #0088cc, #0044cc); - background-image: -o-linear-gradient(top, #0088cc, #0044cc); - background-image: linear-gradient(top, #0088cc, #0044cc); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0088cc', endColorstr='#0044cc', GradientType=0); - border-color: #0044cc #0044cc #002a80; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); + +.thumbnail > img { + display: block; + height: auto; + max-width: 100%; } -.btn-primary:hover, -.btn-primary:active, -.btn-primary.active, -.btn-primary.disabled, -.btn-primary[disabled] { - background-color: #0044cc; + +a.thumbnail:hover, +a.thumbnail:focus { + border-color: #428bca; +} + +.thumbnail > img { + margin-right: auto; + margin-left: auto; +} + +.thumbnail .caption { + padding: 9px; + color: #333333; } -.btn-primary:active, .btn-primary.active { - background-color: #003399 \9; + +.alert { + padding: 15px; + margin-bottom: 20px; + border: 1px solid transparent; + border-radius: 4px; } -.btn-warning { - background-color: #faa732; - background-image: -moz-linear-gradient(top, #fbb450, #f89406); - background-image: -ms-linear-gradient(top, #fbb450, #f89406); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fbb450), to(#f89406)); - background-image: -webkit-linear-gradient(top, #fbb450, #f89406); - background-image: -o-linear-gradient(top, #fbb450, #f89406); - background-image: linear-gradient(top, #fbb450, #f89406); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fbb450', endColorstr='#f89406', GradientType=0); - border-color: #f89406 #f89406 #ad6704; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); + +.alert h4 { + margin-top: 0; + color: inherit; } -.btn-warning:hover, -.btn-warning:active, -.btn-warning.active, -.btn-warning.disabled, -.btn-warning[disabled] { - background-color: #f89406; + +.alert .alert-link { + font-weight: bold; } -.btn-warning:active, .btn-warning.active { - background-color: #c67605 \9; + +.alert > p, +.alert > ul { + margin-bottom: 0; } -.btn-danger { - background-color: #da4f49; - background-image: -moz-linear-gradient(top, #ee5f5b, #bd362f); - background-image: -ms-linear-gradient(top, #ee5f5b, #bd362f); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#bd362f)); - background-image: -webkit-linear-gradient(top, #ee5f5b, #bd362f); - background-image: -o-linear-gradient(top, #ee5f5b, #bd362f); - background-image: linear-gradient(top, #ee5f5b, #bd362f); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ee5f5b', endColorstr='#bd362f', GradientType=0); - border-color: #bd362f #bd362f #802420; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); + +.alert > p + p { + margin-top: 5px; } -.btn-danger:hover, -.btn-danger:active, -.btn-danger.active, -.btn-danger.disabled, -.btn-danger[disabled] { - background-color: #bd362f; + +.alert-dismissable { + padding-right: 35px; } -.btn-danger:active, .btn-danger.active { - background-color: #942a25 \9; + +.alert-dismissable .close { + position: relative; + top: -2px; + right: -21px; + color: inherit; } -.btn-success { - background-color: #5bb75b; - background-image: -moz-linear-gradient(top, #62c462, #51a351); - background-image: -ms-linear-gradient(top, #62c462, #51a351); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#51a351)); - background-image: -webkit-linear-gradient(top, #62c462, #51a351); - background-image: -o-linear-gradient(top, #62c462, #51a351); - background-image: linear-gradient(top, #62c462, #51a351); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#62c462', endColorstr='#51a351', GradientType=0); - border-color: #51a351 #51a351 #387038; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); + +.alert-success { + color: #468847; + background-color: #dff0d8; + border-color: #d6e9c6; } -.btn-success:hover, -.btn-success:active, -.btn-success.active, -.btn-success.disabled, -.btn-success[disabled] { - background-color: #51a351; + +.alert-success hr { + border-top-color: #c9e2b3; } -.btn-success:active, .btn-success.active { - background-color: #408140 \9; + +.alert-success .alert-link { + color: #356635; } -.btn-info { - background-color: #49afcd; - background-image: -moz-linear-gradient(top, #5bc0de, #2f96b4); - background-image: -ms-linear-gradient(top, #5bc0de, #2f96b4); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#2f96b4)); - background-image: -webkit-linear-gradient(top, #5bc0de, #2f96b4); - background-image: -o-linear-gradient(top, #5bc0de, #2f96b4); - background-image: linear-gradient(top, #5bc0de, #2f96b4); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#5bc0de', endColorstr='#2f96b4', GradientType=0); - border-color: #2f96b4 #2f96b4 #1f6377; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); + +.alert-info { + color: #3a87ad; + background-color: #d9edf7; + border-color: #bce8f1; } -.btn-info:hover, -.btn-info:active, -.btn-info.active, -.btn-info.disabled, -.btn-info[disabled] { - background-color: #2f96b4; + +.alert-info hr { + border-top-color: #a6e1ec; } -.btn-info:active, .btn-info.active { - background-color: #24748c \9; + +.alert-info .alert-link { + color: #2d6987; } -button.btn, input[type="submit"].btn { - *padding-top: 2px; - *padding-bottom: 2px; + +.alert-warning { + color: #c09853; + background-color: #fcf8e3; + border-color: #fbeed5; } -button.btn::-moz-focus-inner, input[type="submit"].btn::-moz-focus-inner { - padding: 0; - border: 0; + +.alert-warning hr { + border-top-color: #f8e5be; } -button.btn.large, input[type="submit"].btn.large { - *padding-top: 7px; - *padding-bottom: 7px; + +.alert-warning .alert-link { + color: #a47e3c; } -button.btn.small, input[type="submit"].btn.small { - *padding-top: 3px; - *padding-bottom: 3px; + +.alert-danger { + color: #b94a48; + background-color: #f2dede; + border-color: #eed3d7; } -.btn-group { - position: relative; - *zoom: 1; - *margin-left: .3em; + +.alert-danger hr { + border-top-color: #e6c1c7; } -.btn-group:before, .btn-group:after { - display: table; - content: ""; + +.alert-danger .alert-link { + color: #953b39; } -.btn-group:after { - clear: both; + +@-webkit-keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } } -.btn-group:first-child { - *margin-left: 0; + +@-moz-keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } } -.btn-group + .btn-group { - margin-left: 5px; + +@-o-keyframes progress-bar-stripes { + from { + background-position: 0 0; + } + to { + background-position: 40px 0; + } } -.btn-toolbar { - margin-top: 9px; - margin-bottom: 9px; + +@keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } } -.btn-toolbar .btn-group { - display: inline-block; - *display: inline; - /* IE7 inline-block hack */ - *zoom: 1; +.progress { + height: 20px; + margin-bottom: 20px; + overflow: hidden; + background-color: #f5f5f5; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); } -.btn-group .btn { - position: relative; + +.progress-bar { float: left; - margin-left: -1px; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; + width: 0; + height: 100%; + font-size: 12px; + color: #ffffff; + text-align: center; + background-color: #428bca; + -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + -webkit-transition: width 0.6s ease; + transition: width 0.6s ease; } -.btn-group .btn:first-child { - margin-left: 0; - -webkit-border-top-left-radius: 4px; - -moz-border-radius-topleft: 4px; - border-top-left-radius: 4px; - -webkit-border-bottom-left-radius: 4px; - -moz-border-radius-bottomleft: 4px; - border-bottom-left-radius: 4px; + +.progress-striped .progress-bar { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-size: 40px 40px; } -.btn-group .btn:last-child, .btn-group .dropdown-toggle { - -webkit-border-top-right-radius: 4px; - -moz-border-radius-topright: 4px; - border-top-right-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - -moz-border-radius-bottomright: 4px; - border-bottom-right-radius: 4px; + +.progress.active .progress-bar { + -webkit-animation: progress-bar-stripes 2s linear infinite; + -moz-animation: progress-bar-stripes 2s linear infinite; + -ms-animation: progress-bar-stripes 2s linear infinite; + -o-animation: progress-bar-stripes 2s linear infinite; + animation: progress-bar-stripes 2s linear infinite; } -.btn-group .btn.large:first-child { - margin-left: 0; - -webkit-border-top-left-radius: 6px; - -moz-border-radius-topleft: 6px; - border-top-left-radius: 6px; - -webkit-border-bottom-left-radius: 6px; - -moz-border-radius-bottomleft: 6px; - border-bottom-left-radius: 6px; + +.progress-bar-success { + background-color: #5cb85c; } -.btn-group .btn.large:last-child, .btn-group .large.dropdown-toggle { - -webkit-border-top-right-radius: 6px; - -moz-border-radius-topright: 6px; - border-top-right-radius: 6px; - -webkit-border-bottom-right-radius: 6px; - -moz-border-radius-bottomright: 6px; - border-bottom-right-radius: 6px; + +.progress-striped .progress-bar-success { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } -.btn-group .btn:hover, -.btn-group .btn:focus, -.btn-group .btn:active, -.btn-group .btn.active { - z-index: 2; + +.progress-bar-info { + background-color: #5bc0de; } -.btn-group .dropdown-toggle:active, .btn-group.open .dropdown-toggle { - outline: 0; + +.progress-striped .progress-bar-info { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } -.btn-group .dropdown-toggle { - padding-left: 8px; - padding-right: 8px; - -webkit-box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - *padding-top: 5px; - *padding-bottom: 5px; + +.progress-bar-warning { + background-color: #f0ad4e; } -.btn-group.open { - *z-index: 1000; + +.progress-striped .progress-bar-warning { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } -.btn-group.open .dropdown-menu { - display: block; - margin-top: 1px; - -webkit-border-radius: 5px; - -moz-border-radius: 5px; - border-radius: 5px; + +.progress-bar-danger { + background-color: #d9534f; } -.btn-group.open .dropdown-toggle { - background-image: none; - -webkit-box-shadow: inset 0 1px 6px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 1px 6px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 1px 6px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); + +.progress-striped .progress-bar-danger { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } -.btn .caret { - margin-top: 7px; - margin-left: 0; + +.media, +.media-body { + overflow: hidden; + zoom: 1; } -.btn:hover .caret, .open.btn-group .caret { - opacity: 1; - filter: alpha(opacity=100); + +.media, +.media .media { + margin-top: 15px; } -.btn-primary .caret, -.btn-danger .caret, -.btn-info .caret, -.btn-success .caret { - border-top-color: #ffffff; - opacity: 0.75; - filter: alpha(opacity=75); + +.media:first-child { + margin-top: 0; } -.btn-small .caret { - margin-top: 4px; + +.media-object { + display: block; } -.alert { - padding: 8px 35px 8px 14px; - margin-bottom: 18px; - text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); - background-color: #fcf8e3; - border: 1px solid #fbeed5; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; + +.media-heading { + margin: 0 0 5px; } -.alert, .alert-heading { - color: #c09853; + +.media > .pull-left { + margin-right: 10px; } -.alert .close { - position: relative; - top: -2px; - right: -21px; - line-height: 18px; + +.media > .pull-right { + margin-left: 10px; } -.alert-success { - background-color: #dff0d8; - border-color: #d6e9c6; + +.media-list { + padding-left: 0; + list-style: none; } -.alert-success, .alert-success .alert-heading { - color: #468847; + +.list-group { + padding-left: 0; + margin-bottom: 20px; } -.alert-danger, .alert-error { - background-color: #f2dede; - border-color: #eed3d7; + +.list-group-item { + position: relative; + display: block; + padding: 10px 15px; + margin-bottom: -1px; + background-color: #ffffff; + border: 1px solid #dddddd; } -.alert-danger, -.alert-error, -.alert-danger .alert-heading, -.alert-error .alert-heading { - color: #b94a48; + +.list-group-item:first-child { + border-top-right-radius: 4px; + border-top-left-radius: 4px; } -.alert-info { - background-color: #d9edf7; - border-color: #bce8f1; + +.list-group-item:last-child { + margin-bottom: 0; + border-bottom-right-radius: 4px; + border-bottom-left-radius: 4px; } -.alert-info, .alert-info .alert-heading { - color: #3a87ad; + +.list-group-item > .badge { + float: right; } -.alert-block { - padding-top: 14px; - padding-bottom: 14px; + +.list-group-item > .badge + .badge { + margin-right: 5px; } -.alert-block > p, .alert-block > ul { - margin-bottom: 0; + +a.list-group-item { + color: #555555; } -.alert-block p + p { - margin-top: 5px; + +a.list-group-item .list-group-item-heading { + color: #333333; } -.nav { - margin-left: 0; - margin-bottom: 18px; - list-style: none; + +a.list-group-item:hover, +a.list-group-item:focus { + text-decoration: none; + background-color: #f5f5f5; } -.nav > li > a { - display: block; + +.list-group-item.active, +.list-group-item.active:hover, +.list-group-item.active:focus { + z-index: 2; + color: #ffffff; + background-color: #428bca; + border-color: #428bca; } -.nav > li > a:hover { - text-decoration: none; - background-color: #eeeeee; + +.list-group-item.active .list-group-item-heading, +.list-group-item.active:hover .list-group-item-heading, +.list-group-item.active:focus .list-group-item-heading { + color: inherit; } -.nav-list { - padding-left: 14px; - padding-right: 14px; - margin-bottom: 0; + +.list-group-item.active .list-group-item-text, +.list-group-item.active:hover .list-group-item-text, +.list-group-item.active:focus .list-group-item-text { + color: #e1edf7; } -.nav-list > li > a, .nav-list .nav-header { - display: block; - padding: 3px 15px; - margin-left: -15px; - margin-right: -15px; - text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); + +.list-group-item-heading { + margin-top: 0; + margin-bottom: 5px; } -.nav-list .nav-header { - font-size: 11px; - font-weight: bold; - line-height: 18px; - color: #999999; - text-transform: uppercase; + +.list-group-item-text { + margin-bottom: 0; + line-height: 1.3; } -.nav-list > li + .nav-header { - margin-top: 9px; + +.panel { + margin-bottom: 20px; + background-color: #ffffff; + border: 1px solid transparent; + border-radius: 4px; + -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05); } -.nav-list .active > a { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.2); - background-color: #0088cc; + +.panel-body { + padding: 15px; } -.nav-list .icon { - margin-right: 2px; + +.panel-body:before, +.panel-body:after { + display: table; + content: " "; } -.nav-tabs, .nav-pills { - *zoom: 1; + +.panel-body:after { + clear: both; } -.nav-tabs:before, -.nav-pills:before, -.nav-tabs:after, -.nav-pills:after { + +.panel-body:before, +.panel-body:after { display: table; - content: ""; + content: " "; } -.nav-tabs:after, .nav-pills:after { + +.panel-body:after { clear: both; } -.nav-tabs > li, .nav-pills > li { - float: left; + +.panel > .list-group { + margin-bottom: 0; } -.nav-tabs > li > a, .nav-pills > li > a { - padding-right: 12px; - padding-left: 12px; - margin-right: 2px; - line-height: 14px; + +.panel > .list-group .list-group-item { + border-width: 1px 0; } -.nav-tabs { - border-bottom: 1px solid #ddd; + +.panel > .list-group .list-group-item:first-child { + border-top-right-radius: 0; + border-top-left-radius: 0; } -.nav-tabs > li { - margin-bottom: -1px; + +.panel > .list-group .list-group-item:last-child { + border-bottom: 0; } -.nav-tabs > li > a { - padding-top: 9px; - padding-bottom: 9px; - border: 1px solid transparent; - -webkit-border-radius: 4px 4px 0 0; - -moz-border-radius: 4px 4px 0 0; - border-radius: 4px 4px 0 0; + +.panel-heading + .list-group .list-group-item:first-child { + border-top-width: 0; } -.nav-tabs > li > a:hover { - border-color: #eeeeee #eeeeee #dddddd; + +.panel > .table { + margin-bottom: 0; } -.nav-tabs > .active > a, .nav-tabs > .active > a:hover { - color: #555555; - background-color: #ffffff; - border: 1px solid #ddd; - border-bottom-color: transparent; - cursor: default; + +.panel > .panel-body + .table { + border-top: 1px solid #dddddd; } -.nav-pills > li > a { - padding-top: 8px; - padding-bottom: 8px; - margin-top: 2px; - margin-bottom: 2px; - -webkit-border-radius: 5px; - -moz-border-radius: 5px; - border-radius: 5px; + +.panel-heading { + padding: 10px 15px; + border-bottom: 1px solid transparent; + border-top-right-radius: 3px; + border-top-left-radius: 3px; } -.nav-pills .active > a, .nav-pills .active > a:hover { - color: #ffffff; - background-color: #0088cc; + +.panel-title { + margin-top: 0; + margin-bottom: 0; + font-size: 16px; } -.nav-stacked > li { - float: none; + +.panel-title > a { + color: inherit; } -.nav-stacked > li > a { - margin-right: 0; + +.panel-footer { + padding: 10px 15px; + background-color: #f5f5f5; + border-top: 1px solid #dddddd; + border-bottom-right-radius: 3px; + border-bottom-left-radius: 3px; } -.nav-tabs.nav-stacked { - border-bottom: 0; + +.panel-group .panel { + margin-bottom: 0; + overflow: hidden; + border-radius: 4px; } -.nav-tabs.nav-stacked > li > a { - border: 1px solid #ddd; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; + +.panel-group .panel + .panel { + margin-top: 5px; } -.nav-tabs.nav-stacked > li:first-child > a { - -webkit-border-radius: 4px 4px 0 0; - -moz-border-radius: 4px 4px 0 0; - border-radius: 4px 4px 0 0; + +.panel-group .panel-heading { + border-bottom: 0; } -.nav-tabs.nav-stacked > li:last-child > a { - -webkit-border-radius: 0 0 4px 4px; - -moz-border-radius: 0 0 4px 4px; - border-radius: 0 0 4px 4px; + +.panel-group .panel-heading + .panel-collapse .panel-body { + border-top: 1px solid #dddddd; } -.nav-tabs.nav-stacked > li > a:hover { - border-color: #ddd; - z-index: 2; + +.panel-group .panel-footer { + border-top: 0; } -.nav-pills.nav-stacked > li > a { - margin-bottom: 3px; + +.panel-group .panel-footer + .panel-collapse .panel-body { + border-bottom: 1px solid #dddddd; } -.nav-pills.nav-stacked > li:last-child > a { - margin-bottom: 1px; + +.panel-default { + border-color: #dddddd; } -.nav-tabs .dropdown-menu, .nav-pills .dropdown-menu { - margin-top: 1px; - border-width: 1px; + +.panel-default > .panel-heading { + color: #333333; + background-color: #f5f5f5; + border-color: #dddddd; } -.nav-pills .dropdown-menu { - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; + +.panel-default > .panel-heading + .panel-collapse .panel-body { + border-top-color: #dddddd; } -.nav-tabs .dropdown-toggle .caret, .nav-pills .dropdown-toggle .caret { - border-top-color: #0088cc; - margin-top: 6px; + +.panel-default > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: #dddddd; } -.nav-tabs .dropdown-toggle:hover .caret, .nav-pills .dropdown-toggle:hover .caret { - border-top-color: #005580; + +.panel-primary { + border-color: #428bca; } -.nav-tabs .active .dropdown-toggle .caret, .nav-pills .active .dropdown-toggle .caret { - border-top-color: #333333; + +.panel-primary > .panel-heading { + color: #ffffff; + background-color: #428bca; + border-color: #428bca; } -.nav > .dropdown.active > a:hover { - color: #000000; - cursor: pointer; + +.panel-primary > .panel-heading + .panel-collapse .panel-body { + border-top-color: #428bca; } -.nav-tabs .open .dropdown-toggle, .nav-pills .open .dropdown-toggle, .nav > .open.active > a:hover { - color: #ffffff; - background-color: #999999; - border-color: #999999; + +.panel-primary > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: #428bca; } -.nav .open .caret, .nav .open.active .caret, .nav .open a:hover .caret { - border-top-color: #ffffff; - opacity: 1; - filter: alpha(opacity=100); + +.panel-success { + border-color: #d6e9c6; } -.tabs-stacked .open > a:hover { - border-color: #999999; + +.panel-success > .panel-heading { + color: #468847; + background-color: #dff0d8; + border-color: #d6e9c6; } -.tabbable { - *zoom: 1; + +.panel-success > .panel-heading + .panel-collapse .panel-body { + border-top-color: #d6e9c6; } -.tabbable:before, .tabbable:after { - display: table; - content: ""; + +.panel-success > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: #d6e9c6; } -.tabbable:after { - clear: both; + +.panel-warning { + border-color: #fbeed5; } -.tabs-below .nav-tabs, .tabs-right .nav-tabs, .tabs-left .nav-tabs { - border-bottom: 0; + +.panel-warning > .panel-heading { + color: #c09853; + background-color: #fcf8e3; + border-color: #fbeed5; } -.tab-content > .tab-pane, .pill-content > .pill-pane { - display: none; + +.panel-warning > .panel-heading + .panel-collapse .panel-body { + border-top-color: #fbeed5; } -.tab-content > .active, .pill-content > .active { - display: block; + +.panel-warning > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: #fbeed5; } -.tabs-below .nav-tabs { - border-top: 1px solid #ddd; + +.panel-danger { + border-color: #eed3d7; } -.tabs-below .nav-tabs > li { - margin-top: -1px; - margin-bottom: 0; + +.panel-danger > .panel-heading { + color: #b94a48; + background-color: #f2dede; + border-color: #eed3d7; } -.tabs-below .nav-tabs > li > a { - -webkit-border-radius: 0 0 4px 4px; - -moz-border-radius: 0 0 4px 4px; - border-radius: 0 0 4px 4px; + +.panel-danger > .panel-heading + .panel-collapse .panel-body { + border-top-color: #eed3d7; } -.tabs-below .nav-tabs > li > a:hover { - border-bottom-color: transparent; - border-top-color: #ddd; + +.panel-danger > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: #eed3d7; } -.tabs-below .nav-tabs .active > a, .tabs-below .nav-tabs .active > a:hover { - border-color: transparent #ddd #ddd #ddd; + +.panel-info { + border-color: #bce8f1; } -.tabs-left .nav-tabs > li, .tabs-right .nav-tabs > li { - float: none; + +.panel-info > .panel-heading { + color: #3a87ad; + background-color: #d9edf7; + border-color: #bce8f1; } -.tabs-left .nav-tabs > li > a, .tabs-right .nav-tabs > li > a { - min-width: 74px; - margin-right: 0; - margin-bottom: 3px; + +.panel-info > .panel-heading + .panel-collapse .panel-body { + border-top-color: #bce8f1; } -.tabs-left .nav-tabs { - float: left; - margin-right: 19px; - border-right: 1px solid #ddd; + +.panel-info > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: #bce8f1; +} + +.well { + min-height: 20px; + padding: 19px; + margin-bottom: 20px; + background-color: #f5f5f5; + border: 1px solid #e3e3e3; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); } -.tabs-left .nav-tabs > li > a { - margin-right: -1px; - -webkit-border-radius: 4px 0 0 4px; - -moz-border-radius: 4px 0 0 4px; - border-radius: 4px 0 0 4px; + +.well blockquote { + border-color: #ddd; + border-color: rgba(0, 0, 0, 0.15); } -.tabs-left .nav-tabs > li > a:hover { - border-color: #eeeeee #dddddd #eeeeee #eeeeee; + +.well-lg { + padding: 24px; + border-radius: 6px; } -.tabs-left .nav-tabs .active > a, .tabs-left .nav-tabs .active > a:hover { - border-color: #ddd transparent #ddd #ddd; - *border-right-color: #ffffff; + +.well-sm { + padding: 9px; + border-radius: 3px; } -.tabs-right .nav-tabs { + +.close { float: right; - margin-left: 19px; - border-left: 1px solid #ddd; -} -.tabs-right .nav-tabs > li > a { - margin-left: -1px; - -webkit-border-radius: 0 4px 4px 0; - -moz-border-radius: 0 4px 4px 0; - border-radius: 0 4px 4px 0; + font-size: 21px; + font-weight: bold; + line-height: 1; + color: #000000; + text-shadow: 0 1px 0 #ffffff; + opacity: 0.2; + filter: alpha(opacity=20); } -.tabs-right .nav-tabs > li > a:hover { - border-color: #eeeeee #eeeeee #eeeeee #dddddd; + +.close:hover, +.close:focus { + color: #000000; + text-decoration: none; + cursor: pointer; + opacity: 0.5; + filter: alpha(opacity=50); } -.tabs-right .nav-tabs .active > a, .tabs-right .nav-tabs .active > a:hover { - border-color: #ddd #ddd #ddd transparent; - *border-left-color: #ffffff; + +button.close { + padding: 0; + cursor: pointer; + background: transparent; + border: 0; + -webkit-appearance: none; } -.navbar { - overflow: visible; - margin-bottom: 18px; + +.modal-open { + overflow: hidden; } -.navbar-inner { - padding-left: 20px; - padding-right: 20px; - background-color: #2c2c2c; - background-image: -moz-linear-gradient(top, #333333, #222222); - background-image: -ms-linear-gradient(top, #333333, #222222); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#333333), to(#222222)); - background-image: -webkit-linear-gradient(top, #333333, #222222); - background-image: -o-linear-gradient(top, #333333, #222222); - background-image: linear-gradient(top, #333333, #222222); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#333333', endColorstr='#222222', GradientType=0); - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25), inset 0 -1px 0 rgba(0, 0, 0, 0.1); - -moz-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25), inset 0 -1px 0 rgba(0, 0, 0, 0.1); - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25), inset 0 -1px 0 rgba(0, 0, 0, 0.1); + +body.modal-open, +.modal-open .navbar-fixed-top, +.modal-open .navbar-fixed-bottom { + margin-right: 15px; } -.btn-navbar { + +.modal { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 1040; display: none; - float: right; - padding: 7px 10px; - margin-left: 5px; - margin-right: 5px; - background-color: #2c2c2c; - background-image: -moz-linear-gradient(top, #333333, #222222); - background-image: -ms-linear-gradient(top, #333333, #222222); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#333333), to(#222222)); - background-image: -webkit-linear-gradient(top, #333333, #222222); - background-image: -o-linear-gradient(top, #333333, #222222); - background-image: linear-gradient(top, #333333, #222222); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#333333', endColorstr='#222222', GradientType=0); - border-color: #222222 #222222 #000000; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); - -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); - -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); - box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); -} -.btn-navbar:hover, -.btn-navbar:active, -.btn-navbar.active, -.btn-navbar.disabled, -.btn-navbar[disabled] { - background-color: #222222; + overflow: auto; + overflow-y: scroll; } -.btn-navbar:active, .btn-navbar.active { - background-color: #080808 \9; + +.modal.fade .modal-dialog { + -webkit-transform: translate(0, -25%); + -ms-transform: translate(0, -25%); + transform: translate(0, -25%); + -webkit-transition: -webkit-transform 0.3s ease-out; + -moz-transition: -moz-transform 0.3s ease-out; + -o-transition: -o-transform 0.3s ease-out; + transition: transform 0.3s ease-out; } -.btn-navbar .icon-bar { - display: block; - width: 18px; - height: 2px; - background-color: #f5f5f5; - -webkit-border-radius: 1px; - -moz-border-radius: 1px; - border-radius: 1px; - -webkit-box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); - -moz-box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); - box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); + +.modal.in .modal-dialog { + -webkit-transform: translate(0, 0); + -ms-transform: translate(0, 0); + transform: translate(0, 0); } -.btn-navbar .icon-bar + .icon-bar { - margin-top: 3px; + +.modal-dialog { + z-index: 1050; + width: auto; + padding: 10px; + margin-right: auto; + margin-left: auto; } -.nav-collapse.collapse { - height: auto; + +.modal-content { + position: relative; + background-color: #ffffff; + border: 1px solid #999999; + border: 1px solid rgba(0, 0, 0, 0.2); + border-radius: 6px; + outline: none; + -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); + box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); + background-clip: padding-box; } -.navbar .brand:hover { - text-decoration: none; + +.modal-backdrop { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 1030; + background-color: #000000; } -.navbar .brand { - float: left; - display: block; - padding: 8px 20px 12px; - margin-left: -20px; - font-size: 20px; - font-weight: 200; - line-height: 1; - color: #ffffff; + +.modal-backdrop.fade { + opacity: 0; + filter: alpha(opacity=0); } -.navbar .navbar-text { - margin-bottom: 0; - line-height: 40px; - color: #999999; + +.modal-backdrop.in { + opacity: 0.5; + filter: alpha(opacity=50); } -.navbar .navbar-text a:hover { - color: #ffffff; - background-color: transparent; + +.modal-header { + min-height: 16.428571429px; + padding: 15px; + border-bottom: 1px solid #e5e5e5; } -.navbar .btn, .navbar .btn-group { - margin-top: 5px; + +.modal-header .close { + margin-top: -2px; } -.navbar .btn-group .btn { - margin-top: 0; + +.modal-title { + margin: 0; + line-height: 1.428571429; +} + +.modal-body { + position: relative; + padding: 20px; } -.navbar-form { - margin-bottom: 0; - *zoom: 1; + +.modal-footer { + padding: 19px 20px 20px; + margin-top: 15px; + text-align: right; + border-top: 1px solid #e5e5e5; } -.navbar-form:before, .navbar-form:after { + +.modal-footer:before, +.modal-footer:after { display: table; - content: ""; + content: " "; } -.navbar-form:after { + +.modal-footer:after { clear: both; } -.navbar-form input, .navbar-form select { - display: inline-block; - margin-top: 5px; - margin-bottom: 0; -} -.navbar-form .radio, .navbar-form .checkbox { - margin-top: 5px; + +.modal-footer:before, +.modal-footer:after { + display: table; + content: " "; } -.navbar-form input[type="image"], .navbar-form input[type="checkbox"], .navbar-form input[type="radio"] { - margin-top: 3px; + +.modal-footer:after { + clear: both; } -.navbar-search { - position: relative; - float: left; - margin-top: 6px; + +.modal-footer .btn + .btn { margin-bottom: 0; + margin-left: 5px; } -.navbar-search .search-query { - padding: 4px 9px; - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; - font-size: 13px; - font-weight: normal; - line-height: 1; - color: #ffffff; - color: rgba(255, 255, 255, 0.75); - background: #666; - background: rgba(255, 255, 255, 0.3); - border: 1px solid #111; - -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0px rgba(255, 255, 255, 0.15); - -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0px rgba(255, 255, 255, 0.15); - box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0px rgba(255, 255, 255, 0.15); - -webkit-transition: none; - -moz-transition: none; - -ms-transition: none; - -o-transition: none; - transition: none; -} -.navbar-search .search-query :-moz-placeholder { - color: #eeeeee; -} -.navbar-search .search-query::-webkit-input-placeholder { - color: #eeeeee; -} -.navbar-search .search-query:hover { - color: #ffffff; - background-color: #999999; - background-color: rgba(255, 255, 255, 0.5); -} -.navbar-search .search-query:focus, .navbar-search .search-query.focused { - padding: 5px 10px; - color: #333333; - text-shadow: 0 1px 0 #ffffff; - background-color: #ffffff; - border: 0; - -webkit-box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); - -moz-box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); - box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); - outline: 0; + +.modal-footer .btn-group .btn + .btn { + margin-left: -1px; } -.navbar-fixed-top { - position: fixed; - top: 0; - right: 0; - left: 0; - z-index: 1030; + +.modal-footer .btn-block + .btn-block { + margin-left: 0; } -.navbar-fixed-top .navbar-inner { - padding-left: 0; - padding-right: 0; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; + +@media screen and (min-width: 768px) { + .modal-dialog { + right: auto; + left: 50%; + width: 600px; + padding-top: 30px; + padding-bottom: 30px; + } + .modal-content { + -webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); + box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); + } } -.navbar .nav { - position: relative; - left: 0; + +.tooltip { + position: absolute; + z-index: 1030; display: block; - float: left; - margin: 0 10px 0 0; + font-size: 12px; + line-height: 1.4; + opacity: 0; + filter: alpha(opacity=0); + visibility: visible; } -.navbar .nav.pull-right { - float: right; + +.tooltip.in { + opacity: 0.9; + filter: alpha(opacity=90); } -.navbar .nav > li { - display: block; - float: left; + +.tooltip.top { + padding: 5px 0; + margin-top: -3px; } -.navbar .nav > li > a { - float: none; - padding: 10px 10px 11px; - line-height: 19px; - color: #999999; - text-decoration: none; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + +.tooltip.right { + padding: 0 5px; + margin-left: 3px; } -.navbar .nav > li > a:hover { - background-color: transparent; - color: #ffffff; - text-decoration: none; + +.tooltip.bottom { + padding: 5px 0; + margin-top: 3px; +} + +.tooltip.left { + padding: 0 5px; + margin-left: -3px; } -.navbar .nav .active > a, .navbar .nav .active > a:hover { + +.tooltip-inner { + max-width: 200px; + padding: 3px 8px; color: #ffffff; + text-align: center; text-decoration: none; - background-color: #222222; - background-color: rgba(0, 0, 0, 0.5); + background-color: #000000; + border-radius: 4px; } -.navbar .divider-vertical { - height: 40px; - width: 1px; - margin: 0 9px; - overflow: hidden; - background-color: #222222; - border-right: 1px solid #333333; + +.tooltip-arrow { + position: absolute; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; } -.navbar .nav.pull-right { - margin-left: 10px; - margin-right: 0; + +.tooltip.top .tooltip-arrow { + bottom: 0; + left: 50%; + margin-left: -5px; + border-top-color: #000000; + border-width: 5px 5px 0; } -.navbar .dropdown-menu { - margin-top: 1px; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; + +.tooltip.top-left .tooltip-arrow { + bottom: 0; + left: 5px; + border-top-color: #000000; + border-width: 5px 5px 0; } -.navbar .dropdown-menu:before { - content: ''; - display: inline-block; - border-left: 7px solid transparent; - border-right: 7px solid transparent; - border-bottom: 7px solid #ccc; - border-bottom-color: rgba(0, 0, 0, 0.2); - position: absolute; - top: -7px; - left: 9px; + +.tooltip.top-right .tooltip-arrow { + right: 5px; + bottom: 0; + border-top-color: #000000; + border-width: 5px 5px 0; } -.navbar .dropdown-menu:after { - content: ''; - display: inline-block; - border-left: 6px solid transparent; - border-right: 6px solid transparent; - border-bottom: 6px solid #ffffff; - position: absolute; - top: -6px; - left: 10px; + +.tooltip.right .tooltip-arrow { + top: 50%; + left: 0; + margin-top: -5px; + border-right-color: #000000; + border-width: 5px 5px 5px 0; } -.navbar .nav .dropdown-toggle .caret, .navbar .nav .open.dropdown .caret { - border-top-color: #ffffff; + +.tooltip.left .tooltip-arrow { + top: 50%; + right: 0; + margin-top: -5px; + border-left-color: #000000; + border-width: 5px 0 5px 5px; } -.navbar .nav .active .caret { - opacity: 1; - filter: alpha(opacity=100); + +.tooltip.bottom .tooltip-arrow { + top: 0; + left: 50%; + margin-left: -5px; + border-bottom-color: #000000; + border-width: 0 5px 5px; } -.navbar .nav .open > .dropdown-toggle, .navbar .nav .active > .dropdown-toggle, .navbar .nav .open.active > .dropdown-toggle { - background-color: transparent; + +.tooltip.bottom-left .tooltip-arrow { + top: 0; + left: 5px; + border-bottom-color: #000000; + border-width: 0 5px 5px; } -.navbar .nav .active > .dropdown-toggle:hover { - color: #ffffff; + +.tooltip.bottom-right .tooltip-arrow { + top: 0; + right: 5px; + border-bottom-color: #000000; + border-width: 0 5px 5px; } -.navbar .nav.pull-right .dropdown-menu { - left: auto; - right: 0; + +.popover { + position: absolute; + top: 0; + left: 0; + z-index: 1010; + display: none; + max-width: 276px; + padding: 1px; + text-align: left; + white-space: normal; + background-color: #ffffff; + border: 1px solid #cccccc; + border: 1px solid rgba(0, 0, 0, 0.2); + border-radius: 6px; + -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + background-clip: padding-box; } -.navbar .nav.pull-right .dropdown-menu:before { - left: auto; - right: 12px; + +.popover.top { + margin-top: -10px; } -.navbar .nav.pull-right .dropdown-menu:after { - left: auto; - right: 13px; + +.popover.right { + margin-left: 10px; } -.breadcrumb { - padding: 7px 14px; - margin: 0 0 18px; - background-color: #fbfbfb; - background-image: -moz-linear-gradient(top, #ffffff, #f5f5f5); - background-image: -ms-linear-gradient(top, #ffffff, #f5f5f5); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#f5f5f5)); - background-image: -webkit-linear-gradient(top, #ffffff, #f5f5f5); - background-image: -o-linear-gradient(top, #ffffff, #f5f5f5); - background-image: linear-gradient(top, #ffffff, #f5f5f5); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#f5f5f5', GradientType=0); - border: 1px solid #ddd; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; - -webkit-box-shadow: inset 0 1px 0 #ffffff; - -moz-box-shadow: inset 0 1px 0 #ffffff; - box-shadow: inset 0 1px 0 #ffffff; + +.popover.bottom { + margin-top: 10px; } -.breadcrumb li { - display: inline; - text-shadow: 0 1px 0 #ffffff; + +.popover.left { + margin-left: -10px; } -.breadcrumb .divider { - padding: 0 5px; - color: #999999; + +.popover-title { + padding: 8px 14px; + margin: 0; + font-size: 14px; + font-weight: normal; + line-height: 18px; + background-color: #f7f7f7; + border-bottom: 1px solid #ebebeb; + border-radius: 5px 5px 0 0; } -.breadcrumb .active a { - color: #333333; + +.popover-content { + padding: 9px 14px; } -.pagination { - height: 36px; - margin: 18px 0; + +.popover .arrow, +.popover .arrow:after { + position: absolute; + display: block; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; } -.pagination ul { - display: inline-block; - *display: inline; - /* IE7 inline-block hack */ - *zoom: 1; - margin-left: 0; - margin-bottom: 0; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; - -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); +.popover .arrow { + border-width: 11px; } -.pagination li { - display: inline; + +.popover .arrow:after { + border-width: 10px; + content: ""; } -.pagination a { - float: left; - padding: 0 14px; - line-height: 34px; - text-decoration: none; - border: 1px solid #ddd; - border-left-width: 0; + +.popover.top .arrow { + bottom: -11px; + left: 50%; + margin-left: -11px; + border-top-color: #999999; + border-top-color: rgba(0, 0, 0, 0.25); + border-bottom-width: 0; } -.pagination a:hover, .pagination .active a { - background-color: #f5f5f5; + +.popover.top .arrow:after { + bottom: 1px; + margin-left: -10px; + border-top-color: #ffffff; + border-bottom-width: 0; + content: " "; } -.pagination .active a { - color: #999999; - cursor: default; + +.popover.right .arrow { + top: 50%; + left: -11px; + margin-top: -11px; + border-right-color: #999999; + border-right-color: rgba(0, 0, 0, 0.25); + border-left-width: 0; } -.pagination .disabled a, .pagination .disabled a:hover { - color: #999999; - background-color: transparent; - cursor: default; + +.popover.right .arrow:after { + bottom: -10px; + left: 1px; + border-right-color: #ffffff; + border-left-width: 0; + content: " "; } -.pagination li:first-child a { - border-left-width: 1px; - -webkit-border-radius: 3px 0 0 3px; - -moz-border-radius: 3px 0 0 3px; - border-radius: 3px 0 0 3px; + +.popover.bottom .arrow { + top: -11px; + left: 50%; + margin-left: -11px; + border-bottom-color: #999999; + border-bottom-color: rgba(0, 0, 0, 0.25); + border-top-width: 0; } -.pagination li:last-child a { - -webkit-border-radius: 0 3px 3px 0; - -moz-border-radius: 0 3px 3px 0; - border-radius: 0 3px 3px 0; + +.popover.bottom .arrow:after { + top: 1px; + margin-left: -10px; + border-bottom-color: #ffffff; + border-top-width: 0; + content: " "; } -.pagination-centered { - text-align: center; + +.popover.left .arrow { + top: 50%; + right: -11px; + margin-top: -11px; + border-left-color: #999999; + border-left-color: rgba(0, 0, 0, 0.25); + border-right-width: 0; } -.pagination-right { - text-align: right; + +.popover.left .arrow:after { + right: 1px; + bottom: -10px; + border-left-color: #ffffff; + border-right-width: 0; + content: " "; } -.pager { - margin-left: 0; - margin-bottom: 18px; - list-style: none; - text-align: center; - *zoom: 1; + +.carousel { + position: relative; } -.pager:before, .pager:after { - display: table; - content: ""; + +.carousel-inner { + position: relative; + width: 100%; + overflow: hidden; } -.pager:after { - clear: both; + +.carousel-inner > .item { + position: relative; + display: none; + -webkit-transition: 0.6s ease-in-out left; + transition: 0.6s ease-in-out left; } -.pager li { - display: inline; + +.carousel-inner > .item > img, +.carousel-inner > .item > a > img { + display: block; + height: auto; + max-width: 100%; + line-height: 1; } -.pager a { - display: inline-block; - padding: 5px 14px; - background-color: #fff; - border: 1px solid #ddd; - -webkit-border-radius: 15px; - -moz-border-radius: 15px; - border-radius: 15px; + +.carousel-inner > .active, +.carousel-inner > .next, +.carousel-inner > .prev { + display: block; } -.pager a:hover { - text-decoration: none; - background-color: #f5f5f5; + +.carousel-inner > .active { + left: 0; } -.pager .next a { - float: right; + +.carousel-inner > .next, +.carousel-inner > .prev { + position: absolute; + top: 0; + width: 100%; } -.pager .previous a { - float: left; + +.carousel-inner > .next { + left: 100%; } -.modal-open .dropdown-menu { - z-index: 2050; + +.carousel-inner > .prev { + left: -100%; } -.modal-open .dropdown.open { - *z-index: 2050; + +.carousel-inner > .next.left, +.carousel-inner > .prev.right { + left: 0; } -.modal-open .popover { - z-index: 2060; + +.carousel-inner > .active.left { + left: -100%; } -.modal-open .tooltip { - z-index: 2070; + +.carousel-inner > .active.right { + left: 100%; } -.modal-backdrop { - position: fixed; + +.carousel-control { + position: absolute; top: 0; - right: 0; bottom: 0; left: 0; - z-index: 1040; - background-color: #000000; -} -.modal-backdrop.fade { - opacity: 0; + width: 15%; + font-size: 20px; + color: #ffffff; + text-align: center; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); + opacity: 0.5; + filter: alpha(opacity=50); } -.modal-backdrop, .modal-backdrop.fade.in { - opacity: 0.8; - filter: alpha(opacity=80); + +.carousel-control.left { + background-image: -webkit-gradient(linear, 0 top, 100% top, from(rgba(0, 0, 0, 0.5)), to(rgba(0, 0, 0, 0.0001))); + background-image: -webkit-linear-gradient(left, color-stop(rgba(0, 0, 0, 0.5) 0), color-stop(rgba(0, 0, 0, 0.0001) 100%)); + background-image: -moz-linear-gradient(left, rgba(0, 0, 0, 0.5) 0, rgba(0, 0, 0, 0.0001) 100%); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.5) 0, rgba(0, 0, 0, 0.0001) 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1); } -.modal { - position: fixed; - top: 50%; - left: 50%; - z-index: 1050; - max-height: 500px; - overflow: auto; - width: 560px; - margin: -250px 0 0 -280px; - background-color: #ffffff; - border: 1px solid #999; - border: 1px solid rgba(0, 0, 0, 0.3); - *border: 1px solid #999; - /* IE6-7 */ - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; - -webkit-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - -moz-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - -webkit-background-clip: padding-box; - -moz-background-clip: padding-box; - background-clip: padding-box; +.carousel-control.right { + right: 0; + left: auto; + background-image: -webkit-gradient(linear, 0 top, 100% top, from(rgba(0, 0, 0, 0.0001)), to(rgba(0, 0, 0, 0.5))); + background-image: -webkit-linear-gradient(left, color-stop(rgba(0, 0, 0, 0.0001) 0), color-stop(rgba(0, 0, 0, 0.5) 100%)); + background-image: -moz-linear-gradient(left, rgba(0, 0, 0, 0.0001) 0, rgba(0, 0, 0, 0.5) 100%); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.0001) 0, rgba(0, 0, 0, 0.5) 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1); } -.modal.fade { - -webkit-transition: opacity .3s linear, top .3s ease-out; - -moz-transition: opacity .3s linear, top .3s ease-out; - -ms-transition: opacity .3s linear, top .3s ease-out; - -o-transition: opacity .3s linear, top .3s ease-out; - transition: opacity .3s linear, top .3s ease-out; - top: -25%; + +.carousel-control:hover, +.carousel-control:focus { + color: #ffffff; + text-decoration: none; + opacity: 0.9; + filter: alpha(opacity=90); } -.modal.fade.in { + +.carousel-control .icon-prev, +.carousel-control .icon-next, +.carousel-control .glyphicon-chevron-left, +.carousel-control .glyphicon-chevron-right { + position: absolute; top: 50%; + left: 50%; + z-index: 5; + display: inline-block; } -.modal-header { - padding: 9px 15px; - border-bottom: 1px solid #eee; + +.carousel-control .icon-prev, +.carousel-control .icon-next { + width: 20px; + height: 20px; + margin-top: -10px; + margin-left: -10px; + font-family: serif; } -.modal-header .close { - margin-top: 2px; + +.carousel-control .icon-prev:before { + content: '\2039'; } -.modal-body { - padding: 15px; + +.carousel-control .icon-next:before { + content: '\203a'; } -.modal-footer { - padding: 14px 15px 15px; - margin-bottom: 0; - background-color: #f5f5f5; - border-top: 1px solid #ddd; - -webkit-border-radius: 0 0 6px 6px; - -moz-border-radius: 0 0 6px 6px; - border-radius: 0 0 6px 6px; - -webkit-box-shadow: inset 0 1px 0 #ffffff; - -moz-box-shadow: inset 0 1px 0 #ffffff; - box-shadow: inset 0 1px 0 #ffffff; - *zoom: 1; -} -.modal-footer:before, .modal-footer:after { - display: table; - content: ""; + +.carousel-indicators { + position: absolute; + bottom: 10px; + left: 50%; + z-index: 15; + width: 60%; + padding-left: 0; + margin-left: -30%; + text-align: center; + list-style: none; } -.modal-footer:after { - clear: both; + +.carousel-indicators li { + display: inline-block; + width: 10px; + height: 10px; + margin: 1px; + text-indent: -999px; + cursor: pointer; + border: 1px solid #ffffff; + border-radius: 10px; } -.modal-footer .btn { - float: right; - margin-left: 5px; - margin-bottom: 0; + +.carousel-indicators .active { + width: 12px; + height: 12px; + margin: 0; + background-color: #ffffff; } -.tooltip { + +.carousel-caption { position: absolute; - z-index: 1020; - display: block; - visibility: visible; - padding: 5px; - font-size: 11px; - opacity: 0; - filter: alpha(opacity=0); + right: 15%; + bottom: 20px; + left: 15%; + z-index: 10; + padding-top: 20px; + padding-bottom: 20px; + color: #ffffff; + text-align: center; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); } -.tooltip.in { - opacity: 0.8; - filter: alpha(opacity=80); + +.carousel-caption .btn { + text-shadow: none; } -.tooltip.top { - margin-top: -2px; + +@media screen and (min-width: 768px) { + .carousel-control .icon-prev, + .carousel-control .icon-next { + width: 30px; + height: 30px; + margin-top: -15px; + margin-left: -15px; + font-size: 30px; + } + .carousel-caption { + right: 20%; + left: 20%; + padding-bottom: 30px; + } + .carousel-indicators { + bottom: 20px; + } } -.tooltip.right { - margin-left: 2px; + +.clearfix:before, +.clearfix:after { + display: table; + content: " "; } -.tooltip.bottom { - margin-top: 2px; + +.clearfix:after { + clear: both; } -.tooltip.left { - margin-left: -2px; + +.pull-right { + float: right !important; } -.tooltip.top .tooltip-arrow { - bottom: 0; - left: 50%; - margin-left: -5px; - border-left: 5px solid transparent; - border-right: 5px solid transparent; - border-top: 5px solid #000000; + +.pull-left { + float: left !important; } -.tooltip.left .tooltip-arrow { - top: 50%; - right: 0; - margin-top: -5px; - border-top: 5px solid transparent; - border-bottom: 5px solid transparent; - border-left: 5px solid #000000; + +.hide { + display: none !important; } -.tooltip.bottom .tooltip-arrow { - top: 0; - left: 50%; - margin-left: -5px; - border-left: 5px solid transparent; - border-right: 5px solid transparent; - border-bottom: 5px solid #000000; + +.show { + display: block !important; } -.tooltip.right .tooltip-arrow { - top: 50%; - left: 0; - margin-top: -5px; - border-top: 5px solid transparent; - border-bottom: 5px solid transparent; - border-right: 5px solid #000000; + +.invisible { + visibility: hidden; } -.tooltip-inner { - max-width: 200px; - padding: 3px 8px; - color: #ffffff; - text-align: center; - text-decoration: none; - background-color: #000000; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; + +.text-hide { + font: 0/0 a; + color: transparent; + text-shadow: none; + background-color: transparent; + border: 0; } -.tooltip-arrow { - position: absolute; - width: 0; - height: 0; + +.affix { + position: fixed; } -.popover { - position: absolute; - top: 0; - left: 0; - z-index: 1010; - display: none; - padding: 5px; + +@-ms-viewport { + width: device-width; } -.popover.top { - margin-top: -5px; + +@media screen and (max-width: 400px) { + @-ms-viewport { + width: 320px; + } } -.popover.right { - margin-left: 5px; + +.hidden { + display: none !important; + visibility: hidden !important; } -.popover.bottom { - margin-top: 5px; + +.visible-xs { + display: none !important; } -.popover.left { - margin-left: -5px; + +tr.visible-xs { + display: none !important; } -.popover.top .arrow { - bottom: 0; - left: 50%; - margin-left: -5px; - border-left: 5px solid transparent; - border-right: 5px solid transparent; - border-top: 5px solid #000000; + +th.visible-xs, +td.visible-xs { + display: none !important; } -.popover.right .arrow { - top: 50%; - left: 0; - margin-top: -5px; - border-top: 5px solid transparent; - border-bottom: 5px solid transparent; - border-right: 5px solid #000000; + +@media (max-width: 767px) { + .visible-xs { + display: block !important; + } + tr.visible-xs { + display: table-row !important; + } + th.visible-xs, + td.visible-xs { + display: table-cell !important; + } } -.popover.bottom .arrow { - top: 0; - left: 50%; - margin-left: -5px; - border-left: 5px solid transparent; - border-right: 5px solid transparent; - border-bottom: 5px solid #000000; + +@media (min-width: 768px) and (max-width: 991px) { + .visible-xs.visible-sm { + display: block !important; + } + tr.visible-xs.visible-sm { + display: table-row !important; + } + th.visible-xs.visible-sm, + td.visible-xs.visible-sm { + display: table-cell !important; + } } -.popover.left .arrow { - top: 50%; - right: 0; - margin-top: -5px; - border-top: 5px solid transparent; - border-bottom: 5px solid transparent; - border-left: 5px solid #000000; + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-xs.visible-md { + display: block !important; + } + tr.visible-xs.visible-md { + display: table-row !important; + } + th.visible-xs.visible-md, + td.visible-xs.visible-md { + display: table-cell !important; + } } -.popover .arrow { - position: absolute; - width: 0; - height: 0; + +@media (min-width: 1200px) { + .visible-xs.visible-lg { + display: block !important; + } + tr.visible-xs.visible-lg { + display: table-row !important; + } + th.visible-xs.visible-lg, + td.visible-xs.visible-lg { + display: table-cell !important; + } } -.popover-inner { - padding: 3px; - width: 280px; - overflow: hidden; - background: #000000; - background: rgba(0, 0, 0, 0.8); - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; - -webkit-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - -moz-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); + +.visible-sm { + display: none !important; } -.popover-title { - padding: 9px 15px; - line-height: 1; - background-color: #f5f5f5; - border-bottom: 1px solid #eee; - -webkit-border-radius: 3px 3px 0 0; - -moz-border-radius: 3px 3px 0 0; - border-radius: 3px 3px 0 0; + +tr.visible-sm { + display: none !important; } -.popover-content { - padding: 14px; - background-color: #ffffff; - -webkit-border-radius: 0 0 3px 3px; - -moz-border-radius: 0 0 3px 3px; - border-radius: 0 0 3px 3px; - -webkit-background-clip: padding-box; - -moz-background-clip: padding-box; - background-clip: padding-box; + +th.visible-sm, +td.visible-sm { + display: none !important; } -.popover-content p, .popover-content ul, .popover-content ol { - margin-bottom: 0; + +@media (max-width: 767px) { + .visible-sm.visible-xs { + display: block !important; + } + tr.visible-sm.visible-xs { + display: table-row !important; + } + th.visible-sm.visible-xs, + td.visible-sm.visible-xs { + display: table-cell !important; + } } -.thumbnails { - margin-left: -20px; - list-style: none; - *zoom: 1; + +@media (min-width: 768px) and (max-width: 991px) { + .visible-sm { + display: block !important; + } + tr.visible-sm { + display: table-row !important; + } + th.visible-sm, + td.visible-sm { + display: table-cell !important; + } } -.thumbnails:before, .thumbnails:after { - display: table; - content: ""; + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-sm.visible-md { + display: block !important; + } + tr.visible-sm.visible-md { + display: table-row !important; + } + th.visible-sm.visible-md, + td.visible-sm.visible-md { + display: table-cell !important; + } } -.thumbnails:after { - clear: both; + +@media (min-width: 1200px) { + .visible-sm.visible-lg { + display: block !important; + } + tr.visible-sm.visible-lg { + display: table-row !important; + } + th.visible-sm.visible-lg, + td.visible-sm.visible-lg { + display: table-cell !important; + } } -.thumbnails > li { - float: left; - margin: 0 0 18px 20px; + +.visible-md { + display: none !important; } -.thumbnail { - display: block; - padding: 4px; - line-height: 1; - border: 1px solid #ddd; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075); - -moz-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075); - box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075); + +tr.visible-md { + display: none !important; } -a.thumbnail:hover { - border-color: #0088cc; - -webkit-box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); - -moz-box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); - box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); + +th.visible-md, +td.visible-md { + display: none !important; } -.thumbnail > img { - display: block; - max-width: 100%; - margin-left: auto; - margin-right: auto; + +@media (max-width: 767px) { + .visible-md.visible-xs { + display: block !important; + } + tr.visible-md.visible-xs { + display: table-row !important; + } + th.visible-md.visible-xs, + td.visible-md.visible-xs { + display: table-cell !important; + } } -.thumbnail .caption { - padding: 9px; + +@media (min-width: 768px) and (max-width: 991px) { + .visible-md.visible-sm { + display: block !important; + } + tr.visible-md.visible-sm { + display: table-row !important; + } + th.visible-md.visible-sm, + td.visible-md.visible-sm { + display: table-cell !important; + } } -.label { - padding: 1px 3px 2px; - font-size: 9.75px; - font-weight: bold; - color: #ffffff; - text-transform: uppercase; - background-color: #999999; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-md { + display: block !important; + } + tr.visible-md { + display: table-row !important; + } + th.visible-md, + td.visible-md { + display: table-cell !important; + } } -.label-important { - background-color: #b94a48; + +@media (min-width: 1200px) { + .visible-md.visible-lg { + display: block !important; + } + tr.visible-md.visible-lg { + display: table-row !important; + } + th.visible-md.visible-lg, + td.visible-md.visible-lg { + display: table-cell !important; + } } -.label-warning { - background-color: #f89406; + +.visible-lg { + display: none !important; } -.label-success { - background-color: #468847; + +tr.visible-lg { + display: none !important; } -.label-info { - background-color: #3a87ad; + +th.visible-lg, +td.visible-lg { + display: none !important; } -@-webkit-keyframes progress-bar-stripes { - from { - background-position: 0 0; + +@media (max-width: 767px) { + .visible-lg.visible-xs { + display: block !important; } - to { - background-position: 40px 0; + tr.visible-lg.visible-xs { + display: table-row !important; + } + th.visible-lg.visible-xs, + td.visible-lg.visible-xs { + display: table-cell !important; } } -@-moz-keyframes progress-bar-stripes { - from { - background-position: 0 0; + +@media (min-width: 768px) and (max-width: 991px) { + .visible-lg.visible-sm { + display: block !important; } - to { - background-position: 40px 0; + tr.visible-lg.visible-sm { + display: table-row !important; + } + th.visible-lg.visible-sm, + td.visible-lg.visible-sm { + display: table-cell !important; } } -@keyframes progress-bar-stripes { - from { - background-position: 0 0; + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-lg.visible-md { + display: block !important; } - to { - background-position: 40px 0; + tr.visible-lg.visible-md { + display: table-row !important; + } + th.visible-lg.visible-md, + td.visible-lg.visible-md { + display: table-cell !important; } } -.progress { - overflow: hidden; - height: 18px; - margin-bottom: 18px; - background-color: #f7f7f7; - background-image: -moz-linear-gradient(top, #f5f5f5, #f9f9f9); - background-image: -ms-linear-gradient(top, #f5f5f5, #f9f9f9); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f5f5f5), to(#f9f9f9)); - background-image: -webkit-linear-gradient(top, #f5f5f5, #f9f9f9); - background-image: -o-linear-gradient(top, #f5f5f5, #f9f9f9); - background-image: linear-gradient(top, #f5f5f5, #f9f9f9); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#f5f5f5', endColorstr='#f9f9f9', GradientType=0); - -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); - -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); - box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} -.progress .bar { - width: 0%; - height: 18px; - color: #ffffff; - font-size: 12px; - text-align: center; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #0e90d2; - background-image: -moz-linear-gradient(top, #149bdf, #0480be); - background-image: -ms-linear-gradient(top, #149bdf, #0480be); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#149bdf), to(#0480be)); - background-image: -webkit-linear-gradient(top, #149bdf, #0480be); - background-image: -o-linear-gradient(top, #149bdf, #0480be); - background-image: linear-gradient(top, #149bdf, #0480be); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#149bdf', endColorstr='#0480be', GradientType=0); - -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); - -moz-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); - box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; - box-sizing: border-box; - -webkit-transition: width 0.6s ease; - -moz-transition: width 0.6s ease; - -ms-transition: width 0.6s ease; - -o-transition: width 0.6s ease; - transition: width 0.6s ease; -} -.progress-striped .bar { - background-color: #62c462; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -ms-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - -webkit-background-size: 40px 40px; - -moz-background-size: 40px 40px; - -o-background-size: 40px 40px; - background-size: 40px 40px; -} -.progress.active .bar { - -webkit-animation: progress-bar-stripes 2s linear infinite; - -moz-animation: progress-bar-stripes 2s linear infinite; - animation: progress-bar-stripes 2s linear infinite; -} -.progress-danger .bar { - background-color: #dd514c; - background-image: -moz-linear-gradient(top, #ee5f5b, #c43c35); - background-image: -ms-linear-gradient(top, #ee5f5b, #c43c35); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#c43c35)); - background-image: -webkit-linear-gradient(top, #ee5f5b, #c43c35); - background-image: -o-linear-gradient(top, #ee5f5b, #c43c35); - background-image: linear-gradient(top, #ee5f5b, #c43c35); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ee5f5b', endColorstr='#c43c35', GradientType=0); + +@media (min-width: 1200px) { + .visible-lg { + display: block !important; + } + tr.visible-lg { + display: table-row !important; + } + th.visible-lg, + td.visible-lg { + display: table-cell !important; + } } -.progress-danger.progress-striped .bar { - background-color: #ee5f5b; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -ms-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); -} -.progress-success .bar { - background-color: #5eb95e; - background-image: -moz-linear-gradient(top, #62c462, #57a957); - background-image: -ms-linear-gradient(top, #62c462, #57a957); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#57a957)); - background-image: -webkit-linear-gradient(top, #62c462, #57a957); - background-image: -o-linear-gradient(top, #62c462, #57a957); - background-image: linear-gradient(top, #62c462, #57a957); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#62c462', endColorstr='#57a957', GradientType=0); + +.hidden-xs { + display: block !important; } -.progress-success.progress-striped .bar { - background-color: #62c462; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -ms-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); -} -.progress-info .bar { - background-color: #4bb1cf; - background-image: -moz-linear-gradient(top, #5bc0de, #339bb9); - background-image: -ms-linear-gradient(top, #5bc0de, #339bb9); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#339bb9)); - background-image: -webkit-linear-gradient(top, #5bc0de, #339bb9); - background-image: -o-linear-gradient(top, #5bc0de, #339bb9); - background-image: linear-gradient(top, #5bc0de, #339bb9); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#5bc0de', endColorstr='#339bb9', GradientType=0); + +tr.hidden-xs { + display: table-row !important; } -.progress-info.progress-striped .bar { - background-color: #5bc0de; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -ms-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(-45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); -} -.accordion { - margin-bottom: 18px; -} -.accordion-group { - margin-bottom: 2px; - border: 1px solid #e5e5e5; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; + +th.hidden-xs, +td.hidden-xs { + display: table-cell !important; } -.accordion-heading { - border-bottom: 0; + +@media (max-width: 767px) { + .hidden-xs { + display: none !important; + } + tr.hidden-xs { + display: none !important; + } + th.hidden-xs, + td.hidden-xs { + display: none !important; + } } -.accordion-heading .accordion-toggle { - display: block; - padding: 8px 15px; + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-xs.hidden-sm { + display: none !important; + } + tr.hidden-xs.hidden-sm { + display: none !important; + } + th.hidden-xs.hidden-sm, + td.hidden-xs.hidden-sm { + display: none !important; + } } -.accordion-inner { - padding: 9px 15px; - border-top: 1px solid #e5e5e5; + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-xs.hidden-md { + display: none !important; + } + tr.hidden-xs.hidden-md { + display: none !important; + } + th.hidden-xs.hidden-md, + td.hidden-xs.hidden-md { + display: none !important; + } } -.carousel { - position: relative; - margin-bottom: 18px; - line-height: 1; + +@media (min-width: 1200px) { + .hidden-xs.hidden-lg { + display: none !important; + } + tr.hidden-xs.hidden-lg { + display: none !important; + } + th.hidden-xs.hidden-lg, + td.hidden-xs.hidden-lg { + display: none !important; + } } -.carousel-inner { - overflow: hidden; - width: 100%; - position: relative; + +.hidden-sm { + display: block !important; } -.carousel .item { - display: none; - position: relative; - -webkit-transition: 0.6s ease-in-out left; - -moz-transition: 0.6s ease-in-out left; - -ms-transition: 0.6s ease-in-out left; - -o-transition: 0.6s ease-in-out left; - transition: 0.6s ease-in-out left; + +tr.hidden-sm { + display: table-row !important; } -.carousel .item > img { - display: block; - line-height: 1; + +th.hidden-sm, +td.hidden-sm { + display: table-cell !important; } -.carousel .active, .carousel .next, .carousel .prev { - display: block; + +@media (max-width: 767px) { + .hidden-sm.hidden-xs { + display: none !important; + } + tr.hidden-sm.hidden-xs { + display: none !important; + } + th.hidden-sm.hidden-xs, + td.hidden-sm.hidden-xs { + display: none !important; + } } -.carousel .active { - left: 0; + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-sm { + display: none !important; + } + tr.hidden-sm { + display: none !important; + } + th.hidden-sm, + td.hidden-sm { + display: none !important; + } } -.carousel .next, .carousel .prev { - position: absolute; - top: 0; - width: 100%; + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-sm.hidden-md { + display: none !important; + } + tr.hidden-sm.hidden-md { + display: none !important; + } + th.hidden-sm.hidden-md, + td.hidden-sm.hidden-md { + display: none !important; + } } -.carousel .next { - left: 100%; + +@media (min-width: 1200px) { + .hidden-sm.hidden-lg { + display: none !important; + } + tr.hidden-sm.hidden-lg { + display: none !important; + } + th.hidden-sm.hidden-lg, + td.hidden-sm.hidden-lg { + display: none !important; + } } -.carousel .prev { - left: -100%; + +.hidden-md { + display: block !important; } -.carousel .next.left, .carousel .prev.right { - left: 0; + +tr.hidden-md { + display: table-row !important; } -.carousel .active.left { - left: -100%; + +th.hidden-md, +td.hidden-md { + display: table-cell !important; } -.carousel .active.right { - left: 100%; + +@media (max-width: 767px) { + .hidden-md.hidden-xs { + display: none !important; + } + tr.hidden-md.hidden-xs { + display: none !important; + } + th.hidden-md.hidden-xs, + td.hidden-md.hidden-xs { + display: none !important; + } } -.carousel-control { - position: absolute; - top: 40%; - left: 15px; - width: 40px; - height: 40px; - margin-top: -20px; - font-size: 60px; - font-weight: 100; - line-height: 30px; - color: #ffffff; - text-align: center; - background: #222222; - border: 3px solid #ffffff; - -webkit-border-radius: 23px; - -moz-border-radius: 23px; - border-radius: 23px; - opacity: 0.5; - filter: alpha(opacity=50); + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-md.hidden-sm { + display: none !important; + } + tr.hidden-md.hidden-sm { + display: none !important; + } + th.hidden-md.hidden-sm, + td.hidden-md.hidden-sm { + display: none !important; + } } -.carousel-control.right { - left: auto; - right: 15px; + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-md { + display: none !important; + } + tr.hidden-md { + display: none !important; + } + th.hidden-md, + td.hidden-md { + display: none !important; + } } -.carousel-control:hover { - color: #ffffff; - text-decoration: none; - opacity: 0.9; - filter: alpha(opacity=90); + +@media (min-width: 1200px) { + .hidden-md.hidden-lg { + display: none !important; + } + tr.hidden-md.hidden-lg { + display: none !important; + } + th.hidden-md.hidden-lg, + td.hidden-md.hidden-lg { + display: none !important; + } } -.carousel-caption { - position: absolute; - left: 0; - right: 0; - bottom: 0; - padding: 10px 15px 5px; - background: #333333; - background: rgba(0, 0, 0, 0.75); + +.hidden-lg { + display: block !important; } -.carousel-caption h4, .carousel-caption p { - color: #ffffff; + +tr.hidden-lg { + display: table-row !important; } -.hero-unit { - padding: 60px; - margin-bottom: 30px; - background-color: #f5f5f5; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; + +th.hidden-lg, +td.hidden-lg { + display: table-cell !important; } -.hero-unit h1 { - margin-bottom: 0; - font-size: 60px; - line-height: 1; - letter-spacing: -1px; + +@media (max-width: 767px) { + .hidden-lg.hidden-xs { + display: none !important; + } + tr.hidden-lg.hidden-xs { + display: none !important; + } + th.hidden-lg.hidden-xs, + td.hidden-lg.hidden-xs { + display: none !important; + } } -.hero-unit p { - font-size: 18px; - font-weight: 200; - line-height: 27px; + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-lg.hidden-sm { + display: none !important; + } + tr.hidden-lg.hidden-sm { + display: none !important; + } + th.hidden-lg.hidden-sm, + td.hidden-lg.hidden-sm { + display: none !important; + } } -.pull-right { - float: right; + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-lg.hidden-md { + display: none !important; + } + tr.hidden-lg.hidden-md { + display: none !important; + } + th.hidden-lg.hidden-md, + td.hidden-lg.hidden-md { + display: none !important; + } } -.pull-left { - float: left; + +@media (min-width: 1200px) { + .hidden-lg { + display: none !important; + } + tr.hidden-lg { + display: none !important; + } + th.hidden-lg, + td.hidden-lg { + display: none !important; + } } -.hide { - display: none; + +.visible-print { + display: none !important; } -.show { - display: block; + +tr.visible-print { + display: none !important; } -.invisible { - visibility: hidden; + +th.visible-print, +td.visible-print { + display: none !important; } + +@media print { + .visible-print { + display: block !important; + } + tr.visible-print { + display: table-row !important; + } + th.visible-print, + td.visible-print { + display: table-cell !important; + } + .hidden-print { + display: none !important; + } + tr.hidden-print { + display: none !important; + } + th.hidden-print, + td.hidden-print { + display: none !important; + } +} \ No newline at end of file diff --git a/Examples/index_files/mootools_and_boostrap.js b/Examples/index_files/build.js similarity index 85% rename from Examples/index_files/mootools_and_boostrap.js rename to Examples/index_files/build.js index 3ebdf14..501e83b 100644 --- a/Examples/index_files/mootools_and_boostrap.js +++ b/Examples/index_files/build.js @@ -1,5 +1,26 @@ -//This library: http://localhost:9876/depender/build?requireLibs=Bootstrap&require=Core/DomReady&version=MooTools%20Bootstrap -//Contents: Core:Source/Core/Core.js, Core:Source/Types/Array.js, Core:Source/Types/Function.js, Core:Source/Types/Number.js, Core:Source/Types/String.js, Core:Source/Browser/Browser.js, Core:Source/Types/Object.js, Core:Source/Slick/Slick.Parser.js, Core:Source/Slick/Slick.Finder.js, Core:Source/Element/Element.js, Core:Source/Types/DOMEvent.js, Core:Source/Element/Element.Event.js, Core:Source/Element/Element.Delegation.js, Core:Source/Class/Class.js, Core:Source/Class/Class.Extras.js, Behavior:Source/Event.Mock.js, More:Source/Utilities/Table.js, Core:Source/Utilities/JSON.js, Behavior:Source/Element.Data.js, Behavior:Source/BehaviorAPI.js, Behavior:Source/Behavior.js, Behavior:Source/Delegator.js, Core:Source/Fx/Fx.js, Core:Source/Element/Element.Style.js, Core:Source/Fx/Fx.CSS.js, Core:Source/Fx/Fx.Morph.js, More:Source/More/More.js, More:Source/Element/Element.Shortcuts.js, Core:Source/Element/Element.Dimensions.js, More:Source/Element/Element.Measure.js, More:Source/Fx/Fx.Reveal.js, More-Behaviors:Source/Delegators/Delegator.FxReveal.js, Bootstrap:Source/Behaviors/Behavior.BS.Alert.js, Bootstrap:Source/UI/Bootstrap.js, Core:Source/Utilities/DOMReady.js, Bootstrap:Source/UI/CSSEvents.js, More:Source/Element/Element.Position.js, Bootstrap:Source/UI/Bootstrap.Twipsy.js, Bootstrap:Source/UI/Bootstrap.Dropdown.js, Bootstrap:Source/Behaviors/Behavior.BS.Dropdown.js, Bootstrap:Source/UI/Delegator.BS.ShowPopup.js, More:Source/Types/Object.Extras.js, Core:Source/Fx/Fx.Tween.js, Core:Source/Fx/Fx.Transitions.js, More:Source/Class/Class.Binds.js, More:Source/Class/Class.Occlude.js, More:Source/Utilities/IframeShim.js, More:Source/Interface/Mask.js, More:Source/Element/Elements.From.js, More:Source/Class/Events.Pseudos.js, Bootstrap:Source/UI/Bootstrap.Popup.js, Bootstrap:Source/Behaviors/Behavior.BS.Popup.js, Core:Source/Request/Request.js, Core:Source/Request/Request.HTML.js, More:Source/Class/Class.Refactor.js, More:Source/Interface/Spinner.js, More:Source/Types/String.QueryString.js, More:Source/Element/Element.Event.Pseudos.js, More:Source/Forms/Form.Request.js, Bootstrap:Source/Behaviors/Behavior.BS.Popup.FormRequest.js, Bootstrap:Source/UI/Bootstrap.Popover.js, Bootstrap:Source/Behaviors/Behavior.BS.Popover.js, More:Source/Locale/Locale.js, More:Source/Locale/Locale.en-US.Date.js, More:Source/Types/Date.js, More:Source/Types/String.Extras.js, More:Source/Element/Element.Forms.js, More:Source/Locale/Locale.en-US.Form.Validator.js, More:Source/Forms/Form.Validator.js, More:Source/Forms/Form.Validator.Inline.js, More-Behaviors:Source/Forms/Behavior.FormValidator.js, Bootstrap:Source/Behaviors/Behavior.BS.FormValidator.js, Bootstrap:Source/Behaviors/Behavior.BS.Twipsy.js, Clientcide:Source/Layout/TabSwapper.js, Clientcide:Source/Behaviors/Behavior.Tabs.js, Bootstrap:Source/Behaviors/Behavior.BS.Tabs.js + +//This library: http://localhost:9876/depender/build?requireLibs=Bootstrap&require=Core/DomReady&require=More-Behaviors/Delegator.ToggleClass&require=More-Behaviors/Behavior.Accordion&version=MooTools%20Bootstrap +//Contents: Bootstrap:Source/UI/Bootstrap.js, Core:Source/Core/Core.js, Core:Source/Types/Array.js, Core:Source/Types/Function.js, Core:Source/Types/Number.js, Core:Source/Types/String.js, Core:Source/Browser/Browser.js, Core:Source/Types/Object.js, Core:Source/Slick/Slick.Parser.js, Core:Source/Slick/Slick.Finder.js, Core:Source/Element/Element.js, Core:Source/Types/DOMEvent.js, Core:Source/Element/Element.Event.js, Core:Source/Utilities/DOMReady.js, Bootstrap:Source/UI/CSSEvents.js, Core:Source/Class/Class.js, Core:Source/Class/Class.Extras.js, Core:Source/Element/Element.Style.js, Core:Source/Element/Element.Dimensions.js, More:Source/More/More.js, More:Source/Element/Element.Measure.js, More:Source/Element/Element.Position.js, More:Source/Element/Element.Shortcuts.js, More:Source/Utilities/Table.js, Core:Source/Utilities/JSON.js, Behavior:Source/Element.Data.js, Behavior:Source/BehaviorAPI.js, Behavior:Source/Behavior.js, Bootstrap:Source/UI/Bootstrap.Tooltip.js, Bootstrap:Source/UI/Bootstrap.Dropdown.js, Bootstrap:Source/Behaviors/Behavior.BS.Dropdown.js, Core:Source/Element/Element.Delegation.js, Behavior:Source/Event.Mock.js, Behavior:Source/Delegator.js, Bootstrap:Source/Behaviors/Delegator.BS.ShowPopup.js, Core:Source/Request/Request.js, Core:Source/Request/Request.HTML.js, More:Source/Class/Class.Binds.js, More:Source/Class/Class.Occlude.js, Core:Source/Fx/Fx.js, Core:Source/Fx/Fx.CSS.js, Core:Source/Fx/Fx.Tween.js, More:Source/Class/Class.Refactor.js, More:Source/Utilities/IframeShim.js, More:Source/Interface/Mask.js, More:Source/Interface/Spinner.js, More:Source/Types/String.QueryString.js, More:Source/Class/Events.Pseudos.js, More:Source/Element/Element.Event.Pseudos.js, More:Source/Forms/Form.Request.js, More-Behaviors:Source/Forms/Behavior.FormRequest.js, More:Source/Types/Object.Extras.js, Core:Source/Fx/Fx.Transitions.js, More:Source/Element/Elements.From.js, Bootstrap:Source/UI/Bootstrap.Popup.js, Bootstrap:Source/Behaviors/Behavior.BS.Popup.js, Bootstrap:Source/Behaviors/Behavior.BS.Popup.FormRequest.js, Bootstrap:Source/UI/Bootstrap.Affix.js, Bootstrap:Source/UI/Bootstrap.Popover.js, Bootstrap:Source/Behaviors/Behavior.BS.Popover.js, Bootstrap:Source/Behaviors/Behavior.BS.Affix.js, More:Source/Fx/Fx.Elements.js, More:Source/Fx/Fx.Accordion.js, More-Behaviors:Source/Fx/Behavior.FxAccordion.js, Core:Source/Fx/Fx.Morph.js, More:Source/Fx/Fx.Reveal.js, More:Source/Locale/Locale.js, More:Source/Locale/Locale.en-US.Date.js, More:Source/Types/Date.js, More:Source/Types/String.Extras.js, More:Source/Element/Element.Forms.js, More:Source/Locale/Locale.en-US.Form.Validator.js, More:Source/Forms/Form.Validator.js, More:Source/Forms/Form.Validator.Inline.js, More-Behaviors:Source/Forms/Behavior.FormValidator.js, Bootstrap:Source/Behaviors/Behavior.BS.FormValidator.js, Bootstrap:Source/Behaviors/Behavior.BS.Tooltip.js, Core:Source/Utilities/Cookie.js, Clientcide:Source/Layout/TabSwapper.js, Clientcide:Source/3rdParty/MooHashChange.js, Clientcide:Source/Layout/TabSwapper.Hash.js, Clientcide:Source/Behaviors/Behavior.Tabs.js, Bootstrap:Source/Behaviors/Behavior.BS.Tabs.js, More-Behaviors:Source/Delegators/Delegator.FxReveal.js, Bootstrap:Source/Behaviors/Behavior.BS.Alert.js, More-Behaviors:Source/Delegators/Delegator.AddRemoveClass.js + +// Begin: Source/UI/Bootstrap.js +/* +--- + +name: Bootstrap + +description: The BootStrap namespace. + +authors: [Aaron Newton] + +license: MIT-style license. + +provides: [Bootstrap] + +... +*/ +var Bootstrap = { + version: 3 +}; // Begin: Source/Core/Core.js /* @@ -11,7 +32,7 @@ description: The heart of MooTools. license: MIT-style license. -copyright: Copyright (c) 2006-2010 [Valerio Proietti](http://mad4milk.net/). +copyright: Copyright (c) 2006-2012 [Valerio Proietti](http://mad4milk.net/). authors: The MooTools production team (http://mootools.net/developers/) @@ -27,15 +48,15 @@ provides: [Core, MooTools, Type, typeOf, instanceOf, Native] (function(){ this.MooTools = { - version: '1.4.1', - build: 'd1fb25710e3c5482a219ab9dc675a4e0ad2176b6' + version: '1.4.5', + build: 'ab8ea8824dc3b24b6666867a2c4ed58ebb762cf0' }; // typeOf, instanceOf var typeOf = this.typeOf = function(item){ if (item == null) return 'null'; - if (item.$family) return item.$family(); + if (item.$family != null) return item.$family(); if (item.nodeName){ if (item.nodeType == 1) return 'element'; @@ -55,6 +76,9 @@ var instanceOf = this.instanceOf = function(item, object){ if (constructor === object) return true; constructor = constructor.parent; } + /**/ + if (!item.hasOwnProperty) return false; + /**/ return item instanceof object; }; @@ -87,8 +111,9 @@ Function.prototype.overloadGetter = function(usePlural){ var self = this; return function(a){ var args, result; - if (usePlural || typeof a != 'string') args = a; + if (typeof a != 'string') args = a; else if (arguments.length > 1) args = arguments; + else if (usePlural) args = [a]; if (args){ result = {}; for (var i = 0; i < args.length; i++) result[args[i]] = self.call(this, args[i]); @@ -247,14 +272,18 @@ var force = function(name, object, methods){ proto = prototype[key]; if (generic) generic.protect(); - - if (isType && proto){ - delete prototype[key]; - prototype[key] = proto.protect(); - } + if (isType && proto) object.implement(key, proto.protect()); } - if (isType) object.implement(prototype); + if (isType){ + var methodsEnumerable = prototype.propertyIsEnumerable(methods[0]); + object.forEachMethod = function(fn){ + if (!methodsEnumerable) for (var i = 0, l = methods.length; i < l; i++){ + fn.call(prototype, prototype[methods[i]], methods[i]); + } + for (var key in prototype) fn.call(prototype, prototype[key], key) + }; + } return force; }; @@ -544,8 +573,9 @@ Array.implement({ filter: function(fn, bind){ var results = []; - for (var i = 0, l = this.length >>> 0; i < l; i++){ - if ((i in this) && fn.call(bind, this[i], i, this)) results.push(this[i]); + for (var value, i = 0, l = this.length >>> 0; i < l; i++) if (i in this){ + value = this[i]; + if (fn.call(bind, value, i, this)) results.push(value); } return results; }, @@ -989,17 +1019,6 @@ provides: [Browser, Window, Document] var document = this.document; var window = document.window = this; -var UID = 1; - -this.$uid = (window.ActiveXObject) ? function(item){ - return (item.uid || (item.uid = [UID++]))[0]; -} : function(item){ - return item.uid || (item.uid = UID++); -}; - -$uid(window); -$uid(document); - var ua = navigator.userAgent.toLowerCase(), platform = navigator.platform.toLowerCase(), UA = ua.match(/(opera|ie|firefox|chrome|version)[\s\/:]([\w\d\.]+)?.*?(safari|version[\s\/:]([\w\d\.]+)|$)/) || [null, 'unknown', 0], @@ -1887,8 +1906,14 @@ local.setDocument = function(document){ // contains // FIXME: Add specs: local.contains should be different for xml and html documents? - features.contains = (root && this.isNativeCode(root.contains)) ? function(context, node){ + var nativeRootContains = root && this.isNativeCode(root.contains), + nativeDocumentContains = document && this.isNativeCode(document.contains); + + features.contains = (nativeRootContains && nativeDocumentContains) ? function(context, node){ return context.contains(node); + } : (nativeRootContains && !nativeDocumentContains) ? function(context, node){ + // IE8 does not have .contains on document. + return context === node || ((context === document) ? document.documentElement : context).contains(node); } : (root && root.compareDocumentPosition) ? function(context, node){ return context === node || !!(context.compareDocumentPosition(node) & 16); } : function(context, node){ @@ -2283,7 +2308,7 @@ local.matchSelector = function(node, tag, id, classes, attributes, pseudos){ var i, part, cls; if (classes) for (i = classes.length; i--;){ - cls = node.getAttribute('class') || node.className; + cls = this.getAttribute(node, 'class'); if (!(cls && classes[i].regexp.test(cls))) return false; } if (attributes) for (i = attributes.length; i--;){ @@ -2469,7 +2494,7 @@ var pseudos = { 'nth-last-of-type': local.createNTHPseudo('lastChild', 'previousSibling', 'posNTHTypeLast', true), 'index': function(node, index){ - return this['pseudo:nth-child'](node, '' + index + 1); + return this['pseudo:nth-child'](node, '' + (index + 1)); }, 'even': function(node){ @@ -2541,10 +2566,6 @@ for (var p in pseudos) local['pseudo:' + p] = pseudos[p]; var attributeGetters = local.attributeGetters = { - 'class': function(){ - return this.getAttribute('class') || this.className; - }, - 'for': function(){ return ('htmlFor' in this) ? this.htmlFor : this.getAttribute('for'); }, @@ -2579,7 +2600,7 @@ attributeGetters.MAXLENGTH = attributeGetters.maxLength = attributeGetters.maxle var Slick = local.Slick = (this.Slick || {}); -Slick.version = '1.1.6'; +Slick.version = '1.1.7'; // Slick finder @@ -2709,7 +2730,16 @@ var Element = function(tag, props){ return document.newElement(tag, props); }; -if (Browser.Element) Element.prototype = Browser.Element.prototype; + +if (Browser.Element){ + Element.prototype = Browser.Element.prototype; + // IE8 and IE9 require the wrapping. + Element.prototype._fireEvent = (function(fireEvent){ + return function(type, event){ + return fireEvent.call(this, type, event); + }; + })(Element.prototype.fireEvent); +} new Type('Element', Element).mirror(function(name){ if (Array.prototype[name]) return; @@ -2730,7 +2760,10 @@ new Type('Element', Element).mirror(function(name){ if (!Browser.Element){ Element.parent = Object; - Element.Prototype = {'$family': Function.from('element').hide()}; + Element.Prototype = { + '$constructor': Element, + '$family': Function.from('element').hide() + }; Element.mirror(function(name, method){ Element.Prototype[name] = method; @@ -2853,16 +2886,17 @@ if (object[1] == 1) Elements.implement('splice', function(){ return result; }.protect()); -Elements.implement(Array.prototype); +Array.forEachMethod(function(method, name){ + Elements.implement(name, method); +}); Array.mirror(Elements); /**/ var createElementAcceptsHTML; try { - var x = document.createElement(''); - createElementAcceptsHTML = (x.name == 'x'); -} catch(e){} + createElementAcceptsHTML = (document.createElement('').name == 'x'); +} catch (e){} var escapeQuotes = function(html){ return ('' + html).replace(/&/g, '&').replace(/"/g, '"'); @@ -2890,6 +2924,11 @@ Document.implement({ })(); +(function(){ + +Slick.uidOf(window); +Slick.uidOf(document); + Document.implement({ newTextNode: function(text){ @@ -2914,8 +2953,13 @@ Document.implement({ }, element: function(el, nocash){ - $uid(el); + Slick.uidOf(el); if (!nocash && !el.$family && !(/^(?:object|embed)$/i).test(el.tagName)){ + var fireEvent = el.fireEvent; + // wrapping needed in IE7, or else crash + el._fireEvent = function(type, event){ + return fireEvent(type, event); + }; Object.append(el, Element.Prototype); } return el; @@ -2933,7 +2977,7 @@ Document.implement({ }; return function(el, nocash, doc){ - if (el && el.$family && el.uid) return el; + if (el && el.$family && el.uniqueNumber) return el; var type = typeOf(el); return (types[type]) ? types[type](el, nocash, doc || document) : null; }; @@ -3104,8 +3148,6 @@ if (window.$$ == null) Window.implement('$$', function(selector){ return new Elements(arguments); }); -(function(){ - // Inserters var inserters = { @@ -3165,18 +3207,13 @@ var propertyGetters = {}, propertySetters = {}; var properties = {}; Array.forEach([ 'type', 'value', 'defaultValue', 'accessKey', 'cellPadding', 'cellSpacing', 'colSpan', - 'frameBorder', 'readOnly', 'rowSpan', 'tabIndex', 'useMap' + 'frameBorder', 'rowSpan', 'tabIndex', 'useMap' ], function(property){ properties[property.toLowerCase()] = property; }); -Object.append(properties, { - 'html': 'innerHTML', - 'text': (function(){ - var temp = document.createElement('div'); - return (temp.textContent == null) ? 'innerText': 'textContent'; - })() -}); +properties.html = 'innerHTML'; +properties.text = (document.createElement('div').textContent == null) ? 'innerText': 'textContent'; Object.forEach(properties, function(real, key){ propertySetters[key] = function(node, value){ @@ -3213,7 +3250,7 @@ Array.forEach(bools, function(bool){ Object.append(propertySetters, { 'class': function(node, value){ - ('className' in node) ? node.className = value : node.setAttribute('class', value); + ('className' in node) ? node.className = (value || '') : node.setAttribute('class', value); }, 'for': function(node, value){ @@ -3222,26 +3259,73 @@ Object.append(propertySetters, { 'style': function(node, value){ (node.style) ? node.style.cssText = value : node.setAttribute('style', value); + }, + + 'value': function(node, value){ + node.value = (value != null) ? value : ''; } }); +propertyGetters['class'] = function(node){ + return ('className' in node) ? node.className || null : node.getAttribute('class'); +}; + +/* */ +var el = document.createElement('button'); +// IE sets type as readonly and throws +try { el.type = 'button'; } catch(e){} +if (el.type != 'button') propertySetters.type = function(node, value){ + node.setAttribute('type', value); +}; +el = null; +/* */ + +/**/ +var input = document.createElement('input'); +input.value = 't'; +input.type = 'submit'; +if (input.value != 't') propertySetters.type = function(node, type){ + var value = node.value; + node.type = type; + node.value = value; +}; +input = null; +/**/ + /* getProperty, setProperty */ +/* */ +var pollutesGetAttribute = (function(div){ + div.random = 'attribute'; + return (div.getAttribute('random') == 'attribute'); +})(document.createElement('div')); + +/* */ + Element.implement({ setProperty: function(name, value){ - var lower = name.toLowerCase(); - if (value == null){ - if (!booleans[lower]){ + var setter = propertySetters[name.toLowerCase()]; + if (setter){ + setter(this, value); + } else { + /* */ + if (pollutesGetAttribute) var attributeWhiteList = this.retrieve('$attributeWhiteList', {}); + /* */ + + if (value == null){ this.removeAttribute(name); - return this; + /* */ + if (pollutesGetAttribute) delete attributeWhiteList[name]; + /* */ + } else { + this.setAttribute(name, '' + value); + /* */ + if (pollutesGetAttribute) attributeWhiteList[name] = true; + /* */ } - value = false; } - var setter = propertySetters[lower]; - if (setter) setter(this, value); - else this.setAttribute(name, value); return this; }, @@ -3253,6 +3337,18 @@ Element.implement({ getProperty: function(name){ var getter = propertyGetters[name.toLowerCase()]; if (getter) return getter(this); + /* */ + if (pollutesGetAttribute){ + var attr = this.getAttributeNode(name), attributeWhiteList = this.retrieve('$attributeWhiteList', {}); + if (!attr) return null; + if (attr.expando && !attributeWhiteList[name]){ + var outer = this.outerHTML; + // segment by the opening tag and find mention of attribute name + if (outer.substr(0, outer.search(/\/?['"]?>(?![^<]*<['"])/)).indexOf(name) < 0) return null; + attributeWhiteList[name] = true; + } + } + /* */ var result = Slick.getAttribute(this, name); return (!result && !Slick.hasAttribute(this, name)) ? null : result; }, @@ -3379,7 +3475,7 @@ var get = function(uid){ }; var clean = function(item){ - var uid = item.uid; + var uid = item.uniqueNumber; if (item.removeEvents) item.removeEvents(); if (item.clearAttributes) item.clearAttributes(); if (uid != null){ @@ -3425,7 +3521,7 @@ Element.implement({ if (node.clearAttributes){ node.clearAttributes(); node.mergeAttributes(element); - node.removeAttribute('uid'); + node.removeAttribute('uniqueNumber'); if (node.options){ var no = node.options, eo = element.options; for (var j = no.length; j--;) no[j].selected = eo[j].selected; @@ -3457,7 +3553,7 @@ Element.implement({ old(); }; } else { - collected[$uid(this)] = this; + collected[Slick.uidOf(this)] = this; } if (this.addEventListener) this.addEventListener(type, fn, !!arguments[2]); else this.attachEvent('on' + type, fn); @@ -3471,19 +3567,19 @@ Element.implement({ }, retrieve: function(property, dflt){ - var storage = get($uid(this)), prop = storage[property]; + var storage = get(Slick.uidOf(this)), prop = storage[property]; if (dflt != null && prop == null) prop = storage[property] = dflt; return prop != null ? prop : null; }, store: function(property, value){ - var storage = get($uid(this)); + var storage = get(Slick.uidOf(this)); storage[property] = value; return this; }, eliminate: function(property){ - var storage = get($uid(this)); + var storage = get(Slick.uidOf(this)); delete storage[property]; return this; } @@ -3529,60 +3625,77 @@ Element.Properties.tag = { }; -/**/ -Element.Properties.html = (function(){ +Element.Properties.html = { - var tableTest = Function.attempt(function(){ - var table = document.createElement('table'); - table.innerHTML = ''; - }); + set: function(html){ + if (html == null) html = ''; + else if (typeOf(html) == 'array') html = html.join(''); + this.innerHTML = html; + }, - var wrapper = document.createElement('div'); + erase: function(){ + this.innerHTML = ''; + } - var translations = { - table: [1, '', '
'], - select: [1, ''], - tbody: [2, '', '
'], - tr: [3, '', '
'] - }; - translations.thead = translations.tfoot = translations.tbody; +}; - /**/ - // technique by jdbarlett - http://jdbartlett.com/innershiv/ - wrapper.innerHTML = ''; - var HTML5Test = wrapper.childNodes.length == 1; - if (!HTML5Test){ - var tags = 'abbr article aside audio canvas datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video'.split(' '), - fragment = document.createDocumentFragment(), l = tags.length; - while (l--) fragment.createElement(tags[l]); - fragment.appendChild(wrapper); - } - /**/ +/**/ +// technique by jdbarlett - http://jdbartlett.com/innershiv/ +var div = document.createElement('div'); +div.innerHTML = ''; +var supportsHTML5Elements = (div.childNodes.length == 1); +if (!supportsHTML5Elements){ + var tags = 'abbr article aside audio canvas datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video'.split(' '), + fragment = document.createDocumentFragment(), l = tags.length; + while (l--) fragment.createElement(tags[l]); +} +div = null; +/**/ - var html = { - set: function(html){ - if (typeOf(html) == 'array') html = html.join(''); +/**/ +var supportsTableInnerHTML = Function.attempt(function(){ + var table = document.createElement('table'); + table.innerHTML = ''; + return true; +}); - var wrap = (!tableTest && translations[this.get('tag')]); - /**/ - if (!wrap && !HTML5Test) wrap = [0, '', '']; - /**/ - if (wrap){ - var first = wrapper; - first.innerHTML = wrap[1] + html + wrap[2]; - for (var i = wrap[0]; i--;) first = first.firstChild; - this.empty().adopt(first.childNodes); - } else { - this.innerHTML = html; - } - } - }; +/**/ +var tr = document.createElement('tr'), html = ''; +tr.innerHTML = html; +var supportsTRInnerHTML = (tr.innerHTML == html); +tr = null; +/**/ - html.erase = html.set; +if (!supportsTableInnerHTML || !supportsTRInnerHTML || !supportsHTML5Elements){ - return html; -})(); -/**/ + Element.Properties.html.set = (function(set){ + + var translations = { + table: [1, '', '
'], + select: [1, ''], + tbody: [2, '', '
'], + tr: [3, '', '
'] + }; + + translations.thead = translations.tfoot = translations.tbody; + + return function(html){ + var wrap = translations[this.get('tag')]; + if (!wrap && !supportsHTML5Elements) wrap = [0, '', '']; + if (!wrap) return set.call(this, html); + + var level = wrap[0], wrapper = document.createElement('div'), target = wrapper; + if (!supportsHTML5Elements) fragment.appendChild(wrapper); + wrapper.innerHTML = [wrap[1], html, wrap[2]].flatten().join(''); + while (level--) target = target.firstChild; + this.empty().adopt(target.childNodes); + if (!supportsHTML5Elements) fragment.removeChild(wrapper); + wrapper = null; + }; + + })(Element.Properties.html.set); +} +/*
*/ /**/ var testForm = document.createElement('form'); @@ -3614,8 +3727,23 @@ if (testForm.firstChild.value != 's') Element.Properties.value = { } }; +testForm = null; /**/ +/**/ +if (document.createElement('div').getAttributeNode('id')) Element.Properties.id = { + set: function(id){ + this.id = this.getAttributeNode('id').value = id; + }, + get: function(){ + return this.id || null; + }, + erase: function(){ + this.id = this.getAttributeNode('id').value = ''; + } +}; +/**/ + })(); @@ -3753,7 +3881,7 @@ Event.Keys = new Hash(Event.Keys); name: Element.Event -description: Contains Element methods for dealing with events. This file also includes mouseenter and mouseleave custom Element Events. +description: Contains Element methods for dealing with events. This file also includes mouseenter and mouseleave custom Element Events, if necessary. license: MIT-style license. @@ -3891,30 +4019,30 @@ Element.NativeEvents = { error: 1, abort: 1, scroll: 1 //misc }; -var check = function(event){ - var related = event.relatedTarget; - if (related == null) return true; - if (!related) return false; - return (related != this && related.prefix != 'xul' && typeOf(this) != 'document' && !this.contains(related)); -}; +Element.Events = {mousewheel: { + base: (Browser.firefox) ? 'DOMMouseScroll' : 'mousewheel' +}}; -Element.Events = { +if ('onmouseenter' in document.documentElement){ + Element.NativeEvents.mouseenter = Element.NativeEvents.mouseleave = 2; +} else { + var check = function(event){ + var related = event.relatedTarget; + if (related == null) return true; + if (!related) return false; + return (related != this && related.prefix != 'xul' && typeOf(this) != 'document' && !this.contains(related)); + }; - mouseenter: { + Element.Events.mouseenter = { base: 'mouseover', condition: check - }, + }; - mouseleave: { + Element.Events.mouseleave = { base: 'mouseout', condition: check - }, - - mousewheel: { - base: (Browser.firefox) ? 'DOMMouseScroll' : 'mousewheel' - } - -}; + }; +} /**/ if (!window.addEventListener){ @@ -3925,7 +4053,7 @@ if (!window.addEventListener){ return (this.get('tag') == 'input' && (type == 'radio' || type == 'checkbox')) ? 'propertychange' : 'change' }, condition: function(event){ - return !!(this.type != 'radio' || this.checked); + return this.type != 'radio' || (event.event.propertyName == 'checked' && this.checked); } } } @@ -3940,207 +4068,153 @@ Element.Events = new Hash(Element.Events); })(); -// Begin: Source/Element/Element.Delegation.js +// Begin: Source/Utilities/DOMReady.js /* --- -name: Element.Delegation +name: DOMReady -description: Extends the Element native object to include the delegate method for more efficient event management. +description: Contains the custom event domready. license: MIT-style license. -requires: [Element.Event] +requires: [Browser, Element, Element.Event] -provides: [Element.Delegation] +provides: [DOMReady, DomReady] ... */ -(function(){ +(function(window, document){ -var eventListenerSupport = !!window.addEventListener; +var ready, + loaded, + checks = [], + shouldPoll, + timer, + testElement = document.createElement('div'); -Element.NativeEvents.focusin = Element.NativeEvents.focusout = 2; +var domready = function(){ + clearTimeout(timer); + if (ready) return; + Browser.loaded = ready = true; + document.removeListener('DOMContentLoaded', domready).removeListener('readystatechange', check); -var bubbleUp = function(self, match, fn, event, target){ - while (target && target != self){ - if (match(target, event)) return fn.call(target, event, target); - target = document.id(target.parentNode); - } + document.fireEvent('domready'); + window.fireEvent('domready'); }; -var map = { - mouseenter: { - base: 'mouseover' - }, - mouseleave: { - base: 'mouseout' - }, - focus: { - base: 'focus' + (eventListenerSupport ? '' : 'in'), - capture: true - }, - blur: { - base: eventListenerSupport ? 'blur' : 'focusout', - capture: true +var check = function(){ + for (var i = checks.length; i--;) if (checks[i]()){ + domready(); + return true; } + return false; }; -/**/ -var _key = '$delegation:'; -var formObserver = function(type){ - - return { - - base: 'focusin', +var poll = function(){ + clearTimeout(timer); + if (!check()) timer = setTimeout(poll, 10); +}; - remove: function(self, uid){ - var list = self.retrieve(_key + type + 'listeners', {})[uid]; - if (list && list.forms) for (var i = list.forms.length; i--;){ - list.forms[i].removeEvent(type, list.fns[i]); - } - }, +document.addListener('DOMContentLoaded', domready); - listen: function(self, match, fn, event, target, uid){ - var form = (target.get('tag') == 'form') ? target : event.target.getParent('form'); - if (!form) return; +/**/ +// doScroll technique by Diego Perini http://javascript.nwbox.com/IEContentLoaded/ +// testElement.doScroll() throws when the DOM is not ready, only in the top window +var doScrollWorks = function(){ + try { + testElement.doScroll(); + return true; + } catch (e){} + return false; +}; +// If doScroll works already, it can't be used to determine domready +// e.g. in an iframe +if (testElement.doScroll && !doScrollWorks()){ + checks.push(doScrollWorks); + shouldPoll = true; +} +/**/ - var listeners = self.retrieve(_key + type + 'listeners', {}), - listener = listeners[uid] || {forms: [], fns: []}, - forms = listener.forms, fns = listener.fns; +if (document.readyState) checks.push(function(){ + var state = document.readyState; + return (state == 'loaded' || state == 'complete'); +}); - if (forms.indexOf(form) != -1) return; - forms.push(form); +if ('onreadystatechange' in document) document.addListener('readystatechange', check); +else shouldPoll = true; - var _fn = function(event){ - bubbleUp(self, match, fn, event, target); - }; - form.addEvent(type, _fn); - fns.push(_fn); +if (shouldPoll) poll(); - listeners[uid] = listener; - self.store(_key + type + 'listeners', listeners); - } - }; +Element.Events.domready = { + onAdd: function(fn){ + if (ready) fn.call(this); + } }; -var inputObserver = function(type){ - return { - base: 'focusin', - listen: function(self, match, fn, event, target){ - var events = {blur: function(){ - this.removeEvents(events); - }}; - events[type] = function(event){ - bubbleUp(self, match, fn, event, target); - }; - event.target.addEvents(events); +// Make sure that domready fires before load +Element.Events.load = { + base: 'load', + onAdd: function(fn){ + if (loaded && this == window) fn.call(this); + }, + condition: function(){ + if (this == window){ + domready(); + delete Element.Events.load; } - }; + return true; + } }; -if (!eventListenerSupport) Object.append(map, { - submit: formObserver('submit'), - reset: formObserver('reset'), - change: inputObserver('change'), - select: inputObserver('select') +// This is based on the custom load event +window.addEvent('load', function(){ + loaded = true; }); -/**/ - -var proto = Element.prototype, - addEvent = proto.addEvent, - removeEvent = proto.removeEvent; - -var relay = function(old, method){ - return function(type, fn, useCapture){ - if (type.indexOf(':relay') == -1) return old.call(this, type, fn, useCapture); - var parsed = Slick.parse(type).expressions[0][0]; - if (parsed.pseudos[0].key != 'relay') return old.call(this, type, fn, useCapture); - var newType = parsed.tag; - parsed.pseudos.slice(1).each(function(pseudo){ - newType += ':' + pseudo.key + (pseudo.value ? '(' + pseudo.value + ')' : ''); - }); - old.call(this, type, fn); - return method.call(this, newType, parsed.pseudos[0].value, fn); - }; -}; -var delegation = { +})(window, document); - addEvent: function(type, match, fn){ - var storage = this.retrieve('$delegates', {}), stored = storage[type]; - if (stored) for (var _uid in stored){ - if (stored[_uid].fn == fn && stored[_uid].match == match) return this; - } - var _type = type, _match = match, _fn = fn, _map = map[type] || {}; - type = _map.base || _type; +// Begin: Source/UI/CSSEvents.js +/* +--- - match = function(target){ - return Slick.match(target, _match); - }; +name: CSSEvents - var elementEvent = Element.Events[_type]; - if (elementEvent && elementEvent.condition){ - var __match = match, condition = elementEvent.condition; - match = function(target, event){ - return __match(target, event) && condition.call(target, event, type); - }; - } +license: MIT-style - var self = this, uid = String.uniqueID(); - var delegator = _map.listen ? function(event, target){ - if (!target && event && event.target) target = event.target; - if (target) _map.listen(self, match, fn, event, target, uid); - } : function(event, target){ - if (!target && event && event.target) target = event.target; - if (target) bubbleUp(self, match, fn, event, target); - }; +authors: [Aaron Newton] - if (!stored) stored = {}; - stored[uid] = { - match: _match, - fn: _fn, - delegator: delegator - }; - storage[_type] = stored; - return addEvent.call(this, type, delegator, _map.capture); - }, +requires: [Core/DomReady] - removeEvent: function(type, match, fn, _uid){ - var storage = this.retrieve('$delegates', {}), stored = storage[type]; - if (!stored) return this; +provides: CSSEvents +... +*/ - if (_uid){ - var _type = type, delegator = stored[_uid].delegator, _map = map[type] || {}; - type = _map.base || _type; - if (_map.remove) _map.remove(this, _uid); - delete stored[_uid]; - storage[_type] = stored; - return removeEvent.call(this, type, delegator); - } +Browser.Features.getCSSTransition = function(){ + Browser.Features.cssTransition = (function () { + var thisBody = document.body || document.documentElement + , thisStyle = thisBody.style + , support = thisStyle.transition !== undefined || thisStyle.WebkitTransition !== undefined || thisStyle.MozTransition !== undefined || thisStyle.MsTransition !== undefined || thisStyle.OTransition !== undefined; + return support; + })(); - var __uid, s; - if (fn) for (__uid in stored){ - s = stored[__uid]; - if (s.match == match && s.fn == fn) return delegation.removeEvent.call(this, type, match, fn, __uid); - } else for (__uid in stored){ - s = stored[__uid]; - if (s.match == match) delegation.removeEvent.call(this, type, match, s.fn, __uid); + // set CSS transition event type + if ( Browser.Features.cssTransition ) { + Browser.Features.transitionEnd = "TransitionEnd"; + if ( Browser.safari || Browser.chrome ) { + Browser.Features.transitionEnd = "webkitTransitionEnd"; + } else if ( Browser.firefox ) { + Browser.Features.transitionEnd = "transitionend"; + } else if ( Browser.opera ) { + Browser.Features.transitionEnd = "oTransitionEnd"; } - return this; } - + Browser.Features.getCSSTransition = Function.from(Browser.Features.transitionEnd); }; -[Element, Window, Document].invoke('implement', { - addEvent: relay(addEvent, delegation.addEvent), - removeEvent: relay(removeEvent, delegation.removeEvent) -}); - -})(); - +window.addEvent("domready", Browser.Features.getCSSTransition); // Begin: Source/Class/Class.js /* @@ -4384,2603 +4458,3104 @@ this.Options = new Class({ })(); -// Begin: Source/Event.Mock.js +// Begin: Source/Element/Element.Style.js /* --- -name: Event.Mock -description: Supplies a Mock Event object for use on fireEvent +name: Element.Style -license: MIT-style +description: Contains methods for interacting with the styles of Elements in a fashionable way. -authors: -- Arieh Glazer +license: MIT-style license. -requires: Core/Event +requires: Element -provides: [Event.Mock] +provides: Element.Style ... */ -(function($,window,undef){ - -/** - * creates a Mock event to be used with fire event - * @param Element target an element to set as the target of the event - not required - * @param string type the type of the event to be fired. Will not be used by IE - not required. - * - */ -Event.Mock = function(target,type){ - type = type || 'click'; +(function(){ - var e = { - type: type, - target: target - }; +var html = document.html; - if (document.createEvent){ - e = document.createEvent('HTMLEvents'); - e.initEvent( - type //event type - , false //bubbles - set to false because the event should like normal fireEvent - , true //cancelable - ); - } +// +// Check for oldIE, which does not remove styles when they're set to null +var el = document.createElement('div'); +el.style.color = 'red'; +el.style.color = null; +var doesNotRemoveStyles = el.style.color == 'red'; +el = null; +// - e = new Event(e); +Element.Properties.styles = {set: function(styles){ + this.setStyles(styles); +}}; - e.target = target; +var hasOpacity = (html.style.opacity != null), + hasFilter = (html.style.filter != null), + reAlpha = /alpha\(opacity=([\d.]+)\)/i; - return e; +var setVisibility = function(element, opacity){ + element.store('$opacity', opacity); + element.style.visibility = opacity > 0 || opacity == null ? 'visible' : 'hidden'; }; -})(document.id,window); +var setOpacity = (hasOpacity ? function(element, opacity){ + element.style.opacity = opacity; +} : (hasFilter ? function(element, opacity){ + var style = element.style; + if (!element.currentStyle || !element.currentStyle.hasLayout) style.zoom = 1; + if (opacity == null || opacity == 1) opacity = ''; + else opacity = 'alpha(opacity=' + (opacity * 100).limit(0, 100).round() + ')'; + var filter = style.filter || element.getComputedStyle('filter') || ''; + style.filter = reAlpha.test(filter) ? filter.replace(reAlpha, opacity) : filter + opacity; + if (!style.filter) style.removeAttribute('filter'); +} : setVisibility)); -// Begin: Source/Utilities/Table.js -/* ---- -name: Table -description: LUA-Style table implementation. -license: MIT-style license -authors: - - Valerio Proietti -requires: [Core/Array] -provides: [Table] -... -*/ +var getOpacity = (hasOpacity ? function(element){ + var opacity = element.style.opacity || element.getComputedStyle('opacity'); + return (opacity == '') ? 1 : opacity.toFloat(); +} : (hasFilter ? function(element){ + var filter = (element.style.filter || element.getComputedStyle('filter')), + opacity; + if (filter) opacity = filter.match(reAlpha); + return (opacity == null || filter == null) ? 1 : (opacity[1] / 100); +} : function(element){ + var opacity = element.retrieve('$opacity'); + if (opacity == null) opacity = (element.style.visibility == 'hidden' ? 0 : 1); + return opacity; +})); -(function(){ +var floatName = (html.style.cssFloat == null) ? 'styleFloat' : 'cssFloat'; -var Table = this.Table = function(){ +Element.implement({ - this.length = 0; - var keys = [], - values = []; + getComputedStyle: function(property){ + if (this.currentStyle) return this.currentStyle[property.camelCase()]; + var defaultView = Element.getDocument(this).defaultView, + computed = defaultView ? defaultView.getComputedStyle(this, null) : null; + return (computed) ? computed.getPropertyValue((property == floatName) ? 'float' : property.hyphenate()) : null; + }, - this.set = function(key, value){ - var index = keys.indexOf(key); - if (index == -1){ - var length = keys.length; - keys[length] = key; - values[length] = value; - this.length++; - } else { - values[index] = value; + setStyle: function(property, value){ + if (property == 'opacity'){ + if (value != null) value = parseFloat(value); + setOpacity(this, value); + return this; + } + property = (property == 'float' ? floatName : property).camelCase(); + if (typeOf(value) != 'string'){ + var map = (Element.Styles[property] || '@').split(' '); + value = Array.from(value).map(function(val, i){ + if (!map[i]) return ''; + return (typeOf(val) == 'number') ? map[i].replace('@', Math.round(val)) : val; + }).join(' '); + } else if (value == String(Number(value))){ + value = Math.round(value); + } + this.style[property] = value; + // + if ((value == '' || value == null) && doesNotRemoveStyles && this.style.removeAttribute){ + this.style.removeAttribute(property); } + // return this; - }; - - this.get = function(key){ - var index = keys.indexOf(key); - return (index == -1) ? null : values[index]; - }; + }, - this.erase = function(key){ - var index = keys.indexOf(key); - if (index != -1){ - this.length--; - keys.splice(index, 1); - return values.splice(index, 1)[0]; + getStyle: function(property){ + if (property == 'opacity') return getOpacity(this); + property = (property == 'float' ? floatName : property).camelCase(); + var result = this.style[property]; + if (!result || property == 'zIndex'){ + result = []; + for (var style in Element.ShortStyles){ + if (property != style) continue; + for (var s in Element.ShortStyles[style]) result.push(this.getStyle(s)); + return result.join(' '); + } + result = this.getComputedStyle(property); } - return null; - }; - - this.each = this.forEach = function(fn, bind){ - for (var i = 0, l = this.length; i < l; i++) fn.call(bind, keys[i], values[i], this); - }; - -}; - -if (this.Type) new Type('Table', Table); - -})(); - - -// Begin: Source/Utilities/JSON.js -/* ---- - -name: JSON + if (result){ + result = String(result); + var color = result.match(/rgba?\([\d\s,]+\)/); + if (color) result = result.replace(color[0], color[0].rgbToHex()); + } + if (Browser.opera || Browser.ie){ + if ((/^(height|width)$/).test(property) && !(/px$/.test(result))){ + var values = (property == 'width') ? ['left', 'right'] : ['top', 'bottom'], size = 0; + values.each(function(value){ + size += this.getStyle('border-' + value + '-width').toInt() + this.getStyle('padding-' + value).toInt(); + }, this); + return this['offset' + property.capitalize()] - size + 'px'; + } + if (Browser.ie && (/^border(.+)Width|margin|padding/).test(property) && isNaN(parseFloat(result))){ + return '0px'; + } + } + return result; + }, -description: JSON encoder and decoder. + setStyles: function(styles){ + for (var style in styles) this.setStyle(style, styles[style]); + return this; + }, -license: MIT-style license. + getStyles: function(){ + var result = {}; + Array.flatten(arguments).each(function(key){ + result[key] = this.getStyle(key); + }, this); + return result; + } -SeeAlso: +}); -requires: [Array, String, Number, Function] +Element.Styles = { + left: '@px', top: '@px', bottom: '@px', right: '@px', + width: '@px', height: '@px', maxWidth: '@px', maxHeight: '@px', minWidth: '@px', minHeight: '@px', + backgroundColor: 'rgb(@, @, @)', backgroundPosition: '@px @px', color: 'rgb(@, @, @)', + fontSize: '@px', letterSpacing: '@px', lineHeight: '@px', clip: 'rect(@px @px @px @px)', + margin: '@px @px @px @px', padding: '@px @px @px @px', border: '@px @ rgb(@, @, @) @px @ rgb(@, @, @) @px @ rgb(@, @, @)', + borderWidth: '@px @px @px @px', borderStyle: '@ @ @ @', borderColor: 'rgb(@, @, @) rgb(@, @, @) rgb(@, @, @) rgb(@, @, @)', + zIndex: '@', 'zoom': '@', fontWeight: '@', textIndent: '@px', opacity: '@' +}; -provides: JSON +//<1.3compat> -... -*/ +Element.implement({ -if (typeof JSON == 'undefined') this.JSON = {}; + setOpacity: function(value){ + setOpacity(this, value); + return this; + }, -//<1.2compat> + getOpacity: function(){ + return getOpacity(this); + } -JSON = new Hash({ - stringify: JSON.stringify, - parse: JSON.parse }); -// - -(function(){ - -var special = {'\b': '\\b', '\t': '\\t', '\n': '\\n', '\f': '\\f', '\r': '\\r', '"' : '\\"', '\\': '\\\\'}; +Element.Properties.opacity = { -var escape = function(chr){ - return special[chr] || '\\u' + ('0000' + chr.charCodeAt(0).toString(16)).slice(-4); -}; + set: function(opacity){ + setOpacity(this, opacity); + setVisibility(this, opacity); + }, -JSON.validate = function(string){ - string = string.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g, '@'). - replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g, ']'). - replace(/(?:^|:|,)(?:\s*\[)+/g, ''); + get: function(){ + return getOpacity(this); + } - return (/^[\],:{}\s]*$/).test(string); }; -JSON.encode = JSON.stringify ? function(obj){ - return JSON.stringify(obj); -} : function(obj){ - if (obj && obj.toJSON) obj = obj.toJSON(); +// - switch (typeOf(obj)){ - case 'string': - return '"' + obj.replace(/[\x00-\x1f\\"]/g, escape) + '"'; - case 'array': - return '[' + obj.map(JSON.encode).clean() + ']'; - case 'object': case 'hash': - var string = []; - Object.each(obj, function(value, key){ - var json = JSON.encode(value); - if (json) string.push(JSON.encode(key) + ':' + json); - }); - return '{' + string + '}'; - case 'number': case 'boolean': return '' + obj; - case 'null': return 'null'; - } +//<1.2compat> - return null; -}; +Element.Styles = new Hash(Element.Styles); -JSON.decode = function(string, secure){ - if (!string || typeOf(string) != 'string') return null; +// - if (secure || JSON.secure){ - if (JSON.parse) return JSON.parse(string); - if (!JSON.validate(string)) throw new Error('JSON could not decode the input; security is enabled and the value is not secure.'); - } +Element.ShortStyles = {margin: {}, padding: {}, border: {}, borderWidth: {}, borderStyle: {}, borderColor: {}}; - return eval('(' + string + ')'); -}; +['Top', 'Right', 'Bottom', 'Left'].each(function(direction){ + var Short = Element.ShortStyles; + var All = Element.Styles; + ['margin', 'padding'].each(function(style){ + var sd = style + direction; + Short[style][sd] = All[sd] = '@px'; + }); + var bd = 'border' + direction; + Short.border[bd] = All[bd] = '@px @ rgb(@, @, @)'; + var bdw = bd + 'Width', bds = bd + 'Style', bdc = bd + 'Color'; + Short[bd] = {}; + Short.borderWidth[bdw] = Short[bd][bdw] = All[bdw] = '@px'; + Short.borderStyle[bds] = Short[bd][bds] = All[bds] = '@'; + Short.borderColor[bdc] = Short[bd][bdc] = All[bdc] = 'rgb(@, @, @)'; +}); })(); -// Begin: Source/Element.Data.js +// Begin: Source/Element/Element.Dimensions.js /* --- -name: Element.Data -description: Stores data in HTML5 data properties -provides: [Element.Data] -requires: [Core/Element, Core/JSON] -script: Element.Data.js - -... -*/ -(function(){ - - JSON.isSecure = function(string){ - //this verifies that the string is parsable JSON and not malicious (borrowed from JSON.js in MooTools, which in turn borrowed it from Crockford) - //this version is a little more permissive, as it allows single quoted attributes because forcing the use of double quotes - //is a pain when this stuff is used as HTML properties - return (/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(string.replace(/\\./g, '@').replace(/"[^"\\\n\r]*"/g, '').replace(/'[^'\\\n\r]*'/g, '')); - }; - - Element.implement({ - /* - sets an HTML5 data property. - arguments: - name - (string) the data name to store; will be automatically prefixed with 'data-'. - value - (string, number) the value to store. - */ - setData: function(name, value){ - return this.set('data-' + name.hyphenate(), value); - }, - getData: function(name, defaultValue){ - var value = this.get('data-' + name.hyphenate()); - if (value != undefined){ - return value; - } else if (defaultValue != undefined){ - this.setData(name, defaultValue); - return defaultValue; - } - }, +name: Element.Dimensions - /* - arguments: - name - (string) the data name to store; will be automatically prefixed with 'data-' - value - (string, array, or object) if an object or array the object will be JSON encoded; otherwise stored as provided. - */ - setJSONData: function(name, value){ - return this.setData(name, JSON.encode(value)); - }, +description: Contains methods to work with size, scroll, or positioning of Elements and the window object. - /* - retrieves a property from HTML5 data property you specify +license: MIT-style license. - arguments: - name - (retrieve) the data name to store; will be automatically prefixed with 'data-' - strict - (boolean) if true, will set the JSON.decode's secure flag to true; otherwise the value is still tested but allows single quoted attributes. - defaultValue - (string, array, or object) the value to set if no value is found (see storeData above) - */ - getJSONData: function(name, strict, defaultValue){ - var value = this.get('data-' + name); - if (value != undefined){ - if (value && JSON.isSecure(value)) { - return JSON.decode(value, strict); - } else { - return value; - } - } else if (defaultValue != undefined){ - this.setJSONData(name, defaultValue); - return defaultValue; - } - } +credits: + - Element positioning based on the [qooxdoo](http://qooxdoo.org/) code and smart browser fixes, [LGPL License](http://www.gnu.org/licenses/lgpl.html). + - Viewport dimensions based on [YUI](http://developer.yahoo.com/yui/) code, [BSD License](http://developer.yahoo.com/yui/license.html). - }); +requires: [Element, Element.Style] -})(); +provides: [Element.Dimensions] -// Begin: Source/BehaviorAPI.js -/* ---- -name: BehaviorAPI -description: HTML getters for Behavior's API model. -requires: [Core/Class, /Element.Data] -provides: [BehaviorAPI] ... */ - (function(){ - //see Docs/BehaviorAPI.md for documentation of public methods. - - var reggy = /[^a-z0-9\-]/gi; - window.BehaviorAPI = new Class({ - element: null, - prefix: '', - defaults: {}, +var element = document.createElement('div'), + child = document.createElement('div'); +element.style.height = '0'; +element.appendChild(child); +var brokenOffsetParent = (child.offsetParent === element); +element = child = null; - initialize: function(element, prefix){ - this.element = element; - this.prefix = prefix.toLowerCase().replace('.', '-', 'g').replace(reggy, ''); - }, +var isOffset = function(el){ + return styleString(el, 'position') != 'static' || isBody(el); +}; - /****************** - * PUBLIC METHODS - ******************/ +var isOffsetStatic = function(el){ + return isOffset(el) || (/^(?:table|td|th)$/i).test(el.tagName); +}; - get: function(/* name[, name, name, etc] */){ - if (arguments.length > 1) return this._getObj(Array.from(arguments)); - return this._getValue(arguments[0]); - }, +Element.implement({ - getAs: function(/*returnType, name, defaultValue OR {name: returnType, name: returnType, etc}*/){ - if (typeOf(arguments[0]) == 'object') return this._getValuesAs.apply(this, arguments); - return this._getValueAs.apply(this, arguments); - }, - - require: function(/* name[, name, name, etc] */){ - for (var i = 0; i < arguments.length; i++){ - if (this._getValue(arguments[i]) == undefined) throw new Error('Could not retrieve ' + this.prefix + '-' + arguments[i] + ' option from element.'); - } - return this; - }, - - requireAs: function(returnType, name /* OR {name: returnType, name: returnType, etc}*/){ - var val; - if (typeOf(arguments[0]) == 'object'){ - for (var objName in arguments[0]){ - val = this._getValueAs(arguments[0][objName], objName); - if (val === undefined || val === null) throw new Error("Could not retrieve " + this.prefix + '-' + objName + " option from element."); - } - } else { - val = this._getValueAs(returnType, name); - if (val === undefined || val === null) throw new Error("Could not retrieve " + this.prefix + '-' + name + " option from element."); - } - return this; - }, + scrollTo: function(x, y){ + if (isBody(this)){ + this.getWindow().scrollTo(x, y); + } else { + this.scrollLeft = x; + this.scrollTop = y; + } + return this; + }, - setDefault: function(name, value /* OR {name: value, name: value, etc }*/){ - if (typeOf(arguments[0]) == 'object'){ - for (var objName in arguments[0]){ - this.setDefault(objName, arguments[0][objName]); - } - return; - } - name = name.camelCase(); - this.defaults[name] = value; - if (this._getValue(name) == null){ - var options = this._getOptions(); - options[name] = value; - } - return this; - }, + getSize: function(){ + if (isBody(this)) return this.getWindow().getSize(); + return {x: this.offsetWidth, y: this.offsetHeight}; + }, - refreshAPI: function(){ - delete this.options; - this.setDefault(this.defaults); - return; - }, + getScrollSize: function(){ + if (isBody(this)) return this.getWindow().getScrollSize(); + return {x: this.scrollWidth, y: this.scrollHeight}; + }, - /****************** - * PRIVATE METHODS - ******************/ + getScroll: function(){ + if (isBody(this)) return this.getWindow().getScroll(); + return {x: this.scrollLeft, y: this.scrollTop}; + }, - //given an array of names, returns an object of key/value pairs for each name - _getObj: function(names){ - var obj = {}; - names.each(function(name){ - var value = this._getValue(name); - if (value !== undefined) obj[name] = value; - }, this); - return obj; - }, - //gets the data-behaviorname-options object and parses it as JSON - _getOptions: function(){ - try { - if (!this.options){ - var options = this.element.getData(this.prefix + '-options', '{}'); - if (options && options.substring(0,1) != '{') options = '{' + options + '}'; - var isSecure = JSON.isSecure(options); - if (!isSecure) throw new Error('warning, options value for element is not parsable, check your JSON format for quotes, etc.'); - this.options = isSecure ? JSON.decode(options) : {}; - for (option in this.options) { - this.options[option.camelCase()] = this.options[option]; - } - } - } catch (e){ - throw new Error('Could not get options from element; check your syntax. ' + this.prefix + '-options: "' + this.element.getData(this.prefix + '-options', '{}') + '"'); - } - return this.options; - }, - //given a name (string) returns the value for it - _getValue: function(name){ - name = name.camelCase(); - var options = this._getOptions(); - if (!options.hasOwnProperty(name)){ - var inline = this.element.getData(this.prefix + '-' + name.hyphenate()); - if (inline) options[name] = inline; - } - return options[name]; - }, - //given a Type and a name (string) returns the value for it coerced to that type if possible - //else returns the defaultValue or null - _getValueAs: function(returnType, name, defaultValue){ - var value = this._getValue(name); - if (value == null || value == undefined) return defaultValue; - var coerced = this._coerceFromString(returnType, value); - if (coerced == null) throw new Error("Could not retrieve value '" + name + "' as the specified type. Its value is: " + value); - return coerced; - }, - //given an object of name/Type pairs, returns those as an object of name/value (as specified Type) pairs - _getValuesAs: function(obj){ - var returnObj = {}; - for (var name in obj){ - returnObj[name] = this._getValueAs(obj[name], name); - } - return returnObj; - }, - //attempts to run a value through the JSON parser. If the result is not of that type returns null. - _coerceFromString: function(toType, value){ - if (typeOf(value) == 'string' && toType != String){ - if (JSON.isSecure(value)) value = JSON.decode(value); - } - if (instanceOf(value, toType)) return value; - return null; + getScrolls: function(){ + var element = this.parentNode, position = {x: 0, y: 0}; + while (element && !isBody(element)){ + position.x += element.scrollLeft; + position.y += element.scrollTop; + element = element.parentNode; } - }); - -})(); + return position; + }, -// Begin: Source/Behavior.js -/* ---- -name: Behavior -description: Auto-instantiates widgets/classes based on parsed, declarative HTML. -requires: [Core/Class.Extras, Core/Element.Event, Core/Selectors, More/Table, /Element.Data, /BehaviorAPI] -provides: [Behavior] -... -*/ + getOffsetParent: brokenOffsetParent ? function(){ + var element = this; + if (isBody(element) || styleString(element, 'position') == 'fixed') return null; -(function(){ + var isOffsetCheck = (styleString(element, 'position') == 'static') ? isOffsetStatic : isOffset; + while ((element = element.parentNode)){ + if (isOffsetCheck(element)) return element; + } + return null; + } : function(){ + var element = this; + if (isBody(element) || styleString(element, 'position') == 'fixed') return null; - var getLog = function(method){ - return function(){ - if (window.console && console[method]){ - if(console[method].apply) console[method].apply(console, arguments); - else console[method](Array.from(arguments).join(' ')); - } - }; - }; + try { + return element.offsetParent; + } catch(e) {} + return null; + }, - var PassMethods = new Class({ - //pass a method pointer through to a filter - //by default the methods for add/remove events are passed to the filter - //pointed to this instance of behavior. you could use this to pass along - //other methods to your filters. For example, a method to close a popup - //for filters presented inside popups. - passMethod: function(method, fn){ - if (this.API.prototype[method]) throw new Error('Cannot overwrite API method ' + method + ' as it already exists'); - this.API.implement(method, fn); - return this; - }, + getOffsets: function(){ + if (this.getBoundingClientRect && !Browser.Platform.ios){ + var bound = this.getBoundingClientRect(), + html = document.id(this.getDocument().documentElement), + htmlScroll = html.getScroll(), + elemScrolls = this.getScrolls(), + isFixed = (styleString(this, 'position') == 'fixed'); - passMethods: function(methods){ - for (method in methods) this.passMethod(method, methods[method]); - return this; + return { + x: bound.left.toInt() + elemScrolls.x + ((isFixed) ? 0 : htmlScroll.x) - html.clientLeft, + y: bound.top.toInt() + elemScrolls.y + ((isFixed) ? 0 : htmlScroll.y) - html.clientTop + }; } - }); + var element = this, position = {x: 0, y: 0}; + if (isBody(this)) return position; - var spaceOrCommaRegex = /\s*,\s*|\s+/g; + while (element && !isBody(element)){ + position.x += element.offsetLeft; + position.y += element.offsetTop; - BehaviorAPI.implement({ - deprecate: function(deprecated, asJSON){ - var set, - values = {}; - Object.each(deprecated, function(prop, key){ - var value = this.element[ asJSON ? 'getJSONData' : 'getData'](prop); - if (value !== undefined){ - set = true; - values[key] = value; + if (Browser.firefox){ + if (!borderBox(element)){ + position.x += leftBorder(element); + position.y += topBorder(element); } - }, this); - this.setDefault(values); - return this; + var parent = element.parentNode; + if (parent && styleString(parent, 'overflow') != 'visible'){ + position.x += leftBorder(parent); + position.y += topBorder(parent); + } + } else if (element != this && Browser.safari){ + position.x += leftBorder(element); + position.y += topBorder(element); + } + + element = element.offsetParent; } - }); + if (Browser.firefox && !borderBox(this)){ + position.x -= leftBorder(this); + position.y -= topBorder(this); + } + return position; + }, - this.Behavior = new Class({ + getPosition: function(relative){ + var offset = this.getOffsets(), + scroll = this.getScrolls(); + var position = { + x: offset.x - scroll.x, + y: offset.y - scroll.y + }; - Implements: [Options, Events, PassMethods], + if (relative && (relative = document.id(relative))){ + var relativePosition = relative.getPosition(); + return {x: position.x - relativePosition.x - leftBorder(relative), y: position.y - relativePosition.y - topBorder(relative)}; + } + return position; + }, - options: { - //by default, errors thrown by filters are caught; the onError event is fired. - //set this to *true* to NOT catch these errors to allow them to be handled by the browser. - // breakOnErrors: false, - // container: document.body, + getCoordinates: function(element){ + if (isBody(this)) return this.getWindow().getCoordinates(); + var position = this.getPosition(element), + size = this.getSize(); + var obj = { + left: position.x, + top: position.y, + width: size.x, + height: size.y + }; + obj.right = obj.left + obj.width; + obj.bottom = obj.top + obj.height; + return obj; + }, - //default error behavior when a filter cannot be applied - onError: getLog('error'), - onWarn: getLog('warn'), - enableDeprecation: true, - selector: '[data-behavior]' - }, + computePosition: function(obj){ + return { + left: obj.x - styleNumber(this, 'margin-left'), + top: obj.y - styleNumber(this, 'margin-top') + }; + }, - initialize: function(options){ - this.setOptions(options); - this.API = new Class({ Extends: BehaviorAPI }); - this.passMethods({ - getDelegator: this.getDelegator.bind(this), - addEvent: this.addEvent.bind(this), - removeEvent: this.removeEvent.bind(this), - addEvents: this.addEvents.bind(this), - removeEvents: this.removeEvents.bind(this), - fireEvent: this.fireEvent.bind(this), - applyFilters: this.apply.bind(this), - applyFilter: this.applyFilter.bind(this), - getContentElement: this.getContentElement.bind(this), - cleanup: this.cleanup.bind(this), - getContainerSize: function(){ - return this.getContentElement().measure(function(){ - return this.getSize(); - }); - }.bind(this), - error: function(){ this.fireEvent('error', arguments); }.bind(this), - fail: function(){ - var msg = Array.join(arguments, ' '); - throw new Error(msg); - }, - warn: function(){ - this.fireEvent('warn', arguments); - }.bind(this) - }); - }, + setPosition: function(obj){ + return this.setStyles(this.computePosition(obj)); + } - getDelegator: function(){ - return this.delegator; - }, +}); - setDelegator: function(delegator){ - if (!instanceOf(delegator, Delegator)) throw new Error('Behavior.setDelegator only accepts instances of Delegator.'); - this.delegator = delegator; - return this; - }, - getContentElement: function(){ - return this.options.container || document.body; - }, +[Document, Window].invoke('implement', { - //Applies all the behavior filters for an element. - //container - (element) an element to apply the filters registered with this Behavior instance to. - //force - (boolean; optional) passed through to applyFilter (see it for docs) - apply: function(container, force){ - this._getElements(container).each(function(element){ - var plugins = []; - element.getBehaviors().each(function(name){ - var filter = this.getFilter(name); - if (!filter){ - this.fireEvent('error', ['There is no filter registered with this name: ', name, element]); - } else { - var config = filter.config; - if (config.delay !== undefined){ - this.applyFilter.delay(filter.config.delay, this, [element, filter, force]); - } else if(config.delayUntil){ - this._delayFilterUntil(element, filter, force); - } else if(config.initializer){ - this._customInit(element, filter, force); - } else { - plugins.append(this.applyFilter(element, filter, force, true)); - } - } - }, this); - plugins.each(function(plugin){ plugin(); }); - }, this); - return this; - }, + getSize: function(){ + var doc = getCompatElement(this); + return {x: doc.clientWidth, y: doc.clientHeight}; + }, - _getElements: function(container){ - if (typeOf(this.options.selector) == 'function') return this.options.selector(container); - else return document.id(container).getElements(this.options.selector); - }, + getScroll: function(){ + var win = this.getWindow(), doc = getCompatElement(this); + return {x: win.pageXOffset || doc.scrollLeft, y: win.pageYOffset || doc.scrollTop}; + }, - //delays a filter until the event specified in filter.config.delayUntil is fired on the element - _delayFilterUntil: function(element, filter, force){ - var events = filter.config.delayUntil.split(','), - attached = {}, - inited = false; - var clear = function(){ - events.each(function(event){ - element.removeEvent(event, attached[event]); - }); - clear = function(){}; - }; - events.each(function(event){ - var init = function(e){ - clear(); - if (inited) return; - inited = true; - var setup = filter.setup; - filter.setup = function(element, api, _pluginResult){ - api.event = e; - return setup.apply(filter, [element, api, _pluginResult]); - }; - this.applyFilter(element, filter, force); - filter.setup = setup; - }.bind(this); - element.addEvent(event, init); - attached[event] = init; - }, this); - }, + getScrollSize: function(){ + var doc = getCompatElement(this), + min = this.getSize(), + body = this.getDocument().body; - //runs custom initiliazer defined in filter.config.initializer - _customInit: function(element, filter, force){ - var api = new this.API(element, filter.name); - api.runSetup = this.applyFilter.pass([element, filter, force], this); - filter.config.initializer(element, api); - }, + return {x: Math.max(doc.scrollWidth, body.scrollWidth, min.x), y: Math.max(doc.scrollHeight, body.scrollHeight, min.y)}; + }, - //Applies a specific behavior to a specific element. - //element - the element to which to apply the behavior - //filter - (object) a specific behavior filter, typically one registered with this instance or registered globally. - //force - (boolean; optional) apply the behavior to each element it matches, even if it was previously applied. Defaults to *false*. - //_returnPlugins - (boolean; optional; internal) if true, plugins are not rendered but instead returned as an array of functions - //_pluginTargetResult - (obj; optional internal) if this filter is a plugin for another, this is whatever that target filter returned - // (an instance of a class for example) - applyFilter: function(element, filter, force, _returnPlugins, _pluginTargetResult){ - var pluginsToReturn = []; - if (this.options.breakOnErrors){ - pluginsToReturn = this._applyFilter.apply(this, arguments); - } else { - try { - pluginsToReturn = this._applyFilter.apply(this, arguments); - } catch (e){ - this.fireEvent('error', ['Could not apply the behavior ' + filter.name, e]); - } - } - return _returnPlugins ? pluginsToReturn : this; - }, + getPosition: function(){ + return {x: 0, y: 0}; + }, - //see argument list above for applyFilter - _applyFilter: function(element, filter, force, _returnPlugins, _pluginTargetResult){ - var pluginsToReturn = []; - element = document.id(element); - //get the filters already applied to this element - var applied = getApplied(element); - //if this filter is not yet applied to the element, or we are forcing the filter - if (!applied[filter.name] || force){ - //if it was previously applied, garbage collect it - if (applied[filter.name]) applied[filter.name].cleanup(element); - var api = new this.API(element, filter.name); + getCoordinates: function(){ + var size = this.getSize(); + return {top: 0, left: 0, bottom: size.y, right: size.x, height: size.y, width: size.x}; + } - //deprecated - api.markForCleanup = filter.markForCleanup.bind(filter); - api.onCleanup = function(fn){ - filter.markForCleanup(element, fn); - }; +}); - if (filter.config.deprecated && this.options.enableDeprecation) api.deprecate(filter.config.deprecated); - if (filter.config.deprecateAsJSON && this.options.enableDeprecation) api.deprecate(filter.config.deprecatedAsJSON, true); +// private methods - //deal with requirements and defaults - if (filter.config.requireAs){ - api.requireAs(filter.config.requireAs); - } else if (filter.config.require){ - api.require.apply(api, Array.from(filter.config.require)); - } +var styleString = Element.getComputedStyle; - if (filter.config.defaults) api.setDefault(filter.config.defaults); +function styleNumber(element, style){ + return styleString(element, style).toInt() || 0; +} - //apply the filter - var result = filter.setup(element, api, _pluginTargetResult); - if (filter.config.returns && !instanceOf(result, filter.config.returns)){ - throw new Error("Filter " + filter.name + " did not return a valid instance."); - } - element.store('Behavior Filter result:' + filter.name, result); - //and mark it as having been previously applied - applied[filter.name] = filter; - //apply all the plugins for this filter - var plugins = this.getPlugins(filter.name); - if (plugins){ - for (var name in plugins){ - if (_returnPlugins){ - pluginsToReturn.push(this.applyFilter.pass([element, plugins[name], force, null, result], this)); - } else { - this.applyFilter(element, plugins[name], force, null, result); - } - } - } - } - return pluginsToReturn; - }, +function borderBox(element){ + return styleString(element, '-moz-box-sizing') == 'border-box'; +} - //given a name, returns a registered behavior - getFilter: function(name){ - return this._registered[name] || Behavior.getFilter(name); - }, +function topBorder(element){ + return styleNumber(element, 'border-top-width'); +} - getPlugins: function(name){ - return this._plugins[name] || Behavior._plugins[name]; - }, +function leftBorder(element){ + return styleNumber(element, 'border-left-width'); +} - //Garbage collects all applied filters for an element and its children. - //element - (*element*) container to cleanup - //ignoreChildren - (*boolean*; optional) if *true* only the element will be cleaned, otherwise the element and all the - // children with filters applied will be cleaned. Defaults to *false*. - cleanup: function(element, ignoreChildren){ - element = document.id(element); - var applied = getApplied(element); - for (var filter in applied){ - applied[filter].cleanup(element); - element.eliminate('Behavior Filter result:' + filter); - delete applied[filter]; - } - if (!ignoreChildren) this._getElements(element).each(this.cleanup, this); - return this; - } - - }); - - //Export these for use elsewhere (notabily: Delegator). - Behavior.getLog = getLog; - Behavior.PassMethods = PassMethods; +function isBody(element){ + return (/^(?:body|html)$/i).test(element.tagName); +} +function getCompatElement(element){ + var doc = element.getDocument(); + return (!doc.compatMode || doc.compatMode == 'CSS1Compat') ? doc.html : doc.body; +} - //Returns the applied behaviors for an element. - var getApplied = function(el){ - return el.retrieve('_appliedBehaviors', {}); - }; +})(); - //Registers a behavior filter. - //name - the name of the filter - //fn - a function that applies the filter to the given element - //overwrite - (boolean) if true, will overwrite existing filter if one exists; defaults to false. - var addFilter = function(name, fn, overwrite){ - if (!this._registered[name] || overwrite) this._registered[name] = new Behavior.Filter(name, fn); - else throw new Error('Could not add the Behavior filter "' + name +'" as a previous trigger by that same name exists.'); - }; +//aliases +Element.alias({position: 'setPosition'}); //compatability - var addFilters = function(obj, overwrite){ - for (var name in obj){ - addFilter.apply(this, [name, obj[name], overwrite]); - } - }; +[Window, Document, Element].invoke('implement', { - //Registers a behavior plugin - //filterName - (*string*) the filter (or plugin) this is a plugin for - //name - (*string*) the name of this plugin - //setup - a function that applies the filter to the given element - var addPlugin = function(filterName, name, setup, overwrite){ - if (!this._plugins[filterName]) this._plugins[filterName] = {}; - if (!this._plugins[filterName][name] || overwrite) this._plugins[filterName][name] = new Behavior.Filter(name, setup); - else throw new Error('Could not add the Behavior filter plugin "' + name +'" as a previous trigger by that same name exists.'); - }; + getHeight: function(){ + return this.getSize().y; + }, - var addPlugins = function(obj, overwrite){ - for (var name in obj){ - addPlugin.apply(this, [obj[name].fitlerName, obj[name].name, obj[name].setup], overwrite); - } - }; + getWidth: function(){ + return this.getSize().x; + }, - var setFilterDefaults = function(name, defaults){ - var filter = this.getFilter(name); - if (!filter.config.defaults) filter.config.defaults = {}; - Object.append(filter.config.defaults, defaults); - }; + getScrollTop: function(){ + return this.getScroll().y; + }, - //Add methods to the Behavior namespace for global registration. - Object.append(Behavior, { - _registered: {}, - _plugins: {}, - addGlobalFilter: addFilter, - addGlobalFilters: addFilters, - addGlobalPlugin: addPlugin, - addGlobalPlugins: addPlugins, - setFilterDefaults: setFilterDefaults, - getFilter: function(name){ - return this._registered[name]; - } - }); - //Add methods to the Behavior class for instance registration. - Behavior.implement({ - _registered: {}, - _plugins: {}, - addFilter: addFilter, - addFilters: addFilters, - addPlugin: addPlugin, - addPlugins: addPlugins, - setFilterDefaults: setFilterDefaults - }); + getScrollLeft: function(){ + return this.getScroll().x; + }, - //This class is an actual filter that, given an element, alters it with specific behaviors. - Behavior.Filter = new Class({ + getScrollHeight: function(){ + return this.getScrollSize().y; + }, - config: { - /** - returns: Foo, - require: ['req1', 'req2'], - //or - requireAs: { - req1: Boolean, - req2: Number, - req3: String - }, - defaults: { - opt1: false, - opt2: 2 - }, - //simple example: - setup: function(element, API){ - var kids = element.getElements(API.get('selector')); - //some validation still has to occur here - if (!kids.length) API.fail('there were no child elements found that match ', API.get('selector')); - if (kids.length < 2) API.warn("there weren't more than 2 kids that match", API.get('selector')); - var fooInstance = new Foo(kids, API.get('opt1', 'opt2')); - API.onCleanup(function(){ - fooInstance.destroy(); - }); - return fooInstance; - }, - delayUntil: 'mouseover', - //OR - delay: 100, - //OR - initializer: function(element, API){ - element.addEvent('mouseover', API.runSetup); //same as specifying event - //or - API.runSetup.delay(100); //same as specifying delay - //or something completely esoteric - var timer = (function(){ - if (element.hasClass('foo')){ - clearInterval(timer); - API.runSetup(); - } - }).periodical(100); - //or - API.addEvent('someBehaviorEvent', API.runSetup); - }); - */ - }, + getScrollWidth: function(){ + return this.getScrollSize().x; + }, - //Pass in an object with the following properties: - //name - the name of this filter - //setup - a function that applies the filter to the given element - initialize: function(name, setup){ - this.name = name; - if (typeOf(setup) == "function"){ - this.setup = setup; - } else { - Object.append(this.config, setup); - this.setup = this.config.setup; - } - this._cleanupFunctions = new Table(); - }, + getTop: function(){ + return this.getPosition().y; + }, - //Stores a garbage collection pointer for a specific element. - //Example: if your filter enhances all the inputs in the container - //you might have a function that removes that enhancement for garbage collection. - //You would mark each input matched with its own cleanup function. - //NOTE: this MUST be the element passed to the filter - the element with this filters - // name in its data-behavior property. I.E.: - //
- // - //
- //If this filter is FormValidator, you can mark the form for cleanup, but not, for example - //the input. Only elements that match this filter can be marked. - markForCleanup: function(element, fn){ - var functions = this._cleanupFunctions.get(element); - if (!functions) functions = []; - functions.include(fn); - this._cleanupFunctions.set(element, functions); - return this; - }, + getLeft: function(){ + return this.getPosition().x; + } - //Garbage collect a specific element. - //NOTE: this should be an element that has a data-behavior property that matches this filter. - cleanup: function(element){ - var marks = this._cleanupFunctions.get(element); - if (marks){ - marks.each(function(fn){ fn(); }); - this._cleanupFunctions.erase(element); - } - return this; - } +}); - }); - Behavior.elementDataProperty = 'behavior'; +// Begin: Source/More/More.js +/* +--- - Element.implement({ +script: More.js - addBehaviorFilter: function(name){ - return this.setData(Behavior.elementDataProperty, this.getBehaviors().include(name).join(' ')); - }, +name: More - removeBehaviorFilter: function(name){ - return this.setData(Behavior.elementDataProperty, this.getBehaviors().erase(name).join(' ')); - }, +description: MooTools More - getBehaviors: function(){ - var filters = this.getData(Behavior.elementDataProperty); - if (!filters) return []; - return filters.trim().split(spaceOrCommaRegex); - }, +license: MIT-style license - hasBehavior: function(name){ - return this.getBehaviors().contains(name); - }, +authors: + - Guillermo Rauch + - Thomas Aylott + - Scott Kyle + - Arian Stolwijk + - Tim Wienk + - Christoph Pojer + - Aaron Newton + - Jacob Thornton - getBehaviorResult: function(name){ - return this.retrieve('Behavior Filter result:' + name); - } +requires: + - Core/MooTools - }); +provides: [MooTools.More] +... +*/ -})(); +MooTools.More = { + version: '1.4.3.1dev', + build: '%build%' +}; -// Begin: Source/Delegator.js +// Begin: Source/Element/Element.Measure.js /* --- -name: Delegator -description: Allows for the registration of delegated events on a container. -requires: [Core/Element.Delegation, Core/Options, Core/Events, /Event.Mock, /Behavior] -provides: [Delegator] -... -*/ -(function(){ - var spaceOrCommaRegex = /\s*,\s*|\s+/g; +script: Element.Measure.js - window.Delegator = new Class({ +name: Element.Measure - Implements: [Options, Events, Behavior.PassMethods], +description: Extends the Element native object to include methods useful in measuring dimensions. - options: { - // breakOnErrors: false, - getBehavior: function(){}, - onError: Behavior.getLog('error'), - onWarn: Behavior.getLog('warn') - }, - - initialize: function(options){ - this.setOptions(options); - this._bound = { - eventHandler: this._eventHandler.bind(this) - }; - Delegator._instances.push(this); - Object.each(Delegator._triggers, function(trigger){ - this._eventTypes.combine(trigger.types); - }, this); - this.API = new Class({ Extends: BehaviorAPI }); - this.passMethods({ - addEvent: this.addEvent.bind(this), - removeEvent: this.removeEvent.bind(this), - addEvents: this.addEvents.bind(this), - removeEvents: this.removeEvents.bind(this), - fireEvent: this.fireEvent.bind(this), - attach: this.attach.bind(this), - trigger: this.trigger.bind(this), - error: function(){ this.fireEvent('error', arguments); }.bind(this), - fail: function(){ - var msg = Array.join(arguments, ' '); - throw new Error(msg); - }, - warn: function(){ - this.fireEvent('warn', arguments); - }.bind(this), - getBehavior: function(){ - return this.options.getBehavior(); - }.bind(this) - }); - - this.bindToBehavior(this.options.getBehavior()); - }, +credits: "Element.measure / .expose methods by Daniel Steigerwald License: MIT-style license. Copyright: Copyright (c) 2008 Daniel Steigerwald, daniel.steigerwald.cz" - bindToBehavior: function(behavior){ - if (!behavior) return; - this.unbindFromBehavior(); - this._behavior = behavior; - if (!this._behaviorEvents){ - var self = this; - this._behaviorEvents = { - destroyDom: function(elements){ - Array.from(elements).each(function(element){ - self._behavior.cleanup(element); - self._behavior.fireEvent('destroyDom', element); - }); - }, - ammendDom: function(container){ - self._behavior.apply(container); - self._behavior.fireEvent('ammendDom', container); - } - }; - } - this.addEvents(this._behaviorEvents); - }, +license: MIT-style license - getBehavior: function(){ - return this._behavior; - }, +authors: + - Aaron Newton - unbindFromBehavior: function(){ - if (this._behaviorEvents && this._behavior){ - this._behavior.removeEvents(this._behaviorEvents); - delete this._behavior; - } - }, +requires: + - Core/Element.Style + - Core/Element.Dimensions + - /MooTools.More - attach: function(target, _method){ - _method = _method || 'addEvent'; - target = document.id(target); - if ((_method == 'addEvent' && this._attachedTo.contains(target)) || - (_method == 'removeEvent') && !this._attachedTo.contains(target)) return this; - this._eventTypes.each(function(event){ - target[_method](event + ':relay([data-trigger])', this._bound.eventHandler); - }, this); - this._attachedTo.push(target); - return this; - }, +provides: [Element.Measure] - detach: function(target){ - if (target){ - this.attach(target, 'removeEvent'); - } else { - this._attachedTo.each(this.detach, this); - } - return this; - }, +... +*/ - trigger: function(name, element, event){ - var e = event; - if (!e || typeOf(e) == "string") e = new Event.Mock(element, e); +(function(){ - var trigger = this.getTrigger(name); - if (trigger && (!event || (event && trigger.types.contains(e.type)))) { - if (this.options.breakOnErrors){ - this._trigger(trigger, element, e); - } else { - try { - this._trigger(trigger, element, e); - } catch(error) { - this.fireEvent('error', ['Could not apply the trigger', name, error]); - } - } - } - return this; - }, +var getStylesList = function(styles, planes){ + var list = []; + Object.each(planes, function(directions){ + Object.each(directions, function(edge){ + styles.each(function(style){ + list.push(style + '-' + edge + (style == 'border' ? '-width' : '')); + }); + }); + }); + return list; +}; - getTrigger: function(name){ - return this._triggers[name] || Delegator._triggers[name]; - }, +var calculateEdgeSize = function(edge, styles){ + var total = 0; + Object.each(styles, function(value, style){ + if (style.test(edge)) total = total + value.toInt(); + }); + return total; +}; - addEventTypes: function(triggerName, types){ - this.getTrigger(triggerName).types.combine(Array.from(types)); - return this; - }, +var isVisible = function(el){ + return !!(!el || el.offsetHeight || el.offsetWidth); +}; - /****************** - * PRIVATE METHODS - ******************/ - _trigger: function(trigger, element, event){ - var api = new this.API(element, trigger.name); - if (trigger.requireAs){ - api.requireAs(trigger.requireAs); - } else if (trigger.require){ - api.require.apply(api, Array.from(trigger.require)); - } if (trigger.defaults){ - api.setDefault(trigger.defaults); - } - trigger.handler.apply(this, [event, element, api]); - this.fireEvent('trigger', [trigger, element, event]); - }, +Element.implement({ - _eventHandler: function(event, target){ - var triggers = target.getTriggers(); - if (triggers.contains('Stop')) event.stop(); - if (triggers.contains('PreventDefault')) event.preventDefault(); - triggers.each(function(trigger){ - if (trigger != "Stop" && trigger != "PreventDefault") this.trigger(trigger, target, event); - }, this); - }, + measure: function(fn){ + if (isVisible(this)) return fn.call(this); + var parent = this.getParent(), + toMeasure = []; + while (!isVisible(parent) && parent != document.body){ + toMeasure.push(parent.expose()); + parent = parent.getParent(); + } + var restore = this.expose(), + result = fn.call(this); + restore(); + toMeasure.each(function(restore){ + restore(); + }); + return result; + }, - _onRegister: function(eventTypes){ - eventTypes.each(function(eventType){ - if (!this._eventTypes.contains(eventType)){ - this._attachedTo.each(function(element){ - element.addEvent(eventType + ':relay([data-trigger])', this._bound.eventHandler); - }, this); - } - this._eventTypes.include(eventType); - }, this); - }, + expose: function(){ + if (this.getStyle('display') != 'none') return function(){}; + var before = this.style.cssText; + this.setStyles({ + display: 'block', + position: 'absolute', + visibility: 'hidden' + }); + return function(){ + this.style.cssText = before; + }.bind(this); + }, - _attachedTo: [], - _eventTypes: [], - _triggers: {} + getDimensions: function(options){ + options = Object.merge({computeSize: false}, options); + var dim = {x: 0, y: 0}; - }); + var getSize = function(el, options){ + return (options.computeSize) ? el.getComputedSize(options) : el.getSize(); + }; - Delegator._triggers = {}; - Delegator._instances = []; - Delegator._onRegister = function(eventType){ - this._instances.each(function(instance){ - instance._onRegister(eventType); - }); - }; + var parent = this.getParent('body'); - Delegator.register = function(eventTypes, name, handler, overwrite /** or eventType, obj, overwrite */){ - eventTypes = Array.from(eventTypes); - if (typeOf(name) == "object"){ - var obj = name; - for (name in obj){ - this.register.apply(this, [eventTypes, name, obj[name], handler]); - } - return this; - } - if (!this._triggers[name] || overwrite){ - if (typeOf(handler) == "function"){ - handler = { - handler: handler - }; - } - handler.types = eventTypes; - handler.name = name; - this._triggers[name] = handler; - this._onRegister(eventTypes); - } else { - throw new Error('Could add the trigger "' + name +'" as a previous trigger by that same name exists.'); + if (parent && this.getStyle('display') == 'none'){ + dim = this.measure(function(){ + return getSize(this, options); + }); + } else if (parent){ + try { //safari sometimes crashes here, so catch it + dim = getSize(this, options); + }catch(e){} } - return this; - }; - Delegator.getTrigger = function(name){ - return this._triggers[name]; - }; + return Object.append(dim, (dim.x || dim.x === 0) ? { + width: dim.x, + height: dim.y + } : { + x: dim.width, + y: dim.height + } + ); + }, - Delegator.addEventTypes = function(triggerName, types){ - this.getTrigger(triggerName).types.combine(Array.from(types)); - return this; - }; + getComputedSize: function(options){ + //<1.2compat> + //legacy support for my stupid spelling error + if (options && options.plains) options.planes = options.plains; + // + options = Object.merge({ + styles: ['padding','border'], + planes: { + height: ['top','bottom'], + width: ['left','right'] + }, + mode: 'both' + }, options); - Delegator.implement('register', Delegator.register); + var styles = {}, + size = {width: 0, height: 0}, + dimensions; - Element.implement({ + if (options.mode == 'vertical'){ + delete size.width; + delete options.planes.width; + } else if (options.mode == 'horizontal'){ + delete size.height; + delete options.planes.height; + } - addTrigger: function(name){ - return this.setData('trigger', this.getTriggers().include(name).join(' ')); - }, + getStylesList(options.styles, options.planes).each(function(style){ + styles[style] = this.getStyle(style).toInt(); + }, this); - removeTrigger: function(name){ - return this.setData('trigger', this.getTriggers().erase(name).join(' ')); - }, + Object.each(options.planes, function(edges, plane){ - getTriggers: function(){ - var triggers = this.getData('trigger'); - if (!triggers) return []; - return triggers.trim().split(spaceOrCommaRegex); - }, + var capitalized = plane.capitalize(), + style = this.getStyle(plane); - hasTrigger: function(name){ - return this.getTriggers().contains(name); - } + if (style == 'auto' && !dimensions) dimensions = this.getDimensions(); - }); + style = styles[plane] = (style == 'auto') ? dimensions[plane] : style.toInt(); + size['total' + capitalized] = style; + + edges.each(function(edge){ + var edgesize = calculateEdgeSize(edge, styles); + size['computed' + edge.capitalize()] = edgesize; + size['total' + capitalized] += edgesize; + }); + + }, this); + + return Object.append(size, styles); + } + +}); })(); -// Begin: Source/Fx/Fx.js + +// Begin: Source/Element/Element.Position.js /* --- -name: Fx +script: Element.Position.js -description: Contains the basic animation logic to be extended by all other Fx Classes. +name: Element.Position -license: MIT-style license. +description: Extends the Element native object to include methods useful positioning elements relative to others. -requires: [Chain, Events, Options] +license: MIT-style license -provides: Fx +authors: + - Aaron Newton + - Jacob Thornton + +requires: + - Core/Options + - Core/Element.Dimensions + - Element.Measure + +provides: [Element.Position] ... */ -(function(){ +(function(original){ -var Fx = this.Fx = new Class({ +var local = Element.Position = { - Implements: [Chain, Events, Options], + options: {/* + edge: false, + returnPos: false, + minimum: {x: 0, y: 0}, + maximum: {x: 0, y: 0}, + relFixedPosition: false, + ignoreMargins: false, + ignoreScroll: false, + allowNegative: false,*/ + relativeTo: document.body, + position: { + x: 'center', //left, center, right + y: 'center' //top, center, bottom + }, + offset: {x: 0, y: 0} + }, - options: { - /* - onStart: nil, - onCancel: nil, - onComplete: nil, - */ - fps: 60, - unit: false, - duration: 500, - frames: null, - frameSkip: true, - link: 'ignore' + getOptions: function(element, options){ + options = Object.merge({}, local.options, options); + local.setPositionOption(options); + local.setEdgeOption(options); + local.setOffsetOption(element, options); + local.setDimensionsOption(element, options); + return options; }, - initialize: function(options){ - this.subject = this.subject || this; - this.setOptions(options); + setPositionOption: function(options){ + options.position = local.getCoordinateFromValue(options.position); }, - getTransition: function(){ - return function(p){ - return -(Math.cos(Math.PI * p) - 1) / 2; + setEdgeOption: function(options){ + var edgeOption = local.getCoordinateFromValue(options.edge); + options.edge = edgeOption ? edgeOption : + (options.position.x == 'center' && options.position.y == 'center') ? {x: 'center', y: 'center'} : + {x: 'left', y: 'top'}; + }, + + setOffsetOption: function(element, options){ + var parentOffset = {x: 0, y: 0}, + offsetParent = element.measure(function(){ + return document.id(this.getOffsetParent()); + }), + parentScroll = offsetParent.getScroll(); + + if (!offsetParent || offsetParent == element.getDocument().body) return; + parentOffset = offsetParent.measure(function(){ + var position = this.getPosition(); + if (this.getStyle('position') == 'fixed'){ + var scroll = window.getScroll(); + position.x += scroll.x; + position.y += scroll.y; + } + return position; + }); + + options.offset = { + parentPositioned: offsetParent != document.id(options.relativeTo), + x: options.offset.x - parentOffset.x + parentScroll.x, + y: options.offset.y - parentOffset.y + parentScroll.y }; }, - step: function(now){ - if (this.options.frameSkip){ - var diff = (this.time != null) ? (now - this.time) : 0, frames = diff / this.frameInterval; - this.time = now; - this.frame += frames; - } else { - this.frame++; + setDimensionsOption: function(element, options){ + options.dimensions = element.getDimensions({ + computeSize: true, + styles: ['padding', 'border', 'margin'] + }); + }, + + getPosition: function(element, options){ + var position = {}; + options = local.getOptions(element, options); + var relativeTo = document.id(options.relativeTo) || document.body; + + local.setPositionCoordinates(options, position, relativeTo); + if (options.edge) local.toEdge(position, options); + + var offset = options.offset; + position.left = ((position.x >= 0 || offset.parentPositioned || options.allowNegative) ? position.x : 0).toInt(); + position.top = ((position.y >= 0 || offset.parentPositioned || options.allowNegative) ? position.y : 0).toInt(); + + local.toMinMax(position, options); + + if (options.relFixedPosition || relativeTo.getStyle('position') == 'fixed') local.toRelFixedPosition(relativeTo, position); + if (options.ignoreScroll) local.toIgnoreScroll(relativeTo, position); + if (options.ignoreMargins) local.toIgnoreMargins(position, options); + + position.left = Math.ceil(position.left); + position.top = Math.ceil(position.top); + delete position.x; + delete position.y; + + return position; + }, + + setPositionCoordinates: function(options, position, relativeTo){ + var offsetY = options.offset.y, + offsetX = options.offset.x, + calc = (relativeTo == document.body) ? window.getScroll() : relativeTo.getPosition(), + top = calc.y, + left = calc.x, + winSize = window.getSize(); + + switch(options.position.x){ + case 'left': position.x = left + offsetX; break; + case 'right': position.x = left + offsetX + relativeTo.offsetWidth; break; + default: position.x = left + ((relativeTo == document.body ? winSize.x : relativeTo.offsetWidth) / 2) + offsetX; break; } - if (this.frame < this.frames){ - var delta = this.transition(this.frame / this.frames); - this.set(this.compute(this.from, this.to, delta)); - } else { - this.frame = this.frames; - this.set(this.compute(this.from, this.to, 1)); - this.stop(); + switch(options.position.y){ + case 'top': position.y = top + offsetY; break; + case 'bottom': position.y = top + offsetY + relativeTo.offsetHeight; break; + default: position.y = top + ((relativeTo == document.body ? winSize.y : relativeTo.offsetHeight) / 2) + offsetY; break; } }, - set: function(now){ - return now; + toMinMax: function(position, options){ + var xy = {left: 'x', top: 'y'}, value; + ['minimum', 'maximum'].each(function(minmax){ + ['left', 'top'].each(function(lr){ + value = options[minmax] ? options[minmax][xy[lr]] : null; + if (value != null && ((minmax == 'minimum') ? position[lr] < value : position[lr] > value)) position[lr] = value; + }); + }); }, - compute: function(from, to, delta){ - return Fx.compute(from, to, delta); + toRelFixedPosition: function(relativeTo, position){ + var winScroll = window.getScroll(); + position.top += winScroll.y; + position.left += winScroll.x; }, - check: function(){ - if (!this.isRunning()) return true; - switch (this.options.link){ - case 'cancel': this.cancel(); return true; - case 'chain': this.chain(this.caller.pass(arguments, this)); return false; - } - return false; + toIgnoreScroll: function(relativeTo, position){ + var relScroll = relativeTo.getScroll(); + position.top -= relScroll.y; + position.left -= relScroll.x; }, - start: function(from, to){ - if (!this.check(from, to)) return this; - this.from = from; - this.to = to; - this.frame = (this.options.frameSkip) ? 0 : -1; - this.time = null; - this.transition = this.getTransition(); - var frames = this.options.frames, fps = this.options.fps, duration = this.options.duration; - this.duration = Fx.Durations[duration] || duration.toInt(); - this.frameInterval = 1000 / fps; - this.frames = frames || Math.round(this.duration / this.frameInterval); - this.fireEvent('start', this.subject); - pushInstance.call(this, fps); - return this; - }, + toIgnoreMargins: function(position, options){ + position.left += options.edge.x == 'right' + ? options.dimensions['margin-right'] + : (options.edge.x != 'center' + ? -options.dimensions['margin-left'] + : -options.dimensions['margin-left'] + ((options.dimensions['margin-right'] + options.dimensions['margin-left']) / 2)); - stop: function(){ - if (this.isRunning()){ - this.time = null; - pullInstance.call(this, this.options.fps); - if (this.frames == this.frame){ - this.fireEvent('complete', this.subject); - if (!this.callChain()) this.fireEvent('chainComplete', this.subject); - } else { - this.fireEvent('stop', this.subject); - } - } - return this; + position.top += options.edge.y == 'bottom' + ? options.dimensions['margin-bottom'] + : (options.edge.y != 'center' + ? -options.dimensions['margin-top'] + : -options.dimensions['margin-top'] + ((options.dimensions['margin-bottom'] + options.dimensions['margin-top']) / 2)); }, - cancel: function(){ - if (this.isRunning()){ - this.time = null; - pullInstance.call(this, this.options.fps); - this.frame = this.frames; - this.fireEvent('cancel', this.subject).clearChain(); + toEdge: function(position, options){ + var edgeOffset = {}, + dimensions = options.dimensions, + edge = options.edge; + + switch(edge.x){ + case 'left': edgeOffset.x = 0; break; + case 'right': edgeOffset.x = -dimensions.x - dimensions.computedRight - dimensions.computedLeft; break; + // center + default: edgeOffset.x = -(Math.round(dimensions.totalWidth / 2)); break; } - return this; - }, - pause: function(){ - if (this.isRunning()){ - this.time = null; - pullInstance.call(this, this.options.fps); + switch(edge.y){ + case 'top': edgeOffset.y = 0; break; + case 'bottom': edgeOffset.y = -dimensions.y - dimensions.computedTop - dimensions.computedBottom; break; + // center + default: edgeOffset.y = -(Math.round(dimensions.totalHeight / 2)); break; } - return this; - }, - resume: function(){ - if ((this.frame < this.frames) && !this.isRunning()) pushInstance.call(this, this.options.fps); - return this; + position.x += edgeOffset.x; + position.y += edgeOffset.y; }, - isRunning: function(){ - var list = instances[this.options.fps]; - return list && list.contains(this); - } + getCoordinateFromValue: function(option){ + if (typeOf(option) != 'string') return option; + option = option.toLowerCase(); -}); + return { + x: option.test('left') ? 'left' + : (option.test('right') ? 'right' : 'center'), + y: option.test(/upper|top/) ? 'top' + : (option.test('bottom') ? 'bottom' : 'center') + }; + } -Fx.compute = function(from, to, delta){ - return (to - from) * delta + from; }; -Fx.Durations = {'short': 250, 'normal': 500, 'long': 1000}; - -// global timers +Element.implement({ -var instances = {}, timers = {}; + position: function(options){ + if (options && (options.x != null || options.y != null)){ + return (original ? original.apply(this, arguments) : this); + } + var position = this.setStyle('position', 'absolute').calculatePosition(options); + return (options && options.returnPos) ? position : this.setStyles(position); + }, -var loop = function(){ - var now = Date.now(); - for (var i = this.length; i--;){ - var instance = this[i]; - if (instance) instance.step(now); + calculatePosition: function(options){ + return local.getPosition(this, options); } -}; - -var pushInstance = function(fps){ - var list = instances[fps] || (instances[fps] = []); - list.push(this); - if (!timers[fps]) timers[fps] = loop.periodical(Math.round(1000 / fps), list); -}; -var pullInstance = function(fps){ - var list = instances[fps]; - if (list){ - list.erase(this); - if (!list.length && timers[fps]){ - delete instances[fps]; - timers[fps] = clearInterval(timers[fps]); - } - } -}; +}); -})(); +})(Element.prototype.position); -// Begin: Source/Element/Element.Style.js +// Begin: Source/Element/Element.Shortcuts.js /* --- -name: Element.Style +script: Element.Shortcuts.js -description: Contains methods for interacting with the styles of Elements in a fashionable way. +name: Element.Shortcuts -license: MIT-style license. +description: Extends the Element native object to include some shortcut methods. -requires: Element +license: MIT-style license -provides: Element.Style +authors: + - Aaron Newton + +requires: + - Core/Element.Style + - /MooTools.More + +provides: [Element.Shortcuts] ... */ -(function(){ - -var html = document.html; +Element.implement({ -Element.Properties.styles = {set: function(styles){ - this.setStyles(styles); -}}; + isDisplayed: function(){ + return this.getStyle('display') != 'none'; + }, -var hasOpacity = (html.style.opacity != null), - hasFilter = (html.style.filter != null), - reAlpha = /alpha\(opacity=([\d.]+)\)/i; + isVisible: function(){ + var w = this.offsetWidth, + h = this.offsetHeight; + return (w == 0 && h == 0) ? false : (w > 0 && h > 0) ? true : this.style.display != 'none'; + }, -var setVisibility = function(element, opacity){ - element.store('$opacity', opacity); - element.style.visibility = opacity > 0 ? 'visible' : 'hidden'; -}; + toggle: function(){ + return this[this.isDisplayed() ? 'hide' : 'show'](); + }, -var setOpacity = (hasOpacity ? function(element, opacity){ - element.style.opacity = opacity; -} : (hasFilter ? function(element, opacity){ - if (!element.currentStyle || !element.currentStyle.hasLayout) element.style.zoom = 1; - opacity = (opacity * 100).limit(0, 100).round(); - opacity = (opacity == 100) ? '' : 'alpha(opacity=' + opacity + ')'; - var filter = element.style.filter || element.getComputedStyle('filter') || ''; - element.style.filter = reAlpha.test(filter) ? filter.replace(reAlpha, opacity) : filter + opacity; -} : setVisibility)); + hide: function(){ + var d; + try { + //IE fails here if the element is not in the dom + d = this.getStyle('display'); + } catch(e){} + if (d == 'none') return this; + return this.store('element:_originalDisplay', d || '').setStyle('display', 'none'); + }, -var getOpacity = (hasOpacity ? function(element){ - var opacity = element.style.opacity || element.getComputedStyle('opacity'); - return (opacity == '') ? 1 : opacity.toFloat(); -} : (hasFilter ? function(element){ - var filter = (element.style.filter || element.getComputedStyle('filter')), - opacity; - if (filter) opacity = filter.match(reAlpha); - return (opacity == null || filter == null) ? 1 : (opacity[1] / 100); -} : function(element){ - var opacity = element.retrieve('$opacity'); - if (opacity == null) opacity = (element.style.visibility == 'hidden' ? 0 : 1); - return opacity; -})); + show: function(display){ + if (!display && this.isDisplayed()) return this; + display = display || this.retrieve('element:_originalDisplay') || 'block'; + return this.setStyle('display', (display == 'none') ? 'block' : display); + }, -var floatName = (html.style.cssFloat == null) ? 'styleFloat' : 'cssFloat'; + swapClass: function(remove, add){ + return this.removeClass(remove).addClass(add); + } -Element.implement({ +}); - getComputedStyle: function(property){ - if (this.currentStyle) return this.currentStyle[property.camelCase()]; - var defaultView = Element.getDocument(this).defaultView, - computed = defaultView ? defaultView.getComputedStyle(this, null) : null; - return (computed) ? computed.getPropertyValue((property == floatName) ? 'float' : property.hyphenate()) : null; - }, +Document.implement({ - setStyle: function(property, value){ - if (property == 'opacity'){ - setOpacity(this, parseFloat(value)); - return this; - } - property = (property == 'float' ? floatName : property).camelCase(); - if (typeOf(value) != 'string'){ - var map = (Element.Styles[property] || '@').split(' '); - value = Array.from(value).map(function(val, i){ - if (!map[i]) return ''; - return (typeOf(val) == 'number') ? map[i].replace('@', Math.round(val)) : val; - }).join(' '); - } else if (value == String(Number(value))){ - value = Math.round(value); + clearSelection: function(){ + if (window.getSelection){ + var selection = window.getSelection(); + if (selection && selection.removeAllRanges) selection.removeAllRanges(); + } else if (document.selection && document.selection.empty){ + try { + //IE fails here if selected element is not in dom + document.selection.empty(); + } catch(e){} } - this.style[property] = value; - return this; - }, + } - getStyle: function(property){ - if (property == 'opacity') return getOpacity(this); - property = (property == 'float' ? floatName : property).camelCase(); - var result = this.style[property]; - if (!result || property == 'zIndex'){ - result = []; - for (var style in Element.ShortStyles){ - if (property != style) continue; - for (var s in Element.ShortStyles[style]) result.push(this.getStyle(s)); - return result.join(' '); - } - result = this.getComputedStyle(property); - } - if (result){ - result = String(result); - var color = result.match(/rgba?\([\d\s,]+\)/); - if (color) result = result.replace(color[0], color[0].rgbToHex()); +}); + + +// Begin: Source/Utilities/Table.js +/* +--- +name: Table +description: LUA-Style table implementation. +license: MIT-style license +authors: + - Valerio Proietti +requires: [Core/Array] +provides: [Table] +... +*/ + +(function(){ + +var Table = this.Table = function(){ + + this.length = 0; + var keys = [], + values = []; + + this.set = function(key, value){ + var index = keys.indexOf(key); + if (index == -1){ + var length = keys.length; + keys[length] = key; + values[length] = value; + this.length++; + } else { + values[index] = value; + } + return this; + }; + + this.get = function(key){ + var index = keys.indexOf(key); + return (index == -1) ? null : values[index]; + }; + + this.erase = function(key){ + var index = keys.indexOf(key); + if (index != -1){ + this.length--; + keys.splice(index, 1); + return values.splice(index, 1)[0]; + } + return null; + }; + + this.each = this.forEach = function(fn, bind){ + for (var i = 0, l = this.length; i < l; i++) fn.call(bind, keys[i], values[i], this); + }; + +}; + +if (this.Type) new Type('Table', Table); + +})(); + + +// Begin: Source/Utilities/JSON.js +/* +--- + +name: JSON + +description: JSON encoder and decoder. + +license: MIT-style license. + +SeeAlso: + +requires: [Array, String, Number, Function] + +provides: JSON + +... +*/ + +if (typeof JSON == 'undefined') this.JSON = {}; + +//<1.2compat> + +JSON = new Hash({ + stringify: JSON.stringify, + parse: JSON.parse +}); + +// + +(function(){ + +var special = {'\b': '\\b', '\t': '\\t', '\n': '\\n', '\f': '\\f', '\r': '\\r', '"' : '\\"', '\\': '\\\\'}; + +var escape = function(chr){ + return special[chr] || '\\u' + ('0000' + chr.charCodeAt(0).toString(16)).slice(-4); +}; + +JSON.validate = function(string){ + string = string.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g, '@'). + replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g, ']'). + replace(/(?:^|:|,)(?:\s*\[)+/g, ''); + + return (/^[\],:{}\s]*$/).test(string); +}; + +JSON.encode = JSON.stringify ? function(obj){ + return JSON.stringify(obj); +} : function(obj){ + if (obj && obj.toJSON) obj = obj.toJSON(); + + switch (typeOf(obj)){ + case 'string': + return '"' + obj.replace(/[\x00-\x1f\\"]/g, escape) + '"'; + case 'array': + return '[' + obj.map(JSON.encode).clean() + ']'; + case 'object': case 'hash': + var string = []; + Object.each(obj, function(value, key){ + var json = JSON.encode(value); + if (json) string.push(JSON.encode(key) + ':' + json); + }); + return '{' + string + '}'; + case 'number': case 'boolean': return '' + obj; + case 'null': return 'null'; + } + + return null; +}; + +JSON.decode = function(string, secure){ + if (!string || typeOf(string) != 'string') return null; + + if (secure || JSON.secure){ + if (JSON.parse) return JSON.parse(string); + if (!JSON.validate(string)) throw new Error('JSON could not decode the input; security is enabled and the value is not secure.'); + } + + return eval('(' + string + ')'); +}; + +})(); + + +// Begin: Source/Element.Data.js +/* +--- +name: Element.Data +description: Stores data in HTML5 data properties +provides: [Element.Data] +requires: [Core/Element, Core/JSON] +script: Element.Data.js + +... +*/ +(function(){ + + JSON.isSecure = function(string){ + //this verifies that the string is parsable JSON and not malicious (borrowed from JSON.js in MooTools, which in turn borrowed it from Crockford) + //this version is a little more permissive, as it allows single quoted attributes because forcing the use of double quotes + //is a pain when this stuff is used as HTML properties + return (/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(string.replace(/\\./g, '@').replace(/"[^"\\\n\r]*"/g, '').replace(/'[^'\\\n\r]*'/g, '')); + }; + + Element.implement({ + /* + sets an HTML5 data property. + arguments: + name - (string) the data name to store; will be automatically prefixed with 'data-'. + value - (string, number) the value to store. + */ + setData: function(name, value){ + return this.set('data-' + name.hyphenate(), value); + }, + + getData: function(name, defaultValue){ + var value = this.get('data-' + name.hyphenate()); + if (value != undefined){ + return value; + } else if (defaultValue != undefined){ + this.setData(name, defaultValue); + return defaultValue; + } + }, + + /* + arguments: + name - (string) the data name to store; will be automatically prefixed with 'data-' + value - (string, array, or object) if an object or array the object will be JSON encoded; otherwise stored as provided. + */ + setJSONData: function(name, value){ + return this.setData(name, JSON.encode(value)); + }, + + /* + retrieves a property from HTML5 data property you specify + + arguments: + name - (retrieve) the data name to store; will be automatically prefixed with 'data-' + strict - (boolean) if true, will set the JSON.decode's secure flag to true; otherwise the value is still tested but allows single quoted attributes. + defaultValue - (string, array, or object) the value to set if no value is found (see storeData above) + */ + getJSONData: function(name, strict, defaultValue){ + var value = this.get('data-' + name); + if (value != undefined){ + if (value && JSON.isSecure(value)) { + return JSON.decode(value, strict); + } else { + return value; + } + } else if (defaultValue != undefined){ + this.setJSONData(name, defaultValue); + return defaultValue; + } + } + + }); + +})(); + +// Begin: Source/BehaviorAPI.js +/* +--- +name: BehaviorAPI +description: HTML getters for Behavior's API model. +requires: [Core/Class, /Element.Data] +provides: [BehaviorAPI] +... +*/ + + +(function(){ + //see Docs/BehaviorAPI.md for documentation of public methods. + + var reggy = /[^a-z0-9\-]/gi, + dots = /\./g; + + window.BehaviorAPI = new Class({ + element: null, + prefix: '', + defaults: {}, + + initialize: function(element, prefix){ + this.element = element; + this.prefix = prefix.toLowerCase().replace(dots, '-').replace(reggy, ''); + }, + + /****************** + * PUBLIC METHODS + ******************/ + + get: function(/* name[, name, name, etc] */){ + if (arguments.length > 1) return this._getObj(Array.from(arguments)); + return this._getValue(arguments[0]); + }, + + getAs: function(/*returnType, name, defaultValue OR {name: returnType, name: returnType, etc}*/){ + if (typeOf(arguments[0]) == 'object') return this._getValuesAs.apply(this, arguments); + return this._getValueAs.apply(this, arguments); + }, + + require: function(/* name[, name, name, etc] */){ + for (var i = 0; i < arguments.length; i++){ + if (this._getValue(arguments[i]) == undefined) throw new Error('Could not retrieve ' + this.prefix + '-' + arguments[i] + ' option from element.'); + } + return this; + }, + + requireAs: function(returnType, name /* OR {name: returnType, name: returnType, etc}*/){ + var val; + if (typeOf(arguments[0]) == 'object'){ + for (var objName in arguments[0]){ + val = this._getValueAs(arguments[0][objName], objName); + if (val === undefined || val === null) throw new Error("Could not retrieve " + this.prefix + '-' + objName + " option from element."); + } + } else { + val = this._getValueAs(returnType, name); + if (val === undefined || val === null) throw new Error("Could not retrieve " + this.prefix + '-' + name + " option from element."); + } + return this; + }, + + setDefault: function(name, value /* OR {name: value, name: value, etc }*/){ + if (typeOf(arguments[0]) == 'object'){ + for (var objName in arguments[0]){ + this.setDefault(objName, arguments[0][objName]); + } + return; + } + name = name.camelCase(); + this.defaults[name] = value; + if (this._getValue(name) == null){ + var options = this._getOptions(); + options[name] = value; + } + return this; + }, + + refreshAPI: function(){ + delete this.options; + this.setDefault(this.defaults); + return; + }, + + /****************** + * PRIVATE METHODS + ******************/ + + //given an array of names, returns an object of key/value pairs for each name + _getObj: function(names){ + var obj = {}; + names.each(function(name){ + var value = this._getValue(name); + if (value !== undefined) obj[name] = value; + }, this); + return obj; + }, + //gets the data-behaviorname-options object and parses it as JSON + _getOptions: function(){ + try { + if (!this.options){ + var options = this.element.getData(this.prefix + '-options', '{}'); + if (options === "") return this.options = {}; + if (options && options.substring(0,1) != '{') options = '{' + options + '}'; + var isSecure = JSON.isSecure(options); + if (!isSecure) throw new Error('warning, options value for element is not parsable, check your JSON format for quotes, etc.'); + this.options = isSecure ? JSON.decode(options) : {}; + for (option in this.options) { + this.options[option.camelCase()] = this.options[option]; + } + } + } catch (e){ + throw new Error('Could not get options from element; check your syntax. ' + this.prefix + '-options: "' + this.element.getData(this.prefix + '-options', '{}') + '"'); + } + return this.options; + }, + //given a name (string) returns the value for it + _getValue: function(name){ + name = name.camelCase(); + var options = this._getOptions(); + if (!options.hasOwnProperty(name)){ + var inline = this.element.getData(this.prefix + '-' + name.hyphenate()); + if (inline) options[name] = inline; + } + return options[name]; + }, + //given a Type and a name (string) returns the value for it coerced to that type if possible + //else returns the defaultValue or null + _getValueAs: function(returnType, name, defaultValue){ + var value = this._getValue(name); + if (value == null || value == undefined) return defaultValue; + var coerced = this._coerceFromString(returnType, value); + if (coerced == null) throw new Error("Could not retrieve value '" + name + "' as the specified type. Its value is: " + value); + return coerced; + }, + //given an object of name/Type pairs, returns those as an object of name/value (as specified Type) pairs + _getValuesAs: function(obj){ + var returnObj = {}; + for (var name in obj){ + returnObj[name] = this._getValueAs(obj[name], name); + } + return returnObj; + }, + //attempts to run a value through the JSON parser. If the result is not of that type returns null. + _coerceFromString: function(toType, value){ + if (typeOf(value) == 'string' && toType != String){ + if (JSON.isSecure(value)) value = JSON.decode(value); + } + if (instanceOf(value, toType)) return value; + return null; + } + }); + +})(); + +// Begin: Source/Behavior.js +/* +--- +name: Behavior +description: Auto-instantiates widgets/classes based on parsed, declarative HTML. +requires: [Core/Class.Extras, Core/Element.Event, Core/Selectors, More/Table, /Element.Data, /BehaviorAPI] +provides: [Behavior] +... +*/ + +(function(){ + + var getLog = function(method){ + return function(){ + if (window.console && console[method]){ + if(console[method].apply) console[method].apply(console, arguments); + else console[method](Array.from(arguments).join(' ')); + } + }; + }; + + var PassMethods = new Class({ + //pass a method pointer through to a filter + //by default the methods for add/remove events are passed to the filter + //pointed to this instance of behavior. you could use this to pass along + //other methods to your filters. For example, a method to close a popup + //for filters presented inside popups. + passMethod: function(method, fn){ + if (this.API.prototype[method]) throw new Error('Cannot overwrite API method ' + method + ' as it already exists'); + this.API.implement(method, fn); + return this; + }, + + passMethods: function(methods){ + for (method in methods) this.passMethod(method, methods[method]); + return this; } - if (Browser.opera || (Browser.ie && isNaN(parseFloat(result)))){ - if ((/^(height|width)$/).test(property)){ - var values = (property == 'width') ? ['left', 'right'] : ['top', 'bottom'], size = 0; - values.each(function(value){ - size += this.getStyle('border-' + value + '-width').toInt() + this.getStyle('padding-' + value).toInt(); + + }); + + var GetAPI = new Class({ + _getAPI: function(element, filter){ + var api = new this.API(element, filter.name); + api.getElement = function(apiKey, breakIfNotFound){ + var elements = api.getElements(apiKey, breakIfNotFound); + return elements ? elements[0] : null; + }; + api.getElements = function(apiKey, warnOrFail){ + var method = warnOrFail || "fail"; + var selector = api.get(apiKey); + if (!selector){ + api[method]("Could not find selector for " + apiKey); + return; + } + + if (selector == 'window') return window; + else if (selector == 'self') return element; + + var targets = element.getElements(selector); + if (!targets.length) api[method]("Could not find any elements for target '" + apiKey + "' using selector '" + selector + "'"); + return targets; + }; + return api; + } + }); + + var spaceOrCommaRegex = /\s*,\s*|\s+/g; + + BehaviorAPI.implement({ + deprecate: function(deprecated, asJSON){ + var set, + values = {}; + Object.each(deprecated, function(prop, key){ + var value = this.element[ asJSON ? 'getJSONData' : 'getData'](prop); + if (value !== undefined){ + set = true; + values[key] = value; + } + }, this); + this.setDefault(values); + return this; + } + }); + + this.Behavior = new Class({ + + Implements: [Options, Events, PassMethods, GetAPI], + + options: { + //by default, errors thrown by filters are caught; the onError event is fired. + //set this to *true* to NOT catch these errors to allow them to be handled by the browser. + // breakOnErrors: false, + // container: document.body, + + //default error behavior when a filter cannot be applied + onLog: getLog('info'), + onError: getLog('error'), + onWarn: getLog('warn'), + enableDeprecation: true, + selector: '[data-behavior]' + }, + + initialize: function(options){ + this.setOptions(options); + this.API = new Class({ Extends: BehaviorAPI }); + var self = this; + this.passMethods({ + getDelegator: this.getDelegator.bind(this), + addEvent: this.addEvent.bind(this), + removeEvent: this.removeEvent.bind(this), + addEvents: this.addEvents.bind(this), + removeEvents: this.removeEvents.bind(this), + fireEvent: this.fireEvent.bind(this), + applyFilters: this.apply.bind(this), + applyFilter: this.applyFilter.bind(this), + getContentElement: this.getContentElement.bind(this), + cleanup: this.cleanup.bind(this), + getContainerSize: function(){ + return this.getContentElement().measure(function(){ + return this.getSize(); + }); + }.bind(this), + error: function(){ this.fireEvent('error', arguments); }.bind(this), + fail: function(){ + var msg = Array.join(arguments, ' '); + throw new Error(msg); + }, + warn: function(){ + this.fireEvent('warn', arguments); + }.bind(this) + }); + }, + + getDelegator: function(){ + return this.delegator; + }, + + setDelegator: function(delegator){ + if (!instanceOf(delegator, Delegator)) throw new Error('Behavior.setDelegator only accepts instances of Delegator.'); + this.delegator = delegator; + return this; + }, + + getContentElement: function(){ + return this.options.container || document.body; + }, + + //Applies all the behavior filters for an element. + //container - (element) an element to apply the filters registered with this Behavior instance to. + //force - (boolean; optional) passed through to applyFilter (see it for docs) + apply: function(container, force){ + this._getElements(container).each(function(element){ + var plugins = []; + element.getBehaviors().each(function(name){ + var filter = this.getFilter(name); + if (!filter){ + this.fireEvent('error', ['There is no filter registered with this name: ', name, element]); + } else { + var config = filter.config; + if (config.delay !== undefined){ + this.applyFilter.delay(filter.config.delay, this, [element, filter, force]); + } else if(config.delayUntil){ + this._delayFilterUntil(element, filter, force); + } else if(config.initializer){ + this._customInit(element, filter, force); + } else { + plugins.append(this.applyFilter(element, filter, force, true)); + } + } }, this); - return this['offset' + property.capitalize()] - size + 'px'; + plugins.each(function(plugin){ + if (this.options.verbose) this.fireEvent('log', ['Firing plugin...']); + plugin(); + }, this); + }, this); + return this; + }, + + _getElements: function(container){ + if (typeOf(this.options.selector) == 'function') return this.options.selector(container); + else return document.id(container).getElements(this.options.selector); + }, + + //delays a filter until the event specified in filter.config.delayUntil is fired on the element + _delayFilterUntil: function(element, filter, force){ + var events = filter.config.delayUntil.split(','), + attached = {}, + inited = false; + var clear = function(){ + events.each(function(event){ + element.removeEvent(event, attached[event]); + }); + clear = function(){}; + }; + events.each(function(event){ + var init = function(e){ + clear(); + if (inited) return; + inited = true; + var setup = filter.setup; + filter.setup = function(element, api, _pluginResult){ + api.event = e; + return setup.apply(filter, [element, api, _pluginResult]); + }; + this.applyFilter(element, filter, force); + filter.setup = setup; + }.bind(this); + element.addEvent(event, init); + attached[event] = init; + }, this); + }, + + //runs custom initiliazer defined in filter.config.initializer + _customInit: function(element, filter, force){ + var api = this._getAPI(element, filter); + api.runSetup = this.applyFilter.pass([element, filter, force], this); + filter.config.initializer(element, api); + }, + + //Applies a specific behavior to a specific element. + //element - the element to which to apply the behavior + //filter - (object) a specific behavior filter, typically one registered with this instance or registered globally. + //force - (boolean; optional) apply the behavior to each element it matches, even if it was previously applied. Defaults to *false*. + //_returnPlugins - (boolean; optional; internal) if true, plugins are not rendered but instead returned as an array of functions + //_pluginTargetResult - (obj; optional internal) if this filter is a plugin for another, this is whatever that target filter returned + // (an instance of a class for example) + applyFilter: function(element, filter, force, _returnPlugins, _pluginTargetResult){ + var pluginsToReturn = []; + if (this.options.breakOnErrors){ + pluginsToReturn = this._applyFilter.apply(this, arguments); + } else { + try { + pluginsToReturn = this._applyFilter.apply(this, arguments); + } catch (e){ + this.fireEvent('error', ['Could not apply the behavior ' + filter.name, e.message]); + } + } + return _returnPlugins ? pluginsToReturn : this; + }, + + //see argument list above for applyFilter + _applyFilter: function(element, filter, force, _returnPlugins, _pluginTargetResult){ + var pluginsToReturn = []; + element = document.id(element); + //get the filters already applied to this element + var applied = getApplied(element); + //if this filter is not yet applied to the element, or we are forcing the filter + if (!applied[filter.name] || force){ + if (this.options.verbose) this.fireEvent('log', ['Applying behavior: ', filter.name, element]); + //if it was previously applied, garbage collect it + if (applied[filter.name]) applied[filter.name].cleanup(element); + var api = this._getAPI(element, filter); + + //deprecated + api.markForCleanup = filter.markForCleanup.bind(filter); + api.onCleanup = function(fn){ + filter.markForCleanup(element, fn); + }; + + if (filter.config.deprecated && this.options.enableDeprecation) api.deprecate(filter.config.deprecated); + if (filter.config.deprecateAsJSON && this.options.enableDeprecation) api.deprecate(filter.config.deprecatedAsJSON, true); + + //deal with requirements and defaults + if (filter.config.requireAs){ + api.requireAs(filter.config.requireAs); + } else if (filter.config.require){ + api.require.apply(api, Array.from(filter.config.require)); + } + + if (filter.config.defaults) api.setDefault(filter.config.defaults); + + //apply the filter + if (Behavior.debugging && Behavior.debugging.contains(filter.name)) debugger; + var result = filter.setup(element, api, _pluginTargetResult); + if (filter.config.returns && !instanceOf(result, filter.config.returns)){ + throw new Error("Filter " + filter.name + " did not return a valid instance."); + } + element.store('Behavior Filter result:' + filter.name, result); + if (this.options.verbose){ + if (result && !_pluginTargetResult) this.fireEvent('log', ['Successfully applied behavior: ', filter.name, element, result]); + else this.fireEvent('warn', ['Behavior applied, but did not return result: ', filter.name, element, result]); + } + + //and mark it as having been previously applied + applied[filter.name] = filter; + //apply all the plugins for this filter + var plugins = this.getPlugins(filter.name); + if (plugins){ + for (var name in plugins){ + if (_returnPlugins){ + pluginsToReturn.push(this.applyFilter.pass([element, plugins[name], force, null, result], this)); + } else { + this.applyFilter(element, plugins[name], force, null, result); + } + } + } + } + return pluginsToReturn; + }, + + //given a name, returns a registered behavior + getFilter: function(name){ + return this._registered[name] || Behavior.getFilter(name); + }, + + getPlugins: function(name){ + return this._plugins[name] || Behavior._plugins[name]; + }, + + //Garbage collects all applied filters for an element and its children. + //element - (*element*) container to cleanup + //ignoreChildren - (*boolean*; optional) if *true* only the element will be cleaned, otherwise the element and all the + // children with filters applied will be cleaned. Defaults to *false*. + cleanup: function(element, ignoreChildren){ + element = document.id(element); + var applied = getApplied(element); + for (var filter in applied){ + applied[filter].cleanup(element); + element.eliminate('Behavior Filter result:' + filter); + delete applied[filter]; } - if (Browser.opera && String(result).indexOf('px') != -1) return result; - if ((/^border(.+)Width|margin|padding/).test(property)) return '0px'; + if (!ignoreChildren) this._getElements(element).each(this.cleanup, this); + return this; } - return result; - }, - setStyles: function(styles){ - for (var style in styles) this.setStyle(style, styles[style]); - return this; - }, + }); - getStyles: function(){ - var result = {}; - Array.flatten(arguments).each(function(key){ - result[key] = this.getStyle(key); - }, this); - return result; - } + //Export these for use elsewhere (notabily: Delegator). + Behavior.getLog = getLog; + Behavior.PassMethods = PassMethods; + Behavior.GetAPI = GetAPI; -}); -Element.Styles = { - left: '@px', top: '@px', bottom: '@px', right: '@px', - width: '@px', height: '@px', maxWidth: '@px', maxHeight: '@px', minWidth: '@px', minHeight: '@px', - backgroundColor: 'rgb(@, @, @)', backgroundPosition: '@px @px', color: 'rgb(@, @, @)', - fontSize: '@px', letterSpacing: '@px', lineHeight: '@px', clip: 'rect(@px @px @px @px)', - margin: '@px @px @px @px', padding: '@px @px @px @px', border: '@px @ rgb(@, @, @) @px @ rgb(@, @, @) @px @ rgb(@, @, @)', - borderWidth: '@px @px @px @px', borderStyle: '@ @ @ @', borderColor: 'rgb(@, @, @) rgb(@, @, @) rgb(@, @, @) rgb(@, @, @)', - zIndex: '@', 'zoom': '@', fontWeight: '@', textIndent: '@px', opacity: '@' -}; + //Returns the applied behaviors for an element. + var getApplied = function(el){ + return el.retrieve('_appliedBehaviors', {}); + }; -//<1.3compat> + //Registers a behavior filter. + //name - the name of the filter + //fn - a function that applies the filter to the given element + //overwrite - (boolean) if true, will overwrite existing filter if one exists; defaults to false. + var addFilter = function(name, fn, overwrite){ + if (!this._registered[name] || overwrite) this._registered[name] = new Behavior.Filter(name, fn); + else throw new Error('Could not add the Behavior filter "' + name +'" as a previous trigger by that same name exists.'); + }; -Element.implement({ + var addFilters = function(obj, overwrite){ + for (var name in obj){ + addFilter.apply(this, [name, obj[name], overwrite]); + } + }; - setOpacity: function(value){ - setOpacity(this, value); - return this; - }, + //Registers a behavior plugin + //filterName - (*string*) the filter (or plugin) this is a plugin for + //name - (*string*) the name of this plugin + //setup - a function that applies the filter to the given element + var addPlugin = function(filterName, name, setup, overwrite){ + if (!this._plugins[filterName]) this._plugins[filterName] = {}; + if (!this._plugins[filterName][name] || overwrite) this._plugins[filterName][name] = new Behavior.Filter(name, setup); + else throw new Error('Could not add the Behavior filter plugin "' + name +'" as a previous trigger by that same name exists.'); + }; - getOpacity: function(){ - return getOpacity(this); - } + var addPlugins = function(obj, overwrite){ + for (var name in obj){ + addPlugin.apply(this, [obj[name].fitlerName, obj[name].name, obj[name].setup], overwrite); + } + }; -}); + var setFilterDefaults = function(name, defaults){ + var filter = this.getFilter(name); + if (!filter.config.defaults) filter.config.defaults = {}; + Object.append(filter.config.defaults, defaults); + }; -Element.Properties.opacity = { + //Add methods to the Behavior namespace for global registration. + Object.append(Behavior, { + _registered: {}, + _plugins: {}, + addGlobalFilter: addFilter, + addGlobalFilters: addFilters, + addGlobalPlugin: addPlugin, + addGlobalPlugins: addPlugins, + setFilterDefaults: setFilterDefaults, + getFilter: function(name){ + return this._registered[name]; + } + }); + //Add methods to the Behavior class for instance registration. + Behavior.implement({ + _registered: {}, + _plugins: {}, + addFilter: addFilter, + addFilters: addFilters, + addPlugin: addPlugin, + addPlugins: addPlugins, + setFilterDefaults: setFilterDefaults + }); - set: function(opacity){ - setOpacity(this, opacity); - setVisibility(this, opacity); - }, + //This class is an actual filter that, given an element, alters it with specific behaviors. + Behavior.Filter = new Class({ - get: function(){ - return getOpacity(this); - } + config: { + /** + returns: Foo, + require: ['req1', 'req2'], + //or + requireAs: { + req1: Boolean, + req2: Number, + req3: String + }, + defaults: { + opt1: false, + opt2: 2 + }, + //simple example: + setup: function(element, API){ + var kids = element.getElements(API.get('selector')); + //some validation still has to occur here + if (!kids.length) API.fail('there were no child elements found that match ', API.get('selector')); + if (kids.length < 2) API.warn("there weren't more than 2 kids that match", API.get('selector')); + var fooInstance = new Foo(kids, API.get('opt1', 'opt2')); + API.onCleanup(function(){ + fooInstance.destroy(); + }); + return fooInstance; + }, + delayUntil: 'mouseover', + //OR + delay: 100, + //OR + initializer: function(element, API){ + element.addEvent('mouseover', API.runSetup); //same as specifying event + //or + API.runSetup.delay(100); //same as specifying delay + //or something completely esoteric + var timer = (function(){ + if (element.hasClass('foo')){ + clearInterval(timer); + API.runSetup(); + } + }).periodical(100); + //or + API.addEvent('someBehaviorEvent', API.runSetup); + }); + */ + }, -}; + //Pass in an object with the following properties: + //name - the name of this filter + //setup - a function that applies the filter to the given element + initialize: function(name, setup){ + this.name = name; + if (typeOf(setup) == "function"){ + this.setup = setup; + } else { + Object.append(this.config, setup); + this.setup = this.config.setup; + } + this._cleanupFunctions = new Table(); + }, -// + //Stores a garbage collection pointer for a specific element. + //Example: if your filter enhances all the inputs in the container + //you might have a function that removes that enhancement for garbage collection. + //You would mark each input matched with its own cleanup function. + //NOTE: this MUST be the element passed to the filter - the element with this filters + // name in its data-behavior property. I.E.: + //
+ // + //
+ //If this filter is FormValidator, you can mark the form for cleanup, but not, for example + //the input. Only elements that match this filter can be marked. + markForCleanup: function(element, fn){ + var functions = this._cleanupFunctions.get(element); + if (!functions) functions = []; + functions.include(fn); + this._cleanupFunctions.set(element, functions); + return this; + }, -//<1.2compat> + //Garbage collect a specific element. + //NOTE: this should be an element that has a data-behavior property that matches this filter. + cleanup: function(element){ + var marks = this._cleanupFunctions.get(element); + if (marks){ + marks.each(function(fn){ fn(); }); + this._cleanupFunctions.erase(element); + } + return this; + } -Element.Styles = new Hash(Element.Styles); + }); -// + Behavior.debug = function(name){ + if (!Behavior.debugging) Behavior.debugging = []; + Behavior.debugging.push(name); + }; -Element.ShortStyles = {margin: {}, padding: {}, border: {}, borderWidth: {}, borderStyle: {}, borderColor: {}}; + Behavior.elementDataProperty = 'behavior'; + + Element.implement({ + + addBehaviorFilter: function(name){ + return this.setData(Behavior.elementDataProperty, this.getBehaviors().include(name).join(' ')); + }, + + removeBehaviorFilter: function(name){ + return this.setData(Behavior.elementDataProperty, this.getBehaviors().erase(name).join(' ')); + }, + + getBehaviors: function(){ + var filters = this.getData(Behavior.elementDataProperty); + if (!filters) return []; + return filters.trim().split(spaceOrCommaRegex); + }, + + hasBehavior: function(name){ + return this.getBehaviors().contains(name); + }, + + getBehaviorResult: function(name){ + return this.retrieve('Behavior Filter result:' + name); + } + + }); -['Top', 'Right', 'Bottom', 'Left'].each(function(direction){ - var Short = Element.ShortStyles; - var All = Element.Styles; - ['margin', 'padding'].each(function(style){ - var sd = style + direction; - Short[style][sd] = All[sd] = '@px'; - }); - var bd = 'border' + direction; - Short.border[bd] = All[bd] = '@px @ rgb(@, @, @)'; - var bdw = bd + 'Width', bds = bd + 'Style', bdc = bd + 'Color'; - Short[bd] = {}; - Short.borderWidth[bdw] = Short[bd][bdw] = All[bdw] = '@px'; - Short.borderStyle[bds] = Short[bd][bds] = All[bds] = '@'; - Short.borderColor[bdc] = Short[bd][bdc] = All[bdc] = 'rgb(@, @, @)'; -}); })(); -// Begin: Source/Fx/Fx.CSS.js +// Begin: Source/UI/Bootstrap.Tooltip.js /* --- -name: Fx.CSS +name: Bootstrap.Tooltip -description: Contains the CSS animation logic. Used by Fx.Tween, Fx.Morph, Fx.Elements. +description: A simple tooltip implementation that works with the Twitter Bootstrap css framework. + +authors: [Aaron Newton] license: MIT-style license. -requires: [Fx, Element.Style] +requires: + - /Bootstrap + - /CSSEvents + - More/Element.Position + - More/Element.Shortcuts + - Behavior/Behavior -provides: Fx.CSS +provides: [Bootstrap.Twipsy, Bootstrap.Tooltip] ... */ -Fx.CSS = new Class({ - - Extends: Fx, +Bootstrap.Tooltip = Bootstrap.Twipsy = new Class({ - //prepares the base from/to object + Implements: [Options, Events], - prepare: function(element, property, values){ - values = Array.from(values); - if (values[1] == null){ - values[1] = values[0]; - values[0] = element.getStyle(property); + options: { + location: 'above', //below, left, right, bottom, top + animate: true, + delayIn: 200, + delayOut: 0, + fallback: '', + override: '', + onOverflow: false, + offset: 0, + title: 'title', //element property + trigger: 'hover', //focus, manual + getContent: function(el){ + return el.get(this.options.title); } - var parsed = values.map(this.parse); - return {from: parsed[0], to: parsed[1]}; }, - //parses a value into an array - - parse: function(value){ - value = Function.from(value)(); - value = (typeof value == 'string') ? value.split(' ') : Array.from(value); - return value.map(function(val){ - val = String(val); - var found = false; - Object.each(Fx.CSS.Parsers, function(parser, key){ - if (found) return; - var parsed = parser.parse(val); - if (parsed || parsed === 0) found = {value: parsed, parser: parser}; - }); - found = found || {value: val, parser: Fx.CSS.Parsers.String}; - return found; - }); + initialize: function(el, options){ + this.element = document.id(el); + this.setOptions(options); + var location = this.options.location; + if (location == 'above') this.options.location = 'top'; //bootstrap 2.0 + if (location == 'below') this.options.location = 'bottom'; //bootstrap 2.0 + this._attach(); }, - //computes by a from and to prepared objects, using their parsers. + show: function(){ + this._clear(); + this._makeTip(); + var pos, edge, offset = {x: 0, y: 0}; + switch(this.options.location){ + case 'below': case 'bottom': + pos = 'centerBottom'; + edge = 'centerTop'; + offset.y = this.options.offset; + break; + case 'left': + pos = 'centerLeft'; + edge = 'centerRight'; + offset.x = this.options.offset; + break; + case 'right': + pos = 'centerRight'; + edge = 'centerLeft'; + offset.x = this.options.offset; + break; + default: //top + pos = 'centerTop'; + edge = 'centerBottom'; + offset.y = this.options.offset; + } + if (typeOf(this.options.offset) == "object") offset = this.options.offset; + if (this.element.getParent('.modal')) this.tip.inject(this.element, 'after'); + else this.tip.inject(document.body); + this.tip.show().position({ + relativeTo: this.element, + position: pos, + edge: edge, + offset: offset + }).removeClass('out').addClass('in'); + this.visible = true; + if (!Browser.Features.cssTransition || !this.options.animate) this._complete(); + this.fireEvent('show'); + return this; + }, - compute: function(from, to, delta){ - var computed = []; - (Math.min(from.length, to.length)).times(function(i){ - computed.push({value: from[i].parser.compute(from[i].value, to[i].value, delta), parser: from[i].parser}); - }); - computed.$family = Function.from('fx:css:value'); - return computed; + hide: function(){ + this._makeTip(); + this.tip.removeClass('in').addClass('out'); + this.visible = false; + if (!Browser.Features.cssTransition || !this.options.animate) this._complete(); + this.fireEvent('hide'); + return this; }, - //serves the value as settable + destroy: function(){ + this._detach(); + if (this.tip) this.tip.destroy(); + this.destroyed = true; + return this; + }, - serve: function(value, unit){ - if (typeOf(value) != 'fx:css:value') value = this.parse(value); - var returned = []; - value.each(function(bit){ - returned = returned.concat(bit.parser.serve(bit.value, unit)); - }); - return returned; + toggle: function(){ + return this[this.visible ? 'hide' : 'show'](); }, - //renders the change to an element + // PRIVATE METHODS - render: function(element, property, value, unit){ - element.setStyle(property, this.serve(value, unit)); + _makeTip: function(){ + if (!this.tip){ + var location = this.options.location; + if (location == 'above') location = 'top'; //bootstrap 2.0 + if (location == 'below') location = 'bottom'; //bootstrap 2.0 + this.tip = new Element('div.tooltip').addClass(location) + .adopt(new Element('div.tooltip-arrow')) + .adopt( + new Element('div.tooltip-inner', { + html: this.options.override || this.options.getContent.apply(this, [this.element]) || this.options.fallback + }) + ); + if (this.options.animate) this.tip.addClass('fade'); + if (Browser.Features.cssTransition && this.tip.addEventListener){ + this.tip.addEventListener(Browser.Features.transitionEnd, this.bound.complete); + } + this.element.set('alt', '').set('title', ''); + } + return this.tip; }, - //searches inside the page css to find the values for a selector + _attach: function(method){ + method = method || 'addEvents'; + this.bound = { + enter: this._enter.bind(this), + leave: this._leave.bind(this), + complete: this._complete.bind(this), + toggle: this.toggle.bind(this) + }; - search: function(selector){ - if (Fx.CSS.Cache[selector]) return Fx.CSS.Cache[selector]; - var to = {}, selectorTest = new RegExp('^' + selector.escapeRegExp() + '$'); - Array.each(document.styleSheets, function(sheet, j){ - var href = sheet.href; - if (href && href.contains('://') && !href.contains(document.domain)) return; - var rules = sheet.rules || sheet.cssRules; - Array.each(rules, function(rule, i){ - if (!rule.style) return; - var selectorText = (rule.selectorText) ? rule.selectorText.replace(/^\w+/, function(m){ - return m.toLowerCase(); - }) : null; - if (!selectorText || !selectorTest.test(selectorText)) return; - Object.each(Element.Styles, function(value, style){ - if (!rule.style[style] || Element.ShortStyles[style]) return; - value = String(rule.style[style]); - to[style] = ((/^rgb/).test(value)) ? value.rgbToHex() : value; - }); + if (this.options.trigger == 'hover') { + this.element[method]({ + mouseenter: this.bound.enter, + mouseleave: this.bound.leave }); - }); - return Fx.CSS.Cache[selector] = to; - } - -}); - -Fx.CSS.Cache = {}; - -Fx.CSS.Parsers = { - - Color: { - parse: function(value){ - if (value.match(/^#[0-9a-f]{3,6}$/i)) return value.hexToRgb(true); - return ((value = value.match(/(\d+),\s*(\d+),\s*(\d+)/))) ? [value[1], value[2], value[3]] : false; - }, - compute: function(from, to, delta){ - return from.map(function(value, i){ - return Math.round(Fx.compute(from[i], to[i], delta)); + } else if (this.options.trigger == 'focus'){ + this.element[method]({ + focus: this.bound.enter, + blur: this.bound.leave + }); + } else if (this.options.trigger == 'click'){ + this.element[method]({ + click: this.bound.toggle }); - }, - serve: function(value){ - return value.map(Number); } }, - Number: { - parse: parseFloat, - compute: Fx.compute, - serve: function(value, unit){ - return (unit) ? value + unit : value; - } + _detach: function(){ + this._attach('removeEvents'); }, - String: { - parse: Function.from(false), - compute: function(zero, one){ - return one; - }, - serve: function(zero){ - return zero; - } - } - -}; + _clear: function(){ + clearTimeout(this._inDelay); + clearTimeout(this._outDelay); + }, -//<1.2compat> + _enter: function(){ + if (this.options.onOverflow){ + var scroll = this.element.getScrollSize(), + size = this.element.getSize(); + if (scroll.x <= size.x && scroll.y <= size.y) return; + } + this._clear(); + if (this.options.delayIn){ + this._inDelay = this.show.delay(this.options.delayIn, this); + } else { + this.show(); + } + }, -Fx.CSS.Parsers = new Hash(Fx.CSS.Parsers); + _leave: function(){ + this._clear(); + if (this.options.delayOut){ + this._outDelay = this.hide.delay(this.options.delayOut, this); + } else { + this.hide(); + } + }, -// + _complete: function(){ + if (!this.visible){ + this.tip.dispose(); + } + this.fireEvent('complete', this.visible); + } +}); -// Begin: Source/Fx/Fx.Morph.js +// Begin: Source/UI/Bootstrap.Dropdown.js /* --- -name: Fx.Morph +name: Bootstrap.Dropdown -description: Formerly Fx.Styles, effect to transition any number of CSS properties for an element using an object of rules, or CSS based selector rules. +description: A simple dropdown menu that works with the Twitter Bootstrap css framework. license: MIT-style license. -requires: Fx.CSS +authors: [Aaron Newton] -provides: Fx.Morph +requires: + - /Bootstrap + - Core/Element.Event + - More/Element.Shortcuts + +provides: Bootstrap.Dropdown ... */ +Bootstrap.Dropdown = new Class({ -Fx.Morph = new Class({ + Implements: [Options, Events], - Extends: Fx.CSS, + options: { + /* + onShow: function(element){}, + onHide: function(elements){}, + */ + ignore: 'input, select, label' + }, - initialize: function(element, options){ - this.element = this.subject = document.id(element); - this.parent(options); + initialize: function(container, options){ + this.element = document.id(container); + this.setOptions(options); + this.boundHandle = this._handle.bind(this); + document.id(document.body).addEvent('click', this.boundHandle); }, - set: function(now){ - if (typeof now == 'string') now = this.search(now); - for (var p in now) this.render(this.element, p, now[p], this.options.unit); + hideAll: function(){ + var els = this.element.removeClass('open').getElements('.open').removeClass('open'); + this.fireEvent('hide', els); return this; }, - compute: function(from, to, delta){ - var now = {}; - for (var p in from) now[p] = this.parent(from[p], to[p], delta); - return now; + show: function(subMenu){ + this.hideAll(); + this.fireEvent('show', subMenu); + subMenu.addClass('open'); + return this; }, - start: function(properties){ - if (!this.check(properties)) return this; - if (typeof properties == 'string') properties = this.search(properties); - var from = {}, to = {}; - for (var p in properties){ - var parsed = this.prepare(this.element, p, properties[p]); - from[p] = parsed.from; - to[p] = parsed.to; - } - return this.parent(from, to); - } - -}); - -Element.Properties.morph = { - - set: function(options){ - this.get('morph').cancel().setOptions(options); + destroy: function(){ + this.hideAll(); + document.body.removeEvent('click', this.boundHandle); return this; }, - get: function(){ - var morph = this.retrieve('morph'); - if (!morph){ - morph = new Fx.Morph(this, {link: 'cancel'}); - this.store('morph', morph); - } - return morph; - } - -}; - -Element.implement({ + // PRIVATE - morph: function(props){ - this.get('morph').start(props); - return this; + _handle: function(e){ + var el = e.target; + var open = el.getParent('.open'); + if (!el.match(this.options.ignore) || !open) this.hideAll(); + if (this.element.contains(el)) { + var parent; + if (el.match('[data-toggle="dropdown"]') || el.getParent('[data-toggle="dropdown"] !')){ + parent = el.getParent('.dropdown, .btn-group'); + } +  // backwards compatibility + if (!parent) parent = el.match('.dropdown-toggle') ? el.getParent() : el.getParent('.dropdown-toggle !'); + if (parent){ + e.preventDefault(); + if (!open) this.show(parent); + } + } } - }); - -// Begin: Source/More/More.js +// Begin: Source/Behaviors/Behavior.BS.Dropdown.js /* --- -script: More.js - -name: More +name: Behavior.BS.Dropdown -description: MooTools More +description: Instantiates Bootstrap.Dropdown based on HTML markup. -license: MIT-style license +license: MIT-style license. -authors: - - Guillermo Rauch - - Thomas Aylott - - Scott Kyle - - Arian Stolwijk - - Tim Wienk - - Christoph Pojer - - Aaron Newton - - Jacob Thornton +authors: [Aaron Newton] requires: - - Core/MooTools + - Behavior/Behavior + - Bootstrap.Dropdown -provides: [MooTools.More] +provides: [Behavior.BS.Dropdown] ... */ +Behavior.addGlobalFilters({ + 'BS.Dropdown': { + returns: Bootstrap.Dropdown, + setup: function(el, api){ + return new Bootstrap.Dropdown(el); + } + } +}); -MooTools.More = { - 'version': '1.4.0.1', - 'build': 'a4244edf2aa97ac8a196fc96082dd35af1abab87' -}; - - -// Begin: Source/Element/Element.Shortcuts.js +// Begin: Source/Element/Element.Delegation.js /* --- -script: Element.Shortcuts.js - -name: Element.Shortcuts - -description: Extends the Element native object to include some shortcut methods. +name: Element.Delegation -license: MIT-style license +description: Extends the Element native object to include the delegate method for more efficient event management. -authors: - - Aaron Newton +license: MIT-style license. -requires: - - Core/Element.Style - - /MooTools.More +requires: [Element.Event] -provides: [Element.Shortcuts] +provides: [Element.Delegation] ... */ -Element.implement({ +(function(){ - isDisplayed: function(){ - return this.getStyle('display') != 'none'; - }, +var eventListenerSupport = !!window.addEventListener; - isVisible: function(){ - var w = this.offsetWidth, - h = this.offsetHeight; - return (w == 0 && h == 0) ? false : (w > 0 && h > 0) ? true : this.style.display != 'none'; - }, +Element.NativeEvents.focusin = Element.NativeEvents.focusout = 2; - toggle: function(){ - return this[this.isDisplayed() ? 'hide' : 'show'](); - }, +var bubbleUp = function(self, match, fn, event, target){ + while (target && target != self){ + if (match(target, event)) return fn.call(target, event, target); + target = document.id(target.parentNode); + } +}; - hide: function(){ - var d; - try { - //IE fails here if the element is not in the dom - d = this.getStyle('display'); - } catch(e){} - if (d == 'none') return this; - return this.store('element:_originalDisplay', d || '').setStyle('display', 'none'); +var map = { + mouseenter: { + base: 'mouseover' }, - - show: function(display){ - if (!display && this.isDisplayed()) return this; - display = display || this.retrieve('element:_originalDisplay') || 'block'; - return this.setStyle('display', (display == 'none') ? 'block' : display); + mouseleave: { + base: 'mouseout' }, - - swapClass: function(remove, add){ - return this.removeClass(remove).addClass(add); + focus: { + base: 'focus' + (eventListenerSupport ? '' : 'in'), + capture: true + }, + blur: { + base: eventListenerSupport ? 'blur' : 'focusout', + capture: true } +}; -}); +/**/ +var _key = '$delegation:'; +var formObserver = function(type){ -Document.implement({ + return { - clearSelection: function(){ - if (window.getSelection){ - var selection = window.getSelection(); - if (selection && selection.removeAllRanges) selection.removeAllRanges(); - } else if (document.selection && document.selection.empty){ - try { - //IE fails here if selected element is not in dom - document.selection.empty(); - } catch(e){} + base: 'focusin', + + remove: function(self, uid){ + var list = self.retrieve(_key + type + 'listeners', {})[uid]; + if (list && list.forms) for (var i = list.forms.length; i--;){ + list.forms[i].removeEvent(type, list.fns[i]); + } + }, + + listen: function(self, match, fn, event, target, uid){ + var form = (target.get('tag') == 'form') ? target : event.target.getParent('form'); + if (!form) return; + + var listeners = self.retrieve(_key + type + 'listeners', {}), + listener = listeners[uid] || {forms: [], fns: []}, + forms = listener.forms, fns = listener.fns; + + if (forms.indexOf(form) != -1) return; + forms.push(form); + + var _fn = function(event){ + bubbleUp(self, match, fn, event, target); + }; + form.addEvent(type, _fn); + fns.push(_fn); + + listeners[uid] = listener; + self.store(_key + type + 'listeners', listeners); + } + }; +}; + +var inputObserver = function(type){ + return { + base: 'focusin', + listen: function(self, match, fn, event, target){ + var events = {blur: function(){ + this.removeEvents(events); + }}; + events[type] = function(event){ + bubbleUp(self, match, fn, event, target); + }; + event.target.addEvents(events); } - } + }; +}; +if (!eventListenerSupport) Object.append(map, { + submit: formObserver('submit'), + reset: formObserver('reset'), + change: inputObserver('change'), + select: inputObserver('select') }); +/**/ +var proto = Element.prototype, + addEvent = proto.addEvent, + removeEvent = proto.removeEvent; -// Begin: Source/Element/Element.Dimensions.js -/* ---- +var relay = function(old, method){ + return function(type, fn, useCapture){ + if (type.indexOf(':relay') == -1) return old.call(this, type, fn, useCapture); + var parsed = Slick.parse(type).expressions[0][0]; + if (parsed.pseudos[0].key != 'relay') return old.call(this, type, fn, useCapture); + var newType = parsed.tag; + parsed.pseudos.slice(1).each(function(pseudo){ + newType += ':' + pseudo.key + (pseudo.value ? '(' + pseudo.value + ')' : ''); + }); + old.call(this, type, fn); + return method.call(this, newType, parsed.pseudos[0].value, fn); + }; +}; -name: Element.Dimensions +var delegation = { -description: Contains methods to work with size, scroll, or positioning of Elements and the window object. + addEvent: function(type, match, fn){ + var storage = this.retrieve('$delegates', {}), stored = storage[type]; + if (stored) for (var _uid in stored){ + if (stored[_uid].fn == fn && stored[_uid].match == match) return this; + } -license: MIT-style license. + var _type = type, _match = match, _fn = fn, _map = map[type] || {}; + type = _map.base || _type; -credits: - - Element positioning based on the [qooxdoo](http://qooxdoo.org/) code and smart browser fixes, [LGPL License](http://www.gnu.org/licenses/lgpl.html). - - Viewport dimensions based on [YUI](http://developer.yahoo.com/yui/) code, [BSD License](http://developer.yahoo.com/yui/license.html). + match = function(target){ + return Slick.match(target, _match); + }; -requires: [Element, Element.Style] + var elementEvent = Element.Events[_type]; + if (elementEvent && elementEvent.condition){ + var __match = match, condition = elementEvent.condition; + match = function(target, event){ + return __match(target, event) && condition.call(target, event, type); + }; + } -provides: [Element.Dimensions] + var self = this, uid = String.uniqueID(); + var delegator = _map.listen ? function(event, target){ + if (!target && event && event.target) target = event.target; + if (target) _map.listen(self, match, fn, event, target, uid); + } : function(event, target){ + if (!target && event && event.target) target = event.target; + if (target) bubbleUp(self, match, fn, event, target); + }; -... -*/ + if (!stored) stored = {}; + stored[uid] = { + match: _match, + fn: _fn, + delegator: delegator + }; + storage[_type] = stored; + return addEvent.call(this, type, delegator, _map.capture); + }, -(function(){ + removeEvent: function(type, match, fn, _uid){ + var storage = this.retrieve('$delegates', {}), stored = storage[type]; + if (!stored) return this; -var element = document.createElement('div'), - child = document.createElement('div'); -element.style.height = '0'; -element.appendChild(child); -var brokenOffsetParent = (child.offsetParent === element); -element = child = null; + if (_uid){ + var _type = type, delegator = stored[_uid].delegator, _map = map[type] || {}; + type = _map.base || _type; + if (_map.remove) _map.remove(this, _uid); + delete stored[_uid]; + storage[_type] = stored; + return removeEvent.call(this, type, delegator); + } -var isOffset = function(el){ - return styleString(el, 'position') != 'static' || isBody(el); -}; + var __uid, s; + if (fn) for (__uid in stored){ + s = stored[__uid]; + if (s.match == match && s.fn == fn) return delegation.removeEvent.call(this, type, match, fn, __uid); + } else for (__uid in stored){ + s = stored[__uid]; + if (s.match == match) delegation.removeEvent.call(this, type, match, s.fn, __uid); + } + return this; + } -var isOffsetStatic = function(el){ - return isOffset(el) || (/^(?:table|td|th)$/i).test(el.tagName); }; -Element.implement({ +[Element, Window, Document].invoke('implement', { + addEvent: relay(addEvent, delegation.addEvent), + removeEvent: relay(removeEvent, delegation.removeEvent) +}); - scrollTo: function(x, y){ - if (isBody(this)){ - this.getWindow().scrollTo(x, y); - } else { - this.scrollLeft = x; - this.scrollTop = y; - } - return this; - }, +})(); - getSize: function(){ - if (isBody(this)) return this.getWindow().getSize(); - return {x: this.offsetWidth, y: this.offsetHeight}; - }, - getScrollSize: function(){ - if (isBody(this)) return this.getWindow().getScrollSize(); - return {x: this.scrollWidth, y: this.scrollHeight}; - }, +// Begin: Source/Event.Mock.js +/* +--- +name: Event.Mock - getScroll: function(){ - if (isBody(this)) return this.getWindow().getScroll(); - return {x: this.scrollLeft, y: this.scrollTop}; - }, +description: Supplies a Mock Event object for use on fireEvent - getScrolls: function(){ - var element = this.parentNode, position = {x: 0, y: 0}; - while (element && !isBody(element)){ - position.x += element.scrollLeft; - position.y += element.scrollTop; - element = element.parentNode; - } - return position; - }, +license: MIT-style - getOffsetParent: brokenOffsetParent ? function(){ - var element = this; - if (isBody(element) || styleString(element, 'position') == 'fixed') return null; +authors: +- Arieh Glazer - var isOffsetCheck = (styleString(element, 'position') == 'static') ? isOffsetStatic : isOffset; - while ((element = element.parentNode)){ - if (isOffsetCheck(element)) return element; - } - return null; - } : function(){ - var element = this; - if (isBody(element) || styleString(element, 'position') == 'fixed') return null; +requires: Core/Event - try { - return element.offsetParent; - } catch(e) {} - return null; - }, +provides: [Event.Mock] - getOffsets: function(){ - if (this.getBoundingClientRect && !Browser.Platform.ios){ - var bound = this.getBoundingClientRect(), - html = document.id(this.getDocument().documentElement), - htmlScroll = html.getScroll(), - elemScrolls = this.getScrolls(), - isFixed = (styleString(this, 'position') == 'fixed'); +... +*/ - return { - x: bound.left.toInt() + elemScrolls.x + ((isFixed) ? 0 : htmlScroll.x) - html.clientLeft, - y: bound.top.toInt() + elemScrolls.y + ((isFixed) ? 0 : htmlScroll.y) - html.clientTop - }; - } +(function($,window,undef){ - var element = this, position = {x: 0, y: 0}; - if (isBody(this)) return position; +/** + * creates a Mock event to be used with fire event + * @param Element target an element to set as the target of the event - not required + * @param string type the type of the event to be fired. Will not be used by IE - not required. + * + */ +Event.Mock = function(target,type){ + type = type || 'click'; - while (element && !isBody(element)){ - position.x += element.offsetLeft; - position.y += element.offsetTop; + var e = { + type: type, + target: target + }; - if (Browser.firefox){ - if (!borderBox(element)){ - position.x += leftBorder(element); - position.y += topBorder(element); - } - var parent = element.parentNode; - if (parent && styleString(parent, 'overflow') != 'visible'){ - position.x += leftBorder(parent); - position.y += topBorder(parent); - } - } else if (element != this && Browser.safari){ - position.x += leftBorder(element); - position.y += topBorder(element); - } + if (document.createEvent){ + e = document.createEvent('HTMLEvents'); + e.initEvent( + type //event type + , false //bubbles - set to false because the event should like normal fireEvent + , true //cancelable + ); + } - element = element.offsetParent; - } - if (Browser.firefox && !borderBox(this)){ - position.x -= leftBorder(this); - position.y -= topBorder(this); - } - return position; - }, + e = new Event(e); - getPosition: function(relative){ - var offset = this.getOffsets(), - scroll = this.getScrolls(); - var position = { - x: offset.x - scroll.x, - y: offset.y - scroll.y - }; + e.target = target; + + return e; +}; + +})(document.id,window); - if (relative && (relative = document.id(relative))){ - var relativePosition = relative.getPosition(); - return {x: position.x - relativePosition.x - leftBorder(relative), y: position.y - relativePosition.y - topBorder(relative)}; - } - return position; - }, +// Begin: Source/Delegator.js +/* +--- +name: Delegator +description: Allows for the registration of delegated events on a container. +requires: [Core/Element.Delegation, Core/Options, Core/Events, /Event.Mock, /Behavior] +provides: [Delegator] +... +*/ +(function(){ - getCoordinates: function(element){ - if (isBody(this)) return this.getWindow().getCoordinates(); - var position = this.getPosition(element), - size = this.getSize(); - var obj = { - left: position.x, - top: position.y, - width: size.x, - height: size.y - }; - obj.right = obj.left + obj.width; - obj.bottom = obj.top + obj.height; - return obj; - }, + var spaceOrCommaRegex = /\s*,\s*|\s+/g; - computePosition: function(obj){ - return { - left: obj.x - styleNumber(this, 'margin-left'), - top: obj.y - styleNumber(this, 'margin-top') - }; - }, + var checkEvent = function(trigger, element, event){ + if (!event) return true; + return trigger.types.some(function(type){ + var elementEvent = Element.Events[type]; + if (elementEvent && elementEvent.condition){ + return elementEvent.condition.call(element, event, type); + } else { + var eventType = elementEvent && elementEvent.base ? elementEvent.base : event.type; + return eventType == type; + } + }); + }; - setPosition: function(obj){ - return this.setStyles(this.computePosition(obj)); - } + window.Delegator = new Class({ -}); + Implements: [Options, Events, Behavior.PassMethods, Behavior.GetAPI], + options: { + // breakOnErrors: false, + // onTrigger: function(trigger, element, event, result){}, + getBehavior: function(){}, + onLog: Behavior.getLog('info'), + onError: Behavior.getLog('error'), + onWarn: Behavior.getLog('warn') + }, -[Document, Window].invoke('implement', { + initialize: function(options){ + this.setOptions(options); + this._bound = { + eventHandler: this._eventHandler.bind(this) + }; + Delegator._instances.push(this); + Object.each(Delegator._triggers, function(trigger){ + this._eventTypes.combine(trigger.types); + }, this); + this.API = new Class({ Extends: BehaviorAPI }); + this.passMethods({ + addEvent: this.addEvent.bind(this), + removeEvent: this.removeEvent.bind(this), + addEvents: this.addEvents.bind(this), + removeEvents: this.removeEvents.bind(this), + fireEvent: this.fireEvent.bind(this), + attach: this.attach.bind(this), + trigger: this.trigger.bind(this), + error: function(){ this.fireEvent('error', arguments); }.bind(this), + fail: function(){ + var msg = Array.join(arguments, ' '); + throw new Error(msg); + }, + warn: function(){ + this.fireEvent('warn', arguments); + }.bind(this), + getBehavior: function(){ + return this.options.getBehavior(); + }.bind(this) + }); - getSize: function(){ - var doc = getCompatElement(this); - return {x: doc.clientWidth, y: doc.clientHeight}; - }, + this.bindToBehavior(this.options.getBehavior()); + }, - getScroll: function(){ - var win = this.getWindow(), doc = getCompatElement(this); - return {x: win.pageXOffset || doc.scrollLeft, y: win.pageYOffset || doc.scrollTop}; - }, + bindToBehavior: function(behavior){ + if (!behavior) return; + this.unbindFromBehavior(); + this._behavior = behavior; + if (this._behavior.options.verbose) this.options.verbose = true; + if (!this._behaviorEvents){ + var self = this; + this._behaviorEvents = { + destroyDom: function(elements){ + Array.from(elements).each(function(element){ + self._behavior.cleanup(element); + self._behavior.fireEvent('destroyDom', element); + }); + }, + ammendDom: function(container){ + self._behavior.apply(container); + self._behavior.fireEvent('ammendDom', container); + } + }; + } + this.addEvents(this._behaviorEvents); + }, - getScrollSize: function(){ - var doc = getCompatElement(this), - min = this.getSize(), - body = this.getDocument().body; + getBehavior: function(){ + return this._behavior; + }, - return {x: Math.max(doc.scrollWidth, body.scrollWidth, min.x), y: Math.max(doc.scrollHeight, body.scrollHeight, min.y)}; - }, + unbindFromBehavior: function(){ + if (this._behaviorEvents && this._behavior){ + this._behavior.removeEvents(this._behaviorEvents); + delete this._behavior; + } + }, - getPosition: function(){ - return {x: 0, y: 0}; - }, + attach: function(target, _method){ + _method = _method || 'addEvent'; + target = document.id(target); + if ((_method == 'addEvent' && this._attachedTo.contains(target)) || + (_method == 'removeEvent') && !this._attachedTo.contains(target)) return this; + this._eventTypes.each(function(event){ + target[_method](event + ':relay([data-trigger])', this._bound.eventHandler); + }, this); + this._attachedTo.push(target); + return this; + }, - getCoordinates: function(){ - var size = this.getSize(); - return {top: 0, left: 0, bottom: size.y, right: size.x, height: size.y, width: size.x}; - } + detach: function(target){ + if (target){ + this.attach(target, 'removeEvent'); + } else { + this._attachedTo.each(this.detach, this); + } + return this; + }, -}); + trigger: function(name, element, event){ + var e = event; + if (!e || typeOf(e) == "string") e = new Event.Mock(element, e); + if (this.options.verbose) this.fireEvent('log', ['Applying trigger: ', name, element, event]); + var result, + trigger = this.getTrigger(name); + if (!trigger){ + this.fireEvent('warn', 'Could not find a trigger by the name of ' + name); + } else if (checkEvent(trigger, element, e)) { + if (this.options.breakOnErrors){ + result = this._trigger(trigger, element, e); + } else { + try { + result = this._trigger(trigger, element, e); + } catch(error) { + this.fireEvent('error', ['Could not apply the trigger', name, error.message]); + } + } + } + if (this.options.verbose && result) this.fireEvent('log', ['Successfully applied trigger: ', name, element, event]); + else if (this.options.verbose) this.fireEvent('log', ['Trigger applied, but did not return a result: ', name, element, event]); + return result; + }, -// private methods + getTrigger: function(name){ + return this._triggers[name] || Delegator._triggers[name]; + }, -var styleString = Element.getComputedStyle; + addEventTypes: function(triggerName, types){ + this.getTrigger(triggerName).types.combine(Array.from(types)); + return this; + }, -function styleNumber(element, style){ - return styleString(element, style).toInt() || 0; -} + /****************** + * PRIVATE METHODS + ******************/ -function borderBox(element){ - return styleString(element, '-moz-box-sizing') == 'border-box'; -} + _trigger: function(trigger, element, event){ + var api = this._getAPI(element, trigger); + if (trigger.requireAs){ + api.requireAs(trigger.requireAs); + } else if (trigger.require){ + api.require.apply(api, Array.from(trigger.require)); + } if (trigger.defaults){ + api.setDefault(trigger.defaults); + } + if (Delegator.debugging && Delegator.debugging.contains(name)) debugger; + var result = trigger.handler.apply(this, [event, element, api]); + this.fireEvent('trigger', [trigger, element, event, result]); + return result; + }, -function topBorder(element){ - return styleNumber(element, 'border-top-width'); -} + _eventHandler: function(event, target){ + var triggers = target.getTriggers(); + if (triggers.contains('Stop')) event.stop(); + if (triggers.contains('PreventDefault')) event.preventDefault(); + triggers.each(function(trigger){ + if (trigger != "Stop" && trigger != "PreventDefault") this.trigger(trigger, target, event); + }, this); + }, -function leftBorder(element){ - return styleNumber(element, 'border-left-width'); -} + _onRegister: function(eventTypes){ + eventTypes.each(function(eventType){ + if (!this._eventTypes.contains(eventType)){ + this._attachedTo.each(function(element){ + element.addEvent(eventType + ':relay([data-trigger])', this._bound.eventHandler); + }, this); + } + this._eventTypes.include(eventType); + }, this); + }, -function isBody(element){ - return (/^(?:body|html)$/i).test(element.tagName); -} + _attachedTo: [], + _eventTypes: [], + _triggers: {} -function getCompatElement(element){ - var doc = element.getDocument(); - return (!doc.compatMode || doc.compatMode == 'CSS1Compat') ? doc.html : doc.body; -} + }); -})(); + Delegator._triggers = {}; + Delegator._instances = []; + Delegator._onRegister = function(eventType){ + this._instances.each(function(instance){ + instance._onRegister(eventType); + }); + }; + + Delegator.register = function(eventTypes, name, handler, overwrite /** or eventType, obj, overwrite */){ + eventTypes = Array.from(eventTypes); + if (typeOf(name) == "object"){ + var obj = name; + for (name in obj){ + this.register.apply(this, [eventTypes, name, obj[name], handler]); + } + return this; + } + if (!this._triggers[name] || overwrite){ + if (typeOf(handler) == "function"){ + handler = { + handler: handler + }; + } + handler.types = eventTypes; + handler.name = name; + this._triggers[name] = handler; + this._onRegister(eventTypes); + } else { + throw new Error('Could add the trigger "' + name +'" as a previous trigger by that same name exists.'); + } + return this; + }; -//aliases -Element.alias({position: 'setPosition'}); //compatability + Delegator.getTrigger = function(name){ + return this._triggers[name]; + }; -[Window, Document, Element].invoke('implement', { + Delegator.addEventTypes = function(triggerName, types){ + this.getTrigger(triggerName).types.combine(Array.from(types)); + return this; + }; - getHeight: function(){ - return this.getSize().y; - }, + Delegator.debug = function(name){ + if (!Delegator.debugging) Delegator.debugging = []; + Delegator.debugging.push(name); + }; - getWidth: function(){ - return this.getSize().x; - }, - getScrollTop: function(){ - return this.getScroll().y; - }, + Delegator.implement('register', Delegator.register); - getScrollLeft: function(){ - return this.getScroll().x; - }, + Element.implement({ - getScrollHeight: function(){ - return this.getScrollSize().y; - }, + addTrigger: function(name){ + return this.setData('trigger', this.getTriggers().include(name).join(' ')); + }, - getScrollWidth: function(){ - return this.getScrollSize().x; - }, + removeTrigger: function(name){ + return this.setData('trigger', this.getTriggers().erase(name).join(' ')); + }, - getTop: function(){ - return this.getPosition().y; - }, + getTriggers: function(){ + var triggers = this.getData('trigger'); + if (!triggers) return []; + return triggers.trim().split(spaceOrCommaRegex); + }, - getLeft: function(){ - return this.getPosition().x; - } + hasTrigger: function(name){ + return this.getTriggers().contains(name); + } -}); + }); +})(); -// Begin: Source/Element/Element.Measure.js +// Begin: Source/Behaviors/Delegator.BS.ShowPopup.js /* --- -script: Element.Measure.js - -name: Element.Measure - -description: Extends the Element native object to include methods useful in measuring dimensions. +name: Delegator.BS.ShowPopup -credits: "Element.measure / .expose methods by Daniel Steigerwald License: MIT-style license. Copyright: Copyright (c) 2008 Daniel Steigerwald, daniel.steigerwald.cz" +description: Shows a hidden popup. -license: MIT-style license +authors: [Aaron Newton] -authors: - - Aaron Newton +license: MIT-style license. requires: - - Core/Element.Style - - Core/Element.Dimensions - - /MooTools.More + - Behavior/Delegator + - Behavior/Behavior -provides: [Element.Measure] +provides: [Delegator.BS.ShowPopup] ... */ (function(){ -var getStylesList = function(styles, planes){ - var list = []; - Object.each(planes, function(directions){ - Object.each(directions, function(edge){ - styles.each(function(style){ - list.push(style + '-' + edge + (style == 'border' ? '-width' : '')); - }); - }); - }); - return list; -}; - -var calculateEdgeSize = function(edge, styles){ - var total = 0; - Object.each(styles, function(value, style){ - if (style.test(edge)) total = total + value.toInt(); - }); - return total; -}; - -var isVisible = function(el){ - return !!(!el || el.offsetHeight || el.offsetWidth); -}; - - -Element.implement({ - - measure: function(fn){ - if (isVisible(this)) return fn.call(this); - var parent = this.getParent(), - toMeasure = []; - while (!isVisible(parent) && parent != document.body){ - toMeasure.push(parent.expose()); - parent = parent.getParent(); - } - var restore = this.expose(), - result = fn.call(this); - restore(); - toMeasure.each(function(restore){ - restore(); - }); - return result; - }, - - expose: function(){ - if (this.getStyle('display') != 'none') return function(){}; - var before = this.style.cssText; - this.setStyles({ - display: 'block', - position: 'absolute', - visibility: 'hidden' - }); - return function(){ - this.style.cssText = before; - }.bind(this); - }, - - getDimensions: function(options){ - options = Object.merge({computeSize: false}, options); - var dim = {x: 0, y: 0}; - var getSize = function(el, options){ - return (options.computeSize) ? el.getComputedSize(options) : el.getSize(); - }; - var parent = this.getParent('body'); + Delegator.register('click', 'BS.showPopup', { - if (parent && this.getStyle('display') == 'none'){ - dim = this.measure(function(){ - return getSize(this, options); - }); - } else if (parent){ - try { //safari sometimes crashes here, so catch it - dim = getSize(this, options); - }catch(e){} + handler: function(event, link, api){ + var target = api.get('target') ? link.getElement(api.get('target')) : document.id(link.get('href').split("#")[1]); + event.preventDefault(); + if (!target) api.fail('Could not find target element to activate: ' + (api.get('target') || link.get('href'))); + api.getBehavior().apply(target); + target.getBehaviorResult('BS.Popup').show(); } - return Object.append(dim, (dim.x || dim.x === 0) ? { - width: dim.x, - height: dim.y - } : { - x: dim.width, - y: dim.height - } - ); - }, - - getComputedSize: function(options){ - //<1.2compat> - //legacy support for my stupid spelling error - if (options && options.plains) options.planes = options.plains; - // - - options = Object.merge({ - styles: ['padding','border'], - planes: { - height: ['top','bottom'], - width: ['left','right'] - }, - mode: 'both' - }, options); + }); - var styles = {}, - size = {width: 0, height: 0}, - dimensions; +})(); - if (options.mode == 'vertical'){ - delete size.width; - delete options.planes.width; - } else if (options.mode == 'horizontal'){ - delete size.height; - delete options.planes.height; - } +// Begin: Source/Request/Request.js +/* +--- - getStylesList(options.styles, options.planes).each(function(style){ - styles[style] = this.getStyle(style).toInt(); - }, this); +name: Request - Object.each(options.planes, function(edges, plane){ +description: Powerful all purpose Request Class. Uses XMLHTTPRequest. - var capitalized = plane.capitalize(), - style = this.getStyle(plane); +license: MIT-style license. - if (style == 'auto' && !dimensions) dimensions = this.getDimensions(); +requires: [Object, Element, Chain, Events, Options, Browser] - style = styles[plane] = (style == 'auto') ? dimensions[plane] : style.toInt(); - size['total' + capitalized] = style; +provides: Request - edges.each(function(edge){ - var edgesize = calculateEdgeSize(edge, styles); - size['computed' + edge.capitalize()] = edgesize; - size['total' + capitalized] += edgesize; - }); +... +*/ - }, this); +(function(){ - return Object.append(size, styles); - } +var empty = function(){}, + progressSupport = ('onprogress' in new Browser.Request); -}); +var Request = this.Request = new Class({ -})(); + Implements: [Chain, Events, Options], + options: {/* + onRequest: function(){}, + onLoadstart: function(event, xhr){}, + onProgress: function(event, xhr){}, + onComplete: function(){}, + onCancel: function(){}, + onSuccess: function(responseText, responseXML){}, + onFailure: function(xhr){}, + onException: function(headerName, value){}, + onTimeout: function(){}, + user: '', + password: '',*/ + url: '', + data: '', + headers: { + 'X-Requested-With': 'XMLHttpRequest', + 'Accept': 'text/javascript, text/html, application/xml, text/xml, */*' + }, + async: true, + format: false, + method: 'post', + link: 'ignore', + isSuccess: null, + emulation: true, + urlEncoded: true, + encoding: 'utf-8', + evalScripts: false, + evalResponse: false, + timeout: 0, + noCache: false + }, -// Begin: Source/Fx/Fx.Reveal.js -/* ---- + initialize: function(options){ + this.xhr = new Browser.Request(); + this.setOptions(options); + this.headers = this.options.headers; + }, -script: Fx.Reveal.js + onStateChange: function(){ + var xhr = this.xhr; + if (xhr.readyState != 4 || !this.running) return; + this.running = false; + this.status = 0; + Function.attempt(function(){ + var status = xhr.status; + this.status = (status == 1223) ? 204 : status; + }.bind(this)); + xhr.onreadystatechange = empty; + if (progressSupport) xhr.onprogress = xhr.onloadstart = empty; + clearTimeout(this.timer); -name: Fx.Reveal + this.response = {text: this.xhr.responseText || '', xml: this.xhr.responseXML}; + if (this.options.isSuccess.call(this, this.status)) + this.success(this.response.text, this.response.xml); + else + this.failure(); + }, -description: Defines Fx.Reveal, a class that shows and hides elements with a transition. + isSuccess: function(){ + var status = this.status; + return (status >= 200 && status < 300); + }, -license: MIT-style license + isRunning: function(){ + return !!this.running; + }, -authors: - - Aaron Newton + processScripts: function(text){ + if (this.options.evalResponse || (/(ecma|java)script/).test(this.getHeader('Content-type'))) return Browser.exec(text); + return text.stripScripts(this.options.evalScripts); + }, -requires: - - Core/Fx.Morph - - /Element.Shortcuts - - /Element.Measure + success: function(text, xml){ + this.onSuccess(this.processScripts(text), xml); + }, -provides: [Fx.Reveal] + onSuccess: function(){ + this.fireEvent('complete', arguments).fireEvent('success', arguments).callChain(); + }, -... -*/ + failure: function(){ + this.onFailure(); + }, -(function(){ + onFailure: function(){ + this.fireEvent('complete').fireEvent('failure', this.xhr); + }, + loadstart: function(event){ + this.fireEvent('loadstart', [event, this.xhr]); + }, -var hideTheseOf = function(object){ - var hideThese = object.options.hideInputs; - if (window.OverText){ - var otClasses = [null]; - OverText.each(function(ot){ - otClasses.include('.' + ot.options.labelClass); - }); - if (otClasses) hideThese += otClasses.join(', '); - } - return (hideThese) ? object.element.getElements(hideThese) : null; -}; + progress: function(event){ + this.fireEvent('progress', [event, this.xhr]); + }, + timeout: function(){ + this.fireEvent('timeout', this.xhr); + }, -Fx.Reveal = new Class({ + setHeader: function(name, value){ + this.headers[name] = value; + return this; + }, - Extends: Fx.Morph, + getHeader: function(name){ + return Function.attempt(function(){ + return this.xhr.getResponseHeader(name); + }.bind(this)); + }, - options: {/* - onShow: function(thisElement){}, - onHide: function(thisElement){}, - onComplete: function(thisElement){}, - heightOverride: null, - widthOverride: null,*/ - link: 'cancel', - styles: ['padding', 'border', 'margin'], - transitionOpacity: !Browser.ie6, - mode: 'vertical', - display: function(){ - return this.element.get('tag') != 'tr' ? 'block' : 'table-row'; - }, - opacity: 1, - hideInputs: Browser.ie ? 'select, input, textarea, object, embed' : null + check: function(){ + if (!this.running) return true; + switch (this.options.link){ + case 'cancel': this.cancel(); return true; + case 'chain': this.chain(this.caller.pass(arguments, this)); return false; + } + return false; }, - dissolve: function(){ - if (!this.hiding && !this.showing){ - if (this.element.getStyle('display') != 'none'){ - this.hiding = true; - this.showing = false; - this.hidden = true; - this.cssText = this.element.style.cssText; + send: function(options){ + if (!this.check(options)) return this; - var startStyles = this.element.getComputedSize({ - styles: this.options.styles, - mode: this.options.mode - }); - if (this.options.transitionOpacity) startStyles.opacity = this.options.opacity; + this.options.isSuccess = this.options.isSuccess || this.isSuccess; + this.running = true; - var zero = {}; - Object.each(startStyles, function(style, name){ - zero[name] = [style, 0]; - }); + var type = typeOf(options); + if (type == 'string' || type == 'element') options = {data: options}; - this.element.setStyles({ - display: Function.from(this.options.display).call(this), - overflow: 'hidden' - }); + var old = this.options; + options = Object.append({data: old.data, url: old.url, method: old.method}, options); + var data = options.data, url = String(options.url), method = options.method.toLowerCase(); - var hideThese = hideTheseOf(this); - if (hideThese) hideThese.setStyle('visibility', 'hidden'); + switch (typeOf(data)){ + case 'element': data = document.id(data).toQueryString(); break; + case 'object': case 'hash': data = Object.toQueryString(data); + } - this.$chain.unshift(function(){ - if (this.hidden){ - this.hiding = false; - this.element.style.cssText = this.cssText; - this.element.setStyle('display', 'none'); - if (hideThese) hideThese.setStyle('visibility', 'visible'); - } - this.fireEvent('hide', this.element); - this.callChain(); - }.bind(this)); + if (this.options.format){ + var format = 'format=' + this.options.format; + data = (data) ? format + '&' + data : format; + } - this.start(zero); - } else { - this.callChain.delay(10, this); - this.fireEvent('complete', this.element); - this.fireEvent('hide', this.element); - } - } else if (this.options.link == 'chain'){ - this.chain(this.dissolve.bind(this)); - } else if (this.options.link == 'cancel' && !this.hiding){ - this.cancel(); - this.dissolve(); + if (this.options.emulation && !['get', 'post'].contains(method)){ + var _method = '_method=' + method; + data = (data) ? _method + '&' + data : _method; + method = 'post'; } - return this; - }, - reveal: function(){ - if (!this.showing && !this.hiding){ - if (this.element.getStyle('display') == 'none'){ - this.hiding = false; - this.showing = true; - this.hidden = false; - this.cssText = this.element.style.cssText; + if (this.options.urlEncoded && ['post', 'put'].contains(method)){ + var encoding = (this.options.encoding) ? '; charset=' + this.options.encoding : ''; + this.headers['Content-type'] = 'application/x-www-form-urlencoded' + encoding; + } - var startStyles; - this.element.measure(function(){ - startStyles = this.element.getComputedSize({ - styles: this.options.styles, - mode: this.options.mode - }); - }.bind(this)); - if (this.options.heightOverride != null) startStyles.height = this.options.heightOverride.toInt(); - if (this.options.widthOverride != null) startStyles.width = this.options.widthOverride.toInt(); - if (this.options.transitionOpacity){ - this.element.setStyle('opacity', 0); - startStyles.opacity = this.options.opacity; - } + if (!url) url = document.location.pathname; - var zero = { - height: 0, - display: Function.from(this.options.display).call(this) - }; - Object.each(startStyles, function(style, name){ - zero[name] = 0; - }); - zero.overflow = 'hidden'; + var trimPosition = url.lastIndexOf('/'); + if (trimPosition > -1 && (trimPosition = url.indexOf('#')) > -1) url = url.substr(0, trimPosition); - this.element.setStyles(zero); + if (this.options.noCache) + url += (url.contains('?') ? '&' : '?') + String.uniqueID(); - var hideThese = hideTheseOf(this); - if (hideThese) hideThese.setStyle('visibility', 'hidden'); + if (data && method == 'get'){ + url += (url.contains('?') ? '&' : '?') + data; + data = null; + } - this.$chain.unshift(function(){ - this.element.style.cssText = this.cssText; - this.element.setStyle('display', Function.from(this.options.display).call(this)); - if (!this.hidden) this.showing = false; - if (hideThese) hideThese.setStyle('visibility', 'visible'); - this.callChain(); - this.fireEvent('show', this.element); - }.bind(this)); + var xhr = this.xhr; + if (progressSupport){ + xhr.onloadstart = this.loadstart.bind(this); + xhr.onprogress = this.progress.bind(this); + } - this.start(startStyles); - } else { - this.callChain(); - this.fireEvent('complete', this.element); - this.fireEvent('show', this.element); + xhr.open(method.toUpperCase(), url, this.options.async, this.options.user, this.options.password); + if (this.options.user && 'withCredentials' in xhr) xhr.withCredentials = true; + + xhr.onreadystatechange = this.onStateChange.bind(this); + + Object.each(this.headers, function(value, key){ + try { + xhr.setRequestHeader(key, value); + } catch (e){ + this.fireEvent('exception', [key, value]); } - } else if (this.options.link == 'chain'){ - this.chain(this.reveal.bind(this)); - } else if (this.options.link == 'cancel' && !this.showing){ - this.cancel(); - this.reveal(); - } - return this; - }, + }, this); - toggle: function(){ - if (this.element.getStyle('display') == 'none'){ - this.reveal(); - } else { - this.dissolve(); - } + this.fireEvent('request'); + xhr.send(data); + if (!this.options.async) this.onStateChange(); + else if (this.options.timeout) this.timer = this.timeout.delay(this.options.timeout, this); return this; }, cancel: function(){ - this.parent.apply(this, arguments); - if (this.cssText != null) this.element.style.cssText = this.cssText; - this.hiding = false; - this.showing = false; + if (!this.running) return this; + this.running = false; + var xhr = this.xhr; + xhr.abort(); + clearTimeout(this.timer); + xhr.onreadystatechange = empty; + if (progressSupport) xhr.onprogress = xhr.onloadstart = empty; + this.xhr = new Browser.Request(); + this.fireEvent('cancel'); return this; } }); -Element.Properties.reveal = { +var methods = {}; +['get', 'post', 'put', 'delete', 'GET', 'POST', 'PUT', 'DELETE'].each(function(method){ + methods[method] = function(data){ + var object = { + method: method + }; + if (data != null) object.data = data; + return this.send(object); + }; +}); + +Request.implement(methods); + +Element.Properties.send = { set: function(options){ - this.get('reveal').cancel().setOptions(options); + var send = this.get('send').cancel(); + send.setOptions(options); return this; }, get: function(){ - var reveal = this.retrieve('reveal'); - if (!reveal){ - reveal = new Fx.Reveal(this); - this.store('reveal', reveal); + var send = this.retrieve('send'); + if (!send){ + send = new Request({ + data: this, link: 'cancel', method: this.get('method') || 'post', url: this.get('action') + }); + this.store('send', send); } - return reveal; + return send; } }; -Element.Properties.dissolve = Element.Properties.reveal; - Element.implement({ - reveal: function(options){ - this.get('reveal').setOptions(options).reveal(); - return this; - }, - - dissolve: function(options){ - this.get('reveal').setOptions(options).dissolve(); - return this; - }, - - nix: function(options){ - var params = Array.link(arguments, {destroy: Type.isBoolean, options: Type.isObject}); - this.get('reveal').setOptions(options).dissolve().chain(function(){ - this[params.destroy ? 'destroy' : 'dispose'](); - }.bind(this)); + send: function(url){ + var sender = this.get('send'); + sender.send({data: this, url: url || sender.options.url}); return this; - }, - - wink: function(){ - var params = Array.link(arguments, {duration: Type.isNumber, options: Type.isObject}); - var reveal = this.get('reveal').setOptions(params.options); - reveal.reveal().chain(function(){ - (function(){ - reveal.dissolve(); - }).delay(params.duration || 2000); - }); } }); @@ -6988,823 +7563,698 @@ Element.implement({ })(); -// Begin: Source/Delegators/Delegator.FxReveal.js -/* ---- -description: Provides methods to reveal, dissolve, nix, and toggle using Fx.Reveal. -provides: [Delegator.FxReveal, Delegator.Reveal, Delegator.ToggleReveal, Delegator.Dissolve, Delegator.Nix] -requires: [Behavior/Delegator, More/Fx.Reveal] -script: Delegator.FxReveal.js -name: Delegator.FxReveal - -... -*/ -(function(){ - - var triggers = {}; - - ['reveal', 'toggleReveal', 'dissolve', 'nix'].each(function(action){ - - triggers[action] = { - handler: function(event, link, api){ - var targets; - if (api.get('target')){ - targets = new Elements([link.getElement(api.get('target'))]); - if (!targets) api.fail('could not locate target element to ' + action, link); - } else if (api.get('targets')){ - targets = link.getElements(api.get('targets')); - if (!targets.length) api.fail('could not locate target elements to ' + action, link); - } else { - targets = new Elements([link]); - } - - var fxOptions = api.get('fxOptions'); - if (fxOptions) targets.set('reveal', fxOptions); - targets.get('reveal'); - if (action == 'toggleReveal') targets.get('reveal').invoke('toggle'); - else targets[action](); - if (!api.getAs(Boolean, 'allowEvent')) event.preventDefault(); - } - }; - - }); - - Delegator.register('click', triggers); - -})(); - -// Begin: Source/Behaviors/Behavior.BS.Alert.js -/* ---- - -name: Behavior.BS.Alert - -description: This file just depends on the Fx.Reveal delegator in More-Behaviors to ensure you get it if you load the entire Bootstrap JS package. - -license: MIT-style license. - -authors: [Aaron Newton] - -requires: - - More-Behaviors/Delegator.Nix - -provides: [Behavior.BS.Alert] - -... -*/ - -// Begin: Source/UI/Bootstrap.js -/* ---- - -name: Bootstrap - -description: The BootStrap namespace. - -authors: [Aaron Newton] - -license: MIT-style license. - -provides: [Bootstrap] - -... -*/ -var Bootstrap = {}; - -// Begin: Source/Utilities/DOMReady.js +// Begin: Source/Request/Request.HTML.js /* --- -name: DOMReady +name: Request.HTML -description: Contains the custom event domready. +description: Extends the basic Request Class with additional methods for interacting with HTML responses. license: MIT-style license. -requires: [Browser, Element, Element.Event] +requires: [Element, Request] -provides: [DOMReady, DomReady] +provides: Request.HTML ... */ -(function(window, document){ +Request.HTML = new Class({ -var ready, - loaded, - checks = [], - shouldPoll, - timer, - testElement = document.createElement('div'); + Extends: Request, -var domready = function(){ - clearTimeout(timer); - if (ready) return; - Browser.loaded = ready = true; - document.removeListener('DOMContentLoaded', domready).removeListener('readystatechange', check); + options: { + update: false, + append: false, + evalScripts: true, + filter: false, + headers: { + Accept: 'text/html, application/xml, text/xml, */*' + } + }, - document.fireEvent('domready'); - window.fireEvent('domready'); -}; + success: function(text){ + var options = this.options, response = this.response; -var check = function(){ - for (var i = checks.length; i--;) if (checks[i]()){ - domready(); - return true; - } - return false; -}; + response.html = text.stripScripts(function(script){ + response.javascript = script; + }); -var poll = function(){ - clearTimeout(timer); - if (!check()) timer = setTimeout(poll, 10); -}; + var match = response.html.match(/]*>([\s\S]*?)<\/body>/i); + if (match) response.html = match[1]; + var temp = new Element('div').set('html', response.html); -document.addListener('DOMContentLoaded', domready); + response.tree = temp.childNodes; + response.elements = temp.getElements(options.filter || '*'); -/**/ -// doScroll technique by Diego Perini http://javascript.nwbox.com/IEContentLoaded/ -// testElement.doScroll() throws when the DOM is not ready, only in the top window -var doScrollWorks = function(){ - try { - testElement.doScroll(); - return true; - } catch (e){} - return false; -}; -// If doScroll works already, it can't be used to determine domready -// e.g. in an iframe -if (testElement.doScroll && !doScrollWorks()){ - checks.push(doScrollWorks); - shouldPoll = true; -} -/**/ + if (options.filter) response.tree = response.elements; + if (options.update){ + var update = document.id(options.update).empty(); + if (options.filter) update.adopt(response.elements); + else update.set('html', response.html); + } else if (options.append){ + var append = document.id(options.append); + if (options.filter) response.elements.reverse().inject(append); + else append.adopt(temp.getChildren()); + } + if (options.evalScripts) Browser.exec(response.javascript); + + this.onSuccess(response.tree, response.elements, response.html, response.javascript); + } -if (document.readyState) checks.push(function(){ - var state = document.readyState; - return (state == 'loaded' || state == 'complete'); }); -if ('onreadystatechange' in document) document.addListener('readystatechange', check); -else shouldPoll = true; +Element.Properties.load = { -if (shouldPoll) poll(); + set: function(options){ + var load = this.get('load').cancel(); + load.setOptions(options); + return this; + }, -Element.Events.domready = { - onAdd: function(fn){ - if (ready) fn.call(this); + get: function(){ + var load = this.retrieve('load'); + if (!load){ + load = new Request.HTML({data: this, link: 'cancel', update: this, method: 'get'}); + this.store('load', load); + } + return load; } + }; -// Make sure that domready fires before load -Element.Events.load = { - base: 'load', - onAdd: function(fn){ - if (loaded && this == window) fn.call(this); - }, - condition: function(){ - if (this == window){ - domready(); - delete Element.Events.load; - } - return true; +Element.implement({ + + load: function(){ + this.get('load').send(Array.link(arguments, {data: Type.isObject, url: Type.isString})); + return this; } -}; -// This is based on the custom load event -window.addEvent('load', function(){ - loaded = true; }); -})(window, document); - -// Begin: Source/UI/CSSEvents.js +// Begin: Source/Class/Class.Binds.js /* --- -name: CSSEvents +script: Class.Binds.js -license: MIT-style +name: Class.Binds -authors: [Aaron Newton] +description: Automagically binds specified methods in a class to the instance of the class. -requires: [Core/DomReady] +license: MIT-style license + +authors: + - Aaron Newton + +requires: + - Core/Class + - /MooTools.More + +provides: [Class.Binds] -provides: CSSEvents ... */ -Browser.Features.getCSSTransition = function(){ - Browser.Features.cssTransition = (function () { - var thisBody = document.body || document.documentElement - , thisStyle = thisBody.style - , support = thisStyle.transition !== undefined || thisStyle.WebkitTransition !== undefined || thisStyle.MozTransition !== undefined || thisStyle.MsTransition !== undefined || thisStyle.OTransition !== undefined; - return support; - })(); +Class.Mutators.Binds = function(binds){ + if (!this.prototype.initialize) this.implement('initialize', function(){}); + return Array.from(binds).concat(this.prototype.Binds || []); +}; - // set CSS transition event type - if ( Browser.Features.cssTransition ) { - Browser.Features.transitionEnd = "TransitionEnd"; - if ( Browser.webkit || Browser.chrome ) { - Browser.Features.transitionEnd = "webkitTransitionEnd"; - } else if ( Browser.firefox ) { - Browser.Features.transitionEnd = "transitionend"; - } else if ( Browser.opera ) { - Browser.Features.transitionEnd = "oTransitionEnd"; - } - } - Browser.Features.getCSSTransition = Function.from(Browser.Features.transitionEnd); +Class.Mutators.initialize = function(initialize){ + return function(){ + Array.from(this.Binds).each(function(name){ + var original = this[name]; + if (original) this[name] = original.bind(this); + }, this); + return initialize.apply(this, arguments); + }; }; -window.addEvent("domready", Browser.Features.getCSSTransition); -// Begin: Source/Element/Element.Position.js +// Begin: Source/Class/Class.Occlude.js /* --- -script: Element.Position.js +script: Class.Occlude.js -name: Element.Position +name: Class.Occlude -description: Extends the Element native object to include methods useful positioning elements relative to others. +description: Prevents a class from being applied to a DOM element twice. -license: MIT-style license +license: MIT-style license. authors: - Aaron Newton - - Jacob Thornton requires: - - Core/Options - - Core/Element.Dimensions - - Element.Measure + - Core/Class + - Core/Element + - /MooTools.More -provides: [Element.Position] +provides: [Class.Occlude] ... */ -(function(original){ - -var local = Element.Position = { +Class.Occlude = new Class({ - options: {/* - edge: false, - returnPos: false, - minimum: {x: 0, y: 0}, - maximum: {x: 0, y: 0}, - relFixedPosition: false, - ignoreMargins: false, - ignoreScroll: false, - allowNegative: false,*/ - relativeTo: document.body, - position: { - x: 'center', //left, center, right - y: 'center' //top, center, bottom - }, - offset: {x: 0, y: 0} - }, + occlude: function(property, element){ + element = document.id(element || this.element); + var instance = element.retrieve(property || this.property); + if (instance && !this.occluded) + return (this.occluded = instance); - getOptions: function(element, options){ - options = Object.merge({}, local.options, options); - local.setPositionOption(options); - local.setEdgeOption(options); - local.setOffsetOption(element, options); - local.setDimensionsOption(element, options); - return options; - }, + this.occluded = false; + element.store(property || this.property, this); + return this.occluded; + } - setPositionOption: function(options){ - options.position = local.getCoordinateFromValue(options.position); - }, +}); - setEdgeOption: function(options){ - var edgeOption = local.getCoordinateFromValue(options.edge); - options.edge = edgeOption ? edgeOption : - (options.position.x == 'center' && options.position.y == 'center') ? {x: 'center', y: 'center'} : - {x: 'left', y: 'top'}; - }, - setOffsetOption: function(element, options){ - var parentOffset = {x: 0, y: 0}, - offsetParent = element.measure(function(){ - return document.id(this.getOffsetParent()); - }), - parentScroll = offsetParent.getScroll(); +// Begin: Source/Fx/Fx.js +/* +--- - if (!offsetParent || offsetParent == element.getDocument().body) return; - parentOffset = offsetParent.measure(function(){ - var position = this.getPosition(); - if (this.getStyle('position') == 'fixed'){ - var scroll = window.getScroll(); - position.x += scroll.x; - position.y += scroll.y; - } - return position; - }); +name: Fx - options.offset = { - parentPositioned: offsetParent != document.id(options.relativeTo), - x: options.offset.x - parentOffset.x + parentScroll.x, - y: options.offset.y - parentOffset.y + parentScroll.y - }; - }, +description: Contains the basic animation logic to be extended by all other Fx Classes. - setDimensionsOption: function(element, options){ - options.dimensions = element.getDimensions({ - computeSize: true, - styles: ['padding', 'border', 'margin'] - }); - }, +license: MIT-style license. - getPosition: function(element, options){ - var position = {}; - options = local.getOptions(element, options); - var relativeTo = document.id(options.relativeTo) || document.body; +requires: [Chain, Events, Options] - local.setPositionCoordinates(options, position, relativeTo); - if (options.edge) local.toEdge(position, options); +provides: Fx - var offset = options.offset; - position.left = ((position.x >= 0 || offset.parentPositioned || options.allowNegative) ? position.x : 0).toInt(); - position.top = ((position.y >= 0 || offset.parentPositioned || options.allowNegative) ? position.y : 0).toInt(); +... +*/ - local.toMinMax(position, options); +(function(){ - if (options.relFixedPosition || relativeTo.getStyle('position') == 'fixed') local.toRelFixedPosition(relativeTo, position); - if (options.ignoreScroll) local.toIgnoreScroll(relativeTo, position); - if (options.ignoreMargins) local.toIgnoreMargins(position, options); +var Fx = this.Fx = new Class({ - position.left = Math.ceil(position.left); - position.top = Math.ceil(position.top); - delete position.x; - delete position.y; + Implements: [Chain, Events, Options], - return position; + options: { + /* + onStart: nil, + onCancel: nil, + onComplete: nil, + */ + fps: 60, + unit: false, + duration: 500, + frames: null, + frameSkip: true, + link: 'ignore' }, - setPositionCoordinates: function(options, position, relativeTo){ - var offsetY = options.offset.y, - offsetX = options.offset.x, - calc = (relativeTo == document.body) ? window.getScroll() : relativeTo.getPosition(), - top = calc.y, - left = calc.x, - winSize = window.getSize(); + initialize: function(options){ + this.subject = this.subject || this; + this.setOptions(options); + }, - switch(options.position.x){ - case 'left': position.x = left + offsetX; break; - case 'right': position.x = left + offsetX + relativeTo.offsetWidth; break; - default: position.x = left + ((relativeTo == document.body ? winSize.x : relativeTo.offsetWidth) / 2) + offsetX; break; + getTransition: function(){ + return function(p){ + return -(Math.cos(Math.PI * p) - 1) / 2; + }; + }, + + step: function(now){ + if (this.options.frameSkip){ + var diff = (this.time != null) ? (now - this.time) : 0, frames = diff / this.frameInterval; + this.time = now; + this.frame += frames; + } else { + this.frame++; } - switch(options.position.y){ - case 'top': position.y = top + offsetY; break; - case 'bottom': position.y = top + offsetY + relativeTo.offsetHeight; break; - default: position.y = top + ((relativeTo == document.body ? winSize.y : relativeTo.offsetHeight) / 2) + offsetY; break; + if (this.frame < this.frames){ + var delta = this.transition(this.frame / this.frames); + this.set(this.compute(this.from, this.to, delta)); + } else { + this.frame = this.frames; + this.set(this.compute(this.from, this.to, 1)); + this.stop(); } }, - toMinMax: function(position, options){ - var xy = {left: 'x', top: 'y'}, value; - ['minimum', 'maximum'].each(function(minmax){ - ['left', 'top'].each(function(lr){ - value = options[minmax] ? options[minmax][xy[lr]] : null; - if (value != null && ((minmax == 'minimum') ? position[lr] < value : position[lr] > value)) position[lr] = value; - }); - }); + set: function(now){ + return now; }, - toRelFixedPosition: function(relativeTo, position){ - var winScroll = window.getScroll(); - position.top += winScroll.y; - position.left += winScroll.x; + compute: function(from, to, delta){ + return Fx.compute(from, to, delta); }, - toIgnoreScroll: function(relativeTo, position){ - var relScroll = relativeTo.getScroll(); - position.top -= relScroll.y; - position.left -= relScroll.x; + check: function(){ + if (!this.isRunning()) return true; + switch (this.options.link){ + case 'cancel': this.cancel(); return true; + case 'chain': this.chain(this.caller.pass(arguments, this)); return false; + } + return false; }, - toIgnoreMargins: function(position, options){ - position.left += options.edge.x == 'right' - ? options.dimensions['margin-right'] - : (options.edge.x != 'center' - ? -options.dimensions['margin-left'] - : -options.dimensions['margin-left'] + ((options.dimensions['margin-right'] + options.dimensions['margin-left']) / 2)); - - position.top += options.edge.y == 'bottom' - ? options.dimensions['margin-bottom'] - : (options.edge.y != 'center' - ? -options.dimensions['margin-top'] - : -options.dimensions['margin-top'] + ((options.dimensions['margin-bottom'] + options.dimensions['margin-top']) / 2)); + start: function(from, to){ + if (!this.check(from, to)) return this; + this.from = from; + this.to = to; + this.frame = (this.options.frameSkip) ? 0 : -1; + this.time = null; + this.transition = this.getTransition(); + var frames = this.options.frames, fps = this.options.fps, duration = this.options.duration; + this.duration = Fx.Durations[duration] || duration.toInt(); + this.frameInterval = 1000 / fps; + this.frames = frames || Math.round(this.duration / this.frameInterval); + this.fireEvent('start', this.subject); + pushInstance.call(this, fps); + return this; }, - toEdge: function(position, options){ - var edgeOffset = {}, - dimensions = options.dimensions, - edge = options.edge; - - switch(edge.x){ - case 'left': edgeOffset.x = 0; break; - case 'right': edgeOffset.x = -dimensions.x - dimensions.computedRight - dimensions.computedLeft; break; - // center - default: edgeOffset.x = -(Math.round(dimensions.totalWidth / 2)); break; + stop: function(){ + if (this.isRunning()){ + this.time = null; + pullInstance.call(this, this.options.fps); + if (this.frames == this.frame){ + this.fireEvent('complete', this.subject); + if (!this.callChain()) this.fireEvent('chainComplete', this.subject); + } else { + this.fireEvent('stop', this.subject); + } } + return this; + }, - switch(edge.y){ - case 'top': edgeOffset.y = 0; break; - case 'bottom': edgeOffset.y = -dimensions.y - dimensions.computedTop - dimensions.computedBottom; break; - // center - default: edgeOffset.y = -(Math.round(dimensions.totalHeight / 2)); break; + cancel: function(){ + if (this.isRunning()){ + this.time = null; + pullInstance.call(this, this.options.fps); + this.frame = this.frames; + this.fireEvent('cancel', this.subject).clearChain(); } - - position.x += edgeOffset.x; - position.y += edgeOffset.y; + return this; }, - getCoordinateFromValue: function(option){ - if (typeOf(option) != 'string') return option; - option = option.toLowerCase(); - - return { - x: option.test('left') ? 'left' - : (option.test('right') ? 'right' : 'center'), - y: option.test(/upper|top/) ? 'top' - : (option.test('bottom') ? 'bottom' : 'center') - }; - } - -}; - -Element.implement({ - - position: function(options){ - if (options && (options.x != null || options.y != null)){ - return (original ? original.apply(this, arguments) : this); + pause: function(){ + if (this.isRunning()){ + this.time = null; + pullInstance.call(this, this.options.fps); } - var position = this.setStyle('position', 'absolute').calculatePosition(options); - return (options && options.returnPos) ? position : this.setStyles(position); + return this; }, - calculatePosition: function(options){ - return local.getPosition(this, options); + resume: function(){ + if ((this.frame < this.frames) && !this.isRunning()) pushInstance.call(this, this.options.fps); + return this; + }, + + isRunning: function(){ + var list = instances[this.options.fps]; + return list && list.contains(this); } }); -})(Element.prototype.position); - - -// Begin: Source/UI/Bootstrap.Twipsy.js -/* ---- - -name: Bootstrap.Tooltip - -description: A simple tooltip implementation that works with the Twitter Bootstrap css framework. +Fx.compute = function(from, to, delta){ + return (to - from) * delta + from; +}; -authors: [Aaron Newton] +Fx.Durations = {'short': 250, 'normal': 500, 'long': 1000}; -license: MIT-style license. +// global timers -requires: - - /Bootstrap - - /CSSEvents - - More/Element.Position - - Behavior/Behavior +var instances = {}, timers = {}; -provides: [Bootstrap.Twipsy, Bootstrap.Tooltip] +var loop = function(){ + var now = Date.now(); + for (var i = this.length; i--;){ + var instance = this[i]; + if (instance) instance.step(now); + } +}; -... -*/ +var pushInstance = function(fps){ + var list = instances[fps] || (instances[fps] = []); + list.push(this); + if (!timers[fps]) timers[fps] = loop.periodical(Math.round(1000 / fps), list); +}; -Bootstrap.Tooltip = Bootstrap.Twipsy = new Class({ +var pullInstance = function(fps){ + var list = instances[fps]; + if (list){ + list.erase(this); + if (!list.length && timers[fps]){ + delete instances[fps]; + timers[fps] = clearInterval(timers[fps]); + } + } +}; - Implements: [Options, Events], +})(); - options: { - location: 'above', //below, left, right, bottom, top - animate: true, - delayIn: 200, - delayOut: 0, - fallback: '', - override: '', - onOverflow: false, - offset: 0, - title: 'title', //element property - trigger: 'hover', //focus, manual - getContent: function(el){ - return el.get(this.options.title); - } - }, - initialize: function(el, options){ - this.element = document.id(el); - this.setOptions(options); - this._attach(); - }, +// Begin: Source/Fx/Fx.CSS.js +/* +--- - show: function(){ - this._clear(); - this._makeTip(); - var pos, edge, offset = {x: 0, y: 0}; - switch(this.options.location){ - case 'below': case 'bottom': - pos = 'centerBottom'; - edge = 'centerTop'; - offset.y = this.options.offset; - break; - case 'left': - pos = 'centerLeft'; - edge = 'centerRight'; - offset.x = this.options.offset; - break; - case 'right': - pos = 'centerRight'; - edge = 'centerLeft'; - offset.x = this.options.offset; - break; - default: //top - pos = 'centerTop'; - edge = 'centerBottom'; - offset.y = this.options.offset; - } - if (typeOf(this.options.offset) == "object") offset = this.options.offset; - this.tip.inject(document.body).show().position({ - relativeTo: this.element, - position: pos, - edge: edge, - offset: offset - }).removeClass('out').addClass('in'); - this.visible = true; - if (!Browser.Features.cssTransition || !this.options.animate) this._complete(); - this.fireEvent('show'); - return this; - }, +name: Fx.CSS - hide: function(){ - this._makeTip(); - this.tip.removeClass('in').addClass('out'); - this.visible = false; - if (!Browser.Features.cssTransition || !this.options.animate) this._complete(); - this.fireEvent('hide'); - return this; - }, +description: Contains the CSS animation logic. Used by Fx.Tween, Fx.Morph, Fx.Elements. - destroy: function(){ - this._detach(); - if (this.tip) this.tip.destroy(); - this.destroyed = true; - return this; - }, +license: MIT-style license. - // PRIVATE METHODS +requires: [Fx, Element.Style] - _makeTip: function(){ - if (!this.tip){ - var location = this.options.location; - if (location == 'above') location = 'top'; //bootstrap 2.0 - if (location == 'below') location = 'bottom'; //bootstrap 2.0 - this.tip = new Element('div.tooltip').addClass(location) - .adopt(new Element('div.tooltip-arrow')) - .adopt( - new Element('div.tooltip-inner', { - html: this.options.override || this.options.getContent.apply(this, [this.element]) || this.options.fallback - }) - ); - if (this.options.animate) this.tip.addClass('fade'); - if (Browser.Features.cssTransition && this.tip.addEventListener){ - this.tip.addEventListener(Browser.Features.transitionEnd, this.bound.complete); +provides: Fx.CSS + +... +*/ + +Fx.CSS = new Class({ + + Extends: Fx, + + //prepares the base from/to object + + prepare: function(element, property, values){ + values = Array.from(values); + var from = values[0], to = values[1]; + if (to == null){ + to = from; + from = element.getStyle(property); + var unit = this.options.unit; + // adapted from: https://github.com/ryanmorr/fx/blob/master/fx.js#L299 + if (unit && from.slice(-unit.length) != unit && parseFloat(from) != 0){ + element.setStyle(property, to + unit); + var value = element.getComputedStyle(property); + // IE and Opera support pixelLeft or pixelWidth + if (!(/px$/.test(value))){ + value = element.style[('pixel-' + property).camelCase()]; + if (value == null){ + // adapted from Dean Edwards' http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291 + var left = element.style.left; + element.style.left = to + unit; + value = element.style.pixelLeft; + element.style.left = left; + } + } + from = (to || 1) / (parseFloat(value) || 1) * (parseFloat(from) || 0); + element.setStyle(property, from + unit); } - this.element.set('alt', '').set('title', ''); } - return this.tip; + return {from: this.parse(from), to: this.parse(to)}; }, - _attach: function(method){ - method = method || 'addEvents'; - this.bound = { - enter: this._enter.bind(this), - leave: this._leave.bind(this), - complete: this._complete.bind(this) - }; + //parses a value into an array - if (this.options.trigger == 'hover') { - this.element[method]({ - mouseenter: this.bound.enter, - mouseleave: this.bound.leave - }); - } else if (this.options.trigger == 'focus'){ - this.element[method]({ - focus: this.bound.enter, - blur: this.bound.leave + parse: function(value){ + value = Function.from(value)(); + value = (typeof value == 'string') ? value.split(' ') : Array.from(value); + return value.map(function(val){ + val = String(val); + var found = false; + Object.each(Fx.CSS.Parsers, function(parser, key){ + if (found) return; + var parsed = parser.parse(val); + if (parsed || parsed === 0) found = {value: parsed, parser: parser}; }); - } + found = found || {value: val, parser: Fx.CSS.Parsers.String}; + return found; + }); }, - _detach: function(){ - this._attach('removeEvents'); + //computes by a from and to prepared objects, using their parsers. + + compute: function(from, to, delta){ + var computed = []; + (Math.min(from.length, to.length)).times(function(i){ + computed.push({value: from[i].parser.compute(from[i].value, to[i].value, delta), parser: from[i].parser}); + }); + computed.$family = Function.from('fx:css:value'); + return computed; }, - _clear: function(){ - clearTimeout(this._inDelay); - clearTimeout(this._outDelay); + //serves the value as settable + + serve: function(value, unit){ + if (typeOf(value) != 'fx:css:value') value = this.parse(value); + var returned = []; + value.each(function(bit){ + returned = returned.concat(bit.parser.serve(bit.value, unit)); + }); + return returned; }, - _enter: function(){ - if (this.options.onOverflow){ - var scroll = this.element.getScrollSize(), - size = this.element.getSize(); - if (scroll.x <= size.x && scroll.y <= size.y) return; - } - this._clear(); - if (this.options.delayIn){ - this._inDelay = this.show.delay(this.options.delayIn, this); - } else { - this.show(); + //renders the change to an element + + render: function(element, property, value, unit){ + element.setStyle(property, this.serve(value, unit)); + }, + + //searches inside the page css to find the values for a selector + + search: function(selector){ + if (Fx.CSS.Cache[selector]) return Fx.CSS.Cache[selector]; + var to = {}, selectorTest = new RegExp('^' + selector.escapeRegExp() + '$'); + Array.each(document.styleSheets, function(sheet, j){ + var href = sheet.href; + if (href && href.contains('://') && !href.contains(document.domain)) return; + var rules = sheet.rules || sheet.cssRules; + Array.each(rules, function(rule, i){ + if (!rule.style) return; + var selectorText = (rule.selectorText) ? rule.selectorText.replace(/^\w+/, function(m){ + return m.toLowerCase(); + }) : null; + if (!selectorText || !selectorTest.test(selectorText)) return; + Object.each(Element.Styles, function(value, style){ + if (!rule.style[style] || Element.ShortStyles[style]) return; + value = String(rule.style[style]); + to[style] = ((/^rgb/).test(value)) ? value.rgbToHex() : value; + }); + }); + }); + return Fx.CSS.Cache[selector] = to; + } + +}); + +Fx.CSS.Cache = {}; + +Fx.CSS.Parsers = { + + Color: { + parse: function(value){ + if (value.match(/^#[0-9a-f]{3,6}$/i)) return value.hexToRgb(true); + return ((value = value.match(/(\d+),\s*(\d+),\s*(\d+)/))) ? [value[1], value[2], value[3]] : false; + }, + compute: function(from, to, delta){ + return from.map(function(value, i){ + return Math.round(Fx.compute(from[i], to[i], delta)); + }); + }, + serve: function(value){ + return value.map(Number); } }, - _leave: function(){ - this._clear(); - if (this.options.delayOut){ - this._outDelay = this.hide.delay(this.options.delayOut, this); - } else { - this.hide(); + Number: { + parse: parseFloat, + compute: Fx.compute, + serve: function(value, unit){ + return (unit) ? value + unit : value; } }, - _complete: function(){ - if (!this.visible){ - this.tip.dispose(); + String: { + parse: Function.from(false), + compute: function(zero, one){ + return one; + }, + serve: function(zero){ + return zero; } - this.fireEvent('complete', this.visible); } -}); +}; -// Begin: Source/UI/Bootstrap.Dropdown.js +//<1.2compat> + +Fx.CSS.Parsers = new Hash(Fx.CSS.Parsers); + +// + + +// Begin: Source/Fx/Fx.Tween.js /* --- -name: Bootstrap.Dropdown +name: Fx.Tween -description: A simple dropdown menu that works with the Twitter Bootstrap css framework. +description: Formerly Fx.Style, effect to transition any CSS property for an element. license: MIT-style license. -authors: [Aaron Newton] - -requires: - - /Bootstrap - - Core/Element.Event - - More/Element.Shortcuts +requires: Fx.CSS -provides: Bootstrap.Dropdown +provides: [Fx.Tween, Element.fade, Element.highlight] ... */ -Bootstrap.Dropdown = new Class({ - - Implements: [Options, Events], - - options: { - /* - onShow: function(element){}, - onHide: function(elements){}, - */ - ignore: 'input, select, label' - }, - - initialize: function(container, options){ - this.element = document.id(container); - this.setOptions(options); - this.boundHandle = this._handle.bind(this); - document.id(document.body).addEvent('click', this.boundHandle); - }, - - hideAll: function(){ - var els = this.element.getElements('.open').removeClass('open'); - this.fireEvent('hide', els); - return this; - }, - - show: function(subMenu){ - this.hideAll(); - this.fireEvent('show', subMenu); - subMenu.addClass('open'); - return this; - }, - - destroy: function(){ - this.hideAll(); - document.body.removeEvent('click', this.boundHandle); - return this; - }, - // PRIVATE +Fx.Tween = new Class({ - _handle: function(e){ - var el = e.target; - var open = el.getParent('.open'); - if (!el.match(this.options.ignore) || !open) this.hideAll(); - if (this.element.contains(el)) { - var parent = null; - if (el.match('[data-toggle="dropdown"]') || el.getParent('[data-toggle="dropdown"] !')) { - parent = el.getParent('.dropdown !') || el.getParent('.btn-group !'); - } - // backwards compatibility - if (!parent) parent = el.match('.dropdown-toggle') ? el.getParent() : el.getParent('.dropdown-toggle !'); + Extends: Fx.CSS, + initialize: function(element, options){ + this.element = this.subject = document.id(element); + this.parent(options); + }, - if (parent) { - e.preventDefault(); - if (!open) this.show(parent); - } + set: function(property, now){ + if (arguments.length == 1){ + now = property; + property = this.property || this.options.property; } + this.render(this.element, property, now, this.options.unit); + return this; + }, + + start: function(property, from, to){ + if (!this.check(property, from, to)) return this; + var args = Array.flatten(arguments); + this.property = this.options.property || args.shift(); + var parsed = this.prepare(this.element, this.property, args); + return this.parent(parsed.from, parsed.to); } + }); -// Begin: Source/Behaviors/Behavior.BS.Dropdown.js -/* ---- +Element.Properties.tween = { -name: Behavior.BS.Dropdown + set: function(options){ + this.get('tween').cancel().setOptions(options); + return this; + }, -description: Instantiates Bootstrap.Dropdown based on HTML markup. + get: function(){ + var tween = this.retrieve('tween'); + if (!tween){ + tween = new Fx.Tween(this, {link: 'cancel'}); + this.store('tween', tween); + } + return tween; + } -license: MIT-style license. +}; -authors: [Aaron Newton] +Element.implement({ -requires: - - Behavior/Behavior - - Bootstrap.Dropdown + tween: function(property, from, to){ + this.get('tween').start(property, from, to); + return this; + }, -provides: [Behavior.BS.Dropdown] + fade: function(how){ + var fade = this.get('tween'), method, args = ['opacity'].append(arguments), toggle; + if (args[1] == null) args[1] = 'toggle'; + switch (args[1]){ + case 'in': method = 'start'; args[1] = 1; break; + case 'out': method = 'start'; args[1] = 0; break; + case 'show': method = 'set'; args[1] = 1; break; + case 'hide': method = 'set'; args[1] = 0; break; + case 'toggle': + var flag = this.retrieve('fade:flag', this.getStyle('opacity') == 1); + method = 'start'; + args[1] = flag ? 0 : 1; + this.store('fade:flag', !flag); + toggle = true; + break; + default: method = 'start'; + } + if (!toggle) this.eliminate('fade:flag'); + fade[method].apply(fade, args); + var to = args[args.length - 1]; + if (method == 'set' || to != 0) this.setStyle('visibility', to == 0 ? 'hidden' : 'visible'); + else fade.chain(function(){ + this.element.setStyle('visibility', 'hidden'); + this.callChain(); + }); + return this; + }, -... -*/ -Behavior.addGlobalFilters({ - 'BS.Dropdown': { - returns: Bootstrap.Dropdown, - setup: function(el, api){ - return new Bootstrap.Dropdown(el); + highlight: function(start, end){ + if (!end){ + end = this.retrieve('highlight:original', this.getStyle('background-color')); + end = (end == 'transparent') ? '#fff' : end; } + var tween = this.get('tween'); + tween.start('background-color', start || '#ffff88', end).chain(function(){ + this.setStyle('background-color', this.retrieve('highlight:original')); + tween.callChain(); + }.bind(this)); + return this; } + }); -// Begin: Source/UI/Delegator.BS.ShowPopup.js + +// Begin: Source/Class/Class.Refactor.js /* --- -name: Delegator.BS.ShowPopup +script: Class.Refactor.js -description: Shows a hidden popup. +name: Class.Refactor -authors: [Aaron Newton] +description: Extends a class onto itself with new property, preserving any items attached to the class's namespace. -license: MIT-style license. +license: MIT-style license + +authors: + - Aaron Newton requires: - - Behavior/Delegator - - Behavior/Behavior + - Core/Class + - /MooTools.More -provides: [Delegator.BS.ShowPopup] +# Some modules declare themselves dependent on Class.Refactor +provides: [Class.refactor, Class.Refactor] ... */ -(function(){ - - +Class.refactor = function(original, refactors){ - Delegator.register('click', 'BS.showPopup', { + Object.each(refactors, function(item, name){ + var origin = original.prototype[name]; + origin = (origin && origin.$origin) || origin || function(){}; + original.implement(name, (typeof item == 'function') ? function(){ + var old = this.previous; + this.previous = origin; + var value = item.apply(this, arguments); + this.previous = old; + return value; + } : item); + }); - require: ['target'], - handler: function(event, link, api){ - var target = link.getElement(api.get('target')); - event.preventDefault(); - if (!target) api.fail('Could not find target element to activate: ', api.get('target')); - api.getBehavior().apply(target); - target.getBehaviorResult('BS.Popup').show(); - } + return original; - }); +}; -})(); -// Begin: Source/Types/Object.Extras.js +// Begin: Source/Utilities/IframeShim.js /* --- -script: Object.Extras.js +script: IframeShim.js -name: Object.Extras +name: IframeShim -description: Extra Object generics, like getFromPath which allows a path notation to child elements. +description: Defines IframeShim, a class for obscuring select lists and flash objects in IE. license: MIT-style license @@ -7812,2256 +8262,2635 @@ authors: - Aaron Newton requires: - - Core/Object - - /MooTools.More + - Core/Element.Event + - Core/Element.Style + - Core/Options + - Core/Events + - /Element.Position + - /Class.Occlude -provides: [Object.Extras] +provides: [IframeShim] ... */ -(function(){ +var IframeShim = new Class({ -var defined = function(value){ - return value != null; -}; + Implements: [Options, Events, Class.Occlude], -var hasOwnProperty = Object.prototype.hasOwnProperty; + options: { + className: 'iframeShim', + src: 'javascript:false;document.write("");', + display: false, + zIndex: null, + margin: 0, + offset: {x: 0, y: 0}, + browsers: (Browser.ie6 || (Browser.firefox && Browser.version < 3 && Browser.Platform.mac)) + }, -Object.extend({ + property: 'IframeShim', - getFromPath: function(source, parts){ - if (typeof parts == 'string') parts = parts.split('.'); - for (var i = 0, l = parts.length; i < l; i++){ - if (hasOwnProperty.call(source, parts[i])) source = source[parts[i]]; - else return null; + initialize: function(element, options){ + this.element = document.id(element); + if (this.occlude()) return this.occluded; + this.setOptions(options); + this.makeShim(); + return this; + }, + + makeShim: function(){ + if (this.options.browsers){ + var zIndex = this.element.getStyle('zIndex').toInt(); + + if (!zIndex){ + zIndex = 1; + var pos = this.element.getStyle('position'); + if (pos == 'static' || !pos) this.element.setStyle('position', 'relative'); + this.element.setStyle('zIndex', zIndex); + } + zIndex = ((this.options.zIndex != null || this.options.zIndex === 0) && zIndex > this.options.zIndex) ? this.options.zIndex : zIndex - 1; + if (zIndex < 0) zIndex = 1; + this.shim = new Element('iframe', { + src: this.options.src, + scrolling: 'no', + frameborder: 0, + styles: { + zIndex: zIndex, + position: 'absolute', + border: 'none', + filter: 'progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0)' + }, + 'class': this.options.className + }).store('IframeShim', this); + var inject = (function(){ + this.shim.inject(this.element, 'after'); + this[this.options.display ? 'show' : 'hide'](); + this.fireEvent('inject'); + }).bind(this); + if (!IframeShim.ready) window.addEvent('load', inject); + else inject(); + } else { + this.position = this.hide = this.show = this.dispose = Function.from(this); } - return source; }, - cleanValues: function(object, method){ - method = method || defined; - for (var key in object) if (!method(object[key])){ - delete object[key]; + position: function(){ + if (!IframeShim.ready || !this.shim) return this; + var size = this.element.measure(function(){ + return this.getSize(); + }); + if (this.options.margin != undefined){ + size.x = size.x - (this.options.margin * 2); + size.y = size.y - (this.options.margin * 2); + this.options.offset.x += this.options.margin; + this.options.offset.y += this.options.margin; } - return object; + this.shim.set({width: size.x, height: size.y}).position({ + relativeTo: this.element, + offset: this.options.offset + }); + return this; }, - erase: function(object, key){ - if (hasOwnProperty.call(object, key)) delete object[key]; - return object; + hide: function(){ + if (this.shim) this.shim.setStyle('display', 'none'); + return this; }, - run: function(object){ - var args = Array.slice(arguments, 1); - for (var key in object) if (object[key].apply){ - object[key].apply(object, args); - } - return object; + show: function(){ + if (this.shim) this.shim.setStyle('display', 'block'); + return this.position(); + }, + + dispose: function(){ + if (this.shim) this.shim.dispose(); + return this; + }, + + destroy: function(){ + if (this.shim) this.shim.destroy(); + return this; } }); -})(); +window.addEvent('load', function(){ + IframeShim.ready = true; +}); -// Begin: Source/Fx/Fx.Tween.js +// Begin: Source/Interface/Mask.js /* --- -name: Fx.Tween +script: Mask.js -description: Formerly Fx.Style, effect to transition any CSS property for an element. +name: Mask -license: MIT-style license. +description: Creates a mask element to cover another. -requires: Fx.CSS +license: MIT-style license -provides: [Fx.Tween, Element.fade, Element.highlight] +authors: + - Aaron Newton + +requires: + - Core/Options + - Core/Events + - Core/Element.Event + - /Class.Binds + - /Element.Position + - /IframeShim + +provides: [Mask] ... */ -Fx.Tween = new Class({ +var Mask = new Class({ - Extends: Fx.CSS, + Implements: [Options, Events], - initialize: function(element, options){ - this.element = this.subject = document.id(element); - this.parent(options); - }, + Binds: ['position'], - set: function(property, now){ - if (arguments.length == 1){ - now = property; - property = this.property || this.options.property; - } - this.render(this.element, property, now, this.options.unit); - return this; + options: {/* + onShow: function(){}, + onHide: function(){}, + onDestroy: function(){}, + onClick: function(event){}, + inject: { + where: 'after', + target: null, + }, + hideOnClick: false, + id: null, + destroyOnHide: false,*/ + style: {}, + 'class': 'mask', + maskMargins: false, + useIframeShim: true, + iframeShimOptions: {} }, - start: function(property, from, to){ - if (!this.check(property, from, to)) return this; - var args = Array.flatten(arguments); - this.property = this.options.property || args.shift(); - var parsed = this.prepare(this.element, this.property, args); - return this.parent(parsed.from, parsed.to); - } + initialize: function(target, options){ + this.target = document.id(target) || document.id(document.body); + this.target.store('mask', this); + this.setOptions(options); + this.render(); + this.inject(); + }, -}); + render: function(){ + this.element = new Element('div', { + 'class': this.options['class'], + id: this.options.id || 'mask-' + String.uniqueID(), + styles: Object.merge({}, this.options.style, { + display: 'none' + }), + events: { + click: function(event){ + this.fireEvent('click', event); + if (this.options.hideOnClick) this.hide(); + }.bind(this) + } + }); -Element.Properties.tween = { + this.hidden = true; + }, - set: function(options){ - this.get('tween').cancel().setOptions(options); - return this; + toElement: function(){ + return this.element; }, - get: function(){ - var tween = this.retrieve('tween'); - if (!tween){ - tween = new Fx.Tween(this, {link: 'cancel'}); - this.store('tween', tween); + inject: function(target, where){ + where = where || (this.options.inject ? this.options.inject.where : '') || (this.target == document.body ? 'inside' : 'after'); + target = target || (this.options.inject && this.options.inject.target) || this.target; + + this.element.inject(target, where); + + if (this.options.useIframeShim){ + this.shim = new IframeShim(this.element, this.options.iframeShimOptions); + + this.addEvents({ + show: this.shim.show.bind(this.shim), + hide: this.shim.hide.bind(this.shim), + destroy: this.shim.destroy.bind(this.shim) + }); } - return tween; - } + }, -}; + position: function(){ + this.resize(this.options.width, this.options.height); -Element.implement({ + this.element.position({ + relativeTo: this.target, + position: 'topLeft', + ignoreMargins: !this.options.maskMargins, + ignoreScroll: this.target == document.body + }); - tween: function(property, from, to){ - this.get('tween').start(property, from, to); return this; }, - fade: function(how){ - var fade = this.get('tween'), method, to, toggle; - if (how == null) how = 'toggle'; - switch (how){ - case 'in': method = 'start'; to = 1; break; - case 'out': method = 'start'; to = 0; break; - case 'show': method = 'set'; to = 1; break; - case 'hide': method = 'set'; to = 0; break; - case 'toggle': - var flag = this.retrieve('fade:flag', this.getStyle('opacity') == 1); - method = 'start'; - to = flag ? 0 : 1; - this.store('fade:flag', !flag); - toggle = true; - break; - default: method = 'start'; to = how; + resize: function(x, y){ + var opt = { + styles: ['padding', 'border'] + }; + if (this.options.maskMargins) opt.styles.push('margin'); + + var dim = this.target.getComputedSize(opt); + if (this.target == document.body){ + this.element.setStyles({width: 0, height: 0}); + var win = window.getScrollSize(); + if (dim.totalHeight < win.y) dim.totalHeight = win.y; + if (dim.totalWidth < win.x) dim.totalWidth = win.x; } - if (!toggle) this.eliminate('fade:flag'); - fade[method]('opacity', to); - if (method == 'set' || to != 0) this.setStyle('visibility', to == 0 ? 'hidden' : 'visible'); - else fade.chain(function(){ - this.element.setStyle('visibility', 'hidden'); + this.element.setStyles({ + width: Array.pick([x, dim.totalWidth, dim.x]), + height: Array.pick([y, dim.totalHeight, dim.y]) }); + return this; }, - highlight: function(start, end){ - if (!end){ - end = this.retrieve('highlight:original', this.getStyle('background-color')); - end = (end == 'transparent') ? '#fff' : end; - } - var tween = this.get('tween'); - tween.start('background-color', start || '#ffff88', end).chain(function(){ - this.setStyle('background-color', this.retrieve('highlight:original')); - tween.callChain(); - }.bind(this)); - return this; - } + show: function(){ + if (!this.hidden) return this; -}); + window.addEvent('resize', this.position); + this.position(); + this.showMask.apply(this, arguments); + return this; + }, -// Begin: Source/Fx/Fx.Transitions.js -/* ---- + showMask: function(){ + this.element.setStyle('display', 'block'); + this.hidden = false; + this.fireEvent('show'); + }, -name: Fx.Transitions + hide: function(){ + if (this.hidden) return this; -description: Contains a set of advanced transitions to be used with any of the Fx Classes. + window.removeEvent('resize', this.position); + this.hideMask.apply(this, arguments); + if (this.options.destroyOnHide) return this.destroy(); -license: MIT-style license. + return this; + }, -credits: - - Easing Equations by Robert Penner, , modified and optimized to be used with MooTools. + hideMask: function(){ + this.element.setStyle('display', 'none'); + this.hidden = true; + this.fireEvent('hide'); + }, -requires: Fx + toggle: function(){ + this[this.hidden ? 'show' : 'hide'](); + }, -provides: Fx.Transitions + destroy: function(){ + this.hide(); + this.element.destroy(); + this.fireEvent('destroy'); + this.target.eliminate('mask'); + } -... -*/ +}); -Fx.implement({ +Element.Properties.mask = { - getTransition: function(){ - var trans = this.options.transition || Fx.Transitions.Sine.easeInOut; - if (typeof trans == 'string'){ - var data = trans.split(':'); - trans = Fx.Transitions; - trans = trans[data[0]] || trans[data[0].capitalize()]; - if (data[1]) trans = trans['ease' + data[1].capitalize() + (data[2] ? data[2].capitalize() : '')]; + set: function(options){ + var mask = this.retrieve('mask'); + if (mask) mask.destroy(); + return this.eliminate('mask').store('mask:options', options); + }, + + get: function(){ + var mask = this.retrieve('mask'); + if (!mask){ + mask = new Mask(this, this.retrieve('mask:options')); + this.store('mask', mask); } - return trans; + return mask; } -}); - -Fx.Transition = function(transition, params){ - params = Array.from(params); - var easeIn = function(pos){ - return transition(pos, params); - }; - return Object.append(easeIn, { - easeIn: easeIn, - easeOut: function(pos){ - return 1 - transition(1 - pos, params); - }, - easeInOut: function(pos){ - return (pos <= 0.5 ? transition(2 * pos, params) : (2 - transition(2 * (1 - pos), params))) / 2; - } - }); }; -Fx.Transitions = { +Element.implement({ + + mask: function(options){ + if (options) this.set('mask', options); + this.get('mask').show(); + return this; + }, - linear: function(zero){ - return zero; + unmask: function(){ + this.get('mask').hide(); + return this; } -}; +}); -//<1.2compat> -Fx.Transitions = new Hash(Fx.Transitions); +// Begin: Source/Interface/Spinner.js +/* +--- -// +script: Spinner.js -Fx.Transitions.extend = function(transitions){ - for (var transition in transitions) Fx.Transitions[transition] = new Fx.Transition(transitions[transition]); -}; +name: Spinner -Fx.Transitions.extend({ +description: Adds a semi-transparent overlay over a dom element with a spinnin ajax icon. - Pow: function(p, x){ - return Math.pow(p, x && x[0] || 6); - }, +license: MIT-style license - Expo: function(p){ - return Math.pow(2, 8 * (p - 1)); - }, +authors: + - Aaron Newton - Circ: function(p){ - return 1 - Math.sin(Math.acos(p)); - }, +requires: + - Core/Fx.Tween + - Core/Request + - /Class.refactor + - /Mask - Sine: function(p){ - return 1 - Math.cos(p * Math.PI / 2); - }, +provides: [Spinner] - Back: function(p, x){ - x = x && x[0] || 1.618; - return Math.pow(p, 2) * ((x + 1) * p - x); - }, +... +*/ - Bounce: function(p){ - var value; - for (var a = 0, b = 1; 1; a += b, b /= 2){ - if (p >= (7 - 4 * a) / 11){ - value = b * b - Math.pow((11 - 6 * a - 11 * p) / 4, 2); - break; - } +var Spinner = new Class({ + + Extends: Mask, + + Implements: Chain, + + options: {/* + message: false,*/ + 'class': 'spinner', + containerPosition: {}, + content: { + 'class': 'spinner-content' + }, + messageContainer: { + 'class': 'spinner-msg' + }, + img: { + 'class': 'spinner-img' + }, + fxOptions: { + link: 'chain' } - return value; }, - Elastic: function(p, x){ - return Math.pow(2, 10 * --p) * Math.cos(20 * p * Math.PI * (x && x[0] || 1) / 3); - } + initialize: function(target, options){ + this.target = document.id(target) || document.id(document.body); + this.target.store('spinner', this); + this.setOptions(options); + this.render(); + this.inject(); -}); + // Add this to events for when noFx is true; parent methods handle hide/show. + var deactivate = function(){ this.active = false; }.bind(this); + this.addEvents({ + hide: deactivate, + show: deactivate + }); + }, -['Quad', 'Cubic', 'Quart', 'Quint'].each(function(transition, i){ - Fx.Transitions[transition] = new Fx.Transition(function(p){ - return Math.pow(p, i + 2); - }); -}); + render: function(){ + this.parent(); + this.element.set('id', this.options.id || 'spinner-' + String.uniqueID()); -// Begin: Source/Class/Class.Binds.js -/* ---- + this.content = document.id(this.options.content) || new Element('div', this.options.content); + this.content.inject(this.element); -script: Class.Binds.js + if (this.options.message){ + this.msg = document.id(this.options.message) || new Element('p', this.options.messageContainer).appendText(this.options.message); + this.msg.inject(this.content); + } -name: Class.Binds + if (this.options.img){ + this.img = document.id(this.options.img) || new Element('div', this.options.img); + this.img.inject(this.content); + } -description: Automagically binds specified methods in a class to the instance of the class. + this.element.set('tween', this.options.fxOptions); + }, -license: MIT-style license + show: function(noFx){ + if (this.active) return this.chain(this.show.bind(this)); + if (!this.hidden){ + this.callChain.delay(20, this); + return this; + } -authors: - - Aaron Newton + this.active = true; -requires: - - Core/Class - - /MooTools.More + return this.parent(noFx); + }, -provides: [Class.Binds] + showMask: function(noFx){ + var pos = function(){ + this.content.position(Object.merge({ + relativeTo: this.element + }, this.options.containerPosition)); + }.bind(this); -... -*/ + if (noFx){ + this.parent(); + pos(); + } else { + if (!this.options.style.opacity) this.options.style.opacity = this.element.getStyle('opacity').toFloat(); + this.element.setStyles({ + display: 'block', + opacity: 0 + }).tween('opacity', this.options.style.opacity); + pos(); + this.hidden = false; + this.fireEvent('show'); + this.callChain(); + } + }, -Class.Mutators.Binds = function(binds){ - if (!this.prototype.initialize) this.implement('initialize', function(){}); - return Array.from(binds).concat(this.prototype.Binds || []); -}; + hide: function(noFx){ + if (this.active) return this.chain(this.hide.bind(this)); + if (this.hidden){ + this.callChain.delay(20, this); + return this; + } + this.active = true; + return this.parent(noFx); + }, -Class.Mutators.initialize = function(initialize){ - return function(){ - Array.from(this.Binds).each(function(name){ - var original = this[name]; - if (original) this[name] = original.bind(this); - }, this); - return initialize.apply(this, arguments); - }; -}; + hideMask: function(noFx){ + if (noFx) return this.parent(); + this.element.tween('opacity', 0).get('tween').chain(function(){ + this.element.setStyle('display', 'none'); + this.hidden = true; + this.fireEvent('hide'); + this.callChain(); + }.bind(this)); + }, + destroy: function(){ + this.content.destroy(); + this.parent(); + this.target.eliminate('spinner'); + } -// Begin: Source/Class/Class.Occlude.js -/* ---- +}); -script: Class.Occlude.js +Request = Class.refactor(Request, { -name: Class.Occlude + options: { + useSpinner: false, + spinnerOptions: {}, + spinnerTarget: false + }, -description: Prevents a class from being applied to a DOM element twice. + initialize: function(options){ + this._send = this.send; + this.send = function(options){ + var spinner = this.getSpinner(); + if (spinner) spinner.chain(this._send.pass(options, this)).show(); + else this._send(options); + return this; + }; + this.previous(options); + }, -license: MIT-style license. + getSpinner: function(){ + if (!this.spinner){ + var update = document.id(this.options.spinnerTarget) || document.id(this.options.update); + if (this.options.useSpinner && update){ + update.set('spinner', this.options.spinnerOptions); + var spinner = this.spinner = update.get('spinner'); + ['complete', 'exception', 'cancel'].each(function(event){ + this.addEvent(event, spinner.hide.bind(spinner)); + }, this); + } + } + return this.spinner; + } -authors: - - Aaron Newton +}); -requires: - - Core/Class - - Core/Element - - /MooTools.More +Element.Properties.spinner = { -provides: [Class.Occlude] + set: function(options){ + var spinner = this.retrieve('spinner'); + if (spinner) spinner.destroy(); + return this.eliminate('spinner').store('spinner:options', options); + }, + + get: function(){ + var spinner = this.retrieve('spinner'); + if (!spinner){ + spinner = new Spinner(this, this.retrieve('spinner:options')); + this.store('spinner', spinner); + } + return spinner; + } -... -*/ +}; -Class.Occlude = new Class({ +Element.implement({ - occlude: function(property, element){ - element = document.id(element || this.element); - var instance = element.retrieve(property || this.property); - if (instance && !this.occluded) - return (this.occluded = instance); + spin: function(options){ + if (options) this.set('spinner', options); + this.get('spinner').show(); + return this; + }, - this.occluded = false; - element.store(property || this.property, this); - return this.occluded; + unspin: function(){ + this.get('spinner').hide(); + return this; } }); -// Begin: Source/Utilities/IframeShim.js +// Begin: Source/Types/String.QueryString.js /* --- -script: IframeShim.js +script: String.QueryString.js -name: IframeShim +name: String.QueryString -description: Defines IframeShim, a class for obscuring select lists and flash objects in IE. +description: Methods for dealing with URI query strings. license: MIT-style license authors: + - Sebastian Markbåge - Aaron Newton + - Lennart Pilon + - Valerio Proietti requires: - - Core/Element.Event - - Core/Element.Style - - Core/Options - - Core/Events - - /Element.Position - - /Class.Occlude + - Core/Array + - Core/String + - /MooTools.More -provides: [IframeShim] +provides: [String.QueryString] ... */ -var IframeShim = new Class({ - - Implements: [Options, Events, Class.Occlude], - - options: { - className: 'iframeShim', - src: 'javascript:false;document.write("");', - display: false, - zIndex: null, - margin: 0, - offset: {x: 0, y: 0}, - browsers: (Browser.ie6 || (Browser.firefox && Browser.version < 3 && Browser.Platform.mac)) - }, - - property: 'IframeShim', +String.implement({ - initialize: function(element, options){ - this.element = document.id(element); - if (this.occlude()) return this.occluded; - this.setOptions(options); - this.makeShim(); - return this; - }, + parseQueryString: function(decodeKeys, decodeValues){ + if (decodeKeys == null) decodeKeys = true; + if (decodeValues == null) decodeValues = true; - makeShim: function(){ - if (this.options.browsers){ - var zIndex = this.element.getStyle('zIndex').toInt(); + var vars = this.split(/[&;]/), + object = {}; + if (!vars.length) return object; - if (!zIndex){ - zIndex = 1; - var pos = this.element.getStyle('position'); - if (pos == 'static' || !pos) this.element.setStyle('position', 'relative'); - this.element.setStyle('zIndex', zIndex); - } - zIndex = ((this.options.zIndex != null || this.options.zIndex === 0) && zIndex > this.options.zIndex) ? this.options.zIndex : zIndex - 1; - if (zIndex < 0) zIndex = 1; - this.shim = new Element('iframe', { - src: this.options.src, - scrolling: 'no', - frameborder: 0, - styles: { - zIndex: zIndex, - position: 'absolute', - border: 'none', - filter: 'progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0)' - }, - 'class': this.options.className - }).store('IframeShim', this); - var inject = (function(){ - this.shim.inject(this.element, 'after'); - this[this.options.display ? 'show' : 'hide'](); - this.fireEvent('inject'); - }).bind(this); - if (!IframeShim.ready) window.addEvent('load', inject); - else inject(); - } else { - this.position = this.hide = this.show = this.dispose = Function.from(this); - } - }, + vars.each(function(val){ + var index = val.indexOf('=') + 1, + value = index ? val.substr(index) : '', + keys = index ? val.substr(0, index - 1).match(/([^\]\[]+|(\B)(?=\]))/g) : [val], + obj = object; + if (!keys) return; + if (decodeValues) value = decodeURIComponent(value); + keys.each(function(key, i){ + if (decodeKeys) key = decodeURIComponent(key); + var current = obj[key]; - position: function(){ - if (!IframeShim.ready || !this.shim) return this; - var size = this.element.measure(function(){ - return this.getSize(); - }); - if (this.options.margin != undefined){ - size.x = size.x - (this.options.margin * 2); - size.y = size.y - (this.options.margin * 2); - this.options.offset.x += this.options.margin; - this.options.offset.y += this.options.margin; - } - this.shim.set({width: size.x, height: size.y}).position({ - relativeTo: this.element, - offset: this.options.offset + if (i < keys.length - 1) obj = obj[key] = current || {}; + else if (typeOf(current) == 'array') current.push(value); + else obj[key] = current != null ? [current, value] : value; + }); }); - return this; - }, - - hide: function(){ - if (this.shim) this.shim.setStyle('display', 'none'); - return this; - }, - show: function(){ - if (this.shim) this.shim.setStyle('display', 'block'); - return this.position(); + return object; }, - dispose: function(){ - if (this.shim) this.shim.dispose(); - return this; - }, + cleanQueryString: function(method){ + return this.split('&').filter(function(val){ + var index = val.indexOf('='), + key = index < 0 ? '' : val.substr(0, index), + value = val.substr(index + 1); - destroy: function(){ - if (this.shim) this.shim.destroy(); - return this; + return method ? method.call(null, key, value) : (value || value === 0); + }).join('&'); } }); -window.addEvent('load', function(){ - IframeShim.ready = true; -}); - -// Begin: Source/Interface/Mask.js +// Begin: Source/Class/Events.Pseudos.js /* --- -script: Mask.js - -name: Mask +name: Events.Pseudos -description: Creates a mask element to cover another. +description: Adds the functionality to add pseudo events license: MIT-style license authors: - - Aaron Newton + - Arian Stolwijk -requires: - - Core/Options - - Core/Events - - Core/Element.Event - - /Class.Binds - - /Element.Position - - /IframeShim +requires: [Core/Class.Extras, Core/Slick.Parser, More/MooTools.More] -provides: [Mask] +provides: [Events.Pseudos] ... */ -var Mask = new Class({ - - Implements: [Options, Events], - - Binds: ['position'], +(function(){ - options: {/* - onShow: function(){}, - onHide: function(){}, - onDestroy: function(){}, - onClick: function(event){}, - inject: { - where: 'after', - target: null, - }, - hideOnClick: false, - id: null, - destroyOnHide: false,*/ - style: {}, - 'class': 'mask', - maskMargins: false, - useIframeShim: true, - iframeShimOptions: {} - }, +Events.Pseudos = function(pseudos, addEvent, removeEvent){ - initialize: function(target, options){ - this.target = document.id(target) || document.id(document.body); - this.target.store('mask', this); - this.setOptions(options); - this.render(); - this.inject(); - }, + var storeKey = '_monitorEvents:'; - render: function(){ - this.element = new Element('div', { - 'class': this.options['class'], - id: this.options.id || 'mask-' + String.uniqueID(), - styles: Object.merge({}, this.options.style, { - display: 'none' - }), - events: { - click: function(event){ - this.fireEvent('click', event); - if (this.options.hideOnClick) this.hide(); - }.bind(this) + var storageOf = function(object){ + return { + store: object.store ? function(key, value){ + object.store(storeKey + key, value); + } : function(key, value){ + (object._monitorEvents || (object._monitorEvents = {}))[key] = value; + }, + retrieve: object.retrieve ? function(key, dflt){ + return object.retrieve(storeKey + key, dflt); + } : function(key, dflt){ + if (!object._monitorEvents) return dflt; + return object._monitorEvents[key] || dflt; } - }); - - this.hidden = true; - }, - - toElement: function(){ - return this.element; - }, - - inject: function(target, where){ - where = where || (this.options.inject ? this.options.inject.where : '') || this.target == document.body ? 'inside' : 'after'; - target = target || (this.options.inject && this.options.inject.target) || this.target; + }; + }; - this.element.inject(target, where); + var splitType = function(type){ + if (type.indexOf(':') == -1 || !pseudos) return null; - if (this.options.useIframeShim){ - this.shim = new IframeShim(this.element, this.options.iframeShimOptions); + var parsed = Slick.parse(type).expressions[0][0], + parsedPseudos = parsed.pseudos, + l = parsedPseudos.length, + splits = []; - this.addEvents({ - show: this.shim.show.bind(this.shim), - hide: this.shim.hide.bind(this.shim), - destroy: this.shim.destroy.bind(this.shim) + while (l--){ + var pseudo = parsedPseudos[l].key, + listener = pseudos[pseudo]; + if (listener != null) splits.push({ + event: parsed.tag, + value: parsedPseudos[l].value, + pseudo: pseudo, + original: type, + listener: listener }); } - }, + return splits.length ? splits : null; + }; - position: function(){ - this.resize(this.options.width, this.options.height); + return { - this.element.position({ - relativeTo: this.target, - position: 'topLeft', - ignoreMargins: !this.options.maskMargins, - ignoreScroll: this.target == document.body - }); + addEvent: function(type, fn, internal){ + var split = splitType(type); + if (!split) return addEvent.call(this, type, fn, internal); - return this; - }, + var storage = storageOf(this), + events = storage.retrieve(type, []), + eventType = split[0].event, + args = Array.slice(arguments, 2), + stack = fn, + self = this; - resize: function(x, y){ - var opt = { - styles: ['padding', 'border'] - }; - if (this.options.maskMargins) opt.styles.push('margin'); + split.each(function(item){ + var listener = item.listener, + stackFn = stack; + if (listener == false) eventType += ':' + item.pseudo + '(' + item.value + ')'; + else stack = function(){ + listener.call(self, item, stackFn, arguments, stack); + }; + }); - var dim = this.target.getComputedSize(opt); - if (this.target == document.body){ - this.element.setStyles({width: 0, height: 0}); - var win = window.getScrollSize(); - if (dim.totalHeight < win.y) dim.totalHeight = win.y; - if (dim.totalWidth < win.x) dim.totalWidth = win.x; - } - this.element.setStyles({ - width: Array.pick([x, dim.totalWidth, dim.x]), - height: Array.pick([y, dim.totalHeight, dim.y]) - }); + events.include({type: eventType, event: fn, monitor: stack}); + storage.store(type, events); - return this; - }, + if (type != eventType) addEvent.apply(this, [type, fn].concat(args)); + return addEvent.apply(this, [eventType, stack].concat(args)); + }, - show: function(){ - if (!this.hidden) return this; + removeEvent: function(type, fn){ + var split = splitType(type); + if (!split) return removeEvent.call(this, type, fn); - window.addEvent('resize', this.position); - this.position(); - this.showMask.apply(this, arguments); + var storage = storageOf(this), + events = storage.retrieve(type); + if (!events) return this; - return this; - }, + var args = Array.slice(arguments, 2); - showMask: function(){ - this.element.setStyle('display', 'block'); - this.hidden = false; - this.fireEvent('show'); - }, + removeEvent.apply(this, [type, fn].concat(args)); + events.each(function(monitor, i){ + if (!fn || monitor.event == fn) removeEvent.apply(this, [monitor.type, monitor.monitor].concat(args)); + delete events[i]; + }, this); - hide: function(){ - if (this.hidden) return this; + storage.store(type, events); + return this; + } - window.removeEvent('resize', this.position); - this.hideMask.apply(this, arguments); - if (this.options.destroyOnHide) return this.destroy(); + }; - return this; - }, +}; - hideMask: function(){ - this.element.setStyle('display', 'none'); - this.hidden = true; - this.fireEvent('hide'); - }, +var pseudos = { - toggle: function(){ - this[this.hidden ? 'show' : 'hide'](); + once: function(split, fn, args, monitor){ + fn.apply(this, args); + this.removeEvent(split.event, monitor) + .removeEvent(split.original, fn); }, - destroy: function(){ - this.hide(); - this.element.destroy(); - this.fireEvent('destroy'); - this.target.eliminate('mask'); - } - -}); - -Element.Properties.mask = { - - set: function(options){ - var mask = this.retrieve('mask'); - if (mask) mask.destroy(); - return this.eliminate('mask').store('mask:options', options); + throttle: function(split, fn, args){ + if (!fn._throttled){ + fn.apply(this, args); + fn._throttled = setTimeout(function(){ + fn._throttled = false; + }, split.value || 250); + } }, - get: function(){ - var mask = this.retrieve('mask'); - if (!mask){ - mask = new Mask(this, this.retrieve('mask:options')); - this.store('mask', mask); - } - return mask; + pause: function(split, fn, args){ + clearTimeout(fn._pause); + fn._pause = fn.delay(split.value || 250, this, args); } }; -Element.implement({ +Events.definePseudo = function(key, listener){ + pseudos[key] = listener; + return this; +}; - mask: function(options){ - if (options) this.set('mask', options); - this.get('mask').show(); - return this; - }, +Events.lookupPseudo = function(key){ + return pseudos[key]; +}; - unmask: function(){ - this.get('mask').hide(); - return this; - } +var proto = Events.prototype; +Events.implement(Events.Pseudos(pseudos, proto.addEvent, proto.removeEvent)); +['Request', 'Fx'].each(function(klass){ + if (this[klass]) this[klass].implement(Events.prototype); }); +})(); -// Begin: Source/Element/Elements.From.js + +// Begin: Source/Element/Element.Event.Pseudos.js /* --- -script: Elements.From.js - -name: Elements.From +name: Element.Event.Pseudos -description: Returns a collection of elements from a string of html. +description: Adds the functionality to add pseudo events for Elements license: MIT-style license authors: - - Aaron Newton + - Arian Stolwijk -requires: - - Core/String - - Core/Element - - /MooTools.More +requires: [Core/Element.Event, Core/Element.Delegation, Events.Pseudos] -provides: [Elements.from, Elements.From] +provides: [Element.Event.Pseudos, Element.Delegation] ... */ -Elements.from = function(text, excludeScripts){ - if (excludeScripts || excludeScripts == null) text = text.stripScripts(); +(function(){ - var container, match = text.match(/^\s*<(t[dhr]|tbody|tfoot|thead)/i); +var pseudos = {relay: false}, + copyFromEvents = ['once', 'throttle', 'pause'], + count = copyFromEvents.length; - if (match){ - container = new Element('table'); - var tag = match[1].toLowerCase(); - if (['td', 'th', 'tr'].contains(tag)){ - container = new Element('tbody').inject(container); - if (tag != 'tr') container = new Element('tr').inject(container); - } - } +while (count--) pseudos[copyFromEvents[count]] = Events.lookupPseudo(copyFromEvents[count]); - return (container || new Element('div')).set('html', text).getChildren(); +DOMEvent.definePseudo = function(key, listener){ + pseudos[key] = listener; + return this; }; +var proto = Element.prototype; +[Element, Window, Document].invoke('implement', Events.Pseudos(pseudos, proto.addEvent, proto.removeEvent)); -// Begin: Source/Class/Events.Pseudos.js +})(); + + +// Begin: Source/Forms/Form.Request.js /* --- -name: Events.Pseudos +script: Form.Request.js -description: Adds the functionality to add pseudo events +name: Form.Request + +description: Handles the basic functionality of submitting a form and updating a dom element with the result. license: MIT-style license authors: - - Arian Stolwijk + - Aaron Newton -requires: [Core/Class.Extras, Core/Slick.Parser, More/MooTools.More] +requires: + - Core/Request.HTML + - /Class.Binds + - /Class.Occlude + - /Spinner + - /String.QueryString + - /Element.Delegation -provides: [Events.Pseudos] +provides: [Form.Request] ... */ +if (!window.Form) window.Form = {}; + (function(){ -Events.Pseudos = function(pseudos, addEvent, removeEvent){ + Form.Request = new Class({ + + Binds: ['onSubmit', 'onFormValidate'], + + Implements: [Options, Events, Class.Occlude], + + options: {/* + onFailure: function(){}, + onSuccess: function(){}, // aliased to onComplete, + onSend: function(){}*/ + requestOptions: { + evalScripts: true, + useSpinner: true, + emulation: false, + link: 'ignore' + }, + sendButtonClicked: true, + extraData: {}, + resetForm: true + }, + + property: 'form.request', - var storeKey = '_monitorEvents:'; + initialize: function(form, target, options){ + this.element = document.id(form); + if (this.occlude()) return this.occluded; + this.setOptions(options) + .setTarget(target) + .attach(); + }, - var storageOf = function(object){ - return { - store: object.store ? function(key, value){ - object.store(storeKey + key, value); - } : function(key, value){ - (object._monitorEvents || (object._monitorEvents = {}))[key] = value; - }, - retrieve: object.retrieve ? function(key, dflt){ - return object.retrieve(storeKey + key, dflt); - } : function(key, dflt){ - if (!object._monitorEvents) return dflt; - return object._monitorEvents[key] || dflt; + setTarget: function(target){ + this.target = document.id(target); + if (!this.request){ + this.makeRequest(); + } else { + this.request.setOptions({ + update: this.target + }); } - }; - }; - - var splitType = function(type){ - if (type.indexOf(':') == -1 || !pseudos) return null; + return this; + }, - var parsed = Slick.parse(type).expressions[0][0], - parsedPseudos = parsed.pseudos, - l = parsedPseudos.length, - splits = []; + toElement: function(){ + return this.element; + }, - while (l--){ - var pseudo = parsedPseudos[l].key, - listener = pseudos[pseudo]; - if (listener != null) splits.push({ - event: parsed.tag, - value: parsedPseudos[l].value, - pseudo: pseudo, - original: type, - listener: listener + makeRequest: function(){ + var self = this; + this.request = new Request.HTML(Object.merge({ + update: this.target, + emulation: false, + spinnerTarget: this.element, + method: this.element.get('method') || 'post' + }, this.options.requestOptions)).addEvents({ + success: function(tree, elements, html, javascript){ + ['complete', 'success'].each(function(evt){ + self.fireEvent(evt, [self.target, tree, elements, html, javascript]); + }); + }, + failure: function(){ + self.fireEvent('complete', arguments).fireEvent('failure', arguments); + }, + exception: function(){ + self.fireEvent('failure', arguments); + } }); - } - return splits.length ? splits : null; - }; + return this.attachReset(); + }, - return { + attachReset: function(){ + if (!this.options.resetForm) return this; + this.request.addEvent('success', function(){ + Function.attempt(function(){ + this.element.reset(); + }.bind(this)); + if (window.OverText) OverText.update(); + }.bind(this)); + return this; + }, - addEvent: function(type, fn, internal){ - var split = splitType(type); - if (!split) return addEvent.call(this, type, fn, internal); + attach: function(attach){ + var method = (attach != false) ? 'addEvent' : 'removeEvent'; + this.element[method]('click:relay(button, input[type=submit])', this.saveClickedButton.bind(this)); - var storage = storageOf(this), - events = storage.retrieve(type, []), - eventType = split[0].event, - args = Array.slice(arguments, 2), - stack = fn, - self = this; + var fv = this.element.retrieve('validator'); + if (fv) fv[method]('onFormValidate', this.onFormValidate); + else this.element[method]('submit', this.onSubmit); - split.each(function(item){ - var listener = item.listener, - stackFn = stack; - if (listener == false) eventType += ':' + item.pseudo + '(' + item.value + ')'; - else stack = function(){ - listener.call(self, item, stackFn, arguments, stack); - }; - }); + return this; + }, - events.include({type: eventType, event: fn, monitor: stack}); - storage.store(type, events); + detach: function(){ + return this.attach(false); + }, - if (type != eventType) addEvent.apply(this, [type, fn].concat(args)); - return addEvent.apply(this, [eventType, stack].concat(args)); + //public method + enable: function(){ + return this.attach(); }, - removeEvent: function(type, fn){ - var split = splitType(type); - if (!split) return removeEvent.call(this, type, fn); + //public method + disable: function(){ + return this.detach(); + }, - var storage = storageOf(this), - events = storage.retrieve(type); - if (!events) return this; + onFormValidate: function(valid, form, event){ + //if there's no event, then this wasn't a submit event + if (!event) return; + var fv = this.element.retrieve('validator'); + if (valid || (fv && !fv.options.stopOnFailure)){ + event.stop(); + this.send(); + } + }, - var args = Array.slice(arguments, 2); + onSubmit: function(event){ + var fv = this.element.retrieve('validator'); + if (fv){ + //form validator was created after Form.Request + this.element.removeEvent('submit', this.onSubmit); + fv.addEvent('onFormValidate', this.onFormValidate); + this.element.validate(); + return; + } + if (event) event.stop(); + this.send(); + }, - removeEvent.apply(this, [type, fn].concat(args)); - events.each(function(monitor, i){ - if (!fn || monitor.event == fn) removeEvent.apply(this, [monitor.type, monitor.monitor].concat(args)); - delete events[i]; - }, this); + saveClickedButton: function(event, target){ + var targetName = target.get('name'); + if (!targetName || !this.options.sendButtonClicked) return; + this.options.extraData[targetName] = target.get('value') || true; + this.clickedCleaner = function(){ + delete this.options.extraData[targetName]; + this.clickedCleaner = function(){}; + }.bind(this); + }, - storage.store(type, events); - return this; - } + clickedCleaner: function(){}, - }; + send: function(){ + var str = this.element.toQueryString().trim(), + data = Object.toQueryString(this.options.extraData); -}; + if (str) str += "&" + data; + else str = data; -var pseudos = { + this.fireEvent('send', [this.element, str.parseQueryString()]); + this.request.send({ + data: str, + url: this.options.requestOptions.url || this.element.get('action') + }); + this.clickedCleaner(); + return this; + } - once: function(split, fn, args, monitor){ - fn.apply(this, args); - this.removeEvent(split.event, monitor) - .removeEvent(split.original, fn); - }, + }); - throttle: function(split, fn, args){ - if (!fn._throttled){ - fn.apply(this, args); - fn._throttled = setTimeout(function(){ - fn._throttled = false; - }, split.value || 250); + Element.implement('formUpdate', function(update, options){ + var fq = this.retrieve('form.request'); + if (!fq){ + fq = new Form.Request(this, update, options); + } else { + if (update) fq.setTarget(update); + if (options) fq.setOptions(options).makeRequest(); } - }, - - pause: function(split, fn, args){ - clearTimeout(fn._pause); - fn._pause = fn.delay(split.value || 250, this, args); - } + fq.send(); + return this; + }); -}; +})(); -Events.definePseudo = function(key, listener){ - pseudos[key] = listener; - return this; -}; -Events.lookupPseudo = function(key){ - return pseudos[key]; -}; +// Begin: Source/Forms/Behavior.FormRequest.js +/* +--- +description: Makes form elements with a FormRequest data filter automatically update via Ajax. +provides: [Behavior.FormRequest] +requires: [Behavior/Behavior, More/Form.Request, Behavior/Element.Data] +script: Behavior.FormRequest.js +name: Behavior.FormRequest +... +*/ -var proto = Events.prototype; -Events.implement(Events.Pseudos(pseudos, proto.addEvent, proto.removeEvent)); +Behavior.addGlobalFilter('FormRequest', { + defaults: { + resetForm: true + }, + setup: function(element, api){ + var updateElement, + update = api.get('update'), + spinner = api.get('spinner'); + if (update =="self") updateElement = element; + else updateElement = element.getElement(update); + + if (spinner == "self") spinner = element; + else if (spinner) spinner = element.getElement(spinner); + else spinner = updateElement; + + if (!updateElement) api.fail('Could not find target element for form update'); + var sentAt; + var req = new Form.Request(element, updateElement, { + requestOptions: { + filter: api.get('filter'), + spinnerTarget: spinner + }, + resetForm: api.get('resetForm') + }).addEvent('complete', function(){ + api.applyFilters(updateElement); + }).addEvent('send', function(){ + sentAt = new Date().getTime(); + }); + // this bit below is to throttle form submission in case more than one thing + // is trying to send it + + // remove form.request submit watcher + element.removeEvent('submit', req.onSubmit); + // our new submit handler checks that requests to submit are at least 200ms apart + var submit = function(e){ + if (!sentAt || sentAt + 200 < new Date().getTime()) { + req.onSubmit(e); + } else { + // if they aren't, just stop the submit event if it's present + if (e) e.stop(); + } + }; + // now monitor submit with our new method + element.addEvent('submit', submit); + // and overwrite the submit method on the element + element.submit = submit; + api.onCleanup(function(){ + req.detach(); + delete element.submit; + }); + return req; + } -['Request', 'Fx'].each(function(klass){ - if (this[klass]) this[klass].implement(Events.prototype); }); -})(); - -// Begin: Source/UI/Bootstrap.Popup.js +// Begin: Source/Types/Object.Extras.js /* --- -name: Popup +script: Object.Extras.js -description: A simple Popup class for the Twitter Bootstrap CSS framework. +name: Object.Extras -authors: [Aaron Newton] +description: Extra Object generics, like getFromPath which allows a path notation to child elements. -license: MIT-style license. +license: MIT-style license + +authors: + - Aaron Newton requires: - - Core/Element.Delegation - - Core/Fx.Tween - - Core/Fx.Transitions - - More/Mask - - More/Elements.From - - More/Element.Position - - More/Element.Shortcuts - - More/Events.Pseudos - - /CSSEvents - - /Bootstrap + - Core/Object + - /MooTools.More -provides: [Bootstrap.Popup] +provides: [Object.Extras] ... */ -Bootstrap.Popup = new Class({ - - Implements: [Options, Events], +(function(){ - options: { - /* - onShow: function(){}, - onHide: function(){}, - animate: function(){}, - destroy: function(){}, - */ - persist: true, - closeOnClickOut: true, - closeOnEsc: true, - mask: true, - animate: true - }, +var defined = function(value){ + return value != null; +}; - initialize: function(element, options){ - this.element = document.id(element).store('Bootstrap.Popup', this); - this.setOptions(options); - this.bound = { - hide: this.hide.bind(this), - bodyClick: function(e){ - if (!this.element.contains(e.target)){ - this.hide(); - } - }.bind(this), - keyMonitor: function(e){ - if (e.key == 'esc') this.hide(); - }.bind(this), - animationEnd: this._animationEnd.bind(this) - }; - if ((this.element.hasClass('fade') && this.element.hasClass('in')) || - (!this.element.hasClass('hide') && !this.element.hasClass('fade'))){ - if (this.element.hasClass('fade')) this.element.removeClass('in'); - this.show(); - } - }, +var hasOwnProperty = Object.prototype.hasOwnProperty; - _checkAnimate: function(){ - var check = this.options.animate !== false && Browser.Features.getCSSTransition() && (this.options.animate || this.element.hasClass('fade')); - if (!check) { - this.element.removeClass('fade').addClass('hide'); - this._mask.removeClass('fade').addClass('hide'); - } else if (check) { - this.element.addClass('fade').removeClass('hide'); - this._mask.addClass('fade').removeClass('hide'); - } - return check; - }, +Object.extend({ - show: function(){ - if (this.visible || this.animating) return; - this.element.addEvent('click:relay(.close, .dismiss)', this.bound.hide); - if (this.options.closeOnEsc) document.addEvent('keyup', this.bound.keyMonitor); - this._makeMask(); - this._mask.inject(document.body); - this.animating = true; - if (this._checkAnimate()){ - this.element.offsetWidth; // force reflow - this.element.addClass('in'); - this._mask.addClass('in'); - } else { - this.element.show(); - this._mask.show(); + getFromPath: function(source, parts){ + if (typeof parts == 'string') parts = parts.split('.'); + for (var i = 0, l = parts.length; i < l; i++){ + if (hasOwnProperty.call(source, parts[i])) source = source[parts[i]]; + else return null; } - this.visible = true; - this._watch(); - }, - - _watch: function(){ - if (this._checkAnimate()) this.element.addEventListener(Browser.Features.getCSSTransition(), this.bound.animationEnd); - else this._animationEnd(); + return source; }, - _animationEnd: function(){ - if (Browser.Features.getCSSTransition()) this.element.removeEventListener(Browser.Features.getCSSTransition(), this.bound.animationEnd); - this.animating = false; - if (this.visible){ - this.fireEvent('show', this.element); - } else { - this.fireEvent('hide', this.element); - if (!this.options.persist){ - this.destroy(); - } else { - this._mask.dispose(); - } + cleanValues: function(object, method){ + method = method || defined; + for (var key in object) if (!method(object[key])){ + delete object[key]; } + return object; }, - destroy: function(){ - this._mask.destroy(); - this.fireEvent('destroy', this.element); - this.element.destroy(); - this._mask = null; - this.destroyed = true; - }, - - hide: function(event, clicked){ - if (!this.visible || this.animating) return; - this.animating = true; - if (event && clicked && clicked.hasClass('stopEvent')){ - event.preventDefault(); - } - document.id(document.body).removeEvent('click', this.bound.hide); - document.removeEvent('keyup', this.bound.keyMonitor); - this.element.removeEvent('click:relay(.close, .dismiss)', this.bound.hide); - - if (this._checkAnimate()){ - this.element.removeClass('in'); - this._mask.removeClass('in'); - } else { - this.element.hide(); - this._mask.hide(); - } - this.visible = false; - this._watch(); + erase: function(object, key){ + if (hasOwnProperty.call(object, key)) delete object[key]; + return object; }, - // PRIVATE - - _makeMask: function(){ - if (this.options.mask){ - if (!this._mask){ - this._mask = new Element('div.modal-backdrop', { - events: { - click: this.bound.hide - } - }); - if (this._checkAnimate()){ - this._mask.addClass('fade'); - } - } - } else if (this.options.closeOnClickOut){ - document.id(document.body).addEvent('click', this.bound.hide); + run: function(object){ + var args = Array.slice(arguments, 1); + for (var key in object) if (object[key].apply){ + object[key].apply(object, args); } + return object; } }); -// Begin: Source/Behaviors/Behavior.BS.Popup.js +})(); + + +// Begin: Source/Fx/Fx.Transitions.js /* --- -name: Behavior.Popup +name: Fx.Transitions -description: Creates a bootstrap popup based on HTML markup. +description: Contains a set of advanced transitions to be used with any of the Fx Classes. license: MIT-style license. -authors: [Aaron Newton] +credits: + - Easing Equations by Robert Penner, , modified and optimized to be used with MooTools. -requires: - - Behavior/Behavior - - More/Object.Extras - - Bootstrap.Popup +requires: Fx -provides: [Behavior.BS.Popup] +provides: Fx.Transitions ... */ -Behavior.addGlobalFilters({ - 'BS.Popup': { - defaults: { - hide: false, - animate: true, - closeOnEsc: true, - closeOnClickOut: true, - mask: true, - persist: true +Fx.implement({ + + getTransition: function(){ + var trans = this.options.transition || Fx.Transitions.Sine.easeInOut; + if (typeof trans == 'string'){ + var data = trans.split(':'); + trans = Fx.Transitions; + trans = trans[data[0]] || trans[data[0].capitalize()]; + if (data[1]) trans = trans['ease' + data[1].capitalize() + (data[2] ? data[2].capitalize() : '')]; + } + return trans; + } + +}); + +Fx.Transition = function(transition, params){ + params = Array.from(params); + var easeIn = function(pos){ + return transition(pos, params); + }; + return Object.append(easeIn, { + easeIn: easeIn, + easeOut: function(pos){ + return 1 - transition(1 - pos, params); }, - returns: Bootstrap.Popup, - setup: function(el, api){ - var popup = new Bootstrap.Popup(el, - Object.cleanValues( - api.getAs({ - persist: Boolean, - animate: Boolean, - closeOnEsc: Boolean, - closeOnClickOut: Boolean, - mask: Boolean - }) - ) - ); - popup.addEvent('destroy', function(){ - api.cleanup(el); - }); - if (!el.hasClass('hide') && !api.getAs(Boolean, 'hide') && (!el.hasClass('in') && !el.hasClass('fade'))) { - popup.show(); + easeInOut: function(pos){ + return (pos <= 0.5 ? transition(2 * pos, params) : (2 - transition(2 * (1 - pos), params))) / 2; + } + }); +}; + +Fx.Transitions = { + + linear: function(zero){ + return zero; + } + +}; + +//<1.2compat> + +Fx.Transitions = new Hash(Fx.Transitions); + +// + +Fx.Transitions.extend = function(transitions){ + for (var transition in transitions) Fx.Transitions[transition] = new Fx.Transition(transitions[transition]); +}; + +Fx.Transitions.extend({ + + Pow: function(p, x){ + return Math.pow(p, x && x[0] || 6); + }, + + Expo: function(p){ + return Math.pow(2, 8 * (p - 1)); + }, + + Circ: function(p){ + return 1 - Math.sin(Math.acos(p)); + }, + + Sine: function(p){ + return 1 - Math.cos(p * Math.PI / 2); + }, + + Back: function(p, x){ + x = x && x[0] || 1.618; + return Math.pow(p, 2) * ((x + 1) * p - x); + }, + + Bounce: function(p){ + var value; + for (var a = 0, b = 1; 1; a += b, b /= 2){ + if (p >= (7 - 4 * a) / 11){ + value = b * b - Math.pow((11 - 6 * a - 11 * p) / 4, 2); + break; } - return popup; } + return value; + }, + + Elastic: function(p, x){ + return Math.pow(2, 10 * --p) * Math.cos(20 * p * Math.PI * (x && x[0] || 1) / 3); } + }); -// Begin: Source/Request/Request.js +['Quad', 'Cubic', 'Quart', 'Quint'].each(function(transition, i){ + Fx.Transitions[transition] = new Fx.Transition(function(p){ + return Math.pow(p, i + 2); + }); +}); + + +// Begin: Source/Element/Elements.From.js /* --- -name: Request +script: Elements.From.js -description: Powerful all purpose Request Class. Uses XMLHTTPRequest. +name: Elements.From -license: MIT-style license. +description: Returns a collection of elements from a string of html. -requires: [Object, Element, Chain, Events, Options, Browser] +license: MIT-style license -provides: Request +authors: + - Aaron Newton + +requires: + - Core/String + - Core/Element + - /MooTools.More + +provides: [Elements.from, Elements.From] ... */ -(function(){ +Elements.from = function(text, excludeScripts){ + if (excludeScripts || excludeScripts == null) text = text.stripScripts(); -var empty = function(){}, - progressSupport = ('onprogress' in new Browser.Request); + var container, match = text.match(/^\s*(?:\s*)*<(t[dhr]|tbody|tfoot|thead)/i); -var Request = this.Request = new Class({ + if (match){ + container = new Element('table'); + var tag = match[1].toLowerCase(); + if (['td', 'th', 'tr'].contains(tag)){ + container = new Element('tbody').inject(container); + if (tag != 'tr') container = new Element('tr').inject(container); + } + } - Implements: [Chain, Events, Options], + return (container || new Element('div')).set('html', text).getChildren(); +}; - options: {/* - onRequest: function(){}, - onLoadstart: function(event, xhr){}, - onProgress: function(event, xhr){}, - onComplete: function(){}, - onCancel: function(){}, - onSuccess: function(responseText, responseXML){}, - onFailure: function(xhr){}, - onException: function(headerName, value){}, - onTimeout: function(){}, - user: '', - password: '',*/ - url: '', - data: '', - headers: { - 'X-Requested-With': 'XMLHttpRequest', - 'Accept': 'text/javascript, text/html, application/xml, text/xml, */*' - }, - async: true, - format: false, - method: 'post', - link: 'ignore', - isSuccess: null, - emulation: true, - urlEncoded: true, - encoding: 'utf-8', - evalScripts: false, - evalResponse: false, - timeout: 0, - noCache: false - }, - initialize: function(options){ - this.xhr = new Browser.Request(); - this.setOptions(options); - this.headers = this.options.headers; - }, +// Begin: Source/UI/Bootstrap.Popup.js +/* +--- - onStateChange: function(){ - var xhr = this.xhr; - if (xhr.readyState != 4 || !this.running) return; - this.running = false; - this.status = 0; - Function.attempt(function(){ - var status = xhr.status; - this.status = (status == 1223) ? 204 : status; - }.bind(this)); - xhr.onreadystatechange = empty; - if (progressSupport) xhr.onprogress = xhr.onloadstart = empty; - clearTimeout(this.timer); +name: Popup - this.response = {text: this.xhr.responseText || '', xml: this.xhr.responseXML}; - if (this.options.isSuccess.call(this, this.status)) - this.success(this.response.text, this.response.xml); - else - this.failure(); - }, +description: A simple Popup class for the Twitter Bootstrap CSS framework. - isSuccess: function(){ - var status = this.status; - return (status >= 200 && status < 300); - }, +authors: [Aaron Newton] - isRunning: function(){ - return !!this.running; - }, +license: MIT-style license. - processScripts: function(text){ - if (this.options.evalResponse || (/(ecma|java)script/).test(this.getHeader('Content-type'))) return Browser.exec(text); - return text.stripScripts(this.options.evalScripts); - }, +requires: + - Core/Element.Delegation + - Core/Fx.Tween + - Core/Fx.Transitions + - More/Mask + - More/Elements.From + - More/Element.Position + - More/Element.Shortcuts + - More/Events.Pseudos + - /CSSEvents + - /Bootstrap - success: function(text, xml){ - this.onSuccess(this.processScripts(text), xml); - }, +provides: [Bootstrap.Popup] - onSuccess: function(){ - this.fireEvent('complete', arguments).fireEvent('success', arguments).callChain(); - }, +... +*/ - failure: function(){ - this.onFailure(); - }, +Bootstrap.Popup = new Class({ - onFailure: function(){ - this.fireEvent('complete').fireEvent('failure', this.xhr); - }, + Implements: [Options, Events], - loadstart: function(event){ - this.fireEvent('loadstart', [event, this.xhr]); + options: { + /* + onShow: function(){}, + onHide: function(){}, + animate: function(){}, + destroy: function(){}, + */ + persist: true, + closeOnClickOut: true, + closeOnEsc: true, + mask: true, + animate: true, + changeDisplayValue: true }, - progress: function(event){ - this.fireEvent('progress', [event, this.xhr]); - }, + initialize: function(element, options){ + this.element = document.id(element).store('Bootstrap.Popup', this); + this.setOptions(options); + this.bound = { + hide: this.hide.bind(this), + bodyClick: function(e){ + if (Bootstrap.version == 2){ + if (!this.element.contains(e.target)) this.hide(); + } else { + if (this.element == e.target) this.hide(); + } + }.bind(this), + keyMonitor: function(e){ + if (e.key == 'esc') this.hide(); + }.bind(this), + animationEnd: this._animationEnd.bind(this) + }; + if ((this.element.hasClass('fade') && this.element.hasClass('in')) || + (!this.element.hasClass('hide') && !this.element.hasClass('fade'))){ + if (this.element.hasClass('fade')) this.element.removeClass('in'); + this.show(); + } - timeout: function(){ - this.fireEvent('timeout', this.xhr); + if (Bootstrap.version > 2){ + if (this.options.closeOnClickOut){ + this.element.addEvent('click', this.bound.bodyClick); + } + } }, - setHeader: function(name, value){ - this.headers[name] = value; - return this; + toElement: function(){ + return this.element; }, - getHeader: function(name){ - return Function.attempt(function(){ - return this.xhr.getResponseHeader(name); - }.bind(this)); + _checkAnimate: function(){ + var check = this.options.animate !== false && Browser.Features.getCSSTransition() && (this.options.animate || this.element.hasClass('fade')); + if (!check) { + this.element.removeClass('fade').addClass('hide'); + if (this._mask) this._mask.removeClass('fade').addClass('hide'); + } else if (check) { + this.element.addClass('fade').removeClass('hide'); + if (this._mask) this._mask.addClass('fade').removeClass('hide'); + } + return check; }, - check: function(){ - if (!this.running) return true; - switch (this.options.link){ - case 'cancel': this.cancel(); return true; - case 'chain': this.chain(this.caller.pass(arguments, this)); return false; + show: function(){ + if (this.visible || this.animating) return; + this.element.addEvent('click:relay(.close, .dismiss, [data-dismiss=modal])', this.bound.hide); + if (this.options.closeOnEsc) document.addEvent('keyup', this.bound.keyMonitor); + this._makeMask(); + if (this._mask) this._mask.inject(document.body); + this.animating = true; + if (this.options.changeDisplayValue) this.element.show(); + if (this._checkAnimate()){ + this.element.offsetWidth; // force reflow + this.element.addClass('in'); + if (this._mask) this._mask.addClass('in'); + } else { + this.element.show(); + if (this._mask) this._mask.show(); } - return false; + this.visible = true; + this._watch(); }, - send: function(options){ - if (!this.check(options)) return this; - - this.options.isSuccess = this.options.isSuccess || this.isSuccess; - this.running = true; - - var type = typeOf(options); - if (type == 'string' || type == 'element') options = {data: options}; - - var old = this.options; - options = Object.append({data: old.data, url: old.url, method: old.method}, options); - var data = options.data, url = String(options.url), method = options.method.toLowerCase(); + _watch: function(){ + if (this._checkAnimate()) this.element.addEventListener(Browser.Features.getCSSTransition(), this.bound.animationEnd); + else this._animationEnd(); + }, - switch (typeOf(data)){ - case 'element': data = document.id(data).toQueryString(); break; - case 'object': case 'hash': data = Object.toQueryString(data); + _animationEnd: function(){ + if (Browser.Features.getCSSTransition()) this.element.removeEventListener(Browser.Features.getCSSTransition(), this.bound.animationEnd); + this.animating = false; + if (this.visible){ + this.fireEvent('show', this.element); + } else { + this.fireEvent('hide', this.element); + if (this.options.changeDisplayValue) this.element.hide(); + if (!this.options.persist){ + this.destroy(); + } else if (this._mask) { + this._mask.dispose(); + } } + }, - if (this.options.format){ - var format = 'format=' + this.options.format; - data = (data) ? format + '&' + data : format; - } + destroy: function(){ + if (this._mask) this._mask.destroy(); + this.fireEvent('destroy', this.element); + this.element.destroy(); + this._mask = null; + this.destroyed = true; + }, - if (this.options.emulation && !['get', 'post'].contains(method)){ - var _method = '_method=' + method; - data = (data) ? _method + '&' + data : _method; - method = 'post'; + hide: function(event, clicked){ + if (clicked) { + var immediateParentPopup = clicked.getParent('[data-behavior~=BS.Popup]'); + if (immediateParentPopup && immediateParentPopup != this.element) return; } - - if (this.options.urlEncoded && ['post', 'put'].contains(method)){ - var encoding = (this.options.encoding) ? '; charset=' + this.options.encoding : ''; - this.headers['Content-type'] = 'application/x-www-form-urlencoded' + encoding; + if (!this.visible || this.animating) return; + this.animating = true; + if (event && clicked && clicked.hasClass('stopEvent')){ + event.preventDefault(); } - if (!url) url = document.location.pathname; + if (Bootstrap.version == 2) document.id(document.body).removeEvent('click', this.bound.hide); + document.removeEvent('keyup', this.bound.keyMonitor); + this.element.removeEvent('click:relay(.close, .dismiss)', this.bound.hide); - var trimPosition = url.lastIndexOf('/'); - if (trimPosition > -1 && (trimPosition = url.indexOf('#')) > -1) url = url.substr(0, trimPosition); + if (this._checkAnimate()){ + this.element.removeClass('in'); + if (this._mask) this._mask.removeClass('in'); + } else { + this.element.hide(); + if (this._mask) this._mask.hide(); + } + this.visible = false; + this._watch(); + }, - if (this.options.noCache) - url += (url.contains('?') ? '&' : '?') + String.uniqueID(); + // PRIVATE - if (data && method == 'get'){ - url += (url.contains('?') ? '&' : '?') + data; - data = null; + _makeMask: function(){ + if (this.options.mask){ + if (!this._mask){ + this._mask = new Element('div.modal-backdrop.in'); + if (this._checkAnimate()) this._mask.addClass('fade'); + } } - - var xhr = this.xhr; - if (progressSupport){ - xhr.onloadstart = this.loadstart.bind(this); - xhr.onprogress = this.progress.bind(this); + if (this.options.closeOnClickOut && Bootstrap.version == 2){ + if (this._mask) this._mask.addEvent('click', this.bound.hide); + else document.id(document.body).addEvent('click', this.bound.hide); } + } - xhr.open(method.toUpperCase(), url, this.options.async, this.options.user, this.options.password); - if (this.options.user && 'withCredentials' in xhr) xhr.withCredentials = true; - - xhr.onreadystatechange = this.onStateChange.bind(this); +}); - Object.each(this.headers, function(value, key){ - try { - xhr.setRequestHeader(key, value); - } catch (e){ - this.fireEvent('exception', [key, value]); - } - }, this); +// Begin: Source/Behaviors/Behavior.BS.Popup.js +/* +--- - this.fireEvent('request'); - xhr.send(data); - if (!this.options.async) this.onStateChange(); - if (this.options.timeout) this.timer = this.timeout.delay(this.options.timeout, this); - return this; - }, +name: Behavior.Popup - cancel: function(){ - if (!this.running) return this; - this.running = false; - var xhr = this.xhr; - xhr.abort(); - clearTimeout(this.timer); - xhr.onreadystatechange = empty; - if (progressSupport) xhr.onprogress = xhr.onloadstart = empty; - this.xhr = new Browser.Request(); - this.fireEvent('cancel'); - return this; - } +description: Creates a bootstrap popup based on HTML markup. -}); +license: MIT-style license. -var methods = {}; -['get', 'post', 'put', 'delete', 'GET', 'POST', 'PUT', 'DELETE'].each(function(method){ - methods[method] = function(data){ - var object = { - method: method - }; - if (data != null) object.data = data; - return this.send(object); - }; -}); +authors: [Aaron Newton] -Request.implement(methods); +requires: + - Behavior/Behavior + - More/Object.Extras + - Bootstrap.Popup -Element.Properties.send = { +provides: [Behavior.BS.Popup] - set: function(options){ - var send = this.get('send').cancel(); - send.setOptions(options); - return this; - }, +... +*/ - get: function(){ - var send = this.retrieve('send'); - if (!send){ - send = new Request({ - data: this, link: 'cancel', method: this.get('method') || 'post', url: this.get('action') +Behavior.addGlobalFilters({ + 'BS.Popup': { + defaults: { + focusOnShow: "input[type=text], select, textarea", + hide: false, + animate: true, + closeOnEsc: true, + closeOnClickOut: true, + mask: true, + persist: true + }, + returns: Bootstrap.Popup, + setup: function(el, api){ + var popup = new Bootstrap.Popup(el, + Object.cleanValues( + api.getAs({ + persist: Boolean, + animate: Boolean, + closeOnEsc: Boolean, + closeOnClickOut: Boolean, + mask: Boolean + }) + ) + ); + popup.addEvent('destroy', function(){ + api.cleanup(el); }); - this.store('send', send); + if (api.get('focusOnShow')) { + popup.addEvent('show', function(){ + var input = document.id(popup).getElement(api.get('focusOnShow')); + if (input) input.select(); + }); + } + if (!el.hasClass('hide') && !api.getAs(Boolean, 'hide') && (!el.hasClass('in') && !el.hasClass('fade'))) { + popup.show(); + } + return popup; } - return send; - } - -}; - -Element.implement({ - - send: function(url){ - var sender = this.get('send'); - sender.send({data: this, url: url || sender.options.url}); - return this; } - }); -})(); - -// Begin: Source/Request/Request.HTML.js +// Begin: Source/Behaviors/Behavior.BS.Popup.FormRequest.js /* --- -name: Request.HTML +name: Behavior.BS.Popup.FormRequest -description: Extends the basic Request Class with additional methods for interacting with HTML responses. +description: Integrates FormRequest behavior into Popups. license: MIT-style license. -requires: [Element, Request] +authors: [Aaron Newton] -provides: Request.HTML +requires: + - More-Behaviors/Behavior.FormRequest + - /Behavior.BS.Popup + +provides: [Behavior.BS.Popup.FormRequest] ... */ -Request.HTML = new Class({ - - Extends: Request, - - options: { - update: false, - append: false, - evalScripts: true, - filter: false, - headers: { - Accept: 'text/html, application/xml, text/xml, */*' - } +Behavior.addGlobalPlugin("FormRequest", "Popup.FormRequest", { + defaults: { + closeOnSuccess: true }, + setup: function(element, api, instance){ + if (element.getParent('.modal')){ + var dismissed; + var dismissals = element.getElements('input.dismiss, input.close').map(function(el){ + return el.addEvent('click', function(){ + dismissed = true; + }).removeClass('dismiss').removeClass('close'); + }); + instance.addEvents({ + success: function(){ + var formRequestAPI = new BehaviorAPI(element, 'formrequest'); + if ((formRequestAPI.getAs(Boolean, 'closeOnSuccess') !== false && api.getAs(Boolean, 'closeOnSuccess') !== false) || dismissed){ + element.getParent('.modal').getBehaviorResult('BS.Popup').hide(); + } + } + }); + } + } +}); - success: function(text){ - var options = this.options, response = this.response; +// Begin: Source/UI/Bootstrap.Affix.js +/* +--- - response.html = text.stripScripts(function(script){ - response.javascript = script; - }); +name: Bootstrap.Affix - var match = response.html.match(/]*>([\s\S]*?)<\/body>/i); - if (match) response.html = match[1]; - var temp = new Element('div').set('html', response.html); +description: A MooTools implementation of Affix from Bootstrap; allows you to peg an element to a fixed position after scrolling. - response.tree = temp.childNodes; - response.elements = temp.getElements(options.filter || '*'); +authors: [Aaron Newton] - if (options.filter) response.tree = response.elements; - if (options.update){ - var update = document.id(options.update).empty(); - if (options.filter) update.adopt(response.elements); - else update.set('html', response.html); - } else if (options.append){ - var append = document.id(options.append); - if (options.filter) response.elements.reverse().inject(append); - else append.adopt(temp.getChildren()); - } - if (options.evalScripts) Browser.exec(response.javascript); +license: MIT-style license. - this.onSuccess(response.tree, response.elements, response.html, response.javascript); - } +requires: + - Core/Element.Dimensions + - More/Object.Extras + - /Bootstrap -}); +provides: [Bootstrap.Affix] -Element.Properties.load = { +... +*/ - set: function(options){ - var load = this.get('load').cancel(); - load.setOptions(options); - return this; - }, +Bootstrap.Affix = new Class({ - get: function(){ - var load = this.retrieve('load'); - if (!load){ - load = new Request.HTML({data: this, link: 'cancel', update: this, method: 'get'}); - this.store('load', load); - } - return load; - } + Implements: [Options, Events], -}; + options: { + // onPin: function(){}, + // onUnPin: function(isBottom){}, + top: 0, + bottom: null, + classNames: { + top: "affix-top", + bottom: "affix-bottom", + affixed: "affix" + } + }, -Element.implement({ + initialize: function(element, options){ + this.element = document.id(element); + this.setOptions(options); + this._reset(); + this.element.addClass(this.options.classNames.top); + this.attach(); + }, - load: function(){ - this.get('load').send(Array.link(arguments, {data: Type.isObject, url: Type.isString})); + attach: function(){ + Bootstrap.Affix.register(this); return this; - } - -}); + }, + detach: function(){ + Bootstrap.Affix.drop(this); + return this; + }, -// Begin: Source/Class/Class.Refactor.js -/* ---- + pinned: false, -script: Class.Refactor.js + pin: function(){ + this.pinned = true; + this._reset(); + this.element.addClass(this.options.classNames.affixed); + this.fireEvent('pin'); + return this; + }, -name: Class.Refactor + unpin: function(isBottom){ + this._reset(); + this.element.addClass(this.options.classNames[isBottom ? 'bottom' : 'top']); + this.pinned = false; + this.fireEvent('unPin', [isBottom]); + return this; + }, -description: Extends a class onto itself with new property, preserving any items attached to the class's namespace. + _reset: function(){ + this.element.removeClass(this.options.classNames.affixed) + .removeClass(this.options.classNames.top) + .removeClass(this.options.classNames.bottom); + return this; + } -license: MIT-style license +}); -authors: - - Aaron Newton +Bootstrap.Affix.registered = []; -requires: - - Core/Class - - /MooTools.More +Bootstrap.Affix.register = function(instance){ + if (!Bootstrap.Affix.attached) Bootstrap.Affix.attach(); + Bootstrap.Affix.registered.push(instance); + Bootstrap.Affix.onScroll(); +}; -# Some modules declare themselves dependent on Class.Refactor -provides: [Class.refactor, Class.Refactor] +Bootstrap.Affix.drop = function(instance){ + Bootstrap.Affix.registered.erase(instance); + if (Bootstrap.Affix.registered.length == 0) Bootstrap.Affix.detach(); +}; -... -*/ +Bootstrap.Affix.attach = function(){ + window.addEvent('scroll', Bootstrap.Affix.onScroll); + Bootstrap.Affix.attached = true; +}; -Class.refactor = function(original, refactors){ +Bootstrap.Affix.detach = function(){ + window.removeEvent('scroll', Bootstrap.Affix.onScroll); + Bootstrap.Affix.attached = false; +}; - Object.each(refactors, function(item, name){ - var origin = original.prototype[name]; - origin = (origin && origin.$origin) || origin || function(){}; - original.implement(name, (typeof item == 'function') ? function(){ - var old = this.previous; - this.previous = origin; - var value = item.apply(this, arguments); - this.previous = old; - return value; - } : item); - }); +Bootstrap.Affix.onScroll = function(_y){ + var y = _y || window.getScroll().y, + inSize; + for (var i = 0; i < Bootstrap.Affix.registered.length; i++){ + var instance = Bootstrap.Affix.registered[i]; + var bottom = instance.options.bottom, + top = instance.options.top; + if (bottom && bottom < 0){ + if (winSize == null) winSize = window.getSize().y; + bottom = winSize + bottom; + } - return original; + // if we've scrolled above the top line, unpin + if (y < top && instance.pinned) instance.unpin(); + // if we've scrolled past the bottom line, unpin + else if (bottom && bottom < y && y > top && instance.pinned) instance.unpin(true); + else if (y > top && (!bottom || (bottom && y < bottom)) && !instance.pinned) instance.pin(); + } }; - -// Begin: Source/Interface/Spinner.js +// Begin: Source/UI/Bootstrap.Popover.js /* --- -script: Spinner.js - -name: Spinner +name: Bootstrap.Popover -description: Adds a semi-transparent overlay over a dom element with a spinnin ajax icon. +description: A simple tooltip (yet larger than Bootstrap.Tooltip) implementation that works with the Twitter Bootstrap css framework. -license: MIT-style license +authors: [Aaron Newton] -authors: - - Aaron Newton +license: MIT-style license. requires: - - Core/Fx.Tween - - Core/Request - - /Class.refactor - - /Mask + - /Bootstrap.Tooltip -provides: [Spinner] +provides: Bootstrap.Popover ... */ -var Spinner = new Class({ - - Extends: Mask, +Bootstrap.Popover = new Class({ - Implements: Chain, + Extends: Bootstrap.Tooltip, - options: {/* - message: false,*/ - 'class': 'spinner', - containerPosition: {}, - content: { - 'class': 'spinner-content' - }, - messageContainer: { - 'class': 'spinner-msg' - }, - img: { - 'class': 'spinner-img' + options: { + location: 'right', + offset: Bootstrap.version == 2 ? 10 : 0, + getTitle: function(el){ + return el.get(this.options.title); }, - fxOptions: { - link: 'chain' + content: 'data-content', + getContent: function(el){ + return el.get(this.options.content); } }, - initialize: function(target, options){ - this.target = document.id(target) || document.id(document.body); - this.target.store('spinner', this); - this.setOptions(options); - this.render(); - this.inject(); - - // Add this to events for when noFx is true; parent methods handle hide/show. - var deactivate = function(){ this.active = false; }.bind(this); - this.addEvents({ - hide: deactivate, - show: deactivate - }); - }, + _makeTip: function(){ + if (!this.tip){ + var title = this.options.getTitle.apply(this, [this.element]) || this.options.fallback; + var content = this.options.getContent.apply(this, [this.element]); - render: function(){ - this.parent(); + var inner = new Element('div.popover-inner'); - this.element.set('id', this.options.id || 'spinner-' + String.uniqueID()); - this.content = document.id(this.options.content) || new Element('div', this.options.content); - this.content.inject(this.element); + if (title) { + var titleWrapper = new Element('h3.popover-title'); + if (typeOf(title) == "element") titleWrapper.adopt(title); + else titleWrapper.set('html', title); + inner.adopt(titleWrapper); + } else { + inner.addClass('no-title'); + } - if (this.options.message){ - this.msg = document.id(this.options.message) || new Element('p', this.options.messageContainer).appendText(this.options.message); - this.msg.inject(this.content); + if (typeOf(content) != "element") content = new Element('p', { html: content}); + inner.adopt(new Element('div.popover-content').adopt(content)); + this.tip = new Element('div.popover').addClass(this.options.location) + .adopt(new Element('div.arrow')) + .adopt(inner); + if (this.options.animate) this.tip.addClass('fade'); + if (Browser.Features.cssTransition && this.tip.addEventListener){ + this.tip.addEventListener(Browser.Features.transitionEnd, this.bound.complete); + } + this.element.set('alt', '').set('title', ''); } + return this.tip; + } - if (this.options.img){ - this.img = document.id(this.options.img) || new Element('div', this.options.img); - this.img.inject(this.content); - } +}); - this.element.set('tween', this.options.fxOptions); - }, +// Begin: Source/Behaviors/Behavior.BS.Popover.js +/* +--- - show: function(noFx){ - if (this.active) return this.chain(this.show.bind(this)); - if (!this.hidden){ - this.callChain.delay(20, this); - return this; - } +name: Behavior.BS.Popover - this.active = true; +description: Instantiates Bootstrap.Popover based on HTML markup. - return this.parent(noFx); - }, +license: MIT-style license. - showMask: function(noFx){ - var pos = function(){ - this.content.position(Object.merge({ - relativeTo: this.element - }, this.options.containerPosition)); - }.bind(this); +authors: [Aaron Newton] - if (noFx){ - this.parent(); - pos(); - } else { - if (!this.options.style.opacity) this.options.style.opacity = this.element.getStyle('opacity').toFloat(); - this.element.setStyles({ - display: 'block', - opacity: 0 - }).tween('opacity', this.options.style.opacity); - pos(); - this.hidden = false; - this.fireEvent('show'); - this.callChain(); - } - }, +requires: + - /Bootstrap.Popover + - Behavior/Behavior + - More/Object.Extras - hide: function(noFx){ - if (this.active) return this.chain(this.hide.bind(this)); - if (this.hidden){ - this.callChain.delay(20, this); - return this; - } - this.active = true; - return this.parent(noFx); - }, +provides: [Behavior.BS.Popover] + +... +*/ +Behavior.addGlobalFilters({ + 'BS.Popover': { + defaults: { + contentElement: null, + cloneContent: false, + titleElement: null, + cloneTitle: false, + onOverflow: false, + location: 'right', //below, left, right + animate: true, + delayIn: 200, + delayOut: 0, + offset: Bootstrap.version == 2 ? 10 : 0, + trigger: 'hover' //focus, manual + }, + delayUntil: 'mouseover,focus', + returns: Bootstrap.Popover, + setup: function(el, api){ + var options = Object.cleanValues( + api.getAs({ + onOverflow: Boolean, + location: String, + animate: Boolean, + delayIn: Number, + delayOut: Number, + html: Boolean, + offset: Number, + trigger: String + }) + ); + + var getter = function(which){ + if (api.get(which + 'Element')) { + var target = el.getElement(api.get(which + 'Element')); + if (!target) api.fail('could not find ' + which + ' for popup'); + if (api.get('clone' + which.capitalize())) target = target.clone(true, true); + return target.setStyle('display', 'block'); + } else { + return api.get(which) || el.get(which); + } + }; - hideMask: function(noFx){ - if (noFx) return this.parent(); - this.element.tween('opacity', 0).get('tween').chain(function(){ - this.element.setStyle('display', 'none'); - this.hidden = true; - this.fireEvent('hide'); - this.callChain(); - }.bind(this)); - }, + options.getContent = getter.pass('content'); + options.getTitle = getter.pass('title'); - destroy: function(){ - this.content.destroy(); - this.parent(); - this.target.eliminate('spinner'); + var tip = new Bootstrap.Popover(el, options); + if (api.event && api.get('trigger') != 'click') tip._enter(); + api.onCleanup(tip.destroy.bind(tip)); + return tip; + } } - }); -Request = Class.refactor(Request, { +// Begin: Source/Behaviors/Behavior.BS.Affix.js +/* +--- - options: { - useSpinner: false, - spinnerOptions: {}, - spinnerTarget: false - }, +name: Behavior.BS.Affix - initialize: function(options){ - this._send = this.send; - this.send = function(options){ - var spinner = this.getSpinner(); - if (spinner) spinner.chain(this._send.pass(options, this)).show(); - else this._send(options); - return this; - }; - this.previous(options); - }, +description: Markup invocation for Bootstrap.Affix class. - getSpinner: function(){ - if (!this.spinner){ - var update = document.id(this.options.spinnerTarget) || document.id(this.options.update); - if (this.options.useSpinner && update){ - update.set('spinner', this.options.spinnerOptions); - var spinner = this.spinner = update.get('spinner'); - ['complete', 'exception', 'cancel'].each(function(event){ - this.addEvent(event, spinner.hide.bind(spinner)); - }, this); - } - } - return this.spinner; - } +license: MIT-style license. -}); +authors: [Aaron Newton] -Element.Properties.spinner = { +requires: + - Behavior/Behavior + - /Bootstrap.Affix - set: function(options){ - var spinner = this.retrieve('spinner'); - if (spinner) spinner.destroy(); - return this.eliminate('spinner').store('spinner:options', options); - }, +provides: [Behavior.BS.Affix] - get: function(){ - var spinner = this.retrieve('spinner'); - if (!spinner){ - spinner = new Spinner(this, this.retrieve('spinner:options')); - this.store('spinner', spinner); - } - return spinner; - } +... +*/ -}; +Behavior.addGlobalFilters({ + 'BS.Affix': { -Element.implement({ + requires: ['top'], - spin: function(options){ - if (options) this.set('spinner', options); - this.get('spinner').show(); - return this; - }, + setup: function(el, api){ + var affix = new Bootstrap.Affix(el, + Object.cleanValues( + api.getAs({ + top: Number, + bottom: Number, + classNames: Object + }) + ) + ); - unspin: function(){ - this.get('spinner').hide(); - return this; - } + api.onCleanup(affix.detach.bind(affix)); + return affix; + } + } }); - -// Begin: Source/Types/String.QueryString.js +// Begin: Source/Fx/Fx.Elements.js /* --- -script: String.QueryString.js +script: Fx.Elements.js -name: String.QueryString +name: Fx.Elements -description: Methods for dealing with URI query strings. +description: Effect to change any number of CSS properties of any number of Elements. license: MIT-style license authors: - - Sebastian Markbåge - - Aaron Newton - - Lennart Pilon - Valerio Proietti requires: - - Core/Array - - Core/String + - Core/Fx.CSS - /MooTools.More -provides: [String.QueryString] +provides: [Fx.Elements] ... */ -String.implement({ +Fx.Elements = new Class({ - parseQueryString: function(decodeKeys, decodeValues){ - if (decodeKeys == null) decodeKeys = true; - if (decodeValues == null) decodeValues = true; + Extends: Fx.CSS, - var vars = this.split(/[&;]/), - object = {}; - if (!vars.length) return object; + initialize: function(elements, options){ + this.elements = this.subject = $$(elements); + this.parent(options); + }, - vars.each(function(val){ - var index = val.indexOf('=') + 1, - value = index ? val.substr(index) : '', - keys = index ? val.substr(0, index - 1).match(/([^\]\[]+|(\B)(?=\]))/g) : [val], - obj = object; - if (!keys) return; - if (decodeValues) value = decodeURIComponent(value); - keys.each(function(key, i){ - if (decodeKeys) key = decodeURIComponent(key); - var current = obj[key]; + compute: function(from, to, delta){ + var now = {}; - if (i < keys.length - 1) obj = obj[key] = current || {}; - else if (typeOf(current) == 'array') current.push(value); - else obj[key] = current != null ? [current, value] : value; - }); - }); + for (var i in from){ + var iFrom = from[i], iTo = to[i], iNow = now[i] = {}; + for (var p in iFrom) iNow[p] = this.parent(iFrom[p], iTo[p], delta); + } - return object; + return now; }, - cleanQueryString: function(method){ - return this.split('&').filter(function(val){ - var index = val.indexOf('='), - key = index < 0 ? '' : val.substr(0, index), - value = val.substr(index + 1); + set: function(now){ + for (var i in now){ + if (!this.elements[i]) continue; - return method ? method.call(null, key, value) : (value || value === 0); - }).join('&'); + var iNow = now[i]; + for (var p in iNow) this.render(this.elements[i], p, iNow[p], this.options.unit); + } + + return this; + }, + + start: function(obj){ + if (!this.check(obj)) return this; + var from = {}, to = {}; + + for (var i in obj){ + if (!this.elements[i]) continue; + + var iProps = obj[i], iFrom = from[i] = {}, iTo = to[i] = {}; + + for (var p in iProps){ + var parsed = this.prepare(this.elements[i], p, iProps[p]); + iFrom[p] = parsed.from; + iTo[p] = parsed.to; + } + } + + return this.parent(from, to); } }); -// Begin: Source/Element/Element.Event.Pseudos.js +// Begin: Source/Fx/Fx.Accordion.js /* --- -name: Element.Event.Pseudos +script: Fx.Accordion.js -description: Adds the functionality to add pseudo events for Elements +name: Fx.Accordion + +description: An Fx.Elements extension which allows you to easily create accordion type controls. license: MIT-style license authors: - - Arian Stolwijk + - Valerio Proietti -requires: [Core/Element.Event, Core/Element.Delegation, Events.Pseudos] +requires: + - Core/Element.Event + - /Fx.Elements -provides: [Element.Event.Pseudos, Element.Delegation] +provides: [Fx.Accordion] ... */ -(function(){ +Fx.Accordion = new Class({ -var pseudos = {relay: false}, - copyFromEvents = ['once', 'throttle', 'pause'], - count = copyFromEvents.length; + Extends: Fx.Elements, -while (count--) pseudos[copyFromEvents[count]] = Events.lookupPseudo(copyFromEvents[count]); + options: {/* + onActive: function(toggler, section){}, + onBackground: function(toggler, section){},*/ + fixedHeight: false, + fixedWidth: false, + display: 0, + show: false, + height: true, + width: false, + opacity: true, + alwaysHide: false, + trigger: 'click', + initialDisplayFx: true, + resetHeight: true + }, + + initialize: function(){ + var defined = function(obj){ + return obj != null; + }; -DOMEvent.definePseudo = function(key, listener){ - pseudos[key] = listener; - return this; -}; + var params = Array.link(arguments, { + 'container': Type.isElement, //deprecated + 'options': Type.isObject, + 'togglers': defined, + 'elements': defined + }); + this.parent(params.elements, params.options); -var proto = Element.prototype; -[Element, Window, Document].invoke('implement', Events.Pseudos(pseudos, proto.addEvent, proto.removeEvent)); + var options = this.options, + togglers = this.togglers = $$(params.togglers); -})(); + this.previous = -1; + this.internalChain = new Chain(); + if (options.alwaysHide) this.options.link = 'chain'; -// Begin: Source/Forms/Form.Request.js -/* ---- + if (options.show || this.options.show === 0){ + options.display = false; + this.previous = options.show; + } -script: Form.Request.js + if (options.start){ + options.display = false; + options.show = false; + } -name: Form.Request + var effects = this.effects = {}; -description: Handles the basic functionality of submitting a form and updating a dom element with the result. + if (options.opacity) effects.opacity = 'fullOpacity'; + if (options.width) effects.width = options.fixedWidth ? 'fullWidth' : 'offsetWidth'; + if (options.height) effects.height = options.fixedHeight ? 'fullHeight' : 'scrollHeight'; -license: MIT-style license + for (var i = 0, l = togglers.length; i < l; i++) this.addSection(togglers[i], this.elements[i]); -authors: - - Aaron Newton + this.elements.each(function(el, i){ + if (options.show === i){ + this.fireEvent('active', [togglers[i], el]); + } else { + for (var fx in effects) el.setStyle(fx, 0); + } + }, this); -requires: - - Core/Request.HTML - - /Class.Binds - - /Class.Occlude - - /Spinner - - /String.QueryString - - /Element.Delegation + if (options.display || options.display === 0 || options.initialDisplayFx === false){ + this.display(options.display, options.initialDisplayFx); + } + + if (options.fixedHeight !== false) options.resetHeight = false; + this.addEvent('complete', this.internalChain.callChain.bind(this.internalChain)); + }, + + addSection: function(toggler, element){ + toggler = document.id(toggler); + element = document.id(element); + this.togglers.include(toggler); + this.elements.include(element); + + var togglers = this.togglers, + options = this.options, + test = togglers.contains(toggler), + idx = togglers.indexOf(toggler), + displayer = this.display.pass(idx, this); + + toggler.store('accordion:display', displayer) + .addEvent(options.trigger, displayer); + + if (options.height) element.setStyles({'padding-top': 0, 'border-top': 'none', 'padding-bottom': 0, 'border-bottom': 'none'}); + if (options.width) element.setStyles({'padding-left': 0, 'border-left': 'none', 'padding-right': 0, 'border-right': 'none'}); + + element.fullOpacity = 1; + if (options.fixedWidth) element.fullWidth = options.fixedWidth; + if (options.fixedHeight) element.fullHeight = options.fixedHeight; + element.setStyle('overflow', 'hidden'); + + if (!test) for (var fx in this.effects){ + element.setStyle(fx, 0); + } + return this; + }, + + removeSection: function(toggler, displayIndex){ + var togglers = this.togglers, + idx = togglers.indexOf(toggler), + element = this.elements[idx]; + + var remover = function(){ + togglers.erase(toggler); + this.elements.erase(element); + this.detach(toggler); + }.bind(this); + + if (this.now == idx || displayIndex != null){ + this.display(displayIndex != null ? displayIndex : (idx - 1 >= 0 ? idx - 1 : 0)).chain(remover); + } else { + remover(); + } + return this; + }, + + detach: function(toggler){ + var remove = function(toggler){ + toggler.removeEvent(this.options.trigger, toggler.retrieve('accordion:display')); + }.bind(this); + + if (!toggler) this.togglers.each(remove); + else remove(toggler); + return this; + }, + + display: function(index, useFx){ + if (!this.check(index, useFx)) return this; + + var obj = {}, + elements = this.elements, + options = this.options, + effects = this.effects; + + if (useFx == null) useFx = true; + if (typeOf(index) == 'element') index = elements.indexOf(index); + if (index == this.previous && !options.alwaysHide) return this; + + if (options.resetHeight){ + var prev = elements[this.previous]; + if (prev && !this.selfHidden){ + for (var fx in effects) prev.setStyle(fx, prev[effects[fx]]); + } + } + + if ((this.timer && options.link == 'chain') || (index === this.previous && !options.alwaysHide)) return this; + + this.previous = index; + this.selfHidden = false; + + elements.each(function(el, i){ + obj[i] = {}; + var hide; + if (i != index){ + hide = true; + } else if (options.alwaysHide && ((el.offsetHeight > 0 && options.height) || el.offsetWidth > 0 && options.width)){ + hide = true; + this.selfHidden = true; + } + this.fireEvent(hide ? 'background' : 'active', [this.togglers[i], el]); + for (var fx in effects) obj[i][fx] = hide ? 0 : el[effects[fx]]; + if (!useFx && !hide && options.resetHeight) obj[i].height = 'auto'; + }, this); + + this.internalChain.clearChain(); + this.internalChain.chain(function(){ + if (options.resetHeight && !this.selfHidden){ + var el = elements[index]; + if (el) el.setStyle('height', 'auto'); + } + }.bind(this)); + + return useFx ? this.start(obj) : this.set(obj).internalChain.callChain(); + } + +}); + +/*<1.2compat>*/ +/* + Compatibility with 1.2.0 +*/ +var Accordion = new Class({ + + Extends: Fx.Accordion, + + initialize: function(){ + this.parent.apply(this, arguments); + var params = Array.link(arguments, {'container': Type.isElement}); + this.container = params.container; + }, + + addSection: function(toggler, element, pos){ + toggler = document.id(toggler); + element = document.id(element); + + var test = this.togglers.contains(toggler); + var len = this.togglers.length; + if (len && (!test || pos)){ + pos = pos != null ? pos : len - 1; + toggler.inject(this.togglers[pos], 'before'); + element.inject(toggler, 'after'); + } else if (this.container && !test){ + toggler.inject(this.container); + element.inject(this.container); + } + return this.parent.apply(this, arguments); + } + +}); +/**/ -provides: [Form.Request] +// Begin: Source/Fx/Behavior.FxAccordion.js +/* +--- +description: Creates an Fx.Accordion from any element with Accordion in its data-behavior property. Uses the .toggle elements within the element as the toggles and the .target elements as the targets. +provides: [Behavior.Accordion, Behavior.FxAccordion] +requires: [Behavior/Behavior, More/Fx.Accordion, Behavior/Element.Data, More/Object.Extras] +script: Behavior.Accordion.js +name: Behavior.Accordion ... */ -if (!window.Form) window.Form = {}; +Behavior.addGlobalFilter('Accordion', { + deprecated: { + headers:'toggler-elements', + sections:'section-elements' + }, + defaults: { + // defaults from Fx.Accordion: + display: 0, + height: true, + width: false, + opacity: true, + alwaysHide: false, + trigger: 'click', + initialDisplayFx: true, + resetHeight: true, + headers: '.header', + sections: '.section' + }, + setup: function(element, api){ + var options = Object.cleanValues( + api.getAs({ + fixedHeight: Number, + fixedWidth: Number, + display: Number, + show: Number, + height: Boolean, + width: Boolean, + opacity: Boolean, + alwaysHide: Boolean, + trigger: String, + initialDisplayFx: Boolean, + resetHeight: Boolean + }) + ); + var accordion = new Fx.Accordion(element.getElements(api.get('headers')), element.getElements(api.get('sections')), options); + api.onCleanup(accordion.detach.bind(accordion)); + return accordion; + } +}); -(function(){ +// Begin: Source/Fx/Fx.Morph.js +/* +--- - Form.Request = new Class({ +name: Fx.Morph - Binds: ['onSubmit', 'onFormValidate'], +description: Formerly Fx.Styles, effect to transition any number of CSS properties for an element using an object of rules, or CSS based selector rules. - Implements: [Options, Events, Class.Occlude], +license: MIT-style license. - options: {/* - onFailure: function(){}, - onSuccess: function(){}, // aliased to onComplete, - onSend: function(){}*/ - requestOptions: { - evalScripts: true, - useSpinner: true, - emulation: false, - link: 'ignore' - }, - sendButtonClicked: true, - extraData: {}, - resetForm: true - }, +requires: Fx.CSS - property: 'form.request', +provides: Fx.Morph - initialize: function(form, target, options){ - this.element = document.id(form); - if (this.occlude()) return this.occluded; - this.setOptions(options) - .setTarget(target) - .attach(); - }, +... +*/ - setTarget: function(target){ - this.target = document.id(target); - if (!this.request){ - this.makeRequest(); - } else { - this.request.setOptions({ - update: this.target - }); - } - return this; - }, +Fx.Morph = new Class({ - toElement: function(){ - return this.element; - }, + Extends: Fx.CSS, - makeRequest: function(){ - var self = this; - this.request = new Request.HTML(Object.merge({ - update: this.target, - emulation: false, - spinnerTarget: this.element, - method: this.element.get('method') || 'post' - }, this.options.requestOptions)).addEvents({ - success: function(tree, elements, html, javascript){ - ['complete', 'success'].each(function(evt){ - self.fireEvent(evt, [self.target, tree, elements, html, javascript]); - }); - }, - failure: function(){ - self.fireEvent('complete', arguments).fireEvent('failure', arguments); - }, - exception: function(){ - self.fireEvent('failure', arguments); - } - }); - return this.attachReset(); - }, + initialize: function(element, options){ + this.element = this.subject = document.id(element); + this.parent(options); + }, - attachReset: function(){ - if (!this.options.resetForm) return this; - this.request.addEvent('success', function(){ - Function.attempt(function(){ - this.element.reset(); - }.bind(this)); - if (window.OverText) OverText.update(); - }.bind(this)); - return this; - }, + set: function(now){ + if (typeof now == 'string') now = this.search(now); + for (var p in now) this.render(this.element, p, now[p], this.options.unit); + return this; + }, - attach: function(attach){ - var method = (attach != false) ? 'addEvent' : 'removeEvent'; - this.element[method]('click:relay(button, input[type=submit])', this.saveClickedButton.bind(this)); + compute: function(from, to, delta){ + var now = {}; + for (var p in from) now[p] = this.parent(from[p], to[p], delta); + return now; + }, - var fv = this.element.retrieve('validator'); - if (fv) fv[method]('onFormValidate', this.onFormValidate); - else this.element[method]('submit', this.onSubmit); + start: function(properties){ + if (!this.check(properties)) return this; + if (typeof properties == 'string') properties = this.search(properties); + var from = {}, to = {}; + for (var p in properties){ + var parsed = this.prepare(this.element, p, properties[p]); + from[p] = parsed.from; + to[p] = parsed.to; + } + return this.parent(from, to); + } - return this; - }, +}); - detach: function(){ - return this.attach(false); - }, +Element.Properties.morph = { - //public method - enable: function(){ - return this.attach(); - }, + set: function(options){ + this.get('morph').cancel().setOptions(options); + return this; + }, - //public method - disable: function(){ - return this.detach(); - }, + get: function(){ + var morph = this.retrieve('morph'); + if (!morph){ + morph = new Fx.Morph(this, {link: 'cancel'}); + this.store('morph', morph); + } + return morph; + } - onFormValidate: function(valid, form, event){ - //if there's no event, then this wasn't a submit event - if (!event) return; - var fv = this.element.retrieve('validator'); - if (valid || (fv && !fv.options.stopOnFailure)){ - event.stop(); - this.send(); - } - }, +}; - onSubmit: function(event){ - var fv = this.element.retrieve('validator'); - if (fv){ - //form validator was created after Form.Request - this.element.removeEvent('submit', this.onSubmit); - fv.addEvent('onFormValidate', this.onFormValidate); - this.element.validate(); - return; - } - if (event) event.stop(); - this.send(); - }, +Element.implement({ - saveClickedButton: function(event, target){ - var targetName = target.get('name'); - if (!targetName || !this.options.sendButtonClicked) return; - this.options.extraData[targetName] = target.get('value') || true; - this.clickedCleaner = function(){ - delete this.options.extraData[targetName]; - this.clickedCleaner = function(){}; - }.bind(this); - }, + morph: function(props){ + this.get('morph').start(props); + return this; + } - clickedCleaner: function(){}, +}); - send: function(){ - var str = this.element.toQueryString().trim(), - data = Object.toQueryString(this.options.extraData); - if (str) str += "&" + data; - else str = data; +// Begin: Source/Fx/Fx.Reveal.js +/* +--- - this.fireEvent('send', [this.element, str.parseQueryString()]); - this.request.send({ - data: str, - url: this.options.requestOptions.url || this.element.get('action') - }); - this.clickedCleaner(); - return this; - } +script: Fx.Reveal.js - }); +name: Fx.Reveal - Element.implement('formUpdate', function(update, options){ - var fq = this.retrieve('form.request'); - if (!fq){ - fq = new Form.Request(this, update, options); - } else { - if (update) fq.setTarget(update); - if (options) fq.setOptions(options).makeRequest(); - } - fq.send(); - return this; - }); +description: Defines Fx.Reveal, a class that shows and hides elements with a transition. -})(); +license: MIT-style license + +authors: + - Aaron Newton +requires: + - Core/Fx.Morph + - /Element.Shortcuts + - /Element.Measure -// Begin: Source/Behaviors/Behavior.BS.Popup.FormRequest.js -/* ---- +provides: [Fx.Reveal] -name: Behavior.BS.Popup.FormRequest +... +*/ -description: Integrates FormRequest behavior into Popups. +(function(){ -license: MIT-style license. -authors: [Aaron Newton] +var hideTheseOf = function(object){ + var hideThese = object.options.hideInputs; + if (window.OverText){ + var otClasses = [null]; + OverText.each(function(ot){ + otClasses.include('.' + ot.options.labelClass); + }); + if (otClasses) hideThese += otClasses.join(', '); + } + return (hideThese) ? object.element.getElements(hideThese) : null; +}; + + +Fx.Reveal = new Class({ + + Extends: Fx.Morph, -requires: - - /Behavior.BS.Popup - - More/Form.Request + options: {/* + onShow: function(thisElement){}, + onHide: function(thisElement){}, + onComplete: function(thisElement){}, + heightOverride: null, + widthOverride: null,*/ + link: 'cancel', + styles: ['padding', 'border', 'margin'], + transitionOpacity: !Browser.ie6, + mode: 'vertical', + display: function(){ + return this.element.get('tag') != 'tr' ? 'block' : 'table-row'; + }, + opacity: 1, + hideInputs: Browser.ie ? 'select, input, textarea, object, embed' : null + }, -provides: [Behavior.BS.Popup.FormRequest] + dissolve: function(){ + if (!this.hiding && !this.showing){ + if (this.element.getStyle('display') != 'none'){ + this.hiding = true; + this.showing = false; + this.hidden = true; + this.cssText = this.element.style.cssText; -... -*/ + var startStyles = this.element.getComputedSize({ + styles: this.options.styles, + mode: this.options.mode + }); + if (this.options.transitionOpacity) startStyles.opacity = this.options.opacity; -Behavior.addGlobalPlugin("FormRequest", "Popup.FormRequest", { - defaults: { - closeOnSuccess: true - }, - setup: function(element, api, instance){ - if (element.getParent('.modal')){ - var dismissed; - var dismissals = element.getElements('input.dismiss, input.close').map(function(el){ - return el.addEvent('click', function(){ - dismissed = true; - }).removeClass('dismiss').removeClass('close'); - }); - instance.addEvents({ - success: function(){ - var formRequestAPI = new BehaviorAPI(element, 'formrequest'); - if (formRequestAPI.getAs(Boolean, 'closeOnSuccess') !== false || api.get(Boolean, 'closeOnSuccess') !== false || dismissed){ - element.getParent('.modal').getBehaviorResult('BS.Popup').hide(); - } - } - }); - } - } -}); + var zero = {}; + Object.each(startStyles, function(style, name){ + zero[name] = [style, 0]; + }); -// Begin: Source/UI/Bootstrap.Popover.js -/* ---- + this.element.setStyles({ + display: Function.from(this.options.display).call(this), + overflow: 'hidden' + }); -name: Bootstrap.Popover + var hideThese = hideTheseOf(this); + if (hideThese) hideThese.setStyle('visibility', 'hidden'); -description: A simple tooltip (yet larger than Bootstrap.Tooltip) implementation that works with the Twitter Bootstrap css framework. + this.$chain.unshift(function(){ + if (this.hidden){ + this.hiding = false; + this.element.style.cssText = this.cssText; + this.element.setStyle('display', 'none'); + if (hideThese) hideThese.setStyle('visibility', 'visible'); + } + this.fireEvent('hide', this.element); + this.callChain(); + }.bind(this)); -authors: [Aaron Newton] + this.start(zero); + } else { + this.callChain.delay(10, this); + this.fireEvent('complete', this.element); + this.fireEvent('hide', this.element); + } + } else if (this.options.link == 'chain'){ + this.chain(this.dissolve.bind(this)); + } else if (this.options.link == 'cancel' && !this.hiding){ + this.cancel(); + this.dissolve(); + } + return this; + }, -license: MIT-style license. + reveal: function(){ + if (!this.showing && !this.hiding){ + if (this.element.getStyle('display') == 'none'){ + this.hiding = false; + this.showing = true; + this.hidden = false; + this.cssText = this.element.style.cssText; -requires: - - /Bootstrap.Tooltip + var startStyles; + this.element.measure(function(){ + startStyles = this.element.getComputedSize({ + styles: this.options.styles, + mode: this.options.mode + }); + }.bind(this)); + if (this.options.heightOverride != null) startStyles.height = this.options.heightOverride.toInt(); + if (this.options.widthOverride != null) startStyles.width = this.options.widthOverride.toInt(); + if (this.options.transitionOpacity){ + this.element.setStyle('opacity', 0); + startStyles.opacity = this.options.opacity; + } -provides: Bootstrap.Popover + var zero = { + height: 0, + display: Function.from(this.options.display).call(this) + }; + Object.each(startStyles, function(style, name){ + zero[name] = 0; + }); + zero.overflow = 'hidden'; -... -*/ + this.element.setStyles(zero); -Bootstrap.Popover = new Class({ + var hideThese = hideTheseOf(this); + if (hideThese) hideThese.setStyle('visibility', 'hidden'); - Extends: Bootstrap.Tooltip, + this.$chain.unshift(function(){ + this.element.style.cssText = this.cssText; + this.element.setStyle('display', Function.from(this.options.display).call(this)); + if (!this.hidden) this.showing = false; + if (hideThese) hideThese.setStyle('visibility', 'visible'); + this.callChain(); + this.fireEvent('show', this.element); + }.bind(this)); - options: { - location: 'right', - offset: 10, - getTitle: function(el){ - return el.get(this.options.title); - }, - content: 'data-content', - getContent: function(el){ - return el.get(this.options.content); + this.start(startStyles); + } else { + this.callChain(); + this.fireEvent('complete', this.element); + this.fireEvent('show', this.element); + } + } else if (this.options.link == 'chain'){ + this.chain(this.reveal.bind(this)); + } else if (this.options.link == 'cancel' && !this.showing){ + this.cancel(); + this.reveal(); } + return this; }, - _makeTip: function(){ - if (!this.tip){ - this.tip = new Element('div.popover').addClass(this.options.location) - .adopt(new Element('div.arrow')) - .adopt( - new Element('div.popover-inner').adopt( - new Element('h3.popover-title', { html: this.options.getTitle.apply(this, [this.element]) || this.options.fallback }) - ).adopt( - new Element('div.popover-content').adopt( - new Element('p', { html: this.options.getContent.apply(this, [this.element])}) - ) - ) - ); - if (this.options.animate) this.tip.addClass('fade'); - if (Browser.Features.cssTransition && this.tip.addEventListener){ - this.tip.addEventListener(Browser.Features.transitionEnd, this.bound.complete); - } - this.element.set('alt', '').set('title', ''); + toggle: function(){ + if (this.element.getStyle('display') == 'none'){ + this.reveal(); + } else { + this.dissolve(); } - return this.tip; + return this; + }, + + cancel: function(){ + this.parent.apply(this, arguments); + if (this.cssText != null) this.element.style.cssText = this.cssText; + this.hiding = false; + this.showing = false; + return this; } }); -// Begin: Source/Behaviors/Behavior.BS.Popover.js -/* ---- +Element.Properties.reveal = { -name: Behavior.BS.Popover + set: function(options){ + this.get('reveal').cancel().setOptions(options); + return this; + }, -description: Instantiates Bootstrap.Popover based on HTML markup. + get: function(){ + var reveal = this.retrieve('reveal'); + if (!reveal){ + reveal = new Fx.Reveal(this); + this.store('reveal', reveal); + } + return reveal; + } -license: MIT-style license. +}; -authors: [Aaron Newton] +Element.Properties.dissolve = Element.Properties.reveal; -requires: - - /Bootstrap.Popover - - Behavior/Behavior - - More/Object.Extras +Element.implement({ -provides: [Behavior.BS.Popover] + reveal: function(options){ + this.get('reveal').setOptions(options).reveal(); + return this; + }, -... -*/ -Behavior.addGlobalFilters({ - 'BS.Popover': { - defaults: { - onOverflow: false, - location: 'right', //below, left, right - animate: true, - delayIn: 200, - delayOut: 0, - offset: 10, - trigger: 'hover' //focus, manual - }, - delayUntil: 'mouseover,focus', - returns: Bootstrap.Popover, - setup: function(el, api){ - var options = Object.cleanValues( - api.getAs({ - onOverflow: Boolean, - location: String, - animate: Boolean, - delayIn: Number, - delayOut: Number, - html: Boolean, - offset: Number, - trigger: String - }) - ); - options.getContent = Function.from(api.get('content')); - options.getTitle = Function.from(api.get('title') || el.get('title')); - var tip = new Bootstrap.Popover(el, options); - if (api.event) tip._enter(); - api.onCleanup(tip.destroy.bind(tip)); - return tip; - } + dissolve: function(options){ + this.get('reveal').setOptions(options).dissolve(); + return this; + }, + + nix: function(options){ + var params = Array.link(arguments, {destroy: Type.isBoolean, options: Type.isObject}); + this.get('reveal').setOptions(options).dissolve().chain(function(){ + this[params.destroy ? 'destroy' : 'dispose'](); + }.bind(this)); + return this; + }, + + wink: function(){ + var params = Array.link(arguments, {duration: Type.isNumber, options: Type.isObject}); + var reveal = this.get('reveal').setOptions(params.options); + reveal.reveal().chain(function(){ + (function(){ + reveal.dissolve(); + }).delay(params.duration || 2000); + }); } + }); +})(); + + // Begin: Source/Locale/Locale.js /* --- @@ -10971,7 +11800,16 @@ tidy = { '-': /[\u2013]/g, // '--': /[\u2014]/g, '»': /[\uFFFD]/g -}; +}, + +conversions = { + ms: 1, + s: 1000, + m: 6e4, + h: 36e5 +}, + +findUnits = /(\d*.?\d+)([msh]+)/; var walk = function(string, replacements){ var result = string, key; @@ -11033,6 +11871,13 @@ String.implement({ if (trail) string += trail; } return string; + }, + + ms: function(){ + // "Borrowed" from https://gist.github.com/1503944 + var units = findUnits.exec(this); + if (units == null) return Number(this); + return Number(units[1]) * conversions[units[2]]; } }); @@ -11260,6 +12105,7 @@ authors: requires: - Core/Options - Core/Events + - Core/Element.Delegation - Core/Slick.Finder - Core/Element.Event - Core/Element.Style @@ -11361,8 +12207,6 @@ Form.Validator = new Class({ Implements: [Options, Events], - Binds: ['onSubmit'], - options: {/* onFormValidate: function(isValid, form, event){}, onElementValidate: function(isValid, field, className, warn){}, @@ -11388,11 +12232,15 @@ Form.Validator = new Class({ initialize: function(form, options){ this.setOptions(options); this.element = document.id(form); - this.element.store('validator', this); this.warningPrefix = Function.from(this.options.warningPrefix)(); this.errorPrefix = Function.from(this.options.errorPrefix)(); - if (this.options.evaluateOnSubmit) this.element.addEvent('submit', this.onSubmit); - if (this.options.evaluateFieldsOnBlur || this.options.evaluateFieldsOnChange) this.watchFields(this.getFields()); + this._bound = { + onSubmit: this.onSubmit.bind(this), + blurOrChange: function(event, field){ + this.validationMonitor(field, true); + }.bind(this) + }; + this.enable(); }, toElement: function(){ @@ -11403,13 +12251,24 @@ Form.Validator = new Class({ return (this.fields = this.element.getElements(this.options.fieldSelectors)); }, - watchFields: function(fields){ - fields.each(function(el){ - if (this.options.evaluateFieldsOnBlur) - el.addEvent('blur', this.validationMonitor.pass([el, false], this)); - if (this.options.evaluateFieldsOnChange) - el.addEvent('change', this.validationMonitor.pass([el, true], this)); - }, this); + enable: function(){ + this.element.store('validator', this); + if (this.options.evaluateOnSubmit) this.element.addEvent('submit', this._bound.onSubmit); + if (this.options.evaluateFieldsOnBlur){ + this.element.addEvent('blur:relay(input,select,textarea)', this._bound.blurOrChange); + } + if (this.options.evaluateFieldsOnChange){ + this.element.addEvent('change:relay(input,select,textarea)', this._bound.blurOrChange); + } + }, + + disable: function(){ + this.element.eliminate('validator'); + this.element.removeEvents({ + submit: this._bound.onSubmit, + 'blur:relay(input,select,textarea)': this._bound.blurOrChange, + 'change:relay(input,select,textarea)': this._bound.blurOrChange + }); }, validationMonitor: function(){ @@ -11489,7 +12348,7 @@ Form.Validator = new Class({ if (warn != null) warn = false; if (this.hasValidator(field, 'warnOnly')) warn = true; var isValid = this.hasValidator(field, 'ignoreValidation') || (validator ? validator.test(field) : true); - if (validator && field.isVisible()) this.fireEvent('elementValidate', [isValid, field, className, warn]); + if (validator) this.fireEvent('elementValidate', [isValid, field, className, warn]); if (warn) return true; return isValid; }, @@ -11681,8 +12540,8 @@ Form.Validator.addAllThese([ }, test: function(element, props){ if (Form.Validator.getValidator('IsEmpty').test(element)) return true; - var dateLocale = Locale.getCurrent().sets.Date, - dateNouns = new RegExp([dateLocale.days, dateLocale.days_abbr, dateLocale.months, dateLocale.months_abbr].flatten().join('|'), 'i'), + var dateLocale = Locale.get('Date'), + dateNouns = new RegExp([dateLocale.days, dateLocale.days_abbr, dateLocale.months, dateLocale.months_abbr, dateLocale.AM, dateLocale.PM].flatten().join('|'), 'i'), value = element.get('value'), wordsInValue = value.match(/[a-z]+/gi); @@ -11691,7 +12550,6 @@ Form.Validator.addAllThese([ var date = Date.parse(value), format = props.dateFormat || '%x', formatted = date.format(format); - if (formatted != 'invalid date') element.set('value', formatted); return date.isValid(); } @@ -11871,7 +12729,7 @@ Form.Validator.Inline = new Class({ !field.retrieve('$moo:' + this.getPropName(className)) && ( advice.getStyle('display') == 'none' || - advice.getStyle('visiblity') == 'hidden' || + advice.getStyle('visibility') == 'hidden' || advice.getStyle('opacity') == 0 ) ){ @@ -12033,7 +12891,7 @@ Behavior.addGlobalFilter('FormValidator', { }); } api.onCleanup(function(){ - validator.disable(); + validator.stop(); }); return validator; } @@ -12053,6 +12911,7 @@ license: MIT-style license. authors: [Aaron Newton] requires: + - More/Fx.Reveal - More-Behaviors/Behavior.FormValidator provides: [Behavior.BS.FormValidator] @@ -12060,57 +12919,78 @@ provides: [Behavior.BS.FormValidator] ... */ -Behavior.addGlobalPlugin("FormValidator", "BS.FormValidator", { - setup: function(element, api, instance){ - var original = { - showError: instance.showError, - hideError: instance.hideError - }; - instance.setOptions({ - showError: function(){}, - hideError: function(){} - }); - instance.warningPrefix = ''; - instance.errorPrefix = ''; - instance.addEvents({ - showAdvice: function(field, advice, className){ - var inputParent = field.getParent('.input'), - clearfixParent = inputParent.getParent('.clearfix'); - if (!inputParent || !clearfixParent){ - original.showError(advice); - } else { - field.addClass('error'); - var help = inputParent.getElement('div.advice'); - if (!help){ - inputParent.getElements('span.help-inline').setStyle('display', 'none'); - help = new Element('span.help-inline.advice.auto-created', { - html: advice.get('html') - }).inject(inputParent); +(function(){ + + var getFieldDetails = function(field, advice, className){ + var cls = field.hasClass('warning') || field.hasClass('warn-' + className) ? 'warn' : 'error', + inputParent = field.getParent('.controls, .control-group'); + var clearfixParent; + if (inputParent){ + if (inputParent.hasClass('control-group')) clearfixParent = inputParent; + else clearfixParent = inputParent.getParent('.control-group'); + } + + return { + cls: cls, + inputParent: inputParent, + clearfixParent: clearfixParent + } + }; + + Behavior.addGlobalPlugin("FormValidator", "BS.FormValidator", { + setup: function(element, api, instance){ + var original = { + showError: instance.options.showError, + hideError: instance.options.hideError + }; + instance.setOptions({ + showError: function(){}, + hideError: function(){} + }); + instance.errorPrefix = ''; + instance.addEvents({ + showAdvice: function(field, advice, className){ + var fieldDetails = getFieldDetails(field, advice, className); + if (!fieldDetails.inputParent || !fieldDetails.clearfixParent){ + original.showError(advice); + } else { + field.addClass(fieldDetails.cls); + var help = fieldDetails.inputParent.getElement('div.advice'); + if (!help){ + fieldDetails.inputParent.getElements('span.help-inline').setStyle('display', 'none'); + var closestParent = field.getParent(); + help = new Element('span.help-inline.advice.auto-created', { + html: (field.hasClass('warning') ? 'Suggestion: ' : '') + advice.get('html') + }).hide().inject(closestParent.hasClass('input-append') ? closestParent : field, 'after'); + } + help.set('html', (field.hasClass('warning') ? 'Suggestion: ' : '') + advice.get('html')).reveal(); + help.removeClass('hide'); + help.set('title', advice.get('html')); + fieldDetails.clearfixParent.addClass(fieldDetails.cls); + } + }, + hideAdvice: function(field, advice, className){ + var fieldDetails = getFieldDetails(field, advice, className); + if (!fieldDetails.inputParent || !fieldDetails.clearfixParent){ + original.hideError(advice); + } else { + field.removeClass(fieldDetails.cls); + var help = fieldDetails.inputParent.getElement('.advice'); + fieldDetails.inputParent.getElements('.help-inline, .help-block').dissolve().getLast().get('reveal').chain(function(){ + if (help.hasClass('auto-created')) help.destroy(); + else help.set('html', ''); + }); + fieldDetails.clearfixParent.removeClass(fieldDetails.cls); } - help.removeClass('hide'); - help.set('title', advice.get('html')); - clearfixParent.addClass('error'); - } - }, - hideAdvice: function(field, advice, className){ - var inputParent = field.getParent('.input'), - clearfixParent = inputParent.getParent('.clearfix'); - if (!inputParent || !clearfixParent){ - original.hideError(advice); - } else { - field.removeClass('error'); - var help = inputParent.getElement('span.advice'); - if (help.hasClass('auto-created')) help.destroy(); - else help.set('html', ''); - inputParent.getElements('span.help-inline').setStyle('display', ''); - clearfixParent.removeClass('error'); } - } - }); - } -}); + }); + } + }); + +})(); -// Begin: Source/Behaviors/Behavior.BS.Twipsy.js + +// Begin: Source/Behaviors/Behavior.BS.Tooltip.js /* --- @@ -12172,6 +13052,83 @@ provides: [Behavior.BS.Twipsy, Behavior.BS.Tooltip] }); })(); +// Begin: Source/Utilities/Cookie.js +/* +--- + +name: Cookie + +description: Class for creating, reading, and deleting browser Cookies. + +license: MIT-style license. + +credits: + - Based on the functions by Peter-Paul Koch (http://quirksmode.org). + +requires: [Options, Browser] + +provides: Cookie + +... +*/ + +var Cookie = new Class({ + + Implements: Options, + + options: { + path: '/', + domain: false, + duration: false, + secure: false, + document: document, + encode: true + }, + + initialize: function(key, options){ + this.key = key; + this.setOptions(options); + }, + + write: function(value){ + if (this.options.encode) value = encodeURIComponent(value); + if (this.options.domain) value += '; domain=' + this.options.domain; + if (this.options.path) value += '; path=' + this.options.path; + if (this.options.duration){ + var date = new Date(); + date.setTime(date.getTime() + this.options.duration * 24 * 60 * 60 * 1000); + value += '; expires=' + date.toGMTString(); + } + if (this.options.secure) value += '; secure'; + this.options.document.cookie = this.key + '=' + value; + return this; + }, + + read: function(){ + var value = this.options.document.cookie.match('(?:^|;)\\s*' + this.key.escapeRegExp() + '=([^;]*)'); + return (value) ? decodeURIComponent(value[1]) : null; + }, + + dispose: function(){ + new Cookie(this.key, Object.merge({}, this.options, {duration: -1})).write(''); + return this; + } + +}); + +Cookie.write = function(key, value, options){ + return new Cookie(key, options).write(value); +}; + +Cookie.read = function(key){ + return new Cookie(key).read(); +}; + +Cookie.dispose = function(key, options){ + return new Cookie(key, options).dispose(); +}; + + // Begin: Source/Layout/TabSwapper.js /* --- @@ -12182,7 +13139,7 @@ description: Handles the scripting for a common UI layout; the tabbed box. license: MIT-Style License -requires: [Core/Element.Event, Core/Fx.Tween, Core/Fx.Morph, Core/Element.Dimensions, More/Element.Shortcuts, More/Element.Measure] +requires: [Core/Element.Event, Core/Fx.Tween, Core/Fx.Morph, Core/Element.Dimensions, Core/Cookie, More/Element.Shortcuts, More/Element.Measure] provides: TabSwapper @@ -12382,13 +13339,155 @@ var TabSwapper = new Class({ }); +// Begin: Source/3rdParty/MooHashChange.js +/* +--- +name: MooHashChange + +description: Added the onhashchange event + +license: MIT-style + +authors: +- sdf1981cgn +- Greggory Hernandez + +requires: +- Core/Element.Event + +provides: [Element.Events.hashchange] + +... +*/ +Element.Events.hashchange = { + onAdd: function () { + var hash = location.hash; + + var hashchange = function () { + if (hash == location.hash) return; + else hash = location.hash; + + var value = (hash.indexOf('#') == 0 ? hash.substr(1) : hash); + window.fireEvent('hashchange', value); + document.fireEvent('hashchange', value); + }; + + if (("onhashchange" in window) && ((document.documentMode != 5) && (document.documentMode != 7))) { + window.onhashchange = hashchange; + } + else { + hashchange.periodical(50); + } + } +}; + +// Begin: Source/Layout/TabSwapper.Hash.js +/* +--- + +name: TabSwapper.Hash + +description: Stores tab selection in the window.hash + +license: MIT-Style License + +requires: [/TabSwapper, More/String.QueryString, More/Object.Extras, /Element.Events.hashchange] + +provides: TabSwapper.Hash + +... +*/ + +var getHash = function(){ + return window.location.hash.substring(1, window.location.hash.length).parseQueryString(); +}; + +TabSwapper.Hash = new Class({ + Extends: TabSwapper, + options: { + hash: null // the hash value to store the state in + }, + initialize: function(options){ + this.setOptions(options); + // delete the hash option on startup so that the call to show(0) doesn't change the location hash + hash = this.options.hash; + if (hash){ + delete options.hash; + delete this.options.hash; + options.preventDefault = true; + } + this.parent(options); + if (hash){ + // put the hash back + this.options.hash = hash; + this.bound = { + showByHash: this.showByHash.bind(this) + }; + // watch hashchange for changes + window.addEvent('hashchange', this.bound.showByHash); + this.showByHash(); + } + }, + // shows a section based on the window location hash value + showByHash: function(){ + var i = this.getIndexByHash(); + if (i || i===0) this.show(i); + return this; + }, + // gets the index to show based on an elementID + // returns NULL if nothing is found + getIndexById: function(id){ + var target = document.id(id); + if (target && this.tabs.contains(target)) return this.tabs.indexOf(target); + else if (target && this.sections.contains(target)) return this.sections.indexOf(target); + return null; + }, + // gets the hash value and returns the index to be shown + // returns UNDEFINED if there was no hash value + // returns NULL if no element was found and the value wasn't an int already + // NOTE: hash value may be an int or a string; int if the tab/section had no id + getIndexByHash: function(){ + var hash = getHash(); + if (!hash) return this; + var value = hash[this.options.hash]; + if (value && isNaN(value.toInt())){ + var i = this.getIndexById(value); + if (i !== null) value = i; + else return null; + } + return value; + }, + // for optimization purposes, we store the sections, the base class doesn't do this + addTab: function(tab, section, clicker, index){ + this.parent.apply(this, arguments); + this.sections[this.tabs.indexOf(tab)] = section; + }, + // on show, update the hash + show: function(i){ + this.parent.apply(this, arguments); + if (this.options.hash) { + var hash = getHash() || {}; + hash[this.options.hash] = this.tabs[i].get('id') || this.sections[i].get('id') || i; + window.location.hash = Object.cleanValues(Object.toQueryString(hash)); + } + }, + destroy: function(){ + if (this.bound) window.removeEvent('hashchange', this.bound.showByHash); + this.tabs.each(function(el){ + el.removeEvents(); + }); + this.tabs = null; + this.sections = null; + } +}); + // Begin: Source/Behaviors/Behavior.Tabs.js /* --- name: Behavior.Tabs description: Adds a tab interface (TabSwapper instance) for elements with .css-tab_ui. Matched with tab elements that are .tabs and sections that are .tab_sections. provides: [Behavior.Tabs] -requires: [Behavior/Behavior, /TabSwapper, More/String.QueryString, More/Object.Extras] +requires: [Behavior/Behavior, /TabSwapper.Hash] script: Behavior.Tabs.js ... @@ -12411,19 +13510,18 @@ Behavior.addGlobalFilters({ if (tabs.length != sections.length || tabs.length == 0) { api.fail('warning; sections and sections are not of equal number. tabs: ' + tabs.length + ', sections: ' + sections.length); } - var getHash = function(){ - return window.location.hash.substring(1, window.location.hash.length).parseQueryString(); - }; - var ts = new TabSwapper( + var ts = new TabSwapper.Hash( Object.merge( { tabs: tabs, - sections: sections, - initPanel: api.get('hash') ? getHash()[api.get('hash')] : null + sections: sections }, Object.cleanValues( api.getAs({ + initPanel: Number, + hash: String, + cookieName: String, smooth: Boolean, smoothSize: Boolean, rearrangeDOM: Boolean, @@ -12435,20 +13533,42 @@ Behavior.addGlobalFilters({ ) ); ts.addEvent('active', function(index){ - if (api.get('hash')) { - var hash = getHash(); - hash[api.get('hash')] = index; - window.location.hash = Object.cleanValues(Object.toQueryString(hash)); - } api.fireEvent('layout:display', sections[0].getParent()); }); + + // get the element to delegate clicks to - defaults to the container + var target = element; + if (api.get('delegationTarget')) target = element.getElement(api.get('delegationTarget')); + if (!target) api.fail('Could not find delegation target for tabs'); + + // delegate watching click events for any element with an #href + target.addEvent('click:relay([href^=#])', function(event, link){ + if (link.get('href') == "#") return; + // attempt to find the target for the link within the page + var target = element.getElement(link.get('href')); + // if the target IS a tab, do nothing; valid targets are *sections* + if (ts.tabs.contains(target)) return; + // if no target was found at all, warn + if (!target) api.warn('Could not switch tab; no section found for ' + link.get('href')); + // if the target is a section, show it. + if (ts.sections.contains(target)) { + event.preventDefault(); + var delegator = api.getDelegator(); + if (delegator) delegator._eventHandler(event, ts.tabs[ts.sections.indexOf(target)]); + ts.show(ts.sections.indexOf(target)); + } + }); + element.store('TabSwapper', ts); + api.onCleanup(function(){ + ts.destroy(); + element.eliminate('TabSwapper'); + }); return ts; } } }); - // Begin: Source/Behaviors/Behavior.BS.Tabs.js /* --- @@ -12471,12 +13591,15 @@ provides: [Behavior.BS.Tabs] */ (function(){ + // start with the base options from the tabs behavior var tabs = Object.clone(Behavior.getFilter('Tabs')); + // customizing it here for Bootstrap, we start by duplicationg the other behavior Behavior.addGlobalFilters({ 'BS.Tabs': tabs.config }); + // set custom defaults specific to bootstrap Behavior.setFilterDefaults('BS.Tabs', { 'tabs-selector': 'a:not(.dropdown-toggle)', 'sections-selector': '+.tab-content >', @@ -12485,6 +13608,147 @@ provides: [Behavior.BS.Tabs] smoothSize: false }); + // this plugin configures tabswapper to use bootstrap specific DOM structures + Behavior.addGlobalPlugin('BS.Tabs', 'BS.Tabs.CSS', function(el, api, instance){ + // whenever the tabswapper activates a tab + instance.addEvent('active', function(index, section, tab){ + // get the things in the tabs element that are active and remove that class + el.getElements('.active').removeClass('active'); + // get the parent LI for the tab and add active to it + tab.getParent('li').addClass('active'); + // handle the possibility of a dropdown in the tab. + var dropdown = tab.getParent('.dropdown'); + if (dropdown) dropdown.addClass('active'); + }); + // invoke the event for startup + var now = instance.now; + var tab = instance.tabs[now]; + var section = tab.retrieve('section'); + instance.fireEvent('active', [now, section, tab]); + + }); + + // this plugin makes links that have #href targets select their target tabs + Behavior.addGlobalPlugin('BS.Tabs', 'BS.Tabs.TargetLinks', function(el, api, instance){ + // whenever the instance activates a tab, find any related #href links and add `active-section-link` to the appropriate ones + instance.addEvent('active', function(index, section, tab){ + document.body.getElements('.active-section-link').removeClass('active-section-link'); + // if there's a "group controller" go select it. + if (tab.get('data-tab-group')) { + document.id(tab.get('data-tab-group')).addClass('active-section-link'); + } + }); + + // invoke the event for startup + var now = instance.now; + var tab = instance.tabs[now]; + var section = tab.retrieve('section'); + instance.fireEvent('active', [now, section, tab]); + + }); + +})(); + +// Begin: Source/Delegators/Delegator.FxReveal.js +/* +--- +description: Provides methods to reveal, dissolve, nix, and toggle using Fx.Reveal. +provides: [Delegator.FxReveal, Delegator.Reveal, Delegator.ToggleReveal, Delegator.Dissolve, Delegator.Nix] +requires: [Behavior/Delegator, More/Fx.Reveal] +script: Delegator.FxReveal.js +name: Delegator.FxReveal + +... +*/ +(function(){ + + var triggers = {}; + + ['reveal', 'toggleReveal', 'dissolve', 'nix'].each(function(action){ + + triggers[action] = { + handler: function(event, link, api){ + var targets; + if (api.get('target')){ + targets = new Elements([link.getElement(api.get('target'))]); + if (!targets) api.fail('could not locate target element to ' + action, link); + } else if (api.get('targets')){ + targets = link.getElements(api.get('targets')); + if (!targets.length) api.fail('could not locate target elements to ' + action, link); + } else { + targets = new Elements([link]); + } + + var fxOptions = api.getAs(Object, 'fxOptions'); + if (fxOptions){ + targets.each(function(target){ + target.get('reveal').setOptions(fxOptions); + }); + } + if (action == 'toggleReveal') targets.get('reveal').invoke('toggle'); + else targets[action](); + if (!api.getAs(Boolean, 'allowEvent')) event.preventDefault(); + } + }; + + }); + + Delegator.register('click', triggers); + })(); +// Begin: Source/Behaviors/Behavior.BS.Alert.js +/* +--- + +name: Behavior.BS.Alert + +description: This file just depends on the Fx.Reveal delegator in More-Behaviors to ensure you get it if you load the entire Bootstrap JS package. + +license: MIT-style license. + +authors: [Aaron Newton] + +requires: + - More-Behaviors/Delegator.Nix + +provides: [Behavior.BS.Alert] + +... +*/ + +// Begin: Source/Delegators/Delegator.AddRemoveClass.js +/* +--- +description: Provides methods to add/remove/toggle a class on a given target. +provides: [Delegator.ToggleClass, Delegator.AddClass, Delegator.RemoveClass, Delegator.AddRemoveClass] +requires: [Behavior/Delegator, Core/Element] +script: Delegator.AddRemoveClass.js +name: Delegator.AddRemoveClass + +... +*/ +(function(){ + + var triggers = {}; + + ['add', 'remove', 'toggle'].each(function(action){ + + triggers[action + 'Class'] = { + require: ['class'], + handler: function(event, link, api){ + var target = link; + + if (api.get('target')) target = api.getElements('target') + else if (api.get('targets')) target = api.getElements('targets'); + + target[action + 'Class'](api.get('class')); + } + }; + + }); + + Delegator.register('click', triggers); + +})(); diff --git a/Examples/index_files/docs.css b/Examples/index_files/docs.css index 81021c3..c4551cd 100644 --- a/Examples/index_files/docs.css +++ b/Examples/index_files/docs.css @@ -1,772 +1,1084 @@ -/* Add additional stylesheets below --------------------------------------------------- */ /* - Bootstrap's documentation styles - Special styles for presenting Bootstrap's documentation and examples -*/ + * Bootstrap Documentation + * Special styles for presenting Bootstrap's documentation and code examples. + * + * Table of contents: + * + * Scaffolding + * Main navigation + * Footer + * Social buttons + * Homepage + * Page headers + * Old docs callout + * Ads + * Side navigation + * Docs sections + * Callouts + * Grid styles + * Examples + * Code snippets (highlight) + * Responsive tests + * Glyphicons + * Customizer + * Miscellaneous + */ -/* Body and structure --------------------------------------------------- */ +/* + * Scaffolding + * + * Update the basics of our documents to prep for docs content. + */ + body { - position: relative; - padding-top: 90px; - background-color: #fff; - background-image: url(http://twitter.github.com/bootstrap/assets/img/grid-18px-masked.png); - background-repeat: repeat-x; - background-position: 0 40px; + position: relative; /* For scrollyspy */ + padding-top: 50px; /* Account for fixed navbar */ } - -/* Tweak navbar brand link to be super sleek --------------------------------------------------- */ -.navbar-fixed-top .brand { - padding-right: 0; - padding-left: 0; - margin-left: 20px; - float: right; - font-weight: bold; - color: #000; - text-shadow: 0 1px 0 rgba(255,255,255,.1), 0 0 30px rgba(255,255,255,.125); - -webkit-transition: all .2s linear; - -moz-transition: all .2s linear; - transition: all .2s linear; -} -.navbar-fixed-top .brand:hover { - text-decoration: none; +/* Keep code small in tables on account of limited space */ +.table code { + font-size: 13px; + font-weight: normal; } - -/* Space out sub-sections more --------------------------------------------------- */ -section { - padding-top: 60px; +/* Outline button for use within the docs */ +.btn-outline { + color: #563d7c; + background-color: #fff; + border-color: #e5e5e5; +} +.btn-outline:hover, +.btn-outline:focus, +.btn-outline:active { + color: #fff; + background-color: #563d7c; + border-color: #563d7c; +} + +/* Inverted outline button (white on dark) */ +.btn-outline-inverse { + color: #fff; + background-color: transparent; + border-color: #cdbfe3; +} +.btn-outline-inverse:hover, +.btn-outline-inverse:focus, +.btn-outline-inverse:active { + color: #563d7c; + text-shadow: none; + background-color: #fff; + border-color: #fff; } -/* Faded out hr */ -hr.soften { - height: 1px; - margin: 54px 0; - background-image: -webkit-linear-gradient(left, rgba(0,0,0,0), rgba(0,0,0,.1), rgba(0,0,0,0)); - background-image: -moz-linear-gradient(left, rgba(0,0,0,0), rgba(0,0,0,.1), rgba(0,0,0,0)); - background-image: -ms-linear-gradient(left, rgba(0,0,0,0), rgba(0,0,0,.1), rgba(0,0,0,0)); - background-image: -o-linear-gradient(left, rgba(0,0,0,0), rgba(0,0,0,.1), rgba(0,0,0,0)); - border: 0; -} +/* + * Main navigation + * + * Turn the `.navbar` at the top of the docs purple. + */ -/* Jumbotrons --------------------------------------------------- */ -.jumbotron { - position: relative; +.bs-docs-nav { + text-shadow: 0 -1px 0 rgba(0,0,0,.15); + background-color: #563d7c; + border-color: #463265; + box-shadow: 0 1px 0 rgba(255,255,255,.1); } -.jumbotron h1 { - margin-bottom: 9px; - font-size: 81px; - letter-spacing: -1px; - line-height: 1; +.bs-docs-nav .navbar-collapse { + border-color: #463265; } -.jumbotron p { - margin-bottom: 18px; - font-weight: 300; +.bs-docs-nav .navbar-brand { + color: #fff; } -.jumbotron .btn-large { - font-size: 20px; - font-weight: normal; - padding: 14px 24px; - margin-right: 10px; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; +.bs-docs-nav .navbar-nav > li > a { + color: #cdbfe3; } - -/* Masthead (docs home) */ -.masthead { - padding-top: 36px; - margin-bottom: 72px; +.bs-docs-nav .navbar-nav > li > a:hover { + color: #fff; } -.masthead h1, -.masthead p { - text-align: center; +.bs-docs-nav .navbar-nav > .active > a, +.bs-docs-nav .navbar-nav > .active > a:hover { + color: #fff; + background-color: #463265; } -.masthead h1 { - margin-bottom: 18px; -} -.masthead p { - margin-left: 5%; - margin-right: 5%; - font-size: 30px; - line-height: 36px; -} - - -/* Specific jumbotrons -------------------------- */ -/* supporting docs pages */ -.subhead { - padding-bottom: 0; - margin-bottom: 9px; -} -.subhead h1 { - font-size: 54px; -} - -/* Subnav */ -.subnav { - width: 100%; - height: 36px; - background-color: #eeeeee; /* Old browsers */ - background-repeat: repeat-x; /* Repeat the gradient */ - background-image: -moz-linear-gradient(top, #f5f5f5 0%, #eeeeee 100%); /* FF3.6+ */ - background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#f5f5f5), color-stop(100%,#eeeeee)); /* Chrome,Safari4+ */ - background-image: -webkit-linear-gradient(top, #f5f5f5 0%,#eeeeee 100%); /* Chrome 10+,Safari 5.1+ */ - background-image: -ms-linear-gradient(top, #f5f5f5 0%,#eeeeee 100%); /* IE10+ */ - background-image: -o-linear-gradient(top, #f5f5f5 0%,#eeeeee 100%); /* Opera 11.10+ */ - filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f5f5f5', endColorstr='#eeeeee',GradientType=0 ); /* IE6-9 */ - background-image: linear-gradient(top, #f5f5f5 0%,#eeeeee 100%); /* W3C */ - border: 1px solid #e5e5e5; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} -.subnav .nav { - margin-bottom: 0; +.bs-docs-nav .navbar-toggle { + border-color: #563d7c; } -.subnav .nav > li > a { - margin: 0; - padding-top: 11px; - padding-bottom: 11px; - border-left: 1px solid #f5f5f5; - border-right: 1px solid #e5e5e5; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} -.subnav .nav > .active > a, -.subnav .nav > .active > a:hover { - padding-left: 13px; - color: #777; - background-color: #e9e9e9; - border-right-color: #ddd; - border-left: 0; - -webkit-box-shadow: inset 0 3px 5px rgba(0,0,0,.05); - -moz-box-shadow: inset 0 3px 5px rgba(0,0,0,.05); - box-shadow: inset 0 3px 5px rgba(0,0,0,.05); -} -.subnav .nav > .active > a .caret, -.subnav .nav > .active > a:hover .caret { - border-top-color: #777; -} -.subnav .nav > li:first-child > a, -.subnav .nav > li:first-child > a:hover { - border-left: 0; - padding-left: 12px; - -webkit-border-radius: 4px 0 0 4px; - -moz-border-radius: 4px 0 0 4px; - border-radius: 4px 0 0 4px; -} -.subnav .nav > li:last-child > a { - border-right: 0; -} -.subnav .dropdown-menu { - -webkit-border-radius: 0 0 4px 4px; - -moz-border-radius: 0 0 4px 4px; - border-radius: 0 0 4px 4px; -} - -/* Fixed subnav on scroll, but only for 980px and up (sorry IE!) */ -@media (min-width: 980px) { - .subnav-fixed { - position: fixed; - top: 40px; - left: 0; - right: 0; - z-index: 1020; /* 10 less than .navbar-fixed to prevent any overlap */ - border-color: #d5d5d5; - border-width: 0 0 1px; /* drop the border on the fixed edges */ - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; - -webkit-box-shadow: inset 0 1px 0 #fff, 0 1px 5px rgba(0,0,0,.1); - -moz-box-shadow: inset 0 1px 0 #fff, 0 1px 5px rgba(0,0,0,.1); - box-shadow: inset 0 1px 0 #fff, 0 1px 5px rgba(0,0,0,.1); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); /* IE6-9 */ - } - .subnav-fixed .nav { - width: 938px; - margin: 0 auto; - padding: 0 1px; - } - .subnav .nav > li:first-child > a, - .subnav .nav > li:first-child > a:hover { - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; - } +.bs-docs-nav .navbar-toggle:hover { + background-color: #463265; + border-color: #463265; } -/* Quick links --------------------------------------------------- */ -.quick-links { - min-height: 30px; - padding: 5px 20px; - margin: 36px 0; - list-style: none; +/* + * Footer + * + * Separated section of content at the bottom of all pages, save the homepage. + */ + +.bs-footer { + padding-top: 40px; + padding-bottom: 30px; + margin-top: 100px; + color: #777; text-align: center; - overflow: hidden; + border-top: 1px solid #e5e5e5; +} +.footer-links { + margin: 10px 0; + padding-left: 0; } -.quick-links li { +.footer-links li { display: inline; - margin: 0 5px; - color: #999; + padding: 0 2px; } -.quick-links .github-btn, -.quick-links .tweet-btn, -.quick-links .follow-btn { - position: relative; - top: 5px; +.footer-links li:first-child { + padding-left: 0; } - -/* Marketing section of Overview --------------------------------------------------- */ -.marketing .row { - margin-bottom: 9px; +@media (min-width: 768px) { + .bs-footer { + text-align: left; + } + .bs-footer p { + margin-bottom: 0; + } } -.marketing h1 { - margin: 36px 0 27px; - font-size: 40px; - font-weight: 300; + + +/* + * Social buttons + * + * Twitter and GitHub social action buttons (for homepage and footer). + */ + +.bs-social { + margin-top: 20px; + margin-bottom: 20px; text-align: center; } -.marketing h2, -.marketing h3 { - font-weight: 300; +.bs-social-buttons { + display: inline-block; + margin-bottom: 0; + padding-left: 0; + list-style: none; } -.marketing h2 { - font-size: 22px; +.bs-social-buttons li { + display: inline-block; + line-height: 1; + padding: 5px 8px; } -.marketing p { - margin-right: 10px; +.bs-social-buttons .twitter-follow-button { + width: 225px !important; } -.marketing .bs-icon { - float: left; - margin: 7px 10px 0 0; - opacity: .8; +.bs-social-buttons .twitter-share-button { + width: 98px !important; } -.marketing .small-bs-icon { - float: left; - margin: 4px 5px 0 0; +/* Style the GitHub buttons via CSS instead of inline attributes */ +.github-btn { + border: 0; + overflow: hidden; } +@media screen and (min-width: 768px) { + .bs-social { + text-align: left; + } + .bs-social-buttons li:first-child { + padding-left: 0; + } +} -/* Footer --------------------------------------------------- */ -.footer { - margin-top: 45px; - padding: 35px 0 36px; - border-top: 1px solid #e5e5e5; -} -.footer p { - margin-bottom: 0; - color: #555; +/* + * Topography, yo! + * + * Apply the map background via base64 and relevant colors where we need 'em. + */ + +.bs-docs-home, +.bs-header { + color: #cdbfe3; + background-color: #563d7c; + background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA+gAAAPoAgMAAAAwzTx3AAAACVBMVEVXPX1dQ4FdRIIPRg84AACjV0lEQVR4AZyZQa7cOg5FDwMTCDLSQJ738C2DS+DA3k/QK8n4r7KBR1zAtF2NHzFVfoaN6+iI4hULpoeDBaA/uogBA0jYYYeTirPuZ2mRTkrFBPC6l2CBBRuQlKYpLXUhIQH2MwFgcImpw1jguMXUcCFQWH1JjcZSFGCJJex1FtJJWSFqEWFgsIHpOlflrqMeaMkeCFRB6pALHLdI2D5KQrPpcICd5wHs4mYqSRV9ylNIeH1dA0So2ZNOgrK3o9t+f7wHWCxw0CNgfpDo5g4HHvgJfqC0T8HM/jzFREwHsMEGQwO0aGt5Rxc1OdmuKkwPNpY4uE3j+CRR6WHBgR0AnsLVesD77Cv8soalGWiAWRBKuhSaHAsd2qrSrGCscHQJbxIVp9xpr0OxBP79Mc1KG8a4rX077QRIGBqAqLVE5aAHkDDFSN6LfaJZYYWjhSNJuyUJldRkV2bg0GfCLPpXdJJi1xMTZIrgF3SXNStBwq2j96d7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iJUwQWOqg2RF1KsH9EcMRzk7Q1dTujJ5r/T2bteGXQqy9A742Ues1p+O/oaB+qZ2/N19NQzepJjhr5zqWwDucRkm4nVTiuVq5pHr3pB/8aw9DPRqeElDkRkYDQRdscHv8GZ50EDevtG/2TuS/T0vWnqCJghQH7ceDP0kUK/cFEFHaE1jqbWMbVz8ZkqiQ1dLmlAz4H383WFnc2/EtWL7vMUTXTXZTU69xs9VcJE72KJf5vjfwF77wcpLxPbrwAAAABJRU5ErkJggg==); } +/* + * Homepage + * + * Tweaks to the custom homepage and the masthead (main jumbotron). + */ -/* Special grid styles --------------------------------------------------- */ -.show-grid { - margin-top: 10px; - margin-bottom: 20px; -} -.show-grid [class*="span"] { - background-color: #eee; + /* Masthead (headings and download button) */ + .bs-masthead { + position: relative; + padding: 30px 15px; text-align: center; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; - min-height: 30px; - line-height: 30px; + text-shadow: 0 1px 0 rgba(0,0,0,.15); } -.show-grid:hover [class*="span"] { - background: #ddd; -} -.show-grid .show-grid { - margin-top: 0; - margin-bottom: 0; +.bs-masthead h1 { + font-size: 50px; + line-height: 1; + color: #fff; } -.show-grid .show-grid [class*="span"] { - background-color: #ccc; +.bs-masthead .btn-outline { + margin-top: 20px; + margin-bottom: 20px; + padding: 18px 24px; + font-size: 21px; } - -/* Render mini layout previews --------------------------------------------------- */ -.mini-layout { - border: 1px solid #ddd; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; - -webkit-box-shadow: 0 1px 2px rgba(0,0,0,.075); - -moz-box-shadow: 0 1px 2px rgba(0,0,0,.075); - box-shadow: 0 1px 2px rgba(0,0,0,.075); -} -.mini-layout { - height: 240px; +/* Links to project-level content like the repo, Expo, etc */ +.bs-masthead-links { + margin-top: 20px; margin-bottom: 20px; - padding: 9px; -} -.mini-layout div { - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; -} -.mini-layout .mini-layout-body { - background-color: #dceaf4; - margin: 0 auto; - width: 70%; - height: 240px; -} -.mini-layout.fluid .mini-layout-sidebar, -.mini-layout.fluid .mini-layout-header, -.mini-layout.fluid .mini-layout-body { - float: left; + padding: 0 15px; + list-style: none; + text-align: center; } -.mini-layout.fluid .mini-layout-sidebar { - background-color: #bbd8e9; - width: 20%; - height: 240px; +.bs-masthead-links li { + display: inline; } -.mini-layout.fluid .mini-layout-body { - width: 77.5%; - margin-left: 2.5%; +.bs-masthead-links li + li { + margin-left: 20px; +} +.bs-masthead-links a { + color: #fff; } +@media screen and (min-width: 768px) { + .bs-masthead { + text-align: left; + padding-top: 140px; + padding-bottom: 140px; + } + .bs-masthead h1 { + font-size: 100px; + } + .bs-masthead .lead { + margin-right: 25%; + font-size: 30px; + } + .bs-masthead-links { + padding: 0; + text-align: left; + } +} + + +/* + * Page headers + * + * Jumbotron-esque headers at the top of every page that's not the homepage. + */ + -/* Popover docs --------------------------------------------------- */ -.popover-well { - min-height: 160px; +/* Page headers */ +.bs-header { + padding: 30px 15px 40px; /* side padding builds on .container 15px, so 30px */ + font-size: 16px; + text-align: center; + text-shadow: 0 1px 0 rgba(0,0,0,.15); } -.popover-well .popover { - display: block; +.bs-header h1 { + color: #fff; } -.popover-well .popover-wrapper { - width: 50%; - height: 160px; - float: left; - margin-left: 55px; +.bs-header p { + font-weight: 300; + line-height: 1.5; +} +.bs-header .container { position: relative; } -.popover-well .popover-menu-wrapper { - height: 80px; + +@media screen and (min-width: 768px) { + .bs-header { + font-size: 21px; + text-align: left; + } + .bs-header h1 { + font-size: 60px; + line-height: 1; + } } -.large-bird { - margin: 5px 0 0 310px; - opacity: .1; + +@media screen and (min-width: 992px) { + .bs-header h1, + .bs-header p { + margin-right: 380px; + } } -/* Download page --------------------------------------------------- */ -.download .page-header { - margin-top: 36px; +/* + * Carbon ads + * + * Single display ad that shows on all pages (except homepage) in page headers. + * The hella `!important` is required for any pre-set property. + */ + +.carbonad { + width: auto !important; + margin: 50px -30px -40px !important; + padding: 20px !important; + overflow: hidden; /* clearfix */ + height: auto !important; + font-size: 13px !important; + line-height: 16px !important; + text-align: left; + background: #463265 !important; + border: 0 !important; + box-shadow: inset 0 3px 5px rgba(0,0,0,.075); +} +.carbonad-img { + margin: 0 !important; +} +.carbonad-text, +.carbonad-tag { + float: none !important; + display: block !important; + width: auto !important; + height: auto !important; + margin-left: 145px !important; + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif !important; +} +.carbonad-text { + padding-top: 0 !important; +} +.carbonad-tag { + color: #cdbfe3 !important; + text-align: left !important; +} +.carbonad-text a, +.carbonad-tag a { + color: #fff !important; +} +.carbonad #azcarbon > img { + display: none; /* hide what I assume are tracking images */ +} + +@media screen and (min-width: 768px) { + .carbonad { + margin: 0 !important; + border-radius: 4px; + box-shadow: inset 0 3px 5px rgba(0,0,0,.075), 0 1px 0 rgba(255,255,255,.1); + } } -.page-header .toggle-all { - margin-top: 5px; + +@media screen and (min-width: 992px) { + .carbonad { + position: absolute; + top: 20px; + right: 0; + padding: 15px !important; + width: 330px !important; + min-height: 132px; + } } -/* Space out h3s when following a section */ -.download h3 { - margin-bottom: 5px; + +/* + * Callout for 2.3.2 docs + * + * Only appears below page headers (not on the homepage). The homepage gets its + * own link with the masthead links. + */ + +.bs-old-docs { + padding: 15px 20px; + color: #777; + background-color: #fafafa; + border-top: 1px solid #fff; + border-bottom: 1px solid #e5e5e5; } -.download-builder input + h3, -.download-builder .checkbox + h3 { - margin-top: 9px; +.bs-old-docs strong { + color: #555; } -/* Fields for variables */ -.download-builder input[type=text] { - margin-bottom: 9px; - font-family: Menlo, Monaco, "Courier New", monospace; - font-size: 12px; - color: #d14; + +/* + * Side navigation + * + * Scrollspy and affixed enhanced navigation to highlight sections and secondary + * sections of docs content. + */ + +/* By default it's not affixed in mobile views, so undo that */ +.bs-sidebar.affix { + position: static; +} + +/* First level of nav */ +.bs-sidenav { + margin-top: 30px; + margin-bottom: 30px; + padding-top: 10px; + padding-bottom: 10px; + text-shadow: 0 1px 0 #fff; + background-color: #f7f5fa; + border-radius: 5px; +} + +/* All levels of nav */ +.bs-sidebar .nav > li > a { + display: block; + color: #716b7a; + padding: 5px 20px; } -.download-builder input[type=text]:focus { - background-color: #fff; +.bs-sidebar .nav > li > a:hover, +.bs-sidebar .nav > li > a:focus { + text-decoration: none; + background-color: #e5e3e9; + border-right: 1px solid #dbd8e0; +} +.bs-sidebar .nav > .active > a, +.bs-sidebar .nav > .active:hover > a, +.bs-sidebar .nav > .active:focus > a { + font-weight: bold; + color: #563d7c; + background-color: transparent; + border-right: 1px solid #563d7c; } -/* Custom, larger checkbox labels */ -.download .checkbox { - padding: 6px 10px 6px 25px; - color: #555; - background-color: #f9f9f9; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; - cursor: pointer; +/* Nav: second level (shown on .active) */ +.bs-sidebar .nav .nav { + display: none; /* Hide by default, but at >768px, show it */ + margin-bottom: 8px; } -.download .checkbox:hover { - color: #333; - background-color: #f5f5f5; +.bs-sidebar .nav .nav > li > a { + padding-top: 3px; + padding-bottom: 3px; + padding-left: 30px; + font-size: 90%; } -.download .checkbox small { - font-size: 12px; - color: #777; + +/* Show and affix the side nav when space allows it */ +@media screen and (min-width: 992px) { + .bs-sidebar .nav > .active > ul { + display: block; + } + /* Widen the fixed sidebar */ + .bs-sidebar.affix, + .bs-sidebar.affix-bottom { + width: 213px; + } + .bs-sidebar.affix { + position: fixed; /* Undo the static from mobile first approach */ + top: 80px; + } + .bs-sidebar.affix-bottom { + position: absolute; /* Undo the static from mobile first approach */ + } + .bs-sidebar.affix-bottom .bs-sidenav, + .bs-sidebar.affix .bs-sidenav { + margin-top: 0; + margin-bottom: 0; + } +} +@media screen and (min-width: 1200px) { + /* Widen the fixed sidebar again */ + .bs-sidebar.affix-bottom, + .bs-sidebar.affix { + width: 263px; + } } -/* Variables section */ -#variables label { - margin-bottom: 0; + +/* + * Docs sections + * + * Content blocks for each component or feature. + */ + +/* Space things out */ +.bs-docs-section + .bs-docs-section { + padding-top: 40px; } -/* Giant download button */ -.download-btn { - margin: 36px 0 108px; +/* Janky fix for preventing navbar from overlapping */ +h1[id] { + padding-top: 80px; + margin-top: -45px; } -.download p, -.download h4 { - max-width: 50%; - margin: 0 auto; - color: #999; - text-align: center; + + +/* + * Callouts + * + * Not quite alerts, but custom and helpful notes for folks reading the docs. + * Requires a base and modifier class. + */ + +/* Common styles for all types */ +.bs-callout { + margin: 20px 0; + padding: 15px 30px 15px 15px; + border-left: 5px solid #eee; +} +.bs-callout h4 { + margin-top: 0; } -.download h4 { +.bs-callout p:last-child { margin-bottom: 0; } -.download p { - margin-bottom: 18px; +.bs-callout code, +.bs-callout .highlight { + background-color: #fff; } -.download-btn .btn { - display: block; - width: auto; - padding: 19px 24px; - margin-bottom: 27px; - font-size: 30px; - line-height: 1; - text-align: center; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; + +/* Variations */ +.bs-callout-danger { + background-color: #fcf2f2; + border-color: #dFb5b4; +} +.bs-callout-warning { + background-color: #fefbed; + border-color: #f1e7bc; +} +.bs-callout-info { + background-color: #f0f7fd; + border-color: #d0e3f0; } +/* + * Grid examples + * + * Highlight the grid columns within the docs so folks can see their padding, + * alignment, sizing, etc. + */ -/* Color swatches on LESS docs page --------------------------------------------------- */ -/* Sets the width of the td */ -.swatch-col { - width: 30px; -} -/* Le swatch */ -.swatch { - display: inline-block; - width: 30px; - height: 20px; - margin: -6px 0; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; +.show-grid { + margin-bottom: 15px; } -/* For white swatches, give a border */ -.swatch-bordered { - width: 28px; - height: 18px; - border: 1px solid #eee; +.show-grid [class^="col-"] { + padding-top: 10px; + padding-bottom: 10px; + background-color: #eee; + border: 1px solid #ddd; + background-color: rgba(86,61,124,.15); + border: 1px solid rgba(86,61,124,.2); } -/* Misc --------------------------------------------------- */ +/* + * Examples + * + * Isolated sections of example content for each component or feature. Usually + * followed by a code snippet. + */ +.bs-example { + position: relative; + padding: 45px 15px 15px; + margin: 0 -15px 15px; + background-color: #fafafa; + box-shadow: inset 0 3px 6px rgba(0,0,0,.05); + border-color: #e5e5e5 #eee #eee; + border-style: solid; + border-width: 1px 0; +} +/* Echo out a label for the example */ +.bs-example:after { + content: "Example"; + position: absolute; + top: 15px; + left: 15px; + font-size: 12px; + font-weight: bold; + color: #bbb; + text-transform: uppercase; + letter-spacing: 1px; +} -.browser-support { - max-width: 100%; +/* Tweak display of the code snippets when following an example */ +.bs-example + .highlight { + margin: -15px -15px 15px; + border-radius: 0; + border-width: 0 0 1px; } -/* Make tables spaced out a bit more */ -h2 + table, -h3 + table, -h4 + table, -h2 + .row { - margin-top: 5px; +/* Make the examples and snippets not full-width */ +@media screen and (min-width: 768px) { + .bs-example { + margin-left: 0; + margin-right: 0; + background-color: #fff; + border-width: 1px; + border-color: #ddd; + border-radius: 4px 4px 0 0; + box-shadow: none; + } + .bs-example + .highlight { + margin-top: -16px; + margin-left: 0; + margin-right: 0; + border-width: 1px; + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; + } } -/* Example sites showcase */ -.example-sites img { - max-width: 100%; - margin: 0 auto; +/* Tweak content of examples for optimum awesome */ +.bs-example > p:last-child, +.bs-example > ul:last-child, +.bs-example > ol:last-child, +.bs-example > blockquote:last-child, +.bs-example > .form-control:last-child, +.bs-example > .table:last-child, +.bs-example > .navbar:last-child, +.bs-example > .jumbotron:last-child, +.bs-example > .alert:last-child, +.bs-example > .panel:last-child, +.bs-example > .list-group:last-child, +.bs-example > .well:last-child, +.bs-example > .progress:last-child, +.bs-example > .table-responsive:last-child > .table { + margin-bottom: 0; } -.marketing-byline { - margin: -18px 0 27px; - font-size: 18px; - font-weight: 300; - line-height: 24px; - color: #999; - text-align: center; +.bs-example > p > .close { + float: none; } -.scrollspy-example { - height: 200px; - overflow: auto; - position: relative; +/* Typography */ +.bs-example-type .table td:last-child { + color: #999; + vertical-align: middle; +} +.bs-example-type .table td { + padding: 15px 0; + border-color: #eee; +} +.bs-example-type .table tr:first-child td { + border-top: 0; +} +.bs-example-type h1, +.bs-example-type h2, +.bs-example-type h3, +.bs-example-type h4, +.bs-example-type h5, +.bs-example-type h6 { + margin: 0; } -/* Remove bottom margin on example forms in wells */ -form.well { - padding: 14px; +/* Images */ +.bs-example > .img-circle, +.bs-example > .img-rounded, +.bs-example > .img-thumbnail { + margin: 5px; } -/* Tighten up spacing */ -.well hr { - margin: 18px 0; +/* Buttons */ +.bs-example > .btn, +.bs-example > .btn-group { + margin-top: 5px; + margin-bottom: 5px; +} +.bs-example > .btn-toolbar + .btn-toolbar { + margin-top: 10px; } -/* Fake the :focus state to demo it */ -.focused { - border-color: rgba(82,168,236,.8); - -webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,.1), 0 0 8px rgba(82,168,236,.6); - -moz-box-shadow: inset 0 1px 3px rgba(0,0,0,.1), 0 0 8px rgba(82,168,236,.6); - box-shadow: inset 0 1px 3px rgba(0,0,0,.1), 0 0 8px rgba(82,168,236,.6); - outline: 0; +/* Forms */ +.bs-example-control-sizing select, +.bs-example-control-sizing input[type="text"] + input[type="text"] { + margin-top: 10px; +} +.bs-example-form .input-group { + margin-bottom: 10px; +} +.bs-example > textarea.form-control { + resize: vertical; } -/* For input sizes, make them display block */ -.docs-input-sizes select, -.docs-input-sizes input[type=text] { - display: block; - margin-bottom: 9px; +/* List groups */ +.bs-example > .list-group { + max-width: 400px; } -/* Icons -------------------------- */ -.the-icons { +/* Navbars */ +.bs-example .navbar:last-child { + margin-bottom: 0; +} +.bs-navbar-top-example, +.bs-navbar-bottom-example { + z-index: 1; + padding: 0; + overflow: hidden; /* cut the drop shadows off */ +} +.bs-navbar-top-example .navbar-header, +.bs-navbar-bottom-example .navbar-header { margin-left: 0; - list-style: none; } -.the-icons i:hover { - background-color: rgba(255,0,0,.25); +.bs-navbar-top-example .navbar-fixed-top, +.bs-navbar-bottom-example .navbar-fixed-bottom { + position: relative; + margin-left: 0; + margin-right: 0; } - -/* Eaxmples page -------------------------- */ -.bootstrap-examples .thumbnail { - margin-bottom: 9px; - background-color: #fff; +.bs-navbar-top-example { + padding-bottom: 45px; } - - -/* Responsive Docs --------------------------------------------------- */ -@media (max-width: 480px) { - - /* Reduce padding above jumbotron */ - body { - padding-top: 70px; +.bs-navbar-top-example:after { + top: auto; + bottom: 15px; +} +.bs-navbar-top-example .navbar-fixed-top { + top: -1px; +} +.bs-navbar-bottom-example { + padding-top: 45px; +} +.bs-navbar-bottom-example .navbar-fixed-bottom { + bottom: -1px; +} +.bs-navbar-bottom-example .navbar { + margin-bottom: 0; +} +@media (min-width: 768px) { + .bs-navbar-top-example .navbar-fixed-top, + .bs-navbar-bottom-example .navbar-fixed-bottom { + position: absolute; } - - /* Change up some type stuff */ - h2 { - margin-top: 27px; + .bs-navbar-top-example { + border-radius: 0 0 4px 4px; } - h2 small { - display: block; - line-height: 18px; - } - h3 { - margin-top: 18px; + .bs-navbar-bottom-example { + border-radius: 4px 4px 0 0; } +} - /* Adjust the jumbotron */ - .jumbotron h1, - .jumbotron p { - text-align: center; - margin-right: 0; - } - .jumbotron h1 { - font-size: 45px; - margin-right: 0; - } - .jumbotron p { - margin-right: 0; - margin-left: 0; - font-size: 18px; - line-height: 24px; - } - .jumbotron .btn { - display: block; - font-size: 18px; - padding: 10px 14px; - margin: 0 auto 10px; - } - /* Masthead (home page jumbotron) */ - .masthead { - padding-top: 0; - } +/* Pagination */ +.bs-example .pagination { + margin-top: 10px; + margin-bottom: 10px; +} - /* Don't space out quick links so much */ - .quick-links { - margin: 40px 0 0; - } - /* hide the bullets on mobile since our horizontal space is limited */ - .quick-links .divider { - display: none; - } +/* Pager */ +.bs-example > .pager { + margin-top: 0; +} - /* center example sites */ - .example-sites { - margin-left: 0; - } - .example-sites > li { - float: none; - display: block; - max-width: 280px; - margin: 0 auto 18px; - text-align: center; - } - .example-sites .thumbnail > img { - max-width: 270px; - } +/* Example modals */ +.bs-example-modal { + background-color: #f5f5f5; +} +.bs-example-modal .modal { + position: relative; + top: auto; + right: auto; + left: auto; + bottom: auto; + z-index: 1; + display: block; +} +.bs-example-modal .modal-dialog { + left: auto; + margin-left: auto; + margin-right: auto; +} - table code { - white-space: normal; - word-wrap: break-word; - word-break: break-all; - } +/* Example dropdowns */ +.bs-example > .dropdown > .dropdown-menu { + position: static; + display: block; + margin-bottom: 5px; +} - /* Modal example */ - .modal-example .modal { - position: relative; - top: auto; - right: auto; - bottom: auto; - left: auto; - } +/* Example tabbable tabs */ +.bs-example-tabs .nav-tabs { + margin-bottom: 15px; +} +/* Tooltips */ +.bs-example-tooltips { + text-align: center; +} +.bs-example-tooltips > .btn { + margin-top: 5px; + margin-bottom: 5px; } +/* Popovers */ +.bs-example-popover { + padding-bottom: 24px; + background-color: #f9f9f9; +} +.bs-example-popover .popover { + position: relative; + display: block; + float: left; + width: 260px; + margin: 20px; +} -@media (max-width: 768px) { +/* Scrollspy demo on fixed height div */ +.scrollspy-example { + position: relative; + height: 200px; + margin-top: 10px; + overflow: auto; +} - /* Remove any padding from the body */ - body { - padding-top: 0; - } - /* Jumbotron buttons */ - .jumbotron .btn { - margin-bottom: 10px; - } +/* + * Code snippets + * + * Generated via Pygments and Jekyll, these are snippets of HTML, CSS, and JS. + */ + +.highlight { + display: none; /* hidden by default, until >480px */ + padding: 9px 14px; + margin-bottom: 14px; + background-color: #f7f7f9; + border: 1px solid #e1e1e8; + border-radius: 4px; +} +.highlight pre { + padding: 0; + margin-top: 0; + margin-bottom: 0; + background-color: transparent; + border: 0; + white-space: nowrap; +} +.highlight pre code { + font-size: inherit; + color: #333; /* Effectively the base text color */ +} +.highlight pre .lineno { + display: inline-block; + width: 22px; + padding-right: 5px; + margin-right: 10px; + text-align: right; + color: #bebec5; +} - /* Subnav */ - .subnav { - position: static; - top: auto; - z-index: auto; - width: auto; - height: auto; - background: #fff; /* whole background property since we use a background-image for gradient */ - -webkit-box-shadow: none; - -moz-box-shadow: none; - box-shadow: none; - } - .subnav .nav > li { - float: none; - } - .subnav .nav > li > a { - border: 0; - } - .subnav .nav > li + li > a { - border-top: 1px solid #e5e5e5; - } - .subnav .nav > li:first-child > a, - .subnav .nav > li:first-child > a:hover { - -webkit-border-radius: 4px 4px 0 0; - -moz-border-radius: 4px 4px 0 0; - border-radius: 4px 4px 0 0; +/* Show code snippets when we have the space */ +@media screen and (min-width: 481px) { + .highlight { + display: block; } +} - /* Popovers */ - .large-bird { - display: none; - } - .popover-well .popover-wrapper { - margin-left: 0; - } - /* Space out the show-grid examples */ - .show-grid [class*="span"] { - margin-bottom: 5px; - } +/* + * Responsive tests + * + * Generate a set of tests to show the responsive utilities in action. + */ - /* Unfloat the back to top link in footer */ - .footer .pull-right { - float: none; - } - .footer p { - margin-bottom: 9px; - } +/* Responsive (scrollable) doc tables */ +.table-responsive .highlight pre { + white-space: normal; +} +/* Utility classes table */ +.bs-table th small, +.responsive-utilities th small { + display: block; + font-weight: normal; + color: #999; +} +.responsive-utilities tbody th { + font-weight: normal; +} +.responsive-utilities td { + text-align: center; +} +.responsive-utilities td.is-visible { + color: #468847; + background-color: #dff0d8 !important; +} +.responsive-utilities td.is-hidden { + color: #ccc; + background-color: #f9f9f9 !important; } +/* Responsive tests */ +.responsive-utilities-test { + margin-top: 5px; +} +.responsive-utilities-test .col-xs-6 { + margin-bottom: 10px; +} +.responsive-utilities-test span { + padding: 15px 10px; + font-size: 14px; + font-weight: bold; + line-height: 1.1; + text-align: center; + border-radius: 4px; +} +.visible-on .col-xs-6 .hidden-xs, +.visible-on .col-xs-6 .hidden-sm, +.visible-on .col-xs-6 .hidden-md, +.visible-on .col-xs-6 .hidden-lg, +.hidden-on .col-xs-6 .visible-xs, +.hidden-on .col-xs-6 .visible-sm, +.hidden-on .col-xs-6 .visible-md, +.hidden-on .col-xs-6 .visible-lg { + color: #999; + border: 1px solid #ddd; +} +.visible-on .col-xs-6 .visible-xs, +.visible-on .col-xs-6 .visible-sm, +.visible-on .col-xs-6 .visible-md, +.visible-on .col-xs-6 .visible-lg, +.hidden-on .col-xs-6 .hidden-xs, +.hidden-on .col-xs-6 .hidden-sm, +.hidden-on .col-xs-6 .hidden-md, +.hidden-on .col-xs-6 .hidden-lg { + color: #468847; + background-color: #dff0d8; + border: 1px solid #d6e9c6; +} -@media (min-width: 480px) and (max-width: 768px) { - /* Scale down the jumbotron content */ - .jumbotron h1 { - font-size: 54px; - } - .jumbotron p { - margin-right: 0; - margin-left: 0; - } +/* + * Glyphicons + * + * Special styles for displaying the icons and their classes in the docs. + */ +.bs-glyphicons { + padding-left: 0; + padding-bottom: 1px; + margin-bottom: 20px; + list-style: none; + overflow: hidden; +} +.bs-glyphicons li { + float: left; + width: 25%; + height: 115px; + padding: 10px; + margin: 0 -1px -1px 0; + font-size: 12px; + line-height: 1.4; + text-align: center; + border: 1px solid #ddd; +} +.bs-glyphicons .glyphicon { + display: block; + margin: 5px auto 10px; + font-size: 24px; +} +.bs-glyphicons li:hover { + background-color: rgba(86,61,124,.1); } - -@media (min-width: 768px) and (max-width: 980px) { - - /* Remove any padding from the body */ - body { - padding-top: 0; +@media (min-width: 768px) { + .bs-glyphicons li { + width: 12.5%; } +} - /* Scale down the jumbotron content */ - .jumbotron h1 { - font-size: 72px; - } +/* + * Customizer + * + * Since this is so form control heavy, we have quite a few styles to customize + * the display of inputs, headings, and more. Also included are all the download + * buttons and actions. + */ + +.bs-customizer .toggle { + float: right; + margin-top: 85px; /* On account of ghetto navbar fix */ } +/* Headings and form contrls */ +.bs-customizer label { + margin-top: 10px; + font-weight: 500; + color: #444; +} +.bs-customizer h2 { + margin-top: 0; + margin-bottom: 5px; + padding-top: 30px; +} +.bs-customizer h4 { + margin-top: 15px; +} +.bs-customizer input[type="text"] { + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; + background-color: #fafafa; +} +.bs-customizer .help-block { + font-size: 12px; +} -@media (max-width: 980px) { - - /* Unfloat brand */ - .navbar-fixed-top .brand { - float: left; - margin-left: 0; - padding-left: 10px; - padding-right: 10px; - } +/* For the variables, use regular weight */ +#less-section label { + font-weight: normal; +} - /* Inline-block quick links for more spacing */ - .quick-links li { - display: inline-block; - margin: 5px; - } +/* Downloads */ +.bs-customize-download .btn-outline { + padding: 20px; +} +/* Error handling */ +.bs-customizer-alert { + position: fixed; + top: 51px; + left: 0; + right: 0; + z-index: 1030; + padding: 15px 0; + color: #fff; + background-color: #d9534f; + box-shadow: inset 0 1px 0 rgba(255,255,255,.25); + border-bottom: 1px solid #b94441; +} +.bs-customizer-alert .close { + margin-top: -4px; + font-size: 24px; +} +.bs-customizer-alert p { + margin-bottom: 0; +} +.bs-customizer-alert .glyphicon { + margin-right: 5px; +} +.bs-customizer-alert pre { + margin: 10px 0 0; + color: #fff; + background-color: #a83c3a; + border-color: #973634; + box-shadow: inset 0 2px 4px rgba(0,0,0,.05), 0 1px 0 rgba(255,255,255,.1); } -/* LARGE DESKTOP SCREENS */ -@media (min-width: 1210px) { +/* + * Miscellaneous + * + * Odds and ends for optimum docs display. + */ - /* Update subnav container */ - .subnav-fixed .nav { - width: 1168px; /* 2px less to account for left/right borders being removed when in fixed mode */ - } +/* Examples gallery: space out content better */ +.bs-examples h4 { + margin-bottom: 5px; +} +.bs-examples p { + margin-bottom: 20px; +} -} \ No newline at end of file +/* Pseudo :focus state for showing how it looks in the docs */ +#focusedInput { + border-color: rgba(82,168,236,.8); + outline: 0; + outline: thin dotted \9; /* IE6-9 */ + -moz-box-shadow: 0 0 8px rgba(82,168,236,.6); + box-shadow: 0 0 8px rgba(82,168,236,.6); +} + +/* Better spacing on download options in getting started */ +.bs-docs-dl-options h4 { + margin-top: 15px; + margin-bottom: 5px; +} diff --git a/Examples/index_files/grid-18px.png b/Examples/index_files/grid-18px.png deleted file mode 100644 index 68f9fe1b70c40b25278613599bb593a0cb6acc0b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1118 zcmaJ=O=uHA6y8=^`a>>O0;Uv}tsscmosCJ;U7EIOw$-3pN*ZWdMBMI9nx);Hb$4o# z3RbNs9t0`atHC0A(O!BJ6|Gw9L82gNj~)twVh>*Q_zA-Ag+PZ~xWYVspGL7bOgdvfZuV7d; zS<|Vci6o56DHg}Gz`arxD9itc8b%H6-~`-@_n*Q}GH*dH0Ub1NtE6!0Zr7D1#%!oy zWG4}tt7dU5gD`S3$f9H8A(p3QMb%B$Qew!m7&jfPm@14*5r$~6x~_=;#KI)cVL=!f z;`w1P6bi)zDI5-mc!>ufP~}QUoj0I~t6Xi5+gq3GHiKai&l0rt^H3YHkwKR(E$a1S z3DwoBaJBle^wi~YBpA*u?O&y?nn?e+%Ua`-O|A8zN&4L;joozk!zOtY#kdqr=C;3m ze%^W&92kE8@`>lu;&t!t>e<$z25s9H(gupFxpN~7YEu;9%(span { - display:block; - height:23px; - padding:0 10px 0 8px; - line-height:23px; - background:url(/static/art/minibutton_matrix.png) 100% 0 no-repeat; -} -a.btn-no-txt>span { - padding: 0 15px 0 8px; - text-indent: -9999px; -} - -a.minibutton:hover, a.minibutton:focus, a.minibutton.selected { - color:#fff; - text-decoration:none; - text-shadow:-1px -1px 0 rgba(0,0,0,0.3); - background-position:0 -30px; -} -a.minibutton:hover>span, a.minibutton:focus>span, a.minibutton.selected>span {background-position:100% -30px;} - -a.minibutton.mousedown{background-position:0 -60px; } -a.minibutton.mousedown>span{background-position:100% -60px; } - -/* icons */ -a.minibutton .icon { - float:left; - margin-left:-4px; - width:18px; - height:22px; - background:url(/static/art/minibutton_icons.png) 0 0 no-repeat; -} - -a.btn-download .icon {background-position:-40px 0;} -a.btn-download:hover .icon, a.btn-download:focus .icon {background-position:-40px -25px;} - -a.btn-left .icon {background-position:-161px 1px;} -a.btn-left:hover .icon, a.btn-left:focus .icon {background-position:-161px -24px;} - -a.btn-right .icon {background-position:-178px 1px;} -a.btn-right:hover .icon, a.btn-right:focus .icon {background-position:-178px -24px;} - -a.btn-source .icon {background-position:-211px 0px;} -a.btn-source:hover .icon, a.btn-right:focus .icon {background-position:-211px -24px;} \ No newline at end of file diff --git a/Examples/index_files/reset.css b/Examples/index_files/reset.css new file mode 100644 index 0000000..d624875 --- /dev/null +++ b/Examples/index_files/reset.css @@ -0,0 +1,100 @@ +/* ----------------------------------------------------------------------- + + + Blueprint CSS Framework 0.9 + http://blueprintcss.org + + * Copyright (c) 2007-Present. See LICENSE for more info. + * See README for instructions on how to use Blueprint. + * For credits and origins, see AUTHORS. + * This is a compressed file. See the sources in the 'src' directory. + +----------------------------------------------------------------------- */ + +/* reset.css */ +html, body, div, span, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, code, del, dfn, em, img, q, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td, article, aside, dialog, figure, footer, header, hgroup, nav, section {margin:0;padding:0;border:0;font-weight:inherit;font-style:inherit;font-size:100%;font-family:inherit;vertical-align:baseline;} +article, aside, dialog, figure, footer, header, hgroup, nav, section {display:block;} +body {line-height:1.5;} +table {border-collapse:separate;border-spacing:0;} +caption, th, td {text-align:left;font-weight:normal;} +table, td, th {vertical-align:middle;} +blockquote:before, blockquote:after, q:before, q:after {content:"";} +blockquote, q {quotes:"" "";} +a img {border:none;} + +/* typography.css */ +html {font-size:100.01%;} +body {font-size:75%;color:#222;background:#fff;font-family:"Helvetica Neue", Arial, Helvetica, sans-serif;} +h1, h2, h3, h4, h5, h6 {font-weight:normal;color:#111;} +h1 {font-size:3em;line-height:1;margin-bottom:0.5em;} +h2 {font-size:2em;margin-bottom:0.75em;} +h3 {font-size:1.5em;line-height:1;margin-bottom:1em;} +h4 {font-size:1.2em;line-height:1.25;margin-bottom:1.25em;} +h5 {font-size:1em;font-weight:bold;margin-bottom:1.5em;} +h6 {font-size:1em;font-weight:bold;} +h1 img, h2 img, h3 img, h4 img, h5 img, h6 img {margin:0;} +p {margin:0 0 1.5em;} +p img.left {float:left;margin:1.5em 1.5em 1.5em 0;padding:0;} +p img.right {float:right;margin:1.5em 0 1.5em 1.5em;} +a:focus, a:hover {color:#000;} +a {color:#009;text-decoration:underline;} +blockquote {margin:1.5em;color:#666;font-style:italic;} +strong {font-weight:bold;} +em, dfn {font-style:italic;} +dfn {font-weight:bold;} +sup, sub {line-height:0;} +abbr, acronym {border-bottom:1px dotted #666;} +address {margin:0 0 1.5em;font-style:italic;} +del {color:#666;} +pre {margin:1.5em 0;white-space:pre;} +pre, code, tt {font:1em 'andale mono', 'lucida console', monospace;line-height:1.5;} +li ul, li ol {margin:0;} +ul, ol {margin:0 1.5em 1.5em 0;padding-left:3.333em;} +ul {list-style-type:disc;} +ol {list-style-type:decimal;} +dl {margin:0 0 1.5em 0;} +dl dt {font-weight:bold;} +dd {margin-left:1.5em;} +table {margin-bottom:1.4em;width:100%;} +th {font-weight:bold;} +thead th {background:#c3d9ff;} +th, td, caption {padding:4px 10px 4px 5px;} +tr.even td {background:#e5ecf9;} +tfoot {font-style:italic;} +caption {background:#eee;} +.small {font-size:.8em;margin-bottom:1.875em;line-height:1.875em;} +.large {font-size:1.2em;line-height:2.5em;margin-bottom:1.25em;} +.hide {display:none;} +.quiet {color:#666;} +.loud {color:#000;} +.highlight {background:#ff0;} +.added {background:#060;color:#fff;} +.removed {background:#900;color:#fff;} +.first {margin-left:0;padding-left:0;} +.last {margin-right:0;padding-right:0;} +.top {margin-top:0;padding-top:0;} +.bottom {margin-bottom:0;padding-bottom:0;} + +/* forms.css */ +fieldset {padding:1.4em;margin:0 0 1.5em 0;border:1px solid #ccc;} +legend {font-weight:bold;font-size:1.2em;} +input[type=text], input[type=password], input.text, input.title, textarea, select {background-color:#fff;border:1px solid #bbb;} +input[type=text]:focus, input[type=password]:focus, input.text:focus, input.title:focus, textarea:focus, select:focus {border-color:#666;} +input[type=text], input[type=password], input.text, input.title, textarea, select {margin:0.5em 0;} +input.text, input.title {width:300px;padding:5px;} +input.title {font-size:1.5em;} +textarea {width:390px;height:250px;padding:5px;} +/*input[type=checkbox], input[type=radio], input.checkbox, input.radio {position:relative;top:.25em;}*/ +form.inline {line-height:3;} +form.inline p {margin-bottom:0;} +.error, .notice, .success {padding:.8em;margin-bottom:1em;border:2px solid #ddd;} +.error {background:#FBE3E4;color:#8a1f11;border-color:#FBC2C4;} +.notice {background:#FFF6BF;color:#514721;border-color:#FFD324;} +.success {background:#E6EFC2;color:#264409;border-color:#C6D880;} +.error a {color:#8a1f11;} +.notice a {color:#514721;} +.success a {color:#264409;} + +.clearfix:after, .container:after {content:"\0020";display:block;height:0;clear:both;visibility:hidden;overflow:hidden;} +.clearfix, .container {display:block;} +.clear {clear:both;} \ No newline at end of file diff --git a/Examples/index_files/shared.css b/Examples/index_files/shared.css new file mode 100644 index 0000000..d1aede8 --- /dev/null +++ b/Examples/index_files/shared.css @@ -0,0 +1,13 @@ +body { + height: 100%; + position: absolute; + top: 0px; left: 0px; right: 0px; bottom: 0px; + font-family: "Lucida Grande", "Lucida Sans Unicode", "Trebuchet MS", Helvetica, Arial, sans-serif; + margin: 0px; + padding: 0px; + font-size: 12px; +} +a { + cursor: pointer; + color:#009; +} diff --git a/Examples/index_files/tests.css b/Examples/index_files/tests.css new file mode 100644 index 0000000..c7beb23 --- /dev/null +++ b/Examples/index_files/tests.css @@ -0,0 +1,168 @@ +body { + padding: 12px; +} +#mt-loading { + position: fixed; + bottom: 10px; + right: 10px; + padding: 8px; + width: 120px; + text-align: center; + background: #ccc; + border-radius: 4px; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + border: 1px solid #333; + box-shadow: 2px 2px 2px #888; + -moz-box-shadow: 2px 2px 2px #888; + -webkit-box-shadow: 2px 2px 2px #888; +} +body.loaded #mt-loading { + display: none; +} + +h3.h3_test { + border-bottom: 1px solid #999; + font-weight: bold; + font-size: 14px; + margin-top: 8px; +} +p { + margin-bottom: 4px; +} +#actions { + width: 400px; + position: relative; + z-index: 1000; + background: #fff; + padding: 4px 0px; +} +#actions dt { + font-weight: bold; + margin: 8px; +} +#actions dt a { + text-decoration: none; + display: block; + background: #AABCF2; + border-radius: 4px; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + padding: 4px; +} +#actions dt a:hover { + background: #CACEE8; +} +#actions dd { + padding: 0px 4px; + margin: 0px 8px; + position: relative; + top: -8px; +} +#mt-log-wrapper { + position: fixed; + width: 100%; + bottom: 0px; + height: 100px; +} +#mt-log { + height: 100px; + overflow: auto; +} +.view_source #mt-nav { + min-height: 30px; + height: 30px; +} +.view_source .source { + padding: 20px +} +.view_source .highlight { + padding: 8px; + overflow: auto; + max-height: 400px; + border: 1px solid #666; + margin-bottom: 20px; +} + +.view_source h2, .view_source h3 { + margin-bottom: 4px; +} +.view_source ul li { + list-style: none; +} +.view_source ul { + padding: 0; + margin: 0 0 20px 0; +} +.view_source .totop { + font-size: 10px; + float: right; + position: relative; + top: 4px; +} + +/* + * Styles from Pygments + */ +.view_source .highlight .hll { background-color: #ffffcc } +.view_source .highlight { background: #f8f8f8; } +.view_source .highlight .c { color: #408080; font-style: italic } /* Comment */ +.view_source .highlight .err { border: 1px solid #FF0000 } /* Error */ +.view_source .highlight .k { color: #008000; font-weight: bold } /* Keyword */ +.view_source .highlight .o { color: #666666 } /* Operator */ +.view_source .highlight .cm { color: #408080; font-style: italic } /* Comment.Multiline */ +.view_source .highlight .cp { color: #BC7A00 } /* Comment.Preproc */ +.view_source .highlight .c1 { color: #408080; font-style: italic } /* Comment.Single */ +.view_source .highlight .cs { color: #408080; font-style: italic } /* Comment.Special */ +.view_source .highlight .gd { color: #A00000 } /* Generic.Deleted */ +.view_source .highlight .ge { font-style: italic } /* Generic.Emph */ +.view_source .highlight .gr { color: #FF0000 } /* Generic.Error */ +.view_source .highlight .gh { color: #000080; font-weight: bold } /* Generic.Heading */ +.view_source .highlight .gi { color: #00A000 } /* Generic.Inserted */ +.view_source .highlight .go { color: #808080 } /* Generic.Output */ +.view_source .highlight .gp { color: #000080; font-weight: bold } /* Generic.Prompt */ +.view_source .highlight .gs { font-weight: bold } /* Generic.Strong */ +.view_source .highlight .gu { color: #800080; font-weight: bold } /* Generic.Subheading */ +.view_source .highlight .gt { color: #0040D0 } /* Generic.Traceback */ +.view_source .highlight .kc { color: #008000; font-weight: bold } /* Keyword.Constant */ +.view_source .highlight .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */ +.view_source .highlight .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */ +.view_source .highlight .kp { color: #008000 } /* Keyword.Pseudo */ +.view_source .highlight .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */ +.view_source .highlight .kt { color: #B00040 } /* Keyword.Type */ +.view_source .highlight .m { color: #666666 } /* Literal.Number */ +.view_source .highlight .s { color: #BA2121 } /* Literal.String */ +.view_source .highlight .na { color: #7D9029 } /* Name.Attribute */ +.view_source .highlight .nb { color: #008000 } /* Name.Builtin */ +.view_source .highlight .nc { color: #0000FF; font-weight: bold } /* Name.Class */ +.view_source .highlight .no { color: #880000 } /* Name.Constant */ +.view_source .highlight .nd { color: #AA22FF } /* Name.Decorator */ +.view_source .highlight .ni { color: #999999; font-weight: bold } /* Name.Entity */ +.view_source .highlight .ne { color: #D2413A; font-weight: bold } /* Name.Exception */ +.view_source .highlight .nf { color: #0000FF } /* Name.Function */ +.view_source .highlight .nl { color: #A0A000 } /* Name.Label */ +.view_source .highlight .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */ +.view_source .highlight .nt { color: #008000; font-weight: bold } /* Name.Tag */ +.view_source .highlight .nv { color: #19177C } /* Name.Variable */ +.view_source .highlight .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */ +.view_source .highlight .w { color: #bbbbbb } /* Text.Whitespace */ +.view_source .highlight .mf { color: #666666 } /* Literal.Number.Float */ +.view_source .highlight .mh { color: #666666 } /* Literal.Number.Hex */ +.view_source .highlight .mi { color: #666666 } /* Literal.Number.Integer */ +.view_source .highlight .mo { color: #666666 } /* Literal.Number.Oct */ +.view_source .highlight .sb { color: #BA2121 } /* Literal.String.Backtick */ +.view_source .highlight .sc { color: #BA2121 } /* Literal.String.Char */ +.view_source .highlight .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */ +.view_source .highlight .s2 { color: #BA2121 } /* Literal.String.Double */ +.view_source .highlight .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */ +.view_source .highlight .sh { color: #BA2121 } /* Literal.String.Heredoc */ +.view_source .highlight .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */ +.view_source .highlight .sx { color: #008000 } /* Literal.String.Other */ +.view_source .highlight .sr { color: #BB6688 } /* Literal.String.Regex */ +.view_source .highlight .s1 { color: #BA2121 } /* Literal.String.Single */ +.view_source .highlight .ss { color: #19177C } /* Literal.String.Symbol */ +.view_source .highlight .bp { color: #008000 } /* Name.Builtin.Pseudo */ +.view_source .highlight .vc { color: #19177C } /* Name.Variable.Class */ +.view_source .highlight .vg { color: #19177C } /* Name.Variable.Global */ +.view_source .highlight .vi { color: #19177C } /* Name.Variable.Instance */ +.view_source .highlight .il { color: #666666 } /* Literal.Number.Integer.Long */ \ No newline at end of file diff --git a/Source/Behaviors/Behavior.BS.Affix.js b/Source/Behaviors/Behavior.BS.Affix.js new file mode 100644 index 0000000..39b882d --- /dev/null +++ b/Source/Behaviors/Behavior.BS.Affix.js @@ -0,0 +1,42 @@ +/* +--- + +name: Behavior.BS.Affix + +description: Markup invocation for Bootstrap.Affix class. + +license: MIT-style license. + +authors: [Aaron Newton] + +requires: + - Behavior/Behavior + - /Bootstrap.Affix + +provides: [Behavior.BS.Affix] + +... +*/ + +Behavior.addGlobalFilters({ + 'BS.Affix': { + + requires: ['top'], + + setup: function(el, api){ + var affix = new Bootstrap.Affix(el, + Object.cleanValues( + api.getAs({ + top: Number, + bottom: Number, + classNames: Object + }) + ) + ); + + api.onCleanup(affix.detach.bind(affix)); + + return affix; + } + } +}); \ No newline at end of file diff --git a/Source/Behaviors/Behavior.BS.Popover.js b/Source/Behaviors/Behavior.BS.Popover.js index 993cb55..88e14f7 100644 --- a/Source/Behaviors/Behavior.BS.Popover.js +++ b/Source/Behaviors/Behavior.BS.Popover.js @@ -30,7 +30,7 @@ Behavior.addGlobalFilters({ animate: true, delayIn: 200, delayOut: 0, - offset: 10, + offset: Bootstrap.version == 2 ? 10 : null, trigger: 'hover' //focus, manual }, delayUntil: 'mouseover,focus', @@ -48,6 +48,9 @@ Behavior.addGlobalFilters({ trigger: String }) ); + if (options.offset === undefined && (['above', 'left', 'top'].contains(options.location) || !options.location)){ + options.offset = -6; + } var getter = function(which){ if (api.get(which + 'Element')) { @@ -62,8 +65,9 @@ Behavior.addGlobalFilters({ options.getContent = getter.pass('content'); options.getTitle = getter.pass('title'); + var tip = new Bootstrap.Popover(el, options); - if (api.event) tip._enter(); + if (api.event && api.get('trigger') != 'click') tip._enter(); api.onCleanup(tip.destroy.bind(tip)); return tip; } diff --git a/Source/UI/Delegator.BS.ShowPopup.js b/Source/Behaviors/Delegator.BS.ShowPopup.js similarity index 74% rename from Source/UI/Delegator.BS.ShowPopup.js rename to Source/Behaviors/Delegator.BS.ShowPopup.js index 07fec4a..dab99d2 100644 --- a/Source/UI/Delegator.BS.ShowPopup.js +++ b/Source/Behaviors/Delegator.BS.ShowPopup.js @@ -24,11 +24,10 @@ provides: [Delegator.BS.ShowPopup] Delegator.register('click', 'BS.showPopup', { - require: ['target'], handler: function(event, link, api){ - var target = link.getElement(api.get('target')); + var target = api.get('target') ? link.getElement(api.get('target')) : document.id(link.get('href').split("#")[1]); event.preventDefault(); - if (!target) api.fail('Could not find target element to activate: ', api.get('target')); + if (!target) api.fail('Could not find target element to activate: ' + (api.get('target') || link.get('href'))); api.getBehavior().apply(target); target.getBehaviorResult('BS.Popup').show(); } diff --git a/Source/UI/Bootstrap.Affix.js b/Source/UI/Bootstrap.Affix.js new file mode 100644 index 0000000..feb19c6 --- /dev/null +++ b/Source/UI/Bootstrap.Affix.js @@ -0,0 +1,125 @@ +/* +--- + +name: Bootstrap.Affix + +description: A MooTools implementation of Affix from Bootstrap; allows you to peg an element to a fixed position after scrolling. + +authors: [Aaron Newton] + +license: MIT-style license. + +requires: + - Core/Element.Dimensions + - More/Object.Extras + - /Bootstrap + +provides: [Bootstrap.Affix] + +... +*/ + +Bootstrap.Affix = new Class({ + + Implements: [Options, Events], + + options: { + // onPin: function(){}, + // onUnPin: function(isBottom){}, + top: 0, + bottom: null, + classNames: { + top: "affix-top", + bottom: "affix-bottom", + affixed: "affix" + } + }, + + initialize: function(element, options){ + this.element = document.id(element); + this.setOptions(options); + this._reset(); + this.element.addClass(this.options.classNames.top); + this.attach(); + }, + + attach: function(){ + Bootstrap.Affix.register(this); + return this; + }, + + detach: function(){ + Bootstrap.Affix.drop(this); + return this; + }, + + pinned: false, + + pin: function(){ + this.pinned = true; + this._reset(); + this.element.addClass(this.options.classNames.affixed); + this.fireEvent('pin'); + return this; + }, + + unpin: function(isBottom){ + this._reset(); + this.element.addClass(this.options.classNames[isBottom ? 'bottom' : 'top']); + this.pinned = false; + this.fireEvent('unPin', [isBottom]); + return this; + }, + + _reset: function(){ + this.element.removeClass(this.options.classNames.affixed) + .removeClass(this.options.classNames.top) + .removeClass(this.options.classNames.bottom); + return this; + } + +}); + +Bootstrap.Affix.registered = []; + +Bootstrap.Affix.register = function(instance){ + if (!Bootstrap.Affix.attached) Bootstrap.Affix.attach(); + Bootstrap.Affix.registered.push(instance); + Bootstrap.Affix.onScroll(); +}; + +Bootstrap.Affix.drop = function(instance){ + Bootstrap.Affix.registered.erase(instance); + if (Bootstrap.Affix.registered.length == 0) Bootstrap.Affix.detach(); +}; + +Bootstrap.Affix.attach = function(){ + window.addEvent('scroll', Bootstrap.Affix.onScroll); + Bootstrap.Affix.attached = true; +}; + +Bootstrap.Affix.detach = function(){ + window.removeEvent('scroll', Bootstrap.Affix.onScroll); + Bootstrap.Affix.attached = false; +}; + +Bootstrap.Affix.onScroll = function(_y){ + var y = _y || window.getScroll().y, + inSize; + for (var i = 0; i < Bootstrap.Affix.registered.length; i++){ + var instance = Bootstrap.Affix.registered[i]; + var bottom = instance.options.bottom, + top = instance.options.top; + if (bottom && bottom < 0){ + if (winSize == null) winSize = window.getSize().y; + bottom = winSize + bottom; + } + + // if we've scrolled above the top line, unpin + if (y < top && instance.pinned) instance.unpin(); + // if we've scrolled past the bottom line, unpin + else if (bottom && bottom < y && y > top && instance.pinned) instance.unpin(true); + else if (y > top && (!bottom || (bottom && y < bottom)) && !instance.pinned) instance.pin(); + + } +}; \ No newline at end of file diff --git a/Source/UI/Bootstrap.Dropdown.js b/Source/UI/Bootstrap.Dropdown.js index 02c97e0..dfa7cf3 100644 --- a/Source/UI/Bootstrap.Dropdown.js +++ b/Source/UI/Bootstrap.Dropdown.js @@ -38,7 +38,7 @@ Bootstrap.Dropdown = new Class({ }, hideAll: function(){ - var els = this.element.getElements('.open').removeClass('open'); + var els = this.element.removeClass('open').getElements('.open').removeClass('open'); this.fireEvent('hide', els); return this; }, @@ -67,7 +67,7 @@ Bootstrap.Dropdown = new Class({ if (el.match('[data-toggle="dropdown"]') || el.getParent('[data-toggle="dropdown"] !')){ parent = el.getParent('.dropdown, .btn-group'); } -  // backwards compatibility + // backwards compatibility if (!parent) parent = el.match('.dropdown-toggle') ? el.getParent() : el.getParent('.dropdown-toggle !'); if (parent){ e.preventDefault(); diff --git a/Source/UI/Bootstrap.Popover.js b/Source/UI/Bootstrap.Popover.js index 297f99e..7c37bb4 100644 --- a/Source/UI/Bootstrap.Popover.js +++ b/Source/UI/Bootstrap.Popover.js @@ -23,7 +23,7 @@ Bootstrap.Popover = new Class({ options: { location: 'right', - offset: 10, + offset: Bootstrap.version == 2 ? 10 : 0, getTitle: function(el){ return el.get(this.options.title); }, diff --git a/Source/UI/Bootstrap.Popup.js b/Source/UI/Bootstrap.Popup.js index 39ff0e5..a8d4c21 100644 --- a/Source/UI/Bootstrap.Popup.js +++ b/Source/UI/Bootstrap.Popup.js @@ -51,8 +51,10 @@ Bootstrap.Popup = new Class({ this.bound = { hide: this.hide.bind(this), bodyClick: function(e){ - if (!this.element.contains(e.target)){ - this.hide(); + if (Bootstrap.version == 2){ + if (!this.element.contains(e.target)) this.hide(); + } else { + if (this.element == e.target) this.hide(); } }.bind(this), keyMonitor: function(e){ @@ -65,6 +67,12 @@ Bootstrap.Popup = new Class({ if (this.element.hasClass('fade')) this.element.removeClass('in'); this.show(); } + + if (Bootstrap.version > 2){ + if (this.options.closeOnClickOut){ + this.element.addEvent('click', this.bound.bodyClick); + } + } }, toElement: function(){ @@ -85,7 +93,7 @@ Bootstrap.Popup = new Class({ show: function(){ if (this.visible || this.animating) return; - this.element.addEvent('click:relay(.close, .dismiss)', this.bound.hide); + this.element.addEvent('click:relay(.close, .dismiss, [data-dismiss=modal])', this.bound.hide); if (this.options.closeOnEsc) document.addEvent('keyup', this.bound.keyMonitor); this._makeMask(); if (this._mask) this._mask.inject(document.body); @@ -142,7 +150,8 @@ Bootstrap.Popup = new Class({ if (event && clicked && clicked.hasClass('stopEvent')){ event.preventDefault(); } - document.id(document.body).removeEvent('click', this.bound.hide); + + if (Bootstrap.version == 2) document.id(document.body).removeEvent('click', this.bound.hide); document.removeEvent('keyup', this.bound.keyMonitor); this.element.removeEvent('click:relay(.close, .dismiss)', this.bound.hide); @@ -162,11 +171,11 @@ Bootstrap.Popup = new Class({ _makeMask: function(){ if (this.options.mask){ if (!this._mask){ - this._mask = new Element('div.modal-backdrop'); + this._mask = new Element('div.modal-backdrop.in'); if (this._checkAnimate()) this._mask.addClass('fade'); } } - if (this.options.closeOnClickOut){ + if (this.options.closeOnClickOut && Bootstrap.version == 2){ if (this._mask) this._mask.addEvent('click', this.bound.hide); else document.id(document.body).addEvent('click', this.bound.hide); } diff --git a/Source/UI/Bootstrap.Tooltip.js b/Source/UI/Bootstrap.Tooltip.js index 2dd7fc9..74fa72a 100644 --- a/Source/UI/Bootstrap.Tooltip.js +++ b/Source/UI/Bootstrap.Tooltip.js @@ -76,7 +76,9 @@ Bootstrap.Tooltip = Bootstrap.Twipsy = new Class({ offset.y = this.options.offset; } if (typeOf(this.options.offset) == "object") offset = this.options.offset; - this.tip.inject(document.body).show().position({ + if (this.element.getParent('.modal')) this.tip.inject(this.element, 'after'); + else this.tip.inject(document.body); + this.tip.show().position({ relativeTo: this.element, position: pos, edge: edge, @@ -104,6 +106,10 @@ Bootstrap.Tooltip = Bootstrap.Twipsy = new Class({ return this; }, + toggle: function(){ + return this[this.visible ? 'hide' : 'show'](); + }, + // PRIVATE METHODS _makeTip: function(){ @@ -132,7 +138,8 @@ Bootstrap.Tooltip = Bootstrap.Twipsy = new Class({ this.bound = { enter: this._enter.bind(this), leave: this._leave.bind(this), - complete: this._complete.bind(this) + complete: this._complete.bind(this), + toggle: this.toggle.bind(this) }; if (this.options.trigger == 'hover') { @@ -145,6 +152,10 @@ Bootstrap.Tooltip = Bootstrap.Twipsy = new Class({ focus: this.bound.enter, blur: this.bound.leave }); + } else if (this.options.trigger == 'click'){ + this.element[method]({ + click: this.bound.toggle + }); } }, diff --git a/Source/UI/Bootstrap.js b/Source/UI/Bootstrap.js index 1d253e8..c0e49b8 100644 --- a/Source/UI/Bootstrap.js +++ b/Source/UI/Bootstrap.js @@ -13,4 +13,6 @@ provides: [Bootstrap] ... */ -var Bootstrap = {}; \ No newline at end of file +var Bootstrap = { + version: 3 +}; \ No newline at end of file diff --git a/Tests/Interactive/Bootstrap.mako b/Tests/Interactive/Bootstrap.mako index d9ea413..a125dfd 100644 --- a/Tests/Interactive/Bootstrap.mako +++ b/Tests/Interactive/Bootstrap.mako @@ -1,917 +1,1374 @@ - - - - - - Bootstrap, from Twitter - - - - - - - - - - - - - - - - - - - - - - -