aboutsummaryrefslogtreecommitdiff
path: root/src/client/documents/Documents.ts
diff options
context:
space:
mode:
authorBob Zeleznik <zzzman@gmail.com>2020-06-15 11:58:04 -0400
committerBob Zeleznik <zzzman@gmail.com>2020-06-15 11:58:04 -0400
commit279e71d098053dc2ca5b69e6e502a95dab230daa (patch)
tree8b4e3142c28f0a3407ad9e39ae411dd902826a0b /src/client/documents/Documents.ts
parent39d2e4a2e70ace7a882d3b3b9d9cf06b4224fa69 (diff)
added a linkView and changed display of docFieldView to inline to allow text wrapping on the same line as the fieldLabel
Diffstat (limited to 'src/client/documents/Documents.ts')
-rw-r--r--src/client/documents/Documents.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/documents/Documents.ts b/src/client/documents/Documents.ts
index 2ecc8c8b7..002bfe6a2 100644
--- a/src/client/documents/Documents.ts
+++ b/src/client/documents/Documents.ts
@@ -606,7 +606,6 @@ export namespace Docs {
selection: { type: "text", anchor: 1, head: 1 },
storedMarks: []
};
-
const field = text ? new RichTextField(JSON.stringify(rtf), text) : undefined;
return InstanceFromProto(Prototypes.get(DocumentType.RTF), field, options, undefined, fieldKey);
}
@@ -823,7 +822,8 @@ export namespace DocUtils {
if (sv && sv.props.ContainingCollectionDoc === target.doc) return;
if (target.doc === Doc.UserDoc()) return undefined;
- const linkDoc = Docs.Create.LinkDocument(source, target, { linkRelationship }, id);
+ const linkDoc = Docs.Create.LinkDocument(source, target, { linkRelationship, layoutKey: "layout_linkView" }, id);
+ linkDoc.layout_linkView = Cast(Cast(Doc.UserDoc()["template-button-link"], Doc, null).dragFactory, Doc, null);
Doc.GetProto(linkDoc).title = ComputedField.MakeFunction('self.anchor1.title +" (" + (self.linkRelationship||"to") +") " + self.anchor2.title');
Doc.GetProto(source.doc).links = ComputedField.MakeFunction("links(self)");