Skip to content

Commit ae96e00

Browse files
committed
tidying up some small styles
1 parent 6583e52 commit ae96e00

1 file changed

Lines changed: 55 additions & 14 deletions

File tree

docs/src/styles/custom.css

Lines changed: 55 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -251,18 +251,40 @@ header starlight-theme-select {
251251
/* Center the action button group */
252252
.hero .sl-flex .sl-flex {
253253
justify-content: center !important;
254+
align-items: center !important;
255+
gap: 0.75rem !important;
256+
width: 100% !important;
257+
}
258+
259+
/* Primer ButtonBase shared styles (large size) */
260+
.hero .sl-link-button {
261+
align-items: center !important;
262+
appearance: none !important;
263+
border: 0.0625rem solid !important;
264+
border-radius: 0.375rem !important;
265+
cursor: pointer !important;
266+
display: inline-flex !important;
267+
font-family: inherit !important;
268+
font-size: 0.875rem !important;
269+
font-weight: 500 !important;
270+
gap: 0.5rem !important;
271+
height: 2.5rem !important;
272+
justify-content: center !important;
273+
min-width: 10rem !important;
274+
padding: 0 1rem !important;
275+
text-align: center !important;
276+
text-decoration: none !important;
277+
transition: 80ms cubic-bezier(0.33, 1, 0.68, 1) !important;
254278
}
255279

256-
/* Primary CTA button — GitHub green */
280+
/* Primary CTA button — Primer primary variant */
257281
.hero .sl-link-button:first-of-type,
258282
a.sl-link-button[data-variant='primary'],
259283
.sl-link-button.primary {
260284
background-color: #238636 !important;
285+
border-color: rgba(240, 246, 252, 0.1) !important;
286+
box-shadow: 0 1px 0 rgba(27, 31, 36, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.03) !important;
261287
color: #ffffff !important;
262-
border: 2px solid transparent !important;
263-
border-radius: 8px !important;
264-
font-weight: 500;
265-
transition: background-color 0.15s ease;
266288
}
267289

268290
.hero .sl-link-button:first-of-type:hover,
@@ -271,25 +293,25 @@ a.sl-link-button[data-variant='primary']:hover,
271293
background-color: #2ea043 !important;
272294
}
273295

274-
/* Secondary CTA button — translucent like github.com */
296+
/* Secondary CTA button — Primer default variant */
275297
.hero .sl-link-button:not(:first-of-type) {
276-
background-color: rgba(255, 255, 255, 0.07) !important;
298+
background-color: #21262d !important;
299+
border-color: #3d444d !important;
300+
box-shadow: 0 1px 0 rgba(27, 31, 36, 0.04) !important;
277301
color: #f0f6fc !important;
278-
border: 1px solid #3d444d !important;
279-
border-radius: 8px !important;
280-
font-weight: 500;
281-
transition: background-color 0.15s ease, border-color 0.15s ease;
282302
}
283303

284304
.hero .sl-link-button:not(:first-of-type):hover {
285-
background-color: rgba(255, 255, 255, 0.12) !important;
305+
background-color: #30363d !important;
286306
border-color: #656d76 !important;
287307
}
288308

289309
:root[data-theme='light'] .hero .sl-link-button:first-of-type,
290310
:root[data-theme='light'] a.sl-link-button[data-variant='primary'],
291311
:root[data-theme='light'] .sl-link-button.primary {
292312
background-color: #1f883d !important;
313+
border-color: rgba(27, 31, 36, 0.15) !important;
314+
box-shadow: 0 1px 0 rgba(27, 31, 36, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.03) !important;
293315
color: #ffffff !important;
294316
}
295317

@@ -300,13 +322,14 @@ a.sl-link-button[data-variant='primary']:hover,
300322

301323
:root[data-theme='light'] .hero .sl-link-button:not(:first-of-type) {
302324
background-color: #f6f8fa !important;
325+
border-color: rgba(27, 31, 36, 0.15) !important;
326+
box-shadow: 0 1px 0 rgba(27, 31, 36, 0.04) !important;
303327
color: #1f2328 !important;
304-
border: 1px solid #d1d9e0 !important;
305328
}
306329

307330
:root[data-theme='light'] .hero .sl-link-button:not(:first-of-type):hover {
308331
background-color: #eaeef2 !important;
309-
border-color: #afb8c1 !important;
332+
border-color: rgba(27, 31, 36, 0.25) !important;
310333
}
311334

312335
:root[data-theme='light'] .hero h1 {
@@ -880,6 +903,11 @@ nav a[aria-current='page'] {
880903
}
881904
header site-search button {
882905
border: none !important;
906+
font-size: 1rem !important;
907+
color: var(--sl-color-gray-3) !important;
908+
}
909+
header site-search button:hover {
910+
color: var(--sl-color-text) !important;
883911
}
884912
header starlight-theme-select {
885913
display: none !important;
@@ -906,3 +934,16 @@ nav a[aria-current='page'] {
906934
margin-right: 0;
907935
}
908936
}
937+
938+
/* ============================================================
939+
Search dialog — collapse empty results area
940+
============================================================ */
941+
[data-pagefind-ui] .pagefind-ui__results-area:empty,
942+
dialog .results-inner:empty,
943+
dialog [data-search-results]:empty {
944+
display: none !important;
945+
}
946+
947+
dialog.search-dialog .dialog-frame {
948+
max-height: fit-content !important;
949+
}

0 commit comments

Comments
 (0)