ac149c2aa4
- 11 templates converted (storage, storage_network, storage_init, storage_attach, sharing, login,
claim, launcher_shared, launcher_share_password, catchall, debug); every key translated.
Six ASCII-only Hungarian JS fragments the extractor missed were found by eye and converted by hand
(", majd a(z)", "FIGYELEM:", "jelenlegi:", "mp", "p", " db").
- login, claim, both guest share pages and the catch-all render through executeTemplateLang (the
household language; no session CSRF, no escrow reminder). renderLogin now takes the request.
- Page titles: TitleKey for storage, network storage, the two drive wizards and sharing.
TestHandlerTitleKeysMatchHungarianTitle pins handler literal == hu.json value for every TitleKey.
- Tests: TestDirectRenderHandlersFollowLanguage (real routes, en + hu),
TestI18nDirectRenderPagesHaveNoAdminChrome (escrow reminder due; none on the guest page).
- Fixture correction: the release C cases had invented page titles; the cases now carry the handlers'
real titles (and the wizard pages their real page name), and those 12 fixtures were RE-CAPTURED from
the unconverted templates at 0555091. The diff to the old fixtures is the <title> line (and the nav
highlight on the two wizard pages) only.
- i18n gate: HU_FORMAL_CEILING 12 -> 16 — four more „ön" forms in the converted copy, unchanged by rule (R-516).
Hungarian: byte-identical (TestI18nParity against fixtures from unconverted templates).
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0159rPz1ZhFKsS53msqPYxtS
65 lines
3.9 KiB
HTML
65 lines
3.9 KiB
HTML
{{define "claim"}}
|
|
<!DOCTYPE html>
|
|
<html lang="{{T "layout.html_lang"}}">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>{{if .IsReset}}{{T "claim.jelszo_visszaallitasa"}}{{else}}{{T "claim.a_szerver_beallitasa"}}{{end}} — Felhom</title>
|
|
<link rel="stylesheet" href="/static/style.css">
|
|
</head>
|
|
<body class="login-body">
|
|
<div class="login-card">
|
|
<img src="/static/felhom-logo.svg" alt="Felhom.eu" class="login-logo">
|
|
<h1 class="login-title">{{if .IsReset}}{{T "claim.jelszo"}} <span class="title-accent">{{T "claim.visszaallitasa"}}</span>{{else}}{{T "claim.a_szerver"}} <span class="title-accent">{{T "claim.beallitasa"}}</span>{{end}}</h1>
|
|
<p class="login-subtitle">{{.CustomerName}}</p>
|
|
|
|
{{if .Flash}}<div class="alert alert-info">{{.Flash}}</div>{{end}}
|
|
{{if .Error}}<div class="alert alert-error">{{.Error}}</div>{{end}}
|
|
|
|
{{/* R-295 — ONE NAME PER SECRET. This page used to call the SAME three-word code „Beállító
|
|
kód" on the first-time branch and „Visszaállító kód" on the reset branch, while the
|
|
TEN-word code that opens the sealed backups is called „Helyreállítási kód" elsewhere in
|
|
this UI. Two of those three names are near-homographs, and the collision cost a real code.
|
|
The ruling: the code that gives a person control of the DASHBOARD is „Beállító kód"
|
|
everywhere — the name this page already showed where it is typed — and where one secret
|
|
serves two situations the NAME stays constant and the SENTENCE changes. „Visszaállító
|
|
kód" is retired. This is naming only: no acceptance logic moved, and a test pins that a
|
|
reset code is still accepted here. */}}
|
|
{{if .HasCode}}
|
|
<p style="font-size:0.85rem;color:var(--text-muted,#8a94a6);margin:0 0 1rem">
|
|
{{if .IsReset}}{{T "claim.add_meg_az_e_mailben"}}{{else}}{{T "claim.add_meg_az_e_mailben_2"}}{{end}}
|
|
</p>
|
|
<form method="POST" action="/claim">
|
|
<input type="hidden" name="_csrf" value="{{.ClaimCSRF}}">
|
|
<div class="form-group">
|
|
<label for="code">{{T "claim.beallito_kod"}}</label>
|
|
<input type="text" id="code" name="code" required autofocus autocomplete="off"
|
|
placeholder="{{T "claim.szo_szo_szo"}}" class="form-control">
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="new_password">{{T "claim.uj_jelszo_min_karakter"}}</label>
|
|
<input type="password" id="new_password" name="new_password" required minlength="{{.MinPassword}}"
|
|
placeholder="{{T "claim.legalabb_karakter"}}" class="form-control">
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="confirm_password">{{T "claim.uj_jelszo_megerositese"}}</label>
|
|
<input type="password" id="confirm_password" name="confirm_password" required minlength="{{.MinPassword}}"
|
|
placeholder="{{T "claim.jelszo_megegyszer"}}" class="form-control">
|
|
</div>
|
|
<button type="submit" class="btn btn-primary btn-full">{{if .IsReset}}{{T "claim.jelszo_beallitasa"}}{{else}}{{T "claim.beallitas_es_belepes"}}{{end}}</button>
|
|
</form>
|
|
{{else}}
|
|
<div class="alert alert-info">{{T "claim.jelenleg_nincs_aktiv_kod_ehhez"}}</div>
|
|
{{end}}
|
|
|
|
<form method="POST" action="/claim/request-new-code" style="margin-top:1rem">
|
|
<input type="hidden" name="_csrf" value="{{.ClaimCSRF}}">
|
|
<button type="submit" class="btn btn-outline btn-full">{{if .IsReset}}{{T "claim.uj_beallito_kod_kerese"}}{{else}}{{T "claim.nem_kaptad_meg_a_kodot"}}{{end}}</button>
|
|
</form>
|
|
|
|
<p class="login-footer">{{T "claim.felhom_otthoni_szerver_kezeles_felhom"}}</p>
|
|
</div>
|
|
</body>
|
|
</html>
|
|
{{end}}
|