@sanity/themer 0.10.1 → 0.10.3

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/bundle.css CHANGED
@@ -1,22 +1,22 @@
1
- @keyframes pcwcs07 {
1
+ @keyframes _1wgm57n7 {
2
2
  50% {
3
3
  filter: blur(6px);
4
4
  }
5
5
  }
6
6
 
7
- @keyframes pcwcs08 {
7
+ @keyframes _1wgm57n8 {
8
8
  to {
9
9
  opacity: 0;
10
10
  }
11
11
  }
12
12
 
13
- @keyframes pcwcs09 {
13
+ @keyframes _1wgm57n9 {
14
14
  from {
15
15
  opacity: 0;
16
16
  }
17
17
  }
18
18
 
19
- @keyframes pcwcs0b {
19
+ @keyframes _1wgm57nb {
20
20
  from {
21
21
  opacity: 0;
22
22
  transform: translateX(-100%);
@@ -27,7 +27,7 @@
27
27
  }
28
28
  }
29
29
 
30
- @keyframes pcwcs0c {
30
+ @keyframes _1wgm57nc {
31
31
  to {
32
32
  opacity: 0;
33
33
  transform: translateX(-100%);
@@ -38,71 +38,71 @@
38
38
  }
39
39
  }
40
40
 
41
- @keyframes pcwcs0d {
41
+ @keyframes _1wgm57nd {
42
42
  from {
43
43
  transform: translateX(100%);
44
44
  }
45
45
  }
46
46
 
47
- @keyframes pcwcs0f {
47
+ @keyframes _1wgm57nf {
48
48
  to {
49
49
  transform: translateX(100%);
50
50
  }
51
51
  }
52
52
 
53
- ::view-transition-new(.pcwcs05) {
53
+ ::view-transition-new(._1wgm57n5) {
54
54
  animation: none;
55
55
  }
56
56
 
57
- ::view-transition-old(.pcwcs05) {
57
+ ::view-transition-old(._1wgm57n5) {
58
58
  display: none;
59
59
  }
60
60
 
61
- ::view-transition-new(.pcwcs06) {
61
+ ::view-transition-new(._1wgm57n6) {
62
62
  object-fit: fill;
63
63
  block-size: 100%;
64
64
  inline-size: 100%;
65
65
  }
66
66
 
67
- ::view-transition-old(.pcwcs06) {
67
+ ::view-transition-old(._1wgm57n6) {
68
68
  object-fit: fill;
69
69
  block-size: 100%;
70
70
  inline-size: 100%;
71
71
  }
72
72
 
73
- ::view-transition-new(.pcwcs0a) {
73
+ ::view-transition-new(._1wgm57na) {
74
74
  object-fit: fill;
75
75
  block-size: 100%;
76
76
  inline-size: 100%;
77
- animation-name: pcwcs09;
77
+ animation-name: _1wgm57n9;
78
78
  }
79
79
 
80
- ::view-transition-old(.pcwcs0a) {
80
+ ::view-transition-old(._1wgm57na) {
81
81
  object-fit: fill;
82
82
  block-size: 100%;
83
83
  inline-size: 100%;
84
- animation-name: pcwcs08;
84
+ animation-name: _1wgm57n8;
85
85
  }
86
86
 
87
- ::view-transition-image-pair(.pcwcs0a) {
88
- animation-name: pcwcs07;
87
+ ::view-transition-image-pair(._1wgm57na) {
88
+ animation-name: _1wgm57n7;
89
89
  animation-timing-function: inherit;
90
90
  }
91
91
 
92
- ::view-transition-new(.pcwcs0e) {
93
- animation-name: pcwcs0d;
92
+ ::view-transition-new(._1wgm57ne) {
93
+ animation-name: _1wgm57nd;
94
94
  }
95
95
 
96
- ::view-transition-old(.pcwcs0g) {
97
- animation-name: pcwcs0f;
96
+ ::view-transition-old(._1wgm57ng) {
97
+ animation-name: _1wgm57nf;
98
98
  }
99
99
 
100
- ::view-transition-new(.pcwcs0h) {
101
- animation-name: pcwcs0b;
100
+ ::view-transition-new(._1wgm57nh) {
101
+ animation-name: _1wgm57nb;
102
102
  }
103
103
 
104
- ::view-transition-old(.pcwcs0i) {
105
- animation-name: pcwcs0c;
104
+ ::view-transition-old(._1wgm57ni) {
105
+ animation-name: _1wgm57nc;
106
106
  }
107
107
 
108
108
  :root:active-view-transition-type(sanity-themer)::view-transition-group(*) {
@@ -110,15 +110,15 @@
110
110
  animation-timing-function: cubic-bezier(.65, 0, .35, 1);
111
111
  }
112
112
 
113
- :root:active-view-transition-type(pcwcs02)::view-transition-group(*) {
113
+ :root:active-view-transition-type(_1wgm57n2)::view-transition-group(*) {
114
114
  animation-duration: .48s;
115
115
  }
116
116
 
117
- :root:active-view-transition-type(pcwcs03)::view-transition-group(*) {
117
+ :root:active-view-transition-type(_1wgm57n3)::view-transition-group(*) {
118
118
  animation-duration: .48s;
119
119
  }
120
120
 
121
- .pcwcs0j {
121
+ ._1wgm57nj {
122
122
  position: relative;
123
123
  }
124
124
 
@@ -143,30 +143,30 @@
143
143
  }
144
144
  }
145
145
 
146
- ._1o50s7t0 {
146
+ ._1e4mp8t0 {
147
147
  scrollbar-gutter: stable;
148
148
  }
149
149
 
150
- ._1aa9huua {
150
+ ._1lkz59pa {
151
151
  aspect-ratio: 16 / 9;
152
152
  position: relative;
153
153
  overflow: hidden;
154
154
  }
155
155
 
156
- ._1aa9huub {
157
- background: var(--_1aa9huu0);
156
+ ._1lkz59pb {
157
+ background: var(--_1lkz59p0);
158
158
  flex-direction: column;
159
159
  display: flex;
160
160
  position: absolute;
161
161
  inset: 0;
162
162
  }
163
163
 
164
- ._1aa9huud {
164
+ ._1lkz59pd {
165
165
  clip-path: polygon(58% 0, 100% 0, 100% 100%, 42% 100%);
166
166
  }
167
167
 
168
- ._1aa9huue {
169
- border-bottom: 1px solid var(--_1aa9huu3);
168
+ ._1lkz59pe {
169
+ border-bottom: 1px solid var(--_1lkz59p3);
170
170
  flex: none;
171
171
  align-items: center;
172
172
  gap: 5px;
@@ -175,41 +175,41 @@
175
175
  display: flex;
176
176
  }
177
177
 
178
- ._1aa9huuf {
179
- background: var(--_1aa9huu4);
178
+ ._1lkz59pf {
179
+ background: var(--_1lkz59p4);
180
180
  border-radius: 2px;
181
181
  flex: none;
182
182
  width: 8px;
183
183
  height: 8px;
184
184
  }
185
185
 
186
- ._1aa9huug {
186
+ ._1lkz59pg {
187
187
  flex: 1;
188
188
  }
189
189
 
190
- ._1aa9huuh {
191
- background: var(--_1aa9huu5);
190
+ ._1lkz59ph {
191
+ background: var(--_1lkz59p5);
192
192
  border-radius: 50%;
193
193
  flex: none;
194
194
  width: 8px;
195
195
  height: 8px;
196
196
  }
197
197
 
198
- ._1aa9huui {
198
+ ._1lkz59pi {
199
199
  flex: 1;
200
200
  min-height: 0;
201
201
  display: flex;
202
202
  }
203
203
 
204
- ._1aa9huuj {
205
- border-right: 1px solid var(--_1aa9huu3);
204
+ ._1lkz59pj {
205
+ border-right: 1px solid var(--_1lkz59p3);
206
206
  flex-direction: column;
207
207
  flex: none;
208
208
  width: 36%;
209
209
  display: flex;
210
210
  }
211
211
 
212
- ._1aa9huuk {
212
+ ._1lkz59pk {
213
213
  flex: none;
214
214
  align-items: center;
215
215
  height: 18%;
@@ -217,18 +217,18 @@
217
217
  display: flex;
218
218
  }
219
219
 
220
- ._1aa9huuk[data-selected="true"] {
221
- background: var(--_1aa9huu6);
220
+ ._1lkz59pk[data-selected="true"] {
221
+ background: var(--_1lkz59p6);
222
222
  }
223
223
 
224
- ._1aa9huul {
224
+ ._1lkz59pl {
225
225
  flex-direction: column;
226
226
  flex: 1;
227
227
  min-width: 0;
228
228
  display: flex;
229
229
  }
230
230
 
231
- ._1aa9huum {
231
+ ._1lkz59pm {
232
232
  flex-direction: column;
233
233
  flex: 1;
234
234
  gap: 7px;
@@ -238,22 +238,22 @@
238
238
  overflow: hidden;
239
239
  }
240
240
 
241
- ._1aa9huun {
241
+ ._1lkz59pn {
242
242
  flex-direction: column;
243
243
  flex: none;
244
244
  gap: 3px;
245
245
  display: flex;
246
246
  }
247
247
 
248
- ._1aa9huuo {
249
- background: var(--_1aa9huu8);
248
+ ._1lkz59po {
249
+ background: var(--_1lkz59p8);
250
250
  height: 12px;
251
- box-shadow: inset 0 0 0 1px var(--_1aa9huu9);
251
+ box-shadow: inset 0 0 0 1px var(--_1lkz59p9);
252
252
  border-radius: 3px;
253
253
  }
254
254
 
255
- ._1aa9huup {
256
- border-top: 1px solid var(--_1aa9huu3);
255
+ ._1lkz59pp {
256
+ border-top: 1px solid var(--_1lkz59p3);
257
257
  flex: none;
258
258
  justify-content: flex-end;
259
259
  align-items: center;
@@ -262,47 +262,47 @@
262
262
  display: flex;
263
263
  }
264
264
 
265
- ._1aa9huuq {
266
- background: var(--_1aa9huu4);
265
+ ._1lkz59pq {
266
+ background: var(--_1lkz59p4);
267
267
  border-radius: 3px;
268
268
  width: 32%;
269
269
  height: 50%;
270
270
  }
271
271
 
272
- ._1aa9huur {
272
+ ._1lkz59pr {
273
273
  border-radius: 2px;
274
274
  flex: none;
275
275
  height: 4px;
276
276
  }
277
277
 
278
- ._1aa9huus {
279
- background: var(--_1aa9huu1);
278
+ ._1lkz59ps {
279
+ background: var(--_1lkz59p1);
280
280
  }
281
281
 
282
- ._1aa9huut {
283
- background: var(--_1aa9huu2);
282
+ ._1lkz59pt {
283
+ background: var(--_1lkz59p2);
284
284
  }
285
285
 
286
- ._1aa9huuu {
287
- background: var(--_1aa9huu7);
286
+ ._1lkz59pu {
287
+ background: var(--_1lkz59p7);
288
288
  }
289
289
 
290
- ._1vdkp0v0 {
290
+ ._17dsl9w0 {
291
291
  opacity: .6;
292
292
  }
293
293
 
294
- ._17s80v42 {
294
+ .xuno562 {
295
295
  grid-template-columns: repeat(3, 24px);
296
296
  grid-auto-rows: 24px;
297
297
  gap: 4px;
298
298
  display: grid;
299
299
  }
300
300
 
301
- ._17s80v42[data-with-image="true"] {
301
+ .xuno562[data-with-image="true"] {
302
302
  grid-template-columns: 52px repeat(3, 24px);
303
303
  }
304
304
 
305
- ._17s80v43 {
305
+ .xuno563 {
306
306
  object-fit: cover;
307
307
  width: 52px;
308
308
  height: 52px;
@@ -312,17 +312,17 @@
312
312
  display: block;
313
313
  }
314
314
 
315
- ._17s80v44 {
315
+ .xuno564 {
316
316
  box-shadow: inset 0 0 0 1px var(--card-border-color);
317
317
  border-radius: 3px;
318
318
  display: block;
319
319
  }
320
320
 
321
- ._17s80v44[data-empty="true"] {
321
+ .xuno564[data-empty="true"] {
322
322
  background: repeating-linear-gradient(-45deg, transparent 0 3px, var(--card-border-color) 3px 4px);
323
323
  }
324
324
 
325
- ._17s80v45 {
325
+ .xuno565 {
326
326
  scroll-snap-type: x mandatory;
327
327
  scrollbar-width: thin;
328
328
  gap: 8px;
@@ -333,10 +333,10 @@
333
333
  overflow-x: auto;
334
334
  }
335
335
 
336
- ._17s80v46 {
336
+ .xuno566 {
337
337
  appearance: none;
338
338
  box-sizing: border-box;
339
- width: calc(var(--_17s80v40) + 8px);
339
+ width: calc(var(--xuno560) + 8px);
340
340
  color: inherit;
341
341
  font: inherit;
342
342
  text-align: center;
@@ -350,14 +350,14 @@
350
350
  display: block;
351
351
  }
352
352
 
353
- ._17s80v46:focus {
353
+ .xuno566:focus {
354
354
  outline: none;
355
355
  }
356
356
 
357
- ._17s80v47 {
357
+ .xuno567 {
358
358
  box-sizing: border-box;
359
- width: calc(var(--_17s80v40) + 8px);
360
- height: calc(var(--_17s80v40) * 9 / 16 + 8px);
359
+ width: calc(var(--xuno560) + 8px);
360
+ height: calc(var(--xuno560) * 9 / 16 + 8px);
361
361
  border-radius: 7px;
362
362
  padding: 4px;
363
363
  transition: box-shadow .1s;
@@ -365,27 +365,27 @@
365
365
  overflow: hidden;
366
366
  }
367
367
 
368
- ._17s80v46:hover ._17s80v47 {
368
+ .xuno566:hover .xuno567 {
369
369
  box-shadow: inset 0 0 0 2px var(--card-border-color);
370
370
  }
371
371
 
372
- ._17s80v46[aria-pressed="true"] ._17s80v47 {
372
+ .xuno566[aria-pressed="true"] .xuno567 {
373
373
  box-shadow: inset 0 0 0 2px var(--card-focus-ring-color);
374
374
  }
375
375
 
376
- ._17s80v46:focus-visible ._17s80v47 {
376
+ .xuno566:focus-visible .xuno567 {
377
377
  outline: 2px solid var(--card-focus-ring-color);
378
378
  outline-offset: -2px;
379
379
  }
380
380
 
381
- ._17s80v48 {
381
+ .xuno568 {
382
382
  width: 144px;
383
- transform: scale(var(--_17s80v41));
383
+ transform: scale(var(--xuno561));
384
384
  transform-origin: 0 0;
385
385
  display: block;
386
386
  }
387
387
 
388
- .os3rj0 {
388
+ ._458rep0 {
389
389
  box-sizing: border-box;
390
390
  border: 1px solid var(--card-border-color);
391
391
  cursor: pointer;
@@ -397,36 +397,36 @@
397
397
  padding: 0;
398
398
  }
399
399
 
400
- .os3rj0::-webkit-color-swatch-wrapper {
400
+ ._458rep0::-webkit-color-swatch-wrapper {
401
401
  padding: 0;
402
402
  }
403
403
 
404
- .os3rj0::-webkit-color-swatch {
404
+ ._458rep0::-webkit-color-swatch {
405
405
  border: none;
406
406
  border-radius: 3px;
407
407
  }
408
408
 
409
- .os3rj0::-moz-color-swatch {
409
+ ._458rep0::-moz-color-swatch {
410
410
  border: none;
411
411
  border-radius: 3px;
412
412
  }
413
413
 
414
- .os3rj1 {
414
+ ._458rep1 {
415
415
  width: 100%;
416
416
  accent-color: var(--card-focus-ring-color);
417
417
  margin: 0;
418
418
  display: block;
419
419
  }
420
420
 
421
- .os3rj2 {
421
+ ._458rep2 {
422
422
  min-width: 0;
423
423
  }
424
424
 
425
- ._1wsn7880 {
425
+ ._4rpwsi0 {
426
426
  position: relative;
427
427
  }
428
428
 
429
- ._1wsn7881 {
429
+ ._4rpwsi1 {
430
430
  appearance: none;
431
431
  box-sizing: border-box;
432
432
  width: 100%;
@@ -441,31 +441,31 @@
441
441
  display: block;
442
442
  }
443
443
 
444
- ._1wsn7881:focus {
444
+ ._4rpwsi1:focus {
445
445
  outline: none;
446
446
  }
447
447
 
448
- ._1wsn7882 {
448
+ ._4rpwsi2 {
449
449
  border-radius: 10px;
450
450
  padding: 4px;
451
451
  transition: box-shadow .1s;
452
452
  display: block;
453
453
  }
454
454
 
455
- ._1wsn7881:hover ._1wsn7882 {
455
+ ._4rpwsi1:hover ._4rpwsi2 {
456
456
  box-shadow: inset 0 0 0 2px var(--card-border-color);
457
457
  }
458
458
 
459
- ._1wsn7881[aria-pressed="true"] ._1wsn7882 {
459
+ ._4rpwsi1[aria-pressed="true"] ._4rpwsi2 {
460
460
  box-shadow: inset 0 0 0 2px var(--card-focus-ring-color);
461
461
  }
462
462
 
463
- ._1wsn7881:focus-visible ._1wsn7882 {
463
+ ._4rpwsi1:focus-visible ._4rpwsi2 {
464
464
  outline: 2px solid var(--card-focus-ring-color);
465
465
  outline-offset: -2px;
466
466
  }
467
467
 
468
- ._1wsn7883 {
468
+ ._4rpwsi3 {
469
469
  opacity: 0;
470
470
  transition: opacity .1s;
471
471
  position: absolute;
@@ -473,27 +473,27 @@
473
473
  right: 10px;
474
474
  }
475
475
 
476
- ._1wsn7880:hover ._1wsn7883, ._1wsn7880:focus-within ._1wsn7883, ._1wsn7883[data-visible="true"] {
476
+ ._4rpwsi0:hover ._4rpwsi3, ._4rpwsi0:focus-within ._4rpwsi3, ._4rpwsi3[data-visible="true"] {
477
477
  opacity: 1;
478
478
  }
479
479
 
480
- ._1wsn7884 {
480
+ ._4rpwsi4 {
481
481
  display: inline-block;
482
482
  }
483
483
 
484
- .bgn4np1 {
484
+ .nzsfns1 {
485
485
  flex: none;
486
486
  }
487
487
 
488
- .bgn4np2 {
488
+ .nzsfns2 {
489
489
  position: relative;
490
490
  }
491
491
 
492
- .bgn4np3 {
493
- container: bgn4np0 / inline-size;
492
+ .nzsfns3 {
493
+ container: nzsfns0 / inline-size;
494
494
  }
495
495
 
496
- .bgn4np4 {
496
+ .nzsfns4 {
497
497
  z-index: 1;
498
498
  cursor: col-resize;
499
499
  touch-action: none;
@@ -504,7 +504,7 @@
504
504
  left: -3px;
505
505
  }
506
506
 
507
- .bgn4np4:after {
507
+ .nzsfns4:after {
508
508
  content: "";
509
509
  background: var(--card-focus-ring-color);
510
510
  opacity: 0;
@@ -516,26 +516,26 @@
516
516
  left: 2px;
517
517
  }
518
518
 
519
- .bgn4np4:focus {
519
+ .nzsfns4:focus {
520
520
  outline: none;
521
521
  }
522
522
 
523
- .bgn4np4:hover:after, .bgn4np4:focus-visible:after, .bgn4np4[data-dragging="true"]:after {
523
+ .nzsfns4:hover:after, .nzsfns4:focus-visible:after, .nzsfns4[data-dragging="true"]:after {
524
524
  opacity: 1;
525
525
  }
526
526
 
527
- .twjqgh0 {
527
+ ._1vaxx8n0 {
528
528
  grid-template-columns: minmax(0, 1fr);
529
529
  gap: 16px;
530
530
  display: grid;
531
531
  }
532
532
 
533
- @container bgn4np0 (width >= 260px) {
534
- .twjqgh0 {
533
+ @container nzsfns0 (width >= 260px) {
534
+ ._1vaxx8n0 {
535
535
  grid-template-columns: repeat(2, minmax(0, 1fr));
536
536
  }
537
537
  }
538
538
 
539
- .c2pqej0 {
539
+ ._13zq9j0 {
540
540
  min-width: 0;
541
541
  }
package/dist/index.d.ts CHANGED
@@ -98,7 +98,7 @@ type GeneratedColorPalettes = Record<ThemeColorSchemeKey, GeneratedColorPalette>
98
98
  *
99
99
  * @public
100
100
  */
101
- declare function buildPalette(options?: BuildThemeOptions): GeneratedColorPalettes;
101
+ export declare function buildPalette(options?: BuildThemeOptions): GeneratedColorPalettes;
102
102
  /**
103
103
  * Generates a Studio theme from a handful of colors per color scheme, by
104
104
  * replacing the color palette that the `buildTheme` from `@sanity/ui/theme`
@@ -138,7 +138,7 @@ declare function buildPalette(options?: BuildThemeOptions): GeneratedColorPalett
138
138
  *
139
139
  * @public
140
140
  */
141
- declare function buildTheme(options?: BuildThemeOptions): RootTheme;
141
+ export declare function buildTheme(options?: BuildThemeOptions): RootTheme;
142
142
  /**
143
143
  * A preset theme: a named set of {@link BuildThemeOptions} ready to pass to
144
144
  * `buildTheme`.
@@ -166,6 +166,6 @@ interface ThemePreset {
166
166
  *
167
167
  * @public
168
168
  */
169
- declare const presets: ThemePreset[];
170
- export { type BuildThemeOptions, type GeneratedColorPalette, type GeneratedColorPalettes, type SchemeThemeOptions, type ThemePreset, buildPalette, buildTheme, presets };
169
+ export declare const presets: ThemePreset[];
170
+ export type { BuildThemeOptions, GeneratedColorPalette, GeneratedColorPalettes, SchemeThemeOptions, ThemePreset };
171
171
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","names":[],"sources":["../src/theme/options.ts","../src/theme/buildPalette.ts","../src/theme/buildTheme.ts","../src/theme/presets.ts"],"mappings":";;;;;;;;;;UAciB;;;;;;;;EAQf;;;;;;;;;;;;;EAcA;;;;;;;;;;EAWA;;;;;;;;;EAUA;;;;;;;;;;;;UAae;;EAEf,OAAO;;EAEP,QAAQ;;;;;;;;KC7BE;EAAyB;EAAe;IAAiB,OACnE,aACA,OAAO;;;;;;KAQG,yBAAyB,OAAO,qBAAqB;;;;;;;;;;;;;;;;;iBAkBjD,aAAa,UAAS,oBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBCvB/C,WAAW,UAAS,oBAAyB;;;;;;;UC1C5C;EACf;EACA;;EAEA,SAAS;;;;;;;;;;;;;;;;;cA6BE,SAAS"}
1
+ {"version":3,"file":"index.d.ts","names":[],"sources":["../src/theme/options.ts","../src/theme/buildPalette.ts","../src/theme/buildTheme.ts","../src/theme/presets.ts"],"mappings":";;;;;;;;;;UAciB;;;;;;;;EAQf;;;;;;;;;;;;;EAcA;;;;;;;;;;EAWA;;;;;;;;;EAUA;;;;;;;;;;;;UAae;;EAEf,OAAO;;EAEP,QAAQ;;;;;;;;KC7BE;EAAyB;EAAe;IAAiB,OACnE,aACA,OAAO;;;;;;KAQG,yBAAyB,OAAO,qBAAqB;;;;;;;;;;;;;;;;;wBAkBjD,aAAa,UAAS,oBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBCvB/C,WAAW,UAAS,oBAAyB;;;;;;;UC1C5C;EACf;EACA;;EAEA,SAAS;;;;;;;;;;;;;;;;;qBA6BE,SAAS"}
package/dist/index.js CHANGED
@@ -1,2 +1 @@
1
- import { n as buildTheme, r as buildPalette, t as presets } from "./presets-CqBgS3A-.js";
2
- export { buildPalette, buildTheme, presets };
1
+ export { r as buildPalette, n as buildTheme, t as presets } from "./presets-CqBgS3A-.js";