-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
Copy pathglobals.css
493 lines (404 loc) · 8.48 KB
/
globals.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
@tailwind base;
@tailwind components;
@tailwind utilities;
:root {
--foreground-rgb: 0, 0, 0;
--background-start-rgb: 214, 219, 220;
--background-end-rgb: 255, 255, 255;
}
@media (prefers-color-scheme: dark) {
:root {
--foreground-rgb: 255, 255, 255;
--background-start-rgb: 0, 0, 0;
--background-end-rgb: 0, 0, 0;
}
}
.conf-hero {
background: linear-gradient(
360deg,
#0e031c 10.63%,
#0e031c 10.65%,
rgba(14, 3, 28, 0) 166.98%
),
url("/img/conf/graphql-conf-bg.png");
@apply text-white max-md:text-base h-[calc(100vh-70px)];
}
.with-arrow:after {
@apply content-['_→'] font-sans text-xl;
@apply transition-all duration-75 hover:ml-1;
}
footer {
@apply !bg-transparent;
}
.nextra-logo {
mask-image: linear-gradient(
60deg,
black 25%,
rgba(0, 0, 0, 0.2) 50%,
black 75%
);
mask-size: 400%;
mask-position: 0;
&:hover {
mask-position: 100%;
transition:
mask-position 1s ease,
-webkit-mask-position 1s ease;
}
}
div[role="menu"][data-headlessui-state] {
@apply left-0 right-auto;
}
div[id^="headlessui-menu-items"] {
@apply rounded-none;
> a {
@apply py-3.5;
}
}
/* should be fixed in Nextra 4 */
._max-w-\[90rem\] {
@apply container;
}
.nextra-nav-container + ._max-w-\[90rem\] {
@apply px-0;
}
/* todo: add ability hide links with displaying sidebar in Nextra */
.nextra-nav-container a[href="/graphql-js/"],
.nextra-menu-mobile li:has(a[href="/graphql-js/"]) {
@apply hidden;
}
.nextra-nav-container > nav {
@apply gap-6;
}
/* Move nav links to the left */
.nextra-nav-container nav {
@apply justify-start;
> a {
@apply first:mr-0 hover:!text-primary;
}
button[id^="headlessui-menu-button"] {
@apply hover:text-primary;
+ div > a {
@apply hover:text-primary;
}
}
.nextra-search {
@apply ml-auto;
+ * {
@apply max-md:ml-auto;
}
}
}
/*._max-w-\[90rem\] {*/
/* !* TODO: maybe add to nextra as option to configure width? *!*/
/* @apply container;*/
/*}*/
.miniGraphiQL {
@apply !shadow-none border-2 dark:border-neutral-900 dark:!bg-neutral-900/10 !rounded-md dark:brightness-200;
}
.result-window {
@apply !shadow-none border-l-2 dark:border-neutral-900 !rounded-none;
}
.variable-editor {
@apply before:!bg-transparent border-t-2 dark:border-neutral-900;
}
.CodeMirror-selected {
@apply !bg-primary/50 dark:bg-primary/40;
}
.CodeMirror-cursor {
@apply dark:border-white;
}
.CodeMirror {
@apply p-2;
}
::selection {
@apply bg-primary/50 dark:bg-primary;
}
@media (prefers-color-scheme: dark) {
body {
/*background: linear-gradient(*/
/* 125deg,*/
/* rgba(234, 117, 195, 0.3) -10%,*/
/* rgba(234, 117, 195, 0) 8%*/
/* ),*/
/* linear-gradient(*/
/* -125deg,*/
/* rgba(234, 117, 195, 0.3) -10%,*/
/* rgba(234, 117, 195, 0) 8%*/
/* ),*/
/* linear-gradient(0deg, #05031c, #05031c);*/
/*@apply bg-gradient-to-b from-primary/10 to-[#05031c]*/
/*background:*/
/* !*linear-gradient(0deg, #05031c, #05031c),*!*/
/* linear-gradient(*/
/* 125.93deg,*/
/* rgba(234, 117, 195, 0.7) -10.45%,*/
/* rgba(234, 117, 195, 0) 28.49%*/
/* ),*/
/* linear-gradient(*/
/* -125.93deg,*/
/* rgba(234, 117, 195, 0.7) -33.25%,*/
/* rgba(234, 117, 195, 0) 26.45%*/
/* );*/
}
}
.donts-images ul {
gap: 0 3em;
@apply flex flex-wrap;
li {
@apply flex gap-3 grow md:basis-1/3;
div {
@apply grow;
}
img {
@apply bg-gray-200 p-4 h-20;
}
}
}
.dos > ul:first-child li:before {
background: url("/img/brand/do.svg");
}
.donts > ul:first-child li:before {
background: url("/img/brand/dont.svg");
}
.dos,
.donts {
@apply mt-6;
> ul ul {
@apply mt-0;
li:before {
@apply grayscale;
}
}
& > ul:first-child li {
@apply list-none relative;
&:before {
@apply size-4 absolute content-[''] top-1 -left-6;
}
}
}
.code-page {
background: linear-gradient(
303.75deg,
rgba(124, 124, 124, 0.2) 0.8%,
rgba(124, 124, 124, 0) 74.17%
),
linear-gradient(0deg, #f8f8f8, #f8f8f8);
}
.dark .code-page {
background: linear-gradient(
303.75deg,
rgba(124, 124, 124, 0.2) 0.8%,
rgba(124, 124, 124, 0) 74.17%
),
linear-gradient(0deg, #1b1b1b, #1b1b1b);
}
.dark .blog-page {
background: linear-gradient(
250.93deg,
rgba(115, 119, 125, 0.1),
rgba(115, 119, 125, 0)
),
#18181b;
}
.blog-page {
background: linear-gradient(
231.79deg,
rgba(225, 0, 152, 0.4) -23.67%,
rgba(225, 0, 152, 0) 25.9%
),
linear-gradient(
113.65deg,
rgba(229, 53, 171, 0.4) -49.55%,
rgba(225, 0, 152, 0) 33.97%
),
linear-gradient(180deg, #f3f4f6 0%, #fff 100%);
}
.conf-heading {
@apply text-3xl lg:text-[50px]/[4rem] font-bold text-balance;
}
.conf-block {
@apply py-14 lg:py-24;
}
.tag {
@apply hover:text-white hover:border-transparent hover:bg-primary;
@apply text-sm border border-current rounded px-2.5 py-1 font-bold transition-colors;
}
.index {
p {
@apply text-lg lg:text-xl/9 mb-5 max-w-2xl;
}
h2 {
@apply text-3xl lg:text-5xl font-bold mb-10 text-balance;
}
pre {
@apply bg-white;
}
}
.add,
.remove {
@apply shadow-[2px_0_currentColor_inset];
}
.add {
@apply !bg-green-200 dark:!bg-green-200/50 text-green-300;
&::before {
@apply absolute start-1.5 content-['+'];
}
}
.remove {
@apply !bg-red-200 dark:!bg-red-200/50 text-red-300;
&::before {
@apply absolute start-1.5 content-['-'];
}
}
.step0,
.step6 {
.v2 {
@apply opacity-0;
}
}
.step1 .v2 code > span:nth-child(5) {
@apply add;
}
.step2 .v3 code > span:nth-child(6) {
@apply add;
}
.step3 .v4 code > {
span:nth-child(7),
span:nth-last-child(-n + 5) {
@apply add;
}
}
.step4 {
.v4 code > span:nth-child(6) {
@apply remove;
}
.v5 code > span:nth-child(6) {
@apply add;
}
}
.index-button {
@apply border border-current rounded-md transition-colors py-2.5 px-6;
&:hover,
&:focus {
@apply bg-primary border-transparent text-white;
}
}
.nextra-codeblocks {
div.nextra-code {
pre {
@apply h-full;
}
&:not(:first-child) {
@apply mt-0;
> div {
@apply first:rounded-l-none;
}
pre {
@apply rounded-l-none;
}
}
&:not(:last-child) {
> div {
@apply first:rounded-r-none;
}
pre {
@apply rounded-r-none;
}
}
}
}
.index-bg {
background: linear-gradient(
303.75deg,
rgba(124, 124, 124, 0.2) 0.8%,
rgba(124, 124, 124, 0) 74.17%
),
linear-gradient(0deg, #f8f8f8, #f8f8f8);
.dark & {
background: linear-gradient(0deg, #111, #111),
linear-gradient(
303.75deg,
rgba(124, 124, 124, 0.2) 0.8%,
rgba(124, 124, 124, 0) 74.17%
);
}
}
.index-gradient {
@apply bg-gradient-to-b from-transparent to-primary/5 dark:to-primary/10;
}
.type-evolution {
@apply w-full overflow-hidden;
#typeEvolveView {
@apply select-none h-full relative left-0 flex;
.v1,
.v2,
.v3,
.v4 {
@apply border-r dark:border-neutral-800 w-1/2 shrink-0;
}
.v5 {
@apply w-full shrink-0;
}
&.step1 {
.v2 {
opacity: 1;
transition: opacity 0.5s ease-in-out;
}
}
&.step2 {
left: calc(-1 * 50%);
transition: left 0.5s ease-in-out;
}
&.step3 {
left: calc(-2 * 50%);
transition: left 0.5s ease-in-out;
}
&.step4 {
left: calc(-3 * 50%);
transition: left 0.5s ease-in-out;
}
&.step5 {
left: calc(-4 * 50%);
transition: left 0.5s ease-in-out;
}
&.step6 {
.v5 {
left: calc(-4 * 50%);
opacity: 0;
transition: opacity 0.5s ease-in-out;
}
}
}
}
.apiIndex {
@apply mt-6;
}
.apiIndex li {
margin: 0 0 5px 0;
}
.apiIndex li a {
color: inherit;
display: block;
position: relative;
text-decoration: none;
}
.apiIndex li a:hover::before {
@apply text-primary;
content: "#";
font-size: 16px;
left: -2em;
line-height: 20px;
position: absolute;
}
.apiIndex li {
@apply bg-white dark:bg-black;
@apply [box-shadow:inset_0_0_0_1px_#ddd,inset_4px_0_0_#ddd];
@apply dark:[box-shadow:inset_0_0_0_1px_#444,inset_4px_0_0_#444];
font-size: 13px;
padding: 7px 14px;
}
/* it means the image is still in loading state */
.gallery-page-images-list img[style*="background-image"] {
filter: blur(3.5px);
}