diff options
author | bobzel <zzzman@gmail.com> | 2025-03-26 14:58:23 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2025-03-26 14:58:23 -0400 |
commit | 68e64bbe6bd777e93f9bffe7eb958f8abdce53c3 (patch) | |
tree | 446d36d40f6d5742a0edb3bb18060ee1b1f1c5f0 /src | |
parent | ab785dbb8c9e904b2f4bba8b4000b85db2d8d541 (diff) |
from last
Diffstat (limited to 'src')
-rw-r--r-- | src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx index 7fd5d71fd..09a1b0c53 100644 --- a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx +++ b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx @@ -1489,7 +1489,7 @@ export class CollectionFreeFormView extends CollectionSubView<Partial<collection * @returns whether the new text doc was created and added successfully */ createTextDocCopy = undoable((textBox: FormattedTextBox, below: boolean) => { - const textDoc = DocCast(textBox.Document.rootDocument, textBox.Document); + const textDoc = DocCast(textBox.Document, textBox.Document); const newDoc = Doc.MakeCopy(textDoc, true); newDoc['$' + Doc.LayoutFieldKey(newDoc, textBox._props.LayoutTemplateString)] = undefined; // the copy should not copy the text contents of it source, just the render style newDoc.x = NumCast(textDoc.x) + (below ? 0 : NumCast(textDoc._width) + 10); |