@loidolt/theme-styles 0.6.0 → 0.8.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/README.md +3 -0
- package/package.json +3 -2
- package/src/accessibility.css +30 -9
- package/src/base.css +1 -1
- package/src/components/actions.css +13 -11
- package/src/components/charts.css +40 -0
- package/src/components/data.css +19 -13
- package/src/components/docs.css +304 -0
- package/src/components/feedback.css +19 -15
- package/src/components/forms.css +43 -30
- package/src/components/layout.css +33 -28
- package/src/components/maps.css +327 -0
- package/src/components/media.css +18 -12
- package/src/components/overlays.css +48 -40
- package/src/components/prose.css +21 -17
- package/src/components/selection.css +29 -22
- package/src/components/surfaces.css +18 -12
- package/src/components.css +3 -0
- package/src/index.css +7 -2
- package/src/presets/compact-dark-auto.css +2 -0
- package/src/presets/compact-dark.css +2 -0
- package/src/presets/compact.css +2 -0
- package/src/presets/loidolt-dark-auto.css +2 -0
- package/src/presets/loidolt-dark.css +2 -0
- package/src/presets/loidolt.css +2 -0
- package/src/presets/soft-dark-auto.css +2 -0
- package/src/presets/soft-dark.css +2 -0
- package/src/presets/soft.css +2 -0
- package/src/utilities.css +10 -4
package/README.md
CHANGED
|
@@ -15,4 +15,7 @@ Deep entry points include `/tokens`, `/base`, `/components`, `/utilities`, `/acc
|
|
|
15
15
|
`/fonts`, `/dark`, and `/dark-auto`. Every slice except `/tokens` expects the token custom
|
|
16
16
|
properties to be loaded first.
|
|
17
17
|
|
|
18
|
+
Built-in style presets live under `/presets/*`: `loidolt`, `soft` and `compact`, each with
|
|
19
|
+
`-dark` and `-dark-auto` companions. They apply under `data-preset="<name>"`.
|
|
20
|
+
|
|
18
21
|
See the [design-system documentation](https://theme.loidolt.space) for customization guidance.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@loidolt/theme-styles",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0",
|
|
4
4
|
"description": "Base styles, fonts, accessibility helpers, and utilities for Loidolt applications",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
"./tokens": "./src/tokens.css",
|
|
11
11
|
"./dark": "./src/dark.css",
|
|
12
12
|
"./dark-auto": "./src/dark-auto.css",
|
|
13
|
+
"./presets/*": "./src/presets/*.css",
|
|
13
14
|
"./base": "./src/base.css",
|
|
14
15
|
"./accessibility": "./src/accessibility.css",
|
|
15
16
|
"./utilities": "./src/utilities.css",
|
|
@@ -28,7 +29,7 @@
|
|
|
28
29
|
"build": "node -e \"console.log('theme-styles: source CSS is publish-ready')\""
|
|
29
30
|
},
|
|
30
31
|
"dependencies": {
|
|
31
|
-
"@loidolt/theme-tokens": "^0.
|
|
32
|
+
"@loidolt/theme-tokens": "^0.8.0"
|
|
32
33
|
},
|
|
33
34
|
"publishConfig": {
|
|
34
35
|
"access": "public",
|
package/src/accessibility.css
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
/* Deep slice: assumes the token custom properties are already loaded.
|
|
2
2
|
Import '@loidolt/theme-styles/tokens' (or the whole '@loidolt/theme-styles') first. */
|
|
3
3
|
:where(:focus-visible) {
|
|
4
|
-
outline:
|
|
5
|
-
outline-offset: 2px;
|
|
4
|
+
outline: var(--loidolt-stroke-focus) solid var(--loidolt-focus-ring);
|
|
5
|
+
outline-offset: 2px; /* @literal clearance between control and ring */
|
|
6
6
|
}
|
|
7
7
|
:where(:focus:not(:focus-visible)) {
|
|
8
8
|
outline: none;
|
|
9
9
|
}
|
|
10
10
|
/*
|
|
11
11
|
* A scroll container clips an outset ring against its own edge, and children that fill the
|
|
12
|
-
* container have nowhere to put one. Draw it inside those instead — same
|
|
12
|
+
* container have nowhere to put one. Draw it inside those instead — same indicator,
|
|
13
13
|
* just on the other side of the border box. Zero specificity, declared after the rule above,
|
|
14
14
|
* so it overrides by document order without escalating specificity.
|
|
15
15
|
*/
|
|
@@ -22,10 +22,16 @@
|
|
|
22
22
|
.ldt-tabs__list,
|
|
23
23
|
.ldt-toggle-group,
|
|
24
24
|
.ldt-listbox,
|
|
25
|
-
.ldt-media-grid
|
|
25
|
+
.ldt-media-grid,
|
|
26
|
+
.ldt-map,
|
|
27
|
+
.ldt-map-features__list,
|
|
28
|
+
.ldt-layer-manager,
|
|
29
|
+
.ldt-code__pre,
|
|
30
|
+
.ldt-toc-panel__wide,
|
|
31
|
+
.ldt-mermaid
|
|
26
32
|
)
|
|
27
33
|
:where(:focus-visible) {
|
|
28
|
-
outline-offset: -
|
|
34
|
+
outline-offset: calc(-1 * var(--loidolt-stroke-focus));
|
|
29
35
|
/* Follow the control's accessible foreground pairing so inset focus stays visible on fills. */
|
|
30
36
|
outline-color: currentColor;
|
|
31
37
|
}
|
|
@@ -62,7 +68,7 @@
|
|
|
62
68
|
z-index: var(--loidolt-z-skip-link);
|
|
63
69
|
top: 0;
|
|
64
70
|
left: 0;
|
|
65
|
-
padding:
|
|
71
|
+
padding: var(--loidolt-space-3) var(--loidolt-space-4);
|
|
66
72
|
color: var(--loidolt-on-accent);
|
|
67
73
|
background: var(--loidolt-accent);
|
|
68
74
|
transform: translateY(-110%);
|
|
@@ -113,7 +119,12 @@
|
|
|
113
119
|
.ldt-media-controls__speed,
|
|
114
120
|
.ldt-media-controls__range,
|
|
115
121
|
.ldt-lightbox__control,
|
|
116
|
-
.ldt-media-carousel__control
|
|
122
|
+
.ldt-media-carousel__control,
|
|
123
|
+
.ldt-map-features__item,
|
|
124
|
+
.ldt-map .maplibregl-ctrl-group button,
|
|
125
|
+
.ldt-layer-manager__toggle,
|
|
126
|
+
.ldt-code__copy,
|
|
127
|
+
.ldt-toc__link
|
|
117
128
|
) {
|
|
118
129
|
min-height: 44px;
|
|
119
130
|
}
|
|
@@ -125,10 +136,20 @@
|
|
|
125
136
|
.ldt-chip__remove,
|
|
126
137
|
.ldt-media-controls__button,
|
|
127
138
|
.ldt-lightbox__control,
|
|
128
|
-
.ldt-media-carousel__control
|
|
139
|
+
.ldt-media-carousel__control,
|
|
140
|
+
.ldt-map .maplibregl-ctrl-group button
|
|
129
141
|
) {
|
|
130
142
|
min-width: 44px;
|
|
131
143
|
}
|
|
144
|
+
/* A map marker keeps its drawn size — it points at a spot — and takes a 44px touch. */
|
|
145
|
+
.ldt-map-marker::after {
|
|
146
|
+
content: '';
|
|
147
|
+
position: absolute;
|
|
148
|
+
inset: 50% auto auto 50%;
|
|
149
|
+
width: 44px;
|
|
150
|
+
height: 44px;
|
|
151
|
+
transform: translate(-50%, -50%);
|
|
152
|
+
}
|
|
132
153
|
/* The thumb keeps its drawn size; an invisible 44px square around it takes the touch. */
|
|
133
154
|
.ldt-slider__thumb {
|
|
134
155
|
position: relative;
|
|
@@ -173,7 +194,7 @@
|
|
|
173
194
|
|
|
174
195
|
@media (forced-colors: active) {
|
|
175
196
|
:where(button, input, select, textarea, [role='button']) {
|
|
176
|
-
border: 1px solid ButtonText;
|
|
197
|
+
border: 1px solid ButtonText; /* @literal forced-colors boundary */
|
|
177
198
|
}
|
|
178
199
|
:where(:focus-visible) {
|
|
179
200
|
outline-color: Highlight;
|
package/src/base.css
CHANGED
|
@@ -9,17 +9,18 @@
|
|
|
9
9
|
justify-content: center;
|
|
10
10
|
gap: var(--loidolt-space-2);
|
|
11
11
|
border: var(--loidolt-border-width) solid var(--loidolt-border-strong);
|
|
12
|
-
border-radius: var(--loidolt-
|
|
13
|
-
padding:
|
|
12
|
+
border-radius: var(--loidolt-radius-control);
|
|
13
|
+
padding: var(--loidolt-pad-control-y) var(--loidolt-pad-control-x);
|
|
14
14
|
color: var(--loidolt-text);
|
|
15
15
|
background: transparent;
|
|
16
16
|
font: var(--loidolt-font-size-sm) var(--loidolt-font-utility);
|
|
17
|
-
|
|
17
|
+
font-weight: var(--loidolt-control-weight);
|
|
18
|
+
letter-spacing: var(--loidolt-control-tracking);
|
|
18
19
|
line-height: 1.2;
|
|
19
20
|
overflow-wrap: anywhere;
|
|
20
21
|
text-align: center;
|
|
21
22
|
text-decoration: none;
|
|
22
|
-
text-transform:
|
|
23
|
+
text-transform: var(--loidolt-control-transform);
|
|
23
24
|
white-space: normal;
|
|
24
25
|
}
|
|
25
26
|
.ldt-button:hover:not(:disabled, [aria-disabled='true']) {
|
|
@@ -60,7 +61,7 @@
|
|
|
60
61
|
.ldt-button--text {
|
|
61
62
|
/* 1.5rem is the WCAG 2.2 minimum target size; `auto` left this at ~22px. */
|
|
62
63
|
min-height: 1.5rem;
|
|
63
|
-
padding:
|
|
64
|
+
padding: var(--loidolt-space-1);
|
|
64
65
|
color: var(--loidolt-text-muted);
|
|
65
66
|
}
|
|
66
67
|
.ldt-button--text:hover:not(:disabled, [aria-disabled='true']) {
|
|
@@ -69,12 +70,12 @@
|
|
|
69
70
|
}
|
|
70
71
|
.ldt-button--sm {
|
|
71
72
|
min-height: var(--loidolt-size-control-sm);
|
|
72
|
-
padding:
|
|
73
|
+
padding: var(--loidolt-pad-control-y-sm) var(--loidolt-pad-control-x-sm);
|
|
73
74
|
font-size: var(--loidolt-font-size-xs);
|
|
74
75
|
}
|
|
75
76
|
.ldt-button--lg {
|
|
76
77
|
min-height: var(--loidolt-size-control-lg);
|
|
77
|
-
padding-inline:
|
|
78
|
+
padding-inline: var(--loidolt-pad-control-x-lg);
|
|
78
79
|
}
|
|
79
80
|
.ldt-button:disabled,
|
|
80
81
|
.ldt-button[aria-disabled='true'] {
|
|
@@ -99,9 +100,9 @@
|
|
|
99
100
|
.ldt-spinner {
|
|
100
101
|
width: 1em;
|
|
101
102
|
height: 1em;
|
|
102
|
-
border: 2px solid currentColor;
|
|
103
|
+
border: 2px solid currentColor; /* @literal drawn in proportion to its 1em box */
|
|
103
104
|
border-right-color: transparent;
|
|
104
|
-
border-radius: 50%;
|
|
105
|
+
border-radius: 50%; /* @literal a spinner is a circle in every preset */
|
|
105
106
|
animation: ldt-spin 0.7s linear infinite;
|
|
106
107
|
}
|
|
107
108
|
.ldt-spinner--sm {
|
|
@@ -115,7 +116,7 @@
|
|
|
115
116
|
.ldt-spinner--lg {
|
|
116
117
|
width: 2rem;
|
|
117
118
|
height: 2rem;
|
|
118
|
-
border-width: 3px;
|
|
119
|
+
border-width: 3px; /* @literal spinner ring geometry */
|
|
119
120
|
}
|
|
120
121
|
@keyframes ldt-spin {
|
|
121
122
|
to {
|
|
@@ -129,6 +130,7 @@
|
|
|
129
130
|
align-items: center;
|
|
130
131
|
gap: var(--loidolt-space-2);
|
|
131
132
|
border: 0;
|
|
133
|
+
border-radius: var(--loidolt-radius-inner);
|
|
132
134
|
padding: var(--loidolt-space-1) var(--loidolt-space-2);
|
|
133
135
|
color: inherit;
|
|
134
136
|
background: transparent;
|
|
@@ -142,6 +144,6 @@
|
|
|
142
144
|
text-decoration: none;
|
|
143
145
|
}
|
|
144
146
|
.ldt-list-row--selected {
|
|
145
|
-
box-shadow: inset
|
|
147
|
+
box-shadow: inset var(--loidolt-stroke-indicator) 0 0 var(--loidolt-accent);
|
|
146
148
|
background: var(--loidolt-surface-sunken);
|
|
147
149
|
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/* @loidolt/theme-charts. The chart itself is painted by ECharts from the same tokens (read at
|
|
2
|
+
runtime through `createTokenColors`); this file styles everything around the canvas. */
|
|
3
|
+
.ldt-chart {
|
|
4
|
+
display: grid;
|
|
5
|
+
gap: var(--loidolt-space-2);
|
|
6
|
+
min-width: 0;
|
|
7
|
+
margin: 0;
|
|
8
|
+
}
|
|
9
|
+
/* The label voice, as a stat's label: a chart caption names data, it is not a heading. */
|
|
10
|
+
.ldt-chart__title {
|
|
11
|
+
color: var(--loidolt-text-muted);
|
|
12
|
+
font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
|
|
13
|
+
font-weight: var(--loidolt-label-weight);
|
|
14
|
+
letter-spacing: var(--loidolt-label-tracking);
|
|
15
|
+
text-transform: var(--loidolt-label-transform);
|
|
16
|
+
}
|
|
17
|
+
.ldt-chart__canvas,
|
|
18
|
+
.ldt-chart__state {
|
|
19
|
+
position: relative;
|
|
20
|
+
width: 100%;
|
|
21
|
+
min-width: 0;
|
|
22
|
+
height: var(--ldt-chart-height, 20rem);
|
|
23
|
+
}
|
|
24
|
+
.ldt-chart__canvas[hidden] {
|
|
25
|
+
display: none;
|
|
26
|
+
}
|
|
27
|
+
.ldt-chart__state.ldt-empty-state {
|
|
28
|
+
height: auto;
|
|
29
|
+
min-height: var(--ldt-chart-height, 20rem);
|
|
30
|
+
align-content: center;
|
|
31
|
+
}
|
|
32
|
+
.ldt-chart__alert :where(p) {
|
|
33
|
+
margin: 0 0 0.5rem;
|
|
34
|
+
}
|
|
35
|
+
.ldt-chart__table-toggle {
|
|
36
|
+
justify-self: start;
|
|
37
|
+
}
|
|
38
|
+
.ldt-chart__table[hidden] {
|
|
39
|
+
display: none;
|
|
40
|
+
}
|
package/src/components/data.css
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
width: 100%;
|
|
3
3
|
overflow-x: auto;
|
|
4
4
|
border: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
5
|
+
border-radius: var(--loidolt-radius-surface);
|
|
5
6
|
}
|
|
6
7
|
.ldt-table {
|
|
7
8
|
width: 100%;
|
|
@@ -10,15 +11,16 @@
|
|
|
10
11
|
background: var(--loidolt-surface);
|
|
11
12
|
}
|
|
12
13
|
.ldt-table :where(th, td) {
|
|
13
|
-
padding:
|
|
14
|
+
padding: var(--loidolt-pad-cell);
|
|
14
15
|
border-bottom: var(--loidolt-border-width) solid var(--loidolt-border-soft);
|
|
15
16
|
text-align: left;
|
|
16
17
|
}
|
|
17
18
|
.ldt-table th {
|
|
18
19
|
color: var(--loidolt-text-muted);
|
|
19
20
|
font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
font-weight: var(--loidolt-label-weight);
|
|
22
|
+
letter-spacing: var(--loidolt-label-tracking);
|
|
23
|
+
text-transform: var(--loidolt-label-transform);
|
|
22
24
|
}
|
|
23
25
|
.ldt-table tbody tr:last-child td {
|
|
24
26
|
border-bottom: 0;
|
|
@@ -50,12 +52,12 @@
|
|
|
50
52
|
/* `border-collapse: collapse` drops the borders of a sticky cell — the collapsed edge belongs
|
|
51
53
|
to the table, which scrolls away. An inset shadow is painted by the cell itself and stays. */
|
|
52
54
|
border-bottom: 0;
|
|
53
|
-
box-shadow: inset 0 -
|
|
55
|
+
box-shadow: inset 0 calc(-1 * var(--loidolt-border-width)) 0 var(--loidolt-border);
|
|
54
56
|
}
|
|
55
57
|
.ldt-table__sort {
|
|
56
58
|
display: inline-flex;
|
|
57
59
|
align-items: center;
|
|
58
|
-
gap: 0.4rem;
|
|
60
|
+
gap: 0.4rem; /* @literal glyph-to-label spacing, not density */
|
|
59
61
|
border: 0;
|
|
60
62
|
padding: 0;
|
|
61
63
|
color: inherit;
|
|
@@ -73,8 +75,8 @@
|
|
|
73
75
|
.ldt-table__sort-indicator {
|
|
74
76
|
width: 0;
|
|
75
77
|
height: 0;
|
|
76
|
-
border-inline: 0.3rem solid transparent;
|
|
77
|
-
border-bottom: 0.34rem solid currentColor;
|
|
78
|
+
border-inline: 0.3rem solid transparent; /* @literal CSS triangle geometry */
|
|
79
|
+
border-bottom: 0.34rem solid currentColor; /* @literal CSS triangle geometry */
|
|
78
80
|
opacity: 0;
|
|
79
81
|
}
|
|
80
82
|
.ldt-table__sort:hover .ldt-table__sort-indicator {
|
|
@@ -99,9 +101,10 @@
|
|
|
99
101
|
.ldt-empty-state {
|
|
100
102
|
display: grid;
|
|
101
103
|
justify-items: center;
|
|
102
|
-
gap:
|
|
104
|
+
gap: var(--loidolt-space-2);
|
|
103
105
|
padding: var(--loidolt-space-10) var(--loidolt-space-6);
|
|
104
106
|
border: var(--loidolt-border-width) dashed var(--loidolt-border);
|
|
107
|
+
border-radius: var(--loidolt-radius-surface);
|
|
105
108
|
color: var(--loidolt-text-muted);
|
|
106
109
|
background: var(--loidolt-surface);
|
|
107
110
|
text-align: center;
|
|
@@ -124,7 +127,7 @@
|
|
|
124
127
|
display: flex;
|
|
125
128
|
flex-wrap: wrap;
|
|
126
129
|
justify-content: center;
|
|
127
|
-
gap: var(--loidolt-
|
|
130
|
+
gap: var(--loidolt-gap-actions);
|
|
128
131
|
margin-top: var(--loidolt-space-2);
|
|
129
132
|
}
|
|
130
133
|
/* Trailing action cell in a data table: content hugs the right edge, inline forms welcome. */
|
|
@@ -151,6 +154,7 @@
|
|
|
151
154
|
display: flex;
|
|
152
155
|
align-items: flex-start;
|
|
153
156
|
gap: var(--loidolt-space-2);
|
|
157
|
+
border-radius: var(--loidolt-radius-inner);
|
|
154
158
|
padding: var(--loidolt-space-1) var(--loidolt-space-2);
|
|
155
159
|
}
|
|
156
160
|
.ldt-comment--active {
|
|
@@ -175,6 +179,7 @@
|
|
|
175
179
|
gap: var(--loidolt-space-2);
|
|
176
180
|
padding: var(--loidolt-space-2) var(--loidolt-space-3);
|
|
177
181
|
border: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
182
|
+
border-radius: var(--loidolt-radius-surface);
|
|
178
183
|
background: var(--loidolt-surface-sunken);
|
|
179
184
|
}
|
|
180
185
|
.ldt-code-block__code {
|
|
@@ -225,7 +230,7 @@
|
|
|
225
230
|
background: var(--loidolt-surface-alt);
|
|
226
231
|
}
|
|
227
232
|
.ldt-table tbody tr[data-selected] td:first-child {
|
|
228
|
-
box-shadow: inset
|
|
233
|
+
box-shadow: inset var(--loidolt-stroke-accent) 0 0 var(--loidolt-accent);
|
|
229
234
|
}
|
|
230
235
|
.ldt-data-table__spacer td {
|
|
231
236
|
padding: 0;
|
|
@@ -275,7 +280,7 @@
|
|
|
275
280
|
min-width: 1.25rem;
|
|
276
281
|
place-items: center;
|
|
277
282
|
margin-inline-start: 0.4rem;
|
|
278
|
-
padding-inline: 0.3rem;
|
|
283
|
+
padding-inline: 0.3rem; /* @literal count badge metrics */
|
|
279
284
|
color: var(--loidolt-on-accent);
|
|
280
285
|
background: var(--loidolt-accent);
|
|
281
286
|
font-size: var(--loidolt-font-size-xs);
|
|
@@ -301,8 +306,9 @@
|
|
|
301
306
|
gap: var(--loidolt-space-2);
|
|
302
307
|
color: var(--loidolt-text-muted);
|
|
303
308
|
font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
|
|
304
|
-
|
|
305
|
-
|
|
309
|
+
font-weight: var(--loidolt-label-weight);
|
|
310
|
+
letter-spacing: var(--loidolt-label-tracking);
|
|
311
|
+
text-transform: var(--loidolt-label-transform);
|
|
306
312
|
}
|
|
307
313
|
.ldt-data-table-pagination__size .ldt-select {
|
|
308
314
|
width: auto;
|
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
/* @loidolt/theme-docs. Rendered markdown takes `.ldt-prose` for its typography; this file adds
|
|
2
|
+
what markdown documentation needs beyond it — code frames and highlighting, admonitions,
|
|
3
|
+
footnotes, diagrams, the table of contents, and the page around them. */
|
|
4
|
+
|
|
5
|
+
/* --- Headings that link to themselves ------------------------------------------------------- */
|
|
6
|
+
.ldt-heading-anchor {
|
|
7
|
+
color: inherit;
|
|
8
|
+
text-decoration: none;
|
|
9
|
+
}
|
|
10
|
+
.ldt-heading-anchor:hover {
|
|
11
|
+
text-decoration: underline;
|
|
12
|
+
text-decoration-color: var(--loidolt-accent);
|
|
13
|
+
text-underline-offset: 0.2em;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
/* --- Code ------------------------------------------------------------------------------------ */
|
|
17
|
+
/* Shiki's CSS-variables theme reads `--ldt-syntax-*`; mapping them to the syntax tokens makes
|
|
18
|
+
highlighted code follow the light and dark themes with no second render. */
|
|
19
|
+
.ldt-code {
|
|
20
|
+
--ldt-syntax-foreground: var(--loidolt-text-inverse);
|
|
21
|
+
--ldt-syntax-background: var(--loidolt-surface-inverse);
|
|
22
|
+
--ldt-syntax-token-keyword: var(--loidolt-syntax-keyword);
|
|
23
|
+
--ldt-syntax-token-string: var(--loidolt-syntax-string);
|
|
24
|
+
--ldt-syntax-token-string-expression: var(--loidolt-syntax-string);
|
|
25
|
+
--ldt-syntax-token-comment: var(--loidolt-syntax-comment);
|
|
26
|
+
--ldt-syntax-token-constant: var(--loidolt-syntax-constant);
|
|
27
|
+
--ldt-syntax-token-function: var(--loidolt-syntax-function);
|
|
28
|
+
--ldt-syntax-token-parameter: var(--loidolt-syntax-parameter);
|
|
29
|
+
--ldt-syntax-token-punctuation: var(--loidolt-syntax-punctuation);
|
|
30
|
+
--ldt-syntax-token-link: var(--loidolt-syntax-function);
|
|
31
|
+
margin: 0 0 1.1em;
|
|
32
|
+
min-width: 0;
|
|
33
|
+
}
|
|
34
|
+
.ldt-code__header {
|
|
35
|
+
display: flex;
|
|
36
|
+
gap: var(--loidolt-space-3);
|
|
37
|
+
align-items: center;
|
|
38
|
+
justify-content: space-between;
|
|
39
|
+
min-height: 2rem;
|
|
40
|
+
padding: 0 0 0 var(--loidolt-space-3);
|
|
41
|
+
border: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
42
|
+
border-bottom: 0;
|
|
43
|
+
color: var(--loidolt-text-muted);
|
|
44
|
+
background: var(--loidolt-surface-alt);
|
|
45
|
+
font: var(--loidolt-font-size-xs) var(--loidolt-font-mono);
|
|
46
|
+
}
|
|
47
|
+
.ldt-code__filename {
|
|
48
|
+
overflow: hidden;
|
|
49
|
+
text-overflow: ellipsis;
|
|
50
|
+
white-space: nowrap;
|
|
51
|
+
}
|
|
52
|
+
.ldt-code__copy {
|
|
53
|
+
flex: none;
|
|
54
|
+
margin-inline-start: auto;
|
|
55
|
+
min-height: 2rem;
|
|
56
|
+
padding: 0 var(--loidolt-space-3);
|
|
57
|
+
border: 0;
|
|
58
|
+
border-inline-start: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
59
|
+
color: var(--loidolt-text);
|
|
60
|
+
background: none;
|
|
61
|
+
font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
|
|
62
|
+
font-weight: var(--loidolt-label-weight);
|
|
63
|
+
letter-spacing: var(--loidolt-label-tracking);
|
|
64
|
+
text-transform: var(--loidolt-label-transform);
|
|
65
|
+
cursor: pointer;
|
|
66
|
+
}
|
|
67
|
+
.ldt-code__copy:hover {
|
|
68
|
+
background: var(--loidolt-surface);
|
|
69
|
+
}
|
|
70
|
+
.ldt-code__pre {
|
|
71
|
+
margin: 0;
|
|
72
|
+
padding: 0.9em 1.1em; /* @literal em-based code rhythm */
|
|
73
|
+
overflow-x: auto;
|
|
74
|
+
border: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
75
|
+
color: var(--ldt-syntax-foreground);
|
|
76
|
+
background: var(--ldt-syntax-background);
|
|
77
|
+
font: 0.85em / var(--loidolt-font-line-height-normal) var(--loidolt-font-mono);
|
|
78
|
+
tab-size: 2;
|
|
79
|
+
}
|
|
80
|
+
.ldt-code__pre code {
|
|
81
|
+
padding: 0;
|
|
82
|
+
border: 0;
|
|
83
|
+
color: inherit;
|
|
84
|
+
background: transparent;
|
|
85
|
+
font: inherit;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
/* --- Admonitions ----------------------------------------------------------------------------- */
|
|
89
|
+
.ldt-admonition {
|
|
90
|
+
margin: 0 0 1.1em;
|
|
91
|
+
}
|
|
92
|
+
.ldt-admonition .ldt-alert__title {
|
|
93
|
+
margin: 0 0 0.25rem;
|
|
94
|
+
}
|
|
95
|
+
.ldt-admonition .ldt-alert__description > :last-child {
|
|
96
|
+
margin-bottom: 0;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
/* --- Footnotes ------------------------------------------------------------------------------- */
|
|
100
|
+
.ldt-footnote-ref a {
|
|
101
|
+
padding-inline: 0.1em; /* @literal optical nudge around the marker */
|
|
102
|
+
text-decoration: none;
|
|
103
|
+
}
|
|
104
|
+
.ldt-footnotes {
|
|
105
|
+
margin-top: 2em;
|
|
106
|
+
padding-top: 1em; /* @literal em-based prose rhythm */
|
|
107
|
+
border-top: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
108
|
+
color: var(--loidolt-text-muted);
|
|
109
|
+
font-size: 0.9em;
|
|
110
|
+
}
|
|
111
|
+
.ldt-unsafe-link {
|
|
112
|
+
text-decoration: underline dotted;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/* --- Diagrams -------------------------------------------------------------------------------- */
|
|
116
|
+
.ldt-mermaid {
|
|
117
|
+
display: grid;
|
|
118
|
+
gap: var(--loidolt-space-2);
|
|
119
|
+
margin: 0 0 1.1em;
|
|
120
|
+
padding: var(--loidolt-pad-surface);
|
|
121
|
+
overflow-x: auto;
|
|
122
|
+
border: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
123
|
+
border-radius: var(--loidolt-radius-surface);
|
|
124
|
+
background: var(--loidolt-background);
|
|
125
|
+
}
|
|
126
|
+
.ldt-mermaid__diagram[hidden] {
|
|
127
|
+
display: none;
|
|
128
|
+
}
|
|
129
|
+
.ldt-mermaid__diagram svg {
|
|
130
|
+
display: block;
|
|
131
|
+
max-width: 100%;
|
|
132
|
+
height: auto;
|
|
133
|
+
margin-inline: auto;
|
|
134
|
+
}
|
|
135
|
+
.ldt-mermaid__caption {
|
|
136
|
+
color: var(--loidolt-text-muted);
|
|
137
|
+
font-size: var(--loidolt-font-size-sm);
|
|
138
|
+
}
|
|
139
|
+
.ldt-mermaid__source summary {
|
|
140
|
+
color: var(--loidolt-text-muted);
|
|
141
|
+
font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
|
|
142
|
+
font-weight: var(--loidolt-label-weight);
|
|
143
|
+
letter-spacing: var(--loidolt-label-tracking);
|
|
144
|
+
text-transform: var(--loidolt-label-transform);
|
|
145
|
+
cursor: pointer;
|
|
146
|
+
}
|
|
147
|
+
.ldt-mermaid__source pre,
|
|
148
|
+
.ldt-mermaid__fallback,
|
|
149
|
+
pre.ldt-mermaid {
|
|
150
|
+
margin: 0.5rem 0 0;
|
|
151
|
+
white-space: pre-wrap;
|
|
152
|
+
font: var(--loidolt-font-size-sm) var(--loidolt-font-mono);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
/* --- Table of contents ----------------------------------------------------------------------- */
|
|
156
|
+
.ldt-toc {
|
|
157
|
+
font: var(--loidolt-font-size-sm) var(--loidolt-font-utility);
|
|
158
|
+
}
|
|
159
|
+
.ldt-toc__title {
|
|
160
|
+
margin: 0 0 0.5rem;
|
|
161
|
+
color: var(--loidolt-text-muted);
|
|
162
|
+
font-size: var(--loidolt-font-size-xs);
|
|
163
|
+
letter-spacing: var(--loidolt-label-tracking);
|
|
164
|
+
text-transform: var(--loidolt-label-transform);
|
|
165
|
+
}
|
|
166
|
+
.ldt-toc__list {
|
|
167
|
+
margin: 0;
|
|
168
|
+
padding: 0;
|
|
169
|
+
list-style: none;
|
|
170
|
+
}
|
|
171
|
+
.ldt-toc__item {
|
|
172
|
+
padding-inline-start: calc(var(--ldt-toc-level, 0) * 0.85rem);
|
|
173
|
+
}
|
|
174
|
+
.ldt-toc__link {
|
|
175
|
+
display: flex;
|
|
176
|
+
align-items: center;
|
|
177
|
+
min-block-size: 1.5rem;
|
|
178
|
+
padding: 0.2rem 0 0.2rem 0.65rem; /* @literal rail inset */
|
|
179
|
+
border-inline-start: var(--loidolt-stroke-indicator) solid var(--loidolt-border-soft);
|
|
180
|
+
color: var(--loidolt-text-muted);
|
|
181
|
+
text-decoration: none;
|
|
182
|
+
}
|
|
183
|
+
.ldt-toc__link:hover {
|
|
184
|
+
color: var(--loidolt-text);
|
|
185
|
+
}
|
|
186
|
+
.ldt-toc__link[aria-current='location'] {
|
|
187
|
+
border-inline-start-color: var(--loidolt-accent);
|
|
188
|
+
color: var(--loidolt-text);
|
|
189
|
+
}
|
|
190
|
+
.ldt-toc-panel__wide {
|
|
191
|
+
position: sticky;
|
|
192
|
+
top: var(--ldt-docs-top, calc(var(--loidolt-size-topbar) + 1rem));
|
|
193
|
+
max-height: calc(100vh - var(--ldt-docs-top, calc(var(--loidolt-size-topbar) + 1rem)) - 1rem);
|
|
194
|
+
overflow-y: auto;
|
|
195
|
+
}
|
|
196
|
+
.ldt-toc-panel__compact {
|
|
197
|
+
display: none;
|
|
198
|
+
}
|
|
199
|
+
/* The contents go behind a button where there is no room beside the page for them. */
|
|
200
|
+
@media (max-width: 1023.98px) {
|
|
201
|
+
.ldt-toc-panel__wide {
|
|
202
|
+
display: none;
|
|
203
|
+
}
|
|
204
|
+
.ldt-toc-panel__compact {
|
|
205
|
+
display: block;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
/* --- The page -------------------------------------------------------------------------------- */
|
|
210
|
+
.ldt-markdown-page {
|
|
211
|
+
display: grid;
|
|
212
|
+
gap: var(--loidolt-space-6);
|
|
213
|
+
min-width: 0;
|
|
214
|
+
}
|
|
215
|
+
.ldt-markdown-page__main {
|
|
216
|
+
min-width: 0;
|
|
217
|
+
}
|
|
218
|
+
@media (min-width: 1024px) {
|
|
219
|
+
.ldt-markdown-page--toc {
|
|
220
|
+
grid-template-columns: minmax(0, 1fr) 14rem;
|
|
221
|
+
gap: var(--loidolt-space-10);
|
|
222
|
+
align-items: start;
|
|
223
|
+
}
|
|
224
|
+
.ldt-markdown-page--toc .ldt-markdown-page__toc {
|
|
225
|
+
grid-column: 2;
|
|
226
|
+
grid-row: 1;
|
|
227
|
+
}
|
|
228
|
+
.ldt-markdown-page--toc .ldt-markdown-page__main {
|
|
229
|
+
grid-column: 1;
|
|
230
|
+
grid-row: 1;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
.ldt-markdown-page__pager {
|
|
234
|
+
display: flex;
|
|
235
|
+
flex-wrap: wrap;
|
|
236
|
+
gap: var(--loidolt-space-3);
|
|
237
|
+
justify-content: space-between;
|
|
238
|
+
margin-top: 2.5rem;
|
|
239
|
+
padding-top: var(--loidolt-space-5);
|
|
240
|
+
border-top: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
241
|
+
}
|
|
242
|
+
.ldt-markdown-page__pager a {
|
|
243
|
+
display: grid;
|
|
244
|
+
gap: 0.15rem; /* @literal label-to-title spacing */
|
|
245
|
+
min-width: min(14rem, 100%);
|
|
246
|
+
padding: 0.65rem 0.9rem; /* @literal pager card metrics */
|
|
247
|
+
border: var(--loidolt-border-width) solid var(--loidolt-border);
|
|
248
|
+
border-radius: var(--loidolt-radius-surface);
|
|
249
|
+
color: var(--loidolt-text);
|
|
250
|
+
text-decoration: none;
|
|
251
|
+
}
|
|
252
|
+
.ldt-markdown-page__pager a:hover {
|
|
253
|
+
border-color: var(--loidolt-border-strong);
|
|
254
|
+
}
|
|
255
|
+
.ldt-markdown-page__next {
|
|
256
|
+
margin-inline-start: auto;
|
|
257
|
+
text-align: end;
|
|
258
|
+
}
|
|
259
|
+
.ldt-markdown-page__direction {
|
|
260
|
+
color: var(--loidolt-text-muted);
|
|
261
|
+
font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
|
|
262
|
+
font-weight: var(--loidolt-label-weight);
|
|
263
|
+
letter-spacing: var(--loidolt-label-tracking);
|
|
264
|
+
text-transform: var(--loidolt-label-transform);
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
/* --- Docs index ------------------------------------------------------------------------------ */
|
|
268
|
+
.ldt-docs-hub {
|
|
269
|
+
display: grid;
|
|
270
|
+
gap: 2.25rem; /* @literal hub section rhythm */
|
|
271
|
+
}
|
|
272
|
+
.ldt-docs-hub__title {
|
|
273
|
+
margin: 0;
|
|
274
|
+
}
|
|
275
|
+
.ldt-docs-hub__description {
|
|
276
|
+
margin: 0.35rem 0 0;
|
|
277
|
+
color: var(--loidolt-text-muted);
|
|
278
|
+
}
|
|
279
|
+
.ldt-docs-hub__grid {
|
|
280
|
+
display: grid;
|
|
281
|
+
grid-template-columns: repeat(auto-fill, minmax(min(16rem, 100%), 1fr));
|
|
282
|
+
gap: var(--loidolt-space-4);
|
|
283
|
+
margin: 1rem 0 0;
|
|
284
|
+
padding: 0;
|
|
285
|
+
list-style: none;
|
|
286
|
+
}
|
|
287
|
+
.ldt-docs-hub__grid > li {
|
|
288
|
+
display: grid;
|
|
289
|
+
}
|
|
290
|
+
/* A docs card is often only a heading and a line; drop the empty body and its rule. */
|
|
291
|
+
.ldt-docs-card .ldt-card__content:empty {
|
|
292
|
+
display: none;
|
|
293
|
+
}
|
|
294
|
+
.ldt-docs-card .ldt-card__header:has(+ .ldt-card__content:empty) {
|
|
295
|
+
border-bottom: 0;
|
|
296
|
+
}
|
|
297
|
+
.ldt-docs-card__eyebrow {
|
|
298
|
+
margin: 0 0 0.35rem;
|
|
299
|
+
color: var(--loidolt-text-accent);
|
|
300
|
+
font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
|
|
301
|
+
font-weight: var(--loidolt-label-weight);
|
|
302
|
+
letter-spacing: var(--loidolt-label-tracking-wide);
|
|
303
|
+
text-transform: var(--loidolt-label-transform);
|
|
304
|
+
}
|