@things-factory/ai-assistant 10.1.87 → 10.1.88

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"assistant-session-manager.js","sourceRoot":"","sources":["../../client/components/assistant-session-manager.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AAEnC,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAA4C,MAAM,KAAK,CAAA;AAC9F,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAElE,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAA;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAEzC,OAAO,EACL,qBAAqB,EACrB,cAAc,EAIf,MAAM,qCAAqC,CAAA;AAE5C,MAAM,IAAI,GAAG,EAAE,CAAA;AAGf,MAAM,CAAC,GAAG,CAAC,GAAW,EAAE,YAAoB,EAAE,UAAmC,EAAE,EAAE,EAAE,CACrF,OAAO,CAAC,CAAC,CAAC,wBAAwB,GAAG,EAAE,EAAE,EAAE,YAAY,EAAE,GAAG,OAAO,EAAE,CAAC,CAAA;AAExE;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEI,IAAM,uBAAuB,GAA7B,MAAM,uBAAwB,SAAQ,UAAU;IAAhD;;QAqQL,qGAAqG;QACzE,eAAU,GAAG,EAAE,CAAA;QACf,aAAQ,GAAG,EAAE,CAAA;QACzC,+DAA+D;QACnC,cAAS,GAAG,EAAE,CAAA;QACd,eAAU,GAAG,EAAE,CAAA;QAC3C,mEAAmE;QACnC,UAAK,GAA0B,qBAAqB,CAAA;QACpF,uFAAuF;QAC3D,SAAI,GAAG,EAAE,CAAA;QACrC,4EAA4E;QAC5C,eAAU,GAA2B,EAAE,CAAA;QAEtD,YAAO,GAA4B,EAAE,CAAA;QACrC,UAAK,GAAG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PropertyValues, type TemplateResult } from 'lit'\nimport { customElement, property, state } from 'lit/decorators.js'\n\nimport { i18next } from '@operato/i18n'\nimport { OxPrompt } from '@operato/popup'\n\nimport {\n assistantSessionAdmin,\n sessionActions,\n type AssistantSessionAdmin,\n type AssistantSessionEntry,\n type AssistantSessionFilters\n} from '../utils/assistant-session-admin.js'\n\nconst PAGE = 30\n\n\nconst t = (key: string, defaultValue: string, options: Record<string, unknown> = {}) =>\n i18next.t(`ai-assistant.session.${key}`, { defaultValue, ...options })\n\n/**\n * The conversations on one anchor, managed - `<ox-assistant-session-manager>`.\n *\n * Search, a filter (all / mine / including hidden), paging, and on each row: open, rename, hide or\n * unhide, private ⇄ public, delete. Taken from operato-twin's dock, where it was written first, so every\n * dock gets it by placing this element (typically behind the toolbar's \"All History\").\n *\n * ── What is the host's ──────────────────────────────────────────────────────────\n * Opening and starting a conversation belong to the dock's session controller, so this element asks\n * with the toolbar's own events and does not open anything itself:\n * assistant-session-select { sessionId } open that conversation\n * assistant-session-reset start a new one\n * assistant-session-changed { sessionId, change: 'renamed' | 'hidden' | 'unhidden' | 'removed' | 'visibility' }\n * a row changed - the host refreshes its tabs; if the open\n * conversation was removed or hidden, it moves off it\n *\n * ── What is the server's ────────────────────────────────────────────────────────\n * Who may do what (`sessionActions`): rename any participant, hide anyone for their own list, delete\n * the creator, visibility the owner. The buttons follow those hints; the doors decide again.\n *\n * ── Asking before what cannot be undone ─────────────────────────────────────────\n * Delete, and opening a private conversation to the domain, ask on the row itself - [Cancel][OK].\n * Making it private, hiding and renaming do not: each can be undone from the same row.\n */\n@customElement('ox-assistant-session-manager')\nexport class AssistantSessionManager extends LitElement {\n static styles = css`\n .scope-label { padding: 12px 12px 0; font-size: 14px; font-weight: 600; }\n .filter-toggle, .reset { margin: 6px 10px; padding: 7px; font: inherit; background: transparent; color: inherit; border: 1px solid var(--md-sys-color-outline-variant); border-radius: 6px; cursor: pointer; }\n .filter-toggle { align-self: flex-end; }\n .filters[hidden] { display: none; }\n .open-row { display: block; flex: 1; min-width: 0; text-align: start; border: 0; background: transparent; color: inherit; font: inherit; padding: 4px; cursor: pointer; }\n .meta { display: block; margin-top: 5px; font-size: 12px; color: var(--md-sys-color-on-surface-variant); }\n /* Open and private must part at a glance - an open row is read by everyone in the domain (2026-09-30). */\n .audience { display: inline-flex; align-items: center; gap: 3px; vertical-align: middle; }\n .audience md-icon { --md-icon-size: 14px; }\n .audience.open { padding: 1px 6px 1px 4px; border-radius: 6px; background: var(--md-sys-color-tertiary-container); color: var(--md-sys-color-on-tertiary-container); font-weight: 600; }\n .row.open-audience { box-shadow: inset 3px 0 0 var(--md-sys-color-tertiary); }\n .actions summary { cursor: pointer; padding: 8px; font-size: 18px; list-style: none; }\n .actions[open] .acts { display: flex; flex-direction: column; position: absolute; right: 10px; top: 40px; z-index: 2; min-width: 180px; padding: 6px; background: var(--md-sys-color-surface-container-lowest); border: 1px solid var(--md-sys-color-outline-variant); border-radius: 8px; box-shadow: 0 4px 16px #0002; }\n .actions button.icon { min-height: 40px; padding: 8px 12px; font: inherit; text-align: start; }\n .actions button.danger { color: var(--md-sys-color-error, #b42318); }\n button:focus-visible, summary:focus-visible { outline: 2px solid var(--md-sys-color-primary); outline-offset: 2px; }\n :host {\n display: flex;\n flex-direction: column;\n min-height: 0;\n font-size: 14px;\n color: var(--md-sys-color-on-surface);\n }\n\n .bar {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n }\n\n .bar input,\n .bar select {\n min-width: 0;\n height: 28px;\n box-sizing: border-box;\n border: 1px solid var(--md-sys-color-outline-variant);\n border-radius: 6px;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n font: inherit;\n padding: 0 8px;\n }\n\n .bar input {\n flex: 1;\n }\n\n .new {\n flex: none;\n border: 0;\n border-radius: 6px;\n padding: 4px 8px;\n background: transparent;\n color: var(--md-sys-color-primary);\n font: inherit;\n font-weight: 650;\n cursor: pointer;\n }\n\n .filters {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 6px 10px;\n padding: 6px 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n font-size: 11.5px;\n color: var(--md-sys-color-on-surface-variant);\n }\n\n .filters select {\n height: 26px;\n border: 1px solid var(--md-sys-color-outline-variant);\n border-radius: 6px;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n font: inherit;\n }\n\n .filters label {\n display: inline-flex;\n align-items: center;\n gap: 3px;\n cursor: pointer;\n }\n\n .kind {\n color: var(--md-sys-color-primary);\n }\n\n .list {\n flex: 1;\n min-height: 0;\n overflow: auto;\n }\n\n .row {\n position: relative;\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 9px 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n cursor: pointer;\n }\n\n .row:hover,\n .row.current {\n background: var(--md-sys-color-surface-container);\n }\n\n .row.hidden {\n opacity: 0.6;\n }\n\n .dot {\n flex: none;\n width: 7px;\n height: 7px;\n border-radius: 50%;\n }\n\n .row.unread .dot {\n background: var(--md-sys-color-primary);\n }\n\n .row md-icon {\n --md-icon-size: 16px;\n flex: none;\n color: var(--md-sys-color-on-surface-variant);\n }\n\n .body {\n flex: 1;\n min-width: 0;\n }\n\n .title,\n .prev {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .row.unread .title {\n font-weight: 700;\n }\n\n .prev {\n color: var(--md-sys-color-on-surface-variant);\n font-size: 11px;\n }\n\n /* Row actions show on hover and on keyboard focus - the list's body is the names. */\n .acts {\n display: none;\n gap: 2px;\n }\n\n button.icon {\n display: inline-flex;\n padding: 3px;\n border: 0;\n border-radius: 6px;\n background: none;\n color: var(--md-sys-color-on-surface-variant);\n cursor: pointer;\n }\n\n button.icon:hover {\n background: var(--md-sys-color-surface-container-high);\n color: var(--md-sys-color-on-surface);\n }\n\n button.icon.danger:hover {\n color: var(--md-sys-color-error);\n }\n\n .rename {\n flex: 1;\n min-width: 0;\n height: 26px;\n border: 1px solid var(--md-sys-color-primary);\n border-radius: 6px;\n padding: 0 6px;\n font: inherit;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n }\n\n .ask {\n display: grid;\n gap: 6px;\n padding: 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n background: var(--md-sys-color-surface-container);\n }\n\n .ask .buttons {\n display: flex;\n justify-content: flex-end;\n gap: 6px;\n }\n\n .ask button {\n border: 1px solid var(--md-sys-color-outline-variant);\n border-radius: 6px;\n padding: 4px 10px;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n font: inherit;\n cursor: pointer;\n }\n\n .ask button.ok {\n border-color: var(--md-sys-color-primary);\n background: var(--md-sys-color-primary);\n color: var(--md-sys-color-on-primary);\n }\n\n .ask button.ok.danger {\n border-color: var(--md-sys-color-error);\n background: var(--md-sys-color-error);\n color: var(--md-sys-color-on-error);\n }\n\n .note,\n .empty {\n padding: 14px 12px;\n color: var(--md-sys-color-on-surface-variant);\n }\n\n [role='alert'] {\n color: var(--md-sys-color-error);\n }\n\n .more,\n .hiddenfilter {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: 6px;\n width: 100%;\n padding: 8px;\n border: 0;\n border-top: 1px solid var(--md-sys-color-outline-variant);\n background: none;\n color: var(--md-sys-color-on-surface-variant);\n font: inherit;\n cursor: pointer;\n }\n\n .hiddenfilter md-icon {\n --md-icon-size: 16px;\n }\n `\n\n /** The anchor whose conversations are listed - the same one the dock's session controller opened. */\n @property({ type: String }) anchorType = ''\n @property({ type: String }) anchorId = ''\n /** The conversation the dock has open - marked in the list. */\n @property({ type: String }) sessionId = ''\n @property({ type: String }) scopeLabel = ''\n /** The doors. Replaceable for tests; a host normally leaves it. */\n @property({ attribute: false }) admin: AssistantSessionAdmin = assistantSessionAdmin\n /** The conversation kind (mode) open in the dock - the list's default scope (§2-6). */\n @property({ type: String }) kind = ''\n /** kind → the words people know it by (the modes' labels), for each row. */\n @property({ attribute: false }) kindLabels: Record<string, string> = {}\n\n @state() private entries: AssistantSessionEntry[] = []\n @state() private total = 0\n @state() private hiddenCount = 0\n @state() private search = ''\n @state() private allKinds = false\n @state() private whose: NonNullable<AssistantSessionFilters['whose']> = 'all'\n @state() private visibility: NonNullable<AssistantSessionFilters['visibility']> = 'all'\n @state() private includeHidden = false\n @state() private unreadOnly = false\n @state() private pageSize = PAGE\n @state() private loading = false\n @state() private error = ''\n @state() private renamingId = ''\n @state() private filtersOpen = false\n\n private get hasFilters() {\n return !!this.search.trim() || this.allKinds || this.whose !== 'all' || this.visibility !== 'all' || this.includeHidden || this.unreadOnly\n }\n\n private resetFilters() {\n clearTimeout(this.searchTimer)\n this.refilter(() => {\n this.search = ''\n this.allKinds = false\n this.whose = 'all'\n this.visibility = 'all'\n this.includeHidden = this.unreadOnly = false\n })\n }\n\n private generation = 0\n private searchTimer?: ReturnType<typeof setTimeout>\n\n /** Read the list again - the host calls this after it opened or started a conversation. */\n async reload(): Promise<void> {\n const generation = ++this.generation\n if (!this.anchorType || !this.anchorId) {\n this.entries = []\n this.total = this.hiddenCount = 0\n return\n }\n\n this.loading = true\n this.error = ''\n try {\n /*\n * Paging reads again from the start rather than appending - live activity reorders the list, and\n * appending a later page to an earlier order duplicates and drops rows.\n */\n const page = await this.admin.inbox({\n anchorType: this.anchorType,\n anchorId: this.anchorId,\n search: this.search,\n filters: {\n kind: this.allKinds ? '' : this.kind,\n whose: this.whose,\n visibility: this.visibility,\n includeHidden: this.includeHidden,\n unreadOnly: this.unreadOnly\n },\n limit: this.pageSize,\n offset: 0\n })\n if (generation !== this.generation) return\n this.entries = page.entries\n this.total = page.total\n this.hiddenCount = page.hiddenCount\n } catch (error) {\n if (generation !== this.generation) return\n this.entries = []\n this.total = this.hiddenCount = 0\n this.error = (error as Error).message || t('failed', 'could not load the conversation list.')\n } finally {\n if (generation === this.generation) this.loading = false\n }\n }\n\n protected updated(changed: PropertyValues) {\n if (changed.has('anchorType') || changed.has('anchorId') || changed.has('admin') || changed.has('kind')) void this.reload()\n\n /*\n * The rename box takes the keys the moment it opens, with the name selected. `autofocus` works once\n * per document, so the second rename opened a box that ignored the typing (2026-09-24, operato-ecs).\n */\n if (changed.has('renamingId') && this.renamingId) {\n const input = this.renderRoot.querySelector('input.rename') as HTMLInputElement | null\n input?.focus()\n input?.select()\n }\n }\n\n disconnectedCallback() {\n this.generation++\n clearTimeout(this.searchTimer)\n super.disconnectedCallback()\n }\n\n private emit(name: string, detail?: unknown) {\n this.dispatchEvent(new CustomEvent(name, { detail, bubbles: true, composed: true }))\n }\n\n /* ── what the person does ────────────────────────────────────────────────────────── */\n\n private onSearch(value: string) {\n this.search = value\n clearTimeout(this.searchTimer)\n /* Not on every keystroke. A new search starts from the first page. */\n this.searchTimer = setTimeout(() => {\n this.pageSize = PAGE\n void this.reload()\n }, 200)\n }\n\n /** A filter changed - the list starts from its first page again. */\n private refilter(change: () => void) {\n change()\n this.pageSize = PAGE\n void this.reload()\n }\n\n private loadMore() {\n this.pageSize += PAGE\n void this.reload()\n }\n\n /** Runs one door, then reads the list again - on success and on failure alike, so the row shows the truth. */\n private async act(entry: AssistantSessionEntry, change: string, run: () => Promise<boolean>, refused: string) {\n this.renamingId = ''\n try {\n if (!(await run())) this.error = refused\n else this.emit('assistant-session-changed', { sessionId: entry.id, change })\n } catch (error) {\n /* Never pass a failure silently - a person must not believe a conversation was deleted when it was not. */\n this.error = (error as Error).message\n }\n const error = this.error\n await this.reload()\n if (error && !this.error) this.error = error\n }\n\n private rename(entry: AssistantSessionEntry, name: string) {\n const trimmed = name.trim()\n this.renamingId = ''\n if (!trimmed || trimmed === entry.name) return\n void this.act(entry, 'renamed', () => this.admin.rename(entry.id, trimmed), t('rename-refused', 'this conversation could not be renamed.'))\n }\n\n private setHidden(entry: AssistantSessionEntry, hidden: boolean) {\n void this.act(entry, hidden ? 'hidden' : 'unhidden', () => this.admin.hide(entry.id, hidden), t('hide-refused', 'this conversation could not be hidden.'))\n }\n\n private setVisibility(entry: AssistantSessionEntry, visibility: 'open' | 'private') {\n void this.act(\n entry,\n 'visibility',\n () => this.admin.setVisibility(entry.id, visibility),\n t('visibility-refused', 'only the owner of this conversation can change who reads it.')\n )\n }\n\n private _removeSession(entry: AssistantSessionEntry) {\n void this.act(entry, 'removed', () => this.admin.remove(entry.id), t('remove-refused', 'this conversation could not be deleted.'))\n }\n\n /* ── drawing ─────────────────────────────────────────────────────────────────────── */\n\n render(): TemplateResult {\n const shown = this.entries.length\n\n return html`\n <div class=\"scope-label\">${this.scopeLabel}</div>\n <div class=\"bar\">\n <input\n .value=${this.search}\n placeholder=${t('search', 'Search conversations')}\n aria-label=${t('search', 'Search conversations')}\n @input=${(e: Event) => this.onSearch((e.target as HTMLInputElement).value)}\n @keydown=${(e: KeyboardEvent) => { if (e.key === 'Escape' && this.search) { e.stopPropagation(); this.onSearch('') } }}\n />\n <button class=\"new\" @click=${() => this.emit('assistant-session-reset')}>+ ${t('new', 'New conversation')}</button>\n </div>\n <button class=\"filter-toggle\" aria-expanded=${this.filtersOpen} @click=${() => (this.filtersOpen = !this.filtersOpen)}>${t('filters', 'Filters')}${this.hasFilters ? ' •' : ''}</button>\n <div class=\"filters\" ?hidden=${!this.filtersOpen}>\n ${this.kind\n ? html`<select aria-label=${t('filter-kind', 'Which kind')} .value=${this.allKinds ? 'all' : 'this'}\n @change=${(e: Event) => this.refilter(() => (this.allKinds = (e.target as HTMLSelectElement).value === 'all'))}>\n <option value=\"this\">${this.kindLabels[this.kind] || t('filter-this-kind', 'This conversation')}</option>\n <option value=\"all\">${t('filter-all-kinds', 'All kinds here')}</option>\n </select>`\n : nothing}\n <select aria-label=${t('filter-whose', 'Whose')} .value=${this.whose}\n @change=${(e: Event) => this.refilter(() => (this.whose = (e.target as HTMLSelectElement).value as any))}>\n <option value=\"all\">${t('filter-all', 'All')}</option>\n <option value=\"mine\">${t('filter-mine', 'Started by me')}</option>\n <option value=\"participant\">${t('filter-participant', \"I'm in\")}</option>\n </select>\n <select aria-label=${t('filter-visibility', 'Visibility')} .value=${this.visibility}\n @change=${(e: Event) => this.refilter(() => (this.visibility = (e.target as HTMLSelectElement).value as any))}>\n <option value=\"all\">${t('filter-any-visibility', 'Public and private')}</option>\n <option value=\"open\">${t('filter-open', 'Public')}</option>\n <option value=\"private\">${t('filter-private', 'Private')}</option>\n </select>\n <label><input type=\"checkbox\" .checked=${this.unreadOnly}\n @change=${(e: Event) => this.refilter(() => (this.unreadOnly = (e.target as HTMLInputElement).checked))} />${t('filter-unread', 'Unread')}</label>\n <label><input type=\"checkbox\" .checked=${this.includeHidden}\n @change=${(e: Event) => this.refilter(() => (this.includeHidden = (e.target as HTMLInputElement).checked))} />${t('filter-hidden', 'Including hidden')}</label>\n </div>\n ${this.hasFilters ? html`<button class=\"reset\" @click=${() => this.resetFilters()}>${t('reset-filters', 'Clear search and filters')}</button>` : nothing}\n <div class=\"list\">\n ${this.error ? html`<div class=\"note\" role=\"alert\">${this.error}</div>` : nothing}\n ${this.loading ? html`<div class=\"note\" role=\"status\">${t('loading', 'Loading conversations…')}</div>` : nothing}\n ${shown === 0 && !this.loading && !this.error\n ? html`<div class=\"empty\" role=\"status\">${this.hasFilters ? t('filtered-empty', 'No conversations match these filters here.') : t('scope-empty', 'No conversations for this subject yet.')}</div>`\n : this.entries.map(entry => this.renderRow(entry))}\n ${shown < this.total\n ? html`<button class=\"more\" @click=${() => this.loadMore()}>${t('load-more', 'Show more ({rest})', { rest: this.total - shown })}</button>`\n : nothing}\n </div>\n <!-- A hidden conversation must not be forgotten: say how many, and one press shows them. -->\n ${this.hiddenCount > 0 && !this.includeHidden\n ? html`<button class=\"hiddenfilter\" @click=${() => this.refilter(() => (this.includeHidden = true))}>\n <md-icon>visibility_off</md-icon>${t('hidden-count', '{count} hidden', { count: this.hiddenCount })}\n </button>`\n : nothing}\n `\n }\n\n private renderRow(entry: AssistantSessionEntry): TemplateResult {\n const name = entry.name || t('untitled', 'Untitled conversation')\n const actions = sessionActions(entry)\n const isPrivate = entry.visibility === 'private'\n\n if (this.renamingId === entry.id) {\n return html`<div class=\"row\">\n <span class=\"dot\"></span>\n <input\n class=\"rename\"\n .value=${entry.name || ''}\n aria-label=${t('rename', 'Rename')}\n @keydown=${(e: KeyboardEvent) => {\n if (e.key === 'Enter') this.rename(entry, (e.target as HTMLInputElement).value)\n if (e.key === 'Escape') { e.stopPropagation(); this.renamingId = '' }\n }}\n @blur=${(e: Event) => this.rename(entry, (e.target as HTMLInputElement).value)}\n />\n </div>`\n }\n\n return html`<div\n class=\"row ${entry.unread ? 'unread' : ''} ${entry.hidden ? 'hidden' : ''} ${entry.id === this.sessionId ? 'current' : ''} ${isPrivate ? '' : 'open-audience'}\"\n >\n <span class=\"dot\"></span>\n <button class=\"open-row\" aria-current=${entry.id === this.sessionId ? 'true' : 'false'} @click=${() => this.emit('assistant-session-select', { sessionId: entry.id, kind: entry.kind })}>\n <div class=\"title\">${name}</div>\n <div class=\"prev\">${this.allKinds && entry.kind ? html`<span class=\"kind\">${this.kindLabels[entry.kind] || entry.kind}</span> · ` : nothing}${entry.lastMessagePreview || ''}</div>\n <span class=\"meta\"><span class=\"audience ${isPrivate ? 'private' : 'open'}\"><md-icon aria-hidden=\"true\">${isPrivate ? 'lock' : 'public'}</md-icon>${isPrivate ? t('audience-private', 'Participants only') : t('audience-open', 'Everyone in this domain')}</span>${entry.lastMessageAt && Number.isFinite(Date.parse(entry.lastMessageAt)) ? html` · <time datetime=${entry.lastMessageAt}>${new Intl.DateTimeFormat(i18next.language || 'en', { month: 'short', day: 'numeric', hour: '2-digit', minute: '2-digit' }).format(new Date(entry.lastMessageAt))}</time>` : nothing}${entry.mine ? html` · ${t('filter-mine', 'Started by me')}` : nothing}</span>\n </button>\n <details class=\"actions\" @keydown=${(e: KeyboardEvent) => { if (e.key === 'Escape') { e.stopPropagation(); const details = e.currentTarget as HTMLDetailsElement; details.open = false; details.querySelector('summary')?.focus() } }}>\n <summary aria-label=${t('manage', 'Manage conversation')}>⋯</summary>\n <span class=\"acts\" @click=${(e: Event) => e.stopPropagation()}>\n ${actions.rename\n ? html`<button class=\"icon\" title=${t('rename', 'Rename')} aria-label=${t('rename', 'Rename')} @click=${() => (this.renamingId = entry.id)}>\n ${t('rename', 'Rename')}\n </button>`\n : nothing}\n ${actions.setVisibility\n ? isPrivate\n ? html`<button class=\"icon\" title=${t('make-open', 'Make public')} aria-label=${t('make-open', 'Make public')}\n @click=${() => this.askOpen(entry, name)}>${t('make-open', 'Make public')}</button>`\n : html`<button class=\"icon\" title=${t('make-private', 'Make private')} aria-label=${t('make-private', 'Make private')}\n @click=${() => this.setVisibility(entry, 'private')}>${t('make-private', 'Make private')}</button>`\n : nothing}\n <button\n class=\"icon\"\n title=${actions.unhide ? t('unhide', 'Show in my list') : t('hide', 'Hide from my list')}\n aria-label=${actions.unhide ? t('unhide', 'Show in my list') : t('hide', 'Hide from my list')}\n @click=${() => this.setHidden(entry, !entry.hidden)}\n >\n ${actions.unhide ? t('unhide', 'Show in my list') : t('hide', 'Hide from my list')}\n </button>\n ${actions.remove\n ? html`<button class=\"icon danger\" title=${t('remove', 'Delete')} aria-label=${t('remove', 'Delete')}\n @click=${() => this.askRemove(entry, name)}>${t('remove', 'Delete')}</button>`\n : nothing}\n </span>\n </details>\n </div>`\n }\n\n /** Before what cannot be taken back - the platform's confirm, [Cancel][OK] (decided 2026-09-25, §7-3). */\n private async ask(title: string, text: string, confirmText: string): Promise<boolean> {\n return !!(await OxPrompt.open({\n type: 'warning',\n title,\n text,\n confirmButton: { text: confirmText },\n cancelButton: { text: t('cancel', 'Cancel') }\n }))\n }\n\n private async askRemove(entry: AssistantSessionEntry, name: string) {\n const ok = await this.ask(\n t('remove', 'Delete'),\n t('confirm-remove', 'Delete \"{name}\"? It disappears for every participant and cannot be brought back.', { name }),\n t('remove', 'Delete')\n )\n if (ok) this._removeSession(entry)\n }\n\n private async askOpen(entry: AssistantSessionEntry, name: string) {\n const ok = await this.ask(\n t('make-open', 'Make public'),\n t('confirm-open', 'Make \"{name}\" public? Everyone in this domain will be able to read what is already written.', { name }),\n t('make-open', 'Make public')\n )\n if (ok) this.setVisibility(entry, 'open')\n }\n}\n"]}
1
+ {"version":3,"file":"assistant-session-manager.js","sourceRoot":"","sources":["../../client/components/assistant-session-manager.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AAEnC,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAA4C,MAAM,KAAK,CAAA;AAC9F,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAElE,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAA;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAEzC,OAAO,EACL,qBAAqB,EACrB,cAAc,EAIf,MAAM,qCAAqC,CAAA;AAE5C,MAAM,IAAI,GAAG,EAAE,CAAA;AAGf,MAAM,CAAC,GAAG,CAAC,GAAW,EAAE,YAAoB,EAAE,UAAmC,EAAE,EAAE,EAAE,CACrF,OAAO,CAAC,CAAC,CAAC,wBAAwB,GAAG,EAAE,EAAE,EAAE,YAAY,EAAE,GAAG,OAAO,EAAE,CAAC,CAAA;AAExE;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEI,IAAM,uBAAuB,GAA7B,MAAM,uBAAwB,SAAQ,UAAU;IAAhD;;QAuQL,qGAAqG;QACzE,eAAU,GAAG,EAAE,CAAA;QACf,aAAQ,GAAG,EAAE,CAAA;QACzC,+DAA+D;QACnC,cAAS,GAAG,EAAE,CAAA;QACd,eAAU,GAAG,EAAE,CAAA;QAC3C,mEAAmE;QACnC,UAAK,GAA0B,qBAAqB,CAAA;QACpF,uFAAuF;QAC3D,SAAI,GAAG,EAAE,CAAA;QACrC,4EAA4E;QAC5C,eAAU,GAA2B,EAAE,CAAA;QAEtD,YAAO,GAA4B,EAAE,CAAA;QACrC,UAAK,GAAG,CAAC,CAAA;Q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Result } from 'lit'\nimport { customElement, property, state } from 'lit/decorators.js'\n\nimport { i18next } from '@operato/i18n'\nimport { OxPrompt } from '@operato/popup'\n\nimport {\n assistantSessionAdmin,\n sessionActions,\n type AssistantSessionAdmin,\n type AssistantSessionEntry,\n type AssistantSessionFilters\n} from '../utils/assistant-session-admin.js'\n\nconst PAGE = 30\n\n\nconst t = (key: string, defaultValue: string, options: Record<string, unknown> = {}) =>\n i18next.t(`ai-assistant.session.${key}`, { defaultValue, ...options })\n\n/**\n * The conversations on one anchor, managed - `<ox-assistant-session-manager>`.\n *\n * Search, a filter (all / mine / including hidden), paging, and on each row: open, rename, hide or\n * unhide, private ⇄ public, delete. Taken from operato-twin's dock, where it was written first, so every\n * dock gets it by placing this element (typically behind the toolbar's \"All History\").\n *\n * ── What is the host's ──────────────────────────────────────────────────────────\n * Opening and starting a conversation belong to the dock's session controller, so this element asks\n * with the toolbar's own events and does not open anything itself:\n * assistant-session-select { sessionId } open that conversation\n * assistant-session-reset start a new one\n * assistant-session-changed { sessionId, change: 'renamed' | 'hidden' | 'unhidden' | 'removed' | 'visibility' }\n * a row changed - the host refreshes its tabs; if the open\n * conversation was removed or hidden, it moves off it\n *\n * ── What is the server's ────────────────────────────────────────────────────────\n * Who may do what (`sessionActions`): rename any participant, hide anyone for their own list, delete\n * the creator, visibility the owner. The buttons follow those hints; the doors decide again.\n *\n * ── Asking before what cannot be undone ─────────────────────────────────────────\n * Delete, and opening a private conversation to the domain, ask on the row itself - [Cancel][OK].\n * Making it private, hiding and renaming do not: each can be undone from the same row.\n */\n@customElement('ox-assistant-session-manager')\nexport class AssistantSessionManager extends LitElement {\n static styles = css`\n .scope-label { padding: 12px 12px 0; font-size: 14px; font-weight: 600; }\n .filter-toggle, .reset { margin: 6px 10px; padding: 7px; font: inherit; background: transparent; color: inherit; border: 1px solid var(--md-sys-color-outline-variant); border-radius: 6px; cursor: pointer; }\n .filter-toggle { align-self: flex-end; }\n .filters[hidden] { display: none; }\n .open-row { display: block; flex: 1; min-width: 0; text-align: start; border: 0; background: transparent; color: inherit; font: inherit; padding: 4px; cursor: pointer; }\n .meta { display: block; margin-top: 5px; font-size: 12px; color: var(--md-sys-color-on-surface-variant); }\n /* Open and private must part at a glance - an open row is read by everyone in the domain (2026-09-30). */\n .audience { display: inline-flex; align-items: center; gap: 3px; vertical-align: middle; }\n .audience md-icon { --md-icon-size: 14px; }\n /* The dock's warning colour, fixed across applications - see assistant-dock.ts. */\n :host { --assistant-open-edge: #c47f00; --assistant-open-surface: #f2b01e; --assistant-open-ink: #2e2100; }\n .audience.open { padding: 1px 6px 1px 4px; border-radius: 6px; background: var(--assistant-open-surface); color: var(--assistant-open-ink); font-weight: 600; }\n .row.open-audience { box-shadow: inset 4px 0 0 var(--assistant-open-edge); }\n .actions summary { cursor: pointer; padding: 8px; font-size: 18px; list-style: none; }\n .actions[open] .acts { display: flex; flex-direction: column; position: absolute; right: 10px; top: 40px; z-index: 2; min-width: 180px; padding: 6px; background: var(--md-sys-color-surface-container-lowest); border: 1px solid var(--md-sys-color-outline-variant); border-radius: 8px; box-shadow: 0 4px 16px #0002; }\n .actions button.icon { min-height: 40px; padding: 8px 12px; font: inherit; text-align: start; }\n .actions button.danger { color: var(--md-sys-color-error, #b42318); }\n button:focus-visible, summary:focus-visible { outline: 2px solid var(--md-sys-color-primary); outline-offset: 2px; }\n :host {\n display: flex;\n flex-direction: column;\n min-height: 0;\n font-size: 14px;\n color: var(--md-sys-color-on-surface);\n }\n\n .bar {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n }\n\n .bar input,\n .bar select {\n min-width: 0;\n height: 28px;\n box-sizing: border-box;\n border: 1px solid var(--md-sys-color-outline-variant);\n border-radius: 6px;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n font: inherit;\n padding: 0 8px;\n }\n\n .bar input {\n flex: 1;\n }\n\n .new {\n flex: none;\n border: 0;\n border-radius: 6px;\n padding: 4px 8px;\n background: transparent;\n color: var(--md-sys-color-primary);\n font: inherit;\n font-weight: 650;\n cursor: pointer;\n }\n\n .filters {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 6px 10px;\n padding: 6px 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n font-size: 11.5px;\n color: var(--md-sys-color-on-surface-variant);\n }\n\n .filters select {\n height: 26px;\n border: 1px solid var(--md-sys-color-outline-variant);\n border-radius: 6px;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n font: inherit;\n }\n\n .filters label {\n display: inline-flex;\n align-items: center;\n gap: 3px;\n cursor: pointer;\n }\n\n .kind {\n color: var(--md-sys-color-primary);\n }\n\n .list {\n flex: 1;\n min-height: 0;\n overflow: auto;\n }\n\n .row {\n position: relative;\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 9px 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n cursor: pointer;\n }\n\n .row:hover,\n .row.current {\n background: var(--md-sys-color-surface-container);\n }\n\n .row.hidden {\n opacity: 0.6;\n }\n\n .dot {\n flex: none;\n width: 7px;\n height: 7px;\n border-radius: 50%;\n }\n\n .row.unread .dot {\n background: var(--md-sys-color-primary);\n }\n\n .row md-icon {\n --md-icon-size: 16px;\n flex: none;\n color: var(--md-sys-color-on-surface-variant);\n }\n\n .body {\n flex: 1;\n min-width: 0;\n }\n\n .title,\n .prev {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .row.unread .title {\n font-weight: 700;\n }\n\n .prev {\n color: var(--md-sys-color-on-surface-variant);\n font-size: 11px;\n }\n\n /* Row actions show on hover and on keyboard focus - the list's body is the names. */\n .acts {\n display: none;\n gap: 2px;\n }\n\n button.icon {\n display: inline-flex;\n padding: 3px;\n border: 0;\n border-radius: 6px;\n background: none;\n color: var(--md-sys-color-on-surface-variant);\n cursor: pointer;\n }\n\n button.icon:hover {\n background: var(--md-sys-color-surface-container-high);\n color: var(--md-sys-color-on-surface);\n }\n\n button.icon.danger:hover {\n color: var(--md-sys-color-error);\n }\n\n .rename {\n flex: 1;\n min-width: 0;\n height: 26px;\n border: 1px solid var(--md-sys-color-primary);\n border-radius: 6px;\n padding: 0 6px;\n font: inherit;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n }\n\n .ask {\n display: grid;\n gap: 6px;\n padding: 10px;\n border-bottom: 1px solid var(--md-sys-color-outline-variant);\n background: var(--md-sys-color-surface-container);\n }\n\n .ask .buttons {\n display: flex;\n justify-content: flex-end;\n gap: 6px;\n }\n\n .ask button {\n border: 1px solid var(--md-sys-color-outline-variant);\n border-radius: 6px;\n padding: 4px 10px;\n background: var(--md-sys-color-surface-container-lowest);\n color: inherit;\n font: inherit;\n cursor: pointer;\n }\n\n .ask button.ok {\n border-color: var(--md-sys-color-primary);\n background: var(--md-sys-color-primary);\n color: var(--md-sys-color-on-primary);\n }\n\n .ask button.ok.danger {\n border-color: var(--md-sys-color-error);\n background: var(--md-sys-color-error);\n color: var(--md-sys-color-on-error);\n }\n\n .note,\n .empty {\n padding: 14px 12px;\n color: var(--md-sys-color-on-surface-variant);\n }\n\n [role='alert'] {\n color: var(--md-sys-color-error);\n }\n\n .more,\n .hiddenfilter {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: 6px;\n width: 100%;\n padding: 8px;\n border: 0;\n border-top: 1px solid var(--md-sys-color-outline-variant);\n background: none;\n color: var(--md-sys-color-on-surface-variant);\n font: inherit;\n cursor: pointer;\n }\n\n .hiddenfilter md-icon {\n --md-icon-size: 16px;\n }\n `\n\n /** The anchor whose conversations are listed - the same one the dock's session controller opened. */\n @property({ type: String }) anchorType = ''\n @property({ type: String }) anchorId = ''\n /** The conversation the dock has open - marked in the list. */\n @property({ type: String }) sessionId = ''\n @property({ type: String }) scopeLabel = ''\n /** The doors. Replaceable for tests; a host normally leaves it. */\n @property({ attribute: false }) admin: AssistantSessionAdmin = assistantSessionAdmin\n /** The conversation kind (mode) open in the dock - the list's default scope (§2-6). */\n @property({ type: String }) kind = ''\n /** kind → the words people know it by (the modes' labels), for each row. */\n @property({ attribute: false }) kindLabels: Record<string, string> = {}\n\n @state() private entries: AssistantSessionEntry[] = []\n @state() private total = 0\n @state() private hiddenCount = 0\n @state() private search = ''\n @state() private allKinds = false\n @state() private whose: NonNullable<AssistantSessionFilters['whose']> = 'all'\n @state() private visibility: NonNullable<AssistantSessionFilters['visibility']> = 'all'\n @state() private includeHidden = false\n @state() private unreadOnly = false\n @state() private pageSize = PAGE\n @state() private loading = false\n @state() private error = ''\n @state() private renamingId = ''\n @state() private filtersOpen = false\n\n private get hasFilters() {\n return !!this.search.trim() || this.allKinds || this.whose !== 'all' || this.visibility !== 'all' || this.includeHidden || this.unreadOnly\n }\n\n private resetFilters() {\n clearTimeout(this.searchTimer)\n this.refilter(() => {\n this.search = ''\n this.allKinds = false\n this.whose = 'all'\n this.visibility = 'all'\n this.includeHidden = this.unreadOnly = false\n })\n }\n\n private generation = 0\n private searchTimer?: ReturnType<typeof setTimeout>\n\n /** Read the list again - the host calls this after it opened or started a conversation. */\n async reload(): Promise<void> {\n const generation = ++this.generation\n if (!this.anchorType || !this.anchorId) {\n this.entries = []\n this.total = this.hiddenCount = 0\n return\n }\n\n this.loading = true\n this.error = ''\n try {\n /*\n * Paging reads again from the start rather than appending - live activity reorders the list, and\n * appending a later page to an earlier order duplicates and drops rows.\n */\n const page = await this.admin.inbox({\n anchorType: this.anchorType,\n anchorId: this.anchorId,\n search: this.search,\n filters: {\n kind: this.allKinds ? '' : this.kind,\n whose: this.whose,\n visibility: this.visibility,\n includeHidden: this.includeHidden,\n unreadOnly: this.unreadOnly\n },\n limit: this.pageSize,\n offset: 0\n })\n if (generation !== this.generation) return\n this.entries = page.entries\n this.total = page.total\n this.hiddenCount = page.hiddenCount\n } catch (error) {\n if (generation !== this.generation) return\n this.entries = []\n this.total = this.hiddenCount = 0\n this.error = (error as Error).message || t('failed', 'could not load the conversation list.')\n } finally {\n if (generation === this.generation) this.loading = false\n }\n }\n\n protected updated(changed: PropertyValues) {\n if (changed.has('anchorType') || changed.has('anchorId') || changed.has('admin') || changed.has('kind')) void this.reload()\n\n /*\n * The rename box takes the keys the moment it opens, with the name selected. `autofocus` works once\n * per document, so the second rename opened a box that ignored the typing (2026-09-24, operato-ecs).\n */\n if (changed.has('renamingId') && this.renamingId) {\n const input = this.renderRoot.querySelector('input.rename') as HTMLInputElement | null\n input?.focus()\n input?.select()\n }\n }\n\n disconnectedCallback() {\n this.generation++\n clearTimeout(this.searchTimer)\n super.disconnectedCallback()\n }\n\n private emit(name: string, detail?: unknown) {\n this.dispatchEvent(new CustomEvent(name, { detail, bubbles: true, composed: true }))\n }\n\n /* ── what the person does ────────────────────────────────────────────────────────── */\n\n private onSearch(value: string) {\n this.search = value\n clearTimeout(this.searchTimer)\n /* Not on every keystroke. A new search starts from the first page. */\n this.searchTimer = setTimeout(() => {\n this.pageSize = PAGE\n void this.reload()\n }, 200)\n }\n\n /** A filter changed - the list starts from its first page again. */\n private refilter(change: () => void) {\n change()\n this.pageSize = PAGE\n void this.reload()\n }\n\n private loadMore() {\n this.pageSize += PAGE\n void this.reload()\n }\n\n /** Runs one door, then reads the list again - on success and on failure alike, so the row shows the truth. */\n private async act(entry: AssistantSessionEntry, change: string, run: () => Promise<boolean>, refused: string) {\n this.renamingId = ''\n try {\n if (!(await run())) this.error = refused\n else this.emit('assistant-session-changed', { sessionId: entry.id, change })\n } catch (error) {\n /* Never pass a failure silently - a person must not believe a conversation was deleted when it was not. */\n this.error = (error as Error).message\n }\n const error = this.error\n await this.reload()\n if (error && !this.error) this.error = error\n }\n\n private rename(entry: AssistantSessionEntry, name: string) {\n const trimmed = name.trim()\n this.renamingId = ''\n if (!trimmed || trimmed === entry.name) return\n void this.act(entry, 'renamed', () => this.admin.rename(entry.id, trimmed), t('rename-refused', 'this conversation could not be renamed.'))\n }\n\n private setHidden(entry: AssistantSessionEntry, hidden: boolean) {\n void this.act(entry, hidden ? 'hidden' : 'unhidden', () => this.admin.hide(entry.id, hidden), t('hide-refused', 'this conversation could not be hidden.'))\n }\n\n private setVisibility(entry: AssistantSessionEntry, visibility: 'open' | 'private') {\n void this.act(\n entry,\n 'visibility',\n () => this.admin.setVisibility(entry.id, visibility),\n t('visibility-refused', 'only the owner of this conversation can change who reads it.')\n )\n }\n\n private _removeSession(entry: AssistantSessionEntry) {\n void this.act(entry, 'removed', () => this.admin.remove(entry.id), t('remove-refused', 'this conversation could not be deleted.'))\n }\n\n /* ── drawing ─────────────────────────────────────────────────────────────────────── */\n\n render(): TemplateResult {\n const shown = this.entries.length\n\n return html`\n <div class=\"scope-label\">${this.scopeLabel}</div>\n <div class=\"bar\">\n <input\n .value=${this.search}\n placeholder=${t('search', 'Search conversations')}\n aria-label=${t('search', 'Search conversations')}\n @input=${(e: Event) => this.onSearch((e.target as HTMLInputElement).value)}\n @keydown=${(e: KeyboardEvent) => { if (e.key === 'Escape' && this.search) { e.stopPropagation(); this.onSearch('') } }}\n />\n <button class=\"new\" @click=${() => this.emit('assistant-session-reset')}>+ ${t('new', 'New conversation')}</button>\n </div>\n <button class=\"filter-toggle\" aria-expanded=${this.filtersOpen} @click=${() => (this.filtersOpen = !this.filtersOpen)}>${t('filters', 'Filters')}${this.hasFilters ? ' •' : ''}</button>\n <div class=\"filters\" ?hidden=${!this.filtersOpen}>\n ${this.kind\n ? html`<select aria-label=${t('filter-kind', 'Which kind')} .value=${this.allKinds ? 'all' : 'this'}\n @change=${(e: Event) => this.refilter(() => (this.allKinds = (e.target as HTMLSelectElement).value === 'all'))}>\n <option value=\"this\">${this.kindLabels[this.kind] || t('filter-this-kind', 'This conversation')}</option>\n <option value=\"all\">${t('filter-all-kinds', 'All kinds here')}</option>\n </select>`\n : nothing}\n <select aria-label=${t('filter-whose', 'Whose')} .value=${this.whose}\n @change=${(e: Event) => this.refilter(() => (this.whose = (e.target as HTMLSelectElement).value as any))}>\n <option value=\"all\">${t('filter-all', 'All')}</option>\n <option value=\"mine\">${t('filter-mine', 'Started by me')}</option>\n <option value=\"participant\">${t('filter-participant', \"I'm in\")}</option>\n </select>\n <select aria-label=${t('filter-visibility', 'Visibility')} .value=${this.visibility}\n @change=${(e: Event) => this.refilter(() => (this.visibility = (e.target as HTMLSelectElement).value as any))}>\n <option value=\"all\">${t('filter-any-visibility', 'Public and private')}</option>\n <option value=\"open\">${t('filter-open', 'Public')}</option>\n <option value=\"private\">${t('filter-private', 'Private')}</option>\n </select>\n <label><input type=\"checkbox\" .checked=${this.unreadOnly}\n @change=${(e: Event) => this.refilter(() => (this.unreadOnly = (e.target as HTMLInputElement).checked))} />${t('filter-unread', 'Unread')}</label>\n <label><input type=\"checkbox\" .checked=${this.includeHidden}\n @change=${(e: Event) => this.refilter(() => (this.includeHidden = (e.target as HTMLInputElement).checked))} />${t('filter-hidden', 'Including hidden')}</label>\n </div>\n ${this.hasFilters ? html`<button class=\"reset\" @click=${() => this.resetFilters()}>${t('reset-filters', 'Clear search and filters')}</button>` : nothing}\n <div class=\"list\">\n ${this.error ? html`<div class=\"note\" role=\"alert\">${this.error}</div>` : nothing}\n ${this.loading ? html`<div class=\"note\" role=\"status\">${t('loading', 'Loading conversations…')}</div>` : nothing}\n ${shown === 0 && !this.loading && !this.error\n ? html`<div class=\"empty\" role=\"status\">${this.hasFilters ? t('filtered-empty', 'No conversations match these filters here.') : t('scope-empty', 'No conversations for this subject yet.')}</div>`\n : this.entries.map(entry => this.renderRow(entry))}\n ${shown < this.total\n ? html`<button class=\"more\" @click=${() => this.loadMore()}>${t('load-more', 'Show more ({rest})', { rest: this.total - shown })}</button>`\n : nothing}\n </div>\n <!-- A hidden conversation must not be forgotten: say how many, and one press shows them. -->\n ${this.hiddenCount > 0 && !this.includeHidden\n ? html`<button class=\"hiddenfilter\" @click=${() => this.refilter(() => (this.includeHidden = true))}>\n <md-icon>visibility_off</md-icon>${t('hidden-count', '{count} hidden', { count: this.hiddenCount })}\n </button>`\n : nothing}\n `\n }\n\n private renderRow(entry: AssistantSessionEntry): TemplateResult {\n const name = entry.name || t('untitled', 'Untitled conversation')\n const actions = sessionActions(entry)\n const isPrivate = entry.visibility === 'private'\n\n if (this.renamingId === entry.id) {\n return html`<div class=\"row\">\n <span class=\"dot\"></span>\n <input\n class=\"rename\"\n .value=${entry.name || ''}\n aria-label=${t('rename', 'Rename')}\n @keydown=${(e: KeyboardEvent) => {\n if (e.key === 'Enter') this.rename(entry, (e.target as HTMLInputElement).value)\n if (e.key === 'Escape') { e.stopPropagation(); this.renamingId = '' }\n }}\n @blur=${(e: Event) => this.rename(entry, (e.target as HTMLInputElement).value)}\n />\n </div>`\n }\n\n return html`<div\n class=\"row ${entry.unread ? 'unread' : ''} ${entry.hidden ? 'hidden' : ''} ${entry.id === this.sessionId ? 'current' : ''} ${isPrivate ? '' : 'open-audience'}\"\n >\n <span class=\"dot\"></span>\n <button class=\"open-row\" aria-current=${entry.id === this.sessionId ? 'true' : 'false'} @click=${() => this.emit('assistant-session-select', { sessionId: entry.id, kind: entry.kind })}>\n <div class=\"title\">${name}</div>\n <div class=\"prev\">${this.allKinds && entry.kind ? html`<span class=\"kind\">${this.kindLabels[entry.kind] || entry.kind}</span> · ` : nothing}${entry.lastMessagePreview || ''}</div>\n <span class=\"meta\"><span class=\"audience ${isPrivate ? 'private' : 'open'}\"><md-icon aria-hidden=\"true\">${isPrivate ? 'lock' : 'public'}</md-icon>${isPrivate ? t('audience-private', 'Participants only') : t('audience-open', 'Everyone in this domain')}</span>${entry.lastMessageAt && Number.isFinite(Date.parse(entry.lastMessageAt)) ? html` · <time datetime=${entry.lastMessageAt}>${new Intl.DateTimeFormat(i18next.language || 'en', { month: 'short', day: 'numeric', hour: '2-digit', minute: '2-digit' }).format(new Date(entry.lastMessageAt))}</time>` : nothing}${entry.mine ? html` · ${t('filter-mine', 'Started by me')}` : nothing}</span>\n </button>\n <details class=\"actions\" @keydown=${(e: KeyboardEvent) => { if (e.key === 'Escape') { e.stopPropagation(); const details = e.currentTarget as HTMLDetailsElement; details.open = false; details.querySelector('summary')?.focus() } }}>\n <summary aria-label=${t('manage', 'Manage conversation')}>⋯</summary>\n <span class=\"acts\" @click=${(e: Event) => e.stopPropagation()}>\n ${actions.rename\n ? html`<button class=\"icon\" title=${t('rename', 'Rename')} aria-label=${t('rename', 'Rename')} @click=${() => (this.renamingId = entry.id)}>\n ${t('rename', 'Rename')}\n </button>`\n : nothing}\n ${actions.setVisibility\n ? isPrivate\n ? html`<button class=\"icon\" title=${t('make-open', 'Make public')} aria-label=${t('make-open', 'Make public')}\n @click=${() => this.askOpen(entry, name)}>${t('make-open', 'Make public')}</button>`\n : html`<button class=\"icon\" title=${t('make-private', 'Make private')} aria-label=${t('make-private', 'Make private')}\n @click=${() => this.setVisibility(entry, 'private')}>${t('make-private', 'Make private')}</button>`\n : nothing}\n <button\n class=\"icon\"\n title=${actions.unhide ? t('unhide', 'Show in my list') : t('hide', 'Hide from my list')}\n aria-label=${actions.unhide ? t('unhide', 'Show in my list') : t('hide', 'Hide from my list')}\n @click=${() => this.setHidden(entry, !entry.hidden)}\n >\n ${actions.unhide ? t('unhide', 'Show in my list') : t('hide', 'Hide from my list')}\n </button>\n ${actions.remove\n ? html`<button class=\"icon danger\" title=${t('remove', 'Delete')} aria-label=${t('remove', 'Delete')}\n @click=${() => this.askRemove(entry, name)}>${t('remove', 'Delete')}</button>`\n : nothing}\n </span>\n </details>\n </div>`\n }\n\n /** Before what cannot be taken back - the platform's confirm, [Cancel][OK] (decided 2026-09-25, §7-3). */\n private async ask(title: string, text: string, confirmText: string): Promise<boolean> {\n return !!(await OxPrompt.open({\n type: 'warning',\n title,\n text,\n confirmButton: { text: confirmText },\n cancelButton: { text: t('cancel', 'Cancel') }\n }))\n }\n\n private async askRemove(entry: AssistantSessionEntry, name: string) {\n const ok = await this.ask(\n t('remove', 'Delete'),\n t('confirm-remove', 'Delete \"{name}\"? It disappears for every participant and cannot be brought back.', { name }),\n t('remove', 'Delete')\n )\n if (ok) this._removeSession(entry)\n }\n\n private async askOpen(entry: AssistantSessionEntry, name: string) {\n const ok = await this.ask(\n t('make-open', 'Make public'),\n t('confirm-open', 'Make \"{name}\" public? Everyone in this domain will be able to read what is already written.', { name }),\n t('make-open', 'Make public')\n )\n if (ok) this.setVisibility(entry, 'open')\n }\n}\n"]}