@uh-design-system/component-library 0.5.2 → 0.6.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/{utils-3412cbed.js → attributes-BMbXzbwU.js} +2 -28
- package/dist/cjs/component-library.cjs.js +7 -7
- package/dist/cjs/controlUtils-ofqiQxRF.js +42 -0
- package/dist/cjs/ds-accordion.cjs.entry.js +79 -0
- package/dist/cjs/ds-button.cjs.entry.js +107 -0
- package/dist/cjs/ds-card.cjs.entry.js +58 -0
- package/dist/cjs/ds-checkbox-group.cjs.entry.js +109 -49
- package/dist/cjs/ds-checkbox.cjs.entry.js +88 -79
- package/dist/cjs/ds-icon.cjs.entry.js +943 -0
- package/dist/cjs/ds-input-validity.cjs.entry.js +14 -15
- package/dist/cjs/ds-link-with-arrow.cjs.entry.js +21 -20
- package/dist/cjs/ds-link.cjs.entry.js +34 -31
- package/dist/cjs/ds-radio-button-group.cjs.entry.js +153 -0
- package/dist/cjs/ds-radio-button.cjs.entry.js +151 -0
- package/dist/cjs/ds-spinner.cjs.entry.js +62 -0
- package/dist/cjs/ds-text-input.cjs.entry.js +90 -77
- package/dist/cjs/ds-visually-hidden.cjs.entry.js +3 -6
- package/dist/cjs/index-Bp6Dd2i1.js +94 -0
- package/dist/cjs/{store-9bd20f3c.js → index-DwLFyR5p.js} +6 -2
- package/dist/cjs/{index-bf84b124.js → index-Mjp9Y-Sw.js} +701 -55
- package/dist/cjs/index.cjs.js +3 -5
- package/dist/cjs/{linkUtils-695da37c.js → linkUtils-onlbgKdI.js} +4 -2
- package/dist/cjs/loader.cjs.js +3 -5
- package/dist/cjs/utils-BjZTECpy.js +29 -0
- package/dist/collection/accessibility/stories/naming.stories.js +3 -3
- package/dist/collection/collection-manifest.json +78 -3
- package/dist/collection/components/01-base-components/ds-accordion/ds-accordion.css +18 -17
- package/dist/collection/components/01-base-components/ds-accordion/ds-accordion.js +91 -50
- package/dist/collection/components/01-base-components/ds-accordion/stories/ds-accordion.examples.stories.js +6 -6
- package/dist/collection/components/01-base-components/ds-accordion/stories/ds-accordion.features.stories.js +14 -14
- package/dist/collection/components/01-base-components/ds-accordion/stories/ds-accordion.stories.js +24 -66
- package/dist/collection/components/01-base-components/ds-button/ds-button.css +124 -145
- package/dist/collection/components/01-base-components/ds-button/ds-button.js +150 -65
- package/dist/collection/components/01-base-components/ds-button/stories/ds-button.examples.stories.js +121 -23
- package/dist/collection/components/01-base-components/ds-button/stories/ds-button.features.stories.js +49 -42
- package/dist/collection/components/01-base-components/ds-button/stories/ds-button.stories.js +16 -72
- package/dist/collection/components/01-base-components/ds-card/ds-card.css +127 -0
- package/dist/collection/components/01-base-components/ds-card/ds-card.js +303 -0
- package/dist/collection/components/01-base-components/ds-card/stories/ds-card.examples.stories.js +92 -0
- package/dist/collection/components/01-base-components/ds-card/stories/ds-card.features.stories.js +66 -0
- package/dist/collection/components/01-base-components/ds-card/stories/ds-card.stories.js +71 -0
- package/dist/collection/components/01-base-components/ds-checkbox/ds-checkbox.css +46 -46
- package/dist/collection/components/01-base-components/ds-checkbox/ds-checkbox.js +120 -111
- package/dist/collection/components/01-base-components/ds-checkbox/stories/ds-checkbox.features.stories.js +20 -20
- package/dist/collection/components/01-base-components/ds-checkbox/stories/ds-checkbox.stories.js +12 -25
- package/dist/collection/components/01-base-components/ds-checkbox-group/ds-checkbox-group.css +2 -3
- package/dist/collection/components/01-base-components/ds-checkbox-group/ds-checkbox-group.js +214 -63
- package/dist/collection/components/01-base-components/ds-checkbox-group/stories/ds-checkbox-group.features.stories.js +215 -50
- package/dist/collection/components/01-base-components/ds-checkbox-group/stories/ds-checkbox-group.stories.js +30 -28
- package/dist/collection/components/01-base-components/ds-icon/ds-icon.js +36 -31
- package/dist/collection/components/01-base-components/ds-icon/stories/ds-icon.stories.js +10 -37
- package/dist/collection/components/01-base-components/ds-input-validity/ds-input-validity.css +2 -2
- package/dist/collection/components/01-base-components/ds-input-validity/ds-input-validity.js +60 -30
- package/dist/collection/components/01-base-components/ds-input-validity/stories/ds-input-validity.features.stories.js +4 -4
- package/dist/collection/components/01-base-components/ds-input-validity/stories/ds-input-validity.stories.js +4 -9
- package/dist/collection/components/01-base-components/ds-link/ds-link.css +24 -14
- package/dist/collection/components/01-base-components/ds-link/ds-link.js +74 -75
- package/dist/collection/components/01-base-components/ds-link/stories/ds-link.examples.stories.js +27 -27
- package/dist/collection/components/01-base-components/ds-link/stories/ds-link.features.stories.js +38 -21
- package/dist/collection/components/01-base-components/ds-link/stories/ds-link.stories.js +8 -67
- package/dist/collection/components/01-base-components/ds-link-with-arrow/ds-link-with-arrow.css +10 -12
- package/dist/collection/components/01-base-components/ds-link-with-arrow/ds-link-with-arrow.js +30 -52
- package/dist/collection/components/01-base-components/ds-link-with-arrow/stories/ds-link-with-arrow.examples.stories.js +4 -4
- package/dist/collection/components/01-base-components/ds-link-with-arrow/stories/ds-link-with-arrow.features.stories.js +6 -6
- package/dist/collection/components/01-base-components/ds-link-with-arrow/stories/ds-link-with-arrow.stories.js +4 -28
- package/dist/collection/components/01-base-components/ds-radio-button/ds-radio-button.css +115 -0
- package/dist/collection/components/01-base-components/ds-radio-button/ds-radio-button.js +449 -0
- package/dist/collection/components/01-base-components/ds-radio-button/stories/ds-radio-button.features.stories.js +72 -0
- package/dist/collection/components/01-base-components/ds-radio-button/stories/ds-radio-button.stories.js +22 -0
- package/dist/collection/components/01-base-components/ds-radio-button-group/ds-radio-button-group.css +30 -0
- package/dist/collection/components/01-base-components/ds-radio-button-group/ds-radio-button-group.js +360 -0
- package/dist/collection/components/01-base-components/ds-radio-button-group/stories/ds-radio-button-group.examples.stories.js +42 -0
- package/dist/collection/components/01-base-components/ds-radio-button-group/stories/ds-radio-button-group.features.stories.js +71 -0
- package/dist/collection/components/01-base-components/ds-radio-button-group/stories/ds-radio-button-group.stories.js +60 -0
- package/dist/collection/components/01-base-components/ds-spinner/ds-spinner.css +279 -0
- package/dist/collection/components/01-base-components/ds-spinner/ds-spinner.js +221 -0
- package/dist/collection/components/01-base-components/ds-spinner/stories/ds-spinner.examples.stories.js +120 -0
- package/dist/collection/components/01-base-components/ds-spinner/stories/ds-spinner.features.stories.js +107 -0
- package/dist/collection/components/01-base-components/ds-spinner/stories/ds-spinner.stories.js +14 -0
- package/dist/collection/components/01-base-components/ds-text-input/ds-text-input.css +85 -118
- package/dist/collection/components/01-base-components/ds-text-input/ds-text-input.js +230 -155
- package/dist/collection/components/01-base-components/ds-text-input/stories/ds-text-input.examples.stories.js +26 -21
- package/dist/collection/components/01-base-components/ds-text-input/stories/ds-text-input.features.stories.js +40 -40
- package/dist/collection/components/01-base-components/ds-text-input/stories/ds-text-input.stories.js +30 -56
- package/dist/collection/components/01-base-components/ds-visually-hidden/ds-visually-hidden.js +1 -1
- package/dist/collection/store.js +7 -1
- package/dist/collection/utils/attributes/attributes.js +2 -2
- package/dist/collection/utils/button/buttonUtils.js +14 -0
- package/dist/collection/utils/colours/colourTypes.js +3 -3
- package/dist/collection/utils/colours/colourUtils.js +5 -3
- package/dist/collection/utils/controls/controlUtils.js +35 -1
- package/dist/collection/utils/link/linkUtils.js +3 -2
- package/dist/collection/utils/spinner/spinnerUtils.js +20 -0
- package/dist/collection/utils/tests/testUtils.js +1 -0
- package/dist/collection/utils/typography/typographyUtils.js +3 -3
- package/dist/collection/utils/utils.js +10 -9
- package/dist/component-library/{utils-cfc536bc.js → attributes-BD_lNRxn.js} +1 -1
- package/dist/component-library/component-library.css +1 -1
- package/dist/component-library/component-library.esm.js +1 -1
- package/dist/component-library/controlUtils-CNER0MvM.js +1 -0
- package/dist/component-library/ds-accordion.entry.js +1 -0
- package/dist/component-library/ds-button.entry.js +1 -0
- package/dist/component-library/ds-card.entry.js +1 -0
- package/dist/component-library/ds-checkbox-group.entry.js +1 -1
- package/dist/component-library/ds-checkbox.entry.js +1 -1
- package/dist/component-library/ds-icon.entry.js +1 -0
- package/dist/component-library/ds-input-validity.entry.js +1 -1
- package/dist/component-library/ds-link-with-arrow.entry.js +1 -1
- package/dist/component-library/ds-link.entry.js +1 -1
- package/dist/component-library/ds-radio-button-group.entry.js +1 -0
- package/dist/component-library/ds-radio-button.entry.js +1 -0
- package/dist/component-library/ds-spinner.entry.js +1 -0
- package/dist/component-library/ds-text-input.entry.js +1 -1
- package/dist/component-library/ds-visually-hidden.entry.js +1 -1
- package/dist/component-library/index-BfTCfPZ1.js +6 -0
- package/dist/component-library/index-Cm7V4EAn.js +2 -0
- package/dist/component-library/index-DuYjhvTn.js +1 -0
- package/dist/component-library/index.esm.js +1 -1
- package/dist/component-library/linkUtils-02nCfO0F.js +1 -0
- package/dist/component-library/utils-CqaqnfY4.js +1 -0
- package/dist/components/attributes.js +3 -3
- package/dist/components/controlUtils.js +35 -2
- package/dist/components/ds-accordion.js +58 -42
- package/dist/components/ds-button2.js +78 -39
- package/dist/components/ds-card.d.ts +11 -0
- package/dist/components/ds-card.js +91 -0
- package/dist/components/ds-checkbox-group.js +116 -56
- package/dist/components/ds-checkbox2.js +93 -80
- package/dist/components/ds-icon2.js +292 -292
- package/dist/components/ds-input-validity2.js +17 -14
- package/dist/components/ds-link-with-arrow.js +22 -22
- package/dist/components/ds-link.js +43 -40
- package/dist/components/ds-radio-button-group.d.ts +11 -0
- package/dist/components/ds-radio-button-group.js +185 -0
- package/dist/components/ds-radio-button.d.ts +11 -0
- package/dist/components/ds-radio-button.js +198 -0
- package/dist/components/ds-spinner.d.ts +11 -0
- package/dist/components/ds-spinner.js +6 -0
- package/dist/components/ds-spinner2.js +89 -0
- package/dist/components/ds-text-input.js +126 -104
- package/dist/components/ds-visually-hidden2.js +2 -3
- package/dist/components/index.js +208 -2
- package/dist/components/index2.js +713 -39
- package/dist/components/index3.js +69 -57
- package/dist/components/linkUtils.js +4 -2
- package/dist/docs.d.ts +443 -0
- package/dist/docs.json +4790 -0
- package/dist/esm/{utils-cfc536bc.js → attributes-BD_lNRxn.js} +3 -26
- package/dist/esm/component-library.js +6 -5
- package/dist/esm/controlUtils-CNER0MvM.js +37 -0
- package/dist/esm/ds-accordion.entry.js +77 -0
- package/dist/esm/ds-button.entry.js +105 -0
- package/dist/esm/ds-card.entry.js +56 -0
- package/dist/esm/ds-checkbox-group.entry.js +108 -46
- package/dist/esm/ds-checkbox.entry.js +78 -67
- package/dist/esm/ds-icon.entry.js +941 -0
- package/dist/esm/ds-input-validity.entry.js +14 -13
- package/dist/esm/ds-link-with-arrow.entry.js +21 -18
- package/dist/esm/ds-link.entry.js +34 -29
- package/dist/esm/ds-radio-button-group.entry.js +151 -0
- package/dist/esm/ds-radio-button.entry.js +149 -0
- package/dist/esm/ds-spinner.entry.js +60 -0
- package/dist/esm/ds-text-input.entry.js +88 -73
- package/dist/esm/ds-visually-hidden.entry.js +3 -4
- package/dist/esm/index-BfTCfPZ1.js +92 -0
- package/dist/esm/{index-434995e1.js → index-Cm7V4EAn.js} +699 -34
- package/dist/{components/store.js → esm/index-DuYjhvTn.js} +6 -3
- package/dist/esm/index.js +2 -2
- package/dist/esm/{linkUtils-3d1b28cf.js → linkUtils-02nCfO0F.js} +4 -2
- package/dist/esm/loader.js +4 -4
- package/dist/esm/utils-CqaqnfY4.js +25 -0
- package/dist/hydrate/index.d.ts +271 -0
- package/dist/hydrate/index.js +22280 -0
- package/dist/hydrate/index.mjs +22272 -0
- package/dist/hydrate/package.json +12 -0
- package/dist/styles/helpers.css +15 -0
- package/dist/styles/helpers.css.map +1 -0
- package/dist/styles/mixins/_breakpoints.scss +13 -0
- package/dist/styles/mixins/_focus.scss +26 -0
- package/dist/styles/mixins/_wrapper.scss +5 -0
- package/dist/styles/mixins/imports-default/_imports.scss +2 -0
- package/dist/styles/mixins/tokens/_breakpoints.scss +13 -0
- package/dist/styles/mixins/tokens/_semantic-colours.scss +75 -0
- package/dist/styles/mixins.scss +12 -0
- package/dist/styles/variables.css +176 -0
- package/dist/styles/variables.css.map +1 -0
- package/dist/types/components/01-base-components/ds-accordion/ds-accordion.d.ts +11 -8
- package/dist/types/components/01-base-components/ds-button/ds-button.d.ts +16 -11
- package/dist/types/components/01-base-components/ds-button/stories/ds-button.examples.stories.d.ts +1 -0
- package/dist/types/components/01-base-components/ds-button/stories/ds-button.features.stories.d.ts +1 -0
- package/dist/types/components/01-base-components/ds-card/ds-card.d.ts +20 -0
- package/dist/types/components/01-base-components/ds-card/stories/ds-card.examples.stories.d.ts +8 -0
- package/dist/types/components/01-base-components/ds-card/stories/ds-card.features.stories.d.ts +8 -0
- package/dist/types/components/01-base-components/ds-card/stories/ds-card.stories.d.ts +7 -0
- package/dist/types/components/01-base-components/ds-checkbox/ds-checkbox.d.ts +21 -22
- package/dist/types/components/01-base-components/ds-checkbox-group/ds-checkbox-group.d.ts +21 -11
- package/dist/types/components/01-base-components/ds-checkbox-group/stories/ds-checkbox-group.features.stories.d.ts +3 -0
- package/dist/types/components/01-base-components/ds-icon/ds-icon.d.ts +7 -5
- package/dist/types/components/01-base-components/ds-input-validity/ds-input-validity.d.ts +5 -6
- package/dist/types/components/01-base-components/ds-link/ds-link.d.ts +13 -14
- package/dist/types/components/01-base-components/ds-link/stories/ds-link.features.stories.d.ts +2 -0
- package/dist/types/components/01-base-components/ds-link-with-arrow/ds-link-with-arrow.d.ts +5 -7
- package/dist/types/components/01-base-components/ds-radio-button/ds-radio-button.d.ts +44 -0
- package/dist/types/components/01-base-components/ds-radio-button/stories/ds-radio-button.features.stories.d.ts +15 -0
- package/dist/types/components/01-base-components/ds-radio-button/stories/ds-radio-button.stories.d.ts +7 -0
- package/dist/types/components/01-base-components/ds-radio-button-group/ds-radio-button-group.d.ts +34 -0
- package/dist/types/components/01-base-components/ds-radio-button-group/stories/ds-radio-button-group.examples.stories.d.ts +6 -0
- package/dist/types/components/01-base-components/ds-radio-button-group/stories/ds-radio-button-group.features.stories.d.ts +11 -0
- package/dist/types/components/01-base-components/ds-radio-button-group/stories/ds-radio-button-group.stories.d.ts +7 -0
- package/dist/types/components/01-base-components/ds-spinner/ds-spinner.d.ts +17 -0
- package/dist/types/components/01-base-components/ds-spinner/stories/ds-spinner.examples.stories.d.ts +7 -0
- package/dist/types/components/01-base-components/ds-spinner/stories/ds-spinner.features.stories.d.ts +7 -0
- package/dist/types/components/01-base-components/ds-spinner/stories/ds-spinner.stories.d.ts +7 -0
- package/dist/types/components/01-base-components/ds-text-input/ds-text-input.d.ts +37 -32
- package/dist/types/components.d.ts +1287 -228
- package/dist/types/stencil-public-runtime.d.ts +22 -0
- package/dist/types/store.d.ts +6 -1
- package/dist/types/utils/attributes/attributes.d.ts +1 -1
- package/dist/types/utils/button/buttonUtils.d.ts +1 -0
- package/dist/types/utils/colours/colourTypes.d.ts +3 -3
- package/dist/types/utils/controls/controlUtils.d.ts +2 -0
- package/dist/types/utils/link/linkUtils.d.ts +1 -1
- package/dist/types/utils/spinner/spinnerUtils.d.ts +1 -0
- package/dist/types/utils/tests/testUtils.d.ts +1 -0
- package/dist/types/utils/utils.d.ts +2 -1
- package/package.json +40 -36
- package/dist/cjs/controlUtils-041de0fd.js +0 -7
- package/dist/cjs/ds-accordion_3.cjs.entry.js +0 -1095
- package/dist/cjs/index-5b0b9d4c.js +0 -82
- package/dist/component-library/controlUtils-9ca4087b.js +0 -1
- package/dist/component-library/ds-accordion_3.entry.js +0 -1
- package/dist/component-library/index-434995e1.js +0 -2
- package/dist/component-library/index-72ac5051.js +0 -6
- package/dist/component-library/linkUtils-3d1b28cf.js +0 -1
- package/dist/component-library/store-b8d17c10.js +0 -1
- package/dist/esm/controlUtils-9ca4087b.js +0 -4
- package/dist/esm/ds-accordion_3.entry.js +0 -1089
- package/dist/esm/index-72ac5051.js +0 -80
- package/dist/esm/store-b8d17c10.js +0 -204
- package/dist/loader/package.json +0 -11
- /package/dist/cjs/{app-globals-3a1e7e63.js → app-globals-V2Kpy_OQ.js} +0 -0
- /package/dist/component-library/{app-globals-0f993ce5.js → app-globals-DQuL1Twl.js} +0 -0
- /package/dist/esm/{app-globals-0f993ce5.js → app-globals-DQuL1Twl.js} +0 -0
|
@@ -5,174 +5,672 @@
|
|
|
5
5
|
* It contains typing information for all components that exist in this project.
|
|
6
6
|
*/
|
|
7
7
|
import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
|
|
8
|
-
import { DsCheckboxInputEvent } from "./components/01-base-components/ds-checkbox/ds-checkbox";
|
|
9
8
|
import { DsCheckboxGroupChangeEvent, DsCheckboxGroupIndeterminateChildChangeEvent } from "./components/01-base-components/ds-checkbox-group/ds-checkbox-group";
|
|
10
9
|
import { DsTextInputType } from "./components/01-base-components/ds-text-input/utils";
|
|
11
|
-
import {
|
|
12
|
-
|
|
10
|
+
import { DsTextInputEvent } from "./components/01-base-components/ds-text-input/ds-text-input";
|
|
11
|
+
import { Event } from "./stencil-public-runtime";
|
|
13
12
|
export { DsCheckboxGroupChangeEvent, DsCheckboxGroupIndeterminateChildChangeEvent } from "./components/01-base-components/ds-checkbox-group/ds-checkbox-group";
|
|
14
13
|
export { DsTextInputType } from "./components/01-base-components/ds-text-input/utils";
|
|
15
|
-
export {
|
|
14
|
+
export { DsTextInputEvent } from "./components/01-base-components/ds-text-input/ds-text-input";
|
|
15
|
+
export { Event } from "./stencil-public-runtime";
|
|
16
16
|
export namespace Components {
|
|
17
17
|
interface DsAccordion {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
"
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
"
|
|
18
|
+
/**
|
|
19
|
+
* Id of the accordion button
|
|
20
|
+
*/
|
|
21
|
+
"dsAccordionId": string;
|
|
22
|
+
/**
|
|
23
|
+
* Aligns the border to the position where accordion content starts
|
|
24
|
+
*/
|
|
25
|
+
"dsBorderAligned": boolean;
|
|
26
|
+
/**
|
|
27
|
+
* Text of the close button
|
|
28
|
+
*/
|
|
29
|
+
"dsCloseButtonLabel": string;
|
|
30
|
+
/**
|
|
31
|
+
* Heading level to be used for the accordion
|
|
32
|
+
*/
|
|
33
|
+
"dsHeadingLevel": number;
|
|
34
|
+
/**
|
|
35
|
+
* Removes the bottom border
|
|
36
|
+
*/
|
|
37
|
+
"dsHideBottomBorder": boolean;
|
|
38
|
+
/**
|
|
39
|
+
* Removes the top border
|
|
40
|
+
*/
|
|
41
|
+
"dsHideTopBorder": boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Displays the accordion as opened when loaded
|
|
44
|
+
*/
|
|
45
|
+
"dsOpenByDefault": boolean;
|
|
46
|
+
/**
|
|
47
|
+
* Displays a close button at the end of an opened accordion
|
|
48
|
+
*/
|
|
49
|
+
"dsUseCloseButton": boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Variant of the accordion
|
|
52
|
+
*/
|
|
53
|
+
"dsVariant": 'default' | 'compact';
|
|
26
54
|
}
|
|
27
55
|
interface DsButton {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
"
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
"
|
|
36
|
-
|
|
56
|
+
/**
|
|
57
|
+
* Passed to the `aria-disabled` attribute of the `button` element
|
|
58
|
+
*/
|
|
59
|
+
"dsAriaDisabled": string;
|
|
60
|
+
/**
|
|
61
|
+
* Colour of the button
|
|
62
|
+
*/
|
|
63
|
+
"dsColour": 'blue' | 'black' | 'white';
|
|
64
|
+
/**
|
|
65
|
+
* Passed to the `disabled` attribute of the `button` element
|
|
66
|
+
*/
|
|
67
|
+
"dsDisabled": boolean;
|
|
68
|
+
/**
|
|
69
|
+
* Sets focus to the button element rendered inside `ds-button` component.
|
|
70
|
+
*/
|
|
71
|
+
"dsFocus": () => Promise<void>;
|
|
72
|
+
/**
|
|
73
|
+
* Displays the button as full width
|
|
74
|
+
*/
|
|
75
|
+
"dsFullWidth": boolean;
|
|
76
|
+
/**
|
|
77
|
+
* Icon to display alongside the button text
|
|
78
|
+
*/
|
|
79
|
+
"dsIcon": string;
|
|
80
|
+
/**
|
|
81
|
+
* Whether to display the icon before or after the button text
|
|
82
|
+
*/
|
|
83
|
+
"dsIconPosition": 'start' | 'end';
|
|
84
|
+
/**
|
|
85
|
+
* Displays a loading spinner in the button
|
|
86
|
+
*/
|
|
87
|
+
"dsIsLoading": boolean;
|
|
88
|
+
/**
|
|
89
|
+
* Size of the button
|
|
90
|
+
*/
|
|
91
|
+
"dsSize": 'small' | 'medium';
|
|
92
|
+
/**
|
|
93
|
+
* Information for screen readers when spinner is displayed
|
|
94
|
+
*/
|
|
95
|
+
"dsSpinnerHiddenText": string;
|
|
96
|
+
/**
|
|
97
|
+
* Passed to the `type` attribute of the `button` element
|
|
98
|
+
*/
|
|
99
|
+
"dsType": 'button' | 'submit' | 'reset';
|
|
100
|
+
/**
|
|
101
|
+
* Wraps the button in a container where `aria-live` is set to `polite`
|
|
102
|
+
*/
|
|
103
|
+
"dsUseSpinner": boolean;
|
|
37
104
|
/**
|
|
38
105
|
* Button text content. Uses a text prop instead of `<slot />` to avoid triggering another render to set correct CSS classes just after initial load.
|
|
39
106
|
* @example <ds-button value="button"></ds-button> // Do this <ds-button>button</ds-button> // Instead of this
|
|
40
107
|
* @see {@link https://stackoverflow.com/a/52445966}
|
|
41
108
|
* @see {@link https://github.com/ionic-team/stencil/issues/399}
|
|
42
109
|
*/
|
|
43
|
-
"
|
|
44
|
-
|
|
110
|
+
"dsValue": string;
|
|
111
|
+
/**
|
|
112
|
+
* Variant of the button
|
|
113
|
+
*/
|
|
114
|
+
"dsVariant": 'primary' | 'secondary' | 'supplementary';
|
|
115
|
+
}
|
|
116
|
+
interface DsCard {
|
|
117
|
+
/**
|
|
118
|
+
* Optional description text
|
|
119
|
+
*/
|
|
120
|
+
"dsDescription"?: string;
|
|
121
|
+
/**
|
|
122
|
+
* Optional eyebrow text displayed above the heading
|
|
123
|
+
*/
|
|
124
|
+
"dsEyebrow"?: string;
|
|
125
|
+
/**
|
|
126
|
+
* The main heading text (required)
|
|
127
|
+
*/
|
|
128
|
+
"dsHeading": string;
|
|
129
|
+
/**
|
|
130
|
+
* Heading level, defaults to 3
|
|
131
|
+
*/
|
|
132
|
+
"dsHeadingLevel": number;
|
|
133
|
+
/**
|
|
134
|
+
* Optional image alt text
|
|
135
|
+
*/
|
|
136
|
+
"dsImageAlt"?: string;
|
|
137
|
+
/**
|
|
138
|
+
* Optional image URL
|
|
139
|
+
*/
|
|
140
|
+
"dsImageUrl"?: string;
|
|
141
|
+
/**
|
|
142
|
+
* Optional to show arrow when card is a link, defaults to true
|
|
143
|
+
*/
|
|
144
|
+
"dsShowArrow"?: boolean;
|
|
145
|
+
/**
|
|
146
|
+
* Optional subtitle text displayed below the heading
|
|
147
|
+
*/
|
|
148
|
+
"dsSubtitle"?: string;
|
|
149
|
+
/**
|
|
150
|
+
* Optional URL to use card as a link
|
|
151
|
+
*/
|
|
152
|
+
"dsUrl"?: string;
|
|
153
|
+
/**
|
|
154
|
+
* Optional URL target, if URL should open to new window or not, default _blank
|
|
155
|
+
*/
|
|
156
|
+
"dsUrlTarget": DsCardUrlTarget;
|
|
157
|
+
/**
|
|
158
|
+
* Variant of the card, filled or outlined, defaults to filled
|
|
159
|
+
*/
|
|
160
|
+
"dsVariant": DsCardVariant;
|
|
45
161
|
}
|
|
46
162
|
interface DsCheckbox {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
"
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
"
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
"
|
|
59
|
-
|
|
163
|
+
/**
|
|
164
|
+
* Passed to the `aria-label` attribute of the `input` element of the rendered checkbox.
|
|
165
|
+
*/
|
|
166
|
+
"dsAriaLabel": string;
|
|
167
|
+
/**
|
|
168
|
+
* Text for additional information shown below label
|
|
169
|
+
*/
|
|
170
|
+
"dsAssistiveText"?: string;
|
|
171
|
+
/**
|
|
172
|
+
* Passed to the `checked` attriubte of the `input` element of the rendered checkbox.
|
|
173
|
+
*/
|
|
174
|
+
"dsChecked": boolean;
|
|
175
|
+
/**
|
|
176
|
+
* Passed to the `disabled` attribute of the `input` element of the rendered checkbox.
|
|
177
|
+
*/
|
|
178
|
+
"dsDisabled": boolean;
|
|
179
|
+
/**
|
|
180
|
+
* Error message shown below the text input. If set, the checkbox is shown in an invalid state.
|
|
181
|
+
*/
|
|
182
|
+
"dsErrorText": string;
|
|
183
|
+
/**
|
|
184
|
+
* Used internally in checkbox group to disable error messages for a single checkbox.
|
|
185
|
+
*/
|
|
186
|
+
"dsErrorsDisabled": boolean;
|
|
187
|
+
/**
|
|
188
|
+
* Passed to the `id` attribute of the `input` element of the rendered checkbox.
|
|
189
|
+
*/
|
|
190
|
+
"dsId"?: string;
|
|
191
|
+
/**
|
|
192
|
+
* Mainly used in a nested checkbox group to display a parent checkbox in a partially selected state if some but not all of the nested checkbox group's checkboxes are selected.
|
|
193
|
+
*/
|
|
194
|
+
"dsIndeterminate": boolean;
|
|
195
|
+
/**
|
|
196
|
+
* Label of the checkbox
|
|
197
|
+
*/
|
|
198
|
+
"dsLegend"?: string;
|
|
199
|
+
/**
|
|
200
|
+
* Displays indicator that the checkbox is optional alongside label.
|
|
201
|
+
*/
|
|
202
|
+
"dsOptional": boolean;
|
|
203
|
+
/**
|
|
204
|
+
* Text shown alongside label, if the checkbox is set as optional.
|
|
205
|
+
*/
|
|
206
|
+
"dsOptionalText"?: string;
|
|
207
|
+
/**
|
|
208
|
+
* Passed to the `required` attribute of the `input` element of the rendered checkbox.
|
|
209
|
+
*/
|
|
210
|
+
"dsRequired": boolean;
|
|
211
|
+
/**
|
|
212
|
+
* The text of the checkbox
|
|
213
|
+
*/
|
|
214
|
+
"dsText"?: string;
|
|
60
215
|
}
|
|
61
216
|
interface DsCheckboxGroup {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
"
|
|
66
|
-
|
|
67
|
-
|
|
217
|
+
/**
|
|
218
|
+
* All checkboxes must be checked.
|
|
219
|
+
*/
|
|
220
|
+
"dsAllRequired": boolean;
|
|
221
|
+
/**
|
|
222
|
+
* Text for additional information shown below label
|
|
223
|
+
*/
|
|
224
|
+
"dsAssistiveText"?: string;
|
|
225
|
+
/**
|
|
226
|
+
* Passed to the `checked` attribute of the `input` of parent checkbox element.
|
|
227
|
+
*/
|
|
228
|
+
"dsChecked": boolean;
|
|
229
|
+
/**
|
|
230
|
+
* `vertical` displays checkboxes stacked `horizontal` displays checkboxes side by side
|
|
231
|
+
*/
|
|
232
|
+
"dsDirection": 'horizontal' | 'vertical';
|
|
233
|
+
/**
|
|
234
|
+
* Disables all checkboxes in the checkbox group
|
|
235
|
+
*/
|
|
236
|
+
"dsDisabled": boolean;
|
|
237
|
+
/**
|
|
238
|
+
* Error message shown below the checkbox group. If set, the checkbox group is shown in an invalid state.
|
|
239
|
+
*/
|
|
240
|
+
"dsErrorText": string;
|
|
241
|
+
/**
|
|
242
|
+
* Label of the checkbox group
|
|
243
|
+
*/
|
|
244
|
+
"dsLegend"?: string;
|
|
245
|
+
/**
|
|
246
|
+
* None of the checkboxes need to be checked.
|
|
247
|
+
*/
|
|
248
|
+
"dsOptional": boolean;
|
|
249
|
+
/**
|
|
250
|
+
* Text shown alongside label, if the checkbox button group is set as optional.
|
|
251
|
+
*/
|
|
252
|
+
"dsOptionalText"?: string;
|
|
253
|
+
/**
|
|
254
|
+
* One or more checkboxes must be checked.
|
|
255
|
+
*/
|
|
256
|
+
"dsRequired": boolean;
|
|
257
|
+
/**
|
|
258
|
+
* If given, a parent checkbox with this text will be rendered above slotted checkboxes
|
|
259
|
+
*/
|
|
260
|
+
"dsText": string;
|
|
68
261
|
/**
|
|
69
262
|
* Updates child elements' checked state.
|
|
70
263
|
* @param newValue New checked state.
|
|
71
264
|
*/
|
|
72
265
|
"setChecked": (newValue: boolean) => Promise<void>;
|
|
73
|
-
"text": string;
|
|
74
266
|
}
|
|
75
267
|
interface DsIcon {
|
|
76
|
-
|
|
268
|
+
/**
|
|
269
|
+
* Color of the icon
|
|
270
|
+
*/
|
|
271
|
+
"dsColour": string;
|
|
272
|
+
/**
|
|
273
|
+
* Passed to the `title` attribute of the `svg` element
|
|
274
|
+
*/
|
|
275
|
+
"dsHidden": boolean;
|
|
276
|
+
/**
|
|
277
|
+
* Name of the icon to display
|
|
278
|
+
*/
|
|
279
|
+
"dsName": string;
|
|
280
|
+
/**
|
|
281
|
+
* Passed to the `role` attribute of the `svg` element
|
|
282
|
+
*/
|
|
283
|
+
"dsRole": string;
|
|
284
|
+
/**
|
|
285
|
+
* Size of the icon
|
|
286
|
+
*/
|
|
287
|
+
"dsSize": Size;
|
|
288
|
+
/**
|
|
289
|
+
* Tooltip of the icon
|
|
290
|
+
*/
|
|
77
291
|
"dsTitle": string;
|
|
78
|
-
"hidden": boolean;
|
|
79
|
-
"name": string;
|
|
80
|
-
"role": string;
|
|
81
|
-
"size": string;
|
|
82
292
|
}
|
|
83
293
|
interface DsInputValidity {
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
294
|
+
/**
|
|
295
|
+
* Passed to the `aria-atomic` attribute of the container `div` element. Disabled if client-side validation is not used.
|
|
296
|
+
*/
|
|
297
|
+
"dsAriaAtomic"?: 'true' | 'false';
|
|
298
|
+
/**
|
|
299
|
+
* Passed to the `aria-live` attribute of the container `div` element. Disabled if client-side validation is not used.
|
|
300
|
+
*/
|
|
301
|
+
"dsAriaLive"?: 'assertive' | 'polite';
|
|
302
|
+
/**
|
|
303
|
+
* Text to display in the validity message
|
|
304
|
+
*/
|
|
305
|
+
"dsText": string;
|
|
306
|
+
/**
|
|
307
|
+
* Type of the validity
|
|
308
|
+
*/
|
|
309
|
+
"dsType": 'error' | 'success';
|
|
310
|
+
/**
|
|
311
|
+
* Passed to the `role` attribute of the container `div` element. Disabled if client-side validation is not used.
|
|
312
|
+
*/
|
|
313
|
+
"dsValidityRole"?: 'alert' | 'status';
|
|
87
314
|
}
|
|
88
315
|
interface DsLink {
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
"
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
"
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
"
|
|
101
|
-
|
|
316
|
+
/**
|
|
317
|
+
* Passed to the `aria-label` attribute of the `a` element
|
|
318
|
+
*/
|
|
319
|
+
"dsAriaLabel": string;
|
|
320
|
+
/**
|
|
321
|
+
* Colour of the link. Overrides default colour.
|
|
322
|
+
*/
|
|
323
|
+
"dsColour"?: 'black' | 'white';
|
|
324
|
+
/**
|
|
325
|
+
* Passed to the `download` attribute of the `a` element
|
|
326
|
+
*/
|
|
327
|
+
"dsDownload"?: boolean;
|
|
328
|
+
/**
|
|
329
|
+
* Passed to the `href` attribute of the `a` element
|
|
330
|
+
*/
|
|
331
|
+
"dsHref": string;
|
|
332
|
+
/**
|
|
333
|
+
* Icon to display alongside link
|
|
334
|
+
*/
|
|
335
|
+
"dsIcon": string;
|
|
336
|
+
/**
|
|
337
|
+
* Passed to the `dsHidden` property of the `ds-icon` element
|
|
338
|
+
*/
|
|
339
|
+
"dsIconHidden"?: boolean;
|
|
340
|
+
/**
|
|
341
|
+
* Whether to display the icon before or after the link
|
|
342
|
+
*/
|
|
343
|
+
"dsIconPosition": LinkIconPosition;
|
|
344
|
+
/**
|
|
345
|
+
* Passed to the `dsTitle` property of the `ds-icon` element
|
|
346
|
+
*/
|
|
347
|
+
"dsIconTitle"?: string;
|
|
348
|
+
/**
|
|
349
|
+
* Size of the link
|
|
350
|
+
*/
|
|
351
|
+
"dsSize"?: LinkSize;
|
|
352
|
+
/**
|
|
353
|
+
* Passed to the `target` attribute of the `a` element
|
|
354
|
+
*/
|
|
355
|
+
"dsTarget"?: LinkTarget;
|
|
356
|
+
/**
|
|
357
|
+
* Text content of the link
|
|
358
|
+
*/
|
|
359
|
+
"dsText": string;
|
|
360
|
+
/**
|
|
361
|
+
* Variant of the link
|
|
362
|
+
*/
|
|
363
|
+
"dsVariant": LinkVariant;
|
|
364
|
+
/**
|
|
365
|
+
* Font weight of the link
|
|
366
|
+
*/
|
|
367
|
+
"dsWeight": LinkWeight;
|
|
102
368
|
}
|
|
103
369
|
interface DsLinkWithArrow {
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
"
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
"
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
"
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
"
|
|
124
|
-
"label"?: string;
|
|
125
|
-
"max"?: number;
|
|
126
|
-
"maxlength"?: number;
|
|
127
|
-
"min"?: number;
|
|
128
|
-
"name": string;
|
|
129
|
-
"optional"?: boolean;
|
|
130
|
-
"optionalText"?: string;
|
|
131
|
-
"pattern"?: string;
|
|
132
|
-
"placeholder"?: string;
|
|
133
|
-
"prefixText"?: string;
|
|
134
|
-
"readonly"?: boolean;
|
|
135
|
-
"required"?: boolean;
|
|
136
|
-
"successText"?: string;
|
|
137
|
-
"suffixText"?: string;
|
|
138
|
-
"togglePasswordVisibility": () => Promise<boolean>;
|
|
139
|
-
"type": DsTextInputType;
|
|
140
|
-
"value"?: string;
|
|
141
|
-
}
|
|
142
|
-
interface DsVisuallyHidden {
|
|
370
|
+
/**
|
|
371
|
+
* Passed to the `aria-label` attribute of the `a` element
|
|
372
|
+
*/
|
|
373
|
+
"dsAriaLabel": string;
|
|
374
|
+
/**
|
|
375
|
+
* Passed to the `href` attribute of the `a` element
|
|
376
|
+
*/
|
|
377
|
+
"dsHref": string;
|
|
378
|
+
/**
|
|
379
|
+
* Whether to display the arrow icon before or after the link
|
|
380
|
+
*/
|
|
381
|
+
"dsIconPosition": LinkIconPosition;
|
|
382
|
+
/**
|
|
383
|
+
* Passed to the `target` attribute of the `a` element
|
|
384
|
+
*/
|
|
385
|
+
"dsTarget"?: LinkTarget;
|
|
386
|
+
/**
|
|
387
|
+
* Text content of the link
|
|
388
|
+
*/
|
|
389
|
+
"dsText"?: string;
|
|
143
390
|
}
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
391
|
+
interface DsRadioButton {
|
|
392
|
+
/**
|
|
393
|
+
* Text for additional information shown below label
|
|
394
|
+
*/
|
|
395
|
+
"dsAssistiveText"?: string;
|
|
396
|
+
/**
|
|
397
|
+
* Passed to the `checked` attribute of the `input` element of the rendered radio button.
|
|
398
|
+
*/
|
|
399
|
+
"dsChecked": boolean;
|
|
400
|
+
/**
|
|
401
|
+
* Passed to the `disabled` attribute of the `input` element of the rendered radio button.
|
|
402
|
+
*/
|
|
403
|
+
"dsDisabled": boolean;
|
|
404
|
+
/**
|
|
405
|
+
* Error message shown below the radio button. If set, the radio button is shown in an invalid state.
|
|
406
|
+
*/
|
|
407
|
+
"dsErrorText": string;
|
|
408
|
+
/**
|
|
409
|
+
* Can be used to disable client-side validation. Used internally in radio button group to disable error messages for a single radio button.
|
|
410
|
+
*/
|
|
411
|
+
"dsErrorsDisabled": boolean;
|
|
412
|
+
/**
|
|
413
|
+
* Custom focus method that ensures the correct internal input element is focused
|
|
414
|
+
*/
|
|
415
|
+
"dsFocus": () => Promise<void>;
|
|
416
|
+
/**
|
|
417
|
+
* Passed to the `id` attriubte of the `input` element of the rendered radio button.
|
|
418
|
+
*/
|
|
419
|
+
"dsId"?: string;
|
|
420
|
+
/**
|
|
421
|
+
* Label of the radio button
|
|
422
|
+
*/
|
|
423
|
+
"dsLegend"?: string;
|
|
424
|
+
/**
|
|
425
|
+
* Passed to the `required` attribute of the `input` element of the rendered radio button.
|
|
426
|
+
*/
|
|
427
|
+
"dsRequired": boolean;
|
|
428
|
+
/**
|
|
429
|
+
* The text of the radio button
|
|
430
|
+
*/
|
|
431
|
+
"dsText"?: string;
|
|
432
|
+
/**
|
|
433
|
+
* Passed to the `value` attribute of the `input` element of the rendered radio button.
|
|
434
|
+
*/
|
|
435
|
+
"dsValue"?: string;
|
|
436
|
+
"setChecked": () => Promise<void>;
|
|
437
|
+
/**
|
|
438
|
+
* Whether the radio button is focusable via tab or not. Used internally inside a radio button group to make keyboard usage work as expected. NOTE: manually calling this method may cause unexpected behaviour
|
|
439
|
+
*/
|
|
440
|
+
"setFocusable": (flag: boolean) => Promise<void>;
|
|
159
441
|
}
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
442
|
+
interface DsRadioButtonGroup {
|
|
443
|
+
/**
|
|
444
|
+
* Text for additional information shown below legend
|
|
445
|
+
*/
|
|
446
|
+
"dsAssistiveText"?: string;
|
|
447
|
+
/**
|
|
448
|
+
* `vertical` displays radio buttons stacked `horizontal` displays radio buttons side by side
|
|
449
|
+
*/
|
|
450
|
+
"dsDirection": 'horizontal' | 'vertical';
|
|
451
|
+
/**
|
|
452
|
+
* Error message shown below the text input. If set, the text input is shown in an invalid state.
|
|
453
|
+
*/
|
|
454
|
+
"dsErrorText": string;
|
|
455
|
+
/**
|
|
456
|
+
* Label for the radio button group
|
|
457
|
+
*/
|
|
458
|
+
"dsLegend"?: string;
|
|
459
|
+
/**
|
|
460
|
+
* One or more radio buttons must be checked.
|
|
461
|
+
*/
|
|
462
|
+
"dsRequired": boolean;
|
|
463
|
+
/**
|
|
464
|
+
* Determines which radio button in the group is selected. The radio button with the matching `value` will be selected.
|
|
465
|
+
*/
|
|
466
|
+
"dsValue"?: string;
|
|
467
|
+
"getValue": () => Promise<string>;
|
|
165
468
|
}
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
469
|
+
interface DsSpinner {
|
|
470
|
+
/**
|
|
471
|
+
* Visually hidden information for screen readers
|
|
472
|
+
*/
|
|
473
|
+
"dsHiddenAssistiveText": string;
|
|
474
|
+
/**
|
|
475
|
+
* Size of the spinner
|
|
476
|
+
*/
|
|
477
|
+
"dsSize": SpinnerSize;
|
|
478
|
+
/**
|
|
479
|
+
* Color of the spinner
|
|
480
|
+
*/
|
|
481
|
+
"dsSpinnerColor": SpinnerColor;
|
|
482
|
+
/**
|
|
483
|
+
* Where to display the `dsText` property
|
|
484
|
+
*/
|
|
485
|
+
"dsSpinnerTextPosition": SpinnerTextPosition;
|
|
486
|
+
/**
|
|
487
|
+
* Text to display alongside spinner
|
|
488
|
+
*/
|
|
489
|
+
"dsText": string;
|
|
490
|
+
/**
|
|
491
|
+
* Sets `aria-live="polite"` attribute to the spinner element
|
|
492
|
+
*/
|
|
493
|
+
"dsUseAriaLive": boolean;
|
|
494
|
+
/**
|
|
495
|
+
* Sets `role="alert"` attribute to the spinner element
|
|
496
|
+
*/
|
|
497
|
+
"dsUseRoleAlert": boolean;
|
|
172
498
|
}
|
|
173
|
-
interface
|
|
174
|
-
|
|
175
|
-
|
|
499
|
+
interface DsTextInput {
|
|
500
|
+
"clearInput": (e: Event) => Promise<void>;
|
|
501
|
+
/**
|
|
502
|
+
* Aria-label for action button for text inputs with type `password` or `search`. The action button for `search` text input is the clear button. The action button for `password` text input is the toggle visibility button.
|
|
503
|
+
*/
|
|
504
|
+
"dsActionButtonAriaLabel"?: string;
|
|
505
|
+
/**
|
|
506
|
+
* Passed to the `aria-describedby` attribute of the `input` element.
|
|
507
|
+
*/
|
|
508
|
+
"dsAriaDescribedby"?: string;
|
|
509
|
+
/**
|
|
510
|
+
* Passed to the `aria-label` attribute of the `input` element.
|
|
511
|
+
*/
|
|
512
|
+
"dsAriaLabel": string;
|
|
513
|
+
/**
|
|
514
|
+
* Passed to the `aria-labelledby` attribute of the `input` element.
|
|
515
|
+
*/
|
|
516
|
+
"dsAriaLabelledby"?: string;
|
|
517
|
+
/**
|
|
518
|
+
* Text for additional information shown below label
|
|
519
|
+
*/
|
|
520
|
+
"dsAssistiveText"?: string;
|
|
521
|
+
/**
|
|
522
|
+
* Passed to the `autocomplete` attribute of the `input` element.
|
|
523
|
+
*/
|
|
524
|
+
"dsAutocomplete"?: string;
|
|
525
|
+
/**
|
|
526
|
+
* Passed to the `disabled` attribute of the `input` element.
|
|
527
|
+
*/
|
|
528
|
+
"dsDisabled"?: boolean;
|
|
529
|
+
/**
|
|
530
|
+
* Error message shown below the text input. If set, the text input is shown in an invalid state.
|
|
531
|
+
*/
|
|
532
|
+
"dsErrorText"?: string;
|
|
533
|
+
/**
|
|
534
|
+
* Visually hidden additional information for screen readers
|
|
535
|
+
*/
|
|
536
|
+
"dsHiddenAssistiveText"?: string;
|
|
537
|
+
/**
|
|
538
|
+
* Icon to display at the start of the text input.
|
|
539
|
+
*/
|
|
540
|
+
"dsIcon": string;
|
|
541
|
+
/**
|
|
542
|
+
* Passed to the `id` of the `input` element.
|
|
543
|
+
*/
|
|
544
|
+
"dsId"?: string;
|
|
545
|
+
/**
|
|
546
|
+
* Label of the input
|
|
547
|
+
*/
|
|
548
|
+
"dsLabel"?: string;
|
|
549
|
+
/**
|
|
550
|
+
* Passed to the `max` attribute of the `input` element.
|
|
551
|
+
*/
|
|
552
|
+
"dsMax"?: number;
|
|
553
|
+
/**
|
|
554
|
+
* Passed to the `maxlength` attribute of the `input` element.
|
|
555
|
+
*/
|
|
556
|
+
"dsMaxLength"?: number;
|
|
557
|
+
/**
|
|
558
|
+
* Passed to the `min` attribute of the `input` element.
|
|
559
|
+
*/
|
|
560
|
+
"dsMin"?: number;
|
|
561
|
+
/**
|
|
562
|
+
* Passed to the `name` attribute of the `input` element.
|
|
563
|
+
*/
|
|
564
|
+
"dsName": string;
|
|
565
|
+
/**
|
|
566
|
+
* Displays indicator that the text input is optional alongside label.
|
|
567
|
+
*/
|
|
568
|
+
"dsOptional"?: boolean;
|
|
569
|
+
/**
|
|
570
|
+
* Text shown alongside label, if the text input is set as optional.
|
|
571
|
+
*/
|
|
572
|
+
"dsOptionalText"?: string;
|
|
573
|
+
/**
|
|
574
|
+
* Passed to the `pattern` attribute of the `input` element.
|
|
575
|
+
*/
|
|
576
|
+
"dsPattern"?: string;
|
|
577
|
+
/**
|
|
578
|
+
* Passed to the `placeholder` of the `input` element.
|
|
579
|
+
*/
|
|
580
|
+
"dsPlaceholder"?: string;
|
|
581
|
+
/**
|
|
582
|
+
* Allows additional elements before or after the input field, such as units (e.g., currency, minutes, country codes).
|
|
583
|
+
*/
|
|
584
|
+
"dsPrefixText"?: string;
|
|
585
|
+
/**
|
|
586
|
+
* Passed to the `readonly` attribute of the `input` element.
|
|
587
|
+
*/
|
|
588
|
+
"dsReadonly"?: boolean;
|
|
589
|
+
/**
|
|
590
|
+
* Passed to the `required` attribute of the `input` element.
|
|
591
|
+
*/
|
|
592
|
+
"dsRequired"?: boolean;
|
|
593
|
+
/**
|
|
594
|
+
* Success message shown below the text input. If set, the text input is shown in a success state.
|
|
595
|
+
*/
|
|
596
|
+
"dsSuccessText"?: string;
|
|
597
|
+
/**
|
|
598
|
+
* Allows additional elements before or after the input field, such as units (e.g., currency, minutes, country codes).
|
|
599
|
+
*/
|
|
600
|
+
"dsSuffixText"?: string;
|
|
601
|
+
/**
|
|
602
|
+
* Type of the text input, passed to the `type` attribute of the `input` element. A text input of type `search` has an action button to clear the input value if it is not empty. A text input of type `password` has an action button to toggle the visibility of the entered input.
|
|
603
|
+
*/
|
|
604
|
+
"dsType": DsTextInputType;
|
|
605
|
+
/**
|
|
606
|
+
* Passed to the `value` attribute of the `input` element.
|
|
607
|
+
*/
|
|
608
|
+
"dsValue"?: string;
|
|
609
|
+
"togglePasswordVisibility": () => Promise<boolean>;
|
|
610
|
+
}
|
|
611
|
+
interface DsVisuallyHidden {
|
|
612
|
+
}
|
|
613
|
+
}
|
|
614
|
+
export interface DsAccordionCustomEvent<T> extends CustomEvent<T> {
|
|
615
|
+
detail: T;
|
|
616
|
+
target: HTMLDsAccordionElement;
|
|
617
|
+
}
|
|
618
|
+
export interface DsCheckboxCustomEvent<T> extends CustomEvent<T> {
|
|
619
|
+
detail: T;
|
|
620
|
+
target: HTMLDsCheckboxElement;
|
|
621
|
+
}
|
|
622
|
+
export interface DsCheckboxGroupCustomEvent<T> extends CustomEvent<T> {
|
|
623
|
+
detail: T;
|
|
624
|
+
target: HTMLDsCheckboxGroupElement;
|
|
625
|
+
}
|
|
626
|
+
export interface DsRadioButtonCustomEvent<T> extends CustomEvent<T> {
|
|
627
|
+
detail: T;
|
|
628
|
+
target: HTMLDsRadioButtonElement;
|
|
629
|
+
}
|
|
630
|
+
export interface DsRadioButtonGroupCustomEvent<T> extends CustomEvent<T> {
|
|
631
|
+
detail: T;
|
|
632
|
+
target: HTMLDsRadioButtonGroupElement;
|
|
633
|
+
}
|
|
634
|
+
export interface DsTextInputCustomEvent<T> extends CustomEvent<T> {
|
|
635
|
+
detail: T;
|
|
636
|
+
target: HTMLDsTextInputElement;
|
|
637
|
+
}
|
|
638
|
+
declare global {
|
|
639
|
+
interface HTMLDsAccordionElementEventMap {
|
|
640
|
+
"dsToggle": boolean;
|
|
641
|
+
}
|
|
642
|
+
interface HTMLDsAccordionElement extends Components.DsAccordion, HTMLStencilElement {
|
|
643
|
+
addEventListener<K extends keyof HTMLDsAccordionElementEventMap>(type: K, listener: (this: HTMLDsAccordionElement, ev: DsAccordionCustomEvent<HTMLDsAccordionElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
644
|
+
addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
645
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
646
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
647
|
+
removeEventListener<K extends keyof HTMLDsAccordionElementEventMap>(type: K, listener: (this: HTMLDsAccordionElement, ev: DsAccordionCustomEvent<HTMLDsAccordionElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
|
|
648
|
+
removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
649
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
650
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
651
|
+
}
|
|
652
|
+
var HTMLDsAccordionElement: {
|
|
653
|
+
prototype: HTMLDsAccordionElement;
|
|
654
|
+
new (): HTMLDsAccordionElement;
|
|
655
|
+
};
|
|
656
|
+
interface HTMLDsButtonElement extends Components.DsButton, HTMLStencilElement {
|
|
657
|
+
}
|
|
658
|
+
var HTMLDsButtonElement: {
|
|
659
|
+
prototype: HTMLDsButtonElement;
|
|
660
|
+
new (): HTMLDsButtonElement;
|
|
661
|
+
};
|
|
662
|
+
interface HTMLDsCardElement extends Components.DsCard, HTMLStencilElement {
|
|
663
|
+
}
|
|
664
|
+
var HTMLDsCardElement: {
|
|
665
|
+
prototype: HTMLDsCardElement;
|
|
666
|
+
new (): HTMLDsCardElement;
|
|
667
|
+
};
|
|
668
|
+
interface HTMLDsCheckboxElementEventMap {
|
|
669
|
+
"dsChange": boolean;
|
|
670
|
+
}
|
|
671
|
+
interface HTMLDsCheckboxElement extends Components.DsCheckbox, HTMLStencilElement {
|
|
672
|
+
addEventListener<K extends keyof HTMLDsCheckboxElementEventMap>(type: K, listener: (this: HTMLDsCheckboxElement, ev: DsCheckboxCustomEvent<HTMLDsCheckboxElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
673
|
+
addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
176
674
|
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
177
675
|
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
178
676
|
removeEventListener<K extends keyof HTMLDsCheckboxElementEventMap>(type: K, listener: (this: HTMLDsCheckboxElement, ev: DsCheckboxCustomEvent<HTMLDsCheckboxElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
|
|
@@ -187,6 +685,7 @@ declare global {
|
|
|
187
685
|
interface HTMLDsCheckboxGroupElementEventMap {
|
|
188
686
|
"dsCheckboxGroupChange": DsCheckboxGroupChangeEvent;
|
|
189
687
|
"dsCheckboxGroupIndeterminateChildChange": DsCheckboxGroupIndeterminateChildChangeEvent;
|
|
688
|
+
"dsCheckboxGroupInvalidStateChange": boolean;
|
|
190
689
|
}
|
|
191
690
|
interface HTMLDsCheckboxGroupElement extends Components.DsCheckboxGroup, HTMLStencilElement {
|
|
192
691
|
addEventListener<K extends keyof HTMLDsCheckboxGroupElementEventMap>(type: K, listener: (this: HTMLDsCheckboxGroupElement, ev: DsCheckboxGroupCustomEvent<HTMLDsCheckboxGroupElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
@@ -226,8 +725,53 @@ declare global {
|
|
|
226
725
|
prototype: HTMLDsLinkWithArrowElement;
|
|
227
726
|
new (): HTMLDsLinkWithArrowElement;
|
|
228
727
|
};
|
|
728
|
+
interface HTMLDsRadioButtonElementEventMap {
|
|
729
|
+
"dsChange": boolean;
|
|
730
|
+
"dsRadioButtonChecked": void;
|
|
731
|
+
}
|
|
732
|
+
interface HTMLDsRadioButtonElement extends Components.DsRadioButton, HTMLStencilElement {
|
|
733
|
+
addEventListener<K extends keyof HTMLDsRadioButtonElementEventMap>(type: K, listener: (this: HTMLDsRadioButtonElement, ev: DsRadioButtonCustomEvent<HTMLDsRadioButtonElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
734
|
+
addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
735
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
736
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
737
|
+
removeEventListener<K extends keyof HTMLDsRadioButtonElementEventMap>(type: K, listener: (this: HTMLDsRadioButtonElement, ev: DsRadioButtonCustomEvent<HTMLDsRadioButtonElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
|
|
738
|
+
removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
739
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
740
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
741
|
+
}
|
|
742
|
+
var HTMLDsRadioButtonElement: {
|
|
743
|
+
prototype: HTMLDsRadioButtonElement;
|
|
744
|
+
new (): HTMLDsRadioButtonElement;
|
|
745
|
+
};
|
|
746
|
+
interface HTMLDsRadioButtonGroupElementEventMap {
|
|
747
|
+
"dsRadioGroupValueChange": string | undefined;
|
|
748
|
+
"dsRadioGroupInvalidStateChange": boolean;
|
|
749
|
+
"dsChange": string;
|
|
750
|
+
}
|
|
751
|
+
interface HTMLDsRadioButtonGroupElement extends Components.DsRadioButtonGroup, HTMLStencilElement {
|
|
752
|
+
addEventListener<K extends keyof HTMLDsRadioButtonGroupElementEventMap>(type: K, listener: (this: HTMLDsRadioButtonGroupElement, ev: DsRadioButtonGroupCustomEvent<HTMLDsRadioButtonGroupElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
753
|
+
addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
754
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
755
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
756
|
+
removeEventListener<K extends keyof HTMLDsRadioButtonGroupElementEventMap>(type: K, listener: (this: HTMLDsRadioButtonGroupElement, ev: DsRadioButtonGroupCustomEvent<HTMLDsRadioButtonGroupElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
|
|
757
|
+
removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
758
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
759
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
760
|
+
}
|
|
761
|
+
var HTMLDsRadioButtonGroupElement: {
|
|
762
|
+
prototype: HTMLDsRadioButtonGroupElement;
|
|
763
|
+
new (): HTMLDsRadioButtonGroupElement;
|
|
764
|
+
};
|
|
765
|
+
interface HTMLDsSpinnerElement extends Components.DsSpinner, HTMLStencilElement {
|
|
766
|
+
}
|
|
767
|
+
var HTMLDsSpinnerElement: {
|
|
768
|
+
prototype: HTMLDsSpinnerElement;
|
|
769
|
+
new (): HTMLDsSpinnerElement;
|
|
770
|
+
};
|
|
229
771
|
interface HTMLDsTextInputElementEventMap {
|
|
230
|
-
"
|
|
772
|
+
"dsChange": Omit<DsTextInputEvent, 'event'>;
|
|
773
|
+
"dsInput": DsTextInputEvent<InputEvent>;
|
|
774
|
+
"dsClear": DsTextInputEvent;
|
|
231
775
|
}
|
|
232
776
|
interface HTMLDsTextInputElement extends Components.DsTextInput, HTMLStencilElement {
|
|
233
777
|
addEventListener<K extends keyof HTMLDsTextInputElementEventMap>(type: K, listener: (this: HTMLDsTextInputElement, ev: DsTextInputCustomEvent<HTMLDsTextInputElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
@@ -252,150 +796,661 @@ declare global {
|
|
|
252
796
|
interface HTMLElementTagNameMap {
|
|
253
797
|
"ds-accordion": HTMLDsAccordionElement;
|
|
254
798
|
"ds-button": HTMLDsButtonElement;
|
|
799
|
+
"ds-card": HTMLDsCardElement;
|
|
255
800
|
"ds-checkbox": HTMLDsCheckboxElement;
|
|
256
801
|
"ds-checkbox-group": HTMLDsCheckboxGroupElement;
|
|
257
802
|
"ds-icon": HTMLDsIconElement;
|
|
258
803
|
"ds-input-validity": HTMLDsInputValidityElement;
|
|
259
804
|
"ds-link": HTMLDsLinkElement;
|
|
260
805
|
"ds-link-with-arrow": HTMLDsLinkWithArrowElement;
|
|
806
|
+
"ds-radio-button": HTMLDsRadioButtonElement;
|
|
807
|
+
"ds-radio-button-group": HTMLDsRadioButtonGroupElement;
|
|
808
|
+
"ds-spinner": HTMLDsSpinnerElement;
|
|
261
809
|
"ds-text-input": HTMLDsTextInputElement;
|
|
262
810
|
"ds-visually-hidden": HTMLDsVisuallyHiddenElement;
|
|
263
811
|
}
|
|
264
812
|
}
|
|
265
813
|
declare namespace LocalJSX {
|
|
266
814
|
interface DsAccordion {
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
"
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
"
|
|
815
|
+
/**
|
|
816
|
+
* Id of the accordion button
|
|
817
|
+
*/
|
|
818
|
+
"dsAccordionId"?: string;
|
|
819
|
+
/**
|
|
820
|
+
* Aligns the border to the position where accordion content starts
|
|
821
|
+
*/
|
|
822
|
+
"dsBorderAligned"?: boolean;
|
|
823
|
+
/**
|
|
824
|
+
* Text of the close button
|
|
825
|
+
*/
|
|
826
|
+
"dsCloseButtonLabel"?: string;
|
|
827
|
+
/**
|
|
828
|
+
* Heading level to be used for the accordion
|
|
829
|
+
*/
|
|
830
|
+
"dsHeadingLevel"?: number;
|
|
831
|
+
/**
|
|
832
|
+
* Removes the bottom border
|
|
833
|
+
*/
|
|
834
|
+
"dsHideBottomBorder"?: boolean;
|
|
835
|
+
/**
|
|
836
|
+
* Removes the top border
|
|
837
|
+
*/
|
|
838
|
+
"dsHideTopBorder"?: boolean;
|
|
839
|
+
/**
|
|
840
|
+
* Displays the accordion as opened when loaded
|
|
841
|
+
*/
|
|
842
|
+
"dsOpenByDefault"?: boolean;
|
|
843
|
+
/**
|
|
844
|
+
* Displays a close button at the end of an opened accordion
|
|
845
|
+
*/
|
|
846
|
+
"dsUseCloseButton"?: boolean;
|
|
847
|
+
/**
|
|
848
|
+
* Variant of the accordion
|
|
849
|
+
*/
|
|
850
|
+
"dsVariant"?: 'default' | 'compact';
|
|
851
|
+
/**
|
|
852
|
+
* Emitted when the accordion is expanded or closed.
|
|
853
|
+
*/
|
|
854
|
+
"onDsToggle"?: (event: DsAccordionCustomEvent<boolean>) => void;
|
|
275
855
|
}
|
|
276
856
|
interface DsButton {
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
"
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
"
|
|
285
|
-
|
|
857
|
+
/**
|
|
858
|
+
* Passed to the `aria-disabled` attribute of the `button` element
|
|
859
|
+
*/
|
|
860
|
+
"dsAriaDisabled"?: string;
|
|
861
|
+
/**
|
|
862
|
+
* Colour of the button
|
|
863
|
+
*/
|
|
864
|
+
"dsColour"?: 'blue' | 'black' | 'white';
|
|
865
|
+
/**
|
|
866
|
+
* Passed to the `disabled` attribute of the `button` element
|
|
867
|
+
*/
|
|
868
|
+
"dsDisabled"?: boolean;
|
|
869
|
+
/**
|
|
870
|
+
* Displays the button as full width
|
|
871
|
+
*/
|
|
872
|
+
"dsFullWidth"?: boolean;
|
|
873
|
+
/**
|
|
874
|
+
* Icon to display alongside the button text
|
|
875
|
+
*/
|
|
876
|
+
"dsIcon"?: string;
|
|
877
|
+
/**
|
|
878
|
+
* Whether to display the icon before or after the button text
|
|
879
|
+
*/
|
|
880
|
+
"dsIconPosition"?: 'start' | 'end';
|
|
881
|
+
/**
|
|
882
|
+
* Displays a loading spinner in the button
|
|
883
|
+
*/
|
|
884
|
+
"dsIsLoading"?: boolean;
|
|
885
|
+
/**
|
|
886
|
+
* Size of the button
|
|
887
|
+
*/
|
|
888
|
+
"dsSize"?: 'small' | 'medium';
|
|
889
|
+
/**
|
|
890
|
+
* Information for screen readers when spinner is displayed
|
|
891
|
+
*/
|
|
892
|
+
"dsSpinnerHiddenText"?: string;
|
|
893
|
+
/**
|
|
894
|
+
* Passed to the `type` attribute of the `button` element
|
|
895
|
+
*/
|
|
896
|
+
"dsType"?: 'button' | 'submit' | 'reset';
|
|
897
|
+
/**
|
|
898
|
+
* Wraps the button in a container where `aria-live` is set to `polite`
|
|
899
|
+
*/
|
|
900
|
+
"dsUseSpinner"?: boolean;
|
|
286
901
|
/**
|
|
287
902
|
* Button text content. Uses a text prop instead of `<slot />` to avoid triggering another render to set correct CSS classes just after initial load.
|
|
288
903
|
* @example <ds-button value="button"></ds-button> // Do this <ds-button>button</ds-button> // Instead of this
|
|
289
904
|
* @see {@link https://stackoverflow.com/a/52445966}
|
|
290
905
|
* @see {@link https://github.com/ionic-team/stencil/issues/399}
|
|
291
906
|
*/
|
|
292
|
-
"
|
|
293
|
-
|
|
907
|
+
"dsValue"?: string;
|
|
908
|
+
/**
|
|
909
|
+
* Variant of the button
|
|
910
|
+
*/
|
|
911
|
+
"dsVariant"?: 'primary' | 'secondary' | 'supplementary';
|
|
912
|
+
}
|
|
913
|
+
interface DsCard {
|
|
914
|
+
/**
|
|
915
|
+
* Optional description text
|
|
916
|
+
*/
|
|
917
|
+
"dsDescription"?: string;
|
|
918
|
+
/**
|
|
919
|
+
* Optional eyebrow text displayed above the heading
|
|
920
|
+
*/
|
|
921
|
+
"dsEyebrow"?: string;
|
|
922
|
+
/**
|
|
923
|
+
* The main heading text (required)
|
|
924
|
+
*/
|
|
925
|
+
"dsHeading": string;
|
|
926
|
+
/**
|
|
927
|
+
* Heading level, defaults to 3
|
|
928
|
+
*/
|
|
929
|
+
"dsHeadingLevel"?: number;
|
|
930
|
+
/**
|
|
931
|
+
* Optional image alt text
|
|
932
|
+
*/
|
|
933
|
+
"dsImageAlt"?: string;
|
|
934
|
+
/**
|
|
935
|
+
* Optional image URL
|
|
936
|
+
*/
|
|
937
|
+
"dsImageUrl"?: string;
|
|
938
|
+
/**
|
|
939
|
+
* Optional to show arrow when card is a link, defaults to true
|
|
940
|
+
*/
|
|
941
|
+
"dsShowArrow"?: boolean;
|
|
942
|
+
/**
|
|
943
|
+
* Optional subtitle text displayed below the heading
|
|
944
|
+
*/
|
|
945
|
+
"dsSubtitle"?: string;
|
|
946
|
+
/**
|
|
947
|
+
* Optional URL to use card as a link
|
|
948
|
+
*/
|
|
949
|
+
"dsUrl"?: string;
|
|
950
|
+
/**
|
|
951
|
+
* Optional URL target, if URL should open to new window or not, default _blank
|
|
952
|
+
*/
|
|
953
|
+
"dsUrlTarget"?: DsCardUrlTarget;
|
|
954
|
+
/**
|
|
955
|
+
* Variant of the card, filled or outlined, defaults to filled
|
|
956
|
+
*/
|
|
957
|
+
"dsVariant"?: DsCardVariant;
|
|
294
958
|
}
|
|
295
959
|
interface DsCheckbox {
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
"
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
"
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
"
|
|
308
|
-
|
|
309
|
-
|
|
960
|
+
/**
|
|
961
|
+
* Passed to the `aria-label` attribute of the `input` element of the rendered checkbox.
|
|
962
|
+
*/
|
|
963
|
+
"dsAriaLabel"?: string;
|
|
964
|
+
/**
|
|
965
|
+
* Text for additional information shown below label
|
|
966
|
+
*/
|
|
967
|
+
"dsAssistiveText"?: string;
|
|
968
|
+
/**
|
|
969
|
+
* Passed to the `checked` attriubte of the `input` element of the rendered checkbox.
|
|
970
|
+
*/
|
|
971
|
+
"dsChecked"?: boolean;
|
|
972
|
+
/**
|
|
973
|
+
* Passed to the `disabled` attribute of the `input` element of the rendered checkbox.
|
|
974
|
+
*/
|
|
975
|
+
"dsDisabled"?: boolean;
|
|
976
|
+
/**
|
|
977
|
+
* Error message shown below the text input. If set, the checkbox is shown in an invalid state.
|
|
978
|
+
*/
|
|
979
|
+
"dsErrorText"?: string;
|
|
980
|
+
/**
|
|
981
|
+
* Used internally in checkbox group to disable error messages for a single checkbox.
|
|
982
|
+
*/
|
|
983
|
+
"dsErrorsDisabled"?: boolean;
|
|
984
|
+
/**
|
|
985
|
+
* Passed to the `id` attribute of the `input` element of the rendered checkbox.
|
|
986
|
+
*/
|
|
987
|
+
"dsId"?: string;
|
|
988
|
+
/**
|
|
989
|
+
* Mainly used in a nested checkbox group to display a parent checkbox in a partially selected state if some but not all of the nested checkbox group's checkboxes are selected.
|
|
990
|
+
*/
|
|
991
|
+
"dsIndeterminate"?: boolean;
|
|
992
|
+
/**
|
|
993
|
+
* Label of the checkbox
|
|
994
|
+
*/
|
|
995
|
+
"dsLegend"?: string;
|
|
996
|
+
/**
|
|
997
|
+
* Displays indicator that the checkbox is optional alongside label.
|
|
998
|
+
*/
|
|
999
|
+
"dsOptional"?: boolean;
|
|
1000
|
+
/**
|
|
1001
|
+
* Text shown alongside label, if the checkbox is set as optional.
|
|
1002
|
+
*/
|
|
1003
|
+
"dsOptionalText"?: string;
|
|
1004
|
+
/**
|
|
1005
|
+
* Passed to the `required` attribute of the `input` element of the rendered checkbox.
|
|
1006
|
+
*/
|
|
1007
|
+
"dsRequired"?: boolean;
|
|
1008
|
+
/**
|
|
1009
|
+
* The text of the checkbox
|
|
1010
|
+
*/
|
|
1011
|
+
"dsText"?: string;
|
|
1012
|
+
/**
|
|
1013
|
+
* The `dsChange` event is fired each time the `value` property of the `ds-checkbox` element is changed.
|
|
1014
|
+
*/
|
|
1015
|
+
"onDsChange"?: (event: DsCheckboxCustomEvent<boolean>) => void;
|
|
310
1016
|
}
|
|
311
1017
|
interface DsCheckboxGroup {
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
"
|
|
316
|
-
|
|
317
|
-
|
|
1018
|
+
/**
|
|
1019
|
+
* All checkboxes must be checked.
|
|
1020
|
+
*/
|
|
1021
|
+
"dsAllRequired"?: boolean;
|
|
1022
|
+
/**
|
|
1023
|
+
* Text for additional information shown below label
|
|
1024
|
+
*/
|
|
1025
|
+
"dsAssistiveText"?: string;
|
|
1026
|
+
/**
|
|
1027
|
+
* Passed to the `checked` attribute of the `input` of parent checkbox element.
|
|
1028
|
+
*/
|
|
1029
|
+
"dsChecked"?: boolean;
|
|
1030
|
+
/**
|
|
1031
|
+
* `vertical` displays checkboxes stacked `horizontal` displays checkboxes side by side
|
|
1032
|
+
*/
|
|
1033
|
+
"dsDirection"?: 'horizontal' | 'vertical';
|
|
1034
|
+
/**
|
|
1035
|
+
* Disables all checkboxes in the checkbox group
|
|
1036
|
+
*/
|
|
1037
|
+
"dsDisabled"?: boolean;
|
|
1038
|
+
/**
|
|
1039
|
+
* Error message shown below the checkbox group. If set, the checkbox group is shown in an invalid state.
|
|
1040
|
+
*/
|
|
1041
|
+
"dsErrorText"?: string;
|
|
1042
|
+
/**
|
|
1043
|
+
* Label of the checkbox group
|
|
1044
|
+
*/
|
|
1045
|
+
"dsLegend"?: string;
|
|
1046
|
+
/**
|
|
1047
|
+
* None of the checkboxes need to be checked.
|
|
1048
|
+
*/
|
|
1049
|
+
"dsOptional"?: boolean;
|
|
1050
|
+
/**
|
|
1051
|
+
* Text shown alongside label, if the checkbox button group is set as optional.
|
|
1052
|
+
*/
|
|
1053
|
+
"dsOptionalText"?: string;
|
|
1054
|
+
/**
|
|
1055
|
+
* One or more checkboxes must be checked.
|
|
1056
|
+
*/
|
|
1057
|
+
"dsRequired"?: boolean;
|
|
1058
|
+
/**
|
|
1059
|
+
* If given, a parent checkbox with this text will be rendered above slotted checkboxes
|
|
1060
|
+
*/
|
|
1061
|
+
"dsText"?: string;
|
|
1062
|
+
/**
|
|
1063
|
+
* `dsCheckboxGroupChange` event is emitted when the `checked` state of a checkbox rendered inside the group changes. This is used internally to synchronize the state of checkbox groups.
|
|
1064
|
+
*/
|
|
318
1065
|
"onDsCheckboxGroupChange"?: (event: DsCheckboxGroupCustomEvent<DsCheckboxGroupChangeEvent>) => void;
|
|
1066
|
+
/**
|
|
1067
|
+
* `dsCheckboxGroupIndeterminateChildChange` event is emitted when the `indeterminate` state of a nested checkbox group is changed. This is used internally to synchronize the state of checkbox groups.
|
|
1068
|
+
*/
|
|
319
1069
|
"onDsCheckboxGroupIndeterminateChildChange"?: (event: DsCheckboxGroupCustomEvent<DsCheckboxGroupIndeterminateChildChangeEvent>) => void;
|
|
320
|
-
|
|
1070
|
+
/**
|
|
1071
|
+
* The `dsCheckboxGroupInvalidStateChange` event is emitted when the `dsErrorText` property changes. The event `detail` will be `false` if the `dsErrorText` is empty, otherwise `true`. This event is mainly used internallty to synchronize the invalid state of checkboxes.
|
|
1072
|
+
*/
|
|
1073
|
+
"onDsCheckboxGroupInvalidStateChange"?: (event: DsCheckboxGroupCustomEvent<boolean>) => void;
|
|
321
1074
|
}
|
|
322
1075
|
interface DsIcon {
|
|
323
|
-
|
|
1076
|
+
/**
|
|
1077
|
+
* Color of the icon
|
|
1078
|
+
*/
|
|
1079
|
+
"dsColour"?: string;
|
|
1080
|
+
/**
|
|
1081
|
+
* Passed to the `title` attribute of the `svg` element
|
|
1082
|
+
*/
|
|
1083
|
+
"dsHidden"?: boolean;
|
|
1084
|
+
/**
|
|
1085
|
+
* Name of the icon to display
|
|
1086
|
+
*/
|
|
1087
|
+
"dsName"?: string;
|
|
1088
|
+
/**
|
|
1089
|
+
* Passed to the `role` attribute of the `svg` element
|
|
1090
|
+
*/
|
|
1091
|
+
"dsRole"?: string;
|
|
1092
|
+
/**
|
|
1093
|
+
* Size of the icon
|
|
1094
|
+
*/
|
|
1095
|
+
"dsSize"?: Size;
|
|
1096
|
+
/**
|
|
1097
|
+
* Tooltip of the icon
|
|
1098
|
+
*/
|
|
324
1099
|
"dsTitle"?: string;
|
|
325
|
-
"hidden"?: boolean;
|
|
326
|
-
"name"?: string;
|
|
327
|
-
"role"?: string;
|
|
328
|
-
"size"?: string;
|
|
329
1100
|
}
|
|
330
1101
|
interface DsInputValidity {
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
1102
|
+
/**
|
|
1103
|
+
* Passed to the `aria-atomic` attribute of the container `div` element. Disabled if client-side validation is not used.
|
|
1104
|
+
*/
|
|
1105
|
+
"dsAriaAtomic"?: 'true' | 'false';
|
|
1106
|
+
/**
|
|
1107
|
+
* Passed to the `aria-live` attribute of the container `div` element. Disabled if client-side validation is not used.
|
|
1108
|
+
*/
|
|
1109
|
+
"dsAriaLive"?: 'assertive' | 'polite';
|
|
1110
|
+
/**
|
|
1111
|
+
* Text to display in the validity message
|
|
1112
|
+
*/
|
|
1113
|
+
"dsText"?: string;
|
|
1114
|
+
/**
|
|
1115
|
+
* Type of the validity
|
|
1116
|
+
*/
|
|
1117
|
+
"dsType"?: 'error' | 'success';
|
|
1118
|
+
/**
|
|
1119
|
+
* Passed to the `role` attribute of the container `div` element. Disabled if client-side validation is not used.
|
|
1120
|
+
*/
|
|
1121
|
+
"dsValidityRole"?: 'alert' | 'status';
|
|
334
1122
|
}
|
|
335
1123
|
interface DsLink {
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
"
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
"
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
"
|
|
348
|
-
|
|
1124
|
+
/**
|
|
1125
|
+
* Passed to the `aria-label` attribute of the `a` element
|
|
1126
|
+
*/
|
|
1127
|
+
"dsAriaLabel"?: string;
|
|
1128
|
+
/**
|
|
1129
|
+
* Colour of the link. Overrides default colour.
|
|
1130
|
+
*/
|
|
1131
|
+
"dsColour"?: 'black' | 'white';
|
|
1132
|
+
/**
|
|
1133
|
+
* Passed to the `download` attribute of the `a` element
|
|
1134
|
+
*/
|
|
1135
|
+
"dsDownload"?: boolean;
|
|
1136
|
+
/**
|
|
1137
|
+
* Passed to the `href` attribute of the `a` element
|
|
1138
|
+
*/
|
|
1139
|
+
"dsHref": string;
|
|
1140
|
+
/**
|
|
1141
|
+
* Icon to display alongside link
|
|
1142
|
+
*/
|
|
1143
|
+
"dsIcon"?: string;
|
|
1144
|
+
/**
|
|
1145
|
+
* Passed to the `dsHidden` property of the `ds-icon` element
|
|
1146
|
+
*/
|
|
1147
|
+
"dsIconHidden"?: boolean;
|
|
1148
|
+
/**
|
|
1149
|
+
* Whether to display the icon before or after the link
|
|
1150
|
+
*/
|
|
1151
|
+
"dsIconPosition"?: LinkIconPosition;
|
|
1152
|
+
/**
|
|
1153
|
+
* Passed to the `dsTitle` property of the `ds-icon` element
|
|
1154
|
+
*/
|
|
1155
|
+
"dsIconTitle"?: string;
|
|
1156
|
+
/**
|
|
1157
|
+
* Size of the link
|
|
1158
|
+
*/
|
|
1159
|
+
"dsSize"?: LinkSize;
|
|
1160
|
+
/**
|
|
1161
|
+
* Passed to the `target` attribute of the `a` element
|
|
1162
|
+
*/
|
|
1163
|
+
"dsTarget"?: LinkTarget;
|
|
1164
|
+
/**
|
|
1165
|
+
* Text content of the link
|
|
1166
|
+
*/
|
|
1167
|
+
"dsText": string;
|
|
1168
|
+
/**
|
|
1169
|
+
* Variant of the link
|
|
1170
|
+
*/
|
|
1171
|
+
"dsVariant"?: LinkVariant;
|
|
1172
|
+
/**
|
|
1173
|
+
* Font weight of the link
|
|
1174
|
+
*/
|
|
1175
|
+
"dsWeight"?: LinkWeight;
|
|
349
1176
|
}
|
|
350
1177
|
interface DsLinkWithArrow {
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
"
|
|
355
|
-
|
|
356
|
-
|
|
1178
|
+
/**
|
|
1179
|
+
* Passed to the `aria-label` attribute of the `a` element
|
|
1180
|
+
*/
|
|
1181
|
+
"dsAriaLabel"?: string;
|
|
1182
|
+
/**
|
|
1183
|
+
* Passed to the `href` attribute of the `a` element
|
|
1184
|
+
*/
|
|
1185
|
+
"dsHref": string;
|
|
1186
|
+
/**
|
|
1187
|
+
* Whether to display the arrow icon before or after the link
|
|
1188
|
+
*/
|
|
1189
|
+
"dsIconPosition"?: LinkIconPosition;
|
|
1190
|
+
/**
|
|
1191
|
+
* Passed to the `target` attribute of the `a` element
|
|
1192
|
+
*/
|
|
1193
|
+
"dsTarget"?: LinkTarget;
|
|
1194
|
+
/**
|
|
1195
|
+
* Text content of the link
|
|
1196
|
+
*/
|
|
1197
|
+
"dsText"?: string;
|
|
1198
|
+
}
|
|
1199
|
+
interface DsRadioButton {
|
|
1200
|
+
/**
|
|
1201
|
+
* Text for additional information shown below label
|
|
1202
|
+
*/
|
|
1203
|
+
"dsAssistiveText"?: string;
|
|
1204
|
+
/**
|
|
1205
|
+
* Passed to the `checked` attribute of the `input` element of the rendered radio button.
|
|
1206
|
+
*/
|
|
1207
|
+
"dsChecked"?: boolean;
|
|
1208
|
+
/**
|
|
1209
|
+
* Passed to the `disabled` attribute of the `input` element of the rendered radio button.
|
|
1210
|
+
*/
|
|
1211
|
+
"dsDisabled"?: boolean;
|
|
1212
|
+
/**
|
|
1213
|
+
* Error message shown below the radio button. If set, the radio button is shown in an invalid state.
|
|
1214
|
+
*/
|
|
1215
|
+
"dsErrorText"?: string;
|
|
1216
|
+
/**
|
|
1217
|
+
* Can be used to disable client-side validation. Used internally in radio button group to disable error messages for a single radio button.
|
|
1218
|
+
*/
|
|
1219
|
+
"dsErrorsDisabled"?: boolean;
|
|
1220
|
+
/**
|
|
1221
|
+
* Passed to the `id` attriubte of the `input` element of the rendered radio button.
|
|
1222
|
+
*/
|
|
1223
|
+
"dsId"?: string;
|
|
1224
|
+
/**
|
|
1225
|
+
* Label of the radio button
|
|
1226
|
+
*/
|
|
1227
|
+
"dsLegend"?: string;
|
|
1228
|
+
/**
|
|
1229
|
+
* Passed to the `required` attribute of the `input` element of the rendered radio button.
|
|
1230
|
+
*/
|
|
1231
|
+
"dsRequired"?: boolean;
|
|
1232
|
+
/**
|
|
1233
|
+
* The text of the radio button
|
|
1234
|
+
*/
|
|
1235
|
+
"dsText"?: string;
|
|
1236
|
+
/**
|
|
1237
|
+
* Passed to the `value` attribute of the `input` element of the rendered radio button.
|
|
1238
|
+
*/
|
|
1239
|
+
"dsValue"?: string;
|
|
1240
|
+
/**
|
|
1241
|
+
* Event emitted when the `dsChecked` state changes.
|
|
1242
|
+
*/
|
|
1243
|
+
"onDsChange"?: (event: DsRadioButtonCustomEvent<boolean>) => void;
|
|
1244
|
+
/**
|
|
1245
|
+
* Event emitted when the radio button is set to checked state. Used to notify a parent radio button group of a state change.
|
|
1246
|
+
*/
|
|
1247
|
+
"onDsRadioButtonChecked"?: (event: DsRadioButtonCustomEvent<void>) => void;
|
|
1248
|
+
}
|
|
1249
|
+
interface DsRadioButtonGroup {
|
|
1250
|
+
/**
|
|
1251
|
+
* Text for additional information shown below legend
|
|
1252
|
+
*/
|
|
1253
|
+
"dsAssistiveText"?: string;
|
|
1254
|
+
/**
|
|
1255
|
+
* `vertical` displays radio buttons stacked `horizontal` displays radio buttons side by side
|
|
1256
|
+
*/
|
|
1257
|
+
"dsDirection"?: 'horizontal' | 'vertical';
|
|
1258
|
+
/**
|
|
1259
|
+
* Error message shown below the text input. If set, the text input is shown in an invalid state.
|
|
1260
|
+
*/
|
|
1261
|
+
"dsErrorText"?: string;
|
|
1262
|
+
/**
|
|
1263
|
+
* Label for the radio button group
|
|
1264
|
+
*/
|
|
1265
|
+
"dsLegend"?: string;
|
|
1266
|
+
/**
|
|
1267
|
+
* One or more radio buttons must be checked.
|
|
1268
|
+
*/
|
|
1269
|
+
"dsRequired"?: boolean;
|
|
1270
|
+
/**
|
|
1271
|
+
* Determines which radio button in the group is selected. The radio button with the matching `value` will be selected.
|
|
1272
|
+
*/
|
|
1273
|
+
"dsValue"?: string;
|
|
1274
|
+
/**
|
|
1275
|
+
* The `dsChange` event is emitted each time the `dsValue` of the radio button group is changed.
|
|
1276
|
+
*/
|
|
1277
|
+
"onDsChange"?: (event: DsRadioButtonGroupCustomEvent<string>) => void;
|
|
1278
|
+
/**
|
|
1279
|
+
* The `dsRadioGroupInvalidStateChange` event is emitted when the `dsErrorText` property changes. The event `detail` will be `false` if the `dsErrorText` is empty, otherwise `true`. This event is mainly used internallty to synchronize the invalid state of radio buttons.
|
|
1280
|
+
*/
|
|
1281
|
+
"onDsRadioGroupInvalidStateChange"?: (event: DsRadioButtonGroupCustomEvent<boolean>) => void;
|
|
1282
|
+
/**
|
|
1283
|
+
* The `dsRadioGroupValueChange` event is emitted when a radio button inside the radio button group is selected. This event is mainly used internally to synchronize the state of radio buttons.
|
|
1284
|
+
*/
|
|
1285
|
+
"onDsRadioGroupValueChange"?: (event: DsRadioButtonGroupCustomEvent<string | undefined>) => void;
|
|
1286
|
+
}
|
|
1287
|
+
interface DsSpinner {
|
|
1288
|
+
/**
|
|
1289
|
+
* Visually hidden information for screen readers
|
|
1290
|
+
*/
|
|
1291
|
+
"dsHiddenAssistiveText"?: string;
|
|
1292
|
+
/**
|
|
1293
|
+
* Size of the spinner
|
|
1294
|
+
*/
|
|
1295
|
+
"dsSize"?: SpinnerSize;
|
|
1296
|
+
/**
|
|
1297
|
+
* Color of the spinner
|
|
1298
|
+
*/
|
|
1299
|
+
"dsSpinnerColor"?: SpinnerColor;
|
|
1300
|
+
/**
|
|
1301
|
+
* Where to display the `dsText` property
|
|
1302
|
+
*/
|
|
1303
|
+
"dsSpinnerTextPosition"?: SpinnerTextPosition;
|
|
1304
|
+
/**
|
|
1305
|
+
* Text to display alongside spinner
|
|
1306
|
+
*/
|
|
1307
|
+
"dsText"?: string;
|
|
1308
|
+
/**
|
|
1309
|
+
* Sets `aria-live="polite"` attribute to the spinner element
|
|
1310
|
+
*/
|
|
1311
|
+
"dsUseAriaLive"?: boolean;
|
|
1312
|
+
/**
|
|
1313
|
+
* Sets `role="alert"` attribute to the spinner element
|
|
1314
|
+
*/
|
|
1315
|
+
"dsUseRoleAlert"?: boolean;
|
|
357
1316
|
}
|
|
358
1317
|
interface DsTextInput {
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
"
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
"
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
"
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
"
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
"
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
"
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
"
|
|
1318
|
+
/**
|
|
1319
|
+
* Aria-label for action button for text inputs with type `password` or `search`. The action button for `search` text input is the clear button. The action button for `password` text input is the toggle visibility button.
|
|
1320
|
+
*/
|
|
1321
|
+
"dsActionButtonAriaLabel"?: string;
|
|
1322
|
+
/**
|
|
1323
|
+
* Passed to the `aria-describedby` attribute of the `input` element.
|
|
1324
|
+
*/
|
|
1325
|
+
"dsAriaDescribedby"?: string;
|
|
1326
|
+
/**
|
|
1327
|
+
* Passed to the `aria-label` attribute of the `input` element.
|
|
1328
|
+
*/
|
|
1329
|
+
"dsAriaLabel"?: string;
|
|
1330
|
+
/**
|
|
1331
|
+
* Passed to the `aria-labelledby` attribute of the `input` element.
|
|
1332
|
+
*/
|
|
1333
|
+
"dsAriaLabelledby"?: string;
|
|
1334
|
+
/**
|
|
1335
|
+
* Text for additional information shown below label
|
|
1336
|
+
*/
|
|
1337
|
+
"dsAssistiveText"?: string;
|
|
1338
|
+
/**
|
|
1339
|
+
* Passed to the `autocomplete` attribute of the `input` element.
|
|
1340
|
+
*/
|
|
1341
|
+
"dsAutocomplete"?: string;
|
|
1342
|
+
/**
|
|
1343
|
+
* Passed to the `disabled` attribute of the `input` element.
|
|
1344
|
+
*/
|
|
1345
|
+
"dsDisabled"?: boolean;
|
|
1346
|
+
/**
|
|
1347
|
+
* Error message shown below the text input. If set, the text input is shown in an invalid state.
|
|
1348
|
+
*/
|
|
1349
|
+
"dsErrorText"?: string;
|
|
1350
|
+
/**
|
|
1351
|
+
* Visually hidden additional information for screen readers
|
|
1352
|
+
*/
|
|
1353
|
+
"dsHiddenAssistiveText"?: string;
|
|
1354
|
+
/**
|
|
1355
|
+
* Icon to display at the start of the text input.
|
|
1356
|
+
*/
|
|
1357
|
+
"dsIcon"?: string;
|
|
1358
|
+
/**
|
|
1359
|
+
* Passed to the `id` of the `input` element.
|
|
1360
|
+
*/
|
|
1361
|
+
"dsId"?: string;
|
|
1362
|
+
/**
|
|
1363
|
+
* Label of the input
|
|
1364
|
+
*/
|
|
1365
|
+
"dsLabel"?: string;
|
|
1366
|
+
/**
|
|
1367
|
+
* Passed to the `max` attribute of the `input` element.
|
|
1368
|
+
*/
|
|
1369
|
+
"dsMax"?: number;
|
|
1370
|
+
/**
|
|
1371
|
+
* Passed to the `maxlength` attribute of the `input` element.
|
|
1372
|
+
*/
|
|
1373
|
+
"dsMaxLength"?: number;
|
|
1374
|
+
/**
|
|
1375
|
+
* Passed to the `min` attribute of the `input` element.
|
|
1376
|
+
*/
|
|
1377
|
+
"dsMin"?: number;
|
|
1378
|
+
/**
|
|
1379
|
+
* Passed to the `name` attribute of the `input` element.
|
|
1380
|
+
*/
|
|
1381
|
+
"dsName"?: string;
|
|
1382
|
+
/**
|
|
1383
|
+
* Displays indicator that the text input is optional alongside label.
|
|
1384
|
+
*/
|
|
1385
|
+
"dsOptional"?: boolean;
|
|
1386
|
+
/**
|
|
1387
|
+
* Text shown alongside label, if the text input is set as optional.
|
|
1388
|
+
*/
|
|
1389
|
+
"dsOptionalText"?: string;
|
|
1390
|
+
/**
|
|
1391
|
+
* Passed to the `pattern` attribute of the `input` element.
|
|
1392
|
+
*/
|
|
1393
|
+
"dsPattern"?: string;
|
|
1394
|
+
/**
|
|
1395
|
+
* Passed to the `placeholder` of the `input` element.
|
|
1396
|
+
*/
|
|
1397
|
+
"dsPlaceholder"?: string;
|
|
1398
|
+
/**
|
|
1399
|
+
* Allows additional elements before or after the input field, such as units (e.g., currency, minutes, country codes).
|
|
1400
|
+
*/
|
|
1401
|
+
"dsPrefixText"?: string;
|
|
1402
|
+
/**
|
|
1403
|
+
* Passed to the `readonly` attribute of the `input` element.
|
|
1404
|
+
*/
|
|
1405
|
+
"dsReadonly"?: boolean;
|
|
1406
|
+
/**
|
|
1407
|
+
* Passed to the `required` attribute of the `input` element.
|
|
1408
|
+
*/
|
|
1409
|
+
"dsRequired"?: boolean;
|
|
1410
|
+
/**
|
|
1411
|
+
* Success message shown below the text input. If set, the text input is shown in a success state.
|
|
1412
|
+
*/
|
|
1413
|
+
"dsSuccessText"?: string;
|
|
1414
|
+
/**
|
|
1415
|
+
* Allows additional elements before or after the input field, such as units (e.g., currency, minutes, country codes).
|
|
1416
|
+
*/
|
|
1417
|
+
"dsSuffixText"?: string;
|
|
1418
|
+
/**
|
|
1419
|
+
* Type of the text input, passed to the `type` attribute of the `input` element. A text input of type `search` has an action button to clear the input value if it is not empty. A text input of type `password` has an action button to toggle the visibility of the entered input.
|
|
1420
|
+
*/
|
|
1421
|
+
"dsType"?: DsTextInputType;
|
|
1422
|
+
/**
|
|
1423
|
+
* Passed to the `value` attribute of the `input` element.
|
|
1424
|
+
*/
|
|
1425
|
+
"dsValue"?: string;
|
|
1426
|
+
/**
|
|
1427
|
+
* The `dsChange` event is fired each time the `value` property of the `ds-text-input` element is changed. This may be a side effect of other events such as `dsClear` or `dsInput` event, or when the `value` property is programmatically changed.
|
|
1428
|
+
*/
|
|
1429
|
+
"onDsChange"?: (event: DsTextInputCustomEvent<Omit<DsTextInputEvent, 'event'>>) => void;
|
|
1430
|
+
/**
|
|
1431
|
+
* The `dsClear` event is fired when the clear button of a input of type `search` is pressed.
|
|
1432
|
+
*/
|
|
1433
|
+
"onDsClear"?: (event: DsTextInputCustomEvent<DsTextInputEvent>) => void;
|
|
1434
|
+
/**
|
|
1435
|
+
* The `dsInput` event is fired when the user modifies the input's value. The event is fired on each keystroke.
|
|
1436
|
+
*/
|
|
1437
|
+
"onDsInput"?: (event: DsTextInputCustomEvent<DsTextInputEvent<InputEvent>>) => void;
|
|
387
1438
|
}
|
|
388
1439
|
interface DsVisuallyHidden {
|
|
389
1440
|
}
|
|
390
1441
|
interface IntrinsicElements {
|
|
391
1442
|
"ds-accordion": DsAccordion;
|
|
392
1443
|
"ds-button": DsButton;
|
|
1444
|
+
"ds-card": DsCard;
|
|
393
1445
|
"ds-checkbox": DsCheckbox;
|
|
394
1446
|
"ds-checkbox-group": DsCheckboxGroup;
|
|
395
1447
|
"ds-icon": DsIcon;
|
|
396
1448
|
"ds-input-validity": DsInputValidity;
|
|
397
1449
|
"ds-link": DsLink;
|
|
398
1450
|
"ds-link-with-arrow": DsLinkWithArrow;
|
|
1451
|
+
"ds-radio-button": DsRadioButton;
|
|
1452
|
+
"ds-radio-button-group": DsRadioButtonGroup;
|
|
1453
|
+
"ds-spinner": DsSpinner;
|
|
399
1454
|
"ds-text-input": DsTextInput;
|
|
400
1455
|
"ds-visually-hidden": DsVisuallyHidden;
|
|
401
1456
|
}
|
|
@@ -406,12 +1461,16 @@ declare module "@stencil/core" {
|
|
|
406
1461
|
interface IntrinsicElements {
|
|
407
1462
|
"ds-accordion": LocalJSX.DsAccordion & JSXBase.HTMLAttributes<HTMLDsAccordionElement>;
|
|
408
1463
|
"ds-button": LocalJSX.DsButton & JSXBase.HTMLAttributes<HTMLDsButtonElement>;
|
|
1464
|
+
"ds-card": LocalJSX.DsCard & JSXBase.HTMLAttributes<HTMLDsCardElement>;
|
|
409
1465
|
"ds-checkbox": LocalJSX.DsCheckbox & JSXBase.HTMLAttributes<HTMLDsCheckboxElement>;
|
|
410
1466
|
"ds-checkbox-group": LocalJSX.DsCheckboxGroup & JSXBase.HTMLAttributes<HTMLDsCheckboxGroupElement>;
|
|
411
1467
|
"ds-icon": LocalJSX.DsIcon & JSXBase.HTMLAttributes<HTMLDsIconElement>;
|
|
412
1468
|
"ds-input-validity": LocalJSX.DsInputValidity & JSXBase.HTMLAttributes<HTMLDsInputValidityElement>;
|
|
413
1469
|
"ds-link": LocalJSX.DsLink & JSXBase.HTMLAttributes<HTMLDsLinkElement>;
|
|
414
1470
|
"ds-link-with-arrow": LocalJSX.DsLinkWithArrow & JSXBase.HTMLAttributes<HTMLDsLinkWithArrowElement>;
|
|
1471
|
+
"ds-radio-button": LocalJSX.DsRadioButton & JSXBase.HTMLAttributes<HTMLDsRadioButtonElement>;
|
|
1472
|
+
"ds-radio-button-group": LocalJSX.DsRadioButtonGroup & JSXBase.HTMLAttributes<HTMLDsRadioButtonGroupElement>;
|
|
1473
|
+
"ds-spinner": LocalJSX.DsSpinner & JSXBase.HTMLAttributes<HTMLDsSpinnerElement>;
|
|
415
1474
|
"ds-text-input": LocalJSX.DsTextInput & JSXBase.HTMLAttributes<HTMLDsTextInputElement>;
|
|
416
1475
|
"ds-visually-hidden": LocalJSX.DsVisuallyHidden & JSXBase.HTMLAttributes<HTMLDsVisuallyHiddenElement>;
|
|
417
1476
|
}
|