@nordcode/ui 2.1.9 → 2.2.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/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ ## 2.2.0 (2026-01-03)
2
+
3
+ ### features
4
+
5
+ - simplify dialog styles
6
+ - use ch/lh in few select places (measures, tracking)
7
+ - extend `nc-segmented-control` to be usable for button groups, tabgroups and horizontal controls
8
+
1
9
  ## 2.1.9 (2026-01-02)
2
10
 
3
11
  ### fixes
package/out/bundle.css CHANGED
@@ -12,11 +12,11 @@
12
12
  --line-height-base: 1.55;
13
13
  --line-height-small: 1.1;
14
14
  --tracking-base: normal;
15
- --tracking-tight: -.02em;
16
- --tracking-wide: .03em;
17
- --measure-large: 56em;
18
- --measure-base: 44em;
19
- --measure-small: 28em;
15
+ --tracking-tight: -.04ch;
16
+ --tracking-wide: .06ch;
17
+ --measure-large: 88ch;
18
+ --measure-base: 72ch;
19
+ --measure-small: 44ch;
20
20
  --font-size-smallest: max(.75rem, 12px);
21
21
  --font-size-small: max(.875rem, 14px);
22
22
  --font-size-base: 1rem;
@@ -468,7 +468,7 @@
468
468
  grid-column: 1 / 1;
469
469
  min-block-size: 100%;
470
470
  padding-block-end: 0;
471
- padding-inline-end: 1em;
471
+ padding-inline-end: var(--control-spacing-base, 1em);
472
472
  }
473
473
 
474
474
  :where(dt):not(:last-of-type) {
@@ -966,11 +966,11 @@
966
966
  }
967
967
 
968
968
  :where(.nc-flow) > * {
969
- max-inline-size: var(--flow-base-meassure, 44em);
969
+ max-inline-size: var(--flow-base-meassure, 72ch);
970
970
  }
971
971
 
972
972
  :where(.nc-flow) > :is(h1, h2, h3, h4, h5, h6) {
973
- max-inline-size: var(--flow-headline-meassure, 22em);
973
+ max-inline-size: var(--flow-headline-meassure, 32ch);
974
974
  --flow-gap: 1.5lh;
975
975
  }
976
976
 
@@ -252,7 +252,7 @@
252
252
  grid-column: 1 / 1;
253
253
  min-block-size: 100%;
254
254
  padding-block-end: 0;
255
- padding-inline-end: 1em;
255
+ padding-inline-end: var(--control-spacing-base, 1em);
256
256
  }
257
257
 
258
258
  :where(dt):not(:last-of-type) {
@@ -750,11 +750,11 @@
750
750
  }
751
751
 
752
752
  :where(.nc-flow) > * {
753
- max-inline-size: var(--flow-base-meassure, 44em);
753
+ max-inline-size: var(--flow-base-meassure, 72ch);
754
754
  }
755
755
 
756
756
  :where(.nc-flow) > :is(h1, h2, h3, h4, h5, h6) {
757
- max-inline-size: var(--flow-headline-meassure, 22em);
757
+ max-inline-size: var(--flow-headline-meassure, 32ch);
758
758
  --flow-gap: 1.5lh;
759
759
  }
760
760
 
package/out/complete.css CHANGED
@@ -12,11 +12,11 @@
12
12
  --line-height-base: 1.55;
13
13
  --line-height-small: 1.1;
14
14
  --tracking-base: normal;
15
- --tracking-tight: -.02em;
16
- --tracking-wide: .03em;
17
- --measure-large: 56em;
18
- --measure-base: 44em;
19
- --measure-small: 28em;
15
+ --tracking-tight: -.04ch;
16
+ --tracking-wide: .06ch;
17
+ --measure-large: 88ch;
18
+ --measure-base: 72ch;
19
+ --measure-small: 44ch;
20
20
  --font-size-smallest: max(.75rem, 12px);
21
21
  --font-size-small: max(.875rem, 14px);
22
22
  --font-size-base: 1rem;
@@ -468,7 +468,7 @@
468
468
  grid-column: 1 / 1;
469
469
  min-block-size: 100%;
470
470
  padding-block-end: 0;
471
- padding-inline-end: 1em;
471
+ padding-inline-end: var(--control-spacing-base, 1em);
472
472
  }
473
473
 
474
474
  :where(dt):not(:last-of-type) {
@@ -966,11 +966,11 @@
966
966
  }
967
967
 
968
968
  :where(.nc-flow) > * {
969
- max-inline-size: var(--flow-base-meassure, 44em);
969
+ max-inline-size: var(--flow-base-meassure, 72ch);
970
970
  }
971
971
 
972
972
  :where(.nc-flow) > :is(h1, h2, h3, h4, h5, h6) {
973
- max-inline-size: var(--flow-headline-meassure, 22em);
973
+ max-inline-size: var(--flow-headline-meassure, 32ch);
974
974
  --flow-gap: 1.5lh;
975
975
  }
976
976
 
@@ -1969,6 +1969,8 @@
1969
1969
  :where(.nc-dialog) :where(.dialog-content) {
1970
1970
  padding-inline: var(--_dialog-padding-inline);
1971
1971
  padding-block: var(--spacing-near);
1972
+ overscroll-behavior: contain;
1973
+ scroll-behavior: smooth;
1972
1974
  grid-area: content;
1973
1975
  overflow: auto;
1974
1976
  }
@@ -2457,86 +2459,145 @@
2457
2459
  outline-offset: 0;
2458
2460
  }
2459
2461
 
2462
+ :where(.nc-segmented-control):focus-within:has( > button) {
2463
+ outline: none;
2464
+ }
2465
+
2460
2466
  :where(.nc-segmented-control) input {
2461
2467
  opacity: 0;
2462
2468
  position: absolute;
2463
2469
  }
2464
2470
 
2465
- :where(.nc-segmented-control) label {
2471
+ :where(.nc-segmented-control) > * {
2466
2472
  padding-inline: var(--_input-padding-inline);
2467
2473
  padding-block: var(--_input-padding-block);
2468
2474
  min-block-size: var(--segmented-control-min-height, var(--control-height-base));
2469
2475
  color: var(--_input-color);
2470
2476
  border: var(--_input-border);
2477
+ cursor: pointer;
2478
+ background: none;
2471
2479
  justify-content: center;
2472
2480
  align-items: center;
2473
2481
  display: flex;
2474
2482
  }
2475
2483
 
2476
- :where(.nc-segmented-control) label > .nc-input-label {
2484
+ :where(.nc-segmented-control) > * > .nc-input-label {
2477
2485
  color: inherit;
2478
2486
  }
2479
2487
 
2480
- :where(.nc-segmented-control) label:hover {
2488
+ button:is(:where(.nc-segmented-control) > *) {
2489
+ box-shadow: none;
2490
+ border-radius: 0;
2491
+ transform: none;
2492
+ }
2493
+
2494
+ button:is(:where(.nc-segmented-control) > *):active {
2495
+ scale: 1;
2496
+ }
2497
+
2498
+ button:is(:where(.nc-segmented-control) > *):focus-within {
2499
+ outline-offset: 0;
2500
+ outline: 1px auto;
2501
+ }
2502
+
2503
+ :where(.nc-segmented-control) > *:hover {
2481
2504
  --current-background: var(--_input-hover-background);
2482
2505
  background-color: var(--_input-hover-background);
2483
2506
  }
2484
2507
 
2485
- :where(.nc-segmented-control) label:first-child {
2508
+ :where(.nc-segmented-control) > *:first-child {
2486
2509
  border-radius: var(--_segmented-control-border-radius) var(--_segmented-control-border-radius) 0 0;
2487
2510
  }
2488
2511
 
2489
- :where(.nc-segmented-control) label:last-child {
2512
+ :where(.nc-segmented-control) > *:last-child {
2490
2513
  border-radius: 0 0 var(--_segmented-control-border-radius) var(--_segmented-control-border-radius);
2491
2514
  }
2492
2515
 
2493
- :where(.nc-segmented-control) label:not(:last-child) {
2516
+ :where(.nc-segmented-control) > *:not(:last-child) {
2494
2517
  border-block-end: var(--border-width-thin) solid var(--color-border-muted);
2495
2518
  }
2496
2519
 
2497
- :where(.nc-segmented-control) label:not(:first-child) {
2520
+ :where(.nc-segmented-control) > *:not(:first-child) {
2498
2521
  border-block-start: none;
2499
2522
  }
2500
2523
 
2501
- :where(.nc-segmented-control) label:has(input:checked) {
2524
+ :where(.nc-segmented-control) > *[aria-pressed="true"], :where(.nc-segmented-control) > *[aria-current] {
2502
2525
  background: var(--_segmented-control-checked-surface-color);
2503
2526
  color: var(--_segmented-control-checked-text-color);
2504
2527
  box-shadow: var(--shadow-near);
2528
+ font-weight: var(--font-weight-default);
2505
2529
  }
2506
2530
 
2507
- :where(.nc-segmented-control) label:focus-within {
2531
+ :where(.nc-segmented-control) > *:has(input:checked) {
2532
+ background: var(--_segmented-control-checked-surface-color);
2533
+ color: var(--_segmented-control-checked-text-color);
2534
+ box-shadow: var(--shadow-near);
2535
+ font-weight: var(--font-weight-default);
2536
+ }
2537
+
2538
+ :where(.nc-segmented-control) > *:focus-within {
2508
2539
  outline: none;
2509
2540
  }
2510
2541
 
2511
- :where(.nc-segmented-control) label:has(input:disabled) {
2542
+ :where(.nc-segmented-control) > *:disabled, :where(.nc-segmented-control) > *[aria-disabled="true"] {
2543
+ filter: var(--_input-disabled-filter);
2544
+ cursor: not-allowed;
2545
+ }
2546
+
2547
+ :where(.nc-segmented-control) > *:has(input:disabled) {
2512
2548
  filter: var(--_input-disabled-filter);
2513
2549
  cursor: not-allowed;
2514
2550
  }
2515
2551
 
2516
- @container segmented-control (width >= 32rem) {
2552
+ @container segmented-control (width >= 32rem) or style(--horizontal: true) {
2517
2553
  :where(.nc-segmented-control) {
2518
2554
  grid-auto-columns: 1fr;
2519
2555
  grid-auto-flow: column;
2556
+ inline-size: auto;
2520
2557
  }
2521
2558
 
2522
- :where(.nc-segmented-control) > label:first-child {
2559
+ :where(.nc-segmented-control) > *:first-child {
2523
2560
  border-radius: var(--_segmented-control-border-radius) 0 0 var(--_segmented-control-border-radius);
2524
2561
  }
2525
2562
 
2526
- :where(.nc-segmented-control) > label:last-child {
2563
+ :where(.nc-segmented-control) > *:last-child {
2527
2564
  border-radius: 0 var(--_segmented-control-border-radius) var(--_segmented-control-border-radius) 0;
2528
2565
  }
2529
2566
 
2530
- :where(.nc-segmented-control) > label:not(:last-child) {
2567
+ :where(.nc-segmented-control) > *:not(:last-child) {
2531
2568
  border-block-end: var(--_input-border);
2532
2569
  border-inline-end: var(--border-width-thin) solid var(--color-border-muted);
2533
2570
  }
2534
2571
 
2535
- :where(.nc-segmented-control) > label:not(:first-child) {
2572
+ :where(.nc-segmented-control) > *:not(:first-child) {
2536
2573
  border-block-start: var(--_input-border);
2537
2574
  border-inline-start: none;
2538
2575
  }
2539
2576
  }
2577
+
2578
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) {
2579
+ grid-auto-columns: 1fr;
2580
+ grid-auto-flow: column;
2581
+ inline-size: auto;
2582
+ }
2583
+
2584
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:first-child {
2585
+ border-radius: var(--_segmented-control-border-radius) 0 0 var(--_segmented-control-border-radius);
2586
+ }
2587
+
2588
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:last-child {
2589
+ border-radius: 0 var(--_segmented-control-border-radius) var(--_segmented-control-border-radius) 0;
2590
+ }
2591
+
2592
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:not(:last-child) {
2593
+ border-block-end: var(--_input-border);
2594
+ border-inline-end: var(--border-width-thin) solid var(--color-border-muted);
2595
+ }
2596
+
2597
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:not(:first-child) {
2598
+ border-block-start: var(--_input-border);
2599
+ border-inline-start: none;
2600
+ }
2540
2601
  }
2541
2602
 
2542
2603
  @layer components.input-switch {
@@ -252,7 +252,7 @@
252
252
  grid-column: 1 / 1;
253
253
  min-block-size: 100%;
254
254
  padding-block-end: 0;
255
- padding-inline-end: 1em;
255
+ padding-inline-end: var(--control-spacing-base, 1em);
256
256
  }
257
257
 
258
258
  :where(dt):not(:last-of-type) {
@@ -750,11 +750,11 @@
750
750
  }
751
751
 
752
752
  :where(.nc-flow) > * {
753
- max-inline-size: var(--flow-base-meassure, 44em);
753
+ max-inline-size: var(--flow-base-meassure, 72ch);
754
754
  }
755
755
 
756
756
  :where(.nc-flow) > :is(h1, h2, h3, h4, h5, h6) {
757
- max-inline-size: var(--flow-headline-meassure, 22em);
757
+ max-inline-size: var(--flow-headline-meassure, 32ch);
758
758
  --flow-gap: 1.5lh;
759
759
  }
760
760
 
@@ -1753,6 +1753,8 @@
1753
1753
  :where(.nc-dialog) :where(.dialog-content) {
1754
1754
  padding-inline: var(--_dialog-padding-inline);
1755
1755
  padding-block: var(--spacing-near);
1756
+ overscroll-behavior: contain;
1757
+ scroll-behavior: smooth;
1756
1758
  grid-area: content;
1757
1759
  overflow: auto;
1758
1760
  }
@@ -2241,86 +2243,145 @@
2241
2243
  outline-offset: 0;
2242
2244
  }
2243
2245
 
2246
+ :where(.nc-segmented-control):focus-within:has( > button) {
2247
+ outline: none;
2248
+ }
2249
+
2244
2250
  :where(.nc-segmented-control) input {
2245
2251
  opacity: 0;
2246
2252
  position: absolute;
2247
2253
  }
2248
2254
 
2249
- :where(.nc-segmented-control) label {
2255
+ :where(.nc-segmented-control) > * {
2250
2256
  padding-inline: var(--_input-padding-inline);
2251
2257
  padding-block: var(--_input-padding-block);
2252
2258
  min-block-size: var(--segmented-control-min-height, var(--control-height-base));
2253
2259
  color: var(--_input-color);
2254
2260
  border: var(--_input-border);
2261
+ cursor: pointer;
2262
+ background: none;
2255
2263
  justify-content: center;
2256
2264
  align-items: center;
2257
2265
  display: flex;
2258
2266
  }
2259
2267
 
2260
- :where(.nc-segmented-control) label > .nc-input-label {
2268
+ :where(.nc-segmented-control) > * > .nc-input-label {
2261
2269
  color: inherit;
2262
2270
  }
2263
2271
 
2264
- :where(.nc-segmented-control) label:hover {
2272
+ button:is(:where(.nc-segmented-control) > *) {
2273
+ box-shadow: none;
2274
+ border-radius: 0;
2275
+ transform: none;
2276
+ }
2277
+
2278
+ button:is(:where(.nc-segmented-control) > *):active {
2279
+ scale: 1;
2280
+ }
2281
+
2282
+ button:is(:where(.nc-segmented-control) > *):focus-within {
2283
+ outline-offset: 0;
2284
+ outline: 1px auto;
2285
+ }
2286
+
2287
+ :where(.nc-segmented-control) > *:hover {
2265
2288
  --current-background: var(--_input-hover-background);
2266
2289
  background-color: var(--_input-hover-background);
2267
2290
  }
2268
2291
 
2269
- :where(.nc-segmented-control) label:first-child {
2292
+ :where(.nc-segmented-control) > *:first-child {
2270
2293
  border-radius: var(--_segmented-control-border-radius) var(--_segmented-control-border-radius) 0 0;
2271
2294
  }
2272
2295
 
2273
- :where(.nc-segmented-control) label:last-child {
2296
+ :where(.nc-segmented-control) > *:last-child {
2274
2297
  border-radius: 0 0 var(--_segmented-control-border-radius) var(--_segmented-control-border-radius);
2275
2298
  }
2276
2299
 
2277
- :where(.nc-segmented-control) label:not(:last-child) {
2300
+ :where(.nc-segmented-control) > *:not(:last-child) {
2278
2301
  border-block-end: var(--border-width-thin) solid var(--color-border-muted);
2279
2302
  }
2280
2303
 
2281
- :where(.nc-segmented-control) label:not(:first-child) {
2304
+ :where(.nc-segmented-control) > *:not(:first-child) {
2282
2305
  border-block-start: none;
2283
2306
  }
2284
2307
 
2285
- :where(.nc-segmented-control) label:has(input:checked) {
2308
+ :where(.nc-segmented-control) > *[aria-pressed="true"], :where(.nc-segmented-control) > *[aria-current] {
2286
2309
  background: var(--_segmented-control-checked-surface-color);
2287
2310
  color: var(--_segmented-control-checked-text-color);
2288
2311
  box-shadow: var(--shadow-near);
2312
+ font-weight: var(--font-weight-default);
2289
2313
  }
2290
2314
 
2291
- :where(.nc-segmented-control) label:focus-within {
2315
+ :where(.nc-segmented-control) > *:has(input:checked) {
2316
+ background: var(--_segmented-control-checked-surface-color);
2317
+ color: var(--_segmented-control-checked-text-color);
2318
+ box-shadow: var(--shadow-near);
2319
+ font-weight: var(--font-weight-default);
2320
+ }
2321
+
2322
+ :where(.nc-segmented-control) > *:focus-within {
2292
2323
  outline: none;
2293
2324
  }
2294
2325
 
2295
- :where(.nc-segmented-control) label:has(input:disabled) {
2326
+ :where(.nc-segmented-control) > *:disabled, :where(.nc-segmented-control) > *[aria-disabled="true"] {
2327
+ filter: var(--_input-disabled-filter);
2328
+ cursor: not-allowed;
2329
+ }
2330
+
2331
+ :where(.nc-segmented-control) > *:has(input:disabled) {
2296
2332
  filter: var(--_input-disabled-filter);
2297
2333
  cursor: not-allowed;
2298
2334
  }
2299
2335
 
2300
- @container segmented-control (width >= 32rem) {
2336
+ @container segmented-control (width >= 32rem) or style(--horizontal: true) {
2301
2337
  :where(.nc-segmented-control) {
2302
2338
  grid-auto-columns: 1fr;
2303
2339
  grid-auto-flow: column;
2340
+ inline-size: auto;
2304
2341
  }
2305
2342
 
2306
- :where(.nc-segmented-control) > label:first-child {
2343
+ :where(.nc-segmented-control) > *:first-child {
2307
2344
  border-radius: var(--_segmented-control-border-radius) 0 0 var(--_segmented-control-border-radius);
2308
2345
  }
2309
2346
 
2310
- :where(.nc-segmented-control) > label:last-child {
2347
+ :where(.nc-segmented-control) > *:last-child {
2311
2348
  border-radius: 0 var(--_segmented-control-border-radius) var(--_segmented-control-border-radius) 0;
2312
2349
  }
2313
2350
 
2314
- :where(.nc-segmented-control) > label:not(:last-child) {
2351
+ :where(.nc-segmented-control) > *:not(:last-child) {
2315
2352
  border-block-end: var(--_input-border);
2316
2353
  border-inline-end: var(--border-width-thin) solid var(--color-border-muted);
2317
2354
  }
2318
2355
 
2319
- :where(.nc-segmented-control) > label:not(:first-child) {
2356
+ :where(.nc-segmented-control) > *:not(:first-child) {
2320
2357
  border-block-start: var(--_input-border);
2321
2358
  border-inline-start: none;
2322
2359
  }
2323
2360
  }
2361
+
2362
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) {
2363
+ grid-auto-columns: 1fr;
2364
+ grid-auto-flow: column;
2365
+ inline-size: auto;
2366
+ }
2367
+
2368
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:first-child {
2369
+ border-radius: var(--_segmented-control-border-radius) 0 0 var(--_segmented-control-border-radius);
2370
+ }
2371
+
2372
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:last-child {
2373
+ border-radius: 0 var(--_segmented-control-border-radius) var(--_segmented-control-border-radius) 0;
2374
+ }
2375
+
2376
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:not(:last-child) {
2377
+ border-block-end: var(--_input-border);
2378
+ border-inline-end: var(--border-width-thin) solid var(--color-border-muted);
2379
+ }
2380
+
2381
+ :where(.nc-segmented-control-group.-horizontal) :where(.nc-segmented-control) > *:not(:first-child) {
2382
+ border-block-start: var(--_input-border);
2383
+ border-inline-start: none;
2384
+ }
2324
2385
  }
2325
2386
 
2326
2387
  @layer components.input-switch {
package/package.json CHANGED
@@ -12,7 +12,7 @@
12
12
  "type": "git",
13
13
  "url": "https://github.com/nordcode-agency/nordcode/tree/main/packages/ui"
14
14
  },
15
- "version": "2.1.9",
15
+ "version": "2.2.0",
16
16
  "publishConfig": {
17
17
  "access": "public"
18
18
  },
@@ -131,6 +131,8 @@
131
131
  padding-inline: var(--_dialog-padding-inline);
132
132
  padding-block: var(--spacing-near);
133
133
  overflow: auto;
134
+ overscroll-behavior: contain;
135
+ scroll-behavior: smooth;
134
136
  }
135
137
 
136
138
  :where(.dialog-actions) {
@@ -34,12 +34,16 @@
34
34
  outline-offset: 0;
35
35
  }
36
36
 
37
+ &:focus-within:has(> button) {
38
+ outline: none;
39
+ }
40
+
37
41
  & input {
38
42
  opacity: 0;
39
43
  position: absolute;
40
44
  }
41
45
 
42
- & label {
46
+ & > * {
43
47
  display: flex;
44
48
  padding-inline: var(--_input-padding-inline);
45
49
  padding-block: var(--_input-padding-block);
@@ -48,11 +52,28 @@
48
52
  border: var(--_input-border);
49
53
  align-items: center;
50
54
  justify-content: center;
55
+ cursor: pointer;
56
+ background: none;
51
57
 
52
58
  > .nc-input-label {
53
59
  color: inherit;
54
60
  }
55
61
 
62
+ &button {
63
+ transform: none;
64
+ box-shadow: none;
65
+ border-radius: 0;
66
+
67
+ &:active {
68
+ scale: 1;
69
+ }
70
+
71
+ &:focus-within {
72
+ outline-offset: 0;
73
+ outline: 1px auto;
74
+ }
75
+ }
76
+
56
77
  &:hover {
57
78
  --current-background: var(--_input-hover-background);
58
79
  background-color: var(--_input-hover-background);
@@ -74,29 +95,60 @@
74
95
  border-block-start: none;
75
96
  }
76
97
 
77
- &:has(input:checked) {
98
+ &:has(input:checked), &[aria-pressed="true"], &[aria-current] {
78
99
  background: var(--_segmented-control-checked-surface-color);
79
100
  color: var(--_segmented-control-checked-text-color);
80
101
  box-shadow: var(--shadow-near);
102
+ font-weight: var(--font-weight-default);
81
103
  }
82
104
 
83
105
  &:focus-within {
84
106
  outline: none;
85
107
  }
86
108
 
87
- &:has(input:disabled) {
109
+ &:has(input:disabled), &:disabled, &[aria-disabled="true"] {
88
110
  filter: var(--_input-disabled-filter);
89
111
  cursor: not-allowed;
90
112
  }
91
113
  }
92
114
  }
93
115
 
94
- @container segmented-control (min-width: 32rem) {
116
+ @container segmented-control (min-width: 32rem) or style(--horizontal: true) {
117
+ :where(.nc-segmented-control) {
118
+ grid-auto-columns: 1fr;
119
+ grid-auto-flow: column;
120
+ inline-size: auto;
121
+
122
+ > * {
123
+ &:first-child {
124
+ border-radius: var(--_segmented-control-border-radius) 0 0 var(--_segmented-control-border-radius);
125
+ }
126
+
127
+ &:last-child {
128
+ border-radius: 0 var(--_segmented-control-border-radius) var(--_segmented-control-border-radius) 0;
129
+ }
130
+
131
+ &:not(:last-child) {
132
+ border-block-end: var(--_input-border);
133
+ border-inline-end: var(--border-width-thin) solid var(--color-border-muted);
134
+ }
135
+
136
+ &:not(:first-child) {
137
+ border-block-start: var(--_input-border);
138
+ border-inline-start: none;
139
+ }
140
+ }
141
+ }
142
+ }
143
+
144
+ /* @todo: remove once style container queries are widely supported */
145
+ :where(.nc-segmented-control-group.-horizontal) {
95
146
  :where(.nc-segmented-control) {
96
147
  grid-auto-columns: 1fr;
97
148
  grid-auto-flow: column;
149
+ inline-size: auto;
98
150
 
99
- > label {
151
+ > * {
100
152
  &:first-child {
101
153
  border-radius: var(--_segmented-control-border-radius) 0 0 var(--_segmented-control-border-radius);
102
154
  }
@@ -17,12 +17,12 @@
17
17
  --line-height-small: 1.1;
18
18
 
19
19
  --tracking-base: normal;
20
- --tracking-tight: -0.02em;
21
- --tracking-wide: 0.03em;
20
+ --tracking-tight: -0.04ch;
21
+ --tracking-wide: 0.06ch;
22
22
 
23
- --measure-large: 56em;
24
- --measure-base: 44em;
25
- --measure-small: 28em;
23
+ --measure-large: 88ch;
24
+ --measure-base: 72ch;
25
+ --measure-small: 44ch;
26
26
 
27
27
  --font-size-smallest: max(0.75rem, 12px);
28
28
  --font-size-small: max(0.875rem, 14px);
@@ -113,7 +113,6 @@
113
113
  --lightness-diff: calc(var(--lightness-max) - var(--lightness-min));
114
114
  --lightness-contrast-cutoff: calc(var(--lightness-min) + var(--lightness-diff) * 0.5 + 0.05);
115
115
  --neutral-chroma-scale: 0.95;
116
- --transparency-weaker: 0.8;
117
116
  --c-brand-primary: 0.3;
118
117
  --h-brand-primary: 265;
119
118
  --l-brand-primary-light: 0.56;
@@ -39,7 +39,7 @@
39
39
  @container description-list (min-width: 30rem) {
40
40
  :where(dt) {
41
41
  grid-column: 1 / 1;
42
- padding-inline-end: 1em;
42
+ padding-inline-end: var(--control-spacing-base, 1em);
43
43
  padding-block-end: 0;
44
44
  min-block-size: 100%;
45
45
 
@@ -58,11 +58,11 @@
58
58
  }
59
59
 
60
60
  > * {
61
- max-inline-size: var(--flow-base-meassure, 44em);
61
+ max-inline-size: var(--flow-base-meassure, 72ch);
62
62
  }
63
63
 
64
64
  > *:is(h1, h2, h3, h4, h5, h6) {
65
- max-inline-size: var(--flow-headline-meassure, 22em);
65
+ max-inline-size: var(--flow-headline-meassure, 32ch);
66
66
  --flow-gap: 1.5lh;
67
67
  }
68
68