Skip to content

AI-native design editor. Open-source Figma alternative.

fix(effects): keep undo snapshots free of Vue proxies

Danila Poyarkov964d25215b99
diff --git a/packages/vue/src/controls/effects/use.ts b/packages/vue/src/controls/effects/use.ts
index d38db744e..159852f47 100644
--- a/packages/vue/src/controls/effects/use.ts
+++ b/packages/vue/src/controls/effects/use.ts
@@ -1,4 +1,4 @@
-import { ref } from 'vue'
+import { ref, shallowRef } from 'vue'
import {
EFFECT_OPTIONS,
@@ -20,7 +20,7 @@ export function useEffectsControls() {
const editor = useEditor()
const expandedIndex = ref<number | null>(null)
- const effectsBeforeScrub = ref<EffectEditSnapshot | null>(null)
+ const effectsBeforeScrub = shallowRef<EffectEditSnapshot | null>(null)
const editActions = createEffectEditActions(editor, effectsBeforeScrub)
const controlActions = createEffectControlActions(expandedIndex)