@dotss/ui 0.0.10 → 0.0.12

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 (159) hide show
  1. package/Accordion/Accordion.cjs +13 -7
  2. package/Accordion/Accordion.d.ts +2 -0
  3. package/Accordion/Accordion.es.js +86 -65
  4. package/Autocomplete/Autocomplete.cjs +1 -1
  5. package/Autocomplete/Autocomplete.d.ts +1 -1
  6. package/Autocomplete/Autocomplete.es.js +235 -80
  7. package/BottomSheet/BottomSheet.cjs +5 -5
  8. package/BottomSheet/BottomSheet.d.ts +3 -0
  9. package/BottomSheet/BottomSheet.es.js +88 -70
  10. package/BottomSheet/BottomSheetText/BottomSheetText.cjs +2 -2
  11. package/BottomSheet/BottomSheetText/BottomSheetText.es.js +18 -6
  12. package/BottomSheet/BottomSheetTitle/BottomSheetTitle.cjs +6 -6
  13. package/BottomSheet/BottomSheetTitle/BottomSheetTitle.d.ts +2 -1
  14. package/BottomSheet/BottomSheetTitle/BottomSheetTitle.es.js +26 -15
  15. package/Button/Button.cjs +6 -6
  16. package/Button/Button.es.js +35 -29
  17. package/ChainPicker/ChainPicker.cjs +16 -6
  18. package/ChainPicker/ChainPicker.d.ts +4 -2
  19. package/ChainPicker/ChainPicker.es.js +155 -110
  20. package/ChainPicker/ChainPicker.stories.d.ts +1 -1
  21. package/Checkbox/Checkbox.cjs +3 -3
  22. package/Checkbox/Checkbox.es.js +12 -10
  23. package/CircularProgressIndicator/CircularProgressIndicator.cjs +5 -5
  24. package/CircularProgressIndicator/CircularProgressIndicator.es.js +25 -22
  25. package/DatePicker/DatePicker.cjs +37 -20
  26. package/DatePicker/DatePicker.d.ts +2 -1
  27. package/DatePicker/DatePicker.es.js +345 -320
  28. package/DatePicker/DatePicker.stories.d.ts +1 -0
  29. package/DatePicker/EventDot/EventDot.cjs +8 -0
  30. package/DatePicker/EventDot/EventDot.d.ts +8 -0
  31. package/DatePicker/EventDot/EventDot.es.js +19 -0
  32. package/DatePicker/EventDot/index.cjs +1 -0
  33. package/DatePicker/EventDot/index.d.ts +3 -0
  34. package/DatePicker/EventDot/index.es.js +4 -0
  35. package/DatePicker/EventDotGroup/EventDotGroup.cjs +8 -0
  36. package/DatePicker/EventDotGroup/EventDotGroup.d.ts +8 -0
  37. package/DatePicker/EventDotGroup/EventDotGroup.es.js +39 -0
  38. package/DatePicker/EventDotGroup/index.cjs +1 -0
  39. package/DatePicker/EventDotGroup/index.d.ts +3 -0
  40. package/DatePicker/EventDotGroup/index.es.js +4 -0
  41. package/DatePicker/index.cjs +1 -1
  42. package/DatePicker/index.d.ts +2 -0
  43. package/DatePicker/index.es.js +6 -2
  44. package/Dialog/Dialog.cjs +2 -2
  45. package/Dialog/Dialog.d.ts +2 -0
  46. package/Dialog/Dialog.es.js +45 -40
  47. package/Dialog/Dialog.stories.d.ts +10 -0
  48. package/Dialog/DialogText/DialogText.cjs +1 -1
  49. package/Dialog/DialogText/DialogText.es.js +1 -1
  50. package/Dialog/DialogTitle/DialogTitle.cjs +4 -4
  51. package/Dialog/DialogTitle/DialogTitle.d.ts +2 -1
  52. package/Dialog/DialogTitle/DialogTitle.es.js +17 -17
  53. package/FocusBoundary/FocusBoundary.cjs +1 -1
  54. package/FocusBoundary/FocusBoundary.d.ts +3 -1
  55. package/FocusBoundary/FocusBoundary.es.js +49 -42
  56. package/FormControlText/FormControlText.cjs +7 -5
  57. package/FormControlText/FormControlText.d.ts +2 -0
  58. package/FormControlText/FormControlText.es.js +50 -40
  59. package/Icon/Icon.cjs +1 -1
  60. package/Icon/Icon.es.js +1 -1
  61. package/IconButton/IconButton.cjs +8 -8
  62. package/IconButton/IconButton.es.js +32 -25
  63. package/LineProgressIndicator/LineProgressIndicator.cjs +6 -6
  64. package/LineProgressIndicator/LineProgressIndicator.es.js +34 -22
  65. package/Menu/Menu.cjs +16 -16
  66. package/Menu/Menu.d.ts +3 -2
  67. package/Menu/Menu.es.js +115 -81
  68. package/Menu/Menu.stories.d.ts +1 -0
  69. package/Menu/MenuBlock/MenuBlock.cjs +14 -7
  70. package/Menu/MenuBlock/MenuBlock.d.ts +1 -0
  71. package/Menu/MenuBlock/MenuBlock.es.js +47 -35
  72. package/Menu/MenuButton/MenuButton.cjs +1 -0
  73. package/Menu/MenuButton/MenuButton.d.ts +10 -0
  74. package/Menu/MenuButton/MenuButton.es.js +44 -0
  75. package/Menu/MenuButton/index.cjs +1 -0
  76. package/Menu/MenuButton/index.d.ts +3 -0
  77. package/Menu/MenuButton/index.es.js +4 -0
  78. package/Menu/index.cjs +1 -1
  79. package/Menu/index.d.ts +1 -0
  80. package/Menu/index.es.js +4 -2
  81. package/NumberKeypad/NumberKeypad.cjs +2 -2
  82. package/NumberKeypad/NumberKeypad.es.js +18 -16
  83. package/NumberKeypad/NumberKeypadBlock/NumberKeypadBlock.cjs +1 -1
  84. package/NumberKeypad/NumberKeypadBlock/NumberKeypadBlock.es.js +10 -1
  85. package/PageControl/PageControl.cjs +16 -5
  86. package/PageControl/PageControl.d.ts +3 -0
  87. package/PageControl/PageControl.es.js +77 -24
  88. package/PageControl/PageControl.stories.d.ts +1 -0
  89. package/Radio/Radio.cjs +3 -3
  90. package/Radio/Radio.es.js +22 -20
  91. package/RadioGroup/RadioGroup.cjs +1 -0
  92. package/RadioGroup/RadioGroup.d.ts +8 -0
  93. package/RadioGroup/RadioGroup.es.js +28 -0
  94. package/RadioGroup/RadioGroup.stories.d.ts +14 -0
  95. package/RadioGroup/index.cjs +1 -0
  96. package/RadioGroup/index.d.ts +3 -0
  97. package/RadioGroup/index.es.js +4 -0
  98. package/SegmentedButton/SegmentedButton.cjs +14 -3
  99. package/SegmentedButton/SegmentedButton.es.js +108 -34
  100. package/Select/Select.cjs +4 -4
  101. package/Select/Select.es.js +95 -86
  102. package/Slider/Slider.cjs +27 -12
  103. package/Slider/Slider.d.ts +1 -0
  104. package/Slider/Slider.es.js +177 -90
  105. package/Switch/Switch.cjs +28 -11
  106. package/Switch/Switch.d.ts +2 -0
  107. package/Switch/Switch.es.js +185 -65
  108. package/Switch/Switch.stories.d.ts +1 -0
  109. package/Tab/Tab.es.js +2 -4
  110. package/TextArea/TextArea.cjs +42 -34
  111. package/TextArea/TextArea.es.js +116 -82
  112. package/TextArea/TextArea.stories.d.ts +1 -1
  113. package/TextField/TextField.cjs +29 -13
  114. package/TextField/TextField.d.ts +2 -1
  115. package/TextField/TextField.es.js +122 -79
  116. package/TextField/TextField.stories.d.ts +1 -0
  117. package/Tooltip/Tooltip.cjs +7 -6
  118. package/Tooltip/Tooltip.d.ts +8 -3
  119. package/Tooltip/Tooltip.es.js +248 -146
  120. package/Tooltip/Tooltip.stories.d.ts +1 -0
  121. package/hooks/index.cjs +1 -1
  122. package/hooks/index.d.ts +3 -0
  123. package/hooks/index.es.js +7 -1
  124. package/hooks/useCheckHasFocus/useCheckHasFocus.cjs +1 -0
  125. package/hooks/useCheckHasFocus/useCheckHasFocus.d.ts +9 -0
  126. package/hooks/useCheckHasFocus/useCheckHasFocus.es.js +21 -0
  127. package/hooks/useCheckKeyboardMode/useCheckKeyboardMode.cjs +1 -0
  128. package/hooks/useCheckKeyboardMode/useCheckKeyboardMode.d.ts +4 -0
  129. package/hooks/useCheckKeyboardMode/useCheckKeyboardMode.es.js +30 -0
  130. package/hooks/useFocusBoundary/useFocusBoundary.cjs +1 -0
  131. package/hooks/useFocusBoundary/useFocusBoundary.d.ts +12 -0
  132. package/hooks/useFocusBoundary/useFocusBoundary.es.js +63 -0
  133. package/index.cjs +1 -1
  134. package/index.d.ts +2 -1
  135. package/index.es.js +97 -90
  136. package/package.json +3 -3
  137. package/resources/tictoccroc/icons/fill/certified-fill.svg-B_RVx6K_.cjs +1 -0
  138. package/resources/tictoccroc/icons/fill/certified-fill.svg-CK7UqYft.js +5 -0
  139. package/resources/tictoccroc/icons/fill/index.d.ts +3 -0
  140. package/resources/tictoccroc/icons/fill/location-fill.svg-DfSHAnsd.js +5 -0
  141. package/resources/tictoccroc/icons/fill/location-fill.svg-Die9mxQH.cjs +1 -0
  142. package/resources/tictoccroc/icons/fill/send-fill.svg-CItD_2L1.js +5 -0
  143. package/resources/tictoccroc/icons/fill/send-fill.svg-D197Lwl0.cjs +1 -0
  144. package/resources/tictoccroc/icons/index.ts-BmqvB_n6.cjs +1 -0
  145. package/resources/tictoccroc/icons/index.ts-CzTh-XsD.js +228 -0
  146. package/resources/tictoccroc/icons/line/index.d.ts +4 -0
  147. package/resources/tictoccroc/icons/line/list-line.svg-r5d5htjN.cjs +1 -0
  148. package/resources/tictoccroc/icons/line/list-line.svg-yFfhZxUp.js +5 -0
  149. package/resources/tictoccroc/icons/line/monthly-line.svg-BdyaJ1t_.cjs +1 -0
  150. package/resources/tictoccroc/icons/line/monthly-line.svg-DY5-Xv34.js +5 -0
  151. package/resources/tictoccroc/icons/line/review-line.svg-B4rfJrsO.js +5 -0
  152. package/resources/tictoccroc/icons/line/review-line.svg-DYUuUybx.cjs +1 -0
  153. package/resources/tictoccroc/icons/line/weekly-line.svg-BCO-LS_a.cjs +1 -0
  154. package/resources/tictoccroc/icons/line/weekly-line.svg-BUPmmgeE.js +5 -0
  155. package/utils/getIconLabel/getIconLabel.cjs +1 -1
  156. package/utils/getIconLabel/getIconLabel.es.js +8 -1
  157. package/utils/getSibling/getSibling.es.js +1 -2
  158. package/resources/tictoccroc/icons/index.ts-CarI_z7q.js +0 -214
  159. package/resources/tictoccroc/icons/index.ts-IVJAK4qr.cjs +0 -1
@@ -1,7 +1,13 @@
1
- import { jsxs as g, jsx as p } from "@emotion/react/jsx-runtime";
2
- import { forwardRef as A, useRef as m, useState as j, useId as F, useEffect as M } from "react";
3
- import l from "@emotion/styled";
4
- const T = l.div`
1
+ import { jsxs as u, jsx as a } from "@emotion/react/jsx-runtime";
2
+ import { forwardRef as F, useRef as v, useState as q, useId as h, useEffect as B } from "react";
3
+ import s from "@emotion/styled";
4
+ import y from "../Typography/Typography.es.js";
5
+ const E = s.div`
6
+ position: relative;
7
+ display: flex;
8
+ flex-direction: column;
9
+ ${({ fullWidth: t }) => t ? { width: "100%" } : null};
10
+ `, D = s.div`
5
11
  position: relative;
6
12
  border-radius: 12px;
7
13
  height: auto;
@@ -9,12 +15,12 @@ const T = l.div`
9
15
 
10
16
  ${({
11
17
  theme: {
12
- palette: { brand: t, background: i, grey: n }
18
+ palette: { brand: t, background: e, grey: n }
13
19
  },
14
20
  variant: c,
15
21
  isFocused: r
16
22
  }) => c === "filled" ? {
17
- backgroundColor: i.primary,
23
+ backgroundColor: e.primary,
18
24
  border: "1px solid transparent"
19
25
  } : c === "outlined" ? r ? {
20
26
  backgroundColor: n.white,
@@ -28,9 +34,9 @@ const T = l.div`
28
34
  theme: {
29
35
  palette: { etc: t }
30
36
  },
31
- variant: i,
37
+ variant: e,
32
38
  helper: n
33
- }) => i === "outlined" && ((n == null ? void 0 : n.severity) === "error" || n != null && n.message) ? {
39
+ }) => e === "outlined" && ((n == null ? void 0 : n.severity) === "error" || n != null && n.message) ? {
34
40
  borderColor: t.red
35
41
  } : {}}
36
42
 
@@ -38,9 +44,9 @@ const T = l.div`
38
44
  theme: {
39
45
  palette: { grey: t }
40
46
  },
41
- variant: i,
47
+ variant: e,
42
48
  disabled: n
43
- }) => i === "outlined" && n ? {
49
+ }) => e === "outlined" && n ? {
44
50
  backgroundColor: t[10],
45
51
  borderColor: t[30]
46
52
  } : {}}
@@ -48,7 +54,7 @@ const T = l.div`
48
54
  ${({ fullWidth: t }) => t ? {
49
55
  width: "100%"
50
56
  } : {}}
51
- `, q = l.textarea`
57
+ `, G = s.textarea`
52
58
  width: 100%;
53
59
  overflow: hidden;
54
60
  resize: none;
@@ -82,7 +88,10 @@ const T = l.div`
82
88
  })};
83
89
  }
84
90
 
85
- &::placeholder {
91
+ &::placeholder,
92
+ &::-webkit-input-placeholder,
93
+ &::-ms-input-placeholder,
94
+ &::-moz-placeholder {
86
95
  color: ${({ theme: t }) => t.palette.grey[50]};
87
96
  text-align: justify;
88
97
  }
@@ -95,8 +104,8 @@ const T = l.div`
95
104
  &[disabled]::placeholder {
96
105
  color: ${({ theme: t }) => t.palette.grey[30]};
97
106
  }
98
- `, B = l.div`
99
- color: ${({ theme: t, disabled: i }) => i ? t.palette.grey[30] : t.palette.grey[50]};
107
+ `, J = s.div`
108
+ color: ${({ theme: t, disabled: e }) => e ? t.palette.grey[30] : t.palette.grey[50]};
100
109
  text-align: right;
101
110
  padding-right: ${({ theme: t }) => t.spacing.content(4)}px;
102
111
  padding-bottom: ${({ theme: t }) => t.spacing.content(3)}px;
@@ -113,10 +122,19 @@ const T = l.div`
113
122
  })};
114
123
 
115
124
  & > span {
116
- color: ${({ theme: t, disabled: i }) => i ? t.palette.grey[30] : t.palette.grey[100]};
125
+ color: ${({ theme: t, disabled: e }) => e ? t.palette.grey[30] : t.palette.grey[100]};
126
+ }
127
+ `, K = s.p`
128
+ position: absolute;
129
+ left: 0;
130
+ bottom: calc(
131
+ ${({ theme: { spacing: t } }) => -t.content(1)}px -
132
+ ${({
133
+ theme: {
134
+ typography: { c3R: t }
117
135
  }
118
- `, I = l.p`
119
- margin-top: ${({ theme: { spacing: t } }) => t.content(1)}px;
136
+ }) => t.lineHeight}
137
+ );
120
138
  color: ${({ theme: t }) => t.palette.etc.red};
121
139
 
122
140
  ${({
@@ -129,94 +147,110 @@ const T = l.div`
129
147
  lineHeight: t.lineHeight,
130
148
  letterSpacing: t.letterSpacing
131
149
  })};
132
- `, E = l.p`
133
- position: absolute;
134
- width: 1px;
135
- height: 1px;
136
- margin: -1px;
137
- padding: 0;
138
- overflow: hidden;
139
- clip: rect(0, 0, 0, 0);
140
- border: 0;
141
- `, J = A(
150
+
151
+ &:empty {
152
+ display: none;
153
+ }
154
+ `, V = F(
142
155
  ({
143
156
  onChange: t,
144
- value: i,
157
+ value: e,
145
158
  variant: n = "filled",
146
159
  size: c = "large",
147
160
  maxLength: r = 290,
148
- onFocus: h,
149
- onBlur: y,
161
+ onFocus: $,
162
+ onBlur: x,
150
163
  helper: o,
151
- disabled: s = !1,
152
- wrapperProps: d,
153
- ...S
154
- }, H) => {
155
- const f = m(null), u = m(c === "large" ? 112.5 : 57.5), [v, x] = j(!1), $ = F(), w = (e) => {
156
- e.target.value.length > r && (e.target.value = e.target.value.slice(0, r)), typeof t == "function" && t(e);
157
- }, C = (e) => {
158
- x(!0), typeof h == "function" && h(e);
159
- }, z = (e) => {
160
- x(!1), typeof y == "function" && y(e);
161
- }, b = () => {
162
- var a;
163
- const e = (a = f.current) == null ? void 0 : a.querySelector("textarea");
164
- e && e.focus();
164
+ disabled: d = !1,
165
+ fullWidth: w,
166
+ wrapperProps: g,
167
+ ...z
168
+ }, C) => {
169
+ const f = v(null), p = v(c === "large" ? 112.5 : 57.5), [b, m] = q(!1), S = h(), k = h(), H = h(), W = (i) => {
170
+ i.target.value.length > r && (i.target.value = i.target.value.slice(0, r)), typeof t == "function" && t(i);
171
+ }, A = (i) => {
172
+ m(!0), typeof $ == "function" && $(i);
173
+ }, I = (i) => {
174
+ m(!1), typeof x == "function" && x(i);
175
+ }, M = () => {
176
+ var l;
177
+ const i = (l = f.current) == null ? void 0 : l.querySelector("textarea");
178
+ i && i.focus();
165
179
  };
166
- return M(() => {
167
- var a;
168
- const e = (a = f.current) == null ? void 0 : a.querySelector("textarea");
169
- if (e) {
170
- e.style.height = "auto";
171
- const { scrollHeight: k, clientHeight: W } = e;
172
- e.style.height = `${u.current}px`, e.style.height = `${Math.max(k, u.current, W)}px`;
180
+ return B(() => {
181
+ var l;
182
+ const i = (l = f.current) == null ? void 0 : l.querySelector("textarea");
183
+ if (i) {
184
+ i.style.height = "auto";
185
+ const { scrollHeight: T, clientHeight: j } = i;
186
+ i.style.height = `${p.current}px`, i.style.height = `${Math.max(T, p.current, j)}px`;
173
187
  }
174
- }, [i]), /* @__PURE__ */ g("div", { children: [
175
- /* @__PURE__ */ g(
176
- T,
188
+ }, [e]), /* @__PURE__ */ u(E, { fullWidth: w, children: [
189
+ /* @__PURE__ */ u(
190
+ D,
177
191
  {
178
192
  ref: f,
179
- isFocused: v,
193
+ isFocused: b,
180
194
  variant: n,
181
195
  helper: o,
182
- disabled: s,
183
- ...d,
184
- css: d == null ? void 0 : d.inlineCSS,
196
+ disabled: d,
197
+ ...g,
198
+ css: g == null ? void 0 : g.inlineCSS,
185
199
  children: [
186
- /* @__PURE__ */ p(
187
- q,
200
+ /* @__PURE__ */ a(
201
+ G,
188
202
  {
189
- ref: H,
190
- onChange: w,
191
- onFocus: C,
192
- onBlur: z,
193
- value: i,
194
- disabled: s,
203
+ ref: C,
204
+ id: k,
205
+ onChange: W,
206
+ onFocus: A,
207
+ onBlur: I,
208
+ value: e,
209
+ disabled: d,
195
210
  "aria-invalid": (o == null ? void 0 : o.severity) === "error",
196
- "aria-describedby": o != null && o.message ? $ : void 0,
197
- minHeight: u.current,
198
- ...S
211
+ "aria-describedby": o != null && o.message ? S : H,
212
+ minHeight: p.current,
213
+ ...z
199
214
  }
200
215
  ),
201
- /* @__PURE__ */ g(B, { disabled: s, onClick: b, children: [
202
- "(",
203
- /* @__PURE__ */ p("span", { children: i.length }),
204
- " / ",
205
- r,
206
- ")"
207
- ] })
216
+ /* @__PURE__ */ u(
217
+ J,
218
+ {
219
+ disabled: d,
220
+ onClick: M,
221
+ "aria-label": `현재 ${e.length}자 입력됨, 최대 ${r}자까지 입력 가능`,
222
+ children: [
223
+ "(",
224
+ /* @__PURE__ */ a("span", { children: e.length }),
225
+ " / ",
226
+ r,
227
+ ")"
228
+ ]
229
+ }
230
+ )
208
231
  ]
209
232
  }
210
233
  ),
211
- (o == null ? void 0 : o.message) && !s && /* @__PURE__ */ p(I, { id: $, helper: o, children: o.message }),
212
- i.length >= r && /* @__PURE__ */ g(E, { "aria-live": "assertive", role: "alert", children: [
213
- "최대 입력 글자 수에 도달하였습니다. ",
234
+ /* @__PURE__ */ a(
235
+ K,
236
+ {
237
+ id: S,
238
+ helper: o,
239
+ "aria-live": "assertive",
240
+ role: "alert",
241
+ children: !d && (o == null ? void 0 : o.message)
242
+ }
243
+ ),
244
+ /* @__PURE__ */ u(y, { visuallyHidden: !0, id: H, children: [
245
+ "최대 ",
214
246
  r,
215
- " 자까지 입력이 가능합니다."
216
- ] })
247
+ "까지 입력 가능"
248
+ ] }),
249
+ /* @__PURE__ */ a(y, { visuallyHidden: !0, "aria-live": "assertive", role: "alert", children: e.length >= r && `최대 입력 글자 수에 도달하였습니다. ${r} 자까지 입력이 가능합니다.` }),
250
+ /* @__PURE__ */ a(y, { visuallyHidden: !0, role: "status", children: e.length >= r * 0.8 && e.length < r && `최대 입력 가능한 글자 수의 80퍼센트에 도달했습니다. ${r * 0.8}자 입력됨.` })
217
251
  ] });
218
252
  }
219
253
  );
220
254
  export {
221
- J as default
255
+ V as default
222
256
  };
@@ -21,5 +21,5 @@ export declare const Outlined: Story;
21
21
  export declare const Filled: Story;
22
22
  export declare const FullWidth: Story;
23
23
  export declare const Small: Story;
24
- export declare const Success: Story;
25
24
  export declare const Error: Story;
25
+ export declare const WithScreenReaderSupport: Story;
@@ -1,34 +1,34 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const a=require("@emotion/react/jsx-runtime"),g=require("react"),x=require("../Icon/Icon.cjs"),z=require("@emotion/styled"),F=t=>t&&t.__esModule?t:{default:t},d=F(z),O=d.default.div`
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const c=require("@emotion/react/jsx-runtime"),u=require("react"),b=require("../Icon/Icon.cjs"),O=require("@emotion/styled"),_=t=>t&&t.__esModule?t:{default:t},f=_(O),T=f.default.div`
2
2
  position: relative;
3
3
  display: flex;
4
4
  flex-direction: column;
5
5
  ${({fullWidth:t})=>t?{width:"100%"}:null};
6
- `,_=d.default.div`
6
+ `,V=f.default.div`
7
7
  display: flex;
8
8
  align-items: center;
9
9
  justify-content: center;
10
10
  gap: ${({theme:{spacing:t}})=>t.content(2)}px;
11
11
  border: 1px solid transparent;
12
12
 
13
- ${({theme:{palette:{green:t,grey:e,background:i,etc:o}},variant:f,helper:s})=>{let r={backgroundColor:e.white,borderColor:e[50],color:e[100]};switch(f){case"outlined":(s==null?void 0:s.severity)==="success"&&(r={...r,borderColor:`${t[70]} !important`}),(s==null?void 0:s.severity)==="error"&&(r={...r,borderColor:`${o.red} !important`});break;case"filled":r={backgroundColor:i.primary};break}return r}};
13
+ ${({theme:{palette:{green:t,grey:e,background:o,etc:n}},variant:g,helper:s})=>{let r={backgroundColor:e.white,borderColor:e[50],color:e[100]};switch(g){case"outlined":(s==null?void 0:s.severity)==="success"&&(r={...r,borderColor:`${t[70]} !important`}),(s==null?void 0:s.severity)==="error"&&(r={...r,borderColor:`${n.red} !important`});break;case"filled":r={backgroundColor:o.primary};break}return r}};
14
14
 
15
- ${({theme:{spacing:t},size:e})=>{let i={maxHeight:48,padding:`${t.content(3)}px ${t.content(4)}px`,borderRadius:10};switch(e){case"2xLarge":i={maxHeight:80,padding:`${t.content(4)}px ${t.content(5)}px`,borderRadius:12,"& svg":{width:48,height:48}};break;case"xLarge":i={maxHeight:56,padding:t.content(4),borderRadius:12};break}return i}};
15
+ ${({theme:{spacing:t},size:e})=>{let o={maxHeight:48,padding:`${t.content(3)}px ${t.content(4)}px`,borderRadius:10};switch(e){case"2xLarge":o={maxHeight:80,padding:`${t.content(4)}px ${t.content(5)}px`,borderRadius:12,"& svg":{width:48,height:48}};break;case"xLarge":o={maxHeight:56,padding:t.content(4),borderRadius:12};break}return o}};
16
16
 
17
- ${({theme:{palette:{brand:t}},variant:e,focus:i})=>e==="outlined"&&i?{borderColor:t.primary.line}:null};
17
+ ${({theme:{palette:{brand:t}},variant:e,focus:o})=>e==="outlined"&&o?{borderColor:t.primary.line}:null};
18
18
 
19
19
  ${({fullWidth:t})=>t?{width:"100%"}:null};
20
20
 
21
- ${({theme:{palette:{grey:t}},variant:e,disabled:i})=>{if(!i)return null;let o={backgroundColor:t[10],borderColor:t[30]};switch(e){case"filled":o={backgroundColor:t[10]};break}return o}}
22
- `,T=d.default.input`
21
+ ${({theme:{palette:{grey:t}},variant:e,disabled:o})=>{if(!o)return null;let n={backgroundColor:t[10],borderColor:t[30]};switch(e){case"filled":n={backgroundColor:t[10]};break}return n}}
22
+ `,M=f.default.input`
23
23
  width: inherit;
24
24
  flex-grow: 1;
25
25
  border: none;
26
26
  background-color: transparent;
27
27
  outline: 0;
28
28
 
29
- ${({theme:{typography:{b2R:t,h0R:e}},inputSize:i})=>i==="2xLarge"?{fontSize:e.size,fontWeight:e.weight,lineHeight:e.lineHeight,letterSpacing:e.letterSpacing}:{fontSize:t.size,fontWeight:t.weight,lineHeight:t.lineHeight,letterSpacing:t.letterSpacing}};
29
+ ${({theme:{typography:{b2R:t,h0R:e}},inputSize:o})=>o==="2xLarge"?{fontSize:e.size,fontWeight:e.weight,lineHeight:e.lineHeight,letterSpacing:e.letterSpacing}:{fontSize:t.size,fontWeight:t.weight,lineHeight:t.lineHeight,letterSpacing:t.letterSpacing}};
30
30
 
31
- &::placeholder {
31
+ &::placeholder, &::-webkit-input-placeholder, &::-ms-input-placeholder, &::-moz-placeholder {
32
32
  ${({theme:{palette:{grey:t}},variant:e})=>({color:t[50]})};
33
33
  }
34
34
 
@@ -36,12 +36,28 @@
36
36
  cursor: not-allowed;
37
37
 
38
38
  ${({theme:{palette:{grey:t}}})=>({color:t[30],"&::placeholder":{color:t[30]}})}
39
- `,I=d.default.div`
39
+
40
+ &:focus {
41
+ outline: 'none';
42
+ }
43
+
44
+ &[type='password']::-ms-reveal {
45
+ display: none;
46
+ }
47
+ `,q=f.default.button`
48
+ &:empty {
49
+ display: none;
50
+ }
51
+ `,E=f.default.div`
40
52
  position: absolute;
41
53
  left: 0;
42
54
  bottom: ${({inputSize:t})=>t==="2xLarge"?"-26px":"-16px"};
43
55
  white-space: nowrap;
44
- ${({theme:{typography:{c3R:t,b1R:e}},inputSize:i})=>i==="2xLarge"?{fontSize:e.size,fontWeight:e.weight,lineHeight:e.lineHeight,letterSpacing:e.letterSpacing}:{fontSize:t.size,fontWeight:t.weight,lineHeight:t.lineHeight,letterSpacing:t.letterSpacing}};
56
+ ${({theme:{typography:{c3R:t,b1R:e}},inputSize:o})=>o==="2xLarge"?{fontSize:e.size,fontWeight:e.weight,lineHeight:e.lineHeight,letterSpacing:e.letterSpacing}:{fontSize:t.size,fontWeight:t.weight,lineHeight:t.lineHeight,letterSpacing:t.letterSpacing}};
45
57
 
46
- ${({theme:{palette:{etc:t,grey:e}},helper:i})=>{const o={color:e[100]};return(i==null?void 0:i.severity)==="error"?{color:t.red}:o}}
47
- `,V=g.forwardRef(function({type:e,variant:i="outlined",size:o="large",startAdornment:f,endAdornment:s,fullWidth:r,helper:n,disabled:b,inlineCSS:w,onFocus:m,onBlur:p,disablePasswordVisibility:$,...j},h){const[v,S]=g.useState(!1),[l,C]=g.useState(!1),u=!$&&!s&&e==="password"&&(n==null?void 0:n.severity)!=="success",k=c=>{S(!0),typeof m=="function"&&m(c)},H=c=>{S(!1),typeof p=="function"&&p(c)},y=()=>C(c=>!c),L=()=>u&&l?"text":u&&!l?"password":e;return a.jsxs(O,{fullWidth:r,children:[a.jsxs(_,{variant:i,size:o,focus:v,fullWidth:r,helper:n,disabled:b,css:w,children:[f,a.jsx(T,{ref:h,type:L(),variant:i,inputSize:o,disabled:b,...j,onFocus:k,onBlur:H}),s,!s&&(n==null?void 0:n.severity)==="success"&&a.jsx(x.default,{name:"CheckLine",color:"green.70"}),u&&l&&a.jsx(x.default,{name:"EyeVisibleLine","data-testid":"EyeVisibleLine",onClick:y,inlineCSS:{cursor:"pointer"}}),u&&!l&&a.jsx(x.default,{name:"EyeInvisibleLine","data-testid":"EyeInvisibleLine",onClick:y,inlineCSS:{cursor:"pointer"}})]}),(n==null?void 0:n.message)&&a.jsx(I,{helper:n,inputSize:o,"data-testid":"helper",children:n==null?void 0:n.message})]})});exports.default=V;
58
+ ${({theme:{palette:{etc:t,grey:e}},helper:o})=>{const n={color:e[100]};return(o==null?void 0:o.severity)==="error"?{color:t.red}:n}}
59
+
60
+ &:empty {
61
+ display: none;
62
+ }
63
+ `,W=u.forwardRef(function({type:e="text",variant:o="outlined",size:n="large",startAdornment:g,endAdornment:s,fullWidth:r,helper:i,disabled:x,inlineCSS:w,onFocus:y,onBlur:m,disablePasswordVisibility:S,helperProps:$,...j},k){const C=u.useId(),p=u.useId(),[H,v]=u.useState(!1),[d,I]=u.useState(!1),a=!S&&!s&&e==="password"&&(i==null?void 0:i.severity)!=="success",L=l=>{v(!0),typeof y=="function"&&y(l)},z=l=>{v(!1),typeof m=="function"&&m(l)},F=()=>I(l=>!l),h=()=>a&&d?"text":a&&!d?"password":e;return c.jsxs(T,{fullWidth:r,children:[c.jsxs(V,{variant:o,size:n,focus:H,fullWidth:r,helper:i,disabled:x,css:w,children:[g,c.jsx(M,{ref:k,id:C,type:h(),variant:o,inputSize:n,disabled:x,"aria-invalid":(i==null?void 0:i.severity)==="error","aria-describedby":i!=null&&i.message?p:void 0,...j,onFocus:L,onBlur:z}),s,!s&&(i==null?void 0:i.severity)==="success"&&c.jsx(b.default,{name:"CheckLine",color:"green.70","aria-label":"성공",role:"img"}),c.jsxs(q,{type:"button",tabIndex:a?0:-1,"aria-pressed":a?d:void 0,onClick:F,"aria-hidden":!a,"aria-label":a&&d?"비밀번호 표시됨":"비밀번호 숨김됨",children:[a&&d&&c.jsx(b.default,{name:"EyeVisibleLine","data-testid":"EyeVisibleLine",inlineCSS:{cursor:"pointer"}}),a&&!d&&c.jsx(b.default,{name:"EyeInvisibleLine","data-testid":"EyeInvisibleLine",inlineCSS:{cursor:"pointer"}})]})]}),c.jsx(E,{id:p,className:"textfield-helper","aria-live":(i==null?void 0:i.severity)==="error"?"assertive":"off",role:(i==null?void 0:i.severity)==="error"?"alert":"status",helper:i,inputSize:n,"data-testid":"helper",...$,children:i==null?void 0:i.message})]})});exports.default=W;
@@ -1,4 +1,4 @@
1
- import { InputHTMLAttributes, ReactNode } from 'react';
1
+ import { HTMLAttributes, InputHTMLAttributes, ReactNode } from 'react';
2
2
  import { GeneralComponentProps, Size, Variant } from '../typings/component';
3
3
 
4
4
  export interface TextFieldProps extends GeneralComponentProps<Omit<InputHTMLAttributes<HTMLInputElement>, 'size'>> {
@@ -12,6 +12,7 @@ export interface TextFieldProps extends GeneralComponentProps<Omit<InputHTMLAttr
12
12
  };
13
13
  fullWidth?: boolean;
14
14
  disablePasswordVisibility?: boolean;
15
+ helperProps?: HTMLAttributes<HTMLDivElement>;
15
16
  }
16
17
  declare const TextField: import('react').ForwardRefExoticComponent<TextFieldProps & import('react').RefAttributes<HTMLInputElement>>;
17
18
  export default TextField;