@scalewing/react 1.21.0 → 1.22.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.
Files changed (65) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/README.md +46 -4
  3. package/dist/components/ActionMenu.d.ts +13 -1
  4. package/dist/components/ActionMenu.js +2 -2
  5. package/dist/components/BarChart.d.ts +28 -0
  6. package/dist/components/BarChart.js +5 -4
  7. package/dist/components/CalendarButton.d.ts +10 -0
  8. package/dist/components/CalendarButton.js +4 -3
  9. package/dist/components/DenominationGrid.d.ts +2 -2
  10. package/dist/components/DenominationGrid.js +5 -2
  11. package/dist/components/Field.d.ts +9 -0
  12. package/dist/components/Field.js +3 -2
  13. package/dist/components/SectionNav.d.ts +44 -0
  14. package/dist/components/SectionNav.js +48 -0
  15. package/dist/components/Table.d.ts +38 -13
  16. package/dist/components/Table.js +7 -12
  17. package/dist/components/Tabs.d.ts +3 -1
  18. package/dist/components/Tabs.js +8 -2
  19. package/dist/components/Tooltip.js +19 -3
  20. package/dist/components/action-menu/ActionMenuList.d.ts +3 -2
  21. package/dist/components/action-menu/ActionMenuList.js +16 -4
  22. package/dist/components/date-field/CalendarDialog.d.ts +4 -1
  23. package/dist/components/date-field/CalendarDialog.js +2 -2
  24. package/dist/components/date-field/CalendarGrid.d.ts +4 -1
  25. package/dist/components/date-field/CalendarGrid.js +11 -3
  26. package/dist/components/denomination-grid/DenominationStrip.d.ts +2 -2
  27. package/dist/components/denomination-grid/DenominationStrip.js +17 -6
  28. package/dist/components/denomination-grid/types.d.ts +15 -2
  29. package/dist/components/table/TableCell.d.ts +42 -0
  30. package/dist/components/table/TableCell.js +27 -0
  31. package/dist/components/table/table-layout.d.ts +10 -0
  32. package/dist/components/table/table-layout.js +14 -0
  33. package/dist/components/tooltip/tooltip-open.d.ts +8 -0
  34. package/dist/components/tooltip/tooltip-open.js +60 -0
  35. package/dist/components/tooltip/use-tooltip-placement.d.ts +11 -0
  36. package/dist/components/tooltip/use-tooltip-placement.js +46 -0
  37. package/dist/components/use-anchored-popover.d.ts +2 -0
  38. package/dist/components/use-anchored-popover.js +2 -1
  39. package/dist/css/css-action-menu.js +24 -0
  40. package/dist/css/css-chart.js +45 -1
  41. package/dist/css/css-components.js +3 -0
  42. package/dist/css/css-date-field.js +47 -1
  43. package/dist/css/css-denomination-aligned.d.ts +7 -0
  44. package/dist/css/css-denomination-aligned.js +68 -0
  45. package/dist/css/css-denomination-grid.js +7 -1
  46. package/dist/css/css-field.js +14 -0
  47. package/dist/css/css-scroll-region.d.ts +8 -0
  48. package/dist/css/css-scroll-region.js +9 -3
  49. package/dist/css/css-section-nav.d.ts +4 -0
  50. package/dist/css/css-section-nav.js +120 -0
  51. package/dist/css/css-table-layout.d.ts +20 -0
  52. package/dist/css/css-table-layout.js +59 -0
  53. package/dist/css/css-table-sort.d.ts +2 -0
  54. package/dist/css/css-table-sort.js +105 -0
  55. package/dist/css/css-table.js +8 -0
  56. package/dist/css/css-tabs.d.ts +6 -1
  57. package/dist/css/css-tabs.js +9 -1
  58. package/dist/css/css-tooltip.js +7 -4
  59. package/dist/css/stylesheet.js +2 -0
  60. package/dist/date-only.d.ts +12 -0
  61. package/dist/date-only.js +24 -0
  62. package/dist/index.d.ts +4 -3
  63. package/dist/index.js +1 -0
  64. package/dist/styles.css +363 -6
  65. package/package.json +1 -1
package/dist/styles.css CHANGED
@@ -1420,6 +1420,121 @@ body {
1420
1420
  padding: var(--sw-space-1) var(--sw-space-2);
1421
1421
  }
1422
1422
 
1423
+ .sw-table-fixed {
1424
+ table-layout: fixed;
1425
+ }
1426
+
1427
+ .sw-table .sw-table-col-min {
1428
+ white-space: nowrap;
1429
+ width: 1%;
1430
+ }
1431
+
1432
+ .sw-table-fixed .sw-table-col-min {
1433
+ width: auto;
1434
+ }
1435
+
1436
+ .sw-table .sw-table-col-xs { width: 4rem; }
1437
+ .sw-table .sw-table-col-sm { width: 6rem; }
1438
+ .sw-table .sw-table-col-md { width: 8rem; }
1439
+ .sw-table .sw-table-col-lg { width: 12rem; }
1440
+ .sw-table .sw-table-col-xl { width: 16rem; }
1441
+
1442
+ .sw-table.sw-table-top th,
1443
+ .sw-table.sw-table-top td {
1444
+ vertical-align: top;
1445
+ }
1446
+
1447
+ .sw-table-sort {
1448
+ align-items: center;
1449
+ appearance: none;
1450
+ background: transparent;
1451
+ border: 0;
1452
+ border-radius: var(--sw-radius-sm);
1453
+ color: inherit;
1454
+ cursor: pointer;
1455
+ display: inline-flex;
1456
+ font: inherit;
1457
+ gap: var(--sw-space-1);
1458
+ letter-spacing: inherit;
1459
+ /* A step of room for the focus ring, taken back so the name stays on the cell's edge. */
1460
+ margin-inline: calc(-1 * var(--sw-space-1));
1461
+ min-height: var(--sw-control-xs-min-height);
1462
+ padding: 0 var(--sw-space-1);
1463
+ text-align: inherit;
1464
+ }
1465
+
1466
+ .sw-table .sw-table-numeric .sw-table-sort,
1467
+ .sw-table .sw-table-end .sw-table-sort {
1468
+ flex-direction: row-reverse;
1469
+ }
1470
+
1471
+ .sw-table-sort:hover,
1472
+ .sw-table th[aria-sort] .sw-table-sort {
1473
+ color: var(--sw-color-text);
1474
+ }
1475
+
1476
+ .sw-table-sort:focus-visible {
1477
+ outline: var(--sw-focus-ring-width) solid var(--sw-color-accent);
1478
+ outline-offset: var(--sw-focus-ring-offset);
1479
+ }
1480
+
1481
+ .sw-table-sort-glyph {
1482
+ align-items: center;
1483
+ display: inline-flex;
1484
+ flex: none;
1485
+ flex-direction: column;
1486
+ justify-content: center;
1487
+ min-height: var(--sw-space-4);
1488
+ width: var(--sw-space-2);
1489
+ }
1490
+
1491
+ .sw-table-sort-ascending::before,
1492
+ .sw-table-sort-none::before {
1493
+ content: '';
1494
+ border-bottom: 2px solid var(--sw-color-muted);
1495
+ border-right: 2px solid var(--sw-color-muted);
1496
+ box-sizing: border-box;
1497
+ height: var(--sw-space-2);
1498
+ width: var(--sw-space-2);
1499
+ border-color: currentColor;
1500
+ display: block;
1501
+ margin-top: calc(var(--sw-space-1) / 2);
1502
+ transform: rotate(-135deg);
1503
+ }
1504
+
1505
+ .sw-table-sort-descending::after,
1506
+ .sw-table-sort-none::after {
1507
+ content: '';
1508
+ border-bottom: 2px solid var(--sw-color-muted);
1509
+ border-right: 2px solid var(--sw-color-muted);
1510
+ box-sizing: border-box;
1511
+ height: var(--sw-space-2);
1512
+ width: var(--sw-space-2);
1513
+ border-color: currentColor;
1514
+ display: block;
1515
+ margin-bottom: calc(var(--sw-space-1) / 2);
1516
+ transform: rotate(45deg);
1517
+ }
1518
+
1519
+ .sw-table-sort-none {
1520
+ opacity: var(--sw-quiet-opacity);
1521
+ }
1522
+
1523
+ .sw-table-sort-none::before,
1524
+ .sw-table-sort-none::after {
1525
+ height: calc(var(--sw-space-2) * 0.75);
1526
+ width: calc(var(--sw-space-2) * 0.75);
1527
+ }
1528
+
1529
+ @media (pointer: coarse) {
1530
+ .sw-table-sort { min-height: var(--sw-control-md-min-height); }
1531
+ }
1532
+
1533
+ @media (forced-colors: active) {
1534
+ .sw-table-sort { color: ButtonText; }
1535
+ .sw-table-sort-none { opacity: 1; }
1536
+ }
1537
+
1423
1538
  .sw-table-row-selected > :first-child {
1424
1539
  position: relative;
1425
1540
  }
@@ -1658,16 +1773,51 @@ body {
1658
1773
  background: color-mix(in srgb, var(--sw-color-muted) 16%, transparent);
1659
1774
  }
1660
1775
 
1776
+ /*
1777
+ * A range's days are one band in each week row: square-cornered, the accent
1778
+ * at 16 % over the calendar's glass, rounded at the range's start and end.
1779
+ * accentSubtle is mixed against the surface, not the glass, and fades to
1780
+ * nothing where the accent is near AA, so the band would vanish in most
1781
+ * dark palettes. Every number on the band is in the text colour, which
1782
+ * keeps 4.5:1 on it in every palette (muted and accent do not); a
1783
+ * neighbouring month's day and today are marked by the band and today's
1784
+ * accent ring (3:1 or more on the band). The selected day sits on top.
1785
+ */
1786
+ .sw-date-field-day-in-range {
1787
+ background: color-mix(in srgb, var(--sw-color-accent) 16%, transparent);
1788
+ border-radius: 0;
1789
+ color: var(--sw-color-text);
1790
+ }
1791
+
1792
+ .sw-date-field-day-range-start {
1793
+ border-end-start-radius: var(--sw-radius-pill);
1794
+ border-start-start-radius: var(--sw-radius-pill);
1795
+ }
1796
+
1797
+ .sw-date-field-day-range-end {
1798
+ border-end-end-radius: var(--sw-radius-pill);
1799
+ border-start-end-radius: var(--sw-radius-pill);
1800
+ }
1801
+
1661
1802
  .sw-date-field-day[aria-current='date'] {
1662
1803
  border-color: var(--sw-color-accent);
1663
1804
  color: var(--sw-color-accent);
1664
1805
  font-weight: 600;
1665
1806
  }
1666
1807
 
1808
+ .sw-date-field-day-in-range[aria-current='date'] {
1809
+ color: var(--sw-color-text);
1810
+ }
1811
+
1812
+ .sw-date-field-day-in-range:hover:not([aria-disabled='true']) {
1813
+ background: color-mix(in srgb, var(--sw-color-accent) 24%, transparent);
1814
+ }
1815
+
1667
1816
  .sw-date-field-day[aria-selected='true'],
1668
1817
  .sw-date-field-day[aria-selected='true']:hover {
1669
1818
  background: var(--sw-color-accent);
1670
1819
  border-color: var(--sw-color-accent);
1820
+ border-radius: var(--sw-radius-pill);
1671
1821
  color: var(--sw-color-onAccent);
1672
1822
  font-weight: 600;
1673
1823
  }
@@ -1709,7 +1859,15 @@ body {
1709
1859
  }
1710
1860
  .sw-date-field-calendar { border-color: CanvasText; }
1711
1861
  .sw-date-field-day[aria-current='date'] { border-color: CanvasText; }
1712
- .sw-date-field-day[aria-selected='true'] {
1862
+ .sw-date-field-day-in-range,
1863
+ .sw-date-field-day-in-range:hover:not([aria-disabled='true']),
1864
+ .sw-date-field-day-in-range[aria-current='date'] {
1865
+ background: Mark;
1866
+ color: MarkText;
1867
+ forced-color-adjust: none;
1868
+ }
1869
+ .sw-date-field-day[aria-selected='true'],
1870
+ .sw-date-field-day[aria-selected='true']:hover {
1713
1871
  background: Highlight;
1714
1872
  color: HighlightText;
1715
1873
  forced-color-adjust: none;
@@ -1818,6 +1976,38 @@ body {
1818
1976
  justify-content: space-between;
1819
1977
  }
1820
1978
 
1979
+ .sw-bar-chart-diverging .sw-bar-chart-track {
1980
+ position: relative;
1981
+ }
1982
+
1983
+ .sw-bar-chart-diverging .sw-bar-chart-track::before {
1984
+ background: var(--sw-color-border);
1985
+ content: '';
1986
+ inset-block: 0;
1987
+ inset-inline-start: 50%;
1988
+ position: absolute;
1989
+ width: 1px;
1990
+ }
1991
+
1992
+ .sw-bar-chart-diverging .sw-bar-chart-fill {
1993
+ border-end-start-radius: 0;
1994
+ border-start-start-radius: 0;
1995
+ margin-inline-start: 50%;
1996
+ width: calc(var(--sw-bar-fill, 0) * 50%);
1997
+ }
1998
+
1999
+ .sw-bar-chart-diverging .sw-bar-chart-fill-negative {
2000
+ border-end-end-radius: 0;
2001
+ border-end-start-radius: inherit;
2002
+ border-start-end-radius: 0;
2003
+ border-start-start-radius: inherit;
2004
+ margin-inline-start: calc(50% - var(--sw-bar-fill, 0) * 50%);
2005
+ }
2006
+
2007
+ @media (forced-colors: active) {
2008
+ .sw-bar-chart-diverging .sw-bar-chart-track::before { background: CanvasText; }
2009
+ }
2010
+
1821
2011
  .sw-app-header {
1822
2012
  background: var(--sw-glass-fill);
1823
2013
  border: 1px solid var(--sw-glass-border);
@@ -1870,6 +2060,88 @@ body {
1870
2060
  );
1871
2061
  }
1872
2062
 
2063
+ .sw-section-nav-list {
2064
+ border-bottom: 1px solid var(--sw-color-border);
2065
+ display: flex;
2066
+ flex-wrap: wrap;
2067
+ gap: var(--sw-space-1) var(--sw-space-2);
2068
+ list-style: none;
2069
+ margin: 0;
2070
+ padding: 0;
2071
+ }
2072
+
2073
+ [data-theme] .sw-section-nav-link {
2074
+ align-items: center;
2075
+ border-bottom: 2px solid transparent;
2076
+ border-radius: var(--sw-radius-sm) var(--sw-radius-sm) 0 0;
2077
+ box-sizing: border-box;
2078
+ color: var(--sw-color-muted);
2079
+ display: inline-flex;
2080
+ font-family: var(--sw-font-sans);
2081
+ font-size: 15px;
2082
+ font-weight: 600;
2083
+ gap: var(--sw-space-2);
2084
+ letter-spacing: -0.2px;
2085
+ line-height: 20px;
2086
+ margin-bottom: -1px;
2087
+ min-height: var(--sw-control-sm-min-height);
2088
+ padding-inline: var(--sw-control-xs-padding-inline);
2089
+ text-decoration: none;
2090
+ }
2091
+
2092
+ [data-theme] .sw-section-nav-link:hover {
2093
+ background: color-mix(in srgb, var(--sw-color-muted) 12%, transparent);
2094
+ color: var(--sw-color-text);
2095
+ }
2096
+
2097
+ [data-theme] .sw-section-nav-link:focus-visible {
2098
+ outline: var(--sw-focus-ring-width) solid var(--sw-color-accent);
2099
+ outline-offset: calc(-1 * var(--sw-focus-ring-width));
2100
+ }
2101
+
2102
+ [data-theme] .sw-section-nav-link[aria-current] {
2103
+ border-bottom-color: var(--sw-color-accent);
2104
+ color: var(--sw-color-text);
2105
+ }
2106
+
2107
+ .sw-section-nav-icon {
2108
+ display: inline-flex;
2109
+ flex: none;
2110
+ }
2111
+
2112
+ @media (min-width: 48rem) {
2113
+ .sw-section-nav-vertical-from-md .sw-section-nav-list {
2114
+ border-bottom: 0;
2115
+ flex-direction: column;
2116
+ gap: var(--sw-space-1);
2117
+ }
2118
+
2119
+ .sw-section-nav-vertical-from-md .sw-section-nav-link {
2120
+ border-bottom: 0;
2121
+ border-inline-start: 2px solid transparent;
2122
+ border-radius: 0 var(--sw-radius-sm) var(--sw-radius-sm) 0;
2123
+ margin-bottom: 0;
2124
+ width: 100%;
2125
+ }
2126
+
2127
+ .sw-section-nav-vertical-from-md .sw-section-nav-link:dir(rtl) {
2128
+ border-radius: var(--sw-radius-sm) 0 0 var(--sw-radius-sm);
2129
+ }
2130
+
2131
+ .sw-section-nav-vertical-from-md .sw-section-nav-link[aria-current] {
2132
+ border-inline-start-color: var(--sw-color-accent);
2133
+ }
2134
+ }
2135
+
2136
+ @media (pointer: coarse) {
2137
+ [data-theme] .sw-section-nav-link { min-height: var(--sw-control-md-min-height); }
2138
+ }
2139
+
2140
+ @media (forced-colors: active) {
2141
+ [data-theme] .sw-section-nav-link { color: LinkText; }
2142
+ [data-theme] .sw-section-nav-link[aria-current] { border-color: Highlight; color: CanvasText; }
2143
+ }
2144
+
1873
2145
  .sw-dialog {
1874
2146
  background: var(--sw-glass-fill);
1875
2147
  border: 1px solid var(--sw-glass-border);
@@ -2285,6 +2557,27 @@ body {
2285
2557
  z-index: 10;
2286
2558
  }
2287
2559
 
2560
+ /* Each child of the header is a line of its own: a name, then a role. */
2561
+ .sw-action-menu-header {
2562
+ border-bottom: 1px solid var(--sw-color-border);
2563
+ color: var(--sw-color-muted);
2564
+ display: flex;
2565
+ flex-direction: column;
2566
+ gap: var(--sw-space-1);
2567
+ font-family: var(--sw-font-sans);
2568
+ font-size: 13px;
2569
+ letter-spacing: -0.08px;
2570
+ line-height: 18px;
2571
+ margin-bottom: var(--sw-space-1);
2572
+ /* The commands' inline padding, so the header's words line up with theirs. */
2573
+ padding: var(--sw-space-1) var(--sw-control-xs-padding-inline) var(--sw-space-2);
2574
+ }
2575
+
2576
+ /* With a header, the commands are the menu inside the popover. */
2577
+ .sw-action-menu-items {
2578
+ display: block;
2579
+ }
2580
+
2288
2581
  .sw-action-menu-item {
2289
2582
  align-items: center;
2290
2583
  appearance: none;
@@ -2617,11 +2910,14 @@ body {
2617
2910
  font-family: var(--sw-font-sans);
2618
2911
  font-size: 13px;
2619
2912
  line-height: 18px;
2620
- inset-block-start: calc(100% + var(--sw-space-1));
2621
- inset-inline-start: 0;
2622
- max-width: min(18rem, calc(100vw - 2 * var(--sw-space-3)));
2913
+ /* The popover layer's inset: 0 would ignore the placed left in right-to-left. */
2914
+ inset: auto;
2915
+ margin: 0;
2916
+ /* On the top layer 100% is the viewport without a classic scrollbar. */
2917
+ max-width: min(18rem, calc(100% - 2 * var(--sw-space-2)));
2918
+ overflow: visible;
2623
2919
  padding: var(--sw-space-2);
2624
- position: absolute;
2920
+ position: fixed;
2625
2921
  width: max-content;
2626
2922
  z-index: 10;
2627
2923
  }
@@ -2760,6 +3056,12 @@ body {
2760
3056
  outline-offset: var(--sw-focus-ring-offset);
2761
3057
  }
2762
3058
 
3059
+ .sw-tabs.sw-scroll-more-start { box-shadow: inset var(--sw-space-6) 0 var(--sw-space-5) calc(-1 * var(--sw-space-5)) color-mix(in srgb, var(--sw-color-text) 28%, transparent); }
3060
+ .sw-tabs.sw-scroll-more-end { box-shadow: inset calc(-1 * var(--sw-space-6)) 0 var(--sw-space-5) calc(-1 * var(--sw-space-5)) color-mix(in srgb, var(--sw-color-text) 28%, transparent); }
3061
+ .sw-tabs.sw-scroll-more-start:dir(rtl) { box-shadow: inset calc(-1 * var(--sw-space-6)) 0 var(--sw-space-5) calc(-1 * var(--sw-space-5)) color-mix(in srgb, var(--sw-color-text) 28%, transparent); }
3062
+ .sw-tabs.sw-scroll-more-end:dir(rtl) { box-shadow: inset var(--sw-space-6) 0 var(--sw-space-5) calc(-1 * var(--sw-space-5)) color-mix(in srgb, var(--sw-color-text) 28%, transparent); }
3063
+ .sw-tabs.sw-scroll-more-start.sw-scroll-more-end { box-shadow: inset var(--sw-space-6) 0 var(--sw-space-5) calc(-1 * var(--sw-space-5)) color-mix(in srgb, var(--sw-color-text) 28%, transparent), inset calc(-1 * var(--sw-space-6)) 0 var(--sw-space-5) calc(-1 * var(--sw-space-5)) color-mix(in srgb, var(--sw-color-text) 28%, transparent); }
3064
+
2763
3065
  .sw-tabs-sticky {
2764
3066
  background: color-mix(in srgb, var(--sw-color-background) 90%, transparent);
2765
3067
  backdrop-filter: blur(var(--sw-glass-blur)) saturate(var(--sw-glass-saturate));
@@ -3195,7 +3497,8 @@ body {
3195
3497
  @media not all and (min-width: 48rem) {
3196
3498
  .sw-denomination-strip .sw-denomination-total,
3197
3499
  .sw-denomination-strip .sw-denomination-total-head { padding: 0; position: relative; }
3198
- .sw-denomination-total-value { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
3500
+ .sw-denomination-total-value,
3501
+ .sw-denomination-total-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
3199
3502
  .sw-denomination-total-inline { display: block; }
3200
3503
  .sw-denomination-label-body { flex-direction: column; align-items: flex-start; gap: var(--sw-space-1); }
3201
3504
  .sw-denomination-strip .sw-denomination-label-line { gap: var(--sw-space-1); }
@@ -3226,6 +3529,47 @@ body {
3226
3529
  .sw-denomination-grid .sw-denomination-cell-toned .sw-denomination-cell-zero { color: GrayText; }
3227
3530
  }
3228
3531
 
3532
+ .sw-denomination-scroll-aligned {
3533
+ container-type: inline-size;
3534
+ }
3535
+
3536
+ .sw-denomination-label-xs { --sw-denomination-label-width: 4rem; }
3537
+ .sw-denomination-label-sm { --sw-denomination-label-width: 6rem; }
3538
+ .sw-denomination-label-md { --sw-denomination-label-width: 8rem; }
3539
+ .sw-denomination-label-lg { --sw-denomination-label-width: 12rem; }
3540
+ .sw-denomination-label-xl { --sw-denomination-label-width: 16rem; }
3541
+
3542
+ .sw-denomination-strip-aligned {
3543
+ --sw-denomination-total-shown: 1;
3544
+ --sw-denomination-share: calc(
3545
+ (100cqi - var(--sw-denomination-label-width)) /
3546
+ (var(--sw-denomination-columns) + var(--sw-denomination-total) * var(--sw-denomination-total-shown))
3547
+ );
3548
+ }
3549
+
3550
+ .sw-denomination-strip-aligned th,
3551
+ .sw-denomination-strip-aligned td {
3552
+ box-sizing: border-box;
3553
+ }
3554
+
3555
+ .sw-denomination-strip-aligned .sw-denomination-label,
3556
+ .sw-denomination-strip-aligned thead .sw-denomination-corner:first-child {
3557
+ width: var(--sw-denomination-label-width);
3558
+ }
3559
+
3560
+ .sw-denomination-strip-aligned .sw-denomination-cell,
3561
+ .sw-denomination-strip-aligned .sw-denomination-head:not(.sw-denomination-total-head),
3562
+ .sw-denomination-strip-aligned .sw-denomination-total,
3563
+ .sw-denomination-strip-aligned .sw-denomination-total-head {
3564
+ width: var(--sw-denomination-share);
3565
+ }
3566
+
3567
+ @media not all and (min-width: 48rem) {
3568
+ .sw-denomination-strip-aligned { --sw-denomination-total-shown: 0; }
3569
+ .sw-denomination-strip-aligned .sw-denomination-total,
3570
+ .sw-denomination-strip-aligned .sw-denomination-total-head { width: 0; }
3571
+ }
3572
+
3229
3573
  @media (forced-colors: active) {
3230
3574
  .sw-denomination-label { border-inline-start-color: CanvasText; color: CanvasText; }
3231
3575
  .sw-denomination-strip .sw-denomination-label::before { background: CanvasText; forced-color-adjust: none; }
@@ -3255,6 +3599,17 @@ body {
3255
3599
  border-color: var(--sw-color-danger);
3256
3600
  }
3257
3601
 
3602
+ /*
3603
+ * A changed value: the accent border, a hairline thicker through an inset
3604
+ * shadow so nothing moves, on the control or on an adorned frame (whose
3605
+ * input draws no border of its own).
3606
+ */
3607
+ [data-theme] .sw-field-changed > :is(input, select, textarea),
3608
+ .sw-field-changed .sw-field-adorned {
3609
+ border-color: var(--sw-color-accent);
3610
+ box-shadow: inset 0 0 0 1px var(--sw-color-accent);
3611
+ }
3612
+
3258
3613
  .sw-field-adorned {
3259
3614
  background-color: var(--sw-glass-fill);
3260
3615
  border: 1px solid var(--sw-color-border);
@@ -3321,6 +3676,8 @@ body {
3321
3676
  @media (forced-colors: active) {
3322
3677
  [data-theme] .sw-field-invalid :is(input, select, textarea),
3323
3678
  .sw-field-invalid .sw-field-adorned { border-color: Mark; }
3679
+ [data-theme] .sw-field-changed > :is(input, select, textarea),
3680
+ .sw-field-changed .sw-field-adorned { border-color: Highlight; box-shadow: inset 0 0 0 1px Highlight; }
3324
3681
  .sw-field-prefix, .sw-field-suffix { color: CanvasText; }
3325
3682
  .sw-field-adorned:has(> input:disabled) {
3326
3683
  border-color: GrayText;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scalewing/react",
3
- "version": "1.21.0",
3
+ "version": "1.22.0",
4
4
  "description": "Scalewing DOM components and package-owned CSS utilities.",
5
5
  "type": "module",
6
6
  "license": "MIT",