editor-shell 0.21.0 → 0.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.
- package/dist/panel/panel.css +87 -40
- package/package.json +1 -1
package/dist/panel/panel.css
CHANGED
|
@@ -7,11 +7,13 @@
|
|
|
7
7
|
* dark mode.
|
|
8
8
|
*
|
|
9
9
|
* Two details are deliberate and were decided by measurement, not taste:
|
|
10
|
-
* · rows sit
|
|
11
|
-
* setting reads as ONE thing with air around it.
|
|
12
|
-
* saying which label owns which control
|
|
13
|
-
*
|
|
14
|
-
*
|
|
10
|
+
* · rows sit 38px apart while a label sits 11px from its own control, so a
|
|
11
|
+
* setting reads as ONE thing with air around it. That inside gap is the
|
|
12
|
+
* ONLY thing saying which label owns which control, and the two are a
|
|
13
|
+
* RATIO rather than a pair of numbers: measured at 28 and 7 (card 8802.d,
|
|
14
|
+
* approved from mockups/8802e-settings-spacing-mockup.html) and re-scaled
|
|
15
|
+
* together to 38 and 11 (card 66301), which keeps the gap between settings
|
|
16
|
+
* 3.5x the gap inside one;
|
|
15
17
|
* · the label is small and grey, the value is larger and dark. Before that
|
|
16
18
|
* contrast existed, a merchant could not tell a name from a number.
|
|
17
19
|
*/
|
|
@@ -63,23 +65,38 @@
|
|
|
63
65
|
a heading, after the row above it 36px unchanged
|
|
64
66
|
|
|
65
67
|
The three measured rhythms do not move because 16 is still under them, which
|
|
66
|
-
is the floor doing exactly what it was built to do.
|
|
68
|
+
is the floor doing exactly what it was built to do.
|
|
69
|
+
|
|
70
|
+
NOW 20, AND THE RHYTHMS MOVED WITH IT (card 66301). Lewis, 2026-08-31: the
|
|
71
|
+
vertical spacing is too tight, open it up, roughly 10px more. Asked whether
|
|
72
|
+
the tightest gap should take the full 10 as well he handed the numbers over —
|
|
73
|
+
"you decide, whatever feels comfortable" — so the six values below are this
|
|
74
|
+
desk's, made under that.
|
|
75
|
+
|
|
76
|
+
NOT A FLAT +10 ON EVERY TOKEN, which is what was first asked for. A flat rise
|
|
77
|
+
takes the widest gap against the tightest from 36:7 to 46:17 — 5.1x down to
|
|
78
|
+
2.7x — so it opens the panel and FLATTENS it at the same time, and "these
|
|
79
|
+
belong together" stops reading differently from "these are separate". The six
|
|
80
|
+
values keep it at 4.4x while every seam still grows visibly. */
|
|
67
81
|
/* ── the rhythms: the numbers under the floor, given names (card 66228) ────── */
|
|
68
82
|
|
|
69
83
|
/* THE FLOOR ABOVE IS NOT THE RHYTHM, and handing a consumer the floor was the
|
|
70
|
-
whole problem. `--es-row-gap` answers
|
|
84
|
+
whole problem. `--es-row-gap` answers 20 for all five gaps below alike; what
|
|
71
85
|
the storefront's Layers tree needs in order to "follow the shell's spacing"
|
|
72
|
-
is the RHYTHM —
|
|
86
|
+
is the RHYTHM — 38 between two settings against 11 inside one. Under the floor
|
|
73
87
|
those were bare literals, so the only way to follow them was to COPY them
|
|
74
88
|
into `efficient-shop/components/storefront-editor.css`: a second source of
|
|
75
89
|
truth for numbers this sheet was already the source of.
|
|
76
90
|
|
|
77
|
-
THE VALUES DID NOT CHANGE. Every one
|
|
78
|
-
moved and named;
|
|
79
|
-
|
|
91
|
+
THE VALUES DID NOT CHANGE WHEN THEY WERE NAMED. Every one was the number
|
|
92
|
+
that was there before, moved and named; (g) asserted each still resolved to
|
|
93
|
+
what it resolved to, and (a) still read the scale off the sheet. Card 66301
|
|
94
|
+
is the first card to turn them, and it turned all six at once — which is what
|
|
95
|
+
naming them was for.
|
|
80
96
|
|
|
81
97
|
NAMES, NOT ARITHMETIC, for the reason this sheet already gives one rule down:
|
|
82
|
-
|
|
98
|
+
38 was measured and then re-scaled (cards 8802.d, 66301), it is not "20 plus
|
|
99
|
+
18" and never was "16 plus 12". `calc()` off the floor
|
|
83
100
|
would claim a relationship nobody decided; a name states the value and the
|
|
84
101
|
job it does.
|
|
85
102
|
|
|
@@ -87,28 +104,29 @@
|
|
|
87
104
|
and `--es-rhythm-within` are the two halves of the one rule that has to
|
|
88
105
|
survive being re-scaled: the gap INSIDE a thing stays plainly smaller than
|
|
89
106
|
the gap BETWEEN things, because that inside gap is the ONLY thing saying
|
|
90
|
-
which label owns which control.
|
|
91
|
-
|
|
92
|
-
|
|
107
|
+
which label owns which control. Card 66301 re-scaled all six and is the proof
|
|
108
|
+
the pair travels: 28:7 became 38:11, both up, the ratio held. A tree at 38px a
|
|
109
|
+
row would scroll forever, so a consumer is expected to scale these — and (g)
|
|
110
|
+
is what stops the two from drifting together while it does. */
|
|
93
111
|
.es-editor {
|
|
94
112
|
/* THE FLOOR (card 66206) — no row-to-row gap on this panel resolves below it. */
|
|
95
|
-
--es-row-gap:
|
|
113
|
+
--es-row-gap: 20px;
|
|
96
114
|
|
|
97
115
|
/* THE RHYTHMS. All five are declared in THIS rule and not a second
|
|
98
116
|
`.es-editor` block: the panel has ONE root, and a second block would put
|
|
99
117
|
half the panel's spacing somewhere a reader — and the spec, which reads the
|
|
100
118
|
root by selector — would not look. */
|
|
101
119
|
/* between one group heading and whatever is above it */
|
|
102
|
-
--es-rhythm-group:
|
|
120
|
+
--es-rhythm-group: 48px;
|
|
103
121
|
/* between a group heading and the first setting under it — closer, because
|
|
104
122
|
that setting belongs to that heading */
|
|
105
|
-
--es-rhythm-group-first:
|
|
123
|
+
--es-rhythm-group-first: 24px;
|
|
106
124
|
/* BETWEEN two settings */
|
|
107
|
-
--es-rhythm-between:
|
|
125
|
+
--es-rhythm-between: 38px;
|
|
108
126
|
/* between two one-line rows, which are one line tall and need less air */
|
|
109
|
-
--es-rhythm-between-tight:
|
|
127
|
+
--es-rhythm-between-tight: 26px;
|
|
110
128
|
/* WITHIN one setting: its label to its own control */
|
|
111
|
-
--es-rhythm-within:
|
|
129
|
+
--es-rhythm-within: 11px;
|
|
112
130
|
|
|
113
131
|
/* ── THE CHIP'S OWN METRICS (card 66248) ───────────────────────────────────
|
|
114
132
|
|
|
@@ -551,7 +569,7 @@
|
|
|
551
569
|
border-radius: var(--es-row-radius);
|
|
552
570
|
padding: 8px 11px;
|
|
553
571
|
/* A heading needs more air above it than the settings it heads have between
|
|
554
|
-
them (
|
|
572
|
+
them (38px), or it reads as one more row. Floored on `--es-row-gap` so it
|
|
555
573
|
rises with the rest of the panel (card 66203). */
|
|
556
574
|
margin: max(var(--es-row-gap), var(--es-rhythm-group)) 0 0;
|
|
557
575
|
}
|
|
@@ -595,21 +613,31 @@ button.es-group-head:hover { background: var(--es-chip-bg); }
|
|
|
595
613
|
overriding the attribute's own display:none. */
|
|
596
614
|
.es-group-body[hidden] { display: none; }
|
|
597
615
|
/* The first setting under a head sits CLOSER than the settings below it do to
|
|
598
|
-
each other — it belongs to that head, and
|
|
616
|
+
each other — it belongs to that head, and 38px would cut it loose.
|
|
617
|
+
|
|
618
|
+
AND IT IS LIVE FOR THE FIRST TIME (card 66301). It declared 14 against a 16px
|
|
619
|
+
floor, so it has never once been 14 on screen — the floor answered every
|
|
620
|
+
time, and card 66206 measured that very move (14 → 16) and wrote it down as
|
|
621
|
+
the floor working, which it was. At 24 over a 20px floor the declared number
|
|
622
|
+
is finally the visible one, so this seam grows 16 → 24 rather than the 14 →
|
|
623
|
+
24 the file appears to say. `tests/panel-layout.test.ts` (h) is what turns a
|
|
624
|
+
floored rhythm into a failure instead of a footnote. */
|
|
599
625
|
.es-group-body > .es-field:first-child { margin-top: max(var(--es-row-gap), var(--es-rhythm-group-first)); }
|
|
600
626
|
|
|
601
627
|
/* ── one setting ───────────────────────────────────────────────────────────── */
|
|
602
628
|
|
|
603
|
-
/*
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
was too tight
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
629
|
+
/* 38 IS NOT A THIRD OPINION ABOUT THE FLOOR. A setting is TWO lines — a label
|
|
630
|
+
row and its control — held together by the 11px between them, and that 11px
|
|
631
|
+
is the only thing saying which label owns which control. The gap between
|
|
632
|
+
settings has to be plainly larger than the gap inside one or the panel stops
|
|
633
|
+
being a list of settings and becomes a list of loose parts. The pair was
|
|
634
|
+
measured at 28 and 7 and approved from mockups (card 8802.d) — 20 was tried
|
|
635
|
+
there and was too tight — and re-scaled together to 38 and 11 (card 66301),
|
|
636
|
+
which is the same rule with more air, not a new one.
|
|
637
|
+
|
|
638
|
+
Floored, not replaced, and not `calc()`: 38 was measured and then re-scaled,
|
|
639
|
+
it is not "20 plus 18", so arithmetic off the token would claim a
|
|
640
|
+
relationship nobody decided. */
|
|
613
641
|
.es-field { margin-top: max(var(--es-row-gap), var(--es-rhythm-between)); }
|
|
614
642
|
|
|
615
643
|
.es-field-head {
|
|
@@ -677,8 +705,13 @@ button.es-group-head:hover { background: var(--es-chip-bg); }
|
|
|
677
705
|
control row, the label line's 7px bottom margin would be a gap to nothing.
|
|
678
706
|
|
|
679
707
|
A one-line row is one line tall, so it needs less air above it than a
|
|
680
|
-
two-line setting does —
|
|
681
|
-
same reason everything else here is (card 66203).
|
|
708
|
+
two-line setting does — 26, not 38 — and it is floored on the token for the
|
|
709
|
+
same reason everything else here is (card 66203).
|
|
710
|
+
|
|
711
|
+
IT TIED WITH THE FLOOR UNTIL NOW (card 66301). At 16 against a 16px floor
|
|
712
|
+
nothing was wrong on screen, but the sheet could not tell you which of the
|
|
713
|
+
two numbers you were reading, and moving either one alone would have moved
|
|
714
|
+
nothing. 26 over 20 puts it plainly on its own number. */
|
|
682
715
|
.es-field.is-inline { margin-top: max(var(--es-row-gap), var(--es-rhythm-between-tight)); }
|
|
683
716
|
.es-field.is-inline .es-field-head { margin-bottom: 0; }
|
|
684
717
|
|
|
@@ -780,11 +813,25 @@ button.es-group-head:hover { background: var(--es-chip-bg); }
|
|
|
780
813
|
hairline between them and adds no margin — so the air a merchant sees is
|
|
781
814
|
each row's own vertical padding, on its own side of the line. MEASURED in
|
|
782
815
|
Chromium against these stylesheets (`tests/fixtures/panel-row-spacing.html`):
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
23.
|
|
786
|
-
|
|
787
|
-
|
|
816
|
+
|
|
817
|
+
token above the rule below it word to word recorded by
|
|
818
|
+
10px 11.40px 12.00px 23.40px card 66203
|
|
819
|
+
16px 17.40px 18.00px 35.40px card 66206
|
|
820
|
+
16px 17.39px 17.00px 34.39px card 66301
|
|
821
|
+
20px 21.39px 21.00px 42.39px card 66301
|
|
822
|
+
|
|
823
|
+
TWO ROWS FOR 16px, AND THEY DISAGREE BY A PIXEL. 66301's pair was taken in
|
|
824
|
+
one run of Chromium 124 (zenika/alpine-chrome) so its two rows compare; the
|
|
825
|
+
earlier rows are left as the cards recorded them rather than overwritten,
|
|
826
|
+
because the difference is the engine and the font it had, not this sheet.
|
|
827
|
+
Read a row against another row from the same card, never across cards.
|
|
828
|
+
|
|
829
|
+
THIS SEAM MOVES AT TWICE THE TOKEN'S RATE, and it is the only one that
|
|
830
|
+
does: both rows spend the gap, so +4 on the dial buys +8 of air. Under the
|
|
831
|
+
floor alone it was also the ONLY place raising the token moved a measured
|
|
832
|
+
distance rather than a declared one — every other seam was held by a bigger
|
|
833
|
+
rhythm — which is why it is the row Lewis was looking at when he asked for
|
|
834
|
+
card 66206. Card 66301 moves the rhythms too, so it is no longer alone.
|
|
788
835
|
|
|
789
836
|
A MARGIN WOULD BE THE WRONG FIX. A border-top with space above it detaches
|
|
790
837
|
from the row it belongs to and reads as a line floating in the panel rather
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "editor-shell",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.22.0",
|
|
4
4
|
"description": "Shared editor-chrome primitives for the EFFICIENT editors: EditorRail (a Next-16-safe left icon-rail leaf), the shell token layer, and GoldTextInput — type in place and watch the markup formatting appear as you type.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Lewis Liu",
|