From 6fd264051af3a2ca3e496ea79a092bf08c811657 Mon Sep 17 00:00:00 2001 From: Aitor Moreno Date: Mon, 13 Apr 2026 14:43:52 +0200 Subject: [PATCH] :bug: Fix v2/v3 wrong styling --- frontend/src/app/main/data/workspace/texts.cljs | 3 ++- frontend/src/app/render_wasm/api.cljs | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/frontend/src/app/main/data/workspace/texts.cljs b/frontend/src/app/main/data/workspace/texts.cljs index 6ba7cc903b..dde3e88322 100644 --- a/frontend/src/app/main/data/workspace/texts.cljs +++ b/frontend/src/app/main/data/workspace/texts.cljs @@ -811,7 +811,8 @@ (rx/of (update-text-attrs {:id id :attrs attrs})) (rx/empty))) - (when (features/active-feature? state "text-editor/v2") + (when (and (features/active-feature? state "text-editor/v2") + (not (features/active-feature? state "text-editor-wasm/v1"))) (rx/of (v2-update-text-editor-styles id attrs))) (when (features/active-feature? state "render-wasm/v1") diff --git a/frontend/src/app/render_wasm/api.cljs b/frontend/src/app/render_wasm/api.cljs index 3d8fe0d0df..da5ce35e72 100644 --- a/frontend/src/app/render_wasm/api.cljs +++ b/frontend/src/app/render_wasm/api.cljs @@ -307,8 +307,9 @@ "Apply style attrs to the currently selected text spans. Updates the cached content, pushes to WASM, and returns {:shape-id :content} for saving." [attrs] - (text-editor/apply-styles-to-selection attrs use-shape set-shape-text-content) - (request-render "apply-styles-to-selection")) + (let [result (text-editor/apply-styles-to-selection attrs use-shape set-shape-text-content)] + (request-render "apply-styles-to-selection") + result)) (defn set-parent-id [id]