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
After Issue #19 has built the Configurações skeleton (which deliberately hides the Registros Settings step button until this issue lands), populate the <section id="registros"> placeholder inside #view-settings with the existing Logs surface, reveal the Registros step button, and remove the Logs primary-nav surface. Use the tiny openSettingsSection("registros") helper and the shared showSettingsStep(n) step-activation mechanism (introduced by #19). State remains in-memory only.
After Issue #19 lands, #view-settings contains the populated Operação / Detecção / Notificações / Sistema sections (each already showing its full form) plus the populated empty <section id="fr24"> and <section id="registros"> anchor containers. The Registros Settings step button is hidden (and remains hidden until this issue lands). The Settings step activation logic is the shared, externally-callable showSettingsStep(n) introduced by #19.
#view-logs (app/static/index.html:242-275) currently contains:
Provider filter (populated dynamically from PROVIDER_INFO).
Hex search input.
Inside-only checkbox.
Help button (#logs-help + #logs-help-text).
Error message area (#logs-error).
Summary (#logs-summary).
Table (#logs-body) with columns: time / kind / provider / region / detail / aircraft / disposition.
Pagination prev/next (#logs-prev, #logs-next).
API: GET /api/logs returns rows with recorded_at, kind, provider, region_id, detail, aircraft_hex, inside, area_names, classification, disposition, plus pagination total / offset / limit.
Filter and pagination state lives in appState.logsFilter / appState.logsOffset (in-memory only). There is no persistence across full browser reload — that behavior is unchanged.
The current loadLogs() orchestrator (app/static/app.js:1264) is the existing logs data-loading path; it is reused by app/static/app.js:1563 / :1599 whenever the Logs tab is activated.
Prerequisite
Issue #19 (Configurações IA) has created the <section id="registros"> placeholder inside #view-settings, the shared showSettingsStep(n), and openSettingsSection(sectionId). The Registros Settings step button is hidden. This issue is the one that reveals it.
UX target
Inside #view-settings, the Registros section renders the same content the standalone Logs tab exposes today:
The structure is identical — only the location moves. Filter and pagination state remain in-memory only (no persistence across reload); this issue MUST NOT add persistence behavior that doesn't exist today.
Atomic reveal (this issue owns this)
Because Issue #19 deliberately hides the Registros step button until this issue lands, this issue MUST atomically:
Populate <section id="registros"> inside #view-settings with the existing logs surface.
Add / unhide the Registros Settings step button. It uses the shared showSettingsStep(n) mechanism for ARIA / visible state.
Wire the Registros step activation to trigger the existing loadLogs() data-loading path.
Remove the old Logs primary-nav surface (tab-logs, view-logs, the tab.dataset.view === "logs" branch in the tab activation handler).
Remove the Logs entry from the #nav-overflow overflow menu.
Loading semantics
Merely moving Logs DOM into <section id="registros"> inside #view-settings does NOT cause the existing Settings tab activation to call loadLogs(). This issue wires the Logs loader explicitly:
The shared step activation mechanism (showSettingsStep(n)) optionally invokes a section-specific loader. For Registros, attaching loadLogs() to step activation means opening Configurações › Registros — whether by clicking the Settings stepper, by openSettingsSection("registros"), or by any other activation path — triggers loadLogs().
Other Settings step activations (#operacao, #deteccao, #notificacoes, #fr24, #sistema) do NOT trigger loadLogs(). They use their existing loaders.
The Logs table may use a horizontal scroll on narrow viewports (preserved from the existing Logs surface). This is intentional inner-container scrolling, not page-level horizontal scroll.
Reveal the Registros Settings step button. It uses the shared showSettingsStep(n) mechanism.
Wire Registros step activation to trigger the existing loadLogs() path.
No new hash routes. No general hash router.
Out of scope
New log retention, new log format, new log fields.
New observability backend or new diagnostics infrastructure.
New export / download action (none exists today).
New filters or new pagination styles.
Showing raw technical payload beyond what /api/logs already exposes.
Persisting filter or pagination state across full browser reload. Today's behavior is in-memory only via appState; this issue does NOT change that. Tests assert in-memory behavior only.
A general URL hash router.
Detailed behavior
Filters
Identical behavior. Filter apply button (#logs-filter) calls loadLogs() with the current filter state.
Hex search input accepts up to 6 hex chars (existing behavior).
Table
Identical behavior. Same columns, same disposition translation, same classification badge.
Inside-badged rows use the existing signal inside / signal outside classes.
Pagination
Identical behavior. #logs-prev / #logs-next use appState.logsOffset.
Filter and pagination state is in-memory only; full reload resets to defaults. Do not add localStorage / sessionStorage / URL hash query for these — the current behavior is the contract.
Help
Identical behavior. The ? button toggles #logs-help.
Loading / error state
Identical behavior. #logs-error shows server errors.
On Registros step activation, loadLogs() runs and may produce its existing loading / error states.
Empty state
Existing logs_no_rows translation — reuse.
Responsive behavior
Identical — table has horizontal scroll on narrow viewports (existing behavior). This is intentional inner-container scrolling, not page-level horizontal scroll.
Keyboard behavior
Native form order for filters. Table rows not focusable.
Data / API impact
No backend/API changes expected.
Routing / navigation impact
Logs is no longer a top-level destination. #view-logs is removed from index.html.
The Registros Settings step button is visible alongside Operação / Detecção / Notificações / FR24 / Sistema.
Opening Configurações › Registros (via stepper click or via openSettingsSection("registros")) triggers the existing loadLogs() data-loading path.
The Registros step activation uses the shared showSettingsStep(n) mechanism (the one used by all other Settings steps). No duplicate stepper-state logic.
All four filters (kind / provider / hex / inside) work unchanged.
Pagination works unchanged.
Filter and pagination state survive in-session tab/section navigation but are NOT persisted across full browser reload (current behavior).
Help button toggles the existing help copy.
Empty state shows the existing copy.
No new logging behavior is introduced.
#view-logs is no longer present in index.html.
The Logs tab is removed from primary navigation; the Logs entry is removed from #nav-overflow.
No new hash routes. No hash router introduced.
Test plan
VM JS (tests/test_registros_vm.mjs): filter combinations, pagination, empty state, in-memory filter+page preservation across in-session tab/section navigation (NOT across reload); openSettingsSection("registros") activates Settings + Registros step (through showSettingsStep(n)) + triggers loadLogs(); the Registros step button is visible in the stepper.
Integration: filter by hex + inside-only, navigate to another tab and back, assert filter state preserved; full browser reload, assert filter state resets to default (current behavior).
Summary
After Issue #19 has built the Configurações skeleton (which deliberately hides the Registros Settings step button until this issue lands), populate the
<section id="registros">placeholder inside#view-settingswith the existing Logs surface, reveal the Registros step button, and remove the Logs primary-nav surface. Use the tinyopenSettingsSection("registros")helper and the sharedshowSettingsStep(n)step-activation mechanism (introduced by #19). State remains in-memory only.Current state (after #19 has landed)
After Issue #19 lands,
#view-settingscontains the populated Operação / Detecção / Notificações / Sistema sections (each already showing its full form) plus the populated empty<section id="fr24">and<section id="registros">anchor containers. The Registros Settings step button is hidden (and remains hidden until this issue lands). The Settings step activation logic is the shared, externally-callableshowSettingsStep(n)introduced by #19.#view-logs(app/static/index.html:242-275) currently contains:PROVIDER_INFO).#logs-help+#logs-help-text).#logs-error).#logs-summary).#logs-body) with columns: time / kind / provider / region / detail / aircraft / disposition.#logs-prev,#logs-next).GET /api/logsreturns rows withrecorded_at,kind,provider,region_id,detail,aircraft_hex,inside,area_names,classification,disposition, plus paginationtotal/offset/limit.appState.logsFilter/appState.logsOffset(in-memory only). There is no persistence across full browser reload — that behavior is unchanged.loadLogs()orchestrator (app/static/app.js:1264) is the existing logs data-loading path; it is reused byapp/static/app.js:1563/:1599whenever the Logs tab is activated.Prerequisite
Issue #19 (Configurações IA) has created the
<section id="registros">placeholder inside#view-settings, the sharedshowSettingsStep(n), andopenSettingsSection(sectionId). The Registros Settings step button is hidden. This issue is the one that reveals it.UX target
Inside
#view-settings, the Registros section renders the same content the standalone Logs tab exposes today:The structure is identical — only the location moves. Filter and pagination state remain in-memory only (no persistence across reload); this issue MUST NOT add persistence behavior that doesn't exist today.
Atomic reveal (this issue owns this)
Because Issue #19 deliberately hides the Registros step button until this issue lands, this issue MUST atomically:
<section id="registros">inside#view-settingswith the existing logs surface.showSettingsStep(n)mechanism for ARIA / visible state.loadLogs()data-loading path.tab-logs,view-logs, thetab.dataset.view === "logs"branch in the tab activation handler).#nav-overflowoverflow menu.Loading semantics
Merely moving Logs DOM into
<section id="registros">inside#view-settingsdoes NOT cause the existing Settings tab activation to callloadLogs(). This issue wires the Logs loader explicitly:showSettingsStep(n)) optionally invokes a section-specific loader. For Registros, attachingloadLogs()to step activation means opening Configurações › Registros — whether by clicking the Settings stepper, byopenSettingsSection("registros"), or by any other activation path — triggersloadLogs().#operacao,#deteccao,#notificacoes,#fr24,#sistema) do NOT triggerloadLogs(). They use their existing loaders.Existing functionality to reuse
GET /api/logs— unchanged.logRow()renderer (app/static/app.js:1230).loadLogs()orchestration +appState.logsOffsetpagination (in-memory only).logsPopulateProviderSelect()(app/static/app.js:1172).logsRegionLabel()helper.translateDisposition()translation helper.logs_*).aria-describedby).openSettingsSection(sectionId)DOM helper andshowSettingsStep(n)shared step activation mechanism introduced by Issue [UX Redesign] Reorganize Configurações into clear operational sections #19.Scope
#view-logscontainer fromindex.html.#nav-overflowoverflow menu).<section id="registros">placeholder inside#view-settings(created by [UX Redesign] Reorganize Configurações into clear operational sections #19) with the existing logs surface.showSettingsStep(n)mechanism.loadLogs()path.Out of scope
/api/logsalready exposes.appState; this issue does NOT change that. Tests assert in-memory behavior only.Detailed behavior
Filters
#logs-filter) callsloadLogs()with the current filter state.Table
signal inside/signal outsideclasses.Pagination
#logs-prev/#logs-nextuseappState.logsOffset.Help
?button toggles#logs-help.Loading / error state
#logs-errorshows server errors.loadLogs()runs and may produce its existing loading / error states.Empty state
logs_no_rowstranslation — reuse.Responsive behavior
Identical — table has horizontal scroll on narrow viewports (existing behavior). This is intentional inner-container scrolling, not page-level horizontal scroll.
Keyboard behavior
Native form order for filters. Table rows not focusable.
Data / API impact
No backend/API changes expected.
Routing / navigation impact
#view-logsis removed fromindex.html.#nav-overflow. The overflow container may stay until [UX Redesign] Final responsive, accessibility, and consistency pass #22 removes it.openSettingsSection("registros")activates the Settings tab, callsshowSettingsStep(n)to activate the Registros step, and triggersloadLogs().Security / privacy
/api/logsalready returns the same rows.Acceptance criteria
<section id="registros">placeholder created by [UX Redesign] Reorganize Configurações into clear operational sections #19).openSettingsSection("registros")) triggers the existingloadLogs()data-loading path.showSettingsStep(n)mechanism (the one used by all other Settings steps). No duplicate stepper-state logic.#view-logsis no longer present inindex.html.#nav-overflow.Test plan
tests/test_registros_vm.mjs): filter combinations, pagination, empty state, in-memory filter+page preservation across in-session tab/section navigation (NOT across reload);openSettingsSection("registros")activates Settings + Registros step (throughshowSettingsStep(n)) + triggersloadLogs(); the Registros step button is visible in the stepper.captionfor screen-reader.Visual QA
Dependencies
<section id="registros">placeholder +showSettingsStep(n)+openSettingsSectionhelper created here) — required.Rollout / compatibility
Open questions
None.