Symmetric sidebars: the charts rail matches the left sidebar, centring the map
Some checks are pending
build-gate / build (push) Waiting to run

Driver: 'the charts sidebar can be wider so it is the same width as the
left sidebar, which will put the map in the exact centre.' rail 264 -> 296
everywhere the number lives (inline var, both CSS fallbacks, the
composable's DEFAULTS, the doc comment) -- one quantity, every owner moved
together this time.

Measured: facet 296, rail 296, map margins 297 both sides, centred true.
This commit is contained in:
doxa-maps-88655c70 2026-09-23 21:33:07 +00:00
parent e315487e2b
commit 564af57c4e
9 changed files with 24 additions and 21 deletions

View file

@ -256,7 +256,10 @@ useShadowStyles(`
ONE line, while the charts carry a donut plus a legend that can wrap.
So the widths SWAP ROLES: the tree takes the wider column, the charts the narrower.
The pair still sums to 560px, so the centre map cell is unchanged. */
--facet-w:296px; --rail-w:264px;
/* ★ SYMMETRIC SIDEBARS (Driver 2026-09-23: "the charts sidebar can be wider so it is the
same width as the left sidebar, which will put the map in the exact center"). rail
264 -> 296 = facet width; equal flanks centre the middle column by construction. */
--facet-w:296px; --rail-w:296px;
/* ── ★ ONE EDGE GUTTER FOR THE WHOLE HEADER STACK ────────────────────────────────────
(card BUILD-THE-FOUR-HEADERS-ARE-ONE-CENTRED-STACK: "on the edges there should be padding
so that everything lines up perfectly.")
@ -290,7 +293,7 @@ useShadowStyles(`
--r-lg:10px; --r-md:6px; --r-pill:999px; }
.profile-loader{ width:100%; height:100%; }
.rd-shell{ position:relative; display:grid; width:100%; height:100%; min-height:560px; box-sizing:border-box;
grid-template-columns: var(--facet-w,296px) minmax(0,1fr) var(--rail-w,264px);
grid-template-columns: var(--facet-w,296px) minmax(0,1fr) var(--rail-w,296px);
grid-template-rows: var(--rd-topbar-h,38px) auto var(--rd-stats-h,22px) 1fr var(--table-h,34%);
grid-template-areas: "topbar topbar topbar" "filters filters filters" "stats stats stats" "facets map rail" "facets table rail";
gap:1px; background:var(--rd-line, #d1d4cd); container-type:inline-size;
@ -313,7 +316,7 @@ useShadowStyles(`
/* Facet/rail collapse — override the COLUMN template (not the --*-w vars) so collapse wins
over a dragged inline width, exactly like the table row-template above. Map is minmax(0,1fr)
and self-resizes via DashboardMapPanel's ResizeObserver → map.resize(). */
.rd-shell.rd-facet-collapsed{ grid-template-columns:0 minmax(0,1fr) var(--rail-w,264px); }
.rd-shell.rd-facet-collapsed{ grid-template-columns:0 minmax(0,1fr) var(--rail-w,296px); }
.rd-shell.rd-rail-collapsed{ grid-template-columns:var(--facet-w,296px) minmax(0,1fr) 0; }
.rd-shell.rd-facet-collapsed.rd-rail-collapsed{ grid-template-columns:0 minmax(0,1fr) 0; }
/* Always-reachable edge carets pinned to the map, toggle each rail (desktop only). */

View file

@ -4,7 +4,7 @@
* A dashboard shell (see plugin-designs/doxa-research-dashboards/research-dashboards.vue) is a CSS
* grid whose three flexible tracks are driven by CSS custom properties:
* --facet-w (left facet-rail column width) default 296px
* --rail-w (right charts-rail column width) default 264px
* --rail-w (right charts-rail column width) default 296px — equals --facet-w, so the map column sits centred
* --table-h (bottom table row height) default 34% (map above it is the 1fr hero)
*
* This composable OWNS those three vars: it exposes pointer-based drag handlers (one per edge),
@ -101,7 +101,7 @@ import { ref, unref, onMounted, onBeforeUnmount } from 'vue'
// promise is unchanged; only the map's share shrinks -- and the map compensates by DEFAULTING
// MORE ZOOMED OUT with the world-floor released on the globe (see DashboardMapPanel), so a
// shorter map shows MORE world, not less.
const DEFAULTS = { facetW: 296, railW: 264, tableH: '34%', mapH: 260, shellH: 502 }
const DEFAULTS = { facetW: 296, railW: 296, tableH: '34%', mapH: 260, shellH: 502 }
const CLAMPS = { facetW: [160, 420], railW: [200, 520], tableH: [12, 70], mapH: [220, 1400], shellH: [400, 2600] }
// Mirrors the CSS fallback --rd-table-bar-h (research-dashboard.vue's .rd-table-bar budget calc) —

File diff suppressed because one or more lines are too long

View file

@ -40,7 +40,7 @@
<script>window.MAP_APP_API_URL = "https://pray.doxa.life";</script>
<!-- Bundle IIFE — registers the <dashboard-plus-grid> custom element. -->
<script src="../../dashboard-plus-grid.js" integrity="sha384-0KeXTmj2Q9XKI6AEzKzFz6EhsHkOwEdGYQfe954jOg42tMYpgt9m/XAaCUi9btzW" crossorigin="anonymous"></script>
<script src="../../dashboard-plus-grid.js" integrity="sha384-zBtRlx3cFqHWsuOochNdwrzQCo6GHsY2MbOY9zGhLS9PqBCAr0cbkdQWRFN3/+Cf" crossorigin="anonymous"></script>
<script>
// Mapbox token resolution — the A3 ladder, in precedence order:

View file

@ -40,7 +40,7 @@
<script>window.MAP_APP_API_URL = "https://pray.doxa.life";</script>
<!-- Bundle IIFE — registers the <dashboard-plus-grid> custom element. -->
<script src="../dashboard-plus-grid.js" integrity="sha384-0KeXTmj2Q9XKI6AEzKzFz6EhsHkOwEdGYQfe954jOg42tMYpgt9m/XAaCUi9btzW" crossorigin="anonymous"></script>
<script src="../dashboard-plus-grid.js" integrity="sha384-zBtRlx3cFqHWsuOochNdwrzQCo6GHsY2MbOY9zGhLS9PqBCAr0cbkdQWRFN3/+Cf" crossorigin="anonymous"></script>
<script>
// Mapbox token resolution — the A3 ladder, in precedence order:

File diff suppressed because one or more lines are too long

View file

@ -193,7 +193,7 @@
"bundle": "dashboard-plus-grid",
"scriptUrl": "./dashboard-plus-grid/dashboard-plus-grid.js",
"output": "doxa-maps/dashboard-plus-grid/dashboard-plus-grid.js",
"integrity": "sha384-0KeXTmj2Q9XKI6AEzKzFz6EhsHkOwEdGYQfe954jOg42tMYpgt9m/XAaCUi9btzW",
"integrity": "sha384-zBtRlx3cFqHWsuOochNdwrzQCo6GHsY2MbOY9zGhLS9PqBCAr0cbkdQWRFN3/+Cf",
"elements": [
"dashboard-plus-grid"
],
@ -213,7 +213,7 @@
"scriptUrl": "./dashboard-plus-grid/dashboard-plus-grid.js",
"embed": {
"iframe": "<iframe src=\"./dashboard-plus-grid/dashboard-plus-grid/index.html?utm_source=YOUR_SOURCE\" width=\"100%\" height=\"600\" style=\"border:none;border-radius:12px;\" allowfullscreen></iframe>",
"script": "<script>window.MAP_APP_API_URL=\"https://pray.doxa.life\";</script>\n<script src=\"./dashboard-plus-grid/dashboard-plus-grid.js\" integrity=\"sha384-0KeXTmj2Q9XKI6AEzKzFz6EhsHkOwEdGYQfe954jOg42tMYpgt9m/XAaCUi9btzW\" crossorigin=\"anonymous\"></script>\n<dashboard-plus-grid profile-config='{\"profile\":\"dashboard-plus-grid\",\"tk\":\"YOUR_MAPBOX_TOKEN\",\"utmSource\":\"YOUR_SOURCE\",\"assetsBase\":\"YOUR_TREE_URL/assets\"}'></dashboard-plus-grid>"
"script": "<script>window.MAP_APP_API_URL=\"https://pray.doxa.life\";</script>\n<script src=\"./dashboard-plus-grid/dashboard-plus-grid.js\" integrity=\"sha384-zBtRlx3cFqHWsuOochNdwrzQCo6GHsY2MbOY9zGhLS9PqBCAr0cbkdQWRFN3/+Cf\" crossorigin=\"anonymous\"></script>\n<dashboard-plus-grid profile-config='{\"profile\":\"dashboard-plus-grid\",\"tk\":\"YOUR_MAPBOX_TOKEN\",\"utmSource\":\"YOUR_SOURCE\",\"assetsBase\":\"YOUR_TREE_URL/assets\"}'></dashboard-plus-grid>"
},
"instances": [
{
@ -878,7 +878,7 @@
"bundle": "research-dashboard",
"scriptUrl": "./research-dashboard/research-dashboard.js",
"output": "doxa-maps/research-dashboard/research-dashboard.js",
"integrity": "sha384-j44OuRGe7ZN8HsjwTkFHdthEc/j7dUdSD8DV+Ht6FayakDELokzZZbMdkx+f03Cj",
"integrity": "sha384-y+QrokwdN8T660MHnspQcvfw8igrKkt+EXDljWQRXGK1XuIPq1wcK8Ed7uYV58nX",
"elements": [
"research-dashboard-map"
],
@ -894,7 +894,7 @@
"scriptUrl": "./research-dashboard/research-dashboard.js",
"embed": {
"iframe": "<iframe src=\"./research-dashboard/research-dashboard/index.html?utm_source=YOUR_SOURCE\" width=\"100%\" height=\"600\" style=\"border:none;border-radius:12px;\" allowfullscreen></iframe>",
"script": "<script>window.MAP_APP_API_URL=\"https://pray.doxa.life\";</script>\n<script src=\"./research-dashboard/research-dashboard.js\" integrity=\"sha384-j44OuRGe7ZN8HsjwTkFHdthEc/j7dUdSD8DV+Ht6FayakDELokzZZbMdkx+f03Cj\" crossorigin=\"anonymous\"></script>\n<research-dashboard-map profile-config='{\"profile\":\"research-dashboard\",\"tk\":\"YOUR_MAPBOX_TOKEN\",\"utmSource\":\"YOUR_SOURCE\",\"assetsBase\":\"YOUR_TREE_URL/assets\"}'></research-dashboard-map>"
"script": "<script>window.MAP_APP_API_URL=\"https://pray.doxa.life\";</script>\n<script src=\"./research-dashboard/research-dashboard.js\" integrity=\"sha384-y+QrokwdN8T660MHnspQcvfw8igrKkt+EXDljWQRXGK1XuIPq1wcK8Ed7uYV58nX\" crossorigin=\"anonymous\"></script>\n<research-dashboard-map profile-config='{\"profile\":\"research-dashboard\",\"tk\":\"YOUR_MAPBOX_TOKEN\",\"utmSource\":\"YOUR_SOURCE\",\"assetsBase\":\"YOUR_TREE_URL/assets\"}'></research-dashboard-map>"
},
"bundle": "research-dashboard"
}

File diff suppressed because one or more lines are too long

View file

@ -29,7 +29,7 @@
<script>window.MAP_APP_API_URL = "https://pray.doxa.life";</script>
<!-- Bundle IIFE — registers the <research-dashboard-map> custom element. -->
<script src="../research-dashboard.js" integrity="sha384-j44OuRGe7ZN8HsjwTkFHdthEc/j7dUdSD8DV+Ht6FayakDELokzZZbMdkx+f03Cj" crossorigin="anonymous"></script>
<script src="../research-dashboard.js" integrity="sha384-y+QrokwdN8T660MHnspQcvfw8igrKkt+EXDljWQRXGK1XuIPq1wcK8Ed7uYV58nX" crossorigin="anonymous"></script>
<script>
// Mapbox token resolution — the A3 ladder, in precedence order: