@stn-uiux/pub-ui-react 0.1.68 → 0.1.70
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.d.ts +85 -4
- package/dist/index.js +1241 -811
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -2806,9 +2806,17 @@ var StnTree = forwardRef14(function StnTree2({
|
|
|
2806
2806
|
// src/components/StnCard.tsx
|
|
2807
2807
|
import { forwardRef as forwardRef15 } from "react";
|
|
2808
2808
|
import { jsx as jsx20, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
2809
|
-
function StnCardHeader({
|
|
2809
|
+
function StnCardHeader({
|
|
2810
|
+
children,
|
|
2811
|
+
title,
|
|
2812
|
+
titleSize = "md",
|
|
2813
|
+
titleWeight = "semibold",
|
|
2814
|
+
extra,
|
|
2815
|
+
className,
|
|
2816
|
+
...rest
|
|
2817
|
+
}) {
|
|
2810
2818
|
return /* @__PURE__ */ jsxs14("div", { className: cn("stn-card__header", className), ...rest, children: [
|
|
2811
|
-
title ? /* @__PURE__ */ jsx20("div", { className: "stn-card__header-title", children: title }) : null,
|
|
2819
|
+
title ? /* @__PURE__ */ jsx20("div", { className: cn("stn-card__header-title", titleSize, titleWeight), children: title }) : null,
|
|
2812
2820
|
children,
|
|
2813
2821
|
extra ? /* @__PURE__ */ jsx20("div", { className: "stn-card__header-extra", children: extra }) : null
|
|
2814
2822
|
] });
|
|
@@ -2825,6 +2833,8 @@ var StnCard = forwardRef15(function StnCard2({
|
|
|
2825
2833
|
radius = "md",
|
|
2826
2834
|
padding = "md",
|
|
2827
2835
|
interactive = false,
|
|
2836
|
+
fullWidth = false,
|
|
2837
|
+
fullHeight = false,
|
|
2828
2838
|
className,
|
|
2829
2839
|
role,
|
|
2830
2840
|
tabIndex,
|
|
@@ -2843,6 +2853,8 @@ var StnCard = forwardRef15(function StnCard2({
|
|
|
2843
2853
|
`radius-${radius}`,
|
|
2844
2854
|
`pad-${padding}`,
|
|
2845
2855
|
isClickable && "interactive",
|
|
2856
|
+
fullWidth && "is-full-width",
|
|
2857
|
+
fullHeight && "is-full-height",
|
|
2846
2858
|
className
|
|
2847
2859
|
),
|
|
2848
2860
|
...rest,
|
|
@@ -3224,7 +3236,7 @@ function StnChip(props) {
|
|
|
3224
3236
|
const resolvedShape = rawShape === "rounded" || rawShape === "square" ? "square" : rawShape;
|
|
3225
3237
|
const isOutline = variant === "outline" || variant === "outlined" || variant === "border";
|
|
3226
3238
|
const isSubtle = bgOpacity === 50 || bgOpacity === "50" || bgOpacity === "50%" || bgOpacity === 0.5 || variant === "subtle" || variant === "soft" || variant === "tinted" || variant === "contained-50" || variant === "filled-50";
|
|
3227
|
-
const variantClass7 = isOutline ? "outline" : isSubtle ? "
|
|
3239
|
+
const variantClass7 = isOutline ? "outline" : isSubtle ? "soft" : "filled";
|
|
3228
3240
|
const resolvedColor = color ?? grade;
|
|
3229
3241
|
let content = children ?? label;
|
|
3230
3242
|
if (!content && grade && STN_GRADE_SOURCE[grade]) {
|
|
@@ -3245,8 +3257,8 @@ function StnChip(props) {
|
|
|
3245
3257
|
onClick?.(e);
|
|
3246
3258
|
}
|
|
3247
3259
|
};
|
|
3248
|
-
const iconElement = icon ? /* @__PURE__ */ jsx26("span", { className: "stn-chip__icon", children: icon }) : null;
|
|
3249
|
-
const contentElement = /* @__PURE__ */ jsx26("span", { className: "stn-chip__label", children: content });
|
|
3260
|
+
const iconElement = icon ? /* @__PURE__ */ jsx26("span", { className: "stn-chip__icon", children: icon }, "icon") : null;
|
|
3261
|
+
const contentElement = /* @__PURE__ */ jsx26("span", { className: "stn-chip__label", children: content }, "content");
|
|
3250
3262
|
const deleteElement = onDelete ? /* @__PURE__ */ jsx26(
|
|
3251
3263
|
"button",
|
|
3252
3264
|
{
|
|
@@ -3258,7 +3270,8 @@ function StnChip(props) {
|
|
|
3258
3270
|
onDelete(e);
|
|
3259
3271
|
},
|
|
3260
3272
|
children: deleteIcon ?? /* @__PURE__ */ jsx26(DefaultDeleteIcon, {})
|
|
3261
|
-
}
|
|
3273
|
+
},
|
|
3274
|
+
"delete"
|
|
3262
3275
|
) : null;
|
|
3263
3276
|
const elements = [];
|
|
3264
3277
|
if (deleteElement && deleteIconPosition === "left") {
|
|
@@ -3708,17 +3721,386 @@ function StnSegmented(props) {
|
|
|
3708
3721
|
);
|
|
3709
3722
|
}
|
|
3710
3723
|
|
|
3711
|
-
// src/components/
|
|
3724
|
+
// src/components/tabs/StnTabs.tsx
|
|
3712
3725
|
import {
|
|
3713
|
-
|
|
3726
|
+
forwardRef as forwardRef25,
|
|
3727
|
+
useState as useState9,
|
|
3728
|
+
useRef as useRef5,
|
|
3714
3729
|
useEffect as useEffect7,
|
|
3730
|
+
useCallback as useCallback5,
|
|
3731
|
+
useLayoutEffect
|
|
3732
|
+
} from "react";
|
|
3733
|
+
|
|
3734
|
+
// src/components/tabs/StnTabContext.tsx
|
|
3735
|
+
import { createContext as createContext3, useContext as useContext3 } from "react";
|
|
3736
|
+
import { jsx as jsx32 } from "react/jsx-runtime";
|
|
3737
|
+
var StnTabsContext = createContext3(null);
|
|
3738
|
+
function useStnTabsContext() {
|
|
3739
|
+
return useContext3(StnTabsContext);
|
|
3740
|
+
}
|
|
3741
|
+
function StnTabContextProvider({
|
|
3742
|
+
value,
|
|
3743
|
+
onChange,
|
|
3744
|
+
size = "md",
|
|
3745
|
+
variant = "line",
|
|
3746
|
+
children
|
|
3747
|
+
}) {
|
|
3748
|
+
return /* @__PURE__ */ jsx32(StnTabsContext.Provider, { value: { value, onChange, size, variant }, children });
|
|
3749
|
+
}
|
|
3750
|
+
|
|
3751
|
+
// src/components/tabs/StnTab.tsx
|
|
3752
|
+
import { forwardRef as forwardRef23 } from "react";
|
|
3753
|
+
import { jsx as jsx33, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
3754
|
+
var StnTab = forwardRef23(function StnTab2({
|
|
3755
|
+
value,
|
|
3756
|
+
label,
|
|
3757
|
+
icon,
|
|
3758
|
+
iconPosition = "start",
|
|
3759
|
+
iconSize = "md",
|
|
3760
|
+
badge,
|
|
3761
|
+
count,
|
|
3762
|
+
disabled = false,
|
|
3763
|
+
wrapped = false,
|
|
3764
|
+
className = "",
|
|
3765
|
+
children,
|
|
3766
|
+
onClick,
|
|
3767
|
+
...rest
|
|
3768
|
+
}, ref) {
|
|
3769
|
+
const context = useStnTabsContext();
|
|
3770
|
+
const isActive = context ? context.value === value : false;
|
|
3771
|
+
const handleClick = (e) => {
|
|
3772
|
+
if (disabled) return;
|
|
3773
|
+
onClick?.(e);
|
|
3774
|
+
if (!e.defaultPrevented && context?.onChange) {
|
|
3775
|
+
context.onChange(value);
|
|
3776
|
+
}
|
|
3777
|
+
};
|
|
3778
|
+
const content = children ?? label;
|
|
3779
|
+
const isIconOnly = Boolean(icon && !content);
|
|
3780
|
+
const classList = [
|
|
3781
|
+
"stn-tab",
|
|
3782
|
+
isActive && "is-active",
|
|
3783
|
+
disabled && "is-disabled",
|
|
3784
|
+
wrapped && "is-wrapped",
|
|
3785
|
+
icon && `icon-${iconPosition}`,
|
|
3786
|
+
isIconOnly && "icon-only",
|
|
3787
|
+
className
|
|
3788
|
+
].filter(Boolean).join(" ");
|
|
3789
|
+
const iconSizeClass = typeof iconSize === "string" ? `icon-${iconSize}` : void 0;
|
|
3790
|
+
const iconStyle = typeof iconSize === "number" ? { width: `${iconSize}px`, height: `${iconSize}px` } : void 0;
|
|
3791
|
+
const renderedIcon = icon ? /* @__PURE__ */ jsx33(
|
|
3792
|
+
"span",
|
|
3793
|
+
{
|
|
3794
|
+
className: ["stn-tab__icon", iconSizeClass].filter(Boolean).join(" "),
|
|
3795
|
+
style: iconStyle,
|
|
3796
|
+
"aria-hidden": "true",
|
|
3797
|
+
children: icon
|
|
3798
|
+
}
|
|
3799
|
+
) : null;
|
|
3800
|
+
return /* @__PURE__ */ jsxs25(
|
|
3801
|
+
"button",
|
|
3802
|
+
{
|
|
3803
|
+
ref,
|
|
3804
|
+
type: "button",
|
|
3805
|
+
role: "tab",
|
|
3806
|
+
"aria-selected": isActive,
|
|
3807
|
+
"aria-disabled": disabled,
|
|
3808
|
+
tabIndex: isActive ? 0 : -1,
|
|
3809
|
+
disabled,
|
|
3810
|
+
className: classList,
|
|
3811
|
+
"data-value": value,
|
|
3812
|
+
onClick: handleClick,
|
|
3813
|
+
...rest,
|
|
3814
|
+
children: [
|
|
3815
|
+
iconPosition !== "end" && iconPosition !== "bottom" && renderedIcon,
|
|
3816
|
+
content && /* @__PURE__ */ jsx33("span", { className: "stn-tab__label", children: content }),
|
|
3817
|
+
(iconPosition === "end" || iconPosition === "bottom") && renderedIcon,
|
|
3818
|
+
count !== void 0 && /* @__PURE__ */ jsx33("span", { className: "stn-tab__badge", children: count }),
|
|
3819
|
+
badge && /* @__PURE__ */ jsx33("span", { className: "stn-tab__extra", children: badge })
|
|
3820
|
+
]
|
|
3821
|
+
}
|
|
3822
|
+
);
|
|
3823
|
+
});
|
|
3824
|
+
|
|
3825
|
+
// src/components/tabs/StnTabPanel.tsx
|
|
3826
|
+
import { forwardRef as forwardRef24 } from "react";
|
|
3827
|
+
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
3828
|
+
var StnTabPanel = forwardRef24(function StnTabPanel2({
|
|
3829
|
+
value,
|
|
3830
|
+
current,
|
|
3831
|
+
padding = "md",
|
|
3832
|
+
keepMounted = false,
|
|
3833
|
+
className = "",
|
|
3834
|
+
children,
|
|
3835
|
+
...rest
|
|
3836
|
+
}, ref) {
|
|
3837
|
+
const context = useStnTabsContext();
|
|
3838
|
+
const activeValue = current !== void 0 ? current : context?.value;
|
|
3839
|
+
const isSelected = activeValue !== void 0 ? activeValue === value : true;
|
|
3840
|
+
if (!isSelected && !keepMounted) {
|
|
3841
|
+
return null;
|
|
3842
|
+
}
|
|
3843
|
+
const classList = [
|
|
3844
|
+
"stn-tab-panel",
|
|
3845
|
+
padding && `padding-${padding}`,
|
|
3846
|
+
className
|
|
3847
|
+
].filter(Boolean).join(" ");
|
|
3848
|
+
return /* @__PURE__ */ jsx34(
|
|
3849
|
+
"div",
|
|
3850
|
+
{
|
|
3851
|
+
ref,
|
|
3852
|
+
role: "tabpanel",
|
|
3853
|
+
hidden: !isSelected,
|
|
3854
|
+
tabIndex: 0,
|
|
3855
|
+
className: classList,
|
|
3856
|
+
...rest,
|
|
3857
|
+
children: isSelected ? children : null
|
|
3858
|
+
}
|
|
3859
|
+
);
|
|
3860
|
+
});
|
|
3861
|
+
|
|
3862
|
+
// src/components/tabs/StnTabs.tsx
|
|
3863
|
+
import { jsx as jsx35, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
3864
|
+
var useIsomorphicLayoutEffect = typeof window !== "undefined" ? useLayoutEffect : useEffect7;
|
|
3865
|
+
var StnTabsRoot = forwardRef25(function StnTabs({
|
|
3866
|
+
value: controlledValue,
|
|
3867
|
+
defaultValue,
|
|
3868
|
+
onChange,
|
|
3869
|
+
size: propSize,
|
|
3870
|
+
variant: propVariant,
|
|
3871
|
+
scrollButtons = "auto",
|
|
3872
|
+
fullWidth = false,
|
|
3873
|
+
centered = false,
|
|
3874
|
+
items,
|
|
3875
|
+
className = "",
|
|
3876
|
+
children,
|
|
3877
|
+
...rest
|
|
3878
|
+
}, ref) {
|
|
3879
|
+
const context = useStnTabsContext();
|
|
3880
|
+
const [internalValue, setInternalValue] = useState9(() => {
|
|
3881
|
+
return controlledValue ?? context?.value ?? defaultValue ?? (items && items.length > 0 ? items[0].value : "");
|
|
3882
|
+
});
|
|
3883
|
+
const activeValue = controlledValue ?? context?.value ?? internalValue;
|
|
3884
|
+
const handleValueChange = useCallback5(
|
|
3885
|
+
(newValue) => {
|
|
3886
|
+
if (controlledValue === void 0 && !context?.onChange) {
|
|
3887
|
+
setInternalValue(newValue);
|
|
3888
|
+
}
|
|
3889
|
+
onChange?.(newValue);
|
|
3890
|
+
context?.onChange?.(newValue);
|
|
3891
|
+
},
|
|
3892
|
+
[controlledValue, context, onChange]
|
|
3893
|
+
);
|
|
3894
|
+
const resolvedSize = propSize ?? context?.size ?? "md";
|
|
3895
|
+
const resolvedVariant = propVariant ?? context?.variant ?? "line";
|
|
3896
|
+
const scrollerRef = useRef5(null);
|
|
3897
|
+
const listRef = useRef5(null);
|
|
3898
|
+
const [indicatorStyle, setIndicatorStyle] = useState9({ left: 0, width: 0, opacity: 0 });
|
|
3899
|
+
const [canScrollStart, setCanScrollStart] = useState9(false);
|
|
3900
|
+
const [canScrollEnd, setCanScrollEnd] = useState9(false);
|
|
3901
|
+
const [isScrollable, setIsScrollable] = useState9(false);
|
|
3902
|
+
const updateIndicator = useCallback5(() => {
|
|
3903
|
+
const list = listRef.current;
|
|
3904
|
+
if (!list) return;
|
|
3905
|
+
const activeTab = list.querySelector(
|
|
3906
|
+
`[data-value="${CSS.escape(String(activeValue))}"]`
|
|
3907
|
+
);
|
|
3908
|
+
if (activeTab) {
|
|
3909
|
+
const listRect = list.getBoundingClientRect();
|
|
3910
|
+
const tabRect = activeTab.getBoundingClientRect();
|
|
3911
|
+
setIndicatorStyle({
|
|
3912
|
+
left: tabRect.left - listRect.left,
|
|
3913
|
+
width: tabRect.width,
|
|
3914
|
+
opacity: 1
|
|
3915
|
+
});
|
|
3916
|
+
} else {
|
|
3917
|
+
setIndicatorStyle((prev) => ({ ...prev, opacity: 0 }));
|
|
3918
|
+
}
|
|
3919
|
+
}, [activeValue]);
|
|
3920
|
+
const updateScrollState = useCallback5(() => {
|
|
3921
|
+
const scroller = scrollerRef.current;
|
|
3922
|
+
if (!scroller) return;
|
|
3923
|
+
const { scrollLeft, scrollWidth, clientWidth } = scroller;
|
|
3924
|
+
const scrollMax = scrollWidth - clientWidth;
|
|
3925
|
+
const scrollable = scrollWidth > clientWidth;
|
|
3926
|
+
setIsScrollable(scrollable);
|
|
3927
|
+
setCanScrollStart(scrollLeft > 2);
|
|
3928
|
+
setCanScrollEnd(scrollLeft < scrollMax - 2);
|
|
3929
|
+
}, []);
|
|
3930
|
+
const scrollActiveTabIntoView = useCallback5(() => {
|
|
3931
|
+
const scroller = scrollerRef.current;
|
|
3932
|
+
const list = listRef.current;
|
|
3933
|
+
if (!scroller || !list) return;
|
|
3934
|
+
const activeTab = list.querySelector(
|
|
3935
|
+
`[data-value="${CSS.escape(String(activeValue))}"]`
|
|
3936
|
+
);
|
|
3937
|
+
if (activeTab) {
|
|
3938
|
+
const tabLeft = activeTab.offsetLeft;
|
|
3939
|
+
const tabWidth = activeTab.offsetWidth;
|
|
3940
|
+
const scrollerWidth = scroller.clientWidth;
|
|
3941
|
+
const scrollerScrollLeft = scroller.scrollLeft;
|
|
3942
|
+
if (tabLeft < scrollerScrollLeft) {
|
|
3943
|
+
scroller.scrollTo({ left: tabLeft - 32, behavior: "smooth" });
|
|
3944
|
+
} else if (tabLeft + tabWidth > scrollerScrollLeft + scrollerWidth) {
|
|
3945
|
+
scroller.scrollTo({
|
|
3946
|
+
left: tabLeft + tabWidth - scrollerWidth + 32,
|
|
3947
|
+
behavior: "smooth"
|
|
3948
|
+
});
|
|
3949
|
+
}
|
|
3950
|
+
}
|
|
3951
|
+
}, [activeValue]);
|
|
3952
|
+
useIsomorphicLayoutEffect(() => {
|
|
3953
|
+
updateIndicator();
|
|
3954
|
+
updateScrollState();
|
|
3955
|
+
scrollActiveTabIntoView();
|
|
3956
|
+
}, [activeValue, updateIndicator, updateScrollState, scrollActiveTabIntoView]);
|
|
3957
|
+
useEffect7(() => {
|
|
3958
|
+
const handleResize = () => {
|
|
3959
|
+
updateIndicator();
|
|
3960
|
+
updateScrollState();
|
|
3961
|
+
};
|
|
3962
|
+
window.addEventListener("resize", handleResize);
|
|
3963
|
+
return () => window.removeEventListener("resize", handleResize);
|
|
3964
|
+
}, [updateIndicator, updateScrollState]);
|
|
3965
|
+
const handleScrollLeft = () => {
|
|
3966
|
+
if (scrollerRef.current) {
|
|
3967
|
+
scrollerRef.current.scrollBy({ left: -200, behavior: "smooth" });
|
|
3968
|
+
}
|
|
3969
|
+
};
|
|
3970
|
+
const handleScrollRight = () => {
|
|
3971
|
+
if (scrollerRef.current) {
|
|
3972
|
+
scrollerRef.current.scrollBy({ left: 200, behavior: "smooth" });
|
|
3973
|
+
}
|
|
3974
|
+
};
|
|
3975
|
+
const showScrollButtons = scrollButtons === true || scrollButtons === "auto" && isScrollable;
|
|
3976
|
+
const classList = [
|
|
3977
|
+
"stn-tabs",
|
|
3978
|
+
resolvedSize,
|
|
3979
|
+
resolvedVariant,
|
|
3980
|
+
fullWidth && "full",
|
|
3981
|
+
centered && "centered",
|
|
3982
|
+
isScrollable && "is-scrollable",
|
|
3983
|
+
canScrollStart && "has-scroll-start",
|
|
3984
|
+
canScrollEnd && "has-scroll-end",
|
|
3985
|
+
className
|
|
3986
|
+
].filter(Boolean).join(" ");
|
|
3987
|
+
const content = /* @__PURE__ */ jsxs26("div", { ref, className: classList, ...rest, children: [
|
|
3988
|
+
showScrollButtons && /* @__PURE__ */ jsx35(
|
|
3989
|
+
"button",
|
|
3990
|
+
{
|
|
3991
|
+
type: "button",
|
|
3992
|
+
"aria-label": "\uC774\uC804 \uD0ED \uBCF4\uAE30",
|
|
3993
|
+
disabled: !canScrollStart,
|
|
3994
|
+
className: "stn-tabs__scroll-button start",
|
|
3995
|
+
onClick: handleScrollLeft,
|
|
3996
|
+
children: /* @__PURE__ */ jsx35(
|
|
3997
|
+
"svg",
|
|
3998
|
+
{
|
|
3999
|
+
width: "16",
|
|
4000
|
+
height: "16",
|
|
4001
|
+
viewBox: "0 0 24 24",
|
|
4002
|
+
fill: "none",
|
|
4003
|
+
stroke: "currentColor",
|
|
4004
|
+
strokeWidth: "2",
|
|
4005
|
+
strokeLinecap: "round",
|
|
4006
|
+
strokeLinejoin: "round",
|
|
4007
|
+
children: /* @__PURE__ */ jsx35("polyline", { points: "15 18 9 12 15 6" })
|
|
4008
|
+
}
|
|
4009
|
+
)
|
|
4010
|
+
}
|
|
4011
|
+
),
|
|
4012
|
+
/* @__PURE__ */ jsx35(
|
|
4013
|
+
"div",
|
|
4014
|
+
{
|
|
4015
|
+
ref: scrollerRef,
|
|
4016
|
+
className: "stn-tabs__scroller",
|
|
4017
|
+
onScroll: updateScrollState,
|
|
4018
|
+
children: /* @__PURE__ */ jsxs26("ul", { ref: listRef, role: "tablist", className: "stn-tabs__list", children: [
|
|
4019
|
+
/* @__PURE__ */ jsx35(
|
|
4020
|
+
"div",
|
|
4021
|
+
{
|
|
4022
|
+
className: "stn-tabs__indicator",
|
|
4023
|
+
style: {
|
|
4024
|
+
left: `${indicatorStyle.left}px`,
|
|
4025
|
+
width: `${indicatorStyle.width}px`,
|
|
4026
|
+
opacity: indicatorStyle.opacity
|
|
4027
|
+
}
|
|
4028
|
+
}
|
|
4029
|
+
),
|
|
4030
|
+
items && items.length > 0 ? items.map((item) => /* @__PURE__ */ jsx35(
|
|
4031
|
+
StnTab,
|
|
4032
|
+
{
|
|
4033
|
+
value: item.value,
|
|
4034
|
+
label: item.label,
|
|
4035
|
+
icon: item.icon,
|
|
4036
|
+
iconPosition: item.iconPosition,
|
|
4037
|
+
iconSize: item.iconSize,
|
|
4038
|
+
badge: item.badge,
|
|
4039
|
+
count: item.count,
|
|
4040
|
+
disabled: item.disabled,
|
|
4041
|
+
wrapped: item.wrapped
|
|
4042
|
+
},
|
|
4043
|
+
item.value
|
|
4044
|
+
)) : children
|
|
4045
|
+
] })
|
|
4046
|
+
}
|
|
4047
|
+
),
|
|
4048
|
+
showScrollButtons && /* @__PURE__ */ jsx35(
|
|
4049
|
+
"button",
|
|
4050
|
+
{
|
|
4051
|
+
type: "button",
|
|
4052
|
+
"aria-label": "\uB2E4\uC74C \uD0ED \uBCF4\uAE30",
|
|
4053
|
+
disabled: !canScrollEnd,
|
|
4054
|
+
className: "stn-tabs__scroll-button end",
|
|
4055
|
+
onClick: handleScrollRight,
|
|
4056
|
+
children: /* @__PURE__ */ jsx35(
|
|
4057
|
+
"svg",
|
|
4058
|
+
{
|
|
4059
|
+
width: "16",
|
|
4060
|
+
height: "16",
|
|
4061
|
+
viewBox: "0 0 24 24",
|
|
4062
|
+
fill: "none",
|
|
4063
|
+
stroke: "currentColor",
|
|
4064
|
+
strokeWidth: "2",
|
|
4065
|
+
strokeLinecap: "round",
|
|
4066
|
+
strokeLinejoin: "round",
|
|
4067
|
+
children: /* @__PURE__ */ jsx35("polyline", { points: "9 18 15 12 9 6" })
|
|
4068
|
+
}
|
|
4069
|
+
)
|
|
4070
|
+
}
|
|
4071
|
+
)
|
|
4072
|
+
] });
|
|
4073
|
+
if (!context) {
|
|
4074
|
+
return /* @__PURE__ */ jsx35(
|
|
4075
|
+
StnTabContextProvider,
|
|
4076
|
+
{
|
|
4077
|
+
value: activeValue,
|
|
4078
|
+
onChange: handleValueChange,
|
|
4079
|
+
size: resolvedSize,
|
|
4080
|
+
variant: resolvedVariant,
|
|
4081
|
+
children: content
|
|
4082
|
+
}
|
|
4083
|
+
);
|
|
4084
|
+
}
|
|
4085
|
+
return content;
|
|
4086
|
+
});
|
|
4087
|
+
var StnTabs2 = Object.assign(StnTabsRoot, {
|
|
4088
|
+
Tab: StnTab,
|
|
4089
|
+
Panel: StnTabPanel,
|
|
4090
|
+
Context: StnTabContextProvider
|
|
4091
|
+
});
|
|
4092
|
+
|
|
4093
|
+
// src/components/StnDropdown.tsx
|
|
4094
|
+
import {
|
|
4095
|
+
useCallback as useCallback6,
|
|
4096
|
+
useEffect as useEffect8,
|
|
3715
4097
|
useId as useId9,
|
|
3716
|
-
useRef as
|
|
3717
|
-
useState as
|
|
4098
|
+
useRef as useRef6,
|
|
4099
|
+
useState as useState10
|
|
3718
4100
|
} from "react";
|
|
3719
|
-
import { jsx as
|
|
4101
|
+
import { jsx as jsx36, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
3720
4102
|
function resolveGlyph(node) {
|
|
3721
|
-
if (typeof node === "string") return /* @__PURE__ */
|
|
4103
|
+
if (typeof node === "string") return /* @__PURE__ */ jsx36(StnIcon, { name: node, size: 16, color: "currentColor" });
|
|
3722
4104
|
return node;
|
|
3723
4105
|
}
|
|
3724
4106
|
function modifierClass(modifier) {
|
|
@@ -3742,12 +4124,13 @@ function variantClass(variant = "outline") {
|
|
|
3742
4124
|
if (variant === "standard") return "standard";
|
|
3743
4125
|
if (variant === "filled") return "filled";
|
|
3744
4126
|
if (variant === "transparent") return "transparent";
|
|
4127
|
+
if (variant === "translucent") return "translucent";
|
|
3745
4128
|
return "outline";
|
|
3746
4129
|
}
|
|
3747
4130
|
function useControllable(controlled, defaultValue, onChange) {
|
|
3748
|
-
const [internal, setInternal] =
|
|
4131
|
+
const [internal, setInternal] = useState10(defaultValue);
|
|
3749
4132
|
const value = controlled ?? internal;
|
|
3750
|
-
const setValue =
|
|
4133
|
+
const setValue = useCallback6(
|
|
3751
4134
|
(next) => {
|
|
3752
4135
|
if (controlled === void 0) setInternal(next);
|
|
3753
4136
|
onChange?.(next);
|
|
@@ -3787,8 +4170,8 @@ function StnDropdown({
|
|
|
3787
4170
|
const autoId = useId9();
|
|
3788
4171
|
const rootId = idProp ?? `stn-dropdown-${autoId.replace(/:/g, "")}`;
|
|
3789
4172
|
const [value, setValue] = useControllable(valueProp, defaultValue, onChange);
|
|
3790
|
-
const [open, setOpen] =
|
|
3791
|
-
const rootRef =
|
|
4173
|
+
const [open, setOpen] = useState10(false);
|
|
4174
|
+
const rootRef = useRef6(null);
|
|
3792
4175
|
const selected = options.find((o) => o.value === value);
|
|
3793
4176
|
const hasValue = selected !== void 0 && value !== "";
|
|
3794
4177
|
const displayLabel = hasValue ? selected.label : placeholder ?? (options[0]?.label ?? "");
|
|
@@ -3814,10 +4197,10 @@ function StnDropdown({
|
|
|
3814
4197
|
open && "on",
|
|
3815
4198
|
shouldApplyWidthToDropdown && className
|
|
3816
4199
|
);
|
|
3817
|
-
|
|
4200
|
+
useEffect8(() => {
|
|
3818
4201
|
if (disabled || readOnly) setOpen(false);
|
|
3819
4202
|
}, [disabled, readOnly]);
|
|
3820
|
-
|
|
4203
|
+
useEffect8(() => {
|
|
3821
4204
|
if (!open) return;
|
|
3822
4205
|
const onDoc = (e) => {
|
|
3823
4206
|
if (rootRef.current && !rootRef.current.contains(e.target)) setOpen(false);
|
|
@@ -3859,7 +4242,7 @@ function StnDropdown({
|
|
|
3859
4242
|
setValue(enabledOptions[nextIndex].value);
|
|
3860
4243
|
}
|
|
3861
4244
|
};
|
|
3862
|
-
const dropdownNode = /* @__PURE__ */
|
|
4245
|
+
const dropdownNode = /* @__PURE__ */ jsxs27(
|
|
3863
4246
|
"div",
|
|
3864
4247
|
{
|
|
3865
4248
|
ref: rootRef,
|
|
@@ -3871,7 +4254,7 @@ function StnDropdown({
|
|
|
3871
4254
|
"aria-invalid": error || void 0,
|
|
3872
4255
|
...!hasHelper ? divRest : {},
|
|
3873
4256
|
children: [
|
|
3874
|
-
/* @__PURE__ */
|
|
4257
|
+
/* @__PURE__ */ jsx36(
|
|
3875
4258
|
"div",
|
|
3876
4259
|
{
|
|
3877
4260
|
className: cn("selected", !hasValue && placeholder && "is-placeholder"),
|
|
@@ -3888,7 +4271,7 @@ function StnDropdown({
|
|
|
3888
4271
|
children: displayLabel
|
|
3889
4272
|
}
|
|
3890
4273
|
),
|
|
3891
|
-
/* @__PURE__ */
|
|
4274
|
+
/* @__PURE__ */ jsx36(
|
|
3892
4275
|
"ul",
|
|
3893
4276
|
{
|
|
3894
4277
|
className: cn("select_option", "stn-scroll", "vertical", "thin"),
|
|
@@ -3896,7 +4279,7 @@ function StnDropdown({
|
|
|
3896
4279
|
"aria-label": ariaLabel,
|
|
3897
4280
|
children: options.map((opt) => {
|
|
3898
4281
|
const isSelected = opt.value === value;
|
|
3899
|
-
return /* @__PURE__ */
|
|
4282
|
+
return /* @__PURE__ */ jsxs27(
|
|
3900
4283
|
"li",
|
|
3901
4284
|
{
|
|
3902
4285
|
role: "option",
|
|
@@ -3911,15 +4294,15 @@ function StnDropdown({
|
|
|
3911
4294
|
if (e.key === "Enter" && !opt.disabled) pick(opt.value);
|
|
3912
4295
|
},
|
|
3913
4296
|
children: [
|
|
3914
|
-
/* @__PURE__ */
|
|
4297
|
+
/* @__PURE__ */ jsx36(
|
|
3915
4298
|
"span",
|
|
3916
4299
|
{
|
|
3917
4300
|
className: cn("stn-dropdown__check", isSelected && "is-checked"),
|
|
3918
4301
|
"aria-hidden": "true",
|
|
3919
|
-
children: isSelected ? /* @__PURE__ */
|
|
4302
|
+
children: isSelected ? /* @__PURE__ */ jsx36(StnIcon, { name: "line/check", size: 14, color: "currentColor" }) : null
|
|
3920
4303
|
}
|
|
3921
4304
|
),
|
|
3922
|
-
/* @__PURE__ */
|
|
4305
|
+
/* @__PURE__ */ jsx36("span", { className: "stn-dropdown__item-label", children: opt.label })
|
|
3923
4306
|
]
|
|
3924
4307
|
},
|
|
3925
4308
|
opt.value
|
|
@@ -3934,13 +4317,13 @@ function StnDropdown({
|
|
|
3934
4317
|
const hasWrap = hasLabel || hasHelper;
|
|
3935
4318
|
if (!hasWrap) return dropdownNode;
|
|
3936
4319
|
const resolvedLabelIcon = labelIcon ?? icon;
|
|
3937
|
-
const labelElement = hasLabel ? /* @__PURE__ */
|
|
3938
|
-
resolvedLabelIcon ? /* @__PURE__ */
|
|
3939
|
-
/* @__PURE__ */
|
|
3940
|
-
required && /* @__PURE__ */
|
|
4320
|
+
const labelElement = hasLabel ? /* @__PURE__ */ jsxs27("label", { htmlFor: rootId, className: "stn-dropdown__label", children: [
|
|
4321
|
+
resolvedLabelIcon ? /* @__PURE__ */ jsx36("span", { className: "stn-dropdown__label-icon", "aria-hidden": "true", children: resolveGlyph(resolvedLabelIcon) }) : null,
|
|
4322
|
+
/* @__PURE__ */ jsx36("span", { className: "stn-dropdown__label-text", children: label }),
|
|
4323
|
+
required && /* @__PURE__ */ jsx36("span", { className: "stn-dropdown__required", "aria-hidden": "true", children: "*" })
|
|
3941
4324
|
] }) : null;
|
|
3942
4325
|
const isRow = labelPosition === "left" || labelPosition === "right";
|
|
3943
|
-
return /* @__PURE__ */
|
|
4326
|
+
return /* @__PURE__ */ jsxs27(
|
|
3944
4327
|
"div",
|
|
3945
4328
|
{
|
|
3946
4329
|
className: cn(
|
|
@@ -3958,9 +4341,9 @@ function StnDropdown({
|
|
|
3958
4341
|
...divRest,
|
|
3959
4342
|
children: [
|
|
3960
4343
|
hasLabel && (labelPosition === "left" || labelPosition === "top") ? labelElement : null,
|
|
3961
|
-
/* @__PURE__ */
|
|
4344
|
+
/* @__PURE__ */ jsxs27("div", { className: "stn-dropdown-wrap__body", children: [
|
|
3962
4345
|
dropdownNode,
|
|
3963
|
-
hasHelper && /* @__PURE__ */
|
|
4346
|
+
hasHelper && /* @__PURE__ */ jsx36(
|
|
3964
4347
|
"span",
|
|
3965
4348
|
{
|
|
3966
4349
|
id: helperId,
|
|
@@ -3976,12 +4359,12 @@ function StnDropdown({
|
|
|
3976
4359
|
}
|
|
3977
4360
|
|
|
3978
4361
|
// src/components/StnDropdownMenu.tsx
|
|
3979
|
-
import { jsx as
|
|
4362
|
+
import { jsx as jsx37 } from "react/jsx-runtime";
|
|
3980
4363
|
function StnDropdownMenu({
|
|
3981
4364
|
className,
|
|
3982
4365
|
...rest
|
|
3983
4366
|
}) {
|
|
3984
|
-
return /* @__PURE__ */
|
|
4367
|
+
return /* @__PURE__ */ jsx37(
|
|
3985
4368
|
StnDropdown,
|
|
3986
4369
|
{
|
|
3987
4370
|
size: "xl",
|
|
@@ -3992,8 +4375,8 @@ function StnDropdownMenu({
|
|
|
3992
4375
|
}
|
|
3993
4376
|
|
|
3994
4377
|
// src/components/StnTextField.tsx
|
|
3995
|
-
import { forwardRef as
|
|
3996
|
-
import { jsx as
|
|
4378
|
+
import { forwardRef as forwardRef26, useId as useId10 } from "react";
|
|
4379
|
+
import { jsx as jsx38, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
3997
4380
|
function normalizeSize(size) {
|
|
3998
4381
|
if (!size) return "M";
|
|
3999
4382
|
const u = String(size).toUpperCase();
|
|
@@ -4020,10 +4403,10 @@ function colorClass(color) {
|
|
|
4020
4403
|
return color;
|
|
4021
4404
|
}
|
|
4022
4405
|
function resolveGlyph2(node) {
|
|
4023
|
-
if (typeof node === "string") return /* @__PURE__ */
|
|
4406
|
+
if (typeof node === "string") return /* @__PURE__ */ jsx38(StnIcon, { name: node, size: 16, color: "currentColor" });
|
|
4024
4407
|
return node;
|
|
4025
4408
|
}
|
|
4026
|
-
var StnTextField =
|
|
4409
|
+
var StnTextField = forwardRef26(function StnTextField2({
|
|
4027
4410
|
size = "M",
|
|
4028
4411
|
variant = "outlined",
|
|
4029
4412
|
color,
|
|
@@ -4069,7 +4452,7 @@ var StnTextField = forwardRef23(function StnTextField2({
|
|
|
4069
4452
|
hasSlot && "with-icon",
|
|
4070
4453
|
className
|
|
4071
4454
|
);
|
|
4072
|
-
const input = /* @__PURE__ */
|
|
4455
|
+
const input = /* @__PURE__ */ jsx38(
|
|
4073
4456
|
"input",
|
|
4074
4457
|
{
|
|
4075
4458
|
ref,
|
|
@@ -4084,19 +4467,19 @@ var StnTextField = forwardRef23(function StnTextField2({
|
|
|
4084
4467
|
...rest
|
|
4085
4468
|
}
|
|
4086
4469
|
);
|
|
4087
|
-
const field = hasSlot ? /* @__PURE__ */
|
|
4088
|
-
hasLeft ? /* @__PURE__ */
|
|
4470
|
+
const field = hasSlot ? /* @__PURE__ */ jsxs28("div", { className: fieldClass, style: hasWrap ? void 0 : widthProps.style, children: [
|
|
4471
|
+
hasLeft ? /* @__PURE__ */ jsx38("span", { className: "stn-text-field__icon-left", "aria-hidden": true, children: /* @__PURE__ */ jsx38("span", { className: "stn-text-field__icon-box", children: resolveGlyph2(leftNode) }) }) : null,
|
|
4089
4472
|
input,
|
|
4090
|
-
hasRight ? /* @__PURE__ */
|
|
4473
|
+
hasRight ? /* @__PURE__ */ jsx38("span", { className: "stn-text-field__icon-right", "aria-hidden": true, children: /* @__PURE__ */ jsx38("span", { className: "stn-text-field__icon-box", children: resolveGlyph2(rightNode) }) }) : null
|
|
4091
4474
|
] }) : input;
|
|
4092
4475
|
if (!hasWrap) return field;
|
|
4093
|
-
const labelElement = hasLabel ? /* @__PURE__ */
|
|
4094
|
-
labelIcon ? /* @__PURE__ */
|
|
4095
|
-
/* @__PURE__ */
|
|
4096
|
-
required && /* @__PURE__ */
|
|
4476
|
+
const labelElement = hasLabel ? /* @__PURE__ */ jsxs28("label", { htmlFor: id, className: "stn-text-field__label", children: [
|
|
4477
|
+
labelIcon ? /* @__PURE__ */ jsx38("span", { className: "stn-text-field__label-icon", "aria-hidden": "true", children: resolveGlyph2(labelIcon) }) : null,
|
|
4478
|
+
/* @__PURE__ */ jsx38("span", { className: "stn-text-field__label-text", children: label }),
|
|
4479
|
+
required && /* @__PURE__ */ jsx38("span", { className: "stn-text-field__required", "aria-hidden": "true", children: "*" })
|
|
4097
4480
|
] }) : null;
|
|
4098
4481
|
const isRow = labelPosition === "left" || labelPosition === "right";
|
|
4099
|
-
return /* @__PURE__ */
|
|
4482
|
+
return /* @__PURE__ */ jsxs28(
|
|
4100
4483
|
"div",
|
|
4101
4484
|
{
|
|
4102
4485
|
className: cn(
|
|
@@ -4110,9 +4493,9 @@ var StnTextField = forwardRef23(function StnTextField2({
|
|
|
4110
4493
|
style: widthProps.style,
|
|
4111
4494
|
children: [
|
|
4112
4495
|
hasLabel && (labelPosition === "left" || labelPosition === "top") ? labelElement : null,
|
|
4113
|
-
/* @__PURE__ */
|
|
4496
|
+
/* @__PURE__ */ jsxs28("div", { className: "stn-text-field-wrap__body", children: [
|
|
4114
4497
|
field,
|
|
4115
|
-
hasHelper && /* @__PURE__ */
|
|
4498
|
+
hasHelper && /* @__PURE__ */ jsx38(
|
|
4116
4499
|
"p",
|
|
4117
4500
|
{
|
|
4118
4501
|
id: helperId,
|
|
@@ -4129,11 +4512,11 @@ var StnTextField = forwardRef23(function StnTextField2({
|
|
|
4129
4512
|
|
|
4130
4513
|
// src/components/StnTextArea.tsx
|
|
4131
4514
|
import {
|
|
4132
|
-
forwardRef as
|
|
4515
|
+
forwardRef as forwardRef27,
|
|
4133
4516
|
useId as useId11,
|
|
4134
|
-
useState as
|
|
4517
|
+
useState as useState11
|
|
4135
4518
|
} from "react";
|
|
4136
|
-
import { jsx as
|
|
4519
|
+
import { jsx as jsx39, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
4137
4520
|
function normalizeSize2(size) {
|
|
4138
4521
|
return size ?? "md";
|
|
4139
4522
|
}
|
|
@@ -4154,10 +4537,10 @@ function resizeClass(resize) {
|
|
|
4154
4537
|
return "resize-vertical";
|
|
4155
4538
|
}
|
|
4156
4539
|
function resolveGlyph3(node) {
|
|
4157
|
-
if (typeof node === "string") return /* @__PURE__ */
|
|
4540
|
+
if (typeof node === "string") return /* @__PURE__ */ jsx39(StnIcon, { name: node, size: 16, color: "currentColor" });
|
|
4158
4541
|
return node;
|
|
4159
4542
|
}
|
|
4160
|
-
var StnTextArea =
|
|
4543
|
+
var StnTextArea = forwardRef27(function StnTextArea2({
|
|
4161
4544
|
size = "md",
|
|
4162
4545
|
variant = "outlined",
|
|
4163
4546
|
color,
|
|
@@ -4186,7 +4569,7 @@ var StnTextArea = forwardRef24(function StnTextArea2({
|
|
|
4186
4569
|
const autoId = useId11();
|
|
4187
4570
|
const id = idProp ?? autoId;
|
|
4188
4571
|
const isControlled = value !== void 0;
|
|
4189
|
-
const [uncontrolledLength, setUncontrolledLength] =
|
|
4572
|
+
const [uncontrolledLength, setUncontrolledLength] = useState11(() => {
|
|
4190
4573
|
if (defaultValue != null) return String(defaultValue).length;
|
|
4191
4574
|
return 0;
|
|
4192
4575
|
});
|
|
@@ -4214,7 +4597,7 @@ var StnTextArea = forwardRef24(function StnTextArea2({
|
|
|
4214
4597
|
invalid && "invalid",
|
|
4215
4598
|
className
|
|
4216
4599
|
);
|
|
4217
|
-
const textareaElement = /* @__PURE__ */
|
|
4600
|
+
const textareaElement = /* @__PURE__ */ jsx39(
|
|
4218
4601
|
"textarea",
|
|
4219
4602
|
{
|
|
4220
4603
|
ref,
|
|
@@ -4236,13 +4619,13 @@ var StnTextArea = forwardRef24(function StnTextArea2({
|
|
|
4236
4619
|
if (!hasWrap) {
|
|
4237
4620
|
return textareaElement;
|
|
4238
4621
|
}
|
|
4239
|
-
const labelElement = hasLabel ? /* @__PURE__ */
|
|
4240
|
-
labelIcon ? /* @__PURE__ */
|
|
4241
|
-
/* @__PURE__ */
|
|
4242
|
-
required && /* @__PURE__ */
|
|
4622
|
+
const labelElement = hasLabel ? /* @__PURE__ */ jsxs29("label", { htmlFor: id, className: "stn-text-area__label", children: [
|
|
4623
|
+
labelIcon ? /* @__PURE__ */ jsx39("span", { className: "stn-text-area__label-icon", "aria-hidden": "true", children: resolveGlyph3(labelIcon) }) : null,
|
|
4624
|
+
/* @__PURE__ */ jsx39("span", { className: "stn-text-area__label-text", children: label }),
|
|
4625
|
+
required && /* @__PURE__ */ jsx39("span", { className: "stn-text-area__required", "aria-hidden": "true", children: "*" })
|
|
4243
4626
|
] }) : null;
|
|
4244
4627
|
const isRow = labelPosition === "left" || labelPosition === "right";
|
|
4245
|
-
return /* @__PURE__ */
|
|
4628
|
+
return /* @__PURE__ */ jsxs29(
|
|
4246
4629
|
"div",
|
|
4247
4630
|
{
|
|
4248
4631
|
className: cn(
|
|
@@ -4256,18 +4639,18 @@ var StnTextArea = forwardRef24(function StnTextArea2({
|
|
|
4256
4639
|
style: widthProps.style,
|
|
4257
4640
|
children: [
|
|
4258
4641
|
hasLabel && (labelPosition === "left" || labelPosition === "top") ? labelElement : null,
|
|
4259
|
-
/* @__PURE__ */
|
|
4642
|
+
/* @__PURE__ */ jsxs29("div", { className: "stn-text-area-wrap__body", children: [
|
|
4260
4643
|
textareaElement,
|
|
4261
|
-
hasFooter && /* @__PURE__ */
|
|
4262
|
-
hasHelper ? /* @__PURE__ */
|
|
4644
|
+
hasFooter && /* @__PURE__ */ jsxs29("div", { className: "stn-text-area__footer", children: [
|
|
4645
|
+
hasHelper ? /* @__PURE__ */ jsx39(
|
|
4263
4646
|
"p",
|
|
4264
4647
|
{
|
|
4265
4648
|
id: helperId,
|
|
4266
4649
|
className: cn("stn-text-area__helper", invalid && "stn-text-area__helper--error"),
|
|
4267
4650
|
children: helperText
|
|
4268
4651
|
}
|
|
4269
|
-
) : /* @__PURE__ */
|
|
4270
|
-
showCount && /* @__PURE__ */
|
|
4652
|
+
) : /* @__PURE__ */ jsx39("span", {}),
|
|
4653
|
+
showCount && /* @__PURE__ */ jsxs29("span", { className: "stn-text-area__count", children: [
|
|
4271
4654
|
currentLength,
|
|
4272
4655
|
maxLength != null ? ` / ${maxLength}` : ""
|
|
4273
4656
|
] })
|
|
@@ -4281,13 +4664,13 @@ var StnTextArea = forwardRef24(function StnTextArea2({
|
|
|
4281
4664
|
StnTextArea.displayName = "StnTextArea";
|
|
4282
4665
|
|
|
4283
4666
|
// src/components/StnDateRangeField.tsx
|
|
4284
|
-
import { forwardRef as
|
|
4667
|
+
import { forwardRef as forwardRef28, useId as useId12 } from "react";
|
|
4285
4668
|
import {
|
|
4286
4669
|
formatStnDateRangeFieldValue
|
|
4287
4670
|
} from "@stn-uiux/pub-ui/data/stnDateRangeField";
|
|
4288
|
-
import { jsx as
|
|
4671
|
+
import { jsx as jsx40, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
4289
4672
|
function resolveGlyph4(node) {
|
|
4290
|
-
if (typeof node === "string") return /* @__PURE__ */
|
|
4673
|
+
if (typeof node === "string") return /* @__PURE__ */ jsx40(StnIcon, { name: node, size: 16, color: "currentColor" });
|
|
4291
4674
|
return node;
|
|
4292
4675
|
}
|
|
4293
4676
|
function normalizeSize3(size) {
|
|
@@ -4311,7 +4694,7 @@ function resolveValue(value, format) {
|
|
|
4311
4694
|
const trimmed = value.trim();
|
|
4312
4695
|
return trimmed || null;
|
|
4313
4696
|
}
|
|
4314
|
-
var StnDateRangeField =
|
|
4697
|
+
var StnDateRangeField = forwardRef28(function StnDateRangeField2({
|
|
4315
4698
|
size = "md",
|
|
4316
4699
|
variant = "outline",
|
|
4317
4700
|
start,
|
|
@@ -4345,7 +4728,7 @@ var StnDateRangeField = forwardRef25(function StnDateRangeField2({
|
|
|
4345
4728
|
const hasLabel = label != null && label !== "";
|
|
4346
4729
|
const hasHelper = helperText != null && helperText !== "";
|
|
4347
4730
|
const hasWrap = hasLabel || hasHelper;
|
|
4348
|
-
const buttonNode = /* @__PURE__ */
|
|
4731
|
+
const buttonNode = /* @__PURE__ */ jsx40(
|
|
4349
4732
|
"button",
|
|
4350
4733
|
{
|
|
4351
4734
|
ref,
|
|
@@ -4365,25 +4748,25 @@ var StnDateRangeField = forwardRef25(function StnDateRangeField2({
|
|
|
4365
4748
|
),
|
|
4366
4749
|
style: !hasWrap ? widthProps.style ?? style : void 0,
|
|
4367
4750
|
...rest,
|
|
4368
|
-
children: /* @__PURE__ */
|
|
4369
|
-
/* @__PURE__ */
|
|
4370
|
-
/* @__PURE__ */
|
|
4371
|
-
/* @__PURE__ */
|
|
4372
|
-
/* @__PURE__ */
|
|
4751
|
+
children: /* @__PURE__ */ jsxs30("span", { className: "stn-date-range-field__inner", children: [
|
|
4752
|
+
/* @__PURE__ */ jsxs30("span", { className: "stn-date-range-field__text", children: [
|
|
4753
|
+
/* @__PURE__ */ jsx40("span", { className: cn("stn-date-range-field__value", !startText && "is-placeholder"), children: startText ?? startPlaceholder }),
|
|
4754
|
+
/* @__PURE__ */ jsx40("span", { className: "stn-date-range-field__sep", "aria-hidden": "true", children: "~" }),
|
|
4755
|
+
/* @__PURE__ */ jsx40("span", { className: cn("stn-date-range-field__value", !endText && "is-placeholder"), children: endText ?? endPlaceholder })
|
|
4373
4756
|
] }),
|
|
4374
|
-
/* @__PURE__ */
|
|
4757
|
+
/* @__PURE__ */ jsx40("span", { className: "stn-date-range-field__icon", "aria-hidden": "true" })
|
|
4375
4758
|
] })
|
|
4376
4759
|
}
|
|
4377
4760
|
);
|
|
4378
4761
|
if (!hasWrap) return buttonNode;
|
|
4379
4762
|
const resolvedLabelIcon = labelIcon ?? icon;
|
|
4380
|
-
const labelElement = hasLabel ? /* @__PURE__ */
|
|
4381
|
-
resolvedLabelIcon ? /* @__PURE__ */
|
|
4382
|
-
/* @__PURE__ */
|
|
4383
|
-
required && /* @__PURE__ */
|
|
4763
|
+
const labelElement = hasLabel ? /* @__PURE__ */ jsxs30("label", { htmlFor: rootId, className: "stn-date-range-field__label", children: [
|
|
4764
|
+
resolvedLabelIcon ? /* @__PURE__ */ jsx40("span", { className: "stn-date-range-field__label-icon", "aria-hidden": "true", children: resolveGlyph4(resolvedLabelIcon) }) : null,
|
|
4765
|
+
/* @__PURE__ */ jsx40("span", { className: "stn-date-range-field__label-text", children: label }),
|
|
4766
|
+
required && /* @__PURE__ */ jsx40("span", { className: "stn-date-range-field__required", "aria-hidden": "true", children: "*" })
|
|
4384
4767
|
] }) : null;
|
|
4385
4768
|
const isRow = labelPosition === "left" || labelPosition === "right";
|
|
4386
|
-
return /* @__PURE__ */
|
|
4769
|
+
return /* @__PURE__ */ jsxs30(
|
|
4387
4770
|
"div",
|
|
4388
4771
|
{
|
|
4389
4772
|
className: cn(
|
|
@@ -4399,9 +4782,9 @@ var StnDateRangeField = forwardRef25(function StnDateRangeField2({
|
|
|
4399
4782
|
style: widthProps.style ?? style,
|
|
4400
4783
|
children: [
|
|
4401
4784
|
hasLabel && (labelPosition === "left" || labelPosition === "top") ? labelElement : null,
|
|
4402
|
-
/* @__PURE__ */
|
|
4785
|
+
/* @__PURE__ */ jsxs30("div", { className: "stn-date-range-field-wrap__body", children: [
|
|
4403
4786
|
buttonNode,
|
|
4404
|
-
hasHelper && /* @__PURE__ */
|
|
4787
|
+
hasHelper && /* @__PURE__ */ jsx40(
|
|
4405
4788
|
"span",
|
|
4406
4789
|
{
|
|
4407
4790
|
id: `${rootId}-helper`,
|
|
@@ -4422,11 +4805,11 @@ var StnDateRangeField = forwardRef25(function StnDateRangeField2({
|
|
|
4422
4805
|
// src/components/StnLabelPrefix.tsx
|
|
4423
4806
|
import {
|
|
4424
4807
|
useId as useId13,
|
|
4425
|
-
useState as
|
|
4808
|
+
useState as useState12,
|
|
4426
4809
|
isValidElement as isValidElement4,
|
|
4427
4810
|
cloneElement as cloneElement4
|
|
4428
4811
|
} from "react";
|
|
4429
|
-
import { jsx as
|
|
4812
|
+
import { jsx as jsx41, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
4430
4813
|
function sizeClass4(size) {
|
|
4431
4814
|
return size;
|
|
4432
4815
|
}
|
|
@@ -4466,7 +4849,7 @@ function StnLabelPrefix({
|
|
|
4466
4849
|
const isError = error || invalid || color === "error";
|
|
4467
4850
|
const hasHelper = helperText != null && helperText !== "";
|
|
4468
4851
|
const helperId = hasHelper ? `${id}-helper` : void 0;
|
|
4469
|
-
const [internalChecked, setInternalChecked] =
|
|
4852
|
+
const [internalChecked, setInternalChecked] = useState12(defaultChecked ?? false);
|
|
4470
4853
|
const isChecked = checked !== void 0 ? checked : internalChecked;
|
|
4471
4854
|
const handleCheckboxChange = (nextChecked) => {
|
|
4472
4855
|
if (checked === void 0) {
|
|
@@ -4491,7 +4874,7 @@ function StnLabelPrefix({
|
|
|
4491
4874
|
);
|
|
4492
4875
|
const defaultCheckboxSize = size === "lg" ? "md" : "sm";
|
|
4493
4876
|
const resolvedCheckboxSize = checkboxSize ?? defaultCheckboxSize;
|
|
4494
|
-
const checkboxNode = checkboxSlot ?? (checkbox ? /* @__PURE__ */
|
|
4877
|
+
const checkboxNode = checkboxSlot ?? (checkbox ? /* @__PURE__ */ jsx41("span", { className: "stn-label-prefix__checkbox", children: /* @__PURE__ */ jsx41(
|
|
4495
4878
|
StnCheckbox,
|
|
4496
4879
|
{
|
|
4497
4880
|
size: resolvedCheckboxSize,
|
|
@@ -4502,14 +4885,14 @@ function StnLabelPrefix({
|
|
|
4502
4885
|
"aria-label": typeof label === "string" ? `${label} \uC120\uD0DD` : void 0
|
|
4503
4886
|
}
|
|
4504
4887
|
) }) : null);
|
|
4505
|
-
const labelSection = /* @__PURE__ */
|
|
4888
|
+
const labelSection = /* @__PURE__ */ jsxs31("span", { className: "stn-label-prefix__label", children: [
|
|
4506
4889
|
checkboxNode,
|
|
4507
|
-
labelIcon != null && /* @__PURE__ */
|
|
4508
|
-
/* @__PURE__ */
|
|
4890
|
+
labelIcon != null && /* @__PURE__ */ jsx41("span", { className: "stn-label-prefix__icon", "aria-hidden": "true", children: labelIcon }),
|
|
4891
|
+
/* @__PURE__ */ jsxs31("span", { className: "stn-label-prefix__text", children: [
|
|
4509
4892
|
label,
|
|
4510
|
-
required && /* @__PURE__ */
|
|
4893
|
+
required && /* @__PURE__ */ jsx41("span", { className: "stn-label-prefix__required", "aria-hidden": "true", children: "*" })
|
|
4511
4894
|
] }),
|
|
4512
|
-
/* @__PURE__ */
|
|
4895
|
+
/* @__PURE__ */ jsx41("span", { className: "stn-label-prefix__divider", "aria-hidden": "true" })
|
|
4513
4896
|
] });
|
|
4514
4897
|
let renderedControl = children;
|
|
4515
4898
|
if (isControlDisabled && isValidElement4(children) && typeof children.type !== "string") {
|
|
@@ -4517,7 +4900,7 @@ function StnLabelPrefix({
|
|
|
4517
4900
|
disabled: true
|
|
4518
4901
|
});
|
|
4519
4902
|
}
|
|
4520
|
-
const prefixNode = /* @__PURE__ */
|
|
4903
|
+
const prefixNode = /* @__PURE__ */ jsxs31(
|
|
4521
4904
|
"div",
|
|
4522
4905
|
{
|
|
4523
4906
|
id: !hasHelper ? id : void 0,
|
|
@@ -4529,14 +4912,14 @@ function StnLabelPrefix({
|
|
|
4529
4912
|
...!hasHelper ? rest : {},
|
|
4530
4913
|
children: [
|
|
4531
4914
|
labelSection,
|
|
4532
|
-
/* @__PURE__ */
|
|
4915
|
+
/* @__PURE__ */ jsx41("span", { className: "stn-label-prefix__control", children: renderedControl })
|
|
4533
4916
|
]
|
|
4534
4917
|
}
|
|
4535
4918
|
);
|
|
4536
4919
|
if (!hasHelper) {
|
|
4537
4920
|
return prefixNode;
|
|
4538
4921
|
}
|
|
4539
|
-
return /* @__PURE__ */
|
|
4922
|
+
return /* @__PURE__ */ jsxs31(
|
|
4540
4923
|
"div",
|
|
4541
4924
|
{
|
|
4542
4925
|
id,
|
|
@@ -4550,7 +4933,7 @@ function StnLabelPrefix({
|
|
|
4550
4933
|
...rest,
|
|
4551
4934
|
children: [
|
|
4552
4935
|
prefixNode,
|
|
4553
|
-
/* @__PURE__ */
|
|
4936
|
+
/* @__PURE__ */ jsx41(
|
|
4554
4937
|
"p",
|
|
4555
4938
|
{
|
|
4556
4939
|
id: helperId,
|
|
@@ -4616,14 +4999,14 @@ import {
|
|
|
4616
4999
|
} from "@stn-uiux/pub-ui/data/stnSearchRequirement";
|
|
4617
5000
|
|
|
4618
5001
|
// src/patterns/search/StnSearchRequirementBar.tsx
|
|
4619
|
-
import { jsx as
|
|
5002
|
+
import { jsx as jsx42, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
4620
5003
|
function StnSearchRequirementBar({
|
|
4621
5004
|
children,
|
|
4622
5005
|
className,
|
|
4623
5006
|
density = "default",
|
|
4624
5007
|
...rest
|
|
4625
5008
|
}) {
|
|
4626
|
-
return /* @__PURE__ */
|
|
5009
|
+
return /* @__PURE__ */ jsx42(
|
|
4627
5010
|
"div",
|
|
4628
5011
|
{
|
|
4629
5012
|
className: cn(
|
|
@@ -4639,7 +5022,7 @@ function StnSearchRequirementBar({
|
|
|
4639
5022
|
);
|
|
4640
5023
|
}
|
|
4641
5024
|
function StnSearchRequirementBarFields({ children, className, ...rest }) {
|
|
4642
|
-
return /* @__PURE__ */
|
|
5025
|
+
return /* @__PURE__ */ jsx42("div", { className: cn("stn-search-requirement__fields", className), "data-stn-search-requirement": "fields", ...rest, children });
|
|
4643
5026
|
}
|
|
4644
5027
|
function StnSearchRequirementBarField({
|
|
4645
5028
|
label,
|
|
@@ -4649,20 +5032,20 @@ function StnSearchRequirementBarField({
|
|
|
4649
5032
|
controlClassName,
|
|
4650
5033
|
...rest
|
|
4651
5034
|
}) {
|
|
4652
|
-
return /* @__PURE__ */
|
|
4653
|
-
/* @__PURE__ */
|
|
4654
|
-
/* @__PURE__ */
|
|
5035
|
+
return /* @__PURE__ */ jsxs32("div", { className: cn("stn-search-requirement__field", className), "data-stn-search-requirement": "field", ...rest, children: [
|
|
5036
|
+
/* @__PURE__ */ jsx42("span", { className: cn("stn-search-requirement__label", labelClassName), children: label }),
|
|
5037
|
+
/* @__PURE__ */ jsx42("div", { className: cn("stn-search-requirement__control", controlClassName), children })
|
|
4655
5038
|
] });
|
|
4656
5039
|
}
|
|
4657
5040
|
function StnSearchRequirementBarSearchButton({
|
|
4658
5041
|
children = "\uAC80\uC0C9",
|
|
4659
5042
|
size = "md",
|
|
4660
5043
|
variant = "outlined",
|
|
4661
|
-
icon = /* @__PURE__ */
|
|
5044
|
+
icon = /* @__PURE__ */ jsx42(StnIcon, { name: "line/search", size: 16, color: "currentColor" }),
|
|
4662
5045
|
className,
|
|
4663
5046
|
...rest
|
|
4664
5047
|
}) {
|
|
4665
|
-
return /* @__PURE__ */
|
|
5048
|
+
return /* @__PURE__ */ jsx42(
|
|
4666
5049
|
StnButton,
|
|
4667
5050
|
{
|
|
4668
5051
|
size,
|
|
@@ -4684,10 +5067,10 @@ function StnSearchRequirementBarExport({
|
|
|
4684
5067
|
"aria-label": ariaLabel = "Excel\uBCF4\uB0B4\uAE30",
|
|
4685
5068
|
...rest
|
|
4686
5069
|
}) {
|
|
4687
|
-
return /* @__PURE__ */
|
|
5070
|
+
return /* @__PURE__ */ jsx42(
|
|
4688
5071
|
StnButton,
|
|
4689
5072
|
{
|
|
4690
|
-
icon: icon ?? /* @__PURE__ */
|
|
5073
|
+
icon: icon ?? /* @__PURE__ */ jsx42(StnIcon, { name, size: 24, color: "currentColor" }),
|
|
4691
5074
|
variant,
|
|
4692
5075
|
size,
|
|
4693
5076
|
"aria-label": ariaLabel,
|
|
@@ -4698,7 +5081,7 @@ function StnSearchRequirementBarExport({
|
|
|
4698
5081
|
);
|
|
4699
5082
|
}
|
|
4700
5083
|
function StnSearchRequirementBarDivider({ className, ...rest }) {
|
|
4701
|
-
return /* @__PURE__ */
|
|
5084
|
+
return /* @__PURE__ */ jsx42(
|
|
4702
5085
|
"span",
|
|
4703
5086
|
{
|
|
4704
5087
|
className: cn("stn-search-requirement__divider", className),
|
|
@@ -4720,17 +5103,17 @@ import { STN_SEARCH_REQUIREMENT_DEMO_FIELDS } from "@stn-uiux/pub-ui/data/stnSea
|
|
|
4720
5103
|
|
|
4721
5104
|
// src/components/datePicker/StnDateRangePickerField.tsx
|
|
4722
5105
|
import {
|
|
4723
|
-
useCallback as
|
|
4724
|
-
useEffect as
|
|
4725
|
-
useLayoutEffect,
|
|
4726
|
-
useRef as
|
|
4727
|
-
useState as
|
|
5106
|
+
useCallback as useCallback8,
|
|
5107
|
+
useEffect as useEffect10,
|
|
5108
|
+
useLayoutEffect as useLayoutEffect2,
|
|
5109
|
+
useRef as useRef7,
|
|
5110
|
+
useState as useState14
|
|
4728
5111
|
} from "react";
|
|
4729
5112
|
import { createPortal as createPortal2 } from "react-dom";
|
|
4730
5113
|
import { formatStnDateRangeFieldValue as formatStnDateRangeFieldValue2 } from "@stn-uiux/pub-ui/data/stnDateRangeField";
|
|
4731
5114
|
|
|
4732
5115
|
// src/components/datePicker/StnDateRangePicker.tsx
|
|
4733
|
-
import { useCallback as
|
|
5116
|
+
import { useCallback as useCallback7, useEffect as useEffect9, useId as useId14, useMemo as useMemo3, useState as useState13 } from "react";
|
|
4734
5117
|
import {
|
|
4735
5118
|
STN_DATE_PICKER_WEEKDAYS
|
|
4736
5119
|
} from "@stn-uiux/pub-ui/data/stnDatePicker";
|
|
@@ -4790,10 +5173,10 @@ function normalizeRange(start, end) {
|
|
|
4790
5173
|
}
|
|
4791
5174
|
|
|
4792
5175
|
// src/components/datePicker/StnDateRangePicker.tsx
|
|
4793
|
-
import { jsx as
|
|
5176
|
+
import { jsx as jsx43, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
4794
5177
|
function useDraftRange(value, open) {
|
|
4795
|
-
const [draft, setDraft] =
|
|
4796
|
-
|
|
5178
|
+
const [draft, setDraft] = useState13(value);
|
|
5179
|
+
useEffect9(() => {
|
|
4797
5180
|
if (open) setDraft(value);
|
|
4798
5181
|
}, [open, value]);
|
|
4799
5182
|
return [draft, setDraft];
|
|
@@ -4801,19 +5184,19 @@ function useDraftRange(value, open) {
|
|
|
4801
5184
|
function CalendarPanel({ month, range, onPick, onPrev, onNext, showPrev = true, showNext = true }) {
|
|
4802
5185
|
const days = useMemo3(() => buildMonthGrid(month), [month]);
|
|
4803
5186
|
const { start, end } = range;
|
|
4804
|
-
return /* @__PURE__ */
|
|
4805
|
-
/* @__PURE__ */
|
|
4806
|
-
showPrev ? /* @__PURE__ */
|
|
4807
|
-
/* @__PURE__ */
|
|
4808
|
-
showNext ? /* @__PURE__ */
|
|
5187
|
+
return /* @__PURE__ */ jsxs33("div", { className: "stn-date-picker-panel", children: [
|
|
5188
|
+
/* @__PURE__ */ jsxs33("div", { className: "stn-date-picker-panel__header", children: [
|
|
5189
|
+
showPrev ? /* @__PURE__ */ jsx43("button", { type: "button", className: "stn-date-picker-panel__nav", onClick: onPrev, "aria-label": "Previous month", children: "\u2039" }) : /* @__PURE__ */ jsx43("span", { className: "stn-date-picker-panel__nav", "aria-hidden": "true" }),
|
|
5190
|
+
/* @__PURE__ */ jsx43("p", { className: "stn-date-picker-panel__title", children: formatMonthTitle(month) }),
|
|
5191
|
+
showNext ? /* @__PURE__ */ jsx43("button", { type: "button", className: "stn-date-picker-panel__nav", onClick: onNext, "aria-label": "Next month", children: "\u203A" }) : /* @__PURE__ */ jsx43("span", { className: "stn-date-picker-panel__nav", "aria-hidden": "true" })
|
|
4809
5192
|
] }),
|
|
4810
|
-
/* @__PURE__ */
|
|
4811
|
-
/* @__PURE__ */
|
|
4812
|
-
/* @__PURE__ */
|
|
5193
|
+
/* @__PURE__ */ jsxs33("table", { className: "stn-date-picker-content", children: [
|
|
5194
|
+
/* @__PURE__ */ jsx43("thead", { children: /* @__PURE__ */ jsx43("tr", { children: STN_DATE_PICKER_WEEKDAYS.map((label) => /* @__PURE__ */ jsx43("th", { scope: "col", children: label }, label)) }) }),
|
|
5195
|
+
/* @__PURE__ */ jsx43("tbody", { children: Array.from({ length: 6 }, (_, row) => /* @__PURE__ */ jsx43("tr", { children: days.slice(row * 7, row * 7 + 7).map((cell) => {
|
|
4813
5196
|
const inRange = start && end && isBetweenDays(cell.date, start, end);
|
|
4814
5197
|
const isStart = start ? isSameDay(cell.date, start) : false;
|
|
4815
5198
|
const isEnd = end ? isSameDay(cell.date, end) : false;
|
|
4816
|
-
return /* @__PURE__ */
|
|
5199
|
+
return /* @__PURE__ */ jsx43(
|
|
4817
5200
|
"td",
|
|
4818
5201
|
{
|
|
4819
5202
|
className: cn(
|
|
@@ -4823,7 +5206,7 @@ function CalendarPanel({ month, range, onPick, onPrev, onNext, showPrev = true,
|
|
|
4823
5206
|
isStart && "stn-date-picker-cell--range-start",
|
|
4824
5207
|
isEnd && "stn-date-picker-cell--range-end"
|
|
4825
5208
|
),
|
|
4826
|
-
children: /* @__PURE__ */
|
|
5209
|
+
children: /* @__PURE__ */ jsx43(
|
|
4827
5210
|
"button",
|
|
4828
5211
|
{
|
|
4829
5212
|
type: "button",
|
|
@@ -4845,16 +5228,16 @@ function TimeColumns({ label, value, onChange }) {
|
|
|
4845
5228
|
const seconds = value?.getSeconds() ?? 0;
|
|
4846
5229
|
const base = value ?? /* @__PURE__ */ new Date();
|
|
4847
5230
|
const patch = (h, m, s) => onChange(setTimePart(base, h, m, s));
|
|
4848
|
-
return /* @__PURE__ */
|
|
4849
|
-
/* @__PURE__ */
|
|
4850
|
-
/* @__PURE__ */
|
|
4851
|
-
/* @__PURE__ */
|
|
5231
|
+
return /* @__PURE__ */ jsxs33("div", { className: "stn-date-picker-time__side", children: [
|
|
5232
|
+
/* @__PURE__ */ jsx43("span", { className: "stn-date-picker-time__label", children: label }),
|
|
5233
|
+
/* @__PURE__ */ jsxs33("div", { className: "stn-date-picker-time__columns", children: [
|
|
5234
|
+
/* @__PURE__ */ jsx43(
|
|
4852
5235
|
StnScroll,
|
|
4853
5236
|
{
|
|
4854
5237
|
variant: "arrows",
|
|
4855
5238
|
size: "thin",
|
|
4856
5239
|
className: "stn-date-picker-time__scroll",
|
|
4857
|
-
children: /* @__PURE__ */
|
|
5240
|
+
children: /* @__PURE__ */ jsx43("ul", { className: "stn-date-picker-time__column", "aria-label": `${label} hour`, children: Array.from({ length: 24 }, (_, h) => /* @__PURE__ */ jsx43("li", { children: /* @__PURE__ */ jsx43(
|
|
4858
5241
|
"button",
|
|
4859
5242
|
{
|
|
4860
5243
|
type: "button",
|
|
@@ -4865,13 +5248,13 @@ function TimeColumns({ label, value, onChange }) {
|
|
|
4865
5248
|
) }, h)) })
|
|
4866
5249
|
}
|
|
4867
5250
|
),
|
|
4868
|
-
/* @__PURE__ */
|
|
5251
|
+
/* @__PURE__ */ jsx43(
|
|
4869
5252
|
StnScroll,
|
|
4870
5253
|
{
|
|
4871
5254
|
variant: "arrows",
|
|
4872
5255
|
size: "thin",
|
|
4873
5256
|
className: "stn-date-picker-time__scroll",
|
|
4874
|
-
children: /* @__PURE__ */
|
|
5257
|
+
children: /* @__PURE__ */ jsx43("ul", { className: "stn-date-picker-time__column", "aria-label": `${label} minute`, children: Array.from({ length: 60 }, (_, m) => /* @__PURE__ */ jsx43("li", { children: /* @__PURE__ */ jsx43(
|
|
4875
5258
|
"button",
|
|
4876
5259
|
{
|
|
4877
5260
|
type: "button",
|
|
@@ -4882,13 +5265,13 @@ function TimeColumns({ label, value, onChange }) {
|
|
|
4882
5265
|
) }, m)) })
|
|
4883
5266
|
}
|
|
4884
5267
|
),
|
|
4885
|
-
/* @__PURE__ */
|
|
5268
|
+
/* @__PURE__ */ jsx43(
|
|
4886
5269
|
StnScroll,
|
|
4887
5270
|
{
|
|
4888
5271
|
variant: "arrows",
|
|
4889
5272
|
size: "thin",
|
|
4890
5273
|
className: "stn-date-picker-time__scroll",
|
|
4891
|
-
children: /* @__PURE__ */
|
|
5274
|
+
children: /* @__PURE__ */ jsx43("ul", { className: "stn-date-picker-time__column", "aria-label": `${label} second`, children: Array.from({ length: 60 }, (_, s) => /* @__PURE__ */ jsx43("li", { children: /* @__PURE__ */ jsx43(
|
|
4892
5275
|
"button",
|
|
4893
5276
|
{
|
|
4894
5277
|
type: "button",
|
|
@@ -4915,21 +5298,21 @@ function StnDateRangePicker({
|
|
|
4915
5298
|
}) {
|
|
4916
5299
|
const titleId = useId14();
|
|
4917
5300
|
const [draft, setDraft] = useDraftRange(value, open);
|
|
4918
|
-
const [leftMonth, setLeftMonth] =
|
|
4919
|
-
|
|
5301
|
+
const [leftMonth, setLeftMonth] = useState13(() => startOfMonth(draft.start ?? draft.end ?? /* @__PURE__ */ new Date()));
|
|
5302
|
+
useEffect9(() => {
|
|
4920
5303
|
if (!open) return;
|
|
4921
5304
|
const anchor = draft.start ?? draft.end ?? /* @__PURE__ */ new Date();
|
|
4922
5305
|
setLeftMonth(startOfMonth(anchor));
|
|
4923
5306
|
}, [open, draft.start, draft.end]);
|
|
4924
5307
|
const rightMonth = useMemo3(() => addMonths(leftMonth, 1), [leftMonth]);
|
|
4925
|
-
const updateDraft =
|
|
5308
|
+
const updateDraft = useCallback7(
|
|
4926
5309
|
(next) => {
|
|
4927
5310
|
setDraft(next);
|
|
4928
5311
|
onChange?.(next);
|
|
4929
5312
|
},
|
|
4930
5313
|
[onChange]
|
|
4931
5314
|
);
|
|
4932
|
-
const pickDay =
|
|
5315
|
+
const pickDay = useCallback7(
|
|
4933
5316
|
(day) => {
|
|
4934
5317
|
const nextStart = cloneDate(day);
|
|
4935
5318
|
if (!showTime) {
|
|
@@ -4967,7 +5350,7 @@ function StnDateRangePicker({
|
|
|
4967
5350
|
left: anchorRect.left,
|
|
4968
5351
|
...style
|
|
4969
5352
|
} : style ?? {};
|
|
4970
|
-
return /* @__PURE__ */
|
|
5353
|
+
return /* @__PURE__ */ jsx43(
|
|
4971
5354
|
"div",
|
|
4972
5355
|
{
|
|
4973
5356
|
className: cn("stn-date-picker-dropdown", className),
|
|
@@ -4975,10 +5358,10 @@ function StnDateRangePicker({
|
|
|
4975
5358
|
role: "dialog",
|
|
4976
5359
|
"aria-modal": "false",
|
|
4977
5360
|
"aria-labelledby": titleId,
|
|
4978
|
-
children: /* @__PURE__ */
|
|
4979
|
-
/* @__PURE__ */
|
|
4980
|
-
/* @__PURE__ */
|
|
4981
|
-
/* @__PURE__ */
|
|
5361
|
+
children: /* @__PURE__ */ jsxs33("div", { className: "stn-date-picker-dropdown__body", children: [
|
|
5362
|
+
/* @__PURE__ */ jsx43("span", { id: titleId, className: "stn-sf__visually-hidden", children: "Date range picker" }),
|
|
5363
|
+
/* @__PURE__ */ jsxs33("div", { className: "stn-date-picker-dropdown__panels", children: [
|
|
5364
|
+
/* @__PURE__ */ jsx43(
|
|
4982
5365
|
CalendarPanel,
|
|
4983
5366
|
{
|
|
4984
5367
|
month: leftMonth,
|
|
@@ -4989,7 +5372,7 @@ function StnDateRangePicker({
|
|
|
4989
5372
|
showNext: false
|
|
4990
5373
|
}
|
|
4991
5374
|
),
|
|
4992
|
-
/* @__PURE__ */
|
|
5375
|
+
/* @__PURE__ */ jsx43(
|
|
4993
5376
|
CalendarPanel,
|
|
4994
5377
|
{
|
|
4995
5378
|
month: rightMonth,
|
|
@@ -5001,8 +5384,8 @@ function StnDateRangePicker({
|
|
|
5001
5384
|
}
|
|
5002
5385
|
)
|
|
5003
5386
|
] }),
|
|
5004
|
-
showTime ? /* @__PURE__ */
|
|
5005
|
-
/* @__PURE__ */
|
|
5387
|
+
showTime ? /* @__PURE__ */ jsxs33("div", { className: "stn-date-picker-time", children: [
|
|
5388
|
+
/* @__PURE__ */ jsx43(
|
|
5006
5389
|
TimeColumns,
|
|
5007
5390
|
{
|
|
5008
5391
|
label: "\uC2DC\uC791",
|
|
@@ -5010,7 +5393,7 @@ function StnDateRangePicker({
|
|
|
5010
5393
|
onChange: (start) => updateDraft({ ...draft, start })
|
|
5011
5394
|
}
|
|
5012
5395
|
),
|
|
5013
|
-
/* @__PURE__ */
|
|
5396
|
+
/* @__PURE__ */ jsx43(
|
|
5014
5397
|
TimeColumns,
|
|
5015
5398
|
{
|
|
5016
5399
|
label: "\uC885\uB8CC",
|
|
@@ -5019,18 +5402,18 @@ function StnDateRangePicker({
|
|
|
5019
5402
|
}
|
|
5020
5403
|
)
|
|
5021
5404
|
] }) : null,
|
|
5022
|
-
/* @__PURE__ */
|
|
5405
|
+
/* @__PURE__ */ jsx43("div", { className: "stn-date-picker-footer", children: /* @__PURE__ */ jsx43(StnButton, { size: "md", variant: "contained", onClick: handleApply, disabled: !draft.start || !draft.end, children: "\uD655\uC778" }) })
|
|
5023
5406
|
] })
|
|
5024
5407
|
}
|
|
5025
5408
|
);
|
|
5026
5409
|
}
|
|
5027
5410
|
|
|
5028
5411
|
// src/components/datePicker/StnDateRangePickerField.tsx
|
|
5029
|
-
import { jsx as
|
|
5412
|
+
import { jsx as jsx44, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
5030
5413
|
function useControllableRange(controlled, defaultValue, onChange) {
|
|
5031
|
-
const [internal, setInternal] =
|
|
5414
|
+
const [internal, setInternal] = useState14(defaultValue);
|
|
5032
5415
|
const value = controlled ?? internal;
|
|
5033
|
-
const setValue =
|
|
5416
|
+
const setValue = useCallback8(
|
|
5034
5417
|
(next) => {
|
|
5035
5418
|
if (controlled === void 0) setInternal(next);
|
|
5036
5419
|
onChange?.(next);
|
|
@@ -5060,15 +5443,15 @@ function StnDateRangePickerField({
|
|
|
5060
5443
|
}) {
|
|
5061
5444
|
const format = formatProp ?? (showTime ? formatStnDateRangeFieldValue2 : formatDateOnly);
|
|
5062
5445
|
const [value, setValue] = useControllableRange(valueProp, defaultValue, onChange);
|
|
5063
|
-
const [open, setOpen] =
|
|
5064
|
-
const [anchorRect, setAnchorRect] =
|
|
5065
|
-
const rootRef =
|
|
5066
|
-
const triggerRef =
|
|
5067
|
-
const panelRef =
|
|
5068
|
-
const updateAnchor =
|
|
5446
|
+
const [open, setOpen] = useState14(false);
|
|
5447
|
+
const [anchorRect, setAnchorRect] = useState14(null);
|
|
5448
|
+
const rootRef = useRef7(null);
|
|
5449
|
+
const triggerRef = useRef7(null);
|
|
5450
|
+
const panelRef = useRef7(null);
|
|
5451
|
+
const updateAnchor = useCallback8(() => {
|
|
5069
5452
|
setAnchorRect(triggerRef.current?.getBoundingClientRect() ?? null);
|
|
5070
5453
|
}, []);
|
|
5071
|
-
|
|
5454
|
+
useLayoutEffect2(() => {
|
|
5072
5455
|
if (!open) return;
|
|
5073
5456
|
updateAnchor();
|
|
5074
5457
|
const onReflow = () => updateAnchor();
|
|
@@ -5079,7 +5462,7 @@ function StnDateRangePickerField({
|
|
|
5079
5462
|
window.removeEventListener("scroll", onReflow, true);
|
|
5080
5463
|
};
|
|
5081
5464
|
}, [open, updateAnchor]);
|
|
5082
|
-
|
|
5465
|
+
useEffect10(() => {
|
|
5083
5466
|
if (!open) return;
|
|
5084
5467
|
const onDocMouseDown = (event) => {
|
|
5085
5468
|
const target = event.target;
|
|
@@ -5090,7 +5473,7 @@ function StnDateRangePickerField({
|
|
|
5090
5473
|
document.addEventListener("mousedown", onDocMouseDown);
|
|
5091
5474
|
return () => document.removeEventListener("mousedown", onDocMouseDown);
|
|
5092
5475
|
}, [open]);
|
|
5093
|
-
|
|
5476
|
+
useEffect10(() => {
|
|
5094
5477
|
if (!open) return;
|
|
5095
5478
|
const onKeyDown = (event) => {
|
|
5096
5479
|
if (event.key === "Escape") setOpen(false);
|
|
@@ -5098,8 +5481,8 @@ function StnDateRangePickerField({
|
|
|
5098
5481
|
document.addEventListener("keydown", onKeyDown);
|
|
5099
5482
|
return () => document.removeEventListener("keydown", onKeyDown);
|
|
5100
5483
|
}, [open]);
|
|
5101
|
-
return /* @__PURE__ */
|
|
5102
|
-
/* @__PURE__ */
|
|
5484
|
+
return /* @__PURE__ */ jsxs34("div", { ref: rootRef, className: cn("stn-date-picker-field", className), children: [
|
|
5485
|
+
/* @__PURE__ */ jsx44(
|
|
5103
5486
|
StnDateRangeField,
|
|
5104
5487
|
{
|
|
5105
5488
|
ref: triggerRef,
|
|
@@ -5119,7 +5502,7 @@ function StnDateRangePickerField({
|
|
|
5119
5502
|
}
|
|
5120
5503
|
),
|
|
5121
5504
|
open && typeof document !== "undefined" ? createPortal2(
|
|
5122
|
-
/* @__PURE__ */
|
|
5505
|
+
/* @__PURE__ */ jsx44("div", { ref: panelRef, children: /* @__PURE__ */ jsx44(
|
|
5123
5506
|
StnDateRangePicker,
|
|
5124
5507
|
{
|
|
5125
5508
|
open: true,
|
|
@@ -5138,13 +5521,13 @@ function StnDateRangePickerField({
|
|
|
5138
5521
|
}
|
|
5139
5522
|
|
|
5140
5523
|
// src/patterns/search/StnSearchRequirementBarDemo.tsx
|
|
5141
|
-
import { jsx as
|
|
5524
|
+
import { jsx as jsx45, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
5142
5525
|
var ALL_OPTIONS = [{ value: "", label: "\uC804\uCCB4" }];
|
|
5143
5526
|
function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
5144
5527
|
const demo = STN_SEARCH_REQUIREMENT_DEMO_FIELDS;
|
|
5145
|
-
return /* @__PURE__ */
|
|
5146
|
-
/* @__PURE__ */
|
|
5147
|
-
/* @__PURE__ */
|
|
5528
|
+
return /* @__PURE__ */ jsxs35(StnSearchRequirementBar, { className, children: [
|
|
5529
|
+
/* @__PURE__ */ jsxs35(StnSearchRequirementBar.Fields, { children: [
|
|
5530
|
+
/* @__PURE__ */ jsx45(
|
|
5148
5531
|
StnTextField,
|
|
5149
5532
|
{
|
|
5150
5533
|
label: demo.reportTypeText.label,
|
|
@@ -5154,7 +5537,7 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5154
5537
|
"aria-label": demo.reportTypeText.label
|
|
5155
5538
|
}
|
|
5156
5539
|
),
|
|
5157
|
-
/* @__PURE__ */
|
|
5540
|
+
/* @__PURE__ */ jsx45(
|
|
5158
5541
|
StnDropdown,
|
|
5159
5542
|
{
|
|
5160
5543
|
label: demo.reportTypeSelect.label,
|
|
@@ -5165,7 +5548,7 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5165
5548
|
"aria-label": demo.reportTypeSelect.label
|
|
5166
5549
|
}
|
|
5167
5550
|
),
|
|
5168
|
-
/* @__PURE__ */
|
|
5551
|
+
/* @__PURE__ */ jsx45(
|
|
5169
5552
|
StnDropdown,
|
|
5170
5553
|
{
|
|
5171
5554
|
label: demo.periodType.label,
|
|
@@ -5176,7 +5559,7 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5176
5559
|
"aria-label": demo.periodType.label
|
|
5177
5560
|
}
|
|
5178
5561
|
),
|
|
5179
|
-
/* @__PURE__ */
|
|
5562
|
+
/* @__PURE__ */ jsx45(
|
|
5180
5563
|
StnDateRangePickerField,
|
|
5181
5564
|
{
|
|
5182
5565
|
label: demo.period.label,
|
|
@@ -5190,8 +5573,8 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5190
5573
|
}
|
|
5191
5574
|
)
|
|
5192
5575
|
] }),
|
|
5193
|
-
/* @__PURE__ */
|
|
5194
|
-
/* @__PURE__ */
|
|
5576
|
+
/* @__PURE__ */ jsx45(StnSearchRequirementBar.SearchButton, { onClick: onSearch }),
|
|
5577
|
+
/* @__PURE__ */ jsx45(StnSearchRequirementBar.Export, { onClick: onExport })
|
|
5195
5578
|
] });
|
|
5196
5579
|
}
|
|
5197
5580
|
|
|
@@ -5205,7 +5588,7 @@ import {
|
|
|
5205
5588
|
} from "@stn-uiux/pub-ui/data/stnHeader";
|
|
5206
5589
|
|
|
5207
5590
|
// src/patterns/header/StnHeader.tsx
|
|
5208
|
-
import { jsx as
|
|
5591
|
+
import { jsx as jsx46 } from "react/jsx-runtime";
|
|
5209
5592
|
function variantClass6(variant) {
|
|
5210
5593
|
if (variant === "page") return "stn-header--page";
|
|
5211
5594
|
return void 0;
|
|
@@ -5232,7 +5615,7 @@ function StnHeader({
|
|
|
5232
5615
|
...dynamicStyles,
|
|
5233
5616
|
...style
|
|
5234
5617
|
};
|
|
5235
|
-
return /* @__PURE__ */
|
|
5618
|
+
return /* @__PURE__ */ jsx46(
|
|
5236
5619
|
"header",
|
|
5237
5620
|
{
|
|
5238
5621
|
className: cn(
|
|
@@ -5250,20 +5633,20 @@ function StnHeader({
|
|
|
5250
5633
|
);
|
|
5251
5634
|
}
|
|
5252
5635
|
function StnHeaderLeft({ children, className, ...rest }) {
|
|
5253
|
-
return /* @__PURE__ */
|
|
5636
|
+
return /* @__PURE__ */ jsx46("div", { className: cn("stn-header__left", className), "data-stn-header-region": "left", ...rest, children });
|
|
5254
5637
|
}
|
|
5255
5638
|
function StnHeaderCenter({ children, className, ...rest }) {
|
|
5256
|
-
return /* @__PURE__ */
|
|
5639
|
+
return /* @__PURE__ */ jsx46("div", { className: cn("stn-header__center", className), "data-stn-header-region": "center", ...rest, children });
|
|
5257
5640
|
}
|
|
5258
5641
|
function StnHeaderRight({ children, className, ...rest }) {
|
|
5259
|
-
return /* @__PURE__ */
|
|
5642
|
+
return /* @__PURE__ */ jsx46("div", { className: cn("stn-header__right", className), "data-stn-header-region": "right", ...rest, children });
|
|
5260
5643
|
}
|
|
5261
5644
|
StnHeader.Left = StnHeaderLeft;
|
|
5262
5645
|
StnHeader.Center = StnHeaderCenter;
|
|
5263
5646
|
StnHeader.Right = StnHeaderRight;
|
|
5264
5647
|
function StnHeaderPageTitle({ children, className, title, ...rest }) {
|
|
5265
5648
|
const autoTitle = typeof children === "string" ? children : void 0;
|
|
5266
|
-
return /* @__PURE__ */
|
|
5649
|
+
return /* @__PURE__ */ jsx46(
|
|
5267
5650
|
"h1",
|
|
5268
5651
|
{
|
|
5269
5652
|
className: cn("stn-header__page-title", className),
|
|
@@ -5275,7 +5658,7 @@ function StnHeaderPageTitle({ children, className, title, ...rest }) {
|
|
|
5275
5658
|
}
|
|
5276
5659
|
function StnHeaderSubTitle({ children, className, title, ...rest }) {
|
|
5277
5660
|
const autoTitle = typeof children === "string" ? children : void 0;
|
|
5278
|
-
return /* @__PURE__ */
|
|
5661
|
+
return /* @__PURE__ */ jsx46(
|
|
5279
5662
|
"span",
|
|
5280
5663
|
{
|
|
5281
5664
|
className: cn("stn-header__subtitle", className),
|
|
@@ -5287,7 +5670,7 @@ function StnHeaderSubTitle({ children, className, title, ...rest }) {
|
|
|
5287
5670
|
}
|
|
5288
5671
|
function StnHeaderContextTitle({ children, className, title, ...rest }) {
|
|
5289
5672
|
const autoTitle = typeof children === "string" ? children : void 0;
|
|
5290
|
-
return /* @__PURE__ */
|
|
5673
|
+
return /* @__PURE__ */ jsx46(
|
|
5291
5674
|
"span",
|
|
5292
5675
|
{
|
|
5293
5676
|
className: cn("stn-header__context-title", className),
|
|
@@ -5298,7 +5681,7 @@ function StnHeaderContextTitle({ children, className, title, ...rest }) {
|
|
|
5298
5681
|
);
|
|
5299
5682
|
}
|
|
5300
5683
|
function StnHeaderToolbar({ children, className, ...rest }) {
|
|
5301
|
-
return /* @__PURE__ */
|
|
5684
|
+
return /* @__PURE__ */ jsx46("div", { className: cn("stn-header-toolbar", className), "data-stn-header-toolbar": true, ...rest, children });
|
|
5302
5685
|
}
|
|
5303
5686
|
|
|
5304
5687
|
// src/index.ts
|
|
@@ -5316,7 +5699,7 @@ import {
|
|
|
5316
5699
|
STN_LAYER0_BACKGROUND_DEMO_IMAGES,
|
|
5317
5700
|
STN_LAYER0_MAP_LIGHT_OVERLAY
|
|
5318
5701
|
} from "@stn-uiux/pub-ui/data/stnLayer0Background";
|
|
5319
|
-
import { jsx as
|
|
5702
|
+
import { jsx as jsx47, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
5320
5703
|
function overlayStyle(overlay) {
|
|
5321
5704
|
if (overlay == null || overlay <= 0) return void 0;
|
|
5322
5705
|
const pct = `${Math.min(100, Math.max(0, overlay * 100))}%`;
|
|
@@ -5345,6 +5728,12 @@ function StnLayer0Background({
|
|
|
5345
5728
|
if (variant === "dashboard") {
|
|
5346
5729
|
src = src ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.dashboard;
|
|
5347
5730
|
srcDark = srcDark ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.dashboardDark;
|
|
5731
|
+
} else if (variant === "infomap") {
|
|
5732
|
+
src = src ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.infomap;
|
|
5733
|
+
srcDark = srcDark ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.infomapDark;
|
|
5734
|
+
} else if (variant === "infomap-none") {
|
|
5735
|
+
src = src ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.infomapNone;
|
|
5736
|
+
srcDark = srcDark ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.infomapNoneDark;
|
|
5348
5737
|
} else if (variant === "showroom-a") {
|
|
5349
5738
|
src = src ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.showroomA;
|
|
5350
5739
|
srcDark = srcDark ?? STN_LAYER0_BACKGROUND_DEMO_IMAGES.showroomADark;
|
|
@@ -5365,41 +5754,57 @@ function StnLayer0Background({
|
|
|
5365
5754
|
const isImage = kind === "image" || Boolean(src || srcDark);
|
|
5366
5755
|
if (isImage) {
|
|
5367
5756
|
const paired = Boolean(src && srcDark);
|
|
5368
|
-
return /* @__PURE__ */
|
|
5757
|
+
return /* @__PURE__ */ jsx47(
|
|
5369
5758
|
"div",
|
|
5370
5759
|
{
|
|
5371
5760
|
className: cn("stn-layer0-bg", "image", className),
|
|
5372
5761
|
"aria-hidden": alt === "" ? true : void 0,
|
|
5373
5762
|
style: { ...overlayStyle(overlay), ...style },
|
|
5374
5763
|
...rest,
|
|
5375
|
-
children: /* @__PURE__ */
|
|
5376
|
-
src ? /* @__PURE__ */
|
|
5764
|
+
children: /* @__PURE__ */ jsxs36("div", { className: "stn-layer0-bg__media", children: [
|
|
5765
|
+
src ? /* @__PURE__ */ jsx47(
|
|
5377
5766
|
"img",
|
|
5378
5767
|
{
|
|
5379
5768
|
className: cn("stn-layer0-bg__img", paired && "light"),
|
|
5380
5769
|
src,
|
|
5381
5770
|
alt,
|
|
5382
|
-
decoding: "async"
|
|
5771
|
+
decoding: "async",
|
|
5772
|
+
onError: (e) => {
|
|
5773
|
+
if (src && src.startsWith("http") && src.includes("/images/layer0/")) {
|
|
5774
|
+
const fallback = src.substring(src.indexOf("/images/layer0/"));
|
|
5775
|
+
if (typeof window !== "undefined" && e.currentTarget.src !== window.location.origin + fallback) {
|
|
5776
|
+
e.currentTarget.src = fallback;
|
|
5777
|
+
}
|
|
5778
|
+
}
|
|
5779
|
+
}
|
|
5383
5780
|
}
|
|
5384
5781
|
) : null,
|
|
5385
|
-
srcDark ? /* @__PURE__ */
|
|
5782
|
+
srcDark ? /* @__PURE__ */ jsx47(
|
|
5386
5783
|
"img",
|
|
5387
5784
|
{
|
|
5388
5785
|
className: cn("stn-layer0-bg__img", paired ? "dark" : void 0),
|
|
5389
5786
|
src: srcDark,
|
|
5390
5787
|
alt,
|
|
5391
|
-
decoding: "async"
|
|
5788
|
+
decoding: "async",
|
|
5789
|
+
onError: (e) => {
|
|
5790
|
+
if (srcDark && srcDark.startsWith("http") && srcDark.includes("/images/layer0/")) {
|
|
5791
|
+
const fallback = srcDark.substring(srcDark.indexOf("/images/layer0/"));
|
|
5792
|
+
if (typeof window !== "undefined" && e.currentTarget.src !== window.location.origin + fallback) {
|
|
5793
|
+
e.currentTarget.src = fallback;
|
|
5794
|
+
}
|
|
5795
|
+
}
|
|
5796
|
+
}
|
|
5392
5797
|
}
|
|
5393
5798
|
) : null,
|
|
5394
|
-
overlay != null && overlay > 0 ? /* @__PURE__ */
|
|
5395
|
-
overlayDarkRadial ? /* @__PURE__ */
|
|
5799
|
+
overlay != null && overlay > 0 ? /* @__PURE__ */ jsx47("div", { className: "stn-layer0-bg__overlay", "aria-hidden": "true" }) : null,
|
|
5800
|
+
overlayDarkRadial ? /* @__PURE__ */ jsx47("div", { className: "stn-layer0-bg__overlay radial", "aria-hidden": "true" }) : null
|
|
5396
5801
|
] })
|
|
5397
5802
|
}
|
|
5398
5803
|
);
|
|
5399
5804
|
}
|
|
5400
5805
|
const isGradient = kind === "gradient" || variant === "gradient";
|
|
5401
5806
|
if (isGradient) {
|
|
5402
|
-
return /* @__PURE__ */
|
|
5807
|
+
return /* @__PURE__ */ jsx47(
|
|
5403
5808
|
"div",
|
|
5404
5809
|
{
|
|
5405
5810
|
className: cn("stn-layer0-bg", "gradient", className),
|
|
@@ -5409,7 +5814,7 @@ function StnLayer0Background({
|
|
|
5409
5814
|
}
|
|
5410
5815
|
);
|
|
5411
5816
|
}
|
|
5412
|
-
return /* @__PURE__ */
|
|
5817
|
+
return /* @__PURE__ */ jsx47(
|
|
5413
5818
|
"div",
|
|
5414
5819
|
{
|
|
5415
5820
|
className: cn("stn-layer0-bg", "color", color, className),
|
|
@@ -5446,7 +5851,7 @@ import {
|
|
|
5446
5851
|
|
|
5447
5852
|
// src/components/StnEventBanner.tsx
|
|
5448
5853
|
import React2 from "react";
|
|
5449
|
-
import { jsx as
|
|
5854
|
+
import { jsx as jsx48, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
5450
5855
|
var SEVERITY_ICONS2 = {
|
|
5451
5856
|
critical: "fill/alert4",
|
|
5452
5857
|
major: "fill/alert3",
|
|
@@ -5454,7 +5859,7 @@ var SEVERITY_ICONS2 = {
|
|
|
5454
5859
|
warning: "fill/alert1"
|
|
5455
5860
|
};
|
|
5456
5861
|
function DefaultTriangleIcon() {
|
|
5457
|
-
return /* @__PURE__ */
|
|
5862
|
+
return /* @__PURE__ */ jsxs37(
|
|
5458
5863
|
"svg",
|
|
5459
5864
|
{
|
|
5460
5865
|
width: "20",
|
|
@@ -5464,7 +5869,7 @@ function DefaultTriangleIcon() {
|
|
|
5464
5869
|
xmlns: "http://www.w3.org/2000/svg",
|
|
5465
5870
|
"aria-hidden": "true",
|
|
5466
5871
|
children: [
|
|
5467
|
-
/* @__PURE__ */
|
|
5872
|
+
/* @__PURE__ */ jsx48(
|
|
5468
5873
|
"path",
|
|
5469
5874
|
{
|
|
5470
5875
|
d: "M10.29 3.86L1.82 18A2 2 0 0 0 3.54 21H20.46A2 2 0 0 0 22.18 18L13.71 3.86A2 2 0 0 0 10.29 3.86Z",
|
|
@@ -5474,17 +5879,17 @@ function DefaultTriangleIcon() {
|
|
|
5474
5879
|
strokeLinejoin: "round"
|
|
5475
5880
|
}
|
|
5476
5881
|
),
|
|
5477
|
-
/* @__PURE__ */
|
|
5478
|
-
/* @__PURE__ */
|
|
5882
|
+
/* @__PURE__ */ jsx48("line", { x1: "12", y1: "9", x2: "12", y2: "13", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }),
|
|
5883
|
+
/* @__PURE__ */ jsx48("circle", { cx: "12", cy: "17", r: "1", fill: "currentColor" })
|
|
5479
5884
|
]
|
|
5480
5885
|
}
|
|
5481
5886
|
);
|
|
5482
5887
|
}
|
|
5483
5888
|
function resolveDefaultIcon(severity) {
|
|
5484
5889
|
if (severity === "critical") {
|
|
5485
|
-
return /* @__PURE__ */
|
|
5890
|
+
return /* @__PURE__ */ jsx48(DefaultTriangleIcon, {});
|
|
5486
5891
|
}
|
|
5487
|
-
return /* @__PURE__ */
|
|
5892
|
+
return /* @__PURE__ */ jsx48(StnIcon, { name: SEVERITY_ICONS2[severity] || "fill/alert4", size: 20 });
|
|
5488
5893
|
}
|
|
5489
5894
|
var StnEventBanner = React2.forwardRef(
|
|
5490
5895
|
({
|
|
@@ -5503,7 +5908,7 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5503
5908
|
id,
|
|
5504
5909
|
...restProps
|
|
5505
5910
|
}, ref) => {
|
|
5506
|
-
return /* @__PURE__ */
|
|
5911
|
+
return /* @__PURE__ */ jsxs37(
|
|
5507
5912
|
"div",
|
|
5508
5913
|
{
|
|
5509
5914
|
ref,
|
|
@@ -5520,16 +5925,16 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5520
5925
|
),
|
|
5521
5926
|
...restProps,
|
|
5522
5927
|
children: [
|
|
5523
|
-
/* @__PURE__ */
|
|
5524
|
-
/* @__PURE__ */
|
|
5525
|
-
/* @__PURE__ */
|
|
5526
|
-
title && /* @__PURE__ */
|
|
5527
|
-
time && /* @__PURE__ */
|
|
5928
|
+
/* @__PURE__ */ jsxs37("div", { className: "stn-event-banner__left", children: [
|
|
5929
|
+
/* @__PURE__ */ jsx48("div", { className: "stn-event-banner__icon-wrap", children: icon ?? resolveDefaultIcon(severity) }),
|
|
5930
|
+
/* @__PURE__ */ jsxs37("div", { className: "stn-event-banner__text", children: [
|
|
5931
|
+
title && /* @__PURE__ */ jsx48("span", { className: "stn-event-banner__title", title: typeof title === "string" ? title : void 0, children: title }),
|
|
5932
|
+
time && /* @__PURE__ */ jsx48("span", { className: "stn-event-banner__time", title: typeof time === "string" ? time : void 0, children: time })
|
|
5528
5933
|
] })
|
|
5529
5934
|
] }),
|
|
5530
|
-
/* @__PURE__ */
|
|
5935
|
+
/* @__PURE__ */ jsxs37("div", { className: "stn-event-banner__actions", children: [
|
|
5531
5936
|
actions,
|
|
5532
|
-
actionText && /* @__PURE__ */
|
|
5937
|
+
actionText && /* @__PURE__ */ jsx48(
|
|
5533
5938
|
"button",
|
|
5534
5939
|
{
|
|
5535
5940
|
type: "button",
|
|
@@ -5538,7 +5943,7 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5538
5943
|
children: actionText
|
|
5539
5944
|
}
|
|
5540
5945
|
),
|
|
5541
|
-
onClose && /* @__PURE__ */
|
|
5946
|
+
onClose && /* @__PURE__ */ jsx48(
|
|
5542
5947
|
"button",
|
|
5543
5948
|
{
|
|
5544
5949
|
type: "button",
|
|
@@ -5557,9 +5962,9 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5557
5962
|
StnEventBanner.displayName = "StnEventBanner";
|
|
5558
5963
|
|
|
5559
5964
|
// src/patterns/scaffold/StnLoadingSkeleton.tsx
|
|
5560
|
-
import { jsx as
|
|
5965
|
+
import { jsx as jsx49, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
5561
5966
|
function StnLoadingSkeletonLine({ width = "full", className, style, ...rest }) {
|
|
5562
|
-
return /* @__PURE__ */
|
|
5967
|
+
return /* @__PURE__ */ jsx49(
|
|
5563
5968
|
"div",
|
|
5564
5969
|
{
|
|
5565
5970
|
className: cn(
|
|
@@ -5575,7 +5980,7 @@ function StnLoadingSkeletonLine({ width = "full", className, style, ...rest }) {
|
|
|
5575
5980
|
);
|
|
5576
5981
|
}
|
|
5577
5982
|
function StnLoadingSkeletonBlock({ minHeight = 48, className, style, ...rest }) {
|
|
5578
|
-
return /* @__PURE__ */
|
|
5983
|
+
return /* @__PURE__ */ jsx49(
|
|
5579
5984
|
"div",
|
|
5580
5985
|
{
|
|
5581
5986
|
className: cn("stn-loading-skeleton__block", className),
|
|
@@ -5586,7 +5991,7 @@ function StnLoadingSkeletonBlock({ minHeight = 48, className, style, ...rest })
|
|
|
5586
5991
|
);
|
|
5587
5992
|
}
|
|
5588
5993
|
function StnLoadingSkeletonCircle({ size = 40, className, style, ...rest }) {
|
|
5589
|
-
return /* @__PURE__ */
|
|
5994
|
+
return /* @__PURE__ */ jsx49(
|
|
5590
5995
|
"div",
|
|
5591
5996
|
{
|
|
5592
5997
|
className: cn("stn-loading-skeleton__circle", className),
|
|
@@ -5597,7 +6002,7 @@ function StnLoadingSkeletonCircle({ size = 40, className, style, ...rest }) {
|
|
|
5597
6002
|
);
|
|
5598
6003
|
}
|
|
5599
6004
|
function StnLoadingSkeletonProfile({ avatarSize = 40, className, style, ...rest }) {
|
|
5600
|
-
return /* @__PURE__ */
|
|
6005
|
+
return /* @__PURE__ */ jsxs38(
|
|
5601
6006
|
"div",
|
|
5602
6007
|
{
|
|
5603
6008
|
className: cn("stn-loading-skeleton--profile", className),
|
|
@@ -5606,17 +6011,17 @@ function StnLoadingSkeletonProfile({ avatarSize = 40, className, style, ...rest
|
|
|
5606
6011
|
"aria-label": "\uD504\uB85C\uD544 \uB85C\uB529 \uC911",
|
|
5607
6012
|
...rest,
|
|
5608
6013
|
children: [
|
|
5609
|
-
/* @__PURE__ */
|
|
5610
|
-
/* @__PURE__ */
|
|
5611
|
-
/* @__PURE__ */
|
|
5612
|
-
/* @__PURE__ */
|
|
6014
|
+
/* @__PURE__ */ jsx49(StnLoadingSkeletonCircle, { size: avatarSize }),
|
|
6015
|
+
/* @__PURE__ */ jsxs38("div", { className: "stn-loading-skeleton__profile-content", children: [
|
|
6016
|
+
/* @__PURE__ */ jsx49(StnLoadingSkeletonLine, { width: "medium" }),
|
|
6017
|
+
/* @__PURE__ */ jsx49(StnLoadingSkeletonLine, { width: "short" })
|
|
5613
6018
|
] })
|
|
5614
6019
|
]
|
|
5615
6020
|
}
|
|
5616
6021
|
);
|
|
5617
6022
|
}
|
|
5618
6023
|
function StnLoadingSkeletonWidget({ lines = 4, className, style, ...rest }) {
|
|
5619
|
-
return /* @__PURE__ */
|
|
6024
|
+
return /* @__PURE__ */ jsx49(
|
|
5620
6025
|
"div",
|
|
5621
6026
|
{
|
|
5622
6027
|
className: cn("stn-loading-skeleton", "stn-loading-skeleton--widget", className),
|
|
@@ -5624,12 +6029,12 @@ function StnLoadingSkeletonWidget({ lines = 4, className, style, ...rest }) {
|
|
|
5624
6029
|
"aria-busy": "true",
|
|
5625
6030
|
"aria-label": "\uB85C\uB529 \uC911",
|
|
5626
6031
|
...rest,
|
|
5627
|
-
children: Array.from({ length: lines }, (_, i) => /* @__PURE__ */
|
|
6032
|
+
children: Array.from({ length: lines }, (_, i) => /* @__PURE__ */ jsx49(StnLoadingSkeletonLine, { width: i % 3 === 0 ? "short" : i % 2 === 0 ? "medium" : "full" }, i))
|
|
5628
6033
|
}
|
|
5629
6034
|
);
|
|
5630
6035
|
}
|
|
5631
6036
|
function StnLoadingSkeletonTable({ rows = 5, cols = 4, className, style, ...rest }) {
|
|
5632
|
-
return /* @__PURE__ */
|
|
6037
|
+
return /* @__PURE__ */ jsx49(
|
|
5633
6038
|
"div",
|
|
5634
6039
|
{
|
|
5635
6040
|
className: cn("stn-loading-skeleton", "stn-loading-skeleton--table", className),
|
|
@@ -5637,7 +6042,7 @@ function StnLoadingSkeletonTable({ rows = 5, cols = 4, className, style, ...rest
|
|
|
5637
6042
|
"aria-busy": "true",
|
|
5638
6043
|
"aria-label": "\uD14C\uC774\uBE14 \uB85C\uB529 \uC911",
|
|
5639
6044
|
...rest,
|
|
5640
|
-
children: Array.from({ length: rows }, (_, row) => /* @__PURE__ */
|
|
6045
|
+
children: Array.from({ length: rows }, (_, row) => /* @__PURE__ */ jsx49("div", { className: "stn-loading-skeleton__table-row", children: Array.from({ length: cols }, (_2, col) => /* @__PURE__ */ jsx49(StnLoadingSkeletonLine, {}, col)) }, row))
|
|
5641
6046
|
}
|
|
5642
6047
|
);
|
|
5643
6048
|
}
|
|
@@ -5656,23 +6061,23 @@ function StnLoadingSkeletonRoot({
|
|
|
5656
6061
|
...rest
|
|
5657
6062
|
}) {
|
|
5658
6063
|
if (children != null) {
|
|
5659
|
-
return /* @__PURE__ */
|
|
6064
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-loading-skeleton", className), style, "aria-busy": "true", ...rest, children });
|
|
5660
6065
|
}
|
|
5661
6066
|
const resolvedVariant = variant ?? "line";
|
|
5662
6067
|
switch (resolvedVariant) {
|
|
5663
6068
|
case "circle":
|
|
5664
|
-
return /* @__PURE__ */
|
|
6069
|
+
return /* @__PURE__ */ jsx49(StnLoadingSkeletonCircle, { size, className, style, ...rest });
|
|
5665
6070
|
case "block":
|
|
5666
|
-
return /* @__PURE__ */
|
|
6071
|
+
return /* @__PURE__ */ jsx49(StnLoadingSkeletonBlock, { minHeight, className, style, ...rest });
|
|
5667
6072
|
case "profile":
|
|
5668
|
-
return /* @__PURE__ */
|
|
6073
|
+
return /* @__PURE__ */ jsx49(StnLoadingSkeletonProfile, { avatarSize: avatarSize ?? size, className, style, ...rest });
|
|
5669
6074
|
case "widget":
|
|
5670
|
-
return /* @__PURE__ */
|
|
6075
|
+
return /* @__PURE__ */ jsx49(StnLoadingSkeletonWidget, { lines, className, style, ...rest });
|
|
5671
6076
|
case "table":
|
|
5672
|
-
return /* @__PURE__ */
|
|
6077
|
+
return /* @__PURE__ */ jsx49(StnLoadingSkeletonTable, { rows, cols, className, style, ...rest });
|
|
5673
6078
|
case "line":
|
|
5674
6079
|
default:
|
|
5675
|
-
return /* @__PURE__ */
|
|
6080
|
+
return /* @__PURE__ */ jsx49(StnLoadingSkeletonLine, { width, className, style, ...rest });
|
|
5676
6081
|
}
|
|
5677
6082
|
}
|
|
5678
6083
|
var StnLoadingSkeleton = Object.assign(StnLoadingSkeletonRoot, {
|
|
@@ -5793,7 +6198,7 @@ function ringOrbitRadius(orbit, ringCount, baseRadius, gap = 36) {
|
|
|
5793
6198
|
}
|
|
5794
6199
|
|
|
5795
6200
|
// src/components/topology/StnTopologyNodeMark.tsx
|
|
5796
|
-
import { jsx as
|
|
6201
|
+
import { jsx as jsx50, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
5797
6202
|
function renderTopologyIcon(icon, color, px) {
|
|
5798
6203
|
if (!icon) return null;
|
|
5799
6204
|
if (typeof icon !== "string") return icon;
|
|
@@ -5809,56 +6214,56 @@ function renderTopologyIcon(icon, color, px) {
|
|
|
5809
6214
|
};
|
|
5810
6215
|
switch (icon) {
|
|
5811
6216
|
case "server":
|
|
5812
|
-
return /* @__PURE__ */
|
|
5813
|
-
/* @__PURE__ */
|
|
5814
|
-
/* @__PURE__ */
|
|
5815
|
-
/* @__PURE__ */
|
|
5816
|
-
/* @__PURE__ */
|
|
6217
|
+
return /* @__PURE__ */ jsxs39("svg", { ...iconProps, children: [
|
|
6218
|
+
/* @__PURE__ */ jsx50("rect", { x: "2", y: "2", width: "20", height: "8", rx: "2", ry: "2" }),
|
|
6219
|
+
/* @__PURE__ */ jsx50("rect", { x: "2", y: "14", width: "20", height: "8", rx: "2", ry: "2" }),
|
|
6220
|
+
/* @__PURE__ */ jsx50("line", { x1: "6", y1: "6", x2: "6.01", y2: "6" }),
|
|
6221
|
+
/* @__PURE__ */ jsx50("line", { x1: "6", y1: "18", x2: "6.01", y2: "18" })
|
|
5817
6222
|
] });
|
|
5818
6223
|
case "cloud":
|
|
5819
|
-
return /* @__PURE__ */
|
|
6224
|
+
return /* @__PURE__ */ jsx50("svg", { ...iconProps, children: /* @__PURE__ */ jsx50("path", { d: "M18 10h-1.26A8 8 0 1 0 9 20h9a5 5 0 0 0 0-10z" }) });
|
|
5820
6225
|
case "ai":
|
|
5821
|
-
return /* @__PURE__ */
|
|
5822
|
-
/* @__PURE__ */
|
|
5823
|
-
/* @__PURE__ */
|
|
5824
|
-
/* @__PURE__ */
|
|
5825
|
-
/* @__PURE__ */
|
|
5826
|
-
/* @__PURE__ */
|
|
5827
|
-
/* @__PURE__ */
|
|
5828
|
-
/* @__PURE__ */
|
|
5829
|
-
/* @__PURE__ */
|
|
5830
|
-
/* @__PURE__ */
|
|
5831
|
-
/* @__PURE__ */
|
|
6226
|
+
return /* @__PURE__ */ jsxs39("svg", { ...iconProps, children: [
|
|
6227
|
+
/* @__PURE__ */ jsx50("rect", { x: "4", y: "4", width: "16", height: "16", rx: "2" }),
|
|
6228
|
+
/* @__PURE__ */ jsx50("rect", { x: "9", y: "9", width: "6", height: "6" }),
|
|
6229
|
+
/* @__PURE__ */ jsx50("line", { x1: "9", y1: "1", x2: "9", y2: "4" }),
|
|
6230
|
+
/* @__PURE__ */ jsx50("line", { x1: "15", y1: "1", x2: "15", y2: "4" }),
|
|
6231
|
+
/* @__PURE__ */ jsx50("line", { x1: "9", y1: "20", x2: "9", y2: "23" }),
|
|
6232
|
+
/* @__PURE__ */ jsx50("line", { x1: "15", y1: "20", x2: "15", y2: "23" }),
|
|
6233
|
+
/* @__PURE__ */ jsx50("line", { x1: "20", y1: "9", x2: "23", y2: "9" }),
|
|
6234
|
+
/* @__PURE__ */ jsx50("line", { x1: "20", y1: "14", x2: "23", y2: "14" }),
|
|
6235
|
+
/* @__PURE__ */ jsx50("line", { x1: "1", y1: "9", x2: "4", y2: "9" }),
|
|
6236
|
+
/* @__PURE__ */ jsx50("line", { x1: "1", y1: "14", x2: "4", y2: "14" })
|
|
5832
6237
|
] });
|
|
5833
6238
|
case "network":
|
|
5834
|
-
return /* @__PURE__ */
|
|
5835
|
-
/* @__PURE__ */
|
|
5836
|
-
/* @__PURE__ */
|
|
5837
|
-
/* @__PURE__ */
|
|
5838
|
-
/* @__PURE__ */
|
|
5839
|
-
/* @__PURE__ */
|
|
5840
|
-
/* @__PURE__ */
|
|
5841
|
-
/* @__PURE__ */
|
|
6239
|
+
return /* @__PURE__ */ jsxs39("svg", { ...iconProps, children: [
|
|
6240
|
+
/* @__PURE__ */ jsx50("rect", { x: "2", y: "2", width: "6", height: "6", rx: "1" }),
|
|
6241
|
+
/* @__PURE__ */ jsx50("rect", { x: "16", y: "2", width: "6", height: "6", rx: "1" }),
|
|
6242
|
+
/* @__PURE__ */ jsx50("rect", { x: "9", y: "16", width: "6", height: "6", rx: "1" }),
|
|
6243
|
+
/* @__PURE__ */ jsx50("line", { x1: "5", y1: "8", x2: "5", y2: "12" }),
|
|
6244
|
+
/* @__PURE__ */ jsx50("line", { x1: "19", y1: "8", x2: "19", y2: "12" }),
|
|
6245
|
+
/* @__PURE__ */ jsx50("line", { x1: "5", y1: "12", x2: "19", y2: "12" }),
|
|
6246
|
+
/* @__PURE__ */ jsx50("line", { x1: "12", y1: "12", x2: "12", y2: "16" })
|
|
5842
6247
|
] });
|
|
5843
6248
|
case "shield":
|
|
5844
|
-
return /* @__PURE__ */
|
|
6249
|
+
return /* @__PURE__ */ jsx50("svg", { ...iconProps, children: /* @__PURE__ */ jsx50("path", { d: "M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z" }) });
|
|
5845
6250
|
case "user":
|
|
5846
|
-
return /* @__PURE__ */
|
|
5847
|
-
/* @__PURE__ */
|
|
5848
|
-
/* @__PURE__ */
|
|
6251
|
+
return /* @__PURE__ */ jsxs39("svg", { ...iconProps, children: [
|
|
6252
|
+
/* @__PURE__ */ jsx50("path", { d: "M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2" }),
|
|
6253
|
+
/* @__PURE__ */ jsx50("circle", { cx: "12", cy: "7", r: "4" })
|
|
5849
6254
|
] });
|
|
5850
6255
|
case "database":
|
|
5851
|
-
return /* @__PURE__ */
|
|
5852
|
-
/* @__PURE__ */
|
|
5853
|
-
/* @__PURE__ */
|
|
5854
|
-
/* @__PURE__ */
|
|
6256
|
+
return /* @__PURE__ */ jsxs39("svg", { ...iconProps, children: [
|
|
6257
|
+
/* @__PURE__ */ jsx50("ellipse", { cx: "12", cy: "5", rx: "9", ry: "3" }),
|
|
6258
|
+
/* @__PURE__ */ jsx50("path", { d: "M21 12c0 1.66-4 3-9 3s-9-1.34-9-3" }),
|
|
6259
|
+
/* @__PURE__ */ jsx50("path", { d: "M3 5v14c0 1.66 4 3 9 3s9-1.34 9-3V5" })
|
|
5855
6260
|
] });
|
|
5856
6261
|
case "wifi":
|
|
5857
|
-
return /* @__PURE__ */
|
|
5858
|
-
/* @__PURE__ */
|
|
5859
|
-
/* @__PURE__ */
|
|
5860
|
-
/* @__PURE__ */
|
|
5861
|
-
/* @__PURE__ */
|
|
6262
|
+
return /* @__PURE__ */ jsxs39("svg", { ...iconProps, children: [
|
|
6263
|
+
/* @__PURE__ */ jsx50("path", { d: "M5 12.55a11 11 0 0 1 14.08 0" }),
|
|
6264
|
+
/* @__PURE__ */ jsx50("path", { d: "M1.42 9a16 16 0 0 1 21.16 0" }),
|
|
6265
|
+
/* @__PURE__ */ jsx50("path", { d: "M8.53 16.11a6 6 0 0 1 6.95 0" }),
|
|
6266
|
+
/* @__PURE__ */ jsx50("line", { x1: "12", y1: "20", x2: "12.01", y2: "20" })
|
|
5862
6267
|
] });
|
|
5863
6268
|
default:
|
|
5864
6269
|
return null;
|
|
@@ -5876,11 +6281,11 @@ function NodeShape({
|
|
|
5876
6281
|
}) {
|
|
5877
6282
|
const filter = glow ? `drop-shadow(0 0 8px ${glow})` : "drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4))";
|
|
5878
6283
|
if (shape === "circle") {
|
|
5879
|
-
return /* @__PURE__ */
|
|
6284
|
+
return /* @__PURE__ */ jsx50("circle", { cx: x, cy: y, r, fill, stroke, strokeWidth, style: { filter } });
|
|
5880
6285
|
}
|
|
5881
6286
|
if (shape === "square") {
|
|
5882
6287
|
const size = r * 2;
|
|
5883
|
-
return /* @__PURE__ */
|
|
6288
|
+
return /* @__PURE__ */ jsx50(
|
|
5884
6289
|
"rect",
|
|
5885
6290
|
{
|
|
5886
6291
|
x: x - r,
|
|
@@ -5895,7 +6300,7 @@ function NodeShape({
|
|
|
5895
6300
|
}
|
|
5896
6301
|
);
|
|
5897
6302
|
}
|
|
5898
|
-
return /* @__PURE__ */
|
|
6303
|
+
return /* @__PURE__ */ jsx50(
|
|
5899
6304
|
"polygon",
|
|
5900
6305
|
{
|
|
5901
6306
|
points: topologyShapePoints(shape, x, y, r),
|
|
@@ -5938,7 +6343,7 @@ function StnTopologyNodeMark({
|
|
|
5938
6343
|
const countText = formatTopologyCount(count);
|
|
5939
6344
|
const iconPx = metrics.icon;
|
|
5940
6345
|
const showCornerBadge = !isCount && count != null && count !== "";
|
|
5941
|
-
return /* @__PURE__ */
|
|
6346
|
+
return /* @__PURE__ */ jsxs39(
|
|
5942
6347
|
"g",
|
|
5943
6348
|
{
|
|
5944
6349
|
className: cn("stn-topology-node", selected && "stn-topology-node--selected", className),
|
|
@@ -5950,7 +6355,7 @@ function StnTopologyNodeMark({
|
|
|
5950
6355
|
style: { cursor: onClick ? "pointer" : "default" },
|
|
5951
6356
|
...rest,
|
|
5952
6357
|
children: [
|
|
5953
|
-
isAlert && /* @__PURE__ */
|
|
6358
|
+
isAlert && /* @__PURE__ */ jsxs39(
|
|
5954
6359
|
"circle",
|
|
5955
6360
|
{
|
|
5956
6361
|
className: "stn-topology-node__pulse",
|
|
@@ -5962,13 +6367,13 @@ function StnTopologyNodeMark({
|
|
|
5962
6367
|
strokeWidth: "1.5",
|
|
5963
6368
|
opacity: "0.55",
|
|
5964
6369
|
children: [
|
|
5965
|
-
/* @__PURE__ */
|
|
5966
|
-
/* @__PURE__ */
|
|
6370
|
+
/* @__PURE__ */ jsx50("animate", { attributeName: "r", values: `${r + 4};${r + 12};${r + 4}`, dur: "2s", repeatCount: "indefinite" }),
|
|
6371
|
+
/* @__PURE__ */ jsx50("animate", { attributeName: "opacity", values: "0.75;0.15;0.75", dur: "2s", repeatCount: "indefinite" })
|
|
5967
6372
|
]
|
|
5968
6373
|
}
|
|
5969
6374
|
),
|
|
5970
|
-
selected && /* @__PURE__ */
|
|
5971
|
-
/* @__PURE__ */
|
|
6375
|
+
selected && /* @__PURE__ */ jsx50("circle", { cx: x, cy: y, r: r + 6, fill: "none", stroke: "#00e5ff", strokeWidth: "1.5", strokeDasharray: "3 3" }),
|
|
6376
|
+
/* @__PURE__ */ jsx50(
|
|
5972
6377
|
NodeShape,
|
|
5973
6378
|
{
|
|
5974
6379
|
shape,
|
|
@@ -5981,7 +6386,7 @@ function StnTopologyNodeMark({
|
|
|
5981
6386
|
glow: isAlert || isCount ? tone.glow : ""
|
|
5982
6387
|
}
|
|
5983
6388
|
),
|
|
5984
|
-
isCount ? /* @__PURE__ */
|
|
6389
|
+
isCount ? /* @__PURE__ */ jsx50(
|
|
5985
6390
|
"text",
|
|
5986
6391
|
{
|
|
5987
6392
|
x,
|
|
@@ -5994,10 +6399,10 @@ function StnTopologyNodeMark({
|
|
|
5994
6399
|
style: { textShadow: "0 1px 2px rgba(0, 0, 0, 0.85)" },
|
|
5995
6400
|
children: countText
|
|
5996
6401
|
}
|
|
5997
|
-
) : /* @__PURE__ */
|
|
5998
|
-
showCornerBadge && /* @__PURE__ */
|
|
5999
|
-
/* @__PURE__ */
|
|
6000
|
-
/* @__PURE__ */
|
|
6402
|
+
) : /* @__PURE__ */ jsx50("g", { transform: `translate(${x - iconPx / 2}, ${y - iconPx / 2})`, children: renderTopologyIcon(icon, stroke, iconPx) }),
|
|
6403
|
+
showCornerBadge && /* @__PURE__ */ jsxs39("g", { className: "stn-topology-node__badge", children: [
|
|
6404
|
+
/* @__PURE__ */ jsx50("circle", { cx: x + r * 0.72, cy: y - r * 0.72, r: Math.max(6, r * 0.38), fill: stroke, stroke: "rgba(6,7,15,0.9)", strokeWidth: "1" }),
|
|
6405
|
+
/* @__PURE__ */ jsx50(
|
|
6001
6406
|
"text",
|
|
6002
6407
|
{
|
|
6003
6408
|
x: x + r * 0.72,
|
|
@@ -6011,7 +6416,7 @@ function StnTopologyNodeMark({
|
|
|
6011
6416
|
}
|
|
6012
6417
|
)
|
|
6013
6418
|
] }),
|
|
6014
|
-
showLabel && label && /* @__PURE__ */
|
|
6419
|
+
showLabel && label && /* @__PURE__ */ jsx50(
|
|
6015
6420
|
"text",
|
|
6016
6421
|
{
|
|
6017
6422
|
x,
|
|
@@ -6024,7 +6429,7 @@ function StnTopologyNodeMark({
|
|
|
6024
6429
|
children: label
|
|
6025
6430
|
}
|
|
6026
6431
|
),
|
|
6027
|
-
showStatus && resolvedStatusLabel && /* @__PURE__ */
|
|
6432
|
+
showStatus && resolvedStatusLabel && /* @__PURE__ */ jsxs39(
|
|
6028
6433
|
"text",
|
|
6029
6434
|
{
|
|
6030
6435
|
x,
|
|
@@ -6055,11 +6460,11 @@ function StnTopologyNodePreview({
|
|
|
6055
6460
|
const r = STN_TOPOLOGY_NODE_SIZE[size].r;
|
|
6056
6461
|
const w = width ?? r * 2 + (showLabel ? 88 : 28);
|
|
6057
6462
|
const h = height ?? r * 2 + (showLabel || showStatus ? 56 : 28);
|
|
6058
|
-
return /* @__PURE__ */
|
|
6463
|
+
return /* @__PURE__ */ jsx50("svg", { className: "stn-topology-node-preview", width: w, height: h, viewBox: `0 0 ${w} ${h}`, overflow: "visible", children: /* @__PURE__ */ jsx50(StnTopologyNodeMark, { x: w / 2, y: h / 2, size, showLabel, showStatus, ...rest }) });
|
|
6059
6464
|
}
|
|
6060
6465
|
|
|
6061
6466
|
// src/components/topology/StnTopologyRing.tsx
|
|
6062
|
-
import { jsx as
|
|
6467
|
+
import { jsx as jsx51, jsxs as jsxs40 } from "react/jsx-runtime";
|
|
6063
6468
|
function StnTopologyRing({
|
|
6064
6469
|
core = {
|
|
6065
6470
|
title: "\uC5D0\uC2A4\uD2F0\uC5D4\uC778\uD3EC\uD14D",
|
|
@@ -6118,17 +6523,17 @@ function StnTopologyRing({
|
|
|
6118
6523
|
};
|
|
6119
6524
|
});
|
|
6120
6525
|
if (loading) {
|
|
6121
|
-
return /* @__PURE__ */
|
|
6526
|
+
return /* @__PURE__ */ jsx51(
|
|
6122
6527
|
"div",
|
|
6123
6528
|
{
|
|
6124
6529
|
className: cn("stn-topology-ring", "stn-topology-ring--loading", className),
|
|
6125
6530
|
style,
|
|
6126
6531
|
...rest,
|
|
6127
|
-
children: /* @__PURE__ */
|
|
6532
|
+
children: /* @__PURE__ */ jsx51("div", { className: "stn-topology-ring__loading-label", children: "\uD1A0\uD3F4\uB85C\uC9C0 \uB9C1 \uB370\uC774\uD130\uB97C \uBD88\uB7EC\uC624\uB294 \uC911..." })
|
|
6128
6533
|
}
|
|
6129
6534
|
);
|
|
6130
6535
|
}
|
|
6131
|
-
return /* @__PURE__ */
|
|
6536
|
+
return /* @__PURE__ */ jsx51(
|
|
6132
6537
|
"div",
|
|
6133
6538
|
{
|
|
6134
6539
|
className: cn("stn-topology-ring", className),
|
|
@@ -6136,7 +6541,7 @@ function StnTopologyRing({
|
|
|
6136
6541
|
"data-stn-topology-ring": true,
|
|
6137
6542
|
"data-ring-count": safeRingCount,
|
|
6138
6543
|
...rest,
|
|
6139
|
-
children: /* @__PURE__ */
|
|
6544
|
+
children: /* @__PURE__ */ jsxs40(
|
|
6140
6545
|
"svg",
|
|
6141
6546
|
{
|
|
6142
6547
|
className: "stn-topology-ring__svg",
|
|
@@ -6145,19 +6550,19 @@ function StnTopologyRing({
|
|
|
6145
6550
|
viewBox: `0 0 ${vb} ${vb}`,
|
|
6146
6551
|
overflow: "visible",
|
|
6147
6552
|
children: [
|
|
6148
|
-
/* @__PURE__ */
|
|
6149
|
-
/* @__PURE__ */
|
|
6150
|
-
/* @__PURE__ */
|
|
6151
|
-
/* @__PURE__ */
|
|
6553
|
+
/* @__PURE__ */ jsxs40("defs", { children: [
|
|
6554
|
+
/* @__PURE__ */ jsxs40("radialGradient", { id: coreGlowId, cx: "50%", cy: "50%", r: "50%", children: [
|
|
6555
|
+
/* @__PURE__ */ jsx51("stop", { offset: "0%", stopColor: "#722ed1", stopOpacity: "0.8" }),
|
|
6556
|
+
/* @__PURE__ */ jsx51("stop", { offset: "100%", stopColor: "#120338", stopOpacity: "0" })
|
|
6152
6557
|
] }),
|
|
6153
|
-
/* @__PURE__ */
|
|
6154
|
-
/* @__PURE__ */
|
|
6155
|
-
/* @__PURE__ */
|
|
6558
|
+
/* @__PURE__ */ jsxs40("linearGradient", { id: gradientId, x1: "0%", y1: "0%", x2: "100%", y2: "100%", children: [
|
|
6559
|
+
/* @__PURE__ */ jsx51("stop", { offset: "0%", stopColor: "#00e5ff", stopOpacity: "0.4" }),
|
|
6560
|
+
/* @__PURE__ */ jsx51("stop", { offset: "100%", stopColor: "#722ed1", stopOpacity: "0.4" })
|
|
6156
6561
|
] })
|
|
6157
6562
|
] }),
|
|
6158
6563
|
radii.map((r, idx) => {
|
|
6159
6564
|
const isMain = idx + 1 === mainOrbit;
|
|
6160
|
-
return /* @__PURE__ */
|
|
6565
|
+
return /* @__PURE__ */ jsx51(
|
|
6161
6566
|
"circle",
|
|
6162
6567
|
{
|
|
6163
6568
|
cx: centerX,
|
|
@@ -6171,7 +6576,7 @@ function StnTopologyRing({
|
|
|
6171
6576
|
`orbit-${idx}`
|
|
6172
6577
|
);
|
|
6173
6578
|
}),
|
|
6174
|
-
connectionLineStyle !== "none" && calculatedNodes.map((node) => /* @__PURE__ */
|
|
6579
|
+
connectionLineStyle !== "none" && calculatedNodes.map((node) => /* @__PURE__ */ jsx51(
|
|
6175
6580
|
"line",
|
|
6176
6581
|
{
|
|
6177
6582
|
x1: centerX,
|
|
@@ -6184,9 +6589,9 @@ function StnTopologyRing({
|
|
|
6184
6589
|
},
|
|
6185
6590
|
`line-${node.id}`
|
|
6186
6591
|
)),
|
|
6187
|
-
/* @__PURE__ */
|
|
6188
|
-
/* @__PURE__ */
|
|
6189
|
-
/* @__PURE__ */
|
|
6592
|
+
/* @__PURE__ */ jsxs40("g", { className: "stn-topology-ring__core", children: [
|
|
6593
|
+
/* @__PURE__ */ jsx51("circle", { cx: centerX, cy: centerY, r: 54, fill: `url(#${coreGlowId})` }),
|
|
6594
|
+
/* @__PURE__ */ jsx51(
|
|
6190
6595
|
"circle",
|
|
6191
6596
|
{
|
|
6192
6597
|
cx: centerX,
|
|
@@ -6198,7 +6603,7 @@ function StnTopologyRing({
|
|
|
6198
6603
|
style: { filter: "drop-shadow(0 0 12px rgba(114, 46, 209, 0.6))" }
|
|
6199
6604
|
}
|
|
6200
6605
|
),
|
|
6201
|
-
core.subTitle && /* @__PURE__ */
|
|
6606
|
+
core.subTitle && /* @__PURE__ */ jsx51(
|
|
6202
6607
|
"text",
|
|
6203
6608
|
{
|
|
6204
6609
|
x: centerX,
|
|
@@ -6211,13 +6616,13 @@ function StnTopologyRing({
|
|
|
6211
6616
|
children: core.subTitle
|
|
6212
6617
|
}
|
|
6213
6618
|
),
|
|
6214
|
-
core.title && /* @__PURE__ */
|
|
6215
|
-
/* @__PURE__ */
|
|
6619
|
+
core.title && /* @__PURE__ */ jsx51("text", { x: centerX, y: centerY + 8, textAnchor: "middle", fill: "#f0f2f5", fontSize: "10", fontWeight: "600", children: core.title }),
|
|
6620
|
+
/* @__PURE__ */ jsxs40("text", { x: centerX, y: centerY + 22, textAnchor: "middle", fill: coreColor, fontSize: "9", fontWeight: "500", children: [
|
|
6216
6621
|
"\u25CF ",
|
|
6217
6622
|
coreStatusLabel
|
|
6218
6623
|
] })
|
|
6219
6624
|
] }),
|
|
6220
|
-
calculatedNodes.map((node) => /* @__PURE__ */
|
|
6625
|
+
calculatedNodes.map((node) => /* @__PURE__ */ jsx51(
|
|
6221
6626
|
StnTopologyNodeMark,
|
|
6222
6627
|
{
|
|
6223
6628
|
x: node.x,
|
|
@@ -6245,8 +6650,8 @@ function StnTopologyRing({
|
|
|
6245
6650
|
}
|
|
6246
6651
|
|
|
6247
6652
|
// src/components/topology/StnTopologyGraph.tsx
|
|
6248
|
-
import { useState as
|
|
6249
|
-
import { jsx as
|
|
6653
|
+
import { useState as useState15 } from "react";
|
|
6654
|
+
import { jsx as jsx52, jsxs as jsxs41 } from "react/jsx-runtime";
|
|
6250
6655
|
var DEFAULT_GRAPH_NODES = [
|
|
6251
6656
|
{ id: "n1", x: 200, y: 58, status: "minor", label: "GW-01", shape: "circle", content: "icon", icon: "wifi" },
|
|
6252
6657
|
{ id: "n2", x: 118, y: 118, status: "critical", label: "BACKUP", shape: "hexagon", content: "count", count: 4, pulse: true },
|
|
@@ -6280,12 +6685,12 @@ function StnTopologyGraph({
|
|
|
6280
6685
|
style,
|
|
6281
6686
|
...rest
|
|
6282
6687
|
}) {
|
|
6283
|
-
const [viewMode, setViewMode] =
|
|
6688
|
+
const [viewMode, setViewMode] = useState15(defaultMode);
|
|
6284
6689
|
if (loading) {
|
|
6285
|
-
return /* @__PURE__ */
|
|
6690
|
+
return /* @__PURE__ */ jsx52("div", { className: cn("stn-topology-graph", "stn-topology-graph--loading", className), style, ...rest, children: /* @__PURE__ */ jsx52("div", { className: "stn-topology-graph__loading-label", children: "\uD1A0\uD3F4\uB85C\uC9C0 \uCE94\uBC84\uC2A4 \uB370\uC774\uD130\uB97C \uBD88\uB7EC\uC624\uB294 \uC911..." }) });
|
|
6286
6691
|
}
|
|
6287
6692
|
const nodeMap = new Map(nodes.map((n) => [n.id, n]));
|
|
6288
|
-
return /* @__PURE__ */
|
|
6693
|
+
return /* @__PURE__ */ jsxs41(
|
|
6289
6694
|
"div",
|
|
6290
6695
|
{
|
|
6291
6696
|
className: cn("stn-topology-graph", className),
|
|
@@ -6294,7 +6699,7 @@ function StnTopologyGraph({
|
|
|
6294
6699
|
"data-view-mode": viewMode,
|
|
6295
6700
|
...rest,
|
|
6296
6701
|
children: [
|
|
6297
|
-
showModeToggle && /* @__PURE__ */
|
|
6702
|
+
showModeToggle && /* @__PURE__ */ jsx52("div", { className: "stn-topology-graph__mode", children: /* @__PURE__ */ jsx52(
|
|
6298
6703
|
StnSegmented,
|
|
6299
6704
|
{
|
|
6300
6705
|
size: "sm",
|
|
@@ -6306,23 +6711,23 @@ function StnTopologyGraph({
|
|
|
6306
6711
|
]
|
|
6307
6712
|
}
|
|
6308
6713
|
) }),
|
|
6309
|
-
/* @__PURE__ */
|
|
6310
|
-
viewMode === "3D" ? /* @__PURE__ */
|
|
6311
|
-
/* @__PURE__ */
|
|
6312
|
-
/* @__PURE__ */
|
|
6313
|
-
/* @__PURE__ */
|
|
6314
|
-
/* @__PURE__ */
|
|
6315
|
-
/* @__PURE__ */
|
|
6316
|
-
/* @__PURE__ */
|
|
6317
|
-
/* @__PURE__ */
|
|
6318
|
-
/* @__PURE__ */
|
|
6319
|
-
] }) : /* @__PURE__ */
|
|
6320
|
-
/* @__PURE__ */
|
|
6321
|
-
/* @__PURE__ */
|
|
6322
|
-
/* @__PURE__ */
|
|
6323
|
-
/* @__PURE__ */
|
|
6324
|
-
/* @__PURE__ */
|
|
6325
|
-
/* @__PURE__ */
|
|
6714
|
+
/* @__PURE__ */ jsxs41("svg", { className: "stn-topology-graph__svg", width: "100%", height: "100%", viewBox: "0 0 400 300", overflow: "visible", children: [
|
|
6715
|
+
viewMode === "3D" ? /* @__PURE__ */ jsxs41("g", { opacity: "0.6", children: [
|
|
6716
|
+
/* @__PURE__ */ jsx52("line", { x1: "60", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.06)", strokeDasharray: "3 3" }),
|
|
6717
|
+
/* @__PURE__ */ jsx52("line", { x1: "130", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "3 3" }),
|
|
6718
|
+
/* @__PURE__ */ jsx52("line", { x1: "200", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.14)", strokeDasharray: "3 3" }),
|
|
6719
|
+
/* @__PURE__ */ jsx52("line", { x1: "270", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "3 3" }),
|
|
6720
|
+
/* @__PURE__ */ jsx52("line", { x1: "340", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.06)", strokeDasharray: "3 3" }),
|
|
6721
|
+
/* @__PURE__ */ jsx52("line", { x1: "100", y1: "230", x2: "300", y2: "230", stroke: "rgba(255,255,255,0.06)" }),
|
|
6722
|
+
/* @__PURE__ */ jsx52("line", { x1: "130", y1: "190", x2: "270", y2: "190", stroke: "rgba(255,255,255,0.06)" }),
|
|
6723
|
+
/* @__PURE__ */ jsx52("line", { x1: "160", y1: "140", x2: "240", y2: "140", stroke: "rgba(255,255,255,0.06)" })
|
|
6724
|
+
] }) : /* @__PURE__ */ jsxs41("g", { opacity: "0.3", children: [
|
|
6725
|
+
/* @__PURE__ */ jsx52("line", { x1: "40", y1: "60", x2: "360", y2: "60", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6726
|
+
/* @__PURE__ */ jsx52("line", { x1: "40", y1: "150", x2: "360", y2: "150", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6727
|
+
/* @__PURE__ */ jsx52("line", { x1: "40", y1: "240", x2: "360", y2: "240", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6728
|
+
/* @__PURE__ */ jsx52("line", { x1: "100", y1: "20", x2: "100", y2: "280", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6729
|
+
/* @__PURE__ */ jsx52("line", { x1: "200", y1: "20", x2: "200", y2: "280", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6730
|
+
/* @__PURE__ */ jsx52("line", { x1: "300", y1: "20", x2: "300", y2: "280", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" })
|
|
6326
6731
|
] }),
|
|
6327
6732
|
links.map((link, idx) => {
|
|
6328
6733
|
const s = nodeMap.get(link.source);
|
|
@@ -6330,7 +6735,7 @@ function StnTopologyGraph({
|
|
|
6330
6735
|
if (!s || !t) return null;
|
|
6331
6736
|
const isAlert = s.status === "critical" || t.status === "critical" || link.status === "critical";
|
|
6332
6737
|
const strokeColor = isAlert ? "rgba(255, 77, 79, 0.65)" : "rgba(255, 255, 255, 0.2)";
|
|
6333
|
-
return /* @__PURE__ */
|
|
6738
|
+
return /* @__PURE__ */ jsx52(
|
|
6334
6739
|
"line",
|
|
6335
6740
|
{
|
|
6336
6741
|
x1: s.x,
|
|
@@ -6347,7 +6752,7 @@ function StnTopologyGraph({
|
|
|
6347
6752
|
nodes.map((node) => {
|
|
6348
6753
|
const status = node.status ?? "normal";
|
|
6349
6754
|
const isCore = Boolean(node.isCore);
|
|
6350
|
-
return /* @__PURE__ */
|
|
6755
|
+
return /* @__PURE__ */ jsx52(
|
|
6351
6756
|
StnTopologyNodeMark,
|
|
6352
6757
|
{
|
|
6353
6758
|
x: node.x,
|
|
@@ -6370,17 +6775,17 @@ function StnTopologyGraph({
|
|
|
6370
6775
|
);
|
|
6371
6776
|
})
|
|
6372
6777
|
] }),
|
|
6373
|
-
showMinimap && /* @__PURE__ */
|
|
6374
|
-
/* @__PURE__ */
|
|
6375
|
-
/* @__PURE__ */
|
|
6376
|
-
/* @__PURE__ */
|
|
6778
|
+
showMinimap && /* @__PURE__ */ jsxs41("div", { className: "stn-topology-graph__minimap", children: [
|
|
6779
|
+
/* @__PURE__ */ jsxs41("div", { className: "stn-topology-graph__minimap-head", children: [
|
|
6780
|
+
/* @__PURE__ */ jsx52("span", { children: "\uBBF8\uB9AC\uBCF4\uAE30" }),
|
|
6781
|
+
/* @__PURE__ */ jsx52("span", { children: "\u2014" })
|
|
6377
6782
|
] }),
|
|
6378
|
-
/* @__PURE__ */
|
|
6379
|
-
/* @__PURE__ */
|
|
6380
|
-
/* @__PURE__ */
|
|
6381
|
-
/* @__PURE__ */
|
|
6382
|
-
/* @__PURE__ */
|
|
6383
|
-
/* @__PURE__ */
|
|
6783
|
+
/* @__PURE__ */ jsxs41("svg", { width: "100%", height: "40", viewBox: "0 0 100 50", children: [
|
|
6784
|
+
/* @__PURE__ */ jsx52("polyline", { points: "50,10 40,25 50,40 60,30", fill: "none", stroke: "rgba(255,77,79,0.5)", strokeWidth: "1" }),
|
|
6785
|
+
/* @__PURE__ */ jsx52("circle", { cx: "50", cy: "10", r: "2", fill: STN_TOPOLOGY_STATUS_COLORS.critical.main }),
|
|
6786
|
+
/* @__PURE__ */ jsx52("circle", { cx: "40", cy: "25", r: "2.5", fill: STN_TOPOLOGY_STATUS_COLORS.critical.main }),
|
|
6787
|
+
/* @__PURE__ */ jsx52("circle", { cx: "50", cy: "40", r: "2", fill: "#00e5ff" }),
|
|
6788
|
+
/* @__PURE__ */ jsx52("circle", { cx: "60", cy: "30", r: "2", fill: STN_TOPOLOGY_STATUS_COLORS.normal.main })
|
|
6384
6789
|
] })
|
|
6385
6790
|
] })
|
|
6386
6791
|
]
|
|
@@ -6389,7 +6794,7 @@ function StnTopologyGraph({
|
|
|
6389
6794
|
}
|
|
6390
6795
|
|
|
6391
6796
|
// src/components/StnWidget.tsx
|
|
6392
|
-
import { Fragment as Fragment5, jsx as
|
|
6797
|
+
import { Fragment as Fragment5, jsx as jsx53, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
6393
6798
|
var SHELL_PUB_CLASS = {
|
|
6394
6799
|
card: "",
|
|
6395
6800
|
"fault-panel": "",
|
|
@@ -6472,20 +6877,20 @@ function StnWidgetPeriodText({
|
|
|
6472
6877
|
className,
|
|
6473
6878
|
...rest
|
|
6474
6879
|
}) {
|
|
6475
|
-
return /* @__PURE__ */
|
|
6880
|
+
return /* @__PURE__ */ jsx53("span", { className: cn("stn-widget__period-text", className), ...rest, children });
|
|
6476
6881
|
}
|
|
6477
6882
|
function StnWidgetPeriodSelect({
|
|
6478
6883
|
label,
|
|
6479
6884
|
className,
|
|
6480
6885
|
...rest
|
|
6481
6886
|
}) {
|
|
6482
|
-
return /* @__PURE__ */
|
|
6887
|
+
return /* @__PURE__ */ jsx53(
|
|
6483
6888
|
StnButton,
|
|
6484
6889
|
{
|
|
6485
6890
|
variant: "ghost",
|
|
6486
6891
|
size: "sm",
|
|
6487
6892
|
shape: "square",
|
|
6488
|
-
icon: /* @__PURE__ */
|
|
6893
|
+
icon: /* @__PURE__ */ jsx53(StnIcon, { name: "line/chevron-down" }),
|
|
6489
6894
|
iconPosition: "right",
|
|
6490
6895
|
className,
|
|
6491
6896
|
...rest,
|
|
@@ -6502,26 +6907,26 @@ function StnWidgetPeriodPager({
|
|
|
6502
6907
|
nextLabel = "\uB2E4\uC74C",
|
|
6503
6908
|
...rest
|
|
6504
6909
|
}) {
|
|
6505
|
-
return /* @__PURE__ */
|
|
6506
|
-
/* @__PURE__ */
|
|
6910
|
+
return /* @__PURE__ */ jsxs42("div", { className: cn("stn-widget__period-pager", className), ...rest, children: [
|
|
6911
|
+
/* @__PURE__ */ jsx53(
|
|
6507
6912
|
StnButton,
|
|
6508
6913
|
{
|
|
6509
6914
|
variant: "ghost",
|
|
6510
6915
|
size: "sm",
|
|
6511
6916
|
shape: "square",
|
|
6512
|
-
icon: /* @__PURE__ */
|
|
6917
|
+
icon: /* @__PURE__ */ jsx53(StnIcon, { name: "line/arrow-narrow-left" }),
|
|
6513
6918
|
onClick: onPrev,
|
|
6514
6919
|
"aria-label": prevLabel
|
|
6515
6920
|
}
|
|
6516
6921
|
),
|
|
6517
|
-
/* @__PURE__ */
|
|
6518
|
-
/* @__PURE__ */
|
|
6922
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-widget__period-pager-label", children: label }),
|
|
6923
|
+
/* @__PURE__ */ jsx53(
|
|
6519
6924
|
StnButton,
|
|
6520
6925
|
{
|
|
6521
6926
|
variant: "ghost",
|
|
6522
6927
|
size: "sm",
|
|
6523
6928
|
shape: "square",
|
|
6524
|
-
icon: /* @__PURE__ */
|
|
6929
|
+
icon: /* @__PURE__ */ jsx53(StnIcon, { name: "line/arrow-narrow-right" }),
|
|
6525
6930
|
onClick: onNext,
|
|
6526
6931
|
"aria-label": nextLabel
|
|
6527
6932
|
}
|
|
@@ -6531,6 +6936,8 @@ function StnWidgetPeriodPager({
|
|
|
6531
6936
|
function StnWidgetHeaderInner({
|
|
6532
6937
|
appearance,
|
|
6533
6938
|
title,
|
|
6939
|
+
titleSize = "md",
|
|
6940
|
+
titleWeight = "semibold",
|
|
6534
6941
|
badge,
|
|
6535
6942
|
titleActions,
|
|
6536
6943
|
periodLabel,
|
|
@@ -6540,19 +6947,24 @@ function StnWidgetHeaderInner({
|
|
|
6540
6947
|
headerIcon,
|
|
6541
6948
|
wrapActions = false
|
|
6542
6949
|
}) {
|
|
6950
|
+
const hasStart = showHeaderIcon || title != null || badge != null;
|
|
6951
|
+
const hasEnd = titleActions != null || periodActions != null || periodLabel != null && periodLabel !== "";
|
|
6952
|
+
if (!hasStart && !hasEnd) {
|
|
6953
|
+
return null;
|
|
6954
|
+
}
|
|
6543
6955
|
const resolvedIconName = headerIconName ?? defaultHeaderIconName(appearance);
|
|
6544
|
-
return /* @__PURE__ */
|
|
6545
|
-
/* @__PURE__ */
|
|
6546
|
-
showHeaderIcon ? headerIcon != null ? /* @__PURE__ */
|
|
6547
|
-
title != null || badge != null ? typeof title === "string" || title == null ? /* @__PURE__ */
|
|
6548
|
-
typeof title === "string" ? /* @__PURE__ */
|
|
6956
|
+
return /* @__PURE__ */ jsxs42("div", { className: cn("stn-widget__head", wrapActions && "stn-widget__head--wrap"), children: [
|
|
6957
|
+
/* @__PURE__ */ jsxs42("div", { className: "stn-widget__head-start", children: [
|
|
6958
|
+
showHeaderIcon ? headerIcon != null ? /* @__PURE__ */ jsx53(StnWidgetInsetIcon, { size: "sm", children: headerIcon }) : resolvedIconName ? /* @__PURE__ */ jsx53(StnWidgetInsetIcon, { size: "sm", icon: resolvedIconName }) : null : null,
|
|
6959
|
+
title != null || badge != null ? typeof title === "string" || title == null ? /* @__PURE__ */ jsxs42("div", { className: "stn-widget__title-wrap", children: [
|
|
6960
|
+
typeof title === "string" ? /* @__PURE__ */ jsx53("p", { className: cn("stn-widget__title", titleSize, titleWeight), title, children: title }) : null,
|
|
6549
6961
|
badge
|
|
6550
|
-
] }) : /* @__PURE__ */
|
|
6962
|
+
] }) : /* @__PURE__ */ jsxs42(Fragment5, { children: [
|
|
6551
6963
|
title,
|
|
6552
6964
|
badge
|
|
6553
6965
|
] }) : null
|
|
6554
6966
|
] }),
|
|
6555
|
-
titleActions != null || periodActions != null || periodLabel != null && periodLabel !== "" ? /* @__PURE__ */
|
|
6967
|
+
titleActions != null || periodActions != null || periodLabel != null && periodLabel !== "" ? /* @__PURE__ */ jsx53("div", { className: "stn-widget__head-end", children: titleActions ?? (periodActions != null ? periodActions : periodLabel != null && periodLabel !== "" ? /* @__PURE__ */ jsx53(StnWidgetPeriodText, { children: periodLabel }) : null) }) : null
|
|
6556
6968
|
] });
|
|
6557
6969
|
}
|
|
6558
6970
|
function StnWidgetRoot({
|
|
@@ -6564,6 +6976,8 @@ function StnWidgetRoot({
|
|
|
6564
6976
|
isCritical = false,
|
|
6565
6977
|
kind,
|
|
6566
6978
|
title,
|
|
6979
|
+
titleSize = "md",
|
|
6980
|
+
titleWeight = "semibold",
|
|
6567
6981
|
badge,
|
|
6568
6982
|
titleActions,
|
|
6569
6983
|
showHeaderIcon,
|
|
@@ -6596,7 +7010,8 @@ function StnWidgetRoot({
|
|
|
6596
7010
|
const defaultBg = isCanvas ? false : true;
|
|
6597
7011
|
const bgMode = resolveStnWidgetBackground(background ?? defaultBg);
|
|
6598
7012
|
const pubShell = SHELL_PUB_CLASS[shell];
|
|
6599
|
-
const
|
|
7013
|
+
const hasHeaderContent = title != null || badge != null || titleActions != null || periodActions != null || periodLabel != null && periodLabel !== "";
|
|
7014
|
+
const resolvedShowIcon = showHeaderIcon ?? (isFigmaShell && !isCanvas && hasHeaderContent);
|
|
6600
7015
|
const resolvedCritical = isCritical || status === "critical";
|
|
6601
7016
|
const emptyText = typeof empty === "string" ? empty : emptyMessage;
|
|
6602
7017
|
const isEmptyState = Boolean(empty);
|
|
@@ -6632,14 +7047,16 @@ function StnWidgetRoot({
|
|
|
6632
7047
|
...rest
|
|
6633
7048
|
};
|
|
6634
7049
|
const slots = partitionWidgetChildren(children);
|
|
6635
|
-
const propHead = shell === "fault-panel" && !isFigmaShell ? title != null || titleActions ? /* @__PURE__ */
|
|
6636
|
-
/* @__PURE__ */
|
|
7050
|
+
const propHead = shell === "fault-panel" && !isFigmaShell ? title != null || titleActions ? /* @__PURE__ */ jsxs42("div", { className: "app_bar", children: [
|
|
7051
|
+
/* @__PURE__ */ jsx53("div", { className: "fault_title_box", children: typeof title === "string" ? /* @__PURE__ */ jsx53("span", { children: title }) : title }),
|
|
6637
7052
|
titleActions
|
|
6638
|
-
] }) : null : shell === "board" || shell === "board-item" ? title != null ? /* @__PURE__ */
|
|
7053
|
+
] }) : null : shell === "board" || shell === "board-item" ? title != null ? /* @__PURE__ */ jsx53("div", { className: "stn-widget__head", children: typeof title === "string" ? /* @__PURE__ */ jsx53("p", { children: title }) : title }) : null : isFigmaShell ? /* @__PURE__ */ jsx53(
|
|
6639
7054
|
StnWidgetHeaderInner,
|
|
6640
7055
|
{
|
|
6641
7056
|
appearance,
|
|
6642
7057
|
title,
|
|
7058
|
+
titleSize,
|
|
7059
|
+
titleWeight,
|
|
6643
7060
|
badge,
|
|
6644
7061
|
titleActions,
|
|
6645
7062
|
periodLabel,
|
|
@@ -6649,48 +7066,55 @@ function StnWidgetRoot({
|
|
|
6649
7066
|
headerIcon,
|
|
6650
7067
|
wrapActions
|
|
6651
7068
|
}
|
|
6652
|
-
) : title != null || badge != null || titleActions ? /* @__PURE__ */
|
|
6653
|
-
/* @__PURE__ */
|
|
6654
|
-
title != null ? typeof title === "string" ? /* @__PURE__ */
|
|
7069
|
+
) : title != null || badge != null || titleActions ? /* @__PURE__ */ jsxs42("div", { className: cn("stn-widget__head", wrapActions && "stn-widget__head--wrap"), children: [
|
|
7070
|
+
/* @__PURE__ */ jsxs42("div", { className: "stn-widget__head-start", children: [
|
|
7071
|
+
title != null ? typeof title === "string" ? /* @__PURE__ */ jsx53("p", { className: cn("stn-widget__title", titleSize, titleWeight), title, children: title }) : title : null,
|
|
6655
7072
|
badge
|
|
6656
7073
|
] }),
|
|
6657
|
-
titleActions ? /* @__PURE__ */
|
|
7074
|
+
titleActions ? /* @__PURE__ */ jsx53("div", { className: "stn-widget__head-end", children: titleActions }) : null
|
|
6658
7075
|
] }) : null;
|
|
6659
7076
|
const head = slots.headers.length > 0 ? slots.headers : propHead;
|
|
6660
7077
|
const autoBodyClass = shell === "fault-panel" && !isFigmaShell ? "table_area" : void 0;
|
|
6661
7078
|
let body;
|
|
6662
7079
|
if (loading) {
|
|
6663
|
-
body = /* @__PURE__ */
|
|
7080
|
+
body = /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__body", autoBodyClass, contentClassName), children: /* @__PURE__ */ jsx53(StnWidgetLoading, {}) });
|
|
6664
7081
|
} else if (slots.bodies.length > 0) {
|
|
6665
7082
|
body = slots.bodies.map(
|
|
6666
7083
|
(slot, index) => mergeBodySlot(slot, index === 0 ? slots.rest : [], contentClassName, isEmptyState, emptyStyle)
|
|
6667
7084
|
);
|
|
6668
7085
|
} else {
|
|
6669
|
-
body = /* @__PURE__ */
|
|
7086
|
+
body = /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__body", autoBodyClass, isEmptyState && "empty", contentClassName), style: emptyStyle, children: slots.rest });
|
|
6670
7087
|
}
|
|
6671
|
-
const footerNode = slots.footers.length > 0 ? slots.footers : footer ? /* @__PURE__ */
|
|
6672
|
-
const card = /* @__PURE__ */
|
|
6673
|
-
isFigmaShell && appearanceShell === "overlay" ? /* @__PURE__ */
|
|
7088
|
+
const footerNode = slots.footers.length > 0 ? slots.footers : footer ? /* @__PURE__ */ jsx53("div", { className: "stn-widget__footer", children: footer }) : null;
|
|
7089
|
+
const card = /* @__PURE__ */ jsxs42("div", { ...rootProps, children: [
|
|
7090
|
+
isFigmaShell && appearanceShell === "overlay" ? /* @__PURE__ */ jsx53("div", { className: "stn-widget__map-deco", "aria-hidden": true }) : null,
|
|
6674
7091
|
head,
|
|
6675
7092
|
body,
|
|
6676
7093
|
footerNode
|
|
6677
7094
|
] });
|
|
6678
7095
|
if (banner == null || banner === false) return card;
|
|
6679
|
-
return /* @__PURE__ */
|
|
7096
|
+
return /* @__PURE__ */ jsxs42("div", { className: "stn-widget-anchor", children: [
|
|
6680
7097
|
withBannerSeverity(banner, bannerSeverityFromStatus(status, isCritical)),
|
|
6681
7098
|
card
|
|
6682
7099
|
] });
|
|
6683
7100
|
}
|
|
6684
7101
|
function StnWidgetHeader({ className, wrap = false, children, ...rest }) {
|
|
6685
|
-
return /* @__PURE__ */
|
|
7102
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__head", wrap && "stn-widget__head--wrap", className), ...rest, children });
|
|
6686
7103
|
}
|
|
6687
7104
|
markWidgetSlot(StnWidgetHeader, "header");
|
|
6688
|
-
function StnWidgetTitle({
|
|
7105
|
+
function StnWidgetTitle({
|
|
7106
|
+
className,
|
|
7107
|
+
children,
|
|
7108
|
+
title,
|
|
7109
|
+
size = "md",
|
|
7110
|
+
weight = "semibold",
|
|
7111
|
+
...rest
|
|
7112
|
+
}) {
|
|
6689
7113
|
const titleAttr = title ?? (typeof children === "string" ? children : void 0);
|
|
6690
|
-
return /* @__PURE__ */
|
|
7114
|
+
return /* @__PURE__ */ jsx53("p", { className: cn("stn-widget__title", size, weight, className), title: titleAttr, ...rest, children });
|
|
6691
7115
|
}
|
|
6692
7116
|
function StnWidgetActions({ className, children, ...rest }) {
|
|
6693
|
-
return /* @__PURE__ */
|
|
7117
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__head-end", className), ...rest, children });
|
|
6694
7118
|
}
|
|
6695
7119
|
function StnWidgetBody({
|
|
6696
7120
|
padding,
|
|
@@ -6704,7 +7128,7 @@ function StnWidgetBody({
|
|
|
6704
7128
|
}) {
|
|
6705
7129
|
const emptyText = typeof empty === "string" ? empty : void 0;
|
|
6706
7130
|
const mergedStyle = emptyText ? { ["--stn-widget-empty-text"]: `"${emptyText}"`, ...style } : style;
|
|
6707
|
-
return /* @__PURE__ */
|
|
7131
|
+
return /* @__PURE__ */ jsx53(
|
|
6708
7132
|
"div",
|
|
6709
7133
|
{
|
|
6710
7134
|
className: cn(
|
|
@@ -6726,7 +7150,7 @@ function StnWidgetBody({
|
|
|
6726
7150
|
}
|
|
6727
7151
|
markWidgetSlot(StnWidgetBody, "body");
|
|
6728
7152
|
function StnWidgetChartSlot({ label = "select chart", className, children, ...rest }) {
|
|
6729
|
-
return /* @__PURE__ */
|
|
7153
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__chart-slot", className), "data-stn-widget-chart-slot": true, ...rest, children: children ?? /* @__PURE__ */ jsx53("span", { className: "stn-widget__chart-slot-label", children: label }) });
|
|
6730
7154
|
}
|
|
6731
7155
|
function StnWidgetStatusItem({
|
|
6732
7156
|
label,
|
|
@@ -6738,9 +7162,9 @@ function StnWidgetStatusItem({
|
|
|
6738
7162
|
...rest
|
|
6739
7163
|
}) {
|
|
6740
7164
|
const grade = gradeProp ?? (status === "warning" ? "minor" : status) ?? "normal";
|
|
6741
|
-
return /* @__PURE__ */
|
|
6742
|
-
/* @__PURE__ */
|
|
6743
|
-
showDot ? /* @__PURE__ */
|
|
7165
|
+
return /* @__PURE__ */ jsxs42("div", { className: cn("stn-widget__status-item", className), ...rest, children: [
|
|
7166
|
+
/* @__PURE__ */ jsxs42("span", { className: "stn-widget__status-label", children: [
|
|
7167
|
+
showDot ? /* @__PURE__ */ jsx53(
|
|
6744
7168
|
"span",
|
|
6745
7169
|
{
|
|
6746
7170
|
className: cn("stn-widget__status-dot", `stn-widget__status-dot--${grade}`),
|
|
@@ -6749,23 +7173,23 @@ function StnWidgetStatusItem({
|
|
|
6749
7173
|
) : null,
|
|
6750
7174
|
label
|
|
6751
7175
|
] }),
|
|
6752
|
-
/* @__PURE__ */
|
|
7176
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-widget__status-val", children: value })
|
|
6753
7177
|
] });
|
|
6754
7178
|
}
|
|
6755
7179
|
function StnWidgetStatusList({ className, children, ...rest }) {
|
|
6756
|
-
return /* @__PURE__ */
|
|
7180
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__status-list", className), ...rest, children });
|
|
6757
7181
|
}
|
|
6758
7182
|
function StnWidgetStatGroup({ className, children, ...rest }) {
|
|
6759
|
-
return /* @__PURE__ */
|
|
7183
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__stat-group", className), ...rest, children });
|
|
6760
7184
|
}
|
|
6761
7185
|
function StnWidgetStatCard({ label, count, className, ...rest }) {
|
|
6762
|
-
return /* @__PURE__ */
|
|
6763
|
-
/* @__PURE__ */
|
|
6764
|
-
/* @__PURE__ */
|
|
7186
|
+
return /* @__PURE__ */ jsxs42("div", { className: cn("stn-widget__stat-card", className), ...rest, children: [
|
|
7187
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-widget__stat-label", children: label }),
|
|
7188
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-widget__stat-count", children: count })
|
|
6765
7189
|
] });
|
|
6766
7190
|
}
|
|
6767
7191
|
function StnWidgetPlaceholder({ label = "\uCF58\uD150\uCE20 \uC601\uC5ED" }) {
|
|
6768
|
-
return /* @__PURE__ */
|
|
7192
|
+
return /* @__PURE__ */ jsx53("div", { className: "stn-widget__placeholder", children: label });
|
|
6769
7193
|
}
|
|
6770
7194
|
var GRADE_ROW_ICON = {
|
|
6771
7195
|
critical: "fill/alert4",
|
|
@@ -6788,42 +7212,42 @@ function StnWidgetGradeRow({
|
|
|
6788
7212
|
}) {
|
|
6789
7213
|
const clamped = Math.max(0, Math.min(100, percent));
|
|
6790
7214
|
const resolvedPercentLabel = percentLabel ?? formatGradePercent(clamped);
|
|
6791
|
-
return /* @__PURE__ */
|
|
6792
|
-
/* @__PURE__ */
|
|
6793
|
-
/* @__PURE__ */
|
|
6794
|
-
/* @__PURE__ */
|
|
7215
|
+
return /* @__PURE__ */ jsxs42("div", { className: cn("stn-widget__grade-row", `stn-widget__grade-row--${grade}`, className), ...rest, children: [
|
|
7216
|
+
/* @__PURE__ */ jsxs42("div", { className: "stn-widget__grade-row-left", children: [
|
|
7217
|
+
/* @__PURE__ */ jsxs42("span", { className: "stn-widget__grade-row-label", children: [
|
|
7218
|
+
/* @__PURE__ */ jsx53(StnIcon, { name: GRADE_ROW_ICON[grade], size: 20, className: "stn-widget__grade-row-icon", "aria-hidden": true }),
|
|
6795
7219
|
label
|
|
6796
7220
|
] }),
|
|
6797
|
-
/* @__PURE__ */
|
|
7221
|
+
/* @__PURE__ */ jsx53("div", { className: "stn-widget__grade-row-track", "aria-hidden": true, children: /* @__PURE__ */ jsx53("span", { className: "stn-widget__grade-row-fill", style: { width: `${clamped}%` } }) })
|
|
6798
7222
|
] }),
|
|
6799
|
-
/* @__PURE__ */
|
|
6800
|
-
/* @__PURE__ */
|
|
6801
|
-
/* @__PURE__ */
|
|
7223
|
+
/* @__PURE__ */ jsxs42("div", { className: "stn-widget__grade-row-right", children: [
|
|
7224
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-widget__grade-row-value", children: value }),
|
|
7225
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-widget__grade-row-percent", children: resolvedPercentLabel })
|
|
6802
7226
|
] })
|
|
6803
7227
|
] });
|
|
6804
7228
|
}
|
|
6805
7229
|
function StnWidgetGradeRowList({ className, children, ...rest }) {
|
|
6806
|
-
return /* @__PURE__ */
|
|
7230
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__grade-row-list", className), ...rest, children });
|
|
6807
7231
|
}
|
|
6808
7232
|
function StnWidgetFooter({ className, children, ...rest }) {
|
|
6809
|
-
return /* @__PURE__ */
|
|
7233
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__footer", className), ...rest, children });
|
|
6810
7234
|
}
|
|
6811
7235
|
markWidgetSlot(StnWidgetFooter, "footer");
|
|
6812
7236
|
function StnWidgetEmpty({ className, children, ...rest }) {
|
|
6813
|
-
return /* @__PURE__ */
|
|
6814
|
-
/* @__PURE__ */
|
|
6815
|
-
/* @__PURE__ */
|
|
6816
|
-
/* @__PURE__ */
|
|
6817
|
-
/* @__PURE__ */
|
|
7237
|
+
return /* @__PURE__ */ jsxs42("div", { className: cn("stn-widget__empty", className), ...rest, children: [
|
|
7238
|
+
/* @__PURE__ */ jsxs42("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", style: { opacity: 0.6 }, children: [
|
|
7239
|
+
/* @__PURE__ */ jsx53("circle", { cx: "12", cy: "12", r: "10" }),
|
|
7240
|
+
/* @__PURE__ */ jsx53("line", { x1: "12", y1: "8", x2: "12", y2: "12" }),
|
|
7241
|
+
/* @__PURE__ */ jsx53("line", { x1: "12", y1: "16", x2: "12.01", y2: "16" })
|
|
6818
7242
|
] }),
|
|
6819
|
-
/* @__PURE__ */
|
|
7243
|
+
/* @__PURE__ */ jsx53("div", { children: children ?? "\uB370\uC774\uD130\uAC00 \uC5C6\uC2B5\uB2C8\uB2E4." })
|
|
6820
7244
|
] });
|
|
6821
7245
|
}
|
|
6822
7246
|
function StnWidgetLoading({ lines = 3, className, children, ...rest }) {
|
|
6823
|
-
return /* @__PURE__ */
|
|
7247
|
+
return /* @__PURE__ */ jsx53("div", { className: cn("stn-widget__loading", className), ...rest, children: children ?? /* @__PURE__ */ jsx53(StnLoadingSkeleton.Widget, { lines }) });
|
|
6824
7248
|
}
|
|
6825
7249
|
function StnWidgetInsetIcon({ className, size = "sm", ...rest }) {
|
|
6826
|
-
return /* @__PURE__ */
|
|
7250
|
+
return /* @__PURE__ */ jsx53(StnIconBox, { size, className: cn("stn-widget__inset-icon", className), ...rest });
|
|
6827
7251
|
}
|
|
6828
7252
|
var StnWidget = Object.assign(StnWidgetRoot, {
|
|
6829
7253
|
Header: StnWidgetHeader,
|
|
@@ -6870,11 +7294,11 @@ import {
|
|
|
6870
7294
|
// src/layouts/StnStack.tsx
|
|
6871
7295
|
import {
|
|
6872
7296
|
Children as Children3,
|
|
6873
|
-
forwardRef as
|
|
7297
|
+
forwardRef as forwardRef29,
|
|
6874
7298
|
Fragment as Fragment6,
|
|
6875
7299
|
isValidElement as isValidElement6
|
|
6876
7300
|
} from "react";
|
|
6877
|
-
import { jsx as
|
|
7301
|
+
import { jsx as jsx54, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
6878
7302
|
var BREAKPOINTS = ["xs", "sm", "md", "lg", "xl"];
|
|
6879
7303
|
var DIRECTION_CLASS = /* @__PURE__ */ new Set(["row", "row-reverse", "column", "column-reverse"]);
|
|
6880
7304
|
var STACK_SPACE_TOKENS = /* @__PURE__ */ new Set([2, 4, 6, 8, 10, 12, 14, 16, 20, 24, 32, 36, 40, 44, 48, 56, 64, 80, 84]);
|
|
@@ -6967,7 +7391,7 @@ function spacingClassesAndStyle(spacing) {
|
|
|
6967
7391
|
}
|
|
6968
7392
|
return { classes, inlineGap };
|
|
6969
7393
|
}
|
|
6970
|
-
var StnStack =
|
|
7394
|
+
var StnStack = forwardRef29(function StnStack2({
|
|
6971
7395
|
component,
|
|
6972
7396
|
as,
|
|
6973
7397
|
direction = "column",
|
|
@@ -6997,12 +7421,12 @@ var StnStack = forwardRef26(function StnStack2({
|
|
|
6997
7421
|
const validChildren = Children3.toArray(children).filter(Boolean);
|
|
6998
7422
|
const renderedChildren = divider ? validChildren.map((child, index) => {
|
|
6999
7423
|
const key = isValidElement6(child) && child.key != null ? child.key : index;
|
|
7000
|
-
return /* @__PURE__ */
|
|
7424
|
+
return /* @__PURE__ */ jsxs43(Fragment6, { children: [
|
|
7001
7425
|
index > 0 ? divider : null,
|
|
7002
7426
|
child
|
|
7003
7427
|
] }, key);
|
|
7004
7428
|
}) : children;
|
|
7005
|
-
return /* @__PURE__ */
|
|
7429
|
+
return /* @__PURE__ */ jsx54(
|
|
7006
7430
|
Component,
|
|
7007
7431
|
{
|
|
7008
7432
|
ref,
|
|
@@ -7026,7 +7450,7 @@ var StnStack = forwardRef26(function StnStack2({
|
|
|
7026
7450
|
});
|
|
7027
7451
|
|
|
7028
7452
|
// src/patterns/dashboard/AlertCenterDashboard.tsx
|
|
7029
|
-
import { jsx as
|
|
7453
|
+
import { jsx as jsx55, jsxs as jsxs44 } from "react/jsx-runtime";
|
|
7030
7454
|
var TOP5_ROWS = [
|
|
7031
7455
|
{ label: "\uADF8\uB791\uC2DC\uC544", percent: 80, value: "80\uAC74", grade: "critical" },
|
|
7032
7456
|
{ label: "\uC5F0\uB9BD\uC8FC\uD0DD 15\uC138\uB300", percent: 74, value: "74\uAC74", grade: "major" },
|
|
@@ -7035,7 +7459,7 @@ var TOP5_ROWS = [
|
|
|
7035
7459
|
{ label: "PRADA", percent: 68, value: "68\uAC74", grade: "default" }
|
|
7036
7460
|
];
|
|
7037
7461
|
function AlertCenterDashboard({ className, appearance = "translucent", loading = false }) {
|
|
7038
|
-
return /* @__PURE__ */
|
|
7462
|
+
return /* @__PURE__ */ jsxs44(
|
|
7039
7463
|
StnStack,
|
|
7040
7464
|
{
|
|
7041
7465
|
direction: "column",
|
|
@@ -7044,17 +7468,17 @@ function AlertCenterDashboard({ className, appearance = "translucent", loading =
|
|
|
7044
7468
|
style: { flex: "1 1 0%", minHeight: 0, height: "100%", width: "100%" },
|
|
7045
7469
|
"data-stn-dashboard": "alert-widgets",
|
|
7046
7470
|
children: [
|
|
7047
|
-
/* @__PURE__ */
|
|
7048
|
-
/* @__PURE__ */
|
|
7049
|
-
/* @__PURE__ */
|
|
7050
|
-
/* @__PURE__ */
|
|
7471
|
+
/* @__PURE__ */ jsx55(StnWidget, { title: "\uC2DC\uC124 \uD604\uD669", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx55(StnLoadingSkeleton.Widget, { lines: 3 }) : /* @__PURE__ */ jsxs44(StnWidget.StatusList, { children: [
|
|
7472
|
+
/* @__PURE__ */ jsx55(StnWidget.StatusItem, { label: "PTN", value: "179", showDot: false }),
|
|
7473
|
+
/* @__PURE__ */ jsx55(StnWidget.StatusItem, { label: "MSPP", value: "63", showDot: false }),
|
|
7474
|
+
/* @__PURE__ */ jsx55(StnWidget.StatusItem, { label: "L3\uC2A4\uC704\uCE58", value: "27", showDot: false })
|
|
7051
7475
|
] }) }),
|
|
7052
|
-
/* @__PURE__ */
|
|
7053
|
-
/* @__PURE__ */
|
|
7054
|
-
/* @__PURE__ */
|
|
7055
|
-
/* @__PURE__ */
|
|
7476
|
+
/* @__PURE__ */ jsx55(StnWidget, { title: "\uC7A5\uC560 \uD604\uD669", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx55(StnLoadingSkeleton.Widget, { lines: 3 }) : /* @__PURE__ */ jsxs44(StnWidget.StatusList, { children: [
|
|
7477
|
+
/* @__PURE__ */ jsx55(StnWidget.StatusItem, { label: "Critical", value: "43", grade: "critical" }),
|
|
7478
|
+
/* @__PURE__ */ jsx55(StnWidget.StatusItem, { label: "Major", value: "79", grade: "major" }),
|
|
7479
|
+
/* @__PURE__ */ jsx55(StnWidget.StatusItem, { label: "Minor", value: "3", grade: "minor" })
|
|
7056
7480
|
] }) }),
|
|
7057
|
-
/* @__PURE__ */
|
|
7481
|
+
/* @__PURE__ */ jsx55(StnWidget, { title: "\uC77C\uC77C \uC7A5\uBE44\uBCC4 \uC7A5\uC560 TOP5", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx55(StnLoadingSkeleton.Widget, { lines: 4 }) : /* @__PURE__ */ jsx55(StnWidget.GradeRowList, { children: TOP5_ROWS.map((row) => /* @__PURE__ */ jsx55(
|
|
7058
7482
|
StnWidget.GradeRow,
|
|
7059
7483
|
{
|
|
7060
7484
|
grade: row.grade,
|
|
@@ -7064,50 +7488,50 @@ function AlertCenterDashboard({ className, appearance = "translucent", loading =
|
|
|
7064
7488
|
},
|
|
7065
7489
|
row.label
|
|
7066
7490
|
)) }) }),
|
|
7067
|
-
/* @__PURE__ */
|
|
7491
|
+
/* @__PURE__ */ jsx55(StnWidget, { title: "\uC77C\uC77C \uC7A5\uC560 \uD1B5\uACC4", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx55(StnLoadingSkeleton.Widget, { lines: 3 }) : /* @__PURE__ */ jsx55(StnWidget.ChartSlot, { label: "\uC77C\uC77C \uC7A5\uC560 \uD1B5\uACC4 \uCC28\uD2B8" }) })
|
|
7068
7492
|
]
|
|
7069
7493
|
}
|
|
7070
7494
|
);
|
|
7071
7495
|
}
|
|
7072
7496
|
|
|
7073
7497
|
// src/patterns/dashboard/PubDashboardWidgetBodies.tsx
|
|
7074
|
-
import { jsx as
|
|
7498
|
+
import { jsx as jsx56, jsxs as jsxs45 } from "react/jsx-runtime";
|
|
7075
7499
|
function PubDisabilityStatusList({ items, summary }) {
|
|
7076
|
-
return /* @__PURE__ */
|
|
7077
|
-
/* @__PURE__ */
|
|
7500
|
+
return /* @__PURE__ */ jsxs45("div", { className: "ds-disability-status", children: [
|
|
7501
|
+
/* @__PURE__ */ jsx56("ul", { className: "ds-disability-status__list", children: items.map((item, i) => /* @__PURE__ */ jsxs45(
|
|
7078
7502
|
"li",
|
|
7079
7503
|
{
|
|
7080
7504
|
className: ["ds-disability-status__item", item.grade].filter(Boolean).join(" "),
|
|
7081
7505
|
children: [
|
|
7082
|
-
/* @__PURE__ */
|
|
7083
|
-
item.showDot !== false && item.grade ? /* @__PURE__ */
|
|
7506
|
+
/* @__PURE__ */ jsxs45("span", { children: [
|
|
7507
|
+
item.showDot !== false && item.grade ? /* @__PURE__ */ jsx56("span", { className: "dot", "aria-hidden": true }) : null,
|
|
7084
7508
|
item.label
|
|
7085
7509
|
] }),
|
|
7086
|
-
/* @__PURE__ */
|
|
7510
|
+
/* @__PURE__ */ jsx56("p", { children: item.value })
|
|
7087
7511
|
]
|
|
7088
7512
|
},
|
|
7089
7513
|
i
|
|
7090
7514
|
)) }),
|
|
7091
|
-
summary && summary.length > 0 ? /* @__PURE__ */
|
|
7515
|
+
summary && summary.length > 0 ? /* @__PURE__ */ jsx56("div", { className: "ds-disability-status__summary", children: summary.map((row, i) => /* @__PURE__ */ jsxs45("p", { className: "ds-disability-status__value", children: [
|
|
7092
7516
|
row.label,
|
|
7093
|
-
/* @__PURE__ */
|
|
7517
|
+
/* @__PURE__ */ jsx56("span", { children: row.value })
|
|
7094
7518
|
] }, i)) }) : null
|
|
7095
7519
|
] });
|
|
7096
7520
|
}
|
|
7097
7521
|
function PubTrafficTop5Bars({ rows }) {
|
|
7098
7522
|
const maxPercent = Math.max(...rows.map((row) => row.percent), 0);
|
|
7099
|
-
return /* @__PURE__ */
|
|
7100
|
-
/* @__PURE__ */
|
|
7101
|
-
/* @__PURE__ */
|
|
7102
|
-
/* @__PURE__ */
|
|
7523
|
+
return /* @__PURE__ */ jsx56("div", { className: "ds-bar-group", children: rows.map((row) => /* @__PURE__ */ jsxs45("div", { className: ["ds-bar", row.percent === maxPercent ? "max" : ""].filter(Boolean).join(" "), children: [
|
|
7524
|
+
/* @__PURE__ */ jsx56("p", { className: "ds-bar-name", title: row.label, children: row.label }),
|
|
7525
|
+
/* @__PURE__ */ jsx56("div", { className: "ds-bar-con", title: `${row.percent}%`, children: /* @__PURE__ */ jsx56("span", { className: "ds-bar-gauge", style: { "--percent": `${row.percent}%` } }) }),
|
|
7526
|
+
/* @__PURE__ */ jsx56("p", { className: "ds-bar-value", title: row.value, children: row.value })
|
|
7103
7527
|
] }, row.label)) });
|
|
7104
7528
|
}
|
|
7105
7529
|
function PubTop5EquipmentBars({ rows }) {
|
|
7106
|
-
return /* @__PURE__ */
|
|
7107
|
-
/* @__PURE__ */
|
|
7108
|
-
/* @__PURE__ */
|
|
7109
|
-
/* @__PURE__ */
|
|
7110
|
-
/* @__PURE__ */
|
|
7530
|
+
return /* @__PURE__ */ jsxs45("div", { className: "ds-group", children: [
|
|
7531
|
+
/* @__PURE__ */ jsx56("div", { className: "ds-group-box", children: /* @__PURE__ */ jsx56("div", { className: "ds-equipment-ico", children: /* @__PURE__ */ jsx56("span", { className: "blind", children: "\uC7A5\uBE44 \uC774\uBBF8\uC9C0" }) }) }),
|
|
7532
|
+
/* @__PURE__ */ jsx56("div", { className: "ds-group-box", children: /* @__PURE__ */ jsx56("div", { className: "ds-bar-group", children: rows.map((row) => /* @__PURE__ */ jsx56("div", { className: "ds-bar type-2", children: /* @__PURE__ */ jsxs45("div", { className: "ds-bar-con", title: `${row.percent}%`, children: [
|
|
7533
|
+
/* @__PURE__ */ jsx56("span", { className: "ds-bar-gauge", style: { "--percent": `${row.percent}%` } }),
|
|
7534
|
+
/* @__PURE__ */ jsx56("div", { className: "ds-bar-status", children: row.status })
|
|
7111
7535
|
] }) }, row.label)) }) })
|
|
7112
7536
|
] });
|
|
7113
7537
|
}
|
|
@@ -7116,15 +7540,15 @@ function PubChartSample({
|
|
|
7116
7540
|
alt = "\uCC28\uD2B8",
|
|
7117
7541
|
onError
|
|
7118
7542
|
}) {
|
|
7119
|
-
return /* @__PURE__ */
|
|
7543
|
+
return /* @__PURE__ */ jsx56("div", { className: "ds-chart", children: /* @__PURE__ */ jsx56("img", { src, alt, className: "chart_sample", onError }) });
|
|
7120
7544
|
}
|
|
7121
7545
|
|
|
7122
7546
|
// src/patterns/alertCenter/StnAlertCenterPanel.tsx
|
|
7123
|
-
import { useState as
|
|
7547
|
+
import { useState as useState16 } from "react";
|
|
7124
7548
|
import {
|
|
7125
7549
|
STN_ALERT_CENTER_TABS
|
|
7126
7550
|
} from "@stn-uiux/pub-ui/data/stnAlertCenter";
|
|
7127
|
-
import { jsx as
|
|
7551
|
+
import { jsx as jsx57, jsxs as jsxs46 } from "react/jsx-runtime";
|
|
7128
7552
|
function resolveAlertIcon(item) {
|
|
7129
7553
|
if (item.icon) {
|
|
7130
7554
|
if (item.icon === "line/arrow-down") return "line/arrow-narrow-down";
|
|
@@ -7151,7 +7575,7 @@ function StnAlertCard({
|
|
|
7151
7575
|
}) {
|
|
7152
7576
|
const iconNode = resolveAlertIcon(item);
|
|
7153
7577
|
const gradeLabel = resolveGradeLabel(item.grade);
|
|
7154
|
-
return /* @__PURE__ */
|
|
7578
|
+
return /* @__PURE__ */ jsx57(
|
|
7155
7579
|
StnCard,
|
|
7156
7580
|
{
|
|
7157
7581
|
variant: "elevated",
|
|
@@ -7160,8 +7584,8 @@ function StnAlertCard({
|
|
|
7160
7584
|
interactive: true,
|
|
7161
7585
|
className: cn("stn-alert-card", className),
|
|
7162
7586
|
onClick,
|
|
7163
|
-
children: /* @__PURE__ */
|
|
7164
|
-
/* @__PURE__ */
|
|
7587
|
+
children: /* @__PURE__ */ jsxs46("div", { className: "stn-alert-card__row", children: [
|
|
7588
|
+
/* @__PURE__ */ jsx57(
|
|
7165
7589
|
StnIcon,
|
|
7166
7590
|
{
|
|
7167
7591
|
name: iconNode,
|
|
@@ -7170,9 +7594,9 @@ function StnAlertCard({
|
|
|
7170
7594
|
className: "stn-alert-card__icon"
|
|
7171
7595
|
}
|
|
7172
7596
|
),
|
|
7173
|
-
/* @__PURE__ */
|
|
7174
|
-
/* @__PURE__ */
|
|
7175
|
-
/* @__PURE__ */
|
|
7597
|
+
/* @__PURE__ */ jsxs46("div", { className: "stn-alert-card__body", children: [
|
|
7598
|
+
/* @__PURE__ */ jsxs46(StnStack, { direction: "row", alignItems: "center", spacing: 1, className: "stn-alert-card__header-line", children: [
|
|
7599
|
+
/* @__PURE__ */ jsx57(
|
|
7176
7600
|
StnChip,
|
|
7177
7601
|
{
|
|
7178
7602
|
shape: "pill",
|
|
@@ -7182,25 +7606,25 @@ function StnAlertCard({
|
|
|
7182
7606
|
children: gradeLabel
|
|
7183
7607
|
}
|
|
7184
7608
|
),
|
|
7185
|
-
/* @__PURE__ */
|
|
7609
|
+
/* @__PURE__ */ jsx57(
|
|
7186
7610
|
"span",
|
|
7187
7611
|
{
|
|
7188
7612
|
className: cn("stn-alert-card__title", titleOverflow),
|
|
7189
7613
|
title: item.title,
|
|
7190
|
-
children: /* @__PURE__ */
|
|
7614
|
+
children: /* @__PURE__ */ jsx57("span", { className: "stn-alert-card__text-inner", children: item.title })
|
|
7191
7615
|
}
|
|
7192
7616
|
)
|
|
7193
7617
|
] }),
|
|
7194
|
-
/* @__PURE__ */
|
|
7195
|
-
/* @__PURE__ */
|
|
7618
|
+
/* @__PURE__ */ jsxs46(StnStack, { direction: "row", alignItems: "center", spacing: 2, wrap: "wrap", className: "stn-alert-card__desc-line", children: [
|
|
7619
|
+
/* @__PURE__ */ jsx57(
|
|
7196
7620
|
"span",
|
|
7197
7621
|
{
|
|
7198
7622
|
className: cn("stn-alert-card__desc", descOverflow),
|
|
7199
7623
|
title: item.description,
|
|
7200
|
-
children: /* @__PURE__ */
|
|
7624
|
+
children: /* @__PURE__ */ jsx57("span", { className: "stn-alert-card__text-inner", children: item.description })
|
|
7201
7625
|
}
|
|
7202
7626
|
),
|
|
7203
|
-
item.occurredAt && /* @__PURE__ */
|
|
7627
|
+
item.occurredAt && /* @__PURE__ */ jsxs46(
|
|
7204
7628
|
StnChip,
|
|
7205
7629
|
{
|
|
7206
7630
|
shape: "pill",
|
|
@@ -7216,9 +7640,9 @@ function StnAlertCard({
|
|
|
7216
7640
|
)
|
|
7217
7641
|
] })
|
|
7218
7642
|
] }),
|
|
7219
|
-
/* @__PURE__ */
|
|
7220
|
-
/* @__PURE__ */
|
|
7221
|
-
item.unread !== false && /* @__PURE__ */
|
|
7643
|
+
/* @__PURE__ */ jsxs46("div", { className: "stn-alert-card__meta", children: [
|
|
7644
|
+
/* @__PURE__ */ jsx57("span", { className: "stn-alert-card__time", children: item.time }),
|
|
7645
|
+
item.unread !== false && /* @__PURE__ */ jsx57(
|
|
7222
7646
|
"span",
|
|
7223
7647
|
{
|
|
7224
7648
|
className: cn(
|
|
@@ -7252,11 +7676,11 @@ function StnAlertCenterPanel({
|
|
|
7252
7676
|
closeLabel = "\uB2EB\uAE30",
|
|
7253
7677
|
className
|
|
7254
7678
|
}) {
|
|
7255
|
-
const [activeTab, setActiveTab] =
|
|
7679
|
+
const [activeTab, setActiveTab] = useState16(defaultTab);
|
|
7256
7680
|
const alertCount = alerts.length;
|
|
7257
7681
|
const resolvedTitleOverflow = titleOverflow ?? textOverflow;
|
|
7258
7682
|
const resolvedDescOverflow = descOverflow ?? textOverflow;
|
|
7259
|
-
return /* @__PURE__ */
|
|
7683
|
+
return /* @__PURE__ */ jsxs46(
|
|
7260
7684
|
"div",
|
|
7261
7685
|
{
|
|
7262
7686
|
className: cn(
|
|
@@ -7268,13 +7692,13 @@ function StnAlertCenterPanel({
|
|
|
7268
7692
|
),
|
|
7269
7693
|
"data-stn-alert-center": true,
|
|
7270
7694
|
children: [
|
|
7271
|
-
/* @__PURE__ */
|
|
7272
|
-
/* @__PURE__ */
|
|
7273
|
-
/* @__PURE__ */
|
|
7274
|
-
/* @__PURE__ */
|
|
7275
|
-
alertCount > 0 && /* @__PURE__ */
|
|
7695
|
+
/* @__PURE__ */ jsxs46("div", { className: "stn-alert-center__header", children: [
|
|
7696
|
+
/* @__PURE__ */ jsxs46("div", { className: "stn-alert-center__header-left", children: [
|
|
7697
|
+
/* @__PURE__ */ jsx57(StnIcon, { name: "line/bell", size: 20, color: "var(--stn-primary)" }),
|
|
7698
|
+
/* @__PURE__ */ jsx57("span", { className: "stn-alert-center__title", children: title }),
|
|
7699
|
+
alertCount > 0 && /* @__PURE__ */ jsx57(StnChip, { shape: "pill", size: "sm", variant: "subtle", color: "primary", children: alertCount })
|
|
7276
7700
|
] }),
|
|
7277
|
-
/* @__PURE__ */
|
|
7701
|
+
/* @__PURE__ */ jsx57(
|
|
7278
7702
|
StnSegmented,
|
|
7279
7703
|
{
|
|
7280
7704
|
size: "md",
|
|
@@ -7287,8 +7711,8 @@ function StnAlertCenterPanel({
|
|
|
7287
7711
|
}))
|
|
7288
7712
|
}
|
|
7289
7713
|
),
|
|
7290
|
-
/* @__PURE__ */
|
|
7291
|
-
/* @__PURE__ */
|
|
7714
|
+
/* @__PURE__ */ jsxs46("div", { className: "stn-alert-center__header-right", children: [
|
|
7715
|
+
/* @__PURE__ */ jsx57(
|
|
7292
7716
|
StnButton,
|
|
7293
7717
|
{
|
|
7294
7718
|
variant: "text",
|
|
@@ -7298,8 +7722,8 @@ function StnAlertCenterPanel({
|
|
|
7298
7722
|
children: "\uBAA8\uB450 \uC77D\uC74C"
|
|
7299
7723
|
}
|
|
7300
7724
|
),
|
|
7301
|
-
/* @__PURE__ */
|
|
7302
|
-
/* @__PURE__ */
|
|
7725
|
+
/* @__PURE__ */ jsx57("div", { className: "stn-alert-center__divider", "aria-hidden": true }),
|
|
7726
|
+
/* @__PURE__ */ jsx57(
|
|
7303
7727
|
StnButton,
|
|
7304
7728
|
{
|
|
7305
7729
|
icon: "line/x",
|
|
@@ -7311,14 +7735,14 @@ function StnAlertCenterPanel({
|
|
|
7311
7735
|
)
|
|
7312
7736
|
] })
|
|
7313
7737
|
] }),
|
|
7314
|
-
/* @__PURE__ */
|
|
7738
|
+
/* @__PURE__ */ jsxs46(
|
|
7315
7739
|
StnScroll,
|
|
7316
7740
|
{
|
|
7317
7741
|
orientation: "vertical",
|
|
7318
7742
|
size: "thin",
|
|
7319
7743
|
className: "stn-alert-center__list-wrap",
|
|
7320
7744
|
children: [
|
|
7321
|
-
activeTab === "error" && /* @__PURE__ */
|
|
7745
|
+
activeTab === "error" && /* @__PURE__ */ jsx57("ul", { className: "stn-alert-center__list", children: alerts.map((item) => /* @__PURE__ */ jsx57("li", { children: /* @__PURE__ */ jsx57(
|
|
7322
7746
|
StnAlertCard,
|
|
7323
7747
|
{
|
|
7324
7748
|
item,
|
|
@@ -7327,35 +7751,35 @@ function StnAlertCenterPanel({
|
|
|
7327
7751
|
onClick: () => onItemClick?.(item)
|
|
7328
7752
|
}
|
|
7329
7753
|
) }, item.id ?? item.title)) }),
|
|
7330
|
-
activeTab === "work" && /* @__PURE__ */
|
|
7331
|
-
/* @__PURE__ */
|
|
7332
|
-
/* @__PURE__ */
|
|
7333
|
-
/* @__PURE__ */
|
|
7334
|
-
/* @__PURE__ */
|
|
7754
|
+
activeTab === "work" && /* @__PURE__ */ jsx57("ul", { className: "stn-alert-center__list", children: workItems.map((row) => /* @__PURE__ */ jsx57("li", { children: /* @__PURE__ */ jsx57(StnCard, { variant: "elevated", radius: "md", padding: "md", interactive: true, className: "stn-alert-card", children: /* @__PURE__ */ jsxs46("div", { className: "stn-alert-card__row", children: [
|
|
7755
|
+
/* @__PURE__ */ jsx57(StnIcon, { name: "line/clock", size: 24, color: "var(--stn-text-secondary)", className: "stn-alert-card__icon" }),
|
|
7756
|
+
/* @__PURE__ */ jsxs46("div", { className: "stn-alert-card__body", children: [
|
|
7757
|
+
/* @__PURE__ */ jsx57("span", { className: "stn-alert-card__type-label work", children: row.typeLabel }),
|
|
7758
|
+
/* @__PURE__ */ jsx57("span", { className: cn("stn-alert-card__desc", resolvedDescOverflow), title: row.text, children: /* @__PURE__ */ jsx57("span", { className: "stn-alert-card__text-inner", children: row.text }) })
|
|
7335
7759
|
] }),
|
|
7336
|
-
/* @__PURE__ */
|
|
7760
|
+
/* @__PURE__ */ jsx57("span", { className: "stn-alert-card__time", children: row.time })
|
|
7337
7761
|
] }) }) }, row.id ?? row.text)) }),
|
|
7338
|
-
activeTab === "deploy" && /* @__PURE__ */
|
|
7339
|
-
/* @__PURE__ */
|
|
7340
|
-
/* @__PURE__ */
|
|
7341
|
-
/* @__PURE__ */
|
|
7342
|
-
/* @__PURE__ */
|
|
7762
|
+
activeTab === "deploy" && /* @__PURE__ */ jsx57("ul", { className: "stn-alert-center__list", children: deployItems.map((row) => /* @__PURE__ */ jsx57("li", { children: /* @__PURE__ */ jsx57(StnCard, { variant: "elevated", radius: "md", padding: "md", interactive: true, className: "stn-alert-card", children: /* @__PURE__ */ jsxs46("div", { className: "stn-alert-card__row", children: [
|
|
7763
|
+
/* @__PURE__ */ jsx57(StnIcon, { name: "line/settings", size: 24, color: "var(--stn-secondary)", className: "stn-alert-card__icon" }),
|
|
7764
|
+
/* @__PURE__ */ jsxs46("div", { className: "stn-alert-card__body", children: [
|
|
7765
|
+
/* @__PURE__ */ jsx57("span", { className: "stn-alert-card__type-label stn-alert-card__type-label--deploy", children: row.typeLabel }),
|
|
7766
|
+
/* @__PURE__ */ jsx57("span", { className: cn("stn-alert-card__desc", resolvedDescOverflow), title: row.text, children: /* @__PURE__ */ jsx57("span", { className: "stn-alert-card__text-inner", children: row.text }) })
|
|
7343
7767
|
] }),
|
|
7344
|
-
/* @__PURE__ */
|
|
7768
|
+
/* @__PURE__ */ jsx57("span", { className: "stn-alert-card__time", children: row.time })
|
|
7345
7769
|
] }) }) }, row.id ?? row.text)) })
|
|
7346
7770
|
]
|
|
7347
7771
|
}
|
|
7348
7772
|
),
|
|
7349
|
-
/* @__PURE__ */
|
|
7773
|
+
/* @__PURE__ */ jsx57("div", { className: "stn-alert-center__footer", children: /* @__PURE__ */ jsxs46(
|
|
7350
7774
|
"button",
|
|
7351
7775
|
{
|
|
7352
7776
|
type: "button",
|
|
7353
7777
|
className: "stn-alert-center__footer-link",
|
|
7354
7778
|
onClick: onManageSettings,
|
|
7355
7779
|
children: [
|
|
7356
|
-
/* @__PURE__ */
|
|
7357
|
-
/* @__PURE__ */
|
|
7358
|
-
/* @__PURE__ */
|
|
7780
|
+
/* @__PURE__ */ jsx57("span", { children: "\uC54C\uB9BC \uC124\uC815 \uAD00\uB9AC" }),
|
|
7781
|
+
/* @__PURE__ */ jsx57(StnIcon, { name: "line/settings", size: 14 }),
|
|
7782
|
+
/* @__PURE__ */ jsx57(StnIcon, { name: "line/chevron-right", size: 14 })
|
|
7359
7783
|
]
|
|
7360
7784
|
}
|
|
7361
7785
|
) })
|
|
@@ -7365,18 +7789,18 @@ function StnAlertCenterPanel({
|
|
|
7365
7789
|
}
|
|
7366
7790
|
|
|
7367
7791
|
// src/patterns/alertCenter/StnAlertCenterDocPreview.tsx
|
|
7368
|
-
import { jsx as
|
|
7792
|
+
import { jsx as jsx58 } from "react/jsx-runtime";
|
|
7369
7793
|
function StnAlertCenterDocPreview({
|
|
7370
7794
|
theme = "light",
|
|
7371
7795
|
withDocChrome = true,
|
|
7372
7796
|
children,
|
|
7373
7797
|
...panelProps
|
|
7374
7798
|
}) {
|
|
7375
|
-
const panel = children ?? /* @__PURE__ */
|
|
7799
|
+
const panel = children ?? /* @__PURE__ */ jsx58(StnAlertCenterPanel, { ...panelProps });
|
|
7376
7800
|
if (!withDocChrome) {
|
|
7377
|
-
return /* @__PURE__ */
|
|
7801
|
+
return /* @__PURE__ */ jsx58(StnProvider, { theme, applyThemeToDocument: false, children: panel });
|
|
7378
7802
|
}
|
|
7379
|
-
return /* @__PURE__ */
|
|
7803
|
+
return /* @__PURE__ */ jsx58("div", { className: "stn-doc-frame stn-doc-frame--alert-center", "data-theme": theme, children: /* @__PURE__ */ jsx58("div", { className: "stn-alert-center-preview-shell", children: panel }) });
|
|
7380
7804
|
}
|
|
7381
7805
|
|
|
7382
7806
|
// src/index.ts
|
|
@@ -7393,21 +7817,21 @@ import {
|
|
|
7393
7817
|
} from "@stn-uiux/pub-ui/data/stnAlertCenter";
|
|
7394
7818
|
|
|
7395
7819
|
// src/components/sideNav/SideNavContext.ts
|
|
7396
|
-
import { createContext as
|
|
7397
|
-
var SideNavContext =
|
|
7820
|
+
import { createContext as createContext4, useContext as useContext4 } from "react";
|
|
7821
|
+
var SideNavContext = createContext4({
|
|
7398
7822
|
collapsed: false,
|
|
7399
7823
|
mobileOpen: false
|
|
7400
7824
|
});
|
|
7401
|
-
var useSideNav = () =>
|
|
7825
|
+
var useSideNav = () => useContext4(SideNavContext);
|
|
7402
7826
|
|
|
7403
7827
|
// src/components/sideNav/StnSideNavItem.tsx
|
|
7404
|
-
import { forwardRef as
|
|
7828
|
+
import { forwardRef as forwardRef30 } from "react";
|
|
7405
7829
|
import { STN_NAV_MENU_SUB_ICON } from "@stn-uiux/pub-ui/data/stnSideNavItem";
|
|
7406
|
-
import { jsx as
|
|
7830
|
+
import { jsx as jsx59, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
7407
7831
|
function maskStyle2(src) {
|
|
7408
7832
|
return { maskImage: `url('${src}')`, WebkitMaskImage: `url('${src}')` };
|
|
7409
7833
|
}
|
|
7410
|
-
var StnSideNavItem =
|
|
7834
|
+
var StnSideNavItem = forwardRef30(function StnSideNavItem2({
|
|
7411
7835
|
label,
|
|
7412
7836
|
id,
|
|
7413
7837
|
iconSrc,
|
|
@@ -7450,13 +7874,13 @@ var StnSideNavItem = forwardRef27(function StnSideNavItem2({
|
|
|
7450
7874
|
sideNav.onSelect(id);
|
|
7451
7875
|
}
|
|
7452
7876
|
};
|
|
7453
|
-
const iconElement = hasIcon && !isSub ? /* @__PURE__ */
|
|
7454
|
-
/* @__PURE__ */
|
|
7455
|
-
showDot ? /* @__PURE__ */
|
|
7877
|
+
const iconElement = hasIcon && !isSub ? /* @__PURE__ */ jsxs47("span", { className: "stn-side-nav-item__icon-wrap", children: [
|
|
7878
|
+
/* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__icon", "aria-hidden": "true", children: icon ?? (resolvedIconSrc ? /* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__icon-glyph", style: maskStyle2(resolvedIconSrc) }) : null) }),
|
|
7879
|
+
showDot ? /* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__dot-wrap", "aria-hidden": "true", children: /* @__PURE__ */ jsx59(StnBadge, { variant: "dot", color: "error" }) }) : null
|
|
7456
7880
|
] }) : null;
|
|
7457
|
-
const subIconElement = hasIcon && isSub ? /* @__PURE__ */
|
|
7881
|
+
const subIconElement = hasIcon && isSub ? /* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__sub-icon", "aria-hidden": "true", children: icon ?? (resolvedIconSrc ? /* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__icon-glyph", style: maskStyle2(resolvedIconSrc) }) : null) }) : null;
|
|
7458
7882
|
const activeIconElement = isSub ? subIconElement : iconElement;
|
|
7459
|
-
return /* @__PURE__ */
|
|
7883
|
+
return /* @__PURE__ */ jsx59(
|
|
7460
7884
|
"button",
|
|
7461
7885
|
{
|
|
7462
7886
|
ref,
|
|
@@ -7475,10 +7899,10 @@ var StnSideNavItem = forwardRef27(function StnSideNavItem2({
|
|
|
7475
7899
|
title: collapsed ? label : void 0,
|
|
7476
7900
|
onClick: handleClick,
|
|
7477
7901
|
...rest,
|
|
7478
|
-
children: /* @__PURE__ */
|
|
7479
|
-
/* @__PURE__ */
|
|
7480
|
-
isSub && showSubIndent ? /* @__PURE__ */
|
|
7481
|
-
shouldShowSubDot ? /* @__PURE__ */
|
|
7902
|
+
children: /* @__PURE__ */ jsxs47("span", { className: cn("stn-side-nav-item__inner", spreadTrail && "spread"), children: [
|
|
7903
|
+
/* @__PURE__ */ jsxs47("span", { className: "stn-side-nav-item__lead", children: [
|
|
7904
|
+
isSub && showSubIndent ? /* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__sub-indent", "aria-hidden": "true" }) : null,
|
|
7905
|
+
shouldShowSubDot ? /* @__PURE__ */ jsx59(
|
|
7482
7906
|
"span",
|
|
7483
7907
|
{
|
|
7484
7908
|
className: cn(
|
|
@@ -7486,14 +7910,14 @@ var StnSideNavItem = forwardRef27(function StnSideNavItem2({
|
|
|
7486
7910
|
hasIcon && iconPosition === "left" && "compact"
|
|
7487
7911
|
),
|
|
7488
7912
|
"aria-hidden": "true",
|
|
7489
|
-
children: /* @__PURE__ */
|
|
7913
|
+
children: /* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__sub-dot-glyph", style: maskStyle2(STN_NAV_MENU_SUB_ICON) })
|
|
7490
7914
|
}
|
|
7491
7915
|
) : null,
|
|
7492
7916
|
iconPosition === "left" ? activeIconElement : null,
|
|
7493
|
-
/* @__PURE__ */
|
|
7917
|
+
/* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__label", children: label })
|
|
7494
7918
|
] }),
|
|
7495
7919
|
iconPosition === "right" ? activeIconElement : null,
|
|
7496
|
-
renderBadge ? typeof badge === "string" || typeof badge === "number" ? /* @__PURE__ */
|
|
7920
|
+
renderBadge ? typeof badge === "string" || typeof badge === "number" ? /* @__PURE__ */ jsx59(
|
|
7497
7921
|
StnBadge,
|
|
7498
7922
|
{
|
|
7499
7923
|
badgeContent: badge,
|
|
@@ -7501,7 +7925,7 @@ var StnSideNavItem = forwardRef27(function StnSideNavItem2({
|
|
|
7501
7925
|
appearance: "subtle",
|
|
7502
7926
|
className: "stn-side-nav-item__badge"
|
|
7503
7927
|
}
|
|
7504
|
-
) : badge ? /* @__PURE__ */
|
|
7928
|
+
) : badge ? /* @__PURE__ */ jsx59("span", { className: "stn-side-nav-item__badge", children: badge }) : showBadgeDot ? /* @__PURE__ */ jsx59(
|
|
7505
7929
|
StnBadge,
|
|
7506
7930
|
{
|
|
7507
7931
|
variant: "dot",
|
|
@@ -7509,7 +7933,7 @@ var StnSideNavItem = forwardRef27(function StnSideNavItem2({
|
|
|
7509
7933
|
className: "stn-side-nav-item__badge"
|
|
7510
7934
|
}
|
|
7511
7935
|
) : null : null,
|
|
7512
|
-
!isSub && showChevron && !collapsed ? /* @__PURE__ */
|
|
7936
|
+
!isSub && showChevron && !collapsed ? /* @__PURE__ */ jsx59(
|
|
7513
7937
|
"span",
|
|
7514
7938
|
{
|
|
7515
7939
|
className: cn(
|
|
@@ -7526,15 +7950,15 @@ var StnSideNavItem = forwardRef27(function StnSideNavItem2({
|
|
|
7526
7950
|
});
|
|
7527
7951
|
|
|
7528
7952
|
// src/components/sideNav/StnSideNavHeader.tsx
|
|
7529
|
-
import { forwardRef as
|
|
7953
|
+
import { forwardRef as forwardRef32 } from "react";
|
|
7530
7954
|
|
|
7531
7955
|
// src/components/sideNav/StnSideNavLogo.tsx
|
|
7532
|
-
import { forwardRef as
|
|
7533
|
-
import { jsx as
|
|
7534
|
-
var StnSideNavLogo =
|
|
7956
|
+
import { forwardRef as forwardRef31 } from "react";
|
|
7957
|
+
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
7958
|
+
var StnSideNavLogo = forwardRef31(
|
|
7535
7959
|
function StnSideNavLogo2({ className, logoProps, ...rest }, ref) {
|
|
7536
7960
|
const { collapsed } = useSideNav();
|
|
7537
|
-
return /* @__PURE__ */
|
|
7961
|
+
return /* @__PURE__ */ jsx60(
|
|
7538
7962
|
"div",
|
|
7539
7963
|
{
|
|
7540
7964
|
ref,
|
|
@@ -7545,7 +7969,7 @@ var StnSideNavLogo = forwardRef28(
|
|
|
7545
7969
|
),
|
|
7546
7970
|
title: "InfoMap",
|
|
7547
7971
|
...rest,
|
|
7548
|
-
children: /* @__PURE__ */
|
|
7972
|
+
children: /* @__PURE__ */ jsx60(
|
|
7549
7973
|
StnLogo,
|
|
7550
7974
|
{
|
|
7551
7975
|
variant: collapsed ? "onlyimg" : "horizontal",
|
|
@@ -7559,8 +7983,8 @@ var StnSideNavLogo = forwardRef28(
|
|
|
7559
7983
|
);
|
|
7560
7984
|
|
|
7561
7985
|
// src/components/sideNav/StnSideNavHeader.tsx
|
|
7562
|
-
import { Fragment as Fragment7, jsx as
|
|
7563
|
-
var StnSideNavHeader =
|
|
7986
|
+
import { Fragment as Fragment7, jsx as jsx61, jsxs as jsxs48 } from "react/jsx-runtime";
|
|
7987
|
+
var StnSideNavHeader = forwardRef32(function StnSideNavHeader2({
|
|
7564
7988
|
children,
|
|
7565
7989
|
border = false,
|
|
7566
7990
|
hasBorder = false,
|
|
@@ -7572,7 +7996,7 @@ var StnSideNavHeader = forwardRef29(function StnSideNavHeader2({
|
|
|
7572
7996
|
const { collapsed, onToggleCollapse, isDrawer, setMobileOpen } = useSideNav();
|
|
7573
7997
|
const withBorder = Boolean(border || hasBorder);
|
|
7574
7998
|
const shouldShowClose = showClose ?? Boolean(isDrawer);
|
|
7575
|
-
return /* @__PURE__ */
|
|
7999
|
+
return /* @__PURE__ */ jsx61(
|
|
7576
8000
|
"div",
|
|
7577
8001
|
{
|
|
7578
8002
|
ref,
|
|
@@ -7583,9 +8007,9 @@ var StnSideNavHeader = forwardRef29(function StnSideNavHeader2({
|
|
|
7583
8007
|
className
|
|
7584
8008
|
),
|
|
7585
8009
|
...rest,
|
|
7586
|
-
children: children ?? /* @__PURE__ */
|
|
7587
|
-
/* @__PURE__ */
|
|
7588
|
-
shouldShowClose ? /* @__PURE__ */
|
|
8010
|
+
children: children ?? /* @__PURE__ */ jsxs48(Fragment7, { children: [
|
|
8011
|
+
/* @__PURE__ */ jsx61(StnSideNavLogo, {}),
|
|
8012
|
+
shouldShowClose ? /* @__PURE__ */ jsx61(
|
|
7589
8013
|
StnButton,
|
|
7590
8014
|
{
|
|
7591
8015
|
size: "sm",
|
|
@@ -7597,7 +8021,7 @@ var StnSideNavHeader = forwardRef29(function StnSideNavHeader2({
|
|
|
7597
8021
|
className: "stn-side-nav__collapse-btn",
|
|
7598
8022
|
onClick: () => setMobileOpen?.(false)
|
|
7599
8023
|
}
|
|
7600
|
-
) : showToggle ? /* @__PURE__ */
|
|
8024
|
+
) : showToggle ? /* @__PURE__ */ jsx61(
|
|
7601
8025
|
StnButton,
|
|
7602
8026
|
{
|
|
7603
8027
|
size: "sm",
|
|
@@ -7616,16 +8040,16 @@ var StnSideNavHeader = forwardRef29(function StnSideNavHeader2({
|
|
|
7616
8040
|
});
|
|
7617
8041
|
|
|
7618
8042
|
// src/components/sideNav/StnSideNavMenu.tsx
|
|
7619
|
-
import { forwardRef as
|
|
7620
|
-
import { jsx as
|
|
7621
|
-
var StnSideNavMenu =
|
|
8043
|
+
import { forwardRef as forwardRef33 } from "react";
|
|
8044
|
+
import { jsx as jsx62 } from "react/jsx-runtime";
|
|
8045
|
+
var StnSideNavMenu = forwardRef33(function StnSideNavMenu2({
|
|
7622
8046
|
children,
|
|
7623
8047
|
className,
|
|
7624
8048
|
scrollSize = "thin",
|
|
7625
8049
|
scrollColor = "fade",
|
|
7626
8050
|
...rest
|
|
7627
8051
|
}, ref) {
|
|
7628
|
-
return /* @__PURE__ */
|
|
8052
|
+
return /* @__PURE__ */ jsx62(
|
|
7629
8053
|
"nav",
|
|
7630
8054
|
{
|
|
7631
8055
|
ref,
|
|
@@ -7646,13 +8070,13 @@ var StnSideNavMenu = forwardRef30(function StnSideNavMenu2({
|
|
|
7646
8070
|
|
|
7647
8071
|
// src/components/sideNav/StnSideNavGroup.tsx
|
|
7648
8072
|
import {
|
|
7649
|
-
forwardRef as
|
|
7650
|
-
useEffect as
|
|
7651
|
-
useRef as
|
|
7652
|
-
useState as
|
|
8073
|
+
forwardRef as forwardRef34,
|
|
8074
|
+
useEffect as useEffect11,
|
|
8075
|
+
useRef as useRef8,
|
|
8076
|
+
useState as useState17
|
|
7653
8077
|
} from "react";
|
|
7654
|
-
import { jsx as
|
|
7655
|
-
var StnSideNavGroup =
|
|
8078
|
+
import { jsx as jsx63, jsxs as jsxs49 } from "react/jsx-runtime";
|
|
8079
|
+
var StnSideNavGroup = forwardRef34(function StnSideNavGroup2({
|
|
7656
8080
|
label,
|
|
7657
8081
|
parent,
|
|
7658
8082
|
direction = "down",
|
|
@@ -7668,13 +8092,13 @@ var StnSideNavGroup = forwardRef31(function StnSideNavGroup2({
|
|
|
7668
8092
|
...rest
|
|
7669
8093
|
}, ref) {
|
|
7670
8094
|
const { collapsed } = useSideNav();
|
|
7671
|
-
const [internalOpen, setInternalOpen] =
|
|
8095
|
+
const [internalOpen, setInternalOpen] = useState17(defaultOpen);
|
|
7672
8096
|
const isOpen = openProp ?? internalOpen;
|
|
7673
8097
|
const isDropdown = Boolean(dropdown || variant === "dropdown");
|
|
7674
8098
|
const isTransparent = dropdownVariant === "transparent" || dropdownBackground === false;
|
|
7675
8099
|
const isUp = direction === "up";
|
|
7676
|
-
const groupRef =
|
|
7677
|
-
|
|
8100
|
+
const groupRef = useRef8(null);
|
|
8101
|
+
useEffect11(() => {
|
|
7678
8102
|
if (!isDropdown || !isOpen) return;
|
|
7679
8103
|
const handlePointerDown = (e) => {
|
|
7680
8104
|
if (groupRef.current && !groupRef.current.contains(e.target)) {
|
|
@@ -7696,7 +8120,7 @@ var StnSideNavGroup = forwardRef31(function StnSideNavGroup2({
|
|
|
7696
8120
|
}
|
|
7697
8121
|
onOpenChange?.(next);
|
|
7698
8122
|
};
|
|
7699
|
-
const subnavNode = children && (!collapsed && isOpen) ? /* @__PURE__ */
|
|
8123
|
+
const subnavNode = children && (!collapsed && isOpen) ? /* @__PURE__ */ jsx63(
|
|
7700
8124
|
"div",
|
|
7701
8125
|
{
|
|
7702
8126
|
className: cn(
|
|
@@ -7711,7 +8135,7 @@ var StnSideNavGroup = forwardRef31(function StnSideNavGroup2({
|
|
|
7711
8135
|
children
|
|
7712
8136
|
}
|
|
7713
8137
|
) : null;
|
|
7714
|
-
return /* @__PURE__ */
|
|
8138
|
+
return /* @__PURE__ */ jsxs49(
|
|
7715
8139
|
"div",
|
|
7716
8140
|
{
|
|
7717
8141
|
ref: (node) => {
|
|
@@ -7732,7 +8156,7 @@ var StnSideNavGroup = forwardRef31(function StnSideNavGroup2({
|
|
|
7732
8156
|
"aria-label": typeof label === "string" ? label : void 0,
|
|
7733
8157
|
...rest,
|
|
7734
8158
|
children: [
|
|
7735
|
-
label && !collapsed ? /* @__PURE__ */
|
|
8159
|
+
label && !collapsed ? /* @__PURE__ */ jsx63("span", { className: "stn-side-nav__group-label", onClick: handleToggle, children: label }) : null,
|
|
7736
8160
|
isUp ? subnavNode : null,
|
|
7737
8161
|
parent,
|
|
7738
8162
|
!isUp ? subnavNode : null
|
|
@@ -7742,10 +8166,10 @@ var StnSideNavGroup = forwardRef31(function StnSideNavGroup2({
|
|
|
7742
8166
|
});
|
|
7743
8167
|
|
|
7744
8168
|
// src/components/sideNav/StnSideNavSpacer.tsx
|
|
7745
|
-
import { forwardRef as
|
|
7746
|
-
import { jsx as
|
|
7747
|
-
var StnSideNavSpacer =
|
|
7748
|
-
return /* @__PURE__ */
|
|
8169
|
+
import { forwardRef as forwardRef35 } from "react";
|
|
8170
|
+
import { jsx as jsx64 } from "react/jsx-runtime";
|
|
8171
|
+
var StnSideNavSpacer = forwardRef35(function StnSideNavSpacer2({ className, style, ...rest }, ref) {
|
|
8172
|
+
return /* @__PURE__ */ jsx64(
|
|
7749
8173
|
"div",
|
|
7750
8174
|
{
|
|
7751
8175
|
ref,
|
|
@@ -7758,10 +8182,10 @@ var StnSideNavSpacer = forwardRef32(function StnSideNavSpacer2({ className, styl
|
|
|
7758
8182
|
});
|
|
7759
8183
|
|
|
7760
8184
|
// src/components/sideNav/StnSideNavFooter.tsx
|
|
7761
|
-
import { forwardRef as
|
|
7762
|
-
import { jsx as
|
|
7763
|
-
var StnSideNavFooter =
|
|
7764
|
-
return /* @__PURE__ */
|
|
8185
|
+
import { forwardRef as forwardRef36 } from "react";
|
|
8186
|
+
import { jsx as jsx65 } from "react/jsx-runtime";
|
|
8187
|
+
var StnSideNavFooter = forwardRef36(function StnSideNavFooter2({ curved = false, children, className, ...rest }, ref) {
|
|
8188
|
+
return /* @__PURE__ */ jsx65(
|
|
7765
8189
|
"nav",
|
|
7766
8190
|
{
|
|
7767
8191
|
ref,
|
|
@@ -7774,12 +8198,12 @@ var StnSideNavFooter = forwardRef33(function StnSideNavFooter2({ curved = false,
|
|
|
7774
8198
|
});
|
|
7775
8199
|
|
|
7776
8200
|
// src/components/sideNav/StnSideNavToggle.tsx
|
|
7777
|
-
import { forwardRef as
|
|
7778
|
-
import { jsx as
|
|
7779
|
-
var StnSideNavToggle =
|
|
8201
|
+
import { forwardRef as forwardRef37 } from "react";
|
|
8202
|
+
import { jsx as jsx66 } from "react/jsx-runtime";
|
|
8203
|
+
var StnSideNavToggle = forwardRef37(
|
|
7780
8204
|
function StnSideNavToggle2({ className, onClick, ...rest }, ref) {
|
|
7781
8205
|
const { collapsed, onToggleCollapse } = useSideNav();
|
|
7782
|
-
return /* @__PURE__ */
|
|
8206
|
+
return /* @__PURE__ */ jsx66(
|
|
7783
8207
|
"button",
|
|
7784
8208
|
{
|
|
7785
8209
|
ref,
|
|
@@ -7792,7 +8216,7 @@ var StnSideNavToggle = forwardRef34(
|
|
|
7792
8216
|
"aria-label": collapsed ? "\uC0AC\uC774\uB4DC\uBC14 \uD3BC\uCE58\uAE30" : "\uC0AC\uC774\uB4DC\uBC14 \uC811\uAE30",
|
|
7793
8217
|
title: collapsed ? "\uC0AC\uC774\uB4DC\uBC14 \uD3BC\uCE58\uAE30" : "\uC0AC\uC774\uB4DC\uBC14 \uC811\uAE30",
|
|
7794
8218
|
...rest,
|
|
7795
|
-
children: /* @__PURE__ */
|
|
8219
|
+
children: /* @__PURE__ */ jsx66(
|
|
7796
8220
|
"svg",
|
|
7797
8221
|
{
|
|
7798
8222
|
width: "12",
|
|
@@ -7803,7 +8227,7 @@ var StnSideNavToggle = forwardRef34(
|
|
|
7803
8227
|
strokeWidth: "2.5",
|
|
7804
8228
|
strokeLinecap: "round",
|
|
7805
8229
|
strokeLinejoin: "round",
|
|
7806
|
-
children: /* @__PURE__ */
|
|
8230
|
+
children: /* @__PURE__ */ jsx66("path", { d: "M9 18l6-6-6-6" })
|
|
7807
8231
|
}
|
|
7808
8232
|
)
|
|
7809
8233
|
}
|
|
@@ -7812,30 +8236,30 @@ var StnSideNavToggle = forwardRef34(
|
|
|
7812
8236
|
);
|
|
7813
8237
|
|
|
7814
8238
|
// src/components/sideNav/StnSideNavWatermark.tsx
|
|
7815
|
-
import { forwardRef as
|
|
7816
|
-
import { jsx as
|
|
7817
|
-
var StnSideNavWatermark =
|
|
8239
|
+
import { forwardRef as forwardRef38 } from "react";
|
|
8240
|
+
import { jsx as jsx67 } from "react/jsx-runtime";
|
|
8241
|
+
var StnSideNavWatermark = forwardRef38(
|
|
7818
8242
|
function StnSideNavWatermark2({ size = "xl", theme, className, ...rest }, ref) {
|
|
7819
|
-
return /* @__PURE__ */
|
|
8243
|
+
return /* @__PURE__ */ jsx67(
|
|
7820
8244
|
"div",
|
|
7821
8245
|
{
|
|
7822
8246
|
ref,
|
|
7823
8247
|
className: cn("stn-side-nav__watermark", className),
|
|
7824
8248
|
"aria-hidden": "true",
|
|
7825
8249
|
...rest,
|
|
7826
|
-
children: /* @__PURE__ */
|
|
8250
|
+
children: /* @__PURE__ */ jsx67(StnLogo, { variant: "watermark", size, theme })
|
|
7827
8251
|
}
|
|
7828
8252
|
);
|
|
7829
8253
|
}
|
|
7830
8254
|
);
|
|
7831
8255
|
|
|
7832
8256
|
// src/components/sideNav/StnSideNavMobileTrigger.tsx
|
|
7833
|
-
import { forwardRef as
|
|
7834
|
-
import { jsx as
|
|
7835
|
-
var StnSideNavMobileTrigger =
|
|
8257
|
+
import { forwardRef as forwardRef39 } from "react";
|
|
8258
|
+
import { jsx as jsx68, jsxs as jsxs50 } from "react/jsx-runtime";
|
|
8259
|
+
var StnSideNavMobileTrigger = forwardRef39(
|
|
7836
8260
|
function StnSideNavMobileTrigger2({ floating = false, className, children, onClick, ...rest }, ref) {
|
|
7837
8261
|
const { onToggleMobileOpen, mobileOpen } = useSideNav();
|
|
7838
|
-
return /* @__PURE__ */
|
|
8262
|
+
return /* @__PURE__ */ jsx68(
|
|
7839
8263
|
"button",
|
|
7840
8264
|
{
|
|
7841
8265
|
ref,
|
|
@@ -7853,10 +8277,10 @@ var StnSideNavMobileTrigger = forwardRef36(
|
|
|
7853
8277
|
onToggleMobileOpen?.();
|
|
7854
8278
|
},
|
|
7855
8279
|
...rest,
|
|
7856
|
-
children: children ?? /* @__PURE__ */
|
|
7857
|
-
/* @__PURE__ */
|
|
7858
|
-
/* @__PURE__ */
|
|
7859
|
-
/* @__PURE__ */
|
|
8280
|
+
children: children ?? /* @__PURE__ */ jsxs50("span", { className: "stn-side-nav__hamburger-bars", "aria-hidden": "true", children: [
|
|
8281
|
+
/* @__PURE__ */ jsx68("span", {}),
|
|
8282
|
+
/* @__PURE__ */ jsx68("span", {}),
|
|
8283
|
+
/* @__PURE__ */ jsx68("span", {})
|
|
7860
8284
|
] })
|
|
7861
8285
|
}
|
|
7862
8286
|
);
|
|
@@ -7865,12 +8289,12 @@ var StnSideNavMobileTrigger = forwardRef36(
|
|
|
7865
8289
|
|
|
7866
8290
|
// src/components/sideNav/StnSideNavSub.tsx
|
|
7867
8291
|
import {
|
|
7868
|
-
forwardRef as
|
|
8292
|
+
forwardRef as forwardRef40
|
|
7869
8293
|
} from "react";
|
|
7870
|
-
import { jsx as
|
|
7871
|
-
var StnSideNavSub =
|
|
8294
|
+
import { jsx as jsx69 } from "react/jsx-runtime";
|
|
8295
|
+
var StnSideNavSub = forwardRef40(
|
|
7872
8296
|
function StnSideNavSub2({ children, className, ...rest }, ref) {
|
|
7873
|
-
return /* @__PURE__ */
|
|
8297
|
+
return /* @__PURE__ */ jsx69(
|
|
7874
8298
|
"div",
|
|
7875
8299
|
{
|
|
7876
8300
|
ref,
|
|
@@ -7883,7 +8307,7 @@ var StnSideNavSub = forwardRef37(
|
|
|
7883
8307
|
);
|
|
7884
8308
|
}
|
|
7885
8309
|
);
|
|
7886
|
-
var StnSideNavSubItem =
|
|
8310
|
+
var StnSideNavSubItem = forwardRef40(
|
|
7887
8311
|
function StnSideNavSubItem2({
|
|
7888
8312
|
variant = "ghost",
|
|
7889
8313
|
size = "md",
|
|
@@ -7899,14 +8323,14 @@ var StnSideNavSubItem = forwardRef37(
|
|
|
7899
8323
|
const { collapsed } = useSideNav();
|
|
7900
8324
|
const content = children ?? label;
|
|
7901
8325
|
const computedTitle = title ?? (typeof content === "string" ? content : void 0);
|
|
7902
|
-
const resolvedIcon = icon ?? (iconSrc ? /* @__PURE__ */
|
|
8326
|
+
const resolvedIcon = icon ?? (iconSrc ? /* @__PURE__ */ jsx69("span", { className: "stn-side-nav__sub-icon", children: /* @__PURE__ */ jsx69(
|
|
7903
8327
|
"span",
|
|
7904
8328
|
{
|
|
7905
8329
|
className: "stn-side-nav__sub-glyph",
|
|
7906
8330
|
style: { maskImage: `url('${iconSrc}')`, WebkitMaskImage: `url('${iconSrc}')` }
|
|
7907
8331
|
}
|
|
7908
8332
|
) }) : null);
|
|
7909
|
-
return /* @__PURE__ */
|
|
8333
|
+
return /* @__PURE__ */ jsx69(
|
|
7910
8334
|
StnButton,
|
|
7911
8335
|
{
|
|
7912
8336
|
ref,
|
|
@@ -7925,9 +8349,9 @@ var StnSideNavSubItem = forwardRef37(
|
|
|
7925
8349
|
);
|
|
7926
8350
|
|
|
7927
8351
|
// src/components/sideNav/StnSideNavSubNav.tsx
|
|
7928
|
-
import { forwardRef as
|
|
7929
|
-
import { jsx as
|
|
7930
|
-
var StnSideNavSubNav =
|
|
8352
|
+
import { forwardRef as forwardRef41 } from "react";
|
|
8353
|
+
import { jsx as jsx70 } from "react/jsx-runtime";
|
|
8354
|
+
var StnSideNavSubNav = forwardRef41(
|
|
7931
8355
|
function StnSideNavSubNav2({
|
|
7932
8356
|
dropdown = false,
|
|
7933
8357
|
direction = "down",
|
|
@@ -7939,7 +8363,7 @@ var StnSideNavSubNav = forwardRef38(
|
|
|
7939
8363
|
}, ref) {
|
|
7940
8364
|
const isUp = direction === "up";
|
|
7941
8365
|
const isTransparent = variant === "transparent" || background === false;
|
|
7942
|
-
return /* @__PURE__ */
|
|
8366
|
+
return /* @__PURE__ */ jsx70(
|
|
7943
8367
|
"div",
|
|
7944
8368
|
{
|
|
7945
8369
|
ref,
|
|
@@ -7962,17 +8386,17 @@ var StnSideNavSubNav = forwardRef38(
|
|
|
7962
8386
|
|
|
7963
8387
|
// src/patterns/sideNav/StnSideNavigation.tsx
|
|
7964
8388
|
import {
|
|
7965
|
-
forwardRef as
|
|
7966
|
-
useCallback as
|
|
8389
|
+
forwardRef as forwardRef42,
|
|
8390
|
+
useCallback as useCallback9,
|
|
7967
8391
|
useMemo as useMemo4,
|
|
7968
|
-
useState as
|
|
8392
|
+
useState as useState18
|
|
7969
8393
|
} from "react";
|
|
7970
|
-
import { jsx as
|
|
8394
|
+
import { jsx as jsx71, jsxs as jsxs51 } from "react/jsx-runtime";
|
|
7971
8395
|
function useControllableState(controlledValue, defaultValue, onChange) {
|
|
7972
|
-
const [internalState, setInternalState] =
|
|
8396
|
+
const [internalState, setInternalState] = useState18(defaultValue);
|
|
7973
8397
|
const isControlled = controlledValue !== void 0;
|
|
7974
8398
|
const value = isControlled ? controlledValue : internalState;
|
|
7975
|
-
const setValue =
|
|
8399
|
+
const setValue = useCallback9(
|
|
7976
8400
|
(next) => {
|
|
7977
8401
|
if (!isControlled) {
|
|
7978
8402
|
setInternalState(next);
|
|
@@ -7983,7 +8407,7 @@ function useControllableState(controlledValue, defaultValue, onChange) {
|
|
|
7983
8407
|
);
|
|
7984
8408
|
return [value, setValue];
|
|
7985
8409
|
}
|
|
7986
|
-
var StnSideNavigationRoot =
|
|
8410
|
+
var StnSideNavigationRoot = forwardRef42(function StnSideNavigationRoot2({
|
|
7987
8411
|
variant: variantProp,
|
|
7988
8412
|
appearance,
|
|
7989
8413
|
drawerVariant: drawerVariantProp,
|
|
@@ -8021,10 +8445,10 @@ var StnSideNavigationRoot = forwardRef39(function StnSideNavigationRoot2({
|
|
|
8021
8445
|
defaultMobileOpen,
|
|
8022
8446
|
onMobileOpenChange
|
|
8023
8447
|
);
|
|
8024
|
-
const handleToggleCollapse =
|
|
8448
|
+
const handleToggleCollapse = useCallback9(() => {
|
|
8025
8449
|
setCollapsed(!collapsed);
|
|
8026
8450
|
}, [collapsed, setCollapsed]);
|
|
8027
|
-
const handleToggleMobileOpen =
|
|
8451
|
+
const handleToggleMobileOpen = useCallback9(() => {
|
|
8028
8452
|
setMobileOpen(!mobileOpen);
|
|
8029
8453
|
}, [mobileOpen, setMobileOpen]);
|
|
8030
8454
|
const isDrawerMode = Boolean(drawer || responsiveDrawer && mobileOpen);
|
|
@@ -8044,9 +8468,9 @@ var StnSideNavigationRoot = forwardRef39(function StnSideNavigationRoot2({
|
|
|
8044
8468
|
}),
|
|
8045
8469
|
[isEffectiveCollapsed, activeId, setActiveId, handleToggleCollapse, mobileOpen, handleToggleMobileOpen, setMobileOpen, isDrawerMode]
|
|
8046
8470
|
);
|
|
8047
|
-
return /* @__PURE__ */
|
|
8048
|
-
showMobileTrigger && /* @__PURE__ */
|
|
8049
|
-
(drawer || responsiveDrawer) && /* @__PURE__ */
|
|
8471
|
+
return /* @__PURE__ */ jsxs51(SideNavContext.Provider, { value: contextValue, children: [
|
|
8472
|
+
showMobileTrigger && /* @__PURE__ */ jsx71(StnSideNavMobileTrigger, { floating: true }),
|
|
8473
|
+
(drawer || responsiveDrawer) && /* @__PURE__ */ jsx71(
|
|
8050
8474
|
"div",
|
|
8051
8475
|
{
|
|
8052
8476
|
className: cn("stn-side-nav__backdrop", mobileOpen && "is-open"),
|
|
@@ -8054,7 +8478,7 @@ var StnSideNavigationRoot = forwardRef39(function StnSideNavigationRoot2({
|
|
|
8054
8478
|
"aria-hidden": !mobileOpen
|
|
8055
8479
|
}
|
|
8056
8480
|
),
|
|
8057
|
-
/* @__PURE__ */
|
|
8481
|
+
/* @__PURE__ */ jsx71(
|
|
8058
8482
|
"aside",
|
|
8059
8483
|
{
|
|
8060
8484
|
ref,
|
|
@@ -8095,15 +8519,15 @@ var StnSideNavigation = Object.assign(StnSideNavigationRoot, {
|
|
|
8095
8519
|
// src/components/StnBreadcrumb.tsx
|
|
8096
8520
|
import {
|
|
8097
8521
|
Fragment as Fragment8,
|
|
8098
|
-
useEffect as
|
|
8522
|
+
useEffect as useEffect12,
|
|
8099
8523
|
useId as useId16,
|
|
8100
|
-
useRef as
|
|
8101
|
-
useState as
|
|
8524
|
+
useRef as useRef9,
|
|
8525
|
+
useState as useState19
|
|
8102
8526
|
} from "react";
|
|
8103
8527
|
import {
|
|
8104
8528
|
STN_BREADCRUMB_ICON_SRC
|
|
8105
8529
|
} from "@stn-uiux/pub-ui/data/stnBreadcrumb";
|
|
8106
|
-
import { Fragment as Fragment9, jsx as
|
|
8530
|
+
import { Fragment as Fragment9, jsx as jsx72, jsxs as jsxs52 } from "react/jsx-runtime";
|
|
8107
8531
|
function maskStyle3(src) {
|
|
8108
8532
|
return { maskImage: `url('${src}')`, WebkitMaskImage: `url('${src}')` };
|
|
8109
8533
|
}
|
|
@@ -8116,13 +8540,13 @@ function hasSegmentMenu(item) {
|
|
|
8116
8540
|
return Boolean(item.menu || item.menuItems && item.menuItems.length > 0);
|
|
8117
8541
|
}
|
|
8118
8542
|
function BreadcrumbSeparator() {
|
|
8119
|
-
return /* @__PURE__ */
|
|
8543
|
+
return /* @__PURE__ */ jsx72("li", { className: "separator", "aria-hidden": "true", children: /* @__PURE__ */ jsx72("span", { style: maskStyle3(STN_BREADCRUMB_ICON_SRC.separator) }) });
|
|
8120
8544
|
}
|
|
8121
8545
|
function BreadcrumbIcon({ src }) {
|
|
8122
|
-
return /* @__PURE__ */
|
|
8546
|
+
return /* @__PURE__ */ jsx72("span", { className: "stn-breadcrumb__icon-glyph", style: maskStyle3(src), "aria-hidden": "true" });
|
|
8123
8547
|
}
|
|
8124
8548
|
function BreadcrumbCaret() {
|
|
8125
|
-
return /* @__PURE__ */
|
|
8549
|
+
return /* @__PURE__ */ jsx72(
|
|
8126
8550
|
"span",
|
|
8127
8551
|
{
|
|
8128
8552
|
className: "stn-breadcrumb__caret",
|
|
@@ -8136,10 +8560,10 @@ function SegmentContent({
|
|
|
8136
8560
|
label,
|
|
8137
8561
|
menu
|
|
8138
8562
|
}) {
|
|
8139
|
-
return /* @__PURE__ */
|
|
8140
|
-
iconSrc ? /* @__PURE__ */
|
|
8141
|
-
/* @__PURE__ */
|
|
8142
|
-
menu ? /* @__PURE__ */
|
|
8563
|
+
return /* @__PURE__ */ jsxs52(Fragment9, { children: [
|
|
8564
|
+
iconSrc ? /* @__PURE__ */ jsx72(BreadcrumbIcon, { src: iconSrc }) : null,
|
|
8565
|
+
/* @__PURE__ */ jsx72("span", { className: "stn-breadcrumb__label", children: label }),
|
|
8566
|
+
menu ? /* @__PURE__ */ jsx72(BreadcrumbCaret, {}) : null
|
|
8143
8567
|
] });
|
|
8144
8568
|
}
|
|
8145
8569
|
function BreadcrumbMenuList({
|
|
@@ -8147,7 +8571,7 @@ function BreadcrumbMenuList({
|
|
|
8147
8571
|
items,
|
|
8148
8572
|
onPick
|
|
8149
8573
|
}) {
|
|
8150
|
-
return /* @__PURE__ */
|
|
8574
|
+
return /* @__PURE__ */ jsx72("ul", { id, className: "stn-breadcrumb__menu", role: "menu", children: items.map((option) => /* @__PURE__ */ jsx72("li", { role: "none", children: option.href ? /* @__PURE__ */ jsx72(
|
|
8151
8575
|
"a",
|
|
8152
8576
|
{
|
|
8153
8577
|
role: "menuitem",
|
|
@@ -8159,7 +8583,7 @@ function BreadcrumbMenuList({
|
|
|
8159
8583
|
},
|
|
8160
8584
|
children: option.label
|
|
8161
8585
|
}
|
|
8162
|
-
) : /* @__PURE__ */
|
|
8586
|
+
) : /* @__PURE__ */ jsx72(
|
|
8163
8587
|
"button",
|
|
8164
8588
|
{
|
|
8165
8589
|
type: "button",
|
|
@@ -8174,8 +8598,8 @@ function BreadcrumbMenuList({
|
|
|
8174
8598
|
) }, option.id)) });
|
|
8175
8599
|
}
|
|
8176
8600
|
function useDismissibleMenu(open, onClose) {
|
|
8177
|
-
const rootRef =
|
|
8178
|
-
|
|
8601
|
+
const rootRef = useRef9(null);
|
|
8602
|
+
useEffect12(() => {
|
|
8179
8603
|
if (!open) return;
|
|
8180
8604
|
const onPointerDown = (event) => {
|
|
8181
8605
|
if (!rootRef.current?.contains(event.target)) onClose();
|
|
@@ -8197,19 +8621,19 @@ function BreadcrumbSegment({
|
|
|
8197
8621
|
isCurrent
|
|
8198
8622
|
}) {
|
|
8199
8623
|
const menuId = useId16();
|
|
8200
|
-
const [open, setOpen] =
|
|
8624
|
+
const [open, setOpen] = useState19(false);
|
|
8201
8625
|
const menuItems = item.menuItems ?? [];
|
|
8202
8626
|
const showMenu = hasSegmentMenu(item) && !isCurrent;
|
|
8203
8627
|
const canOpenMenu = showMenu && menuItems.length > 0;
|
|
8204
8628
|
const rootRef = useDismissibleMenu(open, () => setOpen(false));
|
|
8205
8629
|
const iconSrc = resolveIconSrc(item);
|
|
8206
|
-
const content = /* @__PURE__ */
|
|
8630
|
+
const content = /* @__PURE__ */ jsx72(SegmentContent, { iconSrc, label: item.label, menu: showMenu });
|
|
8207
8631
|
if (isCurrent) {
|
|
8208
|
-
return /* @__PURE__ */
|
|
8632
|
+
return /* @__PURE__ */ jsx72("span", { className: "stn-breadcrumb__segment", "aria-current": "page", "aria-label": item.label, children: content });
|
|
8209
8633
|
}
|
|
8210
8634
|
if (canOpenMenu) {
|
|
8211
|
-
return /* @__PURE__ */
|
|
8212
|
-
/* @__PURE__ */
|
|
8635
|
+
return /* @__PURE__ */ jsxs52("span", { ref: rootRef, className: "stn-breadcrumb__segment-wrap", children: [
|
|
8636
|
+
/* @__PURE__ */ jsx72(
|
|
8213
8637
|
"button",
|
|
8214
8638
|
{
|
|
8215
8639
|
type: "button",
|
|
@@ -8225,7 +8649,7 @@ function BreadcrumbSegment({
|
|
|
8225
8649
|
children: content
|
|
8226
8650
|
}
|
|
8227
8651
|
),
|
|
8228
|
-
open ? /* @__PURE__ */
|
|
8652
|
+
open ? /* @__PURE__ */ jsx72(BreadcrumbMenuList, { id: menuId, items: menuItems, onPick: () => setOpen(false) }) : null
|
|
8229
8653
|
] });
|
|
8230
8654
|
}
|
|
8231
8655
|
if (item.menu || item.onClick) {
|
|
@@ -8237,7 +8661,7 @@ function BreadcrumbSegment({
|
|
|
8237
8661
|
"aria-haspopup": item.menu ? "menu" : void 0,
|
|
8238
8662
|
"aria-expanded": item.menu ? false : void 0
|
|
8239
8663
|
};
|
|
8240
|
-
return /* @__PURE__ */
|
|
8664
|
+
return /* @__PURE__ */ jsx72("button", { ...buttonProps, children: content });
|
|
8241
8665
|
}
|
|
8242
8666
|
if (item.href) {
|
|
8243
8667
|
const linkProps = {
|
|
@@ -8246,17 +8670,17 @@ function BreadcrumbSegment({
|
|
|
8246
8670
|
onClick: item.onClick,
|
|
8247
8671
|
"aria-label": item.label
|
|
8248
8672
|
};
|
|
8249
|
-
return /* @__PURE__ */
|
|
8673
|
+
return /* @__PURE__ */ jsx72("a", { ...linkProps, children: content });
|
|
8250
8674
|
}
|
|
8251
|
-
return /* @__PURE__ */
|
|
8675
|
+
return /* @__PURE__ */ jsx72("span", { className: "stn-breadcrumb__segment", "aria-label": item.label, children: content });
|
|
8252
8676
|
}
|
|
8253
8677
|
function BreadcrumbBack({
|
|
8254
8678
|
label,
|
|
8255
8679
|
href,
|
|
8256
8680
|
onClick
|
|
8257
8681
|
}) {
|
|
8258
|
-
const content = /* @__PURE__ */
|
|
8259
|
-
/* @__PURE__ */
|
|
8682
|
+
const content = /* @__PURE__ */ jsxs52(Fragment9, { children: [
|
|
8683
|
+
/* @__PURE__ */ jsx72(
|
|
8260
8684
|
"span",
|
|
8261
8685
|
{
|
|
8262
8686
|
className: "stn-breadcrumb__back-glyph",
|
|
@@ -8264,12 +8688,12 @@ function BreadcrumbBack({
|
|
|
8264
8688
|
"aria-hidden": "true"
|
|
8265
8689
|
}
|
|
8266
8690
|
),
|
|
8267
|
-
/* @__PURE__ */
|
|
8691
|
+
/* @__PURE__ */ jsx72("span", { className: "stn-breadcrumb__label", children: label })
|
|
8268
8692
|
] });
|
|
8269
8693
|
if (href) {
|
|
8270
|
-
return /* @__PURE__ */
|
|
8694
|
+
return /* @__PURE__ */ jsx72("a", { className: "stn-breadcrumb__back", href, onClick, "aria-label": `\uB4A4\uB85C: ${label}`, children: content });
|
|
8271
8695
|
}
|
|
8272
|
-
return /* @__PURE__ */
|
|
8696
|
+
return /* @__PURE__ */ jsx72("button", { type: "button", className: "stn-breadcrumb__back", onClick, "aria-label": `\uB4A4\uB85C: ${label}`, children: content });
|
|
8273
8697
|
}
|
|
8274
8698
|
function splitCollapsedItems(items, maxItems, itemsBeforeCollapse, itemsAfterCollapse) {
|
|
8275
8699
|
if (!maxItems || items.length <= maxItems) {
|
|
@@ -8291,7 +8715,7 @@ function BreadcrumbCollapsed({
|
|
|
8291
8715
|
items,
|
|
8292
8716
|
menuId
|
|
8293
8717
|
}) {
|
|
8294
|
-
const [open, setOpen] =
|
|
8718
|
+
const [open, setOpen] = useState19(false);
|
|
8295
8719
|
const rootRef = useDismissibleMenu(open, () => setOpen(false));
|
|
8296
8720
|
const menuItems = items.map((item) => ({
|
|
8297
8721
|
id: item.id,
|
|
@@ -8300,8 +8724,8 @@ function BreadcrumbCollapsed({
|
|
|
8300
8724
|
onClick: item.onClick,
|
|
8301
8725
|
current: item.current
|
|
8302
8726
|
}));
|
|
8303
|
-
return /* @__PURE__ */
|
|
8304
|
-
/* @__PURE__ */
|
|
8727
|
+
return /* @__PURE__ */ jsxs52("li", { className: "stn-breadcrumb__item", ref: rootRef, children: [
|
|
8728
|
+
/* @__PURE__ */ jsx72(
|
|
8305
8729
|
"button",
|
|
8306
8730
|
{
|
|
8307
8731
|
type: "button",
|
|
@@ -8314,7 +8738,7 @@ function BreadcrumbCollapsed({
|
|
|
8314
8738
|
children: "\u22EF"
|
|
8315
8739
|
}
|
|
8316
8740
|
),
|
|
8317
|
-
open ? /* @__PURE__ */
|
|
8741
|
+
open ? /* @__PURE__ */ jsx72(BreadcrumbMenuList, { id: menuId, items: menuItems, onPick: () => setOpen(false) }) : null
|
|
8318
8742
|
] });
|
|
8319
8743
|
}
|
|
8320
8744
|
function StnBreadcrumb({
|
|
@@ -8346,8 +8770,8 @@ function StnBreadcrumb({
|
|
|
8346
8770
|
const lastId = items[items.length - 1]?.id;
|
|
8347
8771
|
const renderTrailItem = (item) => {
|
|
8348
8772
|
const isCurrent = Boolean(item.current) || item.id === lastId;
|
|
8349
|
-
const segment = /* @__PURE__ */
|
|
8350
|
-
return /* @__PURE__ */
|
|
8773
|
+
const segment = /* @__PURE__ */ jsx72(BreadcrumbSegment, { item, isCurrent });
|
|
8774
|
+
return /* @__PURE__ */ jsx72(
|
|
8351
8775
|
"li",
|
|
8352
8776
|
{
|
|
8353
8777
|
className: cn(
|
|
@@ -8358,27 +8782,27 @@ function StnBreadcrumb({
|
|
|
8358
8782
|
}
|
|
8359
8783
|
);
|
|
8360
8784
|
};
|
|
8361
|
-
return /* @__PURE__ */
|
|
8785
|
+
return /* @__PURE__ */ jsx72(
|
|
8362
8786
|
"nav",
|
|
8363
8787
|
{
|
|
8364
8788
|
className: cn("stn-breadcrumb", size, variant === "chip" && "chip", className),
|
|
8365
8789
|
"aria-label": "Breadcrumb",
|
|
8366
|
-
children: /* @__PURE__ */
|
|
8367
|
-
currentItem ? /* @__PURE__ */
|
|
8368
|
-
showHome ? /* @__PURE__ */
|
|
8369
|
-
/* @__PURE__ */
|
|
8370
|
-
/* @__PURE__ */
|
|
8790
|
+
children: /* @__PURE__ */ jsxs52("ol", { className: "stn-breadcrumb__list", children: [
|
|
8791
|
+
currentItem ? /* @__PURE__ */ jsx72("li", { className: "stn-breadcrumb__item stn-breadcrumb__item--back", children: /* @__PURE__ */ jsx72(BreadcrumbBack, { label: currentItem.label, href: backHref, onClick: backOnClick }) }) : null,
|
|
8792
|
+
showHome ? /* @__PURE__ */ jsx72("li", { className: "stn-breadcrumb__item stn-breadcrumb__item--home", children: /* @__PURE__ */ jsxs52("a", { className: "stn-breadcrumb__home", href: homeHref, onClick: onHomeClick, children: [
|
|
8793
|
+
/* @__PURE__ */ jsx72(BreadcrumbIcon, { src: STN_BREADCRUMB_ICON_SRC.home }),
|
|
8794
|
+
/* @__PURE__ */ jsx72("span", { className: "blind", children: homeLabel })
|
|
8371
8795
|
] }) }) : null,
|
|
8372
|
-
head.map((item, index) => /* @__PURE__ */
|
|
8373
|
-
showHome || index > 0 ? /* @__PURE__ */
|
|
8796
|
+
head.map((item, index) => /* @__PURE__ */ jsxs52(Fragment8, { children: [
|
|
8797
|
+
showHome || index > 0 ? /* @__PURE__ */ jsx72(BreadcrumbSeparator, {}) : null,
|
|
8374
8798
|
renderTrailItem(item)
|
|
8375
8799
|
] }, item.id)),
|
|
8376
|
-
hidden.length > 0 ? /* @__PURE__ */
|
|
8377
|
-
/* @__PURE__ */
|
|
8378
|
-
/* @__PURE__ */
|
|
8800
|
+
hidden.length > 0 ? /* @__PURE__ */ jsxs52(Fragment9, { children: [
|
|
8801
|
+
/* @__PURE__ */ jsx72(BreadcrumbSeparator, {}),
|
|
8802
|
+
/* @__PURE__ */ jsx72(BreadcrumbCollapsed, { items: hidden, menuId })
|
|
8379
8803
|
] }) : null,
|
|
8380
|
-
tail.map((item) => /* @__PURE__ */
|
|
8381
|
-
/* @__PURE__ */
|
|
8804
|
+
tail.map((item) => /* @__PURE__ */ jsxs52(Fragment8, { children: [
|
|
8805
|
+
/* @__PURE__ */ jsx72(BreadcrumbSeparator, {}),
|
|
8382
8806
|
renderTrailItem(item)
|
|
8383
8807
|
] }, item.id))
|
|
8384
8808
|
] })
|
|
@@ -8387,9 +8811,9 @@ function StnBreadcrumb({
|
|
|
8387
8811
|
}
|
|
8388
8812
|
|
|
8389
8813
|
// src/components/StnHeaderTitle.tsx
|
|
8390
|
-
import { useEffect as
|
|
8814
|
+
import { useEffect as useEffect13, useState as useState20 } from "react";
|
|
8391
8815
|
import { STN_HEADER_TITLE_FRAME } from "@stn-uiux/pub-ui/data/stnHeaderTitle";
|
|
8392
|
-
import { jsx as
|
|
8816
|
+
import { jsx as jsx73, jsxs as jsxs53 } from "react/jsx-runtime";
|
|
8393
8817
|
var KO_WEEKDAY_SHORT = ["\uC77C", "\uC6D4", "\uD654", "\uC218", "\uBAA9", "\uAE08", "\uD1A0"];
|
|
8394
8818
|
var KO_WEEKDAY_LONG = [
|
|
8395
8819
|
"\uC77C\uC694\uC77C",
|
|
@@ -8428,8 +8852,8 @@ function formatStnHeaderTitleTime(date, options) {
|
|
|
8428
8852
|
}
|
|
8429
8853
|
function HeaderTitleFrame({ preview = false }) {
|
|
8430
8854
|
const frameClass = preview ? "stn-header-title__frame-preview" : "stn-header-title__frame";
|
|
8431
|
-
return /* @__PURE__ */
|
|
8432
|
-
/* @__PURE__ */
|
|
8855
|
+
return /* @__PURE__ */ jsxs53("div", { className: frameClass, "aria-hidden": "true", children: [
|
|
8856
|
+
/* @__PURE__ */ jsx73("div", { className: "stn-header-title__frame-bleed stn-header-title__frame-bleed--outer", children: /* @__PURE__ */ jsx73(
|
|
8433
8857
|
"img",
|
|
8434
8858
|
{
|
|
8435
8859
|
className: "stn-header-title__frame-img",
|
|
@@ -8438,8 +8862,8 @@ function HeaderTitleFrame({ preview = false }) {
|
|
|
8438
8862
|
draggable: false
|
|
8439
8863
|
}
|
|
8440
8864
|
) }),
|
|
8441
|
-
/* @__PURE__ */
|
|
8442
|
-
/* @__PURE__ */
|
|
8865
|
+
/* @__PURE__ */ jsxs53("div", { className: "stn-header-title__frame-bleed stn-header-title__frame-bleed--inner", children: [
|
|
8866
|
+
/* @__PURE__ */ jsx73(
|
|
8443
8867
|
"img",
|
|
8444
8868
|
{
|
|
8445
8869
|
className: "stn-header-title__frame-img stn-header-title__frame-img--dark",
|
|
@@ -8448,7 +8872,7 @@ function HeaderTitleFrame({ preview = false }) {
|
|
|
8448
8872
|
draggable: false
|
|
8449
8873
|
}
|
|
8450
8874
|
),
|
|
8451
|
-
/* @__PURE__ */
|
|
8875
|
+
/* @__PURE__ */ jsx73(
|
|
8452
8876
|
"img",
|
|
8453
8877
|
{
|
|
8454
8878
|
className: "stn-header-title__frame-img stn-header-title__frame-img--light",
|
|
@@ -8461,11 +8885,11 @@ function HeaderTitleFrame({ preview = false }) {
|
|
|
8461
8885
|
] });
|
|
8462
8886
|
}
|
|
8463
8887
|
function StnHeaderTitleFramePreview({ className }) {
|
|
8464
|
-
return /* @__PURE__ */
|
|
8888
|
+
return /* @__PURE__ */ jsx73("div", { className: cn("stn-header-title__frame-only", className), children: /* @__PURE__ */ jsx73(HeaderTitleFrame, { preview: true }) });
|
|
8465
8889
|
}
|
|
8466
8890
|
function useLiveClock(enabled) {
|
|
8467
|
-
const [now, setNow] =
|
|
8468
|
-
|
|
8891
|
+
const [now, setNow] = useState20(() => /* @__PURE__ */ new Date());
|
|
8892
|
+
useEffect13(() => {
|
|
8469
8893
|
if (!enabled) return;
|
|
8470
8894
|
const id = window.setInterval(() => setNow(/* @__PURE__ */ new Date()), 1e3);
|
|
8471
8895
|
return () => window.clearInterval(id);
|
|
@@ -8477,35 +8901,35 @@ function StnHeaderTitleMainText({
|
|
|
8477
8901
|
children,
|
|
8478
8902
|
...rest
|
|
8479
8903
|
}) {
|
|
8480
|
-
return /* @__PURE__ */
|
|
8904
|
+
return /* @__PURE__ */ jsx73("h1", { className: cn("stn-header-title__text", className), ...rest, children });
|
|
8481
8905
|
}
|
|
8482
8906
|
function StnHeaderTitleSubText({
|
|
8483
8907
|
className,
|
|
8484
8908
|
children,
|
|
8485
8909
|
...rest
|
|
8486
8910
|
}) {
|
|
8487
|
-
return /* @__PURE__ */
|
|
8911
|
+
return /* @__PURE__ */ jsx73("span", { className: cn("stn-header-title__sub-text", className), ...rest, children });
|
|
8488
8912
|
}
|
|
8489
8913
|
function StnHeaderTitleDate({
|
|
8490
8914
|
className,
|
|
8491
8915
|
children,
|
|
8492
8916
|
...rest
|
|
8493
8917
|
}) {
|
|
8494
|
-
return /* @__PURE__ */
|
|
8918
|
+
return /* @__PURE__ */ jsx73("time", { className: cn("stn-header-title__date", className), ...rest, children });
|
|
8495
8919
|
}
|
|
8496
8920
|
function StnHeaderTitleWeekday({
|
|
8497
8921
|
className,
|
|
8498
8922
|
children,
|
|
8499
8923
|
...rest
|
|
8500
8924
|
}) {
|
|
8501
|
-
return /* @__PURE__ */
|
|
8925
|
+
return /* @__PURE__ */ jsx73("span", { className: cn("stn-header-title__weekday", className), ...rest, children });
|
|
8502
8926
|
}
|
|
8503
8927
|
function StnHeaderTitleTime({
|
|
8504
8928
|
className,
|
|
8505
8929
|
children,
|
|
8506
8930
|
...rest
|
|
8507
8931
|
}) {
|
|
8508
|
-
return /* @__PURE__ */
|
|
8932
|
+
return /* @__PURE__ */ jsx73("span", { className: cn("stn-header-title__time", className), "aria-label": "\uD604\uC7AC \uC2DC\uAC01", ...rest, children });
|
|
8509
8933
|
}
|
|
8510
8934
|
function StnHeaderTitleClock({
|
|
8511
8935
|
className,
|
|
@@ -8528,7 +8952,7 @@ function StnHeaderTitleClock({
|
|
|
8528
8952
|
}) {
|
|
8529
8953
|
const now = useLiveClock(live);
|
|
8530
8954
|
if (children != null) {
|
|
8531
|
-
return /* @__PURE__ */
|
|
8955
|
+
return /* @__PURE__ */ jsxs53(
|
|
8532
8956
|
"header",
|
|
8533
8957
|
{
|
|
8534
8958
|
className: cn(
|
|
@@ -8540,8 +8964,8 @@ function StnHeaderTitleClock({
|
|
|
8540
8964
|
),
|
|
8541
8965
|
...rest,
|
|
8542
8966
|
children: [
|
|
8543
|
-
framed ? /* @__PURE__ */
|
|
8544
|
-
/* @__PURE__ */
|
|
8967
|
+
framed ? /* @__PURE__ */ jsx73(HeaderTitleFrame, {}) : null,
|
|
8968
|
+
/* @__PURE__ */ jsx73("div", { className: "stn-header-title__content", children })
|
|
8545
8969
|
]
|
|
8546
8970
|
}
|
|
8547
8971
|
);
|
|
@@ -8571,7 +8995,7 @@ function StnHeaderTitleClock({
|
|
|
8571
8995
|
resolvedTime = formatStnHeaderTitleTime(now, { showSeconds });
|
|
8572
8996
|
}
|
|
8573
8997
|
}
|
|
8574
|
-
return /* @__PURE__ */
|
|
8998
|
+
return /* @__PURE__ */ jsxs53(
|
|
8575
8999
|
"header",
|
|
8576
9000
|
{
|
|
8577
9001
|
className: cn(
|
|
@@ -8583,11 +9007,11 @@ function StnHeaderTitleClock({
|
|
|
8583
9007
|
),
|
|
8584
9008
|
...rest,
|
|
8585
9009
|
children: [
|
|
8586
|
-
framed ? /* @__PURE__ */
|
|
8587
|
-
/* @__PURE__ */
|
|
8588
|
-
resolvedDate ? /* @__PURE__ */
|
|
8589
|
-
showWeekdayOnly ? /* @__PURE__ */
|
|
8590
|
-
resolvedTime ? /* @__PURE__ */
|
|
9010
|
+
framed ? /* @__PURE__ */ jsx73(HeaderTitleFrame, {}) : null,
|
|
9011
|
+
/* @__PURE__ */ jsxs53("div", { className: "stn-header-title__content", children: [
|
|
9012
|
+
resolvedDate ? /* @__PURE__ */ jsx73("time", { className: "stn-header-title__date", dateTime: resolvedDate, children: resolvedDate }) : null,
|
|
9013
|
+
showWeekdayOnly ? /* @__PURE__ */ jsx73("span", { className: "stn-header-title__weekday", children: resolvedWeekday }) : null,
|
|
9014
|
+
resolvedTime ? /* @__PURE__ */ jsx73("span", { className: "stn-header-title__time", "aria-label": "\uD604\uC7AC \uC2DC\uAC01", children: resolvedTime }) : null
|
|
8591
9015
|
] })
|
|
8592
9016
|
]
|
|
8593
9017
|
}
|
|
@@ -8604,7 +9028,7 @@ function StnHeaderTitleDual({
|
|
|
8604
9028
|
...rest
|
|
8605
9029
|
}) {
|
|
8606
9030
|
const resolvedMain = mainText ?? title ?? children;
|
|
8607
|
-
return /* @__PURE__ */
|
|
9031
|
+
return /* @__PURE__ */ jsxs53(
|
|
8608
9032
|
"header",
|
|
8609
9033
|
{
|
|
8610
9034
|
className: cn(
|
|
@@ -8616,10 +9040,10 @@ function StnHeaderTitleDual({
|
|
|
8616
9040
|
),
|
|
8617
9041
|
...rest,
|
|
8618
9042
|
children: [
|
|
8619
|
-
framed ? /* @__PURE__ */
|
|
8620
|
-
/* @__PURE__ */
|
|
8621
|
-
subText != null ? /* @__PURE__ */
|
|
8622
|
-
resolvedMain != null ? typeof resolvedMain === "string" || typeof resolvedMain === "number" ? /* @__PURE__ */
|
|
9043
|
+
framed ? /* @__PURE__ */ jsx73(HeaderTitleFrame, {}) : null,
|
|
9044
|
+
/* @__PURE__ */ jsxs53("div", { className: "stn-header-title__content", children: [
|
|
9045
|
+
subText != null ? /* @__PURE__ */ jsx73("span", { className: "stn-header-title__sub-text", children: subText }) : null,
|
|
9046
|
+
resolvedMain != null ? typeof resolvedMain === "string" || typeof resolvedMain === "number" ? /* @__PURE__ */ jsx73("h1", { className: "stn-header-title__text", children: resolvedMain }) : resolvedMain : null
|
|
8623
9047
|
] })
|
|
8624
9048
|
]
|
|
8625
9049
|
}
|
|
@@ -8634,7 +9058,7 @@ function StnHeaderTitleText({
|
|
|
8634
9058
|
...rest
|
|
8635
9059
|
}) {
|
|
8636
9060
|
const resolved = title ?? children;
|
|
8637
|
-
return /* @__PURE__ */
|
|
9061
|
+
return /* @__PURE__ */ jsxs53(
|
|
8638
9062
|
"header",
|
|
8639
9063
|
{
|
|
8640
9064
|
className: cn(
|
|
@@ -8646,20 +9070,20 @@ function StnHeaderTitleText({
|
|
|
8646
9070
|
),
|
|
8647
9071
|
...rest,
|
|
8648
9072
|
children: [
|
|
8649
|
-
framed ? /* @__PURE__ */
|
|
8650
|
-
/* @__PURE__ */
|
|
9073
|
+
framed ? /* @__PURE__ */ jsx73(HeaderTitleFrame, {}) : null,
|
|
9074
|
+
/* @__PURE__ */ jsx73("div", { className: "stn-header-title__content", children: typeof resolved === "string" || typeof resolved === "number" ? /* @__PURE__ */ jsx73("h1", { className: "stn-header-title__text", children: resolved }) : resolved })
|
|
8651
9075
|
]
|
|
8652
9076
|
}
|
|
8653
9077
|
);
|
|
8654
9078
|
}
|
|
8655
9079
|
function StnHeaderTitleRoot(props) {
|
|
8656
9080
|
if (props.variant === "clock") {
|
|
8657
|
-
return /* @__PURE__ */
|
|
9081
|
+
return /* @__PURE__ */ jsx73(StnHeaderTitleClock, { ...props });
|
|
8658
9082
|
}
|
|
8659
9083
|
if (props.variant === "dual" || "subText" in props && props.subText != null) {
|
|
8660
|
-
return /* @__PURE__ */
|
|
9084
|
+
return /* @__PURE__ */ jsx73(StnHeaderTitleDual, { ...props });
|
|
8661
9085
|
}
|
|
8662
|
-
return /* @__PURE__ */
|
|
9086
|
+
return /* @__PURE__ */ jsx73(StnHeaderTitleText, { ...props });
|
|
8663
9087
|
}
|
|
8664
9088
|
var StnHeaderTitle = Object.assign(StnHeaderTitleRoot, {
|
|
8665
9089
|
Text: StnHeaderTitleMainText,
|
|
@@ -8672,10 +9096,10 @@ var StnHeaderTitle = Object.assign(StnHeaderTitleRoot, {
|
|
|
8672
9096
|
|
|
8673
9097
|
// src/layouts/StnContainer.tsx
|
|
8674
9098
|
import {
|
|
8675
|
-
forwardRef as
|
|
9099
|
+
forwardRef as forwardRef43
|
|
8676
9100
|
} from "react";
|
|
8677
|
-
import { jsx as
|
|
8678
|
-
var StnContainer =
|
|
9101
|
+
import { jsx as jsx74 } from "react/jsx-runtime";
|
|
9102
|
+
var StnContainer = forwardRef43(function StnContainer2({
|
|
8679
9103
|
component,
|
|
8680
9104
|
as,
|
|
8681
9105
|
maxWidth = "lg",
|
|
@@ -8690,7 +9114,7 @@ var StnContainer = forwardRef40(function StnContainer2({
|
|
|
8690
9114
|
const Component = component ?? as ?? "div";
|
|
8691
9115
|
const maxWidthClass = maxWidth ? `stn-container--${maxWidth} stn-container--max-width-${maxWidth}` : "stn-container--fluid stn-container--max-width-false";
|
|
8692
9116
|
const classKey = maxWidth ? `maxWidth${maxWidth.charAt(0).toUpperCase() + maxWidth.slice(1)}` : "maxWidthFalse";
|
|
8693
|
-
return /* @__PURE__ */
|
|
9117
|
+
return /* @__PURE__ */ jsx74(
|
|
8694
9118
|
Component,
|
|
8695
9119
|
{
|
|
8696
9120
|
ref,
|
|
@@ -8713,8 +9137,8 @@ var StnContainer = forwardRef40(function StnContainer2({
|
|
|
8713
9137
|
});
|
|
8714
9138
|
|
|
8715
9139
|
// src/layouts/StnGrid.tsx
|
|
8716
|
-
import { forwardRef as
|
|
8717
|
-
import { jsx as
|
|
9140
|
+
import { forwardRef as forwardRef44 } from "react";
|
|
9141
|
+
import { jsx as jsx75 } from "react/jsx-runtime";
|
|
8718
9142
|
var BREAKPOINTS2 = ["xs", "sm", "md", "lg", "xl"];
|
|
8719
9143
|
var SPACING_CLASS = {
|
|
8720
9144
|
"0": "0",
|
|
@@ -8780,7 +9204,7 @@ function sizeClasses(size) {
|
|
|
8780
9204
|
}
|
|
8781
9205
|
return classes;
|
|
8782
9206
|
}
|
|
8783
|
-
var StnGrid =
|
|
9207
|
+
var StnGrid = forwardRef44(function StnGrid2({
|
|
8784
9208
|
component,
|
|
8785
9209
|
as,
|
|
8786
9210
|
container = false,
|
|
@@ -8800,7 +9224,7 @@ var StnGrid = forwardRef41(function StnGrid2({
|
|
|
8800
9224
|
const Component = component ?? as ?? "div";
|
|
8801
9225
|
const justify = typeof justifyContent === "string" && JUSTIFY_CLASS2.has(justifyContent) ? justifyContent : void 0;
|
|
8802
9226
|
const align = typeof alignItems === "string" && ALIGN_CLASS2.has(alignItems) ? alignItems : void 0;
|
|
8803
|
-
return /* @__PURE__ */
|
|
9227
|
+
return /* @__PURE__ */ jsx75(
|
|
8804
9228
|
Component,
|
|
8805
9229
|
{
|
|
8806
9230
|
ref,
|
|
@@ -8824,7 +9248,7 @@ var StnGrid = forwardRef41(function StnGrid2({
|
|
|
8824
9248
|
});
|
|
8825
9249
|
|
|
8826
9250
|
// src/layouts/StnLayerShell.tsx
|
|
8827
|
-
import { jsx as
|
|
9251
|
+
import { jsx as jsx76, jsxs as jsxs54 } from "react/jsx-runtime";
|
|
8828
9252
|
function StnLayerShell({
|
|
8829
9253
|
gnb,
|
|
8830
9254
|
gnbSide = "left",
|
|
@@ -8845,7 +9269,7 @@ function StnLayerShell({
|
|
|
8845
9269
|
const resolvedMainContent = layer1 ?? children;
|
|
8846
9270
|
const resolvedModal = layer2;
|
|
8847
9271
|
const isGnbRight = gnbSide === "right";
|
|
8848
|
-
return /* @__PURE__ */
|
|
9272
|
+
return /* @__PURE__ */ jsxs54(
|
|
8849
9273
|
"div",
|
|
8850
9274
|
{
|
|
8851
9275
|
id: wrapId,
|
|
@@ -8854,8 +9278,8 @@ function StnLayerShell({
|
|
|
8854
9278
|
className: cn("stn-wrap", isGnbRight && "stn-wrap--gnb-right", wrapClassName),
|
|
8855
9279
|
children: [
|
|
8856
9280
|
layer0,
|
|
8857
|
-
utilities ? /* @__PURE__ */
|
|
8858
|
-
/* @__PURE__ */
|
|
9281
|
+
utilities ? /* @__PURE__ */ jsx76("div", { className: "stn-page-utilities", "data-stn-layer-role": "utility", children: utilities }) : null,
|
|
9282
|
+
/* @__PURE__ */ jsxs54(
|
|
8859
9283
|
"main",
|
|
8860
9284
|
{
|
|
8861
9285
|
id: containerId,
|
|
@@ -8864,9 +9288,9 @@ function StnLayerShell({
|
|
|
8864
9288
|
className: cn("stn-layer-1", scrollable && "scroll", containerClassName),
|
|
8865
9289
|
children: [
|
|
8866
9290
|
!isGnbRight && gnb,
|
|
8867
|
-
/* @__PURE__ */
|
|
8868
|
-
header ? /* @__PURE__ */
|
|
8869
|
-
/* @__PURE__ */
|
|
9291
|
+
/* @__PURE__ */ jsxs54("div", { className: "stn-layer-1__main", children: [
|
|
9292
|
+
header ? /* @__PURE__ */ jsx76("header", { className: "stn-layer-1__header", children: header }) : null,
|
|
9293
|
+
/* @__PURE__ */ jsx76("div", { className: cn("stn-layer-1__body", scrollable && "stn-scroll", contentClassName), children: resolvedMainContent })
|
|
8870
9294
|
] }),
|
|
8871
9295
|
isGnbRight && gnb
|
|
8872
9296
|
]
|
|
@@ -8879,7 +9303,7 @@ function StnLayerShell({
|
|
|
8879
9303
|
}
|
|
8880
9304
|
|
|
8881
9305
|
// src/layouts/StnListViewLayout.tsx
|
|
8882
|
-
import { jsx as
|
|
9306
|
+
import { jsx as jsx77, jsxs as jsxs55 } from "react/jsx-runtime";
|
|
8883
9307
|
function StnListViewLayoutBody({
|
|
8884
9308
|
search,
|
|
8885
9309
|
sidebar,
|
|
@@ -8890,13 +9314,13 @@ function StnListViewLayoutBody({
|
|
|
8890
9314
|
className
|
|
8891
9315
|
}) {
|
|
8892
9316
|
const lnbClass = lnbSide === "right" ? "stn-page-scaffold__lnb lnb_box lnb_box_right" : "stn-page-scaffold__lnb lnb_box";
|
|
8893
|
-
const sidebarAside = sidebar ? /* @__PURE__ */
|
|
8894
|
-
return /* @__PURE__ */
|
|
9317
|
+
const sidebarAside = sidebar ? /* @__PURE__ */ jsx77("aside", { className: lnbClass, children: sidebar }) : null;
|
|
9318
|
+
return /* @__PURE__ */ jsx77(
|
|
8895
9319
|
StnContainer,
|
|
8896
9320
|
{
|
|
8897
9321
|
maxWidth: false,
|
|
8898
9322
|
className: cn("stn-list-view-layout__body", className),
|
|
8899
|
-
children: /* @__PURE__ */
|
|
9323
|
+
children: /* @__PURE__ */ jsxs55(
|
|
8900
9324
|
StnStack,
|
|
8901
9325
|
{
|
|
8902
9326
|
direction: "row",
|
|
@@ -8904,19 +9328,19 @@ function StnListViewLayoutBody({
|
|
|
8904
9328
|
className: "stn-list-view__main",
|
|
8905
9329
|
children: [
|
|
8906
9330
|
lnbSide === "left" ? sidebarAside : null,
|
|
8907
|
-
/* @__PURE__ */
|
|
9331
|
+
/* @__PURE__ */ jsxs55(
|
|
8908
9332
|
StnStack,
|
|
8909
9333
|
{
|
|
8910
9334
|
direction: "column",
|
|
8911
9335
|
spacing: 2,
|
|
8912
9336
|
className: "stn-list-view__content-stack",
|
|
8913
9337
|
children: [
|
|
8914
|
-
search ? /* @__PURE__ */
|
|
8915
|
-
/* @__PURE__ */
|
|
9338
|
+
search ? /* @__PURE__ */ jsx77("div", { className: "stn-page-scaffold__search search_area", children: search }) : null,
|
|
9339
|
+
/* @__PURE__ */ jsx77(
|
|
8916
9340
|
"div",
|
|
8917
9341
|
{
|
|
8918
9342
|
className: "stn-page-scaffold__content content_box",
|
|
8919
|
-
children: children ?? /* @__PURE__ */
|
|
9343
|
+
children: children ?? /* @__PURE__ */ jsxs55("div", { className: "stn-table stn-table--fill", children: [
|
|
8920
9344
|
table,
|
|
8921
9345
|
pagination
|
|
8922
9346
|
] })
|
|
@@ -8948,7 +9372,7 @@ function StnListViewLayoutRoot({
|
|
|
8948
9372
|
}) {
|
|
8949
9373
|
const bare = bareProp ?? noShell ?? false;
|
|
8950
9374
|
const hasLnbClass = lnbSide === "right" ? "has_lnb_right" : "has_lnb";
|
|
8951
|
-
const body = /* @__PURE__ */
|
|
9375
|
+
const body = /* @__PURE__ */ jsx77(
|
|
8952
9376
|
StnListViewLayoutBody,
|
|
8953
9377
|
{
|
|
8954
9378
|
search,
|
|
@@ -8963,10 +9387,10 @@ function StnListViewLayoutRoot({
|
|
|
8963
9387
|
if (bare) {
|
|
8964
9388
|
return body;
|
|
8965
9389
|
}
|
|
8966
|
-
const renderedHeader = header === null ? null : header !== void 0 ? header : /* @__PURE__ */
|
|
8967
|
-
return /* @__PURE__ */
|
|
9390
|
+
const renderedHeader = header === null ? null : header !== void 0 ? header : /* @__PURE__ */ jsx77("div", { className: "stn-layer-1__header", children: /* @__PURE__ */ jsx77(StnHeader, { variant: "page", children: /* @__PURE__ */ jsx77(StnHeader.Left, { children: /* @__PURE__ */ jsx77(StnHeaderPageTitle, { children: title }) }) }) });
|
|
9391
|
+
return /* @__PURE__ */ jsxs55("div", { className: cn("stn-list-view-layout", "stn-layer-1", className), ...rest, children: [
|
|
8968
9392
|
renderedHeader,
|
|
8969
|
-
/* @__PURE__ */
|
|
9393
|
+
/* @__PURE__ */ jsx77(
|
|
8970
9394
|
"div",
|
|
8971
9395
|
{
|
|
8972
9396
|
className: cn("stn-content-area", sidebar ? hasLnbClass : null, search ? "has_sch" : null),
|
|
@@ -8976,10 +9400,10 @@ function StnListViewLayoutRoot({
|
|
|
8976
9400
|
] });
|
|
8977
9401
|
}
|
|
8978
9402
|
function StnListViewLayoutHeader({ className, children, ...rest }) {
|
|
8979
|
-
return /* @__PURE__ */
|
|
9403
|
+
return /* @__PURE__ */ jsx77("div", { className: cn("stn-layer-1__header", className), ...rest, children });
|
|
8980
9404
|
}
|
|
8981
9405
|
function StnListViewLayoutSearch({ className, children, ...rest }) {
|
|
8982
|
-
return /* @__PURE__ */
|
|
9406
|
+
return /* @__PURE__ */ jsx77("div", { className: cn("search_area", className), ...rest, children });
|
|
8983
9407
|
}
|
|
8984
9408
|
function StnListViewLayoutSidebar({
|
|
8985
9409
|
side = "left",
|
|
@@ -8988,16 +9412,16 @@ function StnListViewLayoutSidebar({
|
|
|
8988
9412
|
...rest
|
|
8989
9413
|
}) {
|
|
8990
9414
|
const lnbClass = side === "right" ? "lnb_box_right" : "lnb_box";
|
|
8991
|
-
return /* @__PURE__ */
|
|
9415
|
+
return /* @__PURE__ */ jsx77("aside", { className: cn(lnbClass, className), ...rest, children });
|
|
8992
9416
|
}
|
|
8993
9417
|
function StnListViewLayoutContent({ className, children, ...rest }) {
|
|
8994
|
-
return /* @__PURE__ */
|
|
9418
|
+
return /* @__PURE__ */ jsx77("div", { className: cn("content_box", className), ...rest, children });
|
|
8995
9419
|
}
|
|
8996
9420
|
function StnListViewLayoutTable({ className, children, ...rest }) {
|
|
8997
|
-
return /* @__PURE__ */
|
|
9421
|
+
return /* @__PURE__ */ jsx77("div", { className: cn("stn-table", className), ...rest, children });
|
|
8998
9422
|
}
|
|
8999
9423
|
function StnListViewLayoutPagination({ className, children, ...rest }) {
|
|
9000
|
-
return /* @__PURE__ */
|
|
9424
|
+
return /* @__PURE__ */ jsx77("div", { className: cn("stn-list-view-layout__pagination-wrap", className), ...rest, children });
|
|
9001
9425
|
}
|
|
9002
9426
|
var StnListViewLayout = Object.assign(StnListViewLayoutRoot, {
|
|
9003
9427
|
Body: StnListViewLayoutBody,
|
|
@@ -9031,13 +9455,13 @@ import {
|
|
|
9031
9455
|
} from "@stn-uiux/pub-ui/data/stnLayout";
|
|
9032
9456
|
|
|
9033
9457
|
// src/patterns/dashboard/StnMapCanvas.tsx
|
|
9034
|
-
import { jsx as
|
|
9458
|
+
import { jsx as jsx78 } from "react/jsx-runtime";
|
|
9035
9459
|
function StnMapCanvas({
|
|
9036
9460
|
children,
|
|
9037
9461
|
className,
|
|
9038
9462
|
...rest
|
|
9039
9463
|
}) {
|
|
9040
|
-
return /* @__PURE__ */
|
|
9464
|
+
return /* @__PURE__ */ jsx78(
|
|
9041
9465
|
"div",
|
|
9042
9466
|
{
|
|
9043
9467
|
className: cn("stn-map-canvas", className),
|
|
@@ -9049,7 +9473,7 @@ function StnMapCanvas({
|
|
|
9049
9473
|
}
|
|
9050
9474
|
|
|
9051
9475
|
// src/patterns/dashboard/StnDashboard.tsx
|
|
9052
|
-
import { jsx as
|
|
9476
|
+
import { jsx as jsx79 } from "react/jsx-runtime";
|
|
9053
9477
|
var fillStyle = {
|
|
9054
9478
|
flex: "1 1 0%",
|
|
9055
9479
|
minHeight: 0,
|
|
@@ -9068,7 +9492,7 @@ function StnDashboardRoot({
|
|
|
9068
9492
|
}) {
|
|
9069
9493
|
const isLeft = widgetPosition === "left";
|
|
9070
9494
|
const isBoth = widgetPosition === "both";
|
|
9071
|
-
return /* @__PURE__ */
|
|
9495
|
+
return /* @__PURE__ */ jsx79(
|
|
9072
9496
|
"div",
|
|
9073
9497
|
{
|
|
9074
9498
|
className: cn(
|
|
@@ -9097,7 +9521,7 @@ function StnDashboardLeft({
|
|
|
9097
9521
|
style,
|
|
9098
9522
|
...rest
|
|
9099
9523
|
}) {
|
|
9100
|
-
return /* @__PURE__ */
|
|
9524
|
+
return /* @__PURE__ */ jsx79(
|
|
9101
9525
|
"div",
|
|
9102
9526
|
{
|
|
9103
9527
|
className: cn("stn-dashboard__left", className),
|
|
@@ -9123,7 +9547,7 @@ function StnDashboardRight({
|
|
|
9123
9547
|
style,
|
|
9124
9548
|
...rest
|
|
9125
9549
|
}) {
|
|
9126
|
-
return /* @__PURE__ */
|
|
9550
|
+
return /* @__PURE__ */ jsx79(
|
|
9127
9551
|
"div",
|
|
9128
9552
|
{
|
|
9129
9553
|
className: cn("stn-dashboard__right", className),
|
|
@@ -9151,7 +9575,7 @@ function StnDashboardTopRight({
|
|
|
9151
9575
|
className,
|
|
9152
9576
|
...rest
|
|
9153
9577
|
}) {
|
|
9154
|
-
return /* @__PURE__ */
|
|
9578
|
+
return /* @__PURE__ */ jsx79(
|
|
9155
9579
|
"div",
|
|
9156
9580
|
{
|
|
9157
9581
|
className: cn("stn-dashboard__top-right", className),
|
|
@@ -9170,9 +9594,9 @@ var StnDashboard = Object.assign(StnDashboardRoot, {
|
|
|
9170
9594
|
});
|
|
9171
9595
|
|
|
9172
9596
|
// src/patterns/scaffold/StnPageScaffold.tsx
|
|
9173
|
-
import { jsx as
|
|
9597
|
+
import { jsx as jsx80, jsxs as jsxs56 } from "react/jsx-runtime";
|
|
9174
9598
|
function StnPageScaffoldRoot({ children, className, ...rest }) {
|
|
9175
|
-
return /* @__PURE__ */
|
|
9599
|
+
return /* @__PURE__ */ jsx80(
|
|
9176
9600
|
"div",
|
|
9177
9601
|
{
|
|
9178
9602
|
className: cn("stn-page-scaffold", className),
|
|
@@ -9189,9 +9613,9 @@ function StnPageScaffoldRegion({
|
|
|
9189
9613
|
className,
|
|
9190
9614
|
...rest
|
|
9191
9615
|
}) {
|
|
9192
|
-
return /* @__PURE__ */
|
|
9193
|
-
/* @__PURE__ */
|
|
9194
|
-
hint ? /* @__PURE__ */
|
|
9616
|
+
return /* @__PURE__ */ jsxs56("div", { className: cn("stn-page-scaffold__region", className), "data-stn-page-scaffold": "region", ...rest, children: [
|
|
9617
|
+
/* @__PURE__ */ jsx80("span", { className: "stn-page-scaffold__region-label", children: label }),
|
|
9618
|
+
hint ? /* @__PURE__ */ jsx80("span", { className: "stn-page-scaffold__region-hint", children: hint }) : null,
|
|
9195
9619
|
children
|
|
9196
9620
|
] });
|
|
9197
9621
|
}
|
|
@@ -9202,7 +9626,7 @@ function StnPageScaffoldMapPlaceholder({
|
|
|
9202
9626
|
children,
|
|
9203
9627
|
...rest
|
|
9204
9628
|
}) {
|
|
9205
|
-
return /* @__PURE__ */
|
|
9629
|
+
return /* @__PURE__ */ jsx80("div", { className: "stn-widget shell-canvas stn-map-canvas", "data-stn-dashboard": "canvas", children: /* @__PURE__ */ jsxs56(
|
|
9206
9630
|
"div",
|
|
9207
9631
|
{
|
|
9208
9632
|
className: cn("stn-page-scaffold__canvas-placeholder", className),
|
|
@@ -9210,8 +9634,8 @@ function StnPageScaffoldMapPlaceholder({
|
|
|
9210
9634
|
role: "status",
|
|
9211
9635
|
...rest,
|
|
9212
9636
|
children: [
|
|
9213
|
-
/* @__PURE__ */
|
|
9214
|
-
note ? /* @__PURE__ */
|
|
9637
|
+
/* @__PURE__ */ jsx80("p", { className: "stn-page-scaffold__canvas-placeholder-title", children: message }),
|
|
9638
|
+
note ? /* @__PURE__ */ jsx80("p", { className: "stn-page-scaffold__canvas-placeholder-note", children: note }) : null,
|
|
9215
9639
|
children
|
|
9216
9640
|
]
|
|
9217
9641
|
}
|
|
@@ -9222,7 +9646,7 @@ function StnPageScaffoldMapCanvas({
|
|
|
9222
9646
|
children,
|
|
9223
9647
|
...rest
|
|
9224
9648
|
}) {
|
|
9225
|
-
return /* @__PURE__ */
|
|
9649
|
+
return /* @__PURE__ */ jsx80(
|
|
9226
9650
|
"div",
|
|
9227
9651
|
{
|
|
9228
9652
|
className: cn("stn-widget", "shell-canvas", "stn-map-canvas", "stn-page-scaffold__canvas", className),
|
|
@@ -9235,7 +9659,7 @@ function StnPageScaffoldMapCanvas({
|
|
|
9235
9659
|
}
|
|
9236
9660
|
function StnPageScaffoldLayer({ label, hint, children, className, ...layerProps }) {
|
|
9237
9661
|
const labelText = label ? hint ? `${label} \xB7 ${hint}` : label : void 0;
|
|
9238
|
-
return /* @__PURE__ */
|
|
9662
|
+
return /* @__PURE__ */ jsx80(
|
|
9239
9663
|
StnLayer2,
|
|
9240
9664
|
{
|
|
9241
9665
|
className: cn(
|
|
@@ -9282,25 +9706,25 @@ function DashboardPageScaffold({
|
|
|
9282
9706
|
const isLeft = widgetPosition === "left";
|
|
9283
9707
|
const isBoth = widgetPosition === "both";
|
|
9284
9708
|
const isNone = widgetPosition === "none" || !showRightRegion;
|
|
9285
|
-
const mapColumn = /* @__PURE__ */
|
|
9286
|
-
/* @__PURE__ */
|
|
9709
|
+
const mapColumn = /* @__PURE__ */ jsxs56(StnDashboard.Left, { children: [
|
|
9710
|
+
/* @__PURE__ */ jsx80(StnPageScaffold.MapPlaceholder, { message: finalMapMessage, note: finalMapNote }),
|
|
9287
9711
|
faultPanel
|
|
9288
9712
|
] });
|
|
9289
|
-
const rightWidgets = right ?? /* @__PURE__ */
|
|
9290
|
-
const leftWidgets = left ?? right ?? /* @__PURE__ */
|
|
9291
|
-
const dashboardGrid = bodyEmpty ? /* @__PURE__ */
|
|
9292
|
-
/* @__PURE__ */
|
|
9713
|
+
const rightWidgets = right ?? /* @__PURE__ */ jsx80(StnPageScaffold.Region, { label: "dashboard_right", hint: "\uC704\uC82F\xB7\uC7A5\uC560 \uD328\uB110" });
|
|
9714
|
+
const leftWidgets = left ?? right ?? /* @__PURE__ */ jsx80(StnPageScaffold.Region, { label: "dashboard_right", hint: "\uC88C\uCE21 \uC704\uC82F\xB7\uC7A5\uC560 \uD328\uB110" });
|
|
9715
|
+
const dashboardGrid = bodyEmpty ? /* @__PURE__ */ jsx80(StnDashboard, { empty: true, widgetPosition, "data-stn-page-scaffold": "dashboard-empty" }) : isBoth ? /* @__PURE__ */ jsxs56(StnDashboard, { widgetPosition: "both", children: [
|
|
9716
|
+
/* @__PURE__ */ jsx80(StnDashboard.Right, { children: leftWidgets }),
|
|
9293
9717
|
mapColumn,
|
|
9294
|
-
/* @__PURE__ */
|
|
9295
|
-
] }) : isLeft ? /* @__PURE__ */
|
|
9296
|
-
/* @__PURE__ */
|
|
9718
|
+
/* @__PURE__ */ jsx80(StnDashboard.Right, { children: rightWidgets })
|
|
9719
|
+
] }) : isLeft ? /* @__PURE__ */ jsxs56(StnDashboard, { widgetPosition: "left", children: [
|
|
9720
|
+
/* @__PURE__ */ jsx80(StnDashboard.Right, { children: leftWidgets }),
|
|
9297
9721
|
mapColumn
|
|
9298
|
-
] }) : /* @__PURE__ */
|
|
9722
|
+
] }) : /* @__PURE__ */ jsxs56(StnDashboard, { widgetPosition: isNone ? "none" : "right", children: [
|
|
9299
9723
|
mapColumn,
|
|
9300
|
-
!isNone ? /* @__PURE__ */
|
|
9724
|
+
!isNone ? /* @__PURE__ */ jsx80(StnDashboard.Right, { children: rightWidgets }) : null
|
|
9301
9725
|
] });
|
|
9302
9726
|
const contentNode = children ?? dashboardGrid;
|
|
9303
|
-
return /* @__PURE__ */
|
|
9727
|
+
return /* @__PURE__ */ jsx80(
|
|
9304
9728
|
StnLayerShell,
|
|
9305
9729
|
{
|
|
9306
9730
|
gnb,
|
|
@@ -9309,7 +9733,7 @@ function DashboardPageScaffold({
|
|
|
9309
9733
|
layer0,
|
|
9310
9734
|
layer2,
|
|
9311
9735
|
...shellProps,
|
|
9312
|
-
children: /* @__PURE__ */
|
|
9736
|
+
children: /* @__PURE__ */ jsx80(
|
|
9313
9737
|
StnContainer,
|
|
9314
9738
|
{
|
|
9315
9739
|
maxWidth: false,
|
|
@@ -9323,16 +9747,16 @@ function DashboardPageScaffold({
|
|
|
9323
9747
|
}
|
|
9324
9748
|
|
|
9325
9749
|
// src/patterns/scaffold/AlertCenterPageScaffold.tsx
|
|
9326
|
-
import { useMemo as useMemo5, useState as
|
|
9750
|
+
import { useMemo as useMemo5, useState as useState21 } from "react";
|
|
9327
9751
|
import {
|
|
9328
9752
|
STN_ALERT_CENTER_DEMO_ALERTS,
|
|
9329
9753
|
STN_ALERT_CENTER_DEMO_DEPLOY,
|
|
9330
9754
|
STN_ALERT_CENTER_DEMO_WORK
|
|
9331
9755
|
} from "@stn-uiux/pub-ui/data/stnAlertCenter";
|
|
9332
9756
|
import { systemIconSrc } from "@stn-uiux/pub-ui/data/stnSystemIcons";
|
|
9333
|
-
import { Fragment as Fragment10, jsx as
|
|
9757
|
+
import { Fragment as Fragment10, jsx as jsx81, jsxs as jsxs57 } from "react/jsx-runtime";
|
|
9334
9758
|
function defaultTopologyHeader(_clock) {
|
|
9335
|
-
return /* @__PURE__ */
|
|
9759
|
+
return /* @__PURE__ */ jsx81(StnHeader, { variant: "widget" });
|
|
9336
9760
|
}
|
|
9337
9761
|
function AlertCenterPageScaffold({
|
|
9338
9762
|
gnbAlertPanel,
|
|
@@ -9349,9 +9773,9 @@ function AlertCenterPageScaffold({
|
|
|
9349
9773
|
defaultGnbOpen = true,
|
|
9350
9774
|
...shellProps
|
|
9351
9775
|
}) {
|
|
9352
|
-
const [gnbOpen, setGnbOpen] =
|
|
9776
|
+
const [gnbOpen, setGnbOpen] = useState21(defaultGnbOpen);
|
|
9353
9777
|
const panel = useMemo5(
|
|
9354
|
-
() => gnbAlertPanel ?? /* @__PURE__ */
|
|
9778
|
+
() => gnbAlertPanel ?? /* @__PURE__ */ jsx81(
|
|
9355
9779
|
StnAlertCenterPanel,
|
|
9356
9780
|
{
|
|
9357
9781
|
alerts: STN_ALERT_CENTER_DEMO_ALERTS,
|
|
@@ -9362,26 +9786,26 @@ function AlertCenterPageScaffold({
|
|
|
9362
9786
|
[gnbAlertPanel]
|
|
9363
9787
|
);
|
|
9364
9788
|
const sideNav = useMemo5(
|
|
9365
|
-
() => gnbProp ?? /* @__PURE__ */
|
|
9366
|
-
/* @__PURE__ */
|
|
9789
|
+
() => gnbProp ?? /* @__PURE__ */ jsxs57(Fragment10, { children: [
|
|
9790
|
+
/* @__PURE__ */ jsxs57(
|
|
9367
9791
|
StnSideNavigation,
|
|
9368
9792
|
{
|
|
9369
9793
|
collapsed: !gnbOpen,
|
|
9370
9794
|
onCollapseChange: (col) => setGnbOpen(!col),
|
|
9371
9795
|
children: [
|
|
9372
|
-
/* @__PURE__ */
|
|
9373
|
-
/* @__PURE__ */
|
|
9374
|
-
/* @__PURE__ */
|
|
9796
|
+
/* @__PURE__ */ jsxs57(StnSideNavigation.Header, { children: [
|
|
9797
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Logo, {}),
|
|
9798
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Toggle, {})
|
|
9375
9799
|
] }),
|
|
9376
|
-
/* @__PURE__ */
|
|
9377
|
-
/* @__PURE__ */
|
|
9378
|
-
/* @__PURE__ */
|
|
9379
|
-
/* @__PURE__ */
|
|
9800
|
+
/* @__PURE__ */ jsxs57(StnSideNavigation.Menu, { children: [
|
|
9801
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/layout-grid"), label: "\uBA54\uC778 \uB300\uC2DC\uBCF4\uB4DC", active: true }),
|
|
9802
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/server_2"), label: "\uC11C\uBC84 \uBAA8\uB2C8\uD130\uB9C1" }),
|
|
9803
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/activity"), label: "\uB124\uD2B8\uC6CC\uD06C \uBD84\uC11D" })
|
|
9380
9804
|
] }),
|
|
9381
|
-
/* @__PURE__ */
|
|
9382
|
-
/* @__PURE__ */
|
|
9383
|
-
/* @__PURE__ */
|
|
9384
|
-
/* @__PURE__ */
|
|
9805
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Spacer, {}),
|
|
9806
|
+
/* @__PURE__ */ jsxs57(StnSideNavigation.Footer, { curved: true, children: [
|
|
9807
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Watermark, {}),
|
|
9808
|
+
/* @__PURE__ */ jsx81(
|
|
9385
9809
|
StnSideNavigation.Item,
|
|
9386
9810
|
{
|
|
9387
9811
|
iconSrc: systemIconSrc("line/bell"),
|
|
@@ -9390,7 +9814,7 @@ function AlertCenterPageScaffold({
|
|
|
9390
9814
|
onClick: void 0
|
|
9391
9815
|
}
|
|
9392
9816
|
),
|
|
9393
|
-
/* @__PURE__ */
|
|
9817
|
+
/* @__PURE__ */ jsx81(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/settings"), label: "\uC124\uC815" })
|
|
9394
9818
|
] })
|
|
9395
9819
|
]
|
|
9396
9820
|
}
|
|
@@ -9399,8 +9823,8 @@ function AlertCenterPageScaffold({
|
|
|
9399
9823
|
] }),
|
|
9400
9824
|
[gnbProp, gnbOpen, panel]
|
|
9401
9825
|
);
|
|
9402
|
-
const faultSlot = faultPanel ?? (showFaultPanelPlaceholder ? /* @__PURE__ */
|
|
9403
|
-
return /* @__PURE__ */
|
|
9826
|
+
const faultSlot = faultPanel ?? (showFaultPanelPlaceholder ? /* @__PURE__ */ jsx81("div", { className: "wrap_real_time stn-page-scaffold__fault-ph", children: /* @__PURE__ */ jsx81(StnPageScaffold.Region, { label: "\uC2E4\uC2DC\uAC04 \uC7A5\uC560 \uD604\uD669", hint: "StnWidget shell=fault-panel \xB7 \uC120\uD0DD" }) }) : null);
|
|
9827
|
+
return /* @__PURE__ */ jsx81(
|
|
9404
9828
|
DashboardPageScaffold,
|
|
9405
9829
|
{
|
|
9406
9830
|
gnb: sideNav,
|
|
@@ -9408,7 +9832,7 @@ function AlertCenterPageScaffold({
|
|
|
9408
9832
|
mapMessage,
|
|
9409
9833
|
mapNote,
|
|
9410
9834
|
faultPanel: faultSlot,
|
|
9411
|
-
right: right ?? /* @__PURE__ */
|
|
9835
|
+
right: right ?? /* @__PURE__ */ jsx81(AlertCenterDashboard, {}),
|
|
9412
9836
|
wrapId,
|
|
9413
9837
|
wrapClassName: "stn-page--map-bg",
|
|
9414
9838
|
...shellProps
|
|
@@ -9417,8 +9841,8 @@ function AlertCenterPageScaffold({
|
|
|
9417
9841
|
}
|
|
9418
9842
|
|
|
9419
9843
|
// src/patterns/scaffold/LoginPageScaffold.tsx
|
|
9420
|
-
import { useState as
|
|
9421
|
-
import { jsx as
|
|
9844
|
+
import { useState as useState22 } from "react";
|
|
9845
|
+
import { jsx as jsx82, jsxs as jsxs58 } from "react/jsx-runtime";
|
|
9422
9846
|
var LOGIN_TABS = [
|
|
9423
9847
|
{ value: "normal", label: "\uC77C\uBC18 \uB85C\uADF8\uC778" },
|
|
9424
9848
|
{ value: "social", label: "\uC18C\uC15C \uB85C\uADF8\uC778" }
|
|
@@ -9429,15 +9853,15 @@ function DefaultLoginForm({
|
|
|
9429
9853
|
signUpHref = "#",
|
|
9430
9854
|
recoverHref = "#"
|
|
9431
9855
|
}) {
|
|
9432
|
-
const [mode, setMode] =
|
|
9433
|
-
const [userId, setUserId] =
|
|
9434
|
-
const [password, setPassword] =
|
|
9856
|
+
const [mode, setMode] = useState22("normal");
|
|
9857
|
+
const [userId, setUserId] = useState22("");
|
|
9858
|
+
const [password, setPassword] = useState22("");
|
|
9435
9859
|
function handleSubmit(e) {
|
|
9436
9860
|
e.preventDefault();
|
|
9437
9861
|
onLogin?.(userId, password);
|
|
9438
9862
|
}
|
|
9439
|
-
return /* @__PURE__ */
|
|
9440
|
-
/* @__PURE__ */
|
|
9863
|
+
return /* @__PURE__ */ jsxs58(StnLoginFormStack, { onSubmit: handleSubmit, children: [
|
|
9864
|
+
/* @__PURE__ */ jsx82(
|
|
9441
9865
|
StnSegmented,
|
|
9442
9866
|
{
|
|
9443
9867
|
"aria-label": "\uB85C\uADF8\uC778 \uBC29\uC2DD",
|
|
@@ -9446,8 +9870,8 @@ function DefaultLoginForm({
|
|
|
9446
9870
|
options: LOGIN_TABS
|
|
9447
9871
|
}
|
|
9448
9872
|
),
|
|
9449
|
-
mode === "normal" ? /* @__PURE__ */
|
|
9450
|
-
/* @__PURE__ */
|
|
9873
|
+
mode === "normal" ? /* @__PURE__ */ jsxs58(StnLoginFormFields, { children: [
|
|
9874
|
+
/* @__PURE__ */ jsx82(
|
|
9451
9875
|
StnLoginTextField,
|
|
9452
9876
|
{
|
|
9453
9877
|
icon: "line/user",
|
|
@@ -9459,7 +9883,7 @@ function DefaultLoginForm({
|
|
|
9459
9883
|
"aria-label": "\uC544\uC774\uB514"
|
|
9460
9884
|
}
|
|
9461
9885
|
),
|
|
9462
|
-
/* @__PURE__ */
|
|
9886
|
+
/* @__PURE__ */ jsx82(
|
|
9463
9887
|
StnLoginTextField,
|
|
9464
9888
|
{
|
|
9465
9889
|
icon: "line/lock",
|
|
@@ -9472,11 +9896,11 @@ function DefaultLoginForm({
|
|
|
9472
9896
|
"aria-label": "\uBE44\uBC00\uBC88\uD638"
|
|
9473
9897
|
}
|
|
9474
9898
|
)
|
|
9475
|
-
] }) : socialContent ?? /* @__PURE__ */
|
|
9476
|
-
/* @__PURE__ */
|
|
9477
|
-
/* @__PURE__ */
|
|
9478
|
-
/* @__PURE__ */
|
|
9479
|
-
/* @__PURE__ */
|
|
9899
|
+
] }) : socialContent ?? /* @__PURE__ */ jsx82(StnLoginPlaceholder, {}),
|
|
9900
|
+
/* @__PURE__ */ jsx82(StnButton, { type: "submit", size: "xl", fullWidth: true, children: "\uB85C\uADF8\uC778" }),
|
|
9901
|
+
/* @__PURE__ */ jsxs58(StnLoginFormLinks, { children: [
|
|
9902
|
+
/* @__PURE__ */ jsx82("a", { href: signUpHref, children: "\uD68C\uC6D0\uAC00\uC785" }),
|
|
9903
|
+
/* @__PURE__ */ jsx82("a", { href: recoverHref, children: "\uC544\uC774\uB514 / \uBE44\uBC00\uBC88\uD638 \uCC3E\uAE30" })
|
|
9480
9904
|
] })
|
|
9481
9905
|
] });
|
|
9482
9906
|
}
|
|
@@ -9490,16 +9914,16 @@ function DefaultLoginCard({
|
|
|
9490
9914
|
signUpHref,
|
|
9491
9915
|
recoverHref
|
|
9492
9916
|
}) {
|
|
9493
|
-
return /* @__PURE__ */
|
|
9917
|
+
return /* @__PURE__ */ jsx82(
|
|
9494
9918
|
StnLoginCard,
|
|
9495
9919
|
{
|
|
9496
9920
|
glow,
|
|
9497
9921
|
variant,
|
|
9498
|
-
brand: /* @__PURE__ */
|
|
9499
|
-
logo ?? /* @__PURE__ */
|
|
9500
|
-
/* @__PURE__ */
|
|
9922
|
+
brand: /* @__PURE__ */ jsxs58(StnLoginBrandStack, { children: [
|
|
9923
|
+
logo ?? /* @__PURE__ */ jsx82(StnLogo, { variant: "vertical", size: "xl" }),
|
|
9924
|
+
/* @__PURE__ */ jsx82("p", { className: "stn-login-card__caption", children: productCaption })
|
|
9501
9925
|
] }),
|
|
9502
|
-
children: /* @__PURE__ */
|
|
9926
|
+
children: /* @__PURE__ */ jsx82(
|
|
9503
9927
|
DefaultLoginForm,
|
|
9504
9928
|
{
|
|
9505
9929
|
onLogin,
|
|
@@ -9525,8 +9949,8 @@ function LoginPageScaffold({
|
|
|
9525
9949
|
recoverHref,
|
|
9526
9950
|
...shellProps
|
|
9527
9951
|
}) {
|
|
9528
|
-
const resolvedLayer0 = layer0 ?? /* @__PURE__ */
|
|
9529
|
-
const resolvedCard = children ?? /* @__PURE__ */
|
|
9952
|
+
const resolvedLayer0 = layer0 ?? /* @__PURE__ */ jsx82(StnLayer0Background, { variant: "login" });
|
|
9953
|
+
const resolvedCard = children ?? /* @__PURE__ */ jsx82(
|
|
9530
9954
|
DefaultLoginCard,
|
|
9531
9955
|
{
|
|
9532
9956
|
logo,
|
|
@@ -9539,7 +9963,7 @@ function LoginPageScaffold({
|
|
|
9539
9963
|
recoverHref
|
|
9540
9964
|
}
|
|
9541
9965
|
);
|
|
9542
|
-
return /* @__PURE__ */
|
|
9966
|
+
return /* @__PURE__ */ jsxs58(
|
|
9543
9967
|
"div",
|
|
9544
9968
|
{
|
|
9545
9969
|
className: cn("stn-wrap stn-page--login", wrapClassName),
|
|
@@ -9547,7 +9971,7 @@ function LoginPageScaffold({
|
|
|
9547
9971
|
...shellProps,
|
|
9548
9972
|
children: [
|
|
9549
9973
|
resolvedLayer0,
|
|
9550
|
-
/* @__PURE__ */
|
|
9974
|
+
/* @__PURE__ */ jsx82("div", { className: "stn-login", children: resolvedCard })
|
|
9551
9975
|
]
|
|
9552
9976
|
}
|
|
9553
9977
|
);
|
|
@@ -9576,7 +10000,7 @@ import {
|
|
|
9576
10000
|
|
|
9577
10001
|
// src/patterns/toolbar/StnFloatingToolbar.tsx
|
|
9578
10002
|
import React3 from "react";
|
|
9579
|
-
import { jsx as
|
|
10003
|
+
import { jsx as jsx83, jsxs as jsxs59 } from "react/jsx-runtime";
|
|
9580
10004
|
var DEFAULT_MAP_MODES = [
|
|
9581
10005
|
{ value: "sphere", label: "\uAD6C\uBA74" },
|
|
9582
10006
|
{ value: "plane", label: "\uD3C9\uBA74" },
|
|
@@ -9586,7 +10010,7 @@ var StnFloatingToolbar = React3.forwardRef(
|
|
|
9586
10010
|
({ placement = "none", orientation = "horizontal", className, children, ...restProps }, ref) => {
|
|
9587
10011
|
const placementClass = placement !== "none" ? `stn-floating-toolbar--${placement}` : "";
|
|
9588
10012
|
const orientationClass = orientation === "vertical" ? "stn-floating-toolbar--vertical" : "";
|
|
9589
|
-
return /* @__PURE__ */
|
|
10013
|
+
return /* @__PURE__ */ jsx83(
|
|
9590
10014
|
"div",
|
|
9591
10015
|
{
|
|
9592
10016
|
ref,
|
|
@@ -9619,7 +10043,7 @@ var StnMapToolbar = React3.forwardRef(
|
|
|
9619
10043
|
children,
|
|
9620
10044
|
...restProps
|
|
9621
10045
|
}, ref) => {
|
|
9622
|
-
return /* @__PURE__ */
|
|
10046
|
+
return /* @__PURE__ */ jsxs59(
|
|
9623
10047
|
StnFloatingToolbar,
|
|
9624
10048
|
{
|
|
9625
10049
|
ref,
|
|
@@ -9629,7 +10053,7 @@ var StnMapToolbar = React3.forwardRef(
|
|
|
9629
10053
|
"aria-label": "\uC9C0\uB3C4 \uBC0F \uD1A0\uD3F4\uB85C\uC9C0 \uB3C4\uAD6C \uBAA8\uC74C",
|
|
9630
10054
|
...restProps,
|
|
9631
10055
|
children: [
|
|
9632
|
-
modeOptions && modeOptions.length > 0 && /* @__PURE__ */
|
|
10056
|
+
modeOptions && modeOptions.length > 0 && /* @__PURE__ */ jsx83(
|
|
9633
10057
|
StnDropdown,
|
|
9634
10058
|
{
|
|
9635
10059
|
size: "md",
|
|
@@ -9640,75 +10064,75 @@ var StnMapToolbar = React3.forwardRef(
|
|
|
9640
10064
|
"aria-label": "\uD22C\uC601 \uBAA8\uB4DC \uC120\uD0DD"
|
|
9641
10065
|
}
|
|
9642
10066
|
),
|
|
9643
|
-
onRestore && /* @__PURE__ */
|
|
10067
|
+
onRestore && /* @__PURE__ */ jsx83(
|
|
9644
10068
|
StnButton,
|
|
9645
10069
|
{
|
|
9646
10070
|
variant: buttonVariant,
|
|
9647
10071
|
size: "md",
|
|
9648
10072
|
shape: "square",
|
|
9649
|
-
icon: /* @__PURE__ */
|
|
9650
|
-
/* @__PURE__ */
|
|
9651
|
-
/* @__PURE__ */
|
|
9652
|
-
/* @__PURE__ */
|
|
10073
|
+
icon: /* @__PURE__ */ jsxs59("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.6", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", children: [
|
|
10074
|
+
/* @__PURE__ */ jsx83("path", { d: "M3.06006 13C3.30547 15.1939 4.34865 17.221 5.9912 18.696C7.63374 20.1709 9.76108 20.9907 11.9686 20.9994C14.1762 21.0081 16.3099 20.2052 17.9641 18.7434C19.6183 17.2815 20.6775 15.2627 20.9403 13.0708C21.2031 10.879 20.6511 8.66696 19.3894 6.85551C18.1276 5.04406 16.2441 3.75951 14.0971 3.24618C11.95 2.73284 9.68922 3.02652 7.74457 4.07135C5.79993 5.11619 4.30712 6.83931 3.55006 8.913" }),
|
|
10075
|
+
/* @__PURE__ */ jsx83("path", { d: "M3 4.00098V9.00098H8" }),
|
|
10076
|
+
/* @__PURE__ */ jsx83("circle", { cx: "12", cy: "12", r: "1", fill: "currentColor" })
|
|
9653
10077
|
] }),
|
|
9654
10078
|
"aria-label": "\uCD08\uAE30\uD654 (Restore)",
|
|
9655
10079
|
title: "\uCD08\uAE30\uD654 (Restore)",
|
|
9656
10080
|
onClick: onRestore
|
|
9657
10081
|
}
|
|
9658
10082
|
),
|
|
9659
|
-
onFullscreen && /* @__PURE__ */
|
|
10083
|
+
onFullscreen && /* @__PURE__ */ jsx83(
|
|
9660
10084
|
StnButton,
|
|
9661
10085
|
{
|
|
9662
10086
|
variant: buttonVariant,
|
|
9663
10087
|
size: "md",
|
|
9664
10088
|
shape: "square",
|
|
9665
|
-
icon: /* @__PURE__ */
|
|
9666
|
-
/* @__PURE__ */
|
|
9667
|
-
/* @__PURE__ */
|
|
9668
|
-
/* @__PURE__ */
|
|
9669
|
-
/* @__PURE__ */
|
|
10089
|
+
icon: /* @__PURE__ */ jsxs59("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.6", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", children: [
|
|
10090
|
+
/* @__PURE__ */ jsx83("path", { d: "M16 4H20V8" }),
|
|
10091
|
+
/* @__PURE__ */ jsx83("path", { d: "M14 10L20 4" }),
|
|
10092
|
+
/* @__PURE__ */ jsx83("path", { d: "M8 20H4V16" }),
|
|
10093
|
+
/* @__PURE__ */ jsx83("path", { d: "M4 20L10 14" })
|
|
9670
10094
|
] }),
|
|
9671
10095
|
"aria-label": "\uC804\uCCB4\uD654\uBA74",
|
|
9672
10096
|
title: "\uC804\uCCB4\uD654\uBA74",
|
|
9673
10097
|
onClick: onFullscreen
|
|
9674
10098
|
}
|
|
9675
10099
|
),
|
|
9676
|
-
onZoomIn && /* @__PURE__ */
|
|
10100
|
+
onZoomIn && /* @__PURE__ */ jsx83(
|
|
9677
10101
|
StnButton,
|
|
9678
10102
|
{
|
|
9679
10103
|
variant: buttonVariant,
|
|
9680
10104
|
size: "md",
|
|
9681
10105
|
shape: "square",
|
|
9682
|
-
icon: /* @__PURE__ */
|
|
9683
|
-
/* @__PURE__ */
|
|
9684
|
-
/* @__PURE__ */
|
|
10106
|
+
icon: /* @__PURE__ */ jsxs59("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", children: [
|
|
10107
|
+
/* @__PURE__ */ jsx83("path", { d: "M12 5V19" }),
|
|
10108
|
+
/* @__PURE__ */ jsx83("path", { d: "M5 12H19" })
|
|
9685
10109
|
] }),
|
|
9686
10110
|
"aria-label": "\uD655\uB300",
|
|
9687
10111
|
title: "\uD655\uB300",
|
|
9688
10112
|
onClick: onZoomIn
|
|
9689
10113
|
}
|
|
9690
10114
|
),
|
|
9691
|
-
onZoomOut && /* @__PURE__ */
|
|
10115
|
+
onZoomOut && /* @__PURE__ */ jsx83(
|
|
9692
10116
|
StnButton,
|
|
9693
10117
|
{
|
|
9694
10118
|
variant: buttonVariant,
|
|
9695
10119
|
size: "md",
|
|
9696
10120
|
shape: "square",
|
|
9697
|
-
icon: /* @__PURE__ */
|
|
10121
|
+
icon: /* @__PURE__ */ jsx83("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", children: /* @__PURE__ */ jsx83("path", { d: "M5 12H19" }) }),
|
|
9698
10122
|
"aria-label": "\uCD95\uC18C",
|
|
9699
10123
|
title: "\uCD95\uC18C",
|
|
9700
10124
|
onClick: onZoomOut
|
|
9701
10125
|
}
|
|
9702
10126
|
),
|
|
9703
|
-
onRefresh && /* @__PURE__ */
|
|
10127
|
+
onRefresh && /* @__PURE__ */ jsx83(
|
|
9704
10128
|
StnButton,
|
|
9705
10129
|
{
|
|
9706
10130
|
variant: buttonVariant,
|
|
9707
10131
|
size: "md",
|
|
9708
10132
|
shape: "square",
|
|
9709
|
-
icon: /* @__PURE__ */
|
|
9710
|
-
/* @__PURE__ */
|
|
9711
|
-
/* @__PURE__ */
|
|
10133
|
+
icon: /* @__PURE__ */ jsxs59("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.6", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", children: [
|
|
10134
|
+
/* @__PURE__ */ jsx83("path", { d: "M20 11C19.7554 9.24023 18.9391 7.60967 17.6766 6.35951C16.4142 5.10934 14.7758 4.30893 13.0137 4.08156C11.2516 3.8542 9.46362 4.21249 7.9252 5.10126C6.38678 5.99002 5.18325 7.35995 4.5 9.00001M4 5.00001V9.00001H8" }),
|
|
10135
|
+
/* @__PURE__ */ jsx83("path", { d: "M4 13C4.24456 14.7598 5.06093 16.3903 6.32336 17.6405C7.58579 18.8907 9.22424 19.6911 10.9863 19.9184C12.7484 20.1458 14.5364 19.7875 16.0748 18.8988C17.6132 18.01 18.8168 16.6401 19.5 15M20 19V15H16" })
|
|
9712
10136
|
] }),
|
|
9713
10137
|
"aria-label": "\uC0C8\uB85C\uACE0\uCE68",
|
|
9714
10138
|
title: "\uC0C8\uB85C\uACE0\uCE68",
|
|
@@ -9965,6 +10389,9 @@ export {
|
|
|
9965
10389
|
StnStatusSeverity,
|
|
9966
10390
|
StnStatusSwitch,
|
|
9967
10391
|
StnSwitch,
|
|
10392
|
+
StnTab,
|
|
10393
|
+
StnTabContextProvider,
|
|
10394
|
+
StnTabPanel,
|
|
9968
10395
|
StnTable,
|
|
9969
10396
|
StnTableBody,
|
|
9970
10397
|
StnTableGrid,
|
|
@@ -9975,6 +10402,8 @@ export {
|
|
|
9975
10402
|
StnTableTdCheck,
|
|
9976
10403
|
StnTableTh,
|
|
9977
10404
|
StnTableThCheck,
|
|
10405
|
+
StnTabs2 as StnTabs,
|
|
10406
|
+
StnTabsRoot,
|
|
9978
10407
|
StnTextArea,
|
|
9979
10408
|
StnTextField,
|
|
9980
10409
|
StnToastCloseButton,
|
|
@@ -10025,6 +10454,7 @@ export {
|
|
|
10025
10454
|
systemIconSrc2 as systemIconSrc,
|
|
10026
10455
|
useSideNav,
|
|
10027
10456
|
useStn,
|
|
10028
|
-
useStnOptional
|
|
10457
|
+
useStnOptional,
|
|
10458
|
+
useStnTabsContext
|
|
10029
10459
|
};
|
|
10030
10460
|
//# sourceMappingURL=index.js.map
|