From e70e9f5c436e75e4162447d52851d67590444f70 Mon Sep 17 00:00:00 2001 From: Peppa Date: Tue, 17 Nov 2026 23:14:33 +0500 Subject: [PATCH] =?UTF-8?q?BRM-111:=20=D1=80=D0=B0=D1=81=D1=88=D0=B8=D1=84?= =?UTF-8?q?=D1=80=D0=BE=D0=B2=D0=BA=D0=B0=20=D0=B1=D1=83=D0=BA=D0=B2=20D/U?= =?UTF-8?q?/W/H/V=20=D0=B2=20=C2=AB=D0=9F=D0=B0=D0=BC=D1=8F=D1=82=D0=B8=20?= =?UTF-8?q?=D0=B1=D1=80=D0=B5=D0=BD=D0=B4=D0=B0=C2=BB,=20=D0=BF=D0=BE?= =?UTF-8?q?=D0=BC=D0=B5=D1=82=D0=BA=D0=B0=20=C2=AB=D0=BF=D1=80=D0=BE=D0=B2?= =?UTF-8?q?=D0=B5=D1=80=D0=B8=D1=82=D1=8C=20=D0=B0=D0=B2=D1=82=D0=BE=D1=80?= =?UTF-8?q?=D1=81=D1=82=D0=B2=D0=BE=C2=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 5.5 --- locales/en.json | 9 ++++++++- locales/kk.json | 9 ++++++++- locales/ru.json | 9 ++++++++- public/facts.html | 5 +++-- test/facts-legend.test.js | 15 +++++++++++++++ 5 files changed, 42 insertions(+), 5 deletions(-) create mode 100644 test/facts-legend.test.js diff --git a/locales/en.json b/locales/en.json index f043d48..67cd0ea 100644 --- a/locales/en.json +++ b/locales/en.json @@ -818,5 +818,12 @@ "home.check.channels.post": ": the table should show for each channel the audience, goal, Tatiana's access, whether automatic publishing is possible, limits, fallback and queue. What we don't know yet is marked \"to be clarified\" or \"not confirmed\".", "letter.steps": "Steps: 1. Save. 2. Approve. 3. Open in mail and send it yourself. 4. Mark as sent.", "ui.sum.noValueHint": "— click the row and enter a value", - "ui.sum.legend": "“Not entered” means there is no value yet and you need to add it; “sample” means the value is made up for an example and is not your data." + "ui.sum.legend": "“Not entered” means there is no value yet and you need to add it; “sample” means the value is made up for an example and is not your data.", + "ui.facts.legend": "What the letters next to entries mean", + "ui.facts.legend.D": "D — backed by a document", + "ui.facts.legend.U": "U — in Tatiana's own words", + "ui.facts.legend.W": "W — mentioned in the working plan", + "ui.facts.legend.H": "H — a guess, not checked", + "ui.facts.legend.V": "V — needs proof", + "ui.facts.authorship": "check authorship" } diff --git a/locales/kk.json b/locales/kk.json index 2a287f9..42effe0 100644 --- a/locales/kk.json +++ b/locales/kk.json @@ -818,5 +818,12 @@ "home.check.channels.post": ": кестеде әр арна бойынша аудитория, мақсат, Татьянаның қолжетімділігі, автоматты жариялау мүмкіндігі, шектеулер, қосалқы жол және кезек көрініп тұруы керек. Әзірге белгісіз нәрселер «нақтылау керек» немесе «расталмаған» деп белгіленген.", "letter.steps": "Реті: 1. Сақтау. 2. Мақұлдау. 3. Поштада ашып, өзіңіз жіберу. 4. Жіберілді деп белгілеу.", "ui.sum.noValueHint": "— жолды басып, мәнді жазыңыз", - "ui.sum.legend": "«Енгізілмеген» — мән әлі жоқ, оны жазу керек; «үлгі» — мән мысал үшін ойдан алынған, бұл сіздің деректеріңіз емес." + "ui.sum.legend": "«Енгізілмеген» — мән әлі жоқ, оны жазу керек; «үлгі» — мән мысал үшін ойдан алынған, бұл сіздің деректеріңіз емес.", + "ui.facts.legend": "Жазбалардағы әріптер нені білдіреді", + "ui.facts.legend.D": "D — құжаты бар", + "ui.facts.legend.U": "U — Татьянаның сөзі бойынша", + "ui.facts.legend.W": "W — жұмыс жоспарында аталған", + "ui.facts.legend.H": "H — болжам, тексерілмеген", + "ui.facts.legend.V": "V — дәлел керек", + "ui.facts.authorship": "авторлығын тексеру керек" } diff --git a/locales/ru.json b/locales/ru.json index ff41820..e6334df 100644 --- a/locales/ru.json +++ b/locales/ru.json @@ -818,5 +818,12 @@ "home.check.channels.post": ": в таблице по каждому каналу должны быть видны аудитория, цель, доступ у Татьяны, можно ли публиковать автоматически, ограничения, запасной путь и очередь. Чего мы ещё не знаем, отмечено «нужно уточнить» или «не подтверждено».", "letter.steps": "Порядок: 1. Сохранить. 2. Одобрить. 3. Открыть в почте и отправить самим. 4. Отметить как отправленное.", "ui.sum.noValueHint": "— нажмите на строку и впишите значение", - "ui.sum.legend": "«Не внесено» — значения пока нет, его нужно вписать; «образец» — значение придумано для примера, это не ваши данные." + "ui.sum.legend": "«Не внесено» — значения пока нет, его нужно вписать; «образец» — значение придумано для примера, это не ваши данные.", + "ui.facts.legend": "Что значат буквы у записей", + "ui.facts.legend.D": "D — есть документ", + "ui.facts.legend.U": "U — со слов Татьяны", + "ui.facts.legend.W": "W — упомянуто в рабочем плане", + "ui.facts.legend.H": "H — гипотеза, не проверена", + "ui.facts.legend.V": "V — нужно доказательство", + "ui.facts.authorship": "проверить авторство" } diff --git a/public/facts.html b/public/facts.html index 9dbb2df..18af38d 100644 --- a/public/facts.html +++ b/public/facts.html @@ -8,7 +8,8 @@ h1{font-size:20px}h2{font-size:17px;margin-top:24px}table{border-collapse:collap .q{margin:8px 0}.q input{width:60%}

-

+

+

@@ -22,7 +23,7 @@ const tag=(c,k)=>`${esc(k)}`; function factRow(f){ const p=f.public,why=p.ok?"":" "+esc(tx("ui.facts.why"))+p.why.map(w=>esc(tx("ui.facts.why."+w))).join(", "); const tags=(f.claimed?tag("warn",tx("ui.facts.claimed")):"")+tag(p.ok?"ok":"no",tx(p.ok?"ui.facts.public.yes":"ui.facts.public.no")) - +tag("",f.level+": "+tx("ui.facts.level."+f.level))+tag("",tx("ui.facts.check."+f.check))+tag("",tx("ui.facts.perm."+f.permission)) + +tag("",tx("ui.facts.legend."+f.level))+(/authorship/.test(f.key)?tag("warn",tx("ui.facts.authorship")):"")+tag("",tx("ui.facts.check."+f.check))+tag("",tx("ui.facts.perm."+f.permission)) +(f.stage?tag("",tx("ui.facts.stage")+": "+tx("ui.facts.stage."+f.stage)):""); const rev=f.revoked?`
${esc(fill(tx("ui.facts.revokedAt"),{why:f.revoked.reason}))}
`:""; const btn=f.revoked?`` diff --git a/test/facts-legend.test.js b/test/facts-legend.test.js new file mode 100644 index 0000000..ee62b99 --- /dev/null +++ b/test/facts-legend.test.js @@ -0,0 +1,15 @@ +import test from "node:test"; +import assert from "node:assert/strict"; +import fs from "node:fs"; +import { LEVELS } from "../src/facts.js"; + +// BRM-111: расшифровка букв D/U/W/H/V есть на странице и во всех языках. +test("BRM-111: у каждой буквы есть расшифровка на трёх языках, на странице — легенда", () => { + const html = fs.readFileSync(new URL("../public/facts.html", import.meta.url), "utf8"); + for (const l of ["ru", "kk", "en"]) { + const d = JSON.parse(fs.readFileSync(new URL(`../locales/${l}.json`, import.meta.url), "utf8")); + for (const k of LEVELS) assert.ok(d["ui.facts.legend." + k].startsWith(k + " "), l + k); + assert.ok(d["ui.facts.authorship"]); + } + for (const k of LEVELS) assert.ok(html.includes(`data-t="ui.facts.legend.${k}"`)); +});