Skip to content

Conversation

@bernaskino
Copy link
Contributor

@bernaskino bernaskino commented Oct 11, 2024

Summary:

Autoplay seemed to not work correctly because some props were missing. Adding autoPlay, playsinline and autoPlayMode as props resolved the problem

Types of changes

  • Bug fix (a non-breaking change which fixes an issue)
  • New feature (a non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Description

I added the followings props to CldVideoPlayer:

  • autoPlay?: boolean
  • autoplayMode?: "never" | "always" | "on-scroll";
  • playsinline?: boolean; (needed for iOS devices to autoplay videos)

I changed autoplayMode from a string to a union of the possible values.
Made also autoplayMode default value always so videos autoPlay correctly just by passing autoPlay = true.

Resolves:#242

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes (if not applicable, please state why)

@netlify
Copy link

netlify bot commented Oct 11, 2024

👷 Deploy request for nuxt-cloudinary-module pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 58c6099

@bernaskino
Copy link
Contributor Author

It seems that my prettier formatting was a bit different and unintentionally added colons and double quotes :/
I am so happy, this is my first pull request!

@Baroshem
Copy link
Collaborator

Baroshem commented Oct 11, 2024

Hey there,

Thanks for this amazing work! You did a great job.
About linting. Could you run pnpm run lint --fix in your project and then commit the changes? It should help :)

@bernaskino
Copy link
Contributor Author

Hi Baroshem, thank you again! :)
I tried also to update the docs to reflect the changes.

@Baroshem
Copy link
Collaborator

Hey Buddy, thank you for this change!

I will merge it to 4.0.0 branch and release a bigger major version at the start of next month (after all the goodies from hacktoberfest :) )

@Baroshem Baroshem changed the base branch from main to chore/4.0.0 October 15, 2024 09:28
@Baroshem Baroshem merged commit 68e27c2 into nuxt-modules:chore/4.0.0 Oct 15, 2024
@colbyfayock
Copy link
Collaborator

@Marcos-Bernasconi thanks for your contribution. this PR is eligible for free Cloudinary Hackatoberfest swag. Please send me an email at hacktoberfest@cloudinary.com with your name, GitHub username, and a link to the PR where I'll send further instructions.

Happy Hacktoberfest!

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants