@infineon/infineon-design-system-stencil 32.1.2 → 32.1.3--canary.1732.ff567db738403bfab315bf3a9dfc834b2dbbee94.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/ifx-alert_2.cjs.entry.js +1 -1
- package/dist/cjs/ifx-basic-table.cjs.entry.js +1 -1
- package/dist/cjs/ifx-faq.cjs.entry.js +1 -1
- package/dist/cjs/ifx-filter-accordion.cjs.entry.js +2 -2
- package/dist/cjs/ifx-filter-bar.cjs.entry.js +1 -1
- package/dist/cjs/ifx-filter-search.cjs.entry.js +1 -1
- package/dist/cjs/ifx-filter-type-group.cjs.entry.js +1 -1
- package/dist/cjs/ifx-list-entry.cjs.entry.js +1 -1
- package/dist/cjs/ifx-radio-button-group.cjs.entry.js +61 -0
- package/dist/cjs/ifx-radio-button-group.cjs.entry.js.map +1 -0
- package/dist/cjs/ifx-radio-button.cjs.entry.js +11 -4
- package/dist/cjs/ifx-radio-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ifx-search-bar.cjs.entry.js +1 -1
- package/dist/cjs/ifx-search-field.cjs.entry.js +1 -1
- package/dist/cjs/ifx-segment.cjs.entry.js +1 -1
- package/dist/cjs/ifx-segmented-control.cjs.entry.js +2 -2
- package/dist/cjs/ifx-select.cjs.entry.js +2 -2
- package/dist/cjs/ifx-slider.cjs.entry.js +2 -2
- package/dist/cjs/ifx-spinner_2.cjs.entry.js +6 -6
- package/dist/cjs/ifx-status.cjs.entry.js +1 -1
- package/dist/cjs/ifx-step.cjs.entry.js +4 -4
- package/dist/cjs/ifx-stepper.cjs.entry.js +2 -2
- package/dist/cjs/ifx-switch.cjs.entry.js +1 -1
- package/dist/cjs/ifx-tab.cjs.entry.js +1 -1
- package/dist/cjs/ifx-table.cjs.entry.js +2 -2
- package/dist/cjs/ifx-tabs.cjs.entry.js +2 -2
- package/dist/cjs/ifx-tag.cjs.entry.js +1 -1
- package/dist/cjs/ifx-templates-ui.cjs.entry.js +1 -1
- package/dist/cjs/ifx-textarea.cjs.entry.js +1 -1
- package/dist/cjs/ifx-tooltip.cjs.entry.js +4 -4
- package/dist/cjs/index-1ce5aae1.js +4 -0
- package/dist/cjs/infineon-design-system-stencil.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/radio-button/radio-button.css +4 -0
- package/dist/collection/components/radio-button/radio-button.js +25 -2
- package/dist/collection/components/radio-button/radio-button.js.map +1 -1
- package/dist/collection/components/radio-button-group/radio-button-group.css +59 -0
- package/dist/collection/components/radio-button-group/radio-button-group.js +238 -0
- package/dist/collection/components/radio-button-group/radio-button-group.js.map +1 -0
- package/dist/collection/components/radio-button-group/radio-button-group.stories.js +143 -0
- package/dist/collection/components/radio-button-group/radio-button-group.stories.js.map +1 -0
- package/dist/collection/components/search-bar/search-bar.js +1 -1
- package/dist/collection/components/search-field/search-field.js +1 -1
- package/dist/collection/components/segmented-control/segment/segment.js +1 -1
- package/dist/collection/components/segmented-control/segmented-control.js +2 -2
- package/dist/collection/components/select/single-select/select.js +2 -2
- package/dist/collection/components/slider/slider.js +2 -2
- package/dist/collection/components/spinner/spinner.js +2 -2
- package/dist/collection/components/status/status.js +1 -1
- package/dist/collection/components/stepper/step/step.js +4 -4
- package/dist/collection/components/stepper/stepper.js +2 -2
- package/dist/collection/components/switch/switch.js +1 -1
- package/dist/collection/components/table-advanced-version/filter-bar/filter-bar.js +1 -1
- package/dist/collection/components/table-advanced-version/filter-type-group/filter-accordion/filter-accordion.js +2 -2
- package/dist/collection/components/table-advanced-version/filter-type-group/filter-search/filter-search.js +1 -1
- package/dist/collection/components/table-advanced-version/filter-type-group/filter-type-group.js +1 -1
- package/dist/collection/components/table-advanced-version/list/list-entry/list-entry.js +1 -1
- package/dist/collection/components/table-advanced-version/table.js +2 -2
- package/dist/collection/components/table-basic-version/table.js +1 -1
- package/dist/collection/components/tabs/tab.js +1 -1
- package/dist/collection/components/tabs/tabs.js +2 -2
- package/dist/collection/components/tag/tag.js +1 -1
- package/dist/collection/components/templates/template/template.js +1 -1
- package/dist/collection/components/templates/templates-ui/templates-ui.js +1 -1
- package/dist/collection/components/text-field/text-field.js +4 -4
- package/dist/collection/components/textarea/textarea.js +1 -1
- package/dist/collection/components/tooltip/tooltip.js +4 -4
- package/dist/collection/stories/setup-and-installation/faq/faq.js +1 -1
- package/dist/components/ifx-basic-table.js +1 -1
- package/dist/components/ifx-faq.js +1 -1
- package/dist/components/ifx-filter-accordion.js +2 -2
- package/dist/components/ifx-filter-bar.js +1 -1
- package/dist/components/ifx-filter-search.js +2 -2
- package/dist/components/ifx-filter-type-group.js +1 -1
- package/dist/components/ifx-list-entry.js +2 -2
- package/dist/components/ifx-pagination.js +1 -1
- package/dist/components/ifx-radio-button-group.d.ts +11 -0
- package/dist/components/ifx-radio-button-group.js +91 -0
- package/dist/components/ifx-radio-button-group.js.map +1 -0
- package/dist/components/ifx-radio-button.js +1 -1
- package/dist/components/ifx-search-bar.js +2 -2
- package/dist/components/ifx-search-field.js +1 -1
- package/dist/components/ifx-segment.js +1 -1
- package/dist/components/ifx-segmented-control.js +2 -2
- package/dist/components/ifx-select.js +1 -1
- package/dist/components/ifx-set-filter.js +2 -2
- package/dist/components/ifx-slider.js +2 -2
- package/dist/components/ifx-spinner.js +1 -1
- package/dist/components/ifx-status.js +1 -1
- package/dist/components/ifx-step.js +4 -4
- package/dist/components/ifx-stepper.js +2 -2
- package/dist/components/ifx-switch.js +1 -1
- package/dist/components/ifx-tab.js +1 -1
- package/dist/components/ifx-table.js +4 -4
- package/dist/components/ifx-tabs.js +2 -2
- package/dist/components/ifx-tag.js +1 -1
- package/dist/components/ifx-template.js +1 -1
- package/dist/components/ifx-templates-ui.js +4 -4
- package/dist/components/ifx-text-field.js +1 -1
- package/dist/components/ifx-textarea.js +1 -1
- package/dist/components/ifx-tooltip.js +4 -4
- package/dist/components/{p-30f4f454.js → p-53e64722.js} +2 -2
- package/dist/components/{p-30f4f454.js.map → p-53e64722.js.map} +1 -1
- package/dist/components/{p-47853a7b.js → p-72d634c8.js} +3 -3
- package/dist/components/{p-47853a7b.js.map → p-72d634c8.js.map} +1 -1
- package/dist/components/{p-80856f14.js → p-8373dd14.js} +4 -4
- package/dist/components/{p-80856f14.js.map → p-8373dd14.js.map} +1 -1
- package/dist/components/{p-25dce5bf.js → p-95e7aaa8.js} +2 -2
- package/dist/components/{p-25dce5bf.js.map → p-95e7aaa8.js.map} +1 -1
- package/dist/components/{p-8002e444.js → p-d41c9944.js} +3 -3
- package/dist/components/{p-8002e444.js.map → p-d41c9944.js.map} +1 -1
- package/dist/components/{p-977668df.js → p-d52bf3aa.js} +14 -6
- package/dist/components/p-d52bf3aa.js.map +1 -0
- package/dist/components/{p-3d46d2af.js → p-df959be0.js} +5 -5
- package/dist/components/{p-3d46d2af.js.map → p-df959be0.js.map} +1 -1
- package/dist/esm/ifx-alert_2.entry.js +1 -1
- package/dist/esm/ifx-basic-table.entry.js +1 -1
- package/dist/esm/ifx-faq.entry.js +1 -1
- package/dist/esm/ifx-filter-accordion.entry.js +2 -2
- package/dist/esm/ifx-filter-bar.entry.js +1 -1
- package/dist/esm/ifx-filter-search.entry.js +1 -1
- package/dist/esm/ifx-filter-type-group.entry.js +1 -1
- package/dist/esm/ifx-list-entry.entry.js +1 -1
- package/dist/esm/ifx-radio-button-group.entry.js +57 -0
- package/dist/esm/ifx-radio-button-group.entry.js.map +1 -0
- package/dist/esm/ifx-radio-button.entry.js +11 -4
- package/dist/esm/ifx-radio-button.entry.js.map +1 -1
- package/dist/esm/ifx-search-bar.entry.js +1 -1
- package/dist/esm/ifx-search-field.entry.js +1 -1
- package/dist/esm/ifx-segment.entry.js +1 -1
- package/dist/esm/ifx-segmented-control.entry.js +2 -2
- package/dist/esm/ifx-select.entry.js +2 -2
- package/dist/esm/ifx-slider.entry.js +2 -2
- package/dist/esm/ifx-spinner_2.entry.js +6 -6
- package/dist/esm/ifx-status.entry.js +1 -1
- package/dist/esm/ifx-step.entry.js +4 -4
- package/dist/esm/ifx-stepper.entry.js +2 -2
- package/dist/esm/ifx-switch.entry.js +1 -1
- package/dist/esm/ifx-tab.entry.js +1 -1
- package/dist/esm/ifx-table.entry.js +2 -2
- package/dist/esm/ifx-tabs.entry.js +2 -2
- package/dist/esm/ifx-tag.entry.js +1 -1
- package/dist/esm/ifx-templates-ui.entry.js +1 -1
- package/dist/esm/ifx-textarea.entry.js +1 -1
- package/dist/esm/ifx-tooltip.entry.js +4 -4
- package/dist/esm/index-b4eaf00e.js +4 -0
- package/dist/esm/infineon-design-system-stencil.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/infineon-design-system-stencil/infineon-design-system-stencil.esm.js +1 -1
- package/dist/infineon-design-system-stencil/infineon-design-system-stencil.esm.js.map +1 -1
- package/dist/infineon-design-system-stencil/{p-c8fecc8e.entry.js → p-02bff047.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/p-0c23a1af.entry.js +2 -0
- package/dist/infineon-design-system-stencil/{p-939f2f37.entry.js.map → p-0c23a1af.entry.js.map} +1 -1
- package/dist/infineon-design-system-stencil/{p-2d8c79bc.entry.js → p-11e74a1c.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/p-1715a11f.entry.js +2 -0
- package/dist/infineon-design-system-stencil/p-1715a11f.entry.js.map +1 -0
- package/dist/infineon-design-system-stencil/{p-0c747aac.entry.js → p-26b3022c.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-9901114e.entry.js → p-3246cb71.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-d2998185.entry.js → p-368f2d4e.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-272aab7f.entry.js → p-3ac58e09.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-8276469c.entry.js → p-504e2445.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-1a93de53.entry.js → p-57268492.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-8ab52cac.entry.js → p-5e9f471c.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-ccba569e.entry.js → p-63f61cb7.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-1b907dbd.entry.js → p-647a5858.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-260c4f53.entry.js → p-760821b1.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-b0156752.entry.js → p-78abaef5.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-386f62f0.entry.js → p-79762454.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-70e4a919.entry.js → p-7a9662ce.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/p-8475e064.entry.js +2 -0
- package/dist/infineon-design-system-stencil/{p-16430d76.entry.js → p-bf9cd342.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-65b50486.entry.js → p-c09d77d6.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-f9298124.entry.js → p-ccbab299.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-1c869534.entry.js → p-cce5d1dc.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-7b9fd2df.entry.js → p-d121416b.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-182854c8.entry.js → p-daa2d68b.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/p-e0b21b23.entry.js +2 -0
- package/dist/infineon-design-system-stencil/p-e0b21b23.entry.js.map +1 -0
- package/dist/infineon-design-system-stencil/{p-b1bd480b.entry.js → p-e2f76634.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-f8f10567.entry.js → p-e819ac3f.entry.js} +2 -2
- package/dist/infineon-design-system-stencil/{p-37e5b4b4.entry.js → p-ec7116c4.entry.js} +2 -2
- package/dist/types/components/radio-button/radio-button.d.ts +2 -0
- package/dist/types/components/radio-button-group/radio-button-group.d.ts +19 -0
- package/dist/types/components/radio-button-group/radio-button-group.stories.d.ts +171 -0
- package/dist/types/components.d.ts +30 -0
- package/package.json +1 -1
- package/dist/components/p-977668df.js.map +0 -1
- package/dist/infineon-design-system-stencil/p-094349b2.entry.js +0 -2
- package/dist/infineon-design-system-stencil/p-094349b2.entry.js.map +0 -1
- package/dist/infineon-design-system-stencil/p-89c4fae2.entry.js +0 -2
- package/dist/infineon-design-system-stencil/p-939f2f37.entry.js +0 -2
- /package/dist/infineon-design-system-stencil/{p-c8fecc8e.entry.js.map → p-02bff047.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-2d8c79bc.entry.js.map → p-11e74a1c.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-0c747aac.entry.js.map → p-26b3022c.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-9901114e.entry.js.map → p-3246cb71.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-d2998185.entry.js.map → p-368f2d4e.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-272aab7f.entry.js.map → p-3ac58e09.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-8276469c.entry.js.map → p-504e2445.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-1a93de53.entry.js.map → p-57268492.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-8ab52cac.entry.js.map → p-5e9f471c.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-ccba569e.entry.js.map → p-63f61cb7.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-1b907dbd.entry.js.map → p-647a5858.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-260c4f53.entry.js.map → p-760821b1.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-b0156752.entry.js.map → p-78abaef5.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-386f62f0.entry.js.map → p-79762454.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-70e4a919.entry.js.map → p-7a9662ce.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-89c4fae2.entry.js.map → p-8475e064.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-16430d76.entry.js.map → p-bf9cd342.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-65b50486.entry.js.map → p-c09d77d6.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-f9298124.entry.js.map → p-ccbab299.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-1c869534.entry.js.map → p-cce5d1dc.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-7b9fd2df.entry.js.map → p-d121416b.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-182854c8.entry.js.map → p-daa2d68b.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-b1bd480b.entry.js.map → p-e2f76634.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-f8f10567.entry.js.map → p-e819ac3f.entry.js.map} +0 -0
- /package/dist/infineon-design-system-stencil/{p-37e5b4b4.entry.js.map → p-ec7116c4.entry.js.map} +0 -0
@@ -0,0 +1,59 @@
|
|
1
|
+
:root {
|
2
|
+
--ifx-font-family: "Source Sans 3";
|
3
|
+
font-family: var(--ifx-font-family, sans-serif);
|
4
|
+
}
|
5
|
+
|
6
|
+
.radio-button-group-container {
|
7
|
+
display: flex;
|
8
|
+
flex-direction: column;
|
9
|
+
}
|
10
|
+
|
11
|
+
.radio-button-group {
|
12
|
+
display: flex;
|
13
|
+
font-family: var(--ifx-font-family);
|
14
|
+
gap: 8px;
|
15
|
+
}
|
16
|
+
.radio-button-group.horizontal {
|
17
|
+
flex-direction: row;
|
18
|
+
column-gap: 12px;
|
19
|
+
}
|
20
|
+
.radio-button-group.vertical {
|
21
|
+
flex-direction: column;
|
22
|
+
row-gap: 12px;
|
23
|
+
}
|
24
|
+
|
25
|
+
.group-label {
|
26
|
+
font: 400 0.75rem/1rem "Source Sans 3";
|
27
|
+
margin-bottom: 8px;
|
28
|
+
text-align: left;
|
29
|
+
text-underline-position: from-font;
|
30
|
+
text-decoration-skip-ink: none;
|
31
|
+
}
|
32
|
+
|
33
|
+
.caption {
|
34
|
+
margin-top: 8px;
|
35
|
+
align-self: flex-start;
|
36
|
+
display: flex;
|
37
|
+
width: 100%;
|
38
|
+
column-gap: 8px;
|
39
|
+
justify-content: space-between;
|
40
|
+
}
|
41
|
+
.caption.default {
|
42
|
+
color: #1D1D1D;
|
43
|
+
}
|
44
|
+
.caption.error {
|
45
|
+
color: #CD002F;
|
46
|
+
}
|
47
|
+
|
48
|
+
.caption-text {
|
49
|
+
font: 400 0.75rem/1rem "Source Sans 3";
|
50
|
+
flex: 1;
|
51
|
+
text-align: left;
|
52
|
+
text-underline-position: from-font;
|
53
|
+
text-decoration-skip-ink: none;
|
54
|
+
}
|
55
|
+
|
56
|
+
.caption-icon {
|
57
|
+
align-self: flex-start;
|
58
|
+
display: block;
|
59
|
+
}
|
@@ -0,0 +1,238 @@
|
|
1
|
+
import { h } from "@stencil/core";
|
2
|
+
export class RadioButtonGroup {
|
3
|
+
constructor() {
|
4
|
+
this.errorStates = new Map();
|
5
|
+
this.alignment = 'vertical';
|
6
|
+
this.groupLabelText = 'Group Label Text';
|
7
|
+
this.hasErrors = false;
|
8
|
+
this.handleSlotChange = () => {
|
9
|
+
this.initializeState();
|
10
|
+
};
|
11
|
+
}
|
12
|
+
handleRadioButtonError(event) {
|
13
|
+
const radioButton = event.target;
|
14
|
+
if (radioButton.tagName === 'ifx-radio-button') {
|
15
|
+
this.errorStates.set(radioButton, event.detail);
|
16
|
+
this.updateHasErrors();
|
17
|
+
}
|
18
|
+
}
|
19
|
+
// Method to set the error state of all radio-butttons in the group
|
20
|
+
async setGroupError(error) {
|
21
|
+
const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));
|
22
|
+
radioButtons.forEach((radioButton) => {
|
23
|
+
radioButton.error = error;
|
24
|
+
});
|
25
|
+
}
|
26
|
+
componentWillLoad() {
|
27
|
+
this.initializeState();
|
28
|
+
}
|
29
|
+
initializeState() {
|
30
|
+
this.errorStates.clear();
|
31
|
+
const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));
|
32
|
+
radioButtons.forEach((radioButton) => {
|
33
|
+
if (!this.errorStates.has(radioButton)) {
|
34
|
+
this.errorStates.set(radioButton, radioButton.error || false);
|
35
|
+
}
|
36
|
+
});
|
37
|
+
this.updateHasErrors();
|
38
|
+
}
|
39
|
+
updateHasErrors() {
|
40
|
+
this.hasErrors = Array.from(this.errorStates.values()).some((error) => error);
|
41
|
+
}
|
42
|
+
render() {
|
43
|
+
return (h("div", { key: 'e9c42096ac6db5957388636ba18d289cde561a54', class: 'radio-button-group-container' }, this.showGroupLabel ? h("div", { class: 'group-label' }, this.groupLabelText, " *") : '', h("div", { key: '95f5a1644f8780d7721ebe539b04d60898e34dc5', class: `radio-button-group ${this.alignment} ${this.size}` }, h("slot", { key: '94a278c73773b60156cdc0d30d856426181a8af9', onSlotchange: this.handleSlotChange })), this.showCaption ? (h("div", { class: `caption ${this.hasErrors ? 'error' : 'default'}` }, this.showCaptionIcon ? h("div", { class: 'caption-icon' }, h("ifx-icon", { icon: "c-info-16" })) : '', h("div", { class: 'caption-text' }, this.captionText))) : ''));
|
44
|
+
}
|
45
|
+
static get is() { return "ifx-radio-button-group"; }
|
46
|
+
static get encapsulation() { return "shadow"; }
|
47
|
+
static get formAssociated() { return true; }
|
48
|
+
static get originalStyleUrls() {
|
49
|
+
return {
|
50
|
+
"$": ["radio-button-group.scss"]
|
51
|
+
};
|
52
|
+
}
|
53
|
+
static get styleUrls() {
|
54
|
+
return {
|
55
|
+
"$": ["radio-button-group.css"]
|
56
|
+
};
|
57
|
+
}
|
58
|
+
static get properties() {
|
59
|
+
return {
|
60
|
+
"alignment": {
|
61
|
+
"type": "string",
|
62
|
+
"mutable": false,
|
63
|
+
"complexType": {
|
64
|
+
"original": "'horizontal' | 'vertical'",
|
65
|
+
"resolved": "\"horizontal\" | \"vertical\"",
|
66
|
+
"references": {}
|
67
|
+
},
|
68
|
+
"required": false,
|
69
|
+
"optional": false,
|
70
|
+
"docs": {
|
71
|
+
"tags": [],
|
72
|
+
"text": ""
|
73
|
+
},
|
74
|
+
"getter": false,
|
75
|
+
"setter": false,
|
76
|
+
"attribute": "alignment",
|
77
|
+
"reflect": false,
|
78
|
+
"defaultValue": "'vertical'"
|
79
|
+
},
|
80
|
+
"size": {
|
81
|
+
"type": "string",
|
82
|
+
"mutable": false,
|
83
|
+
"complexType": {
|
84
|
+
"original": "string",
|
85
|
+
"resolved": "string",
|
86
|
+
"references": {}
|
87
|
+
},
|
88
|
+
"required": false,
|
89
|
+
"optional": false,
|
90
|
+
"docs": {
|
91
|
+
"tags": [],
|
92
|
+
"text": ""
|
93
|
+
},
|
94
|
+
"getter": false,
|
95
|
+
"setter": false,
|
96
|
+
"attribute": "size",
|
97
|
+
"reflect": false
|
98
|
+
},
|
99
|
+
"showGroupLabel": {
|
100
|
+
"type": "boolean",
|
101
|
+
"mutable": false,
|
102
|
+
"complexType": {
|
103
|
+
"original": "boolean",
|
104
|
+
"resolved": "boolean",
|
105
|
+
"references": {}
|
106
|
+
},
|
107
|
+
"required": false,
|
108
|
+
"optional": false,
|
109
|
+
"docs": {
|
110
|
+
"tags": [],
|
111
|
+
"text": ""
|
112
|
+
},
|
113
|
+
"getter": false,
|
114
|
+
"setter": false,
|
115
|
+
"attribute": "show-group-label",
|
116
|
+
"reflect": false
|
117
|
+
},
|
118
|
+
"groupLabelText": {
|
119
|
+
"type": "string",
|
120
|
+
"mutable": false,
|
121
|
+
"complexType": {
|
122
|
+
"original": "string",
|
123
|
+
"resolved": "string",
|
124
|
+
"references": {}
|
125
|
+
},
|
126
|
+
"required": false,
|
127
|
+
"optional": false,
|
128
|
+
"docs": {
|
129
|
+
"tags": [],
|
130
|
+
"text": ""
|
131
|
+
},
|
132
|
+
"getter": false,
|
133
|
+
"setter": false,
|
134
|
+
"attribute": "group-label-text",
|
135
|
+
"reflect": false,
|
136
|
+
"defaultValue": "'Group Label Text'"
|
137
|
+
},
|
138
|
+
"showCaption": {
|
139
|
+
"type": "boolean",
|
140
|
+
"mutable": false,
|
141
|
+
"complexType": {
|
142
|
+
"original": "boolean",
|
143
|
+
"resolved": "boolean",
|
144
|
+
"references": {}
|
145
|
+
},
|
146
|
+
"required": false,
|
147
|
+
"optional": false,
|
148
|
+
"docs": {
|
149
|
+
"tags": [],
|
150
|
+
"text": ""
|
151
|
+
},
|
152
|
+
"getter": false,
|
153
|
+
"setter": false,
|
154
|
+
"attribute": "show-caption",
|
155
|
+
"reflect": false
|
156
|
+
},
|
157
|
+
"captionText": {
|
158
|
+
"type": "string",
|
159
|
+
"mutable": false,
|
160
|
+
"complexType": {
|
161
|
+
"original": "string",
|
162
|
+
"resolved": "string",
|
163
|
+
"references": {}
|
164
|
+
},
|
165
|
+
"required": false,
|
166
|
+
"optional": false,
|
167
|
+
"docs": {
|
168
|
+
"tags": [],
|
169
|
+
"text": ""
|
170
|
+
},
|
171
|
+
"getter": false,
|
172
|
+
"setter": false,
|
173
|
+
"attribute": "caption-text",
|
174
|
+
"reflect": false
|
175
|
+
},
|
176
|
+
"showCaptionIcon": {
|
177
|
+
"type": "boolean",
|
178
|
+
"mutable": false,
|
179
|
+
"complexType": {
|
180
|
+
"original": "boolean",
|
181
|
+
"resolved": "boolean",
|
182
|
+
"references": {}
|
183
|
+
},
|
184
|
+
"required": false,
|
185
|
+
"optional": false,
|
186
|
+
"docs": {
|
187
|
+
"tags": [],
|
188
|
+
"text": ""
|
189
|
+
},
|
190
|
+
"getter": false,
|
191
|
+
"setter": false,
|
192
|
+
"attribute": "show-caption-icon",
|
193
|
+
"reflect": false
|
194
|
+
}
|
195
|
+
};
|
196
|
+
}
|
197
|
+
static get states() {
|
198
|
+
return {
|
199
|
+
"hasErrors": {}
|
200
|
+
};
|
201
|
+
}
|
202
|
+
static get methods() {
|
203
|
+
return {
|
204
|
+
"setGroupError": {
|
205
|
+
"complexType": {
|
206
|
+
"signature": "(error: boolean) => Promise<void>",
|
207
|
+
"parameters": [{
|
208
|
+
"name": "error",
|
209
|
+
"type": "boolean",
|
210
|
+
"docs": ""
|
211
|
+
}],
|
212
|
+
"references": {
|
213
|
+
"Promise": {
|
214
|
+
"location": "global",
|
215
|
+
"id": "global::Promise"
|
216
|
+
}
|
217
|
+
},
|
218
|
+
"return": "Promise<void>"
|
219
|
+
},
|
220
|
+
"docs": {
|
221
|
+
"text": "",
|
222
|
+
"tags": []
|
223
|
+
}
|
224
|
+
}
|
225
|
+
};
|
226
|
+
}
|
227
|
+
static get elementRef() { return "el"; }
|
228
|
+
static get listeners() {
|
229
|
+
return [{
|
230
|
+
"name": "ifxError",
|
231
|
+
"method": "handleRadioButtonError",
|
232
|
+
"target": undefined,
|
233
|
+
"capture": false,
|
234
|
+
"passive": false
|
235
|
+
}];
|
236
|
+
}
|
237
|
+
}
|
238
|
+
//# sourceMappingURL=radio-button-group.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"radio-button-group.js","sourceRoot":"","sources":["../../../src/components/radio-button-group/radio-button-group.tsx"],"names":[],"mappings":"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","sourcesContent":["import { Component, State, Prop, h, Element, Listen, Method } from '@stencil/core';\n\n@Component({\n tag: 'ifx-radio-button-group',\n styleUrl: 'radio-button-group.scss',\n shadow: true,\n formAssociated: true\n})\n\nexport class RadioButtonGroup {\n private errorStates: Map<HTMLElement, boolean> = new Map();\n\n @Element() el: HTMLElement;\n @Prop() alignment: 'horizontal' | 'vertical' = 'vertical';\n @Prop() size: string;\n @Prop() showGroupLabel: boolean;\n @Prop() groupLabelText: string = 'Group Label Text';\n @Prop() showCaption: boolean;\n @Prop() captionText: string;\n @Prop() showCaptionIcon: boolean;\n @State() hasErrors: boolean = false;\n \n @Listen('ifxError')\n handleRadioButtonError(event: CustomEvent) {\n const radioButton = event.target as HTMLElement;\n if (radioButton.tagName === 'ifx-radio-button') {\n this.errorStates.set(radioButton, event.detail);\n this.updateHasErrors();\n }\n }\n\n // Method to set the error state of all radio-butttons in the group\n @Method()\n async setGroupError(error: boolean) {\n const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));\n radioButtons.forEach((radioButton) => {\n (radioButton as any).error = error;\n });\n }\n\n componentWillLoad() {\n this.initializeState();\n }\n\n handleSlotChange = () => {\n this.initializeState();\n };\n\n private initializeState() {\n this.errorStates.clear();\n const radioButtons = Array.from(this.el.querySelectorAll('ifx-radio-button'));\n radioButtons.forEach((radioButton) => {\n if (!this.errorStates.has(radioButton)) {\n this.errorStates.set(radioButton, (radioButton as any).error || false);\n }\n });\n this.updateHasErrors();\n }\n\n private updateHasErrors() {\n this.hasErrors = Array.from(this.errorStates.values()).some((error) => error);\n }\n\n render() {\n return (\n <div class='radio-button-group-container'>\n {this.showGroupLabel ? <div class='group-label'>{this.groupLabelText} *</div> : ''}\n <div class={`radio-button-group ${this.alignment} ${this.size}`}>\n <slot onSlotchange={this.handleSlotChange} ></slot>\n </div>\n {this.showCaption ? (\n <div class={`caption ${this.hasErrors ? 'error' : 'default'}`}>\n {this.showCaptionIcon ? <div class='caption-icon'><ifx-icon icon=\"c-info-16\">\n </ifx-icon></div> : ''}\n <div class='caption-text'>{this.captionText}</div>\n </div>) : ''}\n </div>\n );\n }\n}"]}
|
@@ -0,0 +1,143 @@
|
|
1
|
+
export default {
|
2
|
+
title: 'Components/Radio Button Group',
|
3
|
+
tags: ['autodocs'],
|
4
|
+
args: {
|
5
|
+
amountOfItems: 3,
|
6
|
+
alignment: 'vertical',
|
7
|
+
size: 'm',
|
8
|
+
checked: false,
|
9
|
+
disabled: false,
|
10
|
+
error: false,
|
11
|
+
showGroupLabel: false,
|
12
|
+
groupLabelText: 'Group Label',
|
13
|
+
showCaption: false,
|
14
|
+
captionText: 'Caption text, description, error notification',
|
15
|
+
showCaptionIcon: false,
|
16
|
+
},
|
17
|
+
argTypes: {
|
18
|
+
amountOfItems: {
|
19
|
+
categpry: 'story controls',
|
20
|
+
name: 'Amount of Items',
|
21
|
+
description: 'Set the amount of radio buttons.',
|
22
|
+
control: { type: 'number' },
|
23
|
+
table: {
|
24
|
+
category: 'story controls',
|
25
|
+
defaultValue: { summary: 3 }
|
26
|
+
}
|
27
|
+
},
|
28
|
+
alignment: {
|
29
|
+
description: 'Set the orientation of the radio button group.',
|
30
|
+
options: ['vertical', 'horizontal'],
|
31
|
+
control: { type: 'radio' },
|
32
|
+
table: {
|
33
|
+
category: 'ifx-radio-button-group props',
|
34
|
+
defaultValue: { summary: 'vertical' }
|
35
|
+
}
|
36
|
+
},
|
37
|
+
size: {
|
38
|
+
description: 'Size options for the radio button.',
|
39
|
+
options: ['s', 'm'],
|
40
|
+
control: { type: 'radio' },
|
41
|
+
table: {
|
42
|
+
category: 'ifx-radio-button props',
|
43
|
+
defaultValue: { summary: 's' },
|
44
|
+
type: {
|
45
|
+
summary: 's | m'
|
46
|
+
}
|
47
|
+
}
|
48
|
+
},
|
49
|
+
checked: {
|
50
|
+
description: 'Set the checked state.',
|
51
|
+
control: { type: 'boolean' },
|
52
|
+
table: {
|
53
|
+
category: 'ifx-radio-button props',
|
54
|
+
defaultValue: { summary: 'false' }
|
55
|
+
}
|
56
|
+
},
|
57
|
+
disabled: {
|
58
|
+
description: 'Disable the radio button.',
|
59
|
+
control: { type: 'boolean' },
|
60
|
+
table: {
|
61
|
+
category: 'ifx-radio-button props',
|
62
|
+
defaultValue: { summary: 'false' }
|
63
|
+
}
|
64
|
+
},
|
65
|
+
error: {
|
66
|
+
description: 'Set the error state.',
|
67
|
+
control: { type: 'boolean' },
|
68
|
+
table: {
|
69
|
+
category: 'ifx-radio-button props',
|
70
|
+
defaultValue: { summary: 'false' }
|
71
|
+
}
|
72
|
+
},
|
73
|
+
showGroupLabel: {
|
74
|
+
description: 'Show the group label.',
|
75
|
+
control: { type: 'boolean' },
|
76
|
+
table: {
|
77
|
+
category: 'ifx-radio-button-group props',
|
78
|
+
defaultValue: { summary: 'false' }
|
79
|
+
}
|
80
|
+
},
|
81
|
+
groupLabelText: {
|
82
|
+
description: 'Set the group label text.',
|
83
|
+
control: { type: 'text' },
|
84
|
+
table: {
|
85
|
+
category: 'ifx-radio-button-group props',
|
86
|
+
defaultValue: { summary: '' }
|
87
|
+
}
|
88
|
+
},
|
89
|
+
showCaption: {
|
90
|
+
description: 'Show the caption.',
|
91
|
+
control: { type: 'boolean' },
|
92
|
+
table: {
|
93
|
+
category: 'ifx-radio-button-group props',
|
94
|
+
defaultValue: { summary: 'false' }
|
95
|
+
}
|
96
|
+
},
|
97
|
+
captionText: {
|
98
|
+
description: 'Set the caption text.',
|
99
|
+
control: { type: 'text' },
|
100
|
+
table: {
|
101
|
+
category: 'ifx-radio-button-group props',
|
102
|
+
defaultValue: { summary: '' }
|
103
|
+
}
|
104
|
+
},
|
105
|
+
showCaptionIcon: {
|
106
|
+
description: 'Show the caption icon.',
|
107
|
+
control: { type: 'boolean' },
|
108
|
+
table: {
|
109
|
+
category: 'ifx-radio-button-group props',
|
110
|
+
defaultValue: { summary: 'false' }
|
111
|
+
}
|
112
|
+
},
|
113
|
+
setGroupError: {
|
114
|
+
action: 'setGroupError',
|
115
|
+
description: 'Method to set the error state of all checkboxes in the group.',
|
116
|
+
table: {
|
117
|
+
category: 'ifx-radio-buttton-group methods',
|
118
|
+
type: {
|
119
|
+
summary: 'error : boolean',
|
120
|
+
detail: 'RadioButttonGroup.setGroupError(error)'
|
121
|
+
}
|
122
|
+
}
|
123
|
+
}
|
124
|
+
},
|
125
|
+
};
|
126
|
+
const Template = args => {
|
127
|
+
let radioButtons = '';
|
128
|
+
for (let i = 0; i < args.amountOfItems; i++) {
|
129
|
+
if (i === 0) {
|
130
|
+
radioButtons += `<ifx-radio-button value="${i}" disabled="${args.disabled}" checked="${args.checked}" error="${args.error}" size="${args.size}">Option ${i}</ifx-radio-button>`;
|
131
|
+
}
|
132
|
+
else {
|
133
|
+
radioButtons += `<ifx-radio-button value="${i}" size="${args.size}">Option ${i}</ifx-radio-button>`;
|
134
|
+
}
|
135
|
+
}
|
136
|
+
const template = `
|
137
|
+
<ifx-radio-button-group alignment="${args.alignment}" show-group-label="${args.showGroupLabel}" group-label-text="${args.groupLabelText}" show-caption="${args.showCaption}" caption-text="${args.captionText}" show-caption-icon="${args.showCaptionIcon}">
|
138
|
+
${radioButtons}
|
139
|
+
</ifx-radion-button-group>`;
|
140
|
+
return template;
|
141
|
+
};
|
142
|
+
export const Default = Template.bind({});
|
143
|
+
//# sourceMappingURL=radio-button-group.stories.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"radio-button-group.stories.js","sourceRoot":"","sources":["../../../src/components/radio-button-group/radio-button-group.stories.ts"],"names":[],"mappings":"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","sourcesContent":["export default {\n title: 'Components/Radio Button Group',\n tags: ['autodocs'],\n args: {\n amountOfItems: 3,\n alignment: 'vertical',\n size: 'm',\n checked: false,\n disabled: false,\n error: false,\n showGroupLabel: false,\n groupLabelText: 'Group Label',\n showCaption: false,\n captionText: 'Caption text, description, error notification',\n showCaptionIcon: false,\n },\n argTypes: {\n amountOfItems: {\n categpry: 'story controls',\n name: 'Amount of Items',\n description: 'Set the amount of radio buttons.',\n control: { type: 'number' },\n table: {\n category: 'story controls',\n defaultValue: { summary: 3 }\n }\n },\n alignment: {\n description: 'Set the orientation of the radio button group.',\n options: ['vertical', 'horizontal'],\n control: { type: 'radio' },\n table: {\n category: 'ifx-radio-button-group props',\n defaultValue: { summary: 'vertical' }\n }\n },\n size: {\n description: 'Size options for the radio button.',\n options: ['s', 'm'],\n control: { type: 'radio' },\n table: {\n category: 'ifx-radio-button props',\n defaultValue: { summary: 's' },\n type: {\n summary: 's | m'\n }\n }\n },\n checked: {\n description: 'Set the checked state.',\n control: { type: 'boolean' },\n table: {\n category: 'ifx-radio-button props',\n defaultValue: { summary: 'false' }\n }\n },\n disabled: {\n description: 'Disable the radio button.',\n control: { type: 'boolean' },\n table: {\n category: 'ifx-radio-button props',\n defaultValue: { summary: 'false' }\n }\n },\n error: {\n description: 'Set the error state.',\n control: { type: 'boolean' },\n table: {\n category: 'ifx-radio-button props',\n defaultValue: { summary: 'false' }\n }\n },\n showGroupLabel: {\n description: 'Show the group label.',\n control: { type: 'boolean' },\n table: {\n category: 'ifx-radio-button-group props',\n defaultValue: { summary: 'false' }\n }\n },\n groupLabelText: {\n description: 'Set the group label text.',\n control: { type: 'text' },\n table: {\n category: 'ifx-radio-button-group props',\n defaultValue: { summary: '' }\n }\n },\n showCaption: {\n description: 'Show the caption.',\n control: { type: 'boolean' },\n table: {\n category: 'ifx-radio-button-group props',\n defaultValue: { summary: 'false' }\n }\n },\n captionText: {\n description: 'Set the caption text.',\n control: { type: 'text' },\n table: {\n category: 'ifx-radio-button-group props',\n defaultValue: { summary: '' }\n }\n },\n showCaptionIcon: {\n description: 'Show the caption icon.',\n control: { type: 'boolean' },\n table: {\n category: 'ifx-radio-button-group props',\n defaultValue: { summary: 'false' }\n }\n },\n setGroupError: {\n action: 'setGroupError',\n description: 'Method to set the error state of all checkboxes in the group.',\n table: {\n category: 'ifx-radio-buttton-group methods',\n type: {\n summary: 'error : boolean',\n detail: 'RadioButttonGroup.setGroupError(error)'\n }\n }\n }\n },\n};\n\nconst Template = args => {\n let radioButtons = '';\n for (let i = 0; i < args.amountOfItems; i++) {\n if (i === 0) {\n radioButtons += `<ifx-radio-button value=\"${i}\" disabled=\"${args.disabled}\" checked=\"${args.checked}\" error=\"${args.error}\" size=\"${args.size}\">Option ${i}</ifx-radio-button>`;\n }\n else {\n radioButtons += `<ifx-radio-button value=\"${i}\" size=\"${args.size}\">Option ${i}</ifx-radio-button>`;\n }\n }\n const template = `\n <ifx-radio-button-group alignment=\"${args.alignment}\" show-group-label=\"${args.showGroupLabel}\" group-label-text=\"${args.groupLabelText}\" show-caption=\"${args.showCaption}\" caption-text=\"${args.captionText}\" show-caption-icon=\"${args.showCaptionIcon}\">\n ${radioButtons}\n </ifx-radion-button-group>`;\n\n return template;\n}\n\nexport const Default = Template.bind({});"]}
|
@@ -29,7 +29,7 @@ export class SearchBar {
|
|
29
29
|
this.value = event.detail;
|
30
30
|
}
|
31
31
|
render() {
|
32
|
-
return (h("div", { key: '
|
32
|
+
return (h("div", { key: '6b1233aa51e61ff28d90ccbb54b01742c5ff0231', "aria-label": 'a search bar', "aria-disabled": this.disabled, class: `search-bar ${this.internalState ? 'open' : 'closed'}` }, this.internalState ? (h("div", { class: "search-bar-wrapper" }, h("ifx-search-field", { disabled: this.disabled, value: this.value, maxlength: this.maxlength, onIfxInput: this.handleInput.bind(this) }, h("ifx-icon", { icon: "search-16", slot: "search-icon" })), h("a", { tabindex: "-1", href: 'javascript:void(0)', onClick: this.handleCloseButton }, "Close"))) : (h("div", { class: "search-bar__icon-wrapper", onClick: this.handleCloseButton }, h("ifx-icon", { icon: "search-16" })))));
|
33
33
|
}
|
34
34
|
static get is() { return "ifx-search-bar"; }
|
35
35
|
static get encapsulation() { return "shadow"; }
|
@@ -45,7 +45,7 @@ export class SearchField {
|
|
45
45
|
this.showDeleteIconInternalState = false;
|
46
46
|
}
|
47
47
|
render() {
|
48
|
-
return (h("div", { key: '
|
48
|
+
return (h("div", { key: '74fd7b8beb33b30b3e05d02ea921c52e7f4dae39', "aria-label": "a search field for user input", "aria-disabled": this.disabled, "aria-value": this.value, class: 'search-field' }, h("div", { key: '2616b4e80beb40226179c4690cc3746e4fadb60e', class: this.getWrapperClassNames(), tabindex: 1, onFocus: () => this.focusInput(), onClick: () => this.focusInput() }, h("ifx-icon", { key: '2876766c1659917a44e082ab9199f85dbd2c2c71', icon: "search-16", class: "search-icon" }), h("input", { key: '6ac5b6d692be544307012e761be138fd36f37966', ref: (el) => (this.inputElement = el), type: "text", onInput: () => this.handleInput(), placeholder: this.placeholder, disabled: this.disabled, maxlength: this.maxlength, value: this.value }), this.showDeleteIcon && this.showDeleteIconInternalState ? (h("ifx-icon", { icon: "cremove16", class: "delete-icon", onClick: this.handleDelete })) : null)));
|
49
49
|
}
|
50
50
|
getSizeClass() {
|
51
51
|
return `${this.size}` === "s"
|
@@ -18,7 +18,7 @@ export class Segment {
|
|
18
18
|
}
|
19
19
|
}
|
20
20
|
render() {
|
21
|
-
return (h("div", { key: '
|
21
|
+
return (h("div", { key: '316acecd8e676dbcd6f55010bb791d0746cf4937', class: `segment ${this.selected ? 'segment--selected' : ''}`, tabIndex: 0, onClick: () => { this.handleSegmentClick(); }, onKeyDown: (e) => { this.handleSegmentKeyDown(e); } }, h("ifx-icon", { key: '86adc66b777780630ebe3e4157244c2c81ceb5d2', icon: this.icon }), " ", h("slot", { key: '72319efb1d2b4cde4a922957d71ad388b35d276c' })));
|
22
22
|
}
|
23
23
|
static get is() { return "ifx-segment"; }
|
24
24
|
static get encapsulation() { return "shadow"; }
|
@@ -62,8 +62,8 @@ export class SegmentedControl {
|
|
62
62
|
this.setActiveSegment();
|
63
63
|
}
|
64
64
|
render() {
|
65
|
-
return (h("div", { key: '
|
66
|
-
h("div", { key: '
|
65
|
+
return (h("div", { key: 'f1db16681b45767ea6de4148d7ad8668fba35498', "aria-value": this.selectedValue, "aria-label": 'segmented control', class: 'group' }, h("div", { key: '70980b04bcb50110612196979b44e2d61a7bc4c8', class: 'group__label' }, this.label.trim()), h("div", { key: '0dd8dc01db812585c2a58132d4ceb6447a16ddff', class: 'group__controls' }, h("slot", { key: 'e7f95a3c415312fe790e2288391e43e4f68d3279' })), this.caption.trim() &&
|
66
|
+
h("div", { key: '72784a7d56a2e39cc22b329c609828be2944e6ea', class: 'group__caption' }, h("ifx-icon", { key: 'dbb21f0562a130d57defcf648c12c6e00346a0dc', icon: 'cinfo16' }), " ", this.caption.trim())));
|
67
67
|
}
|
68
68
|
componentDidRender() {
|
69
69
|
this.setSegmentSize();
|
@@ -209,9 +209,9 @@ export class Choices {
|
|
209
209
|
// destroy choices element to restore previous dom structure
|
210
210
|
// so vdom can replace the element correctly
|
211
211
|
this.destroy();
|
212
|
-
return (h("div", { key: '
|
212
|
+
return (h("div", { key: '40ae2ee9e22586ab4119c044708dea062f978db6', class: `ifx-select-container` }, this.label ? (h("div", { class: "ifx-label-wrapper" }, h("span", null, this.label))) : null, h("div", { key: '87143d41c3c0513eada166b11052c55e3d993b62', class: `${choicesWrapperClass}
|
213
213
|
${this.disabled ? 'disabled' : ''}
|
214
|
-
${this.error ? 'error' : ''}`, onClick: this.disabled ? undefined : () => this.toggleDropdown(), onKeyDown: event => this.handleKeyDown(event) }, h("select", Object.assign({ key: '
|
214
|
+
${this.error ? 'error' : ''}`, onClick: this.disabled ? undefined : () => this.toggleDropdown(), onKeyDown: event => this.handleKeyDown(event) }, h("select", Object.assign({ key: '2019a42f8e730061cfb502531f5991d2d5e07afe', class: 'single__select-input-field', disabled: this.disabled }, attributes, { "data-trigger": true, onChange: () => this.handleChange() }), this.createSelectOptions(this.options)), h("div", { key: '6fc0ac048ab143a933ba79c48ed86960197ca9ed', class: "single__select-icon-container" }, this.optionIsSelected && (h("div", { key: '46e95d4cfb9c38283028b92d35b14a1430586e81', class: "ifx-choices__icon-wrapper-delete" }, h("ifx-icon", { key: '8e8ae26a55428afd386d940815c6414ae58a1f37', icon: "cremove16", onClick: () => this.handleDeleteSelection() }))), h("div", { key: 'ac1990b97fe0787a8186f27c4258eb9d0f847858', class: "ifx-choices__icon-wrapper-up" }, h("ifx-icon", { key: "icon-up", icon: "chevronup-16" })), h("div", { key: 'd6284be7bb197eaff05397f7246e5b6cd20e1a9c', class: "ifx-choices__icon-wrapper-down" }, h("ifx-icon", { key: "icon-down", icon: "chevron-down-16" })))), this.error ? (h("div", { class: "ifx-error-message-wrapper" }, h("span", null, this.errorMessage))) : null));
|
215
215
|
}
|
216
216
|
toggleDropdown() {
|
217
217
|
const div = this.root.querySelector('.ifx-choices__wrapper');
|
@@ -136,10 +136,10 @@ export class IfxSlider {
|
|
136
136
|
this.updateValuePercent();
|
137
137
|
}
|
138
138
|
render() {
|
139
|
-
return (h("div", { key: '
|
139
|
+
return (h("div", { key: '37d979ae4fab76379eba0afe72a0b1cff75ba6fb', class: "ifx-slider" }, this.leftText && (h("span", { key: '54364e238b205ff9b8906b4f7a84f39e8924806b', class: `left-text` }, this.leftText)), this.leftIcon && (h("ifx-icon", { key: '898c22fc7020ce494ab199b0ae1a53f19538879d', icon: this.leftIcon, class: `left-icon${this.disabled ? ' disabled' : ''}` })), (this.type !== 'double') ?
|
140
140
|
h("input", { type: "range", min: this.min, max: this.max, step: this.step, value: this.internalValue, disabled: this.disabled, ref: (el) => (this.inputRef = el), onInput: (event) => this.handleInputChange(event), "aria-label": 'a slider', "aria-value": this.value, "aria-disabled": this.disabled })
|
141
141
|
:
|
142
|
-
h("div", { class: 'range-slider__wrapper', "aria-label": 'a range slider', "aria-value": this.value, "aria-disabled": this.disabled }, h("input", { id: 'min-slider', type: 'range', min: this.min, max: this.max, step: this.step, value: this.internalMinValue, disabled: this.disabled, ref: (el) => (this.minInputRef = el), onInput: (event) => this.handleInputChangeOfRangeSlider(event), onMouseUp: (event) => this.handleOnMouseLeaveOfRangeSlider(event) }), h("input", { id: 'max-slider', type: 'range', min: this.min, max: this.max, step: this.step, value: this.internalMaxValue, disabled: this.disabled, ref: (el) => (this.maxInputRef = el), onInput: (event) => this.handleInputChangeOfRangeSlider(event), onMouseUp: (event) => this.handleOnMouseLeaveOfRangeSlider(event) })), this.rightIcon && (h("ifx-icon", { key: '
|
142
|
+
h("div", { class: 'range-slider__wrapper', "aria-label": 'a range slider', "aria-value": this.value, "aria-disabled": this.disabled }, h("input", { id: 'min-slider', type: 'range', min: this.min, max: this.max, step: this.step, value: this.internalMinValue, disabled: this.disabled, ref: (el) => (this.minInputRef = el), onInput: (event) => this.handleInputChangeOfRangeSlider(event), onMouseUp: (event) => this.handleOnMouseLeaveOfRangeSlider(event) }), h("input", { id: 'max-slider', type: 'range', min: this.min, max: this.max, step: this.step, value: this.internalMaxValue, disabled: this.disabled, ref: (el) => (this.maxInputRef = el), onInput: (event) => this.handleInputChangeOfRangeSlider(event), onMouseUp: (event) => this.handleOnMouseLeaveOfRangeSlider(event) })), this.rightIcon && (h("ifx-icon", { key: 'dcd74689d748a499bf7e4a1f291808ca09e91be5', icon: this.rightIcon, class: `right-icon${this.disabled ? ' disabled' : ''}` })), this.rightText && (h("span", { key: '46943c6f10919c7822b998c5fc99392d5bbf581b', class: `right-text${this.disabled ? ' disabled' : ''}` }, this.rightText)), this.showPercentage && (this.type !== "double") && (h("span", { key: '333d2a8578ceeeb6c4b9d8e12ba90ac5bf96ebd6', class: `percentage-display${this.disabled ? ' disabled' : ''}` }, this.percentage, "%"))));
|
143
143
|
}
|
144
144
|
static get is() { return "ifx-slider"; }
|
145
145
|
static get encapsulation() { return "shadow"; }
|
@@ -5,8 +5,8 @@ export class Spinner {
|
|
5
5
|
this.inverted = false;
|
6
6
|
}
|
7
7
|
render() {
|
8
|
-
return (h("div", { key: '
|
9
|
-
&& h("div", { key: '
|
8
|
+
return (h("div", { key: '036b7ba57d3d4612adf02dc4af7bb10ab44525bc', "aria-label": "spinner indicating a loading process", class: this.getClassNames() }, h("div", { key: '57506cdc9b93523472a2dd9730ad63fe0747edc3', class: `${this.variant !== 'brand' ? 'border' : ""} ${this.inverted ? 'inverted' : ""}` }), this.variant === 'brand'
|
9
|
+
&& h("div", { key: '9e9d6e55e1fb021dea19d07b640e36b6c2aeda8d', class: `semiconductor ${this.inverted ? 'inverted' : ""} ${this.getSizeClass()}` }, h("svg", { key: '742486b0d84452b2603aaf397c0f09f01a2cb7f0', width: '40', height: '40', viewBox: "0 0 40 40", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("g", { key: 'fc459287dbaee14447dc150ac01a52dad8ce6add', id: "spinner/conductor" }, h("path", { key: '842b3d6a1f256a1de213a205e9eeec563bd9c8c7', id: "Vector", d: "M38.75 18.75C39.4375 18.75 40 19.3125 40 20C40 20.6875 39.4409 21.25 38.75 21.25H35V26.25H38.75C39.4375 26.25 40 26.8125 40 27.5C40 28.1875 39.4409 28.75 38.75 28.75H35V30C35 32.7617 32.7617 35 30 35H28.75V38.75C28.75 39.4409 28.1875 40 27.5 40C26.8125 40 26.25 39.4409 26.25 38.75V35H21.25V38.75C21.25 39.4409 20.6875 40 20 40C19.3125 40 18.75 39.4409 18.75 38.75V35H13.75V38.75C13.75 39.4409 13.1875 40 12.5 40C11.8125 40 11.25 39.4409 11.25 38.75V35H10C7.23828 35 5 32.7617 5 30V28.75H1.25C0.559062 28.75 0 28.1875 0 27.5C0 26.8125 0.559062 26.25 1.25 26.25H5V21.25H1.25C0.559062 21.25 0 20.6875 0 20C0 19.3125 0.559062 18.75 1.25 18.75H5V13.75H1.25C0.559062 13.75 0 13.1875 0 12.5C0 11.8125 0.559062 11.25 1.25 11.25H5V10C5 7.23828 7.23828 5 10 5H11.25V1.25C11.25 0.5625 11.8125 0 12.5 0C13.1875 0 13.75 0.559063 13.75 1.25V5H18.75V1.25C18.75 0.559063 19.3091 0 20 0C20.6909 0 21.25 0.559063 21.25 1.25V5H26.25V1.25C26.25 0.559063 26.8091 0 27.5 0C28.1909 0 28.75 0.559063 28.75 1.25V5H30C32.7617 5 35 7.23828 35 10V11.25H38.75C39.4409 11.25 40 11.8091 40 12.5C40 13.1909 39.4409 13.75 38.75 13.75H35V18.75H38.75ZM32.5 10C32.5 8.62188 31.3781 7.5 30 7.5H10C8.62187 7.5 7.5 8.62188 7.5 10V30C7.5 31.3781 8.62187 32.5 10 32.5H30C31.3781 32.5 32.5 31.3781 32.5 30V10Z" }))))));
|
10
10
|
}
|
11
11
|
getSizeClass() {
|
12
12
|
return `${this.size}` === "s"
|
@@ -8,7 +8,7 @@ export class Status {
|
|
8
8
|
var _a;
|
9
9
|
const effectiveColor = ((_a = this.color) === null || _a === void 0 ? void 0 : _a.trim()) ? this.color : 'orange-500';
|
10
10
|
const containerClass = this.border ? `container border-${effectiveColor}` : 'container no-border';
|
11
|
-
return (h("div", { key: '
|
11
|
+
return (h("div", { key: '0537cea5ff8d9b92bf309e601d32657de3a3d81c', "aria-label": "a status indicator", "aria-value": this.label, class: containerClass }, h("span", { key: '0afda2ddc5bf64ac2b6c09317ceb4d73cfb39cf8', class: `dot ${effectiveColor}` }), h("p", { key: 'bb64b4b6595ae980d98d74ea9116c4c040e72ff5', class: "text" }, this.label)));
|
12
12
|
}
|
13
13
|
static get is() { return "ifx-status"; }
|
14
14
|
static get encapsulation() { return "shadow"; }
|
@@ -42,7 +42,7 @@ export class Step {
|
|
42
42
|
}
|
43
43
|
}
|
44
44
|
render() {
|
45
|
-
return (h("div", { key: '
|
45
|
+
return (h("div", { key: 'a286ec01fede1f1887f7c0b4796805618c8f5ecc', "aria-current": this.active ? 'step' : false, "aria-disabled": this.active || this.complete ? false : true, onClick: (e) => this.stopOnClickPropogation(e), class: `step-wrapper ${this.stepId === 1 ? 'first-step' : ''}
|
46
46
|
${this.error ? 'error' : ''}
|
47
47
|
${this.stepperState.variant}
|
48
48
|
${this.complete ? 'complete' : ''}
|
@@ -50,11 +50,11 @@ export class Step {
|
|
50
50
|
indicator-${this.stepperState.indicatorPosition}
|
51
51
|
${this.active ? 'active' : ''}
|
52
52
|
${this.clickable ? 'clickable' : ''}
|
53
|
-
${this.disabled ? 'disabled' : ''}` }, h("div", { key: '
|
54
|
-
h("div", { key: '
|
53
|
+
${this.disabled ? 'disabled' : ''}` }, h("div", { key: 'd8230818a17da9e6a84a140c3b2b912313884967', class: 'step-icon-wrapper' }, this.stepperState.variant !== 'compact' && h("span", { key: '4d8c49a1ee892eedd31aa645da8f57aa655b7a65', class: 'step-connector-l' }), (this.stepperState.variant !== 'compact' && (!this.error || (this.error && this.active))) &&
|
54
|
+
h("div", { key: 'a6263bf57f9ce8bc615e8d611b0128e075d148b9', class: 'step-icon' }, (this.stepperState.showStepNumber && !this.complete && !this.active) ? this.stepId : '', (this.complete && !this.active) && h("ifx-icon", { key: '17ecbfc2a12141e58e2481efc54bd86683f5e995', icon: 'check16' }), this.active && h("span", { key: 'd0139442be7227f075c6ab065cffc991a87296c9', class: 'active-indic' })), (this.stepperState.variant !== 'compact' && this.error && !this.active) && h("ifx-icon", { key: '867418f5a3f7e5958521cde8634ed03e68f43921', icon: 'warningf24' }), this.stepperState.variant !== 'compact' && h("span", { key: 'a97d98c73df0e64937dd10fca6b456e19000a509', class: `step-connector-r ${this.active ? 'active' : ''}` })),
|
55
55
|
/* Step labels */
|
56
56
|
(this.stepperState.variant !== 'compact' || (this.stepperState.variant === 'compact' && (this.active || this.stepId === this.stepperState.activeStep + 1))) &&
|
57
|
-
h("div", { key: '
|
57
|
+
h("div", { key: 'dc6560632dc1edbaa8ebdec515717a26064a2d8d', tabIndex: !this.disabled && this.complete && !this.active ? 0 : -1, class: `step-label ${this.stepperState.variant === 'compact' ? (this.active ? 'curr-label' : 'next-label') : ''}`, onClick: () => { this.handleStepClick(); }, onKeyDown: (e) => { this.handleStepKeyDown(e); } }, (this.stepperState.variant !== 'compact') && h("slot", { key: '3ef384da05179cc06434b7ab707b12352f292cfe' }), this.stepperState.variant === 'compact' && !this.active ? 'Next: ' : '', this.stepperState.variant === 'compact' && h("slot", { key: '6368938443c139f025aa0e37295f6a4002aab7d0' }))));
|
58
58
|
}
|
59
59
|
;
|
60
60
|
static get is() { return "ifx-step"; }
|