Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/core/mdn-annotation.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { insertStyle } from "./insert-style.js";

export const name = "core/mdn-annotation";

const BASE_JSON_PATH = "https://w3c.github.io/mdn-spec-links/";
const BASE_JSON_PATH = "https://speced.github.io/mdn-spec-links/";
const MDN_URL_BASE = "https://developer.mozilla.org/en-US/docs/Web/";
const MDN_BROWSERS = {
// The browser IDs here must match the ones in the imported JSON data.
Expand Down Expand Up @@ -147,8 +147,8 @@ export async function run(conf) {
const msg = `Could not find MDN data associated with key "${mdnKey}".`;
const hint =
conf.mdn === true
? docLink`When using \`mdn: true\`, the key defaults to ${"[shortName]"} ("${mdnKey}"). Check that your shortName matches an entry in the [MDN spec links map](https://github.com/w3c/mdn-spec-links/blob/main/SPECMAP.json), or set ${"[mdn]"} to the correct key.`
: docLink`Search for your spec's URL in the [MDN spec links map](https://github.com/w3c/mdn-spec-links/blob/main/SPECMAP.json) to find the correct key, then set ${"[mdn]"} to it.`;
? docLink`When using \`mdn: true\`, the key defaults to ${"[shortName]"} ("${mdnKey}"). Check that your shortName matches an entry in the [MDN spec links map](https://github.com/speced/mdn-spec-links/blob/main/SPECMAP.json), or set ${"[mdn]"} to the correct key.`
: docLink`Search for your spec's URL in the [MDN spec links map](https://github.com/speced/mdn-spec-links/blob/main/SPECMAP.json) to find the correct key, then set ${"[mdn]"} to it.`;
showError(msg, name, { hint });
return;
}
Expand Down
2 changes: 1 addition & 1 deletion tests/spec/core/mdn-annotation-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ describe("Core - MDN Annotation", () => {
});

// Can't directly test `mdn: true` because it uses the default
// BASE_JSON_PATH (w3c.github.io), which isn't available in tests.
// BASE_JSON_PATH (speced.github.io), which isn't available in tests.
// Instead, test the explicit-key hint via `mdn.key`.
it("shows a helpful hint when an explicit mdn key is not found (404)", async () => {
const ops = makeStandardOps({
Expand Down
Loading