Skip to content

Commit 6ed20e9

Browse files
committed
fix(w3c/headers): errata text, charter type, w3cid for all TR tracks
- Change 'Errata exists' to 'Check for errata' (#4446) - Add 'charter' as a document type (#3570) - Require w3cid for Note and Registry track editors (#4073) Closes #4446 Closes #3570 Closes #4073
1 parent a3d08f9 commit 6ed20e9

4 files changed

Lines changed: 24 additions & 4 deletions

File tree

src/w3c/defaults.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,9 @@ function validateStatusForGroup(conf) {
181181
default:
182182
if (
183183
!conf.wgId &&
184-
!["unofficial", "base", "UD", "Member-SUBM"].includes(specStatus)
184+
!["unofficial", "base", "UD", "Member-SUBM", "charter"].includes(
185+
specStatus
186+
)
185187
) {
186188
const msg =
187189
"Document is not associated with a [W3C group](https://respec.org/w3c/groups/). Defaulting to 'base' status.";

src/w3c/headers.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,7 @@ export const status2text = {
148148
"CG-FINAL": "Final Community Group Report",
149149
"BG-DRAFT": "Draft Business Group Report",
150150
"BG-FINAL": "Final Business Group Report",
151+
charter: "Charter",
151152
};
152153
const status2long = {
153154
...status2text,
@@ -205,6 +206,7 @@ export const noTrackStatus = [
205206
"finding",
206207
"MO",
207208
"unofficial",
209+
"charter",
208210
];
209211
/** @type {Map<string, LicenseInfo>} */
210212
export const licenses = new Map([
@@ -464,7 +466,10 @@ export async function run(conf) {
464466
const msg = "At least one editor is required.";
465467
const hint = docLink`Add one or more editors using the ${"[editors]"} configuration option.`;
466468
showError(msg, name, { hint });
467-
} else if (editors.length && conf.isRecTrack) {
469+
} else if (
470+
editors.length &&
471+
(conf.isRecTrack || conf.isNote || conf.isRegistry)
472+
) {
468473
// check that every editor has w3cid
469474
editors.forEach((editor, i) => {
470475
if (editor.w3cid) return;

src/w3c/templates/headers.js

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,19 @@ const localizationStrings = {
136136
with_subject_line: "con línea de asunto",
137137
your_topic_here: "TU SUJETO AQUÍ",
138138
},
139+
fr: {
140+
archives: "archives",
141+
author: "Auteur :",
142+
authors: "Auteurs :",
143+
editor: "Éditeur :",
144+
editors: "Éditeurs :",
145+
former_editor: "Ancien éditeur :",
146+
former_editors: "Anciens éditeurs :",
147+
latest_editors_draft: "Dernier brouillon de l'éditeur :",
148+
latest_published_version: "Dernière version publiée :",
149+
this_version: "Cette version :",
150+
history: "Historique :",
151+
},
139152
de: {
140153
archives: "Archiv",
141154
author: "Autor/in:",
@@ -362,7 +375,7 @@ export default (conf, options) => {
362375
: ""}
363376
${conf.errata
364377
? html`<dt>Errata:</dt>
365-
<dd><a href="${conf.errata}">Errata exists</a>.</dd>`
378+
<dd><a href="${conf.errata}">Check for errata</a>.</dd>`
366379
: ""}
367380
${conf.otherLinks ? conf.otherLinks.map(showLink) : ""}
368381
</dl>

tests/spec/w3c/headers-spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1163,7 +1163,7 @@ describe("W3C — Headers", () => {
11631163
const [errata] = contains(
11641164
doc,
11651165
".head dd>a[href='https://foo.com']",
1166-
"Errata exists"
1166+
"Check for errata"
11671167
);
11681168
expect(errata).toBeTruthy();
11691169
});

0 commit comments

Comments
 (0)