mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 16:22:20 +00:00
Merge branch 'main' into feat/draw-mark-actions
This commit is contained in:
149 files changed
+20764
-593
No files matched your search
@@ -12,6 +12,8 @@ import { useCockpitStore } from '../stores/cockpit.js';
|
||||
import { useGlobeActionsStore } from '../stores/globeActions.js';
|
||||
import CockpitBriefing from './panels/CockpitBriefing.vue';
|
||||
import CockpitContext from './panels/CockpitContext.vue';
|
||||
import CockpitOrbital from './panels/CockpitOrbital.vue';
|
||||
import CockpitRadar from './panels/CockpitRadar.vue';
|
||||
import CockpitRollingValue from './panels/CockpitRollingValue.vue';
|
||||
import CockpitUtilityControls from './panels/CockpitUtilityControls.vue';
|
||||
|
||||
@@ -23,13 +25,48 @@ import CockpitUtilityControls from './panels/CockpitUtilityControls.vue';
|
||||
const { presence, instruments, route, vision, utilityLayout } =
|
||||
storeToRefs(useCockpitStore());
|
||||
const active = computed(() => Boolean(presence.value?.active));
|
||||
// A vessel subject swaps the aviation readouts for bridge ones.
|
||||
const bridge = computed(() => presence.value?.subjectKind === 'vessel');
|
||||
// A satellite subject keeps only its orbital HUD over the nadir picture.
|
||||
const orbital = computed(() => presence.value?.subjectKind === 'satellite');
|
||||
const subject = computed(() =>
|
||||
bridge.value ? 'vessel' : orbital.value ? 'satellite' : 'aircraft',
|
||||
);
|
||||
const hudLabel = computed(() =>
|
||||
bridge.value
|
||||
? t('Ship bridge view')
|
||||
: orbital.value
|
||||
? t('Satellite orbital view')
|
||||
: t('Aircraft cockpit view'),
|
||||
);
|
||||
const exitLabel = computed(() =>
|
||||
bridge.value
|
||||
? t('Exit bridge view')
|
||||
: orbital.value
|
||||
? t('Exit orbital view')
|
||||
: t('Exit cockpit view'),
|
||||
);
|
||||
const exitText = computed(() =>
|
||||
bridge.value
|
||||
? t('EXIT BRIDGE')
|
||||
: orbital.value
|
||||
? t('EXIT ORBIT')
|
||||
: t('EXIT COCKPIT'),
|
||||
);
|
||||
const globe = useGlobeActionsStore();
|
||||
const { resetBusy } = storeToRefs(globe);
|
||||
const initialInstruments = createInstrumentState();
|
||||
const initialRoute = createRouteState();
|
||||
const initialVision = createVisionState();
|
||||
const hud = computed(() => instruments.value ?? initialInstruments);
|
||||
// The bridge tape scrolls continuously: its minor ticks shift with the
|
||||
// division nearest the caret.
|
||||
const tapeShift = computed(
|
||||
() => hud.value.compass?.find((division) => division.active)?.slot ?? 0,
|
||||
);
|
||||
const direction = computed(() => (route.value ?? initialRoute).direction);
|
||||
// Where a bridge view is turned; an aircraft's always rests.
|
||||
const look = computed(() => hud.value.look ?? initialInstruments.look);
|
||||
const v = computed(() => vision.value ?? initialVision);
|
||||
const visionLabel = computed(() =>
|
||||
t('Current cockpit vision style: {style}. Activate for next style.', {
|
||||
@@ -54,11 +91,22 @@ const tickStyle = (tick) =>
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<!-- Aircraft first-person view. It can be entered from the visible view switcher. -->
|
||||
<section id="cockpit-hud" :aria-label="t('Aircraft cockpit view')" :hidden="!active" :style="utilityStyle" v-class-toggle="{ 'signals-active': active, 'context-active': Boolean(presence?.context) }" :data-layer="hud.layer ?? undefined">
|
||||
<!-- Aircraft first-person view, a vessel's bridge or a satellite's nadir view. It can be entered from the visible view switcher. -->
|
||||
<section id="cockpit-hud" :aria-label="hudLabel" :hidden="!active" :data-subject="subject" :style="utilityStyle" v-class-toggle="{ 'signals-active': active, 'context-active': Boolean(presence?.context) }" :data-layer="orbital ? 'satellites' : hud.layer ?? undefined">
|
||||
<!-- In orbit the picture keeps only the nadir reticle, readout and zoom. -->
|
||||
<CockpitOrbital v-if="orbital" />
|
||||
<!-- One optical coordinate system: every targeting mark shares this center.
|
||||
Decorative only; telemetry and interactive panels remain separate. -->
|
||||
<svg class="cockpit-frame-lines" viewBox="0 0 1200 720" preserveAspectRatio="none" aria-hidden="true" focusable="false">
|
||||
Decorative only; telemetry and interactive panels remain separate.
|
||||
A bridge looks out through straight window mullions instead: a header
|
||||
beam, two pane posts and the sill either side of the console. -->
|
||||
<svg v-if="bridge" class="cockpit-frame-lines cockpit-bridge-frame" viewBox="0 0 1200 720" preserveAspectRatio="none" aria-hidden="true" focusable="false">
|
||||
<g fill="none" stroke="currentColor">
|
||||
<path d="M0 96H1200 M0 101H1200"/>
|
||||
<path d="M324 101V600 M876 101V600"/>
|
||||
<path d="M0 600H324 M876 600H1200"/>
|
||||
</g>
|
||||
</svg>
|
||||
<svg v-else-if="!orbital" class="cockpit-frame-lines" viewBox="0 0 1200 720" preserveAspectRatio="none" aria-hidden="true" focusable="false">
|
||||
<g fill="none" stroke="currentColor">
|
||||
<path d="M42 106H234L266 126H334 M866 126H934L966 106H1158 M42 114H226L258 136H318 M882 136H942L974 114H1158"/>
|
||||
<path d="M42 616H226L254 598H320 M880 598H946L974 616H1158 M42 624H238L266 606H330 M870 606H934L962 624H1158"/>
|
||||
@@ -68,7 +116,7 @@ const tickStyle = (tick) =>
|
||||
<path class="cockpit-frame-warning" d="M338 645H476L490 654H710L724 645H862" fill="none"/>
|
||||
<path class="cockpit-frame-meter" d="M372 642H418 M782 642H828"/>
|
||||
</svg>
|
||||
<div class="cockpit-scan-array" aria-hidden="true">
|
||||
<div v-if="!bridge && !orbital" class="cockpit-scan-array" aria-hidden="true">
|
||||
<svg class="cockpit-target-geometry" viewBox="0 0 600 600" fill="none" focusable="false">
|
||||
<g class="cockpit-target-hairline">
|
||||
<circle cx="300" cy="300" r="276"/>
|
||||
@@ -100,8 +148,9 @@ const tickStyle = (tick) =>
|
||||
</g>
|
||||
</svg>
|
||||
</div>
|
||||
<div class="cockpit-visor-shell" aria-hidden="true">
|
||||
<div class="cockpit-roll-arc">
|
||||
<div v-if="!orbital" class="cockpit-visor-shell" aria-hidden="true">
|
||||
<!-- A ship's bridge keeps no roll arc or pitch ladder. -->
|
||||
<div v-if="!bridge" class="cockpit-roll-arc">
|
||||
<span style="--slot:-3;--depth:3">−30</span>
|
||||
<span style="--slot:-2;--depth:2">−20</span>
|
||||
<span style="--slot:-1;--depth:1">−10</span>
|
||||
@@ -110,10 +159,10 @@ const tickStyle = (tick) =>
|
||||
<span style="--slot:2;--depth:2">+20</span>
|
||||
<span style="--slot:3;--depth:3">+30</span>
|
||||
</div>
|
||||
<div class="cockpit-pitch-rail cockpit-pitch-rail-left">
|
||||
<div v-if="!bridge" class="cockpit-pitch-rail cockpit-pitch-rail-left">
|
||||
<span>+20</span><span>+10</span><span class="active">00</span><span>−10</span><span>−20</span>
|
||||
</div>
|
||||
<div class="cockpit-pitch-rail cockpit-pitch-rail-right">
|
||||
<div v-if="!bridge" class="cockpit-pitch-rail cockpit-pitch-rail-right">
|
||||
<span>+20</span><span>+10</span><span class="active">00</span><span>−10</span><span>−20</span>
|
||||
</div>
|
||||
<div class="cockpit-horizon-guide">
|
||||
@@ -125,11 +174,11 @@ const tickStyle = (tick) =>
|
||||
</svg>
|
||||
<small id="cockpit-route-direction-label">{{ direction.label }}</small>
|
||||
</div>
|
||||
<div class="cockpit-visor-status cockpit-visor-status-left">{{ t('OPTICAL PLANE · 01') }}</div>
|
||||
<div class="cockpit-visor-status cockpit-visor-status-right">{{ t('VISOR LOCK · ACTIVE') }}</div>
|
||||
<div class="cockpit-visor-status cockpit-visor-status-left">{{ bridge ? t('BRIDGE WINDOW · FWD') : t('OPTICAL PLANE · 01') }}</div>
|
||||
<div class="cockpit-visor-status cockpit-visor-status-right">{{ bridge ? (hud.trackSource === 'course' ? t('COURSE HOLD · AIS') : hud.trackSource === 'heading' ? t('HEADING HOLD · AIS') : t('NO HEADING · AIS')) : t('VISOR LOCK · ACTIVE') }}</div>
|
||||
</div>
|
||||
<div id="cockpit-speed-rim" class="cockpit-altitude-rim cockpit-speed-rim" v-class-toggle="{ unavailable: hud.speedRim.unavailable }">
|
||||
<span class="cockpit-altitude-rim-label">{{ t('GROUND SPEED · KTS') }}</span>
|
||||
<div v-if="!orbital" id="cockpit-speed-rim" class="cockpit-altitude-rim cockpit-speed-rim" v-class-toggle="{ unavailable: hud.speedRim.unavailable }">
|
||||
<span class="cockpit-altitude-rim-label">{{ bridge ? t('SPEED OVER GROUND · KTS') : t('GROUND SPEED · KTS') }}</span>
|
||||
<div class="cockpit-altitude-rim-rail"></div>
|
||||
<div class="cockpit-altitude-rim-scale">
|
||||
<span v-for="(tick, index) in hud.speedRim.ticks" :key="index" data-speed-rim-tick :hidden="tick.hidden" :class="{ major: tick.major }" :style="tickStyle(tick)"><b>{{ tick.label }}</b><i></i></span>
|
||||
@@ -139,7 +188,7 @@ const tickStyle = (tick) =>
|
||||
<strong id="cockpit-speed-rim-value">{{ hud.speedRim.value }}</strong>
|
||||
</div>
|
||||
</div>
|
||||
<div id="cockpit-altitude-rim" class="cockpit-altitude-rim" v-class-toggle="{ unavailable: hud.altitudeRim.unavailable }">
|
||||
<div v-if="!orbital" id="cockpit-altitude-rim" class="cockpit-altitude-rim" :hidden="bridge" v-class-toggle="{ unavailable: hud.altitudeRim.unavailable }">
|
||||
<span class="cockpit-altitude-rim-label">{{ t('ALTITUDE · FT') }}</span>
|
||||
<div class="cockpit-altitude-rim-rail"></div>
|
||||
<div class="cockpit-altitude-rim-scale">
|
||||
@@ -152,7 +201,7 @@ const tickStyle = (tick) =>
|
||||
</div>
|
||||
<div class="cockpit-topline">
|
||||
<div>
|
||||
<span class="cockpit-kicker">{{ t('FIRST PERSON') }}</span>
|
||||
<span class="cockpit-kicker">{{ bridge ? t('BRIDGE VIEW') : t('FIRST PERSON') }}</span>
|
||||
<strong id="cockpit-callsign">{{ hud.callsign }}</strong>
|
||||
<span id="cockpit-aircraft-meta" v-class-toggle="{ emergency: hud.meta.emergency }" class="cockpit-aircraft-meta">{{ hud.meta.text }}</span>
|
||||
</div>
|
||||
@@ -171,32 +220,48 @@ const tickStyle = (tick) =>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="cockpit-reticle material-symbols-outlined" aria-hidden="true">my_location</div>
|
||||
<div class="cockpit-compass" :aria-label="t('Current aircraft heading')">
|
||||
<div v-if="!orbital" class="cockpit-reticle material-symbols-outlined" aria-hidden="true">my_location</div>
|
||||
<!-- A bridge view turned off the bow says where it looks and offers the way back. -->
|
||||
<div v-if="bridge" class="cockpit-look" :hidden="!look.offset">
|
||||
<span id="cockpit-look-readout" class="cockpit-look-readout" aria-live="polite">{{ look.readout }}</span>
|
||||
<button id="cockpit-look-ahead" type="button" class="cockpit-look-ahead" :aria-label="t('Look ahead: turn the bridge view back to the bow')" :title="t('Look ahead (Home or 0)')" aria-keyshortcuts="Home 0">
|
||||
<span>{{ t('LOOK AHEAD') }}</span>
|
||||
</button>
|
||||
</div>
|
||||
<div v-if="!orbital" class="cockpit-compass" :aria-label="bridge ? t('Current vessel heading') : t('Current aircraft heading')">
|
||||
<div class="cockpit-instrument-row">
|
||||
<div class="cockpit-readout cockpit-speed">
|
||||
<span class="cockpit-readout-label">{{ t('GROUND SPEED') }}</span>
|
||||
<span class="cockpit-readout-label">{{ bridge ? t('SPEED OVER GROUND') : t('GROUND SPEED') }}</span>
|
||||
<CockpitRollingValue id="cockpit-speed-value" tag="strong" :reading="hud.speed" placeholder="---" />
|
||||
<span class="cockpit-readout-unit">{{ t('KTS') }}</span>
|
||||
</div>
|
||||
<div class="cockpit-heading-value"><CockpitRollingValue id="cockpit-heading-value" :reading="hud.heading" placeholder="---" :circular-range="360" /><small>°</small></div>
|
||||
<div class="cockpit-readout cockpit-altitude">
|
||||
<div v-if="bridge" class="cockpit-readout cockpit-altitude cockpit-course">
|
||||
<span class="cockpit-readout-label">{{ t('COURSE OVER GROUND') }}</span>
|
||||
<CockpitRollingValue id="cockpit-course-value" tag="strong" :reading="hud.course" placeholder="---" :circular-range="360" />
|
||||
<span class="cockpit-readout-unit">°</span>
|
||||
</div>
|
||||
<div v-else class="cockpit-readout cockpit-altitude">
|
||||
<span class="cockpit-readout-label">{{ t('ALTITUDE') }}</span>
|
||||
<CockpitRollingValue id="cockpit-altitude-value" tag="strong" :reading="hud.altitude" placeholder="-----" />
|
||||
<span class="cockpit-readout-unit">{{ t('FT') }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<span class="cockpit-heading-caret material-symbols-outlined" aria-hidden="true">arrow_drop_down</span>
|
||||
<div class="cockpit-compass-tape" id="cockpit-compass-tape" aria-hidden="true"><span v-for="division in hud.compass" :key="division.slot" :class="division.slot === 0 ? 'active' : ''" :style="{ '--slot': division.slot, '--depth': Math.abs(division.slot) }">{{ division.label }}</span></div>
|
||||
<div class="cockpit-compass-tape" id="cockpit-compass-tape" aria-hidden="true" :style="bridge ? { '--tape-shift': tapeShift } : undefined"><span v-for="division in hud.compass" :key="division.heading ?? division.slot" :class="(division.active ?? division.slot === 0) ? 'active' : ''" :style="{ '--slot': division.slot, '--depth': Math.abs(division.slot) }">{{ division.label }}</span><template v-if="bridge"><i v-if="hud.compassMarkers?.prograde != null" class="cockpit-compass-marker cockpit-compass-prograde" aria-hidden="true" :style="{ '--slot': hud.compassMarkers.prograde }"></i><i v-if="hud.compassMarkers?.retrograde != null" class="cockpit-compass-marker cockpit-compass-retrograde" aria-hidden="true" :style="{ '--slot': hud.compassMarkers.retrograde }"></i></template></div>
|
||||
</div>
|
||||
<div class="cockpit-position-readout">
|
||||
<div v-if="!orbital" class="cockpit-position-readout">
|
||||
<span id="cockpit-clock">{{ hud.clock }}</span>
|
||||
<span id="cockpit-position">{{ hud.position }}</span>
|
||||
</div>
|
||||
<CockpitContext />
|
||||
<CockpitBriefing />
|
||||
<!-- The bridge radar's console: bottom right, below the briefing card. -->
|
||||
<div v-if="bridge" class="cockpit-radar-console">
|
||||
<CockpitRadar />
|
||||
</div>
|
||||
<CockpitUtilityControls />
|
||||
<div class="cockpit-help"><bdi>{{ t('ESC EXIT') }}</bdi> <span>·</span> <bdi>{{ t('C TOGGLE') }}</bdi></div>
|
||||
<div class="cockpit-help"><bdi>{{ t('ESC EXIT') }}</bdi><template v-if="bridge"> <span>·</span> <bdi>{{ t('ARROWS LOOK') }}</bdi> <span>·</span> <bdi>{{ t('HOME RESET') }}</bdi></template><template v-if="orbital"> <span>·</span> <bdi>{{ t('+/− ZOOM') }}</bdi> <span>·</span> <bdi>{{ t('ARROWS TILT') }}</bdi> <span>·</span> <bdi>{{ t('HOME NADIR') }}</bdi></template></div>
|
||||
</section>
|
||||
|
||||
<nav id="view-switcher" :aria-label="t('View switcher')">
|
||||
@@ -204,9 +269,9 @@ const tickStyle = (tick) =>
|
||||
<span class="material-symbols-outlined" aria-hidden="true">public</span>
|
||||
<span>{{ t('RESET') }}</span>
|
||||
</button>
|
||||
<button id="map-view-switch" type="button" :aria-label="t('Exit cockpit view')" aria-keyshortcuts="Escape C" :title="t('Exit cockpit view')" :hidden="!active">
|
||||
<button id="map-view-switch" type="button" :aria-label="exitLabel" aria-keyshortcuts="Escape" :title="exitLabel" :hidden="!active">
|
||||
<span class="material-symbols-outlined" aria-hidden="true">close_fullscreen</span>
|
||||
<span>{{ t('EXIT COCKPIT') }}</span>
|
||||
<span>{{ exitText }}</span>
|
||||
</button>
|
||||
</nav>
|
||||
</template>
|
||||
@@ -20,8 +20,8 @@ import { cockpitEntryFace } from '../cockpitPresentation.js';
|
||||
// publishes them; until it does, the panel shows its initial markup.
|
||||
const { view: ctx } = storeToRefs(useContextStore());
|
||||
const { presence: cockpit } = storeToRefs(useCockpitStore());
|
||||
// The entry rides the tracked aircraft (cockpitEntryFace).
|
||||
const entry = computed(() => cockpitEntryFace('aircraft'));
|
||||
// The entry names the subject it would ride (cockpitEntryFace).
|
||||
const entry = computed(() => cockpitEntryFace(cockpit.value?.entryKind));
|
||||
// While the Bhote Koshi event is on, its panel is the rail's only content.
|
||||
const { panel: bhotePanel } = storeToRefs(useBhoteKoshiPanelStore());
|
||||
// The Scene runtime chip SceneControls presents while a scene plays.
|
||||
|
||||
@@ -16,8 +16,8 @@ const view = computed(() => hud.value ?? EMPTY);
|
||||
// button, so first person needs no Contacts panel. The Cockpit controller
|
||||
// answers its clicks.
|
||||
const { presence: cockpit } = storeToRefs(useCockpitStore());
|
||||
// The entry rides the tracked aircraft (cockpitEntryFace).
|
||||
const entry = computed(() => cockpitEntryFace('aircraft'));
|
||||
// The entry names the subject it would ride (cockpitEntryFace).
|
||||
const entry = computed(() => cockpitEntryFace(cockpit.value?.entryKind));
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
||||
@@ -0,0 +1,341 @@
|
||||
<script setup>
|
||||
import { storeToRefs } from 'pinia';
|
||||
import { computed, nextTick, ref, watch } from 'vue';
|
||||
import { formatNumber, getLocale, t } from '../../../i18n/index.js';
|
||||
import {
|
||||
formatCockpitCoordinate,
|
||||
formatTleEpochUtc,
|
||||
tleAgeParts,
|
||||
} from '../../cockpitPresentation.js';
|
||||
import {
|
||||
loadFlagUrl,
|
||||
ownerMark,
|
||||
regionName,
|
||||
shownOwnerMark,
|
||||
} from '../../ownerFlag.js';
|
||||
import { useCockpitStore } from '../../stores/cockpit.js';
|
||||
|
||||
// The orbital view's HUD: a nadir reticle over the picture, the satellite's
|
||||
// identity and orbit, and the optical zoom. The Cockpit controller presents
|
||||
// it, drives the zoom step's blur and lock tick, and keeps the zoom buttons'
|
||||
// listeners; this view only reflects the store.
|
||||
|
||||
const { orbital } = storeToRefs(useCockpitStore());
|
||||
|
||||
const finite = (value) => typeof value === 'number' && Number.isFinite(value);
|
||||
|
||||
const altitudeText = computed(() => {
|
||||
const altitudeM = orbital.value?.altitudeM;
|
||||
return finite(altitudeM)
|
||||
? t('{value} KM', {
|
||||
value: formatNumber(Math.round(altitudeM / 1000)),
|
||||
})
|
||||
: '—';
|
||||
});
|
||||
|
||||
const velocityText = computed(() => {
|
||||
const velocityMps = orbital.value?.velocityMps;
|
||||
return finite(velocityMps)
|
||||
? t('{value} KM/S', {
|
||||
value: formatNumber(velocityMps / 1000, {
|
||||
minimumFractionDigits: 2,
|
||||
maximumFractionDigits: 2,
|
||||
}),
|
||||
})
|
||||
: null;
|
||||
});
|
||||
|
||||
const subPointText = computed(() => {
|
||||
const { latitude, longitude } = orbital.value || {};
|
||||
if (!finite(latitude) || !finite(longitude)) return '—';
|
||||
return `${formatCockpitCoordinate(latitude, 'N', 'S')} ${formatCockpitCoordinate(longitude, 'E', 'W')}`;
|
||||
});
|
||||
|
||||
const zoomSteps = computed(() => orbital.value?.zoomSteps || [1]);
|
||||
const zoom = computed(() => orbital.value?.zoom ?? zoomSteps.value[0]);
|
||||
// The SENSOR step lands between ladder steps, e.g. 5.7×.
|
||||
const zoomText = computed(() =>
|
||||
t('ZOOM {zoom}×', {
|
||||
zoom: formatNumber(zoom.value, { maximumFractionDigits: 1 }),
|
||||
}),
|
||||
);
|
||||
const maxZoom = computed(
|
||||
() => orbital.value?.maxZoom ?? Math.max(...zoomSteps.value),
|
||||
);
|
||||
const atWidest = computed(() => zoom.value <= Math.min(...zoomSteps.value));
|
||||
const atTightest = computed(() => zoom.value >= maxZoom.value);
|
||||
|
||||
// The imaging sensor's swath: a strip drawn to scale across the view, its
|
||||
// width as a readout, and the SENSOR step that zooms the view to it. Off
|
||||
// nadir the strip stays, the readout scales as the view's swath does (≈),
|
||||
// and the SENSOR step, a nadir framing, is hidden.
|
||||
const sensor = computed(() => orbital.value?.sensor || null);
|
||||
// Track-up turns the frame to the ground track; north's pointer turns back.
|
||||
const trackUp = computed(() => orbital.value?.trackUp === true);
|
||||
const northPointerStyle = computed(() => {
|
||||
const northDeg = orbital.value?.northDeg;
|
||||
return finite(northDeg) && northDeg !== 0
|
||||
? { transform: `rotate(${northDeg.toFixed(1)}deg)` }
|
||||
: null;
|
||||
});
|
||||
// The N itself stays upright as its pointer turns.
|
||||
const northLetterStyle = computed(() => {
|
||||
const northDeg = orbital.value?.northDeg;
|
||||
return finite(northDeg) && northDeg !== 0
|
||||
? { transform: `translateX(-50%) rotate(${(-northDeg).toFixed(1)}deg)` }
|
||||
: null;
|
||||
});
|
||||
|
||||
const sensorStripStyle = computed(() => {
|
||||
const fraction = sensor.value?.stripFraction;
|
||||
return finite(fraction) && fraction > 0
|
||||
? { width: `${(fraction * 100).toFixed(3)}%` }
|
||||
: null;
|
||||
});
|
||||
const sensorText = computed(() => {
|
||||
const km = sensor.value?.swathKm;
|
||||
if (!finite(km)) return '';
|
||||
const look = orbital.value?.look;
|
||||
if (look?.offset === true) {
|
||||
const scale = look.swathScale;
|
||||
if (!finite(scale)) return '';
|
||||
return t('SENSOR SWATH ≈ {value} KM', {
|
||||
value: formatNumber(km * scale, { maximumFractionDigits: 1 }),
|
||||
});
|
||||
}
|
||||
// As published: 13.1 km, 185 km.
|
||||
return t('SENSOR SWATH {value} KM', {
|
||||
value: formatNumber(km, { maximumFractionDigits: 1 }),
|
||||
});
|
||||
});
|
||||
const sensorStepShown = computed(
|
||||
() =>
|
||||
finite(sensor.value?.zoom) &&
|
||||
finite(orbital.value?.footprintKm) &&
|
||||
orbital.value?.look?.offset !== true,
|
||||
);
|
||||
|
||||
// A focused control that turns off (a zoom button at the end of its range,
|
||||
// SENSOR as the view tilts away) hands focus on instead of dropping it to the
|
||||
// page. The watchers run before the re-render, while it still has focus.
|
||||
const zoomInButton = ref(null);
|
||||
const zoomOutButton = ref(null);
|
||||
const sensorButton = ref(null);
|
||||
const nadirButton = ref(null);
|
||||
const handFocus = (from, to) => {
|
||||
if (!from || document.activeElement !== from) return;
|
||||
nextTick(() =>
|
||||
(to() ?? document.getElementById('map-view-switch'))?.focus({
|
||||
preventScroll: true,
|
||||
}),
|
||||
);
|
||||
};
|
||||
watch(
|
||||
atTightest,
|
||||
(now) => now && handFocus(zoomInButton.value, () => zoomOutButton.value),
|
||||
{ flush: 'pre' },
|
||||
);
|
||||
watch(
|
||||
atWidest,
|
||||
(now) => now && handFocus(zoomOutButton.value, () => zoomInButton.value),
|
||||
{ flush: 'pre' },
|
||||
);
|
||||
watch(
|
||||
sensorStepShown,
|
||||
(shown) => !shown && handFocus(sensorButton.value, () => nadirButton.value),
|
||||
{ flush: 'pre' },
|
||||
);
|
||||
|
||||
// At nadir the footprint; tilted, the approximate width at the view's
|
||||
// centre, marked ≈.
|
||||
const swathText = computed(() => {
|
||||
const tilted = orbital.value?.look?.offset === true;
|
||||
const km = tilted ? orbital.value?.look?.swathKm : orbital.value?.footprintKm;
|
||||
if (!finite(km)) return '';
|
||||
const digits = km < 10 ? 1 : 0;
|
||||
const value = formatNumber(km, {
|
||||
minimumFractionDigits: digits,
|
||||
maximumFractionDigits: digits,
|
||||
});
|
||||
return tilted
|
||||
? t('SWATH ≈ {value} KM', { value })
|
||||
: t('SWATH {value} KM', { value });
|
||||
});
|
||||
|
||||
// What the sub-satellite point is over: nothing until the first lookup
|
||||
// lands; on land the division as Natural Earth names it and the country in
|
||||
// the reader's language, with the populated place in view from 8x; at sea
|
||||
// the Natural Earth name.
|
||||
const placeText = computed(() => {
|
||||
const place = orbital.value?.place;
|
||||
if (place === undefined) return '';
|
||||
// No feature holds the point (a gap at a simplified coastline): say
|
||||
// nothing rather than call land open ocean.
|
||||
if (!place) return '';
|
||||
if (place.kind !== 'country') return place.name || '';
|
||||
const country =
|
||||
(place.countryCode && regionName(place.countryCode, getLocale())) ||
|
||||
place.name ||
|
||||
'';
|
||||
const region = place.division
|
||||
? t('{division}, {country}', { division: place.division, country })
|
||||
: country;
|
||||
return place.near
|
||||
? t('{region} · near {place}', { region, place: place.near })
|
||||
: region;
|
||||
});
|
||||
|
||||
// The owner's flag, or a text badge for an owner without one.
|
||||
const mark = computed(() =>
|
||||
ownerMark(orbital.value?.owner, { locale: getLocale() }),
|
||||
);
|
||||
const flagUrl = ref(null);
|
||||
// A flag that would not load (offline, a stale chunk after a deploy, a
|
||||
// missing file) falls back to the code as a badge, never to no owner at all.
|
||||
const flagFailed = ref(false);
|
||||
let flagRequest = 0;
|
||||
watch(
|
||||
() => (mark.value?.kind === 'flag' ? mark.value.code : null),
|
||||
async (code) => {
|
||||
const request = ++flagRequest;
|
||||
flagUrl.value = null;
|
||||
flagFailed.value = false;
|
||||
if (!code) return;
|
||||
let url = null;
|
||||
try {
|
||||
url = await loadFlagUrl(code);
|
||||
} catch {
|
||||
url = null;
|
||||
}
|
||||
if (request !== flagRequest) return;
|
||||
flagUrl.value = url;
|
||||
flagFailed.value = !url;
|
||||
},
|
||||
{ immediate: true },
|
||||
);
|
||||
const shownMark = computed(() =>
|
||||
shownOwnerMark(mark.value, {
|
||||
url: flagUrl.value,
|
||||
failed: flagFailed.value,
|
||||
}),
|
||||
);
|
||||
|
||||
// NORAD · COSPAR · TLE epoch, and the two element lines on request.
|
||||
const identParts = computed(() => {
|
||||
const o = orbital.value;
|
||||
if (!o) return [];
|
||||
const parts = [];
|
||||
if (o.noradId !== null && o.noradId !== undefined && o.noradId !== '')
|
||||
parts.push(t('NORAD {id}', { id: String(o.noradId) }));
|
||||
if (o.cosparId) parts.push(o.cosparId);
|
||||
const epoch = formatTleEpochUtc(o.tle?.epochMs);
|
||||
if (epoch) parts.push(t('EPOCH {time}', { time: epoch }));
|
||||
const age = tleAgeParts(o.tleAgeMs);
|
||||
if (age?.unit === 'under-hour') parts.push(t('<1 H OLD'));
|
||||
else if (age?.unit === 'hours')
|
||||
parts.push(t('{value} H OLD', { value: formatNumber(age.value) }));
|
||||
else if (age?.unit === 'days')
|
||||
parts.push(t('{value} D OLD', { value: formatNumber(age.value) }));
|
||||
return parts;
|
||||
});
|
||||
const identText = computed(() => identParts.value.join(' · '));
|
||||
const tleText = computed(() => {
|
||||
const tle = orbital.value?.tle;
|
||||
return tle?.line1 && tle?.line2 ? `${tle.line1}\n${tle.line2}` : '';
|
||||
});
|
||||
const tleOpen = ref(false);
|
||||
// Another satellite starts with its element set folded.
|
||||
watch(
|
||||
() => orbital.value?.noradId ?? null,
|
||||
() => {
|
||||
tleOpen.value = false;
|
||||
},
|
||||
);
|
||||
|
||||
// The off-nadir tilt; an untilted view shows no readout or reset.
|
||||
const look = computed(() => orbital.value?.look || { offset: false });
|
||||
// A ground focus names its target in a polite live region; the angle,
|
||||
// which changes every update, is left out of it.
|
||||
const focusText = computed(() => {
|
||||
const label = look.value.focus?.label;
|
||||
return label ? t('FOCUS · {name}', { name: label }) : '';
|
||||
});
|
||||
|
||||
const transition = computed(() => orbital.value?.transition || {});
|
||||
const lensStyle = computed(() => {
|
||||
const blurPx = transition.value.blurPx;
|
||||
return {
|
||||
'--cockpit-orbital-blur': `${finite(blurPx) && blurPx > 0 ? blurPx.toFixed(2) : 0}px`,
|
||||
};
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<section id="cockpit-orbital" class="cockpit-orbital" :class="{ 'cockpit-orbital-focusing': transition.active }" :style="lensStyle" :aria-label="t('Orbital view')" :hidden="!orbital">
|
||||
<template v-if="orbital">
|
||||
<div class="cockpit-orbital-lens" aria-hidden="true"></div>
|
||||
<div class="cockpit-orbital-reticle" :class="{ 'cockpit-orbital-reticle-lock': transition.lockTick }" aria-hidden="true">
|
||||
<span class="cockpit-orbital-bracket cockpit-orbital-bracket-tl"></span>
|
||||
<span class="cockpit-orbital-bracket cockpit-orbital-bracket-tr"></span>
|
||||
<span class="cockpit-orbital-bracket cockpit-orbital-bracket-bl"></span>
|
||||
<span class="cockpit-orbital-bracket cockpit-orbital-bracket-br"></span>
|
||||
<span class="cockpit-orbital-cross"></span>
|
||||
<!-- North on the frame: at the top while north-up, turned with the ground track while track-up. -->
|
||||
<span class="cockpit-orbital-north-pointer" :style="northPointerStyle">
|
||||
<span class="cockpit-orbital-north-tick"></span>
|
||||
<span v-if="trackUp" class="cockpit-orbital-north-letter" :style="northLetterStyle">{{ t('N') }}</span>
|
||||
</span>
|
||||
</div>
|
||||
<!-- The imaging sensor's swath, to scale across the view. -->
|
||||
<div v-if="sensorStripStyle" class="cockpit-orbital-sensor-strip" :style="sensorStripStyle" aria-hidden="true"></div>
|
||||
<!-- Under the vision selector: where the ground track is. -->
|
||||
<p v-if="placeText" id="cockpit-orbital-over" class="cockpit-orbital-over"><span>{{ t('CURRENTLY OVER') }}</span> <strong>{{ placeText }}</strong></p>
|
||||
<div class="cockpit-orbital-readout">
|
||||
<p class="cockpit-orbital-kicker">{{ look.offset ? t('ORBITAL VIEW · OFF-NADIR') : t('ORBITAL VIEW · NADIR') }}</p>
|
||||
<div class="cockpit-orbital-title">
|
||||
<!-- i18n-ignore: @error is the image's load-failure event, not a status message. -->
|
||||
<img v-if="shownMark?.kind === 'flag'" class="cockpit-orbital-flag" :src="shownMark.url" :alt="shownMark.label" :title="shownMark.label" width="20" height="15" @error="flagFailed = true" />
|
||||
<span v-else-if="shownMark?.kind === 'badge'" class="cockpit-orbital-owner-badge" :title="shownMark.title">{{ shownMark.label }}</span>
|
||||
<p class="cockpit-orbital-name">{{ orbital.name }}</p>
|
||||
</div>
|
||||
<p v-if="orbital.operator" class="cockpit-orbital-operator">{{ orbital.operator }}</p>
|
||||
<p v-if="orbital.classLabel" class="cockpit-orbital-class">{{ orbital.classLabel }}</p>
|
||||
<div v-if="identText" class="cockpit-orbital-ident">
|
||||
<!-- Wraps between parts, never inside a date. -->
|
||||
<span class="cockpit-orbital-ident-text"><template v-for="(part, index) in identParts" :key="index"><template v-if="index"> · </template><span class="cockpit-orbital-ident-part">{{ part }}</span></template></span>
|
||||
<button v-if="tleText" id="cockpit-orbital-tle-toggle" type="button" class="cockpit-orbital-tle-toggle" :aria-expanded="String(tleOpen)" aria-controls="cockpit-orbital-tle" :aria-label="tleOpen ? t('Hide the two-line element set') : t('Show the two-line element set')" :title="tleOpen ? t('Hide the two-line element set') : t('Show the two-line element set')" @click="tleOpen = !tleOpen">{{ t('TLE') }}</button>
|
||||
</div>
|
||||
<pre v-if="tleText" v-show="tleOpen" id="cockpit-orbital-tle" class="cockpit-orbital-tle" :aria-label="t('Two-line element set')">{{ tleText }}</pre>
|
||||
<dl class="cockpit-orbital-data">
|
||||
<div class="cockpit-orbital-datum">
|
||||
<dt>{{ t('ALTITUDE') }}</dt>
|
||||
<dd class="cockpit-orbital-altitude">{{ altitudeText }}</dd>
|
||||
</div>
|
||||
<div v-if="velocityText" class="cockpit-orbital-datum">
|
||||
<dt>{{ t('ORBITAL VELOCITY') }}</dt>
|
||||
<dd class="cockpit-orbital-velocity">{{ velocityText }}</dd>
|
||||
</div>
|
||||
<div class="cockpit-orbital-datum">
|
||||
<dt>{{ t('SUB-SATELLITE POINT') }}</dt>
|
||||
<dd class="cockpit-orbital-subpoint">{{ subPointText }}</dd>
|
||||
</div>
|
||||
</dl>
|
||||
<p class="cockpit-orbital-north">{{ trackUp ? t('TRACK UP') : t('NORTH UP') }}</p>
|
||||
<!-- Shown only while the view is tilted off nadir: where it looks and the way back. -->
|
||||
<div v-if="look.offset" class="cockpit-orbital-look">
|
||||
<span id="cockpit-orbital-look-readout" class="cockpit-orbital-look-readout" :aria-live="look.focus ? 'off' : 'polite'">{{ look.readout }}</span>
|
||||
<button id="cockpit-orbital-nadir" ref="nadirButton" type="button" class="cockpit-orbital-nadir" :aria-label="t('Return the view to nadir')" :title="t('Return to nadir (Home or 0)')" aria-keyshortcuts="Home 0">{{ t('NADIR') }}</button>
|
||||
</div>
|
||||
<p id="cockpit-orbital-focus" class="cockpit-orbital-focus" aria-live="polite">{{ focusText }}</p>
|
||||
</div>
|
||||
<div class="cockpit-orbital-optics">
|
||||
<button id="cockpit-orbital-zoom-out" ref="zoomOutButton" type="button" class="cockpit-orbital-zoom-button" :disabled="atWidest" :aria-label="t('Zoom out')" :title="t('Zoom out (−)')" aria-keyshortcuts="- _">−</button>
|
||||
<span class="cockpit-orbital-zoom" aria-live="polite">{{ zoomText }}</span>
|
||||
<button id="cockpit-orbital-zoom-in" ref="zoomInButton" type="button" class="cockpit-orbital-zoom-button" :disabled="atTightest" :aria-label="t('Zoom in')" :title="t('Zoom in (+)')" aria-keyshortcuts="+ =">+</button>
|
||||
<span v-if="swathText" class="cockpit-orbital-swath">{{ swathText }}</span>
|
||||
<span v-if="sensorText" class="cockpit-orbital-swath cockpit-orbital-sensor-swath">{{ sensorText }}</span>
|
||||
<button v-if="sensorStepShown" id="cockpit-orbital-sensor" ref="sensorButton" type="button" class="cockpit-orbital-sensor-step" :aria-label="t('Zoom to the imaging sensor swath')" :title="t('Zoom to the imaging sensor swath')">{{ t('SENSOR') }}</button>
|
||||
</div>
|
||||
</template>
|
||||
</section>
|
||||
</template>
|
||||
@@ -0,0 +1,164 @@
|
||||
<script setup>
|
||||
import { storeToRefs } from 'pinia';
|
||||
import { computed, onBeforeUnmount, ref, watch } from 'vue';
|
||||
import { formatNumber, t, tn } from '../../../i18n/index.js';
|
||||
import { useCockpitStore } from '../../stores/cockpit.js';
|
||||
|
||||
// The bridge radar: a heading-up scope of nearby AIS vessels, with a line
|
||||
// where the bridge view looks when it is turned off the bow. The Cockpit
|
||||
// controller presents them as positions on the range circle and keeps the
|
||||
// range button's listener; this view draws them. The sweep and each
|
||||
// contact's afterglow are compositor animations sharing one clock, so a
|
||||
// contact brightens as the sweep crosses its bearing without a frame loop.
|
||||
|
||||
/** One sweep turn, in milliseconds. */
|
||||
const SWEEP_MS = 4000;
|
||||
/** Relative bearings of the rim ticks. */
|
||||
const RIM_TICKS = Array.from({ length: 12 }, (_, index) => index * 30);
|
||||
const SWEEP_FRAMES = [
|
||||
{ transform: 'rotate(0turn)' },
|
||||
{ transform: 'rotate(1turn)' },
|
||||
];
|
||||
const GLOW_FRAMES = [
|
||||
{ opacity: 1, offset: 0 },
|
||||
{ opacity: 0.6, offset: 0.2 },
|
||||
{ opacity: 0.25, offset: 1 },
|
||||
];
|
||||
|
||||
const { radar, instruments } = storeToRefs(useCockpitStore());
|
||||
|
||||
// The bridge view's look line: the yaw the view is turned to off the bow,
|
||||
// kept unwrapped so its turn eases the short way across astern. Unwrapping
|
||||
// needs the last angle shown, so it is state a watch keeps, not a computed.
|
||||
const lookDeg = ref(null);
|
||||
watch(
|
||||
() => {
|
||||
const look = instruments.value?.look;
|
||||
return look?.offset && look.yawDeg !== 0 ? look.yawDeg : null;
|
||||
},
|
||||
(yawDeg) => {
|
||||
if (yawDeg === null) {
|
||||
lookDeg.value = null;
|
||||
return;
|
||||
}
|
||||
const from = lookDeg.value ?? 0;
|
||||
lookDeg.value = from + ((((yawDeg - from) % 360) + 540) % 360) - 180;
|
||||
},
|
||||
{ immediate: true },
|
||||
);
|
||||
|
||||
const motionQuery =
|
||||
typeof window.matchMedia === 'function'
|
||||
? window.matchMedia('(prefers-reduced-motion: reduce)')
|
||||
: null;
|
||||
const reducedMotion = ref(Boolean(motionQuery?.matches));
|
||||
const onMotionChange = (event) => {
|
||||
reducedMotion.value = event.matches;
|
||||
};
|
||||
motionQuery?.addEventListener?.('change', onMotionChange);
|
||||
onBeforeUnmount(() =>
|
||||
motionQuery?.removeEventListener?.('change', onMotionChange),
|
||||
);
|
||||
|
||||
/**
|
||||
* Run an element's sweep-phased animation, or stop it (`phaseMs` null).
|
||||
* Each animation starts on the document timeline at its phase, so every
|
||||
* one keeps time with the sweep however late it was created.
|
||||
*/
|
||||
function phase(el, frames, phaseMs) {
|
||||
if (phaseMs === null || typeof el.animate !== 'function') {
|
||||
el._radarAnimation?.cancel();
|
||||
el._radarAnimation = null;
|
||||
return;
|
||||
}
|
||||
if (!el._radarAnimation) {
|
||||
el._radarAnimation = el.animate(frames, {
|
||||
duration: SWEEP_MS,
|
||||
iterations: Infinity,
|
||||
easing: 'linear',
|
||||
});
|
||||
// Cancelling on unmount rejects `finished`; nothing waits on it.
|
||||
el._radarAnimation.finished?.catch(() => {});
|
||||
}
|
||||
// Before zero, so the animation is already running at page start.
|
||||
const startTime = phaseMs - SWEEP_MS;
|
||||
if (el._radarAnimation.startTime !== startTime)
|
||||
el._radarAnimation.startTime = startTime;
|
||||
}
|
||||
|
||||
const vSweep = {
|
||||
mounted: (el) => phase(el, SWEEP_FRAMES, 0),
|
||||
unmounted: (el) => phase(el, SWEEP_FRAMES, null),
|
||||
};
|
||||
|
||||
const vAfterglow = {
|
||||
mounted: (el, { value }) => phase(el, GLOW_FRAMES, value),
|
||||
updated: (el, { value }) => phase(el, GLOW_FRAMES, value),
|
||||
unmounted: (el) => phase(el, GLOW_FRAMES, null),
|
||||
};
|
||||
|
||||
/** When in the sweep's turn a bearing is crossed, or null when steady. */
|
||||
function glowPhase(relativeBearingDeg) {
|
||||
if (reducedMotion.value) return null;
|
||||
const clockwise = (((relativeBearingDeg % 360) + 360) % 360) / 360;
|
||||
return Math.round(clockwise * SWEEP_MS);
|
||||
}
|
||||
|
||||
const percent = (fraction) => `${(fraction * 100).toFixed(2)}%`;
|
||||
const contactStyle = (contact) => ({
|
||||
left: percent(0.5 + contact.x / 2),
|
||||
top: percent(0.5 - contact.y / 2),
|
||||
'--radar-contact-color': contact.color || undefined,
|
||||
});
|
||||
const rotate = (deg) => ({ transform: `rotate(${deg}deg)` });
|
||||
|
||||
const rangeLabel = computed(() => radar.value?.rangeLabel ?? '');
|
||||
const ringFractions = computed(() =>
|
||||
radar.value
|
||||
? radar.value.ringsNm.map((ring) => ring / radar.value.rangeNm)
|
||||
: [],
|
||||
);
|
||||
const ringLabel = computed(() =>
|
||||
radar.value?.ringsNm.length
|
||||
? t('RINGS {spacing} NM', {
|
||||
spacing: formatNumber(radar.value.ringsNm[0]),
|
||||
})
|
||||
: '',
|
||||
);
|
||||
const countLabel = computed(() => {
|
||||
const count = radar.value?.contacts.length ?? 0;
|
||||
return tn(count, '{count} CONTACT', '{count} CONTACTS', {
|
||||
count: formatNumber(count),
|
||||
});
|
||||
});
|
||||
const rangeAction = computed(() =>
|
||||
t('Radar range {range}. Select for the next range.', {
|
||||
range: rangeLabel.value,
|
||||
}),
|
||||
);
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<section id="cockpit-radar" class="cockpit-radar" :aria-label="t('Bridge radar')" :hidden="!radar">
|
||||
<div class="cockpit-radar-scope" aria-hidden="true">
|
||||
<template v-if="radar">
|
||||
<span v-for="fraction in ringFractions" :key="fraction" class="cockpit-radar-ring" :style="{ width: percent(fraction), height: percent(fraction) }"></span>
|
||||
<span v-for="tick in RIM_TICKS" :key="tick" class="cockpit-radar-tick" :class="{ 'cockpit-radar-tick-major': tick % 90 === 0 }" :style="rotate(tick)"></span>
|
||||
<span v-if="!reducedMotion" v-sweep class="cockpit-radar-sweep"></span>
|
||||
<span class="cockpit-radar-heading-line"></span>
|
||||
<span v-if="lookDeg !== null" class="cockpit-radar-look" :style="rotate(lookDeg)"></span>
|
||||
<span v-for="contact in radar.contacts" :key="contact.id" v-afterglow="glowPhase(contact.relativeBearingDeg)" class="cockpit-radar-contact" :class="{ 'cockpit-radar-contact-stale': contact.stale }" :style="contactStyle(contact)">
|
||||
<span v-if="contact.relativeCourseDeg !== null" class="cockpit-radar-vector" :style="rotate(contact.relativeCourseDeg)"></span>
|
||||
</span>
|
||||
<span class="cockpit-radar-own">
|
||||
<span v-if="radar.ownRelativeCourseDeg !== null && radar.ownRelativeCourseDeg !== undefined" class="cockpit-radar-vector cockpit-radar-own-vector" :style="rotate(radar.ownRelativeCourseDeg)"></span>
|
||||
</span>
|
||||
</template>
|
||||
</div>
|
||||
<div class="cockpit-radar-readout">
|
||||
<button id="cockpit-radar-range" type="button" class="cockpit-radar-range" :aria-label="rangeAction" :title="rangeAction">{{ rangeLabel }}</button>
|
||||
<span class="cockpit-radar-rings">{{ ringLabel }}</span>
|
||||
<span class="cockpit-radar-count">{{ countLabel }}</span>
|
||||
</div>
|
||||
</section>
|
||||
</template>
|
||||
@@ -14,17 +14,17 @@ const r = computed(() => route.value ?? initial);
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<section id="cockpit-route" class="cockpit-route-card" :aria-label="t('Estimated flight plan')" :hidden="!r.visible">
|
||||
<section id="cockpit-route" class="cockpit-route-card" :aria-label="r.kind === 'vessel' ? t('Reported voyage') : t('Estimated flight plan')" :hidden="!r.visible">
|
||||
<div class="cockpit-route-heading">
|
||||
<span class="cockpit-route-kicker">{{ t('ESTIMATED FLIGHT PLAN') }}</span>
|
||||
<span class="cockpit-route-kicker">{{ r.kind === 'vessel' ? t('REPORTED VOYAGE') : t('ESTIMATED FLIGHT PLAN') }}</span>
|
||||
<small id="cockpit-route-status">{{ r.status }}</small>
|
||||
</div>
|
||||
<div class="cockpit-route-endpoints">
|
||||
<div class="cockpit-route-airport">
|
||||
<div v-if="r.kind !== 'vessel'" class="cockpit-route-airport">
|
||||
<span>{{ t('FROM') }}</span>
|
||||
<strong id="cockpit-route-from">{{ r.from }}</strong>
|
||||
</div>
|
||||
<span class="cockpit-route-arrow material-symbols-outlined" aria-hidden="true">east</span>
|
||||
<span v-if="r.kind !== 'vessel'" class="cockpit-route-arrow material-symbols-outlined" aria-hidden="true">east</span>
|
||||
<div class="cockpit-route-airport">
|
||||
<span>{{ t('TO') }}</span>
|
||||
<strong id="cockpit-route-to">{{ r.to }}</strong>
|
||||
|
||||
Reference in new issue
Block a user