From 41c4be2f54766f96ed48d78b946d04404a870477 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Mon, 19 Jul 2021 23:27:11 +1000 Subject: [PATCH] Introduce editable-container Contains the shadow root, and references to the styles. Is ignorant of Editable. Is necessary, so our we editable.scss does not need to contain information about Codable, ImageHandle or all those other things which have nothing to do with Editable --- ts/editor/FormatBlockButtons.svelte | 11 +++--- ts/editor/TemplateButtons.svelte | 3 +- ts/editor/change-timer.ts | 7 ++-- ts/editor/editable-container.ts | 57 ++++++++++++++++++++++++++++ ts/editor/editing-area.ts | 59 +++++++++++------------------ ts/editor/fields.scss | 9 +++++ ts/editor/focus-handlers.ts | 5 ++- ts/editor/helpers.ts | 6 +++ ts/editor/index.ts | 10 ++--- ts/editor/wrap.ts | 3 +- 10 files changed, 112 insertions(+), 58 deletions(-) create mode 100644 ts/editor/editable-container.ts diff --git a/ts/editor/FormatBlockButtons.svelte b/ts/editor/FormatBlockButtons.svelte index 28c0a2dd7..d2fc2a140 100644 --- a/ts/editor/FormatBlockButtons.svelte +++ b/ts/editor/FormatBlockButtons.svelte @@ -3,7 +3,6 @@ Copyright: Ankitects Pty Ltd and contributors License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html -->