sellmate-design-system-react 9.0.0-beta.63 → 9.0.0-beta.65
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/AGENTS.md +31 -5
- package/dist/components/SBarChart/README.md +2 -0
- package/dist/components/SBarChart/SBarChart.d.ts +4 -0
- package/dist/components/SBarChart/barChart.config.d.ts +12 -5
- package/dist/components/SBarcodeInput/README.md +1 -0
- package/dist/components/SBarcodeInput/SBarcodeInput.d.ts +8 -1
- package/dist/components/SCalendarBoard/CalendarDayCard.d.ts +11 -3
- package/dist/components/SCalendarBoard/CalendarEventButton.d.ts +7 -2
- package/dist/components/SCalendarBoard/CalendarMoreButton.d.ts +2 -1
- package/dist/components/SCalendarBoard/README.md +11 -2
- package/dist/components/SCalendarBoard/SCalendarBoard.d.ts +4 -1
- package/dist/components/SCalendarBoard/calendar-board-layout.d.ts +49 -0
- package/dist/components/SCalendarBoard/types.d.ts +10 -1
- package/dist/components/SChipInput/README.md +1 -0
- package/dist/components/SChipInput/SChipInput.d.ts +8 -1
- package/dist/components/SContextAlert/README.md +51 -0
- package/dist/components/SContextAlert/SContextAlert.d.ts +38 -0
- package/dist/components/SContextAlert/contextAlert.config.d.ts +29 -0
- package/dist/components/SContextAlert/index.d.ts +2 -0
- package/dist/components/SDatePicker/README.md +1 -0
- package/dist/components/SDatePicker/SDatePicker.d.ts +9 -2
- package/dist/components/SDateRangePicker/README.md +1 -0
- package/dist/components/SDateRangePicker/SDateRangePicker.d.ts +9 -2
- package/dist/components/SDonutChart/README.md +2 -0
- package/dist/components/SDonutChart/SDonutChart.d.ts +4 -0
- package/dist/components/SEditor/README.md +1 -0
- package/dist/components/SEditor/SEditor.d.ts +8 -1
- package/dist/components/SField/README.md +7 -0
- package/dist/components/SField/SField.d.ts +13 -0
- package/dist/components/SField/index.d.ts +1 -1
- package/dist/components/SFilePicker/README.md +1 -0
- package/dist/components/SFilePicker/SFilePicker.d.ts +9 -2
- package/dist/components/SIcon/README.md +2 -0
- package/dist/components/SInput/README.md +1 -0
- package/dist/components/SInput/SInput.d.ts +3 -1
- package/dist/components/SLineChart/README.md +2 -0
- package/dist/components/SLineChart/SLineChart.d.ts +4 -0
- package/dist/components/SLineChart/lineChart.config.d.ts +42 -33
- package/dist/components/SNumberInput/README.md +1 -0
- package/dist/components/SNumberInput/SNumberInput.d.ts +8 -1
- package/dist/components/SPieChart/README.md +2 -0
- package/dist/components/SPieChart/SPieChart.d.ts +4 -0
- package/dist/components/SSelect/README.md +1 -0
- package/dist/components/SSelect/SSelect.d.ts +8 -1
- package/dist/components/STextarea/README.md +1 -0
- package/dist/components/STextarea/STextarea.d.ts +8 -1
- package/dist/components/STimePicker/README.md +1 -0
- package/dist/components/STimePicker/STimePicker.d.ts +9 -2
- package/dist/components/STimeRangePicker/README.md +1 -0
- package/dist/components/STimeRangePicker/STimeRangePicker.d.ts +9 -2
- package/dist/index.cjs +525 -223
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +521 -224
- package/dist/index.js.map +1 -1
- package/dist/lib/chart/frame.d.ts +5 -1
- package/dist/lib/chart/palette.d.ts +12 -15
- package/dist/lib/chart/radial.d.ts +18 -10
- package/dist/llms-full.txt +120 -8
- package/dist/llms.txt +35 -8
- package/dist/styles.css +170 -18
- package/dist/theme.css +104 -6
- package/eslint/scale.gen.mjs +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -4150,7 +4150,7 @@ function SFooter({
|
|
|
4150
4150
|
{
|
|
4151
4151
|
className: cn(
|
|
4152
4152
|
"relative flex w-full flex-shrink-0 items-center justify-end gap-[var(--cmp-overlay-footer-gap)] overflow-hidden px-[var(--cmp-overlay-footer-paddingX)] py-[var(--cmp-overlay-footer-paddingY)]",
|
|
4153
|
-
isGrey ? "bg-[var(--cmp-overlay-footer-bg-neutral)] border-t border-solid border-[color:var(--sys-color-border-default)]" : "bg-[var(--cmp-overlay-footer-bg-default)] shadow-[var(--
|
|
4153
|
+
isGrey ? "bg-[var(--cmp-overlay-footer-bg-neutral)] border-t border-solid border-[color:var(--sys-color-border-default)]" : "bg-[var(--cmp-overlay-footer-bg-default)] shadow-[var(--cmp-overlay-footer-shadow)]",
|
|
4154
4154
|
className
|
|
4155
4155
|
),
|
|
4156
4156
|
style,
|
|
@@ -4739,6 +4739,7 @@ var SField = /* @__PURE__ */ react.forwardRef(function SField2({
|
|
|
4739
4739
|
iconColor,
|
|
4740
4740
|
labelTooltip = "",
|
|
4741
4741
|
labelTooltipProps,
|
|
4742
|
+
labelPosition = "left",
|
|
4742
4743
|
labelWidth,
|
|
4743
4744
|
labelHeight,
|
|
4744
4745
|
size = "sm",
|
|
@@ -4781,6 +4782,7 @@ var SField = /* @__PURE__ */ react.forwardRef(function SField2({
|
|
|
4781
4782
|
[]
|
|
4782
4783
|
);
|
|
4783
4784
|
const s = FIELD_SIZE[size];
|
|
4785
|
+
const labelOnTop = labelPosition === "top";
|
|
4784
4786
|
if (label !== "" && addonLabel !== "" && typeof console !== "undefined") {
|
|
4785
4787
|
console.warn(
|
|
4786
4788
|
"[SField] label \uACFC addonLabel \uC740 \uD568\uAED8 \uC0AC\uC6A9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. addonLabel \uC744 \uBB34\uC2DC\uD569\uB2C8\uB2E4."
|
|
@@ -4819,103 +4821,120 @@ var SField = /* @__PURE__ */ react.forwardRef(function SField2({
|
|
|
4819
4821
|
style,
|
|
4820
4822
|
onMouseEnter,
|
|
4821
4823
|
onMouseLeave,
|
|
4822
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4823
|
-
|
|
4824
|
-
|
|
4825
|
-
|
|
4826
|
-
|
|
4827
|
-
|
|
4828
|
-
|
|
4829
|
-
|
|
4830
|
-
|
|
4831
|
-
|
|
4832
|
-
|
|
4833
|
-
|
|
4834
|
-
|
|
4835
|
-
|
|
4836
|
-
|
|
4837
|
-
|
|
4838
|
-
|
|
4839
|
-
|
|
4840
|
-
|
|
4841
|
-
|
|
4842
|
-
}
|
|
4843
|
-
),
|
|
4844
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "min-w-0 overflow-hidden text-ellipsis whitespace-nowrap", children: label }),
|
|
4845
|
-
(labelTooltip !== "" || labelTooltipProps) && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0 flex items-center", style: { marginLeft: s.labelGap }, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
4846
|
-
STooltip2,
|
|
4847
|
-
{
|
|
4848
|
-
message: labelTooltip !== "" ? [labelTooltip] : void 0,
|
|
4849
|
-
iconSize: s.icon,
|
|
4850
|
-
...labelTooltipProps
|
|
4851
|
-
}
|
|
4852
|
-
) })
|
|
4853
|
-
]
|
|
4854
|
-
}
|
|
4855
|
-
),
|
|
4856
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
4857
|
-
"div",
|
|
4858
|
-
{
|
|
4859
|
-
className: cn("flex min-w-0 flex-col", !hug && !isPercentWidth && "flex-1"),
|
|
4860
|
-
style: {
|
|
4861
|
-
width: resolvedWidth,
|
|
4862
|
-
minWidth: fieldWidthValue(minWidth),
|
|
4863
|
-
maxWidth: resolvedMaxWidth
|
|
4864
|
-
},
|
|
4865
|
-
children: [
|
|
4866
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
4867
|
-
"div",
|
|
4868
|
-
{
|
|
4869
|
-
className: cn(
|
|
4870
|
-
"relative box-border flex min-w-0 items-stretch border border-solid border-(--field-bc)",
|
|
4871
|
-
// 둘 다 넘친 것을 잘라 내지만 clip 은 스크롤 상자를 만들지 않는다. hidden 이면
|
|
4872
|
-
// 이 상자가 스크롤포트가 되어 안쪽의 position:sticky 가 페이지 스크롤을 따라가지
|
|
4873
|
-
// 못한다 (SEditor 의 고정 툴바). 여러 줄 필드에서만 바꿔 파급을 좁힌다.
|
|
4874
|
-
multiline ? "overflow-clip" : "overflow-hidden",
|
|
4875
|
-
interactive && !borderless && "hover:border-(--sys-color-field-border-focus) hover:shadow-[0px_0px_4px_0px_#0071ff66] focus-within:border-(--sys-color-field-border-focus) focus-within:shadow-[0px_0px_4px_0px_#0071ff66]",
|
|
4876
|
-
disabled && "cursor-not-allowed"
|
|
4877
|
-
),
|
|
4878
|
-
style: {
|
|
4879
|
-
// @ts-expect-error CSS 변수
|
|
4880
|
-
"--field-bc": borderColor,
|
|
4881
|
-
// focused/hovered prop이 명시된 경우 강조를 즉시 반영
|
|
4882
|
-
...interactive && !borderless && (focused || hovered) ? { boxShadow: FOCUS_RING_SHADOW } : {},
|
|
4883
|
-
...multiline ? { minHeight: s.height } : { height: s.height },
|
|
4884
|
-
"borderRadius": s.radius,
|
|
4885
|
-
"background": bgColor,
|
|
4886
|
-
"color": textColor
|
|
4824
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4825
|
+
"div",
|
|
4826
|
+
{
|
|
4827
|
+
className: cn(
|
|
4828
|
+
"flex w-full",
|
|
4829
|
+
labelOnTop ? "flex-col gap-(--sys-space-field-vertical-gap)" : "items-start"
|
|
4830
|
+
),
|
|
4831
|
+
children: [
|
|
4832
|
+
label !== "" && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4833
|
+
"div",
|
|
4834
|
+
{
|
|
4835
|
+
className: "flex shrink-0 items-center font-bold text-(--sys-color-field-text-default)",
|
|
4836
|
+
style: {
|
|
4837
|
+
// 위에 선 라벨은 제 글줄 높이만 차지한다 — 컨트롤 높이에 맞춰 늘리면
|
|
4838
|
+
// 라벨과 컨트롤 사이가 간격 토큰보다 넓어진다. 줄 세우기용 labelWidth 도
|
|
4839
|
+
// 뜻이 없다(아래에 컨트롤이 제 폭으로 선다).
|
|
4840
|
+
...labelOnTop ? {} : {
|
|
4841
|
+
height: cssLen(labelHeight) ?? s.height,
|
|
4842
|
+
marginRight: s.fieldGap,
|
|
4843
|
+
width: cssLen(labelWidth)
|
|
4887
4844
|
},
|
|
4888
|
-
|
|
4889
|
-
|
|
4890
|
-
|
|
4891
|
-
|
|
4892
|
-
|
|
4893
|
-
|
|
4894
|
-
|
|
4895
|
-
|
|
4896
|
-
|
|
4897
|
-
|
|
4898
|
-
|
|
4899
|
-
|
|
4900
|
-
|
|
4901
|
-
|
|
4902
|
-
|
|
4903
|
-
|
|
4904
|
-
|
|
4905
|
-
|
|
4906
|
-
|
|
4907
|
-
|
|
4908
|
-
|
|
4909
|
-
|
|
4910
|
-
|
|
4911
|
-
|
|
4912
|
-
|
|
4913
|
-
|
|
4914
|
-
|
|
4915
|
-
|
|
4916
|
-
|
|
4917
|
-
|
|
4918
|
-
|
|
4845
|
+
fontSize: s.fontSize,
|
|
4846
|
+
lineHeight: `${s.lineHeight}px`
|
|
4847
|
+
},
|
|
4848
|
+
children: [
|
|
4849
|
+
icon && /* @__PURE__ */ jsxRuntime.jsx(
|
|
4850
|
+
SIcon,
|
|
4851
|
+
{
|
|
4852
|
+
name: icon,
|
|
4853
|
+
size: s.icon,
|
|
4854
|
+
color: iconColor,
|
|
4855
|
+
style: { marginRight: s.labelGap }
|
|
4856
|
+
}
|
|
4857
|
+
),
|
|
4858
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "min-w-0 overflow-hidden text-ellipsis whitespace-nowrap", children: label }),
|
|
4859
|
+
(labelTooltip !== "" || labelTooltipProps) && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0 flex items-center", style: { marginLeft: s.labelGap }, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
4860
|
+
STooltip2,
|
|
4861
|
+
{
|
|
4862
|
+
message: labelTooltip !== "" ? [labelTooltip] : void 0,
|
|
4863
|
+
iconSize: s.icon,
|
|
4864
|
+
...labelTooltipProps
|
|
4865
|
+
}
|
|
4866
|
+
) })
|
|
4867
|
+
]
|
|
4868
|
+
}
|
|
4869
|
+
),
|
|
4870
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
4871
|
+
"div",
|
|
4872
|
+
{
|
|
4873
|
+
className: cn(
|
|
4874
|
+
"flex min-w-0 flex-col",
|
|
4875
|
+
!labelOnTop && !hug && !isPercentWidth && "flex-1"
|
|
4876
|
+
),
|
|
4877
|
+
style: {
|
|
4878
|
+
width: resolvedWidth,
|
|
4879
|
+
minWidth: fieldWidthValue(minWidth),
|
|
4880
|
+
maxWidth: resolvedMaxWidth
|
|
4881
|
+
},
|
|
4882
|
+
children: [
|
|
4883
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
4884
|
+
"div",
|
|
4885
|
+
{
|
|
4886
|
+
className: cn(
|
|
4887
|
+
"relative box-border flex min-w-0 items-stretch border border-solid border-(--field-bc)",
|
|
4888
|
+
// 둘 다 넘친 것을 잘라 내지만 clip 은 스크롤 상자를 만들지 않는다. hidden 이면
|
|
4889
|
+
// 이 상자가 스크롤포트가 되어 안쪽의 position:sticky 가 페이지 스크롤을 따라가지
|
|
4890
|
+
// 못한다 (SEditor 의 고정 툴바). 여러 줄 필드에서만 바꿔 파급을 좁힌다.
|
|
4891
|
+
multiline ? "overflow-clip" : "overflow-hidden",
|
|
4892
|
+
interactive && !borderless && "hover:border-(--sys-color-field-border-focus) hover:shadow-[0px_0px_4px_0px_#0071ff66] focus-within:border-(--sys-color-field-border-focus) focus-within:shadow-[0px_0px_4px_0px_#0071ff66]",
|
|
4893
|
+
disabled && "cursor-not-allowed"
|
|
4894
|
+
),
|
|
4895
|
+
style: {
|
|
4896
|
+
// @ts-expect-error CSS 변수
|
|
4897
|
+
"--field-bc": borderColor,
|
|
4898
|
+
// focused/hovered prop이 명시된 경우 강조를 즉시 반영
|
|
4899
|
+
...interactive && !borderless && (focused || hovered) ? { boxShadow: FOCUS_RING_SHADOW } : {},
|
|
4900
|
+
...multiline ? { minHeight: s.height } : { height: s.height },
|
|
4901
|
+
"borderRadius": s.radius,
|
|
4902
|
+
"background": bgColor,
|
|
4903
|
+
"color": textColor
|
|
4904
|
+
},
|
|
4905
|
+
"data-focused": focused || void 0,
|
|
4906
|
+
"data-hovered": hovered || void 0,
|
|
4907
|
+
children: [
|
|
4908
|
+
effectiveAddonLabel !== "" && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4909
|
+
"div",
|
|
4910
|
+
{
|
|
4911
|
+
className: "flex shrink-0 items-center gap-(--cmp-field-addonLabel-gap) whitespace-nowrap border-r border-solid px-(--cmp-field-addonLabel-paddingX) text-12 font-medium leading-sd-20",
|
|
4912
|
+
style: {
|
|
4913
|
+
// 원본 sd-field: labelWidth가 addon 폭(--sd-field-addon-width)에도 적용됨
|
|
4914
|
+
width: cssLen(labelWidth),
|
|
4915
|
+
justifyContent: ALIGN[addonAlign],
|
|
4916
|
+
background: "var(--cmp-field-addonLabel-bg)",
|
|
4917
|
+
borderRightColor: disabled ? "var(--cmp-field-addonLabel-border-disabled)" : "var(--cmp-field-addonLabel-border-default)",
|
|
4918
|
+
borderTopLeftRadius: s.radius - 1,
|
|
4919
|
+
borderBottomLeftRadius: s.radius - 1
|
|
4920
|
+
},
|
|
4921
|
+
children: [
|
|
4922
|
+
icon && !label && /* @__PURE__ */ jsxRuntime.jsx(SIcon, { name: icon, size: s.icon, color: iconColor }),
|
|
4923
|
+
effectiveAddonLabel
|
|
4924
|
+
]
|
|
4925
|
+
}
|
|
4926
|
+
),
|
|
4927
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex min-w-0 flex-1", multiline && "bg-inherit"), children })
|
|
4928
|
+
]
|
|
4929
|
+
}
|
|
4930
|
+
),
|
|
4931
|
+
showError ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-(--cmp-field-contents-gap) px-(--cmp-field-message-paddingX) text-12 font-normal leading-sd-20 text-(--cmp-field-errorMessage-color)", children: errorMessage }) : hint !== "" ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-(--cmp-field-contents-gap) px-(--cmp-field-message-paddingX) text-12 font-normal leading-sd-20 text-(--cmp-field-hint-color)", children: hint }) : null
|
|
4932
|
+
]
|
|
4933
|
+
}
|
|
4934
|
+
)
|
|
4935
|
+
]
|
|
4936
|
+
}
|
|
4937
|
+
)
|
|
4919
4938
|
}
|
|
4920
4939
|
);
|
|
4921
4940
|
});
|
|
@@ -4952,6 +4971,7 @@ var STextarea = /* @__PURE__ */ react.forwardRef(function STextarea2({
|
|
|
4952
4971
|
textareaClassName,
|
|
4953
4972
|
textareaStyle,
|
|
4954
4973
|
label,
|
|
4974
|
+
labelPosition,
|
|
4955
4975
|
labelWidth,
|
|
4956
4976
|
icon,
|
|
4957
4977
|
iconColor,
|
|
@@ -5011,6 +5031,7 @@ var STextarea = /* @__PURE__ */ react.forwardRef(function STextarea2({
|
|
|
5011
5031
|
SField,
|
|
5012
5032
|
{
|
|
5013
5033
|
label,
|
|
5034
|
+
labelPosition,
|
|
5014
5035
|
labelWidth,
|
|
5015
5036
|
icon,
|
|
5016
5037
|
iconColor,
|
|
@@ -6978,7 +6999,7 @@ function TreeConnector({
|
|
|
6978
6999
|
className: cn(
|
|
6979
7000
|
"absolute left-[6px] h-px bg-(--cmp-tree-connector-line-color)",
|
|
6980
7001
|
branchTop,
|
|
6981
|
-
hasChildren ? "w-[14px]" : "w-[calc(14px+var(--cmp-
|
|
7002
|
+
hasChildren ? "w-[14px]" : "w-[calc(14px+var(--cmp-ghostButton-xxs-size))]"
|
|
6982
7003
|
)
|
|
6983
7004
|
}
|
|
6984
7005
|
)
|
|
@@ -7131,7 +7152,12 @@ var STreeItemImpl = /* @__PURE__ */ react.forwardRef(function STreeItem({
|
|
|
7131
7152
|
onToggle?.(node, event);
|
|
7132
7153
|
}
|
|
7133
7154
|
}
|
|
7134
|
-
) :
|
|
7155
|
+
) : (
|
|
7156
|
+
// 자식이 없는 줄은 펼침 버튼 자리를 빈 칸으로 남겨 라벨의 시작점을 맞춘다.
|
|
7157
|
+
// 크기는 자리를 대신하는 그 버튼(`SGhostButton size="xxs"`)의 토큰을 그대로 쓴다 —
|
|
7158
|
+
// 버튼 크기가 바뀌면 빈 칸도 같이 따라가야 줄이 어긋나지 않는다.
|
|
7159
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "size-(--cmp-ghostButton-xxs-size) shrink-0", "aria-hidden": "true" })
|
|
7160
|
+
),
|
|
7135
7161
|
leadingNode,
|
|
7136
7162
|
selectable && /* @__PURE__ */ jsxRuntime.jsx(
|
|
7137
7163
|
"span",
|
|
@@ -8074,6 +8100,96 @@ var SCallout = /* @__PURE__ */ react.forwardRef(function SCallout2({ type = "def
|
|
|
8074
8100
|
}
|
|
8075
8101
|
);
|
|
8076
8102
|
});
|
|
8103
|
+
|
|
8104
|
+
// src/components/SContextAlert/contextAlert.config.ts
|
|
8105
|
+
var CONTEXT_ALERT_INTENTS = [
|
|
8106
|
+
"default",
|
|
8107
|
+
"danger",
|
|
8108
|
+
"warning",
|
|
8109
|
+
"success",
|
|
8110
|
+
"accent",
|
|
8111
|
+
"discovery"
|
|
8112
|
+
];
|
|
8113
|
+
var CONTEXT_ALERT_SURFACE = {
|
|
8114
|
+
default: {
|
|
8115
|
+
bg: "var(--cmp-contextAlert-default-bg)",
|
|
8116
|
+
border: "var(--cmp-contextAlert-default-border)"
|
|
8117
|
+
},
|
|
8118
|
+
danger: {
|
|
8119
|
+
bg: "var(--cmp-contextAlert-danger-bg)",
|
|
8120
|
+
border: "var(--cmp-contextAlert-danger-border)"
|
|
8121
|
+
},
|
|
8122
|
+
warning: {
|
|
8123
|
+
bg: "var(--cmp-contextAlert-warning-bg)",
|
|
8124
|
+
border: "var(--cmp-contextAlert-warning-border)"
|
|
8125
|
+
},
|
|
8126
|
+
success: {
|
|
8127
|
+
bg: "var(--cmp-contextAlert-success-bg)",
|
|
8128
|
+
border: "var(--cmp-contextAlert-success-border)"
|
|
8129
|
+
},
|
|
8130
|
+
accent: {
|
|
8131
|
+
bg: "var(--cmp-contextAlert-accent-bg)",
|
|
8132
|
+
border: "var(--cmp-contextAlert-accent-border)"
|
|
8133
|
+
},
|
|
8134
|
+
discovery: {
|
|
8135
|
+
bg: "var(--cmp-contextAlert-discovery-bg)",
|
|
8136
|
+
border: "var(--cmp-contextAlert-discovery-border)"
|
|
8137
|
+
}
|
|
8138
|
+
};
|
|
8139
|
+
var CONTEXT_ALERT_DEFAULT_ICON = "notificationOutline";
|
|
8140
|
+
var CONTEXT_ALERT_ICON_COLOR = "var(--sys-color-fg-tertiary)";
|
|
8141
|
+
var SContextAlert = /* @__PURE__ */ react.forwardRef(function SContextAlert2({
|
|
8142
|
+
intent = "default",
|
|
8143
|
+
messages = [],
|
|
8144
|
+
icon = CONTEXT_ALERT_DEFAULT_ICON,
|
|
8145
|
+
action: action2,
|
|
8146
|
+
className,
|
|
8147
|
+
style
|
|
8148
|
+
}, ref) {
|
|
8149
|
+
const surface = CONTEXT_ALERT_SURFACE[intent];
|
|
8150
|
+
const vars = {
|
|
8151
|
+
"--ca-bg": surface.bg,
|
|
8152
|
+
"--ca-border": surface.border
|
|
8153
|
+
};
|
|
8154
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8155
|
+
"div",
|
|
8156
|
+
{
|
|
8157
|
+
ref,
|
|
8158
|
+
role: "note",
|
|
8159
|
+
className: cn(
|
|
8160
|
+
"flex w-full items-center gap-[var(--cmp-contextAlert-gap)]",
|
|
8161
|
+
"rounded-[var(--cmp-contextAlert-radius)] border-[length:var(--cmp-contextAlert-border-width)] border-solid",
|
|
8162
|
+
"px-[var(--cmp-contextAlert-paddingX)] py-[var(--cmp-contextAlert-paddingY)]",
|
|
8163
|
+
"border-[color:var(--ca-border)] bg-[var(--ca-bg)]",
|
|
8164
|
+
className
|
|
8165
|
+
),
|
|
8166
|
+
style: { ...vars, ...style },
|
|
8167
|
+
children: [
|
|
8168
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8169
|
+
SIcon,
|
|
8170
|
+
{
|
|
8171
|
+
name: icon,
|
|
8172
|
+
size: "var(--cmp-contextAlert-icon)",
|
|
8173
|
+
color: CONTEXT_ALERT_ICON_COLOR,
|
|
8174
|
+
className: "shrink-0"
|
|
8175
|
+
}
|
|
8176
|
+
),
|
|
8177
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex min-w-0 flex-1 flex-col text-[12px] font-normal leading-[20px] text-[color:var(--cmp-contextAlert-content)]", children: messages.map((m, i) => (
|
|
8178
|
+
// 메시지는 HTML 문자열을 허용하되, sanitizeInlineHtml 로 살균 후 innerHTML 렌더 (XSS 방어)
|
|
8179
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8180
|
+
"p",
|
|
8181
|
+
{
|
|
8182
|
+
className: "m-0 break-keep break-words text-pretty",
|
|
8183
|
+
dangerouslySetInnerHTML: { __html: sanitizeInlineHtml(m) }
|
|
8184
|
+
},
|
|
8185
|
+
`${i}-${m}`
|
|
8186
|
+
)
|
|
8187
|
+
)) }),
|
|
8188
|
+
action2 != null && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex shrink-0 items-center", children: action2 })
|
|
8189
|
+
]
|
|
8190
|
+
}
|
|
8191
|
+
);
|
|
8192
|
+
});
|
|
8077
8193
|
var FILL_COLOR = {
|
|
8078
8194
|
primary: "var(--cmp-progress-color-active)",
|
|
8079
8195
|
error: "var(--cmp-progress-color-error)",
|
|
@@ -10072,7 +10188,7 @@ function SConfirmModal({
|
|
|
10072
10188
|
}
|
|
10073
10189
|
)
|
|
10074
10190
|
] }),
|
|
10075
|
-
hasBody && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[20px] text-center text-[
|
|
10191
|
+
hasBody && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "typo-feedback-md-regular flex w-full flex-col items-center gap-[20px] text-center text-[color:var(--cmp-modal-confirm-message-color)]", children: [
|
|
10076
10192
|
topMessage.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col gap-[2px]", children: topMessage.map((m, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10077
10193
|
"p",
|
|
10078
10194
|
{
|
|
@@ -10258,7 +10374,7 @@ function SLoadingModal({
|
|
|
10258
10374
|
lines.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col gap-[2px]", children: lines.map((m, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10259
10375
|
"p",
|
|
10260
10376
|
{
|
|
10261
|
-
className: "m-0 max-w-[400px] break-keep text-center text-[
|
|
10377
|
+
className: "typo-feedback-md-regular m-0 max-w-[400px] break-keep text-center text-[color:var(--cmp-modal-loading-message-color)]",
|
|
10262
10378
|
children: m
|
|
10263
10379
|
},
|
|
10264
10380
|
i
|
|
@@ -12013,7 +12129,7 @@ var SGnb = /* @__PURE__ */ react.forwardRef(function SGnb2({
|
|
|
12013
12129
|
viewportPadding: 8,
|
|
12014
12130
|
ariaLabel: GNB_LAUNCHER_LABEL,
|
|
12015
12131
|
onOpenAutoFocus: (event) => event.preventDefault(),
|
|
12016
|
-
className: "w-auto rounded-(--cmp-gnb-launcher-listBox-radius) bg-(--cmp-gnb-launcher-listBox-bg) shadow-
|
|
12132
|
+
className: "w-auto rounded-(--cmp-gnb-launcher-listBox-radius) bg-(--cmp-gnb-launcher-listBox-bg) shadow-(--cmp-gnb-launcher-listBox-shadow)",
|
|
12017
12133
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
12018
12134
|
SLauncherListBox,
|
|
12019
12135
|
{
|
|
@@ -13717,6 +13833,98 @@ function monthCells(year, month) {
|
|
|
13717
13833
|
}
|
|
13718
13834
|
var WEEK_LABELS = ["\uC77C", "\uC6D4", "\uD654", "\uC218", "\uBAA9", "\uAE08", "\uD1A0"];
|
|
13719
13835
|
|
|
13836
|
+
// src/components/SCalendarBoard/calendar-board-layout.ts
|
|
13837
|
+
function eventEndDate(event) {
|
|
13838
|
+
const end = event.endDate;
|
|
13839
|
+
return end != null && end > event.date ? end : event.date;
|
|
13840
|
+
}
|
|
13841
|
+
function layoutCalendarBoard({
|
|
13842
|
+
cells,
|
|
13843
|
+
events,
|
|
13844
|
+
rowCapacity,
|
|
13845
|
+
blockedDates
|
|
13846
|
+
}) {
|
|
13847
|
+
const count = cells.length;
|
|
13848
|
+
const weekCount = Math.ceil(count / 7);
|
|
13849
|
+
const segmentsByCell = Array.from({ length: count }, () => []);
|
|
13850
|
+
const eventsByCell = Array.from({ length: count }, () => []);
|
|
13851
|
+
const hiddenCountByCell = new Array(count).fill(0);
|
|
13852
|
+
const moreLaneByWeek = new Array(weekCount).fill(-1);
|
|
13853
|
+
const runs = [];
|
|
13854
|
+
events.forEach((event, order) => {
|
|
13855
|
+
const start = event.date;
|
|
13856
|
+
const end = eventEndDate(event);
|
|
13857
|
+
let from = -1;
|
|
13858
|
+
let to = -1;
|
|
13859
|
+
for (let i = 0; i < count; i++) {
|
|
13860
|
+
const { date } = cells[i];
|
|
13861
|
+
if (date < start || date > end) continue;
|
|
13862
|
+
if (from < 0) from = i;
|
|
13863
|
+
to = i;
|
|
13864
|
+
if (!blockedDates.has(date)) eventsByCell[i].push(event);
|
|
13865
|
+
}
|
|
13866
|
+
if (from < 0) return;
|
|
13867
|
+
let runStart = -1;
|
|
13868
|
+
const flush = (endIndex) => {
|
|
13869
|
+
if (runStart < 0) return;
|
|
13870
|
+
runs.push({ event, order, startIndex: runStart, endIndex, lane: -1 });
|
|
13871
|
+
runStart = -1;
|
|
13872
|
+
};
|
|
13873
|
+
for (let i = from; i <= to; i++) {
|
|
13874
|
+
if (blockedDates.has(cells[i].date)) {
|
|
13875
|
+
flush(i - 1);
|
|
13876
|
+
continue;
|
|
13877
|
+
}
|
|
13878
|
+
if (runStart >= 0 && i % 7 === 0) flush(i - 1);
|
|
13879
|
+
if (runStart < 0) runStart = i;
|
|
13880
|
+
}
|
|
13881
|
+
flush(to);
|
|
13882
|
+
});
|
|
13883
|
+
runs.sort(
|
|
13884
|
+
(a, b) => a.startIndex - b.startIndex || b.endIndex - b.startIndex - (a.endIndex - a.startIndex) || a.order - b.order
|
|
13885
|
+
);
|
|
13886
|
+
const weekLanes = Array.from({ length: weekCount }, () => []);
|
|
13887
|
+
for (const run of runs) {
|
|
13888
|
+
const week = Math.floor(run.startIndex / 7);
|
|
13889
|
+
const fromDay = run.startIndex % 7;
|
|
13890
|
+
const toDay = run.endIndex % 7;
|
|
13891
|
+
const lanes = weekLanes[week];
|
|
13892
|
+
let lane = 0;
|
|
13893
|
+
for (; ; ) {
|
|
13894
|
+
if (lanes[lane] == null) lanes[lane] = new Array(7).fill(false);
|
|
13895
|
+
let free = true;
|
|
13896
|
+
for (let d = fromDay; d <= toDay && free; d++) if (lanes[lane][d]) free = false;
|
|
13897
|
+
if (free) break;
|
|
13898
|
+
lane += 1;
|
|
13899
|
+
}
|
|
13900
|
+
for (let d = fromDay; d <= toDay; d++) lanes[lane][d] = true;
|
|
13901
|
+
run.lane = lane;
|
|
13902
|
+
}
|
|
13903
|
+
for (let week = 0; week < weekCount; week++) {
|
|
13904
|
+
if (weekLanes[week].length > rowCapacity) moreLaneByWeek[week] = rowCapacity - 1;
|
|
13905
|
+
}
|
|
13906
|
+
for (const run of runs) {
|
|
13907
|
+
const week = Math.floor(run.startIndex / 7);
|
|
13908
|
+
const moreLane = moreLaneByWeek[week];
|
|
13909
|
+
const limit = moreLane < 0 ? rowCapacity : moreLane;
|
|
13910
|
+
if (run.lane >= limit) {
|
|
13911
|
+
for (let i = run.startIndex; i <= run.endIndex; i++) hiddenCountByCell[i] += 1;
|
|
13912
|
+
continue;
|
|
13913
|
+
}
|
|
13914
|
+
const { event } = run;
|
|
13915
|
+
segmentsByCell[run.startIndex].push({
|
|
13916
|
+
event,
|
|
13917
|
+
key: `${event.id ?? `${event.date}-${run.order}`}-${run.startIndex}`,
|
|
13918
|
+
startIndex: run.startIndex,
|
|
13919
|
+
span: run.endIndex - run.startIndex + 1,
|
|
13920
|
+
lane: run.lane,
|
|
13921
|
+
startsHere: cells[run.startIndex].date === event.date,
|
|
13922
|
+
endsHere: cells[run.endIndex].date === eventEndDate(event)
|
|
13923
|
+
});
|
|
13924
|
+
}
|
|
13925
|
+
return { segmentsByCell, eventsByCell, hiddenCountByCell, moreLaneByWeek };
|
|
13926
|
+
}
|
|
13927
|
+
|
|
13720
13928
|
// src/components/SCalendarBoard/calendarBoard.config.ts
|
|
13721
13929
|
var CALENDAR_BOARD_EVENT_COLORS = [
|
|
13722
13930
|
"default",
|
|
@@ -13761,7 +13969,10 @@ var CALENDAR_BOARD_DAY_BG = {
|
|
|
13761
13969
|
function CalendarEventButton({
|
|
13762
13970
|
event,
|
|
13763
13971
|
onSelect,
|
|
13764
|
-
|
|
13972
|
+
flatStart = false,
|
|
13973
|
+
flatEnd = false,
|
|
13974
|
+
className,
|
|
13975
|
+
style
|
|
13765
13976
|
}) {
|
|
13766
13977
|
const preset = CALENDAR_BOARD_EVENT_PRESETS[event.color ?? "default"];
|
|
13767
13978
|
const dot = event.dotColor ?? preset.dot;
|
|
@@ -13781,10 +13992,13 @@ function CalendarEventButton({
|
|
|
13781
13992
|
"h-(--cmp-calendarBoard-item-height) shrink-0 rounded-(--cmp-calendarBoard-item-radius)",
|
|
13782
13993
|
"gap-(--cmp-calendarBoard-eventButton-inline-gap) px-(--cmp-calendarBoard-item-paddingX)",
|
|
13783
13994
|
"bg-(--ceb-bg) text-(--cmp-calendarBoard-eventButton-text-color-default)",
|
|
13995
|
+
// 잘린 쪽은 평평하게 — 다음 조각과 이어 보면 한 막대가 주 경계에서 나뉜 모양이 된다.
|
|
13996
|
+
flatStart && "rounded-s-none",
|
|
13997
|
+
flatEnd && "rounded-e-none",
|
|
13784
13998
|
disabled ? "cursor-not-allowed opacity-50" : "cursor-pointer",
|
|
13785
13999
|
className
|
|
13786
14000
|
),
|
|
13787
|
-
style: { "--ceb-bg": preset.bg },
|
|
14001
|
+
style: { ...style, "--ceb-bg": preset.bg },
|
|
13788
14002
|
onClick: (e) => {
|
|
13789
14003
|
if (disabled) return;
|
|
13790
14004
|
onSelect?.(event, e);
|
|
@@ -13794,7 +14008,7 @@ function CalendarEventButton({
|
|
|
13794
14008
|
"span",
|
|
13795
14009
|
{
|
|
13796
14010
|
"aria-hidden": true,
|
|
13797
|
-
className: "pointer-events-none absolute inset-0 rounded-
|
|
14011
|
+
className: "pointer-events-none absolute inset-0 rounded-[inherit] bg-(--cmp-calendarBoard-eventButton-hover-overlay-color) opacity-0 transition-opacity group-hover:opacity-(--cmp-calendarBoard-eventButton-hover-overlay-opacity)"
|
|
13798
14012
|
}
|
|
13799
14013
|
),
|
|
13800
14014
|
/* @__PURE__ */ jsxRuntime.jsx(SBadge, { "aria-hidden": true, color: dot, className: "shrink-0" }),
|
|
@@ -13828,7 +14042,7 @@ function CalendarEventButton({
|
|
|
13828
14042
|
}
|
|
13829
14043
|
);
|
|
13830
14044
|
}
|
|
13831
|
-
var CalendarMoreButton = /* @__PURE__ */ react.forwardRef(function CalendarMoreButton2({ count, label = "\uB354\uBCF4\uAE30", onClick, className }, ref) {
|
|
14045
|
+
var CalendarMoreButton = /* @__PURE__ */ react.forwardRef(function CalendarMoreButton2({ count, label = "\uB354\uBCF4\uAE30", onClick, className, style }, ref) {
|
|
13832
14046
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
13833
14047
|
"button",
|
|
13834
14048
|
{
|
|
@@ -13841,6 +14055,7 @@ var CalendarMoreButton = /* @__PURE__ */ react.forwardRef(function CalendarMoreB
|
|
|
13841
14055
|
"bg-(--cmp-calendarBoard-moreButton-bg)",
|
|
13842
14056
|
className
|
|
13843
14057
|
),
|
|
14058
|
+
style,
|
|
13844
14059
|
onClick,
|
|
13845
14060
|
children: [
|
|
13846
14061
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -13859,6 +14074,9 @@ var CalendarMoreButton = /* @__PURE__ */ react.forwardRef(function CalendarMoreB
|
|
|
13859
14074
|
}
|
|
13860
14075
|
);
|
|
13861
14076
|
});
|
|
14077
|
+
var HEADER_HEIGHT = "var(--cmp-calendarBoard-dayCard-header-paddingTop) + var(--cmp-calendarBoard-daySequence-size) + var(--cmp-calendarBoard-dayCard-header-paddingBottom)";
|
|
14078
|
+
var laneTop = (lane) => `calc(${HEADER_HEIGHT} + ${lane} * (var(--cmp-calendarBoard-item-height) + var(--cmp-calendarBoard-dayCard-grid-gap)))`;
|
|
14079
|
+
var spanWidth = (span) => `calc(${span} * 100% + ${span - 1}px - 2 * var(--cmp-calendarBoard-dayCard-paddingX))`;
|
|
13862
14080
|
var CalendarDayCard = /* @__PURE__ */ react.forwardRef(function CalendarDayCard2({
|
|
13863
14081
|
date,
|
|
13864
14082
|
day,
|
|
@@ -13867,9 +14085,11 @@ var CalendarDayCard = /* @__PURE__ */ react.forwardRef(function CalendarDayCard2
|
|
|
13867
14085
|
isSelected,
|
|
13868
14086
|
selectable,
|
|
13869
14087
|
color,
|
|
13870
|
-
|
|
14088
|
+
segments,
|
|
14089
|
+
dayEventCount,
|
|
13871
14090
|
body,
|
|
13872
14091
|
hiddenCount,
|
|
14092
|
+
moreLane,
|
|
13873
14093
|
isOpen,
|
|
13874
14094
|
moreLabel,
|
|
13875
14095
|
onDaySelect,
|
|
@@ -13877,7 +14097,7 @@ var CalendarDayCard = /* @__PURE__ */ react.forwardRef(function CalendarDayCard2
|
|
|
13877
14097
|
onOpenEvents,
|
|
13878
14098
|
...rest
|
|
13879
14099
|
}, ref) {
|
|
13880
|
-
const hasEvents =
|
|
14100
|
+
const hasEvents = dayEventCount > 0;
|
|
13881
14101
|
const interactive = selectable || hasEvents;
|
|
13882
14102
|
const activate = () => {
|
|
13883
14103
|
if (hasEvents) onOpenEvents?.();
|
|
@@ -13912,7 +14132,7 @@ var CalendarDayCard = /* @__PURE__ */ react.forwardRef(function CalendarDayCard2
|
|
|
13912
14132
|
"span",
|
|
13913
14133
|
{
|
|
13914
14134
|
"aria-hidden": true,
|
|
13915
|
-
className: "pointer-events-none absolute inset-[1px] rounded-(--cmp-calendarBoard-dayCard-focus-border-radius) border-(length:--cmp-calendarBoard-dayCard-focus-border-width) border-solid border-(--cmp-calendarBoard-dayCard-focus-border-color)"
|
|
14135
|
+
className: "pointer-events-none absolute inset-[1px] z-20 rounded-(--cmp-calendarBoard-dayCard-focus-border-radius) border-(length:--cmp-calendarBoard-dayCard-focus-border-width) border-solid border-(--cmp-calendarBoard-dayCard-focus-border-color)"
|
|
13916
14136
|
}
|
|
13917
14137
|
),
|
|
13918
14138
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex shrink-0 pt-(--cmp-calendarBoard-dayCard-header-paddingTop) pb-(--cmp-calendarBoard-dayCard-header-paddingBottom)", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -13931,39 +14151,41 @@ var CalendarDayCard = /* @__PURE__ */ react.forwardRef(function CalendarDayCard2
|
|
|
13931
14151
|
children: day
|
|
13932
14152
|
}
|
|
13933
14153
|
) }),
|
|
13934
|
-
/* @__PURE__ */ jsxRuntime.
|
|
13935
|
-
|
|
14154
|
+
body != null && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex min-h-0 flex-1 flex-col pb-(--cmp-calendarBoard-dayCard-grid-paddingBottom)", children: body }),
|
|
14155
|
+
body == null && segments.map((segment) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
14156
|
+
CalendarEventButton,
|
|
13936
14157
|
{
|
|
13937
|
-
|
|
13938
|
-
|
|
13939
|
-
|
|
13940
|
-
|
|
13941
|
-
|
|
13942
|
-
|
|
13943
|
-
|
|
13944
|
-
|
|
13945
|
-
|
|
13946
|
-
|
|
13947
|
-
|
|
13948
|
-
|
|
13949
|
-
|
|
13950
|
-
|
|
13951
|
-
|
|
13952
|
-
|
|
13953
|
-
|
|
13954
|
-
|
|
13955
|
-
|
|
13956
|
-
|
|
13957
|
-
|
|
13958
|
-
|
|
13959
|
-
|
|
13960
|
-
|
|
13961
|
-
|
|
13962
|
-
|
|
13963
|
-
|
|
13964
|
-
|
|
13965
|
-
)
|
|
13966
|
-
|
|
14158
|
+
event: segment.event,
|
|
14159
|
+
flatStart: !segment.startsHere,
|
|
14160
|
+
flatEnd: !segment.endsHere,
|
|
14161
|
+
className: "absolute z-10",
|
|
14162
|
+
style: {
|
|
14163
|
+
top: laneTop(segment.lane),
|
|
14164
|
+
left: "var(--cmp-calendarBoard-dayCard-paddingX)",
|
|
14165
|
+
width: spanWidth(segment.span)
|
|
14166
|
+
},
|
|
14167
|
+
onSelect: (ev, e) => {
|
|
14168
|
+
e.stopPropagation();
|
|
14169
|
+
onEventClick?.(ev, e);
|
|
14170
|
+
}
|
|
14171
|
+
},
|
|
14172
|
+
segment.key
|
|
14173
|
+
)),
|
|
14174
|
+
body == null && hiddenCount > 0 && moreLane >= 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
14175
|
+
CalendarMoreButton,
|
|
14176
|
+
{
|
|
14177
|
+
count: hiddenCount,
|
|
14178
|
+
label: moreLabel,
|
|
14179
|
+
className: "absolute z-10",
|
|
14180
|
+
style: {
|
|
14181
|
+
top: laneTop(moreLane),
|
|
14182
|
+
left: "var(--cmp-calendarBoard-dayCard-paddingX)",
|
|
14183
|
+
width: spanWidth(1)
|
|
14184
|
+
},
|
|
14185
|
+
onClick: (e) => {
|
|
14186
|
+
e.stopPropagation();
|
|
14187
|
+
onOpenEvents?.();
|
|
14188
|
+
}
|
|
13967
14189
|
}
|
|
13968
14190
|
)
|
|
13969
14191
|
]
|
|
@@ -14097,16 +14319,14 @@ function SCalendarBoard({
|
|
|
14097
14319
|
observer.observe(cell);
|
|
14098
14320
|
return () => observer.disconnect();
|
|
14099
14321
|
}, [rowCount]);
|
|
14100
|
-
const
|
|
14101
|
-
const
|
|
14102
|
-
|
|
14103
|
-
|
|
14104
|
-
|
|
14105
|
-
|
|
14106
|
-
|
|
14107
|
-
|
|
14108
|
-
}, [events]);
|
|
14109
|
-
const openEvents = openDate ? eventMap.get(openDate) ?? [] : [];
|
|
14322
|
+
const layout = react.useMemo(() => {
|
|
14323
|
+
const blockedDates = new Set(
|
|
14324
|
+
cells.filter((cell) => dayContent?.[cell.date] != null).map((cell) => cell.date)
|
|
14325
|
+
);
|
|
14326
|
+
return layoutCalendarBoard({ cells, events: events ?? [], rowCapacity, blockedDates });
|
|
14327
|
+
}, [cells, events, rowCapacity, dayContent]);
|
|
14328
|
+
const openIndex = openDate == null ? -1 : cells.findIndex((cell) => cell.date === openDate);
|
|
14329
|
+
const openEvents = openIndex < 0 ? [] : layout.eventsByCell[openIndex];
|
|
14110
14330
|
react.useLayoutEffect(() => {
|
|
14111
14331
|
if (openDate == null || panelEl == null) return;
|
|
14112
14332
|
const cell = gridRef.current?.querySelector(`[data-date="${openDate}"]`);
|
|
@@ -14247,11 +14467,9 @@ function SCalendarBoard({
|
|
|
14247
14467
|
// 행은 판 높이를 균등하게 나눠 갖는다 — 일정이 많은 주만 길어지면 격자가 깨진다.
|
|
14248
14468
|
gridTemplateRows: `repeat(${rowCount}, minmax(var(--cmp-calendarBoard-dayCard-minHeight), 1fr))`
|
|
14249
14469
|
},
|
|
14250
|
-
children: cells.map((cell) => {
|
|
14470
|
+
children: cells.map((cell, index) => {
|
|
14251
14471
|
const content = dayContent?.[cell.date];
|
|
14252
|
-
const list =
|
|
14253
|
-
const folded = list.length > rowCapacity;
|
|
14254
|
-
const visible = folded ? list.slice(0, rowCapacity - 1) : list;
|
|
14472
|
+
const list = layout.eventsByCell[index];
|
|
14255
14473
|
const card = /* @__PURE__ */ jsxRuntime.jsx(
|
|
14256
14474
|
CalendarDayCard,
|
|
14257
14475
|
{
|
|
@@ -14262,9 +14480,11 @@ function SCalendarBoard({
|
|
|
14262
14480
|
isSelected: value != null && value === cell.date,
|
|
14263
14481
|
selectable,
|
|
14264
14482
|
color: dayColors?.[cell.date] ?? "default",
|
|
14265
|
-
|
|
14483
|
+
segments: layout.segmentsByCell[index],
|
|
14484
|
+
dayEventCount: list.length,
|
|
14266
14485
|
body: content,
|
|
14267
|
-
hiddenCount:
|
|
14486
|
+
hiddenCount: layout.hiddenCountByCell[index],
|
|
14487
|
+
moreLane: layout.moreLaneByWeek[Math.floor(index / 7)],
|
|
14268
14488
|
isOpen: openDate === cell.date,
|
|
14269
14489
|
moreLabel,
|
|
14270
14490
|
onDaySelect: (date) => onValueChange?.(date, list),
|
|
@@ -14657,6 +14877,7 @@ var SSelectImpl = /* @__PURE__ */ react.forwardRef(function SSelect({
|
|
|
14657
14877
|
onSearchChange,
|
|
14658
14878
|
searchDebounce = DEFAULT_SEARCH_DEBOUNCE,
|
|
14659
14879
|
label,
|
|
14880
|
+
labelPosition,
|
|
14660
14881
|
labelWidth,
|
|
14661
14882
|
icon,
|
|
14662
14883
|
iconColor,
|
|
@@ -15089,6 +15310,7 @@ var SSelectImpl = /* @__PURE__ */ react.forwardRef(function SSelect({
|
|
|
15089
15310
|
SField,
|
|
15090
15311
|
{
|
|
15091
15312
|
label,
|
|
15313
|
+
labelPosition,
|
|
15092
15314
|
labelWidth,
|
|
15093
15315
|
icon,
|
|
15094
15316
|
iconColor,
|
|
@@ -16819,6 +17041,7 @@ var SInput = /* @__PURE__ */ react.forwardRef(function SInput2({
|
|
|
16819
17041
|
inputClassName,
|
|
16820
17042
|
inputStyle,
|
|
16821
17043
|
label,
|
|
17044
|
+
labelPosition,
|
|
16822
17045
|
labelWidth,
|
|
16823
17046
|
labelTooltip,
|
|
16824
17047
|
labelTooltipProps,
|
|
@@ -16862,6 +17085,7 @@ var SInput = /* @__PURE__ */ react.forwardRef(function SInput2({
|
|
|
16862
17085
|
SField,
|
|
16863
17086
|
{
|
|
16864
17087
|
label,
|
|
17088
|
+
labelPosition,
|
|
16865
17089
|
labelWidth,
|
|
16866
17090
|
labelTooltip,
|
|
16867
17091
|
labelTooltipProps,
|
|
@@ -17052,6 +17276,7 @@ var SNumberInput = /* @__PURE__ */ react.forwardRef(function SNumberInput2({
|
|
|
17052
17276
|
focused,
|
|
17053
17277
|
hovered,
|
|
17054
17278
|
label,
|
|
17279
|
+
labelPosition,
|
|
17055
17280
|
labelWidth,
|
|
17056
17281
|
icon,
|
|
17057
17282
|
iconColor,
|
|
@@ -17221,6 +17446,7 @@ var SNumberInput = /* @__PURE__ */ react.forwardRef(function SNumberInput2({
|
|
|
17221
17446
|
SField,
|
|
17222
17447
|
{
|
|
17223
17448
|
label,
|
|
17449
|
+
labelPosition,
|
|
17224
17450
|
labelWidth,
|
|
17225
17451
|
icon,
|
|
17226
17452
|
iconColor,
|
|
@@ -17508,7 +17734,7 @@ function SCalendar({
|
|
|
17508
17734
|
if (e !== "" && date > e) return true;
|
|
17509
17735
|
return false;
|
|
17510
17736
|
};
|
|
17511
|
-
const
|
|
17737
|
+
const pick2 = (date) => {
|
|
17512
17738
|
if (!isDisabled(date)) onValueChange?.(date);
|
|
17513
17739
|
};
|
|
17514
17740
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -17593,7 +17819,7 @@ function SCalendar({
|
|
|
17593
17819
|
{
|
|
17594
17820
|
type: "button",
|
|
17595
17821
|
disabled: !cell.inCurrentMonth || disabled,
|
|
17596
|
-
onClick: () => cell.inCurrentMonth &&
|
|
17822
|
+
onClick: () => cell.inCurrentMonth && pick2(cell.date),
|
|
17597
17823
|
className: cn(
|
|
17598
17824
|
"flex min-h-[var(--cmp-datepicker-calendar-day-circle-size)] w-[var(--cmp-datepicker-calendar-day-width)] flex-col items-center justify-start border-none bg-transparent p-0",
|
|
17599
17825
|
!cell.inCurrentMonth ? "invisible pointer-events-none" : disabled ? "cursor-not-allowed" : "cursor-pointer"
|
|
@@ -17939,6 +18165,7 @@ function SDatePicker({
|
|
|
17939
18165
|
rules,
|
|
17940
18166
|
status,
|
|
17941
18167
|
label,
|
|
18168
|
+
labelPosition,
|
|
17942
18169
|
labelWidth,
|
|
17943
18170
|
icon,
|
|
17944
18171
|
iconColor,
|
|
@@ -18011,6 +18238,7 @@ function SDatePicker({
|
|
|
18011
18238
|
SField,
|
|
18012
18239
|
{
|
|
18013
18240
|
label,
|
|
18241
|
+
labelPosition,
|
|
18014
18242
|
labelWidth,
|
|
18015
18243
|
icon,
|
|
18016
18244
|
iconColor,
|
|
@@ -18473,6 +18701,7 @@ function SDateRangePicker({
|
|
|
18473
18701
|
rules,
|
|
18474
18702
|
status,
|
|
18475
18703
|
label,
|
|
18704
|
+
labelPosition,
|
|
18476
18705
|
labelWidth,
|
|
18477
18706
|
icon,
|
|
18478
18707
|
iconColor,
|
|
@@ -18545,6 +18774,7 @@ function SDateRangePicker({
|
|
|
18545
18774
|
SField,
|
|
18546
18775
|
{
|
|
18547
18776
|
label,
|
|
18777
|
+
labelPosition,
|
|
18548
18778
|
labelWidth,
|
|
18549
18779
|
icon,
|
|
18550
18780
|
iconColor,
|
|
@@ -18849,6 +19079,7 @@ function SFilePicker({
|
|
|
18849
19079
|
status,
|
|
18850
19080
|
size = "sm",
|
|
18851
19081
|
label,
|
|
19082
|
+
labelPosition,
|
|
18852
19083
|
labelWidth,
|
|
18853
19084
|
icon,
|
|
18854
19085
|
iconColor,
|
|
@@ -19033,6 +19264,7 @@ function SFilePicker({
|
|
|
19033
19264
|
{
|
|
19034
19265
|
borderless: inline,
|
|
19035
19266
|
label,
|
|
19267
|
+
labelPosition,
|
|
19036
19268
|
labelWidth,
|
|
19037
19269
|
icon,
|
|
19038
19270
|
iconColor,
|
|
@@ -19298,7 +19530,7 @@ function ChartGrid({ scale, direction, width, height }) {
|
|
|
19298
19530
|
return /* @__PURE__ */ jsxRuntime.jsx("g", { "aria-hidden": true, children: scale.ticks.map((tick) => {
|
|
19299
19531
|
const ratio = ratioOf(tick, scale);
|
|
19300
19532
|
const isBaseline = tick === 0;
|
|
19301
|
-
const color = isBaseline ? "var(--cmp-chart-baseline-color)" : "var(--cmp-chart-
|
|
19533
|
+
const color = isBaseline ? "var(--cmp-chart-baseline-color)" : "var(--cmp-chart-gridline-color)";
|
|
19302
19534
|
const position = vertical ? height - ratio * height : ratio * width;
|
|
19303
19535
|
const extent = vertical ? height : width;
|
|
19304
19536
|
const snapped = Math.min(Math.max(Math.round(position), 0), Math.max(0, extent - 1)) + 0.5;
|
|
@@ -19376,7 +19608,7 @@ function ChartAxisLabels({
|
|
|
19376
19608
|
}
|
|
19377
19609
|
);
|
|
19378
19610
|
}
|
|
19379
|
-
var ChartFrame = /* @__PURE__ */ react.forwardRef(function ChartFrame2({ legend, legendPosition = "top", children, className, style, ...props }, ref) {
|
|
19611
|
+
var ChartFrame = /* @__PURE__ */ react.forwardRef(function ChartFrame2({ title, unit, legend, legendPosition = "top", children, className, style, ...props }, ref) {
|
|
19380
19612
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
19381
19613
|
"div",
|
|
19382
19614
|
{
|
|
@@ -19389,6 +19621,14 @@ var ChartFrame = /* @__PURE__ */ react.forwardRef(function ChartFrame2({ legend,
|
|
|
19389
19621
|
style,
|
|
19390
19622
|
...props,
|
|
19391
19623
|
children: [
|
|
19624
|
+
(title || unit) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-(--cmp-chart-gap)", children: [
|
|
19625
|
+
title && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "typo-body-md-medium text-(--cmp-chart-title-color)", children: title }),
|
|
19626
|
+
unit && // ml-auto — title 유무와 관계없이 항상 오른쪽 끝에 붙는다.
|
|
19627
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "ml-auto whitespace-nowrap typo-body-sm-default text-(--cmp-chart-unit-color)", children: [
|
|
19628
|
+
"\uB2E8\uC704 : ",
|
|
19629
|
+
unit
|
|
19630
|
+
] })
|
|
19631
|
+
] }),
|
|
19392
19632
|
legend && legendPosition === "top" && legend,
|
|
19393
19633
|
children,
|
|
19394
19634
|
legend && legendPosition === "bottom" && legend
|
|
@@ -19439,46 +19679,57 @@ function ChartLegend({ items, align = "center", activeIndex, className }) {
|
|
|
19439
19679
|
|
|
19440
19680
|
// src/lib/chart/palette.ts
|
|
19441
19681
|
var V3 = (path) => `var(--cmp-chart-palette-${path})`;
|
|
19442
|
-
var
|
|
19443
|
-
|
|
19444
|
-
|
|
19445
|
-
|
|
19446
|
-
|
|
19447
|
-
|
|
19448
|
-
|
|
19449
|
-
|
|
19450
|
-
|
|
19451
|
-
|
|
19682
|
+
var DIMMED = (path) => `var(--cmp-chart-line-point-dimmed-palette-${path})`;
|
|
19683
|
+
var colorsOf = (v) => ({
|
|
19684
|
+
positivePrimary: v("variation-positivePrimary"),
|
|
19685
|
+
positiveSecondary: v("variation-positiveSecondary"),
|
|
19686
|
+
negativePrimary: v("variation-negativePrimary"),
|
|
19687
|
+
negativeSecondary: v("variation-negativeSecondary"),
|
|
19688
|
+
neutralPrimary: v("variation-neutralPrimary"),
|
|
19689
|
+
neutralSecondary: v("variation-neutralSecondary")
|
|
19690
|
+
});
|
|
19691
|
+
var palettesOf = (v) => ({
|
|
19692
|
+
default: [v("single")],
|
|
19452
19693
|
multi: [
|
|
19453
|
-
|
|
19454
|
-
|
|
19455
|
-
|
|
19456
|
-
|
|
19457
|
-
|
|
19458
|
-
|
|
19459
|
-
|
|
19460
|
-
|
|
19461
|
-
|
|
19462
|
-
|
|
19463
|
-
|
|
19694
|
+
v("multi-blue"),
|
|
19695
|
+
v("multi-skyblue"),
|
|
19696
|
+
v("multi-yellow"),
|
|
19697
|
+
v("multi-olive"),
|
|
19698
|
+
v("multi-lightRed"),
|
|
19699
|
+
v("multi-warmBlue"),
|
|
19700
|
+
v("multi-orange"),
|
|
19701
|
+
v("multi-green"),
|
|
19702
|
+
v("multi-navy"),
|
|
19703
|
+
v("multi-grey"),
|
|
19704
|
+
v("multi-red")
|
|
19464
19705
|
],
|
|
19465
19706
|
gradation: [
|
|
19466
|
-
|
|
19467
|
-
|
|
19468
|
-
|
|
19469
|
-
|
|
19470
|
-
|
|
19471
|
-
|
|
19707
|
+
v("gradation-1"),
|
|
19708
|
+
v("gradation-2"),
|
|
19709
|
+
v("gradation-3"),
|
|
19710
|
+
v("gradation-4"),
|
|
19711
|
+
v("gradation-5"),
|
|
19712
|
+
v("gradation-6")
|
|
19472
19713
|
]
|
|
19473
|
-
};
|
|
19474
|
-
|
|
19714
|
+
});
|
|
19715
|
+
var CHART_COLORS = colorsOf(V3);
|
|
19716
|
+
var CHART_PALETTES = palettesOf(V3);
|
|
19717
|
+
var DIMMED_COLORS = colorsOf(DIMMED);
|
|
19718
|
+
var DIMMED_PALETTES = palettesOf(DIMMED);
|
|
19719
|
+
function pick(names, palettes, palette, index, colors) {
|
|
19475
19720
|
if (palette === "custom") {
|
|
19476
|
-
if (!colors?.length) return
|
|
19477
|
-
return
|
|
19721
|
+
if (!colors?.length) return palettes.default[0];
|
|
19722
|
+
return names[colors[index % colors.length]];
|
|
19478
19723
|
}
|
|
19479
|
-
const list =
|
|
19724
|
+
const list = palettes[palette] ?? palettes.default;
|
|
19480
19725
|
return list[index % list.length];
|
|
19481
19726
|
}
|
|
19727
|
+
function paletteColor(palette, index, colors) {
|
|
19728
|
+
return pick(CHART_COLORS, CHART_PALETTES, palette, index, colors);
|
|
19729
|
+
}
|
|
19730
|
+
function linePointDimmedColor(palette, index, colors) {
|
|
19731
|
+
return pick(DIMMED_COLORS, DIMMED_PALETTES, palette, index, colors);
|
|
19732
|
+
}
|
|
19482
19733
|
function useElementSize() {
|
|
19483
19734
|
const ref = react.useRef(null);
|
|
19484
19735
|
const [size, setSize] = react.useState({ width: 0, height: 0 });
|
|
@@ -19556,7 +19807,8 @@ function ChartTooltip({
|
|
|
19556
19807
|
"pointer-events-none absolute top-0 left-0 z-10 w-max",
|
|
19557
19808
|
"flex flex-col gap-(--cmp-chart-chartTooltip-gap)",
|
|
19558
19809
|
"px-(--cmp-chart-chartTooltip-paddingX) py-(--cmp-chart-chartTooltip-paddingY)",
|
|
19559
|
-
"rounded-(--cmp-chart-chartTooltip-radius) bg-(--cmp-chart-chartTooltip-bg)
|
|
19810
|
+
"rounded-(--cmp-chart-chartTooltip-radius) bg-(--cmp-chart-chartTooltip-bg)",
|
|
19811
|
+
"shadow-(--cmp-chart-chartTooltip-shadow)",
|
|
19560
19812
|
className
|
|
19561
19813
|
),
|
|
19562
19814
|
style: {
|
|
@@ -19603,12 +19855,12 @@ var BAR_SIZE_MAX = 80;
|
|
|
19603
19855
|
var BAR_GAP = 6;
|
|
19604
19856
|
var GROUP_PADDING_MIN = 8;
|
|
19605
19857
|
var GROUP_PADDING_MAX = 24;
|
|
19606
|
-
var VALUE_LABEL_GAP =
|
|
19858
|
+
var VALUE_LABEL_GAP = 4;
|
|
19607
19859
|
var BAR_RADIUS = 8;
|
|
19608
|
-
var BAR_OPACITY_DEFAULT = "var(--cmp-chart-
|
|
19860
|
+
var BAR_OPACITY_DEFAULT = "var(--cmp-chart-opacity-default)";
|
|
19609
19861
|
var BAR_OPACITY_DIMMED = "var(--cmp-chart-bar-opacity-dimmed)";
|
|
19610
19862
|
var BAR_OPACITY_HOVER = 1;
|
|
19611
|
-
var BAR_DATA_LABEL_COLOR = "var(--cmp-chart-
|
|
19863
|
+
var BAR_DATA_LABEL_COLOR = "var(--cmp-chart-dataLabel-color-default)";
|
|
19612
19864
|
var BAR_DATA_LABEL_TYPO = "typo-body-sm-medium";
|
|
19613
19865
|
var BAR_DATA_LABEL_TYPO_HOVER = "typo-body-md-bold";
|
|
19614
19866
|
var BAR_HOVER_TRANSITION = "transition-opacity duration-200 ease-out motion-reduce:transition-none";
|
|
@@ -19668,6 +19920,8 @@ function barPath(x, y, width, height, direction, negative) {
|
|
|
19668
19920
|
var SBarChart = /* @__PURE__ */ react.forwardRef(function SBarChart2({
|
|
19669
19921
|
categories,
|
|
19670
19922
|
series,
|
|
19923
|
+
title,
|
|
19924
|
+
unit,
|
|
19671
19925
|
direction = "vertical",
|
|
19672
19926
|
stacked = false,
|
|
19673
19927
|
palette = "default",
|
|
@@ -20133,6 +20387,8 @@ var SBarChart = /* @__PURE__ */ react.forwardRef(function SBarChart2({
|
|
|
20133
20387
|
ChartFrame,
|
|
20134
20388
|
{
|
|
20135
20389
|
ref,
|
|
20390
|
+
title,
|
|
20391
|
+
unit,
|
|
20136
20392
|
legend,
|
|
20137
20393
|
legendPosition,
|
|
20138
20394
|
className,
|
|
@@ -20173,18 +20429,18 @@ var SBarChart = /* @__PURE__ */ react.forwardRef(function SBarChart2({
|
|
|
20173
20429
|
});
|
|
20174
20430
|
|
|
20175
20431
|
// src/components/SLineChart/lineChart.config.ts
|
|
20176
|
-
var LINE_WIDTH =
|
|
20177
|
-
var
|
|
20178
|
-
var
|
|
20179
|
-
var
|
|
20180
|
-
var
|
|
20181
|
-
var
|
|
20182
|
-
var POINT_HOVER_EXTENT =
|
|
20432
|
+
var LINE_WIDTH = "var(--cmp-chart-line-width)";
|
|
20433
|
+
var LINE_OPACITY = "var(--cmp-chart-line-opacity)";
|
|
20434
|
+
var POINT_RADIUS = 5;
|
|
20435
|
+
var POINT_HOVER_RADIUS = 6;
|
|
20436
|
+
var POINT_HALO_RADIUS = 12;
|
|
20437
|
+
var POINT_HALO_OPACITY = "var(--cmp-chart-line-point-opacity-bg)";
|
|
20438
|
+
var POINT_HOVER_EXTENT = POINT_HALO_RADIUS;
|
|
20183
20439
|
var BAND_MIN = 40;
|
|
20184
|
-
var VALUE_LABEL_GAP2 =
|
|
20185
|
-
var AREA_OPACITY_TOP = "
|
|
20186
|
-
var AREA_OPACITY_BOTTOM = "var(--
|
|
20187
|
-
var LINE_DATA_LABEL_COLOR = "var(--cmp-chart-
|
|
20440
|
+
var VALUE_LABEL_GAP2 = 4;
|
|
20441
|
+
var AREA_OPACITY_TOP = "var(--cmp-chart-line-area-gradation-start)";
|
|
20442
|
+
var AREA_OPACITY_BOTTOM = "var(--cmp-chart-line-area-gradation-end)";
|
|
20443
|
+
var LINE_DATA_LABEL_COLOR = "var(--cmp-chart-dataLabel-color-default)";
|
|
20188
20444
|
var LINE_DATA_LABEL_TYPO = "typo-body-sm-medium";
|
|
20189
20445
|
var LINE_DATA_LABEL_TYPO_HOVER = "typo-body-md-bold";
|
|
20190
20446
|
var r = (value) => Math.round(value * 100) / 100;
|
|
@@ -20264,6 +20520,8 @@ function runsOf(row) {
|
|
|
20264
20520
|
var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
20265
20521
|
categories,
|
|
20266
20522
|
series,
|
|
20523
|
+
title,
|
|
20524
|
+
unit,
|
|
20267
20525
|
curve = "linear",
|
|
20268
20526
|
area = false,
|
|
20269
20527
|
stacked = false,
|
|
@@ -20293,6 +20551,10 @@ var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
|
20293
20551
|
(seriesIndex) => paletteColor(palette, seriesIndex, customColors),
|
|
20294
20552
|
[palette, customColors]
|
|
20295
20553
|
);
|
|
20554
|
+
const dimmedColorAt = react.useCallback(
|
|
20555
|
+
(seriesIndex) => linePointDimmedColor(palette, seriesIndex, customColors),
|
|
20556
|
+
[palette, customColors]
|
|
20557
|
+
);
|
|
20296
20558
|
const rows = react.useMemo(() => {
|
|
20297
20559
|
const running = categories.map(() => 0);
|
|
20298
20560
|
return series.map(
|
|
@@ -20464,10 +20726,13 @@ var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
|
20464
20726
|
"aria-hidden": true,
|
|
20465
20727
|
d,
|
|
20466
20728
|
fill: "none",
|
|
20467
|
-
strokeWidth: LINE_WIDTH,
|
|
20468
20729
|
strokeLinecap: "round",
|
|
20469
20730
|
strokeLinejoin: "round",
|
|
20470
|
-
style: {
|
|
20731
|
+
style: {
|
|
20732
|
+
stroke: colorAt(seriesIndex),
|
|
20733
|
+
strokeWidth: LINE_WIDTH,
|
|
20734
|
+
strokeOpacity: LINE_OPACITY
|
|
20735
|
+
}
|
|
20471
20736
|
},
|
|
20472
20737
|
`line-${seriesIndex}-${runIndex}`
|
|
20473
20738
|
);
|
|
@@ -20484,6 +20749,7 @@ var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
|
20484
20749
|
const hovered = hoveredCategory === categoryIndex;
|
|
20485
20750
|
if (!showPoint && !hovered) return;
|
|
20486
20751
|
const color = colorAt(seriesIndex);
|
|
20752
|
+
const dimmed = hoveredCategory != null && !hovered;
|
|
20487
20753
|
const key = `${seriesIndex}-${categoryIndex}`;
|
|
20488
20754
|
if (hovered) {
|
|
20489
20755
|
halos.push(
|
|
@@ -20493,12 +20759,8 @@ var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
|
20493
20759
|
"aria-hidden": true,
|
|
20494
20760
|
cx: point.x,
|
|
20495
20761
|
cy: point.y,
|
|
20496
|
-
r:
|
|
20497
|
-
style: {
|
|
20498
|
-
fill: POINT_HOVER_BG,
|
|
20499
|
-
stroke: color,
|
|
20500
|
-
strokeWidth: POINT_HOVER_BORDER_WIDTH
|
|
20501
|
-
}
|
|
20762
|
+
r: POINT_HALO_RADIUS,
|
|
20763
|
+
style: { fill: color, fillOpacity: POINT_HALO_OPACITY }
|
|
20502
20764
|
},
|
|
20503
20765
|
`halo-${key}`
|
|
20504
20766
|
)
|
|
@@ -20510,8 +20772,11 @@ var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
|
20510
20772
|
{
|
|
20511
20773
|
cx: point.x,
|
|
20512
20774
|
cy: point.y,
|
|
20513
|
-
r: hovered ?
|
|
20514
|
-
style: {
|
|
20775
|
+
r: hovered ? POINT_HOVER_RADIUS : POINT_RADIUS,
|
|
20776
|
+
style: {
|
|
20777
|
+
fill: dimmed ? dimmedColorAt(seriesIndex) : color,
|
|
20778
|
+
cursor: onPointClick ? "pointer" : void 0
|
|
20779
|
+
},
|
|
20515
20780
|
onClick: onPointClick ? () => onPointClick({ seriesIndex, categoryIndex, value: point.own }) : void 0,
|
|
20516
20781
|
children: /* @__PURE__ */ jsxRuntime.jsx("title", { children: `${categories[categoryIndex]} ${series[seriesIndex]?.name ?? ""} ${formatValue(point.own)}` })
|
|
20517
20782
|
},
|
|
@@ -20521,7 +20786,17 @@ var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
|
20521
20786
|
});
|
|
20522
20787
|
});
|
|
20523
20788
|
return { pointHalos: halos, pointDots: dots };
|
|
20524
|
-
}, [
|
|
20789
|
+
}, [
|
|
20790
|
+
plotted,
|
|
20791
|
+
showPoint,
|
|
20792
|
+
hoveredCategory,
|
|
20793
|
+
colorAt,
|
|
20794
|
+
dimmedColorAt,
|
|
20795
|
+
onPointClick,
|
|
20796
|
+
categories,
|
|
20797
|
+
series,
|
|
20798
|
+
formatValue
|
|
20799
|
+
]);
|
|
20525
20800
|
const valueLabels = react.useMemo(
|
|
20526
20801
|
() => showValueLabel ? plotted.flatMap(
|
|
20527
20802
|
(row, seriesIndex) => row.map(
|
|
@@ -20547,6 +20822,8 @@ var SLineChart = /* @__PURE__ */ react.forwardRef(function SLineChart2({
|
|
|
20547
20822
|
ChartFrame,
|
|
20548
20823
|
{
|
|
20549
20824
|
ref,
|
|
20825
|
+
title,
|
|
20826
|
+
unit,
|
|
20550
20827
|
legend,
|
|
20551
20828
|
legendPosition,
|
|
20552
20829
|
className,
|
|
@@ -20682,8 +20959,9 @@ var LABEL_MIN_RATIO = 0.05;
|
|
|
20682
20959
|
var PIE_LABEL_RADIUS_RATIO = 0.65;
|
|
20683
20960
|
var HOVER_GROW = 4;
|
|
20684
20961
|
var HOVER_CORNER = 2;
|
|
20685
|
-
var OPACITY_DEFAULT = "var(--cmp-chart-
|
|
20686
|
-
var OPACITY_DIMMED = "var(--cmp-chart-
|
|
20962
|
+
var OPACITY_DEFAULT = "var(--cmp-chart-opacity-default)";
|
|
20963
|
+
var OPACITY_DIMMED = "var(--cmp-chart-doughnut-opacity-dimmed)";
|
|
20964
|
+
var SLICE_HOVER_SHADOW = "var(--cmp-chart-doughnut-shadow-hover-filter)";
|
|
20687
20965
|
var OPACITY_HOVER = 1;
|
|
20688
20966
|
var defaultFormat3 = (value) => value.toLocaleString();
|
|
20689
20967
|
function formatRatio(ratio) {
|
|
@@ -20733,6 +21011,8 @@ function slicePath(center, outer, inner, start, end, corner = 0) {
|
|
|
20733
21011
|
}
|
|
20734
21012
|
var RadialChart = /* @__PURE__ */ react.forwardRef(function RadialChart2({
|
|
20735
21013
|
data,
|
|
21014
|
+
title,
|
|
21015
|
+
unit,
|
|
20736
21016
|
palette = "multi",
|
|
20737
21017
|
colors,
|
|
20738
21018
|
showValueLabel = false,
|
|
@@ -20804,6 +21084,8 @@ var RadialChart = /* @__PURE__ */ react.forwardRef(function RadialChart2({
|
|
|
20804
21084
|
ChartFrame,
|
|
20805
21085
|
{
|
|
20806
21086
|
ref,
|
|
21087
|
+
title,
|
|
21088
|
+
unit,
|
|
20807
21089
|
legend,
|
|
20808
21090
|
legendPosition,
|
|
20809
21091
|
className,
|
|
@@ -20814,6 +21096,7 @@ var RadialChart = /* @__PURE__ */ react.forwardRef(function RadialChart2({
|
|
|
20814
21096
|
{
|
|
20815
21097
|
width: diameter,
|
|
20816
21098
|
height: diameter,
|
|
21099
|
+
overflow: "visible",
|
|
20817
21100
|
role: "img",
|
|
20818
21101
|
"aria-label": `${arcs.length}\uAC1C \uD56D\uBAA9 ${kind}`,
|
|
20819
21102
|
onMouseLeave: () => setHovered(null),
|
|
@@ -20826,7 +21109,7 @@ var RadialChart = /* @__PURE__ */ react.forwardRef(function RadialChart2({
|
|
|
20826
21109
|
"aria-hidden": true,
|
|
20827
21110
|
d: slicePath(center, outer, inner, 0, Math.PI * 2),
|
|
20828
21111
|
fillRule: "evenodd",
|
|
20829
|
-
style: { fill: "var(--cmp-chart-
|
|
21112
|
+
style: { fill: "var(--cmp-chart-gridline-color)" }
|
|
20830
21113
|
}
|
|
20831
21114
|
)
|
|
20832
21115
|
) : arcs.map((arc2) => {
|
|
@@ -20840,6 +21123,10 @@ var RadialChart = /* @__PURE__ */ react.forwardRef(function RadialChart2({
|
|
|
20840
21123
|
style: {
|
|
20841
21124
|
fill: arc2.color,
|
|
20842
21125
|
opacity,
|
|
21126
|
+
// 짚은 조각만 떠오른다. SVG 도형에는 box-shadow 가 걸리지 않아
|
|
21127
|
+
// 같은 토큰의 filter 형태를 쓴다 (drop-shadow 에는 spread 가 없다 —
|
|
21128
|
+
// 토큰의 음수 spread 만큼 설계보다 조금 넓게 깔린다).
|
|
21129
|
+
filter: hovered === arc2.index ? SLICE_HOVER_SHADOW : void 0,
|
|
20843
21130
|
cursor: onSliceClick ? "pointer" : void 0
|
|
20844
21131
|
},
|
|
20845
21132
|
onMouseEnter: () => setHovered(arc2.index),
|
|
@@ -23410,6 +23697,7 @@ var SEditor = /* @__PURE__ */ react.forwardRef(function SEditor2({
|
|
|
23410
23697
|
onFocus,
|
|
23411
23698
|
onBlur,
|
|
23412
23699
|
label,
|
|
23700
|
+
labelPosition,
|
|
23413
23701
|
labelWidth,
|
|
23414
23702
|
icon,
|
|
23415
23703
|
iconColor,
|
|
@@ -23498,6 +23786,7 @@ var SEditor = /* @__PURE__ */ react.forwardRef(function SEditor2({
|
|
|
23498
23786
|
{
|
|
23499
23787
|
name,
|
|
23500
23788
|
label,
|
|
23789
|
+
labelPosition,
|
|
23501
23790
|
labelWidth,
|
|
23502
23791
|
icon,
|
|
23503
23792
|
iconColor,
|
|
@@ -25385,7 +25674,7 @@ function ListBox({
|
|
|
25385
25674
|
"div",
|
|
25386
25675
|
{
|
|
25387
25676
|
className: cn(
|
|
25388
|
-
"overflow-hidden border border-solid shadow-[var(--shadow
|
|
25677
|
+
"overflow-hidden border border-solid shadow-[var(--cmp-chipFilter-listbox-shadow)]",
|
|
25389
25678
|
maxHeight && "flex flex-col"
|
|
25390
25679
|
),
|
|
25391
25680
|
style: {
|
|
@@ -25470,6 +25759,7 @@ var SChipInput = /* @__PURE__ */ react.forwardRef(function SChipInput2({
|
|
|
25470
25759
|
loadingRecommendedItems = false,
|
|
25471
25760
|
dropdownMinWidth = 200,
|
|
25472
25761
|
label,
|
|
25762
|
+
labelPosition,
|
|
25473
25763
|
labelWidth,
|
|
25474
25764
|
hint,
|
|
25475
25765
|
errorMessage,
|
|
@@ -25610,6 +25900,7 @@ var SChipInput = /* @__PURE__ */ react.forwardRef(function SChipInput2({
|
|
|
25610
25900
|
SField,
|
|
25611
25901
|
{
|
|
25612
25902
|
label,
|
|
25903
|
+
labelPosition,
|
|
25613
25904
|
labelWidth,
|
|
25614
25905
|
labelHeight: `calc(var(--cmp-chipInput-${size}-minHeight) + 2px)`,
|
|
25615
25906
|
icon,
|
|
@@ -25928,6 +26219,7 @@ var SBarcodeInput = /* @__PURE__ */ react.forwardRef(
|
|
|
25928
26219
|
inputClassName,
|
|
25929
26220
|
inputStyle,
|
|
25930
26221
|
label,
|
|
26222
|
+
labelPosition,
|
|
25931
26223
|
labelWidth,
|
|
25932
26224
|
icon,
|
|
25933
26225
|
iconColor,
|
|
@@ -25964,6 +26256,7 @@ var SBarcodeInput = /* @__PURE__ */ react.forwardRef(
|
|
|
25964
26256
|
SField,
|
|
25965
26257
|
{
|
|
25966
26258
|
label,
|
|
26259
|
+
labelPosition,
|
|
25967
26260
|
labelWidth,
|
|
25968
26261
|
icon,
|
|
25969
26262
|
iconColor,
|
|
@@ -26333,6 +26626,7 @@ function STimePicker({
|
|
|
26333
26626
|
rules,
|
|
26334
26627
|
status,
|
|
26335
26628
|
label,
|
|
26629
|
+
labelPosition,
|
|
26336
26630
|
labelWidth,
|
|
26337
26631
|
icon,
|
|
26338
26632
|
iconColor,
|
|
@@ -26387,6 +26681,7 @@ function STimePicker({
|
|
|
26387
26681
|
SField,
|
|
26388
26682
|
{
|
|
26389
26683
|
label,
|
|
26684
|
+
labelPosition,
|
|
26390
26685
|
labelWidth,
|
|
26391
26686
|
icon,
|
|
26392
26687
|
iconColor,
|
|
@@ -26799,6 +27094,7 @@ function STimeRangePicker({
|
|
|
26799
27094
|
rules,
|
|
26800
27095
|
status,
|
|
26801
27096
|
label,
|
|
27097
|
+
labelPosition,
|
|
26802
27098
|
labelWidth,
|
|
26803
27099
|
icon,
|
|
26804
27100
|
iconColor,
|
|
@@ -26855,6 +27151,7 @@ function STimeRangePicker({
|
|
|
26855
27151
|
SField,
|
|
26856
27152
|
{
|
|
26857
27153
|
label,
|
|
27154
|
+
labelPosition,
|
|
26858
27155
|
labelWidth,
|
|
26859
27156
|
icon,
|
|
26860
27157
|
iconColor,
|
|
@@ -26986,6 +27283,10 @@ exports.CHAT_MESSAGE_READ_STATUSES = CHAT_MESSAGE_READ_STATUSES;
|
|
|
26986
27283
|
exports.CHAT_MESSAGE_VARIANTS = CHAT_MESSAGE_VARIANTS;
|
|
26987
27284
|
exports.CHIP_COLORS = CHIP_COLORS;
|
|
26988
27285
|
exports.COLOR_KEYS = COLOR_KEYS;
|
|
27286
|
+
exports.CONTEXT_ALERT_DEFAULT_ICON = CONTEXT_ALERT_DEFAULT_ICON;
|
|
27287
|
+
exports.CONTEXT_ALERT_ICON_COLOR = CONTEXT_ALERT_ICON_COLOR;
|
|
27288
|
+
exports.CONTEXT_ALERT_INTENTS = CONTEXT_ALERT_INTENTS;
|
|
27289
|
+
exports.CONTEXT_ALERT_SURFACE = CONTEXT_ALERT_SURFACE;
|
|
26989
27290
|
exports.FIELD_WIDTH_GRADES = FIELD_WIDTH_GRADES;
|
|
26990
27291
|
exports.GNB_COLORS = GNB_COLORS;
|
|
26991
27292
|
exports.GNB_COMMON = GNB_COMMON;
|
|
@@ -27040,6 +27341,7 @@ exports.SChipFilter = SChipFilter;
|
|
|
27040
27341
|
exports.SChipInput = SChipInput;
|
|
27041
27342
|
exports.SCircleProgress = SCircleProgress;
|
|
27042
27343
|
exports.SConfirmModal = SConfirmModal;
|
|
27344
|
+
exports.SContextAlert = SContextAlert;
|
|
27043
27345
|
exports.SDatePicker = SDatePicker;
|
|
27044
27346
|
exports.SDatePickerMonthListbox = SDatePickerMonthListbox;
|
|
27045
27347
|
exports.SDatePickerYearListbox = SDatePickerYearListbox;
|