Skip to content

armgit / TREK

Public Imported from GitHub
0

The most complete open-source travel planner: real-time collaboration, bookings, budgets, packing lists, journals, offline PWA, SSO and an AI-ready MCP server, with planet-wide place search and routing built in.

12.4 KB
Raw Blame
import type { BookDecoratedTemplate } from '../template-format';

/**
 * Double spreads that open a part of the journey: a panorama, a block of
 * colour, a day. Each is drawn in the theme of its archetype.
 *
 * Drawn on a 210 mm page and kept as fractions of it (template-format.ts),
 * in the colours and faces of the theme named above; their links let any
 * other theme recolour them.
 */
export const INNER_CHAPTERS: readonly BookDecoratedTemplate[] = [
  {
    id: 'bleed-band-caption',
    labelKey: 'studio.templates.name.bleedBandCaption',
    kind: 'inner',
    archetype: 'spine-band',
    tags: ['full-bleed', 'panorama', 'band', 'caption', 'one-photo', 'calm'],
    descr:
      'One photo across the whole spread to the bleed, a band of paper across the foot of the right page with a terracotta edge, the title in a serif, the date and the caption on it.',
    background: '#efe8db',
    backgroundToken: 'paper',
    elements: [
      {
        id: 'p1',
        role: 'photo:1',
        frame: { x: -0.0143, y: -0.0143, w: 2.0286, h: 1.0286 },
        rotation: 0,
        opacity: 1,
        locked: false,
        kind: 'photo',
        photoId: null,
        fit: 'cover',
        focalX: 0.7,
        focalY: 0.5,
        radius: 0,
        filter: 'none',
        mask: null,
        frameStyle: 'none',
      },
      {
        id: 's2',
        frame: { x: 1.0762, y: 0.6952, w: 0.9381, h: 0.219 },
        rotation: 0,
        opacity: 0.95,
        locked: false,
        group: 'band',
        kind: 'shape',
        shape: 'rect',
        fill: '#efe8db',
        gradient: 'none',
        stroke: null,
        token: 'paper',
        strokeWidth: 0,
        strokeStyle: 'solid',
        radius: 0,
      },
      {
        id: 's3',
        frame: { x: 1.0762, y: 0.6952, w: 0.0119, h: 0.219 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'band',
        kind: 'shape',
        shape: 'rect',
        fill: '#b0603c',
        gradient: 'none',
        stroke: null,
        token: 'accent2',
        strokeWidth: 0,
        strokeStyle: 'solid',
        radius: 0,
      },
      {
        id: 't4',
        role: 'title',
        frame: { x: 1.1429, y: 0.7238, w: 0.781, h: 0.0952 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'band',
        kind: 'text',
        text: '',
        font: 'cormorant',
        size: 0.1524,
        weight: 500,
        italic: false,
        align: 'left',
        leading: 1,
        tracking: 0,
        color: '#2e2a26',
        token: 'ink',
        fontRole: 'display',
        binding: null,
        overridden: false,
        vAlign: 'middle',
        fit: 'shrink',
        fitMax: 0.1524,
      },
      {
        id: 't5',
        role: 'date',
        frame: { x: 1.1429, y: 0.8333, w: 0.2952, h: 0.0333 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'band',
        kind: 'text',
        text: '',
        font: 'montserrat',
        size: 0.0381,
        weight: 600,
        italic: false,
        align: 'left',
        leading: 1,
        tracking: 0.4,
        color: '#68635c',
        token: 'muted',
        fontRole: 'heading',
        binding: null,
        overridden: false,
        transform: 'upper',
        vAlign: 'middle',
        fit: 'shrink',
        fitMax: 0.0381,
      },
      {
        id: 't6',
        role: 'caption',
        frame: { x: 1.4476, y: 0.8333, w: 0.4762, h: 0.0333 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'band',
        kind: 'text',
        text: '',
        font: 'garamond',
        size: 0.0381,
        weight: 400,
        italic: true,
        align: 'right',
        leading: 1,
        tracking: 0,
        color: '#2e2a26',
        token: 'ink',
        fontRole: 'body',
        binding: null,
        overridden: false,
        vAlign: 'middle',
        fit: 'shrink',
        fitMax: 0.0381,
      },
    ],
  },
  {
    id: 'two-tone-split',
    labelKey: 'studio.templates.name.twoToneSplit',
    kind: 'inner',
    archetype: 'cutout',
    tags: ['two-tone', 'colour-block', 'title', 'story', 'two-photos', 'cut-out', 'lively'],
    descr:
      'The left page a block of coral with the title in huge condensed capitals, the date on a band and a small tilted photo in a white border with a cut-out star; the right page a large photo, the story and a sand leaf.',
    background: '#2445b8',
    backgroundToken: 'paper',
    elements: [
      {
        id: 's1',
        frame: { x: -0.0143, y: -0.0143, w: 1.0143, h: 1.0286 },
        rotation: 0,
        opacity: 1,
        locked: false,
        kind: 'shape',
        shape: 'rect',
        fill: '#ff7a59',
        gradient: 'none',
        stroke: null,
        token: 'accent',
        strokeWidth: 0,
        strokeStyle: 'solid',
        radius: 0,
      },
      {
        id: 't2',
        role: 'title',
        on: 'accent',
        frame: { x: 0.0762, y: 0.0857, w: 0.8476, h: 0.4381 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'title',
        kind: 'text',
        text: '',
        font: 'shoulders',
        size: 0.5714,
        weight: 800,
        italic: false,
        align: 'left',
        leading: 0.86,
        tracking: 0,
        color: '#2445b8',
        token: 'paper',
        fontRole: 'display',
        binding: null,
        overridden: false,
        transform: 'upper',
        vAlign: 'top',
        fit: 'shrink',
        fitMax: 0.5714,
      },
      {
        id: 't3',
        role: 'date',
        tint: { highlight: 'paper' },
        frame: { x: 0.0857, y: 0.5429, w: 0.5714, h: 0.0429 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'title',
        kind: 'text',
        text: '',
        font: 'oswald',
        size: 0.0429,
        weight: 500,
        italic: false,
        align: 'left',
        leading: 1,
        tracking: 0.45,
        color: '#fdf8ef',
        token: 'ink',
        fontRole: 'heading',
        binding: null,
        overridden: false,
        transform: 'upper',
        vAlign: 'middle',
        highlight: { color: '#2445b8', alpha: 1, padX: 0.0114, padY: 0.0052, radius: 0 },
        fit: 'shrink',
        fitMax: 0.0429,
      },
      {
        id: 'p4',
        role: 'photo:2',
        frame: { x: 0.4952, y: 0.6095, w: 0.4095, h: 0.3048 },
        rotation: -4,
        opacity: 1,
        locked: false,
        group: 'print',
        kind: 'photo',
        photoId: null,
        fit: 'cover',
        focalX: 0.5,
        focalY: 0.5,
        radius: 0,
        filter: 'none',
        mask: null,
        frameStyle: 'none',
        border: { width: 0.019, color: '#ffffff' },
      },
      {
        id: 's5',
        frame: { x: 0.4095, y: 0.8, w: 0.1429, h: 0.1381 },
        rotation: 12,
        opacity: 1,
        locked: false,
        group: 'print',
        kind: 'shape',
        shape: 'star-organic',
        fill: '#f1d9b5',
        gradient: 'none',
        stroke: null,
        token: 'accent2',
        strokeWidth: 0,
        strokeStyle: 'solid',
        radius: 0,
      },
      {
        id: 'p6',
        role: 'photo:1',
        frame: { x: 1.0762, y: 0.0762, w: 0.8476, h: 0.5524 },
        rotation: 0,
        opacity: 1,
        locked: false,
        kind: 'photo',
        photoId: null,
        fit: 'cover',
        focalX: 0.5,
        focalY: 0.5,
        radius: 0,
        filter: 'none',
        mask: null,
        frameStyle: 'none',
      },
      {
        id: 's7',
        frame: { x: 1.7429, y: 0.6667, w: 0.219, h: 0.2048 },
        rotation: 18,
        opacity: 1,
        locked: false,
        kind: 'shape',
        shape: 'leaf-palm',
        fill: '#f1d9b5',
        gradient: 'none',
        stroke: null,
        token: 'accent2',
        strokeWidth: 0,
        strokeStyle: 'solid',
        radius: 0,
      },
      {
        id: 't8',
        role: 'body',
        frame: { x: 1.0762, y: 0.6762, w: 0.6286, h: 0.2571 },
        rotation: 0,
        opacity: 1,
        locked: false,
        kind: 'text',
        text: '',
        font: 'inter',
        size: 0.0476,
        weight: 400,
        italic: false,
        align: 'left',
        leading: 1.55,
        tracking: 0,
        color: '#fdf8ef',
        token: 'ink',
        fontRole: 'body',
        binding: null,
        overridden: false,
        vAlign: 'top',
      },
    ],
  },
  {
    id: 'day-opener',
    labelKey: 'studio.templates.name.dayOpener',
    kind: 'inner',
    archetype: 'minimal-serif',
    tags: ['chapter', 'day', 'date', 'big-number', 'story', 'two-photos', 'calm'],
    descr:
      'A bleed photo on the left page; on the right the day of the month as a big numeral with the month under it, a hairline, the title in a large thin serif, the subtitle in spaced capitals, the story and a small photo.',
    background: null,
    backgroundToken: 'paper',
    elements: [
      {
        id: 'p1',
        role: 'photo:1',
        frame: { x: -0.0143, y: -0.0143, w: 1.0143, h: 1.0286 },
        rotation: 0,
        opacity: 1,
        locked: false,
        kind: 'photo',
        photoId: null,
        fit: 'cover',
        focalX: 0.5,
        focalY: 0.5,
        radius: 0,
        filter: 'none',
        mask: null,
        frameStyle: 'none',
      },
      {
        id: 'b2',
        role: 'date',
        frame: { x: 1.0762, y: 0.0857, w: 0.3048, h: 0.2952 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'head',
        font: 'cormorant',
        color: '#222222',
        accent: '#111111',
        textScale: 1,
        weight: 300,
        stale: false,
        token: 'ink',
        accentToken: 'ink',
        fontRole: 'display',
        kind: 'badge',
        variant: 'date',
        text: '14',
        sub: 'MAY',
        code: null,
        style: 'plain',
        autoColor: true,
        showIcon: true,
        showLabel: true,
        autoIconColor: true,
        iconColor: '#111111',
      },
      {
        id: 's3',
        frame: { x: 1.0857, y: 0.4095, w: 0.8381, h: 0.0014 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'head',
        kind: 'shape',
        shape: 'rect',
        fill: '#222222',
        gradient: 'none',
        stroke: null,
        token: 'ink',
        strokeWidth: 0,
        strokeStyle: 'solid',
        radius: 0,
      },
      {
        id: 't4',
        role: 'title',
        frame: { x: 1.0857, y: 0.4476, w: 0.8381, h: 0.1429 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'head',
        kind: 'text',
        text: '',
        font: 'cormorant',
        size: 0.1905,
        weight: 300,
        italic: false,
        align: 'left',
        leading: 1,
        tracking: 0,
        color: '#222222',
        token: 'ink',
        fontRole: 'display',
        binding: null,
        overridden: false,
        vAlign: 'top',
        fit: 'shrink',
        fitMax: 0.1905,
      },
      {
        id: 't5',
        role: 'subtitle',
        frame: { x: 1.0857, y: 0.6, w: 0.8381, h: 0.0333 },
        rotation: 0,
        opacity: 1,
        locked: false,
        group: 'head',
        kind: 'text',
        text: '',
        font: 'montserrat',
        size: 0.0381,
        weight: 400,
        italic: false,
        align: 'left',
        leading: 1,
        tracking: 0.4,
        color: '#646464',
        token: 'muted',
        fontRole: 'heading',
        binding: null,
        overridden: false,
        transform: 'upper',
        vAlign: 'middle',
        fit: 'shrink',
        fitMax: 0.0381,
      },
      {
        id: 't6',
        role: 'body',
        frame: { x: 1.0857, y: 0.6667, w: 0.5238, h: 0.2667 },
        rotation: 0,
        opacity: 1,
        locked: false,
        kind: 'text',
        text: '',
        font: 'inter',
        size: 0.0452,
        weight: 400,
        italic: false,
        align: 'left',
        leading: 1.5,
        tracking: 0,
        color: '#222222',
        token: 'ink',
        fontRole: 'body',
        binding: null,
        overridden: false,
        vAlign: 'top',
      },
      {
        id: 'p7',
        role: 'photo:2',
        frame: { x: 1.6476, y: 0.6667, w: 0.2762, h: 0.2667 },
        rotation: 0,
        opacity: 1,
        locked: false,
        kind: 'photo',
        photoId: null,
        fit: 'cover',
        focalX: 0.5,
        focalY: 0.5,
        radius: 0,
        filter: 'none',
        mask: null,
        frameStyle: 'none',
      },
    ],
  },
];