From 6c8effb77029db96bccab92152a6b68a0aefc132 Mon Sep 17 00:00:00 2001 From: bobzel Date: Tue, 1 Apr 2025 13:30:06 -0400 Subject: fixed text views to write/read font_ from data doc. --- .../views/nodes/formattedText/FormattedTextBox.tsx | 38 +++++++++++----------- 1 file changed, 19 insertions(+), 19 deletions(-) (limited to 'src/client/views/nodes/formattedText/FormattedTextBox.tsx') diff --git a/src/client/views/nodes/formattedText/FormattedTextBox.tsx b/src/client/views/nodes/formattedText/FormattedTextBox.tsx index 6955e5401..f7e6d8e1e 100644 --- a/src/client/views/nodes/formattedText/FormattedTextBox.tsx +++ b/src/client/views/nodes/formattedText/FormattedTextBox.tsx @@ -141,20 +141,20 @@ export class FormattedTextBox extends ViewBoxAnnotatableComponent { - if (this.EditorView && this._recordingDictation) { + if (this.EditorView && this.recordingDictation) { this.stopDictation(/* true */); this._break = true; const { state } = this.EditorView; const { to } = state.selection; const updated = TextSelection.create(state.doc, to, to); this.EditorView.dispatch(state.tr.setSelection(updated).insert(to, state.schema.nodes.paragraph.create({}))); - if (this._recordingDictation) { + if (this.recordingDictation) { this.recordDictation(); } } @@ -1333,14 +1333,14 @@ export class FormattedTextBox extends ViewBoxAnnotatableComponent this._recordingDictation, + () => this.recordingDictation, () => { this.stopDictation(/* true */); - this._recordingDictation && this.recordDictation(); + this.recordingDictation && this.recordDictation(); }, { fireImmediately: true } ); - if (this._recordingDictation) setTimeout(this.recordDictation); + if (this.recordingDictation) setTimeout(this.recordDictation); } this._disposers.scroll = reaction( () => NumCast(this.layoutDoc._layout_scrollTop), @@ -1560,8 +1560,8 @@ export class FormattedTextBox extends ViewBoxAnnotatableComponent disposer?.()); this.endUndoTypingBatch(); @@ -1596,7 +1596,7 @@ export class FormattedTextBox extends ViewBoxAnnotatableComponent @@ -1919,7 +1919,7 @@ export class FormattedTextBox extends ViewBoxAnnotatableComponent { - this._recordingDictation = !this._recordingDictation; + this.recordingDictation = !this.recordingDictation; }) ) }> -- cgit v1.2.3-70-g09d2