@builder.io/react
Advanced tools
Comparing version 0.1.66-1 to 0.1.66-2
@@ -53,11 +53,11 @@ "use strict"; | ||
return (react_1.default.createElement("div", { style: { position: 'relative', fontSize: 0 } }, | ||
react_1.default.createElement("video", { height: this.props.height, width: this.props.width, ref: function (ref) { return (_this.video = ref); }, autoPlay: this.props.autoPlay, src: this.props.video, muted: this.props.muted, controls: this.props.controls, loop: this.props.loop, className: "builder-video", style: __assign({ width: '100%', height: '100%', objectFit: this.props.fit, objectPosition: this.props.position, | ||
react_1.default.createElement("video", { poster: this.props.posterImage, height: this.props.height, width: this.props.width, ref: function (ref) { return (_this.video = ref); }, autoPlay: this.props.autoPlay, src: this.props.video, muted: this.props.muted, controls: this.props.controls, loop: this.props.loop, className: "builder-video", style: __assign({ width: '100%', height: '100%', objectFit: this.props.fit, objectPosition: this.props.position, | ||
// Hack to get object fit to work as expected and not have the video | ||
// overflow | ||
borderRadius: 1 }, (aspectRatio && { | ||
position: 'absolute', | ||
position: 'absolute' | ||
})) }), | ||
aspectRatio && (react_1.default.createElement("div", { style: { | ||
width: '100%', | ||
paddingTop: aspectRatio * 100 + '%', | ||
paddingTop: aspectRatio * 100 + '%' | ||
} })))); | ||
@@ -75,8 +75,14 @@ }; | ||
defaultValue: 'https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/assets%2FKQlEmWDxA0coC3PK6UvkrjwkIGI2%2F28cb070609f546cdbe5efa20e931aa4b?alt=media&token=912e9551-7a7c-4dfb-86b6-3da1537d1a7f', | ||
required: true, | ||
required: true | ||
}, | ||
{ | ||
name: 'posterImage', | ||
type: 'file', | ||
allowedFileTypes: ['jpg', 'png'], | ||
helperText: 'Image to show before the video plays' | ||
}, | ||
{ | ||
name: 'autoPlay', | ||
type: 'boolean', | ||
defaultValue: true, | ||
defaultValue: true | ||
}, | ||
@@ -86,3 +92,3 @@ { | ||
type: 'boolean', | ||
defaultValue: false, | ||
defaultValue: false | ||
}, | ||
@@ -92,3 +98,3 @@ { | ||
type: 'boolean', | ||
defaultValue: true, | ||
defaultValue: true | ||
}, | ||
@@ -98,3 +104,3 @@ { | ||
type: 'boolean', | ||
defaultValue: true, | ||
defaultValue: true | ||
}, | ||
@@ -104,3 +110,3 @@ { | ||
type: 'boolean', | ||
defaultValue: true, | ||
defaultValue: true | ||
}, | ||
@@ -111,3 +117,3 @@ { | ||
defaultValue: 'cover', | ||
enum: ['contain', 'cover', 'fill'], | ||
enum: ['contain', 'cover', 'fill'] | ||
}, | ||
@@ -127,4 +133,4 @@ { | ||
'bottom left', | ||
'bottom right', | ||
], | ||
'bottom right' | ||
] | ||
}, | ||
@@ -134,3 +140,3 @@ { | ||
type: 'number', | ||
hideFromUI: true, | ||
hideFromUI: true | ||
}, | ||
@@ -140,3 +146,3 @@ { | ||
type: 'number', | ||
hideFromUI: true, | ||
hideFromUI: true | ||
}, | ||
@@ -146,5 +152,5 @@ { | ||
type: 'number', | ||
hideFromUI: true, | ||
}, | ||
], | ||
hideFromUI: true | ||
} | ||
] | ||
}) | ||
@@ -151,0 +157,0 @@ ], Video); |
@@ -14,2 +14,3 @@ import React from 'react'; | ||
position?: string; | ||
posterImage?: string; | ||
}> { | ||
@@ -16,0 +17,0 @@ video: HTMLVideoElement | null; |
{ | ||
"name": "@builder.io/react", | ||
"version": "0.1.66-1", | ||
"version": "0.1.66-2", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "keywords": [], |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3432929
24540