diff --git a/public/icons.ts b/public/icons.ts index d5e63ca..d2d9012 100644 --- a/public/icons.ts +++ b/public/icons.ts @@ -43,3 +43,6 @@ export const ICON_HISTORY = lineIcon(' ') export const ICON_SHARE = lineIcon(' ') export const ICON_DEVICE = lineIcon(' ') + +export const ICON_BELL = lineIcon(' ') +export const ICON_TIMELINE = lineIcon(' ') diff --git a/public/push.ts b/public/push.ts index 8b724bd..e55109c 100644 --- a/public/push.ts +++ b/public/push.ts @@ -16,6 +16,8 @@ * (NOTIFY_DND env). They are independent. */ +import { ICON_BELL } from './icons.js' + /* ── Types ─────────────────────────────────────────────────────────────────── */ /** All possible push-readiness states. Drives UI rendering in mountPushToggle. */ @@ -297,7 +299,8 @@ function renderPushToggle( function renderDisabled(container: HTMLElement, ariaLabel: string, hint: string): void { const wrap = el('span', 'push-toggle-disabled') - const bell = el('span', 'push-bell push-bell-off', '🔔') + const bell = el('span', 'push-bell push-bell-off') + bell.innerHTML = ICON_BELL bell.setAttribute('aria-label', ariaLabel) const hintEl = el('span', 'push-hint', hint) wrap.append(bell, hintEl) @@ -313,8 +316,9 @@ function renderToggleButton( const btn = el( 'button', isSubscribed ? 'push-toggle-btn push-toggle-on' : 'push-toggle-btn push-toggle-off', - isSubscribed ? '🔔 On' : '🔔 Off', ) + btn.innerHTML = ICON_BELL + btn.append(' ' + (isSubscribed ? 'On' : 'Off')) btn.title = isSubscribed ? 'Click to disable push notifications' : 'Click to enable push notifications' diff --git a/public/tabs.ts b/public/tabs.ts index 05333d7..edb3142 100644 --- a/public/tabs.ts +++ b/public/tabs.ts @@ -22,6 +22,7 @@ */ import { TerminalSession } from './terminal-session.js' +import { ICON_TIMELINE } from './icons.js' import { THEMES, DEFAULT_SETTINGS, type Settings } from './settings.js' import { mountLauncher, type Launcher } from './launcher.js' import { mountProjects, type ProjectsPanel } from './projects.js' @@ -853,7 +854,7 @@ export class TabApp { // survive tabBar.replaceChildren() (the bell's subtree is mounted once). const tl = document.createElement('button') tl.className = 'tab-timeline' - tl.textContent = '📜' + tl.innerHTML = ICON_TIMELINE tl.title = 'Activity timeline' tl.setAttribute('aria-label', 'Activity timeline') tl.classList.toggle('active', this.timelineOpen)