Bento, the office suite that fits in a file
TypeScript mit-licenseofficeoffice-365office-suiteoffice-toolsoffice365open-sourcepowerpointself-hostedsingle-page-appslidesslideshareslideshowslideshow-galleryslideshow-makerslideshows
v0.8.4: topbar redesign — no scrollbar, panel chevrons, Live popover, Save menu
nyblnete33a41b09252
diff --git a/CLAUDE.md b/CLAUDE.mdindex 835a851e..478728ac 100644--- a/CLAUDE.md+++ b/CLAUDE.md@@ -185,9 +185,15 @@ One HTML file = the document + viewer + editor. See `README.md` for the vision.undo step; Alt stays reserved for deep-select, so it can't be the copykey). Present: real fullscreen via overlay.requestFullscreen at start +F toggle (denied requests degrade to tab-fill — that IS the testing/- sharing mode). Topbar is responsive: labels collapse to icons <1280px,- the bar itself x-scrolls; phones (<700px) boot with both side panels- collapsed (canvas-first; toggles/[/] bring them back). Deck buttons use+ sharing mode). Topbar is responsive by HIDING TEXT, never scrolling: labels+ collapse to icons <1200px, the wordmark collapses to the mark <760px.+ Panel show/hide lives ON the resizer strips as chevron tabs (docked+ flush to the screen edge when collapsed); phones (<700px) boot with+ both panels collapsed (canvas-first; chevrons/[/] bring them back).+ Update chip sits beside the wordmark and exists ONLY when an update+ is found. Save is a dropdown: copy (identity-keeping invite) / new+ deck (fresh identity) / template. "Live" button popover: name field,+ collaborator list (click follows), join/leave toasts. Deck buttons useONE invisible hit-rect above button+label (hard-won #7) — never put`link` on both a rect and its label text (two mismatched hover pills).Alt/Option-click digs through overlapping elements (capture-phase, beatsdiff --git a/slides/package.json b/slides/package.jsonindex 9491f090..dddb393b 100644--- a/slides/package.json+++ b/slides/package.json@@ -1,7 +1,7 @@{"name": "bento-slides","private": true,- "version": "0.8.3",+ "version": "0.8.4","type": "module","scripts": {"dev": "vite",diff --git a/slides/src/editor/editor.ts b/slides/src/editor/editor.tsindex 06b4d5ca..9e5d0aba 100644--- a/slides/src/editor/editor.ts+++ b/slides/src/editor/editor.ts@@ -72,9 +72,20 @@ export class Editor {/** wire the live-collaboration session (avatars, remote selections, relay) */connectSync(session: import('../sync/session').SyncSession) {this.session = session+ let known = new Map(session.peers().map((p) => [p.actor, p.name]))session.onPeers(() => {this.renderAvatars()this.canvas.setRemotePeers(session.peers())+ if (this.shareWrap.classList.contains('open')) this.renderSharePanel()+ // presence arrivals/departures get a quiet heads-up+ const now = new Map(session.peers().map((p) => [p.actor, p.name]))+ for (const [actor, name] of now) {+ if (!known.has(actor)) this.toast(t('{name} joined', { name }))+ }+ for (const [actor, name] of known) {+ if (!now.has(actor)) this.toast(t('{name} left', { name }))+ }+ known = now})this.canvas.onTextEditChange = (elId) => session.setEditing(elId)this.store.on('current', () => this.canvas.setRemotePeers(session.peers()))@@ -172,24 +183,23 @@ export class Editor {insert.appendChild(commentB)const actions = div('ed-group ed-group-right')+ // the update chip sits beside the wordmark and exists ONLY when an+ // update is available (manual checks live in the About dialog)this.updatesB = btn(ICONS.sync, '', () => this.openAbout(true), t('Check for updates'))- // launch-time check (opt-out lives in the About dialog); a found update- // turns the button into a visible peach chip+ this.updatesB.style.display = 'none'setTimeout(async () => {if (!autoCheckEnabled() || offlineEnabled()) returnconst r = await checkForUpdates()this.lastAutoCheck = rif (r.status === 'update') {this.updateFound = r.release.version+ this.updatesB.style.display = ''this.updatesB.classList.add('ed-btn-update')this.updatesB.innerHTML = `${ICONS.sync}<span>v${r.release.version}</span>`this.updatesB.title = t('Version {v} is available — click to update', { v: r.release.version })this.toast(t('Update available: v{v} — click the peach button to update', { v: r.release.version }))} else if (r.status === 'current') {- this.updatesB.title = t('Up to date (v{v}) — checked at launch', { v: APP_VERSION })this.toast(t('Up to date — v{v}', { v: APP_VERSION }))- } else {- this.updatesB.title = t('Update check failed: {m} — click to retry', { m: r.message })}}, 1500)const undoB = btn(ICONS.undo, '', () => this.store.undo(), t('Undo (⌘Z)'))@@ -197,14 +207,11 @@ export class Editor {const presentB = btn(ICONS.play, t('Present'), () => this.present(), t('Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends'))presentB.classList.add('ed-btn-primary')const saveB = btn(ICONS.save, t('Save'), () => this.save(false), t('Save — rewrite this file in place (⌘S)'))- const saveAsB = btn(ICONS.download, '', () => this.save(true), t('Save a copy — pick a new file, leave this one untouched'))const pdfB = btn(ICONS.pdf, '', () => this.exportPdf(), t('Export PDF (print)'))- const leftT = btn(ICONS.panelLeft, '', () => this.togglePanel('left'), t('Toggle slide list ([)'))- const rightT = btn(ICONS.panelRight, '', () => this.togglePanel('right'), t('Toggle properties (])'))- actions.append(undoB, redoB, pdfB, this.shareDropdown(), this.updatesB, leftT, rightT, presentB, saveB, saveAsB)+ actions.append(undoB, redoB, pdfB, this.shareDropdown(), presentB, saveB, this.saveDropdown())this.avatarsBox = div('ed-avatars')- bar.append(logo, title, this.dirtyDot, this.avatarsBox, insert, actions)+ bar.append(logo, this.updatesB, title, this.dirtyDot, this.avatarsBox, insert, actions)// main areaconst main = div('ed-main')@@ -249,15 +256,45 @@ export class Editor {this.props.style.setProperty('--panew', `${this.panelW.right}px`)}+ private panelToggles: { left?: HTMLElement; right?: HTMLElement } = {}++ private updatePanelChevrons() {+ const glyph = (side: 'left' | 'right') => {+ const collapsed = (side === 'left' ? this.sidebar : this.props).classList.contains('ed-collapsed')+ // chevron points where clicking will move the boundary+ return side === 'left' ? (collapsed ? '›' : '‹') : (collapsed ? '‹' : '›')+ }+ for (const side of ['left', 'right'] as const) {+ const b = this.panelToggles[side]+ if (b) {+ b.textContent = glyph(side)+ const collapsed = (side === 'left' ? this.sidebar : this.props).classList.contains('ed-collapsed')+ b.title = collapsed+ ? side === 'left' ? t('Show slide list ([)') : t('Show properties (])')+ : side === 'left' ? t('Hide slide list ([)') : t('Hide properties (])')+ }+ }+ }+private makeResizer(side: 'left' | 'right'): HTMLElement {const handle = div('ed-resizer')handle.title = t('Drag to resize · double-click to reset')+ const toggle = document.createElement('button')+ toggle.className = 'ed-panel-toggle'+ toggle.addEventListener('click', (ev) => {+ ev.stopPropagation()+ this.togglePanel(side)+ })+ this.panelToggles[side] = toggle+ handle.appendChild(toggle)+ queueMicrotask(() => this.updatePanelChevrons())const commit = () => {localStorage.setItem('bento-ed-panels', JSON.stringify(this.panelW))// thumbnails render at a width derived from the sidebar — refit themif (side === 'left') this.rebuildSidebar()}handle.addEventListener('mousedown', (down) => {+ if (down.target === toggle) return // the chevron is a click, not a dragconst panel = side === 'left' ? this.sidebar : this.propsif (panel.classList.contains('ed-collapsed')) returndown.preventDefault()@@ -293,15 +330,73 @@ export class Editor {togglePanel(side: 'left' | 'right') {const el = side === 'left' ? this.sidebar : this.propsel.classList.toggle('ed-collapsed')+ this.updatePanelChevrons()// the canvas wrap resizes; its ResizeObserver re-fits the stage}+ // --- Save dropdown: copy / new deck / template -----------------------------++ private saveDropdown(): HTMLElement {+ const wrap = div('ed-dropdown')+ const trigger = btn(ICONS.download, '', () => wrap.classList.toggle('open'),+ t('More ways to save — copy, new deck, template'))+ const menu = div('ed-menu ed-save-menu')+ const item = (label: string, title: string, onClick: () => void) => {+ const b = document.createElement('button')+ b.className = 'ed-btn'+ b.textContent = label+ b.title = title+ b.addEventListener('click', () => {+ wrap.classList.remove('open')+ onClick()+ })+ menu.appendChild(b)+ }+ item(t('Save a copy'),+ t('Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.'),+ () => void this.save(true))+ item(t('Save as new deck…'),+ t('Same content, brand-new document — its own identity and keys; it will never sync with this one.'),+ () => this.saveAsNewDeck())+ item(t('Save as template…'),+ t('Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.'),+ () => void this.saveAsTemplate())+ wrap.append(trigger, menu)+ document.addEventListener('pointerdown', (ev) => {+ if (!wrap.contains(ev.target as Node)) wrap.classList.remove('open')+ })+ return wrap+ }++ private saveAsNewDeck() {+ const clone = JSON.parse(JSON.stringify(this.store.doc)) as import('../model').BentoDoc+ clone.docId = newDocId()+ clone.collab = mintCollab()+ this.store.replaceDoc(clone)+ this.toast(t('This is now a new deck — save it under a new name'))+ void this.save(true)+ }++ private async saveAsTemplate() {+ const clone = JSON.parse(JSON.stringify(this.store.doc)) as import('../model').BentoDoc+ clone.template = true+ delete clone.collab // instances mint their own credentials+ delete (clone as { docId?: string }).docId+ try {+ const ok = await writeUpdatedFileAs(serializeFile(clone), clone)+ if (ok) this.toast(t('Template saved — every open of it starts a fresh deck'))+ } catch (err) {+ console.error(err)+ this.toast(t('Save failed — see console'))+ }+ }+// --- live-collaboration Share popover ------------------------------------private shareDropdown(): HTMLElement {const wrap = div('ed-dropdown')this.shareWrap = wrap- this.shareB = btn(ICONS.share, t('Collaborate'), () => {+ this.shareB = btn(ICONS.share, t('Live'), () => {wrap.classList.toggle('open')if (wrap.classList.contains('open')) this.renderSharePanel()}, t('Live collaboration — work on this deck together'))@@ -354,6 +449,33 @@ export class Editor {nameRow.append(nameLabel, nameInput)panel.appendChild(nameRow)+ // who's here, live — colored dot, name, slide; click follows+ const peers = this.session?.peers() ?? []+ if (peers.length) {+ const list = div('ed-share-peers')+ for (const peer of peers) {+ const row = document.createElement('button')+ row.className = 'ed-share-peer'+ const dot = document.createElement('span')+ dot.className = 'dot'+ dot.style.background = peer.color+ const who = document.createElement('span')+ who.className = 'who'+ who.textContent = peer.editing ? `${peer.name} ✏️` : peer.name+ const where = document.createElement('span')+ where.className = 'where'+ const idx = this.store.doc.slides.findIndex((s) => s.id === peer.slide)+ where.textContent = idx >= 0 ? t('slide {n}', { n: idx + 1 }) : ''+ row.append(dot, who, where)+ row.title = t('{name} — on slide {n} (click to follow)', { name: peer.name, n: idx + 1 })+ row.addEventListener('click', () => {+ if (idx >= 0) this.store.goTo(idx)+ })+ list.appendChild(row)+ }+ panel.appendChild(list)+ }+if (offlineEnabled()) {note(t('Offline mode is on — nothing leaves this computer.'))note(t('Tabs on this machine still sync; turn offline mode off in the About dialog to collaborate online.'))@@ -1116,41 +1238,6 @@ export class Editor {aiRow.append(copyB, replB)box.appendChild(aiRow)- // identity fork: same content, brand-new document — new docId + fresh- // collab credentials, so it never syncs with its ancestor's copies- const dupRow = div('ed-about-row')- const dupB = document.createElement('button')- dupB.className = 'ed-btn'- dupB.textContent = t('Duplicate as new deck…')- dupB.title = t('Copies everything into an independent document with its own identity — it will never sync with this one.')- dupB.addEventListener('click', () => {- const clone = JSON.parse(JSON.stringify(this.store.doc)) as import('../model').BentoDoc- clone.docId = newDocId()- clone.collab = mintCollab()- this.store.replaceDoc(clone)- close()- this.toast(t('This is now a new deck — save it under a new name'))- void this.save(true)- })- const tplB = document.createElement('button')- tplB.className = 'ed-btn'- tplB.textContent = t('Save as template…')- tplB.title = t('Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.')- tplB.addEventListener('click', async () => {- const clone = JSON.parse(JSON.stringify(this.store.doc)) as import('../model').BentoDoc- clone.template = true- delete clone.collab // instances mint their own credentials- delete (clone as { docId?: string }).docId- try {- const ok = await writeUpdatedFileAs(serializeFile(clone), clone)- if (ok) this.toast(t('Template saved — every open of it starts a fresh deck'))- } catch (err) {- console.error(err)- this.toast(t('Save failed — see console'))- }- })- dupRow.append(dupB, tplB)- box.appendChild(dupRow)const fine = div('ed-about-fine')fine.innerHTML =diff --git a/slides/src/i18n/de.ts b/slides/src/i18n/de.tsindex 0ce1b6c8..031f2a91 100644--- a/slides/src/i18n/de.ts+++ b/slides/src/i18n/de.ts@@ -271,4 +271,16 @@ export const de: Catalog = {"Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.": "Speichert eine Vorlagenkopie: Wer sie öffnet, erhält ein frisches, unabhängiges Deck mit eigener Identität und eigenen Schlüsseln.","Template saved — every open of it starts a fresh deck": "Vorlage gespeichert — jedes Öffnen startet ein frisches Deck","Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends": "Ab aktueller Folie präsentieren — F wechselt Vollbild, S öffnet die Referentenansicht, Esc beendet",+ "Show slide list ([)": "Folienliste einblenden ([)",+ "Hide slide list ([)": "Folienliste ausblenden ([)",+ "Show properties (])": "Eigenschaften einblenden (])",+ "Hide properties (])": "Eigenschaften ausblenden (])",+ "More ways to save — copy, new deck, template": "Weitere Speicheroptionen — Kopie, neues Deck, Vorlage",+ "Save a copy": "Kopie speichern",+ "Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.": "Neue Datei wählen, diese bleibt unberührt — die Kopie eines geteilten Decks tritt derselben Live-Sitzung bei.",+ "Save as new deck…": "Als neues Deck speichern…",+ "Same content, brand-new document — its own identity and keys; it will never sync with this one.": "Gleicher Inhalt, brandneues Dokument — eigene Identität und Schlüssel; es synchronisiert sich nie mit diesem.",+ "slide {n}": "Folie {n}",+ "{name} joined": "{name} ist beigetreten",+ "{name} left": "{name} hat verlassen",}diff --git a/slides/src/i18n/es.ts b/slides/src/i18n/es.tsindex cfb48732..3f530608 100644--- a/slides/src/i18n/es.ts+++ b/slides/src/i18n/es.ts@@ -271,4 +271,16 @@ export const es: Catalog = {"Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.": "Guarda una copia como plantilla: cada persona que la abra obtiene una presentación nueva e independiente, con identidad y claves propias.","Template saved — every open of it starts a fresh deck": "Plantilla guardada: cada apertura inicia una presentación nueva","Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends": "Presentar desde la diapositiva actual — F alterna pantalla completa, S abre la vista de ponente, Esc termina",+ "Show slide list ([)": "Mostrar lista de diapositivas ([)",+ "Hide slide list ([)": "Ocultar lista de diapositivas ([)",+ "Show properties (])": "Mostrar propiedades (])",+ "Hide properties (])": "Ocultar propiedades (])",+ "More ways to save — copy, new deck, template": "Más formas de guardar: copia, presentación nueva, plantilla",+ "Save a copy": "Guardar una copia",+ "Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.": "Elige un archivo nuevo sin tocar este: una copia de una presentación compartida se une a la misma sesión en vivo.",+ "Save as new deck…": "Guardar como presentación nueva…",+ "Same content, brand-new document — its own identity and keys; it will never sync with this one.": "Mismo contenido, documento totalmente nuevo: identidad y claves propias; nunca se sincronizará con este.",+ "slide {n}": "diapositiva {n}",+ "{name} joined": "{name} se ha unido",+ "{name} left": "{name} se ha ido",}diff --git a/slides/src/i18n/fr.ts b/slides/src/i18n/fr.tsindex f85fcdb6..78bfa688 100644--- a/slides/src/i18n/fr.ts+++ b/slides/src/i18n/fr.ts@@ -271,4 +271,16 @@ export const fr: Catalog = {"Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.": "Enregistre une copie modèle : chaque personne qui l'ouvre obtient un diaporama neuf et indépendant, avec sa propre identité et ses propres clés.","Template saved — every open of it starts a fresh deck": "Modèle enregistré — chaque ouverture démarre un nouveau diaporama","Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends": "Présenter depuis la diapositive actuelle — F bascule le plein écran, S ouvre la vue présentateur, Échap termine",+ "Show slide list ([)": "Afficher la liste des diapositives ([)",+ "Hide slide list ([)": "Masquer la liste des diapositives ([)",+ "Show properties (])": "Afficher les propriétés (])",+ "Hide properties (])": "Masquer les propriétés (])",+ "More ways to save — copy, new deck, template": "Autres façons d'enregistrer — copie, nouveau diaporama, modèle",+ "Save a copy": "Enregistrer une copie",+ "Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.": "Choisissez un nouveau fichier sans toucher celui-ci — la copie d'un diaporama partagé rejoint la même session en direct.",+ "Save as new deck…": "Enregistrer comme nouveau diaporama…",+ "Same content, brand-new document — its own identity and keys; it will never sync with this one.": "Même contenu, document tout neuf — identité et clés propres ; il ne se synchronisera jamais avec celui-ci.",+ "slide {n}": "diapositive {n}",+ "{name} joined": "{name} a rejoint",+ "{name} left": "{name} est parti",}diff --git a/slides/src/i18n/it.ts b/slides/src/i18n/it.tsindex def9a3f6..c3097a85 100644--- a/slides/src/i18n/it.ts+++ b/slides/src/i18n/it.ts@@ -271,4 +271,16 @@ export const it: Catalog = {"Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.": "Salva una copia modello: chiunque la apra ottiene una presentazione nuova e indipendente, con identità e chiavi proprie.","Template saved — every open of it starts a fresh deck": "Modello salvato: ogni apertura avvia una nuova presentazione","Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends": "Presenta dalla diapositiva corrente — F alterna lo schermo intero, S apre la vista relatore, Esc termina",+ "Show slide list ([)": "Mostra elenco diapositive ([)",+ "Hide slide list ([)": "Nascondi elenco diapositive ([)",+ "Show properties (])": "Mostra proprietà (])",+ "Hide properties (])": "Nascondi proprietà (])",+ "More ways to save — copy, new deck, template": "Altri modi per salvare: copia, nuova presentazione, modello",+ "Save a copy": "Salva una copia",+ "Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.": "Scegli un nuovo file lasciando intatto questo: la copia di una presentazione condivisa si unisce alla stessa sessione dal vivo.",+ "Save as new deck…": "Salva come nuova presentazione…",+ "Same content, brand-new document — its own identity and keys; it will never sync with this one.": "Stesso contenuto, documento nuovo di zecca: identità e chiavi proprie; non si sincronizzerà mai con questo.",+ "slide {n}": "diapositiva {n}",+ "{name} joined": "{name} si è unito",+ "{name} left": "{name} se n'è andato",}diff --git a/slides/src/i18n/ja.ts b/slides/src/i18n/ja.tsindex 6073b5f3..5a03181c 100644--- a/slides/src/i18n/ja.ts+++ b/slides/src/i18n/ja.ts@@ -271,4 +271,16 @@ export const ja: Catalog = {"Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.": "テンプレートを保存します。開いた人はそれぞれ、独自の ID とキーを持つ独立した新しいデッキを取得します。","Template saved — every open of it starts a fresh deck": "テンプレートを保存しました — 開くたびに新しいデッキが始まります","Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends": "現在のスライドからプレゼン開始 — F で全画面切替、S で発表者ビュー、Esc で終了",+ "Show slide list ([)": "スライド一覧を表示([)",+ "Hide slide list ([)": "スライド一覧を隠す([)",+ "Show properties (])": "プロパティを表示(])",+ "Hide properties (])": "プロパティを隠す(])",+ "More ways to save — copy, new deck, template": "その他の保存方法 — コピー・新しいデッキ・テンプレート",+ "Save a copy": "コピーを保存",+ "Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.": "新しいファイルに保存し、元のファイルは変更しません — 共有中のデッキのコピーは同じライブセッションに参加します。",+ "Save as new deck…": "新しいデッキとして保存…",+ "Same content, brand-new document — its own identity and keys; it will never sync with this one.": "内容は同じ、まったく新しいドキュメント — 独自の ID とキーを持ち、このファイルと同期することはありません。",+ "slide {n}": "スライド {n}",+ "{name} joined": "{name} が参加しました",+ "{name} left": "{name} が退出しました",}diff --git a/slides/src/i18n/zh-Hans.ts b/slides/src/i18n/zh-Hans.tsindex 4270525b..c7081d87 100644--- a/slides/src/i18n/zh-Hans.ts+++ b/slides/src/i18n/zh-Hans.ts@@ -271,4 +271,16 @@ export const zhHans: Catalog = {"Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.": "保存为模板副本:每个打开它的人都会得到一份全新的独立演示文稿,拥有自己的标识和密钥。","Template saved — every open of it starts a fresh deck": "模板已保存 — 每次打开都会生成新的演示文稿","Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends": "从当前页开始演示 — F 切换全屏,S 打开演讲者视图,Esc 结束",+ "Show slide list ([)": "显示幻灯片列表([)",+ "Hide slide list ([)": "隐藏幻灯片列表([)",+ "Show properties (])": "显示属性面板(])",+ "Hide properties (])": "隐藏属性面板(])",+ "More ways to save — copy, new deck, template": "更多保存方式 — 副本、新演示文稿、模板",+ "Save a copy": "保存副本",+ "Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.": "保存为新文件,原文件保持不变 — 共享演示文稿的副本会加入同一实时会话。",+ "Save as new deck…": "另存为新演示文稿…",+ "Same content, brand-new document — its own identity and keys; it will never sync with this one.": "内容相同的全新文档 — 拥有自己的标识和密钥,永远不会与当前文档同步。",+ "slide {n}": "第 {n} 页",+ "{name} joined": "{name} 已加入",+ "{name} left": "{name} 已离开",}diff --git a/slides/src/i18n/zh-Hant.ts b/slides/src/i18n/zh-Hant.tsindex b39d57f9..987ac40f 100644--- a/slides/src/i18n/zh-Hant.ts+++ b/slides/src/i18n/zh-Hant.ts@@ -271,4 +271,16 @@ export const zhHant: Catalog = {"Saves a template copy: everyone who opens it gets a fresh, independent deck with its own identity and keys.": "儲存為範本副本:每個開啟它的人都會得到一份全新的獨立簡報,擁有自己的識別碼與金鑰。","Template saved — every open of it starts a fresh deck": "範本已儲存 — 每次開啟都會產生新的簡報","Present from current slide — F toggles fullscreen, S opens speaker view, Esc ends": "從目前頁面開始簡報 — F 切換全螢幕,S 開啟簡報者檢視,Esc 結束",+ "Show slide list ([)": "顯示投影片清單([)",+ "Hide slide list ([)": "隱藏投影片清單([)",+ "Show properties (])": "顯示屬性面板(])",+ "Hide properties (])": "隱藏屬性面板(])",+ "More ways to save — copy, new deck, template": "更多儲存方式 — 副本、新簡報、範本",+ "Save a copy": "儲存副本",+ "Pick a new file, leave this one untouched — a copy of a shared deck joins the same live session.": "儲存為新檔案,原檔案保持不變 — 共用簡報的副本會加入同一即時工作階段。",+ "Save as new deck…": "另存為新簡報…",+ "Same content, brand-new document — its own identity and keys; it will never sync with this one.": "內容相同的全新文件 — 擁有自己的識別碼與金鑰,永遠不會與目前文件同步。",+ "slide {n}": "第 {n} 頁",+ "{name} joined": "{name} 已加入",+ "{name} left": "{name} 已離開",}diff --git a/slides/src/styles.css b/slides/src/styles.cssindex 3c2e5c04..0bfbd38d 100644--- a/slides/src/styles.css+++ b/slides/src/styles.css@@ -906,9 +906,11 @@ html, body {.ed-resizer:hover, body.ed-col-resizing .ed-resizer { background: rgb(91 141 239 / 0.45); }body.ed-col-resizing { cursor: col-resize; user-select: none; }.ed-noanim { transition: none !important; }-/* no grab strip against a collapsed panel — the [ ] toggles reopen it */-.ed-sidebar.ed-collapsed + .ed-resizer { display: none; }-.ed-resizer:has(+ .ed-props.ed-collapsed) { display: none; }+/* against a collapsed panel the strip only carries the reopen chevron */+.ed-sidebar.ed-collapsed + .ed-resizer,+.ed-resizer:has(+ .ed-props.ed-collapsed) { cursor: default; }+.ed-sidebar.ed-collapsed + .ed-resizer:hover,+.ed-resizer:has(+ .ed-props.ed-collapsed):hover { background: transparent; }/* collapsible side panels */.ed-sidebar, .ed-props { transition: width .18s ease, padding .18s ease; }@@ -1072,7 +1074,38 @@ body.ed-col-resizing { cursor: col-resize; user-select: none; }color: #b8860b;}.ed-share-status.ok { color: #2e8b57; }-.ed-share-btn { justify-content: center; }+.ed-share-btn {+ justify-content: center;+ font-size: 12.5px;+ padding: 6px 10px;+ white-space: normal;+ text-align: center;+ line-height: 1.35;+}+.ed-share-peers { display: flex; flex-direction: column; gap: 2px; }+.ed-share-peer {+ display: flex;+ align-items: center;+ gap: 8px;+ padding: 4px 6px;+ border: none;+ background: none;+ border-radius: 6px;+ font-size: 12.5px;+ color: var(--ink);+ cursor: pointer;+ text-align: left;+ width: 100%;+}+.ed-share-peer:hover { background: rgba(94, 118, 153, 0.1); }+.ed-share-peer .dot {+ width: 10px;+ height: 10px;+ border-radius: 50%;+ flex: none;+}+.ed-share-peer .who { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }+.ed-share-peer .where { color: var(--muted, #5d6b80); font-size: 11.5px; flex: none; }.ed-btn-live { position: relative; }.ed-btn-live::after,.ed-btn-connecting::after {@@ -1115,16 +1148,63 @@ body.ed-col-resizing { cursor: col-resize; user-select: none; }font-size: 12.5px;}-/* --- responsive topbar: stays usable at any width ----------------------- */-/* narrow: button labels collapse to icons (tooltips still carry meaning) */-@media (max-width: 1280px) {- .ed-topbar .ed-btn > span { display: none; }+/* --- responsive topbar: labels give way, never a scrollbar ---------------- */+.ed-topbar { min-width: 0; }+.ed-topbar .ed-group { flex-shrink: 0; }+.ed-logo { flex-shrink: 0; }+.ed-title { flex: 0 1 220px; min-width: 48px; }+@media (max-width: 1200px) {+ .ed-topbar .ed-btn > span { display: none; } /* icons + tooltips take over */.ed-topbar .ed-btn.ed-btn-update > span { display: inline; } /* version chip is signal */.ed-topbar { gap: 6px; padding: 8px 8px; }- .ed-title { min-width: 60px; }}-/* very narrow: the bar itself scrolls sideways rather than clipping */-.ed-topbar { overflow-x: auto; overflow-y: hidden; scrollbar-width: thin; }-.ed-topbar::-webkit-scrollbar { height: 4px; }-.ed-topbar .ed-group { flex-shrink: 0; }-.ed-logo { flex-shrink: 0; }+@media (max-width: 760px) {+ .ed-topbar { gap: 4px; padding: 6px 6px; }+ .ed-logo > b { display: none; } /* mark only — the icon is the brand */+}++/* panel collapse chevrons live ON the resizer strips, not in the topbar */+.ed-resizer { position: relative; }+.ed-panel-toggle {+ position: absolute;+ top: 50%;+ left: 50%;+ transform: translate(-50%, -50%);+ width: 16px;+ height: 44px;+ border: 1px solid var(--line);+ border-radius: 8px;+ background: #fff;+ color: #5d6b80;+ font-size: 11px;+ line-height: 1;+ padding: 0;+ cursor: pointer;+ z-index: 15;+ display: flex;+ align-items: center;+ justify-content: center;+ box-shadow: 0 1px 4px rgba(20, 30, 45, 0.12);+}+.ed-panel-toggle:hover { color: var(--ink); border-color: #b9c3d2; }+.ed-save-menu {+ right: 0;+ left: auto;+ min-width: 190px;+}+.ed-save-menu .ed-btn { font-size: 12.5px; }+/* when the adjacent panel is collapsed the chevron pins fully on-screen,+ docked to the edge like a drawer pull */+.ed-sidebar.ed-collapsed + .ed-resizer .ed-panel-toggle {+ left: 0;+ transform: translateY(-50%);+ border-top-left-radius: 0;+ border-bottom-left-radius: 0;+}+.ed-resizer:has(+ .ed-props.ed-collapsed) .ed-panel-toggle {+ left: auto;+ right: 0;+ transform: translateY(-50%);+ border-top-right-radius: 0;+ border-bottom-right-radius: 0;+}