feat(selection): lock single-option boxes, drop the about link
build / build (push) Successful in 1m38s
build / build (push) Successful in 1m38s
Recovered work in progress that sat uncommitted since 2026-05: a SelectionBox renders as a plain div instead of a NuxtLink when locked, so a variant with only one choice reads as decided rather than clickable, and it reports aria-checked in that state. useProductContent gained the content lookups the details and index pages now use, the cookie banner says Schließen instead of Akzeptieren, the Über uns header entry is gone, and ProductCard's hover shadow no longer relies on a short-circuit that could yield a non-array.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
// Product content keyed by cover type
|
||||
// This content is displayed on product detail pages as storytelling modules
|
||||
|
||||
export type CoverType = "Hardcover" | "Softcover" | "Heft" | "Spiralbindung";
|
||||
export type CoverType = "Hardcover" | "Softcover" | "Heft" | "Spiralbindung" | "Promo";
|
||||
|
||||
export interface FeatureModule {
|
||||
eyebrow?: string;
|
||||
@@ -199,6 +199,44 @@ export const FEATURE_MODULES: Record<CoverType, FeatureModule[]> = {
|
||||
imageRight: true,
|
||||
},
|
||||
],
|
||||
|
||||
Promo: [
|
||||
{
|
||||
eyebrow: "12 Wochen · 3 Monate",
|
||||
headline: "Struktur für deinen Alltag",
|
||||
subtitle: "Planung, Intention & Reflexion",
|
||||
body: `Dieses Journaling Booklet im Format A5 sorgt für mehr Produktivität im Alltag.
|
||||
Es beinhaltet Monats-, Wochen- und Tagesplanungen sowie inspirierenden Zitaten
|
||||
für insgesamt 12 Wochen bzw. 3 Monate. Jeder Tag bietet Platz für eine
|
||||
Tagesintention, den täglichen Aufgaben, dem Notieren von Mahlzeiten und der
|
||||
Fitnessroutine. Darüber hinaus bietet es die Möglichkeit der eigene
|
||||
Tagesreflexion. Als tägliche Begleiter soll es helfen, deine Zeit effektiv zu
|
||||
managen, um mit mehr Klarheit und Struktur deine Ziele anzugehen.`,
|
||||
imageRight: true,
|
||||
},
|
||||
{
|
||||
eyebrow: "Gestaltet von mk rietzl",
|
||||
headline: "VIVUS 89 Recyclingpapier",
|
||||
subtitle: "Matt, 120g/qm, fliederfarbener Umschlag",
|
||||
body: `Das Journaling Booklet wurde konzipiert und gestaltet von Michèle Rietzl
|
||||
(mk rietzl). Es ist auf VIVUS 89 Recyclingpapier gedruckt. Die matte,
|
||||
ungestrichene Oberfläche mit feiner Textur verhindert Durchschlagen – selbst bei
|
||||
Füllfederhaltern und Aquarellfarben. Mit 120g/qm und 1,2-fachem Volumen fühlt
|
||||
sich jede Seite substanziell an, ohne starr zu wirken. Der fliederfarbene
|
||||
Umschlag sorgt für schlichte Farbakzente.`,
|
||||
imageRight: false,
|
||||
},
|
||||
{
|
||||
eyebrow: "Handgefertigt in Stuttgart",
|
||||
headline: "Fadenbindung mit offenem Buchrücken",
|
||||
subtitle: "Vollständiges Aufklappen zum Schreiben",
|
||||
body: `Bei der Bindung handelt es sich um eine klassische Fadenbindung mit offenem
|
||||
Buchrücken. Dies ermöglicht ein vollständiges Aufklappen, was sich ideal zum
|
||||
Schreiben eignet. Die Booklets werden mit größter Sorgfalt in Stuttgart
|
||||
produziert. Jedes Exemplar ist handgefertigt.`,
|
||||
imageRight: true,
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
// =============================================================================
|
||||
@@ -244,6 +282,15 @@ export const TECHNICAL_SPECS: Record<CoverType, Record<string, string>> = {
|
||||
Zertifizierung: "FSC® C018175, Blauer Engel, EU Ecolabel",
|
||||
Herstellung: "Stuttgart, Deutschland",
|
||||
},
|
||||
Promo: {
|
||||
Format: "150 × 210 mm (A5)",
|
||||
Umfang: "12 Wochen / 3 Monate",
|
||||
Layout: "Vorgedruckt (Tages-, Wochen- & Monatsplanung)",
|
||||
Papier: "VIVUS 89, 120g/qm, 1,2-faches Volumen, ungestrichen matt",
|
||||
Einband: "Fliederfarbener Softcover",
|
||||
Bindung: "Fadenbindung mit offenem Buchrücken",
|
||||
Herstellung: "Handgefertigt in Stuttgart",
|
||||
},
|
||||
};
|
||||
|
||||
// =============================================================================
|
||||
@@ -284,6 +331,8 @@ export function getCoverType(coverName?: string): CoverType {
|
||||
if (name.includes("hardcover")) return "Hardcover";
|
||||
if (name.includes("softcover")) return "Softcover";
|
||||
if (name.includes("spiral") || name.includes("wire")) return "Spiralbindung";
|
||||
// Standalone promo bucket (cover named "Promo").
|
||||
if (name.includes("promo")) return "Promo";
|
||||
return "Hardcover"; // fallback
|
||||
}
|
||||
|
||||
@@ -314,10 +363,10 @@ export function useProductContent(
|
||||
derivedSpecs["Format"] = prod.cover.copyText.format;
|
||||
}
|
||||
|
||||
// Seitenanzahl from pages
|
||||
if (prod.pages?.name) {
|
||||
// Seitenanzahl from pages (skip for Promo/standalone — page count not relevant)
|
||||
if (prod.pages?.name && coverType.value !== "Promo") {
|
||||
derivedSpecs["Seitenanzahl"] = prod.pages.name;
|
||||
} else if (prod.pages?.count) {
|
||||
} else if (prod.pages?.count && coverType.value !== "Promo") {
|
||||
const sheets = Math.floor(prod.pages.count / 2);
|
||||
derivedSpecs["Seitenanzahl"] = `${prod.pages.count} Seiten (${sheets} Blatt)`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user