Merge branch 'preview-fixes' of https://github.com/the1812/Bilibili-Evolved into preview-fixes

This commit is contained in:
the1812 2024-03-09 18:50:42 +08:00
commit 9d6e11452b
4 changed files with 10 additions and 3 deletions

View File

@ -32,6 +32,9 @@ const entry = async () => {
if (target.hasAttribute('click-title')) {
return
}
if (target.hasAttribute('data-pics')) {
return
}
if (
[
'bili-rich-text__action',

View File

@ -141,6 +141,9 @@ const entry = async () => {
url: string,
...restArgs: unknown[]
) {
if (url === undefined || url === null) {
return original.call(this, data, unused, url, ...restArgs)
}
const resolvedUrl = (() => {
try {
return new URL(url, location.origin + location.pathname).toString()

View File

@ -7,7 +7,8 @@ import { DownloadVideoOutput } from '../../../../components/video/download/types
export const plugin: PluginMetadata = {
name: 'downloadVideo.outputs.idm',
displayName: '下载视频 - IDM 输出支持',
description: '为下载视频增加 IDM 输出支持.',
description:
'为下载视频增加 IDM 输出支持,建议配合 [ef2.exe](https://github.com/MotooriKashin/ef2) 以简化操作、保留文件名.',
setup: ({ addData }) => {
addData('downloadVideo.outputs', (outputs: DownloadVideoOutput[]) => {
outputs.push({

View File

@ -95,11 +95,11 @@ export abstract class PlayerAgent
}
// 关灯状态 && 要开灯 -> 开灯
if (on && isCurrentLightOff) {
this.nativeApi.setLightOff(true)
this.nativeApi.setLightOff(false)
return true
}
if (!on && !isCurrentLightOff) {
this.nativeApi.setLightOff(false)
this.nativeApi.setLightOff(true)
return false
}
return null