From bff76a65b022fd115b60b355933656cd606031dd Mon Sep 17 00:00:00 2001 From: the1812 Date: Mon, 14 Mar 2022 09:07:33 +0800 Subject: [PATCH 01/18] Fix avatar pendant (fix #3119) --- .../lib/components/style/simplify/live/live.scss | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/registry/lib/components/style/simplify/live/live.scss b/registry/lib/components/style/simplify/live/live.scss index f931cb304..4612282b8 100644 --- a/registry/lib/components/style/simplify/live/live.scss +++ b/registry/lib/components/style/simplify/live/live.scss @@ -47,9 +47,23 @@ $prefix: "simplifyLiveroom-switch"; display: flex !important; padding: 10px 24px 10px 12px !important; height: auto !important; + + .blive-avatar-icons, .face-pendants { display: none !important; } + // .blive-avatar-icons { + // right: -2px !important; + // .blive-avatar-icon { + // width: 12px !important; + // height: 12px !important; + // border-width: 1px !important; + // } + // } + .blive-avatar-pendant { + width: 48px !important; + height: 48px !important; + } .blive-avatar-face, .blive-avatar, .avatar { From 0b45a3862c57460b285e5dd75e26ac1d112eba48 Mon Sep 17 00:00:00 2001 From: the1812 Date: Mon, 14 Mar 2022 20:35:48 +0800 Subject: [PATCH 02/18] Fix number validator (fix #3120) --- src/core/utils/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/utils/index.ts b/src/core/utils/index.ts index 2cdb99347..834c328d8 100644 --- a/src/core/utils/index.ts +++ b/src/core/utils/index.ts @@ -472,6 +472,6 @@ export const disableWindowScroll = async (action?: () => unknown | Promise ( (value: number, oldValue: number) => ( - lodash.isNumber(value) ? lodash.clamp(value, clampLower, clampUpper) : oldValue + lodash.isNumber(Number(value)) ? lodash.clamp(value, clampLower, clampUpper) : oldValue ) ) From 2ef5779b41d63a060306cf10345c62fcaa8ed134 Mon Sep 17 00:00:00 2001 From: the1812 Date: Mon, 14 Mar 2022 23:33:15 +0800 Subject: [PATCH 03/18] Fix update url (fix #3122) --- src/components/notify-new-version/index.ts | 7 +++++-- src/core/meta.ts | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/components/notify-new-version/index.ts b/src/components/notify-new-version/index.ts index 49041a22f..4020647b4 100644 --- a/src/components/notify-new-version/index.ts +++ b/src/components/notify-new-version/index.ts @@ -1,3 +1,4 @@ +import { cdnRoots } from '@/core/cdn-types' import { ComponentMetadata, componentsTags } from '../types' export const component: ComponentMetadata = { @@ -24,15 +25,17 @@ export const component: ComponentMetadata = { const { monkey } = await import('@/core/ajax') const { meta } = await import('@/core/meta') const { Toast } = await import('@/core/toast') + const { getGeneralSettings } = await import('@/core/settings') const now = Number(new Date()) const duration = now - options.lastUpdateCheck if (duration < options.minimumDuration) { // 未到间隔期 return } - const updateUrl = GM_info.scriptUpdateURL - if (!updateUrl) { // 本地调试版没有 updateUrl + // 本地调试版不检查 + if (!GM_info.scriptUpdateURL) { return } + const updateUrl = `${cdnRoots[getGeneralSettings().cdnRoot](meta.compilationInfo.branch)}dist/${meta.originalFilename}` const scriptText: string = await monkey({ url: updateUrl, responseType: 'text' }) options.lastUpdateCheck = Number(new Date()) const versionMatch = scriptText.match(/^\/\/ @version\s*([\d\.]+)$/m) diff --git a/src/core/meta.ts b/src/core/meta.ts index d0fc64a85..bd5ada697 100644 --- a/src/core/meta.ts +++ b/src/core/meta.ts @@ -24,7 +24,7 @@ export const meta = { if (branch === branches.stable) { return 'bilibili-evolved.user.js' } - return `bilibili-evolved.${branch}.user.js` + return `bilibili-evolved.${branches.preview}.user.js` }, /** 检查更新的链接 */ get updateURL(): string { From 7b9b0b704a4f098620604ad70a731d1533435050 Mon Sep 17 00:00:00 2001 From: the1812 Date: Tue, 15 Mar 2022 09:54:55 +0800 Subject: [PATCH 04/18] Fix bangumi link (fix #3123) --- .../video/bvid-convert/BvidConvert.vue | 40 +++++++++++++------ 1 file changed, 27 insertions(+), 13 deletions(-) diff --git a/registry/lib/components/video/bvid-convert/BvidConvert.vue b/registry/lib/components/video/bvid-convert/BvidConvert.vue index 8d2804ac3..ec9615050 100644 --- a/registry/lib/components/video/bvid-convert/BvidConvert.vue +++ b/registry/lib/components/video/bvid-convert/BvidConvert.vue @@ -20,6 +20,8 @@