sellmate-design-system-react 9.0.0-beta.61 → 9.0.0-beta.62

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -8,7 +8,7 @@ import { createPortal } from 'react-dom';
8
8
  import * as RCheckbox from '@radix-ui/react-checkbox';
9
9
  import { createRoot } from 'react-dom/client';
10
10
  import * as RTooltip from '@radix-ui/react-tooltip';
11
- import * as RDropdown3 from '@radix-ui/react-dropdown-menu';
11
+ import * as RDropdown5 from '@radix-ui/react-dropdown-menu';
12
12
  import * as RSwitch from '@radix-ui/react-switch';
13
13
  import * as RDialog from '@radix-ui/react-dialog';
14
14
  import * as Ariakit from '@ariakit/react';
@@ -8007,8 +8007,8 @@ function renderItems(message, depth = 1) {
8007
8007
  });
8008
8008
  return out;
8009
8009
  }
8010
- var SCallout = /* @__PURE__ */ forwardRef(function SCallout2({ type = "default", message = [], children, className, style }, ref) {
8011
- const isDanger = type === "danger";
8010
+ var SCallout = /* @__PURE__ */ forwardRef(function SCallout2({ type = "default", showTitle = true, message = [], children, className, style }, ref) {
8011
+ const hasDangerTitle = type === "danger" && showTitle;
8012
8012
  const surface = SURFACE[type];
8013
8013
  const vars = {
8014
8014
  "--co-bg": surface.bg,
@@ -8027,7 +8027,7 @@ var SCallout = /* @__PURE__ */ forwardRef(function SCallout2({ type = "default",
8027
8027
  ),
8028
8028
  style: { ...vars, ...style },
8029
8029
  children: [
8030
- isDanger && /* @__PURE__ */ jsxs(
8030
+ hasDangerTitle && /* @__PURE__ */ jsxs(
8031
8031
  "div",
8032
8032
  {
8033
8033
  className: "flex shrink-0 flex-col items-center justify-center gap-[var(--cmp-callout-danger-title-gap)] px-[var(--cmp-callout-danger-title-paddingX)] py-[8px] text-[16px] font-bold leading-[26px]",
@@ -8354,6 +8354,58 @@ function clampToAvailableWidth(value, availableWidth) {
8354
8354
  const css = typeof value === "number" ? `${value}px` : value;
8355
8355
  return `min(${css}, ${availableWidth})`;
8356
8356
  }
8357
+ var VIEWPORT_PADDING = 12;
8358
+ var itemClass = cn(
8359
+ "flex min-h-[28px] cursor-pointer select-none items-center gap-[8px] rounded-[2px] px-[12px] py-[4px] text-[12px] leading-[20px] outline-none",
8360
+ "text-[color:var(--sys-color-fg-secondary)]",
8361
+ "data-[disabled]:cursor-not-allowed data-[disabled]:text-[color:var(--cmp-button-text-disabled)]",
8362
+ "data-[highlighted]:bg-[var(--sys-color-bg-accent)] data-[highlighted]:text-[color:var(--sys-color-fg-inverse)]"
8363
+ );
8364
+ function DropdownMenuContent({
8365
+ items,
8366
+ onItemClick,
8367
+ align = "start",
8368
+ className,
8369
+ ...contentProps
8370
+ }) {
8371
+ const portalContainer = usePortalContainer();
8372
+ return /* @__PURE__ */ jsx(RDropdown5.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(
8373
+ RDropdown5.Content,
8374
+ {
8375
+ sideOffset: 4,
8376
+ align,
8377
+ collisionPadding: VIEWPORT_PADDING,
8378
+ className: cn(
8379
+ "z-50 overflow-hidden rounded-[var(--cmp-listBox-radius)] bg-[var(--cmp-listBox-bg)] shadow-normal-sm",
8380
+ // 창보다 넓은 메뉴는 창 폭에 맞춰 줄인다. 호출부가 하한(min-width)을 줄 때도 같은
8381
+ // 상한으로 감싸야 한다 — min-width 가 max-width 를 이기기 때문이다.
8382
+ "max-w-[var(--radix-dropdown-menu-content-available-width)]",
8383
+ FLOATING_SLIDE_ANIM,
8384
+ className
8385
+ ),
8386
+ ...contentProps,
8387
+ children: items.map((it) => /* @__PURE__ */ jsxs(
8388
+ RDropdown5.Item,
8389
+ {
8390
+ disabled: it.disabled,
8391
+ onSelect: () => onItemClick?.(it.value),
8392
+ className: itemClass,
8393
+ children: [
8394
+ it.icon && /* @__PURE__ */ jsx(SIcon, { name: it.icon, size: 12 }),
8395
+ /* @__PURE__ */ jsx(
8396
+ "span",
8397
+ {
8398
+ className: "min-w-0 break-words",
8399
+ dangerouslySetInnerHTML: { __html: sanitizeInlineHtml(it.label) }
8400
+ }
8401
+ )
8402
+ ]
8403
+ },
8404
+ it.value
8405
+ ))
8406
+ }
8407
+ ) });
8408
+ }
8357
8409
  var SIZE2 = {
8358
8410
  xs: { height: 24, paddingX: 8, gap: 6, arrow: 12, fontSize: 12, minWidth: 64, splitMinWidth: 72 },
8359
8411
  sm: {
@@ -8390,13 +8442,6 @@ function splitDivider(color, outline) {
8390
8442
  };
8391
8443
  return (outline ? outlined : solid)[color];
8392
8444
  }
8393
- var VIEWPORT_PADDING = 12;
8394
- var itemClass = cn(
8395
- "flex min-h-[28px] cursor-pointer select-none items-center gap-[8px] rounded-[2px] px-[12px] py-[4px] text-[12px] leading-[20px] outline-none",
8396
- "text-[color:var(--sys-color-fg-secondary)]",
8397
- "data-[disabled]:cursor-not-allowed data-[disabled]:text-[color:var(--cmp-button-text-disabled)]",
8398
- "data-[highlighted]:bg-[var(--sys-color-bg-accent)] data-[highlighted]:text-[color:var(--sys-color-fg-inverse)]"
8399
- );
8400
8445
  var SDropdownButtonImpl = /* @__PURE__ */ forwardRef(
8401
8446
  function SDropdownButton({
8402
8447
  color = "primary",
@@ -8412,7 +8457,6 @@ var SDropdownButtonImpl = /* @__PURE__ */ forwardRef(
8412
8457
  className,
8413
8458
  style
8414
8459
  }, ref) {
8415
- const portalContainer = usePortalContainer();
8416
8460
  const insideModal = useInsideModal();
8417
8461
  const [open, setOpen] = useState(false);
8418
8462
  const splitWrapRef = useRef(null);
@@ -8466,45 +8510,20 @@ var SDropdownButtonImpl = /* @__PURE__ */ forwardRef(
8466
8510
  "border-[color:var(--dd-border)] bg-[var(--dd-bg)] text-[color:var(--dd-text)]",
8467
8511
  disabled ? "cursor-not-allowed" : "cursor-pointer hover:bg-[var(--dd-bg-hover)]"
8468
8512
  );
8469
- const menu = /* @__PURE__ */ jsx(RDropdown3.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(
8470
- RDropdown3.Content,
8513
+ const menu = /* @__PURE__ */ jsx(
8514
+ DropdownMenuContent,
8471
8515
  {
8472
- sideOffset: 4,
8473
- align: "start",
8516
+ items,
8517
+ onItemClick,
8474
8518
  alignOffset: split ? splitAlignOffset : 0,
8475
- collisionPadding: VIEWPORT_PADDING,
8476
8519
  className: cn(
8477
- "z-50 overflow-hidden rounded-[var(--cmp-listBox-radius)] bg-[var(--cmp-listBox-bg)] shadow-normal-sm",
8478
- // 창보다 넓은 메뉴는 창 폭에 맞춰 줄인다. 트리거 너비를 따르는 하한도 같은 상한으로
8479
- // 감싸야 한다 — min-width 가 max-width 를 이기기 때문이다.
8480
- "max-w-[var(--radix-dropdown-menu-content-available-width)]",
8481
- !split && "min-w-[min(var(--radix-dropdown-menu-trigger-width),var(--radix-dropdown-menu-content-available-width))]",
8482
- FLOATING_SLIDE_ANIM
8520
+ !split && "min-w-[min(var(--radix-dropdown-menu-trigger-width),var(--radix-dropdown-menu-content-available-width))]"
8483
8521
  ),
8484
- style: split ? { minWidth: clampToAvailableWidth(splitWidth, DROPDOWN_AVAILABLE_WIDTH) } : void 0,
8485
- children: items.map((it) => /* @__PURE__ */ jsxs(
8486
- RDropdown3.Item,
8487
- {
8488
- disabled: it.disabled,
8489
- onSelect: () => onItemClick?.(it.value),
8490
- className: itemClass,
8491
- children: [
8492
- it.icon && /* @__PURE__ */ jsx(SIcon, { name: it.icon, size: 12 }),
8493
- /* @__PURE__ */ jsx(
8494
- "span",
8495
- {
8496
- className: "min-w-0 break-words",
8497
- dangerouslySetInnerHTML: { __html: sanitizeInlineHtml(it.label) }
8498
- }
8499
- )
8500
- ]
8501
- },
8502
- it.value
8503
- ))
8522
+ style: split ? { minWidth: clampToAvailableWidth(splitWidth, DROPDOWN_AVAILABLE_WIDTH) } : void 0
8504
8523
  }
8505
- ) });
8524
+ );
8506
8525
  return /* @__PURE__ */ jsxs(
8507
- RDropdown3.Root,
8526
+ RDropdown5.Root,
8508
8527
  {
8509
8528
  modal: !insideModal,
8510
8529
  open,
@@ -8536,7 +8555,7 @@ var SDropdownButtonImpl = /* @__PURE__ */ forwardRef(
8536
8555
  children: label
8537
8556
  }
8538
8557
  ),
8539
- /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, children: /* @__PURE__ */ jsx(
8558
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, children: /* @__PURE__ */ jsx(
8540
8559
  "button",
8541
8560
  {
8542
8561
  ref: splitToggleRef,
@@ -8555,7 +8574,7 @@ var SDropdownButtonImpl = /* @__PURE__ */ forwardRef(
8555
8574
  ) })
8556
8575
  ]
8557
8576
  }
8558
- ) : /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs(
8577
+ ) : /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs(
8559
8578
  "button",
8560
8579
  {
8561
8580
  type: "button",
@@ -8583,6 +8602,87 @@ var SDropdownButtonImpl = /* @__PURE__ */ forwardRef(
8583
8602
  }
8584
8603
  );
8585
8604
  var SDropdownButton2 = /* @__PURE__ */ withDisplayName(SDropdownButtonImpl, "SDropdownButton");
8605
+ var DEFAULT_LABEL = "\uAE30\uB2A5 \uB354 \uBCF4\uAE30";
8606
+ var SMeatballButtonImpl = /* @__PURE__ */ forwardRef(
8607
+ function SMeatballButton({
8608
+ size = "sm",
8609
+ intent = "default",
8610
+ items = [],
8611
+ // 기본값을 리터럴로 둬야 README(docs:gen)에 실제 문구가 찍힌다
8612
+ tooltipText = "\uAE30\uB2A5 \uB354 \uBCF4\uAE30",
8613
+ ariaLabel,
8614
+ disabled = false,
8615
+ onItemClick,
8616
+ onOpenChange,
8617
+ className,
8618
+ style
8619
+ }, ref) {
8620
+ const insideModal = useInsideModal();
8621
+ const [open, setOpen] = useState(false);
8622
+ const buttonRef = useRef(null);
8623
+ const pointerRef = useRef(false);
8624
+ const setMenuOpen = (o) => {
8625
+ setOpen(o);
8626
+ onOpenChange?.(o);
8627
+ };
8628
+ useImperativeHandle(
8629
+ ref,
8630
+ () => ({
8631
+ open: () => setOpen(true),
8632
+ close: () => setOpen(false)
8633
+ }),
8634
+ []
8635
+ );
8636
+ const label = ariaLabel?.trim() || tooltipText.trim() || DEFAULT_LABEL;
8637
+ return /* @__PURE__ */ jsxs(
8638
+ RDropdown5.Root,
8639
+ {
8640
+ modal: !insideModal,
8641
+ open,
8642
+ onOpenChange: setMenuOpen,
8643
+ children: [
8644
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, disabled, children: /* @__PURE__ */ jsx(
8645
+ "span",
8646
+ {
8647
+ className: cn("inline-flex", className),
8648
+ style,
8649
+ onPointerDownCapture: () => pointerRef.current = true,
8650
+ onKeyDownCapture: () => pointerRef.current = false,
8651
+ children: /* @__PURE__ */ jsx(
8652
+ SGhostButton,
8653
+ {
8654
+ ref: buttonRef,
8655
+ icon: "etc",
8656
+ size,
8657
+ intent,
8658
+ tooltipText: open ? "" : tooltipText,
8659
+ ariaLabel: label,
8660
+ ariaExpanded: open,
8661
+ disabled
8662
+ }
8663
+ )
8664
+ }
8665
+ ) }),
8666
+ /* @__PURE__ */ jsx(
8667
+ DropdownMenuContent,
8668
+ {
8669
+ items,
8670
+ onItemClick,
8671
+ onPointerDown: () => pointerRef.current = true,
8672
+ onPointerDownOutside: () => pointerRef.current = true,
8673
+ onKeyDown: () => pointerRef.current = false,
8674
+ onCloseAutoFocus: (e) => {
8675
+ e.preventDefault();
8676
+ if (!pointerRef.current) buttonRef.current?.focus();
8677
+ }
8678
+ }
8679
+ )
8680
+ ]
8681
+ }
8682
+ );
8683
+ }
8684
+ );
8685
+ var SMeatballButton2 = /* @__PURE__ */ withDisplayName(SMeatballButtonImpl, "SMeatballButton");
8586
8686
  function SSwitch({
8587
8687
  value = false,
8588
8688
  leftLabel,
@@ -9558,7 +9658,7 @@ var SPopup = /* @__PURE__ */ forwardRef(function SPopup2({
9558
9658
  }
9559
9659
  );
9560
9660
  });
9561
- var DEFAULT_LABEL = { tip: "\uD65C\uC6A9 TIP", notion: "\uC0AC\uC6A9\uBC95 \uC548\uB0B4" };
9661
+ var DEFAULT_LABEL2 = { tip: "\uD65C\uC6A9 TIP", notion: "\uC0AC\uC6A9\uBC95 \uC548\uB0B4" };
9562
9662
  var ICON = { tip: "helpOutline", notion: "notion" };
9563
9663
  var VIEWPORT_GUTTER = 24;
9564
9664
  var CLOSE_INSET = 12;
@@ -9580,7 +9680,7 @@ function SGuide({
9580
9680
  const portalContainer = usePortalContainer();
9581
9681
  const isNotion = type === "notion";
9582
9682
  const isAutoWidth = popupWidth === "auto";
9583
- const defaultLabel = DEFAULT_LABEL[type];
9683
+ const defaultLabel = DEFAULT_LABEL2[type];
9584
9684
  const iconName = ICON[type];
9585
9685
  const messages = flattenMessages(message);
9586
9686
  const active = open;
@@ -16478,7 +16578,7 @@ var STable = /* @__PURE__ */ forwardRef(function STable2({
16478
16578
  ),
16479
16579
  contextMenuOn && typeof document !== "undefined" && createPortal(
16480
16580
  /* @__PURE__ */ jsxs(
16481
- RDropdown3.Root,
16581
+ RDropdown5.Root,
16482
16582
  {
16483
16583
  modal: false,
16484
16584
  open: contextMenuOpen,
@@ -16486,7 +16586,7 @@ var STable = /* @__PURE__ */ forwardRef(function STable2({
16486
16586
  if (!open) setContextMenu((m) => m == null ? null : { ...m, open: false });
16487
16587
  },
16488
16588
  children: [
16489
- /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, children: /* @__PURE__ */ jsx(
16589
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, children: /* @__PURE__ */ jsx(
16490
16590
  "span",
16491
16591
  {
16492
16592
  "aria-hidden": true,
@@ -16495,7 +16595,7 @@ var STable = /* @__PURE__ */ forwardRef(function STable2({
16495
16595
  }
16496
16596
  ) }),
16497
16597
  /* @__PURE__ */ jsx(
16498
- RDropdown3.Content,
16598
+ RDropdown5.Content,
16499
16599
  {
16500
16600
  align: "start",
16501
16601
  side: "bottom",
@@ -16509,7 +16609,7 @@ var STable = /* @__PURE__ */ forwardRef(function STable2({
16509
16609
  FLOATING_SLIDE_ANIM
16510
16610
  ),
16511
16611
  children: contextMenuItems?.map((item4) => /* @__PURE__ */ jsxs(
16512
- RDropdown3.Item,
16612
+ RDropdown5.Item,
16513
16613
  {
16514
16614
  disabled: item4.disabled,
16515
16615
  onSelect: () => onContextMenuItemClick?.(item4.value, contextMenu?.rows ?? []),
@@ -19404,6 +19504,7 @@ function ChartTooltip({
19404
19504
  anchor,
19405
19505
  bounds,
19406
19506
  gapX = DEFAULT_GAP_X,
19507
+ footer,
19407
19508
  className
19408
19509
  }) {
19409
19510
  const { ref, size } = useElementSize();
@@ -19454,7 +19555,8 @@ function ChartTooltip({
19454
19555
  ]
19455
19556
  },
19456
19557
  `${item4.label}-${index}`
19457
- ))
19558
+ )),
19559
+ footer != null && footer !== false && /* @__PURE__ */ jsx("div", { children: footer })
19458
19560
  ]
19459
19561
  }
19460
19562
  );
@@ -19545,6 +19647,7 @@ var SBarChart = /* @__PURE__ */ forwardRef(function SBarChart2({
19545
19647
  formatValue = defaultFormat,
19546
19648
  height,
19547
19649
  onBarClick,
19650
+ tooltipFooter,
19548
19651
  className,
19549
19652
  style
19550
19653
  }, ref) {
@@ -19973,7 +20076,16 @@ var SBarChart = /* @__PURE__ */ forwardRef(function SBarChart2({
19973
20076
  items: tooltipItems,
19974
20077
  anchor: tooltipAnchor,
19975
20078
  bounds: size,
19976
- gapX: tooltipGapX
20079
+ gapX: tooltipGapX,
20080
+ footer: tooltipFooter?.({
20081
+ categoryIndex: hoveredCategory,
20082
+ name: categories[hoveredCategory] ?? "",
20083
+ points: series.flatMap((s, seriesIndex) => {
20084
+ const value = s.data[hoveredCategory];
20085
+ if (value == null || !Number.isFinite(value)) return [];
20086
+ return [{ seriesIndex, categoryIndex: hoveredCategory, value }];
20087
+ })
20088
+ })
19977
20089
  }
19978
20090
  )
19979
20091
  ]
@@ -20035,7 +20147,8 @@ var POINT_HOVER_BG = "var(--cmp-chart-bg)";
20035
20147
  var POINT_HOVER_EXTENT = POINT_HOVER_RADIUS + POINT_HOVER_BORDER_WIDTH / 2;
20036
20148
  var BAND_MIN = 40;
20037
20149
  var VALUE_LABEL_GAP2 = 6;
20038
- var AREA_OPACITY = "var(--opacity-040)";
20150
+ var AREA_OPACITY_TOP = "30%";
20151
+ var AREA_OPACITY_BOTTOM = "var(--opacity-005)";
20039
20152
  var LINE_DATA_LABEL_COLOR = "var(--cmp-chart-bar-dataLabel-color-default)";
20040
20153
  var LINE_DATA_LABEL_TYPO = "typo-body-sm-medium";
20041
20154
  var LINE_DATA_LABEL_TYPO_HOVER = "typo-body-md-bold";
@@ -20131,6 +20244,7 @@ var SLineChart = /* @__PURE__ */ forwardRef(function SLineChart2({
20131
20244
  formatValue = defaultFormat2,
20132
20245
  height,
20133
20246
  onPointClick,
20247
+ tooltipFooter,
20134
20248
  className,
20135
20249
  style
20136
20250
  }, ref) {
@@ -20138,6 +20252,7 @@ var SLineChart = /* @__PURE__ */ forwardRef(function SLineChart2({
20138
20252
  const { ref: plotRef, size } = useElementSize();
20139
20253
  const { ref: axisTextRef, size: axisText } = useElementSize();
20140
20254
  const { ref: axisSampleRef, size: axisSample } = useElementSize();
20255
+ const gradientId = useId();
20141
20256
  const [hoveredCategory, setHoveredCategory] = useState(null);
20142
20257
  const colorAt = useCallback(
20143
20258
  (seriesIndex) => paletteColor(palette, seriesIndex, customColors),
@@ -20266,13 +20381,43 @@ var SLineChart = /* @__PURE__ */ forwardRef(function SLineChart2({
20266
20381
  {
20267
20382
  "aria-hidden": true,
20268
20383
  d,
20269
- style: { fill: colorAt(seriesIndex), fillOpacity: AREA_OPACITY }
20384
+ style: { fill: `url(#${gradientId}-area-${seriesIndex})` }
20270
20385
  },
20271
20386
  `area-${seriesIndex}-${runIndex}`
20272
20387
  );
20273
20388
  })
20274
20389
  );
20275
- }, [area, plotted, smooth, colorAt]);
20390
+ }, [area, plotted, smooth, gradientId]);
20391
+ const areaGradients = useMemo(() => {
20392
+ if (!area) return null;
20393
+ return /* @__PURE__ */ jsx("defs", { children: plotted.map((_, seriesIndex) => /* @__PURE__ */ jsxs(
20394
+ "linearGradient",
20395
+ {
20396
+ id: `${gradientId}-area-${seriesIndex}`,
20397
+ x1: "0",
20398
+ y1: "0",
20399
+ x2: "0",
20400
+ y2: "1",
20401
+ children: [
20402
+ /* @__PURE__ */ jsx(
20403
+ "stop",
20404
+ {
20405
+ offset: "0",
20406
+ style: { stopColor: colorAt(seriesIndex), stopOpacity: AREA_OPACITY_TOP }
20407
+ }
20408
+ ),
20409
+ /* @__PURE__ */ jsx(
20410
+ "stop",
20411
+ {
20412
+ offset: "1",
20413
+ style: { stopColor: colorAt(seriesIndex), stopOpacity: AREA_OPACITY_BOTTOM }
20414
+ }
20415
+ )
20416
+ ]
20417
+ },
20418
+ `area-gradient-${seriesIndex}`
20419
+ )) });
20420
+ }, [area, plotted, colorAt, gradientId]);
20276
20421
  const lines = useMemo(
20277
20422
  () => plotted.flatMap(
20278
20423
  (row, seriesIndex) => runsOf(row).map((run, runIndex) => {
@@ -20454,6 +20599,7 @@ var SLineChart = /* @__PURE__ */ forwardRef(function SLineChart2({
20454
20599
  }
20455
20600
  }
20456
20601
  ),
20602
+ areaGradients,
20457
20603
  areas,
20458
20604
  lines,
20459
20605
  pointHalos,
@@ -20469,7 +20615,16 @@ var SLineChart = /* @__PURE__ */ forwardRef(function SLineChart2({
20469
20615
  items: tooltipItems,
20470
20616
  anchor: tooltipAnchor,
20471
20617
  bounds: size,
20472
- gapX: { after: -4, before: -4 }
20618
+ gapX: { after: -4, before: -4 },
20619
+ footer: tooltipFooter?.({
20620
+ categoryIndex: hoveredCategory,
20621
+ name: categories[hoveredCategory] ?? "",
20622
+ points: rows.flatMap((row, seriesIndex) => {
20623
+ const point = row[hoveredCategory];
20624
+ if (point == null) return [];
20625
+ return [{ seriesIndex, categoryIndex: hoveredCategory, value: point.own }];
20626
+ })
20627
+ })
20473
20628
  }
20474
20629
  )
20475
20630
  ]
@@ -20487,9 +20642,11 @@ var SLineChart = /* @__PURE__ */ forwardRef(function SLineChart2({
20487
20642
  }
20488
20643
  );
20489
20644
  });
20490
- var DONUT_INNER_RATIO = 0.6;
20645
+ var DONUT_INNER_RATIO = 0.4;
20491
20646
  var LABEL_MIN_RATIO = 0.05;
20492
20647
  var PIE_LABEL_RADIUS_RATIO = 0.65;
20648
+ var HOVER_GROW = 4;
20649
+ var HOVER_CORNER = 2;
20493
20650
  var OPACITY_DEFAULT = "var(--cmp-chart-bar-opacity-default)";
20494
20651
  var OPACITY_DIMMED = "var(--cmp-chart-bar-opacity-dimmed)";
20495
20652
  var OPACITY_HOVER = 1;
@@ -20502,19 +20659,42 @@ var r2 = (value) => Math.round(value * 100) / 100;
20502
20659
  function polar(center, radius, angle) {
20503
20660
  return { x: center + radius * Math.sin(angle), y: center - radius * Math.cos(angle) };
20504
20661
  }
20505
- function slicePath(center, outer, inner, start, end) {
20662
+ var arc = (radius, large, sweep, p) => `A${r2(radius)} ${r2(radius)} 0 ${large} ${sweep} ${r2(p.x)} ${r2(p.y)}`;
20663
+ function fitCorner(corner, outer, inner, span) {
20664
+ if (corner <= 0 || outer <= 0) return 0;
20665
+ let fitted = Math.min(corner, (outer - inner) / 2);
20666
+ if (span < Math.PI) {
20667
+ const half = Math.sin(span / 2);
20668
+ fitted = Math.min(fitted, outer * half / (1 + half));
20669
+ if (inner > 0) fitted = Math.min(fitted, inner * half / (1 - half));
20670
+ }
20671
+ return fitted >= 0.5 ? fitted : 0;
20672
+ }
20673
+ function slicePath(center, outer, inner, start, end, corner = 0) {
20506
20674
  if (end - start >= Math.PI * 2 - 1e-6) {
20507
20675
  const ring = (radius) => `M${r2(center - radius)} ${r2(center)}A${r2(radius)} ${r2(radius)} 0 1 1 ${r2(center + radius)} ${r2(center)}A${r2(radius)} ${r2(radius)} 0 1 1 ${r2(center - radius)} ${r2(center)}Z`;
20508
20676
  return inner > 0 ? ring(outer) + ring(inner) : ring(outer);
20509
20677
  }
20510
- const large = end - start > Math.PI ? 1 : 0;
20511
- const o0 = polar(center, outer, start);
20512
- const o1 = polar(center, outer, end);
20513
- const outerArc = `M${r2(o0.x)} ${r2(o0.y)}A${r2(outer)} ${r2(outer)} 0 ${large} 1 ${r2(o1.x)} ${r2(o1.y)}`;
20514
- if (inner <= 0) return `${outerArc}L${r2(center)} ${r2(center)}Z`;
20515
- const i1 = polar(center, inner, end);
20516
- const i0 = polar(center, inner, start);
20517
- return `${outerArc}L${r2(i1.x)} ${r2(i1.y)}A${r2(inner)} ${r2(inner)} 0 ${large} 0 ${r2(i0.x)} ${r2(i0.y)}Z`;
20678
+ const span = end - start;
20679
+ const round = fitCorner(corner, outer, inner, span);
20680
+ const outerLine = Math.sqrt(Math.max(outer * outer - 2 * outer * round, 0));
20681
+ const outerPhi = round > 0 ? Math.asin(round / (outer - round)) : 0;
20682
+ const outerLarge = span - 2 * outerPhi > Math.PI ? 1 : 0;
20683
+ const o0 = polar(center, outerLine, start);
20684
+ let d = `M${r2(o0.x)} ${r2(o0.y)}`;
20685
+ if (round > 0) d += arc(round, 0, 1, polar(center, outer, start + outerPhi));
20686
+ d += arc(outer, outerLarge, 1, polar(center, outer, end - outerPhi));
20687
+ if (round > 0) d += arc(round, 0, 1, polar(center, outerLine, end));
20688
+ if (inner <= 0) return `${d}L${r2(center)} ${r2(center)}Z`;
20689
+ const innerLine = Math.sqrt(inner * inner + 2 * inner * round);
20690
+ const innerPhi = round > 0 ? Math.asin(round / (inner + round)) : 0;
20691
+ const innerLarge = span - 2 * innerPhi > Math.PI ? 1 : 0;
20692
+ const i0 = polar(center, innerLine, end);
20693
+ d += `L${r2(i0.x)} ${r2(i0.y)}`;
20694
+ if (round > 0) d += arc(round, 0, 1, polar(center, inner, end - innerPhi));
20695
+ d += arc(inner, innerLarge, 0, polar(center, inner, start + innerPhi));
20696
+ if (round > 0) d += arc(round, 0, 1, polar(center, innerLine, start));
20697
+ return `${d}Z`;
20518
20698
  }
20519
20699
  var RadialChart = /* @__PURE__ */ forwardRef(function RadialChart2({
20520
20700
  data,
@@ -20526,44 +20706,44 @@ var RadialChart = /* @__PURE__ */ forwardRef(function RadialChart2({
20526
20706
  showTooltip = true,
20527
20707
  formatValue = defaultFormat3,
20528
20708
  onSliceClick,
20709
+ tooltipFooter,
20529
20710
  className,
20530
20711
  style,
20531
20712
  innerRatio,
20532
- renderCenter,
20533
20713
  kind
20534
20714
  }, ref) {
20535
20715
  const { ref: plotRef, size } = useElementSize();
20536
20716
  const [hovered, setHovered] = useState(null);
20537
- const { arcs, total } = useMemo(() => {
20717
+ const arcs = useMemo(() => {
20538
20718
  const effective = palette === "custom" && !colors?.length ? "multi" : palette;
20539
- const valid = data.map((slice, index) => ({ ...slice, index })).filter((slice) => Number.isFinite(slice.value) && slice.value > 0);
20540
- const sum = valid.reduce((acc, slice) => acc + slice.value, 0);
20719
+ const valid = data.map((slice2, index) => ({ ...slice2, index })).filter((slice2) => Number.isFinite(slice2.value) && slice2.value > 0);
20720
+ const sum = valid.reduce((acc, slice2) => acc + slice2.value, 0);
20541
20721
  let angle = 0;
20542
- const list = valid.map((slice) => {
20543
- const ratio = slice.value / sum;
20722
+ const list = valid.map((slice2) => {
20723
+ const ratio = slice2.value / sum;
20544
20724
  const start = angle;
20545
20725
  angle += ratio * Math.PI * 2;
20546
20726
  return {
20547
- index: slice.index,
20548
- name: slice.name,
20549
- value: slice.value,
20727
+ index: slice2.index,
20728
+ name: slice2.name,
20729
+ value: slice2.value,
20550
20730
  ratio,
20551
20731
  start,
20552
20732
  end: angle,
20553
- color: paletteColor(effective, slice.index, colors)
20733
+ color: paletteColor(effective, slice2.index, colors)
20554
20734
  };
20555
20735
  });
20556
- return { arcs: list, total: sum };
20736
+ return list;
20557
20737
  }, [data, palette, colors]);
20558
20738
  const diameter = size.width;
20559
20739
  const center = diameter / 2;
20560
- const outer = center;
20740
+ const outer = Math.max(center - HOVER_GROW, 0);
20561
20741
  const inner = outer * innerRatio;
20562
- const hoveredArc = arcs.find((arc) => arc.index === hovered) ?? null;
20742
+ const hoveredArc = arcs.find((arc2) => arc2.index === hovered) ?? null;
20563
20743
  const legend = showLegend ? /* @__PURE__ */ jsx(
20564
20744
  ChartLegend,
20565
20745
  {
20566
- items: arcs.map((arc) => ({ name: arc.name, color: arc.color })),
20746
+ items: arcs.map((arc2) => ({ name: arc2.name, color: arc2.color })),
20567
20747
  activeIndex: hoveredArc ? arcs.indexOf(hoveredArc) : null
20568
20748
  }
20569
20749
  ) : null;
@@ -20574,6 +20754,17 @@ var RadialChart = /* @__PURE__ */ forwardRef(function RadialChart2({
20574
20754
  return { left: point.x, right: point.x, top: point.y };
20575
20755
  }, [hoveredArc, diameter, center, outer, inner]);
20576
20756
  const labelRadius = inner > 0 ? (outer + inner) / 2 : outer * PIE_LABEL_RADIUS_RATIO;
20757
+ const slice = (target) => {
20758
+ const picked = hovered === target.index;
20759
+ return slicePath(
20760
+ center,
20761
+ picked ? outer + HOVER_GROW : outer,
20762
+ picked ? Math.max(inner - HOVER_GROW, 0) : inner,
20763
+ target.start,
20764
+ target.end,
20765
+ picked ? HOVER_CORNER : 0
20766
+ );
20767
+ };
20577
20768
  return /* @__PURE__ */ jsx(
20578
20769
  ChartFrame,
20579
20770
  {
@@ -20603,34 +20794,34 @@ var RadialChart = /* @__PURE__ */ forwardRef(function RadialChart2({
20603
20794
  style: { fill: "var(--cmp-chart-grid-line-color)" }
20604
20795
  }
20605
20796
  )
20606
- ) : arcs.map((arc) => {
20607
- const opacity = hovered == null ? OPACITY_DEFAULT : hovered === arc.index ? OPACITY_HOVER : OPACITY_DIMMED;
20797
+ ) : arcs.map((arc2) => {
20798
+ const opacity = hovered == null ? OPACITY_DEFAULT : hovered === arc2.index ? OPACITY_HOVER : OPACITY_DIMMED;
20608
20799
  return /* @__PURE__ */ jsx(
20609
20800
  "path",
20610
20801
  {
20611
- d: slicePath(center, outer, inner, arc.start, arc.end),
20802
+ d: slice(arc2),
20612
20803
  fillRule: "evenodd",
20613
20804
  className: "transition-opacity duration-200 ease-out motion-reduce:transition-none",
20614
20805
  style: {
20615
- fill: arc.color,
20806
+ fill: arc2.color,
20616
20807
  opacity,
20617
20808
  cursor: onSliceClick ? "pointer" : void 0
20618
20809
  },
20619
- onMouseEnter: () => setHovered(arc.index),
20810
+ onMouseEnter: () => setHovered(arc2.index),
20620
20811
  onClick: onSliceClick ? () => onSliceClick({
20621
- index: arc.index,
20622
- name: arc.name,
20623
- value: arc.value,
20624
- ratio: arc.ratio
20812
+ index: arc2.index,
20813
+ name: arc2.name,
20814
+ value: arc2.value,
20815
+ ratio: arc2.ratio
20625
20816
  }) : void 0,
20626
- children: /* @__PURE__ */ jsx("title", { children: `${arc.name} ${formatValue(arc.value)} (${formatRatio(arc.ratio)})` })
20817
+ children: /* @__PURE__ */ jsx("title", { children: `${arc2.name} ${formatValue(arc2.value)} (${formatRatio(arc2.ratio)})` })
20627
20818
  },
20628
- `slice-${arc.index}`
20819
+ `slice-${arc2.index}`
20629
20820
  );
20630
20821
  }),
20631
- showValueLabel && arcs.map((arc) => {
20632
- if (arc.ratio < LABEL_MIN_RATIO) return null;
20633
- const point = polar(center, labelRadius, (arc.start + arc.end) / 2);
20822
+ showValueLabel && arcs.map((arc2) => {
20823
+ if (arc2.ratio < LABEL_MIN_RATIO) return null;
20824
+ const point = polar(center, labelRadius, (arc2.start + arc2.end) / 2);
20634
20825
  return /* @__PURE__ */ jsx(
20635
20826
  "text",
20636
20827
  {
@@ -20642,25 +20833,16 @@ var RadialChart = /* @__PURE__ */ forwardRef(function RadialChart2({
20642
20833
  className: "pointer-events-none typo-body-sm-bold transition-opacity duration-200 ease-out motion-reduce:transition-none",
20643
20834
  style: {
20644
20835
  fill: "var(--sys-color-fg-inverse)",
20645
- opacity: hovered != null && hovered !== arc.index ? OPACITY_DIMMED : void 0
20836
+ opacity: hovered != null && hovered !== arc2.index ? OPACITY_DIMMED : void 0
20646
20837
  },
20647
- children: formatRatio(arc.ratio)
20838
+ children: formatRatio(arc2.ratio)
20648
20839
  },
20649
- `label-${arc.index}`
20840
+ `label-${arc2.index}`
20650
20841
  );
20651
20842
  })
20652
20843
  ]
20653
20844
  }
20654
20845
  ),
20655
- renderCenter && diameter > 0 && // 가운데 글자는 조각을 가리지 않도록 마우스를 통과시킨다.
20656
- /* @__PURE__ */ jsx(
20657
- "div",
20658
- {
20659
- className: "pointer-events-none absolute top-1/2 left-1/2 flex -translate-x-1/2 -translate-y-1/2 flex-col items-center text-center",
20660
- style: { maxWidth: inner * Math.SQRT2 },
20661
- children: renderCenter(total)
20662
- }
20663
- ),
20664
20846
  showTooltip && hoveredArc && tooltipAnchor && /* @__PURE__ */ jsx(
20665
20847
  ChartTooltip,
20666
20848
  {
@@ -20673,19 +20855,19 @@ var RadialChart = /* @__PURE__ */ forwardRef(function RadialChart2({
20673
20855
  }
20674
20856
  ],
20675
20857
  anchor: tooltipAnchor,
20676
- bounds: size
20858
+ bounds: size,
20859
+ footer: tooltipFooter?.({
20860
+ index: hoveredArc.index,
20861
+ name: hoveredArc.name,
20862
+ value: hoveredArc.value,
20863
+ ratio: hoveredArc.ratio
20864
+ })
20677
20865
  }
20678
20866
  )
20679
20867
  ] })
20680
20868
  }
20681
20869
  );
20682
20870
  });
20683
- function RadialCenter({ label, value }) {
20684
- return /* @__PURE__ */ jsxs(Fragment, { children: [
20685
- label != null && /* @__PURE__ */ jsx("span", { className: cn("typo-body-sm-medium text-(--cmp-chart-axis-color)"), children: label }),
20686
- /* @__PURE__ */ jsx("span", { className: "typo-body-lg-bold break-all text-(--cmp-chart-bar-dataLabel-color-default)", children: value })
20687
- ] });
20688
- }
20689
20871
  var SPieChart = /* @__PURE__ */ forwardRef(function SPieChart2({
20690
20872
  palette = "multi",
20691
20873
  showValueLabel = false,
@@ -20709,17 +20891,12 @@ var SPieChart = /* @__PURE__ */ forwardRef(function SPieChart2({
20709
20891
  }
20710
20892
  );
20711
20893
  });
20712
- var defaultFormat4 = (value) => value.toLocaleString();
20713
20894
  var SDonutChart = /* @__PURE__ */ forwardRef(function SDonutChart2({
20714
- centerLabel,
20715
- centerValue,
20716
- hideCenter = false,
20717
20895
  palette = "multi",
20718
20896
  showValueLabel = false,
20719
20897
  showLegend = true,
20720
20898
  legendPosition = "top",
20721
20899
  showTooltip = true,
20722
- formatValue = defaultFormat4,
20723
20900
  ...props
20724
20901
  }, ref) {
20725
20902
  return /* @__PURE__ */ jsx(
@@ -20732,10 +20909,8 @@ var SDonutChart = /* @__PURE__ */ forwardRef(function SDonutChart2({
20732
20909
  showLegend,
20733
20910
  legendPosition,
20734
20911
  showTooltip,
20735
- formatValue,
20736
20912
  innerRatio: DONUT_INNER_RATIO,
20737
- kind: "\uB3C4\uB11B \uADF8\uB798\uD504",
20738
- renderCenter: hideCenter ? void 0 : (total) => /* @__PURE__ */ jsx(RadialCenter, { label: centerLabel, value: centerValue ?? formatValue(total) })
20913
+ kind: "\uB3C4\uB11B \uADF8\uB798\uD504"
20739
20914
  }
20740
20915
  );
20741
20916
  });
@@ -22021,7 +22196,7 @@ var PaletteItem = ({
22021
22196
  className,
22022
22197
  onSelect,
22023
22198
  children
22024
- }) => asMenu ? /* @__PURE__ */ jsx(RDropdown3.Item, { title: label, "aria-label": label, className, onSelect, children }) : /* @__PURE__ */ jsx("button", { type: "button", title: label, "aria-label": label, className, onClick: onSelect, children });
22199
+ }) => asMenu ? /* @__PURE__ */ jsx(RDropdown5.Item, { title: label, "aria-label": label, className, onSelect, children }) : /* @__PURE__ */ jsx("button", { type: "button", title: label, "aria-label": label, className, onClick: onSelect, children });
22025
22200
  var ColorPalette = ({
22026
22201
  colors,
22027
22202
  columns,
@@ -22153,7 +22328,7 @@ var TableMenuItem = ({
22153
22328
  disabled,
22154
22329
  onSelect
22155
22330
  }) => /* @__PURE__ */ jsx(
22156
- RDropdown3.Item,
22331
+ RDropdown5.Item,
22157
22332
  {
22158
22333
  className: cn(menuItemClass, menuItemDisabledClass),
22159
22334
  disabled,
@@ -22320,8 +22495,8 @@ function EditorToolbarBar({
22320
22495
  const node = (item4) => {
22321
22496
  switch (item4) {
22322
22497
  case "heading":
22323
- return /* @__PURE__ */ jsxs(RDropdown3.Root, { modal: !insideModal, children: [
22324
- /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(
22498
+ return /* @__PURE__ */ jsxs(RDropdown5.Root, { modal: !insideModal, children: [
22499
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(
22325
22500
  ToolbarButton,
22326
22501
  {
22327
22502
  label: "\uC81C\uBAA9 \uB2E8\uACC4",
@@ -22334,9 +22509,9 @@ function EditorToolbarBar({
22334
22509
  ]
22335
22510
  }
22336
22511
  ) }),
22337
- /* @__PURE__ */ jsx(RDropdown3.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(RDropdown3.Content, { sideOffset: 4, align: "start", className: menuClass, children: [
22512
+ /* @__PURE__ */ jsx(RDropdown5.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(RDropdown5.Content, { sideOffset: 4, align: "start", className: menuClass, children: [
22338
22513
  /* @__PURE__ */ jsx(
22339
- RDropdown3.Item,
22514
+ RDropdown5.Item,
22340
22515
  {
22341
22516
  className: menuItemClass,
22342
22517
  onSelect: () => chain()?.setParagraph().run(),
@@ -22344,7 +22519,7 @@ function EditorToolbarBar({
22344
22519
  }
22345
22520
  ),
22346
22521
  SEDITOR_HEADING_LEVELS.map((level) => /* @__PURE__ */ jsx(
22347
- RDropdown3.Item,
22522
+ RDropdown5.Item,
22348
22523
  {
22349
22524
  className: menuItemClass,
22350
22525
  onSelect: () => chain()?.setHeading({ level }).run(),
@@ -22355,13 +22530,13 @@ function EditorToolbarBar({
22355
22530
  ] }) })
22356
22531
  ] }, item4);
22357
22532
  case "fontSize":
22358
- return /* @__PURE__ */ jsxs(RDropdown3.Root, { modal: !insideModal, children: [
22359
- /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(ToolbarButton, { label: "\uAE00\uC790 \uD06C\uAE30", disabled: off, className: "px-[6px]", children: [
22533
+ return /* @__PURE__ */ jsxs(RDropdown5.Root, { modal: !insideModal, children: [
22534
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(ToolbarButton, { label: "\uAE00\uC790 \uD06C\uAE30", disabled: off, className: "px-[6px]", children: [
22360
22535
  /* @__PURE__ */ jsx("span", { className: "text-[12px] leading-[20px]", children: activeFontSize ?? FONT_SIZE_DEFAULT_LABEL }),
22361
22536
  /* @__PURE__ */ jsx(SIcon, { name: "caretDown", size: 12 })
22362
22537
  ] }) }),
22363
- /* @__PURE__ */ jsx(RDropdown3.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(
22364
- RDropdown3.Content,
22538
+ /* @__PURE__ */ jsx(RDropdown5.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(
22539
+ RDropdown5.Content,
22365
22540
  {
22366
22541
  sideOffset: 4,
22367
22542
  align: "start",
@@ -22369,7 +22544,7 @@ function EditorToolbarBar({
22369
22544
  style: { maxHeight: FONT_SIZE_MENU_MAX_HEIGHT },
22370
22545
  children: [
22371
22546
  /* @__PURE__ */ jsx(
22372
- RDropdown3.Item,
22547
+ RDropdown5.Item,
22373
22548
  {
22374
22549
  className: cn(menuItemClass, activeFontSize === null && menuItemSelectedClass),
22375
22550
  title: `${FONT_SIZE_DEFAULT_LABEL} (\uBCF8\uBB38 ${SEDITOR_DEFAULT_FONT_SIZE}px)`,
@@ -22378,7 +22553,7 @@ function EditorToolbarBar({
22378
22553
  }
22379
22554
  ),
22380
22555
  SEDITOR_FONT_SIZES.map((size) => /* @__PURE__ */ jsx(
22381
- RDropdown3.Item,
22556
+ RDropdown5.Item,
22382
22557
  {
22383
22558
  ref: activeFontSize === size ? (el) => {
22384
22559
  el?.scrollIntoView({ block: "nearest" });
@@ -22470,9 +22645,9 @@ function EditorToolbarBar({
22470
22645
  },
22471
22646
  item4
22472
22647
  );
22473
- return /* @__PURE__ */ jsxs(RDropdown3.Root, { modal: !insideModal, children: [
22474
- /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsx(ToolbarButton, { label: "\uAE00\uC790\uC0C9", disabled: off, children: /* @__PURE__ */ jsx(ColorIndicator, { color: off ? "currentColor" : activeColor, children: /* @__PURE__ */ jsx(IconTextColor, { size: ICON_SIZE }) }) }) }),
22475
- /* @__PURE__ */ jsx(RDropdown3.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(RDropdown3.Content, { sideOffset: 4, align: "start", className: menuClass, children: /* @__PURE__ */ jsx(
22648
+ return /* @__PURE__ */ jsxs(RDropdown5.Root, { modal: !insideModal, children: [
22649
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsx(ToolbarButton, { label: "\uAE00\uC790\uC0C9", disabled: off, children: /* @__PURE__ */ jsx(ColorIndicator, { color: off ? "currentColor" : activeColor, children: /* @__PURE__ */ jsx(IconTextColor, { size: ICON_SIZE }) }) }) }),
22650
+ /* @__PURE__ */ jsx(RDropdown5.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(RDropdown5.Content, { sideOffset: 4, align: "start", className: menuClass, children: /* @__PURE__ */ jsx(
22476
22651
  ColorPalette,
22477
22652
  {
22478
22653
  asMenu: true,
@@ -22578,14 +22753,14 @@ function EditorToolbarBar({
22578
22753
  case "list": {
22579
22754
  const ListIcon = state2.orderedList ? IconOrderedList : state2.taskList ? IconTaskList : IconBulletList;
22580
22755
  const listActive = state2.bulletList || state2.orderedList || state2.taskList;
22581
- return /* @__PURE__ */ jsxs(RDropdown3.Root, { modal: !insideModal, children: [
22582
- /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(ToolbarButton, { label: "\uBAA9\uB85D", active: listActive, disabled: off, className: "px-[4px]", children: [
22756
+ return /* @__PURE__ */ jsxs(RDropdown5.Root, { modal: !insideModal, children: [
22757
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(ToolbarButton, { label: "\uBAA9\uB85D", active: listActive, disabled: off, className: "px-[4px]", children: [
22583
22758
  /* @__PURE__ */ jsx(ListIcon, { size: ICON_SIZE }),
22584
22759
  /* @__PURE__ */ jsx(SIcon, { name: "caretDown", size: CARET_SIZE })
22585
22760
  ] }) }),
22586
- /* @__PURE__ */ jsx(RDropdown3.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(RDropdown3.Content, { sideOffset: 4, align: "start", className: menuClass, children: [
22761
+ /* @__PURE__ */ jsx(RDropdown5.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(RDropdown5.Content, { sideOffset: 4, align: "start", className: menuClass, children: [
22587
22762
  /* @__PURE__ */ jsxs(
22588
- RDropdown3.Item,
22763
+ RDropdown5.Item,
22589
22764
  {
22590
22765
  className: menuItemClass,
22591
22766
  onSelect: () => chain()?.toggleBulletList().run(),
@@ -22596,7 +22771,7 @@ function EditorToolbarBar({
22596
22771
  }
22597
22772
  ),
22598
22773
  /* @__PURE__ */ jsxs(
22599
- RDropdown3.Item,
22774
+ RDropdown5.Item,
22600
22775
  {
22601
22776
  className: menuItemClass,
22602
22777
  onSelect: () => chain()?.toggleOrderedList().run(),
@@ -22607,7 +22782,7 @@ function EditorToolbarBar({
22607
22782
  }
22608
22783
  ),
22609
22784
  /* @__PURE__ */ jsxs(
22610
- RDropdown3.Item,
22785
+ RDropdown5.Item,
22611
22786
  {
22612
22787
  className: menuItemClass,
22613
22788
  onSelect: () => chain()?.toggleTaskList().run(),
@@ -22711,17 +22886,17 @@ function EditorToolbarBar({
22711
22886
  );
22712
22887
  case "table":
22713
22888
  return /* @__PURE__ */ jsxs(
22714
- RDropdown3.Root,
22889
+ RDropdown5.Root,
22715
22890
  {
22716
22891
  open: tableOpen,
22717
22892
  onOpenChange: setTableOpen,
22718
22893
  modal: !insideModal,
22719
22894
  children: [
22720
- /* @__PURE__ */ jsx(RDropdown3.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(ToolbarButton, { label: "\uD45C", active: state2.inTable, disabled: off, className: "px-[6px]", children: [
22895
+ /* @__PURE__ */ jsx(RDropdown5.Trigger, { asChild: true, disabled: off, children: /* @__PURE__ */ jsxs(ToolbarButton, { label: "\uD45C", active: state2.inTable, disabled: off, className: "px-[6px]", children: [
22721
22896
  /* @__PURE__ */ jsx(IconTable, { size: ICON_SIZE }),
22722
22897
  /* @__PURE__ */ jsx(SIcon, { name: "caretDown", size: CARET_SIZE })
22723
22898
  ] }) }),
22724
- /* @__PURE__ */ jsx(RDropdown3.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(RDropdown3.Content, { sideOffset: 4, align: "start", className: menuClass, children: [
22899
+ /* @__PURE__ */ jsx(RDropdown5.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(RDropdown5.Content, { sideOffset: 4, align: "start", className: menuClass, children: [
22725
22900
  !state2.inTable && /* @__PURE__ */ jsxs(Fragment, { children: [
22726
22901
  /* @__PURE__ */ jsx(
22727
22902
  TableSizePicker,
@@ -22733,7 +22908,7 @@ function EditorToolbarBar({
22733
22908
  }
22734
22909
  }
22735
22910
  ),
22736
- /* @__PURE__ */ jsx(RDropdown3.Separator, { className: menuSeparatorClass })
22911
+ /* @__PURE__ */ jsx(RDropdown5.Separator, { className: menuSeparatorClass })
22737
22912
  ] }),
22738
22913
  /* @__PURE__ */ jsx(
22739
22914
  TableMenuItem,
@@ -22767,7 +22942,7 @@ function EditorToolbarBar({
22767
22942
  onSelect: () => chain()?.addColumnAfter().run()
22768
22943
  }
22769
22944
  ),
22770
- /* @__PURE__ */ jsx(RDropdown3.Separator, { className: menuSeparatorClass }),
22945
+ /* @__PURE__ */ jsx(RDropdown5.Separator, { className: menuSeparatorClass }),
22771
22946
  /* @__PURE__ */ jsx(
22772
22947
  TableMenuItem,
22773
22948
  {
@@ -22800,7 +22975,7 @@ function EditorToolbarBar({
22800
22975
  onSelect: () => chain()?.toggleHeaderColumn().run()
22801
22976
  }
22802
22977
  ),
22803
- /* @__PURE__ */ jsx(RDropdown3.Separator, { className: menuSeparatorClass }),
22978
+ /* @__PURE__ */ jsx(RDropdown5.Separator, { className: menuSeparatorClass }),
22804
22979
  /* @__PURE__ */ jsx(
22805
22980
  TableMenuItem,
22806
22981
  {
@@ -26753,6 +26928,6 @@ function STimeRangePicker({
26753
26928
  );
26754
26929
  }
26755
26930
 
26756
- export { ACCOUNT_LIST_BOX_ICONS, ACCOUNT_LIST_BOX_ITEM_TONES, ACCOUNT_LIST_BOX_LABELS, ACCOUNT_LIST_BOX_LAYOUT, ACCOUNT_LIST_BOX_TONE_CONFIG, BADGE_COLORS, BAR_GAP, BAR_SIZE_MAX, BAR_SIZE_MIN, BUTTON_COLORS, BUTTON_SIZES, CALENDAR_BOARD_DAY_BG, CALENDAR_BOARD_DAY_COLORS, CALENDAR_BOARD_EVENT_COLORS, CALENDAR_BOARD_EVENT_PRESETS, CALENDAR_BOARD_MAX_VISIBLE_EVENTS, CHAT_ATTACHED_FILE_CONFIG, CHAT_FILE_CONFIG, CHAT_MESSAGE_DIRECTIONS, CHAT_MESSAGE_READ_STATUSES, CHAT_MESSAGE_VARIANTS, CHIP_COLORS, COLOR_KEYS, FIELD_WIDTH_GRADES, GNB_COLORS, GNB_COMMON, GNB_FOLD_MS, GNB_FULL_LOGO_WIDTH, GNB_HEADER, GNB_MENU, GNB_MENU_WIDTH, GNB_RAIL, GNB_RAIL_WIDTH, GNB_SYSTEM_COLORS, GNB_SYSTEM_COLOR_CONFIG, GNB_SYSTEM_LAYOUT, GNB_SYSTEM_PLACEMENTS, GNB_SYSTEM_TOP_COLOR_CONFIG, ICONS, IMAGE_FITS, LAUNCHER_LIST_BOX_LAYOUT, LAUNCHER_LIST_BOX_LOGO_HEIGHT, LAUNCHER_LIST_BOX_LOGO_SERVICE_GAP, LAUNCHER_LIST_BOX_TRAILING_ICON, LAUNCHER_LIST_BOX_WIDTH, LAUNCHER_SERVICES, LAUNCHER_SERVICE_CATALOG, LOGO_DEFAULT_SIZE, LOGO_NAMES, PAGE_BACKGROUNDS, PAGE_CONTENT_HEIGHTS, PAGE_CONTENT_WIDTHS, PAGE_HEADER_VARIANTS, RangeCalendar, SAccountListBox, SActionModal, SBadge, SBarChart, SBarcodeInput, SButton, SCROLL_AREA_AXES, SCalendar, SCalendarBoard, SCallout, SCard, SChatAttachedFile2 as SChatAttachedFile, SChatFile2 as SChatFile, SChatInput2 as SChatInput, SChatMessage2 as SChatMessage, SChatSystemMessage2 as SChatSystemMessage, SCheckbox, SChip2 as SChip, SChipFilter, SChipInput, SCircleProgress, SConfirmModal, SDatePicker, SDatePickerMonthListbox, SDatePickerYearListbox, SDateRangePicker, SDivider, SDonutChart, SDraggableGroup, SDraggableItem2 as SDraggableItem, SDraggableList, SDraggableProvider, SDrawer, SDropdownButton2 as SDropdownButton, SEDITOR_DEFAULT_FONT_SIZE, SEDITOR_HEADING_LABELS, SEDITOR_HEADING_LEVELS, SEditor, SExpansionItem, SExpansionList2 as SExpansionList, SField, SFilePicker, SForm, SGhostButton, SGnb, SGnbSystem, SGnbSystemContext, SGuide, SIcon, SImage, SInput, SKeyValueTable, SLAYOUT_MIN_WIDTH, SLauncherListBox, SLayout, SLayoutContext, SLineChart, SLinearProgress, SList2 as SList, SListItem2 as SListItem, SLoadingContainer, SLoadingModal, SLoadingViewport, SLoginCard2 as SLoginCard, SLogo, SModal, SModalOutlet, SNumberInput, SPage, SPageHeader, SPagination, SPieChart, SPopover, SPopup, SPortal, SRadio, SRadioButton, SRadioCard, SRadioCardGroup, SRadioGroup, SSPLITTER_UNITS, SScrollArea, SSearchInput, SSectionHeaderCard2 as SSectionHeaderCard, SSelect2 as SSelect, SSplitter2 as SSplitter, SStepper, SSwitch, SSystemActionButton, STEPPER_SIZES, STable, STableBar, STabs, STag, STextLink, STextarea, STimePicker, STimeRangePicker, SToast, SToastContainer, SToggle, STooltip2 as STooltip, STree2 as STree, STreeItem2 as STreeItem, SYSTEM_ACTION_BUTTON_COLORS, SYSTEM_ACTION_BUTTON_COLOR_CONFIG, SYSTEM_ACTION_BUTTON_LAYOUT, SYSTEM_ACTION_BUTTON_TYPES, SYSTEM_ACTION_BUTTON_TYPE_CONFIG, TAG_COLORS, TAG_SHAPES, TAG_SIZES, TIMEPICKER_SIZES, TIMEPICKER_SIZE_CONFIG, buttonPreset, cn, fieldWidthValue, fileExtension, findGnbAncestors, findGnbRailValue, formatFileSize, isColorKey, isFieldWidthGrade, loading, normalizeExtension, resolveColor, useSLayout };
26931
+ export { ACCOUNT_LIST_BOX_ICONS, ACCOUNT_LIST_BOX_ITEM_TONES, ACCOUNT_LIST_BOX_LABELS, ACCOUNT_LIST_BOX_LAYOUT, ACCOUNT_LIST_BOX_TONE_CONFIG, BADGE_COLORS, BAR_GAP, BAR_SIZE_MAX, BAR_SIZE_MIN, BUTTON_COLORS, BUTTON_SIZES, CALENDAR_BOARD_DAY_BG, CALENDAR_BOARD_DAY_COLORS, CALENDAR_BOARD_EVENT_COLORS, CALENDAR_BOARD_EVENT_PRESETS, CALENDAR_BOARD_MAX_VISIBLE_EVENTS, CHAT_ATTACHED_FILE_CONFIG, CHAT_FILE_CONFIG, CHAT_MESSAGE_DIRECTIONS, CHAT_MESSAGE_READ_STATUSES, CHAT_MESSAGE_VARIANTS, CHIP_COLORS, COLOR_KEYS, FIELD_WIDTH_GRADES, GNB_COLORS, GNB_COMMON, GNB_FOLD_MS, GNB_FULL_LOGO_WIDTH, GNB_HEADER, GNB_MENU, GNB_MENU_WIDTH, GNB_RAIL, GNB_RAIL_WIDTH, GNB_SYSTEM_COLORS, GNB_SYSTEM_COLOR_CONFIG, GNB_SYSTEM_LAYOUT, GNB_SYSTEM_PLACEMENTS, GNB_SYSTEM_TOP_COLOR_CONFIG, ICONS, IMAGE_FITS, LAUNCHER_LIST_BOX_LAYOUT, LAUNCHER_LIST_BOX_LOGO_HEIGHT, LAUNCHER_LIST_BOX_LOGO_SERVICE_GAP, LAUNCHER_LIST_BOX_TRAILING_ICON, LAUNCHER_LIST_BOX_WIDTH, LAUNCHER_SERVICES, LAUNCHER_SERVICE_CATALOG, LOGO_DEFAULT_SIZE, LOGO_NAMES, PAGE_BACKGROUNDS, PAGE_CONTENT_HEIGHTS, PAGE_CONTENT_WIDTHS, PAGE_HEADER_VARIANTS, RangeCalendar, SAccountListBox, SActionModal, SBadge, SBarChart, SBarcodeInput, SButton, SCROLL_AREA_AXES, SCalendar, SCalendarBoard, SCallout, SCard, SChatAttachedFile2 as SChatAttachedFile, SChatFile2 as SChatFile, SChatInput2 as SChatInput, SChatMessage2 as SChatMessage, SChatSystemMessage2 as SChatSystemMessage, SCheckbox, SChip2 as SChip, SChipFilter, SChipInput, SCircleProgress, SConfirmModal, SDatePicker, SDatePickerMonthListbox, SDatePickerYearListbox, SDateRangePicker, SDivider, SDonutChart, SDraggableGroup, SDraggableItem2 as SDraggableItem, SDraggableList, SDraggableProvider, SDrawer, SDropdownButton2 as SDropdownButton, SEDITOR_DEFAULT_FONT_SIZE, SEDITOR_HEADING_LABELS, SEDITOR_HEADING_LEVELS, SEditor, SExpansionItem, SExpansionList2 as SExpansionList, SField, SFilePicker, SForm, SGhostButton, SGnb, SGnbSystem, SGnbSystemContext, SGuide, SIcon, SImage, SInput, SKeyValueTable, SLAYOUT_MIN_WIDTH, SLauncherListBox, SLayout, SLayoutContext, SLineChart, SLinearProgress, SList2 as SList, SListItem2 as SListItem, SLoadingContainer, SLoadingModal, SLoadingViewport, SLoginCard2 as SLoginCard, SLogo, SMeatballButton2 as SMeatballButton, SModal, SModalOutlet, SNumberInput, SPage, SPageHeader, SPagination, SPieChart, SPopover, SPopup, SPortal, SRadio, SRadioButton, SRadioCard, SRadioCardGroup, SRadioGroup, SSPLITTER_UNITS, SScrollArea, SSearchInput, SSectionHeaderCard2 as SSectionHeaderCard, SSelect2 as SSelect, SSplitter2 as SSplitter, SStepper, SSwitch, SSystemActionButton, STEPPER_SIZES, STable, STableBar, STabs, STag, STextLink, STextarea, STimePicker, STimeRangePicker, SToast, SToastContainer, SToggle, STooltip2 as STooltip, STree2 as STree, STreeItem2 as STreeItem, SYSTEM_ACTION_BUTTON_COLORS, SYSTEM_ACTION_BUTTON_COLOR_CONFIG, SYSTEM_ACTION_BUTTON_LAYOUT, SYSTEM_ACTION_BUTTON_TYPES, SYSTEM_ACTION_BUTTON_TYPE_CONFIG, TAG_COLORS, TAG_SHAPES, TAG_SIZES, TIMEPICKER_SIZES, TIMEPICKER_SIZE_CONFIG, buttonPreset, cn, fieldWidthValue, fileExtension, findGnbAncestors, findGnbRailValue, formatFileSize, isColorKey, isFieldWidthGrade, loading, normalizeExtension, resolveColor, useSLayout };
26757
26932
  //# sourceMappingURL=index.js.map
26758
26933
  //# sourceMappingURL=index.js.map