@dubai-design-system/components-js 4.1.0 → 5.0.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/CHANGELOG.md +151 -0
- package/dist/cjs/dda-accordion.cjs.entry.js +7 -12
- package/dist/cjs/dda-alert.cjs.entry.js +21 -13
- package/dist/cjs/dda-attach-file.cjs.entry.js +27 -18
- package/dist/cjs/dda-avatar.cjs.entry.js +15 -15
- package/dist/cjs/dda-banner.cjs.entry.js +23 -0
- package/dist/cjs/dda-breadcrumb.cjs.entry.js +5 -11
- package/dist/cjs/dda-button.cjs.entry.js +6 -11
- package/dist/cjs/dda-checkbox.cjs.entry.js +5 -11
- package/dist/cjs/dda-chip.cjs.entry.js +5 -11
- package/dist/cjs/dda-credit-card.cjs.entry.js +5 -11
- package/dist/cjs/dda-creditcard-field.cjs.entry.js +23 -11
- package/dist/cjs/dda-dropdown.cjs.entry.js +5 -11
- package/dist/cjs/dda-footer.cjs.entry.js +5 -8
- package/dist/cjs/dda-header.cjs.entry.js +123 -25
- package/dist/cjs/dda-home-banner.cjs.entry.js +204 -0
- package/dist/cjs/dda-horizontal-stepper.cjs.entry.js +5 -11
- package/dist/cjs/dda-input.cjs.entry.js +23 -11
- package/dist/cjs/dda-link-button_2.cjs.entry.js +19 -22
- package/dist/cjs/dda-number-field.cjs.entry.js +20 -11
- package/dist/cjs/dda-pagination.cjs.entry.js +17 -19
- package/dist/cjs/dda-phonefield.cjs.entry.js +201 -189
- package/dist/cjs/dda-progressbar.cjs.entry.js +6 -11
- package/dist/cjs/dda-range-slider.cjs.entry.js +5 -10
- package/dist/cjs/dda-search-input.cjs.entry.js +24 -14
- package/dist/cjs/dda-segmented-tabs.cjs.entry.js +32 -13
- package/dist/cjs/dda-select.cjs.entry.js +115 -12
- package/dist/cjs/dda-sticky-footer.cjs.entry.js +21 -8
- package/dist/cjs/dda-tabs.cjs.entry.js +36 -19
- package/dist/cjs/dda-textarea.cjs.entry.js +6131 -6168
- package/dist/cjs/dda-toggle.cjs.entry.js +5 -11
- package/dist/cjs/dda-tooltip.cjs.entry.js +46 -0
- package/dist/cjs/dda-ui-card.cjs.entry.js +26 -0
- package/dist/cjs/dda-vertical-stepper.cjs.entry.js +4 -9
- package/dist/cjs/dda.cjs.js +7 -10
- package/dist/cjs/index-DGHrEPBX.js +1986 -0
- package/dist/cjs/index.cjs.js +12 -16
- package/dist/cjs/loader.cjs.js +3 -8
- package/dist/collection/assets/countries.js +179 -179
- package/dist/collection/assets/digital-logo.svg +82 -82
- package/dist/collection/assets/fonts/dubai/DubaiBold.svg +5922 -5922
- package/dist/collection/assets/fonts/dubai/DubaiLight.svg +5935 -5935
- package/dist/collection/assets/fonts/dubai/DubaiMedium.svg +5926 -5926
- package/dist/collection/assets/fonts/dubai/DubaiRegular.svg +5925 -5925
- package/dist/collection/assets/img/dda-icon-logo.svg +4 -4
- package/dist/collection/assets/img/digital-logo-white.svg +82 -82
- package/dist/collection/assets/img/digital-logo.svg +82 -82
- package/dist/collection/assets/img/icn/DubaiAI.svg +267 -267
- package/dist/collection/assets/img/icn/icn-Excel.svg +9 -9
- package/dist/collection/assets/img/icn/icn-Image.svg +6 -6
- package/dist/collection/assets/img/icn/icn-OneNote.svg +6 -6
- package/dist/collection/assets/img/icn/icn-PDF.svg +7 -7
- package/dist/collection/assets/img/icn/icn-PowerPoint.svg +10 -10
- package/dist/collection/assets/img/icn/icn-Video.svg +5 -5
- package/dist/collection/assets/img/icn/icn-Word.svg +10 -10
- package/dist/collection/assets/img/icn/icn-accessibility-dark.svg +3 -3
- package/dist/collection/assets/img/icn/icn-apple-dark.svg +3 -3
- package/dist/collection/assets/img/icn/icn-apple.svg +3 -3
- package/dist/collection/assets/img/icn/icn-chat_bubble_outline.svg +3 -3
- package/dist/collection/assets/img/icn/icn-complaints.svg +28 -28
- package/dist/collection/assets/img/icn/icn-facebook-dark.svg +4 -4
- package/dist/collection/assets/img/icn/icn-facebook.svg +11 -11
- package/dist/collection/assets/img/icn/icn-google-dark.svg +13 -13
- package/dist/collection/assets/img/icn/icn-google.svg +13 -13
- package/dist/collection/assets/img/icn/icn-grid-view.svg +3 -3
- package/dist/collection/assets/img/icn/icn-happy.svg +3 -3
- package/dist/collection/assets/img/icn/icn-instagram-dark.svg +12 -12
- package/dist/collection/assets/img/icn/icn-instagram.svg +30 -30
- package/dist/collection/assets/img/icn/icn-search-dark.svg +3 -3
- package/dist/collection/assets/img/icn/icn-user-dark.svg +3 -3
- package/dist/collection/collection-manifest.json +6 -2
- package/dist/collection/components/dda-accordion/dda-accordion.css +82 -72
- package/dist/collection/components/dda-accordion/dda-accordion.js +30 -10
- package/dist/collection/components/dda-accordion/dda-accordion.stories.js +19 -13
- package/dist/collection/components/dda-alert/dda-alert.css +148 -148
- package/dist/collection/components/dda-alert/dda-alert.js +118 -16
- package/dist/collection/components/dda-alert/dda-alert.stories.js +39 -33
- package/dist/collection/components/dda-attach-file/dda-attach-file.js +75 -23
- package/dist/collection/components/dda-attach-file/dda-attach-file.stories.js +38 -21
- package/dist/collection/components/dda-avatar/dda-avatar.css +306 -280
- package/dist/collection/components/dda-avatar/dda-avatar.js +48 -23
- package/dist/collection/components/dda-avatar/dda-avatar.stories.js +51 -43
- package/dist/collection/components/dda-banner/dda-banner.css +3 -0
- package/dist/collection/components/dda-banner/dda-banner.js +90 -0
- package/dist/collection/components/dda-breadcrumb/dda-breadcrumb.css +58 -58
- package/dist/collection/components/dda-breadcrumb/dda-breadcrumb.js +6 -7
- package/dist/collection/components/dda-breadcrumb/dda-breadcrumb.stories.js +16 -17
- package/dist/collection/components/dda-button/dda-button.js +39 -19
- package/dist/collection/components/dda-button/dda-button.stories.js +26 -17
- package/dist/collection/components/dda-checkbox/dda-checkbox.css +119 -119
- package/dist/collection/components/dda-checkbox/dda-checkbox.js +22 -23
- package/dist/collection/components/dda-checkbox/dda-checkbox.stories.js +18 -19
- package/dist/collection/components/dda-chip/dda-chip.css +113 -100
- package/dist/collection/components/dda-chip/dda-chip.js +12 -13
- package/dist/collection/components/dda-chip/dda-chip.stories.js +17 -18
- package/dist/collection/components/dda-credit-card/dda-credit-card.css +109 -103
- package/dist/collection/components/dda-credit-card/dda-credit-card.js +14 -15
- package/dist/collection/components/dda-credit-card/dda-credit-card.stories.js +14 -15
- package/dist/collection/components/dda-creditcard-field/dda-creditcard-field.js +84 -28
- package/dist/collection/components/dda-creditcard-field/dda-creditcard-field.stories.js +39 -22
- package/dist/collection/components/dda-dropdown/dda-dropdown.js +60 -23
- package/dist/collection/components/dda-dropdown/dda-dropdown.stories.js +38 -21
- package/dist/collection/components/dda-footer/dda-footer.js +21 -23
- package/dist/collection/components/dda-footer/dda-footer.stories.js +29 -30
- package/dist/collection/components/dda-header/dda-header.css +36 -0
- package/dist/collection/components/dda-header/dda-header.js +418 -26
- package/dist/collection/components/dda-header/dda-header.stories.js +151 -60
- package/dist/collection/components/dda-home-banner/dda-home-banner.js +397 -0
- package/dist/collection/components/dda-home-banner/dda-home-banner.stories.js +94 -0
- package/dist/collection/components/dda-home-banner/home-banner.css +195 -0
- package/dist/collection/components/dda-input/dda-input.js +63 -27
- package/dist/collection/components/dda-input/dda-input.stories.js +33 -21
- package/dist/collection/components/dda-link-button/dda-link-button.js +20 -21
- package/dist/collection/components/dda-link-button/dda-link-button.stories.js +16 -17
- package/dist/collection/components/dda-number-field/dda-number-field.js +99 -28
- package/dist/collection/components/dda-number-field/dda-number-field.stories.js +47 -24
- package/dist/collection/components/dda-pagination/dda-pagination.css +175 -167
- package/dist/collection/components/dda-pagination/dda-pagination.js +241 -14
- package/dist/collection/components/dda-pagination/dda-pagination.stories.js +156 -13
- package/dist/collection/components/dda-phonefield/dda-phonefield.js +120 -26
- package/dist/collection/components/dda-phonefield/dda-phonefield.stories.js +60 -20
- package/dist/collection/components/dda-progressbar/dda-progressbar.css +98 -94
- package/dist/collection/components/dda-progressbar/dda-progressbar.js +30 -10
- package/dist/collection/components/dda-progressbar/dda-progressbar.stories.js +19 -14
- package/dist/collection/components/dda-radiobutton/dda-radiobutton.css +3858 -3470
- package/dist/collection/components/dda-radiobutton/dda-radiobutton.js +22 -23
- package/dist/collection/components/dda-radiobutton/dda-radiobutton.stories.js +18 -19
- package/dist/collection/components/dda-range-slider/dda-range-slider.css +152 -136
- package/dist/collection/components/dda-range-slider/dda-range-slider.js +60 -23
- package/dist/collection/components/dda-range-slider/dda-range-slider.stories.js +34 -19
- package/dist/collection/components/dda-search-input/dda-search-input.js +116 -24
- package/dist/collection/components/dda-search-input/dda-search-input.stories.js +57 -22
- package/dist/collection/components/dda-select/dda-select.js +173 -25
- package/dist/collection/components/dda-select/dda-select.stories.js +36 -19
- package/dist/collection/components/dda-sticky-footer/dda-sticky-footer.js +161 -83
- package/dist/collection/components/dda-sticky-footer/dda-sticky-footer.stories.js +68 -56
- package/dist/collection/components/dda-tabs/dda-tabs.css +119 -119
- package/dist/collection/components/dda-tabs/dda-tabs.js +119 -21
- package/dist/collection/components/dda-tabs/dda-tabs.stories.js +42 -16
- package/dist/collection/components/dda-textarea/dda-textarea.js +116 -29
- package/dist/collection/components/dda-textarea/dda-textarea.stories.js +27 -19
- package/dist/collection/components/dda-toggle/dda-toggle.css +119 -119
- package/dist/collection/components/dda-toggle/dda-toggle.js +14 -15
- package/dist/collection/components/dda-toggle/dda-toggle.stories.js +17 -18
- package/dist/collection/components/dda-tooltip/dda-tooltip.css +146 -130
- package/dist/collection/components/dda-tooltip/dda-tooltip.js +39 -10
- package/dist/collection/components/dda-tooltip/dda-tooltip.stories.js +16 -17
- package/dist/collection/components/dda-ui-card/dda-ui-card.css +3 -0
- package/dist/collection/components/dda-ui-card/dda-ui-card.js +209 -0
- package/dist/collection/components/segmented-groups/dda-segmented-tabs/dda-segmented-tabs.css +51 -51
- package/dist/collection/components/segmented-groups/dda-segmented-tabs/dda-segmented-tabs.js +116 -12
- package/dist/collection/components/segmented-groups/dda-segmented-tabs/dda-segmented-tabs.stories.js +39 -13
- package/dist/collection/components/stepper/dda-horizontal-stepper/dda-horizontal-stepper.css +120 -108
- package/dist/collection/components/stepper/dda-horizontal-stepper/dda-horizontal-stepper.js +8 -9
- package/dist/collection/components/stepper/dda-horizontal-stepper/dda-horizontal-stepper.stories.js +19 -20
- package/dist/collection/components/stepper/dda-vertical-stepper/dda-vertical-stepper.css +112 -112
- package/dist/collection/components/stepper/dda-vertical-stepper/dda-vertical-stepper.js +7 -8
- package/dist/collection/components/stepper/dda-vertical-stepper/dda-vertical-stepper.stories.js +19 -20
- package/dist/collection/global/dda-button.css +611 -580
- package/dist/collection/global/global.css +3734 -3346
- package/dist/collection/global/input.css +676 -615
- package/dist/collection/index.js +0 -1
- package/dist/collection/utils/applyTheme.js +12 -12
- package/dist/collection/utils/contrast.js +38 -0
- package/dist/collection/utils/utils.js +0 -1
- package/dist/components/dda-accordion.js +1 -54
- package/dist/components/dda-alert.js +1 -60
- package/dist/components/dda-attach-file.js +1 -107
- package/dist/components/dda-avatar.js +1 -91
- package/dist/components/dda-banner.d.ts +11 -0
- package/dist/components/dda-banner.js +1 -0
- package/dist/components/dda-breadcrumb.js +1 -55
- package/dist/components/dda-button.js +1 -8
- package/dist/components/dda-checkbox.js +1 -60
- package/dist/components/dda-chip.js +1 -51
- package/dist/components/dda-credit-card.js +1 -54
- package/dist/components/dda-creditcard-field.js +1 -97
- package/dist/components/dda-dropdown.js +1 -86
- package/dist/components/dda-footer.js +1 -64
- package/dist/components/dda-header.js +1 -155
- package/dist/components/dda-home-banner.d.ts +11 -0
- package/dist/components/dda-home-banner.js +1 -0
- package/dist/components/dda-horizontal-stepper.js +1 -50
- package/dist/components/dda-input.js +1 -67
- package/dist/components/dda-link-button.js +1 -8
- package/dist/components/dda-number-field.js +1 -98
- package/dist/components/dda-pagination.js +1 -103
- package/dist/components/dda-phonefield.js +1 -277
- package/dist/components/dda-progressbar.js +1 -53
- package/dist/components/dda-radiobutton.js +1 -8
- package/dist/components/dda-range-slider.js +1 -80
- package/dist/components/dda-search-input.js +1 -68
- package/dist/components/dda-segmented-tabs.js +1 -50
- package/dist/components/dda-select.js +1 -76
- package/dist/components/dda-sticky-footer.js +1 -89
- package/dist/components/dda-tabs.js +1 -61
- package/dist/components/dda-textarea.js +1 -16461
- package/dist/components/dda-toggle.js +1 -54
- package/dist/components/dda-tooltip.js +1 -8
- package/dist/components/dda-ui-card.d.ts +11 -0
- package/dist/components/dda-ui-card.js +1 -0
- package/dist/components/dda-vertical-stepper.js +1 -48
- package/dist/components/index.d.ts +2 -0
- package/dist/components/index.js +1 -23
- package/dist/components/p-BaW1ewxd.js +1 -0
- package/dist/components/p-C2ufT7tL.js +1 -0
- package/dist/components/p-CbUih1OY.js +1 -0
- package/dist/components/p-Cgvws3Uk.js +1 -0
- package/dist/components/p-HakkUtRK.js +1 -0
- package/dist/dda/dda.css +20 -0
- package/dist/dda/dda.esm.js +1 -2
- package/dist/dda/index.esm.js +1 -2
- package/dist/dda/p-0b56fbcb.entry.js +1 -0
- package/dist/dda/p-1df4494d.entry.js +1 -0
- package/dist/dda/p-207c4034.entry.js +1 -0
- package/dist/dda/p-23c6a709.entry.js +1 -0
- package/dist/dda/p-2c0f4e9e.entry.js +1 -0
- package/dist/dda/p-2e4e47ec.entry.js +1 -0
- package/dist/dda/p-3b9a784a.entry.js +1 -0
- package/dist/dda/p-4400194a.entry.js +1 -0
- package/dist/dda/p-48f14688.entry.js +1 -0
- package/dist/dda/p-4aef15b0.entry.js +1 -0
- package/dist/dda/p-5d0b1fea.entry.js +1 -0
- package/dist/dda/p-6150d6ca.entry.js +1 -0
- package/dist/dda/p-6def14a1.entry.js +1 -0
- package/dist/dda/p-7c8b1191.entry.js +1 -0
- package/dist/dda/p-7eb8942f.entry.js +1 -0
- package/dist/dda/p-82dc3344.entry.js +1 -0
- package/dist/dda/p-88c5aa03.entry.js +1 -0
- package/dist/dda/p-8bbd3b3b.entry.js +1 -0
- package/dist/dda/p-96aaf2c6.entry.js +1 -0
- package/dist/dda/p-99e59635.entry.js +1 -0
- package/dist/dda/p-CfK_KUZU.js +2 -0
- package/dist/dda/p-b6096645.entry.js +1 -0
- package/dist/dda/p-b68b2d3a.entry.js +1 -0
- package/dist/dda/p-c39fc443.entry.js +1 -0
- package/dist/dda/p-cf6c7bc5.entry.js +1 -0
- package/dist/dda/p-d096ea61.entry.js +1 -0
- package/dist/dda/p-d5274874.entry.js +1 -0
- package/dist/dda/p-d606adfc.entry.js +1 -0
- package/dist/dda/p-da82dc4c.entry.js +1 -0
- package/dist/dda/p-dc72bfd8.entry.js +1 -0
- package/dist/dda/p-dec1b61c.entry.js +1 -0
- package/dist/dda/p-eb2d0c46.entry.js +1 -0
- package/dist/dda/p-f9c681e4.entry.js +1 -0
- package/dist/dda/p-fd637136.entry.js +1 -0
- package/dist/esm/dda-accordion.entry.js +7 -10
- package/dist/esm/dda-alert.entry.js +21 -11
- package/dist/esm/dda-attach-file.entry.js +27 -16
- package/dist/esm/dda-avatar.entry.js +15 -13
- package/dist/esm/dda-banner.entry.js +21 -0
- package/dist/esm/dda-breadcrumb.entry.js +5 -9
- package/dist/esm/dda-button.entry.js +6 -9
- package/dist/esm/dda-checkbox.entry.js +5 -9
- package/dist/esm/dda-chip.entry.js +5 -9
- package/dist/esm/dda-credit-card.entry.js +5 -9
- package/dist/esm/dda-creditcard-field.entry.js +23 -9
- package/dist/esm/dda-dropdown.entry.js +5 -9
- package/dist/esm/dda-footer.entry.js +6 -7
- package/dist/esm/dda-header.entry.js +123 -23
- package/dist/esm/dda-home-banner.entry.js +202 -0
- package/dist/esm/dda-horizontal-stepper.entry.js +5 -9
- package/dist/esm/dda-input.entry.js +23 -9
- package/dist/esm/dda-link-button_2.entry.js +19 -20
- package/dist/esm/dda-number-field.entry.js +20 -9
- package/dist/esm/dda-pagination.entry.js +17 -17
- package/dist/esm/dda-phonefield.entry.js +201 -187
- package/dist/esm/dda-progressbar.entry.js +6 -9
- package/dist/esm/dda-range-slider.entry.js +5 -8
- package/dist/esm/dda-search-input.entry.js +24 -12
- package/dist/esm/dda-segmented-tabs.entry.js +32 -11
- package/dist/esm/dda-select.entry.js +115 -10
- package/dist/esm/dda-sticky-footer.entry.js +22 -7
- package/dist/esm/dda-tabs.entry.js +36 -17
- package/dist/esm/dda-textarea.entry.js +6131 -6166
- package/dist/esm/dda-toggle.entry.js +5 -9
- package/dist/esm/dda-tooltip.entry.js +44 -0
- package/dist/esm/dda-ui-card.entry.js +24 -0
- package/dist/esm/dda-vertical-stepper.entry.js +4 -7
- package/dist/esm/dda.js +5 -7
- package/dist/esm/index-CfK_KUZU.js +1976 -0
- package/dist/esm/index.js +12 -14
- package/dist/esm/loader.js +3 -6
- package/dist/types/components/dda-accordion/dda-accordion.d.ts +1 -0
- package/dist/types/components/dda-accordion/dda-accordion.stories.d.ts +4 -0
- package/dist/types/components/dda-alert/dda-alert.d.ts +9 -0
- package/dist/types/components/dda-alert/dda-alert.stories.d.ts +4 -0
- package/dist/types/components/dda-attach-file/dda-attach-file.d.ts +5 -0
- package/dist/types/components/dda-attach-file/dda-attach-file.stories.d.ts +8 -0
- package/dist/types/components/dda-avatar/dda-avatar.d.ts +1 -0
- package/dist/types/components/dda-avatar/dda-avatar.stories.d.ts +6 -0
- package/dist/types/components/dda-banner/dda-banner.d.ts +13 -0
- package/dist/types/components/dda-button/dda-button.d.ts +1 -0
- package/dist/types/components/dda-button/dda-button.stories.d.ts +6 -0
- package/dist/types/components/dda-creditcard-field/dda-creditcard-field.d.ts +5 -0
- package/dist/types/components/dda-creditcard-field/dda-creditcard-field.stories.d.ts +12 -0
- package/dist/types/components/dda-dropdown/dda-dropdown.d.ts +2 -0
- package/dist/types/components/dda-dropdown/dda-dropdown.stories.d.ts +12 -0
- package/dist/types/components/dda-header/dda-header.d.ts +25 -1
- package/dist/types/components/dda-header/dda-header.stories.d.ts +62 -0
- package/dist/types/components/dda-home-banner/dda-home-banner.d.ts +56 -0
- package/dist/types/components/dda-home-banner/dda-home-banner.stories.d.ts +51 -0
- package/dist/types/components/dda-input/dda-input.d.ts +4 -0
- package/dist/types/components/dda-input/dda-input.stories.d.ts +6 -0
- package/dist/types/components/dda-number-field/dda-number-field.d.ts +6 -0
- package/dist/types/components/dda-number-field/dda-number-field.stories.d.ts +18 -0
- package/dist/types/components/dda-pagination/dda-pagination.d.ts +12 -0
- package/dist/types/components/dda-pagination/dda-pagination.stories.d.ts +72 -0
- package/dist/types/components/dda-phonefield/dda-phonefield.d.ts +7 -0
- package/dist/types/components/dda-phonefield/dda-phonefield.stories.d.ts +24 -0
- package/dist/types/components/dda-progressbar/dda-progressbar.d.ts +1 -0
- package/dist/types/components/dda-progressbar/dda-progressbar.stories.d.ts +7 -0
- package/dist/types/components/dda-range-slider/dda-range-slider.d.ts +2 -0
- package/dist/types/components/dda-range-slider/dda-range-slider.stories.d.ts +12 -0
- package/dist/types/components/dda-search-input/dda-search-input.d.ts +7 -0
- package/dist/types/components/dda-search-input/dda-search-input.stories.d.ts +24 -0
- package/dist/types/components/dda-select/dda-select.d.ts +15 -0
- package/dist/types/components/dda-select/dda-select.stories.d.ts +12 -0
- package/dist/types/components/dda-sticky-footer/dda-sticky-footer.d.ts +9 -0
- package/dist/types/components/dda-sticky-footer/dda-sticky-footer.stories.d.ts +8 -0
- package/dist/types/components/dda-tabs/dda-tabs.d.ts +8 -4
- package/dist/types/components/dda-tabs/dda-tabs.stories.d.ts +16 -0
- package/dist/types/components/dda-textarea/dda-textarea.d.ts +7 -0
- package/dist/types/components/dda-textarea/dda-textarea.stories.d.ts +6 -0
- package/dist/types/components/dda-tooltip/dda-tooltip.d.ts +6 -0
- package/dist/types/components/dda-ui-card/dda-ui-card.d.ts +13 -0
- package/dist/types/components/segmented-groups/dda-segmented-tabs/dda-segmented-tabs.d.ts +13 -0
- package/dist/types/components/segmented-groups/dda-segmented-tabs/dda-segmented-tabs.stories.d.ts +18 -0
- package/dist/types/components.d.ts +1559 -70
- package/dist/types/stencil-public-runtime.d.ts +193 -12
- package/dist/types/utils/contrast.d.ts +19 -0
- package/package.json +29 -10
- package/readme.md +80 -78
- package/LICENSE +0 -21
- package/dist/cjs/app-globals-3a1e7e63.js +0 -7
- package/dist/cjs/app-globals-3a1e7e63.js.map +0 -1
- package/dist/cjs/dda-accordion.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-alert.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-attach-file.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-avatar.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-breadcrumb.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-button.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-checkbox.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-chip.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-credit-card.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-creditcard-field.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-dropdown.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-footer.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-header.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-horizontal-stepper.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-input.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-link-button_2.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-number-field.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-pagination.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-phonefield.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-progressbar.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-radiobutton.cjs.entry.js +0 -31
- package/dist/cjs/dda-radiobutton.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-range-slider.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-search-input.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-segmented-tabs.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-select.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-sticky-footer.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-tabs.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-textarea.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-toggle.cjs.entry.js.map +0 -1
- package/dist/cjs/dda-vertical-stepper.cjs.entry.js.map +0 -1
- package/dist/cjs/dda.cjs.js.map +0 -1
- package/dist/cjs/index-a2fa4928.js +0 -1619
- package/dist/cjs/index-a2fa4928.js.map +0 -1
- package/dist/cjs/index.cjs.js.map +0 -1
- package/dist/cjs/loader.cjs.js.map +0 -1
- package/dist/collection/components/dda-accordion/dda-accordion.js.map +0 -1
- package/dist/collection/components/dda-accordion/dda-accordion.stories.js.map +0 -1
- package/dist/collection/components/dda-alert/dda-alert.js.map +0 -1
- package/dist/collection/components/dda-alert/dda-alert.stories.js.map +0 -1
- package/dist/collection/components/dda-attach-file/dda-attach-file.js.map +0 -1
- package/dist/collection/components/dda-attach-file/dda-attach-file.stories.js.map +0 -1
- package/dist/collection/components/dda-avatar/dda-avatar.js.map +0 -1
- package/dist/collection/components/dda-avatar/dda-avatar.stories.js.map +0 -1
- package/dist/collection/components/dda-breadcrumb/dda-breadcrumb.js.map +0 -1
- package/dist/collection/components/dda-breadcrumb/dda-breadcrumb.stories.js.map +0 -1
- package/dist/collection/components/dda-button/dda-button.js.map +0 -1
- package/dist/collection/components/dda-button/dda-button.stories.js.map +0 -1
- package/dist/collection/components/dda-checkbox/dda-checkbox.js.map +0 -1
- package/dist/collection/components/dda-checkbox/dda-checkbox.stories.js.map +0 -1
- package/dist/collection/components/dda-chip/dda-chip.js.map +0 -1
- package/dist/collection/components/dda-chip/dda-chip.stories.js.map +0 -1
- package/dist/collection/components/dda-credit-card/dda-credit-card.js.map +0 -1
- package/dist/collection/components/dda-credit-card/dda-credit-card.stories.js.map +0 -1
- package/dist/collection/components/dda-creditcard-field/dda-creditcard-field.js.map +0 -1
- package/dist/collection/components/dda-creditcard-field/dda-creditcard-field.stories.js.map +0 -1
- package/dist/collection/components/dda-dropdown/dda-dropdown.js.map +0 -1
- package/dist/collection/components/dda-dropdown/dda-dropdown.stories.js.map +0 -1
- package/dist/collection/components/dda-footer/dda-footer.js.map +0 -1
- package/dist/collection/components/dda-footer/dda-footer.stories.js.map +0 -1
- package/dist/collection/components/dda-header/dda-header.js.map +0 -1
- package/dist/collection/components/dda-header/dda-header.stories.js.map +0 -1
- package/dist/collection/components/dda-input/dda-input.js.map +0 -1
- package/dist/collection/components/dda-input/dda-input.stories.js.map +0 -1
- package/dist/collection/components/dda-link-button/dda-link-button.js.map +0 -1
- package/dist/collection/components/dda-link-button/dda-link-button.stories.js.map +0 -1
- package/dist/collection/components/dda-number-field/dda-number-field.js.map +0 -1
- package/dist/collection/components/dda-number-field/dda-number-field.stories.js.map +0 -1
- package/dist/collection/components/dda-pagination/dda-pagination.js.map +0 -1
- package/dist/collection/components/dda-pagination/dda-pagination.stories.js.map +0 -1
- package/dist/collection/components/dda-phonefield/dda-phonefield.js.map +0 -1
- package/dist/collection/components/dda-phonefield/dda-phonefield.stories.js.map +0 -1
- package/dist/collection/components/dda-progressbar/dda-progressbar.js.map +0 -1
- package/dist/collection/components/dda-progressbar/dda-progressbar.stories.js.map +0 -1
- package/dist/collection/components/dda-radiobutton/dda-radiobutton.js.map +0 -1
- package/dist/collection/components/dda-radiobutton/dda-radiobutton.stories.js.map +0 -1
- package/dist/collection/components/dda-range-slider/dda-range-slider.js.map +0 -1
- package/dist/collection/components/dda-range-slider/dda-range-slider.stories.js.map +0 -1
- package/dist/collection/components/dda-search-input/dda-search-input.js.map +0 -1
- package/dist/collection/components/dda-search-input/dda-search-input.stories.js.map +0 -1
- package/dist/collection/components/dda-select/dda-select.js.map +0 -1
- package/dist/collection/components/dda-select/dda-select.stories.js.map +0 -1
- package/dist/collection/components/dda-sticky-footer/dda-sticky-footer.js.map +0 -1
- package/dist/collection/components/dda-sticky-footer/dda-sticky-footer.stories.js.map +0 -1
- package/dist/collection/components/dda-tabs/dda-tabs.js.map +0 -1
- package/dist/collection/components/dda-tabs/dda-tabs.stories.js.map +0 -1
- package/dist/collection/components/dda-textarea/dda-textarea.js.map +0 -1
- package/dist/collection/components/dda-textarea/dda-textarea.stories.js.map +0 -1
- package/dist/collection/components/dda-toggle/dda-toggle.js.map +0 -1
- package/dist/collection/components/dda-toggle/dda-toggle.stories.js.map +0 -1
- package/dist/collection/components/dda-tooltip/dda-tooltip.js.map +0 -1
- package/dist/collection/components/dda-tooltip/dda-tooltip.stories.js.map +0 -1
- package/dist/collection/components/segmented-groups/dda-segmented-tabs/dda-segmented-tabs.js.map +0 -1
- package/dist/collection/components/segmented-groups/dda-segmented-tabs/dda-segmented-tabs.stories.js.map +0 -1
- package/dist/collection/components/stepper/dda-horizontal-stepper/dda-horizontal-stepper.js.map +0 -1
- package/dist/collection/components/stepper/dda-horizontal-stepper/dda-horizontal-stepper.stories.js.map +0 -1
- package/dist/collection/components/stepper/dda-vertical-stepper/dda-vertical-stepper.js.map +0 -1
- package/dist/collection/components/stepper/dda-vertical-stepper/dda-vertical-stepper.stories.js.map +0 -1
- package/dist/collection/index.js.map +0 -1
- package/dist/collection/utils/utils.js.map +0 -1
- package/dist/components/dda-accordion.js.map +0 -1
- package/dist/components/dda-alert.js.map +0 -1
- package/dist/components/dda-attach-file.js.map +0 -1
- package/dist/components/dda-avatar.js.map +0 -1
- package/dist/components/dda-breadcrumb.js.map +0 -1
- package/dist/components/dda-button.js.map +0 -1
- package/dist/components/dda-checkbox.js.map +0 -1
- package/dist/components/dda-chip.js.map +0 -1
- package/dist/components/dda-credit-card.js.map +0 -1
- package/dist/components/dda-creditcard-field.js.map +0 -1
- package/dist/components/dda-dropdown.js.map +0 -1
- package/dist/components/dda-footer.js.map +0 -1
- package/dist/components/dda-header.js.map +0 -1
- package/dist/components/dda-horizontal-stepper.js.map +0 -1
- package/dist/components/dda-input.js.map +0 -1
- package/dist/components/dda-link-button.js.map +0 -1
- package/dist/components/dda-number-field.js.map +0 -1
- package/dist/components/dda-pagination.js.map +0 -1
- package/dist/components/dda-phonefield.js.map +0 -1
- package/dist/components/dda-progressbar.js.map +0 -1
- package/dist/components/dda-radiobutton.js.map +0 -1
- package/dist/components/dda-range-slider.js.map +0 -1
- package/dist/components/dda-search-input.js.map +0 -1
- package/dist/components/dda-segmented-tabs.js.map +0 -1
- package/dist/components/dda-select.js.map +0 -1
- package/dist/components/dda-sticky-footer.js.map +0 -1
- package/dist/components/dda-tabs.js.map +0 -1
- package/dist/components/dda-textarea.js.map +0 -1
- package/dist/components/dda-toggle.js.map +0 -1
- package/dist/components/dda-tooltip.js.map +0 -1
- package/dist/components/dda-vertical-stepper.js.map +0 -1
- package/dist/components/index.js.map +0 -1
- package/dist/components/p-562afefe.js +0 -73
- package/dist/components/p-562afefe.js.map +0 -1
- package/dist/components/p-6f74eccd.js +0 -1422
- package/dist/components/p-6f74eccd.js.map +0 -1
- package/dist/components/p-96fcc6bd.js +0 -54
- package/dist/components/p-96fcc6bd.js.map +0 -1
- package/dist/components/p-ad0417cc.js +0 -44
- package/dist/components/p-ad0417cc.js.map +0 -1
- package/dist/components/p-f15e5894.js +0 -76
- package/dist/components/p-f15e5894.js.map +0 -1
- package/dist/dda/dda.esm.js.map +0 -1
- package/dist/dda/index.esm.js.map +0 -1
- package/dist/dda/p-01b4ec07.entry.js +0 -2
- package/dist/dda/p-01b4ec07.entry.js.map +0 -1
- package/dist/dda/p-231440d1.entry.js +0 -2
- package/dist/dda/p-231440d1.entry.js.map +0 -1
- package/dist/dda/p-2e604126.entry.js +0 -2
- package/dist/dda/p-2e604126.entry.js.map +0 -1
- package/dist/dda/p-31699358.entry.js +0 -2
- package/dist/dda/p-31699358.entry.js.map +0 -1
- package/dist/dda/p-33561c6d.entry.js +0 -2
- package/dist/dda/p-33561c6d.entry.js.map +0 -1
- package/dist/dda/p-36561409.entry.js +0 -2
- package/dist/dda/p-36561409.entry.js.map +0 -1
- package/dist/dda/p-3c099577.entry.js +0 -2
- package/dist/dda/p-3c099577.entry.js.map +0 -1
- package/dist/dda/p-3cdb54c4.entry.js +0 -2
- package/dist/dda/p-3cdb54c4.entry.js.map +0 -1
- package/dist/dda/p-3d5608f7.entry.js +0 -2
- package/dist/dda/p-3d5608f7.entry.js.map +0 -1
- package/dist/dda/p-3fffdb8b.entry.js +0 -2
- package/dist/dda/p-3fffdb8b.entry.js.map +0 -1
- package/dist/dda/p-466f931b.entry.js +0 -2
- package/dist/dda/p-466f931b.entry.js.map +0 -1
- package/dist/dda/p-4d0d3545.entry.js +0 -2
- package/dist/dda/p-4d0d3545.entry.js.map +0 -1
- package/dist/dda/p-511fae4e.entry.js +0 -2
- package/dist/dda/p-511fae4e.entry.js.map +0 -1
- package/dist/dda/p-540284f3.entry.js +0 -2
- package/dist/dda/p-540284f3.entry.js.map +0 -1
- package/dist/dda/p-578b6d01.entry.js +0 -2
- package/dist/dda/p-578b6d01.entry.js.map +0 -1
- package/dist/dda/p-6b401fde.js +0 -3
- package/dist/dda/p-6b401fde.js.map +0 -1
- package/dist/dda/p-8c970299.entry.js +0 -2
- package/dist/dda/p-8c970299.entry.js.map +0 -1
- package/dist/dda/p-8ffca988.entry.js +0 -2
- package/dist/dda/p-8ffca988.entry.js.map +0 -1
- package/dist/dda/p-9c619a7a.entry.js +0 -2
- package/dist/dda/p-9c619a7a.entry.js.map +0 -1
- package/dist/dda/p-9c693b51.entry.js +0 -2
- package/dist/dda/p-9c693b51.entry.js.map +0 -1
- package/dist/dda/p-a5b7698d.entry.js +0 -2
- package/dist/dda/p-a5b7698d.entry.js.map +0 -1
- package/dist/dda/p-a83fa6d1.entry.js +0 -2
- package/dist/dda/p-a83fa6d1.entry.js.map +0 -1
- package/dist/dda/p-ade2b279.entry.js +0 -2
- package/dist/dda/p-ade2b279.entry.js.map +0 -1
- package/dist/dda/p-aec2f087.entry.js +0 -2
- package/dist/dda/p-aec2f087.entry.js.map +0 -1
- package/dist/dda/p-bf69dfab.entry.js +0 -2
- package/dist/dda/p-bf69dfab.entry.js.map +0 -1
- package/dist/dda/p-ccf23fd7.entry.js +0 -2
- package/dist/dda/p-ccf23fd7.entry.js.map +0 -1
- package/dist/dda/p-d6a16216.entry.js +0 -2
- package/dist/dda/p-d6a16216.entry.js.map +0 -1
- package/dist/dda/p-dbba8d56.entry.js +0 -2
- package/dist/dda/p-dbba8d56.entry.js.map +0 -1
- package/dist/dda/p-e1255160.js +0 -2
- package/dist/dda/p-e1255160.js.map +0 -1
- package/dist/dda/p-e4d6f6cb.entry.js +0 -2
- package/dist/dda/p-e4d6f6cb.entry.js.map +0 -1
- package/dist/dda/p-e550c988.entry.js +0 -2
- package/dist/dda/p-e550c988.entry.js.map +0 -1
- package/dist/dda/p-ed0795e7.entry.js +0 -2
- package/dist/dda/p-ed0795e7.entry.js.map +0 -1
- package/dist/esm/app-globals-0f993ce5.js +0 -5
- package/dist/esm/app-globals-0f993ce5.js.map +0 -1
- package/dist/esm/dda-accordion.entry.js.map +0 -1
- package/dist/esm/dda-alert.entry.js.map +0 -1
- package/dist/esm/dda-attach-file.entry.js.map +0 -1
- package/dist/esm/dda-avatar.entry.js.map +0 -1
- package/dist/esm/dda-breadcrumb.entry.js.map +0 -1
- package/dist/esm/dda-button.entry.js.map +0 -1
- package/dist/esm/dda-checkbox.entry.js.map +0 -1
- package/dist/esm/dda-chip.entry.js.map +0 -1
- package/dist/esm/dda-credit-card.entry.js.map +0 -1
- package/dist/esm/dda-creditcard-field.entry.js.map +0 -1
- package/dist/esm/dda-dropdown.entry.js.map +0 -1
- package/dist/esm/dda-footer.entry.js.map +0 -1
- package/dist/esm/dda-header.entry.js.map +0 -1
- package/dist/esm/dda-horizontal-stepper.entry.js.map +0 -1
- package/dist/esm/dda-input.entry.js.map +0 -1
- package/dist/esm/dda-link-button_2.entry.js.map +0 -1
- package/dist/esm/dda-number-field.entry.js.map +0 -1
- package/dist/esm/dda-pagination.entry.js.map +0 -1
- package/dist/esm/dda-phonefield.entry.js.map +0 -1
- package/dist/esm/dda-progressbar.entry.js.map +0 -1
- package/dist/esm/dda-radiobutton.entry.js +0 -27
- package/dist/esm/dda-radiobutton.entry.js.map +0 -1
- package/dist/esm/dda-range-slider.entry.js.map +0 -1
- package/dist/esm/dda-search-input.entry.js.map +0 -1
- package/dist/esm/dda-segmented-tabs.entry.js.map +0 -1
- package/dist/esm/dda-select.entry.js.map +0 -1
- package/dist/esm/dda-sticky-footer.entry.js.map +0 -1
- package/dist/esm/dda-tabs.entry.js.map +0 -1
- package/dist/esm/dda-textarea.entry.js.map +0 -1
- package/dist/esm/dda-toggle.entry.js.map +0 -1
- package/dist/esm/dda-vertical-stepper.entry.js.map +0 -1
- package/dist/esm/dda.js.map +0 -1
- package/dist/esm/index-be8c716a.js +0 -1590
- package/dist/esm/index-be8c716a.js.map +0 -1
- package/dist/esm/index.js.map +0 -1
- package/dist/esm/loader.js.map +0 -1
- package/loader/package.json +0 -11
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
type CustomMethodDecorator<T> = (target: object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<T> | void;
|
|
2
|
+
type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends (k: infer I) => void ? I : never;
|
|
3
|
+
type MixinInstance<F> = F extends (base: MixedInCtor) => MixedInCtor<infer I> ? I : never;
|
|
2
4
|
export interface ComponentDecorator {
|
|
3
5
|
(opts?: ComponentOptions): ClassDecorator;
|
|
4
6
|
}
|
|
@@ -61,6 +63,12 @@ export interface ShadowRootOptions {
|
|
|
61
63
|
* focusable part is given focus, and the shadow host is given any available `:focus` styling.
|
|
62
64
|
*/
|
|
63
65
|
delegatesFocus?: boolean;
|
|
66
|
+
/**
|
|
67
|
+
* Sets the slot assignment mode for the shadow root. When set to `'manual'`, enables imperative
|
|
68
|
+
* slotting using the `HTMLSlotElement.assign()` method. Defaults to `'named'` for standard
|
|
69
|
+
* declarative slotting behavior.
|
|
70
|
+
*/
|
|
71
|
+
slotAssignment?: 'manual' | 'named';
|
|
64
72
|
}
|
|
65
73
|
export interface ModeStyles {
|
|
66
74
|
[modeName: string]: string | string[];
|
|
@@ -117,12 +125,34 @@ export interface EventOptions {
|
|
|
117
125
|
*/
|
|
118
126
|
composed?: boolean;
|
|
119
127
|
}
|
|
128
|
+
export interface AttachInternalsOptions {
|
|
129
|
+
/**
|
|
130
|
+
* Initial custom states to set on the ElementInternals.states CustomStateSet.
|
|
131
|
+
* Each key is the state name and the value is the initial boolean state.
|
|
132
|
+
*
|
|
133
|
+
* These states can be targeted with the CSS `:state()` pseudo-class.
|
|
134
|
+
*
|
|
135
|
+
* @example
|
|
136
|
+
* ```tsx
|
|
137
|
+
* @AttachInternals({ states: { open: true, active: false } })
|
|
138
|
+
* internals: ElementInternals;
|
|
139
|
+
* ```
|
|
140
|
+
*
|
|
141
|
+
* @see https://developer.mozilla.org/en-US/docs/Web/API/CustomStateSet
|
|
142
|
+
*/
|
|
143
|
+
states?: {
|
|
144
|
+
[stateName: string]: boolean;
|
|
145
|
+
};
|
|
146
|
+
}
|
|
120
147
|
export interface AttachInternalsDecorator {
|
|
121
|
-
(): PropertyDecorator;
|
|
148
|
+
(opts?: AttachInternalsOptions): PropertyDecorator;
|
|
122
149
|
}
|
|
123
150
|
export interface ListenDecorator {
|
|
124
151
|
(eventName: string, opts?: ListenOptions): CustomMethodDecorator<any>;
|
|
125
152
|
}
|
|
153
|
+
export interface ResolveVarFunction {
|
|
154
|
+
<T>(variable: T): string;
|
|
155
|
+
}
|
|
126
156
|
export interface ListenOptions {
|
|
127
157
|
/**
|
|
128
158
|
* Handlers can also be registered for an event other than the host itself.
|
|
@@ -151,7 +181,15 @@ export interface StateDecorator {
|
|
|
151
181
|
(): PropertyDecorator;
|
|
152
182
|
}
|
|
153
183
|
export interface WatchDecorator {
|
|
154
|
-
(propName:
|
|
184
|
+
(propName: any, watchOptions?: {
|
|
185
|
+
immediate?: boolean;
|
|
186
|
+
}): CustomMethodDecorator<(newValue?: any, oldValue?: any, propName?: any, ...args: any[]) => any | void>;
|
|
187
|
+
}
|
|
188
|
+
export interface PropSerializeDecorator {
|
|
189
|
+
(propName: any): CustomMethodDecorator<(newValue?: any, propName?: string, ...args: any[]) => string | null>;
|
|
190
|
+
}
|
|
191
|
+
export interface AttrDeserializeDecorator {
|
|
192
|
+
(propName: any): CustomMethodDecorator<(newValue?: any, propName?: string, ...args: any[]) => any>;
|
|
155
193
|
}
|
|
156
194
|
export interface UserBuildConditionals {
|
|
157
195
|
isDev: boolean;
|
|
@@ -200,6 +238,24 @@ export declare const AttachInternals: AttachInternalsDecorator;
|
|
|
200
238
|
* https://stenciljs.com/docs/events#listen-decorator
|
|
201
239
|
*/
|
|
202
240
|
export declare const Listen: ListenDecorator;
|
|
241
|
+
/**
|
|
242
|
+
* The `resolveVar()` function is a compile-time utility that resolves const variables
|
|
243
|
+
* and object properties to their string literal values. This allows variables to be
|
|
244
|
+
* used in `@Listen` and `@Event` decorators instead of hardcoded strings.
|
|
245
|
+
*
|
|
246
|
+
* @example
|
|
247
|
+
* ```ts
|
|
248
|
+
* const MY_EVENT = 'myEvent';
|
|
249
|
+
* @Listen(resolveVar(MY_EVENT))
|
|
250
|
+
* ```
|
|
251
|
+
*
|
|
252
|
+
* @example
|
|
253
|
+
* ```ts
|
|
254
|
+
* const EVENTS = { MY_EVENT: 'myEvent' } as const;
|
|
255
|
+
* @Event({ eventName: resolveVar(EVENTS.MY_EVENT) })
|
|
256
|
+
* ```
|
|
257
|
+
*/
|
|
258
|
+
export declare const resolveVar: ResolveVarFunction;
|
|
203
259
|
/**
|
|
204
260
|
* The `@Method()` decorator is used to expose methods on the public API.
|
|
205
261
|
* Class methods decorated with the @Method() decorator can be called directly
|
|
@@ -233,6 +289,14 @@ export declare const State: StateDecorator;
|
|
|
233
289
|
* https://stenciljs.com/docs/reactive-data#watch-decorator
|
|
234
290
|
*/
|
|
235
291
|
export declare const Watch: WatchDecorator;
|
|
292
|
+
/**
|
|
293
|
+
* Decorator to serialize a property to an attribute string.
|
|
294
|
+
*/
|
|
295
|
+
export declare const PropSerialize: PropSerializeDecorator;
|
|
296
|
+
/**
|
|
297
|
+
* Decorator to deserialize an attribute string to a property.
|
|
298
|
+
*/
|
|
299
|
+
export declare const AttrDeserialize: AttrDeserializeDecorator;
|
|
236
300
|
export type ResolutionHandler = (elm: HTMLElement) => string | undefined | null;
|
|
237
301
|
export type ErrorHandler = (err: any, element?: HTMLElement) => void;
|
|
238
302
|
/**
|
|
@@ -260,6 +324,25 @@ export declare function setPlatformHelpers(helpers: {
|
|
|
260
324
|
* @returns the base path
|
|
261
325
|
*/
|
|
262
326
|
export declare function getAssetPath(path: string): string;
|
|
327
|
+
/**
|
|
328
|
+
* Method to render a virtual DOM tree to a container element.
|
|
329
|
+
*
|
|
330
|
+
* @example
|
|
331
|
+
* ```tsx
|
|
332
|
+
* import { render } from '@stencil/core';
|
|
333
|
+
*
|
|
334
|
+
* const vnode = (
|
|
335
|
+
* <div>
|
|
336
|
+
* <h1>Hello, world!</h1>
|
|
337
|
+
* </div>
|
|
338
|
+
* );
|
|
339
|
+
* render(vnode, document.body);
|
|
340
|
+
* ```
|
|
341
|
+
*
|
|
342
|
+
* @param vnode - The virtual DOM tree to render
|
|
343
|
+
* @param container - The container element to render the virtual DOM tree to
|
|
344
|
+
*/
|
|
345
|
+
export declare function render(vnode: VNode, container: Element): void;
|
|
263
346
|
/**
|
|
264
347
|
* Used to manually set the base path where assets can be found. For lazy-loaded
|
|
265
348
|
* builds the asset path is automatically set and assets copied to the correct
|
|
@@ -330,6 +413,58 @@ export declare function readTask(task: RafCallback): void;
|
|
|
330
413
|
* Unhandled exception raised while rendering, during event handling, or lifecycles will trigger the custom event handler.
|
|
331
414
|
*/
|
|
332
415
|
export declare const setErrorHandler: (handler: ErrorHandler) => void;
|
|
416
|
+
export type TagTransformer = (tag: string) => string;
|
|
417
|
+
/**
|
|
418
|
+
* Sets a tag transformer to be used when rendering your custom elements.
|
|
419
|
+
* ```ts
|
|
420
|
+
* setTagTransformer((tag) => {
|
|
421
|
+
* if (tag.startsWith('my-')) return `new-${tag}`
|
|
422
|
+
* return tag;
|
|
423
|
+
* });
|
|
424
|
+
* ```
|
|
425
|
+
* Will mean all your components that start with `my-` are defined instead with `new-my-` prefix.
|
|
426
|
+
*
|
|
427
|
+
* @param transformer the transformer function to use which must return a string.
|
|
428
|
+
*/
|
|
429
|
+
export declare function setTagTransformer(transformer: TagTransformer): void;
|
|
430
|
+
/**
|
|
431
|
+
* Transforms a tag name using a transformer set via `setTagTransformer`
|
|
432
|
+
*
|
|
433
|
+
* @param tag - the tag to transform e.g. `my-tag`
|
|
434
|
+
* @returns the transformed tag e.g. `new-my-tag`
|
|
435
|
+
*/
|
|
436
|
+
export declare function transformTag(tag: string): string;
|
|
437
|
+
/**
|
|
438
|
+
* @deprecated - Use `MixedInCtor` instead:
|
|
439
|
+
* ```ts
|
|
440
|
+
* import { MixedInCtor } from '@stencil/core';
|
|
441
|
+
*
|
|
442
|
+
* const AFactoryFn = <B extends MixedInCtor>(Base: B) => {class A extends Base { propA = A }; return A;}
|
|
443
|
+
* ```
|
|
444
|
+
*/
|
|
445
|
+
export type MixinFactory = (base: MixedInCtor) => MixedInCtor;
|
|
446
|
+
export type MixedInCtor<T = {}> = new (...args: any[]) => T;
|
|
447
|
+
/**
|
|
448
|
+
* Compose multiple mixin classes into a single constructor.
|
|
449
|
+
* The resulting class has the combined instance types of all mixed-in classes.
|
|
450
|
+
*
|
|
451
|
+
* Example:
|
|
452
|
+
* ```ts
|
|
453
|
+
* import { Mixin, MixedInCtor } from '@stencil/core';
|
|
454
|
+
*
|
|
455
|
+
* const AWrap = <B extends MixedInCtor>(Base: B) => {class A extends Base { propA = A }; return A;}
|
|
456
|
+
* const BWrap = <B extends MixedInCtor>(Base: B) => {class B extends Base { propB = B }; return B;}
|
|
457
|
+
* const CWrap = <B extends MixedInCtor>(Base: B) => {class C extends Base { propC = C }; return C;}
|
|
458
|
+
*
|
|
459
|
+
* class X extends Mixin(AWrap, BWrap, CWrap) {
|
|
460
|
+
* render() { return <div>{this.propA} {this.propB} {this.propC}</div>; }
|
|
461
|
+
* }
|
|
462
|
+
* ```
|
|
463
|
+
*
|
|
464
|
+
* @param mixinFactories mixin factory functions that return a class which extends from the provided class.
|
|
465
|
+
* @returns a class that is composed from extending each of the provided classes in the order they were provided.
|
|
466
|
+
*/
|
|
467
|
+
export declare function Mixin<const TMixins extends readonly MixinFactory[]>(...mixinFactories: TMixins): abstract new (...args: any[]) => UnionToIntersection<MixinInstance<TMixins[number]>>;
|
|
333
468
|
/**
|
|
334
469
|
* This file gets copied to all distributions of stencil component collections.
|
|
335
470
|
* - no imports
|
|
@@ -502,7 +637,7 @@ export interface FunctionalUtilities {
|
|
|
502
637
|
map: (children: VNode[], cb: (vnode: ChildNode, index: number, array: ChildNode[]) => ChildNode) => VNode[];
|
|
503
638
|
}
|
|
504
639
|
export interface FunctionalComponent<T = {}> {
|
|
505
|
-
(props: T, children: VNode[], utils: FunctionalUtilities): VNode | VNode[];
|
|
640
|
+
(props: T, children: VNode[], utils: FunctionalUtilities): VNode | VNode[] | null;
|
|
506
641
|
}
|
|
507
642
|
/**
|
|
508
643
|
* A Child VDOM node
|
|
@@ -544,6 +679,7 @@ export declare namespace h {
|
|
|
544
679
|
function h(sel: any, data: VNodeData | null, text: string): VNode;
|
|
545
680
|
function h(sel: any, data: VNodeData | null, children: Array<VNode | undefined | null>): VNode;
|
|
546
681
|
function h(sel: any, data: VNodeData | null, children: VNode): VNode;
|
|
682
|
+
function h(sel: any, data: VNodeData | null, ...children: (VNode | string | number)[]): VNode;
|
|
547
683
|
namespace JSX {
|
|
548
684
|
interface IntrinsicElements extends LocalJSX.IntrinsicElements, JSXBase.IntrinsicElements {
|
|
549
685
|
[tagName: string]: any;
|
|
@@ -558,6 +694,36 @@ export declare function h(sel: any, children: Array<VNode | undefined | null>):
|
|
|
558
694
|
export declare function h(sel: any, data: VNodeData | null, text: string): VNode;
|
|
559
695
|
export declare function h(sel: any, data: VNodeData | null, children: Array<VNode | undefined | null>): VNode;
|
|
560
696
|
export declare function h(sel: any, data: VNodeData | null, children: VNode): VNode;
|
|
697
|
+
export declare function h(sel: any, data: VNodeData | null, ...children: (VNode | string | number)[]): VNode;
|
|
698
|
+
/**
|
|
699
|
+
* Automatic JSX runtime functions for TypeScript's react-jsx mode.
|
|
700
|
+
* These functions are called automatically by TypeScript when using "jsx": "react-jsx".
|
|
701
|
+
* @param type type of node
|
|
702
|
+
* @param props properties of node
|
|
703
|
+
* @param key optional key for the node
|
|
704
|
+
* @returns a jsx vnode
|
|
705
|
+
*/
|
|
706
|
+
export declare function jsx(type: any, props: any, key?: string): VNode;
|
|
707
|
+
/**
|
|
708
|
+
* Automatic JSX runtime functions for TypeScript's react-jsxmode with multiple children.
|
|
709
|
+
* @param type type of node
|
|
710
|
+
* @param props properties of node
|
|
711
|
+
* @param key optional key for the node
|
|
712
|
+
* @returns a jsx vnode
|
|
713
|
+
*/
|
|
714
|
+
export declare function jsxs(type: any, props: any, key?: string): VNode;
|
|
715
|
+
/**
|
|
716
|
+
* Automatic JSX runtime functions for TypeScript's react-jsxdev mode.
|
|
717
|
+
* These functions are called automatically by TypeScript when using "jsx": "react-jsxdev".
|
|
718
|
+
* @param type type of node
|
|
719
|
+
* @param props properties of node
|
|
720
|
+
* @param key optional key for the node
|
|
721
|
+
* @param isStaticChildren indicates if the children are static
|
|
722
|
+
* @param source source information
|
|
723
|
+
* @param self reference to the component instance
|
|
724
|
+
* @returns a jsx vnode
|
|
725
|
+
*/
|
|
726
|
+
export declare function jsxDEV(type: any, props: any, key?: string | number, isStaticChildren?: boolean, source?: any, self?: any): VNode;
|
|
561
727
|
/**
|
|
562
728
|
* A virtual DOM node
|
|
563
729
|
*/
|
|
@@ -587,7 +753,7 @@ declare namespace LocalJSX {
|
|
|
587
753
|
export { LocalJSX as JSX };
|
|
588
754
|
export declare namespace JSXBase {
|
|
589
755
|
interface IntrinsicElements {
|
|
590
|
-
slot: JSXBase.SlotAttributes
|
|
756
|
+
slot: JSXBase.SlotAttributes<HTMLSlotElement>;
|
|
591
757
|
a: JSXBase.AnchorHTMLAttributes<HTMLAnchorElement>;
|
|
592
758
|
abbr: JSXBase.HTMLAttributes;
|
|
593
759
|
address: JSXBase.HTMLAttributes;
|
|
@@ -757,7 +923,7 @@ export declare namespace JSXBase {
|
|
|
757
923
|
use: JSXBase.SVGAttributes;
|
|
758
924
|
view: JSXBase.SVGAttributes;
|
|
759
925
|
}
|
|
760
|
-
interface SlotAttributes extends JSXAttributes {
|
|
926
|
+
interface SlotAttributes<T = HTMLSlotElement> extends JSXAttributes<T> {
|
|
761
927
|
name?: string;
|
|
762
928
|
slot?: string;
|
|
763
929
|
onSlotchange?: (event: Event) => void;
|
|
@@ -813,6 +979,9 @@ export declare namespace JSXBase {
|
|
|
813
979
|
popoverTargetAction?: string;
|
|
814
980
|
popoverTargetElement?: Element | null;
|
|
815
981
|
popoverTarget?: string;
|
|
982
|
+
command?: string;
|
|
983
|
+
commandFor?: string;
|
|
984
|
+
commandfor?: string;
|
|
816
985
|
}
|
|
817
986
|
interface CanvasHTMLAttributes<T> extends HTMLAttributes<T> {
|
|
818
987
|
height?: number | string;
|
|
@@ -826,7 +995,8 @@ export declare namespace JSXBase {
|
|
|
826
995
|
}
|
|
827
996
|
interface DetailsHTMLAttributes<T> extends HTMLAttributes<T> {
|
|
828
997
|
open?: boolean;
|
|
829
|
-
|
|
998
|
+
name?: string;
|
|
999
|
+
onToggle?: (event: ToggleEvent) => void;
|
|
830
1000
|
}
|
|
831
1001
|
interface DelHTMLAttributes<T> extends HTMLAttributes<T> {
|
|
832
1002
|
cite?: string;
|
|
@@ -900,6 +1070,7 @@ export declare namespace JSXBase {
|
|
|
900
1070
|
importance?: 'low' | 'auto' | 'high';
|
|
901
1071
|
height?: number | string;
|
|
902
1072
|
loading?: 'lazy' | 'auto' | 'eager';
|
|
1073
|
+
referrerPolicy?: ReferrerPolicy;
|
|
903
1074
|
sizes?: string;
|
|
904
1075
|
src?: string;
|
|
905
1076
|
srcSet?: string;
|
|
@@ -1532,6 +1703,13 @@ export declare namespace JSXBase {
|
|
|
1532
1703
|
z?: number | string;
|
|
1533
1704
|
zoomAndPan?: string;
|
|
1534
1705
|
}
|
|
1706
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ToggleEvent) */
|
|
1707
|
+
interface ToggleEvent extends Event {
|
|
1708
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ToggleEvent/newState) */
|
|
1709
|
+
readonly newState: string;
|
|
1710
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ToggleEvent/oldState) */
|
|
1711
|
+
readonly oldState: string;
|
|
1712
|
+
}
|
|
1535
1713
|
interface DOMAttributes<T> extends JSXAttributes<T> {
|
|
1536
1714
|
slot?: string;
|
|
1537
1715
|
part?: string;
|
|
@@ -1548,6 +1726,10 @@ export declare namespace JSXBase {
|
|
|
1548
1726
|
onCompositionstartCapture?: (event: CompositionEvent) => void;
|
|
1549
1727
|
onCompositionupdate?: (event: CompositionEvent) => void;
|
|
1550
1728
|
onCompositionupdateCapture?: (event: CompositionEvent) => void;
|
|
1729
|
+
onBeforeToggle?: (event: ToggleEvent) => void;
|
|
1730
|
+
onBeforeToggleCapture?: (event: ToggleEvent) => void;
|
|
1731
|
+
onToggle?: (event: ToggleEvent) => void;
|
|
1732
|
+
onToggleCapture?: (event: ToggleEvent) => void;
|
|
1551
1733
|
onFocus?: (event: FocusEvent) => void;
|
|
1552
1734
|
onFocusCapture?: (event: FocusEvent) => void;
|
|
1553
1735
|
onFocusin?: (event: FocusEvent) => void;
|
|
@@ -1566,10 +1748,6 @@ export declare namespace JSXBase {
|
|
|
1566
1748
|
onSubmitCapture?: (event: Event) => void;
|
|
1567
1749
|
onInvalid?: (event: Event) => void;
|
|
1568
1750
|
onInvalidCapture?: (event: Event) => void;
|
|
1569
|
-
onBeforeToggle?: (event: Event) => void;
|
|
1570
|
-
onBeforeToggleCapture?: (event: Event) => void;
|
|
1571
|
-
onToggle?: (event: Event) => void;
|
|
1572
|
-
onToggleCapture?: (event: Event) => void;
|
|
1573
1751
|
onLoad?: (event: Event) => void;
|
|
1574
1752
|
onLoadCapture?: (event: Event) => void;
|
|
1575
1753
|
onError?: (event: Event) => void;
|
|
@@ -1581,7 +1759,7 @@ export declare namespace JSXBase {
|
|
|
1581
1759
|
onKeyUp?: (event: KeyboardEvent) => void;
|
|
1582
1760
|
onKeyUpCapture?: (event: KeyboardEvent) => void;
|
|
1583
1761
|
onAuxClick?: (event: MouseEvent) => void;
|
|
1584
|
-
onClick?: (event:
|
|
1762
|
+
onClick?: (event: PointerEvent) => void;
|
|
1585
1763
|
onClickCapture?: (event: MouseEvent) => void;
|
|
1586
1764
|
onContextMenu?: (event: MouseEvent) => void;
|
|
1587
1765
|
onContextMenuCapture?: (event: MouseEvent) => void;
|
|
@@ -1661,6 +1839,8 @@ export declare namespace JSXBase {
|
|
|
1661
1839
|
onTransitionRunCapture?: (event: TransitionEvent) => void;
|
|
1662
1840
|
onTransitionStart?: (event: TransitionEvent) => void;
|
|
1663
1841
|
onTransitionStartCapture?: (event: TransitionEvent) => void;
|
|
1842
|
+
[key: `aria-${string}`]: string | boolean | undefined;
|
|
1843
|
+
[key: `aria${string}`]: string | boolean | undefined;
|
|
1664
1844
|
}
|
|
1665
1845
|
}
|
|
1666
1846
|
export interface JSXAttributes<T = Element> {
|
|
@@ -1671,6 +1851,7 @@ export interface CustomElementsDefineOptions {
|
|
|
1671
1851
|
exclude?: string[];
|
|
1672
1852
|
resourcesUrl?: string;
|
|
1673
1853
|
syncQueue?: boolean;
|
|
1854
|
+
/** @deprecated in-favour of `setTagTransformer` and `transformTag` */
|
|
1674
1855
|
transformTagName?: (tagName: string) => string;
|
|
1675
1856
|
jmp?: (c: Function) => any;
|
|
1676
1857
|
raf?: (c: FrameRequestCallback) => number;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
interface Rgb {
|
|
2
|
+
r: number;
|
|
3
|
+
g: number;
|
|
4
|
+
b: number;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Parses a CSS color string as returned by `getComputedStyle()`
|
|
8
|
+
* (`rgb(r, g, b)` or `rgba(r, g, b, a)`) into its channel values.
|
|
9
|
+
*/
|
|
10
|
+
export declare function parseRgb(color: string): Rgb;
|
|
11
|
+
/** WCAG relative luminance, 0 (black) to 1 (white). */
|
|
12
|
+
export declare function relativeLuminance({ r, g, b }: Rgb): number;
|
|
13
|
+
/**
|
|
14
|
+
* WCAG contrast ratio between two colors, each either a `getComputedStyle()`
|
|
15
|
+
* color string or a pre-parsed { r, g, b }. Order doesn't matter — the
|
|
16
|
+
* lighter color is always treated as the numerator, per spec.
|
|
17
|
+
*/
|
|
18
|
+
export declare function contrastRatio(a: string | Rgb, b: string | Rgb): number;
|
|
19
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dubai-design-system/components-js",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "JavaScript package for the Digital Dubai Design System, offering reusable, customizable components for seamless integration into web applications",
|
|
6
6
|
"main": "dist/index.cjs.js",
|
|
@@ -11,7 +11,6 @@
|
|
|
11
11
|
"unpkg": "dist/stencil/stencil.esm.js",
|
|
12
12
|
"exports": {
|
|
13
13
|
".": {
|
|
14
|
-
"types": "./dist/types/index.d.ts",
|
|
15
14
|
"import": "./dist/stencil/stencil.esm.js",
|
|
16
15
|
"require": "./dist/stencil/stencil.cjs.js"
|
|
17
16
|
},
|
|
@@ -34,7 +33,8 @@
|
|
|
34
33
|
},
|
|
35
34
|
"files": [
|
|
36
35
|
"dist/",
|
|
37
|
-
"loader/"
|
|
36
|
+
"loader/",
|
|
37
|
+
"CHANGELOG.md"
|
|
38
38
|
],
|
|
39
39
|
"scripts": {
|
|
40
40
|
"build": "stencil build",
|
|
@@ -44,16 +44,27 @@
|
|
|
44
44
|
"generate": "stencil generate",
|
|
45
45
|
"storybook": "storybook dev -p 6006",
|
|
46
46
|
"build-storybook": "storybook build",
|
|
47
|
-
"release": "standard-version"
|
|
47
|
+
"release": "standard-version",
|
|
48
|
+
"lint": "eslint src",
|
|
49
|
+
"lint:report": "eslint src -f json -o ../../docs/a11y/eslint-report.json",
|
|
50
|
+
"format:check": "prettier --check \"src/**/*.{ts,tsx,css}\"",
|
|
51
|
+
"format": "prettier --write \"src/**/*.{ts,tsx,css}\"",
|
|
52
|
+
"check:api": "node scripts/check-api-consistency.mjs",
|
|
53
|
+
"check:api:test": "node --test scripts/check-api-consistency.test.mjs",
|
|
54
|
+
"test:a11y": "test-storybook --url http://127.0.0.1:6006",
|
|
55
|
+
"test:a11y:ci": "concurrently -k -s first -n SB,TEST \"http-server storybook-static --port 6006 --silent\" \"wait-on tcp:127.0.0.1:6006 && npm run test:a11y\""
|
|
48
56
|
},
|
|
49
57
|
"dependencies": {
|
|
50
58
|
"chromatic": "^11.11.0",
|
|
59
|
+
"material-icons": "^1.13.14",
|
|
60
|
+
"material-symbols": "^0.28.2",
|
|
51
61
|
"quill": "^2.0.2",
|
|
52
62
|
"react-markdown": "^9.0.1"
|
|
53
63
|
},
|
|
54
64
|
"devDependencies": {
|
|
65
|
+
"@eslint/js": "^9.39.5",
|
|
55
66
|
"@stencil/angular-output-target": "^0.10.2",
|
|
56
|
-
"@stencil/core": "
|
|
67
|
+
"@stencil/core": "4.43.5",
|
|
57
68
|
"@stencil/react-output-target": "^0.8.2",
|
|
58
69
|
"@stencil/vue-output-target": "^0.8.8",
|
|
59
70
|
"@storybook/addon-a11y": "^8.2.7",
|
|
@@ -64,23 +75,31 @@
|
|
|
64
75
|
"@storybook/addons": "^7.6.17",
|
|
65
76
|
"@storybook/blocks": "^8.1.11",
|
|
66
77
|
"@storybook/test": "^8.2.7",
|
|
78
|
+
"@storybook/test-runner": "^0.19.1",
|
|
67
79
|
"@storybook/web-components": "^8.1.11",
|
|
68
80
|
"@storybook/web-components-webpack5": "^8.1.11",
|
|
69
81
|
"@types/jest": "^29.5.6",
|
|
70
82
|
"@types/node": "^16.18.11",
|
|
71
83
|
"@whitespace/storybook-addon-html": "^6.1.1",
|
|
84
|
+
"axe-playwright": "^2.2.2",
|
|
85
|
+
"concurrently": "^8.2.2",
|
|
86
|
+
"eslint": "^9.39.5",
|
|
87
|
+
"eslint-plugin-jsx-a11y": "^6.10.2",
|
|
88
|
+
"http-server": "^14.1.1",
|
|
72
89
|
"jest": "^29.7.0",
|
|
73
90
|
"jest-cli": "^29.7.0",
|
|
74
91
|
"lit": "^3.1.4",
|
|
75
|
-
"prettier": "^3.
|
|
92
|
+
"prettier": "^3.9.6",
|
|
76
93
|
"puppeteer": "^21.9.0",
|
|
77
94
|
"react-syntax-highlighter": "^15.5.0",
|
|
78
95
|
"standard-version": "^9.5.0",
|
|
79
|
-
"storybook": "^8.1.11"
|
|
96
|
+
"storybook": "^8.1.11",
|
|
97
|
+
"typescript-eslint": "^8.67.0",
|
|
98
|
+
"wait-on": "^7.2.0"
|
|
80
99
|
},
|
|
81
100
|
"publishConfig": {
|
|
82
|
-
"access": "
|
|
101
|
+
"access": "public"
|
|
83
102
|
},
|
|
84
|
-
"license": "
|
|
85
|
-
"gitHead": "
|
|
103
|
+
"license": "UNLICENSED",
|
|
104
|
+
"gitHead": "c37cc307e4f1c8f618fd09aed47c782f644c0908"
|
|
86
105
|
}
|
package/readme.md
CHANGED
|
@@ -1,78 +1,80 @@
|
|
|
1
|
-
<p align="center">
|
|
2
|
-
<a href="#">
|
|
3
|
-
<img alt="dda-logo" src="https://www.digitaldubai.ae/ResourcePackages/Theme/assets/dist/images/logo.svg" width="60">
|
|
4
|
-
</a>
|
|
5
|
-
</p>
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
<dda-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
1
|
+
<p align="center">
|
|
2
|
+
<a href="#">
|
|
3
|
+
<img alt="dda-logo" src="https://www.digitaldubai.ae/ResourcePackages/Theme/assets/dist/images/logo.svg" width="60">
|
|
4
|
+
</a>
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<h1 align="center">
|
|
8
|
+
Dubai Design System — Web Components
|
|
9
|
+
</h1>
|
|
10
|
+
|
|
11
|
+
Framework-agnostic web components built with StencilJS as part of the Dubai Design System (DDA). Use them in any HTML, JavaScript, or TypeScript project — no dependency on React, Angular, or Vue.
|
|
12
|
+
|
|
13
|
+
Framework wrappers are also available: [`@dubai-design-system/components-react`](https://www.npmjs.com/package/@dubai-design-system/components-react), [`@dubai-design-system/components-vue`](https://www.npmjs.com/package/@dubai-design-system/components-vue), and [`@dubai-design-system/components-angular`](https://www.npmjs.com/package/@dubai-design-system/components-angular).
|
|
14
|
+
|
|
15
|
+
#### Key features
|
|
16
|
+
|
|
17
|
+
- **Lightweight & fast** — native Web Components with lazy loading.
|
|
18
|
+
- **Customizable** — aligned with Dubai Design System branding, with light and dark themes.
|
|
19
|
+
- **Framework-agnostic** — works in plain HTML or with any framework.
|
|
20
|
+
- **Accessible & responsive** — follows accessibility best practices.
|
|
21
|
+
|
|
22
|
+
## Setup
|
|
23
|
+
|
|
24
|
+
### 1. Add the icon fonts
|
|
25
|
+
|
|
26
|
+
DDA components use Material Icons and Material Symbols. Add both inside your `<head>` tag:
|
|
27
|
+
|
|
28
|
+
```html
|
|
29
|
+
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
|
|
30
|
+
<link href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200" rel="stylesheet">
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### 2. Load the components
|
|
34
|
+
|
|
35
|
+
**Option A — CDN (no build step).** Add this script to your HTML, replacing `X.X.X` with the [latest published version](https://www.npmjs.com/package/@dubai-design-system/components-js). **Always pin an exact version in the CDN URL** — unversioned jsdelivr URLs resolve each file independently, so the loader and its chunks can come from different package versions, which breaks rendering:
|
|
36
|
+
|
|
37
|
+
```html
|
|
38
|
+
<script type="module">
|
|
39
|
+
import { defineCustomElements } from "https://cdn.jsdelivr.net/npm/@dubai-design-system/components-js@X.X.X/loader/index.es2017.js";
|
|
40
|
+
|
|
41
|
+
defineCustomElements();
|
|
42
|
+
</script>
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
**Option B — npm with a bundler (Vite, Rollup).** Install the package:
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
npm i @dubai-design-system/components-js
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Then import the self-registering build for each component you use:
|
|
52
|
+
|
|
53
|
+
```js
|
|
54
|
+
// each import automatically defines its custom element
|
|
55
|
+
import '@dubai-design-system/components-js/dist/components/dda-button.js';
|
|
56
|
+
import '@dubai-design-system/components-js/dist/components/dda-header.js';
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
> ⚠️ With Vite or plain Rollup, do **not** use the lazy loader (`@dubai-design-system/components-js/loader`). Its computed dynamic imports cannot be statically analyzed by these bundlers, so component chunks are missing from the build (404 on `dda-*.entry.js`) and components never render. The CDN approach and Angular's builder are unaffected.
|
|
60
|
+
|
|
61
|
+
### 3. Use the components
|
|
62
|
+
|
|
63
|
+
```html
|
|
64
|
+
<dda-button
|
|
65
|
+
button_color="default-primary"
|
|
66
|
+
start_icon="sentiment_satisfied"
|
|
67
|
+
end_icon="arrow_forward"
|
|
68
|
+
button_id="button"
|
|
69
|
+
aria_label="button"
|
|
70
|
+
onclick="console.log('clicked')"
|
|
71
|
+
>Button</dda-button>
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## Available components
|
|
75
|
+
|
|
76
|
+
`dda-button`, `dda-dropdown`, `dda-modal`, `dda-card`, `dda-header`, and more.
|
|
77
|
+
|
|
78
|
+
## License
|
|
79
|
+
|
|
80
|
+
Copyright (c) 2018-2026 Digital Dubai. All rights reserved. An open-source license is under review and will be announced in a future release.
|
package/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2018
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"file":"app-globals-3a1e7e63.js","mappings":";;AAAY,MAAC,aAAa,GAAG,MAAM;;;;","names":[],"sources":["@stencil/core/internal/app-globals"],"sourcesContent":["export const globalScripts = () => {};\n"],"version":3}
|