@naiheyoung/use 0.0.1 → 0.0.2

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.
@@ -1,386 +1,386 @@
1
- /* Powered by @naiheyoung/use. 奈何*/
2
- @import '@naiheyoung/color';
3
-
4
- /* dm-mono-latin-400-normal */
5
- @font-face {
6
- font-family: 'DM Mono';
7
- font-style: normal;
8
- font-display: swap;
9
- font-weight: 400;
10
- src:
11
- url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-400-normal.woff2)
12
- format('woff2'),
13
- url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-400-normal.woff)
14
- format('woff');
15
- unicode-range:
16
- U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
17
- U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
18
- }
19
-
20
- /* dm-mono-latin-500-normal */
21
- @font-face {
22
- font-family: 'DM Mono';
23
- font-style: normal;
24
- font-display: swap;
25
- font-weight: 500;
26
- src:
27
- url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-500-normal.woff2)
28
- format('woff2'),
29
- url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-500-normal.woff)
30
- format('woff');
31
- unicode-range:
32
- U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
33
- U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
34
- }
35
-
36
- /* dm-sans-latin-wght-normal */
37
- @font-face {
38
- font-family: 'DM Sans Variable';
39
- font-style: normal;
40
- font-display: swap;
41
- font-weight: 100 1000;
42
- src: url(https://cdn.jsdelivr.net/fontsource/fonts/dm-sans:vf@latest/latin-wght-normal.woff2)
43
- format('woff2-variations');
44
- unicode-range:
45
- U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
46
- U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
47
- }
48
-
49
- /* jetbrains-mono-latin-wght-normal */
50
- @font-face {
51
- font-family: 'JetBrains Mono Variable';
52
- font-style: normal;
53
- font-display: swap;
54
- font-weight: 100 800;
55
- src: url(https://cdn.jsdelivr.net/fontsource/fonts/jetbrains-mono:vf@latest/latin-wght-normal.woff2)
56
- format('woff2-variations');
57
- unicode-range:
58
- U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
59
- U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
60
- }
61
-
62
- :root,
63
- :host {
64
- --font-mono: 'DM Mono', monospace;
65
- --font-sans: 'DM Sans Variable', monospace;
66
- --font-code: 'JetBrains Mono Variable', monospace;
67
- }
68
-
69
- :root {
70
- --shiki-dark-bg-0: #151515;
71
- --prose-padding-block: 12px;
72
- --prose-padding-inline: 1.5rem;
73
- --prose-radius: 0.5rem;
74
- --prose-diff-add-color: #3dd68c;
75
- --prose-diff-remove-color: #cb7676;
76
- --prose-highlighted-bg-color: rgba(101, 117, 133, 0.16);
77
- --prose-highlighted-word-color: #e6a817;
78
- --prose-focused-opacity: 0.7;
79
- --prose-focused-blur: 0.095rem;
80
- --prose-li-fg: var(--colors-pink-rgb);
81
- }
82
-
83
- .prose h1 {
84
- font-weight: 800;
85
- font-size: 2.25em;
86
- margin-top: 0;
87
- margin-bottom: 0.8888889em;
88
- line-height: 1.1111111;
89
- }
90
-
91
- .prose h2 {
92
- font-weight: 700;
93
- font-size: 1.5em;
94
- margin-top: 2em;
95
- margin-bottom: 1em;
96
- line-height: 1.3333333;
97
- }
98
-
99
- .prose h3 {
100
- color: inherit;
101
- font-weight: 600;
102
- font-size: 1.25em;
103
- margin-top: 1.6em;
104
- margin-bottom: 0.6em;
105
- line-height: 1.6;
106
- opacity: 0.7;
107
- }
108
-
109
- .prose h4 {
110
- color: inherit;
111
- font-weight: 600;
112
- margin-top: 1.5em;
113
- margin-bottom: 0.5em;
114
- line-height: 1.5;
115
- }
116
-
117
- html.dark .prose .has-diff span.diff::before {
118
- position: absolute;
119
- left: calc(var(--prose-padding-inline) / 3);
120
- transition: color 0.35s;
121
- }
122
-
123
- html.dark .prose .has-diff span.diff.add::before {
124
- content: '+';
125
- color: var(--prose-diff-add-color);
126
- }
127
-
128
- html.dark .prose .has-diff span.diff.remove {
129
- opacity: 0.85;
130
-
131
- &::before {
132
- content: '-';
133
- color: var(--prose-diff-remove-color);
134
- }
135
- }
136
-
137
- html.dark .prose .has-highlighted span.highlighted {
138
- background-color: var(--prose-highlighted-bg-color);
139
- transition: background-color 0.35s;
140
- width: calc(100% + (var(--prose-padding-inline) * 2));
141
- display: inline-block;
142
- margin-inline: -1.5rem;
143
- padding-inline: var(--prose-padding-inline);
144
- }
145
-
146
- html.dark .prose .shiki span.highlighted-word {
147
- padding: 1px 3px;
148
- margin: -1px -3px;
149
- border-radius: 3px;
150
- text-decoration: var(--prose-highlighted-word-color) underline;
151
- }
152
-
153
- html.dark .prose .has-focused .line:not(.focused) {
154
- opacity: var(--prose-focused-opacity);
155
- filter: blur(var(--prose-focused-blur));
156
- transition:
157
- opacity 0.35s,
158
- filter 0.35s;
159
- }
160
-
161
- html.dark .prose .has-focused:hover .line:not(.focused) {
162
- opacity: 1;
163
- filter: blur(0);
164
- }
165
-
166
- .prose hr {
167
- height: 1rem;
168
- }
169
-
170
- .prose mark,
171
- .prose code:not(.shiki code) {
172
- background-color: #fe5a1d;
173
- border-radius: 3px;
174
- padding: 1px 3px;
175
- font-size: 0.875rem;
176
- font-weight: 500;
177
- color: marktext;
178
- }
179
-
180
- .prose blockquote {
181
- position: relative;
182
- font-weight: 500;
183
- font-style: italic;
184
- color: inherit;
185
- margin-block: 1.6em;
186
- padding-left: 1em;
187
- padding-block: 0.5em;
188
-
189
- &::before {
190
- position: absolute;
191
- content: '';
192
- width: 0.25rem;
193
- background-color: rgba(125, 125, 125, 0.3);
194
- top: 0.6rem;
195
- bottom: 0.4rem;
196
- border-radius: 3px;
197
- left: 0;
198
- }
199
- }
200
-
201
- .prose > p,
202
- .markdown-alert > p {
203
- margin-block: 1.25em;
204
- }
205
-
206
- .prose .markdown-magic-link {
207
- display: flex;
208
- gap: 3px;
209
- font-size: 0.875rem;
210
- color: rgba(0, 0, 0, 0.55);
211
- align-items: center;
212
-
213
- &.markdown-magic-link-github-at {
214
- background-color: rgba(0, 0, 0, 0.1);
215
- border-radius: 1.5em;
216
- width: fit-content;
217
- padding-right: 0.6em;
218
- transition: background-color 0.35s;
219
-
220
- &:hover {
221
- background-color: rgba(0, 0, 0, 0.15);
222
- }
223
- }
224
-
225
- & .markdown-magic-link-image {
226
- display: inline-block;
227
- width: 1.5em;
228
- height: 1.5em;
229
- background-size: cover;
230
- background-repeat: no-repeat;
231
- background-position: center;
232
- border-radius: 50%;
233
- }
234
- }
235
-
236
- html.dark .prose .markdown-magic-link {
237
- color: rgba(255, 255, 255, 0.55);
238
-
239
- &.markdown-magic-link-github-at {
240
- background-color: rgba(255, 255, 255, 0.1);
241
-
242
- &:hover {
243
- background-color: rgba(255, 255, 255, 0.15);
244
- }
245
- }
246
- }
247
-
248
- .prose ul {
249
- padding: 1rem;
250
-
251
- > li {
252
- position: relative;
253
- padding-inline: 2rem;
254
- padding-bottom: 1.5rem;
255
- font-size: 1.25rem;
256
-
257
- &::before {
258
- position: absolute;
259
- content: '';
260
- width: 0.625rem;
261
- height: 0.625rem;
262
- left: 0;
263
- top: 0.7rem;
264
- border-radius: 50%;
265
- background: rgb(var(--prose-li-fg));
266
- box-shadow: 0 0 0 0.25rem rgb(var(--prose-li-fg) / 0.3);
267
- animation: living 2s infinite;
268
- animation-delay: calc(0.2s * var(--living-delay));
269
- }
270
- &::after {
271
- position: absolute;
272
- content: '';
273
- width: 1px;
274
- height: 100%;
275
- background-color: #a3a3a31a;
276
- left: 0.3125rem;
277
- top: 0.925rem;
278
- z-index: -1;
279
- }
280
- }
281
-
282
- > li:last-child::after {
283
- height: 0;
284
- }
285
- }
286
-
287
- @keyframes living {
288
- 0% {
289
- box-shadow: 0 0 0 0.25rem rgb(var(--prose-li-fg) / 0.3);
290
- }
291
- 50% {
292
- box-shadow: 0 0 0 0.35rem rgb(var(--prose-li-fg) / 0.3);
293
- }
294
- 100% {
295
- box-shadow: 0 0 0 0.25rem rgb(var(--prose-li-fg) / 0.3);
296
- }
297
- }
298
-
299
- .prose ul > li:nth-child(1) {
300
- --living-delay: 0;
301
- }
302
- .prose ul > li:nth-child(2) {
303
- --living-delay: 1;
304
- }
305
- .prose ul > li:nth-child(3) {
306
- --living-delay: 2;
307
- }
308
- .prose ul > li:nth-child(4) {
309
- --living-delay: 3;
310
- }
311
- .prose ul > li:nth-child(5) {
312
- --living-delay: 4;
313
- }
314
-
315
- .prose p > a:not(:has(img, picture, figure, figcaption)) {
316
- position: relative;
317
-
318
- &::after {
319
- position: absolute;
320
- content: '';
321
- width: 0;
322
- height: 3px;
323
- background-color: rgb(var(--colors-d-rgb) / 0.47);
324
- border-radius: var(--spacing);
325
- bottom: -2px;
326
- left: 50%;
327
- transform: translateX(-50%);
328
- transition: width 0.25s;
329
- }
330
- &:hover::after {
331
- width: 95%;
332
- }
333
- }
334
-
335
- .prose p > a.prose-link {
336
- position: relative;
337
-
338
- & [type='detail'] {
339
- color: rgb(var(--colors-nord13-rgb) / 0.37);
340
- > svg {
341
- display: inline;
342
- color: rgb(var(--colors-nord13-rgb) / 0.9);
343
- margin-right: 0.0875em;
344
- }
345
- }
346
- & [type='repo'] {
347
- color: rgb(var(--colors-yellow-rgb) / 0.67);
348
- > svg {
349
- display: inline;
350
- color: rgb(var(--colors-yellow-rgb) / 0.9);
351
- margin-right: 0.0875em;
352
- }
353
- }
354
- & [type='user'] {
355
- color: rgb(var(--colors-pink-rgb) / 0.87);
356
- > svg {
357
- display: inline;
358
- color: rgb(var(--colors-pink-rgb) / 0.9);
359
- margin-right: 0.0875em;
360
- }
361
- }
362
- &:has([type='user'])::after {
363
- background: linear-gradient(-90deg, rgb(var(--colors-pink-rgb) / 0.87), transparent);
364
- }
365
- &:has([type='repo'])::after {
366
- background: linear-gradient(
367
- -90deg,
368
- rgb(var(--colors-pink-rgb) / 0.87),
369
- rgb(var(--colors-yellow-rgb) / 0.67)
370
- );
371
- }
372
- &:has([type='detail'])::after {
373
- background: linear-gradient(
374
- -90deg,
375
- rgb(var(--colors-yellow-rgb) / 0.67),
376
- rgb(var(--colors-nord13-rgb) / 0.37)
377
- );
378
- }
379
- }
380
-
381
- .prose p > a.prose-link > span > svg {
382
- display: inline;
383
- margin-right: 0.0875em;
384
- width: 1em;
385
- height: 1em;
386
- }
1
+ /* Powered by @naiheyoung/use. 奈何*/
2
+ @import '@naiheyoung/color';
3
+
4
+ /* dm-mono-latin-400-normal */
5
+ @font-face {
6
+ font-family: 'DM Mono';
7
+ font-style: normal;
8
+ font-display: swap;
9
+ font-weight: 400;
10
+ src:
11
+ url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-400-normal.woff2)
12
+ format('woff2'),
13
+ url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-400-normal.woff)
14
+ format('woff');
15
+ unicode-range:
16
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
17
+ U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
18
+ }
19
+
20
+ /* dm-mono-latin-500-normal */
21
+ @font-face {
22
+ font-family: 'DM Mono';
23
+ font-style: normal;
24
+ font-display: swap;
25
+ font-weight: 500;
26
+ src:
27
+ url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-500-normal.woff2)
28
+ format('woff2'),
29
+ url(https://cdn.jsdelivr.net/fontsource/fonts/dm-mono@latest/latin-500-normal.woff)
30
+ format('woff');
31
+ unicode-range:
32
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
33
+ U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
34
+ }
35
+
36
+ /* dm-sans-latin-wght-normal */
37
+ @font-face {
38
+ font-family: 'DM Sans Variable';
39
+ font-style: normal;
40
+ font-display: swap;
41
+ font-weight: 100 1000;
42
+ src: url(https://cdn.jsdelivr.net/fontsource/fonts/dm-sans:vf@latest/latin-wght-normal.woff2)
43
+ format('woff2-variations');
44
+ unicode-range:
45
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
46
+ U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
47
+ }
48
+
49
+ /* jetbrains-mono-latin-wght-normal */
50
+ @font-face {
51
+ font-family: 'JetBrains Mono Variable';
52
+ font-style: normal;
53
+ font-display: swap;
54
+ font-weight: 100 800;
55
+ src: url(https://cdn.jsdelivr.net/fontsource/fonts/jetbrains-mono:vf@latest/latin-wght-normal.woff2)
56
+ format('woff2-variations');
57
+ unicode-range:
58
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
59
+ U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
60
+ }
61
+
62
+ :root,
63
+ :host {
64
+ --font-mono: 'DM Mono', monospace;
65
+ --font-sans: 'DM Sans Variable', monospace;
66
+ --font-code: 'JetBrains Mono Variable', monospace;
67
+ }
68
+
69
+ :root {
70
+ --shiki-dark-bg-0: #151515;
71
+ --prose-padding-block: 12px;
72
+ --prose-padding-inline: 1.5rem;
73
+ --prose-radius: 0.5rem;
74
+ --prose-diff-add-color: #3dd68c;
75
+ --prose-diff-remove-color: #cb7676;
76
+ --prose-highlighted-bg-color: rgba(101, 117, 133, 0.16);
77
+ --prose-highlighted-word-color: #e6a817;
78
+ --prose-focused-opacity: 0.7;
79
+ --prose-focused-blur: 0.095rem;
80
+ --prose-li-fg: var(--colors-pink-rgb);
81
+ }
82
+
83
+ .prose h1 {
84
+ font-weight: 800;
85
+ font-size: 2.25em;
86
+ margin-top: 0;
87
+ margin-bottom: 0.8888889em;
88
+ line-height: 1.1111111;
89
+ }
90
+
91
+ .prose h2 {
92
+ font-weight: 700;
93
+ font-size: 1.5em;
94
+ margin-top: 2em;
95
+ margin-bottom: 1em;
96
+ line-height: 1.3333333;
97
+ }
98
+
99
+ .prose h3 {
100
+ color: inherit;
101
+ font-weight: 600;
102
+ font-size: 1.25em;
103
+ margin-top: 1.6em;
104
+ margin-bottom: 0.6em;
105
+ line-height: 1.6;
106
+ opacity: 0.7;
107
+ }
108
+
109
+ .prose h4 {
110
+ color: inherit;
111
+ font-weight: 600;
112
+ margin-top: 1.5em;
113
+ margin-bottom: 0.5em;
114
+ line-height: 1.5;
115
+ }
116
+
117
+ html.dark .prose .has-diff span.diff::before {
118
+ position: absolute;
119
+ left: calc(var(--prose-padding-inline) / 3);
120
+ transition: color 0.35s;
121
+ }
122
+
123
+ html.dark .prose .has-diff span.diff.add::before {
124
+ content: '+';
125
+ color: var(--prose-diff-add-color);
126
+ }
127
+
128
+ html.dark .prose .has-diff span.diff.remove {
129
+ opacity: 0.85;
130
+
131
+ &::before {
132
+ content: '-';
133
+ color: var(--prose-diff-remove-color);
134
+ }
135
+ }
136
+
137
+ html.dark .prose .has-highlighted span.highlighted {
138
+ background-color: var(--prose-highlighted-bg-color);
139
+ transition: background-color 0.35s;
140
+ width: calc(100% + (var(--prose-padding-inline) * 2));
141
+ display: inline-block;
142
+ margin-inline: -1.5rem;
143
+ padding-inline: var(--prose-padding-inline);
144
+ }
145
+
146
+ html.dark .prose .shiki span.highlighted-word {
147
+ padding: 1px 3px;
148
+ margin: -1px -3px;
149
+ border-radius: 3px;
150
+ text-decoration: var(--prose-highlighted-word-color) underline;
151
+ }
152
+
153
+ html.dark .prose .has-focused .line:not(.focused) {
154
+ opacity: var(--prose-focused-opacity);
155
+ filter: blur(var(--prose-focused-blur));
156
+ transition:
157
+ opacity 0.35s,
158
+ filter 0.35s;
159
+ }
160
+
161
+ html.dark .prose .has-focused:hover .line:not(.focused) {
162
+ opacity: 1;
163
+ filter: blur(0);
164
+ }
165
+
166
+ .prose hr {
167
+ height: 1rem;
168
+ }
169
+
170
+ .prose mark,
171
+ .prose code:not(.shiki code) {
172
+ background-color: #fe5a1d;
173
+ border-radius: 3px;
174
+ padding: 1px 3px;
175
+ font-size: 0.875rem;
176
+ font-weight: 500;
177
+ color: marktext;
178
+ }
179
+
180
+ .prose blockquote {
181
+ position: relative;
182
+ font-weight: 500;
183
+ font-style: italic;
184
+ color: inherit;
185
+ margin-block: 1.6em;
186
+ padding-left: 1em;
187
+ padding-block: 0.5em;
188
+
189
+ &::before {
190
+ position: absolute;
191
+ content: '';
192
+ width: 0.25rem;
193
+ background-color: rgba(125, 125, 125, 0.3);
194
+ top: 0.6rem;
195
+ bottom: 0.4rem;
196
+ border-radius: 3px;
197
+ left: 0;
198
+ }
199
+ }
200
+
201
+ .prose > p,
202
+ .markdown-alert > p {
203
+ margin-block: 1.25em;
204
+ }
205
+
206
+ .prose .markdown-magic-link {
207
+ display: flex;
208
+ gap: 3px;
209
+ font-size: 0.875rem;
210
+ color: rgba(0, 0, 0, 0.55);
211
+ align-items: center;
212
+
213
+ &.markdown-magic-link-github-at {
214
+ background-color: rgba(0, 0, 0, 0.1);
215
+ border-radius: 1.5em;
216
+ width: fit-content;
217
+ padding-right: 0.6em;
218
+ transition: background-color 0.35s;
219
+
220
+ &:hover {
221
+ background-color: rgba(0, 0, 0, 0.15);
222
+ }
223
+ }
224
+
225
+ & .markdown-magic-link-image {
226
+ display: inline-block;
227
+ width: 1.5em;
228
+ height: 1.5em;
229
+ background-size: cover;
230
+ background-repeat: no-repeat;
231
+ background-position: center;
232
+ border-radius: 50%;
233
+ }
234
+ }
235
+
236
+ html.dark .prose .markdown-magic-link {
237
+ color: rgba(255, 255, 255, 0.55);
238
+
239
+ &.markdown-magic-link-github-at {
240
+ background-color: rgba(255, 255, 255, 0.1);
241
+
242
+ &:hover {
243
+ background-color: rgba(255, 255, 255, 0.15);
244
+ }
245
+ }
246
+ }
247
+
248
+ .prose ul {
249
+ padding: 1rem;
250
+
251
+ > li {
252
+ position: relative;
253
+ padding-inline: 2rem;
254
+ padding-bottom: 1.5rem;
255
+ font-size: 1.25rem;
256
+
257
+ &::before {
258
+ position: absolute;
259
+ content: '';
260
+ width: 0.625rem;
261
+ height: 0.625rem;
262
+ left: 0;
263
+ top: 0.7rem;
264
+ border-radius: 50%;
265
+ background: rgb(var(--prose-li-fg));
266
+ box-shadow: 0 0 0 0.25rem rgb(var(--prose-li-fg) / 0.3);
267
+ animation: living 2s infinite;
268
+ animation-delay: calc(0.2s * var(--living-delay));
269
+ }
270
+ &::after {
271
+ position: absolute;
272
+ content: '';
273
+ width: 1px;
274
+ height: 100%;
275
+ background-color: #a3a3a31a;
276
+ left: 0.3125rem;
277
+ top: 0.925rem;
278
+ z-index: -1;
279
+ }
280
+ }
281
+
282
+ > li:last-child::after {
283
+ height: 0;
284
+ }
285
+ }
286
+
287
+ @keyframes living {
288
+ 0% {
289
+ box-shadow: 0 0 0 0.25rem rgb(var(--prose-li-fg) / 0.3);
290
+ }
291
+ 50% {
292
+ box-shadow: 0 0 0 0.35rem rgb(var(--prose-li-fg) / 0.3);
293
+ }
294
+ 100% {
295
+ box-shadow: 0 0 0 0.25rem rgb(var(--prose-li-fg) / 0.3);
296
+ }
297
+ }
298
+
299
+ .prose ul > li:nth-child(1) {
300
+ --living-delay: 0;
301
+ }
302
+ .prose ul > li:nth-child(2) {
303
+ --living-delay: 1;
304
+ }
305
+ .prose ul > li:nth-child(3) {
306
+ --living-delay: 2;
307
+ }
308
+ .prose ul > li:nth-child(4) {
309
+ --living-delay: 3;
310
+ }
311
+ .prose ul > li:nth-child(5) {
312
+ --living-delay: 4;
313
+ }
314
+
315
+ .prose p > a:not(:has(img, picture, figure, figcaption)) {
316
+ position: relative;
317
+
318
+ &::after {
319
+ position: absolute;
320
+ content: '';
321
+ width: 0;
322
+ height: 3px;
323
+ background-color: rgb(var(--colors-d-rgb) / 0.47);
324
+ border-radius: var(--spacing);
325
+ bottom: -2px;
326
+ left: 50%;
327
+ transform: translateX(-50%);
328
+ transition: width 0.25s;
329
+ }
330
+ &:hover::after {
331
+ width: 95%;
332
+ }
333
+ }
334
+
335
+ .prose p > a.prose-link {
336
+ position: relative;
337
+
338
+ & [type='detail'] {
339
+ color: rgb(var(--colors-nord13-rgb) / 0.37);
340
+ > svg {
341
+ display: inline;
342
+ color: rgb(var(--colors-nord13-rgb) / 0.9);
343
+ margin-right: 0.0875em;
344
+ }
345
+ }
346
+ & [type='repo'] {
347
+ color: rgb(var(--colors-yellow-rgb) / 0.67);
348
+ > svg {
349
+ display: inline;
350
+ color: rgb(var(--colors-yellow-rgb) / 0.9);
351
+ margin-right: 0.0875em;
352
+ }
353
+ }
354
+ & [type='user'] {
355
+ color: rgb(var(--colors-pink-rgb) / 0.87);
356
+ > svg {
357
+ display: inline;
358
+ color: rgb(var(--colors-pink-rgb) / 0.9);
359
+ margin-right: 0.0875em;
360
+ }
361
+ }
362
+ &:has([type='user'])::after {
363
+ background: linear-gradient(-90deg, rgb(var(--colors-pink-rgb) / 0.87), transparent);
364
+ }
365
+ &:has([type='repo'])::after {
366
+ background: linear-gradient(
367
+ -90deg,
368
+ rgb(var(--colors-pink-rgb) / 0.87),
369
+ rgb(var(--colors-yellow-rgb) / 0.67)
370
+ );
371
+ }
372
+ &:has([type='detail'])::after {
373
+ background: linear-gradient(
374
+ -90deg,
375
+ rgb(var(--colors-yellow-rgb) / 0.67),
376
+ rgb(var(--colors-nord13-rgb) / 0.37)
377
+ );
378
+ }
379
+ }
380
+
381
+ .prose p > a.prose-link > span > svg {
382
+ display: inline;
383
+ margin-right: 0.0875em;
384
+ width: 1em;
385
+ height: 1em;
386
+ }
@@ -0,0 +1,121 @@
1
+ /* Generate by @shikijs/codegen */
2
+ import type {
3
+ DynamicImportLanguageRegistration,
4
+ DynamicImportThemeRegistration,
5
+ HighlighterGeneric
6
+ } from '@shikijs/types'
7
+ import { createBundledHighlighter, createSingletonShorthands } from '@shikijs/core'
8
+ import { createJavaScriptRegexEngine } from '@shikijs/engine-javascript'
9
+ import {
10
+ transformerNotationDiff,
11
+ transformerNotationHighlight,
12
+ transformerNotationWordHighlight,
13
+ transformerNotationFocus,
14
+ transformerMetaHighlight,
15
+ transformerMetaWordHighlight,
16
+ transformerRemoveNotationEscape
17
+ } from '@shikijs/transformers'
18
+
19
+ type BundledLanguage =
20
+ | 'bash'
21
+ | 'sh'
22
+ | 'bat'
23
+ | 'css'
24
+ | 'diff'
25
+ | 'docker'
26
+ | 'html'
27
+ | 'http'
28
+ | 'java'
29
+ | 'js'
30
+ | 'json'
31
+ | 'lua'
32
+ | 'md'
33
+ | 'nginx'
34
+ | 'py'
35
+ | 'ps'
36
+ | 'plain'
37
+ | 'regex'
38
+ | 'sql'
39
+ | 'ts'
40
+ | 'vim'
41
+ | 'vue'
42
+ | 'xml'
43
+ | 'yml'
44
+ type BundledTheme = 'vitesse-dark' | 'vitesse-light'
45
+ type Highlighter = HighlighterGeneric<BundledLanguage, BundledTheme>
46
+
47
+ const bundledLanguages = {
48
+ bash: () => import('@shikijs/langs/shellscript'),
49
+ sh: () => import('@shikijs/langs/shellscript'),
50
+ bat: () => import('@shikijs/langs/bat'),
51
+ css: () => import('@shikijs/langs/css'),
52
+ diff: () => import('@shikijs/langs/diff'),
53
+ docker: () => import('@shikijs/langs/docker'),
54
+ html: () => import('@shikijs/langs/html'),
55
+ http: () => import('@shikijs/langs/http'),
56
+ java: () => import('@shikijs/langs/java'),
57
+ js: () => import('@shikijs/langs/javascript'),
58
+ json: () => import('@shikijs/langs/json'),
59
+ lua: () => import('@shikijs/langs/lua'),
60
+ md: () => import('@shikijs/langs/markdown'),
61
+ nginx: () => import('@shikijs/langs/nginx'),
62
+ py: () => import('@shikijs/langs/python'),
63
+ ps: () => import('@shikijs/langs/powershell'),
64
+ plain: () => import('@shikijs/langs/tex'),
65
+ regex: () => import('@shikijs/langs/regexp'),
66
+ sql: () => import('@shikijs/langs/sql'),
67
+ ts: () => import('@shikijs/langs/typescript'),
68
+ vim: () => import('@shikijs/langs/viml'),
69
+ vue: () => import('@shikijs/langs/vue'),
70
+ xml: () => import('@shikijs/langs/xml'),
71
+ yml: () => import('@shikijs/langs/yaml')
72
+ } as Record<BundledLanguage, DynamicImportLanguageRegistration>
73
+
74
+ const bundledThemes = {
75
+ 'vitesse-dark': () => import('@shikijs/themes/vitesse-dark'),
76
+ 'vitesse-light': () => import('@shikijs/themes/vitesse-light')
77
+ } as Record<BundledTheme, DynamicImportThemeRegistration>
78
+
79
+ const createHighlighter = /* @__PURE__ */ createBundledHighlighter<
80
+ BundledLanguage,
81
+ BundledTheme
82
+ >({
83
+ langs: bundledLanguages,
84
+ themes: bundledThemes,
85
+ engine: () => createJavaScriptRegexEngine()
86
+ })
87
+
88
+ const {
89
+ codeToHtml,
90
+ codeToHast,
91
+ codeToTokensBase,
92
+ codeToTokens,
93
+ codeToTokensWithThemes,
94
+ getSingletonHighlighter,
95
+ getLastGrammarState
96
+ } = /* @__PURE__ */ createSingletonShorthands<BundledLanguage, BundledTheme>(createHighlighter)
97
+
98
+ const transformers = [
99
+ transformerNotationDiff(),
100
+ transformerNotationHighlight(),
101
+ transformerNotationWordHighlight(),
102
+ transformerNotationFocus(),
103
+ transformerMetaHighlight(),
104
+ transformerMetaWordHighlight(),
105
+ transformerRemoveNotationEscape()
106
+ ]
107
+
108
+ export {
109
+ bundledLanguages,
110
+ bundledThemes,
111
+ codeToHast,
112
+ codeToHtml,
113
+ codeToTokens,
114
+ codeToTokensBase,
115
+ codeToTokensWithThemes,
116
+ createHighlighter,
117
+ getLastGrammarState,
118
+ getSingletonHighlighter,
119
+ transformers
120
+ }
121
+ export type { BundledLanguage, BundledTheme, Highlighter }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@naiheyoung/use",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "description": "Files used for personal development.",
5
5
  "homepage": "https://github.com/naiheyoung/use#readme",
6
6
  "author": "Naihe",
@@ -29,8 +29,14 @@
29
29
  "README.md"
30
30
  ],
31
31
  "devDependencies": {
32
+ "@shikijs/core": "^3.21.0",
33
+ "@shikijs/engine-javascript": "^3.21.0",
34
+ "@shikijs/langs": "^3.21.0",
35
+ "@shikijs/themes": "^3.21.0",
36
+ "@shikijs/transformers": "^3.21.0",
37
+ "@shikijs/types": "^3.21.0",
32
38
  "@types/fs-extra": "^11.0.4",
33
- "@types/node": "^25.0.5",
39
+ "@types/node": "^25.0.6",
34
40
  "@types/prompts": "^2.4.9",
35
41
  "cac": "^6.7.14",
36
42
  "chalk": "^5.6.2",
@@ -48,14 +54,6 @@
48
54
  "dependencies": {
49
55
  "@naiheyoung/color": "^1.1.0"
50
56
  },
51
- "peerDependencies": {
52
- "@naiheyoung/color": "^1.1.0"
53
- },
54
- "peerDependenciesMeta": {
55
- "@naiheyoung/color": {
56
- "optional": true
57
- }
58
- },
59
57
  "scripts": {
60
58
  "test": "vitest",
61
59
  "prebuild": "pnpm run format",