synthesisui 0.16.372 → 0.16.373
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/doctor.js +24 -5
- package/dist/doctor/gap-triage.js +32 -2
- package/package.json +1 -1
package/dist/commands/doctor.js
CHANGED
|
@@ -877,6 +877,21 @@ export async function doctor(opts) {
|
|
|
877
877
|
* `"yours"` e `"adopted"` são o vocabulário dela, e não há duas linhas para ligar.
|
|
878
878
|
*/
|
|
879
879
|
const blocked = table.source === "installed" && (!wiring.imported || !wiring.scoped);
|
|
880
|
+
/**
|
|
881
|
+
* QUANTAS DAS DUAS FALTAM - e sem este número três frases mandavam consertar DUAS coisas quando
|
|
882
|
+
* faltava UMA.
|
|
883
|
+
*
|
|
884
|
+
* `blocked` é um OU, e as frases que ele governa foram escritas assumindo o E: *"Until both are
|
|
885
|
+
* true"*, *"--fix is refused while those two are false"* e *"Wire the two lines first"*. Visto na
|
|
886
|
+
* máquina do dono em 04/09, num repositório onde `data-ds` já estava lá com um ✓ impresso três
|
|
887
|
+
* linhas acima: a tela contradizia a própria lista, e a terceira frase é INSTRUÇÃO - a pessoa está
|
|
888
|
+
* bloqueada, procurando o que escrever, e ela manda escrever duas linhas.
|
|
889
|
+
*
|
|
890
|
+
* O caso de faltar UMA é o mais comum: uma instalação que parou no meio erra um dos dois passos,
|
|
891
|
+
* não os dois. Derivado da mesma leitura que decide `blocked`, para as duas nunca discordarem.
|
|
892
|
+
*/
|
|
893
|
+
const missingWiring = (wiring.imported ? 0 : 1) + (wiring.scoped ? 0 : 1);
|
|
894
|
+
const bothMissing = missingWiring === 2;
|
|
880
895
|
const unwired = table.source === "installed" &&
|
|
881
896
|
(!wiring.imported || !wiring.scoped || fontsPending);
|
|
882
897
|
if (unwired) {
|
|
@@ -907,7 +922,9 @@ export async function doctor(opts) {
|
|
|
907
922
|
* enquanto imprimia o número abaixo; agora não há número abaixo, e prometer um seria a mesma
|
|
908
923
|
* incoerência ao contrário.
|
|
909
924
|
*/
|
|
910
|
-
console.log(body(
|
|
925
|
+
console.log(body(bothMissing
|
|
926
|
+
? `Until both are true, none of the ${table.byName.size} tokens reach the browser.`
|
|
927
|
+
: `Until that one is true, none of the ${table.byName.size} tokens reach the browser.`));
|
|
911
928
|
}
|
|
912
929
|
else {
|
|
913
930
|
console.log(body("Colour and spacing are working. Type is not: the system's faces"));
|
|
@@ -965,10 +982,12 @@ export async function doctor(opts) {
|
|
|
965
982
|
}).catch(() => { });
|
|
966
983
|
console.log("");
|
|
967
984
|
if (opts.fix) {
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
console.log(body("
|
|
971
|
-
console.log(body("
|
|
985
|
+
/** `1 ... do have` saía assim desde sempre; a frase que recusa um comando não pode tropeçar. */
|
|
986
|
+
const one = d.named === 1;
|
|
987
|
+
console.log(body(`--fix is refused while ${bothMissing ? "those two are" : "that one is"} false. ${d.named} of your hand-written values`));
|
|
988
|
+
console.log(body(`${one ? "does" : "do"} have a name in the system, and swapping ${one ? "it" : "them"} now would point ${one ? "it" : "them"} at`));
|
|
989
|
+
console.log(body(`variables the browser cannot resolve - the ${one ? "declaration" : "declarations"} would be dropped`));
|
|
990
|
+
console.log(body(`and the page would change. Wire ${bothMissing ? "the two lines" : "that line"} first.`));
|
|
972
991
|
}
|
|
973
992
|
else {
|
|
974
993
|
console.log(body(`${d.named} of the ${d.findings.length} hand-written values found have a name waiting in`));
|
|
@@ -235,13 +235,43 @@ values) {
|
|
|
235
235
|
* VALOR daquilo está no sistema, e não só que não há o que consertar.
|
|
236
236
|
*/
|
|
237
237
|
const theirs = group.reduce((n, g) => n + (g.withTheirTokens ?? 0), 0);
|
|
238
|
-
lines.push("",
|
|
238
|
+
lines.push("",
|
|
239
|
+
/**
|
|
240
|
+
* O DENOMINADOR VAI NA FRASE - e a falta dele era o mesmo defeito consertado pela METADE.
|
|
241
|
+
*
|
|
242
|
+
* A linha de cima estabelece decisões (1063, das quais 1007 interpretadas: 56 fora), e este
|
|
243
|
+
* percentual é sobre FRAGMENTOS (32). Dizer só "of what was not interpreted" faz as duas
|
|
244
|
+
* grandezas usarem a mesma palavra na mesma tela: quem soma 81 + 9 + 9 conclui que a triagem
|
|
245
|
+
* cobriu tudo, e ela cobriu 32 de 56.
|
|
246
|
+
*
|
|
247
|
+
* Em 03/09 o dono viu exatamente isto e o conserto reescreveu a linha do MEIO ("They live in N
|
|
248
|
+
* places in your code"). Estes três cabeçalhos ficaram com a expressão antiga - mesma tela,
|
|
249
|
+
* mesmo defeito, na parte que não foi olhada. Visto de novo em 04/09.
|
|
250
|
+
*/
|
|
251
|
+
`${label[verdict]} - ${total} fragment${total === 1 ? "" : "s"}, ${unread > 0 ? Math.round((total / unread) * 100) : 0}% of those ${unread} place${unread === 1 ? "" : "s"}${theirs > 0
|
|
239
252
|
? ` — and ${theirs} of them already wear a token you declare, so their value is in the system`
|
|
240
253
|
: ""}`);
|
|
241
254
|
for (const gap of group) {
|
|
242
255
|
lines.push(` ${gap.uses} ${gap.shape} in ${gap.files} file${gap.files === 1 ? "" : "s"} (${gap.share}%) - ${gap.work}`);
|
|
243
|
-
|
|
256
|
+
/**
|
|
257
|
+
* TODOS OS QUE O CENSO GUARDOU, E O QUE FICOU DE FORA DITO EM VOZ ALTA.
|
|
258
|
+
*
|
|
259
|
+
* Isto cortava em dois (`slice(0, 2)`) sobre os até TRÊS que `style-ledger` grava - um por
|
|
260
|
+
* arquivo -, e não dizia nada. Na tela do dono em 04/09: *"3 class in 3 files"* seguido de dois
|
|
261
|
+
* arquivos, e o terceiro sumiu sem uma palavra. Ele conserta dois e acha que acabou.
|
|
262
|
+
*
|
|
263
|
+
* O GÊMEO JÁ TINHA O AVISO e este não: a tela de admin ganhou *"Not the whole set: N more"* no
|
|
264
|
+
* #1304. Duas superfícies respondem a mesma pergunta, e só uma admitia o corte - que é a Lei 8
|
|
265
|
+
* ao contrário, lacuna calada.
|
|
266
|
+
*
|
|
267
|
+
* O QUE FALTA SÃO ARQUIVOS, e é isso que a linha conta: o censo guarda um exemplo por arquivo,
|
|
268
|
+
* então `files` menos os mostrados é literalmente quantos arquivos você não está vendo.
|
|
269
|
+
*/
|
|
270
|
+
for (const example of gap.examples)
|
|
244
271
|
lines.push(` ${example.file}:${example.line} ${example.text.slice(0, 76)}`);
|
|
272
|
+
const hidden = gap.files - gap.examples.length;
|
|
273
|
+
if (hidden > 0)
|
|
274
|
+
lines.push(` not the whole set: ${hidden} more file${hidden === 1 ? "" : "s"} with this shape, not listed here`);
|
|
245
275
|
}
|
|
246
276
|
}
|
|
247
277
|
return lines;
|
package/package.json
CHANGED