mirror of
https://github.com/lWolvesl/antigravity-usage-monitor.git
synced 2026-11-27 01:19:25 +08:00
style(panel): remove redundant window control dots from capsule preview bar
This commit is contained in:
@@ -11458,11 +11458,6 @@ const CapsuleBarWidget = defineComponent({
|
||||
]
|
||||
);
|
||||
|
||||
const titlebarRightMock = h('div', { className: 'preview-win-controls', 'aria-hidden': 'true' }, [
|
||||
h('span', { className: 'preview-win-dot' }),
|
||||
h('span', { className: 'preview-win-dot' }),
|
||||
h('span', { className: 'preview-win-dot' }),
|
||||
]);
|
||||
const composerSendMock = h(
|
||||
'span',
|
||||
{ className: 'preview-composer-send', 'aria-hidden': 'true', hidden: true },
|
||||
@@ -11472,7 +11467,7 @@ const CapsuleBarWidget = defineComponent({
|
||||
const hostBarEl = h(
|
||||
'div',
|
||||
{ className: 'preview-capsule-bar', 'data-mount-mode': 'dual' },
|
||||
[titlebarLeftMock, composerLeftMock, capsuleCluster, titlebarRightMock, composerSendMock]
|
||||
[titlebarLeftMock, composerLeftMock, capsuleCluster, composerSendMock]
|
||||
);
|
||||
|
||||
const sidebarHintEl = h('div', {
|
||||
@@ -11501,7 +11496,6 @@ const CapsuleBarWidget = defineComponent({
|
||||
});
|
||||
|
||||
patchAttr(titlebarLeftMock, 'hidden', isComposer);
|
||||
patchAttr(titlebarRightMock, 'hidden', isComposer);
|
||||
patchAttr(composerLeftMock, 'hidden', !isComposer);
|
||||
patchAttr(composerSendMock, 'hidden', !isComposer);
|
||||
patchAttr(sidebarHintEl, 'hidden', !isSidebar);
|
||||
|
||||
@@ -4,11 +4,11 @@
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>用量监控</title>
|
||||
<link rel="stylesheet" href="/styles.css?v=1794972561672">
|
||||
<link rel="stylesheet" href="/styles.css?v=1794973728117">
|
||||
<script src="/preload.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="app-root"></div>
|
||||
<script src="/app.js?v=1794972561672"></script>
|
||||
<script src="/app.js?v=1794973728117"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -222,11 +222,6 @@ export const CapsuleBarWidget = defineComponent({
|
||||
]
|
||||
);
|
||||
|
||||
const titlebarRightMock = h('div', { className: 'preview-win-controls', 'aria-hidden': 'true' }, [
|
||||
h('span', { className: 'preview-win-dot' }),
|
||||
h('span', { className: 'preview-win-dot' }),
|
||||
h('span', { className: 'preview-win-dot' }),
|
||||
]);
|
||||
const composerSendMock = h(
|
||||
'span',
|
||||
{ className: 'preview-composer-send', 'aria-hidden': 'true', hidden: true },
|
||||
@@ -236,7 +231,7 @@ export const CapsuleBarWidget = defineComponent({
|
||||
const hostBarEl = h(
|
||||
'div',
|
||||
{ className: 'preview-capsule-bar', 'data-mount-mode': 'dual' },
|
||||
[titlebarLeftMock, composerLeftMock, capsuleCluster, titlebarRightMock, composerSendMock]
|
||||
[titlebarLeftMock, composerLeftMock, capsuleCluster, composerSendMock]
|
||||
);
|
||||
|
||||
const sidebarHintEl = h('div', {
|
||||
@@ -265,7 +260,6 @@ export const CapsuleBarWidget = defineComponent({
|
||||
});
|
||||
|
||||
patchAttr(titlebarLeftMock, 'hidden', isComposer);
|
||||
patchAttr(titlebarRightMock, 'hidden', isComposer);
|
||||
patchAttr(composerLeftMock, 'hidden', !isComposer);
|
||||
patchAttr(composerSendMock, 'hidden', !isComposer);
|
||||
patchAttr(sidebarHintEl, 'hidden', !isSidebar);
|
||||
|
||||
@@ -368,21 +368,6 @@
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.preview-win-controls {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
padding-left: 4px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.preview-win-dot {
|
||||
width: 7px;
|
||||
height: 7px;
|
||||
border-radius: var(--radius-pill);
|
||||
background: color-mix(in srgb, var(--text-secondary) 26%, transparent);
|
||||
}
|
||||
|
||||
.preview-composer-send {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
|
||||
@@ -3677,21 +3677,6 @@ html[data-standalone="true"] .app-shell {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.preview-win-controls {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
padding-left: 4px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.preview-win-dot {
|
||||
width: 7px;
|
||||
height: 7px;
|
||||
border-radius: var(--radius-pill);
|
||||
background: color-mix(in srgb, var(--text-secondary) 26%, transparent);
|
||||
}
|
||||
|
||||
.preview-composer-send {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
|
||||
@@ -1705,6 +1705,7 @@ test('Compiled app.js mounts dual Shadow DOM hosts, tracks /c/<uuid> routes, pro
|
||||
const previewCapsuleSlots = sec0.querySelectorAll('.wm-cap-slot');
|
||||
const previewMultiBtn = sec0.querySelector('.wm-multi-btn');
|
||||
assert.ok(previewCapsuleBar, 'Pane 0 mounts real CapsuleBarWidget preview');
|
||||
assert.equal(previewCapsuleBar.querySelector('.preview-win-controls'), null, 'No redundant 3 window dots after capsule');
|
||||
assert.equal(previewCapsuleSlots.length, 5, 'Preview CapsuleBarWidget mounts real 5 capsule slots');
|
||||
assert.equal(previewCapsuleSlots[0].children[0].textContent, '68.4 t/s', 'Preview slot 0 renders simulated speed');
|
||||
assert.equal(previewCapsuleSlots[0].classList.contains('tone-good'), true, 'Preview capsule 68.4 t/s shares tone-good green with cards');
|
||||
|
||||
Reference in New Issue
Block a user