-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy paththeme.css
More file actions
186 lines (166 loc) · 5.33 KB
/
Copy paththeme.css
File metadata and controls
186 lines (166 loc) · 5.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
/* Blume owns the docs shell; map its palette onto shadcn's semantic contract
so registry components keep their native appearance in every theme. */
:root {
--protoform-destructive: oklch(0.577 0.245 27.325);
--background: var(--blume-background);
--foreground: var(--blume-foreground);
--card: var(--blume-background);
--card-foreground: var(--blume-foreground);
--popover: var(--blume-background);
--popover-foreground: var(--blume-foreground);
--primary: var(--blume-foreground);
--primary-foreground: var(--blume-background);
--secondary: var(--blume-muted);
--secondary-foreground: var(--blume-foreground);
--muted: var(--blume-muted);
--muted-foreground: var(--blume-muted-foreground);
--accent: var(--blume-accent);
--accent-foreground: var(--blume-accent-foreground);
--destructive: var(--protoform-destructive);
--border: var(--blume-border);
--input: var(--blume-border);
--ring: var(--blume-foreground);
--selected: var(--blume-foreground);
--selected-foreground: var(--blume-background);
--selection: var(--blume-foreground);
--selection-foreground: var(--blume-background);
}
:root[data-theme="dark"] {
--protoform-destructive: oklch(0.704 0.191 22.216);
}
@theme inline {
--color-background: var(--background);
--color-foreground: var(--foreground);
--color-card: var(--card);
--color-card-foreground: var(--card-foreground);
--color-popover: var(--popover);
--color-popover-foreground: var(--popover-foreground);
--color-primary: var(--primary);
--color-primary-foreground: var(--primary-foreground);
--color-secondary: var(--secondary);
--color-secondary-foreground: var(--secondary-foreground);
--color-muted: var(--muted);
--color-muted-foreground: var(--muted-foreground);
--color-accent: var(--accent);
--color-accent-foreground: var(--accent-foreground);
--color-destructive: var(--destructive);
--color-border: var(--border);
--color-input: var(--input);
--color-ring: var(--ring);
--color-selected: var(--selected);
--color-selected-foreground: var(--selected-foreground);
--color-selection: var(--selection);
--color-selection-foreground: var(--selection-foreground);
}
/* Data-heavy pages opt into more room without widening every prose page. */
#blume-content:has([data-docs-layout="wide"]) > :where(nav, details, article) {
width: 100%;
max-width: 60rem;
}
/* Keep prose measured for reading while live demos use the docs shell's
available center column. This covers both Blume iframe previews and direct
Astro islands without requiring every example page to opt in. */
@media (min-width: 48rem) {
#blume-content {
--protoform-demo-width: min(60rem, calc(100vw - 2rem));
}
#blume-content article > [data-bookstore-workspace],
#blume-content
article
> div:has(iframe[data-blume-example-frame], > astro-island) {
position: relative;
left: 50%;
width: var(--protoform-demo-width);
transform: translateX(-50%);
}
}
@media (min-width: 64rem) {
#blume-content {
--protoform-demo-width: min(60rem, calc(100vw - 18.5rem));
}
}
@media (min-width: 80rem) {
#blume-content {
--protoform-demo-width: min(60rem, calc(100vw - 36rem));
}
}
/* Give Blume's flex-wrapped Mermaid output a definite width. Without this,
the inner div shrink-wraps to the browser's 300px replaced-element default. */
blume-mermaid > div:not([data-diagram-controls]) {
width: 100%;
}
blume-mermaid > div > svg {
margin-inline: auto;
}
:where(blume-mermaid, [data-diagram], [data-architecture-diagram]) {
position: relative;
}
:where(blume-mermaid, [data-diagram], [data-architecture-diagram]):fullscreen {
box-sizing: border-box;
display: flex !important;
align-items: center;
justify-content: center;
width: 100vw;
height: 100dvh;
padding: 2rem;
overflow: auto;
background: var(--blume-background);
}
:where(blume-mermaid, [data-diagram], [data-architecture-diagram]):fullscreen
:where(svg, img, canvas),
[data-diagram-preview] :where(svg, img, canvas) {
width: 100% !important;
max-width: none !important;
height: 100% !important;
max-height: calc(100dvh - 6rem) !important;
object-fit: contain;
}
[data-diagram-preview] > [data-diagram-expanded] {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
min-width: 100%;
height: 100%;
min-height: 100%;
margin: 0;
overflow: auto;
}
/* Shiki's default light-theme orange is below WCAG AA on the docs surface. */
code span[style*="--shiki-light:#E36209"] {
--shiki-light: rgb(150 59 0) !important;
}
/* Component source panes always show the same counter-driven gutter that
Blume exposes as an opt-in for fenced code blocks. */
pre.blume-source > code {
counter-reset: line;
}
pre.blume-source .line::before {
display: inline-block;
width: 1.25rem;
margin-right: 1.25rem;
color: var(--blume-muted-foreground);
text-align: right;
user-select: none;
content: counter(line);
counter-increment: line;
}
.bookstore-source-tabs blume-tabs {
min-width: 0;
margin: 0;
border: 0;
border-radius: 0;
}
.bookstore-source-tabs pre.blume-source {
min-width: 0;
margin: 0;
border: 0;
border-radius: 0;
}
/* Keep the accurate CEL label without showing the expression grammar's icon. */
.prose > pre[data-title="CEL"][data-icon] > .blume-lang-icon {
display: none;
}
.prose > pre[data-title="CEL"][data-icon]::before {
padding-left: 1rem;
}