@sanity/ui 2.0.0-beta.7 → 2.0.0-beta.9

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/theme.js CHANGED
@@ -1263,7 +1263,7 @@ const defaultThemeConfig = {
1263
1263
  switch: {
1264
1264
  width: 25,
1265
1265
  height: 17,
1266
- padding: 2,
1266
+ padding: 5,
1267
1267
  transitionDurationMs: 150,
1268
1268
  transitionTimingFunction: "ease-out",
1269
1269
  focusRing: {
@@ -1998,12 +1998,24 @@ function parseTokenKey(str) {
1998
1998
  }
1999
1999
  return void 0;
2000
2000
  }
2001
+ function isColorMixPercentValue(str) {
2002
+ return /^\d+%$/.test(str);
2003
+ }
2001
2004
  function parseTokenValue(str) {
2002
2005
  const segments = str.split("/");
2003
- const segment0 = segments.shift() || "";
2006
+ let nextSegment = segments.shift() || "";
2007
+ const [segment0, segment0mix] = nextSegment.split(" ");
2004
2008
  if (isColorTintKey(segment0)) {
2005
2009
  const tint = segment0;
2006
2010
  const segment1 = segments.shift() || "";
2011
+ if (isColorMixPercentValue(segment0mix)) {
2012
+ const mix = Number(segment0mix.slice(0, -1)) / 100;
2013
+ return {
2014
+ type: "color",
2015
+ tint,
2016
+ mix
2017
+ };
2018
+ }
2007
2019
  if (isColorOpacityValue(segment1)) {
2008
2020
  const opacity = Number(segment1);
2009
2021
  return {
@@ -2020,6 +2032,14 @@ function parseTokenValue(str) {
2020
2032
  if (isColorValue(segment0)) {
2021
2033
  const key = segment0;
2022
2034
  const segment1 = segments.shift() || "";
2035
+ if (isColorMixPercentValue(segment0mix)) {
2036
+ const mix = Number(segment0mix.slice(0, -1)) / 100;
2037
+ return {
2038
+ type: "color",
2039
+ key,
2040
+ mix
2041
+ };
2042
+ }
2023
2043
  if (isColorOpacityValue(segment1)) {
2024
2044
  const opacity = Number(segment1);
2025
2045
  return {
@@ -2035,15 +2055,24 @@ function parseTokenValue(str) {
2035
2055
  }
2036
2056
  if (isColorHueKey(segment0)) {
2037
2057
  const hue = segment0;
2038
- const segment1 = segments.shift() || "";
2058
+ nextSegment = segments.shift() || "";
2059
+ const [segment1, segment1mix] = nextSegment.split(" ");
2039
2060
  if (isColorTintKey(segment1)) {
2040
2061
  const tint = segment1;
2041
2062
  const segment2 = segments.shift() || "";
2063
+ if (isColorMixPercentValue(segment1mix)) {
2064
+ const mix = Number(segment1mix.slice(0, -1)) / 100;
2065
+ return {
2066
+ type: "color",
2067
+ hue,
2068
+ tint,
2069
+ mix
2070
+ };
2071
+ }
2042
2072
  if (isColorOpacityValue(segment2)) {
2043
2073
  const opacity = Number(segment2);
2044
2074
  return {
2045
2075
  type: "color",
2046
- key: "".concat(hue, "/").concat(tint),
2047
2076
  hue,
2048
2077
  tint,
2049
2078
  opacity
@@ -2051,21 +2080,13 @@ function parseTokenValue(str) {
2051
2080
  }
2052
2081
  return {
2053
2082
  type: "color",
2054
- key: "".concat(hue, "/").concat(tint),
2055
2083
  hue,
2056
2084
  tint
2057
2085
  };
2058
2086
  }
2059
2087
  return {
2060
2088
  type: "hue",
2061
- value: "".concat(hue)
2062
- };
2063
- }
2064
- if (isColorOpacityValue(segment0)) {
2065
- const opacity = Number(segment0);
2066
- return {
2067
- type: "color",
2068
- opacity
2089
+ value: hue
2069
2090
  };
2070
2091
  }
2071
2092
  if (isColorBlendModeValue(segment0)) {
@@ -2109,6 +2130,9 @@ function compileColorTokenValue(node) {
2109
2130
  } else {
2110
2131
  key = "".concat(node.hue, "/").concat(node.tint);
2111
2132
  }
2133
+ if (node.mix !== void 0) {
2134
+ return "".concat(key, " ").concat(node.mix * 100, "%");
2135
+ }
2112
2136
  if (node.opacity !== void 0) {
2113
2137
  key += "/".concat(node.opacity);
2114
2138
  }
@@ -2142,15 +2166,6 @@ const defaultColorTokens = {
2142
2166
  _blend: ["screen", "multiply"],
2143
2167
  bg: ["500", "400"],
2144
2168
  fg: ["white", "black"]
2145
- },
2146
- yellow: {
2147
- bg: ["600", "400"]
2148
- },
2149
- green: {
2150
- bg: ["600", "400"]
2151
- },
2152
- cyan: {
2153
- bg: ["600", "400"]
2154
2169
  }
2155
2170
  },
2156
2171
  backdrop: ["gray/200/0.2", "black/0.5"],
@@ -2162,19 +2177,19 @@ const defaultColorTokens = {
2162
2177
  dot: ["500", "500"]
2163
2178
  },
2164
2179
  positive: {
2165
- bg: ["200/0.6", "900"],
2166
- fg: ["700", "500"]
2180
+ bg: ["200 50%", "900"],
2181
+ fg: ["600", "500"]
2167
2182
  },
2168
2183
  caution: {
2169
- bg: ["200/0.7", "900"],
2170
- fg: ["700", "500"]
2184
+ bg: ["200 50%", "900"],
2185
+ fg: ["600", "500"]
2171
2186
  }
2172
2187
  },
2173
2188
  bg: ["50", "950"],
2174
2189
  border: ["200", "800"],
2175
2190
  code: {
2176
2191
  bg: ["50", "950"],
2177
- fg: ["700", "300"]
2192
+ fg: ["600", "300"]
2178
2193
  },
2179
2194
  fg: ["800", "200"],
2180
2195
  focusRing: ["blue/500", "blue/500"],
@@ -2184,11 +2199,11 @@ const defaultColorTokens = {
2184
2199
  border: ["200", "800"]
2185
2200
  },
2186
2201
  link: {
2187
- fg: ["blue/700", "blue/300"]
2202
+ fg: ["blue/600", "blue/300"]
2188
2203
  },
2189
2204
  muted: {
2190
2205
  bg: ["50", "950"],
2191
- fg: ["600", "400"]
2206
+ fg: ["700 70%", "300 70%"]
2192
2207
  },
2193
2208
  shadow: {
2194
2209
  outline: ["500/0.3", "500/0.4"],
@@ -2198,16 +2213,22 @@ const defaultColorTokens = {
2198
2213
  },
2199
2214
  skeleton: {
2200
2215
  from: ["100", "900"],
2201
- to: ["100/0.5", "900/0.5"]
2216
+ to: ["100 50%", "900 50%"]
2202
2217
  }
2203
2218
  },
2204
2219
  transparent: {
2205
2220
  bg: ["50", "black"],
2206
- fg: ["600", "400"]
2221
+ fg: ["600", "400"],
2222
+ muted: {
2223
+ fg: ["600", "400"]
2224
+ }
2207
2225
  },
2208
2226
  default: {
2209
2227
  bg: ["white", "950"],
2210
- fg: ["black", "200"]
2228
+ fg: ["black", "200"],
2229
+ muted: {
2230
+ fg: ["600", "400"]
2231
+ }
2211
2232
  },
2212
2233
  primary: {
2213
2234
  _hue: "blue"
@@ -2215,20 +2236,17 @@ const defaultColorTokens = {
2215
2236
  positive: {
2216
2237
  _hue: "green",
2217
2238
  shadow: {
2218
- outline: ["600/0.3", "500/0.25"]
2239
+ outline: ["500/0.4", "500/0.4"]
2219
2240
  }
2220
2241
  },
2221
2242
  caution: {
2222
2243
  _hue: "yellow",
2223
2244
  shadow: {
2224
- outline: ["600/0.3", "500/0.25"]
2245
+ outline: ["600/0.3", "500/0.4"]
2225
2246
  }
2226
2247
  },
2227
2248
  critical: {
2228
- _hue: "red",
2229
- shadow: {
2230
- outline: ["500/0.3", "500/0.3"]
2231
- }
2249
+ _hue: "red"
2232
2250
  }
2233
2251
  },
2234
2252
  button: {
@@ -2237,7 +2255,7 @@ const defaultColorTokens = {
2237
2255
  "*": {
2238
2256
  _blend: ["screen", "multiply"],
2239
2257
  accent: {
2240
- fg: ["purple/200", "purple/700"]
2258
+ fg: ["purple/300", "purple/700"]
2241
2259
  },
2242
2260
  badge: {
2243
2261
  "*": {
@@ -2250,8 +2268,8 @@ const defaultColorTokens = {
2250
2268
  bg: ["500", "400"],
2251
2269
  border: ["500/0", "400/0"],
2252
2270
  code: {
2253
- bg: ["500/0.2", "400/0.2"],
2254
- fg: ["200", "700"]
2271
+ bg: ["500 20%", "400 20%"],
2272
+ fg: ["200", "600"]
2255
2273
  },
2256
2274
  fg: ["white", "black"],
2257
2275
  icon: ["200", "800"],
@@ -2264,23 +2282,23 @@ const defaultColorTokens = {
2264
2282
  fg: ["blue/200", "blue/700"]
2265
2283
  },
2266
2284
  muted: {
2267
- bg: ["900", "50"],
2268
- fg: ["200", "700"]
2285
+ bg: ["950", "50"],
2286
+ fg: ["100 70%", "600"]
2269
2287
  },
2270
2288
  skeleton: {
2271
2289
  from: ["900", "100"],
2272
- to: ["900/0.5", "100/0.5"]
2290
+ to: ["900 50%", "100 50%"]
2273
2291
  }
2274
2292
  },
2275
2293
  hovered: {
2276
- bg: ["600", "300"],
2277
- border: ["600/0", "300/0"]
2294
+ bg: ["700", "300"],
2295
+ border: ["700/0", "300/0"]
2278
2296
  },
2279
2297
  pressed: {
2280
- bg: ["700", "200"]
2298
+ bg: ["700", "300"]
2281
2299
  },
2282
2300
  selected: {
2283
- bg: ["700", "200"]
2301
+ bg: ["700", "300"]
2284
2302
  },
2285
2303
  disabled: {
2286
2304
  _hue: "gray",
@@ -2303,7 +2321,11 @@ const defaultColorTokens = {
2303
2321
  },
2304
2322
  default: {
2305
2323
  "*": {
2306
- bg: ["800", "200"]
2324
+ bg: ["800", "200"],
2325
+ muted: {
2326
+ bg: ["950", "50"],
2327
+ fg: ["400", "600"]
2328
+ }
2307
2329
  },
2308
2330
  hovered: {
2309
2331
  bg: ["900", "100"]
@@ -2314,34 +2336,6 @@ const defaultColorTokens = {
2314
2336
  selected: {
2315
2337
  bg: ["black", "white"]
2316
2338
  }
2317
- },
2318
- positive: {
2319
- "*": {
2320
- bg: ["600", "400"]
2321
- },
2322
- hovered: {
2323
- bg: ["700", "300"]
2324
- },
2325
- pressed: {
2326
- bg: ["800", "200"]
2327
- },
2328
- selected: {
2329
- bg: ["800", "200"]
2330
- }
2331
- },
2332
- caution: {
2333
- "*": {
2334
- bg: ["600", "400"]
2335
- },
2336
- hovered: {
2337
- bg: ["700", "300"]
2338
- },
2339
- pressed: {
2340
- bg: ["800", "200"]
2341
- },
2342
- selected: {
2343
- bg: ["800", "200"]
2344
- }
2345
2339
  }
2346
2340
  },
2347
2341
  ghost: {
@@ -2349,7 +2343,7 @@ const defaultColorTokens = {
2349
2343
  "*": {
2350
2344
  _blend: ["multiply", "screen"],
2351
2345
  accent: {
2352
- fg: ["purple/700/0.6", "purple/400/0.8"]
2346
+ fg: ["purple/700 60%", "purple/300 70%"]
2353
2347
  },
2354
2348
  badge: {
2355
2349
  "*": {
@@ -2362,10 +2356,10 @@ const defaultColorTokens = {
2362
2356
  bg: ["50", "950"],
2363
2357
  border: ["100", "900"],
2364
2358
  code: {
2365
- bg: ["500/0.1", "400/0.1"],
2366
- fg: ["700/0.6", "400/0.6"]
2359
+ bg: ["500 10%", "400 10%"],
2360
+ fg: ["700 60%", "400 60%"]
2367
2361
  },
2368
- fg: ["700", "400"],
2362
+ fg: ["600", "400"],
2369
2363
  icon: ["600", "500"],
2370
2364
  kbd: {
2371
2365
  bg: ["white", "black"],
@@ -2373,15 +2367,15 @@ const defaultColorTokens = {
2373
2367
  border: ["200", "800"]
2374
2368
  },
2375
2369
  link: {
2376
- fg: ["blue/700/0.6", "blue/400/0.8"]
2370
+ fg: ["blue/700 60%", "blue/300 60%"]
2377
2371
  },
2378
2372
  muted: {
2379
2373
  bg: ["100", "950"],
2380
- fg: ["700/0.6", "400/0.6"]
2374
+ fg: ["700 60%", "300 60%"]
2381
2375
  },
2382
2376
  skeleton: {
2383
2377
  from: ["100", "900"],
2384
- to: ["100/0.5", "900/0.5"]
2378
+ to: ["100 50%", "900 50%"]
2385
2379
  }
2386
2380
  },
2387
2381
  hovered: {
@@ -2432,12 +2426,12 @@ const defaultColorTokens = {
2432
2426
  },
2433
2427
  positive: {
2434
2428
  "*": {
2435
- border: ["600/0.2", "800"]
2429
+ border: ["600 20%", "800"]
2436
2430
  }
2437
2431
  },
2438
2432
  caution: {
2439
2433
  "*": {
2440
- border: ["600/0.2", "800"]
2434
+ border: ["600 20%", "800"]
2441
2435
  }
2442
2436
  }
2443
2437
  },
@@ -2446,7 +2440,7 @@ const defaultColorTokens = {
2446
2440
  "*": {
2447
2441
  _blend: ["multiply", "screen"],
2448
2442
  accent: {
2449
- fg: ["purple/700/0.7", "purple/300/0.7"]
2443
+ fg: ["purple/700 70%", "purple/300 70%"]
2450
2444
  },
2451
2445
  badge: {
2452
2446
  "*": {
@@ -2463,38 +2457,38 @@ const defaultColorTokens = {
2463
2457
  fg: ["600", "300"]
2464
2458
  },
2465
2459
  fg: ["700", "300"],
2466
- icon: ["700/0.7", "300/0.7"],
2460
+ icon: ["700 70%", "300 70%"],
2467
2461
  kbd: {
2468
2462
  bg: ["white", "black"],
2469
2463
  fg: ["600", "400"],
2470
2464
  border: ["200", "800"]
2471
2465
  },
2472
2466
  link: {
2473
- fg: ["blue/700/0.7", "blue/300/0.7"]
2467
+ fg: ["blue/700 70%", "blue/300 70%"]
2474
2468
  },
2475
2469
  muted: {
2476
2470
  bg: ["100", "950"],
2477
- fg: ["700/0.7", "300/0.7"]
2471
+ fg: ["700 70%", "300 70%"]
2478
2472
  },
2479
2473
  skeleton: {
2480
2474
  from: ["100", "900"],
2481
- to: ["100/0.5", "900/0.5"]
2475
+ to: ["100 50%", "900 50%"]
2482
2476
  }
2483
2477
  },
2484
2478
  hovered: {
2485
2479
  bg: ["50", "950"],
2486
2480
  fg: ["700", "300"],
2487
- icon: ["700/0.7", "400/0.7"]
2481
+ icon: ["700 70%", "400 70%"]
2488
2482
  },
2489
2483
  pressed: {
2490
2484
  bg: ["100", "900"],
2491
2485
  fg: ["800", "200"],
2492
- icon: ["800/0.7", "200/0.7"]
2486
+ icon: ["800 70%", "200 70%"]
2493
2487
  },
2494
2488
  selected: {
2495
2489
  bg: ["100", "900"],
2496
2490
  fg: ["800", "200"],
2497
- icon: ["800/0.7", "200/0.7"]
2491
+ icon: ["800 60%", "200 60%"]
2498
2492
  },
2499
2493
  disabled: {
2500
2494
  _hue: "gray",
@@ -2540,14 +2534,14 @@ const defaultColorTokens = {
2540
2534
  muted: {
2541
2535
  bg: ["50", "950"]
2542
2536
  },
2543
- placeholder: ["400", "600/0.5"]
2537
+ placeholder: ["400", "600 50%"]
2544
2538
  },
2545
2539
  hovered: {
2546
- border: ["300", "800"]
2540
+ border: ["300", "700"]
2547
2541
  },
2548
2542
  readOnly: {
2549
- border: ["200/0", "900/0"],
2550
- bg: ["100", "950"],
2543
+ bg: ["50", "950"],
2544
+ border: ["200", "800"],
2551
2545
  fg: ["800", "200"]
2552
2546
  },
2553
2547
  disabled: {
@@ -2568,26 +2562,16 @@ const defaultColorTokens = {
2568
2562
  _blend: ["multiply", "screen"],
2569
2563
  bg: ["white", "black"],
2570
2564
  fg: ["800", "200"],
2571
- icon: ["700/0.7", "300/0.7"],
2565
+ icon: ["700 70%", "300 70%"],
2572
2566
  avatar: {
2573
2567
  "*": {
2574
2568
  _blend: ["screen", "multiply"],
2575
2569
  bg: ["500", "400"],
2576
2570
  fg: ["white", "black"]
2577
- },
2578
- yellow: {
2579
- bg: ["600", "400"]
2580
- },
2581
- green: {
2582
- bg: ["600", "400"]
2583
- },
2584
- cyan: {
2585
- bg: ["600", "400"]
2586
2571
  }
2587
2572
  },
2588
2573
  badge: {
2589
2574
  "*": {
2590
- // _blend: ['multiply', 'screen'],
2591
2575
  bg: ["100", "900"],
2592
2576
  fg: ["600", "400"],
2593
2577
  dot: ["500", "500"],
@@ -2611,12 +2595,12 @@ const defaultColorTokens = {
2611
2595
  fg: ["blue/700", "blue/300"]
2612
2596
  },
2613
2597
  code: {
2614
- bg: ["100", "950"],
2598
+ bg: ["50", "950"],
2615
2599
  fg: ["700", "300"]
2616
2600
  },
2617
2601
  skeleton: {
2618
2602
  from: ["100", "900"],
2619
- to: ["100/0.5", "900/0.5"]
2603
+ to: ["100 50%", "900 50%"]
2620
2604
  }
2621
2605
  },
2622
2606
  hovered: {
@@ -2636,22 +2620,18 @@ const defaultColorTokens = {
2636
2620
  bg: ["white", "black"],
2637
2621
  fg: ["black", "white"]
2638
2622
  }
2639
- // magenta: {_hue: 'green'},
2640
- // yellow: {bg: ['600', '400']},
2641
- // green: {bg: ['600', '400']},
2642
- // cyan: {bg: ['600', '400']},
2643
2623
  },
2644
2624
  badge: {
2645
2625
  "*": {
2646
- // _blend: ['multiply', 'screen'],
2647
- // _blend: ['screen', 'multiply'],
2648
2626
  bg: ["700", "300"],
2649
- fg: ["white", "black"]
2627
+ fg: ["white", "black"],
2628
+ dot: ["300", "700"],
2629
+ icon: ["300", "700"]
2650
2630
  }
2651
2631
  },
2652
- border: ["500/0.2", "400/0.2"],
2632
+ border: ["500 20%", "400 20%"],
2653
2633
  muted: {
2654
- bg: ["900", "50"],
2634
+ bg: ["950", "50"],
2655
2635
  fg: ["200", "800"]
2656
2636
  },
2657
2637
  accent: {
@@ -2666,86 +2646,76 @@ const defaultColorTokens = {
2666
2646
  fg: ["blue/200", "blue/800"]
2667
2647
  },
2668
2648
  code: {
2669
- bg: ["500/0.2", "400/0.2"],
2670
- fg: ["200", "700"]
2649
+ bg: ["500 20%", "400 20%"],
2650
+ fg: ["300", "700"]
2671
2651
  },
2672
2652
  skeleton: {
2673
2653
  from: ["900", "100"],
2674
- to: ["900/0.5", "100/0.5"]
2654
+ to: ["900 50%", "100 50%"]
2675
2655
  }
2676
- // badge: {
2677
- // '*': {
2678
- // _blend: ['multiply', 'screen'],
2679
- // bg: ['900', '100'],
2680
- // fg: ['white', 'black'],
2681
- // dot: ['700', '300'],
2682
- // icon: ['400', '600'],
2683
- // },
2684
- // },
2685
2656
  },
2686
2657
  disabled: {
2687
2658
  fg: ["200", "800"],
2688
2659
  icon: ["200", "800"],
2689
2660
  muted: {
2690
- fg: ["200", "800/0.5"]
2661
+ fg: ["200", "800"]
2691
2662
  },
2692
2663
  accent: {
2693
- fg: ["purple/200", "purple/800/0.5"]
2664
+ fg: ["purple/200", "purple/800"]
2694
2665
  },
2695
2666
  link: {
2696
- fg: ["blue/200", "blue/800/0.5"]
2667
+ fg: ["blue/200", "blue/800"]
2697
2668
  },
2698
2669
  code: {
2699
- bg: ["100", "950/0.5"],
2700
- fg: ["200", "800/0.5"]
2670
+ bg: ["50", "950"],
2671
+ fg: ["200", "800"]
2701
2672
  }
2702
2673
  }
2703
2674
  },
2704
2675
  default: {
2705
2676
  selected: {
2706
2677
  _hue: "blue"
2707
- // bg: ['500', '400'],
2708
2678
  }
2709
2679
  },
2710
2680
  critical: {
2711
2681
  disabled: {
2712
- bg: ["50/0.5", "950/0.5"]
2682
+ bg: ["50 50%", "950 50%"]
2713
2683
  }
2714
2684
  }
2715
2685
  },
2716
2686
  syntax: {
2717
2687
  atrule: ["purple/600", "purple/400"],
2718
- attrName: ["green/700", "green/400"],
2719
- attrValue: ["yellow/700", "yellow/400"],
2720
- attribute: ["yellow/700", "yellow/400"],
2688
+ attrName: ["green/600", "green/400"],
2689
+ attrValue: ["yellow/600", "yellow/400"],
2690
+ attribute: ["yellow/600", "yellow/400"],
2721
2691
  boolean: ["purple/600", "purple/400"],
2722
2692
  builtin: ["purple/600", "purple/400"],
2723
- cdata: ["yellow/700", "yellow/400"],
2724
- char: ["yellow/700", "yellow/400"],
2725
- class: ["orange/700", "orange/400"],
2726
- className: ["cyan/700", "cyan/400"],
2693
+ cdata: ["yellow/600", "yellow/400"],
2694
+ char: ["yellow/600", "yellow/400"],
2695
+ class: ["orange/600", "orange/400"],
2696
+ className: ["cyan/600", "cyan/400"],
2727
2697
  comment: ["gray/400", "gray/600"],
2728
2698
  constant: ["purple/600", "purple/400"],
2729
2699
  deleted: ["red/600", "red/400"],
2730
2700
  entity: ["red/600", "red/400"],
2731
- function: ["green/700", "green/400"],
2701
+ function: ["green/600", "green/400"],
2732
2702
  hexcode: ["blue/600", "blue/400"],
2733
2703
  id: ["purple/600", "purple/400"],
2734
2704
  important: ["purple/600", "purple/400"],
2735
- inserted: ["yellow/700", "yellow/400"],
2705
+ inserted: ["yellow/600", "yellow/400"],
2736
2706
  keyword: ["magenta/600", "magenta/400"],
2737
2707
  number: ["purple/600", "purple/400"],
2738
2708
  operator: ["magenta/600", "magenta/400"],
2739
2709
  property: ["blue/600", "blue/400"],
2740
- pseudoClass: ["yellow/700", "yellow/400"],
2741
- pseudoElement: ["yellow/700", "yellow/400"],
2710
+ pseudoClass: ["yellow/600", "yellow/400"],
2711
+ pseudoElement: ["yellow/600", "yellow/400"],
2742
2712
  punctuation: ["gray/600", "gray/400"],
2743
2713
  regex: ["blue/600", "blue/400"],
2744
2714
  selector: ["red/600", "red/400"],
2745
- string: ["yellow/700", "yellow/400"],
2715
+ string: ["yellow/600", "yellow/400"],
2746
2716
  symbol: ["purple/600", "purple/400"],
2747
2717
  tag: ["red/600", "red/400"],
2748
- unit: ["orange/700", "orange/400"],
2718
+ unit: ["orange/600", "orange/400"],
2749
2719
  url: ["red/600", "red/400"],
2750
2720
  variable: ["red/600", "red/400"]
2751
2721
  }
@@ -3886,6 +3856,11 @@ function renderColorValue(str, options) {
3886
3856
  };
3887
3857
  try {
3888
3858
  hex = mixThemeColor(hex, mixOptions);
3859
+ if (bg && node.mix !== void 0) {
3860
+ const from = hexToRgb(bg);
3861
+ const to = hexToRgb(hex);
3862
+ hex = rgbToHex(mix(from, to, node.mix));
3863
+ }
3889
3864
  } catch (err) {
3890
3865
  console.warn("could not blend", hex, mixOptions);
3891
3866
  throw err;