@aquera/nile-elements 0.1.35 → 0.1.36-beta-1.1
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 +70 -9
- package/demo/filenames.txt +1 -1
- package/demo/index.css +7 -4
- package/demo/index.html +20 -36
- package/demo/variables.css +13 -0
- package/demo/variables_v2.css +13 -0
- package/dist/{fixture-161dee0b.cjs.js → fixture-d5b55278.cjs.js} +3 -3
- package/dist/fixture-d5b55278.cjs.js.map +1 -0
- package/dist/{fixture-372df3b0.esm.js → fixture-df8b52d7.esm.js} +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/internal/animate.cjs.js +1 -1
- package/dist/internal/animate.cjs.js.map +1 -1
- package/dist/internal/animate.esm.js +1 -1
- package/dist/nile-accordion/nile-accordian.test.cjs.js +1 -1
- package/dist/nile-accordion/nile-accordian.test.esm.js +1 -1
- package/dist/nile-auto-complete/nile-auto-complete.test.cjs.js +1 -1
- package/dist/nile-auto-complete/nile-auto-complete.test.esm.js +1 -1
- package/dist/nile-avatar/nile-avatar.test.cjs.js +1 -1
- package/dist/nile-avatar/nile-avatar.test.cjs.js.map +1 -1
- package/dist/nile-avatar/nile-avatar.test.esm.js +1 -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-badge/nile-badge.test.cjs.js +1 -1
- package/dist/nile-badge/nile-badge.test.cjs.js.map +1 -1
- package/dist/nile-badge/nile-badge.test.esm.js +1 -1
- 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.esm.js +2 -2
- package/dist/nile-button/nile-button.test.cjs.js +1 -1
- package/dist/nile-button/nile-button.test.cjs.js.map +1 -1
- package/dist/nile-button/nile-button.test.esm.js +1 -1
- package/dist/nile-button-toggle-group/nile-button-toggle-group.test.cjs.js +1 -1
- package/dist/nile-button-toggle-group/nile-button-toggle-group.test.esm.js +1 -1
- package/dist/nile-calendar/nile-calendar.test.cjs.js +1 -1
- package/dist/nile-calendar/nile-calendar.test.cjs.js.map +1 -1
- package/dist/nile-calendar/nile-calendar.test.esm.js +4 -4
- package/dist/nile-card/nile-card.test.cjs.js +1 -1
- package/dist/nile-card/nile-card.test.esm.js +1 -1
- package/dist/nile-checkbox/nile-checkbox.test.cjs.js +1 -1
- package/dist/nile-checkbox/nile-checkbox.test.esm.js +1 -1
- package/dist/nile-chip/nile-chip.test.cjs.js +1 -1
- package/dist/nile-chip/nile-chip.test.cjs.js.map +1 -1
- package/dist/nile-chip/nile-chip.test.esm.js +1 -1
- 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 +1 -1
- package/dist/nile-dialog/nile-dialog.test.cjs.js +1 -1
- package/dist/nile-dialog/nile-dialog.test.cjs.js.map +1 -1
- package/dist/nile-dialog/nile-dialog.test.esm.js +1 -1
- 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 +2 -2
- package/dist/nile-drawer/nile-drawer.test.cjs.js +1 -1
- package/dist/nile-drawer/nile-drawer.test.cjs.js.map +1 -1
- package/dist/nile-drawer/nile-drawer.test.esm.js +1 -1
- package/dist/nile-dropdown/nile-dropdown.test.cjs.js +1 -1
- package/dist/nile-dropdown/nile-dropdown.test.esm.js +1 -1
- package/dist/nile-empty-state/nile-empty-state.test.cjs.js +1 -1
- package/dist/nile-empty-state/nile-empty-state.test.esm.js +1 -1
- package/dist/nile-error-message/nile-error-message.cjs.js +1 -1
- package/dist/nile-error-message/nile-error-message.cjs.js.map +1 -1
- package/dist/nile-error-message/nile-error-message.css.cjs.js +1 -1
- package/dist/nile-error-message/nile-error-message.css.cjs.js.map +1 -1
- package/dist/nile-error-message/nile-error-message.css.esm.js +6 -4
- package/dist/nile-error-message/nile-error-message.esm.js +4 -4
- package/dist/nile-error-message/nile-error-message.test.cjs.js +1 -1
- package/dist/nile-error-message/nile-error-message.test.esm.js +1 -1
- package/dist/nile-error-notification/nile-error-notification.css.cjs.js +1 -1
- package/dist/nile-error-notification/nile-error-notification.css.cjs.js.map +1 -1
- package/dist/nile-error-notification/nile-error-notification.css.esm.js +1 -1
- package/dist/nile-filter-chip/index.cjs.js +2 -0
- package/dist/nile-filter-chip/index.cjs.js.map +1 -0
- package/dist/nile-filter-chip/index.esm.js +1 -0
- package/dist/nile-filter-chip/nile-filter-chip.cjs.js +2 -0
- package/dist/nile-filter-chip/nile-filter-chip.cjs.js.map +1 -0
- package/dist/nile-filter-chip/nile-filter-chip.css.cjs.js +2 -0
- package/dist/nile-filter-chip/nile-filter-chip.css.cjs.js.map +1 -0
- package/dist/nile-filter-chip/nile-filter-chip.css.esm.js +121 -0
- package/dist/nile-filter-chip/nile-filter-chip.esm.js +43 -0
- package/dist/nile-filter-chip/nile-filter-chip.test.cjs.js +2 -0
- package/dist/nile-filter-chip/nile-filter-chip.test.cjs.js.map +1 -0
- package/dist/nile-filter-chip/nile-filter-chip.test.esm.js +20 -0
- package/dist/nile-form-group/nile-form-group.test.cjs.js +1 -1
- package/dist/nile-form-group/nile-form-group.test.esm.js +1 -1
- package/dist/nile-form-help-text/nile-form-help-text.test.cjs.js +1 -1
- package/dist/nile-form-help-text/nile-form-help-text.test.esm.js +1 -1
- package/dist/nile-hero/nile-hero.test.cjs.js +1 -1
- package/dist/nile-hero/nile-hero.test.esm.js +1 -1
- package/dist/nile-icon/aliasmap.cjs.js +2 -0
- package/dist/nile-icon/aliasmap.cjs.js.map +1 -0
- package/dist/nile-icon/aliasmap.esm.js +1 -0
- package/dist/nile-icon/icons/svg/actionworkflow.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/actionworkflow.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/actionworkflow.esm.js +1 -1
- package/dist/nile-icon/icons/svg/agents.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/agents.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/agents.esm.js +1 -1
- package/dist/nile-icon/icons/svg/anomaly.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/anomaly.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/anomaly.esm.js +1 -1
- package/dist/nile-icon/icons/svg/application.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/application.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/application.esm.js +1 -1
- package/dist/nile-icon/icons/svg/applications.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/applications.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/applications.esm.js +1 -1
- package/dist/nile-icon/icons/svg/approve.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/approve.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/approve.esm.js +1 -1
- package/dist/nile-icon/icons/svg/bar-chart-square-03.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/bar-chart-square-03.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/bar-chart-square-03.esm.js +1 -1
- package/dist/nile-icon/icons/svg/basic.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/basic.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/basic.esm.js +1 -1
- package/dist/nile-icon/icons/svg/bell-icon.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/bell-icon.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/bell-icon.esm.js +1 -1
- package/dist/nile-icon/icons/svg/bell.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/bell.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/bell.esm.js +1 -1
- package/dist/nile-icon/icons/svg/block-02.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/block-02.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/block-02.esm.js +1 -1
- package/dist/nile-icon/icons/svg/calendar-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/calendar-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/calendar-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/cancel.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/cancel.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/cancel.esm.js +1 -1
- package/dist/nile-icon/icons/svg/caution.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/caution.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/caution.esm.js +1 -1
- package/dist/nile-icon/icons/svg/check.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/check.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/check.esm.js +1 -1
- package/dist/nile-icon/icons/svg/chevron-down.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/chevron-down.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/chevron-down.esm.js +1 -1
- package/dist/nile-icon/icons/svg/chevron-selector-vertical.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/chevron-selector-vertical.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/chevron-selector-vertical.esm.js +1 -1
- package/dist/nile-icon/icons/svg/componentblock.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/componentblock.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/componentblock.esm.js +1 -1
- package/dist/nile-icon/icons/svg/continuous.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/continuous.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/continuous.esm.js +1 -1
- package/dist/nile-icon/icons/svg/custom.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/custom.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/custom.esm.js +1 -1
- package/dist/nile-icon/icons/svg/data-type-expression.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/data-type-expression.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/data-type-expression.esm.js +1 -1
- package/dist/nile-icon/icons/svg/data-type-persistent-variable.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/data-type-persistent-variable.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/data-type-persistent-variable.esm.js +1 -1
- package/dist/nile-icon/icons/svg/data-type-variable.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/data-type-variable.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/data-type-variable.esm.js +1 -1
- package/dist/nile-icon/icons/svg/database-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/database-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/database-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/default-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/default-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/default-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/deleteuser.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/deleteuser.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/deleteuser.esm.js +1 -1
- package/dist/nile-icon/icons/svg/document-new.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/document-new.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/document-new.esm.js +1 -0
- package/dist/nile-icon/icons/svg/document.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/document.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/document.esm.js +1 -1
- package/dist/nile-icon/icons/svg/dots-vertical.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/dots-vertical.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/dots-vertical.esm.js +1 -1
- package/dist/nile-icon/icons/svg/downarrow.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/downarrow.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/downarrow.esm.js +1 -1
- package/dist/nile-icon/icons/svg/download-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/download-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/download-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/download-02.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/download-02.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/download-02.esm.js +1 -1
- package/dist/nile-icon/icons/svg/draglist.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/draglist.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/draglist.esm.js +1 -1
- package/dist/nile-icon/icons/svg/droparrow.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/droparrow.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/droparrow.esm.js +1 -1
- package/dist/nile-icon/icons/svg/dropdown.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/dropdown.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/dropdown.esm.js +1 -1
- package/dist/nile-icon/icons/svg/edit-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/edit-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/edit-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/edit-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/edit-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/edit-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/edit-pencil.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/edit-pencil.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/edit-pencil.esm.js +1 -1
- package/dist/nile-icon/icons/svg/enabled.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/enabled.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/enabled.esm.js +1 -1
- package/dist/nile-icon/icons/svg/event.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/event.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/event.esm.js +1 -1
- package/dist/nile-icon/icons/svg/every.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/every.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/every.esm.js +1 -1
- package/dist/nile-icon/icons/svg/expand-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/expand-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/expand-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flow-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flow-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flow-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flow-h.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flow-h.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flow-h.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-aquera.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-aquera.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-aquera.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-block.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-block.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-block.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-cancel.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-cancel.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-cancel.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-drag.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-drag.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-drag.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-ellipsis.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-ellipsis.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-ellipsis.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-hand.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-hand.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-hand.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-redo.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-redo.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-redo.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-section.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-section.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-section.esm.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-text.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/flowmap-text.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/flowmap-text.esm.js +1 -1
- package/dist/nile-icon/icons/svg/folder-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/folder-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/folder-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/form.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/form.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/form.esm.js +1 -1
- package/dist/nile-icon/icons/svg/header-actions.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/header-actions.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/header-actions.esm.js +1 -1
- package/dist/nile-icon/icons/svg/header-functions.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/header-functions.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/header-functions.esm.js +1 -1
- package/dist/nile-icon/icons/svg/header-variable.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/header-variable.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/header-variable.esm.js +1 -1
- package/dist/nile-icon/icons/svg/help-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/help-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/help-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/help-circle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/help-circle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/help-circle.esm.js +1 -1
- package/dist/nile-icon/icons/svg/if-else-new.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/if-else-new.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/if-else-new.esm.js +1 -0
- package/dist/nile-icon/icons/svg/if.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/if.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/if.esm.js +1 -1
- package/dist/nile-icon/icons/svg/ifelsenew.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/ifelsenew.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/ifelsenew.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/icons/svg/info-circle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/info-circle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/info-circle.esm.js +1 -1
- package/dist/nile-icon/icons/svg/info-icon1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/info-icon1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/info-icon1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/info2.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/info2.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/info2.esm.js +1 -1
- package/dist/nile-icon/icons/svg/itemplaceholder.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/itemplaceholder.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/itemplaceholder.esm.js +1 -1
- package/dist/nile-icon/icons/svg/layers-three-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/layers-three-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/layers-three-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/leftarrow.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/leftarrow.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/leftarrow.esm.js +1 -1
- package/dist/nile-icon/icons/svg/manageduser.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/manageduser.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/manageduser.esm.js +1 -1
- package/dist/nile-icon/icons/svg/multiple-user.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/multiple-user.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/multiple-user.esm.js +1 -1
- package/dist/nile-icon/icons/svg/new-calendar.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/new-calendar.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/new-calendar.esm.js +1 -0
- package/dist/nile-icon/icons/svg/next-down.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/next-down.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/next-down.esm.js +1 -1
- package/dist/nile-icon/icons/svg/next.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/next.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/next.esm.js +1 -1
- package/dist/nile-icon/icons/svg/no-anomaly.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/no-anomaly.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/no-anomaly.esm.js +1 -1
- package/dist/nile-icon/icons/svg/not.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/not.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/not.esm.js +1 -1
- package/dist/nile-icon/icons/svg/notscheduled.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/notscheduled.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/notscheduled.esm.js +1 -1
- package/dist/nile-icon/icons/svg/ou-analysis-icon.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/ou-analysis-icon.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/ou-analysis-icon.esm.js +1 -1
- package/dist/nile-icon/icons/svg/palette.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/palette.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/palette.esm.js +1 -1
- package/dist/nile-icon/icons/svg/pen.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/pen.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/pen.esm.js +1 -1
- package/dist/nile-icon/icons/svg/personaldetails.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/personaldetails.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/personaldetails.esm.js +1 -1
- package/dist/nile-icon/icons/svg/placeholder-wf.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/placeholder-wf.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/placeholder-wf.esm.js +1 -1
- package/dist/nile-icon/icons/svg/play-circle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/play-circle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/play-circle.esm.js +1 -1
- package/dist/nile-icon/icons/svg/plus-icon.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/plus-icon.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/plus-icon.esm.js +1 -1
- package/dist/nile-icon/icons/svg/prev-up.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/prev-up.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/prev-up.esm.js +1 -1
- package/dist/nile-icon/icons/svg/prev.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/prev.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/prev.esm.js +1 -1
- package/dist/nile-icon/icons/svg/refresh-cw-03.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/refresh-cw-03.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/refresh-cw-03.esm.js +1 -1
- package/dist/nile-icon/icons/svg/revocation-cycle.cjs.js +2 -0
- package/dist/nile-icon/icons/svg/revocation-cycle.cjs.js.map +1 -0
- package/dist/nile-icon/icons/svg/revocation-cycle.esm.js +1 -0
- package/dist/nile-icon/icons/svg/revocationcycle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/revocationcycle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/revocationcycle.esm.js +1 -1
- package/dist/nile-icon/icons/svg/revokation-cycle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/revokation-cycle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/revokation-cycle.esm.js +1 -1
- package/dist/nile-icon/icons/svg/rightarrow.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/rightarrow.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/rightarrow.esm.js +1 -1
- package/dist/nile-icon/icons/svg/rolemanager.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/rolemanager.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/rolemanager.esm.js +1 -1
- package/dist/nile-icon/icons/svg/search-lg.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/search-lg.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/search-lg.esm.js +1 -1
- package/dist/nile-icon/icons/svg/section-02.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/section-02.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/section-02.esm.js +1 -1
- package/dist/nile-icon/icons/svg/selectuser.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/selectuser.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/selectuser.esm.js +1 -1
- package/dist/nile-icon/icons/svg/sendprompt.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/sendprompt.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/sendprompt.esm.js +1 -1
- package/dist/nile-icon/icons/svg/setting.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/setting.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/setting.esm.js +1 -1
- package/dist/nile-icon/icons/svg/settings-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/settings-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/settings-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/shape.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/shape.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/shape.esm.js +1 -1
- package/dist/nile-icon/icons/svg/smalltick.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/smalltick.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/smalltick.esm.js +1 -1
- package/dist/nile-icon/icons/svg/stop-circle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/stop-circle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/stop-circle.esm.js +1 -1
- package/dist/nile-icon/icons/svg/table-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/table-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/table-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/themes.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/themes.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/themes.esm.js +1 -1
- package/dist/nile-icon/icons/svg/trash-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/trash-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/trash-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/trash-03.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/trash-03.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/trash-03.esm.js +1 -1
- package/dist/nile-icon/icons/svg/trash-no-fill.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/trash-no-fill.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/trash-no-fill.esm.js +1 -1
- package/dist/nile-icon/icons/svg/trash.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/trash.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/trash.esm.js +1 -1
- package/dist/nile-icon/icons/svg/undo-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/undo-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/undo-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/uparrow.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/uparrow.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/uparrow.esm.js +1 -1
- package/dist/nile-icon/icons/svg/updateuser.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/updateuser.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/updateuser.esm.js +1 -1
- package/dist/nile-icon/icons/svg/user-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/user-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/user-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/user-03.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/user-03.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/user-03.esm.js +1 -1
- package/dist/nile-icon/icons/svg/user-analysis-icon.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/user-analysis-icon.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/user-analysis-icon.esm.js +1 -1
- package/dist/nile-icon/icons/svg/user-circle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/user-circle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/user-circle.esm.js +1 -1
- package/dist/nile-icon/icons/svg/user-inactive.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/user-inactive.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/user-inactive.esm.js +1 -1
- package/dist/nile-icon/icons/svg/user-selection.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/user-selection.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/user-selection.esm.js +1 -1
- package/dist/nile-icon/icons/svg/user-square.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/user-square.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/user-square.esm.js +1 -1
- package/dist/nile-icon/icons/svg/userremove-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/userremove-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/userremove-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/userremove-2.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/userremove-2.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/userremove-2.esm.js +1 -1
- package/dist/nile-icon/icons/svg/users-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/users-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/users-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/users-02.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/users-02.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/users-02.esm.js +1 -1
- package/dist/nile-icon/icons/svg/variable-local-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/variable-local-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/variable-local-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/variable-new-1.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/variable-new-1.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/variable-new-1.esm.js +1 -1
- package/dist/nile-icon/icons/svg/while.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/while.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/while.esm.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-01.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-01.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/workflow-01.esm.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-orchestration.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-orchestration.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/workflow-orchestration.esm.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-section.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-section.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/workflow-section.esm.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-solid.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/workflow-solid.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/workflow-solid.esm.js +1 -1
- package/dist/nile-icon/icons/svg/x-circle.cjs.js +1 -1
- package/dist/nile-icon/icons/svg/x-circle.cjs.js.map +1 -1
- package/dist/nile-icon/icons/svg/x-circle.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 +5 -5
- package/dist/nile-icon/nile-icon.test.cjs.js +1 -1
- package/dist/nile-icon/nile-icon.test.cjs.js.map +1 -1
- package/dist/nile-icon/nile-icon.test.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-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-input/nile-input.test.cjs.js +1 -1
- package/dist/nile-input/nile-input.test.cjs.js.map +1 -1
- package/dist/nile-input/nile-input.test.esm.js +1 -1
- package/dist/nile-link/nile-link.test.cjs.js +1 -1
- package/dist/nile-link/nile-link.test.esm.js +1 -1
- package/dist/nile-loader/nile-loader.test.cjs.js +1 -1
- package/dist/nile-loader/nile-loader.test.esm.js +1 -1
- 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.esm.js +1 -1
- 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-popover/nile-popover.test.cjs.js +1 -1
- package/dist/nile-popover/nile-popover.test.esm.js +1 -1
- package/dist/nile-popup/nile-popup.test.cjs.js +1 -1
- package/dist/nile-popup/nile-popup.test.esm.js +1 -1
- package/dist/nile-progress-bar/nile-progress-bar.css.cjs.js +1 -1
- package/dist/nile-progress-bar/nile-progress-bar.css.cjs.js.map +1 -1
- package/dist/nile-progress-bar/nile-progress-bar.css.esm.js +1 -0
- package/dist/nile-progress-bar/nile-progress-bar.test.cjs.js +1 -1
- package/dist/nile-progress-bar/nile-progress-bar.test.esm.js +1 -1
- package/dist/nile-radio/nile-radio.test.cjs.js +1 -1
- package/dist/nile-radio/nile-radio.test.esm.js +1 -1
- package/dist/nile-radio-group/nile-radio-group.test.cjs.js +1 -1
- package/dist/nile-radio-group/nile-radio-group.test.esm.js +1 -1
- 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.esm.js +10 -10
- package/dist/nile-select/nile-select.test.cjs.js +1 -1
- package/dist/nile-select/nile-select.test.cjs.js.map +1 -1
- package/dist/nile-select/nile-select.test.esm.js +1 -1
- package/dist/nile-slide-toggle/nile-slide-toggle.test.cjs.js +1 -1
- package/dist/nile-slide-toggle/nile-slide-toggle.test.esm.js +1 -1
- 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 +2 -2
- package/dist/nile-tab-group/nile-tab-group.test.cjs.js +1 -1
- package/dist/nile-tab-group/nile-tab-group.test.cjs.js.map +1 -1
- package/dist/nile-tab-group/nile-tab-group.test.esm.js +1 -1
- package/dist/nile-table/nile-table.cjs.js.map +1 -1
- 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 +2 -2
- package/dist/nile-textarea/nile-textarea.test.cjs.js +1 -1
- package/dist/nile-textarea/nile-textarea.test.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 +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-utils.cjs.js +2 -0
- package/dist/nile-tooltip/nile-tooltip-utils.cjs.js.map +1 -0
- package/dist/nile-tooltip/nile-tooltip-utils.esm.js +1 -0
- 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.css.cjs.js +1 -1
- package/dist/nile-tooltip/nile-tooltip.css.cjs.js.map +1 -1
- package/dist/nile-tooltip/nile-tooltip.css.esm.js +78 -45
- package/dist/nile-tooltip/nile-tooltip.esm.js +23 -28
- package/dist/nile-tooltip/nile-tooltip.test.cjs.js +2 -0
- package/dist/nile-tooltip/nile-tooltip.test.cjs.js.map +1 -0
- package/dist/nile-tooltip/nile-tooltip.test.esm.js +47 -0
- 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 +2 -2
- 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/nile-error-message/nile-error-message.css.js +6 -4
- package/dist/src/nile-error-message/nile-error-message.css.js.map +1 -1
- package/dist/src/nile-error-message/nile-error-message.d.ts +4 -0
- package/dist/src/nile-error-message/nile-error-message.js +20 -0
- package/dist/src/nile-error-message/nile-error-message.js.map +1 -1
- package/dist/src/nile-error-notification/nile-error-notification.css.js +1 -1
- package/dist/src/nile-error-notification/nile-error-notification.css.js.map +1 -1
- package/dist/src/nile-filter-chip/index.d.ts +1 -0
- package/dist/src/nile-filter-chip/index.js +2 -0
- package/dist/src/nile-filter-chip/index.js.map +1 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.css.d.ts +12 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.css.js +133 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.css.js.map +1 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.d.ts +37 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.js +145 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.js.map +1 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.test.d.ts +1 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.test.js +80 -0
- package/dist/src/nile-filter-chip/nile-filter-chip.test.js.map +1 -0
- package/dist/src/nile-icon/aliasmap.d.ts +1 -0
- package/dist/src/nile-icon/aliasmap.js +131 -0
- package/dist/src/nile-icon/aliasmap.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/document-new.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/document-new.js +5 -0
- package/dist/src/nile-icon/icons/svg/document-new.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/if-else-new.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/if-else-new.js +5 -0
- package/dist/src/nile-icon/icons/svg/if-else-new.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/ifelsenew.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/ifelsenew.js +5 -0
- package/dist/src/nile-icon/icons/svg/ifelsenew.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/index.d.ts +4 -124
- package/dist/src/nile-icon/icons/svg/index.js +4 -124
- package/dist/src/nile-icon/icons/svg/index.js.map +1 -1
- package/dist/src/nile-icon/icons/svg/new-calendar.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/new-calendar.js +5 -0
- package/dist/src/nile-icon/icons/svg/new-calendar.js.map +1 -0
- package/dist/src/nile-icon/icons/svg/revocation-cycle.d.ts +5 -0
- package/dist/src/nile-icon/icons/svg/revocation-cycle.js +5 -0
- package/dist/src/nile-icon/icons/svg/revocation-cycle.js.map +1 -0
- package/dist/src/nile-icon/index.js +6 -5
- package/dist/src/nile-icon/index.js.map +1 -1
- package/dist/src/nile-progress-bar/nile-progress-bar.css.js +1 -0
- package/dist/src/nile-progress-bar/nile-progress-bar.css.js.map +1 -1
- package/dist/src/nile-select/nile-select.js +1 -1
- package/dist/src/nile-select/nile-select.js.map +1 -1
- package/dist/src/nile-table/nile-table.js.map +1 -1
- package/dist/src/nile-tooltip/nile-tooltip-utils.d.ts +18 -0
- package/dist/src/nile-tooltip/nile-tooltip-utils.js +216 -0
- package/dist/src/nile-tooltip/nile-tooltip-utils.js.map +1 -0
- package/dist/src/nile-tooltip/nile-tooltip.css.js +76 -43
- package/dist/src/nile-tooltip/nile-tooltip.css.js.map +1 -1
- package/dist/src/nile-tooltip/nile-tooltip.d.ts +24 -46
- package/dist/src/nile-tooltip/nile-tooltip.js +235 -232
- package/dist/src/nile-tooltip/nile-tooltip.js.map +1 -1
- package/dist/src/nile-tooltip/nile-tooltip.test.d.ts +1 -0
- package/dist/src/nile-tooltip/nile-tooltip.test.js +148 -0
- package/dist/src/nile-tooltip/nile-tooltip.test.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
- package/plop-templates/lit/index.ts.hbs +1 -1
- package/plop-templates/lit/lit.css.ts.hbs +1 -1
- package/plop-templates/lit/lit.template.ts.hbs +3 -0
- package/plop-templates/lit/lit.test.ts.hbs +38 -0
- package/plop-templates/lit/lit.ts.hbs +7 -3
- package/plop-templates/lit/sub-components/index.ts.hbs +4 -0
- package/plop-templates/lit/types/index.ts.hbs +0 -0
- package/plop-templates/lit/types/type.ts.hbs +3 -0
- package/plop-templates/lit/utils/lit.utils.ts.hbs +4 -0
- package/plopfile.js +32 -1
- package/src/index.ts +2 -1
- package/src/nile-error-message/nile-error-message.css.ts +6 -4
- package/src/nile-error-message/nile-error-message.ts +18 -0
- package/src/nile-error-notification/nile-error-notification.css.ts +1 -1
- package/src/nile-filter-chip/index.ts +1 -0
- package/src/nile-filter-chip/nile-filter-chip.css.ts +138 -0
- package/src/nile-filter-chip/nile-filter-chip.test.ts +92 -0
- package/src/nile-filter-chip/nile-filter-chip.ts +137 -0
- package/src/nile-icon/aliasmap.ts +131 -0
- package/src/nile-icon/icons/svg/document-new.ts +5 -0
- package/src/nile-icon/icons/svg/if-else-new.ts +5 -0
- package/src/nile-icon/icons/svg/ifelsenew.ts +5 -0
- package/src/nile-icon/icons/svg/index.ts +5 -125
- package/src/nile-icon/icons/svg/new-calendar.ts +5 -0
- package/src/nile-icon/icons/svg/revocation-cycle.ts +5 -0
- package/src/nile-icon/index.ts +8 -9
- package/src/nile-progress-bar/nile-progress-bar.css.ts +1 -0
- package/src/nile-select/nile-select.ts +1 -1
- package/src/nile-table/nile-table.ts +2 -2
- package/src/nile-tooltip/nile-tooltip-utils.ts +271 -0
- package/src/nile-tooltip/nile-tooltip.css.ts +77 -44
- package/src/nile-tooltip/nile-tooltip.test.ts +168 -0
- package/src/nile-tooltip/nile-tooltip.ts +268 -230
- package/vscode-html-custom-data.json +148 -95
- package/dist/fixture-161dee0b.cjs.js.map +0 -1
@@ -1,4 +1,4 @@
|
|
1
|
-
import{__decorate as e}from"tslib";import{LitElement as s,html as
|
1
|
+
import{__decorate as e}from"tslib";import{LitElement as s,html as i}from"lit";import{property as r,customElement as t}from"lit/decorators.js";import{s as o}from"./nile-error-message.css.esm.js";let n=class extends s{constructor(){super(...arguments),this.errorMessage="",this.isExpanded=!1,this.MAX_LENGTH=100}static get styles(){return[o]}getTruncatedResponse(){return this.errorResponse.length>this.MAX_LENGTH?`${this.errorResponse.substring(0,this.MAX_LENGTH)}...`:this.errorResponse}updated(e){e.has("maxWidth")&&this.style.setProperty("--nile-error-max-width",this.maxWidth),e.has("maxHeight")&&this.style.setProperty("--nile-error-max-height",this.maxHeight),e.has("maxDialogHeight")&&this.style.setProperty("--nile-error-max-dialog-height",this.maxDialogHeight)}toggleExpanded(){this.isExpanded=!this.isExpanded}render(){const e=this.isExpanded?"arrowup":"arrowdown";return i`
|
2
2
|
<div class="nile-error-message" part="base">
|
3
3
|
<nile-icon
|
4
4
|
name="info2"
|
@@ -10,10 +10,10 @@ import{__decorate as e}from"tslib";import{LitElement as s,html as r}from"lit";im
|
|
10
10
|
<span class="nile-error-message__error">${this.errorMessage}</span>
|
11
11
|
|
12
12
|
|
13
|
-
${this.errorResponse?
|
13
|
+
${this.errorResponse?i`
|
14
14
|
<div class="nile-error-message__response">
|
15
15
|
${this.errorResponse}
|
16
|
-
${this.errorResponseLong?
|
16
|
+
${this.errorResponseLong?i`
|
17
17
|
<span
|
18
18
|
class="nile-error-message__more-button"
|
19
19
|
@click=${this.toggleExpanded}
|
@@ -30,4 +30,4 @@ import{__decorate as e}from"tslib";import{LitElement as s,html as r}from"lit";im
|
|
30
30
|
${this.errorResponseLong}
|
31
31
|
</div>
|
32
32
|
</div>
|
33
|
-
`}};e([
|
33
|
+
`}};e([r({type:String})],n.prototype,"errorMessage",void 0),e([r({type:String})],n.prototype,"errorResponse",void 0),e([r({type:String})],n.prototype,"errorResponseLong",void 0),e([r({type:Boolean})],n.prototype,"isExpanded",void 0),e([r({type:String})],n.prototype,"maxWidth",void 0),e([r({type:String})],n.prototype,"maxHeight",void 0),e([r({type:String})],n.prototype,"maxDialogHeight",void 0),n=e([t("nile-error-message")],n);export{n as N};
|
@@ -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(["../fixture-161dee0b.cjs.js","lit/static-html.js","lit/html.js","lit/directive-helpers.js","lit","lit/directives/unsafe-html.js","./nile-error-message.cjs.js","tslib","lit/decorators.js","./nile-error-message.css.cjs.js"],function(_export,_context){"use strict";var e,r,s,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,_templateObject9;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 _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}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);});};}return{setters:[function(_fixture001CjsJs){e=_fixture001CjsJs.f;r=_fixture001CjsJs.a;},function(_litStaticHtmlJs){s=_litStaticHtmlJs.html;},function(_litHtmlJs){},function(_litDirectiveHelpersJs){},function(_lit){},function(_litDirectivesUnsafeHtmlJs){},function(_nileErrorMessageCjsJs){},function(_tslib){},function(_litDecoratorsJs){},function(_nileErrorMessageCssCjsJs){}],execute:function execute(){describe("NileErrorMessage",function(){it("should render the error message",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(){var o;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:_context2.next=2;return e(s(_templateObject||(_templateObject=_taggedTemplateLiteral(["<nile-error-message errorMessage=\"An error occurred\"></nile-error-message>"]))));case 2:o=_context2.sent.shadowRoot.querySelector(".nile-error-message__error");r(o.textContent).to.equal("An error occurred");case 4:case"end":return _context2.stop();}},_callee);}))),it("should truncate the error response if it is too long",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(){var o,t;return _regeneratorRuntime().wrap(function _callee2$(_context3){while(1)switch(_context3.prev=_context3.next){case 0:o="a".repeat(150);_context3.next=3;return e(s(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"","\"></nile-error-message>"])),o));case 3:t=_context3.sent.getTruncatedResponse();r(t).to.equal("".concat(o.substring(0,100),"..."));case 5:case"end":return _context3.stop();}},_callee2);}))),it("should not truncate the error response if it is within the maximum length",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(){var o,t;return _regeneratorRuntime().wrap(function _callee3$(_context4){while(1)switch(_context4.prev=_context4.next){case 0:o="Short error message";_context4.next=3;return e(s(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"","\"></nile-error-message>"])),o));case 3:t=_context4.sent.getTruncatedResponse();r(t).to.equal(o);case 5:case"end":return _context4.stop();}},_callee3);}))),it("should toggle the expanded state when the button is clicked",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(){var _o$shadowRoot$querySe;var o,t;return _regeneratorRuntime().wrap(function _callee4$(_context5){while(1)switch(_context5.prev=_context5.next){case 0:_context5.next=2;return e(s(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context5.sent;t=(_o$shadowRoot$querySe=o.shadowRoot.querySelector(".nile-error-message__more-button"))!==null&&_o$shadowRoot$querySe!==void 0?_o$shadowRoot$querySe:{};t.click(),r(o.isExpanded).to.be["true"],t.click(),r(o.isExpanded).to.be["false"];case 5:case"end":return _context5.stop();}},_callee4);}))),it('should display the "View More" button if there is extended error information',/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(){var o;return _regeneratorRuntime().wrap(function _callee5$(_context6){while(1)switch(_context6.prev=_context6.next){case 0:_context6.next=2;return e(s(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context6.sent.shadowRoot.querySelector(".nile-error-message__more-button");r(o).to.exist;case 4:case"end":return _context6.stop();}},_callee5);}))),it('should not display the "View More" button if there is no extended error information',/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(){var o;return _regeneratorRuntime().wrap(function _callee6$(_context7){while(1)switch(_context7.prev=_context7.next){case 0:_context7.next=2;return e(s(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\"></nile-error-message>"]))));case 2:o=_context7.sent.shadowRoot.querySelector(".nile-error-message__more-button");r(o).to.not.exist;case 4:case"end":return _context7.stop();}},_callee6);}))),it("should show the extended error information when expanded",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(){var o,t;return _regeneratorRuntime().wrap(function _callee7$(_context8){while(1)switch(_context8.prev=_context8.next){case 0:_context8.next=2;return e(s(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context8.sent;o.isExpanded=!0;_context8.next=6;return o.updateComplete;case 6:t=o.shadowRoot.querySelector(".nile-error-message__response-expanded");r(t===null||t===void 0?void 0:t.textContent).to.include("Detailed error information");case 8:case"end":return _context8.stop();}},_callee7);}))),it("should hide the extended error information when collapsed",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee8(){var o,t;return _regeneratorRuntime().wrap(function _callee8$(_context9){while(1)switch(_context9.prev=_context9.next){case 0:_context9.next=2;return e(s(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context9.sent;o.isExpanded=!1;_context9.next=6;return o.updateComplete;case 6:t=o.shadowRoot.querySelector(".nile-error-message__response-expanded");r(t).to.have["class"]("collapsed");case 8:case"end":return _context9.stop();}},_callee8);}))),it("should render icon and error message parts",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee9(){var o,t,n;return _regeneratorRuntime().wrap(function _callee9$(_context10){while(1)switch(_context10.prev=_context10.next){case 0:_context10.next=2;return e(s(_templateObject9||(_templateObject9=_taggedTemplateLiteral(["<nile-error-message errorMessage=\"An error occurred\"></nile-error-message>"]))));case 2:o=_context10.sent;t=o.shadowRoot.querySelector("nile-icon");r(t).to.exist;n=o.shadowRoot.querySelector(".nile-error-message__error");r(n).to.exist;case 7:case"end":return _context10.stop();}},_callee9);})));});}};});
|
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(["../fixture-d5b55278.cjs.js","lit/static-html.js","lit/html.js","lit/directive-helpers.js","lit","lit/directives/unsafe-html.js","./nile-error-message.cjs.js","tslib","lit/decorators.js","./nile-error-message.css.cjs.js"],function(_export,_context){"use strict";var e,r,s,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,_templateObject9;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 _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}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);});};}return{setters:[function(_fixture001CjsJs){e=_fixture001CjsJs.f;r=_fixture001CjsJs.a;},function(_litStaticHtmlJs){s=_litStaticHtmlJs.html;},function(_litHtmlJs){},function(_litDirectiveHelpersJs){},function(_lit){},function(_litDirectivesUnsafeHtmlJs){},function(_nileErrorMessageCjsJs){},function(_tslib){},function(_litDecoratorsJs){},function(_nileErrorMessageCssCjsJs){}],execute:function execute(){describe("NileErrorMessage",function(){it("should render the error message",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(){var o;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:_context2.next=2;return e(s(_templateObject||(_templateObject=_taggedTemplateLiteral(["<nile-error-message errorMessage=\"An error occurred\"></nile-error-message>"]))));case 2:o=_context2.sent.shadowRoot.querySelector(".nile-error-message__error");r(o.textContent).to.equal("An error occurred");case 4:case"end":return _context2.stop();}},_callee);}))),it("should truncate the error response if it is too long",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(){var o,t;return _regeneratorRuntime().wrap(function _callee2$(_context3){while(1)switch(_context3.prev=_context3.next){case 0:o="a".repeat(150);_context3.next=3;return e(s(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"","\"></nile-error-message>"])),o));case 3:t=_context3.sent.getTruncatedResponse();r(t).to.equal("".concat(o.substring(0,100),"..."));case 5:case"end":return _context3.stop();}},_callee2);}))),it("should not truncate the error response if it is within the maximum length",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(){var o,t;return _regeneratorRuntime().wrap(function _callee3$(_context4){while(1)switch(_context4.prev=_context4.next){case 0:o="Short error message";_context4.next=3;return e(s(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"","\"></nile-error-message>"])),o));case 3:t=_context4.sent.getTruncatedResponse();r(t).to.equal(o);case 5:case"end":return _context4.stop();}},_callee3);}))),it("should toggle the expanded state when the button is clicked",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(){var _o$shadowRoot$querySe;var o,t;return _regeneratorRuntime().wrap(function _callee4$(_context5){while(1)switch(_context5.prev=_context5.next){case 0:_context5.next=2;return e(s(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context5.sent;t=(_o$shadowRoot$querySe=o.shadowRoot.querySelector(".nile-error-message__more-button"))!==null&&_o$shadowRoot$querySe!==void 0?_o$shadowRoot$querySe:{};t.click(),r(o.isExpanded).to.be["true"],t.click(),r(o.isExpanded).to.be["false"];case 5:case"end":return _context5.stop();}},_callee4);}))),it('should display the "View More" button if there is extended error information',/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(){var o;return _regeneratorRuntime().wrap(function _callee5$(_context6){while(1)switch(_context6.prev=_context6.next){case 0:_context6.next=2;return e(s(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context6.sent.shadowRoot.querySelector(".nile-error-message__more-button");r(o).to.exist;case 4:case"end":return _context6.stop();}},_callee5);}))),it('should not display the "View More" button if there is no extended error information',/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(){var o;return _regeneratorRuntime().wrap(function _callee6$(_context7){while(1)switch(_context7.prev=_context7.next){case 0:_context7.next=2;return e(s(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\"></nile-error-message>"]))));case 2:o=_context7.sent.shadowRoot.querySelector(".nile-error-message__more-button");r(o).to.not.exist;case 4:case"end":return _context7.stop();}},_callee6);}))),it("should show the extended error information when expanded",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(){var o,t;return _regeneratorRuntime().wrap(function _callee7$(_context8){while(1)switch(_context8.prev=_context8.next){case 0:_context8.next=2;return e(s(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context8.sent;o.isExpanded=!0;_context8.next=6;return o.updateComplete;case 6:t=o.shadowRoot.querySelector(".nile-error-message__response-expanded");r(t===null||t===void 0?void 0:t.textContent).to.include("Detailed error information");case 8:case"end":return _context8.stop();}},_callee7);}))),it("should hide the extended error information when collapsed",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee8(){var o,t;return _regeneratorRuntime().wrap(function _callee8$(_context9){while(1)switch(_context9.prev=_context9.next){case 0:_context9.next=2;return e(s(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["<nile-error-message errorResponse=\"Short error message\" errorResponseLong=\"Detailed error information\"></nile-error-message>"]))));case 2:o=_context9.sent;o.isExpanded=!1;_context9.next=6;return o.updateComplete;case 6:t=o.shadowRoot.querySelector(".nile-error-message__response-expanded");r(t).to.have["class"]("collapsed");case 8:case"end":return _context9.stop();}},_callee8);}))),it("should render icon and error message parts",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee9(){var o,t,n;return _regeneratorRuntime().wrap(function _callee9$(_context10){while(1)switch(_context10.prev=_context10.next){case 0:_context10.next=2;return e(s(_templateObject9||(_templateObject9=_taggedTemplateLiteral(["<nile-error-message errorMessage=\"An error occurred\"></nile-error-message>"]))));case 2:o=_context10.sent;t=o.shadowRoot.querySelector("nile-icon");r(t).to.exist;n=o.shadowRoot.querySelector(".nile-error-message__error");r(n).to.exist;case 7:case"end":return _context10.stop();}},_callee9);})));});}};});
|
2
2
|
//# sourceMappingURL=nile-error-message.test.cjs.js.map
|
@@ -1 +1 @@
|
|
1
|
-
import{f as e,a as r}from"../fixture-
|
1
|
+
import{f as e,a as r}from"../fixture-df8b52d7.esm.js";import{html as s}from"lit/static-html.js";import"lit/html.js";import"lit/directive-helpers.js";import"lit";import"lit/directives/unsafe-html.js";import"./nile-error-message.esm.js";import"tslib";import"lit/decorators.js";import"./nile-error-message.css.esm.js";describe("NileErrorMessage",(()=>{it("should render the error message",(async()=>{const o=(await e(s`<nile-error-message errorMessage="An error occurred"></nile-error-message>`)).shadowRoot.querySelector(".nile-error-message__error");r(o.textContent).to.equal("An error occurred")})),it("should truncate the error response if it is too long",(async()=>{const o="a".repeat(150),t=(await e(s`<nile-error-message errorResponse="${o}"></nile-error-message>`)).getTruncatedResponse();r(t).to.equal(`${o.substring(0,100)}...`)})),it("should not truncate the error response if it is within the maximum length",(async()=>{const o="Short error message",t=(await e(s`<nile-error-message errorResponse="${o}"></nile-error-message>`)).getTruncatedResponse();r(t).to.equal(o)})),it("should toggle the expanded state when the button is clicked",(async()=>{const o=await e(s`<nile-error-message errorResponse="Short error message" errorResponseLong="Detailed error information"></nile-error-message>`),t=o.shadowRoot.querySelector(".nile-error-message__more-button")??{};t.click(),r(o.isExpanded).to.be.true,t.click(),r(o.isExpanded).to.be.false})),it('should display the "View More" button if there is extended error information',(async()=>{const o=(await e(s`<nile-error-message errorResponse="Short error message" errorResponseLong="Detailed error information"></nile-error-message>`)).shadowRoot.querySelector(".nile-error-message__more-button");r(o).to.exist})),it('should not display the "View More" button if there is no extended error information',(async()=>{const o=(await e(s`<nile-error-message errorResponse="Short error message"></nile-error-message>`)).shadowRoot.querySelector(".nile-error-message__more-button");r(o).to.not.exist})),it("should show the extended error information when expanded",(async()=>{const o=await e(s`<nile-error-message errorResponse="Short error message" errorResponseLong="Detailed error information"></nile-error-message>`);o.isExpanded=!0,await o.updateComplete;const t=o.shadowRoot.querySelector(".nile-error-message__response-expanded");r(t?.textContent).to.include("Detailed error information")})),it("should hide the extended error information when collapsed",(async()=>{const o=await e(s`<nile-error-message errorResponse="Short error message" errorResponseLong="Detailed error information"></nile-error-message>`);o.isExpanded=!1,await o.updateComplete;const t=o.shadowRoot.querySelector(".nile-error-message__response-expanded");r(t).to.have.class("collapsed")})),it("should render icon and error message parts",(async()=>{const o=await e(s`<nile-error-message errorMessage="An error occurred"></nile-error-message>`),t=o.shadowRoot.querySelector("nile-icon");r(t).to.exist;const n=o.shadowRoot.querySelector(".nile-error-message__error");r(n).to.exist}))}));
|
@@ -1,2 +1,2 @@
|
|
1
|
-
System.register(["lit"],function(_export,_context){"use strict";var i,_templateObject,o;function _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}return{setters:[function(_lit){i=_lit.css;}],execute:function execute(){_export("s",o=i(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n :host {\n --indication-color: var(--nile-colors-red-
|
1
|
+
System.register(["lit"],function(_export,_context){"use strict";var i,_templateObject,o;function _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}return{setters:[function(_lit){i=_lit.css;}],execute:function execute(){_export("s",o=i(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n :host {\n --indication-color: var(--nile-colors-red-700);\n }\n\n .nile-error-notification {\n font-family: var(--nile-font-family-serif);\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 12px;\n letter-spacing: 0.2px;\n border: 1px solid var(--indication-color);\n border-left: 6px solid var(--indication-color);\n border-radius: 4px;\n padding: 8px;\n background: var(--nile-colors-neutral-100);\n color: var(--indication-color);\n box-sizing: border-box;\n }\n\n .nile-error-notification__icon {\n vertical-align: middle;\n margin-right: 4px;\n }\n"]))));}};});
|
2
2
|
//# sourceMappingURL=nile-error-notification.css.cjs.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"nile-error-notification.css.cjs.js","sources":["../../../src/nile-error-notification/nile-error-notification.css.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 { css } from 'lit';\n\n/**\n * ErrorNotification CSS\n */\nexport const styles = css`\n :host {\n --indication-color: var(--nile-colors-red-
|
1
|
+
{"version":3,"file":"nile-error-notification.css.cjs.js","sources":["../../../src/nile-error-notification/nile-error-notification.css.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 { css } from 'lit';\n\n/**\n * ErrorNotification CSS\n */\nexport const styles = css`\n :host {\n --indication-color: var(--nile-colors-red-700);\n }\n\n .nile-error-notification {\n font-family: var(--nile-font-family-serif);\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 12px;\n letter-spacing: 0.2px;\n border: 1px solid var(--indication-color);\n border-left: 6px solid var(--indication-color);\n border-radius: 4px;\n padding: 8px;\n background: var(--nile-colors-neutral-100);\n color: var(--indication-color);\n box-sizing: border-box;\n }\n\n .nile-error-notification__icon {\n vertical-align: middle;\n margin-right: 4px;\n }\n`;\n\nexport default [styles];\n"],"names":["styles","css","_templateObject","_taggedTemplateLiteral"],"mappings":"oTAYaA,CAAAA,CAASC,CAAG,CAAAC,eAAA,GAAAA,eAAA,CAAAC,sBAAA"}
|
@@ -0,0 +1,2 @@
|
|
1
|
+
System.register(["./nile-filter-chip.cjs.js","tslib","lit","lit/decorators.js","../internal/nile-element.cjs.js","./nile-filter-chip.css.cjs.js"],function(_export,_context){"use strict";return{setters:[function(_nileFilterChipCjsJs){_export("NileFilterChip",_nileFilterChipCjsJs.N);},function(_tslib){},function(_lit){},function(_litDecoratorsJs){},function(_internalNileElementCjsJs){},function(_nileFilterChipCssCjsJs){}],execute:function execute(){}};});
|
2
|
+
//# sourceMappingURL=index.cjs.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
@@ -0,0 +1 @@
|
|
1
|
+
export{N as NileFilterChip}from"./nile-filter-chip.esm.js";import"tslib";import"lit";import"lit/decorators.js";import"../internal/nile-element.esm.js";import"./nile-filter-chip.css.esm.js";
|
@@ -0,0 +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","../internal/nile-element.cjs.js","./nile-filter-chip.css.cjs.js"],function(_export,_context){"use strict";var t,e,s,i,l,n,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,_templateObject9,_templateObject10,_templateObject11,_o,a;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 _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(_lit){e=_lit.html;},function(_litDecoratorsJs){s=_litDecoratorsJs.property;i=_litDecoratorsJs.customElement;},function(_internalNileElementCjsJs){l=_internalNileElementCjsJs.N;},function(_nileFilterChipCssCjsJs){n=_nileFilterChipCssCjsJs.s;}],execute:function execute(){_export("N",a=_o=/*#__PURE__*/function(_l){function o(){var _this;_classCallCheck(this,o);_this=_callSuper(this,o,arguments),_this.label="",_this.text="",_this.viewMoreCount=0,_this.editable=!1,_this.closable=!1,_this.icon="",_this.removeIcon="",_this.active=!1,_this.maxWidth=140;return _this;}_inherits(o,_l);return _createClass(o,[{key:"connectedCallback",value:function connectedCallback(){_superPropGet(o,"connectedCallback",this,3)([]),this.registerChip();}},{key:"disconnectedCallback",value:function disconnectedCallback(){_superPropGet(o,"disconnectedCallback",this,3)([]),this.unregisterChip();}},{key:"registerChip",value:function registerChip(){_o.activeChips.push(this);}},{key:"unregisterChip",value:function unregisterChip(){var _this2=this;_o.activeChips=_o.activeChips.filter(function(t){return t!==_this2;});}},{key:"handleClose",value:function handleClose(t){t.stopPropagation(),this.dispatchEvent(new CustomEvent("nile-close",{detail:{text:this.text,viewMoreCount:this.viewMoreCount}})),this.remove();}},{key:"handleClick",value:function handleClick(){this.dispatchEvent(new CustomEvent("nile-click",{detail:{text:this.text,viewMoreCount:this.viewMoreCount}}));}},{key:"getLabelSlot",value:function getLabelSlot(){return e(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n <span class=\"label-wrapper\">\n <slot name=\"label\">\n <span class=\"label\">",":</span>\n </slot>\n </span>\n\n "])),this.label);}},{key:"getValueSlot",value:function getValueSlot(){return e(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["\n <span class=\"value-wrapper\">\n <slot name=\"value\">\n <span class=\"value\" style=\"max-width: ","px\">","</span>\n </slot>\n </span>\n\n "])),this.maxWidth,this.text);}},{key:"getviewMoreCountSlot",value:function getviewMoreCountSlot(){return e(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n <slot name=\"suffix\">\n ","\n </slot>\n "])),this.viewMoreCount?e(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n <span class=\"badge-wrapper\">\n <nile-badge variant=\"primary\" pilltype=\"pill-color\">\n +","\n </nile-badge>\n </span>\n\n "])),this.viewMoreCount):e(_templateObject5||(_templateObject5=_taggedTemplateLiteral([""]))));}},{key:"getCloseIconSlot",value:function getCloseIconSlot(){return e(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n ","\n "])),this.closable?e(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n <span class=\"close-icon\" @click=\"","\">\n <nile-icon name=\"","\" size=\"12\"></nile-icon>\n </span>\n "])),this.handleClose,this.removeIcon||"close"):e(_templateObject8||(_templateObject8=_taggedTemplateLiteral([""]))));}},{key:"render",value:function render(){return e(_templateObject9||(_templateObject9=_taggedTemplateLiteral(["\n <div class=\"chip\" @click=\"","\">\n <slot name=\"icon\">\n ","\n </slot>\n ","\n <slot name=\"content\"></slot>\n ","\n ","\n ","\n </div>\n "])),this.handleClick,this.icon?e(_templateObject10||(_templateObject10=_taggedTemplateLiteral(["<span class=\"icon\">","</span>"])),this.icon):e(_templateObject11||(_templateObject11=_taggedTemplateLiteral([""]))),this.getLabelSlot(),this.getValueSlot(),this.getviewMoreCountSlot(),this.getCloseIconSlot());}}],[{key:"styles",get:function get(){return[n];}}]);}(l));a.activeChips=[],t([s({type:String})],a.prototype,"label",void 0),t([s({type:String})],a.prototype,"text",void 0),t([s({type:Number})],a.prototype,"viewMoreCount",void 0),t([s({type:Boolean})],a.prototype,"editable",void 0),t([s({type:Boolean})],a.prototype,"closable",void 0),t([s({type:String})],a.prototype,"icon",void 0),t([s({type:String})],a.prototype,"removeIcon",void 0),t([s({type:Boolean,reflect:!0})],a.prototype,"active",void 0),t([s({type:Number})],a.prototype,"maxWidth",void 0),_export("N",a=_o=t([i("nile-filter-chip")],a));}};});
|
2
|
+
//# sourceMappingURL=nile-filter-chip.cjs.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"nile-filter-chip.cjs.js","sources":["../../../src/nile-filter-chip/nile-filter-chip.ts"],"sourcesContent":["import { LitElement, html, css, CSSResultArray, TemplateResult } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport NileElement from '../internal/nile-element';\nimport { styles } from './nile-filter-chip.css';\n\n/**\n * Nile filter-chip component.\n *\n * @tag nile-filter-chip\n */\n@customElement('nile-filter-chip')\nexport class NileFilterChip extends NileElement {\n @property({ type: String }) label = '';\n @property({ type: String }) text = '';\n @property({ type: Number }) viewMoreCount: number = 0;\n @property({ type: Boolean }) editable = false;\n @property({ type: Boolean }) closable = false;\n @property({ type: String }) icon = '';\n @property({ type: String }) removeIcon = '';\n @property({ type: Boolean, reflect: true }) active = false;\n @property({ type: Number }) maxWidth: number = 140;\n\n\n private static activeChips: NileFilterChip[] = [];\n\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.registerChip();\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.unregisterChip();\n }\n\n private registerChip() {\n NileFilterChip.activeChips.push(this);\n }\n\n private unregisterChip() {\n NileFilterChip.activeChips = NileFilterChip.activeChips.filter(\n (chip) => chip !== this\n );\n }\n\n private handleClose(event: Event) {\n event.stopPropagation();\n this.dispatchEvent(\n new CustomEvent('nile-close', { detail: { text: this.text, viewMoreCount: this.viewMoreCount } })\n );\n this.remove();\n }\n\n private handleClick() {\n this.dispatchEvent(\n new CustomEvent('nile-click', { detail: { text: this.text, viewMoreCount: this.viewMoreCount } })\n );\n }\n\n private getLabelSlot(): TemplateResult {\n return html`\n <span class=\"label-wrapper\">\n <slot name=\"label\">\n <span class=\"label\">${this.label}:</span>\n </slot>\n </span>\n\n `;\n }\n\n private getValueSlot(): TemplateResult {\n return html`\n <span class=\"value-wrapper\">\n <slot name=\"value\">\n <span class=\"value\" style=\"max-width: ${this.maxWidth}px\">${this.text}</span>\n </slot>\n </span>\n\n `;\n }\n\n private getviewMoreCountSlot(): TemplateResult {\n return html`\n <slot name=\"suffix\">\n ${this.viewMoreCount\n ? html`\n <span class=\"badge-wrapper\">\n <nile-badge variant=\"primary\" pilltype=\"pill-color\">\n +${this.viewMoreCount}\n </nile-badge>\n </span>\n\n `\n : html``}\n </slot>\n `;\n }\n\n private getCloseIconSlot(): TemplateResult {\n return html`\n ${this.closable\n ? html`\n <span class=\"close-icon\" @click=\"${this.handleClose}\">\n <nile-icon name=\"${this.removeIcon || 'close'}\" size=\"12\"></nile-icon>\n </span>\n `\n : html``}\n `;\n }\n\n public render(): TemplateResult {\n return html`\n <div class=\"chip\" @click=\"${this.handleClick}\">\n <slot name=\"icon\">\n ${this.icon ? html`<span class=\"icon\">${this.icon}</span>` : html``}\n </slot>\n ${this.getLabelSlot()}\n <slot name=\"content\"></slot>\n ${this.getValueSlot()}\n ${this.getviewMoreCountSlot()}\n ${this.getCloseIconSlot()}\n </div>\n `;\n }\n}\n\nexport default NileFilterChip;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-filter-chip': NileFilterChip;\n }\n}\n"],"names":["NileFilterChip","NileFilterChip_1","_l","o","this","label","text","viewMoreCount","editable","closable","icon","removeIcon","active","maxWidth","_this","_inherits","_createClass","key","value","connectedCallback","super","registerChip","disconnectedCallback","unregisterChip","activeChips","push","filter","chip","handleClose","event","stopPropagation","dispatchEvent","CustomEvent","detail","remove","handleClick","getLabelSlot","html","_templateObject","_taggedTemplateLiteral","getValueSlot","_templateObject2","getviewMoreCountSlot","_templateObject3","_templateObject4","_templateObject5","getCloseIconSlot","_templateObject6","_templateObject7","_templateObject8","render","_templateObject9","_templateObject10","_templateObject11","get","styles","NileElement","__decorate","property","type","String","prototype","Number","Boolean","reflect","customElement"],"mappings":"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"}
|
@@ -0,0 +1,2 @@
|
|
1
|
+
System.register(["lit"],function(_export,_context){"use strict";var e,_templateObject,i;function _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}return{setters:[function(_lit){e=_lit.css;}],execute:function execute(){_export("s",i=e(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n\n\n .filter-chips {\n display: flex;\n align-items: center;\n }\n\n\n .chip {\n display: inline-flex;\n align-items: center;\n height: 30px;\n padding: 8px;\n border: 1px solid var(--nile-filter-chip-chip-border-color-stroke);\n border-radius: 4px;\n font-size: 14px;\n background-color: var(--nile-filter-chip-background-default);\n color: var(--nile-filter-chip-text-default);\n transition: background-color 0.2s ease-in-out, border-color 0.2s ease-in-out;\n cursor: pointer;\n box-sizing: border-box;\n }\n\n .chip:hover {\n background-color: var(--nile-filter-chip-hover-background);\n }\n .chip:active {\n background-color: var(--nile-filter-chip-active-background);\n border-color: var(--nile-filter-chip-active-border-color-stroke);\n}\n:host([active]) .chip {\n background-color: var(--nile-filter-chip-active-background);\n border-color: var(--nile-filter-chip-active-border-color-stroke);\n}\n\n\n .icon {\n color: var(--nile-filter-chip-icon-color-default);\n display: flex;\n align-items: center;\n justify-content: center;\n vertical-align: middle;\n position: relative;\n top: 12px;\n }\n\n .label {\n font-weight: 500;\n color: var(--nile-filter-chip-label-color-default);\n }\n\n nile-badge::part(base) {\n width: auto;\n height: 14px;\n border-radius: 100px;\n padding: 6px;\n gap: 10px;\n font-size: 8px;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n line-height: 1;\n }\n\n .chip-container {\n display: flex;\n justify-content: space-between;\n align-items: center;\n width: 100%;\n }\n\n .clear-all-container {\n margin-left: 18px;\n white-space: nowrap;\n cursor: pointer;\n }\n\n\n .value {\n color: var(--nile-filter-chip-values-color-default);\n display: inline-block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n max-width: 140px;\n vertical-align: bottom;\n}\n\n\n .close-icon {\n color: var(--nile-filter-chip-close-icon-color-default);\n cursor: pointer;\n display: flex;\n align-items: center;\n border-radius: 50%;\n transition: background-color 0.2s;\n }\n\n .close-icon:hover {\n background-color: var(--nile-filter-chip-close-icon-hover-background);\n color: var(--nile-filter-chip-close-icon-hover-color);\n }\n\n.label-wrapper {\n margin-right: 4px;\n}\n\n::slotted([slot=\"icon\"]) {\n margin-right: 6px;\n}\n\n.value-wrapper {\n margin-right: 4px; \n}\n\n.badge-wrapper {\n margin-right: 12px; \n}\n\n"]))));}};});
|
2
|
+
//# sourceMappingURL=nile-filter-chip.css.cjs.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"nile-filter-chip.css.cjs.js","sources":["../../../src/nile-filter-chip/nile-filter-chip.css.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 {css} from 'lit';\n\n/**\n * FilterChip CSS\n */\n\nexport const styles = css`\n\n\n .filter-chips {\n display: flex;\n align-items: center;\n }\n\n\n .chip {\n display: inline-flex;\n align-items: center;\n height: 30px;\n padding: 8px;\n border: 1px solid var(--nile-filter-chip-chip-border-color-stroke);\n border-radius: 4px;\n font-size: 14px;\n background-color: var(--nile-filter-chip-background-default);\n color: var(--nile-filter-chip-text-default);\n transition: background-color 0.2s ease-in-out, border-color 0.2s ease-in-out;\n cursor: pointer;\n box-sizing: border-box;\n }\n\n .chip:hover {\n background-color: var(--nile-filter-chip-hover-background);\n }\n .chip:active {\n background-color: var(--nile-filter-chip-active-background);\n border-color: var(--nile-filter-chip-active-border-color-stroke);\n}\n:host([active]) .chip {\n background-color: var(--nile-filter-chip-active-background);\n border-color: var(--nile-filter-chip-active-border-color-stroke);\n}\n\n\n .icon {\n color: var(--nile-filter-chip-icon-color-default);\n display: flex;\n align-items: center;\n justify-content: center;\n vertical-align: middle;\n position: relative;\n top: 12px;\n }\n\n .label {\n font-weight: 500;\n color: var(--nile-filter-chip-label-color-default);\n }\n\n nile-badge::part(base) {\n width: auto;\n height: 14px;\n border-radius: 100px;\n padding: 6px;\n gap: 10px;\n font-size: 8px;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n line-height: 1;\n }\n\n .chip-container {\n display: flex;\n justify-content: space-between;\n align-items: center;\n width: 100%;\n }\n\n .clear-all-container {\n margin-left: 18px;\n white-space: nowrap;\n cursor: pointer;\n }\n\n\n .value {\n color: var(--nile-filter-chip-values-color-default);\n display: inline-block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n max-width: 140px;\n vertical-align: bottom;\n}\n\n\n .close-icon {\n color: var(--nile-filter-chip-close-icon-color-default);\n cursor: pointer;\n display: flex;\n align-items: center;\n border-radius: 50%;\n transition: background-color 0.2s;\n }\n\n .close-icon:hover {\n background-color: var(--nile-filter-chip-close-icon-hover-background);\n color: var(--nile-filter-chip-close-icon-hover-color);\n }\n\n.label-wrapper {\n margin-right: 4px;\n}\n\n::slotted([slot=\"icon\"]) {\n margin-right: 6px;\n}\n\n.value-wrapper {\n margin-right: 4px; \n}\n\n.badge-wrapper {\n margin-right: 12px; \n}\n\n`;\n\nexport default [styles];\n\n "],"names":["styles","css","_templateObject","_taggedTemplateLiteral"],"mappings":"oTAaaA,CAAAA,CAASC,CAAG,CAAAC,eAAA,GAAAA,eAAA,CAAAC,sBAAA"}
|
@@ -0,0 +1,121 @@
|
|
1
|
+
import{css as e}from"lit";const i=e`
|
2
|
+
|
3
|
+
|
4
|
+
.filter-chips {
|
5
|
+
display: flex;
|
6
|
+
align-items: center;
|
7
|
+
}
|
8
|
+
|
9
|
+
|
10
|
+
.chip {
|
11
|
+
display: inline-flex;
|
12
|
+
align-items: center;
|
13
|
+
height: 30px;
|
14
|
+
padding: 8px;
|
15
|
+
border: 1px solid var(--nile-filter-chip-chip-border-color-stroke);
|
16
|
+
border-radius: 4px;
|
17
|
+
font-size: 14px;
|
18
|
+
background-color: var(--nile-filter-chip-background-default);
|
19
|
+
color: var(--nile-filter-chip-text-default);
|
20
|
+
transition: background-color 0.2s ease-in-out, border-color 0.2s ease-in-out;
|
21
|
+
cursor: pointer;
|
22
|
+
box-sizing: border-box;
|
23
|
+
}
|
24
|
+
|
25
|
+
.chip:hover {
|
26
|
+
background-color: var(--nile-filter-chip-hover-background);
|
27
|
+
}
|
28
|
+
.chip:active {
|
29
|
+
background-color: var(--nile-filter-chip-active-background);
|
30
|
+
border-color: var(--nile-filter-chip-active-border-color-stroke);
|
31
|
+
}
|
32
|
+
:host([active]) .chip {
|
33
|
+
background-color: var(--nile-filter-chip-active-background);
|
34
|
+
border-color: var(--nile-filter-chip-active-border-color-stroke);
|
35
|
+
}
|
36
|
+
|
37
|
+
|
38
|
+
.icon {
|
39
|
+
color: var(--nile-filter-chip-icon-color-default);
|
40
|
+
display: flex;
|
41
|
+
align-items: center;
|
42
|
+
justify-content: center;
|
43
|
+
vertical-align: middle;
|
44
|
+
position: relative;
|
45
|
+
top: 12px;
|
46
|
+
}
|
47
|
+
|
48
|
+
.label {
|
49
|
+
font-weight: 500;
|
50
|
+
color: var(--nile-filter-chip-label-color-default);
|
51
|
+
}
|
52
|
+
|
53
|
+
nile-badge::part(base) {
|
54
|
+
width: auto;
|
55
|
+
height: 14px;
|
56
|
+
border-radius: 100px;
|
57
|
+
padding: 6px;
|
58
|
+
gap: 10px;
|
59
|
+
font-size: 8px;
|
60
|
+
display: inline-flex;
|
61
|
+
align-items: center;
|
62
|
+
justify-content: center;
|
63
|
+
line-height: 1;
|
64
|
+
}
|
65
|
+
|
66
|
+
.chip-container {
|
67
|
+
display: flex;
|
68
|
+
justify-content: space-between;
|
69
|
+
align-items: center;
|
70
|
+
width: 100%;
|
71
|
+
}
|
72
|
+
|
73
|
+
.clear-all-container {
|
74
|
+
margin-left: 18px;
|
75
|
+
white-space: nowrap;
|
76
|
+
cursor: pointer;
|
77
|
+
}
|
78
|
+
|
79
|
+
|
80
|
+
.value {
|
81
|
+
color: var(--nile-filter-chip-values-color-default);
|
82
|
+
display: inline-block;
|
83
|
+
overflow: hidden;
|
84
|
+
text-overflow: ellipsis;
|
85
|
+
white-space: nowrap;
|
86
|
+
max-width: 140px;
|
87
|
+
vertical-align: bottom;
|
88
|
+
}
|
89
|
+
|
90
|
+
|
91
|
+
.close-icon {
|
92
|
+
color: var(--nile-filter-chip-close-icon-color-default);
|
93
|
+
cursor: pointer;
|
94
|
+
display: flex;
|
95
|
+
align-items: center;
|
96
|
+
border-radius: 50%;
|
97
|
+
transition: background-color 0.2s;
|
98
|
+
}
|
99
|
+
|
100
|
+
.close-icon:hover {
|
101
|
+
background-color: var(--nile-filter-chip-close-icon-hover-background);
|
102
|
+
color: var(--nile-filter-chip-close-icon-hover-color);
|
103
|
+
}
|
104
|
+
|
105
|
+
.label-wrapper {
|
106
|
+
margin-right: 4px;
|
107
|
+
}
|
108
|
+
|
109
|
+
::slotted([slot="icon"]) {
|
110
|
+
margin-right: 6px;
|
111
|
+
}
|
112
|
+
|
113
|
+
.value-wrapper {
|
114
|
+
margin-right: 4px;
|
115
|
+
}
|
116
|
+
|
117
|
+
.badge-wrapper {
|
118
|
+
margin-right: 12px;
|
119
|
+
}
|
120
|
+
|
121
|
+
`;export{i as s};
|
@@ -0,0 +1,43 @@
|
|
1
|
+
import{__decorate as t}from"tslib";import{html as e}from"lit";import{property as s,customElement as i}from"lit/decorators.js";import{N as l}from"../internal/nile-element.esm.js";import{s as n}from"./nile-filter-chip.css.esm.js";var o;let a=o=class extends l{constructor(){super(...arguments),this.label="",this.text="",this.viewMoreCount=0,this.editable=!1,this.closable=!1,this.icon="",this.removeIcon="",this.active=!1,this.maxWidth=140}static get styles(){return[n]}connectedCallback(){super.connectedCallback(),this.registerChip()}disconnectedCallback(){super.disconnectedCallback(),this.unregisterChip()}registerChip(){o.activeChips.push(this)}unregisterChip(){o.activeChips=o.activeChips.filter((t=>t!==this))}handleClose(t){t.stopPropagation(),this.dispatchEvent(new CustomEvent("nile-close",{detail:{text:this.text,viewMoreCount:this.viewMoreCount}})),this.remove()}handleClick(){this.dispatchEvent(new CustomEvent("nile-click",{detail:{text:this.text,viewMoreCount:this.viewMoreCount}}))}getLabelSlot(){return e`
|
2
|
+
<span class="label-wrapper">
|
3
|
+
<slot name="label">
|
4
|
+
<span class="label">${this.label}:</span>
|
5
|
+
</slot>
|
6
|
+
</span>
|
7
|
+
|
8
|
+
`}getValueSlot(){return e`
|
9
|
+
<span class="value-wrapper">
|
10
|
+
<slot name="value">
|
11
|
+
<span class="value" style="max-width: ${this.maxWidth}px">${this.text}</span>
|
12
|
+
</slot>
|
13
|
+
</span>
|
14
|
+
|
15
|
+
`}getviewMoreCountSlot(){return e`
|
16
|
+
<slot name="suffix">
|
17
|
+
${this.viewMoreCount?e`
|
18
|
+
<span class="badge-wrapper">
|
19
|
+
<nile-badge variant="primary" pilltype="pill-color">
|
20
|
+
+${this.viewMoreCount}
|
21
|
+
</nile-badge>
|
22
|
+
</span>
|
23
|
+
|
24
|
+
`:e``}
|
25
|
+
</slot>
|
26
|
+
`}getCloseIconSlot(){return e`
|
27
|
+
${this.closable?e`
|
28
|
+
<span class="close-icon" @click="${this.handleClose}">
|
29
|
+
<nile-icon name="${this.removeIcon||"close"}" size="12"></nile-icon>
|
30
|
+
</span>
|
31
|
+
`:e``}
|
32
|
+
`}render(){return e`
|
33
|
+
<div class="chip" @click="${this.handleClick}">
|
34
|
+
<slot name="icon">
|
35
|
+
${this.icon?e`<span class="icon">${this.icon}</span>`:e``}
|
36
|
+
</slot>
|
37
|
+
${this.getLabelSlot()}
|
38
|
+
<slot name="content"></slot>
|
39
|
+
${this.getValueSlot()}
|
40
|
+
${this.getviewMoreCountSlot()}
|
41
|
+
${this.getCloseIconSlot()}
|
42
|
+
</div>
|
43
|
+
`}};a.activeChips=[],t([s({type:String})],a.prototype,"label",void 0),t([s({type:String})],a.prototype,"text",void 0),t([s({type:Number})],a.prototype,"viewMoreCount",void 0),t([s({type:Boolean})],a.prototype,"editable",void 0),t([s({type:Boolean})],a.prototype,"closable",void 0),t([s({type:String})],a.prototype,"icon",void 0),t([s({type:String})],a.prototype,"removeIcon",void 0),t([s({type:Boolean,reflect:!0})],a.prototype,"active",void 0),t([s({type:Number})],a.prototype,"maxWidth",void 0),a=o=t([i("nile-filter-chip")],a);export{a as N};
|
@@ -0,0 +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(["../fixture-d5b55278.cjs.js","lit/static-html.js","lit/html.js","lit/directive-helpers.js","lit","lit/directives/unsafe-html.js","./nile-filter-chip.cjs.js","tslib","lit/decorators.js","../internal/nile-element.cjs.js","./nile-filter-chip.css.cjs.js"],function(_export,_context){"use strict";var e,i,t,l,n,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8;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 _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}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);});};}return{setters:[function(_fixture001CjsJs){e=_fixture001CjsJs.f;i=_fixture001CjsJs.a;t=_fixture001CjsJs.o;},function(_litStaticHtmlJs){l=_litStaticHtmlJs.html;},function(_litHtmlJs){},function(_litDirectiveHelpersJs){},function(_lit){},function(_litDirectivesUnsafeHtmlJs){},function(_nileFilterChipCjsJs){n=_nileFilterChipCjsJs.N;},function(_tslib){},function(_litDecoratorsJs){},function(_internalNileElementCjsJs){},function(_nileFilterChipCssCjsJs){}],execute:function execute(){describe("<nile-filter-chip>",function(){afterEach(function(){n.activeChips=[];}),it("registers and unregisters itself in activeChips",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(){var t;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:_context2.next=2;return e(l(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n <nile-filter-chip label=\"L\" text=\"T\"></nile-filter-chip>\n "]))));case 2:t=_context2.sent;i(n.activeChips).to.include(t);t.remove();_context2.next=7;return t.updateComplete;case 7:i(n.activeChips).to.not.include(t);case 8:case"end":return _context2.stop();}},_callee);}))),it("renders fallback label and text",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(){var t,n,a;return _regeneratorRuntime().wrap(function _callee2$(_context3){while(1)switch(_context3.prev=_context3.next){case 0:_context3.next=2;return e(l(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["\n <nile-filter-chip label=\"MyLabel\" text=\"MyText\"></nile-filter-chip>\n "]))));case 2:t=_context3.sent;n=t.shadowRoot.querySelector(".label");a=t.shadowRoot.querySelector(".value");i(n.textContent).to.equal("MyLabel:"),i(a.textContent.trim()).to.equal("MyText");case 6:case"end":return _context3.stop();}},_callee2);}))),it("renders slotted label and value over fallback",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(){var t,n,a;return _regeneratorRuntime().wrap(function _callee3$(_context4){while(1)switch(_context4.prev=_context4.next){case 0:_context4.next=2;return e(l(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n <nile-filter-chip>\n <span slot=\"label\">SLOT-LBL</span>\n <span slot=\"value\">SLOT-VAL</span>\n </nile-filter-chip>\n "]))));case 2:t=_context4.sent;n=t.querySelector('[slot="label"]');a=t.querySelector('[slot="value"]');i(n.textContent).to.equal("SLOT-LBL"),i(a.textContent).to.equal("SLOT-VAL");case 6:case"end":return _context4.stop();}},_callee3);}))),it("renders an icon when the `icon` property is set",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(){var t;return _regeneratorRuntime().wrap(function _callee4$(_context5){while(1)switch(_context5.prev=_context5.next){case 0:_context5.next=2;return e(l(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n <nile-filter-chip icon=\"\u2605\" label=\"L\" text=\"T\"></nile-filter-chip>\n "]))));case 2:t=_context5.sent.shadowRoot.querySelector(".icon");i(t).to.exist,i(t.textContent).to.equal("★");case 4:case"end":return _context5.stop();}},_callee4);}))),it("does not render a badge when viewMoreCount is zero",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(){var t;return _regeneratorRuntime().wrap(function _callee5$(_context6){while(1)switch(_context6.prev=_context6.next){case 0:_context6.next=2;return e(l(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["\n <nile-filter-chip viewMoreCount=\"0\" label=\"L\" text=\"T\"></nile-filter-chip>\n "]))));case 2:t=_context6.sent;i(t.shadowRoot.querySelector("nile-badge")).to.be["null"];case 4:case"end":return _context6.stop();}},_callee5);}))),it("renders a +badge when viewMoreCount > 0",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(){var t;return _regeneratorRuntime().wrap(function _callee6$(_context7){while(1)switch(_context7.prev=_context7.next){case 0:_context7.next=2;return e(l(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n <nile-filter-chip viewMoreCount=\"5\" label=\"L\" text=\"T\"></nile-filter-chip>\n "]))));case 2:t=_context7.sent.shadowRoot.querySelector("nile-badge");i(t).to.exist,i(t.textContent).to.contain("+5");case 4:case"end":return _context7.stop();}},_callee6);}))),it("dispatches `nile-click` on chip click",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(){var n,a,s;return _regeneratorRuntime().wrap(function _callee7$(_context8){while(1)switch(_context8.prev=_context8.next){case 0:_context8.next=2;return e(l(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n <nile-filter-chip label=\"L\" text=\"T\"></nile-filter-chip>\n "]))));case 2:n=_context8.sent;a=n.shadowRoot.querySelector(".chip");setTimeout(function(){return a.click();});_context8.next=7;return t(n,"nile-click");case 7:s=_context8.sent;i(s.detail).to.deep.equal({text:"T",viewMoreCount:0});case 9:case"end":return _context8.stop();}},_callee7);}))),it("dispatches `nile-close` on close icon click and removes itself",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee8(){var n,a,s;return _regeneratorRuntime().wrap(function _callee8$(_context9){while(1)switch(_context9.prev=_context9.next){case 0:_context9.next=2;return e(l(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["\n <nile-filter-chip closable viewMoreCount=\"2\" text=\"TT\"></nile-filter-chip>\n "]))));case 2:n=_context9.sent;a=n.shadowRoot.querySelector(".close-icon");setTimeout(function(){return a.click();});_context9.next=7;return t(n,"nile-close");case 7:s=_context9.sent;i(s.detail).to.deep.equal({text:"TT",viewMoreCount:2}),i(document.body.contains(n)).to.be["false"];case 9:case"end":return _context9.stop();}},_callee8);})));});}};});
|
2
|
+
//# sourceMappingURL=nile-filter-chip.test.cjs.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"nile-filter-chip.test.cjs.js","sources":["../../../src/nile-filter-chip/nile-filter-chip.test.ts"],"sourcesContent":["import { fixture, expect, html, oneEvent } from '@open-wc/testing';\nimport './nile-filter-chip';\nimport { NileFilterChip } from './nile-filter-chip';\n\ndescribe('<nile-filter-chip>', () => {\n afterEach(() => {\n (NileFilterChip as any).activeChips = [];\n });\n\n it('registers and unregisters itself in activeChips', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip label=\"L\" text=\"T\"></nile-filter-chip>\n `);\n expect((NileFilterChip as any).activeChips).to.include(el);\n el.remove();\n await el.updateComplete;\n expect((NileFilterChip as any).activeChips).to.not.include(el);\n });\n\n it('renders fallback label and text', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip label=\"MyLabel\" text=\"MyText\"></nile-filter-chip>\n `);\n const label = el.shadowRoot!.querySelector('.label')! as HTMLElement;\n const value = el.shadowRoot!.querySelector('.value')! as HTMLElement;\n expect(label.textContent).to.equal('MyLabel:');\n expect(value.textContent!.trim()).to.equal('MyText');\n });\n\n it('renders slotted label and value over fallback', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip>\n <span slot=\"label\">SLOT-LBL</span>\n <span slot=\"value\">SLOT-VAL</span>\n </nile-filter-chip>\n `);\n const slottedLabel = el.querySelector('[slot=\"label\"]')! as HTMLElement;\n const slottedValue = el.querySelector('[slot=\"value\"]')! as HTMLElement;\n expect(slottedLabel.textContent).to.equal('SLOT-LBL');\n expect(slottedValue.textContent).to.equal('SLOT-VAL');\n });\n\n it('renders an icon when the `icon` property is set', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip icon=\"★\" label=\"L\" text=\"T\"></nile-filter-chip>\n `);\n const iconSpan = el.shadowRoot!.querySelector('.icon')! as HTMLElement;\n expect(iconSpan).to.exist;\n expect(iconSpan.textContent).to.equal('★');\n });\n\n it('does not render a badge when viewMoreCount is zero', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip viewMoreCount=\"0\" label=\"L\" text=\"T\"></nile-filter-chip>\n `);\n expect(el.shadowRoot!.querySelector('nile-badge')).to.be.null;\n });\n\n it('renders a +badge when viewMoreCount > 0', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip viewMoreCount=\"5\" label=\"L\" text=\"T\"></nile-filter-chip>\n `);\n const badge = el.shadowRoot!.querySelector('nile-badge')! as HTMLElement;\n expect(badge).to.exist;\n expect(badge.textContent).to.contain('+5');\n });\n\n\n\n it('dispatches `nile-click` on chip click', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip label=\"L\" text=\"T\"></nile-filter-chip>\n `);\n const chip = el.shadowRoot!.querySelector('.chip')! as HTMLElement;\n setTimeout(() => chip.click());\n const ev = await oneEvent(el, 'nile-click');\n expect(ev.detail).to.deep.equal({ text: 'T', viewMoreCount: 0 });\n });\n\n it('dispatches `nile-close` on close icon click and removes itself', async () => {\n const el = await fixture<NileFilterChip>(html`\n <nile-filter-chip closable viewMoreCount=\"2\" text=\"TT\"></nile-filter-chip>\n `);\n const closeIcon = el.shadowRoot!.querySelector('.close-icon')! as HTMLElement;\n setTimeout(() => closeIcon.click());\n const ev = await oneEvent(el, 'nile-close');\n expect(ev.detail).to.deep.equal({ text: 'TT', viewMoreCount: 2 });\n expect(document.body.contains(el)).to.be.false;\n });\n\n \n});\n"],"names":["describe","afterEach","NileFilterChip","activeChips","it","async","fixture","html","_templateObject","_taggedTemplateLiteral","el","expect","to","include","remove","updateComplete","not","_context2","stop","_callee","_templateObject2","label","shadowRoot","querySelector","value","textContent","equal","trim","_context3","_callee2","_templateObject3","slottedLabel","slottedValue","_context4","_callee3","_asyncToGenerator","_regeneratorRuntime","mark","_templateObject4","iconSpan","exist","_context5","_callee4","_templateObject5","be","null","_context6","_callee5","_templateObject6","badge","contain","_context7","_callee6","_templateObject7","chip","setTimeout","click","_context8","next","oneEvent","ev","detail","deep","text","viewMoreCount","_callee7","_templateObject8","closeIcon","_context9","document","body","contains","_callee8"],"mappings":"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"}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import{f as e,a as i,o as t}from"../fixture-df8b52d7.esm.js";import{html as l}from"lit/static-html.js";import"lit/html.js";import"lit/directive-helpers.js";import"lit";import"lit/directives/unsafe-html.js";import{N as n}from"./nile-filter-chip.esm.js";import"tslib";import"lit/decorators.js";import"../internal/nile-element.esm.js";import"./nile-filter-chip.css.esm.js";describe("<nile-filter-chip>",(()=>{afterEach((()=>{n.activeChips=[]})),it("registers and unregisters itself in activeChips",(async()=>{const t=await e(l`
|
2
|
+
<nile-filter-chip label="L" text="T"></nile-filter-chip>
|
3
|
+
`);i(n.activeChips).to.include(t),t.remove(),await t.updateComplete,i(n.activeChips).to.not.include(t)})),it("renders fallback label and text",(async()=>{const t=await e(l`
|
4
|
+
<nile-filter-chip label="MyLabel" text="MyText"></nile-filter-chip>
|
5
|
+
`),n=t.shadowRoot.querySelector(".label"),a=t.shadowRoot.querySelector(".value");i(n.textContent).to.equal("MyLabel:"),i(a.textContent.trim()).to.equal("MyText")})),it("renders slotted label and value over fallback",(async()=>{const t=await e(l`
|
6
|
+
<nile-filter-chip>
|
7
|
+
<span slot="label">SLOT-LBL</span>
|
8
|
+
<span slot="value">SLOT-VAL</span>
|
9
|
+
</nile-filter-chip>
|
10
|
+
`),n=t.querySelector('[slot="label"]'),a=t.querySelector('[slot="value"]');i(n.textContent).to.equal("SLOT-LBL"),i(a.textContent).to.equal("SLOT-VAL")})),it("renders an icon when the `icon` property is set",(async()=>{const t=(await e(l`
|
11
|
+
<nile-filter-chip icon="★" label="L" text="T"></nile-filter-chip>
|
12
|
+
`)).shadowRoot.querySelector(".icon");i(t).to.exist,i(t.textContent).to.equal("★")})),it("does not render a badge when viewMoreCount is zero",(async()=>{const t=await e(l`
|
13
|
+
<nile-filter-chip viewMoreCount="0" label="L" text="T"></nile-filter-chip>
|
14
|
+
`);i(t.shadowRoot.querySelector("nile-badge")).to.be.null})),it("renders a +badge when viewMoreCount > 0",(async()=>{const t=(await e(l`
|
15
|
+
<nile-filter-chip viewMoreCount="5" label="L" text="T"></nile-filter-chip>
|
16
|
+
`)).shadowRoot.querySelector("nile-badge");i(t).to.exist,i(t.textContent).to.contain("+5")})),it("dispatches `nile-click` on chip click",(async()=>{const n=await e(l`
|
17
|
+
<nile-filter-chip label="L" text="T"></nile-filter-chip>
|
18
|
+
`),a=n.shadowRoot.querySelector(".chip");setTimeout((()=>a.click()));const s=await t(n,"nile-click");i(s.detail).to.deep.equal({text:"T",viewMoreCount:0})})),it("dispatches `nile-close` on close icon click and removes itself",(async()=>{const n=await e(l`
|
19
|
+
<nile-filter-chip closable viewMoreCount="2" text="TT"></nile-filter-chip>
|
20
|
+
`),a=n.shadowRoot.querySelector(".close-icon");setTimeout((()=>a.click()));const s=await t(n,"nile-close");i(s.detail).to.deep.equal({text:"TT",viewMoreCount:2}),i(document.body.contains(n)).to.be.false}))}));
|
@@ -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(["../fixture-161dee0b.cjs.js","lit/static-html.js","lit/html.js","lit/directive-helpers.js","lit","lit/directives/unsafe-html.js","./nile-form-group.cjs.js","tslib","lit/decorators.js","./nile-form-group.css.cjs.js","../internal/nile-element.cjs.js"],function(_export,_context){"use strict";var t,e,i,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8;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 _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}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);});};}return{setters:[function(_fixture001CjsJs){t=_fixture001CjsJs.f;e=_fixture001CjsJs.a;},function(_litStaticHtmlJs){i=_litStaticHtmlJs.html;},function(_litHtmlJs){},function(_litDirectiveHelpersJs){},function(_lit){},function(_litDirectivesUnsafeHtmlJs){},function(_nileFormGroupCjsJs){},function(_tslib){},function(_litDecoratorsJs){},function(_nileFormGroupCssCjsJs){},function(_internalNileElementCjsJs){}],execute:function execute(){describe("NileFormGroup",function(){it("should have default properties",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(){var l;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:_context2.next=2;return t(i(_templateObject||(_templateObject=_taggedTemplateLiteral(["<nile-form-group></nile-form-group>"]))));case 2:l=_context2.sent;e(l.title).to.equal(""),e(l.subtitle).to.equal("");case 4:case"end":return _context2.stop();}},_callee);}))),it("should render title when set",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(){var _l$textContent;var l;return _regeneratorRuntime().wrap(function _callee2$(_context3){while(1)switch(_context3.prev=_context3.next){case 0:_context3.next=2;return t(i(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\"></nile-form-group>"]))));case 2:l=_context3.sent.shadowRoot.querySelector('slot[name="title"]');e(l).to.exist,e(l===null||l===void 0||(_l$textContent=l.textContent)===null||_l$textContent===void 0?void 0:_l$textContent.trim()).to.equal("Test Title");case 4:case"end":return _context3.stop();}},_callee2);}))),it("should render subtitle when set",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(){var _l$textContent2;var l;return _regeneratorRuntime().wrap(function _callee3$(_context4){while(1)switch(_context4.prev=_context4.next){case 0:_context4.next=2;return t(i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\" subtitle=\"Test Subtitle\"></nile-form-group>"]))));case 2:l=_context4.sent.shadowRoot.querySelector('slot[name="subtitle"]');e(l).to.exist,e(l===null||l===void 0||(_l$textContent2=l.textContent)===null||_l$textContent2===void 0?void 0:_l$textContent2.trim()).to.equal("Test Subtitle");case 4:case"end":return _context4.stop();}},_callee3);}))),it("should not render title and subtitle if not set",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(){var l,o,s;return _regeneratorRuntime().wrap(function _callee4$(_context5){while(1)switch(_context5.prev=_context5.next){case 0:_context5.next=2;return t(i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["<nile-form-group></nile-form-group>"]))));case 2:l=_context5.sent;o=l.shadowRoot.querySelector('slot[name="title"]');s=l.shadowRoot.querySelector('slot[name="subtitle"]');e(o).to.not.exist,e(s).to.not.exist;case 6:case"end":return _context5.stop();}},_callee4);}))),it("should render content inside the form body slot",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(){var _l$assignedNodes;var l,o;return _regeneratorRuntime().wrap(function _callee5$(_context6){while(1)switch(_context6.prev=_context6.next){case 0:_context6.next=2;return t(i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["<nile-form-group><p>Form Content</p></nile-form-group>"]))));case 2:l=_context6.sent.shadowRoot.querySelector(".form__body slot");o=(_l$assignedNodes=l===null||l===void 0?void 0:l.assignedNodes())!==null&&_l$assignedNodes!==void 0?_l$assignedNodes:[];e(o.length).to.equal(1),e(o[0].textContent.trim()).to.equal("Form Content");case 5:case"end":return _context6.stop();}},_callee5);}))),it("should reflect title and subtitle attributes",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(){var l;return _regeneratorRuntime().wrap(function _callee6$(_context7){while(1)switch(_context7.prev=_context7.next){case 0:_context7.next=2;return t(i(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\" subtitle=\"Test Subtitle\"></nile-form-group>"]))));case 2:l=_context7.sent;e(l.getAttribute("title")).to.equal("Test Title"),e(l.getAttribute("subtitle")).to.equal("Test Subtitle");case 4:case"end":return _context7.stop();}},_callee6);}))),it("should update the title dynamically",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(){var _l$shadowRoot$querySe;var l,o;return _regeneratorRuntime().wrap(function _callee7$(_context8){while(1)switch(_context8.prev=_context8.next){case 0:_context8.next=2;return t(i(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["<nile-form-group title=\"Initial Title\"></nile-form-group>"]))));case 2:l=_context8.sent;l.title="Updated Title";_context8.next=6;return l.updateComplete;case 6:o=(_l$shadowRoot$querySe=l.shadowRoot.querySelector('slot[name="title"]'))!==null&&_l$shadowRoot$querySe!==void 0?_l$shadowRoot$querySe:{};e(o.textContent.trim()).to.equal("Updated Title");case 8:case"end":return _context8.stop();}},_callee7);}))),it("should update the subtitle dynamically",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee8(){var _l$shadowRoot$querySe2;var l,o;return _regeneratorRuntime().wrap(function _callee8$(_context9){while(1)switch(_context9.prev=_context9.next){case 0:_context9.next=2;return t(i(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\" subtitle=\"Initial Subtitle\"></nile-form-group>"]))));case 2:l=_context9.sent;l.subtitle="Updated Subtitle";_context9.next=6;return l.updateComplete;case 6:o=(_l$shadowRoot$querySe2=l.shadowRoot.querySelector('slot[name="subtitle"]'))!==null&&_l$shadowRoot$querySe2!==void 0?_l$shadowRoot$querySe2:{};e(o.textContent.trim()).to.equal("Updated Subtitle");case 8:case"end":return _context9.stop();}},_callee8);})));});}};});
|
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(["../fixture-d5b55278.cjs.js","lit/static-html.js","lit/html.js","lit/directive-helpers.js","lit","lit/directives/unsafe-html.js","./nile-form-group.cjs.js","tslib","lit/decorators.js","./nile-form-group.css.cjs.js","../internal/nile-element.cjs.js"],function(_export,_context){"use strict";var t,e,i,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8;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 _taggedTemplateLiteral(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}));}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);});};}return{setters:[function(_fixture001CjsJs){t=_fixture001CjsJs.f;e=_fixture001CjsJs.a;},function(_litStaticHtmlJs){i=_litStaticHtmlJs.html;},function(_litHtmlJs){},function(_litDirectiveHelpersJs){},function(_lit){},function(_litDirectivesUnsafeHtmlJs){},function(_nileFormGroupCjsJs){},function(_tslib){},function(_litDecoratorsJs){},function(_nileFormGroupCssCjsJs){},function(_internalNileElementCjsJs){}],execute:function execute(){describe("NileFormGroup",function(){it("should have default properties",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(){var l;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:_context2.next=2;return t(i(_templateObject||(_templateObject=_taggedTemplateLiteral(["<nile-form-group></nile-form-group>"]))));case 2:l=_context2.sent;e(l.title).to.equal(""),e(l.subtitle).to.equal("");case 4:case"end":return _context2.stop();}},_callee);}))),it("should render title when set",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(){var _l$textContent;var l;return _regeneratorRuntime().wrap(function _callee2$(_context3){while(1)switch(_context3.prev=_context3.next){case 0:_context3.next=2;return t(i(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\"></nile-form-group>"]))));case 2:l=_context3.sent.shadowRoot.querySelector('slot[name="title"]');e(l).to.exist,e(l===null||l===void 0||(_l$textContent=l.textContent)===null||_l$textContent===void 0?void 0:_l$textContent.trim()).to.equal("Test Title");case 4:case"end":return _context3.stop();}},_callee2);}))),it("should render subtitle when set",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(){var _l$textContent2;var l;return _regeneratorRuntime().wrap(function _callee3$(_context4){while(1)switch(_context4.prev=_context4.next){case 0:_context4.next=2;return t(i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\" subtitle=\"Test Subtitle\"></nile-form-group>"]))));case 2:l=_context4.sent.shadowRoot.querySelector('slot[name="subtitle"]');e(l).to.exist,e(l===null||l===void 0||(_l$textContent2=l.textContent)===null||_l$textContent2===void 0?void 0:_l$textContent2.trim()).to.equal("Test Subtitle");case 4:case"end":return _context4.stop();}},_callee3);}))),it("should not render title and subtitle if not set",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(){var l,o,s;return _regeneratorRuntime().wrap(function _callee4$(_context5){while(1)switch(_context5.prev=_context5.next){case 0:_context5.next=2;return t(i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["<nile-form-group></nile-form-group>"]))));case 2:l=_context5.sent;o=l.shadowRoot.querySelector('slot[name="title"]');s=l.shadowRoot.querySelector('slot[name="subtitle"]');e(o).to.not.exist,e(s).to.not.exist;case 6:case"end":return _context5.stop();}},_callee4);}))),it("should render content inside the form body slot",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(){var _l$assignedNodes;var l,o;return _regeneratorRuntime().wrap(function _callee5$(_context6){while(1)switch(_context6.prev=_context6.next){case 0:_context6.next=2;return t(i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["<nile-form-group><p>Form Content</p></nile-form-group>"]))));case 2:l=_context6.sent.shadowRoot.querySelector(".form__body slot");o=(_l$assignedNodes=l===null||l===void 0?void 0:l.assignedNodes())!==null&&_l$assignedNodes!==void 0?_l$assignedNodes:[];e(o.length).to.equal(1),e(o[0].textContent.trim()).to.equal("Form Content");case 5:case"end":return _context6.stop();}},_callee5);}))),it("should reflect title and subtitle attributes",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(){var l;return _regeneratorRuntime().wrap(function _callee6$(_context7){while(1)switch(_context7.prev=_context7.next){case 0:_context7.next=2;return t(i(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\" subtitle=\"Test Subtitle\"></nile-form-group>"]))));case 2:l=_context7.sent;e(l.getAttribute("title")).to.equal("Test Title"),e(l.getAttribute("subtitle")).to.equal("Test Subtitle");case 4:case"end":return _context7.stop();}},_callee6);}))),it("should update the title dynamically",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(){var _l$shadowRoot$querySe;var l,o;return _regeneratorRuntime().wrap(function _callee7$(_context8){while(1)switch(_context8.prev=_context8.next){case 0:_context8.next=2;return t(i(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["<nile-form-group title=\"Initial Title\"></nile-form-group>"]))));case 2:l=_context8.sent;l.title="Updated Title";_context8.next=6;return l.updateComplete;case 6:o=(_l$shadowRoot$querySe=l.shadowRoot.querySelector('slot[name="title"]'))!==null&&_l$shadowRoot$querySe!==void 0?_l$shadowRoot$querySe:{};e(o.textContent.trim()).to.equal("Updated Title");case 8:case"end":return _context8.stop();}},_callee7);}))),it("should update the subtitle dynamically",/*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee8(){var _l$shadowRoot$querySe2;var l,o;return _regeneratorRuntime().wrap(function _callee8$(_context9){while(1)switch(_context9.prev=_context9.next){case 0:_context9.next=2;return t(i(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["<nile-form-group title=\"Test Title\" subtitle=\"Initial Subtitle\"></nile-form-group>"]))));case 2:l=_context9.sent;l.subtitle="Updated Subtitle";_context9.next=6;return l.updateComplete;case 6:o=(_l$shadowRoot$querySe2=l.shadowRoot.querySelector('slot[name="subtitle"]'))!==null&&_l$shadowRoot$querySe2!==void 0?_l$shadowRoot$querySe2:{};e(o.textContent.trim()).to.equal("Updated Subtitle");case 8:case"end":return _context9.stop();}},_callee8);})));});}};});
|
2
2
|
//# sourceMappingURL=nile-form-group.test.cjs.js.map
|