fumadocs-ui 14.4.2 → 14.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/image-zoom.css +78 -1
- package/dist/components/tabs.d.ts +6 -2
- package/dist/components/tabs.d.ts.map +1 -1
- package/dist/components/tabs.js +32 -18
- package/dist/style.css +2706 -1
- package/dist/tailwind-plugin.d.ts +5 -5
- package/dist/tailwind-plugin.d.ts.map +1 -1
- package/dist/tailwind-plugin.js +9 -10
- package/dist/theme/typography/index.d.ts +12 -0
- package/dist/theme/typography/index.d.ts.map +1 -0
- package/dist/theme/typography/index.js +133 -0
- package/dist/theme/typography/styles.d.ts +486 -0
- package/dist/theme/typography/styles.d.ts.map +1 -0
- package/dist/theme/typography/styles.js +426 -0
- package/package.json +11 -9
- package/dist/theme/typography.d.ts +0 -93
- package/dist/theme/typography.d.ts.map +0 -1
- package/dist/theme/typography.js +0 -97
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/theme/typography/styles.ts"],"names":[],"mappings":"AAsHA,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,mBAAmB,CAAC,EAAE,OAAO,CAAC;CAC/B;AAED,eAAO,MAAM,OAAO,4BAA6B,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8T3D,CAAC"}
|
|
@@ -0,0 +1,426 @@
|
|
|
1
|
+
function round(num) {
|
|
2
|
+
return num
|
|
3
|
+
.toFixed(7)
|
|
4
|
+
.replace(/(\.[0-9]+?)0+$/, '$1')
|
|
5
|
+
.replace(/\.0$/, '');
|
|
6
|
+
}
|
|
7
|
+
function rem(px) {
|
|
8
|
+
return `${round(px / 16)}rem`;
|
|
9
|
+
}
|
|
10
|
+
function em(px, base) {
|
|
11
|
+
return `${round(px / base)}em`;
|
|
12
|
+
}
|
|
13
|
+
const colors = {
|
|
14
|
+
'--tw-prose-body': `theme('colors.fd-foreground / 90%')`,
|
|
15
|
+
'--tw-prose-headings': `theme('colors.fd-foreground')`,
|
|
16
|
+
'--tw-prose-lead': `theme('colors.fd-foreground')`,
|
|
17
|
+
'--tw-prose-links': `theme('colors.fd-foreground')`,
|
|
18
|
+
'--tw-prose-bold': `theme('colors.fd-foreground')`,
|
|
19
|
+
'--tw-prose-counters': `theme('colors.fd-muted.foreground')`,
|
|
20
|
+
'--tw-prose-bullets': `theme('colors.fd-muted.foreground')`,
|
|
21
|
+
'--tw-prose-hr': `theme('colors.fd-border')`,
|
|
22
|
+
'--tw-prose-quotes': `theme('colors.fd-foreground')`,
|
|
23
|
+
'--tw-prose-quote-borders': `theme('colors.fd-border')`,
|
|
24
|
+
'--tw-prose-captions': `theme('colors.fd-foreground')`,
|
|
25
|
+
'--tw-prose-code': `theme('colors.fd-foreground')`,
|
|
26
|
+
'--tw-prose-th-borders': `theme('colors.fd-border')`,
|
|
27
|
+
'--tw-prose-td-borders': `theme('colors.fd-border')`,
|
|
28
|
+
'--tw-prose-kbd': `theme('colors.fd-foreground')`,
|
|
29
|
+
'--tw-prose-kbd-shadows': `theme('colors.fd-primary.DEFAULT / 50%')`,
|
|
30
|
+
};
|
|
31
|
+
const roundedTable = {
|
|
32
|
+
table: {
|
|
33
|
+
borderCollapse: 'separate',
|
|
34
|
+
borderSpacing: '0',
|
|
35
|
+
'@apply bg-fd-card rounded-lg border overflow-hidden': '',
|
|
36
|
+
},
|
|
37
|
+
th: {
|
|
38
|
+
textAlign: 'start',
|
|
39
|
+
'@apply p-2.5 border-s bg-fd-muted': '',
|
|
40
|
+
},
|
|
41
|
+
'th:first-child': {
|
|
42
|
+
'@apply border-s-0': '',
|
|
43
|
+
},
|
|
44
|
+
'th:not(tr:last-child *), td:not(tr:last-child *)': {
|
|
45
|
+
'@apply border-b': '',
|
|
46
|
+
},
|
|
47
|
+
td: {
|
|
48
|
+
textAlign: 'start',
|
|
49
|
+
'@apply border-s p-2.5': '',
|
|
50
|
+
},
|
|
51
|
+
'td:first-child': {
|
|
52
|
+
'@apply border-s-0': '',
|
|
53
|
+
},
|
|
54
|
+
'tfoot th, tfoot td': {
|
|
55
|
+
borderTopWidth: '1px',
|
|
56
|
+
borderTopColor: 'var(--tw-prose-th-borders)',
|
|
57
|
+
},
|
|
58
|
+
'thead th, thead td': {
|
|
59
|
+
borderBottomWidth: '1px',
|
|
60
|
+
borderBottomColor: 'var(--tw-prose-th-borders)',
|
|
61
|
+
},
|
|
62
|
+
};
|
|
63
|
+
const normalTable = {
|
|
64
|
+
thead: {
|
|
65
|
+
borderBottomWidth: '1px',
|
|
66
|
+
borderBottomColor: 'var(--tw-prose-th-borders)',
|
|
67
|
+
},
|
|
68
|
+
'thead th': {
|
|
69
|
+
verticalAlign: 'bottom',
|
|
70
|
+
paddingInlineEnd: em(8, 14),
|
|
71
|
+
paddingBottom: em(8, 14),
|
|
72
|
+
paddingInlineStart: em(8, 14),
|
|
73
|
+
},
|
|
74
|
+
'thead th:first-child': {
|
|
75
|
+
paddingInlineStart: '0',
|
|
76
|
+
},
|
|
77
|
+
'thead th:last-child': {
|
|
78
|
+
paddingInlineEnd: '0',
|
|
79
|
+
},
|
|
80
|
+
'tbody td, tfoot td': {
|
|
81
|
+
paddingTop: em(8, 14),
|
|
82
|
+
paddingInlineEnd: em(8, 14),
|
|
83
|
+
paddingBottom: em(8, 14),
|
|
84
|
+
paddingInlineStart: em(8, 14),
|
|
85
|
+
},
|
|
86
|
+
'tbody td:first-child, tfoot td:first-child': {
|
|
87
|
+
paddingInlineStart: '0',
|
|
88
|
+
},
|
|
89
|
+
'tbody td:last-child, tfoot td:last-child': {
|
|
90
|
+
paddingInlineEnd: '0',
|
|
91
|
+
},
|
|
92
|
+
'tbody tr': {
|
|
93
|
+
borderBottomWidth: '1px',
|
|
94
|
+
borderBottomColor: 'var(--tw-prose-td-borders)',
|
|
95
|
+
},
|
|
96
|
+
'tbody tr:last-child': {
|
|
97
|
+
borderBottomWidth: '0',
|
|
98
|
+
},
|
|
99
|
+
'tbody td': {
|
|
100
|
+
verticalAlign: 'baseline',
|
|
101
|
+
},
|
|
102
|
+
tfoot: {
|
|
103
|
+
borderTopWidth: '1px',
|
|
104
|
+
borderTopColor: 'var(--tw-prose-th-borders)',
|
|
105
|
+
},
|
|
106
|
+
'tfoot td': {
|
|
107
|
+
verticalAlign: 'top',
|
|
108
|
+
},
|
|
109
|
+
'th, td': {
|
|
110
|
+
textAlign: 'start',
|
|
111
|
+
},
|
|
112
|
+
};
|
|
113
|
+
export const DEFAULT = ({ disableRoundedTable }) => ({
|
|
114
|
+
css: [
|
|
115
|
+
{
|
|
116
|
+
color: 'var(--tw-prose-body)',
|
|
117
|
+
maxWidth: 'none',
|
|
118
|
+
fontSize: rem(16),
|
|
119
|
+
lineHeight: round(28 / 16),
|
|
120
|
+
'[class~="lead"]': {
|
|
121
|
+
fontSize: em(20, 16),
|
|
122
|
+
lineHeight: round(32 / 20),
|
|
123
|
+
marginTop: em(24, 20),
|
|
124
|
+
marginBottom: em(24, 20),
|
|
125
|
+
color: 'var(--tw-prose-lead)',
|
|
126
|
+
},
|
|
127
|
+
ul: {
|
|
128
|
+
paddingInlineStart: '1rem',
|
|
129
|
+
listStyleType: 'disc',
|
|
130
|
+
marginTop: em(20, 16),
|
|
131
|
+
marginBottom: em(20, 16),
|
|
132
|
+
},
|
|
133
|
+
li: {
|
|
134
|
+
marginTop: em(8, 16),
|
|
135
|
+
marginBottom: em(8, 16),
|
|
136
|
+
},
|
|
137
|
+
'ol > li': {
|
|
138
|
+
paddingInlineStart: em(6, 16),
|
|
139
|
+
},
|
|
140
|
+
'ul > li': {
|
|
141
|
+
paddingInlineStart: '0',
|
|
142
|
+
},
|
|
143
|
+
'> ul > li p': {
|
|
144
|
+
marginTop: em(12, 16),
|
|
145
|
+
marginBottom: em(12, 16),
|
|
146
|
+
},
|
|
147
|
+
'> ul > li > p:first-child': {
|
|
148
|
+
marginTop: em(20, 16),
|
|
149
|
+
},
|
|
150
|
+
'> ul > li > p:last-child': {
|
|
151
|
+
marginBottom: em(20, 16),
|
|
152
|
+
},
|
|
153
|
+
'> ol > li > p:first-child': {
|
|
154
|
+
marginTop: em(20, 16),
|
|
155
|
+
},
|
|
156
|
+
'> ol > li > p:last-child': {
|
|
157
|
+
marginBottom: em(20, 16),
|
|
158
|
+
},
|
|
159
|
+
'ul ul, ul ol, ol ul, ol ol': {
|
|
160
|
+
marginTop: em(12, 16),
|
|
161
|
+
marginBottom: em(12, 16),
|
|
162
|
+
},
|
|
163
|
+
dl: {
|
|
164
|
+
marginTop: em(20, 16),
|
|
165
|
+
marginBottom: em(20, 16),
|
|
166
|
+
},
|
|
167
|
+
dt: {
|
|
168
|
+
color: 'var(--tw-prose-headings)',
|
|
169
|
+
fontWeight: '600',
|
|
170
|
+
marginTop: em(20, 16),
|
|
171
|
+
},
|
|
172
|
+
dd: {
|
|
173
|
+
marginTop: em(8, 16),
|
|
174
|
+
paddingInlineStart: em(26, 16),
|
|
175
|
+
},
|
|
176
|
+
hr: {
|
|
177
|
+
borderColor: 'var(--tw-prose-hr)',
|
|
178
|
+
borderTopWidth: 1,
|
|
179
|
+
marginTop: em(48, 16),
|
|
180
|
+
marginBottom: em(48, 16),
|
|
181
|
+
},
|
|
182
|
+
p: {
|
|
183
|
+
marginTop: em(20, 16),
|
|
184
|
+
marginBottom: em(20, 16),
|
|
185
|
+
},
|
|
186
|
+
strong: {
|
|
187
|
+
color: 'var(--tw-prose-bold)',
|
|
188
|
+
fontWeight: '600',
|
|
189
|
+
},
|
|
190
|
+
'a strong': {
|
|
191
|
+
color: 'inherit',
|
|
192
|
+
},
|
|
193
|
+
'blockquote strong': {
|
|
194
|
+
color: 'inherit',
|
|
195
|
+
},
|
|
196
|
+
'thead th strong': {
|
|
197
|
+
color: 'inherit',
|
|
198
|
+
},
|
|
199
|
+
ol: {
|
|
200
|
+
listStyleType: 'decimal',
|
|
201
|
+
marginTop: em(20, 16),
|
|
202
|
+
marginBottom: em(20, 16),
|
|
203
|
+
paddingInlineStart: em(26, 16),
|
|
204
|
+
},
|
|
205
|
+
'ol[type="A"]': {
|
|
206
|
+
listStyleType: 'upper-alpha',
|
|
207
|
+
},
|
|
208
|
+
'ol[type="a"]': {
|
|
209
|
+
listStyleType: 'lower-alpha',
|
|
210
|
+
},
|
|
211
|
+
'ol[type="A" s]': {
|
|
212
|
+
listStyleType: 'upper-alpha',
|
|
213
|
+
},
|
|
214
|
+
'ol[type="a" s]': {
|
|
215
|
+
listStyleType: 'lower-alpha',
|
|
216
|
+
},
|
|
217
|
+
'ol[type="I"]': {
|
|
218
|
+
listStyleType: 'upper-roman',
|
|
219
|
+
},
|
|
220
|
+
'ol[type="i"]': {
|
|
221
|
+
listStyleType: 'lower-roman',
|
|
222
|
+
},
|
|
223
|
+
'ol[type="I" s]': {
|
|
224
|
+
listStyleType: 'upper-roman',
|
|
225
|
+
},
|
|
226
|
+
'ol[type="i" s]': {
|
|
227
|
+
listStyleType: 'lower-roman',
|
|
228
|
+
},
|
|
229
|
+
'ol[type="1"]': {
|
|
230
|
+
listStyleType: 'decimal',
|
|
231
|
+
},
|
|
232
|
+
'ol > li::marker': {
|
|
233
|
+
fontWeight: '400',
|
|
234
|
+
color: 'var(--tw-prose-counters)',
|
|
235
|
+
},
|
|
236
|
+
'ul > li::marker': {
|
|
237
|
+
color: 'var(--tw-prose-bullets)',
|
|
238
|
+
},
|
|
239
|
+
blockquote: {
|
|
240
|
+
marginTop: em(32, 20),
|
|
241
|
+
marginBottom: em(32, 20),
|
|
242
|
+
paddingInlineStart: em(20, 20),
|
|
243
|
+
fontWeight: '500',
|
|
244
|
+
fontStyle: 'italic',
|
|
245
|
+
color: 'var(--tw-prose-quotes)',
|
|
246
|
+
borderInlineStartWidth: '0.25rem',
|
|
247
|
+
borderInlineStartColor: 'var(--tw-prose-quote-borders)',
|
|
248
|
+
quotes: '"\\201C""\\201D""\\2018""\\2019"',
|
|
249
|
+
},
|
|
250
|
+
'blockquote p:first-of-type::before': {
|
|
251
|
+
content: 'open-quote',
|
|
252
|
+
},
|
|
253
|
+
'blockquote p:last-of-type::after': {
|
|
254
|
+
content: 'close-quote',
|
|
255
|
+
},
|
|
256
|
+
h1: {
|
|
257
|
+
color: 'var(--tw-prose-headings)',
|
|
258
|
+
fontWeight: '800',
|
|
259
|
+
fontSize: em(36, 16),
|
|
260
|
+
marginTop: '0',
|
|
261
|
+
marginBottom: em(32, 36),
|
|
262
|
+
lineHeight: round(40 / 36),
|
|
263
|
+
},
|
|
264
|
+
'h1 strong': {
|
|
265
|
+
fontWeight: '900',
|
|
266
|
+
color: 'inherit',
|
|
267
|
+
},
|
|
268
|
+
h2: {
|
|
269
|
+
color: 'var(--tw-prose-headings)',
|
|
270
|
+
fontSize: em(24, 16),
|
|
271
|
+
marginTop: em(48, 24),
|
|
272
|
+
marginBottom: em(24, 24),
|
|
273
|
+
lineHeight: round(32 / 24),
|
|
274
|
+
fontWeight: '600',
|
|
275
|
+
},
|
|
276
|
+
'h2 strong': {
|
|
277
|
+
fontWeight: '800',
|
|
278
|
+
color: 'inherit',
|
|
279
|
+
},
|
|
280
|
+
h3: {
|
|
281
|
+
color: 'var(--tw-prose-headings)',
|
|
282
|
+
fontWeight: '600',
|
|
283
|
+
fontSize: em(20, 16),
|
|
284
|
+
marginTop: em(32, 20),
|
|
285
|
+
marginBottom: em(12, 20),
|
|
286
|
+
lineHeight: round(32 / 20),
|
|
287
|
+
},
|
|
288
|
+
'h3 strong': {
|
|
289
|
+
fontWeight: '700',
|
|
290
|
+
color: 'inherit',
|
|
291
|
+
},
|
|
292
|
+
h4: {
|
|
293
|
+
color: 'var(--tw-prose-headings)',
|
|
294
|
+
fontWeight: '600',
|
|
295
|
+
marginTop: em(24, 16),
|
|
296
|
+
marginBottom: em(8, 16),
|
|
297
|
+
lineHeight: round(24 / 16),
|
|
298
|
+
},
|
|
299
|
+
'h4 strong': {
|
|
300
|
+
fontWeight: '700',
|
|
301
|
+
color: 'inherit',
|
|
302
|
+
},
|
|
303
|
+
'hr + *': {
|
|
304
|
+
marginTop: '0',
|
|
305
|
+
},
|
|
306
|
+
'h2 + *': {
|
|
307
|
+
marginTop: '0',
|
|
308
|
+
},
|
|
309
|
+
'h3 + *': {
|
|
310
|
+
marginTop: '0',
|
|
311
|
+
},
|
|
312
|
+
'h4 + *': {
|
|
313
|
+
marginTop: '0',
|
|
314
|
+
},
|
|
315
|
+
img: {
|
|
316
|
+
marginTop: em(32, 16),
|
|
317
|
+
marginBottom: em(32, 16),
|
|
318
|
+
},
|
|
319
|
+
picture: {
|
|
320
|
+
display: 'block',
|
|
321
|
+
marginTop: em(32, 16),
|
|
322
|
+
marginBottom: em(32, 16),
|
|
323
|
+
},
|
|
324
|
+
'picture > img': {
|
|
325
|
+
marginTop: '0',
|
|
326
|
+
marginBottom: '0',
|
|
327
|
+
},
|
|
328
|
+
video: {
|
|
329
|
+
marginTop: em(32, 16),
|
|
330
|
+
marginBottom: em(32, 16),
|
|
331
|
+
},
|
|
332
|
+
kbd: {
|
|
333
|
+
fontSize: em(14, 16),
|
|
334
|
+
borderRadius: rem(5),
|
|
335
|
+
paddingTop: em(3, 16),
|
|
336
|
+
paddingInlineEnd: em(6, 16),
|
|
337
|
+
paddingBottom: em(3, 16),
|
|
338
|
+
paddingInlineStart: em(6, 16),
|
|
339
|
+
fontWeight: '500',
|
|
340
|
+
fontFamily: 'inherit',
|
|
341
|
+
color: 'var(--tw-prose-kbd)',
|
|
342
|
+
boxShadow: '0 0 0 1px var(--tw-prose-kbd-shadows),0 3px 0 var(--tw-prose-kbd-shadows)',
|
|
343
|
+
},
|
|
344
|
+
code: {
|
|
345
|
+
padding: '3px',
|
|
346
|
+
border: 'solid 1px',
|
|
347
|
+
fontSize: '13px',
|
|
348
|
+
borderColor: `theme('colors.fd-border')`,
|
|
349
|
+
borderRadius: '5px',
|
|
350
|
+
fontWeight: '400',
|
|
351
|
+
background: `theme('colors.fd-muted.DEFAULT')`,
|
|
352
|
+
color: 'var(--tw-prose-code)',
|
|
353
|
+
},
|
|
354
|
+
'a code': {
|
|
355
|
+
color: 'inherit',
|
|
356
|
+
},
|
|
357
|
+
'h1 code': {
|
|
358
|
+
color: 'inherit',
|
|
359
|
+
},
|
|
360
|
+
'h2 code': {
|
|
361
|
+
color: 'inherit',
|
|
362
|
+
fontSize: em(21, 24),
|
|
363
|
+
},
|
|
364
|
+
'h3 code': {
|
|
365
|
+
color: 'inherit',
|
|
366
|
+
fontSize: em(18, 20),
|
|
367
|
+
},
|
|
368
|
+
'h4 code': {
|
|
369
|
+
color: 'inherit',
|
|
370
|
+
},
|
|
371
|
+
'blockquote code': {
|
|
372
|
+
color: 'inherit',
|
|
373
|
+
},
|
|
374
|
+
'thead th code': {
|
|
375
|
+
color: 'inherit',
|
|
376
|
+
},
|
|
377
|
+
table: {
|
|
378
|
+
fontSize: em(14, 16),
|
|
379
|
+
lineHeight: round(24 / 14),
|
|
380
|
+
width: '100%',
|
|
381
|
+
tableLayout: 'auto',
|
|
382
|
+
marginTop: em(32, 16),
|
|
383
|
+
marginBottom: em(32, 16),
|
|
384
|
+
},
|
|
385
|
+
'thead th': {
|
|
386
|
+
color: 'var(--tw-prose-headings)',
|
|
387
|
+
fontWeight: '600',
|
|
388
|
+
},
|
|
389
|
+
figure: {
|
|
390
|
+
marginTop: em(32, 16),
|
|
391
|
+
marginBottom: em(32, 16),
|
|
392
|
+
},
|
|
393
|
+
'figure > *': {
|
|
394
|
+
marginTop: '0',
|
|
395
|
+
marginBottom: '0',
|
|
396
|
+
},
|
|
397
|
+
figcaption: {
|
|
398
|
+
color: 'var(--tw-prose-captions)',
|
|
399
|
+
fontSize: em(14, 16),
|
|
400
|
+
lineHeight: round(20 / 14),
|
|
401
|
+
marginTop: em(12, 14),
|
|
402
|
+
},
|
|
403
|
+
'a:not([data-card])': {
|
|
404
|
+
color: 'var(--tw-prose-links)',
|
|
405
|
+
transition: 'opacity 0.3s',
|
|
406
|
+
fontWeight: '400',
|
|
407
|
+
textDecoration: 'underline',
|
|
408
|
+
textUnderlineOffset: '2px',
|
|
409
|
+
textDecorationColor: `theme('colors.fd-primary.DEFAULT')`,
|
|
410
|
+
},
|
|
411
|
+
'a:not([data-card]):hover': {
|
|
412
|
+
opacity: '80%',
|
|
413
|
+
},
|
|
414
|
+
},
|
|
415
|
+
colors,
|
|
416
|
+
{
|
|
417
|
+
'> :first-child': {
|
|
418
|
+
marginTop: '0',
|
|
419
|
+
},
|
|
420
|
+
'> :last-child': {
|
|
421
|
+
marginBottom: '0',
|
|
422
|
+
},
|
|
423
|
+
},
|
|
424
|
+
disableRoundedTable ? normalTable : roundedTable,
|
|
425
|
+
],
|
|
426
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fumadocs-ui",
|
|
3
|
-
"version": "14.
|
|
3
|
+
"version": "14.5.0",
|
|
4
4
|
"description": "The framework for building a documentation website in Next.js",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"NextJs",
|
|
@@ -58,26 +58,28 @@
|
|
|
58
58
|
"@radix-ui/react-direction": "^1.1.0",
|
|
59
59
|
"@radix-ui/react-navigation-menu": "^1.2.1",
|
|
60
60
|
"@radix-ui/react-popover": "^1.1.2",
|
|
61
|
-
"@radix-ui/react-scroll-area": "^1.2.
|
|
61
|
+
"@radix-ui/react-scroll-area": "^1.2.1",
|
|
62
62
|
"@radix-ui/react-slot": "^1.1.0",
|
|
63
63
|
"@radix-ui/react-tabs": "^1.1.1",
|
|
64
|
-
"@tailwindcss/typography": "^0.5.15",
|
|
65
64
|
"class-variance-authority": "^0.7.0",
|
|
66
|
-
"
|
|
65
|
+
"lodash.merge": "^4.6.2",
|
|
66
|
+
"lucide-react": "^0.460.0",
|
|
67
67
|
"next-themes": "^0.4.3",
|
|
68
|
-
"
|
|
68
|
+
"postcss-selector-parser": "^7.0.0",
|
|
69
|
+
"react-medium-image-zoom": "^5.2.11",
|
|
69
70
|
"tailwind-merge": "^2.5.4",
|
|
70
|
-
"fumadocs-core": "14.
|
|
71
|
+
"fumadocs-core": "14.5.0"
|
|
71
72
|
},
|
|
72
73
|
"devDependencies": {
|
|
73
74
|
"@next/eslint-plugin-next": "^15.0.3",
|
|
75
|
+
"@types/lodash.merge": "^4.6.9",
|
|
74
76
|
"@types/react": "^18.3.12",
|
|
75
77
|
"@types/react-dom": "^18.3.1",
|
|
78
|
+
"autoprefixer": "^10.4.20",
|
|
76
79
|
"next": "15.0.3",
|
|
77
|
-
"postcss": "^8.4.
|
|
80
|
+
"postcss": "^8.4.49",
|
|
78
81
|
"postcss-cli": "^11.0.0",
|
|
79
|
-
"
|
|
80
|
-
"tailwindcss": "^3.4.13",
|
|
82
|
+
"tailwindcss": "^3.4.15",
|
|
81
83
|
"tsc-alias": "^1.8.10",
|
|
82
84
|
"@fumadocs/cli": "0.0.3",
|
|
83
85
|
"eslint-config-custom": "0.0.0",
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import type { DocsUIOptions } from '../tailwind-plugin';
|
|
2
|
-
export declare const typography: ({ disableRoundedTable }: DocsUIOptions) => {
|
|
3
|
-
css: {
|
|
4
|
-
table: {
|
|
5
|
-
borderCollapse: string;
|
|
6
|
-
borderSpacing: string;
|
|
7
|
-
'@apply bg-fd-card rounded-lg border overflow-hidden': string;
|
|
8
|
-
} | {
|
|
9
|
-
fontSize: string;
|
|
10
|
-
};
|
|
11
|
-
thead?: {
|
|
12
|
-
border: string;
|
|
13
|
-
} | undefined;
|
|
14
|
-
th?: {
|
|
15
|
-
'@apply p-2.5 border-l bg-fd-muted': string;
|
|
16
|
-
} | undefined;
|
|
17
|
-
'th:first-of-type'?: {
|
|
18
|
-
'@apply border-l-0': string;
|
|
19
|
-
} | undefined;
|
|
20
|
-
'th, td:not(tr:last-of-type *)'?: {
|
|
21
|
-
'@apply border-b': string;
|
|
22
|
-
} | undefined;
|
|
23
|
-
td?: {
|
|
24
|
-
'@apply border-l p-2.5': string;
|
|
25
|
-
} | undefined;
|
|
26
|
-
'td:first-of-type'?: {
|
|
27
|
-
'@apply border-l-0': string;
|
|
28
|
-
} | undefined;
|
|
29
|
-
'--tw-prose-body': string;
|
|
30
|
-
'--tw-prose-headings': string;
|
|
31
|
-
'--tw-prose-lead': string;
|
|
32
|
-
'--tw-prose-links': string;
|
|
33
|
-
'--tw-prose-bold': string;
|
|
34
|
-
'--tw-prose-counters': string;
|
|
35
|
-
'--tw-prose-bullets': string;
|
|
36
|
-
'--tw-prose-hr': string;
|
|
37
|
-
'--tw-prose-quotes': string;
|
|
38
|
-
'--tw-prose-quote-borders': string;
|
|
39
|
-
'--tw-prose-captions': string;
|
|
40
|
-
'--tw-prose-code': string;
|
|
41
|
-
'--tw-prose-th-borders': string;
|
|
42
|
-
'--tw-prose-td-borders': string;
|
|
43
|
-
'--tw-prose-kbd': string;
|
|
44
|
-
'--tw-prose-kbd-shadows': string;
|
|
45
|
-
'--tw-prose-pre-bg': boolean;
|
|
46
|
-
'--tw-prose-pre-code': boolean;
|
|
47
|
-
fontSize: string;
|
|
48
|
-
maxWidth: string;
|
|
49
|
-
a: boolean;
|
|
50
|
-
'a:hover': boolean;
|
|
51
|
-
'a:not([data-card])': {
|
|
52
|
-
color: string;
|
|
53
|
-
transition: string;
|
|
54
|
-
fontWeight: string;
|
|
55
|
-
textDecoration: string;
|
|
56
|
-
textUnderlineOffset: string;
|
|
57
|
-
textDecorationColor: string;
|
|
58
|
-
};
|
|
59
|
-
'a:not([data-card]):hover': {
|
|
60
|
-
opacity: string;
|
|
61
|
-
};
|
|
62
|
-
'thead th': {
|
|
63
|
-
textAlign: string;
|
|
64
|
-
};
|
|
65
|
-
h2: {
|
|
66
|
-
fontWeight: string;
|
|
67
|
-
};
|
|
68
|
-
code: {
|
|
69
|
-
padding: string;
|
|
70
|
-
border: string;
|
|
71
|
-
fontSize: string;
|
|
72
|
-
borderColor: string;
|
|
73
|
-
borderRadius: string;
|
|
74
|
-
fontWeight: string;
|
|
75
|
-
background: string;
|
|
76
|
-
};
|
|
77
|
-
kbd: {
|
|
78
|
-
boxShadow: string;
|
|
79
|
-
};
|
|
80
|
-
ul: {
|
|
81
|
-
paddingInlineStart: string;
|
|
82
|
-
};
|
|
83
|
-
'ul > li': {
|
|
84
|
-
paddingInlineStart: string;
|
|
85
|
-
};
|
|
86
|
-
'pre code': boolean;
|
|
87
|
-
'pre code::after': boolean;
|
|
88
|
-
'pre code::before': boolean;
|
|
89
|
-
'code::after': boolean;
|
|
90
|
-
'code::before': boolean;
|
|
91
|
-
};
|
|
92
|
-
};
|
|
93
|
-
//# sourceMappingURL=typography.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"typography.d.ts","sourceRoot":"","sources":["../../src/theme/typography.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AA8BvD,eAAO,MAAM,UAAU,4BAA6B,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwE/D,CAAC"}
|
package/dist/theme/typography.js
DELETED
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
const tableStyles = {
|
|
2
|
-
table: {
|
|
3
|
-
borderCollapse: 'separate',
|
|
4
|
-
borderSpacing: '0',
|
|
5
|
-
'@apply bg-fd-card rounded-lg border overflow-hidden': '',
|
|
6
|
-
},
|
|
7
|
-
thead: {
|
|
8
|
-
border: '0',
|
|
9
|
-
},
|
|
10
|
-
th: {
|
|
11
|
-
'@apply p-2.5 border-l bg-fd-muted': '',
|
|
12
|
-
},
|
|
13
|
-
'th:first-of-type': {
|
|
14
|
-
'@apply border-l-0': '',
|
|
15
|
-
},
|
|
16
|
-
'th, td:not(tr:last-of-type *)': {
|
|
17
|
-
'@apply border-b': '',
|
|
18
|
-
},
|
|
19
|
-
td: {
|
|
20
|
-
'@apply border-l p-2.5': '',
|
|
21
|
-
},
|
|
22
|
-
'td:first-of-type': {
|
|
23
|
-
'@apply border-l-0': '',
|
|
24
|
-
},
|
|
25
|
-
};
|
|
26
|
-
export const typography = ({ disableRoundedTable }) => ({
|
|
27
|
-
css: {
|
|
28
|
-
'--tw-prose-body': `theme('colors.fd-foreground / 90%')`,
|
|
29
|
-
'--tw-prose-headings': `theme('colors.fd-foreground')`,
|
|
30
|
-
'--tw-prose-lead': `theme('colors.fd-foreground')`,
|
|
31
|
-
'--tw-prose-links': `theme('colors.fd-foreground')`,
|
|
32
|
-
'--tw-prose-bold': `theme('colors.fd-foreground')`,
|
|
33
|
-
'--tw-prose-counters': `theme('colors.fd-muted.foreground')`,
|
|
34
|
-
'--tw-prose-bullets': `theme('colors.fd-muted.foreground')`,
|
|
35
|
-
'--tw-prose-hr': `theme('colors.fd-border')`,
|
|
36
|
-
'--tw-prose-quotes': `theme('colors.fd-foreground')`,
|
|
37
|
-
'--tw-prose-quote-borders': `theme('colors.fd-border')`,
|
|
38
|
-
'--tw-prose-captions': `theme('colors.fd-foreground')`,
|
|
39
|
-
'--tw-prose-code': `theme('colors.fd-foreground')`,
|
|
40
|
-
'--tw-prose-th-borders': `theme('colors.fd-border')`,
|
|
41
|
-
'--tw-prose-td-borders': `theme('colors.fd-border')`,
|
|
42
|
-
'--tw-prose-kbd': `theme('colors.fd-foreground')`,
|
|
43
|
-
'--tw-prose-kbd-shadows': `theme('colors.fd-primary.DEFAULT / 50%')`,
|
|
44
|
-
// not used
|
|
45
|
-
'--tw-prose-pre-bg': false,
|
|
46
|
-
'--tw-prose-pre-code': false,
|
|
47
|
-
fontSize: '16px',
|
|
48
|
-
maxWidth: 'none',
|
|
49
|
-
a: false,
|
|
50
|
-
'a:hover': false,
|
|
51
|
-
'a:not([data-card])': {
|
|
52
|
-
color: 'var(--tw-prose-links)',
|
|
53
|
-
transition: 'opacity 0.3s',
|
|
54
|
-
fontWeight: '400',
|
|
55
|
-
textDecoration: 'underline',
|
|
56
|
-
textUnderlineOffset: '2px',
|
|
57
|
-
textDecorationColor: `theme('colors.fd-primary.DEFAULT')`,
|
|
58
|
-
},
|
|
59
|
-
'a:not([data-card]):hover': {
|
|
60
|
-
opacity: '80%',
|
|
61
|
-
},
|
|
62
|
-
table: {
|
|
63
|
-
fontSize: '14px',
|
|
64
|
-
},
|
|
65
|
-
'thead th': {
|
|
66
|
-
textAlign: 'start',
|
|
67
|
-
},
|
|
68
|
-
h2: {
|
|
69
|
-
fontWeight: '600',
|
|
70
|
-
},
|
|
71
|
-
code: {
|
|
72
|
-
padding: '3px',
|
|
73
|
-
border: 'solid 1px',
|
|
74
|
-
fontSize: '13px',
|
|
75
|
-
borderColor: `theme('colors.fd-border')`,
|
|
76
|
-
borderRadius: '5px',
|
|
77
|
-
fontWeight: '400',
|
|
78
|
-
background: `theme('colors.fd-muted.DEFAULT')`,
|
|
79
|
-
},
|
|
80
|
-
kbd: {
|
|
81
|
-
boxShadow: '0 0 0 1px var(--tw-prose-kbd-shadows),0 3px 0 var(--tw-prose-kbd-shadows)',
|
|
82
|
-
},
|
|
83
|
-
ul: {
|
|
84
|
-
paddingInlineStart: '1rem',
|
|
85
|
-
},
|
|
86
|
-
'ul > li': {
|
|
87
|
-
paddingInlineStart: '0',
|
|
88
|
-
},
|
|
89
|
-
// Disabled styles, handled by Fumadocs UI
|
|
90
|
-
'pre code': false,
|
|
91
|
-
'pre code::after': false,
|
|
92
|
-
'pre code::before': false,
|
|
93
|
-
'code::after': false,
|
|
94
|
-
'code::before': false,
|
|
95
|
-
...(!disableRoundedTable ? tableStyles : undefined),
|
|
96
|
-
},
|
|
97
|
-
});
|