Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

fix[mobile]: mobile dock (#862)

Peter Chinmanb1ad0aa4641b
diff --git a/js/app/packages/app/component/mobile/MobileDock.tsx b/js/app/packages/app/component/mobile/MobileDock.tsx
index c65ee1fee2..0efdd7f929 100644
--- a/js/app/packages/app/component/mobile/MobileDock.tsx
+++ b/js/app/packages/app/component/mobile/MobileDock.tsx
@@ -35,6 +35,12 @@ export function MobileDock() {
const splitContext = useSplitPanelOrThrow();
const { selectedView, setSelectedView } = splitContext.unifiedListContext;
+ const ensureUnifiedList = () => {
+ const content = splitContext.handle.content();
+ if (content.type === 'component' && content.id === 'unified-list') return;
+ splitContext.handle.replace({ type: 'component', id: 'unified-list' });
+ };
+
const focusSearchInput = (viewId: string) => {
setTimeout(() => {
const el = document.getElementById(
@@ -55,6 +61,7 @@ export function MobileDock() {
label="Search"
active={selectedView() === VIEWCONFIG_DEFAULTS_IDS_ENUM.all}
onClick={() => {
+ ensureUnifiedList();
setSelectedView(VIEWCONFIG_DEFAULTS_IDS_ENUM.all);
focusSearchInput(VIEWCONFIG_DEFAULTS_IDS_ENUM.all);
}}
@@ -64,6 +71,7 @@ export function MobileDock() {
label="Inbox"
active={selectedView() === VIEWCONFIG_DEFAULTS_IDS_ENUM.signal}
onClick={() => {
+ ensureUnifiedList();
setSelectedView(VIEWCONFIG_DEFAULTS_IDS_ENUM.signal);
}}
/>
@@ -72,6 +80,7 @@ export function MobileDock() {
label="People"
active={selectedView() === VIEWCONFIG_DEFAULTS_IDS_ENUM.people}
onClick={() => {
+ ensureUnifiedList();
setSelectedView(VIEWCONFIG_DEFAULTS_IDS_ENUM.people);
}}
/>
@@ -80,6 +89,7 @@ export function MobileDock() {
label="Tasks"
active={selectedView() === VIEWCONFIG_DEFAULTS_IDS_ENUM.tasks}
onClick={() => {
+ ensureUnifiedList();
setSelectedView(VIEWCONFIG_DEFAULTS_IDS_ENUM.tasks);
}}
/>
diff --git a/js/app/packages/app/index.html b/js/app/packages/app/index.html
index bfa57e689f..b680367d5d 100644
--- a/js/app/packages/app/index.html
+++ b/js/app/packages/app/index.html
@@ -36,7 +36,7 @@
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
- <div id="root" class="h-full touch:h-screen"></div>
+ <div id="root" class="h-dvh"></div>
<div id="modal" class="z-modal"></div>
<!--
Entrypoint
diff --git a/js/app/tauri/src-tauri/README.md b/js/app/tauri/src-tauri/README.md
index 13a8bf4447..e1ea4e1d56 100644
--- a/js/app/tauri/src-tauri/README.md
+++ b/js/app/tauri/src-tauri/README.md
@@ -41,7 +41,7 @@ cargo tauri ios build
cargo tauri android build
```
-The `beforeBuildCommand` is `bun run build:tauri`, which uses the same
+The `beforeBuildCommand` is `just build-tauri`, which uses the same
`TAURI_ENV_PLATFORM` switch to pick the right Vite entrypoint and emit the
frontend into `packages/app/dist`. Tauri then packages that output according to
`tauri.conf.json`.
diff --git a/js/app/tauri/src-tauri/tauri.conf.json b/js/app/tauri/src-tauri/tauri.conf.json
index 96d40326e5..24772da0b1 100644
--- a/js/app/tauri/src-tauri/tauri.conf.json
+++ b/js/app/tauri/src-tauri/tauri.conf.json
@@ -6,8 +6,8 @@
"build": {
"frontendDist": "../../packages/app/dist",
"devUrl": "http://localhost:3000",
- "beforeDevCommand": { "script": "bun run dev:tauri", "cwd": "../.." },
- "beforeBuildCommand": { "script": "bun run build:tauri", "cwd": "../.." }
+ "beforeDevCommand": { "script": "just dev-tauri", "cwd": "../.." },
+ "beforeBuildCommand": { "script": "just build-tauri", "cwd": "../.." }
},
"app": {
"windows": [
@@ -73,4 +73,4 @@
}
}
}
-}
\ No newline at end of file
+}