From 4ac9fa081a7c045f6a9f1cfc529d82423f485b2e Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Sun, 8 Dec 2013 09:55:49 +0100 Subject: Update to MediaWiki 1.22.0 --- resources/Resources.php | 220 +++- resources/Resources.php.orig | 968 ----------------- resources/jquery.chosen/LICENSE | 24 + resources/jquery.chosen/chosen-sprite.png | Bin 0 -> 646 bytes resources/jquery.chosen/chosen-sprite@2x.png | Bin 0 -> 871 bytes resources/jquery.chosen/chosen.css | 440 ++++++++ resources/jquery.chosen/chosen.jquery.js | 1103 ++++++++++++++++++++ resources/jquery.tipsy/images/tipsy.png | Bin 175 -> 133 bytes .../default/images/ui-bg_flat_0_aaaaaa_40x100.png | Bin 180 -> 87 bytes .../default/images/ui-bg_flat_75_ffffff_40x100.png | Bin 178 -> 87 bytes .../default/images/ui-bg_glass_55_fbf9ee_1x400.png | Bin 120 -> 115 bytes .../default/images/ui-bg_glass_65_ffffff_1x400.png | Bin 105 -> 99 bytes .../default/images/ui-bg_glass_75_dadada_1x400.png | Bin 111 -> 111 bytes .../ui-bg_highlight-soft_75_cccccc_1x100.png | Bin 101 -> 86 bytes .../default/images/ui-icons_222222_256x240.png | Bin 4369 -> 3702 bytes .../default/images/ui-icons_2e83ff_256x240.png | Bin 4369 -> 3702 bytes .../default/images/ui-icons_454545_256x240.png | Bin 4369 -> 3702 bytes .../default/images/ui-icons_888888_256x240.png | Bin 4369 -> 3702 bytes .../default/images/ui-icons_cd0a0a_256x240.png | Bin 4369 -> 3702 bytes .../vector/images/button-blue-hover-large.png | Bin 260 -> 0 bytes .../themes/vector/images/button-blue-hover.png | Bin 175 -> 0 bytes .../themes/vector/images/button-blue-large.png | Bin 265 -> 0 bytes .../jquery.ui/themes/vector/images/button-blue.png | Bin 175 -> 0 bytes .../themes/vector/images/button-disabled-blue.png | Bin 84 -> 0 bytes .../themes/vector/images/button-disabled-green.png | Bin 149 -> 0 bytes .../themes/vector/images/button-disabled-red.png | Bin 84 -> 0 bytes .../themes/vector/images/button-disabled.png | Bin 84 -> 0 bytes .../themes/vector/images/button-down-blue.png | Bin 130 -> 0 bytes .../themes/vector/images/button-down-green.png | Bin 141 -> 0 bytes .../themes/vector/images/button-down-red.png | Bin 130 -> 0 bytes .../jquery.ui/themes/vector/images/button-down.png | Bin 130 -> 0 bytes .../vector/images/button-green-hover-large.png | Bin 265 -> 0 bytes .../themes/vector/images/button-green-hover.png | Bin 175 -> 0 bytes .../themes/vector/images/button-green-large.png | Bin 265 -> 0 bytes .../themes/vector/images/button-green.png | Bin 175 -> 0 bytes .../vector/images/button-large-disabled-green.png | Bin 277 -> 0 bytes .../vector/images/button-large-off-green.png | Bin 282 -> 0 bytes .../themes/vector/images/button-off-blue.png | Bin 175 -> 0 bytes .../themes/vector/images/button-off-green.png | Bin 149 -> 0 bytes .../themes/vector/images/button-off-red.png | Bin 175 -> 0 bytes .../jquery.ui/themes/vector/images/button-off.png | Bin 152 -> 0 bytes .../vector/images/button-orange-hover-large.png | Bin 265 -> 0 bytes .../themes/vector/images/button-orange-hover.png | Bin 175 -> 0 bytes .../themes/vector/images/button-orange-large.png | Bin 265 -> 0 bytes .../themes/vector/images/button-orange.png | Bin 175 -> 0 bytes .../themes/vector/images/button-over-blue.png | Bin 175 -> 0 bytes .../themes/vector/images/button-over-green.png | Bin 149 -> 0 bytes .../themes/vector/images/button-over-red.png | Bin 174 -> 0 bytes .../jquery.ui/themes/vector/images/button-over.png | Bin 155 -> 0 bytes .../vector/images/button-red-hover-large.png | Bin 260 -> 0 bytes .../themes/vector/images/button-red-hover.png | Bin 175 -> 0 bytes .../themes/vector/images/button-red-large.png | Bin 265 -> 0 bytes .../jquery.ui/themes/vector/images/button-red.png | Bin 175 -> 0 bytes .../themes/vector/images/titlebar-fade.png | Bin 188 -> 81 bytes .../jquery.ui/themes/vector/jquery.ui.button.css | 368 ++++--- .../images/jquery.arrowSteps.divider-ltr.png | Bin 135 -> 126 bytes .../images/jquery.arrowSteps.divider-rtl.png | Bin 139 -> 127 bytes .../jquery/images/jquery.arrowSteps.head-ltr.png | Bin 390 -> 303 bytes .../jquery/images/jquery.arrowSteps.head-rtl.png | Bin 365 -> 311 bytes .../jquery/images/jquery.arrowSteps.tail-ltr.png | Bin 223 -> 222 bytes resources/jquery/images/marker.png | Bin 652 -> 472 bytes resources/jquery/images/mask.png | Bin 2020 -> 1795 bytes resources/jquery/jquery.badge.css | 9 +- resources/jquery/jquery.byteLength.js | 12 + resources/jquery/jquery.byteLimit.js | 3 +- resources/jquery/jquery.checkboxShiftClick.js | 16 +- resources/jquery/jquery.client.js | 100 +- resources/jquery/jquery.makeCollapsible.js | 231 ++-- resources/jquery/jquery.placeholder.js | 9 +- resources/jquery/jquery.spinner.css | 2 +- resources/jquery/jquery.spinner.js | 47 +- resources/jquery/jquery.suggestions.js | 4 +- resources/jquery/jquery.tablesorter.js | 180 +++- resources/jquery/jquery.textSelection.js | 4 +- .../mediawiki.action/images/green-checkmark.png | Bin 0 -> 681 bytes .../mediawiki.action.edit.collapsibleFooter.css | 17 + .../mediawiki.action.edit.collapsibleFooter.js | 54 + .../mediawiki.action.edit.editWarning.js | 56 + .../mediawiki.action/mediawiki.action.edit.js | 167 +-- .../mediawiki.action.edit.preview.js | 53 +- .../mediawiki.action.edit.styles.css | 44 + .../mediawiki.action/mediawiki.action.history.js | 2 +- .../mediawiki.action.view.postEdit.css | 77 ++ .../mediawiki.action.view.postEdit.js | 75 +- .../mediawiki.action.view.rightClickEdit.js | 4 +- resources/mediawiki.api/mediawiki.api.category.js | 35 +- resources/mediawiki.api/mediawiki.api.edit.js | 65 +- resources/mediawiki.api/mediawiki.api.js | 88 +- resources/mediawiki.api/mediawiki.api.login.js | 54 + resources/mediawiki.api/mediawiki.api.parse.js | 12 +- resources/mediawiki.api/mediawiki.api.watch.js | 12 +- resources/mediawiki.language/mediawiki.language.js | 23 + .../mediawiki.language.months.js | 54 + resources/mediawiki.less/mediawiki.mixins.less | 46 + .../mediawiki.libs/mediawiki.libs.jpegmeta.js | 2 +- resources/mediawiki.page/mediawiki.page.gallery.js | 248 +++++ .../mediawiki.page.image.pagination.js | 51 + .../mediawiki.page/mediawiki.page.patrol.ajax.js | 2 +- resources/mediawiki.page/mediawiki.page.ready.js | 38 +- resources/mediawiki.page/mediawiki.page.startup.js | 23 +- .../mediawiki.page/mediawiki.page.watch.ajax.js | 6 +- .../images/arrow-collapsed-ltr.png | Bin 206 -> 0 bytes .../images/arrow-collapsed-rtl.png | Bin 205 -> 0 bytes .../mediawiki.special/images/arrow-expanded.png | Bin 205 -> 0 bytes .../images/glyph-people-large.png | Bin 0 -> 1663 bytes .../mediawiki.special/images/icon-contributors.png | Bin 0 -> 1169 bytes resources/mediawiki.special/images/icon-edits.png | Bin 0 -> 780 bytes resources/mediawiki.special/images/icon-lock.png | Bin 0 -> 172 bytes resources/mediawiki.special/images/icon-pages.png | Bin 0 -> 528 bytes .../mediawiki.special/mediawiki.special.block.js | 2 +- .../mediawiki.special.changeemail.js | 2 +- .../mediawiki.special.changeslist.css | 57 - .../mediawiki.special.changeslist.enhanced.css | 66 ++ .../mediawiki.special.createAccount.css | 89 ++ .../mediawiki.special.createAccount.js | 112 ++ .../mediawiki.special.movePage.js | 2 +- .../mediawiki.special.pagesWithProp.css | 4 + .../mediawiki.special.preferences.js | 2 +- .../mediawiki.special.recentchanges.js | 2 +- .../mediawiki.special/mediawiki.special.search.js | 2 +- .../mediawiki.special.undelete.js | 2 +- .../mediawiki.special/mediawiki.special.upload.js | 4 +- .../mediawiki.special.userLogin.css | 39 + .../mediawiki.special.userLogin.signup.js | 10 - .../mediawiki.special/mediawiki.special.vforms.css | 46 + resources/mediawiki.ui/mediawiki.ui.default.css | 272 +++++ resources/mediawiki.ui/mediawiki.ui.vector.css | 414 ++++++++ resources/mediawiki.ui/sourcefiles/Makefile | 24 + resources/mediawiki.ui/sourcefiles/config.rb | 27 + .../sourcefiles/scss/components/_default.scss | 3 + .../sourcefiles/scss/components/_utilities.scss | 17 + .../sourcefiles/scss/components/_vector.scss | 4 + .../scss/components/default/_buttons.scss | 69 ++ .../scss/components/default/_forms.scss | 114 ++ .../scss/components/vector/_buttons.scss | 19 + .../scss/components/vector/_containers.scss | 5 + .../sourcefiles/scss/components/vector/_forms.scss | 7 + .../sourcefiles/scss/mediawiki.ui.default.scss | 16 + .../sourcefiles/scss/mediawiki.ui.vector.scss | 15 + .../mediawiki.ui/sourcefiles/scss/mixins/_all.scss | 4 + .../sourcefiles/scss/mixins/_effects.scss | 62 ++ .../sourcefiles/scss/mixins/_forms.scss | 66 ++ .../sourcefiles/scss/mixins/_type.scss | 6 + .../sourcefiles/scss/mixins/_utilities.scss | 19 + .../sourcefiles/scss/settings/_all.scss | 2 + .../sourcefiles/scss/settings/_colors.scss | 17 + .../sourcefiles/scss/settings/_typography.scss | 5 + resources/mediawiki/images/arrow-collapsed-ltr.png | Bin 0 -> 133 bytes resources/mediawiki/images/arrow-collapsed-rtl.png | Bin 0 -> 136 bytes resources/mediawiki/images/arrow-expanded.png | Bin 0 -> 134 bytes resources/mediawiki/mediawiki.Title.js | 574 +++++++--- resources/mediawiki/mediawiki.Uri.js | 4 +- resources/mediawiki/mediawiki.debug.js | 2 +- resources/mediawiki/mediawiki.htmlform.js | 70 +- resources/mediawiki/mediawiki.icon.css | 15 + resources/mediawiki/mediawiki.inspect.js | 204 ++++ resources/mediawiki/mediawiki.jqueryMsg.js | 335 +++++- resources/mediawiki/mediawiki.js | 496 ++++++--- resources/mediawiki/mediawiki.log.js | 65 +- resources/mediawiki/mediawiki.notification.css | 16 +- resources/mediawiki/mediawiki.notification.js | 25 +- resources/mediawiki/mediawiki.notify.js | 13 +- resources/mediawiki/mediawiki.searchSuggest.js | 48 +- resources/mediawiki/mediawiki.user.js | 253 +++-- resources/mediawiki/mediawiki.util.js | 204 ++-- resources/startup.js | 42 +- 166 files changed, 6697 insertions(+), 2345 deletions(-) delete mode 100644 resources/Resources.php.orig create mode 100644 resources/jquery.chosen/LICENSE create mode 100644 resources/jquery.chosen/chosen-sprite.png create mode 100644 resources/jquery.chosen/chosen-sprite@2x.png create mode 100644 resources/jquery.chosen/chosen.css create mode 100644 resources/jquery.chosen/chosen.jquery.js delete mode 100644 resources/jquery.ui/themes/vector/images/button-blue-hover-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-blue-hover.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-blue-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-blue.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-disabled-blue.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-disabled-green.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-disabled-red.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-disabled.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-down-blue.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-down-green.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-down-red.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-down.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-green-hover-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-green-hover.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-green-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-green.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-large-disabled-green.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-large-off-green.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-off-blue.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-off-green.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-off-red.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-off.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-orange-hover-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-orange-hover.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-orange-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-orange.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-over-blue.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-over-green.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-over-red.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-over.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-red-hover-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-red-hover.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-red-large.png delete mode 100644 resources/jquery.ui/themes/vector/images/button-red.png create mode 100644 resources/mediawiki.action/images/green-checkmark.png create mode 100644 resources/mediawiki.action/mediawiki.action.edit.collapsibleFooter.css create mode 100644 resources/mediawiki.action/mediawiki.action.edit.collapsibleFooter.js create mode 100644 resources/mediawiki.action/mediawiki.action.edit.editWarning.js create mode 100644 resources/mediawiki.action/mediawiki.action.edit.styles.css create mode 100644 resources/mediawiki.action/mediawiki.action.view.postEdit.css create mode 100644 resources/mediawiki.api/mediawiki.api.login.js create mode 100644 resources/mediawiki.language/mediawiki.language.months.js create mode 100644 resources/mediawiki.less/mediawiki.mixins.less create mode 100644 resources/mediawiki.page/mediawiki.page.gallery.js create mode 100644 resources/mediawiki.page/mediawiki.page.image.pagination.js delete mode 100644 resources/mediawiki.special/images/arrow-collapsed-ltr.png delete mode 100644 resources/mediawiki.special/images/arrow-collapsed-rtl.png delete mode 100644 resources/mediawiki.special/images/arrow-expanded.png create mode 100644 resources/mediawiki.special/images/glyph-people-large.png create mode 100644 resources/mediawiki.special/images/icon-contributors.png create mode 100644 resources/mediawiki.special/images/icon-edits.png create mode 100644 resources/mediawiki.special/images/icon-lock.png create mode 100644 resources/mediawiki.special/images/icon-pages.png create mode 100644 resources/mediawiki.special/mediawiki.special.changeslist.enhanced.css create mode 100644 resources/mediawiki.special/mediawiki.special.createAccount.css create mode 100644 resources/mediawiki.special/mediawiki.special.createAccount.js create mode 100644 resources/mediawiki.special/mediawiki.special.pagesWithProp.css create mode 100644 resources/mediawiki.special/mediawiki.special.userLogin.css delete mode 100644 resources/mediawiki.special/mediawiki.special.userLogin.signup.js create mode 100644 resources/mediawiki.special/mediawiki.special.vforms.css create mode 100644 resources/mediawiki.ui/mediawiki.ui.default.css create mode 100644 resources/mediawiki.ui/mediawiki.ui.vector.css create mode 100644 resources/mediawiki.ui/sourcefiles/Makefile create mode 100644 resources/mediawiki.ui/sourcefiles/config.rb create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/_default.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/_utilities.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/_vector.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/default/_buttons.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/default/_forms.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/vector/_buttons.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/vector/_containers.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/components/vector/_forms.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/mediawiki.ui.default.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/mediawiki.ui.vector.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/mixins/_all.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/mixins/_effects.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/mixins/_forms.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/mixins/_type.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/mixins/_utilities.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/settings/_all.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/settings/_colors.scss create mode 100644 resources/mediawiki.ui/sourcefiles/scss/settings/_typography.scss create mode 100644 resources/mediawiki/images/arrow-collapsed-ltr.png create mode 100644 resources/mediawiki/images/arrow-collapsed-rtl.png create mode 100644 resources/mediawiki/images/arrow-expanded.png create mode 100644 resources/mediawiki/mediawiki.icon.css create mode 100644 resources/mediawiki/mediawiki.inspect.js (limited to 'resources') diff --git a/resources/Resources.php b/resources/Resources.php index 6205bb91..06120008 100644 --- a/resources/Resources.php +++ b/resources/Resources.php @@ -20,7 +20,7 @@ * @file */ -if( !defined( 'MEDIAWIKI' ) ) { +if ( !defined( 'MEDIAWIKI' ) ) { die( 'Not an entry point.' ); } @@ -60,14 +60,11 @@ return array( * * See Vector for an example. */ - - 'skins.chick' => array( - 'styles' => array( 'chick/main.css' => array( 'media' => 'screen, handheld' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), 'skins.cologneblue' => array( - 'styles' => array( 'cologneblue/screen.css' => array( 'media' => 'screen' ) ), + 'styles' => array( + 'cologneblue/screen.css' => array( 'media' => 'screen' ), + 'cologneblue/print.css' => array( 'media' => 'print' ), + ), 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], ), @@ -102,37 +99,53 @@ return array( 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], ), - 'skins.nostalgia' => array( - 'styles' => array( 'nostalgia/screen.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.simple' => array( - 'styles' => array( 'simple/main.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.standard' => array( - 'styles' => array( 'standard/main.css' => array( 'media' => 'screen' ) ), + 'skins.vector' => array( + // Used in the web installer. Test it after modifying this definition! + 'styles' => array( + 'common/commonElements.css' => array( 'media' => 'screen' ), + 'common/commonContent.css' => array( 'media' => 'screen' ), + 'common/commonInterface.css' => array( 'media' => 'screen' ), + 'vector/styles.less', + ), 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], ), - 'skins.vector' => array( - // Keep in sync with WebInstallerOutput::getCSS() + 'skins.vector.beta' => array( + // Keep in sync with skins.vector 'styles' => array( 'common/commonElements.css' => array( 'media' => 'screen' ), 'common/commonContent.css' => array( 'media' => 'screen' ), 'common/commonInterface.css' => array( 'media' => 'screen' ), - 'vector/screen.css' => array( 'media' => 'screen' ), - 'vector/screen-hd.css' => array( 'media' => 'screen and (min-width: 982px)' ), + 'vector/styles-beta.less', ), 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], ), 'skins.vector.js' => array( - 'scripts' => 'vector/vector.js', + 'scripts' => array( + 'vector/collapsibleTabs.js', + 'vector/vector.js', + ), + 'position' => 'top', + 'dependencies' => 'jquery.delayedBind', + 'remoteBasePath' => $GLOBALS['wgStylePath'], + 'localBasePath' => $GLOBALS['wgStyleDirectory'], + ), + 'skins.vector.collapsibleNav' => array( + 'scripts' => array( + 'vector/collapsibleNav.js', + ), + 'messages' => array( + 'vector-collapsiblenav-more', + ), + 'dependencies' => array( + 'jquery.client', + 'jquery.cookie', + 'jquery.tabIndex', + ), 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], + 'position' => 'bottom', ), /* jQuery */ @@ -166,6 +179,7 @@ return array( ), 'jquery.byteLength' => array( 'scripts' => 'resources/jquery/jquery.byteLength.js', + 'targets' => array( 'desktop', 'mobile' ), ), 'jquery.byteLimit' => array( 'scripts' => 'resources/jquery/jquery.byteLimit.js', @@ -173,6 +187,11 @@ return array( ), 'jquery.checkboxShiftClick' => array( 'scripts' => 'resources/jquery/jquery.checkboxShiftClick.js', + 'targets' => array( 'desktop', 'mobile' ), + ), + 'jquery.chosen' => array( + 'scripts' => 'resources/jquery.chosen/chosen.jquery.js', + 'styles' => 'resources/jquery.chosen/chosen.css', ), 'jquery.client' => array( 'scripts' => 'resources/jquery/jquery.client.js', @@ -210,6 +229,7 @@ return array( ), 'jquery.getAttrs' => array( 'scripts' => 'resources/jquery/jquery.getAttrs.js', + 'targets' => array( 'desktop', 'mobile' ), ), 'jquery.hidpi' => array( 'scripts' => 'resources/jquery/jquery.hidpi.js', @@ -233,12 +253,14 @@ return array( 'scripts' => 'resources/jquery/jquery.makeCollapsible.js', 'styles' => 'resources/jquery/jquery.makeCollapsible.css', 'messages' => array( 'collapsible-expand', 'collapsible-collapse' ), + 'targets' => array( 'desktop', 'mobile' ), ), 'jquery.mockjax' => array( 'scripts' => 'resources/jquery/jquery.mockjax.js', ), 'jquery.mw-jump' => array( 'scripts' => 'resources/jquery/jquery.mw-jump.js', + 'targets' => array( 'desktop', 'mobile' ), ), 'jquery.mwExtension' => array( 'scripts' => 'resources/jquery/jquery.mwExtension.js', @@ -246,15 +268,18 @@ return array( ), 'jquery.placeholder' => array( 'scripts' => 'resources/jquery/jquery.placeholder.js', + 'targets' => array( 'desktop', 'mobile' ), ), 'jquery.qunit' => array( 'scripts' => 'resources/jquery/jquery.qunit.js', 'styles' => 'resources/jquery/jquery.qunit.css', 'position' => 'top', + 'targets' => array( 'desktop', 'mobile' ), ), 'jquery.qunit.completenessTest' => array( 'scripts' => 'resources/jquery/jquery.qunit.completenessTest.js', 'dependencies' => 'jquery.qunit', + 'targets' => array( 'desktop', 'mobile' ), ), 'jquery.spinner' => array( 'scripts' => 'resources/jquery/jquery.spinner.js', @@ -276,7 +301,10 @@ return array( 'scripts' => 'resources/jquery/jquery.tablesorter.js', 'styles' => 'resources/jquery/jquery.tablesorter.css', 'messages' => array( 'sort-descending', 'sort-ascending' ), - 'dependencies' => 'jquery.mwExtension', + 'dependencies' => array( + 'jquery.mwExtension', + 'mediawiki.language.months', + ), ), 'jquery.textSelection' => array( 'scripts' => 'resources/jquery/jquery.textSelection.js', @@ -605,6 +633,12 @@ return array( 'mediawiki.Title', ), ), + 'mediawiki.api.login' => array( + 'scripts' => 'resources/mediawiki.api/mediawiki.api.login.js', + 'dependencies' => array( + 'mediawiki.api', + ), + ), 'mediawiki.api.parse' => array( 'scripts' => 'resources/mediawiki.api/mediawiki.api.parse.js', 'dependencies' => 'mediawiki.api', @@ -616,6 +650,9 @@ return array( 'user.tokens', ), ), + 'mediawiki.icon' => array( + 'styles' => 'resources/mediawiki/mediawiki.icon.css', + ), 'mediawiki.debug' => array( 'scripts' => 'resources/mediawiki/mediawiki.debug.js', 'styles' => 'resources/mediawiki/mediawiki.debug.css', @@ -629,6 +666,14 @@ return array( // must be loaded on the bottom 'position' => 'bottom', ), + 'mediawiki.inspect' => array( + 'scripts' => 'resources/mediawiki/mediawiki.inspect.js', + 'dependencies' => array( + 'jquery.byteLength', + 'jquery.json', + ), + 'targets' => array( 'desktop', 'mobile' ), + ), 'mediawiki.feedback' => array( 'scripts' => 'resources/mediawiki/mediawiki.feedback.js', 'styles' => 'resources/mediawiki/mediawiki.feedback.css', @@ -663,6 +708,7 @@ return array( ), 'mediawiki.htmlform' => array( 'scripts' => 'resources/mediawiki/mediawiki.htmlform.js', + 'messages' => array( 'htmlform-chosen-placeholder' ), ), 'mediawiki.notification' => array( 'styles' => 'resources/mediawiki/mediawiki.notification.css', @@ -687,11 +733,15 @@ return array( 'jquery.client', 'jquery.placeholder', 'jquery.suggestions', + 'mediawiki.api', ), ), 'mediawiki.Title' => array( 'scripts' => 'resources/mediawiki/mediawiki.Title.js', - 'dependencies' => 'mediawiki.util', + 'dependencies' => array( + 'jquery.byteLength', + 'mediawiki.util', + ), ), 'mediawiki.Uri' => array( 'scripts' => 'resources/mediawiki/mediawiki.Uri.js', @@ -723,16 +773,30 @@ return array( 'mediawiki.action.edit' => array( 'scripts' => 'resources/mediawiki.action/mediawiki.action.edit.js', 'dependencies' => array( + 'mediawiki.action.edit.styles', 'jquery.textSelection', 'jquery.byteLimit', ), 'position' => 'top', ), + 'mediawiki.action.edit.styles' => array( + 'styles' => 'resources/mediawiki.action/mediawiki.action.edit.styles.css', + 'position' => 'top', + ), + 'mediawiki.action.edit.collapsibleFooter' => array( + 'scripts' => 'resources/mediawiki.action/mediawiki.action.edit.collapsibleFooter.js', + 'styles' => 'resources/mediawiki.action/mediawiki.action.edit.collapsibleFooter.css', + 'dependencies' => array( + 'jquery.makeCollapsible', + 'mediawiki.icon', + ), + ), 'mediawiki.action.edit.preview' => array( 'scripts' => 'resources/mediawiki.action/mediawiki.action.edit.preview.js', 'dependencies' => array( 'jquery.form', 'jquery.spinner', + 'mediawiki.action.history.diff', ), ), 'mediawiki.action.history' => array( @@ -759,11 +823,24 @@ return array( ), 'mediawiki.action.view.postEdit' => array( 'scripts' => 'resources/mediawiki.action/mediawiki.action.view.postEdit.js', - 'dependencies' => 'jquery.cookie' + 'styles' => 'resources/mediawiki.action/mediawiki.action.view.postEdit.css', + 'dependencies' => array( + 'jquery.cookie', + 'mediawiki.jqueryMsg' + ), + 'messages' => array( + 'postedit-confirmation', + ), ), 'mediawiki.action.view.rightClickEdit' => array( 'scripts' => 'resources/mediawiki.action/mediawiki.action.view.rightClickEdit.js', ), + 'mediawiki.action.edit.editWarning' => array( + 'scripts' => 'resources/mediawiki.action/mediawiki.action.edit.editWarning.js', + 'messages' => array( + 'editwarning-warning', + ), + ), // Alias for backwards compatibility 'mediawiki.action.watch.ajax' => array( 'dependencies' => 'mediawiki.page.watch.ajax' @@ -825,6 +902,16 @@ return array( 'targets' => array( 'desktop', 'mobile' ), ), + 'mediawiki.language.months' => array( + 'scripts' => 'resources/mediawiki.language/mediawiki.language.months.js', + 'dependencies' => 'mediawiki.language', + 'messages' => array_merge( + Language::$mMonthMsgs, + Language::$mMonthGenMsgs, + Language::$mMonthAbbrevMsgs + ) + ), + /* MediaWiki Libs */ 'mediawiki.libs.jpegmeta' => array( @@ -833,6 +920,9 @@ return array( /* MediaWiki Page */ + 'mediawiki.page.gallery' => array( + 'scripts' => 'resources/mediawiki.page/mediawiki.page.gallery.js', + ), 'mediawiki.page.ready' => array( 'scripts' => 'resources/mediawiki.page/mediawiki.page.ready.js', 'dependencies' => array( @@ -842,6 +932,7 @@ return array( 'jquery.mw-jump', 'mediawiki.util', ), + 'targets' => array( 'desktop', 'mobile' ), ), 'mediawiki.page.startup' => array( 'scripts' => 'resources/mediawiki.page/mediawiki.page.startup.js', @@ -850,6 +941,7 @@ return array( 'mediawiki.util', ), 'position' => 'top', + 'targets' => array( 'desktop', 'mobile' ), ), 'mediawiki.page.patrol.ajax' => array( 'scripts' => 'resources/mediawiki.page/mediawiki.page.patrol.ajax.js', @@ -887,6 +979,10 @@ return array( 'watcherrortext', ), ), + 'mediawiki.page.image.pagination' => array( + 'scripts' => 'resources/mediawiki.page/mediawiki.page.image.pagination.js', + 'dependencies' => array( 'jquery.spinner' ) + ), /* MediaWiki Special pages */ @@ -913,15 +1009,21 @@ return array( ), 'mediawiki.special.changeslist' => array( 'styles' => 'resources/mediawiki.special/mediawiki.special.changeslist.css', - 'dependencies' => array( 'jquery.makeCollapsible' ), + ), + 'mediawiki.special.changeslist.enhanced' => array( + 'styles' => 'resources/mediawiki.special/mediawiki.special.changeslist.enhanced.css', ), 'mediawiki.special.movePage' => array( 'scripts' => 'resources/mediawiki.special/mediawiki.special.movePage.js', 'dependencies' => 'jquery.byteLimit', ), + 'mediawiki.special.pagesWithProp' => array( + 'styles' => 'resources/mediawiki.special/mediawiki.special.pagesWithProp.css', + ), 'mediawiki.special.preferences' => array( 'scripts' => 'resources/mediawiki.special/mediawiki.special.preferences.js', - 'styles' => 'resources/mediawiki.special/mediawiki.special.preferences.css', + 'styles' => 'resources/mediawiki.special/mediawiki.special.preferences.css', + 'position' => 'top', ), 'mediawiki.special.recentchanges' => array( 'scripts' => 'resources/mediawiki.special/mediawiki.special.recentchanges.js', @@ -941,7 +1043,7 @@ return array( 'scripts' => 'resources/mediawiki.special/mediawiki.special.undelete.js', ), 'mediawiki.special.upload' => array( - // @TODO: merge in remainder of mediawiki.legacy.upload + // @todo merge in remainder of mediawiki.legacy.upload 'scripts' => 'resources/mediawiki.special/mediawiki.special.upload.js', 'messages' => array( 'widthheight', @@ -951,10 +1053,33 @@ return array( 'size-gigabytes', 'largefileserver', ), - 'dependencies' => array( 'mediawiki.libs.jpegmeta', 'mediawiki.util' ), + 'dependencies' => array( + 'mediawiki.libs.jpegmeta', + 'mediawiki.util', + ), + ), + 'mediawiki.special.userlogin' => array( + 'styles' => array( + 'resources/mediawiki.special/mediawiki.special.vforms.css', + 'resources/mediawiki.special/mediawiki.special.userLogin.css', + ), + 'position' => 'top', + ), + 'mediawiki.special.createaccount' => array( + 'styles' => array( + 'resources/mediawiki.special/mediawiki.special.vforms.css', + 'resources/mediawiki.special/mediawiki.special.createAccount.css', + ), ), - 'mediawiki.special.userlogin.signup' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.userLogin.signup.js', + 'mediawiki.special.createaccount.js' => array( + 'scripts' => 'resources/mediawiki.special/mediawiki.special.createAccount.js', + 'messages' => array( + 'createacct-captcha', + 'createacct-emailrequired', + 'createacct-imgcaptcha-ph' + ), + 'dependencies' => 'mediawiki.jqueryMsg', + 'position' => 'top', ), 'mediawiki.special.javaScriptTest' => array( 'scripts' => 'resources/mediawiki.special/mediawiki.special.javaScriptTest.js', @@ -964,6 +1089,7 @@ return array( ) ), 'dependencies' => array( 'jquery.qunit' ), 'position' => 'top', + 'targets' => array( 'desktop', 'mobile' ), ), /* MediaWiki Tests */ @@ -978,6 +1104,7 @@ return array( 'mediawiki.page.ready', ), 'position' => 'top', + 'targets' => array( 'desktop', 'mobile' ), ), /* MediaWiki Legacy */ @@ -998,14 +1125,9 @@ return array( 'localBasePath' => $GLOBALS['wgStyleDirectory'], ), 'mediawiki.legacy.config' => array( + // Used in the web installer. Test it after modifying this definition! 'scripts' => 'common/config.js', - 'styles' => array( 'common/config.css', 'common/config-cc.css' ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - 'dependencies' => 'mediawiki.legacy.wikibits', - ), - 'mediawiki.legacy.IEFixes' => array( - 'scripts' => 'common/IEFixes.js', + 'styles' => array( 'common/config.css' ), 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], 'dependencies' => 'mediawiki.legacy.wikibits', @@ -1015,12 +1137,12 @@ return array( 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], 'dependencies' => array( - 'mediawiki.legacy.wikibits', 'jquery.byteLimit', ), 'position' => 'top', ), 'mediawiki.legacy.shared' => array( + // Used in the web installer. Test it after modifying this definition! 'styles' => array( 'common/shared.css' => array( 'media' => 'screen' ) ), 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], @@ -1035,7 +1157,9 @@ return array( 'remoteBasePath' => $GLOBALS['wgStylePath'], 'localBasePath' => $GLOBALS['wgStyleDirectory'], 'dependencies' => array( - 'mediawiki.legacy.wikibits', + 'jquery.spinner', + 'mediawiki.api', + 'mediawiki.Title', 'mediawiki.util', ), ), @@ -1048,9 +1172,11 @@ return array( ), 'position' => 'top', ), - 'mediawiki.legacy.wikiprintable' => array( - 'styles' => array( 'common/wikiprintable.css' => array( 'media' => 'print' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], + 'mediawiki.ui' => array( + 'skinStyles' => array( + 'default' => 'resources/mediawiki.ui/mediawiki.ui.default.css', + 'vector' => 'resources/mediawiki.ui/mediawiki.ui.vector.css', + ), + 'position' => 'top', ), ); diff --git a/resources/Resources.php.orig b/resources/Resources.php.orig deleted file mode 100644 index 0a70c5a2..00000000 --- a/resources/Resources.php.orig +++ /dev/null @@ -1,968 +0,0 @@ - array( 'class' => 'ResourceLoaderSiteModule' ), - 'noscript' => array( 'class' => 'ResourceLoaderNoscriptModule' ), - 'startup' => array( 'class' => 'ResourceLoaderStartUpModule' ), - 'filepage' => array( 'class' => 'ResourceLoaderFilePageModule' ), - 'user.groups' => array( 'class' => 'ResourceLoaderUserGroupsModule' ), - - // Scripts managed by the current user (stored in their user space) - 'user' => array( 'class' => 'ResourceLoaderUserModule' ), - - // Scripts generated based on the current user's preferences - 'user.cssprefs' => array( 'class' => 'ResourceLoaderUserCSSPrefsModule' ), - - // Populate mediawiki.user placeholders with information about the current user - 'user.options' => array( 'class' => 'ResourceLoaderUserOptionsModule' ), - 'user.tokens' => array( 'class' => 'ResourceLoaderUserTokensModule' ), - - // Scripts for the dynamic language specific data, like grammar forms. - 'mediawiki.language.data' => array( 'class' => 'ResourceLoaderLanguageDataModule' ), - - /* Skins */ - - 'skins.chick' => array( - 'styles' => array( 'chick/main.css' => array( 'media' => 'screen, handheld' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.cologneblue' => array( - 'styles' => array( 'cologneblue/screen.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.modern' => array( - 'styles' => array( - 'modern/main.css' => array( 'media' => 'screen' ), - 'modern/print.css' => array( 'media' => 'print' ), - ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.monobook' => array( - 'styles' => array( - 'common/commonElements.css' => array( 'media' => 'screen' ), - 'common/commonContent.css' => array( 'media' => 'screen' ), - 'common/commonInterface.css' => array( 'media' => 'screen' ), - 'monobook/main.css' => array( 'media' => 'screen' ), - ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.archlinux' => array( - 'styles' => array( - 'common/commonElements.css' => array( 'media' => 'screen' ), - 'common/commonContent.css' => array( 'media' => 'screen' ), - 'common/commonInterface.css' => array( 'media' => 'screen' ), - 'archlinux/main.css' => array( 'media' => 'screen' ), - 'archlinux/archnavbar.css' => array( 'media' => 'screen' ), - 'archlinux/arch.css' => array( 'media' => 'screen' ), - 'archlinux/print.css' => array( 'media' => 'print' ), - ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.nostalgia' => array( - 'styles' => array( 'nostalgia/screen.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.simple' => array( - 'styles' => array( 'simple/main.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.standard' => array( - 'styles' => array( 'standard/main.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'skins.vector' => array( - // Keep in sync with WebInstallerOutput::getCSS() - 'styles' => array( - 'common/commonElements.css' => array( 'media' => 'screen' ), - 'common/commonContent.css' => array( 'media' => 'screen' ), - 'common/commonInterface.css' => array( 'media' => 'screen' ), - 'vector/screen.css' => array( 'media' => 'screen' ), - 'vector/screen-hd.css' => array( 'media' => 'screen and (min-width: 982px)' ), - ), - 'scripts' => 'vector/vector.js', - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - - /* jQuery */ - - 'jquery' => array( - 'scripts' => 'resources/jquery/jquery.js', - 'debugRaw' => false, - ), - - /* jQuery Plugins */ - - 'jquery.appear' => array( - 'scripts' => 'resources/jquery/jquery.appear.js', - ), - 'jquery.arrowSteps' => array( - 'scripts' => 'resources/jquery/jquery.arrowSteps.js', - 'styles' => 'resources/jquery/jquery.arrowSteps.css', - ), - 'jquery.async' => array( - 'scripts' => 'resources/jquery/jquery.async.js', - ), - 'jquery.autoEllipsis' => array( - 'scripts' => 'resources/jquery/jquery.autoEllipsis.js', - 'dependencies' => 'jquery.highlightText', - ), - 'jquery.badge' => array( - 'scripts' => 'resources/jquery/jquery.badge.js', - 'styles' => 'resources/jquery/jquery.badge.css', - ), - 'jquery.byteLength' => array( - 'scripts' => 'resources/jquery/jquery.byteLength.js', - ), - 'jquery.byteLimit' => array( - 'scripts' => 'resources/jquery/jquery.byteLimit.js', - 'dependencies' => 'jquery.byteLength', - ), - 'jquery.checkboxShiftClick' => array( - 'scripts' => 'resources/jquery/jquery.checkboxShiftClick.js', - ), - 'jquery.client' => array( - 'scripts' => 'resources/jquery/jquery.client.js', - ), - 'jquery.collapsibleTabs' => array( - 'scripts' => 'resources/jquery/jquery.collapsibleTabs.js', - ), - 'jquery.color' => array( - 'scripts' => 'resources/jquery/jquery.color.js', - 'dependencies' => 'jquery.colorUtil', - ), - 'jquery.colorUtil' => array( - 'scripts' => 'resources/jquery/jquery.colorUtil.js', - ), - 'jquery.cookie' => array( - 'scripts' => 'resources/jquery/jquery.cookie.js', - ), - 'jquery.delayedBind' => array( - 'scripts' => 'resources/jquery/jquery.delayedBind.js', - ), - 'jquery.expandableField' => array( - 'scripts' => 'resources/jquery/jquery.expandableField.js', - 'dependencies' => 'jquery.delayedBind', - ), - 'jquery.farbtastic' => array( - 'scripts' => 'resources/jquery/jquery.farbtastic.js', - 'styles' => 'resources/jquery/jquery.farbtastic.css', - 'dependencies' => 'jquery.colorUtil', - ), - 'jquery.footHovzer' => array( - 'scripts' => 'resources/jquery/jquery.footHovzer.js', - 'styles' => 'resources/jquery/jquery.footHovzer.css', - ), - 'jquery.form' => array( - 'scripts' => 'resources/jquery/jquery.form.js', - ), - 'jquery.getAttrs' => array( - 'scripts' => 'resources/jquery/jquery.getAttrs.js', - ), - 'jquery.highlightText' => array( - 'scripts' => 'resources/jquery/jquery.highlightText.js', - 'dependencies' => 'jquery.mwExtension', - ), - 'jquery.hoverIntent' => array( - 'scripts' => 'resources/jquery/jquery.hoverIntent.js', - ), - 'jquery.json' => array( - 'scripts' => 'resources/jquery/jquery.json.js', - ), - 'jquery.localize' => array( - 'scripts' => 'resources/jquery/jquery.localize.js', - ), - 'jquery.makeCollapsible' => array( - 'scripts' => 'resources/jquery/jquery.makeCollapsible.js', - 'styles' => 'resources/jquery/jquery.makeCollapsible.css', - 'messages' => array( 'collapsible-expand', 'collapsible-collapse' ), - ), - 'jquery.mockjax' => array( - 'scripts' => 'resources/jquery/jquery.mockjax.js', - ), - 'jquery.mw-jump' => array( - 'scripts' => 'resources/jquery/jquery.mw-jump.js', - ), - 'jquery.mwExtension' => array( - 'scripts' => 'resources/jquery/jquery.mwExtension.js', - ), - 'jquery.placeholder' => array( - 'scripts' => 'resources/jquery/jquery.placeholder.js', - ), - 'jquery.qunit' => array( - 'scripts' => 'resources/jquery/jquery.qunit.js', - 'styles' => 'resources/jquery/jquery.qunit.css', - 'position' => 'top', - ), - 'jquery.qunit.completenessTest' => array( - 'scripts' => 'resources/jquery/jquery.qunit.completenessTest.js', - 'dependencies' => 'jquery.qunit', - ), - 'jquery.spinner' => array( - 'scripts' => 'resources/jquery/jquery.spinner.js', - 'styles' => 'resources/jquery/jquery.spinner.css', - ), - 'jquery.jStorage' => array( - 'scripts' => 'resources/jquery/jquery.jStorage.js', - 'dependencies' => 'jquery.json', - ), - 'jquery.suggestions' => array( - 'scripts' => 'resources/jquery/jquery.suggestions.js', - 'styles' => 'resources/jquery/jquery.suggestions.css', - 'dependencies' => 'jquery.autoEllipsis', - ), - 'jquery.tabIndex' => array( - 'scripts' => 'resources/jquery/jquery.tabIndex.js', - ), - 'jquery.tablesorter' => array( - 'scripts' => 'resources/jquery/jquery.tablesorter.js', - 'styles' => 'resources/jquery/jquery.tablesorter.css', - 'messages' => array( 'sort-descending', 'sort-ascending' ), - 'dependencies' => 'jquery.mwExtension', - ), - 'jquery.textSelection' => array( - 'scripts' => 'resources/jquery/jquery.textSelection.js', - 'dependencies' => 'jquery.client', - ), - 'jquery.validate' => array( - 'scripts' => 'resources/jquery/jquery.validate.js', - ), - 'jquery.xmldom' => array( - 'scripts' => 'resources/jquery/jquery.xmldom.js', - ), - - /* jQuery Tipsy */ - - 'jquery.tipsy' => array( - 'scripts' => 'resources/jquery.tipsy/jquery.tipsy.js', - 'styles' => 'resources/jquery.tipsy/jquery.tipsy.css', - ), - - /* jQuery UI */ - - // Core - 'jquery.ui.core' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.core.js', - 'skinStyles' => array( - 'default' => array( - 'resources/jquery.ui/themes/default/jquery.ui.core.css', - 'resources/jquery.ui/themes/default/jquery.ui.theme.css', - ), - 'vector' => array( - 'resources/jquery.ui/themes/vector/jquery.ui.core.css', - 'resources/jquery.ui/themes/vector/jquery.ui.theme.css', - ), - ), - 'dependencies' => 'jquery', - 'group' => 'jquery.ui', - ), - 'jquery.ui.widget' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.widget.js', - 'group' => 'jquery.ui', - ), - 'jquery.ui.mouse' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.mouse.js', - 'dependencies' => 'jquery.ui.widget', - 'group' => 'jquery.ui', - ), - 'jquery.ui.position' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.position.js', - 'group' => 'jquery.ui', - ), - // Interactions - 'jquery.ui.draggable' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.draggable.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.mouse', 'jquery.ui.widget' ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.droppable' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.droppable.js', - 'dependencies' => array( - 'jquery.ui.core', 'jquery.ui.mouse', 'jquery.ui.widget', 'jquery.ui.draggable', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.resizable' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.resizable.js', - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.resizable.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.resizable.css', - ), - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget', 'jquery.ui.mouse' ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.selectable' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.selectable.js', - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.selectable.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.selectable.css', - ), - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget', 'jquery.ui.mouse' ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.sortable' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.sortable.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget', 'jquery.ui.mouse' ), - 'group' => 'jquery.ui', - ), - // Widgets - 'jquery.ui.accordion' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.accordion.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget' ), - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.accordion.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.accordion.css', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.autocomplete' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.autocomplete.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget', 'jquery.ui.position' ), - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.autocomplete.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.autocomplete.css', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.button' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.button.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget' ), - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.button.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.button.css', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.datepicker' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.datepicker.js', - 'dependencies' => 'jquery.ui.core', - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.datepicker.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.datepicker.css', - ), - 'languageScripts' => array( - 'af' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-af.js', - 'ar' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ar.js', - 'az' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-az.js', - 'bg' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-bg.js', - 'bs' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-bs.js', - 'ca' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ca.js', - 'cs' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-cs.js', - 'da' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-da.js', - 'de' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-de.js', - 'el' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-el.js', - 'en-gb' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-en-GB.js', - 'eo' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-eo.js', - 'es' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-es.js', - 'et' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-et.js', - 'eu' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-eu.js', - 'fa' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-fa.js', - 'fi' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-fi.js', - 'fo' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-fo.js', - 'fr' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-fr.js', - 'gl' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-gl.js', - 'he' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-he.js', - 'hi' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-hi.js', - 'hr' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-hr.js', - 'hu' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-hu.js', - 'hy' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-hy.js', - 'id' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-id.js', - 'is' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-is.js', - 'it' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-it.js', - 'ja' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ja.js', - 'ka' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ka.js', - 'kk' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-kk.js', - 'km' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-km.js', - 'ko' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ko.js', - 'lb' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-lb.js', - 'lt' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-lt.js', - 'lv' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-lv.js', - 'mk' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-mk.js', - 'ml' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ml.js', - 'ms' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ms.js', - 'nl' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-nl.js', - 'no' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-no.js', - 'pl' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-pl.js', - 'pt' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-pt.js', - 'pt-br' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-pt-BR.js', - 'rm' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-rm.js', - 'ro' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ro.js', - 'ru' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ru.js', - 'sk' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-sk.js', - 'sl' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-sl.js', - 'sq' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-sq.js', - 'sr-sr' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-sr-SR.js', - 'sr' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-sr.js', - 'sv' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-sv.js', - 'ta' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-ta.js', - 'th' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-th.js', - 'tr' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-tr.js', - 'uk' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-uk.js', - 'vi' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-vi.js', - 'zh-cn' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-zh-CN.js', - 'zh-hk' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-zh-HK.js', - 'zh-tw' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-zh-TW.js', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.dialog' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.dialog.js', - 'dependencies' => array( - 'jquery.ui.core', - 'jquery.ui.widget', - 'jquery.ui.button', - 'jquery.ui.draggable', - 'jquery.ui.mouse', - 'jquery.ui.position', - 'jquery.ui.resizable', - ), - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.dialog.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.dialog.css', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.progressbar' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.progressbar.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget' ), - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.progressbar.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.progressbar.css', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.slider' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.slider.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget', 'jquery.ui.mouse' ), - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.slider.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.slider.css', - ), - 'group' => 'jquery.ui', - ), - 'jquery.ui.tabs' => array( - 'scripts' => 'resources/jquery.ui/jquery.ui.tabs.js', - 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget' ), - 'skinStyles' => array( - 'default' => 'resources/jquery.ui/themes/default/jquery.ui.tabs.css', - 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.tabs.css', - ), - 'group' => 'jquery.ui', - ), - // Effects - 'jquery.effects.core' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.core.js', - 'dependencies' => 'jquery', - 'group' => 'jquery.ui', - ), - 'jquery.effects.blind' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.blind.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.bounce' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.bounce.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.clip' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.clip.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.drop' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.drop.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.explode' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.explode.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.fade' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.fade.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.fold' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.fold.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.highlight' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.highlight.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.pulsate' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.pulsate.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.scale' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.scale.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.shake' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.shake.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.slide' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.slide.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - 'jquery.effects.transfer' => array( - 'scripts' => 'resources/jquery.effects/jquery.effects.transfer.js', - 'dependencies' => 'jquery.effects.core', - 'group' => 'jquery.ui', - ), - - /* MediaWiki */ - - 'mediawiki' => array( - 'scripts' => 'resources/mediawiki/mediawiki.js', - 'debugScripts' => 'resources/mediawiki/mediawiki.log.js', - 'debugRaw' => false, - ), - 'mediawiki.api' => array( - 'scripts' => 'resources/mediawiki.api/mediawiki.api.js', - 'dependencies' => 'mediawiki.util', - ), - 'mediawiki.api.category' => array( - 'scripts' => 'resources/mediawiki.api/mediawiki.api.category.js', - 'dependencies' => array( - 'mediawiki.api', - 'mediawiki.Title', - ), - ), - 'mediawiki.api.edit' => array( - 'scripts' => 'resources/mediawiki.api/mediawiki.api.edit.js', - 'dependencies' => array( - 'mediawiki.api', - 'mediawiki.Title', - ), - ), - 'mediawiki.api.parse' => array( - 'scripts' => 'resources/mediawiki.api/mediawiki.api.parse.js', - 'dependencies' => 'mediawiki.api', - ), - 'mediawiki.api.titleblacklist' => array( - 'scripts' => 'resources/mediawiki.api/mediawiki.api.titleblacklist.js', - 'dependencies' => array( - 'mediawiki.api', - 'mediawiki.Title', - ), - ), - 'mediawiki.api.watch' => array( - 'scripts' => 'resources/mediawiki.api/mediawiki.api.watch.js', - 'dependencies' => array( - 'mediawiki.api', - 'user.tokens', - ), - ), - 'mediawiki.debug' => array( - 'scripts' => 'resources/mediawiki/mediawiki.debug.js', - 'styles' => 'resources/mediawiki/mediawiki.debug.css', - 'dependencies' => 'jquery.footHovzer', - 'position' => 'bottom', - ), - 'mediawiki.debug.init' => array( - 'scripts' => 'resources/mediawiki/mediawiki.debug.init.js', - 'dependencies' => 'mediawiki.debug', - // Uses a custom mw.config variable that is set in debughtml, - // must be loaded on the bottom - 'position' => 'bottom', - ), - 'mediawiki.feedback' => array( - 'scripts' => 'resources/mediawiki/mediawiki.feedback.js', - 'styles' => 'resources/mediawiki/mediawiki.feedback.css', - 'dependencies' => array( - 'mediawiki.api.edit', - 'mediawiki.Title', - 'mediawiki.jqueryMsg', - 'jquery.ui.dialog', - ), - 'messages' => array( - 'feedback-bugornote', - 'feedback-subject', - 'feedback-message', - 'feedback-cancel', - 'feedback-submit', - 'feedback-adding', - 'feedback-error1', - 'feedback-error2', - 'feedback-error3', - 'feedback-thanks', - 'feedback-close', - 'feedback-bugcheck', - 'feedback-bugnew', - ), - ), - 'mediawiki.htmlform' => array( - 'scripts' => 'resources/mediawiki/mediawiki.htmlform.js', - ), - 'mediawiki.notification' => array( - 'styles' => 'resources/mediawiki/mediawiki.notification.css', - 'scripts' => 'resources/mediawiki/mediawiki.notification.js', - 'dependencies' => array( - 'mediawiki.page.startup', - ), - ), - 'mediawiki.notify' => array( - 'scripts' => 'resources/mediawiki/mediawiki.notify.js', - ), - 'mediawiki.searchSuggest' => array( - 'scripts' => 'resources/mediawiki/mediawiki.searchSuggest.js', - 'messages' => array( - 'searchsuggest-search', - 'searchsuggest-containing', - ), - 'dependencies' => array( - 'jquery.autoEllipsis', - 'jquery.client', - 'jquery.placeholder', - 'jquery.suggestions', - ), - ), - 'mediawiki.Title' => array( - 'scripts' => 'resources/mediawiki/mediawiki.Title.js', - 'dependencies' => 'mediawiki.util', - ), - 'mediawiki.Uri' => array( - 'scripts' => 'resources/mediawiki/mediawiki.Uri.js', - ), - 'mediawiki.user' => array( - 'scripts' => 'resources/mediawiki/mediawiki.user.js', - 'dependencies' => array( - 'jquery.cookie', - 'mediawiki.api', - ), - ), - 'mediawiki.util' => array( - 'scripts' => 'resources/mediawiki/mediawiki.util.js', - 'dependencies' => array( - 'jquery.client', - 'jquery.cookie', - 'jquery.mwExtension', - 'mediawiki.notify', - ), - 'messages' => array( 'showtoc', 'hidetoc' ), - 'position' => 'top', // For $wgPreloadJavaScriptMwUtil - ), - - /* MediaWiki Action */ - - 'mediawiki.action.edit' => array( - 'scripts' => 'resources/mediawiki.action/mediawiki.action.edit.js', - 'dependencies' => array( - 'jquery.textSelection', - 'jquery.byteLimit', - ), - 'position' => 'top', - ), - 'mediawiki.action.edit.preview' => array( - 'scripts' => 'resources/mediawiki.action/mediawiki.action.edit.preview.js', - 'dependencies' => array( - 'jquery.form', - 'jquery.spinner', - ), - ), - 'mediawiki.action.history' => array( - 'scripts' => 'resources/mediawiki.action/mediawiki.action.history.js', - 'group' => 'mediawiki.action.history', - ), - 'mediawiki.action.history.diff' => array( - 'styles' => 'resources/mediawiki.action/mediawiki.action.history.diff.css', - 'group' => 'mediawiki.action.history', - ), - 'mediawiki.action.view.dblClickEdit' => array( - 'scripts' => 'resources/mediawiki.action/mediawiki.action.view.dblClickEdit.js', - 'dependencies' => 'mediawiki.util', - ), - 'mediawiki.action.view.metadata' => array( - 'scripts' => 'resources/mediawiki.action/mediawiki.action.view.metadata.js', - 'messages' => array( - 'metadata-expand', - 'metadata-collapse', - ), - ), - 'mediawiki.action.view.rightClickEdit' => array( - 'scripts' => 'resources/mediawiki.action/mediawiki.action.view.rightClickEdit.js', - ), - // Alias for backwards compatibility - 'mediawiki.action.watch.ajax' => array( - 'dependencies' => 'mediawiki.page.watch.ajax' - ), - - /* MediaWiki Language */ - - 'mediawiki.language' => array( - 'scripts' => 'resources/mediawiki.language/mediawiki.language.js', - 'languageScripts' => array( - 'bs' => 'resources/mediawiki.language/languages/bs.js', - 'dsb' => 'resources/mediawiki.language/languages/dsb.js', - 'fi' => 'resources/mediawiki.language/languages/fi.js', - 'ga' => 'resources/mediawiki.language/languages/ga.js', - 'he' => 'resources/mediawiki.language/languages/he.js', - 'hsb' => 'resources/mediawiki.language/languages/hsb.js', - 'hu' => 'resources/mediawiki.language/languages/hu.js', - 'hy' => 'resources/mediawiki.language/languages/hy.js', - 'la' => 'resources/mediawiki.language/languages/la.js', - 'os' => 'resources/mediawiki.language/languages/os.js', - 'ru' => 'resources/mediawiki.language/languages/ru.js', - 'sl' => 'resources/mediawiki.language/languages/sl.js', - 'uk' => 'resources/mediawiki.language/languages/uk.js', - ), - 'dependencies' => array( - 'mediawiki.language.data', - 'mediawiki.cldr' - ), - ), - - 'mediawiki.cldr' => array( - 'scripts' => 'resources/mediawiki.language/mediawiki.cldr.js', - 'dependencies' => array( - 'mediawiki.libs.pluralruleparser', - ), - ), - - 'mediawiki.libs.pluralruleparser' => array( - 'scripts' => 'resources/mediawiki.libs/CLDRPluralRuleParser.js', - ), - - 'mediawiki.language.init' => array( - 'scripts' => 'resources/mediawiki.language/mediawiki.language.init.js', - ), - - 'mediawiki.jqueryMsg' => array( - 'scripts' => 'resources/mediawiki/mediawiki.jqueryMsg.js', - 'dependencies' => array( - 'mediawiki.util', - 'mediawiki.language', - ), - ), - - /* MediaWiki Libs */ - - 'mediawiki.libs.jpegmeta' => array( - 'scripts' => 'resources/mediawiki.libs/mediawiki.libs.jpegmeta.js', - ), - - /* MediaWiki Page */ - - 'mediawiki.page.ready' => array( - 'scripts' => 'resources/mediawiki.page/mediawiki.page.ready.js', - 'dependencies' => array( - 'jquery.checkboxShiftClick', - 'jquery.makeCollapsible', - 'jquery.placeholder', - 'jquery.mw-jump', - 'mediawiki.util', - ), - ), - 'mediawiki.page.startup' => array( - 'scripts' => 'resources/mediawiki.page/mediawiki.page.startup.js', - 'dependencies' => array( - 'jquery.client', - 'mediawiki.util', - ), - 'position' => 'top', - ), - 'mediawiki.page.watch.ajax' => array( - 'scripts' => 'resources/mediawiki.page/mediawiki.page.watch.ajax.js', - 'dependencies' => array( - 'mediawiki.page.startup', - 'mediawiki.api.watch', - 'mediawiki.util', - 'mediawiki.notify', - 'jquery.mwExtension', - ), - 'messages' => array( - 'watch', - 'unwatch', - 'watching', - 'unwatching', - 'tooltip-ca-watch', - 'tooltip-ca-unwatch', - 'watcherrortext', - ), - ), - - /* MediaWiki Special pages */ - - 'mediawiki.special' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.js', - 'styles' => 'resources/mediawiki.special/mediawiki.special.css', - ), - 'mediawiki.special.block' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.block.js', - 'dependencies' => array( - 'mediawiki.util', - ), - ), - 'mediawiki.special.changeemail' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.changeemail.js', - 'styles' => 'resources/mediawiki.special/mediawiki.special.changeemail.css', - 'dependencies' => array( - 'mediawiki.util', - ), - 'messages' => array( - 'email-address-validity-valid', - 'email-address-validity-invalid', - ), - ), - 'mediawiki.special.changeslist' => array( - 'styles' => 'resources/mediawiki.special/mediawiki.special.changeslist.css', - 'dependencies' => array( 'jquery.makeCollapsible' ), - ), - 'mediawiki.special.movePage' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.movePage.js', - 'dependencies' => 'jquery.byteLimit', - ), - 'mediawiki.special.preferences' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.preferences.js', - 'styles' => 'resources/mediawiki.special/mediawiki.special.preferences.css', - ), - 'mediawiki.special.recentchanges' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.recentchanges.js', - 'dependencies' => array( 'mediawiki.special' ), - 'position' => 'top', - ), - 'mediawiki.special.search' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.search.js', - 'styles' => 'resources/mediawiki.special/mediawiki.special.search.css', - 'messages' => array( - 'powersearch-togglelabel', - 'powersearch-toggleall', - 'powersearch-togglenone', - ), - ), - 'mediawiki.special.undelete' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.undelete.js', - ), - 'mediawiki.special.upload' => array( - // @TODO: merge in remainder of mediawiki.legacy.upload - 'scripts' => 'resources/mediawiki.special/mediawiki.special.upload.js', - 'messages' => array( - 'widthheight', - 'size-bytes', - 'size-kilobytes', - 'size-megabytes', - 'size-gigabytes', - 'largefileserver', - ), - 'dependencies' => array( 'mediawiki.libs.jpegmeta', 'mediawiki.util' ), - ), - 'mediawiki.special.javaScriptTest' => array( - 'scripts' => 'resources/mediawiki.special/mediawiki.special.javaScriptTest.js', - 'messages' => array_merge( Skin::getSkinNameMessages(), array( - 'colon-separator', - 'javascripttest-pagetext-skins', - ) ), - 'dependencies' => array( 'jquery.qunit' ), - 'position' => 'top', - ), - - /* MediaWiki Tests */ - - 'mediawiki.tests.qunit.testrunner' => array( - 'scripts' => 'tests/qunit/data/testrunner.js', - 'dependencies' => array( - 'jquery.qunit', - 'jquery.qunit.completenessTest', - 'mediawiki.page.startup', - 'mediawiki.page.ready', - ), - 'position' => 'top', - ), - - /* MediaWiki Legacy */ - - 'mediawiki.legacy.ajax' => array( - 'scripts' => 'common/ajax.js', - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - 'dependencies' => array( - 'mediawiki.util', - 'mediawiki.legacy.wikibits', - ), - 'position' => 'top', // Temporary hack for legacy support - ), - 'mediawiki.legacy.commonPrint' => array( - 'styles' => array( 'common/commonPrint.css' => array( 'media' => 'print' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'mediawiki.legacy.config' => array( - 'scripts' => 'common/config.js', - 'styles' => array( 'common/config.css', 'common/config-cc.css' ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - 'dependencies' => 'mediawiki.legacy.wikibits', - ), - 'mediawiki.legacy.IEFixes' => array( - 'scripts' => 'common/IEFixes.js', - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - 'dependencies' => 'mediawiki.legacy.wikibits', - ), - 'mediawiki.legacy.protect' => array( - 'scripts' => 'common/protect.js', - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - 'dependencies' => array( - 'mediawiki.legacy.wikibits', - 'jquery.byteLimit', - ), - 'position' => 'top', - ), - 'mediawiki.legacy.shared' => array( - 'styles' => array( 'common/shared.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'mediawiki.legacy.oldshared' => array( - 'styles' => array( 'common/oldshared.css' => array( 'media' => 'screen' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), - 'mediawiki.legacy.upload' => array( - 'scripts' => 'common/upload.js', - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - 'dependencies' => array( - 'mediawiki.legacy.wikibits', - 'mediawiki.util', - ), - ), - 'mediawiki.legacy.wikibits' => array( - 'scripts' => 'common/wikibits.js', - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - 'dependencies' => array( - 'mediawiki.util', - ), - 'position' => 'top', - ), - 'mediawiki.legacy.wikiprintable' => array( - 'styles' => array( 'common/wikiprintable.css' => array( 'media' => 'print' ) ), - 'remoteBasePath' => $GLOBALS['wgStylePath'], - 'localBasePath' => $GLOBALS['wgStyleDirectory'], - ), -); diff --git a/resources/jquery.chosen/LICENSE b/resources/jquery.chosen/LICENSE new file mode 100644 index 00000000..0675dc52 --- /dev/null +++ b/resources/jquery.chosen/LICENSE @@ -0,0 +1,24 @@ +# Chosen, a Select Box Enhancer for jQuery and Protoype +## by Patrick Filler for [Harvest](http://getharvest.com) + +Available for use under the [MIT License](http://en.wikipedia.org/wiki/MIT_License) + +Copyright (c) 2011-2013 by Harvest + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/resources/jquery.chosen/chosen-sprite.png b/resources/jquery.chosen/chosen-sprite.png new file mode 100644 index 00000000..3611ae4a Binary files /dev/null and b/resources/jquery.chosen/chosen-sprite.png differ diff --git a/resources/jquery.chosen/chosen-sprite@2x.png b/resources/jquery.chosen/chosen-sprite@2x.png new file mode 100644 index 00000000..bd61d963 Binary files /dev/null and b/resources/jquery.chosen/chosen-sprite@2x.png differ diff --git a/resources/jquery.chosen/chosen.css b/resources/jquery.chosen/chosen.css new file mode 100644 index 00000000..17793ed7 --- /dev/null +++ b/resources/jquery.chosen/chosen.css @@ -0,0 +1,440 @@ +/* @group Base */ +.chzn-container { + font-size: 13px; + position: relative; + display: inline-block; + vertical-align: middle; + zoom: 1; + *display: inline; +} +.chzn-container .chzn-drop { + background: #fff; + border: 1px solid #aaa; + border-top: 0; + position: absolute; + top: 100%; + left: -9999px; + -webkit-box-shadow: 0 4px 5px rgba(0,0,0,.15); + -moz-box-shadow : 0 4px 5px rgba(0,0,0,.15); + box-shadow : 0 4px 5px rgba(0,0,0,.15); + z-index: 1010; + width: 100%; + -moz-box-sizing : border-box; + -ms-box-sizing : border-box; + -webkit-box-sizing: border-box; + -khtml-box-sizing : border-box; + box-sizing : border-box; +} + +.chzn-container.chzn-with-drop .chzn-drop { + left: 0; +} + +/* @end */ + +/* @group Single Chosen */ +.chzn-container-single .chzn-single { + background-color: #ffffff; + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#eeeeee', GradientType=0 ); + background-image: -webkit-gradient(linear, 0 0, 0 100%, color-stop(20%, #ffffff), color-stop(50%, #f6f6f6), color-stop(52%, #eeeeee), color-stop(100%, #f4f4f4)); + background-image: -webkit-linear-gradient(top, #ffffff 20%, #f6f6f6 50%, #eeeeee 52%, #f4f4f4 100%); + background-image: -moz-linear-gradient(top, #ffffff 20%, #f6f6f6 50%, #eeeeee 52%, #f4f4f4 100%); + background-image: -o-linear-gradient(top, #ffffff 20%, #f6f6f6 50%, #eeeeee 52%, #f4f4f4 100%); + background-image: linear-gradient(#ffffff 20%, #f6f6f6 50%, #eeeeee 52%, #f4f4f4 100%); + -webkit-border-radius: 5px; + -moz-border-radius : 5px; + border-radius : 5px; + -moz-background-clip : padding; + -webkit-background-clip: padding-box; + background-clip : padding-box; + border: 1px solid #aaaaaa; + -webkit-box-shadow: 0 0 3px #ffffff inset, 0 1px 1px rgba(0,0,0,0.1); + -moz-box-shadow : 0 0 3px #ffffff inset, 0 1px 1px rgba(0,0,0,0.1); + box-shadow : 0 0 3px #ffffff inset, 0 1px 1px rgba(0,0,0,0.1); + display: block; + overflow: hidden; + white-space: nowrap; + position: relative; + height: 23px; + line-height: 24px; + padding: 0 0 0 8px; + color: #444444; + text-decoration: none; +} +.chzn-container-single .chzn-default { + color: #999; +} +.chzn-container-single .chzn-single span { + margin-right: 26px; + display: block; + overflow: hidden; + white-space: nowrap; + -o-text-overflow: ellipsis; + -ms-text-overflow: ellipsis; + text-overflow: ellipsis; +} +.chzn-container-single .chzn-single abbr { + display: block; + position: absolute; + right: 26px; + top: 6px; + width: 12px; + height: 12px; + font-size: 1px; + background: url('chosen-sprite.png') -42px 1px no-repeat; +} +.chzn-container-single .chzn-single abbr:hover { + background-position: -42px -10px; +} +.chzn-container-single.chzn-disabled .chzn-single abbr:hover { + background-position: -42px -10px; +} +.chzn-container-single .chzn-single div { + position: absolute; + right: 0; + top: 0; + display: block; + height: 100%; + width: 18px; +} +.chzn-container-single .chzn-single div b { + background: url('chosen-sprite.png') no-repeat 0px 2px; + display: block; + width: 100%; + height: 100%; +} +.chzn-container-single .chzn-search { + padding: 3px 4px; + position: relative; + margin: 0; + white-space: nowrap; + z-index: 1010; +} +.chzn-container-single .chzn-search input { + background: #fff url('chosen-sprite.png') no-repeat 100% -20px; + background: url('chosen-sprite.png') no-repeat 100% -20px, -webkit-gradient(linear, 0 0, 0 100%, color-stop(1%, #eeeeee), color-stop(15%, #ffffff)); + background: url('chosen-sprite.png') no-repeat 100% -20px, -webkit-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background: url('chosen-sprite.png') no-repeat 100% -20px, -moz-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background: url('chosen-sprite.png') no-repeat 100% -20px, -o-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background: url('chosen-sprite.png') no-repeat 100% -20px, linear-gradient(#eeeeee 1%, #ffffff 15%); + margin: 1px 0; + padding: 4px 20px 4px 5px; + outline: 0; + border: 1px solid #aaa; + font-family: sans-serif; + font-size: 1em; + width: 100%; + -moz-box-sizing : border-box; + -ms-box-sizing : border-box; + -webkit-box-sizing: border-box; + -khtml-box-sizing : border-box; + box-sizing : border-box; +} +.chzn-container-single .chzn-drop { + margin-top: -1px; + -webkit-border-radius: 0 0 4px 4px; + -moz-border-radius : 0 0 4px 4px; + border-radius : 0 0 4px 4px; + -moz-background-clip : padding; + -webkit-background-clip: padding-box; + background-clip : padding-box; +} +.chzn-container-single-nosearch .chzn-search { + position: absolute; + left: -9999px; +} +/* @end */ + +/* @group Multi Chosen */ +.chzn-container-multi .chzn-choices { + background-color: #fff; + background-image: -webkit-gradient(linear, 0 0, 0 100%, color-stop(1%, #eeeeee), color-stop(15%, #ffffff)); + background-image: -webkit-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background-image: -moz-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background-image: -o-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background-image: linear-gradient(#eeeeee 1%, #ffffff 15%); + border: 1px solid #aaa; + margin: 0; + padding: 0; + cursor: text; + overflow: hidden; + height: auto !important; + height: 1%; + position: relative; + width: 100%; + -moz-box-sizing : border-box; + -ms-box-sizing : border-box; + -webkit-box-sizing: border-box; + -khtml-box-sizing : border-box; + box-sizing : border-box; +} +.chzn-container-multi .chzn-choices li { + float: left; + list-style: none; +} +.chzn-container-multi .chzn-choices .search-field { + white-space: nowrap; + margin: 0; + padding: 0; +} +.chzn-container-multi .chzn-choices .search-field input { + color: #666; + background: transparent !important; + border: 0 !important; + font-family: sans-serif; + font-size: 100%; + height: 15px; + padding: 5px; + margin: 1px 0; + outline: 0; + -webkit-box-shadow: none; + -moz-box-shadow : none; + box-shadow : none; +} +.chzn-container-multi .chzn-choices .search-field .default { + color: #999; +} +.chzn-container-multi .chzn-choices .search-choice { + -webkit-border-radius: 3px; + -moz-border-radius : 3px; + border-radius : 3px; + -moz-background-clip : padding; + -webkit-background-clip: padding-box; + background-clip : padding-box; + background-color: #e4e4e4; + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f4f4f4', endColorstr='#eeeeee', GradientType=0 ); + background-image: -webkit-gradient(linear, 0 0, 0 100%, color-stop(20%, #f4f4f4), color-stop(50%, #f0f0f0), color-stop(52%, #e8e8e8), color-stop(100%, #eeeeee)); + background-image: -webkit-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + background-image: -moz-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + background-image: -o-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + background-image: linear-gradient(#f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + -webkit-box-shadow: 0 0 2px #ffffff inset, 0 1px 0 rgba(0,0,0,0.05); + -moz-box-shadow : 0 0 2px #ffffff inset, 0 1px 0 rgba(0,0,0,0.05); + box-shadow : 0 0 2px #ffffff inset, 0 1px 0 rgba(0,0,0,0.05); + color: #333; + border: 1px solid #aaaaaa; + line-height: 13px; + padding: 3px 20px 3px 5px; + margin: 3px 0 3px 5px; + position: relative; + cursor: default; +} +.chzn-container-multi .chzn-choices .search-choice.search-choice-disabled { + background-color: #e4e4e4; + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f4f4f4', endColorstr='#eeeeee', GradientType=0 ); + background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, color-stop(20%, #f4f4f4), color-stop(50%, #f0f0f0), color-stop(52%, #e8e8e8), color-stop(100%, #eeeeee)); + background-image: -webkit-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + background-image: -moz-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + background-image: -o-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + background-image: -ms-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + background-image: linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%); + color: #666; + border: 1px solid #cccccc; + padding-right: 5px; +} +.chzn-container-multi .chzn-choices .search-choice-focus { + background: #d4d4d4; +} +.chzn-container-multi .chzn-choices .search-choice .search-choice-close { + display: block; + position: absolute; + right: 3px; + top: 4px; + width: 12px; + height: 12px; + font-size: 1px; + background: url('chosen-sprite.png') -42px 1px no-repeat; +} +.chzn-container-multi .chzn-choices .search-choice .search-choice-close:hover { + background-position: -42px -10px; +} +.chzn-container-multi .chzn-choices .search-choice-focus .search-choice-close { + background-position: -42px -10px; +} +/* @end */ + +/* @group Results */ +.chzn-container .chzn-results { + margin: 0 4px 4px 0; + max-height: 240px; + padding: 0 0 0 4px; + position: relative; + overflow-x: hidden; + overflow-y: auto; + -webkit-overflow-scrolling: touch; +} +.chzn-container-multi .chzn-results { + margin: 0; + padding: 0; +} +.chzn-container .chzn-results li { + display: none; + line-height: 15px; + padding: 5px 6px; + margin: 0; + list-style: none; +} +.chzn-container .chzn-results .active-result { + cursor: pointer; + display: list-item; +} +.chzn-container .chzn-results .highlighted { + background-color: #3875d7; + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#3875d7', endColorstr='#2a62bc', GradientType=0 ); + background-image: -webkit-gradient(linear, 0 0, 0 100%, color-stop(20%, #3875d7), color-stop(90%, #2a62bc)); + background-image: -webkit-linear-gradient(top, #3875d7 20%, #2a62bc 90%); + background-image: -moz-linear-gradient(top, #3875d7 20%, #2a62bc 90%); + background-image: -o-linear-gradient(top, #3875d7 20%, #2a62bc 90%); + background-image: linear-gradient(#3875d7 20%, #2a62bc 90%); + color: #fff; +} +.chzn-container .chzn-results li em { + background: #feffde; + font-style: normal; +} +.chzn-container .chzn-results .highlighted em { + background: transparent; +} +.chzn-container .chzn-results .no-results { + background: #f4f4f4; + display: list-item; +} +.chzn-container .chzn-results .group-result { + cursor: default; + color: #999; + font-weight: bold; +} +.chzn-container .chzn-results .group-option { + padding-left: 15px; +} +.chzn-container-multi .chzn-drop .result-selected { + display: none; +} +.chzn-container .chzn-results-scroll { + background: white; + margin: 0 4px; + position: absolute; + text-align: center; + width: 321px; /* This should by dynamic with js */ + z-index: 1; +} +.chzn-container .chzn-results-scroll span { + display: inline-block; + height: 17px; + text-indent: -5000px; + width: 9px; +} +.chzn-container .chzn-results-scroll-down { + bottom: 0; +} +.chzn-container .chzn-results-scroll-down span { + background: url('chosen-sprite.png') no-repeat -4px -3px; +} +.chzn-container .chzn-results-scroll-up span { + background: url('chosen-sprite.png') no-repeat -22px -3px; +} +/* @end */ + +/* @group Active */ +.chzn-container-active .chzn-single { + -webkit-box-shadow: 0 0 5px rgba(0,0,0,.3); + -moz-box-shadow : 0 0 5px rgba(0,0,0,.3); + box-shadow : 0 0 5px rgba(0,0,0,.3); + border: 1px solid #5897fb; +} +.chzn-container-active.chzn-with-drop .chzn-single { + border: 1px solid #aaa; + -webkit-box-shadow: 0 1px 0 #fff inset; + -moz-box-shadow : 0 1px 0 #fff inset; + box-shadow : 0 1px 0 #fff inset; + background-color: #eee; + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#eeeeee', endColorstr='#ffffff', GradientType=0 ); + background-image: -webkit-gradient(linear, 0 0, 0 100%, color-stop(20%, #eeeeee), color-stop(80%, #ffffff)); + background-image: -webkit-linear-gradient(top, #eeeeee 20%, #ffffff 80%); + background-image: -moz-linear-gradient(top, #eeeeee 20%, #ffffff 80%); + background-image: -o-linear-gradient(top, #eeeeee 20%, #ffffff 80%); + background-image: linear-gradient(#eeeeee 20%, #ffffff 80%); + -webkit-border-bottom-left-radius : 0; + -webkit-border-bottom-right-radius: 0; + -moz-border-radius-bottomleft : 0; + -moz-border-radius-bottomright: 0; + border-bottom-left-radius : 0; + border-bottom-right-radius: 0; +} +.chzn-container-active.chzn-with-drop .chzn-single div { + background: transparent; + border-left: none; +} +.chzn-container-active.chzn-with-drop .chzn-single div b { + background-position: -18px 2px; +} +.chzn-container-active .chzn-choices { + -webkit-box-shadow: 0 0 5px rgba(0,0,0,.3); + -moz-box-shadow : 0 0 5px rgba(0,0,0,.3); + box-shadow : 0 0 5px rgba(0,0,0,.3); + border: 1px solid #5897fb; +} +.chzn-container-active .chzn-choices .search-field input { + color: #111 !important; +} +/* @end */ + +/* @group Disabled Support */ +.chzn-disabled { + cursor: default; + opacity:0.5 !important; +} +.chzn-disabled .chzn-single { + cursor: default; +} +.chzn-disabled .chzn-choices .search-choice .search-choice-close { + cursor: default; +} + +/* @group Right to Left */ +.chzn-rtl { text-align: right; } +.chzn-rtl .chzn-single { padding: 0 8px 0 0; overflow: visible; } +.chzn-rtl .chzn-single span { margin-left: 26px; margin-right: 0; direction: rtl; } + +.chzn-rtl .chzn-single div { left: 3px; right: auto; } +.chzn-rtl .chzn-single abbr { + left: 26px; + right: auto; +} +.chzn-rtl .chzn-choices .search-field input { direction: rtl; } +.chzn-rtl .chzn-choices li { float: right; } +.chzn-rtl .chzn-choices .search-choice { padding: 3px 5px 3px 19px; margin: 3px 5px 3px 0; } +.chzn-rtl .chzn-choices .search-choice .search-choice-close { left: 4px; right: auto; } +.chzn-rtl .chzn-search { left: 9999px; } +.chzn-rtl.chzn-with-drop .chzn-search { left: 0px; } +.chzn-rtl .chzn-drop { left: 9999px; } +.chzn-rtl.chzn-container-single .chzn-results { margin: 0 0 4px 4px; padding: 0 4px 0 0; } +.chzn-rtl .chzn-results .group-option { padding-left: 0; padding-right: 15px; } +.chzn-rtl.chzn-container-active.chzn-with-drop .chzn-single div { border-right: none; } +.chzn-rtl .chzn-search input { + background: #fff url('chosen-sprite.png') no-repeat -30px -20px; + background: url('chosen-sprite.png') no-repeat -30px -20px, -webkit-gradient(linear, 0 0, 0 100%, color-stop(1%, #eeeeee), color-stop(15%, #ffffff)); + background: url('chosen-sprite.png') no-repeat -30px -20px, -webkit-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background: url('chosen-sprite.png') no-repeat -30px -20px, -moz-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background: url('chosen-sprite.png') no-repeat -30px -20px, -o-linear-gradient(top, #eeeeee 1%, #ffffff 15%); + background: url('chosen-sprite.png') no-repeat -30px -20px, linear-gradient(#eeeeee 1%, #ffffff 15%); + padding: 4px 5px 4px 20px; + direction: rtl; +} +.chzn-container-single.chzn-rtl .chzn-single div b { + background-position: 6px 2px; +} +.chzn-container-single.chzn-rtl.chzn-with-drop .chzn-single div b { + background-position: -12px 2px; +} +/* @end */ + +/* @group Retina compatibility */ +@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min-resolution: 144dpi) { + .chzn-rtl .chzn-search input, .chzn-container-single .chzn-single abbr, .chzn-container-single .chzn-single div b, .chzn-container-single .chzn-search input, .chzn-container-multi .chzn-choices .search-choice .search-choice-close, .chzn-container .chzn-results-scroll-down span, .chzn-container .chzn-results-scroll-up span { + background-image: url('chosen-sprite@2x.png') !important; + background-repeat: no-repeat !important; + background-size: 52px 37px !important; + } +} +/* @end */ diff --git a/resources/jquery.chosen/chosen.jquery.js b/resources/jquery.chosen/chosen.jquery.js new file mode 100644 index 00000000..745174f7 --- /dev/null +++ b/resources/jquery.chosen/chosen.jquery.js @@ -0,0 +1,1103 @@ +// Chosen, a Select Box Enhancer for jQuery and Protoype +// by Patrick Filler for Harvest, http://getharvest.com +// +// Version 0.9.14 +// Full source at https://github.com/harvesthq/chosen +// Copyright (c) 2011 Harvest http://getharvest.com + +// MIT License, https://github.com/harvesthq/chosen/blob/master/LICENSE.md +// This file is generated by `cake build`, do not edit it by hand. +(function() { + var SelectParser; + + SelectParser = (function() { + + function SelectParser() { + this.options_index = 0; + this.parsed = []; + } + + SelectParser.prototype.add_node = function(child) { + if (child.nodeName.toUpperCase() === "OPTGROUP") { + return this.add_group(child); + } else { + return this.add_option(child); + } + }; + + SelectParser.prototype.add_group = function(group) { + var group_position, option, _i, _len, _ref, _results; + group_position = this.parsed.length; + this.parsed.push({ + array_index: group_position, + group: true, + label: group.label, + children: 0, + disabled: group.disabled + }); + _ref = group.childNodes; + _results = []; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + option = _ref[_i]; + _results.push(this.add_option(option, group_position, group.disabled)); + } + return _results; + }; + + SelectParser.prototype.add_option = function(option, group_position, group_disabled) { + if (option.nodeName.toUpperCase() === "OPTION") { + if (option.text !== "") { + if (group_position != null) { + this.parsed[group_position].children += 1; + } + this.parsed.push({ + array_index: this.parsed.length, + options_index: this.options_index, + value: option.value, + text: option.text, + html: option.innerHTML, + selected: option.selected, + disabled: group_disabled === true ? group_disabled : option.disabled, + group_array_index: group_position, + classes: option.className, + style: option.style.cssText + }); + } else { + this.parsed.push({ + array_index: this.parsed.length, + options_index: this.options_index, + empty: true + }); + } + return this.options_index += 1; + } + }; + + return SelectParser; + + })(); + + SelectParser.select_to_array = function(select) { + var child, parser, _i, _len, _ref; + parser = new SelectParser(); + _ref = select.childNodes; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + child = _ref[_i]; + parser.add_node(child); + } + return parser.parsed; + }; + + this.SelectParser = SelectParser; + +}).call(this); + +/* +Chosen source: generate output using 'cake build' +Copyright (c) 2011 by Harvest +*/ + + +(function() { + var AbstractChosen, root; + + root = this; + + AbstractChosen = (function() { + + function AbstractChosen(form_field, options) { + this.form_field = form_field; + this.options = options != null ? options : {}; + if (!AbstractChosen.browser_is_supported()) { + return; + } + this.is_multiple = this.form_field.multiple; + this.set_default_text(); + this.set_default_values(); + this.setup(); + this.set_up_html(); + this.register_observers(); + this.finish_setup(); + } + + AbstractChosen.prototype.set_default_values = function() { + var _this = this; + this.click_test_action = function(evt) { + return _this.test_active_click(evt); + }; + this.activate_action = function(evt) { + return _this.activate_field(evt); + }; + this.active_field = false; + this.mouse_on_container = false; + this.results_showing = false; + this.result_highlighted = null; + this.result_single_selected = null; + this.allow_single_deselect = (this.options.allow_single_deselect != null) && (this.form_field.options[0] != null) && this.form_field.options[0].text === "" ? this.options.allow_single_deselect : false; + this.disable_search_threshold = this.options.disable_search_threshold || 0; + this.disable_search = this.options.disable_search || false; + this.enable_split_word_search = this.options.enable_split_word_search != null ? this.options.enable_split_word_search : true; + this.search_contains = this.options.search_contains || false; + this.choices = 0; + this.single_backstroke_delete = this.options.single_backstroke_delete || false; + this.max_selected_options = this.options.max_selected_options || Infinity; + return this.inherit_select_classes = this.options.inherit_select_classes || false; + }; + + AbstractChosen.prototype.set_default_text = function() { + if (this.form_field.getAttribute("data-placeholder")) { + this.default_text = this.form_field.getAttribute("data-placeholder"); + } else if (this.is_multiple) { + this.default_text = this.options.placeholder_text_multiple || this.options.placeholder_text || AbstractChosen.default_multiple_text; + } else { + this.default_text = this.options.placeholder_text_single || this.options.placeholder_text || AbstractChosen.default_single_text; + } + return this.results_none_found = this.form_field.getAttribute("data-no_results_text") || this.options.no_results_text || AbstractChosen.default_no_result_text; + }; + + AbstractChosen.prototype.mouse_enter = function() { + return this.mouse_on_container = true; + }; + + AbstractChosen.prototype.mouse_leave = function() { + return this.mouse_on_container = false; + }; + + AbstractChosen.prototype.input_focus = function(evt) { + var _this = this; + if (this.is_multiple) { + if (!this.active_field) { + return setTimeout((function() { + return _this.container_mousedown(); + }), 50); + } + } else { + if (!this.active_field) { + return this.activate_field(); + } + } + }; + + AbstractChosen.prototype.input_blur = function(evt) { + var _this = this; + if (!this.mouse_on_container) { + this.active_field = false; + return setTimeout((function() { + return _this.blur_test(); + }), 100); + } + }; + + AbstractChosen.prototype.result_add_option = function(option) { + var classes, style; + if (!option.disabled) { + option.dom_id = this.container_id + "_o_" + option.array_index; + classes = option.selected && this.is_multiple ? [] : ["active-result"]; + if (option.selected) { + classes.push("result-selected"); + } + if (option.group_array_index != null) { + classes.push("group-option"); + } + if (option.classes !== "") { + classes.push(option.classes); + } + style = option.style.cssText !== "" ? " style=\"" + option.style + "\"" : ""; + return '
  • ' + option.html + '
  • '; + } else { + return ""; + } + }; + + AbstractChosen.prototype.results_update_field = function() { + this.set_default_text(); + if (!this.is_multiple) { + this.results_reset_cleanup(); + } + this.result_clear_highlight(); + this.result_single_selected = null; + return this.results_build(); + }; + + AbstractChosen.prototype.results_toggle = function() { + if (this.results_showing) { + return this.results_hide(); + } else { + return this.results_show(); + } + }; + + AbstractChosen.prototype.results_search = function(evt) { + if (this.results_showing) { + return this.winnow_results(); + } else { + return this.results_show(); + } + }; + + AbstractChosen.prototype.choices_click = function(evt) { + evt.preventDefault(); + if (!this.results_showing) { + return this.results_show(); + } + }; + + AbstractChosen.prototype.keyup_checker = function(evt) { + var stroke, _ref; + stroke = (_ref = evt.which) != null ? _ref : evt.keyCode; + this.search_field_scale(); + switch (stroke) { + case 8: + if (this.is_multiple && this.backstroke_length < 1 && this.choices > 0) { + return this.keydown_backstroke(); + } else if (!this.pending_backstroke) { + this.result_clear_highlight(); + return this.results_search(); + } + break; + case 13: + evt.preventDefault(); + if (this.results_showing) { + return this.result_select(evt); + } + break; + case 27: + if (this.results_showing) { + this.results_hide(); + } + return true; + case 9: + case 38: + case 40: + case 16: + case 91: + case 17: + break; + default: + return this.results_search(); + } + }; + + AbstractChosen.prototype.generate_field_id = function() { + var new_id; + new_id = this.generate_random_id(); + this.form_field.id = new_id; + return new_id; + }; + + AbstractChosen.prototype.generate_random_char = function() { + var chars, newchar, rand; + chars = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"; + rand = Math.floor(Math.random() * chars.length); + return newchar = chars.substring(rand, rand + 1); + }; + + AbstractChosen.prototype.container_width = function() { + var width; + if (this.options.width != null) { + return this.options.width; + } + width = window.getComputedStyle != null ? parseFloat(window.getComputedStyle(this.form_field).getPropertyValue('width')) : (typeof jQuery !== "undefined" && jQuery !== null) && (this.form_field_jq != null) ? this.form_field_jq.outerWidth() : this.form_field.getWidth(); + return width + "px"; + }; + + AbstractChosen.browser_is_supported = function() { + var _ref; + if (window.navigator.appName === "Microsoft Internet Explorer") { + return (null !== (_ref = document.documentMode) && _ref >= 8); + } + return true; + }; + + AbstractChosen.default_multiple_text = "Select Some Options"; + + AbstractChosen.default_single_text = "Select an Option"; + + AbstractChosen.default_no_result_text = "No results match"; + + return AbstractChosen; + + })(); + + root.AbstractChosen = AbstractChosen; + +}).call(this); + +/* +Chosen source: generate output using 'cake build' +Copyright (c) 2011 by Harvest +*/ + + +(function() { + var $, Chosen, root, + __hasProp = {}.hasOwnProperty, + __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }; + + root = this; + + $ = jQuery; + + $.fn.extend({ + chosen: function(options) { + if (!AbstractChosen.browser_is_supported()) { + return this; + } + return this.each(function(input_field) { + var $this; + $this = $(this); + if (!$this.hasClass("chzn-done")) { + return $this.data('chosen', new Chosen(this, options)); + } + }); + } + }); + + Chosen = (function(_super) { + + __extends(Chosen, _super); + + function Chosen() { + return Chosen.__super__.constructor.apply(this, arguments); + } + + Chosen.prototype.setup = function() { + this.form_field_jq = $(this.form_field); + this.current_selectedIndex = this.form_field.selectedIndex; + return this.is_rtl = this.form_field_jq.hasClass("chzn-rtl"); + }; + + Chosen.prototype.finish_setup = function() { + return this.form_field_jq.addClass("chzn-done"); + }; + + Chosen.prototype.set_up_html = function() { + var container_classes, container_props; + this.container_id = this.form_field.id.length ? this.form_field.id.replace(/[^\w]/g, '_') : this.generate_field_id(); + this.container_id += "_chzn"; + container_classes = ["chzn-container"]; + container_classes.push("chzn-container-" + (this.is_multiple ? "multi" : "single")); + if (this.inherit_select_classes && this.form_field.className) { + container_classes.push(this.form_field.className); + } + if (this.is_rtl) { + container_classes.push("chzn-rtl"); + } + container_props = { + 'id': this.container_id, + 'class': container_classes.join(' '), + 'style': "width: " + (this.container_width()) + ";", + 'title': this.form_field.title + }; + this.container = $("
    ", container_props); + if (this.is_multiple) { + this.container.html('
      '); + } else { + this.container.html('' + this.default_text + '
        '); + } + this.form_field_jq.hide().after(this.container); + this.dropdown = this.container.find('div.chzn-drop').first(); + this.search_field = this.container.find('input').first(); + this.search_results = this.container.find('ul.chzn-results').first(); + this.search_field_scale(); + this.search_no_results = this.container.find('li.no-results').first(); + if (this.is_multiple) { + this.search_choices = this.container.find('ul.chzn-choices').first(); + this.search_container = this.container.find('li.search-field').first(); + } else { + this.search_container = this.container.find('div.chzn-search').first(); + this.selected_item = this.container.find('.chzn-single').first(); + } + this.results_build(); + this.set_tab_index(); + this.set_label_behavior(); + return this.form_field_jq.trigger("liszt:ready", { + chosen: this + }); + }; + + Chosen.prototype.register_observers = function() { + var _this = this; + this.container.mousedown(function(evt) { + _this.container_mousedown(evt); + }); + this.container.mouseup(function(evt) { + _this.container_mouseup(evt); + }); + this.container.mouseenter(function(evt) { + _this.mouse_enter(evt); + }); + this.container.mouseleave(function(evt) { + _this.mouse_leave(evt); + }); + this.search_results.mouseup(function(evt) { + _this.search_results_mouseup(evt); + }); + this.search_results.mouseover(function(evt) { + _this.search_results_mouseover(evt); + }); + this.search_results.mouseout(function(evt) { + _this.search_results_mouseout(evt); + }); + this.search_results.bind('mousewheel DOMMouseScroll', function(evt) { + _this.search_results_mousewheel(evt); + }); + this.form_field_jq.bind("liszt:updated", function(evt) { + _this.results_update_field(evt); + }); + this.form_field_jq.bind("liszt:activate", function(evt) { + _this.activate_field(evt); + }); + this.form_field_jq.bind("liszt:open", function(evt) { + _this.container_mousedown(evt); + }); + this.search_field.blur(function(evt) { + _this.input_blur(evt); + }); + this.search_field.keyup(function(evt) { + _this.keyup_checker(evt); + }); + this.search_field.keydown(function(evt) { + _this.keydown_checker(evt); + }); + this.search_field.focus(function(evt) { + _this.input_focus(evt); + }); + if (this.is_multiple) { + return this.search_choices.click(function(evt) { + _this.choices_click(evt); + }); + } else { + return this.container.click(function(evt) { + evt.preventDefault(); + }); + } + }; + + Chosen.prototype.search_field_disabled = function() { + this.is_disabled = this.form_field_jq[0].disabled; + if (this.is_disabled) { + this.container.addClass('chzn-disabled'); + this.search_field[0].disabled = true; + if (!this.is_multiple) { + this.selected_item.unbind("focus", this.activate_action); + } + return this.close_field(); + } else { + this.container.removeClass('chzn-disabled'); + this.search_field[0].disabled = false; + if (!this.is_multiple) { + return this.selected_item.bind("focus", this.activate_action); + } + } + }; + + Chosen.prototype.container_mousedown = function(evt) { + if (!this.is_disabled) { + if (evt && evt.type === "mousedown" && !this.results_showing) { + evt.preventDefault(); + } + if (!((evt != null) && ($(evt.target)).hasClass("search-choice-close"))) { + if (!this.active_field) { + if (this.is_multiple) { + this.search_field.val(""); + } + $(document).click(this.click_test_action); + this.results_show(); + } else if (!this.is_multiple && evt && (($(evt.target)[0] === this.selected_item[0]) || $(evt.target).parents("a.chzn-single").length)) { + evt.preventDefault(); + this.results_toggle(); + } + return this.activate_field(); + } + } + }; + + Chosen.prototype.container_mouseup = function(evt) { + if (evt.target.nodeName === "ABBR" && !this.is_disabled) { + return this.results_reset(evt); + } + }; + + Chosen.prototype.search_results_mousewheel = function(evt) { + var delta, _ref, _ref1; + delta = -((_ref = evt.originalEvent) != null ? _ref.wheelDelta : void 0) || ((_ref1 = evt.originialEvent) != null ? _ref1.detail : void 0); + if (delta != null) { + evt.preventDefault(); + if (evt.type === 'DOMMouseScroll') { + delta = delta * 40; + } + return this.search_results.scrollTop(delta + this.search_results.scrollTop()); + } + }; + + Chosen.prototype.blur_test = function(evt) { + if (!this.active_field && this.container.hasClass("chzn-container-active")) { + return this.close_field(); + } + }; + + Chosen.prototype.close_field = function() { + $(document).unbind("click", this.click_test_action); + this.active_field = false; + this.results_hide(); + this.container.removeClass("chzn-container-active"); + this.winnow_results_clear(); + this.clear_backstroke(); + this.show_search_field_default(); + return this.search_field_scale(); + }; + + Chosen.prototype.activate_field = function() { + this.container.addClass("chzn-container-active"); + this.active_field = true; + this.search_field.val(this.search_field.val()); + return this.search_field.focus(); + }; + + Chosen.prototype.test_active_click = function(evt) { + if ($(evt.target).parents('#' + this.container_id).length) { + return this.active_field = true; + } else { + return this.close_field(); + } + }; + + Chosen.prototype.results_build = function() { + var content, data, _i, _len, _ref; + this.parsing = true; + this.results_data = root.SelectParser.select_to_array(this.form_field); + if (this.is_multiple && this.choices > 0) { + this.search_choices.find("li.search-choice").remove(); + this.choices = 0; + } else if (!this.is_multiple) { + this.selected_item.addClass("chzn-default").find("span").text(this.default_text); + if (this.disable_search || this.form_field.options.length <= this.disable_search_threshold) { + this.container.addClass("chzn-container-single-nosearch"); + } else { + this.container.removeClass("chzn-container-single-nosearch"); + } + } + content = ''; + _ref = this.results_data; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + data = _ref[_i]; + if (data.group) { + content += this.result_add_group(data); + } else if (!data.empty) { + content += this.result_add_option(data); + if (data.selected && this.is_multiple) { + this.choice_build(data); + } else if (data.selected && !this.is_multiple) { + this.selected_item.removeClass("chzn-default").find("span").text(data.text); + if (this.allow_single_deselect) { + this.single_deselect_control_build(); + } + } + } + } + this.search_field_disabled(); + this.show_search_field_default(); + this.search_field_scale(); + this.search_results.html(content); + return this.parsing = false; + }; + + Chosen.prototype.result_add_group = function(group) { + if (!group.disabled) { + group.dom_id = this.container_id + "_g_" + group.array_index; + return '
      • ' + $("
        ").text(group.label).html() + '
      • '; + } else { + return ""; + } + }; + + Chosen.prototype.result_do_highlight = function(el) { + var high_bottom, high_top, maxHeight, visible_bottom, visible_top; + if (el.length) { + this.result_clear_highlight(); + this.result_highlight = el; + this.result_highlight.addClass("highlighted"); + maxHeight = parseInt(this.search_results.css("maxHeight"), 10); + visible_top = this.search_results.scrollTop(); + visible_bottom = maxHeight + visible_top; + high_top = this.result_highlight.position().top + this.search_results.scrollTop(); + high_bottom = high_top + this.result_highlight.outerHeight(); + if (high_bottom >= visible_bottom) { + return this.search_results.scrollTop((high_bottom - maxHeight) > 0 ? high_bottom - maxHeight : 0); + } else if (high_top < visible_top) { + return this.search_results.scrollTop(high_top); + } + } + }; + + Chosen.prototype.result_clear_highlight = function() { + if (this.result_highlight) { + this.result_highlight.removeClass("highlighted"); + } + return this.result_highlight = null; + }; + + Chosen.prototype.results_show = function() { + if (this.result_single_selected != null) { + this.result_do_highlight(this.result_single_selected); + } else if (this.is_multiple && this.max_selected_options <= this.choices) { + this.form_field_jq.trigger("liszt:maxselected", { + chosen: this + }); + return false; + } + this.container.addClass("chzn-with-drop"); + this.form_field_jq.trigger("liszt:showing_dropdown", { + chosen: this + }); + this.results_showing = true; + this.search_field.focus(); + this.search_field.val(this.search_field.val()); + return this.winnow_results(); + }; + + Chosen.prototype.results_hide = function() { + this.result_clear_highlight(); + this.container.removeClass("chzn-with-drop"); + this.form_field_jq.trigger("liszt:hiding_dropdown", { + chosen: this + }); + return this.results_showing = false; + }; + + Chosen.prototype.set_tab_index = function(el) { + var ti; + if (this.form_field_jq.attr("tabindex")) { + ti = this.form_field_jq.attr("tabindex"); + this.form_field_jq.attr("tabindex", -1); + return this.search_field.attr("tabindex", ti); + } + }; + + Chosen.prototype.set_label_behavior = function() { + var _this = this; + this.form_field_label = this.form_field_jq.parents("label"); + if (!this.form_field_label.length && this.form_field.id.length) { + this.form_field_label = $("label[for=" + this.form_field.id + "]"); + } + if (this.form_field_label.length > 0) { + return this.form_field_label.click(function(evt) { + if (_this.is_multiple) { + return _this.container_mousedown(evt); + } else { + return _this.activate_field(); + } + }); + } + }; + + Chosen.prototype.show_search_field_default = function() { + if (this.is_multiple && this.choices < 1 && !this.active_field) { + this.search_field.val(this.default_text); + return this.search_field.addClass("default"); + } else { + this.search_field.val(""); + return this.search_field.removeClass("default"); + } + }; + + Chosen.prototype.search_results_mouseup = function(evt) { + var target; + target = $(evt.target).hasClass("active-result") ? $(evt.target) : $(evt.target).parents(".active-result").first(); + if (target.length) { + this.result_highlight = target; + this.result_select(evt); + return this.search_field.focus(); + } + }; + + Chosen.prototype.search_results_mouseover = function(evt) { + var target; + target = $(evt.target).hasClass("active-result") ? $(evt.target) : $(evt.target).parents(".active-result").first(); + if (target) { + return this.result_do_highlight(target); + } + }; + + Chosen.prototype.search_results_mouseout = function(evt) { + if ($(evt.target).hasClass("active-result" || $(evt.target).parents('.active-result').first())) { + return this.result_clear_highlight(); + } + }; + + Chosen.prototype.choice_build = function(item) { + var choice_id, html, link, + _this = this; + if (this.is_multiple && this.max_selected_options <= this.choices) { + this.form_field_jq.trigger("liszt:maxselected", { + chosen: this + }); + return false; + } + choice_id = this.container_id + "_c_" + item.array_index; + this.choices += 1; + if (item.disabled) { + html = '
      • ' + item.html + '
      • '; + } else { + html = '
      • ' + item.html + '
      • '; + } + this.search_container.before(html); + link = $('#' + choice_id).find("a").first(); + return link.click(function(evt) { + return _this.choice_destroy_link_click(evt); + }); + }; + + Chosen.prototype.choice_destroy_link_click = function(evt) { + evt.preventDefault(); + evt.stopPropagation(); + if (!this.is_disabled) { + return this.choice_destroy($(evt.target)); + } + }; + + Chosen.prototype.choice_destroy = function(link) { + if (this.result_deselect(link.attr("rel"))) { + this.choices -= 1; + this.show_search_field_default(); + if (this.is_multiple && this.choices > 0 && this.search_field.val().length < 1) { + this.results_hide(); + } + link.parents('li').first().remove(); + return this.search_field_scale(); + } + }; + + Chosen.prototype.results_reset = function() { + this.form_field.options[0].selected = true; + this.selected_item.find("span").text(this.default_text); + if (!this.is_multiple) { + this.selected_item.addClass("chzn-default"); + } + this.show_search_field_default(); + this.results_reset_cleanup(); + this.form_field_jq.trigger("change"); + if (this.active_field) { + return this.results_hide(); + } + }; + + Chosen.prototype.results_reset_cleanup = function() { + this.current_selectedIndex = this.form_field.selectedIndex; + return this.selected_item.find("abbr").remove(); + }; + + Chosen.prototype.result_select = function(evt) { + var high, high_id, item, position; + if (this.result_highlight) { + high = this.result_highlight; + high_id = high.attr("id"); + this.result_clear_highlight(); + if (this.is_multiple) { + this.result_deactivate(high); + } else { + this.search_results.find(".result-selected").removeClass("result-selected"); + this.result_single_selected = high; + this.selected_item.removeClass("chzn-default"); + } + high.addClass("result-selected"); + position = high_id.substr(high_id.lastIndexOf("_") + 1); + item = this.results_data[position]; + item.selected = true; + this.form_field.options[item.options_index].selected = true; + if (this.is_multiple) { + this.choice_build(item); + } else { + this.selected_item.find("span").first().text(item.text); + if (this.allow_single_deselect) { + this.single_deselect_control_build(); + } + } + if (!((evt.metaKey || evt.ctrlKey) && this.is_multiple)) { + this.results_hide(); + } + this.search_field.val(""); + if (this.is_multiple || this.form_field.selectedIndex !== this.current_selectedIndex) { + this.form_field_jq.trigger("change", { + 'selected': this.form_field.options[item.options_index].value + }); + } + this.current_selectedIndex = this.form_field.selectedIndex; + return this.search_field_scale(); + } + }; + + Chosen.prototype.result_activate = function(el) { + return el.addClass("active-result"); + }; + + Chosen.prototype.result_deactivate = function(el) { + return el.removeClass("active-result"); + }; + + Chosen.prototype.result_deselect = function(pos) { + var result, result_data; + result_data = this.results_data[pos]; + if (!this.form_field.options[result_data.options_index].disabled) { + result_data.selected = false; + this.form_field.options[result_data.options_index].selected = false; + result = $("#" + this.container_id + "_o_" + pos); + result.removeClass("result-selected").addClass("active-result").show(); + this.result_clear_highlight(); + this.winnow_results(); + this.form_field_jq.trigger("change", { + deselected: this.form_field.options[result_data.options_index].value + }); + this.search_field_scale(); + return true; + } else { + return false; + } + }; + + Chosen.prototype.single_deselect_control_build = function() { + if (this.allow_single_deselect && this.selected_item.find("abbr").length < 1) { + return this.selected_item.find("span").first().after(""); + } + }; + + Chosen.prototype.winnow_results = function() { + var found, option, part, parts, regex, regexAnchor, result, result_id, results, searchText, startpos, text, zregex, _i, _j, _len, _len1, _ref; + this.no_results_clear(); + results = 0; + searchText = this.search_field.val() === this.default_text ? "" : $('
        ').text($.trim(this.search_field.val())).html(); + regexAnchor = this.search_contains ? "" : "^"; + regex = new RegExp(regexAnchor + searchText.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"), 'i'); + zregex = new RegExp(searchText.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"), 'i'); + _ref = this.results_data; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + option = _ref[_i]; + if (!option.disabled && !option.empty) { + if (option.group) { + $('#' + option.dom_id).css('display', 'none'); + } else if (!(this.is_multiple && option.selected)) { + found = false; + result_id = option.dom_id; + result = $("#" + result_id); + if (regex.test(option.html)) { + found = true; + results += 1; + } else if (this.enable_split_word_search && (option.html.indexOf(" ") >= 0 || option.html.indexOf("[") === 0)) { + parts = option.html.replace(/\[|\]/g, "").split(" "); + if (parts.length) { + for (_j = 0, _len1 = parts.length; _j < _len1; _j++) { + part = parts[_j]; + if (regex.test(part)) { + found = true; + results += 1; + } + } + } + } + if (found) { + if (searchText.length) { + startpos = option.html.search(zregex); + text = option.html.substr(0, startpos + searchText.length) + '' + option.html.substr(startpos + searchText.length); + text = text.substr(0, startpos) + '' + text.substr(startpos); + } else { + text = option.html; + } + result.html(text); + this.result_activate(result); + if (option.group_array_index != null) { + $("#" + this.results_data[option.group_array_index].dom_id).css('display', 'list-item'); + } + } else { + if (this.result_highlight && result_id === this.result_highlight.attr('id')) { + this.result_clear_highlight(); + } + this.result_deactivate(result); + } + } + } + } + if (results < 1 && searchText.length) { + return this.no_results(searchText); + } else { + return this.winnow_results_set_highlight(); + } + }; + + Chosen.prototype.winnow_results_clear = function() { + var li, lis, _i, _len, _results; + this.search_field.val(""); + lis = this.search_results.find("li"); + _results = []; + for (_i = 0, _len = lis.length; _i < _len; _i++) { + li = lis[_i]; + li = $(li); + if (li.hasClass("group-result")) { + _results.push(li.css('display', 'auto')); + } else if (!this.is_multiple || !li.hasClass("result-selected")) { + _results.push(this.result_activate(li)); + } else { + _results.push(void 0); + } + } + return _results; + }; + + Chosen.prototype.winnow_results_set_highlight = function() { + var do_high, selected_results; + if (!this.result_highlight) { + selected_results = !this.is_multiple ? this.search_results.find(".result-selected.active-result") : []; + do_high = selected_results.length ? selected_results.first() : this.search_results.find(".active-result").first(); + if (do_high != null) { + return this.result_do_highlight(do_high); + } + } + }; + + Chosen.prototype.no_results = function(terms) { + var no_results_html; + no_results_html = $('
      • ' + this.results_none_found + ' ""
      • '); + no_results_html.find("span").first().html(terms); + return this.search_results.append(no_results_html); + }; + + Chosen.prototype.no_results_clear = function() { + return this.search_results.find(".no-results").remove(); + }; + + Chosen.prototype.keydown_arrow = function() { + var first_active, next_sib; + if (!this.result_highlight) { + first_active = this.search_results.find("li.active-result").first(); + if (first_active) { + this.result_do_highlight($(first_active)); + } + } else if (this.results_showing) { + next_sib = this.result_highlight.nextAll("li.active-result").first(); + if (next_sib) { + this.result_do_highlight(next_sib); + } + } + if (!this.results_showing) { + return this.results_show(); + } + }; + + Chosen.prototype.keyup_arrow = function() { + var prev_sibs; + if (!this.results_showing && !this.is_multiple) { + return this.results_show(); + } else if (this.result_highlight) { + prev_sibs = this.result_highlight.prevAll("li.active-result"); + if (prev_sibs.length) { + return this.result_do_highlight(prev_sibs.first()); + } else { + if (this.choices > 0) { + this.results_hide(); + } + return this.result_clear_highlight(); + } + } + }; + + Chosen.prototype.keydown_backstroke = function() { + var next_available_destroy; + if (this.pending_backstroke) { + this.choice_destroy(this.pending_backstroke.find("a").first()); + return this.clear_backstroke(); + } else { + next_available_destroy = this.search_container.siblings("li.search-choice").last(); + if (next_available_destroy.length && !next_available_destroy.hasClass("search-choice-disabled")) { + this.pending_backstroke = next_available_destroy; + if (this.single_backstroke_delete) { + return this.keydown_backstroke(); + } else { + return this.pending_backstroke.addClass("search-choice-focus"); + } + } + } + }; + + Chosen.prototype.clear_backstroke = function() { + if (this.pending_backstroke) { + this.pending_backstroke.removeClass("search-choice-focus"); + } + return this.pending_backstroke = null; + }; + + Chosen.prototype.keydown_checker = function(evt) { + var stroke, _ref; + stroke = (_ref = evt.which) != null ? _ref : evt.keyCode; + this.search_field_scale(); + if (stroke !== 8 && this.pending_backstroke) { + this.clear_backstroke(); + } + switch (stroke) { + case 8: + this.backstroke_length = this.search_field.val().length; + break; + case 9: + if (this.results_showing && !this.is_multiple) { + this.result_select(evt); + } + this.mouse_on_container = false; + break; + case 13: + evt.preventDefault(); + break; + case 38: + evt.preventDefault(); + this.keyup_arrow(); + break; + case 40: + this.keydown_arrow(); + break; + } + }; + + Chosen.prototype.search_field_scale = function() { + var div, h, style, style_block, styles, w, _i, _len; + if (this.is_multiple) { + h = 0; + w = 0; + style_block = "position:absolute; left: -1000px; top: -1000px; display:none;"; + styles = ['font-size', 'font-style', 'font-weight', 'font-family', 'line-height', 'text-transform', 'letter-spacing']; + for (_i = 0, _len = styles.length; _i < _len; _i++) { + style = styles[_i]; + style_block += style + ":" + this.search_field.css(style) + ";"; + } + div = $('
        ', { + 'style': style_block + }); + div.text(this.search_field.val()); + $('body').append(div); + w = div.width() + 25; + div.remove(); + if (!this.f_width) { + this.f_width = this.container.outerWidth(); + } + if (w > this.f_width - 10) { + w = this.f_width - 10; + } + return this.search_field.css({ + 'width': w + 'px' + }); + } + }; + + Chosen.prototype.generate_random_id = function() { + var string; + string = "sel" + this.generate_random_char() + this.generate_random_char() + this.generate_random_char(); + while ($("#" + string).length > 0) { + string += this.generate_random_char(); + } + return string; + }; + + return Chosen; + + })(AbstractChosen); + + root.Chosen = Chosen; + +}).call(this); diff --git a/resources/jquery.tipsy/images/tipsy.png b/resources/jquery.tipsy/images/tipsy.png index fef8c4b5..ef17cc32 100644 Binary files a/resources/jquery.tipsy/images/tipsy.png and b/resources/jquery.tipsy/images/tipsy.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-bg_flat_0_aaaaaa_40x100.png b/resources/jquery.ui/themes/default/images/ui-bg_flat_0_aaaaaa_40x100.png index 5b5dab2a..e425e6e4 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-bg_flat_0_aaaaaa_40x100.png and b/resources/jquery.ui/themes/default/images/ui-bg_flat_0_aaaaaa_40x100.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-bg_flat_75_ffffff_40x100.png b/resources/jquery.ui/themes/default/images/ui-bg_flat_75_ffffff_40x100.png index ac8b229a..72d47573 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-bg_flat_75_ffffff_40x100.png and b/resources/jquery.ui/themes/default/images/ui-bg_flat_75_ffffff_40x100.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-bg_glass_55_fbf9ee_1x400.png b/resources/jquery.ui/themes/default/images/ui-bg_glass_55_fbf9ee_1x400.png index ad3d6346..3b2914a2 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-bg_glass_55_fbf9ee_1x400.png and b/resources/jquery.ui/themes/default/images/ui-bg_glass_55_fbf9ee_1x400.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-bg_glass_65_ffffff_1x400.png b/resources/jquery.ui/themes/default/images/ui-bg_glass_65_ffffff_1x400.png index 42ccba26..8569c1bc 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-bg_glass_65_ffffff_1x400.png and b/resources/jquery.ui/themes/default/images/ui-bg_glass_65_ffffff_1x400.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-bg_glass_75_dadada_1x400.png b/resources/jquery.ui/themes/default/images/ui-bg_glass_75_dadada_1x400.png index 5a46b47c..d6cc3c58 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-bg_glass_75_dadada_1x400.png and b/resources/jquery.ui/themes/default/images/ui-bg_glass_75_dadada_1x400.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-bg_highlight-soft_75_cccccc_1x100.png b/resources/jquery.ui/themes/default/images/ui-bg_highlight-soft_75_cccccc_1x100.png index 7c9fa6c6..3cd467e1 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-bg_highlight-soft_75_cccccc_1x100.png and b/resources/jquery.ui/themes/default/images/ui-bg_highlight-soft_75_cccccc_1x100.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-icons_222222_256x240.png b/resources/jquery.ui/themes/default/images/ui-icons_222222_256x240.png index ee039dc0..9a9606f7 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-icons_222222_256x240.png and b/resources/jquery.ui/themes/default/images/ui-icons_222222_256x240.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-icons_2e83ff_256x240.png b/resources/jquery.ui/themes/default/images/ui-icons_2e83ff_256x240.png index 45e8928e..08d26179 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-icons_2e83ff_256x240.png and b/resources/jquery.ui/themes/default/images/ui-icons_2e83ff_256x240.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-icons_454545_256x240.png b/resources/jquery.ui/themes/default/images/ui-icons_454545_256x240.png index 7ec70d11..80cb644a 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-icons_454545_256x240.png and b/resources/jquery.ui/themes/default/images/ui-icons_454545_256x240.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-icons_888888_256x240.png b/resources/jquery.ui/themes/default/images/ui-icons_888888_256x240.png index 5ba708c3..8373712d 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-icons_888888_256x240.png and b/resources/jquery.ui/themes/default/images/ui-icons_888888_256x240.png differ diff --git a/resources/jquery.ui/themes/default/images/ui-icons_cd0a0a_256x240.png b/resources/jquery.ui/themes/default/images/ui-icons_cd0a0a_256x240.png index 7930a558..34fc8937 100644 Binary files a/resources/jquery.ui/themes/default/images/ui-icons_cd0a0a_256x240.png and b/resources/jquery.ui/themes/default/images/ui-icons_cd0a0a_256x240.png differ diff --git a/resources/jquery.ui/themes/vector/images/button-blue-hover-large.png b/resources/jquery.ui/themes/vector/images/button-blue-hover-large.png deleted file mode 100644 index 8f7cf74e..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-blue-hover-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-blue-hover.png b/resources/jquery.ui/themes/vector/images/button-blue-hover.png deleted file mode 100644 index 1fc28163..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-blue-hover.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-blue-large.png b/resources/jquery.ui/themes/vector/images/button-blue-large.png deleted file mode 100644 index 22ee5e59..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-blue-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-blue.png b/resources/jquery.ui/themes/vector/images/button-blue.png deleted file mode 100644 index 2e6d121a..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-blue.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-disabled-blue.png b/resources/jquery.ui/themes/vector/images/button-disabled-blue.png deleted file mode 100644 index 28eb1fcd..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-disabled-blue.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-disabled-green.png b/resources/jquery.ui/themes/vector/images/button-disabled-green.png deleted file mode 100644 index 0e29d85b..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-disabled-green.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-disabled-red.png b/resources/jquery.ui/themes/vector/images/button-disabled-red.png deleted file mode 100644 index ede69988..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-disabled-red.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-disabled.png b/resources/jquery.ui/themes/vector/images/button-disabled.png deleted file mode 100644 index e4e4ec1c..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-disabled.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-down-blue.png b/resources/jquery.ui/themes/vector/images/button-down-blue.png deleted file mode 100644 index 766e5746..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-down-blue.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-down-green.png b/resources/jquery.ui/themes/vector/images/button-down-green.png deleted file mode 100644 index 90969c39..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-down-green.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-down-red.png b/resources/jquery.ui/themes/vector/images/button-down-red.png deleted file mode 100644 index f6257298..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-down-red.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-down.png b/resources/jquery.ui/themes/vector/images/button-down.png deleted file mode 100644 index c6467571..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-down.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-green-hover-large.png b/resources/jquery.ui/themes/vector/images/button-green-hover-large.png deleted file mode 100644 index dd8851e1..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-green-hover-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-green-hover.png b/resources/jquery.ui/themes/vector/images/button-green-hover.png deleted file mode 100644 index 19c39911..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-green-hover.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-green-large.png b/resources/jquery.ui/themes/vector/images/button-green-large.png deleted file mode 100644 index a8e830eb..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-green-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-green.png b/resources/jquery.ui/themes/vector/images/button-green.png deleted file mode 100644 index 54c418e9..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-green.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-large-disabled-green.png b/resources/jquery.ui/themes/vector/images/button-large-disabled-green.png deleted file mode 100644 index f76f7b05..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-large-disabled-green.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-large-off-green.png b/resources/jquery.ui/themes/vector/images/button-large-off-green.png deleted file mode 100644 index f997431b..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-large-off-green.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-off-blue.png b/resources/jquery.ui/themes/vector/images/button-off-blue.png deleted file mode 100644 index 82dedb53..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-off-blue.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-off-green.png b/resources/jquery.ui/themes/vector/images/button-off-green.png deleted file mode 100644 index 109907f0..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-off-green.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-off-red.png b/resources/jquery.ui/themes/vector/images/button-off-red.png deleted file mode 100644 index 5a85b8aa..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-off-red.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-off.png b/resources/jquery.ui/themes/vector/images/button-off.png deleted file mode 100644 index cc5eb119..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-off.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-orange-hover-large.png b/resources/jquery.ui/themes/vector/images/button-orange-hover-large.png deleted file mode 100644 index 6f0dbd5d..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-orange-hover-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-orange-hover.png b/resources/jquery.ui/themes/vector/images/button-orange-hover.png deleted file mode 100644 index a1077c58..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-orange-hover.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-orange-large.png b/resources/jquery.ui/themes/vector/images/button-orange-large.png deleted file mode 100644 index 3d7f37f6..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-orange-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-orange.png b/resources/jquery.ui/themes/vector/images/button-orange.png deleted file mode 100644 index 02347cf9..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-orange.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-over-blue.png b/resources/jquery.ui/themes/vector/images/button-over-blue.png deleted file mode 100644 index 9edb7aa2..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-over-blue.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-over-green.png b/resources/jquery.ui/themes/vector/images/button-over-green.png deleted file mode 100644 index 47a0b1b8..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-over-green.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-over-red.png b/resources/jquery.ui/themes/vector/images/button-over-red.png deleted file mode 100644 index a2445365..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-over-red.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-over.png b/resources/jquery.ui/themes/vector/images/button-over.png deleted file mode 100644 index 558f1f80..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-over.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-red-hover-large.png b/resources/jquery.ui/themes/vector/images/button-red-hover-large.png deleted file mode 100644 index 11ccef06..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-red-hover-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-red-hover.png b/resources/jquery.ui/themes/vector/images/button-red-hover.png deleted file mode 100644 index 55a61743..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-red-hover.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-red-large.png b/resources/jquery.ui/themes/vector/images/button-red-large.png deleted file mode 100644 index 8d089efd..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-red-large.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/button-red.png b/resources/jquery.ui/themes/vector/images/button-red.png deleted file mode 100644 index 7a292fc1..00000000 Binary files a/resources/jquery.ui/themes/vector/images/button-red.png and /dev/null differ diff --git a/resources/jquery.ui/themes/vector/images/titlebar-fade.png b/resources/jquery.ui/themes/vector/images/titlebar-fade.png index f9fde8b3..12a80c88 100644 Binary files a/resources/jquery.ui/themes/vector/images/titlebar-fade.png and b/resources/jquery.ui/themes/vector/images/titlebar-fade.png differ diff --git a/resources/jquery.ui/themes/vector/jquery.ui.button.css b/resources/jquery.ui/themes/vector/jquery.ui.button.css index a6a1b544..ea14723f 100644 --- a/resources/jquery.ui/themes/vector/jquery.ui.button.css +++ b/resources/jquery.ui/themes/vector/jquery.ui.button.css @@ -12,23 +12,12 @@ zoom: 1; overflow: visible; /* the overflow property removes extra width in IE */ } -.ui-button-icon-only { - width: 2.2em; /* to make room for the icon, a width needs to be set here */ -} -button.ui-button-icon-only { - width: 2.4em; /* button elements seem to need a little more width */ -} -.ui-button-icons-only { - width: 3.4em; -} -button.ui-button-icons-only { - width: 3.7em; -} /*button text element */ .ui-button .ui-button-text { display: block; line-height: 1.4; + text-shadow: 0 1px 1px #fff; } .ui-button-text-only .ui-button-text { padding: 0.3em 1em 0.25em 1em; @@ -90,7 +79,7 @@ input.ui-button { } .ui-buttonset .ui-button { margin-left: 0; - margin-right: -.3em; + margin-right: -.4em; } /* workarounds */ @@ -98,17 +87,21 @@ button.ui-button::-moz-focus-inner { border: 0; padding: 0; /* reset extra padding in Firefox */ } - -body .ui-button { - margin: 0.5em 0 0.5em 0.4em; - border: 1px solid #a6a6a6 !important; +/* Disables the annoying dashed border Firefox puts on active buttons */ +body button.ui-button::-moz-focus-inner { + border: 0; +} +/* Give large buttons some extra padding */ +body .ui-button-large { + padding: 5px; +} +/* Use white icons for colored buttons */ +.ui-button-green .ui-icon, +.ui-button-blue .ui-icon, +.ui-button-red .ui-icon, +.ui-button-orange .ui-icon { /* @embed */ - background: #f2f2f2 url(images/button-off.png) repeat-x scroll 50% 100% !important; - cursor: pointer; - font-size: 1em; - line-height: 1.4em; - width: auto; - overflow: visible; + background-image: url(images/ui-icons_ffffff_256x240.png) !important; } /* Corner radius */ @@ -124,6 +117,7 @@ body .ui-button { } .ui-button.ui-corner-all, .ui-button.ui-corner-top, + .ui-button.ui-corner-right, .ui-button.ui-corner-tr { -moz-border-radius-topright: 4px; @@ -147,145 +141,239 @@ body .ui-button { border-bottom-right-radius: 4px; } -body .ui-button:hover { - border-color: #6e7273; - /* @embed */ - background: #e1e1e1 url(images/button-over.png) repeat-x scroll 50% 100% !important; -} -body .ui-button:active, -body .ui-button:focus { - border-color: #707271; - /* @embed */ - background: #bfbfbf url(images/button-down.png) repeat-x scroll 50% 100% !important; +body .ui-button { + color: #2779aa; + margin: 0.5em 0 0.5em 0.4em; + border: 1px solid #aaa !important; + background: #f0f0f0 !important; + background: -moz-linear-gradient(top, #fff 0%, #ddd 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #fff 0%, #ddd 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #fff 0%, #ddd 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #fff 0%, #ddd 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #fff 0%, #ddd 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#dddddd', GradientType=0); /* IE6-8 */ + cursor: pointer; + font-size: 1em; + line-height: 1.4em; + width: auto; + overflow: visible; + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,.2); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,.2); + box-shadow: 0 1px 3px rgba(0,0,0,.2); } -body .ui-button.disabled { - color: #7f7f7f; - border-color: #cccccc; - /* @embed */ - background: #f2f2f2 url(images/button-disabled.png) repeat-x scroll 50% 100% !important; + +body .ui-button-icon-only { + width: 2.2em; } -/* Disables the annoying dashed border Firefox puts on active buttons */ -body button.ui-button::-moz-focus-inner { - border: 0; + +body .ui-button-icons-only { + width: 3.4em; } -/* Give large buttons some extra padding */ -body .ui-button-large { - padding: 5px; + +body .ui-button:hover { + color: #2779aa; + border-color: #bbb !important; + background: #fff !important; + background: -moz-linear-gradient(top, #fff 0%, #eee 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #fff 0%, #eee 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #fff 0%, #eee 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #fff 0%, #eee 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #fff 0%, #eee 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#eeeeee', GradientType=0); /* IE6-8 */ + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,.1); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,.1); + box-shadow: 0 1px 3px rgba(0,0,0,.1); } -/* Use white icons for colored buttons */ -.ui-button-green .ui-icon, .ui-button-blue .ui-icon, .ui-button-red .ui-icon, .ui-button-orange .ui-icon { - /* @embed */ - background-image: url(images/ui-icons_ffffff_256x240.png) !important; +body .ui-button:active, +body .ui-button:focus { + border-color: #8ad !important; + -webkit-box-shadow: 0 0 1px 1px rgba(167,215,249,.5); + -moz-box-shadow: 0 0 1px 1px rgba(167,215,249,.5); + box-shadow: 0 0 1px 1px rgba(167,215,249,.5); +} +body .ui-button:active { + background: #e0e0e0 !important; + background: -moz-linear-gradient(top, #f0f0f0 0%, #d0d0d0 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #f0f0f0 0%, #d0d0d0 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #f0f0f0 0%, #d0d0d0 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #f0f0f0 0%, #d0d0d0 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #f0f0f0 0%, #d0d0d0 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#f0f0f0', endColorstr='#d0d0d0', GradientType=0); /* IE6-8 */ } /* Green buttons */ - +body .ui-button-green, +body .ui-button-green .ui-button-text { + color: white; + text-shadow: 0 -1px 1px #072; +} body .ui-button.ui-button-green { - color: white !important; - border-color: #97af7e !important; - /* @embed */ - background: #3cb677 url(images/button-green.png) repeat-x scroll 50% 100% !important; + border-color: #294 !important; + background: #295 !important; + background: -moz-linear-gradient(top, #3c8 0%, #295 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #3c8 0%, #295 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #3c8 0%, #295 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #3c8 0%, #295 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #3c8 0%, #295 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#33cc88', endColorstr='#229955', GradientType=0); /* IE6-8 */ + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,.3); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,.3); + box-shadow: 0 1px 3px rgba(0,0,0,.3); } body .ui-button.ui-button-green:hover { - border-color: #778e61 !important; - /* @embed */ - background: #339b65 url(images/button-green-hover.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-green.ui-button-large { - /* @embed */ - background: #3cb677 url(images/button-green-large.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-green.ui-button-large:hover { - /* @embed */ - background: #339b65 url(images/button-green-hover-large.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-green.disabled { - filter:alpha(opacity=50); - -moz-opacity:0.50; - -khtml-opacity: 0.50; - opacity: 0.50; + background: #33a055 !important; + background: -moz-linear-gradient(top, #44d388 0%, #33a055 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #44d388 0%, #33a055 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #44d388 0%, #33a055 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #44d388 0%, #33a055 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #44d388 0%, #33a055 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#44d388', endColorstr='#33a055', GradientType=0); /* IE6-8 */ + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,.25); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,.25); + box-shadow: 0 1px 3px rgba(0,0,0,.25); +} +body .ui-button.ui-button-green:active, +body .ui-button.ui-button-green:focus { + border-color: #172 !important; + -webkit-box-shadow: 0 0 2px 2px rgba(167,215,249,.75); + -moz-box-shadow: 0 0 2px 2px rgba(167,215,249,.75); + box-shadow: 0 0 2px 2px rgba(167,215,249,.75); +} +body .ui-button.ui-button-green:active { + background: #338855 !important; + background: -moz-linear-gradient(top, #30c080 0%, #338855 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #30c080 0%, #338855 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #30c080 0%, #338855 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #30c080 0%, #338855 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #30c080 0%, #338855 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#30c080', endColorstr='#338855', GradientType=0); /* IE6-8 */ } /* Blue buttons */ - +body .ui-button-blue, +body .ui-button-blue .ui-button-text { + color: white; + text-shadow: 0 -1px 1px #037; +} body .ui-button.ui-button-blue { - color: white !important; - border-color: #628acb !important; - /* @embed */ - background: #3365ba url(images/button-blue.png) repeat-x scroll 50% 100% !important; + border-color: #468 !important; + background: #36b !important; + background: -moz-linear-gradient(top, #48e 0%, #36b 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #48e 0%, #36b 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #48e 0%, #36b 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #48e 0%, #36b 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #48e 0%, #36b 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#4488ee', endColorstr='#3366bb', GradientType=0); /* IE6-8 */ + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,.35); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,.35); + box-shadow: 0 1px 3px rgba(0,0,0,.35); } body .ui-button.ui-button-blue:hover { - border-color: #5375ad !important; - /* @embed */ - background: #2b569e url(images/button-blue-hover.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-blue.ui-button-large { - /* @embed */ - background: #3365ba url(images/button-blue-large.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-blue.ui-button-large:hover { - /* @embed */ - background: #2b569e url(images/button-blue-hover-large.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-blue.disabled { - filter:alpha(opacity=50); - -moz-opacity:0.50; - -khtml-opacity: 0.50; - opacity: 0.50; + background: #36c !important; + background: -moz-linear-gradient(top, #59e 0%, #36c 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #59e 0%, #36c 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #59e 0%, #36c 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #59e 0%, #36c 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #59e 0%, #36c 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#5599ee', endColorstr='#3366cc', GradientType=0); /* IE6-8 */ +} +body .ui-button.ui-button-blue:active, +body .ui-button.ui-button-blue:focus { + border-color: #357 !important; + -webkit-box-shadow: 0 0 2px 2px rgba(167,215,249,.75); + -moz-box-shadow: 0 0 2px 2px rgba(167,215,249,.75); + box-shadow: 0 0 2px 2px rgba(167,215,249,.75); +} +body .ui-button.ui-button-blue:active { + background: #3060a0 !important; + background: -moz-linear-gradient(top, #4080e0 0%, #3060a0 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #4080e0 0%, #3060a0 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #4080e0 0%, #3060a0 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #4080e0 0%, #3060a0 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #4080e0 0%, #3060a0 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#4080e0', endColorstr='#3060a0', GradientType=0); /* IE6-8 */ } /* Red buttons */ - +body .ui-button-red, +body .ui-button-red .ui-button-text { + color: white; + text-shadow: 0 -1px 1px #700; +} body .ui-button.ui-button-red { - color: white !important; - border-color: #af977e !important; - /* @embed */ - background: #cb0000 url(images/button-red.png) repeat-x scroll 50% 100% !important; + border-color: #944 !important; + background: #a22 !important; + background: -moz-linear-gradient(top, #d44 0%, #a22 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #d44 0%, #a22 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #d44 0%, #a22 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #d44 0%, #a22 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #d44 0%, #a22 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#dd4444', endColorstr='#aa2222', GradientType=0); /* IE6-8 */ + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,.35); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,.35); + box-shadow: 0 1px 3px rgba(0,0,0,.35); } body .ui-button.ui-button-red:hover { - border-color: #8e7761 !important; - /* @embed */ - background: #ad0000 url(images/button-red-hover.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-red.ui-button-large { - /* @embed */ - background: #cb0000 url(images/button-red.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-red.ui-button-large:hover { - /* @embed */ - background: #ad0000 url(images/button-red-hover.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-red.disabled { - filter:alpha(opacity=50); - -moz-opacity:0.50; - -khtml-opacity: 0.50; - opacity: 0.50; + border-color: #a44 !important; + background: #b03333 !important; + background: -moz-linear-gradient(top, #ee4646 0%, #b03333 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #ee4646 0%, #b03333 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #ee4646 0%, #b03333 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #ee4646 0%, #b03333 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #ee4646 0%, #b03333 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ee4646', endColorstr='#b03333', GradientType=0); /* IE6-8 */ + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,.3); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,.3); + box-shadow: 0 1px 3px rgba(0,0,0,.3); +} +body .ui-button.ui-button-red:active, +body .ui-button.ui-button-red:focus { + border-color: #747 !important; + -webkit-box-shadow: 0 0 2px 2px rgba(167,215,249,.7); + -moz-box-shadow: 0 0 2px 2px rgba(167,215,249,.7); + box-shadow: 0 0 2px 2px rgba(167,215,249,.7); +} +body .ui-button.ui-button-red:active { + background: #952020 !important; + background: -moz-linear-gradient(top, #d04545 0%, #952020 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #d04545 0%, #952020 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #d04545 0%, #952020 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #d04545 0%, #952020 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #d04545 0%, #952020 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#d04545', endColorstr='#952020', GradientType=0); /* IE6-8 */ } -/* Orange buttons */ - -body .ui-button.ui-button-orange { - color: white !important; - border-color: #f3a863 !important; - /* @embed */ - background: #f07f14 url(images/button-orange.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-orange:hover { - border-color: #ce9055 !important; - /* @embed */ - background: #cc6c11 url(images/button-orange-hover.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-orange.ui-button-large { - /* @embed */ - background: #f07f14 url(images/button-orange-large.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-orange.ui-button-large:hover { - /* @embed */ - background: #cc6c11 url(images/button-orange-hover-large.png) repeat-x scroll 50% 100% !important; -} -body .ui-button.ui-button-orange.disabled { - filter:alpha(opacity=50); - -moz-opacity:0.50; - -khtml-opacity: 0.50; - opacity: 0.50; +/* Disabled buttons */ +body .ui-button-green.disabled, +body .ui-button-green.disabled:hover, +body .ui-button-green.disabled:active, +body .ui-button-green.disabled:focus, +body .ui-button-blue.disabled, +body .ui-button-blue.disabled:hover, +body .ui-button-blue.disabled:active, +body .ui-button-blue.disabled:focus, +body .ui-button-red.disabled, +body .ui-button-red.disabled:hover, +body .ui-button-red.disabled:active, +body .ui-button-red.disabled:focus, +body .ui-button.disabled, +body .ui-button.disabled:hover { + color: #aaa; + border-color: #ccc !important; + background: #eee !important; + background: -moz-linear-gradient(top, #f6f6f6 0%, #eee 90%) !important; /* FF3.6+ */ + background: -webkit-linear-gradient(top, #f6f6f6 0%, #eee 90%) !important; /* Chrome10+, Safari5.1+ */ + background: -o-linear-gradient(top, #f6f6f6 0%, #eee 90%) !important; /* Opera 11.10+ */ + background: -ms-linear-gradient(top, #f6f6f6 0%, #eee 90%) !important; /* IE10+ */ + background: linear-gradient(to bottom, #f6f6f6 0%, #eee 90%) !important; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#f6f6f6', endColorstr='#eeeeee', GradientType=0); /* IE6-8 */ + -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0); + -moz-box-shadow: 0 1px 3px rgba(0,0,0,0); + box-shadow: 0 1px 3px rgba(0,0,0,0); +} +body .ui-button-green.disabled .ui-button-text, +body .ui-button-blue.disabled .ui-button-text, +body .ui-button-red.disabled .ui-button-text { + color: #aaa; + text-shadow: 0 1px 1px #fff; } diff --git a/resources/jquery/images/jquery.arrowSteps.divider-ltr.png b/resources/jquery/images/jquery.arrowSteps.divider-ltr.png index 83d6ff84..84ed2a2d 100644 Binary files a/resources/jquery/images/jquery.arrowSteps.divider-ltr.png and b/resources/jquery/images/jquery.arrowSteps.divider-ltr.png differ diff --git a/resources/jquery/images/jquery.arrowSteps.divider-rtl.png b/resources/jquery/images/jquery.arrowSteps.divider-rtl.png index 529d7b84..7cfbfeba 100644 Binary files a/resources/jquery/images/jquery.arrowSteps.divider-rtl.png and b/resources/jquery/images/jquery.arrowSteps.divider-rtl.png differ diff --git a/resources/jquery/images/jquery.arrowSteps.head-ltr.png b/resources/jquery/images/jquery.arrowSteps.head-ltr.png index 3289617d..eb070280 100644 Binary files a/resources/jquery/images/jquery.arrowSteps.head-ltr.png and b/resources/jquery/images/jquery.arrowSteps.head-ltr.png differ diff --git a/resources/jquery/images/jquery.arrowSteps.head-rtl.png b/resources/jquery/images/jquery.arrowSteps.head-rtl.png index 3d9f70cb..7ea2fdb5 100644 Binary files a/resources/jquery/images/jquery.arrowSteps.head-rtl.png and b/resources/jquery/images/jquery.arrowSteps.head-rtl.png differ diff --git a/resources/jquery/images/jquery.arrowSteps.tail-ltr.png b/resources/jquery/images/jquery.arrowSteps.tail-ltr.png index 92b872b2..3ad990b6 100644 Binary files a/resources/jquery/images/jquery.arrowSteps.tail-ltr.png and b/resources/jquery/images/jquery.arrowSteps.tail-ltr.png differ diff --git a/resources/jquery/images/marker.png b/resources/jquery/images/marker.png index 3929bbb5..19efb6ce 100644 Binary files a/resources/jquery/images/marker.png and b/resources/jquery/images/marker.png differ diff --git a/resources/jquery/images/mask.png b/resources/jquery/images/mask.png index b0a4d406..fe08de0e 100644 Binary files a/resources/jquery/images/mask.png and b/resources/jquery/images/mask.png differ diff --git a/resources/jquery/jquery.badge.css b/resources/jquery/jquery.badge.css index d961bf3d..f313663e 100644 --- a/resources/jquery/jquery.badge.css +++ b/resources/jquery/jquery.badge.css @@ -1,13 +1,12 @@ .mw-badge { min-width: 7px; - -moz-border-radius: 2px; - -webkit-border-radius: 2px; border-radius: 2px; padding: 1px 4px; text-align: center; font-size: 12px; line-height: 12px; background-color: #d2d2d2; + cursor: pointer; } .mw-badge-content { @@ -18,8 +17,12 @@ } .mw-badge-inline { - display: inline-block; margin-left: 3px; + display: inline-block; + /* Hack for IE6 and IE7 (bug 47926) */ + zoom: 1; + *display: inline; + } .mw-badge-overlay { position: absolute; diff --git a/resources/jquery/jquery.byteLength.js b/resources/jquery/jquery.byteLength.js index 3d5b7206..398937e6 100644 --- a/resources/jquery/jquery.byteLength.js +++ b/resources/jquery/jquery.byteLength.js @@ -4,6 +4,8 @@ * Calculate the byte length of a string (accounting for UTF-8). * * @author Jan Paul Posma, 2011 + * @author Timo Tijhof, 2012 + * @author David Chan, 2013 */ jQuery.byteLength = function ( str ) { @@ -12,8 +14,18 @@ jQuery.byteLength = function ( str ) { // Note, surrogate (\uD800-\uDFFF) characters are counted as 2 bytes, since there's two of them // and the actual character takes 4 bytes in UTF-8 (2*2=4). Might not work perfectly in // edge cases such as illegal sequences, but that should never happen. + + // https://en.wikipedia.org/wiki/UTF-8#Description + // The mapping from UTF-16 code units to UTF-8 bytes is as follows: + // > Range 0000-007F: codepoints that become 1 byte of UTF-8 + // > Range 0080-07FF: codepoints that become 2 bytes of UTF-8 + // > Range 0800-D7FF: codepoints that become 3 bytes of UTF-8 + // > Range D800-DFFF: Surrogates (each pair becomes 4 bytes of UTF-8) + // > Range E000-FFFF: codepoints that become 3 bytes of UTF-8 (continued) + return str .replace( /[\u0080-\u07FF\uD800-\uDFFF]/g, '**' ) .replace( /[\u0800-\uD7FF\uE000-\uFFFF]/g, '***' ) .length; + }; diff --git a/resources/jquery/jquery.byteLimit.js b/resources/jquery/jquery.byteLimit.js index f2b98f09..a8c0b065 100644 --- a/resources/jquery/jquery.byteLimit.js +++ b/resources/jquery/jquery.byteLimit.js @@ -78,7 +78,8 @@ // Chop off characters from the end of the "inserted content" string // until the limit is statisfied. if ( fn ) { - while ( $.byteLength( fn( inpParts.join( '' ) ) ) > byteLimit ) { + // stop, when there is nothing to slice - bug 41450 + while ( $.byteLength( fn( inpParts.join( '' ) ) ) > byteLimit && inpParts[1].length > 0 ) { inpParts[1] = inpParts[1].slice( 0, -1 ); } } else { diff --git a/resources/jquery/jquery.checkboxShiftClick.js b/resources/jquery/jquery.checkboxShiftClick.js index aced0633..b2065665 100644 --- a/resources/jquery/jquery.checkboxShiftClick.js +++ b/resources/jquery/jquery.checkboxShiftClick.js @@ -15,11 +15,17 @@ $box.click( function ( e ) { // And one has been clicked before... if ( prevCheckbox !== null && e.shiftKey ) { - // Check or uncheck this one and all in-between checkboxes - $box.slice( - Math.min( $box.index( prevCheckbox ), $box.index( e.target ) ), - Math.max( $box.index( prevCheckbox ), $box.index( e.target ) ) + 1 - ).prop( 'checked', !!e.target.checked ); + // Check or uncheck this one and all in-between checkboxes, + // except for disabled ones + $box + .slice( + Math.min( $box.index( prevCheckbox ), $box.index( e.target ) ), + Math.max( $box.index( prevCheckbox ), $box.index( e.target ) ) + 1 + ) + .filter( function () { + return !this.disabled; + } ) + .prop( 'checked', !!e.target.checked ); } // Either way, update the prevCheckbox variable to the one clicked now prevCheckbox = e.target; diff --git a/resources/jquery/jquery.client.js b/resources/jquery/jquery.client.js index b0bd6850..5a95dc5b 100644 --- a/resources/jquery/jquery.client.js +++ b/resources/jquery/jquery.client.js @@ -6,7 +6,7 @@ /* Private Members */ /** - * @var profileCache {Object} Keyed by userAgent string, + * @var {Object} profileCache Keyed by userAgent string, * value is the parsed $.client.profile object for that user agent. */ var profileCache = {}; @@ -18,9 +18,9 @@ /** * Get an object containing information about the client. * - * @param nav {Object} An object with atleast a 'userAgent' and 'platform' key. + * @param {Object} nav An object with atleast a 'userAgent' and 'platform' key. * Defaults to the global Navigator object. - * @return {Object} The resulting client object will be in the following format: + * @returns {Object} The resulting client object will be in the following format: * { * 'name': 'firefox', * 'layout': 'gecko', @@ -50,47 +50,47 @@ // Generic version digit x = 'x', // Strings found in user agent strings that need to be conformed - wildUserAgents = ['Opera', 'Navigator', 'Minefield', 'KHTML', 'Chrome', 'PLAYSTATION 3'], + wildUserAgents = ['Opera', 'Navigator', 'Minefield', 'KHTML', 'Chrome', 'PLAYSTATION 3', 'Iceweasel'], // Translations for conforming user agent strings userAgentTranslations = [ // Tons of browsers lie about being something they are not - [/(Firefox|MSIE|KHTML,\slike\sGecko|Konqueror)/, ''], + [/(Firefox|MSIE|KHTML,?\slike\sGecko|Konqueror)/, ''], // Chrome lives in the shadow of Safari still ['Chrome Safari', 'Chrome'], // KHTML is the layout engine not the browser - LIES! ['KHTML', 'Konqueror'], // Firefox nightly builds ['Minefield', 'Firefox'], - // This helps keep differnt versions consistent + // This helps keep different versions consistent ['Navigator', 'Netscape'], // This prevents version extraction issues, otherwise translation would happen later ['PLAYSTATION 3', 'PS3'] ], - // Strings which precede a version number in a user agent string - combined and used as match 1 in - // version detectection + // Strings which precede a version number in a user agent string - combined and used as + // match 1 in version detection versionPrefixes = [ 'camino', 'chrome', 'firefox', 'iceweasel', 'netscape', 'netscape6', 'opera', 'version', 'konqueror', - 'lynx', 'msie', 'safari', 'ps3' + 'lynx', 'msie', 'safari', 'ps3', 'android' ], // Used as matches 2, 3 and 4 in version extraction - 3 is used as actual version number versionSuffix = '(\\/|\\;?\\s|)([a-z0-9\\.\\+]*?)(\\;|dev|rel|\\)|\\s|$)', // Names of known browsers names = [ 'camino', 'chrome', 'firefox', 'iceweasel', 'netscape', 'konqueror', 'lynx', 'msie', 'opera', - 'safari', 'ipod', 'iphone', 'blackberry', 'ps3', 'rekonq' + 'safari', 'ipod', 'iphone', 'blackberry', 'ps3', 'rekonq', 'android' ], // Tanslations for conforming browser names nameTranslations = [], // Names of known layout engines - layouts = ['gecko', 'konqueror', 'msie', 'opera', 'webkit'], + layouts = ['gecko', 'konqueror', 'msie', 'trident', 'opera', 'webkit'], // Translations for conforming layout names layoutTranslations = [ ['konqueror', 'khtml'], ['msie', 'trident'], ['opera', 'presto'] ], // Names of supported layout engines for version number - layoutVersions = ['applewebkit', 'gecko'], + layoutVersions = ['applewebkit', 'gecko', 'trident'], // Names of known operating systems - platforms = ['win', 'mac', 'linux', 'sunos', 'solaris', 'iphone'], + platforms = ['win', 'wow64', 'mac', 'linux', 'sunos', 'solaris', 'iphone'], // Translations for conforming operating system names - platformTranslations = [ ['sunos', 'solaris'] ], + platformTranslations = [ ['sunos', 'solaris'], ['wow64', 'win'] ], /* Methods */ @@ -143,18 +143,33 @@ /* Edge Cases -- did I mention about how user agent string lie? */ // Decode Safari's crazy 400+ version numbers - if ( name.match( /safari/ ) && version > 400 ) { + if ( name === 'safari' && version > 400 ) { version = '2.0'; } // Expose Opera 10's lies about being Opera 9.8 - if ( name === 'opera' && version >= 9.8) { - match = ua.match( /version\/([0-9\.]*)/i ); + if ( name === 'opera' && version >= 9.8 ) { + match = ua.match( /\bversion\/([0-9\.]*)/ ); if ( match && match[1] ) { version = match[1]; } else { version = '10'; } } + // And Opera 15's lies about being Chrome + if ( name === 'chrome' && ( match = ua.match( /\bopr\/([0-9\.]*)/ ) ) ) { + if ( match[1] ) { + name = 'opera'; + version = match[1]; + } + } + // And IE 11's lies about being not being IE + if ( layout === 'trident' && layoutversion >= 7 && ( match = ua.match( /\brv[ :\/]([0-9\.]*)/ ) ) ) { + if ( match[1] ) { + name = 'msie'; + version = match[1]; + } + } + versionNumber = parseFloat( version, 10 ) || 0.0; /* Caching */ @@ -173,46 +188,61 @@ }, /** - * Checks the current browser against a support map object to determine if the browser has been black-listed or - * not. If the browser was not configured specifically it is assumed to work. It is assumed that the body - * element is classified as either "ltr" or "rtl". If neither is set, "ltr" is assumed. + * Checks the current browser against a support map object. * * A browser map is in the following format: * { + * // Multiple rules with configurable operators + * 'msie': [['>=', 7], ['!=', 9]], + * // Match no versions + * 'iphone': false, + * // Match any version + * 'android': null + * } + * + * It can optionally be split into ltr/rtl sections: + * { * 'ltr': { - * // Multiple rules with configurable operators - * 'msie': [['>=', 7], ['!=', 9]], - * // Blocked entirely + * 'android': null, * 'iphone': false * }, * 'rtl': { - * // Test against a string - * 'msie': [['!==', '8.1.2.3']], - * // RTL rules do not fall through to LTR rules, you must explicity set each of them + * 'android': false, + * // rules are not inherited from ltr * 'iphone': false * } * } * - * @param map {Object} Browser support map - * @param profile {Object} (optional) a client-profile object. + * @param {Object} map Browser support map + * @param {Object} [profile] A client-profile object + * @param {boolean} [exactMatchOnly=false] Only return true if the browser is matched, otherwise + * returns true if the browser is not found. * - * @return Boolean true if browser known or assumed to be supported, false if blacklisted + * @returns {boolean} The current browser is in the support map */ - test: function ( map, profile ) { + test: function ( map, profile, exactMatchOnly ) { /*jshint evil: true */ var conditions, dir, i, op, val; profile = $.isPlainObject( profile ) ? profile : $.client.profile(); - dir = $( 'body' ).is( '.rtl' ) ? 'rtl' : 'ltr'; + if ( map.ltr && map.rtl ) { + dir = $( 'body' ).is( '.rtl' ) ? 'rtl' : 'ltr'; + map = map[dir]; + } // Check over each browser condition to determine if we are running in a compatible client - if ( typeof map[dir] !== 'object' || map[dir][profile.name] === undefined ) { - // Unknown, so we assume it's working - return true; + if ( typeof map !== 'object' || map[profile.name] === undefined ) { + // Not found, return true if exactMatchOnly not set, false otherwise + return !exactMatchOnly; } - conditions = map[dir][profile.name]; + conditions = map[profile.name]; if ( conditions === false ) { + // Match no versions return false; } + if ( conditions === null ) { + // Match all versions + return true; + } for ( i = 0; i < conditions.length; i++ ) { op = conditions[i][0]; val = conditions[i][1]; diff --git a/resources/jquery/jquery.makeCollapsible.js b/resources/jquery/jquery.makeCollapsible.js index 1407f53b..0cd6417c 100644 --- a/resources/jquery/jquery.makeCollapsible.js +++ b/resources/jquery/jquery.makeCollapsible.js @@ -18,13 +18,15 @@ var lpx = 'jquery.makeCollapsible> '; /** + * Handler for a click on a collapsible toggler. + * * @param {jQuery} $collapsible * @param {string} action The action this function will take ('expand' or 'collapse'). * @param {jQuery|null} [optional] $defaultToggle * @param {Object|undefined} options */ function toggleElement( $collapsible, action, $defaultToggle, options ) { - var $collapsibleContent, $containers; + var $collapsibleContent, $containers, hookCallback; options = options || {}; // Validate parameters @@ -47,6 +49,14 @@ return; } + // Trigger a custom event to allow callers to hook to the collapsing/expanding, + // allowing the module to be testable, and making it possible to + // e.g. implement persistence via cookies + $collapsible.trigger( action === 'expand' ? 'beforeExpand.mw-collapsible' : 'beforeCollapse.mw-collapsible' ); + hookCallback = function () { + $collapsible.trigger( action === 'expand' ? 'afterExpand.mw-collapsible' : 'afterCollapse.mw-collapsible' ); + }; + // Handle different kinds of elements if ( !options.plainMode && $collapsible.is( 'table' ) ) { @@ -63,11 +73,12 @@ // http://stackoverflow.com/questions/467336#920480 if ( options.instantHide ) { $containers.hide(); + hookCallback(); } else { - $containers.stop( true, true ).fadeOut(); + $containers.stop( true, true ).fadeOut().promise().done( hookCallback ); } } else { - $containers.stop( true, true ).fadeIn(); + $containers.stop( true, true ).fadeIn().promise().done( hookCallback ); } } else if ( !options.plainMode && ( $collapsible.is( 'ul' ) || $collapsible.is( 'ol' ) ) ) { @@ -81,11 +92,12 @@ if ( action === 'collapse' ) { if ( options.instantHide ) { $containers.hide(); + hookCallback(); } else { - $containers.stop( true, true ).slideUp(); + $containers.stop( true, true ).slideUp().promise().done( hookCallback ); } } else { - $containers.stop( true, true ).slideDown(); + $containers.stop( true, true ).slideDown().promise().done( hookCallback ); } } else { @@ -97,11 +109,12 @@ if ( action === 'collapse' ) { if ( options.instantHide ) { $collapsibleContent.hide(); + hookCallback(); } else { - $collapsibleContent.slideUp(); + $collapsibleContent.slideUp().promise().done( hookCallback ); } } else { - $collapsibleContent.slideDown(); + $collapsibleContent.slideDown().promise().done( hookCallback ); } // Otherwise assume this is a customcollapse with a remote toggle @@ -110,18 +123,19 @@ if ( action === 'collapse' ) { if ( options.instantHide ) { $collapsible.hide(); + hookCallback(); } else { if ( $collapsible.is( 'tr' ) || $collapsible.is( 'td' ) || $collapsible.is( 'th' ) ) { - $collapsible.fadeOut(); + $collapsible.fadeOut().promise().done( hookCallback ); } else { - $collapsible.slideUp(); + $collapsible.slideUp().promise().done( hookCallback ); } } } else { if ( $collapsible.is( 'tr' ) || $collapsible.is( 'td' ) || $collapsible.is( 'th' ) ) { - $collapsible.fadeIn(); + $collapsible.fadeIn().promise().done( hookCallback ); } else { - $collapsible.slideDown(); + $collapsible.slideDown().promise().done( hookCallback ); } } } @@ -129,7 +143,7 @@ } /** - * Handles clicking on the collapsible element toggle and other + * Handles clicking/keypressing on the collapsible element toggle and other * situations where a collapsible element is toggled (e.g. the initial * toggle for collapsed ones). * @@ -138,20 +152,32 @@ * @param {jQuery.Event|null} e either the event or null if unavailable * @param {Object|undefined} options */ - function togglingHandler( $toggle, $collapsible, event, options ) { + function togglingHandler( $toggle, $collapsible, e, options ) { var wasCollapsed, $textContainer, collapseText, expandText; - if ( event ) { - // Don't fire if a link was clicked, if requested (for premade togglers by default) - if ( options.linksPassthru && $.nodeName( event.target, 'a' ) ) { - return true; + if ( options === undefined ) { + options = {}; + } + + if ( e ) { + if ( e.type === 'click' && options.linksPassthru && $.nodeName( e.target, 'a' ) ) { + // Don't fire if a link was clicked, if requested (for premade togglers by default) + return; + } else if ( e.type === 'keypress' && e.which !== 13 && e.which !== 32 ) { + // Only handle keypresses on the "Enter" or "Space" keys + return; } else { - event.preventDefault(); - event.stopPropagation(); + e.preventDefault(); + e.stopPropagation(); } } - wasCollapsed = $collapsible.hasClass( 'mw-collapsed' ); + // This allows the element to be hidden on initial toggle without fiddling with the class + if ( options.wasCollapsed !== undefined ) { + wasCollapsed = options.wasCollapsed; + } else { + wasCollapsed = $collapsible.hasClass( 'mw-collapsed' ); + } // Toggle the state of the collapsible element (that is, expand or collapse) $collapsible.toggleClass( 'mw-collapsed', !wasCollapsed ); @@ -179,45 +205,6 @@ toggleElement( $collapsible, wasCollapsed ? 'expand' : 'collapse', $toggle, options ); } - /** - * Toggles collapsible and togglelink class and updates text label. - * - * @param {jQuery} $that - * @param {jQuery.Event} e - * @param {Object|undefined} options - */ - function toggleLinkDefault( $that, e, options ) { - var $collapsible = $that.closest( '.mw-collapsible' ); - options = $.extend( { toggleClasses: true }, options ); - togglingHandler( $that, $collapsible, e, options ); - } - - /** - * Toggles collapsible and togglelink class. - * - * @param {jQuery} $that - * @param {jQuery.Event} e - * @param {Object|undefined} options - */ - function toggleLinkPremade( $that, e, options ) { - var $collapsible = $that.eq( 0 ).closest( '.mw-collapsible' ); - options = $.extend( { toggleClasses: true, linksPassthru: true }, options ); - togglingHandler( $that, $collapsible, e, options ); - } - - /** - * Toggles customcollapsible. - * - * @param {jQuery} $that - * @param {jQuery.Event} e - * @param {Object|undefined} options - * @param {jQuery} $collapsible - */ - function toggleLinkCustom( $that, e, options, $collapsible ) { - options = $.extend( {}, options ); - togglingHandler( $that, $collapsible, e, options ); - } - /** * Make any element collapsible. * @@ -243,17 +230,17 @@ * div.mw-collapsible-content. May only be used with custom togglers. */ $.fn.makeCollapsible = function ( options ) { - return this.each(function () { - var $collapsible, collapsetext, expandtext, $toggle, $toggleLink, $firstItem, collapsibleId, - $customTogglers, firstval; + if ( options === undefined ) { + options = {}; + } - if ( options === undefined ) { - options = {}; - } + return this.each( function () { + var $collapsible, collapseText, expandText, $toggle, actionHandler, buildDefaultToggleLink, + premadeToggleHandler, $toggleLink, $firstItem, collapsibleId, $customTogglers, firstval; // Ensure class "mw-collapsible" is present in case .makeCollapsible() // is called on element(s) that don't have it yet. - $collapsible = $(this).addClass( 'mw-collapsible' ); + $collapsible = $( this ).addClass( 'mw-collapsible' ); // Return if it has been enabled already. if ( $collapsible.data( 'mw-made-collapsible' ) ) { @@ -263,21 +250,35 @@ } // Use custom text or default? - collapsetext = options.collapseText || $collapsible.attr( 'data-collapsetext' ) || mw.msg( 'collapsible-collapse' ); - expandtext = options.expandText || $collapsible.attr( 'data-expandtext' ) || mw.msg( 'collapsible-expand' ); - - // Create toggle link with a space around the brackets ( [text] ) - $toggleLink = - $( '' ) - .text( collapsetext ) + collapseText = options.collapseText || $collapsible.attr( 'data-collapsetext' ) || mw.msg( 'collapsible-collapse' ); + expandText = options.expandText || $collapsible.attr( 'data-expandtext' ) || mw.msg( 'collapsible-expand' ); + + // Default click/keypress handler and toggle link to use when none is present + actionHandler = function ( e, opts ) { + var defaultOpts = { + toggleClasses: true, + toggleText: { collapseText: collapseText, expandText: expandText } + }; + opts = $.extend( defaultOpts, options, opts ); + togglingHandler( $( this ), $collapsible, e, opts ); + }; + // Default toggle link. Only build it when needed to avoid jQuery memory leaks (event data). + buildDefaultToggleLink = function () { + return $( '' ) + .text( collapseText ) .wrap( '' ) .parent() .prepend( ' [' ) .append( '] ' ) - .on( 'click.mw-collapse', function ( e, opts ) { - opts = $.extend( { toggleText: { collapseText: collapsetext, expandText: expandtext } }, options, opts ); - toggleLinkDefault( $(this), e, opts ); - } ); + .on( 'click.mw-collapsible keypress.mw-collapsible', actionHandler ); + }; + + // Default handler for clicking on premade toggles + premadeToggleHandler = function ( e, opts ) { + var defaultOpts = { toggleClasses: true, linksPassthru: true }; + opts = $.extend( defaultOpts, options, opts ); + togglingHandler( $( this ), $collapsible, e, opts ); + }; // Check if this element has a custom position for the toggle link // (ie. outside the container or deeper inside the tree) @@ -296,25 +297,21 @@ } } - // Bind the custom togglers + // Bind the togglers if ( $customTogglers && $customTogglers.length ) { - $customTogglers.on( 'click.mw-collapse', function ( e, opts ) { - opts = $.extend( {}, options, opts ); - toggleLinkCustom( $(this), e, opts, $collapsible ); - } ); - - // Initial state - if ( options.collapsed || $collapsible.hasClass( 'mw-collapsed' ) ) { - // Remove here so that the toggler goes in the right direction, - // It re-adds the class. - $collapsible.removeClass( 'mw-collapsed' ); - toggleLinkCustom( $customTogglers, null, $.extend( { instantHide: true }, options ), $collapsible ); - } + actionHandler = function ( e, opts ) { + var defaultOpts = {}; + opts = $.extend( defaultOpts, options, opts ); + togglingHandler( $( this ), $collapsible, e, opts ); + }; + + $toggleLink = $customTogglers; + $toggleLink.on( 'click.mw-collapsible keypress.mw-collapsible', actionHandler ); - // If this is not a custom case, do the default: - // Wrap the contents and add the toggle link } else { - // Elements are treated differently + // If this is not a custom case, do the default: wrap the + // contents and add the toggle link. Different elements are + // treated differently. if ( $collapsible.is( 'table' ) ) { // The toggle-link will be in one the the cells (td or th) of the first row $firstItem = $collapsible.find( 'tr:first th, tr:first td' ); @@ -322,12 +319,10 @@ // If theres no toggle link, add it to the last cell if ( !$toggle.length ) { - $firstItem.eq(-1).prepend( $toggleLink ); + $toggleLink = buildDefaultToggleLink().prependTo( $firstItem.eq( -1 ) ); } else { - $toggleLink = $toggle.off( 'click.mw-collapse' ).on( 'click.mw-collapse', function ( e, opts ) { - opts = $.extend( {}, options, opts ); - toggleLinkPremade( $toggle, e, opts ); - } ); + actionHandler = premadeToggleHandler; + $toggleLink = $toggle.on( 'click.mw-collapsible keypress.mw-collapsible', actionHandler ); } } else if ( $collapsible.is( 'ul' ) || $collapsible.is( 'ol' ) ) { @@ -339,17 +334,16 @@ if ( !$toggle.length ) { // Make sure the numeral order doesn't get messed up, force the first (soon to be second) item // to be "1". Except if the value-attribute is already used. - // If no value was set WebKit returns "", Mozilla returns '-1', others return null or undefined. + // If no value was set WebKit returns "", Mozilla returns '-1', others return 0, null or undefined. firstval = $firstItem.attr( 'value' ); if ( firstval === undefined || !firstval || firstval === '-1' || firstval === -1 ) { $firstItem.attr( 'value', '1' ); } - $collapsible.prepend( $toggleLink.wrap( '
      • ' ).parent() ); + $toggleLink = buildDefaultToggleLink(); + $toggleLink.wrap( '
      • ' ).parent().prependTo( $collapsible ); } else { - $toggleLink = $toggle.off( 'click.mw-collapse' ).on( 'click.mw-collapse', function ( e, opts ) { - opts = $.extend( {}, options, opts ); - toggleLinkPremade( $toggle, e, opts ); - } ); + actionHandler = premadeToggleHandler; + $toggleLink = $toggle.on( 'click.mw-collapsible keypress.mw-collapsible', actionHandler ); } } else { //
        ,

        etc. @@ -364,28 +358,23 @@ // If theres no toggle link, add it if ( !$toggle.length ) { - $collapsible.prepend( $toggleLink ); + $toggleLink = buildDefaultToggleLink().prependTo( $collapsible ); } else { - $toggleLink = $toggle.off( 'click.mw-collapse' ).on( 'click.mw-collapse', function ( e, opts ) { - opts = $.extend( {}, options, opts ); - toggleLinkPremade( $toggle, e, opts ); - } ); + actionHandler = premadeToggleHandler; + $toggleLink = $toggle.on( 'click.mw-collapsible keypress.mw-collapsible', actionHandler ); } } } - // Initial state (only for those that are not custom, - // because the initial state of those has been taken care of already). - if ( - ( options.collapsed || $collapsible.hasClass( 'mw-collapsed' ) ) && - ( !$customTogglers || !$customTogglers.length ) - ) { - $collapsible.removeClass( 'mw-collapsed' ); - // The collapsible element could have multiple togglers - // To toggle the initial state only click one of them (ie. the first one, eq(0) ) - // Else it would go like: hide,show,hide,show for each toggle link. - // This is just like it would be in reality (only one toggle is clicked at a time). - $toggleLink.eq( 0 ).trigger( 'click', [ { instantHide: true } ] ); + // Attributes for accessibility. This isn't necessary when the toggler is already + // an or a