Fix styles in history page (fix #4459)

This commit is contained in:
the1812 2023-11-19 17:07:36 +08:00
parent d13865099f
commit d6b079ce1e
3 changed files with 11 additions and 1 deletions

View File

@ -43,6 +43,10 @@ export const entry: ComponentEntry = async ({ metadata: { name } }) => {
true, true,
) )
} }
// https://github.com/the1812/Bilibili-Evolved/issues/4459
if (matchUrlPattern('https://www.bilibili.com/account/history')) {
document.body.classList.add('history-page')
}
const CustomNavbar = await import('./CustomNavbar.vue') const CustomNavbar = await import('./CustomNavbar.vue')
const customNavbar: Vue & { const customNavbar: Vue & {
styles: string[] styles: string[]

View File

@ -32,10 +32,13 @@ li.nav-item[report-id="playpage_dynamic"] .i-frame,
height: var(--navbar-height) !important; height: var(--navbar-height) !important;
} }
#message-navbar, #message-navbar,
#biliMainHeader:not(.z-top-container), body:not(.history-page) #biliMainHeader:not(.z-top-container),
.z-top-container:not(#biliMainHeader) { .z-top-container:not(#biliMainHeader) {
max-height: var(--navbar-height) !important; max-height: var(--navbar-height) !important;
} }
body.history-page #biliMainHeader:not(.z-top-container) {
height: auto;
}
.link-top-container#tab-container { .link-top-container#tab-container {
top: var(--navbar-height) !important; top: var(--navbar-height) !important;
} }

View File

@ -27,6 +27,9 @@ export const checkTransparentFill = async (vm: {
if ((banner as HTMLVideoElement | HTMLImageElement).src) { if ((banner as HTMLVideoElement | HTMLImageElement).src) {
return true return true
} }
if (banner.querySelector('.animated-banner')) {
return true
}
return false return false
} }
if (banners.some(hasBannerImage)) { if (banners.some(hasBannerImage)) {