@stn-uiux/pub-ui-react 0.1.62 → 0.1.64
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 +76 -24
- package/dist/index.js +895 -778
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -177,13 +177,12 @@ function resolveButtonWidthProps(fullWidth, width, defaultPreset) {
|
|
|
177
177
|
// src/components/StnIcon.tsx
|
|
178
178
|
import { resolveSystemIconSrcFromName } from "@stn-uiux/pub-ui/data/stnSystemIcons";
|
|
179
179
|
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
180
|
-
function StnIcon({ name, src, color, size
|
|
180
|
+
function StnIcon({ name, src, color, size, className, style }) {
|
|
181
181
|
if (name && src) {
|
|
182
182
|
console.warn("[StnIcon] `name` and `src` cannot be used together. Using `src`.");
|
|
183
183
|
}
|
|
184
184
|
const sizeStyle = {
|
|
185
|
-
width: size,
|
|
186
|
-
height: size,
|
|
185
|
+
...size !== void 0 ? { width: size, height: size } : void 0,
|
|
187
186
|
...style
|
|
188
187
|
};
|
|
189
188
|
const resolvedSrc = src ?? (name ? resolveSystemIconSrcFromName(name) : null);
|
|
@@ -358,6 +357,7 @@ var StnTooltip = forwardRef2(
|
|
|
358
357
|
iconPosition = "left",
|
|
359
358
|
leadingIcon,
|
|
360
359
|
trailingIcon,
|
|
360
|
+
offset,
|
|
361
361
|
open,
|
|
362
362
|
alwaysVisible,
|
|
363
363
|
tooltipClassName,
|
|
@@ -368,11 +368,16 @@ var StnTooltip = forwardRef2(
|
|
|
368
368
|
const glyphPx = TOOLTIP_ICON_PX[size] ?? 14;
|
|
369
369
|
const finalLeadingIcon = leadingIcon != null ? resolveIconNode2(leadingIcon, glyphPx) : icon != null && iconPosition !== "right" ? resolveIconNode2(icon, glyphPx) : null;
|
|
370
370
|
const finalTrailingIcon = trailingIcon != null ? resolveIconNode2(trailingIcon, glyphPx) : icon != null && iconPosition === "right" ? resolveIconNode2(icon, glyphPx) : null;
|
|
371
|
+
const resolvedOffset = offset !== void 0 ? typeof offset === "number" ? `${offset}px` : /^space[-_]\d+$/.test(String(offset).trim()) ? `var(--stn-${String(offset).trim().replace("_", "-")})` : /^\d+$/.test(String(offset).trim()) ? `${String(offset).trim()}px` : String(offset).trim() : void 0;
|
|
372
|
+
const tooltipStyle = resolvedOffset !== void 0 ? {
|
|
373
|
+
"--stn-tooltip-offset": resolvedOffset
|
|
374
|
+
} : void 0;
|
|
371
375
|
const tooltipElement = /* @__PURE__ */ jsxs2(
|
|
372
376
|
"div",
|
|
373
377
|
{
|
|
374
378
|
ref: !children ? ref : void 0,
|
|
375
379
|
role: "tooltip",
|
|
380
|
+
style: tooltipStyle,
|
|
376
381
|
className: cn(
|
|
377
382
|
"stn-tooltip",
|
|
378
383
|
variant,
|
|
@@ -1926,40 +1931,6 @@ var StnStatusSeverity = forwardRef11(function StnStatusSeverity2({
|
|
|
1926
1931
|
] });
|
|
1927
1932
|
});
|
|
1928
1933
|
StnStatusSeverity.displayName = "StnStatusSeverity";
|
|
1929
|
-
var ALL_SEVERITIES = ["critical", "major", "minor", "warning"];
|
|
1930
|
-
function StnStatusSeverityFilter({
|
|
1931
|
-
value = ALL_SEVERITIES,
|
|
1932
|
-
onChange,
|
|
1933
|
-
disabledSeverities = [],
|
|
1934
|
-
showIcon = true,
|
|
1935
|
-
className = ""
|
|
1936
|
-
}) {
|
|
1937
|
-
const handleToggle = (sev) => {
|
|
1938
|
-
if (!onChange) return;
|
|
1939
|
-
const exists = value.includes(sev);
|
|
1940
|
-
const next = exists ? value.filter((item) => item !== sev) : [...value, sev];
|
|
1941
|
-
onChange(next);
|
|
1942
|
-
};
|
|
1943
|
-
return /* @__PURE__ */ jsx16("div", { className: `stn-status-severity-filter-group ${className}`.trim(), role: "group", "aria-label": "\uC2EC\uAC01\uB3C4 \uD544\uD130", children: ALL_SEVERITIES.map((sev) => {
|
|
1944
|
-
const isActive = value.includes(sev);
|
|
1945
|
-
const isDisabled = disabledSeverities.includes(sev);
|
|
1946
|
-
return /* @__PURE__ */ jsx16(
|
|
1947
|
-
StnStatusSeverity,
|
|
1948
|
-
{
|
|
1949
|
-
severity: sev,
|
|
1950
|
-
variant: "filter",
|
|
1951
|
-
showIcon,
|
|
1952
|
-
active: isActive,
|
|
1953
|
-
disabled: isDisabled,
|
|
1954
|
-
onClick: () => !isDisabled && handleToggle(sev)
|
|
1955
|
-
},
|
|
1956
|
-
sev
|
|
1957
|
-
);
|
|
1958
|
-
}) });
|
|
1959
|
-
}
|
|
1960
|
-
StnStatusSeverityFilter.displayName = "StnStatusSeverityFilter";
|
|
1961
|
-
var StnSeverityBadge = StnStatusSeverity;
|
|
1962
|
-
var StnSeverityFilter = StnStatusSeverityFilter;
|
|
1963
1934
|
function StnStatus(props) {
|
|
1964
1935
|
switch (props.type) {
|
|
1965
1936
|
case "dot-group": {
|
|
@@ -1974,10 +1945,6 @@ function StnStatus(props) {
|
|
|
1974
1945
|
const { type: _, ...rest } = props;
|
|
1975
1946
|
return /* @__PURE__ */ jsx16(StnStatusSeverity, { ...rest });
|
|
1976
1947
|
}
|
|
1977
|
-
case "severity-filter": {
|
|
1978
|
-
const { type: _, ...rest } = props;
|
|
1979
|
-
return /* @__PURE__ */ jsx16(StnStatusSeverityFilter, { ...rest });
|
|
1980
|
-
}
|
|
1981
1948
|
case "flow": {
|
|
1982
1949
|
const { type: _, ...rest } = props;
|
|
1983
1950
|
return /* @__PURE__ */ jsx16(StnStatusFlow, { ...rest });
|
|
@@ -1992,7 +1959,6 @@ function StnStatus(props) {
|
|
|
1992
1959
|
StnStatus.Dot = StnStatusDot;
|
|
1993
1960
|
StnStatus.DotGroup = StnStatusDotGroup;
|
|
1994
1961
|
StnStatus.Severity = StnStatusSeverity;
|
|
1995
|
-
StnStatus.SeverityFilter = StnStatusSeverityFilter;
|
|
1996
1962
|
StnStatus.Switch = StnStatusSwitch;
|
|
1997
1963
|
StnStatus.Flow = StnStatusFlow;
|
|
1998
1964
|
|
|
@@ -2519,7 +2485,7 @@ function TreeNodeIcon({
|
|
|
2519
2485
|
icon
|
|
2520
2486
|
}) {
|
|
2521
2487
|
if (icon != null) {
|
|
2522
|
-
return /* @__PURE__ */ jsx18("span", { className: "stn-tree__cell stn-tree__cell--icon stn-tree__icon stn-tree__icon--custom", children: typeof icon === "string" ? /* @__PURE__ */ jsx18(StnIcon, { name: icon,
|
|
2488
|
+
return /* @__PURE__ */ jsx18("span", { className: "stn-tree__cell stn-tree__cell--icon stn-tree__icon stn-tree__icon--custom", children: typeof icon === "string" ? /* @__PURE__ */ jsx18(StnIcon, { name: icon, className: "stn-tree__icon-glyph" }) : icon });
|
|
2523
2489
|
}
|
|
2524
2490
|
if (kind === "server") {
|
|
2525
2491
|
return /* @__PURE__ */ jsxs12("span", { className: "stn-tree__cell stn-tree__cell--icon stn-tree__icon stn-tree__icon--server", children: [
|
|
@@ -2527,7 +2493,6 @@ function TreeNodeIcon({
|
|
|
2527
2493
|
StnIcon,
|
|
2528
2494
|
{
|
|
2529
2495
|
name: "fill/server_2_tree_light",
|
|
2530
|
-
size: 16,
|
|
2531
2496
|
className: "stn-tree__icon-glyph stn-tree__server-icon stn-tree__server-icon--light stn-icon--color"
|
|
2532
2497
|
}
|
|
2533
2498
|
),
|
|
@@ -2535,7 +2500,6 @@ function TreeNodeIcon({
|
|
|
2535
2500
|
StnIcon,
|
|
2536
2501
|
{
|
|
2537
2502
|
name: "fill/server_2",
|
|
2538
|
-
size: 16,
|
|
2539
2503
|
className: "stn-tree__icon-glyph stn-tree__server-icon stn-tree__server-icon--dark stn-icon--color"
|
|
2540
2504
|
}
|
|
2541
2505
|
)
|
|
@@ -3167,7 +3131,7 @@ var StnBadge = React.forwardRef(
|
|
|
3167
3131
|
displayContent = `${max}+`;
|
|
3168
3132
|
}
|
|
3169
3133
|
const positionClass = `${anchorOrigin.vertical}-${anchorOrigin.horizontal}`;
|
|
3170
|
-
const
|
|
3134
|
+
const colorClass3 = color;
|
|
3171
3135
|
const appearanceClass = appearance;
|
|
3172
3136
|
const isStandalone = !children;
|
|
3173
3137
|
const customBadgeStyle = {
|
|
@@ -3184,7 +3148,7 @@ var StnBadge = React.forwardRef(
|
|
|
3184
3148
|
"stn-badge",
|
|
3185
3149
|
isDot ? "dot" : "standard",
|
|
3186
3150
|
appearanceClass,
|
|
3187
|
-
|
|
3151
|
+
colorClass3,
|
|
3188
3152
|
!isStandalone && positionClass,
|
|
3189
3153
|
isStandalone && "standalone",
|
|
3190
3154
|
invisible && "is-invisible",
|
|
@@ -3240,6 +3204,7 @@ function StnChip(props) {
|
|
|
3240
3204
|
children,
|
|
3241
3205
|
grade,
|
|
3242
3206
|
accent,
|
|
3207
|
+
dashed = false,
|
|
3243
3208
|
onClick,
|
|
3244
3209
|
onKeyDown,
|
|
3245
3210
|
role: roleProp,
|
|
@@ -3250,7 +3215,7 @@ function StnChip(props) {
|
|
|
3250
3215
|
const resolvedShape = rawShape === "rounded" || rawShape === "square" ? "square" : rawShape;
|
|
3251
3216
|
const isOutline = variant === "outline" || variant === "outlined" || variant === "border";
|
|
3252
3217
|
const isSubtle = bgOpacity === 50 || bgOpacity === "50" || bgOpacity === "50%" || bgOpacity === 0.5 || variant === "subtle" || variant === "soft" || variant === "tinted" || variant === "contained-50" || variant === "filled-50";
|
|
3253
|
-
const
|
|
3218
|
+
const variantClass7 = isOutline ? "outline" : isSubtle ? "subtle contained-50 bg-50" : "filled";
|
|
3254
3219
|
const resolvedColor = color ?? grade;
|
|
3255
3220
|
let content = children ?? label;
|
|
3256
3221
|
if (!content && grade && STN_GRADE_SOURCE[grade]) {
|
|
@@ -3307,10 +3272,11 @@ function StnChip(props) {
|
|
|
3307
3272
|
tabIndex,
|
|
3308
3273
|
className: cn(
|
|
3309
3274
|
"stn-chip",
|
|
3310
|
-
|
|
3275
|
+
variantClass7,
|
|
3311
3276
|
size,
|
|
3312
3277
|
resolvedShape,
|
|
3313
3278
|
resolvedColor,
|
|
3279
|
+
dashed && "dashed",
|
|
3314
3280
|
isClickable && "clickable",
|
|
3315
3281
|
onDelete && "deletable",
|
|
3316
3282
|
accent && `stn-chip--accent-${accent}`,
|
|
@@ -4128,17 +4094,170 @@ var StnTextField = forwardRef23(function StnTextField2({
|
|
|
4128
4094
|
);
|
|
4129
4095
|
});
|
|
4130
4096
|
|
|
4131
|
-
// src/components/
|
|
4132
|
-
import { forwardRef as forwardRef24, useId as useId11 } from "react";
|
|
4097
|
+
// src/components/StnTextArea.tsx
|
|
4133
4098
|
import {
|
|
4134
|
-
|
|
4135
|
-
|
|
4099
|
+
forwardRef as forwardRef24,
|
|
4100
|
+
useId as useId11,
|
|
4101
|
+
useState as useState10
|
|
4102
|
+
} from "react";
|
|
4136
4103
|
import { jsx as jsx35, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
4104
|
+
function normalizeSize2(size) {
|
|
4105
|
+
return size ?? "md";
|
|
4106
|
+
}
|
|
4107
|
+
function variantClass3(variant) {
|
|
4108
|
+
if (variant === "filled") return "filled";
|
|
4109
|
+
if (variant === "standard") return "standard";
|
|
4110
|
+
if (variant === "transparent") return "transparent";
|
|
4111
|
+
return "outlined";
|
|
4112
|
+
}
|
|
4113
|
+
function colorClass2(color) {
|
|
4114
|
+
if (!color || color === "primary" || color === "secondary") return void 0;
|
|
4115
|
+
return color;
|
|
4116
|
+
}
|
|
4117
|
+
function resizeClass(resize) {
|
|
4118
|
+
if (resize === "none") return "resize-none";
|
|
4119
|
+
if (resize === "horizontal") return "resize-horizontal";
|
|
4120
|
+
if (resize === "both") return "resize-both";
|
|
4121
|
+
return "resize-vertical";
|
|
4122
|
+
}
|
|
4137
4123
|
function resolveGlyph3(node) {
|
|
4138
4124
|
if (typeof node === "string") return /* @__PURE__ */ jsx35(StnIcon, { name: node, size: 16, color: "currentColor" });
|
|
4139
4125
|
return node;
|
|
4140
4126
|
}
|
|
4141
|
-
function
|
|
4127
|
+
var StnTextArea = forwardRef24(function StnTextArea2({
|
|
4128
|
+
size = "md",
|
|
4129
|
+
variant = "outlined",
|
|
4130
|
+
color,
|
|
4131
|
+
invalid,
|
|
4132
|
+
fullWidth,
|
|
4133
|
+
width,
|
|
4134
|
+
label,
|
|
4135
|
+
labelIcon,
|
|
4136
|
+
labelPosition = "top",
|
|
4137
|
+
required,
|
|
4138
|
+
helperText,
|
|
4139
|
+
showCount = false,
|
|
4140
|
+
resize = "vertical",
|
|
4141
|
+
rows = 3,
|
|
4142
|
+
maxLength,
|
|
4143
|
+
className,
|
|
4144
|
+
disabled,
|
|
4145
|
+
id: idProp,
|
|
4146
|
+
value,
|
|
4147
|
+
defaultValue,
|
|
4148
|
+
onChange,
|
|
4149
|
+
"aria-invalid": ariaInvalid,
|
|
4150
|
+
"aria-describedby": ariaDescribedBy,
|
|
4151
|
+
...rest
|
|
4152
|
+
}, ref) {
|
|
4153
|
+
const autoId = useId11();
|
|
4154
|
+
const id = idProp ?? autoId;
|
|
4155
|
+
const isControlled = value !== void 0;
|
|
4156
|
+
const [uncontrolledLength, setUncontrolledLength] = useState10(() => {
|
|
4157
|
+
if (defaultValue != null) return String(defaultValue).length;
|
|
4158
|
+
return 0;
|
|
4159
|
+
});
|
|
4160
|
+
const currentLength = isControlled ? String(value ?? "").length : uncontrolledLength;
|
|
4161
|
+
const handleTextChange = (e) => {
|
|
4162
|
+
if (!isControlled) {
|
|
4163
|
+
setUncontrolledLength(e.target.value.length);
|
|
4164
|
+
}
|
|
4165
|
+
onChange?.(e);
|
|
4166
|
+
};
|
|
4167
|
+
const hasLabel = label != null && label !== "";
|
|
4168
|
+
const hasHelper = helperText != null && helperText !== "";
|
|
4169
|
+
const hasFooter = hasHelper || showCount;
|
|
4170
|
+
const hasWrap = hasLabel || hasFooter;
|
|
4171
|
+
const helperId = hasHelper ? `${id}-helper` : void 0;
|
|
4172
|
+
const describedBy = [ariaDescribedBy, helperId].filter(Boolean).join(" ") || void 0;
|
|
4173
|
+
const widthProps = resolveInputWidthProps("stn-text-area", fullWidth, width);
|
|
4174
|
+
const textAreaClass = cn(
|
|
4175
|
+
"stn-text-area",
|
|
4176
|
+
variantClass3(variant),
|
|
4177
|
+
normalizeSize2(size),
|
|
4178
|
+
colorClass2(color),
|
|
4179
|
+
resizeClass(resize),
|
|
4180
|
+
!hasWrap && widthProps.className,
|
|
4181
|
+
invalid && "invalid",
|
|
4182
|
+
className
|
|
4183
|
+
);
|
|
4184
|
+
const textareaElement = /* @__PURE__ */ jsx35(
|
|
4185
|
+
"textarea",
|
|
4186
|
+
{
|
|
4187
|
+
ref,
|
|
4188
|
+
id,
|
|
4189
|
+
rows,
|
|
4190
|
+
disabled,
|
|
4191
|
+
required,
|
|
4192
|
+
maxLength,
|
|
4193
|
+
value,
|
|
4194
|
+
defaultValue,
|
|
4195
|
+
onChange: handleTextChange,
|
|
4196
|
+
"aria-invalid": invalid ? true : ariaInvalid,
|
|
4197
|
+
"aria-describedby": describedBy,
|
|
4198
|
+
className: textAreaClass,
|
|
4199
|
+
style: hasWrap ? void 0 : widthProps.style,
|
|
4200
|
+
...rest
|
|
4201
|
+
}
|
|
4202
|
+
);
|
|
4203
|
+
if (!hasWrap) {
|
|
4204
|
+
return textareaElement;
|
|
4205
|
+
}
|
|
4206
|
+
const labelElement = hasLabel ? /* @__PURE__ */ jsxs27("label", { htmlFor: id, className: "stn-text-area__label", children: [
|
|
4207
|
+
labelIcon ? /* @__PURE__ */ jsx35("span", { className: "stn-text-area__label-icon", "aria-hidden": "true", children: resolveGlyph3(labelIcon) }) : null,
|
|
4208
|
+
/* @__PURE__ */ jsx35("span", { className: "stn-text-area__label-text", children: label }),
|
|
4209
|
+
required && /* @__PURE__ */ jsx35("span", { className: "stn-text-area__required", "aria-hidden": "true", children: "*" })
|
|
4210
|
+
] }) : null;
|
|
4211
|
+
const isRow = labelPosition === "left" || labelPosition === "right";
|
|
4212
|
+
return /* @__PURE__ */ jsxs27(
|
|
4213
|
+
"div",
|
|
4214
|
+
{
|
|
4215
|
+
className: cn(
|
|
4216
|
+
"stn-text-area-wrap",
|
|
4217
|
+
isRow ? "stn-text-area-wrap--row" : "stn-text-area-wrap--col",
|
|
4218
|
+
hasLabel && labelPosition === "left" && "stn-text-area-wrap--label-left",
|
|
4219
|
+
hasLabel && labelPosition === "right" && "stn-text-area-wrap--label-right",
|
|
4220
|
+
hasLabel && labelPosition === "top" && "stn-text-area-wrap--label-top",
|
|
4221
|
+
widthProps.className
|
|
4222
|
+
),
|
|
4223
|
+
style: widthProps.style,
|
|
4224
|
+
children: [
|
|
4225
|
+
hasLabel && (labelPosition === "left" || labelPosition === "top") ? labelElement : null,
|
|
4226
|
+
/* @__PURE__ */ jsxs27("div", { className: "stn-text-area-wrap__body", children: [
|
|
4227
|
+
textareaElement,
|
|
4228
|
+
hasFooter && /* @__PURE__ */ jsxs27("div", { className: "stn-text-area__footer", children: [
|
|
4229
|
+
hasHelper ? /* @__PURE__ */ jsx35(
|
|
4230
|
+
"p",
|
|
4231
|
+
{
|
|
4232
|
+
id: helperId,
|
|
4233
|
+
className: cn("stn-text-area__helper", invalid && "stn-text-area__helper--error"),
|
|
4234
|
+
children: helperText
|
|
4235
|
+
}
|
|
4236
|
+
) : /* @__PURE__ */ jsx35("span", {}),
|
|
4237
|
+
showCount && /* @__PURE__ */ jsxs27("span", { className: "stn-text-area__count", children: [
|
|
4238
|
+
currentLength,
|
|
4239
|
+
maxLength != null ? ` / ${maxLength}` : ""
|
|
4240
|
+
] })
|
|
4241
|
+
] })
|
|
4242
|
+
] }),
|
|
4243
|
+
hasLabel && labelPosition === "right" ? labelElement : null
|
|
4244
|
+
]
|
|
4245
|
+
}
|
|
4246
|
+
);
|
|
4247
|
+
});
|
|
4248
|
+
StnTextArea.displayName = "StnTextArea";
|
|
4249
|
+
|
|
4250
|
+
// src/components/StnDateRangeField.tsx
|
|
4251
|
+
import { forwardRef as forwardRef25, useId as useId12 } from "react";
|
|
4252
|
+
import {
|
|
4253
|
+
formatStnDateRangeFieldValue
|
|
4254
|
+
} from "@stn-uiux/pub-ui/data/stnDateRangeField";
|
|
4255
|
+
import { jsx as jsx36, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
4256
|
+
function resolveGlyph4(node) {
|
|
4257
|
+
if (typeof node === "string") return /* @__PURE__ */ jsx36(StnIcon, { name: node, size: 16, color: "currentColor" });
|
|
4258
|
+
return node;
|
|
4259
|
+
}
|
|
4260
|
+
function normalizeSize3(size) {
|
|
4142
4261
|
if (!size) return "md";
|
|
4143
4262
|
const s = String(size).toLowerCase();
|
|
4144
4263
|
if (s === "s" || s === "sm") return "sm";
|
|
@@ -4147,9 +4266,9 @@ function normalizeSize2(size) {
|
|
|
4147
4266
|
return "md";
|
|
4148
4267
|
}
|
|
4149
4268
|
function sizeClass3(size) {
|
|
4150
|
-
return
|
|
4269
|
+
return normalizeSize3(size);
|
|
4151
4270
|
}
|
|
4152
|
-
function
|
|
4271
|
+
function variantClass4(variant = "outline") {
|
|
4153
4272
|
if (variant === "transparent") return "transparent";
|
|
4154
4273
|
return "";
|
|
4155
4274
|
}
|
|
@@ -4159,7 +4278,7 @@ function resolveValue(value, format) {
|
|
|
4159
4278
|
const trimmed = value.trim();
|
|
4160
4279
|
return trimmed || null;
|
|
4161
4280
|
}
|
|
4162
|
-
var StnDateRangeField =
|
|
4281
|
+
var StnDateRangeField = forwardRef25(function StnDateRangeField2({
|
|
4163
4282
|
size = "md",
|
|
4164
4283
|
variant = "outline",
|
|
4165
4284
|
start,
|
|
@@ -4184,7 +4303,7 @@ var StnDateRangeField = forwardRef24(function StnDateRangeField2({
|
|
|
4184
4303
|
"aria-invalid": ariaInvalid,
|
|
4185
4304
|
...rest
|
|
4186
4305
|
}, ref) {
|
|
4187
|
-
const autoId =
|
|
4306
|
+
const autoId = useId12();
|
|
4188
4307
|
const rootId = idProp ?? `stn-date-range-${autoId.replace(/:/g, "")}`;
|
|
4189
4308
|
const startText = resolveValue(start, format);
|
|
4190
4309
|
const endText = resolveValue(end, format);
|
|
@@ -4193,7 +4312,7 @@ var StnDateRangeField = forwardRef24(function StnDateRangeField2({
|
|
|
4193
4312
|
const hasLabel = label != null && label !== "";
|
|
4194
4313
|
const hasHelper = helperText != null && helperText !== "";
|
|
4195
4314
|
const hasWrap = hasLabel || hasHelper;
|
|
4196
|
-
const buttonNode = /* @__PURE__ */
|
|
4315
|
+
const buttonNode = /* @__PURE__ */ jsx36(
|
|
4197
4316
|
"button",
|
|
4198
4317
|
{
|
|
4199
4318
|
ref,
|
|
@@ -4204,7 +4323,7 @@ var StnDateRangeField = forwardRef24(function StnDateRangeField2({
|
|
|
4204
4323
|
className: cn(
|
|
4205
4324
|
"stn-date-range-field",
|
|
4206
4325
|
sizeClass3(size),
|
|
4207
|
-
|
|
4326
|
+
variantClass4(variant),
|
|
4208
4327
|
!hasWrap && widthProps.className,
|
|
4209
4328
|
fullWidth && "stn-date-range-field--full w100p",
|
|
4210
4329
|
invalid && "stn-date-range-field--invalid",
|
|
@@ -4213,25 +4332,25 @@ var StnDateRangeField = forwardRef24(function StnDateRangeField2({
|
|
|
4213
4332
|
),
|
|
4214
4333
|
style: !hasWrap ? widthProps.style ?? style : void 0,
|
|
4215
4334
|
...rest,
|
|
4216
|
-
children: /* @__PURE__ */
|
|
4217
|
-
/* @__PURE__ */
|
|
4218
|
-
/* @__PURE__ */
|
|
4219
|
-
/* @__PURE__ */
|
|
4220
|
-
/* @__PURE__ */
|
|
4335
|
+
children: /* @__PURE__ */ jsxs28("span", { className: "stn-date-range-field__inner", children: [
|
|
4336
|
+
/* @__PURE__ */ jsxs28("span", { className: "stn-date-range-field__text", children: [
|
|
4337
|
+
/* @__PURE__ */ jsx36("span", { className: cn("stn-date-range-field__value", !startText && "is-placeholder"), children: startText ?? startPlaceholder }),
|
|
4338
|
+
/* @__PURE__ */ jsx36("span", { className: "stn-date-range-field__sep", "aria-hidden": "true", children: "~" }),
|
|
4339
|
+
/* @__PURE__ */ jsx36("span", { className: cn("stn-date-range-field__value", !endText && "is-placeholder"), children: endText ?? endPlaceholder })
|
|
4221
4340
|
] }),
|
|
4222
|
-
/* @__PURE__ */
|
|
4341
|
+
/* @__PURE__ */ jsx36("span", { className: "stn-date-range-field__icon", "aria-hidden": "true" })
|
|
4223
4342
|
] })
|
|
4224
4343
|
}
|
|
4225
4344
|
);
|
|
4226
4345
|
if (!hasWrap) return buttonNode;
|
|
4227
4346
|
const resolvedLabelIcon = labelIcon ?? icon;
|
|
4228
|
-
const labelElement = hasLabel ? /* @__PURE__ */
|
|
4229
|
-
resolvedLabelIcon ? /* @__PURE__ */
|
|
4230
|
-
/* @__PURE__ */
|
|
4231
|
-
required && /* @__PURE__ */
|
|
4347
|
+
const labelElement = hasLabel ? /* @__PURE__ */ jsxs28("label", { htmlFor: rootId, className: "stn-date-range-field__label", children: [
|
|
4348
|
+
resolvedLabelIcon ? /* @__PURE__ */ jsx36("span", { className: "stn-date-range-field__label-icon", "aria-hidden": "true", children: resolveGlyph4(resolvedLabelIcon) }) : null,
|
|
4349
|
+
/* @__PURE__ */ jsx36("span", { className: "stn-date-range-field__label-text", children: label }),
|
|
4350
|
+
required && /* @__PURE__ */ jsx36("span", { className: "stn-date-range-field__required", "aria-hidden": "true", children: "*" })
|
|
4232
4351
|
] }) : null;
|
|
4233
4352
|
const isRow = labelPosition === "left" || labelPosition === "right";
|
|
4234
|
-
return /* @__PURE__ */
|
|
4353
|
+
return /* @__PURE__ */ jsxs28(
|
|
4235
4354
|
"div",
|
|
4236
4355
|
{
|
|
4237
4356
|
className: cn(
|
|
@@ -4247,9 +4366,9 @@ var StnDateRangeField = forwardRef24(function StnDateRangeField2({
|
|
|
4247
4366
|
style: widthProps.style ?? style,
|
|
4248
4367
|
children: [
|
|
4249
4368
|
hasLabel && (labelPosition === "left" || labelPosition === "top") ? labelElement : null,
|
|
4250
|
-
/* @__PURE__ */
|
|
4369
|
+
/* @__PURE__ */ jsxs28("div", { className: "stn-date-range-field-wrap__body", children: [
|
|
4251
4370
|
buttonNode,
|
|
4252
|
-
hasHelper && /* @__PURE__ */
|
|
4371
|
+
hasHelper && /* @__PURE__ */ jsx36(
|
|
4253
4372
|
"span",
|
|
4254
4373
|
{
|
|
4255
4374
|
id: `${rootId}-helper`,
|
|
@@ -4269,16 +4388,16 @@ var StnDateRangeField = forwardRef24(function StnDateRangeField2({
|
|
|
4269
4388
|
|
|
4270
4389
|
// src/components/StnLabelPrefix.tsx
|
|
4271
4390
|
import {
|
|
4272
|
-
useId as
|
|
4273
|
-
useState as
|
|
4391
|
+
useId as useId13,
|
|
4392
|
+
useState as useState11,
|
|
4274
4393
|
isValidElement as isValidElement4,
|
|
4275
4394
|
cloneElement as cloneElement4
|
|
4276
4395
|
} from "react";
|
|
4277
|
-
import { jsx as
|
|
4396
|
+
import { jsx as jsx37, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
4278
4397
|
function sizeClass4(size) {
|
|
4279
4398
|
return size;
|
|
4280
4399
|
}
|
|
4281
|
-
function
|
|
4400
|
+
function variantClass5(variant) {
|
|
4282
4401
|
return variant;
|
|
4283
4402
|
}
|
|
4284
4403
|
function StnLabelPrefix({
|
|
@@ -4309,12 +4428,12 @@ function StnLabelPrefix({
|
|
|
4309
4428
|
id: idProp,
|
|
4310
4429
|
...rest
|
|
4311
4430
|
}) {
|
|
4312
|
-
const autoId =
|
|
4431
|
+
const autoId = useId13();
|
|
4313
4432
|
const id = idProp ?? autoId;
|
|
4314
4433
|
const isError = error || invalid || color === "error";
|
|
4315
4434
|
const hasHelper = helperText != null && helperText !== "";
|
|
4316
4435
|
const helperId = hasHelper ? `${id}-helper` : void 0;
|
|
4317
|
-
const [internalChecked, setInternalChecked] =
|
|
4436
|
+
const [internalChecked, setInternalChecked] = useState11(defaultChecked ?? false);
|
|
4318
4437
|
const isChecked = checked !== void 0 ? checked : internalChecked;
|
|
4319
4438
|
const handleCheckboxChange = (nextChecked) => {
|
|
4320
4439
|
if (checked === void 0) {
|
|
@@ -4327,7 +4446,7 @@ function StnLabelPrefix({
|
|
|
4327
4446
|
const rootClass = cn(
|
|
4328
4447
|
"stn-label-prefix",
|
|
4329
4448
|
sizeClass4(size),
|
|
4330
|
-
|
|
4449
|
+
variantClass5(variant),
|
|
4331
4450
|
color && color !== "error" && color,
|
|
4332
4451
|
labelPosition === "suffix" && "stn-label-prefix--suffix",
|
|
4333
4452
|
radius && `radius-${radius}`,
|
|
@@ -4339,7 +4458,7 @@ function StnLabelPrefix({
|
|
|
4339
4458
|
);
|
|
4340
4459
|
const defaultCheckboxSize = size === "lg" ? "md" : "sm";
|
|
4341
4460
|
const resolvedCheckboxSize = checkboxSize ?? defaultCheckboxSize;
|
|
4342
|
-
const checkboxNode = checkboxSlot ?? (checkbox ? /* @__PURE__ */
|
|
4461
|
+
const checkboxNode = checkboxSlot ?? (checkbox ? /* @__PURE__ */ jsx37("span", { className: "stn-label-prefix__checkbox", children: /* @__PURE__ */ jsx37(
|
|
4343
4462
|
StnCheckbox,
|
|
4344
4463
|
{
|
|
4345
4464
|
size: resolvedCheckboxSize,
|
|
@@ -4350,14 +4469,14 @@ function StnLabelPrefix({
|
|
|
4350
4469
|
"aria-label": typeof label === "string" ? `${label} \uC120\uD0DD` : void 0
|
|
4351
4470
|
}
|
|
4352
4471
|
) }) : null);
|
|
4353
|
-
const labelSection = /* @__PURE__ */
|
|
4472
|
+
const labelSection = /* @__PURE__ */ jsxs29("span", { className: "stn-label-prefix__label", children: [
|
|
4354
4473
|
checkboxNode,
|
|
4355
|
-
labelIcon != null && /* @__PURE__ */
|
|
4356
|
-
/* @__PURE__ */
|
|
4474
|
+
labelIcon != null && /* @__PURE__ */ jsx37("span", { className: "stn-label-prefix__icon", "aria-hidden": "true", children: labelIcon }),
|
|
4475
|
+
/* @__PURE__ */ jsxs29("span", { className: "stn-label-prefix__text", children: [
|
|
4357
4476
|
label,
|
|
4358
|
-
required && /* @__PURE__ */
|
|
4477
|
+
required && /* @__PURE__ */ jsx37("span", { className: "stn-label-prefix__required", "aria-hidden": "true", children: "*" })
|
|
4359
4478
|
] }),
|
|
4360
|
-
/* @__PURE__ */
|
|
4479
|
+
/* @__PURE__ */ jsx37("span", { className: "stn-label-prefix__divider", "aria-hidden": "true" })
|
|
4361
4480
|
] });
|
|
4362
4481
|
let renderedControl = children;
|
|
4363
4482
|
if (isControlDisabled && isValidElement4(children) && typeof children.type !== "string") {
|
|
@@ -4365,7 +4484,7 @@ function StnLabelPrefix({
|
|
|
4365
4484
|
disabled: true
|
|
4366
4485
|
});
|
|
4367
4486
|
}
|
|
4368
|
-
const prefixNode = /* @__PURE__ */
|
|
4487
|
+
const prefixNode = /* @__PURE__ */ jsxs29(
|
|
4369
4488
|
"div",
|
|
4370
4489
|
{
|
|
4371
4490
|
id: !hasHelper ? id : void 0,
|
|
@@ -4377,14 +4496,14 @@ function StnLabelPrefix({
|
|
|
4377
4496
|
...!hasHelper ? rest : {},
|
|
4378
4497
|
children: [
|
|
4379
4498
|
labelSection,
|
|
4380
|
-
/* @__PURE__ */
|
|
4499
|
+
/* @__PURE__ */ jsx37("span", { className: "stn-label-prefix__control", children: renderedControl })
|
|
4381
4500
|
]
|
|
4382
4501
|
}
|
|
4383
4502
|
);
|
|
4384
4503
|
if (!hasHelper) {
|
|
4385
4504
|
return prefixNode;
|
|
4386
4505
|
}
|
|
4387
|
-
return /* @__PURE__ */
|
|
4506
|
+
return /* @__PURE__ */ jsxs29(
|
|
4388
4507
|
"div",
|
|
4389
4508
|
{
|
|
4390
4509
|
id,
|
|
@@ -4398,7 +4517,7 @@ function StnLabelPrefix({
|
|
|
4398
4517
|
...rest,
|
|
4399
4518
|
children: [
|
|
4400
4519
|
prefixNode,
|
|
4401
|
-
/* @__PURE__ */
|
|
4520
|
+
/* @__PURE__ */ jsx37(
|
|
4402
4521
|
"p",
|
|
4403
4522
|
{
|
|
4404
4523
|
id: helperId,
|
|
@@ -4464,14 +4583,14 @@ import {
|
|
|
4464
4583
|
} from "@stn-uiux/pub-ui/data/stnSearchRequirement";
|
|
4465
4584
|
|
|
4466
4585
|
// src/patterns/search/StnSearchRequirementBar.tsx
|
|
4467
|
-
import { jsx as
|
|
4586
|
+
import { jsx as jsx38, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
4468
4587
|
function StnSearchRequirementBar({
|
|
4469
4588
|
children,
|
|
4470
4589
|
className,
|
|
4471
4590
|
density = "default",
|
|
4472
4591
|
...rest
|
|
4473
4592
|
}) {
|
|
4474
|
-
return /* @__PURE__ */
|
|
4593
|
+
return /* @__PURE__ */ jsx38(
|
|
4475
4594
|
"div",
|
|
4476
4595
|
{
|
|
4477
4596
|
className: cn(
|
|
@@ -4487,7 +4606,7 @@ function StnSearchRequirementBar({
|
|
|
4487
4606
|
);
|
|
4488
4607
|
}
|
|
4489
4608
|
function StnSearchRequirementBarFields({ children, className, ...rest }) {
|
|
4490
|
-
return /* @__PURE__ */
|
|
4609
|
+
return /* @__PURE__ */ jsx38("div", { className: cn("stn-search-requirement__fields", className), "data-stn-search-requirement": "fields", ...rest, children });
|
|
4491
4610
|
}
|
|
4492
4611
|
function StnSearchRequirementBarField({
|
|
4493
4612
|
label,
|
|
@@ -4497,20 +4616,20 @@ function StnSearchRequirementBarField({
|
|
|
4497
4616
|
controlClassName,
|
|
4498
4617
|
...rest
|
|
4499
4618
|
}) {
|
|
4500
|
-
return /* @__PURE__ */
|
|
4501
|
-
/* @__PURE__ */
|
|
4502
|
-
/* @__PURE__ */
|
|
4619
|
+
return /* @__PURE__ */ jsxs30("div", { className: cn("stn-search-requirement__field", className), "data-stn-search-requirement": "field", ...rest, children: [
|
|
4620
|
+
/* @__PURE__ */ jsx38("span", { className: cn("stn-search-requirement__label", labelClassName), children: label }),
|
|
4621
|
+
/* @__PURE__ */ jsx38("div", { className: cn("stn-search-requirement__control", controlClassName), children })
|
|
4503
4622
|
] });
|
|
4504
4623
|
}
|
|
4505
4624
|
function StnSearchRequirementBarSearchButton({
|
|
4506
4625
|
children = "\uAC80\uC0C9",
|
|
4507
4626
|
size = "md",
|
|
4508
4627
|
variant = "outlined",
|
|
4509
|
-
icon = /* @__PURE__ */
|
|
4628
|
+
icon = /* @__PURE__ */ jsx38(StnIcon, { name: "line/search", size: 16, color: "currentColor" }),
|
|
4510
4629
|
className,
|
|
4511
4630
|
...rest
|
|
4512
4631
|
}) {
|
|
4513
|
-
return /* @__PURE__ */
|
|
4632
|
+
return /* @__PURE__ */ jsx38(
|
|
4514
4633
|
StnButton,
|
|
4515
4634
|
{
|
|
4516
4635
|
size,
|
|
@@ -4532,10 +4651,10 @@ function StnSearchRequirementBarExport({
|
|
|
4532
4651
|
"aria-label": ariaLabel = "Excel\uBCF4\uB0B4\uAE30",
|
|
4533
4652
|
...rest
|
|
4534
4653
|
}) {
|
|
4535
|
-
return /* @__PURE__ */
|
|
4654
|
+
return /* @__PURE__ */ jsx38(
|
|
4536
4655
|
StnButton,
|
|
4537
4656
|
{
|
|
4538
|
-
icon: icon ?? /* @__PURE__ */
|
|
4657
|
+
icon: icon ?? /* @__PURE__ */ jsx38(StnIcon, { name, size: 24, color: "currentColor" }),
|
|
4539
4658
|
variant,
|
|
4540
4659
|
size,
|
|
4541
4660
|
"aria-label": ariaLabel,
|
|
@@ -4546,7 +4665,7 @@ function StnSearchRequirementBarExport({
|
|
|
4546
4665
|
);
|
|
4547
4666
|
}
|
|
4548
4667
|
function StnSearchRequirementBarDivider({ className, ...rest }) {
|
|
4549
|
-
return /* @__PURE__ */
|
|
4668
|
+
return /* @__PURE__ */ jsx38(
|
|
4550
4669
|
"span",
|
|
4551
4670
|
{
|
|
4552
4671
|
className: cn("stn-search-requirement__divider", className),
|
|
@@ -4572,13 +4691,13 @@ import {
|
|
|
4572
4691
|
useEffect as useEffect9,
|
|
4573
4692
|
useLayoutEffect,
|
|
4574
4693
|
useRef as useRef6,
|
|
4575
|
-
useState as
|
|
4694
|
+
useState as useState13
|
|
4576
4695
|
} from "react";
|
|
4577
4696
|
import { createPortal as createPortal2 } from "react-dom";
|
|
4578
4697
|
import { formatStnDateRangeFieldValue as formatStnDateRangeFieldValue2 } from "@stn-uiux/pub-ui/data/stnDateRangeField";
|
|
4579
4698
|
|
|
4580
4699
|
// src/components/datePicker/StnDateRangePicker.tsx
|
|
4581
|
-
import { useCallback as useCallback6, useEffect as useEffect8, useId as
|
|
4700
|
+
import { useCallback as useCallback6, useEffect as useEffect8, useId as useId14, useMemo as useMemo3, useState as useState12 } from "react";
|
|
4582
4701
|
import {
|
|
4583
4702
|
STN_DATE_PICKER_WEEKDAYS
|
|
4584
4703
|
} from "@stn-uiux/pub-ui/data/stnDatePicker";
|
|
@@ -4638,9 +4757,9 @@ function normalizeRange(start, end) {
|
|
|
4638
4757
|
}
|
|
4639
4758
|
|
|
4640
4759
|
// src/components/datePicker/StnDateRangePicker.tsx
|
|
4641
|
-
import { jsx as
|
|
4760
|
+
import { jsx as jsx39, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
4642
4761
|
function useDraftRange(value, open) {
|
|
4643
|
-
const [draft, setDraft] =
|
|
4762
|
+
const [draft, setDraft] = useState12(value);
|
|
4644
4763
|
useEffect8(() => {
|
|
4645
4764
|
if (open) setDraft(value);
|
|
4646
4765
|
}, [open, value]);
|
|
@@ -4649,19 +4768,19 @@ function useDraftRange(value, open) {
|
|
|
4649
4768
|
function CalendarPanel({ month, range, onPick, onPrev, onNext, showPrev = true, showNext = true }) {
|
|
4650
4769
|
const days = useMemo3(() => buildMonthGrid(month), [month]);
|
|
4651
4770
|
const { start, end } = range;
|
|
4652
|
-
return /* @__PURE__ */
|
|
4653
|
-
/* @__PURE__ */
|
|
4654
|
-
showPrev ? /* @__PURE__ */
|
|
4655
|
-
/* @__PURE__ */
|
|
4656
|
-
showNext ? /* @__PURE__ */
|
|
4771
|
+
return /* @__PURE__ */ jsxs31("div", { className: "stn-date-picker-panel", children: [
|
|
4772
|
+
/* @__PURE__ */ jsxs31("div", { className: "stn-date-picker-panel__header", children: [
|
|
4773
|
+
showPrev ? /* @__PURE__ */ jsx39("button", { type: "button", className: "stn-date-picker-panel__nav", onClick: onPrev, "aria-label": "Previous month", children: "\u2039" }) : /* @__PURE__ */ jsx39("span", { className: "stn-date-picker-panel__nav", "aria-hidden": "true" }),
|
|
4774
|
+
/* @__PURE__ */ jsx39("p", { className: "stn-date-picker-panel__title", children: formatMonthTitle(month) }),
|
|
4775
|
+
showNext ? /* @__PURE__ */ jsx39("button", { type: "button", className: "stn-date-picker-panel__nav", onClick: onNext, "aria-label": "Next month", children: "\u203A" }) : /* @__PURE__ */ jsx39("span", { className: "stn-date-picker-panel__nav", "aria-hidden": "true" })
|
|
4657
4776
|
] }),
|
|
4658
|
-
/* @__PURE__ */
|
|
4659
|
-
/* @__PURE__ */
|
|
4660
|
-
/* @__PURE__ */
|
|
4777
|
+
/* @__PURE__ */ jsxs31("table", { className: "stn-date-picker-content", children: [
|
|
4778
|
+
/* @__PURE__ */ jsx39("thead", { children: /* @__PURE__ */ jsx39("tr", { children: STN_DATE_PICKER_WEEKDAYS.map((label) => /* @__PURE__ */ jsx39("th", { scope: "col", children: label }, label)) }) }),
|
|
4779
|
+
/* @__PURE__ */ jsx39("tbody", { children: Array.from({ length: 6 }, (_, row) => /* @__PURE__ */ jsx39("tr", { children: days.slice(row * 7, row * 7 + 7).map((cell) => {
|
|
4661
4780
|
const inRange = start && end && isBetweenDays(cell.date, start, end);
|
|
4662
4781
|
const isStart = start ? isSameDay(cell.date, start) : false;
|
|
4663
4782
|
const isEnd = end ? isSameDay(cell.date, end) : false;
|
|
4664
|
-
return /* @__PURE__ */
|
|
4783
|
+
return /* @__PURE__ */ jsx39(
|
|
4665
4784
|
"td",
|
|
4666
4785
|
{
|
|
4667
4786
|
className: cn(
|
|
@@ -4671,7 +4790,7 @@ function CalendarPanel({ month, range, onPick, onPrev, onNext, showPrev = true,
|
|
|
4671
4790
|
isStart && "stn-date-picker-cell--range-start",
|
|
4672
4791
|
isEnd && "stn-date-picker-cell--range-end"
|
|
4673
4792
|
),
|
|
4674
|
-
children: /* @__PURE__ */
|
|
4793
|
+
children: /* @__PURE__ */ jsx39(
|
|
4675
4794
|
"button",
|
|
4676
4795
|
{
|
|
4677
4796
|
type: "button",
|
|
@@ -4693,16 +4812,16 @@ function TimeColumns({ label, value, onChange }) {
|
|
|
4693
4812
|
const seconds = value?.getSeconds() ?? 0;
|
|
4694
4813
|
const base = value ?? /* @__PURE__ */ new Date();
|
|
4695
4814
|
const patch = (h, m, s) => onChange(setTimePart(base, h, m, s));
|
|
4696
|
-
return /* @__PURE__ */
|
|
4697
|
-
/* @__PURE__ */
|
|
4698
|
-
/* @__PURE__ */
|
|
4699
|
-
/* @__PURE__ */
|
|
4815
|
+
return /* @__PURE__ */ jsxs31("div", { className: "stn-date-picker-time__side", children: [
|
|
4816
|
+
/* @__PURE__ */ jsx39("span", { className: "stn-date-picker-time__label", children: label }),
|
|
4817
|
+
/* @__PURE__ */ jsxs31("div", { className: "stn-date-picker-time__columns", children: [
|
|
4818
|
+
/* @__PURE__ */ jsx39(
|
|
4700
4819
|
StnScroll,
|
|
4701
4820
|
{
|
|
4702
4821
|
variant: "arrows",
|
|
4703
4822
|
size: "thin",
|
|
4704
4823
|
className: "stn-date-picker-time__scroll",
|
|
4705
|
-
children: /* @__PURE__ */
|
|
4824
|
+
children: /* @__PURE__ */ jsx39("ul", { className: "stn-date-picker-time__column", "aria-label": `${label} hour`, children: Array.from({ length: 24 }, (_, h) => /* @__PURE__ */ jsx39("li", { children: /* @__PURE__ */ jsx39(
|
|
4706
4825
|
"button",
|
|
4707
4826
|
{
|
|
4708
4827
|
type: "button",
|
|
@@ -4713,13 +4832,13 @@ function TimeColumns({ label, value, onChange }) {
|
|
|
4713
4832
|
) }, h)) })
|
|
4714
4833
|
}
|
|
4715
4834
|
),
|
|
4716
|
-
/* @__PURE__ */
|
|
4835
|
+
/* @__PURE__ */ jsx39(
|
|
4717
4836
|
StnScroll,
|
|
4718
4837
|
{
|
|
4719
4838
|
variant: "arrows",
|
|
4720
4839
|
size: "thin",
|
|
4721
4840
|
className: "stn-date-picker-time__scroll",
|
|
4722
|
-
children: /* @__PURE__ */
|
|
4841
|
+
children: /* @__PURE__ */ jsx39("ul", { className: "stn-date-picker-time__column", "aria-label": `${label} minute`, children: Array.from({ length: 60 }, (_, m) => /* @__PURE__ */ jsx39("li", { children: /* @__PURE__ */ jsx39(
|
|
4723
4842
|
"button",
|
|
4724
4843
|
{
|
|
4725
4844
|
type: "button",
|
|
@@ -4730,13 +4849,13 @@ function TimeColumns({ label, value, onChange }) {
|
|
|
4730
4849
|
) }, m)) })
|
|
4731
4850
|
}
|
|
4732
4851
|
),
|
|
4733
|
-
/* @__PURE__ */
|
|
4852
|
+
/* @__PURE__ */ jsx39(
|
|
4734
4853
|
StnScroll,
|
|
4735
4854
|
{
|
|
4736
4855
|
variant: "arrows",
|
|
4737
4856
|
size: "thin",
|
|
4738
4857
|
className: "stn-date-picker-time__scroll",
|
|
4739
|
-
children: /* @__PURE__ */
|
|
4858
|
+
children: /* @__PURE__ */ jsx39("ul", { className: "stn-date-picker-time__column", "aria-label": `${label} second`, children: Array.from({ length: 60 }, (_, s) => /* @__PURE__ */ jsx39("li", { children: /* @__PURE__ */ jsx39(
|
|
4740
4859
|
"button",
|
|
4741
4860
|
{
|
|
4742
4861
|
type: "button",
|
|
@@ -4761,9 +4880,9 @@ function StnDateRangePicker({
|
|
|
4761
4880
|
style,
|
|
4762
4881
|
anchorRect
|
|
4763
4882
|
}) {
|
|
4764
|
-
const titleId =
|
|
4883
|
+
const titleId = useId14();
|
|
4765
4884
|
const [draft, setDraft] = useDraftRange(value, open);
|
|
4766
|
-
const [leftMonth, setLeftMonth] =
|
|
4885
|
+
const [leftMonth, setLeftMonth] = useState12(() => startOfMonth(draft.start ?? draft.end ?? /* @__PURE__ */ new Date()));
|
|
4767
4886
|
useEffect8(() => {
|
|
4768
4887
|
if (!open) return;
|
|
4769
4888
|
const anchor = draft.start ?? draft.end ?? /* @__PURE__ */ new Date();
|
|
@@ -4815,7 +4934,7 @@ function StnDateRangePicker({
|
|
|
4815
4934
|
left: anchorRect.left,
|
|
4816
4935
|
...style
|
|
4817
4936
|
} : style ?? {};
|
|
4818
|
-
return /* @__PURE__ */
|
|
4937
|
+
return /* @__PURE__ */ jsx39(
|
|
4819
4938
|
"div",
|
|
4820
4939
|
{
|
|
4821
4940
|
className: cn("stn-date-picker-dropdown", className),
|
|
@@ -4823,10 +4942,10 @@ function StnDateRangePicker({
|
|
|
4823
4942
|
role: "dialog",
|
|
4824
4943
|
"aria-modal": "false",
|
|
4825
4944
|
"aria-labelledby": titleId,
|
|
4826
|
-
children: /* @__PURE__ */
|
|
4827
|
-
/* @__PURE__ */
|
|
4828
|
-
/* @__PURE__ */
|
|
4829
|
-
/* @__PURE__ */
|
|
4945
|
+
children: /* @__PURE__ */ jsxs31("div", { className: "stn-date-picker-dropdown__body", children: [
|
|
4946
|
+
/* @__PURE__ */ jsx39("span", { id: titleId, className: "stn-sf__visually-hidden", children: "Date range picker" }),
|
|
4947
|
+
/* @__PURE__ */ jsxs31("div", { className: "stn-date-picker-dropdown__panels", children: [
|
|
4948
|
+
/* @__PURE__ */ jsx39(
|
|
4830
4949
|
CalendarPanel,
|
|
4831
4950
|
{
|
|
4832
4951
|
month: leftMonth,
|
|
@@ -4837,7 +4956,7 @@ function StnDateRangePicker({
|
|
|
4837
4956
|
showNext: false
|
|
4838
4957
|
}
|
|
4839
4958
|
),
|
|
4840
|
-
/* @__PURE__ */
|
|
4959
|
+
/* @__PURE__ */ jsx39(
|
|
4841
4960
|
CalendarPanel,
|
|
4842
4961
|
{
|
|
4843
4962
|
month: rightMonth,
|
|
@@ -4849,8 +4968,8 @@ function StnDateRangePicker({
|
|
|
4849
4968
|
}
|
|
4850
4969
|
)
|
|
4851
4970
|
] }),
|
|
4852
|
-
showTime ? /* @__PURE__ */
|
|
4853
|
-
/* @__PURE__ */
|
|
4971
|
+
showTime ? /* @__PURE__ */ jsxs31("div", { className: "stn-date-picker-time", children: [
|
|
4972
|
+
/* @__PURE__ */ jsx39(
|
|
4854
4973
|
TimeColumns,
|
|
4855
4974
|
{
|
|
4856
4975
|
label: "\uC2DC\uC791",
|
|
@@ -4858,7 +4977,7 @@ function StnDateRangePicker({
|
|
|
4858
4977
|
onChange: (start) => updateDraft({ ...draft, start })
|
|
4859
4978
|
}
|
|
4860
4979
|
),
|
|
4861
|
-
/* @__PURE__ */
|
|
4980
|
+
/* @__PURE__ */ jsx39(
|
|
4862
4981
|
TimeColumns,
|
|
4863
4982
|
{
|
|
4864
4983
|
label: "\uC885\uB8CC",
|
|
@@ -4867,16 +4986,16 @@ function StnDateRangePicker({
|
|
|
4867
4986
|
}
|
|
4868
4987
|
)
|
|
4869
4988
|
] }) : null,
|
|
4870
|
-
/* @__PURE__ */
|
|
4989
|
+
/* @__PURE__ */ jsx39("div", { className: "stn-date-picker-footer", children: /* @__PURE__ */ jsx39(StnButton, { size: "md", variant: "contained", onClick: handleApply, disabled: !draft.start || !draft.end, children: "\uD655\uC778" }) })
|
|
4871
4990
|
] })
|
|
4872
4991
|
}
|
|
4873
4992
|
);
|
|
4874
4993
|
}
|
|
4875
4994
|
|
|
4876
4995
|
// src/components/datePicker/StnDateRangePickerField.tsx
|
|
4877
|
-
import { jsx as
|
|
4996
|
+
import { jsx as jsx40, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
4878
4997
|
function useControllableRange(controlled, defaultValue, onChange) {
|
|
4879
|
-
const [internal, setInternal] =
|
|
4998
|
+
const [internal, setInternal] = useState13(defaultValue);
|
|
4880
4999
|
const value = controlled ?? internal;
|
|
4881
5000
|
const setValue = useCallback7(
|
|
4882
5001
|
(next) => {
|
|
@@ -4908,8 +5027,8 @@ function StnDateRangePickerField({
|
|
|
4908
5027
|
}) {
|
|
4909
5028
|
const format = formatProp ?? (showTime ? formatStnDateRangeFieldValue2 : formatDateOnly);
|
|
4910
5029
|
const [value, setValue] = useControllableRange(valueProp, defaultValue, onChange);
|
|
4911
|
-
const [open, setOpen] =
|
|
4912
|
-
const [anchorRect, setAnchorRect] =
|
|
5030
|
+
const [open, setOpen] = useState13(false);
|
|
5031
|
+
const [anchorRect, setAnchorRect] = useState13(null);
|
|
4913
5032
|
const rootRef = useRef6(null);
|
|
4914
5033
|
const triggerRef = useRef6(null);
|
|
4915
5034
|
const panelRef = useRef6(null);
|
|
@@ -4946,8 +5065,8 @@ function StnDateRangePickerField({
|
|
|
4946
5065
|
document.addEventListener("keydown", onKeyDown);
|
|
4947
5066
|
return () => document.removeEventListener("keydown", onKeyDown);
|
|
4948
5067
|
}, [open]);
|
|
4949
|
-
return /* @__PURE__ */
|
|
4950
|
-
/* @__PURE__ */
|
|
5068
|
+
return /* @__PURE__ */ jsxs32("div", { ref: rootRef, className: cn("stn-date-picker-field", className), children: [
|
|
5069
|
+
/* @__PURE__ */ jsx40(
|
|
4951
5070
|
StnDateRangeField,
|
|
4952
5071
|
{
|
|
4953
5072
|
ref: triggerRef,
|
|
@@ -4967,7 +5086,7 @@ function StnDateRangePickerField({
|
|
|
4967
5086
|
}
|
|
4968
5087
|
),
|
|
4969
5088
|
open && typeof document !== "undefined" ? createPortal2(
|
|
4970
|
-
/* @__PURE__ */
|
|
5089
|
+
/* @__PURE__ */ jsx40("div", { ref: panelRef, children: /* @__PURE__ */ jsx40(
|
|
4971
5090
|
StnDateRangePicker,
|
|
4972
5091
|
{
|
|
4973
5092
|
open: true,
|
|
@@ -4986,13 +5105,13 @@ function StnDateRangePickerField({
|
|
|
4986
5105
|
}
|
|
4987
5106
|
|
|
4988
5107
|
// src/patterns/search/StnSearchRequirementBarDemo.tsx
|
|
4989
|
-
import { jsx as
|
|
5108
|
+
import { jsx as jsx41, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
4990
5109
|
var ALL_OPTIONS = [{ value: "", label: "\uC804\uCCB4" }];
|
|
4991
5110
|
function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
4992
5111
|
const demo = STN_SEARCH_REQUIREMENT_DEMO_FIELDS;
|
|
4993
|
-
return /* @__PURE__ */
|
|
4994
|
-
/* @__PURE__ */
|
|
4995
|
-
/* @__PURE__ */
|
|
5112
|
+
return /* @__PURE__ */ jsxs33(StnSearchRequirementBar, { className, children: [
|
|
5113
|
+
/* @__PURE__ */ jsxs33(StnSearchRequirementBar.Fields, { children: [
|
|
5114
|
+
/* @__PURE__ */ jsx41(
|
|
4996
5115
|
StnTextField,
|
|
4997
5116
|
{
|
|
4998
5117
|
label: demo.reportTypeText.label,
|
|
@@ -5002,7 +5121,7 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5002
5121
|
"aria-label": demo.reportTypeText.label
|
|
5003
5122
|
}
|
|
5004
5123
|
),
|
|
5005
|
-
/* @__PURE__ */
|
|
5124
|
+
/* @__PURE__ */ jsx41(
|
|
5006
5125
|
StnDropdown,
|
|
5007
5126
|
{
|
|
5008
5127
|
label: demo.reportTypeSelect.label,
|
|
@@ -5013,7 +5132,7 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5013
5132
|
"aria-label": demo.reportTypeSelect.label
|
|
5014
5133
|
}
|
|
5015
5134
|
),
|
|
5016
|
-
/* @__PURE__ */
|
|
5135
|
+
/* @__PURE__ */ jsx41(
|
|
5017
5136
|
StnDropdown,
|
|
5018
5137
|
{
|
|
5019
5138
|
label: demo.periodType.label,
|
|
@@ -5024,7 +5143,7 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5024
5143
|
"aria-label": demo.periodType.label
|
|
5025
5144
|
}
|
|
5026
5145
|
),
|
|
5027
|
-
/* @__PURE__ */
|
|
5146
|
+
/* @__PURE__ */ jsx41(
|
|
5028
5147
|
StnDateRangePickerField,
|
|
5029
5148
|
{
|
|
5030
5149
|
label: demo.period.label,
|
|
@@ -5038,8 +5157,8 @@ function StnSearchRequirementBarDemo({ onSearch, onExport, className }) {
|
|
|
5038
5157
|
}
|
|
5039
5158
|
)
|
|
5040
5159
|
] }),
|
|
5041
|
-
/* @__PURE__ */
|
|
5042
|
-
/* @__PURE__ */
|
|
5160
|
+
/* @__PURE__ */ jsx41(StnSearchRequirementBar.SearchButton, { onClick: onSearch }),
|
|
5161
|
+
/* @__PURE__ */ jsx41(StnSearchRequirementBar.Export, { onClick: onExport })
|
|
5043
5162
|
] });
|
|
5044
5163
|
}
|
|
5045
5164
|
|
|
@@ -5053,8 +5172,8 @@ import {
|
|
|
5053
5172
|
} from "@stn-uiux/pub-ui/data/stnHeader";
|
|
5054
5173
|
|
|
5055
5174
|
// src/patterns/header/StnHeader.tsx
|
|
5056
|
-
import { jsx as
|
|
5057
|
-
function
|
|
5175
|
+
import { jsx as jsx42 } from "react/jsx-runtime";
|
|
5176
|
+
function variantClass6(variant) {
|
|
5058
5177
|
if (variant === "page") return "stn-header--page";
|
|
5059
5178
|
return void 0;
|
|
5060
5179
|
}
|
|
@@ -5080,12 +5199,12 @@ function StnHeader({
|
|
|
5080
5199
|
...dynamicStyles,
|
|
5081
5200
|
...style
|
|
5082
5201
|
};
|
|
5083
|
-
return /* @__PURE__ */
|
|
5202
|
+
return /* @__PURE__ */ jsx42(
|
|
5084
5203
|
"header",
|
|
5085
5204
|
{
|
|
5086
5205
|
className: cn(
|
|
5087
5206
|
"stn-header",
|
|
5088
|
-
|
|
5207
|
+
variantClass6(variant),
|
|
5089
5208
|
isNamedPadding ? `padding-${padding}` : void 0,
|
|
5090
5209
|
isNamedGap ? `gap-${gap}` : void 0,
|
|
5091
5210
|
className
|
|
@@ -5098,20 +5217,20 @@ function StnHeader({
|
|
|
5098
5217
|
);
|
|
5099
5218
|
}
|
|
5100
5219
|
function StnHeaderLeft({ children, className, ...rest }) {
|
|
5101
|
-
return /* @__PURE__ */
|
|
5220
|
+
return /* @__PURE__ */ jsx42("div", { className: cn("stn-header__left", className), "data-stn-header-region": "left", ...rest, children });
|
|
5102
5221
|
}
|
|
5103
5222
|
function StnHeaderCenter({ children, className, ...rest }) {
|
|
5104
|
-
return /* @__PURE__ */
|
|
5223
|
+
return /* @__PURE__ */ jsx42("div", { className: cn("stn-header__center", className), "data-stn-header-region": "center", ...rest, children });
|
|
5105
5224
|
}
|
|
5106
5225
|
function StnHeaderRight({ children, className, ...rest }) {
|
|
5107
|
-
return /* @__PURE__ */
|
|
5226
|
+
return /* @__PURE__ */ jsx42("div", { className: cn("stn-header__right", className), "data-stn-header-region": "right", ...rest, children });
|
|
5108
5227
|
}
|
|
5109
5228
|
StnHeader.Left = StnHeaderLeft;
|
|
5110
5229
|
StnHeader.Center = StnHeaderCenter;
|
|
5111
5230
|
StnHeader.Right = StnHeaderRight;
|
|
5112
5231
|
function StnHeaderPageTitle({ children, className, title, ...rest }) {
|
|
5113
5232
|
const autoTitle = typeof children === "string" ? children : void 0;
|
|
5114
|
-
return /* @__PURE__ */
|
|
5233
|
+
return /* @__PURE__ */ jsx42(
|
|
5115
5234
|
"h1",
|
|
5116
5235
|
{
|
|
5117
5236
|
className: cn("stn-header__page-title", className),
|
|
@@ -5123,7 +5242,7 @@ function StnHeaderPageTitle({ children, className, title, ...rest }) {
|
|
|
5123
5242
|
}
|
|
5124
5243
|
function StnHeaderSubTitle({ children, className, title, ...rest }) {
|
|
5125
5244
|
const autoTitle = typeof children === "string" ? children : void 0;
|
|
5126
|
-
return /* @__PURE__ */
|
|
5245
|
+
return /* @__PURE__ */ jsx42(
|
|
5127
5246
|
"span",
|
|
5128
5247
|
{
|
|
5129
5248
|
className: cn("stn-header__subtitle", className),
|
|
@@ -5135,7 +5254,7 @@ function StnHeaderSubTitle({ children, className, title, ...rest }) {
|
|
|
5135
5254
|
}
|
|
5136
5255
|
function StnHeaderContextTitle({ children, className, title, ...rest }) {
|
|
5137
5256
|
const autoTitle = typeof children === "string" ? children : void 0;
|
|
5138
|
-
return /* @__PURE__ */
|
|
5257
|
+
return /* @__PURE__ */ jsx42(
|
|
5139
5258
|
"span",
|
|
5140
5259
|
{
|
|
5141
5260
|
className: cn("stn-header__context-title", className),
|
|
@@ -5146,7 +5265,7 @@ function StnHeaderContextTitle({ children, className, title, ...rest }) {
|
|
|
5146
5265
|
);
|
|
5147
5266
|
}
|
|
5148
5267
|
function StnHeaderToolbar({ children, className, ...rest }) {
|
|
5149
|
-
return /* @__PURE__ */
|
|
5268
|
+
return /* @__PURE__ */ jsx42("div", { className: cn("stn-header-toolbar", className), "data-stn-header-toolbar": true, ...rest, children });
|
|
5150
5269
|
}
|
|
5151
5270
|
|
|
5152
5271
|
// src/index.ts
|
|
@@ -5164,7 +5283,7 @@ import {
|
|
|
5164
5283
|
STN_LAYER0_BACKGROUND_DEMO_IMAGES,
|
|
5165
5284
|
STN_LAYER0_MAP_LIGHT_OVERLAY
|
|
5166
5285
|
} from "@stn-uiux/pub-ui/data/stnLayer0Background";
|
|
5167
|
-
import { jsx as
|
|
5286
|
+
import { jsx as jsx43, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
5168
5287
|
function overlayStyle(overlay) {
|
|
5169
5288
|
if (overlay == null || overlay <= 0) return void 0;
|
|
5170
5289
|
const pct = `${Math.min(100, Math.max(0, overlay * 100))}%`;
|
|
@@ -5213,15 +5332,15 @@ function StnLayer0Background({
|
|
|
5213
5332
|
const isImage = kind === "image" || Boolean(src || srcDark);
|
|
5214
5333
|
if (isImage) {
|
|
5215
5334
|
const paired = Boolean(src && srcDark);
|
|
5216
|
-
return /* @__PURE__ */
|
|
5335
|
+
return /* @__PURE__ */ jsx43(
|
|
5217
5336
|
"div",
|
|
5218
5337
|
{
|
|
5219
5338
|
className: cn("stn-layer0-bg", "image", className),
|
|
5220
5339
|
"aria-hidden": alt === "" ? true : void 0,
|
|
5221
5340
|
style: { ...overlayStyle(overlay), ...style },
|
|
5222
5341
|
...rest,
|
|
5223
|
-
children: /* @__PURE__ */
|
|
5224
|
-
src ? /* @__PURE__ */
|
|
5342
|
+
children: /* @__PURE__ */ jsxs34("div", { className: "stn-layer0-bg__media", children: [
|
|
5343
|
+
src ? /* @__PURE__ */ jsx43(
|
|
5225
5344
|
"img",
|
|
5226
5345
|
{
|
|
5227
5346
|
className: cn("stn-layer0-bg__img", paired && "light"),
|
|
@@ -5230,7 +5349,7 @@ function StnLayer0Background({
|
|
|
5230
5349
|
decoding: "async"
|
|
5231
5350
|
}
|
|
5232
5351
|
) : null,
|
|
5233
|
-
srcDark ? /* @__PURE__ */
|
|
5352
|
+
srcDark ? /* @__PURE__ */ jsx43(
|
|
5234
5353
|
"img",
|
|
5235
5354
|
{
|
|
5236
5355
|
className: cn("stn-layer0-bg__img", paired ? "dark" : void 0),
|
|
@@ -5239,13 +5358,13 @@ function StnLayer0Background({
|
|
|
5239
5358
|
decoding: "async"
|
|
5240
5359
|
}
|
|
5241
5360
|
) : null,
|
|
5242
|
-
overlay != null && overlay > 0 ? /* @__PURE__ */
|
|
5243
|
-
overlayDarkRadial ? /* @__PURE__ */
|
|
5361
|
+
overlay != null && overlay > 0 ? /* @__PURE__ */ jsx43("div", { className: "stn-layer0-bg__overlay", "aria-hidden": "true" }) : null,
|
|
5362
|
+
overlayDarkRadial ? /* @__PURE__ */ jsx43("div", { className: "stn-layer0-bg__overlay radial", "aria-hidden": "true" }) : null
|
|
5244
5363
|
] })
|
|
5245
5364
|
}
|
|
5246
5365
|
);
|
|
5247
5366
|
}
|
|
5248
|
-
return /* @__PURE__ */
|
|
5367
|
+
return /* @__PURE__ */ jsx43(
|
|
5249
5368
|
"div",
|
|
5250
5369
|
{
|
|
5251
5370
|
className: cn("stn-layer0-bg", "color", color, className),
|
|
@@ -5282,7 +5401,7 @@ import {
|
|
|
5282
5401
|
|
|
5283
5402
|
// src/components/StnEventBanner.tsx
|
|
5284
5403
|
import React2 from "react";
|
|
5285
|
-
import { jsx as
|
|
5404
|
+
import { jsx as jsx44, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
5286
5405
|
var SEVERITY_ICONS2 = {
|
|
5287
5406
|
critical: "fill/alert4",
|
|
5288
5407
|
major: "fill/alert3",
|
|
@@ -5290,7 +5409,7 @@ var SEVERITY_ICONS2 = {
|
|
|
5290
5409
|
warning: "fill/alert1"
|
|
5291
5410
|
};
|
|
5292
5411
|
function DefaultTriangleIcon() {
|
|
5293
|
-
return /* @__PURE__ */
|
|
5412
|
+
return /* @__PURE__ */ jsxs35(
|
|
5294
5413
|
"svg",
|
|
5295
5414
|
{
|
|
5296
5415
|
width: "20",
|
|
@@ -5300,7 +5419,7 @@ function DefaultTriangleIcon() {
|
|
|
5300
5419
|
xmlns: "http://www.w3.org/2000/svg",
|
|
5301
5420
|
"aria-hidden": "true",
|
|
5302
5421
|
children: [
|
|
5303
|
-
/* @__PURE__ */
|
|
5422
|
+
/* @__PURE__ */ jsx44(
|
|
5304
5423
|
"path",
|
|
5305
5424
|
{
|
|
5306
5425
|
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",
|
|
@@ -5310,17 +5429,17 @@ function DefaultTriangleIcon() {
|
|
|
5310
5429
|
strokeLinejoin: "round"
|
|
5311
5430
|
}
|
|
5312
5431
|
),
|
|
5313
|
-
/* @__PURE__ */
|
|
5314
|
-
/* @__PURE__ */
|
|
5432
|
+
/* @__PURE__ */ jsx44("line", { x1: "12", y1: "9", x2: "12", y2: "13", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }),
|
|
5433
|
+
/* @__PURE__ */ jsx44("circle", { cx: "12", cy: "17", r: "1", fill: "currentColor" })
|
|
5315
5434
|
]
|
|
5316
5435
|
}
|
|
5317
5436
|
);
|
|
5318
5437
|
}
|
|
5319
5438
|
function resolveDefaultIcon(severity) {
|
|
5320
5439
|
if (severity === "critical") {
|
|
5321
|
-
return /* @__PURE__ */
|
|
5440
|
+
return /* @__PURE__ */ jsx44(DefaultTriangleIcon, {});
|
|
5322
5441
|
}
|
|
5323
|
-
return /* @__PURE__ */
|
|
5442
|
+
return /* @__PURE__ */ jsx44(StnIcon, { name: SEVERITY_ICONS2[severity] || "fill/alert4", size: 20 });
|
|
5324
5443
|
}
|
|
5325
5444
|
var StnEventBanner = React2.forwardRef(
|
|
5326
5445
|
({
|
|
@@ -5339,7 +5458,7 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5339
5458
|
id,
|
|
5340
5459
|
...restProps
|
|
5341
5460
|
}, ref) => {
|
|
5342
|
-
return /* @__PURE__ */
|
|
5461
|
+
return /* @__PURE__ */ jsxs35(
|
|
5343
5462
|
"div",
|
|
5344
5463
|
{
|
|
5345
5464
|
ref,
|
|
@@ -5356,16 +5475,16 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5356
5475
|
),
|
|
5357
5476
|
...restProps,
|
|
5358
5477
|
children: [
|
|
5359
|
-
/* @__PURE__ */
|
|
5360
|
-
/* @__PURE__ */
|
|
5361
|
-
/* @__PURE__ */
|
|
5362
|
-
title && /* @__PURE__ */
|
|
5363
|
-
time && /* @__PURE__ */
|
|
5478
|
+
/* @__PURE__ */ jsxs35("div", { className: "stn-event-banner__left", children: [
|
|
5479
|
+
/* @__PURE__ */ jsx44("div", { className: "stn-event-banner__icon-wrap", children: icon ?? resolveDefaultIcon(severity) }),
|
|
5480
|
+
/* @__PURE__ */ jsxs35("div", { className: "stn-event-banner__text", children: [
|
|
5481
|
+
title && /* @__PURE__ */ jsx44("span", { className: "stn-event-banner__title", title: typeof title === "string" ? title : void 0, children: title }),
|
|
5482
|
+
time && /* @__PURE__ */ jsx44("span", { className: "stn-event-banner__time", title: typeof time === "string" ? time : void 0, children: time })
|
|
5364
5483
|
] })
|
|
5365
5484
|
] }),
|
|
5366
|
-
/* @__PURE__ */
|
|
5485
|
+
/* @__PURE__ */ jsxs35("div", { className: "stn-event-banner__actions", children: [
|
|
5367
5486
|
actions,
|
|
5368
|
-
actionText && /* @__PURE__ */
|
|
5487
|
+
actionText && /* @__PURE__ */ jsx44(
|
|
5369
5488
|
"button",
|
|
5370
5489
|
{
|
|
5371
5490
|
type: "button",
|
|
@@ -5374,7 +5493,7 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5374
5493
|
children: actionText
|
|
5375
5494
|
}
|
|
5376
5495
|
),
|
|
5377
|
-
onClose && /* @__PURE__ */
|
|
5496
|
+
onClose && /* @__PURE__ */ jsx44(
|
|
5378
5497
|
"button",
|
|
5379
5498
|
{
|
|
5380
5499
|
type: "button",
|
|
@@ -5393,9 +5512,9 @@ var StnEventBanner = React2.forwardRef(
|
|
|
5393
5512
|
StnEventBanner.displayName = "StnEventBanner";
|
|
5394
5513
|
|
|
5395
5514
|
// src/patterns/scaffold/StnLoadingSkeleton.tsx
|
|
5396
|
-
import { jsx as
|
|
5515
|
+
import { jsx as jsx45, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
5397
5516
|
function StnLoadingSkeletonLine({ width = "full", className, style, ...rest }) {
|
|
5398
|
-
return /* @__PURE__ */
|
|
5517
|
+
return /* @__PURE__ */ jsx45(
|
|
5399
5518
|
"div",
|
|
5400
5519
|
{
|
|
5401
5520
|
className: cn(
|
|
@@ -5411,7 +5530,7 @@ function StnLoadingSkeletonLine({ width = "full", className, style, ...rest }) {
|
|
|
5411
5530
|
);
|
|
5412
5531
|
}
|
|
5413
5532
|
function StnLoadingSkeletonBlock({ minHeight = 48, className, style, ...rest }) {
|
|
5414
|
-
return /* @__PURE__ */
|
|
5533
|
+
return /* @__PURE__ */ jsx45(
|
|
5415
5534
|
"div",
|
|
5416
5535
|
{
|
|
5417
5536
|
className: cn("stn-loading-skeleton__block", className),
|
|
@@ -5422,7 +5541,7 @@ function StnLoadingSkeletonBlock({ minHeight = 48, className, style, ...rest })
|
|
|
5422
5541
|
);
|
|
5423
5542
|
}
|
|
5424
5543
|
function StnLoadingSkeletonCircle({ size = 40, className, style, ...rest }) {
|
|
5425
|
-
return /* @__PURE__ */
|
|
5544
|
+
return /* @__PURE__ */ jsx45(
|
|
5426
5545
|
"div",
|
|
5427
5546
|
{
|
|
5428
5547
|
className: cn("stn-loading-skeleton__circle", className),
|
|
@@ -5433,7 +5552,7 @@ function StnLoadingSkeletonCircle({ size = 40, className, style, ...rest }) {
|
|
|
5433
5552
|
);
|
|
5434
5553
|
}
|
|
5435
5554
|
function StnLoadingSkeletonProfile({ avatarSize = 40, className, style, ...rest }) {
|
|
5436
|
-
return /* @__PURE__ */
|
|
5555
|
+
return /* @__PURE__ */ jsxs36(
|
|
5437
5556
|
"div",
|
|
5438
5557
|
{
|
|
5439
5558
|
className: cn("stn-loading-skeleton--profile", className),
|
|
@@ -5442,17 +5561,17 @@ function StnLoadingSkeletonProfile({ avatarSize = 40, className, style, ...rest
|
|
|
5442
5561
|
"aria-label": "\uD504\uB85C\uD544 \uB85C\uB529 \uC911",
|
|
5443
5562
|
...rest,
|
|
5444
5563
|
children: [
|
|
5445
|
-
/* @__PURE__ */
|
|
5446
|
-
/* @__PURE__ */
|
|
5447
|
-
/* @__PURE__ */
|
|
5448
|
-
/* @__PURE__ */
|
|
5564
|
+
/* @__PURE__ */ jsx45(StnLoadingSkeletonCircle, { size: avatarSize }),
|
|
5565
|
+
/* @__PURE__ */ jsxs36("div", { className: "stn-loading-skeleton__profile-content", children: [
|
|
5566
|
+
/* @__PURE__ */ jsx45(StnLoadingSkeletonLine, { width: "medium" }),
|
|
5567
|
+
/* @__PURE__ */ jsx45(StnLoadingSkeletonLine, { width: "short" })
|
|
5449
5568
|
] })
|
|
5450
5569
|
]
|
|
5451
5570
|
}
|
|
5452
5571
|
);
|
|
5453
5572
|
}
|
|
5454
5573
|
function StnLoadingSkeletonWidget({ lines = 4, className, style, ...rest }) {
|
|
5455
|
-
return /* @__PURE__ */
|
|
5574
|
+
return /* @__PURE__ */ jsx45(
|
|
5456
5575
|
"div",
|
|
5457
5576
|
{
|
|
5458
5577
|
className: cn("stn-loading-skeleton", "stn-loading-skeleton--widget", className),
|
|
@@ -5460,12 +5579,12 @@ function StnLoadingSkeletonWidget({ lines = 4, className, style, ...rest }) {
|
|
|
5460
5579
|
"aria-busy": "true",
|
|
5461
5580
|
"aria-label": "\uB85C\uB529 \uC911",
|
|
5462
5581
|
...rest,
|
|
5463
|
-
children: Array.from({ length: lines }, (_, i) => /* @__PURE__ */
|
|
5582
|
+
children: Array.from({ length: lines }, (_, i) => /* @__PURE__ */ jsx45(StnLoadingSkeletonLine, { width: i % 3 === 0 ? "short" : i % 2 === 0 ? "medium" : "full" }, i))
|
|
5464
5583
|
}
|
|
5465
5584
|
);
|
|
5466
5585
|
}
|
|
5467
5586
|
function StnLoadingSkeletonTable({ rows = 5, cols = 4, className, style, ...rest }) {
|
|
5468
|
-
return /* @__PURE__ */
|
|
5587
|
+
return /* @__PURE__ */ jsx45(
|
|
5469
5588
|
"div",
|
|
5470
5589
|
{
|
|
5471
5590
|
className: cn("stn-loading-skeleton", "stn-loading-skeleton--table", className),
|
|
@@ -5473,7 +5592,7 @@ function StnLoadingSkeletonTable({ rows = 5, cols = 4, className, style, ...rest
|
|
|
5473
5592
|
"aria-busy": "true",
|
|
5474
5593
|
"aria-label": "\uD14C\uC774\uBE14 \uB85C\uB529 \uC911",
|
|
5475
5594
|
...rest,
|
|
5476
|
-
children: Array.from({ length: rows }, (_, row) => /* @__PURE__ */
|
|
5595
|
+
children: Array.from({ length: rows }, (_, row) => /* @__PURE__ */ jsx45("div", { className: "stn-loading-skeleton__table-row", children: Array.from({ length: cols }, (_2, col) => /* @__PURE__ */ jsx45(StnLoadingSkeletonLine, {}, col)) }, row))
|
|
5477
5596
|
}
|
|
5478
5597
|
);
|
|
5479
5598
|
}
|
|
@@ -5492,23 +5611,23 @@ function StnLoadingSkeletonRoot({
|
|
|
5492
5611
|
...rest
|
|
5493
5612
|
}) {
|
|
5494
5613
|
if (children != null) {
|
|
5495
|
-
return /* @__PURE__ */
|
|
5614
|
+
return /* @__PURE__ */ jsx45("div", { className: cn("stn-loading-skeleton", className), style, "aria-busy": "true", ...rest, children });
|
|
5496
5615
|
}
|
|
5497
5616
|
const resolvedVariant = variant ?? "line";
|
|
5498
5617
|
switch (resolvedVariant) {
|
|
5499
5618
|
case "circle":
|
|
5500
|
-
return /* @__PURE__ */
|
|
5619
|
+
return /* @__PURE__ */ jsx45(StnLoadingSkeletonCircle, { size, className, style, ...rest });
|
|
5501
5620
|
case "block":
|
|
5502
|
-
return /* @__PURE__ */
|
|
5621
|
+
return /* @__PURE__ */ jsx45(StnLoadingSkeletonBlock, { minHeight, className, style, ...rest });
|
|
5503
5622
|
case "profile":
|
|
5504
|
-
return /* @__PURE__ */
|
|
5623
|
+
return /* @__PURE__ */ jsx45(StnLoadingSkeletonProfile, { avatarSize: avatarSize ?? size, className, style, ...rest });
|
|
5505
5624
|
case "widget":
|
|
5506
|
-
return /* @__PURE__ */
|
|
5625
|
+
return /* @__PURE__ */ jsx45(StnLoadingSkeletonWidget, { lines, className, style, ...rest });
|
|
5507
5626
|
case "table":
|
|
5508
|
-
return /* @__PURE__ */
|
|
5627
|
+
return /* @__PURE__ */ jsx45(StnLoadingSkeletonTable, { rows, cols, className, style, ...rest });
|
|
5509
5628
|
case "line":
|
|
5510
5629
|
default:
|
|
5511
|
-
return /* @__PURE__ */
|
|
5630
|
+
return /* @__PURE__ */ jsx45(StnLoadingSkeletonLine, { width, className, style, ...rest });
|
|
5512
5631
|
}
|
|
5513
5632
|
}
|
|
5514
5633
|
var StnLoadingSkeleton = Object.assign(StnLoadingSkeletonRoot, {
|
|
@@ -5521,7 +5640,7 @@ var StnLoadingSkeleton = Object.assign(StnLoadingSkeletonRoot, {
|
|
|
5521
5640
|
});
|
|
5522
5641
|
|
|
5523
5642
|
// src/components/topology/StnTopologyRing.tsx
|
|
5524
|
-
import { useId as
|
|
5643
|
+
import { useId as useId15 } from "react";
|
|
5525
5644
|
|
|
5526
5645
|
// src/components/topology/stnTopologyShared.ts
|
|
5527
5646
|
var STN_TOPOLOGY_NODE_SHAPES = [
|
|
@@ -5629,7 +5748,7 @@ function ringOrbitRadius(orbit, ringCount, baseRadius, gap = 36) {
|
|
|
5629
5748
|
}
|
|
5630
5749
|
|
|
5631
5750
|
// src/components/topology/StnTopologyNodeMark.tsx
|
|
5632
|
-
import { jsx as
|
|
5751
|
+
import { jsx as jsx46, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
5633
5752
|
function renderTopologyIcon(icon, color, px) {
|
|
5634
5753
|
if (!icon) return null;
|
|
5635
5754
|
if (typeof icon !== "string") return icon;
|
|
@@ -5645,56 +5764,56 @@ function renderTopologyIcon(icon, color, px) {
|
|
|
5645
5764
|
};
|
|
5646
5765
|
switch (icon) {
|
|
5647
5766
|
case "server":
|
|
5648
|
-
return /* @__PURE__ */
|
|
5649
|
-
/* @__PURE__ */
|
|
5650
|
-
/* @__PURE__ */
|
|
5651
|
-
/* @__PURE__ */
|
|
5652
|
-
/* @__PURE__ */
|
|
5767
|
+
return /* @__PURE__ */ jsxs37("svg", { ...iconProps, children: [
|
|
5768
|
+
/* @__PURE__ */ jsx46("rect", { x: "2", y: "2", width: "20", height: "8", rx: "2", ry: "2" }),
|
|
5769
|
+
/* @__PURE__ */ jsx46("rect", { x: "2", y: "14", width: "20", height: "8", rx: "2", ry: "2" }),
|
|
5770
|
+
/* @__PURE__ */ jsx46("line", { x1: "6", y1: "6", x2: "6.01", y2: "6" }),
|
|
5771
|
+
/* @__PURE__ */ jsx46("line", { x1: "6", y1: "18", x2: "6.01", y2: "18" })
|
|
5653
5772
|
] });
|
|
5654
5773
|
case "cloud":
|
|
5655
|
-
return /* @__PURE__ */
|
|
5774
|
+
return /* @__PURE__ */ jsx46("svg", { ...iconProps, children: /* @__PURE__ */ jsx46("path", { d: "M18 10h-1.26A8 8 0 1 0 9 20h9a5 5 0 0 0 0-10z" }) });
|
|
5656
5775
|
case "ai":
|
|
5657
|
-
return /* @__PURE__ */
|
|
5658
|
-
/* @__PURE__ */
|
|
5659
|
-
/* @__PURE__ */
|
|
5660
|
-
/* @__PURE__ */
|
|
5661
|
-
/* @__PURE__ */
|
|
5662
|
-
/* @__PURE__ */
|
|
5663
|
-
/* @__PURE__ */
|
|
5664
|
-
/* @__PURE__ */
|
|
5665
|
-
/* @__PURE__ */
|
|
5666
|
-
/* @__PURE__ */
|
|
5667
|
-
/* @__PURE__ */
|
|
5776
|
+
return /* @__PURE__ */ jsxs37("svg", { ...iconProps, children: [
|
|
5777
|
+
/* @__PURE__ */ jsx46("rect", { x: "4", y: "4", width: "16", height: "16", rx: "2" }),
|
|
5778
|
+
/* @__PURE__ */ jsx46("rect", { x: "9", y: "9", width: "6", height: "6" }),
|
|
5779
|
+
/* @__PURE__ */ jsx46("line", { x1: "9", y1: "1", x2: "9", y2: "4" }),
|
|
5780
|
+
/* @__PURE__ */ jsx46("line", { x1: "15", y1: "1", x2: "15", y2: "4" }),
|
|
5781
|
+
/* @__PURE__ */ jsx46("line", { x1: "9", y1: "20", x2: "9", y2: "23" }),
|
|
5782
|
+
/* @__PURE__ */ jsx46("line", { x1: "15", y1: "20", x2: "15", y2: "23" }),
|
|
5783
|
+
/* @__PURE__ */ jsx46("line", { x1: "20", y1: "9", x2: "23", y2: "9" }),
|
|
5784
|
+
/* @__PURE__ */ jsx46("line", { x1: "20", y1: "14", x2: "23", y2: "14" }),
|
|
5785
|
+
/* @__PURE__ */ jsx46("line", { x1: "1", y1: "9", x2: "4", y2: "9" }),
|
|
5786
|
+
/* @__PURE__ */ jsx46("line", { x1: "1", y1: "14", x2: "4", y2: "14" })
|
|
5668
5787
|
] });
|
|
5669
5788
|
case "network":
|
|
5670
|
-
return /* @__PURE__ */
|
|
5671
|
-
/* @__PURE__ */
|
|
5672
|
-
/* @__PURE__ */
|
|
5673
|
-
/* @__PURE__ */
|
|
5674
|
-
/* @__PURE__ */
|
|
5675
|
-
/* @__PURE__ */
|
|
5676
|
-
/* @__PURE__ */
|
|
5677
|
-
/* @__PURE__ */
|
|
5789
|
+
return /* @__PURE__ */ jsxs37("svg", { ...iconProps, children: [
|
|
5790
|
+
/* @__PURE__ */ jsx46("rect", { x: "2", y: "2", width: "6", height: "6", rx: "1" }),
|
|
5791
|
+
/* @__PURE__ */ jsx46("rect", { x: "16", y: "2", width: "6", height: "6", rx: "1" }),
|
|
5792
|
+
/* @__PURE__ */ jsx46("rect", { x: "9", y: "16", width: "6", height: "6", rx: "1" }),
|
|
5793
|
+
/* @__PURE__ */ jsx46("line", { x1: "5", y1: "8", x2: "5", y2: "12" }),
|
|
5794
|
+
/* @__PURE__ */ jsx46("line", { x1: "19", y1: "8", x2: "19", y2: "12" }),
|
|
5795
|
+
/* @__PURE__ */ jsx46("line", { x1: "5", y1: "12", x2: "19", y2: "12" }),
|
|
5796
|
+
/* @__PURE__ */ jsx46("line", { x1: "12", y1: "12", x2: "12", y2: "16" })
|
|
5678
5797
|
] });
|
|
5679
5798
|
case "shield":
|
|
5680
|
-
return /* @__PURE__ */
|
|
5799
|
+
return /* @__PURE__ */ jsx46("svg", { ...iconProps, children: /* @__PURE__ */ jsx46("path", { d: "M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z" }) });
|
|
5681
5800
|
case "user":
|
|
5682
|
-
return /* @__PURE__ */
|
|
5683
|
-
/* @__PURE__ */
|
|
5684
|
-
/* @__PURE__ */
|
|
5801
|
+
return /* @__PURE__ */ jsxs37("svg", { ...iconProps, children: [
|
|
5802
|
+
/* @__PURE__ */ jsx46("path", { d: "M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2" }),
|
|
5803
|
+
/* @__PURE__ */ jsx46("circle", { cx: "12", cy: "7", r: "4" })
|
|
5685
5804
|
] });
|
|
5686
5805
|
case "database":
|
|
5687
|
-
return /* @__PURE__ */
|
|
5688
|
-
/* @__PURE__ */
|
|
5689
|
-
/* @__PURE__ */
|
|
5690
|
-
/* @__PURE__ */
|
|
5806
|
+
return /* @__PURE__ */ jsxs37("svg", { ...iconProps, children: [
|
|
5807
|
+
/* @__PURE__ */ jsx46("ellipse", { cx: "12", cy: "5", rx: "9", ry: "3" }),
|
|
5808
|
+
/* @__PURE__ */ jsx46("path", { d: "M21 12c0 1.66-4 3-9 3s-9-1.34-9-3" }),
|
|
5809
|
+
/* @__PURE__ */ jsx46("path", { d: "M3 5v14c0 1.66 4 3 9 3s9-1.34 9-3V5" })
|
|
5691
5810
|
] });
|
|
5692
5811
|
case "wifi":
|
|
5693
|
-
return /* @__PURE__ */
|
|
5694
|
-
/* @__PURE__ */
|
|
5695
|
-
/* @__PURE__ */
|
|
5696
|
-
/* @__PURE__ */
|
|
5697
|
-
/* @__PURE__ */
|
|
5812
|
+
return /* @__PURE__ */ jsxs37("svg", { ...iconProps, children: [
|
|
5813
|
+
/* @__PURE__ */ jsx46("path", { d: "M5 12.55a11 11 0 0 1 14.08 0" }),
|
|
5814
|
+
/* @__PURE__ */ jsx46("path", { d: "M1.42 9a16 16 0 0 1 21.16 0" }),
|
|
5815
|
+
/* @__PURE__ */ jsx46("path", { d: "M8.53 16.11a6 6 0 0 1 6.95 0" }),
|
|
5816
|
+
/* @__PURE__ */ jsx46("line", { x1: "12", y1: "20", x2: "12.01", y2: "20" })
|
|
5698
5817
|
] });
|
|
5699
5818
|
default:
|
|
5700
5819
|
return null;
|
|
@@ -5712,11 +5831,11 @@ function NodeShape({
|
|
|
5712
5831
|
}) {
|
|
5713
5832
|
const filter = glow ? `drop-shadow(0 0 8px ${glow})` : "drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4))";
|
|
5714
5833
|
if (shape === "circle") {
|
|
5715
|
-
return /* @__PURE__ */
|
|
5834
|
+
return /* @__PURE__ */ jsx46("circle", { cx: x, cy: y, r, fill, stroke, strokeWidth, style: { filter } });
|
|
5716
5835
|
}
|
|
5717
5836
|
if (shape === "square") {
|
|
5718
5837
|
const size = r * 2;
|
|
5719
|
-
return /* @__PURE__ */
|
|
5838
|
+
return /* @__PURE__ */ jsx46(
|
|
5720
5839
|
"rect",
|
|
5721
5840
|
{
|
|
5722
5841
|
x: x - r,
|
|
@@ -5731,7 +5850,7 @@ function NodeShape({
|
|
|
5731
5850
|
}
|
|
5732
5851
|
);
|
|
5733
5852
|
}
|
|
5734
|
-
return /* @__PURE__ */
|
|
5853
|
+
return /* @__PURE__ */ jsx46(
|
|
5735
5854
|
"polygon",
|
|
5736
5855
|
{
|
|
5737
5856
|
points: topologyShapePoints(shape, x, y, r),
|
|
@@ -5774,7 +5893,7 @@ function StnTopologyNodeMark({
|
|
|
5774
5893
|
const countText = formatTopologyCount(count);
|
|
5775
5894
|
const iconPx = metrics.icon;
|
|
5776
5895
|
const showCornerBadge = !isCount && count != null && count !== "";
|
|
5777
|
-
return /* @__PURE__ */
|
|
5896
|
+
return /* @__PURE__ */ jsxs37(
|
|
5778
5897
|
"g",
|
|
5779
5898
|
{
|
|
5780
5899
|
className: cn("stn-topology-node", selected && "stn-topology-node--selected", className),
|
|
@@ -5786,7 +5905,7 @@ function StnTopologyNodeMark({
|
|
|
5786
5905
|
style: { cursor: onClick ? "pointer" : "default" },
|
|
5787
5906
|
...rest,
|
|
5788
5907
|
children: [
|
|
5789
|
-
isAlert && /* @__PURE__ */
|
|
5908
|
+
isAlert && /* @__PURE__ */ jsxs37(
|
|
5790
5909
|
"circle",
|
|
5791
5910
|
{
|
|
5792
5911
|
className: "stn-topology-node__pulse",
|
|
@@ -5798,13 +5917,13 @@ function StnTopologyNodeMark({
|
|
|
5798
5917
|
strokeWidth: "1.5",
|
|
5799
5918
|
opacity: "0.55",
|
|
5800
5919
|
children: [
|
|
5801
|
-
/* @__PURE__ */
|
|
5802
|
-
/* @__PURE__ */
|
|
5920
|
+
/* @__PURE__ */ jsx46("animate", { attributeName: "r", values: `${r + 4};${r + 12};${r + 4}`, dur: "2s", repeatCount: "indefinite" }),
|
|
5921
|
+
/* @__PURE__ */ jsx46("animate", { attributeName: "opacity", values: "0.75;0.15;0.75", dur: "2s", repeatCount: "indefinite" })
|
|
5803
5922
|
]
|
|
5804
5923
|
}
|
|
5805
5924
|
),
|
|
5806
|
-
selected && /* @__PURE__ */
|
|
5807
|
-
/* @__PURE__ */
|
|
5925
|
+
selected && /* @__PURE__ */ jsx46("circle", { cx: x, cy: y, r: r + 6, fill: "none", stroke: "#00e5ff", strokeWidth: "1.5", strokeDasharray: "3 3" }),
|
|
5926
|
+
/* @__PURE__ */ jsx46(
|
|
5808
5927
|
NodeShape,
|
|
5809
5928
|
{
|
|
5810
5929
|
shape,
|
|
@@ -5817,7 +5936,7 @@ function StnTopologyNodeMark({
|
|
|
5817
5936
|
glow: isAlert || isCount ? tone.glow : ""
|
|
5818
5937
|
}
|
|
5819
5938
|
),
|
|
5820
|
-
isCount ? /* @__PURE__ */
|
|
5939
|
+
isCount ? /* @__PURE__ */ jsx46(
|
|
5821
5940
|
"text",
|
|
5822
5941
|
{
|
|
5823
5942
|
x,
|
|
@@ -5830,10 +5949,10 @@ function StnTopologyNodeMark({
|
|
|
5830
5949
|
style: { textShadow: "0 1px 2px rgba(0, 0, 0, 0.85)" },
|
|
5831
5950
|
children: countText
|
|
5832
5951
|
}
|
|
5833
|
-
) : /* @__PURE__ */
|
|
5834
|
-
showCornerBadge && /* @__PURE__ */
|
|
5835
|
-
/* @__PURE__ */
|
|
5836
|
-
/* @__PURE__ */
|
|
5952
|
+
) : /* @__PURE__ */ jsx46("g", { transform: `translate(${x - iconPx / 2}, ${y - iconPx / 2})`, children: renderTopologyIcon(icon, stroke, iconPx) }),
|
|
5953
|
+
showCornerBadge && /* @__PURE__ */ jsxs37("g", { className: "stn-topology-node__badge", children: [
|
|
5954
|
+
/* @__PURE__ */ jsx46("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" }),
|
|
5955
|
+
/* @__PURE__ */ jsx46(
|
|
5837
5956
|
"text",
|
|
5838
5957
|
{
|
|
5839
5958
|
x: x + r * 0.72,
|
|
@@ -5847,7 +5966,7 @@ function StnTopologyNodeMark({
|
|
|
5847
5966
|
}
|
|
5848
5967
|
)
|
|
5849
5968
|
] }),
|
|
5850
|
-
showLabel && label && /* @__PURE__ */
|
|
5969
|
+
showLabel && label && /* @__PURE__ */ jsx46(
|
|
5851
5970
|
"text",
|
|
5852
5971
|
{
|
|
5853
5972
|
x,
|
|
@@ -5860,7 +5979,7 @@ function StnTopologyNodeMark({
|
|
|
5860
5979
|
children: label
|
|
5861
5980
|
}
|
|
5862
5981
|
),
|
|
5863
|
-
showStatus && resolvedStatusLabel && /* @__PURE__ */
|
|
5982
|
+
showStatus && resolvedStatusLabel && /* @__PURE__ */ jsxs37(
|
|
5864
5983
|
"text",
|
|
5865
5984
|
{
|
|
5866
5985
|
x,
|
|
@@ -5891,11 +6010,11 @@ function StnTopologyNodePreview({
|
|
|
5891
6010
|
const r = STN_TOPOLOGY_NODE_SIZE[size].r;
|
|
5892
6011
|
const w = width ?? r * 2 + (showLabel ? 88 : 28);
|
|
5893
6012
|
const h = height ?? r * 2 + (showLabel || showStatus ? 56 : 28);
|
|
5894
|
-
return /* @__PURE__ */
|
|
6013
|
+
return /* @__PURE__ */ jsx46("svg", { className: "stn-topology-node-preview", width: w, height: h, viewBox: `0 0 ${w} ${h}`, overflow: "visible", children: /* @__PURE__ */ jsx46(StnTopologyNodeMark, { x: w / 2, y: h / 2, size, showLabel, showStatus, ...rest }) });
|
|
5895
6014
|
}
|
|
5896
6015
|
|
|
5897
6016
|
// src/components/topology/StnTopologyRing.tsx
|
|
5898
|
-
import { jsx as
|
|
6017
|
+
import { jsx as jsx47, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
5899
6018
|
function StnTopologyRing({
|
|
5900
6019
|
core = {
|
|
5901
6020
|
title: "\uC5D0\uC2A4\uD2F0\uC5D4\uC778\uD3EC\uD14D",
|
|
@@ -5916,8 +6035,8 @@ function StnTopologyRing({
|
|
|
5916
6035
|
style,
|
|
5917
6036
|
...rest
|
|
5918
6037
|
}) {
|
|
5919
|
-
const gradientId =
|
|
5920
|
-
const coreGlowId =
|
|
6038
|
+
const gradientId = useId15();
|
|
6039
|
+
const coreGlowId = useId15();
|
|
5921
6040
|
const safeRingCount = Math.max(1, ringCount);
|
|
5922
6041
|
const radii = Array.from(
|
|
5923
6042
|
{ length: safeRingCount },
|
|
@@ -5954,17 +6073,17 @@ function StnTopologyRing({
|
|
|
5954
6073
|
};
|
|
5955
6074
|
});
|
|
5956
6075
|
if (loading) {
|
|
5957
|
-
return /* @__PURE__ */
|
|
6076
|
+
return /* @__PURE__ */ jsx47(
|
|
5958
6077
|
"div",
|
|
5959
6078
|
{
|
|
5960
6079
|
className: cn("stn-topology-ring", "stn-topology-ring--loading", className),
|
|
5961
6080
|
style,
|
|
5962
6081
|
...rest,
|
|
5963
|
-
children: /* @__PURE__ */
|
|
6082
|
+
children: /* @__PURE__ */ jsx47("div", { className: "stn-topology-ring__loading-label", children: "\uD1A0\uD3F4\uB85C\uC9C0 \uB9C1 \uB370\uC774\uD130\uB97C \uBD88\uB7EC\uC624\uB294 \uC911..." })
|
|
5964
6083
|
}
|
|
5965
6084
|
);
|
|
5966
6085
|
}
|
|
5967
|
-
return /* @__PURE__ */
|
|
6086
|
+
return /* @__PURE__ */ jsx47(
|
|
5968
6087
|
"div",
|
|
5969
6088
|
{
|
|
5970
6089
|
className: cn("stn-topology-ring", className),
|
|
@@ -5972,7 +6091,7 @@ function StnTopologyRing({
|
|
|
5972
6091
|
"data-stn-topology-ring": true,
|
|
5973
6092
|
"data-ring-count": safeRingCount,
|
|
5974
6093
|
...rest,
|
|
5975
|
-
children: /* @__PURE__ */
|
|
6094
|
+
children: /* @__PURE__ */ jsxs38(
|
|
5976
6095
|
"svg",
|
|
5977
6096
|
{
|
|
5978
6097
|
className: "stn-topology-ring__svg",
|
|
@@ -5981,19 +6100,19 @@ function StnTopologyRing({
|
|
|
5981
6100
|
viewBox: `0 0 ${vb} ${vb}`,
|
|
5982
6101
|
overflow: "visible",
|
|
5983
6102
|
children: [
|
|
5984
|
-
/* @__PURE__ */
|
|
5985
|
-
/* @__PURE__ */
|
|
5986
|
-
/* @__PURE__ */
|
|
5987
|
-
/* @__PURE__ */
|
|
6103
|
+
/* @__PURE__ */ jsxs38("defs", { children: [
|
|
6104
|
+
/* @__PURE__ */ jsxs38("radialGradient", { id: coreGlowId, cx: "50%", cy: "50%", r: "50%", children: [
|
|
6105
|
+
/* @__PURE__ */ jsx47("stop", { offset: "0%", stopColor: "#722ed1", stopOpacity: "0.8" }),
|
|
6106
|
+
/* @__PURE__ */ jsx47("stop", { offset: "100%", stopColor: "#120338", stopOpacity: "0" })
|
|
5988
6107
|
] }),
|
|
5989
|
-
/* @__PURE__ */
|
|
5990
|
-
/* @__PURE__ */
|
|
5991
|
-
/* @__PURE__ */
|
|
6108
|
+
/* @__PURE__ */ jsxs38("linearGradient", { id: gradientId, x1: "0%", y1: "0%", x2: "100%", y2: "100%", children: [
|
|
6109
|
+
/* @__PURE__ */ jsx47("stop", { offset: "0%", stopColor: "#00e5ff", stopOpacity: "0.4" }),
|
|
6110
|
+
/* @__PURE__ */ jsx47("stop", { offset: "100%", stopColor: "#722ed1", stopOpacity: "0.4" })
|
|
5992
6111
|
] })
|
|
5993
6112
|
] }),
|
|
5994
6113
|
radii.map((r, idx) => {
|
|
5995
6114
|
const isMain = idx + 1 === mainOrbit;
|
|
5996
|
-
return /* @__PURE__ */
|
|
6115
|
+
return /* @__PURE__ */ jsx47(
|
|
5997
6116
|
"circle",
|
|
5998
6117
|
{
|
|
5999
6118
|
cx: centerX,
|
|
@@ -6007,7 +6126,7 @@ function StnTopologyRing({
|
|
|
6007
6126
|
`orbit-${idx}`
|
|
6008
6127
|
);
|
|
6009
6128
|
}),
|
|
6010
|
-
connectionLineStyle !== "none" && calculatedNodes.map((node) => /* @__PURE__ */
|
|
6129
|
+
connectionLineStyle !== "none" && calculatedNodes.map((node) => /* @__PURE__ */ jsx47(
|
|
6011
6130
|
"line",
|
|
6012
6131
|
{
|
|
6013
6132
|
x1: centerX,
|
|
@@ -6020,9 +6139,9 @@ function StnTopologyRing({
|
|
|
6020
6139
|
},
|
|
6021
6140
|
`line-${node.id}`
|
|
6022
6141
|
)),
|
|
6023
|
-
/* @__PURE__ */
|
|
6024
|
-
/* @__PURE__ */
|
|
6025
|
-
/* @__PURE__ */
|
|
6142
|
+
/* @__PURE__ */ jsxs38("g", { className: "stn-topology-ring__core", children: [
|
|
6143
|
+
/* @__PURE__ */ jsx47("circle", { cx: centerX, cy: centerY, r: 54, fill: `url(#${coreGlowId})` }),
|
|
6144
|
+
/* @__PURE__ */ jsx47(
|
|
6026
6145
|
"circle",
|
|
6027
6146
|
{
|
|
6028
6147
|
cx: centerX,
|
|
@@ -6034,7 +6153,7 @@ function StnTopologyRing({
|
|
|
6034
6153
|
style: { filter: "drop-shadow(0 0 12px rgba(114, 46, 209, 0.6))" }
|
|
6035
6154
|
}
|
|
6036
6155
|
),
|
|
6037
|
-
core.subTitle && /* @__PURE__ */
|
|
6156
|
+
core.subTitle && /* @__PURE__ */ jsx47(
|
|
6038
6157
|
"text",
|
|
6039
6158
|
{
|
|
6040
6159
|
x: centerX,
|
|
@@ -6047,13 +6166,13 @@ function StnTopologyRing({
|
|
|
6047
6166
|
children: core.subTitle
|
|
6048
6167
|
}
|
|
6049
6168
|
),
|
|
6050
|
-
core.title && /* @__PURE__ */
|
|
6051
|
-
/* @__PURE__ */
|
|
6169
|
+
core.title && /* @__PURE__ */ jsx47("text", { x: centerX, y: centerY + 8, textAnchor: "middle", fill: "#f0f2f5", fontSize: "10", fontWeight: "600", children: core.title }),
|
|
6170
|
+
/* @__PURE__ */ jsxs38("text", { x: centerX, y: centerY + 22, textAnchor: "middle", fill: coreColor, fontSize: "9", fontWeight: "500", children: [
|
|
6052
6171
|
"\u25CF ",
|
|
6053
6172
|
coreStatusLabel
|
|
6054
6173
|
] })
|
|
6055
6174
|
] }),
|
|
6056
|
-
calculatedNodes.map((node) => /* @__PURE__ */
|
|
6175
|
+
calculatedNodes.map((node) => /* @__PURE__ */ jsx47(
|
|
6057
6176
|
StnTopologyNodeMark,
|
|
6058
6177
|
{
|
|
6059
6178
|
x: node.x,
|
|
@@ -6081,8 +6200,8 @@ function StnTopologyRing({
|
|
|
6081
6200
|
}
|
|
6082
6201
|
|
|
6083
6202
|
// src/components/topology/StnTopologyGraph.tsx
|
|
6084
|
-
import { useState as
|
|
6085
|
-
import { jsx as
|
|
6203
|
+
import { useState as useState14 } from "react";
|
|
6204
|
+
import { jsx as jsx48, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
6086
6205
|
var DEFAULT_GRAPH_NODES = [
|
|
6087
6206
|
{ id: "n1", x: 200, y: 58, status: "minor", label: "GW-01", shape: "circle", content: "icon", icon: "wifi" },
|
|
6088
6207
|
{ id: "n2", x: 118, y: 118, status: "critical", label: "BACKUP", shape: "hexagon", content: "count", count: 4, pulse: true },
|
|
@@ -6116,12 +6235,12 @@ function StnTopologyGraph({
|
|
|
6116
6235
|
style,
|
|
6117
6236
|
...rest
|
|
6118
6237
|
}) {
|
|
6119
|
-
const [viewMode, setViewMode] =
|
|
6238
|
+
const [viewMode, setViewMode] = useState14(defaultMode);
|
|
6120
6239
|
if (loading) {
|
|
6121
|
-
return /* @__PURE__ */
|
|
6240
|
+
return /* @__PURE__ */ jsx48("div", { className: cn("stn-topology-graph", "stn-topology-graph--loading", className), style, ...rest, children: /* @__PURE__ */ jsx48("div", { className: "stn-topology-graph__loading-label", children: "\uD1A0\uD3F4\uB85C\uC9C0 \uCE94\uBC84\uC2A4 \uB370\uC774\uD130\uB97C \uBD88\uB7EC\uC624\uB294 \uC911..." }) });
|
|
6122
6241
|
}
|
|
6123
6242
|
const nodeMap = new Map(nodes.map((n) => [n.id, n]));
|
|
6124
|
-
return /* @__PURE__ */
|
|
6243
|
+
return /* @__PURE__ */ jsxs39(
|
|
6125
6244
|
"div",
|
|
6126
6245
|
{
|
|
6127
6246
|
className: cn("stn-topology-graph", className),
|
|
@@ -6130,7 +6249,7 @@ function StnTopologyGraph({
|
|
|
6130
6249
|
"data-view-mode": viewMode,
|
|
6131
6250
|
...rest,
|
|
6132
6251
|
children: [
|
|
6133
|
-
showModeToggle && /* @__PURE__ */
|
|
6252
|
+
showModeToggle && /* @__PURE__ */ jsx48("div", { className: "stn-topology-graph__mode", children: /* @__PURE__ */ jsx48(
|
|
6134
6253
|
StnSegmented,
|
|
6135
6254
|
{
|
|
6136
6255
|
size: "sm",
|
|
@@ -6142,23 +6261,23 @@ function StnTopologyGraph({
|
|
|
6142
6261
|
]
|
|
6143
6262
|
}
|
|
6144
6263
|
) }),
|
|
6145
|
-
/* @__PURE__ */
|
|
6146
|
-
viewMode === "3D" ? /* @__PURE__ */
|
|
6147
|
-
/* @__PURE__ */
|
|
6148
|
-
/* @__PURE__ */
|
|
6149
|
-
/* @__PURE__ */
|
|
6150
|
-
/* @__PURE__ */
|
|
6151
|
-
/* @__PURE__ */
|
|
6152
|
-
/* @__PURE__ */
|
|
6153
|
-
/* @__PURE__ */
|
|
6154
|
-
/* @__PURE__ */
|
|
6155
|
-
] }) : /* @__PURE__ */
|
|
6156
|
-
/* @__PURE__ */
|
|
6157
|
-
/* @__PURE__ */
|
|
6158
|
-
/* @__PURE__ */
|
|
6159
|
-
/* @__PURE__ */
|
|
6160
|
-
/* @__PURE__ */
|
|
6161
|
-
/* @__PURE__ */
|
|
6264
|
+
/* @__PURE__ */ jsxs39("svg", { className: "stn-topology-graph__svg", width: "100%", height: "100%", viewBox: "0 0 400 300", overflow: "visible", children: [
|
|
6265
|
+
viewMode === "3D" ? /* @__PURE__ */ jsxs39("g", { opacity: "0.6", children: [
|
|
6266
|
+
/* @__PURE__ */ jsx48("line", { x1: "60", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.06)", strokeDasharray: "3 3" }),
|
|
6267
|
+
/* @__PURE__ */ jsx48("line", { x1: "130", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "3 3" }),
|
|
6268
|
+
/* @__PURE__ */ jsx48("line", { x1: "200", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.14)", strokeDasharray: "3 3" }),
|
|
6269
|
+
/* @__PURE__ */ jsx48("line", { x1: "270", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "3 3" }),
|
|
6270
|
+
/* @__PURE__ */ jsx48("line", { x1: "340", y1: "260", x2: "200", y2: "80", stroke: "rgba(255,255,255,0.06)", strokeDasharray: "3 3" }),
|
|
6271
|
+
/* @__PURE__ */ jsx48("line", { x1: "100", y1: "230", x2: "300", y2: "230", stroke: "rgba(255,255,255,0.06)" }),
|
|
6272
|
+
/* @__PURE__ */ jsx48("line", { x1: "130", y1: "190", x2: "270", y2: "190", stroke: "rgba(255,255,255,0.06)" }),
|
|
6273
|
+
/* @__PURE__ */ jsx48("line", { x1: "160", y1: "140", x2: "240", y2: "140", stroke: "rgba(255,255,255,0.06)" })
|
|
6274
|
+
] }) : /* @__PURE__ */ jsxs39("g", { opacity: "0.3", children: [
|
|
6275
|
+
/* @__PURE__ */ jsx48("line", { x1: "40", y1: "60", x2: "360", y2: "60", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6276
|
+
/* @__PURE__ */ jsx48("line", { x1: "40", y1: "150", x2: "360", y2: "150", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6277
|
+
/* @__PURE__ */ jsx48("line", { x1: "40", y1: "240", x2: "360", y2: "240", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6278
|
+
/* @__PURE__ */ jsx48("line", { x1: "100", y1: "20", x2: "100", y2: "280", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6279
|
+
/* @__PURE__ */ jsx48("line", { x1: "200", y1: "20", x2: "200", y2: "280", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" }),
|
|
6280
|
+
/* @__PURE__ */ jsx48("line", { x1: "300", y1: "20", x2: "300", y2: "280", stroke: "rgba(255,255,255,0.08)", strokeDasharray: "4 4" })
|
|
6162
6281
|
] }),
|
|
6163
6282
|
links.map((link, idx) => {
|
|
6164
6283
|
const s = nodeMap.get(link.source);
|
|
@@ -6166,7 +6285,7 @@ function StnTopologyGraph({
|
|
|
6166
6285
|
if (!s || !t) return null;
|
|
6167
6286
|
const isAlert = s.status === "critical" || t.status === "critical" || link.status === "critical";
|
|
6168
6287
|
const strokeColor = isAlert ? "rgba(255, 77, 79, 0.65)" : "rgba(255, 255, 255, 0.2)";
|
|
6169
|
-
return /* @__PURE__ */
|
|
6288
|
+
return /* @__PURE__ */ jsx48(
|
|
6170
6289
|
"line",
|
|
6171
6290
|
{
|
|
6172
6291
|
x1: s.x,
|
|
@@ -6183,7 +6302,7 @@ function StnTopologyGraph({
|
|
|
6183
6302
|
nodes.map((node) => {
|
|
6184
6303
|
const status = node.status ?? "normal";
|
|
6185
6304
|
const isCore = Boolean(node.isCore);
|
|
6186
|
-
return /* @__PURE__ */
|
|
6305
|
+
return /* @__PURE__ */ jsx48(
|
|
6187
6306
|
StnTopologyNodeMark,
|
|
6188
6307
|
{
|
|
6189
6308
|
x: node.x,
|
|
@@ -6206,17 +6325,17 @@ function StnTopologyGraph({
|
|
|
6206
6325
|
);
|
|
6207
6326
|
})
|
|
6208
6327
|
] }),
|
|
6209
|
-
showMinimap && /* @__PURE__ */
|
|
6210
|
-
/* @__PURE__ */
|
|
6211
|
-
/* @__PURE__ */
|
|
6212
|
-
/* @__PURE__ */
|
|
6328
|
+
showMinimap && /* @__PURE__ */ jsxs39("div", { className: "stn-topology-graph__minimap", children: [
|
|
6329
|
+
/* @__PURE__ */ jsxs39("div", { className: "stn-topology-graph__minimap-head", children: [
|
|
6330
|
+
/* @__PURE__ */ jsx48("span", { children: "\uBBF8\uB9AC\uBCF4\uAE30" }),
|
|
6331
|
+
/* @__PURE__ */ jsx48("span", { children: "\u2014" })
|
|
6213
6332
|
] }),
|
|
6214
|
-
/* @__PURE__ */
|
|
6215
|
-
/* @__PURE__ */
|
|
6216
|
-
/* @__PURE__ */
|
|
6217
|
-
/* @__PURE__ */
|
|
6218
|
-
/* @__PURE__ */
|
|
6219
|
-
/* @__PURE__ */
|
|
6333
|
+
/* @__PURE__ */ jsxs39("svg", { width: "100%", height: "40", viewBox: "0 0 100 50", children: [
|
|
6334
|
+
/* @__PURE__ */ jsx48("polyline", { points: "50,10 40,25 50,40 60,30", fill: "none", stroke: "rgba(255,77,79,0.5)", strokeWidth: "1" }),
|
|
6335
|
+
/* @__PURE__ */ jsx48("circle", { cx: "50", cy: "10", r: "2", fill: STN_TOPOLOGY_STATUS_COLORS.critical.main }),
|
|
6336
|
+
/* @__PURE__ */ jsx48("circle", { cx: "40", cy: "25", r: "2.5", fill: STN_TOPOLOGY_STATUS_COLORS.critical.main }),
|
|
6337
|
+
/* @__PURE__ */ jsx48("circle", { cx: "50", cy: "40", r: "2", fill: "#00e5ff" }),
|
|
6338
|
+
/* @__PURE__ */ jsx48("circle", { cx: "60", cy: "30", r: "2", fill: STN_TOPOLOGY_STATUS_COLORS.normal.main })
|
|
6220
6339
|
] })
|
|
6221
6340
|
] })
|
|
6222
6341
|
]
|
|
@@ -6225,7 +6344,7 @@ function StnTopologyGraph({
|
|
|
6225
6344
|
}
|
|
6226
6345
|
|
|
6227
6346
|
// src/components/StnWidget.tsx
|
|
6228
|
-
import { Fragment as Fragment5, jsx as
|
|
6347
|
+
import { Fragment as Fragment5, jsx as jsx49, jsxs as jsxs40 } from "react/jsx-runtime";
|
|
6229
6348
|
var SHELL_PUB_CLASS = {
|
|
6230
6349
|
card: "",
|
|
6231
6350
|
"fault-panel": "",
|
|
@@ -6308,20 +6427,20 @@ function StnWidgetPeriodText({
|
|
|
6308
6427
|
className,
|
|
6309
6428
|
...rest
|
|
6310
6429
|
}) {
|
|
6311
|
-
return /* @__PURE__ */
|
|
6430
|
+
return /* @__PURE__ */ jsx49("span", { className: cn("stn-widget__period-text", className), ...rest, children });
|
|
6312
6431
|
}
|
|
6313
6432
|
function StnWidgetPeriodSelect({
|
|
6314
6433
|
label,
|
|
6315
6434
|
className,
|
|
6316
6435
|
...rest
|
|
6317
6436
|
}) {
|
|
6318
|
-
return /* @__PURE__ */
|
|
6437
|
+
return /* @__PURE__ */ jsx49(
|
|
6319
6438
|
StnButton,
|
|
6320
6439
|
{
|
|
6321
6440
|
variant: "ghost",
|
|
6322
6441
|
size: "sm",
|
|
6323
6442
|
shape: "square",
|
|
6324
|
-
icon: /* @__PURE__ */
|
|
6443
|
+
icon: /* @__PURE__ */ jsx49(StnIcon, { name: "line/chevron-down" }),
|
|
6325
6444
|
iconPosition: "right",
|
|
6326
6445
|
className,
|
|
6327
6446
|
...rest,
|
|
@@ -6338,26 +6457,26 @@ function StnWidgetPeriodPager({
|
|
|
6338
6457
|
nextLabel = "\uB2E4\uC74C",
|
|
6339
6458
|
...rest
|
|
6340
6459
|
}) {
|
|
6341
|
-
return /* @__PURE__ */
|
|
6342
|
-
/* @__PURE__ */
|
|
6460
|
+
return /* @__PURE__ */ jsxs40("div", { className: cn("stn-widget__period-pager", className), ...rest, children: [
|
|
6461
|
+
/* @__PURE__ */ jsx49(
|
|
6343
6462
|
StnButton,
|
|
6344
6463
|
{
|
|
6345
6464
|
variant: "ghost",
|
|
6346
6465
|
size: "sm",
|
|
6347
6466
|
shape: "square",
|
|
6348
|
-
icon: /* @__PURE__ */
|
|
6467
|
+
icon: /* @__PURE__ */ jsx49(StnIcon, { name: "line/arrow-narrow-left" }),
|
|
6349
6468
|
onClick: onPrev,
|
|
6350
6469
|
"aria-label": prevLabel
|
|
6351
6470
|
}
|
|
6352
6471
|
),
|
|
6353
|
-
/* @__PURE__ */
|
|
6354
|
-
/* @__PURE__ */
|
|
6472
|
+
/* @__PURE__ */ jsx49("span", { className: "stn-widget__period-pager-label", children: label }),
|
|
6473
|
+
/* @__PURE__ */ jsx49(
|
|
6355
6474
|
StnButton,
|
|
6356
6475
|
{
|
|
6357
6476
|
variant: "ghost",
|
|
6358
6477
|
size: "sm",
|
|
6359
6478
|
shape: "square",
|
|
6360
|
-
icon: /* @__PURE__ */
|
|
6479
|
+
icon: /* @__PURE__ */ jsx49(StnIcon, { name: "line/arrow-narrow-right" }),
|
|
6361
6480
|
onClick: onNext,
|
|
6362
6481
|
"aria-label": nextLabel
|
|
6363
6482
|
}
|
|
@@ -6377,18 +6496,18 @@ function StnWidgetHeaderInner({
|
|
|
6377
6496
|
wrapActions = false
|
|
6378
6497
|
}) {
|
|
6379
6498
|
const resolvedIconName = headerIconName ?? defaultHeaderIconName(appearance);
|
|
6380
|
-
return /* @__PURE__ */
|
|
6381
|
-
/* @__PURE__ */
|
|
6382
|
-
showHeaderIcon ? headerIcon != null ? /* @__PURE__ */
|
|
6383
|
-
title != null || badge != null ? typeof title === "string" || title == null ? /* @__PURE__ */
|
|
6384
|
-
typeof title === "string" ? /* @__PURE__ */
|
|
6499
|
+
return /* @__PURE__ */ jsxs40("div", { className: cn("stn-widget__head", wrapActions && "stn-widget__head--wrap"), children: [
|
|
6500
|
+
/* @__PURE__ */ jsxs40("div", { className: "stn-widget__head-start", children: [
|
|
6501
|
+
showHeaderIcon ? headerIcon != null ? /* @__PURE__ */ jsx49(StnWidgetInsetIcon, { size: "sm", children: headerIcon }) : resolvedIconName ? /* @__PURE__ */ jsx49(StnWidgetInsetIcon, { size: "sm", icon: resolvedIconName }) : null : null,
|
|
6502
|
+
title != null || badge != null ? typeof title === "string" || title == null ? /* @__PURE__ */ jsxs40("div", { className: "stn-widget__title-wrap", children: [
|
|
6503
|
+
typeof title === "string" ? /* @__PURE__ */ jsx49("p", { className: "stn-widget__title", title, children: title }) : null,
|
|
6385
6504
|
badge
|
|
6386
|
-
] }) : /* @__PURE__ */
|
|
6505
|
+
] }) : /* @__PURE__ */ jsxs40(Fragment5, { children: [
|
|
6387
6506
|
title,
|
|
6388
6507
|
badge
|
|
6389
6508
|
] }) : null
|
|
6390
6509
|
] }),
|
|
6391
|
-
titleActions != null || periodActions != null || periodLabel != null && periodLabel !== "" ? /* @__PURE__ */
|
|
6510
|
+
titleActions != null || periodActions != null || periodLabel != null && periodLabel !== "" ? /* @__PURE__ */ jsx49("div", { className: "stn-widget__head-end", children: titleActions ?? (periodActions != null ? periodActions : periodLabel != null && periodLabel !== "" ? /* @__PURE__ */ jsx49(StnWidgetPeriodText, { children: periodLabel }) : null) }) : null
|
|
6392
6511
|
] });
|
|
6393
6512
|
}
|
|
6394
6513
|
function StnWidgetRoot({
|
|
@@ -6468,10 +6587,10 @@ function StnWidgetRoot({
|
|
|
6468
6587
|
...rest
|
|
6469
6588
|
};
|
|
6470
6589
|
const slots = partitionWidgetChildren(children);
|
|
6471
|
-
const propHead = shell === "fault-panel" && !isFigmaShell ? title != null || titleActions ? /* @__PURE__ */
|
|
6472
|
-
/* @__PURE__ */
|
|
6590
|
+
const propHead = shell === "fault-panel" && !isFigmaShell ? title != null || titleActions ? /* @__PURE__ */ jsxs40("div", { className: "app_bar", children: [
|
|
6591
|
+
/* @__PURE__ */ jsx49("div", { className: "fault_title_box", children: typeof title === "string" ? /* @__PURE__ */ jsx49("span", { children: title }) : title }),
|
|
6473
6592
|
titleActions
|
|
6474
|
-
] }) : null : shell === "board" || shell === "board-item" ? title != null ? /* @__PURE__ */
|
|
6593
|
+
] }) : null : shell === "board" || shell === "board-item" ? title != null ? /* @__PURE__ */ jsx49("div", { className: "stn-widget__head", children: typeof title === "string" ? /* @__PURE__ */ jsx49("p", { children: title }) : title }) : null : isFigmaShell ? /* @__PURE__ */ jsx49(
|
|
6475
6594
|
StnWidgetHeaderInner,
|
|
6476
6595
|
{
|
|
6477
6596
|
appearance,
|
|
@@ -6485,48 +6604,48 @@ function StnWidgetRoot({
|
|
|
6485
6604
|
headerIcon,
|
|
6486
6605
|
wrapActions
|
|
6487
6606
|
}
|
|
6488
|
-
) : title != null || badge != null || titleActions ? /* @__PURE__ */
|
|
6489
|
-
/* @__PURE__ */
|
|
6490
|
-
title != null ? typeof title === "string" ? /* @__PURE__ */
|
|
6607
|
+
) : title != null || badge != null || titleActions ? /* @__PURE__ */ jsxs40("div", { className: cn("stn-widget__head", wrapActions && "stn-widget__head--wrap"), children: [
|
|
6608
|
+
/* @__PURE__ */ jsxs40("div", { className: "stn-widget__head-start", children: [
|
|
6609
|
+
title != null ? typeof title === "string" ? /* @__PURE__ */ jsx49("p", { className: "stn-widget__title", title, children: title }) : title : null,
|
|
6491
6610
|
badge
|
|
6492
6611
|
] }),
|
|
6493
|
-
titleActions ? /* @__PURE__ */
|
|
6612
|
+
titleActions ? /* @__PURE__ */ jsx49("div", { className: "stn-widget__head-end", children: titleActions }) : null
|
|
6494
6613
|
] }) : null;
|
|
6495
6614
|
const head = slots.headers.length > 0 ? slots.headers : propHead;
|
|
6496
6615
|
const autoBodyClass = shell === "fault-panel" && !isFigmaShell ? "table_area" : void 0;
|
|
6497
6616
|
let body;
|
|
6498
6617
|
if (loading) {
|
|
6499
|
-
body = /* @__PURE__ */
|
|
6618
|
+
body = /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__body", autoBodyClass, contentClassName), children: /* @__PURE__ */ jsx49(StnWidgetLoading, {}) });
|
|
6500
6619
|
} else if (slots.bodies.length > 0) {
|
|
6501
6620
|
body = slots.bodies.map(
|
|
6502
6621
|
(slot, index) => mergeBodySlot(slot, index === 0 ? slots.rest : [], contentClassName, isEmptyState, emptyStyle)
|
|
6503
6622
|
);
|
|
6504
6623
|
} else {
|
|
6505
|
-
body = /* @__PURE__ */
|
|
6624
|
+
body = /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__body", autoBodyClass, isEmptyState && "empty", contentClassName), style: emptyStyle, children: slots.rest });
|
|
6506
6625
|
}
|
|
6507
|
-
const footerNode = slots.footers.length > 0 ? slots.footers : footer ? /* @__PURE__ */
|
|
6508
|
-
const card = /* @__PURE__ */
|
|
6509
|
-
isFigmaShell && appearanceShell === "overlay" ? /* @__PURE__ */
|
|
6626
|
+
const footerNode = slots.footers.length > 0 ? slots.footers : footer ? /* @__PURE__ */ jsx49("div", { className: "stn-widget__footer", children: footer }) : null;
|
|
6627
|
+
const card = /* @__PURE__ */ jsxs40("div", { ...rootProps, children: [
|
|
6628
|
+
isFigmaShell && appearanceShell === "overlay" ? /* @__PURE__ */ jsx49("div", { className: "stn-widget__map-deco", "aria-hidden": true }) : null,
|
|
6510
6629
|
head,
|
|
6511
6630
|
body,
|
|
6512
6631
|
footerNode
|
|
6513
6632
|
] });
|
|
6514
6633
|
if (banner == null || banner === false) return card;
|
|
6515
|
-
return /* @__PURE__ */
|
|
6634
|
+
return /* @__PURE__ */ jsxs40("div", { className: "stn-widget-anchor", children: [
|
|
6516
6635
|
withBannerSeverity(banner, bannerSeverityFromStatus(status, isCritical)),
|
|
6517
6636
|
card
|
|
6518
6637
|
] });
|
|
6519
6638
|
}
|
|
6520
6639
|
function StnWidgetHeader({ className, wrap = false, children, ...rest }) {
|
|
6521
|
-
return /* @__PURE__ */
|
|
6640
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__head", wrap && "stn-widget__head--wrap", className), ...rest, children });
|
|
6522
6641
|
}
|
|
6523
6642
|
markWidgetSlot(StnWidgetHeader, "header");
|
|
6524
6643
|
function StnWidgetTitle({ className, children, title, ...rest }) {
|
|
6525
6644
|
const titleAttr = title ?? (typeof children === "string" ? children : void 0);
|
|
6526
|
-
return /* @__PURE__ */
|
|
6645
|
+
return /* @__PURE__ */ jsx49("p", { className: cn("stn-widget__title", className), title: titleAttr, ...rest, children });
|
|
6527
6646
|
}
|
|
6528
6647
|
function StnWidgetActions({ className, children, ...rest }) {
|
|
6529
|
-
return /* @__PURE__ */
|
|
6648
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__head-end", className), ...rest, children });
|
|
6530
6649
|
}
|
|
6531
6650
|
function StnWidgetBody({
|
|
6532
6651
|
padding,
|
|
@@ -6540,7 +6659,7 @@ function StnWidgetBody({
|
|
|
6540
6659
|
}) {
|
|
6541
6660
|
const emptyText = typeof empty === "string" ? empty : void 0;
|
|
6542
6661
|
const mergedStyle = emptyText ? { ["--stn-widget-empty-text"]: `"${emptyText}"`, ...style } : style;
|
|
6543
|
-
return /* @__PURE__ */
|
|
6662
|
+
return /* @__PURE__ */ jsx49(
|
|
6544
6663
|
"div",
|
|
6545
6664
|
{
|
|
6546
6665
|
className: cn(
|
|
@@ -6562,7 +6681,7 @@ function StnWidgetBody({
|
|
|
6562
6681
|
}
|
|
6563
6682
|
markWidgetSlot(StnWidgetBody, "body");
|
|
6564
6683
|
function StnWidgetChartSlot({ label = "select chart", className, children, ...rest }) {
|
|
6565
|
-
return /* @__PURE__ */
|
|
6684
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__chart-slot", className), "data-stn-widget-chart-slot": true, ...rest, children: children ?? /* @__PURE__ */ jsx49("span", { className: "stn-widget__chart-slot-label", children: label }) });
|
|
6566
6685
|
}
|
|
6567
6686
|
function StnWidgetStatusItem({
|
|
6568
6687
|
label,
|
|
@@ -6574,9 +6693,9 @@ function StnWidgetStatusItem({
|
|
|
6574
6693
|
...rest
|
|
6575
6694
|
}) {
|
|
6576
6695
|
const grade = gradeProp ?? (status === "warning" ? "minor" : status) ?? "normal";
|
|
6577
|
-
return /* @__PURE__ */
|
|
6578
|
-
/* @__PURE__ */
|
|
6579
|
-
showDot ? /* @__PURE__ */
|
|
6696
|
+
return /* @__PURE__ */ jsxs40("div", { className: cn("stn-widget__status-item", className), ...rest, children: [
|
|
6697
|
+
/* @__PURE__ */ jsxs40("span", { className: "stn-widget__status-label", children: [
|
|
6698
|
+
showDot ? /* @__PURE__ */ jsx49(
|
|
6580
6699
|
"span",
|
|
6581
6700
|
{
|
|
6582
6701
|
className: cn("stn-widget__status-dot", `stn-widget__status-dot--${grade}`),
|
|
@@ -6585,23 +6704,23 @@ function StnWidgetStatusItem({
|
|
|
6585
6704
|
) : null,
|
|
6586
6705
|
label
|
|
6587
6706
|
] }),
|
|
6588
|
-
/* @__PURE__ */
|
|
6707
|
+
/* @__PURE__ */ jsx49("span", { className: "stn-widget__status-val", children: value })
|
|
6589
6708
|
] });
|
|
6590
6709
|
}
|
|
6591
6710
|
function StnWidgetStatusList({ className, children, ...rest }) {
|
|
6592
|
-
return /* @__PURE__ */
|
|
6711
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__status-list", className), ...rest, children });
|
|
6593
6712
|
}
|
|
6594
6713
|
function StnWidgetStatGroup({ className, children, ...rest }) {
|
|
6595
|
-
return /* @__PURE__ */
|
|
6714
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__stat-group", className), ...rest, children });
|
|
6596
6715
|
}
|
|
6597
6716
|
function StnWidgetStatCard({ label, count, className, ...rest }) {
|
|
6598
|
-
return /* @__PURE__ */
|
|
6599
|
-
/* @__PURE__ */
|
|
6600
|
-
/* @__PURE__ */
|
|
6717
|
+
return /* @__PURE__ */ jsxs40("div", { className: cn("stn-widget__stat-card", className), ...rest, children: [
|
|
6718
|
+
/* @__PURE__ */ jsx49("span", { className: "stn-widget__stat-label", children: label }),
|
|
6719
|
+
/* @__PURE__ */ jsx49("span", { className: "stn-widget__stat-count", children: count })
|
|
6601
6720
|
] });
|
|
6602
6721
|
}
|
|
6603
6722
|
function StnWidgetPlaceholder({ label = "\uCF58\uD150\uCE20 \uC601\uC5ED" }) {
|
|
6604
|
-
return /* @__PURE__ */
|
|
6723
|
+
return /* @__PURE__ */ jsx49("div", { className: "stn-widget__placeholder", children: label });
|
|
6605
6724
|
}
|
|
6606
6725
|
var GRADE_ROW_ICON = {
|
|
6607
6726
|
critical: "fill/alert4",
|
|
@@ -6624,42 +6743,42 @@ function StnWidgetGradeRow({
|
|
|
6624
6743
|
}) {
|
|
6625
6744
|
const clamped = Math.max(0, Math.min(100, percent));
|
|
6626
6745
|
const resolvedPercentLabel = percentLabel ?? formatGradePercent(clamped);
|
|
6627
|
-
return /* @__PURE__ */
|
|
6628
|
-
/* @__PURE__ */
|
|
6629
|
-
/* @__PURE__ */
|
|
6630
|
-
/* @__PURE__ */
|
|
6746
|
+
return /* @__PURE__ */ jsxs40("div", { className: cn("stn-widget__grade-row", `stn-widget__grade-row--${grade}`, className), ...rest, children: [
|
|
6747
|
+
/* @__PURE__ */ jsxs40("div", { className: "stn-widget__grade-row-left", children: [
|
|
6748
|
+
/* @__PURE__ */ jsxs40("span", { className: "stn-widget__grade-row-label", children: [
|
|
6749
|
+
/* @__PURE__ */ jsx49(StnIcon, { name: GRADE_ROW_ICON[grade], size: 20, className: "stn-widget__grade-row-icon", "aria-hidden": true }),
|
|
6631
6750
|
label
|
|
6632
6751
|
] }),
|
|
6633
|
-
/* @__PURE__ */
|
|
6752
|
+
/* @__PURE__ */ jsx49("div", { className: "stn-widget__grade-row-track", "aria-hidden": true, children: /* @__PURE__ */ jsx49("span", { className: "stn-widget__grade-row-fill", style: { width: `${clamped}%` } }) })
|
|
6634
6753
|
] }),
|
|
6635
|
-
/* @__PURE__ */
|
|
6636
|
-
/* @__PURE__ */
|
|
6637
|
-
/* @__PURE__ */
|
|
6754
|
+
/* @__PURE__ */ jsxs40("div", { className: "stn-widget__grade-row-right", children: [
|
|
6755
|
+
/* @__PURE__ */ jsx49("span", { className: "stn-widget__grade-row-value", children: value }),
|
|
6756
|
+
/* @__PURE__ */ jsx49("span", { className: "stn-widget__grade-row-percent", children: resolvedPercentLabel })
|
|
6638
6757
|
] })
|
|
6639
6758
|
] });
|
|
6640
6759
|
}
|
|
6641
6760
|
function StnWidgetGradeRowList({ className, children, ...rest }) {
|
|
6642
|
-
return /* @__PURE__ */
|
|
6761
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__grade-row-list", className), ...rest, children });
|
|
6643
6762
|
}
|
|
6644
6763
|
function StnWidgetFooter({ className, children, ...rest }) {
|
|
6645
|
-
return /* @__PURE__ */
|
|
6764
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__footer", className), ...rest, children });
|
|
6646
6765
|
}
|
|
6647
6766
|
markWidgetSlot(StnWidgetFooter, "footer");
|
|
6648
6767
|
function StnWidgetEmpty({ className, children, ...rest }) {
|
|
6649
|
-
return /* @__PURE__ */
|
|
6650
|
-
/* @__PURE__ */
|
|
6651
|
-
/* @__PURE__ */
|
|
6652
|
-
/* @__PURE__ */
|
|
6653
|
-
/* @__PURE__ */
|
|
6768
|
+
return /* @__PURE__ */ jsxs40("div", { className: cn("stn-widget__empty", className), ...rest, children: [
|
|
6769
|
+
/* @__PURE__ */ jsxs40("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: [
|
|
6770
|
+
/* @__PURE__ */ jsx49("circle", { cx: "12", cy: "12", r: "10" }),
|
|
6771
|
+
/* @__PURE__ */ jsx49("line", { x1: "12", y1: "8", x2: "12", y2: "12" }),
|
|
6772
|
+
/* @__PURE__ */ jsx49("line", { x1: "12", y1: "16", x2: "12.01", y2: "16" })
|
|
6654
6773
|
] }),
|
|
6655
|
-
/* @__PURE__ */
|
|
6774
|
+
/* @__PURE__ */ jsx49("div", { children: children ?? "\uB370\uC774\uD130\uAC00 \uC5C6\uC2B5\uB2C8\uB2E4." })
|
|
6656
6775
|
] });
|
|
6657
6776
|
}
|
|
6658
6777
|
function StnWidgetLoading({ lines = 3, className, children, ...rest }) {
|
|
6659
|
-
return /* @__PURE__ */
|
|
6778
|
+
return /* @__PURE__ */ jsx49("div", { className: cn("stn-widget__loading", className), ...rest, children: children ?? /* @__PURE__ */ jsx49(StnLoadingSkeleton.Widget, { lines }) });
|
|
6660
6779
|
}
|
|
6661
6780
|
function StnWidgetInsetIcon({ className, size = "sm", ...rest }) {
|
|
6662
|
-
return /* @__PURE__ */
|
|
6781
|
+
return /* @__PURE__ */ jsx49(StnIconBox, { size, className: cn("stn-widget__inset-icon", className), ...rest });
|
|
6663
6782
|
}
|
|
6664
6783
|
var StnWidget = Object.assign(StnWidgetRoot, {
|
|
6665
6784
|
Header: StnWidgetHeader,
|
|
@@ -6706,11 +6825,11 @@ import {
|
|
|
6706
6825
|
// src/layouts/StnStack.tsx
|
|
6707
6826
|
import {
|
|
6708
6827
|
Children as Children3,
|
|
6709
|
-
forwardRef as
|
|
6828
|
+
forwardRef as forwardRef26,
|
|
6710
6829
|
Fragment as Fragment6,
|
|
6711
6830
|
isValidElement as isValidElement6
|
|
6712
6831
|
} from "react";
|
|
6713
|
-
import { jsx as
|
|
6832
|
+
import { jsx as jsx50, jsxs as jsxs41 } from "react/jsx-runtime";
|
|
6714
6833
|
var BREAKPOINTS = ["xs", "sm", "md", "lg", "xl"];
|
|
6715
6834
|
var DIRECTION_CLASS = /* @__PURE__ */ new Set(["row", "row-reverse", "column", "column-reverse"]);
|
|
6716
6835
|
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]);
|
|
@@ -6803,7 +6922,7 @@ function spacingClassesAndStyle(spacing) {
|
|
|
6803
6922
|
}
|
|
6804
6923
|
return { classes, inlineGap };
|
|
6805
6924
|
}
|
|
6806
|
-
var StnStack =
|
|
6925
|
+
var StnStack = forwardRef26(function StnStack2({
|
|
6807
6926
|
component,
|
|
6808
6927
|
as,
|
|
6809
6928
|
direction = "column",
|
|
@@ -6833,12 +6952,12 @@ var StnStack = forwardRef25(function StnStack2({
|
|
|
6833
6952
|
const validChildren = Children3.toArray(children).filter(Boolean);
|
|
6834
6953
|
const renderedChildren = divider ? validChildren.map((child, index) => {
|
|
6835
6954
|
const key = isValidElement6(child) && child.key != null ? child.key : index;
|
|
6836
|
-
return /* @__PURE__ */
|
|
6955
|
+
return /* @__PURE__ */ jsxs41(Fragment6, { children: [
|
|
6837
6956
|
index > 0 ? divider : null,
|
|
6838
6957
|
child
|
|
6839
6958
|
] }, key);
|
|
6840
6959
|
}) : children;
|
|
6841
|
-
return /* @__PURE__ */
|
|
6960
|
+
return /* @__PURE__ */ jsx50(
|
|
6842
6961
|
Component,
|
|
6843
6962
|
{
|
|
6844
6963
|
ref,
|
|
@@ -6862,7 +6981,7 @@ var StnStack = forwardRef25(function StnStack2({
|
|
|
6862
6981
|
});
|
|
6863
6982
|
|
|
6864
6983
|
// src/patterns/dashboard/AlertCenterDashboard.tsx
|
|
6865
|
-
import { jsx as
|
|
6984
|
+
import { jsx as jsx51, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
6866
6985
|
var TOP5_ROWS = [
|
|
6867
6986
|
{ label: "\uADF8\uB791\uC2DC\uC544", percent: 80, value: "80\uAC74", grade: "critical" },
|
|
6868
6987
|
{ label: "\uC5F0\uB9BD\uC8FC\uD0DD 15\uC138\uB300", percent: 74, value: "74\uAC74", grade: "major" },
|
|
@@ -6871,7 +6990,7 @@ var TOP5_ROWS = [
|
|
|
6871
6990
|
{ label: "PRADA", percent: 68, value: "68\uAC74", grade: "default" }
|
|
6872
6991
|
];
|
|
6873
6992
|
function AlertCenterDashboard({ className, appearance = "translucent", loading = false }) {
|
|
6874
|
-
return /* @__PURE__ */
|
|
6993
|
+
return /* @__PURE__ */ jsxs42(
|
|
6875
6994
|
StnStack,
|
|
6876
6995
|
{
|
|
6877
6996
|
direction: "column",
|
|
@@ -6880,17 +6999,17 @@ function AlertCenterDashboard({ className, appearance = "translucent", loading =
|
|
|
6880
6999
|
style: { flex: "1 1 0%", minHeight: 0, height: "100%", width: "100%" },
|
|
6881
7000
|
"data-stn-dashboard": "alert-widgets",
|
|
6882
7001
|
children: [
|
|
6883
|
-
/* @__PURE__ */
|
|
6884
|
-
/* @__PURE__ */
|
|
6885
|
-
/* @__PURE__ */
|
|
6886
|
-
/* @__PURE__ */
|
|
7002
|
+
/* @__PURE__ */ jsx51(StnWidget, { title: "\uC2DC\uC124 \uD604\uD669", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx51(StnLoadingSkeleton.Widget, { lines: 3 }) : /* @__PURE__ */ jsxs42(StnWidget.StatusList, { children: [
|
|
7003
|
+
/* @__PURE__ */ jsx51(StnWidget.StatusItem, { label: "PTN", value: "179", showDot: false }),
|
|
7004
|
+
/* @__PURE__ */ jsx51(StnWidget.StatusItem, { label: "MSPP", value: "63", showDot: false }),
|
|
7005
|
+
/* @__PURE__ */ jsx51(StnWidget.StatusItem, { label: "L3\uC2A4\uC704\uCE58", value: "27", showDot: false })
|
|
6887
7006
|
] }) }),
|
|
6888
|
-
/* @__PURE__ */
|
|
6889
|
-
/* @__PURE__ */
|
|
6890
|
-
/* @__PURE__ */
|
|
6891
|
-
/* @__PURE__ */
|
|
7007
|
+
/* @__PURE__ */ jsx51(StnWidget, { title: "\uC7A5\uC560 \uD604\uD669", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx51(StnLoadingSkeleton.Widget, { lines: 3 }) : /* @__PURE__ */ jsxs42(StnWidget.StatusList, { children: [
|
|
7008
|
+
/* @__PURE__ */ jsx51(StnWidget.StatusItem, { label: "Critical", value: "43", grade: "critical" }),
|
|
7009
|
+
/* @__PURE__ */ jsx51(StnWidget.StatusItem, { label: "Major", value: "79", grade: "major" }),
|
|
7010
|
+
/* @__PURE__ */ jsx51(StnWidget.StatusItem, { label: "Minor", value: "3", grade: "minor" })
|
|
6892
7011
|
] }) }),
|
|
6893
|
-
/* @__PURE__ */
|
|
7012
|
+
/* @__PURE__ */ jsx51(StnWidget, { title: "\uC77C\uC77C \uC7A5\uBE44\uBCC4 \uC7A5\uC560 TOP5", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx51(StnLoadingSkeleton.Widget, { lines: 4 }) : /* @__PURE__ */ jsx51(StnWidget.GradeRowList, { children: TOP5_ROWS.map((row) => /* @__PURE__ */ jsx51(
|
|
6894
7013
|
StnWidget.GradeRow,
|
|
6895
7014
|
{
|
|
6896
7015
|
grade: row.grade,
|
|
@@ -6900,50 +7019,50 @@ function AlertCenterDashboard({ className, appearance = "translucent", loading =
|
|
|
6900
7019
|
},
|
|
6901
7020
|
row.label
|
|
6902
7021
|
)) }) }),
|
|
6903
|
-
/* @__PURE__ */
|
|
7022
|
+
/* @__PURE__ */ jsx51(StnWidget, { title: "\uC77C\uC77C \uC7A5\uC560 \uD1B5\uACC4", appearance, interactive: true, children: loading ? /* @__PURE__ */ jsx51(StnLoadingSkeleton.Widget, { lines: 3 }) : /* @__PURE__ */ jsx51(StnWidget.ChartSlot, { label: "\uC77C\uC77C \uC7A5\uC560 \uD1B5\uACC4 \uCC28\uD2B8" }) })
|
|
6904
7023
|
]
|
|
6905
7024
|
}
|
|
6906
7025
|
);
|
|
6907
7026
|
}
|
|
6908
7027
|
|
|
6909
7028
|
// src/patterns/dashboard/PubDashboardWidgetBodies.tsx
|
|
6910
|
-
import { jsx as
|
|
7029
|
+
import { jsx as jsx52, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
6911
7030
|
function PubDisabilityStatusList({ items, summary }) {
|
|
6912
|
-
return /* @__PURE__ */
|
|
6913
|
-
/* @__PURE__ */
|
|
7031
|
+
return /* @__PURE__ */ jsxs43("div", { className: "ds-disability-status", children: [
|
|
7032
|
+
/* @__PURE__ */ jsx52("ul", { className: "ds-disability-status__list", children: items.map((item, i) => /* @__PURE__ */ jsxs43(
|
|
6914
7033
|
"li",
|
|
6915
7034
|
{
|
|
6916
7035
|
className: ["ds-disability-status__item", item.grade].filter(Boolean).join(" "),
|
|
6917
7036
|
children: [
|
|
6918
|
-
/* @__PURE__ */
|
|
6919
|
-
item.showDot !== false && item.grade ? /* @__PURE__ */
|
|
7037
|
+
/* @__PURE__ */ jsxs43("span", { children: [
|
|
7038
|
+
item.showDot !== false && item.grade ? /* @__PURE__ */ jsx52("span", { className: "dot", "aria-hidden": true }) : null,
|
|
6920
7039
|
item.label
|
|
6921
7040
|
] }),
|
|
6922
|
-
/* @__PURE__ */
|
|
7041
|
+
/* @__PURE__ */ jsx52("p", { children: item.value })
|
|
6923
7042
|
]
|
|
6924
7043
|
},
|
|
6925
7044
|
i
|
|
6926
7045
|
)) }),
|
|
6927
|
-
summary && summary.length > 0 ? /* @__PURE__ */
|
|
7046
|
+
summary && summary.length > 0 ? /* @__PURE__ */ jsx52("div", { className: "ds-disability-status__summary", children: summary.map((row, i) => /* @__PURE__ */ jsxs43("p", { className: "ds-disability-status__value", children: [
|
|
6928
7047
|
row.label,
|
|
6929
|
-
/* @__PURE__ */
|
|
7048
|
+
/* @__PURE__ */ jsx52("span", { children: row.value })
|
|
6930
7049
|
] }, i)) }) : null
|
|
6931
7050
|
] });
|
|
6932
7051
|
}
|
|
6933
7052
|
function PubTrafficTop5Bars({ rows }) {
|
|
6934
7053
|
const maxPercent = Math.max(...rows.map((row) => row.percent), 0);
|
|
6935
|
-
return /* @__PURE__ */
|
|
6936
|
-
/* @__PURE__ */
|
|
6937
|
-
/* @__PURE__ */
|
|
6938
|
-
/* @__PURE__ */
|
|
7054
|
+
return /* @__PURE__ */ jsx52("div", { className: "ds-bar-group", children: rows.map((row) => /* @__PURE__ */ jsxs43("div", { className: ["ds-bar", row.percent === maxPercent ? "max" : ""].filter(Boolean).join(" "), children: [
|
|
7055
|
+
/* @__PURE__ */ jsx52("p", { className: "ds-bar-name", title: row.label, children: row.label }),
|
|
7056
|
+
/* @__PURE__ */ jsx52("div", { className: "ds-bar-con", title: `${row.percent}%`, children: /* @__PURE__ */ jsx52("span", { className: "ds-bar-gauge", style: { "--percent": `${row.percent}%` } }) }),
|
|
7057
|
+
/* @__PURE__ */ jsx52("p", { className: "ds-bar-value", title: row.value, children: row.value })
|
|
6939
7058
|
] }, row.label)) });
|
|
6940
7059
|
}
|
|
6941
7060
|
function PubTop5EquipmentBars({ rows }) {
|
|
6942
|
-
return /* @__PURE__ */
|
|
6943
|
-
/* @__PURE__ */
|
|
6944
|
-
/* @__PURE__ */
|
|
6945
|
-
/* @__PURE__ */
|
|
6946
|
-
/* @__PURE__ */
|
|
7061
|
+
return /* @__PURE__ */ jsxs43("div", { className: "ds-group", children: [
|
|
7062
|
+
/* @__PURE__ */ jsx52("div", { className: "ds-group-box", children: /* @__PURE__ */ jsx52("div", { className: "ds-equipment-ico", children: /* @__PURE__ */ jsx52("span", { className: "blind", children: "\uC7A5\uBE44 \uC774\uBBF8\uC9C0" }) }) }),
|
|
7063
|
+
/* @__PURE__ */ jsx52("div", { className: "ds-group-box", children: /* @__PURE__ */ jsx52("div", { className: "ds-bar-group", children: rows.map((row) => /* @__PURE__ */ jsx52("div", { className: "ds-bar type-2", children: /* @__PURE__ */ jsxs43("div", { className: "ds-bar-con", title: `${row.percent}%`, children: [
|
|
7064
|
+
/* @__PURE__ */ jsx52("span", { className: "ds-bar-gauge", style: { "--percent": `${row.percent}%` } }),
|
|
7065
|
+
/* @__PURE__ */ jsx52("div", { className: "ds-bar-status", children: row.status })
|
|
6947
7066
|
] }) }, row.label)) }) })
|
|
6948
7067
|
] });
|
|
6949
7068
|
}
|
|
@@ -6952,15 +7071,15 @@ function PubChartSample({
|
|
|
6952
7071
|
alt = "\uCC28\uD2B8",
|
|
6953
7072
|
onError
|
|
6954
7073
|
}) {
|
|
6955
|
-
return /* @__PURE__ */
|
|
7074
|
+
return /* @__PURE__ */ jsx52("div", { className: "ds-chart", children: /* @__PURE__ */ jsx52("img", { src, alt, className: "chart_sample", onError }) });
|
|
6956
7075
|
}
|
|
6957
7076
|
|
|
6958
7077
|
// src/patterns/alertCenter/StnAlertCenterPanel.tsx
|
|
6959
|
-
import { useState as
|
|
7078
|
+
import { useState as useState15 } from "react";
|
|
6960
7079
|
import {
|
|
6961
7080
|
STN_ALERT_CENTER_TABS
|
|
6962
7081
|
} from "@stn-uiux/pub-ui/data/stnAlertCenter";
|
|
6963
|
-
import { jsx as
|
|
7082
|
+
import { jsx as jsx53, jsxs as jsxs44 } from "react/jsx-runtime";
|
|
6964
7083
|
function resolveAlertIcon(item) {
|
|
6965
7084
|
if (item.icon) {
|
|
6966
7085
|
if (item.icon === "line/arrow-down") return "line/arrow-narrow-down";
|
|
@@ -6987,7 +7106,7 @@ function StnAlertCard({
|
|
|
6987
7106
|
}) {
|
|
6988
7107
|
const iconNode = resolveAlertIcon(item);
|
|
6989
7108
|
const gradeLabel = resolveGradeLabel(item.grade);
|
|
6990
|
-
return /* @__PURE__ */
|
|
7109
|
+
return /* @__PURE__ */ jsx53(
|
|
6991
7110
|
StnCard,
|
|
6992
7111
|
{
|
|
6993
7112
|
variant: "elevated",
|
|
@@ -6996,8 +7115,8 @@ function StnAlertCard({
|
|
|
6996
7115
|
interactive: true,
|
|
6997
7116
|
className: cn("stn-alert-card", className),
|
|
6998
7117
|
onClick,
|
|
6999
|
-
children: /* @__PURE__ */
|
|
7000
|
-
/* @__PURE__ */
|
|
7118
|
+
children: /* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__row", children: [
|
|
7119
|
+
/* @__PURE__ */ jsx53(
|
|
7001
7120
|
StnIcon,
|
|
7002
7121
|
{
|
|
7003
7122
|
name: iconNode,
|
|
@@ -7006,9 +7125,9 @@ function StnAlertCard({
|
|
|
7006
7125
|
className: "stn-alert-card__icon"
|
|
7007
7126
|
}
|
|
7008
7127
|
),
|
|
7009
|
-
/* @__PURE__ */
|
|
7010
|
-
/* @__PURE__ */
|
|
7011
|
-
/* @__PURE__ */
|
|
7128
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__body", children: [
|
|
7129
|
+
/* @__PURE__ */ jsxs44(StnStack, { direction: "row", alignItems: "center", spacing: 1, className: "stn-alert-card__header-line", children: [
|
|
7130
|
+
/* @__PURE__ */ jsx53(
|
|
7012
7131
|
StnChip,
|
|
7013
7132
|
{
|
|
7014
7133
|
shape: "pill",
|
|
@@ -7018,25 +7137,25 @@ function StnAlertCard({
|
|
|
7018
7137
|
children: gradeLabel
|
|
7019
7138
|
}
|
|
7020
7139
|
),
|
|
7021
|
-
/* @__PURE__ */
|
|
7140
|
+
/* @__PURE__ */ jsx53(
|
|
7022
7141
|
"span",
|
|
7023
7142
|
{
|
|
7024
7143
|
className: cn("stn-alert-card__title", titleOverflow),
|
|
7025
7144
|
title: item.title,
|
|
7026
|
-
children: /* @__PURE__ */
|
|
7145
|
+
children: /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__text-inner", children: item.title })
|
|
7027
7146
|
}
|
|
7028
7147
|
)
|
|
7029
7148
|
] }),
|
|
7030
|
-
/* @__PURE__ */
|
|
7031
|
-
/* @__PURE__ */
|
|
7149
|
+
/* @__PURE__ */ jsxs44(StnStack, { direction: "row", alignItems: "center", spacing: 2, wrap: "wrap", className: "stn-alert-card__desc-line", children: [
|
|
7150
|
+
/* @__PURE__ */ jsx53(
|
|
7032
7151
|
"span",
|
|
7033
7152
|
{
|
|
7034
7153
|
className: cn("stn-alert-card__desc", descOverflow),
|
|
7035
7154
|
title: item.description,
|
|
7036
|
-
children: /* @__PURE__ */
|
|
7155
|
+
children: /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__text-inner", children: item.description })
|
|
7037
7156
|
}
|
|
7038
7157
|
),
|
|
7039
|
-
item.occurredAt && /* @__PURE__ */
|
|
7158
|
+
item.occurredAt && /* @__PURE__ */ jsxs44(
|
|
7040
7159
|
StnChip,
|
|
7041
7160
|
{
|
|
7042
7161
|
shape: "pill",
|
|
@@ -7052,9 +7171,9 @@ function StnAlertCard({
|
|
|
7052
7171
|
)
|
|
7053
7172
|
] })
|
|
7054
7173
|
] }),
|
|
7055
|
-
/* @__PURE__ */
|
|
7056
|
-
/* @__PURE__ */
|
|
7057
|
-
item.unread !== false && /* @__PURE__ */
|
|
7174
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__meta", children: [
|
|
7175
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-alert-card__time", children: item.time }),
|
|
7176
|
+
item.unread !== false && /* @__PURE__ */ jsx53(
|
|
7058
7177
|
"span",
|
|
7059
7178
|
{
|
|
7060
7179
|
className: cn(
|
|
@@ -7088,11 +7207,11 @@ function StnAlertCenterPanel({
|
|
|
7088
7207
|
closeLabel = "\uB2EB\uAE30",
|
|
7089
7208
|
className
|
|
7090
7209
|
}) {
|
|
7091
|
-
const [activeTab, setActiveTab] =
|
|
7210
|
+
const [activeTab, setActiveTab] = useState15(defaultTab);
|
|
7092
7211
|
const alertCount = alerts.length;
|
|
7093
7212
|
const resolvedTitleOverflow = titleOverflow ?? textOverflow;
|
|
7094
7213
|
const resolvedDescOverflow = descOverflow ?? textOverflow;
|
|
7095
|
-
return /* @__PURE__ */
|
|
7214
|
+
return /* @__PURE__ */ jsxs44(
|
|
7096
7215
|
"div",
|
|
7097
7216
|
{
|
|
7098
7217
|
className: cn(
|
|
@@ -7104,13 +7223,13 @@ function StnAlertCenterPanel({
|
|
|
7104
7223
|
),
|
|
7105
7224
|
"data-stn-alert-center": true,
|
|
7106
7225
|
children: [
|
|
7107
|
-
/* @__PURE__ */
|
|
7108
|
-
/* @__PURE__ */
|
|
7109
|
-
/* @__PURE__ */
|
|
7110
|
-
/* @__PURE__ */
|
|
7111
|
-
alertCount > 0 && /* @__PURE__ */
|
|
7226
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-center__header", children: [
|
|
7227
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-center__header-left", children: [
|
|
7228
|
+
/* @__PURE__ */ jsx53(StnIcon, { name: "line/bell", size: 20, color: "var(--stn-primary)" }),
|
|
7229
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-alert-center__title", children: title }),
|
|
7230
|
+
alertCount > 0 && /* @__PURE__ */ jsx53(StnChip, { shape: "pill", size: "sm", variant: "subtle", color: "primary", children: alertCount })
|
|
7112
7231
|
] }),
|
|
7113
|
-
/* @__PURE__ */
|
|
7232
|
+
/* @__PURE__ */ jsx53(
|
|
7114
7233
|
StnSegmented,
|
|
7115
7234
|
{
|
|
7116
7235
|
size: "md",
|
|
@@ -7123,8 +7242,8 @@ function StnAlertCenterPanel({
|
|
|
7123
7242
|
}))
|
|
7124
7243
|
}
|
|
7125
7244
|
),
|
|
7126
|
-
/* @__PURE__ */
|
|
7127
|
-
/* @__PURE__ */
|
|
7245
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-center__header-right", children: [
|
|
7246
|
+
/* @__PURE__ */ jsx53(
|
|
7128
7247
|
StnButton,
|
|
7129
7248
|
{
|
|
7130
7249
|
variant: "text",
|
|
@@ -7134,8 +7253,8 @@ function StnAlertCenterPanel({
|
|
|
7134
7253
|
children: "\uBAA8\uB450 \uC77D\uC74C"
|
|
7135
7254
|
}
|
|
7136
7255
|
),
|
|
7137
|
-
/* @__PURE__ */
|
|
7138
|
-
/* @__PURE__ */
|
|
7256
|
+
/* @__PURE__ */ jsx53("div", { className: "stn-alert-center__divider", "aria-hidden": true }),
|
|
7257
|
+
/* @__PURE__ */ jsx53(
|
|
7139
7258
|
StnButton,
|
|
7140
7259
|
{
|
|
7141
7260
|
icon: "line/x",
|
|
@@ -7147,8 +7266,8 @@ function StnAlertCenterPanel({
|
|
|
7147
7266
|
)
|
|
7148
7267
|
] })
|
|
7149
7268
|
] }),
|
|
7150
|
-
/* @__PURE__ */
|
|
7151
|
-
activeTab === "error" && /* @__PURE__ */
|
|
7269
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-center__list-wrap", children: [
|
|
7270
|
+
activeTab === "error" && /* @__PURE__ */ jsx53("ul", { className: "stn-alert-center__list", children: alerts.map((item) => /* @__PURE__ */ jsx53("li", { children: /* @__PURE__ */ jsx53(
|
|
7152
7271
|
StnAlertCard,
|
|
7153
7272
|
{
|
|
7154
7273
|
item,
|
|
@@ -7157,33 +7276,33 @@ function StnAlertCenterPanel({
|
|
|
7157
7276
|
onClick: () => onItemClick?.(item)
|
|
7158
7277
|
}
|
|
7159
7278
|
) }, item.id ?? item.title)) }),
|
|
7160
|
-
activeTab === "work" && /* @__PURE__ */
|
|
7161
|
-
/* @__PURE__ */
|
|
7162
|
-
/* @__PURE__ */
|
|
7163
|
-
/* @__PURE__ */
|
|
7164
|
-
/* @__PURE__ */
|
|
7279
|
+
activeTab === "work" && /* @__PURE__ */ jsx53("ul", { className: "stn-alert-center__list", children: workItems.map((row) => /* @__PURE__ */ jsx53("li", { children: /* @__PURE__ */ jsx53(StnCard, { variant: "elevated", radius: "md", padding: "md", interactive: true, className: "stn-alert-card", children: /* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__row", children: [
|
|
7280
|
+
/* @__PURE__ */ jsx53(StnIcon, { name: "line/clock", size: 24, color: "var(--stn-text-secondary)", className: "stn-alert-card__icon" }),
|
|
7281
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__body", children: [
|
|
7282
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-alert-card__type-label work", children: row.typeLabel }),
|
|
7283
|
+
/* @__PURE__ */ jsx53("span", { className: cn("stn-alert-card__desc", resolvedDescOverflow), title: row.text, children: /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__text-inner", children: row.text }) })
|
|
7165
7284
|
] }),
|
|
7166
|
-
/* @__PURE__ */
|
|
7285
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-alert-card__time", children: row.time })
|
|
7167
7286
|
] }) }) }, row.id ?? row.text)) }),
|
|
7168
|
-
activeTab === "deploy" && /* @__PURE__ */
|
|
7169
|
-
/* @__PURE__ */
|
|
7170
|
-
/* @__PURE__ */
|
|
7171
|
-
/* @__PURE__ */
|
|
7172
|
-
/* @__PURE__ */
|
|
7287
|
+
activeTab === "deploy" && /* @__PURE__ */ jsx53("ul", { className: "stn-alert-center__list", children: deployItems.map((row) => /* @__PURE__ */ jsx53("li", { children: /* @__PURE__ */ jsx53(StnCard, { variant: "elevated", radius: "md", padding: "md", interactive: true, className: "stn-alert-card", children: /* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__row", children: [
|
|
7288
|
+
/* @__PURE__ */ jsx53(StnIcon, { name: "line/settings", size: 24, color: "var(--stn-secondary)", className: "stn-alert-card__icon" }),
|
|
7289
|
+
/* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__body", children: [
|
|
7290
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-alert-card__type-label stn-alert-card__type-label--deploy", children: row.typeLabel }),
|
|
7291
|
+
/* @__PURE__ */ jsx53("span", { className: cn("stn-alert-card__desc", resolvedDescOverflow), title: row.text, children: /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__text-inner", children: row.text }) })
|
|
7173
7292
|
] }),
|
|
7174
|
-
/* @__PURE__ */
|
|
7293
|
+
/* @__PURE__ */ jsx53("span", { className: "stn-alert-card__time", children: row.time })
|
|
7175
7294
|
] }) }) }, row.id ?? row.text)) })
|
|
7176
7295
|
] }),
|
|
7177
|
-
/* @__PURE__ */
|
|
7296
|
+
/* @__PURE__ */ jsx53("div", { className: "stn-alert-center__footer", children: /* @__PURE__ */ jsxs44(
|
|
7178
7297
|
"button",
|
|
7179
7298
|
{
|
|
7180
7299
|
type: "button",
|
|
7181
7300
|
className: "stn-alert-center__footer-link",
|
|
7182
7301
|
onClick: onManageSettings,
|
|
7183
7302
|
children: [
|
|
7184
|
-
/* @__PURE__ */
|
|
7185
|
-
/* @__PURE__ */
|
|
7186
|
-
/* @__PURE__ */
|
|
7303
|
+
/* @__PURE__ */ jsx53("span", { children: "\uC54C\uB9BC \uC124\uC815 \uAD00\uB9AC" }),
|
|
7304
|
+
/* @__PURE__ */ jsx53(StnIcon, { name: "line/settings", size: 14 }),
|
|
7305
|
+
/* @__PURE__ */ jsx53(StnIcon, { name: "line/chevron-right", size: 14 })
|
|
7187
7306
|
]
|
|
7188
7307
|
}
|
|
7189
7308
|
) })
|
|
@@ -7193,18 +7312,18 @@ function StnAlertCenterPanel({
|
|
|
7193
7312
|
}
|
|
7194
7313
|
|
|
7195
7314
|
// src/patterns/alertCenter/StnAlertCenterDocPreview.tsx
|
|
7196
|
-
import { jsx as
|
|
7315
|
+
import { jsx as jsx54 } from "react/jsx-runtime";
|
|
7197
7316
|
function StnAlertCenterDocPreview({
|
|
7198
7317
|
theme = "light",
|
|
7199
7318
|
withDocChrome = true,
|
|
7200
7319
|
children,
|
|
7201
7320
|
...panelProps
|
|
7202
7321
|
}) {
|
|
7203
|
-
const panel = children ?? /* @__PURE__ */
|
|
7322
|
+
const panel = children ?? /* @__PURE__ */ jsx54(StnAlertCenterPanel, { ...panelProps });
|
|
7204
7323
|
if (!withDocChrome) {
|
|
7205
|
-
return /* @__PURE__ */
|
|
7324
|
+
return /* @__PURE__ */ jsx54(StnProvider, { theme, applyThemeToDocument: false, children: panel });
|
|
7206
7325
|
}
|
|
7207
|
-
return /* @__PURE__ */
|
|
7326
|
+
return /* @__PURE__ */ jsx54("div", { className: "stn-doc-frame stn-doc-frame--alert-center", "data-theme": theme, children: /* @__PURE__ */ jsx54("div", { className: "stn-alert-center-preview-shell", children: panel }) });
|
|
7208
7327
|
}
|
|
7209
7328
|
|
|
7210
7329
|
// src/index.ts
|
|
@@ -7229,13 +7348,13 @@ var SideNavContext = createContext3({
|
|
|
7229
7348
|
var useSideNav = () => useContext3(SideNavContext);
|
|
7230
7349
|
|
|
7231
7350
|
// src/components/sideNav/StnSideNavItem.tsx
|
|
7232
|
-
import { forwardRef as
|
|
7351
|
+
import { forwardRef as forwardRef27 } from "react";
|
|
7233
7352
|
import { STN_NAV_MENU_SUB_ICON } from "@stn-uiux/pub-ui/data/stnSideNavItem";
|
|
7234
|
-
import { jsx as
|
|
7353
|
+
import { jsx as jsx55, jsxs as jsxs45 } from "react/jsx-runtime";
|
|
7235
7354
|
function maskStyle2(src) {
|
|
7236
7355
|
return { maskImage: `url('${src}')`, WebkitMaskImage: `url('${src}')` };
|
|
7237
7356
|
}
|
|
7238
|
-
var StnSideNavItem =
|
|
7357
|
+
var StnSideNavItem = forwardRef27(function StnSideNavItem2({
|
|
7239
7358
|
label,
|
|
7240
7359
|
id,
|
|
7241
7360
|
iconSrc,
|
|
@@ -7278,13 +7397,13 @@ var StnSideNavItem = forwardRef26(function StnSideNavItem2({
|
|
|
7278
7397
|
sideNav.onSelect(id);
|
|
7279
7398
|
}
|
|
7280
7399
|
};
|
|
7281
|
-
const iconElement = hasIcon && !isSub ? /* @__PURE__ */
|
|
7282
|
-
/* @__PURE__ */
|
|
7283
|
-
showDot ? /* @__PURE__ */
|
|
7400
|
+
const iconElement = hasIcon && !isSub ? /* @__PURE__ */ jsxs45("span", { className: "stn-side-nav-item__icon-wrap", children: [
|
|
7401
|
+
/* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__icon", "aria-hidden": "true", children: icon ?? (resolvedIconSrc ? /* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__icon-glyph", style: maskStyle2(resolvedIconSrc) }) : null) }),
|
|
7402
|
+
showDot ? /* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__dot-wrap", "aria-hidden": "true", children: /* @__PURE__ */ jsx55(StnBadge, { variant: "dot", color: "error" }) }) : null
|
|
7284
7403
|
] }) : null;
|
|
7285
|
-
const subIconElement = hasIcon && isSub ? /* @__PURE__ */
|
|
7404
|
+
const subIconElement = hasIcon && isSub ? /* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__sub-icon", "aria-hidden": "true", children: icon ?? (resolvedIconSrc ? /* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__icon-glyph", style: maskStyle2(resolvedIconSrc) }) : null) }) : null;
|
|
7286
7405
|
const activeIconElement = isSub ? subIconElement : iconElement;
|
|
7287
|
-
return /* @__PURE__ */
|
|
7406
|
+
return /* @__PURE__ */ jsx55(
|
|
7288
7407
|
"button",
|
|
7289
7408
|
{
|
|
7290
7409
|
ref,
|
|
@@ -7303,10 +7422,10 @@ var StnSideNavItem = forwardRef26(function StnSideNavItem2({
|
|
|
7303
7422
|
title: collapsed ? label : void 0,
|
|
7304
7423
|
onClick: handleClick,
|
|
7305
7424
|
...rest,
|
|
7306
|
-
children: /* @__PURE__ */
|
|
7307
|
-
/* @__PURE__ */
|
|
7308
|
-
isSub && showSubIndent ? /* @__PURE__ */
|
|
7309
|
-
shouldShowSubDot ? /* @__PURE__ */
|
|
7425
|
+
children: /* @__PURE__ */ jsxs45("span", { className: cn("stn-side-nav-item__inner", spreadTrail && "spread"), children: [
|
|
7426
|
+
/* @__PURE__ */ jsxs45("span", { className: "stn-side-nav-item__lead", children: [
|
|
7427
|
+
isSub && showSubIndent ? /* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__sub-indent", "aria-hidden": "true" }) : null,
|
|
7428
|
+
shouldShowSubDot ? /* @__PURE__ */ jsx55(
|
|
7310
7429
|
"span",
|
|
7311
7430
|
{
|
|
7312
7431
|
className: cn(
|
|
@@ -7314,14 +7433,14 @@ var StnSideNavItem = forwardRef26(function StnSideNavItem2({
|
|
|
7314
7433
|
hasIcon && iconPosition === "left" && "compact"
|
|
7315
7434
|
),
|
|
7316
7435
|
"aria-hidden": "true",
|
|
7317
|
-
children: /* @__PURE__ */
|
|
7436
|
+
children: /* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__sub-dot-glyph", style: maskStyle2(STN_NAV_MENU_SUB_ICON) })
|
|
7318
7437
|
}
|
|
7319
7438
|
) : null,
|
|
7320
7439
|
iconPosition === "left" ? activeIconElement : null,
|
|
7321
|
-
/* @__PURE__ */
|
|
7440
|
+
/* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__label", children: label })
|
|
7322
7441
|
] }),
|
|
7323
7442
|
iconPosition === "right" ? activeIconElement : null,
|
|
7324
|
-
renderBadge ? typeof badge === "string" || typeof badge === "number" ? /* @__PURE__ */
|
|
7443
|
+
renderBadge ? typeof badge === "string" || typeof badge === "number" ? /* @__PURE__ */ jsx55(
|
|
7325
7444
|
StnBadge,
|
|
7326
7445
|
{
|
|
7327
7446
|
badgeContent: badge,
|
|
@@ -7329,7 +7448,7 @@ var StnSideNavItem = forwardRef26(function StnSideNavItem2({
|
|
|
7329
7448
|
appearance: "subtle",
|
|
7330
7449
|
className: "stn-side-nav-item__badge"
|
|
7331
7450
|
}
|
|
7332
|
-
) : badge ? /* @__PURE__ */
|
|
7451
|
+
) : badge ? /* @__PURE__ */ jsx55("span", { className: "stn-side-nav-item__badge", children: badge }) : showBadgeDot ? /* @__PURE__ */ jsx55(
|
|
7333
7452
|
StnBadge,
|
|
7334
7453
|
{
|
|
7335
7454
|
variant: "dot",
|
|
@@ -7337,7 +7456,7 @@ var StnSideNavItem = forwardRef26(function StnSideNavItem2({
|
|
|
7337
7456
|
className: "stn-side-nav-item__badge"
|
|
7338
7457
|
}
|
|
7339
7458
|
) : null : null,
|
|
7340
|
-
!isSub && showChevron && !collapsed ? /* @__PURE__ */
|
|
7459
|
+
!isSub && showChevron && !collapsed ? /* @__PURE__ */ jsx55(
|
|
7341
7460
|
"span",
|
|
7342
7461
|
{
|
|
7343
7462
|
className: cn(
|
|
@@ -7354,15 +7473,15 @@ var StnSideNavItem = forwardRef26(function StnSideNavItem2({
|
|
|
7354
7473
|
});
|
|
7355
7474
|
|
|
7356
7475
|
// src/components/sideNav/StnSideNavHeader.tsx
|
|
7357
|
-
import { forwardRef as
|
|
7476
|
+
import { forwardRef as forwardRef29 } from "react";
|
|
7358
7477
|
|
|
7359
7478
|
// src/components/sideNav/StnSideNavLogo.tsx
|
|
7360
|
-
import { forwardRef as
|
|
7361
|
-
import { jsx as
|
|
7362
|
-
var StnSideNavLogo =
|
|
7479
|
+
import { forwardRef as forwardRef28 } from "react";
|
|
7480
|
+
import { jsx as jsx56 } from "react/jsx-runtime";
|
|
7481
|
+
var StnSideNavLogo = forwardRef28(
|
|
7363
7482
|
function StnSideNavLogo2({ className, logoProps, ...rest }, ref) {
|
|
7364
7483
|
const { collapsed } = useSideNav();
|
|
7365
|
-
return /* @__PURE__ */
|
|
7484
|
+
return /* @__PURE__ */ jsx56(
|
|
7366
7485
|
"div",
|
|
7367
7486
|
{
|
|
7368
7487
|
ref,
|
|
@@ -7373,7 +7492,7 @@ var StnSideNavLogo = forwardRef27(
|
|
|
7373
7492
|
),
|
|
7374
7493
|
title: "InfoMap",
|
|
7375
7494
|
...rest,
|
|
7376
|
-
children: /* @__PURE__ */
|
|
7495
|
+
children: /* @__PURE__ */ jsx56(
|
|
7377
7496
|
StnLogo,
|
|
7378
7497
|
{
|
|
7379
7498
|
variant: collapsed ? "onlyimg" : "horizontal",
|
|
@@ -7387,8 +7506,8 @@ var StnSideNavLogo = forwardRef27(
|
|
|
7387
7506
|
);
|
|
7388
7507
|
|
|
7389
7508
|
// src/components/sideNav/StnSideNavHeader.tsx
|
|
7390
|
-
import { Fragment as Fragment7, jsx as
|
|
7391
|
-
var StnSideNavHeader =
|
|
7509
|
+
import { Fragment as Fragment7, jsx as jsx57, jsxs as jsxs46 } from "react/jsx-runtime";
|
|
7510
|
+
var StnSideNavHeader = forwardRef29(function StnSideNavHeader2({
|
|
7392
7511
|
children,
|
|
7393
7512
|
border = false,
|
|
7394
7513
|
hasBorder = false,
|
|
@@ -7400,7 +7519,7 @@ var StnSideNavHeader = forwardRef28(function StnSideNavHeader2({
|
|
|
7400
7519
|
const { collapsed, onToggleCollapse, isDrawer, setMobileOpen } = useSideNav();
|
|
7401
7520
|
const withBorder = Boolean(border || hasBorder);
|
|
7402
7521
|
const shouldShowClose = showClose ?? Boolean(isDrawer);
|
|
7403
|
-
return /* @__PURE__ */
|
|
7522
|
+
return /* @__PURE__ */ jsx57(
|
|
7404
7523
|
"div",
|
|
7405
7524
|
{
|
|
7406
7525
|
ref,
|
|
@@ -7411,9 +7530,9 @@ var StnSideNavHeader = forwardRef28(function StnSideNavHeader2({
|
|
|
7411
7530
|
className
|
|
7412
7531
|
),
|
|
7413
7532
|
...rest,
|
|
7414
|
-
children: children ?? /* @__PURE__ */
|
|
7415
|
-
/* @__PURE__ */
|
|
7416
|
-
shouldShowClose ? /* @__PURE__ */
|
|
7533
|
+
children: children ?? /* @__PURE__ */ jsxs46(Fragment7, { children: [
|
|
7534
|
+
/* @__PURE__ */ jsx57(StnSideNavLogo, {}),
|
|
7535
|
+
shouldShowClose ? /* @__PURE__ */ jsx57(
|
|
7417
7536
|
StnButton,
|
|
7418
7537
|
{
|
|
7419
7538
|
size: "sm",
|
|
@@ -7425,7 +7544,7 @@ var StnSideNavHeader = forwardRef28(function StnSideNavHeader2({
|
|
|
7425
7544
|
className: "stn-side-nav__collapse-btn",
|
|
7426
7545
|
onClick: () => setMobileOpen?.(false)
|
|
7427
7546
|
}
|
|
7428
|
-
) : showToggle ? /* @__PURE__ */
|
|
7547
|
+
) : showToggle ? /* @__PURE__ */ jsx57(
|
|
7429
7548
|
StnButton,
|
|
7430
7549
|
{
|
|
7431
7550
|
size: "sm",
|
|
@@ -7444,16 +7563,16 @@ var StnSideNavHeader = forwardRef28(function StnSideNavHeader2({
|
|
|
7444
7563
|
});
|
|
7445
7564
|
|
|
7446
7565
|
// src/components/sideNav/StnSideNavMenu.tsx
|
|
7447
|
-
import { forwardRef as
|
|
7448
|
-
import { jsx as
|
|
7449
|
-
var StnSideNavMenu =
|
|
7566
|
+
import { forwardRef as forwardRef30 } from "react";
|
|
7567
|
+
import { jsx as jsx58 } from "react/jsx-runtime";
|
|
7568
|
+
var StnSideNavMenu = forwardRef30(function StnSideNavMenu2({
|
|
7450
7569
|
children,
|
|
7451
7570
|
className,
|
|
7452
7571
|
scrollSize = "thin",
|
|
7453
7572
|
scrollColor = "fade",
|
|
7454
7573
|
...rest
|
|
7455
7574
|
}, ref) {
|
|
7456
|
-
return /* @__PURE__ */
|
|
7575
|
+
return /* @__PURE__ */ jsx58(
|
|
7457
7576
|
"nav",
|
|
7458
7577
|
{
|
|
7459
7578
|
ref,
|
|
@@ -7474,13 +7593,13 @@ var StnSideNavMenu = forwardRef29(function StnSideNavMenu2({
|
|
|
7474
7593
|
|
|
7475
7594
|
// src/components/sideNav/StnSideNavGroup.tsx
|
|
7476
7595
|
import {
|
|
7477
|
-
forwardRef as
|
|
7596
|
+
forwardRef as forwardRef31,
|
|
7478
7597
|
useEffect as useEffect10,
|
|
7479
7598
|
useRef as useRef7,
|
|
7480
|
-
useState as
|
|
7599
|
+
useState as useState16
|
|
7481
7600
|
} from "react";
|
|
7482
|
-
import { jsx as
|
|
7483
|
-
var StnSideNavGroup =
|
|
7601
|
+
import { jsx as jsx59, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
7602
|
+
var StnSideNavGroup = forwardRef31(function StnSideNavGroup2({
|
|
7484
7603
|
label,
|
|
7485
7604
|
parent,
|
|
7486
7605
|
direction = "down",
|
|
@@ -7496,7 +7615,7 @@ var StnSideNavGroup = forwardRef30(function StnSideNavGroup2({
|
|
|
7496
7615
|
...rest
|
|
7497
7616
|
}, ref) {
|
|
7498
7617
|
const { collapsed } = useSideNav();
|
|
7499
|
-
const [internalOpen, setInternalOpen] =
|
|
7618
|
+
const [internalOpen, setInternalOpen] = useState16(defaultOpen);
|
|
7500
7619
|
const isOpen = openProp ?? internalOpen;
|
|
7501
7620
|
const isDropdown = Boolean(dropdown || variant === "dropdown");
|
|
7502
7621
|
const isTransparent = dropdownVariant === "transparent" || dropdownBackground === false;
|
|
@@ -7524,7 +7643,7 @@ var StnSideNavGroup = forwardRef30(function StnSideNavGroup2({
|
|
|
7524
7643
|
}
|
|
7525
7644
|
onOpenChange?.(next);
|
|
7526
7645
|
};
|
|
7527
|
-
const subnavNode = children && (!collapsed && isOpen) ? /* @__PURE__ */
|
|
7646
|
+
const subnavNode = children && (!collapsed && isOpen) ? /* @__PURE__ */ jsx59(
|
|
7528
7647
|
"div",
|
|
7529
7648
|
{
|
|
7530
7649
|
className: cn(
|
|
@@ -7539,7 +7658,7 @@ var StnSideNavGroup = forwardRef30(function StnSideNavGroup2({
|
|
|
7539
7658
|
children
|
|
7540
7659
|
}
|
|
7541
7660
|
) : null;
|
|
7542
|
-
return /* @__PURE__ */
|
|
7661
|
+
return /* @__PURE__ */ jsxs47(
|
|
7543
7662
|
"div",
|
|
7544
7663
|
{
|
|
7545
7664
|
ref: (node) => {
|
|
@@ -7560,7 +7679,7 @@ var StnSideNavGroup = forwardRef30(function StnSideNavGroup2({
|
|
|
7560
7679
|
"aria-label": typeof label === "string" ? label : void 0,
|
|
7561
7680
|
...rest,
|
|
7562
7681
|
children: [
|
|
7563
|
-
label && !collapsed ? /* @__PURE__ */
|
|
7682
|
+
label && !collapsed ? /* @__PURE__ */ jsx59("span", { className: "stn-side-nav__group-label", onClick: handleToggle, children: label }) : null,
|
|
7564
7683
|
isUp ? subnavNode : null,
|
|
7565
7684
|
parent,
|
|
7566
7685
|
!isUp ? subnavNode : null
|
|
@@ -7570,10 +7689,10 @@ var StnSideNavGroup = forwardRef30(function StnSideNavGroup2({
|
|
|
7570
7689
|
});
|
|
7571
7690
|
|
|
7572
7691
|
// src/components/sideNav/StnSideNavSpacer.tsx
|
|
7573
|
-
import { forwardRef as
|
|
7574
|
-
import { jsx as
|
|
7575
|
-
var StnSideNavSpacer =
|
|
7576
|
-
return /* @__PURE__ */
|
|
7692
|
+
import { forwardRef as forwardRef32 } from "react";
|
|
7693
|
+
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
7694
|
+
var StnSideNavSpacer = forwardRef32(function StnSideNavSpacer2({ className, style, ...rest }, ref) {
|
|
7695
|
+
return /* @__PURE__ */ jsx60(
|
|
7577
7696
|
"div",
|
|
7578
7697
|
{
|
|
7579
7698
|
ref,
|
|
@@ -7586,10 +7705,10 @@ var StnSideNavSpacer = forwardRef31(function StnSideNavSpacer2({ className, styl
|
|
|
7586
7705
|
});
|
|
7587
7706
|
|
|
7588
7707
|
// src/components/sideNav/StnSideNavFooter.tsx
|
|
7589
|
-
import { forwardRef as
|
|
7590
|
-
import { jsx as
|
|
7591
|
-
var StnSideNavFooter =
|
|
7592
|
-
return /* @__PURE__ */
|
|
7708
|
+
import { forwardRef as forwardRef33 } from "react";
|
|
7709
|
+
import { jsx as jsx61 } from "react/jsx-runtime";
|
|
7710
|
+
var StnSideNavFooter = forwardRef33(function StnSideNavFooter2({ curved = false, children, className, ...rest }, ref) {
|
|
7711
|
+
return /* @__PURE__ */ jsx61(
|
|
7593
7712
|
"nav",
|
|
7594
7713
|
{
|
|
7595
7714
|
ref,
|
|
@@ -7602,12 +7721,12 @@ var StnSideNavFooter = forwardRef32(function StnSideNavFooter2({ curved = false,
|
|
|
7602
7721
|
});
|
|
7603
7722
|
|
|
7604
7723
|
// src/components/sideNav/StnSideNavToggle.tsx
|
|
7605
|
-
import { forwardRef as
|
|
7606
|
-
import { jsx as
|
|
7607
|
-
var StnSideNavToggle =
|
|
7724
|
+
import { forwardRef as forwardRef34 } from "react";
|
|
7725
|
+
import { jsx as jsx62 } from "react/jsx-runtime";
|
|
7726
|
+
var StnSideNavToggle = forwardRef34(
|
|
7608
7727
|
function StnSideNavToggle2({ className, onClick, ...rest }, ref) {
|
|
7609
7728
|
const { collapsed, onToggleCollapse } = useSideNav();
|
|
7610
|
-
return /* @__PURE__ */
|
|
7729
|
+
return /* @__PURE__ */ jsx62(
|
|
7611
7730
|
"button",
|
|
7612
7731
|
{
|
|
7613
7732
|
ref,
|
|
@@ -7620,7 +7739,7 @@ var StnSideNavToggle = forwardRef33(
|
|
|
7620
7739
|
"aria-label": collapsed ? "\uC0AC\uC774\uB4DC\uBC14 \uD3BC\uCE58\uAE30" : "\uC0AC\uC774\uB4DC\uBC14 \uC811\uAE30",
|
|
7621
7740
|
title: collapsed ? "\uC0AC\uC774\uB4DC\uBC14 \uD3BC\uCE58\uAE30" : "\uC0AC\uC774\uB4DC\uBC14 \uC811\uAE30",
|
|
7622
7741
|
...rest,
|
|
7623
|
-
children: /* @__PURE__ */
|
|
7742
|
+
children: /* @__PURE__ */ jsx62(
|
|
7624
7743
|
"svg",
|
|
7625
7744
|
{
|
|
7626
7745
|
width: "12",
|
|
@@ -7631,7 +7750,7 @@ var StnSideNavToggle = forwardRef33(
|
|
|
7631
7750
|
strokeWidth: "2.5",
|
|
7632
7751
|
strokeLinecap: "round",
|
|
7633
7752
|
strokeLinejoin: "round",
|
|
7634
|
-
children: /* @__PURE__ */
|
|
7753
|
+
children: /* @__PURE__ */ jsx62("path", { d: "M9 18l6-6-6-6" })
|
|
7635
7754
|
}
|
|
7636
7755
|
)
|
|
7637
7756
|
}
|
|
@@ -7640,30 +7759,30 @@ var StnSideNavToggle = forwardRef33(
|
|
|
7640
7759
|
);
|
|
7641
7760
|
|
|
7642
7761
|
// src/components/sideNav/StnSideNavWatermark.tsx
|
|
7643
|
-
import { forwardRef as
|
|
7644
|
-
import { jsx as
|
|
7645
|
-
var StnSideNavWatermark =
|
|
7762
|
+
import { forwardRef as forwardRef35 } from "react";
|
|
7763
|
+
import { jsx as jsx63 } from "react/jsx-runtime";
|
|
7764
|
+
var StnSideNavWatermark = forwardRef35(
|
|
7646
7765
|
function StnSideNavWatermark2({ size = "xl", theme, className, ...rest }, ref) {
|
|
7647
|
-
return /* @__PURE__ */
|
|
7766
|
+
return /* @__PURE__ */ jsx63(
|
|
7648
7767
|
"div",
|
|
7649
7768
|
{
|
|
7650
7769
|
ref,
|
|
7651
7770
|
className: cn("stn-side-nav__watermark", className),
|
|
7652
7771
|
"aria-hidden": "true",
|
|
7653
7772
|
...rest,
|
|
7654
|
-
children: /* @__PURE__ */
|
|
7773
|
+
children: /* @__PURE__ */ jsx63(StnLogo, { variant: "watermark", size, theme })
|
|
7655
7774
|
}
|
|
7656
7775
|
);
|
|
7657
7776
|
}
|
|
7658
7777
|
);
|
|
7659
7778
|
|
|
7660
7779
|
// src/components/sideNav/StnSideNavMobileTrigger.tsx
|
|
7661
|
-
import { forwardRef as
|
|
7662
|
-
import { jsx as
|
|
7663
|
-
var StnSideNavMobileTrigger =
|
|
7780
|
+
import { forwardRef as forwardRef36 } from "react";
|
|
7781
|
+
import { jsx as jsx64, jsxs as jsxs48 } from "react/jsx-runtime";
|
|
7782
|
+
var StnSideNavMobileTrigger = forwardRef36(
|
|
7664
7783
|
function StnSideNavMobileTrigger2({ floating = false, className, children, onClick, ...rest }, ref) {
|
|
7665
7784
|
const { onToggleMobileOpen, mobileOpen } = useSideNav();
|
|
7666
|
-
return /* @__PURE__ */
|
|
7785
|
+
return /* @__PURE__ */ jsx64(
|
|
7667
7786
|
"button",
|
|
7668
7787
|
{
|
|
7669
7788
|
ref,
|
|
@@ -7681,10 +7800,10 @@ var StnSideNavMobileTrigger = forwardRef35(
|
|
|
7681
7800
|
onToggleMobileOpen?.();
|
|
7682
7801
|
},
|
|
7683
7802
|
...rest,
|
|
7684
|
-
children: children ?? /* @__PURE__ */
|
|
7685
|
-
/* @__PURE__ */
|
|
7686
|
-
/* @__PURE__ */
|
|
7687
|
-
/* @__PURE__ */
|
|
7803
|
+
children: children ?? /* @__PURE__ */ jsxs48("span", { className: "stn-side-nav__hamburger-bars", "aria-hidden": "true", children: [
|
|
7804
|
+
/* @__PURE__ */ jsx64("span", {}),
|
|
7805
|
+
/* @__PURE__ */ jsx64("span", {}),
|
|
7806
|
+
/* @__PURE__ */ jsx64("span", {})
|
|
7688
7807
|
] })
|
|
7689
7808
|
}
|
|
7690
7809
|
);
|
|
@@ -7693,12 +7812,12 @@ var StnSideNavMobileTrigger = forwardRef35(
|
|
|
7693
7812
|
|
|
7694
7813
|
// src/components/sideNav/StnSideNavSub.tsx
|
|
7695
7814
|
import {
|
|
7696
|
-
forwardRef as
|
|
7815
|
+
forwardRef as forwardRef37
|
|
7697
7816
|
} from "react";
|
|
7698
|
-
import { jsx as
|
|
7699
|
-
var StnSideNavSub =
|
|
7817
|
+
import { jsx as jsx65 } from "react/jsx-runtime";
|
|
7818
|
+
var StnSideNavSub = forwardRef37(
|
|
7700
7819
|
function StnSideNavSub2({ children, className, ...rest }, ref) {
|
|
7701
|
-
return /* @__PURE__ */
|
|
7820
|
+
return /* @__PURE__ */ jsx65(
|
|
7702
7821
|
"div",
|
|
7703
7822
|
{
|
|
7704
7823
|
ref,
|
|
@@ -7711,7 +7830,7 @@ var StnSideNavSub = forwardRef36(
|
|
|
7711
7830
|
);
|
|
7712
7831
|
}
|
|
7713
7832
|
);
|
|
7714
|
-
var StnSideNavSubItem =
|
|
7833
|
+
var StnSideNavSubItem = forwardRef37(
|
|
7715
7834
|
function StnSideNavSubItem2({
|
|
7716
7835
|
variant = "ghost",
|
|
7717
7836
|
size = "md",
|
|
@@ -7727,14 +7846,14 @@ var StnSideNavSubItem = forwardRef36(
|
|
|
7727
7846
|
const { collapsed } = useSideNav();
|
|
7728
7847
|
const content = children ?? label;
|
|
7729
7848
|
const computedTitle = title ?? (typeof content === "string" ? content : void 0);
|
|
7730
|
-
const resolvedIcon = icon ?? (iconSrc ? /* @__PURE__ */
|
|
7849
|
+
const resolvedIcon = icon ?? (iconSrc ? /* @__PURE__ */ jsx65("span", { className: "stn-side-nav__sub-icon", children: /* @__PURE__ */ jsx65(
|
|
7731
7850
|
"span",
|
|
7732
7851
|
{
|
|
7733
7852
|
className: "stn-side-nav__sub-glyph",
|
|
7734
7853
|
style: { maskImage: `url('${iconSrc}')`, WebkitMaskImage: `url('${iconSrc}')` }
|
|
7735
7854
|
}
|
|
7736
7855
|
) }) : null);
|
|
7737
|
-
return /* @__PURE__ */
|
|
7856
|
+
return /* @__PURE__ */ jsx65(
|
|
7738
7857
|
StnButton,
|
|
7739
7858
|
{
|
|
7740
7859
|
ref,
|
|
@@ -7753,9 +7872,9 @@ var StnSideNavSubItem = forwardRef36(
|
|
|
7753
7872
|
);
|
|
7754
7873
|
|
|
7755
7874
|
// src/components/sideNav/StnSideNavSubNav.tsx
|
|
7756
|
-
import { forwardRef as
|
|
7757
|
-
import { jsx as
|
|
7758
|
-
var StnSideNavSubNav =
|
|
7875
|
+
import { forwardRef as forwardRef38 } from "react";
|
|
7876
|
+
import { jsx as jsx66 } from "react/jsx-runtime";
|
|
7877
|
+
var StnSideNavSubNav = forwardRef38(
|
|
7759
7878
|
function StnSideNavSubNav2({
|
|
7760
7879
|
dropdown = false,
|
|
7761
7880
|
direction = "down",
|
|
@@ -7767,7 +7886,7 @@ var StnSideNavSubNav = forwardRef37(
|
|
|
7767
7886
|
}, ref) {
|
|
7768
7887
|
const isUp = direction === "up";
|
|
7769
7888
|
const isTransparent = variant === "transparent" || background === false;
|
|
7770
|
-
return /* @__PURE__ */
|
|
7889
|
+
return /* @__PURE__ */ jsx66(
|
|
7771
7890
|
"div",
|
|
7772
7891
|
{
|
|
7773
7892
|
ref,
|
|
@@ -7790,14 +7909,14 @@ var StnSideNavSubNav = forwardRef37(
|
|
|
7790
7909
|
|
|
7791
7910
|
// src/patterns/sideNav/StnSideNavigation.tsx
|
|
7792
7911
|
import {
|
|
7793
|
-
forwardRef as
|
|
7912
|
+
forwardRef as forwardRef39,
|
|
7794
7913
|
useCallback as useCallback8,
|
|
7795
7914
|
useMemo as useMemo4,
|
|
7796
|
-
useState as
|
|
7915
|
+
useState as useState17
|
|
7797
7916
|
} from "react";
|
|
7798
|
-
import { jsx as
|
|
7917
|
+
import { jsx as jsx67, jsxs as jsxs49 } from "react/jsx-runtime";
|
|
7799
7918
|
function useControllableState(controlledValue, defaultValue, onChange) {
|
|
7800
|
-
const [internalState, setInternalState] =
|
|
7919
|
+
const [internalState, setInternalState] = useState17(defaultValue);
|
|
7801
7920
|
const isControlled = controlledValue !== void 0;
|
|
7802
7921
|
const value = isControlled ? controlledValue : internalState;
|
|
7803
7922
|
const setValue = useCallback8(
|
|
@@ -7811,7 +7930,7 @@ function useControllableState(controlledValue, defaultValue, onChange) {
|
|
|
7811
7930
|
);
|
|
7812
7931
|
return [value, setValue];
|
|
7813
7932
|
}
|
|
7814
|
-
var StnSideNavigationRoot =
|
|
7933
|
+
var StnSideNavigationRoot = forwardRef39(function StnSideNavigationRoot2({
|
|
7815
7934
|
variant: variantProp,
|
|
7816
7935
|
appearance,
|
|
7817
7936
|
drawerVariant: drawerVariantProp,
|
|
@@ -7872,9 +7991,9 @@ var StnSideNavigationRoot = forwardRef38(function StnSideNavigationRoot2({
|
|
|
7872
7991
|
}),
|
|
7873
7992
|
[isEffectiveCollapsed, activeId, setActiveId, handleToggleCollapse, mobileOpen, handleToggleMobileOpen, setMobileOpen, isDrawerMode]
|
|
7874
7993
|
);
|
|
7875
|
-
return /* @__PURE__ */
|
|
7876
|
-
showMobileTrigger && /* @__PURE__ */
|
|
7877
|
-
(drawer || responsiveDrawer) && /* @__PURE__ */
|
|
7994
|
+
return /* @__PURE__ */ jsxs49(SideNavContext.Provider, { value: contextValue, children: [
|
|
7995
|
+
showMobileTrigger && /* @__PURE__ */ jsx67(StnSideNavMobileTrigger, { floating: true }),
|
|
7996
|
+
(drawer || responsiveDrawer) && /* @__PURE__ */ jsx67(
|
|
7878
7997
|
"div",
|
|
7879
7998
|
{
|
|
7880
7999
|
className: cn("stn-side-nav__backdrop", mobileOpen && "is-open"),
|
|
@@ -7882,7 +8001,7 @@ var StnSideNavigationRoot = forwardRef38(function StnSideNavigationRoot2({
|
|
|
7882
8001
|
"aria-hidden": !mobileOpen
|
|
7883
8002
|
}
|
|
7884
8003
|
),
|
|
7885
|
-
/* @__PURE__ */
|
|
8004
|
+
/* @__PURE__ */ jsx67(
|
|
7886
8005
|
"aside",
|
|
7887
8006
|
{
|
|
7888
8007
|
ref,
|
|
@@ -7924,14 +8043,14 @@ var StnSideNavigation = Object.assign(StnSideNavigationRoot, {
|
|
|
7924
8043
|
import {
|
|
7925
8044
|
Fragment as Fragment8,
|
|
7926
8045
|
useEffect as useEffect11,
|
|
7927
|
-
useId as
|
|
8046
|
+
useId as useId16,
|
|
7928
8047
|
useRef as useRef8,
|
|
7929
|
-
useState as
|
|
8048
|
+
useState as useState18
|
|
7930
8049
|
} from "react";
|
|
7931
8050
|
import {
|
|
7932
8051
|
STN_BREADCRUMB_ICON_SRC
|
|
7933
8052
|
} from "@stn-uiux/pub-ui/data/stnBreadcrumb";
|
|
7934
|
-
import { Fragment as Fragment9, jsx as
|
|
8053
|
+
import { Fragment as Fragment9, jsx as jsx68, jsxs as jsxs50 } from "react/jsx-runtime";
|
|
7935
8054
|
function maskStyle3(src) {
|
|
7936
8055
|
return { maskImage: `url('${src}')`, WebkitMaskImage: `url('${src}')` };
|
|
7937
8056
|
}
|
|
@@ -7944,13 +8063,13 @@ function hasSegmentMenu(item) {
|
|
|
7944
8063
|
return Boolean(item.menu || item.menuItems && item.menuItems.length > 0);
|
|
7945
8064
|
}
|
|
7946
8065
|
function BreadcrumbSeparator() {
|
|
7947
|
-
return /* @__PURE__ */
|
|
8066
|
+
return /* @__PURE__ */ jsx68("li", { className: "separator", "aria-hidden": "true", children: /* @__PURE__ */ jsx68("span", { style: maskStyle3(STN_BREADCRUMB_ICON_SRC.separator) }) });
|
|
7948
8067
|
}
|
|
7949
8068
|
function BreadcrumbIcon({ src }) {
|
|
7950
|
-
return /* @__PURE__ */
|
|
8069
|
+
return /* @__PURE__ */ jsx68("span", { className: "stn-breadcrumb__icon-glyph", style: maskStyle3(src), "aria-hidden": "true" });
|
|
7951
8070
|
}
|
|
7952
8071
|
function BreadcrumbCaret() {
|
|
7953
|
-
return /* @__PURE__ */
|
|
8072
|
+
return /* @__PURE__ */ jsx68(
|
|
7954
8073
|
"span",
|
|
7955
8074
|
{
|
|
7956
8075
|
className: "stn-breadcrumb__caret",
|
|
@@ -7964,10 +8083,10 @@ function SegmentContent({
|
|
|
7964
8083
|
label,
|
|
7965
8084
|
menu
|
|
7966
8085
|
}) {
|
|
7967
|
-
return /* @__PURE__ */
|
|
7968
|
-
iconSrc ? /* @__PURE__ */
|
|
7969
|
-
/* @__PURE__ */
|
|
7970
|
-
menu ? /* @__PURE__ */
|
|
8086
|
+
return /* @__PURE__ */ jsxs50(Fragment9, { children: [
|
|
8087
|
+
iconSrc ? /* @__PURE__ */ jsx68(BreadcrumbIcon, { src: iconSrc }) : null,
|
|
8088
|
+
/* @__PURE__ */ jsx68("span", { className: "stn-breadcrumb__label", children: label }),
|
|
8089
|
+
menu ? /* @__PURE__ */ jsx68(BreadcrumbCaret, {}) : null
|
|
7971
8090
|
] });
|
|
7972
8091
|
}
|
|
7973
8092
|
function BreadcrumbMenuList({
|
|
@@ -7975,7 +8094,7 @@ function BreadcrumbMenuList({
|
|
|
7975
8094
|
items,
|
|
7976
8095
|
onPick
|
|
7977
8096
|
}) {
|
|
7978
|
-
return /* @__PURE__ */
|
|
8097
|
+
return /* @__PURE__ */ jsx68("ul", { id, className: "stn-breadcrumb__menu", role: "menu", children: items.map((option) => /* @__PURE__ */ jsx68("li", { role: "none", children: option.href ? /* @__PURE__ */ jsx68(
|
|
7979
8098
|
"a",
|
|
7980
8099
|
{
|
|
7981
8100
|
role: "menuitem",
|
|
@@ -7987,7 +8106,7 @@ function BreadcrumbMenuList({
|
|
|
7987
8106
|
},
|
|
7988
8107
|
children: option.label
|
|
7989
8108
|
}
|
|
7990
|
-
) : /* @__PURE__ */
|
|
8109
|
+
) : /* @__PURE__ */ jsx68(
|
|
7991
8110
|
"button",
|
|
7992
8111
|
{
|
|
7993
8112
|
type: "button",
|
|
@@ -8024,20 +8143,20 @@ function BreadcrumbSegment({
|
|
|
8024
8143
|
item,
|
|
8025
8144
|
isCurrent
|
|
8026
8145
|
}) {
|
|
8027
|
-
const menuId =
|
|
8028
|
-
const [open, setOpen] =
|
|
8146
|
+
const menuId = useId16();
|
|
8147
|
+
const [open, setOpen] = useState18(false);
|
|
8029
8148
|
const menuItems = item.menuItems ?? [];
|
|
8030
8149
|
const showMenu = hasSegmentMenu(item) && !isCurrent;
|
|
8031
8150
|
const canOpenMenu = showMenu && menuItems.length > 0;
|
|
8032
8151
|
const rootRef = useDismissibleMenu(open, () => setOpen(false));
|
|
8033
8152
|
const iconSrc = resolveIconSrc(item);
|
|
8034
|
-
const content = /* @__PURE__ */
|
|
8153
|
+
const content = /* @__PURE__ */ jsx68(SegmentContent, { iconSrc, label: item.label, menu: showMenu });
|
|
8035
8154
|
if (isCurrent) {
|
|
8036
|
-
return /* @__PURE__ */
|
|
8155
|
+
return /* @__PURE__ */ jsx68("span", { className: "stn-breadcrumb__segment", "aria-current": "page", "aria-label": item.label, children: content });
|
|
8037
8156
|
}
|
|
8038
8157
|
if (canOpenMenu) {
|
|
8039
|
-
return /* @__PURE__ */
|
|
8040
|
-
/* @__PURE__ */
|
|
8158
|
+
return /* @__PURE__ */ jsxs50("span", { ref: rootRef, className: "stn-breadcrumb__segment-wrap", children: [
|
|
8159
|
+
/* @__PURE__ */ jsx68(
|
|
8041
8160
|
"button",
|
|
8042
8161
|
{
|
|
8043
8162
|
type: "button",
|
|
@@ -8053,7 +8172,7 @@ function BreadcrumbSegment({
|
|
|
8053
8172
|
children: content
|
|
8054
8173
|
}
|
|
8055
8174
|
),
|
|
8056
|
-
open ? /* @__PURE__ */
|
|
8175
|
+
open ? /* @__PURE__ */ jsx68(BreadcrumbMenuList, { id: menuId, items: menuItems, onPick: () => setOpen(false) }) : null
|
|
8057
8176
|
] });
|
|
8058
8177
|
}
|
|
8059
8178
|
if (item.menu || item.onClick) {
|
|
@@ -8065,7 +8184,7 @@ function BreadcrumbSegment({
|
|
|
8065
8184
|
"aria-haspopup": item.menu ? "menu" : void 0,
|
|
8066
8185
|
"aria-expanded": item.menu ? false : void 0
|
|
8067
8186
|
};
|
|
8068
|
-
return /* @__PURE__ */
|
|
8187
|
+
return /* @__PURE__ */ jsx68("button", { ...buttonProps, children: content });
|
|
8069
8188
|
}
|
|
8070
8189
|
if (item.href) {
|
|
8071
8190
|
const linkProps = {
|
|
@@ -8074,17 +8193,17 @@ function BreadcrumbSegment({
|
|
|
8074
8193
|
onClick: item.onClick,
|
|
8075
8194
|
"aria-label": item.label
|
|
8076
8195
|
};
|
|
8077
|
-
return /* @__PURE__ */
|
|
8196
|
+
return /* @__PURE__ */ jsx68("a", { ...linkProps, children: content });
|
|
8078
8197
|
}
|
|
8079
|
-
return /* @__PURE__ */
|
|
8198
|
+
return /* @__PURE__ */ jsx68("span", { className: "stn-breadcrumb__segment", "aria-label": item.label, children: content });
|
|
8080
8199
|
}
|
|
8081
8200
|
function BreadcrumbBack({
|
|
8082
8201
|
label,
|
|
8083
8202
|
href,
|
|
8084
8203
|
onClick
|
|
8085
8204
|
}) {
|
|
8086
|
-
const content = /* @__PURE__ */
|
|
8087
|
-
/* @__PURE__ */
|
|
8205
|
+
const content = /* @__PURE__ */ jsxs50(Fragment9, { children: [
|
|
8206
|
+
/* @__PURE__ */ jsx68(
|
|
8088
8207
|
"span",
|
|
8089
8208
|
{
|
|
8090
8209
|
className: "stn-breadcrumb__back-glyph",
|
|
@@ -8092,12 +8211,12 @@ function BreadcrumbBack({
|
|
|
8092
8211
|
"aria-hidden": "true"
|
|
8093
8212
|
}
|
|
8094
8213
|
),
|
|
8095
|
-
/* @__PURE__ */
|
|
8214
|
+
/* @__PURE__ */ jsx68("span", { className: "stn-breadcrumb__label", children: label })
|
|
8096
8215
|
] });
|
|
8097
8216
|
if (href) {
|
|
8098
|
-
return /* @__PURE__ */
|
|
8217
|
+
return /* @__PURE__ */ jsx68("a", { className: "stn-breadcrumb__back", href, onClick, "aria-label": `\uB4A4\uB85C: ${label}`, children: content });
|
|
8099
8218
|
}
|
|
8100
|
-
return /* @__PURE__ */
|
|
8219
|
+
return /* @__PURE__ */ jsx68("button", { type: "button", className: "stn-breadcrumb__back", onClick, "aria-label": `\uB4A4\uB85C: ${label}`, children: content });
|
|
8101
8220
|
}
|
|
8102
8221
|
function splitCollapsedItems(items, maxItems, itemsBeforeCollapse, itemsAfterCollapse) {
|
|
8103
8222
|
if (!maxItems || items.length <= maxItems) {
|
|
@@ -8119,7 +8238,7 @@ function BreadcrumbCollapsed({
|
|
|
8119
8238
|
items,
|
|
8120
8239
|
menuId
|
|
8121
8240
|
}) {
|
|
8122
|
-
const [open, setOpen] =
|
|
8241
|
+
const [open, setOpen] = useState18(false);
|
|
8123
8242
|
const rootRef = useDismissibleMenu(open, () => setOpen(false));
|
|
8124
8243
|
const menuItems = items.map((item) => ({
|
|
8125
8244
|
id: item.id,
|
|
@@ -8128,8 +8247,8 @@ function BreadcrumbCollapsed({
|
|
|
8128
8247
|
onClick: item.onClick,
|
|
8129
8248
|
current: item.current
|
|
8130
8249
|
}));
|
|
8131
|
-
return /* @__PURE__ */
|
|
8132
|
-
/* @__PURE__ */
|
|
8250
|
+
return /* @__PURE__ */ jsxs50("li", { className: "stn-breadcrumb__item", ref: rootRef, children: [
|
|
8251
|
+
/* @__PURE__ */ jsx68(
|
|
8133
8252
|
"button",
|
|
8134
8253
|
{
|
|
8135
8254
|
type: "button",
|
|
@@ -8142,7 +8261,7 @@ function BreadcrumbCollapsed({
|
|
|
8142
8261
|
children: "\u22EF"
|
|
8143
8262
|
}
|
|
8144
8263
|
),
|
|
8145
|
-
open ? /* @__PURE__ */
|
|
8264
|
+
open ? /* @__PURE__ */ jsx68(BreadcrumbMenuList, { id: menuId, items: menuItems, onPick: () => setOpen(false) }) : null
|
|
8146
8265
|
] });
|
|
8147
8266
|
}
|
|
8148
8267
|
function StnBreadcrumb({
|
|
@@ -8159,7 +8278,7 @@ function StnBreadcrumb({
|
|
|
8159
8278
|
homeLabel = "\uD648",
|
|
8160
8279
|
renderItem
|
|
8161
8280
|
}) {
|
|
8162
|
-
const menuId =
|
|
8281
|
+
const menuId = useId16();
|
|
8163
8282
|
const currentIndex = items.findIndex((item, index) => item.current ?? index === items.length - 1);
|
|
8164
8283
|
const currentItem = currentIndex >= 0 ? items[currentIndex] : items[items.length - 1];
|
|
8165
8284
|
const previousItem = currentIndex > 0 ? items[currentIndex - 1] : null;
|
|
@@ -8174,8 +8293,8 @@ function StnBreadcrumb({
|
|
|
8174
8293
|
const lastId = items[items.length - 1]?.id;
|
|
8175
8294
|
const renderTrailItem = (item) => {
|
|
8176
8295
|
const isCurrent = Boolean(item.current) || item.id === lastId;
|
|
8177
|
-
const segment = /* @__PURE__ */
|
|
8178
|
-
return /* @__PURE__ */
|
|
8296
|
+
const segment = /* @__PURE__ */ jsx68(BreadcrumbSegment, { item, isCurrent });
|
|
8297
|
+
return /* @__PURE__ */ jsx68(
|
|
8179
8298
|
"li",
|
|
8180
8299
|
{
|
|
8181
8300
|
className: cn(
|
|
@@ -8186,27 +8305,27 @@ function StnBreadcrumb({
|
|
|
8186
8305
|
}
|
|
8187
8306
|
);
|
|
8188
8307
|
};
|
|
8189
|
-
return /* @__PURE__ */
|
|
8308
|
+
return /* @__PURE__ */ jsx68(
|
|
8190
8309
|
"nav",
|
|
8191
8310
|
{
|
|
8192
8311
|
className: cn("stn-breadcrumb", size, variant === "chip" && "chip", className),
|
|
8193
8312
|
"aria-label": "Breadcrumb",
|
|
8194
|
-
children: /* @__PURE__ */
|
|
8195
|
-
currentItem ? /* @__PURE__ */
|
|
8196
|
-
showHome ? /* @__PURE__ */
|
|
8197
|
-
/* @__PURE__ */
|
|
8198
|
-
/* @__PURE__ */
|
|
8313
|
+
children: /* @__PURE__ */ jsxs50("ol", { className: "stn-breadcrumb__list", children: [
|
|
8314
|
+
currentItem ? /* @__PURE__ */ jsx68("li", { className: "stn-breadcrumb__item stn-breadcrumb__item--back", children: /* @__PURE__ */ jsx68(BreadcrumbBack, { label: currentItem.label, href: backHref, onClick: backOnClick }) }) : null,
|
|
8315
|
+
showHome ? /* @__PURE__ */ jsx68("li", { className: "stn-breadcrumb__item stn-breadcrumb__item--home", children: /* @__PURE__ */ jsxs50("a", { className: "stn-breadcrumb__home", href: homeHref, onClick: onHomeClick, children: [
|
|
8316
|
+
/* @__PURE__ */ jsx68(BreadcrumbIcon, { src: STN_BREADCRUMB_ICON_SRC.home }),
|
|
8317
|
+
/* @__PURE__ */ jsx68("span", { className: "blind", children: homeLabel })
|
|
8199
8318
|
] }) }) : null,
|
|
8200
|
-
head.map((item, index) => /* @__PURE__ */
|
|
8201
|
-
showHome || index > 0 ? /* @__PURE__ */
|
|
8319
|
+
head.map((item, index) => /* @__PURE__ */ jsxs50(Fragment8, { children: [
|
|
8320
|
+
showHome || index > 0 ? /* @__PURE__ */ jsx68(BreadcrumbSeparator, {}) : null,
|
|
8202
8321
|
renderTrailItem(item)
|
|
8203
8322
|
] }, item.id)),
|
|
8204
|
-
hidden.length > 0 ? /* @__PURE__ */
|
|
8205
|
-
/* @__PURE__ */
|
|
8206
|
-
/* @__PURE__ */
|
|
8323
|
+
hidden.length > 0 ? /* @__PURE__ */ jsxs50(Fragment9, { children: [
|
|
8324
|
+
/* @__PURE__ */ jsx68(BreadcrumbSeparator, {}),
|
|
8325
|
+
/* @__PURE__ */ jsx68(BreadcrumbCollapsed, { items: hidden, menuId })
|
|
8207
8326
|
] }) : null,
|
|
8208
|
-
tail.map((item) => /* @__PURE__ */
|
|
8209
|
-
/* @__PURE__ */
|
|
8327
|
+
tail.map((item) => /* @__PURE__ */ jsxs50(Fragment8, { children: [
|
|
8328
|
+
/* @__PURE__ */ jsx68(BreadcrumbSeparator, {}),
|
|
8210
8329
|
renderTrailItem(item)
|
|
8211
8330
|
] }, item.id))
|
|
8212
8331
|
] })
|
|
@@ -8215,9 +8334,9 @@ function StnBreadcrumb({
|
|
|
8215
8334
|
}
|
|
8216
8335
|
|
|
8217
8336
|
// src/components/StnHeaderTitle.tsx
|
|
8218
|
-
import { useEffect as useEffect12, useState as
|
|
8337
|
+
import { useEffect as useEffect12, useState as useState19 } from "react";
|
|
8219
8338
|
import { STN_HEADER_TITLE_FRAME } from "@stn-uiux/pub-ui/data/stnHeaderTitle";
|
|
8220
|
-
import { jsx as
|
|
8339
|
+
import { jsx as jsx69, jsxs as jsxs51 } from "react/jsx-runtime";
|
|
8221
8340
|
var KO_WEEKDAY_SHORT = ["\uC77C", "\uC6D4", "\uD654", "\uC218", "\uBAA9", "\uAE08", "\uD1A0"];
|
|
8222
8341
|
var KO_WEEKDAY_LONG = [
|
|
8223
8342
|
"\uC77C\uC694\uC77C",
|
|
@@ -8256,8 +8375,8 @@ function formatStnHeaderTitleTime(date, options) {
|
|
|
8256
8375
|
}
|
|
8257
8376
|
function HeaderTitleFrame({ preview = false }) {
|
|
8258
8377
|
const frameClass = preview ? "stn-header-title__frame-preview" : "stn-header-title__frame";
|
|
8259
|
-
return /* @__PURE__ */
|
|
8260
|
-
/* @__PURE__ */
|
|
8378
|
+
return /* @__PURE__ */ jsxs51("div", { className: frameClass, "aria-hidden": "true", children: [
|
|
8379
|
+
/* @__PURE__ */ jsx69("div", { className: "stn-header-title__frame-bleed stn-header-title__frame-bleed--outer", children: /* @__PURE__ */ jsx69(
|
|
8261
8380
|
"img",
|
|
8262
8381
|
{
|
|
8263
8382
|
className: "stn-header-title__frame-img",
|
|
@@ -8266,8 +8385,8 @@ function HeaderTitleFrame({ preview = false }) {
|
|
|
8266
8385
|
draggable: false
|
|
8267
8386
|
}
|
|
8268
8387
|
) }),
|
|
8269
|
-
/* @__PURE__ */
|
|
8270
|
-
/* @__PURE__ */
|
|
8388
|
+
/* @__PURE__ */ jsxs51("div", { className: "stn-header-title__frame-bleed stn-header-title__frame-bleed--inner", children: [
|
|
8389
|
+
/* @__PURE__ */ jsx69(
|
|
8271
8390
|
"img",
|
|
8272
8391
|
{
|
|
8273
8392
|
className: "stn-header-title__frame-img stn-header-title__frame-img--dark",
|
|
@@ -8276,7 +8395,7 @@ function HeaderTitleFrame({ preview = false }) {
|
|
|
8276
8395
|
draggable: false
|
|
8277
8396
|
}
|
|
8278
8397
|
),
|
|
8279
|
-
/* @__PURE__ */
|
|
8398
|
+
/* @__PURE__ */ jsx69(
|
|
8280
8399
|
"img",
|
|
8281
8400
|
{
|
|
8282
8401
|
className: "stn-header-title__frame-img stn-header-title__frame-img--light",
|
|
@@ -8289,10 +8408,10 @@ function HeaderTitleFrame({ preview = false }) {
|
|
|
8289
8408
|
] });
|
|
8290
8409
|
}
|
|
8291
8410
|
function StnHeaderTitleFramePreview({ className }) {
|
|
8292
|
-
return /* @__PURE__ */
|
|
8411
|
+
return /* @__PURE__ */ jsx69("div", { className: cn("stn-header-title__frame-only", className), children: /* @__PURE__ */ jsx69(HeaderTitleFrame, { preview: true }) });
|
|
8293
8412
|
}
|
|
8294
8413
|
function useLiveClock(enabled) {
|
|
8295
|
-
const [now, setNow] =
|
|
8414
|
+
const [now, setNow] = useState19(() => /* @__PURE__ */ new Date());
|
|
8296
8415
|
useEffect12(() => {
|
|
8297
8416
|
if (!enabled) return;
|
|
8298
8417
|
const id = window.setInterval(() => setNow(/* @__PURE__ */ new Date()), 1e3);
|
|
@@ -8305,35 +8424,35 @@ function StnHeaderTitleMainText({
|
|
|
8305
8424
|
children,
|
|
8306
8425
|
...rest
|
|
8307
8426
|
}) {
|
|
8308
|
-
return /* @__PURE__ */
|
|
8427
|
+
return /* @__PURE__ */ jsx69("h1", { className: cn("stn-header-title__text", className), ...rest, children });
|
|
8309
8428
|
}
|
|
8310
8429
|
function StnHeaderTitleSubText({
|
|
8311
8430
|
className,
|
|
8312
8431
|
children,
|
|
8313
8432
|
...rest
|
|
8314
8433
|
}) {
|
|
8315
|
-
return /* @__PURE__ */
|
|
8434
|
+
return /* @__PURE__ */ jsx69("span", { className: cn("stn-header-title__sub-text", className), ...rest, children });
|
|
8316
8435
|
}
|
|
8317
8436
|
function StnHeaderTitleDate({
|
|
8318
8437
|
className,
|
|
8319
8438
|
children,
|
|
8320
8439
|
...rest
|
|
8321
8440
|
}) {
|
|
8322
|
-
return /* @__PURE__ */
|
|
8441
|
+
return /* @__PURE__ */ jsx69("time", { className: cn("stn-header-title__date", className), ...rest, children });
|
|
8323
8442
|
}
|
|
8324
8443
|
function StnHeaderTitleWeekday({
|
|
8325
8444
|
className,
|
|
8326
8445
|
children,
|
|
8327
8446
|
...rest
|
|
8328
8447
|
}) {
|
|
8329
|
-
return /* @__PURE__ */
|
|
8448
|
+
return /* @__PURE__ */ jsx69("span", { className: cn("stn-header-title__weekday", className), ...rest, children });
|
|
8330
8449
|
}
|
|
8331
8450
|
function StnHeaderTitleTime({
|
|
8332
8451
|
className,
|
|
8333
8452
|
children,
|
|
8334
8453
|
...rest
|
|
8335
8454
|
}) {
|
|
8336
|
-
return /* @__PURE__ */
|
|
8455
|
+
return /* @__PURE__ */ jsx69("span", { className: cn("stn-header-title__time", className), "aria-label": "\uD604\uC7AC \uC2DC\uAC01", ...rest, children });
|
|
8337
8456
|
}
|
|
8338
8457
|
function StnHeaderTitleClock({
|
|
8339
8458
|
className,
|
|
@@ -8356,7 +8475,7 @@ function StnHeaderTitleClock({
|
|
|
8356
8475
|
}) {
|
|
8357
8476
|
const now = useLiveClock(live);
|
|
8358
8477
|
if (children != null) {
|
|
8359
|
-
return /* @__PURE__ */
|
|
8478
|
+
return /* @__PURE__ */ jsxs51(
|
|
8360
8479
|
"header",
|
|
8361
8480
|
{
|
|
8362
8481
|
className: cn(
|
|
@@ -8368,8 +8487,8 @@ function StnHeaderTitleClock({
|
|
|
8368
8487
|
),
|
|
8369
8488
|
...rest,
|
|
8370
8489
|
children: [
|
|
8371
|
-
framed ? /* @__PURE__ */
|
|
8372
|
-
/* @__PURE__ */
|
|
8490
|
+
framed ? /* @__PURE__ */ jsx69(HeaderTitleFrame, {}) : null,
|
|
8491
|
+
/* @__PURE__ */ jsx69("div", { className: "stn-header-title__content", children })
|
|
8373
8492
|
]
|
|
8374
8493
|
}
|
|
8375
8494
|
);
|
|
@@ -8399,7 +8518,7 @@ function StnHeaderTitleClock({
|
|
|
8399
8518
|
resolvedTime = formatStnHeaderTitleTime(now, { showSeconds });
|
|
8400
8519
|
}
|
|
8401
8520
|
}
|
|
8402
|
-
return /* @__PURE__ */
|
|
8521
|
+
return /* @__PURE__ */ jsxs51(
|
|
8403
8522
|
"header",
|
|
8404
8523
|
{
|
|
8405
8524
|
className: cn(
|
|
@@ -8411,11 +8530,11 @@ function StnHeaderTitleClock({
|
|
|
8411
8530
|
),
|
|
8412
8531
|
...rest,
|
|
8413
8532
|
children: [
|
|
8414
|
-
framed ? /* @__PURE__ */
|
|
8415
|
-
/* @__PURE__ */
|
|
8416
|
-
resolvedDate ? /* @__PURE__ */
|
|
8417
|
-
showWeekdayOnly ? /* @__PURE__ */
|
|
8418
|
-
resolvedTime ? /* @__PURE__ */
|
|
8533
|
+
framed ? /* @__PURE__ */ jsx69(HeaderTitleFrame, {}) : null,
|
|
8534
|
+
/* @__PURE__ */ jsxs51("div", { className: "stn-header-title__content", children: [
|
|
8535
|
+
resolvedDate ? /* @__PURE__ */ jsx69("time", { className: "stn-header-title__date", dateTime: resolvedDate, children: resolvedDate }) : null,
|
|
8536
|
+
showWeekdayOnly ? /* @__PURE__ */ jsx69("span", { className: "stn-header-title__weekday", children: resolvedWeekday }) : null,
|
|
8537
|
+
resolvedTime ? /* @__PURE__ */ jsx69("span", { className: "stn-header-title__time", "aria-label": "\uD604\uC7AC \uC2DC\uAC01", children: resolvedTime }) : null
|
|
8419
8538
|
] })
|
|
8420
8539
|
]
|
|
8421
8540
|
}
|
|
@@ -8432,7 +8551,7 @@ function StnHeaderTitleDual({
|
|
|
8432
8551
|
...rest
|
|
8433
8552
|
}) {
|
|
8434
8553
|
const resolvedMain = mainText ?? title ?? children;
|
|
8435
|
-
return /* @__PURE__ */
|
|
8554
|
+
return /* @__PURE__ */ jsxs51(
|
|
8436
8555
|
"header",
|
|
8437
8556
|
{
|
|
8438
8557
|
className: cn(
|
|
@@ -8444,10 +8563,10 @@ function StnHeaderTitleDual({
|
|
|
8444
8563
|
),
|
|
8445
8564
|
...rest,
|
|
8446
8565
|
children: [
|
|
8447
|
-
framed ? /* @__PURE__ */
|
|
8448
|
-
/* @__PURE__ */
|
|
8449
|
-
subText != null ? /* @__PURE__ */
|
|
8450
|
-
resolvedMain != null ? typeof resolvedMain === "string" || typeof resolvedMain === "number" ? /* @__PURE__ */
|
|
8566
|
+
framed ? /* @__PURE__ */ jsx69(HeaderTitleFrame, {}) : null,
|
|
8567
|
+
/* @__PURE__ */ jsxs51("div", { className: "stn-header-title__content", children: [
|
|
8568
|
+
subText != null ? /* @__PURE__ */ jsx69("span", { className: "stn-header-title__sub-text", children: subText }) : null,
|
|
8569
|
+
resolvedMain != null ? typeof resolvedMain === "string" || typeof resolvedMain === "number" ? /* @__PURE__ */ jsx69("h1", { className: "stn-header-title__text", children: resolvedMain }) : resolvedMain : null
|
|
8451
8570
|
] })
|
|
8452
8571
|
]
|
|
8453
8572
|
}
|
|
@@ -8462,7 +8581,7 @@ function StnHeaderTitleText({
|
|
|
8462
8581
|
...rest
|
|
8463
8582
|
}) {
|
|
8464
8583
|
const resolved = title ?? children;
|
|
8465
|
-
return /* @__PURE__ */
|
|
8584
|
+
return /* @__PURE__ */ jsxs51(
|
|
8466
8585
|
"header",
|
|
8467
8586
|
{
|
|
8468
8587
|
className: cn(
|
|
@@ -8474,20 +8593,20 @@ function StnHeaderTitleText({
|
|
|
8474
8593
|
),
|
|
8475
8594
|
...rest,
|
|
8476
8595
|
children: [
|
|
8477
|
-
framed ? /* @__PURE__ */
|
|
8478
|
-
/* @__PURE__ */
|
|
8596
|
+
framed ? /* @__PURE__ */ jsx69(HeaderTitleFrame, {}) : null,
|
|
8597
|
+
/* @__PURE__ */ jsx69("div", { className: "stn-header-title__content", children: typeof resolved === "string" || typeof resolved === "number" ? /* @__PURE__ */ jsx69("h1", { className: "stn-header-title__text", children: resolved }) : resolved })
|
|
8479
8598
|
]
|
|
8480
8599
|
}
|
|
8481
8600
|
);
|
|
8482
8601
|
}
|
|
8483
8602
|
function StnHeaderTitleRoot(props) {
|
|
8484
8603
|
if (props.variant === "clock") {
|
|
8485
|
-
return /* @__PURE__ */
|
|
8604
|
+
return /* @__PURE__ */ jsx69(StnHeaderTitleClock, { ...props });
|
|
8486
8605
|
}
|
|
8487
8606
|
if (props.variant === "dual" || "subText" in props && props.subText != null) {
|
|
8488
|
-
return /* @__PURE__ */
|
|
8607
|
+
return /* @__PURE__ */ jsx69(StnHeaderTitleDual, { ...props });
|
|
8489
8608
|
}
|
|
8490
|
-
return /* @__PURE__ */
|
|
8609
|
+
return /* @__PURE__ */ jsx69(StnHeaderTitleText, { ...props });
|
|
8491
8610
|
}
|
|
8492
8611
|
var StnHeaderTitle = Object.assign(StnHeaderTitleRoot, {
|
|
8493
8612
|
Text: StnHeaderTitleMainText,
|
|
@@ -8500,10 +8619,10 @@ var StnHeaderTitle = Object.assign(StnHeaderTitleRoot, {
|
|
|
8500
8619
|
|
|
8501
8620
|
// src/layouts/StnContainer.tsx
|
|
8502
8621
|
import {
|
|
8503
|
-
forwardRef as
|
|
8622
|
+
forwardRef as forwardRef40
|
|
8504
8623
|
} from "react";
|
|
8505
|
-
import { jsx as
|
|
8506
|
-
var StnContainer =
|
|
8624
|
+
import { jsx as jsx70 } from "react/jsx-runtime";
|
|
8625
|
+
var StnContainer = forwardRef40(function StnContainer2({
|
|
8507
8626
|
component,
|
|
8508
8627
|
as,
|
|
8509
8628
|
maxWidth = "lg",
|
|
@@ -8518,7 +8637,7 @@ var StnContainer = forwardRef39(function StnContainer2({
|
|
|
8518
8637
|
const Component = component ?? as ?? "div";
|
|
8519
8638
|
const maxWidthClass = maxWidth ? `stn-container--${maxWidth} stn-container--max-width-${maxWidth}` : "stn-container--fluid stn-container--max-width-false";
|
|
8520
8639
|
const classKey = maxWidth ? `maxWidth${maxWidth.charAt(0).toUpperCase() + maxWidth.slice(1)}` : "maxWidthFalse";
|
|
8521
|
-
return /* @__PURE__ */
|
|
8640
|
+
return /* @__PURE__ */ jsx70(
|
|
8522
8641
|
Component,
|
|
8523
8642
|
{
|
|
8524
8643
|
ref,
|
|
@@ -8541,8 +8660,8 @@ var StnContainer = forwardRef39(function StnContainer2({
|
|
|
8541
8660
|
});
|
|
8542
8661
|
|
|
8543
8662
|
// src/layouts/StnGrid.tsx
|
|
8544
|
-
import { forwardRef as
|
|
8545
|
-
import { jsx as
|
|
8663
|
+
import { forwardRef as forwardRef41 } from "react";
|
|
8664
|
+
import { jsx as jsx71 } from "react/jsx-runtime";
|
|
8546
8665
|
var BREAKPOINTS2 = ["xs", "sm", "md", "lg", "xl"];
|
|
8547
8666
|
var SPACING_CLASS = {
|
|
8548
8667
|
"0": "0",
|
|
@@ -8608,7 +8727,7 @@ function sizeClasses(size) {
|
|
|
8608
8727
|
}
|
|
8609
8728
|
return classes;
|
|
8610
8729
|
}
|
|
8611
|
-
var StnGrid =
|
|
8730
|
+
var StnGrid = forwardRef41(function StnGrid2({
|
|
8612
8731
|
component,
|
|
8613
8732
|
as,
|
|
8614
8733
|
container = false,
|
|
@@ -8628,7 +8747,7 @@ var StnGrid = forwardRef40(function StnGrid2({
|
|
|
8628
8747
|
const Component = component ?? as ?? "div";
|
|
8629
8748
|
const justify = typeof justifyContent === "string" && JUSTIFY_CLASS2.has(justifyContent) ? justifyContent : void 0;
|
|
8630
8749
|
const align = typeof alignItems === "string" && ALIGN_CLASS2.has(alignItems) ? alignItems : void 0;
|
|
8631
|
-
return /* @__PURE__ */
|
|
8750
|
+
return /* @__PURE__ */ jsx71(
|
|
8632
8751
|
Component,
|
|
8633
8752
|
{
|
|
8634
8753
|
ref,
|
|
@@ -8652,7 +8771,7 @@ var StnGrid = forwardRef40(function StnGrid2({
|
|
|
8652
8771
|
});
|
|
8653
8772
|
|
|
8654
8773
|
// src/layouts/StnLayerShell.tsx
|
|
8655
|
-
import { jsx as
|
|
8774
|
+
import { jsx as jsx72, jsxs as jsxs52 } from "react/jsx-runtime";
|
|
8656
8775
|
function StnLayerShell({
|
|
8657
8776
|
gnb,
|
|
8658
8777
|
gnbSide = "left",
|
|
@@ -8673,7 +8792,7 @@ function StnLayerShell({
|
|
|
8673
8792
|
const resolvedMainContent = layer1 ?? children;
|
|
8674
8793
|
const resolvedModal = layer2;
|
|
8675
8794
|
const isGnbRight = gnbSide === "right";
|
|
8676
|
-
return /* @__PURE__ */
|
|
8795
|
+
return /* @__PURE__ */ jsxs52(
|
|
8677
8796
|
"div",
|
|
8678
8797
|
{
|
|
8679
8798
|
id: wrapId,
|
|
@@ -8682,8 +8801,8 @@ function StnLayerShell({
|
|
|
8682
8801
|
className: cn("stn-wrap", isGnbRight && "stn-wrap--gnb-right", wrapClassName),
|
|
8683
8802
|
children: [
|
|
8684
8803
|
layer0,
|
|
8685
|
-
utilities ? /* @__PURE__ */
|
|
8686
|
-
/* @__PURE__ */
|
|
8804
|
+
utilities ? /* @__PURE__ */ jsx72("div", { className: "stn-page-utilities", "data-stn-layer-role": "utility", children: utilities }) : null,
|
|
8805
|
+
/* @__PURE__ */ jsxs52(
|
|
8687
8806
|
"main",
|
|
8688
8807
|
{
|
|
8689
8808
|
id: containerId,
|
|
@@ -8692,9 +8811,9 @@ function StnLayerShell({
|
|
|
8692
8811
|
className: cn("stn-layer-1", scrollable && "scroll", containerClassName),
|
|
8693
8812
|
children: [
|
|
8694
8813
|
!isGnbRight && gnb,
|
|
8695
|
-
/* @__PURE__ */
|
|
8696
|
-
header ? /* @__PURE__ */
|
|
8697
|
-
/* @__PURE__ */
|
|
8814
|
+
/* @__PURE__ */ jsxs52("div", { className: "stn-layer-1__main", children: [
|
|
8815
|
+
header ? /* @__PURE__ */ jsx72("header", { className: "stn-layer-1__header", children: header }) : null,
|
|
8816
|
+
/* @__PURE__ */ jsx72("div", { className: cn("stn-layer-1__body", scrollable && "stn-scroll", contentClassName), children: resolvedMainContent })
|
|
8698
8817
|
] }),
|
|
8699
8818
|
isGnbRight && gnb
|
|
8700
8819
|
]
|
|
@@ -8707,7 +8826,7 @@ function StnLayerShell({
|
|
|
8707
8826
|
}
|
|
8708
8827
|
|
|
8709
8828
|
// src/layouts/StnListViewLayout.tsx
|
|
8710
|
-
import { jsx as
|
|
8829
|
+
import { jsx as jsx73, jsxs as jsxs53 } from "react/jsx-runtime";
|
|
8711
8830
|
function StnListViewLayoutBody({
|
|
8712
8831
|
search,
|
|
8713
8832
|
sidebar,
|
|
@@ -8718,13 +8837,13 @@ function StnListViewLayoutBody({
|
|
|
8718
8837
|
className
|
|
8719
8838
|
}) {
|
|
8720
8839
|
const lnbClass = lnbSide === "right" ? "stn-page-scaffold__lnb lnb_box lnb_box_right" : "stn-page-scaffold__lnb lnb_box";
|
|
8721
|
-
const sidebarAside = sidebar ? /* @__PURE__ */
|
|
8722
|
-
return /* @__PURE__ */
|
|
8840
|
+
const sidebarAside = sidebar ? /* @__PURE__ */ jsx73("aside", { className: lnbClass, children: sidebar }) : null;
|
|
8841
|
+
return /* @__PURE__ */ jsx73(
|
|
8723
8842
|
StnContainer,
|
|
8724
8843
|
{
|
|
8725
8844
|
maxWidth: false,
|
|
8726
8845
|
className: cn("stn-list-view-layout__body", className),
|
|
8727
|
-
children: /* @__PURE__ */
|
|
8846
|
+
children: /* @__PURE__ */ jsxs53(
|
|
8728
8847
|
StnStack,
|
|
8729
8848
|
{
|
|
8730
8849
|
direction: "row",
|
|
@@ -8732,19 +8851,19 @@ function StnListViewLayoutBody({
|
|
|
8732
8851
|
className: "stn-list-view__main",
|
|
8733
8852
|
children: [
|
|
8734
8853
|
lnbSide === "left" ? sidebarAside : null,
|
|
8735
|
-
/* @__PURE__ */
|
|
8854
|
+
/* @__PURE__ */ jsxs53(
|
|
8736
8855
|
StnStack,
|
|
8737
8856
|
{
|
|
8738
8857
|
direction: "column",
|
|
8739
8858
|
spacing: 2,
|
|
8740
8859
|
className: "stn-list-view__content-stack",
|
|
8741
8860
|
children: [
|
|
8742
|
-
search ? /* @__PURE__ */
|
|
8743
|
-
/* @__PURE__ */
|
|
8861
|
+
search ? /* @__PURE__ */ jsx73("div", { className: "stn-page-scaffold__search search_area", children: search }) : null,
|
|
8862
|
+
/* @__PURE__ */ jsx73(
|
|
8744
8863
|
"div",
|
|
8745
8864
|
{
|
|
8746
8865
|
className: "stn-page-scaffold__content content_box",
|
|
8747
|
-
children: children ?? /* @__PURE__ */
|
|
8866
|
+
children: children ?? /* @__PURE__ */ jsxs53("div", { className: "stn-table stn-table--fill", children: [
|
|
8748
8867
|
table,
|
|
8749
8868
|
pagination
|
|
8750
8869
|
] })
|
|
@@ -8776,7 +8895,7 @@ function StnListViewLayoutRoot({
|
|
|
8776
8895
|
}) {
|
|
8777
8896
|
const bare = bareProp ?? noShell ?? false;
|
|
8778
8897
|
const hasLnbClass = lnbSide === "right" ? "has_lnb_right" : "has_lnb";
|
|
8779
|
-
const body = /* @__PURE__ */
|
|
8898
|
+
const body = /* @__PURE__ */ jsx73(
|
|
8780
8899
|
StnListViewLayoutBody,
|
|
8781
8900
|
{
|
|
8782
8901
|
search,
|
|
@@ -8791,10 +8910,10 @@ function StnListViewLayoutRoot({
|
|
|
8791
8910
|
if (bare) {
|
|
8792
8911
|
return body;
|
|
8793
8912
|
}
|
|
8794
|
-
const renderedHeader = header === null ? null : header !== void 0 ? header : /* @__PURE__ */
|
|
8795
|
-
return /* @__PURE__ */
|
|
8913
|
+
const renderedHeader = header === null ? null : header !== void 0 ? header : /* @__PURE__ */ jsx73("div", { className: "stn-layer-1__header", children: /* @__PURE__ */ jsx73(StnHeader, { variant: "page", children: /* @__PURE__ */ jsx73(StnHeader.Left, { children: /* @__PURE__ */ jsx73(StnHeaderPageTitle, { children: title }) }) }) });
|
|
8914
|
+
return /* @__PURE__ */ jsxs53("div", { className: cn("stn-list-view-layout", "stn-layer-1", className), ...rest, children: [
|
|
8796
8915
|
renderedHeader,
|
|
8797
|
-
/* @__PURE__ */
|
|
8916
|
+
/* @__PURE__ */ jsx73(
|
|
8798
8917
|
"div",
|
|
8799
8918
|
{
|
|
8800
8919
|
className: cn("stn-content-area", sidebar ? hasLnbClass : null, search ? "has_sch" : null),
|
|
@@ -8804,10 +8923,10 @@ function StnListViewLayoutRoot({
|
|
|
8804
8923
|
] });
|
|
8805
8924
|
}
|
|
8806
8925
|
function StnListViewLayoutHeader({ className, children, ...rest }) {
|
|
8807
|
-
return /* @__PURE__ */
|
|
8926
|
+
return /* @__PURE__ */ jsx73("div", { className: cn("stn-layer-1__header", className), ...rest, children });
|
|
8808
8927
|
}
|
|
8809
8928
|
function StnListViewLayoutSearch({ className, children, ...rest }) {
|
|
8810
|
-
return /* @__PURE__ */
|
|
8929
|
+
return /* @__PURE__ */ jsx73("div", { className: cn("search_area", className), ...rest, children });
|
|
8811
8930
|
}
|
|
8812
8931
|
function StnListViewLayoutSidebar({
|
|
8813
8932
|
side = "left",
|
|
@@ -8816,16 +8935,16 @@ function StnListViewLayoutSidebar({
|
|
|
8816
8935
|
...rest
|
|
8817
8936
|
}) {
|
|
8818
8937
|
const lnbClass = side === "right" ? "lnb_box_right" : "lnb_box";
|
|
8819
|
-
return /* @__PURE__ */
|
|
8938
|
+
return /* @__PURE__ */ jsx73("aside", { className: cn(lnbClass, className), ...rest, children });
|
|
8820
8939
|
}
|
|
8821
8940
|
function StnListViewLayoutContent({ className, children, ...rest }) {
|
|
8822
|
-
return /* @__PURE__ */
|
|
8941
|
+
return /* @__PURE__ */ jsx73("div", { className: cn("content_box", className), ...rest, children });
|
|
8823
8942
|
}
|
|
8824
8943
|
function StnListViewLayoutTable({ className, children, ...rest }) {
|
|
8825
|
-
return /* @__PURE__ */
|
|
8944
|
+
return /* @__PURE__ */ jsx73("div", { className: cn("stn-table", className), ...rest, children });
|
|
8826
8945
|
}
|
|
8827
8946
|
function StnListViewLayoutPagination({ className, children, ...rest }) {
|
|
8828
|
-
return /* @__PURE__ */
|
|
8947
|
+
return /* @__PURE__ */ jsx73("div", { className: cn("stn-list-view-layout__pagination-wrap", className), ...rest, children });
|
|
8829
8948
|
}
|
|
8830
8949
|
var StnListViewLayout = Object.assign(StnListViewLayoutRoot, {
|
|
8831
8950
|
Body: StnListViewLayoutBody,
|
|
@@ -8859,13 +8978,13 @@ import {
|
|
|
8859
8978
|
} from "@stn-uiux/pub-ui/data/stnLayout";
|
|
8860
8979
|
|
|
8861
8980
|
// src/patterns/dashboard/StnMapCanvas.tsx
|
|
8862
|
-
import { jsx as
|
|
8981
|
+
import { jsx as jsx74 } from "react/jsx-runtime";
|
|
8863
8982
|
function StnMapCanvas({
|
|
8864
8983
|
children,
|
|
8865
8984
|
className,
|
|
8866
8985
|
...rest
|
|
8867
8986
|
}) {
|
|
8868
|
-
return /* @__PURE__ */
|
|
8987
|
+
return /* @__PURE__ */ jsx74(
|
|
8869
8988
|
"div",
|
|
8870
8989
|
{
|
|
8871
8990
|
className: cn("stn-map-canvas", className),
|
|
@@ -8877,7 +8996,7 @@ function StnMapCanvas({
|
|
|
8877
8996
|
}
|
|
8878
8997
|
|
|
8879
8998
|
// src/patterns/dashboard/StnDashboard.tsx
|
|
8880
|
-
import { jsx as
|
|
8999
|
+
import { jsx as jsx75 } from "react/jsx-runtime";
|
|
8881
9000
|
var fillStyle = {
|
|
8882
9001
|
flex: "1 1 0%",
|
|
8883
9002
|
minHeight: 0,
|
|
@@ -8896,7 +9015,7 @@ function StnDashboardRoot({
|
|
|
8896
9015
|
}) {
|
|
8897
9016
|
const isLeft = widgetPosition === "left";
|
|
8898
9017
|
const isBoth = widgetPosition === "both";
|
|
8899
|
-
return /* @__PURE__ */
|
|
9018
|
+
return /* @__PURE__ */ jsx75(
|
|
8900
9019
|
"div",
|
|
8901
9020
|
{
|
|
8902
9021
|
className: cn(
|
|
@@ -8925,7 +9044,7 @@ function StnDashboardLeft({
|
|
|
8925
9044
|
style,
|
|
8926
9045
|
...rest
|
|
8927
9046
|
}) {
|
|
8928
|
-
return /* @__PURE__ */
|
|
9047
|
+
return /* @__PURE__ */ jsx75(
|
|
8929
9048
|
"div",
|
|
8930
9049
|
{
|
|
8931
9050
|
className: cn("stn-dashboard__left", className),
|
|
@@ -8951,7 +9070,7 @@ function StnDashboardRight({
|
|
|
8951
9070
|
style,
|
|
8952
9071
|
...rest
|
|
8953
9072
|
}) {
|
|
8954
|
-
return /* @__PURE__ */
|
|
9073
|
+
return /* @__PURE__ */ jsx75(
|
|
8955
9074
|
"div",
|
|
8956
9075
|
{
|
|
8957
9076
|
className: cn("stn-dashboard__right", className),
|
|
@@ -8979,7 +9098,7 @@ function StnDashboardTopRight({
|
|
|
8979
9098
|
className,
|
|
8980
9099
|
...rest
|
|
8981
9100
|
}) {
|
|
8982
|
-
return /* @__PURE__ */
|
|
9101
|
+
return /* @__PURE__ */ jsx75(
|
|
8983
9102
|
"div",
|
|
8984
9103
|
{
|
|
8985
9104
|
className: cn("stn-dashboard__top-right", className),
|
|
@@ -8998,9 +9117,9 @@ var StnDashboard = Object.assign(StnDashboardRoot, {
|
|
|
8998
9117
|
});
|
|
8999
9118
|
|
|
9000
9119
|
// src/patterns/scaffold/StnPageScaffold.tsx
|
|
9001
|
-
import { jsx as
|
|
9120
|
+
import { jsx as jsx76, jsxs as jsxs54 } from "react/jsx-runtime";
|
|
9002
9121
|
function StnPageScaffoldRoot({ children, className, ...rest }) {
|
|
9003
|
-
return /* @__PURE__ */
|
|
9122
|
+
return /* @__PURE__ */ jsx76(
|
|
9004
9123
|
"div",
|
|
9005
9124
|
{
|
|
9006
9125
|
className: cn("stn-page-scaffold", className),
|
|
@@ -9017,9 +9136,9 @@ function StnPageScaffoldRegion({
|
|
|
9017
9136
|
className,
|
|
9018
9137
|
...rest
|
|
9019
9138
|
}) {
|
|
9020
|
-
return /* @__PURE__ */
|
|
9021
|
-
/* @__PURE__ */
|
|
9022
|
-
hint ? /* @__PURE__ */
|
|
9139
|
+
return /* @__PURE__ */ jsxs54("div", { className: cn("stn-page-scaffold__region", className), "data-stn-page-scaffold": "region", ...rest, children: [
|
|
9140
|
+
/* @__PURE__ */ jsx76("span", { className: "stn-page-scaffold__region-label", children: label }),
|
|
9141
|
+
hint ? /* @__PURE__ */ jsx76("span", { className: "stn-page-scaffold__region-hint", children: hint }) : null,
|
|
9023
9142
|
children
|
|
9024
9143
|
] });
|
|
9025
9144
|
}
|
|
@@ -9030,7 +9149,7 @@ function StnPageScaffoldMapPlaceholder({
|
|
|
9030
9149
|
children,
|
|
9031
9150
|
...rest
|
|
9032
9151
|
}) {
|
|
9033
|
-
return /* @__PURE__ */
|
|
9152
|
+
return /* @__PURE__ */ jsx76("div", { className: "stn-widget shell-canvas stn-map-canvas", "data-stn-dashboard": "canvas", children: /* @__PURE__ */ jsxs54(
|
|
9034
9153
|
"div",
|
|
9035
9154
|
{
|
|
9036
9155
|
className: cn("stn-page-scaffold__canvas-placeholder", className),
|
|
@@ -9038,8 +9157,8 @@ function StnPageScaffoldMapPlaceholder({
|
|
|
9038
9157
|
role: "status",
|
|
9039
9158
|
...rest,
|
|
9040
9159
|
children: [
|
|
9041
|
-
/* @__PURE__ */
|
|
9042
|
-
note ? /* @__PURE__ */
|
|
9160
|
+
/* @__PURE__ */ jsx76("p", { className: "stn-page-scaffold__canvas-placeholder-title", children: message }),
|
|
9161
|
+
note ? /* @__PURE__ */ jsx76("p", { className: "stn-page-scaffold__canvas-placeholder-note", children: note }) : null,
|
|
9043
9162
|
children
|
|
9044
9163
|
]
|
|
9045
9164
|
}
|
|
@@ -9050,7 +9169,7 @@ function StnPageScaffoldMapCanvas({
|
|
|
9050
9169
|
children,
|
|
9051
9170
|
...rest
|
|
9052
9171
|
}) {
|
|
9053
|
-
return /* @__PURE__ */
|
|
9172
|
+
return /* @__PURE__ */ jsx76(
|
|
9054
9173
|
"div",
|
|
9055
9174
|
{
|
|
9056
9175
|
className: cn("stn-widget", "shell-canvas", "stn-map-canvas", "stn-page-scaffold__canvas", className),
|
|
@@ -9063,7 +9182,7 @@ function StnPageScaffoldMapCanvas({
|
|
|
9063
9182
|
}
|
|
9064
9183
|
function StnPageScaffoldLayer({ label, hint, children, className, ...layerProps }) {
|
|
9065
9184
|
const labelText = label ? hint ? `${label} \xB7 ${hint}` : label : void 0;
|
|
9066
|
-
return /* @__PURE__ */
|
|
9185
|
+
return /* @__PURE__ */ jsx76(
|
|
9067
9186
|
StnLayer2,
|
|
9068
9187
|
{
|
|
9069
9188
|
className: cn(
|
|
@@ -9110,25 +9229,25 @@ function DashboardPageScaffold({
|
|
|
9110
9229
|
const isLeft = widgetPosition === "left";
|
|
9111
9230
|
const isBoth = widgetPosition === "both";
|
|
9112
9231
|
const isNone = widgetPosition === "none" || !showRightRegion;
|
|
9113
|
-
const mapColumn = /* @__PURE__ */
|
|
9114
|
-
/* @__PURE__ */
|
|
9232
|
+
const mapColumn = /* @__PURE__ */ jsxs54(StnDashboard.Left, { children: [
|
|
9233
|
+
/* @__PURE__ */ jsx76(StnPageScaffold.MapPlaceholder, { message: finalMapMessage, note: finalMapNote }),
|
|
9115
9234
|
faultPanel
|
|
9116
9235
|
] });
|
|
9117
|
-
const rightWidgets = right ?? /* @__PURE__ */
|
|
9118
|
-
const leftWidgets = left ?? right ?? /* @__PURE__ */
|
|
9119
|
-
const dashboardGrid = bodyEmpty ? /* @__PURE__ */
|
|
9120
|
-
/* @__PURE__ */
|
|
9236
|
+
const rightWidgets = right ?? /* @__PURE__ */ jsx76(StnPageScaffold.Region, { label: "dashboard_right", hint: "\uC704\uC82F\xB7\uC7A5\uC560 \uD328\uB110" });
|
|
9237
|
+
const leftWidgets = left ?? right ?? /* @__PURE__ */ jsx76(StnPageScaffold.Region, { label: "dashboard_right", hint: "\uC88C\uCE21 \uC704\uC82F\xB7\uC7A5\uC560 \uD328\uB110" });
|
|
9238
|
+
const dashboardGrid = bodyEmpty ? /* @__PURE__ */ jsx76(StnDashboard, { empty: true, widgetPosition, "data-stn-page-scaffold": "dashboard-empty" }) : isBoth ? /* @__PURE__ */ jsxs54(StnDashboard, { widgetPosition: "both", children: [
|
|
9239
|
+
/* @__PURE__ */ jsx76(StnDashboard.Right, { children: leftWidgets }),
|
|
9121
9240
|
mapColumn,
|
|
9122
|
-
/* @__PURE__ */
|
|
9123
|
-
] }) : isLeft ? /* @__PURE__ */
|
|
9124
|
-
/* @__PURE__ */
|
|
9241
|
+
/* @__PURE__ */ jsx76(StnDashboard.Right, { children: rightWidgets })
|
|
9242
|
+
] }) : isLeft ? /* @__PURE__ */ jsxs54(StnDashboard, { widgetPosition: "left", children: [
|
|
9243
|
+
/* @__PURE__ */ jsx76(StnDashboard.Right, { children: leftWidgets }),
|
|
9125
9244
|
mapColumn
|
|
9126
|
-
] }) : /* @__PURE__ */
|
|
9245
|
+
] }) : /* @__PURE__ */ jsxs54(StnDashboard, { widgetPosition: isNone ? "none" : "right", children: [
|
|
9127
9246
|
mapColumn,
|
|
9128
|
-
!isNone ? /* @__PURE__ */
|
|
9247
|
+
!isNone ? /* @__PURE__ */ jsx76(StnDashboard.Right, { children: rightWidgets }) : null
|
|
9129
9248
|
] });
|
|
9130
9249
|
const contentNode = children ?? dashboardGrid;
|
|
9131
|
-
return /* @__PURE__ */
|
|
9250
|
+
return /* @__PURE__ */ jsx76(
|
|
9132
9251
|
StnLayerShell,
|
|
9133
9252
|
{
|
|
9134
9253
|
gnb,
|
|
@@ -9137,7 +9256,7 @@ function DashboardPageScaffold({
|
|
|
9137
9256
|
layer0,
|
|
9138
9257
|
layer2,
|
|
9139
9258
|
...shellProps,
|
|
9140
|
-
children: /* @__PURE__ */
|
|
9259
|
+
children: /* @__PURE__ */ jsx76(
|
|
9141
9260
|
StnContainer,
|
|
9142
9261
|
{
|
|
9143
9262
|
maxWidth: false,
|
|
@@ -9151,16 +9270,16 @@ function DashboardPageScaffold({
|
|
|
9151
9270
|
}
|
|
9152
9271
|
|
|
9153
9272
|
// src/patterns/scaffold/AlertCenterPageScaffold.tsx
|
|
9154
|
-
import { useMemo as useMemo5, useState as
|
|
9273
|
+
import { useMemo as useMemo5, useState as useState20 } from "react";
|
|
9155
9274
|
import {
|
|
9156
9275
|
STN_ALERT_CENTER_DEMO_ALERTS,
|
|
9157
9276
|
STN_ALERT_CENTER_DEMO_DEPLOY,
|
|
9158
9277
|
STN_ALERT_CENTER_DEMO_WORK
|
|
9159
9278
|
} from "@stn-uiux/pub-ui/data/stnAlertCenter";
|
|
9160
9279
|
import { systemIconSrc } from "@stn-uiux/pub-ui/data/stnSystemIcons";
|
|
9161
|
-
import { Fragment as Fragment10, jsx as
|
|
9280
|
+
import { Fragment as Fragment10, jsx as jsx77, jsxs as jsxs55 } from "react/jsx-runtime";
|
|
9162
9281
|
function defaultTopologyHeader(_clock) {
|
|
9163
|
-
return /* @__PURE__ */
|
|
9282
|
+
return /* @__PURE__ */ jsx77(StnHeader, { variant: "widget" });
|
|
9164
9283
|
}
|
|
9165
9284
|
function AlertCenterPageScaffold({
|
|
9166
9285
|
gnbAlertPanel,
|
|
@@ -9177,9 +9296,9 @@ function AlertCenterPageScaffold({
|
|
|
9177
9296
|
defaultGnbOpen = true,
|
|
9178
9297
|
...shellProps
|
|
9179
9298
|
}) {
|
|
9180
|
-
const [gnbOpen, setGnbOpen] =
|
|
9299
|
+
const [gnbOpen, setGnbOpen] = useState20(defaultGnbOpen);
|
|
9181
9300
|
const panel = useMemo5(
|
|
9182
|
-
() => gnbAlertPanel ?? /* @__PURE__ */
|
|
9301
|
+
() => gnbAlertPanel ?? /* @__PURE__ */ jsx77(
|
|
9183
9302
|
StnAlertCenterPanel,
|
|
9184
9303
|
{
|
|
9185
9304
|
alerts: STN_ALERT_CENTER_DEMO_ALERTS,
|
|
@@ -9190,26 +9309,26 @@ function AlertCenterPageScaffold({
|
|
|
9190
9309
|
[gnbAlertPanel]
|
|
9191
9310
|
);
|
|
9192
9311
|
const sideNav = useMemo5(
|
|
9193
|
-
() => gnbProp ?? /* @__PURE__ */
|
|
9194
|
-
/* @__PURE__ */
|
|
9312
|
+
() => gnbProp ?? /* @__PURE__ */ jsxs55(Fragment10, { children: [
|
|
9313
|
+
/* @__PURE__ */ jsxs55(
|
|
9195
9314
|
StnSideNavigation,
|
|
9196
9315
|
{
|
|
9197
9316
|
collapsed: !gnbOpen,
|
|
9198
9317
|
onCollapseChange: (col) => setGnbOpen(!col),
|
|
9199
9318
|
children: [
|
|
9200
|
-
/* @__PURE__ */
|
|
9201
|
-
/* @__PURE__ */
|
|
9202
|
-
/* @__PURE__ */
|
|
9319
|
+
/* @__PURE__ */ jsxs55(StnSideNavigation.Header, { children: [
|
|
9320
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Logo, {}),
|
|
9321
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Toggle, {})
|
|
9203
9322
|
] }),
|
|
9204
|
-
/* @__PURE__ */
|
|
9205
|
-
/* @__PURE__ */
|
|
9206
|
-
/* @__PURE__ */
|
|
9207
|
-
/* @__PURE__ */
|
|
9323
|
+
/* @__PURE__ */ jsxs55(StnSideNavigation.Menu, { children: [
|
|
9324
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/layout-grid"), label: "\uBA54\uC778 \uB300\uC2DC\uBCF4\uB4DC", active: true }),
|
|
9325
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/server_2"), label: "\uC11C\uBC84 \uBAA8\uB2C8\uD130\uB9C1" }),
|
|
9326
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/activity"), label: "\uB124\uD2B8\uC6CC\uD06C \uBD84\uC11D" })
|
|
9208
9327
|
] }),
|
|
9209
|
-
/* @__PURE__ */
|
|
9210
|
-
/* @__PURE__ */
|
|
9211
|
-
/* @__PURE__ */
|
|
9212
|
-
/* @__PURE__ */
|
|
9328
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Spacer, {}),
|
|
9329
|
+
/* @__PURE__ */ jsxs55(StnSideNavigation.Footer, { curved: true, children: [
|
|
9330
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Watermark, {}),
|
|
9331
|
+
/* @__PURE__ */ jsx77(
|
|
9213
9332
|
StnSideNavigation.Item,
|
|
9214
9333
|
{
|
|
9215
9334
|
iconSrc: systemIconSrc("line/bell"),
|
|
@@ -9218,7 +9337,7 @@ function AlertCenterPageScaffold({
|
|
|
9218
9337
|
onClick: void 0
|
|
9219
9338
|
}
|
|
9220
9339
|
),
|
|
9221
|
-
/* @__PURE__ */
|
|
9340
|
+
/* @__PURE__ */ jsx77(StnSideNavigation.Item, { iconSrc: systemIconSrc("line/settings"), label: "\uC124\uC815" })
|
|
9222
9341
|
] })
|
|
9223
9342
|
]
|
|
9224
9343
|
}
|
|
@@ -9227,8 +9346,8 @@ function AlertCenterPageScaffold({
|
|
|
9227
9346
|
] }),
|
|
9228
9347
|
[gnbProp, gnbOpen, panel]
|
|
9229
9348
|
);
|
|
9230
|
-
const faultSlot = faultPanel ?? (showFaultPanelPlaceholder ? /* @__PURE__ */
|
|
9231
|
-
return /* @__PURE__ */
|
|
9349
|
+
const faultSlot = faultPanel ?? (showFaultPanelPlaceholder ? /* @__PURE__ */ jsx77("div", { className: "wrap_real_time stn-page-scaffold__fault-ph", children: /* @__PURE__ */ jsx77(StnPageScaffold.Region, { label: "\uC2E4\uC2DC\uAC04 \uC7A5\uC560 \uD604\uD669", hint: "StnWidget shell=fault-panel \xB7 \uC120\uD0DD" }) }) : null);
|
|
9350
|
+
return /* @__PURE__ */ jsx77(
|
|
9232
9351
|
DashboardPageScaffold,
|
|
9233
9352
|
{
|
|
9234
9353
|
gnb: sideNav,
|
|
@@ -9236,7 +9355,7 @@ function AlertCenterPageScaffold({
|
|
|
9236
9355
|
mapMessage,
|
|
9237
9356
|
mapNote,
|
|
9238
9357
|
faultPanel: faultSlot,
|
|
9239
|
-
right: right ?? /* @__PURE__ */
|
|
9358
|
+
right: right ?? /* @__PURE__ */ jsx77(AlertCenterDashboard, {}),
|
|
9240
9359
|
wrapId,
|
|
9241
9360
|
wrapClassName: "stn-page--map-bg",
|
|
9242
9361
|
...shellProps
|
|
@@ -9245,8 +9364,8 @@ function AlertCenterPageScaffold({
|
|
|
9245
9364
|
}
|
|
9246
9365
|
|
|
9247
9366
|
// src/patterns/scaffold/LoginPageScaffold.tsx
|
|
9248
|
-
import { useState as
|
|
9249
|
-
import { jsx as
|
|
9367
|
+
import { useState as useState21 } from "react";
|
|
9368
|
+
import { jsx as jsx78, jsxs as jsxs56 } from "react/jsx-runtime";
|
|
9250
9369
|
var LOGIN_TABS = [
|
|
9251
9370
|
{ value: "normal", label: "\uC77C\uBC18 \uB85C\uADF8\uC778" },
|
|
9252
9371
|
{ value: "social", label: "\uC18C\uC15C \uB85C\uADF8\uC778" }
|
|
@@ -9257,15 +9376,15 @@ function DefaultLoginForm({
|
|
|
9257
9376
|
signUpHref = "#",
|
|
9258
9377
|
recoverHref = "#"
|
|
9259
9378
|
}) {
|
|
9260
|
-
const [mode, setMode] =
|
|
9261
|
-
const [userId, setUserId] =
|
|
9262
|
-
const [password, setPassword] =
|
|
9379
|
+
const [mode, setMode] = useState21("normal");
|
|
9380
|
+
const [userId, setUserId] = useState21("");
|
|
9381
|
+
const [password, setPassword] = useState21("");
|
|
9263
9382
|
function handleSubmit(e) {
|
|
9264
9383
|
e.preventDefault();
|
|
9265
9384
|
onLogin?.(userId, password);
|
|
9266
9385
|
}
|
|
9267
|
-
return /* @__PURE__ */
|
|
9268
|
-
/* @__PURE__ */
|
|
9386
|
+
return /* @__PURE__ */ jsxs56(StnLoginFormStack, { onSubmit: handleSubmit, children: [
|
|
9387
|
+
/* @__PURE__ */ jsx78(
|
|
9269
9388
|
StnSegmented,
|
|
9270
9389
|
{
|
|
9271
9390
|
"aria-label": "\uB85C\uADF8\uC778 \uBC29\uC2DD",
|
|
@@ -9274,8 +9393,8 @@ function DefaultLoginForm({
|
|
|
9274
9393
|
options: LOGIN_TABS
|
|
9275
9394
|
}
|
|
9276
9395
|
),
|
|
9277
|
-
mode === "normal" ? /* @__PURE__ */
|
|
9278
|
-
/* @__PURE__ */
|
|
9396
|
+
mode === "normal" ? /* @__PURE__ */ jsxs56(StnLoginFormFields, { children: [
|
|
9397
|
+
/* @__PURE__ */ jsx78(
|
|
9279
9398
|
StnLoginTextField,
|
|
9280
9399
|
{
|
|
9281
9400
|
icon: "line/user",
|
|
@@ -9287,7 +9406,7 @@ function DefaultLoginForm({
|
|
|
9287
9406
|
"aria-label": "\uC544\uC774\uB514"
|
|
9288
9407
|
}
|
|
9289
9408
|
),
|
|
9290
|
-
/* @__PURE__ */
|
|
9409
|
+
/* @__PURE__ */ jsx78(
|
|
9291
9410
|
StnLoginTextField,
|
|
9292
9411
|
{
|
|
9293
9412
|
icon: "line/lock",
|
|
@@ -9300,11 +9419,11 @@ function DefaultLoginForm({
|
|
|
9300
9419
|
"aria-label": "\uBE44\uBC00\uBC88\uD638"
|
|
9301
9420
|
}
|
|
9302
9421
|
)
|
|
9303
|
-
] }) : socialContent ?? /* @__PURE__ */
|
|
9304
|
-
/* @__PURE__ */
|
|
9305
|
-
/* @__PURE__ */
|
|
9306
|
-
/* @__PURE__ */
|
|
9307
|
-
/* @__PURE__ */
|
|
9422
|
+
] }) : socialContent ?? /* @__PURE__ */ jsx78(StnLoginPlaceholder, {}),
|
|
9423
|
+
/* @__PURE__ */ jsx78(StnButton, { type: "submit", size: "xl", fullWidth: true, children: "\uB85C\uADF8\uC778" }),
|
|
9424
|
+
/* @__PURE__ */ jsxs56(StnLoginFormLinks, { children: [
|
|
9425
|
+
/* @__PURE__ */ jsx78("a", { href: signUpHref, children: "\uD68C\uC6D0\uAC00\uC785" }),
|
|
9426
|
+
/* @__PURE__ */ jsx78("a", { href: recoverHref, children: "\uC544\uC774\uB514 / \uBE44\uBC00\uBC88\uD638 \uCC3E\uAE30" })
|
|
9308
9427
|
] })
|
|
9309
9428
|
] });
|
|
9310
9429
|
}
|
|
@@ -9318,16 +9437,16 @@ function DefaultLoginCard({
|
|
|
9318
9437
|
signUpHref,
|
|
9319
9438
|
recoverHref
|
|
9320
9439
|
}) {
|
|
9321
|
-
return /* @__PURE__ */
|
|
9440
|
+
return /* @__PURE__ */ jsx78(
|
|
9322
9441
|
StnLoginCard,
|
|
9323
9442
|
{
|
|
9324
9443
|
glow,
|
|
9325
9444
|
variant,
|
|
9326
|
-
brand: /* @__PURE__ */
|
|
9327
|
-
logo ?? /* @__PURE__ */
|
|
9328
|
-
/* @__PURE__ */
|
|
9445
|
+
brand: /* @__PURE__ */ jsxs56(StnLoginBrandStack, { children: [
|
|
9446
|
+
logo ?? /* @__PURE__ */ jsx78(StnLogo, { variant: "vertical", size: "xl" }),
|
|
9447
|
+
/* @__PURE__ */ jsx78("p", { className: "stn-login-card__caption", children: productCaption })
|
|
9329
9448
|
] }),
|
|
9330
|
-
children: /* @__PURE__ */
|
|
9449
|
+
children: /* @__PURE__ */ jsx78(
|
|
9331
9450
|
DefaultLoginForm,
|
|
9332
9451
|
{
|
|
9333
9452
|
onLogin,
|
|
@@ -9353,8 +9472,8 @@ function LoginPageScaffold({
|
|
|
9353
9472
|
recoverHref,
|
|
9354
9473
|
...shellProps
|
|
9355
9474
|
}) {
|
|
9356
|
-
const resolvedLayer0 = layer0 ?? /* @__PURE__ */
|
|
9357
|
-
const resolvedCard = children ?? /* @__PURE__ */
|
|
9475
|
+
const resolvedLayer0 = layer0 ?? /* @__PURE__ */ jsx78(StnLayer0Background, { variant: "login" });
|
|
9476
|
+
const resolvedCard = children ?? /* @__PURE__ */ jsx78(
|
|
9358
9477
|
DefaultLoginCard,
|
|
9359
9478
|
{
|
|
9360
9479
|
logo,
|
|
@@ -9367,7 +9486,7 @@ function LoginPageScaffold({
|
|
|
9367
9486
|
recoverHref
|
|
9368
9487
|
}
|
|
9369
9488
|
);
|
|
9370
|
-
return /* @__PURE__ */
|
|
9489
|
+
return /* @__PURE__ */ jsxs56(
|
|
9371
9490
|
"div",
|
|
9372
9491
|
{
|
|
9373
9492
|
className: cn("stn-wrap stn-page--login", wrapClassName),
|
|
@@ -9375,7 +9494,7 @@ function LoginPageScaffold({
|
|
|
9375
9494
|
...shellProps,
|
|
9376
9495
|
children: [
|
|
9377
9496
|
resolvedLayer0,
|
|
9378
|
-
/* @__PURE__ */
|
|
9497
|
+
/* @__PURE__ */ jsx78("div", { className: "stn-login", children: resolvedCard })
|
|
9379
9498
|
]
|
|
9380
9499
|
}
|
|
9381
9500
|
);
|
|
@@ -9404,7 +9523,7 @@ import {
|
|
|
9404
9523
|
|
|
9405
9524
|
// src/patterns/toolbar/StnFloatingToolbar.tsx
|
|
9406
9525
|
import React3 from "react";
|
|
9407
|
-
import { jsx as
|
|
9526
|
+
import { jsx as jsx79, jsxs as jsxs57 } from "react/jsx-runtime";
|
|
9408
9527
|
var DEFAULT_MAP_MODES = [
|
|
9409
9528
|
{ value: "sphere", label: "\uAD6C\uBA74" },
|
|
9410
9529
|
{ value: "plane", label: "\uD3C9\uBA74" },
|
|
@@ -9414,7 +9533,7 @@ var StnFloatingToolbar = React3.forwardRef(
|
|
|
9414
9533
|
({ placement = "none", orientation = "horizontal", className, children, ...restProps }, ref) => {
|
|
9415
9534
|
const placementClass = placement !== "none" ? `stn-floating-toolbar--${placement}` : "";
|
|
9416
9535
|
const orientationClass = orientation === "vertical" ? "stn-floating-toolbar--vertical" : "";
|
|
9417
|
-
return /* @__PURE__ */
|
|
9536
|
+
return /* @__PURE__ */ jsx79(
|
|
9418
9537
|
"div",
|
|
9419
9538
|
{
|
|
9420
9539
|
ref,
|
|
@@ -9447,7 +9566,7 @@ var StnMapToolbar = React3.forwardRef(
|
|
|
9447
9566
|
children,
|
|
9448
9567
|
...restProps
|
|
9449
9568
|
}, ref) => {
|
|
9450
|
-
return /* @__PURE__ */
|
|
9569
|
+
return /* @__PURE__ */ jsxs57(
|
|
9451
9570
|
StnFloatingToolbar,
|
|
9452
9571
|
{
|
|
9453
9572
|
ref,
|
|
@@ -9457,7 +9576,7 @@ var StnMapToolbar = React3.forwardRef(
|
|
|
9457
9576
|
"aria-label": "\uC9C0\uB3C4 \uBC0F \uD1A0\uD3F4\uB85C\uC9C0 \uB3C4\uAD6C \uBAA8\uC74C",
|
|
9458
9577
|
...restProps,
|
|
9459
9578
|
children: [
|
|
9460
|
-
modeOptions && modeOptions.length > 0 && /* @__PURE__ */
|
|
9579
|
+
modeOptions && modeOptions.length > 0 && /* @__PURE__ */ jsx79(
|
|
9461
9580
|
StnDropdown,
|
|
9462
9581
|
{
|
|
9463
9582
|
size: "md",
|
|
@@ -9468,75 +9587,75 @@ var StnMapToolbar = React3.forwardRef(
|
|
|
9468
9587
|
"aria-label": "\uD22C\uC601 \uBAA8\uB4DC \uC120\uD0DD"
|
|
9469
9588
|
}
|
|
9470
9589
|
),
|
|
9471
|
-
onRestore && /* @__PURE__ */
|
|
9590
|
+
onRestore && /* @__PURE__ */ jsx79(
|
|
9472
9591
|
StnButton,
|
|
9473
9592
|
{
|
|
9474
9593
|
variant: buttonVariant,
|
|
9475
9594
|
size: "md",
|
|
9476
9595
|
shape: "square",
|
|
9477
|
-
icon: /* @__PURE__ */
|
|
9478
|
-
/* @__PURE__ */
|
|
9479
|
-
/* @__PURE__ */
|
|
9480
|
-
/* @__PURE__ */
|
|
9596
|
+
icon: /* @__PURE__ */ jsxs57("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: [
|
|
9597
|
+
/* @__PURE__ */ jsx79("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" }),
|
|
9598
|
+
/* @__PURE__ */ jsx79("path", { d: "M3 4.00098V9.00098H8" }),
|
|
9599
|
+
/* @__PURE__ */ jsx79("circle", { cx: "12", cy: "12", r: "1", fill: "currentColor" })
|
|
9481
9600
|
] }),
|
|
9482
9601
|
"aria-label": "\uCD08\uAE30\uD654 (Restore)",
|
|
9483
9602
|
title: "\uCD08\uAE30\uD654 (Restore)",
|
|
9484
9603
|
onClick: onRestore
|
|
9485
9604
|
}
|
|
9486
9605
|
),
|
|
9487
|
-
onFullscreen && /* @__PURE__ */
|
|
9606
|
+
onFullscreen && /* @__PURE__ */ jsx79(
|
|
9488
9607
|
StnButton,
|
|
9489
9608
|
{
|
|
9490
9609
|
variant: buttonVariant,
|
|
9491
9610
|
size: "md",
|
|
9492
9611
|
shape: "square",
|
|
9493
|
-
icon: /* @__PURE__ */
|
|
9494
|
-
/* @__PURE__ */
|
|
9495
|
-
/* @__PURE__ */
|
|
9496
|
-
/* @__PURE__ */
|
|
9497
|
-
/* @__PURE__ */
|
|
9612
|
+
icon: /* @__PURE__ */ jsxs57("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: [
|
|
9613
|
+
/* @__PURE__ */ jsx79("path", { d: "M16 4H20V8" }),
|
|
9614
|
+
/* @__PURE__ */ jsx79("path", { d: "M14 10L20 4" }),
|
|
9615
|
+
/* @__PURE__ */ jsx79("path", { d: "M8 20H4V16" }),
|
|
9616
|
+
/* @__PURE__ */ jsx79("path", { d: "M4 20L10 14" })
|
|
9498
9617
|
] }),
|
|
9499
9618
|
"aria-label": "\uC804\uCCB4\uD654\uBA74",
|
|
9500
9619
|
title: "\uC804\uCCB4\uD654\uBA74",
|
|
9501
9620
|
onClick: onFullscreen
|
|
9502
9621
|
}
|
|
9503
9622
|
),
|
|
9504
|
-
onZoomIn && /* @__PURE__ */
|
|
9623
|
+
onZoomIn && /* @__PURE__ */ jsx79(
|
|
9505
9624
|
StnButton,
|
|
9506
9625
|
{
|
|
9507
9626
|
variant: buttonVariant,
|
|
9508
9627
|
size: "md",
|
|
9509
9628
|
shape: "square",
|
|
9510
|
-
icon: /* @__PURE__ */
|
|
9511
|
-
/* @__PURE__ */
|
|
9512
|
-
/* @__PURE__ */
|
|
9629
|
+
icon: /* @__PURE__ */ jsxs57("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: [
|
|
9630
|
+
/* @__PURE__ */ jsx79("path", { d: "M12 5V19" }),
|
|
9631
|
+
/* @__PURE__ */ jsx79("path", { d: "M5 12H19" })
|
|
9513
9632
|
] }),
|
|
9514
9633
|
"aria-label": "\uD655\uB300",
|
|
9515
9634
|
title: "\uD655\uB300",
|
|
9516
9635
|
onClick: onZoomIn
|
|
9517
9636
|
}
|
|
9518
9637
|
),
|
|
9519
|
-
onZoomOut && /* @__PURE__ */
|
|
9638
|
+
onZoomOut && /* @__PURE__ */ jsx79(
|
|
9520
9639
|
StnButton,
|
|
9521
9640
|
{
|
|
9522
9641
|
variant: buttonVariant,
|
|
9523
9642
|
size: "md",
|
|
9524
9643
|
shape: "square",
|
|
9525
|
-
icon: /* @__PURE__ */
|
|
9644
|
+
icon: /* @__PURE__ */ jsx79("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__ */ jsx79("path", { d: "M5 12H19" }) }),
|
|
9526
9645
|
"aria-label": "\uCD95\uC18C",
|
|
9527
9646
|
title: "\uCD95\uC18C",
|
|
9528
9647
|
onClick: onZoomOut
|
|
9529
9648
|
}
|
|
9530
9649
|
),
|
|
9531
|
-
onRefresh && /* @__PURE__ */
|
|
9650
|
+
onRefresh && /* @__PURE__ */ jsx79(
|
|
9532
9651
|
StnButton,
|
|
9533
9652
|
{
|
|
9534
9653
|
variant: buttonVariant,
|
|
9535
9654
|
size: "md",
|
|
9536
9655
|
shape: "square",
|
|
9537
|
-
icon: /* @__PURE__ */
|
|
9538
|
-
/* @__PURE__ */
|
|
9539
|
-
/* @__PURE__ */
|
|
9656
|
+
icon: /* @__PURE__ */ jsxs57("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: [
|
|
9657
|
+
/* @__PURE__ */ jsx79("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" }),
|
|
9658
|
+
/* @__PURE__ */ jsx79("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" })
|
|
9540
9659
|
] }),
|
|
9541
9660
|
"aria-label": "\uC0C8\uB85C\uACE0\uCE68",
|
|
9542
9661
|
title: "\uC0C8\uB85C\uACE0\uCE68",
|
|
@@ -9769,8 +9888,6 @@ export {
|
|
|
9769
9888
|
StnSectionSide,
|
|
9770
9889
|
StnSectionSidePreset,
|
|
9771
9890
|
StnSegmented,
|
|
9772
|
-
StnSeverityBadge,
|
|
9773
|
-
StnSeverityFilter,
|
|
9774
9891
|
StnSideNavFooter,
|
|
9775
9892
|
StnSideNavGroup,
|
|
9776
9893
|
StnSideNavHeader,
|
|
@@ -9792,7 +9909,6 @@ export {
|
|
|
9792
9909
|
StnStatusDotGroup,
|
|
9793
9910
|
StnStatusFlow,
|
|
9794
9911
|
StnStatusSeverity,
|
|
9795
|
-
StnStatusSeverityFilter,
|
|
9796
9912
|
StnStatusSwitch,
|
|
9797
9913
|
StnSwitch,
|
|
9798
9914
|
StnTable,
|
|
@@ -9805,6 +9921,7 @@ export {
|
|
|
9805
9921
|
StnTableTdCheck,
|
|
9806
9922
|
StnTableTh,
|
|
9807
9923
|
StnTableThCheck,
|
|
9924
|
+
StnTextArea,
|
|
9808
9925
|
StnTextField,
|
|
9809
9926
|
StnToastCloseButton,
|
|
9810
9927
|
StnToastIcon,
|