mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-19 17:52:21 +00:00
Merge branch 'main' into fix/shortcuts-modifier-keys
This commit is contained in:
1214 files changed
+37676
-9143
No files matched your search
+3
-1
@@ -396,7 +396,9 @@ their `this`; one that throws or returns a promise is treated as having
|
||||
failed. What a method returns may carry getters: one that throws when read
|
||||
makes a candidate none, a frame malformed (the view ends) and a HUD view keep
|
||||
the last; a worded member (labels, entry face, look) that throws keeps its
|
||||
last good words.
|
||||
last good words. An entry face's `icon` is a Material Symbols name whose glyph
|
||||
the application's page must load (GEV's own `index.html` loads a subset, its
|
||||
`icon_names`); a glyph the page does not load renders as its name.
|
||||
|
||||
```js
|
||||
import { getLocale, onLocaleChange } from 'gods-eye-view/i18n';
|
||||
|
||||
@@ -781,8 +781,7 @@ palettes use `--gev-field-background`, `--gev-field-border-color`,
|
||||
`--gev-field-color` and `--gev-field-disabled-opacity`. Radio retains its own
|
||||
compact density and arrow space. CCTV owns calibration editor width in
|
||||
`cctv.css`; the shared inline density does not impose a feature-specific width.
|
||||
Cyber supplies a shared-field palette explicitly and keeps its legacy native
|
||||
field rules separate, so Radio's palette remains an intentional exception.
|
||||
Radio's palette remains an intentional exception.
|
||||
|
||||
### Read-only status badges
|
||||
|
||||
|
||||
+653
-171
File diff suppressed because it is too large.
Load diff
@@ -28,7 +28,12 @@ own `.d.ts`:
|
||||
- `gods-eye-view/render/recession`: how a set that recedes shrinks and
|
||||
fades its items toward the limb;
|
||||
- `gods-eye-view/render/windStreamlines`: the wind field's streamlines;
|
||||
- `gods-eye-view/geo/screenCluster`: screen-space clustering.
|
||||
- `gods-eye-view/geo/screenCluster`: screen-space clustering;
|
||||
- `gods-eye-view/fleet`: fleet contacts as the Flights and Vessels layers
|
||||
draw them: the fleet model set and its loader, which model and size an
|
||||
aircraft or a vessel takes, the distances a contact's icon hands over to
|
||||
its model at, how a model is lit, tinted and posed, and the vessel hull
|
||||
sprites.
|
||||
|
||||
`src/render/neutralExports.test.mjs` checks that each is declared, that its
|
||||
names match what it exports, that it type-checks under strict TypeScript and
|
||||
@@ -356,6 +361,18 @@ names the nearest frame's time once every globe tile drawn shows that
|
||||
frame's own imagery (`src/render/cesium/imageryFrames.js`). The checks
|
||||
`globe.imagery.frames` and `globe.imagery.video` cover both.
|
||||
|
||||
It also draws `decoded` sources (`imageryDecoded`): tiles the application
|
||||
makes itself and hands over as finished images. Their slots are times: the
|
||||
source's `slotAt` names the slot a time shows and `prefetch` the slots held
|
||||
ahead, of which the first `prefetch` (the option, 1 by default) load unseen.
|
||||
Each slot is a Cesium imagery layer in the layer's tiling whose tiles are the
|
||||
images the source's `tile` answers, asked as `shown` or `prefetch`; a
|
||||
deferred tile is asked again on a later frame, a missing one draws its
|
||||
parent's, and a slot let go aborts the tiles it still waits on and closes an
|
||||
image that arrives after. A time with no slot draws nothing and announces
|
||||
nothing; `frameReady` names the slot shown once it is drawn. The check
|
||||
`globe.imagery.decoded` covers it.
|
||||
|
||||
Every Cesium draw set takes `setColumns` (`columns`): icon sets on the GPU,
|
||||
any other as the rows the columns make over the items it holds, each row the
|
||||
item of that id with the columns' fields over it, replacing every item as
|
||||
|
||||
@@ -54,8 +54,14 @@ fallback for zero; holds may be zero.
|
||||
|
||||
Visual fields are `style`, `mapStack`, `styleParams`, `bloom`, `sharpen`, `hud`, and
|
||||
`detection`, and `scope`. Bloom has `enabled`, `intensity`, `version`; sharpen has `enabled`,
|
||||
`intensity`; HUD has `visible`, `variant`; detection has `mode`, `density`,
|
||||
`intensity`; HUD has `visible`, `variant` and an optional `sonar`; detection has `mode`, `density`,
|
||||
`allocation`, `fadePct` and `outsideOpacityPct`. Scope has `enabled`, `featherPct`.
|
||||
HUD `sonar: true` is Sonar on beside a layout that cannot say it (Minimal); it
|
||||
is written only then, so Tactical with Sonar stays the variant `cyber` and a
|
||||
shot without Sonar has no `sonar`. A shot without it opens with Sonar on only
|
||||
when its variant is `cyber`. A build from before `sonar` refuses a project
|
||||
that has it, as it refuses any field it does not know; every other project
|
||||
still opens there.
|
||||
The latter settings were written by Update Shot but previously lost during
|
||||
normalization; they now survive import and capture.
|
||||
Version-1/2 bloom without an explicit scale version uses the original inverted
|
||||
|
||||
@@ -134,7 +134,7 @@ probability of about 255 in 256 (many of them already fail as base64url).
|
||||
| 13 | thing | LEN | none | sub-message, see thing views |
|
||||
| 14 | `style` | enum | `normal` | normal, retro, surveillance, thermal, anime, noir, snow (retired) |
|
||||
| 15 | `mapStack` | enum | `photoreal` | photoreal, bing-aerial, bing-labels, esri-imagery, osm |
|
||||
| 16 | `hudVariant` | enum | style | tactical, operator (retired), minimal, cyber |
|
||||
| 16 | `hudVariant` | enum | style | tactical, operator (retired), minimal, cyber (Tactical + Sonar) |
|
||||
| 17 | `bloomIntensity` | uint | style | |
|
||||
| 18 | `bloomVersion` | uint | 2 | |
|
||||
| 19 | `sharpenIntensity` | uint | style | |
|
||||
@@ -176,7 +176,11 @@ Opacity slider (the long form's `sco`). It is written only below 100, so a
|
||||
link made before it, which opens at full opacity, keeps its code.
|
||||
|
||||
Flag bits (field 9): 0 `bloom`, 1 `sharpen`, 2 `hudVisible`, 3
|
||||
`celestialRing` (each defaulting by style), 4 `scopeEnabled` (default on).
|
||||
`celestialRing` (each defaulting by style), 4 `scopeEnabled` (default on), 5
|
||||
`hudSonar` (default off). `hudSonar` is Sonar on beside a HUD layout whose code
|
||||
cannot say so, Minimal (the long form's `hs=1`); Tactical with Sonar stays the
|
||||
`cyber` layout code alone. A link made before the bit has it off, and opens
|
||||
with Sonar on only when it names `cyber`, as before.
|
||||
|
||||
### Style defaults
|
||||
|
||||
@@ -282,6 +286,7 @@ reserved: a decoder ignores that entry, as for collapsed 0.
|
||||
| 8 | `global-context-panel` | `g` | collapsed |
|
||||
| 9 | `pp-toggles` | `p` | collapsed |
|
||||
| 10 | `param-slider-panel` | `m` | expanded |
|
||||
| 11 | `space-missions-panel` | `n` | collapsed |
|
||||
|
||||
### Style parameters (field 27)
|
||||
|
||||
|
||||
+133
-17
@@ -37,14 +37,40 @@ one-panel rule too. Share links continue to record which panels are open.
|
||||
## Component kit
|
||||
|
||||
`src/ui/kit/` holds the generic components: `UiRail`, `UiTooltip`, `UiIcon`,
|
||||
`UiButton`, `UiPanel`, `UiSegmented`, `UiSlider`, `UiChip`, `UiSelect`,
|
||||
`UiBadge` and `UiEmpty` so far, with more joining as the controls they serve
|
||||
are converted. One component
|
||||
`UiButton`, `UiCloseButton`, `UiPanel`, `UiSegmented`, `UiSlider`, `UiChip`,
|
||||
`UiSelect`, `UiSearchField`, `UiCheckbox`, `UiDialog`, `UiBadge` and `UiEmpty` so far, with more
|
||||
joining as the controls they serve are converted. One component
|
||||
serves every use of a control, with props for the differences (`UiPanel`'s
|
||||
`sideways`, `glow`, `scroll`), rather than a copy per panel. The components
|
||||
are styled by the existing stylesheet and custom properties; a kit class such as
|
||||
`ui-button--icon` carries no Core style yet, and a converted control keeps
|
||||
its own classes beside it. They contain no application state.
|
||||
are styled by the existing stylesheet and custom properties, and they contain
|
||||
no application state. The kit's own classes wear Core's standard looks, each
|
||||
sharing one selector list with the Core skin it comes from, so the rules are
|
||||
never copied:
|
||||
|
||||
| Kit class | Look | Rules |
|
||||
| --- | --- | --- |
|
||||
| `UiButton` `variant="ghost"` (default) | none: the caller's classes style it | — |
|
||||
| `UiButton` `variant="action"` | the action surface (`gev-action-button`); `tone="danger"` hovers red, `size="compact"` is the shot-row footprint (on this variant only) | `src/ui/styles/action-button.css` |
|
||||
| `UiButton` `variant="primary"` | the action surface with a group's main-action accent | `src/ui/styles/action-button.css` |
|
||||
| `UiButton` `variant="icon"` | the 22px square glyph button of a panel's collapse toggle | `src/ui/styles/controls.css` |
|
||||
| `UiCloseButton` | a close, dismiss or clear button: a bare glyph (× with `glyph="times"`, the Material `close` symbol with `glyph="icon"`) with no padding, border or background of its own and a pointer; the site's feature class sets size, colour, hover and any surface, and `bare` leaves the look off for a skin that sets its own padding and border | `src/ui/styles/close-button.css` |
|
||||
| `UiSearchField` | a search field: the Material `search` glyph and a search input in a flex row, the input bare (no border or background, free to shrink); the site's feature classes set the frame's size, surface and focus ring and the input's type and outline, and the browser's own cancel button is left to each skin | `src/ui/styles/search-field.css` |
|
||||
| `UiCheckbox` | a checkbox: a label wrapping a native box and its words in a centred flex row; the box keeps each site's size, margin and accent colour, and the site's feature class sets the row's gap, direction and colour | `src/ui/styles/checkbox.css` |
|
||||
| `UiDialog` | none: a native modal `<dialog>`; the site's feature class or inline style draws it | — |
|
||||
| `UiChip` | the read-only chip (a pill of uppercase mono text); `selected` takes the accent | `src/ui/styles/chip.css` |
|
||||
| `UiEmpty` | the one-line empty state (dim mono text), its hint on a line below | `src/ui/styles/empty-state.css` |
|
||||
| `UiBadge` | the read-only badge (`gev-status-badge`) | `src/ui/styles/status-badge.css` |
|
||||
| `UiSegmented` | the segmented control (`gev-segmented`, `gev-segment`) | `src/ui/styles/segmented-control.css` |
|
||||
|
||||
A pressed action, primary or icon button looks as a hovered regular one does
|
||||
(a compact action's quieter hover is for an unpressed button), and a disabled
|
||||
one dims and ignores hover and press. `tone` is `accent` or `danger`, and
|
||||
`size` styles the action variant only. Each look's resting rule selects one
|
||||
kit class; the button, chip and empty-state skins load before the feature
|
||||
stylesheets that restyle them, so a feature class still wins. The badge and
|
||||
segmented skins are the stylesheets their Core classes always used. A
|
||||
converted control keeps its own classes beside the kit's.
|
||||
`src/ui/kit/kitStyles.test.mjs` pins these rules.
|
||||
`UiPanel` takes a `title`, slots and `v-model:collapsed`, but its
|
||||
`collapsed` drives only the button and `ui-panel--collapsed`: the root's
|
||||
`collapsed` class, which hides the body, is drawn at once by `v-panel-state`
|
||||
@@ -63,6 +89,22 @@ tilt-map button, whose owners still write their state into the DOM. Core's
|
||||
pressable chips and pills (rail card chips, map sources, cities and places)
|
||||
are `UiButton`s too; `UiChip` is a non-interactive label chip, used by
|
||||
the voice card.
|
||||
The welcome card's buttons (SKIP, the three start tiles, BROWSE STORIES,
|
||||
BACK and the main NEXT / ENTER GOD MODE action) are ghost `UiButton`s:
|
||||
the start tiles are pressed toggles, and all but SKIP keep `aria-disabled`
|
||||
rather than `disabled`, so they stay focusable while the card is busy. Its
|
||||
tile, tip, Stories and arrow glyphs are `UiIcon`s with `:size="null"`, so
|
||||
first-run.css still sizes them (`src/ui/kit/welcomeControls.test.mjs` pins
|
||||
it). God mode's preview globe and callouts stay inline SVG drawings, and
|
||||
its outbound links stay links.
|
||||
The Omnibar's mic (a pressed toggle with `active`) and its suggestion
|
||||
strip's chips (options, so `aria-current` rather than `pressed`) are
|
||||
ghost `UiButton`s, and its search, row and chip glyphs are `UiIcon`s with
|
||||
`:size="null"`, so its own rules still size them
|
||||
(`src/ui/kit/omnibarControls.test.mjs` pins it). The mic's and the chat
|
||||
row's glyphs stay inline SVG, since no Material symbol the page loads
|
||||
draws them, and its field is its own combobox rather than a
|
||||
`UiSearchField`.
|
||||
`UiSelect` renders the bare native select (Core's labels sit outside it or
|
||||
come as an `aria-label`) with `v-model`, `options` and `disabled`;
|
||||
options that carry their own attributes come through the slot, a caller's
|
||||
@@ -74,9 +116,62 @@ gain) takes `hold`. Every select in the views is a `UiSelect`.
|
||||
density variants and colours stay caller classes, and it renders the CCTV
|
||||
source and calibration badges and the rail card badges. `UiEmpty` takes
|
||||
a `title` and `hint`, but Core's empty states are one line, so the title
|
||||
is the text itself rather than a bold heading; the Scene shot list, mission
|
||||
roster and imagery strip use it. The locale picker's and the mission tables'
|
||||
is the text itself rather than a bold heading; the News feed, Scene shot
|
||||
list, mission roster and imagery strip use it. The locale picker's and the mission tables'
|
||||
empty rows stay a paragraph and table cells.
|
||||
`UiCloseButton` is a `UiButton` with a fixed glyph, a required `label` and
|
||||
no tip unless the site passes a `title`; attributes and classes pass through,
|
||||
so each site keeps its id, feature class and look. Every close, dismiss and
|
||||
clear button in the views is one (`src/ui/kit/closeButtons.test.mjs` pins
|
||||
it); Street Level's and the space mission's keep `bare`, since their skins
|
||||
set their own padding and border, and so does the credits list's. The
|
||||
Quebec CCTV overlay's close is one too, and so is the Omnibar guide's,
|
||||
which keeps its feature class and tip.
|
||||
`UiSearchField` takes `v-model`, a required `label` (the input's
|
||||
accessible name), `placeholder` and `tag` (`div`, given `role="search"` by
|
||||
the site, or `label`); attributes and classes go to the frame, and
|
||||
`inputId`, `inputClass`, `autocomplete` and `spellcheck` to the input. With
|
||||
`clearLabel` it shows a `UiCloseButton` (`clearClass`, its label as its tip)
|
||||
while text is typed, which empties the field and focuses the input again.
|
||||
Escape stops at the input and is emitted with its event, so a site that also
|
||||
keeps the browser from clearing the field prevents it there; `focus()`
|
||||
focuses the input. The Context search and the Layer Finder's are
|
||||
`UiSearchField`s; the locale picker's combobox, the Omnibar's location
|
||||
field and the Data Library's labelled search are other controls. Its kit rules hold the declarations both search
|
||||
skins had in common, moved rather than copied, and load before them.
|
||||
`UiCheckbox` is a `<label>` wrapping a native `<input type="checkbox">` and
|
||||
its default slot; `trailing` puts the box after the words, as the Visual
|
||||
panel's rows have it. It takes `v-model` (the change emits the checked state)
|
||||
and emits `change` with its event; without a `modelValue` the box is the
|
||||
browser's own, as the welcome card's "Don't show this again" is, whose
|
||||
owner puts a refused save back itself. `restore` puts the box back to
|
||||
`modelValue` once a change has rendered without the owner taking it, so the
|
||||
voice panel's quick commands and Voice Preview show the applied value after
|
||||
a refused change. Attributes and classes go to the label; `inputId` and
|
||||
`inputAttrs` (such as `aria-describedby` or a data hook) to the box. The
|
||||
Visual panel's Scope, sky and application toggles, the voice and chat
|
||||
preferences, the Data Library's filter and the welcome card's box are
|
||||
`UiCheckbox`es (`src/ui/kit/checkboxes.test.mjs` pins it); Story Explore's
|
||||
filters are not converted yet. Its kit rule holds the centred row the
|
||||
checkbox-only labels drew, moved rather than copied.
|
||||
`UiDialog` is a native `<dialog>` its owner opens and closes with `open`:
|
||||
true opens it with `showModal()` (on mount, for one mounted open), false
|
||||
closes it, and unmounting closes it. Each change is applied once the content
|
||||
has rendered and then emitted as `opened` or `closed`, so the Data Library
|
||||
focuses its search field on open and returns focus to Browse on close.
|
||||
Escape's `cancel` is prevented and emitted as `dismiss`, so the owner
|
||||
decides; `backdropDismiss` makes a click on the dialog itself, outside its
|
||||
content, a `dismiss` too. When the browser closes the dialog on its own
|
||||
while `open` is still true (an Escape the page may not cancel),
|
||||
`browserClose` tells the owner; closing on unmount reports nothing. A DOM
|
||||
without `showModal()` leaves it closed rather than failing. Attributes,
|
||||
classes, styles and listeners go to the dialog, and `element` is exposed.
|
||||
The Data Library and the scene sharing dialogs are `UiDialog`s
|
||||
(`src/ui/kit/dialogs.test.mjs` pins it); the panels drawn as
|
||||
`role="dialog"` (key setup, the welcome launcher, the CCTV popup, Story
|
||||
Explore's filter, the credits) and the render failure's `alertdialog` are
|
||||
other controls. The two dialogs share no declarations, so it has no kit
|
||||
rules.
|
||||
`UiSlider` keeps the native range input rather than drawing a
|
||||
`role="slider"` track, so Core's keyboard, form behaviour and styling stay;
|
||||
it takes `v-model`, `min`, `max`, `step` and `disabled`, emits a
|
||||
@@ -92,14 +187,19 @@ a functional component would not render again.
|
||||
|
||||
Controls share one skin, so every panel reads the same. Every scrolling
|
||||
surface carries the kit's `.ui-scroll`, which draws the thin
|
||||
themed scrollbar from `--scroll-thumb` and `--scroll-track`; the Cyber theme
|
||||
sets those two tokens, and Cockpit's HUD windows keep their accent tint. A
|
||||
themed scrollbar from `--scroll-thumb` and `--scroll-track`, and Cockpit's HUD windows keep their accent tint. A
|
||||
surface without it would draw the platform's light scrollbar, because the
|
||||
page declares no dark `color-scheme`. Selects and number fields are
|
||||
`.gev-field`, which draws its own chevron in place of the platform's arrow
|
||||
and keeps native spinners dark; ranges are `.gev-quantitative-slider`, with
|
||||
a feature supplying only its accent.
|
||||
|
||||
`t()` is not reactive. Words a view passes to a kit component as a prop
|
||||
(`UiCloseButton`'s `label`) follow a locale change on the view's next
|
||||
render, but words in a kit component's slot do not: the compiled slot does
|
||||
not render the child again. A view whose words must follow the locale at
|
||||
once passes the locale itself as a prop or key, as the credits line does.
|
||||
|
||||
## Phases
|
||||
|
||||
1. **Foundation.** Vue, Pinia and the Vite Vue plugin join the browser build
|
||||
@@ -167,8 +267,13 @@ a feature supplying only its accent.
|
||||
the whole panel from the `gev-cctv` store, including the camera picker,
|
||||
the inline pose editor, the frame preview, source badge and typed
|
||||
summary; `CctvControls` keeps its listeners, the frame requests and the
|
||||
live video surface), Layers (done: `LayerPanel` presents each row and
|
||||
renders `LayerRows` synchronously; keyed chips and list items keep focus
|
||||
live video surface; `QuebecCctvOverlay` teleports the Québec 511 player
|
||||
and its map preview to the end of the body, rendered synchronously by
|
||||
`createQuebecCctvOverlay()` from the view it computes, as the rail cards
|
||||
are; the owner keeps every decision and the parts the template never
|
||||
binds: each video's source, playback and refresh timer, the window's drag
|
||||
and the marker's per-frame visibility and place), Layers (done:
|
||||
`LayerPanel` presents each row and renders `LayerRows` synchronously; keyed chips and list items keep focus
|
||||
through the refresh their own click triggers, and clicks re-read the live
|
||||
descriptor before acting), Display (in progress: `DisplayPanel` renders
|
||||
the HUD, Sonar, Scope, Celestial, detection, bloom, sharpen and the
|
||||
@@ -213,7 +318,11 @@ a feature supplying only its accent.
|
||||
`gev-location` store, and the search field keeps its listeners; beside
|
||||
the voice control, the dock teleports each voice pointer reticle to the
|
||||
body where its `PointerReticle` presents it in the `gev-pointer-reticle`
|
||||
store), the phone shell (`PhoneTabBar` renders the tabs and open sheet the shell
|
||||
store; `startGuide()` renders the Omnibar's guided walk, `OmnibarGuide`,
|
||||
synchronously from the view it computes for each step, teleported to the
|
||||
end of the body, and keeps every decision and word, focus and its return,
|
||||
Escape, the entrance replay, and the callout's and spotlight rings' place
|
||||
each frame), the phone shell (`PhoneTabBar` renders the tabs and open sheet the shell
|
||||
publishes to the `gev-display` store, teleporting the tab bar and sheet
|
||||
backdrop to the end of the page from the first publish until the shell
|
||||
is destroyed; the shell takes their clicks from the document), the
|
||||
@@ -291,7 +400,14 @@ a feature supplying only its accent.
|
||||
choices, DISMISS and "Don't show this again" call the launcher's
|
||||
controls; a refused save hands the tick back to the view to revert. The
|
||||
launcher still reads the rendered card for its hit test, keyboard trap,
|
||||
focus and overflow measurement), then
|
||||
focus and overflow measurement), the attribution line (for a renderer
|
||||
without its own credit display, `mountCreditsView()` renders
|
||||
`CreditsView` synchronously, as the weather readout is, and the view
|
||||
teleports the line and its "Data attribution" list to the end of the
|
||||
body, where the page's rules select them; the owner keeps the credits
|
||||
shown, the list's open state and its focus, and words the view again
|
||||
when the locale changes; the list's close button is a bare
|
||||
`UiCloseButton`), then
|
||||
Cockpit (in progress: `CockpitBriefing` renders the briefing card's
|
||||
pages, cycle toggle, regional news and local conditions, and
|
||||
`CockpitContext` the Contact card's scope, navigation, counts, nearest
|
||||
@@ -338,8 +454,8 @@ a feature supplying only its accent.
|
||||
records surface by surface; [Building UI](../CONTRIBUTING.md#building-ui)
|
||||
now requires the pattern for new UI. The page-level markup tests read
|
||||
`renderApplicationHtml()`, the real views rendered on the server, and new
|
||||
tests mount components; three tests still read a `.vue` file's source
|
||||
(`cyberTheme`, `panelStorageDocs`, `geoFileImport`). The views translate with `t()`
|
||||
tests mount components; two tests still read a `.vue` file's source
|
||||
(`panelStorageDocs`, `geoFileImport`). The views translate with `t()`
|
||||
while rendering, and vue-i18n holds the locale they read; the attribute
|
||||
translation pass is left for static page markup (the loading screen and a
|
||||
host's own markup). An explicit API for hosts to register panels and rail items is
|
||||
@@ -361,7 +477,7 @@ a feature supplying only its accent.
|
||||
- Panels lifted out of a view keep its verbatim markup in
|
||||
`src/ui/views/panels/`, which Prettier leaves alone like the views.
|
||||
- Visual parity: before/after screenshots of every panel at desktop and phone
|
||||
widths, in the default and Cyber themes, with the rail as the only expected
|
||||
widths, in the default theme, with the rail as the only expected
|
||||
difference.
|
||||
- Browser QA: the selector-based `scripts/qa-*.mjs` suites keep passing.
|
||||
- `npm run format:check`, `npm run check:boundaries`, `npm run i18n` and
|
||||
|
||||
+9
-11
@@ -1,9 +1,8 @@
|
||||
# Panel surface contract
|
||||
|
||||
`src/ui/styles/panel-surfaces.css` supplies an opt-in visual surface for new
|
||||
panels. It uses the application's default color, font, border and radius tokens;
|
||||
Cyber supplies its existing red/slate palette, monospace typography and shaped
|
||||
frame. This is CSS shared by the existing panel system, not a panel registry or
|
||||
panels. It uses the application's default color, font, border and radius tokens.
|
||||
This is CSS shared by the existing panel system, not a panel registry or
|
||||
a controller. A panel ID does not need a new theme selector.
|
||||
|
||||
## Markup
|
||||
@@ -57,13 +56,12 @@ fit when those contents should instead scroll.
|
||||
| Mount | Shared contract | Owner responsibilities |
|
||||
| ------------------------------------- | --------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| Direct child of `#left-panel-stack` | An owner with a direct `[data-panel-surface]` child receives relative positioning and allocated height; inner surface/body skin | Add the wrapper shown above, use the existing layout/disclosure owners, and retain left-rail focus/auto-collapse rules. |
|
||||
| Direct child of `#right-context-rail` | The same hooks with right-rail allocation and intrinsic measurement | Keep `data-rail-scroller` on the body so measurement preserves its scroll position. Respect Cyber's one-expanded-panel policy. |
|
||||
| Direct child of `#right-context-rail` | The same hooks with right-rail allocation and intrinsic measurement | Keep `data-rail-scroller` on the body so measurement preserves its scroll position. |
|
||||
| Surface inside `#command-dock` | Surface, controls, popup decoration and inherited dock concealment | Supply geometry, stacking, disclosure, pin behavior if wanted, safe viewport bounds and dismissal. This CSS does not extend the existing Location/Visual Presets tray stack manager to arbitrary panels. |
|
||||
| `dialog[data-panel-surface]` | The same surface/body skin; a closed dialog remains hidden | Set width/max-height, use `showModal()` or `show()` and `close()`, and own labels, initial/return focus and dismissal. Do not put `panel-collapsible` on a dialog. |
|
||||
|
||||
For rails, `--panel-expanded-width` and `--panel-collapsed-width` customize
|
||||
the desired widths within the rail; otherwise Cyber uses its existing left,
|
||||
right and collapsed panel widths. `--left-panel-allocated-height` and
|
||||
the desired widths within the rail. `--left-panel-allocated-height` and
|
||||
`--right-panel-allocated-height` belong
|
||||
to the existing layout owner, not to individual panels. The surface must be
|
||||
the wrapper's first non-glow child because left-rail intrinsic measurement
|
||||
@@ -121,9 +119,9 @@ dismiss open popups/dialogs and restore focus before removing a dynamic panel.
|
||||
|
||||
## Decoration, popups and visibility
|
||||
|
||||
The shared surface reserves `::before` for its non-interactive background. The
|
||||
Cyber frame clips this pseudo-element only; the surface stays unclipped with
|
||||
visible overflow. This follows the existing Display and Global Context pattern.
|
||||
The shared surface reserves `::before` for its non-interactive background; the
|
||||
surface stays unclipped with visible overflow. This follows the existing
|
||||
Display and Global Context pattern.
|
||||
Putting the shape on an interactive ancestor clips all descendant popups even
|
||||
if their `z-index` is high. A scrolling body also clips descendants by design,
|
||||
so outward popups must be siblings of the body, or use an explicitly owned
|
||||
@@ -148,8 +146,8 @@ visible.
|
||||
|
||||
## Check an addition
|
||||
|
||||
Use the real application with the default and Cyber themes. Check open,
|
||||
collapsed, hidden, disabled/error, theme round trips, clean UI/recording and
|
||||
Use the real application with the Tactical and Minimal HUD layouts. Check open,
|
||||
collapsed, hidden, disabled/error, layout round trips, clean UI/recording and
|
||||
the intended Cockpit behavior. Exercise keyboard focus, Escape, pointer input,
|
||||
the last scrolling item, resize without reload and any pin/unpin controls.
|
||||
For an outward popup, test visible pixels and pointer hit-testing outside the
|
||||
|
||||
@@ -65,7 +65,6 @@ The `many` form is the `other` text with «de» after the number: «{count} de c
|
||||
| detection overlay | superposición de detección |
|
||||
| pin (Draw tool) | marcador |
|
||||
| Bloom / Glow (visual effect) | resplandor |
|
||||
| Cyber (HUD layout, effect) | Ciber |
|
||||
| heading, course / altitude / ground speed | rumbo / altitud / velocidad respecto al suelo (short: VEL. SUELO) |
|
||||
| HDG / BRG / CRS / FOV / DEST / SPD / RANGE | HDG / BRG / CRS / FOV / DEST / SPD / RANGE (unchanged) |
|
||||
| PREV / NEXT | ANT. / SIG. |
|
||||
|
||||
@@ -82,7 +82,6 @@ The `many` form is the `other` text with « de » (« d' » before a vowel) afte
|
||||
| Recent Imagery / box | imagerie récente / zone |
|
||||
| Daily overview / overview (Recent Imagery VIIRS product) | vue quotidienne (one name for the product, not « vue d'ensemble ») |
|
||||
| pin (Draw tool) / pin (Recent Imagery) | épingle / épingler |
|
||||
| Cyber (HUD layout, effect) | Cyber |
|
||||
| heading / course (ground track) / altitude / ground speed | cap / route / altitude / vitesse sol |
|
||||
| HDG / BRG / CRS / FOV / DEST / SPD / ALT | unchanged |
|
||||
| RANGE / PITCH / HGT (CCTV calibration chips) | PORTÉE / INCL. / HAUT. |
|
||||
|
||||
@@ -82,7 +82,7 @@ The `many` form is the `other` text with «di» after the number when a noun fol
|
||||
| briefing / panel / dock | briefing / pannello / dock |
|
||||
| cockpit | cockpit |
|
||||
| preset / visual preset | preset / preset visivo |
|
||||
| Tactical / Minimal / Cyber | Tattico / Minimale / Cyber |
|
||||
| Tactical / Minimal | Tattico / Minimale |
|
||||
| Scope (circular viewport mask) / keyhole | scope / foro |
|
||||
| feather / fade | sfumatura / dissolvenza |
|
||||
| detection overlay | overlay di rilevamento |
|
||||
|
||||
@@ -61,7 +61,7 @@ Translation source: abiyeenzo (#913).
|
||||
| scene / shot | シーン / ショット |
|
||||
| briefing / panel / dock | ブリーフィング / パネル / ドック |
|
||||
| preset / visual preset | プリセット / ビジュアルプリセット |
|
||||
| Tactical / Minimal / Cyber | タクティカル / ミニマル / サイバー |
|
||||
| Tactical / Minimal | タクティカル / ミニマル |
|
||||
| Scope (circular viewport mask) / keyhole | スコープ / キーホール |
|
||||
| Clean UI | クリーンUI |
|
||||
| cockpit | コックピット |
|
||||
|
||||
@@ -91,7 +91,6 @@ The `many` form is the `other` text with «de» after the number: «{count} de c
|
||||
| feather / fade | suavização / esmaecimento |
|
||||
| detection overlay | sobreposição de detecção |
|
||||
| pin (Draw tool) / box (Recent Imagery) | marcador / área |
|
||||
| Cyber (HUD layout, effect) | Ciber |
|
||||
| heading / course / altitude / ground speed | rumo / curso (a ship's course: rumo) / altitude / velocidade solo (VELOC. SOLO) |
|
||||
| map heading / bearing (compass, north up) | orientação (do mapa) |
|
||||
| HDG / BRG / CRS / FOV / DEST / SPD / RANGE | HDG / BRG / CRS / FOV / DEST / SPD / RANGE (unchanged) |
|
||||
|
||||
@@ -43,7 +43,7 @@ Translation sources: abiyeenzo (#914) and EDIT-Aeterna (#979).
|
||||
| briefing / panel / dock | 简报 / 面板 / 停靠栏 |
|
||||
| preset / visual preset | 预设 / 视觉预设 |
|
||||
| Display / HUD layout | 显示 / HUD 布局 |
|
||||
| Tactical / Minimal / Cyber | 战术 / 精简 / 赛博 |
|
||||
| Tactical / Minimal | 战术 / 精简 |
|
||||
| Scope (circular viewport mask) / keyhole | 视域 |
|
||||
| Clean UI | 纯净界面 |
|
||||
| cockpit | 座舱 |
|
||||
|
||||
Reference in new issue
Block a user