mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 19:04:02 +00:00
merge main 0c28dc7 into feat/voice-outlines
This commit is contained in:
commit
d9a460658d
17 files changed
+344
-18
No files matched your search
@@ -490,3 +490,26 @@ test('the scene summary types in, then holds the whole text', async (t) => {
|
||||
await nextTick();
|
||||
assert.equal(byId('cctv-summary').textContent, text);
|
||||
});
|
||||
|
||||
test('the panel meta line reads a bearing that rounds to north as HDG 0°', () => {
|
||||
const meta = (headingDeg) => {
|
||||
const camera = {
|
||||
id: 'a',
|
||||
city: 'Austin',
|
||||
headingDeg,
|
||||
fovDeg: 74,
|
||||
rangeM: 700,
|
||||
};
|
||||
return presentCctvPanel(
|
||||
{
|
||||
enabled: true,
|
||||
activeCameraId: camera.id,
|
||||
activeCamera: camera,
|
||||
cameras: [camera],
|
||||
},
|
||||
true,
|
||||
).meta;
|
||||
};
|
||||
assert.match(meta(359.4), /· HDG 359° ·/);
|
||||
assert.match(meta(359.6), /· HDG 0° ·/);
|
||||
});
|
||||
@@ -107,7 +107,7 @@ function metaText(state, enabled, activeCamera, catalogCount) {
|
||||
'{city} · HDG {heading} · FOV {fov} · RANGE {range}m · {projection}{calBadge} · {provider}{status}',
|
||||
{
|
||||
city: activeCamera.city,
|
||||
heading: `${Math.round(activeCamera.headingDeg)}°`,
|
||||
heading: `${Math.round(activeCamera.headingDeg) % 360}°`,
|
||||
fov: `${Math.round(activeCamera.fovDeg)}°`,
|
||||
range: Math.round(activeCamera.rangeM),
|
||||
projection: projLabel,
|
||||
|
||||
Reference in new issue
Block a user