@stn-uiux/pub-ui-react 0.1.64 → 0.1.66

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 CHANGED
@@ -789,6 +789,8 @@ interface StnSeverityBadgeProps extends ButtonHTMLAttributes<HTMLButtonElement |
789
789
  glow?: boolean;
790
790
  /** glow의 별칭 prop (blur 발광 효과 제어) */
791
791
  blur?: boolean;
792
+ /** 축약 약어 라벨 표출 여부 (true 시 CR · MJ · MN · WR 표출) @default false */
793
+ abbr?: boolean;
792
794
  /** 텍스트 라벨 (미지정 시 기본 라벨 표시) */
793
795
  label?: ReactNode;
794
796
  /** 필터 모드일 때 활성화(선택) 상태 */
package/dist/index.js CHANGED
@@ -1859,6 +1859,12 @@ var SEVERITY_DEFAULT_LABELS = {
1859
1859
  minor: "Minor",
1860
1860
  warning: "Warning"
1861
1861
  };
1862
+ var SEVERITY_ABBR_LABELS = {
1863
+ critical: "CR",
1864
+ major: "MJ",
1865
+ minor: "MN",
1866
+ warning: "WR"
1867
+ };
1862
1868
  var SEVERITY_ICONS = {
1863
1869
  critical: "fill/alert4",
1864
1870
  major: "fill/alert3",
@@ -1874,6 +1880,7 @@ var StnStatusSeverity = forwardRef11(function StnStatusSeverity2({
1874
1880
  iconOnly = false,
1875
1881
  glow = false,
1876
1882
  blur = false,
1883
+ abbr = false,
1877
1884
  label,
1878
1885
  active = false,
1879
1886
  onClick,
@@ -1898,7 +1905,7 @@ var StnStatusSeverity = forwardRef11(function StnStatusSeverity2({
1898
1905
  active ? "is-active" : "",
1899
1906
  className
1900
1907
  ].filter(Boolean).join(" ");
1901
- const defaultLabel = SEVERITY_DEFAULT_LABELS[severity];
1908
+ const defaultLabel = abbr ? SEVERITY_ABBR_LABELS[severity] : SEVERITY_DEFAULT_LABELS[severity];
1902
1909
  const displayLabel = children ?? label ?? defaultLabel;
1903
1910
  const iconName = SEVERITY_ICONS[severity];
1904
1911
  const elementProps = {
@@ -2880,6 +2887,7 @@ var StnSectionSide = forwardRef16(function StnSectionSide2({
2880
2887
  StnScroll,
2881
2888
  {
2882
2889
  orientation: "vertical",
2890
+ size: "thin",
2883
2891
  className: cn("stn-section-side__body", scrollClassName),
2884
2892
  ...scrollRest,
2885
2893
  children
@@ -3879,21 +3887,45 @@ function StnDropdown({
3879
3887
  children: displayLabel
3880
3888
  }
3881
3889
  ),
3882
- /* @__PURE__ */ jsx32("ul", { className: "select_option", role: "listbox", "aria-label": ariaLabel, children: options.map((opt) => /* @__PURE__ */ jsx32(
3883
- "li",
3890
+ /* @__PURE__ */ jsx32(
3891
+ "ul",
3884
3892
  {
3885
- role: "option",
3886
- "aria-selected": opt.value === value,
3887
- "aria-disabled": opt.disabled,
3888
- className: opt.disabled ? "disabled" : void 0,
3889
- onClick: () => !opt.disabled && pick(opt.value),
3890
- onKeyDown: (e) => {
3891
- if (e.key === "Enter" && !opt.disabled) pick(opt.value);
3892
- },
3893
- children: opt.label
3894
- },
3895
- opt.value
3896
- )) })
3893
+ className: cn("select_option", "stn-scroll", "vertical", "thin"),
3894
+ role: "listbox",
3895
+ "aria-label": ariaLabel,
3896
+ children: options.map((opt) => {
3897
+ const isSelected = opt.value === value;
3898
+ return /* @__PURE__ */ jsxs25(
3899
+ "li",
3900
+ {
3901
+ role: "option",
3902
+ "aria-selected": isSelected,
3903
+ "aria-disabled": opt.disabled,
3904
+ className: cn(
3905
+ opt.disabled && "disabled",
3906
+ isSelected && "is-selected selected"
3907
+ ),
3908
+ onClick: () => !opt.disabled && pick(opt.value),
3909
+ onKeyDown: (e) => {
3910
+ if (e.key === "Enter" && !opt.disabled) pick(opt.value);
3911
+ },
3912
+ children: [
3913
+ /* @__PURE__ */ jsx32(
3914
+ "span",
3915
+ {
3916
+ className: cn("stn-dropdown__check", isSelected && "is-checked"),
3917
+ "aria-hidden": "true",
3918
+ children: isSelected ? /* @__PURE__ */ jsx32(StnIcon, { name: "line/check", size: 14, color: "currentColor" }) : null
3919
+ }
3920
+ ),
3921
+ /* @__PURE__ */ jsx32("span", { className: "stn-dropdown__item-label", children: opt.label })
3922
+ ]
3923
+ },
3924
+ opt.value
3925
+ );
3926
+ })
3927
+ }
3928
+ )
3897
3929
  ]
3898
3930
  }
3899
3931
  );
@@ -7266,33 +7298,41 @@ function StnAlertCenterPanel({
7266
7298
  )
7267
7299
  ] })
7268
7300
  ] }),
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(
7271
- StnAlertCard,
7272
- {
7273
- item,
7274
- titleOverflow: resolvedTitleOverflow,
7275
- descOverflow: resolvedDescOverflow,
7276
- onClick: () => onItemClick?.(item)
7277
- }
7278
- ) }, item.id ?? item.title)) }),
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 }) })
7284
- ] }),
7285
- /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__time", children: row.time })
7286
- ] }) }) }, row.id ?? row.text)) }),
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 }) })
7292
- ] }),
7293
- /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__time", children: row.time })
7294
- ] }) }) }, row.id ?? row.text)) })
7295
- ] }),
7301
+ /* @__PURE__ */ jsxs44(
7302
+ StnScroll,
7303
+ {
7304
+ orientation: "vertical",
7305
+ size: "thin",
7306
+ className: "stn-alert-center__list-wrap",
7307
+ children: [
7308
+ activeTab === "error" && /* @__PURE__ */ jsx53("ul", { className: "stn-alert-center__list", children: alerts.map((item) => /* @__PURE__ */ jsx53("li", { children: /* @__PURE__ */ jsx53(
7309
+ StnAlertCard,
7310
+ {
7311
+ item,
7312
+ titleOverflow: resolvedTitleOverflow,
7313
+ descOverflow: resolvedDescOverflow,
7314
+ onClick: () => onItemClick?.(item)
7315
+ }
7316
+ ) }, item.id ?? item.title)) }),
7317
+ 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: [
7318
+ /* @__PURE__ */ jsx53(StnIcon, { name: "line/clock", size: 24, color: "var(--stn-text-secondary)", className: "stn-alert-card__icon" }),
7319
+ /* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__body", children: [
7320
+ /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__type-label work", children: row.typeLabel }),
7321
+ /* @__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 }) })
7322
+ ] }),
7323
+ /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__time", children: row.time })
7324
+ ] }) }) }, row.id ?? row.text)) }),
7325
+ 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: [
7326
+ /* @__PURE__ */ jsx53(StnIcon, { name: "line/settings", size: 24, color: "var(--stn-secondary)", className: "stn-alert-card__icon" }),
7327
+ /* @__PURE__ */ jsxs44("div", { className: "stn-alert-card__body", children: [
7328
+ /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__type-label stn-alert-card__type-label--deploy", children: row.typeLabel }),
7329
+ /* @__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 }) })
7330
+ ] }),
7331
+ /* @__PURE__ */ jsx53("span", { className: "stn-alert-card__time", children: row.time })
7332
+ ] }) }) }, row.id ?? row.text)) })
7333
+ ]
7334
+ }
7335
+ ),
7296
7336
  /* @__PURE__ */ jsx53("div", { className: "stn-alert-center__footer", children: /* @__PURE__ */ jsxs44(
7297
7337
  "button",
7298
7338
  {