From 1e5c3127c7571846a46b2782da0f92c1efab9270 Mon Sep 17 00:00:00 2001 From: Cadence Ember Date: Thu, 18 Jun 2020 01:58:06 +1200 Subject: [PATCH] Add invidious embed links --- .../components/ft-share-button/ft-share-button.js | 14 +++++++++++++- .../components/ft-share-button/ft-share-button.vue | 14 ++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/src/renderer/components/ft-share-button/ft-share-button.js b/src/renderer/components/ft-share-button/ft-share-button.js index 764ed906..9a1355ff 100644 --- a/src/renderer/components/ft-share-button/ft-share-button.js +++ b/src/renderer/components/ft-share-button/ft-share-button.js @@ -40,6 +40,10 @@ export default Vue.extend({ return `${this.invidiousInstance}/watch?v=${this.id}` }, + getInvidiousEmbedURL() { + return `${this.invidiousInstance}/embed/${this.id}` + }, + getYoutubeURL() { return `https://www.youtube.com/watch?v=${this.id}` }, @@ -70,6 +74,14 @@ export default Vue.extend({ copyYoutubeEmbed() { this.copy(this.getYoutubeEmbedURL()) - } + }, + + openInvidiousEmbed() { + this.open(this.getInvidiousEmbedURL()) + }, + + copyInvidiousEmbed() { + this.copy(this.getInvidiousEmbedURL()) + }, } }) diff --git a/src/renderer/components/ft-share-button/ft-share-button.vue b/src/renderer/components/ft-share-button/ft-share-button.vue index b0bf59b4..ae9a67c9 100644 --- a/src/renderer/components/ft-share-button/ft-share-button.vue +++ b/src/renderer/components/ft-share-button/ft-share-button.vue @@ -60,6 +60,20 @@ Open link + + + Copy embed + + + + Open embed +