Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS
JavaScript ai-agentsdashboarddeveloper-toolsdigital-twinquantified-selfsecond-brainself-hostedtailscale
address review (claude, codex): preserve draft state and fix Drawer close label
[._.]/ Adam Eivy8b9014a3c7d8
diff --git a/.changelog/NEXT.md b/.changelog/NEXT.mdindex cf9800a684..0d7c1becc5 100644--- a/.changelog/NEXT.md+++ b/.changelog/NEXT.md@@ -40,7 +40,7 @@## UX & Accessibility-- **[issue-1853] Consolidated remaining hand-rolled overlays onto the shared `Modal`/`Drawer` components** — `ConversationViewer`, the digital-twin Documents tab's "create document" and "delete document" dialogs, and the CoS task "mark as blocked" dialog had their own bespoke `fixed inset-0` backdrop markup at inconsistent opacities (`bg-black/50` vs `bg-black/70`); they now render through `<Modal>`, picking up its standardized backdrop, Esc/click-outside handling, and stacking behavior for free. The calendar event-detail panel — a bespoke right-side slide-in that duplicated `Drawer`'s mobile-full-width/desktop-~520px/backdrop/Esc behavior — now renders through `<Drawer>` directly, and `Drawer`'s close button is bumped from 40px to the project's 44px minimum touch target (#1850) so the conversion doesn't regress that fix; the bump applies to every `Drawer` consumer. (#1853)+- **[issue-1853] Consolidated remaining hand-rolled overlays onto the shared `Modal`/`Drawer` components** — `ConversationViewer`, the digital-twin Documents tab's "create document" and "delete document" dialogs, and the CoS task "mark as blocked" dialog had their own bespoke `fixed inset-0` backdrop markup at inconsistent opacities (`bg-black/50` vs `bg-black/70`); they now render through `<Modal>`, picking up its standardized backdrop, Esc/click-outside handling, and stacking behavior for free. The "create document" dialog opts out of backdrop/Esc dismissal (`closeOnBackdrop`/`closeOnEsc={false}`) so an accidental outside click can't silently discard a typed draft, matching its pre-conversion behavior. The calendar event-detail panel — a bespoke right-side slide-in that duplicated `Drawer`'s mobile-full-width/desktop-~520px/backdrop/Esc behavior — now renders through `<Drawer>` directly; `Drawer` gains an optional `closeLabel` prop (default unchanged, `"Close settings"`) so the event panel's close button keeps its own accessible name instead of inheriting Drawer's settings-flavored one, and `Drawer`'s close button is bumped from 40px to the project's 44px minimum touch target (#1850) so the conversion doesn't regress that fix — the bump applies to every `Drawer` consumer. (#1853)- **[issue-1850] Calendar and message action buttons now meet the 44px minimum touch-target size** — the day/week/month calendar nav chevrons, the event-detail close button, and the message-detail action row (Reply / Voice / AI Reply / Refresh / Archive / Delete) previously rendered at ~28–31px, below the WCAG 2.5.5 / Apple HIG 44px minimum and awkward to tap on mobile. Each now enforces `min-w-[44px] min-h-[44px]` with centered icons, matching the shared `Drawer` close-button pattern, without changing the visual layout. (#1850)## Internaldiff --git a/client/src/components/Drawer.jsx b/client/src/components/Drawer.jsxindex b756ae67f5..573362dd14 100644--- a/client/src/components/Drawer.jsx+++ b/client/src/components/Drawer.jsx@@ -16,7 +16,8 @@ export default function Drawer({children,widthClass = 'sm:w-[520px]',closeOnEsc = true,- closeOnBackdrop = true+ closeOnBackdrop = true,+ closeLabel = 'Close settings'}) {useScrollLock(open);@@ -48,7 +49,7 @@ export default function Drawer({type="button"onClick={onClose}className="p-2 rounded-lg text-gray-400 hover:text-white hover:bg-port-border/50 min-h-[44px] min-w-[44px] flex items-center justify-center"- aria-label="Close settings"+ aria-label={closeLabel}><X className="w-5 h-5" /></button>diff --git a/client/src/components/calendar/EventDetail.jsx b/client/src/components/calendar/EventDetail.jsxindex 0d01ed05b0..50a47ab259 100644--- a/client/src/components/calendar/EventDetail.jsx+++ b/client/src/components/calendar/EventDetail.jsx@@ -11,7 +11,7 @@ const RSVP_STYLES = {export default function EventDetail({ event, onClose }) {return (- <Drawer open onClose={onClose} title={event.title}>+ <Drawer open onClose={onClose} title={event.title} closeLabel="Close"><div className="space-y-4">{/* Time */}<div className="flex items-start gap-3">diff --git a/client/src/components/calendar/EventDetail.test.jsx b/client/src/components/calendar/EventDetail.test.jsxindex 2cbc73efcd..7fbc80f99d 100644--- a/client/src/components/calendar/EventDetail.test.jsx+++ b/client/src/components/calendar/EventDetail.test.jsx@@ -13,7 +13,7 @@ const baseEvent = {describe('EventDetail', () => {it('renders a close button that meets the 44px minimum touch target', () => {render(<EventDetail event={baseEvent} onClose={() => {}} />);- const closeBtn = screen.getByRole('button', { name: 'Close settings' });+ const closeBtn = screen.getByRole('button', { name: 'Close' });expect(closeBtn.className).toContain('min-w-[44px]');expect(closeBtn.className).toContain('min-h-[44px]');// icon stays visually centered@@ -24,7 +24,7 @@ describe('EventDetail', () => {it('invokes onClose when the close button is clicked', () => {const onClose = vi.fn();render(<EventDetail event={baseEvent} onClose={onClose} />);- fireEvent.click(screen.getByRole('button', { name: 'Close settings' }));+ fireEvent.click(screen.getByRole('button', { name: 'Close' }));expect(onClose).toHaveBeenCalledTimes(1);});});diff --git a/client/src/components/cos/tabs/TaskItem.jsx b/client/src/components/cos/tabs/TaskItem.jsxindex ab8ce7bbfb..9e5d5f6cd2 100644--- a/client/src/components/cos/tabs/TaskItem.jsx+++ b/client/src/components/cos/tabs/TaskItem.jsx@@ -472,7 +472,6 @@ export default function TaskItem({ task, isSystem, awaitingApproval, onRefresh,onChange={e => setBlockedReason(e.target.value)}onKeyDown={e => {if (e.key === 'Enter') handleConfirmBlocked();- if (e.key === 'Escape') setShowBlockedModal(false);}}placeholder="e.g., Waiting for API access, Needs design review..."className="w-full px-3 py-2 bg-port-bg border border-port-border rounded-lg text-white text-sm mb-4"diff --git a/client/src/components/digital-twin/tabs/DocumentsTab.jsx b/client/src/components/digital-twin/tabs/DocumentsTab.jsxindex 94fd2f7c3c..7ab79ce2af 100644--- a/client/src/components/digital-twin/tabs/DocumentsTab.jsx+++ b/client/src/components/digital-twin/tabs/DocumentsTab.jsx@@ -306,13 +306,18 @@ export default function DocumentsTab({ onRefresh }) {)}</div>- {/* Create Document Modal */}+ {/* Create Document Modal — closeOnBackdrop/closeOnEsc disabled so an+ accidental outside click or Escape can't silently discard a typed+ draft; matches the pre-Modal markup, which had no backdrop-click or+ Escape dismissal at all (only the explicit Cancel/Create buttons). */}<Modalopen={showCreate}onClose={() => {setShowCreate(false);setNewDoc({ filename: '', title: '', category: 'core', content: '' });}}+ closeOnBackdrop={false}+ closeOnEsc={false}ariaLabel="Create Soul Document"panelClassName="bg-port-card rounded-lg border border-port-border p-4 sm:p-6 max-h-[90vh] overflow-y-auto">