Skip to content

[6.x] Support more video providers, including Cloudflare Stream#11871

Open
edalzell wants to merge 38 commits into
statamic:6.xfrom
edalzell:feature/add-cf-to-video-fieldtype
Open

[6.x] Support more video providers, including Cloudflare Stream#11871
edalzell wants to merge 38 commits into
statamic:6.xfrom
edalzell:feature/add-cf-to-video-fieldtype

Conversation

@edalzell

Copy link
Copy Markdown
Contributor

@godismyjudge95

Copy link
Copy Markdown
Contributor

Might be worthwhile doing something similar to what I did with the embera tag - https://github.com/godismyjudge95/statamic-embera

Embera is a oembed client that takes in a video url and spits out an iframe. It has a decent number of video providers supported - https://github.com/mpratt/Embera/blob/master/doc/02-providers.md

@edalzell

Copy link
Copy Markdown
Contributor Author

Might be worthwhile doing something similar to what I did with the embera tag - godismyjudge95/statamic-embera

This is a really nice idea. I'll chat w/ the team on how they'd like to approach, as it's another dependency.

@duncanmcclean duncanmcclean changed the base branch from ui to master June 30, 2025 18:42
@edalzell

edalzell commented Jul 1, 2025

Copy link
Copy Markdown
Contributor Author
  • 3 fields - url for pasting, dropdown for provider, video id
  • if you paste into the url, we'll extract the id and populate provider/id
  • save the provider/id

for augmenting maybe...

  • have a Video class with provider and id
  • the Video class would know how to get the regular and embed urls
  • __toString could output the non-embed url so {{ video_field }} on its own would continue to work
  • the embed_url modifier could handle a Video instance, so it could get the embed url from that

for backwards compat...

  • if your field has a url, it doesnt get augmented to a Video instance. it stays as a string.

@edalzell edalzell marked this pull request as ready for review July 9, 2025 22:13
@edalzell edalzell requested a review from jasonvarga July 9, 2025 22:13

@duncanmcclean duncanmcclean left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like some of the tests are failing. Are you able to take a look?

@edalzell

Copy link
Copy Markdown
Contributor Author

It looks like some of the tests are failing. Are you able to take a look?

Done

@jasonvarga jasonvarga changed the base branch from master to 6.x January 28, 2026 16:32
@edalzell edalzell requested a review from duncanmcclean March 19, 2026 22:44
@edalzell edalzell requested a review from a team as a code owner June 9, 2026 20:51
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