Skip to content

Commit

Permalink
Add arraybuffer-base64 and digital identities specs (#1204)
Browse files Browse the repository at this point in the history
Also adjust logic in compute-shortname to avoid giving series versions to TC39 specs.
  • Loading branch information
dontcallmedom authored Feb 19, 2024
1 parent 85dcd45 commit a008958
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 2 deletions.
11 changes: 11 additions & 0 deletions specs.json
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,16 @@
},
"https://tc39.es/proposal-array-from-async/",
"https://tc39.es/proposal-array-grouping/",
{
"url": "https://tc39.es/proposal-arraybuffer-base64/spec/",
"series": {
"shortname": "tc39-arraybuffer-base64"
},
"shortname": "tc39-arraybuffer-base64",
"nightly": {
"sourcePath": "spec.html"
}
},
"https://tc39.es/proposal-arraybuffer-transfer/",
"https://tc39.es/proposal-async-explicit-resource-management/",
{
Expand Down Expand Up @@ -577,6 +587,7 @@
"https://wicg.github.io/datacue/",
"https://wicg.github.io/deprecation-reporting/",
"https://wicg.github.io/digital-goods/",
"https://wicg.github.io/digital-identities/",
"https://wicg.github.io/direct-sockets/",
"https://wicg.github.io/document-picture-in-picture/",
"https://wicg.github.io/document-policy/",
Expand Down
5 changes: 3 additions & 2 deletions src/compute-shortname.js
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,8 @@ function completeWithSeriesAndLevel(shortname, url, forkOf) {
// typically have the form "ecma-ddd", and "ddd" is *not* a level number.
// And that's the same for ISO standards which end with plenty of non-level
// digits, as in "iso18181-2".
if (seriesBasename.match(/^ecma-/) ||
if (seriesBasename.startsWith("ecma-") ||
seriesBasename.startsWith("tc39-") ||
seriesBasename.startsWith("iso") ||
url.match(/^https:\/\/registry\.khronos\.org\/webgl\/extensions\//)) {
return {
Expand All @@ -188,7 +189,7 @@ function completeWithSeriesAndLevel(shortname, url, forkOf) {

// Extract X and X.Y levels, with form "name-X" or "name-X.Y".
// (e.g. 5 for "mediaqueries-5", 1.2 for "wai-aria-1.2")
let match = seriesBasename.match(/^(.*?)-v?(\d+)(.\d+)?$/);
let match = seriesBasename.match(/^(.*?)-v?(\d+)(\.\d+)?$/);
if (match) {
return {
shortname: specShortname,
Expand Down
3 changes: 3 additions & 0 deletions src/data/ignore.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,9 @@
"WICG/close-watcher": {
"comment": "merged into HTML"
},
"WICG/discourse-archive": {
"comment": "not a spec"
},
"WICG/priority-hints": {
"comment": "merged into HTML"
},
Expand Down
4 changes: 4 additions & 0 deletions test/compute-shortname.js
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,10 @@ describe("compute-shortname module", () => {
assertNoSeriesVersion("ecma-402");
});

it("does not confuse a TC39 proposal number with a series version", () => {
assertNoSeriesVersion("tc39-arraybuffer-base64");
});

it("does not confuse an ISO spec number with a series version", () => {
assertNoSeriesVersion("iso18181-2");
});
Expand Down

0 comments on commit a008958

Please sign in to comment.