@aquera/nile-elements 1.6.2 → 1.6.4
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/README.md +16 -0
- package/demo/variables.css +1 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.js +527 -339
- package/dist/internal/accessibility/a11y.custom-value.enum.cjs.js +2 -0
- package/dist/internal/accessibility/a11y.custom-value.enum.cjs.js.map +1 -0
- package/dist/internal/accessibility/a11y.custom-value.enum.esm.js +1 -0
- package/dist/internal/accessibility/a11y.property.enum.cjs.js +2 -0
- package/dist/internal/accessibility/a11y.property.enum.cjs.js.map +1 -0
- package/dist/internal/accessibility/a11y.property.enum.esm.js +1 -0
- package/dist/internal/accessibility/a11y.role.enum.cjs.js +2 -0
- package/dist/internal/accessibility/a11y.role.enum.cjs.js.map +1 -0
- package/dist/internal/accessibility/a11y.role.enum.esm.js +1 -0
- package/dist/internal/accessibility/a11y.state.enum.cjs.js +2 -0
- package/dist/internal/accessibility/a11y.state.enum.cjs.js.map +1 -0
- package/dist/internal/accessibility/a11y.state.enum.esm.js +1 -0
- package/dist/internal/accessibility/accessibility.const.cjs.js +2 -0
- package/dist/internal/accessibility/accessibility.const.cjs.js.map +1 -0
- package/dist/internal/accessibility/accessibility.const.esm.js +1 -0
- package/dist/internal/accessibility/role.enum.cjs.js +2 -0
- package/dist/internal/accessibility/role.enum.cjs.js.map +1 -0
- package/dist/internal/accessibility/role.enum.esm.js +1 -0
- package/dist/internal/nile-element.cjs.js +1 -1
- package/dist/internal/nile-element.cjs.js.map +1 -1
- package/dist/internal/nile-element.esm.js +1 -1
- package/dist/nile-accordion/index.cjs.js +1 -1
- package/dist/nile-accordion/index.esm.js +1 -1
- package/dist/nile-accordion/nile-accordion.cjs.js +1 -1
- package/dist/nile-accordion/nile-accordion.cjs.js.map +1 -1
- package/dist/nile-accordion/nile-accordion.esm.js +2 -2
- package/dist/nile-auto-complete/index.cjs.js +1 -1
- package/dist/nile-auto-complete/index.esm.js +1 -1
- package/dist/nile-auto-complete/nile-auto-complete.cjs.js +1 -1
- package/dist/nile-auto-complete/nile-auto-complete.cjs.js.map +1 -1
- package/dist/nile-auto-complete/nile-auto-complete.esm.js +1 -1
- package/dist/nile-avatar/index.cjs.js +1 -1
- package/dist/nile-avatar/index.esm.js +1 -1
- package/dist/nile-avatar/nile-avatar.cjs.js +1 -1
- package/dist/nile-avatar/nile-avatar.cjs.js.map +1 -1
- package/dist/nile-avatar/nile-avatar.esm.js +3 -1
- package/dist/nile-badge/index.cjs.js +1 -1
- package/dist/nile-badge/index.esm.js +1 -1
- package/dist/nile-badge/nile-badge.cjs.js +1 -1
- package/dist/nile-badge/nile-badge.cjs.js.map +1 -1
- package/dist/nile-badge/nile-badge.esm.js +2 -2
- package/dist/nile-breadcrumb/index.cjs.js +1 -1
- package/dist/nile-breadcrumb/index.esm.js +1 -1
- package/dist/nile-breadcrumb/nile-breadcrumb.cjs.js +1 -1
- package/dist/nile-breadcrumb/nile-breadcrumb.cjs.js.map +1 -1
- package/dist/nile-breadcrumb/nile-breadcrumb.esm.js +1 -1
- package/dist/nile-breadcrumb-item/index.cjs.js +1 -1
- package/dist/nile-breadcrumb-item/index.esm.js +1 -1
- package/dist/nile-breadcrumb-item/nile-breadcrumb-item.cjs.js +1 -1
- package/dist/nile-breadcrumb-item/nile-breadcrumb-item.cjs.js.map +1 -1
- package/dist/nile-breadcrumb-item/nile-breadcrumb-item.esm.js +4 -4
- package/dist/nile-button/index.cjs.js +1 -1
- package/dist/nile-button/index.esm.js +1 -1
- package/dist/nile-button/nile-button.cjs.js +1 -1
- package/dist/nile-button/nile-button.cjs.js.map +1 -1
- package/dist/nile-button/nile-button.css.cjs.js +1 -1
- package/dist/nile-button/nile-button.css.cjs.js.map +1 -1
- package/dist/nile-button/nile-button.css.esm.js +5 -0
- package/dist/nile-button/nile-button.esm.js +1 -1
- package/dist/nile-button-filter/index.cjs.js +1 -1
- package/dist/nile-button-filter/index.esm.js +1 -1
- package/dist/nile-button-filter/nile-button-filter.cjs.js +1 -1
- package/dist/nile-button-filter/nile-button-filter.cjs.js.map +1 -1
- package/dist/nile-button-filter/nile-button-filter.esm.js +7 -7
- package/dist/nile-button-toggle/index.cjs.js +1 -1
- package/dist/nile-button-toggle/index.esm.js +1 -1
- package/dist/nile-button-toggle/nile-button-toggle.cjs.js +1 -1
- package/dist/nile-button-toggle/nile-button-toggle.cjs.js.map +1 -1
- package/dist/nile-button-toggle/nile-button-toggle.esm.js +2 -2
- package/dist/nile-button-toggle-group/index.cjs.js +1 -1
- package/dist/nile-button-toggle-group/index.esm.js +1 -1
- package/dist/nile-button-toggle-group/nile-button-toggle-group.cjs.js +1 -1
- package/dist/nile-button-toggle-group/nile-button-toggle-group.cjs.js.map +1 -1
- package/dist/nile-button-toggle-group/nile-button-toggle-group.esm.js +1 -1
- package/dist/nile-calendar/index.cjs.js +1 -1
- package/dist/nile-calendar/index.esm.js +1 -1
- package/dist/nile-calendar/nile-calendar.cjs.js +1 -1
- package/dist/nile-calendar/nile-calendar.cjs.js.map +1 -1
- package/dist/nile-calendar/nile-calendar.esm.js +4 -4
- package/dist/nile-card/index.cjs.js +1 -1
- package/dist/nile-card/index.esm.js +1 -1
- package/dist/nile-card/nile-card.cjs.js +1 -1
- package/dist/nile-card/nile-card.cjs.js.map +1 -1
- package/dist/nile-card/nile-card.esm.js +2 -2
- package/dist/nile-carousel/index.cjs.js +1 -1
- package/dist/nile-carousel/index.esm.js +1 -1
- package/dist/nile-carousel/nile-carousel-item/index.cjs.js +1 -1
- package/dist/nile-carousel/nile-carousel-item/index.esm.js +1 -1
- package/dist/nile-carousel/nile-carousel-item/nile-carousel-item.cjs.js +1 -1
- package/dist/nile-carousel/nile-carousel-item/nile-carousel-item.cjs.js.map +1 -1
- package/dist/nile-carousel/nile-carousel-item/nile-carousel-item.esm.js +2 -2
- package/dist/nile-carousel/nile-carousel.cjs.js +1 -1
- package/dist/nile-carousel/nile-carousel.cjs.js.map +1 -1
- package/dist/nile-carousel/nile-carousel.esm.js +1 -1
- package/dist/nile-checkbox/index.cjs.js +1 -1
- package/dist/nile-checkbox/index.esm.js +1 -1
- package/dist/nile-checkbox/nile-checkbox.cjs.js +1 -1
- package/dist/nile-checkbox/nile-checkbox.cjs.js.map +1 -1
- package/dist/nile-checkbox/nile-checkbox.css.cjs.js +1 -1
- package/dist/nile-checkbox/nile-checkbox.css.cjs.js.map +1 -1
- package/dist/nile-checkbox/nile-checkbox.css.esm.js +4 -0
- package/dist/nile-checkbox/nile-checkbox.esm.js +3 -3
- package/dist/nile-checkbox-group/index.cjs.js +2 -0
- package/dist/nile-checkbox-group/index.cjs.js.map +1 -0
- package/dist/nile-checkbox-group/index.esm.js +1 -0
- package/dist/nile-checkbox-group/nile-checkbox-group.cjs.js +2 -0
- package/dist/nile-checkbox-group/nile-checkbox-group.cjs.js.map +1 -0
- package/dist/nile-checkbox-group/nile-checkbox-group.css.cjs.js +2 -0
- package/dist/nile-checkbox-group/nile-checkbox-group.css.cjs.js.map +1 -0
- package/dist/nile-checkbox-group/nile-checkbox-group.css.esm.js +68 -0
- package/dist/nile-checkbox-group/nile-checkbox-group.esm.js +56 -0
- package/dist/nile-chip/index.cjs.js +1 -1
- package/dist/nile-chip/index.esm.js +1 -1
- package/dist/nile-chip/nile-chip.cjs.js +1 -1
- package/dist/nile-chip/nile-chip.cjs.js.map +1 -1
- package/dist/nile-chip/nile-chip.esm.js +2 -2
- package/dist/nile-circular-progressbar/index.cjs.js +1 -1
- package/dist/nile-circular-progressbar/index.esm.js +1 -1
- package/dist/nile-circular-progressbar/nile-circular-progressbar.cjs.js +1 -1
- package/dist/nile-circular-progressbar/nile-circular-progressbar.cjs.js.map +1 -1
- package/dist/nile-circular-progressbar/nile-circular-progressbar.esm.js +2 -2
- package/dist/nile-code-editor/index.cjs.js +1 -1
- package/dist/nile-code-editor/index.esm.js +1 -1
- package/dist/nile-code-editor/nile-code-editor.cjs.js +2 -2
- package/dist/nile-code-editor/nile-code-editor.cjs.js.map +1 -1
- package/dist/nile-code-editor/nile-code-editor.esm.js +2 -2
- package/dist/nile-content-editor/index.cjs.js +1 -1
- package/dist/nile-content-editor/index.esm.js +1 -1
- package/dist/nile-content-editor/nile-content-editor.cjs.js +1 -1
- package/dist/nile-content-editor/nile-content-editor.cjs.js.map +1 -1
- package/dist/nile-content-editor/nile-content-editor.esm.js +5 -5
- package/dist/nile-date-picker/index.cjs.js +1 -1
- package/dist/nile-date-picker/index.esm.js +1 -1
- package/dist/nile-date-picker/nile-date-picker.cjs.js +1 -1
- package/dist/nile-date-picker/nile-date-picker.cjs.js.map +1 -1
- package/dist/nile-date-picker/nile-date-picker.esm.js +1 -1
- package/dist/nile-detail/index.cjs.js +1 -1
- package/dist/nile-detail/index.esm.js +1 -1
- package/dist/nile-detail/nile-detail.cjs.js +1 -1
- package/dist/nile-detail/nile-detail.cjs.js.map +1 -1
- package/dist/nile-detail/nile-detail.esm.js +2 -2
- package/dist/nile-dialog/index.cjs.js +1 -1
- package/dist/nile-dialog/index.esm.js +1 -1
- package/dist/nile-dialog/nile-dialog.cjs.js +1 -1
- package/dist/nile-dialog/nile-dialog.cjs.js.map +1 -1
- package/dist/nile-dialog/nile-dialog.esm.js +2 -2
- package/dist/nile-divider/index.cjs.js +1 -1
- package/dist/nile-divider/index.esm.js +1 -1
- package/dist/nile-divider/nile-divider.cjs.js +1 -1
- package/dist/nile-divider/nile-divider.cjs.js.map +1 -1
- package/dist/nile-divider/nile-divider.esm.js +2 -2
- package/dist/nile-drawer/index.cjs.js +1 -1
- package/dist/nile-drawer/index.esm.js +1 -1
- package/dist/nile-drawer/nile-drawer.cjs.js +1 -1
- package/dist/nile-drawer/nile-drawer.cjs.js.map +1 -1
- package/dist/nile-drawer/nile-drawer.esm.js +1 -1
- package/dist/nile-dropdown/index.cjs.js +1 -1
- package/dist/nile-dropdown/index.esm.js +1 -1
- package/dist/nile-dropdown/nile-dropdown.cjs.js +1 -1
- package/dist/nile-dropdown/nile-dropdown.cjs.js.map +1 -1
- package/dist/nile-dropdown/nile-dropdown.esm.js +1 -1
- package/dist/nile-empty-state/index.cjs.js +1 -1
- package/dist/nile-empty-state/index.esm.js +1 -1
- package/dist/nile-empty-state/nile-empty-state.cjs.js +1 -1
- package/dist/nile-empty-state/nile-empty-state.cjs.js.map +1 -1
- package/dist/nile-empty-state/nile-empty-state.esm.js +2 -2
- package/dist/nile-file-preview/index.cjs.js +1 -1
- package/dist/nile-file-preview/index.esm.js +1 -1
- package/dist/nile-file-preview/nile-file-preview.cjs.js +1 -1
- package/dist/nile-file-preview/nile-file-preview.cjs.js.map +1 -1
- package/dist/nile-file-preview/nile-file-preview.esm.js +1 -1
- package/dist/nile-file-upload/index.cjs.js +1 -1
- package/dist/nile-file-upload/index.esm.js +1 -1
- package/dist/nile-file-upload/nile-file-upload.cjs.js +1 -1
- package/dist/nile-file-upload/nile-file-upload.cjs.js.map +1 -1
- package/dist/nile-file-upload/nile-file-upload.esm.js +2 -2
- package/dist/nile-filter-chip/index.cjs.js +1 -1
- package/dist/nile-filter-chip/index.esm.js +1 -1
- package/dist/nile-filter-chip/nile-filter-chip.cjs.js +1 -1
- package/dist/nile-filter-chip/nile-filter-chip.cjs.js.map +1 -1
- package/dist/nile-filter-chip/nile-filter-chip.esm.js +2 -2
- package/dist/nile-floating-panel/index.cjs.js +1 -1
- package/dist/nile-floating-panel/index.esm.js +1 -1
- package/dist/nile-floating-panel/nile-floating-panel.cjs.js +1 -1
- package/dist/nile-floating-panel/nile-floating-panel.cjs.js.map +1 -1
- package/dist/nile-floating-panel/nile-floating-panel.esm.js +1 -1
- package/dist/nile-form-group/index.cjs.js +1 -1
- package/dist/nile-form-group/index.esm.js +1 -1
- package/dist/nile-form-group/nile-form-group.cjs.js +1 -1
- package/dist/nile-form-group/nile-form-group.cjs.js.map +1 -1
- package/dist/nile-form-group/nile-form-group.esm.js +2 -2
- package/dist/nile-format-date/index.cjs.js +1 -1
- package/dist/nile-format-date/index.esm.js +1 -1
- package/dist/nile-format-date/nile-format-date.cjs.js +1 -1
- package/dist/nile-format-date/nile-format-date.cjs.js.map +1 -1
- package/dist/nile-format-date/nile-format-date.esm.js +1 -1
- package/dist/nile-grid/index.cjs.js +1 -1
- package/dist/nile-grid/index.esm.js +1 -1
- package/dist/nile-grid/nile-grid-body/index.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-body/index.esm.js +1 -1
- package/dist/nile-grid/nile-grid-body/nile-grid-body.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-body/nile-grid-body.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid-body/nile-grid-body.esm.js +2 -2
- package/dist/nile-grid/nile-grid-cell-item/index.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-cell-item/index.esm.js +1 -1
- package/dist/nile-grid/nile-grid-cell-item/nile-grid-cell-item.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-cell-item/nile-grid-cell-item.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid-cell-item/nile-grid-cell-item.esm.js +2 -2
- package/dist/nile-grid/nile-grid-head/index.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-head/index.esm.js +1 -1
- package/dist/nile-grid/nile-grid-head/nile-grid-head.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-head/nile-grid-head.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid-head/nile-grid-head.esm.js +2 -2
- package/dist/nile-grid/nile-grid-head-item/index.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-head-item/index.esm.js +1 -1
- package/dist/nile-grid/nile-grid-head-item/nile-grid-head-item.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-head-item/nile-grid-head-item.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid-head-item/nile-grid-head-item.esm.js +3 -3
- package/dist/nile-grid/nile-grid-row/index.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-row/index.esm.js +1 -1
- package/dist/nile-grid/nile-grid-row/nile-grid-row.cjs.js +1 -1
- package/dist/nile-grid/nile-grid-row/nile-grid-row.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid-row/nile-grid-row.esm.js +2 -2
- package/dist/nile-grid/nile-grid.cjs.js +1 -1
- package/dist/nile-grid/nile-grid.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid.esm.js +2 -2
- package/dist/nile-hero/index.cjs.js +1 -1
- package/dist/nile-hero/index.esm.js +1 -1
- package/dist/nile-hero/nile-hero.cjs.js +1 -1
- package/dist/nile-hero/nile-hero.cjs.js.map +1 -1
- package/dist/nile-hero/nile-hero.esm.js +2 -2
- package/dist/nile-hero-header/index.cjs.js +1 -1
- package/dist/nile-hero-header/index.esm.js +1 -1
- package/dist/nile-hero-header/nile-hero-header.cjs.js +1 -1
- package/dist/nile-hero-header/nile-hero-header.cjs.js.map +1 -1
- package/dist/nile-hero-header/nile-hero-header.esm.js +2 -2
- package/dist/nile-icon/icons/svg/arrow-left-small.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/arrow-left-small.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/arrow-left-small.esm.js +1 -0
- package/dist/nile-icon/icons/svg/arrow-right-small.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/arrow-right-small.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/arrow-right-small.esm.js +1 -0
- package/dist/nile-icon/icons/svg/arrow_left_small.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/arrow_left_small.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/arrow_left_small.esm.js +1 -0
- package/dist/nile-icon/icons/svg/arrow_right_small.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/arrow_right_small.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/arrow_right_small.esm.js +1 -0
- package/dist/nile-icon/icons/svg/index.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/index.esm.js +1 -1
- package/dist/nile-icon/index.cjs.js +1 -1
- package/dist/nile-icon/index.cjs.js.map +1 -1
- package/dist/nile-icon/index.esm.js +1 -1
- package/dist/nile-icon-button/index.cjs.js +1 -1
- package/dist/nile-icon-button/index.esm.js +1 -1
- package/dist/nile-icon-button/nile-icon-button.cjs.js +1 -1
- package/dist/nile-icon-button/nile-icon-button.cjs.js.map +1 -1
- package/dist/nile-icon-button/nile-icon-button.esm.js +1 -1
- package/dist/nile-inline-edit/index.cjs.js +1 -1
- package/dist/nile-inline-edit/index.esm.js +1 -1
- package/dist/nile-inline-edit/nile-inline-edit.cjs.js +1 -1
- package/dist/nile-inline-edit/nile-inline-edit.cjs.js.map +1 -1
- package/dist/nile-inline-edit/nile-inline-edit.esm.js +2 -2
- package/dist/nile-inline-sidebar/index.cjs.js +1 -1
- package/dist/nile-inline-sidebar/index.esm.js +1 -1
- package/dist/nile-inline-sidebar/nile-inline-sidebar.cjs.js +1 -1
- package/dist/nile-inline-sidebar/nile-inline-sidebar.cjs.js.map +1 -1
- package/dist/nile-inline-sidebar/nile-inline-sidebar.esm.js +3 -3
- package/dist/nile-inline-sidebar-group/index.cjs.js +1 -1
- package/dist/nile-inline-sidebar-group/index.esm.js +1 -1
- package/dist/nile-inline-sidebar-group/nile-inline-sidebar-group.cjs.js +1 -1
- package/dist/nile-inline-sidebar-group/nile-inline-sidebar-group.cjs.js.map +1 -1
- package/dist/nile-inline-sidebar-group/nile-inline-sidebar-group.esm.js +3 -3
- package/dist/nile-inline-sidebar-item/index.cjs.js +1 -1
- package/dist/nile-inline-sidebar-item/index.esm.js +1 -1
- package/dist/nile-inline-sidebar-item/nile-inline-sidebar-item.cjs.js +1 -1
- package/dist/nile-inline-sidebar-item/nile-inline-sidebar-item.cjs.js.map +1 -1
- package/dist/nile-inline-sidebar-item/nile-inline-sidebar-item.esm.js +3 -3
- package/dist/nile-input/index.cjs.js +1 -1
- package/dist/nile-input/index.esm.js +1 -1
- package/dist/nile-input/nile-input.cjs.js +1 -1
- package/dist/nile-input/nile-input.cjs.js.map +1 -1
- package/dist/nile-input/nile-input.esm.js +1 -1
- package/dist/nile-link/index.cjs.js +1 -1
- package/dist/nile-link/index.esm.js +1 -1
- package/dist/nile-link/nile-link.cjs.js +1 -1
- package/dist/nile-link/nile-link.cjs.js.map +1 -1
- package/dist/nile-link/nile-link.esm.js +3 -3
- package/dist/nile-list/index.cjs.js +1 -1
- package/dist/nile-list/index.esm.js +1 -1
- package/dist/nile-list/nile-list.cjs.js +1 -1
- package/dist/nile-list/nile-list.cjs.js.map +1 -1
- package/dist/nile-list/nile-list.esm.js +1 -1
- package/dist/nile-list-item/index.cjs.js +1 -1
- package/dist/nile-list-item/index.esm.js +1 -1
- package/dist/nile-list-item/nile-list-item.cjs.js +1 -1
- package/dist/nile-list-item/nile-list-item.cjs.js.map +1 -1
- package/dist/nile-list-item/nile-list-item.esm.js +2 -2
- package/dist/nile-lite-tooltip/index.cjs.js +1 -1
- package/dist/nile-lite-tooltip/index.esm.js +1 -1
- package/dist/nile-lite-tooltip/nile-lite-tooltip.cjs.js +1 -1
- package/dist/nile-lite-tooltip/nile-lite-tooltip.cjs.js.map +1 -1
- package/dist/nile-lite-tooltip/nile-lite-tooltip.esm.js +1 -1
- package/dist/nile-menu/index.cjs.js +1 -1
- package/dist/nile-menu/index.esm.js +1 -1
- package/dist/nile-menu/nile-menu.cjs.js +1 -1
- package/dist/nile-menu/nile-menu.cjs.js.map +1 -1
- package/dist/nile-menu/nile-menu.esm.js +2 -2
- package/dist/nile-menu-item/index.cjs.js +1 -1
- package/dist/nile-menu-item/index.esm.js +1 -1
- package/dist/nile-menu-item/nile-menu-item.cjs.js +1 -1
- package/dist/nile-menu-item/nile-menu-item.cjs.js.map +1 -1
- package/dist/nile-menu-item/nile-menu-item.css.cjs.js +1 -1
- package/dist/nile-menu-item/nile-menu-item.css.cjs.js.map +1 -1
- package/dist/nile-menu-item/nile-menu-item.css.esm.js +11 -2
- package/dist/nile-menu-item/nile-menu-item.esm.js +3 -3
- package/dist/nile-option/index.cjs.js +1 -1
- package/dist/nile-option/index.esm.js +1 -1
- package/dist/nile-option/nile-option.cjs.js +1 -1
- package/dist/nile-option/nile-option.cjs.js.map +1 -1
- package/dist/nile-option/nile-option.esm.js +1 -1
- package/dist/nile-option-group/index.cjs.js +1 -1
- package/dist/nile-option-group/index.esm.js +1 -1
- package/dist/nile-option-group/nile-option-group.cjs.js +1 -1
- package/dist/nile-option-group/nile-option-group.cjs.js.map +1 -1
- package/dist/nile-option-group/nile-option-group.esm.js +2 -2
- package/dist/nile-otp-input/index.cjs.js +1 -1
- package/dist/nile-otp-input/index.esm.js +1 -1
- package/dist/nile-otp-input/nile-otp-input.cjs.js +1 -1
- package/dist/nile-otp-input/nile-otp-input.cjs.js.map +1 -1
- package/dist/nile-otp-input/nile-otp-input.esm.js +1 -1
- package/dist/nile-page-header/index.cjs.js +1 -1
- package/dist/nile-page-header/index.esm.js +1 -1
- package/dist/nile-page-header/nile-page-header.cjs.js +1 -1
- package/dist/nile-page-header/nile-page-header.cjs.js.map +1 -1
- package/dist/nile-page-header/nile-page-header.esm.js +2 -2
- package/dist/nile-pagination/index.cjs.js +1 -1
- package/dist/nile-pagination/index.esm.js +1 -1
- package/dist/nile-pagination/nile-pagination.cjs.js +1 -1
- package/dist/nile-pagination/nile-pagination.cjs.js.map +1 -1
- package/dist/nile-pagination/nile-pagination.css.cjs.js +1 -1
- package/dist/nile-pagination/nile-pagination.css.cjs.js.map +1 -1
- package/dist/nile-pagination/nile-pagination.css.esm.js +13 -0
- package/dist/nile-pagination/nile-pagination.esm.js +1 -1
- package/dist/nile-popover/index.cjs.js +1 -1
- package/dist/nile-popover/index.esm.js +1 -1
- package/dist/nile-popover/nile-popover.cjs.js +2 -2
- package/dist/nile-popover/nile-popover.cjs.js.map +1 -1
- package/dist/nile-popover/nile-popover.esm.js +3 -3
- package/dist/nile-popup/index.cjs.js +1 -1
- package/dist/nile-popup/index.esm.js +1 -1
- package/dist/nile-popup/nile-popup.cjs.js +1 -1
- package/dist/nile-popup/nile-popup.cjs.js.map +1 -1
- package/dist/nile-popup/nile-popup.esm.js +2 -2
- package/dist/nile-progress-bar/index.cjs.js +1 -1
- package/dist/nile-progress-bar/index.esm.js +1 -1
- package/dist/nile-progress-bar/nile-progress-bar.cjs.js +1 -1
- package/dist/nile-progress-bar/nile-progress-bar.cjs.js.map +1 -1
- package/dist/nile-progress-bar/nile-progress-bar.esm.js +2 -2
- package/dist/nile-qr-code/index.cjs.js +1 -1
- package/dist/nile-qr-code/index.esm.js +1 -1
- package/dist/nile-qr-code/nile-qr-code.cjs.js +1 -1
- package/dist/nile-qr-code/nile-qr-code.cjs.js.map +1 -1
- package/dist/nile-qr-code/nile-qr-code.esm.js +2 -2
- package/dist/nile-radio/index.cjs.js +1 -1
- package/dist/nile-radio/index.esm.js +1 -1
- package/dist/nile-radio/nile-radio.cjs.js +1 -1
- package/dist/nile-radio/nile-radio.cjs.js.map +1 -1
- package/dist/nile-radio/nile-radio.css.cjs.js +1 -1
- package/dist/nile-radio/nile-radio.css.cjs.js.map +1 -1
- package/dist/nile-radio/nile-radio.css.esm.js +4 -0
- package/dist/nile-radio/nile-radio.esm.js +2 -2
- package/dist/nile-radio-group/index.cjs.js +1 -1
- package/dist/nile-radio-group/index.esm.js +1 -1
- package/dist/nile-radio-group/nile-radio-group.cjs.js +1 -1
- package/dist/nile-radio-group/nile-radio-group.cjs.js.map +1 -1
- package/dist/nile-radio-group/nile-radio-group.esm.js +2 -2
- package/dist/nile-rich-text-editor/nile-rich-text-editor.cjs.js +1 -1
- package/dist/nile-rich-text-editor/nile-rich-text-editor.cjs.js.map +1 -1
- package/dist/nile-rich-text-editor/nile-rich-text-editor.css.cjs.js +1 -1
- package/dist/nile-rich-text-editor/nile-rich-text-editor.css.cjs.js.map +1 -1
- package/dist/nile-rich-text-editor/nile-rich-text-editor.css.esm.js +8 -6
- package/dist/nile-rich-text-editor/nile-rich-text-editor.esm.js +1 -1
- package/dist/nile-rich-text-editor/utils/list-utils.cjs.js +1 -1
- package/dist/nile-rich-text-editor/utils/list-utils.cjs.js.map +1 -1
- package/dist/nile-rich-text-editor/utils/list-utils.esm.js +1 -1
- package/dist/nile-section-message/index.cjs.js +1 -1
- package/dist/nile-section-message/index.esm.js +1 -1
- package/dist/nile-section-message/nile-section-message.cjs.js +1 -1
- package/dist/nile-section-message/nile-section-message.cjs.js.map +1 -1
- package/dist/nile-section-message/nile-section-message.esm.js +2 -2
- package/dist/nile-select/index.cjs.js +1 -1
- package/dist/nile-select/index.esm.js +1 -1
- package/dist/nile-select/nile-select.cjs.js +1 -1
- package/dist/nile-select/nile-select.cjs.js.map +1 -1
- package/dist/nile-select/nile-select.css.cjs.js +1 -1
- package/dist/nile-select/nile-select.css.cjs.js.map +1 -1
- package/dist/nile-select/nile-select.css.esm.js +21 -2
- package/dist/nile-select/nile-select.esm.js +33 -25
- package/dist/nile-select/portal-utils.cjs.js +1 -1
- package/dist/nile-select/portal-utils.cjs.js.map +1 -1
- package/dist/nile-select/portal-utils.esm.js +1 -1
- package/dist/nile-side-bar/index.cjs.js +1 -1
- package/dist/nile-side-bar/index.esm.js +1 -1
- package/dist/nile-side-bar/nile-side-bar.cjs.js +1 -1
- package/dist/nile-side-bar/nile-side-bar.cjs.js.map +1 -1
- package/dist/nile-side-bar/nile-side-bar.esm.js +2 -2
- package/dist/nile-side-bar-action/index.cjs.js +1 -1
- package/dist/nile-side-bar-action/index.esm.js +1 -1
- package/dist/nile-side-bar-action/nile-side-bar-action.cjs.js +1 -1
- package/dist/nile-side-bar-action/nile-side-bar-action.cjs.js.map +1 -1
- package/dist/nile-side-bar-action/nile-side-bar-action.esm.js +3 -3
- package/dist/nile-side-bar-action-menu/index.cjs.js +1 -1
- package/dist/nile-side-bar-action-menu/index.esm.js +1 -1
- package/dist/nile-side-bar-action-menu/nile-side-bar-action-menu.cjs.js +1 -1
- package/dist/nile-side-bar-action-menu/nile-side-bar-action-menu.cjs.js.map +1 -1
- package/dist/nile-side-bar-action-menu/nile-side-bar-action-menu.esm.js +2 -2
- package/dist/nile-side-bar-action-menu-item/index.cjs.js +1 -1
- package/dist/nile-side-bar-action-menu-item/index.esm.js +1 -1
- package/dist/nile-side-bar-action-menu-item/nile-side-bar-action-menu-item.cjs.js +1 -1
- package/dist/nile-side-bar-action-menu-item/nile-side-bar-action-menu-item.cjs.js.map +1 -1
- package/dist/nile-side-bar-action-menu-item/nile-side-bar-action-menu-item.esm.js +1 -1
- package/dist/nile-side-bar-expand/index.cjs.js +1 -1
- package/dist/nile-side-bar-expand/index.esm.js +1 -1
- package/dist/nile-side-bar-expand/nile-side-bar-expand.cjs.js +1 -1
- package/dist/nile-side-bar-expand/nile-side-bar-expand.cjs.js.map +1 -1
- package/dist/nile-side-bar-expand/nile-side-bar-expand.esm.js +2 -2
- package/dist/nile-side-bar-footer/index.cjs.js +1 -1
- package/dist/nile-side-bar-footer/index.esm.js +1 -1
- package/dist/nile-side-bar-footer/nile-side-bar-footer.cjs.js +1 -1
- package/dist/nile-side-bar-footer/nile-side-bar-footer.cjs.js.map +1 -1
- package/dist/nile-side-bar-footer/nile-side-bar-footer.esm.js +2 -2
- package/dist/nile-side-bar-footer-item/index.cjs.js +1 -1
- package/dist/nile-side-bar-footer-item/index.esm.js +1 -1
- package/dist/nile-side-bar-footer-item/nile-side-bar-footer-item.cjs.js +1 -1
- package/dist/nile-side-bar-footer-item/nile-side-bar-footer-item.cjs.js.map +1 -1
- package/dist/nile-side-bar-footer-item/nile-side-bar-footer-item.esm.js +1 -1
- package/dist/nile-side-bar-footer-text/index.cjs.js +1 -1
- package/dist/nile-side-bar-footer-text/index.esm.js +1 -1
- package/dist/nile-side-bar-footer-text/nile-side-bar-footer-text.cjs.js +1 -1
- package/dist/nile-side-bar-footer-text/nile-side-bar-footer-text.cjs.js.map +1 -1
- package/dist/nile-side-bar-footer-text/nile-side-bar-footer-text.esm.js +3 -3
- package/dist/nile-side-bar-group/index.cjs.js +1 -1
- package/dist/nile-side-bar-group/index.esm.js +1 -1
- package/dist/nile-side-bar-group/nile-side-bar-group.cjs.js +1 -1
- package/dist/nile-side-bar-group/nile-side-bar-group.cjs.js.map +1 -1
- package/dist/nile-side-bar-group/nile-side-bar-group.esm.js +2 -2
- package/dist/nile-side-bar-group-item/index.cjs.js +1 -1
- package/dist/nile-side-bar-group-item/index.esm.js +1 -1
- package/dist/nile-side-bar-group-item/nile-side-bar-group-item.cjs.js +1 -1
- package/dist/nile-side-bar-group-item/nile-side-bar-group-item.cjs.js.map +1 -1
- package/dist/nile-side-bar-group-item/nile-side-bar-group-item.esm.js +2 -2
- package/dist/nile-side-bar-group-item-icon/index.cjs.js +1 -1
- package/dist/nile-side-bar-group-item-icon/index.esm.js +1 -1
- package/dist/nile-side-bar-group-item-icon/nile-side-bar-group-item-icon.cjs.js +1 -1
- package/dist/nile-side-bar-group-item-icon/nile-side-bar-group-item-icon.cjs.js.map +1 -1
- package/dist/nile-side-bar-group-item-icon/nile-side-bar-group-item-icon.esm.js +2 -2
- package/dist/nile-side-bar-group-item-text/index.cjs.js +1 -1
- package/dist/nile-side-bar-group-item-text/index.esm.js +1 -1
- package/dist/nile-side-bar-group-item-text/nile-side-bar-group-item-text.cjs.js +1 -1
- package/dist/nile-side-bar-group-item-text/nile-side-bar-group-item-text.cjs.js.map +1 -1
- package/dist/nile-side-bar-group-item-text/nile-side-bar-group-item-text.esm.js +1 -1
- package/dist/nile-side-bar-header/index.cjs.js +1 -1
- package/dist/nile-side-bar-header/index.esm.js +1 -1
- package/dist/nile-side-bar-header/nile-side-bar-header.cjs.js +1 -1
- package/dist/nile-side-bar-header/nile-side-bar-header.cjs.js.map +1 -1
- package/dist/nile-side-bar-header/nile-side-bar-header.esm.js +2 -2
- package/dist/nile-side-bar-logo/index.cjs.js +1 -1
- package/dist/nile-side-bar-logo/index.esm.js +1 -1
- package/dist/nile-side-bar-logo/nile-side-bar-logo.cjs.js +1 -1
- package/dist/nile-side-bar-logo/nile-side-bar-logo.cjs.js.map +1 -1
- package/dist/nile-side-bar-logo/nile-side-bar-logo.esm.js +2 -2
- package/dist/nile-side-bar-panel/index.cjs.js +1 -1
- package/dist/nile-side-bar-panel/index.esm.js +1 -1
- package/dist/nile-side-bar-panel/nile-side-bar-panel.cjs.js +1 -1
- package/dist/nile-side-bar-panel/nile-side-bar-panel.cjs.js.map +1 -1
- package/dist/nile-side-bar-panel/nile-side-bar-panel.esm.js +2 -2
- package/dist/nile-skeleton-loader/index.cjs.js +1 -1
- package/dist/nile-skeleton-loader/index.esm.js +1 -1
- package/dist/nile-skeleton-loader/nile-skeleton-loader.cjs.js +1 -1
- package/dist/nile-skeleton-loader/nile-skeleton-loader.cjs.js.map +1 -1
- package/dist/nile-skeleton-loader/nile-skeleton-loader.esm.js +2 -2
- package/dist/nile-slide-toggle/index.cjs.js +1 -1
- package/dist/nile-slide-toggle/index.esm.js +1 -1
- package/dist/nile-slide-toggle/nile-slide-toggle.cjs.js +1 -1
- package/dist/nile-slide-toggle/nile-slide-toggle.cjs.js.map +1 -1
- package/dist/nile-slide-toggle/nile-slide-toggle.esm.js +2 -2
- package/dist/nile-slider/index.cjs.js +1 -1
- package/dist/nile-slider/index.esm.js +1 -1
- package/dist/nile-slider/nile-slider.cjs.js +1 -1
- package/dist/nile-slider/nile-slider.cjs.js.map +1 -1
- package/dist/nile-slider/nile-slider.esm.js +3 -3
- package/dist/nile-split-panel/index.cjs.js +1 -1
- package/dist/nile-split-panel/index.esm.js +1 -1
- package/dist/nile-split-panel/nile-split-panel.cjs.js +1 -1
- package/dist/nile-split-panel/nile-split-panel.cjs.js.map +1 -1
- package/dist/nile-split-panel/nile-split-panel.esm.js +2 -2
- package/dist/nile-stepper/index.cjs.js +1 -1
- package/dist/nile-stepper/index.esm.js +1 -1
- package/dist/nile-stepper/nile-stepper.cjs.js +1 -1
- package/dist/nile-stepper/nile-stepper.cjs.js.map +1 -1
- package/dist/nile-stepper/nile-stepper.esm.js +3 -3
- package/dist/nile-stepper-item/index.cjs.js +1 -1
- package/dist/nile-stepper-item/index.esm.js +1 -1
- package/dist/nile-stepper-item/nile-stepper-item.cjs.js +1 -1
- package/dist/nile-stepper-item/nile-stepper-item.cjs.js.map +1 -1
- package/dist/nile-stepper-item/nile-stepper-item.esm.js +1 -1
- package/dist/nile-switcher/index.cjs.js +1 -1
- package/dist/nile-switcher/index.esm.js +1 -1
- package/dist/nile-switcher/nile-switcher.cjs.js +1 -1
- package/dist/nile-switcher/nile-switcher.cjs.js.map +1 -1
- package/dist/nile-switcher/nile-switcher.esm.js +23 -23
- package/dist/nile-tab/index.cjs.js +1 -1
- package/dist/nile-tab/index.esm.js +1 -1
- package/dist/nile-tab/nile-tab.cjs.js +1 -1
- package/dist/nile-tab/nile-tab.cjs.js.map +1 -1
- package/dist/nile-tab/nile-tab.esm.js +1 -1
- package/dist/nile-tab-group/index.cjs.js +1 -1
- package/dist/nile-tab-group/index.esm.js +1 -1
- package/dist/nile-tab-group/nile-tab-group.cjs.js +1 -1
- package/dist/nile-tab-group/nile-tab-group.cjs.js.map +1 -1
- package/dist/nile-tab-group/nile-tab-group.esm.js +1 -1
- package/dist/nile-tab-panel/index.cjs.js +1 -1
- package/dist/nile-tab-panel/index.esm.js +1 -1
- package/dist/nile-tab-panel/nile-tab-panel.cjs.js +1 -1
- package/dist/nile-tab-panel/nile-tab-panel.cjs.js.map +1 -1
- package/dist/nile-tab-panel/nile-tab-panel.esm.js +3 -3
- package/dist/nile-table/index.cjs.js +1 -1
- package/dist/nile-table/index.esm.js +1 -1
- package/dist/nile-table/nile-table.cjs.js +1 -1
- package/dist/nile-table/nile-table.cjs.js.map +1 -1
- package/dist/nile-table/nile-table.esm.js +1 -1
- package/dist/nile-table-body/index.cjs.js +1 -1
- package/dist/nile-table-body/index.esm.js +1 -1
- package/dist/nile-table-body/nile-table-body.cjs.js +1 -1
- package/dist/nile-table-body/nile-table-body.cjs.js.map +1 -1
- package/dist/nile-table-body/nile-table-body.esm.js +3 -3
- package/dist/nile-table-cell-item/index.cjs.js +1 -1
- package/dist/nile-table-cell-item/index.esm.js +1 -1
- package/dist/nile-table-cell-item/nile-table-cell-item.cjs.js +1 -1
- package/dist/nile-table-cell-item/nile-table-cell-item.cjs.js.map +1 -1
- package/dist/nile-table-cell-item/nile-table-cell-item.esm.js +5 -5
- package/dist/nile-table-header-item/index.cjs.js +1 -1
- package/dist/nile-table-header-item/index.esm.js +1 -1
- package/dist/nile-table-header-item/nile-table-header-item.cjs.js +1 -1
- package/dist/nile-table-header-item/nile-table-header-item.cjs.js.map +1 -1
- package/dist/nile-table-header-item/nile-table-header-item.esm.js +1 -1
- package/dist/nile-table-row/index.cjs.js +1 -1
- package/dist/nile-table-row/index.esm.js +1 -1
- package/dist/nile-table-row/nile-table-row.cjs.js +1 -1
- package/dist/nile-table-row/nile-table-row.cjs.js.map +1 -1
- package/dist/nile-table-row/nile-table-row.esm.js +2 -2
- package/dist/nile-tag/index.cjs.js +1 -1
- package/dist/nile-tag/index.esm.js +1 -1
- package/dist/nile-tag/nile-tag.cjs.js +1 -1
- package/dist/nile-tag/nile-tag.cjs.js.map +1 -1
- package/dist/nile-tag/nile-tag.esm.js +1 -1
- package/dist/nile-textarea/index.cjs.js +1 -1
- package/dist/nile-textarea/index.esm.js +1 -1
- package/dist/nile-textarea/nile-textarea.cjs.js +1 -1
- package/dist/nile-textarea/nile-textarea.cjs.js.map +1 -1
- package/dist/nile-textarea/nile-textarea.esm.js +2 -2
- package/dist/nile-title/index.cjs.js +1 -1
- package/dist/nile-title/index.esm.js +1 -1
- package/dist/nile-title/nile-title.cjs.js +1 -1
- package/dist/nile-title/nile-title.cjs.js.map +1 -1
- package/dist/nile-title/nile-title.esm.js +1 -1
- package/dist/nile-toast/index.cjs.js +1 -1
- package/dist/nile-toast/index.esm.js +1 -1
- package/dist/nile-toast/nile-toast.cjs.js +1 -1
- package/dist/nile-toast/nile-toast.cjs.js.map +1 -1
- package/dist/nile-toast/nile-toast.esm.js +1 -1
- package/dist/nile-toolbar/index.cjs.js +1 -1
- package/dist/nile-toolbar/index.esm.js +1 -1
- package/dist/nile-toolbar/nile-toolbar.cjs.js +1 -1
- package/dist/nile-toolbar/nile-toolbar.cjs.js.map +1 -1
- package/dist/nile-toolbar/nile-toolbar.esm.js +2 -2
- package/dist/nile-tooltip/index.cjs.js +1 -1
- package/dist/nile-tooltip/index.esm.js +1 -1
- package/dist/nile-tooltip/nile-tooltip.cjs.js +1 -1
- package/dist/nile-tooltip/nile-tooltip.cjs.js.map +1 -1
- package/dist/nile-tooltip/nile-tooltip.esm.js +2 -2
- package/dist/nile-tree/index.cjs.js +1 -1
- package/dist/nile-tree/index.esm.js +1 -1
- package/dist/nile-tree/nile-tree.cjs.js +1 -1
- package/dist/nile-tree/nile-tree.cjs.js.map +1 -1
- package/dist/nile-tree/nile-tree.esm.js +1 -1
- package/dist/nile-tree-item/index.cjs.js +1 -1
- package/dist/nile-tree-item/index.esm.js +1 -1
- package/dist/nile-tree-item/nile-tree-item.cjs.js +1 -1
- package/dist/nile-tree-item/nile-tree-item.cjs.js.map +1 -1
- package/dist/nile-tree-item/nile-tree-item.esm.js +1 -1
- package/dist/nile-vertical-stepper-item/index.cjs.js +1 -1
- package/dist/nile-vertical-stepper-item/index.esm.js +1 -1
- package/dist/nile-vertical-stepper-item/nile-vertical-stepper-item.cjs.js +1 -1
- package/dist/nile-vertical-stepper-item/nile-vertical-stepper-item.cjs.js.map +1 -1
- package/dist/nile-vertical-stepper-item/nile-vertical-stepper-item.esm.js +7 -7
- package/dist/nile-virtual-select/index.cjs.js +1 -1
- package/dist/nile-virtual-select/index.esm.js +1 -1
- package/dist/nile-virtual-select/nile-virtual-select.cjs.js +2 -2
- package/dist/nile-virtual-select/nile-virtual-select.esm.js +1 -1
- package/dist/src/index.d.ts +1 -0
- package/dist/src/index.js +1 -0
- package/dist/src/index.js.map +1 -1
- package/dist/src/internal/accessibility/a11y.custom-value.enum.d.ts +69 -0
- package/dist/src/internal/accessibility/a11y.custom-value.enum.js +71 -0
- package/dist/src/internal/accessibility/a11y.custom-value.enum.js.map +1 -0
- package/dist/src/internal/accessibility/a11y.property.enum.d.ts +33 -0
- package/dist/src/internal/accessibility/a11y.property.enum.js +35 -0
- package/dist/src/internal/accessibility/a11y.property.enum.js.map +1 -0
- package/dist/src/internal/accessibility/a11y.role.enum.d.ts +50 -0
- package/dist/src/internal/accessibility/a11y.role.enum.js +52 -0
- package/dist/src/internal/accessibility/a11y.role.enum.js.map +1 -0
- package/dist/src/internal/accessibility/a11y.state.enum.d.ts +17 -0
- package/dist/src/internal/accessibility/a11y.state.enum.js +19 -0
- package/dist/src/internal/accessibility/a11y.state.enum.js.map +1 -0
- package/dist/src/internal/accessibility/accessibility.const.d.ts +8 -0
- package/dist/src/internal/accessibility/accessibility.const.js +9 -0
- package/dist/src/internal/accessibility/accessibility.const.js.map +1 -0
- package/dist/src/internal/accessibility/role.enum.d.ts +3 -0
- package/dist/src/internal/accessibility/role.enum.js +5 -0
- package/dist/src/internal/accessibility/role.enum.js.map +1 -0
- package/dist/src/internal/nile-element.d.ts +52 -0
- package/dist/src/internal/nile-element.js +45 -0
- package/dist/src/internal/nile-element.js.map +1 -1
- package/dist/src/nile-avatar/nile-avatar.js +2 -0
- package/dist/src/nile-avatar/nile-avatar.js.map +1 -1
- package/dist/src/nile-badge/nile-badge.d.ts +1 -0
- package/dist/src/nile-badge/nile-badge.js +12 -1
- package/dist/src/nile-badge/nile-badge.js.map +1 -1
- package/dist/src/nile-button/nile-button.css.js +5 -0
- package/dist/src/nile-button/nile-button.css.js.map +1 -1
- package/dist/src/nile-checkbox/nile-checkbox.css.js +4 -0
- package/dist/src/nile-checkbox/nile-checkbox.css.js.map +1 -1
- package/dist/src/nile-checkbox/nile-checkbox.d.ts +2 -0
- package/dist/src/nile-checkbox/nile-checkbox.js +5 -0
- package/dist/src/nile-checkbox/nile-checkbox.js.map +1 -1
- package/dist/src/nile-checkbox-group/index.d.ts +1 -0
- package/dist/src/nile-checkbox-group/index.js +2 -0
- package/dist/src/nile-checkbox-group/index.js.map +1 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.css.d.ts +1 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.css.js +70 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.css.js.map +1 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.d.ts +84 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.js +355 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.js.map +1 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.test.d.ts +2 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.test.js +671 -0
- package/dist/src/nile-checkbox-group/nile-checkbox-group.test.js.map +1 -0
- package/dist/src/nile-code-editor/nile-code-editor.d.ts +1 -1
- package/dist/src/nile-code-editor/nile-code-editor.js +1 -7
- package/dist/src/nile-code-editor/nile-code-editor.js.map +1 -1
- package/dist/src/nile-icon/icons/svg/arrow-left-small.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/arrow-left-small.js +5 -0
- package/dist/src/nile-icon/icons/svg/arrow-left-small.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/arrow-right-small.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/arrow-right-small.js +5 -0
- package/dist/src/nile-icon/icons/svg/arrow-right-small.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/arrow_left_small.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/arrow_left_small.js +5 -0
- package/dist/src/nile-icon/icons/svg/arrow_left_small.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/arrow_right_small.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/arrow_right_small.js +5 -0
- package/dist/src/nile-icon/icons/svg/arrow_right_small.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/index.d.ts +4 -0
- package/dist/src/nile-icon/icons/svg/index.js +4 -0
- package/dist/src/nile-icon/icons/svg/index.js.map +1 -1
- package/dist/src/nile-link/nile-link.d.ts +2 -1
- package/dist/src/nile-link/nile-link.js +18 -1
- package/dist/src/nile-link/nile-link.js.map +1 -1
- package/dist/src/nile-menu-item/nile-menu-item.css.js +11 -2
- package/dist/src/nile-menu-item/nile-menu-item.css.js.map +1 -1
- package/dist/src/nile-menu-item/nile-menu-item.d.ts +2 -0
- package/dist/src/nile-menu-item/nile-menu-item.js +7 -1
- package/dist/src/nile-menu-item/nile-menu-item.js.map +1 -1
- package/dist/src/nile-otp-input/nile-otp-input.test.js +7 -7
- package/dist/src/nile-otp-input/nile-otp-input.test.js.map +1 -1
- package/dist/src/nile-pagination/nile-pagination.css.js +13 -0
- package/dist/src/nile-pagination/nile-pagination.css.js.map +1 -1
- package/dist/src/nile-radio/nile-radio.css.js +4 -0
- package/dist/src/nile-radio/nile-radio.css.js.map +1 -1
- package/dist/src/nile-radio-group/nile-radio-group.js +7 -0
- package/dist/src/nile-radio-group/nile-radio-group.js.map +1 -1
- package/dist/src/nile-rich-text-editor/nile-rich-text-editor.css.js +8 -6
- package/dist/src/nile-rich-text-editor/nile-rich-text-editor.css.js.map +1 -1
- package/dist/src/nile-rich-text-editor/nile-rich-text-editor.d.ts +2 -0
- package/dist/src/nile-rich-text-editor/nile-rich-text-editor.js +43 -0
- package/dist/src/nile-rich-text-editor/nile-rich-text-editor.js.map +1 -1
- package/dist/src/nile-rich-text-editor/nile-rte-link.test.js +6 -5
- package/dist/src/nile-rich-text-editor/nile-rte-link.test.js.map +1 -1
- package/dist/src/nile-rich-text-editor/utils/list-utils.js +0 -1
- package/dist/src/nile-rich-text-editor/utils/list-utils.js.map +1 -1
- package/dist/src/nile-select/nile-select.css.js +21 -2
- package/dist/src/nile-select/nile-select.css.js.map +1 -1
- package/dist/src/nile-select/nile-select.d.ts +4 -0
- package/dist/src/nile-select/nile-select.js +42 -24
- package/dist/src/nile-select/nile-select.js.map +1 -1
- package/dist/src/nile-select/portal-utils.d.ts +2 -0
- package/dist/src/nile-select/portal-utils.js +36 -3
- package/dist/src/nile-select/portal-utils.js.map +1 -1
- package/dist/src/version.js +2 -2
- package/dist/src/version.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -2
- package/src/index.ts +1 -0
- package/src/internal/accessibility/a11y.custom-value.enum.ts +69 -0
- package/src/internal/accessibility/a11y.property.enum.ts +33 -0
- package/src/internal/accessibility/a11y.role.enum.ts +50 -0
- package/src/internal/accessibility/a11y.state.enum.ts +17 -0
- package/src/internal/accessibility/accessibility.const.ts +9 -0
- package/src/internal/accessibility/role.enum.ts +3 -0
- package/src/internal/nile-element.ts +99 -0
- package/src/nile-avatar/nile-avatar.ts +2 -0
- package/src/nile-badge/nile-badge.ts +13 -1
- package/src/nile-button/nile-button.css.ts +5 -0
- package/src/nile-checkbox/nile-checkbox.css.ts +4 -0
- package/src/nile-checkbox/nile-checkbox.ts +3 -0
- package/src/nile-checkbox-group/index.ts +1 -0
- package/src/nile-checkbox-group/nile-checkbox-group.css.ts +70 -0
- package/src/nile-checkbox-group/nile-checkbox-group.test.ts +769 -0
- package/src/nile-checkbox-group/nile-checkbox-group.ts +351 -0
- package/src/nile-code-editor/nile-code-editor.ts +1 -7
- package/src/nile-icon/icons/svg/arrow-left-small.ts +5 -0
- package/src/nile-icon/icons/svg/arrow-right-small.ts +5 -0
- package/src/nile-icon/icons/svg/arrow_left_small.ts +5 -0
- package/src/nile-icon/icons/svg/arrow_right_small.ts +5 -0
- package/src/nile-icon/icons/svg/index.ts +4 -0
- package/src/nile-link/nile-link.ts +21 -2
- package/src/nile-menu-item/nile-menu-item.css.ts +11 -2
- package/src/nile-menu-item/nile-menu-item.ts +5 -1
- package/src/nile-otp-input/nile-otp-input.test.ts +7 -7
- package/src/nile-pagination/nile-pagination.css.ts +13 -0
- package/src/nile-radio/nile-radio.css.ts +4 -0
- package/src/nile-radio-group/nile-radio-group.ts +7 -0
- package/src/nile-rich-text-editor/nile-rich-text-editor.css.ts +8 -6
- package/src/nile-rich-text-editor/nile-rich-text-editor.ts +43 -0
- package/src/nile-rich-text-editor/nile-rte-link.test.ts +6 -5
- package/src/nile-rich-text-editor/utils/list-utils.ts +1 -2
- package/src/nile-select/nile-select.css.ts +21 -2
- package/src/nile-select/nile-select.ts +44 -24
- package/src/nile-select/portal-utils.ts +46 -3
- package/vscode-html-custom-data.json +117 -20
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-dropdown.cjs.js","sources":["../../../src/nile-dropdown/nile-dropdown.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport {LitElement, html, CSSResultArray, TemplateResult, PropertyValues} from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport {styles} from './nile-dropdown.css';\nimport { animateTo, stopAnimations } from '../internal/animate';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { query } from 'lit/decorators.js';\nimport { getAnimation, setDefaultAnimation } from '../utilities/animation-registry';\nimport { getTabbableBoundary } from '../internal/tabbable';\nimport { waitForEvent } from '../internal/event';\nimport { watch } from '../internal/watch';\nimport NileElement from '../internal/nile-element';\nimport type { CSSResultGroup } from 'lit';\nimport type NileButton from '../nile-button/nile-button';\nimport type NileIconButton from '../nile-icon-button/nile-icon-button';\nimport type { NileMenu } from '../nile-menu';\nimport type { NilePopup } from '../nile-popup';\nimport '../nile-popup';\nimport { DropdownPortalManager } from './portal-manager';\nimport { VisibilityManager } from '../utilities/visibility-manager.js';\n\n/**\n * Nile icon component.\n *\n * @tag nile-dropdown\n * @summary Dropdowns expose additional content that \"drops down\" in a panel.\n * @dependency nile-popup\n *\n * @slot - The dropdown's main content.\n * @slot trigger - The dropdown's trigger, usually a `<nile-button>` element.\n *\n * @event nile-show - Emitted when the dropdown opens.\n * @event nile-after-show - Emitted after the dropdown opens and all animations are complete.\n * @event nile-hide - Emitted when the dropdown closes.\n * @event nile-after-hide - Emitted after the dropdown closes and all animations are complete.\n *\n * @csspart base - The component's base wrapper.\n * @csspart trigger - The container that wraps the trigger.\n * @csspart panel - The panel that gets shown when the dropdown is open.\n *\n * @animation dropdown.show - The animation to use when showing the dropdown.\n * @animation dropdown.hide - The animation to use when hiding the dropdown.\n */\n@customElement('nile-dropdown')\nexport class NileDropdown extends NileElement {\n static styles: CSSResultGroup = styles;\n\n @query('.dropdown') popup: NilePopup;\n @query('.dropdown__trigger') trigger: HTMLSlotElement;\n @query('.dropdown__panel') panel: HTMLSlotElement;\n\n\n /**\n * Indicates whether or not the dropdown is open. You can toggle this attribute to show and hide the dropdown, or you\n * can use the `show()` and `hide()` methods and this attribute will reflect the dropdown's open state.\n */\n @property({ type: Boolean, reflect: true }) open = false;\n\n /**\n * The preferred placement of the dropdown panel. Note that the actual placement may vary as needed to keep the panel\n * inside of the viewport.\n */\n @property({ reflect: true }) placement:\n | 'top'\n | 'top-start'\n | 'top-end'\n | 'bottom'\n | 'bottom-start'\n | 'bottom-end'\n | 'right'\n | 'right-start'\n | 'right-end'\n | 'left'\n | 'left-start'\n | 'left-end' = 'bottom-start';\n\n /** Disables the dropdown so the panel will not open. */\n @property({ type: Boolean, reflect: true }) disabled = false;\n\n /**\n * By default, the dropdown is closed when an item is selected. This attribute will keep it open instead. Useful for\n * dropdowns that allow for multiple interactions.\n */\n @property({ attribute: 'stay-open-on-select', type: Boolean, reflect: true }) stayOpenOnSelect = false;\n\n /**\n * The dropdown will close when the user interacts outside of this element (e.g. clicking). Useful for composing other\n * components that use a dropdown internally.\n */\n @property({ attribute: false }) containingElement?: HTMLElement;\n\n /** The distance in pixels from which to offset the panel away from its trigger. */\n @property({ type: Number }) distance = 0;\n\n\n @property({ type: Boolean }) noOpenOnClick = false;\n\n /** The distance in pixels from which to offset the panel along its trigger. */\n @property({ type: Number }) skidding = 0;\n\n /** Syncs the popup's width or height to that of the anchor element. */\n @property() sync: 'width' | 'height' | 'both';\n\n /**\n * Enable this option to prevent the panel from being clipped when the component is placed inside a container with\n * `overflow: auto|scroll`. Hoisting uses a fixed positioning strategy that works in many, but not all, scenarios.\n */\n @property({ type: Boolean }) hoist = false;\n\n /**\n * Enable portal mode to render the dropdown panel in a portal outside the component's DOM tree.\n * This provides better positioning control and prevents clipping issues in complex layouts.\n */\n @property({ type: Boolean, reflect: true }) portal = false;\n\n @property({ type: Boolean, reflect: true }) enableVisibilityEffect = false;\n\n @property({ type: Boolean, reflect: true }) enableTabClose = false;\n\n\n private portalManager: DropdownPortalManager | null = null;\n private visibilityManager?: VisibilityManager;\n\n connectedCallback() {\n super.connectedCallback();\n this.handlePanelSelect = this.handlePanelSelect.bind(this);\n this.handleKeyDown = this.handleKeyDown.bind(this);\n this.handleDocumentKeyDown = this.handleDocumentKeyDown.bind(this);\n this.handleDocumentMouseDown = this.handleDocumentMouseDown.bind(this);\n\n if (!this.containingElement) {\n this.containingElement = this;\n }\n this.emit('nile-init');\n\n requestAnimationFrame(() => {\n if (this.portal && !this.portalManager) {\n this.portalManager = new DropdownPortalManager(this);\n }\n });\n }\n\n protected async firstUpdated(_changed: PropertyValues) {\n \n this.panel.hidden = !this.open;\n\n // If the dropdown is visible on init, update its position\n if (this.open) {\n this.addOpenListeners();\n this.popup.active = true;\n }\n \n await this.updateComplete;\n const triggerNode = this.trigger.assignedElements({ flatten: true })[0] as HTMLElement | undefined;\n \n this.visibilityManager = new VisibilityManager({\n host: this,\n target: triggerNode || null,\n enableVisibilityEffect: this.enableVisibilityEffect,\n enableTabClose: this.enableTabClose,\n isOpen: () => this.open,\n onAnchorOutOfView: () => {\n this.hide();\n this.emit('nile-visibility-change', {\n visible: false,\n reason: 'anchor-out-of-view',\n });\n },\n onDocumentHidden: () => {\n this.hide();\n this.emit('nile-visibility-change', {\n visible: false,\n reason: 'document-hidden',\n });\n },\n emit: (event, detail) => this.emit(`nile-${event}`, detail),\n });\n }\n \n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.visibilityManager?.cleanup();\n this.removeOpenListeners();\n this.hide();\n this.emit('nile-destroy');\n\n if (this.portalManager) {\n this.portalManager.cleanupPortalAppend();\n this.portalManager = null;\n }\n }\n\n focusOnTrigger() {\n const trigger = this.trigger.assignedElements({ flatten: true })[0] as HTMLElement | undefined;\n if (typeof trigger?.focus === 'function') {\n trigger.focus();\n }\n }\n\n getMenu() {\n return this.panel.assignedElements({ flatten: true }).find(el => el.tagName.toLowerCase() === 'nile-menu') as\n | NileMenu\n | undefined;\n }\n\n handleKeyDown(event: KeyboardEvent) {\n // Close when escape is pressed inside an open dropdown. We need to listen on the panel itself and stop propagation\n // in case any ancestors are also listening for this key.\n if (this.open && event.key === 'Escape') {\n event.stopPropagation();\n this.hide();\n this.focusOnTrigger();\n }\n }\n\n handleDocumentKeyDown(event: KeyboardEvent) {\n // Close when escape or tab is pressed\n if (event.key === 'Escape' && this.open) {\n event.stopPropagation();\n this.focusOnTrigger();\n this.hide();\n return;\n }\n\n // Handle tabbing\n if (event.key === 'Tab') {\n // Tabbing within an open menu should close the dropdown and refocus the trigger\n if (this.open && document.activeElement?.tagName.toLowerCase() === 'nile-menu-item') {\n event.preventDefault();\n this.hide();\n this.focusOnTrigger();\n return;\n }\n\n // Tabbing outside of the containing element closes the panel\n //\n // If the dropdown is used within a shadow DOM, we need to obtain the activeElement within that shadowRoot,\n // otherwise `document.activeElement` will only return the name of the parent shadow DOM element.\n setTimeout(() => {\n const activeElement =\n this.containingElement?.getRootNode() instanceof ShadowRoot\n ? document.activeElement?.shadowRoot?.activeElement\n : document.activeElement;\n\n const hitSelf = this.containingElement && activeElement?.closest(this.containingElement.tagName.toLowerCase()) === this.containingElement;\n const hitPortalAppend = this.portal && this.portalManager?.portalContainerElement && \n (activeElement === this.portalManager.portalContainerElement || \n activeElement?.closest('.nile-dropdown-portal-append') === this.portalManager.portalContainerElement);\n\n if (!hitSelf && !hitPortalAppend) {\n this.hide();\n }\n });\n }\n }\n\n handleDocumentMouseDown(event: MouseEvent) {\n // Close when clicking outside of the containing element\n const path = event.composedPath();\n const hitSelf = this.containingElement && path.includes(this.containingElement);\n const hitPortalAppend = this.portal && this.portalManager?.portalContainerElement && path.includes(this.portalManager.portalContainerElement);\n\n if (!hitSelf && !hitPortalAppend) {\n this.hide();\n }\n }\n\n handlePanelSelect(event: any) {\n const target = event.target as HTMLElement;\n\n // Hide the dropdown when a menu item is selected\n if (!this.stayOpenOnSelect && target.tagName.toLowerCase() === 'nile-menu') {\n this.hide();\n this.focusOnTrigger();\n } else if(this.stayOpenOnSelect && target.tagName.toLowerCase() === 'nile-menu') {\n this.show();\n this.focusOnTrigger();\n }\n }\n\n handleTriggerClick() {\n if(this.noOpenOnClick){\n return;\n }\n if (this.open) {\n this.hide();\n } else {\n this.show();\n this.focusOnTrigger();\n }\n }\n\n handleTriggerKeyDown(event: KeyboardEvent) {\n // When spacebar/enter is pressed, show the panel but don't focus on the menu. This let's the user press the same\n // key again to hide the menu in case they don't want to make a selection.\n // if (['Enter'].includes(event.key)) {\n // event.preventDefault();\n // this.handleTriggerClick();\n // return;\n // }\n\n const menu = this.getMenu();\n\n if (menu) {\n const menuItems = menu.getAllItems();\n const firstMenuItem = menuItems[0];\n const lastMenuItem = menuItems[menuItems.length - 1];\n\n // When up/down is pressed, we make the assumption that the user is familiar with the menu and plans to make a\n // selection. Rather than toggle the panel, we focus on the menu (if one exists) and activate the first item for\n // faster navigation.\n if (['ArrowDown', 'ArrowUp', 'Home', 'End'].includes(event.key)) {\n event.preventDefault();\n\n // Show the menu if it's not already open\n if (!this.open) {\n this.show();\n }\n\n if (menuItems.length > 0) {\n // Focus on the first/last menu item after showing\n this.updateComplete.then(() => {\n if (event.key === 'ArrowDown' || event.key === 'Home') {\n menu.setCurrentItem(firstMenuItem);\n firstMenuItem.focus();\n }\n\n if (event.key === 'ArrowUp' || event.key === 'End') {\n menu.setCurrentItem(lastMenuItem);\n lastMenuItem.focus();\n }\n });\n }\n }\n }\n }\n\n handleTriggerKeyUp(event: KeyboardEvent) {\n // Prevent space from triggering a click event in Firefox\n if (event.key === ' ') {\n event.preventDefault();\n }\n }\n\n handleTriggerSlotChange() {\n this.updateAccessibleTrigger();\n }\n\n //\n // Slotted triggers can be arbitrary content, but we need to link them to the dropdown panel with `aria-haspopup` and\n // `aria-expanded`. These must be applied to the \"accessible trigger\" (the tabbable portion of the trigger element\n // that gets slotted in) so screen readers will understand them. The accessible trigger could be the slotted element,\n // a child of the slotted element, or an element in the slotted element's shadow root.\n //\n // For example, the accessible trigger of an <nile-button> is a <button> located inside its shadow root.\n //\n // To determine this, we assume the first tabbable element in the trigger slot is the \"accessible trigger.\"\n //\n updateAccessibleTrigger() {\n const assignedElements = this.trigger.assignedElements({ flatten: true }) as HTMLElement[];\n const accessibleTrigger = assignedElements.find(el => getTabbableBoundary(el).start);\n let target: HTMLElement;\n\n if (accessibleTrigger) {\n switch (accessibleTrigger.tagName.toLowerCase()) {\n // nile buttons have to update the internal button so it's announced correctly by screen readers\n case 'nile-button':\n case 'nile-icon-button':\n target = (accessibleTrigger as NileButton | NileIconButton).button;\n break;\n\n default:\n target = accessibleTrigger;\n }\n\n target.setAttribute('aria-haspopup', 'true');\n target.setAttribute('aria-expanded', this.open ? 'true' : 'false');\n }\n }\n\n /** Shows the dropdown panel. */\n async show() {\n if (this.open) {\n return undefined;\n }\n\n this.open = true;\n return waitForEvent(this, 'nile-after-show');\n }\n\n /** Hides the dropdown panel */\n async hide() {\n if (!this.open) {\n return undefined;\n }\n\n this.open = false;\n return waitForEvent(this, 'nile-after-hide');\n }\n\n /**\n * Instructs the dropdown menu to reposition. Useful when the position or size of the trigger changes when the menu\n * is activated.\n */\n reposition() {\n this.popup.reposition();\n }\n\n addOpenListeners() {\n this.panel.addEventListener('nile-select', this.handlePanelSelect);\n this.panel.addEventListener('keydown', this.handleKeyDown);\n document.addEventListener('keydown', this.handleDocumentKeyDown);\n document.addEventListener('mousedown', this.handleDocumentMouseDown);\n }\n\n removeOpenListeners() {\n if (this.panel) {\n this.panel.removeEventListener('nile-select', this.handlePanelSelect);\n this.panel.removeEventListener('keydown', this.handleKeyDown);\n }\n document.removeEventListener('keydown', this.handleDocumentKeyDown);\n document.removeEventListener('mousedown', this.handleDocumentMouseDown);\n }\n\n protected updated(changedProperties: PropertyValues): void {\n super.updated(changedProperties);\n \n if (changedProperties.has('portal')) {\n if (this.portal && !this.portalManager) {\n this.portalManager = new DropdownPortalManager(this);\n if (this.open) {\n this.portalManager.setupPortalAppend();\n }\n } else if (!this.portal && this.portalManager) {\n this.portalManager.cleanupPortalAppend();\n this.portalManager = null;\n }\n }\n if (changedProperties.has('disabled')) {\n this.updateTriggerDisabledState();\n }\n }\n \n private updateTriggerDisabledState() {\n const trigger = this.querySelector('[slot=\"trigger\"]') as any;\n if (!trigger) return;\n const triggerAlreadyDisabled = trigger.hasAttribute('disabled');\n if (this.disabled || triggerAlreadyDisabled) {\n trigger.disabled = true;\n this.disabled = true;\n }\n }\n\n @watch('open', { waitUntilFirstUpdate: true })\n async handleOpenChange() {\n this.visibilityManager?.setup();\n if (this.disabled) {\n this.open = false;\n return;\n }\n\n this.updateAccessibleTrigger();\n\n if (this.open) {\n // Show\n this.emit('nile-show');\n this.addOpenListeners();\n\n if (this.portal && this.portalManager) {\n this.portalManager.setupPortalAppend();\n } else if (this.portal && !this.portalManager) {\n this.portalManager = new DropdownPortalManager(this);\n this.portalManager.setupPortalAppend();\n }\n\n await stopAnimations(this);\n \n // Only show panel and animate if not using portal\n if (!this.portal) {\n this.panel.hidden = false;\n this.popup.active = true;\n const { keyframes, options } = getAnimation(this, 'dropdown.show', { dir: '' });\n await animateTo(this.popup.popup, keyframes, options);\n }\n\n this.emit('nile-after-show');\n } else {\n // Hide\n this.emit('nile-hide');\n this.removeOpenListeners();\n this.visibilityManager?.cleanup();\n\n if (this.portal && this.portalManager) {\n this.portalManager.cleanupPortalAppend();\n }\n\n await stopAnimations(this);\n \n // Only hide panel and animate if not using portal\n if (!this.portal) {\n const { keyframes, options } = getAnimation(this, 'dropdown.hide', { dir: '' });\n await animateTo(this.popup.popup, keyframes, options);\n this.panel.hidden = true;\n this.popup.active = false;\n }\n\n this.emit('nile-after-hide');\n }\n }\n\n render() {\n return html`\n <nile-popup\n part=\"base\"\n id=\"dropdown\"\n placement=${this.placement}\n distance=${this.distance}\n skidding=${this.skidding}\n strategy=${this.hoist ? 'fixed' : 'absolute'}\n sync=${this.sync}\n flip\n shift\n auto-size=\"both\"\n auto-size-padding=\"10\"\n class=${classMap({\n dropdown: true,\n 'dropdown--open': this.open\n })}\n >\n <slot\n name=\"trigger\"\n slot=\"anchor\"\n part=\"trigger\"\n class=\"dropdown__trigger\"\n @click=${this.handleTriggerClick}\n @keydown=${this.handleTriggerKeyDown}\n @keyup=${this.handleTriggerKeyUp}\n @slotchange=${this.handleTriggerSlotChange}\n ></slot>\n\n <slot\n part=\"panel\"\n class=\"dropdown__panel\"\n aria-hidden=${this.open ? 'false' : 'true'}\n aria-labelledby=\"dropdown\"\n style=${this.portal && this.portalManager ? 'display: none;' : ''}\n ></slot>\n </nile-popup>\n `;\n }\n}\n\nsetDefaultAnimation('dropdown.show', {\n keyframes: [\n { opacity: 0, scale: 0.9 },\n { opacity: 1, scale: 1 }\n ],\n options: { duration: 100, easing: 'ease' }\n});\n\nsetDefaultAnimation('dropdown.hide', {\n keyframes: [\n { opacity: 1, scale: 1 },\n { opacity: 0, scale: 0.9 }\n ],\n options: { duration: 100, easing: 'ease' }\n});\n\nexport default NileDropdown;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-dropdown': NileDropdown;\n }\n}\n"],"names":["NileDropdown","y","this","open","placement","disabled","stayOpenOnSelect","distance","noOpenOnClick","skidding","hoist","portal","enableVisibilityEffect","enableTabClose","portalManager","_this","_inherits","_u","_createClass","key","value","connectedCallback","super","handlePanelSelect","bind","handleKeyDown","handleDocumentKeyDown","handleDocumentMouseDown","containingElement","emit","requestAnimationFrame","DropdownPortalManager","_firstUpdated","_asyncToGenerator","_regeneratorRuntime","mark","_callee","_changed","panel","hidden","addOpenListeners","popup","active","_context2","next","updateComplete","triggerNode","trigger","assignedElements","flatten","visibilityManager","VisibilityManager","host","target","isOpen","onAnchorOutOfView","hide","visible","reason","onDocumentHidden","event","detail","stop","firstUpdated","disconnectedCallback","cleanup","removeOpenListeners","cleanupPortalAppend","focusOnTrigger","focus","getMenu","find","el","tagName","toLowerCase","stopPropagation","_this4","_document$activeEleme","document","activeElement","preventDefault","setTimeout","_this4$containingElem","_document$activeEleme2","_this4$portalManager","getRootNode","ShadowRoot","shadowRoot","hitSelf","closest","hitPortalAppend","portalContainerElement","_this$portalManager","path","composedPath","includes","show","handleTriggerClick","handleTriggerKeyDown","menu","menuItems","getAllItems","firstMenuItem","lastMenuItem","length","then","setCurrentItem","handleTriggerKeyUp","handleTriggerSlotChange","updateAccessibleTrigger","accessibleTrigger","getTabbableBoundary","start","button","setAttribute","_show","_callee2","wrap","_callee2$","_context3","prev","waitForEvent","_callee3","_callee3$","_context4","abrupt","reposition","addEventListener","removeEventListener","updated","changedProperties","has","setupPortalAppend","updateTriggerDisabledState","querySelector","triggerAlreadyDisabled","hasAttribute","_handleOpenChange","_callee4","_this$visibilityManag2","_d","_t","_i","_this$visibilityManag3","_d2","_t2","_i2","_callee4$","_context5","setup","stopAnimations","getAnimation","dir","animateTo","keyframes","options","handleOpenChange","render","html","_templateObject","_taggedTemplateLiteral","sync","classMap","dropdown","NileElement","styles","__decorate","query","prototype","property","type","Boolean","reflect","attribute","Number","watch","waitUntilFirstUpdate","customElement","setDefaultAnimation","opacity","scale","duration","easing"],"mappings":"qxZAkDaA,CAAAA,uBAAAA,EAAAA,EAAN,SAAAC,EAAA,qEAYuCC,EAAAA,KAAAA,CAAIC,IAAG,CAAA,CAAA,CAAA,CAMtBD,KAAAA,CAASE,SAYrB,CAAA,cAAA,CAG2BF,KAAAA,CAAQG,QAAAA,CAAAA,CAAG,CAMuBH,CAAAA,KAAAA,CAAgBI,kBAAG,CASrEJ,CAAAA,KAAAA,CAAQK,SAAG,CAGVL,CAAAA,KAAAA,CAAaM,eAAG,CAGjBN,CAAAA,KAAAA,CAAQO,QAAG,CAAA,C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nile-dropdown.cjs.js","sources":["../../../src/nile-dropdown/nile-dropdown.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport {LitElement, html, CSSResultArray, TemplateResult, PropertyValues} from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport {styles} from './nile-dropdown.css';\nimport { animateTo, stopAnimations } from '../internal/animate';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { query } from 'lit/decorators.js';\nimport { getAnimation, setDefaultAnimation } from '../utilities/animation-registry';\nimport { getTabbableBoundary } from '../internal/tabbable';\nimport { waitForEvent } from '../internal/event';\nimport { watch } from '../internal/watch';\nimport NileElement from '../internal/nile-element';\nimport type { CSSResultGroup } from 'lit';\nimport type NileButton from '../nile-button/nile-button';\nimport type NileIconButton from '../nile-icon-button/nile-icon-button';\nimport type { NileMenu } from '../nile-menu';\nimport type { NilePopup } from '../nile-popup';\nimport '../nile-popup';\nimport { DropdownPortalManager } from './portal-manager';\nimport { VisibilityManager } from '../utilities/visibility-manager.js';\n\n/**\n * Nile icon component.\n *\n * @tag nile-dropdown\n * @summary Dropdowns expose additional content that \"drops down\" in a panel.\n * @dependency nile-popup\n *\n * @slot - The dropdown's main content.\n * @slot trigger - The dropdown's trigger, usually a `<nile-button>` element.\n *\n * @event nile-show - Emitted when the dropdown opens.\n * @event nile-after-show - Emitted after the dropdown opens and all animations are complete.\n * @event nile-hide - Emitted when the dropdown closes.\n * @event nile-after-hide - Emitted after the dropdown closes and all animations are complete.\n *\n * @csspart base - The component's base wrapper.\n * @csspart trigger - The container that wraps the trigger.\n * @csspart panel - The panel that gets shown when the dropdown is open.\n *\n * @animation dropdown.show - The animation to use when showing the dropdown.\n * @animation dropdown.hide - The animation to use when hiding the dropdown.\n */\n@customElement('nile-dropdown')\nexport class NileDropdown extends NileElement {\n static styles: CSSResultGroup = styles;\n\n @query('.dropdown') popup: NilePopup;\n @query('.dropdown__trigger') trigger: HTMLSlotElement;\n @query('.dropdown__panel') panel: HTMLSlotElement;\n\n\n /**\n * Indicates whether or not the dropdown is open. You can toggle this attribute to show and hide the dropdown, or you\n * can use the `show()` and `hide()` methods and this attribute will reflect the dropdown's open state.\n */\n @property({ type: Boolean, reflect: true }) open = false;\n\n /**\n * The preferred placement of the dropdown panel. Note that the actual placement may vary as needed to keep the panel\n * inside of the viewport.\n */\n @property({ reflect: true }) placement:\n | 'top'\n | 'top-start'\n | 'top-end'\n | 'bottom'\n | 'bottom-start'\n | 'bottom-end'\n | 'right'\n | 'right-start'\n | 'right-end'\n | 'left'\n | 'left-start'\n | 'left-end' = 'bottom-start';\n\n /** Disables the dropdown so the panel will not open. */\n @property({ type: Boolean, reflect: true }) disabled = false;\n\n /**\n * By default, the dropdown is closed when an item is selected. This attribute will keep it open instead. Useful for\n * dropdowns that allow for multiple interactions.\n */\n @property({ attribute: 'stay-open-on-select', type: Boolean, reflect: true }) stayOpenOnSelect = false;\n\n /**\n * The dropdown will close when the user interacts outside of this element (e.g. clicking). Useful for composing other\n * components that use a dropdown internally.\n */\n @property({ attribute: false }) containingElement?: HTMLElement;\n\n /** The distance in pixels from which to offset the panel away from its trigger. */\n @property({ type: Number }) distance = 0;\n\n\n @property({ type: Boolean }) noOpenOnClick = false;\n\n /** The distance in pixels from which to offset the panel along its trigger. */\n @property({ type: Number }) skidding = 0;\n\n /** Syncs the popup's width or height to that of the anchor element. */\n @property() sync: 'width' | 'height' | 'both';\n\n /**\n * Enable this option to prevent the panel from being clipped when the component is placed inside a container with\n * `overflow: auto|scroll`. Hoisting uses a fixed positioning strategy that works in many, but not all, scenarios.\n */\n @property({ type: Boolean }) hoist = false;\n\n /**\n * Enable portal mode to render the dropdown panel in a portal outside the component's DOM tree.\n * This provides better positioning control and prevents clipping issues in complex layouts.\n */\n @property({ type: Boolean, reflect: true }) portal = false;\n\n @property({ type: Boolean, reflect: true }) enableVisibilityEffect = false;\n\n @property({ type: Boolean, reflect: true }) enableTabClose = false;\n\n\n private portalManager: DropdownPortalManager | null = null;\n private visibilityManager?: VisibilityManager;\n\n connectedCallback() {\n super.connectedCallback();\n this.handlePanelSelect = this.handlePanelSelect.bind(this);\n this.handleKeyDown = this.handleKeyDown.bind(this);\n this.handleDocumentKeyDown = this.handleDocumentKeyDown.bind(this);\n this.handleDocumentMouseDown = this.handleDocumentMouseDown.bind(this);\n\n if (!this.containingElement) {\n this.containingElement = this;\n }\n this.emit('nile-init');\n\n requestAnimationFrame(() => {\n if (this.portal && !this.portalManager) {\n this.portalManager = new DropdownPortalManager(this);\n }\n });\n }\n\n protected async firstUpdated(_changed: PropertyValues) {\n \n this.panel.hidden = !this.open;\n\n // If the dropdown is visible on init, update its position\n if (this.open) {\n this.addOpenListeners();\n this.popup.active = true;\n }\n \n await this.updateComplete;\n const triggerNode = this.trigger.assignedElements({ flatten: true })[0] as HTMLElement | undefined;\n \n this.visibilityManager = new VisibilityManager({\n host: this,\n target: triggerNode || null,\n enableVisibilityEffect: this.enableVisibilityEffect,\n enableTabClose: this.enableTabClose,\n isOpen: () => this.open,\n onAnchorOutOfView: () => {\n this.hide();\n this.emit('nile-visibility-change', {\n visible: false,\n reason: 'anchor-out-of-view',\n });\n },\n onDocumentHidden: () => {\n this.hide();\n this.emit('nile-visibility-change', {\n visible: false,\n reason: 'document-hidden',\n });\n },\n emit: (event, detail) => this.emit(`nile-${event}`, detail),\n });\n }\n \n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.visibilityManager?.cleanup();\n this.removeOpenListeners();\n this.hide();\n this.emit('nile-destroy');\n\n if (this.portalManager) {\n this.portalManager.cleanupPortalAppend();\n this.portalManager = null;\n }\n }\n\n focusOnTrigger() {\n const trigger = this.trigger.assignedElements({ flatten: true })[0] as HTMLElement | undefined;\n if (typeof trigger?.focus === 'function') {\n trigger.focus();\n }\n }\n\n getMenu() {\n return this.panel.assignedElements({ flatten: true }).find(el => el.tagName.toLowerCase() === 'nile-menu') as\n | NileMenu\n | undefined;\n }\n\n handleKeyDown(event: KeyboardEvent) {\n // Close when escape is pressed inside an open dropdown. We need to listen on the panel itself and stop propagation\n // in case any ancestors are also listening for this key.\n if (this.open && event.key === 'Escape') {\n event.stopPropagation();\n this.hide();\n this.focusOnTrigger();\n }\n }\n\n handleDocumentKeyDown(event: KeyboardEvent) {\n // Close when escape or tab is pressed\n if (event.key === 'Escape' && this.open) {\n event.stopPropagation();\n this.focusOnTrigger();\n this.hide();\n return;\n }\n\n // Handle tabbing\n if (event.key === 'Tab') {\n // Tabbing within an open menu should close the dropdown and refocus the trigger\n if (this.open && document.activeElement?.tagName.toLowerCase() === 'nile-menu-item') {\n event.preventDefault();\n this.hide();\n this.focusOnTrigger();\n return;\n }\n\n // Tabbing outside of the containing element closes the panel\n //\n // If the dropdown is used within a shadow DOM, we need to obtain the activeElement within that shadowRoot,\n // otherwise `document.activeElement` will only return the name of the parent shadow DOM element.\n setTimeout(() => {\n const activeElement =\n this.containingElement?.getRootNode() instanceof ShadowRoot\n ? document.activeElement?.shadowRoot?.activeElement\n : document.activeElement;\n\n const hitSelf = this.containingElement && activeElement?.closest(this.containingElement.tagName.toLowerCase()) === this.containingElement;\n const hitPortalAppend = this.portal && this.portalManager?.portalContainerElement && \n (activeElement === this.portalManager.portalContainerElement || \n activeElement?.closest('.nile-dropdown-portal-append') === this.portalManager.portalContainerElement);\n\n if (!hitSelf && !hitPortalAppend) {\n this.hide();\n }\n });\n }\n }\n\n handleDocumentMouseDown(event: MouseEvent) {\n // Close when clicking outside of the containing element\n const path = event.composedPath();\n const hitSelf = this.containingElement && path.includes(this.containingElement);\n const hitPortalAppend = this.portal && this.portalManager?.portalContainerElement && path.includes(this.portalManager.portalContainerElement);\n\n if (!hitSelf && !hitPortalAppend) {\n this.hide();\n }\n }\n\n handlePanelSelect(event: any) {\n const target = event.target as HTMLElement;\n\n // Hide the dropdown when a menu item is selected\n if (!this.stayOpenOnSelect && target.tagName.toLowerCase() === 'nile-menu') {\n this.hide();\n this.focusOnTrigger();\n } else if(this.stayOpenOnSelect && target.tagName.toLowerCase() === 'nile-menu') {\n this.show();\n this.focusOnTrigger();\n }\n }\n\n handleTriggerClick() {\n if(this.noOpenOnClick){\n return;\n }\n if (this.open) {\n this.hide();\n } else {\n this.show();\n this.focusOnTrigger();\n }\n }\n\n handleTriggerKeyDown(event: KeyboardEvent) {\n // When spacebar/enter is pressed, show the panel but don't focus on the menu. This let's the user press the same\n // key again to hide the menu in case they don't want to make a selection.\n // if (['Enter'].includes(event.key)) {\n // event.preventDefault();\n // this.handleTriggerClick();\n // return;\n // }\n\n const menu = this.getMenu();\n\n if (menu) {\n const menuItems = menu.getAllItems();\n const firstMenuItem = menuItems[0];\n const lastMenuItem = menuItems[menuItems.length - 1];\n\n // When up/down is pressed, we make the assumption that the user is familiar with the menu and plans to make a\n // selection. Rather than toggle the panel, we focus on the menu (if one exists) and activate the first item for\n // faster navigation.\n if (['ArrowDown', 'ArrowUp', 'Home', 'End'].includes(event.key)) {\n event.preventDefault();\n\n // Show the menu if it's not already open\n if (!this.open) {\n this.show();\n }\n\n if (menuItems.length > 0) {\n // Focus on the first/last menu item after showing\n this.updateComplete.then(() => {\n if (event.key === 'ArrowDown' || event.key === 'Home') {\n menu.setCurrentItem(firstMenuItem);\n firstMenuItem.focus();\n }\n\n if (event.key === 'ArrowUp' || event.key === 'End') {\n menu.setCurrentItem(lastMenuItem);\n lastMenuItem.focus();\n }\n });\n }\n }\n }\n }\n\n handleTriggerKeyUp(event: KeyboardEvent) {\n // Prevent space from triggering a click event in Firefox\n if (event.key === ' ') {\n event.preventDefault();\n }\n }\n\n handleTriggerSlotChange() {\n this.updateAccessibleTrigger();\n }\n\n //\n // Slotted triggers can be arbitrary content, but we need to link them to the dropdown panel with `aria-haspopup` and\n // `aria-expanded`. These must be applied to the \"accessible trigger\" (the tabbable portion of the trigger element\n // that gets slotted in) so screen readers will understand them. The accessible trigger could be the slotted element,\n // a child of the slotted element, or an element in the slotted element's shadow root.\n //\n // For example, the accessible trigger of an <nile-button> is a <button> located inside its shadow root.\n //\n // To determine this, we assume the first tabbable element in the trigger slot is the \"accessible trigger.\"\n //\n updateAccessibleTrigger() {\n const assignedElements = this.trigger.assignedElements({ flatten: true }) as HTMLElement[];\n const accessibleTrigger = assignedElements.find(el => getTabbableBoundary(el).start);\n let target: HTMLElement;\n\n if (accessibleTrigger) {\n switch (accessibleTrigger.tagName.toLowerCase()) {\n // nile buttons have to update the internal button so it's announced correctly by screen readers\n case 'nile-button':\n case 'nile-icon-button':\n target = (accessibleTrigger as NileButton | NileIconButton).button;\n break;\n\n default:\n target = accessibleTrigger;\n }\n\n target.setAttribute('aria-haspopup', 'true');\n target.setAttribute('aria-expanded', this.open ? 'true' : 'false');\n }\n }\n\n /** Shows the dropdown panel. */\n async show() {\n if (this.open) {\n return undefined;\n }\n\n this.open = true;\n return waitForEvent(this, 'nile-after-show');\n }\n\n /** Hides the dropdown panel */\n async hide() {\n if (!this.open) {\n return undefined;\n }\n\n this.open = false;\n return waitForEvent(this, 'nile-after-hide');\n }\n\n /**\n * Instructs the dropdown menu to reposition. Useful when the position or size of the trigger changes when the menu\n * is activated.\n */\n reposition() {\n this.popup.reposition();\n }\n\n addOpenListeners() {\n this.panel.addEventListener('nile-select', this.handlePanelSelect);\n this.panel.addEventListener('keydown', this.handleKeyDown);\n document.addEventListener('keydown', this.handleDocumentKeyDown);\n document.addEventListener('mousedown', this.handleDocumentMouseDown);\n }\n\n removeOpenListeners() {\n if (this.panel) {\n this.panel.removeEventListener('nile-select', this.handlePanelSelect);\n this.panel.removeEventListener('keydown', this.handleKeyDown);\n }\n document.removeEventListener('keydown', this.handleDocumentKeyDown);\n document.removeEventListener('mousedown', this.handleDocumentMouseDown);\n }\n\n protected updated(changedProperties: PropertyValues): void {\n super.updated(changedProperties);\n \n if (changedProperties.has('portal')) {\n if (this.portal && !this.portalManager) {\n this.portalManager = new DropdownPortalManager(this);\n if (this.open) {\n this.portalManager.setupPortalAppend();\n }\n } else if (!this.portal && this.portalManager) {\n this.portalManager.cleanupPortalAppend();\n this.portalManager = null;\n }\n }\n if (changedProperties.has('disabled')) {\n this.updateTriggerDisabledState();\n }\n }\n \n private updateTriggerDisabledState() {\n const trigger = this.querySelector('[slot=\"trigger\"]') as any;\n if (!trigger) return;\n const triggerAlreadyDisabled = trigger.hasAttribute('disabled');\n if (this.disabled || triggerAlreadyDisabled) {\n trigger.disabled = true;\n this.disabled = true;\n }\n }\n\n @watch('open', { waitUntilFirstUpdate: true })\n async handleOpenChange() {\n this.visibilityManager?.setup();\n if (this.disabled) {\n this.open = false;\n return;\n }\n\n this.updateAccessibleTrigger();\n\n if (this.open) {\n // Show\n this.emit('nile-show');\n this.addOpenListeners();\n\n if (this.portal && this.portalManager) {\n this.portalManager.setupPortalAppend();\n } else if (this.portal && !this.portalManager) {\n this.portalManager = new DropdownPortalManager(this);\n this.portalManager.setupPortalAppend();\n }\n\n await stopAnimations(this);\n \n // Only show panel and animate if not using portal\n if (!this.portal) {\n this.panel.hidden = false;\n this.popup.active = true;\n const { keyframes, options } = getAnimation(this, 'dropdown.show', { dir: '' });\n await animateTo(this.popup.popup, keyframes, options);\n }\n\n this.emit('nile-after-show');\n } else {\n // Hide\n this.emit('nile-hide');\n this.removeOpenListeners();\n this.visibilityManager?.cleanup();\n\n if (this.portal && this.portalManager) {\n this.portalManager.cleanupPortalAppend();\n }\n\n await stopAnimations(this);\n \n // Only hide panel and animate if not using portal\n if (!this.portal) {\n const { keyframes, options } = getAnimation(this, 'dropdown.hide', { dir: '' });\n await animateTo(this.popup.popup, keyframes, options);\n this.panel.hidden = true;\n this.popup.active = false;\n }\n\n this.emit('nile-after-hide');\n }\n }\n\n render() {\n return html`\n <nile-popup\n part=\"base\"\n id=\"dropdown\"\n placement=${this.placement}\n distance=${this.distance}\n skidding=${this.skidding}\n strategy=${this.hoist ? 'fixed' : 'absolute'}\n sync=${this.sync}\n flip\n shift\n auto-size=\"both\"\n auto-size-padding=\"10\"\n class=${classMap({\n dropdown: true,\n 'dropdown--open': this.open\n })}\n >\n <slot\n name=\"trigger\"\n slot=\"anchor\"\n part=\"trigger\"\n class=\"dropdown__trigger\"\n @click=${this.handleTriggerClick}\n @keydown=${this.handleTriggerKeyDown}\n @keyup=${this.handleTriggerKeyUp}\n @slotchange=${this.handleTriggerSlotChange}\n ></slot>\n\n <slot\n part=\"panel\"\n class=\"dropdown__panel\"\n aria-hidden=${this.open ? 'false' : 'true'}\n aria-labelledby=\"dropdown\"\n style=${this.portal && this.portalManager ? 'display: none;' : ''}\n ></slot>\n </nile-popup>\n `;\n }\n}\n\nsetDefaultAnimation('dropdown.show', {\n keyframes: [\n { opacity: 0, scale: 0.9 },\n { opacity: 1, scale: 1 }\n ],\n options: { duration: 100, easing: 'ease' }\n});\n\nsetDefaultAnimation('dropdown.hide', {\n keyframes: [\n { opacity: 1, scale: 1 },\n { opacity: 0, scale: 0.9 }\n ],\n options: { duration: 100, easing: 'ease' }\n});\n\nexport default NileDropdown;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-dropdown': NileDropdown;\n }\n}\n"],"names":["NileDropdown","y","constructor","this","open","placement","disabled","stayOpenOnSelect","distance","noOpenOnClick","skidding","hoist","portal","enableVisibilityEffect","enableTabClose","portalManager","_this","_inherits","_u","_createClass","key","value","connectedCallback","super","handlePanelSelect","bind","handleKeyDown","handleDocumentKeyDown","handleDocumentMouseDown","containingElement","emit","requestAnimationFrame","DropdownPortalManager","_firstUpdated","_asyncToGenerator","_regeneratorRuntime","mark","_callee","_changed","panel","hidden","addOpenListeners","popup","active","_context2","next","updateComplete","triggerNode","trigger","assignedElements","flatten","visibilityManager","VisibilityManager","host","target","isOpen","onAnchorOutOfView","hide","visible","reason","onDocumentHidden","event","detail","stop","firstUpdated","disconnectedCallback","cleanup","removeOpenListeners","cleanupPortalAppend","focusOnTrigger","focus","getMenu","find","el","tagName","toLowerCase","stopPropagation","_document$activeEleme","document","activeElement","preventDefault","setTimeout","getRootNode","ShadowRoot","shadowRoot","hitSelf","closest","hitPortalAppend","portalContainerElement","path","composedPath","includes","show","handleTriggerClick","handleTriggerKeyDown","menu","menuItems","getAllItems","firstMenuItem","lastMenuItem","length","then","setCurrentItem","handleTriggerKeyUp","handleTriggerSlotChange","updateAccessibleTrigger","accessibleTrigger","getTabbableBoundary","start","button","setAttribute","_show","_callee2","wrap","_callee2$","_context3","prev","abrupt","waitForEvent","_callee3","_callee3$","_context4","reposition","addEventListener","removeEventListener","updated","changedProperties","has","setupPortalAppend","updateTriggerDisabledState","querySelector","triggerAlreadyDisabled","hasAttribute","_handleOpenChange","_callee4","_this$visibilityManag2","_d","_t","_i","_this$visibilityManag3","_d2","_t2","_i2","_callee4$","_context5","setup","stopAnimations","getAnimation","dir","animateTo","keyframes","options","handleOpenChange","render","html","_templateObject","_taggedTemplateLiteral","sync","classMap","dropdown","NileElement","styles","__decorate","query","prototype","property","type","Boolean","reflect","attribute","Number","watch","waitUntilFirstUpdate","customElement","setDefaultAnimation","opacity","scale","duration","easing"],"mappings":"wkaAkDaA,4BAAN,SAAAC,EAAA,CAAAC,KAAAA,KAAAA,CAAAA,eAAAA,MAAAA,CAAAA,qCAYuCC,KAAAA,CAAIC,IAAG,CAAA,CAAA,CAAA,CAMtBD,KAAAA,CAASE,SAAAA,CAYrB,cAG2BF,CAAAA,KAAAA,CAAQG,UAAG,CAMuBH,CAAAA,KAAAA,CAAgBI,kBAAG,CASrEJ,CAAAA,KAAAA,CAAQK,SAAG,CAGVL,CAAAA,KAAAA,CAAaM,aAAG,CAAA,CAAA,CAAA,CAGjBN,KAAAA,CAAQO,QAAAA,CAAG,EASVP,KAAAA,CAAKQ,KAAAA,CAAAA,CAAG,EAMOR,KAAAA,CAAMS,MAAAA,CAAAA,CAAG,EAETT,KAAAA,CAAsBU,sBAAAA,CAAAA,CAAG,CAEzBV,CAAAA,KAAAA,CAAcW,cAAG,CAAA,CAAA,CAAA,CAGrDX,KAAAA,CAAaY,aAAiC,CAAA,IA+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CAAAA,OAAAA,CAASC,OAAS,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAA+BxK,CAAAoK,CAAAA,SAAAA,CAAA,gBAAA,CAAA,IAAA,EAAA,CAAA,CAkV7DF,CAAA,CAAA,CADLS,EAAM,MAAQ,CAAA,CAAEC,oBAAsB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAuDtC5K,CAAAoK,CAAAA,SAAAA,CAAA,mBAAA,IAjdUpK,CAAAA,CAAAA,OAAAA,KAAAA,CAAAA,CAAYkK,CAAA,CAAA,CADxBW,CAAc,CAAA,eAAA,CAAA,CAAA,CACF7K,IA6fb8K,CAAoB,CAAA,eAAA,CAAiB,CACnCxB,SAAAA,CAAW,CACT,CAAEyB,OAAS,CAAA,CAAA,CAAGC,KAAO,CAAA,EAAA,CAAA,CACrB,CAAED,OAAAA,CAAS,CAAGC,CAAAA,KAAAA,CAAO,IAEvBzB,OAAS,CAAA,CAAE0B,QAAU,CAAA,GAAA,CAAKC,MAAQ,CAAA,MAAA,CAAA,CAAA,CAAA,CAGpCJ,EAAoB,eAAiB,CAAA,CACnCxB,SAAW,CAAA,CACT,CAAEyB,OAAAA,CAAS,EAAGC,KAAO,CAAA,CAAA,CAAA,CACrB,CAAED,OAAAA,CAAS,CAAGC,CAAAA,KAAAA,CAAO,EAEvBzB,CAAAA,CAAAA,CAAAA,OAAAA,CAAS,CAAE0B,QAAAA,CAAU,GAAKC,CAAAA,MAAAA,CAAQ"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{__decorate as t}from"tslib";import{html as i}from"lit";import{query as s,property as e,customElement as n}from"lit/decorators.js";import{s as o}from"./nile-dropdown.css.esm.js";import{s as h,a}from"../internal/animate.esm.js";import{classMap as r}from"lit/directives/class-map.js";import{s as l,g as d}from"../utilities/animation-registry.esm.js";import{g as p}from"../internal/tabbable.esm.js";import{w as c}from"../internal/event.esm.js";import{w as m}from"../internal/watch.esm.js";import{N as u}from"../internal/nile-element.esm.js";import"../nile-popup/nile-popup.esm.js";import{D as f}from"./portal-manager.esm.js";import{V as w}from"../utilities/visibility-manager.esm.js";import"../floating-ui.dom-cc9126da.esm.js";import"../nile-popup/nile-popup.css.esm.js";import"./portal-utils.esm.js";let y=class extends u{constructor(){super(...arguments),this.open=!1,this.placement="bottom-start",this.disabled=!1,this.stayOpenOnSelect=!1,this.distance=0,this.noOpenOnClick=!1,this.skidding=0,this.hoist=!1,this.portal=!1,this.enableVisibilityEffect=!1,this.enableTabClose=!1,this.portalManager=null}connectedCallback(){super.connectedCallback(),this.handlePanelSelect=this.handlePanelSelect.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleDocumentKeyDown=this.handleDocumentKeyDown.bind(this),this.handleDocumentMouseDown=this.handleDocumentMouseDown.bind(this),this.containingElement||(this.containingElement=this),this.emit("nile-init"),requestAnimationFrame((()=>{this.portal&&!this.portalManager&&(this.portalManager=new f(this))}))}async firstUpdated(t){this.panel.hidden=!this.open,this.open&&(this.addOpenListeners(),this.popup.active=!0),await this.updateComplete;const i=this.trigger.assignedElements({flatten:!0})[0];this.visibilityManager=new w({host:this,target:i||null,enableVisibilityEffect:this.enableVisibilityEffect,enableTabClose:this.enableTabClose,isOpen:()=>this.open,onAnchorOutOfView:()=>{this.hide(),this.emit("nile-visibility-change",{visible:!1,reason:"anchor-out-of-view"})},onDocumentHidden:()=>{this.hide(),this.emit("nile-visibility-change",{visible:!1,reason:"document-hidden"})},emit:(t,i)=>this.emit(`nile-${t}`,i)})}disconnectedCallback(){super.disconnectedCallback(),this.visibilityManager?.cleanup(),this.removeOpenListeners(),this.hide(),this.emit("nile-destroy"),this.portalManager&&(this.portalManager.cleanupPortalAppend(),this.portalManager=null)}focusOnTrigger(){const t=this.trigger.assignedElements({flatten:!0})[0];"function"==typeof t?.focus&&t.focus()}getMenu(){return this.panel.assignedElements({flatten:!0}).find((t=>"nile-menu"===t.tagName.toLowerCase()))}handleKeyDown(t){this.open&&"Escape"===t.key&&(t.stopPropagation(),this.hide(),this.focusOnTrigger())}handleDocumentKeyDown(t){if("Escape"===t.key&&this.open)return t.stopPropagation(),this.focusOnTrigger(),void this.hide();if("Tab"===t.key){if(this.open&&"nile-menu-item"===document.activeElement?.tagName.toLowerCase())return t.preventDefault(),this.hide(),void this.focusOnTrigger();setTimeout((()=>{const t=this.containingElement?.getRootNode()instanceof ShadowRoot?document.activeElement?.shadowRoot?.activeElement:document.activeElement,i=this.containingElement&&t?.closest(this.containingElement.tagName.toLowerCase())===this.containingElement,s=this.portal&&this.portalManager?.portalContainerElement&&(t===this.portalManager.portalContainerElement||t?.closest(".nile-dropdown-portal-append")===this.portalManager.portalContainerElement);i||s||this.hide()}))}}handleDocumentMouseDown(t){const i=t.composedPath(),s=this.containingElement&&i.includes(this.containingElement),e=this.portal&&this.portalManager?.portalContainerElement&&i.includes(this.portalManager.portalContainerElement);s||e||this.hide()}handlePanelSelect(t){const i=t.target;this.stayOpenOnSelect||"nile-menu"!==i.tagName.toLowerCase()?this.stayOpenOnSelect&&"nile-menu"===i.tagName.toLowerCase()&&(this.show(),this.focusOnTrigger()):(this.hide(),this.focusOnTrigger())}handleTriggerClick(){this.noOpenOnClick||(this.open?this.hide():(this.show(),this.focusOnTrigger()))}handleTriggerKeyDown(t){const i=this.getMenu();if(i){const s=i.getAllItems(),e=s[0],n=s[s.length-1];["ArrowDown","ArrowUp","Home","End"].includes(t.key)&&(t.preventDefault(),this.open||this.show(),s.length>0&&this.updateComplete.then((()=>{"ArrowDown"!==t.key&&"Home"!==t.key||(i.setCurrentItem(e),e.focus()),"ArrowUp"!==t.key&&"End"!==t.key||(i.setCurrentItem(n),n.focus())})))}}handleTriggerKeyUp(t){" "===t.key&&t.preventDefault()}handleTriggerSlotChange(){this.updateAccessibleTrigger()}updateAccessibleTrigger(){const t=this.trigger.assignedElements({flatten:!0}).find((t=>p(t).start));let i;if(t){switch(t.tagName.toLowerCase()){case"nile-button":case"nile-icon-button":i=t.button;break;default:i=t}i.setAttribute("aria-haspopup","true"),i.setAttribute("aria-expanded",this.open?"true":"false")}}async show(){if(!this.open)return this.open=!0,c(this,"nile-after-show")}async hide(){if(this.open)return this.open=!1,c(this,"nile-after-hide")}reposition(){this.popup.reposition()}addOpenListeners(){this.panel.addEventListener("nile-select",this.handlePanelSelect),this.panel.addEventListener("keydown",this.handleKeyDown),document.addEventListener("keydown",this.handleDocumentKeyDown),document.addEventListener("mousedown",this.handleDocumentMouseDown)}removeOpenListeners(){this.panel&&(this.panel.removeEventListener("nile-select",this.handlePanelSelect),this.panel.removeEventListener("keydown",this.handleKeyDown)),document.removeEventListener("keydown",this.handleDocumentKeyDown),document.removeEventListener("mousedown",this.handleDocumentMouseDown)}updated(t){super.updated(t),t.has("portal")&&(this.portal&&!this.portalManager?(this.portalManager=new f(this),this.open&&this.portalManager.setupPortalAppend()):!this.portal&&this.portalManager&&(this.portalManager.cleanupPortalAppend(),this.portalManager=null)),t.has("disabled")&&this.updateTriggerDisabledState()}updateTriggerDisabledState(){const t=this.querySelector('[slot="trigger"]');if(!t)return;const i=t.hasAttribute("disabled");(this.disabled||i)&&(t.disabled=!0,this.disabled=!0)}async handleOpenChange(){if(this.visibilityManager?.setup(),this.disabled)this.open=!1;else if(this.updateAccessibleTrigger(),this.open){if(this.emit("nile-show"),this.addOpenListeners(),this.portal&&this.portalManager?this.portalManager.setupPortalAppend():this.portal&&!this.portalManager&&(this.portalManager=new f(this),this.portalManager.setupPortalAppend()),await h(this),!this.portal){this.panel.hidden=!1,this.popup.active=!0;const{keyframes:t,options:i}=d(this,"dropdown.show",{dir:""});await a(this.popup.popup,t,i)}this.emit("nile-after-show")}else{if(this.emit("nile-hide"),this.removeOpenListeners(),this.visibilityManager?.cleanup(),this.portal&&this.portalManager&&this.portalManager.cleanupPortalAppend(),await h(this),!this.portal){const{keyframes:t,options:i}=d(this,"dropdown.hide",{dir:""});await a(this.popup.popup,t,i),this.panel.hidden=!0,this.popup.active=!1}this.emit("nile-after-hide")}}render(){return i`
|
|
1
|
+
import{__decorate as t}from"tslib";import{html as i}from"lit";import{query as s,property as e,customElement as n}from"lit/decorators.js";import{s as o}from"./nile-dropdown.css.esm.js";import{s as h,a}from"../internal/animate.esm.js";import{classMap as r}from"lit/directives/class-map.js";import{s as l,g as d}from"../utilities/animation-registry.esm.js";import{g as p}from"../internal/tabbable.esm.js";import{w as c}from"../internal/event.esm.js";import{w as m}from"../internal/watch.esm.js";import{N as u}from"../internal/nile-element.esm.js";import"../nile-popup/nile-popup.esm.js";import{D as f}from"./portal-manager.esm.js";import{V as w}from"../utilities/visibility-manager.esm.js";import"../internal/accessibility/a11y.state.enum.esm.js";import"../internal/accessibility/a11y.property.enum.esm.js";import"../internal/accessibility/role.enum.esm.js";import"../floating-ui.dom-cc9126da.esm.js";import"../nile-popup/nile-popup.css.esm.js";import"./portal-utils.esm.js";let y=class extends u{constructor(){super(...arguments),this.open=!1,this.placement="bottom-start",this.disabled=!1,this.stayOpenOnSelect=!1,this.distance=0,this.noOpenOnClick=!1,this.skidding=0,this.hoist=!1,this.portal=!1,this.enableVisibilityEffect=!1,this.enableTabClose=!1,this.portalManager=null}connectedCallback(){super.connectedCallback(),this.handlePanelSelect=this.handlePanelSelect.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleDocumentKeyDown=this.handleDocumentKeyDown.bind(this),this.handleDocumentMouseDown=this.handleDocumentMouseDown.bind(this),this.containingElement||(this.containingElement=this),this.emit("nile-init"),requestAnimationFrame((()=>{this.portal&&!this.portalManager&&(this.portalManager=new f(this))}))}async firstUpdated(t){this.panel.hidden=!this.open,this.open&&(this.addOpenListeners(),this.popup.active=!0),await this.updateComplete;const i=this.trigger.assignedElements({flatten:!0})[0];this.visibilityManager=new w({host:this,target:i||null,enableVisibilityEffect:this.enableVisibilityEffect,enableTabClose:this.enableTabClose,isOpen:()=>this.open,onAnchorOutOfView:()=>{this.hide(),this.emit("nile-visibility-change",{visible:!1,reason:"anchor-out-of-view"})},onDocumentHidden:()=>{this.hide(),this.emit("nile-visibility-change",{visible:!1,reason:"document-hidden"})},emit:(t,i)=>this.emit(`nile-${t}`,i)})}disconnectedCallback(){super.disconnectedCallback(),this.visibilityManager?.cleanup(),this.removeOpenListeners(),this.hide(),this.emit("nile-destroy"),this.portalManager&&(this.portalManager.cleanupPortalAppend(),this.portalManager=null)}focusOnTrigger(){const t=this.trigger.assignedElements({flatten:!0})[0];"function"==typeof t?.focus&&t.focus()}getMenu(){return this.panel.assignedElements({flatten:!0}).find((t=>"nile-menu"===t.tagName.toLowerCase()))}handleKeyDown(t){this.open&&"Escape"===t.key&&(t.stopPropagation(),this.hide(),this.focusOnTrigger())}handleDocumentKeyDown(t){if("Escape"===t.key&&this.open)return t.stopPropagation(),this.focusOnTrigger(),void this.hide();if("Tab"===t.key){if(this.open&&"nile-menu-item"===document.activeElement?.tagName.toLowerCase())return t.preventDefault(),this.hide(),void this.focusOnTrigger();setTimeout((()=>{const t=this.containingElement?.getRootNode()instanceof ShadowRoot?document.activeElement?.shadowRoot?.activeElement:document.activeElement,i=this.containingElement&&t?.closest(this.containingElement.tagName.toLowerCase())===this.containingElement,s=this.portal&&this.portalManager?.portalContainerElement&&(t===this.portalManager.portalContainerElement||t?.closest(".nile-dropdown-portal-append")===this.portalManager.portalContainerElement);i||s||this.hide()}))}}handleDocumentMouseDown(t){const i=t.composedPath(),s=this.containingElement&&i.includes(this.containingElement),e=this.portal&&this.portalManager?.portalContainerElement&&i.includes(this.portalManager.portalContainerElement);s||e||this.hide()}handlePanelSelect(t){const i=t.target;this.stayOpenOnSelect||"nile-menu"!==i.tagName.toLowerCase()?this.stayOpenOnSelect&&"nile-menu"===i.tagName.toLowerCase()&&(this.show(),this.focusOnTrigger()):(this.hide(),this.focusOnTrigger())}handleTriggerClick(){this.noOpenOnClick||(this.open?this.hide():(this.show(),this.focusOnTrigger()))}handleTriggerKeyDown(t){const i=this.getMenu();if(i){const s=i.getAllItems(),e=s[0],n=s[s.length-1];["ArrowDown","ArrowUp","Home","End"].includes(t.key)&&(t.preventDefault(),this.open||this.show(),s.length>0&&this.updateComplete.then((()=>{"ArrowDown"!==t.key&&"Home"!==t.key||(i.setCurrentItem(e),e.focus()),"ArrowUp"!==t.key&&"End"!==t.key||(i.setCurrentItem(n),n.focus())})))}}handleTriggerKeyUp(t){" "===t.key&&t.preventDefault()}handleTriggerSlotChange(){this.updateAccessibleTrigger()}updateAccessibleTrigger(){const t=this.trigger.assignedElements({flatten:!0}).find((t=>p(t).start));let i;if(t){switch(t.tagName.toLowerCase()){case"nile-button":case"nile-icon-button":i=t.button;break;default:i=t}i.setAttribute("aria-haspopup","true"),i.setAttribute("aria-expanded",this.open?"true":"false")}}async show(){if(!this.open)return this.open=!0,c(this,"nile-after-show")}async hide(){if(this.open)return this.open=!1,c(this,"nile-after-hide")}reposition(){this.popup.reposition()}addOpenListeners(){this.panel.addEventListener("nile-select",this.handlePanelSelect),this.panel.addEventListener("keydown",this.handleKeyDown),document.addEventListener("keydown",this.handleDocumentKeyDown),document.addEventListener("mousedown",this.handleDocumentMouseDown)}removeOpenListeners(){this.panel&&(this.panel.removeEventListener("nile-select",this.handlePanelSelect),this.panel.removeEventListener("keydown",this.handleKeyDown)),document.removeEventListener("keydown",this.handleDocumentKeyDown),document.removeEventListener("mousedown",this.handleDocumentMouseDown)}updated(t){super.updated(t),t.has("portal")&&(this.portal&&!this.portalManager?(this.portalManager=new f(this),this.open&&this.portalManager.setupPortalAppend()):!this.portal&&this.portalManager&&(this.portalManager.cleanupPortalAppend(),this.portalManager=null)),t.has("disabled")&&this.updateTriggerDisabledState()}updateTriggerDisabledState(){const t=this.querySelector('[slot="trigger"]');if(!t)return;const i=t.hasAttribute("disabled");(this.disabled||i)&&(t.disabled=!0,this.disabled=!0)}async handleOpenChange(){if(this.visibilityManager?.setup(),this.disabled)this.open=!1;else if(this.updateAccessibleTrigger(),this.open){if(this.emit("nile-show"),this.addOpenListeners(),this.portal&&this.portalManager?this.portalManager.setupPortalAppend():this.portal&&!this.portalManager&&(this.portalManager=new f(this),this.portalManager.setupPortalAppend()),await h(this),!this.portal){this.panel.hidden=!1,this.popup.active=!0;const{keyframes:t,options:i}=d(this,"dropdown.show",{dir:""});await a(this.popup.popup,t,i)}this.emit("nile-after-show")}else{if(this.emit("nile-hide"),this.removeOpenListeners(),this.visibilityManager?.cleanup(),this.portal&&this.portalManager&&this.portalManager.cleanupPortalAppend(),await h(this),!this.portal){const{keyframes:t,options:i}=d(this,"dropdown.hide",{dir:""});await a(this.popup.popup,t,i),this.panel.hidden=!0,this.popup.active=!1}this.emit("nile-after-hide")}}render(){return i`
|
|
2
2
|
<nile-popup
|
|
3
3
|
part="base"
|
|
4
4
|
id="dropdown"
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
System.register(["./nile-empty-state.cjs.js","tslib","lit","lit/decorators.js","lit/directives/class-map.js","./nile-empty-state.css.cjs.js","../internal/nile-element.cjs.js","lit/directives/if-defined.js"],function(_export,_context){"use strict";return{setters:[function(_nileEmptyStateCjsJs){_export("NileEmptyState",_nileEmptyStateCjsJs.N);},function(_tslib){},function(_lit){},function(_litDecoratorsJs){},function(_litDirectivesClassMapJs){},function(_nileEmptyStateCssCjsJs){},function(_internalNileElementCjsJs){},function(_litDirectivesIfDefinedJs){}],execute:function execute(){}};});
|
|
1
|
+
System.register(["./nile-empty-state.cjs.js","tslib","lit","lit/decorators.js","lit/directives/class-map.js","./nile-empty-state.css.cjs.js","../internal/nile-element.cjs.js","../internal/accessibility/a11y.state.enum.cjs.js","../internal/accessibility/a11y.property.enum.cjs.js","../internal/accessibility/role.enum.cjs.js","lit/directives/if-defined.js"],function(_export,_context){"use strict";return{setters:[function(_nileEmptyStateCjsJs){_export("NileEmptyState",_nileEmptyStateCjsJs.N);},function(_tslib){},function(_lit){},function(_litDecoratorsJs){},function(_litDirectivesClassMapJs){},function(_nileEmptyStateCssCjsJs){},function(_internalNileElementCjsJs){},function(_internalAccessibilityA11yStateEnumCjsJs){},function(_internalAccessibilityA11yPropertyEnumCjsJs){},function(_internalAccessibilityRoleEnumCjsJs){},function(_litDirectivesIfDefinedJs){}],execute:function execute(){}};});
|
|
2
2
|
//# sourceMappingURL=index.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{N as NileEmptyState}from"./nile-empty-state.esm.js";import"tslib";import"lit";import"lit/decorators.js";import"lit/directives/class-map.js";import"./nile-empty-state.css.esm.js";import"../internal/nile-element.esm.js";import"lit/directives/if-defined.js";
|
|
1
|
+
export{N as NileEmptyState}from"./nile-empty-state.esm.js";import"tslib";import"lit";import"lit/decorators.js";import"lit/directives/class-map.js";import"./nile-empty-state.css.esm.js";import"../internal/nile-element.esm.js";import"../internal/accessibility/a11y.state.enum.esm.js";import"../internal/accessibility/a11y.property.enum.esm.js";import"../internal/accessibility/role.enum.esm.js";import"lit/directives/if-defined.js";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
function _typeof(o){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o;}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o;},_typeof(o);}System.register(["tslib","lit","lit/decorators.js","lit/directives/class-map.js","./nile-empty-state.css.cjs.js","../internal/nile-element.cjs.js","lit/directives/if-defined.js"],function(_export,_context){"use strict";var t,i,s,e,o,a,n,l,r,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,_templateObject9,_templateObject10,_templateObject11,c;function _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}function _classCallCheck(a,n){if(!(a instanceof n))throw new TypeError("Cannot call a class as a function");}function _defineProperties(e,r){for(var t=0;t<r.length;t++){var o=r[t];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,_toPropertyKey(o.key),o);}}function _createClass(e,r,t){return r&&_defineProperties(e.prototype,r),t&&_defineProperties(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e;}function _toPropertyKey(t){var i=_toPrimitive(t,"string");return"symbol"==_typeof(i)?i:i+"";}function _toPrimitive(t,r){if("object"!=_typeof(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,r||"default");if("object"!=_typeof(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.");}return("string"===r?String:Number)(t);}function _callSuper(t,o,e){return o=_getPrototypeOf(o),_possibleConstructorReturn(t,_isNativeReflectConstruct()?Reflect.construct(o,e||[],_getPrototypeOf(t).constructor):o.apply(t,e));}function _possibleConstructorReturn(t,e){if(e&&("object"==_typeof(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(t);}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e;}function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t;})();}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t);},_getPrototypeOf(t);}function _inherits(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf(t,e);}function _setPrototypeOf(t,e){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t;},_setPrototypeOf(t,e);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_lit){i=_lit.html;s=_lit.nothing;},function(_litDecoratorsJs){e=_litDecoratorsJs.property;o=_litDecoratorsJs.customElement;},function(_litDirectivesClassMapJs){a=_litDirectivesClassMapJs.classMap;},function(_nileEmptyStateCssCjsJs){n=_nileEmptyStateCssCjsJs.s;},function(_internalNileElementCjsJs){l=_internalNileElementCjsJs.N;},function(_litDirectivesIfDefinedJs){r=_litDirectivesIfDefinedJs.ifDefined;}],execute:function execute(){_export("N",c=/*#__PURE__*/function(_l){function c(){var _this;_classCallCheck(this,c);_this=_callSuper(this,c,arguments),_this.size="md",_this.variant="tonal",_this.icon="var(--nile-icon-error, var(--ng-icon-x-circle))",_this.grayscale=!1,_this.text="Empty State",_this.subText="No Data",_this.svgIconSize=40;return _this;}_inherits(c,_l);return _createClass(c,[{key:"render",value:function render(){return i(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n <div part=\"container\" class=\"","\">\n <div part=\"body\" class=\"","\">\n\n ","\n\n ","\n\n ","\n\n <div part=\"text-section\" class=\"empty__state__text-section\">\n <div part=\"text\" class=\"empty-state__text\">","</div>\n <div part=\"subtitle\" class=\"empty-state__subtext\">","</div>\n </div>\n </div>\n\n <div part=\"actions\" class=\"empty-state-actions\">\n <slot></slot>\n </div>\n </div>\n "])),a({"empty-state":!0,"empty-state--sm":"sm"==this.size,"empty-state--md":"md"==this.size,"empty-state--lg":"lg"==this.size}),a({"empty-state__body":!0}),"content"==this.variant?i(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["\n <div part=\"content-image\" class=\"empty-state__body--content\">\n ","\n </div>"])),this.icon||this.svgIconUrl?i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n <div part=\"icon-wrapper\" class=\"empty-state__img__icon\">\n ","\n </div>"])),this.svgIconUrl?i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n <nile-icon customSvgPath=\"","\" size=\"","\" color=\"","\" noFill></nile-icon>\n <!-- <nile-icon customSvgPath=\"","\" size=\"","\" color=\"","\"></nile-icon> -->\n "])),this.svgIconUrl,this.svgIconSize,r(this.svgIconColor),this.svgIconUrl,this.svgIconSize,this.svgIconColor?this.svgIconColor:"#ddd"):i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["\n <nile-icon name=\"","\" color=\"white\" size=\"","\"></nile-icon>\n "])),this.icon,"sm"==this.size||"md"==this.size?24:28)):s):s,"tonal"==this.variant?i(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n <div part=\"tonal-body\" class=\"empty-state__body--tonal\">\n ","\n </div>"])),this.svgIconUrl?i(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n <nile-icon customSvgPath=\"","\" size=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" color=\"","\" noFill></nile-icon>\n "])),this.svgIconUrl,this.svgIconSize,r(this.svgIconColor)):i(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["\n <nile-icon name=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"40\"></nile-icon>\n "])),this.icon)):s,"flat"==this.variant?i(_templateObject9||(_templateObject9=_taggedTemplateLiteral(["\n <div part=\"flat-body\" class=\"empty-state__body--flat\">\n\t\t\t\t\t<span class=\"nile-flat-type-icon\">\n\t\t\t\t\t\t","\n\t\t\t\t\t</span>\n </div>"])),this.svgIconUrl?i(_templateObject10||(_templateObject10=_taggedTemplateLiteral(["\n <nile-icon customSvgPath=\"","\" size=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" variant=\"secondary\" color=\"","\" noFill></nile-icon>\n "])),this.svgIconUrl,this.svgIconSize,r(this.svgIconColor)):i(_templateObject11||(_templateObject11=_taggedTemplateLiteral(["\n <nile-icon name=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"","\" variant=\"secondary\"></nile-icon>\n "])),this.icon,"sm"==this.size||"md"==this.size?24:28)):s,this.text,this.subText);}}],[{key:"styles",get:function get(){return[n];}}]);}(l));t([e()],c.prototype,"size",void 0),t([e()],c.prototype,"variant",void 0),t([e()],c.prototype,"icon",void 0),t([e({type:Boolean})],c.prototype,"grayscale",void 0),t([e()],c.prototype,"text",void 0),t([e({attribute:"sub-text"})],c.prototype,"subText",void 0),t([e()],c.prototype,"svgIconUrl",void 0),t([e({type:Number})],c.prototype,"svgIconSize",void 0),t([e({type:String})],c.prototype,"svgIconColor",void 0),_export("N",c=t([o("nile-empty-state")],c));}};});
|
|
1
|
+
function _typeof(o){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o;}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o;},_typeof(o);}System.register(["tslib","lit","lit/decorators.js","lit/directives/class-map.js","./nile-empty-state.css.cjs.js","../internal/nile-element.cjs.js","lit/directives/if-defined.js","../internal/accessibility/a11y.state.enum.cjs.js","../internal/accessibility/a11y.property.enum.cjs.js","../internal/accessibility/role.enum.cjs.js"],function(_export,_context){"use strict";var t,i,s,e,o,a,n,l,r,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,_templateObject9,_templateObject10,_templateObject11,c;function _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}function _classCallCheck(a,n){if(!(a instanceof n))throw new TypeError("Cannot call a class as a function");}function _defineProperties(e,r){for(var t=0;t<r.length;t++){var o=r[t];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,_toPropertyKey(o.key),o);}}function _createClass(e,r,t){return r&&_defineProperties(e.prototype,r),t&&_defineProperties(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e;}function _toPropertyKey(t){var i=_toPrimitive(t,"string");return"symbol"==_typeof(i)?i:i+"";}function _toPrimitive(t,r){if("object"!=_typeof(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,r||"default");if("object"!=_typeof(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.");}return("string"===r?String:Number)(t);}function _callSuper(t,o,e){return o=_getPrototypeOf(o),_possibleConstructorReturn(t,_isNativeReflectConstruct()?Reflect.construct(o,e||[],_getPrototypeOf(t).constructor):o.apply(t,e));}function _possibleConstructorReturn(t,e){if(e&&("object"==_typeof(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(t);}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e;}function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t;})();}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t);},_getPrototypeOf(t);}function _inherits(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf(t,e);}function _setPrototypeOf(t,e){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t;},_setPrototypeOf(t,e);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_lit){i=_lit.html;s=_lit.nothing;},function(_litDecoratorsJs){e=_litDecoratorsJs.property;o=_litDecoratorsJs.customElement;},function(_litDirectivesClassMapJs){a=_litDirectivesClassMapJs.classMap;},function(_nileEmptyStateCssCjsJs){n=_nileEmptyStateCssCjsJs.s;},function(_internalNileElementCjsJs){l=_internalNileElementCjsJs.N;},function(_litDirectivesIfDefinedJs){r=_litDirectivesIfDefinedJs.ifDefined;},function(_internalAccessibilityA11yStateEnumCjsJs){},function(_internalAccessibilityA11yPropertyEnumCjsJs){},function(_internalAccessibilityRoleEnumCjsJs){}],execute:function execute(){_export("N",c=/*#__PURE__*/function(_l){function c(){var _this;_classCallCheck(this,c);_this=_callSuper(this,c,arguments),_this.size="md",_this.variant="tonal",_this.icon="var(--nile-icon-error, var(--ng-icon-x-circle))",_this.grayscale=!1,_this.text="Empty State",_this.subText="No Data",_this.svgIconSize=40;return _this;}_inherits(c,_l);return _createClass(c,[{key:"render",value:function render(){return i(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n <div part=\"container\" class=\"","\">\n <div part=\"body\" class=\"","\">\n\n ","\n\n ","\n\n ","\n\n <div part=\"text-section\" class=\"empty__state__text-section\">\n <div part=\"text\" class=\"empty-state__text\">","</div>\n <div part=\"subtitle\" class=\"empty-state__subtext\">","</div>\n </div>\n </div>\n\n <div part=\"actions\" class=\"empty-state-actions\">\n <slot></slot>\n </div>\n </div>\n "])),a({"empty-state":!0,"empty-state--sm":"sm"==this.size,"empty-state--md":"md"==this.size,"empty-state--lg":"lg"==this.size}),a({"empty-state__body":!0}),"content"==this.variant?i(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["\n <div part=\"content-image\" class=\"empty-state__body--content\">\n ","\n </div>"])),this.icon||this.svgIconUrl?i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n <div part=\"icon-wrapper\" class=\"empty-state__img__icon\">\n ","\n </div>"])),this.svgIconUrl?i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n <nile-icon customSvgPath=\"","\" size=\"","\" color=\"","\" noFill></nile-icon>\n <!-- <nile-icon customSvgPath=\"","\" size=\"","\" color=\"","\"></nile-icon> -->\n "])),this.svgIconUrl,this.svgIconSize,r(this.svgIconColor),this.svgIconUrl,this.svgIconSize,this.svgIconColor?this.svgIconColor:"#ddd"):i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["\n <nile-icon name=\"","\" color=\"white\" size=\"","\"></nile-icon>\n "])),this.icon,"sm"==this.size||"md"==this.size?24:28)):s):s,"tonal"==this.variant?i(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n <div part=\"tonal-body\" class=\"empty-state__body--tonal\">\n ","\n </div>"])),this.svgIconUrl?i(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n <nile-icon customSvgPath=\"","\" size=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" color=\"","\" noFill></nile-icon>\n "])),this.svgIconUrl,this.svgIconSize,r(this.svgIconColor)):i(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["\n <nile-icon name=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"40\"></nile-icon>\n "])),this.icon)):s,"flat"==this.variant?i(_templateObject9||(_templateObject9=_taggedTemplateLiteral(["\n <div part=\"flat-body\" class=\"empty-state__body--flat\">\n\t\t\t\t\t<span class=\"nile-flat-type-icon\">\n\t\t\t\t\t\t","\n\t\t\t\t\t</span>\n </div>"])),this.svgIconUrl?i(_templateObject10||(_templateObject10=_taggedTemplateLiteral(["\n <nile-icon customSvgPath=\"","\" size=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" variant=\"secondary\" color=\"","\" noFill></nile-icon>\n "])),this.svgIconUrl,this.svgIconSize,r(this.svgIconColor)):i(_templateObject11||(_templateObject11=_taggedTemplateLiteral(["\n <nile-icon name=\"","\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"","\" variant=\"secondary\"></nile-icon>\n "])),this.icon,"sm"==this.size||"md"==this.size?24:28)):s,this.text,this.subText);}}],[{key:"styles",get:function get(){return[n];}}]);}(l));t([e()],c.prototype,"size",void 0),t([e()],c.prototype,"variant",void 0),t([e()],c.prototype,"icon",void 0),t([e({type:Boolean})],c.prototype,"grayscale",void 0),t([e()],c.prototype,"text",void 0),t([e({attribute:"sub-text"})],c.prototype,"subText",void 0),t([e()],c.prototype,"svgIconUrl",void 0),t([e({type:Number})],c.prototype,"svgIconSize",void 0),t([e({type:String})],c.prototype,"svgIconColor",void 0),_export("N",c=t([o("nile-empty-state")],c));}};});
|
|
2
2
|
//# sourceMappingURL=nile-empty-state.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-empty-state.cjs.js","sources":["../../../src/nile-empty-state/nile-empty-state.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { html, nothing, CSSResultArray, TemplateResult } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { styles } from './nile-empty-state.css';\nimport NileElement from '../internal/nile-element';\nimport { ifDefined } from 'lit/directives/if-defined.js';\n/**\n * Nile empty-state component.\n *\n * @tag nile-empty-state\n *\n */\n@customElement('nile-empty-state')\nexport class NileEmptyState extends NileElement {\n\n /**\n * The styles for nile-empty-state\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n @property() size: 'sm' | 'md' | 'lg' = 'md';\n\n @property() variant:\n | 'flat'\n | 'content'\n | 'tonal' = 'tonal';\n\n @property() icon: string = 'var(--nile-icon-error, var(--ng-icon-x-circle))';\n @property({type:Boolean}) grayscale: boolean = false;\n\n @property() text: String = 'Empty State';\n @property({attribute:'sub-text'}) subText: String = 'No Data';\n @property() svgIconUrl: string;\n @property({type: Number}) svgIconSize: number = 40;\n @property({type: String}) svgIconColor: string;\n\n /* #endregion */\n\n /* #region Methods */\n\n /**\n * Render method\n * @slot This is a slot test\n */\n public render(): TemplateResult {\n return html`\n <div part=\"container\" class=\"${classMap({\n 'empty-state': true,\n 'empty-state--sm': this.size == 'sm',\n 'empty-state--md': this.size == 'md',\n 'empty-state--lg': this.size == 'lg'\n })}\">\n <div part=\"body\" class=\"${classMap({ 'empty-state__body': true })}\">\n\n ${this.variant == 'content' ? html`\n <div part=\"content-image\" class=\"empty-state__body--content\">\n ${!this.icon && !this.svgIconUrl ? nothing : html`\n <div part=\"icon-wrapper\" class=\"empty-state__img__icon\">\n ${this.svgIconUrl ? html`\n <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" color=\"${ifDefined(this.svgIconColor)}\" noFill></nile-icon>\n <!-- <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" color=\"${this.svgIconColor ? this.svgIconColor : '#ddd'}\"></nile-icon> -->\n ` : html`\n <nile-icon name=\"${this.icon}\" color=\"white\" size=\"${this.size == 'sm' ? 24 : this.size == 'md' ? 24 : 28}\"></nile-icon>\n `}\n </div>`\n }\n </div>`: nothing\n }\n\n ${this.variant == 'tonal' ? html`\n <div part=\"tonal-body\" class=\"empty-state__body--tonal\">\n ${this.svgIconUrl ? html`\n <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" color=\"${ifDefined(this.svgIconColor)}\" noFill></nile-icon>\n ` : html`\n <nile-icon name=\"${this.icon}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"40\"></nile-icon>\n `}\n </div>`: nothing\n }\n\n ${this.variant == 'flat' ? html`\n <div part=\"flat-body\" class=\"empty-state__body--flat\">\n\t\t\t\t\t<span class=\"nile-flat-type-icon\">\n\t\t\t\t\t\t${this.svgIconUrl ? html`\n <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" variant=\"secondary\" color=\"${ifDefined(this.svgIconColor)}\" noFill></nile-icon>\n ` : html`\n <nile-icon name=\"${this.icon}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"${this.size == 'sm' ? 24 : this.size == 'md' ? 24 : 28}\" variant=\"secondary\"></nile-icon>\n `}\n\t\t\t\t\t</span>\n </div>`: nothing\n }\n\n <div part=\"text-section\" class=\"empty__state__text-section\">\n <div part=\"text\" class=\"empty-state__text\">${this.text}</div>\n <div part=\"subtitle\" class=\"empty-state__subtext\">${this.subText}</div>\n </div>\n </div>\n\n <div part=\"actions\" class=\"empty-state-actions\">\n <slot></slot>\n </div>\n </div>\n `;\n }\n\n /* #endregion */\n}\n\nexport default NileEmptyState;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-empty-state': NileEmptyState;\n }\n}\n"],"names":["NileEmptyState","c","constructor","this","size","variant","icon","grayscale","text","subText","svgIconSize","_this","_inherits","_l","_createClass","key","value","render","html","_templateObject","_taggedTemplateLiteral","classMap","_templateObject2","svgIconUrl","_templateObject3","_templateObject4","ifDefined","svgIconColor","_templateObject5","nothing","_templateObject6","_templateObject7","_templateObject8","_templateObject9","_templateObject10","_templateObject11","get","styles","NileElement","__decorate","property","prototype","type","Boolean","attribute","Number","String","customElement"],"mappings":"
|
|
1
|
+
{"version":3,"file":"nile-empty-state.cjs.js","sources":["../../../src/nile-empty-state/nile-empty-state.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { html, nothing, CSSResultArray, TemplateResult } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { styles } from './nile-empty-state.css';\nimport NileElement from '../internal/nile-element';\nimport { ifDefined } from 'lit/directives/if-defined.js';\n/**\n * Nile empty-state component.\n *\n * @tag nile-empty-state\n *\n */\n@customElement('nile-empty-state')\nexport class NileEmptyState extends NileElement {\n\n /**\n * The styles for nile-empty-state\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n @property() size: 'sm' | 'md' | 'lg' = 'md';\n\n @property() variant:\n | 'flat'\n | 'content'\n | 'tonal' = 'tonal';\n\n @property() icon: string = 'var(--nile-icon-error, var(--ng-icon-x-circle))';\n @property({type:Boolean}) grayscale: boolean = false;\n\n @property() text: String = 'Empty State';\n @property({attribute:'sub-text'}) subText: String = 'No Data';\n @property() svgIconUrl: string;\n @property({type: Number}) svgIconSize: number = 40;\n @property({type: String}) svgIconColor: string;\n\n /* #endregion */\n\n /* #region Methods */\n\n /**\n * Render method\n * @slot This is a slot test\n */\n public render(): TemplateResult {\n return html`\n <div part=\"container\" class=\"${classMap({\n 'empty-state': true,\n 'empty-state--sm': this.size == 'sm',\n 'empty-state--md': this.size == 'md',\n 'empty-state--lg': this.size == 'lg'\n })}\">\n <div part=\"body\" class=\"${classMap({ 'empty-state__body': true })}\">\n\n ${this.variant == 'content' ? html`\n <div part=\"content-image\" class=\"empty-state__body--content\">\n ${!this.icon && !this.svgIconUrl ? nothing : html`\n <div part=\"icon-wrapper\" class=\"empty-state__img__icon\">\n ${this.svgIconUrl ? html`\n <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" color=\"${ifDefined(this.svgIconColor)}\" noFill></nile-icon>\n <!-- <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" color=\"${this.svgIconColor ? this.svgIconColor : '#ddd'}\"></nile-icon> -->\n ` : html`\n <nile-icon name=\"${this.icon}\" color=\"white\" size=\"${this.size == 'sm' ? 24 : this.size == 'md' ? 24 : 28}\"></nile-icon>\n `}\n </div>`\n }\n </div>`: nothing\n }\n\n ${this.variant == 'tonal' ? html`\n <div part=\"tonal-body\" class=\"empty-state__body--tonal\">\n ${this.svgIconUrl ? html`\n <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" color=\"${ifDefined(this.svgIconColor)}\" noFill></nile-icon>\n ` : html`\n <nile-icon name=\"${this.icon}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"40\"></nile-icon>\n `}\n </div>`: nothing\n }\n\n ${this.variant == 'flat' ? html`\n <div part=\"flat-body\" class=\"empty-state__body--flat\">\n\t\t\t\t\t<span class=\"nile-flat-type-icon\">\n\t\t\t\t\t\t${this.svgIconUrl ? html`\n <nile-icon customSvgPath=\"${this.svgIconUrl}\" size=\"${this.svgIconSize}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" variant=\"secondary\" color=\"${ifDefined(this.svgIconColor)}\" noFill></nile-icon>\n ` : html`\n <nile-icon name=\"${this.icon}\" method=\"var(--nile-svg-method-fill, var(--ng-svg-method-stroke))\" size=\"${this.size == 'sm' ? 24 : this.size == 'md' ? 24 : 28}\" variant=\"secondary\"></nile-icon>\n `}\n\t\t\t\t\t</span>\n </div>`: nothing\n }\n\n <div part=\"text-section\" class=\"empty__state__text-section\">\n <div part=\"text\" class=\"empty-state__text\">${this.text}</div>\n <div part=\"subtitle\" class=\"empty-state__subtext\">${this.subText}</div>\n </div>\n </div>\n\n <div part=\"actions\" class=\"empty-state-actions\">\n <slot></slot>\n </div>\n </div>\n `;\n }\n\n /* #endregion */\n}\n\nexport default NileEmptyState;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-empty-state': NileEmptyState;\n }\n}\n"],"names":["NileEmptyState","c","constructor","this","size","variant","icon","grayscale","text","subText","svgIconSize","_this","_inherits","_l","_createClass","key","value","render","html","_templateObject","_taggedTemplateLiteral","classMap","_templateObject2","svgIconUrl","_templateObject3","_templateObject4","ifDefined","svgIconColor","_templateObject5","nothing","_templateObject6","_templateObject7","_templateObject8","_templateObject9","_templateObject10","_templateObject11","get","styles","NileElement","__decorate","property","prototype","type","Boolean","attribute","Number","String","customElement"],"mappings":"80HAoBaA,CAAAA,uBAAAA,EAAAA,EAAN,SAAAC,EAAA,CAAAC,KAAAA,KAAAA,CAAAA,eAAAA,MAAAA,CAAAA,qCAUOC,KAAAA,CAAIC,IAAAA,CAAwB,KAE5BD,KAAAA,CAAOE,OAAAA,CAGL,OAEFF,CAAAA,KAAAA,CAAIG,IAAW,CAAA,iDAAA,CACDH,KAAAA,CAASI,SAAAA,CAAAA,CAAY,CAEnCJ,CAAAA,KAAAA,CAAIK,IAAW,CA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CxC,CAAAyC,CAAAA,SAAAA,CAAA,WAAA,EAEjCF,CAAAA,CAAAA,CAAAA,CAAA,CAAXC,CAAAA,CAAAA,CAAAA,CAAAA,CAGqBxC,EAAAyC,SAAA,CAAA,SAAA,CAAA,IAAA,IAEVF,CAAA,CAAA,CAAXC,KAA4ExC,CAAAyC,CAAAA,SAAAA,CAAA,MAAA,CAAA,IAAA,EAAA,CAAA,CACnDF,EAAA,CAAzBC,CAAAA,CAAS,CAACE,IAAAA,CAAKC,WAAqC3C,CAAAyC,CAAAA,SAAAA,CAAA,WAAA,CAAA,IAAA,EAAA,CAAA,CAEzCF,EAAA,CAAXC,CAAAA,CAAAA,CAAAA,CAAAA,CAAwCxC,EAAAyC,SAAA,CAAA,MAAA,CAAA,IAAA,IACPF,CAAA,CAAA,CAAjCC,CAAS,CAAA,CAACI,UAAU,UAAyC5C,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAyC,SAAA,CAAA,SAAA,CAAA,IAAA,IAClDF,CAAA,CAAA,CAAXC,CAA8BxC,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAyC,UAAA,YAAA,CAAA,IAAA,EAAA,CAAA,CACLF,EAAA,CAAzBC,CAAAA,CAAS,CAACE,IAAMG,CAAAA,MAAAA,CAAAA,CAAAA,CAAAA,CAAkC7C,CAAAyC,CAAAA,SAAAA,CAAA,kBAAA,EACzBF,CAAAA,CAAAA,CAAAA,CAAA,CAAzBC,CAAAA,CAAS,CAACE,IAAMI,CAAAA,MAAAA,CAAAA,CAAAA,CAAAA,CAA8B9C,CAAAyC,CAAAA,SAAAA,CAAA,mBAAA,EAxBpCzC,CAAAA,CAAAA,OAAAA,KAAAA,CAAAA,CAAcuC,EAAA,CAD1BQ,CAAAA,CAAc,qBACF/C"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{__decorate as t}from"tslib";import{html as i,nothing as s}from"lit";import{property as e,customElement as o}from"lit/decorators.js";import{classMap as a}from"lit/directives/class-map.js";import{s as n}from"./nile-empty-state.css.esm.js";import{N as l}from"../internal/nile-element.esm.js";import{ifDefined as r}from"lit/directives/if-defined.js";let
|
|
1
|
+
import{__decorate as t}from"tslib";import{html as i,nothing as s}from"lit";import{property as e,customElement as o}from"lit/decorators.js";import{classMap as a}from"lit/directives/class-map.js";import{s as n}from"./nile-empty-state.css.esm.js";import{N as l}from"../internal/nile-element.esm.js";import{ifDefined as r}from"lit/directives/if-defined.js";import"../internal/accessibility/a11y.state.enum.esm.js";import"../internal/accessibility/a11y.property.enum.esm.js";import"../internal/accessibility/role.enum.esm.js";let m=class extends l{constructor(){super(...arguments),this.size="md",this.variant="tonal",this.icon="var(--nile-icon-error, var(--ng-icon-x-circle))",this.grayscale=!1,this.text="Empty State",this.subText="No Data",this.svgIconSize=40}static get styles(){return[n]}render(){return i`
|
|
2
2
|
<div part="container" class="${a({"empty-state":!0,"empty-state--sm":"sm"==this.size,"empty-state--md":"md"==this.size,"empty-state--lg":"lg"==this.size})}">
|
|
3
3
|
<div part="body" class="${a({"empty-state__body":!0})}">
|
|
4
4
|
|
|
@@ -45,4 +45,4 @@ import{__decorate as t}from"tslib";import{html as i,nothing as s}from"lit";impor
|
|
|
45
45
|
<slot></slot>
|
|
46
46
|
</div>
|
|
47
47
|
</div>
|
|
48
|
-
`}};t([e()],
|
|
48
|
+
`}};t([e()],m.prototype,"size",void 0),t([e()],m.prototype,"variant",void 0),t([e()],m.prototype,"icon",void 0),t([e({type:Boolean})],m.prototype,"grayscale",void 0),t([e()],m.prototype,"text",void 0),t([e({attribute:"sub-text"})],m.prototype,"subText",void 0),t([e()],m.prototype,"svgIconUrl",void 0),t([e({type:Number})],m.prototype,"svgIconSize",void 0),t([e({type:String})],m.prototype,"svgIconColor",void 0),m=t([o("nile-empty-state")],m);export{m as N};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
System.register(["./nile-file-preview.cjs.js","tslib","./nile-file-preview.css.cjs.js","lit","../internal/nile-element.cjs.js","lit/decorators.js","./utils/nile-file-preview.util.cjs.js","./types/nile-file-preview.enums.cjs.js","./nile-file-preview.template.cjs.js"],function(_export,_context){"use strict";return{setters:[function(_nileFilePreviewCjsJs){_export("NileFilePreview",_nileFilePreviewCjsJs.N);},function(_tslib){},function(_nileFilePreviewCssCjsJs){},function(_lit){},function(_internalNileElementCjsJs){},function(_litDecoratorsJs){},function(_utilsNileFilePreviewUtilCjsJs){},function(_typesNileFilePreviewEnumsCjsJs){},function(_nileFilePreviewTemplateCjsJs){}],execute:function execute(){}};});
|
|
1
|
+
System.register(["./nile-file-preview.cjs.js","tslib","./nile-file-preview.css.cjs.js","lit","../internal/nile-element.cjs.js","../internal/accessibility/a11y.state.enum.cjs.js","../internal/accessibility/a11y.property.enum.cjs.js","../internal/accessibility/role.enum.cjs.js","lit/decorators.js","./utils/nile-file-preview.util.cjs.js","./types/nile-file-preview.enums.cjs.js","./nile-file-preview.template.cjs.js"],function(_export,_context){"use strict";return{setters:[function(_nileFilePreviewCjsJs){_export("NileFilePreview",_nileFilePreviewCjsJs.N);},function(_tslib){},function(_nileFilePreviewCssCjsJs){},function(_lit){},function(_internalNileElementCjsJs){},function(_internalAccessibilityA11yStateEnumCjsJs){},function(_internalAccessibilityA11yPropertyEnumCjsJs){},function(_internalAccessibilityRoleEnumCjsJs){},function(_litDecoratorsJs){},function(_utilsNileFilePreviewUtilCjsJs){},function(_typesNileFilePreviewEnumsCjsJs){},function(_nileFilePreviewTemplateCjsJs){}],execute:function execute(){}};});
|
|
2
2
|
//# sourceMappingURL=index.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{N as NileFilePreview}from"./nile-file-preview.esm.js";import"tslib";import"./nile-file-preview.css.esm.js";import"lit";import"../internal/nile-element.esm.js";import"lit/decorators.js";import"./utils/nile-file-preview.util.esm.js";import"./types/nile-file-preview.enums.esm.js";import"./nile-file-preview.template.esm.js";
|
|
1
|
+
export{N as NileFilePreview}from"./nile-file-preview.esm.js";import"tslib";import"./nile-file-preview.css.esm.js";import"lit";import"../internal/nile-element.esm.js";import"../internal/accessibility/a11y.state.enum.esm.js";import"../internal/accessibility/a11y.property.enum.esm.js";import"../internal/accessibility/role.enum.esm.js";import"lit/decorators.js";import"./utils/nile-file-preview.util.esm.js";import"./types/nile-file-preview.enums.esm.js";import"./nile-file-preview.template.esm.js";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
function _typeof(o){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o;}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o;},_typeof(o);}System.register(["tslib","./nile-file-preview.css.cjs.js","../internal/nile-element.cjs.js","lit/decorators.js","./utils/nile-file-preview.util.cjs.js","./types/nile-file-preview.enums.cjs.js","lit","./nile-file-preview.template.cjs.js"],function(_export,_context){"use strict";var t,i,s,e,h,a,r,l,o,n,p,c,d,m,f,u,y,v,j,w,_templateObject,_templateObject2,g;function _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}function _regeneratorRuntime(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */_regeneratorRuntime=function _regeneratorRuntime(){return e;};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value;},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function define(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e];}try{define({},"");}catch(t){define=function define(t,e,r){return t[e]=r;};}function wrap(t,e,r,n){var i=e&&e.prototype instanceof Generator?e:Generator,a=Object.create(i.prototype),c=new Context(n||[]);return o(a,"_invoke",{value:makeInvokeMethod(t,r,c)}),a;}function tryCatch(t,e,r){try{return{type:"normal",arg:t.call(e,r)};}catch(t){return{type:"throw",arg:t};}}e.wrap=wrap;var h="suspendedStart",l="suspendedYield",f="executing",s="completed",y={};function Generator(){}function GeneratorFunction(){}function GeneratorFunctionPrototype(){}var p={};define(p,a,function(){return this;});var d=Object.getPrototypeOf,v=d&&d(d(values([])));v&&v!==r&&n.call(v,a)&&(p=v);var g=GeneratorFunctionPrototype.prototype=Generator.prototype=Object.create(p);function defineIteratorMethods(t){["next","throw","return"].forEach(function(e){define(t,e,function(t){return this._invoke(e,t);});});}function AsyncIterator(t,e){function invoke(r,o,i,a){var c=tryCatch(t[r],t,o);if("throw"!==c.type){var u=c.arg,h=u.value;return h&&"object"==_typeof(h)&&n.call(h,"__await")?e.resolve(h.__await).then(function(t){invoke("next",t,i,a);},function(t){invoke("throw",t,i,a);}):e.resolve(h).then(function(t){u.value=t,i(u);},function(t){return invoke("throw",t,i,a);});}a(c.arg);}var r;o(this,"_invoke",{value:function value(t,n){function callInvokeWithMethodAndArg(){return new e(function(e,r){invoke(t,n,e,r);});}return r=r?r.then(callInvokeWithMethodAndArg,callInvokeWithMethodAndArg):callInvokeWithMethodAndArg();}});}function makeInvokeMethod(e,r,n){var o=h;return function(i,a){if(o===f)throw Error("Generator is already running");if(o===s){if("throw"===i)throw a;return{value:t,done:!0};}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=maybeInvokeDelegate(c,n);if(u){if(u===y)continue;return u;}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=s,n.arg;n.dispatchException(n.arg);}else"return"===n.method&&n.abrupt("return",n.arg);o=f;var p=tryCatch(e,r,n);if("normal"===p.type){if(o=n.done?s:l,p.arg===y)continue;return{value:p.arg,done:n.done};}"throw"===p.type&&(o=s,n.method="throw",n.arg=p.arg);}};}function maybeInvokeDelegate(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator["return"]&&(r.method="return",r.arg=t,maybeInvokeDelegate(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var i=tryCatch(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,y;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y);}function pushTryEntry(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e);}function resetTryEntry(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e;}function Context(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(pushTryEntry,this),this.reset(!0);}function values(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function next(){for(;++o<e.length;)if(n.call(e,o))return next.value=e[o],next.done=!1,next;return next.value=t,next.done=!0,next;};return i.next=i;}}throw new TypeError(_typeof(e)+" is not iterable");}return GeneratorFunction.prototype=GeneratorFunctionPrototype,o(g,"constructor",{value:GeneratorFunctionPrototype,configurable:!0}),o(GeneratorFunctionPrototype,"constructor",{value:GeneratorFunction,configurable:!0}),GeneratorFunction.displayName=define(GeneratorFunctionPrototype,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===GeneratorFunction||"GeneratorFunction"===(e.displayName||e.name));},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,GeneratorFunctionPrototype):(t.__proto__=GeneratorFunctionPrototype,define(t,u,"GeneratorFunction")),t.prototype=Object.create(g),t;},e.awrap=function(t){return{__await:t};},defineIteratorMethods(AsyncIterator.prototype),define(AsyncIterator.prototype,c,function(){return this;}),e.AsyncIterator=AsyncIterator,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new AsyncIterator(wrap(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then(function(t){return t.done?t.value:a.next();});},defineIteratorMethods(g),define(g,u,"Generator"),define(g,a,function(){return this;}),define(g,"toString",function(){return"[object Generator]";}),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function next(){for(;r.length;){var t=r.pop();if(t in e)return next.value=t,next.done=!1,next;}return next.done=!0,next;};},e.values=values,Context.prototype={constructor:Context,reset:function reset(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(resetTryEntry),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t);},stop:function stop(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval;},dispatchException:function dispatchException(e){if(this.done)throw e;var r=this;function handle(n,o){return a.type="throw",a.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o;}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return handle("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}else if(c){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}}}},abrupt:function abrupt(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break;}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a);},complete:function complete(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y;},finish:function finish(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),resetTryEntry(r),y;}},"catch":function _catch(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;resetTryEntry(r);}return o;}}throw Error("illegal catch attempt");},delegateYield:function delegateYield(e,r,n){return this.delegate={iterator:values(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y;}},e;}function asyncGeneratorStep(n,t,e,r,o,a,c){try{var i=n[a](c),u=i.value;}catch(n){return void e(n);}i.done?t(u):Promise.resolve(u).then(r,o);}function _asyncToGenerator(n){return function(){var t=this,e=arguments;return new Promise(function(r,o){var a=n.apply(t,e);function _next(n){asyncGeneratorStep(a,r,o,_next,_throw,"next",n);}function _throw(n){asyncGeneratorStep(a,r,o,_next,_throw,"throw",n);}_next(void 0);});};}function _classCallCheck(a,n){if(!(a instanceof n))throw new TypeError("Cannot call a class as a function");}function _defineProperties(e,r){for(var t=0;t<r.length;t++){var o=r[t];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,_toPropertyKey(o.key),o);}}function _createClass(e,r,t){return r&&_defineProperties(e.prototype,r),t&&_defineProperties(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e;}function _toPropertyKey(t){var i=_toPrimitive(t,"string");return"symbol"==_typeof(i)?i:i+"";}function _toPrimitive(t,r){if("object"!=_typeof(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,r||"default");if("object"!=_typeof(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.");}return("string"===r?String:Number)(t);}function _callSuper(t,o,e){return o=_getPrototypeOf(o),_possibleConstructorReturn(t,_isNativeReflectConstruct()?Reflect.construct(o,e||[],_getPrototypeOf(t).constructor):o.apply(t,e));}function _possibleConstructorReturn(t,e){if(e&&("object"==_typeof(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(t);}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e;}function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t;})();}function _superPropGet(t,o,e,r){var p=_get(_getPrototypeOf(1&r?t.prototype:t),o,e);return 2&r&&"function"==typeof p?function(t){return p.apply(e,t);}:p;}function _get(){return _get="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,r){var p=_superPropBase(e,t);if(p){var n=Object.getOwnPropertyDescriptor(p,t);return n.get?n.get.call(arguments.length<3?e:r):n.value;}},_get.apply(null,arguments);}function _superPropBase(t,o){for(;!{}.hasOwnProperty.call(t,o)&&null!==(t=_getPrototypeOf(t)););return t;}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t);},_getPrototypeOf(t);}function _inherits(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf(t,e);}function _setPrototypeOf(t,e){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t;},_setPrototypeOf(t,e);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_nileFilePreviewCssCjsJs){i=_nileFilePreviewCssCjsJs.s;},function(_internalNileElementCjsJs){s=_internalNileElementCjsJs.N;},function(_litDecoratorsJs){e=_litDecoratorsJs.property;h=_litDecoratorsJs.customElement;},function(_utilsNileFilePreviewUtilCjsJs){a=_utilsNileFilePreviewUtilCjsJs.i;r=_utilsNileFilePreviewUtilCjsJs.a;},function(_typesNileFilePreviewEnumsCjsJs){l=_typesNileFilePreviewEnumsCjsJs.F;o=_typesNileFilePreviewEnumsCjsJs.a;n=_typesNileFilePreviewEnumsCjsJs.b;p=_typesNileFilePreviewEnumsCjsJs.c;},function(_lit){c=_lit.html;},function(_nileFilePreviewTemplateCjsJs){d=_nileFilePreviewTemplateCjsJs.g;m=_nileFilePreviewTemplateCjsJs.a;f=_nileFilePreviewTemplateCjsJs.b;u=_nileFilePreviewTemplateCjsJs.c;y=_nileFilePreviewTemplateCjsJs.d;v=_nileFilePreviewTemplateCjsJs.e;j=_nileFilePreviewTemplateCjsJs.f;w=_nileFilePreviewTemplateCjsJs.h;}],execute:function execute(){_export("N",g=/*#__PURE__*/function(_s){function g(){var _this;_classCallCheck(this,g);_this=_callSuper(this,g,arguments),_this.errorMessage="",_this.fileUrl="",_this.uploadStatus=0,_this.state=l.DEFAULT,_this.variant=o.HORIZONTAL,_this.inputFileName="",_this.showFileType=!1,_this.inputFileHtml=null,_this.originalUrl="",_this.isStringTruncated=!1;return _this;}_inherits(g,_s);return _createClass(g,[{key:"connectedCallback",value:function connectedCallback(){_superPropGet(g,"connectedCallback",this,3)([]),this.emit(n.NILE_INIT);}},{key:"firstUpdated",value:function firstUpdated(t){_superPropGet(g,"firstUpdated",this,3)([t]);}},{key:"updated",value:function updated(t){t.has("uploadStatus")&&this.uploadStatus?this.uploadStatus<100?this.createUploadState(this.inputFile,this.uploadStatus):this.createState(this.inputFile):t.has("inputFile")&&this.inputFile?(this.createState(this.inputFile),this.emit(n.NILE_RECEIVE)):t.has("fileUrl")&&this.fileUrl?(this.handleFileUrl(this.fileUrl),this.emit(n.NILE_RECEIVE)):t.has("errorMessage")&&this.createState(this.inputFile);}},{key:"createUploadState",value:function createUploadState(t,i){var s=this.variant===o.HORIZONTAL;this.inputFileHtml=s?d(t,i,this):m(t,i,this),this.requestUpdate();}},{key:"handleFileUrl",value:function(){var _handleFileUrl=_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(t){var _i,_s2,_e,_h,_i2;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:this.originalUrl=t;_context2.prev=1;_context2.next=4;return fetch(t);case 4:_i=_context2.sent;_context2.next=7;return _i.blob();case 7:_s2=_context2.sent;_e=this.inputFileName||t.split("/").pop()||p.UNKNOWN_FILE_NAME;_h=new File([_s2],_e,{type:_s2.type});this.createState(_h);_context2.next=17;break;case 13:_context2.prev=13;_context2.t0=_context2["catch"](1);_i2=new File([],this.inputFileName||p.UNKNOWN_FILE_NAME,{type:"application/octet-stream"});this.errorMessage=p.FAILED_TO_LOAD,console.error(this.errorMessage),this.inputFileHtml=this.variant===o.HORIZONTAL?f(_i2,this.errorMessage,this.originalUrl,this):u(_i2,this.errorMessage,this.originalUrl,this),this.requestUpdate();case 17:case"end":return _context2.stop();}},_callee,this,[[1,13]]);}));function handleFileUrl(_x){return _handleFileUrl.apply(this,arguments);}return handleFileUrl;}()},{key:"createState",value:function(){var _createState=_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(t){var i,_s3,_s4;return _regeneratorRuntime().wrap(function _callee2$(_context3){while(1)switch(_context3.prev=_context3.next){case 0:i=this.variant===o.HORIZONTAL;if(!this.errorMessage){_context3.next=5;break;}this.inputFileHtml=i?f(t,this.errorMessage,this.originalUrl,this):u(t,this.errorMessage,this.originalUrl,this);_context3.next=32;break;case 5:_s3=!1;_context3.prev=6;_context3.t0=t;if(!_context3.t0){_context3.next=12;break;}_context3.next=11;return a(t);case 11:_context3.t0=_context3.sent;case 12:_s3=_context3.t0;_context3.next=18;break;case 15:_context3.prev=15;_context3.t1=_context3["catch"](6);_s3=!1;case 18:if(!_s3){_context3.next=31;break;}_context3.prev=19;_context3.next=22;return r(t);case 22:_s4=_context3.sent;this.inputFileHtml=i?y(_s4,t,this.originalUrl,this.showFileType):v(_s4,t,this.originalUrl,this.showFileType);_context3.next=29;break;case 26:_context3.prev=26;_context3.t2=_context3["catch"](19);this.inputFileHtml=i?j(t,this.originalUrl,this.showFileType):w(t,this.originalUrl,this.showFileType);case 29:_context3.next=32;break;case 31:this.inputFileHtml=i?j(t,this.originalUrl,this.showFileType):w(t,this.originalUrl,this.showFileType);case 32:this.requestUpdate();case 33:case"end":return _context3.stop();}},_callee2,this,[[6,15],[19,26]]);}));function createState(_x2){return _createState.apply(this,arguments);}return createState;}()},{key:"render",value:function render(){var _this$inputFileHtml;return c(_templateObject||(_templateObject=_taggedTemplateLiteral(["",""])),(_this$inputFileHtml=this.inputFileHtml)!==null&&_this$inputFileHtml!==void 0?_this$inputFileHtml:c(_templateObject2||(_templateObject2=_taggedTemplateLiteral([""]))));}},{key:"disconnectedCallback",value:function disconnectedCallback(){_superPropGet(g,"disconnectedCallback",this,3)([]),this.emit(n.NILE_DESTROY);}}],[{key:"styles",get:function get(){return[i];}}]);}(s));t([e({type:String})],g.prototype,"errorMessage",void 0),t([e({type:Object})],g.prototype,"inputFile",void 0),t([e({type:String})],g.prototype,"fileUrl",void 0),t([e({type:Number})],g.prototype,"uploadStatus",void 0),t([e({type:String})],g.prototype,"state",void 0),t([e({type:String})],g.prototype,"variant",void 0),t([e({type:String})],g.prototype,"inputFileName",void 0),t([e({type:Boolean,reflect:!0,attribute:!0})],g.prototype,"showFileType",void 0),_export("N",g=t([h("nile-file-preview")],g));}};});
|
|
1
|
+
function _typeof(o){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o;}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o;},_typeof(o);}System.register(["tslib","./nile-file-preview.css.cjs.js","../internal/nile-element.cjs.js","lit/decorators.js","./utils/nile-file-preview.util.cjs.js","./types/nile-file-preview.enums.cjs.js","lit","./nile-file-preview.template.cjs.js","../internal/accessibility/a11y.state.enum.cjs.js","../internal/accessibility/a11y.property.enum.cjs.js","../internal/accessibility/role.enum.cjs.js"],function(_export,_context){"use strict";var t,i,s,e,h,a,r,l,o,n,c,p,m,u,y,d,f,j,v,w,_templateObject,_templateObject2,b;function _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}function _regeneratorRuntime(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */_regeneratorRuntime=function _regeneratorRuntime(){return e;};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value;},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function define(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e];}try{define({},"");}catch(t){define=function define(t,e,r){return t[e]=r;};}function wrap(t,e,r,n){var i=e&&e.prototype instanceof Generator?e:Generator,a=Object.create(i.prototype),c=new Context(n||[]);return o(a,"_invoke",{value:makeInvokeMethod(t,r,c)}),a;}function tryCatch(t,e,r){try{return{type:"normal",arg:t.call(e,r)};}catch(t){return{type:"throw",arg:t};}}e.wrap=wrap;var h="suspendedStart",l="suspendedYield",f="executing",s="completed",y={};function Generator(){}function GeneratorFunction(){}function GeneratorFunctionPrototype(){}var p={};define(p,a,function(){return this;});var d=Object.getPrototypeOf,v=d&&d(d(values([])));v&&v!==r&&n.call(v,a)&&(p=v);var g=GeneratorFunctionPrototype.prototype=Generator.prototype=Object.create(p);function defineIteratorMethods(t){["next","throw","return"].forEach(function(e){define(t,e,function(t){return this._invoke(e,t);});});}function AsyncIterator(t,e){function invoke(r,o,i,a){var c=tryCatch(t[r],t,o);if("throw"!==c.type){var u=c.arg,h=u.value;return h&&"object"==_typeof(h)&&n.call(h,"__await")?e.resolve(h.__await).then(function(t){invoke("next",t,i,a);},function(t){invoke("throw",t,i,a);}):e.resolve(h).then(function(t){u.value=t,i(u);},function(t){return invoke("throw",t,i,a);});}a(c.arg);}var r;o(this,"_invoke",{value:function value(t,n){function callInvokeWithMethodAndArg(){return new e(function(e,r){invoke(t,n,e,r);});}return r=r?r.then(callInvokeWithMethodAndArg,callInvokeWithMethodAndArg):callInvokeWithMethodAndArg();}});}function makeInvokeMethod(e,r,n){var o=h;return function(i,a){if(o===f)throw Error("Generator is already running");if(o===s){if("throw"===i)throw a;return{value:t,done:!0};}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=maybeInvokeDelegate(c,n);if(u){if(u===y)continue;return u;}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=s,n.arg;n.dispatchException(n.arg);}else"return"===n.method&&n.abrupt("return",n.arg);o=f;var p=tryCatch(e,r,n);if("normal"===p.type){if(o=n.done?s:l,p.arg===y)continue;return{value:p.arg,done:n.done};}"throw"===p.type&&(o=s,n.method="throw",n.arg=p.arg);}};}function maybeInvokeDelegate(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator["return"]&&(r.method="return",r.arg=t,maybeInvokeDelegate(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var i=tryCatch(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,y;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y);}function pushTryEntry(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e);}function resetTryEntry(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e;}function Context(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(pushTryEntry,this),this.reset(!0);}function values(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function next(){for(;++o<e.length;)if(n.call(e,o))return next.value=e[o],next.done=!1,next;return next.value=t,next.done=!0,next;};return i.next=i;}}throw new TypeError(_typeof(e)+" is not iterable");}return GeneratorFunction.prototype=GeneratorFunctionPrototype,o(g,"constructor",{value:GeneratorFunctionPrototype,configurable:!0}),o(GeneratorFunctionPrototype,"constructor",{value:GeneratorFunction,configurable:!0}),GeneratorFunction.displayName=define(GeneratorFunctionPrototype,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===GeneratorFunction||"GeneratorFunction"===(e.displayName||e.name));},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,GeneratorFunctionPrototype):(t.__proto__=GeneratorFunctionPrototype,define(t,u,"GeneratorFunction")),t.prototype=Object.create(g),t;},e.awrap=function(t){return{__await:t};},defineIteratorMethods(AsyncIterator.prototype),define(AsyncIterator.prototype,c,function(){return this;}),e.AsyncIterator=AsyncIterator,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new AsyncIterator(wrap(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then(function(t){return t.done?t.value:a.next();});},defineIteratorMethods(g),define(g,u,"Generator"),define(g,a,function(){return this;}),define(g,"toString",function(){return"[object Generator]";}),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function next(){for(;r.length;){var t=r.pop();if(t in e)return next.value=t,next.done=!1,next;}return next.done=!0,next;};},e.values=values,Context.prototype={constructor:Context,reset:function reset(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(resetTryEntry),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t);},stop:function stop(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval;},dispatchException:function dispatchException(e){if(this.done)throw e;var r=this;function handle(n,o){return a.type="throw",a.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o;}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return handle("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}else if(c){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}}}},abrupt:function abrupt(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break;}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a);},complete:function complete(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y;},finish:function finish(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),resetTryEntry(r),y;}},"catch":function _catch(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;resetTryEntry(r);}return o;}}throw Error("illegal catch attempt");},delegateYield:function delegateYield(e,r,n){return this.delegate={iterator:values(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y;}},e;}function asyncGeneratorStep(n,t,e,r,o,a,c){try{var i=n[a](c),u=i.value;}catch(n){return void e(n);}i.done?t(u):Promise.resolve(u).then(r,o);}function _asyncToGenerator(n){return function(){var t=this,e=arguments;return new Promise(function(r,o){var a=n.apply(t,e);function _next(n){asyncGeneratorStep(a,r,o,_next,_throw,"next",n);}function _throw(n){asyncGeneratorStep(a,r,o,_next,_throw,"throw",n);}_next(void 0);});};}function _classCallCheck(a,n){if(!(a instanceof n))throw new TypeError("Cannot call a class as a function");}function _defineProperties(e,r){for(var t=0;t<r.length;t++){var o=r[t];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,_toPropertyKey(o.key),o);}}function _createClass(e,r,t){return r&&_defineProperties(e.prototype,r),t&&_defineProperties(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e;}function _toPropertyKey(t){var i=_toPrimitive(t,"string");return"symbol"==_typeof(i)?i:i+"";}function _toPrimitive(t,r){if("object"!=_typeof(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,r||"default");if("object"!=_typeof(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.");}return("string"===r?String:Number)(t);}function _callSuper(t,o,e){return o=_getPrototypeOf(o),_possibleConstructorReturn(t,_isNativeReflectConstruct()?Reflect.construct(o,e||[],_getPrototypeOf(t).constructor):o.apply(t,e));}function _possibleConstructorReturn(t,e){if(e&&("object"==_typeof(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(t);}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e;}function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t;})();}function _superPropGet(t,o,e,r){var p=_get(_getPrototypeOf(1&r?t.prototype:t),o,e);return 2&r&&"function"==typeof p?function(t){return p.apply(e,t);}:p;}function _get(){return _get="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,r){var p=_superPropBase(e,t);if(p){var n=Object.getOwnPropertyDescriptor(p,t);return n.get?n.get.call(arguments.length<3?e:r):n.value;}},_get.apply(null,arguments);}function _superPropBase(t,o){for(;!{}.hasOwnProperty.call(t,o)&&null!==(t=_getPrototypeOf(t)););return t;}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t);},_getPrototypeOf(t);}function _inherits(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf(t,e);}function _setPrototypeOf(t,e){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t;},_setPrototypeOf(t,e);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_nileFilePreviewCssCjsJs){i=_nileFilePreviewCssCjsJs.s;},function(_internalNileElementCjsJs){s=_internalNileElementCjsJs.N;},function(_litDecoratorsJs){e=_litDecoratorsJs.property;h=_litDecoratorsJs.customElement;},function(_utilsNileFilePreviewUtilCjsJs){a=_utilsNileFilePreviewUtilCjsJs.i;r=_utilsNileFilePreviewUtilCjsJs.a;},function(_typesNileFilePreviewEnumsCjsJs){l=_typesNileFilePreviewEnumsCjsJs.F;o=_typesNileFilePreviewEnumsCjsJs.a;n=_typesNileFilePreviewEnumsCjsJs.b;c=_typesNileFilePreviewEnumsCjsJs.c;},function(_lit){p=_lit.html;},function(_nileFilePreviewTemplateCjsJs){m=_nileFilePreviewTemplateCjsJs.g;u=_nileFilePreviewTemplateCjsJs.a;y=_nileFilePreviewTemplateCjsJs.b;d=_nileFilePreviewTemplateCjsJs.c;f=_nileFilePreviewTemplateCjsJs.d;j=_nileFilePreviewTemplateCjsJs.e;v=_nileFilePreviewTemplateCjsJs.f;w=_nileFilePreviewTemplateCjsJs.h;},function(_internalAccessibilityA11yStateEnumCjsJs){},function(_internalAccessibilityA11yPropertyEnumCjsJs){},function(_internalAccessibilityRoleEnumCjsJs){}],execute:function execute(){_export("N",b=/*#__PURE__*/function(_s){function b(){var _this;_classCallCheck(this,b);_this=_callSuper(this,b,arguments),_this.errorMessage="",_this.fileUrl="",_this.uploadStatus=0,_this.state=l.DEFAULT,_this.variant=o.HORIZONTAL,_this.inputFileName="",_this.showFileType=!1,_this.inputFileHtml=null,_this.originalUrl="",_this.isStringTruncated=!1;return _this;}_inherits(b,_s);return _createClass(b,[{key:"connectedCallback",value:function connectedCallback(){_superPropGet(b,"connectedCallback",this,3)([]),this.emit(n.NILE_INIT);}},{key:"firstUpdated",value:function firstUpdated(t){_superPropGet(b,"firstUpdated",this,3)([t]);}},{key:"updated",value:function updated(t){t.has("uploadStatus")&&this.uploadStatus?this.uploadStatus<100?this.createUploadState(this.inputFile,this.uploadStatus):this.createState(this.inputFile):t.has("inputFile")&&this.inputFile?(this.createState(this.inputFile),this.emit(n.NILE_RECEIVE)):t.has("fileUrl")&&this.fileUrl?(this.handleFileUrl(this.fileUrl),this.emit(n.NILE_RECEIVE)):t.has("errorMessage")&&this.createState(this.inputFile);}},{key:"createUploadState",value:function createUploadState(t,i){var s=this.variant===o.HORIZONTAL;this.inputFileHtml=s?m(t,i,this):u(t,i,this),this.requestUpdate();}},{key:"handleFileUrl",value:function(){var _handleFileUrl=_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(t){var _i,_s2,_e,_h,_i2;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:this.originalUrl=t;_context2.prev=1;_context2.next=4;return fetch(t);case 4:_i=_context2.sent;_context2.next=7;return _i.blob();case 7:_s2=_context2.sent;_e=this.inputFileName||t.split("/").pop()||c.UNKNOWN_FILE_NAME;_h=new File([_s2],_e,{type:_s2.type});this.createState(_h);_context2.next=17;break;case 13:_context2.prev=13;_context2.t0=_context2["catch"](1);_i2=new File([],this.inputFileName||c.UNKNOWN_FILE_NAME,{type:"application/octet-stream"});this.errorMessage=c.FAILED_TO_LOAD,console.error(this.errorMessage),this.inputFileHtml=this.variant===o.HORIZONTAL?y(_i2,this.errorMessage,this.originalUrl,this):d(_i2,this.errorMessage,this.originalUrl,this),this.requestUpdate();case 17:case"end":return _context2.stop();}},_callee,this,[[1,13]]);}));function handleFileUrl(_x){return _handleFileUrl.apply(this,arguments);}return handleFileUrl;}()},{key:"createState",value:function(){var _createState=_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(t){var i,_s3,_s4;return _regeneratorRuntime().wrap(function _callee2$(_context3){while(1)switch(_context3.prev=_context3.next){case 0:i=this.variant===o.HORIZONTAL;if(!this.errorMessage){_context3.next=5;break;}this.inputFileHtml=i?y(t,this.errorMessage,this.originalUrl,this):d(t,this.errorMessage,this.originalUrl,this);_context3.next=32;break;case 5:_s3=!1;_context3.prev=6;_context3.t0=t;if(!_context3.t0){_context3.next=12;break;}_context3.next=11;return a(t);case 11:_context3.t0=_context3.sent;case 12:_s3=_context3.t0;_context3.next=18;break;case 15:_context3.prev=15;_context3.t1=_context3["catch"](6);_s3=!1;case 18:if(!_s3){_context3.next=31;break;}_context3.prev=19;_context3.next=22;return r(t);case 22:_s4=_context3.sent;this.inputFileHtml=i?f(_s4,t,this.originalUrl,this.showFileType):j(_s4,t,this.originalUrl,this.showFileType);_context3.next=29;break;case 26:_context3.prev=26;_context3.t2=_context3["catch"](19);this.inputFileHtml=i?v(t,this.originalUrl,this.showFileType):w(t,this.originalUrl,this.showFileType);case 29:_context3.next=32;break;case 31:this.inputFileHtml=i?v(t,this.originalUrl,this.showFileType):w(t,this.originalUrl,this.showFileType);case 32:this.requestUpdate();case 33:case"end":return _context3.stop();}},_callee2,this,[[6,15],[19,26]]);}));function createState(_x2){return _createState.apply(this,arguments);}return createState;}()},{key:"render",value:function render(){var _this$inputFileHtml;return p(_templateObject||(_templateObject=_taggedTemplateLiteral(["",""])),(_this$inputFileHtml=this.inputFileHtml)!==null&&_this$inputFileHtml!==void 0?_this$inputFileHtml:p(_templateObject2||(_templateObject2=_taggedTemplateLiteral([""]))));}},{key:"disconnectedCallback",value:function disconnectedCallback(){_superPropGet(b,"disconnectedCallback",this,3)([]),this.emit(n.NILE_DESTROY);}}],[{key:"styles",get:function get(){return[i];}}]);}(s));t([e({type:String})],b.prototype,"errorMessage",void 0),t([e({type:Object})],b.prototype,"inputFile",void 0),t([e({type:String})],b.prototype,"fileUrl",void 0),t([e({type:Number})],b.prototype,"uploadStatus",void 0),t([e({type:String})],b.prototype,"state",void 0),t([e({type:String})],b.prototype,"variant",void 0),t([e({type:String})],b.prototype,"inputFileName",void 0),t([e({type:Boolean,reflect:!0,attribute:!0})],b.prototype,"showFileType",void 0),_export("N",b=t([h("nile-file-preview")],b));}};});
|
|
2
2
|
//# sourceMappingURL=nile-file-preview.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-file-preview.cjs.js","sources":["../../../src/nile-file-preview/nile-file-preview.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport {styles} from './nile-file-preview.css';\nimport NileElement from '../internal/nile-element';\nimport { customElement, property } from 'lit/decorators.js';\nimport { generatePreviewUrl, isRealImage } from './utils';\nimport { FilePreviewState, FilePreviewVariant, FilePreviewErrorMessages, FilePreviewEvent } from './types';\nimport { LitElement, html, CSSResultArray, TemplateResult, PropertyValues } from 'lit';\nimport {\n getHorizontalErrorState,\n getHorizontalNoPreviewState,\n getHorizontalPreviewState,\n getHorizontalUploadingState,\n getVerticalErrorState,\n getVerticalNoPreviewState,\n getVerticalPreviewState,\n getVerticalUploadingState\n} from './nile-file-preview.template';\n\n\n/**\n * Nile preview component.\n *\n * @tag nile-preview\n *\n */\n@customElement('nile-file-preview')\nexport class NileFilePreview extends NileElement {\n /**\n * The styles for nile-preview\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n @property({ type: String }) errorMessage: string = \"\";\n\t@property({ type: Object }) inputFile: File;\n\t@property({ type: String }) fileUrl: string = \"\";\n\t@property({ type: Number }) uploadStatus: number = 0;\n\t@property({ type: String }) state: FilePreviewState = FilePreviewState.DEFAULT;\n\t@property({ type: String }) variant: FilePreviewVariant = FilePreviewVariant.HORIZONTAL;\n @property({ type: String }) inputFileName: string = \"\";\n @property({ type: Boolean, reflect: true, attribute: true }) showFileType: boolean = false;\n\tprivate inputFileHtml: TemplateResult | null = null;\n private originalUrl: string = \"\";\n public isStringTruncated: boolean = false;\n\n /**\n * Render method\n * @slot This is a slot test\n */\n\n connectedCallback(): void {\n super.connectedCallback();\n this.emit(FilePreviewEvent.NILE_INIT);\n }\n\n protected firstUpdated(_changedProperties: PropertyValues): void {\n super.firstUpdated(_changedProperties);\n }\n\n protected updated(changedProperties: PropertyValues): void {\n if(changedProperties.has('uploadStatus') && this.uploadStatus) {\n if(this.uploadStatus < 100) {\n this.createUploadState(this.inputFile, this.uploadStatus);\n } else {\n this.createState(this.inputFile);\n }\n } else if (changedProperties.has('inputFile') && this.inputFile) {\n this.createState(this.inputFile);\n this.emit(FilePreviewEvent.NILE_RECEIVE);\n\n } else if (changedProperties.has('fileUrl') && this.fileUrl) {\n this.handleFileUrl(this.fileUrl);\n this.emit(FilePreviewEvent.NILE_RECEIVE);\n\n } else if (changedProperties.has('errorMessage')) {\n this.createState(this.inputFile);\n }\n }\n\n private createUploadState( file: File, uploadStatus: number): void {\n const isHorizontal = this.variant === FilePreviewVariant.HORIZONTAL;\n\n this.inputFileHtml = isHorizontal\n ? getHorizontalUploadingState(file, uploadStatus, this)\n : getVerticalUploadingState(file, uploadStatus, this);\n\n this.requestUpdate();\n }\n\n private async handleFileUrl(url: string): Promise<void> {\n this.originalUrl = url;\n try {\n const response = await fetch(url);\n const blob = await response.blob();\n const fileName = this.inputFileName || url.split('/').pop() || FilePreviewErrorMessages.UNKNOWN_FILE_NAME;\n const file = new File([blob], fileName, { type: blob.type });\n\n this.createState(file);\n } catch (error) {\n const dummyFile = new File([], this.inputFileName || FilePreviewErrorMessages.UNKNOWN_FILE_NAME, { type: 'application/octet-stream' });\n this.errorMessage = FilePreviewErrorMessages.FAILED_TO_LOAD;\n console.error(this.errorMessage);\n\n this.inputFileHtml = this.variant === FilePreviewVariant.HORIZONTAL\n ? getHorizontalErrorState(dummyFile, this.errorMessage, this.originalUrl, this)\n : getVerticalErrorState(dummyFile, this.errorMessage, this.originalUrl, this);\n this.requestUpdate();\n }\n }\n\n\tpublic async createState(file: File): Promise<void> {\n const isHorizontal = this.variant === FilePreviewVariant.HORIZONTAL;\n\n if (!this.errorMessage) {\n let isImage = false;\n try {\n isImage = file && await isRealImage(file);\n } catch (error) {\n isImage = false;\n }\n if (isImage) {\n try {\n const url = await generatePreviewUrl(file);\n this.inputFileHtml = isHorizontal\n ? getHorizontalPreviewState(url, file, this.originalUrl, this.showFileType)\n : getVerticalPreviewState(url, file, this.originalUrl, this.showFileType);\n } catch (error) {\n this.inputFileHtml = isHorizontal\n ? getHorizontalNoPreviewState(file, this.originalUrl, this.showFileType)\n : getVerticalNoPreviewState(file, this.originalUrl, this.showFileType);\n }\n } else {\n this.inputFileHtml = isHorizontal\n ? getHorizontalNoPreviewState(file, this.originalUrl, this.showFileType)\n : getVerticalNoPreviewState(file, this.originalUrl, this.showFileType);\n }\n } else {\n this.inputFileHtml = isHorizontal\n ? getHorizontalErrorState(file, this.errorMessage, this.originalUrl, this)\n : getVerticalErrorState(file, this.errorMessage, this.originalUrl, this);\n }\n this.requestUpdate();\n }\n\n public render(): TemplateResult {\n return html`${this.inputFileHtml ?? html``}`;\n }\n\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n this.emit(FilePreviewEvent.NILE_DESTROY);\n }\n\n /* #endregion */\n}\n\nexport default NileFilePreview;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-file-preview': NileFilePreview;\n }\n}\n"],"names":["NileFilePreview","_s","g","this","errorMessage","fileUrl","uploadStatus","state","FilePreviewState","DEFAULT","variant","FilePreviewVariant","HORIZONTAL","inputFileName","showFileType","inputFileHtml","originalUrl","isStringTruncated","_this","_inherits","_createClass","key","value","connectedCallback","super","emit","FilePreviewEvent","NILE_INIT","firstUpdated","_changedProperties","updated","changedProperties","has","createUploadState","inputFile","createState","NILE_RECEIVE","handleFileUrl","file","isHorizontal","getHorizontalUploadingState","getVerticalUploadingState","requestUpdate","_handleFileUrl","_asyncToGenerator","_regeneratorRuntime","mark","_callee","url","_context2","prev","next","fetch","blob","response","fileName","split","pop","FilePreviewErrorMessages","UNKNOWN_FILE_NAME","File","type","t0","dummyFile","FAILED_TO_LOAD","console","error","getHorizontalErrorState","getVerticalErrorState","stop","_callee2","i","_s3","_s4","wrap","_callee2$","_context3","isImage","isRealImage","sent","generatePreviewUrl","getHorizontalPreviewState","getVerticalPreviewState","t2","getHorizontalNoPreviewState","getVerticalNoPreviewState","render","html","_templateObject","_taggedTemplateLiteral","_this$inputFileHtml","_templateObject2","disconnectedCallback","NILE_DESTROY","get","styles","NileElement","__decorate","property","String","prototype","Object","Number","Boolean","reflect","attribute","customElement"],"mappings":"+5YAgCaA,CAAN,uBAAAC,EAAA,EAAA,SAAAC,EAAA,uEASuBC,KAAAA,CAAYC,YAAAA,CAAW,EAExBD,CAAAA,KAAAA,CAAOE,OAAW,CAAA,EAAA,CAClBF,KAAAA,CAAYG,YAAW,CAAA,CAAA,CACvBH,KAAAA,CAAAI,KAAAA,CAA0BC,CAAiBC,CAAAA,OAAAA,CAC3CN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,CAAErC,IAAAA,CAAMsC,MAAsEnG,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAoG,SAAA,CAAA,SAAA,CAAA,IAAA,EAC3DH,CAAAA,CAAAA,CAAAA,CAAA,CAA3BC,CAAS,CAAA,CAAErC,IAAMsC,CAAAA,MAAAA,CAAAA,CAAAA,CAAAA,CAAqCnG,CAAAoG,CAAAA,SAAAA,CAAA,eAAA,CAAA,IAAA,EAAA,CAAA,CACMH,CAAA,CAAA,CAA5DC,CAAS,CAAA,CAAErC,IAAM0C,CAAAA,OAAAA,CAASC,SAAS,CAAMC,CAAAA,SAAAA,CAAAA,CAAW,CAAsCzG,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAoG,SAAA,CAAA,cAAA,CAAA,IAAA,EAhBhFpG,CAAAA,CAAAA,OAAAA,KAAAA,CAAAA,CAAeiG,CAAA,CAAA,CAD3BS,CAAc,CAAA,mBAAA,CAAA,CAAA,CACF1G"}
|
|
1
|
+
{"version":3,"file":"nile-file-preview.cjs.js","sources":["../../../src/nile-file-preview/nile-file-preview.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport {styles} from './nile-file-preview.css';\nimport NileElement from '../internal/nile-element';\nimport { customElement, property } from 'lit/decorators.js';\nimport { generatePreviewUrl, isRealImage } from './utils';\nimport { FilePreviewState, FilePreviewVariant, FilePreviewErrorMessages, FilePreviewEvent } from './types';\nimport { LitElement, html, CSSResultArray, TemplateResult, PropertyValues } from 'lit';\nimport {\n getHorizontalErrorState,\n getHorizontalNoPreviewState,\n getHorizontalPreviewState,\n getHorizontalUploadingState,\n getVerticalErrorState,\n getVerticalNoPreviewState,\n getVerticalPreviewState,\n getVerticalUploadingState\n} from './nile-file-preview.template';\n\n\n/**\n * Nile preview component.\n *\n * @tag nile-preview\n *\n */\n@customElement('nile-file-preview')\nexport class NileFilePreview extends NileElement {\n /**\n * The styles for nile-preview\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n @property({ type: String }) errorMessage: string = \"\";\n\t@property({ type: Object }) inputFile: File;\n\t@property({ type: String }) fileUrl: string = \"\";\n\t@property({ type: Number }) uploadStatus: number = 0;\n\t@property({ type: String }) state: FilePreviewState = FilePreviewState.DEFAULT;\n\t@property({ type: String }) variant: FilePreviewVariant = FilePreviewVariant.HORIZONTAL;\n @property({ type: String }) inputFileName: string = \"\";\n @property({ type: Boolean, reflect: true, attribute: true }) showFileType: boolean = false;\n\tprivate inputFileHtml: TemplateResult | null = null;\n private originalUrl: string = \"\";\n public isStringTruncated: boolean = false;\n\n /**\n * Render method\n * @slot This is a slot test\n */\n\n connectedCallback(): void {\n super.connectedCallback();\n this.emit(FilePreviewEvent.NILE_INIT);\n }\n\n protected firstUpdated(_changedProperties: PropertyValues): void {\n super.firstUpdated(_changedProperties);\n }\n\n protected updated(changedProperties: PropertyValues): void {\n if(changedProperties.has('uploadStatus') && this.uploadStatus) {\n if(this.uploadStatus < 100) {\n this.createUploadState(this.inputFile, this.uploadStatus);\n } else {\n this.createState(this.inputFile);\n }\n } else if (changedProperties.has('inputFile') && this.inputFile) {\n this.createState(this.inputFile);\n this.emit(FilePreviewEvent.NILE_RECEIVE);\n\n } else if (changedProperties.has('fileUrl') && this.fileUrl) {\n this.handleFileUrl(this.fileUrl);\n this.emit(FilePreviewEvent.NILE_RECEIVE);\n\n } else if (changedProperties.has('errorMessage')) {\n this.createState(this.inputFile);\n }\n }\n\n private createUploadState( file: File, uploadStatus: number): void {\n const isHorizontal = this.variant === FilePreviewVariant.HORIZONTAL;\n\n this.inputFileHtml = isHorizontal\n ? getHorizontalUploadingState(file, uploadStatus, this)\n : getVerticalUploadingState(file, uploadStatus, this);\n\n this.requestUpdate();\n }\n\n private async handleFileUrl(url: string): Promise<void> {\n this.originalUrl = url;\n try {\n const response = await fetch(url);\n const blob = await response.blob();\n const fileName = this.inputFileName || url.split('/').pop() || FilePreviewErrorMessages.UNKNOWN_FILE_NAME;\n const file = new File([blob], fileName, { type: blob.type });\n\n this.createState(file);\n } catch (error) {\n const dummyFile = new File([], this.inputFileName || FilePreviewErrorMessages.UNKNOWN_FILE_NAME, { type: 'application/octet-stream' });\n this.errorMessage = FilePreviewErrorMessages.FAILED_TO_LOAD;\n console.error(this.errorMessage);\n\n this.inputFileHtml = this.variant === FilePreviewVariant.HORIZONTAL\n ? getHorizontalErrorState(dummyFile, this.errorMessage, this.originalUrl, this)\n : getVerticalErrorState(dummyFile, this.errorMessage, this.originalUrl, this);\n this.requestUpdate();\n }\n }\n\n\tpublic async createState(file: File): Promise<void> {\n const isHorizontal = this.variant === FilePreviewVariant.HORIZONTAL;\n\n if (!this.errorMessage) {\n let isImage = false;\n try {\n isImage = file && await isRealImage(file);\n } catch (error) {\n isImage = false;\n }\n if (isImage) {\n try {\n const url = await generatePreviewUrl(file);\n this.inputFileHtml = isHorizontal\n ? getHorizontalPreviewState(url, file, this.originalUrl, this.showFileType)\n : getVerticalPreviewState(url, file, this.originalUrl, this.showFileType);\n } catch (error) {\n this.inputFileHtml = isHorizontal\n ? getHorizontalNoPreviewState(file, this.originalUrl, this.showFileType)\n : getVerticalNoPreviewState(file, this.originalUrl, this.showFileType);\n }\n } else {\n this.inputFileHtml = isHorizontal\n ? getHorizontalNoPreviewState(file, this.originalUrl, this.showFileType)\n : getVerticalNoPreviewState(file, this.originalUrl, this.showFileType);\n }\n } else {\n this.inputFileHtml = isHorizontal\n ? getHorizontalErrorState(file, this.errorMessage, this.originalUrl, this)\n : getVerticalErrorState(file, this.errorMessage, this.originalUrl, this);\n }\n this.requestUpdate();\n }\n\n public render(): TemplateResult {\n return html`${this.inputFileHtml ?? html``}`;\n }\n\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n this.emit(FilePreviewEvent.NILE_DESTROY);\n }\n\n /* #endregion */\n}\n\nexport default NileFilePreview;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-file-preview': NileFilePreview;\n }\n}\n"],"names":["NileFilePreview","b","constructor","this","errorMessage","fileUrl","uploadStatus","state","FilePreviewState","DEFAULT","variant","FilePreviewVariant","HORIZONTAL","inputFileName","showFileType","inputFileHtml","originalUrl","isStringTruncated","_this","_inherits","_s","_createClass","key","value","connectedCallback","super","emit","FilePreviewEvent","NILE_INIT","firstUpdated","_changedProperties","updated","changedProperties","has","createUploadState","inputFile","createState","NILE_RECEIVE","handleFileUrl","file","isHorizontal","getHorizontalUploadingState","getVerticalUploadingState","requestUpdate","_handleFileUrl","_asyncToGenerator","_regeneratorRuntime","mark","_callee","url","_context2","prev","next","fetch","response","blob","fileName","split","pop","FilePreviewErrorMessages","UNKNOWN_FILE_NAME","File","type","t0","dummyFile","FAILED_TO_LOAD","console","error","getHorizontalErrorState","getVerticalErrorState","stop","_callee2","i","_s3","_s4","wrap","_callee2$","_context3","isImage","isRealImage","sent","generatePreviewUrl","getHorizontalPreviewState","getVerticalPreviewState","t2","getHorizontalNoPreviewState","getVerticalNoPreviewState","render","_this$inputFileHtml","html","_templateObject","_taggedTemplateLiteral","_templateObject2","disconnectedCallback","NILE_DESTROY","__decorate","get","styles","NileElement","property","String","prototype","Object","Number","Boolean","reflect","attribute","customElement"],"mappings":"ktZAgCaA,CAAAA,uBAAAA,EAAAA,EAAN,SAAAC,EAAA,CAAAC,KAAAA,KAAAA,CAAAA,eAAAA,MAAAA,CAAAA,qCASuBC,KAAAA,CAAYC,YAAAA,CAAW,EAExBD,CAAAA,KAAAA,CAAOE,QAAW,EAClBF,CAAAA,KAAAA,CAAYG,YAAW,CAAA,CAAA,CACvBH,KAAAA,CAAAI,KAAAA,CAA0BC,CAAiBC,CAAAA,OAAAA,CAC3CN,KAAAA,CAAAO,OAAAA,CAA8BC,CAAmBC,CAAAA,UAAAA,CAChDT,KAAAA,CAAaU,aAAAA,CAAW,GACSV,KAAAA,CAAYW,YAAA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