mirror of
https://github.com/actions/setup-java.git
synced 2025-04-22 02:46:46 +00:00
Fix.
This commit is contained in:
parent
596a6da241
commit
c1a589c5b6
7078 changed files with 1882834 additions and 319 deletions
3
node_modules/uri-js/dist/esnext/schemes/http.d.ts
generated
vendored
Normal file
3
node_modules/uri-js/dist/esnext/schemes/http.d.ts
generated
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
import { URISchemeHandler } from "../uri";
|
||||
declare const handler: URISchemeHandler;
|
||||
export default handler;
|
27
node_modules/uri-js/dist/esnext/schemes/http.js
generated
vendored
Normal file
27
node_modules/uri-js/dist/esnext/schemes/http.js
generated
vendored
Normal file
|
@ -0,0 +1,27 @@
|
|||
const handler = {
|
||||
scheme: "http",
|
||||
domainHost: true,
|
||||
parse: function (components, options) {
|
||||
//report missing host
|
||||
if (!components.host) {
|
||||
components.error = components.error || "HTTP URIs must have a host.";
|
||||
}
|
||||
return components;
|
||||
},
|
||||
serialize: function (components, options) {
|
||||
//normalize the default port
|
||||
if (components.port === (String(components.scheme).toLowerCase() !== "https" ? 80 : 443) || components.port === "") {
|
||||
components.port = undefined;
|
||||
}
|
||||
//normalize the empty path
|
||||
if (!components.path) {
|
||||
components.path = "/";
|
||||
}
|
||||
//NOTE: We do not parse query strings for HTTP URIs
|
||||
//as WWW Form Url Encoded query strings are part of the HTML4+ spec,
|
||||
//and not the HTTP spec.
|
||||
return components;
|
||||
}
|
||||
};
|
||||
export default handler;
|
||||
//# sourceMappingURL=http.js.map
|
1
node_modules/uri-js/dist/esnext/schemes/http.js.map
generated
vendored
Normal file
1
node_modules/uri-js/dist/esnext/schemes/http.js.map
generated
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"http.js","sourceRoot":"","sources":["../../../src/schemes/http.ts"],"names":[],"mappings":"AAEA,MAAM,OAAO,GAAoB;IAChC,MAAM,EAAG,MAAM;IAEf,UAAU,EAAG,IAAI;IAEjB,KAAK,EAAG,UAAU,UAAwB,EAAE,OAAkB;QAC7D,qBAAqB;QACrB,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE;YACrB,UAAU,CAAC,KAAK,GAAG,UAAU,CAAC,KAAK,IAAI,6BAA6B,CAAC;SACrE;QAED,OAAO,UAAU,CAAC;IACnB,CAAC;IAED,SAAS,EAAG,UAAU,UAAwB,EAAE,OAAkB;QACjE,4BAA4B;QAC5B,IAAI,UAAU,CAAC,IAAI,KAAK,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,KAAK,OAAO,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,UAAU,CAAC,IAAI,KAAK,EAAE,EAAE;YACnH,UAAU,CAAC,IAAI,GAAG,SAAS,CAAC;SAC5B;QAED,0BAA0B;QAC1B,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE;YACrB,UAAU,CAAC,IAAI,GAAG,GAAG,CAAC;SACtB;QAED,mDAAmD;QACnD,oEAAoE;QACpE,wBAAwB;QAExB,OAAO,UAAU,CAAC;IACnB,CAAC;CACD,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
3
node_modules/uri-js/dist/esnext/schemes/https.d.ts
generated
vendored
Normal file
3
node_modules/uri-js/dist/esnext/schemes/https.d.ts
generated
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
import { URISchemeHandler } from "../uri";
|
||||
declare const handler: URISchemeHandler;
|
||||
export default handler;
|
9
node_modules/uri-js/dist/esnext/schemes/https.js
generated
vendored
Normal file
9
node_modules/uri-js/dist/esnext/schemes/https.js
generated
vendored
Normal file
|
@ -0,0 +1,9 @@
|
|||
import http from "./http";
|
||||
const handler = {
|
||||
scheme: "https",
|
||||
domainHost: http.domainHost,
|
||||
parse: http.parse,
|
||||
serialize: http.serialize
|
||||
};
|
||||
export default handler;
|
||||
//# sourceMappingURL=https.js.map
|
1
node_modules/uri-js/dist/esnext/schemes/https.js.map
generated
vendored
Normal file
1
node_modules/uri-js/dist/esnext/schemes/https.js.map
generated
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"https.js","sourceRoot":"","sources":["../../../src/schemes/https.ts"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,QAAQ,CAAC;AAE1B,MAAM,OAAO,GAAoB;IAChC,MAAM,EAAG,OAAO;IAChB,UAAU,EAAG,IAAI,CAAC,UAAU;IAC5B,KAAK,EAAG,IAAI,CAAC,KAAK;IAClB,SAAS,EAAG,IAAI,CAAC,SAAS;CAC1B,CAAA;AAED,eAAe,OAAO,CAAC"}
|
12
node_modules/uri-js/dist/esnext/schemes/mailto.d.ts
generated
vendored
Normal file
12
node_modules/uri-js/dist/esnext/schemes/mailto.d.ts
generated
vendored
Normal file
|
@ -0,0 +1,12 @@
|
|||
import { URISchemeHandler, URIComponents } from "../uri";
|
||||
export interface MailtoHeaders {
|
||||
[hfname: string]: string;
|
||||
}
|
||||
export interface MailtoComponents extends URIComponents {
|
||||
to: Array<string>;
|
||||
headers?: MailtoHeaders;
|
||||
subject?: string;
|
||||
body?: string;
|
||||
}
|
||||
declare const handler: URISchemeHandler<MailtoComponents>;
|
||||
export default handler;
|
148
node_modules/uri-js/dist/esnext/schemes/mailto.js
generated
vendored
Normal file
148
node_modules/uri-js/dist/esnext/schemes/mailto.js
generated
vendored
Normal file
|
@ -0,0 +1,148 @@
|
|||
import { pctEncChar, pctDecChars, unescapeComponent } from "../uri";
|
||||
import punycode from "punycode";
|
||||
import { merge, subexp, toUpperCase, toArray } from "../util";
|
||||
const O = {};
|
||||
const isIRI = true;
|
||||
//RFC 3986
|
||||
const UNRESERVED$$ = "[A-Za-z0-9\\-\\.\\_\\~" + (isIRI ? "\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF" : "") + "]";
|
||||
const HEXDIG$$ = "[0-9A-Fa-f]"; //case-insensitive
|
||||
const PCT_ENCODED$ = subexp(subexp("%[EFef]" + HEXDIG$$ + "%" + HEXDIG$$ + HEXDIG$$ + "%" + HEXDIG$$ + HEXDIG$$) + "|" + subexp("%[89A-Fa-f]" + HEXDIG$$ + "%" + HEXDIG$$ + HEXDIG$$) + "|" + subexp("%" + HEXDIG$$ + HEXDIG$$)); //expanded
|
||||
//RFC 5322, except these symbols as per RFC 6068: @ : / ? # [ ] & ; =
|
||||
//const ATEXT$$ = "[A-Za-z0-9\\!\\#\\$\\%\\&\\'\\*\\+\\-\\/\\=\\?\\^\\_\\`\\{\\|\\}\\~]";
|
||||
//const WSP$$ = "[\\x20\\x09]";
|
||||
//const OBS_QTEXT$$ = "[\\x01-\\x08\\x0B\\x0C\\x0E-\\x1F\\x7F]"; //(%d1-8 / %d11-12 / %d14-31 / %d127)
|
||||
//const QTEXT$$ = merge("[\\x21\\x23-\\x5B\\x5D-\\x7E]", OBS_QTEXT$$); //%d33 / %d35-91 / %d93-126 / obs-qtext
|
||||
//const VCHAR$$ = "[\\x21-\\x7E]";
|
||||
//const WSP$$ = "[\\x20\\x09]";
|
||||
//const OBS_QP$ = subexp("\\\\" + merge("[\\x00\\x0D\\x0A]", OBS_QTEXT$$)); //%d0 / CR / LF / obs-qtext
|
||||
//const FWS$ = subexp(subexp(WSP$$ + "*" + "\\x0D\\x0A") + "?" + WSP$$ + "+");
|
||||
//const QUOTED_PAIR$ = subexp(subexp("\\\\" + subexp(VCHAR$$ + "|" + WSP$$)) + "|" + OBS_QP$);
|
||||
//const QUOTED_STRING$ = subexp('\\"' + subexp(FWS$ + "?" + QCONTENT$) + "*" + FWS$ + "?" + '\\"');
|
||||
const ATEXT$$ = "[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]";
|
||||
const QTEXT$$ = "[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]";
|
||||
const VCHAR$$ = merge(QTEXT$$, "[\\\"\\\\]");
|
||||
const DOT_ATOM_TEXT$ = subexp(ATEXT$$ + "+" + subexp("\\." + ATEXT$$ + "+") + "*");
|
||||
const QUOTED_PAIR$ = subexp("\\\\" + VCHAR$$);
|
||||
const QCONTENT$ = subexp(QTEXT$$ + "|" + QUOTED_PAIR$);
|
||||
const QUOTED_STRING$ = subexp('\\"' + QCONTENT$ + "*" + '\\"');
|
||||
//RFC 6068
|
||||
const DTEXT_NO_OBS$$ = "[\\x21-\\x5A\\x5E-\\x7E]"; //%d33-90 / %d94-126
|
||||
const SOME_DELIMS$$ = "[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]";
|
||||
const QCHAR$ = subexp(UNRESERVED$$ + "|" + PCT_ENCODED$ + "|" + SOME_DELIMS$$);
|
||||
const DOMAIN$ = subexp(DOT_ATOM_TEXT$ + "|" + "\\[" + DTEXT_NO_OBS$$ + "*" + "\\]");
|
||||
const LOCAL_PART$ = subexp(DOT_ATOM_TEXT$ + "|" + QUOTED_STRING$);
|
||||
const ADDR_SPEC$ = subexp(LOCAL_PART$ + "\\@" + DOMAIN$);
|
||||
const TO$ = subexp(ADDR_SPEC$ + subexp("\\," + ADDR_SPEC$) + "*");
|
||||
const HFNAME$ = subexp(QCHAR$ + "*");
|
||||
const HFVALUE$ = HFNAME$;
|
||||
const HFIELD$ = subexp(HFNAME$ + "\\=" + HFVALUE$);
|
||||
const HFIELDS2$ = subexp(HFIELD$ + subexp("\\&" + HFIELD$) + "*");
|
||||
const HFIELDS$ = subexp("\\?" + HFIELDS2$);
|
||||
const MAILTO_URI = new RegExp("^mailto\\:" + TO$ + "?" + HFIELDS$ + "?$");
|
||||
const UNRESERVED = new RegExp(UNRESERVED$$, "g");
|
||||
const PCT_ENCODED = new RegExp(PCT_ENCODED$, "g");
|
||||
const NOT_LOCAL_PART = new RegExp(merge("[^]", ATEXT$$, "[\\.]", '[\\"]', VCHAR$$), "g");
|
||||
const NOT_DOMAIN = new RegExp(merge("[^]", ATEXT$$, "[\\.]", "[\\[]", DTEXT_NO_OBS$$, "[\\]]"), "g");
|
||||
const NOT_HFNAME = new RegExp(merge("[^]", UNRESERVED$$, SOME_DELIMS$$), "g");
|
||||
const NOT_HFVALUE = NOT_HFNAME;
|
||||
const TO = new RegExp("^" + TO$ + "$");
|
||||
const HFIELDS = new RegExp("^" + HFIELDS2$ + "$");
|
||||
function decodeUnreserved(str) {
|
||||
const decStr = pctDecChars(str);
|
||||
return (!decStr.match(UNRESERVED) ? str : decStr);
|
||||
}
|
||||
const handler = {
|
||||
scheme: "mailto",
|
||||
parse: function (components, options) {
|
||||
const mailtoComponents = components;
|
||||
const to = mailtoComponents.to = (mailtoComponents.path ? mailtoComponents.path.split(",") : []);
|
||||
mailtoComponents.path = undefined;
|
||||
if (mailtoComponents.query) {
|
||||
let unknownHeaders = false;
|
||||
const headers = {};
|
||||
const hfields = mailtoComponents.query.split("&");
|
||||
for (let x = 0, xl = hfields.length; x < xl; ++x) {
|
||||
const hfield = hfields[x].split("=");
|
||||
switch (hfield[0]) {
|
||||
case "to":
|
||||
const toAddrs = hfield[1].split(",");
|
||||
for (let x = 0, xl = toAddrs.length; x < xl; ++x) {
|
||||
to.push(toAddrs[x]);
|
||||
}
|
||||
break;
|
||||
case "subject":
|
||||
mailtoComponents.subject = unescapeComponent(hfield[1], options);
|
||||
break;
|
||||
case "body":
|
||||
mailtoComponents.body = unescapeComponent(hfield[1], options);
|
||||
break;
|
||||
default:
|
||||
unknownHeaders = true;
|
||||
headers[unescapeComponent(hfield[0], options)] = unescapeComponent(hfield[1], options);
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (unknownHeaders)
|
||||
mailtoComponents.headers = headers;
|
||||
}
|
||||
mailtoComponents.query = undefined;
|
||||
for (let x = 0, xl = to.length; x < xl; ++x) {
|
||||
const addr = to[x].split("@");
|
||||
addr[0] = unescapeComponent(addr[0]);
|
||||
if (!options.unicodeSupport) {
|
||||
//convert Unicode IDN -> ASCII IDN
|
||||
try {
|
||||
addr[1] = punycode.toASCII(unescapeComponent(addr[1], options).toLowerCase());
|
||||
}
|
||||
catch (e) {
|
||||
mailtoComponents.error = mailtoComponents.error || "Email address's domain name can not be converted to ASCII via punycode: " + e;
|
||||
}
|
||||
}
|
||||
else {
|
||||
addr[1] = unescapeComponent(addr[1], options).toLowerCase();
|
||||
}
|
||||
to[x] = addr.join("@");
|
||||
}
|
||||
return mailtoComponents;
|
||||
},
|
||||
serialize: function (mailtoComponents, options) {
|
||||
const components = mailtoComponents;
|
||||
const to = toArray(mailtoComponents.to);
|
||||
if (to) {
|
||||
for (let x = 0, xl = to.length; x < xl; ++x) {
|
||||
const toAddr = String(to[x]);
|
||||
const atIdx = toAddr.lastIndexOf("@");
|
||||
const localPart = (toAddr.slice(0, atIdx)).replace(PCT_ENCODED, decodeUnreserved).replace(PCT_ENCODED, toUpperCase).replace(NOT_LOCAL_PART, pctEncChar);
|
||||
let domain = toAddr.slice(atIdx + 1);
|
||||
//convert IDN via punycode
|
||||
try {
|
||||
domain = (!options.iri ? punycode.toASCII(unescapeComponent(domain, options).toLowerCase()) : punycode.toUnicode(domain));
|
||||
}
|
||||
catch (e) {
|
||||
components.error = components.error || "Email address's domain name can not be converted to " + (!options.iri ? "ASCII" : "Unicode") + " via punycode: " + e;
|
||||
}
|
||||
to[x] = localPart + "@" + domain;
|
||||
}
|
||||
components.path = to.join(",");
|
||||
}
|
||||
const headers = mailtoComponents.headers = mailtoComponents.headers || {};
|
||||
if (mailtoComponents.subject)
|
||||
headers["subject"] = mailtoComponents.subject;
|
||||
if (mailtoComponents.body)
|
||||
headers["body"] = mailtoComponents.body;
|
||||
const fields = [];
|
||||
for (const name in headers) {
|
||||
if (headers[name] !== O[name]) {
|
||||
fields.push(name.replace(PCT_ENCODED, decodeUnreserved).replace(PCT_ENCODED, toUpperCase).replace(NOT_HFNAME, pctEncChar) +
|
||||
"=" +
|
||||
headers[name].replace(PCT_ENCODED, decodeUnreserved).replace(PCT_ENCODED, toUpperCase).replace(NOT_HFVALUE, pctEncChar));
|
||||
}
|
||||
}
|
||||
if (fields.length) {
|
||||
components.query = fields.join("&");
|
||||
}
|
||||
return components;
|
||||
}
|
||||
};
|
||||
export default handler;
|
||||
//# sourceMappingURL=mailto.js.map
|
1
node_modules/uri-js/dist/esnext/schemes/mailto.js.map
generated
vendored
Normal file
1
node_modules/uri-js/dist/esnext/schemes/mailto.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
7
node_modules/uri-js/dist/esnext/schemes/urn-uuid.d.ts
generated
vendored
Normal file
7
node_modules/uri-js/dist/esnext/schemes/urn-uuid.d.ts
generated
vendored
Normal file
|
@ -0,0 +1,7 @@
|
|||
import { URISchemeHandler, URIOptions } from "../uri";
|
||||
import { URNComponents } from "./urn";
|
||||
export interface UUIDComponents extends URNComponents {
|
||||
uuid?: string;
|
||||
}
|
||||
declare const handler: URISchemeHandler<UUIDComponents, URIOptions, URNComponents>;
|
||||
export default handler;
|
23
node_modules/uri-js/dist/esnext/schemes/urn-uuid.js
generated
vendored
Normal file
23
node_modules/uri-js/dist/esnext/schemes/urn-uuid.js
generated
vendored
Normal file
|
@ -0,0 +1,23 @@
|
|||
const UUID = /^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;
|
||||
const UUID_PARSE = /^[0-9A-Fa-f\-]{36}/;
|
||||
//RFC 4122
|
||||
const handler = {
|
||||
scheme: "urn:uuid",
|
||||
parse: function (urnComponents, options) {
|
||||
const uuidComponents = urnComponents;
|
||||
uuidComponents.uuid = uuidComponents.nss;
|
||||
uuidComponents.nss = undefined;
|
||||
if (!options.tolerant && (!uuidComponents.uuid || !uuidComponents.uuid.match(UUID))) {
|
||||
uuidComponents.error = uuidComponents.error || "UUID is not valid.";
|
||||
}
|
||||
return uuidComponents;
|
||||
},
|
||||
serialize: function (uuidComponents, options) {
|
||||
const urnComponents = uuidComponents;
|
||||
//normalize UUID
|
||||
urnComponents.nss = (uuidComponents.uuid || "").toLowerCase();
|
||||
return urnComponents;
|
||||
},
|
||||
};
|
||||
export default handler;
|
||||
//# sourceMappingURL=urn-uuid.js.map
|
1
node_modules/uri-js/dist/esnext/schemes/urn-uuid.js.map
generated
vendored
Normal file
1
node_modules/uri-js/dist/esnext/schemes/urn-uuid.js.map
generated
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"urn-uuid.js","sourceRoot":"","sources":["../../../src/schemes/urn-uuid.ts"],"names":[],"mappings":"AAQA,MAAM,IAAI,GAAG,0DAA0D,CAAC;AACxE,MAAM,UAAU,GAAG,oBAAoB,CAAC;AAExC,UAAU;AACV,MAAM,OAAO,GAA+D;IAC3E,MAAM,EAAG,UAAU;IAEnB,KAAK,EAAG,UAAU,aAA2B,EAAE,OAAkB;QAChE,MAAM,cAAc,GAAG,aAA+B,CAAC;QACvD,cAAc,CAAC,IAAI,GAAG,cAAc,CAAC,GAAG,CAAC;QACzC,cAAc,CAAC,GAAG,GAAG,SAAS,CAAC;QAE/B,IAAI,CAAC,OAAO,CAAC,QAAQ,IAAI,CAAC,CAAC,cAAc,CAAC,IAAI,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,EAAE;YACpF,cAAc,CAAC,KAAK,GAAG,cAAc,CAAC,KAAK,IAAI,oBAAoB,CAAC;SACpE;QAED,OAAO,cAAc,CAAC;IACvB,CAAC;IAED,SAAS,EAAG,UAAU,cAA6B,EAAE,OAAkB;QACtE,MAAM,aAAa,GAAG,cAA+B,CAAC;QACtD,gBAAgB;QAChB,aAAa,CAAC,GAAG,GAAG,CAAC,cAAc,CAAC,IAAI,IAAI,EAAE,CAAC,CAAC,WAAW,EAAE,CAAC;QAC9D,OAAO,aAAa,CAAC;IACtB,CAAC;CACD,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
10
node_modules/uri-js/dist/esnext/schemes/urn.d.ts
generated
vendored
Normal file
10
node_modules/uri-js/dist/esnext/schemes/urn.d.ts
generated
vendored
Normal file
|
@ -0,0 +1,10 @@
|
|||
import { URISchemeHandler, URIComponents, URIOptions } from "../uri";
|
||||
export interface URNComponents extends URIComponents {
|
||||
nid?: string;
|
||||
nss?: string;
|
||||
}
|
||||
export interface URNOptions extends URIOptions {
|
||||
nid?: string;
|
||||
}
|
||||
declare const handler: URISchemeHandler<URNComponents, URNOptions>;
|
||||
export default handler;
|
49
node_modules/uri-js/dist/esnext/schemes/urn.js
generated
vendored
Normal file
49
node_modules/uri-js/dist/esnext/schemes/urn.js
generated
vendored
Normal file
|
@ -0,0 +1,49 @@
|
|||
import { SCHEMES } from "../uri";
|
||||
const NID$ = "(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})";
|
||||
const PCT_ENCODED$ = "(?:\\%[0-9A-Fa-f]{2})";
|
||||
const TRANS$$ = "[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]";
|
||||
const NSS$ = "(?:(?:" + PCT_ENCODED$ + "|" + TRANS$$ + ")+)";
|
||||
const URN_SCHEME = new RegExp("^urn\\:(" + NID$ + ")$");
|
||||
const URN_PATH = new RegExp("^(" + NID$ + ")\\:(" + NSS$ + ")$");
|
||||
const URN_PARSE = /^([^\:]+)\:(.*)/;
|
||||
const URN_EXCLUDED = /[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g;
|
||||
//RFC 2141
|
||||
const handler = {
|
||||
scheme: "urn",
|
||||
parse: function (components, options) {
|
||||
const matches = components.path && components.path.match(URN_PARSE);
|
||||
let urnComponents = components;
|
||||
if (matches) {
|
||||
const scheme = options.scheme || urnComponents.scheme || "urn";
|
||||
const nid = matches[1].toLowerCase();
|
||||
const nss = matches[2];
|
||||
const urnScheme = `${scheme}:${options.nid || nid}`;
|
||||
const schemeHandler = SCHEMES[urnScheme];
|
||||
urnComponents.nid = nid;
|
||||
urnComponents.nss = nss;
|
||||
urnComponents.path = undefined;
|
||||
if (schemeHandler) {
|
||||
urnComponents = schemeHandler.parse(urnComponents, options);
|
||||
}
|
||||
}
|
||||
else {
|
||||
urnComponents.error = urnComponents.error || "URN can not be parsed.";
|
||||
}
|
||||
return urnComponents;
|
||||
},
|
||||
serialize: function (urnComponents, options) {
|
||||
const scheme = options.scheme || urnComponents.scheme || "urn";
|
||||
const nid = urnComponents.nid;
|
||||
const urnScheme = `${scheme}:${options.nid || nid}`;
|
||||
const schemeHandler = SCHEMES[urnScheme];
|
||||
if (schemeHandler) {
|
||||
urnComponents = schemeHandler.serialize(urnComponents, options);
|
||||
}
|
||||
const uriComponents = urnComponents;
|
||||
const nss = urnComponents.nss;
|
||||
uriComponents.path = `${nid || options.nid}:${nss}`;
|
||||
return uriComponents;
|
||||
},
|
||||
};
|
||||
export default handler;
|
||||
//# sourceMappingURL=urn.js.map
|
1
node_modules/uri-js/dist/esnext/schemes/urn.js.map
generated
vendored
Normal file
1
node_modules/uri-js/dist/esnext/schemes/urn.js.map
generated
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"urn.js","sourceRoot":"","sources":["../../../src/schemes/urn.ts"],"names":[],"mappings":"AACA,OAAO,EAAc,OAAO,EAAE,MAAM,QAAQ,CAAC;AAW7C,MAAM,IAAI,GAAG,qCAAqC,CAAC;AACnD,MAAM,YAAY,GAAG,uBAAuB,CAAC;AAC7C,MAAM,OAAO,GAAG,mEAAmE,CAAC;AACpF,MAAM,IAAI,GAAG,QAAQ,GAAG,YAAY,GAAG,GAAG,GAAG,OAAO,GAAG,KAAK,CAAC;AAC7D,MAAM,UAAU,GAAG,IAAI,MAAM,CAAC,UAAU,GAAG,IAAI,GAAG,IAAI,CAAC,CAAC;AACxD,MAAM,QAAQ,GAAG,IAAI,MAAM,CAAC,IAAI,GAAG,IAAI,GAAG,OAAO,GAAG,IAAI,GAAG,IAAI,CAAC,CAAC;AACjE,MAAM,SAAS,GAAG,iBAAiB,CAAC;AACpC,MAAM,YAAY,GAAG,iDAAiD,CAAC;AAEvE,UAAU;AACV,MAAM,OAAO,GAA8C;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