Skip to content
This repository was archived by the owner on Feb 6, 2024. It is now read-only.

feat(youtube): add toggle method #51

Merged
merged 1 commit into from
Feb 14, 2019

Conversation

natemoo-re
Copy link
Contributor

Adds @Method() toggle to the <deckgo-slide-youtube> component, which alternates between play and pause states.

TODO: post a message from the YouTube iFrame when the video is played/paused, so that <deckgo-slide-youtube> keeps an internal @State() isPlaying in sync with the video. Currently this implementation only works if play, pause, or toggle are called programmatically.

@peterpeterparker peterpeterparker merged commit 92b040d into deckgo:master Feb 14, 2019
peterpeterparker added a commit that referenced this pull request Feb 14, 2019
@peterpeterparker
Copy link
Contributor

peterpeterparker commented Feb 14, 2019

Cool idea and thx for the PR @natemoo-re 👍

After merge I allowed my self to remove the @State() decorator on the state variable as it do not need to trigger a new repaint and also make the playPauseVideo a bit simpler I think (no use of typeof, 2dd98ec)

I also added the new method to the DeckDeckGo docs (not yet published, https://github.com/deckgo/deckdeckgo-docs/commit/84af7e780833a0e7e64cb4ed349752154072e5db)

@natemoo-re natemoo-re deleted the feat-youtube-toggle branch February 14, 2019 13:24
@peterpeterparker peterpeterparker added this to the v1.0.0-beta.27 milestone Feb 15, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
2 participants