Skip to content

WorkBuddy、CodeBuddy 桌面端增强助手:签到猫猫旅行成长计划查询、多账号独立备份、点切即用;免打扰模式让 AI 无人值守跑长任务;跨账号会话迁移、异常中断自动续接;暂存/快捷提示词;毛玻璃主题与更多实用功能。

fix: apply frosted theme patches on Windows

[email protected]acab75f6fa8b
diff --git a/scripts/theme-patches.js b/scripts/theme-patches.js
index 908b8d3..1b65f1c 100644
--- a/scripts/theme-patches.js
+++ b/scripts/theme-patches.js
@@ -493,20 +493,20 @@ module.exports = [
{
id: 'patch-102',
themeId: 'nebula',
- desc: '最新版 mac teams 布局:滚动容器与内部 gridView 的不透明底色会盖住毛玻璃背景,改为透明并移除自身模糊层',
- css: ':is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container.is-mac>.teams-grid-scroll-content,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container.is-mac>.teams-grid-scroll-content>[class*="_grid_"]>[class*="_gridView_"],body[data-vscode-theme-name="IDE Night"] .teams-container.is-mac>.teams-grid-scroll-content,body[data-vscode-theme-name="IDE Night"] .teams-container.is-mac>.teams-grid-scroll-content>[class*="_grid_"]>[class*="_gridView_"]{background:transparent !important;background-color:transparent !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;}',
+ desc: '新版 teams 布局:滚动容器与内部 gridView 的不透明底色会盖住毛玻璃背景,改为透明并移除自身模糊层',
+ css: ':is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container>.teams-grid-scroll-content,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container>.teams-grid-scroll-content>[class*="_grid_"]>[class*="_gridView_"],body[data-vscode-theme-name="IDE Night"] .teams-container>.teams-grid-scroll-content,body[data-vscode-theme-name="IDE Night"] .teams-container>.teams-grid-scroll-content>[class*="_grid_"]>[class*="_gridView_"]{background:transparent !important;background-color:transparent !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;}',
},
{
id: 'patch-103',
themeId: 'nebula',
- desc: '毛玻璃主题下新版 mac teams 主页与会话页发送按钮 tooltip 包装层去掉背景色,避免输入框右侧出现多余色块',
- css: ':is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container.is-mac .cr-input-toolbar__send>span.cr-send-button__tooltip-wrapper,body[data-vscode-theme-name="IDE Night"] .teams-container.is-mac .cr-input-toolbar__send>span.cr-send-button__tooltip-wrapper{background:transparent !important;background-color:transparent !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;}',
+ desc: '毛玻璃主题下新版 teams 主页与会话页发送按钮 tooltip 包装层去掉背景色,避免输入框右侧出现多余色块',
+ css: ':is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container .cr-input-toolbar__send>span.cr-send-button__tooltip-wrapper,body[data-vscode-theme-name="IDE Night"] .teams-container .cr-input-toolbar__send>span.cr-send-button__tooltip-wrapper{background:transparent !important;background-color:transparent !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;}',
},
{
id: 'patch-104',
themeId: 'nebula',
desc: '毛玻璃主题下左侧模板切换按钮与代码块复制提示去掉官方背景色,避免出现实心色块',
- css: ':is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary:hover,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary:focus-visible,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary:active,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .cr-code-like-box__header>span.cr-code-block__copy-tooltip,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .cr-code-like-box__header>span.cr-code-block__copy-tooltip:hover,body[data-vscode-theme-name="IDE Night"] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary,body[data-vscode-theme-name="IDE Night"] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary:hover,body[data-vscode-theme-name="IDE Night"] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary:focus-visible,body[data-vscode-theme-name="IDE Night"] .teams-container.is-mac .industry-template-switcher__host>button.wb-button.wb-button--secondary:active,body[data-vscode-theme-name="IDE Night"] .cr-code-like-box__header>span.cr-code-block__copy-tooltip,body[data-vscode-theme-name="IDE Night"] .cr-code-like-box__header>span.cr-code-block__copy-tooltip:hover{background:transparent !important;background-color:transparent !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;box-shadow:none !important;}',
+ css: ':is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary:hover,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary:focus-visible,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary:active,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .cr-code-like-box__header>span.cr-code-block__copy-tooltip,:is(html.cb-dark,html[data-theme="dark"]) body[data-vscode-theme-name] .cr-code-like-box__header>span.cr-code-block__copy-tooltip:hover,body[data-vscode-theme-name="IDE Night"] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary,body[data-vscode-theme-name="IDE Night"] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary:hover,body[data-vscode-theme-name="IDE Night"] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary:focus-visible,body[data-vscode-theme-name="IDE Night"] .teams-container .industry-template-switcher__host>button.wb-button.wb-button--secondary:active,body[data-vscode-theme-name="IDE Night"] .cr-code-like-box__header>span.cr-code-block__copy-tooltip,body[data-vscode-theme-name="IDE Night"] .cr-code-like-box__header>span.cr-code-block__copy-tooltip:hover{background:transparent !important;background-color:transparent !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;box-shadow:none !important;}',
},
/* 原 patch-82(AI 端快捷短语弹层 z-index 抬升)已移入 inject.js 常驻样式:
theme-patches 仅在非默认主题时注入,默认浅色主题下会失效;层级修复不依赖主题,随注入脚本常驻更可靠。 */
diff --git a/test/theme-patches.test.js b/test/theme-patches.test.js
index e7c7985..0518040 100644
--- a/test/theme-patches.test.js
+++ b/test/theme-patches.test.js
@@ -26,22 +26,24 @@ test('WorkBuddy widget cards use translucent theme surfaces', () => {
assert.doesNotMatch(patch.css, /WBS_PROFILE|workbuddy-ai/);
});
-test('nebula makes the latest mac teams grid containers transparent', () => {
+test('nebula makes the latest teams grid containers transparent', () => {
const patch = patches.find((item) => item && item.id === 'patch-102');
assert.ok(patch, 'patch-102 must be registered');
assert.equal(patch.themeId, 'nebula');
- assert.match(patch.css, /\.teams-container\.is-mac\s*>\s*\.teams-grid-scroll-content(?:,|\{)/);
+ assert.match(patch.css, /\.teams-container\s*>\s*\.teams-grid-scroll-content(?:,|\{)/);
+ assert.doesNotMatch(patch.css, /\.teams-container\.is-mac/);
assert.match(patch.css, /\.teams-grid-scroll-content\s*>\s*\[class\*="_grid_"\]\s*>\s*\[class\*="_gridView_"\]\{/);
assert.match(patch.css, /background:transparent !important/);
assert.match(patch.css, /background-color:transparent !important/);
assert.match(patch.css, /backdrop-filter:none !important/);
});
-test('nebula removes the mac teams send tooltip wrapper background', () => {
+test('nebula removes the teams send tooltip wrapper background', () => {
const patch = patches.find((item) => item && item.id === 'patch-103');
assert.ok(patch, 'patch-103 must be registered');
assert.equal(patch.themeId, 'nebula');
- assert.match(patch.css, /\.teams-container\.is-mac \.cr-input-toolbar__send>span\.cr-send-button__tooltip-wrapper/);
+ assert.match(patch.css, /\.teams-container \.cr-input-toolbar__send>span\.cr-send-button__tooltip-wrapper/);
+ assert.doesNotMatch(patch.css, /\.teams-container\.is-mac/);
assert.match(patch.css, /background:transparent !important/);
assert.match(patch.css, /background-color:transparent !important/);
});
@@ -49,6 +51,8 @@ test('nebula removes the mac teams send tooltip wrapper background', () => {
test('nebula removes backgrounds from the template switcher and code copy tooltip', () => {
const patch = patches.find((item) => item && item.id === 'patch-104');
assert.ok(patch, 'patch-104 must be registered');
+ assert.match(patch.css, /\.teams-container \.industry-template-switcher__host/);
+ assert.doesNotMatch(patch.css, /\.teams-container\.is-mac/);
assert.equal(patch.themeId, 'nebula');
assert.match(patch.css, /\.industry-template-switcher__host>button\.wb-button\.wb-button--secondary/);
assert.match(patch.css, /\.cr-code-like-box__header>span\.cr-code-block__copy-tooltip/);