@siemens/ix 2.0.0 → 2.0.2
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/components/_commonjsHelpers.js +21 -0
- package/components/_commonjsHelpers.js.map +1 -0
- package/{dist/esm/a11y-d5dd20ad.js → components/a11y.js} +2 -2
- package/components/a11y.js.map +1 -0
- package/components/animation.js +19 -0
- package/components/animation.js.map +1 -0
- package/components/anime.es.js +1311 -0
- package/components/anime.es.js.map +1 -0
- package/components/application-header.js +109 -0
- package/components/application-header.js.map +1 -0
- package/components/avatar.js +53 -0
- package/components/avatar.js.map +1 -0
- package/components/base-button.js +47 -0
- package/components/base-button.js.map +1 -0
- package/components/base-icon-button.js +18 -0
- package/components/base-icon-button.js.map +1 -0
- package/components/breadcrumb-item.js +100 -0
- package/components/breadcrumb-item.js.map +1 -0
- package/components/breakpoints.js +25 -0
- package/components/breakpoints.js.map +1 -0
- package/components/burger-menu.js +55 -0
- package/components/burger-menu.js.map +1 -0
- package/components/button.js +91 -0
- package/components/button.js.map +1 -0
- package/components/card-accordion.js +72 -0
- package/components/card-accordion.js.map +1 -0
- package/components/card-content.js +32 -0
- package/components/card-content.js.map +1 -0
- package/components/card-title.js +32 -0
- package/components/card-title.js.map +1 -0
- package/components/card.js +36 -0
- package/components/card.js.map +1 -0
- package/components/context.js +101 -0
- package/components/context.js.map +1 -0
- package/components/custom-elements.d.ts +10 -0
- package/components/date-picker.js +372 -0
- package/components/date-picker.js.map +1 -0
- package/components/date-time-card.js +45 -0
- package/components/date-time-card.js.map +1 -0
- package/components/default-tree-item.js +22 -0
- package/components/default-tree-item.js.map +1 -0
- package/components/divider.js +32 -0
- package/components/divider.js.map +1 -0
- package/components/dropdown-item.js +69 -0
- package/components/dropdown-item.js.map +1 -0
- package/components/dropdown.js +351 -0
- package/components/dropdown.js.map +1 -0
- package/components/filter-chip.js +56 -0
- package/components/filter-chip.js.map +1 -0
- package/components/flip-tile-state.js +20 -0
- package/components/flip-tile-state.js.map +1 -0
- package/components/floating-ui.dom.esm.js +1512 -0
- package/components/floating-ui.dom.esm.js.map +1 -0
- package/components/group-context-menu.js +73 -0
- package/components/group-context-menu.js.map +1 -0
- package/components/group-item.js +58 -0
- package/components/group-item.js.map +1 -0
- package/components/icon-button.js +99 -0
- package/components/icon-button.js.map +1 -0
- package/components/index.d.ts +27 -0
- package/components/index.js +101 -0
- package/components/index.js.map +1 -0
- package/components/ix-action-card.d.ts +11 -0
- package/components/ix-action-card.js +66 -0
- package/components/ix-action-card.js.map +1 -0
- package/components/ix-application-header.d.ts +11 -0
- package/components/ix-application-header.js +8 -0
- package/components/ix-application-header.js.map +1 -0
- package/components/ix-application-sidebar.d.ts +11 -0
- package/components/ix-application-sidebar.js +63 -0
- package/components/ix-application-sidebar.js.map +1 -0
- package/components/ix-application.d.ts +11 -0
- package/components/ix-application.js +128 -0
- package/components/ix-application.js.map +1 -0
- package/components/ix-avatar.d.ts +11 -0
- package/components/ix-avatar.js +8 -0
- package/components/ix-avatar.js.map +1 -0
- package/components/ix-basic-navigation.d.ts +11 -0
- package/components/ix-basic-navigation.js +132 -0
- package/components/ix-basic-navigation.js.map +1 -0
- package/components/ix-blind.d.ts +11 -0
- package/components/ix-blind.js +128 -0
- package/components/ix-blind.js.map +1 -0
- package/components/ix-breadcrumb-item.d.ts +11 -0
- package/components/ix-breadcrumb-item.js +8 -0
- package/components/ix-breadcrumb-item.js.map +1 -0
- package/components/ix-breadcrumb.d.ts +11 -0
- package/components/ix-breadcrumb.js +154 -0
- package/components/ix-breadcrumb.js.map +1 -0
- package/components/ix-burger-menu.d.ts +11 -0
- package/components/ix-burger-menu.js +8 -0
- package/components/ix-burger-menu.js.map +1 -0
- package/components/ix-button.d.ts +11 -0
- package/components/ix-button.js +8 -0
- package/components/ix-button.js.map +1 -0
- package/components/ix-card-accordion.d.ts +11 -0
- package/components/ix-card-accordion.js +8 -0
- package/components/ix-card-accordion.js.map +1 -0
- package/components/ix-card-content.d.ts +11 -0
- package/components/ix-card-content.js +8 -0
- package/components/ix-card-content.js.map +1 -0
- package/components/ix-card-list.d.ts +11 -0
- package/components/ix-card-list.js +228 -0
- package/components/ix-card-list.js.map +1 -0
- package/components/ix-card-title.d.ts +11 -0
- package/components/ix-card-title.js +8 -0
- package/components/ix-card-title.js.map +1 -0
- package/components/ix-card.d.ts +11 -0
- package/components/ix-card.js +8 -0
- package/components/ix-card.js.map +1 -0
- package/components/ix-category-filter.d.ts +11 -0
- package/components/ix-category-filter.js +464 -0
- package/components/ix-category-filter.js.map +1 -0
- package/components/ix-chip.d.ts +11 -0
- package/components/ix-chip.js +98 -0
- package/components/ix-chip.js.map +1 -0
- package/components/ix-col.d.ts +11 -0
- package/components/ix-col.js +96 -0
- package/components/ix-col.js.map +1 -0
- package/components/ix-content-header.d.ts +11 -0
- package/components/ix-content-header.js +63 -0
- package/components/ix-content-header.js.map +1 -0
- package/components/ix-content.d.ts +11 -0
- package/components/ix-content.js +48 -0
- package/components/ix-content.js.map +1 -0
- package/components/ix-css-grid-item.d.ts +11 -0
- package/components/ix-css-grid-item.js +40 -0
- package/components/ix-css-grid-item.js.map +1 -0
- package/components/ix-css-grid.d.ts +11 -0
- package/components/ix-css-grid.js +113 -0
- package/components/ix-css-grid.js.map +1 -0
- package/components/ix-date-picker.d.ts +11 -0
- package/components/ix-date-picker.js +8 -0
- package/components/ix-date-picker.js.map +1 -0
- package/components/ix-date-time-card.d.ts +11 -0
- package/components/ix-date-time-card.js +8 -0
- package/components/ix-date-time-card.js.map +1 -0
- package/components/ix-datetime-picker.d.ts +11 -0
- package/components/ix-datetime-picker.js +149 -0
- package/components/ix-datetime-picker.js.map +1 -0
- package/components/ix-divider.d.ts +11 -0
- package/components/ix-divider.js +8 -0
- package/components/ix-divider.js.map +1 -0
- package/components/ix-drawer.d.ts +11 -0
- package/components/ix-drawer.js +145 -0
- package/components/ix-drawer.js.map +1 -0
- package/components/ix-dropdown-button.d.ts +11 -0
- package/components/ix-dropdown-button.js +92 -0
- package/components/ix-dropdown-button.js.map +1 -0
- package/components/ix-dropdown-header.d.ts +11 -0
- package/components/ix-dropdown-header.js +44 -0
- package/components/ix-dropdown-header.js.map +1 -0
- package/components/ix-dropdown-item.d.ts +11 -0
- package/components/ix-dropdown-item.js +8 -0
- package/components/ix-dropdown-item.js.map +1 -0
- package/components/ix-dropdown-quick-actions.d.ts +11 -0
- package/components/ix-dropdown-quick-actions.js +35 -0
- package/components/ix-dropdown-quick-actions.js.map +1 -0
- package/components/ix-dropdown.d.ts +11 -0
- package/components/ix-dropdown.js +8 -0
- package/components/ix-dropdown.js.map +1 -0
- package/components/ix-empty-state.d.ts +11 -0
- package/components/ix-empty-state.js +65 -0
- package/components/ix-empty-state.js.map +1 -0
- package/components/ix-event-list-item.d.ts +11 -0
- package/components/ix-event-list-item.js +61 -0
- package/components/ix-event-list-item.js.map +1 -0
- package/components/ix-event-list.d.ts +11 -0
- package/components/ix-event-list.js +143 -0
- package/components/ix-event-list.js.map +1 -0
- package/components/ix-expanding-search.d.ts +11 -0
- package/components/ix-expanding-search.js +119 -0
- package/components/ix-expanding-search.js.map +1 -0
- package/components/ix-filter-chip.d.ts +11 -0
- package/components/ix-filter-chip.js +8 -0
- package/components/ix-filter-chip.js.map +1 -0
- package/components/ix-flip-tile-content.d.ts +11 -0
- package/components/ix-flip-tile-content.js +38 -0
- package/components/ix-flip-tile-content.js.map +1 -0
- package/components/ix-flip-tile.d.ts +11 -0
- package/components/ix-flip-tile.js +121 -0
- package/components/ix-flip-tile.js.map +1 -0
- package/components/ix-form-field.d.ts +11 -0
- package/components/ix-form-field.js +43 -0
- package/components/ix-form-field.js.map +1 -0
- package/components/ix-group-context-menu.d.ts +11 -0
- package/components/ix-group-context-menu.js +8 -0
- package/components/ix-group-context-menu.js.map +1 -0
- package/components/ix-group-item.d.ts +11 -0
- package/components/ix-group-item.js +8 -0
- package/components/ix-group-item.js.map +1 -0
- package/components/ix-group.d.ts +11 -0
- package/components/ix-group.js +178 -0
- package/components/ix-group.js.map +1 -0
- package/components/ix-icon-button.d.ts +11 -0
- package/components/ix-icon-button.js +8 -0
- package/components/ix-icon-button.js.map +1 -0
- package/components/ix-icon-toggle-button.d.ts +11 -0
- package/components/ix-icon-toggle-button.js +116 -0
- package/components/ix-icon-toggle-button.js.map +1 -0
- package/components/ix-input-group.d.ts +11 -0
- package/components/ix-input-group.js +143 -0
- package/components/ix-input-group.js.map +1 -0
- package/components/ix-key-value-list.d.ts +11 -0
- package/components/ix-key-value-list.js +38 -0
- package/components/ix-key-value-list.js.map +1 -0
- package/components/ix-key-value.d.ts +11 -0
- package/components/ix-key-value.js +47 -0
- package/components/ix-key-value.js.map +1 -0
- package/components/ix-kpi.d.ts +11 -0
- package/components/ix-kpi.js +69 -0
- package/components/ix-kpi.js.map +1 -0
- package/components/ix-layout-grid.d.ts +11 -0
- package/components/ix-layout-grid.js +47 -0
- package/components/ix-layout-grid.js.map +1 -0
- package/components/ix-link-button.d.ts +11 -0
- package/components/ix-link-button.js +48 -0
- package/components/ix-link-button.js.map +1 -0
- package/components/ix-map-navigation-overlay.d.ts +11 -0
- package/components/ix-map-navigation-overlay.js +8 -0
- package/components/ix-map-navigation-overlay.js.map +1 -0
- package/components/ix-map-navigation.d.ts +11 -0
- package/components/ix-map-navigation.js +226 -0
- package/components/ix-map-navigation.js.map +1 -0
- package/components/ix-menu-about-item.d.ts +11 -0
- package/components/ix-menu-about-item.js +38 -0
- package/components/ix-menu-about-item.js.map +1 -0
- package/components/ix-menu-about-news.d.ts +11 -0
- package/components/ix-menu-about-news.js +83 -0
- package/components/ix-menu-about-news.js.map +1 -0
- package/components/ix-menu-about.d.ts +11 -0
- package/components/ix-menu-about.js +119 -0
- package/components/ix-menu-about.js.map +1 -0
- package/components/ix-menu-avatar-item.d.ts +11 -0
- package/components/ix-menu-avatar-item.js +8 -0
- package/components/ix-menu-avatar-item.js.map +1 -0
- package/components/ix-menu-avatar.d.ts +11 -0
- package/components/ix-menu-avatar.js +77 -0
- package/components/ix-menu-avatar.js.map +1 -0
- package/components/ix-menu-category.d.ts +11 -0
- package/components/ix-menu-category.js +190 -0
- package/components/ix-menu-category.js.map +1 -0
- package/components/ix-menu-item.d.ts +11 -0
- package/components/ix-menu-item.js +8 -0
- package/components/ix-menu-item.js.map +1 -0
- package/components/ix-menu-settings-item.d.ts +11 -0
- package/components/ix-menu-settings-item.js +38 -0
- package/components/ix-menu-settings-item.js.map +1 -0
- package/components/ix-menu-settings.d.ts +11 -0
- package/components/ix-menu-settings.js +106 -0
- package/components/ix-menu-settings.js.map +1 -0
- package/components/ix-menu.d.ts +11 -0
- package/components/ix-menu.js +508 -0
- package/components/ix-menu.js.map +1 -0
- package/components/ix-message-bar.d.ts +11 -0
- package/components/ix-message-bar.js +87 -0
- package/components/ix-message-bar.js.map +1 -0
- package/components/ix-modal-content.d.ts +11 -0
- package/components/ix-modal-content.js +35 -0
- package/components/ix-modal-content.js.map +1 -0
- package/components/ix-modal-example.d.ts +11 -0
- package/components/ix-modal-example.js +58 -0
- package/components/ix-modal-example.js.map +1 -0
- package/components/ix-modal-footer.d.ts +11 -0
- package/components/ix-modal-footer.js +35 -0
- package/components/ix-modal-footer.js.map +1 -0
- package/components/ix-modal-header.d.ts +11 -0
- package/components/ix-modal-header.js +84 -0
- package/components/ix-modal-header.js.map +1 -0
- package/components/ix-modal-loading.d.ts +11 -0
- package/components/ix-modal-loading.js +41 -0
- package/components/ix-modal-loading.js.map +1 -0
- package/components/ix-modal.d.ts +11 -0
- package/components/ix-modal.js +155 -0
- package/components/ix-modal.js.map +1 -0
- package/components/ix-pagination.d.ts +11 -0
- package/components/ix-pagination.js +211 -0
- package/components/ix-pagination.js.map +1 -0
- package/components/ix-pill.d.ts +11 -0
- package/components/ix-pill.js +78 -0
- package/components/ix-pill.js.map +1 -0
- package/components/ix-push-card.d.ts +11 -0
- package/components/ix-push-card.js +80 -0
- package/components/ix-push-card.js.map +1 -0
- package/components/ix-row.d.ts +11 -0
- package/components/ix-row.js +35 -0
- package/components/ix-row.js.map +1 -0
- package/components/ix-select-item.d.ts +11 -0
- package/components/ix-select-item.js +8 -0
- package/components/ix-select-item.js.map +1 -0
- package/components/ix-select.d.ts +11 -0
- package/components/ix-select.js +8 -0
- package/components/ix-select.js.map +1 -0
- package/components/ix-slider.d.ts +11 -0
- package/components/ix-slider.js +192 -0
- package/components/ix-slider.js.map +1 -0
- package/components/ix-spinner.d.ts +11 -0
- package/components/ix-spinner.js +8 -0
- package/components/ix-spinner.js.map +1 -0
- package/components/ix-split-button-item.d.ts +11 -0
- package/components/ix-split-button-item.js +51 -0
- package/components/ix-split-button-item.js.map +1 -0
- package/components/ix-split-button.d.ts +11 -0
- package/components/ix-split-button.js +97 -0
- package/components/ix-split-button.js.map +1 -0
- package/components/ix-tab-item.d.ts +11 -0
- package/components/ix-tab-item.js +8 -0
- package/components/ix-tab-item.js.map +1 -0
- package/components/ix-tabs.d.ts +11 -0
- package/components/ix-tabs.js +8 -0
- package/components/ix-tabs.js.map +1 -0
- package/components/ix-tile.d.ts +11 -0
- package/components/ix-tile.js +59 -0
- package/components/ix-tile.js.map +1 -0
- package/components/ix-time-picker.d.ts +11 -0
- package/components/ix-time-picker.js +8 -0
- package/components/ix-time-picker.js.map +1 -0
- package/components/ix-toast-container.d.ts +11 -0
- package/components/ix-toast-container.js +124 -0
- package/components/ix-toast-container.js.map +1 -0
- package/components/ix-toast.d.ts +11 -0
- package/components/ix-toast.js +8 -0
- package/components/ix-toast.js.map +1 -0
- package/components/ix-toggle-button.d.ts +11 -0
- package/components/ix-toggle-button.js +105 -0
- package/components/ix-toggle-button.js.map +1 -0
- package/components/ix-toggle.d.ts +11 -0
- package/components/ix-toggle.js +62 -0
- package/components/ix-toggle.js.map +1 -0
- package/components/ix-tooltip.d.ts +11 -0
- package/components/ix-tooltip.js +8 -0
- package/components/ix-tooltip.js.map +1 -0
- package/components/ix-tree-item.d.ts +11 -0
- package/components/ix-tree-item.js +8 -0
- package/components/ix-tree-item.js.map +1 -0
- package/components/ix-tree.d.ts +11 -0
- package/components/ix-tree.js +727 -0
- package/components/ix-tree.js.map +1 -0
- package/components/ix-typography.d.ts +11 -0
- package/components/ix-typography.js +8 -0
- package/components/ix-typography.js.map +1 -0
- package/components/ix-upload.d.ts +11 -0
- package/components/ix-upload.js +147 -0
- package/components/ix-upload.js.map +1 -0
- package/components/ix-validation-tooltip.d.ts +11 -0
- package/components/ix-validation-tooltip.js +170 -0
- package/components/ix-validation-tooltip.js.map +1 -0
- package/components/ix-workflow-step.d.ts +11 -0
- package/components/ix-workflow-step.js +120 -0
- package/components/ix-workflow-step.js.map +1 -0
- package/components/ix-workflow-steps.d.ts +11 -0
- package/components/ix-workflow-steps.js +99 -0
- package/components/ix-workflow-steps.js.map +1 -0
- package/components/logical-filter-operator.js +35 -0
- package/components/logical-filter-operator.js.map +1 -0
- package/components/luxon.js +7828 -0
- package/components/luxon.js.map +1 -0
- package/components/map-navigation-overlay.js +89 -0
- package/components/map-navigation-overlay.js.map +1 -0
- package/components/menu-avatar-item.js +45 -0
- package/components/menu-avatar-item.js.map +1 -0
- package/components/menu-item.js +92 -0
- package/components/menu-item.js.map +1 -0
- package/components/menu-service.js +156 -0
- package/components/menu-service.js.map +1 -0
- package/components/modal.js +245 -0
- package/components/modal.js.map +1 -0
- package/components/mutation-observer.js +13 -0
- package/components/mutation-observer.js.map +1 -0
- package/components/my-component.d.ts +11 -0
- package/components/my-component.js +34 -0
- package/components/my-component.js.map +1 -0
- package/components/package.json +8 -0
- package/components/rwd.util.js +41 -0
- package/components/rwd.util.js.map +1 -0
- package/components/select-item.js +92 -0
- package/components/select-item.js.map +1 -0
- package/components/select.js +410 -0
- package/components/select.js.map +1 -0
- package/components/shadow-dom.js +21 -0
- package/components/shadow-dom.js.map +1 -0
- package/components/spinner.js +48 -0
- package/components/spinner.js.map +1 -0
- package/components/tab-item.js +87 -0
- package/components/tab-item.js.map +1 -0
- package/components/tabs.js +227 -0
- package/components/tabs.js.map +1 -0
- package/components/theme-switcher.js +123 -0
- package/components/theme-switcher.js.map +1 -0
- package/components/time-picker.js +252 -0
- package/components/time-picker.js.map +1 -0
- package/components/toast.js +105 -0
- package/components/toast.js.map +1 -0
- package/components/tooltip.js +197 -0
- package/components/tooltip.js.map +1 -0
- package/components/tree-item.js +51 -0
- package/components/tree-item.js.map +1 -0
- package/components/typed-event.js +46 -0
- package/components/typed-event.js.map +1 -0
- package/components/typography.js +76 -0
- package/components/typography.js.map +1 -0
- package/components/upload-file-state.js +19 -0
- package/components/upload-file-state.js.map +1 -0
- package/dist/cjs/{a11y-4fdcefb4.js → a11y-7e1c1b86.js} +2 -2
- package/dist/cjs/a11y-7e1c1b86.js.map +1 -0
- package/dist/cjs/ix-application-header.cjs.entry.js +15 -2
- package/dist/cjs/ix-application-header.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-blind.cjs.entry.js +1 -1
- package/dist/cjs/ix-breadcrumb-item.cjs.entry.js +11 -4
- package/dist/cjs/ix-breadcrumb-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-breadcrumb.cjs.entry.js +5 -2
- package/dist/cjs/ix-breadcrumb.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-burger-menu.cjs.entry.js +1 -1
- package/dist/cjs/ix-button.cjs.entry.js +1 -1
- package/dist/cjs/ix-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-category-filter.cjs.entry.js +1 -1
- package/dist/cjs/ix-category-filter.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-drawer.cjs.entry.js +1 -1
- package/dist/cjs/ix-drawer.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-dropdown.cjs.entry.js +9 -4
- package/dist/cjs/ix-dropdown.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-icon-button_2.cjs.entry.js +1 -1
- package/dist/cjs/ix-icon-button_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-icon-toggle-button.cjs.entry.js +2 -2
- package/dist/cjs/ix-icon-toggle-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-input-group.cjs.entry.js +16 -3
- package/dist/cjs/ix-input-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-modal.cjs.entry.js +2 -3
- package/dist/cjs/ix-modal.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-pagination.cjs.entry.js +3 -3
- package/dist/cjs/ix-pagination.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-slider.cjs.entry.js +1 -1
- package/dist/cjs/ix-toggle-button.cjs.entry.js +1 -1
- package/dist/cjs/ix-toggle.cjs.entry.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/siemens-ix.cjs.js +1 -1
- package/dist/collection/components/application-header/application-header.js +18 -3
- package/dist/collection/components/application-header/application-header.js.map +1 -1
- package/dist/collection/components/application-header/test/application-headet.ct.js +16 -1
- package/dist/collection/components/application-header/test/application-headet.ct.js.map +1 -1
- package/dist/collection/components/breadcrumb/breadcrumb.js +4 -1
- package/dist/collection/components/breadcrumb/breadcrumb.js.map +1 -1
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.css +36 -0
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.js +14 -2
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.js.map +1 -1
- package/dist/collection/components/button/button.css +18 -0
- package/dist/collection/components/button/test/button.ct.js +6 -0
- package/dist/collection/components/button/test/button.ct.js.map +1 -1
- package/dist/collection/components/category-filter/category-filter.css +18 -0
- package/dist/collection/components/drawer/drawer.css +4 -0
- package/dist/collection/components/dropdown/dropdown.js +9 -4
- package/dist/collection/components/dropdown/dropdown.js.map +1 -1
- package/dist/collection/components/dropdown/test/dropdown.ct.js +21 -0
- package/dist/collection/components/dropdown/test/dropdown.ct.js.map +1 -1
- package/dist/collection/components/icon-button/icon-button.css +18 -0
- package/dist/collection/components/icon-toggle-button/icon-toggle-button.css +18 -0
- package/dist/collection/components/input-group/input-group.js +16 -3
- package/dist/collection/components/input-group/input-group.js.map +1 -1
- package/dist/collection/components/input-group/tests/input-group.ct.js +86 -0
- package/dist/collection/components/input-group/tests/input-group.ct.js.map +1 -0
- package/dist/collection/components/menu/menu.js +4 -1
- package/dist/collection/components/menu/menu.js.map +1 -1
- package/dist/collection/components/modal/modal.js +1 -2
- package/dist/collection/components/modal/modal.js.map +1 -1
- package/dist/collection/components/pagination/pagination.css +18 -0
- package/dist/collection/components/pagination/pagination.js +1 -1
- package/dist/collection/components/pagination/pagination.js.map +1 -1
- package/dist/collection/components/pagination/test/pagination.ct.js +20 -0
- package/dist/collection/components/pagination/test/pagination.ct.js.map +1 -1
- package/dist/collection/components/utils/a11y.js +1 -1
- package/dist/collection/components/utils/a11y.js.map +1 -1
- package/dist/esm/a11y-115b6a36.js +79 -0
- package/dist/esm/a11y-115b6a36.js.map +1 -0
- package/dist/esm/ix-application-header.entry.js +15 -2
- package/dist/esm/ix-application-header.entry.js.map +1 -1
- package/dist/esm/ix-blind.entry.js +1 -1
- package/dist/esm/ix-breadcrumb-item.entry.js +11 -4
- package/dist/esm/ix-breadcrumb-item.entry.js.map +1 -1
- package/dist/esm/ix-breadcrumb.entry.js +5 -2
- package/dist/esm/ix-breadcrumb.entry.js.map +1 -1
- package/dist/esm/ix-burger-menu.entry.js +1 -1
- package/dist/esm/ix-button.entry.js +1 -1
- package/dist/esm/ix-button.entry.js.map +1 -1
- package/dist/esm/ix-category-filter.entry.js +1 -1
- package/dist/esm/ix-category-filter.entry.js.map +1 -1
- package/dist/esm/ix-drawer.entry.js +1 -1
- package/dist/esm/ix-drawer.entry.js.map +1 -1
- package/dist/esm/ix-dropdown.entry.js +9 -4
- package/dist/esm/ix-dropdown.entry.js.map +1 -1
- package/dist/esm/ix-icon-button_2.entry.js +1 -1
- package/dist/esm/ix-icon-button_2.entry.js.map +1 -1
- package/dist/esm/ix-icon-toggle-button.entry.js +2 -2
- package/dist/esm/ix-icon-toggle-button.entry.js.map +1 -1
- package/dist/esm/ix-input-group.entry.js +16 -3
- package/dist/esm/ix-input-group.entry.js.map +1 -1
- package/dist/esm/ix-menu.entry.js.map +1 -1
- package/dist/esm/ix-modal.entry.js +2 -3
- package/dist/esm/ix-modal.entry.js.map +1 -1
- package/dist/esm/ix-pagination.entry.js +3 -3
- package/dist/esm/ix-pagination.entry.js.map +1 -1
- package/dist/esm/ix-slider.entry.js +1 -1
- package/dist/esm/ix-toggle-button.entry.js +1 -1
- package/dist/esm/ix-toggle.entry.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/siemens-ix.js +1 -1
- package/dist/siemens-ix/{p-4796a3ae.entry.js → p-042b8889.entry.js} +2 -2
- package/dist/siemens-ix/{p-b53bed3a.entry.js → p-228c5657.entry.js} +2 -2
- package/dist/siemens-ix/{p-fa0d5f4e.entry.js → p-28d29e36.entry.js} +2 -2
- package/dist/siemens-ix/p-2fd30d79.js +2 -0
- package/dist/siemens-ix/p-2fd30d79.js.map +1 -0
- package/dist/siemens-ix/p-302cd093.entry.js +2 -0
- package/dist/siemens-ix/{p-eb29049a.entry.js.map → p-302cd093.entry.js.map} +1 -1
- package/dist/siemens-ix/p-32265ee2.entry.js +2 -0
- package/dist/siemens-ix/p-32265ee2.entry.js.map +1 -0
- package/dist/siemens-ix/p-355f9085.entry.js +2 -0
- package/dist/siemens-ix/{p-74a7d191.entry.js.map → p-355f9085.entry.js.map} +1 -1
- package/dist/siemens-ix/p-574e3cd1.entry.js +2 -0
- package/dist/siemens-ix/p-574e3cd1.entry.js.map +1 -0
- package/dist/siemens-ix/p-59dc0873.entry.js +2 -0
- package/dist/siemens-ix/{p-90efad65.entry.js.map → p-59dc0873.entry.js.map} +1 -1
- package/dist/siemens-ix/p-7cc23245.entry.js +2 -0
- package/dist/siemens-ix/p-7cc23245.entry.js.map +1 -0
- package/dist/siemens-ix/p-9249df8d.entry.js +2 -0
- package/dist/siemens-ix/{p-d78cd3f4.entry.js.map → p-9249df8d.entry.js.map} +1 -1
- package/dist/siemens-ix/p-ad94f795.entry.js +2 -0
- package/dist/siemens-ix/p-ad94f795.entry.js.map +1 -0
- package/dist/siemens-ix/{p-0ebc6c4d.entry.js → p-b2042a15.entry.js} +2 -2
- package/dist/siemens-ix/p-b2042a15.entry.js.map +1 -0
- package/dist/siemens-ix/p-bd873b87.entry.js +2 -0
- package/dist/siemens-ix/p-bd873b87.entry.js.map +1 -0
- package/dist/siemens-ix/{p-6ae65cac.entry.js → p-c1318e16.entry.js} +2 -2
- package/dist/siemens-ix/p-c7e502d7.entry.js +2 -0
- package/dist/siemens-ix/p-c7e502d7.entry.js.map +1 -0
- package/dist/siemens-ix/p-dcb957d8.entry.js.map +1 -1
- package/dist/siemens-ix/{p-77b14ca1.entry.js → p-f304f7ce.entry.js} +2 -2
- package/dist/siemens-ix/p-fa7f3eef.entry.js +2 -0
- package/dist/siemens-ix/p-fa7f3eef.entry.js.map +1 -0
- package/dist/siemens-ix/siemens-ix-core.css +1 -1
- package/dist/siemens-ix/siemens-ix.css +12 -0
- package/dist/siemens-ix/siemens-ix.esm.js +1 -1
- package/dist/siemens-ix/siemens-ix.esm.js.map +1 -1
- package/dist/types/components/application-header/application-header.d.ts +1 -0
- package/dist/types/components/breadcrumb-item/breadcrumb-item.d.ts +2 -0
- package/dist/types/components/input-group/input-group.d.ts +1 -0
- package/dist/types/components/input-group/tests/input-group.ct.d.ts +1 -0
- package/dist/types/components/menu/menu.d.ts +2 -0
- package/dist/types/components.d.ts +2 -0
- package/package.json +1 -1
- package/scss/components/_checkboxes.scss +3 -0
- package/scss/components/_radiobuttons.scss +5 -0
- package/dist/cjs/a11y-4fdcefb4.js.map +0 -1
- package/dist/esm/a11y-d5dd20ad.js.map +0 -1
- package/dist/siemens-ix/p-0ebc6c4d.entry.js.map +0 -1
- package/dist/siemens-ix/p-2e75f0e4.entry.js +0 -2
- package/dist/siemens-ix/p-2e75f0e4.entry.js.map +0 -1
- package/dist/siemens-ix/p-66d7fbd9.entry.js +0 -2
- package/dist/siemens-ix/p-66d7fbd9.entry.js.map +0 -1
- package/dist/siemens-ix/p-74a7d191.entry.js +0 -2
- package/dist/siemens-ix/p-774eca79.entry.js +0 -2
- package/dist/siemens-ix/p-774eca79.entry.js.map +0 -1
- package/dist/siemens-ix/p-78c9489b.js +0 -2
- package/dist/siemens-ix/p-78c9489b.js.map +0 -1
- package/dist/siemens-ix/p-7a884056.entry.js +0 -2
- package/dist/siemens-ix/p-7a884056.entry.js.map +0 -1
- package/dist/siemens-ix/p-7b362f58.entry.js +0 -2
- package/dist/siemens-ix/p-7b362f58.entry.js.map +0 -1
- package/dist/siemens-ix/p-90efad65.entry.js +0 -2
- package/dist/siemens-ix/p-d78cd3f4.entry.js +0 -2
- package/dist/siemens-ix/p-d9c99b88.entry.js +0 -2
- package/dist/siemens-ix/p-d9c99b88.entry.js.map +0 -1
- package/dist/siemens-ix/p-eb29049a.entry.js +0 -2
- package/dist/siemens-ix/p-f7b95fd7.entry.js +0 -2
- package/dist/siemens-ix/p-f7b95fd7.entry.js.map +0 -1
- /package/dist/siemens-ix/{p-4796a3ae.entry.js.map → p-042b8889.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-b53bed3a.entry.js.map → p-228c5657.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-fa0d5f4e.entry.js.map → p-28d29e36.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-6ae65cac.entry.js.map → p-c1318e16.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-77b14ca1.entry.js.map → p-f304f7ce.entry.js.map} +0 -0
|
@@ -0,0 +1,727 @@
|
|
|
1
|
+
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
|
+
import { c as createCommonjsModule, g as getDefaultExportFromCjs, a as commonjsRequire } from './_commonjsHelpers.js';
|
|
3
|
+
import { r as renderDefaultItem } from './default-tree-item.js';
|
|
4
|
+
import { d as defineCustomElement$2 } from './tree-item.js';
|
|
5
|
+
|
|
6
|
+
var hyperlist = createCommonjsModule(function (module, exports) {
|
|
7
|
+
(function(f){{module.exports=f();}})(function(){return (function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof commonjsRequire&&commonjsRequire;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t);}return n[i].exports}for(var u="function"==typeof commonjsRequire&&commonjsRequire,i=0;i<t.length;i++)o(t[i]);return o}return r})()({1:[function(_dereq_,module,exports){
|
|
8
|
+
|
|
9
|
+
// Default configuration.
|
|
10
|
+
|
|
11
|
+
Object.defineProperty(exports, "__esModule", {
|
|
12
|
+
value: true
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
16
|
+
|
|
17
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
18
|
+
|
|
19
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
20
|
+
|
|
21
|
+
var defaultConfig = {
|
|
22
|
+
width: '100%',
|
|
23
|
+
height: '100%'
|
|
24
|
+
|
|
25
|
+
// Check for valid number.
|
|
26
|
+
};var isNumber = function isNumber(input) {
|
|
27
|
+
return Number(input) === Number(input);
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
// Add a class to an element.
|
|
31
|
+
var addClass = 'classList' in document.documentElement ? function (element, className) {
|
|
32
|
+
element.classList.add(className);
|
|
33
|
+
} : function (element, className) {
|
|
34
|
+
var oldClass = element.getAttribute('class') || '';
|
|
35
|
+
element.setAttribute('class', oldClass + ' ' + className);
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Creates a HyperList instance that virtually scrolls very large amounts of
|
|
40
|
+
* data effortlessly.
|
|
41
|
+
*/
|
|
42
|
+
|
|
43
|
+
var HyperList = function () {
|
|
44
|
+
_createClass(HyperList, null, [{
|
|
45
|
+
key: 'create',
|
|
46
|
+
value: function create(element, userProvidedConfig) {
|
|
47
|
+
return new HyperList(element, userProvidedConfig);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Merge given css style on an element
|
|
52
|
+
* @param {DOMElement} element
|
|
53
|
+
* @param {Object} style
|
|
54
|
+
*/
|
|
55
|
+
|
|
56
|
+
}, {
|
|
57
|
+
key: 'mergeStyle',
|
|
58
|
+
value: function mergeStyle(element, style) {
|
|
59
|
+
for (var i in style) {
|
|
60
|
+
if (element.style[i] !== style[i]) {
|
|
61
|
+
element.style[i] = style[i];
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}, {
|
|
66
|
+
key: 'getMaxBrowserHeight',
|
|
67
|
+
value: function getMaxBrowserHeight() {
|
|
68
|
+
// Create two elements, the wrapper is `1px` tall and is transparent and
|
|
69
|
+
// positioned at the top of the page. Inside that is an element that gets
|
|
70
|
+
// set to 1 billion pixels. Then reads the max height the browser can
|
|
71
|
+
// calculate.
|
|
72
|
+
var wrapper = document.createElement('div');
|
|
73
|
+
var fixture = document.createElement('div');
|
|
74
|
+
|
|
75
|
+
// As said above, these values get set to put the fixture elements into the
|
|
76
|
+
// right visual state.
|
|
77
|
+
HyperList.mergeStyle(wrapper, { position: 'absolute', height: '1px', opacity: 0 });
|
|
78
|
+
HyperList.mergeStyle(fixture, { height: '1e7px' });
|
|
79
|
+
|
|
80
|
+
// Add the fixture into the wrapper element.
|
|
81
|
+
wrapper.appendChild(fixture);
|
|
82
|
+
|
|
83
|
+
// Apply to the page, the values won't kick in unless this is attached.
|
|
84
|
+
document.body.appendChild(wrapper);
|
|
85
|
+
|
|
86
|
+
// Get the maximum element height in pixels.
|
|
87
|
+
var maxElementHeight = fixture.offsetHeight;
|
|
88
|
+
|
|
89
|
+
// Remove the element immediately after reading the value.
|
|
90
|
+
document.body.removeChild(wrapper);
|
|
91
|
+
|
|
92
|
+
return maxElementHeight;
|
|
93
|
+
}
|
|
94
|
+
}]);
|
|
95
|
+
|
|
96
|
+
function HyperList(element, userProvidedConfig) {
|
|
97
|
+
var _this = this;
|
|
98
|
+
|
|
99
|
+
_classCallCheck(this, HyperList);
|
|
100
|
+
|
|
101
|
+
this._config = {};
|
|
102
|
+
this._lastRepaint = null;
|
|
103
|
+
this._maxElementHeight = HyperList.getMaxBrowserHeight();
|
|
104
|
+
|
|
105
|
+
this.refresh(element, userProvidedConfig);
|
|
106
|
+
|
|
107
|
+
var config = this._config;
|
|
108
|
+
|
|
109
|
+
// Create internal render loop.
|
|
110
|
+
var render = function render() {
|
|
111
|
+
var scrollTop = _this._getScrollPosition();
|
|
112
|
+
var lastRepaint = _this._lastRepaint;
|
|
113
|
+
|
|
114
|
+
_this._renderAnimationFrame = window.requestAnimationFrame(render);
|
|
115
|
+
|
|
116
|
+
if (scrollTop === lastRepaint) {
|
|
117
|
+
return;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
var diff = lastRepaint ? scrollTop - lastRepaint : 0;
|
|
121
|
+
if (!lastRepaint || diff < 0 || diff > _this._averageHeight) {
|
|
122
|
+
var rendered = _this._renderChunk();
|
|
123
|
+
|
|
124
|
+
_this._lastRepaint = scrollTop;
|
|
125
|
+
|
|
126
|
+
if (rendered !== false && typeof config.afterRender === 'function') {
|
|
127
|
+
config.afterRender();
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
};
|
|
131
|
+
|
|
132
|
+
render();
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
_createClass(HyperList, [{
|
|
136
|
+
key: 'destroy',
|
|
137
|
+
value: function destroy() {
|
|
138
|
+
window.cancelAnimationFrame(this._renderAnimationFrame);
|
|
139
|
+
}
|
|
140
|
+
}, {
|
|
141
|
+
key: 'refresh',
|
|
142
|
+
value: function refresh(element, userProvidedConfig) {
|
|
143
|
+
var _scrollerStyle;
|
|
144
|
+
|
|
145
|
+
Object.assign(this._config, defaultConfig, userProvidedConfig);
|
|
146
|
+
|
|
147
|
+
if (!element || element.nodeType !== 1) {
|
|
148
|
+
throw new Error('HyperList requires a valid DOM Node container');
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
this._element = element;
|
|
152
|
+
|
|
153
|
+
var config = this._config;
|
|
154
|
+
|
|
155
|
+
var scroller = this._scroller || config.scroller || document.createElement(config.scrollerTagName || 'tr');
|
|
156
|
+
|
|
157
|
+
// Default configuration option `useFragment` to `true`.
|
|
158
|
+
if (typeof config.useFragment !== 'boolean') {
|
|
159
|
+
this._config.useFragment = true;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
if (!config.generate) {
|
|
163
|
+
throw new Error('Missing required `generate` function');
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
if (!isNumber(config.total)) {
|
|
167
|
+
throw new Error('Invalid required `total` value, expected number');
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
if (!Array.isArray(config.itemHeight) && !isNumber(config.itemHeight)) {
|
|
171
|
+
throw new Error('\n Invalid required `itemHeight` value, expected number or array\n '.trim());
|
|
172
|
+
} else if (isNumber(config.itemHeight)) {
|
|
173
|
+
this._itemHeights = Array(config.total).fill(config.itemHeight);
|
|
174
|
+
} else {
|
|
175
|
+
this._itemHeights = config.itemHeight;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
// Width and height should be coerced to string representations. Either in
|
|
179
|
+
// `%` or `px`.
|
|
180
|
+
Object.keys(defaultConfig).filter(function (prop) {
|
|
181
|
+
return prop in config;
|
|
182
|
+
}).forEach(function (prop) {
|
|
183
|
+
var value = config[prop];
|
|
184
|
+
var isValueNumber = isNumber(value);
|
|
185
|
+
|
|
186
|
+
if (value && typeof value !== 'string' && typeof value !== 'number') {
|
|
187
|
+
var msg = 'Invalid optional `' + prop + '`, expected string or number';
|
|
188
|
+
throw new Error(msg);
|
|
189
|
+
} else if (isValueNumber) {
|
|
190
|
+
config[prop] = value + 'px';
|
|
191
|
+
}
|
|
192
|
+
});
|
|
193
|
+
|
|
194
|
+
var isHoriz = Boolean(config.horizontal);
|
|
195
|
+
var value = config[isHoriz ? 'width' : 'height'];
|
|
196
|
+
|
|
197
|
+
if (value) {
|
|
198
|
+
var isValueNumber = isNumber(value);
|
|
199
|
+
var isValuePercent = isValueNumber ? false : value.slice(-1) === '%';
|
|
200
|
+
// Compute the containerHeight as number
|
|
201
|
+
var numberValue = isValueNumber ? value : parseInt(value.replace(/px|%/, ''), 10);
|
|
202
|
+
var innerSize = window[isHoriz ? 'innerWidth' : 'innerHeight'];
|
|
203
|
+
|
|
204
|
+
if (isValuePercent) {
|
|
205
|
+
this._containerSize = innerSize * numberValue / 100;
|
|
206
|
+
} else {
|
|
207
|
+
this._containerSize = isNumber(value) ? value : numberValue;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
var scrollContainer = config.scrollContainer;
|
|
212
|
+
var scrollerHeight = config.itemHeight * config.total;
|
|
213
|
+
var maxElementHeight = this._maxElementHeight;
|
|
214
|
+
|
|
215
|
+
if (scrollerHeight > maxElementHeight) {
|
|
216
|
+
console.warn(['HyperList: The maximum element height', maxElementHeight + 'px has', 'been exceeded; please reduce your item height.'].join(' '));
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
// Decorate the container element with styles that will match
|
|
220
|
+
// the user supplied configuration.
|
|
221
|
+
var elementStyle = {
|
|
222
|
+
width: '' + config.width,
|
|
223
|
+
height: scrollContainer ? scrollerHeight + 'px' : '' + config.height,
|
|
224
|
+
overflow: scrollContainer ? 'none' : 'auto',
|
|
225
|
+
position: 'relative'
|
|
226
|
+
};
|
|
227
|
+
|
|
228
|
+
HyperList.mergeStyle(element, elementStyle);
|
|
229
|
+
|
|
230
|
+
if (scrollContainer) {
|
|
231
|
+
HyperList.mergeStyle(config.scrollContainer, { overflow: 'auto' });
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
var scrollerStyle = (_scrollerStyle = {
|
|
235
|
+
opacity: '0',
|
|
236
|
+
position: 'absolute'
|
|
237
|
+
}, _defineProperty(_scrollerStyle, isHoriz ? 'height' : 'width', '1px'), _defineProperty(_scrollerStyle, isHoriz ? 'width' : 'height', scrollerHeight + 'px'), _scrollerStyle);
|
|
238
|
+
|
|
239
|
+
HyperList.mergeStyle(scroller, scrollerStyle);
|
|
240
|
+
|
|
241
|
+
// Only append the scroller element once.
|
|
242
|
+
if (!this._scroller) {
|
|
243
|
+
element.appendChild(scroller);
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
var padding = this._computeScrollPadding();
|
|
247
|
+
this._scrollPaddingBottom = padding.bottom;
|
|
248
|
+
this._scrollPaddingTop = padding.top;
|
|
249
|
+
|
|
250
|
+
// Set the scroller instance.
|
|
251
|
+
this._scroller = scroller;
|
|
252
|
+
this._scrollHeight = this._computeScrollHeight();
|
|
253
|
+
|
|
254
|
+
// Reuse the item positions if refreshed, otherwise set to empty array.
|
|
255
|
+
this._itemPositions = this._itemPositions || Array(config.total).fill(0);
|
|
256
|
+
|
|
257
|
+
// Each index in the array should represent the position in the DOM.
|
|
258
|
+
this._computePositions(0);
|
|
259
|
+
|
|
260
|
+
// Render after refreshing. Force render if we're calling refresh manually.
|
|
261
|
+
this._renderChunk(this._lastRepaint !== null);
|
|
262
|
+
|
|
263
|
+
if (typeof config.afterRender === 'function') {
|
|
264
|
+
config.afterRender();
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
}, {
|
|
268
|
+
key: '_getRow',
|
|
269
|
+
value: function _getRow(i) {
|
|
270
|
+
var config = this._config;
|
|
271
|
+
var item = config.generate(i);
|
|
272
|
+
var height = item.height;
|
|
273
|
+
|
|
274
|
+
if (height !== undefined && isNumber(height)) {
|
|
275
|
+
item = item.element;
|
|
276
|
+
|
|
277
|
+
// The height isn't the same as predicted, compute positions again
|
|
278
|
+
if (height !== this._itemHeights[i]) {
|
|
279
|
+
this._itemHeights[i] = height;
|
|
280
|
+
this._computePositions(i);
|
|
281
|
+
this._scrollHeight = this._computeScrollHeight(i);
|
|
282
|
+
}
|
|
283
|
+
} else {
|
|
284
|
+
height = this._itemHeights[i];
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
if (!item || item.nodeType !== 1) {
|
|
288
|
+
throw new Error('Generator did not return a DOM Node for index: ' + i);
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
addClass(item, config.rowClassName || 'vrow');
|
|
292
|
+
|
|
293
|
+
var top = this._itemPositions[i] + this._scrollPaddingTop;
|
|
294
|
+
|
|
295
|
+
HyperList.mergeStyle(item, _defineProperty({
|
|
296
|
+
position: 'absolute'
|
|
297
|
+
}, config.horizontal ? 'left' : 'top', top + 'px'));
|
|
298
|
+
|
|
299
|
+
return item;
|
|
300
|
+
}
|
|
301
|
+
}, {
|
|
302
|
+
key: '_getScrollPosition',
|
|
303
|
+
value: function _getScrollPosition() {
|
|
304
|
+
var config = this._config;
|
|
305
|
+
|
|
306
|
+
if (typeof config.overrideScrollPosition === 'function') {
|
|
307
|
+
return config.overrideScrollPosition();
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
return this._element[config.horizontal ? 'scrollLeft' : 'scrollTop'];
|
|
311
|
+
}
|
|
312
|
+
}, {
|
|
313
|
+
key: '_renderChunk',
|
|
314
|
+
value: function _renderChunk(force) {
|
|
315
|
+
var config = this._config;
|
|
316
|
+
var element = this._element;
|
|
317
|
+
var scrollTop = this._getScrollPosition();
|
|
318
|
+
var total = config.total;
|
|
319
|
+
|
|
320
|
+
var from = config.reverse ? this._getReverseFrom(scrollTop) : this._getFrom(scrollTop) - 1;
|
|
321
|
+
|
|
322
|
+
if (from < 0 || from - this._screenItemsLen < 0) {
|
|
323
|
+
from = 0;
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
if (!force && this._lastFrom === from) {
|
|
327
|
+
return false;
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
this._lastFrom = from;
|
|
331
|
+
|
|
332
|
+
var to = from + this._cachedItemsLen;
|
|
333
|
+
|
|
334
|
+
if (to > total || to + this._cachedItemsLen > total) {
|
|
335
|
+
to = total;
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
// Append all the new rows in a document fragment that we will later append
|
|
339
|
+
// to the parent node
|
|
340
|
+
var fragment = config.useFragment ? document.createDocumentFragment() : []
|
|
341
|
+
// Sometimes you'll pass fake elements to this tool and Fragments require
|
|
342
|
+
// real elements.
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
// The element that forces the container to scroll.
|
|
346
|
+
;var scroller = this._scroller;
|
|
347
|
+
|
|
348
|
+
// Keep the scroller in the list of children.
|
|
349
|
+
fragment[config.useFragment ? 'appendChild' : 'push'](scroller);
|
|
350
|
+
|
|
351
|
+
for (var i = from; i < to; i++) {
|
|
352
|
+
var row = this._getRow(i);
|
|
353
|
+
|
|
354
|
+
fragment[config.useFragment ? 'appendChild' : 'push'](row);
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
if (config.applyPatch) {
|
|
358
|
+
return config.applyPatch(element, fragment);
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
element.innerHTML = '';
|
|
362
|
+
element.appendChild(fragment);
|
|
363
|
+
}
|
|
364
|
+
}, {
|
|
365
|
+
key: '_computePositions',
|
|
366
|
+
value: function _computePositions() {
|
|
367
|
+
var from = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1;
|
|
368
|
+
|
|
369
|
+
var config = this._config;
|
|
370
|
+
var total = config.total;
|
|
371
|
+
var reverse = config.reverse;
|
|
372
|
+
|
|
373
|
+
if (from < 1 && !reverse) {
|
|
374
|
+
from = 1;
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
for (var i = from; i < total; i++) {
|
|
378
|
+
if (reverse) {
|
|
379
|
+
if (i === 0) {
|
|
380
|
+
this._itemPositions[0] = this._scrollHeight - this._itemHeights[0];
|
|
381
|
+
} else {
|
|
382
|
+
this._itemPositions[i] = this._itemPositions[i - 1] - this._itemHeights[i];
|
|
383
|
+
}
|
|
384
|
+
} else {
|
|
385
|
+
this._itemPositions[i] = this._itemHeights[i - 1] + this._itemPositions[i - 1];
|
|
386
|
+
}
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
}, {
|
|
390
|
+
key: '_computeScrollHeight',
|
|
391
|
+
value: function _computeScrollHeight() {
|
|
392
|
+
var _HyperList$mergeStyle2,
|
|
393
|
+
_this2 = this;
|
|
394
|
+
|
|
395
|
+
var config = this._config;
|
|
396
|
+
var isHoriz = Boolean(config.horizontal);
|
|
397
|
+
var total = config.total;
|
|
398
|
+
var scrollHeight = this._itemHeights.reduce(function (a, b) {
|
|
399
|
+
return a + b;
|
|
400
|
+
}, 0) + this._scrollPaddingBottom + this._scrollPaddingTop;
|
|
401
|
+
|
|
402
|
+
HyperList.mergeStyle(this._scroller, (_HyperList$mergeStyle2 = {
|
|
403
|
+
opacity: 0,
|
|
404
|
+
position: 'absolute',
|
|
405
|
+
top: '0px'
|
|
406
|
+
}, _defineProperty(_HyperList$mergeStyle2, isHoriz ? 'height' : 'width', '1px'), _defineProperty(_HyperList$mergeStyle2, isHoriz ? 'width' : 'height', scrollHeight + 'px'), _HyperList$mergeStyle2));
|
|
407
|
+
|
|
408
|
+
// Calculate the height median
|
|
409
|
+
var sortedItemHeights = this._itemHeights.slice(0).sort(function (a, b) {
|
|
410
|
+
return a - b;
|
|
411
|
+
});
|
|
412
|
+
var middle = Math.floor(total / 2);
|
|
413
|
+
var averageHeight = total % 2 === 0 ? (sortedItemHeights[middle] + sortedItemHeights[middle - 1]) / 2 : sortedItemHeights[middle];
|
|
414
|
+
|
|
415
|
+
var clientProp = isHoriz ? 'clientWidth' : 'clientHeight';
|
|
416
|
+
var element = config.scrollContainer ? config.scrollContainer : this._element;
|
|
417
|
+
var containerHeight = element[clientProp] ? element[clientProp] : this._containerSize;
|
|
418
|
+
this._screenItemsLen = Math.ceil(containerHeight / averageHeight);
|
|
419
|
+
this._containerSize = containerHeight;
|
|
420
|
+
|
|
421
|
+
// Cache 3 times the number of items that fit in the container viewport.
|
|
422
|
+
this._cachedItemsLen = Math.max(this._cachedItemsLen || 0, this._screenItemsLen * 3);
|
|
423
|
+
this._averageHeight = averageHeight;
|
|
424
|
+
|
|
425
|
+
if (config.reverse) {
|
|
426
|
+
window.requestAnimationFrame(function () {
|
|
427
|
+
if (isHoriz) {
|
|
428
|
+
_this2._element.scrollLeft = scrollHeight;
|
|
429
|
+
} else {
|
|
430
|
+
_this2._element.scrollTop = scrollHeight;
|
|
431
|
+
}
|
|
432
|
+
});
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
return scrollHeight;
|
|
436
|
+
}
|
|
437
|
+
}, {
|
|
438
|
+
key: '_computeScrollPadding',
|
|
439
|
+
value: function _computeScrollPadding() {
|
|
440
|
+
var config = this._config;
|
|
441
|
+
var isHoriz = Boolean(config.horizontal);
|
|
442
|
+
var isReverse = config.reverse;
|
|
443
|
+
var styles = window.getComputedStyle(this._element);
|
|
444
|
+
|
|
445
|
+
var padding = function padding(location) {
|
|
446
|
+
var cssValue = styles.getPropertyValue('padding-' + location);
|
|
447
|
+
return parseInt(cssValue, 10) || 0;
|
|
448
|
+
};
|
|
449
|
+
|
|
450
|
+
if (isHoriz && isReverse) {
|
|
451
|
+
return {
|
|
452
|
+
bottom: padding('left'),
|
|
453
|
+
top: padding('right')
|
|
454
|
+
};
|
|
455
|
+
} else if (isHoriz) {
|
|
456
|
+
return {
|
|
457
|
+
bottom: padding('right'),
|
|
458
|
+
top: padding('left')
|
|
459
|
+
};
|
|
460
|
+
} else if (isReverse) {
|
|
461
|
+
return {
|
|
462
|
+
bottom: padding('top'),
|
|
463
|
+
top: padding('bottom')
|
|
464
|
+
};
|
|
465
|
+
} else {
|
|
466
|
+
return {
|
|
467
|
+
bottom: padding('bottom'),
|
|
468
|
+
top: padding('top')
|
|
469
|
+
};
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
}, {
|
|
473
|
+
key: '_getFrom',
|
|
474
|
+
value: function _getFrom(scrollTop) {
|
|
475
|
+
var i = 0;
|
|
476
|
+
|
|
477
|
+
while (this._itemPositions[i] < scrollTop) {
|
|
478
|
+
i++;
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
return i;
|
|
482
|
+
}
|
|
483
|
+
}, {
|
|
484
|
+
key: '_getReverseFrom',
|
|
485
|
+
value: function _getReverseFrom(scrollTop) {
|
|
486
|
+
var i = this._config.total - 1;
|
|
487
|
+
|
|
488
|
+
while (i > 0 && this._itemPositions[i] < scrollTop + this._containerSize) {
|
|
489
|
+
i--;
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
return i;
|
|
493
|
+
}
|
|
494
|
+
}]);
|
|
495
|
+
|
|
496
|
+
return HyperList;
|
|
497
|
+
}();
|
|
498
|
+
|
|
499
|
+
exports.default = HyperList;
|
|
500
|
+
module.exports = exports['default'];
|
|
501
|
+
|
|
502
|
+
},{}]},{},[1])(1)
|
|
503
|
+
});
|
|
504
|
+
});
|
|
505
|
+
|
|
506
|
+
const Hyperlist = /*@__PURE__*/getDefaultExportFromCjs(hyperlist);
|
|
507
|
+
|
|
508
|
+
const treeCss = ":host{display:block}";
|
|
509
|
+
|
|
510
|
+
const Tree = /*@__PURE__*/ proxyCustomElement(class Tree extends HTMLElement {
|
|
511
|
+
constructor() {
|
|
512
|
+
super();
|
|
513
|
+
this.__registerHost();
|
|
514
|
+
this.__attachShadow();
|
|
515
|
+
this.contextChange = createEvent(this, "contextChange", 7);
|
|
516
|
+
this.nodeToggled = createEvent(this, "nodeToggled", 7);
|
|
517
|
+
this.nodeClicked = createEvent(this, "nodeClicked", 7);
|
|
518
|
+
this.nodeRemoved = createEvent(this, "nodeRemoved", 7);
|
|
519
|
+
this.toggleListener = new Map();
|
|
520
|
+
this.itemClickListener = new Map();
|
|
521
|
+
this.updates = new Map();
|
|
522
|
+
this.hasFirstRender = false;
|
|
523
|
+
this.root = undefined;
|
|
524
|
+
this.model = undefined;
|
|
525
|
+
this.renderItem = undefined;
|
|
526
|
+
this.context = {};
|
|
527
|
+
}
|
|
528
|
+
updatePadding(element, item) {
|
|
529
|
+
element.style.paddingLeft = item.level + 'rem';
|
|
530
|
+
}
|
|
531
|
+
getVirtualizerOptions() {
|
|
532
|
+
const list = this.buildTreeList(this.model[this.root]);
|
|
533
|
+
let setToggleListener = (item, el, index) => {
|
|
534
|
+
if (item.hasChildren && !this.toggleListener.has(el)) {
|
|
535
|
+
const toggleCallback = (e) => {
|
|
536
|
+
e.preventDefault();
|
|
537
|
+
e.stopPropagation();
|
|
538
|
+
const context = this.getContext(list[index].id);
|
|
539
|
+
context.isExpanded = !context.isExpanded;
|
|
540
|
+
this.nodeToggled.emit({ id: item.id, isExpaned: context.isExpanded });
|
|
541
|
+
this.setContext(item.id, context);
|
|
542
|
+
};
|
|
543
|
+
el.addEventListener('toggle', toggleCallback);
|
|
544
|
+
this.toggleListener.set(el, toggleCallback);
|
|
545
|
+
}
|
|
546
|
+
};
|
|
547
|
+
return {
|
|
548
|
+
itemHeight: 32,
|
|
549
|
+
total: list.length,
|
|
550
|
+
generate: (index) => {
|
|
551
|
+
const item = list[index];
|
|
552
|
+
const renderedTreeItem = this.hostElement.querySelector(`[data-tree-node-id="${item.id}"]`);
|
|
553
|
+
const context = this.getContext(item.id);
|
|
554
|
+
if (renderedTreeItem) {
|
|
555
|
+
renderedTreeItem.hasChildren = item.hasChildren;
|
|
556
|
+
renderedTreeItem.context = Object.assign({}, context);
|
|
557
|
+
setToggleListener(item, renderedTreeItem, index);
|
|
558
|
+
if (this.updates.has(item.id)) {
|
|
559
|
+
const doUpdate = this.updates.get(item.id);
|
|
560
|
+
doUpdate(item, Object.assign({}, this.context));
|
|
561
|
+
}
|
|
562
|
+
this.updatePadding(renderedTreeItem, item);
|
|
563
|
+
return renderedTreeItem;
|
|
564
|
+
}
|
|
565
|
+
const update = (callback) => {
|
|
566
|
+
this.updates.set(item.id, callback);
|
|
567
|
+
};
|
|
568
|
+
let innerElement = null;
|
|
569
|
+
if (this.renderItem) {
|
|
570
|
+
innerElement = this.renderItem(index, item, list, Object.assign({}, this.context), update);
|
|
571
|
+
}
|
|
572
|
+
if (innerElement === null) {
|
|
573
|
+
innerElement = renderDefaultItem(item, context, update);
|
|
574
|
+
}
|
|
575
|
+
const el = innerElement;
|
|
576
|
+
el.setAttribute('data-tree-node-id', item.id);
|
|
577
|
+
el.style.paddingRight = '1rem';
|
|
578
|
+
this.updatePadding(el, item);
|
|
579
|
+
if (!this.itemClickListener.has(el)) {
|
|
580
|
+
const itemClickCallback = (e) => {
|
|
581
|
+
e.preventDefault();
|
|
582
|
+
e.stopPropagation();
|
|
583
|
+
Object.values(this.context).forEach((c) => (c.isSelected = false));
|
|
584
|
+
const context = this.getContext(item.id);
|
|
585
|
+
context.isSelected = true;
|
|
586
|
+
this.setContext(item.id, context);
|
|
587
|
+
this.nodeClicked.emit(item.id);
|
|
588
|
+
};
|
|
589
|
+
el.addEventListener('itemClick', itemClickCallback);
|
|
590
|
+
this.itemClickListener.set(el, itemClickCallback);
|
|
591
|
+
}
|
|
592
|
+
setToggleListener(item, el, index);
|
|
593
|
+
return el;
|
|
594
|
+
},
|
|
595
|
+
};
|
|
596
|
+
}
|
|
597
|
+
setContext(id, context) {
|
|
598
|
+
this.context = Object.assign(Object.assign({}, this.context), { [id]: context });
|
|
599
|
+
this.contextChange.emit(this.context);
|
|
600
|
+
}
|
|
601
|
+
getContext(id) {
|
|
602
|
+
if (!this.context) {
|
|
603
|
+
return {
|
|
604
|
+
isExpanded: false,
|
|
605
|
+
isSelected: false,
|
|
606
|
+
};
|
|
607
|
+
}
|
|
608
|
+
if (!this.context[id]) {
|
|
609
|
+
this.context[id] = {
|
|
610
|
+
isExpanded: false,
|
|
611
|
+
isSelected: false,
|
|
612
|
+
};
|
|
613
|
+
}
|
|
614
|
+
return this.context[id];
|
|
615
|
+
}
|
|
616
|
+
buildTreeList(root, level = 0) {
|
|
617
|
+
const itemList = [];
|
|
618
|
+
if (root === null || root === void 0 ? void 0 : root.hasChildren) {
|
|
619
|
+
const newLevel = level + 1;
|
|
620
|
+
root.children.forEach((id) => {
|
|
621
|
+
const item = this.model[id];
|
|
622
|
+
const context = this.getContext(id);
|
|
623
|
+
itemList.push(Object.assign(Object.assign({}, item), { level }));
|
|
624
|
+
if (item.hasChildren && context.isExpanded) {
|
|
625
|
+
itemList.push(...this.buildTreeList(item, newLevel));
|
|
626
|
+
}
|
|
627
|
+
});
|
|
628
|
+
}
|
|
629
|
+
return itemList;
|
|
630
|
+
}
|
|
631
|
+
componentDidLoad() {
|
|
632
|
+
this.initList();
|
|
633
|
+
this.observer = new MutationObserver((records) => {
|
|
634
|
+
let removed = [];
|
|
635
|
+
records.forEach((record) => {
|
|
636
|
+
removed = [...removed, ...Array.from(record.removedNodes)];
|
|
637
|
+
record.addedNodes.forEach((an) => {
|
|
638
|
+
const index = removed.indexOf(an);
|
|
639
|
+
if (index >= 0) {
|
|
640
|
+
removed.splice(index, 1);
|
|
641
|
+
}
|
|
642
|
+
});
|
|
643
|
+
});
|
|
644
|
+
this.nodeRemoved.emit(removed);
|
|
645
|
+
});
|
|
646
|
+
this.observer.observe(this.hostElement, {
|
|
647
|
+
childList: true,
|
|
648
|
+
});
|
|
649
|
+
}
|
|
650
|
+
componentWillRender() {
|
|
651
|
+
this.hasFirstRender = true;
|
|
652
|
+
if (this.isListInitialized()) {
|
|
653
|
+
this.refreshList();
|
|
654
|
+
}
|
|
655
|
+
else {
|
|
656
|
+
this.initList();
|
|
657
|
+
}
|
|
658
|
+
}
|
|
659
|
+
disconnectedCallback() {
|
|
660
|
+
this.hyperlist.destroy();
|
|
661
|
+
this.observer.disconnect();
|
|
662
|
+
}
|
|
663
|
+
modelChange() {
|
|
664
|
+
if (this.hasFirstRender && !this.isListInitialized()) {
|
|
665
|
+
this.initList();
|
|
666
|
+
}
|
|
667
|
+
}
|
|
668
|
+
isListInitialized() {
|
|
669
|
+
var _a;
|
|
670
|
+
const itemPositions = (_a = this.hyperlist) === null || _a === void 0 ? void 0 : _a._itemPositions;
|
|
671
|
+
return (itemPositions !== undefined &&
|
|
672
|
+
itemPositions.length &&
|
|
673
|
+
!(itemPositions === null || itemPositions === void 0 ? void 0 : itemPositions.some((item) => item === undefined || Number.isNaN(item))));
|
|
674
|
+
}
|
|
675
|
+
refreshList() {
|
|
676
|
+
if (this.hyperlist) {
|
|
677
|
+
this.hyperlist.refresh(this.hostElement, this.getVirtualizerOptions());
|
|
678
|
+
}
|
|
679
|
+
}
|
|
680
|
+
initList() {
|
|
681
|
+
var _a;
|
|
682
|
+
if (!this.model) {
|
|
683
|
+
return;
|
|
684
|
+
}
|
|
685
|
+
(_a = this.hyperlist) === null || _a === void 0 ? void 0 : _a.destroy();
|
|
686
|
+
const config = this.getVirtualizerOptions();
|
|
687
|
+
this.hyperlist = new Hyperlist(this.hostElement, config);
|
|
688
|
+
}
|
|
689
|
+
render() {
|
|
690
|
+
return (h(Host, null, h("slot", null)));
|
|
691
|
+
}
|
|
692
|
+
get hostElement() { return this; }
|
|
693
|
+
static get watchers() { return {
|
|
694
|
+
"model": ["modelChange"]
|
|
695
|
+
}; }
|
|
696
|
+
static get style() { return treeCss; }
|
|
697
|
+
}, [1, "ix-tree", {
|
|
698
|
+
"root": [1],
|
|
699
|
+
"model": [16],
|
|
700
|
+
"renderItem": [16],
|
|
701
|
+
"context": [1040]
|
|
702
|
+
}]);
|
|
703
|
+
function defineCustomElement$1() {
|
|
704
|
+
if (typeof customElements === "undefined") {
|
|
705
|
+
return;
|
|
706
|
+
}
|
|
707
|
+
const components = ["ix-tree", "ix-tree-item"];
|
|
708
|
+
components.forEach(tagName => { switch (tagName) {
|
|
709
|
+
case "ix-tree":
|
|
710
|
+
if (!customElements.get(tagName)) {
|
|
711
|
+
customElements.define(tagName, Tree);
|
|
712
|
+
}
|
|
713
|
+
break;
|
|
714
|
+
case "ix-tree-item":
|
|
715
|
+
if (!customElements.get(tagName)) {
|
|
716
|
+
defineCustomElement$2();
|
|
717
|
+
}
|
|
718
|
+
break;
|
|
719
|
+
} });
|
|
720
|
+
}
|
|
721
|
+
|
|
722
|
+
const IxTree = Tree;
|
|
723
|
+
const defineCustomElement = defineCustomElement$1;
|
|
724
|
+
|
|
725
|
+
export { IxTree, defineCustomElement };
|
|
726
|
+
|
|
727
|
+
//# sourceMappingURL=ix-tree.js.map
|