fix(admin): collapse location list by default
This commit is contained in:
@@ -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");
|
||||||
|
|||||||
@@ -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">
|
||||||
|
|||||||
Reference in New Issue
Block a user