mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-11-27 15:17:30 +00:00
feat(studio): the Templates panel offers the decorated templates with a style filter
The Templates section of the rail now opens on the decorated templates of the page's kind, covers two to a row and spreads at full width, each card the page renderer drawing the page the click will lay: this page's photos and words in it, in the book theme, a cover in the journey's title and subtitle as the assistant's layout sets it. A row of style chips narrows the set to one archetype. A click is one undo step on the page as it is then, refused for the other kind of page, and opens the photos when frames are left empty. The book's own layouts and the built-in wireframes follow below, and the help guide and the wiki describe the panel as it now is. The panel moved out of StudioSidebar into its own file; the sidebar keeps the rail, and its two physical sides went with the code, so the rtl baseline entry goes too. The Travel panel and a template's map build the journey they draw with one helper.
This commit is contained in:
@@ -58,7 +58,6 @@
|
||||
"components/Studio/StudioExport.tsx": 1,
|
||||
"components/Studio/StudioInspector.tsx": 1,
|
||||
"components/Studio/StudioSavedLayouts.tsx": 1,
|
||||
"components/Studio/StudioSidebar.tsx": 2,
|
||||
"components/Studio/TravelElements.tsx": 4,
|
||||
"components/Studio/TravelPreview.tsx": 1,
|
||||
"components/SystemNotices/ReleaseNoticeVisuals.tsx": 3,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { useEffect, useMemo, useRef, useState } from 'react'
|
||||
import { useEffect, useRef, useState } from 'react'
|
||||
import {
|
||||
Camera, ChevronDown, ImagePlus, ChevronUp, Compass, Copy, FileDown, Files, ImageIcon, Layers, LayoutTemplate,
|
||||
Palette, Plus, Search, Shapes, Sticker, Trash2, Upload, X,
|
||||
@@ -11,10 +11,7 @@ import { useToast } from '../shared/Toast'
|
||||
import { SpreadThumb } from './SpreadThumb'
|
||||
import { folioLabel, foliosOf } from './bookSheets'
|
||||
import { photoSrc } from './bookRender'
|
||||
import {
|
||||
BOOK_COVER_TEMPLATES as COVER_TEMPLATES, BOOK_TEMPLATES as TEMPLATES, applyBookTemplate as applyTemplate,
|
||||
bookElementId as uid,
|
||||
} from '@trek/shared'
|
||||
import { bookElementId as uid } from '@trek/shared'
|
||||
import {
|
||||
bookCoordValue as coordValue, formatBookCoords, formatBookDate, type BookCoordFormat as CoordFormat,
|
||||
} from '@trek/shared'
|
||||
@@ -25,7 +22,7 @@ import { StudioStickersPanel } from './StudioStickersPanel'
|
||||
import { StudioLayersPanel } from './StudioLayersPanel'
|
||||
import { StudioTravelPanel } from './StudioTravelPanel'
|
||||
import { StudioThemePanel } from './theme/StudioThemePanel'
|
||||
import { StudioSavedLayouts } from './StudioSavedLayouts'
|
||||
import { StudioTemplatesPanel } from './templates/StudioTemplatesPanel'
|
||||
import { MAX_SPREAD_FILE_BYTES, importSpread } from './spreadFile'
|
||||
import { StudioContentFilter } from './StudioContentFilter'
|
||||
import { emptyKeyFor, matchingEntries, matchingPhotos, photosFor, type PhotoFilter } from './photoFilter'
|
||||
@@ -45,6 +42,13 @@ import type { StudioUploader } from './studioUpload'
|
||||
type Section = 'pages' | 'content' | 'elements' | 'stickers' | 'travel' | 'templates' | 'layers' | 'theme'
|
||||
|
||||
export interface JourneySource {
|
||||
/**
|
||||
* The journey's title and subtitle, which a cover is set in when the book has
|
||||
* no title of its own. The Studio always gives them; a source built only for
|
||||
* the content browser may leave them out.
|
||||
*/
|
||||
title?: string
|
||||
subtitle?: string | null
|
||||
entries: {
|
||||
id: number
|
||||
title: string | null
|
||||
@@ -166,7 +170,10 @@ export function StudioSidebar({
|
||||
)}
|
||||
{section === 'layers' && <StudioLayersPanel t={t} />}
|
||||
{section === 'theme' && <StudioThemePanel t={t} />}
|
||||
{section === 'templates' && <TemplatesPanel page={page} pxPerMm={pxPerMm} t={t} onOpenContent={() => setSection('content')} />}
|
||||
{section === 'templates' && (
|
||||
<StudioTemplatesPanel page={page} pxPerMm={pxPerMm} t={t} locale={locale} source={source} stats={stats}
|
||||
path={path} onOpenContent={() => setSection('content')} />
|
||||
)}
|
||||
</aside>
|
||||
</>
|
||||
)
|
||||
@@ -776,103 +783,3 @@ function ContentPanel({
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
/**
|
||||
* Layouts for the current spread.
|
||||
*
|
||||
* Each card draws the arrangement itself rather than naming it — "hero + story"
|
||||
* means nothing until you have seen it, and a diagram is faster to read than a
|
||||
* label anyway.
|
||||
*/
|
||||
function TemplatesPanel({
|
||||
page, pxPerMm, t, onOpenContent,
|
||||
}: { page: BookPageSetup; pxPerMm: number; t: (k: string) => string; onOpenContent: () => void }) {
|
||||
const doc = useStudioStore(s => s.doc)
|
||||
const active = useStudioStore(s => s.activeSpread)
|
||||
const commit = useStudioStore(s => s.commit)
|
||||
const spread = doc?.spreads[active]
|
||||
|
||||
const list = useElementSize<HTMLDivElement>()
|
||||
const CARD_W = Math.max(MIN_PREVIEW_W, list.width - THUMB_CHROME)
|
||||
const doc2 = doc
|
||||
const cardIsSingle = (doc2?.spreads[active]?.role ?? 'inner') !== 'inner'
|
||||
// A cover card is one page wide, not two — scaling it as a spread would draw
|
||||
// the layout at half size in the left half of the card.
|
||||
const scale = useMemo(
|
||||
() => CARD_W / (page.pageWidth * (cardIsSingle ? 1 : 2) * pxPerMm),
|
||||
[CARD_W, page.pageWidth, pxPerMm, cardIsSingle],
|
||||
)
|
||||
|
||||
if (!spread) return null
|
||||
const single = spread.role !== 'inner'
|
||||
/*
|
||||
* The cover has its own set. It used to have none — the panel said covers
|
||||
* are designed by hand, which was true and unhelpful: the cover is the page
|
||||
* people care most about and the one they had no starting point for.
|
||||
*/
|
||||
const templates = single ? COVER_TEMPLATES : TEMPLATES
|
||||
|
||||
return (
|
||||
<>
|
||||
<Head label={t('journey.studio.templates')} count={templates.length} />
|
||||
<div className="st-panel-scroll">
|
||||
<StudioSavedLayouts page={page} width={CARD_W} pxPerMm={pxPerMm} t={t} />
|
||||
{(
|
||||
<div className="st-thumbs" ref={list.ref}>
|
||||
{templates.map(tpl => {
|
||||
const slots = tpl.build(page)
|
||||
return (
|
||||
<button
|
||||
type="button"
|
||||
key={tpl.id}
|
||||
className="st-thumb"
|
||||
onClick={() => {
|
||||
let empties = 0
|
||||
commit(d => ({
|
||||
...d,
|
||||
spreads: d.spreads.map((sp, i) => {
|
||||
if (i !== active) return sp
|
||||
const next = applyTemplate(sp, tpl, page)
|
||||
empties = next.elements.filter(e => e.kind === 'photo' && e.photoId == null).length
|
||||
return next
|
||||
}),
|
||||
}))
|
||||
// The layout left frames waiting for a picture — so put the
|
||||
// pictures within reach instead of making the user go and
|
||||
// find the panel that holds them.
|
||||
if (empties > 0) onOpenContent()
|
||||
}}
|
||||
>
|
||||
<div
|
||||
className="st-thumb-sheet"
|
||||
style={{ width: CARD_W, height: page.pageHeight * pxPerMm * scale }}
|
||||
>
|
||||
{slots.map((slot, i) => (
|
||||
<span
|
||||
key={i}
|
||||
className={`st-tpl-slot is-${slot.kind}`}
|
||||
style={{
|
||||
left: slot.frame.x * pxPerMm * scale,
|
||||
top: slot.frame.y * pxPerMm * scale,
|
||||
width: slot.frame.w * pxPerMm * scale,
|
||||
height: Math.max(2, slot.frame.h * pxPerMm * scale),
|
||||
}}
|
||||
/>
|
||||
))}
|
||||
{!single && (
|
||||
<span
|
||||
className="st-tpl-fold"
|
||||
style={{ left: page.pageWidth * pxPerMm * scale }}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
<span className="st-thumb-label">{t(tpl.labelKey)}</span>
|
||||
</button>
|
||||
)
|
||||
})}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useEffect, useRef, useState } from 'react'
|
||||
import { Check, RouteOff } from 'lucide-react'
|
||||
import type {
|
||||
BookBadgeVariant, BookElement, BookMapScope, BookMetric, BookPageSetup, BookTravelContext, JourneyStats,
|
||||
BookBadgeVariant, BookElement, BookMapScope, BookMetric, BookPageSetup, JourneyStats,
|
||||
} from '@trek/shared'
|
||||
import {
|
||||
BOOK_METRICS, bookBadgeValue, bookCountryMark, bookCountryName, bookElementId as uid, bookTravelBadge,
|
||||
@@ -9,6 +9,7 @@ import {
|
||||
} from '@trek/shared'
|
||||
import { useStudioStore } from '../../store/studioStore'
|
||||
import { PanelHead } from './StudioPanelHead'
|
||||
import { studioTravelContext } from './studioTravelContext'
|
||||
import { Section } from './StudioControls'
|
||||
import { TravelPreview } from './TravelPreview'
|
||||
import { fetchRoads } from './roadRoute'
|
||||
@@ -167,21 +168,11 @@ export function StudioTravelPanel({
|
||||
}
|
||||
|
||||
/*
|
||||
* What the book engine's factories read: the journey, its recorded way and
|
||||
* the words in the reader's language. Every tile below is built by the
|
||||
* factory the engine's `add` calls. Where it lands is the panel's own:
|
||||
* centred across the spread, where `add` takes the right page. The day word
|
||||
* is the engine's too, handed over as its template: `t` leaves the `{day}`
|
||||
* in it untouched, and `bookDayText` puts the number there.
|
||||
* What the book engine's factories read (studioTravelContext.ts). Every tile
|
||||
* below is built by the factory the engine's `add` calls. Where it lands is
|
||||
* the panel's own: centred across the spread, where `add` takes the right page.
|
||||
*/
|
||||
const travel: BookTravelContext = {
|
||||
locale, stats, path, entries: [],
|
||||
labels: {
|
||||
day: t('journey.studio.day'), stations: t('journey.studio.stations'), summary: t('journey.studio.summary'),
|
||||
countries: t('journey.studio.countries'), distance: t('journey.studio.metric.distance'),
|
||||
pros: t('journey.editor.pros'), cons: t('journey.editor.cons'),
|
||||
},
|
||||
}
|
||||
const travel = studioTravelContext(stats, path, locale, t)
|
||||
const at = (size: { w: number; h: number }) => centre(size.w, size.h)
|
||||
|
||||
/**
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
import type { BookTravelContext, JourneyStats } from '@trek/shared';
|
||||
|
||||
/**
|
||||
* What the book engine's travel factories read, as the Studio knows it: the
|
||||
* journey's figures, its recorded way and the words in the reader's
|
||||
* language. The Travel panel builds its tiles with it, and the Templates
|
||||
* panel lays a template's map with it, so both draw the same journey.
|
||||
*
|
||||
* The day word is the engine's template: `t` leaves the `{day}` in it
|
||||
* untouched, and `bookDayText` puts the number there.
|
||||
*/
|
||||
export function studioTravelContext(
|
||||
stats: JourneyStats,
|
||||
path: [number, number][][],
|
||||
locale: string,
|
||||
t: (k: string) => string
|
||||
): BookTravelContext {
|
||||
return {
|
||||
locale,
|
||||
stats,
|
||||
path,
|
||||
entries: [],
|
||||
labels: {
|
||||
day: t('journey.studio.day'),
|
||||
stations: t('journey.studio.stations'),
|
||||
summary: t('journey.studio.summary'),
|
||||
countries: t('journey.studio.countries'),
|
||||
distance: t('journey.studio.metric.distance'),
|
||||
pros: t('journey.editor.pros'),
|
||||
cons: t('journey.editor.cons'),
|
||||
},
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,148 @@
|
||||
import { afterAll, beforeAll, beforeEach, describe, expect, it, vi } from 'vitest';
|
||||
|
||||
import type { BookDocument } from '@trek/shared';
|
||||
import { bookPageSetupSchema, decoratedTemplatesFor, normalizeBookDocument } from '@trek/shared';
|
||||
|
||||
import { act, fireEvent, render, screen } from '../../../../tests/helpers/render';
|
||||
import { useStudioStore } from '../../../store/studioStore';
|
||||
import { StudioTemplatesPanel } from './StudioTemplatesPanel';
|
||||
|
||||
/**
|
||||
* The Templates panel: the decorated templates of the open page's kind, each
|
||||
* a button named after its template and drawn as the page it lays, a style
|
||||
* filter, and a click that lays the page out in one undo step.
|
||||
*/
|
||||
|
||||
const t = (k: string) => k;
|
||||
const page = bookPageSetupSchema.parse({});
|
||||
const source = {
|
||||
title: 'Azores',
|
||||
subtitle: 'Nine islands in the Atlantic',
|
||||
entries: [{ id: 4, title: 'Sintra', story: 'Up through the fog.', location: 'Serra de Sintra', date: '2026-05-14' }],
|
||||
};
|
||||
|
||||
const book = (title = 'Portugal'): BookDocument =>
|
||||
normalizeBookDocument({
|
||||
version: 1,
|
||||
title,
|
||||
page: { preset: 'square-210', pageWidth: 210, pageHeight: 210, bleed: 3, safe: 5 },
|
||||
spreads: [
|
||||
{
|
||||
id: 'sp-cover',
|
||||
role: 'cover',
|
||||
background: null,
|
||||
entryId: null,
|
||||
parked: [],
|
||||
elements: [{ id: 'ph', kind: 'photo', frame: { x: 0, y: 0, w: 50, h: 50 }, photoId: 7 }],
|
||||
},
|
||||
{ id: 'sp-in', role: 'inner', background: null, entryId: 4, parked: [], elements: [] },
|
||||
],
|
||||
});
|
||||
|
||||
/* jsdom lays nothing out; the cards measure their row to scale the page drawing into it. */
|
||||
const size = Object.getOwnPropertyDescriptors(HTMLElement.prototype);
|
||||
beforeAll(() => {
|
||||
Object.defineProperty(HTMLElement.prototype, 'offsetWidth', { configurable: true, get: () => 220 });
|
||||
Object.defineProperty(HTMLElement.prototype, 'offsetHeight', { configurable: true, get: () => 600 });
|
||||
});
|
||||
afterAll(() => {
|
||||
for (const key of ['offsetWidth', 'offsetHeight'] as const) {
|
||||
const was = size[key];
|
||||
if (was) Object.defineProperty(HTMLElement.prototype, key, was);
|
||||
}
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
useStudioStore.getState().load(book());
|
||||
useStudioStore.setState({ readOnly: false });
|
||||
});
|
||||
|
||||
const panel = (onOpenContent = vi.fn()) =>
|
||||
render(
|
||||
<StudioTemplatesPanel
|
||||
page={page}
|
||||
pxPerMm={96 / 25.4}
|
||||
t={t}
|
||||
locale="en"
|
||||
source={source}
|
||||
stats={null}
|
||||
path={[]}
|
||||
onOpenContent={onOpenContent}
|
||||
/>
|
||||
);
|
||||
|
||||
const spreadOf = (i: number) => useStudioStore.getState().doc?.spreads[i];
|
||||
|
||||
describe('the Templates panel', () => {
|
||||
it('offers the cover templates on the cover, each a named button drawn with the page photo and the book title', () => {
|
||||
panel();
|
||||
for (const tpl of decoratedTemplatesFor('single')) {
|
||||
expect(screen.getByRole('button', { name: tpl.labelKey })).toBeTruthy();
|
||||
}
|
||||
expect(screen.queryByRole('button', { name: 'studio.templates.name.polaroidStack' })).toBeNull();
|
||||
const card = screen.getByRole('button', { name: 'studio.templates.name.minimalSerifClassic' });
|
||||
expect(card.textContent).toContain('Portugal');
|
||||
expect(card.querySelector('img')?.getAttribute('src')).toContain('/api/photos/7/');
|
||||
expect(screen.getByText('studio.templates.decorated')).toBeTruthy();
|
||||
expect(screen.getByText('journey.studio.builtInLayouts')).toBeTruthy();
|
||||
});
|
||||
|
||||
it('narrows the set to one archetype from the style chips', () => {
|
||||
panel();
|
||||
const chips = screen.getByRole('radiogroup', { name: 'studio.templates.style' });
|
||||
expect(chips.querySelectorAll('[role="radio"]')).toHaveLength(8);
|
||||
fireEvent.click(screen.getByRole('radio', { name: 'studio.templates.archetype.postcard' }));
|
||||
expect(
|
||||
screen.getByRole('radio', { name: 'studio.templates.archetype.postcard' }).getAttribute('aria-checked')
|
||||
).toBe('true');
|
||||
const names = decoratedTemplatesFor('single', 'postcard').map((tpl) => tpl.labelKey);
|
||||
for (const name of names) expect(screen.getByRole('button', { name })).toBeTruthy();
|
||||
expect(screen.queryByRole('button', { name: 'studio.templates.name.gridBadgeCircle' })).toBeNull();
|
||||
});
|
||||
|
||||
it('lays the page out on a click, as one undo step, keeping its photo', () => {
|
||||
panel();
|
||||
fireEvent.click(screen.getByRole('button', { name: 'studio.templates.name.postcardHouses' }));
|
||||
const cover = spreadOf(0);
|
||||
expect(cover?.elements.some((e) => e.kind === 'sticker' && e.stickerId === 'rowHouses')).toBe(true);
|
||||
expect(cover?.elements.find((e) => e.kind === 'photo')).toMatchObject({ photoId: 7 });
|
||||
expect(cover?.elements.some((e) => e.kind === 'text' && e.text === 'Portugal')).toBe(true);
|
||||
expect(useStudioStore.getState().past).toHaveLength(1);
|
||||
useStudioStore.getState().undo();
|
||||
expect(spreadOf(0)?.elements.map((e) => e.id)).toEqual(['ph']);
|
||||
});
|
||||
|
||||
it("sets a cover in the journey's subtitle, bound to it, and in the journey's title when the book has none", () => {
|
||||
panel();
|
||||
fireEvent.click(screen.getByRole('button', { name: 'studio.templates.name.minimalSerifClassic' }));
|
||||
const texts = (spreadOf(0)?.elements ?? []).flatMap((e) => (e.kind === 'text' ? [e] : []));
|
||||
expect(texts.map((e) => e.text)).toEqual(['Portugal', 'Nine islands in the Atlantic', '2026']);
|
||||
expect(texts[1]?.binding).toEqual({ source: 'journey.subtitle' });
|
||||
|
||||
act(() => useStudioStore.getState().load(book('')));
|
||||
fireEvent.click(screen.getByRole('button', { name: 'studio.templates.name.minimalSerifClassic' }));
|
||||
const untitled = (spreadOf(0)?.elements ?? []).flatMap((e) => (e.kind === 'text' ? [e.text] : []));
|
||||
expect(untitled[0]).toBe('Azores');
|
||||
});
|
||||
|
||||
it('offers the spread templates on a double page, sets it in its entry and opens the photos for empty frames', () => {
|
||||
useStudioStore.getState().setActiveSpread(1);
|
||||
const onOpenContent = vi.fn();
|
||||
panel(onOpenContent);
|
||||
for (const tpl of decoratedTemplatesFor('inner')) {
|
||||
expect(screen.getByRole('button', { name: tpl.labelKey })).toBeTruthy();
|
||||
}
|
||||
fireEvent.click(screen.getByRole('button', { name: 'studio.templates.name.storyQuote' }));
|
||||
const inner = spreadOf(1);
|
||||
const title = inner?.elements.find((e) => e.kind === 'text' && e.text === 'Sintra');
|
||||
expect(title?.kind === 'text' && title.binding).toEqual({ source: 'entry.title', entryId: 4 });
|
||||
expect(onOpenContent).toHaveBeenCalledTimes(1);
|
||||
});
|
||||
|
||||
it('lays a built-in layout out from the same panel', () => {
|
||||
useStudioStore.getState().setActiveSpread(1);
|
||||
panel();
|
||||
fireEvent.click(screen.getByText('journey.studio.tpl.grid4'));
|
||||
expect(spreadOf(1)?.elements.filter((e) => e.kind === 'photo')).toHaveLength(4);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,251 @@
|
||||
import type { BookDecoratedTemplate, BookPageSetup, BookSpread, BookTemplate, JourneyStats } from '@trek/shared';
|
||||
import {
|
||||
applyBookTemplate as applyTemplate,
|
||||
BOOK_COVER_TEMPLATES as COVER_TEMPLATES,
|
||||
BOOK_TEMPLATES as TEMPLATES,
|
||||
} from '@trek/shared';
|
||||
import { memo, useDeferredValue, useMemo, useState } from 'react';
|
||||
|
||||
import { useElementSize } from '../../../hooks/useElementSize';
|
||||
import { useStudioStore } from '../../../store/studioStore';
|
||||
import '../../../styles/studio-templates.css';
|
||||
import { SpreadThumb } from '../SpreadThumb';
|
||||
import { Choice } from '../StudioControls';
|
||||
import { PanelHead } from '../StudioPanelHead';
|
||||
import { StudioSavedLayouts } from '../StudioSavedLayouts';
|
||||
import {
|
||||
ARCHETYPE_FILTERS,
|
||||
emptyFrames,
|
||||
layTemplate,
|
||||
pageKind,
|
||||
previewIds,
|
||||
studioTemplateWords,
|
||||
templatesForSpread,
|
||||
templateTravel,
|
||||
type ArchetypeFilter,
|
||||
type TemplateContext,
|
||||
type TemplateSource,
|
||||
} from './templatesModel';
|
||||
|
||||
/**
|
||||
* The Templates section of the rail: the decorated templates first, then the
|
||||
* book's own layouts and the built-in wireframes.
|
||||
*
|
||||
* A decorated template is a whole designed page, and its card is that page as
|
||||
* the click will lay it: this page's photos and words poured into it, in the
|
||||
* book's theme, drawn by the page renderer at a small scale. Covers are drawn
|
||||
* two to a row so the set can be compared at a glance; a double spread takes
|
||||
* the full width. A row of style chips narrows the set to one archetype.
|
||||
*/
|
||||
|
||||
/** The smallest a preview is drawn, and the button's border and padding the row's width still includes. */
|
||||
const MIN_PREVIEW_W = 96;
|
||||
const THUMB_CHROME = (2 + 3) * 2;
|
||||
/** The gap between two cover cards in a row, as studio-templates.css sets it. */
|
||||
const PAIR_GAP = 8;
|
||||
|
||||
type Translate = (k: string, params?: Record<string, string | number>) => string;
|
||||
|
||||
/** How wide a card draws its page, from the measured row: the full row, or half of it for a cover. */
|
||||
function previewWidths(row: number, single: boolean): { full: number; card: number } {
|
||||
const full = Math.max(MIN_PREVIEW_W, row - THUMB_CHROME);
|
||||
return { full, card: single ? Math.max(MIN_PREVIEW_W / 2, (row - PAIR_GAP) / 2 - THUMB_CHROME) : full };
|
||||
}
|
||||
|
||||
interface DecoratedCardProps {
|
||||
tpl: BookDecoratedTemplate;
|
||||
spread: BookSpread;
|
||||
page: BookPageSetup;
|
||||
ctx: TemplateContext;
|
||||
width: number;
|
||||
pxPerMm: number;
|
||||
label: string;
|
||||
onPick: (tpl: BookDecoratedTemplate) => void;
|
||||
}
|
||||
|
||||
/** One decorated template, drawn as the page it makes of the page that is open. */
|
||||
const DecoratedCard = memo(function DecoratedCard({
|
||||
tpl,
|
||||
spread,
|
||||
page,
|
||||
ctx,
|
||||
width,
|
||||
pxPerMm,
|
||||
label,
|
||||
onPick,
|
||||
}: DecoratedCardProps) {
|
||||
const preview = useMemo(
|
||||
() => layTemplate(spread, tpl, page, ctx, previewIds(`tpl-${tpl.id}`)),
|
||||
[spread, tpl, page, ctx]
|
||||
);
|
||||
return (
|
||||
<button type="button" className="st-thumb st-tpl-card" title={label} aria-label={label} onClick={() => onPick(tpl)}>
|
||||
<span aria-hidden className="st-tpl-art">
|
||||
<SpreadThumb
|
||||
spread={preview}
|
||||
page={page}
|
||||
width={width}
|
||||
pxPerMm={pxPerMm}
|
||||
fold={tpl.kind === 'inner'}
|
||||
className="st-thumb-sheet"
|
||||
/>
|
||||
</span>
|
||||
<span className="st-thumb-label st-tpl-label">{label}</span>
|
||||
</button>
|
||||
);
|
||||
});
|
||||
|
||||
/** The built-in layouts, drawn as the frames they lay out: the wireframes Studio has always had. */
|
||||
function BuiltInLayouts({
|
||||
spread,
|
||||
page,
|
||||
pxPerMm,
|
||||
width,
|
||||
t,
|
||||
onPick,
|
||||
}: {
|
||||
spread: BookSpread;
|
||||
page: BookPageSetup;
|
||||
pxPerMm: number;
|
||||
width: number;
|
||||
t: Translate;
|
||||
onPick: (tpl: BookTemplate) => void;
|
||||
}) {
|
||||
const single = spread.role !== 'inner';
|
||||
// A cover card is one page wide, not two: scaled as a spread it would draw at half size.
|
||||
const scale = width / (page.pageWidth * (single ? 1 : 2) * pxPerMm);
|
||||
const templates = single ? COVER_TEMPLATES : TEMPLATES;
|
||||
return (
|
||||
<div className="st-thumbs">
|
||||
{templates.map((tpl) => (
|
||||
<button type="button" key={tpl.id} className="st-thumb" onClick={() => onPick(tpl)}>
|
||||
{/* A page is laid out from its top left in either reading direction. */}
|
||||
<div dir="ltr" className="st-thumb-sheet" style={{ width, height: page.pageHeight * pxPerMm * scale }}>
|
||||
{tpl.build(page).map((slot, i) => (
|
||||
<span
|
||||
key={i}
|
||||
className={`st-tpl-slot is-${slot.kind}`}
|
||||
style={{
|
||||
insetInlineStart: slot.frame.x * pxPerMm * scale,
|
||||
top: slot.frame.y * pxPerMm * scale,
|
||||
width: slot.frame.w * pxPerMm * scale,
|
||||
height: Math.max(2, slot.frame.h * pxPerMm * scale),
|
||||
}}
|
||||
/>
|
||||
))}
|
||||
{!single && <span className="st-tpl-fold" style={{ insetInlineStart: page.pageWidth * pxPerMm * scale }} />}
|
||||
</div>
|
||||
<span className="st-thumb-label">{t(tpl.labelKey)}</span>
|
||||
</button>
|
||||
))}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export function StudioTemplatesPanel({
|
||||
page,
|
||||
pxPerMm,
|
||||
t,
|
||||
locale,
|
||||
source,
|
||||
stats,
|
||||
path,
|
||||
onOpenContent,
|
||||
}: {
|
||||
page: BookPageSetup;
|
||||
pxPerMm: number;
|
||||
t: Translate;
|
||||
locale: string;
|
||||
source: TemplateSource;
|
||||
stats: JourneyStats | null;
|
||||
path: [number, number][][];
|
||||
/** Opens the panel of the journey's photos, for frames a layout left empty. */
|
||||
onOpenContent: () => void;
|
||||
}) {
|
||||
const doc = useStudioStore((s) => s.doc);
|
||||
const active = useStudioStore((s) => s.activeSpread);
|
||||
const commit = useStudioStore((s) => s.commit);
|
||||
const select = useStudioStore((s) => s.select);
|
||||
const [filter, setFilter] = useState<ArchetypeFilter>('all');
|
||||
const list = useElementSize<HTMLDivElement>();
|
||||
// The cards redraw from the page as it is; deferred, so typing on the page never waits on them.
|
||||
const spread = useDeferredValue(doc?.spreads[active]);
|
||||
const theme = doc?.theme;
|
||||
const title = doc?.title ?? '';
|
||||
|
||||
const ctx = useMemo<TemplateContext | null>(() => {
|
||||
if (!spread) return null;
|
||||
const words = studioTemplateWords(title, spread, source, locale);
|
||||
return { theme, words, travel: templateTravel(stats, path, locale, t), locale };
|
||||
}, [spread, theme, title, source, stats, path, locale, t]);
|
||||
|
||||
if (!doc || !spread || !ctx) return null;
|
||||
const single = spread.role !== 'inner';
|
||||
const templates = templatesForSpread(spread, filter);
|
||||
const { full, card: cardWidth } = previewWidths(list.width, single);
|
||||
|
||||
/**
|
||||
* One undo step: the page laid out, nothing selected, and the photos at hand
|
||||
* when frames are left empty. It works on the page as it is now, not as the
|
||||
* deferred cards last drew it: a click right after moving to another page
|
||||
* lays nothing when the layout is for the other kind of page.
|
||||
*/
|
||||
const lay = (make: (sp: BookSpread) => BookSpread | null) => {
|
||||
const done: { page: BookSpread | null } = { page: null };
|
||||
commit((d) => {
|
||||
const now = d.spreads[active];
|
||||
const next = now ? make(now) : null;
|
||||
done.page = next;
|
||||
return next ? { ...d, spreads: d.spreads.map((sp, i) => (i === active ? next : sp)) } : d;
|
||||
});
|
||||
if (!done.page) return;
|
||||
select([]);
|
||||
if (emptyFrames(done.page) > 0) onOpenContent();
|
||||
};
|
||||
const pickDecorated = (tpl: BookDecoratedTemplate) =>
|
||||
lay((sp) =>
|
||||
pageKind(sp) === tpl.kind
|
||||
? layTemplate(sp, tpl, page, { ...ctx, words: studioTemplateWords(title, sp, source, locale) })
|
||||
: null
|
||||
);
|
||||
const pickBuiltIn = (tpl: BookTemplate) =>
|
||||
lay((sp) => (pageKind(sp) === (tpl.role ?? 'inner') ? applyTemplate(sp, tpl, page) : null));
|
||||
|
||||
return (
|
||||
<>
|
||||
<PanelHead label={t('journey.studio.templates')} count={templates.length} />
|
||||
<div className="st-panel-scroll">
|
||||
<div className="st-section st-tpl-section">
|
||||
<div className="st-section-label">{t('studio.templates.decorated')}</div>
|
||||
<Choice<ArchetypeFilter>
|
||||
value={filter}
|
||||
ariaLabel={t('studio.templates.style')}
|
||||
onPick={setFilter}
|
||||
options={ARCHETYPE_FILTERS.map((a) => ({
|
||||
value: a,
|
||||
label: a === 'all' ? t('studio.templates.all') : t(`studio.templates.archetype.${a}`),
|
||||
}))}
|
||||
/>
|
||||
<div className={`st-tpl-grid ${single ? 'is-pages' : 'is-spreads'}`} ref={list.ref}>
|
||||
{templates.map((tpl) => (
|
||||
<DecoratedCard
|
||||
key={tpl.id}
|
||||
tpl={tpl}
|
||||
spread={spread}
|
||||
page={page}
|
||||
ctx={ctx}
|
||||
width={cardWidth}
|
||||
pxPerMm={pxPerMm}
|
||||
label={t(tpl.labelKey)}
|
||||
onPick={pickDecorated}
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
<p className="st-hint">{t('studio.templates.hint')}</p>
|
||||
</div>
|
||||
<StudioSavedLayouts page={page} width={full} pxPerMm={pxPerMm} t={t} />
|
||||
<BuiltInLayouts spread={spread} page={page} pxPerMm={pxPerMm} width={full} t={t} onPick={pickBuiltIn} />
|
||||
</div>
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,83 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
|
||||
import type { BookSpread } from '@trek/shared';
|
||||
import { bookSpreadSchema, journeyStatsSchema } from '@trek/shared';
|
||||
|
||||
import { pageKind, studioTemplateWords, templateTravel, templatesForSpread } from './templatesModel';
|
||||
|
||||
/**
|
||||
* What the Templates panel lays a page out with: which templates a page
|
||||
* takes, the words their empty roles take (the same the assistant's layout
|
||||
* gives), and the journey's figures for a template's map.
|
||||
*/
|
||||
|
||||
const t = (k: string) => `[${k}]`;
|
||||
const spread = (role: BookSpread['role'], entryId: number | null = null) =>
|
||||
bookSpreadSchema.parse({ id: `sp-${role}`, role, entryId, elements: [] });
|
||||
const source = {
|
||||
title: 'Azores',
|
||||
subtitle: 'Nine islands in the Atlantic',
|
||||
entries: [{ id: 4, title: 'Sintra', story: 'Up through the fog.', location: 'Serra de Sintra', date: '2026-05-14' }],
|
||||
};
|
||||
|
||||
describe('the templates a page takes', () => {
|
||||
it('takes the covers on every single page and the spreads on a double one', () => {
|
||||
for (const role of ['cover', 'first', 'last', 'back'] as const) expect(pageKind(spread(role))).toBe('single');
|
||||
expect(pageKind(spread('inner'))).toBe('inner');
|
||||
expect(templatesForSpread(spread('back'), 'all').every((tpl) => tpl.kind === 'single')).toBe(true);
|
||||
expect(templatesForSpread(spread('inner'), 'postcard').every((tpl) => tpl.archetype === 'postcard')).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
describe('the words of a template', () => {
|
||||
it("sets a cover in the book's title, the journey's when the book has none, and the journey's subtitle bound to it", () => {
|
||||
const own = studioTemplateWords(' Portugal ', spread('cover'), source, 'en');
|
||||
expect(own.title).toEqual({ text: 'Portugal' });
|
||||
expect(own.subtitle).toEqual({ text: 'Nine islands in the Atlantic', binding: { source: 'journey.subtitle' } });
|
||||
expect(own.date).toEqual({ text: '2026' });
|
||||
expect(studioTemplateWords('', spread('cover'), source, 'en').title).toEqual({ text: 'Azores' });
|
||||
});
|
||||
|
||||
it('leaves a cover without a title when neither the book nor the journey has one, rather than a sample word', () => {
|
||||
const words = studioTemplateWords('', spread('cover'), { ...source, title: '', subtitle: null }, 'en');
|
||||
expect(words.title).toBeUndefined();
|
||||
expect(words.subtitle).toBeUndefined();
|
||||
});
|
||||
|
||||
it('sets a page made from an entry in that entry, bound to it', () => {
|
||||
const words = studioTemplateWords('Portugal', spread('inner', 4), source, 'en');
|
||||
expect(words.title).toEqual({ text: 'Sintra', binding: { source: 'entry.title', entryId: 4 } });
|
||||
expect(words.date?.binding).toEqual({ source: 'entry.date', entryId: 4, value: '2026-05-14' });
|
||||
expect(studioTemplateWords('Portugal', spread('inner'), source, 'en')).toEqual({});
|
||||
});
|
||||
});
|
||||
|
||||
describe('the journey of a template map', () => {
|
||||
it('has none while the figures load, and the travel words of the reader once they are in', () => {
|
||||
expect(templateTravel(null, [], 'en', t)).toBeNull();
|
||||
const stats = journeyStatsSchema.parse({
|
||||
journeyId: 1,
|
||||
distance: 1200,
|
||||
days: 3,
|
||||
steps: 2,
|
||||
photos: 0,
|
||||
places: 0,
|
||||
furthest: 900,
|
||||
countries: [],
|
||||
points: [],
|
||||
start: '2026-05-12',
|
||||
end: '2026-05-14',
|
||||
});
|
||||
const travel = templateTravel(stats, [[[38.7, -9.1]]], 'de', t);
|
||||
expect(travel).toMatchObject({ locale: 'de', stats, path: [[[38.7, -9.1]]], entries: [] });
|
||||
expect(travel?.labels).toEqual({
|
||||
day: '[journey.studio.day]',
|
||||
stations: '[journey.studio.stations]',
|
||||
summary: '[journey.studio.summary]',
|
||||
countries: '[journey.studio.countries]',
|
||||
distance: '[journey.studio.metric.distance]',
|
||||
pros: '[journey.editor.pros]',
|
||||
cons: '[journey.editor.cons]',
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,116 @@
|
||||
import type {
|
||||
BookCoverArchetype,
|
||||
BookDecoratedTemplate,
|
||||
BookDocument,
|
||||
BookPageSetup,
|
||||
BookSpread,
|
||||
BookTemplateKind,
|
||||
BookTemplateWords,
|
||||
BookTravelContext,
|
||||
JourneyStats,
|
||||
} from '@trek/shared';
|
||||
import { BOOK_COVER_ARCHETYPES, applyDecoratedTemplate, bookTemplateWords, decoratedTemplatesFor } from '@trek/shared';
|
||||
|
||||
import { studioTravelContext } from '../studioTravelContext';
|
||||
|
||||
/**
|
||||
* What the Templates panel lays out and draws: the decorated templates a page
|
||||
* can take, the words and the figures they are filled with, and the page one
|
||||
* template makes. The card and the click run the same function, so a card
|
||||
* shows the page the click gives, with this page's own photos and words in it.
|
||||
*/
|
||||
|
||||
export type ArchetypeFilter = BookCoverArchetype | 'all';
|
||||
|
||||
/** The panel's style filter: every template, or those of one archetype. */
|
||||
export const ARCHETYPE_FILTERS: readonly ArchetypeFilter[] = ['all', ...BOOK_COVER_ARCHETYPES];
|
||||
|
||||
/** Which templates a page takes: a single page (the cover, the first, the last, the back) or a double spread. */
|
||||
export function pageKind(spread: BookSpread): BookTemplateKind {
|
||||
return spread.role === 'inner' ? 'inner' : 'single';
|
||||
}
|
||||
|
||||
/** The decorated templates for a page: covers for a single page, spreads for a double one. */
|
||||
export function templatesForSpread(spread: BookSpread, filter: ArchetypeFilter): BookDecoratedTemplate[] {
|
||||
return decoratedTemplatesFor(pageKind(spread), filter === 'all' ? null : filter);
|
||||
}
|
||||
|
||||
/** What the Studio knows of the journey that a template takes words and a map from. */
|
||||
export interface TemplateSource {
|
||||
/** The journey's title, for a cover of a book without its own, and its subtitle. */
|
||||
title?: string;
|
||||
subtitle?: string | null;
|
||||
entries: readonly {
|
||||
id: number;
|
||||
title: string | null;
|
||||
story: string | null;
|
||||
location: string | null;
|
||||
date: string | null;
|
||||
}[];
|
||||
}
|
||||
|
||||
/** Everything a page is laid out on a template with. */
|
||||
export interface TemplateContext {
|
||||
theme: BookDocument['theme'];
|
||||
words: BookTemplateWords;
|
||||
travel: BookTravelContext | null;
|
||||
locale: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* The words a template's empty roles take, as the assistant's layout gives
|
||||
* them (template-op.ts in shared): on a single page the book's title, or the
|
||||
* journey's when the book has none, the journey's subtitle and the year; on
|
||||
* a page made from a journal entry that entry's title, place, date and story.
|
||||
*/
|
||||
export function studioTemplateWords(
|
||||
bookTitle: string,
|
||||
spread: BookSpread,
|
||||
source: TemplateSource,
|
||||
locale: string
|
||||
): BookTemplateWords {
|
||||
return bookTemplateWords(spread, {
|
||||
bookTitle: bookTitle.trim() || (source.title ?? ''),
|
||||
subtitle: source.subtitle ?? null,
|
||||
locale,
|
||||
entries: source.entries,
|
||||
});
|
||||
}
|
||||
|
||||
/** The journey's figures and way, for a template's map; null while they are loading or failed. */
|
||||
export function templateTravel(
|
||||
stats: JourneyStats | null,
|
||||
path: [number, number][][],
|
||||
locale: string,
|
||||
t: (k: string) => string
|
||||
): BookTravelContext | null {
|
||||
return stats ? studioTravelContext(stats, path, locale, t) : null;
|
||||
}
|
||||
|
||||
/** A page laid out on a template: what a card draws and what a click commits. */
|
||||
export function layTemplate(
|
||||
spread: BookSpread,
|
||||
tpl: BookDecoratedTemplate,
|
||||
page: BookPageSetup,
|
||||
ctx: TemplateContext,
|
||||
newId?: (prefix: string) => string
|
||||
): BookSpread {
|
||||
return applyDecoratedTemplate(spread, tpl, page, {
|
||||
theme: ctx.theme ?? null,
|
||||
words: ctx.words,
|
||||
travel: ctx.travel,
|
||||
locale: ctx.locale,
|
||||
...(newId ? { newId } : {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Ids for a card's drawing that stay the same from one render to the next, so its keys do too. */
|
||||
export function previewIds(prefix: string): (kind: string) => string {
|
||||
let n = 0;
|
||||
return (kind) => `${prefix}-${kind}${(n += 1)}`;
|
||||
}
|
||||
|
||||
/** How many frames a laid page is left waiting for a picture in. */
|
||||
export function emptyFrames(spread: BookSpread): number {
|
||||
return spread.elements.filter((e) => e.kind === 'photo' && e.photoId == null).length;
|
||||
}
|
||||
@@ -174,6 +174,8 @@ export function useJourneyStudio() {
|
||||
}
|
||||
}
|
||||
return {
|
||||
title: journey?.title || '',
|
||||
subtitle: journey?.subtitle ?? null,
|
||||
entries: entries
|
||||
.filter((e: JourneyEntry) => !!(
|
||||
e.title || e.story || e.location_name || e.mood || e.weather
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
/* ============================================================================
|
||||
TREK Studio: the decorated templates in the Templates panel.
|
||||
|
||||
Scoped under `.trek-dash` like every Studio rule (see the head of
|
||||
studio.css for why), in the dashboard tokens. A card is the page renderer
|
||||
at a small scale inside the page thumbnail's own button and sheet
|
||||
(`.st-thumb`, `.st-thumb-sheet`), so a template card and a page in the rail
|
||||
look like the same object.
|
||||
============================================================================ */
|
||||
|
||||
.trek-dash .st-tpl-section {
|
||||
padding-top: 4px;
|
||||
}
|
||||
|
||||
.trek-dash .st-tpl-section > .st-row {
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
|
||||
/* Covers two to a row, so a set reads at a glance; a double spread takes the width. */
|
||||
.trek-dash .st-tpl-grid {
|
||||
display: grid;
|
||||
gap: 10px 8px;
|
||||
align-items: start;
|
||||
}
|
||||
.trek-dash .st-tpl-grid.is-pages {
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
}
|
||||
.trek-dash .st-tpl-grid.is-spreads {
|
||||
grid-template-columns: minmax(0, 1fr);
|
||||
}
|
||||
|
||||
.trek-dash .st-tpl-card {
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.trek-dash .st-tpl-art {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/* A name wraps onto a second line rather than being cut off at the card's edge. */
|
||||
.trek-dash .st-tpl-label {
|
||||
line-height: 1.35;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
.trek-dash .st-tpl-section > .st-hint {
|
||||
margin-top: 10px;
|
||||
}
|
||||
@@ -916,7 +916,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'تطبيق تخطيط على صفحتين متقابلتين',
|
||||
'help.guide.studio-layouts.goal': 'امنح الصفحة المزدوجة ترتيبًا جاهزًا لإطارات الصور والنصوص.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'افتح «التخطيطات» في الشريط. ستجد ثلاثة عشر تخطيطًا للصفحات المزدوجة، ومجموعة منفصلة للغلاف الأمامي والخلفي والصفحات المفردة.',
|
||||
'افتح «التخطيطات» في الشريط. تأتي الصفحات المصممة أولًا: أغلفة وصفحات مزدوجة كاملة بسمة الكتاب، تحصرها أزرار «النمط» في مظهر واحد. وتليها في الأسفل تخطيطات الكتاب الخاصة والتخطيطات المدمجة.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'انقر على أحدها. تحصل الصفحات المتقابلة في منطقة العمل على إطارات هذا التخطيط، وتوضع صورك ونصوصك الحالية فيها.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -1019,7 +1019,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Açılıma tərtibat tətbiq edin',
|
||||
'help.guide.studio-layouts.goal': 'Açılıma foto və mətn çərçivələrinin hazır düzülüşünü verin.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Paneldə «Tərtibatlar» bölməsini açın. Burada on üç açılım tərtibatı, üzlük, arxa qabıq və tək səhifələr üçün isə ayrıca dəst var.',
|
||||
'Paneldə «Tərtibatlar» bölməsini açın. Əvvəlcə dizayn olunmuş səhifələr gəlir: kitabın mövzusunda hazırlanmış bütöv üzlüklər və açılımlar; «Üslub» düymələri onları bir görünüşə qədər daraldır. Onların altında kitabın öz tərtibatları və daxili tərtibatlar gəlir.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Birinə klikləyin. İş masasındakı açılım bu tərtibatın çərçivələrini alır, mövcud fotolarınız və mətniniz də onlara yerləşdirilir.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -991,7 +991,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Aplicar um layout a uma página dupla',
|
||||
'help.guide.studio-layouts.goal': 'Aplique a uma página dupla uma disposição pronta de molduras de foto e texto.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Abra “Layouts” na coluna. Ali há treze layouts de página dupla e um conjunto separado para a capa, a contracapa e as páginas avulsas.',
|
||||
'Abra “Layouts” na coluna. Primeiro vêm as páginas desenhadas: capas e páginas duplas inteiras no tema do livro, que os botões de estilo filtram por um visual. Logo abaixo ficam os layouts do próprio livro e os prontos.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Clique em um. A página dupla na bancada recebe as molduras desse layout, e as fotos e textos que você já tinha são colocados nelas.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -1000,7 +1000,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Aplicar un layout a una doble pàgina',
|
||||
'help.guide.studio-layouts.goal': 'Aplica a una doble pàgina una distribució predefinida de marcs de foto i de text.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Obre «Disposicions» a la columna. Hi ha tretze disposicions de doble pàgina i un conjunt a part per a la coberta, la contracoberta i les pàgines soltes.',
|
||||
'Obre «Disposicions» a la columna. Primer hi ha les pàgines dissenyades: cobertes i dobles pàgines senceres amb el tema del llibre, que els botons d’estil redueixen a un sol aspecte. A sota hi ha les disposicions del llibre i les predefinides.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
"Fes clic en una. La doble pàgina de la taula de treball rep els marcs d'aquesta composició, i les fotos i el text que ja hi tenies s'hi col·loquen.",
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -961,7 +961,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Použít rozvržení na dvojstranu',
|
||||
'help.guide.studio-layouts.goal': 'Dejte dvoustraně hotové rozvržení rámečků pro fotky a text.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Otevřete v liště „Layouts“. Najdete tam třináct rozvržení dvoustran a zvláštní sadu pro obálku, zadní stranu a samostatné strany.',
|
||||
'Otevřete v liště „Layouts“. Nejdřív jsou navržené stránky: celé obálky a dvoustrany v motivu knihy, které tlačítka stylu zúží na jeden vzhled. Pod nimi následují vlastní rozvržení knihy a vestavěná rozvržení.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Klikněte na jedno z nich. Dvojstrana na pracovní ploše dostane rámečky tohoto rozvržení a vaše stávající fotky a text se do nich umístí.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -1007,7 +1007,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Layout auf eine Doppelseite anwenden',
|
||||
'help.guide.studio-layouts.goal': 'Gib einer Doppelseite eine fertige Anordnung aus Foto- und Textrahmen.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Öffne in der Leiste „Layouts“. Dort gibt es dreizehn Layouts für Doppelseiten und eigene für Cover, Rückseite und Einzelseiten.',
|
||||
'Öffne in der Leiste „Layouts“. Zuerst kommen die gestalteten Seiten: ganze Cover und Doppelseiten im Thema des Buchs, die du über die Stile auf einen Look eingrenzt. Darunter folgen die eigenen Layouts des Buchs und die vorgefertigten.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Klick eines an. Die Doppelseite auf der Arbeitsfläche bekommt die Rahmen dieses Layouts, und deine vorhandenen Fotos und Texte werden darin platziert.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -1185,7 +1185,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Apply a layout to a spread',
|
||||
'help.guide.studio-layouts.goal': 'Give a spread a ready-made arrangement of photo and text frames.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Open Layouts in the rail. It offers thirteen spread layouts, and a separate set for the cover, the back and the single pages.',
|
||||
"Open Layouts in the rail. Designed pages come first: whole covers and spreads set in the book's theme, which the style chips narrow to one look. The book's own layouts and the built-in ones follow below them.",
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Click one. The spread on the workbench gets the frames of this layout, and your existing photos and text are placed into them.',
|
||||
'help.guide.studio-layouts.tip.1': 'A layout is an undo step like any other.',
|
||||
|
||||
@@ -1004,7 +1004,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.goal':
|
||||
'Aplica a una doble página una distribución predefinida de marcos de foto y de texto.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Abre Diseños en la columna. Ofrece trece diseños de doble página y un conjunto aparte para la portada, la contraportada y las páginas sueltas.',
|
||||
'Abre Diseños en la columna. Primero aparecen las páginas diseñadas: portadas y dobles páginas completas con el tema del libro, que los botones de estilo reducen a un solo aspecto. Debajo siguen los diseños propios del libro y los predefinidos.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Haz clic en una. La doble página de la mesa de trabajo toma los marcos de esa composición, y tus fotos y textos se colocan en ellos.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -978,7 +978,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Rakenda lehepaarile paigutus',
|
||||
'help.guide.studio-layouts.goal': 'Anna lehepaarile valmis paigutus foto- ja tekstiraamidega.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Ava külgribal „Paigutused“. Seal on kolmteist lehepaari paigutust ning eraldi komplekt kaane, tagakaane ja üksiklehtede jaoks.',
|
||||
'Ava külgribal „Paigutused“. Kõigepealt tulevad kujundatud lehed: terved kaaned ja lehepaarid raamatu teemas, mida stiilinupud ühe ilmeni kitsendavad. Nende all on raamatu enda paigutused ja sisseehitatud paigutused.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Klõpsa ühel neist. Tööpinnal olev lehepaar saab selle paigutuse raamid ning olemasolevad fotod ja tekst paigutatakse neisse.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -1017,7 +1017,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Appliquer une mise en page à une double page',
|
||||
'help.guide.studio-layouts.goal': 'Appliquer à une double page une disposition toute prête de cadres photo et texte.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Ouvrez « Layouts » dans la colonne de gauche. Vous y trouvez treize mises en page de double page, et une série à part pour la couverture, la quatrième de couverture et les pages simples.',
|
||||
'Ouvrez « Layouts » dans la colonne de gauche. Les pages composées viennent d’abord : couvertures et doubles pages entières dans le thème du livre, que les pastilles de style restreignent à un seul style. Plus bas suivent les mises en page du livre et les mises en page intégrées.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Cliquez sur l’une d’elles. La double page du plan de travail reprend les cadres de cette mise en page, et vos photos et textes existants y sont placés.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -1016,7 +1016,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Εφαρμογή διάταξης σε δισέλιδο',
|
||||
'help.guide.studio-layouts.goal': 'Δώστε σε ένα δισέλιδο μια έτοιμη διάταξη πλαισίων για φωτογραφίες και κείμενο.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Ανοίξτε το «Layouts» στην πλαϊνή στήλη. Προσφέρει δεκατρείς διατάξεις δισέλιδου και ξεχωριστές διατάξεις για το εξώφυλλο, το οπισθόφυλλο και τις μονές σελίδες.',
|
||||
'Ανοίξτε το «Layouts» στην πλαϊνή στήλη. Πρώτα εμφανίζονται οι σχεδιασμένες σελίδες: ολόκληρα εξώφυλλα και δισέλιδα στο θέμα του βιβλίου, που τα κουμπιά στυλ τα περιορίζουν σε μία εμφάνιση. Από κάτω ακολουθούν οι διατάξεις του ίδιου του βιβλίου και οι ενσωματωμένες.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Πατήστε μία. Το δισέλιδο στον χώρο εργασίας παίρνει τα πλαίσια αυτής της διάταξης και οι φωτογραφίες και τα κείμενα που έχετε ήδη μπαίνουν μέσα σε αυτά.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -1008,7 +1008,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Elrendezés alkalmazása egy oldalpárra',
|
||||
'help.guide.studio-layouts.goal': 'Adj egy oldalpárnak kész elrendezést fotó- és szövegkeretekkel.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Nyisd meg az oldalsávban a „Layouts” részt. Tizenhárom oldalpár-elrendezés közül választhatsz, a borítóhoz, a hátlaphoz és az önálló oldalakhoz pedig külön készlet tartozik.',
|
||||
'Nyisd meg az oldalsávban a „Layouts” részt. Elöl a megtervezett oldalak állnak: teljes borítók és oldalpárok a könyv témájában, amelyeket a stílusgombok egyetlen megjelenésre szűkítenek. Alattuk következnek a könyv saját elrendezései és a beépítettek.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Kattints egyre. A munkaterületen lévő kétoldalas nézet megkapja ennek az elrendezésnek a kereteit, a meglévő fotóid és szövegeid pedig bekerülnek a keretekbe.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -986,7 +986,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Terapkan tata letak ke halaman ganda',
|
||||
'help.guide.studio-layouts.goal': 'Beri halaman ganda susunan bingkai foto dan teks yang siap pakai.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Buka “Layouts” di panel samping. Ada tiga belas tata letak halaman ganda, serta satu set terpisah untuk sampul depan, sampul belakang, dan halaman tunggal.',
|
||||
'Buka “Layouts” di panel samping. Halaman berdesain tampil lebih dulu: sampul dan halaman ganda utuh dengan tema buku, yang bisa dipersempit ke satu gaya lewat tombol gaya. Di bawahnya ada tata letak milik buku dan tata letak bawaan.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Klik salah satunya. Halaman ganda di area kerja mendapat bingkai-bingkai dari tata letak ini, dan foto serta teks yang sudah ada ditempatkan ke dalamnya.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -996,7 +996,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Applicare un layout a una doppia pagina',
|
||||
'help.guide.studio-layouts.goal': 'Dai a una doppia pagina una disposizione già pronta di cornici per foto e testo.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Apri «Layout» nella barra laterale. Trovi tredici layout per le doppie pagine e una serie a parte per copertina, retro e pagine singole.',
|
||||
'Apri «Layout» nella barra laterale. Per prime ci sono le pagine progettate: copertine e doppie pagine intere nel tema del libro, che i pulsanti di stile restringono a un solo aspetto. Sotto seguono i layout del libro e quelli predefiniti.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Cliccane uno. La doppia pagina sul piano di lavoro riceve le cornici di quel layout, e le foto e i testi già presenti vengono inseriti al loro interno.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -924,7 +924,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': '見開きにレイアウトを適用する',
|
||||
'help.guide.studio-layouts.goal': '見開きに、写真とテキストのフレームを配置した既成のレイアウトを適用します。',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'サイドバーの「レイアウト」を開きます。見開き用のレイアウトが13種類と、表紙、裏表紙、単ページ用のレイアウトが別に用意されています。',
|
||||
'サイドバーの「レイアウト」を開きます。最初にデザイン済みページが並びます。本のテーマで組まれた表紙と見開きのページ全体で、スタイルのボタンで一つの雰囲気に絞り込めます。その下に、この本のレイアウトと標準のレイアウトが続きます。',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'レイアウトを1つクリックします。作業エリアの見開きにそのレイアウトのフレームが適用され、既存の写真とテキストがフレームに配置されます。',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -882,7 +882,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': '펼침면에 레이아웃 적용하기',
|
||||
'help.guide.studio-layouts.goal': '사진과 텍스트 프레임이 미리 배치된 레이아웃을 펼침면에 적용해요.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'레일에서 Layouts를 여세요. 펼침면 레이아웃 열세 가지와 표지, 뒤표지, 낱쪽용 레이아웃 세트가 따로 있어요.',
|
||||
'레일에서 Layouts를 여세요. 먼저 디자인된 페이지가 나와요. 책의 테마로 꾸민 표지와 펼침면 전체이고, 스타일 버튼으로 한 가지 느낌만 골라 볼 수 있어요. 그 아래에 이 책의 레이아웃과 기본 제공 레이아웃이 이어져요.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'하나를 클릭하세요. 작업 공간의 펼침면에 이 레이아웃의 프레임이 적용되고, 기존 사진과 글이 그 안에 배치돼요.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -992,7 +992,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.goal':
|
||||
"Geef een dubbele pagina een kant-en-klare indeling met kaders voor foto's en tekst.",
|
||||
'help.guide.studio-layouts.step.1':
|
||||
"Open Layouts in de zijbalk. Daar vind je dertien lay-outs voor dubbele pagina's, en een aparte set voor de omslag, de achterkant en losse pagina's.",
|
||||
'Open Layouts in de zijbalk. Eerst komen de ontworpen pagina’s: hele omslagen en dubbele pagina’s in het thema van het boek, die je met de stijlknoppen tot één uitstraling beperkt. Daaronder volgen de eigen lay-outs van het boek en de standaardlay-outs.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
"Klik op een opmaak. De dubbele pagina op het werkblad krijgt de kaders van die opmaak, en je bestaande foto's en tekst worden erin geplaatst.",
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -985,7 +985,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Zastosuj układ do rozkładówki',
|
||||
'help.guide.studio-layouts.goal': 'Nadaj rozkładówce gotowy układ ramek na zdjęcia i tekst.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Otwórz Layouts na pasku bocznym. Znajdziesz tam trzynaście układów rozkładówek oraz osobny zestaw dla okładki, tyłu i pojedynczych stron.',
|
||||
'Otwórz Layouts na pasku bocznym. Najpierw są zaprojektowane strony: całe okładki i rozkładówki w motywie książki, które przyciski stylu zawężają do jednego wyglądu. Pod nimi są własne układy książki i układy wbudowane.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Kliknij jeden z układów. Rozkładówka na stole roboczym dostaje ramki tego układu, a Twoje dotychczasowe zdjęcia i teksty zostają w nich rozmieszczone.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -985,7 +985,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Применить макет к развороту',
|
||||
'help.guide.studio-layouts.goal': 'Примените к развороту готовую раскладку рамок для фото и текста.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Откройте «Layouts» на панели. Там тринадцать макетов разворотов и отдельный набор для обложки, задней обложки и одиночных страниц.',
|
||||
'Откройте «Layouts» на панели. Сначала идут оформленные страницы: целые обложки и развороты в теме книги, которые кнопки стиля сужают до одного вида. Ниже следуют собственные макеты книги и встроенные макеты.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Выберите макет. Разворот в рабочей области получит его рамки, а уже добавленные фото и текст разместятся в них.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -976,7 +976,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Použiť rozloženie na dvojstranu',
|
||||
'help.guide.studio-layouts.goal': 'Dajte dvojstrane hotové rozloženie rámčekov pre fotky a text.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'V paneli otvorte Rozloženia. Ponúka trinásť rozložení dvojstrán a samostatnú sadu pre obálku, zadnú stranu a jednotlivé strany.',
|
||||
'V paneli otvorte Rozloženia. Najprv sú navrhnuté strany: celé obálky a dvojstrany v motíve knihy, ktoré tlačidlá štýlu zúžia na jeden vzhľad. Pod nimi nasledujú vlastné rozloženia knihy a vstavané rozloženia.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Kliknite na jedno z nich. Dvojstrana na pracovnej ploche dostane rámčeky tohto rozloženia a vaše existujúce fotky a texty sa do nich umiestnia.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -965,7 +965,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Använd en layout på ett uppslag',
|
||||
'help.guide.studio-layouts.goal': 'Ge ett uppslag en färdig uppställning av foto- och textramar.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Öppna ”Layouts” i sidofältet. Där finns tretton uppslagslayouter och en separat uppsättning för omslaget, baksidan och de enskilda sidorna.',
|
||||
'Öppna ”Layouts” i sidofältet. Först kommer de formgivna sidorna: hela omslag och uppslag i bokens tema, som stilknapparna begränsar till ett uttryck. Under dem följer bokens egna layouter och de inbyggda.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Klicka på en. Uppslaget på arbetsytan får layoutens ramar, och dina befintliga foton och texter placeras i dem.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -913,7 +913,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'ใช้เค้าโครงกับหน้าคู่',
|
||||
'help.guide.studio-layouts.goal': 'ให้หน้าคู่มีการจัดวางกรอบรูปและกรอบข้อความแบบสำเร็จรูป',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'เปิด “เค้าโครง” ในแถบด้านข้าง มีเค้าโครงหน้าคู่สิบสามแบบ และอีกชุดแยกสำหรับปก ปกหลัง และหน้าเดี่ยว',
|
||||
'เปิด “เค้าโครง” ในแถบด้านข้าง หน้าที่ออกแบบไว้จะแสดงก่อน คือปกและหน้าคู่ทั้งหน้าในธีมของหนังสือ ซึ่งปุ่มสไตล์ช่วยกรองให้เหลือแบบเดียว ด้านล่างเป็นเค้าโครงของหนังสือเองและเค้าโครงในตัว',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'คลิกเลือกหนึ่งแบบ หน้าคู่บนพื้นที่ทำงานจะใช้กรอบของเค้าโครงนั้น รูปภาพและข้อความที่มีอยู่แล้วจะถูกใส่ลงในกรอบ',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -980,7 +980,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Bir çift sayfaya yerleşim uygulayın',
|
||||
'help.guide.studio-layouts.goal': 'Bir çift sayfaya hazır bir fotoğraf ve metin çerçevesi düzeni uygulayın.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Şeritte Layouts bölümünü açın. On üç çift sayfa düzeni sunar, ayrıca kapak, arka kapak ve tek sayfalar için ayrı bir küme vardır.',
|
||||
'Şeritte Layouts bölümünü açın. Önce tasarlanmış sayfalar gelir: kitabın temasında hazırlanmış kapaklar ve çift sayfalar; stil düğmeleri bunları tek bir görünüme daraltır. Altlarında kitabın kendi düzenleri ve hazır düzenler yer alır.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Birine tıklayın. Çalışma alanındaki çift sayfa bu düzenin çerçevelerini alır; mevcut fotoğraflarınız ve metinleriniz bu çerçevelere yerleştirilir.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -983,7 +983,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Застосувати макет до розвороту',
|
||||
'help.guide.studio-layouts.goal': 'Дайте розвороту готове розташування рамок для фото й тексту.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Відкрийте «Layouts» на панелі. Там тринадцять макетів розворотів і окремий набір для обкладинки, задньої обкладинки й окремих сторінок.',
|
||||
'Відкрийте «Layouts» на панелі. Спершу йдуть оформлені сторінки: цілі обкладинки й розвороти в темі книги, які кнопки стилю звужують до одного вигляду. Нижче йдуть власні макети книги та вбудовані макети.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Клацніть потрібний. Розворот у робочій області отримає рамки цього макета, а ваші фото й текст розмістяться в них.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -965,7 +965,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': 'Áp dụng bố cục cho một trang đôi',
|
||||
'help.guide.studio-layouts.goal': 'Áp dụng cho trang đôi một cách sắp xếp sẵn của các khung ảnh và khung văn bản.',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'Mở Layouts trên thanh bên. Có mười ba bố cục trang đôi, cùng một bộ riêng cho bìa, bìa sau và các trang đơn.',
|
||||
'Mở Layouts trên thanh bên. Trước tiên là các trang thiết kế sẵn: bìa và trang đôi hoàn chỉnh theo chủ đề của sách, có thể lọc theo một phong cách bằng các nút phong cách. Bên dưới là các bố cục riêng của sách và các bố cục có sẵn.',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'Nhấn vào một bố cục. Trang đôi trên vùng làm việc sẽ có các khung của bố cục này, và ảnh cùng văn bản bạn đã có được đặt vào các khung đó.',
|
||||
'help.guide.studio-layouts.result':
|
||||
|
||||
@@ -828,7 +828,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': '為跨頁套用版面',
|
||||
'help.guide.studio-layouts.goal': '為跨頁套用現成的照片框和文字框排版。',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'在側欄開啟 Layouts。這裡提供十三種跨頁版面,另外還有一組專為封面、封底和單頁設計的版面。',
|
||||
'在側欄開啟 Layouts。最上方是設計好的頁面:以書的主題呈現的完整封面與跨頁,可用風格按鈕篩選出一種風格。下方接著是這本書自己的版面和內建版面。',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'點選其中一個。工作區中的跨頁會套用這個版型的框,你原有的照片和文字也會放進這些框裡。',
|
||||
'help.guide.studio-layouts.result': '空框是內容的預留位置:從 Content 把照片拖到框上,或使用 Add to this page。',
|
||||
|
||||
@@ -827,7 +827,7 @@ const help: TranslationStrings = {
|
||||
'help.guide.studio-layouts.title': '为跨页应用版式',
|
||||
'help.guide.studio-layouts.goal': '为跨页套用一组现成的照片框和文字框排版。',
|
||||
'help.guide.studio-layouts.step.1':
|
||||
'在侧栏中打开 Layouts。这里有十三种跨页版式,另有一组单独用于封面、封底和单页的版式。',
|
||||
'在侧栏中打开 Layouts。最上面是设计好的页面:以书的主题呈现的完整封面和跨页,可用风格按钮筛选出一种风格。下面接着是这本书自己的版式和内置版式。',
|
||||
'help.guide.studio-layouts.step.2':
|
||||
'点击其中一个。工作台上的跨页会换成这个版式的相框,你已有的照片和文字会放进这些相框里。',
|
||||
'help.guide.studio-layouts.result': '空相框是内容的占位:把照片从“内容”拖到相框上,或使用“添加到此页”。',
|
||||
|
||||
@@ -179,7 +179,7 @@ A journey can also be laid out as a printable photo book. Open a journey and cli
|
||||
- **Page format** — Square 21 × 21 cm (the default), Square 30 × 30 cm, A4 landscape, A4 portrait, A5 landscape, or a custom width × height in millimetres. Everything is drawn as a spread (two pages side by side) with 3 mm bleed and a 5 mm safe margin.
|
||||
- **The shape of the book** follows a bound one: a cover, a single first page on the right (page 1, where a title page or a dedication goes), the spreads, a single last page on the left, and a back cover. The first and last pages take the cover layouts and, like the covers, stay where they are; new spreads always go between them. Page numbers, when switched on, count from the first page, and the number on screen is the number that prints. Books made before this had no single pages and keep their numbering as it was.
|
||||
- **Auto layout** has two entries. **This spread** builds the spread on screen again from the journal entry it came from, and is only offered on a spread that came from one. **The whole book** replaces every page, keeping your title and page setup. Both are ordinary undo steps, so you can press one, look at it, and undo.
|
||||
- **Pages, Content, Elements, Travel and Layouts** are the sections of the left rail. Content holds the journey's own photos and entries, with **Upload photos** and, when Immich or Synology Photos is connected, **From Immich** or **From Synology Photos** to add photos from your library the way the journey gallery does; Layouts has thirteen spread layouts (Hero and story, Four up, Strip and text, Mosaic and so on) plus a separate set of five for the cover and back; Elements has text styles, shapes, lines, grids, empty frames with their frame styles, and a searchable icon library; Travel builds figures out of the journey itself: route maps, country outlines and lists, flags, date, day and distance marks, and a trip summary.
|
||||
- **Pages, Content, Elements, Travel and Layouts** are the sections of the left rail. Content holds the journey's own photos and entries, with **Upload photos** and, when Immich or Synology Photos is connected, **From Immich** or **From Synology Photos** to add photos from your library the way the journey gallery does; Layouts opens on **Designed pages**, whole pages laid out by a designer: 21 covers in seven styles (spine band, poster, cut-out, postcard, grid and badge, minimal, stamps) for the cover and the other single pages, and 16 double spreads for the pages between. Each card shows the page you are on as the click will lay it, with its own photos and words in the template and in the book's theme, and the style chips narrow the set to one look. Below them come the book's own layouts and the built-in ones: thirteen spread layouts (Hero and story, Four up, Strip and text, Mosaic and so on) plus a separate set of five for the cover and back; Elements has text styles, shapes, lines, grids, empty frames with their frame styles, and a searchable icon library; Travel builds figures out of the journey itself: route maps, country outlines and lists, flags, date, day and distance marks, and a trip summary.
|
||||
- **Properties** on the right edits whatever is selected: position and size, crop and focal point, fill or fit, a look filter, corner radius, frame style, stacking order, lock. An element that auto layout tied to a journal entry follows that entry until you edit it here, which breaks the link.
|
||||
- **Copy and paste**: a selected element copies with Ctrl+C and pastes on any page with Ctrl+V or the paste button.
|
||||
- **My layouts**: **Save this page as a layout** keeps the arrangement of a page without its photos, for every editor of the book, and applying it lays another page out the same way while keeping that page's photos and words. A book keeps up to 24 layouts.
|
||||
|
||||
Reference in New Issue
Block a user