@stenajs-webui/core 21.32.1 → 21.33.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,6 +8,8 @@ export interface TextProps extends SpanProps {
8
8
  whiteSpace?: Property.WhiteSpace;
9
9
  wordBreak?: Property.WordBreak;
10
10
  textAlign?: Property.TextAlign;
11
+ overflow?: Property.Overflow;
12
+ textOverflow?: Property.TextOverflow;
11
13
  color?: string;
12
14
  }
13
15
  export type TextVariant = "standard" | "caption" | "overline" | "bold";
package/dist/index.es.js CHANGED
@@ -1,11 +1,11 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode("._separatorLine_nzfcz_1{display:flex;border:0;margin:0;flex:none}._visuallyHidden_1gevf_1{border:0;clip:rect(0 0 0 0);height:1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}._text_1iisw_1{--swui-text-color: var(--swui-text-primary-color);--swui-text-color-caption: var(--lhds-color-ui-600);--swui-text-color-overline: var(--lhds-color-ui-600);--swui-text-font-family: var(--swui-font-primary);--swui-text-font-weight: var(--swui-font-weight-text);--current-color: var(--swui-text-color);--current-font-size: var(--swui-font-size-medium);--current-line-height: var(--swui-line-height-medium);--current-font-weight: var(--swui-text-font-weight);--current-letter-spacing: var(--swui-text-letter-spacing);font-size:var(--current-font-size);line-height:var(--current-line-height);color:var(--current-color);letter-spacing:var(--current-letter-spacing);font-family:var(--swui-text-font-family);font-weight:var(--current-font-weight)}._text_1iisw_1._bold_1iisw_27{--current-font-weight: var(--swui-font-weight-text-bold)}._text_1iisw_1._caption_1iisw_31{--current-font-size: var(--swui-font-size-small);--current-line-height: var(--swui-line-height-small);--current-color: var(--swui-text-color-caption);--current-letter-spacing: 0;font-style:italic}._text_1iisw_1._overline_1iisw_39{--current-font-size: var(--swui-font-size-smaller);--current-line-height: var(--swui-line-height-smaller);--current-color: var(--swui-text-color-overline);--current-font-weight: var(--swui-font-weight-text-bold);--current-letter-spacing: .1rem;text-transform:uppercase}._text_1iisw_1._large_1iisw_48{--current-font-size: var(--swui-font-size-large);--current-line-height: var(--swui-line-height-large)}._text_1iisw_1._medium_1iisw_53{--current-font-size: var(--swui-font-size-medium);--current-line-height: var(--swui-line-height-medium)}._text_1iisw_1._small_1iisw_58{--current-font-size: var(--swui-font-size-small);--current-line-height: var(--swui-line-height-small)}._text_1iisw_1._smaller_1iisw_63{--current-font-size: var(--swui-font-size-smaller);--current-line-height: var(--swui-line-height-smaller)}._heading_1cnsg_1{font-size:2rem;color:var(--swui-text-primary-color);letter-spacing:0;margin:0;line-height:var(--swui-line-height);font-family:var(--swui-font-primary);font-weight:var(--swui-font-weight-text-bold)}._heading_1cnsg_1._h1_1cnsg_10{font-size:2.8rem}._heading_1cnsg_1._h2_1cnsg_14{font-size:2.4rem}._heading_1cnsg_1._h3_1cnsg_18{font-size:2rem}._heading_1cnsg_1._h4_1cnsg_22{font-size:1.8rem}._heading_1cnsg_1._h5_1cnsg_26{font-size:1.6rem}._heading_1cnsg_1._h6_1cnsg_30{font-size:1.4rem}")),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}})();
2
2
  import { cssColor as D } from "@stenajs-webui/theme";
3
- import { jsx as a, Fragment as S } from "react/jsx-runtime";
4
- import H, { forwardRef as h, useState as y, useCallback as m, useLayoutEffect as R, useRef as g, useEffect as d, useMemo as L } from "react";
5
- import _ from "@emotion/styled";
3
+ import { jsx as a, Fragment as T } from "react/jsx-runtime";
4
+ import H, { forwardRef as h, useState as y, useCallback as m, useLayoutEffect as M, useRef as g, useEffect as d, useMemo as O } from "react";
5
+ import S from "@emotion/styled";
6
6
  import { system as z, background as F, border as N, borderRight as U, borderLeft as V, borderTop as q, borderBottom as j, borderColor as B, borderRadius as W, borderStyle as X, borderWidth as G, boxShadow as Y, flexbox as K, overflow as Z, position as J, layout as Q, zIndex as ee, left as te, right as re, top as ue, bottom as ne } from "styled-system";
7
7
  import { memoize as oe, pickBy as se, debounce as ie } from "lodash-es";
8
- import M from "classnames";
8
+ import A from "classnames";
9
9
  const ae = "_separatorLine_nzfcz_1", ce = {
10
10
  separatorLine: ae
11
11
  }, rt = h(
@@ -28,7 +28,7 @@ const ae = "_separatorLine_nzfcz_1", ce = {
28
28
  ref: n
29
29
  }
30
30
  )
31
- ), le = _.button`
31
+ ), le = S.button`
32
32
  display: inline-block;
33
33
  user-select: none;
34
34
  border: 0;
@@ -65,8 +65,8 @@ const ae = "_separatorLine_nzfcz_1", ce = {
65
65
  background: l = "transparent",
66
66
  hoverBackground: p,
67
67
  focusBackground: f,
68
- type: O = "button",
69
- ...A
68
+ type: k = "button",
69
+ ..._
70
70
  }, P) => /* @__PURE__ */ a(
71
71
  le,
72
72
  {
@@ -82,15 +82,15 @@ const ae = "_separatorLine_nzfcz_1", ce = {
82
82
  background: l,
83
83
  hoverBackground: p,
84
84
  focusBackground: f,
85
- type: O,
86
- ...A,
85
+ type: k,
86
+ ..._,
87
87
  children: i
88
88
  }
89
89
  )
90
90
  ), x = (e) => e == null ? 0 : typeof e == "boolean" ? e ? 1 : 0 : e, de = (e) => {
91
91
  if (e !== 0)
92
92
  return `calc(${e} * var(--swui-metrics-space))`;
93
- }, E = (e) => de(x(e)), pe = {
93
+ }, C = (e) => de(x(e)), pe = {
94
94
  // react props
95
95
  // https://github.com/facebook/react/blob/5495a7f24aef85ba6937truetrue1ce962673ca9f5fde6/src/renderers/dom/shared/hooks/ReactDOMUnknownPropertyHook.js
96
96
  children: !0,
@@ -616,17 +616,17 @@ const ae = "_separatorLine_nzfcz_1", ce = {
616
616
  },
617
617
  columnGap: {
618
618
  property: "columnGap",
619
- transform: E
619
+ transform: C
620
620
  },
621
621
  rowGap: {
622
622
  property: "rowGap",
623
- transform: E
623
+ transform: C
624
624
  },
625
625
  shadow: {
626
626
  property: "boxShadow",
627
627
  transform: (e) => fe[e] ?? e
628
628
  }
629
- }), b = _("div", {
629
+ }), b = S("div", {
630
630
  shouldForwardProp: (e) => typeof e == "string" ? ve(e) ? !1 : ge(e) : !1
631
631
  })`
632
632
  --current-spacing: 0;
@@ -701,7 +701,7 @@ const ae = "_separatorLine_nzfcz_1", ce = {
701
701
  }
702
702
  });
703
703
  }, [e, r, u, t]);
704
- return R(() => {
704
+ return M(() => {
705
705
  n();
706
706
  }, [n]), {
707
707
  dimensions: r
@@ -721,7 +721,7 @@ const ae = "_separatorLine_nzfcz_1", ce = {
721
721
  function({ num: t = 1, ...r }, u) {
722
722
  return /* @__PURE__ */ a(b, { spacing: t, ref: u, ...r });
723
723
  }
724
- ), _e = _.div`
724
+ ), _e = S.div`
725
725
  --current-size: 1;
726
726
  flex: none;
727
727
  width: calc(var(--current-size) * var(--swui-metrics-space));
@@ -743,12 +743,12 @@ const ae = "_separatorLine_nzfcz_1", ce = {
743
743
  }
744
744
  }
745
745
  );
746
- }, lt = ({ children: e, nest: t, render: r }) => t ? /* @__PURE__ */ a(S, { children: r(e) }) : /* @__PURE__ */ a(S, { children: e }), $e = "_visuallyHidden_1gevf_1", Se = {
746
+ }, lt = ({ children: e, nest: t, render: r }) => t ? /* @__PURE__ */ a(T, { children: r(e) }) : /* @__PURE__ */ a(T, { children: e }), $e = "_visuallyHidden_1gevf_1", Se = {
747
747
  visuallyHidden: $e
748
748
  }, Ee = (e) => se(e, Te), Te = (e, t) => Ce(t), Ce = (e) => e.startsWith("data-") || e.startsWith("aria-"), dt = ({
749
749
  children: e,
750
750
  ...t
751
- }) => /* @__PURE__ */ a("span", { className: Se.visuallyHidden, ...Ee(t), children: e }), Ie = "_text_1iisw_1", Re = "_standard_1iisw_24", Le = "_bold_1iisw_27", Me = "_caption_1iisw_31", Oe = "_overline_1iisw_39", Ae = "_large_1iisw_48", Pe = "_medium_1iisw_53", De = "_small_1iisw_58", He = "_smaller_1iisw_63", k = {
751
+ }) => /* @__PURE__ */ a("span", { className: Se.visuallyHidden, ...Ee(t), children: e }), Ie = "_text_1iisw_1", Re = "_standard_1iisw_24", Le = "_bold_1iisw_27", Me = "_caption_1iisw_31", Oe = "_overline_1iisw_39", Ae = "_large_1iisw_48", Pe = "_medium_1iisw_53", De = "_small_1iisw_58", He = "_smaller_1iisw_63", $ = {
752
752
  text: Ie,
753
753
  standard: Re,
754
754
  bold: Le,
@@ -769,26 +769,30 @@ const ae = "_separatorLine_nzfcz_1", ce = {
769
769
  whiteSpace: s,
770
770
  wordBreak: c,
771
771
  textAlign: i,
772
- style: l,
773
- ...p
774
- }, f) => /* @__PURE__ */ a(
772
+ overflow: l,
773
+ textOverflow: p,
774
+ style: f,
775
+ ...k
776
+ }, _) => /* @__PURE__ */ a(
775
777
  "span",
776
778
  {
777
- className: M(k.text, k[t], k[r], u),
778
- ref: f,
779
+ className: A($.text, $[t], $[r], u),
780
+ ref: _,
779
781
  style: {
780
782
  color: n,
781
783
  userSelect: o,
782
784
  whiteSpace: s,
783
785
  wordBreak: c,
784
786
  textAlign: i,
785
- ...l
787
+ overflow: l,
788
+ textOverflow: p,
789
+ ...f
786
790
  },
787
- ...p,
791
+ ...k,
788
792
  children: e
789
793
  }
790
794
  )
791
- ), pt = w, mt = (e) => /* @__PURE__ */ a(w, { size: "small", ...e }), ht = (e) => /* @__PURE__ */ a(w, { size: "smaller", ...e }), gt = (e) => /* @__PURE__ */ a(w, { size: "medium", ...e }), ft = (e) => /* @__PURE__ */ a(w, { size: "large", ...e }), ze = "_heading_1cnsg_1", Fe = "_h1_1cnsg_10", Ne = "_h2_1cnsg_14", Ue = "_h3_1cnsg_18", Ve = "_h4_1cnsg_22", qe = "_h5_1cnsg_26", je = "_h6_1cnsg_30", T = {
795
+ ), pt = w, mt = (e) => /* @__PURE__ */ a(w, { size: "small", ...e }), ht = (e) => /* @__PURE__ */ a(w, { size: "smaller", ...e }), gt = (e) => /* @__PURE__ */ a(w, { size: "medium", ...e }), ft = (e) => /* @__PURE__ */ a(w, { size: "large", ...e }), ze = "_heading_1cnsg_1", Fe = "_h1_1cnsg_10", Ne = "_h2_1cnsg_14", Ue = "_h3_1cnsg_18", Ve = "_h4_1cnsg_22", qe = "_h5_1cnsg_26", je = "_h6_1cnsg_30", I = {
792
796
  heading: ze,
793
797
  h1: Fe,
794
798
  h2: Ne,
@@ -810,7 +814,7 @@ const ae = "_separatorLine_nzfcz_1", ce = {
810
814
  }, l) => /* @__PURE__ */ a(
811
815
  c ?? e,
812
816
  {
813
- className: M(T.heading, T[e], t),
817
+ className: A(I.heading, I[e], t),
814
818
  style: { color: r, whiteSpace: u, wordBreak: n, ...o },
815
819
  ref: l,
816
820
  ...i,
@@ -854,7 +858,7 @@ const ae = "_separatorLine_nzfcz_1", ce = {
854
858
  removeMultiple: s,
855
859
  toggle: c
856
860
  };
857
- }, $ = (e) => {
861
+ }, E = (e) => {
858
862
  const [t, r] = y(e), u = m(() => {
859
863
  r(!0);
860
864
  }, [r]), n = m(() => {
@@ -886,9 +890,9 @@ const ae = "_separatorLine_nzfcz_1", ce = {
886
890
  }, [e, t]), r;
887
891
  };
888
892
  let Xe = 0;
889
- const C = (e) => `webui-${e ? e + "-" : ""}${++Xe}`, xt = (e) => {
890
- const [t, r] = y(() => C(e));
891
- return d(() => r(C(e)), [e]), t;
893
+ const R = (e) => `webui-${e ? e + "-" : ""}${++Xe}`, xt = (e) => {
894
+ const [t, r] = y(() => R(e));
895
+ return d(() => r(R(e)), [e]), t;
892
896
  }, v = (e, t, r) => {
893
897
  const u = g(null);
894
898
  d(() => {
@@ -907,7 +911,7 @@ const C = (e) => `webui-${e ? e + "-" : ""}${++Xe}`, xt = (e) => {
907
911
  };
908
912
  }, [t, e]);
909
913
  }, kt = (e) => {
910
- const [t, r, u] = $(!1);
914
+ const [t, r, u] = E(!1);
911
915
  d(() => {
912
916
  document.activeElement === e.current ? r() : u();
913
917
  }, [e, u, r]), v(e, "focus", r), v(e, "blur", u);
@@ -919,7 +923,7 @@ const C = (e) => `webui-${e ? e + "-" : ""}${++Xe}`, xt = (e) => {
919
923
  return { isInFocus: t, focus: n, blur: o };
920
924
  }, _t = (e) => {
921
925
  const t = g(e);
922
- return R(() => {
926
+ return M(() => {
923
927
  t.current = e;
924
928
  }), m((...r) => {
925
929
  const { current: u } = t;
@@ -929,10 +933,10 @@ const C = (e) => `webui-${e ? e + "-" : ""}${++Xe}`, xt = (e) => {
929
933
  const t = H.useRef(e);
930
934
  return t.current = e, t;
931
935
  }, St = (e) => {
932
- const [t, r, u] = $(!1);
936
+ const [t, r, u] = E(!1);
933
937
  return v(e, "mouseover", r), v(e, "mouseout", u), t;
934
938
  }, Et = (e) => {
935
- const [t, r, u] = $(!1);
939
+ const [t, r, u] = E(!1);
936
940
  return v(e, "mouseenter", r), v(e, "mouseleave", u), t;
937
941
  }, Tt = (e, t) => {
938
942
  const r = g(() => {
@@ -960,21 +964,21 @@ const C = (e) => `webui-${e ? e + "-" : ""}${++Xe}`, xt = (e) => {
960
964
  document.removeEventListener("mousedown", n, r), document.removeEventListener("touchstart", n, r);
961
965
  };
962
966
  }, [e, r]);
963
- }, I = ["mousemove", "mousedown", "keydown", "touchstart", "scroll"], It = (e, t) => {
967
+ }, L = ["mousemove", "mousedown", "keydown", "touchstart", "scroll"], It = (e, t) => {
964
968
  const r = g(() => {
965
969
  });
966
970
  d(() => {
967
971
  r.current = e;
968
972
  }, [e]), d(() => {
969
973
  const u = ie(r.current, t);
970
- return I.forEach((n) => window.addEventListener(n, u)), () => {
971
- I.forEach(
974
+ return L.forEach((n) => window.addEventListener(n, u)), () => {
975
+ L.forEach(
972
976
  (n) => window.removeEventListener(n, u)
973
977
  );
974
978
  };
975
979
  }, [t]);
976
980
  }, Rt = (e, t) => {
977
- const [r, u] = y(!1), { rootMargin: n, root: o, threshold: s } = t || {}, c = L(() => new IntersectionObserver(
981
+ const [r, u] = y(!1), { rootMargin: n, root: o, threshold: s } = t || {}, c = O(() => new IntersectionObserver(
978
982
  ([i]) => u(i.isIntersecting),
979
983
  {
980
984
  rootMargin: n,
@@ -1000,7 +1004,7 @@ const C = (e) => `webui-${e ? e + "-" : ""}${++Xe}`, xt = (e) => {
1000
1004
  return d(() => () => {
1001
1005
  clearTimeout(o.current);
1002
1006
  }, []), [u, s];
1003
- }, Ot = () => L(() => /* @__PURE__ */ new Date(), []), At = (e) => (t, r) => e(t).localeCompare(e(r)), Pt = (e) => (t, r) => e(t) - e(r), Dt = (e) => {
1007
+ }, Ot = () => O(() => /* @__PURE__ */ new Date(), []), At = (e) => (t, r) => e(t).localeCompare(e(r)), Pt = (e) => (t, r) => e(t) - e(r), Dt = (e) => {
1004
1008
  throw new Error(`Switch unhandled case: ${e}`);
1005
1009
  }, Ht = (e, t) => t, zt = (e) => Object.keys(e).filter((t) => e[t]), Ft = (e) => {
1006
1010
  try {
@@ -1051,7 +1055,7 @@ export {
1051
1055
  Nt as parseIntElseUndefined,
1052
1056
  zt as truthyKeysAsList,
1053
1057
  vt as useArraySet,
1054
- $ as useBoolean,
1058
+ E as useBoolean,
1055
1059
  bt as useDebounce,
1056
1060
  wt as useDelayedFalse,
1057
1061
  xt as useDomId,
@@ -1 +1 @@
1
- {"version":3,"file":"index.es.js","sources":["../src/components/decorators/separatorline/SeparatorLine.tsx","../src/components/interaction/Clickable.tsx","../src/utils/BooleanOrNumberToNumber.ts","../src/components/util/IsPropValid.ts","../src/components/layout/box/Box.tsx","../src/components/layout/column/Column.tsx","../src/hooks/UseElementDimensions.ts","../src/components/layout/box/ResizeAwareBox.tsx","../src/components/layout/row/Row.tsx","../src/components/layout/indent/Indent.tsx","../src/components/layout/spacing/Spacing.tsx","../src/components/layout/space/Space.tsx","../src/components/util/Nest.tsx","../src/utils/PropsForwarder.ts","../src/components/accessibility/ScreenReaderOnlyText.tsx","../src/components/text/Text.tsx","../src/components/deprecated-text/SmallText.tsx","../src/components/deprecated-text/SmallerText.tsx","../src/components/deprecated-text/StandardText.tsx","../src/components/deprecated-text/LargeText.tsx","../src/components/heading/Heading.tsx","../src/components/deprecated-text/HeaderText.tsx","../src/hooks/UseArraySet.ts","../src/hooks/UseBoolean.ts","../src/hooks/UseDebounce.ts","../src/hooks/UseDelayedFalse.ts","../src/hooks/UseDomId.ts","../src/hooks/UseEventListener.ts","../src/hooks/UseElementFocus.ts","../src/hooks/UseEventCallback.tsx","../src/hooks/UseLatest.ts","../src/hooks/UseMouseIsOver.ts","../src/hooks/UseMouseIsEntered.ts","../src/hooks/UseMultiOnClickOutside.ts","../src/hooks/UseOnClickOutside.ts","../src/hooks/UseOnNoMouseInput.ts","../src/hooks/UseOnScreen.ts","../src/hooks/UseForwardedRef.ts","../src/hooks/UseTimeoutState.ts","../src/hooks/UseToday.ts","../src/sorting/Comparators.ts","../src/utils/SwitchCaseExhauster.ts","../src/utils/TruthyKeysAsList.ts","../src/utils/parsers/NumberParser.ts","../src/utils/Invariant.ts"],"sourcesContent":["import { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { cssColor } from \"@stenajs-webui/theme\";\nimport styles from \"./SeparatorLine.module.css\";\n\nexport interface SeparatorLineProps {\n color?: Property.Color;\n vertical?: boolean;\n size?: string;\n width?: string;\n}\n\nexport const SeparatorLine = forwardRef<HTMLHRElement, SeparatorLineProps>(\n (\n {\n color = cssColor(\"--lhds-color-ui-300\"),\n size = \"100%\",\n width = \"1px\",\n vertical = false,\n },\n ref,\n ) => {\n return (\n <hr\n className={styles.separatorLine}\n aria-hidden={true}\n color={color}\n style={{\n backgroundColor: color,\n height: vertical ? size || \"100%\" : width || \"1px\",\n width: vertical ? width || \"1px\" : size || \"100%\",\n }}\n ref={ref}\n />\n );\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\nimport { CSSProperties, forwardRef, MouseEventHandler } from \"react\";\nimport { ButtonElementProps } from \"../../types/ElementProps\";\n\nexport interface ClickableProps extends ButtonElementProps {\n /** Callback function called when clicking on click area. */\n onClick?: MouseEventHandler<HTMLButtonElement>;\n /** Callback function called when double clicking on click area. */\n onDblClick?: MouseEventHandler<HTMLButtonElement>;\n /** Adds a title to the click area. */\n tooltip?: string;\n /** If set, there is no opacity applies when clicking on the click area. */\n disableOpacityOnClick?: boolean;\n /** Mouse does not turn into pointer when hovering over click area. */\n disablePointer?: boolean;\n /** When set, click area receives opacity when mouse hovers over it. */\n opacityOnHover?: boolean;\n /** Custom style on div with click event. */\n style?: CSSProperties;\n /** Disables shadow when element is focused. */\n disableFocusHighlight?: boolean;\n /** Disables the HTML button element. */\n disabled?: boolean;\n /**\n * Sets the background of the box.\n */\n background?: string;\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: string;\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: string;\n /**\n * The width.\n */\n width?: string;\n /**\n * The height.\n */\n height?: string;\n /**\n * Border radius\n */\n borderRadius?: string;\n}\n\ninterface ClickableElementProps {\n disableOpacityOnClick?: boolean;\n opacityOnHover?: boolean;\n disableFocusHighlight?: boolean;\n pointer?: boolean;\n background?: string;\n focusBackground?: string;\n hoverBackground?: string;\n width?: string;\n height?: string;\n borderRadius?: string;\n}\n\nconst ClickableElement = styled.button<ClickableElementProps>`\n display: inline-block;\n user-select: none;\n border: 0;\n padding: 0;\n background: ${({ background }) => background};\n ${({ pointer }) => (pointer ? \"cursor: pointer;\" : \"\")}\n\n :hover {\n ${(props) => (props.opacityOnHover ? \"opacity: 0.7;\" : \"\")};\n ${({ hoverBackground }) => `background: ${hoverBackground};`}\n }\n :active {\n ${({ disableOpacityOnClick }) =>\n !disableOpacityOnClick ? \"opacity: 0.5;\" : \"\"}\n }\n :focus {\n outline: 0;\n ${({ disableFocusHighlight }) =>\n disableFocusHighlight\n ? \"\"\n : \"box-shadow: 0 0 3pt 2pt rgba(0, 0, 100, 0.3);\"}\n ${({ focusBackground }) => `background: ${focusBackground};`}\n }\n ${({ width }) => (width ? `width: ${width};` : \"\")}\n ${({ height }) => (height ? `height: ${height};` : \"\")}\n ${({ borderRadius }) =>\n borderRadius ? `border-radius: ${borderRadius};` : \"\"}\n`;\n\nexport const Clickable = forwardRef<HTMLButtonElement, ClickableProps>(\n (\n {\n disableFocusHighlight,\n onClick,\n onDblClick,\n tooltip,\n disableOpacityOnClick,\n disablePointer,\n opacityOnHover,\n disabled,\n children,\n background = \"transparent\",\n hoverBackground,\n focusBackground,\n type = \"button\",\n ...restProps\n },\n ref,\n ) => {\n const hasClickHandler = !!(onClick || onDblClick);\n\n return (\n <ClickableElement\n opacityOnHover={opacityOnHover}\n title={tooltip}\n disabled={disabled}\n disableOpacityOnClick={disableOpacityOnClick}\n onClick={onClick}\n onDoubleClick={onDblClick}\n disableFocusHighlight={disableFocusHighlight}\n pointer={hasClickHandler && !disablePointer}\n ref={ref}\n background={background}\n hoverBackground={hoverBackground}\n focusBackground={focusBackground}\n type={type}\n {...restProps}\n >\n {children}\n </ClickableElement>\n );\n },\n);\n","export const booleanOrNumberToNumber = (\n num: number | boolean | undefined,\n): number => {\n if (num == null) {\n return 0;\n }\n if (typeof num === \"boolean\") {\n return num ? 1 : 0;\n }\n return num;\n};\n\nexport const numberToMetricCalc = (num: number): string | undefined => {\n if (num === 0) {\n return undefined;\n }\n return `calc(${num} * var(--swui-metrics-space))`;\n};\n\nexport const booleanOrNumberToMetricCalc = (\n num: number | boolean | undefined,\n): string | undefined => numberToMetricCalc(booleanOrNumberToNumber(num));\n","import { memoize } from \"lodash-es\";\n\nconst validPropsRecord = {\n // react props\n // https://github.com/facebook/react/blob/5495a7f24aef85ba6937truetrue1ce962673ca9f5fde6/src/renderers/dom/shared/hooks/ReactDOMUnknownPropertyHook.js\n children: true,\n dangerouslySetInnerHTML: true,\n key: true,\n ref: true,\n autoFocus: true,\n defaultValue: true,\n defaultChecked: true,\n innerHTML: true,\n suppressContentEditableWarning: true,\n suppressHydrationWarning: true,\n // deprecated react prop\n valueLink: true,\n\n // https://github.com/facebook/react/blob/d7157651f7b72d9888ctrue123e191f9b88cd8f41e9/src/renderers/dom/shared/HTMLDOMPropertyConfig.js\n /**\n * Standard Properties\n */\n\n abbr: true,\n accept: true,\n acceptCharset: true,\n accessKey: true,\n action: true,\n allow: true,\n allowUserMedia: true,\n allowPaymentRequest: true,\n allowFullScreen: true,\n allowTransparency: true,\n alt: true,\n // specifies target context for links with `preload` type\n // as: true,\n async: true,\n autoComplete: true,\n // autoFocus is polyfilled/normalized by AutoFocusUtils\n // autoFocus: true,\n autoPlay: true,\n capture: true,\n cellPadding: true,\n cellSpacing: true,\n // keygen prop\n challenge: true,\n charSet: true,\n checked: true,\n cite: true,\n classID: true,\n className: true,\n cols: true,\n colSpan: true,\n content: true,\n contentEditable: true,\n contextMenu: true,\n controls: true,\n controlsList: true,\n coords: true,\n crossOrigin: true,\n data: true, // For `<object />` acts as `src`.\n dateTime: true,\n decoding: true,\n default: true,\n defer: true,\n dir: true,\n disabled: true,\n disablePictureInPicture: true,\n disableRemotePlayback: true,\n download: true,\n draggable: true,\n encType: true,\n enterKeyHint: true,\n form: true,\n formAction: true,\n formEncType: true,\n formMethod: true,\n formNoValidate: true,\n formTarget: true,\n frameBorder: true,\n headers: true,\n height: true,\n hidden: true,\n high: true,\n href: true,\n hrefLang: true,\n htmlFor: true,\n httpEquiv: true,\n id: true,\n inputMode: true,\n integrity: true,\n is: true,\n keyParams: true,\n keyType: true,\n kind: true,\n label: true,\n lang: true,\n list: true,\n loading: true,\n loop: true,\n low: true,\n // manifest: true,\n marginHeight: true,\n marginWidth: true,\n max: true,\n maxLength: true,\n media: true,\n mediaGroup: true,\n method: true,\n min: true,\n minLength: true,\n // Caution; `option.selected` is not updated if `select.multiple` is\n // disabled with `removeAttribute`.\n multiple: true,\n muted: true,\n name: true,\n nonce: true,\n noValidate: true,\n open: true,\n optimum: true,\n pattern: true,\n placeholder: true,\n playsInline: true,\n poster: true,\n preload: true,\n profile: true,\n radioGroup: true,\n readOnly: true,\n referrerPolicy: true,\n rel: true,\n required: true,\n reversed: true,\n role: true,\n rows: true,\n rowSpan: true,\n sandbox: true,\n scope: true,\n scoped: true,\n scrolling: true,\n seamless: true,\n selected: true,\n shape: true,\n size: true,\n sizes: true,\n // support for projecting regular DOM Elements via V1 named slots ( shadow dom )\n slot: true,\n span: true,\n spellCheck: true,\n src: true,\n srcDoc: true,\n srcLang: true,\n srcSet: true,\n start: true,\n step: true,\n style: true,\n summary: true,\n tabIndex: true,\n target: true,\n title: true,\n translate: true,\n // Setting .type throws on non-<input> tags\n type: true,\n useMap: true,\n value: true,\n width: true,\n wmode: true,\n wrap: true,\n\n /**\n * RDFa Properties\n */\n about: true,\n datatype: true,\n inlist: true,\n prefix: true,\n // property is also supported for OpenGraph in meta tags.\n property: true,\n resource: true,\n typeof: true,\n vocab: true,\n\n /**\n * Non-standard Properties\n */\n // autoCapitalize and autoCorrect are supported in Mobile Safari for\n // keyboard hints.\n autoCapitalize: true,\n autoCorrect: true,\n // autoSave allows WebKit/Blink to persist values of input fields on page reloads\n autoSave: true,\n // color is for Safari mask-icon link\n color: true,\n // https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/search#incremental_This_API_has_not_been_standardized\n incremental: true,\n // used in amp html for indicating the fallback behavior\n // https://amp.dev/documentation/guides-and-tutorials/develop/style_and_layout/placeholders/\n fallback: true,\n // https://html.spec.whatwg.org/multipage/interaction.html#inert\n inert: true,\n // itemProp, itemScope, itemType are for\n // Microdata support. See http://schema.org/docs/gs.html\n itemProp: true,\n itemScope: true,\n itemType: true,\n // itemID and itemRef are for Microdata support as well but\n // only specified in the WHATWG spec document. See\n // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api\n itemID: true,\n itemRef: true,\n // used in amp html for eventing purposes\n // https://amp.dev/documentation/guides-and-tutorials/learn/common_attributes/\n on: true,\n // used in amp html for indicating that the option is selectable\n // https://amp.dev/documentation/components/amp-selector/\n option: true,\n // results show looking glass icon and recent searches on input\n // search fields in WebKit/Blink\n results: true,\n // IE-only attribute that specifies security restrictions on an iframe\n // as an alternative to the sandbox attribute on IE<1true\n security: true,\n // IE-only attribute that controls focus behavior\n unselectable: true,\n //\n // SVG properties: https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\n // The following \"onX\" events have been omitted:\n //\n // onabort\n // onactivate\n // onbegin\n // onclick\n // onend\n // onerror\n // onfocusin\n // onfocusout\n // onload\n // onmousedown\n // onmousemove\n // onmouseout\n // onmouseover\n // onmouseup\n // onrepeat\n // onresize\n // onscroll\n // onunload\n accentHeight: true,\n accumulate: true,\n additive: true,\n alignmentBaseline: true,\n allowReorder: true,\n alphabetic: true,\n amplitude: true,\n arabicForm: true,\n ascent: true,\n attributeName: true,\n attributeType: true,\n autoReverse: true,\n azimuth: true,\n baseFrequency: true,\n baselineShift: true,\n baseProfile: true,\n bbox: true,\n begin: true,\n bias: true,\n by: true,\n calcMode: true,\n capHeight: true,\n clip: true,\n clipPathUnits: true,\n clipPath: true,\n clipRule: true,\n colorInterpolation: true,\n colorInterpolationFilters: true,\n colorProfile: true,\n colorRendering: true,\n contentScriptType: true,\n contentStyleType: true,\n cursor: true,\n cx: true,\n cy: true,\n d: true,\n decelerate: true,\n descent: true,\n diffuseConstant: true,\n direction: true,\n display: true,\n divisor: true,\n dominantBaseline: true,\n dur: true,\n dx: true,\n dy: true,\n edgeMode: true,\n elevation: true,\n enableBackground: true,\n end: true,\n exponent: true,\n externalResourcesRequired: true,\n fill: true,\n fillOpacity: true,\n fillRule: true,\n filter: true,\n filterRes: true,\n filterUnits: true,\n floodColor: true,\n floodOpacity: true,\n focusable: true,\n fontFamily: true,\n fontSize: true,\n fontSizeAdjust: true,\n fontStretch: true,\n fontStyle: true,\n fontVariant: true,\n fontWeight: true,\n format: true,\n from: true,\n fr: true, // valid SVG element but React will ask for removal\n fx: true,\n fy: true,\n g1: true,\n g2: true,\n glyphName: true,\n glyphOrientationHorizontal: true,\n glyphOrientationVertical: true,\n glyphRef: true,\n gradientTransform: true,\n gradientUnits: true,\n hanging: true,\n horizAdvX: true,\n horizOriginX: true,\n ideographic: true,\n imageRendering: true,\n in: true,\n in2: true,\n intercept: true,\n k: true,\n k1: true,\n k2: true,\n k3: true,\n k4: true,\n kernelMatrix: true,\n kernelUnitLength: true,\n kerning: true,\n keyPoints: true,\n keySplines: true,\n keyTimes: true,\n lengthAdjust: true,\n letterSpacing: true,\n lightingColor: true,\n limitingConeAngle: true,\n local: true,\n markerEnd: true,\n markerMid: true,\n markerStart: true,\n markerHeight: true,\n markerUnits: true,\n markerWidth: true,\n mask: true,\n maskContentUnits: true,\n maskUnits: true,\n mathematical: true,\n mode: true,\n numOctaves: true,\n offset: true,\n opacity: true,\n operator: true,\n order: true,\n orient: true,\n orientation: true,\n origin: true,\n overflow: true,\n overlinePosition: true,\n overlineThickness: true,\n panose1: true,\n paintOrder: true,\n pathLength: true,\n patternContentUnits: true,\n patternTransform: true,\n patternUnits: true,\n pointerEvents: true,\n points: true,\n pointsAtX: true,\n pointsAtY: true,\n pointsAtZ: true,\n preserveAlpha: true,\n preserveAspectRatio: true,\n primitiveUnits: true,\n r: true,\n radius: true,\n refX: true,\n refY: true,\n renderingIntent: true,\n repeatCount: true,\n repeatDur: true,\n requiredExtensions: true,\n requiredFeatures: true,\n restart: true,\n result: true,\n rotate: true,\n rx: true,\n ry: true,\n scale: true,\n seed: true,\n shapeRendering: true,\n slope: true,\n spacing: true,\n specularConstant: true,\n specularExponent: true,\n speed: true,\n spreadMethod: true,\n startOffset: true,\n stdDeviation: true,\n stemh: true,\n stemv: true,\n stitchTiles: true,\n stopColor: true,\n stopOpacity: true,\n strikethroughPosition: true,\n strikethroughThickness: true,\n string: true,\n stroke: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeLinecap: true,\n strokeLinejoin: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true,\n surfaceScale: true,\n systemLanguage: true,\n tableValues: true,\n targetX: true,\n targetY: true,\n textAnchor: true,\n textDecoration: true,\n textRendering: true,\n textLength: true,\n to: true,\n transform: true,\n u1: true,\n u2: true,\n underlinePosition: true,\n underlineThickness: true,\n unicode: true,\n unicodeBidi: true,\n unicodeRange: true,\n unitsPerEm: true,\n vAlphabetic: true,\n vHanging: true,\n vIdeographic: true,\n vMathematical: true,\n values: true,\n vectorEffect: true,\n version: true,\n vertAdvY: true,\n vertOriginX: true,\n vertOriginY: true,\n viewBox: true,\n viewTarget: true,\n visibility: true,\n widths: true,\n wordSpacing: true,\n writingMode: true,\n x: true,\n xHeight: true,\n x1: true,\n x2: true,\n xChannelSelector: true,\n xlinkActuate: true,\n xlinkArcrole: true,\n xlinkHref: true,\n xlinkRole: true,\n xlinkShow: true,\n xlinkTitle: true,\n xlinkType: true,\n xmlBase: true,\n xmlns: true,\n xmlnsXlink: true,\n xmlLang: true,\n xmlSpace: true,\n y: true,\n y1: true,\n y2: true,\n yChannelSelector: true,\n z: true,\n zoomAndPan: true,\n\n // For preact. We have this code here even though Emotion doesn't support\n // Preact, since @emotion/is-prop-valid is used by some libraries outside of\n // the context of Emotion.\n for: true,\n class: true,\n autofocus: true,\n};\n\nconst validProps = `^((${Object.keys(validPropsRecord).join(\n \"|\",\n)})|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$`;\n\nconst r = new RegExp(validProps);\n\nexport const isPropValid: (prop: string) => boolean = memoize(\n (prop: string) =>\n r.test(prop) ||\n (prop.charCodeAt(0) === 111 /* o */ &&\n prop.charCodeAt(1) === 110 /* n */ &&\n prop.charCodeAt(2) < 91) /* Z+1 */,\n);\n","import styled from \"@emotion/styled\";\nimport { Property } from \"csstype\";\n\nimport {\n background,\n BackgroundProps,\n border,\n borderBottom,\n BorderBottomProps,\n borderColor,\n borderLeft,\n BorderLeftProps,\n borderRadius,\n BorderRadiusProps,\n borderRight,\n BorderRightProps,\n borderStyle,\n BorderStyleProps,\n borderTop,\n BorderTopProps,\n borderWidth,\n BorderWidthProps,\n bottom,\n BottomProps,\n boxShadow,\n BoxShadowProps,\n flexbox,\n FlexboxProps,\n layout,\n LayoutProps,\n left,\n LeftProps,\n overflow,\n OverflowProps,\n position,\n PositionProps,\n ResponsiveValue,\n right,\n RightProps,\n system,\n TLengthStyledSystem,\n top,\n TopProps,\n zIndex,\n ZIndexProps,\n} from \"styled-system\";\nimport { DivProps } from \"../../../types/ElementProps\";\nimport {\n booleanOrNumberToMetricCalc,\n booleanOrNumberToNumber,\n} from \"../../../utils/BooleanOrNumberToNumber\";\nimport { isPropValid } from \"../../util/IsPropValid\";\n\ninterface StyledSystemProps\n extends BorderRadiusProps,\n BorderStyleProps,\n BorderWidthProps,\n BorderLeftProps,\n BorderRightProps,\n BorderTopProps,\n BorderBottomProps,\n FlexboxProps,\n LayoutProps,\n OverflowProps,\n PositionProps,\n ZIndexProps,\n LeftProps,\n RightProps,\n TopProps,\n BottomProps {}\n\nconst shadows = {\n box: \"var(--swui-shadow-box)\",\n popover: \"var(--swui-shadow-popover)\",\n modal: \"var(--swui-shadow-modal)\",\n bottom: \"var(--swui-shadow-bottom)\",\n};\n\ntype ShadowType = keyof typeof shadows;\n\nexport interface BoxProps extends StyledSystemProps, DivProps {\n /**\n * If true, children are placed in a row.\n */\n row?: ResponsiveValue<boolean>;\n\n /**\n * Adds spacing over and under content.\n */\n spacing?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing left and right of content.\n */\n indent?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing between children.\n */\n gap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between columns.\n */\n columnGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between rows.\n */\n rowGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds a shadow around the box.\n */\n shadow?: ResponsiveValue<Property.BoxShadow | ShadowType>;\n\n /**\n * Sets the background of the box.\n */\n background?: ResponsiveValue<Property.Background<TLengthStyledSystem>>;\n\n /**\n * Sets the border of the box.\n */\n border?: ResponsiveValue<Property.Border<TLengthStyledSystem>>;\n\n /**\n * Sets the border color of the box.\n */\n borderColor?: ResponsiveValue<Property.BorderColor>;\n\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when hovering with mouse.\n */\n hoverBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when the box is in focus.\n */\n focusBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when focus is within the box.\n */\n focusWithinBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when focus is within the box.\n */\n focusWithinBorder?: Property.Border<TLengthStyledSystem>;\n}\n\nconst excludedProps = [\n \"spacing\",\n \"indent\",\n \"gap\",\n \"width\",\n \"height\",\n \"overflow\",\n \"display\",\n];\n\nconst isExcludedWebUiProp = (propName: string) =>\n excludedProps.includes(propName);\n\nconst box = system({\n row: {\n property: \"flexDirection\",\n transform: (row: boolean) => (row ? \"row\" : \"column\"),\n },\n indent: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-indent\",\n transform: booleanOrNumberToNumber,\n },\n spacing: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-spacing\",\n transform: booleanOrNumberToNumber,\n },\n gap: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-gap\",\n transform: booleanOrNumberToNumber,\n },\n columnGap: {\n property: \"columnGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n rowGap: {\n property: \"rowGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n shadow: {\n property: \"boxShadow\",\n transform: (value: ShadowType) => shadows[value] ?? value,\n },\n});\n\ntype InnerProps = BoxProps & BoxShadowProps & BackgroundProps;\n\nexport const Box = styled(\"div\", {\n shouldForwardProp: (propName) =>\n typeof propName === \"string\"\n ? isExcludedWebUiProp(propName)\n ? false\n : isPropValid(propName)\n : false,\n})<InnerProps>`\n --current-spacing: 0;\n --current-indent: 0;\n --current-gap: 0;\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n ${box};\n ${background};\n ${border};\n ${borderRight};\n ${borderLeft};\n ${borderTop};\n ${borderBottom};\n ${borderColor};\n ${borderRadius};\n ${borderStyle};\n ${borderWidth};\n ${boxShadow};\n ${flexbox};\n ${overflow};\n ${position};\n ${layout};\n ${zIndex};\n ${left};\n ${right};\n ${top};\n ${bottom};\n\n gap: calc(var(--current-gap) * var(--swui-metrics-space));\n\n padding: calc(var(--current-spacing) * var(--swui-metrics-spacing))\n calc(var(--current-indent) * var(--swui-metrics-indent));\n\n :hover {\n ${({ hoverBackground }) =>\n hoverBackground ? `background: ${hoverBackground};` : \"\"}\n ${({ hoverBorder }) => (hoverBorder ? `border: ${hoverBorder};` : \"\")}\n }\n\n :focus {\n ${({ focusBackground }) =>\n focusBackground ? `background: ${focusBackground};` : \"\"}\n ${({ focusBorder }) => (focusBorder ? `border: ${focusBorder};` : \"\")}\n }\n\n :focus-within {\n ${({ focusWithinBackground }) =>\n focusWithinBackground ? `background: ${focusWithinBackground};` : \"\"}\n ${({ focusWithinBorder }) =>\n focusWithinBorder ? `border: ${focusWithinBorder};` : \"\"}\n }\n`;\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Column = forwardRef<HTMLDivElement, BoxProps>(\n function Column(props, ref) {\n return <Box ref={ref} {...props} />;\n },\n);\n","import { RefObject, useCallback, useLayoutEffect, useState } from \"react\";\n\nexport interface ElementDimensions {\n width: number;\n height: number;\n top: number;\n left: number;\n x: number;\n y: number;\n right: number;\n bottom: number;\n}\n\nexport const getDimensionObject = (node: HTMLElement): ElementDimensions => {\n const { x, y, width, height, bottom, top, left, right } =\n node.getBoundingClientRect();\n\n return {\n width,\n height,\n top,\n left,\n x,\n y,\n right,\n bottom,\n };\n};\n\nconst isEqualDimensions = (\n a: ElementDimensions,\n b: ElementDimensions,\n): boolean =>\n a.x === b.x &&\n a.y === b.y &&\n a.width === b.width &&\n a.height === b.height &&\n a.bottom === b.bottom &&\n a.top === b.top &&\n a.left === b.left &&\n a.right === b.right;\n\nexport const useElementDimensions = (\n ref: RefObject<HTMLElement | null>,\n onResizeElement?: (dimensions: ElementDimensions) => void,\n) => {\n const [dimensions, setDimensions] = useState<ElementDimensions | undefined>();\n\n const updateDimensions = useCallback(() => {\n window.requestAnimationFrame(() => {\n if (ref.current) {\n const newDimensions = getDimensionObject(ref.current);\n if (!dimensions || !isEqualDimensions(dimensions, newDimensions)) {\n if (onResizeElement) {\n onResizeElement(newDimensions);\n }\n }\n setDimensions(newDimensions);\n }\n });\n }, [ref, dimensions, setDimensions, onResizeElement]);\n\n useLayoutEffect(() => {\n updateDimensions();\n }, [updateDimensions]);\n\n return {\n dimensions,\n };\n};\n","import * as React from \"react\";\nimport { forwardRef, RefObject, useRef } from \"react\";\nimport { Box, BoxProps } from \"./Box\";\nimport {\n ElementDimensions,\n useElementDimensions,\n} from \"../../../hooks/UseElementDimensions\";\n\nexport interface ResizeAwareBoxProps extends Omit<BoxProps, \"onResize\"> {\n onResize?: (dimensions: ElementDimensions) => void;\n}\n\nexport const ResizeAwareBox = forwardRef<HTMLDivElement, ResizeAwareBoxProps>(\n function ResizeAwareBox({ onResize, ...boxProps }, ref) {\n const localRef = useRef<HTMLDivElement>(null);\n const currentRef = (ref as RefObject<HTMLDivElement>) ?? localRef;\n useElementDimensions(currentRef, onResize);\n\n return <Box {...boxProps} ref={ref} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Row = forwardRef<HTMLDivElement, BoxProps>(\n function Row(props, ref) {\n return <Box row ref={ref} {...props} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface IndentProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Indent = forwardRef<HTMLDivElement, IndentProps>(function Indent(\n { num = 1, ...props },\n ref,\n) {\n return <Box indent={num} ref={ref} {...props} />;\n});\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface SpacingProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Spacing = forwardRef<HTMLDivElement, SpacingProps>(\n function Spacing({ num = 1, ...props }, ref) {\n return <Box spacing={num} ref={ref} {...props} />;\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\n\nexport interface SpaceProps {\n half?: boolean;\n horizontal?: boolean;\n num?: number;\n vertical?: boolean;\n}\n\nconst InnerSpace = styled.div`\n --current-size: 1;\n flex: none;\n width: calc(var(--current-size) * var(--swui-metrics-space));\n height: calc(var(--current-size) * var(--swui-metrics-space));\n`;\n\nexport const Space: React.FC<SpaceProps> = ({\n half = false,\n horizontal = false,\n num = 1,\n vertical = false,\n}) => {\n const size = num * (half ? 0.5 : 1);\n\n return (\n <InnerSpace\n style={{\n [\"--current-size\" as string]: size,\n height: horizontal ? 1 : undefined,\n width: vertical ? 1 : undefined,\n }}\n />\n );\n};\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\n\ninterface Props {\n nest?: boolean;\n render: (children: ReactNode) => ReactNode;\n children?: ReactNode;\n}\n\nexport const Nest: React.FC<Props> = ({ children, nest, render }) => {\n if (nest) {\n return <>{render(children)}</>;\n }\n return <>{children}</>;\n};\n","import { pickBy } from \"lodash-es\";\n\nexport const getDataProps = <T extends Record<string, unknown>>(\n props: Record<string, unknown> | object,\n): T => pickBy(props, isDataPropMapper) as T;\n\nconst isDataPropMapper = (_: unknown, key: string): boolean => isDataProp(key);\n\nconst isDataProp = <TProp extends string>(propName: TProp): boolean =>\n propName.startsWith(\"data-\") || propName.startsWith(\"aria-\");\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\nimport styles from \"./ScreenReaderOnlyText.module.css\";\nimport { getDataProps } from \"../../utils/PropsForwarder\";\n\nexport interface ScreenReaderOnlyTextProps {\n children?: ReactNode;\n}\n\nexport const ScreenReaderOnlyText: React.FC<ScreenReaderOnlyTextProps> = ({\n children,\n ...props\n}) => {\n return (\n <span className={styles.visuallyHidden} {...getDataProps(props)}>\n {children}\n </span>\n );\n};\n","import * as React from \"react\";\nimport cx from \"classnames\";\nimport styles from \"./Text.module.css\";\nimport { SpanProps } from \"../../types/ElementProps\";\nimport { Property } from \"csstype\";\nimport { forwardRef } from \"react\";\n\nexport interface TextProps extends SpanProps {\n variant?: TextVariant;\n size?: TextSize;\n userSelect?: Property.UserSelect;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n textAlign?: Property.TextAlign;\n color?: string;\n}\n\nexport type TextVariant = \"standard\" | \"caption\" | \"overline\" | \"bold\";\nexport type TextSize = \"large\" | \"medium\" | \"small\" | \"smaller\";\n\nexport const Text = forwardRef<HTMLSpanElement, TextProps>(\n (\n {\n children,\n variant = \"standard\",\n size = \"medium\",\n className,\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n style,\n ...spanProps\n },\n ref,\n ) => {\n return (\n <span\n className={cx(styles.text, styles[variant], styles[size], className)}\n ref={ref}\n style={{\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n ...style,\n }}\n {...spanProps}\n >\n {children}\n </span>\n );\n },\n);\n\nexport const Txt = Text;\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"small\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallerText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"smaller\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const StandardText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"medium\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const LargeText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"large\"} {...props} />;\n};\n","import cx from \"classnames\";\nimport { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { H1Props } from \"../../types/ElementProps\";\nimport styles from \"./Heading.module.css\";\n\nexport interface HeadingProps extends H1Props {\n variant?: HeadingVariant;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n as?: HeadingVariant;\n}\n\nexport type HeadingVariant = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\nexport const Heading = forwardRef<HTMLHeadingElement, HeadingProps>(\n (\n {\n variant = \"h3\",\n className,\n color,\n whiteSpace,\n wordBreak,\n style,\n children,\n as,\n ...hProps\n },\n ref,\n ) => {\n const Element = as ?? variant;\n return (\n <Element\n className={cx(styles.heading, styles[variant], className)}\n style={{ color, whiteSpace, wordBreak, ...style }}\n ref={ref}\n {...hProps}\n >\n {children}\n </Element>\n );\n },\n);\n","import * as React from \"react\";\nimport { Heading, HeadingProps } from \"../heading/Heading\";\n\n/**\n * @deprecated Please use `Heading` instead.\n */\nexport const HeaderText: React.FC<Omit<HeadingProps, \"variant\">> = (props) => {\n return <Heading variant={\"h2\"} {...props} />;\n};\n","import { useCallback } from \"react\";\n\ntype ArrayItemEqualsComparator<T> = (a: T, b: T) => boolean;\n\nconst defaultComparator = <T>(a: T, b: T) => a === b;\n\nexport const useArraySet = <T>(\n list: Array<T>,\n setList: (list: Array<T>) => void,\n comparator: ArrayItemEqualsComparator<T> = defaultComparator,\n) => {\n const add = useCallback(\n (item: T) => {\n if (!list.some((l) => comparator(l, item))) {\n setList([...list, item]);\n }\n },\n [list, setList, comparator],\n );\n\n const addMultiple = useCallback(\n (items: Array<T>) => {\n setList(\n items.reduce((list, item) => {\n if (!list.some((l) => comparator(l, item))) {\n return [...list, item];\n }\n return list;\n }, list),\n );\n },\n [list, setList, comparator],\n );\n\n const remove = useCallback(\n (item: T) => {\n const index = list.findIndex((l) => comparator(l, item));\n if (index >= 0) {\n setList(list.filter((_, i) => i !== index));\n }\n },\n [list, setList, comparator],\n );\n\n const removeMultiple = useCallback(\n (items: Array<T>) => {\n setList(list.filter((item) => !items.some((l) => comparator(l, item))));\n },\n [list, setList, comparator],\n );\n\n const toggle = useCallback(\n (item: T) => {\n const found = list.some((l) => comparator(l, item));\n if (found) {\n remove(item);\n } else {\n add(item);\n }\n },\n [list, add, remove, comparator],\n );\n\n return {\n add,\n addMultiple,\n remove,\n removeMultiple,\n toggle,\n };\n};\n","import { useCallback, useState } from \"react\";\n\ntype Value = boolean;\ntype SetTrue = () => void;\ntype SetFalse = () => void;\ntype ToggleValue = () => void;\ntype BooleanHook = [Value, SetTrue, SetFalse, ToggleValue];\n\nexport const useBoolean = (initialValue: Value): BooleanHook => {\n const [value, setValue] = useState(initialValue);\n\n const setTrue = useCallback(() => {\n setValue(true);\n }, [setValue]);\n\n const setFalse = useCallback(() => {\n setValue(false);\n }, [setValue]);\n\n const toggle = useCallback(() => {\n setValue((v) => !v);\n }, [setValue]);\n\n return [value, setTrue, setFalse, toggle];\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDebounce = <T>(value: T, delay: number): T => {\n // State and setters for debounced value\n const [debouncedValue, setDebouncedValue] = useState<T>(value);\n\n useEffect(() => {\n // Update debounced value after delay\n const handler = setTimeout(() => {\n setDebouncedValue(value);\n }, delay);\n\n // Cancel the timeout if value changes (also on delay change or unmount)\n // This is how we prevent debounced value from updating if value is changed ...\n // .. within the delay period. Timeout gets cleared and restarted.\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]); // Only re-call effect if value or delay changes\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDelayedFalse = (value: boolean, delay: number) => {\n const [debouncedValue, setDebouncedValue] = useState<boolean>(value);\n\n useEffect(() => {\n if (value) {\n setDebouncedValue(true);\n }\n\n const handler = setTimeout(() => {\n if (!value) {\n setDebouncedValue(value);\n }\n }, delay);\n\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]);\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nlet id = 0;\nconst genId = (componentName?: string) =>\n `webui-${componentName ? componentName + \"-\" : \"\"}${++id}`;\n\n/** @deprecated use useId-hook from React 18 */\nexport const useDomId = (componentName?: string): string => {\n const [id, setId] = useState<string | null>(() => genId(componentName));\n useEffect(() => setId(genId(componentName)), [componentName]);\n return id!;\n};\n","import { RefObject, useEffect, useRef } from \"react\";\n\ntype EventHandler<TEventName extends keyof HTMLElementEventMap> = (\n event: HTMLElementEventMap[TEventName],\n) => void;\n\nexport const useEventListener = <TEventName extends keyof HTMLElementEventMap>(\n ref: RefObject<HTMLElement | null>,\n eventName: TEventName,\n handler: EventHandler<TEventName>,\n) => {\n // Create a ref that stores handler\n const savedHandler = useRef<EventHandler<TEventName>>(null);\n\n // Update ref.current value if handler changes.\n // This allows our effect below to always get latest handler ...\n // ... without us needing to pass it in effect deps array ...\n // ... and potentially cause effect to re-run every render.\n useEffect(() => {\n savedHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n // Make sure element supports addEventListener\n const isSupported = ref.current && ref.current.addEventListener;\n if (!isSupported) return;\n\n // Create event listener that calls handler function stored in ref\n const eventListener: EventHandler<TEventName> = (event) => {\n if (savedHandler.current) {\n return savedHandler.current(event);\n }\n };\n\n // Add event listener\n if (!ref.current) {\n return;\n }\n\n const element = ref.current;\n element.addEventListener(eventName, eventListener);\n\n // Remove event listener on cleanup\n return () => {\n if (element) {\n element.removeEventListener(eventName, eventListener);\n }\n };\n }, [eventName, ref]); // Re-run if eventName or element changes\n};\n","import { RefObject, useCallback, useEffect } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useElementFocus = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [isInFocus, setIsInFocus, setIsNotInFocus] = useBoolean(false);\n\n useEffect(() => {\n if (document.activeElement === ref.current) {\n setIsInFocus();\n } else {\n setIsNotInFocus();\n }\n }, [ref, setIsNotInFocus, setIsInFocus]);\n\n useEventListener(ref, \"focus\", setIsInFocus);\n useEventListener(ref, \"blur\", setIsNotInFocus);\n\n const focus = useCallback(() => {\n if (ref.current) {\n ref.current.focus();\n }\n }, [ref]);\n\n const blur = useCallback(() => {\n if (ref.current) {\n ref.current.blur();\n }\n }, [ref]);\n\n return { isInFocus, focus, blur };\n};\n","import { useCallback, useLayoutEffect, useRef } from \"react\";\n\ntype Fn<ARGS extends unknown[], R> = (...args: ARGS) => R;\n\nexport const useEventCallback = <A extends unknown[], R>(\n fn: Fn<A, R>,\n): Fn<A, R> => {\n const ref = useRef<Fn<A, R>>(fn);\n useLayoutEffect(() => {\n ref.current = fn;\n });\n return useCallback((...args: A): R => {\n const { current } = ref;\n return current(...args);\n }, []);\n};\n","import React, { MutableRefObject } from \"react\";\n\nexport const useLatest = <T>(value: T): MutableRefObject<T> => {\n const ref = React.useRef(value);\n ref.current = value;\n return ref;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsOver = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsOver, setMouseIsOver, setMouseIsNotOver] = useBoolean(false);\n\n useEventListener(ref, \"mouseover\", setMouseIsOver);\n useEventListener(ref, \"mouseout\", setMouseIsNotOver);\n\n return mouseIsOver;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsEntered = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsEntered, setMouseIsEntered, setMouseIsNotEntered] =\n useBoolean(false);\n\n useEventListener(ref, \"mouseenter\", setMouseIsEntered);\n useEventListener(ref, \"mouseleave\", setMouseIsNotEntered);\n\n return mouseIsEntered;\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useMultiOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n refs: Array<React.RefObject<any>>,\n handler: (event: TouchEvent | MouseEvent) => void,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n\n const allNotContains = refs\n .filter((ref) => ref.current)\n .every((ref) => {\n return ref.current && !ref.current.contains(event.target);\n });\n\n if (!allNotContains) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener);\n document.addEventListener(\"touchstart\", listener);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener);\n document.removeEventListener(\"touchstart\", listener);\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [...refs]);\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ref: React.RefObject<any>,\n handler: (event: TouchEvent | MouseEvent) => void,\n options?: AddEventListenerOptions,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n if (!ref.current || ref.current.contains(event.target)) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener, options);\n document.addEventListener(\"touchstart\", listener, options);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener, options);\n document.removeEventListener(\"touchstart\", listener, options);\n };\n }, [ref, options]);\n};\n","import { debounce } from \"lodash-es\";\nimport { useEffect, useRef } from \"react\";\n\nconst events = [\"mousemove\", \"mousedown\", \"keydown\", \"touchstart\", \"scroll\"];\n\nexport const useOnNoMouseMovement = (callback: () => void, delay: number) => {\n const eventHandler = useRef<(event: Event) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = callback;\n }, [callback]);\n\n useEffect(() => {\n const onIdleChange = debounce(eventHandler.current, delay);\n events.forEach((event) => window.addEventListener(event, onIdleChange));\n\n return () => {\n events.forEach((event) =>\n window.removeEventListener(event, onIdleChange),\n );\n };\n }, [delay]);\n};\n","import { RefObject, useEffect, useMemo, useState } from \"react\";\n\nexport const useOnScreen = (\n ref: RefObject<Element | null>,\n options?: IntersectionObserverInit,\n) => {\n const [isVisible, setIsVisible] = useState(false);\n\n const { rootMargin, root, threshold } = options || {};\n\n const observer = useMemo(() => {\n return new IntersectionObserver(\n ([entry]) => setIsVisible(entry.isIntersecting),\n {\n rootMargin,\n root,\n threshold,\n },\n );\n }, [setIsVisible, rootMargin, root, threshold]);\n\n useEffect(() => {\n if (ref.current) {\n observer.observe(ref.current);\n }\n return () => {\n observer.disconnect();\n };\n }, [observer, ref]);\n\n return isVisible;\n};\n","import {\n MutableRefObject,\n RefCallback,\n RefObject,\n useEffect,\n useRef,\n} from \"react\";\n\nexport const useForwardedRef = <T>(\n ref: RefCallback<T> | MutableRefObject<T> | null,\n): RefObject<NonNullable<T>> => {\n const innerRef = useRef<T>(null) as MutableRefObject<NonNullable<T>>;\n\n useEffect(() => {\n if (!ref) return;\n if (typeof ref === \"function\") {\n ref(innerRef.current);\n } else {\n ref.current = innerRef.current;\n }\n });\n\n return innerRef;\n};\n","import { useCallback, useEffect, useRef, useState } from \"react\";\n\nexport const useTimeoutState = <S>(\n initialValue: S,\n defaultTimeout: number,\n clearTimeoutOnSetValue = true,\n): [S, (v: S) => void] => {\n const [value, setValue] = useState<S>(initialValue);\n const timeoutRef = useRef<NodeJS.Timeout>(null);\n\n const wrappedSetter = useCallback(\n (newValue: S, timeout = defaultTimeout) => {\n setValue(newValue);\n if (clearTimeoutOnSetValue) {\n clearTimeout(timeoutRef.current!);\n }\n timeoutRef.current = setTimeout(() => setValue(initialValue), timeout);\n },\n [defaultTimeout, clearTimeoutOnSetValue, initialValue],\n );\n\n useEffect(() => {\n return () => {\n clearTimeout(timeoutRef.current!);\n };\n }, []);\n\n return [value, wrappedSetter];\n};\n","import { useMemo } from \"react\";\n\nexport const useToday = () => {\n return useMemo(() => new Date(), []);\n};\n","export const byStringField =\n <T>(fieldResolver: (item: T) => string) =>\n (a: T, b: T): number =>\n fieldResolver(a).localeCompare(fieldResolver(b));\n\nexport const byNumberField =\n <T>(fieldResolver: (item: T) => number) =>\n (a: T, b: T): number =>\n fieldResolver(a) - fieldResolver(b);\n","export const exhaustSwitchCaseElseThrow = (arg: never) => {\n throw new Error(`Switch unhandled case: ${arg}`);\n};\n\nexport const exhaustSwitchCase = <T>(_arg: never, fallback: T) => {\n return fallback;\n};\n","export const truthyKeysAsList = (r: Record<string, boolean>): Array<string> =>\n Object.keys(r).filter((key) => r[key]);\n","export const parseFloatElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseFloat(s);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n\nexport const parseIntElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseInt(s, 10);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n","export function invariant<T>(\n val: T | null | undefined,\n message: string,\n): asserts val is T {\n if (val == null) {\n throw new Error(\"Invariant error: \" + message);\n }\n}\n"],"names":["SeparatorLine","forwardRef","color","cssColor","size","width","vertical","ref","jsx","styles","ClickableElement","styled","background","pointer","props","hoverBackground","disableOpacityOnClick","disableFocusHighlight","focusBackground","height","borderRadius","Clickable","onClick","onDblClick","tooltip","disablePointer","opacityOnHover","disabled","children","type","restProps","booleanOrNumberToNumber","num","numberToMetricCalc","booleanOrNumberToMetricCalc","validPropsRecord","validProps","r","isPropValid","memoize","prop","shadows","excludedProps","isExcludedWebUiProp","propName","box","system","row","value","Box","border","borderRight","borderLeft","borderTop","borderBottom","borderColor","borderStyle","borderWidth","boxShadow","flexbox","overflow","position","layout","zIndex","left","right","top","bottom","hoverBorder","focusBorder","focusWithinBackground","focusWithinBorder","Column","getDimensionObject","node","x","y","isEqualDimensions","a","b","useElementDimensions","onResizeElement","dimensions","setDimensions","useState","updateDimensions","useCallback","newDimensions","useLayoutEffect","ResizeAwareBox","onResize","boxProps","localRef","useRef","Row","Indent","Spacing","InnerSpace","Space","half","horizontal","Nest","nest","render","Fragment","getDataProps","pickBy","isDataPropMapper","_","key","isDataProp","ScreenReaderOnlyText","Text","variant","className","userSelect","whiteSpace","wordBreak","textAlign","style","spanProps","cx","Txt","SmallText","SmallerText","StandardText","LargeText","Heading","as","hProps","HeaderText","defaultComparator","useArraySet","list","setList","comparator","add","item","addMultiple","items","l","remove","index","i","removeMultiple","toggle","useBoolean","initialValue","setValue","setTrue","setFalse","v","useDebounce","delay","debouncedValue","setDebouncedValue","useEffect","handler","useDelayedFalse","id","genId","componentName","useDomId","setId","useEventListener","eventName","savedHandler","eventListener","event","element","useElementFocus","isInFocus","setIsInFocus","setIsNotInFocus","focus","blur","useEventCallback","fn","args","current","useLatest","React","useMouseIsOver","mouseIsOver","setMouseIsOver","setMouseIsNotOver","useMouseIsEntered","mouseIsEntered","setMouseIsEntered","setMouseIsNotEntered","useMultiOnClickOutside","refs","eventHandler","listener","useOnClickOutside","options","events","useOnNoMouseMovement","callback","onIdleChange","debounce","useOnScreen","isVisible","setIsVisible","rootMargin","root","threshold","observer","useMemo","entry","useForwardedRef","innerRef","useTimeoutState","defaultTimeout","clearTimeoutOnSetValue","timeoutRef","wrappedSetter","newValue","timeout","useToday","byStringField","fieldResolver","byNumberField","exhaustSwitchCaseElseThrow","arg","exhaustSwitchCase","_arg","fallback","truthyKeysAsList","parseFloatElseUndefined","s","f","parseIntElseUndefined","invariant","val","message"],"mappings":";;;;;;;;;GAaaA,KAAgBC;AAAA,EAC3B,CACE;AAAA,IACE,OAAAC,IAAQC,EAAS,qBAAqB;AAAA,IACtC,MAAAC,IAAO;AAAA,IACP,OAAAC,IAAQ;AAAA,IACR,UAAAC,IAAW;AAAA,KAEbC,MAGE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC,GAAO;AAAA,MAClB,eAAa;AAAA,MACb,OAAAP;AAAA,MACA,OAAO;AAAA,QACL,iBAAiBA;AAAA,QACjB,QAAQI,IAAWF,KAAQ,SAASC,KAAS;AAAA,QAC7C,OAAOC,IAAWD,KAAS,QAAQD,KAAQ;AAAA,MAC7C;AAAA,MACA,KAAAG;AAAA,IAAA;AAAA,EACF;AAGN,GC0BMG,KAAmBC,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA,gBAKhB,CAAC,EAAE,YAAAC,EAAW,MAAMA,CAAU;AAAA,IAC1C,CAAC,EAAE,SAAAC,EAAA,MAAeA,IAAU,qBAAqB,EAAG;AAAA;AAAA;AAAA,MAGlD,CAACC,MAAWA,EAAM,iBAAiB,kBAAkB,EAAG;AAAA,MACxD,CAAC,EAAE,iBAAAC,EAAsB,MAAA,eAAeA,CAAe,GAAG;AAAA;AAAA;AAAA,MAG1D,CAAC,EAAE,uBAAAC,EAAA,MACFA,IAA0C,KAAlB,eAAoB;AAAA;AAAA;AAAA;AAAA,MAI7C,CAAC,EAAE,uBAAAC,EAAA,MACHA,IACI,KACA,+CAA+C;AAAA,MACnD,CAAC,EAAE,iBAAAC,EAAsB,MAAA,eAAeA,CAAe,GAAG;AAAA;AAAA,IAE5D,CAAC,EAAE,OAAAb,EAAM,MAAOA,I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I,EAAc9I,CAAC,CAAC,GAEtC+I,KACX,CAAID,MACJ,CAAC/I,GAAMC,MACL8I,EAAc/I,CAAC,IAAI+I,EAAc9I,CAAC,GCRzBgJ,KAA6B,CAACC,MAAe;AACxD,QAAM,IAAI,MAAM,0BAA0BA,CAAG,EAAE;AACjD,GAEaC,KAAoB,CAAIC,GAAaC,MACzCA,GCLIC,KAAmB,CAAC/L,MAC/B,OAAO,KAAKA,CAAC,EAAE,OAAO,CAACwE,MAAQxE,EAAEwE,CAAG,CAAC,GCD1BwH,KAA0B,CAACC,MAAkC;AACpE,MAAA;AACI,UAAAC,IAAI,WAAWD,CAAC;AAItB,WAHI,MAAMC,CAAC,KAGPA,KAAK,OACA,SAEFA;AAAA,EAAA,QACD;AAAA,EAAA;AAIV,GAEaC,KAAwB,CAACF,MAAkC;AAClE,MAAA;AACI,UAAAC,IAAI,SAASD,GAAG,EAAE;AAIxB,WAHI,MAAMC,CAAC,KAGPA,KAAK,OACA,SAEFA;AAAA,EAAA,QACD;AAAA,EAAA;AAIV;AC9BgB,SAAAE,GACdC,GACAC,GACkB;AAClB,MAAID,KAAO;AACH,UAAA,IAAI,MAAM,sBAAsBC,CAAO;AAEjD;"}
1
+ {"version":3,"file":"index.es.js","sources":["../src/components/decorators/separatorline/SeparatorLine.tsx","../src/components/interaction/Clickable.tsx","../src/utils/BooleanOrNumberToNumber.ts","../src/components/util/IsPropValid.ts","../src/components/layout/box/Box.tsx","../src/components/layout/column/Column.tsx","../src/hooks/UseElementDimensions.ts","../src/components/layout/box/ResizeAwareBox.tsx","../src/components/layout/row/Row.tsx","../src/components/layout/indent/Indent.tsx","../src/components/layout/spacing/Spacing.tsx","../src/components/layout/space/Space.tsx","../src/components/util/Nest.tsx","../src/utils/PropsForwarder.ts","../src/components/accessibility/ScreenReaderOnlyText.tsx","../src/components/text/Text.tsx","../src/components/deprecated-text/SmallText.tsx","../src/components/deprecated-text/SmallerText.tsx","../src/components/deprecated-text/StandardText.tsx","../src/components/deprecated-text/LargeText.tsx","../src/components/heading/Heading.tsx","../src/components/deprecated-text/HeaderText.tsx","../src/hooks/UseArraySet.ts","../src/hooks/UseBoolean.ts","../src/hooks/UseDebounce.ts","../src/hooks/UseDelayedFalse.ts","../src/hooks/UseDomId.ts","../src/hooks/UseEventListener.ts","../src/hooks/UseElementFocus.ts","../src/hooks/UseEventCallback.tsx","../src/hooks/UseLatest.ts","../src/hooks/UseMouseIsOver.ts","../src/hooks/UseMouseIsEntered.ts","../src/hooks/UseMultiOnClickOutside.ts","../src/hooks/UseOnClickOutside.ts","../src/hooks/UseOnNoMouseInput.ts","../src/hooks/UseOnScreen.ts","../src/hooks/UseForwardedRef.ts","../src/hooks/UseTimeoutState.ts","../src/hooks/UseToday.ts","../src/sorting/Comparators.ts","../src/utils/SwitchCaseExhauster.ts","../src/utils/TruthyKeysAsList.ts","../src/utils/parsers/NumberParser.ts","../src/utils/Invariant.ts"],"sourcesContent":["import { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { cssColor } from \"@stenajs-webui/theme\";\nimport styles from \"./SeparatorLine.module.css\";\n\nexport interface SeparatorLineProps {\n color?: Property.Color;\n vertical?: boolean;\n size?: string;\n width?: string;\n}\n\nexport const SeparatorLine = forwardRef<HTMLHRElement, SeparatorLineProps>(\n (\n {\n color = cssColor(\"--lhds-color-ui-300\"),\n size = \"100%\",\n width = \"1px\",\n vertical = false,\n },\n ref,\n ) => {\n return (\n <hr\n className={styles.separatorLine}\n aria-hidden={true}\n color={color}\n style={{\n backgroundColor: color,\n height: vertical ? size || \"100%\" : width || \"1px\",\n width: vertical ? width || \"1px\" : size || \"100%\",\n }}\n ref={ref}\n />\n );\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\nimport { CSSProperties, forwardRef, MouseEventHandler } from \"react\";\nimport { ButtonElementProps } from \"../../types/ElementProps\";\n\nexport interface ClickableProps extends ButtonElementProps {\n /** Callback function called when clicking on click area. */\n onClick?: MouseEventHandler<HTMLButtonElement>;\n /** Callback function called when double clicking on click area. */\n onDblClick?: MouseEventHandler<HTMLButtonElement>;\n /** Adds a title to the click area. */\n tooltip?: string;\n /** If set, there is no opacity applies when clicking on the click area. */\n disableOpacityOnClick?: boolean;\n /** Mouse does not turn into pointer when hovering over click area. */\n disablePointer?: boolean;\n /** When set, click area receives opacity when mouse hovers over it. */\n opacityOnHover?: boolean;\n /** Custom style on div with click event. */\n style?: CSSProperties;\n /** Disables shadow when element is focused. */\n disableFocusHighlight?: boolean;\n /** Disables the HTML button element. */\n disabled?: boolean;\n /**\n * Sets the background of the box.\n */\n background?: string;\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: string;\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: string;\n /**\n * The width.\n */\n width?: string;\n /**\n * The height.\n */\n height?: string;\n /**\n * Border radius\n */\n borderRadius?: string;\n}\n\ninterface ClickableElementProps {\n disableOpacityOnClick?: boolean;\n opacityOnHover?: boolean;\n disableFocusHighlight?: boolean;\n pointer?: boolean;\n background?: string;\n focusBackground?: string;\n hoverBackground?: string;\n width?: string;\n height?: string;\n borderRadius?: string;\n}\n\nconst ClickableElement = styled.button<ClickableElementProps>`\n display: inline-block;\n user-select: none;\n border: 0;\n padding: 0;\n background: ${({ background }) => background};\n ${({ pointer }) => (pointer ? \"cursor: pointer;\" : \"\")}\n\n :hover {\n ${(props) => (props.opacityOnHover ? \"opacity: 0.7;\" : \"\")};\n ${({ hoverBackground }) => `background: ${hoverBackground};`}\n }\n :active {\n ${({ disableOpacityOnClick }) =>\n !disableOpacityOnClick ? \"opacity: 0.5;\" : \"\"}\n }\n :focus {\n outline: 0;\n ${({ disableFocusHighlight }) =>\n disableFocusHighlight\n ? \"\"\n : \"box-shadow: 0 0 3pt 2pt rgba(0, 0, 100, 0.3);\"}\n ${({ focusBackground }) => `background: ${focusBackground};`}\n }\n ${({ width }) => (width ? `width: ${width};` : \"\")}\n ${({ height }) => (height ? `height: ${height};` : \"\")}\n ${({ borderRadius }) =>\n borderRadius ? `border-radius: ${borderRadius};` : \"\"}\n`;\n\nexport const Clickable = forwardRef<HTMLButtonElement, ClickableProps>(\n (\n {\n disableFocusHighlight,\n onClick,\n onDblClick,\n tooltip,\n disableOpacityOnClick,\n disablePointer,\n opacityOnHover,\n disabled,\n children,\n background = \"transparent\",\n hoverBackground,\n focusBackground,\n type = \"button\",\n ...restProps\n },\n ref,\n ) => {\n const hasClickHandler = !!(onClick || onDblClick);\n\n return (\n <ClickableElement\n opacityOnHover={opacityOnHover}\n title={tooltip}\n disabled={disabled}\n disableOpacityOnClick={disableOpacityOnClick}\n onClick={onClick}\n onDoubleClick={onDblClick}\n disableFocusHighlight={disableFocusHighlight}\n pointer={hasClickHandler && !disablePointer}\n ref={ref}\n background={background}\n hoverBackground={hoverBackground}\n focusBackground={focusBackground}\n type={type}\n {...restProps}\n >\n {children}\n </ClickableElement>\n );\n },\n);\n","export const booleanOrNumberToNumber = (\n num: number | boolean | undefined,\n): number => {\n if (num == null) {\n return 0;\n }\n if (typeof num === \"boolean\") {\n return num ? 1 : 0;\n }\n return num;\n};\n\nexport const numberToMetricCalc = (num: number): string | undefined => {\n if (num === 0) {\n return undefined;\n }\n return `calc(${num} * var(--swui-metrics-space))`;\n};\n\nexport const booleanOrNumberToMetricCalc = (\n num: number | boolean | undefined,\n): string | undefined => numberToMetricCalc(booleanOrNumberToNumber(num));\n","import { memoize } from \"lodash-es\";\n\nconst validPropsRecord = {\n // react props\n // https://github.com/facebook/react/blob/5495a7f24aef85ba6937truetrue1ce962673ca9f5fde6/src/renderers/dom/shared/hooks/ReactDOMUnknownPropertyHook.js\n children: true,\n dangerouslySetInnerHTML: true,\n key: true,\n ref: true,\n autoFocus: true,\n defaultValue: true,\n defaultChecked: true,\n innerHTML: true,\n suppressContentEditableWarning: true,\n suppressHydrationWarning: true,\n // deprecated react prop\n valueLink: true,\n\n // https://github.com/facebook/react/blob/d7157651f7b72d9888ctrue123e191f9b88cd8f41e9/src/renderers/dom/shared/HTMLDOMPropertyConfig.js\n /**\n * Standard Properties\n */\n\n abbr: true,\n accept: true,\n acceptCharset: true,\n accessKey: true,\n action: true,\n allow: true,\n allowUserMedia: true,\n allowPaymentRequest: true,\n allowFullScreen: true,\n allowTransparency: true,\n alt: true,\n // specifies target context for links with `preload` type\n // as: true,\n async: true,\n autoComplete: true,\n // autoFocus is polyfilled/normalized by AutoFocusUtils\n // autoFocus: true,\n autoPlay: true,\n capture: true,\n cellPadding: true,\n cellSpacing: true,\n // keygen prop\n challenge: true,\n charSet: true,\n checked: true,\n cite: true,\n classID: true,\n className: true,\n cols: true,\n colSpan: true,\n content: true,\n contentEditable: true,\n contextMenu: true,\n controls: true,\n controlsList: true,\n coords: true,\n crossOrigin: true,\n data: true, // For `<object />` acts as `src`.\n dateTime: true,\n decoding: true,\n default: true,\n defer: true,\n dir: true,\n disabled: true,\n disablePictureInPicture: true,\n disableRemotePlayback: true,\n download: true,\n draggable: true,\n encType: true,\n enterKeyHint: true,\n form: true,\n formAction: true,\n formEncType: true,\n formMethod: true,\n formNoValidate: true,\n formTarget: true,\n frameBorder: true,\n headers: true,\n height: true,\n hidden: true,\n high: true,\n href: true,\n hrefLang: true,\n htmlFor: true,\n httpEquiv: true,\n id: true,\n inputMode: true,\n integrity: true,\n is: true,\n keyParams: true,\n keyType: true,\n kind: true,\n label: true,\n lang: true,\n list: true,\n loading: true,\n loop: true,\n low: true,\n // manifest: true,\n marginHeight: true,\n marginWidth: true,\n max: true,\n maxLength: true,\n media: true,\n mediaGroup: true,\n method: true,\n min: true,\n minLength: true,\n // Caution; `option.selected` is not updated if `select.multiple` is\n // disabled with `removeAttribute`.\n multiple: true,\n muted: true,\n name: true,\n nonce: true,\n noValidate: true,\n open: true,\n optimum: true,\n pattern: true,\n placeholder: true,\n playsInline: true,\n poster: true,\n preload: true,\n profile: true,\n radioGroup: true,\n readOnly: true,\n referrerPolicy: true,\n rel: true,\n required: true,\n reversed: true,\n role: true,\n rows: true,\n rowSpan: true,\n sandbox: true,\n scope: true,\n scoped: true,\n scrolling: true,\n seamless: true,\n selected: true,\n shape: true,\n size: true,\n sizes: true,\n // support for projecting regular DOM Elements via V1 named slots ( shadow dom )\n slot: true,\n span: true,\n spellCheck: true,\n src: true,\n srcDoc: true,\n srcLang: true,\n srcSet: true,\n start: true,\n step: true,\n style: true,\n summary: true,\n tabIndex: true,\n target: true,\n title: true,\n translate: true,\n // Setting .type throws on non-<input> tags\n type: true,\n useMap: true,\n value: true,\n width: true,\n wmode: true,\n wrap: true,\n\n /**\n * RDFa Properties\n */\n about: true,\n datatype: true,\n inlist: true,\n prefix: true,\n // property is also supported for OpenGraph in meta tags.\n property: true,\n resource: true,\n typeof: true,\n vocab: true,\n\n /**\n * Non-standard Properties\n */\n // autoCapitalize and autoCorrect are supported in Mobile Safari for\n // keyboard hints.\n autoCapitalize: true,\n autoCorrect: true,\n // autoSave allows WebKit/Blink to persist values of input fields on page reloads\n autoSave: true,\n // color is for Safari mask-icon link\n color: true,\n // https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/search#incremental_This_API_has_not_been_standardized\n incremental: true,\n // used in amp html for indicating the fallback behavior\n // https://amp.dev/documentation/guides-and-tutorials/develop/style_and_layout/placeholders/\n fallback: true,\n // https://html.spec.whatwg.org/multipage/interaction.html#inert\n inert: true,\n // itemProp, itemScope, itemType are for\n // Microdata support. See http://schema.org/docs/gs.html\n itemProp: true,\n itemScope: true,\n itemType: true,\n // itemID and itemRef are for Microdata support as well but\n // only specified in the WHATWG spec document. See\n // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api\n itemID: true,\n itemRef: true,\n // used in amp html for eventing purposes\n // https://amp.dev/documentation/guides-and-tutorials/learn/common_attributes/\n on: true,\n // used in amp html for indicating that the option is selectable\n // https://amp.dev/documentation/components/amp-selector/\n option: true,\n // results show looking glass icon and recent searches on input\n // search fields in WebKit/Blink\n results: true,\n // IE-only attribute that specifies security restrictions on an iframe\n // as an alternative to the sandbox attribute on IE<1true\n security: true,\n // IE-only attribute that controls focus behavior\n unselectable: true,\n //\n // SVG properties: https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\n // The following \"onX\" events have been omitted:\n //\n // onabort\n // onactivate\n // onbegin\n // onclick\n // onend\n // onerror\n // onfocusin\n // onfocusout\n // onload\n // onmousedown\n // onmousemove\n // onmouseout\n // onmouseover\n // onmouseup\n // onrepeat\n // onresize\n // onscroll\n // onunload\n accentHeight: true,\n accumulate: true,\n additive: true,\n alignmentBaseline: true,\n allowReorder: true,\n alphabetic: true,\n amplitude: true,\n arabicForm: true,\n ascent: true,\n attributeName: true,\n attributeType: true,\n autoReverse: true,\n azimuth: true,\n baseFrequency: true,\n baselineShift: true,\n baseProfile: true,\n bbox: true,\n begin: true,\n bias: true,\n by: true,\n calcMode: true,\n capHeight: true,\n clip: true,\n clipPathUnits: true,\n clipPath: true,\n clipRule: true,\n colorInterpolation: true,\n colorInterpolationFilters: true,\n colorProfile: true,\n colorRendering: true,\n contentScriptType: true,\n contentStyleType: true,\n cursor: true,\n cx: true,\n cy: true,\n d: true,\n decelerate: true,\n descent: true,\n diffuseConstant: true,\n direction: true,\n display: true,\n divisor: true,\n dominantBaseline: true,\n dur: true,\n dx: true,\n dy: true,\n edgeMode: true,\n elevation: true,\n enableBackground: true,\n end: true,\n exponent: true,\n externalResourcesRequired: true,\n fill: true,\n fillOpacity: true,\n fillRule: true,\n filter: true,\n filterRes: true,\n filterUnits: true,\n floodColor: true,\n floodOpacity: true,\n focusable: true,\n fontFamily: true,\n fontSize: true,\n fontSizeAdjust: true,\n fontStretch: true,\n fontStyle: true,\n fontVariant: true,\n fontWeight: true,\n format: true,\n from: true,\n fr: true, // valid SVG element but React will ask for removal\n fx: true,\n fy: true,\n g1: true,\n g2: true,\n glyphName: true,\n glyphOrientationHorizontal: true,\n glyphOrientationVertical: true,\n glyphRef: true,\n gradientTransform: true,\n gradientUnits: true,\n hanging: true,\n horizAdvX: true,\n horizOriginX: true,\n ideographic: true,\n imageRendering: true,\n in: true,\n in2: true,\n intercept: true,\n k: true,\n k1: true,\n k2: true,\n k3: true,\n k4: true,\n kernelMatrix: true,\n kernelUnitLength: true,\n kerning: true,\n keyPoints: true,\n keySplines: true,\n keyTimes: true,\n lengthAdjust: true,\n letterSpacing: true,\n lightingColor: true,\n limitingConeAngle: true,\n local: true,\n markerEnd: true,\n markerMid: true,\n markerStart: true,\n markerHeight: true,\n markerUnits: true,\n markerWidth: true,\n mask: true,\n maskContentUnits: true,\n maskUnits: true,\n mathematical: true,\n mode: true,\n numOctaves: true,\n offset: true,\n opacity: true,\n operator: true,\n order: true,\n orient: true,\n orientation: true,\n origin: true,\n overflow: true,\n overlinePosition: true,\n overlineThickness: true,\n panose1: true,\n paintOrder: true,\n pathLength: true,\n patternContentUnits: true,\n patternTransform: true,\n patternUnits: true,\n pointerEvents: true,\n points: true,\n pointsAtX: true,\n pointsAtY: true,\n pointsAtZ: true,\n preserveAlpha: true,\n preserveAspectRatio: true,\n primitiveUnits: true,\n r: true,\n radius: true,\n refX: true,\n refY: true,\n renderingIntent: true,\n repeatCount: true,\n repeatDur: true,\n requiredExtensions: true,\n requiredFeatures: true,\n restart: true,\n result: true,\n rotate: true,\n rx: true,\n ry: true,\n scale: true,\n seed: true,\n shapeRendering: true,\n slope: true,\n spacing: true,\n specularConstant: true,\n specularExponent: true,\n speed: true,\n spreadMethod: true,\n startOffset: true,\n stdDeviation: true,\n stemh: true,\n stemv: true,\n stitchTiles: true,\n stopColor: true,\n stopOpacity: true,\n strikethroughPosition: true,\n strikethroughThickness: true,\n string: true,\n stroke: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeLinecap: true,\n strokeLinejoin: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true,\n surfaceScale: true,\n systemLanguage: true,\n tableValues: true,\n targetX: true,\n targetY: true,\n textAnchor: true,\n textDecoration: true,\n textRendering: true,\n textLength: true,\n to: true,\n transform: true,\n u1: true,\n u2: true,\n underlinePosition: true,\n underlineThickness: true,\n unicode: true,\n unicodeBidi: true,\n unicodeRange: true,\n unitsPerEm: true,\n vAlphabetic: true,\n vHanging: true,\n vIdeographic: true,\n vMathematical: true,\n values: true,\n vectorEffect: true,\n version: true,\n vertAdvY: true,\n vertOriginX: true,\n vertOriginY: true,\n viewBox: true,\n viewTarget: true,\n visibility: true,\n widths: true,\n wordSpacing: true,\n writingMode: true,\n x: true,\n xHeight: true,\n x1: true,\n x2: true,\n xChannelSelector: true,\n xlinkActuate: true,\n xlinkArcrole: true,\n xlinkHref: true,\n xlinkRole: true,\n xlinkShow: true,\n xlinkTitle: true,\n xlinkType: true,\n xmlBase: true,\n xmlns: true,\n xmlnsXlink: true,\n xmlLang: true,\n xmlSpace: true,\n y: true,\n y1: true,\n y2: true,\n yChannelSelector: true,\n z: true,\n zoomAndPan: true,\n\n // For preact. We have this code here even though Emotion doesn't support\n // Preact, since @emotion/is-prop-valid is used by some libraries outside of\n // the context of Emotion.\n for: true,\n class: true,\n autofocus: true,\n};\n\nconst validProps = `^((${Object.keys(validPropsRecord).join(\n \"|\",\n)})|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$`;\n\nconst r = new RegExp(validProps);\n\nexport const isPropValid: (prop: string) => boolean = memoize(\n (prop: string) =>\n r.test(prop) ||\n (prop.charCodeAt(0) === 111 /* o */ &&\n prop.charCodeAt(1) === 110 /* n */ &&\n prop.charCodeAt(2) < 91) /* Z+1 */,\n);\n","import styled from \"@emotion/styled\";\nimport { Property } from \"csstype\";\n\nimport {\n background,\n BackgroundProps,\n border,\n borderBottom,\n BorderBottomProps,\n borderColor,\n borderLeft,\n BorderLeftProps,\n borderRadius,\n BorderRadiusProps,\n borderRight,\n BorderRightProps,\n borderStyle,\n BorderStyleProps,\n borderTop,\n BorderTopProps,\n borderWidth,\n BorderWidthProps,\n bottom,\n BottomProps,\n boxShadow,\n BoxShadowProps,\n flexbox,\n FlexboxProps,\n layout,\n LayoutProps,\n left,\n LeftProps,\n overflow,\n OverflowProps,\n position,\n PositionProps,\n ResponsiveValue,\n right,\n RightProps,\n system,\n TLengthStyledSystem,\n top,\n TopProps,\n zIndex,\n ZIndexProps,\n} from \"styled-system\";\nimport { DivProps } from \"../../../types/ElementProps\";\nimport {\n booleanOrNumberToMetricCalc,\n booleanOrNumberToNumber,\n} from \"../../../utils/BooleanOrNumberToNumber\";\nimport { isPropValid } from \"../../util/IsPropValid\";\n\ninterface StyledSystemProps\n extends BorderRadiusProps,\n BorderStyleProps,\n BorderWidthProps,\n BorderLeftProps,\n BorderRightProps,\n BorderTopProps,\n BorderBottomProps,\n FlexboxProps,\n LayoutProps,\n OverflowProps,\n PositionProps,\n ZIndexProps,\n LeftProps,\n RightProps,\n TopProps,\n BottomProps {}\n\nconst shadows = {\n box: \"var(--swui-shadow-box)\",\n popover: \"var(--swui-shadow-popover)\",\n modal: \"var(--swui-shadow-modal)\",\n bottom: \"var(--swui-shadow-bottom)\",\n};\n\ntype ShadowType = keyof typeof shadows;\n\nexport interface BoxProps extends StyledSystemProps, DivProps {\n /**\n * If true, children are placed in a row.\n */\n row?: ResponsiveValue<boolean>;\n\n /**\n * Adds spacing over and under content.\n */\n spacing?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing left and right of content.\n */\n indent?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing between children.\n */\n gap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between columns.\n */\n columnGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between rows.\n */\n rowGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds a shadow around the box.\n */\n shadow?: ResponsiveValue<Property.BoxShadow | ShadowType>;\n\n /**\n * Sets the background of the box.\n */\n background?: ResponsiveValue<Property.Background<TLengthStyledSystem>>;\n\n /**\n * Sets the border of the box.\n */\n border?: ResponsiveValue<Property.Border<TLengthStyledSystem>>;\n\n /**\n * Sets the border color of the box.\n */\n borderColor?: ResponsiveValue<Property.BorderColor>;\n\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when hovering with mouse.\n */\n hoverBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when the box is in focus.\n */\n focusBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when focus is within the box.\n */\n focusWithinBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when focus is within the box.\n */\n focusWithinBorder?: Property.Border<TLengthStyledSystem>;\n}\n\nconst excludedProps = [\n \"spacing\",\n \"indent\",\n \"gap\",\n \"width\",\n \"height\",\n \"overflow\",\n \"display\",\n];\n\nconst isExcludedWebUiProp = (propName: string) =>\n excludedProps.includes(propName);\n\nconst box = system({\n row: {\n property: \"flexDirection\",\n transform: (row: boolean) => (row ? \"row\" : \"column\"),\n },\n indent: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-indent\",\n transform: booleanOrNumberToNumber,\n },\n spacing: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-spacing\",\n transform: booleanOrNumberToNumber,\n },\n gap: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-gap\",\n transform: booleanOrNumberToNumber,\n },\n columnGap: {\n property: \"columnGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n rowGap: {\n property: \"rowGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n shadow: {\n property: \"boxShadow\",\n transform: (value: ShadowType) => shadows[value] ?? value,\n },\n});\n\ntype InnerProps = BoxProps & BoxShadowProps & BackgroundProps;\n\nexport const Box = styled(\"div\", {\n shouldForwardProp: (propName) =>\n typeof propName === \"string\"\n ? isExcludedWebUiProp(propName)\n ? false\n : isPropValid(propName)\n : false,\n})<InnerProps>`\n --current-spacing: 0;\n --current-indent: 0;\n --current-gap: 0;\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n ${box};\n ${background};\n ${border};\n ${borderRight};\n ${borderLeft};\n ${borderTop};\n ${borderBottom};\n ${borderColor};\n ${borderRadius};\n ${borderStyle};\n ${borderWidth};\n ${boxShadow};\n ${flexbox};\n ${overflow};\n ${position};\n ${layout};\n ${zIndex};\n ${left};\n ${right};\n ${top};\n ${bottom};\n\n gap: calc(var(--current-gap) * var(--swui-metrics-space));\n\n padding: calc(var(--current-spacing) * var(--swui-metrics-spacing))\n calc(var(--current-indent) * var(--swui-metrics-indent));\n\n :hover {\n ${({ hoverBackground }) =>\n hoverBackground ? `background: ${hoverBackground};` : \"\"}\n ${({ hoverBorder }) => (hoverBorder ? `border: ${hoverBorder};` : \"\")}\n }\n\n :focus {\n ${({ focusBackground }) =>\n focusBackground ? `background: ${focusBackground};` : \"\"}\n ${({ focusBorder }) => (focusBorder ? `border: ${focusBorder};` : \"\")}\n }\n\n :focus-within {\n ${({ focusWithinBackground }) =>\n focusWithinBackground ? `background: ${focusWithinBackground};` : \"\"}\n ${({ focusWithinBorder }) =>\n focusWithinBorder ? `border: ${focusWithinBorder};` : \"\"}\n }\n`;\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Column = forwardRef<HTMLDivElement, BoxProps>(\n function Column(props, ref) {\n return <Box ref={ref} {...props} />;\n },\n);\n","import { RefObject, useCallback, useLayoutEffect, useState } from \"react\";\n\nexport interface ElementDimensions {\n width: number;\n height: number;\n top: number;\n left: number;\n x: number;\n y: number;\n right: number;\n bottom: number;\n}\n\nexport const getDimensionObject = (node: HTMLElement): ElementDimensions => {\n const { x, y, width, height, bottom, top, left, right } =\n node.getBoundingClientRect();\n\n return {\n width,\n height,\n top,\n left,\n x,\n y,\n right,\n bottom,\n };\n};\n\nconst isEqualDimensions = (\n a: ElementDimensions,\n b: ElementDimensions,\n): boolean =>\n a.x === b.x &&\n a.y === b.y &&\n a.width === b.width &&\n a.height === b.height &&\n a.bottom === b.bottom &&\n a.top === b.top &&\n a.left === b.left &&\n a.right === b.right;\n\nexport const useElementDimensions = (\n ref: RefObject<HTMLElement | null>,\n onResizeElement?: (dimensions: ElementDimensions) => void,\n) => {\n const [dimensions, setDimensions] = useState<ElementDimensions | undefined>();\n\n const updateDimensions = useCallback(() => {\n window.requestAnimationFrame(() => {\n if (ref.current) {\n const newDimensions = getDimensionObject(ref.current);\n if (!dimensions || !isEqualDimensions(dimensions, newDimensions)) {\n if (onResizeElement) {\n onResizeElement(newDimensions);\n }\n }\n setDimensions(newDimensions);\n }\n });\n }, [ref, dimensions, setDimensions, onResizeElement]);\n\n useLayoutEffect(() => {\n updateDimensions();\n }, [updateDimensions]);\n\n return {\n dimensions,\n };\n};\n","import * as React from \"react\";\nimport { forwardRef, RefObject, useRef } from \"react\";\nimport { Box, BoxProps } from \"./Box\";\nimport {\n ElementDimensions,\n useElementDimensions,\n} from \"../../../hooks/UseElementDimensions\";\n\nexport interface ResizeAwareBoxProps extends Omit<BoxProps, \"onResize\"> {\n onResize?: (dimensions: ElementDimensions) => void;\n}\n\nexport const ResizeAwareBox = forwardRef<HTMLDivElement, ResizeAwareBoxProps>(\n function ResizeAwareBox({ onResize, ...boxProps }, ref) {\n const localRef = useRef<HTMLDivElement>(null);\n const currentRef = (ref as RefObject<HTMLDivElement>) ?? localRef;\n useElementDimensions(currentRef, onResize);\n\n return <Box {...boxProps} ref={ref} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Row = forwardRef<HTMLDivElement, BoxProps>(\n function Row(props, ref) {\n return <Box row ref={ref} {...props} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface IndentProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Indent = forwardRef<HTMLDivElement, IndentProps>(function Indent(\n { num = 1, ...props },\n ref,\n) {\n return <Box indent={num} ref={ref} {...props} />;\n});\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface SpacingProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Spacing = forwardRef<HTMLDivElement, SpacingProps>(\n function Spacing({ num = 1, ...props }, ref) {\n return <Box spacing={num} ref={ref} {...props} />;\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\n\nexport interface SpaceProps {\n half?: boolean;\n horizontal?: boolean;\n num?: number;\n vertical?: boolean;\n}\n\nconst InnerSpace = styled.div`\n --current-size: 1;\n flex: none;\n width: calc(var(--current-size) * var(--swui-metrics-space));\n height: calc(var(--current-size) * var(--swui-metrics-space));\n`;\n\nexport const Space: React.FC<SpaceProps> = ({\n half = false,\n horizontal = false,\n num = 1,\n vertical = false,\n}) => {\n const size = num * (half ? 0.5 : 1);\n\n return (\n <InnerSpace\n style={{\n [\"--current-size\" as string]: size,\n height: horizontal ? 1 : undefined,\n width: vertical ? 1 : undefined,\n }}\n />\n );\n};\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\n\ninterface Props {\n nest?: boolean;\n render: (children: ReactNode) => ReactNode;\n children?: ReactNode;\n}\n\nexport const Nest: React.FC<Props> = ({ children, nest, render }) => {\n if (nest) {\n return <>{render(children)}</>;\n }\n return <>{children}</>;\n};\n","import { pickBy } from \"lodash-es\";\n\nexport const getDataProps = <T extends Record<string, unknown>>(\n props: Record<string, unknown> | object,\n): T => pickBy(props, isDataPropMapper) as T;\n\nconst isDataPropMapper = (_: unknown, key: string): boolean => isDataProp(key);\n\nconst isDataProp = <TProp extends string>(propName: TProp): boolean =>\n propName.startsWith(\"data-\") || propName.startsWith(\"aria-\");\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\nimport styles from \"./ScreenReaderOnlyText.module.css\";\nimport { getDataProps } from \"../../utils/PropsForwarder\";\n\nexport interface ScreenReaderOnlyTextProps {\n children?: ReactNode;\n}\n\nexport const ScreenReaderOnlyText: React.FC<ScreenReaderOnlyTextProps> = ({\n children,\n ...props\n}) => {\n return (\n <span className={styles.visuallyHidden} {...getDataProps(props)}>\n {children}\n </span>\n );\n};\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport cx from \"classnames\";\nimport styles from \"./Text.module.css\";\nimport { SpanProps } from \"../../types/ElementProps\";\nimport { Property } from \"csstype\";\n\nexport interface TextProps extends SpanProps {\n variant?: TextVariant;\n size?: TextSize;\n userSelect?: Property.UserSelect;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n textAlign?: Property.TextAlign;\n overflow?: Property.Overflow;\n textOverflow?: Property.TextOverflow;\n color?: string;\n}\n\nexport type TextVariant = \"standard\" | \"caption\" | \"overline\" | \"bold\";\nexport type TextSize = \"large\" | \"medium\" | \"small\" | \"smaller\";\n\nexport const Text = forwardRef<HTMLSpanElement, TextProps>(\n (\n {\n children,\n variant = \"standard\",\n size = \"medium\",\n className,\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n overflow,\n textOverflow,\n style,\n ...spanProps\n },\n ref,\n ) => {\n return (\n <span\n className={cx(styles.text, styles[variant], styles[size], className)}\n ref={ref}\n style={{\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n overflow,\n textOverflow,\n ...style,\n }}\n {...spanProps}\n >\n {children}\n </span>\n );\n },\n);\n\nexport const Txt = Text;\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"small\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallerText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"smaller\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const StandardText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"medium\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const LargeText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"large\"} {...props} />;\n};\n","import cx from \"classnames\";\nimport { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { H1Props } from \"../../types/ElementProps\";\nimport styles from \"./Heading.module.css\";\n\nexport interface HeadingProps extends H1Props {\n variant?: HeadingVariant;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n as?: HeadingVariant;\n}\n\nexport type HeadingVariant = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\nexport const Heading = forwardRef<HTMLHeadingElement, HeadingProps>(\n (\n {\n variant = \"h3\",\n className,\n color,\n whiteSpace,\n wordBreak,\n style,\n children,\n as,\n ...hProps\n },\n ref,\n ) => {\n const Element = as ?? variant;\n return (\n <Element\n className={cx(styles.heading, styles[variant], className)}\n style={{ color, whiteSpace, wordBreak, ...style }}\n ref={ref}\n {...hProps}\n >\n {children}\n </Element>\n );\n },\n);\n","import * as React from \"react\";\nimport { Heading, HeadingProps } from \"../heading/Heading\";\n\n/**\n * @deprecated Please use `Heading` instead.\n */\nexport const HeaderText: React.FC<Omit<HeadingProps, \"variant\">> = (props) => {\n return <Heading variant={\"h2\"} {...props} />;\n};\n","import { useCallback } from \"react\";\n\ntype ArrayItemEqualsComparator<T> = (a: T, b: T) => boolean;\n\nconst defaultComparator = <T>(a: T, b: T) => a === b;\n\nexport const useArraySet = <T>(\n list: Array<T>,\n setList: (list: Array<T>) => void,\n comparator: ArrayItemEqualsComparator<T> = defaultComparator,\n) => {\n const add = useCallback(\n (item: T) => {\n if (!list.some((l) => comparator(l, item))) {\n setList([...list, item]);\n }\n },\n [list, setList, comparator],\n );\n\n const addMultiple = useCallback(\n (items: Array<T>) => {\n setList(\n items.reduce((list, item) => {\n if (!list.some((l) => comparator(l, item))) {\n return [...list, item];\n }\n return list;\n }, list),\n );\n },\n [list, setList, comparator],\n );\n\n const remove = useCallback(\n (item: T) => {\n const index = list.findIndex((l) => comparator(l, item));\n if (index >= 0) {\n setList(list.filter((_, i) => i !== index));\n }\n },\n [list, setList, comparator],\n );\n\n const removeMultiple = useCallback(\n (items: Array<T>) => {\n setList(list.filter((item) => !items.some((l) => comparator(l, item))));\n },\n [list, setList, comparator],\n );\n\n const toggle = useCallback(\n (item: T) => {\n const found = list.some((l) => comparator(l, item));\n if (found) {\n remove(item);\n } else {\n add(item);\n }\n },\n [list, add, remove, comparator],\n );\n\n return {\n add,\n addMultiple,\n remove,\n removeMultiple,\n toggle,\n };\n};\n","import { useCallback, useState } from \"react\";\n\ntype Value = boolean;\ntype SetTrue = () => void;\ntype SetFalse = () => void;\ntype ToggleValue = () => void;\ntype BooleanHook = [Value, SetTrue, SetFalse, ToggleValue];\n\nexport const useBoolean = (initialValue: Value): BooleanHook => {\n const [value, setValue] = useState(initialValue);\n\n const setTrue = useCallback(() => {\n setValue(true);\n }, [setValue]);\n\n const setFalse = useCallback(() => {\n setValue(false);\n }, [setValue]);\n\n const toggle = useCallback(() => {\n setValue((v) => !v);\n }, [setValue]);\n\n return [value, setTrue, setFalse, toggle];\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDebounce = <T>(value: T, delay: number): T => {\n // State and setters for debounced value\n const [debouncedValue, setDebouncedValue] = useState<T>(value);\n\n useEffect(() => {\n // Update debounced value after delay\n const handler = setTimeout(() => {\n setDebouncedValue(value);\n }, delay);\n\n // Cancel the timeout if value changes (also on delay change or unmount)\n // This is how we prevent debounced value from updating if value is changed ...\n // .. within the delay period. Timeout gets cleared and restarted.\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]); // Only re-call effect if value or delay changes\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDelayedFalse = (value: boolean, delay: number) => {\n const [debouncedValue, setDebouncedValue] = useState<boolean>(value);\n\n useEffect(() => {\n if (value) {\n setDebouncedValue(true);\n }\n\n const handler = setTimeout(() => {\n if (!value) {\n setDebouncedValue(value);\n }\n }, delay);\n\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]);\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nlet id = 0;\nconst genId = (componentName?: string) =>\n `webui-${componentName ? componentName + \"-\" : \"\"}${++id}`;\n\n/** @deprecated use useId-hook from React 18 */\nexport const useDomId = (componentName?: string): string => {\n const [id, setId] = useState<string | null>(() => genId(componentName));\n useEffect(() => setId(genId(componentName)), [componentName]);\n return id!;\n};\n","import { RefObject, useEffect, useRef } from \"react\";\n\ntype EventHandler<TEventName extends keyof HTMLElementEventMap> = (\n event: HTMLElementEventMap[TEventName],\n) => void;\n\nexport const useEventListener = <TEventName extends keyof HTMLElementEventMap>(\n ref: RefObject<HTMLElement | null>,\n eventName: TEventName,\n handler: EventHandler<TEventName>,\n) => {\n // Create a ref that stores handler\n const savedHandler = useRef<EventHandler<TEventName>>(null);\n\n // Update ref.current value if handler changes.\n // This allows our effect below to always get latest handler ...\n // ... without us needing to pass it in effect deps array ...\n // ... and potentially cause effect to re-run every render.\n useEffect(() => {\n savedHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n // Make sure element supports addEventListener\n const isSupported = ref.current && ref.current.addEventListener;\n if (!isSupported) return;\n\n // Create event listener that calls handler function stored in ref\n const eventListener: EventHandler<TEventName> = (event) => {\n if (savedHandler.current) {\n return savedHandler.current(event);\n }\n };\n\n // Add event listener\n if (!ref.current) {\n return;\n }\n\n const element = ref.current;\n element.addEventListener(eventName, eventListener);\n\n // Remove event listener on cleanup\n return () => {\n if (element) {\n element.removeEventListener(eventName, eventListener);\n }\n };\n }, [eventName, ref]); // Re-run if eventName or element changes\n};\n","import { RefObject, useCallback, useEffect } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useElementFocus = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [isInFocus, setIsInFocus, setIsNotInFocus] = useBoolean(false);\n\n useEffect(() => {\n if (document.activeElement === ref.current) {\n setIsInFocus();\n } else {\n setIsNotInFocus();\n }\n }, [ref, setIsNotInFocus, setIsInFocus]);\n\n useEventListener(ref, \"focus\", setIsInFocus);\n useEventListener(ref, \"blur\", setIsNotInFocus);\n\n const focus = useCallback(() => {\n if (ref.current) {\n ref.current.focus();\n }\n }, [ref]);\n\n const blur = useCallback(() => {\n if (ref.current) {\n ref.current.blur();\n }\n }, [ref]);\n\n return { isInFocus, focus, blur };\n};\n","import { useCallback, useLayoutEffect, useRef } from \"react\";\n\ntype Fn<ARGS extends unknown[], R> = (...args: ARGS) => R;\n\nexport const useEventCallback = <A extends unknown[], R>(\n fn: Fn<A, R>,\n): Fn<A, R> => {\n const ref = useRef<Fn<A, R>>(fn);\n useLayoutEffect(() => {\n ref.current = fn;\n });\n return useCallback((...args: A): R => {\n const { current } = ref;\n return current(...args);\n }, []);\n};\n","import React, { MutableRefObject } from \"react\";\n\nexport const useLatest = <T>(value: T): MutableRefObject<T> => {\n const ref = React.useRef(value);\n ref.current = value;\n return ref;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsOver = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsOver, setMouseIsOver, setMouseIsNotOver] = useBoolean(false);\n\n useEventListener(ref, \"mouseover\", setMouseIsOver);\n useEventListener(ref, \"mouseout\", setMouseIsNotOver);\n\n return mouseIsOver;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsEntered = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsEntered, setMouseIsEntered, setMouseIsNotEntered] =\n useBoolean(false);\n\n useEventListener(ref, \"mouseenter\", setMouseIsEntered);\n useEventListener(ref, \"mouseleave\", setMouseIsNotEntered);\n\n return mouseIsEntered;\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useMultiOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n refs: Array<React.RefObject<any>>,\n handler: (event: TouchEvent | MouseEvent) => void,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n\n const allNotContains = refs\n .filter((ref) => ref.current)\n .every((ref) => {\n return ref.current && !ref.current.contains(event.target);\n });\n\n if (!allNotContains) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener);\n document.addEventListener(\"touchstart\", listener);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener);\n document.removeEventListener(\"touchstart\", listener);\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [...refs]);\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ref: React.RefObject<any>,\n handler: (event: TouchEvent | MouseEvent) => void,\n options?: AddEventListenerOptions,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n if (!ref.current || ref.current.contains(event.target)) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener, options);\n document.addEventListener(\"touchstart\", listener, options);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener, options);\n document.removeEventListener(\"touchstart\", listener, options);\n };\n }, [ref, options]);\n};\n","import { debounce } from \"lodash-es\";\nimport { useEffect, useRef } from \"react\";\n\nconst events = [\"mousemove\", \"mousedown\", \"keydown\", \"touchstart\", \"scroll\"];\n\nexport const useOnNoMouseMovement = (callback: () => void, delay: number) => {\n const eventHandler = useRef<(event: Event) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = callback;\n }, [callback]);\n\n useEffect(() => {\n const onIdleChange = debounce(eventHandler.current, delay);\n events.forEach((event) => window.addEventListener(event, onIdleChange));\n\n return () => {\n events.forEach((event) =>\n window.removeEventListener(event, onIdleChange),\n );\n };\n }, [delay]);\n};\n","import { RefObject, useEffect, useMemo, useState } from \"react\";\n\nexport const useOnScreen = (\n ref: RefObject<Element | null>,\n options?: IntersectionObserverInit,\n) => {\n const [isVisible, setIsVisible] = useState(false);\n\n const { rootMargin, root, threshold } = options || {};\n\n const observer = useMemo(() => {\n return new IntersectionObserver(\n ([entry]) => setIsVisible(entry.isIntersecting),\n {\n rootMargin,\n root,\n threshold,\n },\n );\n }, [setIsVisible, rootMargin, root, threshold]);\n\n useEffect(() => {\n if (ref.current) {\n observer.observe(ref.current);\n }\n return () => {\n observer.disconnect();\n };\n }, [observer, ref]);\n\n return isVisible;\n};\n","import {\n MutableRefObject,\n RefCallback,\n RefObject,\n useEffect,\n useRef,\n} from \"react\";\n\nexport const useForwardedRef = <T>(\n ref: RefCallback<T> | MutableRefObject<T> | null,\n): RefObject<NonNullable<T>> => {\n const innerRef = useRef<T>(null) as MutableRefObject<NonNullable<T>>;\n\n useEffect(() => {\n if (!ref) return;\n if (typeof ref === \"function\") {\n ref(innerRef.current);\n } else {\n ref.current = innerRef.current;\n }\n });\n\n return innerRef;\n};\n","import { useCallback, useEffect, useRef, useState } from \"react\";\n\nexport const useTimeoutState = <S>(\n initialValue: S,\n defaultTimeout: number,\n clearTimeoutOnSetValue = true,\n): [S, (v: S) => void] => {\n const [value, setValue] = useState<S>(initialValue);\n const timeoutRef = useRef<NodeJS.Timeout>(null);\n\n const wrappedSetter = useCallback(\n (newValue: S, timeout = defaultTimeout) => {\n setValue(newValue);\n if (clearTimeoutOnSetValue) {\n clearTimeout(timeoutRef.current!);\n }\n timeoutRef.current = setTimeout(() => setValue(initialValue), timeout);\n },\n [defaultTimeout, clearTimeoutOnSetValue, initialValue],\n );\n\n useEffect(() => {\n return () => {\n clearTimeout(timeoutRef.current!);\n };\n }, []);\n\n return [value, wrappedSetter];\n};\n","import { useMemo } from \"react\";\n\nexport const useToday = () => {\n return useMemo(() => new Date(), []);\n};\n","export const byStringField =\n <T>(fieldResolver: (item: T) => string) =>\n (a: T, b: T): number =>\n fieldResolver(a).localeCompare(fieldResolver(b));\n\nexport const byNumberField =\n <T>(fieldResolver: (item: T) => number) =>\n (a: T, b: T): number =>\n fieldResolver(a) - fieldResolver(b);\n","export const exhaustSwitchCaseElseThrow = (arg: never) => {\n throw new Error(`Switch unhandled case: ${arg}`);\n};\n\nexport const exhaustSwitchCase = <T>(_arg: never, fallback: T) => {\n return fallback;\n};\n","export const truthyKeysAsList = (r: Record<string, boolean>): Array<string> =>\n Object.keys(r).filter((key) => r[key]);\n","export const parseFloatElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseFloat(s);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n\nexport const parseIntElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseInt(s, 10);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n","export function invariant<T>(\n val: T | null | undefined,\n message: string,\n): asserts val is T {\n if (val == null) {\n throw new Error(\"Invariant error: \" + message);\n }\n}\n"],"names":["SeparatorLine","forwardRef","color","cssColor","size","width","vertical","ref","jsx","styles","ClickableElement","styled","background","pointer","props","hoverBackground","disableOpacityOnClick","disableFocusHighlight","focusBackground","height","borderRadius","Clickable","onClick","onDblClick","tooltip","disablePointer","opacityOnHover","disabled","children","type","restProps","booleanOrNumberToNumber","num","numberToMetricCalc","booleanOrNumberToMetricCalc","validPropsRecord","validProps","r","isPropValid","memoize","prop","shadows","excludedProps","isExcludedWebUiProp","propName","box","system","row","value","Box","border","borderRight","borderLeft","borderTop","borderBottom","borderColor","borderStyle","borderWidth","boxShadow","flexbox","overflow","position","layout","zIndex","left","right","top","bottom","hoverBorder","focusBorder","focusWithinBackground","focusWithinBorder","Column","getDimensionObject","node","x","y","isEqualDimensions","a","b","useElementDimensions","onResizeElement","dimensions","setDimensions","useState","updateDimensions","useCallback","newDimensions","useLayoutEffect","ResizeAwareBox","onResize","boxProps","localRef","useRef","Row","Indent","Spacing","InnerSpace","Space","half","horizontal","Nest","nest","render","Fragment","getDataProps","pickBy","isDataPropMapper","_","key","isDataProp","ScreenReaderOnlyText","Text","variant","className","userSelect","whiteSpace","wordBreak","textAlign","textOverflow","style","spanProps","cx","Txt","SmallText","SmallerText","StandardText","LargeText","Heading","as","hProps","HeaderText","defaultComparator","useArraySet","list","setList","comparator","add","item","addMultiple","items","l","remove","index","i","removeMultiple","toggle","useBoolean","initialValue","setValue","setTrue","setFalse","v","useDebounce","delay","debouncedValue","setDebouncedValue","useEffect","handler","useDelayedFalse","id","genId","componentName","useDomId","setId","useEventListener","eventName","savedHandler","eventListener","event","element","useElementFocus","isInFocus","setIsInFocus","setIsNotInFocus","focus","blur","useEventCallback","fn","args","current","useLatest","React","useMouseIsOver","mouseIsOver","setMouseIsOver","setMouseIsNotOver","useMouseIsEntered","mouseIsEntered","setMouseIsEntered","setMouseIsNotEntered","useMultiOnClickOutside","refs","eventHandler","listener","useOnClickOutside","options","events","useOnNoMouseMovement","callback","onIdleChange","debounce","useOnScreen","isVisible","setIsVisible","rootMargin","root","threshold","observer","useMemo","entry","useForwardedRef","innerRef","useTimeoutState","defaultTimeout","clearTimeoutOnSetValue","timeoutRef","wrappedSetter","newValue","timeout","useToday","byStringField","fieldResolver","byNumberField","exhaustSwitchCaseElseThrow","arg","exhaustSwitchCase","_arg","fallback","truthyKeysAsList","parseFloatElseUndefined","s","f","parseIntElseUndefined","invariant","val","message"],"mappings":";;;;;;;;;GAaaA,KAAgBC;AAAA,EAC3B,CACE;AAAA,IACE,OAAAC,IAAQC,EAAS,qBAAqB;AAAA,IACtC,MAAAC,IAAO;AAAA,IACP,OAAAC,IAAQ;AAAA,IACR,UAAAC,IAAW;AAAA,KAEbC,MAGE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC,GAAO;AAAA,MAClB,eAAa;AAAA,MACb,OAAAP;AAAA,MACA,OAAO;AAAA,QACL,iBAAiBA;AAAA,QACjB,QAAQI,IAAWF,KAAQ,SAASC,KAAS;AAAA,QAC7C,OAAOC,IAAWD,KAAS,QAAQD,KAAQ;AAAA,MAC7C;AAAA,MACA,KAAAG;AAAA,IAAA;AAAA,EACF;AAGN,GC0BMG,KAAmBC,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA,gBAKhB,CAAC,EAAE,YAAAC,EAAW,MAAMA,CAAU;AAAA,IAC1C,CAAC,EAAE,SAAAC,EAAA,MAAeA,IAAU,qBAAqB,EAAG;AAAA;AAAA;AAAA,MAGlD,CAACC,MAAWA,EAAM,iBAAiB,kBAAkB,EAAG;AAAA,MACxD,CAAC,EAAE,iBAAAC,EAAsB,MAAA,eAAeA,CAAe,GAAG;AAAA;AAAA;AAAA,MAG1D,CAAC,EAAE,uBAAAC,EAAA,MACFA,IAA0C,KAAlB,eAAoB;AAAA;AAAA;AAAA;AAA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D;AAEA,SAAAS,EAAU,MACD,MAAM;AACX,iBAAa2D,EAAW,OAAQ;AAAA,EAClC,GACC,EAAE,GAEE,CAACxK,GAAOyK,CAAa;AAC9B,GC1BaG,KAAW,MACfX,EAAQ,MAAM,oBAAI,KAAK,GAAG,CAAA,CAAE,GCHxBY,KACX,CAAIC,MACJ,CAAChJ,GAAMC,MACL+I,EAAchJ,CAAC,EAAE,cAAcgJ,EAAc/I,CAAC,CAAC,GAEtCgJ,KACX,CAAID,MACJ,CAAChJ,GAAMC,MACL+I,EAAchJ,CAAC,IAAIgJ,EAAc/I,CAAC,GCRzBiJ,KAA6B,CAACC,MAAe;AACxD,QAAM,IAAI,MAAM,0BAA0BA,CAAG,EAAE;AACjD,GAEaC,KAAoB,CAAIC,GAAaC,MACzCA,GCLIC,KAAmB,CAAChM,MAC/B,OAAO,KAAKA,CAAC,EAAE,OAAO,CAACwE,MAAQxE,EAAEwE,CAAG,CAAC,GCD1ByH,KAA0B,CAACC,MAAkC;AACpE,MAAA;AACI,UAAAC,IAAI,WAAWD,CAAC;AAItB,WAHI,MAAMC,CAAC,KAGPA,KAAK,OACA,SAEFA;AAAA,EAAA,QACD;AAAA,EAAA;AAIV,GAEaC,KAAwB,CAACF,MAAkC;AAClE,MAAA;AACI,UAAAC,IAAI,SAASD,GAAG,EAAE;AAIxB,WAHI,MAAMC,CAAC,KAGPA,KAAK,OACA,SAEFA;AAAA,EAAA,QACD;AAAA,EAAA;AAIV;AC9BgB,SAAAE,GACdC,GACAC,GACkB;AAClB,MAAID,KAAO;AACH,UAAA,IAAI,MAAM,sBAAsBC,CAAO;AAEjD;"}
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode("._separatorLine_nzfcz_1{display:flex;border:0;margin:0;flex:none}._visuallyHidden_1gevf_1{border:0;clip:rect(0 0 0 0);height:1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}._text_1iisw_1{--swui-text-color: var(--swui-text-primary-color);--swui-text-color-caption: var(--lhds-color-ui-600);--swui-text-color-overline: var(--lhds-color-ui-600);--swui-text-font-family: var(--swui-font-primary);--swui-text-font-weight: var(--swui-font-weight-text);--current-color: var(--swui-text-color);--current-font-size: var(--swui-font-size-medium);--current-line-height: var(--swui-line-height-medium);--current-font-weight: var(--swui-text-font-weight);--current-letter-spacing: var(--swui-text-letter-spacing);font-size:var(--current-font-size);line-height:var(--current-line-height);color:var(--current-color);letter-spacing:var(--current-letter-spacing);font-family:var(--swui-text-font-family);font-weight:var(--current-font-weight)}._text_1iisw_1._bold_1iisw_27{--current-font-weight: var(--swui-font-weight-text-bold)}._text_1iisw_1._caption_1iisw_31{--current-font-size: var(--swui-font-size-small);--current-line-height: var(--swui-line-height-small);--current-color: var(--swui-text-color-caption);--current-letter-spacing: 0;font-style:italic}._text_1iisw_1._overline_1iisw_39{--current-font-size: var(--swui-font-size-smaller);--current-line-height: var(--swui-line-height-smaller);--current-color: var(--swui-text-color-overline);--current-font-weight: var(--swui-font-weight-text-bold);--current-letter-spacing: .1rem;text-transform:uppercase}._text_1iisw_1._large_1iisw_48{--current-font-size: var(--swui-font-size-large);--current-line-height: var(--swui-line-height-large)}._text_1iisw_1._medium_1iisw_53{--current-font-size: var(--swui-font-size-medium);--current-line-height: var(--swui-line-height-medium)}._text_1iisw_1._small_1iisw_58{--current-font-size: var(--swui-font-size-small);--current-line-height: var(--swui-line-height-small)}._text_1iisw_1._smaller_1iisw_63{--current-font-size: var(--swui-font-size-smaller);--current-line-height: var(--swui-line-height-smaller)}._heading_1cnsg_1{font-size:2rem;color:var(--swui-text-primary-color);letter-spacing:0;margin:0;line-height:var(--swui-line-height);font-family:var(--swui-font-primary);font-weight:var(--swui-font-weight-text-bold)}._heading_1cnsg_1._h1_1cnsg_10{font-size:2.8rem}._heading_1cnsg_1._h2_1cnsg_14{font-size:2.4rem}._heading_1cnsg_1._h3_1cnsg_18{font-size:2rem}._heading_1cnsg_1._h4_1cnsg_22{font-size:1.8rem}._heading_1cnsg_1._h5_1cnsg_26{font-size:1.6rem}._heading_1cnsg_1._h6_1cnsg_30{font-size:1.4rem}")),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}})();
2
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const P=require("@stenajs-webui/theme"),l=require("react/jsx-runtime"),n=require("react"),w=require("@emotion/styled"),c=require("styled-system"),k=require("lodash-es"),_=require("classnames"),F="_separatorLine_nzfcz_1",j={separatorLine:F},H=n.forwardRef(({color:e=P.cssColor("--lhds-color-ui-300"),size:t="100%",width:r="1px",vertical:u=!1},s)=>l.jsx("hr",{className:j.separatorLine,"aria-hidden":!0,color:e,style:{backgroundColor:e,height:u?t||"100%":r||"1px",width:u?r||"1px":t||"100%"},ref:s})),z=w.button`
2
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const P=require("@stenajs-webui/theme"),l=require("react/jsx-runtime"),n=require("react"),S=require("@emotion/styled"),c=require("styled-system"),E=require("lodash-es"),R=require("classnames"),F="_separatorLine_nzfcz_1",j={separatorLine:F},H=n.forwardRef(({color:e=P.cssColor("--lhds-color-ui-300"),size:t="100%",width:r="1px",vertical:u=!1},s)=>l.jsx("hr",{className:j.separatorLine,"aria-hidden":!0,color:e,style:{backgroundColor:e,height:u?t||"100%":r||"1px",width:u?r||"1px":t||"100%"},ref:s})),z=S.button`
3
3
  display: inline-block;
4
4
  user-select: none;
5
5
  border: 0;
@@ -22,7 +22,7 @@
22
22
  ${({width:e})=>e?`width: ${e};`:""}
23
23
  ${({height:e})=>e?`height: ${e};`:""}
24
24
  ${({borderRadius:e})=>e?`border-radius: ${e};`:""}
25
- `,N=n.forwardRef(({disableFocusHighlight:e,onClick:t,onDblClick:r,tooltip:u,disableOpacityOnClick:s,disablePointer:o,opacityOnHover:i,disabled:d,children:a,background:f="transparent",hoverBackground:p,focusBackground:m,type:L="button",...M},A)=>{const D=!!(t||r);return l.jsx(z,{opacityOnHover:i,title:u,disabled:d,disableOpacityOnClick:s,onClick:t,onDoubleClick:r,disableFocusHighlight:e,pointer:D&&!o,ref:A,background:f,hoverBackground:p,focusBackground:m,type:L,...M,children:a})}),y=e=>e==null?0:typeof e=="boolean"?e?1:0:e,q=e=>{if(e!==0)return`calc(${e} * var(--swui-metrics-space))`},S=e=>q(y(e)),U={children:!0,dangerouslySetInnerHTML:!0,key:!0,ref:!0,autoFocus:!0,defaultValue:!0,defaultChecked:!0,innerHTML:!0,suppressContentEditableWarning:!0,suppressHydrationWarning:!0,valueLink:!0,abbr:!0,accept:!0,acceptCharset:!0,accessKey:!0,action:!0,allow:!0,allowUserMedia:!0,allowPaymentRequest:!0,allowFullScreen:!0,allowTransparency:!0,alt:!0,async:!0,autoComplete:!0,autoPlay:!0,capture:!0,cellPadding:!0,cellSpacing:!0,challenge:!0,charSet:!0,checked:!0,cite:!0,classID:!0,className:!0,cols:!0,colSpan:!0,content:!0,contentEditable:!0,contextMenu:!0,controls:!0,controlsList:!0,coords:!0,crossOrigin:!0,data:!0,dateTime:!0,decoding:!0,default:!0,defer:!0,dir:!0,disabled:!0,disablePictureInPicture:!0,disableRemotePlayback:!0,download:!0,draggable:!0,encType:!0,enterKeyHint:!0,form:!0,formAction:!0,formEncType:!0,formMethod:!0,formNoValidate:!0,formTarget:!0,frameBorder:!0,headers:!0,height:!0,hidden:!0,high:!0,href:!0,hrefLang:!0,htmlFor:!0,httpEquiv:!0,id:!0,inputMode:!0,integrity:!0,is:!0,keyParams:!0,keyType:!0,kind:!0,label:!0,lang:!0,list:!0,loading:!0,loop:!0,low:!0,marginHeight:!0,marginWidth:!0,max:!0,maxLength:!0,media:!0,mediaGroup:!0,method:!0,min:!0,minLength:!0,multiple:!0,muted:!0,name:!0,nonce:!0,noValidate:!0,open:!0,optimum:!0,pattern:!0,placeholder:!0,playsInline:!0,poster:!0,preload:!0,profile:!0,radioGroup:!0,readOnly:!0,referrerPolicy:!0,rel:!0,required:!0,reversed:!0,role:!0,rows:!0,rowSpan:!0,sandbox:!0,scope:!0,scoped:!0,scrolling:!0,seamless:!0,selected:!0,shape:!0,size:!0,sizes:!0,slot:!0,span:!0,spellCheck:!0,src:!0,srcDoc:!0,srcLang:!0,srcSet:!0,start:!0,step:!0,style:!0,summary:!0,tabIndex:!0,target:!0,title:!0,translate:!0,type:!0,useMap:!0,value:!0,width:!0,wmode:!0,wrap:!0,about:!0,datatype:!0,inlist:!0,prefix:!0,property:!0,resource:!0,typeof:!0,vocab:!0,autoCapitalize:!0,autoCorrect:!0,autoSave:!0,color:!0,incremental:!0,fallback:!0,inert:!0,itemProp:!0,itemScope:!0,itemType:!0,itemID:!0,itemRef:!0,on:!0,option:!0,results:!0,security:!0,unselectable:!0,accentHeight:!0,accumulate:!0,additive:!0,alignmentBaseline:!0,allowReorder:!0,alphabetic:!0,amplitude:!0,arabicForm:!0,ascent:!0,attributeName:!0,attributeType:!0,autoReverse:!0,azimuth:!0,baseFrequency:!0,baselineShift:!0,baseProfile:!0,bbox:!0,begin:!0,bias:!0,by:!0,calcMode:!0,capHeight:!0,clip:!0,clipPathUnits:!0,clipPath:!0,clipRule:!0,colorInterpolation:!0,colorInterpolationFilters:!0,colorProfile:!0,colorRendering:!0,contentScriptType:!0,contentStyleType:!0,cursor:!0,cx:!0,cy:!0,d:!0,decelerate:!0,descent:!0,diffuseConstant:!0,direction:!0,display:!0,divisor:!0,dominantBaseline:!0,dur:!0,dx:!0,dy:!0,edgeMode:!0,elevation:!0,enableBackground:!0,end:!0,exponent:!0,externalResourcesRequired:!0,fill:!0,fillOpacity:!0,fillRule:!0,filter:!0,filterRes:!0,filterUnits:!0,floodColor:!0,floodOpacity:!0,focusable:!0,fontFamily:!0,fontSize:!0,fontSizeAdjust:!0,fontStretch:!0,fontStyle:!0,fontVariant:!0,fontWeight:!0,format:!0,from:!0,fr:!0,fx:!0,fy:!0,g1:!0,g2:!0,glyphName:!0,glyphOrientationHorizontal:!0,glyphOrientationVertical:!0,glyphRef:!0,gradientTransform:!0,gradientUnits:!0,hanging:!0,horizAdvX:!0,horizOriginX:!0,ideographic:!0,imageRendering:!0,in:!0,in2:!0,intercept:!0,k:!0,k1:!0,k2:!0,k3:!0,k4:!0,kernelMatrix:!0,kernelUnitLength:!0,kerning:!0,keyPoints:!0,keySplines:!0,keyTimes:!0,lengthAdjust:!0,letterSpacing:!0,lightingColor:!0,limitingConeAngle:!0,local:!0,markerEnd:!0,markerMid:!0,markerStart:!0,markerHeight:!0,markerUnits:!0,markerWidth:!0,mask:!0,maskContentUnits:!0,maskUnits:!0,mathematical:!0,mode:!0,numOctaves:!0,offset:!0,opacity:!0,operator:!0,order:!0,orient:!0,orientation:!0,origin:!0,overflow:!0,overlinePosition:!0,overlineThickness:!0,panose1:!0,paintOrder:!0,pathLength:!0,patternContentUnits:!0,patternTransform:!0,patternUnits:!0,pointerEvents:!0,points:!0,pointsAtX:!0,pointsAtY:!0,pointsAtZ:!0,preserveAlpha:!0,preserveAspectRatio:!0,primitiveUnits:!0,r:!0,radius:!0,refX:!0,refY:!0,renderingIntent:!0,repeatCount:!0,repeatDur:!0,requiredExtensions:!0,requiredFeatures:!0,restart:!0,result:!0,rotate:!0,rx:!0,ry:!0,scale:!0,seed:!0,shapeRendering:!0,slope:!0,spacing:!0,specularConstant:!0,specularExponent:!0,speed:!0,spreadMethod:!0,startOffset:!0,stdDeviation:!0,stemh:!0,stemv:!0,stitchTiles:!0,stopColor:!0,stopOpacity:!0,strikethroughPosition:!0,strikethroughThickness:!0,string:!0,stroke:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeLinecap:!0,strokeLinejoin:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0,surfaceScale:!0,systemLanguage:!0,tableValues:!0,targetX:!0,targetY:!0,textAnchor:!0,textDecoration:!0,textRendering:!0,textLength:!0,to:!0,transform:!0,u1:!0,u2:!0,underlinePosition:!0,underlineThickness:!0,unicode:!0,unicodeBidi:!0,unicodeRange:!0,unitsPerEm:!0,vAlphabetic:!0,vHanging:!0,vIdeographic:!0,vMathematical:!0,values:!0,vectorEffect:!0,version:!0,vertAdvY:!0,vertOriginX:!0,vertOriginY:!0,viewBox:!0,viewTarget:!0,visibility:!0,widths:!0,wordSpacing:!0,writingMode:!0,x:!0,xHeight:!0,x1:!0,x2:!0,xChannelSelector:!0,xlinkActuate:!0,xlinkArcrole:!0,xlinkHref:!0,xlinkRole:!0,xlinkShow:!0,xlinkTitle:!0,xlinkType:!0,xmlBase:!0,xmlns:!0,xmlnsXlink:!0,xmlLang:!0,xmlSpace:!0,y:!0,y1:!0,y2:!0,yChannelSelector:!0,z:!0,zoomAndPan:!0,for:!0,class:!0,autofocus:!0},V=`^((${Object.keys(U).join("|")})|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$`,B=new RegExp(V),W=k.memoize(e=>B.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91),X={box:"var(--swui-shadow-box)",popover:"var(--swui-shadow-popover)",modal:"var(--swui-shadow-modal)",bottom:"var(--swui-shadow-bottom)"},G=["spacing","indent","gap","width","height","overflow","display"],Y=e=>G.includes(e),K=c.system({row:{property:"flexDirection",transform:e=>e?"row":"column"},indent:{property:"--current-indent",transform:y},spacing:{property:"--current-spacing",transform:y},gap:{property:"--current-gap",transform:y},columnGap:{property:"columnGap",transform:S},rowGap:{property:"rowGap",transform:S},shadow:{property:"boxShadow",transform:e=>X[e]??e}}),g=w("div",{shouldForwardProp:e=>typeof e=="string"?Y(e)?!1:W(e):!1})`
25
+ `,N=n.forwardRef(({disableFocusHighlight:e,onClick:t,onDblClick:r,tooltip:u,disableOpacityOnClick:s,disablePointer:o,opacityOnHover:i,disabled:d,children:a,background:f="transparent",hoverBackground:p,focusBackground:m,type:v="button",...w},A)=>{const D=!!(t||r);return l.jsx(z,{opacityOnHover:i,title:u,disabled:d,disableOpacityOnClick:s,onClick:t,onDoubleClick:r,disableFocusHighlight:e,pointer:D&&!o,ref:A,background:f,hoverBackground:p,focusBackground:m,type:v,...w,children:a})}),y=e=>e==null?0:typeof e=="boolean"?e?1:0:e,q=e=>{if(e!==0)return`calc(${e} * var(--swui-metrics-space))`},C=e=>q(y(e)),U={children:!0,dangerouslySetInnerHTML:!0,key:!0,ref:!0,autoFocus:!0,defaultValue:!0,defaultChecked:!0,innerHTML:!0,suppressContentEditableWarning:!0,suppressHydrationWarning:!0,valueLink:!0,abbr:!0,accept:!0,acceptCharset:!0,accessKey:!0,action:!0,allow:!0,allowUserMedia:!0,allowPaymentRequest:!0,allowFullScreen:!0,allowTransparency:!0,alt:!0,async:!0,autoComplete:!0,autoPlay:!0,capture:!0,cellPadding:!0,cellSpacing:!0,challenge:!0,charSet:!0,checked:!0,cite:!0,classID:!0,className:!0,cols:!0,colSpan:!0,content:!0,contentEditable:!0,contextMenu:!0,controls:!0,controlsList:!0,coords:!0,crossOrigin:!0,data:!0,dateTime:!0,decoding:!0,default:!0,defer:!0,dir:!0,disabled:!0,disablePictureInPicture:!0,disableRemotePlayback:!0,download:!0,draggable:!0,encType:!0,enterKeyHint:!0,form:!0,formAction:!0,formEncType:!0,formMethod:!0,formNoValidate:!0,formTarget:!0,frameBorder:!0,headers:!0,height:!0,hidden:!0,high:!0,href:!0,hrefLang:!0,htmlFor:!0,httpEquiv:!0,id:!0,inputMode:!0,integrity:!0,is:!0,keyParams:!0,keyType:!0,kind:!0,label:!0,lang:!0,list:!0,loading:!0,loop:!0,low:!0,marginHeight:!0,marginWidth:!0,max:!0,maxLength:!0,media:!0,mediaGroup:!0,method:!0,min:!0,minLength:!0,multiple:!0,muted:!0,name:!0,nonce:!0,noValidate:!0,open:!0,optimum:!0,pattern:!0,placeholder:!0,playsInline:!0,poster:!0,preload:!0,profile:!0,radioGroup:!0,readOnly:!0,referrerPolicy:!0,rel:!0,required:!0,reversed:!0,role:!0,rows:!0,rowSpan:!0,sandbox:!0,scope:!0,scoped:!0,scrolling:!0,seamless:!0,selected:!0,shape:!0,size:!0,sizes:!0,slot:!0,span:!0,spellCheck:!0,src:!0,srcDoc:!0,srcLang:!0,srcSet:!0,start:!0,step:!0,style:!0,summary:!0,tabIndex:!0,target:!0,title:!0,translate:!0,type:!0,useMap:!0,value:!0,width:!0,wmode:!0,wrap:!0,about:!0,datatype:!0,inlist:!0,prefix:!0,property:!0,resource:!0,typeof:!0,vocab:!0,autoCapitalize:!0,autoCorrect:!0,autoSave:!0,color:!0,incremental:!0,fallback:!0,inert:!0,itemProp:!0,itemScope:!0,itemType:!0,itemID:!0,itemRef:!0,on:!0,option:!0,results:!0,security:!0,unselectable:!0,accentHeight:!0,accumulate:!0,additive:!0,alignmentBaseline:!0,allowReorder:!0,alphabetic:!0,amplitude:!0,arabicForm:!0,ascent:!0,attributeName:!0,attributeType:!0,autoReverse:!0,azimuth:!0,baseFrequency:!0,baselineShift:!0,baseProfile:!0,bbox:!0,begin:!0,bias:!0,by:!0,calcMode:!0,capHeight:!0,clip:!0,clipPathUnits:!0,clipPath:!0,clipRule:!0,colorInterpolation:!0,colorInterpolationFilters:!0,colorProfile:!0,colorRendering:!0,contentScriptType:!0,contentStyleType:!0,cursor:!0,cx:!0,cy:!0,d:!0,decelerate:!0,descent:!0,diffuseConstant:!0,direction:!0,display:!0,divisor:!0,dominantBaseline:!0,dur:!0,dx:!0,dy:!0,edgeMode:!0,elevation:!0,enableBackground:!0,end:!0,exponent:!0,externalResourcesRequired:!0,fill:!0,fillOpacity:!0,fillRule:!0,filter:!0,filterRes:!0,filterUnits:!0,floodColor:!0,floodOpacity:!0,focusable:!0,fontFamily:!0,fontSize:!0,fontSizeAdjust:!0,fontStretch:!0,fontStyle:!0,fontVariant:!0,fontWeight:!0,format:!0,from:!0,fr:!0,fx:!0,fy:!0,g1:!0,g2:!0,glyphName:!0,glyphOrientationHorizontal:!0,glyphOrientationVertical:!0,glyphRef:!0,gradientTransform:!0,gradientUnits:!0,hanging:!0,horizAdvX:!0,horizOriginX:!0,ideographic:!0,imageRendering:!0,in:!0,in2:!0,intercept:!0,k:!0,k1:!0,k2:!0,k3:!0,k4:!0,kernelMatrix:!0,kernelUnitLength:!0,kerning:!0,keyPoints:!0,keySplines:!0,keyTimes:!0,lengthAdjust:!0,letterSpacing:!0,lightingColor:!0,limitingConeAngle:!0,local:!0,markerEnd:!0,markerMid:!0,markerStart:!0,markerHeight:!0,markerUnits:!0,markerWidth:!0,mask:!0,maskContentUnits:!0,maskUnits:!0,mathematical:!0,mode:!0,numOctaves:!0,offset:!0,opacity:!0,operator:!0,order:!0,orient:!0,orientation:!0,origin:!0,overflow:!0,overlinePosition:!0,overlineThickness:!0,panose1:!0,paintOrder:!0,pathLength:!0,patternContentUnits:!0,patternTransform:!0,patternUnits:!0,pointerEvents:!0,points:!0,pointsAtX:!0,pointsAtY:!0,pointsAtZ:!0,preserveAlpha:!0,preserveAspectRatio:!0,primitiveUnits:!0,r:!0,radius:!0,refX:!0,refY:!0,renderingIntent:!0,repeatCount:!0,repeatDur:!0,requiredExtensions:!0,requiredFeatures:!0,restart:!0,result:!0,rotate:!0,rx:!0,ry:!0,scale:!0,seed:!0,shapeRendering:!0,slope:!0,spacing:!0,specularConstant:!0,specularExponent:!0,speed:!0,spreadMethod:!0,startOffset:!0,stdDeviation:!0,stemh:!0,stemv:!0,stitchTiles:!0,stopColor:!0,stopOpacity:!0,strikethroughPosition:!0,strikethroughThickness:!0,string:!0,stroke:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeLinecap:!0,strokeLinejoin:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0,surfaceScale:!0,systemLanguage:!0,tableValues:!0,targetX:!0,targetY:!0,textAnchor:!0,textDecoration:!0,textRendering:!0,textLength:!0,to:!0,transform:!0,u1:!0,u2:!0,underlinePosition:!0,underlineThickness:!0,unicode:!0,unicodeBidi:!0,unicodeRange:!0,unitsPerEm:!0,vAlphabetic:!0,vHanging:!0,vIdeographic:!0,vMathematical:!0,values:!0,vectorEffect:!0,version:!0,vertAdvY:!0,vertOriginX:!0,vertOriginY:!0,viewBox:!0,viewTarget:!0,visibility:!0,widths:!0,wordSpacing:!0,writingMode:!0,x:!0,xHeight:!0,x1:!0,x2:!0,xChannelSelector:!0,xlinkActuate:!0,xlinkArcrole:!0,xlinkHref:!0,xlinkRole:!0,xlinkShow:!0,xlinkTitle:!0,xlinkType:!0,xmlBase:!0,xmlns:!0,xmlnsXlink:!0,xmlLang:!0,xmlSpace:!0,y:!0,y1:!0,y2:!0,yChannelSelector:!0,z:!0,zoomAndPan:!0,for:!0,class:!0,autofocus:!0},V=`^((${Object.keys(U).join("|")})|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$`,B=new RegExp(V),W=E.memoize(e=>B.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91),X={box:"var(--swui-shadow-box)",popover:"var(--swui-shadow-popover)",modal:"var(--swui-shadow-modal)",bottom:"var(--swui-shadow-bottom)"},G=["spacing","indent","gap","width","height","overflow","display"],Y=e=>G.includes(e),K=c.system({row:{property:"flexDirection",transform:e=>e?"row":"column"},indent:{property:"--current-indent",transform:y},spacing:{property:"--current-spacing",transform:y},gap:{property:"--current-gap",transform:y},columnGap:{property:"columnGap",transform:C},rowGap:{property:"rowGap",transform:C},shadow:{property:"boxShadow",transform:e=>X[e]??e}}),g=S("div",{shouldForwardProp:e=>typeof e=="string"?Y(e)?!1:W(e):!1})`
26
26
  --current-spacing: 0;
27
27
  --current-indent: 0;
28
28
  --current-gap: 0;
@@ -70,10 +70,10 @@
70
70
  ${({focusWithinBackground:e})=>e?`background: ${e};`:""}
71
71
  ${({focusWithinBorder:e})=>e?`border: ${e};`:""}
72
72
  }
73
- `,Z=n.forwardRef(function(t,r){return l.jsx(g,{ref:r,...t})}),$=e=>{const{x:t,y:r,width:u,height:s,bottom:o,top:i,left:d,right:a}=e.getBoundingClientRect();return{width:u,height:s,top:i,left:d,x:t,y:r,right:a,bottom:o}},J=(e,t)=>e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height&&e.bottom===t.bottom&&e.top===t.top&&e.left===t.left&&e.right===t.right,R=(e,t)=>{const[r,u]=n.useState(),s=n.useCallback(()=>{window.requestAnimationFrame(()=>{if(e.current){const o=$(e.current);(!r||!J(r,o))&&t&&t(o),u(o)}})},[e,r,u,t]);return n.useLayoutEffect(()=>{s()},[s]),{dimensions:r}},Q=n.forwardRef(function({onResize:t,...r},u){const s=n.useRef(null);return R(u??s,t),l.jsx(g,{...r,ref:u})}),ee=n.forwardRef(function(t,r){return l.jsx(g,{row:!0,ref:r,...t})}),te=n.forwardRef(function({num:t=1,...r},u){return l.jsx(g,{indent:t,ref:u,...r})}),re=n.forwardRef(function({num:t=1,...r},u){return l.jsx(g,{spacing:t,ref:u,...r})}),ue=w.div`
73
+ `,Z=n.forwardRef(function(t,r){return l.jsx(g,{ref:r,...t})}),I=e=>{const{x:t,y:r,width:u,height:s,bottom:o,top:i,left:d,right:a}=e.getBoundingClientRect();return{width:u,height:s,top:i,left:d,x:t,y:r,right:a,bottom:o}},J=(e,t)=>e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height&&e.bottom===t.bottom&&e.top===t.top&&e.left===t.left&&e.right===t.right,O=(e,t)=>{const[r,u]=n.useState(),s=n.useCallback(()=>{window.requestAnimationFrame(()=>{if(e.current){const o=I(e.current);(!r||!J(r,o))&&t&&t(o),u(o)}})},[e,r,u,t]);return n.useLayoutEffect(()=>{s()},[s]),{dimensions:r}},Q=n.forwardRef(function({onResize:t,...r},u){const s=n.useRef(null);return O(u??s,t),l.jsx(g,{...r,ref:u})}),ee=n.forwardRef(function(t,r){return l.jsx(g,{row:!0,ref:r,...t})}),te=n.forwardRef(function({num:t=1,...r},u){return l.jsx(g,{indent:t,ref:u,...r})}),re=n.forwardRef(function({num:t=1,...r},u){return l.jsx(g,{spacing:t,ref:u,...r})}),ue=S.div`
74
74
  --current-size: 1;
75
75
  flex: none;
76
76
  width: calc(var(--current-size) * var(--swui-metrics-space));
77
77
  height: calc(var(--current-size) * var(--swui-metrics-space));
78
- `,ne=({half:e=!1,horizontal:t=!1,num:r=1,vertical:u=!1})=>{const s=r*(e?.5:1);return l.jsx(ue,{style:{"--current-size":s,height:t?1:void 0,width:u?1:void 0}})},se=({children:e,nest:t,render:r})=>t?l.jsx(l.Fragment,{children:r(e)}):l.jsx(l.Fragment,{children:e}),oe="_visuallyHidden_1gevf_1",ie={visuallyHidden:oe},I=e=>k.pickBy(e,ae),ae=(e,t)=>ce(t),ce=e=>e.startsWith("data-")||e.startsWith("aria-"),le=({children:e,...t})=>l.jsx("span",{className:ie.visuallyHidden,...I(t),children:e}),de="_text_1iisw_1",fe="_standard_1iisw_24",pe="_bold_1iisw_27",me="_caption_1iisw_31",he="_overline_1iisw_39",ge="_large_1iisw_48",be="_medium_1iisw_53",ye="_small_1iisw_58",xe="_smaller_1iisw_63",v={text:de,standard:fe,bold:pe,caption:me,overline:he,large:ge,medium:be,small:ye,smaller:xe},b=n.forwardRef(({children:e,variant:t="standard",size:r="medium",className:u,color:s,userSelect:o,whiteSpace:i,wordBreak:d,textAlign:a,style:f,...p},m)=>l.jsx("span",{className:_(v.text,v[t],v[r],u),ref:m,style:{color:s,userSelect:o,whiteSpace:i,wordBreak:d,textAlign:a,...f},...p,children:e})),ve=b,we=e=>l.jsx(b,{size:"small",...e}),ke=e=>l.jsx(b,{size:"smaller",...e}),Se=e=>l.jsx(b,{size:"medium",...e}),Ee=e=>l.jsx(b,{size:"large",...e}),Ce="_heading_1cnsg_1",Te="_h1_1cnsg_10",_e="_h2_1cnsg_14",$e="_h3_1cnsg_18",Re="_h4_1cnsg_22",Ie="_h5_1cnsg_26",Oe="_h6_1cnsg_30",E={heading:Ce,h1:Te,h2:_e,h3:$e,h4:Re,h5:Ie,h6:Oe},O=n.forwardRef(({variant:e="h3",className:t,color:r,whiteSpace:u,wordBreak:s,style:o,children:i,as:d,...a},f)=>{const p=d??e;return l.jsx(p,{className:_(E.heading,E[e],t),style:{color:r,whiteSpace:u,wordBreak:s,...o},ref:f,...a,children:i})}),Le=e=>l.jsx(O,{variant:"h2",...e}),Me=(e,t)=>e===t,Ae=(e,t,r=Me)=>{const u=n.useCallback(a=>{e.some(f=>r(f,a))||t([...e,a])},[e,t,r]),s=n.useCallback(a=>{t(a.reduce((f,p)=>f.some(m=>r(m,p))?f:[...f,p],e))},[e,t,r]),o=n.useCallback(a=>{const f=e.findIndex(p=>r(p,a));f>=0&&t(e.filter((p,m)=>m!==f))},[e,t,r]),i=n.useCallback(a=>{t(e.filter(f=>!a.some(p=>r(p,f))))},[e,t,r]),d=n.useCallback(a=>{e.some(p=>r(p,a))?o(a):u(a)},[e,u,o,r]);return{add:u,addMultiple:s,remove:o,removeMultiple:i,toggle:d}},x=e=>{const[t,r]=n.useState(e),u=n.useCallback(()=>{r(!0)},[r]),s=n.useCallback(()=>{r(!1)},[r]),o=n.useCallback(()=>{r(i=>!i)},[r]);return[t,u,s,o]},De=(e,t)=>{const[r,u]=n.useState(e);return n.useEffect(()=>{const s=setTimeout(()=>{u(e)},t);return()=>{clearTimeout(s)}},[e,t]),r},Pe=(e,t)=>{const[r,u]=n.useState(e);return n.useEffect(()=>{e&&u(!0);const s=setTimeout(()=>{e||u(e)},t);return()=>{clearTimeout(s)}},[e,t]),r};let Fe=0;const C=e=>`webui-${e?e+"-":""}${++Fe}`,je=e=>{const[t,r]=n.useState(()=>C(e));return n.useEffect(()=>r(C(e)),[e]),t},h=(e,t,r)=>{const u=n.useRef(null);n.useEffect(()=>{u.current=r},[r]),n.useEffect(()=>{if(!(e.current&&e.current.addEventListener))return;const o=d=>{if(u.current)return u.current(d)};if(!e.current)return;const i=e.current;return i.addEventListener(t,o),()=>{i&&i.removeEventListener(t,o)}},[t,e])},He=e=>{const[t,r,u]=x(!1);n.useEffect(()=>{document.activeElement===e.current?r():u()},[e,u,r]),h(e,"focus",r),h(e,"blur",u);const s=n.useCallback(()=>{e.current&&e.current.focus()},[e]),o=n.useCallback(()=>{e.current&&e.current.blur()},[e]);return{isInFocus:t,focus:s,blur:o}},ze=e=>{const t=n.useRef(e);return n.useLayoutEffect(()=>{t.current=e}),n.useCallback((...r)=>{const{current:u}=t;return u(...r)},[])},Ne=e=>{const t=n.useRef(e);return t.current=e,t},qe=e=>{const[t,r,u]=x(!1);return h(e,"mouseover",r),h(e,"mouseout",u),t},Ue=e=>{const[t,r,u]=x(!1);return h(e,"mouseenter",r),h(e,"mouseleave",u),t},Ve=(e,t)=>{const r=n.useRef(()=>{});n.useEffect(()=>{r.current=t},[t]),n.useEffect(()=>{const u=s=>{e.filter(i=>i.current).every(i=>i.current&&!i.current.contains(s.target))&&r.current(s)};return document.addEventListener("mousedown",u),document.addEventListener("touchstart",u),()=>{document.removeEventListener("mousedown",u),document.removeEventListener("touchstart",u)}},[...e])},Be=(e,t,r)=>{const u=n.useRef(()=>{});n.useEffect(()=>{u.current=t},[t]),n.useEffect(()=>{const s=o=>{!e.current||e.current.contains(o.target)||u.current(o)};return document.addEventListener("mousedown",s,r),document.addEventListener("touchstart",s,r),()=>{document.removeEventListener("mousedown",s,r),document.removeEventListener("touchstart",s,r)}},[e,r])},T=["mousemove","mousedown","keydown","touchstart","scroll"],We=(e,t)=>{const r=n.useRef(()=>{});n.useEffect(()=>{r.current=e},[e]),n.useEffect(()=>{const u=k.debounce(r.current,t);return T.forEach(s=>window.addEventListener(s,u)),()=>{T.forEach(s=>window.removeEventListener(s,u))}},[t])},Xe=(e,t)=>{const[r,u]=n.useState(!1),{rootMargin:s,root:o,threshold:i}=t||{},d=n.useMemo(()=>new IntersectionObserver(([a])=>u(a.isIntersecting),{rootMargin:s,root:o,threshold:i}),[u,s,o,i]);return n.useEffect(()=>(e.current&&d.observe(e.current),()=>{d.disconnect()}),[d,e]),r},Ge=e=>{const t=n.useRef(null);return n.useEffect(()=>{e&&(typeof e=="function"?e(t.current):e.current=t.current)}),t},Ye=(e,t,r=!0)=>{const[u,s]=n.useState(e),o=n.useRef(null),i=n.useCallback((d,a=t)=>{s(d),r&&clearTimeout(o.current),o.current=setTimeout(()=>s(e),a)},[t,r,e]);return n.useEffect(()=>()=>{clearTimeout(o.current)},[]),[u,i]},Ke=()=>n.useMemo(()=>new Date,[]),Ze=e=>(t,r)=>e(t).localeCompare(e(r)),Je=e=>(t,r)=>e(t)-e(r),Qe=e=>{throw new Error(`Switch unhandled case: ${e}`)},et=(e,t)=>t,tt=e=>Object.keys(e).filter(t=>e[t]),rt=e=>{try{const t=parseFloat(e);return isNaN(t)||t==null?void 0:t}catch{}},ut=e=>{try{const t=parseInt(e,10);return isNaN(t)||t==null?void 0:t}catch{}};function nt(e,t){if(e==null)throw new Error("Invariant error: "+t)}exports.Box=g;exports.Clickable=N;exports.Column=Z;exports.HeaderText=Le;exports.Heading=O;exports.Indent=te;exports.LargeText=Ee;exports.Nest=se;exports.ResizeAwareBox=Q;exports.Row=ee;exports.ScreenReaderOnlyText=le;exports.SeparatorLine=H;exports.SmallText=we;exports.SmallerText=ke;exports.Space=ne;exports.Spacing=re;exports.StandardText=Se;exports.Text=b;exports.Txt=ve;exports.booleanOrNumberToNumber=y;exports.byNumberField=Je;exports.byStringField=Ze;exports.exhaustSwitchCase=et;exports.exhaustSwitchCaseElseThrow=Qe;exports.getDataProps=I;exports.getDimensionObject=$;exports.invariant=nt;exports.parseFloatElseUndefined=rt;exports.parseIntElseUndefined=ut;exports.truthyKeysAsList=tt;exports.useArraySet=Ae;exports.useBoolean=x;exports.useDebounce=De;exports.useDelayedFalse=Pe;exports.useDomId=je;exports.useElementDimensions=R;exports.useElementFocus=He;exports.useEventCallback=ze;exports.useEventListener=h;exports.useForwardedRef=Ge;exports.useLatest=Ne;exports.useMouseIsEntered=Ue;exports.useMouseIsOver=qe;exports.useMultiOnClickOutside=Ve;exports.useOnClickOutside=Be;exports.useOnNoMouseMovement=We;exports.useOnScreen=Xe;exports.useTimeoutState=Ye;exports.useToday=Ke;
78
+ `,ne=({half:e=!1,horizontal:t=!1,num:r=1,vertical:u=!1})=>{const s=r*(e?.5:1);return l.jsx(ue,{style:{"--current-size":s,height:t?1:void 0,width:u?1:void 0}})},se=({children:e,nest:t,render:r})=>t?l.jsx(l.Fragment,{children:r(e)}):l.jsx(l.Fragment,{children:e}),oe="_visuallyHidden_1gevf_1",ie={visuallyHidden:oe},L=e=>E.pickBy(e,ae),ae=(e,t)=>ce(t),ce=e=>e.startsWith("data-")||e.startsWith("aria-"),le=({children:e,...t})=>l.jsx("span",{className:ie.visuallyHidden,...L(t),children:e}),de="_text_1iisw_1",fe="_standard_1iisw_24",pe="_bold_1iisw_27",me="_caption_1iisw_31",he="_overline_1iisw_39",ge="_large_1iisw_48",be="_medium_1iisw_53",ye="_small_1iisw_58",xe="_smaller_1iisw_63",k={text:de,standard:fe,bold:pe,caption:me,overline:he,large:ge,medium:be,small:ye,smaller:xe},b=n.forwardRef(({children:e,variant:t="standard",size:r="medium",className:u,color:s,userSelect:o,whiteSpace:i,wordBreak:d,textAlign:a,overflow:f,textOverflow:p,style:m,...v},w)=>l.jsx("span",{className:R(k.text,k[t],k[r],u),ref:w,style:{color:s,userSelect:o,whiteSpace:i,wordBreak:d,textAlign:a,overflow:f,textOverflow:p,...m},...v,children:e})),ve=b,we=e=>l.jsx(b,{size:"small",...e}),ke=e=>l.jsx(b,{size:"smaller",...e}),Se=e=>l.jsx(b,{size:"medium",...e}),Ee=e=>l.jsx(b,{size:"large",...e}),Ce="_heading_1cnsg_1",Te="_h1_1cnsg_10",_e="_h2_1cnsg_14",$e="_h3_1cnsg_18",Re="_h4_1cnsg_22",Ie="_h5_1cnsg_26",Oe="_h6_1cnsg_30",T={heading:Ce,h1:Te,h2:_e,h3:$e,h4:Re,h5:Ie,h6:Oe},M=n.forwardRef(({variant:e="h3",className:t,color:r,whiteSpace:u,wordBreak:s,style:o,children:i,as:d,...a},f)=>{const p=d??e;return l.jsx(p,{className:R(T.heading,T[e],t),style:{color:r,whiteSpace:u,wordBreak:s,...o},ref:f,...a,children:i})}),Le=e=>l.jsx(M,{variant:"h2",...e}),Me=(e,t)=>e===t,Ae=(e,t,r=Me)=>{const u=n.useCallback(a=>{e.some(f=>r(f,a))||t([...e,a])},[e,t,r]),s=n.useCallback(a=>{t(a.reduce((f,p)=>f.some(m=>r(m,p))?f:[...f,p],e))},[e,t,r]),o=n.useCallback(a=>{const f=e.findIndex(p=>r(p,a));f>=0&&t(e.filter((p,m)=>m!==f))},[e,t,r]),i=n.useCallback(a=>{t(e.filter(f=>!a.some(p=>r(p,f))))},[e,t,r]),d=n.useCallback(a=>{e.some(p=>r(p,a))?o(a):u(a)},[e,u,o,r]);return{add:u,addMultiple:s,remove:o,removeMultiple:i,toggle:d}},x=e=>{const[t,r]=n.useState(e),u=n.useCallback(()=>{r(!0)},[r]),s=n.useCallback(()=>{r(!1)},[r]),o=n.useCallback(()=>{r(i=>!i)},[r]);return[t,u,s,o]},De=(e,t)=>{const[r,u]=n.useState(e);return n.useEffect(()=>{const s=setTimeout(()=>{u(e)},t);return()=>{clearTimeout(s)}},[e,t]),r},Pe=(e,t)=>{const[r,u]=n.useState(e);return n.useEffect(()=>{e&&u(!0);const s=setTimeout(()=>{e||u(e)},t);return()=>{clearTimeout(s)}},[e,t]),r};let Fe=0;const _=e=>`webui-${e?e+"-":""}${++Fe}`,je=e=>{const[t,r]=n.useState(()=>_(e));return n.useEffect(()=>r(_(e)),[e]),t},h=(e,t,r)=>{const u=n.useRef(null);n.useEffect(()=>{u.current=r},[r]),n.useEffect(()=>{if(!(e.current&&e.current.addEventListener))return;const o=d=>{if(u.current)return u.current(d)};if(!e.current)return;const i=e.current;return i.addEventListener(t,o),()=>{i&&i.removeEventListener(t,o)}},[t,e])},He=e=>{const[t,r,u]=x(!1);n.useEffect(()=>{document.activeElement===e.current?r():u()},[e,u,r]),h(e,"focus",r),h(e,"blur",u);const s=n.useCallback(()=>{e.current&&e.current.focus()},[e]),o=n.useCallback(()=>{e.current&&e.current.blur()},[e]);return{isInFocus:t,focus:s,blur:o}},ze=e=>{const t=n.useRef(e);return n.useLayoutEffect(()=>{t.current=e}),n.useCallback((...r)=>{const{current:u}=t;return u(...r)},[])},Ne=e=>{const t=n.useRef(e);return t.current=e,t},qe=e=>{const[t,r,u]=x(!1);return h(e,"mouseover",r),h(e,"mouseout",u),t},Ue=e=>{const[t,r,u]=x(!1);return h(e,"mouseenter",r),h(e,"mouseleave",u),t},Ve=(e,t)=>{const r=n.useRef(()=>{});n.useEffect(()=>{r.current=t},[t]),n.useEffect(()=>{const u=s=>{e.filter(i=>i.current).every(i=>i.current&&!i.current.contains(s.target))&&r.current(s)};return document.addEventListener("mousedown",u),document.addEventListener("touchstart",u),()=>{document.removeEventListener("mousedown",u),document.removeEventListener("touchstart",u)}},[...e])},Be=(e,t,r)=>{const u=n.useRef(()=>{});n.useEffect(()=>{u.current=t},[t]),n.useEffect(()=>{const s=o=>{!e.current||e.current.contains(o.target)||u.current(o)};return document.addEventListener("mousedown",s,r),document.addEventListener("touchstart",s,r),()=>{document.removeEventListener("mousedown",s,r),document.removeEventListener("touchstart",s,r)}},[e,r])},$=["mousemove","mousedown","keydown","touchstart","scroll"],We=(e,t)=>{const r=n.useRef(()=>{});n.useEffect(()=>{r.current=e},[e]),n.useEffect(()=>{const u=E.debounce(r.current,t);return $.forEach(s=>window.addEventListener(s,u)),()=>{$.forEach(s=>window.removeEventListener(s,u))}},[t])},Xe=(e,t)=>{const[r,u]=n.useState(!1),{rootMargin:s,root:o,threshold:i}=t||{},d=n.useMemo(()=>new IntersectionObserver(([a])=>u(a.isIntersecting),{rootMargin:s,root:o,threshold:i}),[u,s,o,i]);return n.useEffect(()=>(e.current&&d.observe(e.current),()=>{d.disconnect()}),[d,e]),r},Ge=e=>{const t=n.useRef(null);return n.useEffect(()=>{e&&(typeof e=="function"?e(t.current):e.current=t.current)}),t},Ye=(e,t,r=!0)=>{const[u,s]=n.useState(e),o=n.useRef(null),i=n.useCallback((d,a=t)=>{s(d),r&&clearTimeout(o.current),o.current=setTimeout(()=>s(e),a)},[t,r,e]);return n.useEffect(()=>()=>{clearTimeout(o.current)},[]),[u,i]},Ke=()=>n.useMemo(()=>new Date,[]),Ze=e=>(t,r)=>e(t).localeCompare(e(r)),Je=e=>(t,r)=>e(t)-e(r),Qe=e=>{throw new Error(`Switch unhandled case: ${e}`)},et=(e,t)=>t,tt=e=>Object.keys(e).filter(t=>e[t]),rt=e=>{try{const t=parseFloat(e);return isNaN(t)||t==null?void 0:t}catch{}},ut=e=>{try{const t=parseInt(e,10);return isNaN(t)||t==null?void 0:t}catch{}};function nt(e,t){if(e==null)throw new Error("Invariant error: "+t)}exports.Box=g;exports.Clickable=N;exports.Column=Z;exports.HeaderText=Le;exports.Heading=M;exports.Indent=te;exports.LargeText=Ee;exports.Nest=se;exports.ResizeAwareBox=Q;exports.Row=ee;exports.ScreenReaderOnlyText=le;exports.SeparatorLine=H;exports.SmallText=we;exports.SmallerText=ke;exports.Space=ne;exports.Spacing=re;exports.StandardText=Se;exports.Text=b;exports.Txt=ve;exports.booleanOrNumberToNumber=y;exports.byNumberField=Je;exports.byStringField=Ze;exports.exhaustSwitchCase=et;exports.exhaustSwitchCaseElseThrow=Qe;exports.getDataProps=L;exports.getDimensionObject=I;exports.invariant=nt;exports.parseFloatElseUndefined=rt;exports.parseIntElseUndefined=ut;exports.truthyKeysAsList=tt;exports.useArraySet=Ae;exports.useBoolean=x;exports.useDebounce=De;exports.useDelayedFalse=Pe;exports.useDomId=je;exports.useElementDimensions=O;exports.useElementFocus=He;exports.useEventCallback=ze;exports.useEventListener=h;exports.useForwardedRef=Ge;exports.useLatest=Ne;exports.useMouseIsEntered=Ue;exports.useMouseIsOver=qe;exports.useMultiOnClickOutside=Ve;exports.useOnClickOutside=Be;exports.useOnNoMouseMovement=We;exports.useOnScreen=Xe;exports.useTimeoutState=Ye;exports.useToday=Ke;
79
79
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../src/components/decorators/separatorline/SeparatorLine.tsx","../src/components/interaction/Clickable.tsx","../src/utils/BooleanOrNumberToNumber.ts","../src/components/util/IsPropValid.ts","../src/components/layout/box/Box.tsx","../src/components/layout/column/Column.tsx","../src/hooks/UseElementDimensions.ts","../src/components/layout/box/ResizeAwareBox.tsx","../src/components/layout/row/Row.tsx","../src/components/layout/indent/Indent.tsx","../src/components/layout/spacing/Spacing.tsx","../src/components/layout/space/Space.tsx","../src/components/util/Nest.tsx","../src/utils/PropsForwarder.ts","../src/components/accessibility/ScreenReaderOnlyText.tsx","../src/components/text/Text.tsx","../src/components/deprecated-text/SmallText.tsx","../src/components/deprecated-text/SmallerText.tsx","../src/components/deprecated-text/StandardText.tsx","../src/components/deprecated-text/LargeText.tsx","../src/components/heading/Heading.tsx","../src/components/deprecated-text/HeaderText.tsx","../src/hooks/UseArraySet.ts","../src/hooks/UseBoolean.ts","../src/hooks/UseDebounce.ts","../src/hooks/UseDelayedFalse.ts","../src/hooks/UseDomId.ts","../src/hooks/UseEventListener.ts","../src/hooks/UseElementFocus.ts","../src/hooks/UseEventCallback.tsx","../src/hooks/UseLatest.ts","../src/hooks/UseMouseIsOver.ts","../src/hooks/UseMouseIsEntered.ts","../src/hooks/UseMultiOnClickOutside.ts","../src/hooks/UseOnClickOutside.ts","../src/hooks/UseOnNoMouseInput.ts","../src/hooks/UseOnScreen.ts","../src/hooks/UseForwardedRef.ts","../src/hooks/UseTimeoutState.ts","../src/hooks/UseToday.ts","../src/sorting/Comparators.ts","../src/utils/SwitchCaseExhauster.ts","../src/utils/TruthyKeysAsList.ts","../src/utils/parsers/NumberParser.ts","../src/utils/Invariant.ts"],"sourcesContent":["import { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { cssColor } from \"@stenajs-webui/theme\";\nimport styles from \"./SeparatorLine.module.css\";\n\nexport interface SeparatorLineProps {\n color?: Property.Color;\n vertical?: boolean;\n size?: string;\n width?: string;\n}\n\nexport const SeparatorLine = forwardRef<HTMLHRElement, SeparatorLineProps>(\n (\n {\n color = cssColor(\"--lhds-color-ui-300\"),\n size = \"100%\",\n width = \"1px\",\n vertical = false,\n },\n ref,\n ) => {\n return (\n <hr\n className={styles.separatorLine}\n aria-hidden={true}\n color={color}\n style={{\n backgroundColor: color,\n height: vertical ? size || \"100%\" : width || \"1px\",\n width: vertical ? width || \"1px\" : size || \"100%\",\n }}\n ref={ref}\n />\n );\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\nimport { CSSProperties, forwardRef, MouseEventHandler } from \"react\";\nimport { ButtonElementProps } from \"../../types/ElementProps\";\n\nexport interface ClickableProps extends ButtonElementProps {\n /** Callback function called when clicking on click area. */\n onClick?: MouseEventHandler<HTMLButtonElement>;\n /** Callback function called when double clicking on click area. */\n onDblClick?: MouseEventHandler<HTMLButtonElement>;\n /** Adds a title to the click area. */\n tooltip?: string;\n /** If set, there is no opacity applies when clicking on the click area. */\n disableOpacityOnClick?: boolean;\n /** Mouse does not turn into pointer when hovering over click area. */\n disablePointer?: boolean;\n /** When set, click area receives opacity when mouse hovers over it. */\n opacityOnHover?: boolean;\n /** Custom style on div with click event. */\n style?: CSSProperties;\n /** Disables shadow when element is focused. */\n disableFocusHighlight?: boolean;\n /** Disables the HTML button element. */\n disabled?: boolean;\n /**\n * Sets the background of the box.\n */\n background?: string;\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: string;\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: string;\n /**\n * The width.\n */\n width?: string;\n /**\n * The height.\n */\n height?: string;\n /**\n * Border radius\n */\n borderRadius?: string;\n}\n\ninterface ClickableElementProps {\n disableOpacityOnClick?: boolean;\n opacityOnHover?: boolean;\n disableFocusHighlight?: boolean;\n pointer?: boolean;\n background?: string;\n focusBackground?: string;\n hoverBackground?: string;\n width?: string;\n height?: string;\n borderRadius?: string;\n}\n\nconst ClickableElement = styled.button<ClickableElementProps>`\n display: inline-block;\n user-select: none;\n border: 0;\n padding: 0;\n background: ${({ background }) => background};\n ${({ pointer }) => (pointer ? \"cursor: pointer;\" : \"\")}\n\n :hover {\n ${(props) => (props.opacityOnHover ? \"opacity: 0.7;\" : \"\")};\n ${({ hoverBackground }) => `background: ${hoverBackground};`}\n }\n :active {\n ${({ disableOpacityOnClick }) =>\n !disableOpacityOnClick ? \"opacity: 0.5;\" : \"\"}\n }\n :focus {\n outline: 0;\n ${({ disableFocusHighlight }) =>\n disableFocusHighlight\n ? \"\"\n : \"box-shadow: 0 0 3pt 2pt rgba(0, 0, 100, 0.3);\"}\n ${({ focusBackground }) => `background: ${focusBackground};`}\n }\n ${({ width }) => (width ? `width: ${width};` : \"\")}\n ${({ height }) => (height ? `height: ${height};` : \"\")}\n ${({ borderRadius }) =>\n borderRadius ? `border-radius: ${borderRadius};` : \"\"}\n`;\n\nexport const Clickable = forwardRef<HTMLButtonElement, ClickableProps>(\n (\n {\n disableFocusHighlight,\n onClick,\n onDblClick,\n tooltip,\n disableOpacityOnClick,\n disablePointer,\n opacityOnHover,\n disabled,\n children,\n background = \"transparent\",\n hoverBackground,\n focusBackground,\n type = \"button\",\n ...restProps\n },\n ref,\n ) => {\n const hasClickHandler = !!(onClick || onDblClick);\n\n return (\n <ClickableElement\n opacityOnHover={opacityOnHover}\n title={tooltip}\n disabled={disabled}\n disableOpacityOnClick={disableOpacityOnClick}\n onClick={onClick}\n onDoubleClick={onDblClick}\n disableFocusHighlight={disableFocusHighlight}\n pointer={hasClickHandler && !disablePointer}\n ref={ref}\n background={background}\n hoverBackground={hoverBackground}\n focusBackground={focusBackground}\n type={type}\n {...restProps}\n >\n {children}\n </ClickableElement>\n );\n },\n);\n","export const booleanOrNumberToNumber = (\n num: number | boolean | undefined,\n): number => {\n if (num == null) {\n return 0;\n }\n if (typeof num === \"boolean\") {\n return num ? 1 : 0;\n }\n return num;\n};\n\nexport const numberToMetricCalc = (num: number): string | undefined => {\n if (num === 0) {\n return undefined;\n }\n return `calc(${num} * var(--swui-metrics-space))`;\n};\n\nexport const booleanOrNumberToMetricCalc = (\n num: number | boolean | undefined,\n): string | undefined => numberToMetricCalc(booleanOrNumberToNumber(num));\n","import { memoize } from \"lodash-es\";\n\nconst validPropsRecord = {\n // react props\n // https://github.com/facebook/react/blob/5495a7f24aef85ba6937truetrue1ce962673ca9f5fde6/src/renderers/dom/shared/hooks/ReactDOMUnknownPropertyHook.js\n children: true,\n dangerouslySetInnerHTML: true,\n key: true,\n ref: true,\n autoFocus: true,\n defaultValue: true,\n defaultChecked: true,\n innerHTML: true,\n suppressContentEditableWarning: true,\n suppressHydrationWarning: true,\n // deprecated react prop\n valueLink: true,\n\n // https://github.com/facebook/react/blob/d7157651f7b72d9888ctrue123e191f9b88cd8f41e9/src/renderers/dom/shared/HTMLDOMPropertyConfig.js\n /**\n * Standard Properties\n */\n\n abbr: true,\n accept: true,\n acceptCharset: true,\n accessKey: true,\n action: true,\n allow: true,\n allowUserMedia: true,\n allowPaymentRequest: true,\n allowFullScreen: true,\n allowTransparency: true,\n alt: true,\n // specifies target context for links with `preload` type\n // as: true,\n async: true,\n autoComplete: true,\n // autoFocus is polyfilled/normalized by AutoFocusUtils\n // autoFocus: true,\n autoPlay: true,\n capture: true,\n cellPadding: true,\n cellSpacing: true,\n // keygen prop\n challenge: true,\n charSet: true,\n checked: true,\n cite: true,\n classID: true,\n className: true,\n cols: true,\n colSpan: true,\n content: true,\n contentEditable: true,\n contextMenu: true,\n controls: true,\n controlsList: true,\n coords: true,\n crossOrigin: true,\n data: true, // For `<object />` acts as `src`.\n dateTime: true,\n decoding: true,\n default: true,\n defer: true,\n dir: true,\n disabled: true,\n disablePictureInPicture: true,\n disableRemotePlayback: true,\n download: true,\n draggable: true,\n encType: true,\n enterKeyHint: true,\n form: true,\n formAction: true,\n formEncType: true,\n formMethod: true,\n formNoValidate: true,\n formTarget: true,\n frameBorder: true,\n headers: true,\n height: true,\n hidden: true,\n high: true,\n href: true,\n hrefLang: true,\n htmlFor: true,\n httpEquiv: true,\n id: true,\n inputMode: true,\n integrity: true,\n is: true,\n keyParams: true,\n keyType: true,\n kind: true,\n label: true,\n lang: true,\n list: true,\n loading: true,\n loop: true,\n low: true,\n // manifest: true,\n marginHeight: true,\n marginWidth: true,\n max: true,\n maxLength: true,\n media: true,\n mediaGroup: true,\n method: true,\n min: true,\n minLength: true,\n // Caution; `option.selected` is not updated if `select.multiple` is\n // disabled with `removeAttribute`.\n multiple: true,\n muted: true,\n name: true,\n nonce: true,\n noValidate: true,\n open: true,\n optimum: true,\n pattern: true,\n placeholder: true,\n playsInline: true,\n poster: true,\n preload: true,\n profile: true,\n radioGroup: true,\n readOnly: true,\n referrerPolicy: true,\n rel: true,\n required: true,\n reversed: true,\n role: true,\n rows: true,\n rowSpan: true,\n sandbox: true,\n scope: true,\n scoped: true,\n scrolling: true,\n seamless: true,\n selected: true,\n shape: true,\n size: true,\n sizes: true,\n // support for projecting regular DOM Elements via V1 named slots ( shadow dom )\n slot: true,\n span: true,\n spellCheck: true,\n src: true,\n srcDoc: true,\n srcLang: true,\n srcSet: true,\n start: true,\n step: true,\n style: true,\n summary: true,\n tabIndex: true,\n target: true,\n title: true,\n translate: true,\n // Setting .type throws on non-<input> tags\n type: true,\n useMap: true,\n value: true,\n width: true,\n wmode: true,\n wrap: true,\n\n /**\n * RDFa Properties\n */\n about: true,\n datatype: true,\n inlist: true,\n prefix: true,\n // property is also supported for OpenGraph in meta tags.\n property: true,\n resource: true,\n typeof: true,\n vocab: true,\n\n /**\n * Non-standard Properties\n */\n // autoCapitalize and autoCorrect are supported in Mobile Safari for\n // keyboard hints.\n autoCapitalize: true,\n autoCorrect: true,\n // autoSave allows WebKit/Blink to persist values of input fields on page reloads\n autoSave: true,\n // color is for Safari mask-icon link\n color: true,\n // https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/search#incremental_This_API_has_not_been_standardized\n incremental: true,\n // used in amp html for indicating the fallback behavior\n // https://amp.dev/documentation/guides-and-tutorials/develop/style_and_layout/placeholders/\n fallback: true,\n // https://html.spec.whatwg.org/multipage/interaction.html#inert\n inert: true,\n // itemProp, itemScope, itemType are for\n // Microdata support. See http://schema.org/docs/gs.html\n itemProp: true,\n itemScope: true,\n itemType: true,\n // itemID and itemRef are for Microdata support as well but\n // only specified in the WHATWG spec document. See\n // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api\n itemID: true,\n itemRef: true,\n // used in amp html for eventing purposes\n // https://amp.dev/documentation/guides-and-tutorials/learn/common_attributes/\n on: true,\n // used in amp html for indicating that the option is selectable\n // https://amp.dev/documentation/components/amp-selector/\n option: true,\n // results show looking glass icon and recent searches on input\n // search fields in WebKit/Blink\n results: true,\n // IE-only attribute that specifies security restrictions on an iframe\n // as an alternative to the sandbox attribute on IE<1true\n security: true,\n // IE-only attribute that controls focus behavior\n unselectable: true,\n //\n // SVG properties: https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\n // The following \"onX\" events have been omitted:\n //\n // onabort\n // onactivate\n // onbegin\n // onclick\n // onend\n // onerror\n // onfocusin\n // onfocusout\n // onload\n // onmousedown\n // onmousemove\n // onmouseout\n // onmouseover\n // onmouseup\n // onrepeat\n // onresize\n // onscroll\n // onunload\n accentHeight: true,\n accumulate: true,\n additive: true,\n alignmentBaseline: true,\n allowReorder: true,\n alphabetic: true,\n amplitude: true,\n arabicForm: true,\n ascent: true,\n attributeName: true,\n attributeType: true,\n autoReverse: true,\n azimuth: true,\n baseFrequency: true,\n baselineShift: true,\n baseProfile: true,\n bbox: true,\n begin: true,\n bias: true,\n by: true,\n calcMode: true,\n capHeight: true,\n clip: true,\n clipPathUnits: true,\n clipPath: true,\n clipRule: true,\n colorInterpolation: true,\n colorInterpolationFilters: true,\n colorProfile: true,\n colorRendering: true,\n contentScriptType: true,\n contentStyleType: true,\n cursor: true,\n cx: true,\n cy: true,\n d: true,\n decelerate: true,\n descent: true,\n diffuseConstant: true,\n direction: true,\n display: true,\n divisor: true,\n dominantBaseline: true,\n dur: true,\n dx: true,\n dy: true,\n edgeMode: true,\n elevation: true,\n enableBackground: true,\n end: true,\n exponent: true,\n externalResourcesRequired: true,\n fill: true,\n fillOpacity: true,\n fillRule: true,\n filter: true,\n filterRes: true,\n filterUnits: true,\n floodColor: true,\n floodOpacity: true,\n focusable: true,\n fontFamily: true,\n fontSize: true,\n fontSizeAdjust: true,\n fontStretch: true,\n fontStyle: true,\n fontVariant: true,\n fontWeight: true,\n format: true,\n from: true,\n fr: true, // valid SVG element but React will ask for removal\n fx: true,\n fy: true,\n g1: true,\n g2: true,\n glyphName: true,\n glyphOrientationHorizontal: true,\n glyphOrientationVertical: true,\n glyphRef: true,\n gradientTransform: true,\n gradientUnits: true,\n hanging: true,\n horizAdvX: true,\n horizOriginX: true,\n ideographic: true,\n imageRendering: true,\n in: true,\n in2: true,\n intercept: true,\n k: true,\n k1: true,\n k2: true,\n k3: true,\n k4: true,\n kernelMatrix: true,\n kernelUnitLength: true,\n kerning: true,\n keyPoints: true,\n keySplines: true,\n keyTimes: true,\n lengthAdjust: true,\n letterSpacing: true,\n lightingColor: true,\n limitingConeAngle: true,\n local: true,\n markerEnd: true,\n markerMid: true,\n markerStart: true,\n markerHeight: true,\n markerUnits: true,\n markerWidth: true,\n mask: true,\n maskContentUnits: true,\n maskUnits: true,\n mathematical: true,\n mode: true,\n numOctaves: true,\n offset: true,\n opacity: true,\n operator: true,\n order: true,\n orient: true,\n orientation: true,\n origin: true,\n overflow: true,\n overlinePosition: true,\n overlineThickness: true,\n panose1: true,\n paintOrder: true,\n pathLength: true,\n patternContentUnits: true,\n patternTransform: true,\n patternUnits: true,\n pointerEvents: true,\n points: true,\n pointsAtX: true,\n pointsAtY: true,\n pointsAtZ: true,\n preserveAlpha: true,\n preserveAspectRatio: true,\n primitiveUnits: true,\n r: true,\n radius: true,\n refX: true,\n refY: true,\n renderingIntent: true,\n repeatCount: true,\n repeatDur: true,\n requiredExtensions: true,\n requiredFeatures: true,\n restart: true,\n result: true,\n rotate: true,\n rx: true,\n ry: true,\n scale: true,\n seed: true,\n shapeRendering: true,\n slope: true,\n spacing: true,\n specularConstant: true,\n specularExponent: true,\n speed: true,\n spreadMethod: true,\n startOffset: true,\n stdDeviation: true,\n stemh: true,\n stemv: true,\n stitchTiles: true,\n stopColor: true,\n stopOpacity: true,\n strikethroughPosition: true,\n strikethroughThickness: true,\n string: true,\n stroke: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeLinecap: true,\n strokeLinejoin: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true,\n surfaceScale: true,\n systemLanguage: true,\n tableValues: true,\n targetX: true,\n targetY: true,\n textAnchor: true,\n textDecoration: true,\n textRendering: true,\n textLength: true,\n to: true,\n transform: true,\n u1: true,\n u2: true,\n underlinePosition: true,\n underlineThickness: true,\n unicode: true,\n unicodeBidi: true,\n unicodeRange: true,\n unitsPerEm: true,\n vAlphabetic: true,\n vHanging: true,\n vIdeographic: true,\n vMathematical: true,\n values: true,\n vectorEffect: true,\n version: true,\n vertAdvY: true,\n vertOriginX: true,\n vertOriginY: true,\n viewBox: true,\n viewTarget: true,\n visibility: true,\n widths: true,\n wordSpacing: true,\n writingMode: true,\n x: true,\n xHeight: true,\n x1: true,\n x2: true,\n xChannelSelector: true,\n xlinkActuate: true,\n xlinkArcrole: true,\n xlinkHref: true,\n xlinkRole: true,\n xlinkShow: true,\n xlinkTitle: true,\n xlinkType: true,\n xmlBase: true,\n xmlns: true,\n xmlnsXlink: true,\n xmlLang: true,\n xmlSpace: true,\n y: true,\n y1: true,\n y2: true,\n yChannelSelector: true,\n z: true,\n zoomAndPan: true,\n\n // For preact. We have this code here even though Emotion doesn't support\n // Preact, since @emotion/is-prop-valid is used by some libraries outside of\n // the context of Emotion.\n for: true,\n class: true,\n autofocus: true,\n};\n\nconst validProps = `^((${Object.keys(validPropsRecord).join(\n \"|\",\n)})|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$`;\n\nconst r = new RegExp(validProps);\n\nexport const isPropValid: (prop: string) => boolean = memoize(\n (prop: string) =>\n r.test(prop) ||\n (prop.charCodeAt(0) === 111 /* o */ &&\n prop.charCodeAt(1) === 110 /* n */ &&\n prop.charCodeAt(2) < 91) /* Z+1 */,\n);\n","import styled from \"@emotion/styled\";\nimport { Property } from \"csstype\";\n\nimport {\n background,\n BackgroundProps,\n border,\n borderBottom,\n BorderBottomProps,\n borderColor,\n borderLeft,\n BorderLeftProps,\n borderRadius,\n BorderRadiusProps,\n borderRight,\n BorderRightProps,\n borderStyle,\n BorderStyleProps,\n borderTop,\n BorderTopProps,\n borderWidth,\n BorderWidthProps,\n bottom,\n BottomProps,\n boxShadow,\n BoxShadowProps,\n flexbox,\n FlexboxProps,\n layout,\n LayoutProps,\n left,\n LeftProps,\n overflow,\n OverflowProps,\n position,\n PositionProps,\n ResponsiveValue,\n right,\n RightProps,\n system,\n TLengthStyledSystem,\n top,\n TopProps,\n zIndex,\n ZIndexProps,\n} from \"styled-system\";\nimport { DivProps } from \"../../../types/ElementProps\";\nimport {\n booleanOrNumberToMetricCalc,\n booleanOrNumberToNumber,\n} from \"../../../utils/BooleanOrNumberToNumber\";\nimport { isPropValid } from \"../../util/IsPropValid\";\n\ninterface StyledSystemProps\n extends BorderRadiusProps,\n BorderStyleProps,\n BorderWidthProps,\n BorderLeftProps,\n BorderRightProps,\n BorderTopProps,\n BorderBottomProps,\n FlexboxProps,\n LayoutProps,\n OverflowProps,\n PositionProps,\n ZIndexProps,\n LeftProps,\n RightProps,\n TopProps,\n BottomProps {}\n\nconst shadows = {\n box: \"var(--swui-shadow-box)\",\n popover: \"var(--swui-shadow-popover)\",\n modal: \"var(--swui-shadow-modal)\",\n bottom: \"var(--swui-shadow-bottom)\",\n};\n\ntype ShadowType = keyof typeof shadows;\n\nexport interface BoxProps extends StyledSystemProps, DivProps {\n /**\n * If true, children are placed in a row.\n */\n row?: ResponsiveValue<boolean>;\n\n /**\n * Adds spacing over and under content.\n */\n spacing?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing left and right of content.\n */\n indent?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing between children.\n */\n gap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between columns.\n */\n columnGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between rows.\n */\n rowGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds a shadow around the box.\n */\n shadow?: ResponsiveValue<Property.BoxShadow | ShadowType>;\n\n /**\n * Sets the background of the box.\n */\n background?: ResponsiveValue<Property.Background<TLengthStyledSystem>>;\n\n /**\n * Sets the border of the box.\n */\n border?: ResponsiveValue<Property.Border<TLengthStyledSystem>>;\n\n /**\n * Sets the border color of the box.\n */\n borderColor?: ResponsiveValue<Property.BorderColor>;\n\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when hovering with mouse.\n */\n hoverBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when the box is in focus.\n */\n focusBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when focus is within the box.\n */\n focusWithinBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when focus is within the box.\n */\n focusWithinBorder?: Property.Border<TLengthStyledSystem>;\n}\n\nconst excludedProps = [\n \"spacing\",\n \"indent\",\n \"gap\",\n \"width\",\n \"height\",\n \"overflow\",\n \"display\",\n];\n\nconst isExcludedWebUiProp = (propName: string) =>\n excludedProps.includes(propName);\n\nconst box = system({\n row: {\n property: \"flexDirection\",\n transform: (row: boolean) => (row ? \"row\" : \"column\"),\n },\n indent: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-indent\",\n transform: booleanOrNumberToNumber,\n },\n spacing: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-spacing\",\n transform: booleanOrNumberToNumber,\n },\n gap: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-gap\",\n transform: booleanOrNumberToNumber,\n },\n columnGap: {\n property: \"columnGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n rowGap: {\n property: \"rowGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n shadow: {\n property: \"boxShadow\",\n transform: (value: ShadowType) => shadows[value] ?? value,\n },\n});\n\ntype InnerProps = BoxProps & BoxShadowProps & BackgroundProps;\n\nexport const Box = styled(\"div\", {\n shouldForwardProp: (propName) =>\n typeof propName === \"string\"\n ? isExcludedWebUiProp(propName)\n ? false\n : isPropValid(propName)\n : false,\n})<InnerProps>`\n --current-spacing: 0;\n --current-indent: 0;\n --current-gap: 0;\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n ${box};\n ${background};\n ${border};\n ${borderRight};\n ${borderLeft};\n ${borderTop};\n ${borderBottom};\n ${borderColor};\n ${borderRadius};\n ${borderStyle};\n ${borderWidth};\n ${boxShadow};\n ${flexbox};\n ${overflow};\n ${position};\n ${layout};\n ${zIndex};\n ${left};\n ${right};\n ${top};\n ${bottom};\n\n gap: calc(var(--current-gap) * var(--swui-metrics-space));\n\n padding: calc(var(--current-spacing) * var(--swui-metrics-spacing))\n calc(var(--current-indent) * var(--swui-metrics-indent));\n\n :hover {\n ${({ hoverBackground }) =>\n hoverBackground ? `background: ${hoverBackground};` : \"\"}\n ${({ hoverBorder }) => (hoverBorder ? `border: ${hoverBorder};` : \"\")}\n }\n\n :focus {\n ${({ focusBackground }) =>\n focusBackground ? `background: ${focusBackground};` : \"\"}\n ${({ focusBorder }) => (focusBorder ? `border: ${focusBorder};` : \"\")}\n }\n\n :focus-within {\n ${({ focusWithinBackground }) =>\n focusWithinBackground ? `background: ${focusWithinBackground};` : \"\"}\n ${({ focusWithinBorder }) =>\n focusWithinBorder ? `border: ${focusWithinBorder};` : \"\"}\n }\n`;\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Column = forwardRef<HTMLDivElement, BoxProps>(\n function Column(props, ref) {\n return <Box ref={ref} {...props} />;\n },\n);\n","import { RefObject, useCallback, useLayoutEffect, useState } from \"react\";\n\nexport interface ElementDimensions {\n width: number;\n height: number;\n top: number;\n left: number;\n x: number;\n y: number;\n right: number;\n bottom: number;\n}\n\nexport const getDimensionObject = (node: HTMLElement): ElementDimensions => {\n const { x, y, width, height, bottom, top, left, right } =\n node.getBoundingClientRect();\n\n return {\n width,\n height,\n top,\n left,\n x,\n y,\n right,\n bottom,\n };\n};\n\nconst isEqualDimensions = (\n a: ElementDimensions,\n b: ElementDimensions,\n): boolean =>\n a.x === b.x &&\n a.y === b.y &&\n a.width === b.width &&\n a.height === b.height &&\n a.bottom === b.bottom &&\n a.top === b.top &&\n a.left === b.left &&\n a.right === b.right;\n\nexport const useElementDimensions = (\n ref: RefObject<HTMLElement | null>,\n onResizeElement?: (dimensions: ElementDimensions) => void,\n) => {\n const [dimensions, setDimensions] = useState<ElementDimensions | undefined>();\n\n const updateDimensions = useCallback(() => {\n window.requestAnimationFrame(() => {\n if (ref.current) {\n const newDimensions = getDimensionObject(ref.current);\n if (!dimensions || !isEqualDimensions(dimensions, newDimensions)) {\n if (onResizeElement) {\n onResizeElement(newDimensions);\n }\n }\n setDimensions(newDimensions);\n }\n });\n }, [ref, dimensions, setDimensions, onResizeElement]);\n\n useLayoutEffect(() => {\n updateDimensions();\n }, [updateDimensions]);\n\n return {\n dimensions,\n };\n};\n","import * as React from \"react\";\nimport { forwardRef, RefObject, useRef } from \"react\";\nimport { Box, BoxProps } from \"./Box\";\nimport {\n ElementDimensions,\n useElementDimensions,\n} from \"../../../hooks/UseElementDimensions\";\n\nexport interface ResizeAwareBoxProps extends Omit<BoxProps, \"onResize\"> {\n onResize?: (dimensions: ElementDimensions) => void;\n}\n\nexport const ResizeAwareBox = forwardRef<HTMLDivElement, ResizeAwareBoxProps>(\n function ResizeAwareBox({ onResize, ...boxProps }, ref) {\n const localRef = useRef<HTMLDivElement>(null);\n const currentRef = (ref as RefObject<HTMLDivElement>) ?? localRef;\n useElementDimensions(currentRef, onResize);\n\n return <Box {...boxProps} ref={ref} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Row = forwardRef<HTMLDivElement, BoxProps>(\n function Row(props, ref) {\n return <Box row ref={ref} {...props} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface IndentProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Indent = forwardRef<HTMLDivElement, IndentProps>(function Indent(\n { num = 1, ...props },\n ref,\n) {\n return <Box indent={num} ref={ref} {...props} />;\n});\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface SpacingProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Spacing = forwardRef<HTMLDivElement, SpacingProps>(\n function Spacing({ num = 1, ...props }, ref) {\n return <Box spacing={num} ref={ref} {...props} />;\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\n\nexport interface SpaceProps {\n half?: boolean;\n horizontal?: boolean;\n num?: number;\n vertical?: boolean;\n}\n\nconst InnerSpace = styled.div`\n --current-size: 1;\n flex: none;\n width: calc(var(--current-size) * var(--swui-metrics-space));\n height: calc(var(--current-size) * var(--swui-metrics-space));\n`;\n\nexport const Space: React.FC<SpaceProps> = ({\n half = false,\n horizontal = false,\n num = 1,\n vertical = false,\n}) => {\n const size = num * (half ? 0.5 : 1);\n\n return (\n <InnerSpace\n style={{\n [\"--current-size\" as string]: size,\n height: horizontal ? 1 : undefined,\n width: vertical ? 1 : undefined,\n }}\n />\n );\n};\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\n\ninterface Props {\n nest?: boolean;\n render: (children: ReactNode) => ReactNode;\n children?: ReactNode;\n}\n\nexport const Nest: React.FC<Props> = ({ children, nest, render }) => {\n if (nest) {\n return <>{render(children)}</>;\n }\n return <>{children}</>;\n};\n","import { pickBy } from \"lodash-es\";\n\nexport const getDataProps = <T extends Record<string, unknown>>(\n props: Record<string, unknown> | object,\n): T => pickBy(props, isDataPropMapper) as T;\n\nconst isDataPropMapper = (_: unknown, key: string): boolean => isDataProp(key);\n\nconst isDataProp = <TProp extends string>(propName: TProp): boolean =>\n propName.startsWith(\"data-\") || propName.startsWith(\"aria-\");\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\nimport styles from \"./ScreenReaderOnlyText.module.css\";\nimport { getDataProps } from \"../../utils/PropsForwarder\";\n\nexport interface ScreenReaderOnlyTextProps {\n children?: ReactNode;\n}\n\nexport const ScreenReaderOnlyText: React.FC<ScreenReaderOnlyTextProps> = ({\n children,\n ...props\n}) => {\n return (\n <span className={styles.visuallyHidden} {...getDataProps(props)}>\n {children}\n </span>\n );\n};\n","import * as React from \"react\";\nimport cx from \"classnames\";\nimport styles from \"./Text.module.css\";\nimport { SpanProps } from \"../../types/ElementProps\";\nimport { Property } from \"csstype\";\nimport { forwardRef } from \"react\";\n\nexport interface TextProps extends SpanProps {\n variant?: TextVariant;\n size?: TextSize;\n userSelect?: Property.UserSelect;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n textAlign?: Property.TextAlign;\n color?: string;\n}\n\nexport type TextVariant = \"standard\" | \"caption\" | \"overline\" | \"bold\";\nexport type TextSize = \"large\" | \"medium\" | \"small\" | \"smaller\";\n\nexport const Text = forwardRef<HTMLSpanElement, TextProps>(\n (\n {\n children,\n variant = \"standard\",\n size = \"medium\",\n className,\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n style,\n ...spanProps\n },\n ref,\n ) => {\n return (\n <span\n className={cx(styles.text, styles[variant], styles[size], className)}\n ref={ref}\n style={{\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n ...style,\n }}\n {...spanProps}\n >\n {children}\n </span>\n );\n },\n);\n\nexport const Txt = Text;\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"small\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallerText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"smaller\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const StandardText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"medium\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const LargeText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"large\"} {...props} />;\n};\n","import cx from \"classnames\";\nimport { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { H1Props } from \"../../types/ElementProps\";\nimport styles from \"./Heading.module.css\";\n\nexport interface HeadingProps extends H1Props {\n variant?: HeadingVariant;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n as?: HeadingVariant;\n}\n\nexport type HeadingVariant = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\nexport const Heading = forwardRef<HTMLHeadingElement, HeadingProps>(\n (\n {\n variant = \"h3\",\n className,\n color,\n whiteSpace,\n wordBreak,\n style,\n children,\n as,\n ...hProps\n },\n ref,\n ) => {\n const Element = as ?? variant;\n return (\n <Element\n className={cx(styles.heading, styles[variant], className)}\n style={{ color, whiteSpace, wordBreak, ...style }}\n ref={ref}\n {...hProps}\n >\n {children}\n </Element>\n );\n },\n);\n","import * as React from \"react\";\nimport { Heading, HeadingProps } from \"../heading/Heading\";\n\n/**\n * @deprecated Please use `Heading` instead.\n */\nexport const HeaderText: React.FC<Omit<HeadingProps, \"variant\">> = (props) => {\n return <Heading variant={\"h2\"} {...props} />;\n};\n","import { useCallback } from \"react\";\n\ntype ArrayItemEqualsComparator<T> = (a: T, b: T) => boolean;\n\nconst defaultComparator = <T>(a: T, b: T) => a === b;\n\nexport const useArraySet = <T>(\n list: Array<T>,\n setList: (list: Array<T>) => void,\n comparator: ArrayItemEqualsComparator<T> = defaultComparator,\n) => {\n const add = useCallback(\n (item: T) => {\n if (!list.some((l) => comparator(l, item))) {\n setList([...list, item]);\n }\n },\n [list, setList, comparator],\n );\n\n const addMultiple = useCallback(\n (items: Array<T>) => {\n setList(\n items.reduce((list, item) => {\n if (!list.some((l) => comparator(l, item))) {\n return [...list, item];\n }\n return list;\n }, list),\n );\n },\n [list, setList, comparator],\n );\n\n const remove = useCallback(\n (item: T) => {\n const index = list.findIndex((l) => comparator(l, item));\n if (index >= 0) {\n setList(list.filter((_, i) => i !== index));\n }\n },\n [list, setList, comparator],\n );\n\n const removeMultiple = useCallback(\n (items: Array<T>) => {\n setList(list.filter((item) => !items.some((l) => comparator(l, item))));\n },\n [list, setList, comparator],\n );\n\n const toggle = useCallback(\n (item: T) => {\n const found = list.some((l) => comparator(l, item));\n if (found) {\n remove(item);\n } else {\n add(item);\n }\n },\n [list, add, remove, comparator],\n );\n\n return {\n add,\n addMultiple,\n remove,\n removeMultiple,\n toggle,\n };\n};\n","import { useCallback, useState } from \"react\";\n\ntype Value = boolean;\ntype SetTrue = () => void;\ntype SetFalse = () => void;\ntype ToggleValue = () => void;\ntype BooleanHook = [Value, SetTrue, SetFalse, ToggleValue];\n\nexport const useBoolean = (initialValue: Value): BooleanHook => {\n const [value, setValue] = useState(initialValue);\n\n const setTrue = useCallback(() => {\n setValue(true);\n }, [setValue]);\n\n const setFalse = useCallback(() => {\n setValue(false);\n }, [setValue]);\n\n const toggle = useCallback(() => {\n setValue((v) => !v);\n }, [setValue]);\n\n return [value, setTrue, setFalse, toggle];\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDebounce = <T>(value: T, delay: number): T => {\n // State and setters for debounced value\n const [debouncedValue, setDebouncedValue] = useState<T>(value);\n\n useEffect(() => {\n // Update debounced value after delay\n const handler = setTimeout(() => {\n setDebouncedValue(value);\n }, delay);\n\n // Cancel the timeout if value changes (also on delay change or unmount)\n // This is how we prevent debounced value from updating if value is changed ...\n // .. within the delay period. Timeout gets cleared and restarted.\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]); // Only re-call effect if value or delay changes\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDelayedFalse = (value: boolean, delay: number) => {\n const [debouncedValue, setDebouncedValue] = useState<boolean>(value);\n\n useEffect(() => {\n if (value) {\n setDebouncedValue(true);\n }\n\n const handler = setTimeout(() => {\n if (!value) {\n setDebouncedValue(value);\n }\n }, delay);\n\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]);\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nlet id = 0;\nconst genId = (componentName?: string) =>\n `webui-${componentName ? componentName + \"-\" : \"\"}${++id}`;\n\n/** @deprecated use useId-hook from React 18 */\nexport const useDomId = (componentName?: string): string => {\n const [id, setId] = useState<string | null>(() => genId(componentName));\n useEffect(() => setId(genId(componentName)), [componentName]);\n return id!;\n};\n","import { RefObject, useEffect, useRef } from \"react\";\n\ntype EventHandler<TEventName extends keyof HTMLElementEventMap> = (\n event: HTMLElementEventMap[TEventName],\n) => void;\n\nexport const useEventListener = <TEventName extends keyof HTMLElementEventMap>(\n ref: RefObject<HTMLElement | null>,\n eventName: TEventName,\n handler: EventHandler<TEventName>,\n) => {\n // Create a ref that stores handler\n const savedHandler = useRef<EventHandler<TEventName>>(null);\n\n // Update ref.current value if handler changes.\n // This allows our effect below to always get latest handler ...\n // ... without us needing to pass it in effect deps array ...\n // ... and potentially cause effect to re-run every render.\n useEffect(() => {\n savedHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n // Make sure element supports addEventListener\n const isSupported = ref.current && ref.current.addEventListener;\n if (!isSupported) return;\n\n // Create event listener that calls handler function stored in ref\n const eventListener: EventHandler<TEventName> = (event) => {\n if (savedHandler.current) {\n return savedHandler.current(event);\n }\n };\n\n // Add event listener\n if (!ref.current) {\n return;\n }\n\n const element = ref.current;\n element.addEventListener(eventName, eventListener);\n\n // Remove event listener on cleanup\n return () => {\n if (element) {\n element.removeEventListener(eventName, eventListener);\n }\n };\n }, [eventName, ref]); // Re-run if eventName or element changes\n};\n","import { RefObject, useCallback, useEffect } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useElementFocus = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [isInFocus, setIsInFocus, setIsNotInFocus] = useBoolean(false);\n\n useEffect(() => {\n if (document.activeElement === ref.current) {\n setIsInFocus();\n } else {\n setIsNotInFocus();\n }\n }, [ref, setIsNotInFocus, setIsInFocus]);\n\n useEventListener(ref, \"focus\", setIsInFocus);\n useEventListener(ref, \"blur\", setIsNotInFocus);\n\n const focus = useCallback(() => {\n if (ref.current) {\n ref.current.focus();\n }\n }, [ref]);\n\n const blur = useCallback(() => {\n if (ref.current) {\n ref.current.blur();\n }\n }, [ref]);\n\n return { isInFocus, focus, blur };\n};\n","import { useCallback, useLayoutEffect, useRef } from \"react\";\n\ntype Fn<ARGS extends unknown[], R> = (...args: ARGS) => R;\n\nexport const useEventCallback = <A extends unknown[], R>(\n fn: Fn<A, R>,\n): Fn<A, R> => {\n const ref = useRef<Fn<A, R>>(fn);\n useLayoutEffect(() => {\n ref.current = fn;\n });\n return useCallback((...args: A): R => {\n const { current } = ref;\n return current(...args);\n }, []);\n};\n","import React, { MutableRefObject } from \"react\";\n\nexport const useLatest = <T>(value: T): MutableRefObject<T> => {\n const ref = React.useRef(value);\n ref.current = value;\n return ref;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsOver = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsOver, setMouseIsOver, setMouseIsNotOver] = useBoolean(false);\n\n useEventListener(ref, \"mouseover\", setMouseIsOver);\n useEventListener(ref, \"mouseout\", setMouseIsNotOver);\n\n return mouseIsOver;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsEntered = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsEntered, setMouseIsEntered, setMouseIsNotEntered] =\n useBoolean(false);\n\n useEventListener(ref, \"mouseenter\", setMouseIsEntered);\n useEventListener(ref, \"mouseleave\", setMouseIsNotEntered);\n\n return mouseIsEntered;\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useMultiOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n refs: Array<React.RefObject<any>>,\n handler: (event: TouchEvent | MouseEvent) => void,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n\n const allNotContains = refs\n .filter((ref) => ref.current)\n .every((ref) => {\n return ref.current && !ref.current.contains(event.target);\n });\n\n if (!allNotContains) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener);\n document.addEventListener(\"touchstart\", listener);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener);\n document.removeEventListener(\"touchstart\", listener);\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [...refs]);\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ref: React.RefObject<any>,\n handler: (event: TouchEvent | MouseEvent) => void,\n options?: AddEventListenerOptions,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n if (!ref.current || ref.current.contains(event.target)) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener, options);\n document.addEventListener(\"touchstart\", listener, options);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener, options);\n document.removeEventListener(\"touchstart\", listener, options);\n };\n }, [ref, options]);\n};\n","import { debounce } from \"lodash-es\";\nimport { useEffect, useRef } from \"react\";\n\nconst events = [\"mousemove\", \"mousedown\", \"keydown\", \"touchstart\", \"scroll\"];\n\nexport const useOnNoMouseMovement = (callback: () => void, delay: number) => {\n const eventHandler = useRef<(event: Event) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = callback;\n }, [callback]);\n\n useEffect(() => {\n const onIdleChange = debounce(eventHandler.current, delay);\n events.forEach((event) => window.addEventListener(event, onIdleChange));\n\n return () => {\n events.forEach((event) =>\n window.removeEventListener(event, onIdleChange),\n );\n };\n }, [delay]);\n};\n","import { RefObject, useEffect, useMemo, useState } from \"react\";\n\nexport const useOnScreen = (\n ref: RefObject<Element | null>,\n options?: IntersectionObserverInit,\n) => {\n const [isVisible, setIsVisible] = useState(false);\n\n const { rootMargin, root, threshold } = options || {};\n\n const observer = useMemo(() => {\n return new IntersectionObserver(\n ([entry]) => setIsVisible(entry.isIntersecting),\n {\n rootMargin,\n root,\n threshold,\n },\n );\n }, [setIsVisible, rootMargin, root, threshold]);\n\n useEffect(() => {\n if (ref.current) {\n observer.observe(ref.current);\n }\n return () => {\n observer.disconnect();\n };\n }, [observer, ref]);\n\n return isVisible;\n};\n","import {\n MutableRefObject,\n RefCallback,\n RefObject,\n useEffect,\n useRef,\n} from \"react\";\n\nexport const useForwardedRef = <T>(\n ref: RefCallback<T> | MutableRefObject<T> | null,\n): RefObject<NonNullable<T>> => {\n const innerRef = useRef<T>(null) as MutableRefObject<NonNullable<T>>;\n\n useEffect(() => {\n if (!ref) return;\n if (typeof ref === \"function\") {\n ref(innerRef.current);\n } else {\n ref.current = innerRef.current;\n }\n });\n\n return innerRef;\n};\n","import { useCallback, useEffect, useRef, useState } from \"react\";\n\nexport const useTimeoutState = <S>(\n initialValue: S,\n defaultTimeout: number,\n clearTimeoutOnSetValue = true,\n): [S, (v: S) => void] => {\n const [value, setValue] = useState<S>(initialValue);\n const timeoutRef = useRef<NodeJS.Timeout>(null);\n\n const wrappedSetter = useCallback(\n (newValue: S, timeout = defaultTimeout) => {\n setValue(newValue);\n if (clearTimeoutOnSetValue) {\n clearTimeout(timeoutRef.current!);\n }\n timeoutRef.current = setTimeout(() => setValue(initialValue), timeout);\n },\n [defaultTimeout, clearTimeoutOnSetValue, initialValue],\n );\n\n useEffect(() => {\n return () => {\n clearTimeout(timeoutRef.current!);\n };\n }, []);\n\n return [value, wrappedSetter];\n};\n","import { useMemo } from \"react\";\n\nexport const useToday = () => {\n return useMemo(() => new Date(), []);\n};\n","export const byStringField =\n <T>(fieldResolver: (item: T) => string) =>\n (a: T, b: T): number =>\n fieldResolver(a).localeCompare(fieldResolver(b));\n\nexport const byNumberField =\n <T>(fieldResolver: (item: T) => number) =>\n (a: T, b: T): number =>\n fieldResolver(a) - fieldResolver(b);\n","export const exhaustSwitchCaseElseThrow = (arg: never) => {\n throw new Error(`Switch unhandled case: ${arg}`);\n};\n\nexport const exhaustSwitchCase = <T>(_arg: never, fallback: T) => {\n return fallback;\n};\n","export const truthyKeysAsList = (r: Record<string, boolean>): Array<string> =>\n Object.keys(r).filter((key) => r[key]);\n","export const parseFloatElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseFloat(s);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n\nexport const parseIntElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseInt(s, 10);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n","export function invariant<T>(\n val: T | null | undefined,\n message: string,\n): asserts val is T {\n if (val == null) {\n throw new Error(\"Invariant error: \" + message);\n }\n}\n"],"names":["SeparatorLine","forwardRef","color","cssColor","size","width","vertical","ref","jsx","styles","ClickableElement","styled","background","pointer","props","hoverBackground","disableOpacityOnClick","disableFocusHighlight","focusBackground","height","borderRadius","Clickable","onClick","onDblClick","tooltip","disablePointer","opacityOnHover","disabled","children","type","restProps","hasClickHandler","booleanOrNumberToNumber","num","numberToMetricCalc","booleanOrNumberToMetricCalc","validPropsRecord","validProps","r","isPropValid","memoize","prop","shadows","excludedProps","isExcludedWebUiProp","propName","box","system","row","value","Box","border","borderRight","borderLeft","borderTop","borderBottom","borderColor","borderStyle","borderWidth","boxShadow","flexbox","overflow","position","layout","zIndex","left","right","top","bottom","hoverBorder","focusBorder","focusWithinBackground","focusWithinBorder","Column","getDimensionObject","node","x","y","isEqualDimensions","a","b","useElementDimensions","onResizeElement","dimensions","setDimensions","useState","updateDimensions","useCallback","newDimensions","useLayoutEffect","ResizeAwareBox","onResize","boxProps","localRef","useRef","Row","Indent","Spacing","InnerSpace","Space","half","horizontal","Nest","nest","render","Fragment","getDataProps","pickBy","isDataPropMapper","_","key","isDataProp","ScreenReaderOnlyText","Text","variant","className","userSelect","whiteSpace","wordBreak","textAlign","style","spanProps","cx","Txt","SmallText","SmallerText","StandardText","LargeText","Heading","as","hProps","Element","HeaderText","defaultComparator","useArraySet","list","setList","comparator","add","item","l","addMultiple","items","remove","index","i","removeMultiple","toggle","useBoolean","initialValue","setValue","setTrue","setFalse","v","useDebounce","delay","debouncedValue","setDebouncedValue","useEffect","handler","useDelayedFalse","id","genId","componentName","useDomId","setId","useEventListener","eventName","savedHandler","eventListener","event","element","useElementFocus","isInFocus","setIsInFocus","setIsNotInFocus","focus","blur","useEventCallback","fn","args","current","useLatest","React","useMouseIsOver","mouseIsOver","setMouseIsOver","setMouseIsNotOver","useMouseIsEntered","mouseIsEntered","setMouseIsEntered","setMouseIsNotEntered","useMultiOnClickOutside","refs","eventHandler","listener","useOnClickOutside","options","events","useOnNoMouseMovement","callback","onIdleChange","debounce","useOnScreen","isVisible","setIsVisible","rootMargin","root","threshold","observer","useMemo","entry","useForwardedRef","innerRef","useTimeoutState","defaultTimeout","clearTimeoutOnSetValue","timeoutRef","wrappedSetter","newValue","timeout","useToday","byStringField","fieldResolver","byNumberField","exhaustSwitchCaseElseThrow","arg","exhaustSwitchCase","_arg","fallback","truthyKeysAsList","parseFloatElseUndefined","s","f","parseIntElseUndefined","invariant","val","message"],"mappings":"gUAaaA,EAAgBC,EAAA,WAC3B,CACE,CACE,MAAAC,EAAQC,WAAS,qBAAqB,EACtC,KAAAC,EAAO,OACP,MAAAC,EAAQ,MACR,SAAAC,EAAW,IAEbC,IAGEC,EAAA,IAAC,KAAA,CACC,UAAWC,EAAO,cAClB,cAAa,GACb,MAAAP,EACA,MAAO,CACL,gBAAiBA,EACjB,OAAQI,EAAWF,GAAQ,OAASC,GAAS,MAC7C,MAAOC,EAAWD,GAAS,MAAQD,GAAQ,MAC7C,EACA,IAAAG,CAAA,CACF,CAGN,EC0BMG,EAAmBC,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA,gBAKhB,CAAC,CAAE,WAAAC,CAAW,IAA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wE,GAAQxE,EAAEwE,CAAG,CAAC,ECD1ByH,GAA2BC,GAAkC,CACpE,GAAA,CACI,MAAAC,EAAI,WAAWD,CAAC,EAItB,OAHI,MAAMC,CAAC,GAGPA,GAAK,KACA,OAEFA,CAAA,MACD,CAAA,CAIV,EAEaC,GAAyBF,GAAkC,CAClE,GAAA,CACI,MAAAC,EAAI,SAASD,EAAG,EAAE,EAIxB,OAHI,MAAMC,CAAC,GAGPA,GAAK,KACA,OAEFA,CAAA,MACD,CAAA,CAIV,EC9BgB,SAAAE,GACdC,EACAC,EACkB,CAClB,GAAID,GAAO,KACH,MAAA,IAAI,MAAM,oBAAsBC,CAAO,CAEjD"}
1
+ {"version":3,"file":"index.js","sources":["../src/components/decorators/separatorline/SeparatorLine.tsx","../src/components/interaction/Clickable.tsx","../src/utils/BooleanOrNumberToNumber.ts","../src/components/util/IsPropValid.ts","../src/components/layout/box/Box.tsx","../src/components/layout/column/Column.tsx","../src/hooks/UseElementDimensions.ts","../src/components/layout/box/ResizeAwareBox.tsx","../src/components/layout/row/Row.tsx","../src/components/layout/indent/Indent.tsx","../src/components/layout/spacing/Spacing.tsx","../src/components/layout/space/Space.tsx","../src/components/util/Nest.tsx","../src/utils/PropsForwarder.ts","../src/components/accessibility/ScreenReaderOnlyText.tsx","../src/components/text/Text.tsx","../src/components/deprecated-text/SmallText.tsx","../src/components/deprecated-text/SmallerText.tsx","../src/components/deprecated-text/StandardText.tsx","../src/components/deprecated-text/LargeText.tsx","../src/components/heading/Heading.tsx","../src/components/deprecated-text/HeaderText.tsx","../src/hooks/UseArraySet.ts","../src/hooks/UseBoolean.ts","../src/hooks/UseDebounce.ts","../src/hooks/UseDelayedFalse.ts","../src/hooks/UseDomId.ts","../src/hooks/UseEventListener.ts","../src/hooks/UseElementFocus.ts","../src/hooks/UseEventCallback.tsx","../src/hooks/UseLatest.ts","../src/hooks/UseMouseIsOver.ts","../src/hooks/UseMouseIsEntered.ts","../src/hooks/UseMultiOnClickOutside.ts","../src/hooks/UseOnClickOutside.ts","../src/hooks/UseOnNoMouseInput.ts","../src/hooks/UseOnScreen.ts","../src/hooks/UseForwardedRef.ts","../src/hooks/UseTimeoutState.ts","../src/hooks/UseToday.ts","../src/sorting/Comparators.ts","../src/utils/SwitchCaseExhauster.ts","../src/utils/TruthyKeysAsList.ts","../src/utils/parsers/NumberParser.ts","../src/utils/Invariant.ts"],"sourcesContent":["import { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { cssColor } from \"@stenajs-webui/theme\";\nimport styles from \"./SeparatorLine.module.css\";\n\nexport interface SeparatorLineProps {\n color?: Property.Color;\n vertical?: boolean;\n size?: string;\n width?: string;\n}\n\nexport const SeparatorLine = forwardRef<HTMLHRElement, SeparatorLineProps>(\n (\n {\n color = cssColor(\"--lhds-color-ui-300\"),\n size = \"100%\",\n width = \"1px\",\n vertical = false,\n },\n ref,\n ) => {\n return (\n <hr\n className={styles.separatorLine}\n aria-hidden={true}\n color={color}\n style={{\n backgroundColor: color,\n height: vertical ? size || \"100%\" : width || \"1px\",\n width: vertical ? width || \"1px\" : size || \"100%\",\n }}\n ref={ref}\n />\n );\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\nimport { CSSProperties, forwardRef, MouseEventHandler } from \"react\";\nimport { ButtonElementProps } from \"../../types/ElementProps\";\n\nexport interface ClickableProps extends ButtonElementProps {\n /** Callback function called when clicking on click area. */\n onClick?: MouseEventHandler<HTMLButtonElement>;\n /** Callback function called when double clicking on click area. */\n onDblClick?: MouseEventHandler<HTMLButtonElement>;\n /** Adds a title to the click area. */\n tooltip?: string;\n /** If set, there is no opacity applies when clicking on the click area. */\n disableOpacityOnClick?: boolean;\n /** Mouse does not turn into pointer when hovering over click area. */\n disablePointer?: boolean;\n /** When set, click area receives opacity when mouse hovers over it. */\n opacityOnHover?: boolean;\n /** Custom style on div with click event. */\n style?: CSSProperties;\n /** Disables shadow when element is focused. */\n disableFocusHighlight?: boolean;\n /** Disables the HTML button element. */\n disabled?: boolean;\n /**\n * Sets the background of the box.\n */\n background?: string;\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: string;\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: string;\n /**\n * The width.\n */\n width?: string;\n /**\n * The height.\n */\n height?: string;\n /**\n * Border radius\n */\n borderRadius?: string;\n}\n\ninterface ClickableElementProps {\n disableOpacityOnClick?: boolean;\n opacityOnHover?: boolean;\n disableFocusHighlight?: boolean;\n pointer?: boolean;\n background?: string;\n focusBackground?: string;\n hoverBackground?: string;\n width?: string;\n height?: string;\n borderRadius?: string;\n}\n\nconst ClickableElement = styled.button<ClickableElementProps>`\n display: inline-block;\n user-select: none;\n border: 0;\n padding: 0;\n background: ${({ background }) => background};\n ${({ pointer }) => (pointer ? \"cursor: pointer;\" : \"\")}\n\n :hover {\n ${(props) => (props.opacityOnHover ? \"opacity: 0.7;\" : \"\")};\n ${({ hoverBackground }) => `background: ${hoverBackground};`}\n }\n :active {\n ${({ disableOpacityOnClick }) =>\n !disableOpacityOnClick ? \"opacity: 0.5;\" : \"\"}\n }\n :focus {\n outline: 0;\n ${({ disableFocusHighlight }) =>\n disableFocusHighlight\n ? \"\"\n : \"box-shadow: 0 0 3pt 2pt rgba(0, 0, 100, 0.3);\"}\n ${({ focusBackground }) => `background: ${focusBackground};`}\n }\n ${({ width }) => (width ? `width: ${width};` : \"\")}\n ${({ height }) => (height ? `height: ${height};` : \"\")}\n ${({ borderRadius }) =>\n borderRadius ? `border-radius: ${borderRadius};` : \"\"}\n`;\n\nexport const Clickable = forwardRef<HTMLButtonElement, ClickableProps>(\n (\n {\n disableFocusHighlight,\n onClick,\n onDblClick,\n tooltip,\n disableOpacityOnClick,\n disablePointer,\n opacityOnHover,\n disabled,\n children,\n background = \"transparent\",\n hoverBackground,\n focusBackground,\n type = \"button\",\n ...restProps\n },\n ref,\n ) => {\n const hasClickHandler = !!(onClick || onDblClick);\n\n return (\n <ClickableElement\n opacityOnHover={opacityOnHover}\n title={tooltip}\n disabled={disabled}\n disableOpacityOnClick={disableOpacityOnClick}\n onClick={onClick}\n onDoubleClick={onDblClick}\n disableFocusHighlight={disableFocusHighlight}\n pointer={hasClickHandler && !disablePointer}\n ref={ref}\n background={background}\n hoverBackground={hoverBackground}\n focusBackground={focusBackground}\n type={type}\n {...restProps}\n >\n {children}\n </ClickableElement>\n );\n },\n);\n","export const booleanOrNumberToNumber = (\n num: number | boolean | undefined,\n): number => {\n if (num == null) {\n return 0;\n }\n if (typeof num === \"boolean\") {\n return num ? 1 : 0;\n }\n return num;\n};\n\nexport const numberToMetricCalc = (num: number): string | undefined => {\n if (num === 0) {\n return undefined;\n }\n return `calc(${num} * var(--swui-metrics-space))`;\n};\n\nexport const booleanOrNumberToMetricCalc = (\n num: number | boolean | undefined,\n): string | undefined => numberToMetricCalc(booleanOrNumberToNumber(num));\n","import { memoize } from \"lodash-es\";\n\nconst validPropsRecord = {\n // react props\n // https://github.com/facebook/react/blob/5495a7f24aef85ba6937truetrue1ce962673ca9f5fde6/src/renderers/dom/shared/hooks/ReactDOMUnknownPropertyHook.js\n children: true,\n dangerouslySetInnerHTML: true,\n key: true,\n ref: true,\n autoFocus: true,\n defaultValue: true,\n defaultChecked: true,\n innerHTML: true,\n suppressContentEditableWarning: true,\n suppressHydrationWarning: true,\n // deprecated react prop\n valueLink: true,\n\n // https://github.com/facebook/react/blob/d7157651f7b72d9888ctrue123e191f9b88cd8f41e9/src/renderers/dom/shared/HTMLDOMPropertyConfig.js\n /**\n * Standard Properties\n */\n\n abbr: true,\n accept: true,\n acceptCharset: true,\n accessKey: true,\n action: true,\n allow: true,\n allowUserMedia: true,\n allowPaymentRequest: true,\n allowFullScreen: true,\n allowTransparency: true,\n alt: true,\n // specifies target context for links with `preload` type\n // as: true,\n async: true,\n autoComplete: true,\n // autoFocus is polyfilled/normalized by AutoFocusUtils\n // autoFocus: true,\n autoPlay: true,\n capture: true,\n cellPadding: true,\n cellSpacing: true,\n // keygen prop\n challenge: true,\n charSet: true,\n checked: true,\n cite: true,\n classID: true,\n className: true,\n cols: true,\n colSpan: true,\n content: true,\n contentEditable: true,\n contextMenu: true,\n controls: true,\n controlsList: true,\n coords: true,\n crossOrigin: true,\n data: true, // For `<object />` acts as `src`.\n dateTime: true,\n decoding: true,\n default: true,\n defer: true,\n dir: true,\n disabled: true,\n disablePictureInPicture: true,\n disableRemotePlayback: true,\n download: true,\n draggable: true,\n encType: true,\n enterKeyHint: true,\n form: true,\n formAction: true,\n formEncType: true,\n formMethod: true,\n formNoValidate: true,\n formTarget: true,\n frameBorder: true,\n headers: true,\n height: true,\n hidden: true,\n high: true,\n href: true,\n hrefLang: true,\n htmlFor: true,\n httpEquiv: true,\n id: true,\n inputMode: true,\n integrity: true,\n is: true,\n keyParams: true,\n keyType: true,\n kind: true,\n label: true,\n lang: true,\n list: true,\n loading: true,\n loop: true,\n low: true,\n // manifest: true,\n marginHeight: true,\n marginWidth: true,\n max: true,\n maxLength: true,\n media: true,\n mediaGroup: true,\n method: true,\n min: true,\n minLength: true,\n // Caution; `option.selected` is not updated if `select.multiple` is\n // disabled with `removeAttribute`.\n multiple: true,\n muted: true,\n name: true,\n nonce: true,\n noValidate: true,\n open: true,\n optimum: true,\n pattern: true,\n placeholder: true,\n playsInline: true,\n poster: true,\n preload: true,\n profile: true,\n radioGroup: true,\n readOnly: true,\n referrerPolicy: true,\n rel: true,\n required: true,\n reversed: true,\n role: true,\n rows: true,\n rowSpan: true,\n sandbox: true,\n scope: true,\n scoped: true,\n scrolling: true,\n seamless: true,\n selected: true,\n shape: true,\n size: true,\n sizes: true,\n // support for projecting regular DOM Elements via V1 named slots ( shadow dom )\n slot: true,\n span: true,\n spellCheck: true,\n src: true,\n srcDoc: true,\n srcLang: true,\n srcSet: true,\n start: true,\n step: true,\n style: true,\n summary: true,\n tabIndex: true,\n target: true,\n title: true,\n translate: true,\n // Setting .type throws on non-<input> tags\n type: true,\n useMap: true,\n value: true,\n width: true,\n wmode: true,\n wrap: true,\n\n /**\n * RDFa Properties\n */\n about: true,\n datatype: true,\n inlist: true,\n prefix: true,\n // property is also supported for OpenGraph in meta tags.\n property: true,\n resource: true,\n typeof: true,\n vocab: true,\n\n /**\n * Non-standard Properties\n */\n // autoCapitalize and autoCorrect are supported in Mobile Safari for\n // keyboard hints.\n autoCapitalize: true,\n autoCorrect: true,\n // autoSave allows WebKit/Blink to persist values of input fields on page reloads\n autoSave: true,\n // color is for Safari mask-icon link\n color: true,\n // https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/search#incremental_This_API_has_not_been_standardized\n incremental: true,\n // used in amp html for indicating the fallback behavior\n // https://amp.dev/documentation/guides-and-tutorials/develop/style_and_layout/placeholders/\n fallback: true,\n // https://html.spec.whatwg.org/multipage/interaction.html#inert\n inert: true,\n // itemProp, itemScope, itemType are for\n // Microdata support. See http://schema.org/docs/gs.html\n itemProp: true,\n itemScope: true,\n itemType: true,\n // itemID and itemRef are for Microdata support as well but\n // only specified in the WHATWG spec document. See\n // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api\n itemID: true,\n itemRef: true,\n // used in amp html for eventing purposes\n // https://amp.dev/documentation/guides-and-tutorials/learn/common_attributes/\n on: true,\n // used in amp html for indicating that the option is selectable\n // https://amp.dev/documentation/components/amp-selector/\n option: true,\n // results show looking glass icon and recent searches on input\n // search fields in WebKit/Blink\n results: true,\n // IE-only attribute that specifies security restrictions on an iframe\n // as an alternative to the sandbox attribute on IE<1true\n security: true,\n // IE-only attribute that controls focus behavior\n unselectable: true,\n //\n // SVG properties: https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\n // The following \"onX\" events have been omitted:\n //\n // onabort\n // onactivate\n // onbegin\n // onclick\n // onend\n // onerror\n // onfocusin\n // onfocusout\n // onload\n // onmousedown\n // onmousemove\n // onmouseout\n // onmouseover\n // onmouseup\n // onrepeat\n // onresize\n // onscroll\n // onunload\n accentHeight: true,\n accumulate: true,\n additive: true,\n alignmentBaseline: true,\n allowReorder: true,\n alphabetic: true,\n amplitude: true,\n arabicForm: true,\n ascent: true,\n attributeName: true,\n attributeType: true,\n autoReverse: true,\n azimuth: true,\n baseFrequency: true,\n baselineShift: true,\n baseProfile: true,\n bbox: true,\n begin: true,\n bias: true,\n by: true,\n calcMode: true,\n capHeight: true,\n clip: true,\n clipPathUnits: true,\n clipPath: true,\n clipRule: true,\n colorInterpolation: true,\n colorInterpolationFilters: true,\n colorProfile: true,\n colorRendering: true,\n contentScriptType: true,\n contentStyleType: true,\n cursor: true,\n cx: true,\n cy: true,\n d: true,\n decelerate: true,\n descent: true,\n diffuseConstant: true,\n direction: true,\n display: true,\n divisor: true,\n dominantBaseline: true,\n dur: true,\n dx: true,\n dy: true,\n edgeMode: true,\n elevation: true,\n enableBackground: true,\n end: true,\n exponent: true,\n externalResourcesRequired: true,\n fill: true,\n fillOpacity: true,\n fillRule: true,\n filter: true,\n filterRes: true,\n filterUnits: true,\n floodColor: true,\n floodOpacity: true,\n focusable: true,\n fontFamily: true,\n fontSize: true,\n fontSizeAdjust: true,\n fontStretch: true,\n fontStyle: true,\n fontVariant: true,\n fontWeight: true,\n format: true,\n from: true,\n fr: true, // valid SVG element but React will ask for removal\n fx: true,\n fy: true,\n g1: true,\n g2: true,\n glyphName: true,\n glyphOrientationHorizontal: true,\n glyphOrientationVertical: true,\n glyphRef: true,\n gradientTransform: true,\n gradientUnits: true,\n hanging: true,\n horizAdvX: true,\n horizOriginX: true,\n ideographic: true,\n imageRendering: true,\n in: true,\n in2: true,\n intercept: true,\n k: true,\n k1: true,\n k2: true,\n k3: true,\n k4: true,\n kernelMatrix: true,\n kernelUnitLength: true,\n kerning: true,\n keyPoints: true,\n keySplines: true,\n keyTimes: true,\n lengthAdjust: true,\n letterSpacing: true,\n lightingColor: true,\n limitingConeAngle: true,\n local: true,\n markerEnd: true,\n markerMid: true,\n markerStart: true,\n markerHeight: true,\n markerUnits: true,\n markerWidth: true,\n mask: true,\n maskContentUnits: true,\n maskUnits: true,\n mathematical: true,\n mode: true,\n numOctaves: true,\n offset: true,\n opacity: true,\n operator: true,\n order: true,\n orient: true,\n orientation: true,\n origin: true,\n overflow: true,\n overlinePosition: true,\n overlineThickness: true,\n panose1: true,\n paintOrder: true,\n pathLength: true,\n patternContentUnits: true,\n patternTransform: true,\n patternUnits: true,\n pointerEvents: true,\n points: true,\n pointsAtX: true,\n pointsAtY: true,\n pointsAtZ: true,\n preserveAlpha: true,\n preserveAspectRatio: true,\n primitiveUnits: true,\n r: true,\n radius: true,\n refX: true,\n refY: true,\n renderingIntent: true,\n repeatCount: true,\n repeatDur: true,\n requiredExtensions: true,\n requiredFeatures: true,\n restart: true,\n result: true,\n rotate: true,\n rx: true,\n ry: true,\n scale: true,\n seed: true,\n shapeRendering: true,\n slope: true,\n spacing: true,\n specularConstant: true,\n specularExponent: true,\n speed: true,\n spreadMethod: true,\n startOffset: true,\n stdDeviation: true,\n stemh: true,\n stemv: true,\n stitchTiles: true,\n stopColor: true,\n stopOpacity: true,\n strikethroughPosition: true,\n strikethroughThickness: true,\n string: true,\n stroke: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeLinecap: true,\n strokeLinejoin: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true,\n surfaceScale: true,\n systemLanguage: true,\n tableValues: true,\n targetX: true,\n targetY: true,\n textAnchor: true,\n textDecoration: true,\n textRendering: true,\n textLength: true,\n to: true,\n transform: true,\n u1: true,\n u2: true,\n underlinePosition: true,\n underlineThickness: true,\n unicode: true,\n unicodeBidi: true,\n unicodeRange: true,\n unitsPerEm: true,\n vAlphabetic: true,\n vHanging: true,\n vIdeographic: true,\n vMathematical: true,\n values: true,\n vectorEffect: true,\n version: true,\n vertAdvY: true,\n vertOriginX: true,\n vertOriginY: true,\n viewBox: true,\n viewTarget: true,\n visibility: true,\n widths: true,\n wordSpacing: true,\n writingMode: true,\n x: true,\n xHeight: true,\n x1: true,\n x2: true,\n xChannelSelector: true,\n xlinkActuate: true,\n xlinkArcrole: true,\n xlinkHref: true,\n xlinkRole: true,\n xlinkShow: true,\n xlinkTitle: true,\n xlinkType: true,\n xmlBase: true,\n xmlns: true,\n xmlnsXlink: true,\n xmlLang: true,\n xmlSpace: true,\n y: true,\n y1: true,\n y2: true,\n yChannelSelector: true,\n z: true,\n zoomAndPan: true,\n\n // For preact. We have this code here even though Emotion doesn't support\n // Preact, since @emotion/is-prop-valid is used by some libraries outside of\n // the context of Emotion.\n for: true,\n class: true,\n autofocus: true,\n};\n\nconst validProps = `^((${Object.keys(validPropsRecord).join(\n \"|\",\n)})|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$`;\n\nconst r = new RegExp(validProps);\n\nexport const isPropValid: (prop: string) => boolean = memoize(\n (prop: string) =>\n r.test(prop) ||\n (prop.charCodeAt(0) === 111 /* o */ &&\n prop.charCodeAt(1) === 110 /* n */ &&\n prop.charCodeAt(2) < 91) /* Z+1 */,\n);\n","import styled from \"@emotion/styled\";\nimport { Property } from \"csstype\";\n\nimport {\n background,\n BackgroundProps,\n border,\n borderBottom,\n BorderBottomProps,\n borderColor,\n borderLeft,\n BorderLeftProps,\n borderRadius,\n BorderRadiusProps,\n borderRight,\n BorderRightProps,\n borderStyle,\n BorderStyleProps,\n borderTop,\n BorderTopProps,\n borderWidth,\n BorderWidthProps,\n bottom,\n BottomProps,\n boxShadow,\n BoxShadowProps,\n flexbox,\n FlexboxProps,\n layout,\n LayoutProps,\n left,\n LeftProps,\n overflow,\n OverflowProps,\n position,\n PositionProps,\n ResponsiveValue,\n right,\n RightProps,\n system,\n TLengthStyledSystem,\n top,\n TopProps,\n zIndex,\n ZIndexProps,\n} from \"styled-system\";\nimport { DivProps } from \"../../../types/ElementProps\";\nimport {\n booleanOrNumberToMetricCalc,\n booleanOrNumberToNumber,\n} from \"../../../utils/BooleanOrNumberToNumber\";\nimport { isPropValid } from \"../../util/IsPropValid\";\n\ninterface StyledSystemProps\n extends BorderRadiusProps,\n BorderStyleProps,\n BorderWidthProps,\n BorderLeftProps,\n BorderRightProps,\n BorderTopProps,\n BorderBottomProps,\n FlexboxProps,\n LayoutProps,\n OverflowProps,\n PositionProps,\n ZIndexProps,\n LeftProps,\n RightProps,\n TopProps,\n BottomProps {}\n\nconst shadows = {\n box: \"var(--swui-shadow-box)\",\n popover: \"var(--swui-shadow-popover)\",\n modal: \"var(--swui-shadow-modal)\",\n bottom: \"var(--swui-shadow-bottom)\",\n};\n\ntype ShadowType = keyof typeof shadows;\n\nexport interface BoxProps extends StyledSystemProps, DivProps {\n /**\n * If true, children are placed in a row.\n */\n row?: ResponsiveValue<boolean>;\n\n /**\n * Adds spacing over and under content.\n */\n spacing?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing left and right of content.\n */\n indent?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds spacing between children.\n */\n gap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between columns.\n */\n columnGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds gap between rows.\n */\n rowGap?: ResponsiveValue<boolean | TLengthStyledSystem>;\n\n /**\n * Adds a shadow around the box.\n */\n shadow?: ResponsiveValue<Property.BoxShadow | ShadowType>;\n\n /**\n * Sets the background of the box.\n */\n background?: ResponsiveValue<Property.Background<TLengthStyledSystem>>;\n\n /**\n * Sets the border of the box.\n */\n border?: ResponsiveValue<Property.Border<TLengthStyledSystem>>;\n\n /**\n * Sets the border color of the box.\n */\n borderColor?: ResponsiveValue<Property.BorderColor>;\n\n /**\n * Sets the background of the box when hovering with mouse.\n */\n hoverBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when hovering with mouse.\n */\n hoverBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when the box is in focus.\n */\n focusBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when the box is in focus.\n */\n focusBorder?: Property.Border<TLengthStyledSystem>;\n\n /**\n * Sets the background of the box when focus is within the box.\n */\n focusWithinBackground?: Property.Background<TLengthStyledSystem>;\n\n /**\n * Sets the border of the box when focus is within the box.\n */\n focusWithinBorder?: Property.Border<TLengthStyledSystem>;\n}\n\nconst excludedProps = [\n \"spacing\",\n \"indent\",\n \"gap\",\n \"width\",\n \"height\",\n \"overflow\",\n \"display\",\n];\n\nconst isExcludedWebUiProp = (propName: string) =>\n excludedProps.includes(propName);\n\nconst box = system({\n row: {\n property: \"flexDirection\",\n transform: (row: boolean) => (row ? \"row\" : \"column\"),\n },\n indent: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-indent\",\n transform: booleanOrNumberToNumber,\n },\n spacing: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-spacing\",\n transform: booleanOrNumberToNumber,\n },\n gap: {\n // @ts-expect-error Sets a CSS property.\n property: \"--current-gap\",\n transform: booleanOrNumberToNumber,\n },\n columnGap: {\n property: \"columnGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n rowGap: {\n property: \"rowGap\",\n transform: booleanOrNumberToMetricCalc,\n },\n shadow: {\n property: \"boxShadow\",\n transform: (value: ShadowType) => shadows[value] ?? value,\n },\n});\n\ntype InnerProps = BoxProps & BoxShadowProps & BackgroundProps;\n\nexport const Box = styled(\"div\", {\n shouldForwardProp: (propName) =>\n typeof propName === \"string\"\n ? isExcludedWebUiProp(propName)\n ? false\n : isPropValid(propName)\n : false,\n})<InnerProps>`\n --current-spacing: 0;\n --current-indent: 0;\n --current-gap: 0;\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n ${box};\n ${background};\n ${border};\n ${borderRight};\n ${borderLeft};\n ${borderTop};\n ${borderBottom};\n ${borderColor};\n ${borderRadius};\n ${borderStyle};\n ${borderWidth};\n ${boxShadow};\n ${flexbox};\n ${overflow};\n ${position};\n ${layout};\n ${zIndex};\n ${left};\n ${right};\n ${top};\n ${bottom};\n\n gap: calc(var(--current-gap) * var(--swui-metrics-space));\n\n padding: calc(var(--current-spacing) * var(--swui-metrics-spacing))\n calc(var(--current-indent) * var(--swui-metrics-indent));\n\n :hover {\n ${({ hoverBackground }) =>\n hoverBackground ? `background: ${hoverBackground};` : \"\"}\n ${({ hoverBorder }) => (hoverBorder ? `border: ${hoverBorder};` : \"\")}\n }\n\n :focus {\n ${({ focusBackground }) =>\n focusBackground ? `background: ${focusBackground};` : \"\"}\n ${({ focusBorder }) => (focusBorder ? `border: ${focusBorder};` : \"\")}\n }\n\n :focus-within {\n ${({ focusWithinBackground }) =>\n focusWithinBackground ? `background: ${focusWithinBackground};` : \"\"}\n ${({ focusWithinBorder }) =>\n focusWithinBorder ? `border: ${focusWithinBorder};` : \"\"}\n }\n`;\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Column = forwardRef<HTMLDivElement, BoxProps>(\n function Column(props, ref) {\n return <Box ref={ref} {...props} />;\n },\n);\n","import { RefObject, useCallback, useLayoutEffect, useState } from \"react\";\n\nexport interface ElementDimensions {\n width: number;\n height: number;\n top: number;\n left: number;\n x: number;\n y: number;\n right: number;\n bottom: number;\n}\n\nexport const getDimensionObject = (node: HTMLElement): ElementDimensions => {\n const { x, y, width, height, bottom, top, left, right } =\n node.getBoundingClientRect();\n\n return {\n width,\n height,\n top,\n left,\n x,\n y,\n right,\n bottom,\n };\n};\n\nconst isEqualDimensions = (\n a: ElementDimensions,\n b: ElementDimensions,\n): boolean =>\n a.x === b.x &&\n a.y === b.y &&\n a.width === b.width &&\n a.height === b.height &&\n a.bottom === b.bottom &&\n a.top === b.top &&\n a.left === b.left &&\n a.right === b.right;\n\nexport const useElementDimensions = (\n ref: RefObject<HTMLElement | null>,\n onResizeElement?: (dimensions: ElementDimensions) => void,\n) => {\n const [dimensions, setDimensions] = useState<ElementDimensions | undefined>();\n\n const updateDimensions = useCallback(() => {\n window.requestAnimationFrame(() => {\n if (ref.current) {\n const newDimensions = getDimensionObject(ref.current);\n if (!dimensions || !isEqualDimensions(dimensions, newDimensions)) {\n if (onResizeElement) {\n onResizeElement(newDimensions);\n }\n }\n setDimensions(newDimensions);\n }\n });\n }, [ref, dimensions, setDimensions, onResizeElement]);\n\n useLayoutEffect(() => {\n updateDimensions();\n }, [updateDimensions]);\n\n return {\n dimensions,\n };\n};\n","import * as React from \"react\";\nimport { forwardRef, RefObject, useRef } from \"react\";\nimport { Box, BoxProps } from \"./Box\";\nimport {\n ElementDimensions,\n useElementDimensions,\n} from \"../../../hooks/UseElementDimensions\";\n\nexport interface ResizeAwareBoxProps extends Omit<BoxProps, \"onResize\"> {\n onResize?: (dimensions: ElementDimensions) => void;\n}\n\nexport const ResizeAwareBox = forwardRef<HTMLDivElement, ResizeAwareBoxProps>(\n function ResizeAwareBox({ onResize, ...boxProps }, ref) {\n const localRef = useRef<HTMLDivElement>(null);\n const currentRef = (ref as RefObject<HTMLDivElement>) ?? localRef;\n useElementDimensions(currentRef, onResize);\n\n return <Box {...boxProps} ref={ref} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\n\nexport const Row = forwardRef<HTMLDivElement, BoxProps>(\n function Row(props, ref) {\n return <Box row ref={ref} {...props} />;\n },\n);\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface IndentProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Indent = forwardRef<HTMLDivElement, IndentProps>(function Indent(\n { num = 1, ...props },\n ref,\n) {\n return <Box indent={num} ref={ref} {...props} />;\n});\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { Box, BoxProps } from \"../box/Box\";\nimport { ResponsiveValue, TLengthStyledSystem } from \"styled-system\";\n\nexport interface SpacingProps extends BoxProps {\n num?: ResponsiveValue<boolean | TLengthStyledSystem>;\n}\n\nexport const Spacing = forwardRef<HTMLDivElement, SpacingProps>(\n function Spacing({ num = 1, ...props }, ref) {\n return <Box spacing={num} ref={ref} {...props} />;\n },\n);\n","import styled from \"@emotion/styled\";\nimport * as React from \"react\";\n\nexport interface SpaceProps {\n half?: boolean;\n horizontal?: boolean;\n num?: number;\n vertical?: boolean;\n}\n\nconst InnerSpace = styled.div`\n --current-size: 1;\n flex: none;\n width: calc(var(--current-size) * var(--swui-metrics-space));\n height: calc(var(--current-size) * var(--swui-metrics-space));\n`;\n\nexport const Space: React.FC<SpaceProps> = ({\n half = false,\n horizontal = false,\n num = 1,\n vertical = false,\n}) => {\n const size = num * (half ? 0.5 : 1);\n\n return (\n <InnerSpace\n style={{\n [\"--current-size\" as string]: size,\n height: horizontal ? 1 : undefined,\n width: vertical ? 1 : undefined,\n }}\n />\n );\n};\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\n\ninterface Props {\n nest?: boolean;\n render: (children: ReactNode) => ReactNode;\n children?: ReactNode;\n}\n\nexport const Nest: React.FC<Props> = ({ children, nest, render }) => {\n if (nest) {\n return <>{render(children)}</>;\n }\n return <>{children}</>;\n};\n","import { pickBy } from \"lodash-es\";\n\nexport const getDataProps = <T extends Record<string, unknown>>(\n props: Record<string, unknown> | object,\n): T => pickBy(props, isDataPropMapper) as T;\n\nconst isDataPropMapper = (_: unknown, key: string): boolean => isDataProp(key);\n\nconst isDataProp = <TProp extends string>(propName: TProp): boolean =>\n propName.startsWith(\"data-\") || propName.startsWith(\"aria-\");\n","import * as React from \"react\";\nimport { ReactNode } from \"react\";\nimport styles from \"./ScreenReaderOnlyText.module.css\";\nimport { getDataProps } from \"../../utils/PropsForwarder\";\n\nexport interface ScreenReaderOnlyTextProps {\n children?: ReactNode;\n}\n\nexport const ScreenReaderOnlyText: React.FC<ScreenReaderOnlyTextProps> = ({\n children,\n ...props\n}) => {\n return (\n <span className={styles.visuallyHidden} {...getDataProps(props)}>\n {children}\n </span>\n );\n};\n","import * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport cx from \"classnames\";\nimport styles from \"./Text.module.css\";\nimport { SpanProps } from \"../../types/ElementProps\";\nimport { Property } from \"csstype\";\n\nexport interface TextProps extends SpanProps {\n variant?: TextVariant;\n size?: TextSize;\n userSelect?: Property.UserSelect;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n textAlign?: Property.TextAlign;\n overflow?: Property.Overflow;\n textOverflow?: Property.TextOverflow;\n color?: string;\n}\n\nexport type TextVariant = \"standard\" | \"caption\" | \"overline\" | \"bold\";\nexport type TextSize = \"large\" | \"medium\" | \"small\" | \"smaller\";\n\nexport const Text = forwardRef<HTMLSpanElement, TextProps>(\n (\n {\n children,\n variant = \"standard\",\n size = \"medium\",\n className,\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n overflow,\n textOverflow,\n style,\n ...spanProps\n },\n ref,\n ) => {\n return (\n <span\n className={cx(styles.text, styles[variant], styles[size], className)}\n ref={ref}\n style={{\n color,\n userSelect,\n whiteSpace,\n wordBreak,\n textAlign,\n overflow,\n textOverflow,\n ...style,\n }}\n {...spanProps}\n >\n {children}\n </span>\n );\n },\n);\n\nexport const Txt = Text;\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"small\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const SmallerText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"smaller\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const StandardText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"medium\"} {...props} />;\n};\n","import * as React from \"react\";\nimport { Text, TextProps } from \"../text/Text\";\n\n/**\n * @deprecated Please use `Text` instead.\n */\nexport const LargeText: React.FC<Omit<TextProps, \"size\">> = (props) => {\n return <Text size={\"large\"} {...props} />;\n};\n","import cx from \"classnames\";\nimport { Property } from \"csstype\";\nimport * as React from \"react\";\nimport { forwardRef } from \"react\";\nimport { H1Props } from \"../../types/ElementProps\";\nimport styles from \"./Heading.module.css\";\n\nexport interface HeadingProps extends H1Props {\n variant?: HeadingVariant;\n whiteSpace?: Property.WhiteSpace;\n wordBreak?: Property.WordBreak;\n as?: HeadingVariant;\n}\n\nexport type HeadingVariant = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\nexport const Heading = forwardRef<HTMLHeadingElement, HeadingProps>(\n (\n {\n variant = \"h3\",\n className,\n color,\n whiteSpace,\n wordBreak,\n style,\n children,\n as,\n ...hProps\n },\n ref,\n ) => {\n const Element = as ?? variant;\n return (\n <Element\n className={cx(styles.heading, styles[variant], className)}\n style={{ color, whiteSpace, wordBreak, ...style }}\n ref={ref}\n {...hProps}\n >\n {children}\n </Element>\n );\n },\n);\n","import * as React from \"react\";\nimport { Heading, HeadingProps } from \"../heading/Heading\";\n\n/**\n * @deprecated Please use `Heading` instead.\n */\nexport const HeaderText: React.FC<Omit<HeadingProps, \"variant\">> = (props) => {\n return <Heading variant={\"h2\"} {...props} />;\n};\n","import { useCallback } from \"react\";\n\ntype ArrayItemEqualsComparator<T> = (a: T, b: T) => boolean;\n\nconst defaultComparator = <T>(a: T, b: T) => a === b;\n\nexport const useArraySet = <T>(\n list: Array<T>,\n setList: (list: Array<T>) => void,\n comparator: ArrayItemEqualsComparator<T> = defaultComparator,\n) => {\n const add = useCallback(\n (item: T) => {\n if (!list.some((l) => comparator(l, item))) {\n setList([...list, item]);\n }\n },\n [list, setList, comparator],\n );\n\n const addMultiple = useCallback(\n (items: Array<T>) => {\n setList(\n items.reduce((list, item) => {\n if (!list.some((l) => comparator(l, item))) {\n return [...list, item];\n }\n return list;\n }, list),\n );\n },\n [list, setList, comparator],\n );\n\n const remove = useCallback(\n (item: T) => {\n const index = list.findIndex((l) => comparator(l, item));\n if (index >= 0) {\n setList(list.filter((_, i) => i !== index));\n }\n },\n [list, setList, comparator],\n );\n\n const removeMultiple = useCallback(\n (items: Array<T>) => {\n setList(list.filter((item) => !items.some((l) => comparator(l, item))));\n },\n [list, setList, comparator],\n );\n\n const toggle = useCallback(\n (item: T) => {\n const found = list.some((l) => comparator(l, item));\n if (found) {\n remove(item);\n } else {\n add(item);\n }\n },\n [list, add, remove, comparator],\n );\n\n return {\n add,\n addMultiple,\n remove,\n removeMultiple,\n toggle,\n };\n};\n","import { useCallback, useState } from \"react\";\n\ntype Value = boolean;\ntype SetTrue = () => void;\ntype SetFalse = () => void;\ntype ToggleValue = () => void;\ntype BooleanHook = [Value, SetTrue, SetFalse, ToggleValue];\n\nexport const useBoolean = (initialValue: Value): BooleanHook => {\n const [value, setValue] = useState(initialValue);\n\n const setTrue = useCallback(() => {\n setValue(true);\n }, [setValue]);\n\n const setFalse = useCallback(() => {\n setValue(false);\n }, [setValue]);\n\n const toggle = useCallback(() => {\n setValue((v) => !v);\n }, [setValue]);\n\n return [value, setTrue, setFalse, toggle];\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDebounce = <T>(value: T, delay: number): T => {\n // State and setters for debounced value\n const [debouncedValue, setDebouncedValue] = useState<T>(value);\n\n useEffect(() => {\n // Update debounced value after delay\n const handler = setTimeout(() => {\n setDebouncedValue(value);\n }, delay);\n\n // Cancel the timeout if value changes (also on delay change or unmount)\n // This is how we prevent debounced value from updating if value is changed ...\n // .. within the delay period. Timeout gets cleared and restarted.\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]); // Only re-call effect if value or delay changes\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nexport const useDelayedFalse = (value: boolean, delay: number) => {\n const [debouncedValue, setDebouncedValue] = useState<boolean>(value);\n\n useEffect(() => {\n if (value) {\n setDebouncedValue(true);\n }\n\n const handler = setTimeout(() => {\n if (!value) {\n setDebouncedValue(value);\n }\n }, delay);\n\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]);\n\n return debouncedValue;\n};\n","import { useEffect, useState } from \"react\";\n\nlet id = 0;\nconst genId = (componentName?: string) =>\n `webui-${componentName ? componentName + \"-\" : \"\"}${++id}`;\n\n/** @deprecated use useId-hook from React 18 */\nexport const useDomId = (componentName?: string): string => {\n const [id, setId] = useState<string | null>(() => genId(componentName));\n useEffect(() => setId(genId(componentName)), [componentName]);\n return id!;\n};\n","import { RefObject, useEffect, useRef } from \"react\";\n\ntype EventHandler<TEventName extends keyof HTMLElementEventMap> = (\n event: HTMLElementEventMap[TEventName],\n) => void;\n\nexport const useEventListener = <TEventName extends keyof HTMLElementEventMap>(\n ref: RefObject<HTMLElement | null>,\n eventName: TEventName,\n handler: EventHandler<TEventName>,\n) => {\n // Create a ref that stores handler\n const savedHandler = useRef<EventHandler<TEventName>>(null);\n\n // Update ref.current value if handler changes.\n // This allows our effect below to always get latest handler ...\n // ... without us needing to pass it in effect deps array ...\n // ... and potentially cause effect to re-run every render.\n useEffect(() => {\n savedHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n // Make sure element supports addEventListener\n const isSupported = ref.current && ref.current.addEventListener;\n if (!isSupported) return;\n\n // Create event listener that calls handler function stored in ref\n const eventListener: EventHandler<TEventName> = (event) => {\n if (savedHandler.current) {\n return savedHandler.current(event);\n }\n };\n\n // Add event listener\n if (!ref.current) {\n return;\n }\n\n const element = ref.current;\n element.addEventListener(eventName, eventListener);\n\n // Remove event listener on cleanup\n return () => {\n if (element) {\n element.removeEventListener(eventName, eventListener);\n }\n };\n }, [eventName, ref]); // Re-run if eventName or element changes\n};\n","import { RefObject, useCallback, useEffect } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useElementFocus = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [isInFocus, setIsInFocus, setIsNotInFocus] = useBoolean(false);\n\n useEffect(() => {\n if (document.activeElement === ref.current) {\n setIsInFocus();\n } else {\n setIsNotInFocus();\n }\n }, [ref, setIsNotInFocus, setIsInFocus]);\n\n useEventListener(ref, \"focus\", setIsInFocus);\n useEventListener(ref, \"blur\", setIsNotInFocus);\n\n const focus = useCallback(() => {\n if (ref.current) {\n ref.current.focus();\n }\n }, [ref]);\n\n const blur = useCallback(() => {\n if (ref.current) {\n ref.current.blur();\n }\n }, [ref]);\n\n return { isInFocus, focus, blur };\n};\n","import { useCallback, useLayoutEffect, useRef } from \"react\";\n\ntype Fn<ARGS extends unknown[], R> = (...args: ARGS) => R;\n\nexport const useEventCallback = <A extends unknown[], R>(\n fn: Fn<A, R>,\n): Fn<A, R> => {\n const ref = useRef<Fn<A, R>>(fn);\n useLayoutEffect(() => {\n ref.current = fn;\n });\n return useCallback((...args: A): R => {\n const { current } = ref;\n return current(...args);\n }, []);\n};\n","import React, { MutableRefObject } from \"react\";\n\nexport const useLatest = <T>(value: T): MutableRefObject<T> => {\n const ref = React.useRef(value);\n ref.current = value;\n return ref;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsOver = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsOver, setMouseIsOver, setMouseIsNotOver] = useBoolean(false);\n\n useEventListener(ref, \"mouseover\", setMouseIsOver);\n useEventListener(ref, \"mouseout\", setMouseIsNotOver);\n\n return mouseIsOver;\n};\n","import { RefObject } from \"react\";\nimport { useBoolean } from \"./UseBoolean\";\nimport { useEventListener } from \"./UseEventListener\";\n\nexport const useMouseIsEntered = <TElement extends HTMLElement>(\n ref: RefObject<TElement>,\n) => {\n const [mouseIsEntered, setMouseIsEntered, setMouseIsNotEntered] =\n useBoolean(false);\n\n useEventListener(ref, \"mouseenter\", setMouseIsEntered);\n useEventListener(ref, \"mouseleave\", setMouseIsNotEntered);\n\n return mouseIsEntered;\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useMultiOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n refs: Array<React.RefObject<any>>,\n handler: (event: TouchEvent | MouseEvent) => void,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n\n const allNotContains = refs\n .filter((ref) => ref.current)\n .every((ref) => {\n return ref.current && !ref.current.contains(event.target);\n });\n\n if (!allNotContains) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener);\n document.addEventListener(\"touchstart\", listener);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener);\n document.removeEventListener(\"touchstart\", listener);\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [...refs]);\n};\n","import * as React from \"react\";\nimport { useEffect, useRef } from \"react\";\n\nexport const useOnClickOutside = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ref: React.RefObject<any>,\n handler: (event: TouchEvent | MouseEvent) => void,\n options?: AddEventListenerOptions,\n) => {\n const eventHandler = useRef<(event: TouchEvent | MouseEvent) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = handler;\n }, [handler]);\n\n useEffect(() => {\n const listener = (event: TouchEvent | MouseEvent) => {\n // Do nothing if clicking ref's element or descendent elements\n if (!ref.current || ref.current.contains(event.target)) {\n return;\n }\n\n eventHandler.current(event);\n };\n\n document.addEventListener(\"mousedown\", listener, options);\n document.addEventListener(\"touchstart\", listener, options);\n\n return () => {\n document.removeEventListener(\"mousedown\", listener, options);\n document.removeEventListener(\"touchstart\", listener, options);\n };\n }, [ref, options]);\n};\n","import { debounce } from \"lodash-es\";\nimport { useEffect, useRef } from \"react\";\n\nconst events = [\"mousemove\", \"mousedown\", \"keydown\", \"touchstart\", \"scroll\"];\n\nexport const useOnNoMouseMovement = (callback: () => void, delay: number) => {\n const eventHandler = useRef<(event: Event) => void>(() => {\n return;\n });\n\n useEffect(() => {\n eventHandler.current = callback;\n }, [callback]);\n\n useEffect(() => {\n const onIdleChange = debounce(eventHandler.current, delay);\n events.forEach((event) => window.addEventListener(event, onIdleChange));\n\n return () => {\n events.forEach((event) =>\n window.removeEventListener(event, onIdleChange),\n );\n };\n }, [delay]);\n};\n","import { RefObject, useEffect, useMemo, useState } from \"react\";\n\nexport const useOnScreen = (\n ref: RefObject<Element | null>,\n options?: IntersectionObserverInit,\n) => {\n const [isVisible, setIsVisible] = useState(false);\n\n const { rootMargin, root, threshold } = options || {};\n\n const observer = useMemo(() => {\n return new IntersectionObserver(\n ([entry]) => setIsVisible(entry.isIntersecting),\n {\n rootMargin,\n root,\n threshold,\n },\n );\n }, [setIsVisible, rootMargin, root, threshold]);\n\n useEffect(() => {\n if (ref.current) {\n observer.observe(ref.current);\n }\n return () => {\n observer.disconnect();\n };\n }, [observer, ref]);\n\n return isVisible;\n};\n","import {\n MutableRefObject,\n RefCallback,\n RefObject,\n useEffect,\n useRef,\n} from \"react\";\n\nexport const useForwardedRef = <T>(\n ref: RefCallback<T> | MutableRefObject<T> | null,\n): RefObject<NonNullable<T>> => {\n const innerRef = useRef<T>(null) as MutableRefObject<NonNullable<T>>;\n\n useEffect(() => {\n if (!ref) return;\n if (typeof ref === \"function\") {\n ref(innerRef.current);\n } else {\n ref.current = innerRef.current;\n }\n });\n\n return innerRef;\n};\n","import { useCallback, useEffect, useRef, useState } from \"react\";\n\nexport const useTimeoutState = <S>(\n initialValue: S,\n defaultTimeout: number,\n clearTimeoutOnSetValue = true,\n): [S, (v: S) => void] => {\n const [value, setValue] = useState<S>(initialValue);\n const timeoutRef = useRef<NodeJS.Timeout>(null);\n\n const wrappedSetter = useCallback(\n (newValue: S, timeout = defaultTimeout) => {\n setValue(newValue);\n if (clearTimeoutOnSetValue) {\n clearTimeout(timeoutRef.current!);\n }\n timeoutRef.current = setTimeout(() => setValue(initialValue), timeout);\n },\n [defaultTimeout, clearTimeoutOnSetValue, initialValue],\n );\n\n useEffect(() => {\n return () => {\n clearTimeout(timeoutRef.current!);\n };\n }, []);\n\n return [value, wrappedSetter];\n};\n","import { useMemo } from \"react\";\n\nexport const useToday = () => {\n return useMemo(() => new Date(), []);\n};\n","export const byStringField =\n <T>(fieldResolver: (item: T) => string) =>\n (a: T, b: T): number =>\n fieldResolver(a).localeCompare(fieldResolver(b));\n\nexport const byNumberField =\n <T>(fieldResolver: (item: T) => number) =>\n (a: T, b: T): number =>\n fieldResolver(a) - fieldResolver(b);\n","export const exhaustSwitchCaseElseThrow = (arg: never) => {\n throw new Error(`Switch unhandled case: ${arg}`);\n};\n\nexport const exhaustSwitchCase = <T>(_arg: never, fallback: T) => {\n return fallback;\n};\n","export const truthyKeysAsList = (r: Record<string, boolean>): Array<string> =>\n Object.keys(r).filter((key) => r[key]);\n","export const parseFloatElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseFloat(s);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n\nexport const parseIntElseUndefined = (s: string): number | undefined => {\n try {\n const f = parseInt(s, 10);\n if (isNaN(f)) {\n return undefined;\n }\n if (f == null) {\n return undefined;\n }\n return f;\n } catch {\n /* empty */\n }\n return undefined;\n};\n","export function invariant<T>(\n val: T | null | undefined,\n message: string,\n): asserts val is T {\n if (val == null) {\n throw new Error(\"Invariant error: \" + message);\n }\n}\n"],"names":["SeparatorLine","forwardRef","color","cssColor","size","width","vertical","ref","jsx","styles","ClickableElement","styled","background","pointer","props","hoverBackground","disableOpacityOnClick","disableFocusHighlight","focusBackground","height","borderRadius","Clickable","onClick","onDblClick","tooltip","disablePointer","opacityOnHover","disabled","children","type","restProps","hasClickHandler","booleanOrNumberToNumber","num","numberToMetricCalc","booleanOrNumberToMetricCalc","validPropsRecord","validProps","r","isPropValid","memoize","prop","shadows","excludedProps","isExcludedWebUiProp","propName","box","system","row","value","Box","border","borderRight","borderLeft","borderTop","borderBottom","borderColor","borderStyle","borderWidth","boxShadow","flexbox","overflow","position","layout","zIndex","left","right","top","bottom","hoverBorder","focusBorder","focusWithinBackground","focusWithinBorder","Column","getDimensionObject","node","x","y","isEqualDimensions","a","b","useElementDimensions","onResizeElement","dimensions","setDimensions","useState","updateDimensions","useCallback","newDimensions","useLayoutEffect","ResizeAwareBox","onResize","boxProps","localRef","useRef","Row","Indent","Spacing","InnerSpace","Space","half","horizontal","Nest","nest","render","Fragment","getDataProps","pickBy","isDataPropMapper","_","key","isDataProp","ScreenReaderOnlyText","Text","variant","className","userSelect","whiteSpace","wordBreak","textAlign","textOverflow","style","spanProps","cx","Txt","SmallText","SmallerText","StandardText","LargeText","Heading","as","hProps","Element","HeaderText","defaultComparator","useArraySet","list","setList","comparator","add","item","l","addMultiple","items","remove","index","i","removeMultiple","toggle","useBoolean","initialValue","setValue","setTrue","setFalse","v","useDebounce","delay","debouncedValue","setDebouncedValue","useEffect","handler","useDelayedFalse","id","genId","componentName","useDomId","setId","useEventListener","eventName","savedHandler","eventListener","event","element","useElementFocus","isInFocus","setIsInFocus","setIsNotInFocus","focus","blur","useEventCallback","fn","args","current","useLatest","React","useMouseIsOver","mouseIsOver","setMouseIsOver","setMouseIsNotOver","useMouseIsEntered","mouseIsEntered","setMouseIsEntered","setMouseIsNotEntered","useMultiOnClickOutside","refs","eventHandler","listener","useOnClickOutside","options","events","useOnNoMouseMovement","callback","onIdleChange","debounce","useOnScreen","isVisible","setIsVisible","rootMargin","root","threshold","observer","useMemo","entry","useForwardedRef","innerRef","useTimeoutState","defaultTimeout","clearTimeoutOnSetValue","timeoutRef","wrappedSetter","newValue","timeout","useToday","byStringField","fieldResolver","byNumberField","exhaustSwitchCaseElseThrow","arg","exhaustSwitchCase","_arg","fallback","truthyKeys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BC,EAAwBnE,CAAY,CACvD,EAEAS,OAAAA,EAAAA,UAAU,IACD,IAAM,CACX,aAAa2D,EAAW,OAAQ,CAClC,EACC,EAAE,EAEE,CAACzK,EAAO0K,CAAa,CAC9B,EC1BaG,GAAW,IACfX,UAAQ,IAAM,IAAI,KAAQ,CAAA,CAAE,ECHxBY,GACPC,GACJ,CAACjJ,EAAMC,IACLgJ,EAAcjJ,CAAC,EAAE,cAAciJ,EAAchJ,CAAC,CAAC,EAEtCiJ,GACPD,GACJ,CAACjJ,EAAMC,IACLgJ,EAAcjJ,CAAC,EAAIiJ,EAAchJ,CAAC,ECRzBkJ,GAA8BC,GAAe,CACxD,MAAM,IAAI,MAAM,0BAA0BA,CAAG,EAAE,CACjD,EAEaC,GAAoB,CAAIC,EAAaC,IACzCA,ECLIC,GAAoBjM,GAC/B,OAAO,KAAKA,CAAC,EAAE,OAAQwE,GAAQxE,EAAEwE,CAAG,CAAC,ECD1B0H,GAA2BC,GAAkC,CACpE,GAAA,CACI,MAAAC,EAAI,WAAWD,CAAC,EAItB,OAHI,MAAMC,CAAC,GAGPA,GAAK,KACA,OAEFA,CAAA,MACD,CAAA,CAIV,EAEaC,GAAyBF,GAAkC,CAClE,GAAA,CACI,MAAAC,EAAI,SAASD,EAAG,EAAE,EAIxB,OAHI,MAAMC,CAAC,GAGPA,GAAK,KACA,OAEFA,CAAA,MACD,CAAA,CAIV,EC9BgB,SAAAE,GACdC,EACAC,EACkB,CAClB,GAAID,GAAO,KACH,MAAA,IAAI,MAAM,oBAAsBC,CAAO,CAEjD"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stenajs-webui/core",
3
- "version": "21.32.1",
3
+ "version": "21.33.0",
4
4
  "type": "module",
5
5
  "description": "",
6
6
  "author": "mattias800",
@@ -61,9 +61,9 @@
61
61
  "files": [
62
62
  "dist"
63
63
  ],
64
- "gitHead": "38d7cb59525335f4ba496499f97cac377a54b258",
64
+ "gitHead": "90f385f98df48f3faf3fb381f764a14936c12dee",
65
65
  "dependencies": {
66
- "@stenajs-webui/theme": "21.32.1",
66
+ "@stenajs-webui/theme": "21.33.0",
67
67
  "classnames": "^2.5.1",
68
68
  "lodash-es": "^4.17.21"
69
69
  }