@brignano/design 0.10.1 → 0.11.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/DECISIONS.md +36 -0
- package/DESIGN.md +16 -1
- package/components.css +10 -1
- package/package.json +1 -1
- package/product-page.css +3 -1
package/DECISIONS.md
CHANGED
|
@@ -761,3 +761,39 @@ swapped. Anthony chose a direction from the wireframe
|
|
|
761
761
|
- Three pages differ, so a change to the shared rules is checked on three
|
|
762
762
|
layouts. The `A|B` stamp in the footer is the one family resemblance.
|
|
763
763
|
|
|
764
|
+
## ADR-0018 — A product's card may carry its stage
|
|
765
|
+
|
|
766
|
+
**Status:** accepted · 2026-11-15 · #164
|
|
767
|
+
**Extends:** ADR-0011 (the stage behind a hero proof), ADR-0017
|
|
768
|
+
|
|
769
|
+
### Context
|
|
770
|
+
|
|
771
|
+
brignano.io/projects lists products as cards, each with a drawing of what
|
|
772
|
+
the product does. The approved wireframe puts each drawing on a faint field
|
|
773
|
+
of its product's mark, so Driftwood's card reads as Driftwood before its
|
|
774
|
+
name does. DESIGN.md §3 kept the mark grounds to product pages, and
|
|
775
|
+
`.card-media` crops a photo to 16:9, which cuts a drawing's edges. Without a
|
|
776
|
+
rule each site would invent its own tint.
|
|
777
|
+
|
|
778
|
+
### Decision
|
|
779
|
+
|
|
780
|
+
- **`.card-media.card-stage`** draws the stage on a card: a
|
|
781
|
+
`color-mix(in srgb, var(--mark-current) 8%, transparent)` field, with the
|
|
782
|
+
picture padded and contained in its 16:9 box rather than cropped.
|
|
783
|
+
- **Same strength as the product page.** `--pp-stage` and `.card-stage` mix
|
|
784
|
+
the mark at 8%, so a product looks the same on its card and its page. No new
|
|
785
|
+
token: `product-page.css` stays self-contained, so the value is repeated,
|
|
786
|
+
and `npm run check` (gate 13) keeps the copies equal.
|
|
787
|
+
- **Only on a card that stands for a product**, and only as its picture's
|
|
788
|
+
ground. Buttons, links, text, chips and state on the card stay as they are.
|
|
789
|
+
- **Unmarked products stay amber.** A product gets its own hue with its
|
|
790
|
+
product page (§3); until then its card's stage is the family amber.
|
|
791
|
+
|
|
792
|
+
### Consequences
|
|
793
|
+
|
|
794
|
+
- "Identity is not a fill" has a third scoped exception, the smallest: a
|
|
795
|
+
translucent field behind one picture.
|
|
796
|
+
- A site listing products gets the tint from the package instead of a local
|
|
797
|
+
copy (brignano.io#340 drops its own).
|
|
798
|
+
- Changing the stage strength means changing both files; the check fails
|
|
799
|
+
until they agree.
|
package/DESIGN.md
CHANGED
|
@@ -70,7 +70,8 @@ system coherent across a marketing site and an operational tool.
|
|
|
70
70
|
|
|
71
71
|
`--mark` inks a **graphic**: a product's glyph, the `A|B` monogram, a hero rule.
|
|
72
72
|
That is its entire permitted use. It is never a button, chip, badge, wash, border,
|
|
73
|
-
or link.
|
|
73
|
+
or link. The scoped exceptions are the next sections: a product page, and the
|
|
74
|
+
stage behind a product's picture on its card.
|
|
74
75
|
|
|
75
76
|
This is the resolution of a real problem. Amber used to be both the brand colour
|
|
76
77
|
and the warning colour, kept apart by a rule about scale — and rules enforced by
|
|
@@ -119,6 +120,20 @@ This is a scoped exception to "identity is not a fill", as the stage behind a
|
|
|
119
120
|
hero proof was (ADR-0011). It never reaches an app, a link, text or a state,
|
|
120
121
|
and the focus ring stays `--i-ink`.
|
|
121
122
|
|
|
123
|
+
### On a card that stands for a product, the stage
|
|
124
|
+
|
|
125
|
+
A card that stands for one product, in a list of products on a page that
|
|
126
|
+
isn't its product page, may put that product's picture on its stage
|
|
127
|
+
(ADR-0018): `.card-media.card-stage`, the same 8% mix of `--mark-current` as
|
|
128
|
+
the hero stage on the product page, so a product looks the same on its card
|
|
129
|
+
and its page. `data-mark` on the card or an ancestor picks the hue; a product
|
|
130
|
+
without a product page has none and stays on the family amber.
|
|
131
|
+
|
|
132
|
+
The stage is the picture's ground and nothing else. On that card the mark
|
|
133
|
+
still never colours a button, link, text, chip, badge, border or state, and
|
|
134
|
+
the focus ring stays `--i-ink`. A card that doesn't stand for a product (a
|
|
135
|
+
trip, a post) never gets a stage.
|
|
136
|
+
|
|
122
137
|
### Colour is a surface, not text
|
|
123
138
|
|
|
124
139
|
A wash (12% light / 20% dark via `color-mix`) behind an element with the text kept
|
package/components.css
CHANGED
|
@@ -594,7 +594,9 @@
|
|
|
594
594
|
link), so the markup stays a heading and a link, not a link wrapped
|
|
595
595
|
round blocks. One focus ring goes round the card. Other buttons and
|
|
596
596
|
links inside a .card-link still work: they sit above the stretched area.
|
|
597
|
-
.card-media goes first and runs edge to edge. No cards inside cards.
|
|
597
|
+
.card-media goes first and runs edge to edge. No cards inside cards.
|
|
598
|
+
.card-media.card-stage is for a drawing of a product (data-mark on the
|
|
599
|
+
card picks its hue): <div class="card-media card-stage"><svg …></div>. */
|
|
598
600
|
@layer brignano.components {
|
|
599
601
|
.card {
|
|
600
602
|
position: relative;
|
|
@@ -612,6 +614,13 @@
|
|
|
612
614
|
}
|
|
613
615
|
.card-media { margin: calc(-1 * var(--s5)) calc(-1 * var(--s5)) 0; }
|
|
614
616
|
.card-media > :is(img, video, picture, svg) { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
|
|
617
|
+
/* Stage (ADR-0018): a product's drawing on a faint field of its mark, the
|
|
618
|
+
same 8% mix as --pp-stage on its product page, so the card and the page
|
|
619
|
+
match. data-mark on the card or an ancestor picks the hue; with none it
|
|
620
|
+
is the family amber. The drawing is padded and contained, never cropped,
|
|
621
|
+
and the box stays 16:9. Only on a card that stands for a product. */
|
|
622
|
+
.card-stage { background-color: color-mix(in srgb, var(--mark-current) 8%, transparent); }
|
|
623
|
+
.card-stage > :is(img, video, picture, svg) { box-sizing: border-box; padding: var(--s5); object-fit: contain; }
|
|
615
624
|
.card-header { display: grid; gap: var(--s1); }
|
|
616
625
|
.card-title { margin: 0; font-size: var(--text-lg); font-weight: var(--weight-semibold); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
|
|
617
626
|
.card-title a { color: inherit; text-decoration: none; }
|
package/package.json
CHANGED
package/product-page.css
CHANGED
|
@@ -88,7 +88,9 @@
|
|
|
88
88
|
--pp-width: 1160px;
|
|
89
89
|
--pp-gutter: var(--s5);
|
|
90
90
|
/* The product's mark (ADR-0011): ink until data-mark picks one. The stage
|
|
91
|
-
is the field behind the hero proof, a faint wash of the mark.
|
|
91
|
+
is the field behind the hero proof, a faint wash of the mark. The card
|
|
92
|
+
stage (.card-stage, ADR-0018) repeats this strength; npm run check keeps
|
|
93
|
+
the two equal. */
|
|
92
94
|
--pp-mark: var(--ink);
|
|
93
95
|
--pp-stage: color-mix(in srgb, var(--pp-mark) 8%, transparent);
|
|
94
96
|
/* The primary button's fill (ADR-0017): ink until data-mark picks a mark.
|