Skip to content

Releases: jiuyang5354/bilibili-margin

v0.48.0

Choose a tag to compare

@github-actions github-actions released this 03 Nov 03:19
  • 实验功能「App 推荐流」(设置 → 实验功能,默认关):首页「推荐」改用手机 B 站 App 的推荐接口;用 B 站 App 扫一次码授权后,推荐和手机上是同一套个性化结果,不授权时是不带个性化的 App 推荐。卡片上的「不感兴趣」和屏蔽 UP 主会反馈给 App 推荐。授权凭证只存在本机,随时可以取消。接口与扫码流程参考 bilibili-API-collect 与 BewlyBewly「授权 App」(MIT),原生重写。
  • 实验功能「X 式重排」(默认关):照 X 开源推荐的召回 → 打分 → 过滤三段,在本机给首页推荐重新排序:常看完的 UP 往前,秒退(不到 10 秒)和点过「不感兴趣」的往后;每批混入最多 3 条关注的人 48 小时内的新稿(卡片标「关注 · 新稿」);看过的视频不再出现,同一个 UP 不连着出。偏好只从 B 站自己的观看历史读(6 小时缓存),负反馈存在本机,可以和 App 推荐流一起用。
  • 合并 PR #10(@zwh-study):设置里新增「减少动画」、全站屏蔽词(搜索页、播放页推荐、热门 / 排行 / 番剧也生效)、全局宽屏模式、隐藏广告(默认开,只做展示层)、首页版块顺序、消息提醒开关。
  • 修复:打开视频时开头约 1 秒会播两遍。原因是播放页的卡片底板在 B 站页面水合(SSR → Vue 接管)之前插进了左栏,Vue 判定 DOM 不匹配、整页重新渲染,播放器被重建一次;现在等水合完成再插。感谢 @K-aloy 反馈。
  • 首页「换一批」旁边新增「上一批」:刷走了可以回到刚才那批,再点一次又回来。感谢 @K-aloy 建议,也回应 @我是真的小心眼 的反馈。
  • 背景新增「随机范围」:随机模式只在点亮的样式里挑,太花的点掉就不会再随机到。感谢 @K-aloy 建议。
  • 消息:回复我的 / @ 我的,先显示「你的评论」引用(左侧细线),再显示对方的话,短句不再像两句不同字号的回复;私信面板铺满到窗口底部,小屏不再整页滚动。感谢 @K-aloy 反馈。
  • 修复:网页全屏时滚轮调不了音量、反而滚动页面(v0.43「网页全屏可滚动」带来的)。现在播放器铺满屏幕时,在画面上滚轮照常调音量;鼠标放在底部控制栏那一条再滚,或者已经滚下去看评论时,只滚页面、不再顺手改音量。感谢 @bgbfbfb 反馈。
  • 修复:长按点赞三连,进度环转满就松手时只转了一圈、没有三连。映间的环 1.5 秒就画满,B 站自己的长按要更久才触发;现在环满后会先替你「按住」,等 B 站三连生效(最多 2.5 秒)再松开。感谢 @阿埋为爱拉磨中 反馈。
  • 修复:消息角标偶尔永远剩一条关不掉。未读数改用和 B 站网页顶栏相同的新接口(旧接口失败时再回退)。感谢 @-九条泷川- 反馈。
  • 新增 app.bilibili.com 主机权限:App 推荐接口不允许网页跨域,只能从扩展后台请求;功能关闭时不发请求。

  • Experimental "App feed" (Settings → Experimental, off by default): the home Recommended tab uses the Bilibili mobile app's recommendation API. Scan a QR code once with the Bilibili app to get the same personalised feed as on your phone; without it you get the non-personalised app feed. "Not interested" and blocking an uploader are sent back to the app feed. The token stays on this device and can be revoked any time. API and QR flow based on bilibili-API-collect and BewlyBewly's "Authorize app" (MIT), reimplemented natively.
  • Experimental "X-style rerank" (off by default): following the candidate → scoring → filtering stages of X's open-source recommender, home recommendations are reordered on this device: uploaders you finish watching move up, quick exits (under 10 s) and "Not interested" move down; each batch mixes in up to 3 videos from people you follow posted in the last 48 hours (tagged "Following · new"); watched videos are dropped and the same uploader never appears twice in a row. Preferences come only from Bilibili's own watch history (cached for 6 hours); negative feedback stays local. Works together with the App feed.
  • Merged PR #10 (@zwh-study): Reduce motion, global block words (search, watch-page recommendations, popular / ranking / bangumi too), global wide mode, hide ads (on by default, display only), home section order, and a message reminder toggle.
  • Fix: the first ~1 s of a video played twice on open. The watch-page card backdrop was inserted into the left column before Bilibili's SSR page finished hydrating, so Vue saw a DOM mismatch, re-rendered the page and rebuilt the player; it now waits for hydration. Thanks to @K-aloy for the report.
  • Home: a "Previous batch" button next to "Refresh" brings back the batch you just replaced (click again to go forward). Thanks to @K-aloy for suggesting it, and to @我是真的小心眼 for the feedback.
  • Background: new "Random pool" — random mode only picks from the styles you keep lit. Thanks to @K-aloy for suggesting it.
  • Messages: replies / mentions show your quoted comment first (thin left rule) and then their reply, so short lines no longer look like two replies; the DM panel now fills to the bottom of the window. Thanks to @K-aloy for the feedback.
  • Fix: in web fullscreen the mouse wheel scrolled the page instead of changing volume (side effect of v0.43's scrollable web fullscreen). While the player fills the screen, the wheel over the picture changes volume as usual; over the bottom control strip, or once you have scrolled down to the comments, it only scrolls and no longer touches the volume. Thanks to @bgbfbfb for the report.
  • Fix: long-pressing Like for the triple action only spun the ring once if you let go as soon as it filled. Margin's ring fills in 1.5 s but Bilibili's own long press needs longer; once the ring is full Margin now keeps the press held until Bilibili's triple lands (up to 2.5 s). Thanks to @阿埋为爱拉磨中 for the report.
  • Fix: the message badge could keep one unread that never cleared. Unread counts now use the same newer endpoint as Bilibili's own header (falling back to the old one). Thanks to @-九条泷川- for the report.
  • New host permission app.bilibili.com: the app feed API has no CORS, so it is requested from the extension's background worker; nothing is requested while the feature is off.

v0.47.4

Choose a tag to compare

@github-actions github-actions released this 02 Nov 14:56
  • 私信:聊天里的图片点一下在页内打开大图,← → 切换,Esc 关闭;Ctrl 点击仍在新标签打开原图。
  • 评论区:回车直接发送,Shift + 回车换行;输入法选字中、正在输入 @ 时不发送。
  • 设置:不常改的项目收进抽屉(字体与缩放、布局与细节、顶栏入口、视频 CDN 节点、天气城市与卡片信息、背景强度与自定义图片、播放量与时长),收起时右侧显示当前值。设计参考 21st「Accordion」(coss.com) 与「Disclosure」(hero_ui)。

  • Messages: images in a chat open in an in-page lightbox (← → to switch, Esc to close); Ctrl-click still opens the original in a new tab.
  • Comments: Enter sends, Shift + Enter adds a line; never sends while an IME is composing or an @ mention is being typed.
  • Settings: rarely changed options moved into collapsible drawers that show the current value when closed. Design reference: 21st "Accordion" (coss.com) and "Disclosure" (hero_ui).

v0.47.3

Choose a tag to compare

@github-actions github-actions released this 02 Nov 13:48

GitHub issue 修复:

  • #6 稍后再看 / 收藏夹播放页:标题不再被顶栏盖住;点了「原版」以后,左下角会出现「回到映间」,点一下就能切回来。
  • #9 顶栏「动态」弹窗:往下滚会继续加载,不再固定显示 8 条。
  • #8 动态页:点小图在页内打开图组,可以用 ← → 切换,下方有缩略图条,也能打开原图;超过 8 行的长动态默认折叠;整张卡片都能点进详情;屏蔽关键词和屏蔽 UP 也作用于动态页;详情页评论区「最热 / 最新」不再贴着标签栏。

GitHub issues:

  • #6 Watch-later / playlist pages: title no longer hidden under the header; after switching to the native page a "Back to MARGIN" pill appears.
  • #9 Header "Dynamics" popover loads more on scroll instead of a fixed 8.
  • #8 Feed: in-page image viewer with ← → and thumbnails, long posts fold, whole card opens the detail, keyword / uploader blocklist applies to the feed, comment sort tabs on detail pages no longer touch the tab bar.

v0.46.0

Choose a tag to compare

@github-actions github-actions released this 01 Nov 15:15
  • 首页卡片新增「不感兴趣」(B 站评论:点了不喜欢还一直推):悬停卡片左上角 × 或右键菜单,卡片立刻淡出,同时用 B 站首页自己的反馈接口告诉推荐算法,可撤销(撤销会一并取消反馈)。「屏蔽 UP」也会顺带告诉 B 站「不想看此 UP 主」。接口参数照 B 站首页源码里的 feedback/dislike 调用。
  • 修复消息中心点开消息后红点不立即消失(B 站评论):点开私信会话时发送已读(update_ack),点开回复 / @ / 赞 / 系统通知后左侧未读数立刻清零、系统通知推进已读游标,顶栏消息角标随即刷新。
  • 「颗粒」背景不再像电视雪花(B 站评论,34 寸带鱼屏):颗粒以前每帧重新随机,改为固定在屏幕像素上,强度减半;实测帧间闪动从 1.03 降到 0.07。
  • 设置「外观」新增「标题字体」:衬线(宋体,默认)/ 无衬线(黑体),首页、接管页和换皮页一起换(B 站评论)。
  • 设置「外观」新增「账号卡片可拖拽」:关掉后头像下的卡片固定挂着,不能甩动,点一下仍可翻面(B 站评论)。
  • 卡片悬停按钮去掉毛玻璃,改为半透明实底,少一层模糊。

同时包含 v0.45.0(收藏夹性能优化)

  • 收藏夹侧板大幅减负:实测滚动时每帧合成耗时约 13ms → 4.5ms,悬停文件夹约 16ms → 10ms,播放页上悬停约 18ms → 8ms。最大的开销是侧板自己的毛玻璃(backdrop-filter)——身后的动态背景或正在播放的视频每变一帧,820px 宽的整块区域都要重新模糊一遍;收藏夹侧板和播放页的侧板改为实底(原本就是 90% 不透明,观感几乎不变)。
  • 任何侧板(设置、收藏夹)打开时动态背景和天气动画定格,身后不再每帧变化。
  • 文件夹悬停视差不再改根节点上的 CSS 变量(会让整个文件夹连同模糊副本一起重算样式),改为直接移动那几层;高光改为平移而不是重画渐变。悬停时的样式重算约减半。
  • 思路参考 GitHub 上的同类修复:Slush97/grimoire#264(去掉网格卡片里的 backdrop-blur,GPU 耗时 956ms → 31ms)、vuejs/vitepress#1049、nextcloud/server#45452(用实底或预模糊代替实时模糊)。

v0.44.0

Choose a tag to compare

@github-actions github-actions released this 01 Nov 13:35
  • 加载更快:播放页映间自身的脚本耗时从约 650ms 降到约 240ms,首页从约 450ms 降到约 340ms。去掉了几处加载时的强制重排:日月开关首次设置(约 160ms)、设置面板里分段控件的测量(约 110ms,面板关着时不再量)、二维码改到空闲时生成、液态玻璃位移图同尺寸只算一次。
  • 滚动更顺:播放页滚动时映间脚本耗时从约 440ms 降到约 150ms。顶栏小电视的眼睛不再在每次鼠标移动和动画帧里读布局;右侧滚动刻度尺不在滚动事件里读页面高度,刻度只更新变化的几根;播放页卡片底板不再每 1.5 秒主动测量一次。
  • 背景画布、足迹热力图的尺寸改由 ResizeObserver 提供,不再额外触发排版。
  • 其他页面加载也更轻:空间页映间脚本耗时约 2.1s → 0.5s,动态页约 1.5s → 0.45s,历史页约 1.3s → 0.45s,搜索页约 1.2s → 0.6s(沙盒软件渲染下的相对对比)。设置面板改为第一次打开时才建(约 220 个节点);账号卡片改为第一次悬停头像时才建,也不再在加载时下载两张大头像;分段控件只在布局完成后的回调里测量;顶栏小电视的颜色改在布局完成后读取;图标解析一次后克隆复用。

  • Faster load: MARGIN's own script time on the watch page drops from ~650 ms to ~240 ms, home from ~450 ms to ~340 ms. Removed forced reflows during load: the sun/moon switch's first paint (~160 ms), segmented controls measuring inside the closed settings sheet (~110 ms), QR codes now drawn when idle, liquid-glass maps computed once per size.
  • Smoother scrolling: script time while scrolling the watch page drops from ~440 ms to ~150 ms. The header TV eyes no longer read layout on every pointer move and frame; the scroll ruler stops reading page height inside scroll events and only updates the ticks that change; the watch card underlay no longer re-measures every 1.5 s.
  • Background canvas and footprint heatmap sizes now come from ResizeObserver instead of extra layout reads.
  • Lighter loads on other pages too: MARGIN script time on space ~2.1 s → 0.5 s, feed ~1.5 s → 0.45 s, history ~1.3 s → 0.45 s, search ~1.2 s → 0.6 s (relative, sandbox software rendering). The settings sheet is built on first open (~220 nodes); the account card is built on first avatar hover and no longer downloads two large avatars at load; segmented controls measure only in post-layout callbacks; the header TV reads its color after layout; icons are parsed once and cloned.

v0.43.0

Choose a tag to compare

@github-actions github-actions released this 01 Nov 12:19
  • 设置「首页顶部」改为「首页组件」:搜索框、日期栏、换一批按钮可以单独隐藏;隐藏搜索框后顶栏的小搜索框会回来(B 站评论建议)。
  • 新增「卡片信息」:首页视频卡片的 UP 主、播放、弹幕、发布时间、时长、推荐理由可以逐项开关,分隔点自动跟着变。
  • 减少卡顿:播放视频时、网页全屏 / 全屏时动态背景定格,GPU 留给视频解码和弹幕;滚动时背景暂停;滚过首屏后背景降到 30 帧;滚动中天气卡也暂时去掉毛玻璃;关着的设置 / 收藏夹侧板不再参与合成。
  • 顶栏新增「分区」入口:悬停展开番剧、国创、电影、动画、游戏、知识等 24 个分区,点图标直达番剧(B 站评论建议)。
  • 新增「播放页」设置:自动网页全屏(默认关);网页全屏时可滚动(默认开),往下滚就能看评论,播放器跟着滚走,按 Esc 退出(B 站评论建议)。

  • Settings "Home top" becomes "Home components": hide the search box, date row or refresh button individually; hiding the big search brings back the header search.
  • New "Card info": toggle uploader, views, danmaku, publish time, duration and recommendation reason on home video cards; separators follow automatically.
  • Less stutter: the animated background freezes while a video plays and in web/full screen, pauses while scrolling, and drops to 30 fps below the first screen; the weather card drops its blur while scrolling; closed settings/favorites sheets no longer take part in compositing.
  • New header "Zones" entry: hover for 24 Bilibili zones (anime, guochuang, movies, animation, games, knowledge…).
  • New "Watch page" settings: auto web fullscreen (off by default); scrollable web fullscreen (on by default) — scroll down to the comments while the player scrolls away, Esc exits.

v0.42.2

Choose a tag to compare

@github-actions github-actions released this 01 Nov 10:57
  • 修复足迹热力图最后一列的月份标签(如「11月」)被挤成两行、压在今天的格子上。
  • 顶栏「收藏夹」弹窗里点「全部收藏」直接在当前页打开收藏夹面板,不再新开页面。

  • Fix the footprint heatmap's last month label (e.g. "11月") wrapping onto today's cell.
  • "All favorites" in the header favorites popover opens the favorites panel in place instead of a new tab.

v0.42.1

Choose a tag to compare

@github-actions github-actions released this 01 Nov 10:40
  • 修复网页全屏时右栏(UP 主卡片、弹幕列表、推荐视频)盖在播放器上面;网页全屏下顶栏也会让开。

  • Fix web-fullscreen player being covered by the right column (uploader card, danmaku list, recommendations); header hides in web fullscreen.

v0.42.0

Choose a tag to compare

@github-actions github-actions released this 01 Nov 10:30
  • 播放器控制栏恢复 B 站原版(撤回 v0.40.0 的浮动玻璃控制坞),画面里的播放量 · 弹幕数胶囊一并去掉。
  • 视频卡片信息行加入弹幕数:UP 主 · 播放 · 弹幕 · 时间;卡片太窄时先收起时间,数字不被挤掉(B 站评论建议)。
  • 设置新增「首页每行视频」:自动(按窗口 6–8 个)/ 4 个 / 5 个(B 站评论建议)。
  • 收藏夹「全部播放」、稍后再看播放列表(/list/…)套用播放页样式。
  • 顶栏悬停弹窗(直播、消息、动态、历史、收藏、稍后再看)去掉 1.5 秒延迟,鼠标放上去立即展开。

  • Player control bar back to Bilibili's original (v0.40.0 floating glass dock removed), in-video views · danmaku chip removed.
  • Video cards show danmaku count: uploader · views · danmaku · time; time hides first on narrow cards.
  • New setting "Videos per row" on home: auto (6–8 by width) / 4 / 5.
  • Favorites "play all" and watch-later playlists (/list/…) use the watch page styling.
  • Header hover popovers (live, messages, feed, history, favorites, watch later) open instantly, no 1.5s delay.

v0.41.0

Choose a tag to compare

@github-actions github-actions released this 01 Nov 10:09
  • 播放页「一张卡片」(参考 21st Post Card,shadcnui-blocks):播放器、弹幕发送栏、点赞投币收藏、简介和标签合成一张表面卡片,播放器贴卡片顶边,下方内容内缩 20px。
  • 视频画面左下角新增播放量 · 弹幕数胶囊,和控制坞同一套暗色玻璃,随控制坞出现和收起。
  • 弹幕发送栏恢复跟随主题(撤回 v0.40.1 的深色机身),保留去掉白线和胶囊输入框。
  • 动态:开播提醒和直播间分享现在会显示封面、标题、分区和人气,带「直播中」标记;合集、番剧、课程、音乐等卡片类动态不再空白。
  • 动态页、UP 主空间的视频封面支持悬停静音预览;首页、空间、动态的视频封面右上角加「稍后再看」按钮(屏蔽按钮移到左上)。
  • 动态页左栏限高到视口内、可单独滚动,「正在直播」不再被截掉,并列出全部开播的人。
  • 私信:通知、分享、活动等卡片消息完整显示(标题、正文、封面、明细、跳转);对方消息左侧显示头像;对话区更宽、左侧导航更窄;系统账号用占位图标。
  • 历史记录:UP 主名可点进空间;新增「时间线 / 网格」两种排版,网格接近原版、一屏看更多。
  • 播放页:UP 主悬停名片换成映间风格;侧栏推荐卡封面上下居中;快捷菜单按 Shift 不再出现蓝线,展开后顶部不再空一截。
  • 设置:新增「天气城市」,输入后从候选里选(带省份 / 国家),也能一键回到自动定位。

  • Watch page "one card" (after 21st Post Card, shadcnui-blocks): player, danmaku bar, actions, description and tags share one surface.
  • Views · danmaku count chip inside the video, shown with the control dock.
  • Sending bar follows the theme again (reverts v0.40.1 dark body).
  • Feed: live notices and live-room shares render (cover, title, area, popularity, LIVE badge); season / bangumi / course / music / common cards no longer blank.
  • Hover preview on feed and space video covers; "Watch later" button on home, space and feed covers (block button moved top-left).
  • Feed sidebar fits the viewport and scrolls; all live users listed.
  • Whispers: card / notice / share messages shown in full, sender avatar, wider chat.
  • History: uploader name links to their space; new timeline / grid views.
  • Watch: restyled uploader hover card, centered rec thumbnails, quick menu focus line and top gap fixed.
  • Settings: manual weather city with candidates, or back to auto.