🐛 Fix frame inner strokes ignoring focus mode in wasm renderer

This commit is contained in:
Alejandro Alonso 2026-06-10 09:36:28 +02:00 committed by GitHub
parent e0a44eede0
commit becba0a82b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2584,8 +2584,11 @@ impl RenderState {
// Strokes are drawn over children for clipped frames (all strokes), and for non-clipped
// frames with inner strokes (inner strokes only — non-inner were rendered before children).
let needs_exit_strokes = element.clip()
|| (matches!(element.shape_type, Type::Frame(_)) && element.has_inner_stroke());
// Skip when focus mode excludes this subtree (focus_mode.exit runs after this, so
// is_active() still reflects this element's focus state here).
let needs_exit_strokes = self.focus_mode.is_active()
&& (element.clip()
|| (matches!(element.shape_type, Type::Frame(_)) && element.has_inner_stroke()));
if needs_exit_strokes {
let mut element_strokes: Cow<Shape> = Cow::Borrowed(element);