Moin
09.Февраль.2026 21:34:59
1
Когда упрощённое создание категорий отключено, ввести адрес входящей электронной почты для категории очень сложно, так как поле теряет фокус после ввода каждой буквы.
6 лайков
Это должно исправить проблему
main ← fix/legacy-category-email-settings-focus-loss
merged 11:47PM - 11 Feb 26 UTC
When `enable_simplified_category_creation` is disabled, the email fields in cate… gory settings lose focus after every keystroke, making it impossible to type an email address.
The legacy category editor wraps all tabs in a FormKit `<Form>` component. The Form wrapper uses `{{#each (array @data)}}` which destroys and recreates the entire component tree when `@data` changes identity. Since the controller's `formData` getter returns a new object (via `getProperties`) every time a model property changes, any two-way binding mutation — including every keystroke in a `<TextField>` — triggers a full teardown and rebuild of all form elements, destroying the focused input.
This commit converts the email section inputs (`email_in`, `email_in_allow_strangers`, `mailinglist_mirror`) from two-way model bindings to use FormKit's data layer (`form.set` / `transientData`). Edits to these fields no longer mutate the model, so `formData` isn't invalidated and the form is not recreated.
This commit also passes `form` to the `category-email-in` and `category-custom-settings` plugin outlets on the legacy page, matching what the simplified page already does, so that plugins can adopt FormKit as well.
https://meta.discourse.org/t/395609
3 лайка
sam
(Sam Saffron)
Закрыл(а) тему
12.Февраль.2026 21:00:38
6
Эта тема была автоматически закрыта через 21 час. Новые ответы больше не принимаются.