card 1.96.2 → 1.96.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/config/initializers/patches.rb +1 -1
- data/db/migrate_core_cards/20130823192433_add_style_cards.rb +1 -1
- data/db/migrate_core_cards/20170314175313_add_notification_event_card.rb +2 -3
- data/db/migrate_core_cards/data/1.11_help_text.json +16 -16
- data/db/migrate_core_cards/data/1.13_config_text.json +2 -2
- data/db/migrate_core_cards/data/1.14_config_descriptions_etc.json +12 -12
- data/db/migrate_core_cards/data/bootstrap_layout.json +1 -1
- data/db/seed/new/card_actions.yml +799 -799
- data/db/seed/new/card_acts.yml +2 -2
- data/db/seed/new/cards.yml +1610 -1610
- data/db/seed/new/schema_migrations.yml +8 -10
- data/db/seed/test/fixtures/card_actions.yml +1789 -1789
- data/db/seed/test/fixtures/card_acts.yml +447 -447
- data/db/seed/test/fixtures/card_changes.yml +66 -66
- data/db/seed/test/fixtures/card_references.yml +575 -575
- data/db/seed/test/fixtures/cards.yml +2612 -2612
- data/db/seed/test/seed.rb +2 -1
- data/lib/card/format/error.rb +12 -6
- data/lib/card/model/save_helper.rb +2 -1
- data/lib/card/query.rb +1 -1
- data/lib/card/set.rb +22 -12
- data/lib/card/view/cache.rb +3 -3
- data/lib/cardio.rb +3 -1
- data/mod/ace_editor/db/migrate_core_cards/20160804112538_add_ace_cards.rb +1 -1
- data/mod/basic_formats/set/all/base.rb +16 -2
- data/mod/basic_formats/set/all/json.rb +16 -14
- data/mod/bootstrap/lib/stylesheets/style_bootstrap_cards.scss +54 -4
- data/mod/bootstrap/vendor/bootstrap/Gemfile +3 -3
- data/mod/bootstrap/vendor/bootstrap/Gemfile.lock +15 -15
- data/mod/bootstrap/vendor/bootstrap/README.md +36 -30
- data/mod/bootstrap/vendor/bootstrap/_config.yml +12 -30
- data/mod/bootstrap/vendor/bootstrap/build/build-plugins.js +81 -0
- data/mod/bootstrap/vendor/bootstrap/build/generate-sri.js +2 -2
- data/mod/bootstrap/vendor/bootstrap/build/workbox.config.json +1 -1
- data/mod/bootstrap/vendor/bootstrap/build/workbox.js +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-grid.css +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-grid.css.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-grid.min.css +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-grid.min.css.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-reboot.css +5 -4
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-reboot.css.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-reboot.min.css +2 -2
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap-reboot.min.css.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap.css +145 -96
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap.css.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap.min.css +2 -2
- data/mod/bootstrap/vendor/bootstrap/dist/css/bootstrap.min.css.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.bundle.js +123 -106
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.bundle.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.bundle.min.js +2 -2
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.bundle.min.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.js +123 -106
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.min.js +2 -2
- data/mod/bootstrap/vendor/bootstrap/dist/js/bootstrap.min.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/alert.js +160 -134
- data/mod/bootstrap/vendor/bootstrap/js/dist/alert.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/button.js +150 -125
- data/mod/bootstrap/vendor/bootstrap/js/dist/button.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/carousel.js +465 -406
- data/mod/bootstrap/vendor/bootstrap/js/dist/carousel.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/collapse.js +338 -274
- data/mod/bootstrap/vendor/bootstrap/js/dist/collapse.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/dropdown.js +442 -379
- data/mod/bootstrap/vendor/bootstrap/js/dist/dropdown.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/index.js +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/index.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/modal.js +503 -454
- data/mod/bootstrap/vendor/bootstrap/js/dist/modal.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/popover.js +224 -164
- data/mod/bootstrap/vendor/bootstrap/js/dist/popover.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/scrollspy.js +308 -248
- data/mod/bootstrap/vendor/bootstrap/js/dist/scrollspy.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/tab.js +218 -191
- data/mod/bootstrap/vendor/bootstrap/js/dist/tab.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/tooltip.js +584 -524
- data/mod/bootstrap/vendor/bootstrap/js/dist/tooltip.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/dist/util.js +130 -118
- data/mod/bootstrap/vendor/bootstrap/js/dist/util.js.map +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/src/alert.js +3 -3
- data/mod/bootstrap/vendor/bootstrap/js/src/button.js +7 -7
- data/mod/bootstrap/vendor/bootstrap/js/src/carousel.js +16 -13
- data/mod/bootstrap/vendor/bootstrap/js/src/collapse.js +25 -21
- data/mod/bootstrap/vendor/bootstrap/js/src/dropdown.js +16 -9
- data/mod/bootstrap/vendor/bootstrap/js/src/index.js +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/src/modal.js +30 -30
- data/mod/bootstrap/vendor/bootstrap/js/src/popover.js +2 -2
- data/mod/bootstrap/vendor/bootstrap/js/src/scrollspy.js +12 -9
- data/mod/bootstrap/vendor/bootstrap/js/src/tab.js +5 -4
- data/mod/bootstrap/vendor/bootstrap/js/src/tooltip.js +11 -9
- data/mod/bootstrap/vendor/bootstrap/js/src/util.js +2 -3
- data/mod/bootstrap/vendor/bootstrap/js/tests/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/js/tests/karma-bundle.conf.js +2 -2
- data/mod/bootstrap/vendor/bootstrap/js/tests/karma.conf.js +7 -2
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/alert.js +1 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/button.js +1 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/carousel.js +1 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/collapse.js +1 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/dropdown.js +69 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/modal.js +3 -43
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/popover.js +1 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/scrollspy.js +1 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/tab.js +1 -0
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/tooltip.js +24 -40
- data/mod/bootstrap/vendor/bootstrap/js/tests/unit/util.js +5 -1
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/alert.html +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/button.html +1 -1
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/carousel.html +1 -2
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/collapse.html +15 -1
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/dropdown.html +2 -2
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/modal.html +8 -8
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/popover.html +2 -2
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/scrollspy.html +1 -2
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/tab.html +3 -2
- data/mod/bootstrap/vendor/bootstrap/js/tests/visual/tooltip.html +35 -23
- data/mod/bootstrap/vendor/bootstrap/nuget/bootstrap.nuspec +5 -1
- data/mod/bootstrap/vendor/bootstrap/nuget/bootstrap.sass.nuspec +5 -1
- data/mod/bootstrap/vendor/bootstrap/package-lock.json +5397 -7292
- data/mod/bootstrap/vendor/bootstrap/package.js +1 -1
- data/mod/bootstrap/vendor/bootstrap/package.json +63 -64
- data/mod/bootstrap/vendor/bootstrap/scss/_buttons.scss +0 -1
- data/mod/bootstrap/vendor/bootstrap/scss/_carousel.scss +1 -1
- data/mod/bootstrap/vendor/bootstrap/scss/_close.scss +8 -7
- data/mod/bootstrap/vendor/bootstrap/scss/_custom-forms.scss +32 -20
- data/mod/bootstrap/vendor/bootstrap/scss/_forms.scss +13 -15
- data/mod/bootstrap/vendor/bootstrap/scss/_functions.scss +1 -1
- data/mod/bootstrap/vendor/bootstrap/scss/_input-group.scss +22 -7
- data/mod/bootstrap/vendor/bootstrap/scss/_modal.scss +18 -6
- data/mod/bootstrap/vendor/bootstrap/scss/_navbar.scss +2 -2
- data/mod/bootstrap/vendor/bootstrap/scss/_reboot.scss +5 -2
- data/mod/bootstrap/vendor/bootstrap/scss/_tables.scss +0 -1
- data/mod/bootstrap/vendor/bootstrap/scss/_variables.scss +88 -65
- data/mod/bootstrap/vendor/bootstrap/scss/bootstrap-grid.scss +1 -1
- data/mod/bootstrap/vendor/bootstrap/scss/bootstrap-reboot.scss +1 -1
- data/mod/bootstrap/vendor/bootstrap/scss/bootstrap.scss +1 -1
- data/mod/bootstrap/vendor/bootstrap/scss/mixins/_breakpoints.scss +1 -1
- data/mod/bootstrap/vendor/bootstrap/scss/mixins/_forms.scss +7 -7
- data/mod/bootstrap/vendor/bootstrap/scss/mixins/_hover.scss +1 -1
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/breakpoints.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/browser-bugs.yml +5 -5
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/browser-features.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/colors.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/examples.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/grays.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/nav.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/theme-colors.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_data → site/_data}/translations.yml +0 -0
- data/mod/bootstrap/vendor/bootstrap/site/_includes/ads.html +1 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/bugify.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/callout-danger-async-methods.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/callout-info-mediaqueries-breakpoints.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/callout-warning-color-assistive-technologies.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/callout.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/docs-navbar.html +1 -4
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/docs-sidebar.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/example.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/site/_includes/favicons.html +9 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/footer.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/header.html +5 -7
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/bootstrap.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/download.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/github.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/import.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/lightning.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/menu.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/slack.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/icons/twitter.svg +0 -0
- data/mod/bootstrap/vendor/bootstrap/site/_includes/scripts.html +26 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/skippy.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_includes → site/_includes}/social.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_layouts → site/_layouts}/default.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_layouts → site/_layouts}/docs.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_layouts → site/_layouts}/examples.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_layouts → site/_layouts}/home.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{_layouts → site/_layouts}/redirect.html +1 -1
- data/mod/bootstrap/vendor/bootstrap/{_layouts → site/_layouts}/simple.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/about/brand.md +5 -5
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/about/license.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/about/overview.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/about/translations.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/site/docs/4.1/assets/brand/bootstrap-outline.svg +4 -0
- data/mod/bootstrap/vendor/bootstrap/site/docs/4.1/assets/brand/bootstrap-punchout.svg +4 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/brand/bootstrap-social-logo.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/brand/bootstrap-social.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/site/docs/4.1/assets/brand/bootstrap-solid.svg +4 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/css/docs.min.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/site/docs/4.1/assets/css/docs.min.css.map +1 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/bootstrap-stack.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/bootstrap-themes.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/android-chrome-192x192.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/android-chrome-512x512.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/apple-touch-icon.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/browserconfig.xml +1 -1
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/favicon-16x16.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/favicon-32x32.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/manifest.json +2 -2
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/mstile-144x144.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/mstile-150x150.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/mstile-310x150.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/mstile-310x310.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/img/favicons/mstile-70x70.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/site/docs/4.1/assets/img/favicons/safari-pinned-tab.svg +4 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/docs.min.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/src/application.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/src/ie-emulation-modes-warning.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/src/pwa.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/src/search.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/vendor/anchor.min.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/vendor/clipboard.min.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/vendor/holder.min.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/vendor/jquery-slim.min.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/js/vendor/popper.min.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_ads.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_algolia.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_anchor.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_brand.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_browser-bugs.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_buttons.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_callouts.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_clipboard-js.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_colors.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_component-examples.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_content.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_examples.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_footer.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_masthead.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_nav.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_sidebar.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_skiplink.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_syntax.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/_variables.scss +0 -0
- data/mod/bootstrap/vendor/bootstrap/{assets → site/docs/4.1/assets}/scss/docs.scss +3 -3
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/browser-bugs.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/alerts.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/badge.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/breadcrumb.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/button-group.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/buttons.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/card.md +2 -2
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/carousel.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/collapse.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/dropdowns.md +3 -2
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/forms.md +17 -17
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/input-group.md +27 -27
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/jumbotron.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/list-group.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/modal.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/navbar.md +3 -3
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/navs.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/pagination.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/popovers.md +2 -2
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/progress.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/scrollspy.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/components/tooltips.md +11 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/content/code.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/content/figures.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/content/images.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/content/reboot.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/content/tables.md +16 -5
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/content/typography.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/album/album.css +0 -2
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/album/index.html +15 -15
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/blog/blog.css +0 -5
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/blog/index.html +7 -7
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/carousel/carousel.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/carousel/index.html +5 -5
- data/mod/bootstrap/vendor/bootstrap/site/docs/4.1/examples/checkout/form-validation.css +5 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/checkout/index.html +6 -6
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/cover/cover.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/cover/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/dashboard/dashboard.css +0 -7
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/dashboard/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/floating-labels/floating-labels.css +23 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/floating-labels/index.html +2 -2
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/grid/grid.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/grid/index.html +9 -9
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/index.html +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/jumbotron/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/jumbotron/jumbotron.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/navbar-bottom/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/navbar-fixed/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/navbar-fixed/navbar-top-fixed.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/navbar-static/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/navbar-static/navbar-top.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/navbars/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/navbars/navbar.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/offcanvas/index.html +10 -10
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/offcanvas/offcanvas.css +0 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/offcanvas/offcanvas.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/pricing/index.html +10 -10
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/pricing/pricing.css +0 -5
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/product/index.html +15 -15
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/product/product.css +0 -5
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/album.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/blog.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/carousel.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/checkout.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/cover.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/dashboard.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/floating-labels.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/grid.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/jumbotron.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/navbar-bottom.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/navbar-fixed.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/navbar-static.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/navbars.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/offcanvas.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/pricing.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/product.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/sign-in.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/starter-template.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/sticky-footer-navbar.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/screenshots/sticky-footer.png +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/sign-in/index.html +2 -2
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/sign-in/signin.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/starter-template/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/starter-template/starter-template.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/sticky-footer-navbar/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/sticky-footer-navbar/sticky-footer-navbar.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/sticky-footer/index.html +1 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/sticky-footer/sticky-footer.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/tooltip-viewport/index.html +4 -4
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/tooltip-viewport/tooltip-viewport.css +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/examples/tooltip-viewport/tooltip-viewport.js +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/extend/approach.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/extend/icons.md +1 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/extend/index.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/accessibility.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/best-practices.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/browsers-devices.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/build-tools.md +1 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/contents.md +12 -8
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/download.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/introduction.md +2 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/javascript.md +3 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/theming.md +16 -16
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/getting-started/webpack.md +1 -6
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/layout/grid.md +1 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/layout/media-object.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/layout/overview.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/layout/utilities-for-layout.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/migration.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/borders.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/clearfix.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/close-icon.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/colors.md +1 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/display.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/embed.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/flex.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/float.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/image-replacement.md +1 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/position.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/screenreaders.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/shadows.md +1 -1
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/sizing.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/spacing.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/text.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/vertical-align.md +0 -0
- data/mod/bootstrap/vendor/bootstrap/{docs → site/docs}/4.1/utilities/visibility.md +1 -1
- data/mod/bootstrap/vendor/bootstrap/{favicon.ico → site/favicon.ico} +0 -0
- data/mod/bootstrap/vendor/bootstrap/{index.html → site/index.html} +2 -2
- data/mod/bootstrap/vendor/bootstrap/{robots.txt → site/robots.txt} +0 -0
- data/mod/bootstrap/vendor/bootstrap/{sw.js → site/sw.js} +1 -1
- data/mod/carrierwave/lib/carrier_wave/file_card_uploader.rb +1 -1
- data/mod/carrierwave/set/abstract/attachment/upload_cache.rb +5 -8
- data/mod/carrierwave/template/type/file/file_chooser.haml +1 -1
- data/mod/core/set/abstract/code_file.rb +4 -0
- data/mod/core/set/all/haml.rb +2 -2
- data/mod/follow/spec/set/all/notify_spec.rb +2 -1
- data/mod/google_analytics/set/all/google_analytics.rb +5 -3
- data/mod/item/set/all/bar.haml +6 -3
- data/mod/item/set/all/bar.rb +27 -12
- data/mod/item/set/all/box.haml +4 -3
- data/mod/item/set/all/box.rb +1 -1
- data/mod/item/set/all/expanded_bar.haml +8 -6
- data/mod/item/spec/set/all/bar_spec.rb +3 -3
- data/mod/machines/lib/javascript/decko_filter.js.coffee +5 -1
- data/mod/machines/lib/stylesheets/style_cards.scss +16 -24
- data/mod/pointer/set/abstract/01_paging.rb +4 -4
- data/mod/pointer/set/abstract/02_pointer/options_api.rb +10 -12
- data/mod/prosemirror_editor/db/migrate_core_cards/20160804112548_add_prosemirror_cards.rb +1 -1
- data/mod/search/set/abstract/search.rb +9 -6
- data/mod/search/set/abstract/wql_search.rb +20 -5
- data/mod/search/set/self/search.rb +1 -1
- data/mod/standard/set/all/error.rb +15 -0
- data/mod/standard/set/all/rich_html/content.rb +30 -21
- data/mod/standard/set/all/rich_html/content/labeled.haml +4 -0
- data/mod/standard/set/all/rich_html/error.rb +11 -12
- data/mod/standard/set/all/rich_html/title.rb +1 -1
- data/mod/standard/spec/content/chunk/include_spec.rb +1 -1
- data/mod/standard/spec/set/all/error_spec.rb +1 -1
- data/mod/standard/spec/set/type/email_template/email_config_spec.rb +10 -9
- data/mod/standard/spec/set/type/uri_spec.rb +7 -7
- data/mod/tinymce_editor/db/migrate_core_cards/20160804112560_add_tinymce_cards.rb +1 -1
- data/mod/utility/set/abstract/bs_badge/labeled_badge.haml +1 -1
- data/mod/utility/set/abstract/media/media_snippet.haml +1 -2
- metadata +231 -230
- data/mod/bootstrap/vendor/bootstrap/_includes/ads.html +0 -1
- data/mod/bootstrap/vendor/bootstrap/_includes/favicons.html +0 -9
- data/mod/bootstrap/vendor/bootstrap/_includes/scripts.html +0 -26
- data/mod/bootstrap/vendor/bootstrap/assets/brand/bootstrap-outline.svg +0 -6
- data/mod/bootstrap/vendor/bootstrap/assets/brand/bootstrap-punchout.svg +0 -6
- data/mod/bootstrap/vendor/bootstrap/assets/brand/bootstrap-solid.svg +0 -6
- data/mod/bootstrap/vendor/bootstrap/assets/css/docs.min.css.map +0 -1
- data/mod/bootstrap/vendor/bootstrap/assets/img/favicons/safari-pinned-tab.svg +0 -20
- data/mod/bootstrap/vendor/bootstrap/build/upload-preview.sh +0 -13
- data/mod/bootstrap/vendor/bootstrap/docs/4.1/examples/checkout/form-validation.css +0 -11
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/dropdown.js"],"names":["Dropdown","$","NAME","VERSION","DATA_KEY","EVENT_KEY","DATA_API_KEY","JQUERY_NO_CONFLICT","fn","ESCAPE_KEYCODE","SPACE_KEYCODE","TAB_KEYCODE","ARROW_UP_KEYCODE","ARROW_DOWN_KEYCODE","RIGHT_MOUSE_BUTTON_WHICH","REGEXP_KEYDOWN","RegExp","Event","HIDE","HIDDEN","SHOW","SHOWN","CLICK","CLICK_DATA_API","KEYDOWN_DATA_API","KEYUP_DATA_API","ClassName","DISABLED","DROPUP","DROPRIGHT","DROPLEFT","MENURIGHT","MENULEFT","POSITION_STATIC","Selector","DATA_TOGGLE","FORM_CHILD","MENU","NAVBAR_NAV","VISIBLE_ITEMS","AttachmentMap","TOP","TOPEND","BOTTOM","BOTTOMEND","RIGHT","RIGHTEND","LEFT","LEFTEND","Default","offset","flip","boundary","reference","display","DefaultType","element","config","_element","_popper","_config","_getConfig","_menu","_getMenuElement","_inNavbar","_detectNavbar","_addEventListeners","toggle","disabled","hasClass","parent","_getParentFromElement","isActive","_clearMenus","relatedTarget","showEvent","trigger","isDefaultPrevented","Popper","TypeError","referenceElement","Util","isElement","jquery","addClass","_getPopperConfig","document","documentElement","closest","length","body","children","on","noop","focus","setAttribute","toggleClass","dispose","removeData","off","destroy","update","scheduleUpdate","event","preventDefault","stopPropagation","constructor","data","typeCheckConfig","find","_getPlacement","$parentDropdown","placement","offsetConf","offsets","popperConfig","modifiers","enabled","preventOverflow","boundariesElement","applyStyle","_jQueryInterface","each","which","type","toggles","makeArray","i","context","dropdownMenu","test","target","tagName","contains","hideEvent","removeClass","selector","getSelectorFromElement","parentNode","_dataApiKeydownHandler","items","get","index","indexOf","call","e","Constructor","noConflict"],"mappings":";;;;;;;;AAIA;;;;;;AAOA,IAAMA,WAAY,UAACC,CAAD,EAAO;AACvB;;;;;AAMA,MAAMC,OAA2B,UAAjC;AACA,MAAMC,UAA2B,OAAjC;AACA,MAAMC,WAA2B,aAAjC;AACA,MAAMC,kBAA+BD,QAArC;AACA,MAAME,eAA2B,WAAjC;AACA,MAAMC,qBAA2BN,EAAEO,EAAF,CAA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AAY;AAClClJ,MAAEO,EAAF,CAAKN,IAAL,IAAaK,kBAAb;AACA,WAAOP,SAASyH,gBAAhB;AACD,GAHD;;AAKA,SAAOzH,QAAP;AACD,CAzdgB,CAyddC,CAzdc,EAydX6E,MAzdW,CAAjB","sourcesContent":["import $ from 'jquery'\nimport Popper from 'popper.js'\nimport Util from './util'\n\n/**\n * --------------------------------------------------------------------------\n * Bootstrap (v4.1.1): dropdown.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nconst Dropdown = (($) => {\n /**\n * ------------------------------------------------------------------------\n * Constants\n * ------------------------------------------------------------------------\n */\n\n const NAME = 'dropdown'\n const VERSION = '4.1.1'\n const DATA_KEY = 'bs.dropdown'\n const EVENT_KEY = `.${DATA_KEY}`\n const DATA_API_KEY = '.data-api'\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n const ESCAPE_KEYCODE = 27 // KeyboardEvent.which value for Escape (Esc) key\n const SPACE_KEYCODE = 32 // KeyboardEvent.which value for space key\n const TAB_KEYCODE = 9 // KeyboardEvent.which value for tab key\n const ARROW_UP_KEYCODE = 38 // KeyboardEvent.which value for up arrow key\n const ARROW_DOWN_KEYCODE = 40 // KeyboardEvent.which value for down arrow key\n const RIGHT_MOUSE_BUTTON_WHICH = 3 // MouseEvent.which value for the right button (assuming a right-handed mouse)\n const REGEXP_KEYDOWN = new RegExp(`${ARROW_UP_KEYCODE}|${ARROW_DOWN_KEYCODE}|${ESCAPE_KEYCODE}`)\n\n const Event = {\n HIDE : `hide${EVENT_KEY}`,\n HIDDEN : `hidden${EVENT_KEY}`,\n SHOW : `show${EVENT_KEY}`,\n SHOWN : `shown${EVENT_KEY}`,\n CLICK : `click${EVENT_KEY}`,\n CLICK_DATA_API : `click${EVENT_KEY}${DATA_API_KEY}`,\n KEYDOWN_DATA_API : `keydown${EVENT_KEY}${DATA_API_KEY}`,\n KEYUP_DATA_API : `keyup${EVENT_KEY}${DATA_API_KEY}`\n }\n\n const ClassName = {\n DISABLED : 'disabled',\n SHOW : 'show',\n DROPUP : 'dropup',\n DROPRIGHT : 'dropright',\n DROPLEFT : 'dropleft',\n MENURIGHT : 'dropdown-menu-right',\n MENULEFT : 'dropdown-menu-left',\n POSITION_STATIC : 'position-static'\n }\n\n const Selector = {\n DATA_TOGGLE : '[data-toggle=\"dropdown\"]',\n FORM_CHILD : '.dropdown form',\n MENU : '.dropdown-menu',\n NAVBAR_NAV : '.navbar-nav',\n VISIBLE_ITEMS : '.dropdown-menu .dropdown-item:not(.disabled):not(:disabled)'\n }\n\n const AttachmentMap = {\n TOP : 'top-start',\n TOPEND : 'top-end',\n BOTTOM : 'bottom-start',\n BOTTOMEND : 'bottom-end',\n RIGHT : 'right-start',\n RIGHTEND : 'right-end',\n LEFT : 'left-start',\n LEFTEND : 'left-end'\n }\n\n const Default = {\n offset : 0,\n flip : true,\n boundary : 'scrollParent',\n reference : 'toggle',\n display : 'dynamic'\n }\n\n const DefaultType = {\n offset : '(number|string|function)',\n flip : 'boolean',\n boundary : '(string|element)',\n reference : '(string|element)',\n display : 'string'\n }\n\n /**\n * ------------------------------------------------------------------------\n * Class Definition\n * ------------------------------------------------------------------------\n */\n\n class Dropdown {\n constructor(element, config) {\n this._element = element\n this._popper = null\n this._config = this._getConfig(config)\n this._menu = this._getMenuElement()\n this._inNavbar = this._detectNavbar()\n\n this._addEventListeners()\n }\n\n // Getters\n\n static get VERSION() {\n return VERSION\n }\n\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n // Public\n\n toggle() {\n if (this._element.disabled || $(this._element).hasClass(ClassName.DISABLED)) {\n return\n }\n\n const parent = Dropdown._getParentFromElement(this._element)\n const isActive = $(this._menu).hasClass(ClassName.SHOW)\n\n Dropdown._clearMenus()\n\n if (isActive) {\n return\n }\n\n const relatedTarget = {\n relatedTarget: this._element\n }\n const showEvent = $.Event(Event.SHOW, relatedTarget)\n\n $(parent).trigger(showEvent)\n\n if (showEvent.isDefaultPrevented()) {\n return\n }\n\n // Disable totally Popper.js for Dropdown in Navbar\n if (!this._inNavbar) {\n /**\n * Check for Popper dependency\n * Popper - https://popper.js.org\n */\n if (typeof Popper === 'undefined') {\n throw new TypeError('Bootstrap dropdown require Popper.js (https://popper.js.org)')\n }\n\n let referenceElement = this._element\n\n if (this._config.reference === 'parent') {\n referenceElement = parent\n } else if (Util.isElement(this._config.reference)) {\n referenceElement = this._config.reference\n\n // Check if it's jQuery element\n if (typeof this._config.reference.jquery !== 'undefined') {\n referenceElement = this._config.reference[0]\n }\n }\n\n // If boundary is not `scrollParent`, then set position to `static`\n // to allow the menu to \"escape\" the scroll parent's boundaries\n // https://github.com/twbs/bootstrap/issues/24251\n if (this._config.boundary !== 'scrollParent') {\n $(parent).addClass(ClassName.POSITION_STATIC)\n }\n this._popper = new Popper(referenceElement, this._menu, this._getPopperConfig())\n }\n\n // If this is a touch-enabled device we add extra\n // empty mouseover listeners to the body's immediate children;\n // only needed because of broken event delegation on iOS\n // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html\n if ('ontouchstart' in document.documentElement &&\n $(parent).closest(Selector.NAVBAR_NAV).length === 0) {\n $(document.body).children().on('mouseover', null, $.noop)\n }\n\n this._element.focus()\n this._element.setAttribute('aria-expanded', true)\n\n $(this._menu).toggleClass(ClassName.SHOW)\n $(parent)\n .toggleClass(ClassName.SHOW)\n .trigger($.Event(Event.SHOWN, relatedTarget))\n }\n\n dispose() {\n $.removeData(this._element, DATA_KEY)\n $(this._element).off(EVENT_KEY)\n this._element = null\n this._menu = null\n if (this._popper !== null) {\n this._popper.destroy()\n this._popper = null\n }\n }\n\n update() {\n this._inNavbar = this._detectNavbar()\n if (this._popper !== null) {\n this._popper.scheduleUpdate()\n }\n }\n\n // Private\n\n _addEventListeners() {\n $(this._element).on(Event.CLICK, (event) => {\n event.preventDefault()\n event.stopPropagation()\n this.toggle()\n })\n }\n\n _getConfig(config) {\n config = {\n ...this.constructor.Default,\n ...$(this._element).data(),\n ...config\n }\n\n Util.typeCheckConfig(\n NAME,\n config,\n this.constructor.DefaultType\n )\n\n return config\n }\n\n _getMenuElement() {\n if (!this._menu) {\n const parent = Dropdown._getParentFromElement(this._element)\n this._menu = $(parent).find(Selector.MENU)[0]\n }\n return this._menu\n }\n\n _getPlacement() {\n const $parentDropdown = $(this._element).parent()\n let placement = AttachmentMap.BOTTOM\n\n // Handle dropup\n if ($parentDropdown.hasClass(ClassName.DROPUP)) {\n placement = AttachmentMap.TOP\n if ($(this._menu).hasClass(ClassName.MENURIGHT)) {\n placement = AttachmentMap.TOPEND\n }\n } else if ($parentDropdown.hasClass(ClassName.DROPRIGHT)) {\n placement = AttachmentMap.RIGHT\n } else if ($parentDropdown.hasClass(ClassName.DROPLEFT)) {\n placement = AttachmentMap.LEFT\n } else if ($(this._menu).hasClass(ClassName.MENURIGHT)) {\n placement = AttachmentMap.BOTTOMEND\n }\n return placement\n }\n\n _detectNavbar() {\n return $(this._element).closest('.navbar').length > 0\n }\n\n _getPopperConfig() {\n const offsetConf = {}\n if (typeof this._config.offset === 'function') {\n offsetConf.fn = (data) => {\n data.offsets = {\n ...data.offsets,\n ...this._config.offset(data.offsets) || {}\n }\n return data\n }\n } else {\n offsetConf.offset = this._config.offset\n }\n const popperConfig = {\n placement: this._getPlacement(),\n modifiers: {\n offset: offsetConf,\n flip: {\n enabled: this._config.flip\n },\n preventOverflow: {\n boundariesElement: this._config.boundary\n }\n }\n }\n\n // Disable Popper.js if we have a static display\n if (this._config.display === 'static') {\n popperConfig.modifiers.applyStyle = {\n enabled: false\n }\n }\n return popperConfig\n }\n\n // Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _config = typeof config === 'object' ? config : null\n\n if (!data) {\n data = new Dropdown(this, _config)\n $(this).data(DATA_KEY, data)\n }\n\n if (typeof config === 'string') {\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n data[config]()\n }\n })\n }\n\n static _clearMenus(event) {\n if (event && (event.which === RIGHT_MOUSE_BUTTON_WHICH ||\n event.type === 'keyup' && event.which !== TAB_KEYCODE)) {\n return\n }\n\n const toggles = $.makeArray($(Selector.DATA_TOGGLE))\n for (let i = 0; i < toggles.length; i++) {\n const parent = Dropdown._getParentFromElement(toggles[i])\n const context = $(toggles[i]).data(DATA_KEY)\n const relatedTarget = {\n relatedTarget: toggles[i]\n }\n\n if (!context) {\n continue\n }\n\n const dropdownMenu = context._menu\n if (!$(parent).hasClass(ClassName.SHOW)) {\n continue\n }\n\n if (event && (event.type === 'click' &&\n /input|textarea/i.test(event.target.tagName) || event.type === 'keyup' && event.which === TAB_KEYCODE) &&\n $.contains(parent, event.target)) {\n continue\n }\n\n const hideEvent = $.Event(Event.HIDE, relatedTarget)\n $(parent).trigger(hideEvent)\n if (hideEvent.isDefaultPrevented()) {\n continue\n }\n\n // If this is a touch-enabled device we remove the extra\n // empty mouseover listeners we added for iOS support\n if ('ontouchstart' in document.documentElement) {\n $(document.body).children().off('mouseover', null, $.noop)\n }\n\n toggles[i].setAttribute('aria-expanded', 'false')\n\n $(dropdownMenu).removeClass(ClassName.SHOW)\n $(parent)\n .removeClass(ClassName.SHOW)\n .trigger($.Event(Event.HIDDEN, relatedTarget))\n }\n }\n\n static _getParentFromElement(element) {\n let parent\n const selector = Util.getSelectorFromElement(element)\n\n if (selector) {\n parent = $(selector)[0]\n }\n\n return parent || element.parentNode\n }\n\n // eslint-disable-next-line complexity\n static _dataApiKeydownHandler(event) {\n // If not input/textarea:\n // - And not a key in REGEXP_KEYDOWN => not a dropdown command\n // If input/textarea:\n // - If space key => not a dropdown command\n // - If key is other than escape\n // - If key is not up or down => not a dropdown command\n // - If trigger inside the menu => not a dropdown command\n if (/input|textarea/i.test(event.target.tagName)\n ? event.which === SPACE_KEYCODE || event.which !== ESCAPE_KEYCODE &&\n (event.which !== ARROW_DOWN_KEYCODE && event.which !== ARROW_UP_KEYCODE ||\n $(event.target).closest(Selector.MENU).length) : !REGEXP_KEYDOWN.test(event.which)) {\n return\n }\n\n event.preventDefault()\n event.stopPropagation()\n\n if (this.disabled || $(this).hasClass(ClassName.DISABLED)) {\n return\n }\n\n const parent = Dropdown._getParentFromElement(this)\n const isActive = $(parent).hasClass(ClassName.SHOW)\n\n if (!isActive && (event.which !== ESCAPE_KEYCODE || event.which !== SPACE_KEYCODE) ||\n isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) {\n if (event.which === ESCAPE_KEYCODE) {\n const toggle = $(parent).find(Selector.DATA_TOGGLE)[0]\n $(toggle).trigger('focus')\n }\n\n $(this).trigger('click')\n return\n }\n\n const items = $(parent).find(Selector.VISIBLE_ITEMS).get()\n\n if (items.length === 0) {\n return\n }\n\n let index = items.indexOf(event.target)\n\n if (event.which === ARROW_UP_KEYCODE && index > 0) { // Up\n index--\n }\n\n if (event.which === ARROW_DOWN_KEYCODE && index < items.length - 1) { // Down\n index++\n }\n\n if (index < 0) {\n index = 0\n }\n\n items[index].focus()\n }\n }\n\n /**\n * ------------------------------------------------------------------------\n * Data Api implementation\n * ------------------------------------------------------------------------\n */\n\n $(document)\n .on(Event.KEYDOWN_DATA_API, Selector.DATA_TOGGLE, Dropdown._dataApiKeydownHandler)\n .on(Event.KEYDOWN_DATA_API, Selector.MENU, Dropdown._dataApiKeydownHandler)\n .on(`${Event.CLICK_DATA_API} ${Event.KEYUP_DATA_API}`, Dropdown._clearMenus)\n .on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {\n event.preventDefault()\n event.stopPropagation()\n Dropdown._jQueryInterface.call($(this), 'toggle')\n })\n .on(Event.CLICK_DATA_API, Selector.FORM_CHILD, (e) => {\n e.stopPropagation()\n })\n\n /**\n * ------------------------------------------------------------------------\n * jQuery\n * ------------------------------------------------------------------------\n */\n\n $.fn[NAME] = Dropdown._jQueryInterface\n $.fn[NAME].Constructor = Dropdown\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return Dropdown._jQueryInterface\n }\n\n return Dropdown\n})($, Popper)\n\nexport default Dropdown\n"],"file":"dropdown.js"}
|
1
|
+
{"version":3,"file":"dropdown.js","sources":["../src/dropdown.js"],"sourcesContent":["import $ from 'jquery'\nimport Popper from 'popper.js'\nimport Util from './util'\n\n/**\n * --------------------------------------------------------------------------\n * Bootstrap (v4.1.3): dropdown.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nconst Dropdown = (($) => {\n /**\n * ------------------------------------------------------------------------\n * Constants\n * ------------------------------------------------------------------------\n */\n\n const NAME = 'dropdown'\n const VERSION = '4.1.3'\n const DATA_KEY = 'bs.dropdown'\n const EVENT_KEY = `.${DATA_KEY}`\n const DATA_API_KEY = '.data-api'\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n const ESCAPE_KEYCODE = 27 // KeyboardEvent.which value for Escape (Esc) key\n const SPACE_KEYCODE = 32 // KeyboardEvent.which value for space key\n const TAB_KEYCODE = 9 // KeyboardEvent.which value for tab key\n const ARROW_UP_KEYCODE = 38 // KeyboardEvent.which value for up arrow key\n const ARROW_DOWN_KEYCODE = 40 // KeyboardEvent.which value for down arrow key\n const RIGHT_MOUSE_BUTTON_WHICH = 3 // MouseEvent.which value for the right button (assuming a right-handed mouse)\n const REGEXP_KEYDOWN = new RegExp(`${ARROW_UP_KEYCODE}|${ARROW_DOWN_KEYCODE}|${ESCAPE_KEYCODE}`)\n\n const Event = {\n HIDE : `hide${EVENT_KEY}`,\n HIDDEN : `hidden${EVENT_KEY}`,\n SHOW : `show${EVENT_KEY}`,\n SHOWN : `shown${EVENT_KEY}`,\n CLICK : `click${EVENT_KEY}`,\n CLICK_DATA_API : `click${EVENT_KEY}${DATA_API_KEY}`,\n KEYDOWN_DATA_API : `keydown${EVENT_KEY}${DATA_API_KEY}`,\n KEYUP_DATA_API : `keyup${EVENT_KEY}${DATA_API_KEY}`\n }\n\n const ClassName = {\n DISABLED : 'disabled',\n SHOW : 'show',\n DROPUP : 'dropup',\n DROPRIGHT : 'dropright',\n DROPLEFT : 'dropleft',\n MENURIGHT : 'dropdown-menu-right',\n MENULEFT : 'dropdown-menu-left',\n POSITION_STATIC : 'position-static'\n }\n\n const Selector = {\n DATA_TOGGLE : '[data-toggle=\"dropdown\"]',\n FORM_CHILD : '.dropdown form',\n MENU : '.dropdown-menu',\n NAVBAR_NAV : '.navbar-nav',\n VISIBLE_ITEMS : '.dropdown-menu .dropdown-item:not(.disabled):not(:disabled)'\n }\n\n const AttachmentMap = {\n TOP : 'top-start',\n TOPEND : 'top-end',\n BOTTOM : 'bottom-start',\n BOTTOMEND : 'bottom-end',\n RIGHT : 'right-start',\n RIGHTEND : 'right-end',\n LEFT : 'left-start',\n LEFTEND : 'left-end'\n }\n\n const Default = {\n offset : 0,\n flip : true,\n boundary : 'scrollParent',\n reference : 'toggle',\n display : 'dynamic'\n }\n\n const DefaultType = {\n offset : '(number|string|function)',\n flip : 'boolean',\n boundary : '(string|element)',\n reference : '(string|element)',\n display : 'string'\n }\n\n /**\n * ------------------------------------------------------------------------\n * Class Definition\n * ------------------------------------------------------------------------\n */\n\n class Dropdown {\n constructor(element, config) {\n this._element = element\n this._popper = null\n this._config = this._getConfig(config)\n this._menu = this._getMenuElement()\n this._inNavbar = this._detectNavbar()\n\n this._addEventListeners()\n }\n\n // Getters\n\n static get VERSION() {\n return VERSION\n }\n\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n // Public\n\n toggle() {\n if (this._element.disabled || $(this._element).hasClass(ClassName.DISABLED)) {\n return\n }\n\n const parent = Dropdown._getParentFromElement(this._element)\n const isActive = $(this._menu).hasClass(ClassName.SHOW)\n\n Dropdown._clearMenus()\n\n if (isActive) {\n return\n }\n\n const relatedTarget = {\n relatedTarget: this._element\n }\n const showEvent = $.Event(Event.SHOW, relatedTarget)\n\n $(parent).trigger(showEvent)\n\n if (showEvent.isDefaultPrevented()) {\n return\n }\n\n // Disable totally Popper.js for Dropdown in Navbar\n if (!this._inNavbar) {\n /**\n * Check for Popper dependency\n * Popper - https://popper.js.org\n */\n if (typeof Popper === 'undefined') {\n throw new TypeError('Bootstrap dropdown require Popper.js (https://popper.js.org)')\n }\n\n let referenceElement = this._element\n\n if (this._config.reference === 'parent') {\n referenceElement = parent\n } else if (Util.isElement(this._config.reference)) {\n referenceElement = this._config.reference\n\n // Check if it's jQuery element\n if (typeof this._config.reference.jquery !== 'undefined') {\n referenceElement = this._config.reference[0]\n }\n }\n\n // If boundary is not `scrollParent`, then set position to `static`\n // to allow the menu to \"escape\" the scroll parent's boundaries\n // https://github.com/twbs/bootstrap/issues/24251\n if (this._config.boundary !== 'scrollParent') {\n $(parent).addClass(ClassName.POSITION_STATIC)\n }\n this._popper = new Popper(referenceElement, this._menu, this._getPopperConfig())\n }\n\n // If this is a touch-enabled device we add extra\n // empty mouseover listeners to the body's immediate children;\n // only needed because of broken event delegation on iOS\n // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html\n if ('ontouchstart' in document.documentElement &&\n $(parent).closest(Selector.NAVBAR_NAV).length === 0) {\n $(document.body).children().on('mouseover', null, $.noop)\n }\n\n this._element.focus()\n this._element.setAttribute('aria-expanded', true)\n\n $(this._menu).toggleClass(ClassName.SHOW)\n $(parent)\n .toggleClass(ClassName.SHOW)\n .trigger($.Event(Event.SHOWN, relatedTarget))\n }\n\n dispose() {\n $.removeData(this._element, DATA_KEY)\n $(this._element).off(EVENT_KEY)\n this._element = null\n this._menu = null\n if (this._popper !== null) {\n this._popper.destroy()\n this._popper = null\n }\n }\n\n update() {\n this._inNavbar = this._detectNavbar()\n if (this._popper !== null) {\n this._popper.scheduleUpdate()\n }\n }\n\n // Private\n\n _addEventListeners() {\n $(this._element).on(Event.CLICK, (event) => {\n event.preventDefault()\n event.stopPropagation()\n this.toggle()\n })\n }\n\n _getConfig(config) {\n config = {\n ...this.constructor.Default,\n ...$(this._element).data(),\n ...config\n }\n\n Util.typeCheckConfig(\n NAME,\n config,\n this.constructor.DefaultType\n )\n\n return config\n }\n\n _getMenuElement() {\n if (!this._menu) {\n const parent = Dropdown._getParentFromElement(this._element)\n if (parent) {\n this._menu = parent.querySelector(Selector.MENU)\n }\n }\n return this._menu\n }\n\n _getPlacement() {\n const $parentDropdown = $(this._element.parentNode)\n let placement = AttachmentMap.BOTTOM\n\n // Handle dropup\n if ($parentDropdown.hasClass(ClassName.DROPUP)) {\n placement = AttachmentMap.TOP\n if ($(this._menu).hasClass(ClassName.MENURIGHT)) {\n placement = AttachmentMap.TOPEND\n }\n } else if ($parentDropdown.hasClass(ClassName.DROPRIGHT)) {\n placement = AttachmentMap.RIGHT\n } else if ($parentDropdown.hasClass(ClassName.DROPLEFT)) {\n placement = AttachmentMap.LEFT\n } else if ($(this._menu).hasClass(ClassName.MENURIGHT)) {\n placement = AttachmentMap.BOTTOMEND\n }\n return placement\n }\n\n _detectNavbar() {\n return $(this._element).closest('.navbar').length > 0\n }\n\n _getPopperConfig() {\n const offsetConf = {}\n if (typeof this._config.offset === 'function') {\n offsetConf.fn = (data) => {\n data.offsets = {\n ...data.offsets,\n ...this._config.offset(data.offsets) || {}\n }\n return data\n }\n } else {\n offsetConf.offset = this._config.offset\n }\n\n const popperConfig = {\n placement: this._getPlacement(),\n modifiers: {\n offset: offsetConf,\n flip: {\n enabled: this._config.flip\n },\n preventOverflow: {\n boundariesElement: this._config.boundary\n }\n }\n }\n\n // Disable Popper.js if we have a static display\n if (this._config.display === 'static') {\n popperConfig.modifiers.applyStyle = {\n enabled: false\n }\n }\n return popperConfig\n }\n\n // Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _config = typeof config === 'object' ? config : null\n\n if (!data) {\n data = new Dropdown(this, _config)\n $(this).data(DATA_KEY, data)\n }\n\n if (typeof config === 'string') {\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n data[config]()\n }\n })\n }\n\n static _clearMenus(event) {\n if (event && (event.which === RIGHT_MOUSE_BUTTON_WHICH ||\n event.type === 'keyup' && event.which !== TAB_KEYCODE)) {\n return\n }\n\n const toggles = [].slice.call(document.querySelectorAll(Selector.DATA_TOGGLE))\n for (let i = 0, len = toggles.length; i < len; i++) {\n const parent = Dropdown._getParentFromElement(toggles[i])\n const context = $(toggles[i]).data(DATA_KEY)\n const relatedTarget = {\n relatedTarget: toggles[i]\n }\n\n if (event && event.type === 'click') {\n relatedTarget.clickEvent = event\n }\n\n if (!context) {\n continue\n }\n\n const dropdownMenu = context._menu\n if (!$(parent).hasClass(ClassName.SHOW)) {\n continue\n }\n\n if (event && (event.type === 'click' &&\n /input|textarea/i.test(event.target.tagName) || event.type === 'keyup' && event.which === TAB_KEYCODE) &&\n $.contains(parent, event.target)) {\n continue\n }\n\n const hideEvent = $.Event(Event.HIDE, relatedTarget)\n $(parent).trigger(hideEvent)\n if (hideEvent.isDefaultPrevented()) {\n continue\n }\n\n // If this is a touch-enabled device we remove the extra\n // empty mouseover listeners we added for iOS support\n if ('ontouchstart' in document.documentElement) {\n $(document.body).children().off('mouseover', null, $.noop)\n }\n\n toggles[i].setAttribute('aria-expanded', 'false')\n\n $(dropdownMenu).removeClass(ClassName.SHOW)\n $(parent)\n .removeClass(ClassName.SHOW)\n .trigger($.Event(Event.HIDDEN, relatedTarget))\n }\n }\n\n static _getParentFromElement(element) {\n let parent\n const selector = Util.getSelectorFromElement(element)\n\n if (selector) {\n parent = document.querySelector(selector)\n }\n\n return parent || element.parentNode\n }\n\n // eslint-disable-next-line complexity\n static _dataApiKeydownHandler(event) {\n // If not input/textarea:\n // - And not a key in REGEXP_KEYDOWN => not a dropdown command\n // If input/textarea:\n // - If space key => not a dropdown command\n // - If key is other than escape\n // - If key is not up or down => not a dropdown command\n // - If trigger inside the menu => not a dropdown command\n if (/input|textarea/i.test(event.target.tagName)\n ? event.which === SPACE_KEYCODE || event.which !== ESCAPE_KEYCODE &&\n (event.which !== ARROW_DOWN_KEYCODE && event.which !== ARROW_UP_KEYCODE ||\n $(event.target).closest(Selector.MENU).length) : !REGEXP_KEYDOWN.test(event.which)) {\n return\n }\n\n event.preventDefault()\n event.stopPropagation()\n\n if (this.disabled || $(this).hasClass(ClassName.DISABLED)) {\n return\n }\n\n const parent = Dropdown._getParentFromElement(this)\n const isActive = $(parent).hasClass(ClassName.SHOW)\n\n if (!isActive && (event.which !== ESCAPE_KEYCODE || event.which !== SPACE_KEYCODE) ||\n isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) {\n if (event.which === ESCAPE_KEYCODE) {\n const toggle = parent.querySelector(Selector.DATA_TOGGLE)\n $(toggle).trigger('focus')\n }\n\n $(this).trigger('click')\n return\n }\n\n const items = [].slice.call(parent.querySelectorAll(Selector.VISIBLE_ITEMS))\n\n if (items.length === 0) {\n return\n }\n\n let index = items.indexOf(event.target)\n\n if (event.which === ARROW_UP_KEYCODE && index > 0) { // Up\n index--\n }\n\n if (event.which === ARROW_DOWN_KEYCODE && index < items.length - 1) { // Down\n index++\n }\n\n if (index < 0) {\n index = 0\n }\n\n items[index].focus()\n }\n }\n\n /**\n * ------------------------------------------------------------------------\n * Data Api implementation\n * ------------------------------------------------------------------------\n */\n\n $(document)\n .on(Event.KEYDOWN_DATA_API, Selector.DATA_TOGGLE, Dropdown._dataApiKeydownHandler)\n .on(Event.KEYDOWN_DATA_API, Selector.MENU, Dropdown._dataApiKeydownHandler)\n .on(`${Event.CLICK_DATA_API} ${Event.KEYUP_DATA_API}`, Dropdown._clearMenus)\n .on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {\n event.preventDefault()\n event.stopPropagation()\n Dropdown._jQueryInterface.call($(this), 'toggle')\n })\n .on(Event.CLICK_DATA_API, Selector.FORM_CHILD, (e) => {\n e.stopPropagation()\n })\n\n /**\n * ------------------------------------------------------------------------\n * jQuery\n * ------------------------------------------------------------------------\n */\n\n $.fn[NAME] = Dropdown._jQueryInterface\n $.fn[NAME].Constructor = Dropdown\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return Dropdown._jQueryInterface\n }\n\n return Dropdown\n})($, Popper)\n\nexport default Dropdown\n"],"names":["Dropdown","$","NAME","VERSION","DATA_KEY","EVENT_KEY","DATA_API_KEY","JQUERY_NO_CONFLICT","fn","ESCAPE_KEYCODE","SPACE_KEYCODE","TAB_KEYCODE","ARROW_UP_KEYCODE","ARROW_DOWN_KEYCODE","RIGHT_MOUSE_BUTTON_WHICH","REGEXP_KEYDOWN","RegExp","Event","HIDE","HIDDEN","SHOW","SHOWN","CLICK","CLICK_DATA_API","KEYDOWN_DATA_API","KEYUP_DATA_API","ClassName","DISABLED","DROPUP","DROPRIGHT","DROPLEFT","MENURIGHT","MENULEFT","POSITION_STATIC","Selector","DATA_TOGGLE","FORM_CHILD","MENU","NAVBAR_NAV","VISIBLE_ITEMS","AttachmentMap","TOP","TOPEND","BOTTOM","BOTTOMEND","RIGHT","RIGHTEND","LEFT","LEFTEND","Default","offset","flip","boundary","reference","display","DefaultType","element","config","_element","_popper","_config","_getConfig","_menu","_getMenuElement","_inNavbar","_detectNavbar","_addEventListeners","toggle","disabled","hasClass","parent","_getParentFromElement","isActive","_clearMenus","relatedTarget","showEvent","trigger","isDefaultPrevented","Popper","TypeError","referenceElement","Util","isElement","jquery","addClass","_getPopperConfig","document","documentElement","closest","length","body","children","on","noop","focus","setAttribute","toggleClass","dispose","removeData","off","destroy","update","scheduleUpdate","event","preventDefault","stopPropagation","constructor","data","typeCheckConfig","querySelector","_getPlacement","$parentDropdown","parentNode","placement","offsetConf","offsets","popperConfig","modifiers","enabled","preventOverflow","boundariesElement","applyStyle","_jQueryInterface","each","which","type","toggles","slice","call","querySelectorAll","i","len","context","clickEvent","dropdownMenu","test","target","tagName","contains","hideEvent","removeClass","selector","getSelectorFromElement","_dataApiKeydownHandler","items","index","indexOf","e","Constructor","noConflict"],"mappings":";;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/B,EAAwC,QAAxC;EACD,GARH,EASG2F,EATH,CASM3E,MAAMM,cATZ,EAS4BW,SAASE,UATrC,EASiD,UAAC+G,CAAD,EAAO;EACpDA,MAAE1C,eAAF;EACD,GAXH;EAaA;;;;;;EAMAxG,OAAEO,EAAF,CAAKN,IAAL,IAAaF,SAAS0H,gBAAtB;EACAzH,OAAEO,EAAF,CAAKN,IAAL,EAAWkJ,WAAX,GAAyBpJ,QAAzB;;EACAC,OAAEO,EAAF,CAAKN,IAAL,EAAWmJ,UAAX,GAAwB,YAAY;EAClCpJ,SAAEO,EAAF,CAAKN,IAAL,IAAaK,kBAAb;EACA,WAAOP,SAAS0H,gBAAhB;EACD,GAHD;;EAKA,SAAO1H,QAAP;EACD,CAhegB,CAgedC,CAhec,EAgeX6E,MAheW,CAAjB;;;;;;;;"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
/**
|
2
2
|
* --------------------------------------------------------------------------
|
3
|
-
* Bootstrap (v4.1.
|
3
|
+
* Bootstrap (v4.1.3): index.js
|
4
4
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
|
5
5
|
* --------------------------------------------------------------------------
|
6
6
|
*/
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/index.js"],"names":["$","TypeError","version","fn","jquery","split","minMajor","ltMajor","minMinor","minPatch","maxMajor","Error"],"mappings":"AAaA;;;;;;AAOA,CAAC,UAACA,CAAD,EAAO;AACN,MAAI,OAAOA,CAAP,KAAa,WAAjB,EAA8B;AAC5B,UAAM,IAAIC,SAAJ,CAAc,kGAAd,CAAN;AACD;;AAED,MAAMC,UAAUF,EAAEG,EAAF,CAAKC,MAAL,CAAYC,KAAZ,CAAkB,GAAlB,EAAuB,CAAvB,EAA0BA,KAA1B,CAAgC,GAAhC,CAAhB;AACA,MAAMC,WAAW,CAAjB;AACA,MAAMC,UAAU,CAAhB;AACA,MAAMC,WAAW,CAAjB;AACA,MAAMC,WAAW,CAAjB;AACA,MAAMC,WAAW,CAAjB;;AAEA,MAAIR,QAAQ,CAAR,IAAaK,OAAb,IAAwBL,QAAQ,CAAR,IAAaM,QAArC,IAAiDN,QAAQ,CAAR,MAAeI,QAAf,IAA2BJ,QAAQ,CAAR,MAAeM,QAA1C,IAAsDN,QAAQ,CAAR,IAAaO,QAApH,IAAgIP,QAAQ,CAAR,KAAcQ,QAAlJ,EAA4J;AAC1J,UAAM,IAAIC,KAAJ,CAAU,8EAAV,CAAN;AACD;AACF,CAfD,EAeGX,CAfH","sourcesContent":["import $ from 'jquery'\nimport Alert from './alert'\nimport Button from './button'\nimport Carousel from './carousel'\nimport Collapse from './collapse'\nimport Dropdown from './dropdown'\nimport Modal from './modal'\nimport Popover from './popover'\nimport Scrollspy from './scrollspy'\nimport Tab from './tab'\nimport Tooltip from './tooltip'\nimport Util from './util'\n\n/**\n * --------------------------------------------------------------------------\n * Bootstrap (v4.1.
|
1
|
+
{"version":3,"sources":["../src/index.js"],"names":["$","TypeError","version","fn","jquery","split","minMajor","ltMajor","minMinor","minPatch","maxMajor","Error"],"mappings":"AAaA;;;;;;AAOA,CAAC,UAACA,CAAD,EAAO;AACN,MAAI,OAAOA,CAAP,KAAa,WAAjB,EAA8B;AAC5B,UAAM,IAAIC,SAAJ,CAAc,kGAAd,CAAN;AACD;;AAED,MAAMC,UAAUF,EAAEG,EAAF,CAAKC,MAAL,CAAYC,KAAZ,CAAkB,GAAlB,EAAuB,CAAvB,EAA0BA,KAA1B,CAAgC,GAAhC,CAAhB;AACA,MAAMC,WAAW,CAAjB;AACA,MAAMC,UAAU,CAAhB;AACA,MAAMC,WAAW,CAAjB;AACA,MAAMC,WAAW,CAAjB;AACA,MAAMC,WAAW,CAAjB;;AAEA,MAAIR,QAAQ,CAAR,IAAaK,OAAb,IAAwBL,QAAQ,CAAR,IAAaM,QAArC,IAAiDN,QAAQ,CAAR,MAAeI,QAAf,IAA2BJ,QAAQ,CAAR,MAAeM,QAA1C,IAAsDN,QAAQ,CAAR,IAAaO,QAApH,IAAgIP,QAAQ,CAAR,KAAcQ,QAAlJ,EAA4J;AAC1J,UAAM,IAAIC,KAAJ,CAAU,8EAAV,CAAN;AACD;AACF,CAfD,EAeGX,CAfH","sourcesContent":["import $ from 'jquery'\nimport Alert from './alert'\nimport Button from './button'\nimport Carousel from './carousel'\nimport Collapse from './collapse'\nimport Dropdown from './dropdown'\nimport Modal from './modal'\nimport Popover from './popover'\nimport Scrollspy from './scrollspy'\nimport Tab from './tab'\nimport Tooltip from './tooltip'\nimport Util from './util'\n\n/**\n * --------------------------------------------------------------------------\n * Bootstrap (v4.1.2): index.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n * --------------------------------------------------------------------------\n */\n\n(($) => {\n if (typeof $ === 'undefined') {\n throw new TypeError('Bootstrap\\'s JavaScript requires jQuery. jQuery must be included before Bootstrap\\'s JavaScript.')\n }\n\n const version = $.fn.jquery.split(' ')[0].split('.')\n const minMajor = 1\n const ltMajor = 2\n const minMinor = 9\n const minPatch = 1\n const maxMajor = 4\n\n if (version[0] < ltMajor && version[1] < minMinor || version[0] === minMajor && version[1] === minMinor && version[2] < minPatch || version[0] >= maxMajor) {\n throw new Error('Bootstrap\\'s JavaScript requires at least jQuery v1.9.1 but less than v4.0.0')\n }\n})($)\n\nexport {\n Util,\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Popover,\n Scrollspy,\n Tab,\n Tooltip\n}\n"],"file":"index.js"}
|
@@ -1,585 +1,634 @@
|
|
1
|
-
|
1
|
+
(function (global, factory) {
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('jquery'), require('./util.js')) :
|
3
|
+
typeof define === 'function' && define.amd ? define(['jquery', './util.js'], factory) :
|
4
|
+
(global.Modal = factory(global.jQuery,global.Util));
|
5
|
+
}(this, (function ($,Util) { 'use strict';
|
6
|
+
|
7
|
+
$ = $ && $.hasOwnProperty('default') ? $['default'] : $;
|
8
|
+
Util = Util && Util.hasOwnProperty('default') ? Util['default'] : Util;
|
9
|
+
|
10
|
+
function _defineProperties(target, props) {
|
11
|
+
for (var i = 0; i < props.length; i++) {
|
12
|
+
var descriptor = props[i];
|
13
|
+
descriptor.enumerable = descriptor.enumerable || false;
|
14
|
+
descriptor.configurable = true;
|
15
|
+
if ("value" in descriptor) descriptor.writable = true;
|
16
|
+
Object.defineProperty(target, descriptor.key, descriptor);
|
17
|
+
}
|
18
|
+
}
|
19
|
+
|
20
|
+
function _createClass(Constructor, protoProps, staticProps) {
|
21
|
+
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
22
|
+
if (staticProps) _defineProperties(Constructor, staticProps);
|
23
|
+
return Constructor;
|
24
|
+
}
|
25
|
+
|
26
|
+
function _defineProperty(obj, key, value) {
|
27
|
+
if (key in obj) {
|
28
|
+
Object.defineProperty(obj, key, {
|
29
|
+
value: value,
|
30
|
+
enumerable: true,
|
31
|
+
configurable: true,
|
32
|
+
writable: true
|
33
|
+
});
|
34
|
+
} else {
|
35
|
+
obj[key] = value;
|
36
|
+
}
|
2
37
|
|
3
|
-
|
38
|
+
return obj;
|
39
|
+
}
|
40
|
+
|
41
|
+
function _objectSpread(target) {
|
42
|
+
for (var i = 1; i < arguments.length; i++) {
|
43
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
44
|
+
var ownKeys = Object.keys(source);
|
45
|
+
|
46
|
+
if (typeof Object.getOwnPropertySymbols === 'function') {
|
47
|
+
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
|
48
|
+
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
49
|
+
}));
|
50
|
+
}
|
4
51
|
|
5
|
-
|
52
|
+
ownKeys.forEach(function (key) {
|
53
|
+
_defineProperty(target, key, source[key]);
|
54
|
+
});
|
55
|
+
}
|
6
56
|
|
7
|
-
|
57
|
+
return target;
|
58
|
+
}
|
8
59
|
|
9
|
-
/**
|
10
|
-
* --------------------------------------------------------------------------
|
11
|
-
* Bootstrap (v4.1.1): modal.js
|
12
|
-
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
|
13
|
-
* --------------------------------------------------------------------------
|
14
|
-
*/
|
15
|
-
var Modal = function ($) {
|
16
60
|
/**
|
17
|
-
*
|
18
|
-
*
|
19
|
-
*
|
61
|
+
* --------------------------------------------------------------------------
|
62
|
+
* Bootstrap (v4.1.3): modal.js
|
63
|
+
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
|
64
|
+
* --------------------------------------------------------------------------
|
20
65
|
*/
|
21
|
-
|
22
|
-
var
|
23
|
-
var DATA_KEY = 'bs.modal';
|
24
|
-
var EVENT_KEY = "." + DATA_KEY;
|
25
|
-
var DATA_API_KEY = '.data-api';
|
26
|
-
var JQUERY_NO_CONFLICT = $.fn[NAME];
|
27
|
-
var ESCAPE_KEYCODE = 27; // KeyboardEvent.which value for Escape (Esc) key
|
28
|
-
|
29
|
-
var Default = {
|
30
|
-
backdrop: true,
|
31
|
-
keyboard: true,
|
32
|
-
focus: true,
|
33
|
-
show: true
|
34
|
-
};
|
35
|
-
var DefaultType = {
|
36
|
-
backdrop: '(boolean|string)',
|
37
|
-
keyboard: 'boolean',
|
38
|
-
focus: 'boolean',
|
39
|
-
show: 'boolean'
|
40
|
-
};
|
41
|
-
var Event = {
|
42
|
-
HIDE: "hide" + EVENT_KEY,
|
43
|
-
HIDDEN: "hidden" + EVENT_KEY,
|
44
|
-
SHOW: "show" + EVENT_KEY,
|
45
|
-
SHOWN: "shown" + EVENT_KEY,
|
46
|
-
FOCUSIN: "focusin" + EVENT_KEY,
|
47
|
-
RESIZE: "resize" + EVENT_KEY,
|
48
|
-
CLICK_DISMISS: "click.dismiss" + EVENT_KEY,
|
49
|
-
KEYDOWN_DISMISS: "keydown.dismiss" + EVENT_KEY,
|
50
|
-
MOUSEUP_DISMISS: "mouseup.dismiss" + EVENT_KEY,
|
51
|
-
MOUSEDOWN_DISMISS: "mousedown.dismiss" + EVENT_KEY,
|
52
|
-
CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY
|
53
|
-
};
|
54
|
-
var ClassName = {
|
55
|
-
SCROLLBAR_MEASURER: 'modal-scrollbar-measure',
|
56
|
-
BACKDROP: 'modal-backdrop',
|
57
|
-
OPEN: 'modal-open',
|
58
|
-
FADE: 'fade',
|
59
|
-
SHOW: 'show'
|
60
|
-
};
|
61
|
-
var Selector = {
|
62
|
-
DIALOG: '.modal-dialog',
|
63
|
-
DATA_TOGGLE: '[data-toggle="modal"]',
|
64
|
-
DATA_DISMISS: '[data-dismiss="modal"]',
|
65
|
-
FIXED_CONTENT: '.fixed-top, .fixed-bottom, .is-fixed, .sticky-top',
|
66
|
-
STICKY_CONTENT: '.sticky-top',
|
67
|
-
NAVBAR_TOGGLER: '.navbar-toggler'
|
66
|
+
|
67
|
+
var Modal = function ($$$1) {
|
68
68
|
/**
|
69
69
|
* ------------------------------------------------------------------------
|
70
|
-
*
|
70
|
+
* Constants
|
71
71
|
* ------------------------------------------------------------------------
|
72
72
|
*/
|
73
|
+
var NAME = 'modal';
|
74
|
+
var VERSION = '4.1.3';
|
75
|
+
var DATA_KEY = 'bs.modal';
|
76
|
+
var EVENT_KEY = "." + DATA_KEY;
|
77
|
+
var DATA_API_KEY = '.data-api';
|
78
|
+
var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
|
79
|
+
var ESCAPE_KEYCODE = 27; // KeyboardEvent.which value for Escape (Esc) key
|
80
|
+
|
81
|
+
var Default = {
|
82
|
+
backdrop: true,
|
83
|
+
keyboard: true,
|
84
|
+
focus: true,
|
85
|
+
show: true
|
86
|
+
};
|
87
|
+
var DefaultType = {
|
88
|
+
backdrop: '(boolean|string)',
|
89
|
+
keyboard: 'boolean',
|
90
|
+
focus: 'boolean',
|
91
|
+
show: 'boolean'
|
92
|
+
};
|
93
|
+
var Event = {
|
94
|
+
HIDE: "hide" + EVENT_KEY,
|
95
|
+
HIDDEN: "hidden" + EVENT_KEY,
|
96
|
+
SHOW: "show" + EVENT_KEY,
|
97
|
+
SHOWN: "shown" + EVENT_KEY,
|
98
|
+
FOCUSIN: "focusin" + EVENT_KEY,
|
99
|
+
RESIZE: "resize" + EVENT_KEY,
|
100
|
+
CLICK_DISMISS: "click.dismiss" + EVENT_KEY,
|
101
|
+
KEYDOWN_DISMISS: "keydown.dismiss" + EVENT_KEY,
|
102
|
+
MOUSEUP_DISMISS: "mouseup.dismiss" + EVENT_KEY,
|
103
|
+
MOUSEDOWN_DISMISS: "mousedown.dismiss" + EVENT_KEY,
|
104
|
+
CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY
|
105
|
+
};
|
106
|
+
var ClassName = {
|
107
|
+
SCROLLBAR_MEASURER: 'modal-scrollbar-measure',
|
108
|
+
BACKDROP: 'modal-backdrop',
|
109
|
+
OPEN: 'modal-open',
|
110
|
+
FADE: 'fade',
|
111
|
+
SHOW: 'show'
|
112
|
+
};
|
113
|
+
var Selector = {
|
114
|
+
DIALOG: '.modal-dialog',
|
115
|
+
DATA_TOGGLE: '[data-toggle="modal"]',
|
116
|
+
DATA_DISMISS: '[data-dismiss="modal"]',
|
117
|
+
FIXED_CONTENT: '.fixed-top, .fixed-bottom, .is-fixed, .sticky-top',
|
118
|
+
STICKY_CONTENT: '.sticky-top'
|
119
|
+
/**
|
120
|
+
* ------------------------------------------------------------------------
|
121
|
+
* Class Definition
|
122
|
+
* ------------------------------------------------------------------------
|
123
|
+
*/
|
73
124
|
|
74
|
-
|
125
|
+
};
|
75
126
|
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
127
|
+
var Modal =
|
128
|
+
/*#__PURE__*/
|
129
|
+
function () {
|
130
|
+
function Modal(element, config) {
|
131
|
+
this._config = this._getConfig(config);
|
132
|
+
this._element = element;
|
133
|
+
this._dialog = element.querySelector(Selector.DIALOG);
|
134
|
+
this._backdrop = null;
|
135
|
+
this._isShown = false;
|
136
|
+
this._isBodyOverflowing = false;
|
137
|
+
this._ignoreBackdropClick = false;
|
138
|
+
this._scrollbarWidth = 0;
|
139
|
+
} // Getters
|
89
140
|
|
90
141
|
|
91
|
-
|
142
|
+
var _proto = Modal.prototype;
|
92
143
|
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
144
|
+
// Public
|
145
|
+
_proto.toggle = function toggle(relatedTarget) {
|
146
|
+
return this._isShown ? this.hide() : this.show(relatedTarget);
|
147
|
+
};
|
97
148
|
|
98
|
-
|
99
|
-
|
149
|
+
_proto.show = function show(relatedTarget) {
|
150
|
+
var _this = this;
|
100
151
|
|
101
|
-
|
102
|
-
|
103
|
-
|
152
|
+
if (this._isTransitioning || this._isShown) {
|
153
|
+
return;
|
154
|
+
}
|
104
155
|
|
105
|
-
|
106
|
-
|
107
|
-
|
156
|
+
if ($$$1(this._element).hasClass(ClassName.FADE)) {
|
157
|
+
this._isTransitioning = true;
|
158
|
+
}
|
108
159
|
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
160
|
+
var showEvent = $$$1.Event(Event.SHOW, {
|
161
|
+
relatedTarget: relatedTarget
|
162
|
+
});
|
163
|
+
$$$1(this._element).trigger(showEvent);
|
113
164
|
|
114
|
-
|
115
|
-
|
116
|
-
|
165
|
+
if (this._isShown || showEvent.isDefaultPrevented()) {
|
166
|
+
return;
|
167
|
+
}
|
117
168
|
|
118
|
-
|
169
|
+
this._isShown = true;
|
119
170
|
|
120
|
-
|
171
|
+
this._checkScrollbar();
|
121
172
|
|
122
|
-
|
173
|
+
this._setScrollbar();
|
123
174
|
|
124
|
-
|
175
|
+
this._adjustDialog();
|
125
176
|
|
126
|
-
|
177
|
+
$$$1(document.body).addClass(ClassName.OPEN);
|
127
178
|
|
128
|
-
|
179
|
+
this._setEscapeEvent();
|
129
180
|
|
130
|
-
|
181
|
+
this._setResizeEvent();
|
131
182
|
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
183
|
+
$$$1(this._element).on(Event.CLICK_DISMISS, Selector.DATA_DISMISS, function (event) {
|
184
|
+
return _this.hide(event);
|
185
|
+
});
|
186
|
+
$$$1(this._dialog).on(Event.MOUSEDOWN_DISMISS, function () {
|
187
|
+
$$$1(_this._element).one(Event.MOUSEUP_DISMISS, function (event) {
|
188
|
+
if ($$$1(event.target).is(_this._element)) {
|
189
|
+
_this._ignoreBackdropClick = true;
|
190
|
+
}
|
191
|
+
});
|
140
192
|
});
|
141
|
-
});
|
142
193
|
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
194
|
+
this._showBackdrop(function () {
|
195
|
+
return _this._showElement(relatedTarget);
|
196
|
+
});
|
197
|
+
};
|
147
198
|
|
148
|
-
|
149
|
-
|
199
|
+
_proto.hide = function hide(event) {
|
200
|
+
var _this2 = this;
|
150
201
|
|
151
|
-
|
152
|
-
|
153
|
-
|
202
|
+
if (event) {
|
203
|
+
event.preventDefault();
|
204
|
+
}
|
154
205
|
|
155
|
-
|
156
|
-
|
157
|
-
|
206
|
+
if (this._isTransitioning || !this._isShown) {
|
207
|
+
return;
|
208
|
+
}
|
158
209
|
|
159
|
-
|
160
|
-
|
210
|
+
var hideEvent = $$$1.Event(Event.HIDE);
|
211
|
+
$$$1(this._element).trigger(hideEvent);
|
161
212
|
|
162
|
-
|
163
|
-
|
164
|
-
|
213
|
+
if (!this._isShown || hideEvent.isDefaultPrevented()) {
|
214
|
+
return;
|
215
|
+
}
|
165
216
|
|
166
|
-
|
167
|
-
|
217
|
+
this._isShown = false;
|
218
|
+
var transition = $$$1(this._element).hasClass(ClassName.FADE);
|
168
219
|
|
169
|
-
|
170
|
-
|
171
|
-
|
220
|
+
if (transition) {
|
221
|
+
this._isTransitioning = true;
|
222
|
+
}
|
172
223
|
|
173
|
-
|
224
|
+
this._setEscapeEvent();
|
174
225
|
|
175
|
-
|
226
|
+
this._setResizeEvent();
|
176
227
|
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
228
|
+
$$$1(document).off(Event.FOCUSIN);
|
229
|
+
$$$1(this._element).removeClass(ClassName.SHOW);
|
230
|
+
$$$1(this._element).off(Event.CLICK_DISMISS);
|
231
|
+
$$$1(this._dialog).off(Event.MOUSEDOWN_DISMISS);
|
181
232
|
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
233
|
+
if (transition) {
|
234
|
+
var transitionDuration = Util.getTransitionDurationFromElement(this._element);
|
235
|
+
$$$1(this._element).one(Util.TRANSITION_END, function (event) {
|
236
|
+
return _this2._hideModal(event);
|
237
|
+
}).emulateTransitionEnd(transitionDuration);
|
238
|
+
} else {
|
239
|
+
this._hideModal();
|
240
|
+
}
|
241
|
+
};
|
191
242
|
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
243
|
+
_proto.dispose = function dispose() {
|
244
|
+
$$$1.removeData(this._element, DATA_KEY);
|
245
|
+
$$$1(window, document, this._element, this._backdrop).off(EVENT_KEY);
|
246
|
+
this._config = null;
|
247
|
+
this._element = null;
|
248
|
+
this._dialog = null;
|
249
|
+
this._backdrop = null;
|
250
|
+
this._isShown = null;
|
251
|
+
this._isBodyOverflowing = null;
|
252
|
+
this._ignoreBackdropClick = null;
|
253
|
+
this._scrollbarWidth = null;
|
254
|
+
};
|
204
255
|
|
205
|
-
|
206
|
-
|
207
|
-
|
256
|
+
_proto.handleUpdate = function handleUpdate() {
|
257
|
+
this._adjustDialog();
|
258
|
+
}; // Private
|
208
259
|
|
209
260
|
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
261
|
+
_proto._getConfig = function _getConfig(config) {
|
262
|
+
config = _objectSpread({}, Default, config);
|
263
|
+
Util.typeCheckConfig(NAME, config, DefaultType);
|
264
|
+
return config;
|
265
|
+
};
|
215
266
|
|
216
|
-
|
217
|
-
|
267
|
+
_proto._showElement = function _showElement(relatedTarget) {
|
268
|
+
var _this3 = this;
|
218
269
|
|
219
|
-
|
270
|
+
var transition = $$$1(this._element).hasClass(ClassName.FADE);
|
220
271
|
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
272
|
+
if (!this._element.parentNode || this._element.parentNode.nodeType !== Node.ELEMENT_NODE) {
|
273
|
+
// Don't move modal's DOM position
|
274
|
+
document.body.appendChild(this._element);
|
275
|
+
}
|
225
276
|
|
226
|
-
|
277
|
+
this._element.style.display = 'block';
|
227
278
|
|
228
|
-
|
279
|
+
this._element.removeAttribute('aria-hidden');
|
229
280
|
|
230
|
-
|
281
|
+
this._element.scrollTop = 0;
|
231
282
|
|
232
|
-
|
233
|
-
|
234
|
-
|
283
|
+
if (transition) {
|
284
|
+
Util.reflow(this._element);
|
285
|
+
}
|
235
286
|
|
236
|
-
|
287
|
+
$$$1(this._element).addClass(ClassName.SHOW);
|
237
288
|
|
238
|
-
|
239
|
-
|
240
|
-
|
289
|
+
if (this._config.focus) {
|
290
|
+
this._enforceFocus();
|
291
|
+
}
|
241
292
|
|
242
|
-
|
243
|
-
|
244
|
-
|
293
|
+
var shownEvent = $$$1.Event(Event.SHOWN, {
|
294
|
+
relatedTarget: relatedTarget
|
295
|
+
});
|
296
|
+
|
297
|
+
var transitionComplete = function transitionComplete() {
|
298
|
+
if (_this3._config.focus) {
|
299
|
+
_this3._element.focus();
|
300
|
+
}
|
301
|
+
|
302
|
+
_this3._isTransitioning = false;
|
303
|
+
$$$1(_this3._element).trigger(shownEvent);
|
304
|
+
};
|
245
305
|
|
246
|
-
|
247
|
-
|
248
|
-
|
306
|
+
if (transition) {
|
307
|
+
var transitionDuration = Util.getTransitionDurationFromElement(this._element);
|
308
|
+
$$$1(this._dialog).one(Util.TRANSITION_END, transitionComplete).emulateTransitionEnd(transitionDuration);
|
309
|
+
} else {
|
310
|
+
transitionComplete();
|
249
311
|
}
|
312
|
+
};
|
250
313
|
|
251
|
-
|
252
|
-
|
314
|
+
_proto._enforceFocus = function _enforceFocus() {
|
315
|
+
var _this4 = this;
|
316
|
+
|
317
|
+
$$$1(document).off(Event.FOCUSIN) // Guard against infinite focus loop
|
318
|
+
.on(Event.FOCUSIN, function (event) {
|
319
|
+
if (document !== event.target && _this4._element !== event.target && $$$1(_this4._element).has(event.target).length === 0) {
|
320
|
+
_this4._element.focus();
|
321
|
+
}
|
322
|
+
});
|
253
323
|
};
|
254
324
|
|
255
|
-
|
256
|
-
var
|
257
|
-
$(this._dialog).one(Util.TRANSITION_END, transitionComplete).emulateTransitionEnd(transitionDuration);
|
258
|
-
} else {
|
259
|
-
transitionComplete();
|
260
|
-
}
|
261
|
-
};
|
325
|
+
_proto._setEscapeEvent = function _setEscapeEvent() {
|
326
|
+
var _this5 = this;
|
262
327
|
|
263
|
-
|
264
|
-
|
328
|
+
if (this._isShown && this._config.keyboard) {
|
329
|
+
$$$1(this._element).on(Event.KEYDOWN_DISMISS, function (event) {
|
330
|
+
if (event.which === ESCAPE_KEYCODE) {
|
331
|
+
event.preventDefault();
|
265
332
|
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
333
|
+
_this5.hide();
|
334
|
+
}
|
335
|
+
});
|
336
|
+
} else if (!this._isShown) {
|
337
|
+
$$$1(this._element).off(Event.KEYDOWN_DISMISS);
|
270
338
|
}
|
271
|
-
}
|
272
|
-
};
|
273
|
-
|
274
|
-
_proto._setEscapeEvent = function _setEscapeEvent() {
|
275
|
-
var _this5 = this;
|
339
|
+
};
|
276
340
|
|
277
|
-
|
278
|
-
|
279
|
-
if (event.which === ESCAPE_KEYCODE) {
|
280
|
-
event.preventDefault();
|
341
|
+
_proto._setResizeEvent = function _setResizeEvent() {
|
342
|
+
var _this6 = this;
|
281
343
|
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
344
|
+
if (this._isShown) {
|
345
|
+
$$$1(window).on(Event.RESIZE, function (event) {
|
346
|
+
return _this6.handleUpdate(event);
|
347
|
+
});
|
348
|
+
} else {
|
349
|
+
$$$1(window).off(Event.RESIZE);
|
350
|
+
}
|
351
|
+
};
|
289
352
|
|
290
|
-
|
291
|
-
|
353
|
+
_proto._hideModal = function _hideModal() {
|
354
|
+
var _this7 = this;
|
292
355
|
|
293
|
-
|
294
|
-
$(window).on(Event.RESIZE, function (event) {
|
295
|
-
return _this6.handleUpdate(event);
|
296
|
-
});
|
297
|
-
} else {
|
298
|
-
$(window).off(Event.RESIZE);
|
299
|
-
}
|
300
|
-
};
|
356
|
+
this._element.style.display = 'none';
|
301
357
|
|
302
|
-
|
303
|
-
var _this7 = this;
|
358
|
+
this._element.setAttribute('aria-hidden', true);
|
304
359
|
|
305
|
-
|
360
|
+
this._isTransitioning = false;
|
306
361
|
|
307
|
-
|
362
|
+
this._showBackdrop(function () {
|
363
|
+
$$$1(document.body).removeClass(ClassName.OPEN);
|
308
364
|
|
309
|
-
|
365
|
+
_this7._resetAdjustments();
|
310
366
|
|
311
|
-
|
312
|
-
$(document.body).removeClass(ClassName.OPEN);
|
367
|
+
_this7._resetScrollbar();
|
313
368
|
|
314
|
-
|
369
|
+
$$$1(_this7._element).trigger(Event.HIDDEN);
|
370
|
+
});
|
371
|
+
};
|
315
372
|
|
316
|
-
|
373
|
+
_proto._removeBackdrop = function _removeBackdrop() {
|
374
|
+
if (this._backdrop) {
|
375
|
+
$$$1(this._backdrop).remove();
|
376
|
+
this._backdrop = null;
|
377
|
+
}
|
378
|
+
};
|
317
379
|
|
318
|
-
|
319
|
-
|
320
|
-
};
|
380
|
+
_proto._showBackdrop = function _showBackdrop(callback) {
|
381
|
+
var _this8 = this;
|
321
382
|
|
322
|
-
|
323
|
-
if (this._backdrop) {
|
324
|
-
$(this._backdrop).remove();
|
325
|
-
this._backdrop = null;
|
326
|
-
}
|
327
|
-
};
|
383
|
+
var animate = $$$1(this._element).hasClass(ClassName.FADE) ? ClassName.FADE : '';
|
328
384
|
|
329
|
-
|
330
|
-
|
385
|
+
if (this._isShown && this._config.backdrop) {
|
386
|
+
this._backdrop = document.createElement('div');
|
387
|
+
this._backdrop.className = ClassName.BACKDROP;
|
331
388
|
|
332
|
-
|
389
|
+
if (animate) {
|
390
|
+
this._backdrop.classList.add(animate);
|
391
|
+
}
|
333
392
|
|
334
|
-
|
335
|
-
|
336
|
-
|
393
|
+
$$$1(this._backdrop).appendTo(document.body);
|
394
|
+
$$$1(this._element).on(Event.CLICK_DISMISS, function (event) {
|
395
|
+
if (_this8._ignoreBackdropClick) {
|
396
|
+
_this8._ignoreBackdropClick = false;
|
397
|
+
return;
|
398
|
+
}
|
399
|
+
|
400
|
+
if (event.target !== event.currentTarget) {
|
401
|
+
return;
|
402
|
+
}
|
403
|
+
|
404
|
+
if (_this8._config.backdrop === 'static') {
|
405
|
+
_this8._element.focus();
|
406
|
+
} else {
|
407
|
+
_this8.hide();
|
408
|
+
}
|
409
|
+
});
|
410
|
+
|
411
|
+
if (animate) {
|
412
|
+
Util.reflow(this._backdrop);
|
413
|
+
}
|
337
414
|
|
338
|
-
|
339
|
-
$(this._backdrop).addClass(animate);
|
340
|
-
}
|
415
|
+
$$$1(this._backdrop).addClass(ClassName.SHOW);
|
341
416
|
|
342
|
-
|
343
|
-
$(this._element).on(Event.CLICK_DISMISS, function (event) {
|
344
|
-
if (_this8._ignoreBackdropClick) {
|
345
|
-
_this8._ignoreBackdropClick = false;
|
417
|
+
if (!callback) {
|
346
418
|
return;
|
347
419
|
}
|
348
420
|
|
349
|
-
if (
|
421
|
+
if (!animate) {
|
422
|
+
callback();
|
350
423
|
return;
|
351
424
|
}
|
352
425
|
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
}
|
358
|
-
});
|
426
|
+
var backdropTransitionDuration = Util.getTransitionDurationFromElement(this._backdrop);
|
427
|
+
$$$1(this._backdrop).one(Util.TRANSITION_END, callback).emulateTransitionEnd(backdropTransitionDuration);
|
428
|
+
} else if (!this._isShown && this._backdrop) {
|
429
|
+
$$$1(this._backdrop).removeClass(ClassName.SHOW);
|
359
430
|
|
360
|
-
|
361
|
-
|
362
|
-
}
|
431
|
+
var callbackRemove = function callbackRemove() {
|
432
|
+
_this8._removeBackdrop();
|
363
433
|
|
364
|
-
|
434
|
+
if (callback) {
|
435
|
+
callback();
|
436
|
+
}
|
437
|
+
};
|
365
438
|
|
366
|
-
|
367
|
-
|
368
|
-
}
|
439
|
+
if ($$$1(this._element).hasClass(ClassName.FADE)) {
|
440
|
+
var _backdropTransitionDuration = Util.getTransitionDurationFromElement(this._backdrop);
|
369
441
|
|
370
|
-
|
442
|
+
$$$1(this._backdrop).one(Util.TRANSITION_END, callbackRemove).emulateTransitionEnd(_backdropTransitionDuration);
|
443
|
+
} else {
|
444
|
+
callbackRemove();
|
445
|
+
}
|
446
|
+
} else if (callback) {
|
371
447
|
callback();
|
372
|
-
return;
|
373
448
|
}
|
449
|
+
}; // ----------------------------------------------------------------------
|
450
|
+
// the following methods are used to handle overflowing modals
|
451
|
+
// todo (fat): these should probably be refactored out of modal.js
|
452
|
+
// ----------------------------------------------------------------------
|
374
453
|
|
375
|
-
var backdropTransitionDuration = Util.getTransitionDurationFromElement(this._backdrop);
|
376
|
-
$(this._backdrop).one(Util.TRANSITION_END, callback).emulateTransitionEnd(backdropTransitionDuration);
|
377
|
-
} else if (!this._isShown && this._backdrop) {
|
378
|
-
$(this._backdrop).removeClass(ClassName.SHOW);
|
379
454
|
|
380
|
-
|
381
|
-
|
455
|
+
_proto._adjustDialog = function _adjustDialog() {
|
456
|
+
var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight;
|
382
457
|
|
383
|
-
|
384
|
-
|
385
|
-
}
|
386
|
-
};
|
387
|
-
|
388
|
-
if ($(this._element).hasClass(ClassName.FADE)) {
|
389
|
-
var _backdropTransitionDuration = Util.getTransitionDurationFromElement(this._backdrop);
|
390
|
-
|
391
|
-
$(this._backdrop).one(Util.TRANSITION_END, callbackRemove).emulateTransitionEnd(_backdropTransitionDuration);
|
392
|
-
} else {
|
393
|
-
callbackRemove();
|
458
|
+
if (!this._isBodyOverflowing && isModalOverflowing) {
|
459
|
+
this._element.style.paddingLeft = this._scrollbarWidth + "px";
|
394
460
|
}
|
395
|
-
} else if (callback) {
|
396
|
-
callback();
|
397
|
-
}
|
398
|
-
}; // ----------------------------------------------------------------------
|
399
|
-
// the following methods are used to handle overflowing modals
|
400
|
-
// todo (fat): these should probably be refactored out of modal.js
|
401
|
-
// ----------------------------------------------------------------------
|
402
|
-
|
403
|
-
|
404
|
-
_proto._adjustDialog = function _adjustDialog() {
|
405
|
-
var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight;
|
406
|
-
|
407
|
-
if (!this._isBodyOverflowing && isModalOverflowing) {
|
408
|
-
this._element.style.paddingLeft = this._scrollbarWidth + "px";
|
409
|
-
}
|
410
461
|
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
_proto._resetAdjustments = function _resetAdjustments() {
|
417
|
-
this._element.style.paddingLeft = '';
|
418
|
-
this._element.style.paddingRight = '';
|
419
|
-
};
|
420
|
-
|
421
|
-
_proto._checkScrollbar = function _checkScrollbar() {
|
422
|
-
var rect = document.body.getBoundingClientRect();
|
423
|
-
this._isBodyOverflowing = rect.left + rect.right < window.innerWidth;
|
424
|
-
this._scrollbarWidth = this._getScrollbarWidth();
|
425
|
-
};
|
462
|
+
if (this._isBodyOverflowing && !isModalOverflowing) {
|
463
|
+
this._element.style.paddingRight = this._scrollbarWidth + "px";
|
464
|
+
}
|
465
|
+
};
|
426
466
|
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
// Note: DOMNode.style.paddingRight returns the actual value or '' if not set
|
432
|
-
// while $(DOMNode).css('padding-right') returns the calculated value or 0 if not set
|
433
|
-
// Adjust fixed content padding
|
434
|
-
$(Selector.FIXED_CONTENT).each(function (index, element) {
|
435
|
-
var actualPadding = $(element)[0].style.paddingRight;
|
436
|
-
var calculatedPadding = $(element).css('padding-right');
|
437
|
-
$(element).data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + _this9._scrollbarWidth + "px");
|
438
|
-
}); // Adjust sticky content margin
|
439
|
-
|
440
|
-
$(Selector.STICKY_CONTENT).each(function (index, element) {
|
441
|
-
var actualMargin = $(element)[0].style.marginRight;
|
442
|
-
var calculatedMargin = $(element).css('margin-right');
|
443
|
-
$(element).data('margin-right', actualMargin).css('margin-right', parseFloat(calculatedMargin) - _this9._scrollbarWidth + "px");
|
444
|
-
}); // Adjust navbar-toggler margin
|
445
|
-
|
446
|
-
$(Selector.NAVBAR_TOGGLER).each(function (index, element) {
|
447
|
-
var actualMargin = $(element)[0].style.marginRight;
|
448
|
-
var calculatedMargin = $(element).css('margin-right');
|
449
|
-
$(element).data('margin-right', actualMargin).css('margin-right', parseFloat(calculatedMargin) + _this9._scrollbarWidth + "px");
|
450
|
-
}); // Adjust body padding
|
451
|
-
|
452
|
-
var actualPadding = document.body.style.paddingRight;
|
453
|
-
var calculatedPadding = $(document.body).css('padding-right');
|
454
|
-
$(document.body).data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + this._scrollbarWidth + "px");
|
455
|
-
}
|
456
|
-
};
|
467
|
+
_proto._resetAdjustments = function _resetAdjustments() {
|
468
|
+
this._element.style.paddingLeft = '';
|
469
|
+
this._element.style.paddingRight = '';
|
470
|
+
};
|
457
471
|
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
472
|
+
_proto._checkScrollbar = function _checkScrollbar() {
|
473
|
+
var rect = document.body.getBoundingClientRect();
|
474
|
+
this._isBodyOverflowing = rect.left + rect.right < window.innerWidth;
|
475
|
+
this._scrollbarWidth = this._getScrollbarWidth();
|
476
|
+
};
|
462
477
|
|
463
|
-
|
464
|
-
|
478
|
+
_proto._setScrollbar = function _setScrollbar() {
|
479
|
+
var _this9 = this;
|
480
|
+
|
481
|
+
if (this._isBodyOverflowing) {
|
482
|
+
// Note: DOMNode.style.paddingRight returns the actual value or '' if not set
|
483
|
+
// while $(DOMNode).css('padding-right') returns the calculated value or 0 if not set
|
484
|
+
var fixedContent = [].slice.call(document.querySelectorAll(Selector.FIXED_CONTENT));
|
485
|
+
var stickyContent = [].slice.call(document.querySelectorAll(Selector.STICKY_CONTENT)); // Adjust fixed content padding
|
486
|
+
|
487
|
+
$$$1(fixedContent).each(function (index, element) {
|
488
|
+
var actualPadding = element.style.paddingRight;
|
489
|
+
var calculatedPadding = $$$1(element).css('padding-right');
|
490
|
+
$$$1(element).data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + _this9._scrollbarWidth + "px");
|
491
|
+
}); // Adjust sticky content margin
|
492
|
+
|
493
|
+
$$$1(stickyContent).each(function (index, element) {
|
494
|
+
var actualMargin = element.style.marginRight;
|
495
|
+
var calculatedMargin = $$$1(element).css('margin-right');
|
496
|
+
$$$1(element).data('margin-right', actualMargin).css('margin-right', parseFloat(calculatedMargin) - _this9._scrollbarWidth + "px");
|
497
|
+
}); // Adjust body padding
|
498
|
+
|
499
|
+
var actualPadding = document.body.style.paddingRight;
|
500
|
+
var calculatedPadding = $$$1(document.body).css('padding-right');
|
501
|
+
$$$1(document.body).data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + this._scrollbarWidth + "px");
|
465
502
|
}
|
466
|
-
}
|
503
|
+
};
|
467
504
|
|
468
|
-
|
469
|
-
|
505
|
+
_proto._resetScrollbar = function _resetScrollbar() {
|
506
|
+
// Restore fixed content padding
|
507
|
+
var fixedContent = [].slice.call(document.querySelectorAll(Selector.FIXED_CONTENT));
|
508
|
+
$$$1(fixedContent).each(function (index, element) {
|
509
|
+
var padding = $$$1(element).data('padding-right');
|
510
|
+
$$$1(element).removeData('padding-right');
|
511
|
+
element.style.paddingRight = padding ? padding : '';
|
512
|
+
}); // Restore sticky content
|
513
|
+
|
514
|
+
var elements = [].slice.call(document.querySelectorAll("" + Selector.STICKY_CONTENT));
|
515
|
+
$$$1(elements).each(function (index, element) {
|
516
|
+
var margin = $$$1(element).data('margin-right');
|
517
|
+
|
518
|
+
if (typeof margin !== 'undefined') {
|
519
|
+
$$$1(element).css('margin-right', margin).removeData('margin-right');
|
520
|
+
}
|
521
|
+
}); // Restore body padding
|
470
522
|
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
}
|
523
|
+
var padding = $$$1(document.body).data('padding-right');
|
524
|
+
$$$1(document.body).removeData('padding-right');
|
525
|
+
document.body.style.paddingRight = padding ? padding : '';
|
526
|
+
};
|
475
527
|
|
476
|
-
|
528
|
+
_proto._getScrollbarWidth = function _getScrollbarWidth() {
|
529
|
+
// thx d.walsh
|
530
|
+
var scrollDiv = document.createElement('div');
|
531
|
+
scrollDiv.className = ClassName.SCROLLBAR_MEASURER;
|
532
|
+
document.body.appendChild(scrollDiv);
|
533
|
+
var scrollbarWidth = scrollDiv.getBoundingClientRect().width - scrollDiv.clientWidth;
|
534
|
+
document.body.removeChild(scrollDiv);
|
535
|
+
return scrollbarWidth;
|
536
|
+
}; // Static
|
477
537
|
|
478
|
-
if (typeof padding !== 'undefined') {
|
479
|
-
$(document.body).css('padding-right', padding).removeData('padding-right');
|
480
|
-
}
|
481
|
-
};
|
482
538
|
|
483
|
-
|
484
|
-
|
485
|
-
|
486
|
-
scrollDiv.className = ClassName.SCROLLBAR_MEASURER;
|
487
|
-
document.body.appendChild(scrollDiv);
|
488
|
-
var scrollbarWidth = scrollDiv.getBoundingClientRect().width - scrollDiv.clientWidth;
|
489
|
-
document.body.removeChild(scrollDiv);
|
490
|
-
return scrollbarWidth;
|
491
|
-
}; // Static
|
539
|
+
Modal._jQueryInterface = function _jQueryInterface(config, relatedTarget) {
|
540
|
+
return this.each(function () {
|
541
|
+
var data = $$$1(this).data(DATA_KEY);
|
492
542
|
|
543
|
+
var _config = _objectSpread({}, Default, $$$1(this).data(), typeof config === 'object' && config ? config : {});
|
493
544
|
|
494
|
-
|
495
|
-
|
496
|
-
|
545
|
+
if (!data) {
|
546
|
+
data = new Modal(this, _config);
|
547
|
+
$$$1(this).data(DATA_KEY, data);
|
548
|
+
}
|
497
549
|
|
498
|
-
|
550
|
+
if (typeof config === 'string') {
|
551
|
+
if (typeof data[config] === 'undefined') {
|
552
|
+
throw new TypeError("No method named \"" + config + "\"");
|
553
|
+
}
|
499
554
|
|
500
|
-
|
501
|
-
|
502
|
-
|
503
|
-
}
|
504
|
-
|
505
|
-
if (typeof config === 'string') {
|
506
|
-
if (typeof data[config] === 'undefined') {
|
507
|
-
throw new TypeError("No method named \"" + config + "\"");
|
555
|
+
data[config](relatedTarget);
|
556
|
+
} else if (_config.show) {
|
557
|
+
data.show(relatedTarget);
|
508
558
|
}
|
559
|
+
});
|
560
|
+
};
|
509
561
|
|
510
|
-
|
511
|
-
|
512
|
-
|
562
|
+
_createClass(Modal, null, [{
|
563
|
+
key: "VERSION",
|
564
|
+
get: function get() {
|
565
|
+
return VERSION;
|
513
566
|
}
|
514
|
-
}
|
515
|
-
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
return VERSION;
|
521
|
-
}
|
522
|
-
}, {
|
523
|
-
key: "Default",
|
524
|
-
get: function get() {
|
525
|
-
return Default;
|
526
|
-
}
|
527
|
-
}]);
|
528
|
-
|
529
|
-
return Modal;
|
530
|
-
}();
|
531
|
-
/**
|
532
|
-
* ------------------------------------------------------------------------
|
533
|
-
* Data Api implementation
|
534
|
-
* ------------------------------------------------------------------------
|
535
|
-
*/
|
567
|
+
}, {
|
568
|
+
key: "Default",
|
569
|
+
get: function get() {
|
570
|
+
return Default;
|
571
|
+
}
|
572
|
+
}]);
|
536
573
|
|
574
|
+
return Modal;
|
575
|
+
}();
|
576
|
+
/**
|
577
|
+
* ------------------------------------------------------------------------
|
578
|
+
* Data Api implementation
|
579
|
+
* ------------------------------------------------------------------------
|
580
|
+
*/
|
537
581
|
|
538
|
-
$(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
|
539
|
-
var _this10 = this;
|
540
582
|
|
541
|
-
|
542
|
-
|
583
|
+
$$$1(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
|
584
|
+
var _this10 = this;
|
543
585
|
|
544
|
-
|
545
|
-
|
546
|
-
}
|
586
|
+
var target;
|
587
|
+
var selector = Util.getSelectorFromElement(this);
|
547
588
|
|
548
|
-
|
589
|
+
if (selector) {
|
590
|
+
target = document.querySelector(selector);
|
591
|
+
}
|
549
592
|
|
550
|
-
|
551
|
-
event.preventDefault();
|
552
|
-
}
|
593
|
+
var config = $$$1(target).data(DATA_KEY) ? 'toggle' : _objectSpread({}, $$$1(target).data(), $$$1(this).data());
|
553
594
|
|
554
|
-
|
555
|
-
|
556
|
-
// Only register focus restorer if modal will actually get shown
|
557
|
-
return;
|
595
|
+
if (this.tagName === 'A' || this.tagName === 'AREA') {
|
596
|
+
event.preventDefault();
|
558
597
|
}
|
559
598
|
|
560
|
-
$target.one(Event.
|
561
|
-
if (
|
562
|
-
|
599
|
+
var $target = $$$1(target).one(Event.SHOW, function (showEvent) {
|
600
|
+
if (showEvent.isDefaultPrevented()) {
|
601
|
+
// Only register focus restorer if modal will actually get shown
|
602
|
+
return;
|
563
603
|
}
|
604
|
+
|
605
|
+
$target.one(Event.HIDDEN, function () {
|
606
|
+
if ($$$1(_this10).is(':visible')) {
|
607
|
+
_this10.focus();
|
608
|
+
}
|
609
|
+
});
|
564
610
|
});
|
611
|
+
|
612
|
+
Modal._jQueryInterface.call($$$1(target), config, this);
|
565
613
|
});
|
614
|
+
/**
|
615
|
+
* ------------------------------------------------------------------------
|
616
|
+
* jQuery
|
617
|
+
* ------------------------------------------------------------------------
|
618
|
+
*/
|
566
619
|
|
567
|
-
Modal._jQueryInterface
|
568
|
-
|
569
|
-
/**
|
570
|
-
* ------------------------------------------------------------------------
|
571
|
-
* jQuery
|
572
|
-
* ------------------------------------------------------------------------
|
573
|
-
*/
|
620
|
+
$$$1.fn[NAME] = Modal._jQueryInterface;
|
621
|
+
$$$1.fn[NAME].Constructor = Modal;
|
574
622
|
|
575
|
-
|
576
|
-
|
623
|
+
$$$1.fn[NAME].noConflict = function () {
|
624
|
+
$$$1.fn[NAME] = JQUERY_NO_CONFLICT;
|
625
|
+
return Modal._jQueryInterface;
|
626
|
+
};
|
577
627
|
|
578
|
-
|
579
|
-
|
580
|
-
return Modal._jQueryInterface;
|
581
|
-
};
|
628
|
+
return Modal;
|
629
|
+
}($);
|
582
630
|
|
583
631
|
return Modal;
|
584
|
-
|
585
|
-
|
632
|
+
|
633
|
+
})));
|
634
|
+
//# sourceMappingURL=modal.js.map
|