aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-08-20 11:46:25 +0200
committerChocobozzz <chocobozzz@cpy.re>2020-08-20 14:23:57 +0200
commitf95628636b6ccdf3eae2449ca718e075b072f678 (patch)
tree35d51980c87b7d6747bdff6e37bdfe37e3c989dc /shared
parenta9f6802e7dac4f21599076bc1119bb6ff16961dc (diff)
downloadPeerTube-f95628636b6ccdf3eae2449ca718e075b072f678.tar.gz
PeerTube-f95628636b6ccdf3eae2449ca718e075b072f678.tar.zst
PeerTube-f95628636b6ccdf3eae2449ca718e075b072f678.zip
Support plugin hooks in embed
Diffstat (limited to 'shared')
-rw-r--r--shared/models/plugins/client-hook.model.ts8
-rw-r--r--shared/models/plugins/plugin-client-scope.type.ts2
2 files changed, 8 insertions, 2 deletions
diff --git a/shared/models/plugins/client-hook.model.ts b/shared/models/plugins/client-hook.model.ts
index b53b8de99..193a3f646 100644
--- a/shared/models/plugins/client-hook.model.ts
+++ b/shared/models/plugins/client-hook.model.ts
@@ -80,7 +80,13 @@ export const clientActionHookObject = {
80 'action:router.navigation-end': true, 80 'action:router.navigation-end': true,
81 81
82 // Fired when the registration page is being initialized 82 // Fired when the registration page is being initialized
83 'action:signup.register.init': true 83 'action:signup.register.init': true,
84
85 // ####### Embed hooks #######
86 // In embed scope, peertube helpers are not available
87
88 // Fired when the embed loaded the player
89 'action:embed.player.loaded': true
84} 90}
85 91
86export type ClientActionHookName = keyof typeof clientActionHookObject 92export type ClientActionHookName = keyof typeof clientActionHookObject
diff --git a/shared/models/plugins/plugin-client-scope.type.ts b/shared/models/plugins/plugin-client-scope.type.ts
index d112434e8..a3c669fe7 100644
--- a/shared/models/plugins/plugin-client-scope.type.ts
+++ b/shared/models/plugins/plugin-client-scope.type.ts
@@ -1 +1 @@
export type PluginClientScope = 'common' | 'video-watch' | 'search' | 'signup' | 'login' export type PluginClientScope = 'common' | 'video-watch' | 'search' | 'signup' | 'login' | 'embed'