diff options
author | Bob Zeleznik <zzzman@gmail.com> | 2019-08-04 13:34:29 -0400 |
---|---|---|
committer | Bob Zeleznik <zzzman@gmail.com> | 2019-08-04 13:34:29 -0400 |
commit | 0b2d0cc563755c7b5899bc25a791359306166d9b (patch) | |
tree | a38e71da8c69be3222302a2955a144cf0031c39e /src/client/views/nodes/DocumentView.tsx | |
parent | fd047fa87334b948a4a0b00ccf9bd02ded03ea36 (diff) |
fixed up backend for titles and captions.
Diffstat (limited to 'src/client/views/nodes/DocumentView.tsx')
-rw-r--r-- | src/client/views/nodes/DocumentView.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/nodes/DocumentView.tsx b/src/client/views/nodes/DocumentView.tsx index 4528cf94d..a7b4f33db 100644 --- a/src/client/views/nodes/DocumentView.tsx +++ b/src/client/views/nodes/DocumentView.tsx @@ -690,8 +690,8 @@ export class DocumentView extends DocComponent<DocumentViewProps, Document>(Docu let templates = Cast(this.layoutDoc.templates, listSpec("string")); if (!showOverlays && templates instanceof List) { templates.map(str => { - if (str.indexOf("{props.Document.title}") !== -1) showTitle = "title"; - if (str.indexOf("fieldKey={\"caption\"}") !== -1) showCaption = "caption"; + if (!showTitle && str.indexOf("{props.Document.title}") !== -1) showTitle = "title"; + if (!showCaption && str.indexOf("fieldKey={\"caption\"}") !== -1) showCaption = "caption"; }); } let showTextTitle = showTitle && StrCast(this.layoutDoc.layout).startsWith("<FormattedTextBox") ? showTitle : undefined; |