Files
windwiderstand/src/lib/constants.ts
T
Peter Meier 61d2093d0b
Deploy / verify (push) Successful in 55s
Deploy / deploy (push) Successful in 1m16s
seo: use banner PNG as default OG image, skip SVG logos for social
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-19 15:06:38 +02:00

51 lines
1.8 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/**
* Zentrale Konstanten für die Anwendung.
* URLs, CMS-Resolve-Arrays und Fallback-Werte.
*/
/** Platzhalter-Bild für og:image / twitter:image, wenn weder Page/Post-Bild noch Logo gesetzt ist. */
export const DEFAULT_SOCIAL_IMAGE_URL =
"/api/assets/windwiderstand_banner.png?_environment=windwiderstand";
/** og:image-Dimensionen (Facebook/Twitter empfehlen 1200×630, 1.91:1). */
export const SOCIAL_IMAGE_DIMENSIONS = {
width: 1200,
height: 630,
} as const;
/** Logo-Fallback für og:image: letterboxed (contain), damit Logo komplett sichtbar bleibt. */
export const SOCIAL_IMAGE_TRANSFORM = {
...SOCIAL_IMAGE_DIMENSIONS,
fit: "contain" as const,
format: "webp" as const,
};
/** Post-Bild für og:image: cover (Banner-Look), Focal wird separat übergeben. */
export const POST_SOCIAL_IMAGE_TRANSFORM = {
...SOCIAL_IMAGE_DIMENSIONS,
fit: "cover" as const,
format: "webp" as const,
};
/** CMS Content-Rows für resolve (Footer, Pages, Posts). */
export const ROW_RESOLVE: string[] = [
"row1Content",
"row2Content",
"row3Content",
];
/** Resolve für Page-Requests: "all" = alle Referenzen inkl. verschachtelt (z. B. image_gallery.images). */
export const PAGE_RESOLVE = ["all"];
/** Resolve für Post-Requests: "all" damit auch img in row1Content/Image-Blöcken aufgelöst wird (src), sonst nur Referenz. */
export const POST_RESOLVE = ["all"];
/** Fallback-Slug für die Startseite, wenn page_config keine homePage liefert. */
export const DEFAULT_HOME_PAGE_SLUG = "page-home";
/** Site-Name für og:site_name und JSON-LD (in Layout via PUBLIC_SITE_NAME überschreibbar). */
export const SITE_NAME = "Windwiderstand";
/** Slug des Translation-Bundles im CMS (content/de/translation_bundle/{slug}.json5). Alle UI-Texte aus diesem Bundle. */
export const TRANSLATION_BUNDLE_SLUG = "app";