-
-
-
-
{this.props.source.id}
+ if (typeof(source) !== 'object') {
+ return renderError()
+ }
+ const {id, url, title, date, type, affil_1, affil_2} = source
+ return (
+
+
+
+
+
-
- {this._renderContent()}
-
-
-
- {id ?
{id}
: null}
- {title?
{title}
: null}
-
- {type ?
Type: {type}
: null}
- {date ?
Date:{date}
: null}
-
- {url ?
: null}
-
+
{source.id}
+
+
+ {_renderContent()}
+
+
+
+ {id ?
{id}
: null}
+ {title?
{title}
: null}
+
+ {type ?
Type: {type}
: null}
+ {date ?
Date:{date}
: null}
+
+ {url ?
: null}
- )
- }
+
+ )
}
export default SourceOverlay
diff --git a/src/components/presentational/CardSource.js b/src/components/presentational/CardSource.js
index b3bca21..9b3da5b 100644
--- a/src/components/presentational/CardSource.js
+++ b/src/components/presentational/CardSource.js
@@ -43,7 +43,6 @@ const CardSource = ({ source, isLoading, onClickHandler }) => {
const imgs = source.paths.filter(p => p.match(isImgUrl))
thumbnail = imgs.length > 0 ? imgs[0] : null
}
- console.log(thumbnail)
const fallbackIcon = (
diff --git a/src/scss/mediaoverlay.scss b/src/scss/mediaoverlay.scss
index 9046ba7..891280f 100644
--- a/src/scss/mediaoverlay.scss
+++ b/src/scss/mediaoverlay.scss
@@ -48,34 +48,45 @@ $header-inset: 10px;
.mo-container {
background-color: rgba(239, 239, 239, 0.9);
- max-width: $panel-width;
- min-width: $panel-width;
- max-height: $panel-height;
- min-height: $panel-height;
+ // max-width: $panel-width;
+ // min-width: $panel-width;
+ // max-height: $panel-height;
+ // min-height: $panel-height;
display: flex;
flex-direction: column;
- justify-content: flex-start;
align-items: center;
+ height: 80vh;
+ max-width: 90vw;
.mo-media-container {
flex: 1;
display: flex;
+ flex-direction: column;
justify-content: center;
align-items: center;
}
}
.mo-media-container {
- // padding-top: 3*$header-inset;
font-family: "Lato", Helvetica, sans-serif;
- // max-height: $vimeo-height;
min-width: 100%;
- max-height: 500px;
+ max-height: 60vh;
+ overflow-y: auto;
.media-player {
width: 100%;
max-width: $vimeo-width;
}
+
+ .media-content {
+ display: flex;
+ flex-direction: column;
+ }
+
+ // NB: topcushion seems to be necessary with certain overflows..
+ &.topcushion {
+ padding-top: 150px;
+ }
}
.mo-meta-container {
@@ -146,8 +157,10 @@ $header-inset: 10px;
.source-image-container {
padding: 0 25px;
- overflow-y: scroll;
height: 100%;
+ display: flex;
+ justify-content: center;
+ align-items: center;
}
.source-image, .source-video {