@db-ux/react-core-components 4.11.1 → 4.12.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +23 -0
- package/dist/components/accordion/accordion.d.ts +1 -1
- package/dist/components/accordion/accordion.js +83 -102
- package/dist/components/accordion/index.d.ts +1 -1
- package/dist/components/accordion/index.js +1 -0
- package/dist/components/accordion/model.d.ts +2 -2
- package/dist/components/accordion/model.js +2 -4
- package/dist/components/accordion-item/accordion-item.d.ts +2 -2
- package/dist/components/accordion-item/accordion-item.js +56 -89
- package/dist/components/accordion-item/index.d.ts +1 -1
- package/dist/components/accordion-item/index.js +1 -0
- package/dist/components/accordion-item/model.d.ts +1 -1
- package/dist/components/accordion-item/model.js +1 -0
- package/dist/components/badge/badge.d.ts +1 -1
- package/dist/components/badge/badge.js +28 -72
- package/dist/components/badge/index.d.ts +1 -1
- package/dist/components/badge/index.js +1 -0
- package/dist/components/badge/model.d.ts +1 -1
- package/dist/components/badge/model.js +1 -12
- package/dist/components/brand/brand.d.ts +1 -1
- package/dist/components/brand/brand.js +10 -60
- package/dist/components/brand/index.d.ts +1 -1
- package/dist/components/brand/index.js +1 -0
- package/dist/components/brand/model.d.ts +1 -1
- package/dist/components/brand/model.js +1 -0
- package/dist/components/button/button.d.ts +1 -1
- package/dist/components/button/button.js +19 -75
- package/dist/components/button/index.d.ts +1 -1
- package/dist/components/button/index.js +1 -0
- package/dist/components/button/model.d.ts +1 -1
- package/dist/components/button/model.js +2 -13
- package/dist/components/card/card.d.ts +1 -1
- package/dist/components/card/card.js +14 -65
- package/dist/components/card/index.d.ts +1 -1
- package/dist/components/card/index.js +1 -0
- package/dist/components/card/model.d.ts +1 -1
- package/dist/components/card/model.js +2 -8
- package/dist/components/checkbox/checkbox.d.ts +1 -1
- package/dist/components/checkbox/checkbox.js +143 -163
- package/dist/components/checkbox/index.d.ts +1 -1
- package/dist/components/checkbox/index.js +1 -0
- package/dist/components/checkbox/model.d.ts +1 -1
- package/dist/components/checkbox/model.js +1 -0
- package/dist/components/custom-button/custom-button.d.ts +1 -1
- package/dist/components/custom-button/custom-button.js +10 -65
- package/dist/components/custom-button/index.d.ts +1 -1
- package/dist/components/custom-button/index.js +1 -0
- package/dist/components/custom-button/model.d.ts +2 -2
- package/dist/components/custom-button/model.js +1 -0
- package/dist/components/custom-select/custom-select.d.ts +1 -1
- package/dist/components/custom-select/custom-select.js +688 -509
- package/dist/components/custom-select/index.d.ts +1 -1
- package/dist/components/custom-select/index.js +1 -0
- package/dist/components/custom-select/model.d.ts +4 -4
- package/dist/components/custom-select/model.js +1 -8
- package/dist/components/custom-select-dropdown/custom-select-dropdown.d.ts +1 -1
- package/dist/components/custom-select-dropdown/custom-select-dropdown.js +10 -62
- package/dist/components/custom-select-dropdown/index.d.ts +1 -1
- package/dist/components/custom-select-dropdown/index.js +1 -0
- package/dist/components/custom-select-dropdown/model.d.ts +1 -1
- package/dist/components/custom-select-dropdown/model.js +1 -8
- package/dist/components/custom-select-form-field/custom-select-form-field.d.ts +1 -1
- package/dist/components/custom-select-form-field/custom-select-form-field.js +9 -57
- package/dist/components/custom-select-form-field/index.d.ts +1 -1
- package/dist/components/custom-select-form-field/index.js +1 -0
- package/dist/components/custom-select-form-field/model.d.ts +1 -1
- package/dist/components/custom-select-form-field/model.js +1 -0
- package/dist/components/custom-select-list/custom-select-list.d.ts +1 -1
- package/dist/components/custom-select-list/custom-select-list.js +9 -60
- package/dist/components/custom-select-list/index.d.ts +1 -1
- package/dist/components/custom-select-list/index.js +1 -0
- package/dist/components/custom-select-list/model.d.ts +1 -1
- package/dist/components/custom-select-list/model.js +1 -0
- package/dist/components/custom-select-list-item/custom-select-list-item.d.ts +2 -2
- package/dist/components/custom-select-list-item/custom-select-list-item.js +28 -89
- package/dist/components/custom-select-list-item/index.d.ts +1 -1
- package/dist/components/custom-select-list-item/index.js +1 -0
- package/dist/components/custom-select-list-item/model.d.ts +1 -1
- package/dist/components/custom-select-list-item/model.js +1 -4
- package/dist/components/divider/divider.d.ts +1 -1
- package/dist/components/divider/divider.js +9 -60
- package/dist/components/divider/index.d.ts +1 -1
- package/dist/components/divider/index.js +1 -0
- package/dist/components/divider/model.d.ts +1 -1
- package/dist/components/divider/model.js +2 -4
- package/dist/components/drawer/drawer.d.ts +2 -2
- package/dist/components/drawer/drawer.js +109 -118
- package/dist/components/drawer/index.d.ts +1 -1
- package/dist/components/drawer/index.js +1 -0
- package/dist/components/drawer/model.d.ts +4 -1
- package/dist/components/drawer/model.js +4 -14
- package/dist/components/header/header.d.ts +1 -1
- package/dist/components/header/header.js +43 -143
- package/dist/components/header/index.d.ts +1 -1
- package/dist/components/header/index.js +1 -0
- package/dist/components/header/model.d.ts +1 -1
- package/dist/components/header/model.js +1 -0
- package/dist/components/icon/icon.d.ts +1 -1
- package/dist/components/icon/icon.js +9 -61
- package/dist/components/icon/index.d.ts +1 -1
- package/dist/components/icon/index.js +1 -0
- package/dist/components/icon/model.d.ts +1 -1
- package/dist/components/icon/model.js +1 -11
- package/dist/components/infotext/index.d.ts +1 -1
- package/dist/components/infotext/index.js +1 -0
- package/dist/components/infotext/infotext.d.ts +1 -1
- package/dist/components/infotext/infotext.js +9 -62
- package/dist/components/infotext/model.d.ts +1 -1
- package/dist/components/infotext/model.js +1 -0
- package/dist/components/input/index.d.ts +1 -1
- package/dist/components/input/index.js +1 -0
- package/dist/components/input/input.d.ts +1 -1
- package/dist/components/input/input.js +154 -198
- package/dist/components/input/model.d.ts +1 -1
- package/dist/components/input/model.js +5 -21
- package/dist/components/link/index.d.ts +1 -1
- package/dist/components/link/index.js +1 -0
- package/dist/components/link/link.d.ts +1 -1
- package/dist/components/link/link.js +9 -70
- package/dist/components/link/model.d.ts +1 -1
- package/dist/components/link/model.js +3 -8
- package/dist/components/navigation/index.d.ts +1 -1
- package/dist/components/navigation/index.js +1 -0
- package/dist/components/navigation/model.d.ts +1 -1
- package/dist/components/navigation/model.js +1 -0
- package/dist/components/navigation/navigation.d.ts +1 -1
- package/dist/components/navigation/navigation.js +9 -57
- package/dist/components/navigation-item/index.d.ts +1 -1
- package/dist/components/navigation-item/index.js +1 -0
- package/dist/components/navigation-item/model.d.ts +2 -2
- package/dist/components/navigation-item/model.js +1 -0
- package/dist/components/navigation-item/navigation-item.d.ts +1 -1
- package/dist/components/navigation-item/navigation-item.js +71 -117
- package/dist/components/notification/index.d.ts +1 -1
- package/dist/components/notification/index.js +1 -0
- package/dist/components/notification/model.d.ts +1 -1
- package/dist/components/notification/model.js +3 -12
- package/dist/components/notification/notification.d.ts +2 -2
- package/dist/components/notification/notification.js +23 -100
- package/dist/components/page/index.d.ts +1 -1
- package/dist/components/page/index.js +1 -0
- package/dist/components/page/model.d.ts +1 -1
- package/dist/components/page/model.js +2 -4
- package/dist/components/page/page.d.ts +1 -1
- package/dist/components/page/page.js +42 -74
- package/dist/components/popover/index.d.ts +1 -1
- package/dist/components/popover/index.js +1 -0
- package/dist/components/popover/model.d.ts +1 -1
- package/dist/components/popover/model.js +1 -0
- package/dist/components/popover/popover.d.ts +1 -1
- package/dist/components/popover/popover.js +119 -126
- package/dist/components/radio/index.d.ts +1 -1
- package/dist/components/radio/index.js +1 -0
- package/dist/components/radio/model.d.ts +1 -1
- package/dist/components/radio/model.js +1 -0
- package/dist/components/radio/radio.d.ts +1 -1
- package/dist/components/radio/radio.js +86 -124
- package/dist/components/section/index.d.ts +1 -1
- package/dist/components/section/index.js +1 -0
- package/dist/components/section/model.d.ts +1 -1
- package/dist/components/section/model.js +1 -0
- package/dist/components/section/section.d.ts +1 -1
- package/dist/components/section/section.js +9 -59
- package/dist/components/select/index.d.ts +1 -1
- package/dist/components/select/index.js +1 -0
- package/dist/components/select/model.d.ts +1 -1
- package/dist/components/select/model.js +1 -0
- package/dist/components/select/select.d.ts +1 -1
- package/dist/components/select/select.js +172 -188
- package/dist/components/stack/index.d.ts +1 -1
- package/dist/components/stack/index.js +1 -0
- package/dist/components/stack/model.d.ts +1 -1
- package/dist/components/stack/model.js +4 -14
- package/dist/components/stack/stack.d.ts +1 -1
- package/dist/components/stack/stack.js +9 -63
- package/dist/components/switch/index.d.ts +1 -1
- package/dist/components/switch/index.js +1 -0
- package/dist/components/switch/model.d.ts +1 -1
- package/dist/components/switch/model.js +1 -0
- package/dist/components/switch/switch.d.ts +1 -1
- package/dist/components/switch/switch.js +135 -182
- package/dist/components/tab-item/index.d.ts +1 -1
- package/dist/components/tab-item/index.js +1 -0
- package/dist/components/tab-item/model.d.ts +1 -1
- package/dist/components/tab-item/model.js +1 -0
- package/dist/components/tab-item/tab-item.d.ts +1 -1
- package/dist/components/tab-item/tab-item.js +72 -105
- package/dist/components/tab-list/index.d.ts +1 -1
- package/dist/components/tab-list/index.js +1 -0
- package/dist/components/tab-list/model.d.ts +1 -1
- package/dist/components/tab-list/model.js +1 -0
- package/dist/components/tab-list/tab-list.d.ts +1 -1
- package/dist/components/tab-list/tab-list.js +9 -60
- package/dist/components/tab-panel/index.d.ts +1 -1
- package/dist/components/tab-panel/index.js +1 -0
- package/dist/components/tab-panel/model.d.ts +1 -1
- package/dist/components/tab-panel/model.js +1 -0
- package/dist/components/tab-panel/tab-panel.d.ts +1 -1
- package/dist/components/tab-panel/tab-panel.js +10 -59
- package/dist/components/table/examples/data.d.ts +1 -1
- package/dist/components/table/examples/data.js +258 -0
- package/dist/components/table/index.d.ts +1 -1
- package/dist/components/table/index.js +1 -0
- package/dist/components/table/model.d.ts +2 -2
- package/dist/components/table/model.js +6 -28
- package/dist/components/table/table.d.ts +1 -1
- package/dist/components/table/table.js +77 -111
- package/dist/components/table-body/index.d.ts +1 -1
- package/dist/components/table-body/index.js +1 -0
- package/dist/components/table-body/model.d.ts +2 -2
- package/dist/components/table-body/model.js +1 -0
- package/dist/components/table-body/table-body.d.ts +1 -1
- package/dist/components/table-body/table-body.js +12 -64
- package/dist/components/table-caption/index.d.ts +1 -1
- package/dist/components/table-caption/index.js +1 -0
- package/dist/components/table-caption/model.d.ts +1 -1
- package/dist/components/table-caption/model.js +1 -0
- package/dist/components/table-caption/table-caption.d.ts +1 -1
- package/dist/components/table-caption/table-caption.js +9 -57
- package/dist/components/table-data-cell/index.d.ts +1 -1
- package/dist/components/table-data-cell/index.js +1 -0
- package/dist/components/table-data-cell/model.d.ts +1 -1
- package/dist/components/table-data-cell/model.js +1 -0
- package/dist/components/table-data-cell/table-data-cell.d.ts +1 -1
- package/dist/components/table-data-cell/table-data-cell.js +9 -62
- package/dist/components/table-footer/index.d.ts +1 -1
- package/dist/components/table-footer/index.js +1 -0
- package/dist/components/table-footer/model.d.ts +2 -2
- package/dist/components/table-footer/model.js +1 -0
- package/dist/components/table-footer/table-footer.d.ts +1 -1
- package/dist/components/table-footer/table-footer.js +12 -64
- package/dist/components/table-head/index.d.ts +1 -1
- package/dist/components/table-head/index.js +1 -0
- package/dist/components/table-head/model.d.ts +2 -2
- package/dist/components/table-head/model.js +1 -0
- package/dist/components/table-head/table-head.d.ts +1 -1
- package/dist/components/table-head/table-head.js +18 -71
- package/dist/components/table-header-cell/index.d.ts +1 -1
- package/dist/components/table-header-cell/index.js +1 -0
- package/dist/components/table-header-cell/model.d.ts +1 -1
- package/dist/components/table-header-cell/model.js +1 -9
- package/dist/components/table-header-cell/table-header-cell.d.ts +1 -1
- package/dist/components/table-header-cell/table-header-cell.js +9 -65
- package/dist/components/table-row/index.d.ts +1 -1
- package/dist/components/table-row/index.js +1 -0
- package/dist/components/table-row/model.d.ts +4 -4
- package/dist/components/table-row/model.js +1 -8
- package/dist/components/table-row/table-row.d.ts +1 -1
- package/dist/components/table-row/table-row.js +20 -127
- package/dist/components/tabs/index.d.ts +1 -1
- package/dist/components/tabs/index.js +1 -0
- package/dist/components/tabs/model.d.ts +3 -3
- package/dist/components/tabs/model.js +2 -4
- package/dist/components/tabs/tabs.d.ts +1 -1
- package/dist/components/tabs/tabs.js +170 -191
- package/dist/components/tag/index.d.ts +1 -1
- package/dist/components/tag/index.js +1 -0
- package/dist/components/tag/model.d.ts +1 -1
- package/dist/components/tag/model.js +1 -4
- package/dist/components/tag/tag.d.ts +1 -1
- package/dist/components/tag/tag.js +26 -91
- package/dist/components/textarea/index.d.ts +1 -1
- package/dist/components/textarea/index.js +1 -0
- package/dist/components/textarea/model.d.ts +1 -1
- package/dist/components/textarea/model.js +2 -13
- package/dist/components/textarea/textarea.d.ts +1 -1
- package/dist/components/textarea/textarea.js +139 -165
- package/dist/components/tooltip/index.d.ts +1 -1
- package/dist/components/tooltip/index.js +1 -0
- package/dist/components/tooltip/model.d.ts +1 -1
- package/dist/components/tooltip/model.js +1 -4
- package/dist/components/tooltip/tooltip.d.ts +1 -1
- package/dist/components/tooltip/tooltip.js +197 -160
- package/dist/index.d.ts +97 -97
- package/dist/index.js +97 -75
- package/dist/shared/constants.js +100 -32
- package/dist/shared/examples/index.js +4 -0
- package/dist/shared/figma.js +1 -0
- package/dist/shared/model.js +22 -77
- package/dist/shared/showcase/show-code-link.js +51 -0
- package/dist/utils/document-click-listener.js +29 -26
- package/dist/utils/document-scroll-listener.js +38 -30
- package/dist/utils/floating-components.js +404 -107
- package/dist/utils/form-components.js +71 -34
- package/dist/utils/index.d.ts +1 -1
- package/dist/utils/index.js +170 -49
- package/dist/utils/navigation.js +134 -68
- package/dist/utils/react.js +21 -10
- package/package.json +6 -9
package/dist/index.js
CHANGED
|
@@ -1,75 +1,97 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
export
|
|
1
|
+
export * from './components/accordion/index.js';
|
|
2
|
+
export * from './components/accordion-item/index.js';
|
|
3
|
+
export * from './components/accordion-item/model.js';
|
|
4
|
+
export * from './components/accordion/model.js';
|
|
5
|
+
export * from './components/badge/index.js';
|
|
6
|
+
export * from './components/badge/model.js';
|
|
7
|
+
export * from './components/brand/index.js';
|
|
8
|
+
export * from './components/brand/model.js';
|
|
9
|
+
export * from './components/button/index.js';
|
|
10
|
+
export * from './components/button/model.js';
|
|
11
|
+
export * from './components/card/index.js';
|
|
12
|
+
export * from './components/card/model.js';
|
|
13
|
+
export * from './components/checkbox/index.js';
|
|
14
|
+
export * from './components/checkbox/model.js';
|
|
15
|
+
export * from './components/custom-button/index.js';
|
|
16
|
+
export * from './components/custom-button/model.js';
|
|
17
|
+
export * from './components/custom-select/index.js';
|
|
18
|
+
export * from './components/custom-select-dropdown/index.js';
|
|
19
|
+
export * from './components/custom-select-dropdown/model.js';
|
|
20
|
+
export * from './components/custom-select-form-field/index.js';
|
|
21
|
+
export * from './components/custom-select-form-field/model.js';
|
|
22
|
+
export * from './components/custom-select-list/index.js';
|
|
23
|
+
export * from './components/custom-select-list-item/index.js';
|
|
24
|
+
export * from './components/custom-select-list-item/model.js';
|
|
25
|
+
export * from './components/custom-select-list/model.js';
|
|
26
|
+
export * from './components/custom-select/model.js';
|
|
27
|
+
export * from './components/divider/index.js';
|
|
28
|
+
export * from './components/divider/model.js';
|
|
29
|
+
export * from './components/drawer/index.js';
|
|
30
|
+
export * from './components/drawer/model.js';
|
|
31
|
+
export * from './components/header/index.js';
|
|
32
|
+
export * from './components/header/model.js';
|
|
33
|
+
export * from './components/icon/index.js';
|
|
34
|
+
export * from './components/icon/model.js';
|
|
35
|
+
export * from './components/infotext/index.js';
|
|
36
|
+
export * from './components/infotext/model.js';
|
|
37
|
+
export * from './components/input/index.js';
|
|
38
|
+
export * from './components/input/model.js';
|
|
39
|
+
export * from './components/link/index.js';
|
|
40
|
+
export * from './components/link/model.js';
|
|
41
|
+
export * from './components/navigation/index.js';
|
|
42
|
+
export * from './components/navigation-item/index.js';
|
|
43
|
+
export * from './components/navigation-item/model.js';
|
|
44
|
+
export * from './components/navigation/model.js';
|
|
45
|
+
export * from './components/notification/index.js';
|
|
46
|
+
export * from './components/notification/model.js';
|
|
47
|
+
export * from './components/page/index.js';
|
|
48
|
+
export * from './components/page/model.js';
|
|
49
|
+
export * from './components/popover/index.js';
|
|
50
|
+
export * from './components/popover/model.js';
|
|
51
|
+
export * from './components/radio/index.js';
|
|
52
|
+
export * from './components/radio/model.js';
|
|
53
|
+
export * from './components/section/index.js';
|
|
54
|
+
export * from './components/section/model.js';
|
|
55
|
+
export * from './components/select/index.js';
|
|
56
|
+
export * from './components/select/model.js';
|
|
57
|
+
export * from './components/stack/index.js';
|
|
58
|
+
export * from './components/stack/model.js';
|
|
59
|
+
export * from './components/switch/index.js';
|
|
60
|
+
export * from './components/switch/model.js';
|
|
61
|
+
export * from './components/tab-item/index.js';
|
|
62
|
+
export * from './components/tab-item/model.js';
|
|
63
|
+
export * from './components/tab-list/index.js';
|
|
64
|
+
export * from './components/tab-list/model.js';
|
|
65
|
+
export * from './components/tab-panel/index.js';
|
|
66
|
+
export * from './components/tab-panel/model.js';
|
|
67
|
+
export * from './components/table/index.js';
|
|
68
|
+
export * from './components/table-body/index.js';
|
|
69
|
+
export * from './components/table-body/model.js';
|
|
70
|
+
export * from './components/table-caption/index.js';
|
|
71
|
+
export * from './components/table-caption/model.js';
|
|
72
|
+
export * from './components/table-data-cell/index.js';
|
|
73
|
+
export * from './components/table-data-cell/model.js';
|
|
74
|
+
export * from './components/table-footer/index.js';
|
|
75
|
+
export * from './components/table-footer/model.js';
|
|
76
|
+
export * from './components/table-head/index.js';
|
|
77
|
+
export * from './components/table-head/model.js';
|
|
78
|
+
export * from './components/table-header-cell/index.js';
|
|
79
|
+
export * from './components/table-header-cell/model.js';
|
|
80
|
+
export * from './components/table-row/index.js';
|
|
81
|
+
export * from './components/table-row/model.js';
|
|
82
|
+
export * from './components/table/model.js';
|
|
83
|
+
export * from './components/tabs/index.js';
|
|
84
|
+
export * from './components/tabs/model.js';
|
|
85
|
+
export * from './components/tag/index.js';
|
|
86
|
+
export * from './components/tag/model.js';
|
|
87
|
+
export * from './components/textarea/index.js';
|
|
88
|
+
export * from './components/textarea/model.js';
|
|
89
|
+
export * from './components/tooltip/index.js';
|
|
90
|
+
export * from './components/tooltip/model.js';
|
|
91
|
+
export * from './shared/constants.js';
|
|
92
|
+
export * from './shared/model.js';
|
|
93
|
+
export * from './utils/document-click-listener.js';
|
|
94
|
+
export * from './utils/document-scroll-listener.js';
|
|
95
|
+
export * from './utils/floating-components.js';
|
|
96
|
+
export * from './utils/index.js';
|
|
97
|
+
export * from './utils/navigation.js';
|
package/dist/shared/constants.js
CHANGED
|
@@ -1,32 +1,100 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
1
|
+
export const DEFAULT_ID = 'OVERWRITE_DEFAULT_ID';
|
|
2
|
+
export const DEFAULT_LABEL = 'LABEL SHOULD BE SET';
|
|
3
|
+
export const DEFAULT_PLACEHOLDER = ' ';
|
|
4
|
+
export const DEFAULT_MESSAGE = 'MESSAGE SHOULD BE SET';
|
|
5
|
+
export const DEFAULT_LABEL_ID_SUFFIX = '-label';
|
|
6
|
+
export const DEFAULT_SELECT_ID_SUFFIX = '-select';
|
|
7
|
+
export const DEFAULT_MESSAGE_ID_SUFFIX = '-message';
|
|
8
|
+
export const DEFAULT_VALID_MESSAGE_ID_SUFFIX = '-valid-message';
|
|
9
|
+
export const DEFAULT_INVALID_MESSAGE_ID_SUFFIX = '-invalid-message';
|
|
10
|
+
export const DEFAULT_PLACEHOLDER_ID_SUFFIX = '-placeholder';
|
|
11
|
+
export const DEFAULT_DATALIST_ID_SUFFIX = '-datalist';
|
|
12
|
+
export const DEFAULT_VALID_MESSAGE = 'TODO: Add a validMessage';
|
|
13
|
+
export const DEFAULT_INVALID_MESSAGE = 'TODO: Add an invalidMessage';
|
|
14
|
+
export const DEFAULT_REMOVE = 'Remove';
|
|
15
|
+
export const DEFAULT_BACK = 'Back';
|
|
16
|
+
export const DEFAULT_SELECTED = 'Selected';
|
|
17
|
+
export const DEFAULT_BURGER_MENU = 'BurgerMenu';
|
|
18
|
+
export const DEFAULT_ICON = 'brand';
|
|
19
|
+
export const DEFAULT_ROWS = 4;
|
|
20
|
+
export const DEFAULT_CLOSE_BUTTON = 'Close';
|
|
21
|
+
export const DENSITY_CONST = 'density';
|
|
22
|
+
export const COLOR_CONST = 'color';
|
|
23
|
+
export var DENSITY;
|
|
24
|
+
(function (DENSITY) {
|
|
25
|
+
DENSITY["FUNCTIONAL"] = "functional";
|
|
26
|
+
DENSITY["REGULAR"] = "regular";
|
|
27
|
+
DENSITY["EXPRESSIVE"] = "expressive";
|
|
28
|
+
})(DENSITY || (DENSITY = {}));
|
|
29
|
+
export const DENSITIES = Object.entries(DENSITY).map(([, value]) => value);
|
|
30
|
+
export var COLOR_SIMPLE;
|
|
31
|
+
(function (COLOR_SIMPLE) {
|
|
32
|
+
COLOR_SIMPLE["PRIMARY"] = "primary";
|
|
33
|
+
})(COLOR_SIMPLE || (COLOR_SIMPLE = {}));
|
|
34
|
+
export var COLOR;
|
|
35
|
+
(function (COLOR) {
|
|
36
|
+
COLOR["NEUTRAL_BG_LEVEL_1"] = "neutral-bg-basic-level-1";
|
|
37
|
+
COLOR["NEUTRAL_BG_LEVEL_2"] = "neutral-bg-basic-level-2";
|
|
38
|
+
COLOR["NEUTRAL_BG_LEVEL_3"] = "neutral-bg-basic-level-3";
|
|
39
|
+
COLOR["NEUTRAL_BG_TRANSPARENT_SEMI"] = "neutral-bg-basic-transparent-semi";
|
|
40
|
+
COLOR["NEUTRAL_BG_TRANSPARENT_FULL"] = "neutral-bg-basic-transparent-full";
|
|
41
|
+
COLOR["BRAND_BG_LEVEL_1"] = "brand-bg-basic-level-1";
|
|
42
|
+
COLOR["BRAND_BG_LEVEL_2"] = "brand-bg-basic-level-2";
|
|
43
|
+
COLOR["BRAND_BG_LEVEL_3"] = "brand-bg-basic-level-3";
|
|
44
|
+
COLOR["BRAND_BG_TRANSPARENT_SEMI"] = "brand-bg-basic-transparent-semi";
|
|
45
|
+
COLOR["BRAND_BG_TRANSPARENT_FULL"] = "brand-bg-basic-transparent-full";
|
|
46
|
+
COLOR["SUCCESSFUL_BG_LEVEL_1"] = "successful-bg-basic-level-1";
|
|
47
|
+
COLOR["SUCCESSFUL_BG_LEVEL_2"] = "successful-bg-basic-level-2";
|
|
48
|
+
COLOR["SUCCESSFUL_BG_LEVEL_3"] = "successful-bg-basic-level-3";
|
|
49
|
+
COLOR["SUCCESSFUL_BG_TRANSPARENT_SEMI"] = "successful-bg-basic-transparent-semi";
|
|
50
|
+
COLOR["SUCCESSFUL_BG_TRANSPARENT_FULL"] = "successful-bg-basic-transparent-full";
|
|
51
|
+
COLOR["CRITICAL_BG_LEVEL_1"] = "critical-bg-basic-level-1";
|
|
52
|
+
COLOR["CRITICAL_BG_LEVEL_2"] = "critical-bg-basic-level-2";
|
|
53
|
+
COLOR["CRITICAL_BG_LEVEL_3"] = "critical-bg-basic-level-3";
|
|
54
|
+
COLOR["CRITICAL_BG_TRANSPARENT_SEMI"] = "critical-bg-basic-transparent-semi";
|
|
55
|
+
COLOR["CRITICAL_BG_TRANSPARENT_Full"] = "critical-bg-basic-transparent-full";
|
|
56
|
+
COLOR["WARNING_BG_LEVEL_1"] = "warning-bg-basic-level-1";
|
|
57
|
+
COLOR["WARNING_BG_LEVEL_2"] = "warning-bg-basic-level-2";
|
|
58
|
+
COLOR["WARNING_BG_LEVEL_3"] = "warning-bg-basic-level-3";
|
|
59
|
+
COLOR["WARNING_BG_TRANSPARENT_SEMI"] = "warning-bg-basic-transparent-semi";
|
|
60
|
+
COLOR["WARNING_BG_TRANSPARENT_FULL"] = "warning-bg-basic-transparent-full";
|
|
61
|
+
COLOR["INFORMATIONAL_BG_LEVEL_1"] = "informational-bg-basic-level-1";
|
|
62
|
+
COLOR["INFORMATIONAL_BG_LEVEL_2"] = "informational-bg-basic-level-2";
|
|
63
|
+
COLOR["INFORMATIONAL_BG_LEVEL_3"] = "informational-bg-basic-level-3";
|
|
64
|
+
COLOR["INFORMATIONAL_BG_TRANSPARENT_SEMI"] = "informational-bg-basic-transparent-semi";
|
|
65
|
+
COLOR["INFORMATIONAL_BG_TRANSPARENT_FULL"] = "informational-bg-basic-transparent-full";
|
|
66
|
+
})(COLOR || (COLOR = {}));
|
|
67
|
+
export const COLORS = Object.entries(COLOR).map(([, value]) => value);
|
|
68
|
+
export const COLORS_SIMPLE = Object.entries(COLOR_SIMPLE).map(([, value]) => value);
|
|
69
|
+
export var SEMANTIC;
|
|
70
|
+
(function (SEMANTIC) {
|
|
71
|
+
SEMANTIC["CRITICAL"] = "critical";
|
|
72
|
+
SEMANTIC["INFORMATIONAL"] = "informational";
|
|
73
|
+
SEMANTIC["WARNING"] = "warning";
|
|
74
|
+
SEMANTIC["SUCCESSFUL"] = "successful";
|
|
75
|
+
})(SEMANTIC || (SEMANTIC = {}));
|
|
76
|
+
export const SEMANTICS = Object.entries(SEMANTIC).map(([, value]) => value);
|
|
77
|
+
export const DEFAULT_VIEWPORT = {
|
|
78
|
+
width: 390,
|
|
79
|
+
height: 884
|
|
80
|
+
};
|
|
81
|
+
export const DESKTOP_VIEWPORT = {
|
|
82
|
+
width: 1920,
|
|
83
|
+
height: 1280
|
|
84
|
+
};
|
|
85
|
+
/**
|
|
86
|
+
* Use those viewports if your component has a css media-query otherwise use the DEFAULT_VIEWPORT
|
|
87
|
+
*/
|
|
88
|
+
export const TESTING_VIEWPORTS = [{
|
|
89
|
+
name: 'desktop',
|
|
90
|
+
...DESKTOP_VIEWPORT
|
|
91
|
+
}, {
|
|
92
|
+
name: 'tablet',
|
|
93
|
+
width: 768,
|
|
94
|
+
height: 1024
|
|
95
|
+
}, {
|
|
96
|
+
name: 'mobile',
|
|
97
|
+
...DEFAULT_VIEWPORT
|
|
98
|
+
}];
|
|
99
|
+
export const DB_UX_LOCAL_STORAGE_FRAMEWORK = 'db-ux-framework';
|
|
100
|
+
export const DB_UX_LOCAL_STORAGE_MODE = 'db-ux-mode';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/shared/model.js
CHANGED
|
@@ -1,77 +1,22 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
"left-end",
|
|
24
|
-
"right-start",
|
|
25
|
-
"right-end"
|
|
26
|
-
], i = [
|
|
27
|
-
"top",
|
|
28
|
-
"bottom",
|
|
29
|
-
"top-start",
|
|
30
|
-
"top-end",
|
|
31
|
-
"bottom-start",
|
|
32
|
-
"bottom-end"
|
|
33
|
-
], a = [...r, ...i], o = [
|
|
34
|
-
"none",
|
|
35
|
-
"3x-large",
|
|
36
|
-
"2x-large",
|
|
37
|
-
"x-large",
|
|
38
|
-
"large",
|
|
39
|
-
"medium",
|
|
40
|
-
"small",
|
|
41
|
-
"x-small",
|
|
42
|
-
"2x-small",
|
|
43
|
-
"3x-small"
|
|
44
|
-
], s = ["horizontal", "vertical"], c = ["full", "auto"], l = [
|
|
45
|
-
"full",
|
|
46
|
-
"medium",
|
|
47
|
-
"large",
|
|
48
|
-
"small"
|
|
49
|
-
], u = [
|
|
50
|
-
"none",
|
|
51
|
-
"slow",
|
|
52
|
-
"fast"
|
|
53
|
-
], d = ["auto", "fixed"], f = ["small", "medium"], p = ["weak", "strong"], m = [
|
|
54
|
-
"invalid",
|
|
55
|
-
"valid",
|
|
56
|
-
"no-validation"
|
|
57
|
-
], h = ["fixed", "content"], g = ["above", "floating"], _ = ["leading", "trailing"], v = /* @__PURE__ */ "off.on.name.honorific-prefix.given-name.additional-name.family-name.honorific-suffix.nickname.email.username.new-password.current-password.one-time-code.organization-title.organization.street-address.shipping.billing.address-line1.address-line2.address-line3.address-level4.address-level3.address-level2.address-level1.country.country-name.postal-code.cc-name.cc-given-name.cc-additional-name.cc-family-name.cc-number.cc-exp.cc-exp-month.cc-exp-year.cc-csc.cc-type.transaction-currency.transaction-amount.language.bday.bday-day.bday-month.bday-year.sex.tel.tel-country-code.tel-national.tel-area-code.tel-local.tel-extension.impp.url.photo.webauthn".split("."), y = [
|
|
58
|
-
"_self",
|
|
59
|
-
"_blank",
|
|
60
|
-
"_parent",
|
|
61
|
-
"_top"
|
|
62
|
-
], b = [
|
|
63
|
-
"no-referrer",
|
|
64
|
-
"no-referrer-when-downgrade",
|
|
65
|
-
"origin",
|
|
66
|
-
"origin-when-cross-origin",
|
|
67
|
-
"same-origin",
|
|
68
|
-
"strict-origin",
|
|
69
|
-
"strict-origin-when-cross-origin",
|
|
70
|
-
"unsafe-url"
|
|
71
|
-
], x = [
|
|
72
|
-
"start",
|
|
73
|
-
"center",
|
|
74
|
-
"end"
|
|
75
|
-
];
|
|
76
|
-
//#endregion
|
|
77
|
-
export { x as AlignmentList, v as AutoCompleteList, p as EmphasisList, h as FieldSizingList, o as GapSpacingList, _ as LabelVariantHorizontalList, g as LabelVariantList, b as LinkReferrerPolicyList, y as LinkTargetList, n as MarginList, l as MaxWidthList, s as OrientationList, r as PlacementHorizontalList, a as PlacementList, i as PlacementVerticalList, u as PopoverDelayList, d as PopoverWidthList, e as SemanticList, f as SizeList, t as SpacingList, m as ValidationList, c as WidthList };
|
|
1
|
+
export const SemanticList = ['adaptive', 'neutral', 'critical', 'informational', 'warning', 'successful'];
|
|
2
|
+
export const SpacingList = ['medium', 'small', 'large', 'none'];
|
|
3
|
+
export const MarginList = ['medium', 'small', 'large', 'none'];
|
|
4
|
+
export const PlacementHorizontalList = ['left', 'right', 'left-start', 'left-end', 'right-start', 'right-end'];
|
|
5
|
+
export const PlacementVerticalList = ['top', 'bottom', 'top-start', 'top-end', 'bottom-start', 'bottom-end'];
|
|
6
|
+
export const PlacementList = [...PlacementHorizontalList, ...PlacementVerticalList];
|
|
7
|
+
export const GapSpacingList = ['none', '3x-large', '2x-large', 'x-large', 'large', 'medium', 'small', 'x-small', '2x-small', '3x-small'];
|
|
8
|
+
export const OrientationList = ['horizontal', 'vertical'];
|
|
9
|
+
export const WidthList = ['full', 'auto'];
|
|
10
|
+
export const MaxWidthList = ['full', 'medium', 'large', 'small'];
|
|
11
|
+
export const PopoverDelayList = ['none', 'slow', 'fast'];
|
|
12
|
+
export const PopoverWidthList = ['auto', 'fixed'];
|
|
13
|
+
export const SizeList = ['small', 'medium'];
|
|
14
|
+
export const EmphasisList = ['weak', 'strong'];
|
|
15
|
+
export const ValidationList = ['invalid', 'valid', 'no-validation'];
|
|
16
|
+
export const FieldSizingList = ['fixed', 'content'];
|
|
17
|
+
export const LabelVariantList = ['above', 'floating'];
|
|
18
|
+
export const LabelVariantHorizontalList = ['leading', 'trailing'];
|
|
19
|
+
export const AutoCompleteList = ['off', 'on', 'name', 'honorific-prefix', 'given-name', 'additional-name', 'family-name', 'honorific-suffix', 'nickname', 'email', 'username', 'new-password', 'current-password', 'one-time-code', 'organization-title', 'organization', 'street-address', 'shipping', 'billing', 'address-line1', 'address-line2', 'address-line3', 'address-level4', 'address-level3', 'address-level2', 'address-level1', 'country', 'country-name', 'postal-code', 'cc-name', 'cc-given-name', 'cc-additional-name', 'cc-family-name', 'cc-number', 'cc-exp', 'cc-exp-month', 'cc-exp-year', 'cc-csc', 'cc-type', 'transaction-currency', 'transaction-amount', 'language', 'bday', 'bday-day', 'bday-month', 'bday-year', 'sex', 'tel', 'tel-country-code', 'tel-national', 'tel-area-code', 'tel-local', 'tel-extension', 'impp', 'url', 'photo', 'webauthn'];
|
|
20
|
+
export const LinkTargetList = ['_self', '_blank', '_parent', '_top'];
|
|
21
|
+
export const LinkReferrerPolicyList = ['no-referrer', 'no-referrer-when-downgrade', 'origin', 'origin-when-cross-origin', 'same-origin', 'strict-origin', 'strict-origin-when-cross-origin', 'unsafe-url'];
|
|
22
|
+
export const AlignmentList = ['start', 'center', 'end'];
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
const LOCALHOST_STORYBOOK_PORT_MAP = {
|
|
2
|
+
react: '6005',
|
|
3
|
+
angular: '6006',
|
|
4
|
+
vue: '6007',
|
|
5
|
+
html: '6001'
|
|
6
|
+
};
|
|
7
|
+
const DEFAULT_FRAMEWORK = 'react';
|
|
8
|
+
const NON_COMPONENT_ROUTE_SEGMENTS = new Set(['docs', 'overview']);
|
|
9
|
+
/**
|
|
10
|
+
* Builds the Storybook docs path for a component route.
|
|
11
|
+
* @param pathname - URL pathname (e.g., "/docs/components/my-button")
|
|
12
|
+
* @returns Storybook docs path or undefined when no component segment is available
|
|
13
|
+
*/
|
|
14
|
+
function buildStorybookDocsPathname(pathname) {
|
|
15
|
+
const segments = pathname.split('/').filter(Boolean);
|
|
16
|
+
const componentsIndex = segments.indexOf('components');
|
|
17
|
+
const routeSegments = segments.slice(componentsIndex + 1);
|
|
18
|
+
if (componentsIndex === -1 || routeSegments.length === 0) {
|
|
19
|
+
return undefined;
|
|
20
|
+
}
|
|
21
|
+
let componentName = routeSegments.at(-1);
|
|
22
|
+
if (componentName && NON_COMPONENT_ROUTE_SEGMENTS.has(componentName) && routeSegments.length > 1) {
|
|
23
|
+
componentName = routeSegments.at(-2);
|
|
24
|
+
}
|
|
25
|
+
if (!componentName) {
|
|
26
|
+
return undefined;
|
|
27
|
+
}
|
|
28
|
+
const normalizedComponentName = componentName.replace(/-/g, '');
|
|
29
|
+
return `/docs/components-db${normalizedComponentName}`;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Resolves the framework-specific Storybook URL for the current component page.
|
|
33
|
+
* @param currentUrl - Current page URL
|
|
34
|
+
* @param frameworkRaw - Framework name ('react', 'angular', 'vue', 'html')
|
|
35
|
+
* @returns Storybook URL or undefined when the component route cannot be determined
|
|
36
|
+
*/
|
|
37
|
+
export function getShowCodeHref(currentUrl, frameworkRaw) {
|
|
38
|
+
const framework = (frameworkRaw || DEFAULT_FRAMEWORK).toLowerCase();
|
|
39
|
+
const url = new URL(currentUrl);
|
|
40
|
+
const componentsIndex = url.pathname.indexOf('/components/');
|
|
41
|
+
const docsPath = buildStorybookDocsPathname(url.pathname);
|
|
42
|
+
if (componentsIndex === -1 || !docsPath) {
|
|
43
|
+
return undefined;
|
|
44
|
+
}
|
|
45
|
+
if (url.hostname === 'localhost' || url.hostname === '127.0.0.1') {
|
|
46
|
+
const port = LOCALHOST_STORYBOOK_PORT_MAP[framework] || LOCALHOST_STORYBOOK_PORT_MAP[DEFAULT_FRAMEWORK];
|
|
47
|
+
return `${url.protocol}//${url.hostname}:${port}/?path=${docsPath}`;
|
|
48
|
+
}
|
|
49
|
+
const basePath = url.pathname.slice(0, componentsIndex);
|
|
50
|
+
return `${url.origin}${basePath}/${framework}-storybook?path=${docsPath}`;
|
|
51
|
+
}
|
|
@@ -1,26 +1,29 @@
|
|
|
1
|
-
import { uuid
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
1
|
+
import { uuid } from './index.js';
|
|
2
|
+
export class DocumentClickListener {
|
|
3
|
+
static callbacks = {};
|
|
4
|
+
static _instance = null;
|
|
5
|
+
static runCallbacks(event) {
|
|
6
|
+
for (const callback of Object.values(DocumentClickListener.callbacks)) {
|
|
7
|
+
if (typeof callback === 'function') {
|
|
8
|
+
callback(event);
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
constructor() {
|
|
13
|
+
if (DocumentClickListener._instance) {
|
|
14
|
+
return DocumentClickListener._instance;
|
|
15
|
+
}
|
|
16
|
+
DocumentClickListener._instance = this;
|
|
17
|
+
if (self.document) {
|
|
18
|
+
self.document.addEventListener('click', event => DocumentClickListener.runCallbacks(event));
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
addCallback(callback) {
|
|
22
|
+
const callbackID = uuid();
|
|
23
|
+
DocumentClickListener.callbacks[callbackID] = callback;
|
|
24
|
+
return callbackID;
|
|
25
|
+
}
|
|
26
|
+
removeCallback(id) {
|
|
27
|
+
delete DocumentClickListener.callbacks[id];
|
|
28
|
+
}
|
|
29
|
+
}
|