mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 10:53:59 +00:00
feat(cockpit): render the Contact and briefing cards' collapse from the store
Cockpit presence now carries contextCollapsed and signalCollapsed. setContextCollapsed and setSignalCollapsed update presence and republish it only when the value changes, instead of writing the dataset and the toggle attributes. CockpitContext and CockpitBriefing bind data-collapsed and their toggles' aria-expanded, aria-label, title and icon from presence. The Cockpit utility QA script waits a frame for Vue to render before it reads the toggles.
This commit is contained in:
1 parent
95523e09cd
commit
a3fc475cbe
10 files changed
+106
-50
No files matched your search
@@ -1197,9 +1197,13 @@ test('cockpit summary presents the focused item as Contact', () => {
|
||||
);
|
||||
assert.match(match[0], /aria-label="Collapse Contact panel"/);
|
||||
assert.doesNotMatch(match[0], />GLOBAL CONTEXT</);
|
||||
// The toggle renders the collapse the controller presents.
|
||||
assert.match(
|
||||
setContextCollapsed.toString(),
|
||||
/expanded \? t\('Collapse Contact panel'\) : t\('Expand Contact panel'\)/,
|
||||
fs.readFileSync(
|
||||
new URL('./ui/views/panels/CockpitContext.vue', import.meta.url),
|
||||
'utf8',
|
||||
),
|
||||
/collapsed \? t\('Expand Contact panel'\) : t\('Collapse Contact panel'\)/,
|
||||
);
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user