@epam/ai-dial-ui-kit 0.15.0-dev.4 → 0.15.0-dev.42

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.
Files changed (202) hide show
  1. package/README.md +191 -0
  2. package/dist/CHANGELOG.md +75 -0
  3. package/dist/DateCellRenderer-ChqbDlQ2.cjs +1 -0
  4. package/dist/{DateCellRenderer-BVM-Q8yx.cjs → DateCellRenderer-Cl_mNbi1.cjs} +31 -31
  5. package/dist/IconButton-DHOFapLo.cjs +1 -0
  6. package/dist/JsonEditor-CpSpVa0v.cjs +1 -0
  7. package/dist/{MarkdownEditor-jQ8nDJfx.cjs → MarkdownEditor-CPzMv3lE.cjs} +1 -1
  8. package/dist/{MarkdownEditor-DHn2pYOJ.cjs → MarkdownEditor-NYMcKLJy.cjs} +1 -1
  9. package/dist/MarkdownEditorContainer-DVPRplYf.cjs +1 -0
  10. package/dist/{Switch-CUKClcEz.cjs → Switch-DE6MrcqJ.cjs} +1 -1
  11. package/dist/components/Button/constants.js +9 -8
  12. package/dist/components/Dropdown/Dropdown.js +70 -65
  13. package/dist/components/Dropdown/DropdownSubMenuItem.js +63 -55
  14. package/dist/components/Dropdown/constants.js +16 -14
  15. package/dist/components/DropdownIcon/DropdownIcon.js +43 -32
  16. package/dist/components/FileManager/FileManager.js +373 -372
  17. package/dist/components/FileManager/FileManagerProvider.js +266 -264
  18. package/dist/components/FileManager/hooks/use-grid-context-menu.js +59 -59
  19. package/dist/components/MarkdownEditor/MarkdownEditorContainer.js +18 -16
  20. package/dist/components/New/Accordion/Accordion.js +87 -71
  21. package/dist/components/New/AutocompleteTagInput/AutocompleteTagInput.js +206 -0
  22. package/dist/components/New/AutocompleteTagInput/utils.js +11 -0
  23. package/dist/components/New/Avatar/Avatar.js +70 -0
  24. package/dist/components/New/Badge/Badge.js +45 -0
  25. package/dist/components/New/BottomSheet/BottomSheet.js +128 -0
  26. package/dist/components/New/Breadcrumbs/Breadcrumbs.js +159 -0
  27. package/dist/components/New/Breadcrumbs/constants.js +41 -0
  28. package/dist/components/New/Button/Button.js +32 -32
  29. package/dist/components/New/Button/ButtonWrappers.js +93 -37
  30. package/dist/components/New/Button/constants.js +3 -0
  31. package/dist/components/New/Button/utils.js +18 -8
  32. package/dist/components/New/ButtonDropdown/ButtonDropdown.js +26 -16
  33. package/dist/components/New/Calendar/Calendar.js +301 -265
  34. package/dist/components/New/Calendar/constants.js +5 -5
  35. package/dist/components/New/CaptionText/CaptionText.js +18 -15
  36. package/dist/components/New/CardShell/CardShell.js +5 -3
  37. package/dist/components/New/Checkbox/Checkbox.js +67 -56
  38. package/dist/components/New/Checkbox/CheckboxBox.js +5 -3
  39. package/dist/components/New/CloseButton/CloseButton.js +18 -16
  40. package/dist/components/New/CollapsibleSidebar/CollapsibleSidebar.js +39 -34
  41. package/dist/components/New/ConfirmationPopup/ConfirmationPopup.js +38 -37
  42. package/dist/components/New/ConfirmationPopup/constants.js +8 -11
  43. package/dist/components/New/Dropdown/Dropdown.js +112 -105
  44. package/dist/components/New/Dropdown/DropdownSubMenuItem.js +17 -17
  45. package/dist/components/New/Dropdown/constants.js +22 -17
  46. package/dist/components/New/EllipsisTooltip/EllipsisTooltip.js +20 -18
  47. package/dist/components/New/EntityIdentity/EntityIdentity.js +135 -0
  48. package/dist/components/New/FileDropzone/FileDropzone.js +27 -25
  49. package/dist/components/New/FileIcon/FileIcon.js +55 -0
  50. package/dist/components/New/FileIcon/constants.js +134 -0
  51. package/dist/components/New/FileIcon/icons/FileGlyph.js +150 -0
  52. package/dist/components/New/FileIcon/icons/FolderGlyph.js +50 -0
  53. package/dist/components/New/FileName/FileName.js +78 -0
  54. package/dist/components/New/FilterChips/FilterChips.js +43 -0
  55. package/dist/components/New/FilterChips/constants.js +5 -0
  56. package/dist/components/New/FolderName/FolderName.js +16 -0
  57. package/dist/components/New/FolderPath/FolderPath.js +29 -28
  58. package/dist/components/New/Highlight/Highlight.js +23 -30
  59. package/dist/components/New/IconButton/IconButton.js +30 -28
  60. package/dist/components/New/InfoButton/InfoButton.js +13 -11
  61. package/dist/components/New/InlineSelect/InlineSelect.js +74 -56
  62. package/dist/components/New/InteractiveTooltip/InteractiveTooltip.js +41 -39
  63. package/dist/components/New/InteractiveTooltip/constants.js +2 -2
  64. package/dist/components/New/Label/Label.js +13 -8
  65. package/dist/components/New/MenuItem/MenuItem.js +29 -27
  66. package/dist/components/New/MenuItem/constants.js +9 -8
  67. package/dist/components/New/NoDataContent/NoDataContent.js +21 -19
  68. package/dist/components/New/Notification/Notification.js +33 -29
  69. package/dist/components/New/NumberInput/NumberInput.js +42 -33
  70. package/dist/components/New/PasswordInput/PasswordInput.js +41 -35
  71. package/dist/components/New/Popup/Popup.js +46 -44
  72. package/dist/components/New/Popup/constants.js +3 -3
  73. package/dist/components/New/Radio/Radio.js +75 -64
  74. package/dist/components/New/RadioGroup/RadioGroup.js +76 -65
  75. package/dist/components/New/RadioGroupPopupField/RadioGroupPopupField.js +117 -106
  76. package/dist/components/New/ResizableContainer/ResizableContainer.js +42 -40
  77. package/dist/components/New/Search/Search.js +29 -27
  78. package/dist/components/New/SegmentedControl/SegmentedControl.js +29 -23
  79. package/dist/components/New/Select/CollapsedSelectTags.js +127 -0
  80. package/dist/components/New/Select/MultiSelectTags.js +18 -15
  81. package/dist/components/New/Select/Select.js +219 -197
  82. package/dist/components/New/Select/constants.js +23 -20
  83. package/dist/components/New/SharedEntityIndicator/SharedEntityIndicator.js +34 -0
  84. package/dist/components/New/SideDrawer/SideDrawer.js +148 -0
  85. package/dist/components/New/Switch/Switch.js +69 -58
  86. package/dist/components/New/Tabs/Tabs.js +125 -61
  87. package/dist/components/New/Tag/Tag.js +42 -40
  88. package/dist/components/New/TagInput/TagInput.js +48 -44
  89. package/dist/components/New/ToggleIconButton/ToggleIconButton.js +26 -24
  90. package/dist/components/New/Tooltip/TooltipContent.js +11 -9
  91. package/dist/components/New/Tooltip/constants.js +1 -1
  92. package/dist/components/New/TransferQueue/TransferQueue.js +124 -0
  93. package/dist/components/New/TransferQueue/TransferQueueHeader.js +71 -0
  94. package/dist/components/New/TransferQueue/TransferQueueRow.js +119 -0
  95. package/dist/components/New/TransferQueue/constants.js +24 -0
  96. package/dist/components/New/constants/overlay.js +17 -9
  97. package/dist/components/Popup/constants.js +8 -8
  98. package/dist/components/ProgressBar/ProgressBar.js +45 -33
  99. package/dist/components/SchemaRenderer/components/SchemaAdditionalPropertiesEditor.js +46 -31
  100. package/dist/components/SchemaRenderer/components/SchemaField.js +19 -19
  101. package/dist/components/SchemaRenderer/components/SchemaFieldContent.js +18 -18
  102. package/dist/components/SchemaRenderer/components/SchemaKeyValueEditor.js +223 -135
  103. package/dist/components/SchemaRenderer/types.js +19 -8
  104. package/dist/components/SchemaRenderer/utils.js +122 -95
  105. package/dist/components/Skeleton/Skeleton.js +25 -19
  106. package/dist/components/Spinner/Spinner.js +7 -5
  107. package/dist/components/Tooltip/TooltipContent.js +11 -11
  108. package/dist/components-manifest.json +1653 -71
  109. package/dist/constants/public-class-names.js +210 -0
  110. package/dist/dial-ui-kit.cjs +2 -2
  111. package/dist/dial-ui-kit.js +346 -299
  112. package/dist/editor-Bc9xzKuR.cjs +1 -0
  113. package/dist/editors.cjs +1 -1
  114. package/dist/file-manager.cjs +1 -1
  115. package/dist/grid.cjs +1 -1
  116. package/dist/index.css +2 -2
  117. package/dist/lazy-Cy9WobJf.cjs +1 -0
  118. package/dist/merge-classes-BEJXjzkx.cjs +1 -0
  119. package/dist/migration-guides/0.15.0/legacy-theme-variable-fallbacks-removal.md +69 -0
  120. package/dist/migration-guides/README.md +1 -0
  121. package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js +419 -399
  122. package/dist/src/components/FileManager/FileManager.d.ts +2 -0
  123. package/dist/src/components/FileManager/FileManagerContext.d.ts +1 -0
  124. package/dist/src/components/FileManager/hooks/use-grid-context-menu.d.ts +2 -1
  125. package/dist/src/components/New/Accordion/Accordion.d.ts +6 -1
  126. package/dist/src/components/New/AutocompleteTagInput/AutocompleteTagInput.d.ts +97 -0
  127. package/dist/src/components/New/AutocompleteTagInput/utils.d.ts +17 -0
  128. package/dist/src/components/New/AutocompleteTagInput/utils.spec.d.ts +1 -0
  129. package/dist/src/components/New/Avatar/Avatar.d.ts +55 -0
  130. package/dist/src/components/New/Badge/Badge.d.ts +47 -0
  131. package/dist/src/components/New/BottomSheet/BottomSheet.d.ts +84 -0
  132. package/dist/src/components/New/Breadcrumbs/Breadcrumbs.d.ts +94 -0
  133. package/dist/src/components/New/Breadcrumbs/constants.d.ts +60 -0
  134. package/dist/src/components/New/Button/Button.d.ts +4 -1
  135. package/dist/src/components/New/Button/ButtonWrappers.d.ts +20 -0
  136. package/dist/src/components/New/Button/utils.d.ts +15 -0
  137. package/dist/src/components/New/ButtonDropdown/ButtonDropdown.d.ts +4 -0
  138. package/dist/src/components/New/Calendar/Calendar.d.ts +7 -1
  139. package/dist/src/components/New/Calendar/constants.d.ts +1 -1
  140. package/dist/src/components/New/ConfirmationPopup/constants.d.ts +0 -1
  141. package/dist/src/components/New/Dropdown/Dropdown.d.ts +9 -1
  142. package/dist/src/components/New/Dropdown/constants.d.ts +3 -0
  143. package/dist/src/components/New/EntityIdentity/EntityIdentity.d.ts +85 -0
  144. package/dist/src/components/New/FileIcon/FileIcon.d.ts +61 -0
  145. package/dist/src/components/New/FileIcon/constants.d.ts +16 -0
  146. package/dist/src/components/New/FileIcon/icons/FileGlyph.d.ts +18 -0
  147. package/dist/src/components/New/FileIcon/icons/FolderGlyph.d.ts +17 -0
  148. package/dist/src/components/New/FileName/FileName.d.ts +79 -0
  149. package/dist/src/components/New/FilterChips/FilterChips.d.ts +69 -0
  150. package/dist/src/components/New/FilterChips/constants.d.ts +13 -0
  151. package/dist/src/components/New/FolderName/FolderName.d.ts +37 -0
  152. package/dist/src/components/New/InlineSelect/InlineSelect.d.ts +16 -1
  153. package/dist/src/components/New/InteractiveTooltip/constants.d.ts +5 -4
  154. package/dist/src/components/New/Notification/Notification.d.ts +18 -0
  155. package/dist/src/components/New/Popup/constants.d.ts +1 -1
  156. package/dist/src/components/New/Select/CollapsedSelectTags.d.ts +22 -0
  157. package/dist/src/components/New/Select/MultiSelectTags.d.ts +5 -0
  158. package/dist/src/components/New/Select/Select.d.ts +9 -0
  159. package/dist/src/components/New/Select/constants.d.ts +3 -2
  160. package/dist/src/components/New/SharedEntityIndicator/SharedEntityIndicator.d.ts +35 -0
  161. package/dist/src/components/New/SideDrawer/SideDrawer.d.ts +100 -0
  162. package/dist/src/components/New/Tabs/Tabs.d.ts +54 -6
  163. package/dist/src/components/New/Tooltip/constants.d.ts +5 -3
  164. package/dist/src/components/New/TransferQueue/TransferQueue.d.ts +139 -0
  165. package/dist/src/components/New/TransferQueue/TransferQueueHeader.d.ts +16 -0
  166. package/dist/src/components/New/TransferQueue/TransferQueueRow.d.ts +10 -0
  167. package/dist/src/components/New/TransferQueue/constants.d.ts +6 -0
  168. package/dist/src/components/New/constants/overlay.d.ts +13 -0
  169. package/dist/src/components/Popup/constants.d.ts +1 -1
  170. package/dist/src/components/SchemaRenderer/types.d.ts +11 -0
  171. package/dist/src/components/SchemaRenderer/utils.d.ts +10 -1
  172. package/dist/src/constants/public-class-names.d.ts +201 -0
  173. package/dist/src/index.d.ts +36 -1
  174. package/dist/src/types/accordion.d.ts +7 -0
  175. package/dist/src/types/avatar.d.ts +7 -0
  176. package/dist/src/types/badge.d.ts +16 -0
  177. package/dist/src/types/breadcrumbs.d.ts +9 -0
  178. package/dist/src/types/button.d.ts +1 -0
  179. package/dist/src/types/entity-type.d.ts +9 -0
  180. package/dist/src/types/transfer-queue.d.ts +10 -0
  181. package/dist/src/utils/__tests__/avatar.spec.d.ts +1 -0
  182. package/dist/src/utils/avatar.d.ts +12 -0
  183. package/dist/src/utils/sub-menu-floating.d.ts +7 -4
  184. package/dist/types/accordion.js +4 -0
  185. package/dist/types/avatar.js +4 -0
  186. package/dist/types/badge.js +5 -0
  187. package/dist/types/breadcrumbs.js +4 -0
  188. package/dist/types/button.js +3 -3
  189. package/dist/types/entity-type.js +4 -0
  190. package/dist/types/transfer-queue.js +4 -0
  191. package/dist/use-file-manager-tabs-C-dMqEFy.cjs +3 -0
  192. package/dist/utils/avatar.js +22 -0
  193. package/dist/utils/merge-classes.js +12 -5
  194. package/dist/utils/sub-menu-floating.js +99 -54
  195. package/package.json +4 -7
  196. package/dist/DateCellRenderer-ssp7eaZY.cjs +0 -1
  197. package/dist/IconButton-DWqoaBWf.cjs +0 -1
  198. package/dist/JsonEditor-qv1Z0dLX.cjs +0 -1
  199. package/dist/MarkdownEditorContainer-Bzcnoemw.cjs +0 -1
  200. package/dist/lazy-tfN4sKhq.cjs +0 -1
  201. package/dist/merge-classes-Dipy1Ih1.cjs +0 -1
  202. package/dist/use-file-manager-tabs-DjdR_mYM.cjs +0 -3
@@ -1,63 +1,64 @@
1
- import { JsonSchemaType as d } from "./types.js";
2
- function b(r, n) {
1
+ import { JsonSchemaType as f } from "./types.js";
2
+ function $(r, n) {
3
3
  const i = { ...r, ...n };
4
4
  return (r.properties || n.properties) && (i.properties = { ...r.properties, ...n.properties }), (r.required || n.required) && (i.required = Array.from(
5
5
  /* @__PURE__ */ new Set([...r.required ?? [], ...n.required ?? []])
6
6
  )), i;
7
7
  }
8
- function u(r, n, i = 0) {
8
+ function p(r, n, i = 0) {
9
9
  if (i > 10) return r;
10
10
  let t = r;
11
11
  if (t.$ref) {
12
12
  const e = t.$ref.replace(/^#\//, "").split("/");
13
13
  let o = n;
14
- for (const l of e)
15
- o = o?.[l];
14
+ for (const u of e)
15
+ o = o?.[u];
16
16
  if (!o || typeof o != "object") return r;
17
- const { $ref: f, ...y } = t, p = o;
18
- t = { ...p.$ref ? u(p, n, i + 1) : p, ...y };
17
+ const { $ref: s, ...y } = t, d = o;
18
+ t = { ...d.$ref ? p(d, n, i + 1) : d, ...y };
19
19
  }
20
20
  if (t.allOf && t.allOf.length > 0) {
21
21
  const { allOf: e, ...o } = t;
22
- let f = {};
22
+ let s = {};
23
23
  for (const y of e)
24
- f = b(f, u(y, n, i + 1));
25
- t = b(f, o);
24
+ s = $(s, p(y, n, i + 1));
25
+ t = $(s, o);
26
26
  }
27
27
  return t;
28
28
  }
29
- function P(r) {
29
+ function T(r) {
30
30
  return r.map((n, i) => ({ entry: n, index: i })).sort((n, i) => {
31
31
  const t = n.entry[1]["dial:meta"]?.["dial:propertyOrder"] ?? 1 / 0, e = i.entry[1]["dial:meta"]?.["dial:propertyOrder"] ?? 1 / 0;
32
32
  return t !== e ? t - e : n.index - i.index;
33
33
  }).map(({ entry: n }) => n);
34
34
  }
35
- function A(r) {
35
+ function j(r) {
36
36
  return r == null || r === "";
37
37
  }
38
38
  function O(r) {
39
- return r.type === d.Object || r.properties != null && r.oneOf == null && r.anyOf == null && r.type == null;
39
+ return r.type === f.Object || r.properties != null && r.oneOf == null && r.anyOf == null && r.type == null;
40
40
  }
41
- function I(r) {
41
+ function N(r) {
42
42
  return r.replace(/_/g, " ").replace(/([a-z])([A-Z])/g, "$1 $2").replace(/\b\w/g, (n) => n.toUpperCase());
43
43
  }
44
+ const I = (r) => `"${r}" is required`;
44
45
  function q(r, n) {
45
- return r.type === d.Null ? "null" : r.$ref ? u(r, n).title ?? r.$ref.split("/").pop() ?? "Option" : r.title ? r.title : r.type ? Array.isArray(r.type) ? r.type.join(" | ") : r.type : r.discriminator ? Object.keys(r.discriminator.mapping).join(" | ") : r.const != null ? String(r.const) : r.oneOf ? "One of options" : "Option";
46
+ return r.type === f.Null ? "null" : r.$ref ? p(r, n).title ?? r.$ref.split("/").pop() ?? "Option" : r.title ? r.title : r.type ? Array.isArray(r.type) ? r.type.join(" | ") : r.type : r.discriminator ? Object.keys(r.discriminator.mapping).join(" | ") : r.const != null ? String(r.const) : r.oneOf ? "One of options" : "Option";
46
47
  }
47
- function j(r, n, i = 0) {
48
+ function A(r, n, i = 0) {
48
49
  if (i > 15) return;
49
- const t = u(r, n);
50
+ const t = p(r, n);
50
51
  if ("default" in t)
51
52
  return t.default;
52
53
  if (t.discriminator && t.oneOf) {
53
54
  const e = Object.keys(t.discriminator.mapping)[0];
54
55
  if (e) {
55
- const o = u(
56
+ const o = p(
56
57
  { $ref: t.discriminator.mapping[e] },
57
58
  n
58
59
  );
59
60
  return {
60
- ...j(o, n, i + 1) ?? {},
61
+ ...A(o, n, i + 1) ?? {},
61
62
  [t.discriminator.propertyName]: e
62
63
  };
63
64
  }
@@ -66,9 +67,9 @@ function j(r, n, i = 0) {
66
67
  if (t.properties) {
67
68
  const e = {};
68
69
  let o = !1;
69
- for (const [f, y] of Object.entries(t.properties)) {
70
- const p = j(y, n, i + 1);
71
- p !== void 0 && (e[f] = p, o = !0);
70
+ for (const [s, y] of Object.entries(t.properties)) {
71
+ const d = A(y, n, i + 1);
72
+ d !== void 0 && (e[s] = d, o = !0);
72
73
  }
73
74
  return o ? e : void 0;
74
75
  }
@@ -76,26 +77,26 @@ function j(r, n, i = 0) {
76
77
  return {};
77
78
  }
78
79
  }
79
- function $(r, n, i, t = "", e = 0) {
80
+ function b(r, n, i, t = "", e = 0) {
80
81
  if (e > 15) return [];
81
- const o = [], f = u(n, i);
82
- if (f.anyOf) {
83
- const s = f.anyOf.filter(
84
- (l) => l.type !== d.Null
82
+ const o = [], s = p(n, i);
83
+ if (s.anyOf) {
84
+ const l = s.anyOf.filter(
85
+ (u) => u.type !== f.Null
85
86
  );
86
- return r != null && s.length === 1 ? $(
87
+ return r != null && l.length === 1 ? b(
87
88
  r,
88
- s[0],
89
+ l[0],
89
90
  i,
90
91
  t,
91
92
  e + 1
92
93
  ) : o;
93
94
  }
94
- if (f.oneOf && f.discriminator) {
95
- const s = f.discriminator.propertyName, l = r?.[s];
96
- if (l && f.discriminator.mapping[l]) {
97
- const a = { $ref: f.discriminator.mapping[l] }, c = u(a, i);
98
- return $(
95
+ if (s.oneOf && s.discriminator) {
96
+ const l = s.discriminator.propertyName, u = r?.[l];
97
+ if (u && s.discriminator.mapping[u]) {
98
+ const a = { $ref: s.discriminator.mapping[u] }, c = p(a, i);
99
+ return b(
99
100
  r,
100
101
  c,
101
102
  i,
@@ -105,41 +106,41 @@ function $(r, n, i, t = "", e = 0) {
105
106
  }
106
107
  return o;
107
108
  }
108
- if (f.type === d.Array || !f.type && Array.isArray(r)) {
109
- if (Array.isArray(r) && f.items)
110
- for (let s = 0; s < r.length; s++) {
111
- const l = $(
112
- r[s],
113
- f.items,
109
+ if (s.type === f.Array || !s.type && Array.isArray(r)) {
110
+ if (Array.isArray(r) && s.items)
111
+ for (let l = 0; l < r.length; l++) {
112
+ const u = b(
113
+ r[l],
114
+ s.items,
114
115
  i,
115
- `${t}[${s}]`,
116
+ `${t}[${l}]`,
116
117
  e + 1
117
118
  );
118
- o.push(...l);
119
+ o.push(...u);
119
120
  }
120
121
  return o;
121
122
  }
122
- if (!O(f)) return o;
123
- const y = f.required ?? [], p = r;
124
- for (const s of y) {
125
- const l = f.properties?.[s];
126
- if (l && u(l, i).isHidden)
123
+ if (!O(s)) return o;
124
+ const y = s.required ?? [], d = r;
125
+ for (const l of y) {
126
+ const u = s.properties?.[l];
127
+ if (u && p(u, i).isHidden)
127
128
  continue;
128
- const a = t ? `${t}.${s}` : s, c = p?.[s];
129
- if (A(c)) {
130
- const g = l?.title ?? I(s);
131
- o.push({ path: a, message: `${g} is required` });
129
+ const a = t ? `${t}.${l}` : l, c = d?.[l];
130
+ if (j(c)) {
131
+ const g = u?.title ?? N(l);
132
+ o.push({ path: a, message: I(g) });
132
133
  }
133
134
  }
134
- if (p && f.properties)
135
- for (const [s, l] of Object.entries(f.properties)) {
136
- if (u(l, i).isHidden)
135
+ if (d && s.properties)
136
+ for (const [l, u] of Object.entries(s.properties)) {
137
+ if (p(u, i).isHidden)
137
138
  continue;
138
- const a = t ? `${t}.${s}` : s, c = p[s];
139
+ const a = t ? `${t}.${l}` : l, c = d[l];
139
140
  if (c != null) {
140
- const g = $(
141
+ const g = b(
141
142
  c,
142
- l,
143
+ u,
143
144
  i,
144
145
  a,
145
146
  e + 1
@@ -147,12 +148,12 @@ function $(r, n, i, t = "", e = 0) {
147
148
  o.push(...g);
148
149
  }
149
150
  }
150
- if (p && f.additionalProperties != null && f.additionalProperties !== !1 && typeof f.additionalProperties == "object") {
151
- const s = f.additionalProperties;
152
- for (const [l, a] of Object.entries(p)) {
153
- const c = t ? `${t}.${l}` : l, g = $(
151
+ if (d && s.additionalProperties != null && s.additionalProperties !== !1 && typeof s.additionalProperties == "object") {
152
+ const l = s.additionalProperties;
153
+ for (const [u, a] of Object.entries(d)) {
154
+ const c = t ? `${t}.${u}` : u, g = b(
154
155
  a,
155
- s,
156
+ l,
156
157
  i,
157
158
  c,
158
159
  e + 1
@@ -162,61 +163,61 @@ function $(r, n, i, t = "", e = 0) {
162
163
  }
163
164
  return o;
164
165
  }
165
- function v(r, n, i) {
166
- const t = u(n, i);
166
+ function E(r, n, i) {
167
+ const t = p(n, i);
167
168
  if (Array.isArray(r))
168
169
  return `${r.length} item${r.length !== 1 ? "s" : ""}`;
169
170
  if (O(t) && t.properties) {
170
171
  const e = Object.entries(t.properties).filter(
171
- ([, p]) => !u(p, i).isHidden
172
- ), o = e.length, f = r;
173
- return `${e.filter(([p]) => {
174
- const s = f?.[p];
175
- return s != null && s !== "";
172
+ ([, d]) => !p(d, i).isHidden
173
+ ), o = e.length, s = r;
174
+ return `${e.filter(([d]) => {
175
+ const l = s?.[d];
176
+ return l != null && l !== "";
176
177
  }).length}/${o} fields`;
177
178
  }
178
179
  return "";
179
180
  }
180
- function N(r, n, i) {
181
+ function R(r, n, i) {
181
182
  if (r == null) {
182
- const t = n.findIndex((e) => e.type === d.Null);
183
+ const t = n.findIndex((e) => e.type === f.Null);
183
184
  return t >= 0 ? t : 0;
184
185
  }
185
186
  if (Array.isArray(r)) {
186
- const t = n.findIndex((e) => u(e, i).type === d.Array);
187
+ const t = n.findIndex((e) => p(e, i).type === f.Array);
187
188
  return t >= 0 ? t : 0;
188
189
  }
189
190
  if (typeof r == "boolean") {
190
- const t = n.findIndex((e) => u(e, i).type === d.Boolean);
191
+ const t = n.findIndex((e) => p(e, i).type === f.Boolean);
191
192
  return t >= 0 ? t : 0;
192
193
  }
193
194
  if (typeof r == "number") {
194
195
  const t = n.findIndex((e) => {
195
- const o = u(e, i);
196
- return o.type === d.Number || o.type === d.Integer;
196
+ const o = p(e, i);
197
+ return o.type === f.Number || o.type === f.Integer;
197
198
  });
198
199
  return t >= 0 ? t : 0;
199
200
  }
200
201
  if (typeof r == "string") {
201
- const t = n.findIndex((e) => u(e, i).type === d.String);
202
+ const t = n.findIndex((e) => p(e, i).type === f.String);
202
203
  return t >= 0 ? t : 0;
203
204
  }
204
205
  if (typeof r == "object") {
205
206
  const t = r;
206
207
  for (let e = 0; e < n.length; e++) {
207
- const o = u(n[e], i);
208
+ const o = p(n[e], i);
208
209
  if (o.discriminator && o.discriminator.propertyName in t)
209
210
  return e;
210
211
  }
211
212
  for (let e = 0; e < n.length; e++) {
212
- const o = u(n[e], i);
213
+ const o = p(n[e], i);
213
214
  if (O(o) || o.oneOf) return e;
214
215
  }
215
216
  return 0;
216
217
  }
217
218
  return 0;
218
219
  }
219
- function V(r, n, i) {
220
+ function B(r, n, i) {
220
221
  if (n && typeof r == "object" && r !== null) {
221
222
  const t = r[n];
222
223
  if (t) return `Item ${i + 1}: ${t}`;
@@ -227,32 +228,58 @@ function V(r, n, i) {
227
228
  }
228
229
  return `Item ${i + 1}`;
229
230
  }
230
- function k(r) {
231
+ function D(r) {
231
232
  switch (Array.isArray(r.type) ? r.type[0] : r.type) {
232
- case d.String:
233
+ case f.String:
233
234
  return "";
234
- case d.Boolean:
235
+ case f.Boolean:
235
236
  return !1;
236
- case d.Array:
237
+ case f.Array:
237
238
  return [];
238
- case d.Integer:
239
- case d.Number:
239
+ case f.Integer:
240
+ case f.Number:
240
241
  return;
241
242
  default:
242
243
  return {};
243
244
  }
244
245
  }
246
+ const V = [
247
+ f.String,
248
+ f.Number,
249
+ f.Boolean,
250
+ f.Null,
251
+ f.Object,
252
+ f.Array
253
+ ];
254
+ function k(r) {
255
+ return Array.isArray(r) ? f.Array : typeof r == "object" && r !== null ? f.Object : typeof r == "boolean" ? f.Boolean : typeof r == "number" ? f.Number : r === null ? f.Null : f.String;
256
+ }
257
+ const P = {
258
+ [f.String]: "",
259
+ [f.Number]: 0,
260
+ [f.Boolean]: !1,
261
+ [f.Null]: null,
262
+ [f.Object]: {},
263
+ [f.Array]: []
264
+ };
265
+ function _(r) {
266
+ return P[r];
267
+ }
245
268
  export {
246
- v as buildSummary,
247
- N as detectAnyOfVariant,
248
- j as extractDefaults,
249
- V as getItemTitle,
269
+ V as ENTRY_TYPE_OPTIONS,
270
+ E as buildSummary,
271
+ R as detectAnyOfVariant,
272
+ A as extractDefaults,
273
+ _ as getEntryTypeDefault,
274
+ B as getItemTitle,
250
275
  q as getOptionLabel,
251
- k as getSchemaDefault,
252
- A as isMissingRequiredValue,
276
+ D as getSchemaDefault,
277
+ k as inferEntryType,
278
+ j as isMissingRequiredValue,
253
279
  O as isObjectType,
254
- u as resolveRef,
255
- P as sortByPropertyOrder,
256
- I as toFieldLabel,
257
- $ as validateRequired
280
+ p as resolveRef,
281
+ T as sortByPropertyOrder,
282
+ N as toFieldLabel,
283
+ I as toRequiredMessage,
284
+ b as validateRequired
258
285
  };
@@ -1,14 +1,15 @@
1
- import { jsx as t, Fragment as $, jsxs as k } from "react/jsx-runtime";
1
+ import { jsx as t, Fragment as L, jsxs as k } from "react/jsx-runtime";
2
2
  import "react";
3
3
  import { mergeClasses as n } from "../../utils/merge-classes.js";
4
- import { SkeletonVariant as i, SkeletonAvatarShape as N } from "../../types/skeleton.js";
5
- import { getAvatarSize as F } from "./utils.js";
6
- const G = ({
7
- active: j = !0,
4
+ import { SkeletonVariant as i, SkeletonAvatarShape as S } from "../../types/skeleton.js";
5
+ import { getAvatarSize as P } from "./utils.js";
6
+ import { DIAL_KIT_CLASS as R } from "../../constants/public-class-names.js";
7
+ const B = ({
8
+ active: A = !0,
8
9
  paragraph: u = !0,
9
10
  avatar: m = !1,
10
11
  showTitle: p = !0,
11
- loading: S = !0,
12
+ loading: N = !0,
12
13
  children: g,
13
14
  variant: o = i.Default,
14
15
  width: l,
@@ -16,13 +17,13 @@ const G = ({
16
17
  overlay: s,
17
18
  color: e,
18
19
  className: h,
19
- ...b
20
+ ...C
20
21
  }) => {
21
- if (!S && g)
22
- return /* @__PURE__ */ t($, { children: g });
22
+ if (!N && g)
23
+ return /* @__PURE__ */ t(L, { children: g });
23
24
  const d = n(
24
25
  "bg-layer-raised",
25
- j && "animate-pulse",
26
+ A && "animate-pulse",
26
27
  h
27
28
  );
28
29
  if (o !== i.Default) {
@@ -33,21 +34,26 @@ const G = ({
33
34
  o === i.Text && "rounded",
34
35
  !!s && "relative"
35
36
  ), r = {};
36
- return l && (r.width = typeof l == "number" ? `${l}px` : l), c && (r.height = typeof c == "number" ? `${c}px` : c), e && (r.backgroundColor = e), /* @__PURE__ */ t("div", { className: a, style: r, ...b, children: s && /* @__PURE__ */ t("div", { className: "absolute inset-0 flex items-center justify-center pointer-events-none", children: s }) });
37
+ return l && (r.width = typeof l == "number" ? `${l}px` : l), c && (r.height = typeof c == "number" ? `${c}px` : c), e && (r.backgroundColor = e), /* @__PURE__ */ t("div", { className: a, style: r, ...C, children: s && /* @__PURE__ */ t("div", { className: "absolute inset-0 flex items-center justify-center pointer-events-none", children: s }) });
37
38
  }
38
- const A = !!m, w = !!p, z = !!u, x = typeof m == "object" ? m : {}, W = typeof p == "object" ? p : {}, C = typeof u == "object" ? u : {}, y = F(x.size), D = x.shape ?? N.Circle, P = W.width ?? "38%", v = C.rows ?? 3, f = C.width, R = (a) => f ? Array.isArray(f) ? f[a] ?? "100%" : f : a === v - 1 ? "61%" : "100%";
39
+ const j = !!m, w = !!p, z = !!u, b = typeof m == "object" ? m : {}, D = typeof p == "object" ? p : {}, x = typeof u == "object" ? u : {}, y = P(b.size), W = b.shape ?? S.Circle, _ = D.width ?? "38%", v = x.rows ?? 3, f = x.width, I = (a) => f ? Array.isArray(f) ? f[a] ?? "100%" : f : a === v - 1 ? "61%" : "100%";
39
40
  return /* @__PURE__ */ k(
40
41
  "div",
41
42
  {
42
- ...b,
43
- className: n("flex gap-4", !!s && "relative", h),
43
+ ...C,
44
+ className: n(
45
+ "flex gap-4",
46
+ !!s && "relative",
47
+ h,
48
+ R.skeleton
49
+ ),
44
50
  children: [
45
- A && /* @__PURE__ */ t(
51
+ j && /* @__PURE__ */ t(
46
52
  "div",
47
53
  {
48
54
  className: n(
49
55
  d,
50
- D === N.Circle ? "rounded-full" : "rounded",
56
+ W === S.Circle ? "rounded-full" : "rounded",
51
57
  "flex-shrink-0"
52
58
  ),
53
59
  style: {
@@ -63,7 +69,7 @@ const G = ({
63
69
  {
64
70
  className: n(d, "h-4 rounded"),
65
71
  style: {
66
- width: P,
72
+ width: _,
67
73
  ...e && { backgroundColor: e }
68
74
  }
69
75
  }
@@ -73,7 +79,7 @@ const G = ({
73
79
  {
74
80
  className: n(d, "h-4 rounded"),
75
81
  style: {
76
- width: R(r),
82
+ width: I(r),
77
83
  ...e && { backgroundColor: e }
78
84
  }
79
85
  },
@@ -86,5 +92,5 @@ const G = ({
86
92
  );
87
93
  };
88
94
  export {
89
- G as Skeleton
95
+ B as Skeleton
90
96
  };
@@ -1,6 +1,7 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
- import { mergeClasses as a } from "../../utils/merge-classes.js";
3
- const o = ({
2
+ import { mergeClasses as n } from "../../utils/merge-classes.js";
3
+ import { DIAL_KIT_CLASS as o } from "../../constants/public-class-names.js";
4
+ const d = ({
4
5
  size: e = 40,
5
6
  className: s,
6
7
  fullWidth: t = !1,
@@ -9,10 +10,11 @@ const o = ({
9
10
  "div",
10
11
  {
11
12
  role: "status",
12
- className: a(
13
+ className: n(
13
14
  "flex items-center justify-center",
14
15
  { "size-full": t },
15
- s
16
+ s,
17
+ o.spinner
16
18
  ),
17
19
  children: /* @__PURE__ */ r(
18
20
  "div",
@@ -26,5 +28,5 @@ const o = ({
26
28
  }
27
29
  );
28
30
  export {
29
- o as Spinner
31
+ d as Spinner
30
32
  };
@@ -4,28 +4,28 @@ import c from "classnames";
4
4
  import { useRef as f } from "react";
5
5
  import { useHasHover as d } from "../../hooks/use-has-hover.js";
6
6
  import { useTooltipContext as x } from "./TooltipContext.js";
7
- const F = ({ style: e, ...o }) => {
8
- const r = x(), s = d(), a = f(null), l = n([r.refs.setFloating, a]);
9
- return !r.open || !s ? null : /* @__PURE__ */ t(p, { id: "tooltip-portal", children: /* @__PURE__ */ i(
7
+ const F = ({ style: e, ...r }) => {
8
+ const o = x(), s = d(), l = f(null), a = n([o.refs.setFloating, l]);
9
+ return !o.open || !s ? null : /* @__PURE__ */ t(p, { id: "tooltip-portal", children: /* @__PURE__ */ i(
10
10
  "div",
11
11
  {
12
- ref: l,
12
+ ref: a,
13
13
  style: {
14
- ...r.floatingStyles,
14
+ ...o.floatingStyles,
15
15
  ...e
16
16
  },
17
- ...r.getFloatingProps(o),
17
+ ...o.getFloatingProps(r),
18
18
  className: c(
19
- "z-[55] whitespace-pre-wrap break-words rounded border border-primary bg-layer-0 px-2 py-1 dial-tiny-text shadow max-w-[300px]",
20
- r.getFloatingProps(o).className
19
+ "z-tooltip whitespace-pre-wrap break-words rounded border border-primary bg-layer-0 px-2 py-1 dial-tiny-text shadow max-w-[300px]",
20
+ o.getFloatingProps(r).className
21
21
  ),
22
22
  children: [
23
- o.children,
23
+ r.children,
24
24
  /* @__PURE__ */ t(
25
25
  m,
26
26
  {
27
- ref: r.arrowRef,
28
- context: r.context,
27
+ ref: o.arrowRef,
28
+ context: o.context,
29
29
  fill: "currentColor",
30
30
  strokeWidth: 1,
31
31
  className: "stroke-primary text-[var(--bg-layer-0,_#000000)]"