From 003e4a08d5c9af1e387a9d95ac3f79df813e9b45 Mon Sep 17 00:00:00 2001 From: Lumap Date: Sat, 10 Aug 2024 16:39:33 +0200 Subject: [PATCH] fix PictureInPicture (#2773) Co-authored-by: v --- src/plugins/pictureInPicture/index.tsx | 6 +++--- src/utils/constants.ts | 10 +++++----- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/plugins/pictureInPicture/index.tsx b/src/plugins/pictureInPicture/index.tsx index 81d75a256..20cedf45b 100644 --- a/src/plugins/pictureInPicture/index.tsx +++ b/src/plugins/pictureInPicture/index.tsx @@ -24,13 +24,13 @@ const settings = definePluginSettings({ export default definePlugin({ name: "PictureInPicture", description: "Adds picture in picture to videos (next to the Download button)", - authors: [Devs.Nobody], + authors: [Devs.Lumap], settings, patches: [ { - find: ".nonMediaMosaicItem]", + find: ".removeMosaicItemHoverButton),", replacement: { - match: /\.nonMediaMosaicItem\]:!(\i).{0,50}?children:\[(\S)/, + match: /\.nonMediaMosaicItem\]:!(\i).{0,50}?children:\[\S,(\S)/, replace: "$&,$1&&$2&&$self.renderPiPButton()," }, }, diff --git a/src/utils/constants.ts b/src/utils/constants.ts index 35525cd17..febb8f9af 100644 --- a/src/utils/constants.ts +++ b/src/utils/constants.ts @@ -33,10 +33,6 @@ export interface Dev { * If you are fine with attribution but don't want the badge, add badge: false */ export const Devs = /* #__PURE__*/ Object.freeze({ - Nobody: { - name: "Nobody", - id: 0n, - }, Ven: { name: "Vee", id: 343383572805058560n @@ -545,7 +541,11 @@ export const Devs = /* #__PURE__*/ Object.freeze({ surgedevs: { name: "Chloe", id: 1084592643784331324n - } + }, + Lumap: { + name: "Lumap", + id: 585278686291427338n, + }, } satisfies Record); // iife so #__PURE__ works correctly