diff options
author | Tyler Schicke <tyler_schicke@brown.edu> | 2019-07-13 16:46:58 -0400 |
---|---|---|
committer | Tyler Schicke <tyler_schicke@brown.edu> | 2019-07-13 16:46:58 -0400 |
commit | 2e75ca29e6e17d637cdad5992ee55e921559922a (patch) | |
tree | 6a471f0a7c20c3fc6695e22cf38388458ec22972 /src/client/documents/Documents.ts | |
parent | 60ceef0a3a8c11d85434a154e542424d34d9562c (diff) | |
parent | 3c6c4e6da942ef4c1e7faebdc165eb4fcaa7bee4 (diff) |
Merge branch 'master' of github-tsch-brown:browngraphicslab/Dash-Web
Diffstat (limited to 'src/client/documents/Documents.ts')
-rw-r--r-- | src/client/documents/Documents.ts | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/src/client/documents/Documents.ts b/src/client/documents/Documents.ts index 2a3827782..ada9f3610 100644 --- a/src/client/documents/Documents.ts +++ b/src/client/documents/Documents.ts @@ -54,7 +54,8 @@ export enum DocumentType { PDF = "pdf", ICON = "icon", IMPORT = "import", - LINK = "link" + LINK = "link", + LINKDOC = "linkdoc" } export interface DocumentOptions { @@ -85,6 +86,12 @@ export interface DocumentOptions { // [key: string]: Opt<Field>; } +class EmptyBox { + public static LayoutString() { + return ""; + } +} + export namespace Docs { export namespace Prototypes { @@ -135,7 +142,7 @@ export namespace Docs { }], [DocumentType.AUDIO, { layout: { view: AudioBox }, - options: { height: 150 } + options: { height: 32 } }], [DocumentType.PDF, { layout: { view: PDFBox, collectionView: [CollectionPDFView, data, anno] as CollectionViewType }, @@ -148,6 +155,11 @@ export namespace Docs { [DocumentType.IMPORT, { layout: { view: DirectoryImportBox }, options: { height: 150 } + }], + [DocumentType.LINKDOC, { + data: new List<Doc>(), + layout: { view: EmptyBox }, + options: {} }] ]); @@ -195,6 +207,10 @@ export namespace Docs { return PrototypeMap.get(type)!; } + export function MainLinkDocument() { + return Prototypes.get(DocumentType.LINKDOC); + } + /** * This is a convenience method that is used to initialize * prototype documents for the first time. |