@sellmate/design-system 1.0.78 → 1.2.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/cjs/component.table-CMqGfEui.js +66 -0
- package/dist/cjs/design-system.cjs.js +2 -2
- package/dist/cjs/{index--F2wGuAi.js → index-Cw-78mnC.js} +1 -1
- package/dist/cjs/index.cjs.js +5 -5
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{resolveColor-LhfOKtTZ.js → resolveColor-B0hzQNLG.js} +2 -2
- package/dist/cjs/sd-action-modal.cjs.entry.js +3 -3
- package/dist/cjs/sd-badge.cjs.entry.js +2 -3
- package/dist/cjs/sd-barcode-input.cjs.entry.js +3 -3
- package/dist/cjs/{sd-button-v2.config-CnqCQQMi.js → sd-button.config-DH08UNfl.js} +114 -28
- package/dist/cjs/{sd-button-v2_2.cjs.entry.js → sd-button_2.cjs.entry.js} +102 -85
- package/dist/cjs/sd-calendar.cjs.entry.js +15 -15
- package/dist/cjs/sd-card.cjs.entry.js +2 -2
- package/dist/cjs/sd-checkbox.cjs.entry.js +4 -4
- package/dist/cjs/sd-chip.cjs.entry.js +4 -4
- package/dist/cjs/sd-circle-progress.cjs.entry.js +3 -3
- package/dist/cjs/sd-confirm-modal_2.cjs.entry.js +19 -11
- package/dist/cjs/sd-date-box.cjs.entry.js +9 -4
- package/dist/cjs/{sd-date-picker-calendar.cjs.entry.js → sd-date-picker-calendar_2.cjs.entry.js} +59 -6
- package/dist/cjs/{sd-date-picker.config-CRgCT5dn.js → sd-date-picker.config-CjvrFpYK.js} +1 -2
- package/dist/cjs/sd-date-picker_7.cjs.entry.js +1235 -0
- package/dist/cjs/sd-date-range-picker-calendar.cjs.entry.js +14 -14
- package/dist/cjs/sd-dropdown-button.cjs.entry.js +32 -27
- package/dist/cjs/{sd-button_4.cjs.entry.js → sd-field_3.cjs.entry.js} +47 -102
- package/dist/cjs/sd-form.cjs.entry.js +5 -5
- package/dist/cjs/sd-ghost-button.cjs.entry.js +12 -10
- package/dist/cjs/sd-guide.cjs.entry.js +11 -11
- package/dist/cjs/sd-key-value-table.cjs.entry.js +230 -0
- package/dist/cjs/sd-linear-progress.cjs.entry.js +3 -3
- package/dist/cjs/sd-loading-container.cjs.entry.js +3 -3
- package/dist/cjs/sd-modal-container.cjs.entry.js +3 -3
- package/dist/cjs/{sd-pagination_5.cjs.entry.js → sd-pagination_4.cjs.entry.js} +136 -325
- package/dist/cjs/sd-popover.cjs.entry.js +18 -11
- package/dist/cjs/sd-popup.cjs.entry.js +112 -0
- package/dist/cjs/sd-portal.cjs.entry.js +3 -3
- package/dist/cjs/sd-radio-button.cjs.entry.js +9 -6
- package/dist/cjs/sd-radio.cjs.entry.js +2 -2
- package/dist/cjs/sd-select-list-item_2.cjs.entry.js +159 -0
- package/dist/cjs/sd-select.config-B19ptCT2.js +178 -0
- package/dist/cjs/{sd-select-list-item_4.cjs.entry.js → sd-select_3.cjs.entry.js} +296 -323
- package/dist/cjs/sd-switch.cjs.entry.js +2 -2
- package/dist/cjs/sd-table.cjs.entry.js +188 -48
- package/dist/cjs/sd-table.config-BIpldZtw.js +76 -0
- package/dist/cjs/sd-tabs.cjs.entry.js +8 -3
- package/dist/cjs/sd-tag.cjs.entry.js +56 -21
- package/dist/cjs/sd-td.cjs.entry.js +52 -10
- package/dist/cjs/sd-text-link.cjs.entry.js +13 -5
- package/dist/cjs/sd-toast-container.cjs.entry.js +5 -5
- package/dist/cjs/sd-toast.cjs.entry.js +35 -5
- package/dist/cjs/sd-toggle.cjs.entry.js +2 -2
- package/dist/cjs/{system-DpTN1vBC.js → system-VmZRYp6V.js} +4 -2
- package/dist/cjs/{tooltipArrow-D1-wcNm1.js → tooltipArrow-BjSFKIUq.js} +1 -1
- package/dist/collection/collection-manifest.json +4 -3
- package/dist/collection/components/assets/CheckboxCheck.js +5 -0
- package/dist/collection/components/assets/CheckboxIndeterminate.js +5 -0
- package/dist/collection/components/assets/index.js +4 -0
- package/dist/collection/components/sd-action-modal/sd-action-modal.css +1 -1
- package/dist/collection/components/sd-action-modal/sd-action-modal.js +7 -7
- package/dist/collection/components/sd-badge/sd-badge.config.js +10 -1
- package/dist/collection/components/sd-badge/sd-badge.js +1 -22
- package/dist/collection/components/sd-barcode-input/sd-barcode-input.js +4 -4
- package/dist/collection/components/{sd-button-v2/sd-button-v2.config.js → sd-button/sd-button.config.js} +1 -1
- package/dist/collection/components/sd-button/sd-button.css +47 -93
- package/dist/collection/components/sd-button/sd-button.js +100 -173
- package/dist/collection/components/sd-calendar/sd-calendar.js +14 -14
- package/dist/collection/components/sd-card/sd-card.js +1 -1
- package/dist/collection/components/sd-checkbox/sd-checkbox.js +3 -3
- package/dist/collection/components/sd-chip/sd-chip.js +4 -4
- package/dist/collection/components/sd-circle-progress/sd-circle-progress.js +1 -1
- package/dist/collection/components/sd-confirm-modal/sd-confirm-modal.js +13 -8
- package/dist/collection/components/sd-date-box/sd-date-box.js +8 -3
- package/dist/collection/components/sd-date-picker/sd-date-picker-calendar/sd-date-picker-calendar.js +4 -4
- package/dist/collection/components/sd-date-picker/sd-date-picker-trigger/sd-date-picker-trigger.css +1 -1
- package/dist/collection/components/sd-date-picker/sd-date-picker-trigger/sd-date-picker-trigger.js +13 -6
- package/dist/collection/components/sd-date-picker/sd-date-picker.js +4 -4
- package/dist/collection/components/sd-date-range-picker/sd-date-range-picker-calendar/sd-date-range-picker-calendar.js +12 -12
- package/dist/collection/components/sd-date-range-picker/sd-date-range-picker.js +5 -5
- package/dist/collection/components/sd-dropdown-button/sd-dropdown-button.config.js +7 -3
- package/dist/collection/components/sd-dropdown-button/sd-dropdown-button.js +13 -11
- package/dist/collection/components/sd-field/sd-field.css +6 -2
- package/dist/collection/components/sd-field/sd-field.js +48 -22
- package/dist/collection/components/sd-file-picker/sd-file-picker.js +10 -5
- package/dist/collection/components/sd-floating-portal/sd-floating-portal.css +1 -3
- package/dist/collection/components/sd-floating-portal/sd-floating-portal.js +6 -6
- package/dist/collection/components/sd-form/sd-form.js +4 -4
- package/dist/collection/components/sd-ghost-button/sd-ghost-button.js +12 -10
- package/dist/collection/components/sd-guide/sd-guide.css +8 -172
- package/dist/collection/components/sd-guide/sd-guide.js +8 -6
- package/dist/collection/components/sd-icon/sd-icon.js +4 -4
- package/dist/collection/components/sd-input/sd-input.css +4 -2
- package/dist/collection/components/sd-input/sd-input.js +6 -6
- package/dist/collection/components/sd-key-value-table/sd-key-value-table.config.js +36 -0
- package/dist/collection/components/sd-key-value-table/sd-key-value-table.css +119 -0
- package/dist/collection/components/sd-key-value-table/sd-key-value-table.js +301 -0
- package/dist/collection/components/sd-linear-progress/sd-linear-progress.js +1 -1
- package/dist/collection/components/sd-loading-container/sd-loading-container.js +2 -2
- package/dist/collection/components/sd-loading-modal/sd-loading-modal.js +6 -3
- package/dist/collection/components/sd-modal-container/sd-modal-container.js +2 -2
- package/dist/collection/components/sd-number-input/sd-number-input.css +7 -0
- package/dist/collection/components/sd-number-input/sd-number-input.js +8 -5
- package/dist/collection/components/sd-pagination/sd-pagination.js +3 -3
- package/dist/collection/components/sd-popover/sd-popover.js +129 -36
- package/dist/collection/components/sd-popup/sd-popup.config.js +34 -0
- package/dist/collection/components/sd-popup/sd-popup.css +73 -0
- package/dist/collection/components/sd-popup/sd-popup.js +163 -0
- package/dist/collection/components/sd-portal/sd-portal.js +2 -2
- package/dist/collection/components/sd-radio/sd-radio.js +1 -1
- package/dist/collection/components/sd-radio-button/sd-radio-button.js +8 -5
- package/dist/collection/components/sd-radio-group/sd-radio-group.js +2 -2
- package/dist/collection/components/sd-select/sd-select-list-item/sd-select-list-item.js +7 -3
- package/dist/collection/components/sd-select/sd-select-list-item-search/sd-select-list-item-search.css +4 -4
- package/dist/collection/components/sd-select/sd-select-list-item-search/sd-select-list-item-search.js +7 -7
- package/dist/collection/components/sd-select/sd-select-listbox/sd-select-listbox.js +8 -8
- package/dist/collection/components/sd-select/sd-select-trigger/sd-select-trigger.js +9 -4
- package/dist/collection/components/sd-select/sd-select.js +6 -6
- package/dist/collection/components/sd-switch/sd-switch.js +1 -1
- package/dist/collection/components/sd-table/sd-table.config.js +6 -2
- package/dist/collection/components/sd-table/sd-table.css +30 -11
- package/dist/collection/components/sd-table/sd-table.js +233 -50
- package/dist/collection/components/sd-table/sd-table.stories.helpers.js +2 -3
- package/dist/collection/components/sd-table/sd-tbody/sd-tbody.js +5 -5
- package/dist/collection/components/sd-table/sd-td/sd-td.js +111 -9
- package/dist/collection/components/sd-table/sd-thead/sd-thead.js +30 -16
- package/dist/collection/components/sd-table/sd-tr/sd-tr.css +24 -1
- package/dist/collection/components/sd-table/sd-tr/sd-tr.js +116 -19
- package/dist/collection/components/sd-tabs/sd-tabs.js +7 -2
- package/dist/collection/components/sd-tag/sd-tag.config.js +43 -11
- package/dist/collection/components/sd-tag/sd-tag.js +13 -7
- package/dist/collection/components/sd-text-link/sd-text-link.css +1 -0
- package/dist/collection/components/sd-text-link/sd-text-link.js +10 -4
- package/dist/collection/components/sd-textarea/sd-textarea.css +3 -0
- package/dist/collection/components/sd-textarea/sd-textarea.js +2 -2
- package/dist/collection/components/sd-toast/sd-toast.config.js +14 -0
- package/dist/collection/components/sd-toast/sd-toast.css +3 -5
- package/dist/collection/components/sd-toast/sd-toast.js +52 -5
- package/dist/collection/components/sd-toast-container/sd-toast-container.js +4 -4
- package/dist/collection/components/sd-toggle/sd-toggle.js +1 -1
- package/dist/collection/components/sd-tooltip/sd-tooltip.js +77 -30
- package/dist/collection/utils/color/resolveColor.js +2 -2
- package/dist/collection/utils/dropdown-manager.js +1 -1
- package/dist/collection/utils/modal.js +1 -1
- package/dist/collection/utils/toast.js +4 -4
- package/dist/components/index.js +1 -1
- package/dist/components/p-2wB9cing.js +1 -0
- package/dist/components/p-B-sK7I83.js +1 -0
- package/dist/components/p-B3D43x7F.js +1 -0
- package/dist/components/p-B7mpdnNl.js +1 -0
- package/dist/components/{p-TwGlKfsC.js → p-BAcmO7w0.js} +1 -1
- package/dist/components/p-BL0ZcHK8.js +1 -0
- package/dist/components/p-BXCyVrle.js +1 -0
- package/dist/components/p-BY1LGlfc.js +1 -0
- package/dist/components/p-BjkROjjt.js +1 -0
- package/dist/components/p-Bm3W_eBv.js +1 -0
- package/dist/components/p-BnfUIhUj.js +1 -0
- package/dist/components/{p-Dcc2Vm6z.js → p-BorUSgEK.js} +1 -1
- package/dist/components/{p-Bvq0Vpln.js → p-BsM-fwYd.js} +1 -1
- package/dist/components/p-C5CH-s6a.js +1 -0
- package/dist/components/p-C7WLft_0.js +1 -0
- package/dist/components/p-CK9ciBIR.js +1 -0
- package/dist/components/p-CQI40kiY.js +1 -0
- package/dist/components/p-CRL7TjSB.js +1 -0
- package/dist/components/p-CdOHomUp.js +1 -0
- package/dist/components/p-Ch5Yu1qd.js +1 -0
- package/dist/components/p-Cktiasfd.js +1 -0
- package/dist/components/p-CsVAx6KV.js +1 -0
- package/dist/components/p-D0Jiw-Zk.js +1 -0
- package/dist/components/p-D5F7wCNo.js +1 -0
- package/dist/components/p-DBFgk0rX.js +1 -0
- package/dist/components/p-DFLCjX1a.js +1 -0
- package/dist/components/p-DL1ac1QS.js +1 -0
- package/dist/components/p-DdLntfiw.js +1 -0
- package/dist/components/p-DeQcDHpn.js +1 -0
- package/dist/components/p-DfK4DiDI.js +1 -0
- package/dist/components/p-DhTcn6jX.js +1 -0
- package/dist/components/p-Dl8TIEQu.js +1 -0
- package/dist/components/p-DyAnn9ea.js +1 -0
- package/dist/components/p-GBlVDmy4.js +1 -0
- package/dist/components/p-Jts7ueOa.js +1 -0
- package/dist/components/p-arZfxxPn.js +1 -0
- package/dist/components/p-mmdt-WnS.js +1 -0
- package/dist/components/p-nOCYbyW4.js +1 -0
- package/dist/components/p-teN3CfOr.js +1 -0
- package/dist/components/p-u8teDaMa.js +1 -0
- package/dist/components/p-wCNRlKLa.js +1 -0
- package/dist/components/sd-action-modal.js +1 -1
- package/dist/components/sd-badge.js +1 -1
- package/dist/components/sd-barcode-input.js +1 -1
- package/dist/components/sd-button.js +1 -1
- package/dist/components/sd-calendar.js +1 -1
- package/dist/components/sd-card.js +1 -1
- package/dist/components/sd-checkbox.js +1 -1
- package/dist/components/sd-chip.js +1 -1
- package/dist/components/sd-circle-progress.js +1 -1
- package/dist/components/sd-confirm-modal.js +1 -1
- package/dist/components/sd-date-box.js +1 -1
- package/dist/components/sd-date-picker-calendar.js +1 -1
- package/dist/components/sd-date-picker-trigger.js +1 -1
- package/dist/components/sd-date-picker.js +1 -1
- package/dist/components/sd-date-range-picker-calendar.js +1 -1
- package/dist/components/sd-date-range-picker.js +1 -1
- package/dist/components/sd-dropdown-button.js +1 -1
- package/dist/components/sd-field.js +1 -1
- package/dist/components/sd-file-picker.js +1 -1
- package/dist/components/sd-floating-portal.js +1 -1
- package/dist/components/sd-form.js +1 -1
- package/dist/components/sd-ghost-button.js +1 -1
- package/dist/components/sd-guide.js +1 -1
- package/dist/components/sd-icon.js +1 -1
- package/dist/components/sd-input.js +1 -1
- package/dist/components/sd-key-value-table.d.ts +11 -0
- package/dist/components/sd-key-value-table.js +1 -0
- package/dist/components/sd-linear-progress.js +1 -1
- package/dist/components/sd-loading-container.js +1 -1
- package/dist/components/sd-loading-modal.js +1 -1
- package/dist/components/sd-modal-container.js +1 -1
- package/dist/components/sd-number-input.js +1 -1
- package/dist/components/sd-pagination.js +1 -1
- package/dist/components/sd-popover.js +1 -1
- package/dist/components/{sd-button-v2.d.ts → sd-popup.d.ts} +4 -4
- package/dist/components/sd-popup.js +1 -0
- package/dist/components/sd-portal.js +1 -1
- package/dist/components/sd-radio-button.js +1 -1
- package/dist/components/sd-radio-group.js +1 -1
- package/dist/components/sd-radio.js +1 -1
- package/dist/components/sd-select-list-item-search.js +1 -1
- package/dist/components/sd-select-list-item.js +1 -1
- package/dist/components/sd-select-listbox.js +1 -1
- package/dist/components/sd-select-trigger.js +1 -1
- package/dist/components/sd-select.js +1 -1
- package/dist/components/sd-switch.js +1 -1
- package/dist/components/sd-table.js +1 -1
- package/dist/components/sd-tabs.js +1 -1
- package/dist/components/sd-tag.js +1 -1
- package/dist/components/sd-tbody.js +1 -1
- package/dist/components/sd-td.js +1 -1
- package/dist/components/sd-text-link.js +1 -1
- package/dist/components/sd-textarea.js +1 -1
- package/dist/components/sd-thead.js +1 -1
- package/dist/components/sd-toast-container.js +1 -1
- package/dist/components/sd-toast.js +1 -1
- package/dist/components/sd-toggle.js +1 -1
- package/dist/components/sd-tooltip.js +1 -1
- package/dist/components/sd-tr.js +1 -1
- package/dist/design-system/design-system.css +1 -1
- package/dist/design-system/design-system.esm.js +1 -1
- package/dist/design-system/index.esm.js +1 -1
- package/dist/design-system/p-04fdb4b1.entry.js +1 -0
- package/dist/design-system/p-05611ff7.entry.js +1 -0
- package/dist/design-system/p-0U6dRjlq.js +2 -0
- package/dist/design-system/{p-fe9cef6a.entry.js → p-0fe603a4.entry.js} +1 -1
- package/dist/design-system/p-100f5887.entry.js +1 -0
- package/dist/design-system/p-18c5ae1a.entry.js +1 -0
- package/dist/design-system/p-1baa05ae.entry.js +1 -0
- package/dist/design-system/p-2a1ef965.entry.js +1 -0
- package/dist/design-system/p-2c63404f.entry.js +1 -0
- package/dist/design-system/{p-33bc3176.entry.js → p-435ae69e.entry.js} +1 -1
- package/dist/design-system/p-43e97572.entry.js +1 -0
- package/dist/design-system/p-44d05570.entry.js +1 -0
- package/dist/design-system/p-501fae20.entry.js +1 -0
- package/dist/design-system/{p-ead3e688.entry.js → p-5705e6d6.entry.js} +1 -1
- package/dist/design-system/p-5cbaf1db.entry.js +1 -0
- package/dist/design-system/p-5ed0becf.entry.js +1 -0
- package/dist/design-system/p-5f1c39b8.entry.js +1 -0
- package/dist/design-system/p-66af0ba0.entry.js +1 -0
- package/dist/design-system/p-77690440.entry.js +1 -0
- package/dist/design-system/p-78cc0289.entry.js +1 -0
- package/dist/design-system/p-790165f8.entry.js +1 -0
- package/dist/design-system/p-80466582.entry.js +1 -0
- package/dist/design-system/{p-e5cebccd.entry.js → p-857c44e8.entry.js} +1 -1
- package/dist/design-system/{p-f522c91d.entry.js → p-87c868c3.entry.js} +1 -1
- package/dist/design-system/p-8db7d8f2.entry.js +1 -0
- package/dist/design-system/p-8ee990bd.entry.js +1 -0
- package/dist/design-system/p-8f22106e.entry.js +1 -0
- package/dist/design-system/p-BDjErF_K.js +1 -0
- package/dist/design-system/p-BnfUIhUj.js +1 -0
- package/dist/{components/p-DkJqVXpD.js → design-system/p-C29HUShl.js} +1 -1
- package/dist/design-system/{p-BxPyZJaz.js → p-Ce0cmS4R.js} +1 -1
- package/dist/design-system/p-CxOCk_ge.js +1 -0
- package/dist/design-system/p-GBlVDmy4.js +1 -0
- package/dist/design-system/p-a6545130.entry.js +1 -0
- package/dist/design-system/p-ae2d45a2.entry.js +1 -0
- package/dist/design-system/{p-797517b5.entry.js → p-aeccfb2b.entry.js} +1 -1
- package/dist/design-system/p-b0aad445.entry.js +1 -0
- package/dist/design-system/p-b3c144ff.entry.js +1 -0
- package/dist/design-system/p-caee95b0.entry.js +1 -0
- package/dist/design-system/p-d30c823e.entry.js +1 -0
- package/dist/design-system/{p-3f7bc660.entry.js → p-d3212544.entry.js} +1 -1
- package/dist/design-system/p-d8c41313.entry.js +1 -0
- package/dist/design-system/{p-6bfe3612.entry.js → p-de8bb9ba.entry.js} +1 -1
- package/dist/design-system/p-e2334c1c.entry.js +1 -0
- package/dist/design-system/p-f4d73a0c.entry.js +1 -0
- package/dist/design-system/p-fc973500.entry.js +1 -0
- package/dist/design-system/p-fe0a5368.entry.js +1 -0
- package/dist/design-system/p-mmdt-WnS.js +1 -0
- package/dist/esm/component.table-BnfUIhUj.js +64 -0
- package/dist/esm/design-system.js +3 -3
- package/dist/esm/{index-Cnwbjz1F.js → index-0U6dRjlq.js} +1 -1
- package/dist/esm/index.js +5 -5
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{resolveColor-BxPyZJaz.js → resolveColor-Ce0cmS4R.js} +2 -2
- package/dist/esm/sd-action-modal.entry.js +3 -3
- package/dist/esm/sd-badge.entry.js +2 -3
- package/dist/esm/sd-barcode-input.entry.js +3 -3
- package/dist/esm/{sd-button-v2.config-CV4xelxV.js → sd-button.config-BDjErF_K.js} +88 -3
- package/dist/esm/{sd-button-v2_2.entry.js → sd-button_2.entry.js} +102 -85
- package/dist/esm/sd-calendar.entry.js +15 -15
- package/dist/esm/sd-card.entry.js +2 -2
- package/dist/esm/sd-checkbox.entry.js +4 -4
- package/dist/esm/sd-chip.entry.js +4 -4
- package/dist/esm/sd-circle-progress.entry.js +3 -3
- package/dist/esm/sd-confirm-modal_2.entry.js +19 -11
- package/dist/esm/sd-date-box.entry.js +9 -4
- package/dist/esm/{sd-date-picker-calendar.entry.js → sd-date-picker-calendar_2.entry.js} +59 -7
- package/dist/esm/{sd-date-picker.config-C2fDbE9d.js → sd-date-picker.config-B6cqMQaM.js} +1 -2
- package/dist/esm/sd-date-picker_7.entry.js +1227 -0
- package/dist/esm/sd-date-range-picker-calendar.entry.js +14 -14
- package/dist/esm/sd-dropdown-button.entry.js +21 -16
- package/dist/esm/{sd-button_4.entry.js → sd-field_3.entry.js} +48 -102
- package/dist/esm/sd-form.entry.js +5 -5
- package/dist/esm/sd-ghost-button.entry.js +12 -10
- package/dist/esm/sd-guide.entry.js +11 -11
- package/dist/esm/sd-key-value-table.entry.js +228 -0
- package/dist/esm/sd-linear-progress.entry.js +3 -3
- package/dist/esm/sd-loading-container.entry.js +3 -3
- package/dist/esm/sd-modal-container.entry.js +3 -3
- package/dist/esm/{sd-pagination_5.entry.js → sd-pagination_4.entry.js} +137 -325
- package/dist/esm/sd-popover.entry.js +18 -11
- package/dist/esm/sd-popup.entry.js +110 -0
- package/dist/esm/sd-portal.entry.js +3 -3
- package/dist/esm/sd-radio-button.entry.js +9 -6
- package/dist/esm/sd-radio.entry.js +2 -2
- package/dist/esm/sd-select-list-item_2.entry.js +156 -0
- package/dist/esm/sd-select.config-CxOCk_ge.js +165 -0
- package/dist/esm/{sd-select-list-item_4.entry.js → sd-select_3.entry.js} +281 -307
- package/dist/esm/sd-switch.entry.js +2 -2
- package/dist/esm/{sd-table.config-Bj-EEo7N.js → sd-table.config-B-VgXXT7.js} +16 -46
- package/dist/esm/sd-table.entry.js +188 -48
- package/dist/esm/sd-tabs.entry.js +8 -3
- package/dist/esm/sd-tag.entry.js +56 -21
- package/dist/esm/sd-td.entry.js +52 -10
- package/dist/esm/sd-text-link.entry.js +13 -5
- package/dist/esm/sd-toast-container.entry.js +5 -5
- package/dist/esm/sd-toast.entry.js +35 -5
- package/dist/esm/sd-toggle.entry.js +2 -2
- package/dist/esm/{system-CZ4ltUOw.js → system-GBlVDmy4.js} +4 -2
- package/dist/esm/{tooltipArrow-D8sr81Xw.js → tooltipArrow-O5LOsHae.js} +1 -1
- package/dist/types/components/assets/CheckboxCheck.d.ts +1 -0
- package/dist/types/components/assets/CheckboxIndeterminate.d.ts +1 -0
- package/dist/types/components/assets/index.d.ts +2 -0
- package/dist/types/components/sd-action-modal/sd-action-modal.d.ts +2 -2
- package/dist/types/components/sd-badge/sd-badge.d.ts +0 -1
- package/dist/types/components/{sd-button-v2/sd-button-v2.config.d.ts → sd-button/sd-button.config.d.ts} +9 -15
- package/dist/types/components/sd-button/sd-button.d.ts +11 -13
- package/dist/types/components/sd-confirm-modal/sd-confirm-modal.config.d.ts +3 -3
- package/dist/types/components/sd-confirm-modal/sd-confirm-modal.d.ts +2 -1
- package/dist/types/components/sd-dropdown-button/sd-dropdown-button.config.d.ts +6 -5
- package/dist/types/components/sd-dropdown-button/sd-dropdown-button.d.ts +1 -0
- package/dist/types/components/sd-field/sd-field.d.ts +1 -0
- package/dist/types/components/sd-key-value-table/sd-key-value-table.config.d.ts +105 -0
- package/dist/types/components/sd-key-value-table/sd-key-value-table.d.ts +38 -0
- package/dist/types/components/sd-loading-modal/sd-loading-modal.config.d.ts +2 -2
- package/dist/types/components/sd-loading-modal/sd-loading-modal.d.ts +1 -0
- package/dist/types/components/sd-modal-container/sd-modal-container.config.d.ts +1 -1
- package/dist/types/components/sd-popover/sd-popover.d.ts +16 -10
- package/dist/types/components/sd-popup/sd-popup.config.d.ts +30 -0
- package/dist/types/components/sd-popup/sd-popup.d.ts +11 -0
- package/dist/types/components/sd-table/constants.d.ts +2 -0
- package/dist/types/components/sd-table/sd-table.config.d.ts +4 -0
- package/dist/types/components/sd-table/sd-table.d.ts +21 -15
- package/dist/types/components/sd-table/sd-td/sd-td.d.ts +6 -0
- package/dist/types/components/sd-table/sd-tr/sd-tr.d.ts +9 -0
- package/dist/types/components/sd-tag/sd-tag.d.ts +2 -0
- package/dist/types/components/sd-toast/sd-toast.config.d.ts +5 -1
- package/dist/types/components/sd-toast/sd-toast.d.ts +2 -0
- package/dist/types/components/sd-toast-container/sd-toast-container.config.d.ts +2 -0
- package/dist/types/components/sd-tooltip/sd-tooltip.config.d.ts +2 -13
- package/dist/types/components/sd-tooltip/sd-tooltip.d.ts +6 -4
- package/dist/types/components.d.ts +278 -192
- package/dist/types/index.d.ts +1 -1
- package/dist/types/types/form.d.ts +1 -1
- package/dist/types/types/global.d.ts +14 -13
- package/dist/types/utils/toast.d.ts +1 -1
- package/hydrate/index.js +5513 -4761
- package/hydrate/index.mjs +5513 -4761
- package/package.json +111 -97
- package/readme.md +13 -7
- package/dist/cjs/component.button-cqV-iCG5.js +0 -90
- package/dist/cjs/sd-date-picker-trigger.cjs.entry.js +0 -51
- package/dist/cjs/sd-date-picker.cjs.entry.js +0 -117
- package/dist/cjs/sd-date-range-picker.cjs.entry.js +0 -123
- package/dist/cjs/sd-file-picker.cjs.entry.js +0 -244
- package/dist/cjs/sd-input.cjs.entry.js +0 -175
- package/dist/cjs/sd-number-input.cjs.entry.js +0 -409
- package/dist/cjs/sd-radio-group.cjs.entry.js +0 -46
- package/dist/cjs/sd-table.config-Cb0Ot3C6.js +0 -105
- package/dist/cjs/sd-textarea.cjs.entry.js +0 -146
- package/dist/collection/components/sd-button-v2/sd-button-v2.css +0 -125
- package/dist/collection/components/sd-button-v2/sd-button-v2.js +0 -273
- package/dist/components/p-B1XBwjCW.js +0 -1
- package/dist/components/p-B8jXOXtJ.js +0 -1
- package/dist/components/p-BE6TxbtX.js +0 -1
- package/dist/components/p-BJsHakU2.js +0 -1
- package/dist/components/p-BStczlLa.js +0 -1
- package/dist/components/p-BcMNA89i.js +0 -1
- package/dist/components/p-BheX6lAy.js +0 -1
- package/dist/components/p-BmYM7-4v.js +0 -1
- package/dist/components/p-BppjYHF6.js +0 -1
- package/dist/components/p-BwWDMpJc.js +0 -1
- package/dist/components/p-C-kw2p2a.js +0 -1
- package/dist/components/p-C5qZtNLl.js +0 -1
- package/dist/components/p-C7DajKYn.js +0 -1
- package/dist/components/p-CZ4ltUOw.js +0 -1
- package/dist/components/p-CeVMl_M9.js +0 -1
- package/dist/components/p-D1DpOp6M.js +0 -1
- package/dist/components/p-D3gjBBCU.js +0 -1
- package/dist/components/p-DC-6inj0.js +0 -1
- package/dist/components/p-DRF0He-x.js +0 -1
- package/dist/components/p-DegvQLTF.js +0 -1
- package/dist/components/p-Dey-lS6x.js +0 -1
- package/dist/components/p-DfH_fO01.js +0 -1
- package/dist/components/p-DngV3MT1.js +0 -1
- package/dist/components/p-EbjZr2OA.js +0 -1
- package/dist/components/p-LwWOleLJ.js +0 -1
- package/dist/components/p-Nvx13YlG.js +0 -1
- package/dist/components/p-ZMpCZhXP.js +0 -1
- package/dist/components/p-dNJIFthT.js +0 -1
- package/dist/components/p-q0VWISKA.js +0 -1
- package/dist/components/p-xnLvZ-xn.js +0 -1
- package/dist/components/sd-button-v2.js +0 -1
- package/dist/design-system/p-0356c195.entry.js +0 -1
- package/dist/design-system/p-045bc426.entry.js +0 -1
- package/dist/design-system/p-12dfd239.entry.js +0 -1
- package/dist/design-system/p-16d3a485.entry.js +0 -1
- package/dist/design-system/p-1706ed6f.entry.js +0 -1
- package/dist/design-system/p-182548f7.entry.js +0 -1
- package/dist/design-system/p-1a79edce.entry.js +0 -1
- package/dist/design-system/p-1cf87e87.entry.js +0 -1
- package/dist/design-system/p-25a08e98.entry.js +0 -1
- package/dist/design-system/p-2812b9ce.entry.js +0 -1
- package/dist/design-system/p-38f661ea.entry.js +0 -1
- package/dist/design-system/p-429dab5c.entry.js +0 -1
- package/dist/design-system/p-455dccf5.entry.js +0 -1
- package/dist/design-system/p-59313838.entry.js +0 -1
- package/dist/design-system/p-6af01ab0.entry.js +0 -1
- package/dist/design-system/p-70d4903f.entry.js +0 -1
- package/dist/design-system/p-767e99f9.entry.js +0 -1
- package/dist/design-system/p-7c370335.entry.js +0 -1
- package/dist/design-system/p-7fe8be6a.entry.js +0 -1
- package/dist/design-system/p-83b262dc.entry.js +0 -1
- package/dist/design-system/p-881adaa5.entry.js +0 -1
- package/dist/design-system/p-88d7303c.entry.js +0 -1
- package/dist/design-system/p-8a601e0f.entry.js +0 -1
- package/dist/design-system/p-B1XBwjCW.js +0 -1
- package/dist/design-system/p-BsrEibf7.js +0 -1
- package/dist/design-system/p-C5qZtNLl.js +0 -1
- package/dist/design-system/p-CZ4ltUOw.js +0 -1
- package/dist/design-system/p-Cnwbjz1F.js +0 -2
- package/dist/design-system/p-DnCBBIoq.js +0 -1
- package/dist/design-system/p-a82be987.entry.js +0 -1
- package/dist/design-system/p-b917c82a.entry.js +0 -1
- package/dist/design-system/p-b9f00eef.entry.js +0 -1
- package/dist/design-system/p-bcb53788.entry.js +0 -1
- package/dist/design-system/p-c24344ac.entry.js +0 -1
- package/dist/design-system/p-d76192bd.entry.js +0 -1
- package/dist/design-system/p-d9d8c51b.entry.js +0 -1
- package/dist/design-system/p-de67937d.entry.js +0 -1
- package/dist/design-system/p-ea5e6c2c.entry.js +0 -1
- package/dist/design-system/p-eeb1cac2.entry.js +0 -1
- package/dist/design-system/p-f1a74359.entry.js +0 -1
- package/dist/design-system/p-f44786a9.entry.js +0 -1
- package/dist/design-system/p-f69c7539.entry.js +0 -1
- package/dist/esm/component.button-B1XBwjCW.js +0 -88
- package/dist/esm/sd-date-picker-trigger.entry.js +0 -49
- package/dist/esm/sd-date-picker.entry.js +0 -115
- package/dist/esm/sd-date-range-picker.entry.js +0 -121
- package/dist/esm/sd-file-picker.entry.js +0 -242
- package/dist/esm/sd-input.entry.js +0 -173
- package/dist/esm/sd-number-input.entry.js +0 -407
- package/dist/esm/sd-radio-group.entry.js +0 -44
- package/dist/esm/sd-textarea.entry.js +0 -144
- package/dist/types/components/sd-button-v2/sd-button-v2.d.ts +0 -19
- /package/dist/components/{p-C2fDbE9d.js → p-B6cqMQaM.js} +0 -0
- /package/dist/design-system/{p-C2fDbE9d.js → p-B6cqMQaM.js} +0 -0
|
@@ -1,146 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var index = require('./index--F2wGuAi.js');
|
|
4
|
-
var index$1 = require('./index-BUvXpPc3.js');
|
|
5
|
-
var component_textinput = require('./component.textinput-BpXDeZPD.js');
|
|
6
|
-
|
|
7
|
-
const TEXTAREA_TOKENS = {
|
|
8
|
-
paddingX: component_textinput.inputTokens.textinput.sm.paddingX,
|
|
9
|
-
paddingY: component_textinput.inputTokens.textinput.sm.paddingY,
|
|
10
|
-
radius: component_textinput.inputTokens.textinput.sm.radius,
|
|
11
|
-
fontSize: component_textinput.inputTokens.textinput.sm.typography.fontSize,
|
|
12
|
-
lineHeight: component_textinput.inputTokens.textinput.sm.typography.lineHeight,
|
|
13
|
-
fontWeight: component_textinput.inputTokens.textinput.sm.typography.fontWeight};
|
|
14
|
-
const TEXTAREA_COLORS = {
|
|
15
|
-
text: component_textinput.inputTokens.textinput.text,
|
|
16
|
-
bg: component_textinput.inputTokens.textinput.bg,
|
|
17
|
-
border: component_textinput.inputTokens.textinput.border,
|
|
18
|
-
resizer: component_textinput.inputTokens.textinput.resizer,
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
const sdTextareaCss = () => `sd-textarea{display:inline-flex}sd-textarea .sd-textarea__content{width:100%;display:flex}sd-textarea .sd-textarea__content .sd-textarea__native{width:100%;min-height:100px;border:none;outline:none;background:transparent;padding:var(--sd-textarea-padding-y) var(--sd-textarea-padding-x);font-family:inherit;font-size:var(--sd-textarea-font-size);line-height:var(--sd-textarea-line-height);font-weight:var(--sd-textarea-font-weight);color:var(--sd-textarea-text-color);resize:vertical}sd-textarea .sd-textarea__content .sd-textarea__native::placeholder{color:var(--sd-textarea-placeholder-color)}sd-textarea .sd-textarea__content .sd-textarea__native:disabled{cursor:not-allowed;color:var(--sd-textarea-disabled-color)}`;
|
|
22
|
-
|
|
23
|
-
const SdTextarea = class {
|
|
24
|
-
constructor(hostRef) {
|
|
25
|
-
index.registerInstance(this, hostRef);
|
|
26
|
-
this.input = index.createEvent(this, "sdUpdate", 7);
|
|
27
|
-
this.focus = index.createEvent(this, "sdFocus", 7);
|
|
28
|
-
this.blur = index.createEvent(this, "sdBlur", 7);
|
|
29
|
-
}
|
|
30
|
-
get host() { return index.getElement(this); }
|
|
31
|
-
value = null;
|
|
32
|
-
placeholder = '입력해 주세요.';
|
|
33
|
-
disabled = false;
|
|
34
|
-
readonly = false;
|
|
35
|
-
autoFocus = false;
|
|
36
|
-
textareaClass = '';
|
|
37
|
-
textareaStyle = {};
|
|
38
|
-
maxLength;
|
|
39
|
-
rows;
|
|
40
|
-
spellcheck = false;
|
|
41
|
-
width = '';
|
|
42
|
-
// props - sd-field
|
|
43
|
-
label = '';
|
|
44
|
-
labelWidth = '';
|
|
45
|
-
addonLabel = '';
|
|
46
|
-
addonAlign = 'start';
|
|
47
|
-
hint = '';
|
|
48
|
-
errorMessage = '';
|
|
49
|
-
icon = undefined;
|
|
50
|
-
labelTooltip = '';
|
|
51
|
-
labelTooltipProps = null;
|
|
52
|
-
rules = [];
|
|
53
|
-
error = false;
|
|
54
|
-
status;
|
|
55
|
-
focused = false;
|
|
56
|
-
hovered = false;
|
|
57
|
-
internalValue = null;
|
|
58
|
-
nativeEl = undefined;
|
|
59
|
-
formField;
|
|
60
|
-
name = index$1.nanoid();
|
|
61
|
-
input;
|
|
62
|
-
focus;
|
|
63
|
-
blur;
|
|
64
|
-
valueChanged(newValue) {
|
|
65
|
-
this.internalValue = newValue;
|
|
66
|
-
}
|
|
67
|
-
internalValueChanged(newValue) {
|
|
68
|
-
if (newValue !== this.value) {
|
|
69
|
-
this.value = newValue;
|
|
70
|
-
this.input?.emit(this.value);
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
async sdGetNativeElement() {
|
|
74
|
-
return this.nativeEl || null;
|
|
75
|
-
}
|
|
76
|
-
async sdValidate() {
|
|
77
|
-
this.formField?.sdValidate();
|
|
78
|
-
}
|
|
79
|
-
async sdReset() {
|
|
80
|
-
this.formField?.sdReset();
|
|
81
|
-
}
|
|
82
|
-
async sdResetValidate() {
|
|
83
|
-
this.formField?.sdResetValidation();
|
|
84
|
-
}
|
|
85
|
-
async sdFocus() {
|
|
86
|
-
this.formField?.sdFocus();
|
|
87
|
-
}
|
|
88
|
-
componentWillLoad() {
|
|
89
|
-
if (this.value !== null && this.value !== undefined) {
|
|
90
|
-
this.internalValue = this.value;
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
componentDidLoad() {
|
|
94
|
-
if (this.autoFocus) {
|
|
95
|
-
this.nativeEl?.focus();
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
handleInput = (event) => {
|
|
99
|
-
const target = event.target;
|
|
100
|
-
this.internalValue = target.value;
|
|
101
|
-
};
|
|
102
|
-
handleFocus = async (type, event) => {
|
|
103
|
-
this.focused = type === 'focus';
|
|
104
|
-
if (type === 'blur') {
|
|
105
|
-
if (this.rules && this.rules.length > 0) {
|
|
106
|
-
await this.formField?.sdValidate();
|
|
107
|
-
}
|
|
108
|
-
this.blur?.emit(event);
|
|
109
|
-
}
|
|
110
|
-
else {
|
|
111
|
-
this.focus?.emit(event);
|
|
112
|
-
}
|
|
113
|
-
};
|
|
114
|
-
render() {
|
|
115
|
-
const cssVars = {
|
|
116
|
-
'--sd-textarea-font-size': `${TEXTAREA_TOKENS.fontSize}px`,
|
|
117
|
-
'--sd-textarea-line-height': `${TEXTAREA_TOKENS.lineHeight}px`,
|
|
118
|
-
'--sd-textarea-font-weight': TEXTAREA_TOKENS.fontWeight,
|
|
119
|
-
'--sd-textarea-padding-x': `${TEXTAREA_TOKENS.paddingX}px`,
|
|
120
|
-
'--sd-textarea-padding-y': `${TEXTAREA_TOKENS.paddingY}px`,
|
|
121
|
-
'--sd-textarea-radius': `${TEXTAREA_TOKENS.radius}px`,
|
|
122
|
-
'--sd-textarea-text-color': TEXTAREA_COLORS.text.default,
|
|
123
|
-
'--sd-textarea-placeholder-color': TEXTAREA_COLORS.text.placeholder,
|
|
124
|
-
'--sd-textarea-disabled-color': TEXTAREA_COLORS.text.disabled,
|
|
125
|
-
'--sd-textarea-bg-color': TEXTAREA_COLORS.bg.default,
|
|
126
|
-
'--sd-textarea-disabled-bg-color': TEXTAREA_COLORS.bg.disabled,
|
|
127
|
-
'--sd-textarea-border-color': TEXTAREA_COLORS.border.default,
|
|
128
|
-
'--sd-textarea-resizer-color': TEXTAREA_COLORS.resizer.color,
|
|
129
|
-
// sd-field 시스템 변수 override (textarea는 고정 높이가 아닌 auto)
|
|
130
|
-
'--sd-system-size-field-sm-height': 'auto',
|
|
131
|
-
'--sd-system-radius-field-sm': `${TEXTAREA_TOKENS.radius}px`,
|
|
132
|
-
};
|
|
133
|
-
return (index.h("sd-field", { key: 'ca7dc6c13d22ba43cd99ee1e976599d7efb1eceb', name: this.name, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, addonAlign: this.addonAlign, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, index.h("div", { key: 'a36ffabff714596bf780f2a63ccfde3e02eadda7', class: "sd-textarea__content" }, index.h("textarea", { key: 'b7f8a55b7ee4dfc394c380a97e21c6cc34d12b9b', name: this.name, ref: el => (this.nativeEl = el), class: `sd-textarea__native ${this.textareaClass}`, value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readOnly: this.readonly, autofocus: this.autoFocus, maxLength: this.maxLength, rows: this.rows, spellcheck: this.spellcheck, onInput: this.handleInput, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event), style: this.textareaStyle }))));
|
|
134
|
-
}
|
|
135
|
-
static get watchers() { return {
|
|
136
|
-
"value": [{
|
|
137
|
-
"valueChanged": 0
|
|
138
|
-
}],
|
|
139
|
-
"internalValue": [{
|
|
140
|
-
"internalValueChanged": 0
|
|
141
|
-
}]
|
|
142
|
-
}; }
|
|
143
|
-
};
|
|
144
|
-
SdTextarea.style = sdTextareaCss();
|
|
145
|
-
|
|
146
|
-
exports.sd_textarea = SdTextarea;
|
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
sd-button-v2 {
|
|
2
|
-
display: inline-flex;
|
|
3
|
-
width: fit-content;
|
|
4
|
-
height: fit-content;
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
.sd-button-v2 {
|
|
8
|
-
--sd-button-v2-height: 36px;
|
|
9
|
-
--sd-button-v2-padding-x: 20px;
|
|
10
|
-
--sd-button-v2-gap: 8px;
|
|
11
|
-
--sd-button-v2-font-family: inherit;
|
|
12
|
-
--sd-button-v2-font-size: 16px;
|
|
13
|
-
--sd-button-v2-font-weight: 500;
|
|
14
|
-
--sd-button-v2-text-decoration: none;
|
|
15
|
-
--sd-button-v2-label-min-width: auto;
|
|
16
|
-
--sd-button-v2-icon-only-size: var(--sd-button-v2-height);
|
|
17
|
-
--sd-button-v2-bg: #025497;
|
|
18
|
-
--sd-button-v2-bg-hover: #004177;
|
|
19
|
-
--sd-button-v2-border: transparent;
|
|
20
|
-
--sd-button-v2-content: #FFFFFF;
|
|
21
|
-
--sd-button-v2-current-content: var(--sd-button-v2-content);
|
|
22
|
-
--sd-button-v2-current-icon: var(--sd-button-v2-content);
|
|
23
|
-
display: inline-flex;
|
|
24
|
-
align-items: center;
|
|
25
|
-
justify-content: center;
|
|
26
|
-
min-height: var(--sd-button-v2-height);
|
|
27
|
-
min-width: var(--sd-button-v2-min-width, auto);
|
|
28
|
-
padding: 0 var(--sd-button-v2-padding-x);
|
|
29
|
-
border: var(--sd-button-button-border-width-default, 1px) solid var(--sd-button-v2-border);
|
|
30
|
-
border-radius: var(--sd-button-button-radius-sm, 4px);
|
|
31
|
-
background: var(--sd-button-v2-bg);
|
|
32
|
-
color: var(--sd-button-v2-current-content);
|
|
33
|
-
cursor: pointer;
|
|
34
|
-
box-sizing: border-box;
|
|
35
|
-
font-family: var(--sd-button-v2-font-family);
|
|
36
|
-
font-size: var(--sd-button-v2-font-size);
|
|
37
|
-
font-weight: var(--sd-button-v2-font-weight);
|
|
38
|
-
line-height: 1;
|
|
39
|
-
text-decoration: var(--sd-button-v2-text-decoration);
|
|
40
|
-
transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
|
|
41
|
-
white-space: nowrap;
|
|
42
|
-
-webkit-user-select: none;
|
|
43
|
-
user-select: none;
|
|
44
|
-
}
|
|
45
|
-
.sd-button-v2:hover:not(.sd-button-v2--disabled) {
|
|
46
|
-
background: var(--sd-button-v2-bg-hover);
|
|
47
|
-
}
|
|
48
|
-
.sd-button-v2:focus-visible {
|
|
49
|
-
outline: 0;
|
|
50
|
-
box-shadow: 0 0 0 2px var(--sd-button-v2-accent);
|
|
51
|
-
}
|
|
52
|
-
.sd-button-v2--xs {
|
|
53
|
-
--sd-button-v2-height: var(--sd-button-button-xs-height, 24px);
|
|
54
|
-
--sd-button-v2-padding-x: var(--sd-button-button-xs-padding-x, 8px);
|
|
55
|
-
--sd-button-v2-gap: var(--sd-button-button-xs-gap, 4px);
|
|
56
|
-
--sd-button-v2-font-family: var(--sd-button-button-xs-typography-font-family, inherit);
|
|
57
|
-
--sd-button-v2-font-size: var(--sd-button-button-xs-typography-font-size, 12px);
|
|
58
|
-
--sd-button-v2-font-weight: var(--sd-button-button-xs-typography-font-weight, 500);
|
|
59
|
-
--sd-button-v2-text-decoration: var(--sd-button-button-xs-typography-text-decoration, none);
|
|
60
|
-
--sd-button-v2-label-min-width: var(--sd-button-label-xs-min-width, 36px);
|
|
61
|
-
--sd-button-v2-icon-only-size: var(--sd-button-button-icon-only-xs-width, var(--sd-button-v2-height));
|
|
62
|
-
}
|
|
63
|
-
.sd-button-v2--sm {
|
|
64
|
-
--sd-button-v2-height: var(--sd-button-button-sm-height, 28px);
|
|
65
|
-
--sd-button-v2-padding-x: var(--sd-button-button-sm-padding-x, 12px);
|
|
66
|
-
--sd-button-v2-gap: var(--sd-button-button-sm-gap, 6px);
|
|
67
|
-
--sd-button-v2-font-family: var(--sd-button-button-sm-typography-font-family, inherit);
|
|
68
|
-
--sd-button-v2-font-size: var(--sd-button-button-sm-typography-font-size, 12px);
|
|
69
|
-
--sd-button-v2-font-weight: var(--sd-button-button-sm-typography-font-weight, 500);
|
|
70
|
-
--sd-button-v2-text-decoration: var(--sd-button-button-sm-typography-text-decoration, none);
|
|
71
|
-
--sd-button-v2-label-min-width: var(--sd-button-label-sm-min-width, 70px);
|
|
72
|
-
--sd-button-v2-icon-only-size: var(--sd-button-button-icon-only-sm-width, var(--sd-button-v2-height));
|
|
73
|
-
}
|
|
74
|
-
.sd-button-v2--md {
|
|
75
|
-
--sd-button-v2-height: var(--sd-button-button-md-height, 36px);
|
|
76
|
-
--sd-button-v2-padding-x: var(--sd-button-button-md-padding-x, 20px);
|
|
77
|
-
--sd-button-v2-gap: var(--sd-button-button-md-gap, 8px);
|
|
78
|
-
--sd-button-v2-font-family: var(--sd-button-button-md-typography-font-family, inherit);
|
|
79
|
-
--sd-button-v2-font-size: var(--sd-button-button-md-typography-font-size, 16px);
|
|
80
|
-
--sd-button-v2-font-weight: var(--sd-button-button-md-typography-font-weight, 500);
|
|
81
|
-
--sd-button-v2-text-decoration: var(--sd-button-button-md-typography-text-decoration, none);
|
|
82
|
-
--sd-button-v2-label-min-width: var(--sd-button-label-md-min-width, 100px);
|
|
83
|
-
--sd-button-v2-icon-only-size: var(--sd-button-button-icon-only-md-width, var(--sd-button-v2-height));
|
|
84
|
-
border-radius: var(--sd-button-button-radius-md, 6px);
|
|
85
|
-
}
|
|
86
|
-
.sd-button-v2--lg {
|
|
87
|
-
--sd-button-v2-height: var(--sd-button-button-lg-height, 62px);
|
|
88
|
-
--sd-button-v2-padding-x: var(--sd-button-button-lg-padding-x, 28px);
|
|
89
|
-
--sd-button-v2-gap: var(--sd-button-button-lg-gap, 12px);
|
|
90
|
-
--sd-button-v2-font-family: var(--sd-button-button-lg-typography-font-family, inherit);
|
|
91
|
-
--sd-button-v2-font-size: var(--sd-button-button-lg-typography-font-size, 18px);
|
|
92
|
-
--sd-button-v2-font-weight: var(--sd-button-button-lg-typography-font-weight, 500);
|
|
93
|
-
--sd-button-v2-text-decoration: var(--sd-button-button-lg-typography-text-decoration, none);
|
|
94
|
-
--sd-button-v2-label-min-width: var(--sd-button-label-lg-min-width, 120px);
|
|
95
|
-
--sd-button-v2-icon-only-size: var(--sd-button-button-icon-only-lg-width, var(--sd-button-v2-height));
|
|
96
|
-
border-radius: var(--sd-button-button-radius-md, 6px);
|
|
97
|
-
}
|
|
98
|
-
.sd-button-v2--has-label {
|
|
99
|
-
--sd-button-v2-min-width: var(--sd-button-v2-label-min-width, auto);
|
|
100
|
-
}
|
|
101
|
-
.sd-button-v2--icon-only {
|
|
102
|
-
width: var(--sd-button-v2-icon-only-size, var(--sd-button-v2-height));
|
|
103
|
-
min-width: var(--sd-button-v2-icon-only-size, var(--sd-button-v2-height));
|
|
104
|
-
height: var(--sd-button-v2-icon-only-size, var(--sd-button-v2-height));
|
|
105
|
-
padding: 0;
|
|
106
|
-
}
|
|
107
|
-
.sd-button-v2--icon-only .sd-button-v2__content {
|
|
108
|
-
gap: 0;
|
|
109
|
-
}
|
|
110
|
-
.sd-button-v2--disabled {
|
|
111
|
-
border-color: var(--sd-button-button-border-disabled, #CCCCCC);
|
|
112
|
-
background: var(--sd-button-button-bg-disabled, #E1E1E1);
|
|
113
|
-
--sd-button-v2-current-content: var(--sd-button-button-text-disabled, #888888);
|
|
114
|
-
--sd-button-v2-current-icon: var(--sd-button-button-icon-disabled, #BBBBBB);
|
|
115
|
-
cursor: not-allowed;
|
|
116
|
-
}
|
|
117
|
-
.sd-button-v2 .sd-button-v2__content {
|
|
118
|
-
display: inline-flex;
|
|
119
|
-
align-items: center;
|
|
120
|
-
justify-content: center;
|
|
121
|
-
gap: var(--sd-button-v2-gap);
|
|
122
|
-
}
|
|
123
|
-
.sd-button-v2 .sd-button-v2__label {
|
|
124
|
-
font: inherit;
|
|
125
|
-
}
|
|
@@ -1,273 +0,0 @@
|
|
|
1
|
-
import { h } from "@stencil/core";
|
|
2
|
-
import { BUTTON_CONFIG, BUTTON_FOCUS_RING_COLOR, BUTTON_ICON_SIZES, PRESET_BORDER_COLORS, PRESET_CONTENT_COLORS, PRESET_HOVER_BACKGROUNDS, getPresetName, isButtonV2Name, } from "./sd-button-v2.config";
|
|
3
|
-
export class SdButtonV2 {
|
|
4
|
-
name = 'primary_sm';
|
|
5
|
-
label = '';
|
|
6
|
-
icon;
|
|
7
|
-
rightIcon;
|
|
8
|
-
ariaLabel = '';
|
|
9
|
-
disabled = false;
|
|
10
|
-
type = 'button';
|
|
11
|
-
click;
|
|
12
|
-
hasWarnedMissingAriaLabel = false;
|
|
13
|
-
handleClick = (event) => {
|
|
14
|
-
if (this.disabled) {
|
|
15
|
-
event.preventDefault();
|
|
16
|
-
return;
|
|
17
|
-
}
|
|
18
|
-
this.click.emit(event);
|
|
19
|
-
};
|
|
20
|
-
get resolvedConfig() {
|
|
21
|
-
if (!isButtonV2Name(this.name)) {
|
|
22
|
-
throw new Error(`Invalid sd-button-v2 name: ${this.name}`);
|
|
23
|
-
}
|
|
24
|
-
const config = BUTTON_CONFIG[this.name];
|
|
25
|
-
const preset = getPresetName(this.name);
|
|
26
|
-
return {
|
|
27
|
-
config,
|
|
28
|
-
preset,
|
|
29
|
-
};
|
|
30
|
-
}
|
|
31
|
-
getButtonClasses(preset, size, hasLabel, iconOnly) {
|
|
32
|
-
const classes = ['sd-button-v2', `sd-button-v2--${preset}`, `sd-button-v2--${size}`];
|
|
33
|
-
if (this.disabled) {
|
|
34
|
-
classes.push('sd-button-v2--disabled');
|
|
35
|
-
}
|
|
36
|
-
if (iconOnly) {
|
|
37
|
-
classes.push('sd-button-v2--icon-only');
|
|
38
|
-
}
|
|
39
|
-
if (hasLabel) {
|
|
40
|
-
classes.push('sd-button-v2--has-label');
|
|
41
|
-
}
|
|
42
|
-
return classes.join(' ');
|
|
43
|
-
}
|
|
44
|
-
componentWillRender() {
|
|
45
|
-
this.warnIfMissingAriaLabel();
|
|
46
|
-
}
|
|
47
|
-
warnIfMissingAriaLabel() {
|
|
48
|
-
const iconOnly = !this.label && (Boolean(this.icon) || Boolean(this.rightIcon));
|
|
49
|
-
const missingAriaLabel = iconOnly && !this.ariaLabel.trim();
|
|
50
|
-
if (!missingAriaLabel) {
|
|
51
|
-
this.hasWarnedMissingAriaLabel = false;
|
|
52
|
-
return;
|
|
53
|
-
}
|
|
54
|
-
if (this.hasWarnedMissingAriaLabel) {
|
|
55
|
-
return;
|
|
56
|
-
}
|
|
57
|
-
console.warn(`[sd-button-v2] icon-only buttons require \`ariaLabel\`. Received name="${this.name}" icon="${this.icon ?? this.rightIcon}".`);
|
|
58
|
-
this.hasWarnedMissingAriaLabel = true;
|
|
59
|
-
}
|
|
60
|
-
render() {
|
|
61
|
-
const { config, preset } = this.resolvedConfig;
|
|
62
|
-
const hasLabel = Boolean(this.label);
|
|
63
|
-
const iconOnly = !this.label && Boolean(this.icon) !== Boolean(this.rightIcon);
|
|
64
|
-
const accessibleName = iconOnly && this.ariaLabel.trim() ? this.ariaLabel : undefined;
|
|
65
|
-
return (h("button", { key: 'e3e2074fbe2b48117d5834efac7ff3036757aab3', class: this.getButtonClasses(preset, config.size, hasLabel, iconOnly), type: this.type, disabled: this.disabled, "aria-label": accessibleName, style: {
|
|
66
|
-
'--sd-button-v2-bg': config.color,
|
|
67
|
-
'--sd-button-v2-bg-hover': PRESET_HOVER_BACKGROUNDS[preset],
|
|
68
|
-
'--sd-button-v2-border': PRESET_BORDER_COLORS[preset],
|
|
69
|
-
'--sd-button-v2-content': PRESET_CONTENT_COLORS[preset],
|
|
70
|
-
'--sd-button-v2-accent': BUTTON_FOCUS_RING_COLOR,
|
|
71
|
-
}, onClick: this.handleClick }, h("span", { key: '90ea3bf42c9e16c836c6fdfdf26a74c8a848c31b', class: "sd-button-v2__content" }, this.icon && (h("sd-icon", { key: 'b9f4a1c42ae866aac1f65f4bbedb282ae0c10c72', class: "sd-button-v2__icon", name: this.icon, size: BUTTON_ICON_SIZES[config.size], color: "var(--sd-button-v2-current-icon)" })), this.label && h("span", { key: '5e5dfbabdbec86c2da625c6a70fcda10303d0e50', class: "sd-button-v2__label" }, this.label), this.rightIcon && (h("sd-icon", { key: 'f1c3a74b6d7e83fa755c97f83c6d97dea8411537', class: "sd-button-v2__icon sd-button-v2__icon--right", name: this.rightIcon, size: BUTTON_ICON_SIZES[config.size], color: "var(--sd-button-v2-current-icon)" })))));
|
|
72
|
-
}
|
|
73
|
-
static get is() { return "sd-button-v2"; }
|
|
74
|
-
static get originalStyleUrls() {
|
|
75
|
-
return {
|
|
76
|
-
"$": ["sd-button-v2.scss"]
|
|
77
|
-
};
|
|
78
|
-
}
|
|
79
|
-
static get styleUrls() {
|
|
80
|
-
return {
|
|
81
|
-
"$": ["sd-button-v2.css"]
|
|
82
|
-
};
|
|
83
|
-
}
|
|
84
|
-
static get properties() {
|
|
85
|
-
return {
|
|
86
|
-
"name": {
|
|
87
|
-
"type": "string",
|
|
88
|
-
"mutable": false,
|
|
89
|
-
"complexType": {
|
|
90
|
-
"original": "ButtonV2Name",
|
|
91
|
-
"resolved": "\"danger_lg\" | \"danger_md\" | \"danger_outline_lg\" | \"danger_outline_md\" | \"danger_outline_sm\" | \"danger_outline_xs\" | \"danger_sm\" | \"danger_xs\" | \"neutral_outline_lg\" | \"neutral_outline_md\" | \"neutral_outline_sm\" | \"neutral_outline_xs\" | \"primary_lg\" | \"primary_md\" | \"primary_outline_lg\" | \"primary_outline_md\" | \"primary_outline_sm\" | \"primary_outline_xs\" | \"primary_sm\" | \"primary_xs\" | \"secondary_lg\" | \"secondary_md\" | \"secondary_sm\" | \"secondary_xs\"",
|
|
92
|
-
"references": {
|
|
93
|
-
"ButtonV2Name": {
|
|
94
|
-
"location": "import",
|
|
95
|
-
"path": "./sd-button-v2.config",
|
|
96
|
-
"id": "src/components/sd-button-v2/sd-button-v2.config.ts::ButtonV2Name",
|
|
97
|
-
"referenceLocation": "ButtonV2Name"
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
},
|
|
101
|
-
"required": false,
|
|
102
|
-
"optional": false,
|
|
103
|
-
"docs": {
|
|
104
|
-
"tags": [],
|
|
105
|
-
"text": ""
|
|
106
|
-
},
|
|
107
|
-
"getter": false,
|
|
108
|
-
"setter": false,
|
|
109
|
-
"reflect": false,
|
|
110
|
-
"attribute": "name",
|
|
111
|
-
"defaultValue": "'primary_sm'"
|
|
112
|
-
},
|
|
113
|
-
"label": {
|
|
114
|
-
"type": "string",
|
|
115
|
-
"mutable": false,
|
|
116
|
-
"complexType": {
|
|
117
|
-
"original": "string",
|
|
118
|
-
"resolved": "string",
|
|
119
|
-
"references": {}
|
|
120
|
-
},
|
|
121
|
-
"required": false,
|
|
122
|
-
"optional": false,
|
|
123
|
-
"docs": {
|
|
124
|
-
"tags": [],
|
|
125
|
-
"text": ""
|
|
126
|
-
},
|
|
127
|
-
"getter": false,
|
|
128
|
-
"setter": false,
|
|
129
|
-
"reflect": false,
|
|
130
|
-
"attribute": "label",
|
|
131
|
-
"defaultValue": "''"
|
|
132
|
-
},
|
|
133
|
-
"icon": {
|
|
134
|
-
"type": "string",
|
|
135
|
-
"mutable": false,
|
|
136
|
-
"complexType": {
|
|
137
|
-
"original": "IconName",
|
|
138
|
-
"resolved": "\"add\" | \"alert\" | \"alignKorean\" | \"archive\" | \"arrowDown\" | \"arrowLeft\" | \"arrowRight\" | \"arrowUp\" | \"attachFile\" | \"barcode\" | \"bell\" | \"board\" | \"box\" | \"camera\" | \"cancelFill\" | \"cancelOutline\" | \"caretDown\" | \"caretLeft\" | \"caretRight\" | \"caretUp\" | \"check\" | \"checkFill\" | \"checkOutline\" | \"chevronDown\" | \"chevronLeft\" | \"chevronLeftEnd\" | \"chevronRight\" | \"chevronRightEnd\" | \"chevronUp\" | \"clockFill\" | \"clockOutline\" | \"close\" | \"copy\" | \"dashboard\" | \"date\" | \"download\" | \"drag\" | \"edit\" | \"etc\" | \"event\" | \"global\" | \"helpFill\" | \"helpOutline\" | \"history\" | \"imageFill\" | \"imageOutline\" | \"inline\" | \"line\" | \"location\" | \"logout\" | \"minus\" | \"new\" | \"notificationFill\" | \"notificationOutline\" | \"notion\" | \"outline\" | \"pageEdit\" | \"pageMove\" | \"pdf\" | \"print\" | \"remove\" | \"reset\" | \"robot\" | \"row\" | \"save\" | \"search\" | \"setting\" | \"star\" | \"synchronize\" | \"updown\" | \"user\" | \"visibilityOff\" | \"visibilityOn\" | \"warehouseFill\" | \"warehouseOutline\" | \"warningFill\" | \"warningOutline\" | \"youtube\" | undefined",
|
|
139
|
-
"references": {
|
|
140
|
-
"IconName": {
|
|
141
|
-
"location": "global",
|
|
142
|
-
"id": "global::IconName"
|
|
143
|
-
}
|
|
144
|
-
}
|
|
145
|
-
},
|
|
146
|
-
"required": false,
|
|
147
|
-
"optional": true,
|
|
148
|
-
"docs": {
|
|
149
|
-
"tags": [],
|
|
150
|
-
"text": ""
|
|
151
|
-
},
|
|
152
|
-
"getter": false,
|
|
153
|
-
"setter": false,
|
|
154
|
-
"reflect": false,
|
|
155
|
-
"attribute": "icon"
|
|
156
|
-
},
|
|
157
|
-
"rightIcon": {
|
|
158
|
-
"type": "string",
|
|
159
|
-
"mutable": false,
|
|
160
|
-
"complexType": {
|
|
161
|
-
"original": "IconName",
|
|
162
|
-
"resolved": "\"add\" | \"alert\" | \"alignKorean\" | \"archive\" | \"arrowDown\" | \"arrowLeft\" | \"arrowRight\" | \"arrowUp\" | \"attachFile\" | \"barcode\" | \"bell\" | \"board\" | \"box\" | \"camera\" | \"cancelFill\" | \"cancelOutline\" | \"caretDown\" | \"caretLeft\" | \"caretRight\" | \"caretUp\" | \"check\" | \"checkFill\" | \"checkOutline\" | \"chevronDown\" | \"chevronLeft\" | \"chevronLeftEnd\" | \"chevronRight\" | \"chevronRightEnd\" | \"chevronUp\" | \"clockFill\" | \"clockOutline\" | \"close\" | \"copy\" | \"dashboard\" | \"date\" | \"download\" | \"drag\" | \"edit\" | \"etc\" | \"event\" | \"global\" | \"helpFill\" | \"helpOutline\" | \"history\" | \"imageFill\" | \"imageOutline\" | \"inline\" | \"line\" | \"location\" | \"logout\" | \"minus\" | \"new\" | \"notificationFill\" | \"notificationOutline\" | \"notion\" | \"outline\" | \"pageEdit\" | \"pageMove\" | \"pdf\" | \"print\" | \"remove\" | \"reset\" | \"robot\" | \"row\" | \"save\" | \"search\" | \"setting\" | \"star\" | \"synchronize\" | \"updown\" | \"user\" | \"visibilityOff\" | \"visibilityOn\" | \"warehouseFill\" | \"warehouseOutline\" | \"warningFill\" | \"warningOutline\" | \"youtube\" | undefined",
|
|
163
|
-
"references": {
|
|
164
|
-
"IconName": {
|
|
165
|
-
"location": "global",
|
|
166
|
-
"id": "global::IconName"
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
},
|
|
170
|
-
"required": false,
|
|
171
|
-
"optional": true,
|
|
172
|
-
"docs": {
|
|
173
|
-
"tags": [],
|
|
174
|
-
"text": ""
|
|
175
|
-
},
|
|
176
|
-
"getter": false,
|
|
177
|
-
"setter": false,
|
|
178
|
-
"reflect": false,
|
|
179
|
-
"attribute": "right-icon"
|
|
180
|
-
},
|
|
181
|
-
"ariaLabel": {
|
|
182
|
-
"type": "string",
|
|
183
|
-
"mutable": false,
|
|
184
|
-
"complexType": {
|
|
185
|
-
"original": "string",
|
|
186
|
-
"resolved": "string",
|
|
187
|
-
"references": {}
|
|
188
|
-
},
|
|
189
|
-
"required": false,
|
|
190
|
-
"optional": false,
|
|
191
|
-
"docs": {
|
|
192
|
-
"tags": [],
|
|
193
|
-
"text": ""
|
|
194
|
-
},
|
|
195
|
-
"getter": false,
|
|
196
|
-
"setter": false,
|
|
197
|
-
"reflect": false,
|
|
198
|
-
"attribute": "aria-label",
|
|
199
|
-
"defaultValue": "''"
|
|
200
|
-
},
|
|
201
|
-
"disabled": {
|
|
202
|
-
"type": "boolean",
|
|
203
|
-
"mutable": false,
|
|
204
|
-
"complexType": {
|
|
205
|
-
"original": "boolean",
|
|
206
|
-
"resolved": "boolean",
|
|
207
|
-
"references": {}
|
|
208
|
-
},
|
|
209
|
-
"required": false,
|
|
210
|
-
"optional": false,
|
|
211
|
-
"docs": {
|
|
212
|
-
"tags": [],
|
|
213
|
-
"text": ""
|
|
214
|
-
},
|
|
215
|
-
"getter": false,
|
|
216
|
-
"setter": false,
|
|
217
|
-
"reflect": false,
|
|
218
|
-
"attribute": "disabled",
|
|
219
|
-
"defaultValue": "false"
|
|
220
|
-
},
|
|
221
|
-
"type": {
|
|
222
|
-
"type": "string",
|
|
223
|
-
"mutable": false,
|
|
224
|
-
"complexType": {
|
|
225
|
-
"original": "ButtonV2Type",
|
|
226
|
-
"resolved": "\"button\" | \"reset\" | \"submit\"",
|
|
227
|
-
"references": {
|
|
228
|
-
"ButtonV2Type": {
|
|
229
|
-
"location": "import",
|
|
230
|
-
"path": "./sd-button-v2.config",
|
|
231
|
-
"id": "src/components/sd-button-v2/sd-button-v2.config.ts::ButtonV2Type",
|
|
232
|
-
"referenceLocation": "ButtonV2Type"
|
|
233
|
-
}
|
|
234
|
-
}
|
|
235
|
-
},
|
|
236
|
-
"required": false,
|
|
237
|
-
"optional": false,
|
|
238
|
-
"docs": {
|
|
239
|
-
"tags": [],
|
|
240
|
-
"text": ""
|
|
241
|
-
},
|
|
242
|
-
"getter": false,
|
|
243
|
-
"setter": false,
|
|
244
|
-
"reflect": false,
|
|
245
|
-
"attribute": "type",
|
|
246
|
-
"defaultValue": "'button'"
|
|
247
|
-
}
|
|
248
|
-
};
|
|
249
|
-
}
|
|
250
|
-
static get events() {
|
|
251
|
-
return [{
|
|
252
|
-
"method": "click",
|
|
253
|
-
"name": "sdClick",
|
|
254
|
-
"bubbles": true,
|
|
255
|
-
"cancelable": true,
|
|
256
|
-
"composed": true,
|
|
257
|
-
"docs": {
|
|
258
|
-
"tags": [],
|
|
259
|
-
"text": ""
|
|
260
|
-
},
|
|
261
|
-
"complexType": {
|
|
262
|
-
"original": "MouseEvent",
|
|
263
|
-
"resolved": "MouseEvent",
|
|
264
|
-
"references": {
|
|
265
|
-
"MouseEvent": {
|
|
266
|
-
"location": "global",
|
|
267
|
-
"id": "global::MouseEvent"
|
|
268
|
-
}
|
|
269
|
-
}
|
|
270
|
-
}
|
|
271
|
-
}];
|
|
272
|
-
}
|
|
273
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var F={button:{xs:{icon:"12"},sm:{icon:"16"},md:{icon:"20"},lg:{icon:"24"},border:{disabled:"#CCCCCC"},bg:{disabled:"#E1E1E1"},text:{disabled:"#888888"},brand:{strong:{bg:{default:"#025497",hover:"#004177"},content:"#FFFFFF",dropdown:{divider:"#006AC1"}},subtle:{bg:{default:"#1F8AE1",hover:"#006AC1"},content:"#FFFFFF",dropdown:{divider:"#5CB0F3"}},outline:{bg:{default:"#FFFFFF",hover:"#EAF5FE"},border:"#025497",content:"#025497"}},neutral:{outline:{bg:{default:"#FFFFFF",hover:"#EEEEEE"},border:"#888888",content:"#222222"}},danger:{strong:{bg:{default:"#E30000",hover:"#AD0000"},content:"#FFFFFF",dropdown:{divider:"#FF7C7C"}},outline:{bg:{default:"#FFFFFF",hover:"#FCEFEF"},border:"#E30000",content:"#E30000"}}}};export{F as b}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{p as t,H as n,c as o,h as s,t as d}from"./p-D3gjBBCU.js";import{i,g as b,B as e,d as a,c as u,a as r,P as v,b as h}from"./p-C-kw2p2a.js";import{d as l}from"./p-EbjZr2OA.js";const c=t(class extends n{constructor(t){super(),!1!==t&&this.__registerHost(),this.click=o(this,"sdClick",7)}name="primary_sm";label="";icon;rightIcon;ariaLabel="";disabled=!1;type="button";click;hasWarnedMissingAriaLabel=!1;handleClick=t=>{this.disabled?t.preventDefault():this.click.emit(t)};get resolvedConfig(){if(!i(this.name))throw new Error(`Invalid sd-button-v2 name: ${this.name}`);return{config:e[this.name],preset:b(this.name)}}getButtonClasses(t,n,o,s){const d=["sd-button-v2",`sd-button-v2--${t}`,`sd-button-v2--${n}`];return this.disabled&&d.push("sd-button-v2--disabled"),s&&d.push("sd-button-v2--icon-only"),o&&d.push("sd-button-v2--has-label"),d.join(" ")}componentWillRender(){this.warnIfMissingAriaLabel()}warnIfMissingAriaLabel(){this.label||!Boolean(this.icon)&&!Boolean(this.rightIcon)||this.ariaLabel.trim()?this.hasWarnedMissingAriaLabel=!1:this.hasWarnedMissingAriaLabel||(console.warn(`[sd-button-v2] icon-only buttons require \`ariaLabel\`. Received name="${this.name}" icon="${this.icon??this.rightIcon}".`),this.hasWarnedMissingAriaLabel=!0)}render(){const{config:t,preset:n}=this.resolvedConfig,o=Boolean(this.label),d=!this.label&&Boolean(this.icon)!==Boolean(this.rightIcon),i=d&&this.ariaLabel.trim()?this.ariaLabel:void 0;return s("button",{key:"e3e2074fbe2b48117d5834efac7ff3036757aab3",class:this.getButtonClasses(n,t.size,o,d),type:this.type,disabled:this.disabled,"aria-label":i,style:{"--sd-button-v2-bg":t.color,"--sd-button-v2-bg-hover":h[n],"--sd-button-v2-border":v[n],"--sd-button-v2-content":r[n],"--sd-button-v2-accent":u},onClick:this.handleClick},s("span",{key:"90ea3bf42c9e16c836c6fdfdf26a74c8a848c31b",class:"sd-button-v2__content"},this.icon&&s("sd-icon",{key:"b9f4a1c42ae866aac1f65f4bbedb282ae0c10c72",class:"sd-button-v2__icon",name:this.icon,size:a[t.size],color:"var(--sd-button-v2-current-icon)"}),this.label&&s("span",{key:"5e5dfbabdbec86c2da625c6a70fcda10303d0e50",class:"sd-button-v2__label"},this.label),this.rightIcon&&s("sd-icon",{key:"f1c3a74b6d7e83fa755c97f83c6d97dea8411537",class:"sd-button-v2__icon sd-button-v2__icon--right",name:this.rightIcon,size:a[t.size],color:"var(--sd-button-v2-current-icon)"})))}static get style(){return"sd-button-v2{display:inline-flex;width:fit-content;height:fit-content}.sd-button-v2{--sd-button-v2-height:36px;--sd-button-v2-padding-x:20px;--sd-button-v2-gap:8px;--sd-button-v2-font-family:inherit;--sd-button-v2-font-size:16px;--sd-button-v2-font-weight:500;--sd-button-v2-text-decoration:none;--sd-button-v2-label-min-width:auto;--sd-button-v2-icon-only-size:var(--sd-button-v2-height);--sd-button-v2-bg:#025497;--sd-button-v2-bg-hover:#004177;--sd-button-v2-border:transparent;--sd-button-v2-content:#FFFFFF;--sd-button-v2-current-content:var(--sd-button-v2-content);--sd-button-v2-current-icon:var(--sd-button-v2-content);display:inline-flex;align-items:center;justify-content:center;min-height:var(--sd-button-v2-height);min-width:var(--sd-button-v2-min-width, auto);padding:0 var(--sd-button-v2-padding-x);border:var(--sd-button-button-border-width-default, 1px) solid var(--sd-button-v2-border);border-radius:var(--sd-button-button-radius-sm, 4px);background:var(--sd-button-v2-bg);color:var(--sd-button-v2-current-content);cursor:pointer;box-sizing:border-box;font-family:var(--sd-button-v2-font-family);font-size:var(--sd-button-v2-font-size);font-weight:var(--sd-button-v2-font-weight);line-height:1;text-decoration:var(--sd-button-v2-text-decoration);transition:background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;white-space:nowrap;-webkit-user-select:none;user-select:none}.sd-button-v2:hover:not(.sd-button-v2--disabled){background:var(--sd-button-v2-bg-hover)}.sd-button-v2:focus-visible{outline:0;box-shadow:0 0 0 2px var(--sd-button-v2-accent)}.sd-button-v2--xs{--sd-button-v2-height:var(--sd-button-button-xs-height, 24px);--sd-button-v2-padding-x:var(--sd-button-button-xs-padding-x, 8px);--sd-button-v2-gap:var(--sd-button-button-xs-gap, 4px);--sd-button-v2-font-family:var(--sd-button-button-xs-typography-font-family, inherit);--sd-button-v2-font-size:var(--sd-button-button-xs-typography-font-size, 12px);--sd-button-v2-font-weight:var(--sd-button-button-xs-typography-font-weight, 500);--sd-button-v2-text-decoration:var(--sd-button-button-xs-typography-text-decoration, none);--sd-button-v2-label-min-width:var(--sd-button-label-xs-min-width, 36px);--sd-button-v2-icon-only-size:var(--sd-button-button-icon-only-xs-width, var(--sd-button-v2-height))}.sd-button-v2--sm{--sd-button-v2-height:var(--sd-button-button-sm-height, 28px);--sd-button-v2-padding-x:var(--sd-button-button-sm-padding-x, 12px);--sd-button-v2-gap:var(--sd-button-button-sm-gap, 6px);--sd-button-v2-font-family:var(--sd-button-button-sm-typography-font-family, inherit);--sd-button-v2-font-size:var(--sd-button-button-sm-typography-font-size, 12px);--sd-button-v2-font-weight:var(--sd-button-button-sm-typography-font-weight, 500);--sd-button-v2-text-decoration:var(--sd-button-button-sm-typography-text-decoration, none);--sd-button-v2-label-min-width:var(--sd-button-label-sm-min-width, 70px);--sd-button-v2-icon-only-size:var(--sd-button-button-icon-only-sm-width, var(--sd-button-v2-height))}.sd-button-v2--md{--sd-button-v2-height:var(--sd-button-button-md-height, 36px);--sd-button-v2-padding-x:var(--sd-button-button-md-padding-x, 20px);--sd-button-v2-gap:var(--sd-button-button-md-gap, 8px);--sd-button-v2-font-family:var(--sd-button-button-md-typography-font-family, inherit);--sd-button-v2-font-size:var(--sd-button-button-md-typography-font-size, 16px);--sd-button-v2-font-weight:var(--sd-button-button-md-typography-font-weight, 500);--sd-button-v2-text-decoration:var(--sd-button-button-md-typography-text-decoration, none);--sd-button-v2-label-min-width:var(--sd-button-label-md-min-width, 100px);--sd-button-v2-icon-only-size:var(--sd-button-button-icon-only-md-width, var(--sd-button-v2-height));border-radius:var(--sd-button-button-radius-md, 6px)}.sd-button-v2--lg{--sd-button-v2-height:var(--sd-button-button-lg-height, 62px);--sd-button-v2-padding-x:var(--sd-button-button-lg-padding-x, 28px);--sd-button-v2-gap:var(--sd-button-button-lg-gap, 12px);--sd-button-v2-font-family:var(--sd-button-button-lg-typography-font-family, inherit);--sd-button-v2-font-size:var(--sd-button-button-lg-typography-font-size, 18px);--sd-button-v2-font-weight:var(--sd-button-button-lg-typography-font-weight, 500);--sd-button-v2-text-decoration:var(--sd-button-button-lg-typography-text-decoration, none);--sd-button-v2-label-min-width:var(--sd-button-label-lg-min-width, 120px);--sd-button-v2-icon-only-size:var(--sd-button-button-icon-only-lg-width, var(--sd-button-v2-height));border-radius:var(--sd-button-button-radius-md, 6px)}.sd-button-v2--has-label{--sd-button-v2-min-width:var(--sd-button-v2-label-min-width, auto)}.sd-button-v2--icon-only{width:var(--sd-button-v2-icon-only-size, var(--sd-button-v2-height));min-width:var(--sd-button-v2-icon-only-size, var(--sd-button-v2-height));height:var(--sd-button-v2-icon-only-size, var(--sd-button-v2-height));padding:0}.sd-button-v2--icon-only .sd-button-v2__content{gap:0}.sd-button-v2--disabled{border-color:var(--sd-button-button-border-disabled, #CCCCCC);background:var(--sd-button-button-bg-disabled, #E1E1E1);--sd-button-v2-current-content:var(--sd-button-button-text-disabled, #888888);--sd-button-v2-current-icon:var(--sd-button-button-icon-disabled, #BBBBBB);cursor:not-allowed}.sd-button-v2 .sd-button-v2__content{display:inline-flex;align-items:center;justify-content:center;gap:var(--sd-button-v2-gap)}.sd-button-v2 .sd-button-v2__label{font:inherit}"}},[512,"sd-button-v2",{name:[1],label:[1],icon:[1],rightIcon:[1,"right-icon"],ariaLabel:[1,"aria-label"],disabled:[4],type:[1]}]);function p(){"undefined"!=typeof customElements&&["sd-button-v2","sd-icon"].forEach((t=>{switch(t){case"sd-button-v2":customElements.get(d(t))||customElements.define(d(t),c);break;case"sd-icon":customElements.get(d(t))||l()}}))}export{c as S,p as d}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{p as t,H as o,c as s,h as a,t as e}from"./p-D3gjBBCU.js";import{m as i}from"./p-DOXMJi-V.js";import{d}from"./p-B8jXOXtJ.js";import{d as n}from"./p-Dey-lS6x.js";import{d as l}from"./p-EbjZr2OA.js";import{d as m}from"./p-BppjYHF6.js";const c={positive:"primary_md",negative:"danger_md",default:"neutral_outline_md"},r={positive:"notificationOutline",negative:"warningOutline",default:null},f={positive:i.modal.confirm.positive.icon,negative:i.modal.confirm.negative.icon,default:""},b=Number(i.modal.confirm.title.icon),h=t(class extends o{constructor(t){super(),!1!==t&&this.__registerHost(),this.close=s(this,"sdClose",7),this.cancel=s(this,"sdCancel",7),this.ok=s(this,"sdOk",7)}get el(){return this}hasSlottedContent=!1;customContentRef;slotObserver;type="positive";modalTitle="";titleClass="";topMessage=[];bottomMessage=[];mainButtonName;mainButtonLabel="확인";subButtonLabel="";tagPreset="square_sm_grey";tagLabel="";slotLabel="";tagContents;close;cancel;ok;componentWillLoad(){this.syncHasSlottedContent()}componentDidLoad(){"undefined"!=typeof MutationObserver&&(this.slotObserver=new MutationObserver((()=>this.syncHasSlottedContent())),this.slotObserver.observe(this.el,{childList:!0,characterData:!0}))}componentDidRender(){this.customContentRef&&this.tagContents instanceof o&&("function"==typeof this.customContentRef.replaceChildren?this.customContentRef.replaceChildren(this.tagContents):(this.customContentRef.innerHTML="",this.customContentRef.appendChild(this.tagContents)))}disconnectedCallback(){this.slotObserver?.disconnect()}get resolvedMainButton(){return this.mainButtonName??c[this.type]}get hasTagContent(){return!(!this.tagLabel&&!this.slotLabel)}get showContentBox(){return!!this.tagContents||this.hasTagContent||this.hasSlottedContent}syncHasSlottedContent(){const t=Array.from(this.el.childNodes).some((t=>!(t.nodeType===Node.ELEMENT_NODE&&t.classList.contains("sd-confirm-modal"))&&(t.nodeType===Node.ELEMENT_NODE||t.nodeType===Node.TEXT_NODE&&t.textContent?.trim())));t!==this.hasSlottedContent&&(this.hasSlottedContent=t)}render(){const t=r[this.type],o=f[this.type];return a("div",{key:"4ef44b1b2a86914eae3fc59e3c383b12646d1d0c",class:"sd-confirm-modal"},a("sd-ghost-button",{key:"aa62624aaf76a23eb4f1d30b846e6054f3cf001c",class:"sd-confirm-modal__close-button",icon:"close",ariaLabel:"close",onClick:()=>this.close.emit()}),t&&a("sd-icon",{key:"d1329b8e71d455357790a4aa5f73547142830532",class:"sd-confirm-modal__icon",name:t,size:b,color:o}),a("h2",{key:"2c5e0f902327c5eb663e6ccc5057e22e2be11c03",class:`sd-confirm-modal__title ${this.titleClass}`},this.modalTitle),a("div",{key:"1917ef85f9f06de3dd321d664d4022dd4a1524ff",class:"sd-confirm-modal__body"},(this.topMessage??[]).length>0&&a("div",{key:"afa7e6671f4849b7a90317664d07d3c04178c554",class:"sd-confirm-modal__message"},(this.topMessage??[]).map((t=>a("p",{class:"sd-confirm-modal__message-text",innerHTML:t})))),this.showContentBox&&a("div",{key:"d4c06bfdd2222212b1cf8e3ec86ccaca4c394394",class:"sd-confirm-modal__content-box"},this.tagContents?a("div",{class:"sd-confirm-modal__custom-content",ref:t=>{this.customContentRef=t}}):a("slot",{onSlotchange:()=>this.syncHasSlottedContent()},this.tagLabel&&a("sd-tag",{name:this.tagPreset,label:this.tagLabel}),this.slotLabel&&a("span",{class:"sd-confirm-modal__slot-label"},this.slotLabel))),(this.bottomMessage??[]).length>0&&a("div",{key:"8af201f6b6b08991ba31db2f2e59ee44a7b10d50",class:"sd-confirm-modal__message"},(this.bottomMessage??[]).map((t=>a("p",{class:"sd-confirm-modal__message-text",innerHTML:t}))))),a("div",{key:"733f478a57a68bd9d4cc6563558bc0fafbfa5b9a",class:"sd-confirm-modal__button"},this.subButtonLabel&&a("sd-button-v2",{key:"a7be74a833fbd012d14e79b570a4d97e3a495a52",name:"neutral_outline_md",label:this.subButtonLabel,onSdClick:()=>this.cancel.emit()}),a("sd-button-v2",{key:"e09be98a918aafd291a7b12c221b70e72ba14ab9",name:this.resolvedMainButton,label:this.mainButtonLabel,onSdClick:()=>this.ok.emit()})))}static get style(){return"sd-confirm-modal{display:block;width:fit-content;min-width:520px}sd-confirm-modal .sd-confirm-modal{position:relative;padding:var(--sd-modal-modal-confirm-padding-y) var(--sd-modal-modal-confirm-padding-x);border-radius:var(--sd-modal-modal-radius);box-shadow:4px 4px 24px 4px rgba(0, 0, 0, 0.2);background:var(--sd-modal-modal-bg)}sd-confirm-modal .sd-confirm-modal__close-button{position:absolute;top:12px;right:12px}sd-confirm-modal .sd-confirm-modal__icon{display:block;width:var(--sd-modal-modal-confirm-title-icon);height:var(--sd-modal-modal-confirm-title-icon);margin:0 auto var(--sd-modal-modal-confirm-title-gap) auto}sd-confirm-modal .sd-confirm-modal__title{color:var(--sd-modal-modal-confirm-title-color);font-size:var(--sd-modal-modal-confirm-title-typography-font-size);font-weight:var(--sd-modal-modal-confirm-title-typography-font-weight);line-height:var(--sd-modal-modal-confirm-title-typography-line-height);text-align:center;margin:0 0 var(--sd-modal-modal-confirm-body-gap) 0}sd-confirm-modal .sd-confirm-modal__body{display:flex;flex-direction:column;gap:var(--sd-modal-modal-confirm-body-gap)}sd-confirm-modal .sd-confirm-modal__message-text{color:var(--sd-modal-modal-confirm-message-color);font-size:12px;font-weight:400;line-height:20px;text-align:center;margin:0}sd-confirm-modal .sd-confirm-modal__content-box{display:flex;align-items:center;justify-content:center;gap:8px;padding:12px 16px;border:1px solid #e1e1e1;border-radius:8px;background:white}sd-confirm-modal .sd-confirm-modal__slot-label{font-size:14px;font-weight:700;line-height:22px;color:var(--sd-modal-modal-confirm-message-color)}sd-confirm-modal .sd-confirm-modal__button{display:flex;justify-content:center;gap:var(--sd-modal-modal-confirm-button-gap);margin-top:40px}"}},[772,"sd-confirm-modal",{type:[1],modalTitle:[1,"modal-title"],titleClass:[1,"title-class"],topMessage:[16],bottomMessage:[16],mainButtonName:[1,"main-button-name"],mainButtonLabel:[1,"main-button-label"],subButtonLabel:[1,"sub-button-label"],tagPreset:[1,"tag-preset"],tagLabel:[1,"tag-label"],slotLabel:[1,"slot-label"],tagContents:[16],hasSlottedContent:[32]}]);function p(){"undefined"!=typeof customElements&&["sd-confirm-modal","sd-button-v2","sd-ghost-button","sd-icon","sd-tag"].forEach((t=>{switch(t){case"sd-confirm-modal":customElements.get(e(t))||customElements.define(e(t),h);break;case"sd-button-v2":customElements.get(e(t))||d();break;case"sd-ghost-button":customElements.get(e(t))||n();break;case"sd-icon":customElements.get(e(t))||l();break;case"sd-tag":customElements.get(e(t))||m()}}))}export{h as S,p as d}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{p as t,H as e,c as s,h as i,t as o}from"./p-D3gjBBCU.js";import{n as r}from"./p-CCwNgVmC.js";import{d as l}from"./p-dNJIFthT.js";import{d as h}from"./p-DfH_fO01.js";import{d as a}from"./p-C7DajKYn.js";import{d}from"./p-BcMNA89i.js";import{d as n}from"./p-EbjZr2OA.js";import{d as c}from"./p-q0VWISKA.js";import{d as p}from"./p-Nvx13YlG.js";import{d as u}from"./p-DegvQLTF.js";import{d as m}from"./p-xnLvZ-xn.js";import{d as b}from"./p-BmYM7-4v.js";import{d as f}from"./p-BheX6lAy.js";const g=t(class t extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.update=s(this,"sdUpdate",7),this.dropDownShow=s(this,"sdDropDownShow",7)}static VIEWPORT_PADDING=20;static PORTAL_OFFSET_Y=4;static CLOSE_ANIMATION_DURATION=150;get el(){return this}type="default";value=null;options=[];placeholder="선택";maxDropdownWidth="640px";dropdownHeight="260px";disabled=!1;label="";labelWidth="";addonLabel="";addonAlign="start";error=!1;hint="";errorMessage="";rules=[];icon=void 0;labelTooltip="";labelTooltipProps=null;emitValue=!1;width="";useSearch=!1;allSelectedLabel="전체";useSelectAll=!1;isOpen=!1;isAnimatingOut=!1;triggerWidth="200px";resolvedDropdownHeight="260px";resolvedMaxDropdownWidth="640px";focused=!1;hovered=!1;update;dropDownShow;async sdFocus(){this.disabled||await(this.triggerComponentRef?.sdFocus())}async sdOpen(){await new Promise((t=>setTimeout(t,0))),this.disabled||this.isOpen||(this.prepareDropdownGeometry(),this.closeAnimationTimer&&clearTimeout(this.closeAnimationTimer),this.isAnimatingOut=!1,this.isOpen=!0)}triggerRef;triggerComponentRef;closeAnimationTimer;name=r();triggerHasFocus=!1;watchIsOpen(t){this.syncFocusedState(t),this.dropDownShow.emit({isOpen:t})}get isMulti(){return"multi"===this.type||"multi_depth"===this.type}get displayText(){if(this.isMulti){if(!Array.isArray(this.value)||0===this.value.length)return"";const t=this.getNonDisabledLeaves(this.options),e=this.getSelectedOptions();if(t.length>0&&t.every((t=>e.some((e=>e.value===t.value)))))return this.allSelectedLabel??"전체";const s=this.flattenOptions(this.options);return this.value.map((t=>{if(null!=t&&"object"==typeof t){const e=t;return e.label??s.find((t=>t.value===e.value))?.label??""}return s.find((e=>e.value===t))?.label??""})).filter(Boolean).join(", ")}if(null==this.value)return"";if(!this.emitValue&&"object"==typeof this.value&&!Array.isArray(this.value))return this.value.label??"";const t=this.flattenOptions(this.options).find((t=>t.value===this.value));return t?.label??""}flattenOptions(t){return t.flatMap((t=>t.children?this.flattenOptions(t.children):[t]))}getNonDisabledLeaves(t){return t.flatMap((t=>t.disabled?[]:t.children?this.getNonDisabledLeaves(t.children):[t]))}getSelectedOptions(){const t=this.value;return t&&Array.isArray(t)?this.emitValue?t.map((t=>this.findOriginalOption(t,this.options))).filter((t=>!!t)):t:[]}toMultiValue(t){return this.emitValue?t.map((t=>t.value)):t}parsePixelValue(t,e){const s=Number.parseFloat(t);return Number.isFinite(s)?s:e}updateDropdownViewportConstraints(){if(!this.triggerRef)return;const e=this.triggerRef.getBoundingClientRect(),s=t.VIEWPORT_PADDING,i=t.PORTAL_OFFSET_Y,o=this.parsePixelValue(this.dropdownHeight,260),r=this.parsePixelValue(this.maxDropdownWidth,640),l=Math.max(window.innerHeight-e.bottom-s-i,0),h=Math.max(e.top-s-i,0),a=Math.max(l,h),d=Math.max(window.innerWidth-2*s,0);this.resolvedDropdownHeight=`${Math.min(o,a)}px`,this.resolvedMaxDropdownWidth=`${Math.min(r,d)}px`}handleViewportResize=()=>{this.isOpen&&this.updateDropdownViewportConstraints()};findOriginalOption(t,e){for(const s of e){if(s.value===t)return s;if(s.children){const e=this.findOriginalOption(t,s.children);if(e)return e}}}closeDropdown(){this.isOpen&&(this.isOpen=!1,this.isAnimatingOut=!0,this.closeAnimationTimer&&clearTimeout(this.closeAnimationTimer),this.closeAnimationTimer=setTimeout((()=>{this.isAnimatingOut=!1}),t.CLOSE_ANIMATION_DURATION))}prepareDropdownGeometry(){this.triggerRef&&(this.triggerWidth=`${this.triggerRef.offsetWidth}px`),this.updateDropdownViewportConstraints()}syncFocusedState(t=this.isOpen){this.focused=t||this.triggerHasFocus}handleTriggerFocus=()=>{this.triggerHasFocus=!0,this.syncFocusedState()};handleTriggerBlur=()=>{this.triggerHasFocus=!1,this.syncFocusedState()};handleTriggerClick=()=>{this.isOpen?this.closeDropdown():(this.prepareDropdownGeometry(),this.closeAnimationTimer&&clearTimeout(this.closeAnimationTimer),this.isAnimatingOut=!1,this.isOpen=!0)};emitUpdate(t){this.update.emit(t)}handleOptionSelect=t=>{const{option:e,leaves:s}=t;if(this.isMulti)this.handleMultiSelect(e,s);else{this.closeDropdown(),this.value=this.emitValue?e.value:e;const t=this.value;requestAnimationFrame((()=>{this.emitUpdate(t)}))}};handleMultiSelect(t,e){const s=this.getSelectedOptions();let i;if(t.children)if(e.every((t=>s.some((e=>e.value===t.value))))){const t=new Set(e.map((t=>t.value)));i=s.filter((e=>!t.has(e.value)))}else{const t=new Set(s.map((t=>t.value))),o=e.filter((e=>!t.has(e.value)));i=[...s,...o]}else i=s.some((e=>e.value===t.value))?s.filter((e=>e.value!==t.value)):[...s,t];this.value=this.toMultiValue(i),this.emitUpdate(this.value)}connectedCallback(){window.addEventListener("resize",this.handleViewportResize)}disconnectedCallback(){window.removeEventListener("resize",this.handleViewportResize),this.closeAnimationTimer&&clearTimeout(this.closeAnimationTimer)}render(){const e={open:this.isOpen,parentRef:this.triggerRef,viewportPadding:t.VIEWPORT_PADDING,onSdClose:()=>{this.closeDropdown()}};return i("sd-field",{key:"76625e332090d20e2f66159bba5ee1b9a11320a6",name:this.name,label:this.label,labelWidth:this.labelWidth,addonLabel:this.addonLabel,addonAlign:this.addonAlign,hint:this.hint,errorMessage:this.errorMessage,width:this.width,rules:this.rules,error:this.error,disabled:this.disabled,focused:this.focused,hovered:this.hovered,icon:this.icon,labelTooltip:this.labelTooltip,labelTooltipProps:this.labelTooltipProps,onMouseEnter:()=>{this.hovered=!0},onMouseLeave:()=>{this.hovered=!1}},i("div",{key:"8a0ae8a5e05459128409dbe21779f5e3d91b3a04",class:"sd-select",ref:t=>{this.triggerRef=t}},i("sd-select-trigger",{key:"6b47231914655a8e197e3b38cd8e37c5214efc17",ref:t=>{this.triggerComponentRef=t},displayText:this.displayText,placeholder:this.placeholder,disabled:this.disabled,isOpen:this.isOpen,onSdTriggerClick:this.handleTriggerClick,onSdTriggerFocus:this.handleTriggerFocus,onSdTriggerBlur:this.handleTriggerBlur})),(this.isOpen||this.isAnimatingOut)&&i("sd-portal",{key:"eaed402d276cc94a1324ede9cbf09bc436f8a1db",...e},i("sd-select-listbox",{key:"a96f75e06d974c8fd88ac72f083fe4b0ef424a0b",type:this.type,options:this.options,value:this.value,emitValue:this.emitValue,useSearch:this.useSearch,useSelectAll:this.useSelectAll,triggerWidth:this.triggerWidth,maxWidth:this.resolvedMaxDropdownWidth,maxHeight:this.resolvedDropdownHeight,onSdOptionSelect:t=>this.handleOptionSelect(t.detail)})))}static get watchers(){return{isOpen:[{watchIsOpen:0}]}}static get style(){return"sd-select{display:inline-flex}sd-select sd-portal{display:none}sd-select .sd-select{position:relative;width:100%;height:100%}"}},[512,"sd-select",{type:[1],value:[1032],options:[16],placeholder:[1],maxDropdownWidth:[1,"max-dropdown-width"],dropdownHeight:[1,"dropdown-height"],disabled:[4],label:[1],labelWidth:[8,"label-width"],addonLabel:[1,"addon-label"],addonAlign:[1,"addon-align"],error:[1028],hint:[1],errorMessage:[1,"error-message"],rules:[16],icon:[16],labelTooltip:[1,"label-tooltip"],labelTooltipProps:[16],emitValue:[4,"emit-value"],width:[8],useSearch:[4,"use-search"],allSelectedLabel:[1,"all-selected-label"],useSelectAll:[4,"use-select-all"],name:[1],isOpen:[32],isAnimatingOut:[32],triggerWidth:[32],resolvedDropdownHeight:[32],resolvedMaxDropdownWidth:[32],focused:[32],hovered:[32],sdFocus:[64],sdOpen:[64]},void 0,{isOpen:[{watchIsOpen:0}]}]);function w(){"undefined"!=typeof customElements&&["sd-select","sd-button","sd-checkbox","sd-field","sd-floating-portal","sd-icon","sd-portal","sd-select-list-item","sd-select-list-item-search","sd-select-listbox","sd-select-trigger","sd-tooltip"].forEach((t=>{switch(t){case"sd-select":customElements.get(o(t))||customElements.define(o(t),g);break;case"sd-button":customElements.get(o(t))||l();break;case"sd-checkbox":customElements.get(o(t))||h();break;case"sd-field":customElements.get(o(t))||a();break;case"sd-floating-portal":customElements.get(o(t))||d();break;case"sd-icon":customElements.get(o(t))||n();break;case"sd-portal":customElements.get(o(t))||c();break;case"sd-select-list-item":customElements.get(o(t))||p();break;case"sd-select-list-item-search":customElements.get(o(t))||u();break;case"sd-select-listbox":customElements.get(o(t))||m();break;case"sd-select-trigger":customElements.get(o(t))||b();break;case"sd-tooltip":customElements.get(o(t))||f()}}))}export{g as S,w as d}
|