Skip to content

Can't play video when calling openLightboxModal event #97

Description

@chanhnv91

Screen Shot 2021-08-25 at 02 40 49

I get an error like the picture attached when I click on the thumbnail to open the video. Here is my code:
              _.each(element.files, function (file) {
                    var r = new FileReader();
                    r.onload = function (e) {
                        if (!vm.fileContainers) vm.fileContainers = [];
                        var newFileContainer = {
                            name: file.name,
                            type: file.type.split('/')[0],
                            url: this.result
                        };
                        vm.fileContainers.push(newFileContainer);
                        $scope.$apply();
                        vm.changeEvent(vm.fileContainers);
                    }
                    r.readAsDataURL(file);
                })
       function openLightboxModal(imageContainers, index) {
          
                Lightbox.openModal(imageContainers, index);
        };

Thanks

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions