From 91238211318976f63e66724b16bee12985ae3081 Mon Sep 17 00:00:00 2001 From: Hikaru Y Date: Sat, 22 Apr 2023 15:08:25 +0900 Subject: [PATCH] Refactor plain/rich text input toggling code; fix focus loss (#2479) * Refactor plain/rich text input toggling code; fix focus loss Fix: - Issue where field loses focus when plain/rich text input is closed Refactoring: - Call refocus() inside the reactive statement in Plain/RichTextInput.svelte to eliminate the need for polling with requestAnimationFrame - Introduce 'Flag' class - Move 'on:toggle' handlers from inline to functions defined in the