diff options
| author | bob <bcz@cs.brown.edu> | 2020-01-22 12:08:20 -0500 |
|---|---|---|
| committer | bob <bcz@cs.brown.edu> | 2020-01-22 12:08:20 -0500 |
| commit | 5a6f6868dc25b2b24c6c7f4a7bc25670e6a35f47 (patch) | |
| tree | 31cf7400f701dd215c6004a02a59bb72fb2ea3d0 /src/client/util/DropConverter.ts | |
| parent | 17c4ca6f517ab786f3c6b269c95a9b5ae4b0ff9a (diff) | |
fixed template/scripting problem. added collectionDoc parameter for onClick scripts. made buxton layout update hero image on click.
Diffstat (limited to 'src/client/util/DropConverter.ts')
| -rw-r--r-- | src/client/util/DropConverter.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/util/DropConverter.ts b/src/client/util/DropConverter.ts index ff0e19347..3e2cc6a2e 100644 --- a/src/client/util/DropConverter.ts +++ b/src/client/util/DropConverter.ts @@ -7,7 +7,7 @@ import { StrCast } from "../../new_fields/Types"; import { Docs } from "../documents/Documents"; import { ScriptField } from "../../new_fields/ScriptField"; -export function makeTemplate(doc: Doc, suppressTitle = false): boolean { +export function makeTemplate(doc: Doc): boolean { const layoutDoc = doc.layout instanceof Doc && doc.layout.isTemplateField ? doc.layout : doc; const layout = StrCast(layoutDoc.layout).match(/fieldKey={'[^']*'}/)![0]; const fieldKey = layout.replace("fieldKey={'", "").replace(/'}$/, ""); @@ -16,7 +16,7 @@ export function makeTemplate(doc: Doc, suppressTitle = false): boolean { docs.forEach(d => { if (!StrCast(d.title).startsWith("-")) { any = true; - Doc.MakeMetadataFieldTemplate(d, Doc.GetProto(layoutDoc), suppressTitle); + Doc.MakeMetadataFieldTemplate(d, Doc.GetProto(layoutDoc)); } else if (d.type === DocumentType.COL) { any = makeTemplate(d) || any; } |
