boottent-design 0.1.228 → 0.1.230

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 (232) hide show
  1. package/README.md +44 -264
  2. package/dist/common-BDxfDP0R.cjs +1 -0
  3. package/dist/common-BIhdwzSy.js +36 -0
  4. package/dist/components.cjs.js +1 -36
  5. package/dist/components.es.js +3418 -12613
  6. package/dist/hooks.cjs.js +1 -1
  7. package/dist/hooks.es.js +15 -18
  8. package/dist/index-Bd5H-34O.js +480 -0
  9. package/dist/index-Pk9DsS9C.cjs +1 -0
  10. package/dist/{notion-CfqLwM8d.js → notion-Cj4oTQKd.js} +1 -1
  11. package/dist/notion-Dlh1st3Q.cjs +1 -0
  12. package/dist/portal-manager-DFLUb__g.js +120 -0
  13. package/dist/portal-manager-Dl6mDNAG.cjs +1 -0
  14. package/dist/provider.cjs.js +1 -1
  15. package/dist/provider.es.js +49 -50
  16. package/dist/styles.css +1 -0
  17. package/dist/toast-form-CV2bTOOT.js +274 -0
  18. package/dist/toast-form-kmiEb4pb.cjs +1 -0
  19. package/dist/types/accordion.d.ts +11 -0
  20. package/dist/types/alert-dialog.d.ts +39 -0
  21. package/dist/types/anchor.d.ts +15 -0
  22. package/dist/types/aspect-ratio.d.ts +9 -0
  23. package/dist/types/avatar.d.ts +10 -0
  24. package/dist/types/badge.d.ts +15 -0
  25. package/dist/types/box.d.ts +14 -0
  26. package/dist/types/button.d.ts +20 -0
  27. package/dist/types/calendar.d.ts +13 -0
  28. package/dist/types/callout.d.ts +15 -0
  29. package/dist/types/card.d.ts +15 -0
  30. package/dist/types/checkbox.d.ts +6 -0
  31. package/dist/types/circled-check-button.d.ts +9 -0
  32. package/dist/types/command.d.ts +94 -0
  33. package/dist/types/dialog.d.ts +31 -0
  34. package/dist/types/dropdown-menu.d.ts +44 -0
  35. package/dist/types/file-uploader.d.ts +42 -0
  36. package/dist/types/flexbox.d.ts +13 -0
  37. package/dist/types/form.d.ts +45 -0
  38. package/dist/types/gridbox.d.ts +14 -0
  39. package/dist/types/heading3.d.ts +11 -0
  40. package/dist/types/heading4.d.ts +10 -0
  41. package/dist/types/highlight-text.d.ts +12 -0
  42. package/dist/types/icons.d.ts +186 -0
  43. package/dist/types/image.d.ts +24 -0
  44. package/dist/types/input.d.ts +11 -0
  45. package/dist/types/label.d.ts +8 -0
  46. package/dist/types/month-picker.d.ts +11 -0
  47. package/dist/types/multi-select.d.ts +54 -0
  48. package/dist/types/navigation-menu.d.ts +23 -0
  49. package/dist/types/popover.d.ts +10 -0
  50. package/dist/types/radio-group.d.ts +10 -0
  51. package/dist/types/scroll-area.d.ts +8 -0
  52. package/dist/types/select.d.ts +24 -0
  53. package/dist/types/separator.d.ts +6 -0
  54. package/dist/types/simple-table.d.ts +19 -0
  55. package/dist/types/skeleton.d.ts +10 -0
  56. package/dist/types/slider.d.ts +7 -0
  57. package/dist/types/switch.d.ts +6 -0
  58. package/dist/types/symbols.d.ts +20 -0
  59. package/dist/types/tabs.d.ts +12 -0
  60. package/dist/types/tag.d.ts +19 -0
  61. package/dist/types/text.d.ts +48 -0
  62. package/dist/types/textarea.d.ts +9 -0
  63. package/dist/types/toast-modal.d.ts +53 -0
  64. package/dist/types/toast.d.ts +40 -0
  65. package/dist/types/toggle-group.d.ts +50 -0
  66. package/dist/types/toggle.d.ts +22 -0
  67. package/dist/types/tooltip.d.ts +44 -0
  68. package/dist/types/ui/accordion.d.ts +2 -0
  69. package/dist/types/ui/alert-dialog.d.ts +2 -0
  70. package/dist/types/ui/anchor.d.ts +2 -0
  71. package/dist/types/ui/aspect-ratio.d.ts +2 -0
  72. package/dist/types/ui/avatar.d.ts +2 -0
  73. package/dist/types/ui/badge.d.ts +2 -0
  74. package/dist/types/ui/box.d.ts +2 -0
  75. package/dist/types/ui/button.d.ts +2 -0
  76. package/dist/types/ui/calendar.d.ts +2 -0
  77. package/dist/types/ui/callout.d.ts +2 -0
  78. package/dist/types/ui/card.d.ts +2 -0
  79. package/dist/types/ui/checkbox.d.ts +2 -0
  80. package/dist/types/ui/circled-check-button.d.ts +2 -0
  81. package/dist/types/ui/command.d.ts +2 -0
  82. package/dist/types/ui/dialog.d.ts +2 -0
  83. package/dist/types/ui/dropdown-menu.d.ts +2 -0
  84. package/dist/types/ui/file-uploader.d.ts +2 -0
  85. package/dist/types/ui/flexbox.d.ts +2 -0
  86. package/dist/types/ui/form.d.ts +2 -0
  87. package/dist/types/ui/gridbox.d.ts +2 -0
  88. package/dist/types/ui/heading3.d.ts +2 -0
  89. package/dist/types/ui/heading4.d.ts +2 -0
  90. package/dist/types/ui/highlight-text.d.ts +2 -0
  91. package/dist/types/ui/icons.d.ts +2 -0
  92. package/dist/types/ui/image.d.ts +4 -0
  93. package/dist/types/ui/input.d.ts +2 -0
  94. package/dist/types/ui/label.d.ts +2 -0
  95. package/dist/types/ui/month-picker.d.ts +2 -0
  96. package/dist/types/ui/multi-select.d.ts +2 -0
  97. package/dist/types/ui/navigation-menu.d.ts +2 -0
  98. package/dist/types/ui/popover.d.ts +2 -0
  99. package/dist/types/ui/radio-group.d.ts +2 -0
  100. package/dist/types/ui/scroll-area.d.ts +2 -0
  101. package/dist/types/ui/select.d.ts +2 -0
  102. package/dist/types/ui/separator.d.ts +2 -0
  103. package/dist/types/ui/simple-table.d.ts +2 -0
  104. package/dist/types/ui/skeleton.d.ts +2 -0
  105. package/dist/types/ui/slider.d.ts +2 -0
  106. package/dist/types/ui/switch.d.ts +2 -0
  107. package/dist/types/ui/symbols.d.ts +2 -0
  108. package/dist/types/ui/tabs.d.ts +2 -0
  109. package/dist/types/ui/tag.d.ts +2 -0
  110. package/dist/types/ui/text.d.ts +2 -0
  111. package/dist/types/ui/textarea.d.ts +2 -0
  112. package/dist/types/ui/toast-modal.d.ts +2 -0
  113. package/dist/types/ui/toast.d.ts +2 -0
  114. package/dist/types/ui/toggle-group.d.ts +2 -0
  115. package/dist/types/ui/toggle.d.ts +2 -0
  116. package/dist/types/ui/tooltip.d.ts +2 -0
  117. package/dist/ui/accordion.cjs.js +1 -0
  118. package/dist/ui/accordion.es.js +44 -0
  119. package/dist/ui/alert-dialog.cjs.js +1 -0
  120. package/dist/ui/alert-dialog.es.js +100 -0
  121. package/dist/ui/anchor.cjs.js +1 -0
  122. package/dist/ui/anchor.es.js +42 -0
  123. package/dist/ui/aspect-ratio.cjs.js +1 -0
  124. package/dist/ui/aspect-ratio.es.js +5 -0
  125. package/dist/ui/avatar.cjs.js +1 -0
  126. package/dist/ui/avatar.es.js +29 -0
  127. package/dist/ui/badge.cjs.js +1 -0
  128. package/dist/ui/badge.es.js +27 -0
  129. package/dist/ui/box.cjs.js +1 -0
  130. package/dist/ui/box.es.js +6 -0
  131. package/dist/ui/button.cjs.js +1 -0
  132. package/dist/ui/button.es.js +97 -0
  133. package/dist/ui/calendar.cjs.js +1 -0
  134. package/dist/ui/calendar.es.js +90 -0
  135. package/dist/ui/callout.cjs.js +1 -0
  136. package/dist/ui/callout.es.js +62 -0
  137. package/dist/ui/card.cjs.js +1 -0
  138. package/dist/ui/card.es.js +33 -0
  139. package/dist/ui/checkbox.cjs.js +1 -0
  140. package/dist/ui/checkbox.es.js +18 -0
  141. package/dist/ui/circled-check-button.cjs.js +1 -0
  142. package/dist/ui/circled-check-button.es.js +8 -0
  143. package/dist/ui/command.cjs.js +1 -0
  144. package/dist/ui/command.es.js +83 -0
  145. package/dist/ui/dialog.cjs.js +1 -0
  146. package/dist/ui/dialog.es.js +65 -0
  147. package/dist/ui/dropdown-menu.cjs.js +1 -0
  148. package/dist/ui/dropdown-menu.es.js +129 -0
  149. package/dist/ui/file-uploader.cjs.js +1 -0
  150. package/dist/ui/file-uploader.es.js +228 -0
  151. package/dist/ui/flexbox.cjs.js +1 -0
  152. package/dist/ui/flexbox.es.js +9 -0
  153. package/dist/ui/form.cjs.js +1 -0
  154. package/dist/ui/form.es.js +110 -0
  155. package/dist/ui/gridbox.cjs.js +1 -0
  156. package/dist/ui/gridbox.es.js +17 -0
  157. package/dist/ui/heading3.cjs.js +1 -0
  158. package/dist/ui/heading3.es.js +8 -0
  159. package/dist/ui/heading4.cjs.js +1 -0
  160. package/dist/ui/heading4.es.js +7 -0
  161. package/dist/ui/highlight-text.cjs.js +1 -0
  162. package/dist/ui/highlight-text.es.js +17 -0
  163. package/dist/ui/icons.cjs.js +2 -0
  164. package/dist/ui/icons.es.js +1790 -0
  165. package/dist/ui/image.cjs.js +1 -0
  166. package/dist/ui/image.es.js +39 -0
  167. package/dist/ui/input.cjs.js +1 -0
  168. package/dist/ui/input.es.js +27 -0
  169. package/dist/ui/label.cjs.js +1 -0
  170. package/dist/ui/label.es.js +10 -0
  171. package/dist/ui/month-picker.cjs.js +1 -0
  172. package/dist/ui/month-picker.es.js +10 -0
  173. package/dist/ui/multi-select.cjs.js +1 -0
  174. package/dist/ui/multi-select.es.js +200 -0
  175. package/dist/ui/navigation-menu.cjs.js +1 -0
  176. package/dist/ui/navigation-menu.es.js +98 -0
  177. package/dist/ui/popover.cjs.js +1 -0
  178. package/dist/ui/popover.es.js +23 -0
  179. package/dist/ui/radio-group.cjs.js +1 -0
  180. package/dist/ui/radio-group.es.js +32 -0
  181. package/dist/ui/scroll-area.cjs.js +1 -0
  182. package/dist/ui/scroll-area.es.js +30 -0
  183. package/dist/ui/select.cjs.js +1 -0
  184. package/dist/ui/select.es.js +102 -0
  185. package/dist/ui/separator.cjs.js +1 -0
  186. package/dist/ui/separator.es.js +18 -0
  187. package/dist/ui/simple-table.cjs.js +1 -0
  188. package/dist/ui/simple-table.es.js +26 -0
  189. package/dist/ui/skeleton.cjs.js +1 -0
  190. package/dist/ui/skeleton.es.js +21 -0
  191. package/dist/ui/slider.cjs.js +1 -0
  192. package/dist/ui/slider.es.js +61 -0
  193. package/dist/ui/switch.cjs.js +1 -0
  194. package/dist/ui/switch.es.js +27 -0
  195. package/dist/ui/symbols.cjs.js +1 -0
  196. package/dist/ui/symbols.es.js +365 -0
  197. package/dist/ui/tabs.cjs.js +1 -0
  198. package/dist/ui/tabs.es.js +43 -0
  199. package/dist/ui/tag.cjs.js +1 -0
  200. package/dist/ui/tag.es.js +57 -0
  201. package/dist/ui/text.cjs.js +1 -0
  202. package/dist/ui/text.es.js +27 -0
  203. package/dist/ui/textarea.cjs.js +1 -0
  204. package/dist/ui/textarea.es.js +20 -0
  205. package/dist/ui/toast-modal.cjs.js +1 -0
  206. package/dist/ui/toast-modal.es.js +88 -0
  207. package/dist/ui/toast.cjs.js +1 -0
  208. package/dist/ui/toast.es.js +94 -0
  209. package/dist/ui/toggle-group.cjs.js +1 -0
  210. package/dist/ui/toggle-group.es.js +39 -0
  211. package/dist/ui/toggle.cjs.js +1 -0
  212. package/dist/ui/toggle.es.js +65 -0
  213. package/dist/ui/tooltip.cjs.js +1 -0
  214. package/dist/ui/tooltip.es.js +162 -0
  215. package/dist/ui.cjs.js +1 -6
  216. package/dist/ui.es.js +209 -1099
  217. package/dist/utils.cjs.js +1 -1
  218. package/dist/utils.es.js +50 -25
  219. package/package.json +33 -20
  220. package/dist/index-C1V-Rppc.js +0 -14674
  221. package/dist/index-C4XuWaYn.cjs +0 -1
  222. package/dist/index-Cv4pTXfv.cjs +0 -67
  223. package/dist/index-DD82nOxO.js +0 -60
  224. package/dist/index-DT339AZp.js +0 -5507
  225. package/dist/index-DmwELRWu.cjs +0 -85
  226. package/dist/notion-Sqp-Xzqi.cjs +0 -1
  227. package/dist/portal-manager-CyWNKHmr.cjs +0 -1
  228. package/dist/portal-manager-fk0biCEh.js +0 -142
  229. package/dist/preview-9QZ5P9LT.cjs +0 -1
  230. package/dist/preview-Cocn_vDi.js +0 -2334
  231. package/dist/toast-form-BeZm-DM9.cjs +0 -1
  232. package/dist/toast-form-eSsNpl77.js +0 -237
package/README.md CHANGED
@@ -6,7 +6,9 @@
6
6
  - [특징](#특징)
7
7
  - [시작하기](#시작하기)
8
8
  - [설치](#설치)
9
- - [프로젝트 설정](#프로젝트-설정)
9
+ - [빠른 사용법 (Tailwind 설정 불필요)](#빠른-사용법-tailwind-설정-불필요)
10
+ - [성능 권장 import](#성능-권장-import)
11
+ - [모듈 import 경로](#모듈-import-경로)
10
12
  - [제작 및 배포](#제작-및-배포)
11
13
 
12
14
  ## 소개
@@ -27,289 +29,67 @@ yarn add boottent-design@latest
27
29
  npm install boottent-design@latest
28
30
  ```
29
31
 
30
- ### 프로젝트 설정
32
+ ### 빠른 사용법 (Tailwind 설정 불필요)
31
33
 
32
- boottent-design을 프로젝트에 적용하기 위해 Vite와 TailwindCSS 설정이 필요합니다.
34
+ Tailwind를 직접 설치하거나 `tailwind.config`를 수정하지 않아도 됩니다.
35
+ 라이브러리에서 미리 빌드된 CSS를 함께 제공하므로, 아래 2단계만 하면 동작합니다.
33
36
 
34
- #### 1. React + TypeScript 프로젝트 생성
37
+ 1. 엔트리에서 스타일 1회 임포트
35
38
 
36
- ```sh
37
- yarn create vite my-react-app --template react-ts
38
- cd my-react-app
39
- yarn
40
- ```
41
-
42
- #### 2. TailwindCSS 설정
43
-
44
- Tailwind CSS와 관련된 패키지를 설치합니다:
45
-
46
- ```sh
47
- yarn add -D tailwindcss postcss autoprefixer
48
- ```
49
-
50
- #### 3. TailwindCSS 설정 파일 생성
39
+ ```tsx
40
+ import React from "react";
41
+ import ReactDOM from "react-dom/client";
42
+ import App from "./App";
43
+ import "boottent-design/styles.css";
51
44
 
52
- ```sh
53
- npx tailwindcss init -p
45
+ ReactDOM.createRoot(document.getElementById("root") as HTMLElement).render(
46
+ <React.StrictMode>
47
+ <App />
48
+ </React.StrictMode>,
49
+ );
54
50
  ```
55
51
 
56
- #### 4. TailwindCSS 설정 파일 편집
57
-
58
- tailwind.config.js 파일에 다음 내용을 추가합니다:
52
+ 2. 필요한 모듈 import 후 바로 사용
59
53
 
60
- ```js
61
- /** @type {import('tailwindcss').Config} */
62
-
63
- const colors = require("tailwindcss/colors");
64
- const defaultTheme = require("tailwindcss/defaultTheme");
65
-
66
- export default {
67
- content: [
68
- "./index.html",
69
- "./src/**/*.{js,ts,jsx,tsx}",
70
- "./node_modules/boottent-design/**/*.{js,ts,jsx,tsx}", // boottent-design 적용 경로 추가
71
- ],
72
- theme: {
73
- screens: {
74
- xs: "480px",
75
- xxs: "360px",
76
- ...defaultTheme.screens,
77
- },
78
- colors: {
79
- ...colors,
80
- grey: {
81
- 50: "#FCFEFF",
82
- 100: "#F5F8FA",
83
- 200: "#DDE2E6",
84
- 300: "#D0D3D5",
85
- 400: "#A2A3A4",
86
- 500: "#737474",
87
- 600: "#525252",
88
- 700: "#404040",
89
- 800: "#26282A",
90
- 900: "#181919",
91
- 950: "#0A0A0B",
92
- },
93
- main: {
94
- 50: "#F8F8FF",
95
- 100: "#ECECFF",
96
- 200: "#D5D4FA",
97
- 300: "#BEB6F7",
98
- 400: "#A08DF2",
99
- 500: "#8261ED",
100
- 600: "#7344E3",
101
- 700: "#6434D1",
102
- 800: "#532FB1",
103
- 900: "#462690",
104
- 950: "#2A1662",
105
- },
106
- red: {
107
- ...colors.red,
108
- 50: "#FEEFEE",
109
- 300: "#FF4A56",
110
- 400: "#E91927",
111
- 500: "#C4131F",
112
- },
113
- pink: {
114
- ...colors.pink,
115
- 50: "#FFEAFD",
116
- 500: "#D2216C",
117
- },
118
- yellow: {
119
- ...colors.yellow,
120
- 100: "#FFFAE2",
121
- 300: "#FFED97",
122
- 400: "#FFE55C",
123
- kakao: "#FEE500",
124
- },
125
- orange: {
126
- ...colors.orange,
127
- 50: "#FFF2DD",
128
- 500: "#F16815",
129
- },
130
- brown: {
131
- 50: "#FEF6E2",
132
- 500: "#C9600B",
133
- },
134
- lime: {
135
- ...colors.lime,
136
- 50: "#FAFFE2",
137
- 500: "#639A05",
138
- },
139
- green: {
140
- ...colors.green,
141
- 50: "#F4FFEA",
142
- 500: "#349613",
143
- naver: "#03C75A",
144
- },
145
- teal: {
146
- ...colors.teal,
147
- 50: "#E3FFFA",
148
- 500: "#248E93",
149
- },
150
- blue: {
151
- ...colors.blue,
152
- 50: "#F0F8FF",
153
- 100: "#E4F6FF",
154
- 400: "#3A8AF1",
155
- 500: "#2D60D4",
156
- 600: "#4145AC",
157
- },
158
- },
159
- extend: {
160
- colors: {
161
- border: "var(--border)",
162
- input: "hsl(var(--input))",
163
- ring: "hsl(var(--ring))",
164
- background: "var(--background)",
165
- foreground: "var(--foreground)",
166
- primary: {
167
- DEFAULT: "var(--primary)",
168
- foreground: "var(--primary-foreground)",
169
- },
170
- secondary: {
171
- DEFAULT: "var(--secondary)",
172
- foreground: "var(--secondary-foreground)",
173
- },
174
- destructive: {
175
- DEFAULT: "var(--destructive)",
176
- foreground: "hsl(var(--destructive-foreground))",
177
- },
178
- muted: {
179
- DEFAULT: "var(--muted)",
180
- foreground: "var(--muted-foreground)",
181
- },
182
- accent: {
183
- DEFAULT: "hsl(var(--accent))",
184
- foreground: "hsl(var(--accent-foreground))",
185
- },
186
- popover: {
187
- DEFAULT: "hsl(var(--popover))",
188
- foreground: "hsl(var(--popover-foreground))",
189
- },
190
- card: {
191
- DEFAULT: "hsl(var(--card))",
192
- foreground: "hsl(var(--card-foreground))",
193
- },
194
- },
195
- borderRadius: {
196
- lg: "var(--radius)",
197
- md: "calc(var(--radius) - 2px)",
198
- sm: "calc(var(--radius) - 4px)",
199
- },
200
- keyframes: {
201
- "accordion-down": {
202
- from: { height: "0" },
203
- to: { height: "var(--radix-accordion-content-height)" },
204
- },
205
- "accordion-up": {
206
- from: { height: "var(--radix-accordion-content-height)" },
207
- to: { height: "0" },
208
- },
209
- },
210
- animation: {
211
- "accordion-down": "accordion-down 0.2s ease-out",
212
- "accordion-up": "accordion-up 0.2s ease-out",
213
- },
214
- },
215
- },
216
- plugins: [],
217
- };
218
- ```
219
-
220
- postcss.config.js 파일에 다음 내용을 추가합니다:
54
+ ```tsx
55
+ import { Button } from "boottent-design/ui/button";
221
56
 
222
- ```js
223
- export default {
224
- plugins: {
225
- tailwindcss: {},
226
- autoprefixer: {},
227
- },
228
- };
57
+ export function Sample() {
58
+ return <Button>확인</Button>;
59
+ }
229
60
  ```
230
61
 
231
- #### 5. Tailwind CSS 스타일 임포트
62
+ ### 성능 권장 import
232
63
 
233
- src/index.css 혹은 main.css 파일을 생성하고 Tailwind CSS 지시문을 추가합니다:
64
+ 소비자 빌드 시간을 줄이려면 배럴 import보다 deep import를 권장합니다.
234
65
 
235
- ```css
236
- @tailwind base;
237
- @tailwind components;
238
- @tailwind utilities;
66
+ - 권장: `import { Button } from "boottent-design/ui/button"`
67
+ - 비권장(대량 사용 시 빌드 시간 증가 가능): `import { Button } from "boottent-design/ui"`
239
68
 
240
- @layer base {
241
- :root {
242
- --background: #ffffff;
243
- --foreground: #26282a;
244
- --card: 0 0% 100%;
245
- --card-foreground: 224 71.4% 4.1%;
246
- --popover: 0 0% 100%;
247
- --popover-foreground: 224 71.4% 4.1%;
248
- --primary: #7344e3;
249
- --primary-foreground: #ffffff;
250
- --secondary: #26282a;
251
- --secondary-foreground: #ffffff;
252
- --muted: #a2a3a4;
253
- --muted-foreground: #ffffff;
254
- --muted-border: #dde2e6;
255
- --accent: 220 14.3% 95.9%;
256
- --accent-foreground: 220.9 39.3% 11%;
257
- --destructive: #e91927;
258
- --destructive-foreground: 210 20% 98%;
259
- --border: #dde2e6;
260
- --input: 220 13% 91%;
261
- --ring: 224 71.4% 4.1%;
262
- --radius: 0.5rem;
263
- }
69
+ `boottent-design/ui`는 기존 호환성을 위해 유지되지만, 성능 관점에서는 `ui/*` 경로 사용을 권장합니다.
264
70
 
265
- .dark {
266
- --background: 224 71.4% 4.1%;
267
- --foreground: 210 20% 98%;
268
- --card: 224 71.4% 4.1%;
269
- --card-foreground: 210 20% 98%;
270
- --popover: 224 71.4% 4.1%;
271
- --popover-foreground: 210 20% 98%;
272
- --primary: 210 20% 98%;
273
- --primary-foreground: 220.9 39.3% 11%;
274
- --secondary: 215 27.9% 16.9%;
275
- --secondary-foreground: 210 20% 98%;
276
- --muted: 215 27.9% 16.9%;
277
- --muted-foreground: 217.9 10.6% 64.9%;
278
- --accent: 215 27.9% 16.9%;
279
- --accent-foreground: 210 20% 98%;
280
- --destructive: 0 62.8% 30.6%;
281
- --destructive-foreground: 210 20% 98%;
282
- --border: 215 27.9% 16.9%;
283
- --input: 215 27.9% 16.9%;
284
- --ring: 216 12.2% 83.9%;
285
- }
286
- }
71
+ ```tsx
72
+ import { Button } from "boottent-design/ui";
287
73
 
288
- @layer base {
289
- * {
290
- @apply border-border;
291
- }
292
- body {
293
- @apply bg-background text-foreground;
294
- }
74
+ export function Sample() {
75
+ return <Button>확인</Button>;
295
76
  }
296
77
  ```
297
78
 
298
- 그리고 src/main.tsx 파일에 main.css 파일을 임포트합니다:
79
+ ### 모듈 import 경로
299
80
 
300
- ```tsx
301
- // src/main.tsx
302
- import React from "react";
303
- import ReactDOM from "react-dom/client";
304
- import App from "./App";
305
- import "./main.css"; // Tailwind CSS 파일 임포트
81
+ - `boottent-design/ui`
82
+ - `boottent-design/components`
83
+ - `boottent-design/provider`
84
+ - `boottent-design/hooks`
85
+ - `boottent-design/tokens`
86
+ - `boottent-design/utils`
87
+ - `boottent-design/types`
306
88
 
307
- ReactDOM.createRoot(document.getElementById("root") as HTMLElement).render(
308
- <React.StrictMode>
309
- <App />
310
- </React.StrictMode>,
311
- );
312
- ```
89
+ ### 참고
90
+
91
+ - 기존처럼 소비자 프로젝트에서 Tailwind를 직접 운영해도 됩니다.
92
+ - 다만 `boottent-design`을 사용하기 위해 Tailwind 설정이 필수는 아닙니다.
313
93
 
314
94
  ## 제작 및 배포
315
95
 
@@ -0,0 +1 @@
1
+ "use strict";const a=require("clsx"),u=require("tailwind-merge"),f=(...e)=>u.twMerge(a(e));function l(e){const r=!e||e.includes("utm_source")?"":"utm_source=boottent&utm_medium=referral",n=e&&e.includes("?")?"&":"?";return`${e}${n}${r}`}const m=e=>{const t={};return e.split(";").forEach(r=>{const[n,s]=r.split(":").map(c=>c.trim());if(n&&s){const c=n.replace(/-([a-z])/g,(g,i)=>i.toUpperCase());t[c]=s}}),t},o=e=>{const t=e.trim().split(" ");return t.length===3&&t[1]==="00:00"?`${t[0]} ${t[2]}`:t.length===2?`${t[0]} ${t[1]??"00:00"}`:e};function p(e){e=o(e);const t=24*60*60*1e3,r=new Date;r.setHours(0,0,0,0);const n=new Date(e);n.setHours(0,0,0,0);const s=n.getTime()-r.getTime();return Math.round(s/t)}exports.addUTMtoUrl=l;exports.cn=f;exports.getDaysDifference=p;exports.parseDateString=o;exports.parseInlineStyle=m;
@@ -0,0 +1,36 @@
1
+ import a from "clsx";
2
+ import { twMerge as i } from "tailwind-merge";
3
+ const l = (...e) => i(a(e));
4
+ function g(e) {
5
+ const n = !e || e.includes("utm_source") ? "" : "utm_source=boottent&utm_medium=referral", r = e && e.includes("?") ? "&" : "?";
6
+ return `${e}${r}${n}`;
7
+ }
8
+ const D = (e) => {
9
+ const t = {};
10
+ return e.split(";").forEach((n) => {
11
+ const [r, s] = n.split(":").map((o) => o.trim());
12
+ if (r && s) {
13
+ const o = r.replace(/-([a-z])/g, (u, c) => c.toUpperCase());
14
+ t[o] = s;
15
+ }
16
+ }), t;
17
+ }, m = (e) => {
18
+ const t = e.trim().split(" ");
19
+ return t.length === 3 && t[1] === "00:00" ? `${t[0]} ${t[2]}` : t.length === 2 ? `${t[0]} ${t[1] ?? "00:00"}` : e;
20
+ };
21
+ function $(e) {
22
+ e = m(e);
23
+ const t = 24 * 60 * 60 * 1e3, n = /* @__PURE__ */ new Date();
24
+ n.setHours(0, 0, 0, 0);
25
+ const r = new Date(e);
26
+ r.setHours(0, 0, 0, 0);
27
+ const s = r.getTime() - n.getTime();
28
+ return Math.round(s / t);
29
+ }
30
+ export {
31
+ g as a,
32
+ m as b,
33
+ l as c,
34
+ $ as g,
35
+ D as p
36
+ };