sellmate-design-system-react 0.1.8 → 0.1.9

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.
Files changed (104) hide show
  1. package/dist/components/SActionModal/SActionModal.cjs +1 -1
  2. package/dist/components/SActionModal/SActionModal.cjs.map +1 -1
  3. package/dist/components/SActionModal/SActionModal.js +1 -1
  4. package/dist/components/SActionModal/SActionModal.js.map +1 -1
  5. package/dist/components/SBarcodeInput/SBarcodeInput.cjs +218 -209
  6. package/dist/components/SBarcodeInput/SBarcodeInput.cjs.map +1 -1
  7. package/dist/components/SBarcodeInput/SBarcodeInput.js +218 -209
  8. package/dist/components/SBarcodeInput/SBarcodeInput.js.map +1 -1
  9. package/dist/components/SCalendar/SCalendar.cjs +1 -1
  10. package/dist/components/SCalendar/SCalendar.cjs.map +1 -1
  11. package/dist/components/SCalendar/SCalendar.js +1 -1
  12. package/dist/components/SCalendar/SCalendar.js.map +1 -1
  13. package/dist/components/SChip/SChip.cjs +1 -1
  14. package/dist/components/SChip/SChip.cjs.map +1 -1
  15. package/dist/components/SChip/SChip.d.ts +1 -1
  16. package/dist/components/SChip/SChip.js +1 -1
  17. package/dist/components/SChip/SChip.js.map +1 -1
  18. package/dist/components/SChipInput/SChipInput.cjs +235 -221
  19. package/dist/components/SChipInput/SChipInput.cjs.map +1 -1
  20. package/dist/components/SChipInput/SChipInput.js +235 -221
  21. package/dist/components/SChipInput/SChipInput.js.map +1 -1
  22. package/dist/components/SCircleProgress/SCircleProgress.cjs +53 -55
  23. package/dist/components/SCircleProgress/SCircleProgress.cjs.map +1 -1
  24. package/dist/components/SCircleProgress/SCircleProgress.js +53 -55
  25. package/dist/components/SCircleProgress/SCircleProgress.js.map +1 -1
  26. package/dist/components/SDatePicker/SDatePicker.cjs +223 -214
  27. package/dist/components/SDatePicker/SDatePicker.cjs.map +1 -1
  28. package/dist/components/SDatePicker/SDatePicker.js +223 -214
  29. package/dist/components/SDatePicker/SDatePicker.js.map +1 -1
  30. package/dist/components/SDateRangePicker/SDateRangePicker.cjs +298 -263
  31. package/dist/components/SDateRangePicker/SDateRangePicker.cjs.map +1 -1
  32. package/dist/components/SDateRangePicker/SDateRangePicker.js +298 -263
  33. package/dist/components/SDateRangePicker/SDateRangePicker.js.map +1 -1
  34. package/dist/components/SDropdownButton/SDropdownButton.cjs +4 -4
  35. package/dist/components/SDropdownButton/SDropdownButton.cjs.map +1 -1
  36. package/dist/components/SDropdownButton/SDropdownButton.js +4 -4
  37. package/dist/components/SDropdownButton/SDropdownButton.js.map +1 -1
  38. package/dist/components/SField/SField.cjs +218 -21
  39. package/dist/components/SField/SField.cjs.map +1 -1
  40. package/dist/components/SField/SField.d.ts +11 -0
  41. package/dist/components/SField/SField.js +218 -21
  42. package/dist/components/SField/SField.js.map +1 -1
  43. package/dist/components/SFilePicker/SFilePicker.cjs +298 -278
  44. package/dist/components/SFilePicker/SFilePicker.cjs.map +1 -1
  45. package/dist/components/SFilePicker/SFilePicker.d.ts +4 -2
  46. package/dist/components/SFilePicker/SFilePicker.js +298 -278
  47. package/dist/components/SFilePicker/SFilePicker.js.map +1 -1
  48. package/dist/components/SInput/SInput.cjs +218 -209
  49. package/dist/components/SInput/SInput.cjs.map +1 -1
  50. package/dist/components/SInput/SInput.js +218 -209
  51. package/dist/components/SInput/SInput.js.map +1 -1
  52. package/dist/components/SKeyValueTable/SKeyValueTable.cjs +610 -450
  53. package/dist/components/SKeyValueTable/SKeyValueTable.cjs.map +1 -1
  54. package/dist/components/SKeyValueTable/SKeyValueTable.d.ts +3 -1
  55. package/dist/components/SKeyValueTable/SKeyValueTable.js +610 -450
  56. package/dist/components/SKeyValueTable/SKeyValueTable.js.map +1 -1
  57. package/dist/components/SLoadingContainer/SLoadingContainer.cjs +61 -55
  58. package/dist/components/SLoadingContainer/SLoadingContainer.cjs.map +1 -1
  59. package/dist/components/SLoadingContainer/SLoadingContainer.js +61 -55
  60. package/dist/components/SLoadingContainer/SLoadingContainer.js.map +1 -1
  61. package/dist/components/SLoadingContainer/loading.cjs +61 -55
  62. package/dist/components/SLoadingContainer/loading.cjs.map +1 -1
  63. package/dist/components/SLoadingContainer/loading.js +61 -55
  64. package/dist/components/SLoadingContainer/loading.js.map +1 -1
  65. package/dist/components/SLoadingModal/SLoadingModal.cjs +56 -57
  66. package/dist/components/SLoadingModal/SLoadingModal.cjs.map +1 -1
  67. package/dist/components/SLoadingModal/SLoadingModal.js +56 -57
  68. package/dist/components/SLoadingModal/SLoadingModal.js.map +1 -1
  69. package/dist/components/SNumberInput/SNumberInput.cjs +326 -50
  70. package/dist/components/SNumberInput/SNumberInput.cjs.map +1 -1
  71. package/dist/components/SNumberInput/SNumberInput.d.ts +2 -0
  72. package/dist/components/SNumberInput/SNumberInput.js +326 -50
  73. package/dist/components/SNumberInput/SNumberInput.js.map +1 -1
  74. package/dist/components/SPagination/SPagination.cjs +1 -1
  75. package/dist/components/SPagination/SPagination.cjs.map +1 -1
  76. package/dist/components/SPagination/SPagination.js +1 -1
  77. package/dist/components/SPagination/SPagination.js.map +1 -1
  78. package/dist/components/SSelect/SSelect.cjs +67 -32
  79. package/dist/components/SSelect/SSelect.cjs.map +1 -1
  80. package/dist/components/SSelect/SSelect.js +67 -32
  81. package/dist/components/SSelect/SSelect.js.map +1 -1
  82. package/dist/components/STable/STable.cjs +121 -88
  83. package/dist/components/STable/STable.cjs.map +1 -1
  84. package/dist/components/STable/STable.js +121 -88
  85. package/dist/components/STable/STable.js.map +1 -1
  86. package/dist/components/STextarea/STextarea.cjs +218 -21
  87. package/dist/components/STextarea/STextarea.cjs.map +1 -1
  88. package/dist/components/STextarea/STextarea.js +218 -21
  89. package/dist/components/STextarea/STextarea.js.map +1 -1
  90. package/dist/components/SToast/SToastContainer.cjs +3 -3
  91. package/dist/components/SToast/SToastContainer.cjs.map +1 -1
  92. package/dist/components/SToast/SToastContainer.js +3 -3
  93. package/dist/components/SToast/SToastContainer.js.map +1 -1
  94. package/dist/components/STooltip/STooltip.cjs +209 -14
  95. package/dist/components/STooltip/STooltip.cjs.map +1 -1
  96. package/dist/components/STooltip/STooltip.js +209 -14
  97. package/dist/components/STooltip/STooltip.js.map +1 -1
  98. package/dist/index.cjs +432 -260
  99. package/dist/index.cjs.map +1 -1
  100. package/dist/index.js +432 -260
  101. package/dist/index.js.map +1 -1
  102. package/dist/styles.css +51 -27
  103. package/dist/theme.css +4 -2
  104. package/package.json +1 -1
@@ -2,8 +2,8 @@
2
2
  import { forwardRef, createContext, useState, useRef, useImperativeHandle, useEffect, useId, useMemo, useContext } from 'react';
3
3
  import { clsx } from 'clsx';
4
4
  import { extendTailwindMerge } from 'tailwind-merge';
5
- import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
6
- import * as RPopover from '@radix-ui/react-popover';
5
+ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
6
+ import * as RPopover2 from '@radix-ui/react-popover';
7
7
  import * as RTooltip from '@radix-ui/react-tooltip';
8
8
 
9
9
  var twMerge = extendTailwindMerge({
@@ -2876,11 +2876,200 @@ PortalContainerContext.Provider;
2876
2876
  function usePortalContainer() {
2877
2877
  return useContext(PortalContainerContext) ?? void 0;
2878
2878
  }
2879
+
2880
+ // src/components/STag/tag.config.ts
2881
+ var TAG_SIZE_CONFIG = {
2882
+ xs: {
2883
+ height: 20,
2884
+ paddingX: 8,
2885
+ gap: 4,
2886
+ radius: 6,
2887
+ iconSize: 12,
2888
+ fontSize: 11,
2889
+ fontWeight: 500,
2890
+ lineHeight: 18
2891
+ },
2892
+ sm: {
2893
+ height: 24,
2894
+ paddingX: 8,
2895
+ gap: 4,
2896
+ radius: 6,
2897
+ iconSize: 16,
2898
+ fontSize: 12,
2899
+ fontWeight: 700,
2900
+ lineHeight: 20
2901
+ },
2902
+ md: {
2903
+ height: 28,
2904
+ paddingX: 12,
2905
+ gap: 6,
2906
+ radius: 8,
2907
+ iconSize: 16,
2908
+ fontSize: 14,
2909
+ fontWeight: 700,
2910
+ lineHeight: 24
2911
+ }
2912
+ };
2913
+ var STag = forwardRef(function STag2({
2914
+ shape = "square",
2915
+ size = "sm",
2916
+ color = "grey",
2917
+ label = "",
2918
+ icon,
2919
+ iconLeft = true,
2920
+ width,
2921
+ className,
2922
+ style,
2923
+ ...rest
2924
+ }, ref) {
2925
+ const s = TAG_SIZE_CONFIG[size];
2926
+ const contentColor = `var(--cmp-tag-${color}-content)`;
2927
+ const iconNode = icon ? /* @__PURE__ */ jsx(SIcon, { name: icon, size: s.iconSize, color: contentColor }) : null;
2928
+ const resolvedWidth = typeof width === "number" ? `${width}px` : width;
2929
+ return /* @__PURE__ */ jsxs(
2930
+ "span",
2931
+ {
2932
+ ref,
2933
+ "aria-label": label || "tag",
2934
+ className: cn(
2935
+ "box-border inline-flex w-fit select-none items-center justify-center whitespace-nowrap",
2936
+ className
2937
+ ),
2938
+ style: {
2939
+ minHeight: s.height,
2940
+ padding: `0 ${s.paddingX}px`,
2941
+ gap: s.gap,
2942
+ borderRadius: shape === "pill" ? 999 : s.radius,
2943
+ fontSize: s.fontSize,
2944
+ fontWeight: s.fontWeight,
2945
+ lineHeight: `${s.lineHeight}px`,
2946
+ background: `var(--cmp-tag-${color}-bg)`,
2947
+ color: contentColor,
2948
+ ...resolvedWidth != null ? { width: resolvedWidth } : {},
2949
+ ...style
2950
+ },
2951
+ ...rest,
2952
+ children: [
2953
+ icon && iconLeft && iconNode,
2954
+ label && /* @__PURE__ */ jsx("span", { className: "inline-flex min-w-0 items-center justify-center", children: label }),
2955
+ icon && !iconLeft && iconNode
2956
+ ]
2957
+ }
2958
+ );
2959
+ });
2960
+ var SIZE = {
2961
+ xxs: { icon: 12, radius: "sm" },
2962
+ xs: { icon: 16, radius: "sm" },
2963
+ sm: { icon: 20, radius: "sm" },
2964
+ md: { icon: 24, radius: "md" },
2965
+ lg: { icon: 32, radius: "md" }
2966
+ };
2967
+ var TOOLTIP_HIDE_DELAY_MS = 100;
2968
+ function SGhostButton({
2969
+ icon,
2970
+ size = "sm",
2971
+ intent = "default",
2972
+ ariaLabel = "",
2973
+ tooltipText,
2974
+ disabled = false,
2975
+ onClick,
2976
+ className,
2977
+ style
2978
+ }) {
2979
+ const portalContainer = usePortalContainer();
2980
+ const [open, setOpen] = useState(false);
2981
+ const hideTimer = useRef(void 0);
2982
+ const cancelHide = () => {
2983
+ if (hideTimer.current) {
2984
+ clearTimeout(hideTimer.current);
2985
+ hideTimer.current = void 0;
2986
+ }
2987
+ };
2988
+ const openNow = () => {
2989
+ cancelHide();
2990
+ setOpen(true);
2991
+ };
2992
+ const startHide = () => {
2993
+ cancelHide();
2994
+ hideTimer.current = setTimeout(() => setOpen(false), TOOLTIP_HIDE_DELAY_MS);
2995
+ };
2996
+ const s = SIZE[size];
2997
+ const contentColor = disabled ? intent === "inverse" ? "var(--cmp-ghostButton-inverse-disabled)" : "var(--cmp-ghostButton-icon-disabled)" : `var(--cmp-ghostButton-${intent}-content)`;
2998
+ const btn = /* @__PURE__ */ jsxs(
2999
+ "button",
3000
+ {
3001
+ type: "button",
3002
+ disabled,
3003
+ "aria-disabled": disabled ? "true" : void 0,
3004
+ "aria-label": ariaLabel.trim() || void 0,
3005
+ tabIndex: disabled ? -1 : void 0,
3006
+ onClick: (e) => {
3007
+ if (disabled) {
3008
+ e.preventDefault();
3009
+ return;
3010
+ }
3011
+ onClick?.(e);
3012
+ },
3013
+ className: cn(
3014
+ "group relative box-border inline-flex items-center justify-center border-none bg-transparent p-0 transition-shadow",
3015
+ disabled ? "cursor-not-allowed" : "cursor-pointer",
3016
+ "focus-visible:outline-none focus-visible:shadow-[0_0_0_2px_var(--cmp-ghostButton-action-hover-bg)]",
3017
+ className
3018
+ ),
3019
+ style: {
3020
+ width: `var(--cmp-ghostButton-${size}-size)`,
3021
+ height: `var(--cmp-ghostButton-${size}-size)`,
3022
+ borderRadius: `var(--cmp-ghostButton-radius-${s.radius})`,
3023
+ ...style
3024
+ },
3025
+ children: [
3026
+ !disabled && /* @__PURE__ */ jsx(
3027
+ "span",
3028
+ {
3029
+ "aria-hidden": true,
3030
+ className: "pointer-events-none absolute inset-0 rounded-[inherit] opacity-0 transition-opacity duration-200 group-hover:opacity-5",
3031
+ style: { background: `var(--cmp-ghostButton-${intent}-hover-bg)` }
3032
+ }
3033
+ ),
3034
+ /* @__PURE__ */ jsx(SIcon, { name: icon, size: s.icon, color: contentColor })
3035
+ ]
3036
+ }
3037
+ );
3038
+ const text = (tooltipText ?? "").trim();
3039
+ if (text === "") return btn;
3040
+ return /* @__PURE__ */ jsxs(RPopover2.Root, { open, onOpenChange: setOpen, children: [
3041
+ /* @__PURE__ */ jsx(RPopover2.Anchor, { asChild: true, children: /* @__PURE__ */ jsx(
3042
+ "span",
3043
+ {
3044
+ className: "inline-flex",
3045
+ onMouseEnter: openNow,
3046
+ onMouseLeave: startHide,
3047
+ onFocus: openNow,
3048
+ onBlur: startHide,
3049
+ children: btn
3050
+ }
3051
+ ) }),
3052
+ /* @__PURE__ */ jsx(RPopover2.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(
3053
+ RPopover2.Content,
3054
+ {
3055
+ side: "top",
3056
+ sideOffset: 4,
3057
+ className: cn("z-50", FLOATING_SLIDE_ANIM),
3058
+ "aria-hidden": true,
3059
+ onOpenAutoFocus: (e) => e.preventDefault(),
3060
+ onMouseEnter: cancelHide,
3061
+ onMouseLeave: startHide,
3062
+ children: /* @__PURE__ */ jsx(STag, { shape: "square", size: "xs", color: "grey", label: text })
3063
+ }
3064
+ ) })
3065
+ ] });
3066
+ }
2879
3067
  var HIDE_DELAY_MS = 100;
2880
3068
  function useBody(content, message = []) {
2881
3069
  if (content != null) return content;
2882
3070
  if (message.length === 0) return null;
2883
- return /* @__PURE__ */ jsx(Fragment, { children: message.map((line, i) => /* @__PURE__ */ jsx("div", { children: line }, i)) });
3071
+ const singleLine = message.length === 1;
3072
+ return /* @__PURE__ */ jsx(Fragment, { children: message.map((line, i) => /* @__PURE__ */ jsx("div", { className: singleLine ? "leading-[24px]" : void 0, children: line }, i)) });
2884
3073
  }
2885
3074
  var STooltip = forwardRef(function STooltip2({
2886
3075
  content,
@@ -2938,7 +3127,7 @@ var STooltip = forwardRef(function STooltip2({
2938
3127
  if (disabled || body == null) return /* @__PURE__ */ jsx(Fragment, { children: triggerNode });
2939
3128
  const isHover = trigger === "hover";
2940
3129
  const contentClass = cn(
2941
- "z-50 max-w-xs rounded-[6px] px-[16px] py-[12px] text-[12px] leading-[20px]",
3130
+ "z-50 max-w-xs rounded-[6px] px-[16px] py-[12px] text-[12px] leading-[20px] shadow-[2px_2px_12px_2px_rgba(0,0,0,0.1)]",
2942
3131
  FLOATING_SLIDE_ANIM,
2943
3132
  className
2944
3133
  );
@@ -2948,10 +3137,10 @@ var STooltip = forwardRef(function STooltip2({
2948
3137
  fontWeight: tooltipType === "default" ? 500 : 700,
2949
3138
  ...style
2950
3139
  };
2951
- return /* @__PURE__ */ jsxs(RPopover.Root, { open, onOpenChange: setOpen, children: [
3140
+ return /* @__PURE__ */ jsxs(RPopover2.Root, { open, onOpenChange: setOpen, children: [
2952
3141
  isHover ? (
2953
3142
  // hover: Anchor(위치 기준) + 직접 mouse 핸들러 — 클릭으로 토글되지 않도록 Trigger 미사용
2954
- /* @__PURE__ */ jsx(RPopover.Anchor, { asChild: true, children: /* @__PURE__ */ jsx(
3143
+ /* @__PURE__ */ jsx(RPopover2.Anchor, { asChild: true, children: /* @__PURE__ */ jsx(
2955
3144
  "span",
2956
3145
  {
2957
3146
  className: "inline-flex",
@@ -2962,9 +3151,9 @@ var STooltip = forwardRef(function STooltip2({
2962
3151
  children: triggerNode
2963
3152
  }
2964
3153
  ) })
2965
- ) : /* @__PURE__ */ jsx(RPopover.Trigger, { asChild: true, children: triggerNode }),
2966
- /* @__PURE__ */ jsx(RPopover.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(
2967
- RPopover.Content,
3154
+ ) : /* @__PURE__ */ jsx(RPopover2.Trigger, { asChild: true, children: triggerNode }),
3155
+ /* @__PURE__ */ jsx(RPopover2.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxs(
3156
+ RPopover2.Content,
2968
3157
  {
2969
3158
  side: placement,
2970
3159
  sideOffset: 8,
@@ -2983,15 +3172,21 @@ var STooltip = forwardRef(function STooltip2({
2983
3172
  /* @__PURE__ */ jsxs("div", { className: "flex items-start gap-[12px]", children: [
2984
3173
  /* @__PURE__ */ jsx("div", { className: "min-w-0 flex-1", children: body }),
2985
3174
  useClose && /* @__PURE__ */ jsx(
2986
- RPopover.Close,
3175
+ SGhostButton,
2987
3176
  {
2988
- "aria-label": "\uB2EB\uAE30",
2989
- className: "shrink-0 cursor-pointer opacity-70 hover:opacity-100",
2990
- children: /* @__PURE__ */ jsx(SIcon, { name: "close", size: 16, color: fg })
3177
+ icon: "close",
3178
+ size: "xs",
3179
+ intent: tooltipType === "default" ? "inverse" : "default",
3180
+ ariaLabel: "\uB2EB\uAE30",
3181
+ className: "shrink-0",
3182
+ onClick: () => {
3183
+ cancelHide();
3184
+ setOpen(false);
3185
+ }
2991
3186
  }
2992
3187
  )
2993
3188
  ] }),
2994
- /* @__PURE__ */ jsx(RPopover.Arrow, { width: 16, height: 12, style: { fill: bg } })
3189
+ /* @__PURE__ */ jsx(RPopover2.Arrow, { width: 16, height: 12, style: { fill: bg } })
2995
3190
  ]
2996
3191
  }
2997
3192
  ) })
@@ -3025,8 +3220,8 @@ function useFormField(field) {
3025
3220
  }, [ctx, name]);
3026
3221
  }
3027
3222
  var FIELD_SIZE = {
3028
- sm: { height: 28, radius: 4, fieldGap: 12, labelGap: 6, fontSize: 12, lineHeight: 20, icon: 12 },
3029
- md: { height: 36, radius: 6, fieldGap: 16, labelGap: 8, fontSize: 14, lineHeight: 24, icon: 12 }
3223
+ sm: { height: 28, radius: 4, fieldGap: 12, labelGap: 6, fontSize: 12, lineHeight: 20, icon: 16 },
3224
+ md: { height: 36, radius: 6, fieldGap: 16, labelGap: 8, fontSize: 14, lineHeight: 24, icon: 16 }
3030
3225
  };
3031
3226
  var ALIGN = {
3032
3227
  start: "flex-start",
@@ -3041,6 +3236,7 @@ var SField = forwardRef(function SField2({
3041
3236
  labelTooltip = "",
3042
3237
  labelTooltipProps,
3043
3238
  labelWidth,
3239
+ labelHeight,
3044
3240
  size = "sm",
3045
3241
  addonLabel = "",
3046
3242
  addonAlign = "start",
@@ -3055,6 +3251,7 @@ var SField = forwardRef(function SField2({
3055
3251
  readOnly = false,
3056
3252
  width,
3057
3253
  multiline = false,
3254
+ borderless = false,
3058
3255
  children,
3059
3256
  className,
3060
3257
  style,
@@ -3088,8 +3285,8 @@ var SField = forwardRef(function SField2({
3088
3285
  const resolvedSuccess = status === "pass";
3089
3286
  const showError = resolvedError && errorMessage !== "";
3090
3287
  const interactive = !disabled && !readOnly;
3091
- const borderColor = disabled ? "var(--color-grey-45)" : interactive && focused ? "var(--sys-color-field-border-focus)" : resolvedSuccess ? "var(--sys-color-field-border-success)" : resolvedError ? "var(--sys-color-field-border-danger)" : "var(--sys-color-field-border-default)";
3092
- const bgColor = disabled ? "var(--color-grey-30)" : readOnly ? "var(--sys-color-field-bg-readOnly)" : "var(--sys-color-field-bg-default)";
3288
+ const borderColor = borderless ? "transparent" : disabled ? "var(--color-grey-45)" : interactive && focused ? "var(--sys-color-field-border-focus)" : resolvedSuccess ? "var(--sys-color-field-border-success)" : resolvedError ? "var(--sys-color-field-border-danger)" : "var(--sys-color-field-border-default)";
3289
+ const bgColor = borderless ? "transparent" : disabled ? "var(--color-grey-30)" : readOnly ? "var(--sys-color-field-bg-readOnly)" : "var(--sys-color-field-bg-default)";
3093
3290
  const textColor = disabled ? "var(--color-grey-65)" : readOnly ? "var(--sys-color-field-text-readOnly)" : "var(--sys-color-field-text-default)";
3094
3291
  return /* @__PURE__ */ jsx(
3095
3292
  "div",
@@ -3106,7 +3303,7 @@ var SField = forwardRef(function SField2({
3106
3303
  {
3107
3304
  className: "flex shrink-0 items-center font-bold text-(--sys-color-field-text-default)",
3108
3305
  style: {
3109
- height: s.height,
3306
+ height: cssLen(labelHeight) ?? s.height,
3110
3307
  marginRight: s.fieldGap,
3111
3308
  width: cssLen(labelWidth),
3112
3309
  fontSize: s.fontSize,
@@ -3132,14 +3329,14 @@ var SField = forwardRef(function SField2({
3132
3329
  {
3133
3330
  className: cn(
3134
3331
  "relative box-border flex min-w-0 items-stretch overflow-hidden border border-solid border-(--field-bc)",
3135
- interactive && "hover:border-(--sys-color-field-border-focus) hover:shadow-[0px_0px_4px_0px_#0071ff66] focus-within:border-(--sys-color-field-border-focus) focus-within:shadow-[0px_0px_4px_0px_#0071ff66]",
3332
+ interactive && !borderless && "hover:border-(--sys-color-field-border-focus) hover:shadow-[0px_0px_4px_0px_#0071ff66] focus-within:border-(--sys-color-field-border-focus) focus-within:shadow-[0px_0px_4px_0px_#0071ff66]",
3136
3333
  disabled && "cursor-not-allowed"
3137
3334
  ),
3138
3335
  style: {
3139
3336
  // @ts-expect-error CSS 변수
3140
3337
  "--field-bc": borderColor,
3141
3338
  // focused/hovered prop이 명시된 경우 강조를 즉시 반영
3142
- ...interactive && focused ? { boxShadow: "0px 0px 4px 0px #0071ff66" } : {},
3339
+ ...interactive && !borderless && focused ? { boxShadow: "0px 0px 4px 0px #0071ff66" } : {},
3143
3340
  ...multiline ? { minHeight: s.height } : { height: s.height },
3144
3341
  "width": cssLen(width),
3145
3342
  "borderRadius": s.radius,
@@ -3178,200 +3375,12 @@ var SField = forwardRef(function SField2({
3178
3375
  }
3179
3376
  );
3180
3377
  });
3181
-
3182
- // src/components/STag/tag.config.ts
3183
- var TAG_SIZE_CONFIG = {
3184
- xs: {
3185
- height: 20,
3186
- paddingX: 8,
3187
- gap: 4,
3188
- radius: 6,
3189
- iconSize: 12,
3190
- fontSize: 11,
3191
- fontWeight: 500,
3192
- lineHeight: 18
3193
- },
3194
- sm: {
3195
- height: 24,
3196
- paddingX: 8,
3197
- gap: 4,
3198
- radius: 6,
3199
- iconSize: 16,
3200
- fontSize: 12,
3201
- fontWeight: 700,
3202
- lineHeight: 20
3203
- },
3204
- md: {
3205
- height: 28,
3206
- paddingX: 12,
3207
- gap: 6,
3208
- radius: 8,
3209
- iconSize: 16,
3210
- fontSize: 14,
3211
- fontWeight: 700,
3212
- lineHeight: 24
3213
- }
3214
- };
3215
- var STag = forwardRef(function STag2({
3216
- shape = "square",
3217
- size = "sm",
3218
- color = "grey",
3219
- label = "",
3220
- icon,
3221
- iconLeft = true,
3222
- width,
3223
- className,
3224
- style,
3225
- ...rest
3226
- }, ref) {
3227
- const s = TAG_SIZE_CONFIG[size];
3228
- const contentColor = `var(--cmp-tag-${color}-content)`;
3229
- const iconNode = icon ? /* @__PURE__ */ jsx(SIcon, { name: icon, size: s.iconSize, color: contentColor }) : null;
3230
- const resolvedWidth = typeof width === "number" ? `${width}px` : width;
3231
- return /* @__PURE__ */ jsxs(
3232
- "span",
3233
- {
3234
- ref,
3235
- "aria-label": label || "tag",
3236
- className: cn(
3237
- "box-border inline-flex w-fit select-none items-center justify-center whitespace-nowrap",
3238
- className
3239
- ),
3240
- style: {
3241
- minHeight: s.height,
3242
- padding: `0 ${s.paddingX}px`,
3243
- gap: s.gap,
3244
- borderRadius: shape === "pill" ? 999 : s.radius,
3245
- fontSize: s.fontSize,
3246
- fontWeight: s.fontWeight,
3247
- lineHeight: `${s.lineHeight}px`,
3248
- background: `var(--cmp-tag-${color}-bg)`,
3249
- color: contentColor,
3250
- ...resolvedWidth != null ? { width: resolvedWidth } : {},
3251
- ...style
3252
- },
3253
- ...rest,
3254
- children: [
3255
- icon && iconLeft && iconNode,
3256
- label && /* @__PURE__ */ jsx("span", { className: "inline-flex min-w-0 items-center justify-center", children: label }),
3257
- icon && !iconLeft && iconNode
3258
- ]
3259
- }
3260
- );
3261
- });
3262
- var SIZE = {
3263
- xxs: { icon: 12, radius: "sm" },
3264
- xs: { icon: 16, radius: "sm" },
3265
- sm: { icon: 20, radius: "sm" },
3266
- md: { icon: 24, radius: "md" },
3267
- lg: { icon: 32, radius: "md" }
3268
- };
3269
- var TOOLTIP_HIDE_DELAY_MS = 100;
3270
- function SGhostButton({
3271
- icon,
3272
- size = "sm",
3273
- intent = "default",
3274
- ariaLabel = "",
3275
- tooltipText,
3276
- disabled = false,
3277
- onClick,
3278
- className,
3279
- style
3280
- }) {
3281
- const portalContainer = usePortalContainer();
3282
- const [open, setOpen] = useState(false);
3283
- const hideTimer = useRef(void 0);
3284
- const cancelHide = () => {
3285
- if (hideTimer.current) {
3286
- clearTimeout(hideTimer.current);
3287
- hideTimer.current = void 0;
3288
- }
3289
- };
3290
- const openNow = () => {
3291
- cancelHide();
3292
- setOpen(true);
3293
- };
3294
- const startHide = () => {
3295
- cancelHide();
3296
- hideTimer.current = setTimeout(() => setOpen(false), TOOLTIP_HIDE_DELAY_MS);
3297
- };
3298
- const s = SIZE[size];
3299
- const contentColor = disabled ? intent === "inverse" ? "var(--cmp-ghostButton-inverse-disabled)" : "var(--cmp-ghostButton-icon-disabled)" : `var(--cmp-ghostButton-${intent}-content)`;
3300
- const btn = /* @__PURE__ */ jsxs(
3301
- "button",
3302
- {
3303
- type: "button",
3304
- disabled,
3305
- "aria-disabled": disabled ? "true" : void 0,
3306
- "aria-label": ariaLabel.trim() || void 0,
3307
- tabIndex: disabled ? -1 : void 0,
3308
- onClick: (e) => {
3309
- if (disabled) {
3310
- e.preventDefault();
3311
- return;
3312
- }
3313
- onClick?.(e);
3314
- },
3315
- className: cn(
3316
- "group relative box-border inline-flex items-center justify-center border-none bg-transparent p-0 transition-shadow",
3317
- disabled ? "cursor-not-allowed" : "cursor-pointer",
3318
- "focus-visible:outline-none focus-visible:shadow-[0_0_0_2px_var(--cmp-ghostButton-action-hover-bg)]",
3319
- className
3320
- ),
3321
- style: {
3322
- width: `var(--cmp-ghostButton-${size}-size)`,
3323
- height: `var(--cmp-ghostButton-${size}-size)`,
3324
- borderRadius: `var(--cmp-ghostButton-radius-${s.radius})`,
3325
- ...style
3326
- },
3327
- children: [
3328
- !disabled && /* @__PURE__ */ jsx(
3329
- "span",
3330
- {
3331
- "aria-hidden": true,
3332
- className: "pointer-events-none absolute inset-0 rounded-[inherit] opacity-0 transition-opacity duration-200 group-hover:opacity-5",
3333
- style: { background: `var(--cmp-ghostButton-${intent}-hover-bg)` }
3334
- }
3335
- ),
3336
- /* @__PURE__ */ jsx(SIcon, { name: icon, size: s.icon, color: contentColor })
3337
- ]
3338
- }
3339
- );
3340
- const text = (tooltipText ?? "").trim();
3341
- if (text === "") return btn;
3342
- return /* @__PURE__ */ jsxs(RPopover.Root, { open, onOpenChange: setOpen, children: [
3343
- /* @__PURE__ */ jsx(RPopover.Anchor, { asChild: true, children: /* @__PURE__ */ jsx(
3344
- "span",
3345
- {
3346
- className: "inline-flex",
3347
- onMouseEnter: openNow,
3348
- onMouseLeave: startHide,
3349
- onFocus: openNow,
3350
- onBlur: startHide,
3351
- children: btn
3352
- }
3353
- ) }),
3354
- /* @__PURE__ */ jsx(RPopover.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(
3355
- RPopover.Content,
3356
- {
3357
- side: "top",
3358
- sideOffset: 4,
3359
- className: cn("z-50", FLOATING_SLIDE_ANIM),
3360
- "aria-hidden": true,
3361
- onOpenAutoFocus: (e) => e.preventDefault(),
3362
- onMouseEnter: cancelHide,
3363
- onMouseLeave: startHide,
3364
- children: /* @__PURE__ */ jsx(STag, { shape: "square", size: "xs", color: "grey", label: text })
3365
- }
3366
- ) })
3367
- ] });
3368
- }
3369
3378
  var SChip = forwardRef(function SChip2({
3370
3379
  name,
3371
3380
  value = "",
3372
3381
  error: errorProp = false,
3373
3382
  disabled = false,
3374
- editable = true,
3383
+ editable = false,
3375
3384
  showRemove = true,
3376
3385
  placeholder = "",
3377
3386
  rules,
@@ -3629,7 +3638,7 @@ function SPortal({
3629
3638
  }) {
3630
3639
  const portalContainer = usePortalContainer();
3631
3640
  return /* @__PURE__ */ jsxs(
3632
- RPopover.Root,
3641
+ RPopover2.Root,
3633
3642
  {
3634
3643
  open,
3635
3644
  onOpenChange: (next) => {
@@ -3637,9 +3646,9 @@ function SPortal({
3637
3646
  if (!next) onClose?.();
3638
3647
  },
3639
3648
  children: [
3640
- /* @__PURE__ */ jsx(RPopover.Anchor, { virtualRef: anchorRef }),
3641
- /* @__PURE__ */ jsx(RPopover.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(
3642
- RPopover.Content,
3649
+ /* @__PURE__ */ jsx(RPopover2.Anchor, { virtualRef: anchorRef }),
3650
+ /* @__PURE__ */ jsx(RPopover2.Portal, { container: portalContainer, children: /* @__PURE__ */ jsx(
3651
+ RPopover2.Content,
3643
3652
  {
3644
3653
  side: placement,
3645
3654
  align,
@@ -3687,7 +3696,7 @@ var SChipInput = forwardRef(function SChipInput2({
3687
3696
  disabledChips = [],
3688
3697
  size = "sm",
3689
3698
  disabled = false,
3690
- placeholder = "\uC785\uB825\uD574 \uC8FC\uC138\uC694.",
3699
+ placeholder = "\uD0DC\uADF8 \uC785\uB825 (Enter\uB85C \uB4F1\uB85D / \uCF64\uB9C8\uB85C \uAD6C\uBD84 / \uB744\uC5B4\uC4F0\uAE30 \uBD88\uAC00)",
3691
3700
  name,
3692
3701
  rules,
3693
3702
  error,
@@ -3838,6 +3847,7 @@ var SChipInput = forwardRef(function SChipInput2({
3838
3847
  {
3839
3848
  label,
3840
3849
  labelWidth,
3850
+ labelHeight: `calc(var(--cmp-chipInput-${size}-minHeight) + 2px)`,
3841
3851
  icon,
3842
3852
  labelTooltip,
3843
3853
  labelTooltipProps,
@@ -3908,9 +3918,11 @@ var SChipInput = forwardRef(function SChipInput2({
3908
3918
  paddingInline: isFieldFilled ? "var(--cmp-chip-paddingX)" : void 0,
3909
3919
  borderWidth: isFieldFilled ? "var(--cmp-chip-border-width)" : void 0,
3910
3920
  borderStyle: isFieldFilled ? "solid" : void 0,
3911
- borderColor: isFieldFilled ? "transparent" : void 0,
3921
+ // 작성중 필드는 SChip의 editable 수정중(editing) 스타일과 동일하게 —
3922
+ // bg/보더/글자색 모두 focus 토큰을 사용한다.
3923
+ borderColor: isFieldFilled ? "var(--cmp-chip-border-focus)" : void 0,
3912
3924
  borderRadius: isFieldFilled ? "var(--cmp-chip-radius)" : 0,
3913
- background: isFieldFilled ? "var(--cmp-chip-bg-default)" : "transparent",
3925
+ background: isFieldFilled ? "var(--cmp-chip-bg-focus)" : "transparent",
3914
3926
  overflow: "hidden"
3915
3927
  },
3916
3928
  children: [
@@ -3919,7 +3931,7 @@ var SChipInput = forwardRef(function SChipInput2({
3919
3931
  {
3920
3932
  "aria-hidden": true,
3921
3933
  className: cn(
3922
- "invisible col-start-1 row-start-1 whitespace-pre font-medium",
3934
+ "invisible col-start-1 row-start-1 whitespace-pre font-normal",
3923
3935
  size === "md" ? "text-14 leading-24" : "text-12 leading-20"
3924
3936
  ),
3925
3937
  children: inputValue !== "" ? inputValue : values.length === 0 ? placeholder : ""
@@ -3932,12 +3944,14 @@ var SChipInput = forwardRef(function SChipInput2({
3932
3944
  name: resolvedName,
3933
3945
  size: 1,
3934
3946
  className: cn(
3935
- "s-chip-input__input col-start-1 row-start-1 w-full border-0 bg-transparent p-0 font-medium text-(--cmp-chip-content-focus) outline-none placeholder:text-(--cmp-chipInput-text-placeholder) disabled:cursor-not-allowed",
3947
+ "s-chip-input__input col-start-1 row-start-1 w-full border-0 bg-transparent p-0 font-normal text-(--cmp-chip-content-focus) outline-none placeholder:text-(--cmp-chipInput-text-placeholder) disabled:cursor-not-allowed",
3936
3948
  size === "md" ? "text-14 leading-24" : "text-12 leading-20"
3937
3949
  ),
3938
3950
  style: {
3939
3951
  minWidth: "1ch",
3940
- height: "var(--cmp-chip-height)",
3952
+ // height 지정하지 않고 line-height(20/24px)에 맞춰 자동 크기로 둔다.
3953
+ // var(--cmp-chip-height)(24px)로 고정하면 네이티브 <input>이 남는 세로 여백에
3954
+ // 텍스트를 아래로 밀어 넣어, 확정된 chip 텍스트보다 2px 낮게 보인다.
3941
3955
  margin: 0,
3942
3956
  overflow: "hidden",
3943
3957
  textOverflow: "ellipsis"
@@ -3982,7 +3996,7 @@ var SChipInput = forwardRef(function SChipInput2({
3982
3996
  showMetaInfo && /* @__PURE__ */ jsxs(
3983
3997
  "div",
3984
3998
  {
3985
- className: "s-chip-input__meta flex items-center gap-8",
3999
+ className: "s-chip-input__meta ml-auto flex items-center gap-8",
3986
4000
  onMouseDown: (e) => e.preventDefault(),
3987
4001
  children: [
3988
4002
  /* @__PURE__ */ jsx(