From dcbe7bbdd6f8c54f17f14951f309ead6fb4dbaa7 Mon Sep 17 00:00:00 2001 From: Oleg Isonen Date: Fri, 28 Feb 2025 16:53:08 +0000 Subject: [PATCH 1/2] copy recent properties as well when copy all --- .../builder/features/style-panel/sections/advanced/advanced.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx b/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx index 3f6575f435e0..2e3719331902 100644 --- a/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx +++ b/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx @@ -476,7 +476,7 @@ export const Section = () => { Date: Fri, 28 Feb 2025 17:21:48 +0000 Subject: [PATCH 2/2] focus previous style input after deleting --- .../features/style-panel/sections/advanced/advanced.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx b/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx index 2e3719331902..2b9d053e0993 100644 --- a/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx +++ b/apps/builder/app/builder/features/style-panel/sections/advanced/advanced.tsx @@ -451,7 +451,7 @@ export const Section = () => { setSearchProperties(matched as CssProperty[]); }; - const afterAddingStyles = () => { + const afterChangingStyles = () => { setIsAdding(false); requestAnimationFrame(() => { // We are either focusing the last value input from the recent list if available or the search input. @@ -502,6 +502,7 @@ export const Section = () => { (recentProperty) => recentProperty !== property ) ); + afterChangingStyles(); }} /> ); @@ -519,10 +520,10 @@ export const Section = () => { onSubmit={(cssText: string) => { const styles = handleInsertStyles(cssText); if (styles.size > 0) { - afterAddingStyles(); + afterChangingStyles(); } }} - onClose={afterAddingStyles} + onClose={afterChangingStyles} onFocus={() => { if (isAdding === false) { handleShowAddStyleInput();