aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBob Zeleznik <zzzman@gmail.com>2019-03-12 00:15:05 -0400
committerBob Zeleznik <zzzman@gmail.com>2019-03-12 00:15:05 -0400
commit2100f1b25fa822d14a49a1ddbb38182860db6edb (patch)
tree9352d529fc97dcdb218e1eefdec16e8c2b180b60 /src
parent5021cc23beec55085167bd974299fb314d3bdbcf (diff)
finally got css right for images?
Diffstat (limited to 'src')
-rw-r--r--src/client/documents/Documents.ts4
-rw-r--r--src/client/views/collections/CollectionFreeFormView.scss2
-rw-r--r--src/client/views/nodes/ImageBox.scss2
3 files changed, 5 insertions, 3 deletions
diff --git a/src/client/documents/Documents.ts b/src/client/documents/Documents.ts
index e6e2378c4..3d9f4a0cb 100644
--- a/src/client/documents/Documents.ts
+++ b/src/client/documents/Documents.ts
@@ -151,6 +151,8 @@ export namespace Documents {
export function ImageDocument(url: string, options: DocumentOptions = {}) {
return SetInstanceOptions(GetImagePrototype(), { ...options, layoutKeys: [KeyStore.Data, KeyStore.Annotations, KeyStore.Caption] },
[new URL(url), ImageField]);
+ // let doc = SetInstanceOptions(GetImagePrototype(), { ...options, layoutKeys: [KeyStore.Data, KeyStore.Annotations, KeyStore.Caption] },
+ // [new URL(url), ImageField]);
// doc.SetText(KeyStore.Caption, "my caption...");
// doc.SetText(KeyStore.BackgroundLayout, EmbeddedCaption());
// doc.SetText(KeyStore.OverlayLayout, FixedCaption());
@@ -190,7 +192,7 @@ export namespace Documents {
// example of custom display string for an image that shows a caption.
function EmbeddedCaption() {
return `<div style="height:100%">
- <div style="position:relative; margin:auto; height:85%;" >`
+ <div style="position:relative; margin:auto; height:85%; width:85%;" >`
+ ImageBox.LayoutString() +
`</div>
<div style="position:relative; height:15%; text-align:center; ">`
diff --git a/src/client/views/collections/CollectionFreeFormView.scss b/src/client/views/collections/CollectionFreeFormView.scss
index d294dc4d7..d487cd7ce 100644
--- a/src/client/views/collections/CollectionFreeFormView.scss
+++ b/src/client/views/collections/CollectionFreeFormView.scss
@@ -40,7 +40,7 @@
}
border-style: solid;
- box-sizing: content-box;
+ box-sizing: border-box;
position: absolute;
top: 0;
left: 0;
diff --git a/src/client/views/nodes/ImageBox.scss b/src/client/views/nodes/ImageBox.scss
index ea459b911..31452bc85 100644
--- a/src/client/views/nodes/ImageBox.scss
+++ b/src/client/views/nodes/ImageBox.scss
@@ -10,8 +10,8 @@
}
.imageBox-cont img {
- object-fit: contain;
height: 100%;
+ width:100%;
}
.imageBox-button {