editor-shell 0.18.0 → 0.19.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 +51 -5
- package/package.json +1 -1
package/dist/panel/panel.css
CHANGED
|
@@ -64,8 +64,51 @@
|
|
|
64
64
|
|
|
65
65
|
The three measured rhythms do not move because 16 is still under them, which
|
|
66
66
|
is the floor doing exactly what it was built to do. */
|
|
67
|
+
/* ── the rhythms: the numbers under the floor, given names (card 66228) ────── */
|
|
68
|
+
|
|
69
|
+
/* THE FLOOR ABOVE IS NOT THE RHYTHM, and handing a consumer the floor was the
|
|
70
|
+
whole problem. `--es-row-gap` answers 16 for all five gaps below alike; what
|
|
71
|
+
the storefront's Layers tree needs in order to "follow the shell's spacing"
|
|
72
|
+
is the RHYTHM — 28 between two settings against 7 inside one. Under the floor
|
|
73
|
+
those were bare literals, so the only way to follow them was to COPY them
|
|
74
|
+
into `efficient-shop/components/storefront-editor.css`: a second source of
|
|
75
|
+
truth for numbers this sheet was already the source of.
|
|
76
|
+
|
|
77
|
+
THE VALUES DID NOT CHANGE. Every one is the number that was there before,
|
|
78
|
+
moved and named; `tests/panel-layout.test.ts` (g) asserts each still resolves
|
|
79
|
+
to what it resolved to, and (a) still reads the scale off the sheet.
|
|
80
|
+
|
|
81
|
+
NAMES, NOT ARITHMETIC, for the reason this sheet already gives one rule down:
|
|
82
|
+
28 was measured (card 8802.d), it is not "16 plus 12". `calc()` off the floor
|
|
83
|
+
would claim a relationship nobody decided; a name states the value and the
|
|
84
|
+
job it does.
|
|
85
|
+
|
|
86
|
+
WHAT A CONSUMER IS ACTUALLY BUYING is the pair at the end. `--es-rhythm-between`
|
|
87
|
+
and `--es-rhythm-within` are the two halves of the one rule that has to
|
|
88
|
+
survive being re-scaled: the gap INSIDE a thing stays plainly smaller than
|
|
89
|
+
the gap BETWEEN things, because that inside gap is the ONLY thing saying
|
|
90
|
+
which label owns which control. A tree at 28px a row would scroll forever, so
|
|
91
|
+
a consumer is expected to scale these — and (g) is what stops the two from
|
|
92
|
+
drifting together while it does. */
|
|
67
93
|
.es-editor {
|
|
94
|
+
/* THE FLOOR (card 66206) — no row-to-row gap on this panel resolves below it. */
|
|
68
95
|
--es-row-gap: 16px;
|
|
96
|
+
|
|
97
|
+
/* THE RHYTHMS. All five are declared in THIS rule and not a second
|
|
98
|
+
`.es-editor` block: the panel has ONE root, and a second block would put
|
|
99
|
+
half the panel's spacing somewhere a reader — and the spec, which reads the
|
|
100
|
+
root by selector — would not look. */
|
|
101
|
+
/* between one group heading and whatever is above it */
|
|
102
|
+
--es-rhythm-group: 36px;
|
|
103
|
+
/* between a group heading and the first setting under it — closer, because
|
|
104
|
+
that setting belongs to that heading */
|
|
105
|
+
--es-rhythm-group-first: 14px;
|
|
106
|
+
/* BETWEEN two settings */
|
|
107
|
+
--es-rhythm-between: 28px;
|
|
108
|
+
/* between two one-line rows, which are one line tall and need less air */
|
|
109
|
+
--es-rhythm-between-tight: 16px;
|
|
110
|
+
/* WITHIN one setting: its label to its own control */
|
|
111
|
+
--es-rhythm-within: 7px;
|
|
69
112
|
}
|
|
70
113
|
|
|
71
114
|
/* ── the tab strip: a segmented control ────────────────────────────────────── */
|
|
@@ -338,7 +381,7 @@
|
|
|
338
381
|
/* A heading needs more air above it than the settings it heads have between
|
|
339
382
|
them (28px), or it reads as one more row. Floored on `--es-row-gap` so it
|
|
340
383
|
rises with the rest of the panel (card 66203). */
|
|
341
|
-
margin: max(var(--es-row-gap),
|
|
384
|
+
margin: max(var(--es-row-gap), var(--es-rhythm-group)) 0 0;
|
|
342
385
|
}
|
|
343
386
|
|
|
344
387
|
button.es-group-head {
|
|
@@ -381,7 +424,7 @@ button.es-group-head:hover { background: var(--es-chip-bg); }
|
|
|
381
424
|
.es-group-body[hidden] { display: none; }
|
|
382
425
|
/* The first setting under a head sits CLOSER than the settings below it do to
|
|
383
426
|
each other — it belongs to that head, and 28px would cut it loose. */
|
|
384
|
-
.es-group-body > .es-field:first-child { margin-top: max(var(--es-row-gap),
|
|
427
|
+
.es-group-body > .es-field:first-child { margin-top: max(var(--es-row-gap), var(--es-rhythm-group-first)); }
|
|
385
428
|
|
|
386
429
|
/* ── one setting ───────────────────────────────────────────────────────────── */
|
|
387
430
|
|
|
@@ -395,13 +438,16 @@ button.es-group-head:hover { background: var(--es-chip-bg); }
|
|
|
395
438
|
|
|
396
439
|
Floored, not replaced, and not `calc()`: 28 was measured, it is not "10 plus
|
|
397
440
|
18", so arithmetic off the token would claim a relationship nobody decided. */
|
|
398
|
-
.es-field { margin-top: max(var(--es-row-gap),
|
|
441
|
+
.es-field { margin-top: max(var(--es-row-gap), var(--es-rhythm-between)); }
|
|
399
442
|
|
|
400
443
|
.es-field-head {
|
|
401
444
|
display: flex;
|
|
402
445
|
align-items: center;
|
|
403
446
|
gap: 8px;
|
|
404
|
-
|
|
447
|
+
/* THE ONE THAT SAYS WHICH LABEL OWNS WHICH CONTROL. Named so a consumer can
|
|
448
|
+
read it (card 66228) — it is half of the rule, and the half that is easiest
|
|
449
|
+
to lose when someone re-scales the other half. */
|
|
450
|
+
margin-bottom: var(--es-rhythm-within);
|
|
405
451
|
min-height: 16px;
|
|
406
452
|
}
|
|
407
453
|
|
|
@@ -461,7 +507,7 @@ button.es-group-head:hover { background: var(--es-chip-bg); }
|
|
|
461
507
|
A one-line row is one line tall, so it needs less air above it than a
|
|
462
508
|
two-line setting does — 16, not 28 — and it is floored on the token for the
|
|
463
509
|
same reason everything else here is (card 66203). */
|
|
464
|
-
.es-field.is-inline { margin-top: max(var(--es-row-gap),
|
|
510
|
+
.es-field.is-inline { margin-top: max(var(--es-row-gap), var(--es-rhythm-between-tight)); }
|
|
465
511
|
.es-field.is-inline .es-field-head { margin-bottom: 0; }
|
|
466
512
|
|
|
467
513
|
/* ── the switch: one yes-or-no shape, both editors ─────────────────────────── */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "editor-shell",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.19.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",
|