@twreporter/react-typescript-components 0.1.0-beta.5 → 0.1.0-beta.6
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/README.md +11 -1
- package/lib/button/components/text-button/index.d.mts +24 -0
- package/lib/button/components/text-button/index.d.ts +24 -0
- package/lib/button/components/text-button/index.js +156 -0
- package/lib/button/components/text-button/index.js.map +1 -0
- package/lib/button/components/text-button/index.mjs +7 -0
- package/lib/button/components/text-button/index.mjs.map +1 -0
- package/lib/button/constant.d.mts +11 -0
- package/lib/button/constant.d.ts +11 -0
- package/lib/button/constant.js +13 -0
- package/lib/button/constant.js.map +1 -0
- package/lib/button/constant.mjs +3 -0
- package/lib/button/constant.mjs.map +1 -0
- package/lib/button/enum.d.mts +11 -0
- package/lib/button/enum.d.ts +11 -0
- package/lib/button/enum.js +19 -0
- package/lib/button/enum.js.map +1 -0
- package/lib/button/enum.mjs +3 -0
- package/lib/button/enum.mjs.map +1 -0
- package/lib/button/index.d.mts +26 -0
- package/lib/button/index.d.ts +26 -0
- package/lib/button/index.js +162 -0
- package/lib/button/index.js.map +1 -0
- package/lib/button/index.mjs +8 -0
- package/lib/button/index.mjs.map +1 -0
- package/lib/button/stories/text-button.stories.d.mts +55 -0
- package/lib/button/stories/text-button.stories.d.ts +55 -0
- package/lib/button/stories/text-button.stories.js +206 -0
- package/lib/button/stories/text-button.stories.js.map +1 -0
- package/lib/button/stories/text-button.stories.mjs +34 -0
- package/lib/button/stories/text-button.stories.mjs.map +1 -0
- package/lib/{chunk-3B7LTZRJ.mjs → chunk-6DXA3EX7.mjs} +8 -6
- package/lib/chunk-6DXA3EX7.mjs.map +1 -0
- package/lib/chunk-7DK5MO62.mjs +8 -0
- package/lib/chunk-7DK5MO62.mjs.map +1 -0
- package/lib/chunk-CZVB2Y6O.mjs +27 -0
- package/lib/chunk-CZVB2Y6O.mjs.map +1 -0
- package/lib/chunk-GQWO45DN.mjs +32 -0
- package/lib/chunk-GQWO45DN.mjs.map +1 -0
- package/lib/chunk-GRCEZABQ.mjs +38 -0
- package/lib/chunk-GRCEZABQ.mjs.map +1 -0
- package/lib/chunk-JB4TYHDE.mjs +11 -0
- package/lib/chunk-JB4TYHDE.mjs.map +1 -0
- package/lib/chunk-JFT6JILC.mjs +12 -0
- package/lib/chunk-JFT6JILC.mjs.map +1 -0
- package/lib/chunk-QE5LVT7A.mjs +90 -0
- package/lib/chunk-QE5LVT7A.mjs.map +1 -0
- package/lib/chunk-QOLETTSG.mjs +28 -0
- package/lib/chunk-QOLETTSG.mjs.map +1 -0
- package/lib/chunk-R4F4LGAY.mjs +56 -0
- package/lib/chunk-R4F4LGAY.mjs.map +1 -0
- package/lib/chunk-URJXIWFX.mjs +16 -0
- package/lib/chunk-URJXIWFX.mjs.map +1 -0
- package/lib/chunk-X2UWIBNH.mjs +16 -0
- package/lib/chunk-X2UWIBNH.mjs.map +1 -0
- package/lib/chunk-XO7SDD7W.mjs +17 -0
- package/lib/chunk-XO7SDD7W.mjs.map +1 -0
- package/lib/customized-link/external-link.d.mts +7 -0
- package/lib/customized-link/external-link.d.ts +7 -0
- package/lib/customized-link/external-link.js +18 -0
- package/lib/customized-link/external-link.js.map +1 -0
- package/lib/customized-link/external-link.mjs +3 -0
- package/lib/customized-link/external-link.mjs.map +1 -0
- package/lib/customized-link/index.d.mts +11 -0
- package/lib/customized-link/index.d.ts +11 -0
- package/lib/customized-link/index.js +42 -0
- package/lib/customized-link/index.js.map +1 -0
- package/lib/customized-link/index.mjs +5 -0
- package/lib/customized-link/index.mjs.map +1 -0
- package/lib/customized-link/internal-link.d.mts +7 -0
- package/lib/customized-link/internal-link.d.ts +7 -0
- package/lib/customized-link/internal-link.js +22 -0
- package/lib/customized-link/internal-link.js.map +1 -0
- package/lib/customized-link/internal-link.mjs +3 -0
- package/lib/customized-link/internal-link.mjs.map +1 -0
- package/lib/customized-link/type.d.mts +9 -0
- package/lib/customized-link/type.d.ts +9 -0
- package/lib/customized-link/type.js +4 -0
- package/lib/customized-link/type.js.map +1 -0
- package/lib/customized-link/type.mjs +3 -0
- package/lib/customized-link/type.mjs.map +1 -0
- package/lib/storybook/utils/get-enum-arg.d.mts +19 -0
- package/lib/storybook/utils/get-enum-arg.d.ts +19 -0
- package/lib/storybook/utils/get-enum-arg.js +31 -0
- package/lib/storybook/utils/get-enum-arg.js.map +1 -0
- package/lib/storybook/utils/get-enum-arg.mjs +3 -0
- package/lib/storybook/utils/get-enum-arg.mjs.map +1 -0
- package/lib/styles.css +178 -2
- package/lib/styles.css.map +1 -1
- package/lib/text/heading.d.mts +8 -8
- package/lib/text/heading.d.ts +8 -8
- package/lib/text/paragraph.d.mts +6 -6
- package/lib/text/paragraph.d.ts +6 -6
- package/lib/text/stories/heading.stories.d.mts +35 -0
- package/lib/text/stories/heading.stories.d.ts +35 -0
- package/lib/text/stories/heading.stories.js +131 -0
- package/lib/text/stories/heading.stories.js.map +1 -0
- package/lib/text/stories/heading.stories.mjs +50 -0
- package/lib/text/stories/heading.stories.mjs.map +1 -0
- package/lib/text/stories/paragraph.stories.d.mts +33 -0
- package/lib/text/stories/paragraph.stories.d.ts +33 -0
- package/lib/text/stories/paragraph.stories.js +108 -0
- package/lib/text/stories/paragraph.stories.js.map +1 -0
- package/lib/text/stories/paragraph.stories.mjs +40 -0
- package/lib/text/stories/paragraph.stories.mjs.map +1 -0
- package/lib/title-bar/components/title-tab/hook.d.mts +5 -0
- package/lib/title-bar/components/title-tab/hook.d.ts +5 -0
- package/lib/title-bar/components/title-tab/hook.js +34 -0
- package/lib/title-bar/components/title-tab/hook.js.map +1 -0
- package/lib/title-bar/components/title-tab/hook.mjs +3 -0
- package/lib/title-bar/components/title-tab/hook.mjs.map +1 -0
- package/lib/title-bar/components/title-tab/index.d.mts +11 -0
- package/lib/title-bar/components/title-tab/index.d.ts +11 -0
- package/lib/title-bar/components/title-tab/index.js +321 -0
- package/lib/title-bar/components/title-tab/index.js.map +1 -0
- package/lib/title-bar/components/title-tab/index.mjs +15 -0
- package/lib/title-bar/components/title-tab/index.mjs.map +1 -0
- package/lib/title-bar/components/title-tab/tab-item.d.mts +10 -0
- package/lib/title-bar/components/title-tab/tab-item.d.ts +10 -0
- package/lib/title-bar/components/title-tab/tab-item.js +204 -0
- package/lib/title-bar/components/title-tab/tab-item.js.map +1 -0
- package/lib/title-bar/components/title-tab/tab-item.mjs +12 -0
- package/lib/title-bar/components/title-tab/tab-item.mjs.map +1 -0
- package/lib/title-bar/components/title-tab/type.d.mts +8 -0
- package/lib/title-bar/components/title-tab/type.d.ts +8 -0
- package/lib/title-bar/components/title-tab/type.js +4 -0
- package/lib/title-bar/components/title-tab/type.js.map +1 -0
- package/lib/title-bar/components/title-tab/type.mjs +3 -0
- package/lib/title-bar/components/title-tab/type.mjs.map +1 -0
- package/lib/title-bar/components/title1.d.mts +10 -0
- package/lib/title-bar/components/title1.d.ts +10 -0
- package/lib/title-bar/components/title1.js +123 -0
- package/lib/title-bar/components/title1.js.map +1 -0
- package/lib/title-bar/components/title1.mjs +6 -0
- package/lib/title-bar/components/title1.mjs.map +1 -0
- package/lib/title-bar/components/title2.d.mts +3 -3
- package/lib/title-bar/components/title2.d.ts +3 -3
- package/lib/title-bar/components/title2.js +6 -4
- package/lib/title-bar/components/title2.js.map +1 -1
- package/lib/title-bar/components/title2.mjs +1 -1
- package/lib/title-bar/index.d.mts +15 -2
- package/lib/title-bar/index.d.ts +15 -2
- package/lib/title-bar/index.js +250 -8
- package/lib/title-bar/index.js.map +1 -1
- package/lib/title-bar/index.mjs +18 -3
- package/lib/title-bar/index.mjs.map +1 -1
- package/lib/title-bar/stories/title-tab.stories.d.mts +17 -0
- package/lib/title-bar/stories/title-tab.stories.d.ts +17 -0
- package/lib/title-bar/stories/title-tab.stories.js +345 -0
- package/lib/title-bar/stories/title-tab.stories.js.map +1 -0
- package/lib/title-bar/stories/title-tab.stories.mjs +38 -0
- package/lib/title-bar/stories/title-tab.stories.mjs.map +1 -0
- package/lib/title-bar/stories/title1.stories.d.mts +18 -0
- package/lib/title-bar/stories/title1.stories.d.ts +18 -0
- package/lib/title-bar/stories/title1.stories.js +155 -0
- package/lib/title-bar/stories/title1.stories.js.map +1 -0
- package/lib/title-bar/stories/title1.stories.mjs +35 -0
- package/lib/title-bar/stories/title1.stories.mjs.map +1 -0
- package/lib/title-bar/stories/title2.stories.d.mts +18 -0
- package/lib/title-bar/stories/title2.stories.d.ts +18 -0
- package/lib/title-bar/stories/title2.stories.js +258 -0
- package/lib/title-bar/stories/title2.stories.js.map +1 -0
- package/lib/title-bar/stories/title2.stories.mjs +37 -0
- package/lib/title-bar/stories/title2.stories.mjs.map +1 -0
- package/package.json +12 -5
- package/lib/chunk-3B7LTZRJ.mjs.map +0 -1
package/lib/styles.css
CHANGED
|
@@ -7,14 +7,23 @@
|
|
|
7
7
|
"Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
|
|
8
8
|
--font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
|
|
9
9
|
"Courier New", monospace;
|
|
10
|
+
--color-gray-100: #f1f1f1;
|
|
11
|
+
--color-gray-200: #e2e2e2;
|
|
12
|
+
--color-gray-300: #cdcdcd;
|
|
13
|
+
--color-gray-400: #bbbbbb;
|
|
14
|
+
--color-gray-500: #9c9c9c;
|
|
10
15
|
--color-gray-600: #808080;
|
|
11
16
|
--color-gray-800: #404040;
|
|
12
17
|
--spacing: 0.25rem;
|
|
13
18
|
--font-weight-bold: 700;
|
|
14
19
|
--default-font-family: var(--font-sans);
|
|
15
20
|
--default-mono-font-family: var(--font-mono);
|
|
16
|
-
--
|
|
17
|
-
--
|
|
21
|
+
--color-brand-heavy: #c40d23;
|
|
22
|
+
--color-supportive-faded: #f0d5be;
|
|
23
|
+
--color-supportive-pastel: #e3be98;
|
|
24
|
+
--color-gray-white: #ffffff;
|
|
25
|
+
--font-title: "merriweather", "source-han-serif-tc", serif;
|
|
26
|
+
--font-default: "Roboto Slab", "Noto Sans TC", sans-serif, "Tauhu Oo";
|
|
18
27
|
}
|
|
19
28
|
}
|
|
20
29
|
@layer base {
|
|
@@ -163,24 +172,68 @@
|
|
|
163
172
|
}
|
|
164
173
|
}
|
|
165
174
|
@layer utilities {
|
|
175
|
+
.absolute {
|
|
176
|
+
position: absolute;
|
|
177
|
+
}
|
|
178
|
+
.relative {
|
|
179
|
+
position: relative;
|
|
180
|
+
}
|
|
166
181
|
.m-0 {
|
|
167
182
|
margin: calc(var(--spacing) * 0);
|
|
168
183
|
}
|
|
184
|
+
.mt-\[0px\] {
|
|
185
|
+
margin-top: 0px;
|
|
186
|
+
}
|
|
169
187
|
.mt-\[8px\] {
|
|
170
188
|
margin-top: 8px;
|
|
171
189
|
}
|
|
190
|
+
.mr-\[4px\] {
|
|
191
|
+
margin-right: 4px;
|
|
192
|
+
}
|
|
193
|
+
.mr-\[24px\] {
|
|
194
|
+
margin-right: 24px;
|
|
195
|
+
}
|
|
196
|
+
.ml-\[4px\] {
|
|
197
|
+
margin-left: 4px;
|
|
198
|
+
}
|
|
199
|
+
.box-border {
|
|
200
|
+
box-sizing: border-box;
|
|
201
|
+
}
|
|
172
202
|
.flex {
|
|
173
203
|
display: flex;
|
|
174
204
|
}
|
|
205
|
+
.inline-block {
|
|
206
|
+
display: inline-block;
|
|
207
|
+
}
|
|
208
|
+
.size-\[18px\] {
|
|
209
|
+
width: 18px;
|
|
210
|
+
height: 18px;
|
|
211
|
+
}
|
|
212
|
+
.size-\[24px\] {
|
|
213
|
+
width: 24px;
|
|
214
|
+
height: 24px;
|
|
215
|
+
}
|
|
175
216
|
.h-\[1px\] {
|
|
176
217
|
height: 1px;
|
|
177
218
|
}
|
|
178
219
|
.w-full {
|
|
179
220
|
width: 100%;
|
|
180
221
|
}
|
|
222
|
+
.shrink-0 {
|
|
223
|
+
flex-shrink: 0;
|
|
224
|
+
}
|
|
225
|
+
.cursor-default {
|
|
226
|
+
cursor: default;
|
|
227
|
+
}
|
|
228
|
+
.cursor-pointer {
|
|
229
|
+
cursor: pointer;
|
|
230
|
+
}
|
|
181
231
|
.flex-col {
|
|
182
232
|
flex-direction: column;
|
|
183
233
|
}
|
|
234
|
+
.flex-row {
|
|
235
|
+
flex-direction: row;
|
|
236
|
+
}
|
|
184
237
|
.items-baseline {
|
|
185
238
|
align-items: baseline;
|
|
186
239
|
}
|
|
@@ -190,12 +243,44 @@
|
|
|
190
243
|
.justify-between {
|
|
191
244
|
justify-content: space-between;
|
|
192
245
|
}
|
|
246
|
+
.justify-center {
|
|
247
|
+
justify-content: center;
|
|
248
|
+
}
|
|
193
249
|
.gap-\[16px\] {
|
|
194
250
|
gap: 16px;
|
|
195
251
|
}
|
|
252
|
+
.overflow-x-scroll {
|
|
253
|
+
overflow-x: scroll;
|
|
254
|
+
}
|
|
255
|
+
.rounded-\[50\%\] {
|
|
256
|
+
border-radius: 50%;
|
|
257
|
+
}
|
|
258
|
+
.border-2 {
|
|
259
|
+
border-style: var(--tw-border-style);
|
|
260
|
+
border-width: 2px;
|
|
261
|
+
}
|
|
262
|
+
.border-solid {
|
|
263
|
+
--tw-border-style: solid;
|
|
264
|
+
border-style: solid;
|
|
265
|
+
}
|
|
266
|
+
.border-gray-400 {
|
|
267
|
+
border-color: var(--color-gray-400);
|
|
268
|
+
}
|
|
269
|
+
.border-t-gray-600 {
|
|
270
|
+
border-top-color: var(--color-gray-600);
|
|
271
|
+
}
|
|
272
|
+
.bg-gray-300 {
|
|
273
|
+
background-color: var(--color-gray-300);
|
|
274
|
+
}
|
|
196
275
|
.bg-gray-800 {
|
|
197
276
|
background-color: var(--color-gray-800);
|
|
198
277
|
}
|
|
278
|
+
.\[mask-image\:linear-gradient\(to_left\,rgba\(241\,241\,241\,0\)\,\#f1f1f1_48px\)\] {
|
|
279
|
+
mask-image: linear-gradient(to left,rgba(241,241,241,0),#f1f1f1 48px);
|
|
280
|
+
}
|
|
281
|
+
.py-\[16px\] {
|
|
282
|
+
padding-block: 16px;
|
|
283
|
+
}
|
|
199
284
|
.font-default {
|
|
200
285
|
font-family: var(--font-default);
|
|
201
286
|
}
|
|
@@ -241,12 +326,92 @@
|
|
|
241
326
|
--tw-font-weight: var(--font-weight-bold);
|
|
242
327
|
font-weight: var(--font-weight-bold);
|
|
243
328
|
}
|
|
329
|
+
.text-brand-heavy {
|
|
330
|
+
color: var(--color-brand-heavy);
|
|
331
|
+
}
|
|
332
|
+
.text-gray-100 {
|
|
333
|
+
color: var(--color-gray-100);
|
|
334
|
+
}
|
|
335
|
+
.text-gray-200 {
|
|
336
|
+
color: var(--color-gray-200);
|
|
337
|
+
}
|
|
338
|
+
.text-gray-300 {
|
|
339
|
+
color: var(--color-gray-300);
|
|
340
|
+
}
|
|
341
|
+
.text-gray-400 {
|
|
342
|
+
color: var(--color-gray-400);
|
|
343
|
+
}
|
|
344
|
+
.text-gray-500 {
|
|
345
|
+
color: var(--color-gray-500);
|
|
346
|
+
}
|
|
244
347
|
.text-gray-600 {
|
|
245
348
|
color: var(--color-gray-600);
|
|
246
349
|
}
|
|
247
350
|
.text-gray-800 {
|
|
248
351
|
color: var(--color-gray-800);
|
|
249
352
|
}
|
|
353
|
+
.text-gray-white {
|
|
354
|
+
color: var(--color-gray-white);
|
|
355
|
+
}
|
|
356
|
+
.text-supportive-faded {
|
|
357
|
+
color: var(--color-supportive-faded);
|
|
358
|
+
}
|
|
359
|
+
.opacity-0 {
|
|
360
|
+
opacity: 0%;
|
|
361
|
+
}
|
|
362
|
+
.opacity-100 {
|
|
363
|
+
opacity: 100%;
|
|
364
|
+
}
|
|
365
|
+
.\[-webkit-mask-image\:linear-gradient\(to_left\,rgba\(241\,241\,241\,0\)\,\#f1f1f1_48px\)\] {
|
|
366
|
+
-webkit-mask-image: linear-gradient(to left,rgba(241,241,241,0),#f1f1f1 48px);
|
|
367
|
+
}
|
|
368
|
+
.last\:mr-0 {
|
|
369
|
+
&:last-child {
|
|
370
|
+
margin-right: calc(var(--spacing) * 0);
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
.hover\:text-brand-heavy {
|
|
374
|
+
&:hover {
|
|
375
|
+
@media (hover: hover) {
|
|
376
|
+
color: var(--color-brand-heavy);
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
}
|
|
380
|
+
.hover\:text-gray-200 {
|
|
381
|
+
&:hover {
|
|
382
|
+
@media (hover: hover) {
|
|
383
|
+
color: var(--color-gray-200);
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
.hover\:text-gray-400 {
|
|
388
|
+
&:hover {
|
|
389
|
+
@media (hover: hover) {
|
|
390
|
+
color: var(--color-gray-400);
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
.hover\:text-gray-500 {
|
|
395
|
+
&:hover {
|
|
396
|
+
@media (hover: hover) {
|
|
397
|
+
color: var(--color-gray-500);
|
|
398
|
+
}
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
.hover\:text-gray-white {
|
|
402
|
+
&:hover {
|
|
403
|
+
@media (hover: hover) {
|
|
404
|
+
color: var(--color-gray-white);
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
.hover\:text-supportive-pastel {
|
|
409
|
+
&:hover {
|
|
410
|
+
@media (hover: hover) {
|
|
411
|
+
color: var(--color-supportive-pastel);
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
}
|
|
250
415
|
.tablet\:text-\[16px\] {
|
|
251
416
|
@media (width >= 768px) {
|
|
252
417
|
font-size: 16px;
|
|
@@ -277,12 +442,22 @@
|
|
|
277
442
|
font-size: 36px;
|
|
278
443
|
}
|
|
279
444
|
}
|
|
445
|
+
.desktop\:mt-\[0px\] {
|
|
446
|
+
@media (width >= 1024px) {
|
|
447
|
+
margin-top: 0px;
|
|
448
|
+
}
|
|
449
|
+
}
|
|
280
450
|
.desktop\:mt-\[16px\] {
|
|
281
451
|
@media (width >= 1024px) {
|
|
282
452
|
margin-top: 16px;
|
|
283
453
|
}
|
|
284
454
|
}
|
|
285
455
|
}
|
|
456
|
+
@property --tw-border-style {
|
|
457
|
+
syntax: "*";
|
|
458
|
+
inherits: false;
|
|
459
|
+
initial-value: solid;
|
|
460
|
+
}
|
|
286
461
|
@property --tw-leading {
|
|
287
462
|
syntax: "*";
|
|
288
463
|
inherits: false;
|
|
@@ -294,6 +469,7 @@
|
|
|
294
469
|
@layer properties {
|
|
295
470
|
@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {
|
|
296
471
|
*, ::before, ::after, ::backdrop {
|
|
472
|
+
--tw-border-style: solid;
|
|
297
473
|
--tw-leading: initial;
|
|
298
474
|
--tw-font-weight: initial;
|
|
299
475
|
}
|
package/lib/styles.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../tailwind-config/shared-styles.css"],"sourcesContent":["@import 'tailwindcss';\n\n@theme {\n /* Brand */\n --color-brand-faded: #f4c6c6;\n --color-brand-pastel: #f76977;\n --color-brand-main: #f80b28;\n --color-brand-heavy: #c40d23;\n --color-brand-dark: #9b051e;\n\n /* Photography */\n --color-photo-faded: #abdef4;\n --color-photo-pastel: #6d9be0;\n --color-photo-main: #2f58cc;\n --color-photo-heavy: #143071;\n --color-photo-dark: #052142;\n\n /* Podcast */\n --color-podcast-faded: #c4f2dc;\n --color-podcast-pastel: #99ecc9;\n --color-podcast-main: #6ee5b5;\n --color-podcast-heavy: #3c927a;\n --color-podcast-dark: #0e3532;\n\n /* Supportive */\n --color-supportive-faded: #f0d5be;\n --color-supportive-pastel: #e3be98;\n --color-supportive-main: #c09662;\n --color-supportive-heavy: #9f7544;\n --color-supportive-dark: #7a522c;\n\n /* Grayscale */\n --color-gray-white: #ffffff;\n --color-gray-100: #f1f1f1;\n --color-gray-200: #e2e2e2;\n --color-gray-300: #cdcdcd;\n --color-gray-400: #bbbbbb;\n --color-gray-500: #9c9c9c;\n --color-gray-600: #808080;\n --color-gray-700: #666666;\n --color-gray-800: #404040;\n --color-gray-900: #262626;\n --color-gray-black: #000000;\n\n /* Opacity colors */\n --color-opacity-white-0: rgba(255, 255, 255, 0.0);\n --color-opacity-white-02: rgba(255, 255, 255, 0.2);\n --color-opacity-white-05: rgba(255, 255, 255, 0.5);\n --color-opacity-white-08: rgba(255, 255, 255, 0.8);\n --color-opacity-white-09: rgba(255, 255, 255, 0.9);\n --color-opacity-gray100-08: rgba(241, 241, 241, 0.8);\n --color-opacity-black-01: rgba(0, 0, 0, 0.1);\n --color-opacity-black-02: rgba(0, 0, 0, 0.2);\n --color-opacity-black-05: rgba(0, 0, 0, 0.5);\n --color-opacity-black-07: rgba(0, 0, 0, 0.7);\n --color-opacity-black-08: rgba(0, 0, 0, 0.8);\n --color-opacity-black-005: rgba(0, 0, 0, 0.05);\n\n /* Semantic */\n --color-semantic-danger: #c7000a;\n --color-semantic-success: #4db41d;\n --color-semantic-info: #1a7aeb;\n --color-semantic-warning: #fcaa0c;\n\n /* Pink Article */\n --color-pink-article-light-blue: #2440fb;\n --color-pink-article-blue: #355ed3;\n --color-pink-article-dark-blue: #08192d;\n --color-pink-article-light-pink: #fadaf5;\n --color-pink-article-pink: #fbafef;\n --color-pink-article-dark-pink: #ef7ede;\n\n /* Font families */\n --font-title: 'merriweather', 'source-han-serif-tc', serif;\n --font-default: 'Roboto Slab', 'Noto Sans TC', sans-serif, 'Tauhu Oo';\n --font-default-fallback: 'Roboto Slab', sans-serif;\n\n /* Font weights */\n --font-weight-extra-light: 100;\n --font-weight-normal: 400;\n --font-weight-bold: 700;\n\n /* Screen breakpoint */\n --breakpoint-tablet: 768px;\n --breakpoint-desktop: 1024px;\n --breakpoint-hd: 1440px;\n}\n"],"mappings":";;;AAEA,OAAO,EAEL,mBAAmB,EAAE,OAAO,EAC5B,oBAAoB,EAAE,OAAO,EAC7B,kBAAkB,EAAE,OAAO,EAC3B,mBAAmB,EAAE,OAAO,EAC5B,kBAAkB,EAAE,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AAC,EAAE,CAAC,EAAE,IAAI,EAC5C,wBAAwB,EAAE,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,IAAI,EAC5C,wBAAwB,EAAE,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,IAAI,EAC5C,wBAAwB,EAAE,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,IAAI,EAC5C,yBAAyB,EAAE,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,KAAK,EAG9C,uBAAuB,EAAE,OAAO,EAChC,wBAAwB,EAAE,OAAO,EACjC,qBAAqB,EAAE,OAAO,EAC9B,wBAAwB,EAAE,OAAO,EAGjC,+BAA+B,EAAE,OAAO,EACxC,yBAAyB,EAAE,OAAO,EAClC,8BAA8B,EAAE,OAAO,EACvC,+BAA+B,EAAE,OAAO,EACxC,yBAAyB,EAAE,OAAO,EAClC,8BAA8B,EAAE,OAAO,EAGvC,YAAY,EAAE,cAAc,EAAE,qBAAqB,EAAE,KAAK,EAC1D,cAAc,EAAE,aAAa,EAAE,cAAc,EAAE,UAAU,EAAE,UAAU,EACrE,uBAAuB,EAAE,aAAa,EAAE,UAAU,EAGlD,yBAAyB,EAAE,GAAG,EAC9B,oBAAoB,EAAE,GAAG,EACzB,kBAAkB,EAAE,GAAG,EAGvB,mBAAmB,EAAE,KAAK,EAC1B,oBAAoB,EAAE,MAAM,EAC5B,eAAe,EAAE,MAAM;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/styles.css"],"sourcesContent":["/*! tailwindcss v4.1.11 | MIT License | https://tailwindcss.com */\n@layer properties;\n@layer theme, base, components, utilities;\n@layer theme {\n :root, :host {\n --font-sans: ui-sans-serif, system-ui, sans-serif, \"Apple Color Emoji\",\n \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";\n --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, \"Liberation Mono\",\n \"Courier New\", monospace;\n --color-gray-100: #f1f1f1;\n --color-gray-200: #e2e2e2;\n --color-gray-300: #cdcdcd;\n --color-gray-400: #bbbbbb;\n --color-gray-500: #9c9c9c;\n --color-gray-600: #808080;\n --color-gray-800: #404040;\n --spacing: 0.25rem;\n --font-weight-bold: 700;\n --default-font-family: var(--font-sans);\n --default-mono-font-family: var(--font-mono);\n --color-brand-heavy: #c40d23;\n --color-supportive-faded: #f0d5be;\n --color-supportive-pastel: #e3be98;\n --color-gray-white: #ffffff;\n --font-title: \"merriweather\", \"source-han-serif-tc\", serif;\n --font-default: \"Roboto Slab\", \"Noto Sans TC\", sans-serif, \"Tauhu Oo\";\n }\n}\n@layer base {\n *, ::after, ::before, ::backdrop, ::file-selector-button {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n border: 0 solid;\n }\n html, :host {\n line-height: 1.5;\n -webkit-text-size-adjust: 100%;\n -moz-tab-size: 4;\n -o-tab-size: 4;\n tab-size: 4;\n font-family: var(--default-font-family, ui-sans-serif, system-ui, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\");\n font-feature-settings: var(--default-font-feature-settings, normal);\n font-variation-settings: var(--default-font-variation-settings, normal);\n -webkit-tap-highlight-color: transparent;\n }\n hr {\n height: 0;\n color: inherit;\n border-top-width: 1px;\n }\n abbr:where([title]) {\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted;\n }\n h1, h2, h3, h4, h5, h6 {\n font-size: inherit;\n font-weight: inherit;\n }\n a {\n color: inherit;\n -webkit-text-decoration: inherit;\n text-decoration: inherit;\n }\n b, strong {\n font-weight: bolder;\n }\n code, kbd, samp, pre {\n font-family: var(--default-mono-font-family, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace);\n font-feature-settings: var(--default-mono-font-feature-settings, normal);\n font-variation-settings: var(--default-mono-font-variation-settings, normal);\n font-size: 1em;\n }\n small {\n font-size: 80%;\n }\n sub, sup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n }\n sub {\n bottom: -0.25em;\n }\n sup {\n top: -0.5em;\n }\n table {\n text-indent: 0;\n border-color: inherit;\n border-collapse: collapse;\n }\n :-moz-focusring {\n outline: auto;\n }\n progress {\n vertical-align: baseline;\n }\n summary {\n display: list-item;\n }\n ol, ul, menu {\n list-style: none;\n }\n img, svg, video, canvas, audio, iframe, embed, object {\n display: block;\n vertical-align: middle;\n }\n img, video {\n max-width: 100%;\n height: auto;\n }\n button, input, select, optgroup, textarea, ::file-selector-button {\n font: inherit;\n font-feature-settings: inherit;\n font-variation-settings: inherit;\n letter-spacing: inherit;\n color: inherit;\n border-radius: 0;\n background-color: transparent;\n opacity: 1;\n }\n :where(select:is([multiple], [size])) optgroup {\n font-weight: bolder;\n }\n :where(select:is([multiple], [size])) optgroup option {\n padding-inline-start: 20px;\n }\n ::file-selector-button {\n margin-inline-end: 4px;\n }\n ::-moz-placeholder {\n opacity: 1;\n }\n ::placeholder {\n opacity: 1;\n }\n @supports (not (-webkit-appearance: -apple-pay-button)) or (contain-intrinsic-size: 1px) {\n ::-moz-placeholder {\n color: currentcolor;\n @supports (color: color-mix(in lab, red, red)) {\n color: color-mix(in oklab, currentcolor 50%, transparent);\n }\n }\n ::placeholder {\n color: currentcolor;\n @supports (color: color-mix(in lab, red, red)) {\n color: color-mix(in oklab, currentcolor 50%, transparent);\n }\n }\n }\n textarea {\n resize: vertical;\n }\n ::-webkit-search-decoration {\n -webkit-appearance: none;\n }\n ::-webkit-date-and-time-value {\n min-height: 1lh;\n text-align: inherit;\n }\n ::-webkit-datetime-edit {\n display: inline-flex;\n }\n ::-webkit-datetime-edit-fields-wrapper {\n padding: 0;\n }\n ::-webkit-datetime-edit, ::-webkit-datetime-edit-year-field, ::-webkit-datetime-edit-month-field, ::-webkit-datetime-edit-day-field, ::-webkit-datetime-edit-hour-field, ::-webkit-datetime-edit-minute-field, ::-webkit-datetime-edit-second-field, ::-webkit-datetime-edit-millisecond-field, ::-webkit-datetime-edit-meridiem-field {\n padding-block: 0;\n }\n :-moz-ui-invalid {\n box-shadow: none;\n }\n button, input:where([type=\"button\"], [type=\"reset\"], [type=\"submit\"]), ::file-selector-button {\n -webkit-appearance: button;\n -moz-appearance: button;\n appearance: button;\n }\n ::-webkit-inner-spin-button, ::-webkit-outer-spin-button {\n height: auto;\n }\n [hidden]:where(:not([hidden=\"until-found\"])) {\n display: none !important;\n }\n}\n@layer utilities {\n .absolute {\n position: absolute;\n }\n .relative {\n position: relative;\n }\n .m-0 {\n margin: calc(var(--spacing) * 0);\n }\n .mt-\\[0px\\] {\n margin-top: 0px;\n }\n .mt-\\[8px\\] {\n margin-top: 8px;\n }\n .mr-\\[4px\\] {\n margin-right: 4px;\n }\n .mr-\\[24px\\] {\n margin-right: 24px;\n }\n .ml-\\[4px\\] {\n margin-left: 4px;\n }\n .box-border {\n box-sizing: border-box;\n }\n .flex {\n display: flex;\n }\n .inline-block {\n display: inline-block;\n }\n .size-\\[18px\\] {\n width: 18px;\n height: 18px;\n }\n .size-\\[24px\\] {\n width: 24px;\n height: 24px;\n }\n .h-\\[1px\\] {\n height: 1px;\n }\n .w-full {\n width: 100%;\n }\n .shrink-0 {\n flex-shrink: 0;\n }\n .cursor-default {\n cursor: default;\n }\n .cursor-pointer {\n cursor: pointer;\n }\n .flex-col {\n flex-direction: column;\n }\n .flex-row {\n flex-direction: row;\n }\n .items-baseline {\n align-items: baseline;\n }\n .items-center {\n align-items: center;\n }\n .justify-between {\n justify-content: space-between;\n }\n .justify-center {\n justify-content: center;\n }\n .gap-\\[16px\\] {\n gap: 16px;\n }\n .overflow-x-scroll {\n overflow-x: scroll;\n }\n .rounded-\\[50\\%\\] {\n border-radius: 50%;\n }\n .border-2 {\n border-style: var(--tw-border-style);\n border-width: 2px;\n }\n .border-solid {\n --tw-border-style: solid;\n border-style: solid;\n }\n .border-gray-400 {\n border-color: var(--color-gray-400);\n }\n .border-t-gray-600 {\n border-top-color: var(--color-gray-600);\n }\n .bg-gray-300 {\n background-color: var(--color-gray-300);\n }\n .bg-gray-800 {\n background-color: var(--color-gray-800);\n }\n .\\[mask-image\\:linear-gradient\\(to_left\\,rgba\\(241\\,241\\,241\\,0\\)\\,\\#f1f1f1_48px\\)\\] {\n -webkit-mask-image: linear-gradient(to left,rgba(241,241,241,0),#f1f1f1 48px);\n mask-image: linear-gradient(to left,rgba(241,241,241,0),#f1f1f1 48px);\n }\n .py-\\[16px\\] {\n padding-block: 16px;\n }\n .font-default {\n font-family: var(--font-default);\n }\n .font-title {\n font-family: var(--font-title);\n }\n .text-\\[10px\\] {\n font-size: 10px;\n }\n .text-\\[12px\\] {\n font-size: 12px;\n }\n .text-\\[14px\\] {\n font-size: 14px;\n }\n .text-\\[16px\\] {\n font-size: 16px;\n }\n .text-\\[17px\\] {\n font-size: 17px;\n }\n .text-\\[18px\\] {\n font-size: 18px;\n }\n .text-\\[22px\\] {\n font-size: 22px;\n }\n .text-\\[24px\\] {\n font-size: 24px;\n }\n .text-\\[28px\\] {\n font-size: 28px;\n }\n .leading-\\[125\\%\\] {\n --tw-leading: 125%;\n line-height: 125%;\n }\n .leading-\\[150\\%\\] {\n --tw-leading: 150%;\n line-height: 150%;\n }\n .font-bold {\n --tw-font-weight: var(--font-weight-bold);\n font-weight: var(--font-weight-bold);\n }\n .text-brand-heavy {\n color: var(--color-brand-heavy);\n }\n .text-gray-100 {\n color: var(--color-gray-100);\n }\n .text-gray-200 {\n color: var(--color-gray-200);\n }\n .text-gray-300 {\n color: var(--color-gray-300);\n }\n .text-gray-400 {\n color: var(--color-gray-400);\n }\n .text-gray-500 {\n color: var(--color-gray-500);\n }\n .text-gray-600 {\n color: var(--color-gray-600);\n }\n .text-gray-800 {\n color: var(--color-gray-800);\n }\n .text-gray-white {\n color: var(--color-gray-white);\n }\n .text-supportive-faded {\n color: var(--color-supportive-faded);\n }\n .opacity-0 {\n opacity: 0%;\n }\n .opacity-100 {\n opacity: 100%;\n }\n .\\[-webkit-mask-image\\:linear-gradient\\(to_left\\,rgba\\(241\\,241\\,241\\,0\\)\\,\\#f1f1f1_48px\\)\\] {\n -webkit-mask-image: linear-gradient(to left,rgba(241,241,241,0),#f1f1f1 48px);\n }\n .last\\:mr-0 {\n &:last-child {\n margin-right: calc(var(--spacing) * 0);\n }\n }\n .hover\\:text-brand-heavy {\n &:hover {\n @media (hover: hover) {\n color: var(--color-brand-heavy);\n }\n }\n }\n .hover\\:text-gray-200 {\n &:hover {\n @media (hover: hover) {\n color: var(--color-gray-200);\n }\n }\n }\n .hover\\:text-gray-400 {\n &:hover {\n @media (hover: hover) {\n color: var(--color-gray-400);\n }\n }\n }\n .hover\\:text-gray-500 {\n &:hover {\n @media (hover: hover) {\n color: var(--color-gray-500);\n }\n }\n }\n .hover\\:text-gray-white {\n &:hover {\n @media (hover: hover) {\n color: var(--color-gray-white);\n }\n }\n }\n .hover\\:text-supportive-pastel {\n &:hover {\n @media (hover: hover) {\n color: var(--color-supportive-pastel);\n }\n }\n }\n .tablet\\:text-\\[16px\\] {\n @media (width >= 768px) {\n font-size: 16px;\n }\n }\n .tablet\\:text-\\[18px\\] {\n @media (width >= 768px) {\n font-size: 18px;\n }\n }\n .tablet\\:text-\\[22px\\] {\n @media (width >= 768px) {\n font-size: 22px;\n }\n }\n .tablet\\:text-\\[28px\\] {\n @media (width >= 768px) {\n font-size: 28px;\n }\n }\n .tablet\\:text-\\[32px\\] {\n @media (width >= 768px) {\n font-size: 32px;\n }\n }\n .tablet\\:text-\\[36px\\] {\n @media (width >= 768px) {\n font-size: 36px;\n }\n }\n .desktop\\:mt-\\[0px\\] {\n @media (width >= 1024px) {\n margin-top: 0px;\n }\n }\n .desktop\\:mt-\\[16px\\] {\n @media (width >= 1024px) {\n margin-top: 16px;\n }\n }\n}\n@property --tw-border-style {\n syntax: \"*\";\n inherits: false;\n initial-value: solid;\n}\n@property --tw-leading {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-font-weight {\n syntax: \"*\";\n inherits: false;\n}\n@layer properties {\n @supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {\n *, ::before, ::after, ::backdrop {\n --tw-border-style: solid;\n --tw-leading: initial;\n --tw-font-weight: initial;\n }\n }\n}\n"],"mappings":";AACA;AACA;AACA;AACE;AAAA,EAAO;AACL;AAAA,MAAa,aAAa;AAAA,MAAE,SAAS;AAAA,MAAE,UAAU;AAAA,MAAE,mBAAmB;AAAA,MACpE,gBAAgB;AAAA,MAAE,iBAAiB;AAAA,MAAE;AACvC;AAAA,MAAa,YAAY;AAAA,MAAE,cAAc;AAAA,MAAE,KAAK;AAAA,MAAE,MAAM;AAAA,MAAE,QAAQ;AAAA,MAAE,iBAAiB;AAAA,MACnF,aAAa;AAAA,MAAE;AACjB,sBAAkB;AAClB,sBAAkB;AAClB,sBAAkB;AAClB,sBAAkB;AAClB,sBAAkB;AAClB,sBAAkB;AAClB,sBAAkB;AAClB,eAAW;AACX,wBAAoB;AACpB,2BAAuB,IAAI;AAC3B,gCAA4B,IAAI;AAChC,yBAAqB;AACrB,8BAA0B;AAC1B,+BAA2B;AAC3B,wBAAoB;AACpB;AAAA,MAAc,cAAc;AAAA,MAAE,qBAAqB;AAAA,MAAE;AACrD;AAAA,MAAgB,aAAa;AAAA,MAAE,cAAc;AAAA,MAAE,UAAU;AAAA,MAAE;AAC7D;AACF;AACA;AACE;AAAA,EAAG;AAAA,EAAS;AAAA,EAAU;AAAA,EAAY;AAChC,gBAAY;AACZ,YAAQ;AACR,aAAS;AACT,YAAQ,EAAE;AACZ;AACA;AAAA,EAAM;AACJ,iBAAa;AACb,8BAA0B;AAC1B,mBAAe;AACb,iBAAa;AACV,cAAU;AACf,iBAAa,IAAI,qBAAqB,EAAE,aAAa,EAAE,SAAS,EAAE,UAAU,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,iBAAiB,EAAE;AACxI,2BAAuB,IAAI,+BAA+B,EAAE;AAC5D,6BAAyB,IAAI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ACnB;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,eAAW;AACb;AACA,GAAC;AACC,kBAAc;AACd,iBAAa;AACf;AACA,GAAC;AACC,kBAAc;AACd,iBAAa;AACf;AACA,GAAC;AACC,sBAAkB,IAAI;AACtB,iBAAa,IAAI;AACnB;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,WAAO,IAAI;AACb;AACA,GAAC;AACC,aAAS;AACX;AACA,GAAC;AACC,aAAS;AACX;AACA,GAAC;AACC;AAAA,MAAoB;AAAA,QAAgB,GAAG,IAAI;AAAA,QAAC,KAAK,GAAG,EAAC,GAAG,EAAC,GAAG,EAAC,EAAE;AAAA,QAAC,QAAQ;AAC1E;AACA,GAAC;AACC,KAAC;AACC,oBAAc,KAAK,IAAI,WAAW,EAAE;AACtC;AACF;AACA,GAAC;AACC,KAAC;AACC,aAAO,CAAC,KAAK,EAAE;AACb,eAAO,IAAI;AACb;AACF;AACF;AACA,GAAC;AACC,KAAC;AACC,aAAO,CAAC,KAAK,EAAE;AACb,eAAO,IAAI;AACb;AACF;AACF;AACA,GAAC;AACC,KAAC;AACC,aAAO,CAAC,KAAK,EAAE;AACb,eAAO,IAAI;AACb;AACF;AACF;AACA,GAAC;AACC,KAAC;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;AACpB,yBAAmB;AACnB,oBAAc;AACd,wBAAkB;AACpB;AACF;AACF;","names":[]}
|
package/lib/text/heading.d.mts
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import
|
|
1
|
+
import react__default from 'react';
|
|
2
2
|
import { Type, TYPE } from './enum/index.mjs';
|
|
3
3
|
import '../types/index.mjs';
|
|
4
4
|
|
|
5
|
-
type HeadingProps =
|
|
5
|
+
type HeadingProps = react__default.HTMLAttributes<HTMLHeadingElement> & {
|
|
6
6
|
text?: string;
|
|
7
7
|
type?: Type;
|
|
8
8
|
className?: string;
|
|
9
9
|
};
|
|
10
|
-
declare const H1:
|
|
10
|
+
declare const H1: react__default.FC<HeadingProps> & {
|
|
11
11
|
Type: typeof TYPE;
|
|
12
12
|
};
|
|
13
|
-
declare const H2:
|
|
13
|
+
declare const H2: react__default.FC<HeadingProps> & {
|
|
14
14
|
Type: typeof TYPE;
|
|
15
15
|
};
|
|
16
|
-
declare const H3:
|
|
16
|
+
declare const H3: react__default.FC<HeadingProps> & {
|
|
17
17
|
Type: typeof TYPE;
|
|
18
18
|
};
|
|
19
|
-
declare const H4:
|
|
19
|
+
declare const H4: react__default.FC<HeadingProps> & {
|
|
20
20
|
Type: typeof TYPE;
|
|
21
21
|
};
|
|
22
|
-
declare const H5:
|
|
22
|
+
declare const H5: react__default.FC<HeadingProps> & {
|
|
23
23
|
Type: typeof TYPE;
|
|
24
24
|
};
|
|
25
|
-
declare const H6:
|
|
25
|
+
declare const H6: react__default.FC<HeadingProps> & {
|
|
26
26
|
Type: typeof TYPE;
|
|
27
27
|
};
|
|
28
28
|
|
package/lib/text/heading.d.ts
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import
|
|
1
|
+
import react__default from 'react';
|
|
2
2
|
import { Type, TYPE } from './enum/index.js';
|
|
3
3
|
import '../types/index.js';
|
|
4
4
|
|
|
5
|
-
type HeadingProps =
|
|
5
|
+
type HeadingProps = react__default.HTMLAttributes<HTMLHeadingElement> & {
|
|
6
6
|
text?: string;
|
|
7
7
|
type?: Type;
|
|
8
8
|
className?: string;
|
|
9
9
|
};
|
|
10
|
-
declare const H1:
|
|
10
|
+
declare const H1: react__default.FC<HeadingProps> & {
|
|
11
11
|
Type: typeof TYPE;
|
|
12
12
|
};
|
|
13
|
-
declare const H2:
|
|
13
|
+
declare const H2: react__default.FC<HeadingProps> & {
|
|
14
14
|
Type: typeof TYPE;
|
|
15
15
|
};
|
|
16
|
-
declare const H3:
|
|
16
|
+
declare const H3: react__default.FC<HeadingProps> & {
|
|
17
17
|
Type: typeof TYPE;
|
|
18
18
|
};
|
|
19
|
-
declare const H4:
|
|
19
|
+
declare const H4: react__default.FC<HeadingProps> & {
|
|
20
20
|
Type: typeof TYPE;
|
|
21
21
|
};
|
|
22
|
-
declare const H5:
|
|
22
|
+
declare const H5: react__default.FC<HeadingProps> & {
|
|
23
23
|
Type: typeof TYPE;
|
|
24
24
|
};
|
|
25
|
-
declare const H6:
|
|
25
|
+
declare const H6: react__default.FC<HeadingProps> & {
|
|
26
26
|
Type: typeof TYPE;
|
|
27
27
|
};
|
|
28
28
|
|
package/lib/text/paragraph.d.mts
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import
|
|
1
|
+
import react__default from 'react';
|
|
2
2
|
import { Weight, WEIGHT } from './enum/index.mjs';
|
|
3
3
|
import '../types/index.mjs';
|
|
4
4
|
|
|
5
|
-
type ParagraphProps =
|
|
5
|
+
type ParagraphProps = react__default.HTMLAttributes<HTMLParagraphElement> & {
|
|
6
6
|
text?: string;
|
|
7
7
|
weight?: Weight;
|
|
8
8
|
className?: string;
|
|
9
9
|
};
|
|
10
|
-
declare const P1:
|
|
10
|
+
declare const P1: react__default.FC<ParagraphProps> & {
|
|
11
11
|
Weight: typeof WEIGHT;
|
|
12
12
|
};
|
|
13
|
-
declare const P2:
|
|
13
|
+
declare const P2: react__default.FC<ParagraphProps> & {
|
|
14
14
|
Weight: typeof WEIGHT;
|
|
15
15
|
};
|
|
16
|
-
declare const P3:
|
|
16
|
+
declare const P3: react__default.FC<ParagraphProps> & {
|
|
17
17
|
Weight: typeof WEIGHT;
|
|
18
18
|
};
|
|
19
|
-
declare const P4:
|
|
19
|
+
declare const P4: react__default.FC<ParagraphProps> & {
|
|
20
20
|
Weight: typeof WEIGHT;
|
|
21
21
|
};
|
|
22
22
|
|
package/lib/text/paragraph.d.ts
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import
|
|
1
|
+
import react__default from 'react';
|
|
2
2
|
import { Weight, WEIGHT } from './enum/index.js';
|
|
3
3
|
import '../types/index.js';
|
|
4
4
|
|
|
5
|
-
type ParagraphProps =
|
|
5
|
+
type ParagraphProps = react__default.HTMLAttributes<HTMLParagraphElement> & {
|
|
6
6
|
text?: string;
|
|
7
7
|
weight?: Weight;
|
|
8
8
|
className?: string;
|
|
9
9
|
};
|
|
10
|
-
declare const P1:
|
|
10
|
+
declare const P1: react__default.FC<ParagraphProps> & {
|
|
11
11
|
Weight: typeof WEIGHT;
|
|
12
12
|
};
|
|
13
|
-
declare const P2:
|
|
13
|
+
declare const P2: react__default.FC<ParagraphProps> & {
|
|
14
14
|
Weight: typeof WEIGHT;
|
|
15
15
|
};
|
|
16
|
-
declare const P3:
|
|
16
|
+
declare const P3: react__default.FC<ParagraphProps> & {
|
|
17
17
|
Weight: typeof WEIGHT;
|
|
18
18
|
};
|
|
19
|
-
declare const P4:
|
|
19
|
+
declare const P4: react__default.FC<ParagraphProps> & {
|
|
20
20
|
Weight: typeof WEIGHT;
|
|
21
21
|
};
|
|
22
22
|
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { Type, TYPE } from '../enum/index.mjs';
|
|
2
|
+
import * as react from 'react';
|
|
3
|
+
import { StoryObj } from '@storybook/react-vite';
|
|
4
|
+
import '../../types/index.mjs';
|
|
5
|
+
|
|
6
|
+
declare const meta: {
|
|
7
|
+
title: string;
|
|
8
|
+
component: react.FC<react.HTMLAttributes<HTMLHeadingElement> & {
|
|
9
|
+
text?: string;
|
|
10
|
+
type?: Type;
|
|
11
|
+
className?: string;
|
|
12
|
+
}> & {
|
|
13
|
+
Type: typeof TYPE;
|
|
14
|
+
};
|
|
15
|
+
argTypes: {
|
|
16
|
+
type: {
|
|
17
|
+
defaultValue: "article" | "default";
|
|
18
|
+
options: string[];
|
|
19
|
+
mapping: Record<string, "article" | "default">;
|
|
20
|
+
control: {
|
|
21
|
+
type: "radio";
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
type Story = StoryObj<typeof meta>;
|
|
28
|
+
declare const h1: Story;
|
|
29
|
+
declare const h2: Story;
|
|
30
|
+
declare const h3: Story;
|
|
31
|
+
declare const h4: Story;
|
|
32
|
+
declare const h5: Story;
|
|
33
|
+
declare const h6: Story;
|
|
34
|
+
|
|
35
|
+
export { meta as default, h1, h2, h3, h4, h5, h6 };
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { Type, TYPE } from '../enum/index.js';
|
|
2
|
+
import * as react from 'react';
|
|
3
|
+
import { StoryObj } from '@storybook/react-vite';
|
|
4
|
+
import '../../types/index.js';
|
|
5
|
+
|
|
6
|
+
declare const meta: {
|
|
7
|
+
title: string;
|
|
8
|
+
component: react.FC<react.HTMLAttributes<HTMLHeadingElement> & {
|
|
9
|
+
text?: string;
|
|
10
|
+
type?: Type;
|
|
11
|
+
className?: string;
|
|
12
|
+
}> & {
|
|
13
|
+
Type: typeof TYPE;
|
|
14
|
+
};
|
|
15
|
+
argTypes: {
|
|
16
|
+
type: {
|
|
17
|
+
defaultValue: "article" | "default";
|
|
18
|
+
options: string[];
|
|
19
|
+
mapping: Record<string, "article" | "default">;
|
|
20
|
+
control: {
|
|
21
|
+
type: "radio";
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
type Story = StoryObj<typeof meta>;
|
|
28
|
+
declare const h1: Story;
|
|
29
|
+
declare const h2: Story;
|
|
30
|
+
declare const h3: Story;
|
|
31
|
+
declare const h4: Story;
|
|
32
|
+
declare const h5: Story;
|
|
33
|
+
declare const h6: Story;
|
|
34
|
+
|
|
35
|
+
export { meta as default, h1, h2, h3, h4, h5, h6 };
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var clsx = require('clsx');
|
|
6
|
+
var React = require('react');
|
|
7
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
8
|
+
|
|
9
|
+
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
10
|
+
|
|
11
|
+
var clsx__default = /*#__PURE__*/_interopDefault(clsx);
|
|
12
|
+
var React__default = /*#__PURE__*/_interopDefault(React);
|
|
13
|
+
|
|
14
|
+
// src/storybook/utils/get-enum-arg.ts
|
|
15
|
+
function getRadioArgFromEnum(enumObject, defaultValue) {
|
|
16
|
+
const keys = Object.keys(enumObject).filter(
|
|
17
|
+
(key) => Number.isNaN(Number(key))
|
|
18
|
+
);
|
|
19
|
+
const mapping = {};
|
|
20
|
+
keys.forEach((key) => {
|
|
21
|
+
mapping[key] = enumObject[key];
|
|
22
|
+
});
|
|
23
|
+
const defaultKey = keys.find((key) => enumObject[key] === defaultValue) || keys[0];
|
|
24
|
+
return {
|
|
25
|
+
defaultValue: enumObject[defaultKey],
|
|
26
|
+
options: keys,
|
|
27
|
+
mapping,
|
|
28
|
+
control: { type: "radio" }
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// src/text/enum/index.ts
|
|
33
|
+
var TYPE = {
|
|
34
|
+
default: "default",
|
|
35
|
+
article: "article"
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
// src/text/heading.tsx
|
|
39
|
+
var baseClass = "font-bold";
|
|
40
|
+
var variantClass = {
|
|
41
|
+
H1: "text-[28px] leading-[125%] tablet:text-[36px]",
|
|
42
|
+
H2: "text-[24px] leading-[125%] tablet:text-[32px]",
|
|
43
|
+
H3: "text-[22px] leading-[150%] tablet:text-[28px]",
|
|
44
|
+
H4: "text-[18px] leading-[150%] tablet:text-[22px]",
|
|
45
|
+
H5: "text-[17px] leading-[150%] tablet:text-[18px]",
|
|
46
|
+
H6: "text-[16px] leading-[150%] tablet:text-[16px]"
|
|
47
|
+
};
|
|
48
|
+
var HeadingVariant = (variant) => {
|
|
49
|
+
const Component = ({
|
|
50
|
+
text = "",
|
|
51
|
+
type = TYPE.default,
|
|
52
|
+
className = "",
|
|
53
|
+
...props
|
|
54
|
+
}) => {
|
|
55
|
+
const htmlTag = variant.toLowerCase();
|
|
56
|
+
const fontFamily = type === TYPE.article ? "font-title" : "font-default";
|
|
57
|
+
return React__default.default.createElement(
|
|
58
|
+
htmlTag,
|
|
59
|
+
{
|
|
60
|
+
className: clsx__default.default(
|
|
61
|
+
fontFamily,
|
|
62
|
+
baseClass,
|
|
63
|
+
variantClass[variant],
|
|
64
|
+
className
|
|
65
|
+
),
|
|
66
|
+
...props
|
|
67
|
+
},
|
|
68
|
+
text
|
|
69
|
+
);
|
|
70
|
+
};
|
|
71
|
+
Component.displayName = variant;
|
|
72
|
+
Component.Type = TYPE;
|
|
73
|
+
return Component;
|
|
74
|
+
};
|
|
75
|
+
var H1 = HeadingVariant("H1");
|
|
76
|
+
var H2 = HeadingVariant("H2");
|
|
77
|
+
var H3 = HeadingVariant("H3");
|
|
78
|
+
var H4 = HeadingVariant("H4");
|
|
79
|
+
var H5 = HeadingVariant("H5");
|
|
80
|
+
var H6 = HeadingVariant("H6");
|
|
81
|
+
var meta = {
|
|
82
|
+
title: "Text/Headline",
|
|
83
|
+
component: H1,
|
|
84
|
+
argTypes: {
|
|
85
|
+
type: getRadioArgFromEnum(H1.Type, H1.Type.default)
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
var heading_stories_default = meta;
|
|
89
|
+
var defaultArg = {
|
|
90
|
+
text: "\u6A19\u984C\u300C\u6A19\u984C\u300D\uFF1A\u6A19\u984C\uFF0C\u300A\u6A19\u984C\u300B\u6A19\u984CEnglish\u6A19\u984C123\u6A19\u984C\uFF1F",
|
|
91
|
+
type: H1.Type.default
|
|
92
|
+
};
|
|
93
|
+
var h1 = {
|
|
94
|
+
args: defaultArg,
|
|
95
|
+
parameters: { controls: { exclude: ["className"] } }
|
|
96
|
+
};
|
|
97
|
+
var h2 = {
|
|
98
|
+
render: (args) => /* @__PURE__ */ jsxRuntime.jsx(H2, { ...args }),
|
|
99
|
+
args: defaultArg,
|
|
100
|
+
parameters: { controls: { exclude: ["className"] } }
|
|
101
|
+
};
|
|
102
|
+
var h3 = {
|
|
103
|
+
render: (args) => /* @__PURE__ */ jsxRuntime.jsx(H3, { ...args }),
|
|
104
|
+
args: defaultArg,
|
|
105
|
+
parameters: { controls: { exclude: ["className"] } }
|
|
106
|
+
};
|
|
107
|
+
var h4 = {
|
|
108
|
+
render: (args) => /* @__PURE__ */ jsxRuntime.jsx(H4, { ...args }),
|
|
109
|
+
args: defaultArg,
|
|
110
|
+
parameters: { controls: { exclude: ["className"] } }
|
|
111
|
+
};
|
|
112
|
+
var h5 = {
|
|
113
|
+
render: (args) => /* @__PURE__ */ jsxRuntime.jsx(H5, { ...args }),
|
|
114
|
+
args: defaultArg,
|
|
115
|
+
parameters: { controls: { exclude: ["className"] } }
|
|
116
|
+
};
|
|
117
|
+
var h6 = {
|
|
118
|
+
render: (args) => /* @__PURE__ */ jsxRuntime.jsx(H6, { ...args }),
|
|
119
|
+
args: defaultArg,
|
|
120
|
+
parameters: { controls: { exclude: ["className"] } }
|
|
121
|
+
};
|
|
122
|
+
|
|
123
|
+
exports.default = heading_stories_default;
|
|
124
|
+
exports.h1 = h1;
|
|
125
|
+
exports.h2 = h2;
|
|
126
|
+
exports.h3 = h3;
|
|
127
|
+
exports.h4 = h4;
|
|
128
|
+
exports.h5 = h5;
|
|
129
|
+
exports.h6 = h6;
|
|
130
|
+
//# sourceMappingURL=heading.stories.js.map
|
|
131
|
+
//# sourceMappingURL=heading.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/storybook/utils/get-enum-arg.ts","../../../src/text/enum/index.ts","../../../src/text/heading.tsx","../../../src/text/stories/heading.stories.tsx"],"names":["React","clsx","jsx"],"mappings":";;;;;;;;;;;;;;AAwBO,SAAS,mBAAA,CACd,YACA,YAAA,EAC0B;AAE1B,EAAA,MAAM,IAAA,GAAO,MAAA,CAAO,IAAA,CAAK,UAAU,CAAA,CAAE,MAAA;AAAA,IAAO,CAAC,GAAA,KAC3C,MAAA,CAAO,KAAA,CAAM,MAAA,CAAO,GAAG,CAAC;AAAA,GAC1B;AAEA,EAAA,MAAM,UAAsC,EAAC;AAC7C,EAAA,IAAA,CAAK,OAAA,CAAQ,CAAC,GAAA,KAAQ;AACpB,IAAA,OAAA,CAAQ,GAAG,CAAA,GAAI,UAAA,CAAW,GAAc,CAAA;AAAA,EAC1C,CAAC,CAAA;AAGD,EAAA,MAAM,UAAA,GACJ,IAAA,CAAK,IAAA,CAAK,CAAC,GAAA,KAAQ,UAAA,CAAW,GAAc,CAAA,KAAM,YAAY,CAAA,IAAK,IAAA,CAAK,CAAC,CAAA;AAE3E,EAAA,OAAO;AAAA,IACL,YAAA,EAAc,WAAW,UAAqB,CAAA;AAAA,IAC9C,OAAA,EAAS,IAAA;AAAA,IACT,OAAA;AAAA,IACA,OAAA,EAAS,EAAE,IAAA,EAAM,OAAA;AAAQ,GAC3B;AACF;;;AC9CO,IAAM,IAAA,GAAO;AAAA,EAClB,OAAA,EAAS,SAAA;AAAA,EACT,OAAA,EAAS;AACX,CAAA;;;ACKA,IAAM,SAAA,GAAY,WAAA;AAElB,IAAM,YAAA,GAAe;AAAA,EACnB,EAAA,EAAI,+CAAA;AAAA,EACJ,EAAA,EAAI,+CAAA;AAAA,EACJ,EAAA,EAAI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AAA,EACvB,QAAQ,CAAC,IAAA,qBAASA,cAAA,CAAC,EAAA,EAAA,EAAI,GAAG,IAAA,EAAM,CAAA;AAAA,EAChC,IAAA,EAAM,UAAA;AAAA,EACN,UAAA,EAAY,EAAE,QAAA,EAAU,EAAE,SAAS,CAAC,WAAW,GAAE;AACnD","file":"heading.stories.js","sourcesContent":["type RadioArgObject<T> = {\n defaultValue: T\n options: T[]\n control: { type: 'radio' }\n}\n\nexport function getRadioArgFromObject<T extends string | number>(\n object: Record<string, T>,\n defaultValue: T\n): RadioArgObject<T> {\n return {\n defaultValue,\n options: Object.values(object),\n control: { type: 'radio' },\n }\n}\n\ntype RadioArgEnum<E> = {\n defaultValue: E\n options: string[]\n mapping: Record<string, E>\n control: { type: 'radio' }\n}\n\nexport function getRadioArgFromEnum<E extends Record<string, string | number>>(\n enumObject: E,\n defaultValue: E[keyof E]\n): RadioArgEnum<E[keyof E]> {\n // Only keep \"real\" keys (filter numeric reverse mapping)\n const keys = Object.keys(enumObject).filter((key) =>\n Number.isNaN(Number(key))\n )\n\n const mapping: Record<string, E[keyof E]> = {}\n keys.forEach((key) => {\n mapping[key] = enumObject[key as keyof E]\n })\n\n // Find the key corresponding to the default value\n const defaultKey =\n keys.find((key) => enumObject[key as keyof E] === defaultValue) || keys[0]\n\n return {\n defaultValue: enumObject[defaultKey as keyof E],\n options: keys,\n mapping,\n control: { type: 'radio' },\n }\n}\n","import type { ValuesOf } from '../../types'\n\nexport const TYPE = {\n default: 'default',\n article: 'article',\n} as const\n\nexport type Type = ValuesOf<typeof TYPE>\n\nexport const WEIGHT = {\n extraLight: 'extra-light',\n normal: 'normal',\n bold: 'bold',\n} as const\n\nexport type Weight = ValuesOf<typeof WEIGHT>\n","import clsx from 'clsx'\nimport React from 'react'\nimport { TYPE, type Type } from './enum'\n\ntype HeadingProps = React.HTMLAttributes<HTMLHeadingElement> & {\n text?: string\n type?: Type\n className?: string\n}\n\nconst baseClass = 'font-bold'\n\nconst variantClass = {\n H1: 'text-[28px] leading-[125%] tablet:text-[36px]',\n H2: 'text-[24px] leading-[125%] tablet:text-[32px]',\n H3: 'text-[22px] leading-[150%] tablet:text-[28px]',\n H4: 'text-[18px] leading-[150%] tablet:text-[22px]',\n H5: 'text-[17px] leading-[150%] tablet:text-[18px]',\n H6: 'text-[16px] leading-[150%] tablet:text-[16px]',\n}\n\nconst HeadingVariant = (variant: keyof typeof variantClass) => {\n const Component: React.FC<HeadingProps> & { Type: typeof TYPE } = ({\n text = '',\n type = TYPE.default,\n className = '',\n ...props\n }) => {\n const htmlTag = variant.toLowerCase() // 產生 'h1', 'h2', ...\n const fontFamily = type === TYPE.article ? 'font-title' : 'font-default'\n return React.createElement(\n htmlTag,\n {\n className: clsx(\n fontFamily,\n baseClass,\n variantClass[variant],\n className\n ),\n ...props,\n },\n text\n )\n }\n Component.displayName = variant\n Component.Type = TYPE\n return Component\n}\n\nconst H1 = HeadingVariant('H1')\nconst H2 = HeadingVariant('H2')\nconst H3 = HeadingVariant('H3')\nconst H4 = HeadingVariant('H4')\nconst H5 = HeadingVariant('H5')\nconst H6 = HeadingVariant('H6')\n\nexport { H1, H2, H3, H4, H5, H6 }\n","import type { Meta, StoryObj } from '@storybook/react-vite'\n// utils\nimport { getRadioArgFromEnum } from '../../storybook/utils/get-enum-arg'\n// components\nimport { H1, H2, H3, H4, H5, H6 } from '../heading'\n\nconst meta = {\n title: 'Text/Headline',\n component: H1,\n argTypes: {\n type: getRadioArgFromEnum(H1.Type, H1.Type.default),\n },\n} satisfies Meta<typeof H1>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst defaultArg = {\n text: '標題「標題」:標題,《標題》標題English標題123標題?',\n type: H1.Type.default,\n}\n\nexport const h1: Story = {\n args: defaultArg,\n parameters: { controls: { exclude: ['className'] } },\n}\n\nexport const h2: Story = {\n render: (args) => <H2 {...args} />,\n args: defaultArg,\n parameters: { controls: { exclude: ['className'] } },\n}\n\nexport const h3: Story = {\n render: (args) => <H3 {...args} />,\n args: defaultArg,\n parameters: { controls: { exclude: ['className'] } },\n}\n\nexport const h4: Story = {\n render: (args) => <H4 {...args} />,\n args: defaultArg,\n parameters: { controls: { exclude: ['className'] } },\n}\n\nexport const h5: Story = {\n render: (args) => <H5 {...args} />,\n args: defaultArg,\n parameters: { controls: { exclude: ['className'] } },\n}\n\nexport const h6: Story = {\n render: (args) => <H6 {...args} />,\n args: defaultArg,\n parameters: { controls: { exclude: ['className'] } },\n}\n"]}
|