diff options
author | Tyler Schicke <tyler_schicke@brown.edu> | 2019-02-01 15:33:21 -0500 |
---|---|---|
committer | Tyler Schicke <tyler_schicke@brown.edu> | 2019-02-01 15:33:21 -0500 |
commit | dd427c8d72a5189c0b91132863a6e9c5a62eadfe (patch) | |
tree | d3dd624c5f3948b24861c19a5939a2b2f3b9a295 /src/documents/Documents.ts | |
parent | c5e60251835ef9fa60054e422f51d5f92c8494bb (diff) | |
parent | 156245bbca2082a8b8cf426a381ed25d1be57bcb (diff) |
Merge branch 'master' of github-tsch-brown:browngraphicslab/Dash-Web
Diffstat (limited to 'src/documents/Documents.ts')
-rw-r--r-- | src/documents/Documents.ts | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/documents/Documents.ts b/src/documents/Documents.ts index a2d25e606..a5edebda2 100644 --- a/src/documents/Documents.ts +++ b/src/documents/Documents.ts @@ -8,6 +8,7 @@ import { CollectionDockingView } from "../views/collections/CollectionDockingVie import { CollectionSchemaView } from "../views/collections/CollectionSchemaView"; import { ImageField } from "../fields/ImageField"; import { RichTextField } from "../fields/RichTextField"; +import { ImageBox } from "../views/nodes/ImageBox"; interface DocumentOptions { x?: number; @@ -112,9 +113,9 @@ export namespace Documents { imageProto.SetField(KeyStore.Y, new NumberField(0)); imageProto.SetField(KeyStore.Width, new NumberField(300)); imageProto.SetField(KeyStore.Height, new NumberField(300)); - imageProto.SetField(KeyStore.Layout, new TextField('<img src={Data} draggable="false" width="100%" alt="Image not found"/>')); + imageProto.SetField(KeyStore.Layout, new TextField(ImageBox.LayoutString())); // imageProto.SetField(KeyStore.Layout, new TextField('<div style={"background-image: " + {Data}} />')); - imageProto.SetField(KeyStore.LayoutFields, new ListField([KeyStore.Data])); + imageProto.SetField(KeyStore.LayoutKeys, new ListField([KeyStore.Data])); } return imageProto; } |