@sparkle-learning/core 0.0.57 → 0.0.58
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/PrivateRoute-f97245ce.js +217 -0
- package/dist/cjs/active-router-f9e18bd8.js +75 -0
- package/dist/cjs/animation-ee586546.js +986 -0
- package/dist/cjs/app-globals-33c9f31b.js +9 -0
- package/dist/cjs/appdata.service-c8d71e05.js +73 -0
- package/dist/cjs/assets.service-bfa75092.js +50 -0
- package/dist/cjs/assignment.service-690fb59c.js +19 -0
- package/dist/cjs/auth.store-1e630a7d.js +3392 -0
- package/dist/cjs/compass-svg.cjs.entry.js +132 -0
- package/dist/cjs/context-consumer.cjs.entry.js +29 -0
- package/dist/cjs/course-select.cjs.entry.js +30 -0
- package/dist/cjs/cubic-bezier-53d26d05.js +93 -0
- package/dist/cjs/dir-5af5259a.js +20 -0
- package/dist/cjs/environment-config.service-c8ff1f3d.js +28 -0
- package/dist/cjs/facilitator.service-ff0e1659.js +95 -0
- package/dist/cjs/feed.service-8eca4de6.js +57 -0
- package/dist/cjs/focus-visible-b0b07ba6.js +76 -0
- package/dist/cjs/framework-delegate-59a98abd.js +111 -0
- package/dist/cjs/gesture-controller-0eb5579e.js +196 -0
- package/dist/cjs/haptic-780f33c4.js +116 -0
- package/dist/cjs/hardware-back-button-92d97ff8.js +76 -0
- package/dist/cjs/header-mobile-collapse_61.cjs.entry.js +15124 -0
- package/dist/cjs/helpers-c2496722.js +425 -0
- package/dist/cjs/httpService-d2e7bf8f.js +687 -0
- package/dist/cjs/icons-fda820af.js +26 -0
- package/dist/cjs/index-12082cba.js +465 -0
- package/dist/cjs/index-15ea05f5.js +314 -0
- package/dist/cjs/index-51e8292e.js +1928 -0
- package/dist/cjs/index-787d4498.js +232 -0
- package/dist/cjs/index-8b5629a6.js +186 -0
- package/dist/cjs/index-975586fd.js +48 -0
- package/dist/cjs/index-9c7b27e4.js +140 -0
- package/dist/cjs/index-af080b50.js +139 -0
- package/dist/cjs/index-e56e09b8.js +38 -0
- package/dist/cjs/index.cjs.js +26 -0
- package/dist/cjs/index.es-38cbcdbe.js +10666 -0
- package/dist/cjs/input-shims-eff63b88.js +418 -0
- package/dist/cjs/ion-accordion-group.cjs.entry.js +205 -0
- package/dist/cjs/ion-accordion.cjs.entry.js +336 -0
- package/dist/cjs/ion-action-sheet_7.cjs.entry.js +2935 -0
- package/dist/cjs/ion-app.cjs.entry.js +79 -0
- package/dist/cjs/ion-back-button.cjs.entry.js +94 -0
- package/dist/cjs/ion-backdrop.cjs.entry.js +67 -0
- package/dist/cjs/ion-badge.cjs.entry.js +29 -0
- package/dist/cjs/ion-breadcrumb.cjs.entry.js +95 -0
- package/dist/cjs/ion-breadcrumbs.cjs.entry.js +133 -0
- package/dist/cjs/ion-buttons_3.cjs.entry.js +153 -0
- package/dist/cjs/ion-card-header.cjs.entry.js +37 -0
- package/dist/cjs/ion-card-subtitle.cjs.entry.js +30 -0
- package/dist/cjs/ion-card-title.cjs.entry.js +30 -0
- package/dist/cjs/ion-chip.cjs.entry.js +40 -0
- package/dist/cjs/ion-content_2.cjs.entry.js +659 -0
- package/dist/cjs/ion-datetime-button.cjs.entry.js +312 -0
- package/dist/cjs/ion-datetime.cjs.entry.js +1623 -0
- package/dist/cjs/ion-fab-button.cjs.entry.js +108 -0
- package/dist/cjs/ion-fab-list.cjs.entry.js +45 -0
- package/dist/cjs/ion-fab.cjs.entry.js +76 -0
- package/dist/cjs/ion-footer.cjs.entry.js +120 -0
- package/dist/cjs/ion-img.cjs.entry.js +101 -0
- package/dist/cjs/ion-infinite-scroll-content.cjs.entry.js +37 -0
- package/dist/cjs/ion-infinite-scroll.cjs.entry.js +206 -0
- package/dist/cjs/ion-item-divider.cjs.entry.js +40 -0
- package/dist/cjs/ion-item-group.cjs.entry.js +31 -0
- package/dist/cjs/ion-item-option.cjs.entry.js +60 -0
- package/dist/cjs/ion-item-options.cjs.entry.js +47 -0
- package/dist/cjs/ion-item-sliding.cjs.entry.js +398 -0
- package/dist/cjs/ion-loading.cjs.entry.js +215 -0
- package/dist/cjs/ion-menu-button.cjs.entry.js +76 -0
- package/dist/cjs/ion-menu-toggle.cjs.entry.js +47 -0
- package/dist/cjs/ion-menu.cjs.entry.js +575 -0
- package/dist/cjs/ion-modal.cjs.entry.js +1711 -0
- package/dist/cjs/ion-nav-link.cjs.entry.js +47 -0
- package/dist/cjs/ion-nav.cjs.entry.js +872 -0
- package/dist/cjs/ion-picker-column-internal_2.cjs.entry.js +808 -0
- package/dist/cjs/ion-picker-column.cjs.entry.js +331 -0
- package/dist/cjs/ion-picker.cjs.entry.js +221 -0
- package/dist/cjs/ion-progress-bar.cjs.entry.js +74 -0
- package/dist/cjs/ion-refresher-content.cjs.entry.js +35 -0
- package/dist/cjs/ion-refresher.cjs.entry.js +802 -0
- package/dist/cjs/ion-reorder-group.cjs.entry.js +281 -0
- package/dist/cjs/ion-reorder.cjs.entry.js +38 -0
- package/dist/cjs/ion-route-redirect.cjs.entry.js +24 -0
- package/dist/cjs/ion-route.cjs.entry.js +49 -0
- package/dist/cjs/ion-router-link.cjs.entry.js +38 -0
- package/dist/cjs/ion-router-outlet.cjs.entry.js +200 -0
- package/dist/cjs/ion-router.cjs.entry.js +831 -0
- package/dist/cjs/ion-searchbar.cjs.entry.js +370 -0
- package/dist/cjs/ion-segment-button.cjs.entry.js +102 -0
- package/dist/cjs/ion-segment.cjs.entry.js +417 -0
- package/dist/cjs/ion-skeleton-text.cjs.entry.js +33 -0
- package/dist/cjs/ion-slide.cjs.entry.js +25 -0
- package/dist/cjs/ion-slides.cjs.entry.js +391 -0
- package/dist/cjs/ion-split-pane.cjs.entry.js +154 -0
- package/dist/cjs/ion-tab-bar.cjs.entry.js +75 -0
- package/dist/cjs/ion-tab-button.cjs.entry.js +103 -0
- package/dist/cjs/ion-tab.cjs.entry.js +59 -0
- package/dist/cjs/ion-tabs.cjs.entry.js +154 -0
- package/dist/cjs/ion-thumbnail.cjs.entry.js +20 -0
- package/dist/cjs/ion-toast.cjs.entry.js +272 -0
- package/dist/cjs/ion-toggle.cjs.entry.js +177 -0
- package/dist/cjs/ion-virtual-scroll.cjs.entry.js +555 -0
- package/dist/cjs/ionic-global-2cde9d3a.js +231 -0
- package/dist/cjs/ios.transition-da235483.js +482 -0
- package/dist/cjs/keyboard-91096619.js +140 -0
- package/dist/cjs/loader.cjs.js +24 -0
- package/dist/cjs/localstorage.service-6346a41d.js +40 -0
- package/dist/cjs/md.transition-be429e07.js +57 -0
- package/dist/cjs/media.service-8a1b9bc5.js +40 -0
- package/dist/cjs/menu-toggle-util-7a01448c.js +14 -0
- package/dist/cjs/overlays-32df265a.js +507 -0
- package/dist/cjs/parse-d0071120.js +1237 -0
- package/dist/cjs/purify-fb9c107e.js +1468 -0
- package/dist/cjs/signalR.service-bd6b42f9.js +2985 -0
- package/dist/cjs/sparkle-animation-player.cjs.entry.js +515 -0
- package/dist/cjs/sparkle-assignment.cjs.entry.js +110 -0
- package/dist/cjs/sparkle-character-intro.cjs.entry.js +26 -0
- package/dist/cjs/sparkle-code.cjs.entry.js +43 -0
- package/dist/cjs/sparkle-compass-post.cjs.entry.js +133 -0
- package/dist/cjs/sparkle-compass.cjs.entry.js +126 -0
- package/dist/cjs/sparkle-core.cjs.js +22 -0
- package/dist/cjs/sparkle-discussion-questions_2.cjs.entry.js +281 -0
- package/dist/cjs/sparkle-discussion.cjs.entry.js +42 -0
- package/dist/cjs/sparkle-emoji.cjs.entry.js +80 -0
- package/dist/cjs/sparkle-facilitator-notes-form.cjs.entry.js +121 -0
- package/dist/cjs/sparkle-feed-post.cjs.entry.js +122 -0
- package/dist/cjs/sparkle-feedback.cjs.entry.js +101 -0
- package/dist/cjs/sparkle-file-upload.cjs.entry.js +53 -0
- package/dist/cjs/sparkle-goal-form.cjs.entry.js +179 -0
- package/dist/cjs/sparkle-gww-comment-list.cjs.entry.js +26 -0
- package/dist/cjs/sparkle-gww-graph.cjs.entry.js +19 -0
- package/dist/cjs/sparkle-input.cjs.entry.js +56 -0
- package/dist/cjs/sparkle-intro.cjs.entry.js +26 -0
- package/dist/cjs/sparkle-lower-content-nav.cjs.entry.js +22 -0
- package/dist/cjs/sparkle-menu-collapsible.cjs.entry.js +46 -0
- package/dist/cjs/sparkle-modal-image.cjs.entry.js +34 -0
- package/dist/cjs/sparkle-notfound-page.cjs.entry.js +25 -0
- package/dist/cjs/sparkle-overlay.cjs.entry.js +92 -0
- package/dist/cjs/sparkle-poll.cjs.entry.js +19 -0
- package/dist/cjs/sparkle-quiz-container.cjs.entry.js +47 -0
- package/dist/cjs/sparkle-quiz-feedback_5.cjs.entry.js +117 -0
- package/dist/cjs/sparkle-quiz-old.cjs.entry.js +120 -0
- package/dist/cjs/sparkle-quiz.cjs.entry.js +103 -0
- package/dist/cjs/sparkle-select.cjs.entry.js +61 -0
- package/dist/cjs/sparkle-sidebar.cjs.entry.js +43 -0
- package/dist/cjs/sparkle-tab.cjs.entry.js +26 -0
- package/dist/cjs/sparkle-table-of-contents.cjs.entry.js +71 -0
- package/dist/cjs/sparkle-tabs.cjs.entry.js +66 -0
- package/dist/cjs/sparkle-video-player.cjs.entry.js +22 -0
- package/dist/cjs/sparkle-youtube.cjs.entry.js +39 -0
- package/dist/cjs/spinner-configs-0ac05f2d.js +147 -0
- package/dist/cjs/status-tap-033befa2.js +42 -0
- package/dist/cjs/stencil-async-content.cjs.entry.js +32 -0
- package/dist/cjs/stencil-route-title.cjs.entry.js +32 -0
- package/dist/cjs/stencil-router-prompt.cjs.entry.js +59 -0
- package/dist/cjs/student.service-7e5385be.js +78 -0
- package/dist/cjs/swipe-back-4a826f9b.js +76 -0
- package/dist/cjs/swiper.bundle-8c897c07.js +6420 -0
- package/dist/cjs/theme-b0b295c1.js +48 -0
- package/dist/cjs/token.service-7a41953d.js +97 -0
- package/dist/cjs/util-47e320b2.js +2462 -0
- package/dist/collection/PrivateRoute.js +27 -0
- package/dist/collection/appconst.js +13 -0
- package/dist/collection/assets/img/forward.svg +5 -0
- package/dist/collection/assets/img/help/fitt-logo.svg +1 -0
- package/dist/collection/assets/img/home/big-white-wall.svg +15 -0
- package/dist/collection/assets/img/home/find-help.svg +23 -0
- package/dist/collection/assets/img/home/lessons.svg +26 -0
- package/dist/collection/assets/img/home/my-goals.svg +19 -0
- package/dist/collection/assets/img/home/my-health.svg +17 -0
- package/dist/collection/assets/img/home/my-mood.svg +26 -0
- package/dist/collection/assets/img/pause.svg +5 -0
- package/dist/collection/assets/img/play-symbol.svg +8 -0
- package/dist/collection/assets/img/play.svg +4 -0
- package/dist/collection/assets/img/rewind.svg +5 -0
- package/dist/collection/assets/lib/SignalRAspNetCoreHelper.js +17 -0
- package/dist/collection/assets/lib/sparkleUtility.js +8 -0
- package/dist/collection/assets/svg/profile.svg +2 -0
- package/dist/collection/collection-manifest.json +219 -0
- package/dist/collection/components/compass-svg/compass-svg.css +15 -0
- package/dist/collection/components/compass-svg/compass-svg.js +156 -0
- package/dist/collection/components/layout/facilitator/export-lessons/export-lessons.css +7 -0
- package/dist/collection/components/layout/facilitator/export-lessons/export-lessons.js +110 -0
- package/dist/collection/components/layout/facilitator/facilitator-dashboard/facilitator-dashboard.css +3 -0
- package/dist/collection/components/layout/facilitator/facilitator-dashboard/facilitator-dashboard.js +214 -0
- package/dist/collection/components/layout/facilitator/facilitator-header/facilitator-header-mobile-collapse/facilitator-header-mobile-collapse.js +0 -0
- package/dist/collection/components/layout/facilitator/facilitator-header/facilitator-header.css +172 -0
- package/dist/collection/components/layout/facilitator/facilitator-header/facilitator-header.js +104 -0
- package/dist/collection/components/layout/facilitator/facilitator-notes/facilitator-notes-form/facilitator-notes-form.css +3 -0
- package/dist/collection/components/layout/facilitator/facilitator-notes/facilitator-notes-form/facilitator-notes-form.js +144 -0
- package/dist/collection/components/layout/facilitator/facilitator-notes/facilitator-notes.css +14 -0
- package/dist/collection/components/layout/facilitator/facilitator-notes/facilitator-notes.js +64 -0
- package/dist/collection/components/layout/facilitator/facilitator-page.css +196 -0
- package/dist/collection/components/layout/facilitator/facilitator-page.js +281 -0
- package/dist/collection/components/layout/facilitator/online-students/online-students.css +0 -0
- package/dist/collection/components/layout/facilitator/online-students/online-students.js +70 -0
- package/dist/collection/components/layout/page/page.css +183 -0
- package/dist/collection/components/layout/page/page.js +321 -0
- package/dist/collection/components/layout/page/templates/default.js +9 -0
- package/dist/collection/components/layout/page/templates/error.js +33 -0
- package/dist/collection/components/layout/page/templates/index.js +8 -0
- package/dist/collection/components/layout/page/templates/pdf.js +8 -0
- package/dist/collection/components/layout/page/to-hypertext.js +27 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goal-form/sparkle-goal-form.css +3 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goal-form/sparkle-goal-form.js +252 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goal-item/sparkle-goal-item.css +12 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goal-item/sparkle-goal-item.js +59 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goal-progress/sparkle-goal-progress.css +33 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goal-progress/sparkle-goal-progress.js +37 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goals.css +8 -0
- package/dist/collection/components/mini-apps/sparkle-goals/sparkle-goals.js +40 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww-comment-list/sparkle-gww-comment-list.css +7 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww-comment-list/sparkle-gww-comment-list.js +52 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww-graph/sparkle-gww-graph.css +3 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww-graph/sparkle-gww-graph.js +14 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww-item/sparkle-gww-item.css +30 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww-item/sparkle-gww-item.js +187 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww.css +3 -0
- package/dist/collection/components/mini-apps/sparkle-gww/sparkle-gww.js +43 -0
- package/dist/collection/components/mini-apps/sparkle-health/sparkle-health.css +10 -0
- package/dist/collection/components/mini-apps/sparkle-health/sparkle-health.js +111 -0
- package/dist/collection/components/mini-apps/sparkle-mood/sparkle-mood.css +11 -0
- package/dist/collection/components/mini-apps/sparkle-mood/sparkle-mood.js +127 -0
- package/dist/collection/components/modal-image/modal-image.css +61 -0
- package/dist/collection/components/modal-image/modal-image.js +159 -0
- package/dist/collection/components/sparkle-animation-player/assets/play-button-disabled-overlay.png +0 -0
- package/dist/collection/components/sparkle-animation-player/assets/play-button-overlay.png +0 -0
- package/dist/collection/components/sparkle-animation-player/caption-parser.js +94 -0
- package/dist/collection/components/sparkle-animation-player/sparkle-animation-player.css +157 -0
- package/dist/collection/components/sparkle-animation-player/sparkle-animation-player.js +598 -0
- package/dist/collection/components/sparkle-assignment/sparkle-assignment.css +30 -0
- package/dist/collection/components/sparkle-assignment/sparkle-assignment.js +159 -0
- package/dist/collection/components/sparkle-character-intro/assets/characters/character-img.jpg +0 -0
- package/dist/collection/components/sparkle-character-intro/assets/characters/jen.png +0 -0
- package/dist/collection/components/sparkle-character-intro/assets/characters/kimberly.png +0 -0
- package/dist/collection/components/sparkle-character-intro/assets/characters/valeria.png +0 -0
- package/dist/collection/components/sparkle-character-intro/assets/characters/yuna.png +0 -0
- package/dist/collection/components/sparkle-character-intro/assets/characters/zynab.png +0 -0
- package/dist/collection/components/sparkle-character-intro/sparkle-character-intro.css +74 -0
- package/dist/collection/components/sparkle-character-intro/sparkle-character-intro.js +68 -0
- package/dist/collection/components/sparkle-compass/sparkle-compass-post/sparkle-compass-post.css +35 -0
- package/dist/collection/components/sparkle-compass/sparkle-compass-post/sparkle-compass-post.js +171 -0
- package/dist/collection/components/sparkle-compass/sparkle-compass.css +25 -0
- package/dist/collection/components/sparkle-compass/sparkle-compass.js +283 -0
- package/dist/collection/components/sparkle-course-root/sparkle-course-root.css +3 -0
- package/dist/collection/components/sparkle-course-root/sparkle-course-root.js +196 -0
- package/dist/collection/components/sparkle-discussion/sparkle-discussion-questions/sparkle-discussion-questions.css +157 -0
- package/dist/collection/components/sparkle-discussion/sparkle-discussion-questions/sparkle-discussion-questions.js +232 -0
- package/dist/collection/components/sparkle-discussion/sparkle-discussion-results/sparkle-discussion-results.css +158 -0
- package/dist/collection/components/sparkle-discussion/sparkle-discussion-results/sparkle-discussion-results.js +274 -0
- package/dist/collection/components/sparkle-discussion/sparkle-discussion.css +5 -0
- package/dist/collection/components/sparkle-discussion/sparkle-discussion.js +112 -0
- package/dist/collection/components/sparkle-emoji/sparkle-emoji.css +16 -0
- package/dist/collection/components/sparkle-emoji/sparkle-emoji.js +116 -0
- package/dist/collection/components/sparkle-feed-post/sparkle-feed-post.css +35 -0
- package/dist/collection/components/sparkle-feed-post/sparkle-feed-post.js +199 -0
- package/dist/collection/components/sparkle-feedback/sparkle-feedback.css +3 -0
- package/dist/collection/components/sparkle-feedback/sparkle-feedback.js +118 -0
- package/dist/collection/components/sparkle-file-upload/sparkle-file-upload.css +0 -0
- package/dist/collection/components/sparkle-file-upload/sparkle-file-upload.js +105 -0
- package/dist/collection/components/sparkle-forgot-password/sparkle-forgot-password.css +4 -0
- package/dist/collection/components/sparkle-forgot-password/sparkle-forgot-password.js +107 -0
- package/dist/collection/components/sparkle-input/sparkle-input.css +0 -0
- package/dist/collection/components/sparkle-input/sparkle-input.js +212 -0
- package/dist/collection/components/sparkle-intro/sparkle-intro.css +15 -0
- package/dist/collection/components/sparkle-intro/sparkle-intro.js +35 -0
- package/dist/collection/components/sparkle-login/sparkle-login.css +4 -0
- package/dist/collection/components/sparkle-login/sparkle-login.js +173 -0
- package/dist/collection/components/sparkle-poll/sparkle-poll.css +3 -0
- package/dist/collection/components/sparkle-poll/sparkle-poll.js +15 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-feedback/sparkle-quiz-feedback.css +3 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-feedback/sparkle-quiz-feedback.js +69 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-input/sparkle-quiz-input.css +3 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-input/sparkle-quiz-input.js +59 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-old/sparkle-quiz-old.css +48 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-old/sparkle-quiz-old.js +327 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-opinion/sparkle-quiz-opinion.css +18 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-opinion/sparkle-quiz-opinion.js +106 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-poll/sparkle-quiz-poll.css +3 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-poll/sparkle-quiz-poll.js +59 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-select/sparkle-quiz-select.css +3 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz-select/sparkle-quiz-select.js +100 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz.css +48 -0
- package/dist/collection/components/sparkle-quiz/sparkle-quiz.js +221 -0
- package/dist/collection/components/sparkle-quiz-container/sparkle-quiz-container.css +3 -0
- package/dist/collection/components/sparkle-quiz-container/sparkle-quiz-container.js +98 -0
- package/dist/collection/components/sparkle-reset-password/sparkle-reset-password.css +3 -0
- package/dist/collection/components/sparkle-reset-password/sparkle-reset-password.js +126 -0
- package/dist/collection/components/sparkle-root/sparkle-root.css +61 -0
- package/dist/collection/components/sparkle-root/sparkle-root.js +86 -0
- package/dist/collection/components/sparkle-signup/sparkle-signup.css +6 -0
- package/dist/collection/components/sparkle-signup/sparkle-signup.js +197 -0
- package/dist/collection/components/sparkle-unauthorized/sparkle-unauthorized.css +13 -0
- package/dist/collection/components/sparkle-unauthorized/sparkle-unauthorized.js +18 -0
- package/dist/collection/components/sparkle-user-enrollment/sparkle-user-enrollment.css +3 -0
- package/dist/collection/components/sparkle-user-enrollment/sparkle-user-enrollment.js +93 -0
- package/dist/collection/components/sparkle-user-profile/sparkle-user-profile.css +54 -0
- package/dist/collection/components/sparkle-user-profile/sparkle-user-profile.js +151 -0
- package/dist/collection/components/sparkle-validation-error/sparkle-validation-error.css +11 -0
- package/dist/collection/components/sparkle-validation-error/sparkle-validation-error.js +44 -0
- package/dist/collection/components/sparkle-video-player/sparkle-video-player.css +0 -0
- package/dist/collection/components/sparkle-video-player/sparkle-video-player.js +92 -0
- package/dist/collection/components/sparkle-youtube/sparkle-youtube.css +24 -0
- package/dist/collection/components/sparkle-youtube/sparkle-youtube.js +99 -0
- package/dist/collection/global/app.js +4 -0
- package/dist/collection/helpers/utils.js +3 -0
- package/dist/collection/icons.js +36 -0
- package/dist/collection/index.js +3 -0
- package/dist/collection/l10n.js +18 -0
- package/dist/collection/models/api.model.js +7 -0
- package/dist/collection/models/assets.model.js +1 -0
- package/dist/collection/models/auth/auth.user.js +1 -0
- package/dist/collection/models/class.model.js +5 -0
- package/dist/collection/models/course.model.js +10 -0
- package/dist/collection/models/definitions.js +1 -0
- package/dist/collection/models/facilitator-dashboard.model.js +5 -0
- package/dist/collection/models/goal.model.js +1 -0
- package/dist/collection/models/index.js +1 -0
- package/dist/collection/models/markdown.model.js +1 -0
- package/dist/collection/models/page.model.js +1 -0
- package/dist/collection/models/quiz.model.js +3 -0
- package/dist/collection/models/user.model.js +1 -0
- package/dist/collection/pages/course/welcome-to-mind-body/introduction/animation/m4l1p1_part1.js +2727 -0
- package/dist/collection/pages/course/welcome-to-mind-body/introduction/animation/m4l1p1_part2.js +2042 -0
- package/dist/collection/services/account.service.js +61 -0
- package/dist/collection/services/appdata.service.js +60 -0
- package/dist/collection/services/assignment.service.js +14 -0
- package/dist/collection/services/auth/auth.service.js +64 -0
- package/dist/collection/services/core/assets.service.js +45 -0
- package/dist/collection/services/core/localstorage.service.js +34 -0
- package/dist/collection/services/environment/environment-config.js +24 -0
- package/dist/collection/services/environment/environment-config.service.js +24 -0
- package/dist/collection/services/facilitator.service.js +76 -0
- package/dist/collection/services/feed.service.js +43 -0
- package/dist/collection/services/httpService.js +103 -0
- package/dist/collection/services/index.js +4 -0
- package/dist/collection/services/media.service.js +29 -0
- package/dist/collection/services/signalR.service.js +83 -0
- package/dist/collection/services/store.service.js +13 -0
- package/dist/collection/services/student.service.js +56 -0
- package/dist/collection/services/token.service.js +79 -0
- package/dist/collection/stores/auth.store.js +12 -0
- package/dist/collection/stores/class.store.js +5 -0
- package/dist/collection/stores/error.store.js +5 -0
- package/dist/collection/stores/facilitator.store.js +15 -0
- package/dist/collection/stores/feed.store.js +8 -0
- package/dist/collection/stores/goal.store.js +7 -0
- package/dist/collection/stores/index.js +1 -0
- package/dist/collection/stores/media.store.js +5 -0
- package/dist/collection/stores/mood.store.js +5 -0
- package/dist/collection/stores/nav.store.js +11 -0
- package/dist/collection/stores/signalR.store.js +6 -0
- package/dist/collection/stores/theme.store.js +9 -0
- package/dist/collection/stores/toc.store.js +5 -0
- package/dist/collection/stores/user.store.js +16 -0
- package/dist/collection/util.js +55 -0
- package/dist/collection/utils.js +92 -0
- package/dist/esm/PrivateRoute-90ac95b8.js +212 -0
- package/dist/esm/active-router-fc9e4e06.js +73 -0
- package/dist/esm/animation-12377cb3.js +984 -0
- package/dist/esm/app-globals-3f0347b0.js +7 -0
- package/dist/esm/appdata.service-2e84e167.js +70 -0
- package/dist/esm/assets.service-def1d63c.js +48 -0
- package/dist/esm/assignment.service-8d31f141.js +17 -0
- package/dist/esm/auth.store-dba2c2da.js +3381 -0
- package/dist/esm/compass-svg.entry.js +128 -0
- package/dist/esm/context-consumer.entry.js +25 -0
- package/dist/esm/course-select.entry.js +26 -0
- package/dist/esm/dir-03012648.js +18 -0
- package/dist/esm/environment-config.service-b191f276.js +26 -0
- package/dist/esm/facilitator.service-18c47bdf.js +92 -0
- package/dist/esm/feed.service-b4f3cae4.js +54 -0
- package/dist/esm/framework-delegate-3e634a5c.js +107 -0
- package/dist/esm/gesture-controller-7be18351.js +194 -0
- package/dist/esm/haptic-522f76f2.js +110 -0
- package/dist/esm/header-mobile-collapse_61.entry.js +15060 -0
- package/dist/esm/helpers-bf0e23d6.js +403 -0
- package/dist/esm/httpService-7986aeed.js +685 -0
- package/dist/esm/icons-1c794c74.js +18 -0
- package/dist/esm/index-21661af2.js +463 -0
- package/dist/esm/index-2b84cad2.js +223 -0
- package/dist/esm/index-4044fde9.js +25 -0
- package/dist/esm/index-45fec1e7.js +184 -0
- package/dist/esm/index-5e8971ae.js +128 -0
- package/dist/esm/index-c04b9ed5.js +1888 -0
- package/dist/esm/index-cded2d87.js +312 -0
- package/dist/esm/index-dad75b83.js +34 -0
- package/dist/esm/index.es-e0c0f891.js +10580 -0
- package/dist/esm/index.js +12 -0
- package/dist/esm/input-shims-671d8d9f.js +416 -0
- package/dist/esm/ion-accordion-group.entry.js +201 -0
- package/dist/esm/ion-accordion.entry.js +332 -0
- package/dist/esm/ion-action-sheet_7.entry.js +2925 -0
- package/dist/esm/ion-app.entry.js +75 -0
- package/dist/esm/ion-back-button.entry.js +90 -0
- package/dist/esm/ion-backdrop.entry.js +63 -0
- package/dist/esm/ion-badge.entry.js +25 -0
- package/dist/esm/ion-breadcrumb.entry.js +91 -0
- package/dist/esm/ion-breadcrumbs.entry.js +129 -0
- package/dist/esm/ion-buttons_3.entry.js +147 -0
- package/dist/esm/ion-card-header.entry.js +33 -0
- package/dist/esm/ion-card-subtitle.entry.js +26 -0
- package/dist/esm/ion-card-title.entry.js +26 -0
- package/dist/esm/ion-chip.entry.js +36 -0
- package/dist/esm/ion-content_2.entry.js +654 -0
- package/dist/esm/ion-datetime-button.entry.js +308 -0
- package/dist/esm/ion-datetime.entry.js +1619 -0
- package/dist/esm/ion-fab-button.entry.js +104 -0
- package/dist/esm/ion-fab-list.entry.js +41 -0
- package/dist/esm/ion-fab.entry.js +72 -0
- package/dist/esm/ion-footer.entry.js +116 -0
- package/dist/esm/ion-img.entry.js +97 -0
- package/dist/esm/ion-infinite-scroll-content.entry.js +33 -0
- package/dist/esm/ion-infinite-scroll.entry.js +202 -0
- package/dist/esm/ion-item-divider.entry.js +36 -0
- package/dist/esm/ion-item-group.entry.js +27 -0
- package/dist/esm/ion-item-option.entry.js +56 -0
- package/dist/esm/ion-item-options.entry.js +43 -0
- package/dist/esm/ion-item-sliding.entry.js +394 -0
- package/dist/esm/ion-loading.entry.js +211 -0
- package/dist/esm/ion-menu-button.entry.js +72 -0
- package/dist/esm/ion-menu-toggle.entry.js +43 -0
- package/dist/esm/ion-menu.entry.js +571 -0
- package/dist/esm/ion-modal.entry.js +1707 -0
- package/dist/esm/ion-nav-link.entry.js +43 -0
- package/dist/esm/ion-nav.entry.js +868 -0
- package/dist/esm/ion-picker-column-internal_2.entry.js +803 -0
- package/dist/esm/ion-picker-column.entry.js +327 -0
- package/dist/esm/ion-picker.entry.js +217 -0
- package/dist/esm/ion-progress-bar.entry.js +70 -0
- package/dist/esm/ion-refresher-content.entry.js +31 -0
- package/dist/esm/ion-refresher.entry.js +798 -0
- package/dist/esm/ion-reorder-group.entry.js +277 -0
- package/dist/esm/ion-reorder.entry.js +34 -0
- package/dist/esm/ion-route-redirect.entry.js +20 -0
- package/dist/esm/ion-route.entry.js +45 -0
- package/dist/esm/ion-router-link.entry.js +34 -0
- package/dist/esm/ion-router-outlet.entry.js +196 -0
- package/dist/esm/ion-router.entry.js +827 -0
- package/dist/esm/ion-searchbar.entry.js +366 -0
- package/dist/esm/ion-segment-button.entry.js +98 -0
- package/dist/esm/ion-segment.entry.js +413 -0
- package/dist/esm/ion-skeleton-text.entry.js +29 -0
- package/dist/esm/ion-slide.entry.js +21 -0
- package/dist/esm/ion-slides.entry.js +387 -0
- package/dist/esm/ion-split-pane.entry.js +150 -0
- package/dist/esm/ion-tab-bar.entry.js +71 -0
- package/dist/esm/ion-tab-button.entry.js +99 -0
- package/dist/esm/ion-tab.entry.js +55 -0
- package/dist/esm/ion-tabs.entry.js +150 -0
- package/dist/esm/ion-thumbnail.entry.js +16 -0
- package/dist/esm/ion-toast.entry.js +268 -0
- package/dist/esm/ion-toggle.entry.js +173 -0
- package/dist/esm/ion-virtual-scroll.entry.js +551 -0
- package/dist/esm/ionic-global-4903e23e.js +226 -0
- package/dist/esm/ios.transition-131d64fe.js +479 -0
- package/dist/esm/loader.js +20 -0
- package/dist/esm/md.transition-f6126011.js +55 -0
- package/dist/esm/media.service-6e90bc41.js +37 -0
- package/dist/esm/menu-toggle-util-bace8ae6.js +12 -0
- package/dist/esm/overlays-4233a39d.js +491 -0
- package/dist/esm/parse-1ae3a9bb.js +1196 -0
- package/dist/esm/polyfills/core-js.js +11 -0
- package/dist/esm/polyfills/css-shim.js +1 -0
- package/dist/esm/polyfills/dom.js +79 -0
- package/dist/esm/polyfills/es5-html-element.js +1 -0
- package/dist/esm/polyfills/index.js +34 -0
- package/dist/esm/polyfills/system.js +6 -0
- package/dist/esm/purify-85bfcc69.js +1466 -0
- package/dist/esm/signalR.service-c33fba50.js +2982 -0
- package/dist/esm/sparkle-animation-player.entry.js +511 -0
- package/dist/esm/sparkle-assignment.entry.js +106 -0
- package/dist/esm/sparkle-character-intro.entry.js +22 -0
- package/dist/esm/sparkle-code.entry.js +39 -0
- package/dist/esm/sparkle-compass-post.entry.js +129 -0
- package/dist/esm/sparkle-compass.entry.js +122 -0
- package/dist/esm/sparkle-core.js +20 -0
- package/dist/esm/sparkle-discussion-questions_2.entry.js +276 -0
- package/dist/esm/sparkle-discussion.entry.js +38 -0
- package/dist/esm/sparkle-emoji.entry.js +76 -0
- package/dist/esm/sparkle-facilitator-notes-form.entry.js +117 -0
- package/dist/esm/sparkle-feed-post.entry.js +118 -0
- package/dist/esm/sparkle-feedback.entry.js +97 -0
- package/dist/esm/sparkle-file-upload.entry.js +49 -0
- package/dist/esm/sparkle-goal-form.entry.js +175 -0
- package/dist/esm/sparkle-gww-comment-list.entry.js +22 -0
- package/dist/esm/sparkle-gww-graph.entry.js +15 -0
- package/dist/esm/sparkle-input.entry.js +52 -0
- package/dist/esm/sparkle-intro.entry.js +22 -0
- package/dist/esm/sparkle-lower-content-nav.entry.js +18 -0
- package/dist/esm/sparkle-menu-collapsible.entry.js +42 -0
- package/dist/esm/sparkle-modal-image.entry.js +30 -0
- package/dist/esm/sparkle-notfound-page.entry.js +21 -0
- package/dist/esm/sparkle-overlay.entry.js +88 -0
- package/dist/esm/sparkle-poll.entry.js +15 -0
- package/dist/esm/sparkle-quiz-container.entry.js +43 -0
- package/dist/esm/sparkle-quiz-feedback_5.entry.js +109 -0
- package/dist/esm/sparkle-quiz-old.entry.js +116 -0
- package/dist/esm/sparkle-quiz.entry.js +99 -0
- package/dist/esm/sparkle-select.entry.js +57 -0
- package/dist/esm/sparkle-sidebar.entry.js +39 -0
- package/dist/esm/sparkle-tab.entry.js +22 -0
- package/dist/esm/sparkle-table-of-contents.entry.js +67 -0
- package/dist/esm/sparkle-tabs.entry.js +62 -0
- package/dist/esm/sparkle-video-player.entry.js +18 -0
- package/dist/esm/sparkle-youtube.entry.js +35 -0
- package/dist/esm/status-tap-dde52787.js +40 -0
- package/dist/esm/stencil-async-content.entry.js +28 -0
- package/dist/esm/stencil-route-title.entry.js +28 -0
- package/dist/esm/stencil-router-prompt.entry.js +55 -0
- package/dist/esm/student.service-08af124f.js +75 -0
- package/dist/esm/swipe-back-7847a0c1.js +74 -0
- package/dist/esm/swiper.bundle-b6a959de.js +6418 -0
- package/dist/esm/token.service-71a5d33f.js +94 -0
- package/dist/esm/util-57cc8006.js +2451 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.js +1 -0
- package/dist/loader/cdn.js +3 -0
- package/dist/loader/index.cjs.js +3 -0
- package/dist/loader/index.d.ts +12 -0
- package/dist/loader/index.es2017.js +3 -0
- package/dist/loader/index.js +4 -0
- package/dist/loader/package.json +10 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/accordion/accordion.ios.css +75 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/accordion/accordion.md.css +72 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/accordion-group/accordion-group.ios.css +25 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/accordion-group/accordion-group.md.css +59 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/action-sheet/action-sheet.ios.css +357 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/action-sheet/action-sheet.md.css +290 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/alert/alert.ios.css +494 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/alert/alert.md.css +502 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/app/app.css +17 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/avatar/avatar.ios.css +22 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/avatar/avatar.md.css +22 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/back-button/back-button.ios.css +281 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/back-button/back-button.md.css +309 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/backdrop/backdrop.ios.css +26 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/backdrop/backdrop.md.css +26 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/badge/badge.ios.css +58 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/badge/badge.md.css +62 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumb/breadcrumb.ios.css +234 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumb/breadcrumb.md.css +237 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumbs/breadcrumbs.ios.css +38 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumbs/breadcrumbs.md.css +37 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/button/button.ios.css +439 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/button/button.md.css +428 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/buttons/buttons.ios.css +128 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/buttons/buttons.md.css +151 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card/card.ios.css +101 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card/card.md.css +95 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-content/card-content.ios.css +61 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-content/card-content.md.css +63 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-header/card-header.ios.css +37 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-header/card-header.md.css +35 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-subtitle/card-subtitle.ios.css +28 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-subtitle/card-subtitle.md.css +26 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-title/card-title.ios.css +27 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/card-title/card-title.md.css +27 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/checkbox/checkbox.ios.css +169 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/checkbox/checkbox.md.css +172 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/chip/chip.ios.css +200 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/chip/chip.md.css +200 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/col/col.css +108 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/content/content.css +237 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/datetime/datetime.ios.css +648 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/datetime/datetime.md.css +637 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/datetime-button/datetime-button.css +60 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/fab/fab.css +61 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/fab-button/fab-button.ios.css +338 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/fab-button/fab-button.md.css +307 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/fab-list/fab-list.css +116 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/footer/footer.ios.css +37 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/footer/footer.md.css +37 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/grid/grid.css +151 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/header/header.ios.css +108 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/header/header.md.css +40 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/img/img.css +12 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/infinite-scroll/infinite-scroll.css +8 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/infinite-scroll-content/infinite-scroll-content.ios.css +54 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/infinite-scroll-content/infinite-scroll-content.md.css +54 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/input/input.ios.css +185 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/input/input.md.css +185 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item/item.ios.css +669 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item/item.md.css +928 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-divider/item-divider.ios.css +204 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-divider/item-divider.md.css +297 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-group/item-group.ios.css +3 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-group/item-group.md.css +3 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-option/item-option.ios.css +186 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-option/item-option.md.css +180 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-options/item-options.ios.css +88 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-options/item-options.md.css +85 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/item-sliding/item-sliding.css +42 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/label/label.ios.css +156 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/label/label.md.css +250 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/list/list.ios.css +91 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/list/list.md.css +114 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/list-header/list-header.ios.css +118 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/list-header/list-header.md.css +94 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/loading/loading.ios.css +109 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/loading/loading.md.css +100 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/menu/menu.ios.css +127 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/menu/menu.md.css +123 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/menu-button/menu-button.ios.css +175 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/menu-button/menu-button.md.css +178 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/menu-toggle/menu-toggle.css +3 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/modal/modal.ios.css +250 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/modal/modal.md.css +177 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/nav/nav.css +10 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/note/note.ios.css +16 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/note/note.md.css +17 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker/picker.ios.css +217 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker/picker.md.css +204 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker-column/picker-column.ios.css +122 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker-column/picker-column.md.css +123 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker-column-internal/picker-column-internal.ios.css +82 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker-column-internal/picker-column-internal.md.css +85 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker-internal/picker-internal.ios.css +126 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/picker-internal/picker-internal.md.css +122 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/popover/popover.ios.css +201 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/popover/popover.md.css +132 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/progress-bar/progress-bar.ios.css +206 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/progress-bar/progress-bar.md.css +206 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/radio/radio.ios.css +177 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/radio/radio.md.css +178 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/range/range.ios.css +275 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/range/range.md.css +320 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/refresher/refresher.ios.css +189 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/refresher/refresher.md.css +210 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/reorder/reorder.ios.css +15 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/reorder/reorder.md.css +15 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/reorder-group/reorder-group.css +33 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/ripple-effect/ripple-effect.css +58 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/router-link/router-link.css +29 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/router-outlet/route-outlet.css +10 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/row/row.css +4 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/searchbar/searchbar.ios.css +348 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/searchbar/searchbar.md.css +279 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/segment/segment.ios.css +65 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/segment/segment.md.css +36 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/segment-button/segment-button.ios.css +446 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/segment-button/segment-button.md.css +424 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/select/select.ios.css +145 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/select/select.md.css +177 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/select-option/select-option.css +3 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/select-popover/select-popover.ios.css +14 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/select-popover/select-popover.md.css +37 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/skeleton-text/skeleton-text.css +53 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/slide/slide.css +31 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/slides/slides.ios.css +764 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/slides/slides.md.css +764 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/spinner/spinner.css +167 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/split-pane/split-pane.ios.css +108 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/split-pane/split-pane.md.css +108 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/tab/tab.css +4 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/tab-bar/tab-bar.ios.css +97 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/tab-bar/tab-bar.md.css +82 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/tab-button/tab-button.ios.css +308 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/tab-button/tab-button.md.css +331 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/tabs/tabs.css +19 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/text/text.css +3 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/textarea/textarea.ios.css +175 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/textarea/textarea.md.css +179 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/thumbnail/thumbnail.css +21 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/title/title.ios.css +122 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/title/title.md.css +55 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/toast/toast.ios.css +262 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/toast/toast.md.css +295 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/toggle/toggle.ios.css +286 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/toggle/toggle.md.css +261 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/toolbar/toolbar.ios.css +175 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/toolbar/toolbar.md.css +168 -0
- package/dist/node_modules/@ionic/core/dist/collection/components/virtual-scroll/virtual-scroll.css +21 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/button/button.css +49 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/card/card.css +208 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/cards.css +31 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/code/code.css +245 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/dropdown/dropdown.css +115 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header-mobile-collapse/header-mobile-collapse.css +255 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header.css +232 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/collapsible/collapsible.css +3 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu-toggle/menu-toggle.css +25 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu.css +71 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/nav/nav.css +194 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/notfound-page/notfound-page.css +4 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/overlay/overlay.css +67 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/page-footer/page-footer.css +25 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/pagination/pagination.css +93 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/select/select.css +52 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sidebar/sidebar.css +98 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sparkle-lower-content-nav/sparkle-lower-content-nav.css +8 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/table-of-contents/table-of-contents.css +37 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/tabs/tabs.css +64 -0
- package/dist/node_modules/@stencil/router/dist/collection/components/route/route.css +3 -0
- package/dist/node_modules/ionicons/dist/collection/components/icon/icon.css +101 -0
- package/dist/sparkle-core/index.esm.js +1 -19
- package/dist/sparkle-core/p-00d10dc9.js +4 -0
- package/dist/sparkle-core/p-0147266a.js +1 -0
- package/dist/sparkle-core/p-04c7b276.entry.js +1 -0
- package/dist/sparkle-core/p-05c032dd.js +4 -0
- package/dist/sparkle-core/p-06642405.entry.js +1 -0
- package/dist/sparkle-core/p-0664370b.entry.js +1 -0
- package/dist/sparkle-core/p-06c7d0f2.entry.js +1 -0
- package/dist/sparkle-core/p-076f0239.js +4 -0
- package/dist/sparkle-core/p-077c732b.js +4 -0
- package/dist/sparkle-core/p-08420531.entry.js +1 -0
- package/dist/sparkle-core/p-0ad5c123.entry.js +1 -0
- package/dist/sparkle-core/p-0afa3a4d.entry.js +1 -0
- package/dist/sparkle-core/p-0c3f3ea6.entry.js +1 -0
- package/dist/sparkle-core/p-0e4de1d0.js +4 -0
- package/dist/sparkle-core/p-0e8e539f.entry.js +1 -0
- package/dist/sparkle-core/p-11356b03.entry.js +1 -0
- package/dist/sparkle-core/p-11a6c175.entry.js +1 -0
- package/dist/sparkle-core/p-12dd96d7.js +4 -0
- package/dist/sparkle-core/p-13ec39db.entry.js +1 -0
- package/dist/sparkle-core/p-1adc98f6.js +1 -0
- package/dist/sparkle-core/p-1b1ba156.entry.js +1 -0
- package/dist/sparkle-core/p-1e125ca5.entry.js +1 -0
- package/dist/sparkle-core/p-1e4782af.entry.js +1 -0
- package/dist/sparkle-core/p-2033cd86.js +7 -0
- package/dist/sparkle-core/p-214d1229.entry.js +1 -0
- package/dist/sparkle-core/p-23aca7ca.js +4 -0
- package/dist/sparkle-core/p-24cb9a33.entry.js +1 -0
- package/dist/sparkle-core/p-27fbabc3.entry.js +1 -0
- package/dist/sparkle-core/p-2ba70507.entry.js +1 -0
- package/dist/sparkle-core/p-2c1ca854.entry.js +1 -0
- package/dist/sparkle-core/p-2caed39f.entry.js +1 -0
- package/dist/sparkle-core/p-2d9659e2.entry.js +1 -0
- package/dist/sparkle-core/p-2f569553.js +1 -0
- package/dist/sparkle-core/p-30b810d1.entry.js +4 -0
- package/dist/sparkle-core/p-32f4e565.entry.js +1 -0
- package/dist/sparkle-core/p-352677e6.entry.js +1 -0
- package/dist/sparkle-core/p-38b7cf68.entry.js +1 -0
- package/dist/sparkle-core/p-38c842d5.entry.js +1 -0
- package/dist/sparkle-core/p-3963e02b.entry.js +1 -0
- package/dist/sparkle-core/p-39712c56.entry.js +4 -0
- package/dist/sparkle-core/p-39a31e43.js +1 -0
- package/dist/sparkle-core/p-3daf2915.entry.js +352 -0
- package/dist/sparkle-core/p-3de0e00c.js +4 -0
- package/dist/sparkle-core/p-4053ecdb.entry.js +1 -0
- package/dist/sparkle-core/p-408176ba.js +1 -0
- package/dist/sparkle-core/p-42ed7d5f.entry.js +1 -0
- package/dist/sparkle-core/p-48f72e63.js +4 -0
- package/dist/sparkle-core/p-4b4a8703.js +1 -0
- package/dist/sparkle-core/p-4c6a7e52.js +1 -0
- package/dist/sparkle-core/p-4d1cfcbe.entry.js +1 -0
- package/dist/sparkle-core/p-4d4077ea.js +4 -0
- package/dist/sparkle-core/p-4fba3e4c.js +1 -0
- package/dist/sparkle-core/p-506221fe.js +4 -0
- package/dist/sparkle-core/p-5096739e.entry.js +1 -0
- package/dist/sparkle-core/p-5322c920.entry.js +1 -0
- package/dist/sparkle-core/p-5893bbe5.entry.js +1 -0
- package/dist/sparkle-core/p-594a6982.entry.js +1 -0
- package/dist/sparkle-core/p-5c435d5a.entry.js +1 -0
- package/dist/sparkle-core/p-5cad23f1.js +3 -0
- package/dist/sparkle-core/p-5d409601.js +1 -0
- package/dist/sparkle-core/p-601397df.entry.js +1 -0
- package/dist/sparkle-core/p-604a7987.js +4 -0
- package/dist/sparkle-core/p-616941c6.entry.js +1 -0
- package/dist/sparkle-core/p-6316d124.entry.js +1 -0
- package/dist/sparkle-core/p-63f71ada.entry.js +1 -0
- package/dist/sparkle-core/p-69487d90.entry.js +1 -0
- package/dist/sparkle-core/p-6bde0192.entry.js +7 -0
- package/dist/sparkle-core/p-6d2f4093.entry.js +7 -0
- package/dist/sparkle-core/p-6ffd2420.entry.js +1 -0
- package/dist/sparkle-core/p-72053ae0.entry.js +1 -0
- package/dist/sparkle-core/p-73721c84.js +4 -0
- package/dist/sparkle-core/p-74864276.entry.js +1 -0
- package/dist/sparkle-core/p-7d8427eb.js +4 -0
- package/dist/sparkle-core/p-7dae0f0e.js +1 -0
- package/dist/sparkle-core/p-7dbfc316.js +1 -0
- package/dist/sparkle-core/p-7e7ce516.js +4 -0
- package/dist/sparkle-core/p-81714d94.entry.js +1 -0
- package/dist/sparkle-core/p-8492a765.entry.js +1 -0
- package/dist/sparkle-core/p-859563db.entry.js +1 -0
- package/dist/sparkle-core/p-85d4cd5c.entry.js +1 -0
- package/dist/sparkle-core/p-865f36a8.entry.js +1 -0
- package/dist/sparkle-core/p-86ed13f0.js +5 -0
- package/dist/sparkle-core/p-871106e0.js +4 -0
- package/dist/sparkle-core/p-894ff7e6.entry.js +1 -0
- package/dist/sparkle-core/p-8a41b502.entry.js +1 -0
- package/dist/sparkle-core/p-8b56f734.js +1 -0
- package/dist/sparkle-core/p-8c74cbb6.entry.js +1 -0
- package/dist/sparkle-core/p-924b2917.js +4 -0
- package/dist/sparkle-core/p-9289cdbc.entry.js +1 -0
- package/dist/sparkle-core/p-957715c5.entry.js +1 -0
- package/dist/sparkle-core/p-973fe404.entry.js +22 -0
- package/dist/sparkle-core/p-975b99ee.entry.js +1 -0
- package/dist/sparkle-core/p-98daeddb.entry.js +1 -0
- package/dist/sparkle-core/p-99ee9919.js +1 -0
- package/dist/sparkle-core/p-9abbd715.entry.js +1 -0
- package/dist/sparkle-core/p-9d894ed4.js +4 -0
- package/dist/sparkle-core/p-9e309b3e.entry.js +1 -0
- package/dist/sparkle-core/p-9e7fee8f.entry.js +1 -0
- package/dist/sparkle-core/p-9ebf0537.entry.js +1 -0
- package/dist/sparkle-core/p-a208ab2d.js +4 -0
- package/dist/sparkle-core/p-a2638250.entry.js +1 -0
- package/dist/sparkle-core/p-a2ebcf0a.entry.js +1 -0
- package/dist/sparkle-core/p-a98d7ebe.entry.js +1 -0
- package/dist/sparkle-core/p-add30d46.js +4 -0
- package/dist/sparkle-core/p-b0603d19.js +16 -0
- package/dist/sparkle-core/p-b06e2bef.js +1 -0
- package/dist/sparkle-core/p-b3f375fb.entry.js +1 -0
- package/dist/sparkle-core/p-b5f3e1bf.entry.js +1 -0
- package/dist/sparkle-core/p-b6fec622.entry.js +1 -0
- package/dist/sparkle-core/p-b8d71ff4.js +1 -0
- package/dist/sparkle-core/p-b96f3c84.entry.js +7 -0
- package/dist/sparkle-core/p-bd80ff43.js +4 -0
- package/dist/sparkle-core/p-bd90903e.js +1 -0
- package/dist/sparkle-core/p-be64105c.entry.js +1 -0
- package/dist/sparkle-core/p-c0533c23.entry.js +1 -0
- package/dist/sparkle-core/p-c2990b24.entry.js +1 -0
- package/dist/sparkle-core/p-c3cadfc6.entry.js +1 -0
- package/dist/sparkle-core/p-c60b29bd.entry.js +4 -0
- package/dist/sparkle-core/p-c64a34cd.entry.js +1 -0
- package/dist/sparkle-core/p-c7e21070.entry.js +1 -0
- package/dist/sparkle-core/p-c9f753a4.js +1 -0
- package/dist/sparkle-core/p-cabe9139.js +1 -0
- package/dist/sparkle-core/p-cabfbf22.entry.js +1 -0
- package/dist/sparkle-core/p-cc518c36.entry.js +1 -0
- package/dist/sparkle-core/p-cffd4817.entry.js +1 -0
- package/dist/sparkle-core/p-d0adf726.entry.js +1 -0
- package/dist/sparkle-core/p-d20e4fcf.entry.js +1 -0
- package/dist/sparkle-core/p-d24e53ab.entry.js +1 -0
- package/dist/sparkle-core/p-d288e6c1.entry.js +1 -0
- package/dist/sparkle-core/p-d601810e.entry.js +1 -0
- package/dist/sparkle-core/p-d68092b7.js +4 -0
- package/dist/sparkle-core/p-da391f3f.js +1 -0
- package/dist/sparkle-core/p-de4deb61.entry.js +1 -0
- package/dist/sparkle-core/p-e0cad1bb.js +1 -0
- package/dist/sparkle-core/p-e249aebf.entry.js +1 -0
- package/dist/sparkle-core/p-e3e36ce9.entry.js +1 -0
- package/dist/sparkle-core/p-e421d638.entry.js +1 -0
- package/dist/sparkle-core/p-e686d8b5.entry.js +4 -0
- package/dist/sparkle-core/p-e8988989.entry.js +1 -0
- package/dist/sparkle-core/p-e9431eeb.js +7 -0
- package/dist/sparkle-core/p-ea962e1b.entry.js +1 -0
- package/dist/sparkle-core/p-eaa8bbee.js +4 -0
- package/dist/sparkle-core/p-ebd4354b.entry.js +1 -0
- package/dist/sparkle-core/p-ee1e0eb4.js +2 -0
- package/dist/sparkle-core/p-ef4edc48.entry.js +4 -0
- package/dist/sparkle-core/p-f196c124.entry.js +7 -0
- package/dist/sparkle-core/p-f3cba72a.js +4 -0
- package/dist/sparkle-core/p-f47fe1fe.entry.js +1 -0
- package/dist/sparkle-core/p-f714f77a.entry.js +1 -0
- package/dist/sparkle-core/p-f891c79a.entry.js +1 -0
- package/dist/sparkle-core/p-fb0ca75e.entry.js +5 -0
- package/dist/sparkle-core/p-fb757951.entry.js +1 -0
- package/dist/sparkle-core/p-fd8d0738.entry.js +4 -0
- package/dist/sparkle-core/p-fda95b6e.entry.js +1 -0
- package/dist/sparkle-core/p-fe6dc976.entry.js +1 -0
- package/dist/sparkle-core/p-ff080f82.entry.js +10 -0
- package/dist/sparkle-core/p-ff7a8a71.js +4 -0
- package/dist/sparkle-core/sparkle-core.css +1 -2660
- package/dist/sparkle-core/sparkle-core.esm.js +1 -130
- package/package.json +1 -1
- package/dist/sparkle-core/PrivateRoute-a12e7ee5.js +0 -37
- package/dist/sparkle-core/account.service-e711795d.js +0 -63
- package/dist/sparkle-core/active-router-af86c9b4.js +0 -73
- package/dist/sparkle-core/animation-676a644d.js +0 -984
- package/dist/sparkle-core/app-globals-9ffa9ec3.js +0 -10
- package/dist/sparkle-core/appdata.service-703dff70.js +0 -69
- package/dist/sparkle-core/assets/user.png +0 -0
- package/dist/sparkle-core/assets.service-6508aae6.js +0 -71
- package/dist/sparkle-core/assignment.service-e42e9368.js +0 -17
- package/dist/sparkle-core/button-active-d68c5eb7.js +0 -67
- package/dist/sparkle-core/compass-svg.entry.js +0 -128
- package/dist/sparkle-core/context-consumer.entry.js +0 -25
- package/dist/sparkle-core/course-select.entry.js +0 -26
- package/dist/sparkle-core/css-shim-04165e59.js +0 -4
- package/dist/sparkle-core/dom-26e7cb2c.js +0 -73
- package/dist/sparkle-core/dom-utils-8e73e88b.js +0 -55
- package/dist/sparkle-core/facilitator.service-00a88935.js +0 -79
- package/dist/sparkle-core/facilitator.store-01be0386.js +0 -18
- package/dist/sparkle-core/feed.service-d495f3e1.js +0 -53
- package/dist/sparkle-core/framework-delegate-d3fa493f.js +0 -107
- package/dist/sparkle-core/haptic-a9e94599.js +0 -124
- package/dist/sparkle-core/header-mobile-collapse.entry.js +0 -86
- package/dist/sparkle-core/helpers-f11f0674.js +0 -406
- package/dist/sparkle-core/icons-758d1417.js +0 -41
- package/dist/sparkle-core/index-05b398c2.js +0 -34
- package/dist/sparkle-core/index-0af0deac.js +0 -312
- package/dist/sparkle-core/index-0df264ee.js +0 -4518
- package/dist/sparkle-core/index-183cda39.js +0 -223
- package/dist/sparkle-core/index-18a69883.js +0 -1336
- package/dist/sparkle-core/index-1d7a6fa0.js +0 -269
- package/dist/sparkle-core/index-1dec9544.js +0 -3064
- package/dist/sparkle-core/index-81dab78f.js +0 -85
- package/dist/sparkle-core/index-9b5bcea1.js +0 -22
- package/dist/sparkle-core/index-bb469fe3.js +0 -128
- package/dist/sparkle-core/index-d2990a48.js +0 -184
- package/dist/sparkle-core/index-dd414b33.js +0 -653
- package/dist/sparkle-core/index-faeec85a.js +0 -8
- package/dist/sparkle-core/index.es-1f6eedc5.js +0 -11066
- package/dist/sparkle-core/input-shims-0b2f5522.js +0 -418
- package/dist/sparkle-core/ion-accordion-group.entry.js +0 -201
- package/dist/sparkle-core/ion-accordion.entry.js +0 -332
- package/dist/sparkle-core/ion-action-sheet.entry.js +0 -263
- package/dist/sparkle-core/ion-alert.entry.js +0 -448
- package/dist/sparkle-core/ion-app.entry.js +0 -75
- package/dist/sparkle-core/ion-avatar.entry.js +0 -21
- package/dist/sparkle-core/ion-back-button.entry.js +0 -90
- package/dist/sparkle-core/ion-backdrop.entry.js +0 -63
- package/dist/sparkle-core/ion-badge.entry.js +0 -25
- package/dist/sparkle-core/ion-breadcrumb.entry.js +0 -91
- package/dist/sparkle-core/ion-breadcrumbs.entry.js +0 -129
- package/dist/sparkle-core/ion-button.entry.js +0 -125
- package/dist/sparkle-core/ion-buttons.entry.js +0 -38
- package/dist/sparkle-core/ion-card-content.entry.js +0 -26
- package/dist/sparkle-core/ion-card-header.entry.js +0 -33
- package/dist/sparkle-core/ion-card-subtitle.entry.js +0 -26
- package/dist/sparkle-core/ion-card-title.entry.js +0 -26
- package/dist/sparkle-core/ion-card.entry.js +0 -64
- package/dist/sparkle-core/ion-checkbox.entry.js +0 -109
- package/dist/sparkle-core/ion-chip.entry.js +0 -36
- package/dist/sparkle-core/ion-col.entry.js +0 -121
- package/dist/sparkle-core/ion-content.entry.js +0 -319
- package/dist/sparkle-core/ion-datetime-button.entry.js +0 -308
- package/dist/sparkle-core/ion-datetime.entry.js +0 -1619
- package/dist/sparkle-core/ion-fab-button.entry.js +0 -104
- package/dist/sparkle-core/ion-fab-list.entry.js +0 -41
- package/dist/sparkle-core/ion-fab.entry.js +0 -72
- package/dist/sparkle-core/ion-footer.entry.js +0 -116
- package/dist/sparkle-core/ion-grid.entry.js +0 -24
- package/dist/sparkle-core/ion-header.entry.js +0 -341
- package/dist/sparkle-core/ion-icon.entry.js +0 -200
- package/dist/sparkle-core/ion-img.entry.js +0 -97
- package/dist/sparkle-core/ion-infinite-scroll-content.entry.js +0 -33
- package/dist/sparkle-core/ion-infinite-scroll.entry.js +0 -202
- package/dist/sparkle-core/ion-input.entry.js +0 -293
- package/dist/sparkle-core/ion-item-divider.entry.js +0 -36
- package/dist/sparkle-core/ion-item-group.entry.js +0 -27
- package/dist/sparkle-core/ion-item-option.entry.js +0 -56
- package/dist/sparkle-core/ion-item-options.entry.js +0 -43
- package/dist/sparkle-core/ion-item-sliding.entry.js +0 -394
- package/dist/sparkle-core/ion-item.entry.js +0 -267
- package/dist/sparkle-core/ion-label.entry.js +0 -77
- package/dist/sparkle-core/ion-list-header.entry.js +0 -27
- package/dist/sparkle-core/ion-list.entry.js +0 -48
- package/dist/sparkle-core/ion-loading.entry.js +0 -211
- package/dist/sparkle-core/ion-menu-button.entry.js +0 -72
- package/dist/sparkle-core/ion-menu-toggle.entry.js +0 -43
- package/dist/sparkle-core/ion-menu.entry.js +0 -575
- package/dist/sparkle-core/ion-modal.entry.js +0 -1706
- package/dist/sparkle-core/ion-nav-link.entry.js +0 -43
- package/dist/sparkle-core/ion-nav.entry.js +0 -872
- package/dist/sparkle-core/ion-note.entry.js +0 -25
- package/dist/sparkle-core/ion-picker-column-internal.entry.js +0 -363
- package/dist/sparkle-core/ion-picker-column.entry.js +0 -327
- package/dist/sparkle-core/ion-picker-internal.entry.js +0 -454
- package/dist/sparkle-core/ion-picker.entry.js +0 -217
- package/dist/sparkle-core/ion-popover.entry.js +0 -1362
- package/dist/sparkle-core/ion-progress-bar.entry.js +0 -70
- package/dist/sparkle-core/ion-radio-group.entry.js +0 -121
- package/dist/sparkle-core/ion-radio.entry.js +0 -111
- package/dist/sparkle-core/ion-range.entry.js +0 -511
- package/dist/sparkle-core/ion-refresher-content.entry.js +0 -31
- package/dist/sparkle-core/ion-refresher.entry.js +0 -798
- package/dist/sparkle-core/ion-reorder-group.entry.js +0 -277
- package/dist/sparkle-core/ion-reorder.entry.js +0 -34
- package/dist/sparkle-core/ion-ripple-effect.entry.js +0 -89
- package/dist/sparkle-core/ion-route-redirect.entry.js +0 -20
- package/dist/sparkle-core/ion-route.entry.js +0 -45
- package/dist/sparkle-core/ion-router-link.entry.js +0 -34
- package/dist/sparkle-core/ion-router-outlet.entry.js +0 -196
- package/dist/sparkle-core/ion-router.entry.js +0 -827
- package/dist/sparkle-core/ion-row.entry.js +0 -16
- package/dist/sparkle-core/ion-searchbar.entry.js +0 -366
- package/dist/sparkle-core/ion-segment-button.entry.js +0 -98
- package/dist/sparkle-core/ion-segment.entry.js +0 -415
- package/dist/sparkle-core/ion-select-option.entry.js +0 -23
- package/dist/sparkle-core/ion-select-popover.entry.js +0 -96
- package/dist/sparkle-core/ion-select.entry.js +0 -510
- package/dist/sparkle-core/ion-skeleton-text.entry.js +0 -29
- package/dist/sparkle-core/ion-slide.entry.js +0 -21
- package/dist/sparkle-core/ion-slides.entry.js +0 -387
- package/dist/sparkle-core/ion-spinner.entry.js +0 -60
- package/dist/sparkle-core/ion-split-pane.entry.js +0 -156
- package/dist/sparkle-core/ion-tab-bar.entry.js +0 -71
- package/dist/sparkle-core/ion-tab-button.entry.js +0 -99
- package/dist/sparkle-core/ion-tab.entry.js +0 -63
- package/dist/sparkle-core/ion-tabs.entry.js +0 -150
- package/dist/sparkle-core/ion-text.entry.js +0 -20
- package/dist/sparkle-core/ion-textarea.entry.js +0 -244
- package/dist/sparkle-core/ion-thumbnail.entry.js +0 -16
- package/dist/sparkle-core/ion-title.entry.js +0 -48
- package/dist/sparkle-core/ion-toast.entry.js +0 -268
- package/dist/sparkle-core/ion-toggle.entry.js +0 -173
- package/dist/sparkle-core/ion-toolbar.entry.js +0 -70
- package/dist/sparkle-core/ion-virtual-scroll.entry.js +0 -551
- package/dist/sparkle-core/ionic-global-127576f6.js +0 -226
- package/dist/sparkle-core/ios.transition-02531dda.js +0 -479
- package/dist/sparkle-core/location-utils-fea12957.js +0 -229
- package/dist/sparkle-core/match-path-760e1797.js +0 -343
- package/dist/sparkle-core/md.transition-f8765467.js +0 -55
- package/dist/sparkle-core/media.service-2609406e.js +0 -36
- package/dist/sparkle-core/menu-toggle-util-6cc13cbd.js +0 -12
- package/dist/sparkle-core/overlays-fd3cfa13.js +0 -493
- package/dist/sparkle-core/parse-60474840.js +0 -1196
- package/dist/sparkle-core/purify-d9093094.js +0 -1469
- package/dist/sparkle-core/quiz.model-1cff62e4.js +0 -5
- package/dist/sparkle-core/shadow-css-1257b266.js +0 -387
- package/dist/sparkle-core/signalR.service-2b7645c1.js +0 -2983
- package/dist/sparkle-core/sparkle-animation-player.entry.js +0 -513
- package/dist/sparkle-core/sparkle-assignment.entry.js +0 -114
- package/dist/sparkle-core/sparkle-button.entry.js +0 -24
- package/dist/sparkle-core/sparkle-card.entry.js +0 -61
- package/dist/sparkle-core/sparkle-cards.entry.js +0 -15
- package/dist/sparkle-core/sparkle-character-intro.entry.js +0 -22
- package/dist/sparkle-core/sparkle-code.entry.js +0 -39
- package/dist/sparkle-core/sparkle-compass-post.entry.js +0 -129
- package/dist/sparkle-core/sparkle-compass.entry.js +0 -122
- package/dist/sparkle-core/sparkle-course-root.entry.js +0 -155
- package/dist/sparkle-core/sparkle-discussion-questions.entry.js +0 -122
- package/dist/sparkle-core/sparkle-discussion-results.entry.js +0 -189
- package/dist/sparkle-core/sparkle-discussion.entry.js +0 -52
- package/dist/sparkle-core/sparkle-dropdown.entry.js +0 -57
- package/dist/sparkle-core/sparkle-emoji.entry.js +0 -77
- package/dist/sparkle-core/sparkle-export-lessons.entry.js +0 -10081
- package/dist/sparkle-core/sparkle-facilitator-dashboard.entry.js +0 -93
- package/dist/sparkle-core/sparkle-facilitator-header.entry.js +0 -60
- package/dist/sparkle-core/sparkle-facilitator-notes-form.entry.js +0 -160
- package/dist/sparkle-core/sparkle-facilitator-notes.entry.js +0 -65
- package/dist/sparkle-core/sparkle-facilitator-page.entry.js +0 -198
- package/dist/sparkle-core/sparkle-feed-post.entry.js +0 -131
- package/dist/sparkle-core/sparkle-feedback.entry.js +0 -106
- package/dist/sparkle-core/sparkle-file-upload.entry.js +0 -57
- package/dist/sparkle-core/sparkle-forgot-password.entry.js +0 -80
- package/dist/sparkle-core/sparkle-goal-form.entry.js +0 -182
- package/dist/sparkle-core/sparkle-goal-item.entry.js +0 -15
- package/dist/sparkle-core/sparkle-goal-progress.entry.js +0 -15
- package/dist/sparkle-core/sparkle-goals.entry.js +0 -47
- package/dist/sparkle-core/sparkle-gww-comment-list.entry.js +0 -22
- package/dist/sparkle-core/sparkle-gww-graph.entry.js +0 -15
- package/dist/sparkle-core/sparkle-gww-item.entry.js +0 -80
- package/dist/sparkle-core/sparkle-gww.entry.js +0 -44
- package/dist/sparkle-core/sparkle-header.entry.js +0 -97
- package/dist/sparkle-core/sparkle-health.entry.js +0 -70
- package/dist/sparkle-core/sparkle-input.entry.js +0 -52
- package/dist/sparkle-core/sparkle-intro.entry.js +0 -22
- package/dist/sparkle-core/sparkle-login.entry.js +0 -116
- package/dist/sparkle-core/sparkle-lower-content-nav.entry.js +0 -18
- package/dist/sparkle-core/sparkle-menu-collapsible.entry.js +0 -42
- package/dist/sparkle-core/sparkle-menu-toggle.entry.js +0 -24
- package/dist/sparkle-core/sparkle-menu.entry.js +0 -26
- package/dist/sparkle-core/sparkle-modal-image.entry.js +0 -33
- package/dist/sparkle-core/sparkle-mood.entry.js +0 -76
- package/dist/sparkle-core/sparkle-nav.entry.js +0 -113
- package/dist/sparkle-core/sparkle-notfound-page.entry.js +0 -25
- package/dist/sparkle-core/sparkle-online-students.entry.js +0 -55
- package/dist/sparkle-core/sparkle-overlay.entry.js +0 -90
- package/dist/sparkle-core/sparkle-page-footer.entry.js +0 -24
- package/dist/sparkle-core/sparkle-page.entry.js +0 -245
- package/dist/sparkle-core/sparkle-pagination.entry.js +0 -67
- package/dist/sparkle-core/sparkle-poll.entry.js +0 -15
- package/dist/sparkle-core/sparkle-quiz-container.entry.js +0 -43
- package/dist/sparkle-core/sparkle-quiz-feedback.entry.js +0 -18
- package/dist/sparkle-core/sparkle-quiz-input.entry.js +0 -16
- package/dist/sparkle-core/sparkle-quiz-old.entry.js +0 -116
- package/dist/sparkle-core/sparkle-quiz-opinion.entry.js +0 -41
- package/dist/sparkle-core/sparkle-quiz-poll.entry.js +0 -16
- package/dist/sparkle-core/sparkle-quiz-select.entry.js +0 -29
- package/dist/sparkle-core/sparkle-quiz.entry.js +0 -98
- package/dist/sparkle-core/sparkle-reset-password.entry.js +0 -96
- package/dist/sparkle-core/sparkle-root.entry.js +0 -79
- package/dist/sparkle-core/sparkle-select.entry.js +0 -57
- package/dist/sparkle-core/sparkle-sidebar.entry.js +0 -39
- package/dist/sparkle-core/sparkle-signup.entry.js +0 -144
- package/dist/sparkle-core/sparkle-tab.entry.js +0 -22
- package/dist/sparkle-core/sparkle-table-of-contents.entry.js +0 -67
- package/dist/sparkle-core/sparkle-tabs.entry.js +0 -62
- package/dist/sparkle-core/sparkle-unauthorized.entry.js +0 -17
- package/dist/sparkle-core/sparkle-user-enrollment.entry.js +0 -85
- package/dist/sparkle-core/sparkle-user-profile.entry.js +0 -129
- package/dist/sparkle-core/sparkle-validation-error.entry.js +0 -17
- package/dist/sparkle-core/sparkle-video-player.entry.js +0 -18
- package/dist/sparkle-core/sparkle-youtube.entry.js +0 -35
- package/dist/sparkle-core/status-tap-52feb1b1.js +0 -40
- package/dist/sparkle-core/stencil-async-content.entry.js +0 -28
- package/dist/sparkle-core/stencil-route-link.entry.js +0 -74
- package/dist/sparkle-core/stencil-route-switch.entry.js +0 -100
- package/dist/sparkle-core/stencil-route-title.entry.js +0 -28
- package/dist/sparkle-core/stencil-route.entry.js +0 -93
- package/dist/sparkle-core/stencil-router-prompt.entry.js +0 -55
- package/dist/sparkle-core/stencil-router-redirect.entry.js +0 -28
- package/dist/sparkle-core/stencil-router.entry.js +0 -636
- package/dist/sparkle-core/store.service-0f7d998b.js +0 -16
- package/dist/sparkle-core/student.service-f0375229.js +0 -59
- package/dist/sparkle-core/swipe-back-9a614189.js +0 -73
- package/dist/sparkle-core/swiper.bundle-4274e115.js +0 -6418
- package/dist/sparkle-core/user.store-3d052406.js +0 -19
- package/dist/sparkle-core/util-ba470e54.js +0 -14683
- package/dist/sparkle-core/utils-cae23bce.js +0 -114
- /package/dist/{sparkle-core → esm}/cubic-bezier-4c0db14f.js +0 -0
- /package/dist/{sparkle-core → esm}/focus-visible-4e9a0764.js +0 -0
- /package/dist/{sparkle-core → esm}/hardware-back-button-fa04d6e9.js +0 -0
- /package/dist/{sparkle-core → esm}/index-be6112f8.js +0 -0
- /package/dist/{sparkle-core → esm}/keyboard-7e8329b3.js +0 -0
- /package/dist/{sparkle-core → esm}/localstorage.service-4bf408c8.js +0 -0
- /package/dist/{sparkle-core → esm}/spinner-configs-a37e628a.js +0 -0
- /package/dist/{sparkle-core → esm}/theme-7ef00c83.js +0 -0
@@ -0,0 +1,1707 @@
|
|
1
|
+
import { r as registerInstance, i as createEvent, w as writeTask, h, H as Host, e as getElement } from './index-c04b9ed5.js';
|
2
|
+
import { g as getIonMode, c as config } from './ionic-global-4903e23e.js';
|
3
|
+
import { f as findClosestIonContent, i as isIonContent, d as disableContentScrollY, r as resetContentScrollY, a as findIonContent, p as printIonContentErrorMsg } from './index-5e8971ae.js';
|
4
|
+
import { C as CoreDelegate, a as attachComponent, d as detachComponent } from './framework-delegate-3e634a5c.js';
|
5
|
+
import { g as getElementRoot, m as clamp, l as raf } from './helpers-bf0e23d6.js';
|
6
|
+
import { KEYBOARD_DID_OPEN } from './keyboard-7e8329b3.js';
|
7
|
+
import { a as printIonWarning } from './index-dad75b83.js';
|
8
|
+
import { B as BACKDROP, p as prepareOverlay, b as present, c as activeAnimations, d as dismiss, e as eventMethod } from './overlays-4233a39d.js';
|
9
|
+
import { g as getClassMap } from './theme-7ef00c83.js';
|
10
|
+
import { d as deepReady } from './index-2b84cad2.js';
|
11
|
+
import { c as createAnimation } from './animation-12377cb3.js';
|
12
|
+
import { g as getTimeGivenProgression } from './cubic-bezier-4c0db14f.js';
|
13
|
+
import { createGesture } from './index-21661af2.js';
|
14
|
+
import './hardware-back-button-fa04d6e9.js';
|
15
|
+
import './gesture-controller-7be18351.js';
|
16
|
+
|
17
|
+
/*!
|
18
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
19
|
+
*/
|
20
|
+
/**
|
21
|
+
* When accessing the window, it is important
|
22
|
+
* to account for SSR applications where the
|
23
|
+
* window is not available. Code that accesses
|
24
|
+
* window when it is not available will crash.
|
25
|
+
* Even checking if `window === undefined` will cause
|
26
|
+
* apps to crash in SSR.
|
27
|
+
*
|
28
|
+
* Use win below to access an SSR-safe version
|
29
|
+
* of the window.
|
30
|
+
*
|
31
|
+
* Example 1:
|
32
|
+
* Before:
|
33
|
+
* if (window.innerWidth > 768) { ... }
|
34
|
+
*
|
35
|
+
* After:
|
36
|
+
* import { win } from 'path/to/this/file';
|
37
|
+
* if (win?.innerWidth > 768) { ... }
|
38
|
+
*
|
39
|
+
* Note: Code inside of this if-block will
|
40
|
+
* not run in an SSR environment.
|
41
|
+
*/
|
42
|
+
const win = typeof window !== 'undefined' ? window : undefined;
|
43
|
+
|
44
|
+
/*!
|
45
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
46
|
+
*/
|
47
|
+
var Style;
|
48
|
+
(function (Style) {
|
49
|
+
Style["Dark"] = "DARK";
|
50
|
+
Style["Light"] = "LIGHT";
|
51
|
+
Style["Default"] = "DEFAULT";
|
52
|
+
})(Style || (Style = {}));
|
53
|
+
const StatusBar = {
|
54
|
+
getEngine() {
|
55
|
+
var _a, _b, _c;
|
56
|
+
return ((_b = (_a = win) === null || _a === void 0 ? void 0 : _a.Capacitor) === null || _b === void 0 ? void 0 : _b.isPluginAvailable('StatusBar')) && ((_c = win) === null || _c === void 0 ? void 0 : _c.Capacitor.Plugins.StatusBar);
|
57
|
+
},
|
58
|
+
supportsDefaultStatusBarStyle() {
|
59
|
+
var _a, _b;
|
60
|
+
/**
|
61
|
+
* The 'DEFAULT' status bar style was added
|
62
|
+
* to the @capacitor/status-bar plugin in Capacitor 3.
|
63
|
+
* PluginHeaders is only supported in Capacitor 3+,
|
64
|
+
* so we can use this to detect Capacitor 3.
|
65
|
+
*/
|
66
|
+
return !!((_b = (_a = win) === null || _a === void 0 ? void 0 : _a.Capacitor) === null || _b === void 0 ? void 0 : _b.PluginHeaders);
|
67
|
+
},
|
68
|
+
setStyle(options) {
|
69
|
+
const engine = this.getEngine();
|
70
|
+
if (!engine) {
|
71
|
+
return;
|
72
|
+
}
|
73
|
+
engine.setStyle(options);
|
74
|
+
},
|
75
|
+
};
|
76
|
+
|
77
|
+
/*!
|
78
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
79
|
+
*/
|
80
|
+
/**
|
81
|
+
* Use y = mx + b to
|
82
|
+
* figure out the backdrop value
|
83
|
+
* at a particular x coordinate. This
|
84
|
+
* is useful when the backdrop does
|
85
|
+
* not begin to fade in until after
|
86
|
+
* the 0 breakpoint.
|
87
|
+
*/
|
88
|
+
const getBackdropValueForSheet = (x, backdropBreakpoint) => {
|
89
|
+
/**
|
90
|
+
* We will use these points:
|
91
|
+
* (backdropBreakpoint, 0)
|
92
|
+
* (maxBreakpoint, 1)
|
93
|
+
* We know that at the beginning breakpoint,
|
94
|
+
* the backdrop will be hidden. We also
|
95
|
+
* know that at the maxBreakpoint, the backdrop
|
96
|
+
* must be fully visible. maxBreakpoint should
|
97
|
+
* always be 1 even if the maximum value
|
98
|
+
* of the breakpoints array is not 1 since
|
99
|
+
* the animation runs from a progress of 0
|
100
|
+
* to a progress of 1.
|
101
|
+
* m = (y2 - y1) / (x2 - x1)
|
102
|
+
*
|
103
|
+
* This is simplified from:
|
104
|
+
* m = (1 - 0) / (maxBreakpoint - backdropBreakpoint)
|
105
|
+
*
|
106
|
+
* If the backdropBreakpoint is 1, we return 0 as the
|
107
|
+
* backdrop is completely hidden.
|
108
|
+
*
|
109
|
+
*/
|
110
|
+
if (backdropBreakpoint === 1) {
|
111
|
+
return 0;
|
112
|
+
}
|
113
|
+
const slope = 1 / (1 - backdropBreakpoint);
|
114
|
+
/**
|
115
|
+
* From here, compute b which is
|
116
|
+
* the backdrop opacity if the offset
|
117
|
+
* is 0. If the backdrop does not
|
118
|
+
* begin to fade in until after the
|
119
|
+
* 0 breakpoint, this b value will be
|
120
|
+
* negative. This is fine as we never pass
|
121
|
+
* b directly into the animation keyframes.
|
122
|
+
* b = y - mx
|
123
|
+
* Use a known point: (backdropBreakpoint, 0)
|
124
|
+
* This is simplified from:
|
125
|
+
* b = 0 - (backdropBreakpoint * slope)
|
126
|
+
*/
|
127
|
+
const b = -(backdropBreakpoint * slope);
|
128
|
+
/**
|
129
|
+
* Finally, we can now determine the
|
130
|
+
* backdrop offset given an arbitrary
|
131
|
+
* gesture offset.
|
132
|
+
*/
|
133
|
+
return x * slope + b;
|
134
|
+
};
|
135
|
+
/**
|
136
|
+
* The tablet/desktop card modal activates
|
137
|
+
* when the window width is >= 768.
|
138
|
+
* At that point, the presenting element
|
139
|
+
* is not transformed, so we do not need to
|
140
|
+
* adjust the status bar color.
|
141
|
+
*
|
142
|
+
* Note: We check supportsDefaultStatusBarStyle so that
|
143
|
+
* Capacitor <= 2 users do not get their status bar
|
144
|
+
* stuck in an inconsistent state due to a lack of
|
145
|
+
* support for Style.Default.
|
146
|
+
*/
|
147
|
+
const setCardStatusBarDark = () => {
|
148
|
+
if (!win || win.innerWidth >= 768 || !StatusBar.supportsDefaultStatusBarStyle()) {
|
149
|
+
return;
|
150
|
+
}
|
151
|
+
StatusBar.setStyle({ style: Style.Dark });
|
152
|
+
};
|
153
|
+
const setCardStatusBarDefault = () => {
|
154
|
+
if (!win || win.innerWidth >= 768 || !StatusBar.supportsDefaultStatusBarStyle()) {
|
155
|
+
return;
|
156
|
+
}
|
157
|
+
StatusBar.setStyle({ style: Style.Default });
|
158
|
+
};
|
159
|
+
|
160
|
+
/*!
|
161
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
162
|
+
*/
|
163
|
+
const handleCanDismiss = async (el, animation) => {
|
164
|
+
/**
|
165
|
+
* If canDismiss is not a function
|
166
|
+
* then we can return early. If canDismiss is `true`,
|
167
|
+
* then canDismissBlocksGesture is `false` as canDismiss
|
168
|
+
* will never interrupt the gesture. As a result,
|
169
|
+
* this code block is never reached. If canDismiss is `false`,
|
170
|
+
* then we never dismiss.
|
171
|
+
*/
|
172
|
+
if (typeof el.canDismiss !== 'function') {
|
173
|
+
return;
|
174
|
+
}
|
175
|
+
/**
|
176
|
+
* Run the canDismiss callback.
|
177
|
+
* If the function returns `true`,
|
178
|
+
* then we can proceed with dismiss.
|
179
|
+
*/
|
180
|
+
const shouldDismiss = await el.canDismiss();
|
181
|
+
if (!shouldDismiss) {
|
182
|
+
return;
|
183
|
+
}
|
184
|
+
/**
|
185
|
+
* If canDismiss resolved after the snap
|
186
|
+
* back animation finished, we can
|
187
|
+
* dismiss immediately.
|
188
|
+
*
|
189
|
+
* If canDismiss resolved before the snap
|
190
|
+
* back animation finished, we need to
|
191
|
+
* wait until the snap back animation is
|
192
|
+
* done before dismissing.
|
193
|
+
*/
|
194
|
+
if (animation.isRunning()) {
|
195
|
+
animation.onFinish(() => {
|
196
|
+
el.dismiss(undefined, 'handler');
|
197
|
+
}, { oneTimeCallback: true });
|
198
|
+
}
|
199
|
+
else {
|
200
|
+
el.dismiss(undefined, 'handler');
|
201
|
+
}
|
202
|
+
};
|
203
|
+
/**
|
204
|
+
* This function lets us simulate a realistic spring-like animation
|
205
|
+
* when swiping down on the modal.
|
206
|
+
* There are two forces that we need to use to compute the spring physics:
|
207
|
+
*
|
208
|
+
* 1. Stiffness, k: This is a measure of resistance applied a spring.
|
209
|
+
* 2. Dampening, c: This value has the effect of reducing or preventing oscillation.
|
210
|
+
*
|
211
|
+
* Using these two values, we can calculate the Spring Force and the Dampening Force
|
212
|
+
* to compute the total force applied to a spring.
|
213
|
+
*
|
214
|
+
* Spring Force: This force pulls a spring back into its equilibrium position.
|
215
|
+
* Hooke's Law tells us that that spring force (FS) = kX.
|
216
|
+
* k is the stiffness of a spring, and X is the displacement of the spring from its
|
217
|
+
* equilibrium position. In this case, it is the amount by which the free end
|
218
|
+
* of a spring was displaced (stretched/pushed) from its "relaxed" position.
|
219
|
+
*
|
220
|
+
* Dampening Force: This force slows down motion. Without it, a spring would oscillate forever.
|
221
|
+
* The dampening force, FD, can be found via this formula: FD = -cv
|
222
|
+
* where c the dampening value and v is velocity.
|
223
|
+
*
|
224
|
+
* Therefore, the resulting force that is exerted on the block is:
|
225
|
+
* F = FS + FD = -kX - cv
|
226
|
+
*
|
227
|
+
* Newton's 2nd Law tells us that F = ma:
|
228
|
+
* ma = -kX - cv.
|
229
|
+
*
|
230
|
+
* For Ionic's purposes, we can assume that m = 1:
|
231
|
+
* a = -kX - cv
|
232
|
+
*
|
233
|
+
* Imagine a block attached to the end of a spring. At equilibrium
|
234
|
+
* the block is at position x = 1.
|
235
|
+
* Pressing on the block moves it to position x = 0;
|
236
|
+
* So, to calculate the displacement, we need to take the
|
237
|
+
* current position and subtract the previous position from it.
|
238
|
+
* X = x - x0 = 0 - 1 = -1.
|
239
|
+
*
|
240
|
+
* For Ionic's purposes, we are only pushing on the spring modal
|
241
|
+
* so we have a max position of 1.
|
242
|
+
* As a result, we can expand displacement to this formula:
|
243
|
+
* X = x - 1
|
244
|
+
*
|
245
|
+
* a = -k(x - 1) - cv
|
246
|
+
*
|
247
|
+
* We can represent the motion of something as a function of time: f(t) = x.
|
248
|
+
* The derivative of position gives us the velocity: f'(t)
|
249
|
+
* The derivative of the velocity gives us the acceleration: f''(t)
|
250
|
+
*
|
251
|
+
* We can substitute the formula above with these values:
|
252
|
+
*
|
253
|
+
* f"(t) = -k * (f(t) - 1) - c * f'(t)
|
254
|
+
*
|
255
|
+
* This is called a differential equation.
|
256
|
+
*
|
257
|
+
* We know that at t = 0, we are at x = 0 because the modal does not move: f(0) = 0
|
258
|
+
* This means our velocity is also zero: f'(0) = 0.
|
259
|
+
*
|
260
|
+
* We can cheat a bit and plug the formula into Wolfram Alpha.
|
261
|
+
* However, we need to pick stiffness and dampening values:
|
262
|
+
* k = 0.57
|
263
|
+
* c = 15
|
264
|
+
*
|
265
|
+
* I picked these as they are fairly close to native iOS's spring effect
|
266
|
+
* with the modal.
|
267
|
+
*
|
268
|
+
* What we plug in is this: f(0) = 0; f'(0) = 0; f''(t) = -0.57(f(t) - 1) - 15f'(t)
|
269
|
+
*
|
270
|
+
* The result is a formula that lets us calculate the acceleration
|
271
|
+
* for a given time t.
|
272
|
+
* Note: This is the approximate form of the solution. Wolfram Alpha will
|
273
|
+
* give you a complex differential equation too.
|
274
|
+
*/
|
275
|
+
const calculateSpringStep = (t) => {
|
276
|
+
return 0.00255275 * 2.71828 ** (-14.9619 * t) - 1.00255 * 2.71828 ** (-0.0380968 * t) + 1;
|
277
|
+
};
|
278
|
+
|
279
|
+
/*!
|
280
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
281
|
+
*/
|
282
|
+
// Defaults for the card swipe animation
|
283
|
+
const SwipeToCloseDefaults = {
|
284
|
+
MIN_PRESENTING_SCALE: 0.93,
|
285
|
+
};
|
286
|
+
const createSwipeToCloseGesture = (el, animation, onDismiss) => {
|
287
|
+
/**
|
288
|
+
* The step value at which a card modal
|
289
|
+
* is eligible for dismissing via gesture.
|
290
|
+
*/
|
291
|
+
const DISMISS_THRESHOLD = 0.5;
|
292
|
+
const height = el.offsetHeight;
|
293
|
+
let isOpen = false;
|
294
|
+
let canDismissBlocksGesture = false;
|
295
|
+
let contentEl = null;
|
296
|
+
let scrollEl = null;
|
297
|
+
const canDismissMaxStep = 0.2;
|
298
|
+
let initialScrollY = true;
|
299
|
+
let lastStep = 0;
|
300
|
+
const getScrollY = () => {
|
301
|
+
if (contentEl && isIonContent(contentEl)) {
|
302
|
+
return contentEl.scrollY;
|
303
|
+
/**
|
304
|
+
* Custom scroll containers are intended to be
|
305
|
+
* used with virtual scrolling, so we assume
|
306
|
+
* there is scrolling in this case.
|
307
|
+
*/
|
308
|
+
}
|
309
|
+
else {
|
310
|
+
return true;
|
311
|
+
}
|
312
|
+
};
|
313
|
+
const canStart = (detail) => {
|
314
|
+
const target = detail.event.target;
|
315
|
+
if (target === null || !target.closest) {
|
316
|
+
return true;
|
317
|
+
}
|
318
|
+
/**
|
319
|
+
* If we are swiping on the content,
|
320
|
+
* swiping should only be possible if
|
321
|
+
* the content is scrolled all the way
|
322
|
+
* to the top so that we do not interfere
|
323
|
+
* with scrolling.
|
324
|
+
*
|
325
|
+
* We cannot assume that the `ion-content`
|
326
|
+
* target will remain consistent between
|
327
|
+
* swipes. For example, when using
|
328
|
+
* ion-nav within a card modal it is
|
329
|
+
* possible to swipe, push a view, and then
|
330
|
+
* swipe again. The target content will not
|
331
|
+
* be the same between swipes.
|
332
|
+
*/
|
333
|
+
contentEl = findClosestIonContent(target);
|
334
|
+
if (contentEl) {
|
335
|
+
/**
|
336
|
+
* The card should never swipe to close
|
337
|
+
* on the content with a refresher.
|
338
|
+
* Note: We cannot solve this by making the
|
339
|
+
* swipeToClose gesture have a higher priority
|
340
|
+
* than the refresher gesture as the iOS native
|
341
|
+
* refresh gesture uses a scroll listener in
|
342
|
+
* addition to a gesture.
|
343
|
+
*
|
344
|
+
* Note: Do not use getScrollElement here
|
345
|
+
* because we need this to be a synchronous
|
346
|
+
* operation, and getScrollElement is
|
347
|
+
* asynchronous.
|
348
|
+
*/
|
349
|
+
if (isIonContent(contentEl)) {
|
350
|
+
const root = getElementRoot(contentEl);
|
351
|
+
scrollEl = root.querySelector('.inner-scroll');
|
352
|
+
}
|
353
|
+
else {
|
354
|
+
scrollEl = contentEl;
|
355
|
+
}
|
356
|
+
const hasRefresherInContent = !!contentEl.querySelector('ion-refresher');
|
357
|
+
return !hasRefresherInContent && scrollEl.scrollTop === 0;
|
358
|
+
}
|
359
|
+
/**
|
360
|
+
* Card should be swipeable on all
|
361
|
+
* parts of the modal except for the footer.
|
362
|
+
*/
|
363
|
+
const footer = target.closest('ion-footer');
|
364
|
+
if (footer === null) {
|
365
|
+
return true;
|
366
|
+
}
|
367
|
+
return false;
|
368
|
+
};
|
369
|
+
const onStart = (detail) => {
|
370
|
+
const { deltaY } = detail;
|
371
|
+
/**
|
372
|
+
* Get the initial scrollY value so
|
373
|
+
* that we can correctly reset the scrollY
|
374
|
+
* prop when the gesture ends.
|
375
|
+
*/
|
376
|
+
initialScrollY = getScrollY();
|
377
|
+
/**
|
378
|
+
* If canDismiss is anything other than `true`
|
379
|
+
* then users should be able to swipe down
|
380
|
+
* until a threshold is hit. At that point,
|
381
|
+
* the card modal should not proceed any further.
|
382
|
+
* TODO (FW-937)
|
383
|
+
* Remove undefined check
|
384
|
+
*/
|
385
|
+
canDismissBlocksGesture = el.canDismiss !== undefined && el.canDismiss !== true;
|
386
|
+
/**
|
387
|
+
* If we are pulling down, then
|
388
|
+
* it is possible we are pulling on the
|
389
|
+
* content. We do not want scrolling to
|
390
|
+
* happen at the same time as the gesture.
|
391
|
+
*/
|
392
|
+
if (deltaY > 0 && contentEl) {
|
393
|
+
disableContentScrollY(contentEl);
|
394
|
+
}
|
395
|
+
animation.progressStart(true, isOpen ? 1 : 0);
|
396
|
+
};
|
397
|
+
const onMove = (detail) => {
|
398
|
+
const { deltaY } = detail;
|
399
|
+
/**
|
400
|
+
* If we are pulling down, then
|
401
|
+
* it is possible we are pulling on the
|
402
|
+
* content. We do not want scrolling to
|
403
|
+
* happen at the same time as the gesture.
|
404
|
+
*/
|
405
|
+
if (deltaY > 0 && contentEl) {
|
406
|
+
disableContentScrollY(contentEl);
|
407
|
+
}
|
408
|
+
/**
|
409
|
+
* If we are swiping on the content
|
410
|
+
* then the swipe gesture should only
|
411
|
+
* happen if we are pulling down.
|
412
|
+
*
|
413
|
+
* However, if we pull up and
|
414
|
+
* then down such that the scroll position
|
415
|
+
* returns to 0, we should be able to swipe
|
416
|
+
* the card.
|
417
|
+
*/
|
418
|
+
const step = detail.deltaY / height;
|
419
|
+
/**
|
420
|
+
* Check if user is swiping down and
|
421
|
+
* if we have a canDismiss value that
|
422
|
+
* should block the gesture from
|
423
|
+
* proceeding,
|
424
|
+
*/
|
425
|
+
const isAttempingDismissWithCanDismiss = step >= 0 && canDismissBlocksGesture;
|
426
|
+
/**
|
427
|
+
* If we are blocking the gesture from dismissing,
|
428
|
+
* set the max step value so that the sheet cannot be
|
429
|
+
* completely hidden.
|
430
|
+
*/
|
431
|
+
const maxStep = isAttempingDismissWithCanDismiss ? canDismissMaxStep : 0.9999;
|
432
|
+
/**
|
433
|
+
* If we are blocking the gesture from
|
434
|
+
* dismissing, calculate the spring modifier value
|
435
|
+
* this will be added to the starting breakpoint
|
436
|
+
* value to give the gesture a spring-like feeling.
|
437
|
+
* Note that the starting breakpoint is always 0,
|
438
|
+
* so we omit adding 0 to the result.
|
439
|
+
*/
|
440
|
+
const processedStep = isAttempingDismissWithCanDismiss ? calculateSpringStep(step / maxStep) : step;
|
441
|
+
const clampedStep = clamp(0.0001, processedStep, maxStep);
|
442
|
+
animation.progressStep(clampedStep);
|
443
|
+
/**
|
444
|
+
* When swiping down half way, the status bar style
|
445
|
+
* should be reset to its default value.
|
446
|
+
*
|
447
|
+
* We track lastStep so that we do not fire these
|
448
|
+
* functions on every onMove, only when the user has
|
449
|
+
* crossed a certain threshold.
|
450
|
+
*/
|
451
|
+
if (clampedStep >= DISMISS_THRESHOLD && lastStep < DISMISS_THRESHOLD) {
|
452
|
+
setCardStatusBarDefault();
|
453
|
+
/**
|
454
|
+
* However, if we swipe back up, then the
|
455
|
+
* status bar style should be set to have light
|
456
|
+
* text on a dark background.
|
457
|
+
*/
|
458
|
+
}
|
459
|
+
else if (clampedStep < DISMISS_THRESHOLD && lastStep >= DISMISS_THRESHOLD) {
|
460
|
+
setCardStatusBarDark();
|
461
|
+
}
|
462
|
+
lastStep = clampedStep;
|
463
|
+
};
|
464
|
+
const onEnd = (detail) => {
|
465
|
+
const velocity = detail.velocityY;
|
466
|
+
const step = detail.deltaY / height;
|
467
|
+
const isAttempingDismissWithCanDismiss = step >= 0 && canDismissBlocksGesture;
|
468
|
+
const maxStep = isAttempingDismissWithCanDismiss ? canDismissMaxStep : 0.9999;
|
469
|
+
const processedStep = isAttempingDismissWithCanDismiss ? calculateSpringStep(step / maxStep) : step;
|
470
|
+
const clampedStep = clamp(0.0001, processedStep, maxStep);
|
471
|
+
const threshold = (detail.deltaY + velocity * 1000) / height;
|
472
|
+
/**
|
473
|
+
* If canDismiss blocks
|
474
|
+
* the swipe gesture, then the
|
475
|
+
* animation can never complete until
|
476
|
+
* canDismiss is checked.
|
477
|
+
*/
|
478
|
+
const shouldComplete = !isAttempingDismissWithCanDismiss && threshold >= DISMISS_THRESHOLD;
|
479
|
+
let newStepValue = shouldComplete ? -0.001 : 0.001;
|
480
|
+
if (!shouldComplete) {
|
481
|
+
animation.easing('cubic-bezier(1, 0, 0.68, 0.28)');
|
482
|
+
newStepValue += getTimeGivenProgression([0, 0], [1, 0], [0.68, 0.28], [1, 1], clampedStep)[0];
|
483
|
+
}
|
484
|
+
else {
|
485
|
+
animation.easing('cubic-bezier(0.32, 0.72, 0, 1)');
|
486
|
+
newStepValue += getTimeGivenProgression([0, 0], [0.32, 0.72], [0, 1], [1, 1], clampedStep)[0];
|
487
|
+
}
|
488
|
+
const duration = shouldComplete
|
489
|
+
? computeDuration(step * height, velocity)
|
490
|
+
: computeDuration((1 - clampedStep) * height, velocity);
|
491
|
+
isOpen = shouldComplete;
|
492
|
+
gesture.enable(false);
|
493
|
+
if (contentEl) {
|
494
|
+
resetContentScrollY(contentEl, initialScrollY);
|
495
|
+
}
|
496
|
+
animation
|
497
|
+
.onFinish(() => {
|
498
|
+
if (!shouldComplete) {
|
499
|
+
gesture.enable(true);
|
500
|
+
}
|
501
|
+
})
|
502
|
+
.progressEnd(shouldComplete ? 1 : 0, newStepValue, duration);
|
503
|
+
/**
|
504
|
+
* If the canDismiss value blocked the gesture
|
505
|
+
* from proceeding, then we should ignore whatever
|
506
|
+
* shouldComplete is. Whether or not the modal
|
507
|
+
* animation should complete is now determined by
|
508
|
+
* canDismiss.
|
509
|
+
*
|
510
|
+
* If the user swiped >25% of the way
|
511
|
+
* to the max step, then we should
|
512
|
+
* check canDismiss. 25% was chosen
|
513
|
+
* to avoid accidental swipes.
|
514
|
+
*/
|
515
|
+
if (isAttempingDismissWithCanDismiss && clampedStep > maxStep / 4) {
|
516
|
+
handleCanDismiss(el, animation);
|
517
|
+
}
|
518
|
+
else if (shouldComplete) {
|
519
|
+
onDismiss();
|
520
|
+
}
|
521
|
+
};
|
522
|
+
const gesture = createGesture({
|
523
|
+
el,
|
524
|
+
gestureName: 'modalSwipeToClose',
|
525
|
+
gesturePriority: 39,
|
526
|
+
direction: 'y',
|
527
|
+
threshold: 10,
|
528
|
+
canStart,
|
529
|
+
onStart,
|
530
|
+
onMove,
|
531
|
+
onEnd,
|
532
|
+
});
|
533
|
+
return gesture;
|
534
|
+
};
|
535
|
+
const computeDuration = (remaining, velocity) => {
|
536
|
+
return clamp(400, remaining / Math.abs(velocity * 1.1), 500);
|
537
|
+
};
|
538
|
+
|
539
|
+
/*!
|
540
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
541
|
+
*/
|
542
|
+
const createSheetEnterAnimation = (opts) => {
|
543
|
+
const { currentBreakpoint, backdropBreakpoint } = opts;
|
544
|
+
/**
|
545
|
+
* If the backdropBreakpoint is undefined, then the backdrop
|
546
|
+
* should always fade in. If the backdropBreakpoint came before the
|
547
|
+
* current breakpoint, then the backdrop should be fading in.
|
548
|
+
*/
|
549
|
+
const shouldShowBackdrop = backdropBreakpoint === undefined || backdropBreakpoint < currentBreakpoint;
|
550
|
+
const initialBackdrop = shouldShowBackdrop ? `calc(var(--backdrop-opacity) * ${currentBreakpoint})` : '0';
|
551
|
+
const backdropAnimation = createAnimation('backdropAnimation').fromTo('opacity', 0, initialBackdrop);
|
552
|
+
if (shouldShowBackdrop) {
|
553
|
+
backdropAnimation
|
554
|
+
.beforeStyles({
|
555
|
+
'pointer-events': 'none',
|
556
|
+
})
|
557
|
+
.afterClearStyles(['pointer-events']);
|
558
|
+
}
|
559
|
+
const wrapperAnimation = createAnimation('wrapperAnimation').keyframes([
|
560
|
+
{ offset: 0, opacity: 1, transform: 'translateY(100%)' },
|
561
|
+
{ offset: 1, opacity: 1, transform: `translateY(${100 - currentBreakpoint * 100}%)` },
|
562
|
+
]);
|
563
|
+
return { wrapperAnimation, backdropAnimation };
|
564
|
+
};
|
565
|
+
const createSheetLeaveAnimation = (opts) => {
|
566
|
+
const { currentBreakpoint, backdropBreakpoint } = opts;
|
567
|
+
/**
|
568
|
+
* Backdrop does not always fade in from 0 to 1 if backdropBreakpoint
|
569
|
+
* is defined, so we need to account for that offset by figuring out
|
570
|
+
* what the current backdrop value should be.
|
571
|
+
*/
|
572
|
+
const backdropValue = `calc(var(--backdrop-opacity) * ${getBackdropValueForSheet(currentBreakpoint, backdropBreakpoint)})`;
|
573
|
+
const defaultBackdrop = [
|
574
|
+
{ offset: 0, opacity: backdropValue },
|
575
|
+
{ offset: 1, opacity: 0 },
|
576
|
+
];
|
577
|
+
const customBackdrop = [
|
578
|
+
{ offset: 0, opacity: backdropValue },
|
579
|
+
{ offset: backdropBreakpoint, opacity: 0 },
|
580
|
+
{ offset: 1, opacity: 0 },
|
581
|
+
];
|
582
|
+
const backdropAnimation = createAnimation('backdropAnimation').keyframes(backdropBreakpoint !== 0 ? customBackdrop : defaultBackdrop);
|
583
|
+
const wrapperAnimation = createAnimation('wrapperAnimation').keyframes([
|
584
|
+
{ offset: 0, opacity: 1, transform: `translateY(${100 - currentBreakpoint * 100}%)` },
|
585
|
+
{ offset: 1, opacity: 1, transform: `translateY(100%)` },
|
586
|
+
]);
|
587
|
+
return { wrapperAnimation, backdropAnimation };
|
588
|
+
};
|
589
|
+
|
590
|
+
/*!
|
591
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
592
|
+
*/
|
593
|
+
const createEnterAnimation$1 = () => {
|
594
|
+
const backdropAnimation = createAnimation()
|
595
|
+
.fromTo('opacity', 0.01, 'var(--backdrop-opacity)')
|
596
|
+
.beforeStyles({
|
597
|
+
'pointer-events': 'none',
|
598
|
+
})
|
599
|
+
.afterClearStyles(['pointer-events']);
|
600
|
+
const wrapperAnimation = createAnimation().fromTo('transform', 'translateY(100vh)', 'translateY(0vh)');
|
601
|
+
return { backdropAnimation, wrapperAnimation };
|
602
|
+
};
|
603
|
+
/**
|
604
|
+
* iOS Modal Enter Animation for the Card presentation style
|
605
|
+
*/
|
606
|
+
const iosEnterAnimation = (baseEl, opts) => {
|
607
|
+
const { presentingEl, currentBreakpoint } = opts;
|
608
|
+
const root = getElementRoot(baseEl);
|
609
|
+
const { wrapperAnimation, backdropAnimation } = currentBreakpoint !== undefined ? createSheetEnterAnimation(opts) : createEnterAnimation$1();
|
610
|
+
backdropAnimation.addElement(root.querySelector('ion-backdrop'));
|
611
|
+
wrapperAnimation.addElement(root.querySelectorAll('.modal-wrapper, .modal-shadow')).beforeStyles({ opacity: 1 });
|
612
|
+
const baseAnimation = createAnimation('entering-base')
|
613
|
+
.addElement(baseEl)
|
614
|
+
.easing('cubic-bezier(0.32,0.72,0,1)')
|
615
|
+
.duration(500)
|
616
|
+
.addAnimation(wrapperAnimation);
|
617
|
+
if (presentingEl) {
|
618
|
+
const isMobile = window.innerWidth < 768;
|
619
|
+
const hasCardModal = presentingEl.tagName === 'ION-MODAL' && presentingEl.presentingElement !== undefined;
|
620
|
+
const presentingElRoot = getElementRoot(presentingEl);
|
621
|
+
const presentingAnimation = createAnimation().beforeStyles({
|
622
|
+
transform: 'translateY(0)',
|
623
|
+
'transform-origin': 'top center',
|
624
|
+
overflow: 'hidden',
|
625
|
+
});
|
626
|
+
const bodyEl = document.body;
|
627
|
+
if (isMobile) {
|
628
|
+
/**
|
629
|
+
* Fallback for browsers that does not support `max()` (ex: Firefox)
|
630
|
+
* No need to worry about statusbar padding since engines like Gecko
|
631
|
+
* are not used as the engine for standalone Cordova/Capacitor apps
|
632
|
+
*/
|
633
|
+
const transformOffset = !CSS.supports('width', 'max(0px, 1px)') ? '30px' : 'max(30px, var(--ion-safe-area-top))';
|
634
|
+
const modalTransform = hasCardModal ? '-10px' : transformOffset;
|
635
|
+
const toPresentingScale = SwipeToCloseDefaults.MIN_PRESENTING_SCALE;
|
636
|
+
const finalTransform = `translateY(${modalTransform}) scale(${toPresentingScale})`;
|
637
|
+
presentingAnimation
|
638
|
+
.afterStyles({
|
639
|
+
transform: finalTransform,
|
640
|
+
})
|
641
|
+
.beforeAddWrite(() => bodyEl.style.setProperty('background-color', 'black'))
|
642
|
+
.addElement(presentingEl)
|
643
|
+
.keyframes([
|
644
|
+
{ offset: 0, filter: 'contrast(1)', transform: 'translateY(0px) scale(1)', borderRadius: '0px' },
|
645
|
+
{ offset: 1, filter: 'contrast(0.85)', transform: finalTransform, borderRadius: '10px 10px 0 0' },
|
646
|
+
]);
|
647
|
+
baseAnimation.addAnimation(presentingAnimation);
|
648
|
+
}
|
649
|
+
else {
|
650
|
+
baseAnimation.addAnimation(backdropAnimation);
|
651
|
+
if (!hasCardModal) {
|
652
|
+
wrapperAnimation.fromTo('opacity', '0', '1');
|
653
|
+
}
|
654
|
+
else {
|
655
|
+
const toPresentingScale = hasCardModal ? SwipeToCloseDefaults.MIN_PRESENTING_SCALE : 1;
|
656
|
+
const finalTransform = `translateY(-10px) scale(${toPresentingScale})`;
|
657
|
+
presentingAnimation
|
658
|
+
.afterStyles({
|
659
|
+
transform: finalTransform,
|
660
|
+
})
|
661
|
+
.addElement(presentingElRoot.querySelector('.modal-wrapper'))
|
662
|
+
.keyframes([
|
663
|
+
{ offset: 0, filter: 'contrast(1)', transform: 'translateY(0) scale(1)' },
|
664
|
+
{ offset: 1, filter: 'contrast(0.85)', transform: finalTransform },
|
665
|
+
]);
|
666
|
+
const shadowAnimation = createAnimation()
|
667
|
+
.afterStyles({
|
668
|
+
transform: finalTransform,
|
669
|
+
})
|
670
|
+
.addElement(presentingElRoot.querySelector('.modal-shadow'))
|
671
|
+
.keyframes([
|
672
|
+
{ offset: 0, opacity: '1', transform: 'translateY(0) scale(1)' },
|
673
|
+
{ offset: 1, opacity: '0', transform: finalTransform },
|
674
|
+
]);
|
675
|
+
baseAnimation.addAnimation([presentingAnimation, shadowAnimation]);
|
676
|
+
}
|
677
|
+
}
|
678
|
+
}
|
679
|
+
else {
|
680
|
+
baseAnimation.addAnimation(backdropAnimation);
|
681
|
+
}
|
682
|
+
return baseAnimation;
|
683
|
+
};
|
684
|
+
|
685
|
+
/*!
|
686
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
687
|
+
*/
|
688
|
+
const createLeaveAnimation$1 = () => {
|
689
|
+
const backdropAnimation = createAnimation().fromTo('opacity', 'var(--backdrop-opacity)', 0);
|
690
|
+
const wrapperAnimation = createAnimation().fromTo('transform', 'translateY(0vh)', 'translateY(100vh)');
|
691
|
+
return { backdropAnimation, wrapperAnimation };
|
692
|
+
};
|
693
|
+
/**
|
694
|
+
* iOS Modal Leave Animation
|
695
|
+
*/
|
696
|
+
const iosLeaveAnimation = (baseEl, opts, duration = 500) => {
|
697
|
+
const { presentingEl, currentBreakpoint } = opts;
|
698
|
+
const root = getElementRoot(baseEl);
|
699
|
+
const { wrapperAnimation, backdropAnimation } = currentBreakpoint !== undefined ? createSheetLeaveAnimation(opts) : createLeaveAnimation$1();
|
700
|
+
backdropAnimation.addElement(root.querySelector('ion-backdrop'));
|
701
|
+
wrapperAnimation.addElement(root.querySelectorAll('.modal-wrapper, .modal-shadow')).beforeStyles({ opacity: 1 });
|
702
|
+
const baseAnimation = createAnimation('leaving-base')
|
703
|
+
.addElement(baseEl)
|
704
|
+
.easing('cubic-bezier(0.32,0.72,0,1)')
|
705
|
+
.duration(duration)
|
706
|
+
.addAnimation(wrapperAnimation);
|
707
|
+
if (presentingEl) {
|
708
|
+
const isMobile = window.innerWidth < 768;
|
709
|
+
const hasCardModal = presentingEl.tagName === 'ION-MODAL' && presentingEl.presentingElement !== undefined;
|
710
|
+
const presentingElRoot = getElementRoot(presentingEl);
|
711
|
+
const presentingAnimation = createAnimation()
|
712
|
+
.beforeClearStyles(['transform'])
|
713
|
+
.afterClearStyles(['transform'])
|
714
|
+
.onFinish((currentStep) => {
|
715
|
+
// only reset background color if this is the last card-style modal
|
716
|
+
if (currentStep !== 1) {
|
717
|
+
return;
|
718
|
+
}
|
719
|
+
presentingEl.style.setProperty('overflow', '');
|
720
|
+
const numModals = Array.from(bodyEl.querySelectorAll('ion-modal')).filter((m) => m.presentingElement !== undefined).length;
|
721
|
+
if (numModals <= 1) {
|
722
|
+
bodyEl.style.setProperty('background-color', '');
|
723
|
+
}
|
724
|
+
});
|
725
|
+
const bodyEl = document.body;
|
726
|
+
if (isMobile) {
|
727
|
+
const transformOffset = !CSS.supports('width', 'max(0px, 1px)') ? '30px' : 'max(30px, var(--ion-safe-area-top))';
|
728
|
+
const modalTransform = hasCardModal ? '-10px' : transformOffset;
|
729
|
+
const toPresentingScale = SwipeToCloseDefaults.MIN_PRESENTING_SCALE;
|
730
|
+
const finalTransform = `translateY(${modalTransform}) scale(${toPresentingScale})`;
|
731
|
+
presentingAnimation.addElement(presentingEl).keyframes([
|
732
|
+
{ offset: 0, filter: 'contrast(0.85)', transform: finalTransform, borderRadius: '10px 10px 0 0' },
|
733
|
+
{ offset: 1, filter: 'contrast(1)', transform: 'translateY(0px) scale(1)', borderRadius: '0px' },
|
734
|
+
]);
|
735
|
+
baseAnimation.addAnimation(presentingAnimation);
|
736
|
+
}
|
737
|
+
else {
|
738
|
+
baseAnimation.addAnimation(backdropAnimation);
|
739
|
+
if (!hasCardModal) {
|
740
|
+
wrapperAnimation.fromTo('opacity', '1', '0');
|
741
|
+
}
|
742
|
+
else {
|
743
|
+
const toPresentingScale = hasCardModal ? SwipeToCloseDefaults.MIN_PRESENTING_SCALE : 1;
|
744
|
+
const finalTransform = `translateY(-10px) scale(${toPresentingScale})`;
|
745
|
+
presentingAnimation
|
746
|
+
.addElement(presentingElRoot.querySelector('.modal-wrapper'))
|
747
|
+
.afterStyles({
|
748
|
+
transform: 'translate3d(0, 0, 0)',
|
749
|
+
})
|
750
|
+
.keyframes([
|
751
|
+
{ offset: 0, filter: 'contrast(0.85)', transform: finalTransform },
|
752
|
+
{ offset: 1, filter: 'contrast(1)', transform: 'translateY(0) scale(1)' },
|
753
|
+
]);
|
754
|
+
const shadowAnimation = createAnimation()
|
755
|
+
.addElement(presentingElRoot.querySelector('.modal-shadow'))
|
756
|
+
.afterStyles({
|
757
|
+
transform: 'translateY(0) scale(1)',
|
758
|
+
})
|
759
|
+
.keyframes([
|
760
|
+
{ offset: 0, opacity: '0', transform: finalTransform },
|
761
|
+
{ offset: 1, opacity: '1', transform: 'translateY(0) scale(1)' },
|
762
|
+
]);
|
763
|
+
baseAnimation.addAnimation([presentingAnimation, shadowAnimation]);
|
764
|
+
}
|
765
|
+
}
|
766
|
+
}
|
767
|
+
else {
|
768
|
+
baseAnimation.addAnimation(backdropAnimation);
|
769
|
+
}
|
770
|
+
return baseAnimation;
|
771
|
+
};
|
772
|
+
|
773
|
+
/*!
|
774
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
775
|
+
*/
|
776
|
+
const createEnterAnimation = () => {
|
777
|
+
const backdropAnimation = createAnimation()
|
778
|
+
.fromTo('opacity', 0.01, 'var(--backdrop-opacity)')
|
779
|
+
.beforeStyles({
|
780
|
+
'pointer-events': 'none',
|
781
|
+
})
|
782
|
+
.afterClearStyles(['pointer-events']);
|
783
|
+
const wrapperAnimation = createAnimation().keyframes([
|
784
|
+
{ offset: 0, opacity: 0.01, transform: 'translateY(40px)' },
|
785
|
+
{ offset: 1, opacity: 1, transform: `translateY(0px)` },
|
786
|
+
]);
|
787
|
+
return { backdropAnimation, wrapperAnimation };
|
788
|
+
};
|
789
|
+
/**
|
790
|
+
* Md Modal Enter Animation
|
791
|
+
*/
|
792
|
+
const mdEnterAnimation = (baseEl, opts) => {
|
793
|
+
const { currentBreakpoint } = opts;
|
794
|
+
const root = getElementRoot(baseEl);
|
795
|
+
const { wrapperAnimation, backdropAnimation } = currentBreakpoint !== undefined ? createSheetEnterAnimation(opts) : createEnterAnimation();
|
796
|
+
backdropAnimation.addElement(root.querySelector('ion-backdrop'));
|
797
|
+
wrapperAnimation.addElement(root.querySelector('.modal-wrapper'));
|
798
|
+
return createAnimation()
|
799
|
+
.addElement(baseEl)
|
800
|
+
.easing('cubic-bezier(0.36,0.66,0.04,1)')
|
801
|
+
.duration(280)
|
802
|
+
.addAnimation([backdropAnimation, wrapperAnimation]);
|
803
|
+
};
|
804
|
+
|
805
|
+
/*!
|
806
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
807
|
+
*/
|
808
|
+
const createLeaveAnimation = () => {
|
809
|
+
const backdropAnimation = createAnimation().fromTo('opacity', 'var(--backdrop-opacity)', 0);
|
810
|
+
const wrapperAnimation = createAnimation().keyframes([
|
811
|
+
{ offset: 0, opacity: 0.99, transform: `translateY(0px)` },
|
812
|
+
{ offset: 1, opacity: 0, transform: 'translateY(40px)' },
|
813
|
+
]);
|
814
|
+
return { backdropAnimation, wrapperAnimation };
|
815
|
+
};
|
816
|
+
/**
|
817
|
+
* Md Modal Leave Animation
|
818
|
+
*/
|
819
|
+
const mdLeaveAnimation = (baseEl, opts) => {
|
820
|
+
const { currentBreakpoint } = opts;
|
821
|
+
const root = getElementRoot(baseEl);
|
822
|
+
const { wrapperAnimation, backdropAnimation } = currentBreakpoint !== undefined ? createSheetLeaveAnimation(opts) : createLeaveAnimation();
|
823
|
+
backdropAnimation.addElement(root.querySelector('ion-backdrop'));
|
824
|
+
wrapperAnimation.addElement(root.querySelector('.modal-wrapper'));
|
825
|
+
return createAnimation()
|
826
|
+
.easing('cubic-bezier(0.47,0,0.745,0.715)')
|
827
|
+
.duration(200)
|
828
|
+
.addAnimation([backdropAnimation, wrapperAnimation]);
|
829
|
+
};
|
830
|
+
|
831
|
+
/*!
|
832
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
833
|
+
*/
|
834
|
+
const createSheetGesture = (baseEl, backdropEl, wrapperEl, initialBreakpoint, backdropBreakpoint, animation, breakpoints = [], getCurrentBreakpoint, onDismiss, onBreakpointChange) => {
|
835
|
+
// Defaults for the sheet swipe animation
|
836
|
+
const defaultBackdrop = [
|
837
|
+
{ offset: 0, opacity: 'var(--backdrop-opacity)' },
|
838
|
+
{ offset: 1, opacity: 0.01 },
|
839
|
+
];
|
840
|
+
const customBackdrop = [
|
841
|
+
{ offset: 0, opacity: 'var(--backdrop-opacity)' },
|
842
|
+
{ offset: 1 - backdropBreakpoint, opacity: 0 },
|
843
|
+
{ offset: 1, opacity: 0 },
|
844
|
+
];
|
845
|
+
const SheetDefaults = {
|
846
|
+
WRAPPER_KEYFRAMES: [
|
847
|
+
{ offset: 0, transform: 'translateY(0%)' },
|
848
|
+
{ offset: 1, transform: 'translateY(100%)' },
|
849
|
+
],
|
850
|
+
BACKDROP_KEYFRAMES: backdropBreakpoint !== 0 ? customBackdrop : defaultBackdrop,
|
851
|
+
};
|
852
|
+
const contentEl = baseEl.querySelector('ion-content');
|
853
|
+
const height = wrapperEl.clientHeight;
|
854
|
+
let currentBreakpoint = initialBreakpoint;
|
855
|
+
let offset = 0;
|
856
|
+
let canDismissBlocksGesture = false;
|
857
|
+
const canDismissMaxStep = 0.95;
|
858
|
+
const wrapperAnimation = animation.childAnimations.find((ani) => ani.id === 'wrapperAnimation');
|
859
|
+
const backdropAnimation = animation.childAnimations.find((ani) => ani.id === 'backdropAnimation');
|
860
|
+
const maxBreakpoint = breakpoints[breakpoints.length - 1];
|
861
|
+
const minBreakpoint = breakpoints[0];
|
862
|
+
const enableBackdrop = () => {
|
863
|
+
baseEl.style.setProperty('pointer-events', 'auto');
|
864
|
+
backdropEl.style.setProperty('pointer-events', 'auto');
|
865
|
+
/**
|
866
|
+
* When the backdrop is enabled, elements such
|
867
|
+
* as inputs should not be focusable outside
|
868
|
+
* the sheet.
|
869
|
+
*/
|
870
|
+
baseEl.classList.remove('ion-disable-focus-trap');
|
871
|
+
};
|
872
|
+
const disableBackdrop = () => {
|
873
|
+
baseEl.style.setProperty('pointer-events', 'none');
|
874
|
+
backdropEl.style.setProperty('pointer-events', 'none');
|
875
|
+
/**
|
876
|
+
* When the backdrop is enabled, elements such
|
877
|
+
* as inputs should not be focusable outside
|
878
|
+
* the sheet.
|
879
|
+
* Adding this class disables focus trapping
|
880
|
+
* for the sheet temporarily.
|
881
|
+
*/
|
882
|
+
baseEl.classList.add('ion-disable-focus-trap');
|
883
|
+
};
|
884
|
+
/**
|
885
|
+
* After the entering animation completes,
|
886
|
+
* we need to set the animation to go from
|
887
|
+
* offset 0 to offset 1 so that users can
|
888
|
+
* swipe in any direction. We then set the
|
889
|
+
* animation offset to the current breakpoint
|
890
|
+
* so there is no flickering.
|
891
|
+
*/
|
892
|
+
if (wrapperAnimation && backdropAnimation) {
|
893
|
+
wrapperAnimation.keyframes([...SheetDefaults.WRAPPER_KEYFRAMES]);
|
894
|
+
backdropAnimation.keyframes([...SheetDefaults.BACKDROP_KEYFRAMES]);
|
895
|
+
animation.progressStart(true, 1 - currentBreakpoint);
|
896
|
+
/**
|
897
|
+
* If backdrop is not enabled, then content
|
898
|
+
* behind modal should be clickable. To do this, we need
|
899
|
+
* to remove pointer-events from ion-modal as a whole.
|
900
|
+
* ion-backdrop and .modal-wrapper always have pointer-events: auto
|
901
|
+
* applied, so the modal content can still be interacted with.
|
902
|
+
*/
|
903
|
+
const shouldEnableBackdrop = currentBreakpoint > backdropBreakpoint;
|
904
|
+
if (shouldEnableBackdrop) {
|
905
|
+
enableBackdrop();
|
906
|
+
}
|
907
|
+
else {
|
908
|
+
disableBackdrop();
|
909
|
+
}
|
910
|
+
}
|
911
|
+
if (contentEl && currentBreakpoint !== maxBreakpoint) {
|
912
|
+
contentEl.scrollY = false;
|
913
|
+
}
|
914
|
+
const canStart = (detail) => {
|
915
|
+
/**
|
916
|
+
* If the sheet is fully expanded and
|
917
|
+
* the user is swiping on the content,
|
918
|
+
* the gesture should not start to
|
919
|
+
* allow for scrolling on the content.
|
920
|
+
*/
|
921
|
+
const content = detail.event.target.closest('ion-content');
|
922
|
+
currentBreakpoint = getCurrentBreakpoint();
|
923
|
+
if (currentBreakpoint === 1 && content) {
|
924
|
+
return false;
|
925
|
+
}
|
926
|
+
return true;
|
927
|
+
};
|
928
|
+
const onStart = () => {
|
929
|
+
/**
|
930
|
+
* If canDismiss is anything other than `true`
|
931
|
+
* then users should be able to swipe down
|
932
|
+
* until a threshold is hit. At that point,
|
933
|
+
* the card modal should not proceed any further.
|
934
|
+
*
|
935
|
+
* canDismiss is never fired via gesture if there is
|
936
|
+
* no 0 breakpoint. However, it can be fired if the user
|
937
|
+
* presses Esc or the hardware back button.
|
938
|
+
* TODO (FW-937)
|
939
|
+
* Remove undefined check
|
940
|
+
*/
|
941
|
+
canDismissBlocksGesture = baseEl.canDismiss !== undefined && baseEl.canDismiss !== true && minBreakpoint === 0;
|
942
|
+
/**
|
943
|
+
* If swiping on the content
|
944
|
+
* we should disable scrolling otherwise
|
945
|
+
* the sheet will expand and the content will scroll.
|
946
|
+
*/
|
947
|
+
if (contentEl) {
|
948
|
+
contentEl.scrollY = false;
|
949
|
+
}
|
950
|
+
raf(() => {
|
951
|
+
/**
|
952
|
+
* Dismisses the open keyboard when the sheet drag gesture is started.
|
953
|
+
* Sets the focus onto the modal element.
|
954
|
+
*/
|
955
|
+
baseEl.focus();
|
956
|
+
});
|
957
|
+
animation.progressStart(true, 1 - currentBreakpoint);
|
958
|
+
};
|
959
|
+
const onMove = (detail) => {
|
960
|
+
/**
|
961
|
+
* Given the change in gesture position on the Y axis,
|
962
|
+
* compute where the offset of the animation should be
|
963
|
+
* relative to where the user dragged.
|
964
|
+
*/
|
965
|
+
const initialStep = 1 - currentBreakpoint;
|
966
|
+
const secondToLastBreakpoint = breakpoints.length > 1 ? 1 - breakpoints[1] : undefined;
|
967
|
+
const step = initialStep + detail.deltaY / height;
|
968
|
+
const isAttemptingDismissWithCanDismiss = secondToLastBreakpoint !== undefined && step >= secondToLastBreakpoint && canDismissBlocksGesture;
|
969
|
+
/**
|
970
|
+
* If we are blocking the gesture from dismissing,
|
971
|
+
* set the max step value so that the sheet cannot be
|
972
|
+
* completely hidden.
|
973
|
+
*/
|
974
|
+
const maxStep = isAttemptingDismissWithCanDismiss ? canDismissMaxStep : 0.9999;
|
975
|
+
/**
|
976
|
+
* If we are blocking the gesture from
|
977
|
+
* dismissing, calculate the spring modifier value
|
978
|
+
* this will be added to the starting breakpoint
|
979
|
+
* value to give the gesture a spring-like feeling.
|
980
|
+
* Note that when isAttemptingDismissWithCanDismiss is true,
|
981
|
+
* the modifier is always added to the breakpoint that
|
982
|
+
* appears right after the 0 breakpoint.
|
983
|
+
*
|
984
|
+
* Note that this modifier is essentially the progression
|
985
|
+
* between secondToLastBreakpoint and maxStep which is
|
986
|
+
* why we subtract secondToLastBreakpoint. This lets us get
|
987
|
+
* the result as a value from 0 to 1.
|
988
|
+
*/
|
989
|
+
const processedStep = isAttemptingDismissWithCanDismiss && secondToLastBreakpoint !== undefined
|
990
|
+
? secondToLastBreakpoint +
|
991
|
+
calculateSpringStep((step - secondToLastBreakpoint) / (maxStep - secondToLastBreakpoint))
|
992
|
+
: step;
|
993
|
+
offset = clamp(0.0001, processedStep, maxStep);
|
994
|
+
animation.progressStep(offset);
|
995
|
+
};
|
996
|
+
const onEnd = (detail) => {
|
997
|
+
/**
|
998
|
+
* When the gesture releases, we need to determine
|
999
|
+
* the closest breakpoint to snap to.
|
1000
|
+
*/
|
1001
|
+
const velocity = detail.velocityY;
|
1002
|
+
const threshold = (detail.deltaY + velocity * 100) / height;
|
1003
|
+
const diff = currentBreakpoint - threshold;
|
1004
|
+
const closest = breakpoints.reduce((a, b) => {
|
1005
|
+
return Math.abs(b - diff) < Math.abs(a - diff) ? b : a;
|
1006
|
+
});
|
1007
|
+
moveSheetToBreakpoint({
|
1008
|
+
breakpoint: closest,
|
1009
|
+
breakpointOffset: offset,
|
1010
|
+
canDismiss: canDismissBlocksGesture,
|
1011
|
+
});
|
1012
|
+
};
|
1013
|
+
const moveSheetToBreakpoint = (options) => {
|
1014
|
+
const { breakpoint, canDismiss, breakpointOffset } = options;
|
1015
|
+
/**
|
1016
|
+
* canDismiss should only prevent snapping
|
1017
|
+
* when users are trying to dismiss. If canDismiss
|
1018
|
+
* is present but the user is trying to swipe upwards,
|
1019
|
+
* we should allow that to happen,
|
1020
|
+
*/
|
1021
|
+
const shouldPreventDismiss = canDismiss && breakpoint === 0;
|
1022
|
+
const snapToBreakpoint = shouldPreventDismiss ? currentBreakpoint : breakpoint;
|
1023
|
+
const shouldRemainOpen = snapToBreakpoint !== 0;
|
1024
|
+
currentBreakpoint = 0;
|
1025
|
+
/**
|
1026
|
+
* Update the animation so that it plays from
|
1027
|
+
* the last offset to the closest snap point.
|
1028
|
+
*/
|
1029
|
+
if (wrapperAnimation && backdropAnimation) {
|
1030
|
+
wrapperAnimation.keyframes([
|
1031
|
+
{ offset: 0, transform: `translateY(${breakpointOffset * 100}%)` },
|
1032
|
+
{ offset: 1, transform: `translateY(${(1 - snapToBreakpoint) * 100}%)` },
|
1033
|
+
]);
|
1034
|
+
backdropAnimation.keyframes([
|
1035
|
+
{
|
1036
|
+
offset: 0,
|
1037
|
+
opacity: `calc(var(--backdrop-opacity) * ${getBackdropValueForSheet(1 - breakpointOffset, backdropBreakpoint)})`,
|
1038
|
+
},
|
1039
|
+
{
|
1040
|
+
offset: 1,
|
1041
|
+
opacity: `calc(var(--backdrop-opacity) * ${getBackdropValueForSheet(snapToBreakpoint, backdropBreakpoint)})`,
|
1042
|
+
},
|
1043
|
+
]);
|
1044
|
+
animation.progressStep(0);
|
1045
|
+
}
|
1046
|
+
/**
|
1047
|
+
* Gesture should remain disabled until the
|
1048
|
+
* snapping animation completes.
|
1049
|
+
*/
|
1050
|
+
gesture.enable(false);
|
1051
|
+
if (shouldPreventDismiss) {
|
1052
|
+
handleCanDismiss(baseEl, animation);
|
1053
|
+
}
|
1054
|
+
else if (!shouldRemainOpen) {
|
1055
|
+
onDismiss();
|
1056
|
+
}
|
1057
|
+
return new Promise((resolve) => {
|
1058
|
+
animation
|
1059
|
+
.onFinish(() => {
|
1060
|
+
if (shouldRemainOpen) {
|
1061
|
+
/**
|
1062
|
+
* Once the snapping animation completes,
|
1063
|
+
* we need to reset the animation to go
|
1064
|
+
* from 0 to 1 so users can swipe in any direction.
|
1065
|
+
* We then set the animation offset to the current
|
1066
|
+
* breakpoint so that it starts at the snapped position.
|
1067
|
+
*/
|
1068
|
+
if (wrapperAnimation && backdropAnimation) {
|
1069
|
+
raf(() => {
|
1070
|
+
wrapperAnimation.keyframes([...SheetDefaults.WRAPPER_KEYFRAMES]);
|
1071
|
+
backdropAnimation.keyframes([...SheetDefaults.BACKDROP_KEYFRAMES]);
|
1072
|
+
animation.progressStart(true, 1 - snapToBreakpoint);
|
1073
|
+
currentBreakpoint = snapToBreakpoint;
|
1074
|
+
onBreakpointChange(currentBreakpoint);
|
1075
|
+
/**
|
1076
|
+
* If the sheet is fully expanded, we can safely
|
1077
|
+
* enable scrolling again.
|
1078
|
+
*/
|
1079
|
+
if (contentEl && currentBreakpoint === breakpoints[breakpoints.length - 1]) {
|
1080
|
+
contentEl.scrollY = true;
|
1081
|
+
}
|
1082
|
+
/**
|
1083
|
+
* Backdrop should become enabled
|
1084
|
+
* after the backdropBreakpoint value
|
1085
|
+
*/
|
1086
|
+
const shouldEnableBackdrop = currentBreakpoint > backdropBreakpoint;
|
1087
|
+
if (shouldEnableBackdrop) {
|
1088
|
+
enableBackdrop();
|
1089
|
+
}
|
1090
|
+
else {
|
1091
|
+
disableBackdrop();
|
1092
|
+
}
|
1093
|
+
gesture.enable(true);
|
1094
|
+
resolve();
|
1095
|
+
});
|
1096
|
+
}
|
1097
|
+
else {
|
1098
|
+
gesture.enable(true);
|
1099
|
+
resolve();
|
1100
|
+
}
|
1101
|
+
}
|
1102
|
+
else {
|
1103
|
+
resolve();
|
1104
|
+
}
|
1105
|
+
/**
|
1106
|
+
* This must be a one time callback
|
1107
|
+
* otherwise a new callback will
|
1108
|
+
* be added every time onEnd runs.
|
1109
|
+
*/
|
1110
|
+
}, { oneTimeCallback: true })
|
1111
|
+
.progressEnd(1, 0, 500);
|
1112
|
+
});
|
1113
|
+
};
|
1114
|
+
const gesture = createGesture({
|
1115
|
+
el: wrapperEl,
|
1116
|
+
gestureName: 'modalSheet',
|
1117
|
+
gesturePriority: 40,
|
1118
|
+
direction: 'y',
|
1119
|
+
threshold: 10,
|
1120
|
+
canStart,
|
1121
|
+
onStart,
|
1122
|
+
onMove,
|
1123
|
+
onEnd,
|
1124
|
+
});
|
1125
|
+
return {
|
1126
|
+
gesture,
|
1127
|
+
moveSheetToBreakpoint,
|
1128
|
+
};
|
1129
|
+
};
|
1130
|
+
|
1131
|
+
const modalIosCss = ":host{--width:100%;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:auto;--overflow:hidden;--border-radius:0;--border-width:0;--border-style:none;--border-color:transparent;--background:var(--ion-background-color, #fff);--box-shadow:none;--backdrop-opacity:0;left:0;right:0;top:0;bottom:0;display:flex;position:absolute;align-items:center;justify-content:center;outline:none;contain:strict}.modal-wrapper,ion-backdrop{pointer-events:auto}:host(.overlay-hidden){display:none}.modal-wrapper,.modal-shadow{border-radius:var(--border-radius);width:var(--width);min-width:var(--min-width);max-width:var(--max-width);height:var(--height);min-height:var(--min-height);max-height:var(--max-height);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);background:var(--background);box-shadow:var(--box-shadow);overflow:var(--overflow);z-index:10}.modal-shadow{position:absolute;background:transparent}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--width:600px;--height:500px;--ion-safe-area-top:0px;--ion-safe-area-bottom:0px;--ion-safe-area-right:0px;--ion-safe-area-left:0px}}@media only screen and (min-width: 768px) and (min-height: 768px){:host{--width:600px;--height:600px}}.modal-handle{left:0px;right:0px;top:5px;border-radius:8px;margin-left:auto;margin-right:auto;position:absolute;width:36px;height:5px;transform:translateZ(0);border:0;background:var(--ion-color-step-350, #c0c0be);cursor:pointer;z-index:11}@supports (margin-inline-start: 0) or (-webkit-margin-start: 0){.modal-handle{margin-left:unset;margin-right:unset;-webkit-margin-start:auto;margin-inline-start:auto;-webkit-margin-end:auto;margin-inline-end:auto}}.modal-handle::before{padding-left:4px;padding-right:4px;padding-top:4px;padding-bottom:4px;position:absolute;width:36px;height:5px;transform:translate(-50%, -50%);content:\"\"}@supports (margin-inline-start: 0) or (-webkit-margin-start: 0){.modal-handle::before{padding-left:unset;padding-right:unset;-webkit-padding-start:4px;padding-inline-start:4px;-webkit-padding-end:4px;padding-inline-end:4px}}:host(.modal-sheet){--height:calc(100% - (var(--ion-safe-area-top) + 10px))}:host(.modal-sheet) .modal-wrapper,:host(.modal-sheet) .modal-shadow{position:absolute;bottom:0}:host{--backdrop-opacity:var(--ion-backdrop-opacity, 0.4)}:host(.modal-card),:host(.modal-sheet){--border-radius:10px}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--border-radius:10px}}.modal-wrapper{transform:translate3d(0, 100%, 0)}@media screen and (max-width: 767px){@supports (width: 1px){:host(.modal-card){--height:calc(100% - max(30px, var(--ion-safe-area-top)) - 10px)}}@supports not (width: 1px){:host(.modal-card){--height:calc(100% - 40px)}}:host(.modal-card) .modal-wrapper{border-top-left-radius:var(--border-radius);border-top-right-radius:var(--border-radius);border-bottom-right-radius:0;border-bottom-left-radius:0}:host-context([dir=rtl]):host(.modal-card) .modal-wrapper,:host-context([dir=rtl]).modal-card .modal-wrapper{border-top-left-radius:var(--border-radius);border-top-right-radius:var(--border-radius);border-bottom-right-radius:0;border-bottom-left-radius:0}:host(.modal-card){--backdrop-opacity:0;--width:100%;align-items:flex-end}:host(.modal-card) .modal-shadow{display:none}:host(.modal-card) ion-backdrop{pointer-events:none}}@media screen and (min-width: 768px){:host(.modal-card){--width:calc(100% - 120px);--height:calc(100% - (120px + var(--ion-safe-area-top) + var(--ion-safe-area-bottom)));--max-width:720px;--max-height:1000px;--backdrop-opacity:0;--box-shadow:0px 0px 30px 10px rgba(0, 0, 0, 0.1);transition:all 0.5s ease-in-out}:host(.modal-card) .modal-wrapper{box-shadow:none}:host(.modal-card) .modal-shadow{box-shadow:var(--box-shadow)}}:host(.modal-sheet) .modal-wrapper{border-top-left-radius:var(--border-radius);border-top-right-radius:var(--border-radius);border-bottom-right-radius:0;border-bottom-left-radius:0}:host-context([dir=rtl]):host(.modal-sheet) .modal-wrapper,:host-context([dir=rtl]).modal-sheet .modal-wrapper{border-top-left-radius:var(--border-radius);border-top-right-radius:var(--border-radius);border-bottom-right-radius:0;border-bottom-left-radius:0}";
|
1132
|
+
|
1133
|
+
const modalMdCss = ":host{--width:100%;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:auto;--overflow:hidden;--border-radius:0;--border-width:0;--border-style:none;--border-color:transparent;--background:var(--ion-background-color, #fff);--box-shadow:none;--backdrop-opacity:0;left:0;right:0;top:0;bottom:0;display:flex;position:absolute;align-items:center;justify-content:center;outline:none;contain:strict}.modal-wrapper,ion-backdrop{pointer-events:auto}:host(.overlay-hidden){display:none}.modal-wrapper,.modal-shadow{border-radius:var(--border-radius);width:var(--width);min-width:var(--min-width);max-width:var(--max-width);height:var(--height);min-height:var(--min-height);max-height:var(--max-height);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);background:var(--background);box-shadow:var(--box-shadow);overflow:var(--overflow);z-index:10}.modal-shadow{position:absolute;background:transparent}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--width:600px;--height:500px;--ion-safe-area-top:0px;--ion-safe-area-bottom:0px;--ion-safe-area-right:0px;--ion-safe-area-left:0px}}@media only screen and (min-width: 768px) and (min-height: 768px){:host{--width:600px;--height:600px}}.modal-handle{left:0px;right:0px;top:5px;border-radius:8px;margin-left:auto;margin-right:auto;position:absolute;width:36px;height:5px;transform:translateZ(0);border:0;background:var(--ion-color-step-350, #c0c0be);cursor:pointer;z-index:11}@supports (margin-inline-start: 0) or (-webkit-margin-start: 0){.modal-handle{margin-left:unset;margin-right:unset;-webkit-margin-start:auto;margin-inline-start:auto;-webkit-margin-end:auto;margin-inline-end:auto}}.modal-handle::before{padding-left:4px;padding-right:4px;padding-top:4px;padding-bottom:4px;position:absolute;width:36px;height:5px;transform:translate(-50%, -50%);content:\"\"}@supports (margin-inline-start: 0) or (-webkit-margin-start: 0){.modal-handle::before{padding-left:unset;padding-right:unset;-webkit-padding-start:4px;padding-inline-start:4px;-webkit-padding-end:4px;padding-inline-end:4px}}:host(.modal-sheet){--height:calc(100% - (var(--ion-safe-area-top) + 10px))}:host(.modal-sheet) .modal-wrapper,:host(.modal-sheet) .modal-shadow{position:absolute;bottom:0}:host{--backdrop-opacity:var(--ion-backdrop-opacity, 0.32)}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--border-radius:2px;--box-shadow:0 28px 48px rgba(0, 0, 0, 0.4)}}.modal-wrapper{transform:translate3d(0, 40px, 0);opacity:0.01}";
|
1134
|
+
|
1135
|
+
const Modal = class {
|
1136
|
+
constructor(hostRef) {
|
1137
|
+
registerInstance(this, hostRef);
|
1138
|
+
this.didPresent = createEvent(this, "ionModalDidPresent", 7);
|
1139
|
+
this.willPresent = createEvent(this, "ionModalWillPresent", 7);
|
1140
|
+
this.willDismiss = createEvent(this, "ionModalWillDismiss", 7);
|
1141
|
+
this.didDismiss = createEvent(this, "ionModalDidDismiss", 7);
|
1142
|
+
this.ionBreakpointDidChange = createEvent(this, "ionBreakpointDidChange", 7);
|
1143
|
+
this.didPresentShorthand = createEvent(this, "didPresent", 7);
|
1144
|
+
this.willPresentShorthand = createEvent(this, "willPresent", 7);
|
1145
|
+
this.willDismissShorthand = createEvent(this, "willDismiss", 7);
|
1146
|
+
this.didDismissShorthand = createEvent(this, "didDismiss", 7);
|
1147
|
+
this.modalIndex = modalIds++;
|
1148
|
+
this.coreDelegate = CoreDelegate();
|
1149
|
+
this.isSheetModal = false;
|
1150
|
+
this.inline = false;
|
1151
|
+
// Whether or not modal is being dismissed via gesture
|
1152
|
+
this.gestureAnimationDismissing = false;
|
1153
|
+
this.presented = false;
|
1154
|
+
/** @internal */
|
1155
|
+
this.hasController = false;
|
1156
|
+
/**
|
1157
|
+
* If `true`, the keyboard will be automatically dismissed when the overlay is presented.
|
1158
|
+
*/
|
1159
|
+
this.keyboardClose = true;
|
1160
|
+
/**
|
1161
|
+
* A decimal value between 0 and 1 that indicates the
|
1162
|
+
* point after which the backdrop will begin to fade in
|
1163
|
+
* when using a sheet modal. Prior to this point, the
|
1164
|
+
* backdrop will be hidden and the content underneath
|
1165
|
+
* the sheet can be interacted with. This value is exclusive
|
1166
|
+
* meaning the backdrop will become active after the value
|
1167
|
+
* specified.
|
1168
|
+
*/
|
1169
|
+
this.backdropBreakpoint = 0;
|
1170
|
+
/**
|
1171
|
+
* The interaction behavior for the sheet modal when the handle is pressed.
|
1172
|
+
*
|
1173
|
+
* Defaults to `"none"`, which means the modal will not change size or position when the handle is pressed.
|
1174
|
+
* Set to `"cycle"` to let the modal cycle between available breakpoints when pressed.
|
1175
|
+
*
|
1176
|
+
* Handle behavior is unavailable when the `handle` property is set to `false` or
|
1177
|
+
* when the `breakpoints` property is not set (using a fullscreen or card modal).
|
1178
|
+
*/
|
1179
|
+
this.handleBehavior = 'none';
|
1180
|
+
/**
|
1181
|
+
* If `true`, the modal will be dismissed when the backdrop is clicked.
|
1182
|
+
*/
|
1183
|
+
this.backdropDismiss = true;
|
1184
|
+
/**
|
1185
|
+
* If `true`, a backdrop will be displayed behind the modal.
|
1186
|
+
* This property controls whether or not the backdrop
|
1187
|
+
* darkens the screen when the modal is presented.
|
1188
|
+
* It does not control whether or not the backdrop
|
1189
|
+
* is active or present in the DOM.
|
1190
|
+
*/
|
1191
|
+
this.showBackdrop = true;
|
1192
|
+
/**
|
1193
|
+
* If `true`, the modal will animate.
|
1194
|
+
*/
|
1195
|
+
this.animated = true;
|
1196
|
+
/**
|
1197
|
+
* If `true`, the modal can be swiped to dismiss. Only applies in iOS mode.
|
1198
|
+
* @deprecated - To prevent modals from dismissing, use canDismiss instead.
|
1199
|
+
*/
|
1200
|
+
this.swipeToClose = false;
|
1201
|
+
/**
|
1202
|
+
* If `true`, the modal will open. If `false`, the modal will close.
|
1203
|
+
* Use this if you need finer grained control over presentation, otherwise
|
1204
|
+
* just use the modalController or the `trigger` property.
|
1205
|
+
* Note: `isOpen` will not automatically be set back to `false` when
|
1206
|
+
* the modal dismisses. You will need to do that in your code.
|
1207
|
+
*/
|
1208
|
+
this.isOpen = false;
|
1209
|
+
/**
|
1210
|
+
* If `true`, the component passed into `ion-modal` will
|
1211
|
+
* automatically be mounted when the modal is created. The
|
1212
|
+
* component will remain mounted even when the modal is dismissed.
|
1213
|
+
* However, the component will be destroyed when the modal is
|
1214
|
+
* destroyed. This property is not reactive and should only be
|
1215
|
+
* used when initially creating a modal.
|
1216
|
+
*
|
1217
|
+
* Note: This feature only applies to inline modals in JavaScript
|
1218
|
+
* frameworks such as Angular, React, and Vue.
|
1219
|
+
*/
|
1220
|
+
this.keepContentsMounted = false;
|
1221
|
+
this.configureTriggerInteraction = () => {
|
1222
|
+
const { trigger, el, destroyTriggerInteraction } = this;
|
1223
|
+
if (destroyTriggerInteraction) {
|
1224
|
+
destroyTriggerInteraction();
|
1225
|
+
}
|
1226
|
+
const triggerEl = trigger !== undefined ? document.getElementById(trigger) : null;
|
1227
|
+
if (!triggerEl) {
|
1228
|
+
return;
|
1229
|
+
}
|
1230
|
+
const configureTriggerInteraction = (trigEl, modalEl) => {
|
1231
|
+
const openModal = () => {
|
1232
|
+
modalEl.present();
|
1233
|
+
};
|
1234
|
+
trigEl.addEventListener('click', openModal);
|
1235
|
+
return () => {
|
1236
|
+
trigEl.removeEventListener('click', openModal);
|
1237
|
+
};
|
1238
|
+
};
|
1239
|
+
this.destroyTriggerInteraction = configureTriggerInteraction(triggerEl, el);
|
1240
|
+
};
|
1241
|
+
this.onHandleClick = () => {
|
1242
|
+
const { sheetTransition, handleBehavior } = this;
|
1243
|
+
if (handleBehavior !== 'cycle' || sheetTransition !== undefined) {
|
1244
|
+
/**
|
1245
|
+
* The sheet modal should not advance to the next breakpoint
|
1246
|
+
* if the handle behavior is not `cycle` or if the handle
|
1247
|
+
* is clicked while the sheet is moving to a breakpoint.
|
1248
|
+
*/
|
1249
|
+
return;
|
1250
|
+
}
|
1251
|
+
this.moveToNextBreakpoint();
|
1252
|
+
};
|
1253
|
+
this.onBackdropTap = () => {
|
1254
|
+
const { sheetTransition } = this;
|
1255
|
+
if (sheetTransition !== undefined) {
|
1256
|
+
/**
|
1257
|
+
* When the handle is double clicked at the largest breakpoint,
|
1258
|
+
* it will start to move to the first breakpoint. While transitioning,
|
1259
|
+
* the backdrop will often receive the second click. We prevent the
|
1260
|
+
* backdrop from dismissing the modal while moving between breakpoints.
|
1261
|
+
*/
|
1262
|
+
return;
|
1263
|
+
}
|
1264
|
+
this.dismiss(undefined, BACKDROP);
|
1265
|
+
};
|
1266
|
+
this.onLifecycle = (modalEvent) => {
|
1267
|
+
const el = this.usersElement;
|
1268
|
+
const name = LIFECYCLE_MAP[modalEvent.type];
|
1269
|
+
if (el && name) {
|
1270
|
+
const ev = new CustomEvent(name, {
|
1271
|
+
bubbles: false,
|
1272
|
+
cancelable: false,
|
1273
|
+
detail: modalEvent.detail,
|
1274
|
+
});
|
1275
|
+
el.dispatchEvent(ev);
|
1276
|
+
}
|
1277
|
+
};
|
1278
|
+
}
|
1279
|
+
onIsOpenChange(newValue, oldValue) {
|
1280
|
+
if (newValue === true && oldValue === false) {
|
1281
|
+
this.present();
|
1282
|
+
}
|
1283
|
+
else if (newValue === false && oldValue === true) {
|
1284
|
+
this.dismiss();
|
1285
|
+
}
|
1286
|
+
}
|
1287
|
+
onTriggerChange() {
|
1288
|
+
this.configureTriggerInteraction();
|
1289
|
+
}
|
1290
|
+
async swipeToCloseChanged(enable) {
|
1291
|
+
if (this.gesture) {
|
1292
|
+
this.gesture.enable(enable);
|
1293
|
+
}
|
1294
|
+
else if (enable) {
|
1295
|
+
await this.initSwipeToClose();
|
1296
|
+
}
|
1297
|
+
}
|
1298
|
+
breakpointsChanged(breakpoints) {
|
1299
|
+
if (breakpoints !== undefined) {
|
1300
|
+
this.sortedBreakpoints = breakpoints.sort((a, b) => a - b);
|
1301
|
+
}
|
1302
|
+
}
|
1303
|
+
connectedCallback() {
|
1304
|
+
prepareOverlay(this.el);
|
1305
|
+
}
|
1306
|
+
componentWillLoad() {
|
1307
|
+
const { breakpoints, initialBreakpoint, swipeToClose } = this;
|
1308
|
+
/**
|
1309
|
+
* If user has custom ID set then we should
|
1310
|
+
* not assign the default incrementing ID.
|
1311
|
+
*/
|
1312
|
+
this.modalId = this.el.hasAttribute('id') ? this.el.getAttribute('id') : `ion-modal-${this.modalIndex}`;
|
1313
|
+
const isSheetModal = (this.isSheetModal = breakpoints !== undefined && initialBreakpoint !== undefined);
|
1314
|
+
if (isSheetModal) {
|
1315
|
+
this.currentBreakpoint = this.initialBreakpoint;
|
1316
|
+
}
|
1317
|
+
if (breakpoints !== undefined && initialBreakpoint !== undefined && !breakpoints.includes(initialBreakpoint)) {
|
1318
|
+
printIonWarning('Your breakpoints array must include the initialBreakpoint value.');
|
1319
|
+
}
|
1320
|
+
if (swipeToClose) {
|
1321
|
+
printIonWarning('swipeToClose has been deprecated in favor of canDismiss.\n\nIf you want a card modal to be swipeable, set canDismiss to `true`. In the next major release of Ionic, swipeToClose will be removed, and all card modals will be swipeable by default.');
|
1322
|
+
}
|
1323
|
+
}
|
1324
|
+
componentDidLoad() {
|
1325
|
+
/**
|
1326
|
+
* If modal was rendered with isOpen="true"
|
1327
|
+
* then we should open modal immediately.
|
1328
|
+
*/
|
1329
|
+
if (this.isOpen === true) {
|
1330
|
+
raf(() => this.present());
|
1331
|
+
}
|
1332
|
+
this.breakpointsChanged(this.breakpoints);
|
1333
|
+
this.configureTriggerInteraction();
|
1334
|
+
}
|
1335
|
+
/**
|
1336
|
+
* Determines whether or not an overlay
|
1337
|
+
* is being used inline or via a controller/JS
|
1338
|
+
* and returns the correct delegate.
|
1339
|
+
* By default, subsequent calls to getDelegate
|
1340
|
+
* will use a cached version of the delegate.
|
1341
|
+
* This is useful for calling dismiss after
|
1342
|
+
* present so that the correct delegate is given.
|
1343
|
+
*/
|
1344
|
+
getDelegate(force = false) {
|
1345
|
+
if (this.workingDelegate && !force) {
|
1346
|
+
return {
|
1347
|
+
delegate: this.workingDelegate,
|
1348
|
+
inline: this.inline,
|
1349
|
+
};
|
1350
|
+
}
|
1351
|
+
/**
|
1352
|
+
* If using overlay inline
|
1353
|
+
* we potentially need to use the coreDelegate
|
1354
|
+
* so that this works in vanilla JS apps.
|
1355
|
+
* If a developer has presented this component
|
1356
|
+
* via a controller, then we can assume
|
1357
|
+
* the component is already in the
|
1358
|
+
* correct place.
|
1359
|
+
*/
|
1360
|
+
const parentEl = this.el.parentNode;
|
1361
|
+
const inline = (this.inline = parentEl !== null && !this.hasController);
|
1362
|
+
const delegate = (this.workingDelegate = inline ? this.delegate || this.coreDelegate : this.delegate);
|
1363
|
+
return { inline, delegate };
|
1364
|
+
}
|
1365
|
+
/**
|
1366
|
+
* Determines whether or not the
|
1367
|
+
* modal is allowed to dismiss based
|
1368
|
+
* on the state of the canDismiss prop.
|
1369
|
+
*/
|
1370
|
+
async checkCanDismiss() {
|
1371
|
+
const { canDismiss } = this;
|
1372
|
+
/**
|
1373
|
+
* TODO (FW-937) - Remove the following check in
|
1374
|
+
* the next major release of Ionic.
|
1375
|
+
*/
|
1376
|
+
if (canDismiss === undefined) {
|
1377
|
+
return true;
|
1378
|
+
}
|
1379
|
+
if (typeof canDismiss === 'function') {
|
1380
|
+
return canDismiss();
|
1381
|
+
}
|
1382
|
+
return canDismiss;
|
1383
|
+
}
|
1384
|
+
/**
|
1385
|
+
* Present the modal overlay after it has been created.
|
1386
|
+
*/
|
1387
|
+
async present() {
|
1388
|
+
if (this.presented) {
|
1389
|
+
return;
|
1390
|
+
}
|
1391
|
+
/**
|
1392
|
+
* When using an inline modal
|
1393
|
+
* and dismissing a modal it is possible to
|
1394
|
+
* quickly present the modal while it is
|
1395
|
+
* dismissing. We need to await any current
|
1396
|
+
* transition to allow the dismiss to finish
|
1397
|
+
* before presenting again.
|
1398
|
+
*/
|
1399
|
+
if (this.currentTransition !== undefined) {
|
1400
|
+
await this.currentTransition;
|
1401
|
+
}
|
1402
|
+
/**
|
1403
|
+
* If the modal is presented multiple times (inline modals), we
|
1404
|
+
* need to reset the current breakpoint to the initial breakpoint.
|
1405
|
+
*/
|
1406
|
+
this.currentBreakpoint = this.initialBreakpoint;
|
1407
|
+
const data = Object.assign(Object.assign({}, this.componentProps), { modal: this.el });
|
1408
|
+
const { inline, delegate } = this.getDelegate(true);
|
1409
|
+
this.usersElement = await attachComponent(delegate, this.el, this.component, ['ion-page'], data, inline);
|
1410
|
+
await deepReady(this.usersElement);
|
1411
|
+
writeTask(() => this.el.classList.add('show-modal'));
|
1412
|
+
this.currentTransition = present(this, 'modalEnter', iosEnterAnimation, mdEnterAnimation, {
|
1413
|
+
presentingEl: this.presentingElement,
|
1414
|
+
currentBreakpoint: this.initialBreakpoint,
|
1415
|
+
backdropBreakpoint: this.backdropBreakpoint,
|
1416
|
+
});
|
1417
|
+
/**
|
1418
|
+
* TODO (FW-937) - In the next major release of Ionic, all card modals
|
1419
|
+
* will be swipeable by default. canDismiss will be used to determine if the
|
1420
|
+
* modal can be dismissed. This check should change to check the presence of
|
1421
|
+
* presentingElement instead.
|
1422
|
+
*
|
1423
|
+
* If we did not do this check, then not using swipeToClose would mean you could
|
1424
|
+
* not run canDismiss on swipe as there would be no swipe gesture created.
|
1425
|
+
*/
|
1426
|
+
const hasCardModal = this.swipeToClose || (this.canDismiss !== undefined && this.presentingElement !== undefined);
|
1427
|
+
/**
|
1428
|
+
* We need to change the status bar at the
|
1429
|
+
* start of the animation so that it completes
|
1430
|
+
* by the time the card animation is done.
|
1431
|
+
*/
|
1432
|
+
if (hasCardModal && getIonMode(this) === 'ios') {
|
1433
|
+
setCardStatusBarDark();
|
1434
|
+
}
|
1435
|
+
await this.currentTransition;
|
1436
|
+
if (this.isSheetModal) {
|
1437
|
+
this.initSheetGesture();
|
1438
|
+
}
|
1439
|
+
else if (hasCardModal) {
|
1440
|
+
await this.initSwipeToClose();
|
1441
|
+
}
|
1442
|
+
/* tslint:disable-next-line */
|
1443
|
+
if (typeof window !== 'undefined') {
|
1444
|
+
this.keyboardOpenCallback = () => {
|
1445
|
+
if (this.gesture) {
|
1446
|
+
/**
|
1447
|
+
* When the native keyboard is opened and the webview
|
1448
|
+
* is resized, the gesture implementation will become unresponsive
|
1449
|
+
* and enter a free-scroll mode.
|
1450
|
+
*
|
1451
|
+
* When the keyboard is opened, we disable the gesture for
|
1452
|
+
* a single frame and re-enable once the contents have repositioned
|
1453
|
+
* from the keyboard placement.
|
1454
|
+
*/
|
1455
|
+
this.gesture.enable(false);
|
1456
|
+
raf(() => {
|
1457
|
+
if (this.gesture) {
|
1458
|
+
this.gesture.enable(true);
|
1459
|
+
}
|
1460
|
+
});
|
1461
|
+
}
|
1462
|
+
};
|
1463
|
+
window.addEventListener(KEYBOARD_DID_OPEN, this.keyboardOpenCallback);
|
1464
|
+
}
|
1465
|
+
this.currentTransition = undefined;
|
1466
|
+
}
|
1467
|
+
initSwipeToClose() {
|
1468
|
+
if (getIonMode(this) !== 'ios') {
|
1469
|
+
return;
|
1470
|
+
}
|
1471
|
+
const { el } = this;
|
1472
|
+
// All of the elements needed for the swipe gesture
|
1473
|
+
// should be in the DOM and referenced by now, except
|
1474
|
+
// for the presenting el
|
1475
|
+
const animationBuilder = this.leaveAnimation || config.get('modalLeave', iosLeaveAnimation);
|
1476
|
+
const ani = (this.animation = animationBuilder(el, { presentingEl: this.presentingElement }));
|
1477
|
+
const contentEl = findIonContent(el);
|
1478
|
+
if (!contentEl) {
|
1479
|
+
printIonContentErrorMsg(el);
|
1480
|
+
return;
|
1481
|
+
}
|
1482
|
+
this.gesture = createSwipeToCloseGesture(el, ani, () => {
|
1483
|
+
/**
|
1484
|
+
* While the gesture animation is finishing
|
1485
|
+
* it is possible for a user to tap the backdrop.
|
1486
|
+
* This would result in the dismiss animation
|
1487
|
+
* being played again. Typically this is avoided
|
1488
|
+
* by setting `presented = false` on the overlay
|
1489
|
+
* component; however, we cannot do that here as
|
1490
|
+
* that would prevent the element from being
|
1491
|
+
* removed from the DOM.
|
1492
|
+
*/
|
1493
|
+
this.gestureAnimationDismissing = true;
|
1494
|
+
this.animation.onFinish(async () => {
|
1495
|
+
await this.dismiss(undefined, 'gesture');
|
1496
|
+
this.gestureAnimationDismissing = false;
|
1497
|
+
});
|
1498
|
+
});
|
1499
|
+
this.gesture.enable(true);
|
1500
|
+
}
|
1501
|
+
initSheetGesture() {
|
1502
|
+
const { wrapperEl, initialBreakpoint, backdropBreakpoint } = this;
|
1503
|
+
if (!wrapperEl || initialBreakpoint === undefined) {
|
1504
|
+
return;
|
1505
|
+
}
|
1506
|
+
const animationBuilder = this.enterAnimation || config.get('modalEnter', iosEnterAnimation);
|
1507
|
+
const ani = (this.animation = animationBuilder(this.el, {
|
1508
|
+
presentingEl: this.presentingElement,
|
1509
|
+
currentBreakpoint: initialBreakpoint,
|
1510
|
+
backdropBreakpoint,
|
1511
|
+
}));
|
1512
|
+
ani.progressStart(true, 1);
|
1513
|
+
const { gesture, moveSheetToBreakpoint } = createSheetGesture(this.el, this.backdropEl, wrapperEl, initialBreakpoint, backdropBreakpoint, ani, this.sortedBreakpoints, () => { var _a; return (_a = this.currentBreakpoint) !== null && _a !== void 0 ? _a : 0; }, () => this.sheetOnDismiss(), (breakpoint) => {
|
1514
|
+
if (this.currentBreakpoint !== breakpoint) {
|
1515
|
+
this.currentBreakpoint = breakpoint;
|
1516
|
+
this.ionBreakpointDidChange.emit({ breakpoint });
|
1517
|
+
}
|
1518
|
+
});
|
1519
|
+
this.gesture = gesture;
|
1520
|
+
this.moveSheetToBreakpoint = moveSheetToBreakpoint;
|
1521
|
+
this.gesture.enable(true);
|
1522
|
+
}
|
1523
|
+
sheetOnDismiss() {
|
1524
|
+
/**
|
1525
|
+
* While the gesture animation is finishing
|
1526
|
+
* it is possible for a user to tap the backdrop.
|
1527
|
+
* This would result in the dismiss animation
|
1528
|
+
* being played again. Typically this is avoided
|
1529
|
+
* by setting `presented = false` on the overlay
|
1530
|
+
* component; however, we cannot do that here as
|
1531
|
+
* that would prevent the element from being
|
1532
|
+
* removed from the DOM.
|
1533
|
+
*/
|
1534
|
+
this.gestureAnimationDismissing = true;
|
1535
|
+
this.animation.onFinish(async () => {
|
1536
|
+
this.currentBreakpoint = 0;
|
1537
|
+
this.ionBreakpointDidChange.emit({ breakpoint: this.currentBreakpoint });
|
1538
|
+
await this.dismiss(undefined, 'gesture');
|
1539
|
+
this.gestureAnimationDismissing = false;
|
1540
|
+
});
|
1541
|
+
}
|
1542
|
+
/**
|
1543
|
+
* Dismiss the modal overlay after it has been presented.
|
1544
|
+
*
|
1545
|
+
* @param data Any data to emit in the dismiss events.
|
1546
|
+
* @param role The role of the element that is dismissing the modal. For example, 'cancel' or 'backdrop'.
|
1547
|
+
*/
|
1548
|
+
async dismiss(data, role) {
|
1549
|
+
if (this.gestureAnimationDismissing && role !== 'gesture') {
|
1550
|
+
return false;
|
1551
|
+
}
|
1552
|
+
/**
|
1553
|
+
* If a canDismiss handler is responsible
|
1554
|
+
* for calling the dismiss method, we should
|
1555
|
+
* not run the canDismiss check again.
|
1556
|
+
*/
|
1557
|
+
if (role !== 'handler' && !(await this.checkCanDismiss())) {
|
1558
|
+
return false;
|
1559
|
+
}
|
1560
|
+
/**
|
1561
|
+
* We need to start the status bar change
|
1562
|
+
* before the animation so that the change
|
1563
|
+
* finishes when the dismiss animation does.
|
1564
|
+
* TODO (FW-937)
|
1565
|
+
*/
|
1566
|
+
const hasCardModal = this.swipeToClose || (this.canDismiss !== undefined && this.presentingElement !== undefined);
|
1567
|
+
if (hasCardModal && getIonMode(this) === 'ios') {
|
1568
|
+
setCardStatusBarDefault();
|
1569
|
+
}
|
1570
|
+
/* tslint:disable-next-line */
|
1571
|
+
if (typeof window !== 'undefined' && this.keyboardOpenCallback) {
|
1572
|
+
window.removeEventListener(KEYBOARD_DID_OPEN, this.keyboardOpenCallback);
|
1573
|
+
}
|
1574
|
+
/**
|
1575
|
+
* When using an inline modal
|
1576
|
+
* and presenting a modal it is possible to
|
1577
|
+
* quickly dismiss the modal while it is
|
1578
|
+
* presenting. We need to await any current
|
1579
|
+
* transition to allow the present to finish
|
1580
|
+
* before dismissing again.
|
1581
|
+
*/
|
1582
|
+
if (this.currentTransition !== undefined) {
|
1583
|
+
await this.currentTransition;
|
1584
|
+
}
|
1585
|
+
const enteringAnimation = activeAnimations.get(this) || [];
|
1586
|
+
this.currentTransition = dismiss(this, data, role, 'modalLeave', iosLeaveAnimation, mdLeaveAnimation, {
|
1587
|
+
presentingEl: this.presentingElement,
|
1588
|
+
currentBreakpoint: this.currentBreakpoint || this.initialBreakpoint,
|
1589
|
+
backdropBreakpoint: this.backdropBreakpoint,
|
1590
|
+
});
|
1591
|
+
const dismissed = await this.currentTransition;
|
1592
|
+
if (dismissed) {
|
1593
|
+
const { delegate } = this.getDelegate();
|
1594
|
+
await detachComponent(delegate, this.usersElement);
|
1595
|
+
writeTask(() => this.el.classList.remove('show-modal'));
|
1596
|
+
if (this.animation) {
|
1597
|
+
this.animation.destroy();
|
1598
|
+
}
|
1599
|
+
if (this.gesture) {
|
1600
|
+
this.gesture.destroy();
|
1601
|
+
}
|
1602
|
+
enteringAnimation.forEach((ani) => ani.destroy());
|
1603
|
+
}
|
1604
|
+
this.currentBreakpoint = undefined;
|
1605
|
+
this.currentTransition = undefined;
|
1606
|
+
this.animation = undefined;
|
1607
|
+
return dismissed;
|
1608
|
+
}
|
1609
|
+
/**
|
1610
|
+
* Returns a promise that resolves when the modal did dismiss.
|
1611
|
+
*/
|
1612
|
+
onDidDismiss() {
|
1613
|
+
return eventMethod(this.el, 'ionModalDidDismiss');
|
1614
|
+
}
|
1615
|
+
/**
|
1616
|
+
* Returns a promise that resolves when the modal will dismiss.
|
1617
|
+
*/
|
1618
|
+
onWillDismiss() {
|
1619
|
+
return eventMethod(this.el, 'ionModalWillDismiss');
|
1620
|
+
}
|
1621
|
+
/**
|
1622
|
+
* Move a sheet style modal to a specific breakpoint. The breakpoint value must
|
1623
|
+
* be a value defined in your `breakpoints` array.
|
1624
|
+
*/
|
1625
|
+
async setCurrentBreakpoint(breakpoint) {
|
1626
|
+
if (!this.isSheetModal) {
|
1627
|
+
printIonWarning('setCurrentBreakpoint is only supported on sheet modals.');
|
1628
|
+
return;
|
1629
|
+
}
|
1630
|
+
if (!this.breakpoints.includes(breakpoint)) {
|
1631
|
+
printIonWarning(`Attempted to set invalid breakpoint value ${breakpoint}. Please double check that the breakpoint value is part of your defined breakpoints.`);
|
1632
|
+
return;
|
1633
|
+
}
|
1634
|
+
const { currentBreakpoint, moveSheetToBreakpoint, canDismiss, breakpoints } = this;
|
1635
|
+
if (currentBreakpoint === breakpoint) {
|
1636
|
+
return;
|
1637
|
+
}
|
1638
|
+
if (moveSheetToBreakpoint) {
|
1639
|
+
this.sheetTransition = moveSheetToBreakpoint({
|
1640
|
+
breakpoint,
|
1641
|
+
breakpointOffset: 1 - currentBreakpoint,
|
1642
|
+
canDismiss: canDismiss !== undefined && canDismiss !== true && breakpoints[0] === 0,
|
1643
|
+
});
|
1644
|
+
await this.sheetTransition;
|
1645
|
+
this.sheetTransition = undefined;
|
1646
|
+
}
|
1647
|
+
}
|
1648
|
+
/**
|
1649
|
+
* Returns the current breakpoint of a sheet style modal
|
1650
|
+
*/
|
1651
|
+
async getCurrentBreakpoint() {
|
1652
|
+
return this.currentBreakpoint;
|
1653
|
+
}
|
1654
|
+
async moveToNextBreakpoint() {
|
1655
|
+
const { breakpoints, currentBreakpoint } = this;
|
1656
|
+
if (!breakpoints || currentBreakpoint == null) {
|
1657
|
+
/**
|
1658
|
+
* If the modal does not have breakpoints and/or the current
|
1659
|
+
* breakpoint is not set, we can't move to the next breakpoint.
|
1660
|
+
*/
|
1661
|
+
return false;
|
1662
|
+
}
|
1663
|
+
const allowedBreakpoints = breakpoints.filter((b) => b !== 0);
|
1664
|
+
const currentBreakpointIndex = allowedBreakpoints.indexOf(currentBreakpoint);
|
1665
|
+
const nextBreakpointIndex = (currentBreakpointIndex + 1) % allowedBreakpoints.length;
|
1666
|
+
const nextBreakpoint = allowedBreakpoints[nextBreakpointIndex];
|
1667
|
+
/**
|
1668
|
+
* Sets the current breakpoint to the next available breakpoint.
|
1669
|
+
* If the current breakpoint is the last breakpoint, we set the current
|
1670
|
+
* breakpoint to the first non-zero breakpoint to avoid dismissing the sheet.
|
1671
|
+
*/
|
1672
|
+
await this.setCurrentBreakpoint(nextBreakpoint);
|
1673
|
+
return true;
|
1674
|
+
}
|
1675
|
+
render() {
|
1676
|
+
const { handle, isSheetModal, presentingElement, htmlAttributes, handleBehavior } = this;
|
1677
|
+
const showHandle = handle !== false && isSheetModal;
|
1678
|
+
const mode = getIonMode(this);
|
1679
|
+
const { modalId } = this;
|
1680
|
+
const isCardModal = presentingElement !== undefined && mode === 'ios';
|
1681
|
+
const isHandleCycle = handleBehavior === 'cycle';
|
1682
|
+
return (h(Host, Object.assign({ "no-router": true, "aria-modal": "true", tabindex: "-1" }, htmlAttributes, { style: {
|
1683
|
+
zIndex: `${20000 + this.overlayIndex}`,
|
1684
|
+
}, class: Object.assign({ [mode]: true, ['modal-default']: !isCardModal && !isSheetModal, [`modal-card`]: isCardModal, [`modal-sheet`]: isSheetModal, 'overlay-hidden': true }, getClassMap(this.cssClass)), id: modalId, onIonBackdropTap: this.onBackdropTap, onIonModalDidPresent: this.onLifecycle, onIonModalWillPresent: this.onLifecycle, onIonModalWillDismiss: this.onLifecycle, onIonModalDidDismiss: this.onLifecycle }), h("ion-backdrop", { ref: (el) => (this.backdropEl = el), visible: this.showBackdrop, tappable: this.backdropDismiss, part: "backdrop" }), mode === 'ios' && h("div", { class: "modal-shadow" }), h("div", { role: "dialog", class: "modal-wrapper ion-overlay-wrapper", part: "content", ref: (el) => (this.wrapperEl = el) }, showHandle && (h("button", { class: "modal-handle",
|
1685
|
+
// Prevents the handle from receiving keyboard focus when it does not cycle
|
1686
|
+
tabIndex: !isHandleCycle ? -1 : 0, "aria-label": "Activate to adjust the size of the dialog overlaying the screen", onClick: isHandleCycle ? this.onHandleClick : undefined, part: "handle" })), h("slot", null))));
|
1687
|
+
}
|
1688
|
+
get el() { return getElement(this); }
|
1689
|
+
static get watchers() { return {
|
1690
|
+
"isOpen": ["onIsOpenChange"],
|
1691
|
+
"trigger": ["onTriggerChange"],
|
1692
|
+
"swipeToClose": ["swipeToCloseChanged"]
|
1693
|
+
}; }
|
1694
|
+
};
|
1695
|
+
const LIFECYCLE_MAP = {
|
1696
|
+
ionModalDidPresent: 'ionViewDidEnter',
|
1697
|
+
ionModalWillPresent: 'ionViewWillEnter',
|
1698
|
+
ionModalWillDismiss: 'ionViewWillLeave',
|
1699
|
+
ionModalDidDismiss: 'ionViewDidLeave',
|
1700
|
+
};
|
1701
|
+
let modalIds = 0;
|
1702
|
+
Modal.style = {
|
1703
|
+
ios: modalIosCss,
|
1704
|
+
md: modalMdCss
|
1705
|
+
};
|
1706
|
+
|
1707
|
+
export { Modal as ion_modal };
|