Present: slide order, presentation settings, blocks drawn for a screen
- Setup's Order list: drag or move any slide; saved in the address - A heading-only section titles the slides after it, no slide of its own - Event Presentation settings (095): background image and color, dim, frame, accent, text color, logo - Blocks: Presentation text and Leave out of the presentation; map blocks get a slide per section, map only, no details, location slides - Presented, links are plain text, people a row of round photos and names, organizations their logos Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
a79559d290
commit
7e21a0dd40
16 changed files with 652 additions and 68 deletions
|
|
@ -64,6 +64,20 @@ export function loadLinks(db, ownerKind, ids) {
|
|||
rather than no key, so the renderer never has to check.
|
||||
───────────────────────────────────────────────────────────── */
|
||||
|
||||
/* A block's presentation settings (095), or null with none set. */
|
||||
function presentOf(row) {
|
||||
const present = {
|
||||
hide: row.present_hide === 1,
|
||||
text: row.present_text,
|
||||
map_split: row.present_map_split === 1,
|
||||
map_no_list: row.present_map_no_list === 1,
|
||||
map_no_details: row.present_map_no_details === 1,
|
||||
places: row.present_places,
|
||||
place_keys: row.present_place_keys ? row.present_place_keys.split(",").filter(Boolean) : [],
|
||||
};
|
||||
return Object.values(present).some((value) => (Array.isArray(value) ? value.length : value)) ? present : null;
|
||||
}
|
||||
|
||||
export function loadBlocks(db, ownerKind, ids, slot = "body", depth = 0) {
|
||||
const out = new Map();
|
||||
if (ids.length === 0) return out;
|
||||
|
|
@ -71,7 +85,9 @@ export function loadBlocks(db, ownerKind, ids, slot = "body", depth = 0) {
|
|||
const blockRows = db
|
||||
.prepare(
|
||||
`SELECT id, owner_id, type, text, media, href, alt, cite, captions, team_id, venue_id,
|
||||
word_motion, word_direction, word_seconds, list_style, org_kind
|
||||
word_motion, word_direction, word_seconds, list_style, org_kind,
|
||||
present_hide, present_text, present_map_split, present_map_no_list,
|
||||
present_map_no_details, present_places, present_place_keys
|
||||
FROM content_blocks
|
||||
WHERE owner_kind = ? AND slot IN (?, 'both') AND owner_id IN (${placeholders(ids.length)})
|
||||
ORDER BY owner_id, sort_order`,
|
||||
|
|
@ -99,6 +115,8 @@ export function loadBlocks(db, ownerKind, ids, slot = "body", depth = 0) {
|
|||
words: row.word_motion || row.word_direction || row.word_seconds
|
||||
? { motion: row.word_motion, direction: row.word_direction, seconds: row.word_seconds }
|
||||
: null,
|
||||
// How it's presented (095), when anything is set.
|
||||
present: presentOf(row),
|
||||
items: [],
|
||||
};
|
||||
byId.set(row.id, block);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue