@micromag/screen-urbania-trivia 0.3.607 → 0.3.610
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/index.js +18 -18
- package/package.json +11 -11
package/es/index.js
CHANGED
|
@@ -105,19 +105,19 @@ var UrbaniaTrivia = function UrbaniaTrivia(_ref) {
|
|
|
105
105
|
// get resized video style props
|
|
106
106
|
var _ref2 = video || {},
|
|
107
107
|
_ref2$autoPlay = _ref2.autoPlay,
|
|
108
|
-
autoPlay = _ref2$autoPlay ===
|
|
108
|
+
autoPlay = _ref2$autoPlay === undefined ? true : _ref2$autoPlay,
|
|
109
109
|
_ref2$media = _ref2.media,
|
|
110
|
-
videoMedia = _ref2$media ===
|
|
110
|
+
videoMedia = _ref2$media === undefined ? null : _ref2$media,
|
|
111
111
|
_ref2$closedCaptions = _ref2.closedCaptions,
|
|
112
|
-
closedCaptions = _ref2$closedCaptions ===
|
|
112
|
+
closedCaptions = _ref2$closedCaptions === undefined ? null : _ref2$closedCaptions,
|
|
113
113
|
_ref2$withSeekBar = _ref2.withSeekBar,
|
|
114
|
-
withSeekBar = _ref2$withSeekBar ===
|
|
114
|
+
withSeekBar = _ref2$withSeekBar === undefined ? false : _ref2$withSeekBar,
|
|
115
115
|
_ref2$withControls = _ref2.withControls,
|
|
116
|
-
withControls = _ref2$withControls ===
|
|
116
|
+
withControls = _ref2$withControls === undefined ? false : _ref2$withControls,
|
|
117
117
|
_ref2$color = _ref2.color,
|
|
118
|
-
color = _ref2$color ===
|
|
118
|
+
color = _ref2$color === undefined ? null : _ref2$color,
|
|
119
119
|
_ref2$progressColor = _ref2.progressColor,
|
|
120
|
-
progressColor = _ref2$progressColor ===
|
|
120
|
+
progressColor = _ref2$progressColor === undefined ? null : _ref2$progressColor;
|
|
121
121
|
var _usePlaybackContext = usePlaybackContext(),
|
|
122
122
|
playing = _usePlaybackContext.playing,
|
|
123
123
|
muted = _usePlaybackContext.muted,
|
|
@@ -217,9 +217,9 @@ var UrbaniaTrivia = function UrbaniaTrivia(_ref) {
|
|
|
217
217
|
var fullscreen = layout === 'full';
|
|
218
218
|
var _ref5 = background || {},
|
|
219
219
|
_ref5$image = _ref5.image,
|
|
220
|
-
backgroundImage = _ref5$image ===
|
|
220
|
+
backgroundImage = _ref5$image === undefined ? null : _ref5$image,
|
|
221
221
|
_ref5$video = _ref5.video,
|
|
222
|
-
backgroundVideo = _ref5$video ===
|
|
222
|
+
backgroundVideo = _ref5$video === undefined ? null : _ref5$video;
|
|
223
223
|
var isCustomBackground = background === null || backgroundImage === null && backgroundVideo === null;
|
|
224
224
|
var isAnimatedBackground = !isStatic && !isPreview && isCustomBackground;
|
|
225
225
|
var hasVideo = video !== null;
|
|
@@ -234,21 +234,21 @@ var UrbaniaTrivia = function UrbaniaTrivia(_ref) {
|
|
|
234
234
|
}, [hasVideo, video, isPreview, isStatic, isCapture, autoPlay, current]);
|
|
235
235
|
var _ref6 = videoMedia || {},
|
|
236
236
|
_ref6$metadata = _ref6.metadata,
|
|
237
|
-
videoMetadata = _ref6$metadata ===
|
|
237
|
+
videoMetadata = _ref6$metadata === undefined ? null : _ref6$metadata,
|
|
238
238
|
_ref6$url = _ref6.url,
|
|
239
|
-
videoUrl = _ref6$url ===
|
|
239
|
+
videoUrl = _ref6$url === undefined ? null : _ref6$url,
|
|
240
240
|
_ref6$thumbnail_url = _ref6.thumbnail_url,
|
|
241
|
-
thumbnailUrl = _ref6$thumbnail_url ===
|
|
241
|
+
thumbnailUrl = _ref6$thumbnail_url === undefined ? null : _ref6$thumbnail_url;
|
|
242
242
|
var hasVideoUrl = videoUrl !== null;
|
|
243
243
|
var _ref7 = videoMetadata || {},
|
|
244
244
|
_ref7$width = _ref7.width,
|
|
245
|
-
videoWidth = _ref7$width ===
|
|
245
|
+
videoWidth = _ref7$width === undefined ? 0 : _ref7$width,
|
|
246
246
|
_ref7$height = _ref7.height,
|
|
247
|
-
videoHeight = _ref7$height ===
|
|
247
|
+
videoHeight = _ref7$height === undefined ? 0 : _ref7$height;
|
|
248
248
|
var _useDimensionObserver = useDimensionObserver(),
|
|
249
249
|
titleRef = _useDimensionObserver.ref,
|
|
250
250
|
_useDimensionObserver2 = _useDimensionObserver.height,
|
|
251
|
-
titleHeight = _useDimensionObserver2 ===
|
|
251
|
+
titleHeight = _useDimensionObserver2 === undefined ? 0 : _useDimensionObserver2;
|
|
252
252
|
var videoMaxHeight = height - titleHeight - (padding ? padding * 2 : 40);
|
|
253
253
|
var _getSizeWithinBounds = getSizeWithinBounds(videoWidth, videoHeight, width, videoMaxHeight, {
|
|
254
254
|
cover: fullscreen
|
|
@@ -265,11 +265,11 @@ var UrbaniaTrivia = function UrbaniaTrivia(_ref) {
|
|
|
265
265
|
}
|
|
266
266
|
var _ref8 = background || {},
|
|
267
267
|
_ref8$image = _ref8.image,
|
|
268
|
-
bgImage = _ref8$image ===
|
|
268
|
+
bgImage = _ref8$image === undefined ? null : _ref8$image,
|
|
269
269
|
_ref8$video = _ref8.video,
|
|
270
|
-
bgVideo = _ref8$video ===
|
|
270
|
+
bgVideo = _ref8$video === undefined ? null : _ref8$video,
|
|
271
271
|
_ref8$color = _ref8.color,
|
|
272
|
-
bgColor = _ref8$color ===
|
|
272
|
+
bgColor = _ref8$color === undefined ? null : _ref8$color;
|
|
273
273
|
if (bgImage !== null || bgVideo !== null) {
|
|
274
274
|
return _objectSpread(_objectSpread({}, defaultBackground), background);
|
|
275
275
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/screen-urbania-trivia",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.610",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "",
|
|
6
6
|
"keywords": [
|
|
@@ -62,15 +62,15 @@
|
|
|
62
62
|
"dependencies": {
|
|
63
63
|
"@babel/runtime": "^7.13.10",
|
|
64
64
|
"@folklore/size": "^0.1.20",
|
|
65
|
-
"@micromag/core": "^0.3.
|
|
66
|
-
"@micromag/element-background": "^0.3.
|
|
67
|
-
"@micromag/element-call-to-action": "^0.3.
|
|
68
|
-
"@micromag/element-closed-captions": "^0.3.
|
|
69
|
-
"@micromag/element-container": "^0.3.
|
|
70
|
-
"@micromag/element-heading": "^0.3.
|
|
71
|
-
"@micromag/element-image": "^0.3.
|
|
72
|
-
"@micromag/element-video": "^0.3.
|
|
73
|
-
"@micromag/transforms": "^0.3.
|
|
65
|
+
"@micromag/core": "^0.3.610",
|
|
66
|
+
"@micromag/element-background": "^0.3.610",
|
|
67
|
+
"@micromag/element-call-to-action": "^0.3.610",
|
|
68
|
+
"@micromag/element-closed-captions": "^0.3.610",
|
|
69
|
+
"@micromag/element-container": "^0.3.610",
|
|
70
|
+
"@micromag/element-heading": "^0.3.610",
|
|
71
|
+
"@micromag/element-image": "^0.3.610",
|
|
72
|
+
"@micromag/element-video": "^0.3.610",
|
|
73
|
+
"@micromag/transforms": "^0.3.610",
|
|
74
74
|
"classnames": "^2.2.6",
|
|
75
75
|
"lodash": "^4.17.21",
|
|
76
76
|
"prop-types": "^15.7.2",
|
|
@@ -81,5 +81,5 @@
|
|
|
81
81
|
"access": "public",
|
|
82
82
|
"registry": "https://registry.npmjs.org/"
|
|
83
83
|
},
|
|
84
|
-
"gitHead": "
|
|
84
|
+
"gitHead": "7a002b920dc02d8daa6dfd6aedc1a97951a8e939"
|
|
85
85
|
}
|