@tcn/ui 0.3.0 → 0.3.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.
Files changed (127) hide show
  1. package/dist/Color-ASIRERSW-B4GaVKuQ.js +990 -0
  2. package/dist/Color-ASIRERSW-B4GaVKuQ.js.map +1 -0
  3. package/dist/WithTooltip-IO6J4KBT-B1oq93K5.js +1485 -0
  4. package/dist/WithTooltip-IO6J4KBT-B1oq93K5.js.map +1 -0
  5. package/dist/actions/__docs__/components/gallery.d.ts +8 -0
  6. package/dist/actions/__docs__/components/gallery.d.ts.map +1 -0
  7. package/dist/actions/__docs__/components/gallery.js +20 -0
  8. package/dist/actions/__docs__/components/gallery.js.map +1 -0
  9. package/dist/actions/__docs__/components/showcase.d.ts +27 -0
  10. package/dist/actions/__docs__/components/showcase.d.ts.map +1 -0
  11. package/dist/actions/__docs__/components/showcase.js +15 -0
  12. package/dist/actions/__docs__/components/showcase.js.map +1 -0
  13. package/dist/actions/button/base_button/base_button.d.ts +2 -0
  14. package/dist/actions/button/base_button/base_button.d.ts.map +1 -1
  15. package/dist/actions/button/base_button/base_button.js +18 -16
  16. package/dist/actions/button/base_button/base_button.js.map +1 -1
  17. package/dist/actions/button/button/button.js +6 -6
  18. package/dist/actions/button/button_group/button_group.js +1 -1
  19. package/dist/actions/button/select_group/select_group.js +13 -13
  20. package/dist/actions/button/select_group/single_select_group.js +6 -6
  21. package/dist/actions/button/slim_button/slim_button.js +2 -2
  22. package/dist/actions/types.d.ts +2 -0
  23. package/dist/actions/types.d.ts.map +1 -0
  24. package/dist/actions/types.js +2 -0
  25. package/dist/actions/types.js.map +1 -0
  26. package/dist/feedback/loading/loading.js +12 -12
  27. package/dist/feedback/loading/loading.js.map +1 -1
  28. package/dist/feedback/progress/progress_bar.js +1 -1
  29. package/dist/form/field/common/field_control/field_control.js +8 -8
  30. package/dist/form/field/common/status_input/status_input.js +6 -6
  31. package/dist/form/field/field.js +5 -5
  32. package/dist/form/field/h_field/h_field.js +11 -11
  33. package/dist/form/field/v_field/v_field.js +10 -10
  34. package/dist/form/field_set/field_set.js +3 -3
  35. package/dist/formatter-QJ4M4OGQ-DaIl2Wi_.js +6 -0
  36. package/dist/formatter-QJ4M4OGQ-DaIl2Wi_.js.map +1 -0
  37. package/dist/gallery.css +1 -0
  38. package/dist/inputs/checkbox/checkbox.js +11 -11
  39. package/dist/inputs/color_input/color_picker.js +5 -5
  40. package/dist/inputs/combo_box/combo_box.js +16 -16
  41. package/dist/inputs/date_picker/date_picker.js +18 -18
  42. package/dist/inputs/date_picker/date_picker_body.js +2 -2
  43. package/dist/inputs/date_picker/date_picker_input.js +18 -18
  44. package/dist/inputs/input/input.js +5 -5
  45. package/dist/inputs/mask_input/key_capture_input.js +7 -7
  46. package/dist/inputs/mask_input/mask_input.js +4 -4
  47. package/dist/inputs/multi_combo_box/multi_combo_box.js +17 -17
  48. package/dist/inputs/multiselect/multiselect.js +13 -13
  49. package/dist/inputs/multiselect/multiselect_row.js +8 -8
  50. package/dist/inputs/phone_number_input/phone_number_input.js +11 -11
  51. package/dist/inputs/radio/radio.js +10 -10
  52. package/dist/inputs/radio/radio_row.js +3 -3
  53. package/dist/inputs/select/select.js +14 -14
  54. package/dist/inputs/slider/slider.js +10 -10
  55. package/dist/inputs/switch/switch.js +4 -4
  56. package/dist/inputs/textarea/textarea.js +7 -7
  57. package/dist/inputs/unit_input/unit_input.js +4 -4
  58. package/dist/layouts/body/h_body.js +7 -7
  59. package/dist/layouts/body/v_body.js +6 -6
  60. package/dist/layouts/column/column.js +17 -17
  61. package/dist/layouts/footer/footer.js +7 -7
  62. package/dist/layouts/grid/grid.js +24 -24
  63. package/dist/layouts/header/header.js +2 -2
  64. package/dist/layouts/list/item.js +2 -2
  65. package/dist/layouts/list/list.js +7 -7
  66. package/dist/layouts/list/section_header.js +6 -6
  67. package/dist/layouts/scaffold/scaffold.js +16 -16
  68. package/dist/layouts/sidebar_end/sidebar_end.js +14 -14
  69. package/dist/layouts/sidebar_start/sidebar_start.js +10 -10
  70. package/dist/layouts/utility_bar/utility_bar.js +10 -10
  71. package/dist/overlay/frame/frame.js +4 -4
  72. package/dist/overlay/menu/menu.js +34 -34
  73. package/dist/overlay/portal/portal_platform_context.js +4 -4
  74. package/dist/showcase-WfP6kBEb.js +58401 -0
  75. package/dist/showcase-WfP6kBEb.js.map +1 -0
  76. package/dist/showcase.css +1 -0
  77. package/dist/stacks/box/box.js +23 -23
  78. package/dist/stacks/h_collapsible_box.js +2 -2
  79. package/dist/stacks/h_stack.js +41 -41
  80. package/dist/stacks/spacer.js +11 -11
  81. package/dist/stacks/story_components/circle.js +10 -10
  82. package/dist/stacks/story_components/picture_placeholder.js +9 -9
  83. package/dist/stacks/story_components/rect.js +7 -7
  84. package/dist/stacks/story_components/style_box.js +4 -4
  85. package/dist/stacks/utils/use_is_collapsed.js +6 -6
  86. package/dist/stacks/v_collapsible_box.js +2 -2
  87. package/dist/stacks/v_stack.js +42 -42
  88. package/dist/stacks/z_stack.js +39 -39
  89. package/dist/surfaces/alert/alert.js +4 -4
  90. package/dist/surfaces/card/card.js +4 -4
  91. package/dist/surfaces/confirm/confirm.js +9 -9
  92. package/dist/surfaces/drawers/drawer_start/drawer_start.js +2 -2
  93. package/dist/surfaces/drawers/drawer_top/drawer_top.js +2 -2
  94. package/dist/surfaces/modal/modal.js +5 -5
  95. package/dist/surfaces/page/h_page.js +7 -7
  96. package/dist/surfaces/page/v_page.js +5 -5
  97. package/dist/surfaces/panel/h_panel.js +14 -14
  98. package/dist/surfaces/panel/v_panel.js +9 -9
  99. package/dist/surfaces/pop_confirm/pop_confirm.js +6 -6
  100. package/dist/surfaces/popconfirm/pop_confirm.js +8 -8
  101. package/dist/surfaces/tooltip/tooltip.js +8 -8
  102. package/dist/surfaces/window/window.js +9 -9
  103. package/dist/syntaxhighlighter-IQDEPFLK-BX_eF8__.js +3777 -0
  104. package/dist/syntaxhighlighter-IQDEPFLK-BX_eF8__.js.map +1 -0
  105. package/dist/themes/themes/ergo/ergo_theme.js +33 -1
  106. package/dist/themes/themes/ergo/ergo_theme.js.map +1 -1
  107. package/dist/tokens/badge/badge.js +9 -9
  108. package/dist/tokens/bubble/bubble.js +8 -8
  109. package/dist/tokens/chip/chip.js +3 -3
  110. package/dist/utils/click_away_listener.js +10 -10
  111. package/dist/utils/click_away_listener.js.map +1 -1
  112. package/dist/utils/dnd/draggable/draggable.js +4 -4
  113. package/dist/utils/dnd/handle.js +8 -8
  114. package/dist/utils/focus_redirect.js +5 -5
  115. package/dist/utils/hooks/make_context_hook.js +4 -4
  116. package/dist/utils/hooks/use_media_query.js +2 -2
  117. package/dist/utils/hooks/use_media_query.js.map +1 -1
  118. package/package.json +1 -1
  119. package/src/actions/__docs__/actions.mdx +131 -0
  120. package/src/actions/__docs__/actions.stories.tsx +309 -0
  121. package/src/actions/__docs__/components/gallery.module.css +6 -0
  122. package/src/actions/__docs__/components/gallery.tsx +28 -0
  123. package/src/actions/__docs__/components/showcase.module.css +55 -0
  124. package/src/actions/__docs__/components/showcase.tsx +121 -0
  125. package/src/actions/button/base_button/base_button.tsx +5 -1
  126. package/src/actions/types.ts +6 -0
  127. package/src/themes/themes/ergo/ergo_theme.css +33 -1
@@ -1,42 +1,42 @@
1
1
  import { jsx as i } from "react/jsx-runtime";
2
- import { HStack as v } from "../../../stacks/h_stack.js";
2
+ import { HStack as _ } from "../../../stacks/h_stack.js";
3
3
  import { clsx as l } from "clsx";
4
4
  import n from "react";
5
- import { Button as x } from "../button/button.js";
6
- import '../../../select_group.css';const y = "_select-group_c24986f", _ = "_select-group-option_28f4dfd", b = "_select-group-divider_b5b865b", a = { "select-group": y, "select-group-option": _, "select-group-divider": b }, C = n.forwardRef(function({ children: o, value: c, className: u, onChange: d, disabled: s = !1, ...f }, m) {
5
+ import { Button as v } from "../button/button.js";
6
+ import '../../../select_group.css';const x = "_select-group_c24986f", y = "_select-group-option_28f4dfd", b = "_select-group-divider_b5b865b", a = { "select-group": x, "select-group-option": y, "select-group-divider": b }, C = n.forwardRef(function({ children: o, value: c, className: u, onChange: d, disabled: t = !1, ...f }, m) {
7
7
  const g = Array.isArray(o) ? o : [o], h = (e, p) => {
8
- if (s) return;
8
+ if (t) return;
9
9
  const r = [...c];
10
10
  if (p) {
11
- const t = c.indexOf(e);
12
- t > -1 && r.splice(t, 1);
11
+ const s = c.indexOf(e);
12
+ s > -1 && r.splice(s, 1);
13
13
  } else
14
14
  r.push(e);
15
15
  d?.(r);
16
16
  };
17
17
  return /* @__PURE__ */ i(
18
- v,
18
+ _,
19
19
  {
20
20
  ref: m,
21
21
  as: "div",
22
22
  inline: !0,
23
23
  width: "auto",
24
24
  height: "auto",
25
- "data-is-disabled": s,
25
+ "data-is-disabled": t,
26
26
  className: l(a["select-group"], "select-group", u),
27
27
  ...f,
28
28
  children: g.map((e, p) => {
29
- const r = c.includes(e.props.value), t = () => {
29
+ const r = c.includes(e.props.value), s = () => {
30
30
  h(e.props.value, r);
31
31
  };
32
32
  return /* @__PURE__ */ i(n.Fragment, { children: /* @__PURE__ */ i(
33
- x,
33
+ v,
34
34
  {
35
- disabled: s || e.props.disabled,
36
- "data-is-disabled": s || e.props.disabled,
35
+ disabled: t || e.props.disabled,
36
+ "data-is-disabled": t || e.props.disabled,
37
37
  className: l(a["select-group-option"], "select-group-option"),
38
38
  hierarchy: r ? "primary" : "secondary",
39
- onClick: t,
39
+ onClick: s,
40
40
  value: e.props.value,
41
41
  children: e.props.children
42
42
  }
@@ -1,14 +1,14 @@
1
1
  import { jsx as p } from "react/jsx-runtime";
2
2
  import h from "react";
3
3
  import { SelectGroup as m } from "./select_group.js";
4
- const G = h.forwardRef(function({
4
+ const s = h.forwardRef(function({
5
5
  children: t,
6
6
  value: n,
7
7
  className: o,
8
8
  onChange: r,
9
9
  disabled: l = !1,
10
- ...c
11
- }, f) {
10
+ ...f
11
+ }, c) {
12
12
  const g = (e) => {
13
13
  if (e.length === 0)
14
14
  return;
@@ -18,17 +18,17 @@ const G = h.forwardRef(function({
18
18
  return /* @__PURE__ */ p(
19
19
  m,
20
20
  {
21
- ref: f,
21
+ ref: c,
22
22
  value: n != null ? [n] : [],
23
23
  onChange: g,
24
24
  disabled: l,
25
25
  className: o,
26
- ...c,
26
+ ...f,
27
27
  children: t
28
28
  }
29
29
  );
30
30
  });
31
31
  export {
32
- G as SingleSelectGroup
32
+ s as SingleSelectGroup
33
33
  };
34
34
  //# sourceMappingURL=single_select_group.js.map
@@ -2,12 +2,12 @@ import { jsx as r } from "react/jsx-runtime";
2
2
  import n from "react";
3
3
  import { Button as i } from "../button/button.js";
4
4
  import { clsx as l } from "clsx";
5
- import '../../../slim_button.css';const c = "_slim-button_188fdc3", u = { "slim-button": c }, b = n.forwardRef(
5
+ import '../../../slim_button.css';const u = "_slim-button_188fdc3", c = { "slim-button": u }, b = n.forwardRef(
6
6
  ({ children: t, className: o, ...m }, s) => /* @__PURE__ */ r(
7
7
  i,
8
8
  {
9
9
  ref: s,
10
- className: l(u["slim-button"], "tcn-slim-button", o),
10
+ className: l(c["slim-button"], "tcn-slim-button", o),
11
11
  ...m,
12
12
  children: t
13
13
  }
@@ -0,0 +1,2 @@
1
+ export type ActionSeverity = 'dangerous' | 'cautious' | 'neutral' | 'suggested' | 'encouraged';
2
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/actions/types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,cAAc,GACtB,WAAW,GACX,UAAU,GACV,SAAS,GACT,WAAW,GACX,YAAY,CAAC"}
@@ -0,0 +1,2 @@
1
+
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,34 +1,34 @@
1
1
  import { jsx as c } from "react/jsx-runtime";
2
2
  import M from "react";
3
- import '../../loading.css';const p = "_loading-line_e364229", y = "_linePulse_bde300c", f = { "loading-line": p, linePulse: y }, I = M.forwardRef(
3
+ import '../../loading.css';const f = "_loading-line_e364229", p = "_linePulse_bde300c", u = { "loading-line": f, linePulse: p }, I = M.forwardRef(
4
4
  ({
5
- size: e = "1em",
5
+ size: s = "1em",
6
6
  color: l = "var(--accent-color)",
7
- lineCount: a = 12,
7
+ lineCount: n = 12,
8
8
  animationDuration: t = 1200,
9
9
  className: r,
10
10
  style: h
11
- }, v) => {
12
- const d = Array.from({ length: a }), g = 360 / a;
11
+ }, d) => {
12
+ const v = Array.from({ length: n }), g = 360 / n;
13
13
  return /* @__PURE__ */ c(
14
14
  "svg",
15
15
  {
16
- ref: v,
16
+ ref: d,
17
17
  width: 50,
18
18
  height: 50,
19
19
  viewBox: "0 0 50 50",
20
20
  className: r,
21
21
  xmlns: "http://www.w3.org/2000/svg",
22
- style: { height: e, width: e, ...h },
22
+ style: { height: s, width: s, ...h },
23
23
  fill: "none",
24
- children: d.map((x, s) => {
25
- const n = g * s, i = 50 / 4.5, o = 50 / 2.25, m = 50 / 2 + i * Math.cos(n * Math.PI / 180), S = 50 / 2 + i * Math.sin(n * Math.PI / 180), z = 50 / 2 + o * Math.cos(n * Math.PI / 180), w = 50 / 2 + o * Math.sin(n * Math.PI / 180);
24
+ children: v.map((_, e) => {
25
+ const a = g * e, i = 50 / 4.5, o = 50 / 2.25, m = 50 / 2 + i * Math.cos(a * Math.PI / 180), S = 50 / 2 + i * Math.sin(a * Math.PI / 180), z = 50 / 2 + o * Math.cos(a * Math.PI / 180), w = 50 / 2 + o * Math.sin(a * Math.PI / 180);
26
26
  return /* @__PURE__ */ c(
27
27
  "line",
28
28
  {
29
- className: f["loading-line"],
29
+ className: u["loading-line"],
30
30
  style: {
31
- animationDelay: `${s * t / a}ms`,
31
+ animationDelay: `${e * t / n}ms`,
32
32
  animationDuration: `${t}ms`
33
33
  },
34
34
  x1: m,
@@ -39,7 +39,7 @@ import '../../loading.css';const p = "_loading-line_e364229", y = "_linePulse_bd
39
39
  strokeWidth: 3,
40
40
  strokeLinecap: "round"
41
41
  },
42
- s
42
+ e
43
43
  );
44
44
  })
45
45
  }
@@ -1 +1 @@
1
- {"version":3,"file":"loading.js","sources":["../../../src/feedback/loading/loading.tsx"],"sourcesContent":["import React, { CSSProperties } from 'react';\nimport styles from './loading.module.css';\n\nexport interface LoadingProps {\n size?: string;\n color?: string;\n lineCount?: number;\n animationDuration?: number;\n className?: string;\n style?: CSSProperties;\n}\n\nexport const Loading = React.forwardRef(\n (\n {\n size = '1em',\n color = 'var(--accent-color)',\n lineCount = 12,\n animationDuration = 1200,\n className,\n style,\n }: LoadingProps,\n ref: React.Ref<SVGSVGElement>\n ) => {\n const canvasSize = 50;\n const lines = Array.from({ length: lineCount });\n const angleStep = 360 / lineCount;\n\n return (\n <svg\n ref={ref}\n width={canvasSize}\n height={canvasSize}\n viewBox={`0 0 ${canvasSize} ${canvasSize}`}\n className={className}\n xmlns=\"http://www.w3.org/2000/svg\"\n style={{ height: size, width: size, ...style }}\n fill=\"none\"\n >\n {lines.map((_, i) => {\n const angle = angleStep * i;\n const innerRadius = canvasSize / 4.5;\n const outerRadius = canvasSize / 2.25;\n\n const x1 = canvasSize / 2 + innerRadius * Math.cos((angle * Math.PI) / 180);\n const y1 = canvasSize / 2 + innerRadius * Math.sin((angle * Math.PI) / 180);\n const x2 = canvasSize / 2 + outerRadius * Math.cos((angle * Math.PI) / 180);\n const y2 = canvasSize / 2 + outerRadius * Math.sin((angle * Math.PI) / 180);\n\n return (\n <line\n className={styles['loading-line']}\n style={{\n animationDelay: `${(i * animationDuration) / lineCount}ms`,\n animationDuration: `${animationDuration}ms`,\n }}\n key={i}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n stroke={color}\n strokeWidth={3}\n strokeLinecap=\"round\"\n />\n );\n })}\n </svg>\n );\n }\n);\n"],"names":["Loading","React","size","color","lineCount","animationDuration","className","style","ref","lines","angleStep","jsx","_","i","angle","innerRadius","outerRadius","x1","y1","x2","y2","styles"],"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eAAc;AAAA,YAAA;AAAA,YAPTU;AAAA,UAAA;AAAA,QAUX,CAAC;AAAA,MAAA;AAAA,IAAA;AAAA,EAGP;AACF;"}
1
+ {"version":3,"file":"loading.js","sources":["../../../src/feedback/loading/loading.tsx"],"sourcesContent":["import React, { CSSProperties } from 'react';\nimport styles from './loading.module.css';\n\nexport interface LoadingProps {\n size?: string;\n color?: string;\n lineCount?: number;\n animationDuration?: number;\n className?: string;\n style?: CSSProperties;\n}\n\nexport const Loading = React.forwardRef(\n (\n {\n size = '1em',\n color = 'var(--accent-color)',\n lineCount = 12,\n animationDuration = 1200,\n className,\n style,\n }: LoadingProps,\n ref: React.Ref<SVGSVGElement>\n ) => {\n const canvasSize = 50;\n const lines = Array.from({ length: lineCount });\n const angleStep = 360 / lineCount;\n\n return (\n <svg\n ref={ref}\n width={canvasSize}\n height={canvasSize}\n viewBox={`0 0 ${canvasSize} ${canvasSize}`}\n className={className}\n xmlns=\"http://www.w3.org/2000/svg\"\n style={{ height: size, width: size, ...style }}\n fill=\"none\"\n >\n {lines.map((_, i) => {\n const angle = angleStep * i;\n const innerRadius = canvasSize / 4.5;\n const outerRadius = canvasSize / 2.25;\n\n const x1 = canvasSize / 2 + innerRadius * Math.cos((angle * Math.PI) / 180);\n const y1 = canvasSize / 2 + innerRadius * Math.sin((angle * Math.PI) / 180);\n const x2 = canvasSize / 2 + outerRadius * Math.cos((angle * Math.PI) / 180);\n const y2 = canvasSize / 2 + outerRadius * Math.sin((angle * Math.PI) / 180);\n\n return (\n <line\n className={styles['loading-line']}\n style={{\n animationDelay: `${(i * animationDuration) / lineCount}ms`,\n animationDuration: `${animationDuration}ms`,\n }}\n key={i}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n stroke={color}\n strokeWidth={3}\n strokeLinecap=\"round\"\n />\n );\n })}\n </svg>\n );\n }\n);\n"],"names":["Loading","React","size","color","lineCount","animationDuration","className","style","ref","lines","angleStep","jsx","i","angle","innerRadius","outerRadius","x1","y1","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;AAAA,cACb,eAAc;AAAA,YAAA;AAAA,YAPTS;AAAA,UAAA;AAAA,QAUX,CAAC;AAAA,MAAA;AAAA,IAAA;AAAA,EAGP;AACF;"}
@@ -12,7 +12,7 @@ import { HStack as l } from "../../stacks/h_stack.js";
12
12
  import { Spacer as a } from "../../stacks/spacer.js";
13
13
  import { VStack as d } from "../../stacks/v_stack.js";
14
14
  import { ZStack as b } from "../../stacks/z_stack.js";
15
- import '../../progress_bar.css';const f = "_progress-bar-container_014b4d9", h = "_progress-bar-background_9176cc0", _ = "_progress-bar_057c33d", k = "_progress-bar-fill_00854f0", x = "_moveStripes_d219e85", s = { "progress-bar-container": f, "progress-bar-background": h, "progress-bar": _, "progress-bar-fill": k, moveStripes: x }, H = m.forwardRef(function({ message: i, value: p, ...c }, n) {
15
+ import '../../progress_bar.css';const f = "_progress-bar-container_014b4d9", h = "_progress-bar-background_9176cc0", _ = "_progress-bar_057c33d", k = "_progress-bar-fill_00854f0", u = "_moveStripes_d219e85", s = { "progress-bar-container": f, "progress-bar-background": h, "progress-bar": _, "progress-bar-fill": k, moveStripes: u }, H = m.forwardRef(function({ message: i, value: p, ...c }, n) {
16
16
  const o = `${(p * 100).toFixed(0)}%`, g = { "--progress-percentage": o };
17
17
  return /* @__PURE__ */ e(d, { ref: n, className: s["progress-bar-container"], ...c, children: [
18
18
  /* @__PURE__ */ e(l, { height: "auto", vAlign: "end", children: [
@@ -1,20 +1,20 @@
1
- import { jsxs as d, jsx as a } from "react/jsx-runtime";
2
- import c from "react";
3
- import { VStack as f } from "../../../../stacks/v_stack.js";
1
+ import { jsxs as n, jsx as a } from "react/jsx-runtime";
2
+ import f from "react";
3
+ import { VStack as c } from "../../../../stacks/v_stack.js";
4
4
  import { clsx as s } from "clsx";
5
5
  import { FieldErrorMessage as m } from "../field_error.js";
6
- import '../../../../field_control.css';const h = "_field-error_44124ee", p = "_field-control_ca50e63", x = { "field-error": h, "field-control": p }, k = c.forwardRef(function({
6
+ import '../../../../field_control.css';const h = "_field-error_44124ee", p = "_field-control_ca50e63", x = { "field-error": h, "field-control": p }, k = f.forwardRef(function({
7
7
  children: o,
8
8
  errorMessage: r,
9
9
  locked: e = !1,
10
10
  loading: l = !1,
11
11
  className: t,
12
12
  ...i
13
- }, n) {
14
- return /* @__PURE__ */ d(
15
- f,
13
+ }, d) {
14
+ return /* @__PURE__ */ n(
15
+ c,
16
16
  {
17
- ref: n,
17
+ ref: d,
18
18
  "data-locked": e,
19
19
  "data-loading": l,
20
20
  "data-error": !!r,
@@ -8,14 +8,14 @@ import "../../../../feedback/progress/progress_bar.js";
8
8
  import "@tcn/state";
9
9
  import "../../../../stacks/v_stack.js";
10
10
  import { clsx as o } from "clsx";
11
- import '../../../../status_input.css';const A = "_field-error_6d015c9", x = "_field-status-input_c30d6fb", n = { "field-error": A, "field-status-input": x }, h = () => /* @__PURE__ */ r(f, { className: "field-lock", size: "lg" }), k = () => /* @__PURE__ */ r(g, { size: "20px", className: "field-loader" }), I = () => /* @__PURE__ */ r(u, { className: o(n["field-error"], "field-error"), size: "lg" }), w = ({ state: e }) => {
11
+ import '../../../../status_input.css';const A = "_field-error_6d015c9", x = "_field-status-input_c30d6fb", n = { "field-error": A, "field-status-input": x }, _ = () => /* @__PURE__ */ r(f, { className: "field-lock", size: "lg" }), h = () => /* @__PURE__ */ r(g, { size: "20px", className: "field-loader" }), k = () => /* @__PURE__ */ r(u, { className: o(n["field-error"], "field-error"), size: "lg" }), I = ({ state: e }) => {
12
12
  switch (e) {
13
13
  case "locked":
14
- return /* @__PURE__ */ r(h, {});
14
+ return /* @__PURE__ */ r(_, {});
15
15
  case "loading":
16
- return /* @__PURE__ */ r(k, {});
16
+ return /* @__PURE__ */ r(h, {});
17
17
  case "error":
18
- return /* @__PURE__ */ r(I, {});
18
+ return /* @__PURE__ */ r(k, {});
19
19
  default:
20
20
  return null;
21
21
  }
@@ -38,13 +38,13 @@ import '../../../../status_input.css';const A = "_field-error_6d015c9", x = "_fi
38
38
  ...l,
39
39
  children: [
40
40
  a && i,
41
- /* @__PURE__ */ r(w, { state: t })
41
+ /* @__PURE__ */ r(I, { state: t })
42
42
  ]
43
43
  }
44
44
  );
45
45
  });
46
46
  export {
47
- w as AdornmentMap,
47
+ I as AdornmentMap,
48
48
  v as FieldStatusInput
49
49
  };
50
50
  //# sourceMappingURL=status_input.js.map
@@ -7,13 +7,13 @@ import "../../utils/focus_redirect.js";
7
7
  import "../../utils/scroll_away_listener.js";
8
8
  import { useForkRef as l } from "../../utils/hooks/use_fork_ref.js";
9
9
  import { useResizeObserver as p } from "../../utils/hooks/use_resize_observer.js";
10
- const H = c.forwardRef(function({ children: t, breakpointPixels: i = 500, ...e }, m) {
11
- const [f, n] = u(!0), s = p((d) => {
10
+ const z = c.forwardRef(function({ children: t, breakpointPixels: i = 500, ...e }, f) {
11
+ const [m, n] = u(!0), s = p((d) => {
12
12
  n(d >= i);
13
- }), o = l(m, s);
14
- return /* @__PURE__ */ r(a, { children: f ? /* @__PURE__ */ r(F, { ...e, ref: o, ...e, children: t }) : /* @__PURE__ */ r(R, { ...e, ref: o, ...e, children: t }) });
13
+ }), o = l(f, s);
14
+ return /* @__PURE__ */ r(a, { children: m ? /* @__PURE__ */ r(F, { ...e, ref: o, ...e, children: t }) : /* @__PURE__ */ r(R, { ...e, ref: o, ...e, children: t }) });
15
15
  });
16
16
  export {
17
- H as Field
17
+ z as Field
18
18
  };
19
19
  //# sourceMappingURL=field.js.map
@@ -1,13 +1,13 @@
1
1
  import { jsxs as F, jsx as r } from "react/jsx-runtime";
2
2
  import { HStack as I } from "../../../stacks/h_stack.js";
3
3
  import { clsx as H } from "clsx";
4
- import g, { useState as y } from "react";
5
- import { FieldHeader as S } from "../common/field_header.js";
6
- import { FieldControl as $ } from "../common/field_control/field_control.js";
7
- import { FieldStatusInput as j } from "../common/status_input/status_input.js";
8
- import '../../../h_field.css';const v = "_h-field_845b93f", w = { "h-field": v };
9
- let A = 0;
10
- const B = g.forwardRef(function({
4
+ import _, { useState as g } from "react";
5
+ import { FieldHeader as y } from "../common/field_header.js";
6
+ import { FieldControl as S } from "../common/field_control/field_control.js";
7
+ import { FieldStatusInput as $ } from "../common/status_input/status_input.js";
8
+ import '../../../h_field.css';const j = "_h-field_845b93f", v = { "h-field": j };
9
+ let w = 0;
10
+ const B = _.forwardRef(function({
11
11
  label: o,
12
12
  description: s,
13
13
  errorMessage: d,
@@ -20,7 +20,7 @@ const B = g.forwardRef(function({
20
20
  required: m,
21
21
  ...h
22
22
  }, p) {
23
- const [i] = y(() => c || `h-field-${A++}`), u = `${i}-label`, b = `${i}-description`, a = !!d, x = t ? "locked" : e ? "loading" : a ? "error" : "default";
23
+ const [i] = g(() => c || `h-field-${w++}`), u = `${i}-label`, b = `${i}-description`, a = !!d, x = t ? "locked" : e ? "loading" : a ? "error" : "default";
24
24
  return /* @__PURE__ */ F(
25
25
  I,
26
26
  {
@@ -31,7 +31,7 @@ const B = g.forwardRef(function({
31
31
  "data-locked": t,
32
32
  "data-error": a,
33
33
  "data-loading": e,
34
- className: H("base-field", w["h-field"], "h-field", f),
34
+ className: H("base-field", v["h-field"], "h-field", f),
35
35
  vAlign: "start",
36
36
  hAlign: "start",
37
37
  height: "auto",
@@ -39,7 +39,7 @@ const B = g.forwardRef(function({
39
39
  ...h,
40
40
  children: [
41
41
  /* @__PURE__ */ r(
42
- S,
42
+ y,
43
43
  {
44
44
  minWidth: l,
45
45
  width: l,
@@ -49,7 +49,7 @@ const B = g.forwardRef(function({
49
49
  required: m
50
50
  }
51
51
  ),
52
- /* @__PURE__ */ r($, { errorMessage: d, loading: e, locked: t, children: /* @__PURE__ */ r(j, { state: x, children: n }) })
52
+ /* @__PURE__ */ r(S, { errorMessage: d, loading: e, locked: t, children: /* @__PURE__ */ r($, { state: x, children: n }) })
53
53
  ]
54
54
  }
55
55
  );
@@ -7,21 +7,21 @@ import { FieldHeader as y } from "../common/field_header.js";
7
7
  import { FieldStatusInput as S } from "../common/status_input/status_input.js";
8
8
  import '../../../v_field.css';const V = {};
9
9
  let $ = 0;
10
- const z = F.forwardRef(function({
10
+ const q = F.forwardRef(function({
11
11
  label: d,
12
12
  description: o,
13
13
  errorMessage: a,
14
14
  children: s,
15
15
  locked: t = !1,
16
- loading: r = !1,
16
+ loading: e = !1,
17
17
  maxWidth: R,
18
18
  minWidth: W,
19
19
  className: n,
20
- id: c,
21
- required: f,
20
+ id: f,
21
+ required: c,
22
22
  ...m
23
23
  }, p) {
24
- const [e] = I(() => c || `v-field-${$++}`), l = !!a, h = `${e}-label`, u = `${e}-description`, b = t ? "locked" : r ? "loading" : l ? "error" : "default";
24
+ const [r] = I(() => f || `v-field-${$++}`), l = !!a, h = `${r}-label`, u = `${r}-description`, b = t ? "locked" : e ? "loading" : l ? "error" : "default";
25
25
  return /* @__PURE__ */ x(
26
26
  g,
27
27
  {
@@ -31,7 +31,7 @@ const z = F.forwardRef(function({
31
31
  "aria-describedby": u,
32
32
  "data-locked": t,
33
33
  "data-error": l,
34
- "data-loading": r,
34
+ "data-loading": e,
35
35
  className: v("base-field", V["v-field"], "v-field", n),
36
36
  vAlign: "start",
37
37
  hAlign: "start",
@@ -42,17 +42,17 @@ const z = F.forwardRef(function({
42
42
  /* @__PURE__ */ i(
43
43
  y,
44
44
  {
45
- id: e,
45
+ id: r,
46
46
  label: d,
47
47
  description: o,
48
- required: f
48
+ required: c
49
49
  }
50
50
  ),
51
51
  /* @__PURE__ */ i(
52
52
  A,
53
53
  {
54
54
  errorMessage: a,
55
- loading: r,
55
+ loading: e,
56
56
  locked: t,
57
57
  hAlign: "start",
58
58
  children: /* @__PURE__ */ i(S, { state: b, hAlign: "start", children: s })
@@ -63,6 +63,6 @@ const z = F.forwardRef(function({
63
63
  );
64
64
  });
65
65
  export {
66
- z as VField
66
+ q as VField
67
67
  };
68
68
  //# sourceMappingURL=v_field.js.map
@@ -11,8 +11,8 @@ import { HStack as b } from "../../stacks/h_stack.js";
11
11
  import { Spacer as f } from "../../stacks/spacer.js";
12
12
  import { VStack as m } from "../../stacks/v_stack.js";
13
13
  import y, { useMemo as S } from "react";
14
- import '../../field_set.css';const x = "_field-set_8e981d9", g = "_field-set-body_4cd3139", c = { "field-set": x, "field-set-body": g };
15
- let u = 0;
14
+ import '../../field_set.css';const u = "_field-set_8e981d9", x = "_field-set-body_4cd3139", c = { "field-set": u, "field-set-body": x };
15
+ let _ = 0;
16
16
  const q = y.forwardRef(function({
17
17
  legend: l,
18
18
  startAdornments: d,
@@ -21,7 +21,7 @@ const q = y.forwardRef(function({
21
21
  children: n,
22
22
  ...t
23
23
  }, p) {
24
- const s = `field-set-${S(() => u++, [])}`;
24
+ const s = `field-set-${S(() => _++, [])}`;
25
25
  return /* @__PURE__ */ r(
26
26
  m,
27
27
  {
@@ -0,0 +1,6 @@
1
+ import { _ as a, d as i, r as m } from "./showcase-WfP6kBEb.js";
2
+ var t = a(m(), 1), f = (0, t.default)(2)(async (e, r) => e === !1 ? r : i(r));
3
+ export {
4
+ f as formatter
5
+ };
6
+ //# sourceMappingURL=formatter-QJ4M4OGQ-DaIl2Wi_.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"formatter-QJ4M4OGQ-DaIl2Wi_.js","sources":["../../../node_modules/.pnpm/storybook@10.1.11_@testing-library+dom@10.4.1_prettier@2.8.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/storybook/dist/_browser-chunks/formatter-QJ4M4OGQ.js"],"sourcesContent":["import {\n require_memoizerific\n} from \"./chunk-WJYERY3R.js\";\nimport {\n dedent\n} from \"./chunk-JP7NCOJX.js\";\nimport {\n __toESM\n} from \"./chunk-A242L54C.js\";\n\n// src/components/components/syntaxhighlighter/formatter.ts\nvar import_memoizerific = __toESM(require_memoizerific(), 1);\nvar formatter = (0, import_memoizerific.default)(2)(async (type, source) => type === !1 ? source : dedent(source));\nexport {\n formatter\n};\n"],"names":["import_memoizerific","__toESM","require_memoizerific","formatter","type","source","dedent"],"mappings":";AAWA,IAAIA,IAAsBC,EAAQC,EAAoB,GAAI,CAAC,GACvDC,QAAgBH,EAAoB,SAAS,CAAC,EAAE,OAAOI,GAAMC,MAAWD,MAAS,KAAKC,IAASC,EAAOD,CAAM,CAAC;","x_google_ignoreList":[0]}
@@ -0,0 +1 @@
1
+ ._container_932284e{display:grid;grid-template-columns:repeat(auto-fit,minmax(var(--min-column-width),1fr));gap:20px;max-width:var(--max-gallery-width)}
@@ -1,34 +1,34 @@
1
1
  import { jsx as x } from "react/jsx-runtime";
2
- import { clsx as i } from "clsx";
3
- import d from "react";
4
- import '../../checkbox.css';const f = "_checkbox_cb77818", h = { checkbox: f }, y = d.forwardRef(function({
2
+ import { clsx as d } from "clsx";
3
+ import f from "react";
4
+ import '../../checkbox.css';const i = "_checkbox_cb77818", l = { checkbox: i }, _ = f.forwardRef(function({
5
5
  style: a,
6
6
  className: r,
7
7
  width: s,
8
8
  height: b,
9
- checked: c,
10
- inputRef: l,
11
- onChange: e,
9
+ checked: e,
10
+ inputRef: k,
11
+ onChange: c,
12
12
  ...o
13
13
  }, n) {
14
14
  return /* @__PURE__ */ x(
15
15
  "input",
16
16
  {
17
17
  ref: n,
18
- "data-checked": c,
18
+ "data-checked": e,
19
19
  "data-is-disabled": o.disabled || !1,
20
- checked: c,
20
+ checked: e,
21
21
  type: "checkbox",
22
22
  onChange: (t) => {
23
- e && e(!!t.currentTarget.checked, t);
23
+ c && c(!!t.currentTarget.checked, t);
24
24
  },
25
25
  ...o,
26
- className: i(r, h.checkbox, "checkbox"),
26
+ className: d(r, l.checkbox, "checkbox"),
27
27
  style: { width: s, height: b, ...a }
28
28
  }
29
29
  );
30
30
  });
31
31
  export {
32
- y as Checkbox
32
+ _ as Checkbox
33
33
  };
34
34
  //# sourceMappingURL=checkbox.js.map
@@ -7,23 +7,23 @@ import { useForkRef as k } from "../../utils/hooks/use_fork_ref.js";
7
7
  import "../../utils/hooks/use_resize_observer.js";
8
8
  import { ZStack as l } from "../../stacks/z_stack.js";
9
9
  import { clsx as u } from "clsx";
10
- import { ChromePicker as h } from "react-color";
11
- import '../../color_picker.css';const d = "_color-picker_4757d5a", R = "_chrome-picker_2f64060", e = { "color-picker": d, "chrome-picker": R }, F = s.forwardRef(function({ color: c, onColorChange: t, className: i, ...m }, p) {
12
- const r = n(null), f = k(r, p);
10
+ import { ChromePicker as d } from "react-color";
11
+ import '../../color_picker.css';const h = "_color-picker_4757d5a", R = "_chrome-picker_2f64060", e = { "color-picker": h, "chrome-picker": R }, F = s.forwardRef(function({ color: c, onColorChange: t, className: i, ...m }, f) {
12
+ const r = n(null), p = k(r, f);
13
13
  return a(() => {
14
14
  r.current && r.current.focus();
15
15
  }, []), /* @__PURE__ */ o(
16
16
  l,
17
17
  {
18
18
  tabIndex: 0,
19
- ref: f,
19
+ ref: p,
20
20
  padding: "8px",
21
21
  height: "auto",
22
22
  width: "auto",
23
23
  className: u(e["color-picker"], i),
24
24
  ...m,
25
25
  children: /* @__PURE__ */ o(
26
- h,
26
+ d,
27
27
  {
28
28
  className: e["chrome-picker"],
29
29
  color: c,
@@ -1,14 +1,14 @@
1
- import { jsxs as D, Fragment as L, jsx as S } from "react/jsx-runtime";
1
+ import { jsxs as w, Fragment as D, jsx as S } from "react/jsx-runtime";
2
2
  import "../../utils/click_away_listener.js";
3
3
  import "../../utils/focus_redirect.js";
4
4
  import "../../utils/scroll_away_listener.js";
5
- import N, { useRef as s, useState as x } from "react";
6
- import { useForkRef as V } from "../../utils/hooks/use_fork_ref.js";
5
+ import L, { useRef as s, useState as x } from "react";
6
+ import { useForkRef as N } from "../../utils/hooks/use_fork_ref.js";
7
7
  import "../../utils/hooks/use_resize_observer.js";
8
- import { clsx as z } from "clsx";
9
- import { SuggestionList as G } from "../suggestions/suggestion_list.js";
10
- import { Input as H } from "../input/input.js";
11
- const ee = N.forwardRef(function({
8
+ import { clsx as V } from "clsx";
9
+ import { SuggestionList as z } from "../suggestions/suggestion_list.js";
10
+ import { Input as G } from "../input/input.js";
11
+ const ee = L.forwardRef(function({
12
12
  onOptionSelect: a,
13
13
  children: C = [],
14
14
  onKeyDown: o,
@@ -21,18 +21,18 @@ const ee = N.forwardRef(function({
21
21
  onMouseUp: g,
22
22
  ...i
23
23
  }, y) {
24
- const A = s(!1), d = s(c), n = s(!1), [E, F] = x(null), f = s(null), [h, R] = x(!1), T = V(y, f);
24
+ const A = s(!1), d = s(c), n = s(!1), [E, F] = x(null), f = s(null), [h, R] = x(!1), T = N(y, f);
25
25
  function l() {
26
26
  R(!0);
27
27
  }
28
28
  function r() {
29
29
  n.current = !1, R(!1);
30
30
  }
31
- function I(e, t, w) {
31
+ function I(e, t, q) {
32
32
  n.current = !0;
33
33
  const u = f.current;
34
34
  requestAnimationFrame(() => {
35
- u != null && (u.value = e, u.focus(), u.setSelectionRange(t, w));
35
+ u != null && (u.value = e, u.focus(), u.setSelectionRange(t, q));
36
36
  }), i.onChange && i.onChange(e), r();
37
37
  }
38
38
  function M(e) {
@@ -53,25 +53,25 @@ const ee = N.forwardRef(function({
53
53
  function U(e) {
54
54
  F(e.currentTarget), A.current = document.activeElement === e.currentTarget, p && p(e);
55
55
  }
56
- function q(e) {
56
+ function _(e) {
57
57
  n.current && (n.current = !1, r()), l(), g && g(e);
58
58
  }
59
- return /* @__PURE__ */ D(L, { children: [
59
+ return /* @__PURE__ */ w(D, { children: [
60
60
  /* @__PURE__ */ S(
61
- H,
61
+ G,
62
62
  {
63
63
  ref: T,
64
- className: z(b, "combo-box-input"),
64
+ className: V(b, "combo-box-input"),
65
65
  ...i,
66
66
  value: c,
67
67
  onKeyDown: j,
68
68
  onKeyUp: B,
69
69
  onMouseDown: U,
70
- onMouseUp: q
70
+ onMouseUp: _
71
71
  }
72
72
  ),
73
73
  h && /* @__PURE__ */ S(
74
- G,
74
+ z,
75
75
  {
76
76
  anchorElement: E,
77
77
  onClose: I,