Skip to content

Commit 27406cf

Browse files
committed
chore: generate
1 parent 0596b02 commit 27406cf

2 files changed

Lines changed: 17 additions & 19 deletions

File tree

packages/app/src/pages/layout.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1614,9 +1614,7 @@ export default function Layout(props: ParentProps) {
16141614
</Collapsible.Trigger>
16151615
}
16161616
>
1617-
<div class="flex items-center justify-between w-full pl-2 pr-16 py-1.5 rounded-md">
1618-
{header()}
1619-
</div>
1617+
<div class="flex items-center justify-between w-full pl-2 pr-16 py-1.5 rounded-md">{header()}</div>
16201618
</Show>
16211619
<div
16221620
class="absolute right-1 top-1/2 -translate-y-1/2 flex items-center gap-0.5 transition-opacity"

packages/desktop/src/index.tsx

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -89,27 +89,27 @@ const createPlatform = (password: Accessor<string | null>): Platform => ({
8989
length(): Promise<number>
9090
}
9191

92-
const WRITE_DEBOUNCE_MS = 250
92+
const WRITE_DEBOUNCE_MS = 250
9393

94-
const storeCache = new Map<string, Promise<StoreLike>>()
95-
const apiCache = new Map<string, AsyncStorage & { flush: () => Promise<void> }>()
96-
const memoryCache = new Map<string, StoreLike>()
94+
const storeCache = new Map<string, Promise<StoreLike>>()
95+
const apiCache = new Map<string, AsyncStorage & { flush: () => Promise<void> }>()
96+
const memoryCache = new Map<string, StoreLike>()
9797

98-
const flushAll = async () => {
99-
const apis = Array.from(apiCache.values())
100-
await Promise.all(apis.map((api) => api.flush().catch(() => undefined)))
101-
}
102-
103-
if ("addEventListener" in globalThis) {
104-
const handleVisibility = () => {
105-
if (document.visibilityState !== "hidden") return
106-
void flushAll()
107-
}
98+
const flushAll = async () => {
99+
const apis = Array.from(apiCache.values())
100+
await Promise.all(apis.map((api) => api.flush().catch(() => undefined)))
101+
}
108102

109-
window.addEventListener("pagehide", () => void flushAll())
110-
document.addEventListener("visibilitychange", handleVisibility)
103+
if ("addEventListener" in globalThis) {
104+
const handleVisibility = () => {
105+
if (document.visibilityState !== "hidden") return
106+
void flushAll()
111107
}
112108

109+
window.addEventListener("pagehide", () => void flushAll())
110+
document.addEventListener("visibilitychange", handleVisibility)
111+
}
112+
113113
const createMemoryStore = () => {
114114
const data = new Map<string, string>()
115115
const store: StoreLike = {

0 commit comments

Comments
 (0)