infinity-forge 2.4.2 → 2.4.3
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/sites/components/default-pages/blog/components/blog-item/index.d.ts +1 -1
- package/dist/sites/components/default-pages/blog/components/blog-item/index.js +3 -3
- package/dist/sites/components/default-pages/blog/components/blog-item/intefaces.d.ts +1 -1
- package/dist/sites/components/default-pages/blog/components/blog-item/share/index.js +2 -2
- package/dist/sites/components/default-pages/blog/components/featured-blog/featured-blog-item/index.d.ts +1 -1
- package/dist/sites/components/default-pages/blog/components/featured-blog/featured-blog-item/index.js +2 -2
- package/dist/sites/components/default-pages/blog/components/featured-blog/index.d.ts +1 -1
- package/dist/sites/components/default-pages/blog/components/featured-blog/index.js +2 -2
- package/dist/sites/components/default-pages/blog/components/featured-blog/interfaces.d.ts +2 -2
- package/dist/sites/components/default-pages/blog/components/side-box-categories/index.d.ts +2 -2
- package/dist/sites/components/default-pages/blog/components/side-box-categories/index.js +2 -2
- package/dist/sites/components/default-pages/blog/components/side-box-categories/interfaces.d.ts +1 -1
- package/dist/sites/components/default-pages/blog/components/side-box-newsletter/index.d.ts +1 -1
- package/dist/sites/components/default-pages/blog/components/side-box-newsletter/index.js +3 -3
- package/dist/sites/components/default-pages/blog/components/title-blog/index.js +2 -2
- package/dist/system/domain/protocols/http/errors/http-errors/index.d.ts +7 -7
- package/dist/system/domain/protocols/http/errors/http-errors/index.js +7 -7
- package/dist/system/domain/protocols/http/errors/system-errors-model/index.d.ts +1 -1
- package/dist/system/domain/protocols/http/errors/system-errors-model/index.js +1 -1
- package/dist/system/domain/use-cases/auth/admin/index.js +18 -0
- package/dist/system/presentation/components/data/avatar/index.js +59 -0
- package/dist/system/presentation/components/data/buttons/index.d.ts +1 -0
- package/dist/system/presentation/components/data/buttons/index.js +18 -0
- package/dist/system/presentation/components/data/buttons/sidebar-button/index.js +3 -3
- package/dist/system/presentation/components/data/chat/card-message/index.d.ts +1 -1
- package/dist/system/presentation/components/data/chat/card-message/index.js +3 -3
- package/dist/system/presentation/components/data/chat/index.d.ts +2 -0
- package/dist/system/presentation/components/data/chat/index.js +38 -0
- package/dist/system/presentation/components/data/chat/interfaces.d.ts +8 -0
- package/dist/system/presentation/components/data/chat/loader/index.js +1 -1
- package/dist/system/presentation/components/data/detail-card/component.d.ts +2 -0
- package/dist/system/presentation/components/data/detail-card/component.js +42 -0
- package/dist/system/presentation/components/data/detail-card/index.d.ts +2 -0
- package/dist/system/presentation/components/data/detail-card/index.js +19 -0
- package/dist/system/presentation/components/data/detail-card/interfaces.d.ts +19 -0
- package/dist/system/presentation/components/data/highlight-icon/index.d.ts +2 -0
- package/dist/system/presentation/components/data/highlight-icon/index.js +40 -0
- package/dist/system/presentation/components/data/highlight-icon/interfaces.d.ts +8 -0
- package/dist/system/presentation/components/data/highlight-text/index.d.ts +2 -0
- package/dist/system/presentation/components/data/highlight-text/index.js +43 -0
- package/dist/system/presentation/components/data/input-search/index.d.ts +2 -0
- package/dist/system/presentation/components/data/input-search/index.js +39 -0
- package/dist/system/presentation/components/data/logo/index.js +34 -0
- package/dist/system/presentation/components/data/menu/component.js +17 -0
- package/dist/system/presentation/components/data/menu/components/index.d.ts +1 -1
- package/dist/system/presentation/components/data/menu/components/index.js +1 -1
- package/dist/system/presentation/components/data/menu/components/menu-item/index.js +3 -3
- package/dist/system/presentation/components/data/menu/index.d.ts +2 -0
- package/dist/system/presentation/components/data/menu/index.js +19 -0
- package/dist/system/presentation/components/data/menu/modes/collapsed-menu/index.js +5 -5
- package/dist/system/presentation/components/data/menu/modes/collapsed-menu/styles.js +1 -1
- package/dist/system/presentation/components/data/menu/modes/index.d.ts +2 -2
- package/dist/system/presentation/components/data/menu/modes/index.js +2 -2
- package/dist/system/presentation/components/data/menu/modes/opened/index.js +3 -3
- package/dist/system/presentation/components/data/menu/modes/opened/styles.js +1 -1
- package/dist/system/presentation/components/data/notifications/card/index.d.ts +1 -1
- package/dist/system/presentation/components/data/notifications/card/index.js +2 -2
- package/dist/system/presentation/components/data/notifications/index.js +155 -0
- package/dist/system/presentation/components/data/page-wrapper/index.d.ts +2 -0
- package/dist/system/presentation/components/data/page-wrapper/index.js +35 -0
- package/dist/system/presentation/components/data/page-wrapper/interfaces.d.ts +7 -0
- package/dist/system/presentation/components/data/popover/index.d.ts +2 -0
- package/dist/system/presentation/components/data/profile-infos/index.d.ts +2 -0
- package/dist/system/presentation/components/data/profile-infos/index.js +48 -0
- package/dist/system/presentation/components/data/profile-infos/interfaces.d.ts +6 -0
- package/dist/system/presentation/components/data/profile-infos/profile/index.d.ts +1 -1
- package/dist/system/presentation/components/data/profile-infos/profile/index.js +3 -3
- package/dist/system/presentation/components/data/select-workspace/index.d.ts +4 -0
- package/dist/system/presentation/components/data/select-workspace/index.js +69 -0
- package/dist/system/presentation/components/data/tab/component.d.ts +2 -0
- package/dist/system/presentation/components/data/tab/component.js +67 -0
- package/dist/system/presentation/components/data/tab/index.d.ts +2 -0
- package/dist/system/presentation/components/data/tab/index.js +19 -0
- package/dist/system/presentation/components/data/tab/interfaces.d.ts +29 -0
- package/dist/system/presentation/components/data/tab/tab-item/index.d.ts +1 -1
- package/dist/system/presentation/components/data/tab/tab-item/index.js +2 -2
- package/dist/system/presentation/components/data/tab/tab-item/styles.d.ts +1 -1
- package/dist/system/presentation/components/layout/header/components/index.d.ts +2 -2
- package/dist/system/presentation/components/layout/header/components/index.js +2 -2
- package/dist/system/presentation/components/layout/header/components/menu-right/index.d.ts +1 -1
- package/dist/system/presentation/components/layout/header/components/menu-right/index.js +4 -4
- package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/card/index.d.ts +1 -1
- package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/card/index.js +4 -5
- package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/index.js +4 -4
- package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/interfaces.d.ts +1 -1
- package/dist/system/presentation/components/layout/header/components/menu-right/messages/index.js +5 -5
- package/dist/system/presentation/components/layout/header/components/menu-right/profile/content/index.js +4 -5
- package/dist/system/presentation/components/layout/header/components/menu-right/profile/index.js +5 -6
- package/dist/system/presentation/components/layout/header/components/menu-right/settings/index.js +4 -4
- package/dist/system/presentation/components/layout/header/components/search-modal/index.js +4 -4
- package/dist/system/presentation/components/layout/header/components/search-modal/search-list/index.js +4 -5
- package/dist/system/presentation/components/layout/header/components/search-modal/trigger/index.js +3 -3
- package/dist/system/presentation/components/layout/header/index.d.ts +2 -0
- package/dist/system/presentation/components/layout/header/index.js +25 -0
- package/dist/system/presentation/components/layout/header/version-01/index.d.ts +1 -1
- package/dist/system/presentation/components/layout/header/version-01/index.js +4 -4
- package/dist/system/presentation/components/pages/menus/index.d.ts +1 -0
- package/dist/system/presentation/components/pages/menus/index.js +18 -0
- package/dist/system/presentation/components/pages/menus/page.js +40 -0
- package/dist/system/presentation/components/pages/menus/table/columns.d.ts +2 -2
- package/dist/system/presentation/components/pages/menus/table/columns.js +1 -1
- package/dist/system/presentation/components/pages/menus/table/create.d.ts +2 -2
- package/dist/system/presentation/components/pages/menus/table/create.js +2 -2
- package/dist/system/presentation/components/pages/menus/table/delete.js +2 -2
- package/dist/system/presentation/components/pages/menus/table/edit.d.ts +2 -2
- package/dist/system/presentation/components/pages/menus/table/edit.js +2 -2
- package/dist/system/presentation/components/pages/menus/table/icon/index.js +1 -1
- package/dist/system/presentation/components/pages/menus/table/index.d.ts +4 -4
- package/dist/system/presentation/components/pages/menus/table/index.js +4 -4
- package/dist/system/presentation/components/pages/users/index.d.ts +1 -0
- package/dist/system/presentation/components/pages/users/index.js +18 -0
- package/dist/system/presentation/components/pages/users/page.js +40 -0
- package/dist/system/presentation/components/pages/users/table/columns.d.ts +2 -2
- package/dist/system/presentation/components/pages/users/table/create.d.ts +2 -2
- package/dist/system/presentation/components/pages/users/table/create.js +2 -2
- package/dist/system/presentation/components/pages/users/table/delete.js +2 -2
- package/dist/system/presentation/components/pages/users/table/edit.d.ts +2 -2
- package/dist/system/presentation/components/pages/users/table/edit.js +2 -2
- package/dist/system/presentation/components/pages/users/table/index.d.ts +4 -4
- package/dist/system/presentation/components/pages/users/table/index.js +4 -4
- package/dist/system/presentation/context/auth/components/index.d.ts +2 -0
- package/dist/system/presentation/context/auth/components/index.js +19 -0
- package/dist/system/presentation/context/auth/components/login/form-login/index.js +2 -2
- package/dist/system/presentation/context/auth/components/login/index.js +4 -4
- package/dist/system/presentation/context/auth/components/private-page/index.d.ts +1 -1
- package/dist/system/presentation/context/auth/components/private-page/index.js +3 -3
- package/dist/system/presentation/hooks/notifications/use-load-all/index.d.ts +1 -0
- package/dist/system/presentation/hooks/notifications/use-load-all/index.js +63 -0
- package/dist/system/presentation/hooks/notifications/use-load-no-read/index.d.ts +2 -0
- package/dist/system/presentation/hooks/notifications/use-load-no-read/index.js +60 -0
- package/dist/system/presentation/hooks/ui/use-table/component.d.ts +8 -0
- package/dist/system/presentation/hooks/ui/use-table/component.js +26 -0
- package/dist/system/presentation/hooks/ui/use-table/components/index.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/index.js +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/table/actions/index.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/table/actions/index.js +3 -3
- package/dist/system/presentation/hooks/ui/use-table/components/table/active-filters/index.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/table/active-filters/index.js +3 -3
- package/dist/system/presentation/hooks/ui/use-table/components/table/create/index.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/table/create/index.js +3 -3
- package/dist/system/presentation/hooks/ui/use-table/components/table/export/index.d.ts +2 -2
- package/dist/system/presentation/hooks/ui/use-table/components/table/export/index.js +3 -3
- package/dist/system/presentation/hooks/ui/use-table/components/table/filters/index.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/table/filters/index.js +4 -5
- package/dist/system/presentation/hooks/ui/use-table/components/table/index.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/table/index.js +10 -10
- package/dist/system/presentation/hooks/ui/use-table/components/table/interfaces.d.ts +2 -2
- package/dist/system/presentation/hooks/ui/use-table/components/table/pagination/index.d.ts +2 -2
- package/dist/system/presentation/hooks/ui/use-table/components/table/pagination/index.js +4 -4
- package/dist/system/presentation/hooks/ui/use-table/components/table/skeleton-table/index.js +3 -3
- package/dist/system/presentation/hooks/ui/use-table/components/table/thead-item/index.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/components/table/thead-item/index.js +3 -3
- package/dist/system/presentation/hooks/ui/use-table/components/table/thead-item/interfaces.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/index.d.ts +4 -0
- package/dist/system/presentation/hooks/ui/use-table/index.js +21 -0
- package/dist/system/presentation/hooks/ui/use-table/interfaces.d.ts +92 -0
- package/dist/system/presentation/hooks/ui/use-table/query/get-query-arguments-table.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/query/hook.d.ts +1 -1
- package/dist/system/presentation/hooks/ui/use-table/query/hook.js +1 -1
- package/dist/system/presentation/hooks/ui/use-table/query/index.d.ts +2 -2
- package/dist/system/presentation/hooks/ui/use-table/query/index.js +2 -2
- package/dist/ui/components/carousel/carousel-lib/components-shared/get-changed-params.js +51 -0
- package/dist/ui/components/carousel/carousel-lib/components-shared/get-element-params.js +148 -0
- package/dist/ui/components/carousel/carousel-lib/components-shared/get-params.js +61 -0
- package/dist/ui/components/carousel/carousel-lib/components-shared/mount-swiper.js +24 -0
- package/dist/ui/components/carousel/carousel-lib/components-shared/update-swiper.js +208 -0
- package/dist/ui/components/carousel/carousel-lib/core/breakpoints/getBreakpoint.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/breakpoints/index.d.ts +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/breakpoints/index.js +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/breakpoints/setBreakpoint.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/classes/index.d.ts +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/classes/index.js +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/core.js +654 -0
- package/dist/ui/components/carousel/carousel-lib/core/events/index.js +9 -9
- package/dist/ui/components/carousel/carousel-lib/core/events/onLoad.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/events/onTouchEnd.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/events/onTouchMove.js +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/events/onTouchStart.js +3 -3
- package/dist/ui/components/carousel/carousel-lib/core/grab-cursor/index.d.ts +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/grab-cursor/index.js +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/loop/index.d.ts +3 -3
- package/dist/ui/components/carousel/carousel-lib/core/loop/index.js +3 -3
- package/dist/ui/components/carousel/carousel-lib/core/loop/loopCreate.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/loop/loopFix.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/moduleExtendParams.js +42 -0
- package/dist/ui/components/carousel/carousel-lib/core/modules/observer/observer.js +2 -2
- package/dist/ui/components/carousel/carousel-lib/core/modules/resize/resize.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/slide/index.d.ts +7 -7
- package/dist/ui/components/carousel/carousel-lib/core/slide/index.js +7 -7
- package/dist/ui/components/carousel/carousel-lib/core/slide/slideTo.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/slide/slideToClickedSlide.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/transition/index.d.ts +3 -3
- package/dist/ui/components/carousel/carousel-lib/core/transition/index.js +3 -3
- package/dist/ui/components/carousel/carousel-lib/core/transition/transitionEnd.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/transition/transitionStart.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/translate/getTranslate.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/translate/index.d.ts +5 -5
- package/dist/ui/components/carousel/carousel-lib/core/translate/index.js +5 -5
- package/dist/ui/components/carousel/carousel-lib/core/translate/translateTo.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/update/index.d.ts +9 -9
- package/dist/ui/components/carousel/carousel-lib/core/update/index.js +9 -9
- package/dist/ui/components/carousel/carousel-lib/core/update/updateActiveIndex.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/update/updateSize.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/update/updateSlides.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/core/update/updateSlidesClasses.js +1 -1
- package/dist/ui/components/carousel/carousel-lib/modules/autoplay.js +336 -0
- package/dist/ui/components/carousel/carousel-lib/modules/effect-fade.js +63 -0
- package/dist/ui/components/carousel/carousel-lib/modules/free-mode.js +247 -0
- package/dist/ui/components/carousel/carousel-lib/modules/index.d.ts +6 -0
- package/dist/ui/components/carousel/carousel-lib/modules/index.js +23 -0
- package/dist/ui/components/carousel/carousel-lib/modules/navigation.js +223 -0
- package/dist/ui/components/carousel/carousel-lib/modules/pagination.js +514 -0
- package/dist/ui/components/carousel/carousel-lib/modules/virtual.js +379 -0
- package/dist/ui/components/carousel/carousel-lib/react/swiper-slide.js +88 -0
- package/dist/ui/components/carousel/carousel-lib/react/swiper.js +210 -0
- package/dist/ui/components/carousel/carousel-lib/shared/create-element-if-not-defined.js +22 -0
- package/dist/ui/components/carousel/carousel-lib/shared/create-shadow.js +15 -0
- package/dist/ui/components/carousel/carousel-lib/shared/effect-target.js +13 -0
- package/dist/ui/components/carousel/carousel-lib/shared/effect-virtual-transition-end.js +47 -0
- package/dist/ui/components/carousel/carousel-lib/shared/get-browser.js +43 -0
- package/dist/ui/components/carousel/carousel-lib/shared/get-device.js +69 -0
- package/dist/ui/components/carousel/carousel-lib/shared/get-support.js +25 -0
- package/dist/ui/components/carousel/carousel-lib/shared/utils.js +372 -0
- package/dist/ui/components/carousel/carousel-lib/ssr-window/document.js +65 -0
- package/dist/ui/components/carousel/carousel-lib/ssr-window/ssr-window.d.ts +4 -0
- package/dist/ui/components/carousel/carousel-lib/ssr-window/ssr-window.js +15 -0
- package/dist/ui/components/carousel/carousel-lib/ssr-window/window.js +71 -0
- package/dist/ui/components/carousel/carousel-lib/types/index.d.ts +5 -0
- package/dist/ui/components/carousel/carousel-lib/types/index.js +27 -0
- package/dist/ui/components/carousel/carousel-lib/types/swiper-events.d.ts +162 -0
- package/dist/ui/components/form/handler/custom-submit/index.d.ts +17 -0
- package/dist/ui/components/form/handler/custom-submit/index.js +25 -0
- package/dist/ui/components/form/handler/dynamic_form_handler/component.d.ts +2 -0
- package/dist/ui/components/form/handler/dynamic_form_handler/component.js +117 -0
- package/dist/ui/components/form/handler/dynamic_form_handler/index.d.ts +2 -0
- package/dist/ui/components/form/handler/dynamic_form_handler/index.js +19 -0
- package/dist/ui/components/form/handler/dynamic_form_handler/interfaces.d.ts +28 -0
- package/dist/ui/components/form/handler/form-handler/generate-schemas.js +111 -0
- package/dist/ui/components/form/handler/form-handler/index.d.ts +2 -0
- package/dist/ui/components/form/handler/form-handler/index.js +241 -0
- package/dist/ui/components/form/handler/form-handler/use-schemas.d.ts +2 -0
- package/dist/ui/components/form/handler/form-handler/use-schemas.js +115 -0
- package/dist/ui/components/form/handler/form-handler/use-send-file.d.ts +5 -0
- package/dist/ui/components/form/handler/form-handler/use-send-file.js +209 -0
- package/dist/ui/components/form/handler/i18n/capture-i18n-errors/index.d.ts +1 -1
- package/dist/ui/components/form/handler/i18n/index.d.ts +2 -0
- package/dist/ui/components/form/handler/i18n/index.js +4 -4
- package/dist/ui/components/form/input-cep/use-cep/hook.d.ts +2 -2
- package/dist/ui/components/form/input-cep/use-cep/hook.js +1 -1
- package/dist/ui/components/form/input-cep/use-cep/index.d.ts +2 -2
- package/dist/ui/components/form/input-cep/use-cep/index.js +2 -2
- package/dist/ui/components/form/input-cep/use-cep/providers/ibge/hook.d.ts +1 -1
- package/dist/ui/components/form/input-cep/use-cep/providers/ibge/hook.js +1 -1
- package/dist/ui/components/form/input-cep/use-cep/providers/ibge/index.d.ts +3 -3
- package/dist/ui/components/form/input-cep/use-cep/providers/ibge/index.js +3 -3
- package/dist/ui/components/form/input-cep/use-cep/providers/index.d.ts +1 -1
- package/dist/ui/components/form/input-cep/use-cep/providers/index.js +1 -1
- package/dist/ui/components/form/input-control/error/index.js +1 -1
- package/dist/ui/components/form/input-control/label/index.js +1 -1
- package/dist/ui/components/form/input-control/loader-input/index.js +2 -2
- package/dist/ui/components/form/input-currency/components/CurrencyInput.js +1 -1
- package/dist/ui/components/form/input-currency/components/index.d.ts +1 -1
- package/dist/ui/components/form/input-currency/components/index.js +1 -1
- package/dist/ui/components/form/input-currency/components/utils/cleanValue.d.ts +1 -1
- package/dist/ui/components/form/input-currency/components/utils/cleanValue.js +4 -4
- package/dist/ui/components/form/input-currency/components/utils/formatValue.d.ts +1 -1
- package/dist/ui/components/form/input-currency/components/utils/formatValue.js +2 -2
- package/dist/ui/components/form/input-currency/components/utils/getLocaleConfig.d.ts +1 -1
- package/dist/ui/components/form/input-currency/components/utils/getSuffix.js +1 -1
- package/dist/ui/components/form/input-currency/components/utils/index.d.ts +8 -8
- package/dist/ui/components/form/input-currency/components/utils/index.js +8 -8
- package/dist/ui/components/form/input-currency/components/utils/parseAbbrValue.js +1 -1
- package/dist/ui/components/form/input-currency/components/utils/removeInvalidChars.js +1 -1
- package/dist/ui/components/form/input-currency/components/utils/removeSeparators.js +1 -1
- package/dist/ui/components/form/input-date-picker/calendar/calendar-header/index.d.ts +1 -1
- package/dist/ui/components/form/input-date-picker/calendar/calendar-header/index.js +3 -3
- package/dist/ui/components/form/input-date-picker/calendar/days/index.d.ts +1 -1
- package/dist/ui/components/form/input-date-picker/calendar/days/index.js +2 -2
- package/dist/ui/components/form/input-date-picker/calendar/index.d.ts +1 -1
- package/dist/ui/components/form/input-date-picker/calendar/index.js +4 -4
- package/dist/ui/components/form/input-date-picker/calendar/interface.d.ts +2 -2
- package/dist/ui/components/form/input-date-picker/calendar/months/index.d.ts +1 -1
- package/dist/ui/components/form/input-date-picker/calendar/months/index.js +2 -2
- package/dist/ui/components/form/input-date-picker/calendar/styles.d.ts +1 -1
- package/dist/ui/components/form/input-date-picker/mock/index.d.ts +1 -1
- package/dist/ui/components/form/input-date-picker/mock/index.js +1 -1
- package/dist/ui/components/form/input-file/hooks/index.d.ts +4 -4
- package/dist/ui/components/form/input-file/hooks/index.js +4 -4
- package/dist/ui/components/form/input-file/hooks/use-components-file.d.ts +2 -2
- package/dist/ui/components/form/input-file/hooks/use-components-file.js +2 -2
- package/dist/ui/components/form/input-file/hooks/use-file-elements.d.ts +1 -1
- package/dist/ui/components/form/input-file/hooks/use-file-elements.js +2 -2
- package/dist/ui/components/form/input-file/hooks/use-file.d.ts +2 -2
- package/dist/ui/components/form/input-file/hooks/use-file.js +2 -2
- package/dist/ui/components/form/input-file/hooks/use-rendered-file.d.ts +1 -1
- package/dist/ui/components/form/input-file/hooks/use-rendered-file.js +1 -1
- package/dist/ui/components/form/input-file/render-files/component.d.ts +1 -1
- package/dist/ui/components/form/input-file/render-files/component.js +2 -2
- package/dist/ui/components/form/input-file/render-files/file-item/button-upload-image-mobile/index.d.ts +1 -1
- package/dist/ui/components/form/input-file/render-files/file-item/button-upload-image-mobile/index.js +1 -1
- package/dist/ui/components/form/input-file/render-files/file-item/index.d.ts +2 -2
- package/dist/ui/components/form/input-file/render-files/file-item/index.js +3 -3
- package/dist/ui/components/form/input-file/render-files/index.d.ts +3 -3
- package/dist/ui/components/form/input-file/render-files/index.js +3 -3
- package/dist/ui/components/form/input-file/render-files/interfaces.d.ts +2 -2
- package/dist/ui/components/form/input-mask/lib/core/errors/SyntheticChangeError.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/core/hooks/useInput.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/core/hooks/useInput.js +2 -2
- package/dist/ui/components/form/input-mask/lib/core/index.d.ts +5 -5
- package/dist/ui/components/form/input-mask/lib/core/index.js +4 -4
- package/dist/ui/components/form/input-mask/lib/core/utils/setInputAttributes.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/InputMask.d.ts +2 -2
- package/dist/ui/components/form/input-mask/lib/mask/InputMask.js +2 -2
- package/dist/ui/components/form/input-mask/lib/mask/index.d.ts +5 -5
- package/dist/ui/components/form/input-mask/lib/mask/index.js +3 -3
- package/dist/ui/components/form/input-mask/lib/mask/types.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/useMask.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/useMask.js +7 -7
- package/dist/ui/components/form/input-mask/lib/mask/utils/filter.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils/format.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils/formatToParts.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils/formatToReplacementObject.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils/resolveDetail.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils/resolveDetail.js +3 -3
- package/dist/ui/components/form/input-mask/lib/mask/utils/resolveSelection.d.ts +2 -2
- package/dist/ui/components/form/input-mask/lib/mask/utils/unformat.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils/validate.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/mask/utils.js +5 -5
- package/dist/ui/components/form/input-mask/lib/number-format/InputNumberFormat.d.ts +2 -2
- package/dist/ui/components/form/input-mask/lib/number-format/InputNumberFormat.js +2 -2
- package/dist/ui/components/form/input-mask/lib/number-format/index.d.ts +4 -4
- package/dist/ui/components/form/input-mask/lib/number-format/index.js +2 -2
- package/dist/ui/components/form/input-mask/lib/number-format/types.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/number-format/useNumberFormat.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/number-format/useNumberFormat.js +6 -6
- package/dist/ui/components/form/input-mask/lib/number-format/utils/localizeValues.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveDetail.d.ts +2 -2
- package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveDetail.js +1 -1
- package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveMinimumFractionDigits.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveOptions.d.ts +1 -1
- package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveSelection.d.ts +2 -2
- package/dist/ui/components/form/input-seo/input-meta-image/index.d.ts +1 -1
- package/dist/ui/components/form/input-seo/input-meta-image/index.js +2 -2
- package/dist/ui/components/menu-mobile/components/nav-links/index.d.ts +1 -1
- package/dist/ui/components/menu-mobile/components/nav-links/index.js +3 -3
- package/dist/ui/components/menu-mobile/components/nav-links/interfaces.d.ts +1 -1
- package/package.json +75 -75
|
@@ -0,0 +1,514 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
3
|
+
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
4
|
+
if (ar || !(i in from)) {
|
|
5
|
+
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
6
|
+
ar[i] = from[i];
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
10
|
+
};
|
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
exports.Pagination = void 0;
|
|
16
|
+
var classes_to_selector_1 = __importDefault(require("../shared/classes-to-selector.js"));
|
|
17
|
+
var create_element_if_not_defined_1 = __importDefault(require("../shared/create-element-if-not-defined.js"));
|
|
18
|
+
var utils_1 = require("../shared/utils.js");
|
|
19
|
+
function Pagination(_a) {
|
|
20
|
+
var swiper = _a.swiper, extendParams = _a.extendParams, on = _a.on, emit = _a.emit;
|
|
21
|
+
var pfx = 'swiper-pagination';
|
|
22
|
+
extendParams({
|
|
23
|
+
pagination: {
|
|
24
|
+
el: null,
|
|
25
|
+
bulletElement: 'span',
|
|
26
|
+
clickable: false,
|
|
27
|
+
hideOnClick: false,
|
|
28
|
+
renderBullet: null,
|
|
29
|
+
renderProgressbar: null,
|
|
30
|
+
renderFraction: null,
|
|
31
|
+
renderCustom: null,
|
|
32
|
+
progressbarOpposite: false,
|
|
33
|
+
type: 'bullets', // 'bullets' or 'progressbar' or 'fraction' or 'custom'
|
|
34
|
+
dynamicBullets: false,
|
|
35
|
+
dynamicMainBullets: 1,
|
|
36
|
+
formatFractionCurrent: function (number) { return number; },
|
|
37
|
+
formatFractionTotal: function (number) { return number; },
|
|
38
|
+
bulletClass: "".concat(pfx, "-bullet"),
|
|
39
|
+
bulletActiveClass: "".concat(pfx, "-bullet-active"),
|
|
40
|
+
modifierClass: "".concat(pfx, "-"),
|
|
41
|
+
currentClass: "".concat(pfx, "-current"),
|
|
42
|
+
totalClass: "".concat(pfx, "-total"),
|
|
43
|
+
hiddenClass: "".concat(pfx, "-hidden"),
|
|
44
|
+
progressbarFillClass: "".concat(pfx, "-progressbar-fill"),
|
|
45
|
+
progressbarOppositeClass: "".concat(pfx, "-progressbar-opposite"),
|
|
46
|
+
clickableClass: "".concat(pfx, "-clickable"),
|
|
47
|
+
lockClass: "".concat(pfx, "-lock"),
|
|
48
|
+
horizontalClass: "".concat(pfx, "-horizontal"),
|
|
49
|
+
verticalClass: "".concat(pfx, "-vertical"),
|
|
50
|
+
paginationDisabledClass: "".concat(pfx, "-disabled"),
|
|
51
|
+
},
|
|
52
|
+
});
|
|
53
|
+
swiper.pagination = {
|
|
54
|
+
el: null,
|
|
55
|
+
bullets: [],
|
|
56
|
+
};
|
|
57
|
+
var bulletSize;
|
|
58
|
+
var dynamicBulletIndex = 0;
|
|
59
|
+
function isPaginationDisabled() {
|
|
60
|
+
return (!swiper.params.pagination.el ||
|
|
61
|
+
!swiper.pagination.el ||
|
|
62
|
+
(Array.isArray(swiper.pagination.el) && swiper.pagination.el.length === 0));
|
|
63
|
+
}
|
|
64
|
+
function setSideBullets(bulletEl, position) {
|
|
65
|
+
var bulletActiveClass = swiper.params.pagination.bulletActiveClass;
|
|
66
|
+
if (!bulletEl)
|
|
67
|
+
return;
|
|
68
|
+
bulletEl = bulletEl["".concat(position === 'prev' ? 'previous' : 'next', "ElementSibling")];
|
|
69
|
+
if (bulletEl) {
|
|
70
|
+
bulletEl.classList.add("".concat(bulletActiveClass, "-").concat(position));
|
|
71
|
+
bulletEl = bulletEl["".concat(position === 'prev' ? 'previous' : 'next', "ElementSibling")];
|
|
72
|
+
if (bulletEl) {
|
|
73
|
+
bulletEl.classList.add("".concat(bulletActiveClass, "-").concat(position, "-").concat(position));
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
function onBulletClick(e) {
|
|
78
|
+
var bulletEl = e.target.closest((0, classes_to_selector_1.default)(swiper.params.pagination.bulletClass));
|
|
79
|
+
if (!bulletEl) {
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
e.preventDefault();
|
|
83
|
+
var index = (0, utils_1.elementIndex)(bulletEl) * swiper.params.slidesPerGroup;
|
|
84
|
+
if (swiper.params.loop) {
|
|
85
|
+
if (swiper.realIndex === index)
|
|
86
|
+
return;
|
|
87
|
+
swiper.slideToLoop(index);
|
|
88
|
+
}
|
|
89
|
+
else {
|
|
90
|
+
swiper.slideTo(index);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
function update() {
|
|
94
|
+
var _a, _b;
|
|
95
|
+
// Render || Update Pagination bullets/items
|
|
96
|
+
var rtl = swiper.rtl;
|
|
97
|
+
var params = swiper.params.pagination;
|
|
98
|
+
if (isPaginationDisabled())
|
|
99
|
+
return;
|
|
100
|
+
var el = swiper.pagination.el;
|
|
101
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
102
|
+
// Current/Total
|
|
103
|
+
var current;
|
|
104
|
+
var previousIndex;
|
|
105
|
+
var slidesLength = swiper.virtual && swiper.params.virtual.enabled
|
|
106
|
+
? swiper.virtual.slides.length
|
|
107
|
+
: swiper.slides.length;
|
|
108
|
+
var total = swiper.params.loop
|
|
109
|
+
? Math.ceil(slidesLength / swiper.params.slidesPerGroup)
|
|
110
|
+
: swiper.snapGrid.length;
|
|
111
|
+
if (swiper.params.loop) {
|
|
112
|
+
previousIndex = swiper.previousRealIndex || 0;
|
|
113
|
+
current =
|
|
114
|
+
swiper.params.slidesPerGroup > 1
|
|
115
|
+
? Math.floor(swiper.realIndex / swiper.params.slidesPerGroup)
|
|
116
|
+
: swiper.realIndex;
|
|
117
|
+
}
|
|
118
|
+
else if (typeof swiper.snapIndex !== 'undefined') {
|
|
119
|
+
current = swiper.snapIndex;
|
|
120
|
+
previousIndex = swiper.previousSnapIndex;
|
|
121
|
+
}
|
|
122
|
+
else {
|
|
123
|
+
previousIndex = swiper.previousIndex || 0;
|
|
124
|
+
current = swiper.activeIndex || 0;
|
|
125
|
+
}
|
|
126
|
+
// Types
|
|
127
|
+
if (params.type === 'bullets' &&
|
|
128
|
+
swiper.pagination.bullets &&
|
|
129
|
+
swiper.pagination.bullets.length > 0) {
|
|
130
|
+
var bullets = swiper.pagination.bullets;
|
|
131
|
+
var firstIndex_1;
|
|
132
|
+
var lastIndex_1;
|
|
133
|
+
var midIndex = void 0;
|
|
134
|
+
if (params.dynamicBullets) {
|
|
135
|
+
bulletSize = (0, utils_1.elementOuterSize)(bullets[0], swiper.isHorizontal() ? 'width' : 'height', true);
|
|
136
|
+
el.forEach(function (subEl) {
|
|
137
|
+
subEl.style[swiper.isHorizontal() ? 'width' : 'height'] = "".concat(bulletSize * (params.dynamicMainBullets + 4), "px");
|
|
138
|
+
});
|
|
139
|
+
if (params.dynamicMainBullets > 1 && previousIndex !== undefined) {
|
|
140
|
+
dynamicBulletIndex += current - (previousIndex || 0);
|
|
141
|
+
if (dynamicBulletIndex > params.dynamicMainBullets - 1) {
|
|
142
|
+
dynamicBulletIndex = params.dynamicMainBullets - 1;
|
|
143
|
+
}
|
|
144
|
+
else if (dynamicBulletIndex < 0) {
|
|
145
|
+
dynamicBulletIndex = 0;
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
firstIndex_1 = Math.max(current - dynamicBulletIndex, 0);
|
|
149
|
+
lastIndex_1 = firstIndex_1 + (Math.min(bullets.length, params.dynamicMainBullets) - 1);
|
|
150
|
+
midIndex = (lastIndex_1 + firstIndex_1) / 2;
|
|
151
|
+
}
|
|
152
|
+
bullets.forEach(function (bulletEl) {
|
|
153
|
+
var _a;
|
|
154
|
+
var classesToRemove = __spreadArray([], ['', '-next', '-next-next', '-prev', '-prev-prev', '-main'].map(function (suffix) { return "".concat(params.bulletActiveClass).concat(suffix); }), true).map(function (s) { return (typeof s === 'string' && s.includes(' ') ? s.split(' ') : s); })
|
|
155
|
+
.flat();
|
|
156
|
+
(_a = bulletEl.classList).remove.apply(_a, classesToRemove);
|
|
157
|
+
});
|
|
158
|
+
if (el.length > 1) {
|
|
159
|
+
bullets.forEach(function (bullet) {
|
|
160
|
+
var _a, _b;
|
|
161
|
+
var bulletIndex = (0, utils_1.elementIndex)(bullet);
|
|
162
|
+
if (bulletIndex === current) {
|
|
163
|
+
(_a = bullet.classList).add.apply(_a, params.bulletActiveClass.split(' '));
|
|
164
|
+
}
|
|
165
|
+
else if (swiper.isElement) {
|
|
166
|
+
bullet.setAttribute('part', 'bullet');
|
|
167
|
+
}
|
|
168
|
+
if (params.dynamicBullets) {
|
|
169
|
+
if (bulletIndex >= firstIndex_1 && bulletIndex <= lastIndex_1) {
|
|
170
|
+
(_b = bullet.classList).add.apply(_b, "".concat(params.bulletActiveClass, "-main").split(' '));
|
|
171
|
+
}
|
|
172
|
+
if (bulletIndex === firstIndex_1) {
|
|
173
|
+
setSideBullets(bullet, 'prev');
|
|
174
|
+
}
|
|
175
|
+
if (bulletIndex === lastIndex_1) {
|
|
176
|
+
setSideBullets(bullet, 'next');
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
});
|
|
180
|
+
}
|
|
181
|
+
else {
|
|
182
|
+
var bullet = bullets[current];
|
|
183
|
+
if (bullet) {
|
|
184
|
+
(_a = bullet.classList).add.apply(_a, params.bulletActiveClass.split(' '));
|
|
185
|
+
}
|
|
186
|
+
if (swiper.isElement) {
|
|
187
|
+
bullets.forEach(function (bulletEl, bulletIndex) {
|
|
188
|
+
bulletEl.setAttribute('part', bulletIndex === current ? 'bullet-active' : 'bullet');
|
|
189
|
+
});
|
|
190
|
+
}
|
|
191
|
+
if (params.dynamicBullets) {
|
|
192
|
+
var firstDisplayedBullet = bullets[firstIndex_1];
|
|
193
|
+
var lastDisplayedBullet = bullets[lastIndex_1];
|
|
194
|
+
for (var i = firstIndex_1; i <= lastIndex_1; i += 1) {
|
|
195
|
+
if (bullets[i]) {
|
|
196
|
+
(_b = bullets[i].classList).add.apply(_b, "".concat(params.bulletActiveClass, "-main").split(' '));
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
setSideBullets(firstDisplayedBullet, 'prev');
|
|
200
|
+
setSideBullets(lastDisplayedBullet, 'next');
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
if (params.dynamicBullets) {
|
|
204
|
+
var dynamicBulletsLength = Math.min(bullets.length, params.dynamicMainBullets + 4);
|
|
205
|
+
var bulletsOffset_1 = (bulletSize * dynamicBulletsLength - bulletSize) / 2 - midIndex * bulletSize;
|
|
206
|
+
var offsetProp_1 = rtl ? 'right' : 'left';
|
|
207
|
+
bullets.forEach(function (bullet) {
|
|
208
|
+
bullet.style[swiper.isHorizontal() ? offsetProp_1 : 'top'] = "".concat(bulletsOffset_1, "px");
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
el.forEach(function (subEl, subElIndex) {
|
|
213
|
+
if (params.type === 'fraction') {
|
|
214
|
+
subEl.querySelectorAll((0, classes_to_selector_1.default)(params.currentClass)).forEach(function (fractionEl) {
|
|
215
|
+
fractionEl.textContent = params.formatFractionCurrent(current + 1);
|
|
216
|
+
});
|
|
217
|
+
subEl.querySelectorAll((0, classes_to_selector_1.default)(params.totalClass)).forEach(function (totalEl) {
|
|
218
|
+
totalEl.textContent = params.formatFractionTotal(total);
|
|
219
|
+
});
|
|
220
|
+
}
|
|
221
|
+
if (params.type === 'progressbar') {
|
|
222
|
+
var progressbarDirection = void 0;
|
|
223
|
+
if (params.progressbarOpposite) {
|
|
224
|
+
progressbarDirection = swiper.isHorizontal() ? 'vertical' : 'horizontal';
|
|
225
|
+
}
|
|
226
|
+
else {
|
|
227
|
+
progressbarDirection = swiper.isHorizontal() ? 'horizontal' : 'vertical';
|
|
228
|
+
}
|
|
229
|
+
var scale = (current + 1) / total;
|
|
230
|
+
var scaleX_1 = 1;
|
|
231
|
+
var scaleY_1 = 1;
|
|
232
|
+
if (progressbarDirection === 'horizontal') {
|
|
233
|
+
scaleX_1 = scale;
|
|
234
|
+
}
|
|
235
|
+
else {
|
|
236
|
+
scaleY_1 = scale;
|
|
237
|
+
}
|
|
238
|
+
subEl
|
|
239
|
+
.querySelectorAll((0, classes_to_selector_1.default)(params.progressbarFillClass))
|
|
240
|
+
.forEach(function (progressEl) {
|
|
241
|
+
progressEl.style.transform = "translate3d(0,0,0) scaleX(".concat(scaleX_1, ") scaleY(").concat(scaleY_1, ")");
|
|
242
|
+
progressEl.style.transitionDuration = "".concat(swiper.params.speed, "ms");
|
|
243
|
+
});
|
|
244
|
+
}
|
|
245
|
+
if (params.type === 'custom' && params.renderCustom) {
|
|
246
|
+
subEl.innerHTML = params.renderCustom(swiper, current + 1, total);
|
|
247
|
+
if (subElIndex === 0)
|
|
248
|
+
emit('paginationRender', subEl);
|
|
249
|
+
}
|
|
250
|
+
else {
|
|
251
|
+
if (subElIndex === 0)
|
|
252
|
+
emit('paginationRender', subEl);
|
|
253
|
+
emit('paginationUpdate', subEl);
|
|
254
|
+
}
|
|
255
|
+
if (swiper.params.watchOverflow && swiper.enabled) {
|
|
256
|
+
subEl.classList[swiper.isLocked ? 'add' : 'remove'](params.lockClass);
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
}
|
|
260
|
+
function render() {
|
|
261
|
+
// Render Container
|
|
262
|
+
var params = swiper.params.pagination;
|
|
263
|
+
if (isPaginationDisabled())
|
|
264
|
+
return;
|
|
265
|
+
var slidesLength = swiper.virtual && swiper.params.virtual.enabled
|
|
266
|
+
? swiper.virtual.slides.length
|
|
267
|
+
: swiper.grid && swiper.params.grid.rows > 1
|
|
268
|
+
? swiper.slides.length / Math.ceil(swiper.params.grid.rows)
|
|
269
|
+
: swiper.slides.length;
|
|
270
|
+
var el = swiper.pagination.el;
|
|
271
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
272
|
+
var paginationHTML = '';
|
|
273
|
+
if (params.type === 'bullets') {
|
|
274
|
+
var numberOfBullets = swiper.params.loop
|
|
275
|
+
? Math.ceil(slidesLength / swiper.params.slidesPerGroup)
|
|
276
|
+
: swiper.snapGrid.length;
|
|
277
|
+
if (swiper.params.freeMode &&
|
|
278
|
+
swiper.params.freeMode.enabled &&
|
|
279
|
+
numberOfBullets > slidesLength) {
|
|
280
|
+
numberOfBullets = slidesLength;
|
|
281
|
+
}
|
|
282
|
+
for (var i = 0; i < numberOfBullets; i += 1) {
|
|
283
|
+
if (params.renderBullet) {
|
|
284
|
+
paginationHTML += params.renderBullet.call(swiper, i, params.bulletClass);
|
|
285
|
+
}
|
|
286
|
+
else {
|
|
287
|
+
// prettier-ignore
|
|
288
|
+
paginationHTML += "<".concat(params.bulletElement, " ").concat(swiper.isElement ? 'part="bullet"' : '', " class=\"").concat(params.bulletClass, "\"></").concat(params.bulletElement, ">");
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
if (params.type === 'fraction') {
|
|
293
|
+
if (params.renderFraction) {
|
|
294
|
+
paginationHTML = params.renderFraction.call(swiper, params.currentClass, params.totalClass);
|
|
295
|
+
}
|
|
296
|
+
else {
|
|
297
|
+
paginationHTML =
|
|
298
|
+
"<span class=\"".concat(params.currentClass, "\"></span>") +
|
|
299
|
+
' / ' +
|
|
300
|
+
"<span class=\"".concat(params.totalClass, "\"></span>");
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
if (params.type === 'progressbar') {
|
|
304
|
+
if (params.renderProgressbar) {
|
|
305
|
+
paginationHTML = params.renderProgressbar.call(swiper, params.progressbarFillClass);
|
|
306
|
+
}
|
|
307
|
+
else {
|
|
308
|
+
paginationHTML = "<span class=\"".concat(params.progressbarFillClass, "\"></span>");
|
|
309
|
+
}
|
|
310
|
+
}
|
|
311
|
+
swiper.pagination.bullets = [];
|
|
312
|
+
el.forEach(function (subEl) {
|
|
313
|
+
var _a;
|
|
314
|
+
if (params.type !== 'custom') {
|
|
315
|
+
subEl.innerHTML = paginationHTML || '';
|
|
316
|
+
}
|
|
317
|
+
if (params.type === 'bullets') {
|
|
318
|
+
(_a = swiper.pagination.bullets).push.apply(_a, subEl.querySelectorAll((0, classes_to_selector_1.default)(params.bulletClass)));
|
|
319
|
+
}
|
|
320
|
+
});
|
|
321
|
+
if (params.type !== 'custom') {
|
|
322
|
+
emit('paginationRender', el[0]);
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
function init() {
|
|
326
|
+
swiper.params.pagination = (0, create_element_if_not_defined_1.default)(swiper, swiper.originalParams.pagination, swiper.params.pagination, { el: 'swiper-pagination' });
|
|
327
|
+
var params = swiper.params.pagination;
|
|
328
|
+
if (!params.el)
|
|
329
|
+
return;
|
|
330
|
+
var el;
|
|
331
|
+
if (typeof params.el === 'string' && swiper.isElement) {
|
|
332
|
+
el = swiper.el.querySelector(params.el);
|
|
333
|
+
}
|
|
334
|
+
if (!el && typeof params.el === 'string') {
|
|
335
|
+
el = __spreadArray([], document.querySelectorAll(params.el), true);
|
|
336
|
+
}
|
|
337
|
+
if (!el) {
|
|
338
|
+
el = params.el;
|
|
339
|
+
}
|
|
340
|
+
if (!el || el.length === 0)
|
|
341
|
+
return;
|
|
342
|
+
if (swiper.params.uniqueNavElements &&
|
|
343
|
+
typeof params.el === 'string' &&
|
|
344
|
+
Array.isArray(el) &&
|
|
345
|
+
el.length > 1) {
|
|
346
|
+
el = __spreadArray([], swiper.el.querySelectorAll(params.el), true);
|
|
347
|
+
// check if it belongs to another nested Swiper
|
|
348
|
+
if (el.length > 1) {
|
|
349
|
+
el = el.filter(function (subEl) {
|
|
350
|
+
if ((0, utils_1.elementParents)(subEl, '.swiper')[0] !== swiper.el)
|
|
351
|
+
return false;
|
|
352
|
+
return true;
|
|
353
|
+
})[0];
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
if (Array.isArray(el) && el.length === 1)
|
|
357
|
+
el = el[0];
|
|
358
|
+
Object.assign(swiper.pagination, {
|
|
359
|
+
el: el,
|
|
360
|
+
});
|
|
361
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
362
|
+
el.forEach(function (subEl) {
|
|
363
|
+
var _a;
|
|
364
|
+
if (params.type === 'bullets' && params.clickable) {
|
|
365
|
+
(_a = subEl.classList).add.apply(_a, (params.clickableClass || '').split(' '));
|
|
366
|
+
}
|
|
367
|
+
subEl.classList.add(params.modifierClass + params.type);
|
|
368
|
+
subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
|
|
369
|
+
if (params.type === 'bullets' && params.dynamicBullets) {
|
|
370
|
+
subEl.classList.add("".concat(params.modifierClass).concat(params.type, "-dynamic"));
|
|
371
|
+
dynamicBulletIndex = 0;
|
|
372
|
+
if (params.dynamicMainBullets < 1) {
|
|
373
|
+
params.dynamicMainBullets = 1;
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
if (params.type === 'progressbar' && params.progressbarOpposite) {
|
|
377
|
+
subEl.classList.add(params.progressbarOppositeClass);
|
|
378
|
+
}
|
|
379
|
+
if (params.clickable) {
|
|
380
|
+
subEl.addEventListener('click', onBulletClick);
|
|
381
|
+
}
|
|
382
|
+
if (!swiper.enabled) {
|
|
383
|
+
subEl.classList.add(params.lockClass);
|
|
384
|
+
}
|
|
385
|
+
});
|
|
386
|
+
}
|
|
387
|
+
function destroy() {
|
|
388
|
+
var params = swiper.params.pagination;
|
|
389
|
+
if (isPaginationDisabled())
|
|
390
|
+
return;
|
|
391
|
+
var el = swiper.pagination.el;
|
|
392
|
+
if (el) {
|
|
393
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
394
|
+
el.forEach(function (subEl) {
|
|
395
|
+
var _a;
|
|
396
|
+
subEl.classList.remove(params.hiddenClass);
|
|
397
|
+
subEl.classList.remove(params.modifierClass + params.type);
|
|
398
|
+
subEl.classList.remove(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
|
|
399
|
+
if (params.clickable) {
|
|
400
|
+
(_a = subEl.classList).remove.apply(_a, (params.clickableClass || '').split(' '));
|
|
401
|
+
subEl.removeEventListener('click', onBulletClick);
|
|
402
|
+
}
|
|
403
|
+
});
|
|
404
|
+
}
|
|
405
|
+
if (swiper.pagination.bullets)
|
|
406
|
+
swiper.pagination.bullets.forEach(function (subEl) {
|
|
407
|
+
var _a;
|
|
408
|
+
return (_a = subEl.classList).remove.apply(_a, params.bulletActiveClass.split(' '));
|
|
409
|
+
});
|
|
410
|
+
}
|
|
411
|
+
on('changeDirection', function () {
|
|
412
|
+
if (!swiper.pagination || !swiper.pagination.el)
|
|
413
|
+
return;
|
|
414
|
+
var params = swiper.params.pagination;
|
|
415
|
+
var el = swiper.pagination.el;
|
|
416
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
417
|
+
el.forEach(function (subEl) {
|
|
418
|
+
subEl.classList.remove(params.horizontalClass, params.verticalClass);
|
|
419
|
+
subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
|
|
420
|
+
});
|
|
421
|
+
});
|
|
422
|
+
on('init', function () {
|
|
423
|
+
if (swiper.params.pagination.enabled === false) {
|
|
424
|
+
// eslint-disable-next-line
|
|
425
|
+
disable();
|
|
426
|
+
}
|
|
427
|
+
else {
|
|
428
|
+
init();
|
|
429
|
+
render();
|
|
430
|
+
update();
|
|
431
|
+
}
|
|
432
|
+
});
|
|
433
|
+
on('activeIndexChange', function () {
|
|
434
|
+
if (typeof swiper.snapIndex === 'undefined') {
|
|
435
|
+
update();
|
|
436
|
+
}
|
|
437
|
+
});
|
|
438
|
+
on('snapIndexChange', function () {
|
|
439
|
+
update();
|
|
440
|
+
});
|
|
441
|
+
on('snapGridLengthChange', function () {
|
|
442
|
+
render();
|
|
443
|
+
update();
|
|
444
|
+
});
|
|
445
|
+
on('destroy', function () {
|
|
446
|
+
destroy();
|
|
447
|
+
});
|
|
448
|
+
on('enable disable', function () {
|
|
449
|
+
var el = swiper.pagination.el;
|
|
450
|
+
if (el) {
|
|
451
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
452
|
+
el.forEach(function (subEl) {
|
|
453
|
+
return subEl.classList[swiper.enabled ? 'remove' : 'add'](swiper.params.pagination.lockClass);
|
|
454
|
+
});
|
|
455
|
+
}
|
|
456
|
+
});
|
|
457
|
+
on('lock unlock', function () {
|
|
458
|
+
update();
|
|
459
|
+
});
|
|
460
|
+
on('click', function (_s, e) {
|
|
461
|
+
var targetEl = e.target;
|
|
462
|
+
var el = (0, utils_1.makeElementsArray)(swiper.pagination.el);
|
|
463
|
+
if (swiper.params.pagination.el &&
|
|
464
|
+
swiper.params.pagination.hideOnClick &&
|
|
465
|
+
el &&
|
|
466
|
+
el.length > 0 &&
|
|
467
|
+
!targetEl.classList.contains(swiper.params.pagination.bulletClass)) {
|
|
468
|
+
if (swiper.navigation &&
|
|
469
|
+
((swiper.navigation.nextEl && targetEl === swiper.navigation.nextEl) ||
|
|
470
|
+
(swiper.navigation.prevEl && targetEl === swiper.navigation.prevEl)))
|
|
471
|
+
return;
|
|
472
|
+
var isHidden = el[0].classList.contains(swiper.params.pagination.hiddenClass);
|
|
473
|
+
if (isHidden === true) {
|
|
474
|
+
emit('paginationShow');
|
|
475
|
+
}
|
|
476
|
+
else {
|
|
477
|
+
emit('paginationHide');
|
|
478
|
+
}
|
|
479
|
+
el.forEach(function (subEl) { return subEl.classList.toggle(swiper.params.pagination.hiddenClass); });
|
|
480
|
+
}
|
|
481
|
+
});
|
|
482
|
+
var enable = function () {
|
|
483
|
+
swiper.el.classList.remove(swiper.params.pagination.paginationDisabledClass);
|
|
484
|
+
var el = swiper.pagination.el;
|
|
485
|
+
if (el) {
|
|
486
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
487
|
+
el.forEach(function (subEl) {
|
|
488
|
+
return subEl.classList.remove(swiper.params.pagination.paginationDisabledClass);
|
|
489
|
+
});
|
|
490
|
+
}
|
|
491
|
+
init();
|
|
492
|
+
render();
|
|
493
|
+
update();
|
|
494
|
+
};
|
|
495
|
+
var disable = function () {
|
|
496
|
+
swiper.el.classList.add(swiper.params.pagination.paginationDisabledClass);
|
|
497
|
+
var el = swiper.pagination.el;
|
|
498
|
+
if (el) {
|
|
499
|
+
el = (0, utils_1.makeElementsArray)(el);
|
|
500
|
+
el.forEach(function (subEl) { return subEl.classList.add(swiper.params.pagination.paginationDisabledClass); });
|
|
501
|
+
}
|
|
502
|
+
destroy();
|
|
503
|
+
};
|
|
504
|
+
Object.assign(swiper.pagination, {
|
|
505
|
+
enable: enable,
|
|
506
|
+
disable: disable,
|
|
507
|
+
render: render,
|
|
508
|
+
update: update,
|
|
509
|
+
init: init,
|
|
510
|
+
destroy: destroy,
|
|
511
|
+
});
|
|
512
|
+
}
|
|
513
|
+
exports.Pagination = Pagination;
|
|
514
|
+
//# sourceMappingURL=pagination.js.map
|