From a616adf69aae6f7cc16c999d5123a8ed0b642ec1 Mon Sep 17 00:00:00 2001 From: Bogdan Chadkin Date: Sat, 2 Aug 2025 21:32:22 +0200 Subject: [PATCH] fix: let user type "auto" into duration input --- .../props-section/animation/animation-panel-content.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/apps/builder/app/builder/features/settings-panel/props-section/animation/animation-panel-content.tsx b/apps/builder/app/builder/features/settings-panel/props-section/animation/animation-panel-content.tsx index 606f2123b078..bb14e767ff8b 100644 --- a/apps/builder/app/builder/features/settings-panel/props-section/animation/animation-panel-content.tsx +++ b/apps/builder/app/builder/features/settings-panel/props-section/animation/animation-panel-content.tsx @@ -262,6 +262,12 @@ const DurationInput = ({ onChangeComplete={(event) => { const value = durationUnitValueSchema.safeParse(event.value); onChange(undefined, true); + // allow user to reset with initial value + if (toValue(event.value).toLowerCase() === "auto") { + onChange(undefined, false); + setIntermediateValue(undefined); + return; + } if (value.success) { onChange(value.data, false); setIntermediateValue(undefined);