Commit
Author: Jacob Lamb [jacobtlamb@hey.com]
Committer: GitHub [noreply@github.com] Thu, 16 Nov 2023 22:26:28 +0000
Hash: 43435de03a9d65384e6f5df3b04653c5531dbd62
Timestamp: Thu, 16 Nov 2023 22:26:28 +0000 (1 year ago)

+12 -11 +/-1 browse
Chore: add `width: fit-content` to a tag (#436)
Chore: add `width: fit-content` to a tag (#436)

* Add `width: fit-content` to anchor tag style

* Update normalize.src.css

* Update src/extra/normalize.src.css

Co-authored-by: Adam Argyle <argyle@google.com>

---------

Co-authored-by: Adam Argyle <argyle@google.com>
1diff --git a/src/extra/normalize.src.css b/src/extra/normalize.src.css
2index 65cdea5..22f7dfd 100644
3--- a/src/extra/normalize.src.css
4+++ b/src/extra/normalize.src.css
5 @@ -37,7 +37,7 @@
6 outline-offset: 5px;
7 }
8
9- :where(body) {
10+ :where(body) {
11 min-block-size: 100%;
12 }
13
14 @@ -47,13 +47,13 @@
15 text-wrap: balance;
16 }
17
18- :where(h1) {
19- font-size: var(--font-size-8);
20- max-inline-size: var(--size-header-1);
21+ :where(h1) {
22+ font-size: var(--font-size-8);
23+ max-inline-size: var(--size-header-1);
24 }
25
26- :where(h2) {
27- font-size: var(--font-size-6);
28+ :where(h2) {
29+ font-size: var(--font-size-6);
30 max-inline-size: var(--size-header-2);
31 }
32
33 @@ -91,6 +91,7 @@
34 margin-inline: calc(var(--size-1) * -1);
35 padding-block: var(--size-1);
36 margin-block: calc(var(--size-1) * -1);
37+ max-inline-size: fit-content;
38
39 &:where([href]) {
40 text-decoration-color: var(--indigo-2);
41 @@ -156,10 +157,10 @@
42 :where(code, kbd, samp, pre) { font-family: var(--font-mono) }
43 :where(:not(pre) > code, kbd) { white-space: nowrap }
44
45- :where(pre) {
46+ :where(pre) {
47 white-space: pre;
48 min-inline-size: 0;
49- max-inline-size: max-content;
50+ max-inline-size: max-content;
51 writing-mode: lr;
52 direction: ltr;
53 }
54 @@ -193,8 +194,8 @@
55 margin-block-start: var(--size-5);
56 }
57
58- :where(small) {
59- font-size: max(.5em, var(--font-size-0));
60+ :where(small) {
61+ font-size: max(.5em, var(--font-size-0));
62 max-inline-size: var(--size-content-1);
63 }
64
65 @@ -359,7 +360,7 @@
66 :where(table tr:hover td),
67 :where(tbody tr:nth-child(even):hover td) {
68 background-color: var(--gray-10);
69-
70+
71 @media (prefers-color-scheme: light) {
72 background-color: white;
73 }