4509a2b6d3
- P5-41/35 useTauriToastActions: native rich-toast click → navigate(path) (opens the room), quick reply → mx.sendMessage(roomId, m.text). The desktop bridge routes message notifications (tag=roomId) to show_rich_toast. - P5-56 useTauriFocusAssist + focusAssistActiveAtom: a native focus-assist-changed event drives the atom, OR'd into the existing quiet-hours gate in ClientNonUIFeatures so notifications+sounds suppress during Windows Focus Assist. - P5-48 recursive folder drag-drop: fileEntries.ts (sync webkitGetAsEntry capture → async batched readEntries traversal, path-prefixed names, 500-file cap) wired into useFileDrop, reusing the existing upload pipeline. +3 unit tests. Hooks no-op in the browser. Gates: tsc/eslint/prettier clean, build OK, 559 tests. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
26 lines
1.3 KiB
TypeScript
26 lines
1.3 KiB
TypeScript
import { useTauriCallPower } from '../hooks/useTauriCallPower';
|
|
import { useTauriJumpList } from '../hooks/useTauriJumpList';
|
|
import { useTauriThumbbar } from '../hooks/useTauriThumbbar';
|
|
import { useTauriSmtc } from '../hooks/useTauriSmtc';
|
|
import { useTauriNetwork } from '../hooks/useTauriNetwork';
|
|
import { useTauriToastActions } from '../hooks/useTauriToastActions';
|
|
import { useTauriFocusAssist } from '../hooks/useTauriFocusAssist';
|
|
|
|
/**
|
|
* Mounts the client-scoped native desktop feature hooks (call/room aware). Each
|
|
* `useTauri*` hook no-ops in the browser (guards on `isTauri`), so this is safe
|
|
* to render unconditionally. Rendered once by `ClientNonUIFeatures`. App-level
|
|
* desktop features (window chrome) live in `App.tsx` instead, so they work
|
|
* before login.
|
|
*/
|
|
export function TauriDesktopFeatures(): null {
|
|
useTauriCallPower(); // P5-46 no-sleep during calls
|
|
useTauriJumpList(); // P5-36 Windows jump list of recent rooms
|
|
useTauriThumbbar(); // P5-44 taskbar thumbnail toolbar (mute/deafen/end)
|
|
useTauriSmtc(); // P5-43 system media transport controls
|
|
useTauriNetwork(); // P5-49 network-change awareness → sync retry
|
|
useTauriToastActions(); // P5-41/35 rich toast click → open room, quick reply → send
|
|
useTauriFocusAssist(); // P5-56 Windows Focus Assist → DND suppression atom
|
|
return null;
|
|
}
|