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

Video component #4

Closed
jxnblk opened this issue Jul 29, 2018 · 10 comments
Closed

Video component #4

jxnblk opened this issue Jul 29, 2018 · 10 comments
Labels
enhancement New feature or request

Comments

@jxnblk
Copy link
Owner

jxnblk commented Jul 29, 2018

For videos etc.

@busypeoples
Copy link
Contributor

What should these component specifically do? Wouldn't using a provided embed code suffice?

@jxnblk
Copy link
Owner Author

jxnblk commented Aug 4, 2018

I think we'll want a scalable/resizable version, something like this but for fullscreen: https://github.com/jxnblk/rebass/blob/master/src/Embed.js

@jxnblk
Copy link
Owner Author

jxnblk commented Aug 5, 2018

A more video-centric extension of this could also have an autoplay attribute, hook into the SlideDeck context and start playing when the slide comes into view – and pause when the slide leaves the view

@trevordmiller
Copy link

This will be awesome. I really like the included fullscreen Image component - having one for videos would be very helpful. Thanks for such a great library!

@SaraVieira
Copy link
Contributor

@jxnblk The link to rebass no longer works :(

@jxnblk
Copy link
Owner Author

jxnblk commented Sep 16, 2018

Updated Rebass link: https://rebass-v2.now.sh/components/Embed

@jxnblk jxnblk mentioned this issue Sep 30, 2018
@karlhorky
Copy link
Contributor

karlhorky commented Mar 6, 2019

For now, this seems to be a workaround (dangerouslySetInnerHTML for autoplay with muted in Chrome, see facebook/react#10389):

import screencapture from './screencapture.mp4';

<div
  dangerouslySetInnerHTML={{
    __html: `
      <video
        style="max-width: 80%"
        controls
        autoplay
        muted
        src="${screencapture}"
      />
    `,
  }}
/>

Older versions of mdx-deck don't use the import:

<div
  dangerouslySetInnerHTML={{
    __html: `
      <video
        style="max-width: 80%"
        controls
        autoplay
        muted
        src="./screencapture.mp4"
      />
    `,
  }}
/>

@jxnblk jxnblk changed the title Embed component Video component Apr 20, 2019
@jxnblk jxnblk closed this as completed Jul 17, 2019
@karlhorky
Copy link
Contributor

@jxnblk Why was this closed? Has this been implemented in v3?

@jxnblk
Copy link
Owner Author

jxnblk commented Jul 20, 2019

I has not been implemented, but I'm planning on opening a new issue with a clearer specification

@karlhorky
Copy link
Contributor

Ok sounds good, thanks for the info.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants