We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents f1c5267 + 54be788 commit d480affCopy full SHA for d480aff
lib/src/replaced_element.dart
@@ -249,9 +249,9 @@ class VideoContentElement extends ReplacedElement {
249
250
@override
251
Widget toWidget(RenderContext context) {
252
+ final double _width = width ?? (height ?? 150) * 2;
253
+ final double _height = height ?? (width ?? 300) / 2;
254
return Container(
- width: width ?? (height ?? 150) * 2,
- height: height ?? (width ?? 300) / 2,
255
child: Chewie(
256
controller: ChewieController(
257
videoPlayerController: VideoPlayerController.network(
@@ -264,6 +264,7 @@ class VideoContentElement extends ReplacedElement {
264
looping: loop,
265
showControls: showControls,
266
autoInitialize: true,
267
+ aspectRatio: _width / _height,
268
),
269
270
);
0 commit comments