Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to pass URLs (and YouTube link!) to st.video #348

Closed
tvst opened this issue Oct 9, 2019 · 2 comments
Closed

Ability to pass URLs (and YouTube link!) to st.video #348

tvst opened this issue Oct 9, 2019 · 2 comments
Assignees

Comments

@tvst
Copy link
Collaborator

@tvst tvst commented Oct 9, 2019

See related post: https://discuss.streamlit.io/t/are-you-using-html-in-markdown-tell-us-why/96/7?u=thiago

And actually we should support the same for st.audio.

For reference, see what we did with st.image, which already supports this. We should reuse the image code and API as much as possible.

@nthmost

This comment has been minimized.

Copy link
Contributor

@nthmost nthmost commented Oct 16, 2019

Here's a draft pull request for this feature:

#423

Currently I don't have it supporting YouTube links. Since that seems like a hugely common use case (I'd totally use it), I'll add that to the PR soon.

@nthmost

This comment has been minimized.

Copy link
Contributor

@nthmost nthmost commented Oct 16, 2019

I added YouTube link support, so you can pass in any style of YouTube link that includes the video code.

I wasn't sure where to put the regular expression part of that equation, so it's in the video part of DeltaGenerator. This makes the video and audio sections significantly different (harder to refactor when it's time to do that), so let me know if there's a better approach I should take.

@nthmost nthmost closed this Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.