jquery-ui-rails 4.2.1 → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitmodules +1 -1
- data/.travis.yml +1 -1
- data/History.md +41 -2
- data/README.md +100 -83
- data/Rakefile +82 -49
- data/VERSIONS.md +9 -0
- data/app/assets/images/jquery-ui/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_444444_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_555555_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_777620_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_777777_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_cc0000_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_ffffff_256x240.png +0 -0
- data/app/assets/javascripts/jquery-ui/core.js +15 -0
- data/app/assets/javascripts/jquery-ui/data.js +45 -0
- data/app/assets/javascripts/jquery-ui/disable-selection.js +51 -0
- data/app/assets/javascripts/jquery-ui/effect.all.js +15 -0
- data/app/assets/javascripts/jquery-ui/effect.js +975 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-blind.js +76 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-bounce.js +116 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-clip.js +71 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-drop.js +75 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-explode.js +117 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-fade.js +53 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-fold.js +95 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-highlight.js +63 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-puff.js +49 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-pulsate.js +70 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-scale.js +63 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-shake.js +80 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-size.js +199 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-slide.js +82 -0
- data/app/assets/javascripts/jquery-ui/effects/effect-transfer.js +46 -0
- data/app/assets/javascripts/jquery-ui/focusable.js +89 -0
- data/app/assets/javascripts/jquery-ui/form-reset-mixin.js +83 -0
- data/app/assets/javascripts/jquery-ui/form.js +25 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-af.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ar-DZ.js +42 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ar.js +42 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-az.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-be.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-bg.js +41 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-bs.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ca.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-cs.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-cy-GB.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-da.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-de-AT.js +41 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-de.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-el.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-en-AU.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-en-GB.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-en-NZ.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-eo.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-es.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-et.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-eu.js +39 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-fa.js +76 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-fi.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-fo.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-fr-CA.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-fr-CH.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-fr.js +42 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-gl.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-he.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-hi.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-hr.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-hu.js +39 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-hy.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-id.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-is.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-it-CH.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-it.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ja.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ka.js +51 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-kk.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-km.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ko.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ky.js +41 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-lb.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-lt.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-lv.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-mk.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ml.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ms.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-nb.js +52 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-nl-BE.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-nl.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-nn.js +52 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-no.js +53 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-pl.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-pt-BR.js +48 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-pt.js +47 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-rm.js +64 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ro.js +43 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ru.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-sk.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-sl.js +41 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-sq.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-sr-SR.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-sr.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-sv.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-ta.js +56 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-th.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-tj.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-tr.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-uk.js +41 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-vi.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-zh-CN.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-zh-HK.js +40 -0
- data/app/assets/javascripts/jquery-ui/i18n/datepicker-zh-TW.js +40 -0
- data/app/assets/javascripts/jquery-ui/ie.js +20 -0
- data/app/assets/javascripts/jquery-ui/jquery-patch.js +91 -0
- data/app/assets/javascripts/jquery-ui/jquery-var-for-color.js +24 -0
- data/app/assets/javascripts/jquery-ui/keycode.js +51 -0
- data/app/assets/javascripts/jquery-ui/labels.js +71 -0
- data/app/assets/javascripts/jquery-ui/plugin.js +49 -0
- data/app/assets/javascripts/{jquery.ui.position.js → jquery-ui/position.js} +120 -108
- data/app/assets/javascripts/jquery-ui/safe-active-element.js +46 -0
- data/app/assets/javascripts/jquery-ui/safe-blur.js +27 -0
- data/app/assets/javascripts/jquery-ui/scroll-parent.js +50 -0
- data/app/assets/javascripts/jquery-ui/tabbable.js +41 -0
- data/app/assets/javascripts/jquery-ui/unique-id.js +54 -0
- data/app/assets/javascripts/jquery-ui/vendor/jquery-color/jquery.color.js +722 -0
- data/app/assets/javascripts/jquery-ui/version.js +20 -0
- data/app/assets/javascripts/jquery-ui/widget.js +754 -0
- data/app/assets/javascripts/{jquery.ui.accordion.js → jquery-ui/widgets/accordion.js} +257 -203
- data/app/assets/javascripts/{jquery.ui.autocomplete.js → jquery-ui/widgets/autocomplete.js} +202 -133
- data/app/assets/javascripts/jquery-ui/widgets/button.js +454 -0
- data/app/assets/javascripts/jquery-ui/widgets/checkboxradio.js +289 -0
- data/app/assets/javascripts/jquery-ui/widgets/controlgroup.js +304 -0
- data/app/assets/javascripts/jquery-ui/widgets/datepicker.js +2243 -0
- data/app/assets/javascripts/jquery-ui/widgets/dialog.js +968 -0
- data/app/assets/javascripts/jquery-ui/widgets/draggable.js +1268 -0
- data/app/assets/javascripts/jquery-ui/widgets/droppable.js +508 -0
- data/app/assets/javascripts/{jquery.ui.menu.js → jquery-ui/widgets/menu.js} +276 -187
- data/app/assets/javascripts/jquery-ui/widgets/mouse.js +241 -0
- data/app/assets/javascripts/jquery-ui/widgets/progressbar.js +184 -0
- data/app/assets/javascripts/jquery-ui/widgets/resizable.js +1225 -0
- data/app/assets/javascripts/jquery-ui/widgets/selectable.js +321 -0
- data/app/assets/javascripts/jquery-ui/widgets/selectmenu.js +702 -0
- data/app/assets/javascripts/{jquery.ui.slider.js → jquery-ui/widgets/slider.js} +254 -174
- data/app/assets/javascripts/jquery-ui/widgets/sortable.js +1623 -0
- data/app/assets/javascripts/{jquery.ui.spinner.js → jquery-ui/widgets/spinner.js} +206 -119
- data/app/assets/javascripts/{jquery.ui.tabs.js → jquery-ui/widgets/tabs.js} +334 -255
- data/app/assets/javascripts/jquery-ui/widgets/tooltip.js +530 -0
- data/app/assets/javascripts/jquery-ui.js +57 -0
- data/app/assets/stylesheets/jquery-ui/accordion.css +26 -0
- data/app/assets/stylesheets/{jquery.ui.all.css.erb → jquery-ui/all.css} +4 -4
- data/app/assets/stylesheets/{jquery.ui.autocomplete.css.erb → jquery-ui/autocomplete.css} +3 -5
- data/app/assets/stylesheets/jquery-ui/base.css +32 -0
- data/app/assets/stylesheets/jquery-ui/button.css +85 -0
- data/app/assets/stylesheets/jquery-ui/checkboxradio.css +37 -0
- data/app/assets/stylesheets/jquery-ui/controlgroup.css +68 -0
- data/app/assets/stylesheets/{jquery.ui.core.css.erb → jquery-ui/core.css} +16 -9
- data/app/assets/stylesheets/{jquery.ui.datepicker.css.erb → jquery-ui/datepicker.css} +14 -5
- data/app/assets/stylesheets/{jquery.ui.dialog.css.erb → jquery-ui/dialog.css} +40 -12
- data/app/assets/stylesheets/jquery-ui/draggable.css +15 -0
- data/app/assets/stylesheets/jquery-ui/menu.css +67 -0
- data/app/assets/stylesheets/jquery-ui/progressbar.css +31 -0
- data/app/assets/stylesheets/{jquery.ui.resizable.css.erb → jquery-ui/resizable.css} +5 -4
- data/app/assets/stylesheets/{jquery.ui.selectable.css.erb → jquery-ui/selectable.css} +7 -4
- data/app/assets/stylesheets/jquery-ui/selectmenu.css +53 -0
- data/app/assets/stylesheets/{jquery.ui.slider.css.erb → jquery-ui/slider.css} +7 -6
- data/app/assets/stylesheets/jquery-ui/sortable.css +15 -0
- data/app/assets/stylesheets/{jquery.ui.spinner.css.erb → jquery-ui/spinner.css} +9 -24
- data/app/assets/stylesheets/{jquery.ui.tabs.css.erb → jquery-ui/tabs.css} +3 -4
- data/app/assets/stylesheets/{jquery.ui.theme.css.erb → jquery-ui/theme.css.erb} +122 -96
- data/app/assets/stylesheets/{jquery.ui.tooltip.css.erb → jquery-ui/tooltip.css} +3 -6
- data/app/assets/stylesheets/jquery-ui.css +1 -0
- data/lib/jquery/ui/rails/version.rb +2 -2
- metadata +180 -166
- data/app/assets/images/jquery-ui/animated-overlay.gif +0 -0
- data/app/assets/images/jquery-ui/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/app/assets/images/jquery-ui/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/app/assets/images/jquery-ui/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/app/assets/images/jquery-ui/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/app/assets/images/jquery-ui/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/app/assets/images/jquery-ui/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/app/assets/images/jquery-ui/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_222222_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_2e83ff_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_454545_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_888888_256x240.png +0 -0
- data/app/assets/images/jquery-ui/ui-icons_cd0a0a_256x240.png +0 -0
- data/app/assets/javascripts/jquery.ui.all.js +0 -34
- data/app/assets/javascripts/jquery.ui.button.js +0 -398
- data/app/assets/javascripts/jquery.ui.core.js +0 -320
- data/app/assets/javascripts/jquery.ui.datepicker-af.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ar-DZ.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ar.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-az.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-be.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-bg.js +0 -24
- data/app/assets/javascripts/jquery.ui.datepicker-bs.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ca.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-cs.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-cy-GB.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-da.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-de.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-el.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-en-AU.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-en-GB.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-en-NZ.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-eo.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-es.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-et.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-eu.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-fa.js +0 -59
- data/app/assets/javascripts/jquery.ui.datepicker-fi.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-fo.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-fr-CA.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-fr-CH.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-fr.js +0 -25
- data/app/assets/javascripts/jquery.ui.datepicker-gl.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-he.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-hi.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-hr.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-hu.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-hy.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-id.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-is.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-it.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ja.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ka.js +0 -21
- data/app/assets/javascripts/jquery.ui.datepicker-kk.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-km.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ko.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ky.js +0 -24
- data/app/assets/javascripts/jquery.ui.datepicker-lb.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-lt.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-lv.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-mk.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ml.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ms.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-nb.js +0 -22
- data/app/assets/javascripts/jquery.ui.datepicker-nl-BE.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-nl.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-nn.js +0 -22
- data/app/assets/javascripts/jquery.ui.datepicker-no.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-pl.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-pt-BR.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-pt.js +0 -22
- data/app/assets/javascripts/jquery.ui.datepicker-rm.js +0 -21
- data/app/assets/javascripts/jquery.ui.datepicker-ro.js +0 -26
- data/app/assets/javascripts/jquery.ui.datepicker-ru.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-sk.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-sl.js +0 -24
- data/app/assets/javascripts/jquery.ui.datepicker-sq.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-sr-SR.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-sr.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-sv.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-ta.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-th.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-tj.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-tr.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-uk.js +0 -24
- data/app/assets/javascripts/jquery.ui.datepicker-vi.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-zh-CN.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-zh-HK.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker-zh-TW.js +0 -23
- data/app/assets/javascripts/jquery.ui.datepicker.js +0 -2040
- data/app/assets/javascripts/jquery.ui.dialog.js +0 -830
- data/app/assets/javascripts/jquery.ui.draggable.js +0 -962
- data/app/assets/javascripts/jquery.ui.droppable.js +0 -394
- data/app/assets/javascripts/jquery.ui.effect-blind.js +0 -84
- data/app/assets/javascripts/jquery.ui.effect-bounce.js +0 -115
- data/app/assets/javascripts/jquery.ui.effect-clip.js +0 -69
- data/app/assets/javascripts/jquery.ui.effect-drop.js +0 -67
- data/app/assets/javascripts/jquery.ui.effect-explode.js +0 -99
- data/app/assets/javascripts/jquery.ui.effect-fade.js +0 -32
- data/app/assets/javascripts/jquery.ui.effect-fold.js +0 -78
- data/app/assets/javascripts/jquery.ui.effect-highlight.js +0 -52
- data/app/assets/javascripts/jquery.ui.effect-pulsate.js +0 -65
- data/app/assets/javascripts/jquery.ui.effect-scale.js +0 -320
- data/app/assets/javascripts/jquery.ui.effect-shake.js +0 -76
- data/app/assets/javascripts/jquery.ui.effect-slide.js +0 -66
- data/app/assets/javascripts/jquery.ui.effect-transfer.js +0 -49
- data/app/assets/javascripts/jquery.ui.effect.all.js +0 -14
- data/app/assets/javascripts/jquery.ui.effect.js +0 -1289
- data/app/assets/javascripts/jquery.ui.mouse.js +0 -172
- data/app/assets/javascripts/jquery.ui.progressbar.js +0 -148
- data/app/assets/javascripts/jquery.ui.resizable.js +0 -982
- data/app/assets/javascripts/jquery.ui.selectable.js +0 -281
- data/app/assets/javascripts/jquery.ui.sortable.js +0 -1293
- data/app/assets/javascripts/jquery.ui.tooltip.js +0 -406
- data/app/assets/javascripts/jquery.ui.widget.js +0 -521
- data/app/assets/stylesheets/jquery.ui.accordion.css.erb +0 -42
- data/app/assets/stylesheets/jquery.ui.base.css.erb +0 -27
- data/app/assets/stylesheets/jquery.ui.button.css.erb +0 -118
- data/app/assets/stylesheets/jquery.ui.menu.css.erb +0 -83
- data/app/assets/stylesheets/jquery.ui.progressbar.css.erb +0 -37
@@ -1,28 +1,53 @@
|
|
1
|
-
//= require jquery
|
2
|
-
//= require jquery
|
3
|
-
//= require jquery
|
4
|
-
//= require jquery
|
1
|
+
//= require jquery-ui/widgets/menu
|
2
|
+
//= require jquery-ui/keycode
|
3
|
+
//= require jquery-ui/position
|
4
|
+
//= require jquery-ui/safe-active-element
|
5
|
+
//= require jquery-ui/version
|
6
|
+
//= require jquery-ui/widget
|
5
7
|
|
6
8
|
/*!
|
7
|
-
* jQuery UI Autocomplete 1.
|
9
|
+
* jQuery UI Autocomplete 1.13.0
|
8
10
|
* http://jqueryui.com
|
9
11
|
*
|
10
|
-
* Copyright
|
12
|
+
* Copyright jQuery Foundation and other contributors
|
11
13
|
* Released under the MIT license.
|
12
14
|
* http://jquery.org/license
|
13
|
-
*
|
14
|
-
* http://api.jqueryui.com/autocomplete/
|
15
|
-
*
|
16
|
-
* Depends:
|
17
|
-
* jquery.ui.core.js
|
18
|
-
* jquery.ui.widget.js
|
19
|
-
* jquery.ui.position.js
|
20
|
-
* jquery.ui.menu.js
|
21
15
|
*/
|
22
|
-
|
16
|
+
|
17
|
+
//>>label: Autocomplete
|
18
|
+
//>>group: Widgets
|
19
|
+
//>>description: Lists suggested words as the user is typing.
|
20
|
+
//>>docs: http://api.jqueryui.com/autocomplete/
|
21
|
+
//>>demos: http://jqueryui.com/autocomplete/
|
22
|
+
//>>css.structure: ../../themes/base/core.css
|
23
|
+
//>>css.structure: ../../themes/base/autocomplete.css
|
24
|
+
//>>css.theme: ../../themes/base/theme.css
|
25
|
+
|
26
|
+
( function( factory ) {
|
27
|
+
"use strict";
|
28
|
+
|
29
|
+
if ( typeof define === "function" && define.amd ) {
|
30
|
+
|
31
|
+
// AMD. Register as an anonymous module.
|
32
|
+
define( [
|
33
|
+
"jquery",
|
34
|
+
"./menu",
|
35
|
+
"../keycode",
|
36
|
+
"../position",
|
37
|
+
"../safe-active-element",
|
38
|
+
"../version",
|
39
|
+
"../widget"
|
40
|
+
], factory );
|
41
|
+
} else {
|
42
|
+
|
43
|
+
// Browser globals
|
44
|
+
factory( jQuery );
|
45
|
+
}
|
46
|
+
} )( function( $ ) {
|
47
|
+
"use strict";
|
23
48
|
|
24
49
|
$.widget( "ui.autocomplete", {
|
25
|
-
version: "1.
|
50
|
+
version: "1.13.0",
|
26
51
|
defaultElement: "<input>",
|
27
52
|
options: {
|
28
53
|
appendTo: null,
|
@@ -36,7 +61,7 @@ $.widget( "ui.autocomplete", {
|
|
36
61
|
},
|
37
62
|
source: null,
|
38
63
|
|
39
|
-
//
|
64
|
+
// Callbacks
|
40
65
|
change: null,
|
41
66
|
close: null,
|
42
67
|
focus: null,
|
@@ -50,6 +75,7 @@ $.widget( "ui.autocomplete", {
|
|
50
75
|
pending: 0,
|
51
76
|
|
52
77
|
_create: function() {
|
78
|
+
|
53
79
|
// Some browsers only repeat keydown events, not keypress events,
|
54
80
|
// so we use the suppressKeyPress flag to determine if we've already
|
55
81
|
// handled the keydown event. #7269
|
@@ -58,25 +84,21 @@ $.widget( "ui.autocomplete", {
|
|
58
84
|
// events when we know the keydown event was used to modify the
|
59
85
|
// search term. #7799
|
60
86
|
var suppressKeyPress, suppressKeyPressRepeat, suppressInput,
|
61
|
-
nodeName = this.element[0].nodeName.toLowerCase(),
|
87
|
+
nodeName = this.element[ 0 ].nodeName.toLowerCase(),
|
62
88
|
isTextarea = nodeName === "textarea",
|
63
89
|
isInput = nodeName === "input";
|
64
90
|
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
isInput ? false :
|
71
|
-
// All other element types are determined by whether or not they're contentEditable
|
72
|
-
this.element.prop( "isContentEditable" );
|
91
|
+
// Textareas are always multi-line
|
92
|
+
// Inputs are always single-line, even if inside a contentEditable element
|
93
|
+
// IE also treats inputs as contentEditable
|
94
|
+
// All other element types are determined by whether or not they're contentEditable
|
95
|
+
this.isMultiLine = isTextarea || !isInput && this._isContentEditable( this.element );
|
73
96
|
|
74
97
|
this.valueMethod = this.element[ isTextarea || isInput ? "val" : "text" ];
|
75
98
|
this.isNewMenu = true;
|
76
99
|
|
77
|
-
this.
|
78
|
-
|
79
|
-
.attr( "autocomplete", "off" );
|
100
|
+
this._addClass( "ui-autocomplete-input" );
|
101
|
+
this.element.attr( "autocomplete", "off" );
|
80
102
|
|
81
103
|
this._on( this.element, {
|
82
104
|
keydown: function( event ) {
|
@@ -91,7 +113,7 @@ $.widget( "ui.autocomplete", {
|
|
91
113
|
suppressInput = false;
|
92
114
|
suppressKeyPressRepeat = false;
|
93
115
|
var keyCode = $.ui.keyCode;
|
94
|
-
switch( event.keyCode ) {
|
116
|
+
switch ( event.keyCode ) {
|
95
117
|
case keyCode.PAGE_UP:
|
96
118
|
suppressKeyPress = true;
|
97
119
|
this._move( "previousPage", event );
|
@@ -109,9 +131,10 @@ $.widget( "ui.autocomplete", {
|
|
109
131
|
this._keyEvent( "next", event );
|
110
132
|
break;
|
111
133
|
case keyCode.ENTER:
|
112
|
-
|
134
|
+
|
113
135
|
// when menu is open and has focus
|
114
136
|
if ( this.menu.active ) {
|
137
|
+
|
115
138
|
// #6055 - Opera still allows the keypress to occur
|
116
139
|
// which causes forms to submit
|
117
140
|
suppressKeyPress = true;
|
@@ -126,8 +149,11 @@ $.widget( "ui.autocomplete", {
|
|
126
149
|
break;
|
127
150
|
case keyCode.ESCAPE:
|
128
151
|
if ( this.menu.element.is( ":visible" ) ) {
|
129
|
-
|
152
|
+
if ( !this.isMultiLine ) {
|
153
|
+
this._value( this.term );
|
154
|
+
}
|
130
155
|
this.close( event );
|
156
|
+
|
131
157
|
// Different browsers have different default behavior for escape
|
132
158
|
// Single press can mean undo or clear
|
133
159
|
// Double press in IE means clear the whole form
|
@@ -136,6 +162,7 @@ $.widget( "ui.autocomplete", {
|
|
136
162
|
break;
|
137
163
|
default:
|
138
164
|
suppressKeyPressRepeat = true;
|
165
|
+
|
139
166
|
// search timeout should be triggered before the input value is changed
|
140
167
|
this._searchTimeout( event );
|
141
168
|
break;
|
@@ -153,9 +180,9 @@ $.widget( "ui.autocomplete", {
|
|
153
180
|
return;
|
154
181
|
}
|
155
182
|
|
156
|
-
//
|
183
|
+
// Replicate some key handlers to allow them to repeat in Firefox and Opera
|
157
184
|
var keyCode = $.ui.keyCode;
|
158
|
-
switch( event.keyCode ) {
|
185
|
+
switch ( event.keyCode ) {
|
159
186
|
case keyCode.PAGE_UP:
|
160
187
|
this._move( "previousPage", event );
|
161
188
|
break;
|
@@ -183,59 +210,43 @@ $.widget( "ui.autocomplete", {
|
|
183
210
|
this.previous = this._value();
|
184
211
|
},
|
185
212
|
blur: function( event ) {
|
186
|
-
if ( this.cancelBlur ) {
|
187
|
-
delete this.cancelBlur;
|
188
|
-
return;
|
189
|
-
}
|
190
|
-
|
191
213
|
clearTimeout( this.searching );
|
192
214
|
this.close( event );
|
193
215
|
this._change( event );
|
194
216
|
}
|
195
|
-
});
|
217
|
+
} );
|
196
218
|
|
197
219
|
this._initSource();
|
198
220
|
this.menu = $( "<ul>" )
|
199
|
-
.addClass( "ui-autocomplete ui-front" )
|
200
221
|
.appendTo( this._appendTo() )
|
201
|
-
.menu({
|
222
|
+
.menu( {
|
223
|
+
|
202
224
|
// disable ARIA support, the live region takes care of that
|
203
225
|
role: null
|
204
|
-
})
|
226
|
+
} )
|
205
227
|
.hide()
|
206
|
-
.data( "ui-menu" );
|
207
228
|
|
229
|
+
// Support: IE 11 only, Edge <= 14
|
230
|
+
// For other browsers, we preventDefault() on the mousedown event
|
231
|
+
// to keep the dropdown from taking focus from the input. This doesn't
|
232
|
+
// work for IE/Edge, causing problems with selection and scrolling (#9638)
|
233
|
+
// Happily, IE and Edge support an "unselectable" attribute that
|
234
|
+
// prevents an element from receiving focus, exactly what we want here.
|
235
|
+
.attr( {
|
236
|
+
"unselectable": "on"
|
237
|
+
} )
|
238
|
+
.menu( "instance" );
|
239
|
+
|
240
|
+
this._addClass( this.menu.element, "ui-autocomplete", "ui-front" );
|
208
241
|
this._on( this.menu.element, {
|
209
242
|
mousedown: function( event ) {
|
210
|
-
// prevent moving focus out of the text field
|
211
|
-
event.preventDefault();
|
212
243
|
|
213
|
-
//
|
214
|
-
|
215
|
-
this.cancelBlur = true;
|
216
|
-
this._delay(function() {
|
217
|
-
delete this.cancelBlur;
|
218
|
-
});
|
219
|
-
|
220
|
-
// clicking on the scrollbar causes focus to shift to the body
|
221
|
-
// but we can't detect a mouseup or a click immediately afterward
|
222
|
-
// so we have to track the next mousedown and close the menu if
|
223
|
-
// the user clicks somewhere outside of the autocomplete
|
224
|
-
var menuElement = this.menu.element[ 0 ];
|
225
|
-
if ( !$( event.target ).closest( ".ui-menu-item" ).length ) {
|
226
|
-
this._delay(function() {
|
227
|
-
var that = this;
|
228
|
-
this.document.one( "mousedown", function( event ) {
|
229
|
-
if ( event.target !== that.element[ 0 ] &&
|
230
|
-
event.target !== menuElement &&
|
231
|
-
!$.contains( menuElement, event.target ) ) {
|
232
|
-
that.close();
|
233
|
-
}
|
234
|
-
});
|
235
|
-
});
|
236
|
-
}
|
244
|
+
// Prevent moving focus out of the text field
|
245
|
+
event.preventDefault();
|
237
246
|
},
|
238
247
|
menufocus: function( event, ui ) {
|
248
|
+
var label, item;
|
249
|
+
|
239
250
|
// support: Firefox
|
240
251
|
// Prevent accidental activation of menu items in Firefox (#7024 #9118)
|
241
252
|
if ( this.isNewMenu ) {
|
@@ -245,47 +256,50 @@ $.widget( "ui.autocomplete", {
|
|
245
256
|
|
246
257
|
this.document.one( "mousemove", function() {
|
247
258
|
$( event.target ).trigger( event.originalEvent );
|
248
|
-
});
|
259
|
+
} );
|
249
260
|
|
250
261
|
return;
|
251
262
|
}
|
252
263
|
}
|
253
264
|
|
254
|
-
|
265
|
+
item = ui.item.data( "ui-autocomplete-item" );
|
255
266
|
if ( false !== this._trigger( "focus", event, { item: item } ) ) {
|
267
|
+
|
256
268
|
// use value to match what will end up in the input, if it was a key event
|
257
269
|
if ( event.originalEvent && /^key/.test( event.originalEvent.type ) ) {
|
258
270
|
this._value( item.value );
|
259
271
|
}
|
260
|
-
}
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
272
|
+
}
|
273
|
+
|
274
|
+
// Announce the value in the liveRegion
|
275
|
+
label = ui.item.attr( "aria-label" ) || item.value;
|
276
|
+
if ( label && String.prototype.trim.call( label ).length ) {
|
277
|
+
this.liveRegion.children().hide();
|
278
|
+
$( "<div>" ).text( label ).appendTo( this.liveRegion );
|
267
279
|
}
|
268
280
|
},
|
269
281
|
menuselect: function( event, ui ) {
|
270
282
|
var item = ui.item.data( "ui-autocomplete-item" ),
|
271
283
|
previous = this.previous;
|
272
284
|
|
273
|
-
//
|
274
|
-
if ( this.element[0] !== this.document[0]
|
275
|
-
this.element.focus
|
285
|
+
// Only trigger when focus was lost (click on menu)
|
286
|
+
if ( this.element[ 0 ] !== $.ui.safeActiveElement( this.document[ 0 ] ) ) {
|
287
|
+
this.element.trigger( "focus" );
|
276
288
|
this.previous = previous;
|
289
|
+
|
277
290
|
// #6109 - IE triggers two focus events and the second
|
278
291
|
// is asynchronous, so we need to reset the previous
|
279
292
|
// term synchronously and asynchronously :-(
|
280
|
-
this._delay(function() {
|
293
|
+
this._delay( function() {
|
281
294
|
this.previous = previous;
|
282
295
|
this.selectedItem = item;
|
283
|
-
});
|
296
|
+
} );
|
284
297
|
}
|
285
298
|
|
286
299
|
if ( false !== this._trigger( "select", event, { item: item } ) ) {
|
287
300
|
this._value( item.value );
|
288
301
|
}
|
302
|
+
|
289
303
|
// reset the term after the select event
|
290
304
|
// this allows custom select handling to work properly
|
291
305
|
this.term = this._value();
|
@@ -293,30 +307,30 @@ $.widget( "ui.autocomplete", {
|
|
293
307
|
this.close( event );
|
294
308
|
this.selectedItem = item;
|
295
309
|
}
|
296
|
-
});
|
310
|
+
} );
|
297
311
|
|
298
|
-
this.liveRegion = $( "<
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
.
|
312
|
+
this.liveRegion = $( "<div>", {
|
313
|
+
role: "status",
|
314
|
+
"aria-live": "assertive",
|
315
|
+
"aria-relevant": "additions"
|
316
|
+
} )
|
317
|
+
.appendTo( this.document[ 0 ].body );
|
304
318
|
|
305
|
-
|
319
|
+
this._addClass( this.liveRegion, null, "ui-helper-hidden-accessible" );
|
320
|
+
|
321
|
+
// Turning off autocomplete prevents the browser from remembering the
|
306
322
|
// value when navigating through history, so we re-enable autocomplete
|
307
323
|
// if the page is unloaded before the widget is destroyed. #7790
|
308
324
|
this._on( this.window, {
|
309
325
|
beforeunload: function() {
|
310
326
|
this.element.removeAttr( "autocomplete" );
|
311
327
|
}
|
312
|
-
});
|
328
|
+
} );
|
313
329
|
},
|
314
330
|
|
315
331
|
_destroy: function() {
|
316
332
|
clearTimeout( this.searching );
|
317
|
-
this.element
|
318
|
-
.removeClass( "ui-autocomplete-input" )
|
319
|
-
.removeAttr( "autocomplete" );
|
333
|
+
this.element.removeAttr( "autocomplete" );
|
320
334
|
this.menu.element.remove();
|
321
335
|
this.liveRegion.remove();
|
322
336
|
},
|
@@ -334,6 +348,20 @@ $.widget( "ui.autocomplete", {
|
|
334
348
|
}
|
335
349
|
},
|
336
350
|
|
351
|
+
_isEventTargetInWidget: function( event ) {
|
352
|
+
var menuElement = this.menu.element[ 0 ];
|
353
|
+
|
354
|
+
return event.target === this.element[ 0 ] ||
|
355
|
+
event.target === menuElement ||
|
356
|
+
$.contains( menuElement, event.target );
|
357
|
+
},
|
358
|
+
|
359
|
+
_closeOnClickOutside: function( event ) {
|
360
|
+
if ( !this._isEventTargetInWidget( event ) ) {
|
361
|
+
this.close();
|
362
|
+
}
|
363
|
+
},
|
364
|
+
|
337
365
|
_appendTo: function() {
|
338
366
|
var element = this.options.appendTo;
|
339
367
|
|
@@ -343,12 +371,12 @@ $.widget( "ui.autocomplete", {
|
|
343
371
|
this.document.find( element ).eq( 0 );
|
344
372
|
}
|
345
373
|
|
346
|
-
if ( !element ) {
|
347
|
-
element = this.element.closest( ".ui-front" );
|
374
|
+
if ( !element || !element[ 0 ] ) {
|
375
|
+
element = this.element.closest( ".ui-front, dialog" );
|
348
376
|
}
|
349
377
|
|
350
378
|
if ( !element.length ) {
|
351
|
-
element = this.document[0].body;
|
379
|
+
element = this.document[ 0 ].body;
|
352
380
|
}
|
353
381
|
|
354
382
|
return element;
|
@@ -357,7 +385,7 @@ $.widget( "ui.autocomplete", {
|
|
357
385
|
_initSource: function() {
|
358
386
|
var array, url,
|
359
387
|
that = this;
|
360
|
-
if (
|
388
|
+
if ( Array.isArray( this.options.source ) ) {
|
361
389
|
array = this.options.source;
|
362
390
|
this.source = function( request, response ) {
|
363
391
|
response( $.ui.autocomplete.filter( array, request.term ) );
|
@@ -368,7 +396,7 @@ $.widget( "ui.autocomplete", {
|
|
368
396
|
if ( that.xhr ) {
|
369
397
|
that.xhr.abort();
|
370
398
|
}
|
371
|
-
that.xhr = $.ajax({
|
399
|
+
that.xhr = $.ajax( {
|
372
400
|
url: url,
|
373
401
|
data: request,
|
374
402
|
dataType: "json",
|
@@ -378,7 +406,7 @@ $.widget( "ui.autocomplete", {
|
|
378
406
|
error: function() {
|
379
407
|
response( [] );
|
380
408
|
}
|
381
|
-
});
|
409
|
+
} );
|
382
410
|
};
|
383
411
|
} else {
|
384
412
|
this.source = this.options.source;
|
@@ -387,9 +415,14 @@ $.widget( "ui.autocomplete", {
|
|
387
415
|
|
388
416
|
_searchTimeout: function( event ) {
|
389
417
|
clearTimeout( this.searching );
|
390
|
-
this.searching = this._delay(function() {
|
391
|
-
|
392
|
-
if
|
418
|
+
this.searching = this._delay( function() {
|
419
|
+
|
420
|
+
// Search if the value has changed, or if the user retypes the same value (see #7434)
|
421
|
+
var equalValues = this.term === this._value(),
|
422
|
+
menuVisible = this.menu.element.is( ":visible" ),
|
423
|
+
modifierKey = event.altKey || event.ctrlKey || event.metaKey || event.shiftKey;
|
424
|
+
|
425
|
+
if ( !equalValues || ( equalValues && !menuVisible && !modifierKey ) ) {
|
393
426
|
this.selectedItem = null;
|
394
427
|
this.search( null, event );
|
395
428
|
}
|
@@ -399,7 +432,7 @@ $.widget( "ui.autocomplete", {
|
|
399
432
|
search: function( value, event ) {
|
400
433
|
value = value != null ? value : this._value();
|
401
434
|
|
402
|
-
//
|
435
|
+
// Always save the actual value, not the one passed as an argument
|
403
436
|
this.term = this._value();
|
404
437
|
|
405
438
|
if ( value.length < this.options.minLength ) {
|
@@ -415,7 +448,7 @@ $.widget( "ui.autocomplete", {
|
|
415
448
|
|
416
449
|
_search: function( value ) {
|
417
450
|
this.pending++;
|
418
|
-
this.
|
451
|
+
this._addClass( "ui-autocomplete-loading" );
|
419
452
|
this.cancelSearch = false;
|
420
453
|
|
421
454
|
this.source( { term: value }, this._response() );
|
@@ -424,16 +457,16 @@ $.widget( "ui.autocomplete", {
|
|
424
457
|
_response: function() {
|
425
458
|
var index = ++this.requestIndex;
|
426
459
|
|
427
|
-
return
|
460
|
+
return function( content ) {
|
428
461
|
if ( index === this.requestIndex ) {
|
429
462
|
this.__response( content );
|
430
463
|
}
|
431
464
|
|
432
465
|
this.pending--;
|
433
466
|
if ( !this.pending ) {
|
434
|
-
this.
|
467
|
+
this._removeClass( "ui-autocomplete-loading" );
|
435
468
|
}
|
436
|
-
}
|
469
|
+
}.bind( this );
|
437
470
|
},
|
438
471
|
|
439
472
|
__response: function( content ) {
|
@@ -445,6 +478,7 @@ $.widget( "ui.autocomplete", {
|
|
445
478
|
this._suggest( content );
|
446
479
|
this._trigger( "open" );
|
447
480
|
} else {
|
481
|
+
|
448
482
|
// use ._close() instead of .close() so we don't cancel future searches
|
449
483
|
this._close();
|
450
484
|
}
|
@@ -456,6 +490,10 @@ $.widget( "ui.autocomplete", {
|
|
456
490
|
},
|
457
491
|
|
458
492
|
_close: function( event ) {
|
493
|
+
|
494
|
+
// Remove the handler that closes the menu on outside clicks
|
495
|
+
this._off( this.document, "mousedown" );
|
496
|
+
|
459
497
|
if ( this.menu.element.is( ":visible" ) ) {
|
460
498
|
this.menu.element.hide();
|
461
499
|
this.menu.blur();
|
@@ -471,8 +509,9 @@ $.widget( "ui.autocomplete", {
|
|
471
509
|
},
|
472
510
|
|
473
511
|
_normalize: function( items ) {
|
512
|
+
|
474
513
|
// assume all items have the right format when the first item is complete
|
475
|
-
if ( items.length && items[0].label && items[0].value ) {
|
514
|
+
if ( items.length && items[ 0 ].label && items[ 0 ].value ) {
|
476
515
|
return items;
|
477
516
|
}
|
478
517
|
return $.map( items, function( item ) {
|
@@ -482,11 +521,11 @@ $.widget( "ui.autocomplete", {
|
|
482
521
|
value: item
|
483
522
|
};
|
484
523
|
}
|
485
|
-
return $.extend({
|
524
|
+
return $.extend( {}, item, {
|
486
525
|
label: item.label || item.value,
|
487
526
|
value: item.value || item.label
|
488
|
-
}
|
489
|
-
});
|
527
|
+
} );
|
528
|
+
} );
|
490
529
|
},
|
491
530
|
|
492
531
|
_suggest: function( items ) {
|
@@ -495,21 +534,27 @@ $.widget( "ui.autocomplete", {
|
|
495
534
|
this.isNewMenu = true;
|
496
535
|
this.menu.refresh();
|
497
536
|
|
498
|
-
//
|
537
|
+
// Size and position menu
|
499
538
|
ul.show();
|
500
539
|
this._resizeMenu();
|
501
|
-
ul.position( $.extend({
|
540
|
+
ul.position( $.extend( {
|
502
541
|
of: this.element
|
503
|
-
}, this.options.position ));
|
542
|
+
}, this.options.position ) );
|
504
543
|
|
505
544
|
if ( this.options.autoFocus ) {
|
506
545
|
this.menu.next();
|
507
546
|
}
|
547
|
+
|
548
|
+
// Listen for interactions outside of the widget (#6642)
|
549
|
+
this._on( this.document, {
|
550
|
+
mousedown: "_closeOnClickOutside"
|
551
|
+
} );
|
508
552
|
},
|
509
553
|
|
510
554
|
_resizeMenu: function() {
|
511
555
|
var ul = this.menu.element;
|
512
556
|
ul.outerWidth( Math.max(
|
557
|
+
|
513
558
|
// Firefox wraps long text (possibly a rounding bug)
|
514
559
|
// so we add 1px to avoid the wrapping (#7513)
|
515
560
|
ul.width( "" ).outerWidth() + 1,
|
@@ -521,7 +566,7 @@ $.widget( "ui.autocomplete", {
|
|
521
566
|
var that = this;
|
522
567
|
$.each( items, function( index, item ) {
|
523
568
|
that._renderItemData( ul, item );
|
524
|
-
});
|
569
|
+
} );
|
525
570
|
},
|
526
571
|
|
527
572
|
_renderItemData: function( ul, item ) {
|
@@ -530,7 +575,7 @@ $.widget( "ui.autocomplete", {
|
|
530
575
|
|
531
576
|
_renderItem: function( ul, item ) {
|
532
577
|
return $( "<li>" )
|
533
|
-
.append( $( "<
|
578
|
+
.append( $( "<div>" ).text( item.label ) )
|
534
579
|
.appendTo( ul );
|
535
580
|
},
|
536
581
|
|
@@ -541,7 +586,11 @@ $.widget( "ui.autocomplete", {
|
|
541
586
|
}
|
542
587
|
if ( this.menu.isFirstItem() && /^previous/.test( direction ) ||
|
543
588
|
this.menu.isLastItem() && /^next/.test( direction ) ) {
|
544
|
-
|
589
|
+
|
590
|
+
if ( !this.isMultiLine ) {
|
591
|
+
this._value( this.term );
|
592
|
+
}
|
593
|
+
|
545
594
|
this.menu.blur();
|
546
595
|
return;
|
547
596
|
}
|
@@ -560,26 +609,43 @@ $.widget( "ui.autocomplete", {
|
|
560
609
|
if ( !this.isMultiLine || this.menu.element.is( ":visible" ) ) {
|
561
610
|
this._move( keyEvent, event );
|
562
611
|
|
563
|
-
//
|
612
|
+
// Prevents moving cursor to beginning/end of the text field in some browsers
|
564
613
|
event.preventDefault();
|
565
614
|
}
|
615
|
+
},
|
616
|
+
|
617
|
+
// Support: Chrome <=50
|
618
|
+
// We should be able to just use this.element.prop( "isContentEditable" )
|
619
|
+
// but hidden elements always report false in Chrome.
|
620
|
+
// https://code.google.com/p/chromium/issues/detail?id=313082
|
621
|
+
_isContentEditable: function( element ) {
|
622
|
+
if ( !element.length ) {
|
623
|
+
return false;
|
624
|
+
}
|
625
|
+
|
626
|
+
var editable = element.prop( "contentEditable" );
|
627
|
+
|
628
|
+
if ( editable === "inherit" ) {
|
629
|
+
return this._isContentEditable( element.parent() );
|
630
|
+
}
|
631
|
+
|
632
|
+
return editable === "true";
|
566
633
|
}
|
567
|
-
});
|
634
|
+
} );
|
568
635
|
|
569
636
|
$.extend( $.ui.autocomplete, {
|
570
637
|
escapeRegex: function( value ) {
|
571
|
-
return value.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&");
|
638
|
+
return value.replace( /[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&" );
|
572
639
|
},
|
573
|
-
filter: function(array, term) {
|
574
|
-
var matcher = new RegExp( $.ui.autocomplete.escapeRegex(term), "i" );
|
575
|
-
return $.grep( array, function(value) {
|
640
|
+
filter: function( array, term ) {
|
641
|
+
var matcher = new RegExp( $.ui.autocomplete.escapeRegex( term ), "i" );
|
642
|
+
return $.grep( array, function( value ) {
|
576
643
|
return matcher.test( value.label || value.value || value );
|
577
|
-
});
|
644
|
+
} );
|
578
645
|
}
|
579
|
-
});
|
580
|
-
|
646
|
+
} );
|
581
647
|
|
582
|
-
//
|
648
|
+
// Live region extension, adding a `messages` option
|
583
649
|
// NOTE: This is an experimental API. We are still investigating
|
584
650
|
// a full solution for string manipulation and internationalization.
|
585
651
|
$.widget( "ui.autocomplete", $.ui.autocomplete, {
|
@@ -604,8 +670,11 @@ $.widget( "ui.autocomplete", $.ui.autocomplete, {
|
|
604
670
|
} else {
|
605
671
|
message = this.options.messages.noResults;
|
606
672
|
}
|
607
|
-
this.liveRegion.
|
673
|
+
this.liveRegion.children().hide();
|
674
|
+
$( "<div>" ).text( message ).appendTo( this.liveRegion );
|
608
675
|
}
|
609
|
-
});
|
676
|
+
} );
|
677
|
+
|
678
|
+
return $.ui.autocomplete;
|
610
679
|
|
611
|
-
}
|
680
|
+
} );
|