diff --git a/plugin-designs/doxa-research-map/research-map.vue b/plugin-designs/doxa-research-map/research-map.vue index e70556067..8dac549ec 100644 --- a/plugin-designs/doxa-research-map/research-map.vue +++ b/plugin-designs/doxa-research-map/research-map.vue @@ -1542,6 +1542,20 @@ function onExport(kind) { if (kind === 'packet') return openPacket() } +// ★ THE PHONE HAD NO EXPORT AT ALL. The desktop legend gets :export-enabled and @export in the +// template, but LegendMobile does not read props from here — it reaches for an injected handler, and +// decides whether to offer the control at all by whether one exists: mobileExportEnabled is +// `typeof onLegendExport === 'function'` (LegendMobile.vue:412-413). Nothing provided it here, so a +// reader on a phone saw no poster and no packet, while the same map on a desktop offered both. Not a +// leak — an absence, which is why it never showed up as a broken control. +// +// ⚠ IT MUST CARRY EXPORT_FEATURE_ENABLED, not just the function. The desktop passes that flag, so +// providing unconditionally would hand the phone an affordance the desktop deliberately hides when +// the flag is off. Passing null when it is off is what makes the mobile sheet hide the control, +// because "is there a handler" IS the mobile switch. Same shape as countries-map.vue, which fixed +// this first (its comment records the same two causes on my-upg-100-list). +provide('onLegendExport', EXPORT_FEATURE_ENABLED ? onExport : null) + // ─── Packet export (printed, multi-page: map + a card per people group) ────── // Lazy-loaded on first use, the same pattern openPoster() uses. Defensive throughout: never throw // uncaught into the UI; guard against double-run.