q2-tecton-elements 1.55.4 → 1.56.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle-report.json +15973 -11906
- package/dist/cjs/{index-905f4c87.js → index-99667782.js} +5 -1
- package/dist/cjs/index-99667782.js.map +1 -0
- package/dist/cjs/{index-e0aba375.js → index-f69742cf.js} +1 -1
- package/dist/cjs/{index-e0aba375.js.map → index-f69742cf.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/q2-action-group.cjs.entry.js +2 -2
- package/dist/cjs/q2-action-sheet.cjs.entry.js +2 -2
- package/dist/cjs/q2-avatar.cjs.entry.js +2 -2
- package/dist/cjs/q2-avatar.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-badge_7.cjs.entry.js +56 -55
- package/dist/cjs/q2-badge_7.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-calendar.cjs.entry.js +3 -3
- package/dist/cjs/q2-card.cjs.entry.js +1 -1
- package/dist/cjs/q2-carousel-pane.cjs.entry.js +3 -3
- package/dist/cjs/q2-carousel.cjs.entry.js +2 -2
- package/dist/cjs/q2-chart-area.cjs.entry.js +2 -2
- package/dist/cjs/q2-chart-bar.cjs.entry.js +2 -2
- package/dist/cjs/q2-chart-donut.cjs.entry.js +2 -2
- package/dist/cjs/q2-checkbox-group.cjs.entry.js +2 -2
- package/dist/cjs/q2-checkbox.cjs.entry.js +3 -3
- package/dist/cjs/q2-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-currency.cjs.entry.js +2 -2
- package/dist/cjs/q2-currency.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-data-table.cjs.entry.js +3 -3
- package/dist/cjs/q2-data-table.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-detail.cjs.entry.js +2 -2
- package/dist/cjs/q2-dropdown-item.cjs.entry.js +1 -1
- package/dist/cjs/q2-dropdown.cjs.entry.js +2 -2
- package/dist/cjs/q2-editable-field.cjs.entry.js +2 -2
- package/dist/cjs/q2-example.cjs.entry.js +1 -1
- package/dist/cjs/q2-file-picker.cjs.entry.js +20 -7
- package/dist/cjs/q2-file-picker.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-form.cjs.entry.js +1 -1
- package/dist/cjs/q2-formatted-text.cjs.entry.js +1 -1
- package/dist/cjs/q2-grid-area.cjs.entry.js +133 -0
- package/dist/cjs/q2-grid-area.cjs.entry.js.map +1 -0
- package/dist/cjs/q2-grid.cjs.entry.js +109 -0
- package/dist/cjs/q2-grid.cjs.entry.js.map +1 -0
- package/dist/cjs/q2-item_3.cjs.entry.js +4 -4
- package/dist/cjs/q2-item_3.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-legend.cjs.entry.js +1 -1
- package/dist/cjs/q2-loc.cjs.entry.js +1 -1
- package/dist/cjs/q2-message.cjs.entry.js +2 -2
- package/dist/cjs/q2-modal.cjs.entry.js +2 -2
- package/dist/cjs/q2-month-picker.cjs.entry.js +3 -3
- package/dist/cjs/q2-optgroup.cjs.entry.js +2 -2
- package/dist/cjs/q2-option-list_2.cjs.entry.js +18 -6
- package/dist/cjs/q2-option-list_2.cjs.entry.js.map +1 -1
- package/dist/cjs/q2-option.cjs.entry.js +1 -1
- package/dist/cjs/q2-pagination.cjs.entry.js +4 -4
- package/dist/cjs/q2-pill.cjs.entry.js +2 -2
- package/dist/cjs/q2-radio-group.cjs.entry.js +2 -2
- package/dist/cjs/q2-radio.cjs.entry.js +2 -2
- package/dist/cjs/q2-relative-time.cjs.entry.js +3 -3
- package/dist/cjs/q2-resize-observer.cjs.entry.js +1 -1
- package/dist/cjs/q2-section.cjs.entry.js +3 -3
- package/dist/cjs/q2-select.cjs.entry.js +3 -3
- package/dist/cjs/q2-stepper-pane.cjs.entry.js +2 -2
- package/dist/cjs/q2-stepper-vertical.cjs.entry.js +2 -2
- package/dist/cjs/q2-stepper.cjs.entry.js +2 -2
- package/dist/cjs/q2-tag.cjs.entry.js +2 -2
- package/dist/cjs/q2-tecton-elements.cjs.js +1 -1
- package/dist/cjs/q2-textarea.cjs.entry.js +2 -2
- package/dist/cjs/q2-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/tecton-tab-pane.cjs.entry.js +2 -2
- package/dist/collection/collection-manifest.json +8 -6
- package/dist/collection/components/q2-action-group/q2-action-group.js +1 -1
- package/dist/collection/components/q2-action-sheet/q2-action-sheet.js +1 -1
- package/dist/collection/components/q2-avatar/q2-avatar.css +8 -8
- package/dist/collection/components/q2-avatar/q2-avatar.js +1 -1
- package/dist/collection/components/q2-calendar/q2-calendar.js +1 -1
- package/dist/collection/components/q2-calendar/q2-month-picker.js +2 -2
- package/dist/collection/components/q2-carousel/q2-carousel.js +1 -1
- package/dist/collection/components/q2-carousel-pane/q2-carousel-pane.js +2 -2
- package/dist/collection/components/q2-chart-area/q2-chart-area.js +1 -1
- package/dist/collection/components/q2-chart-bar/q2-chart-bar.js +1 -1
- package/dist/collection/components/q2-chart-donut/q2-chart-donut.js +1 -1
- package/dist/collection/components/q2-checkbox/q2-checkbox.css +6 -2
- package/dist/collection/components/q2-checkbox/q2-checkbox.js +1 -1
- package/dist/collection/components/q2-checkbox-group/q2-checkbox-group.js +1 -1
- package/dist/collection/components/q2-currency/q2-currency.css +2 -2
- package/dist/collection/components/q2-currency/q2-currency.js +1 -1
- package/dist/collection/components/q2-data-table/q2-data-table.css +1 -2
- package/dist/collection/components/q2-data-table/q2-data-table.js +8 -8
- package/dist/collection/components/q2-detail/q2-detail.js +1 -1
- package/dist/collection/components/q2-dropdown/q2-dropdown.js +1 -1
- package/dist/collection/components/q2-editable-field/q2-editable-field.js +1 -1
- package/dist/collection/components/q2-example/q2-example.js +1 -1
- package/dist/collection/components/q2-file-picker/q2-file-picker.css +11 -2
- package/dist/collection/components/q2-file-picker/q2-file-picker.js +54 -14
- package/dist/collection/components/q2-file-picker/q2-file-picker.js.map +1 -1
- package/dist/collection/components/q2-file-picker/test/q2-file-picker-test.e2e.js +25 -0
- package/dist/collection/components/q2-file-picker/test/q2-file-picker-test.e2e.js.map +1 -1
- package/dist/collection/components/q2-file-picker/test/q2-file-picker-test.spec.js +107 -18
- package/dist/collection/components/q2-file-picker/test/q2-file-picker-test.spec.js.map +1 -1
- package/dist/collection/components/q2-form/q2-form.js +1 -1
- package/dist/collection/components/q2-formatted-text/q2-formatted-text.js +1 -1
- package/dist/collection/components/q2-grid/q2-grid.css +98 -0
- package/dist/collection/components/q2-grid/q2-grid.js +807 -0
- package/dist/collection/components/q2-grid/q2-grid.js.map +1 -0
- package/dist/collection/components/q2-grid/test/q2-grid.e2e.js +218 -0
- package/dist/collection/components/q2-grid/test/q2-grid.e2e.js.map +1 -0
- package/dist/collection/components/q2-grid-area/q2-grid-area.css +110 -0
- package/dist/collection/components/q2-grid-area/q2-grid-area.js +1109 -0
- package/dist/collection/components/q2-grid-area/q2-grid-area.js.map +1 -0
- package/dist/collection/components/q2-grid-area/test/q2-grid-area.e2e.js +196 -0
- package/dist/collection/components/q2-grid-area/test/q2-grid-area.e2e.js.map +1 -0
- package/dist/collection/components/q2-icon/assets/brand.symbol.svg +1 -1
- package/dist/collection/components/q2-icon/assets/browsersos.symbol.svg +1 -0
- package/dist/collection/components/q2-icon/assets/cards.symbol.svg +1 -1
- package/dist/collection/components/q2-icon/assets/{system.symbol.svg → devices.symbol.svg} +1 -1
- package/dist/collection/components/q2-icon/assets/icon-file-list.json +1 -1
- package/dist/collection/components/q2-icon/assets/icon-map.json +1 -1
- package/dist/collection/components/q2-icon/assets/legacy.symbol.svg +1 -1
- package/dist/collection/components/q2-icon/assets/mobile.symbol.svg +1 -1
- package/dist/collection/components/q2-icon/q2-icon.css +7 -1
- package/dist/collection/components/q2-icon/q2-icon.js +3 -2
- package/dist/collection/components/q2-icon/q2-icon.js.map +1 -1
- package/dist/collection/components/q2-icon/test/q2-icon-test.spec.js +3 -3
- package/dist/collection/components/q2-icon/test/q2-icon-test.spec.js.map +1 -1
- package/dist/collection/components/q2-input/q2-input.js +2 -2
- package/dist/collection/components/q2-input/test/q2-input-test.e2e.js +5 -3
- package/dist/collection/components/q2-input/test/q2-input-test.e2e.js.map +1 -1
- package/dist/collection/components/q2-item/q2-item.css +3 -3
- package/dist/collection/components/q2-item/q2-item.js +1 -1
- package/dist/collection/components/q2-legend/q2-legend.js +1 -1
- package/dist/collection/components/q2-list/q2-list.js +1 -1
- package/dist/collection/components/q2-message/q2-message.js +1 -1
- package/dist/collection/components/q2-modal/q2-modal.js +1 -1
- package/dist/collection/components/q2-optgroup/q2-optgroup.js +1 -1
- package/dist/collection/components/q2-option-list/q2-option-list.js +7 -7
- package/dist/collection/components/q2-pagination/q2-pagination.js +3 -3
- package/dist/collection/components/q2-pill/q2-pill.js +1 -1
- package/dist/collection/components/q2-popover/q2-popover.js +40 -5
- package/dist/collection/components/q2-popover/q2-popover.js.map +1 -1
- package/dist/collection/components/q2-popover/test/q2-popover-test.spec.js +2 -2
- package/dist/collection/components/q2-popover/test/q2-popover-test.spec.js.map +1 -1
- package/dist/collection/components/q2-radio/q2-radio.js +1 -1
- package/dist/collection/components/q2-radio-group/q2-radio-group.js +1 -1
- package/dist/collection/components/q2-relative-time/q2-relative-time.js +1 -1
- package/dist/collection/components/q2-resize-observer/q2-resize-observer.js +1 -1
- package/dist/collection/components/q2-section/q2-section.js +2 -2
- package/dist/collection/components/q2-select/q2-select.js +2 -2
- package/dist/collection/components/q2-stepper/q2-stepper.js +1 -1
- package/dist/collection/components/q2-stepper-pane/q2-stepper-pane.js +3 -3
- package/dist/collection/components/q2-stepper-vertical/q2-stepper-vertical.js +1 -1
- package/dist/collection/components/q2-tab-container/q2-tab-container.js +1 -1
- package/dist/collection/components/q2-tab-pane/q2-tab-pane.js +1 -1
- package/dist/collection/components/q2-tag/q2-tag.js +1 -1
- package/dist/collection/components/q2-textarea/q2-textarea.js +1 -1
- package/dist/collection/components/tecton-tab-pane/tecton-tab-pane.js +2 -2
- package/dist/collection/utils/helpers.js +15 -0
- package/dist/collection/utils/helpers.js.map +1 -1
- package/dist/collection/utils/index.js +3 -0
- package/dist/collection/utils/index.js.map +1 -1
- package/dist/components/index.js +4 -0
- package/dist/components/index.js.map +1 -1
- package/dist/components/index2.js +4 -1
- package/dist/components/index2.js.map +1 -1
- package/dist/components/q2-action-group2.js +1 -1
- package/dist/components/q2-action-sheet.js +1 -1
- package/dist/components/q2-avatar2.js +2 -2
- package/dist/components/q2-avatar2.js.map +1 -1
- package/dist/components/q2-calendar.js +1 -1
- package/dist/components/q2-carousel-pane.js +2 -2
- package/dist/components/q2-carousel.js +1 -1
- package/dist/components/q2-chart-area.js +1 -1
- package/dist/components/q2-chart-bar.js +1 -1
- package/dist/components/q2-chart-donut.js +1 -1
- package/dist/components/q2-checkbox-group.js +1 -1
- package/dist/components/q2-checkbox2.js +2 -2
- package/dist/components/q2-checkbox2.js.map +1 -1
- package/dist/components/q2-currency.js +2 -2
- package/dist/components/q2-currency.js.map +1 -1
- package/dist/components/q2-data-table.js +2 -2
- package/dist/components/q2-data-table.js.map +1 -1
- package/dist/components/q2-detail.js +1 -1
- package/dist/components/q2-dropdown.js +1 -1
- package/dist/components/q2-editable-field.js +1 -1
- package/dist/components/q2-example.js +1 -1
- package/dist/components/q2-file-picker.js +20 -6
- package/dist/components/q2-file-picker.js.map +1 -1
- package/dist/components/q2-form.js +1 -1
- package/dist/components/q2-formatted-text.js +1 -1
- package/dist/components/q2-grid-area.d.ts +11 -0
- package/dist/components/q2-grid-area.js +190 -0
- package/dist/components/q2-grid-area.js.map +1 -0
- package/dist/components/q2-grid.d.ts +11 -0
- package/dist/components/q2-grid.js +154 -0
- package/dist/components/q2-grid.js.map +1 -0
- package/dist/components/q2-icon2.js +52 -51
- package/dist/components/q2-icon2.js.map +1 -1
- package/dist/components/q2-input2.js +1 -1
- package/dist/components/q2-item2.js +2 -2
- package/dist/components/q2-item2.js.map +1 -1
- package/dist/components/q2-legend2.js +1 -1
- package/dist/components/q2-list2.js +1 -1
- package/dist/components/q2-message2.js +1 -1
- package/dist/components/q2-modal.js +1 -1
- package/dist/components/q2-month-picker.js +2 -2
- package/dist/components/q2-optgroup2.js +1 -1
- package/dist/components/q2-option-list2.js +1 -1
- package/dist/components/q2-pagination.js +3 -3
- package/dist/components/q2-pill.js +1 -1
- package/dist/components/q2-popover2.js +17 -5
- package/dist/components/q2-popover2.js.map +1 -1
- package/dist/components/q2-radio-group.js +1 -1
- package/dist/components/q2-radio.js +1 -1
- package/dist/components/q2-relative-time.js +1 -1
- package/dist/components/q2-resize-observer2.js +1 -1
- package/dist/components/q2-section.js +2 -2
- package/dist/components/q2-select2.js +3 -3
- package/dist/components/q2-stepper-pane.js +1 -1
- package/dist/components/q2-stepper-vertical.js +1 -1
- package/dist/components/q2-stepper.js +1 -1
- package/dist/components/q2-tab-container.js +1 -1
- package/dist/components/q2-tab-pane.js +1 -1
- package/dist/components/q2-tag.js +1 -1
- package/dist/components/q2-textarea.js +1 -1
- package/dist/components/tecton-tab-pane.js +2 -2
- package/dist/esm/{index-3bb7a785.js → index-3184c760.js} +1 -1
- package/dist/esm/{index-3bb7a785.js.map → index-3184c760.js.map} +1 -1
- package/dist/esm/{index-f2a66217.js → index-c215e8ef.js} +5 -2
- package/dist/esm/index-c215e8ef.js.map +1 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/q2-action-group.entry.js +2 -2
- package/dist/esm/q2-action-sheet.entry.js +2 -2
- package/dist/esm/q2-avatar.entry.js +2 -2
- package/dist/esm/q2-avatar.entry.js.map +1 -1
- package/dist/esm/q2-badge_7.entry.js +56 -55
- package/dist/esm/q2-badge_7.entry.js.map +1 -1
- package/dist/esm/q2-calendar.entry.js +3 -3
- package/dist/esm/q2-card.entry.js +1 -1
- package/dist/esm/q2-carousel-pane.entry.js +3 -3
- package/dist/esm/q2-carousel.entry.js +2 -2
- package/dist/esm/q2-chart-area.entry.js +2 -2
- package/dist/esm/q2-chart-bar.entry.js +2 -2
- package/dist/esm/q2-chart-donut.entry.js +2 -2
- package/dist/esm/q2-checkbox-group.entry.js +2 -2
- package/dist/esm/q2-checkbox.entry.js +3 -3
- package/dist/esm/q2-checkbox.entry.js.map +1 -1
- package/dist/esm/q2-currency.entry.js +2 -2
- package/dist/esm/q2-currency.entry.js.map +1 -1
- package/dist/esm/q2-data-table.entry.js +3 -3
- package/dist/esm/q2-data-table.entry.js.map +1 -1
- package/dist/esm/q2-detail.entry.js +2 -2
- package/dist/esm/q2-dropdown-item.entry.js +1 -1
- package/dist/esm/q2-dropdown.entry.js +2 -2
- package/dist/esm/q2-editable-field.entry.js +2 -2
- package/dist/esm/q2-example.entry.js +1 -1
- package/dist/esm/q2-file-picker.entry.js +20 -7
- package/dist/esm/q2-file-picker.entry.js.map +1 -1
- package/dist/esm/q2-form.entry.js +1 -1
- package/dist/esm/q2-formatted-text.entry.js +1 -1
- package/dist/esm/q2-grid-area.entry.js +129 -0
- package/dist/esm/q2-grid-area.entry.js.map +1 -0
- package/dist/esm/q2-grid.entry.js +105 -0
- package/dist/esm/q2-grid.entry.js.map +1 -0
- package/dist/esm/q2-item_3.entry.js +4 -4
- package/dist/esm/q2-item_3.entry.js.map +1 -1
- package/dist/esm/q2-legend.entry.js +1 -1
- package/dist/esm/q2-loc.entry.js +1 -1
- package/dist/esm/q2-message.entry.js +2 -2
- package/dist/esm/q2-modal.entry.js +2 -2
- package/dist/esm/q2-month-picker.entry.js +3 -3
- package/dist/esm/q2-optgroup.entry.js +2 -2
- package/dist/esm/q2-option-list_2.entry.js +18 -6
- package/dist/esm/q2-option-list_2.entry.js.map +1 -1
- package/dist/esm/q2-option.entry.js +1 -1
- package/dist/esm/q2-pagination.entry.js +4 -4
- package/dist/esm/q2-pill.entry.js +2 -2
- package/dist/esm/q2-radio-group.entry.js +2 -2
- package/dist/esm/q2-radio.entry.js +2 -2
- package/dist/esm/q2-relative-time.entry.js +3 -3
- package/dist/esm/q2-resize-observer.entry.js +1 -1
- package/dist/esm/q2-section.entry.js +3 -3
- package/dist/esm/q2-select.entry.js +3 -3
- package/dist/esm/q2-stepper-pane.entry.js +2 -2
- package/dist/esm/q2-stepper-vertical.entry.js +2 -2
- package/dist/esm/q2-stepper.entry.js +2 -2
- package/dist/esm/q2-tag.entry.js +2 -2
- package/dist/esm/q2-tecton-elements.js +1 -1
- package/dist/esm/q2-textarea.entry.js +2 -2
- package/dist/esm/q2-tooltip.entry.js +1 -1
- package/dist/esm/tecton-tab-pane.entry.js +2 -2
- package/dist/q2-tecton-elements/assets/brand.symbol.svg +1 -1
- package/dist/q2-tecton-elements/assets/browsersos.symbol.svg +1 -0
- package/dist/q2-tecton-elements/assets/cards.symbol.svg +1 -1
- package/dist/q2-tecton-elements/assets/{system.symbol.svg → devices.symbol.svg} +1 -1
- package/dist/q2-tecton-elements/assets/icon-file-list.json +1 -1
- package/dist/q2-tecton-elements/assets/icon-map.json +1 -1
- package/dist/q2-tecton-elements/assets/legacy.symbol.svg +1 -1
- package/dist/q2-tecton-elements/assets/mobile.symbol.svg +1 -1
- package/dist/q2-tecton-elements/{index-3bb7a785.js → index-3184c760.js} +1 -1
- package/dist/q2-tecton-elements/{index-f2a66217.js → index-c215e8ef.js} +6 -2
- package/dist/q2-tecton-elements/index-c215e8ef.js.map +1 -0
- package/dist/q2-tecton-elements/q2-action-group.entry.js +4 -4
- package/dist/q2-tecton-elements/q2-action-sheet.entry.js +63 -63
- package/dist/q2-tecton-elements/q2-avatar.entry.js +7 -7
- package/dist/q2-tecton-elements/q2-avatar.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-badge_7.entry.js +70 -68
- package/dist/q2-tecton-elements/q2-badge_7.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-calendar.entry.js +4 -4
- package/dist/q2-tecton-elements/q2-card.entry.js +1 -1
- package/dist/q2-tecton-elements/q2-carousel-pane.entry.js +4 -4
- package/dist/q2-tecton-elements/q2-carousel.entry.js +2 -2
- package/dist/q2-tecton-elements/q2-chart-area.entry.js +3 -3
- package/dist/q2-tecton-elements/q2-chart-bar.entry.js +3 -3
- package/dist/q2-tecton-elements/q2-chart-donut.entry.js +7 -7
- package/dist/q2-tecton-elements/q2-checkbox-group.entry.js +7 -7
- package/dist/q2-tecton-elements/q2-checkbox.entry.js +12 -12
- package/dist/q2-tecton-elements/q2-checkbox.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-currency.entry.js +7 -7
- package/dist/q2-tecton-elements/q2-currency.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-data-table.entry.js +5 -5
- package/dist/q2-tecton-elements/q2-data-table.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-detail.entry.js +4 -4
- package/dist/q2-tecton-elements/q2-dropdown-item.entry.js +1 -1
- package/dist/q2-tecton-elements/q2-dropdown.entry.js +6 -6
- package/dist/q2-tecton-elements/q2-editable-field.entry.js +2 -2
- package/dist/q2-tecton-elements/q2-example.entry.js +1 -1
- package/dist/q2-tecton-elements/q2-file-picker.entry.js +31 -20
- package/dist/q2-tecton-elements/q2-file-picker.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-form.entry.js +2 -2
- package/dist/q2-tecton-elements/q2-formatted-text.entry.js +2 -2
- package/dist/q2-tecton-elements/q2-grid-area.entry.js +135 -0
- package/dist/q2-tecton-elements/q2-grid-area.entry.js.map +1 -0
- package/dist/q2-tecton-elements/q2-grid.entry.js +114 -0
- package/dist/q2-tecton-elements/q2-grid.entry.js.map +1 -0
- package/dist/q2-tecton-elements/q2-item_3.entry.js +23 -23
- package/dist/q2-tecton-elements/q2-item_3.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-legend.entry.js +5 -5
- package/dist/q2-tecton-elements/q2-loc.entry.js +1 -1
- package/dist/q2-tecton-elements/q2-message.entry.js +6 -6
- package/dist/q2-tecton-elements/q2-modal.entry.js +18 -18
- package/dist/q2-tecton-elements/q2-month-picker.entry.js +14 -14
- package/dist/q2-tecton-elements/q2-optgroup.entry.js +5 -5
- package/dist/q2-tecton-elements/q2-option-list_2.entry.js +41 -31
- package/dist/q2-tecton-elements/q2-option-list_2.entry.js.map +1 -1
- package/dist/q2-tecton-elements/q2-option.entry.js +1 -1
- package/dist/q2-tecton-elements/q2-pagination.entry.js +38 -38
- package/dist/q2-tecton-elements/q2-pill.entry.js +14 -14
- package/dist/q2-tecton-elements/q2-radio-group.entry.js +12 -12
- package/dist/q2-tecton-elements/q2-radio.entry.js +9 -9
- package/dist/q2-tecton-elements/q2-relative-time.entry.js +3 -3
- package/dist/q2-tecton-elements/q2-resize-observer.entry.js +1 -1
- package/dist/q2-tecton-elements/q2-section.entry.js +19 -19
- package/dist/q2-tecton-elements/q2-select.entry.js +6 -6
- package/dist/q2-tecton-elements/q2-stepper-pane.entry.js +14 -14
- package/dist/q2-tecton-elements/q2-stepper-vertical.entry.js +37 -37
- package/dist/q2-tecton-elements/q2-stepper.entry.js +29 -29
- package/dist/q2-tecton-elements/q2-tag.entry.js +6 -6
- package/dist/q2-tecton-elements/q2-tecton-elements.esm.js +1 -1
- package/dist/q2-tecton-elements/q2-tecton-elements.esm.js.map +1 -1
- package/dist/q2-tecton-elements/q2-textarea.entry.js +3 -3
- package/dist/q2-tecton-elements/q2-tooltip.entry.js +1 -1
- package/dist/q2-tecton-elements/tecton-tab-pane.entry.js +6 -6
- package/dist/types/components/q2-action-group/q2-action-group.d.ts +1 -0
- package/dist/types/components/q2-action-sheet/q2-action-sheet.d.ts +60 -0
- package/dist/types/components/q2-calendar/q2-calendar.d.ts +327 -0
- package/dist/types/components/q2-carousel/q2-carousel.d.ts +95 -0
- package/dist/types/components/q2-data-table/q2-data-table.d.ts +261 -0
- package/dist/types/components/q2-dropdown/q2-dropdown.d.ts +181 -0
- package/dist/types/components/q2-editable-field/q2-editable-field.d.ts +140 -0
- package/dist/types/components/q2-file-picker/q2-file-picker.d.ts +31 -17
- package/dist/types/components/q2-grid/q2-grid.d.ts +157 -0
- package/dist/types/components/q2-grid-area/q2-grid-area.d.ts +168 -0
- package/dist/types/components/q2-icon/q2-icon.d.ts +1 -0
- package/dist/types/components/q2-loading/skeleton/shapes.d.ts +1 -0
- package/dist/types/components/q2-optgroup/q2-optgroup.d.ts +1 -1
- package/dist/types/components/q2-option-list/q2-option-list.d.ts +100 -0
- package/dist/types/components/q2-pagination/q2-pagination.d.ts +117 -0
- package/dist/types/components/q2-pill/q2-pill.d.ts +143 -0
- package/dist/types/components/q2-popover/q2-popover.d.ts +23 -0
- package/dist/types/components/q2-select/q2-select.d.ts +238 -0
- package/dist/types/components/q2-stepper/q2-stepper.d.ts +61 -0
- package/dist/types/components/q2-stepper-vertical/q2-stepper-vertical.d.ts +68 -0
- package/dist/types/components/q2-tab-container/q2-tab-container.d.ts +2 -2
- package/dist/types/components/q2-tag/q2-tag.d.ts +91 -0
- package/dist/types/components.d.ts +698 -6
- package/dist/types/util.d.ts +2 -2
- package/dist/types/utils/action-sheet.d.ts +12 -0
- package/dist/types/utils/helpers.d.ts +1 -0
- package/dist/types/utils/index.d.ts +1 -0
- package/package.json +4 -3
- package/dist/cjs/index-905f4c87.js.map +0 -1
- package/dist/esm/index-f2a66217.js.map +0 -1
- package/dist/q2-tecton-elements/index-f2a66217.js.map +0 -1
- /package/dist/q2-tecton-elements/{index-3bb7a785.js.map → index-3184c760.js.map} +0 -0
- /package/dist/types/{Users/kvanhouten/Documents/Work/tecton_extra → builds/q2e/development/tecton/tecton}/packages/q2-tecton-elements/.stencil/jest.setup.d.ts +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { r as t, c as
|
|
1
|
+
import { r as t, c as e, h as i, F as o, g as a } from "./index-7a5365e2.js";
|
|
2
2
|
|
|
3
|
-
import { l as s, w as r } from "./index-
|
|
3
|
+
import { l as s, w as r } from "./index-c215e8ef.js";
|
|
4
4
|
|
|
5
5
|
import { s as n } from "./sanitize-html-string-735c19f5.js";
|
|
6
6
|
|
|
@@ -8,20 +8,20 @@ const c = '*{box-sizing:border-box}*:active{outline:none}*:focus{outline:none;bo
|
|
|
8
8
|
|
|
9
9
|
const d = c;
|
|
10
10
|
|
|
11
|
-
var l = undefined && undefined.__rest || function(t,
|
|
12
|
-
var
|
|
13
|
-
for (var o in t) if (Object.prototype.hasOwnProperty.call(t, o) &&
|
|
11
|
+
var l = undefined && undefined.__rest || function(t, e) {
|
|
12
|
+
var i = {};
|
|
13
|
+
for (var o in t) if (Object.prototype.hasOwnProperty.call(t, o) && e.indexOf(o) < 0) i[o] = t[o];
|
|
14
14
|
if (t != null && typeof Object.getOwnPropertySymbols === "function") for (var a = 0, o = Object.getOwnPropertySymbols(t); a < o.length; a++) {
|
|
15
|
-
if (
|
|
15
|
+
if (e.indexOf(o[a]) < 0 && Object.prototype.propertyIsEnumerable.call(t, o[a])) i[o[a]] = t[o[a]];
|
|
16
16
|
}
|
|
17
|
-
return
|
|
17
|
+
return i;
|
|
18
18
|
};
|
|
19
19
|
|
|
20
20
|
const h = class {
|
|
21
21
|
constructor(a) {
|
|
22
22
|
t(this, a);
|
|
23
|
-
this.close =
|
|
24
|
-
this.ready =
|
|
23
|
+
this.close = e(this, "close", 7);
|
|
24
|
+
this.ready = e(this, "ready", 3);
|
|
25
25
|
this.initialSelectedOptions = [];
|
|
26
26
|
this.maxHeight = .75;
|
|
27
27
|
this.minHeight = .2;
|
|
@@ -30,41 +30,41 @@ const h = class {
|
|
|
30
30
|
value: ""
|
|
31
31
|
};
|
|
32
32
|
this.generateOptgroup = t => {
|
|
33
|
-
const
|
|
34
|
-
if (t.label)
|
|
35
|
-
if (t.disabled)
|
|
36
|
-
if (!!t.options.length) t.options.forEach((t =>
|
|
37
|
-
return
|
|
33
|
+
const e = document.createElement("q2-optgroup");
|
|
34
|
+
if (t.label) e.setAttribute("label", t.label);
|
|
35
|
+
if (t.disabled) e.setAttribute("disabled", "");
|
|
36
|
+
if (!!t.options.length) t.options.forEach((t => e.appendChild(this.generateOption(t))));
|
|
37
|
+
return e;
|
|
38
38
|
};
|
|
39
39
|
this.generateOption = t => {
|
|
40
|
-
const
|
|
41
|
-
const {innerHTML:
|
|
42
|
-
if (
|
|
43
|
-
Object.entries(o).forEach((([t,
|
|
44
|
-
if (
|
|
45
|
-
if (typeof
|
|
46
|
-
if (
|
|
40
|
+
const e = document.createElement("q2-option");
|
|
41
|
+
const {innerHTML: i} = t, o = l(t, [ "innerHTML" ]);
|
|
42
|
+
if (i) e.innerHTML = n(i);
|
|
43
|
+
Object.entries(o).forEach((([t, i]) => {
|
|
44
|
+
if (i === undefined) return;
|
|
45
|
+
if (typeof i === "boolean") {
|
|
46
|
+
if (i) e.setAttribute(t, "");
|
|
47
47
|
} else {
|
|
48
|
-
|
|
48
|
+
e.setAttribute(t, i);
|
|
49
49
|
}
|
|
50
50
|
}));
|
|
51
|
-
return
|
|
51
|
+
return e;
|
|
52
52
|
};
|
|
53
53
|
this.onCancel = t => {
|
|
54
|
-
var
|
|
54
|
+
var e, i;
|
|
55
55
|
t.preventDefault();
|
|
56
56
|
const {initialSelectedOptions: o} = this;
|
|
57
57
|
this.hide({
|
|
58
|
-
value: (
|
|
58
|
+
value: (i = (e = o === null || o === void 0 ? void 0 : o[0]) === null || e === void 0 ? void 0 : e.value) !== null && i !== void 0 ? i : "",
|
|
59
59
|
values: o,
|
|
60
60
|
type: "cancel"
|
|
61
61
|
});
|
|
62
62
|
};
|
|
63
63
|
this.onClick = t => {
|
|
64
|
-
const
|
|
65
|
-
if (!(
|
|
66
|
-
const
|
|
67
|
-
if (
|
|
64
|
+
const e = t.target;
|
|
65
|
+
if (!(e instanceof HTMLElement)) return;
|
|
66
|
+
const i = !!e.closest(".interior, q2-action-sheet");
|
|
67
|
+
if (i) return;
|
|
68
68
|
this.onCancel(t);
|
|
69
69
|
};
|
|
70
70
|
this.onListChange = t => {
|
|
@@ -86,30 +86,30 @@ const h = class {
|
|
|
86
86
|
// #endregion
|
|
87
87
|
// #region Render Methods
|
|
88
88
|
this.renderList = ({data: t}) => {
|
|
89
|
-
const {listProps:
|
|
90
|
-
return
|
|
89
|
+
const {listProps: e} = t;
|
|
90
|
+
return i(o, null, i("div", {
|
|
91
91
|
class: "content",
|
|
92
92
|
ref: t => this.contentElement = t
|
|
93
|
-
},
|
|
93
|
+
}, i("q2-option-list", {
|
|
94
94
|
ref: t => this.optionListElement = t,
|
|
95
|
-
multiple:
|
|
96
|
-
noSelect:
|
|
95
|
+
multiple: e.multiple,
|
|
96
|
+
noSelect: e.noSelect,
|
|
97
97
|
onChange: this.onListChange,
|
|
98
98
|
onPopoverState: this.onListPopoverStateChange,
|
|
99
|
-
selectedOptions:
|
|
100
|
-
},
|
|
99
|
+
selectedOptions: e.selectedOptions
|
|
100
|
+
}, i("slot", null))), i("footer", null, e.multiple && i("q2-btn", {
|
|
101
101
|
"test-id": "btnDone",
|
|
102
102
|
intent: "workflow-primary",
|
|
103
103
|
onClick: this.onListDone
|
|
104
104
|
}, s("tecton.element.actionSheet.done"))));
|
|
105
105
|
};
|
|
106
|
-
this.renderMessage = ({data: t}) =>
|
|
106
|
+
this.renderMessage = ({data: t}) => i("q2-message", {
|
|
107
107
|
type: t.type
|
|
108
|
-
}, t.title &&
|
|
109
|
-
this.renderSlot = () =>
|
|
108
|
+
}, t.title && i("h2", null, t.title), t.description && i("p", null, t.description));
|
|
109
|
+
this.renderSlot = () => i("div", {
|
|
110
110
|
class: "content",
|
|
111
111
|
ref: t => this.contentElement = t
|
|
112
|
-
},
|
|
112
|
+
}, i("slot", null));
|
|
113
113
|
this.isScrollable = false;
|
|
114
114
|
this.renderStatus = "is-closing";
|
|
115
115
|
this.data = undefined;
|
|
@@ -171,9 +171,9 @@ const h = class {
|
|
|
171
171
|
const {data: t} = this;
|
|
172
172
|
if (!t) return;
|
|
173
173
|
if (t.appearance === "list") {
|
|
174
|
-
const {event:
|
|
175
|
-
if (
|
|
176
|
-
this.optionListElement.handleExternalKeydown(
|
|
174
|
+
const {event: e} = t;
|
|
175
|
+
if (e instanceof KeyboardEvent) {
|
|
176
|
+
this.optionListElement.handleExternalKeydown(e);
|
|
177
177
|
} else {
|
|
178
178
|
this.optionListElement.focus();
|
|
179
179
|
}
|
|
@@ -210,11 +210,11 @@ const h = class {
|
|
|
210
210
|
}
|
|
211
211
|
render() {
|
|
212
212
|
var t;
|
|
213
|
-
const {data:
|
|
214
|
-
const o = (
|
|
213
|
+
const {data: e} = this;
|
|
214
|
+
const o = (e === null || e === void 0 ? void 0 : e.title) || this.title || !this.hideClose;
|
|
215
215
|
const a = this.renderStatus || "";
|
|
216
216
|
let s = null;
|
|
217
|
-
switch (
|
|
217
|
+
switch (e === null || e === void 0 ? void 0 : e.appearance) {
|
|
218
218
|
case "message":
|
|
219
219
|
s = this.renderMessage;
|
|
220
220
|
break;
|
|
@@ -227,35 +227,35 @@ const h = class {
|
|
|
227
227
|
s = this.renderSlot;
|
|
228
228
|
break;
|
|
229
229
|
}
|
|
230
|
-
const r = (
|
|
230
|
+
const r = (e === null || e === void 0 ? void 0 : e.appearance) || "slot";
|
|
231
231
|
const n = `interior is-${r}`;
|
|
232
|
-
return
|
|
233
|
-
key: "
|
|
232
|
+
return i("dialog", {
|
|
233
|
+
key: "556d963140d0cd87822dcd9b2fae4739793f56c3",
|
|
234
234
|
ref: t => this.dialogElement = t,
|
|
235
235
|
class: a,
|
|
236
236
|
onClick: this.onClick
|
|
237
|
-
},
|
|
238
|
-
key: "
|
|
237
|
+
}, i("div", {
|
|
238
|
+
key: "d8061060c384136cb2941aa2e4d9628866946127",
|
|
239
239
|
class: n
|
|
240
|
-
}, o &&
|
|
241
|
-
key: "
|
|
242
|
-
},
|
|
243
|
-
key: "
|
|
240
|
+
}, o && i("header", {
|
|
241
|
+
key: "cbd3bd7664b4e4b5b2facb7716174210e3e0ccfe"
|
|
242
|
+
}, i("div", {
|
|
243
|
+
key: "4f506806a80c41f84f5e0d3a0056523d3784c7d4",
|
|
244
244
|
class: "title"
|
|
245
|
-
}, (
|
|
246
|
-
key: "
|
|
245
|
+
}, (e === null || e === void 0 ? void 0 : e.title) || this.title), !this.hideClose && i("q2-btn", {
|
|
246
|
+
key: "600f883b6809db14d53fede67e238d40c28a89d8",
|
|
247
247
|
class: "btn-close",
|
|
248
248
|
"test-id": "btnClose",
|
|
249
249
|
onClick: this.onCancel,
|
|
250
250
|
label: "tecton.element.actionSheet.close",
|
|
251
251
|
"hide-label": true
|
|
252
|
-
},
|
|
253
|
-
key: "
|
|
252
|
+
}, i("q2-icon", {
|
|
253
|
+
key: "1f80214fa5e66d1e031be2727a197f9137d3dfa3",
|
|
254
254
|
type: "close"
|
|
255
|
-
}))), ((t = this.data) === null || t === void 0 ? void 0 : t.description) &&
|
|
256
|
-
key: "
|
|
257
|
-
},
|
|
258
|
-
key: "
|
|
255
|
+
}))), ((t = this.data) === null || t === void 0 ? void 0 : t.description) && i("p", {
|
|
256
|
+
key: "1fbd683272184f40afe07eddcf146b4533d356a3"
|
|
257
|
+
}, e.description), s && i(s, {
|
|
258
|
+
key: "3cdf691ca2aa46de25ccde884f9b51542bd3e6df",
|
|
259
259
|
data: this.data
|
|
260
260
|
})));
|
|
261
261
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { r as a, h as t, g as r } from "./index-7a5365e2.js";
|
|
2
2
|
|
|
3
|
-
const i = "*{box-sizing:border-box}*:active{outline:none}*:focus{outline:none;box-shadow:var(--const-double-focus-ring, 0 0 0 2px #ffffff, 0 0 0 4px #0066cc)}:host{box-shadow:none !important}::-moz-focus-inner{border:none}input,textarea,button{font-family:inherit;font-size:inherit;font-stretch:inherit}:host(.sr),:host(.sr) button{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap}.sr,.sr button{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap}.hidden{display:none}:host([hidden]){display:none}.invisible{visibility:hidden}.avatar-img,.avatar-img-default{display:var(--tct-avatar-display,
|
|
3
|
+
const i = "*{box-sizing:border-box}*:active{outline:none}*:focus{outline:none;box-shadow:var(--const-double-focus-ring, 0 0 0 2px #ffffff, 0 0 0 4px #0066cc)}:host{box-shadow:none !important}::-moz-focus-inner{border:none}input,textarea,button{font-family:inherit;font-size:inherit;font-stretch:inherit}:host(.sr),:host(.sr) button{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap}.sr,.sr button{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap}.hidden{display:none}:host([hidden]){display:none}.invisible{visibility:hidden}.avatar-img,.avatar-img-default{display:var(--tct-avatar-display, block);object-fit:cover;height:var(--tct-avatar-img-height, var(--tct-avatar-height, 44px));width:var(--tct-avatar-img-width, var(--tct-avatar-width, 44px));border-radius:var(--tct-avatar-img-border-radius, var(--tct-avatar-img-br, var(--tct-avatar-border-radius, 50%)));border:var(--tct-avatar-border, none)}.avatar-img-default{background:var(--tct-avatar-background, var(--tct-avatar-bg, #9e9e9e))}.avatar-initials{display:var(--tct-avatar-display, block);height:var(--tct-avatar-height, 44px);width:var(--tct-avatar-width, 44px);background:var(--tct-avatar-background, var(--tct-avatar-bg, var(--t-gray-8, #9e9e9e)));border-radius:var(--tct-avatar-br, 50%);border:var(--tct-avatar-border, none)}.size-1{--tct-avatar-font-size:var(--tct-avatar-size-1, 60px)}.size-2{--tct-avatar-font-size:var(--tct-avatar-size-2, 48px)}.size-3{--tct-avatar-font-size:var(--tct-avatar-size-3, 40px)}.size-4{--tct-avatar-font-size:var(--tct-avatar-size-4, 30px)}text{fill:var(--tct-avatar-text-color, var(--tct-avatar-color, #ffffff));font-weight:var(--tct-avatar-font-weight, 200);font-size:var(--tct-avatar-font-size, 40px)}.fallback{height:var(--tct-avatar-fallback-height, var(--tct-avatar-height, 44px));width:var(--tct-avatar-fallback-width, var(--tct-avatar-width, 44px));border-radius:var(--tct-avatar-fallback-border-radius, var(--tct-avatar-fallback-br, var(--tct-avatar-img-border-radius, var(--tct-avatar-img-br, 50%))));border:var(--tct-avatar-border, none);background:var(--tct-avatar-fallback-background, var(--tct-avatar-fallback-bg, var(--tct-avatar-background, var(--tct-avatar-bg, var(--t-gray-8, #9e9e9e)))));display:flex;align-items:center;justify-content:center}q2-icon{--tct-icon-size:var(--tct-avatar-icon-size, var(--tct-avatar-fallback-icon-size, 65%));--tct-icon-stroke-primary:var(--tct-avatar-icon-stroke-primary, var(--tct-avatar-fallback-stroke-primary, currentcolor));--tct-icon-stroke-secondary:var(--tct-avatar-icon-stroke-secondary, var(--tct-avatar-fallback-stroke-secondary, currentcolor));--tct-icon-fill:var(--tct-avatar-icon-fill, var(--tct-avatar-fallback-fill));color:var(--tct-avatar-icon-color, var(--tct-avatar-fallback-color, var(--tct-avatar-color, var(--t-base, #ffffff))));width:var(--tct-avatar-icon-size, var(--tct-icon-size));height:var(--tct-avatar-icon-size, var(--tct-icon-size))}";
|
|
4
4
|
|
|
5
5
|
const e = i;
|
|
6
6
|
|
|
@@ -52,9 +52,9 @@ const c = class {
|
|
|
52
52
|
const e = (this.name || this.initials) && (!this.src || this.badSrc);
|
|
53
53
|
const c = !this.name && !this.initials && (!this.src || this.badSrc);
|
|
54
54
|
return t("div", {
|
|
55
|
-
key: "
|
|
55
|
+
key: "d9721ec70f2f1162159d401c3d6e25bc7d757387"
|
|
56
56
|
}, r && t("img", {
|
|
57
|
-
key: "
|
|
57
|
+
key: "4453493c5432082368a77764dfb9851571a70237",
|
|
58
58
|
class: i ? "avatar-img" : "avatar-img-default",
|
|
59
59
|
"test-id": "userImage",
|
|
60
60
|
src: this.src,
|
|
@@ -62,7 +62,7 @@ const c = class {
|
|
|
62
62
|
onLoad: this.onLoad,
|
|
63
63
|
alt: this.name || ""
|
|
64
64
|
}), e && t("svg", {
|
|
65
|
-
key: "
|
|
65
|
+
key: "10303ff815e3839035e0f1ab466b9999c3c1ad95",
|
|
66
66
|
viewBox: "0 0 100 100",
|
|
67
67
|
preserveAspectRatio: "xMidYMid meet",
|
|
68
68
|
"test-id": "userInitials",
|
|
@@ -70,18 +70,18 @@ const c = class {
|
|
|
70
70
|
"aria-label": this.name,
|
|
71
71
|
"aria-hidden": !this.name && "true"
|
|
72
72
|
}, t("text", {
|
|
73
|
-
key: "
|
|
73
|
+
key: "9fa420ccf432f2ccf5d2e99555489ac5fbc28358",
|
|
74
74
|
x: "50",
|
|
75
75
|
y: "50",
|
|
76
76
|
"dominant-baseline": "central",
|
|
77
77
|
"text-anchor": "middle",
|
|
78
78
|
"aria-hidden": "true"
|
|
79
79
|
}, a)), c && t("div", {
|
|
80
|
-
key: "
|
|
80
|
+
key: "20da7ea3494eb9a403b0a7c5d038c097003c15e1",
|
|
81
81
|
"test-id": "fallbackIcon",
|
|
82
82
|
class: "fallback"
|
|
83
83
|
}, t("q2-icon", {
|
|
84
|
-
key: "
|
|
84
|
+
key: "a7b493de65050f601d395e183dcec0ff4382011a",
|
|
85
85
|
type: this.icon
|
|
86
86
|
})));
|
|
87
87
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["q2AvatarCss","Q2AvatarStyle0","Q2Avatar","this","onError","badSrc","onLoad","isLoaded","srcDidUpdate","computedInitials","initials","name","result","substr","parts","split","firstCharacter","lastCharacter","length","undefined","toUpperCase","render","showImg","src","showInitials","showFallback","h","key","class","alt","viewBox","preserveAspectRatio","x","y","type","icon"],"sources":["src/components/q2-avatar/q2-avatar.scss?tag=q2-avatar&encapsulation=shadow","src/components/q2-avatar/q2-avatar.tsx"],"sourcesContent":["@import '../../styles/host.scss';\n@import '../../styles/functions';\n\n.avatar-img,\n.avatar-img-default {\n display: var(--tct-avatar-display,
|
|
1
|
+
{"version":3,"names":["q2AvatarCss","Q2AvatarStyle0","Q2Avatar","this","onError","badSrc","onLoad","isLoaded","srcDidUpdate","computedInitials","initials","name","result","substr","parts","split","firstCharacter","lastCharacter","length","undefined","toUpperCase","render","showImg","src","showInitials","showFallback","h","key","class","alt","viewBox","preserveAspectRatio","x","y","type","icon"],"sources":["src/components/q2-avatar/q2-avatar.scss?tag=q2-avatar&encapsulation=shadow","src/components/q2-avatar/q2-avatar.tsx"],"sourcesContent":["@import '../../styles/host.scss';\n@import '../../styles/functions';\n\n.avatar-img,\n.avatar-img-default {\n display: var(--tct-avatar-display, block);\n object-fit: cover;\n height: var-list(--tct-avatar-img-height, --tct-avatar-height, 44px);\n width: var-list(--tct-avatar-img-width, --tct-avatar-width, 44px);\n border-radius: var-list(--tct-avatar-img-border-radius, --tct-avatar-img-br, --tct-avatar-border-radius, 50%);\n border: var(--tct-avatar-border, none);\n}\n\n.avatar-img-default {\n background: var-list(--tct-avatar-background, --tct-avatar-bg, #9e9e9e);\n}\n\n.avatar-initials {\n display: var(--tct-avatar-display, block);\n height: var(--tct-avatar-height, 44px);\n width: var(--tct-avatar-width, 44px);\n background: var-list(--tct-avatar-background, --tct-avatar-bg, --t-gray-8, #9e9e9e);\n border-radius: var(--tct-avatar-br, 50%);\n border: var(--tct-avatar-border, none);\n}\n\n.size-1 {\n --tct-avatar-font-size: var(--tct-avatar-size-1, 60px);\n}\n.size-2 {\n --tct-avatar-font-size: var(--tct-avatar-size-2, 48px);\n}\n.size-3 {\n --tct-avatar-font-size: var(--tct-avatar-size-3, 40px);\n}\n.size-4 {\n --tct-avatar-font-size: var(--tct-avatar-size-4, 30px);\n}\n\ntext {\n fill: var-list(--tct-avatar-text-color, --tct-avatar-color, #ffffff);\n font-weight: var(--tct-avatar-font-weight, 200);\n font-size: var(--tct-avatar-font-size, 40px);\n}\n\n.fallback {\n height: var-list(--tct-avatar-fallback-height, --tct-avatar-height, 44px);\n width: var-list(--tct-avatar-fallback-width, --tct-avatar-width, 44px);\n border-radius: var-list(\n --tct-avatar-fallback-border-radius,\n --tct-avatar-fallback-br,\n --tct-avatar-img-border-radius,\n --tct-avatar-img-br,\n 50%\n );\n border: var(--tct-avatar-border, none);\n background: var-list(\n --tct-avatar-fallback-background,\n --tct-avatar-fallback-bg,\n --tct-avatar-background,\n --tct-avatar-bg,\n --t-gray-8,\n #9e9e9e\n );\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\nq2-icon {\n --tct-icon-size: #{var-list(--tct-avatar-icon-size, --tct-avatar-fallback-icon-size, 65%)};\n --tct-icon-stroke-primary: #{var-list(\n --tct-avatar-icon-stroke-primary,\n --tct-avatar-fallback-stroke-primary,\n currentcolor\n )};\n --tct-icon-stroke-secondary: #{var-list(\n --tct-avatar-icon-stroke-secondary,\n --tct-avatar-fallback-stroke-secondary,\n currentcolor\n )};\n --tct-icon-fill: #{var-list(--tct-avatar-icon-fill, --tct-avatar-fallback-fill)};\n color: var-list(--tct-avatar-icon-color, --tct-avatar-fallback-color, --tct-avatar-color, --t-base, #ffffff);\n width: var-list(--tct-avatar-icon-size, --tct-icon-size);\n height: var-list(--tct-avatar-icon-size, --tct-icon-size);\n}\n","import { Component, ComponentInterface, Prop, Element, h, State, Watch } from '@stencil/core';\n\n@Component({ tag: 'q2-avatar', shadow: true, styleUrl: 'q2-avatar.scss' })\nexport class Q2Avatar implements ComponentInterface {\n // #region Host HTML Element\n\n @Element()\n el: HTMLElement;\n\n // #endregion\n // #region State Properties\n\n @State()\n badSrc: boolean = false;\n\n @State()\n isLoaded: boolean = false;\n\n // #endregion\n // #region Public Property API\n\n /** A [q2-icon](https://tecton.q2developer.com/design-system/q2-icon/) to display as the fallback. */\n @Prop()\n icon: string = 'person';\n\n /** A set of up to four initials to display as capitalized text. Takes priority over `name`. */\n @Prop({ reflect: true })\n initials: string;\n\n /**\n * The name associated with the avatar.\n * The initials of the first and last words provided will display as capital letters.\n *\n * @info\n * We recommend always providing a name when you want the avatar to be presented to screen readers.\n */\n @Prop({ reflect: true })\n name: string;\n\n /** Displays the image provided by the user. */\n @Prop({ reflect: true })\n src: string;\n\n // #endregion\n // #region Watchers\n\n @Watch('src')\n srcDidUpdate() {\n this.badSrc = false;\n }\n\n // #endregion\n // #region Local Methods\n\n get computedInitials() {\n const { initials, name } = this;\n if (!initials && !name) return;\n\n let result = '';\n if (initials) {\n result = initials.substr(0, 4);\n } else if (name) {\n const parts = name.split(' ');\n const firstCharacter = parts[0][0];\n const lastCharacter = parts.length > 1 ? parts[parts.length - 1][0] : undefined;\n result += firstCharacter;\n if (lastCharacter) result += lastCharacter;\n }\n\n result = result?.toUpperCase();\n\n return result;\n }\n\n onError = () => {\n this.badSrc = true;\n };\n\n onLoad = () => {\n this.isLoaded = true;\n };\n\n // #endregion\n // #region Render Methods\n\n render() {\n const { computedInitials } = this;\n const showImg = this.src && !this.badSrc;\n const isLoaded = this.isLoaded;\n const showInitials = (this.name || this.initials) && (!this.src || this.badSrc);\n const showFallback = !this.name && !this.initials && (!this.src || this.badSrc);\n\n return (\n <div>\n {showImg && (\n <img\n class={isLoaded ? 'avatar-img' : 'avatar-img-default'}\n test-id=\"userImage\"\n src={this.src}\n onError={this.onError}\n onLoad={this.onLoad}\n alt={this.name || ''}\n />\n )}\n {showInitials && (\n <svg\n viewBox=\"0 0 100 100\"\n preserveAspectRatio=\"xMidYMid meet\"\n test-id=\"userInitials\"\n class={`avatar-initials size-${computedInitials.length}`}\n aria-label={this.name}\n aria-hidden={!this.name && 'true'}\n >\n <text\n x=\"50\"\n y=\"50\"\n dominant-baseline=\"central\"\n text-anchor=\"middle\"\n aria-hidden=\"true\"\n >\n {computedInitials}\n </text>\n </svg>\n )}\n {showFallback && (\n <div\n test-id=\"fallbackIcon\"\n class=\"fallback\"\n >\n <q2-icon type={this.icon}></q2-icon>\n </div>\n )}\n </div>\n );\n }\n\n // #endregion\n}\n"],"mappings":";;AAAA,MAAMA,IAAc;;AACpB,MAAAC,IAAeD;;MCEFE,IAAQ;;;IAuEjBC,KAAAC,UAAU;MACND,KAAKE,SAAS;AAAI;IAGtBF,KAAAG,SAAS;MACLH,KAAKI,WAAW;AAAI;kBAlEN;oBAGE;gBAOL;;;;;;;EAwBf,YAAAC;IACIL,KAAKE,SAAS;;;;EAMlB,oBAAII;IACA,OAAMC,UAAEA,GAAQC,MAAEA,KAASR;IAC3B,KAAKO,MAAaC,GAAM;IAExB,IAAIC,IAAS;IACb,IAAIF,GAAU;MACVE,IAASF,EAASG,OAAO,GAAG;WACzB,IAAIF,GAAM;MACb,MAAMG,IAAQH,EAAKI,MAAM;MACzB,MAAMC,IAAiBF,EAAM,GAAG;MAChC,MAAMG,IAAgBH,EAAMI,SAAS,IAAIJ,EAAMA,EAAMI,SAAS,GAAG,KAAKC;MACtEP,KAAUI;MACV,IAAIC,GAAeL,KAAUK;;IAGjCL,IAASA,MAAM,QAANA,WAAM,aAANA,EAAQQ;IAEjB,OAAOR;;;;EAcX,MAAAS;IACI,OAAMZ,kBAAEA,KAAqBN;IAC7B,MAAMmB,IAAUnB,KAAKoB,QAAQpB,KAAKE;IAClC,MAAME,IAAWJ,KAAKI;IACtB,MAAMiB,KAAgBrB,KAAKQ,QAAQR,KAAKO,eAAeP,KAAKoB,OAAOpB,KAAKE;IACxE,MAAMoB,KAAgBtB,KAAKQ,SAASR,KAAKO,cAAcP,KAAKoB,OAAOpB,KAAKE;IAExE,OACIqB,EAAA;MAAAC,KAAA;OACKL,KACGI,EAAA;MAAAC,KAAA;MACIC,OAAOrB,IAAW,eAAe;MAAoB,WAC7C;MACRgB,KAAKpB,KAAKoB;MACVnB,SAASD,KAAKC;MACdE,QAAQH,KAAKG;MACbuB,KAAK1B,KAAKQ,QAAQ;QAGzBa,KACGE,EAAA;MAAAC,KAAA;MACIG,SAAQ;MACRC,qBAAoB;MAAe,WAC3B;MACRH,OAAO,wBAAwBnB,EAAiBS;MAAQ,cAC5Cf,KAAKQ;MAAI,gBACPR,KAAKQ,QAAQ;OAE3Be,EAAA;MAAAC,KAAA;MACIK,GAAE;MACFC,GAAE;MAAI,qBACY;MAAS,eACf;MAAQ,eACR;OAEXxB,KAIZgB,KACGC,EAAA;MAAAC,KAAA;MAAA,WACY;MACRC,OAAM;OAENF,EAAA;MAAAC,KAAA;MAASO,MAAM/B,KAAKgC"}
|