You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .agents/skills/gettokens-domain-engineering/SKILL.md
+6-2Lines changed: 6 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,6 +40,7 @@ This skill unifies the technical rules for building, styling, and debugging GetT
40
40
3. keep deep-link restoration and detail hash behavior intact while changing layout
41
41
4. lock the new density with focused tests that assert structure, module ordering, and route restoration
42
42
- For account detail surfaces, keep top-of-page runtime summaries limited to live operational signals. Quota, balance, raw auth content, and export/route controls should live in their own sections rather than repeating in the runtime strip.
43
+
- Detail modals backed by frame hash state must update their local detail state synchronously when opening or closing before relying on `hashchange`. If close only clears `selectedAccount` while the old `detail` value is still in local state, the hydration effect can reopen the modal and make the close button require two clicks.
43
44
44
45
## 2. Feature / Page Boundary
45
46
-**Pages**: `frontend/src/pages/*` should be route wrappers, not long-lived business implementation files.
@@ -156,8 +157,10 @@ This skill unifies the technical rules for building, styling, and debugging GetT
156
157
- For streaming / active / reconnecting requests without `completedAt`, project `totalDurationMs` from `nowMs - startedAt` with a bounded safety cap. Do not mutate the original request or invent first-event / first-token timings.
157
158
- Only the current active request is allowed to use `nowMs - startedAt` projection in the timing trend. Historical request rows that still carry `streaming` / `reconnecting` from cache or stale sidecar state must keep their recorded `timing.totalDurationMs` or `completedAt - startedAt`; otherwise every total-duration point will grow together.
158
159
- Trend chart x positions should use request timestamps inside a fixed recent window, not array index spacing or request min/max auto-fit. The default frontend window is 5 minutes: filter out older request points, set the x-domain to `latestStartedAt - windowMs` through `latestStartedAt`, and compute y-axis maxima only from points still inside the window.
159
-
- Trend chart viewport should follow the latest request sample only when the user has not panned history. New request points may auto-scroll to the right edge; time-based refresh without new request timestamps must not move the x viewport. If the user horizontally scrolls or drags the chart away from the right edge, pause auto-follow until they scroll back to the latest edge.
160
+
- Trend chart viewport should be a fixed, non-scrollable heartbeat strip chart. Keep a stable time density with the latest request anchored near the right edge: wider surfaces can reveal more of the recent window, narrower surfaces show fewer recent samples. Do not reintroduce horizontal panning or auto-scroll follow logic.
160
161
- Keep the live-session chart visually inside the page section, not as a nested card. Use the existing Swiss-industrial chart tokens, footer summaries below the graph, and live markers such as dashed strokes/rings for in-flight samples.
162
+
- Request timing trend visuals should read closer to an ECG / request heartbeat than a smooth finance area chart. Keep the data-driven timestamp x-axis and metric values, but render the selected timing metric as angular pulse segments with no filled area; use stroke weight, opacity, color, and live rings to distinguish the active metric from the others.
163
+
- The request timeline inside the detail pane is a recent-scan surface, not the full history list. Render only the latest 15 sorted request rows and keep the visible row count aligned with that cap; rely on history/detail data for deeper inspection.
161
164
- Browser preview data for timing charts must include multiple completed requests plus one in-flight request, so `#frame=codex&workspace=live-sessions` exercises curve shape, latest sample footer, and live marker behavior without a Wails runtime.
162
165
- Regression coverage for this class should include pure trend model tests, source-structure tests for live refresh / timestamp x-axis, preview multi-sample assertions, `typecheck`, `build`, focused `model.test.mjs`, and at least one browser/DevTools DOM or screenshot check that the chart renders nonblank.
163
166
-**Account Route Guard & WebSocket Hot Switch**:
@@ -287,7 +290,7 @@ This skill unifies the technical rules for building, styling, and debugging GetT
- Module headers must use the standardized `AccountDetailSectionHeader` path inside `AccountDetailSection`; do not hand-roll per-module eyebrow/title/meta/action headers in account detail body modules.
289
292
- Header-level module actions such as add-row/add-model belong in `AccountDetailSection``actions` so they render at the module header's top right. Do not leave primary row-creation actions at the bottom of dense editor sections.
290
-
- Wide detail modals should use `AccountDetailModuleStack layout="cards"` for editable modules so sections can occupy multiple columns. Single-column module stacks waste space on detail-sized modals.
293
+
- Wide detail modals should usually use `AccountDetailModuleStack layout="cards"` for editable modules so sections can occupy multiple columns. Use `cardColumns={1}` when a variant is a dense form/editor surface, such as OpenAI-compatible provider detail, where two-column cards create large empty regions or squeeze row controls.
291
294
- Use `span="wide"` for modules with horizontal data, tables, textareas, rule rows, quota/billing editors, or model catalogs so the card grid does not compress operational controls.
292
295
- Runtime information that already exists on account cards (recent requests, tokens, cached tokens, latency, quota windows, balance) should be shown in details through `AccountRuntimeSnapshotSection`, not by embedding account cards inside the modal. In the runtime section, quota and balance should share the `quota-balance` resource grid so wide modals can compare them side by side.
293
296
- Runtime snapshot and evidence should sit together in `AccountDetailOverviewGrid` near the top of the detail body, instead of sending evidence to a disconnected secondary sidebar. The runtime and evidence sections must stretch to equal height in wide overview rows.
@@ -296,6 +299,7 @@ This skill unifies the technical rules for building, styling, and debugging GetT
296
299
- Save actions for detail-page modules should follow the page/modal footer when the edit affects persistent account configuration. Individual sections may keep local actions such as add row, delete draft row, verify, fetch models, or copy.
297
300
- OpenAI-compatible and Codex route-row details are account detail variants; keep them visually aligned with `UnifiedAccountDetailModal` even when their controller/state logic remains separate.
298
301
- Account creation/configuration modals such as `UnifiedComposeModal` should reuse account detail primitives instead of hand-rolled form shells. Keep configuration flows in named sections, localize visible menu labels and section eyebrows, and preserve the existing submit callbacks while changing layout.
302
+
- OpenAI-compatible provider details should defer runtime/evidence split until very wide viewports and keep model rows responsive: model and alias inputs may split at medium width, but destructive row actions must stay horizontal and only join the row when there is enough width.
299
303
-**Rotation Cards**: `AccountRotationModal` is a variant of the account card, not a second visual system. Reuse the account-card content hierarchy and only replace the bottom action strip plus rotation-only affordances such as rank rail and drag marker.
300
304
-**Rotation Disable Semantics**:
301
305
- Disabled accounts stay in the saved rotation order.
0 commit comments