Repository navigation
Conversation
Three things verified against a v15.4 instance instead of assumed: the paths go relative with no leading slash; user/login and user/session/get return the session flat while the rest wrap it in `response`, so the client unwraps nothing; and the second-factor literal is `2fa-required` (DnsWebService.cs:2530), not the one I had written in the plan.
A literal replica of auth.js:24-68: the fragment wins, the URL is always cleaned, the cookie is deleted as it is read and only then does it fall back to localStorage. The test setup installs an in-memory Storage: Node 26 ships a native localStorage that is disabled without --localstorage-file, and jsdom does not expose it either in this combination of versions. It is test environment, it does not travel to the bundle.
The amber theme values come from upstream amber-mode.css: it is amber ON BLACK, text included (#ffb000 over #1a120b), not a dark theme with an amber accent. Turning it into the latter would leave the dark and amber themes nearly identical and the user would lose a theme in practice.
A replica of auth.js:207-297. The alert texts are upstream literals and they are contract. It includes the auto-submit on the sixth digit, the 30 s expiry and the admin/admin case with no 2FA that forces a password change. Tests with fake clocks need shouldAdvanceTime and delay:null, or userEvent blocks; and findBy* is no use because it waits on timers that do not advance.
React 19 passes ref as an ordinary prop but it has to be declared in the type, or tsc rejects the build. The tests did not catch it because vitest does no type checking: only `npm run build` sees it.
Three behaviours that are only visible by reading main.js and that are covered by tests: each section hides if its canView is false, it lands on the first visible one when Dashboard is not, and an SSO user has "Change Password" and "Configure 2FA" hidden. The side-by-side comparison against the reference instance uncovered two divergences in the alerts: the "×" to dismiss them was missing —which is a control, not decoration— and so was the space between title and text. Fixed and compared again: the three messages match word for word.
Without a base style the console inherited the browser serif. The fonts are the system ones out of necessity: the server CSP declares no font-src, so there can be neither a CDN nor data: URIs.
My Profile, Change Password, Configure 2FA, Create API Token and Change Theme, on Radix Dialog. The twelve alert messages are upstream literals and they are covered by tests, as are the validation order of the password change and the fact that an SSO user is not sent `displayName` because the field is disabled. The 2FA QR is drawn as a data: URI, which the server CSP does allow for images (`img-src 'self' data:`) though not for fonts.
session/delete arrives with the active sessions table of My Profile, which I had left out: it was a real loss of functionality. It includes the confirm with the literal text of upstream. checkForUpdate honours `disableUpdateNotification`: when it is silenced the endpoint is NOT EVEN called, only an explicit force skips it. createSingleUseToken comes with the `openDownload` helper the six downloads of phases 4, 5, 6 and 8 will use. One defect the test uncovered: when reloading the profile after deleting a session, the effect cleared the success alert and the message flashed and vanished.
Adrián's decision. Out go the light and amber tokens, the Change Theme modal and its entry in the user menu: the modals drop from 40 to 39. It is the only deliberate exception to "design only, zero functionality" in the whole project — the only thing that removes something instead of just changing how it looks. It is noted in tokens.css itself in case it ever comes back.
The `status` endpoint governs two login behaviours I had skipped, and they only
came out while inventorying phase 3:
· ssoEnabled decides whether the "Sign in with SSO" button shows. I drew it
always. Checked against upstream: with ssoEnabled=false neither console
shows it.
· hasDefaultCredentials makes a fresh install log ITSELF in with admin/admin,
and makes a failure of that attempt leave no alert hanging.
Along the way, two phase 2 tests were fragile: they assumed the first call to
apiRequest was the login. Now they find the call instead of its position.
The Dashboard with its 11 metrics, the 6 counters, the 3 Top lists and all FOUR
charts. Chart.js and not SVG for behavioural reasons: the data arrives in its
format and clicking a series in the legend hides it.
Two defects fixed on seeing it run:
· The shell still had tabs on top. It was built in phase 2, before the side
panel was decided, and I never applied it. Now it is a side panel with
nested sub-items, which only show with their section active.
· A chart with no value other than zero left an empty 190 px canvas. Now it
says there is no data.
Verified against the real binary with generated DNS traffic: 131 queries, 66
authoritative and 65 blocked, with no console errors.
The 5 endpoints of the phase (dashboard ×3, dnsClient, status) implemented and
struck off the inventory. 109 tests green.
A contract detail that only came out testing it against the real server: the
"Server" field shows labels like "This Server {this-server}" and what gets sent
is ONLY what sits between the braces. On top of that, with `recursive-resolver`
or `system-dns` the protocol is forced to UDP. And the empty-server alert is
checked AFTER extracting, so "{}" counts as empty.
Verified on the real binary: the query returns 10.0.1.50. The first attempt came
back empty and it was NOT a bug in the code: `.test` is not signed and DNSSEC
validation rejected the chain, which is the correct behaviour.
It collects the governing rule, where the reference is (upstream/master, because the old www is no longer in the tree), the two disposable instances for checking response shapes instead of assuming them, and the three assumptions that have already turned out false.
The client now supports multipart uploads (FormData without setting Content-Type: the browser sets the boundary). The console's five uploads need it: install and update app, import zone, import records and restore settings. A correction to something I claimed in the spec myself: **there are two different paginations**. `zones/list` paginates on the server with pageNumber/zonesPerPage —and its paging fields only appear if you send pageNumber— but `zones/records/get` does NOT paginate: upstream asks for it with listZone=true and no page parameters and paginates on the client. Verified against v15.4.
Work from the phase 7 agent, with its loose ends closed: the client now accepts a pre-built FormData, so installApp and updateApp stop being blocked and their two pending tests become real ones. Added the Textarea primitive it asked for, and wired Apps into the shell. **A correction to my own design**: the 07-apps page promised an Enabled/Disabled badge and an "Enable" button that DO NOT EXIST. The apps API has nine endpoints and none of them enables or disables anything; an installed app is always active. The agent refused to implement it, which was the right call. The mockup is corrected and annotated. Collected in CONVENCIONES.md the reusable findings: optional fields that look required, config that comes back null, POST-only uploads, the multipart boundary, and the two different paginations.
Work from the phase 5 agent, wired into the shell. 335 tests green.
**Two more corrections to my design**, verified in the server code:
· The Cache table carried a "Delete" per row. It does not exist:
`cache/delete` deletes the WHOLE NODE and there is no endpoint for a single
record. The agent refused to implement it, which was the right call.
· The "184,302 in lists" badge on Blocked asked for a datum that screen does
not have: `blocked/list` only reads the manually blocked zones, and the
downloaded lists are counted in `dashboard/stats/get`.
Findings collected in CONVENCIONES.md, and the most dangerous is this one: **the
server can return a domain different from the one asked for**, because it walks
down the chain on its own while the node has no records and has a single child.
`response.domain` has to be drawn, never the one asked for.
Work from the phase 6 agent, wired into the shell with the three different permissions that govern its action bar. 338 tests green. A figure corrected, and the mistake was mine: the settings family has 7 endpoints, not 6. The agent counted 6 because the grep I gave it in the brief only looked at main.js and common.js, and `settings/getTsigKeyNames` is used from zone.js. Added, with a note that Zones consumes it even though it belongs to this family. Added the Select and Textarea primitives, which two agents asked for. The most reusable finding: **upstream's textarea `\r\n` never reaches the server** because the browser normalises it when reading from the DOM. In React there is no intermediate DOM, so copying it literally sends `%0D` to the server. It bites any screen with lists in a textarea. Recorded in CONVENCIONES.md the three deliberate deviations so far, so they do not pile up in silence.
The 34 endpoints of the `zones` family, split across three modules because they
are three different contracts: zone management (zones.ts), records
(registros.ts) and DNSSEC (dnssec.ts).
What has been pulled into modules of its own and tested on its own is whatever
drifts in silence if left inside a component:
· registro-form.ts the 23 record types, their validation order and their
literal alert texts. Add and edit together because they
are the SAME form: splitting them doubled the places to
get it wrong.
· opciones.ts the visibility matrix of the five zone-options tabs,
which depends on the type AND on whether the zone belongs
to a catalog.
· filtro.ts the glob of the records table, including the rule that
looks like a bug and is not: a filter starting with `*`
looks for the literal wildcard record.
· paginacion.ts the ten-page window that slides backwards on reaching the
end.
· registro-vista.ts what gets drawn in the Data cell of each type.
Two different paginations and both written by hand: `zones/list` paginates on
the server and `zones/records/get` does not paginate at all. That is the reason
TanStack Table was ruled out.
Verified against a real instance: adding an A record from the modal produces a
record byte for byte identical to the one the upstream console produces from the
same action.
Along the way, three corrections outside Zones that were needed here:
`apps/list` and `settings/getTsigKeyNames` were not sending `node` although
upstream does; and the `ts` cache-buster on downloads becomes optional, because
upstream only adds it on two of the six.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01Tj92NfpUyhxHwxrPoscBRf
The 16 endpoints of the two families: 10 of `dhcp` (leases and scopes) and 6 of
`logs` (file viewer and query logs), with their four screens.
Two contracts that look like nothing else in the console:
· `logs/download` does NOT return JSON. It gives `text/plain` with the file
when it goes well and `application/json` when it fails, so it cannot go
through `apiRequest`: that would do `res.json()` and turn every log into a
network failure.
· `dhcp/scopes/set` is a PARTIAL update: each field is applied only if it
comes. A body with only `name` and `newName` renames without touching
anything else, and a scope created that way is born enabled.
And an exception to the rule that deleting the non-existent answers `ok`:
`leases/remove` on a lease that does not exist answers an error.
"Delete All Stats" lives on the Logs screen but asks for the Dashboard
permission. It is not an oversight: that is how it is in WebServiceLogsApi.cs.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01Tj92NfpUyhxHwxrPoscBRf
The 30 endpoints of the `admin` family and its six sub-tabs: sessions, users,
groups, permissions, SSO and cluster.
The 19 that are not cluster are verified against a real instance. The 11 cluster
ones are NOT: a single instance never forms a cluster, so they are written
against cluster.js and WebServiceClusterApi.cs and covered by tests over
simulated responses built from the C#. No claim is made that they work against a
real cluster.
Three contract traps that would be expensive to discover in production:
· `admin/sso/set` returns LESS than its `get`: it does not bring
`localGroups`. Reloading the form with the save response would empty the
group map.
· The SSO secret comes back masked (`************`) and has to be sent back
that way: the server ignores that exact value. Clearing it "because it looks
like filler" would delete the real secret.
· "Force Remove Node" does not change a parameter: it changes the ENDPOINT,
between `primary/deleteSecondary` and `primary/removeSecondary`.
No permission props, and that is deliberate: upstream hides and disables nothing
inside Administration. The only check is `Administration.canView` to show the
section; from there it shows everything and lets the server reject. Adding
client-side gating would be adding behaviour.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01Tj92NfpUyhxHwxrPoscBRf
The four sections go into the Shell and with that all 12 are implemented: the
129 endpoints of the inventory are covered.
Three things that had to be fixed and belonged to none of the three phases:
· **The interface had nine Spanish texts**, from phases 3, 5 and 7: empty and
loading states. The console is `lang="en"` and has no translation
infrastructure, so any visible string in Spanish is a blocker for the pull
request. Translated, with their tests. The rule is noted in CONVENCIONES.md:
the interface goes in English and Spanish is only for the code comments.
· **Three copies of the same date helper**, one per phase, each replicating
`moment().format()` and `fromNow()`. Unified into `src/lib/fechas.ts`; the
one that survived is the only one that replicates moment's thresholds
instead of approximating them, and along the way it pads the year to four
digits: without that, `0001-01-01` —the .NET `default(DateTime)` that turns
up on every unused record— was drawn as `1-01-01`.
· **The comment on `openDownload` said `ts` goes on three downloads.** It goes
on two: the settings backup and a log download.
CONVENCIONES.md grows by a score of upstream behaviours checked against the real
server. The ones that hurt most: `zones/list` omits `dnssecStatus` on Catalog
and Forwarder zones; user permissions bring `username` and group ones `name`;
`records/delete` has no branch for CNAME, DNAME, SOA or APP; and disabling a
record reads the expiry TTL from the MODAL, not from the row, which is an
upstream bug that gets replicated.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01Tj92NfpUyhxHwxrPoscBRf
They compare upstream's text against the whole source, comments included. While those were in Spanish it made no difference, because they could not match an English sentence; on translating them to English it would have — a comment quoting the help text it explains would make a REALLY lost help text match, and the check would go green for the opposite reason to the one it exists for. They are stripped before comparing. All three stay green with the stripping in place, so none was matching only inside a comment. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
First batch of translating the repository so it can be proposed upstream: `dev/` is what a reviewer looks at to trust the parity figures, so it goes first. Comments and identifiers. Verified by running them, not just by compiling: `css-muertas` still gives 0 of 368, `css-repetido` 10 groups, and the three parities are still green (28 destinations, 112 help texts, 94 examples). The two that run in the browser pass `node --check`. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
It closes `dev/`: the three READMEs, the six tools, the five scripts and the compose file. Comments, identifiers and output texts. Verified by running all of it, not just by compiling: the three control parities are still green (28/112/94), `check-paridad-acciones.sh` still gives the fourteen actions identical, `check-paridad.sh /robots.txt` is still IDENTICAL, the inventory still counts 42 dialogs across 31 files, and the four that run in the browser pass `node --check`. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
57 files of `src/ui/`, 68,000 characters. Comments only: verified mechanically that, with them stripped, the 57 are byte for byte identical to how they were —the check was first proved red by touching a line of code on purpose. The identifiers and the test names go in a separate pass, because they are exports the whole codebase uses and renaming them file by file would break the rest halfway through. 821 tests green, typecheck clean, builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
…o English `theme/tokens.css` and `theme/base.css` —the surface ramp, the type scale, the layers, the reason for each shadow— plus `app/Shell.tsx`, the routing, the session boot and the static routes. And the safety check was corrected, because it was unreliable for precisely what is being done: it protected the strings BEFORE stripping the comments, so as soon as an English comment carried an apostrophe —"console's"— it took that for the start of a string and swallowed half the file. Now it strips first. The 57 already-committed files of `src/ui/` re-verified with the corrected checker: 0 with code touched. The only thing that showed up was the `www/assets/` bundle, which changes name on every build because of its hash. 821 tests green, typecheck clean, builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The 22 files of `src/api`: the 15 endpoint modules and their 10 test files. It is the densest area of the project in facts that cannot be deduced by reading anything —neither upstream's JavaScript nor the server's C#— but only by checking against a v15.4 instance: which keys the server omits instead of sending them as null, which endpoints ask for `Delete` where you would expect `Modify`, on which two of the six downloads upstream adds the cache-buster and on which it does not. With them go the reasons for the four calls that stopped returning `null` or `[]` on a failure: an empty list and a fallen call draw the same, and that is how the Dashboard said "No queries for this period." when what had happened was that the request never arrived. Checked with the verifier: 22 files, comments only. 821 tests green and typecheck clean. The Spanish names of identifiers and test descriptions remain; that goes in a separate pass. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
`lib/` (upstream's page window, the `|` serialisation of the editable tables, moment's thresholds and the failure alert that was written thirty-six times), `app/Shell.module.css` with the measurement that brought down the tabs on top, `main.tsx` with the favicon that was anchored late, the test harness and the session tests —including why the side panel stopped declaring itself a `tablist`. With this `src/otros` is complete: only the screens are left. 14 files, comments only according to the verifier. 821 tests green, typecheck clean, builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The twelve densest files of `src/screens`: the zone list, the DHCP scope form, Query Logs, Cluster, the Settings model, the record form, the zone options, the Dashboard, the lists, SSO and the leases. It is where most of what was learned replicating upstream lives: why the two "the app is missing" alerts do not say the same thing, why an empty list travels as the string "false" except in two places, why "Quick Add" compares by substring, and why the Dashboard stopped drawing eleven zeros when what was happening was that the call had never arrived. 12 files, comments only according to the verifier. 821 tests green and typecheck clean. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
Zone records, permissions, Settings, Apps, Users, About, Administration, My Profile, User Details, Scopes, Sessions, the record view, the Dashboard CSS and the add-zone form. Here are the three corrections that took the most justifying: why About got back the eight author links this fork had deleted —donations, support and documentation— why the last-login column stopped showing "0000-12-31 23:45:16 from 0.0.0.0" to someone who has never logged in, and why the browser `confirm()` had to disappear from uninstalling an app too. 14 files, comments only according to the verifier. 821 tests green. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
Login, DNS Client, View Logs, the blocking menu, the Dashboard custom range, the zone view, DHCP, the DNSSEC properties, the records filter, the three zone modals, Zones, StoreApps, the Administration CSS and the test with the real response captured from the server. In there go two rules that took work to understand: why the records filter rewrites `.*\.` to a literal asterisk —so the wildcard record can be found, which in DNS really is called that— and why the custom range reads the dates in local time below seven days and in UTC above. 15 files, comments only according to the verifier. 821 tests green. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The forms and the medium-sized pieces: the scope form, Top Stats, Logs, zone options and permissions, the domain tree, the records table, sign zone, the shared Administration parts, the four screen CSS files and the tests of Dashboard, Cluster, lists, About and the login OTP. 18,000 characters remain across some 65 small files. 24 files, comments only according to the verifier. 821 tests green and typecheck clean. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The 67 files that were missing, nearly all of one or two lines: the nine Settings panels, the small Apps and Zones modals, the screen CSS files and the remaining tests. With this the translation of the COMMENTS is done: 286,000 characters across 268 files, from `dev/` to `src/screens`. The final sweep finds none. What is still in Spanish are the identifiers —171 symbol names, 30 CSS classes and the test descriptions— and that goes in a separate pass, because there code really is touched and the "comments only" verifier stops working as a net. 67 files, comments only. 821 tests green, typecheck clean, builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The identifier pass begins, and the test descriptions go first because they are
the only ones where the net is exact: the count has to keep saying 821.
A flaw in the method turned up that is worth pinning down: the English
apostrophe ("the server's failure") inside a single-quoted string breaks the
parse, and it took five files down on the first pass. The rule now is no
apostrophes in the descriptions —they get reworded ("the failure from the
server")— and the script checks it before writing.
821 tests green.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The 59 test files. Not one description is left in Spanish: the sweep that counts them —comparing Spanish markers against English markers in each string— comes out at zero. The count still says 821 across the 59 suites, which is the exact net for this kind of change: had a description been split, the whole file would stop parsing and the number would drop. One more stumble of the method, of the same kind as the apostrophe one: "\"blank\" touches nothing" is a prefix of "\"blank\" touches nothing and \"none\" empties the table", so the short substitution ate the long one. It is fixed by ordering from longest to shortest. The Spanish identifiers and the CSS classes remain. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The mechanical pass: variable, property, type and CSS class names. 5,900
occurrences across 194 files.
The rename cannot be done with a regular expression, and it took three attempts
to learn that. All three failed for the same reason —a quote where none was
expected— and each in a different way:
1st the substitution got into the `import` paths and broke them;
2nd a template with `${...}` unpaired the quotes and left half a screen
untouched (`<Tabla>` opened and `</Table>` closed);
3rd the apostrophe of the JSX text —"DNS Server's config folder"— opened a
false string that swallowed the rest of the file.
The version that survived is a lexical scanner with states, which understands
the nesting of `${...}` inside templates and requires a string to close on its
own line. It carries six self-check cases with exactly those stumbles.
The 48 collisions that remained are real and are fixed one by one: a local
shadowing its own source in Login and in Sessions, the `Row` of `ui/Form`
against the SSO one, the `clave` prop against React's `key`, and `zona` (the
name) against `zone` (the object) on the three Zones screens. `Registro` cannot
be called `Record` —it clashes with TypeScript's `Record<K,V>`— so it is
`ResourceRecord`, which is also the DNS term.
0 typecheck errors, 0 lint errors, 821 tests green and it builds.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
139 more: the verbs (load, save, delete, open, close, mount, draw, choose, serialise…), `aviso` and its family, `tipo`, `orden`, `modo`, `fallo`, and the component names that were left —Segmentado, TablaEditable, MenuBloqueo, Icono, Avisador. With them, the icon vocabulary and the literal unions that travelled inside strings and that the renamer cannot see: the icon names, the state of About's update check and the dialog sizes. The collisions in this batch are more interesting than the first one's, because nearly all are a local shadowing the endpoint it calls: `borrarLog` and `logs/delete` both end up wanting to be called `deleteLog`. They are resolved by giving the local the interface's verb (`removeLogFile`) and leaving the endpoint's name to the endpoint. Same with `open()` against Select's `open` state, and with the two editable tables —the raw piece and the form kit's wrapper— which were both called `TablaEditable`. 0 typecheck errors, 0 lint errors, 821 tests green and it builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
400 more: `onCerrar`, `alternar`, `porBorrar`, `zonaDeRegistros`, `celdasDeRegistro`, `construirCuerpo`, the thirty-odd screen components (ListaZonas, RegistrosZona, PermisosZona, FirmarZona…), the uppercase constants and the row and cell props. The last remnant of the method was also solved: the strings that are NAMES —the `vi.spyOn(api, 'listarNodo')` of the tests and the literal union values— are invisible to the renamer, because by design it does not touch the inside of a string. They go in a separate, explicit pass. 0 typecheck, 0 lint, 821 tests green and it builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
`screens/listas` becomes `screens/lists`, `screens/zones/modales` becomes `screens/zones/modals`, and with them the files: ListaZonas → ZoneList, RegistrosZona → ZoneRecords, PropiedadesDnssec → DnssecProperties, ui/Ajustes → ui/PanelForm, lib/tabla-serie → lib/table-serialise… They were moved with `git mv` to preserve the history. Rewriting the `import` is the symmetric problem to renaming identifiers —here you have to look ONLY inside the strings— and that is why they are two tools and not one. A stumble specific to this step: a file that changes FOLDER has to resolve its own relative `import` against its OLD folder, which is where they were written. Resolving against the new one produced paths that do not exist (`../listas/Listas.module.css` from `screens/lists/`), and along the way a double `.css.css` extension. 0 typecheck, 0 lint, 821 tests green and it builds. Not one file name is left in Spanish. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The fifteen files of `dev/` take English names —check-parity, css-dead, measure-screen, dialog-census, uniformity…— along with their cross-references in the three READMEs and in each script's usage header. With them, the identifiers that were left inside (`contraste`, `tactil`, `sinNombre`, `problemas`) and the category labels they print. And `vite.config.ts`, which is the piece that explains why there are 32 folders each with its `index.html`: `rutasEstaticas` → `staticRoutes`, `RUTAS_ESTATICAS` → `STATIC_ROUTES`, and its header comment into English. Checked: the five `.sh` pass `bash -n`, the `.js` pass `node --check`, 0 typecheck, 821 tests green and it builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
`CONVENCIONES.md` becomes `CONVENTIONS.md`, translated in full: the sixty-odd observations about upstream's behaviour discovered by checking against a real instance, which is the most valuable document this project produces and the one an upstream reviewer will want to read. The chance was taken to correct three things the document said that are no longer true: that Spanish is fine for the comments (it is not), that the API must always return `null` on a failure (only where empty and failure cannot be confused), and that the self-dismissal of the success alert was not replicated (it is). And two rules that were learned the hard way were added: the spacing and type tokens, and the ban on apostrophes in test descriptions. With them, the webapp README —which now explains the 32 route folders— and the fonts one, which is the same file in `public/fonts/` and in `www/fonts/`. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
166 more: `pestana`, `ventana`, `respuesta`, `filtros`, `camino`, `coletilla`, `interletrado`, `hamburguesa`, `cajon`, `velo`… and the ones that only appeared two or three times. Finding them meant changing method: searching by Spanish stems no longer worked —what was left were words with no `ción`, no `dad` and no accent. What works is using THE REPOSITORY'S OWN ENGLISH PROSE as a dictionary: every word that appears in the comments (which are already translated) is collected, and every identifier whose words appear not once there is flagged. That leaves 157 candidates instead of 4,500, and of those nearly all are real. 0 typecheck, 0 lint, 821 tests green and it builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
The last 87 identifiers and the error messages of the test helpers, the header of `vite.config.ts` —which had been left half done because renaming `ruta` to `route` broke the texts it was going to replace— and the angle quotes of `dev/dialog-census.js`, which already surrounded English text. The accent sweep over `src/`, `dev/` and the documents comes out empty except for three things that must stay: Adrián's name in the product decisions he signed off, `mañana.test` as an internationalised test domain —which is exactly what that test checks— and `Mía` as an app name in a fixture. With this the whole translation is done: 286,000 characters of comment, 852 test descriptions, some 800 identifiers, 85 files, two folders and four documents. 0 typecheck, 0 lint, 821 tests green and it builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
…t name
A regression I introduced myself in the translation and that neither the
typecheck nor the 821 tests catch: on renaming `ruta` to `route` in
`vite.config.ts`, the `<meta>` each `index.html` carries came to be called
`route`, but `app/base.ts` still looks for it inside a STRING
—`meta[name="ruta"]`— and the renamer, by design, does not go into strings. The
tests cannot see it either because they write the meta under the same old name
they read it by.
The effect is exactly the one that file explains has to be avoided: from
`/dhcp/scopes/`, `api/status` resolved against the current path and asked for
`/dhcp/scopes/api/status`. A 404 on every deep route —that is, on 31 of the 32.
It was uncovered by opening the console in the browser; the three local gates
were green.
With it, three classes the DHCP form asked for that did not exist in its module:
`styles.ctlLine`, `styles.suffix` and `styles.area` were `undefined`, and that
is why the "Days / Hours / Minutes" suffixes of the lease time came out at 13 px
in the main ink colour instead of at 11.5 and muted. They are not from this
session —they date from when `ui/Panel` absorbed the markup— and they are the
same three Administration and Zones do declare. Measured before and after in the
browser.
And the other way round: the five `className={styles.panel}` of About and View
Logs were dead code —that class does not exist in their modules and the gap
comes from the parent's `gap`— so they are removed.
Verified in the browser: the 32 routes serve their `index.html` with the right
`<meta>`, and Zones, Settings, Dashboard, About and the DHCP form mount without
a single console error. 596 uses of `styles.X` checked against their module:
none broken.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
…the one the app reads The test that was missing, written after its absence let a 404 through on 31 of the 32 routes. The cases that already existed could not see it: they mount the `<meta>` under the same name they then read it by, so they always agree with themselves. The name is written by `vite.config.ts` and read by `app/base.ts`, and there was not a single test over that configuration file. This case reads both files with Vite's `?raw` —which adds no dependency, and a new dependency would show up in the diff of the PR— and compares the two names. Verified that it fails in both directions: changing only the one that writes and changing only the one that reads. 822 tests green, 0 typecheck, 0 lint, it builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
I wrote them yesterday, in the two previous commits: the explanation of the three classes missing from `Dhcp.module.css` and the one for why the `<meta>` joint test was needed. Habit is heavy. 822 tests green, 0 typecheck, 0 lint, it builds. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_012UJsDPJVbNo74gXz8Y81Wu
|
Thanks for the PR. However, it is really not possible to accept it for multiple reasons. Firstly, I am not a frontend developer and thus I will have to first learn the frontend tech stack you used which is not feasible due to lack of time. Then the DNS Server project is still work in progress which means there are several things that will change in each new update so without understanding the frontend stack, it would not be possible to make new changes. The PR is also huge and it is not really feasible to go through each part of the code and test it to see if all the GUI options are functional. I would suggest that you package your work as an alternative GUI for the DNS server which users can install to replace the default GUI. Have some kind of installer script to make it easy to replace it. You will need to keep maintaining the project though for several years as this project keeps on updating, adding new features/options each release. Closing this PR. |
|
Thanks for the quick and clear reasoning. I'll do what you suggested and package the console as an alternative GUI that users can install over the default one. One small request before I start — and it's fine if the answer is no. The web root is currently fixed to the install directory: // DnsServerCore/DnsWebService.cs
builder.Environment.WebRootFileProvider = new PhysicalFileProvider(Path.Combine(_appFolder, "www"))so on a standard install, replacing the UI means overwriting Would you accept a small PR — backend C# only, a few lines in If you'd rather keep the path fixed, no problem at all — I'll go the installer route as you suggested. Thanks again for the project. |
|
Thanks for understanding.
The issue with this would be that in case of lot of updates, there are major changes that wont be available with the custom GUI. So, if a user has to upgrade, they have to also make sure that the custom GUI is also available to support it. Also in most cases, the API is backwards compatible but it may happen that a major release breaks compatibility due to unavoidable reasons and the existing custom GUI may break. I would say that the user is made aware of this and they should install newer update for the custom GUI along with the DNS server update. This would mean that they have to run your GUI installer anyway for the update. If you still think that having a environment variable for this would be useful then you can have a PR for it and I will get it merged. |
This replaces the Bootstrap 3 / jQuery admin console with one built on Vite + React 19 +
TypeScript. It is a redesign, not a rewrite of the product: same API calls, same behaviour, same
user-visible strings.
What it looks like
Captured against a stock v15.4 container. The images live on an orphan branch of my fork, so
they are not part of this diff.
What it does not change
DnsServerCore.csprojnow picks upwww\**\*with a wildcard instead of enumerating every file by hand. The bundle filenames carry acontent hash, so they cannot be listed one by one. That is the whole .NET diff.
dohwww/is untouched. It is a second static site served by the DNS server itself forDoH client configuration, on the same old stack. Left out on purpose, said here so it does not
look like an oversight.
Parity is enforced by scripts, not by eye
dev/carries three checks that run against a stock upstream container and compare it to thisbranch. All three are green on this commit:
hrefupstream has.placeholder. This one was added after finding 34 had been lost,including
example.com or 192.168.0.0/24 or 2001:db8::/64on the Add Zone field, which is how auser discovers that field accepts a reverse zone in CIDR form.
There is also a fourth check that matters more than the three above:
dev/check-parity-actions.shruns the same fourteen actions on both consoles and compares thestate the server is left in — a split TXT, an SVCB with flattened
svcParams, disabling a record(which upstream does as a
records/updateresending it whole), deleting a CNAME (which sends noidentity parameter at all). All fourteen leave the server identical.
There are also 822 unit tests (
npm test), a dead-CSS detector, a duplicate-rule detector, and across-screen uniformity sweep. All of these live under
dev/and pull in no dependencies.The code carries a lot of comments, and they are the part worth reading: each one records the
upstream line it replicates, the measurement that motivated a change, or the trap it avoids. Roughly
sixty of those are behaviours of the server that are not deducible from the JavaScript or the C# and
were checked against a live v15.4 instance — they are collected in
DnsServerCore/webapp/CONVENTIONS.md,which is the first thing to read.
Build
www/is committed, so the .NET build needs no Node toolchain — installing the binary or buildingthe solution gets a console that is already built, exactly as before.
Runtime dependencies are four:
react,react-dom,chart.jsand@radix-ui/react-dialog.The served bundle is 868 KB of JS and 52 KB of CSS. 32 routes are pre-rendered so deep links,
bookmarks and reloads work without any server-side rewrite;
X-Forwarded-Prefixis honoured becauseVite is configured with
base: './'.The credit line is optional — say the word and it goes
The footer carries one line this branch adds:
Theme by agarmoli, linking to my GitHub profile. Itsits on its own line below your five links, which are unchanged.
It is self-contained — a constant in
app/footer.ts, the block that renders it inui/FooterLinks.tsxand one CSS class — so if you would rather the console did not carry it, say soand I will remove it in a single commit and everything else applies unchanged. I would rather ask
than assume.
What is not verified
Stated plainly rather than left for review to discover:
against
cluster.jsand the C# and covered by tests with simulated responses, but never exercisedagainst a real cluster.
read and cleared, the token reaches
localStorage,#error=renders as an alert and is strippedfrom the URL), but the round trip against a real OIDC provider is not.