From c11d179d3d7ef9b224aaaf849a63e477b2fed10b Mon Sep 17 00:00:00 2001 From: Doxa Maps Date: Thu, 1 Oct 2026 22:21:59 +0000 Subject: [PATCH] Poster Design: a withheld country's large-format cards say why, and are never drawn or printed countrySheet.js now withholds the whole-India poster (WITHHELD, sheetWithheld), and makeCountrySheet returns nothing for India. The three large-format Styles cards use India as their sample, so they showed "preview unavailable" and their print fell through to a stored poster that does not exist. They now answer PosterWall's unsupported with messages.countryPosterTooMany, in the reader's language: the card shows that sentence instead of a preview, and a print opens only that notice. The designs stay in the catalogue, so they return when India is no longer withheld. --- plugin-designs/poster-design/poster-styles.vue | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/plugin-designs/poster-design/poster-styles.vue b/plugin-designs/poster-design/poster-styles.vue index e27a14009..0b6961441 100644 --- a/plugin-designs/poster-design/poster-styles.vue +++ b/plugin-designs/poster-design/poster-styles.vue @@ -22,7 +22,7 @@ import { createPeopleGroupRecords } from '@map/lists/peopleGroupRecords.js' import { getApiBaseUrl } from '@map/api/apiBaseUrl.js' import { getRuntimeLocale, detectLocale } from '@map/i18n/index.js' import countryData from '@map/data/country-posters.json' -import { makeCountrySheet } from '@map/packet/countrySheet.js' +import { makeCountrySheet, sheetWithheld } from '@map/packet/countrySheet.js' import { loadPacketStrings } from '@map/packet/packetStrings.js' import { firstPageImage } from './src/pageThumb.js' import { panelsSvgUrl } from './src/panelsSvg.js' @@ -54,6 +54,14 @@ const groupBy = (item) => t(FAMILY_KEYS[byName.get(item.id)?.family] || FAMILY_K // ── drawing a configuration from the library ────────────────────────────────────────────────── const countryById = (id) => (countryData.countries || []).find((c) => c.id === id) +// A design whose sample country is WITHHELD (countrySheet.js: the whole-India poster, for now) shows this sentence on its +// card and is never drawn or printed: PosterWall answers `unsupported` before it draws a preview or starts a print. The +// designs stay in the catalogue, so they reappear the day the country is no longer withheld. +const withheld = (item) => { + const c = byName.get(item.id) + const sample = c && c.sample ? countryById(c.sample) : null + return sample && sheetWithheld(sample) ? t('messages.countryPosterTooMany') : null +} const sample = countryById(SAMPLE_COUNTRY_ID) const recordsFor = createPeopleGroupRecords({ apiBase: () => profileConfig.value?.apiBaseUrl || getApiBaseUrl(), @@ -192,6 +200,7 @@ useShadowStyles(` :collapsible="true" :header-action="{ labelKey: 'posterDesign.showFullDetails', ariaKey: 'posterDesign.showFullDetailsAria' }" :preview-src="previewSrc" + :unsupported="withheld" :sheet="sheet" :hide-prayer-list-when-soon="true" download-prefix="doxa-poster-design"