@axiapps/axi-design 1.23.0 → 1.24.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/dist/axi.css +40 -8
- package/package.json +1 -1
- package/src/primitives.css +10 -1
- package/src/shells.css +21 -4
- package/src/tokens.css +9 -3
package/dist/axi.css
CHANGED
|
@@ -31,9 +31,15 @@
|
|
|
31
31
|
wedge of colour. The ground stays a colour. This is the page's light. */
|
|
32
32
|
--axi-ground-image: none;
|
|
33
33
|
--axi-surface: #222731; /* a panel raised off the page */
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
34
|
+
/* A chip, a hover, a table head - something raised off a panel that is part
|
|
35
|
+
of the page rather than over it. It said "a chip or popover" until the
|
|
36
|
+
popovers moved to the float: what they were borrowing was opacity, which
|
|
37
|
+
this token cannot promise under a translucent theme. */
|
|
38
|
+
--axi-surface-raised: #2b313d;
|
|
39
|
+
/* The fill for a surface that FLOATS over content which scrolls behind it:
|
|
40
|
+
the command palette, the menu and picker popovers, the modal, the drawer,
|
|
41
|
+
the toast, and any .axi-panel--float or .axi-rail--float a consumer
|
|
42
|
+
declares. Holds --axi-surface, because for
|
|
37
43
|
a theme whose panels are opaque a floating panel is just a panel and there
|
|
38
44
|
is nothing to decide.
|
|
39
45
|
|
|
@@ -321,6 +327,13 @@ a { color: inherit; }
|
|
|
321
327
|
.axi-panel--tile {
|
|
322
328
|
border-width: var(--axi-border-control);
|
|
323
329
|
box-shadow: var(--axi-shadow-control);
|
|
330
|
+
/* The control radius, not the panel's. A tile has already said it is
|
|
331
|
+
control-sized by taking the control border and the control block, and
|
|
332
|
+
--axi-radius's own note says control-sized surfaces read the small step -
|
|
333
|
+
so inheriting .axi-panel's corner was the one place the tile disagreed
|
|
334
|
+
with itself. Both are 0 in this theme, which is exactly why it had to be
|
|
335
|
+
fixed by reading the token rather than by looking at it. */
|
|
336
|
+
border-radius: var(--axi-radius-sm);
|
|
324
337
|
padding: var(--axi-panel-pad, 12px);
|
|
325
338
|
}
|
|
326
339
|
/* A tile you can press moves under the press, the way every other control in
|
|
@@ -717,7 +730,9 @@ button.axi-panel--tile:hover,
|
|
|
717
730
|
min-width: 100%;
|
|
718
731
|
max-height: 340px; overflow-y: auto;
|
|
719
732
|
padding: 6px;
|
|
720
|
-
|
|
733
|
+
/* Float, for the reason .axi-menu__pop is - this is the same object with a
|
|
734
|
+
selected row. */
|
|
735
|
+
background: var(--axi-surface-float);
|
|
721
736
|
backdrop-filter: var(--axi-surface-filter);
|
|
722
737
|
border: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
723
738
|
border-radius: var(--axi-radius);
|
|
@@ -1248,7 +1263,13 @@ textarea.axi-input {
|
|
|
1248
1263
|
position: absolute; top: calc(100% + 9px); left: 0; z-index: 41;
|
|
1249
1264
|
width: var(--axi-menu-width, 310px);
|
|
1250
1265
|
max-height: 340px; overflow-y: auto; padding: 8px;
|
|
1251
|
-
|
|
1266
|
+
/* The other component --axi-surface-float names. It read --axi-surface-raised
|
|
1267
|
+
because that token's comment says "a chip or popover" and, before the float
|
|
1268
|
+
existed, raised was the only word for "higher than the panel". Height is
|
|
1269
|
+
carried by the border and the block, though - the modal is the highest
|
|
1270
|
+
surface on screen and sits on the plain fill - so what raised was actually
|
|
1271
|
+
lending here was opacity it cannot promise under a translucent theme. */
|
|
1272
|
+
background: var(--axi-surface-float);
|
|
1252
1273
|
backdrop-filter: var(--axi-surface-filter);
|
|
1253
1274
|
border: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
1254
1275
|
border-radius: var(--axi-radius);
|
|
@@ -1512,7 +1533,9 @@ textarea.axi-input {
|
|
|
1512
1533
|
position: fixed; top: 0; right: 0; bottom: 0; z-index: 51;
|
|
1513
1534
|
width: min(var(--axi-drawer-width, 560px), 100vw);
|
|
1514
1535
|
display: flex; flex-direction: column;
|
|
1515
|
-
|
|
1536
|
+
/* A drawer is pinned to three edges with the page live beside it, and its
|
|
1537
|
+
own body scrolls. Float on both counts. */
|
|
1538
|
+
background: var(--axi-surface-float);
|
|
1516
1539
|
backdrop-filter: var(--axi-surface-filter);
|
|
1517
1540
|
border-left: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
1518
1541
|
}
|
|
@@ -1701,7 +1724,12 @@ textarea.axi-input {
|
|
|
1701
1724
|
.axi-modal {
|
|
1702
1725
|
padding: 0;
|
|
1703
1726
|
max-width: min(var(--axi-modal-width, 560px), calc(100vw - 32px));
|
|
1704
|
-
|
|
1727
|
+
/* The float surface, not the plain one. --axi-surface-float's own note names
|
|
1728
|
+
this component as one of its three consumers and it was only ever wired
|
|
1729
|
+
into the palette; a modal is the strongest case the token has, because the
|
|
1730
|
+
whole app is behind it and a scrim does not make a .42-alpha pane legible
|
|
1731
|
+
on a platform where the blur is switched off. */
|
|
1732
|
+
background: var(--axi-surface-float);
|
|
1705
1733
|
backdrop-filter: var(--axi-surface-filter);
|
|
1706
1734
|
color: var(--axi-text);
|
|
1707
1735
|
border: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
@@ -1797,7 +1825,11 @@ textarea.axi-input {
|
|
|
1797
1825
|
pointer-events: auto;
|
|
1798
1826
|
display: flex; align-items: center; gap: 12px;
|
|
1799
1827
|
padding: 12px 15px;
|
|
1800
|
-
|
|
1828
|
+
/* Float at the control weight. A toast is the one floating thing the reader
|
|
1829
|
+
did not open and cannot hold still: whatever is under it is mid-scroll by
|
|
1830
|
+
definition, which is the float's case exactly, while the border and the
|
|
1831
|
+
block stay at the control step for the reason above. */
|
|
1832
|
+
background: var(--axi-surface-float);
|
|
1801
1833
|
backdrop-filter: var(--axi-surface-filter);
|
|
1802
1834
|
border: var(--axi-border-control) solid var(--axi-ink-line);
|
|
1803
1835
|
border-radius: var(--axi-radius-sm);
|
package/package.json
CHANGED
package/src/primitives.css
CHANGED
|
@@ -55,6 +55,13 @@
|
|
|
55
55
|
.axi-panel--tile {
|
|
56
56
|
border-width: var(--axi-border-control);
|
|
57
57
|
box-shadow: var(--axi-shadow-control);
|
|
58
|
+
/* The control radius, not the panel's. A tile has already said it is
|
|
59
|
+
control-sized by taking the control border and the control block, and
|
|
60
|
+
--axi-radius's own note says control-sized surfaces read the small step -
|
|
61
|
+
so inheriting .axi-panel's corner was the one place the tile disagreed
|
|
62
|
+
with itself. Both are 0 in this theme, which is exactly why it had to be
|
|
63
|
+
fixed by reading the token rather than by looking at it. */
|
|
64
|
+
border-radius: var(--axi-radius-sm);
|
|
58
65
|
padding: var(--axi-panel-pad, 12px);
|
|
59
66
|
}
|
|
60
67
|
/* A tile you can press moves under the press, the way every other control in
|
|
@@ -451,7 +458,9 @@ button.axi-panel--tile:hover,
|
|
|
451
458
|
min-width: 100%;
|
|
452
459
|
max-height: 340px; overflow-y: auto;
|
|
453
460
|
padding: 6px;
|
|
454
|
-
|
|
461
|
+
/* Float, for the reason .axi-menu__pop is - this is the same object with a
|
|
462
|
+
selected row. */
|
|
463
|
+
background: var(--axi-surface-float);
|
|
455
464
|
backdrop-filter: var(--axi-surface-filter);
|
|
456
465
|
border: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
457
466
|
border-radius: var(--axi-radius);
|
package/src/shells.css
CHANGED
|
@@ -293,7 +293,13 @@
|
|
|
293
293
|
position: absolute; top: calc(100% + 9px); left: 0; z-index: 41;
|
|
294
294
|
width: var(--axi-menu-width, 310px);
|
|
295
295
|
max-height: 340px; overflow-y: auto; padding: 8px;
|
|
296
|
-
|
|
296
|
+
/* The other component --axi-surface-float names. It read --axi-surface-raised
|
|
297
|
+
because that token's comment says "a chip or popover" and, before the float
|
|
298
|
+
existed, raised was the only word for "higher than the panel". Height is
|
|
299
|
+
carried by the border and the block, though - the modal is the highest
|
|
300
|
+
surface on screen and sits on the plain fill - so what raised was actually
|
|
301
|
+
lending here was opacity it cannot promise under a translucent theme. */
|
|
302
|
+
background: var(--axi-surface-float);
|
|
297
303
|
backdrop-filter: var(--axi-surface-filter);
|
|
298
304
|
border: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
299
305
|
border-radius: var(--axi-radius);
|
|
@@ -557,7 +563,9 @@
|
|
|
557
563
|
position: fixed; top: 0; right: 0; bottom: 0; z-index: 51;
|
|
558
564
|
width: min(var(--axi-drawer-width, 560px), 100vw);
|
|
559
565
|
display: flex; flex-direction: column;
|
|
560
|
-
|
|
566
|
+
/* A drawer is pinned to three edges with the page live beside it, and its
|
|
567
|
+
own body scrolls. Float on both counts. */
|
|
568
|
+
background: var(--axi-surface-float);
|
|
561
569
|
backdrop-filter: var(--axi-surface-filter);
|
|
562
570
|
border-left: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
563
571
|
}
|
|
@@ -746,7 +754,12 @@
|
|
|
746
754
|
.axi-modal {
|
|
747
755
|
padding: 0;
|
|
748
756
|
max-width: min(var(--axi-modal-width, 560px), calc(100vw - 32px));
|
|
749
|
-
|
|
757
|
+
/* The float surface, not the plain one. --axi-surface-float's own note names
|
|
758
|
+
this component as one of its three consumers and it was only ever wired
|
|
759
|
+
into the palette; a modal is the strongest case the token has, because the
|
|
760
|
+
whole app is behind it and a scrim does not make a .42-alpha pane legible
|
|
761
|
+
on a platform where the blur is switched off. */
|
|
762
|
+
background: var(--axi-surface-float);
|
|
750
763
|
backdrop-filter: var(--axi-surface-filter);
|
|
751
764
|
color: var(--axi-text);
|
|
752
765
|
border: var(--axi-border-panel) solid var(--axi-ink-line);
|
|
@@ -842,7 +855,11 @@
|
|
|
842
855
|
pointer-events: auto;
|
|
843
856
|
display: flex; align-items: center; gap: 12px;
|
|
844
857
|
padding: 12px 15px;
|
|
845
|
-
|
|
858
|
+
/* Float at the control weight. A toast is the one floating thing the reader
|
|
859
|
+
did not open and cannot hold still: whatever is under it is mid-scroll by
|
|
860
|
+
definition, which is the float's case exactly, while the border and the
|
|
861
|
+
block stay at the control step for the reason above. */
|
|
862
|
+
background: var(--axi-surface-float);
|
|
846
863
|
backdrop-filter: var(--axi-surface-filter);
|
|
847
864
|
border: var(--axi-border-control) solid var(--axi-ink-line);
|
|
848
865
|
border-radius: var(--axi-radius-sm);
|
package/src/tokens.css
CHANGED
|
@@ -27,9 +27,15 @@
|
|
|
27
27
|
wedge of colour. The ground stays a colour. This is the page's light. */
|
|
28
28
|
--axi-ground-image: none;
|
|
29
29
|
--axi-surface: #222731; /* a panel raised off the page */
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
30
|
+
/* A chip, a hover, a table head - something raised off a panel that is part
|
|
31
|
+
of the page rather than over it. It said "a chip or popover" until the
|
|
32
|
+
popovers moved to the float: what they were borrowing was opacity, which
|
|
33
|
+
this token cannot promise under a translucent theme. */
|
|
34
|
+
--axi-surface-raised: #2b313d;
|
|
35
|
+
/* The fill for a surface that FLOATS over content which scrolls behind it:
|
|
36
|
+
the command palette, the menu and picker popovers, the modal, the drawer,
|
|
37
|
+
the toast, and any .axi-panel--float or .axi-rail--float a consumer
|
|
38
|
+
declares. Holds --axi-surface, because for
|
|
33
39
|
a theme whose panels are opaque a floating panel is just a panel and there
|
|
34
40
|
is nothing to decide.
|
|
35
41
|
|