@x-plat/design-system 0.5.17 → 0.5.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/dist/components/Chart/index.cjs +147 -27
  2. package/dist/components/Chart/index.css +74 -7
  3. package/dist/components/Chart/index.js +147 -27
  4. package/dist/components/Drawer/index.cjs +2 -4
  5. package/dist/components/Drawer/index.css +12 -0
  6. package/dist/components/Drawer/index.d.cts +2 -1
  7. package/dist/components/Drawer/index.d.ts +2 -1
  8. package/dist/components/Drawer/index.js +2 -4
  9. package/dist/components/Dropdown/index.cjs +2 -0
  10. package/dist/components/Dropdown/index.js +2 -0
  11. package/dist/components/PopOver/index.cjs +2 -0
  12. package/dist/components/PopOver/index.css +2 -1
  13. package/dist/components/PopOver/index.js +2 -0
  14. package/dist/components/Select/index.cjs +2 -0
  15. package/dist/components/Select/index.js +2 -0
  16. package/dist/components/Skeleton/index.cjs +3 -2
  17. package/dist/components/Skeleton/index.d.cts +3 -2
  18. package/dist/components/Skeleton/index.d.ts +3 -2
  19. package/dist/components/Skeleton/index.js +3 -2
  20. package/dist/components/index.cjs +154 -33
  21. package/dist/components/index.css +88 -8
  22. package/dist/components/index.js +154 -33
  23. package/dist/index.cjs +158 -49
  24. package/dist/index.css +88 -8
  25. package/dist/index.js +158 -49
  26. package/dist/layout/Grid/FullGrid/index.cjs +2 -8
  27. package/dist/layout/Grid/FullGrid/index.d.cts +2 -1
  28. package/dist/layout/Grid/FullGrid/index.d.ts +2 -1
  29. package/dist/layout/Grid/FullGrid/index.js +2 -8
  30. package/dist/layout/Grid/FullScreen/index.cjs +2 -8
  31. package/dist/layout/Grid/FullScreen/index.d.cts +2 -1
  32. package/dist/layout/Grid/FullScreen/index.d.ts +2 -1
  33. package/dist/layout/Grid/FullScreen/index.js +2 -8
  34. package/dist/layout/Grid/index.cjs +4 -16
  35. package/dist/layout/Grid/index.js +4 -16
  36. package/dist/layout/index.cjs +4 -16
  37. package/dist/layout/index.js +4 -16
  38. package/package.json +1 -1
package/dist/index.cjs CHANGED
@@ -6608,6 +6608,37 @@ var useChartSize = (ref) => {
6608
6608
  }, [ref]);
6609
6609
  return size;
6610
6610
  };
6611
+ var prefersReducedMotion = () => typeof window !== "undefined" && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
6612
+ var useChartAnimation = (containerRef, dataKey) => {
6613
+ const [animate, setAnimate] = import_react5.default.useState(false);
6614
+ const prevDataKey = import_react5.default.useRef(dataKey);
6615
+ const hasAnimated = import_react5.default.useRef(false);
6616
+ import_react5.default.useEffect(() => {
6617
+ if (prefersReducedMotion()) return;
6618
+ const el = containerRef.current;
6619
+ if (!el) return;
6620
+ const observer = new IntersectionObserver(
6621
+ ([entry]) => {
6622
+ if (entry.isIntersecting && !hasAnimated.current) {
6623
+ hasAnimated.current = true;
6624
+ setAnimate(true);
6625
+ }
6626
+ },
6627
+ { threshold: 0.1 }
6628
+ );
6629
+ observer.observe(el);
6630
+ return () => observer.disconnect();
6631
+ }, [containerRef]);
6632
+ import_react5.default.useEffect(() => {
6633
+ if (dataKey !== prevDataKey.current) {
6634
+ prevDataKey.current = dataKey;
6635
+ if (prefersReducedMotion()) return;
6636
+ setAnimate(false);
6637
+ requestAnimationFrame(() => setAnimate(true));
6638
+ }
6639
+ }, [dataKey]);
6640
+ return animate || prefersReducedMotion();
6641
+ };
6611
6642
  var useChartTooltip = (enabled) => {
6612
6643
  const [tooltip, setTooltip] = import_react5.default.useState({
6613
6644
  visible: false,
@@ -6673,7 +6704,7 @@ var AxisLabels = import_react5.default.memo(({ labels, count, chartW, height })
6673
6704
  }) });
6674
6705
  });
6675
6706
  AxisLabels.displayName = "AxisLabels";
6676
- var LineChart = import_react5.default.memo(({ data, labels, width, height, onHover, onMove, onLeave }) => {
6707
+ var LineChart = import_react5.default.memo(({ data, labels, width, height, animate, onHover, onMove, onLeave }) => {
6677
6708
  const entries = import_react5.default.useMemo(() => Object.entries(data), [data]);
6678
6709
  const maxVal = import_react5.default.useMemo(() => {
6679
6710
  const allValues = entries.flatMap(([, v]) => v);
@@ -6693,18 +6724,52 @@ var LineChart = import_react5.default.memo(({ data, labels, width, height, onHov
6693
6724
  [entries, count, chartW, chartH, maxVal]
6694
6725
  );
6695
6726
  const showPoints = count <= 100;
6727
+ const lineRefs = import_react5.default.useRef([]);
6728
+ import_react5.default.useEffect(() => {
6729
+ if (!animate) return;
6730
+ lineRefs.current.forEach((el) => {
6731
+ if (!el) return;
6732
+ const len = el.getTotalLength();
6733
+ el.style.strokeDasharray = `${len}`;
6734
+ el.style.strokeDashoffset = `${len}`;
6735
+ requestAnimationFrame(() => {
6736
+ el.style.transition = "stroke-dashoffset 1200ms ease-out 200ms";
6737
+ el.style.strokeDashoffset = "0";
6738
+ });
6739
+ });
6740
+ }, [animate, seriesPoints]);
6696
6741
  return /* @__PURE__ */ (0, import_jsx_runtime305.jsxs)("svg", { viewBox: `0 0 ${width} ${height}`, className: "chart-svg", children: [
6697
6742
  /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(GridLines, { width, height, chartH, maxVal }),
6698
6743
  /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(AxisLabels, { labels, count, chartW, height }),
6699
6744
  entries.map(([key], di) => {
6700
6745
  const palette = getPalette(LINE_BAR_PALETTES, di, key);
6701
6746
  const color = palette[2];
6747
+ const areaColor = palette[0];
6702
6748
  const points = seriesPoints[di];
6749
+ const gradientId = `line-gradient-${di}`;
6750
+ const polyPoints = points.map((p) => `${p.x},${p.y}`).join(" ");
6751
+ const areaD = `M ${points[0].x},${points[0].y} ${points.map((p) => `L ${p.x},${p.y}`).join(" ")} L ${points[points.length - 1].x},${PADDING.top + chartH} L ${points[0].x},${PADDING.top + chartH} Z`;
6703
6752
  return /* @__PURE__ */ (0, import_jsx_runtime305.jsxs)("g", { children: [
6753
+ /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime305.jsxs)("linearGradient", { id: gradientId, x1: "0", y1: "0", x2: "0", y2: "1", children: [
6754
+ /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("stop", { offset: "0%", stopColor: areaColor, stopOpacity: "0.2" }),
6755
+ /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("stop", { offset: "100%", stopColor: areaColor, stopOpacity: "0" })
6756
+ ] }) }),
6757
+ /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6758
+ "path",
6759
+ {
6760
+ d: areaD,
6761
+ fill: `url(#${gradientId})`,
6762
+ className: "chart-area",
6763
+ style: animate ? { animationDelay: "600ms" } : { opacity: 1 }
6764
+ }
6765
+ ),
6704
6766
  /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6705
6767
  "polyline",
6706
6768
  {
6707
- points: points.map((p) => `${p.x},${p.y}`).join(" "),
6769
+ ref: (el) => {
6770
+ lineRefs.current[di] = el;
6771
+ },
6772
+ points: polyPoints,
6708
6773
  fill: "none",
6709
6774
  stroke: color,
6710
6775
  strokeWidth: "2"
@@ -6729,7 +6794,7 @@ var LineChart = import_react5.default.memo(({ data, labels, width, height, onHov
6729
6794
  ] });
6730
6795
  });
6731
6796
  LineChart.displayName = "LineChart";
6732
- var CurveChart = import_react5.default.memo(({ data, labels, width, height, onHover, onMove, onLeave }) => {
6797
+ var CurveChart = import_react5.default.memo(({ data, labels, width, height, animate, onHover, onMove, onLeave }) => {
6733
6798
  const entries = import_react5.default.useMemo(() => Object.entries(data), [data]);
6734
6799
  const maxVal = import_react5.default.useMemo(() => {
6735
6800
  const allValues = entries.flatMap(([, v]) => v);
@@ -6749,6 +6814,20 @@ var CurveChart = import_react5.default.memo(({ data, labels, width, height, onHo
6749
6814
  [entries, count, chartW, chartH, maxVal]
6750
6815
  );
6751
6816
  const showPoints = count <= 100;
6817
+ const lineRefs = import_react5.default.useRef([]);
6818
+ import_react5.default.useEffect(() => {
6819
+ if (!animate) return;
6820
+ lineRefs.current.forEach((el) => {
6821
+ if (!el) return;
6822
+ const len = el.getTotalLength();
6823
+ el.style.strokeDasharray = `${len}`;
6824
+ el.style.strokeDashoffset = `${len}`;
6825
+ requestAnimationFrame(() => {
6826
+ el.style.transition = "stroke-dashoffset 1200ms ease-out 200ms";
6827
+ el.style.strokeDashoffset = "0";
6828
+ });
6829
+ });
6830
+ }, [animate, seriesPoints]);
6752
6831
  return /* @__PURE__ */ (0, import_jsx_runtime305.jsxs)("svg", { viewBox: `0 0 ${width} ${height}`, className: "chart-svg", children: [
6753
6832
  /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(GridLines, { width, height, chartH, maxVal }),
6754
6833
  /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(AxisLabels, { labels, count, chartW, height }),
@@ -6765,8 +6844,27 @@ var CurveChart = import_react5.default.memo(({ data, labels, width, height, onHo
6765
6844
  /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("stop", { offset: "0%", stopColor: areaColor, stopOpacity: "0.4" }),
6766
6845
  /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("stop", { offset: "100%", stopColor: areaColor, stopOpacity: "0.02" })
6767
6846
  ] }) }),
6768
- /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("path", { d: areaPath, fill: `url(#${gradientId})` }),
6769
- /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("path", { d: linePath, fill: "none", stroke: color, strokeWidth: "2" }),
6847
+ /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6848
+ "path",
6849
+ {
6850
+ d: areaPath,
6851
+ fill: `url(#${gradientId})`,
6852
+ className: "chart-area",
6853
+ style: animate ? { animationDelay: "600ms" } : { opacity: 1 }
6854
+ }
6855
+ ),
6856
+ /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6857
+ "path",
6858
+ {
6859
+ ref: (el) => {
6860
+ lineRefs.current[di] = el;
6861
+ },
6862
+ d: linePath,
6863
+ fill: "none",
6864
+ stroke: color,
6865
+ strokeWidth: "2"
6866
+ }
6867
+ ),
6770
6868
  showPoints && points.map((p, i) => /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6771
6869
  "circle",
6772
6870
  {
@@ -6786,7 +6884,7 @@ var CurveChart = import_react5.default.memo(({ data, labels, width, height, onHo
6786
6884
  ] });
6787
6885
  });
6788
6886
  CurveChart.displayName = "CurveChart";
6789
- var BarChart = import_react5.default.memo(({ data, labels, width, height, onHover, onMove, onLeave }) => {
6887
+ var BarChart = import_react5.default.memo(({ data, labels, width, height, animate, onHover, onMove, onLeave }) => {
6790
6888
  const entries = import_react5.default.useMemo(() => Object.entries(data), [data]);
6791
6889
  const maxVal = import_react5.default.useMemo(() => {
6792
6890
  const allValues = entries.flatMap(([, v]) => v);
@@ -6799,6 +6897,7 @@ var BarChart = import_react5.default.memo(({ data, labels, width, height, onHove
6799
6897
  const groupW = chartW / count;
6800
6898
  const barGap = groupCount > 1 ? 2 : 0;
6801
6899
  const barW = Math.max(1, Math.min(32, (groupW * 0.7 - barGap * (groupCount - 1)) / groupCount));
6900
+ const baseline = PADDING.top + chartH;
6802
6901
  const bars = import_react5.default.useMemo(
6803
6902
  () => entries.map(
6804
6903
  ([, values], di) => values.map((v, i) => {
@@ -6824,12 +6923,17 @@ var BarChart = import_react5.default.memo(({ data, labels, width, height, onHove
6824
6923
  return bars[di].map((b, i) => {
6825
6924
  const r2 = Math.min(4, b.w / 2);
6826
6925
  const d = b.h <= r2 ? `M ${b.x} ${b.y + b.h} V ${b.y} H ${b.x + b.w} V ${b.y + b.h} Z` : `M ${b.x} ${b.y + b.h} V ${b.y + r2} Q ${b.x} ${b.y} ${b.x + r2} ${b.y} H ${b.x + b.w - r2} Q ${b.x + b.w} ${b.y} ${b.x + b.w} ${b.y + r2} V ${b.y + b.h} Z`;
6926
+ const delay = 100 + i * 80;
6827
6927
  return /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6828
6928
  "path",
6829
6929
  {
6830
6930
  d,
6831
6931
  fill: color,
6832
- className: "chart-bar",
6932
+ className: `chart-bar ${animate ? "chart-bar-animate" : ""}`,
6933
+ style: animate ? {
6934
+ transformOrigin: `${b.x + b.w / 2}px ${baseline}px`,
6935
+ animationDelay: `${delay}ms`
6936
+ } : void 0,
6833
6937
  onMouseEnter: (e) => onHover(e, `${key}: ${labels[i]} \u2014 ${b.v}`),
6834
6938
  onMouseMove: onMove,
6835
6939
  onMouseLeave: onLeave
@@ -6842,7 +6946,7 @@ var BarChart = import_react5.default.memo(({ data, labels, width, height, onHove
6842
6946
  });
6843
6947
  BarChart.displayName = "BarChart";
6844
6948
  var PieDonutChart = import_react5.default.memo(
6845
- ({ data, labels, width, height, isDoughnut, onHover, onMove, onLeave }) => {
6949
+ ({ data, labels, width, height, animate, isDoughnut, onHover, onMove, onLeave }) => {
6846
6950
  const entries = import_react5.default.useMemo(() => Object.entries(data), [data]);
6847
6951
  const values = import_react5.default.useMemo(() => entries.flatMap(([, v]) => v), [entries]);
6848
6952
  const total = import_react5.default.useMemo(() => values.reduce((a, b) => a + b, 0) || 1, [values]);
@@ -6882,20 +6986,34 @@ var PieDonutChart = import_react5.default.memo(
6882
6986
  return { d, lx, ly, v, pct, angle, label: labels[i] || `${i + 1}` };
6883
6987
  });
6884
6988
  }, [values, total, cx, cy, r2, innerR, labels]);
6885
- return /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("svg", { viewBox: `0 0 ${size} ${size}`, className: "chart-svg chart-pie", children: sliceData.map((s, i) => /* @__PURE__ */ (0, import_jsx_runtime305.jsxs)("g", { children: [
6886
- /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6887
- "path",
6888
- {
6889
- d: s.d,
6890
- fill: PIE_COLORS[(i + colorOffset) % PIE_COLORS.length],
6891
- className: "chart-slice",
6892
- onMouseEnter: (e) => onHover(e, `${s.label}: ${s.v} (${s.pct}%)`),
6893
- onMouseMove: onMove,
6894
- onMouseLeave: onLeave
6895
- }
6896
- ),
6897
- s.angle > 0.2 && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("text", { x: s.lx, y: s.ly, className: "chart-pie-label", textAnchor: "middle", dominantBaseline: "central", children: s.v })
6898
- ] }, i)) });
6989
+ return /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("svg", { viewBox: `0 0 ${size} ${size}`, className: "chart-svg chart-pie", children: sliceData.map((s, i) => {
6990
+ const delay = i * 100;
6991
+ return /* @__PURE__ */ (0, import_jsx_runtime305.jsxs)("g", { className: animate ? "chart-slice-group-animate" : "", style: animate ? { animationDelay: `${delay}ms` } : void 0, children: [
6992
+ /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
6993
+ "path",
6994
+ {
6995
+ d: s.d,
6996
+ fill: PIE_COLORS[(i + colorOffset) % PIE_COLORS.length],
6997
+ className: "chart-slice",
6998
+ onMouseEnter: (e) => onHover(e, `${s.label}: ${s.v} (${s.pct}%)`),
6999
+ onMouseMove: onMove,
7000
+ onMouseLeave: onLeave
7001
+ }
7002
+ ),
7003
+ s.angle > 0.2 && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(
7004
+ "text",
7005
+ {
7006
+ x: s.lx,
7007
+ y: s.ly,
7008
+ className: `chart-pie-label ${animate ? "chart-pie-label-animate" : ""}`,
7009
+ style: animate ? { animationDelay: `${delay + 150}ms` } : void 0,
7010
+ textAnchor: "middle",
7011
+ dominantBaseline: "central",
7012
+ children: s.v
7013
+ }
7014
+ )
7015
+ ] }, i);
7016
+ }) });
6899
7017
  }
6900
7018
  );
6901
7019
  PieDonutChart.displayName = "PieDonutChart";
@@ -6929,13 +7047,15 @@ var Chart = import_react5.default.memo((props) => {
6929
7047
  const { width, height } = useChartSize(containerRef);
6930
7048
  const stableData = import_react5.default.useMemo(() => data, [JSON.stringify(data)]);
6931
7049
  const stableLabels = import_react5.default.useMemo(() => labels, [JSON.stringify(labels)]);
7050
+ const dataKey = import_react5.default.useMemo(() => JSON.stringify(labels), [labels]);
7051
+ const animate = useChartAnimation(containerRef, dataKey);
6932
7052
  const ready = width > 0 && height > 0;
6933
7053
  return /* @__PURE__ */ (0, import_jsx_runtime305.jsxs)("div", { className: "lib-xplat-chart", ref: containerRef, children: [
6934
- ready && type === "line" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(LineChart, { data: stableData, labels: stableLabels, width, height, onHover: show, onMove: move, onLeave: hide }),
6935
- ready && type === "curve" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(CurveChart, { data: stableData, labels: stableLabels, width, height, onHover: show, onMove: move, onLeave: hide }),
6936
- ready && type === "bar" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(BarChart, { data: stableData, labels: stableLabels, width, height, onHover: show, onMove: move, onLeave: hide }),
6937
- ready && type === "pie" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(PieDonutChart, { data: stableData, labels: stableLabels, width, height, onHover: show, onMove: move, onLeave: hide }),
6938
- ready && type === "doughnut" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(PieDonutChart, { data: stableData, labels: stableLabels, width, height, isDoughnut: true, onHover: show, onMove: move, onLeave: hide }),
7054
+ ready && type === "line" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(LineChart, { data: stableData, labels: stableLabels, width, height, animate, onHover: show, onMove: move, onLeave: hide }),
7055
+ ready && type === "curve" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(CurveChart, { data: stableData, labels: stableLabels, width, height, animate, onHover: show, onMove: move, onLeave: hide }),
7056
+ ready && type === "bar" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(BarChart, { data: stableData, labels: stableLabels, width, height, animate, onHover: show, onMove: move, onLeave: hide }),
7057
+ ready && type === "pie" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(PieDonutChart, { data: stableData, labels: stableLabels, width, height, animate, onHover: show, onMove: move, onLeave: hide }),
7058
+ ready && type === "doughnut" && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(PieDonutChart, { data: stableData, labels: stableLabels, width, height, animate, isDoughnut: true, onHover: show, onMove: move, onLeave: hide }),
6939
7059
  tooltip.visible && /* @__PURE__ */ (0, import_jsx_runtime305.jsx)(TooltipBubble, { x: tooltip.x, y: tooltip.y, containerWidth: width, children: tooltip.content })
6940
7060
  ] });
6941
7061
  });
@@ -7760,7 +7880,7 @@ var import_react_dom3 = require("react-dom");
7760
7880
  var import_jsx_runtime320 = require("react/jsx-runtime");
7761
7881
  var ANIMATION_DURATION_MS2 = 250;
7762
7882
  var Drawer = (props) => {
7763
- const { isOpen, onClose, placement = "right", width = 320, title, children } = props;
7883
+ const { isOpen, onClose, placement = "right", size = "md", title, children } = props;
7764
7884
  const [mounted, setMounted] = import_react17.default.useState(false);
7765
7885
  const [visible, setVisible] = import_react17.default.useState(false);
7766
7886
  import_react17.default.useEffect(() => {
@@ -7776,7 +7896,6 @@ var Drawer = (props) => {
7776
7896
  if (typeof document === "undefined") return null;
7777
7897
  if (!mounted) return null;
7778
7898
  const stateClass = visible ? "enter" : "exit";
7779
- const widthValue = typeof width === "number" ? `${width}px` : width;
7780
7899
  return (0, import_react_dom3.createPortal)(
7781
7900
  /* @__PURE__ */ (0, import_jsx_runtime320.jsx)(
7782
7901
  "div",
@@ -7786,8 +7905,7 @@ var Drawer = (props) => {
7786
7905
  children: /* @__PURE__ */ (0, import_jsx_runtime320.jsxs)(
7787
7906
  "div",
7788
7907
  {
7789
- className: clsx_default("lib-xplat-drawer", placement, stateClass),
7790
- style: { width: widthValue },
7908
+ className: clsx_default("lib-xplat-drawer", placement, size, stateClass),
7791
7909
  role: "dialog",
7792
7910
  "aria-modal": "true",
7793
7911
  onClick: (e) => e.stopPropagation(),
@@ -7847,6 +7965,8 @@ var useAutoPosition = (triggerRef, popRef, enabled = true) => {
7847
7965
  import_react18.default.useLayoutEffect(() => {
7848
7966
  if (!enabled) return;
7849
7967
  calculatePosition();
7968
+ const raf = requestAnimationFrame(calculatePosition);
7969
+ return () => cancelAnimationFrame(raf);
7850
7970
  }, [calculatePosition, enabled]);
7851
7971
  import_react18.default.useEffect(() => {
7852
7972
  if (!enabled) return;
@@ -8663,11 +8783,12 @@ var Select_default = Select;
8663
8783
 
8664
8784
  // src/components/Skeleton/Skeleton.tsx
8665
8785
  var import_jsx_runtime333 = require("react/jsx-runtime");
8786
+ var toSizeVar = (token) => token === "full" ? "100%" : `var(--spacing-size-${token})`;
8666
8787
  var Skeleton = (props) => {
8667
8788
  const { variant = "text", width, height } = props;
8668
8789
  const style = {
8669
- width: typeof width === "number" ? `${width}px` : width,
8670
- height: typeof height === "number" ? `${height}px` : height
8790
+ ...width != null && { width: toSizeVar(width) },
8791
+ ...height != null && { height: toSizeVar(height) }
8671
8792
  };
8672
8793
  return /* @__PURE__ */ (0, import_jsx_runtime333.jsx)(
8673
8794
  "div",
@@ -9812,14 +9933,8 @@ var Video_default = Video;
9812
9933
  var import_jsx_runtime348 = require("react/jsx-runtime");
9813
9934
  var FullGrid = (props) => {
9814
9935
  const { children, gap } = props;
9815
- return /* @__PURE__ */ (0, import_jsx_runtime348.jsx)(
9816
- "div",
9817
- {
9818
- className: "lib-xplat-full-grid",
9819
- style: gap ? { gap } : void 0,
9820
- children
9821
- }
9822
- );
9936
+ const style = gap != null ? { gap: `var(--spacing-space-${gap})` } : void 0;
9937
+ return /* @__PURE__ */ (0, import_jsx_runtime348.jsx)("div", { className: "lib-xplat-full-grid", style, children });
9823
9938
  };
9824
9939
  FullGrid.displayName = "FullGrid";
9825
9940
  var FullGrid_default = FullGrid;
@@ -9828,14 +9943,8 @@ var FullGrid_default = FullGrid;
9828
9943
  var import_jsx_runtime349 = require("react/jsx-runtime");
9829
9944
  var FullScreen = (props) => {
9830
9945
  const { children, gap } = props;
9831
- return /* @__PURE__ */ (0, import_jsx_runtime349.jsx)(
9832
- "div",
9833
- {
9834
- className: "lib-xplat-full-screen",
9835
- style: gap ? { gap } : void 0,
9836
- children
9837
- }
9838
- );
9946
+ const style = gap != null ? { gap: `var(--spacing-space-${gap})` } : void 0;
9947
+ return /* @__PURE__ */ (0, import_jsx_runtime349.jsx)("div", { className: "lib-xplat-full-screen", style, children });
9839
9948
  };
9840
9949
  FullScreen.displayName = "FullScreen";
9841
9950
  var FullScreen_default = FullScreen;
package/dist/index.css CHANGED
@@ -1826,6 +1826,7 @@
1826
1826
  font-weight: 600;
1827
1827
  fill: var(--semantic-text-inverse);
1828
1828
  pointer-events: none;
1829
+ opacity: 1;
1829
1830
  }
1830
1831
  .lib-xplat-chart .chart-pie {
1831
1832
  max-width: 300px;
@@ -1835,10 +1836,10 @@
1835
1836
  cursor: pointer;
1836
1837
  r: 0;
1837
1838
  opacity: 0;
1838
- transition: r 0.15s, opacity 0.15s;
1839
+ transition: r 0.15s ease-out, opacity 0.15s ease-out;
1839
1840
  }
1840
1841
  .lib-xplat-chart .chart-point:hover {
1841
- r: 5;
1842
+ r: 6;
1842
1843
  opacity: 1;
1843
1844
  }
1844
1845
  .lib-xplat-chart .chart-svg:hover .chart-point {
@@ -1847,7 +1848,7 @@
1847
1848
  }
1848
1849
  .lib-xplat-chart .chart-bar {
1849
1850
  cursor: pointer;
1850
- transition: opacity 0.15s, filter 0.15s;
1851
+ transition: opacity 0.15s ease-out, filter 0.15s ease-out;
1851
1852
  }
1852
1853
  .lib-xplat-chart .chart-bar:hover {
1853
1854
  opacity: 0.85;
@@ -1858,15 +1859,22 @@
1858
1859
  stroke: var(--semantic-surface-neutral-default);
1859
1860
  stroke-width: 2;
1860
1861
  transition:
1861
- opacity 0.15s,
1862
- filter 0.15s,
1863
- transform 0.15s;
1862
+ opacity 0.15s ease-out,
1863
+ filter 0.15s ease-out,
1864
+ transform 0.15s ease-out;
1864
1865
  transform-origin: center;
1865
1866
  }
1867
+ .lib-xplat-chart .chart-svg:hover .chart-slice {
1868
+ opacity: 0.5;
1869
+ }
1866
1870
  .lib-xplat-chart .chart-slice:hover {
1867
- opacity: 0.9;
1871
+ opacity: 1 !important;
1872
+ transform: scale(1.03);
1868
1873
  filter: brightness(1.05) drop-shadow(0 2px 6px rgba(0, 0, 0, 0.2));
1869
1874
  }
1875
+ .lib-xplat-chart .chart-area {
1876
+ opacity: 1;
1877
+ }
1870
1878
  .lib-xplat-chart .chart-tooltip {
1871
1879
  position: absolute;
1872
1880
  transform: translate(-50%, -100%);
@@ -1879,6 +1887,65 @@
1879
1887
  white-space: nowrap;
1880
1888
  pointer-events: none;
1881
1889
  z-index: 10;
1890
+ animation: chart-tooltip-in 150ms ease-out;
1891
+ }
1892
+ .lib-xplat-chart .chart-bar-animate {
1893
+ animation: chart-bar-grow 800ms ease-out both;
1894
+ }
1895
+ .lib-xplat-chart .chart-slice-group-animate {
1896
+ animation: chart-slice-in 1000ms ease-out both;
1897
+ }
1898
+ .lib-xplat-chart .chart-pie-label-animate {
1899
+ animation: chart-fade-in 150ms ease-out both;
1900
+ }
1901
+ .lib-xplat-chart .chart-area[style*=animationDelay] {
1902
+ animation: chart-fade-in 800ms ease-out both;
1903
+ }
1904
+ @keyframes chart-bar-grow {
1905
+ from {
1906
+ transform: scaleY(0);
1907
+ }
1908
+ to {
1909
+ transform: scaleY(1);
1910
+ }
1911
+ }
1912
+ @keyframes chart-slice-in {
1913
+ from {
1914
+ opacity: 0;
1915
+ transform: scale(0.8);
1916
+ }
1917
+ to {
1918
+ opacity: 1;
1919
+ transform: scale(1);
1920
+ }
1921
+ }
1922
+ @keyframes chart-fade-in {
1923
+ from {
1924
+ opacity: 0;
1925
+ }
1926
+ to {
1927
+ opacity: 1;
1928
+ }
1929
+ }
1930
+ @keyframes chart-tooltip-in {
1931
+ from {
1932
+ opacity: 0;
1933
+ transform: translate(-50%, -90%);
1934
+ }
1935
+ to {
1936
+ opacity: 1;
1937
+ transform: translate(-50%, -100%);
1938
+ }
1939
+ }
1940
+ @media (prefers-reduced-motion: reduce) {
1941
+ .lib-xplat-chart .chart-bar-animate,
1942
+ .lib-xplat-chart .chart-slice-group-animate,
1943
+ .lib-xplat-chart .chart-pie-label-animate,
1944
+ .lib-xplat-chart .chart-area {
1945
+ animation: none !important;
1946
+ opacity: 1 !important;
1947
+ transform: none !important;
1948
+ }
1882
1949
  }
1883
1950
 
1884
1951
  /* src/components/CheckBox/checkbox.scss */
@@ -2551,6 +2618,18 @@
2551
2618
  transition: transform 0.25s ease;
2552
2619
  z-index: 1001;
2553
2620
  }
2621
+ .lib-xplat-drawer.sm {
2622
+ width: 280px;
2623
+ }
2624
+ .lib-xplat-drawer.md {
2625
+ width: 360px;
2626
+ }
2627
+ .lib-xplat-drawer.lg {
2628
+ width: 480px;
2629
+ }
2630
+ .lib-xplat-drawer.xl {
2631
+ width: 640px;
2632
+ }
2554
2633
  .lib-xplat-drawer.right {
2555
2634
  right: 0;
2556
2635
  transform: translateX(100%);
@@ -2934,7 +3013,8 @@
2934
3013
  /* src/components/PopOver/popOver.scss */
2935
3014
  .lib-xplat-pop-over {
2936
3015
  position: relative;
2937
- width: fit-content;
3016
+ width: 100%;
3017
+ height: 100%;
2938
3018
  cursor: pointer;
2939
3019
  user-select: none;
2940
3020
  }