Skip to content

Commit 01a0d16

Browse files
thebenternclaude
andcommitted
Remove dividers from the basemap menu items
The basemap switcher's items are buttons nested in .mt-basemap-list, so MapLibre's `.maplibregl-ctrl-group button + button` rule drew a #ddd top border between them (it out-specifies .mt-basemap-item, which my earlier direct-child scoping didn't cover). Scope the item rules under .mt-basemap-list so border:0 wins, and give the active basemap a subtle green wash instead of flat grey. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent c42c536 commit 01a0d16

1 file changed

Lines changed: 13 additions & 6 deletions

File tree

src/style.css

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -470,28 +470,35 @@ body {
470470
padding: 0.375rem;
471471
}
472472

473-
.mt-basemap-item {
473+
/* Scoped under .mt-basemap-list so `border: 0` out-specifies MapLibre's
474+
* `.maplibregl-ctrl-group button + button` top border, which otherwise draws a
475+
* #ddd divider between these nested menu items. Items read as clean padded
476+
* rows: hover tint, and a subtle green wash for the active basemap. */
477+
.mt-basemap-list .mt-basemap-item {
474478
display: block;
475479
width: 100% !important;
476480
height: auto !important;
477-
padding: 0.5rem 0.75rem;
481+
padding: 0.4375rem 0.625rem;
478482
background: none;
479483
border: 0;
480-
border-radius: 0.375rem;
484+
border-radius: 0.5rem;
481485
color: var(--mt-on-surface);
482486
font-size: 0.8125rem;
483487
font-weight: 600;
484488
text-align: left;
485489
cursor: pointer;
490+
transition:
491+
background-color 0.12s ease,
492+
color 0.12s ease;
486493
}
487494

488-
.mt-basemap-item:hover {
495+
.mt-basemap-list .mt-basemap-item:hover {
489496
background: var(--mt-surface-container-highest);
490497
}
491498

492-
.mt-basemap-item.active {
499+
.mt-basemap-list .mt-basemap-item.active {
493500
color: var(--mt-primary);
494-
background: var(--mt-surface-container-highest);
501+
background: rgba(103, 234, 148, 0.14);
495502
}
496503

497504
/* ---------- Map: popups ---------- */

0 commit comments

Comments
 (0)