diff options
author | Nathan-SR <144961007+Nathan-SR@users.noreply.github.com> | 2024-11-05 17:12:29 -0500 |
---|---|---|
committer | Nathan-SR <144961007+Nathan-SR@users.noreply.github.com> | 2024-11-05 17:12:29 -0500 |
commit | c86f18caf079d97f673935b7a83a16d6e97bb804 (patch) | |
tree | 04b8c02397cd3c9197b61010f2dbde366125e3c4 /src/client/views/nodes/DataVizBox/DocCreatorMenu/DocCreatorMenu.tsx | |
parent | c041bc0ee0346e6b7f0678228e909747bc36f73c (diff) |
edits are persisting!!
Diffstat (limited to 'src/client/views/nodes/DataVizBox/DocCreatorMenu/DocCreatorMenu.tsx')
-rw-r--r-- | src/client/views/nodes/DataVizBox/DocCreatorMenu/DocCreatorMenu.tsx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/client/views/nodes/DataVizBox/DocCreatorMenu/DocCreatorMenu.tsx b/src/client/views/nodes/DataVizBox/DocCreatorMenu/DocCreatorMenu.tsx index e21f0a70c..d214a7954 100644 --- a/src/client/views/nodes/DataVizBox/DocCreatorMenu/DocCreatorMenu.tsx +++ b/src/client/views/nodes/DataVizBox/DocCreatorMenu/DocCreatorMenu.tsx @@ -112,12 +112,13 @@ export class DocCreatorMenu extends ObservableReactComponent<FieldViewProps> { this._templateDocs = docs.map(doc => (doc.annotationOn ? DocCast(doc.annotationOn) : doc)); }; @action updateTemplatePreviews = (templates: Template[]) => { + templates.forEach(template => template.renderUpdates()); this._suggestedTemplatePreviews = templates.map(template => { const doc = template.mainField.renderedDoc(); const wrapper: Doc = Docs.Create.FreeformDocument([doc], { _height: NumListCast(doc._height)[0], _width: NumListCast(doc._width)[0], title: ''}); return {doc: wrapper, template: template}; }); - } + }; @action setSuggestedTemplates = (templates: Template[]) => { this._suggestedTemplates = templates; this.updateTemplatePreviews(templates); |