fix(admin): collapse location list by default
CI / validate (push) Successful in 5m35s
Release / release (push) Successful in 7m40s

This commit is contained in:
dmg
2026-08-02 12:11:07 -04:00
parent 9f0832a5b5
commit eb1c5b6de4
2 changed files with 3 additions and 2 deletions
@@ -44,7 +44,8 @@ describe("UserWorldMap", () => {
expect(markup).toContain("Alex (AlexMC)"); expect(markup).toContain("Alex (AlexMC)");
expect(markup).toContain("2 users near Mountain View, California, US"); expect(markup).toContain("2 users near Mountain View, California, US");
expect(markup).toMatch(/<text[^>]*>2<\/text>/); expect(markup).toMatch(/<text[^>]*>2<\/text>/);
expect(markup).toContain('<details class="mt-5 border-t border-line pt-4" id="map-location-list" open="">'); expect(markup).toContain('<details class="mt-5 border-t border-line pt-4" id="map-location-list">');
expect(markup).not.toContain('id="map-location-list" open');
expect(markup).toContain("Mountain View, California, US"); expect(markup).toContain("Mountain View, California, US");
expect(markup).toContain("Comcast Cable Communications, LLC"); expect(markup).toContain("Comcast Cable Communications, LLC");
expect(markup).toContain("AS7922"); expect(markup).toContain("AS7922");
+1 -1
View File
@@ -99,7 +99,7 @@ export function UserWorldMap({ locations, unavailableCount }: { locations: UserM
</MapViewToggle> </MapViewToggle>
<p className="mt-2 text-right font-mono text-[9px] text-muted">Map boundaries: Natural Earth, public domain</p> <p className="mt-2 text-right font-mono text-[9px] text-muted">Map boundaries: Natural Earth, public domain</p>
<details className="mt-5 border-t border-line pt-4" id="map-location-list" open={locationGroups.some((group) => group.count > 1)}> <details className="mt-5 border-t border-line pt-4" id="map-location-list">
<summary className="w-fit cursor-pointer font-mono text-[10px] font-bold uppercase underline underline-offset-4">View accessible location list</summary> <summary className="w-fit cursor-pointer font-mono text-[10px] font-bold uppercase underline underline-offset-4">View accessible location list</summary>
<div className="mt-4 overflow-x-auto"> <div className="mt-4 overflow-x-auto">
<table className="w-full min-w-[980px] border-collapse text-left text-xs"> <table className="w-full min-w-[980px] border-collapse text-left text-xs">