Skip to content

Commit 4043ca2

Browse files
authored
Disable synchronize button for observers (#1741)
1 parent abcc01a commit 4043ca2

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

frontend/viewer/src/project/SyncDialog.svelte

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,10 @@
1515
import { fade } from 'svelte/transition';
1616
import { delay } from '$lib/utils/time';
1717
import { cn } from '$lib/utils';
18+
import {useFeatures} from '$lib/services/feature-service';
1819
1920
const service = useSyncStatusService();
21+
const features = useFeatures();
2022
let remoteStatus: IProjectSyncStatus | undefined = $state();
2123
let localStatus: ISyncResult | undefined = $state();
2224
let server: ILexboxServer | undefined = $state();
@@ -206,7 +208,7 @@
206208
<div class="content-center text-center">
207209
<Button
208210
loading={loadingSyncLexboxToFlex}
209-
disabled={loadingSyncLexboxToLocal}
211+
disabled={loadingSyncLexboxToLocal || !features.write}
210212
onclick={syncLexboxToFlex}
211213
icon="i-mdi-sync"
212214
iconProps={{ class: 'size-5' }}>

0 commit comments

Comments
 (0)