New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

typal

Package Overview
Dependencies
Maintainers
1
Versions
88
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

typal - npm Package Compare versions

Comparing version 1.13.1 to 1.14.0

4

build/lib/closure/index.js

@@ -26,3 +26,3 @@ const Type = require('../Type'); // eslint-disable-line

*/
const closureJoinTypes = (imports, types, noSuppress) => {
const closureJoinTypes = (imports, types, noSuppress) => {
const tblocks = types.map((t) => {

@@ -48,3 +48,3 @@ const m = t.toTypedef(true, noSuppress)

*/
const externsJoinTypes = (types, namespace, currentNamespaces, skipNsDecl = false) => {
const externsJoinTypes = (types, namespace, currentNamespaces, skipNsDecl = false) => {
const tblocks = types.map((t) => {

@@ -51,0 +51,0 @@ return t.toExtern()

const { Transform } = require('stream');
let createRegexTransformStream = require('restream'); if (createRegexTransformStream && createRegexTransformStream.__esModule) createRegexTransformStream = createRegexTransformStream.default;
let mismatch = require('mismatch'); if (mismatch && mismatch.__esModule) mismatch = mismatch.default;
const mismatch = require('mismatch');
const { collect } = require('catchment');

@@ -15,3 +15,3 @@ const { getNameWithDefault } = require('./');

const propExtractRe = /^ \* @prop {(.+?)} (\[)?(.+?)(?:=(["'])?(.+?)\4)?(?:])?(?: (.+?))?(?: Default `(.+?)`.)?$/gm
const propExtractRe = /^ \* @prop {(.+?)} (\[)?(.+?)(?:=(["'])?(.+?)\4)?(?:])?(?: (.+?))?(?: Default `(.+?)`.)?$/gm
const propRe = / \* @prop(?:erty)? .+\n/

@@ -131,3 +131,3 @@ const keys = ['type', 'opt', 'name', 'quote', 'defaultValue', 'description', 'Default']

*/
async function extractTypedef(input) {
async function extractTypedef(input) {
const ts = createRegexTransformStream(typedefRe)

@@ -134,0 +134,0 @@ const ps = new Properties()

/**
* The representation of a parsed import.
*/
class Import {
class Import {
constructor() {

@@ -6,0 +6,0 @@ /**

@@ -19,3 +19,3 @@ /**

*/
const getNameWithDefault = (name, defaultValue, type, parentParam) => {
const getNameWithDefault = (name, defaultValue, type, parentParam) => {
if (!name) throw new Error('The name of the property is not given')

@@ -36,3 +36,3 @@ const n = `${parentParam ? `${parentParam}.` : ''}${name}`

const getPropType = ({ number, string, boolean, type }) => {
const getPropType = ({ number, string, boolean, type }) => {
if (string) return 'string'

@@ -46,3 +46,3 @@ if (number) return 'number'

// update this to match what documentary has
const getLink = (title, prefix = '') => {
const getLink = (title, prefix = '') => {
const l = title

@@ -63,3 +63,3 @@ .replace(/<\/?code>/g, '')

*/
const makeOptional = (type) => {
const makeOptional = (type) => {
let t

@@ -71,3 +71,3 @@ if (/[^\w\d._]/.test(type)) t = `(${type})`

const makeBlock = (s) => {
const makeBlock = (s) => {
return `/**

@@ -79,3 +79,3 @@ ${s}

const addSuppress = (line) => {
const addSuppress = (line) => {
const m = ` * @suppress {nonStandardJsDocs}

@@ -91,3 +91,3 @@ ${line}`

*/
const getExternDeclaration = (namespace, name, constr) => {
const getExternDeclaration = (namespace, name, constr) => {
const ns = namespace ? `${namespace}.` : ''

@@ -94,0 +94,0 @@ const v = namespace ? '' : 'var '

@@ -5,3 +5,3 @@ const { Replaceable } = require('restream');

class JSTypal extends Replaceable {
class JSTypal extends Replaceable {
constructor(rules, conf = {}) {

@@ -8,0 +8,0 @@ super(rules)

@@ -1,2 +0,2 @@

let extractTags = require('rexml'); if (extractTags && extractTags.__esModule) extractTags = extractTags.default;
const extractTags = require('rexml');
const Type = require('./Type');

@@ -3,0 +3,0 @@ const Import = require('./Import');

@@ -6,3 +6,3 @@ const { getPropType, getNameWithDefault, makeOptional } = require('./');

*/
class Property {
class Property {
constructor() {

@@ -9,0 +9,0 @@ /**

@@ -1,3 +0,3 @@

let extractTags = require('rexml'); if (extractTags && extractTags.__esModule) extractTags = extractTags.default;
let parse = require('@typedefs/parser'); if (parse && parse.__esModule) parse = parse.default;
const extractTags = require('rexml');
const parse = require('@typedefs/parser');
const Property = require('./Property');

@@ -9,3 +9,3 @@ const { getLink, addSuppress, makeBlock, getExternDeclaration, makeOptional } = require('./');

*/
class Type {
class Type {
constructor() {

@@ -147,3 +147,3 @@ /**

const d = this.description ? ` ${this.description}` : ''
const t = this.tag ? ` \`@${this.tag}\`` : ''
const t = this.tag ? ` \`@${this.tag}\`` : ''
return `${t}${d}`

@@ -290,3 +290,3 @@ }

*/
const getLinks = (allTypes, type) => {
const getLinks = (allTypes, type) => {
let parsed

@@ -393,3 +393,3 @@ try {

*/
const makePropsTable = (props = [], allTypes = []) => {
const makePropsTable = (props = [], allTypes = []) => {
if (!props.length) return ''

@@ -396,0 +396,0 @@ const anyHaveDefault = props.some(({ hasDefault }) => hasDefault)

@@ -1,2 +0,2 @@

let parser = require('@typedefs/parser'); if (parser && parser.__esModule) parser = parser.default;
const parser = require('@typedefs/parser');
const JSTypal = require('../JSTypal'); // eslint-disable-line

@@ -8,3 +8,3 @@

const jsDocRe = /( *) \* @param {(.+?)} (\[)?([^\s\]]+)\]?(?: .+)?((?:\n(?: +)\* @param {(?:.+?)} \[?\4\]?.*)*)/gm
const jsDocRe = /( *) \* @param {(.+?)} (\[)?([^\s\]]+)\]?(?: .+)?((?:\n(?: +)\* @param {(?:.+?)} \[?\4\]?.*)*)/gm

@@ -11,0 +11,0 @@ /**

@@ -12,3 +12,3 @@ let read = require('@wrote/read'); if (read && read.__esModule) read = read.default;

*/
const typedefJsRe = /^\/\*\*? (documentary|typal) (.+?) \*\/\n(?:([^\n][\s\S]+?\n))?$/mg
const typedefJsRe = /^\/\*\*? (documentary|typal) (.+?) \*\/\n(?:([^\n][\s\S]+?\n))?$/mg

@@ -15,0 +15,0 @@ /**

@@ -0,1 +1,8 @@

## 20 June 2019
### [1.14.0](https://github.com/artdecocode/typal/compare/v1.13.1...v1.14.0)
- [deps] Upgrade `rexml` to 2.0.0 (major).
- [fix] Print `@` (Fullwidth Commercial At) instead of `@` in JSDoc tags (e.g., `@interface`) for _TypeScript_ [3.5](https://github.com/microsoft/TypeScript/issues/31993).
## 15 May 2019

@@ -2,0 +9,0 @@

@@ -25,3 +25,3 @@ #!/usr/bin/env node

return {value:c, argv:[...a.slice(0, b), ...a.slice(d + 1)]};
}, ba = a => {
}, aa = a => {
const b = [];

@@ -56,3 +56,3 @@ for (let c = 0; c < a.length; c++) {

[, , ...b] = b;
const c = ba(b);
const c = aa(b);
b = b.slice(c.length);

@@ -62,6 +62,6 @@ let d = !c.length;

var g = Object.assign({}, e);
e = e.j;
g = (delete g.j, g);
e = e.m;
g = (delete g.m, g);
if (0 == e.length && d) {
return Object.assign({}, {j:e}, g);
return Object.assign({}, {m:e}, g);
}

@@ -77,7 +77,7 @@ const h = a[f];

} catch (l) {
return Object.assign({}, {j:e}, g);
return Object.assign({}, {m:e}, g);
}
}
return void 0 === k ? Object.assign({}, {j:e}, g) : Object.assign({}, {j:e}, g, {[f]:k});
}, {j:b});
return void 0 === k ? Object.assign({}, {m:e}, g) : Object.assign({}, {m:e}, g, {[f]:k});
}, {m:b});
}(v), z = y.source, A = y.output, da = y.closure, ea = y.externs, fa = y.types, ha = y.migrate, ia = y.help, ja = y.version;

@@ -166,11 +166,11 @@ function ka(a = {usage:{}}) {

b = (delete c.binary, delete c.rs, c);
const {K:f = H(!0), proxyError:g} = a || {}, h = (k, l) => f(l);
const {M:f = H(!0), proxyError:g} = a || {}, h = (k, l) => f(l);
super(b);
this.a = [];
this.I = new Promise((k, l) => {
this.b = [];
this.K = new Promise((k, l) => {
this.on("finish", () => {
let m;
d ? m = Buffer.concat(this.a) : m = this.a.join("");
d ? m = Buffer.concat(this.b) : m = this.b.join("");
k(m);
this.a = [];
this.b = [];
});

@@ -191,7 +191,7 @@ this.once("error", m => {

_write(a, b, c) {
this.a.push(a);
this.b.push(a);
c();
}
get g() {
return this.I;
get i() {
return this.K;
}

@@ -201,3 +201,3 @@ }

var b = void 0 === b ? {} : b;
({g:a} = new wa(Object.assign({}, {rs:a}, b, {K:H(!0)})));
({i:a} = new wa(Object.assign({}, {rs:a}, b, {M:H(!0)})));
return await a;

@@ -298,3 +298,3 @@ };

return `${a}=${b}`;
}, Aa = ({number:a, N:b, boolean:c, type:d}) => b ? "string" : a ? "number" : c ? "boolean" : d ? d : "*", R = a => `${/[^\w\d._]/.test(a) ? `(${a})` : a}|undefined`, Ba = a => `/**
}, Aa = ({number:a, P:b, boolean:c, type:d}) => b ? "string" : a ? "number" : c ? "boolean" : d ? d : "*", R = a => `${/[^\w\d._]/.test(a) ? `(${a})` : a}|undefined`, Ba = a => `/**
${a}

@@ -308,35 +308,30 @@ */

};
const U = new RegExp(`(${/[A-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEF\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7B9\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{10300}-\u{1031F}\u{1032D}-\u{10340}\u{10342}-\u{10349}\u{10350}-\u{10375}\u{10380}-\u{1039D}\u{103A0}-\u{103C3}\u{103C8}-\u{103CF}\u{10400}-\u{1049D}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10860}-\u{10876}\u{10880}-\u{1089E}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{10900}-\u{10915}\u{10920}-\u{10939}\u{10980}-\u{109B7}\u{109BE}\u{109BF}\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A60}-\u{10A7C}\u{10A80}-\u{10A9C}\u{10AC0}-\u{10AC7}\u{10AC9}-\u{10AE4}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B60}-\u{10B72}\u{10B80}-\u{10B91}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10D00}-\u{10D23}\u{10F00}-\u{10F1C}\u{10F27}\u{10F30}-\u{10F45}\u{11003}-\u{11037}\u{11083}-\u{110AF}\u{110D0}-\u{110E8}\u{11103}-\u{11126}\u{11144}\u{11150}-\u{11172}\u{11176}\u{11183}-\u{111B2}\u{111C1}-\u{111C4}\u{111DA}\u{111DC}\u{11200}-\u{11211}\u{11213}-\u{1122B}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A8}\u{112B0}-\u{112DE}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133D}\u{11350}\u{1135D}-\u{11361}\u{11400}-\u{11434}\u{11447}-\u{1144A}\u{11480}-\u{114AF}\u{114C4}\u{114C5}\u{114C7}\u{11580}-\u{115AE}\u{115D8}-\u{115DB}\u{11600}-\u{1162F}\u{11644}\u{11680}-\u{116AA}\u{11700}-\u{1171A}\u{11800}-\u{1182B}\u{118A0}-\u{118DF}\u{118FF}\u{11A00}\u{11A0B}-\u{11A32}\u{11A3A}\u{11A50}\u{11A5C}-\u{11A83}\u{11A86}-\u{11A89}\u{11A9D}\u{11AC0}-\u{11AF8}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C2E}\u{11C40}\u{11C72}-\u{11C8F}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D30}\u{11D46}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D89}\u{11D98}\u{11EE0}-\u{11EF2}\u{12000}-\u{12399}\u{12480}-\u{12543}\u{13000}-\u{1342E}\u{14400}-\u{14646}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16AD0}-\u{16AED}\u{16B00}-\u{16B2F}\u{16B40}-\u{16B43}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16E40}-\u{16E7F}\u{16F00}-\u{16F44}\u{16F50}\u{16F93}-\u{16F9F}\u{16FE0}\u{16FE1}\u{17000}-\u{187F1}\u{18800}-\u{18AF2}\u{1B000}-\u{1B11E}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D6C0}\u{1D6C2}-\u{1D6DA}\u{1D6DC}-\u{1D6FA}\u{1D6FC}-\u{1D714}\u{1D716}-\u{1D734}\u{1D736}-\u{1D74E}\u{1D750}-\u{1D76E}\u{1D770}-\u{1D788}\u{1D78A}-\u{1D7A8}\u{1D7AA}-\u{1D7C2}\u{1D7C4}-\u{1D7CB}\u{1E800}-\u{1E8C4}\u{1E900}-\u{1E943}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}\u{20000}-\u{2A6D6}\u{2A700}-\u{2B734}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2F800}-\u{2FA1D}][\x2D\.0-9A-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEF\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7B9\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{10300}-\u{1031F}\u{1032D}-\u{10340}\u{10342}-\u{10349}\u{10350}-\u{10375}\u{10380}-\u{1039D}\u{103A0}-\u{103C3}\u{103C8}-\u{103CF}\u{10400}-\u{1049D}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10860}-\u{10876}\u{10880}-\u{1089E}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{10900}-\u{10915}\u{10920}-\u{10939}\u{10980}-\u{109B7}\u{109BE}\u{109BF}\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A60}-\u{10A7C}\u{10A80}-\u{10A9C}\u{10AC0}-\u{10AC7}\u{10AC9}-\u{10AE4}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B60}-\u{10B72}\u{10B80}-\u{10B91}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10D00}-\u{10D23}\u{10F00}-\u{10F1C}\u{10F27}\u{10F30}-\u{10F45}\u{11003}-\u{11037}\u{11083}-\u{110AF}\u{110D0}-\u{110E8}\u{11103}-\u{11126}\u{11144}\u{11150}-\u{11172}\u{11176}\u{11183}-\u{111B2}\u{111C1}-\u{111C4}\u{111DA}\u{111DC}\u{11200}-\u{11211}\u{11213}-\u{1122B}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A8}\u{112B0}-\u{112DE}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133D}\u{11350}\u{1135D}-\u{11361}\u{11400}-\u{11434}\u{11447}-\u{1144A}\u{11480}-\u{114AF}\u{114C4}\u{114C5}\u{114C7}\u{11580}-\u{115AE}\u{115D8}-\u{115DB}\u{11600}-\u{1162F}\u{11644}\u{11680}-\u{116AA}\u{11700}-\u{1171A}\u{11800}-\u{1182B}\u{118A0}-\u{118DF}\u{118FF}\u{11A00}\u{11A0B}-\u{11A32}\u{11A3A}\u{11A50}\u{11A5C}-\u{11A83}\u{11A86}-\u{11A89}\u{11A9D}\u{11AC0}-\u{11AF8}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C2E}\u{11C40}\u{11C72}-\u{11C8F}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D30}\u{11D46}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D89}\u{11D98}\u{11EE0}-\u{11EF2}\u{12000}-\u{12399}\u{12480}-\u{12543}\u{13000}-\u{1342E}\u{14400}-\u{14646}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16AD0}-\u{16AED}\u{16B00}-\u{16B2F}\u{16B40}-\u{16B43}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16E40}-\u{16E7F}\u{16F00}-\u{16F44}\u{16F50}\u{16F93}-\u{16F9F}\u{16FE0}\u{16FE1}\u{17000}-\u{187F1}\u{18800}-\u{18AF2}\u{1B000}-\u{1B11E}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D6C0}\u{1D6C2}-\u{1D6DA}\u{1D6DC}-\u{1D6FA}\u{1D6FC}-\u{1D714}\u{1D716}-\u{1D734}\u{1D736}-\u{1D74E}\u{1D750}-\u{1D76E}\u{1D770}-\u{1D788}\u{1D78A}-\u{1D7A8}\u{1D7AA}-\u{1D7C2}\u{1D7C4}-\u{1D7CB}\u{1E800}-\u{1E8C4}\u{1E900}-\u{1E943}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}\u{20000}-\u{2A6D6}\u{2A700}-\u{2B734}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2F800}-\u{2FA1D}]*/u.source})(?:\\s*=\\s*${/(?:"([\s\S]*?)"|'([\s\S]*?)')/.source})?`,
"u"), Ca = new RegExp(`\\s*((?:${U.source.replace(/\(\[/g, "(?:[")}\\s*)*)`, "u");
const Da = a => {
const b = {};
a.replace(new RegExp(U.source, "gu"), (c, d, e, f) => {
c = f || e;
c = void 0 === c ? !0 : c;
b[d] = "true" == c ? !0 : "false" == c ? !1 : /^\d+$/.test(c) ? parseInt(c, 10) : c;
function U(a, b, c) {
const d = [];
b.replace(a, (e, ...f) => {
e = f.slice(0, f.length - 2).reduce((g, h, k) => {
k = c[k];
if (!k || void 0 === h) {
return g;
}
g[k] = h;
return g;
}, {});
d.push(e);
});
return d;
}
;const V = new RegExp(`${/([^\s>=/]+)/.source}(?:\\s*=\\s*${/(?:"([\s\S]*?)"|'([\s\S]*?)')/.source})?`, "g"), Ca = new RegExp(`\\s*((?:${V.source}\\s*)*)`);
const W = (a, b) => U(new RegExp(`<${a}${Ca.source}?(?:${/\s*\/>/.source}|${(new RegExp(`>([\\s\\S]+?)?</${a}>`)).source})`, "g"), b, ["a", "v", "v1", "v2", "c"]).map(({a:c = "", c:d = ""}) => {
c = c.replace(/\/$/, "").trim();
c = Da(c);
return {content:d, B:c};
}), Da = a => U(V, a, ["key", "val", "def", "f"]).reduce((b, {key:c, val:d}) => {
if (!d) {
return b[c] = !0, b;
}
b[c] = "true" == d ? !0 : "false" == d ? !1 : /^\d+$/.test(d) ? parseInt(d, 10) : d;
return b;
};
const Ea = (a, b) => {
a = a.exec(b);
if (!a) {
return a;
}
[, ...a] = a;
return a;
}, V = (a, b) => {
a = new RegExp(`<${a}${Ca.source}?(?:${/\s*\/>/.source}|${(new RegExp(`>([\\s\\S]+?)?</${a}>`)).source})`, "gu");
const c = [];
for (var d; d = Ea(a, b);) {
if (!d.length) {
continue;
}
const [e = "", f = ""] = d;
d = e.replace(/\/$/, "").trim();
d = {w:Da(d), content:f};
c.push(d);
}
return c;
};
const Fa = a => a.split(/([!?=*(),:.<>{}|\s+])/g).filter(b => /\S/.test(b)).map(b => {
}, {});
const Ea = a => a.split(/([!?=*(),:.<>{}|\s+])/g).filter(b => /\S/.test(b)).map(b => {
switch(b) {

@@ -358,3 +353,3 @@ case "function":

});
function Ga(a) {
function Fa(a) {
let b = 0;

@@ -507,7 +502,7 @@ const c = (d, e) => {

}
;function Ha(a) {
a = Fa(a);
return Ga(a);
;function Ga(a) {
a = Ea(a);
return Fa(a);
}
;function Ia(a, b, {name:c, string:d, "boolean":e, opt:f, number:g, type:h, "default":k, closure:l}) {
;function Ha(a, b, {name:c, string:d, "boolean":e, opt:f, number:g, type:h, "default":k, closure:l}) {
if (!c) {

@@ -518,11 +513,11 @@ throw Error("Property does not have a name.");

b && (a.description = b.trim());
a.type = Aa({number:g, N:d, boolean:e, type:h});
l ? a.b = l : a.b = a.type;
void 0 !== k && (a.a = !0);
a.a && (a.default = k);
if (f || a.a) {
a.type = Aa({number:g, P:d, boolean:e, type:h});
l ? a.f = l : a.f = a.type;
void 0 !== k && (a.b = !0);
a.b && (a.default = k);
if (f || a.b) {
a.optional = !0;
}
}
function W(a, b = null, c = !1) {
function X(a, b = null, c = !1) {
if (!a.name) {

@@ -532,22 +527,22 @@ throw Error("Property does not have a name. Has it been constructed using fromXML?");

b = Q(a.name, a.default, a.type, b);
return `{${c ? a.b : a.type}} ${a.optional ? `[${b}]` : b}${`${a.description ? ` ${a.description}` : ""}${a.a ? ` Default \`${a.default}\`.` : ""}`}`;
return `{${c ? a.f : a.type}} ${a.optional ? `[${b}]` : b}${`${a.description ? ` ${a.description}` : ""}${a.b ? ` Default \`${a.default}\`.` : ""}`}`;
}
function Ja(a, b = !1) {
return ` * @prop ${W(a, null, b)}`;
function Ia(a, b = !1) {
return ` * @prop ${X(a, null, b)}`;
}
class Ka {
class Ja {
constructor() {
this.description = this.name = null;
this.type = "*";
this.b = "";
this.a = !1;
this.f = "";
this.b = !1;
this.default = null;
this.optional = !1;
}
F(a, b = "", c = !1) {
a = W(this, a, c);
H(a, b = "", c = !1) {
a = X(this, a, c);
return `${b} * @param ${a}`;
}
}
;function X(a, b, {name:c, type:d, desc:e, noToc:f, spread:g, noExpand:h, "import":k, link:l, closure:m, constructor:n, "extends":p, "interface":q, record:r}, t) {
;function Ka(a, b, {name:c, type:d, desc:e, noToc:f, spread:g, noExpand:h, "import":k, link:l, closure:m, constructor:n, "extends":p, "interface":q, record:r}, t) {
if (!c) {

@@ -558,19 +553,19 @@ throw Error("Type does not have a name.");

d && (a.type = d);
m ? a.b = m : a.b = a.type;
m ? a.f = m : a.f = a.type;
e && (a.description = e.trim());
a.H = !!f;
a.G = !!g;
a.v = !!h;
a.J = !!f;
a.I = !!g;
a.A = !!h;
a.import = !!k;
l && (a.link = l);
!0 === n && (a.isConstructor = n);
!0 === q && (a.l = q);
!0 === r && (a.m = r);
!0 === q && (a.o = q);
!0 === r && (a.s = r);
p && (a.extends = p);
b && (a.f = V("prop", b).map(({content:w, w:x}) => {
const aa = new Ka;
Ia(aa, w, x);
return aa;
b && (a.h = W("prop", b).map(({content:w, B:x}) => {
const ba = new Ja;
Ha(ba, w, x);
return ba;
}));
t && (a.i = t);
t && (a.l = t);
}

@@ -581,3 +576,3 @@ function La(a) {

a.extends && b.push(` * @extends {${a.extends}}`);
b.push(` * @${a.L}`);
b.push(` * @${a.N}`);
b = `/**

@@ -587,4 +582,4 @@ ${b.join("\n")}

`;
b += T(a.i, a.name, void 0);
const c = a.f.map(d => {
b += T(a.l, a.name, void 0);
const c = a.h.map(d => {
var e = [];

@@ -596,3 +591,3 @@ if (d.description) {

}
e.push(` * @type {${d.optional ? R(d.b) : d.b}}`);
e.push(` * @type {${d.optional ? R(d.f) : d.f}}`);
e = e.join("\n");

@@ -603,3 +598,3 @@ e = `/**

`;
return e += T(`${a.c}.prototype`, d.name);
return e += T(`${a.g}.prototype`, d.name);
});

@@ -610,7 +605,7 @@ return [b, ...c].join("\n");

const c = `${a.extends ? "$" : ""}${a.name}`;
return b ? `${a.o}${c}` : c;
return b ? `${a.u}${c}` : c;
}
function Na(a, b, c) {
var d = ` * @typedef {${(b ? a.b : a.type) || "Object"}}${` ${Ma(a, b)}${a.g}`}`;
a = a.f ? a.f.map(e => Ja(e, b)) : [];
var d = ` * @typedef {${(b ? a.f : a.type) || "Object"}}${` ${Ma(a, b)}${a.i}`}`;
a = a.h ? a.h.map(e => Ia(e, b)) : [];
d = [d, ...a].join("\n");

@@ -625,4 +620,4 @@ b && !c && (d = S(d));

const d = !!a.extends, e = Na(a, b, c), f = [];
if (a.i && b) {
let g = ` * @typedef {${a.c}} ${a.name}${a.g}`;
if (a.l && b) {
let g = ` * @typedef {${a.g}} ${a.name}${a.i}`;
b && !c && (g = S(g));

@@ -635,3 +630,3 @@ g = `/**

}
d && (a = ` * @typedef {${a.extends} & ${Ma(a, b)}} ${b ? a.c : a.name}${a.g}`, b && !c && (a = S(a)), a = `/**
d && (a = ` * @typedef {${a.extends} & ${Ma(a, b)}} ${b ? a.g : a.name}${a.i}`, b && !c && (a = S(a)), a = `/**
${a}

@@ -646,16 +641,16 @@ */

this.name = "";
this.link = this.v = this.import = this.G = this.H = this.description = this.b = this.type = null;
this.f = [];
this.i = null;
this.m = this.l = this.isConstructor = !1;
this.link = this.A = this.import = this.I = this.J = this.description = this.f = this.type = null;
this.h = [];
this.l = null;
this.s = this.o = this.isConstructor = !1;
this.extends = null;
}
get M() {
return this.isConstructor || this.l || this.m;
get O() {
return this.isConstructor || this.o || this.s;
}
get g() {
return `${this.a ? ` \`@${this.a}\`` : ""}${this.description ? ` ${this.description}` : ""}`;
get i() {
return `${this.b ? ` \`\uff20${this.b}\`` : ""}${this.description ? ` ${this.description}` : ""}`;
}
get L() {
const a = this.a;
get N() {
const a = this.b;
if (!a) {

@@ -666,18 +661,18 @@ throw Error("Unknown prototype type (not constructor or interface).");

}
get a() {
return this.isConstructor ? "constructor" : this.l ? "interface" : this.m ? "record" : "";
get b() {
return this.isConstructor ? "constructor" : this.o ? "interface" : this.s ? "record" : "";
}
get o() {
return this.i ? `${this.i}.` : "";
get u() {
return this.l ? `${this.l}.` : "";
}
get c() {
return `${this.o}${this.name}`;
get g() {
return `${this.u}${this.name}`;
}
F(a, b, c, d, e = !1) {
H(a, b, c, d, e = !1) {
var f = "";
!0 === d ? f = "?" : !1 === d && (f = "!");
d = this.description ? ` ${this.description}` : "";
const g = this.G ? Pa(this.f) : e ? this.c : this.name;
const g = this.I ? Pa(this.h) : e ? this.g : this.name;
b = `${c || ""} * @param {${f}${g}} ${b ? `[${a}]` : a}${d}`;
f = this.f && !this.v ? this.f.map(h => h.F(a, c, e)) : [];
f = this.h && !this.A ? this.h.map(h => h.H(a, c, e)) : [];
return [b, ...f].join("\n");

@@ -687,3 +682,3 @@ }

const Pa = (a = [], b = !1) => `{ ${a.map(c => {
const d = b ? c.b : c.type;
const d = b ? c.f : c.type;
let e = c.name, f = d;

@@ -723,11 +718,11 @@ c.optional && !b ? e = `${c.name}?` : c.optional && b && (f = `(${R(d)})`);

super(b);
this.l = (Array.isArray(a) ? a : [a]).filter(Qa);
this.a = !1;
this.v = b;
this.o = (Array.isArray(a) ? a : [a]).filter(Qa);
this.b = !1;
this.A = b;
}
async replace(a, b) {
const c = new Ta(this.l, this.v);
const c = new Ta(this.o, this.A);
b && Object.assign(c, b);
a = await Sa(c, a);
c.a && this.brake();
c.b && this.brake();
b && Object.keys(b).forEach(d => {

@@ -739,8 +734,8 @@ b[d] = c[d];

brake() {
this.a = !0;
this.b = !0;
}
async reduce(a) {
return await this.l.reduce(async(b, {re:c, replacement:d}) => {
return await this.o.reduce(async(b, {re:c, replacement:d}) => {
b = await b;
if (this.a) {
if (this.b) {
return b;

@@ -756,3 +751,3 @@ }

try {
if (this.a) {
if (this.b) {
return e.length ? e.push(Promise.resolve(h)) : h;

@@ -806,21 +801,21 @@ }

a.from = c;
a.B = d;
a.D = d;
a.link = e;
a.o = f || a.from;
a.u = f || a.from;
}
function Xa(a, b = !0) {
return ` * @typedef {import('${a.from}').${a.name}} ${b ? a.c : a.name}`;
return ` * @typedef {import('${a.from}').${a.name}} ${b ? a.g : a.name}`;
}
class Ya {
constructor() {
this.from = this.name = this.o = "";
this.link = this.B = null;
this.from = this.name = this.u = "";
this.link = this.D = null;
}
get c() {
return `${this.o}.${this.name}`;
get g() {
return `${this.u}.${this.name}`;
}
}
;function Za(a, b) {
b = b.reduce((c, d) => Object.assign({}, c, {[d.c]:d}), {});
a.A = Object.assign({}, a.A, b);
b = b.reduce((c, d) => Object.assign({}, c, {[d.g]:d}), {});
a.C = Object.assign({}, a.C, b);
}

@@ -831,3 +826,3 @@ class $a extends Ta {

super(a);
this.A = {};
this.C = {};
this.on("types", c => {

@@ -837,7 +832,7 @@ Za(this, c);

this.on("namespace", c => {
this.g.includes(c) || this.g.push(c);
this.i.includes(c) || this.i.push(c);
});
this.m = b;
this.g = [];
this.h = console.log;
this.s = b;
this.i = [];
this.j = console.log;
this.file = null;

@@ -849,30 +844,30 @@ this.lines = [];

}
static get a() {
static get b() {
return Ya;
}
get types() {
return this.A;
return this.C;
}
}
;const ab = a => {
a = V("types", a);
a = W("types", a);
if (!a.length) {
throw Error("XML file should contain root types element.");
}
const [{content:b, w:{namespace:c, ns:d = c}}] = a, e = void 0 == d ? void 0 : d;
a = V("type", b).map(({content:h, w:k}) => {
const [{content:b, B:{namespace:c, ns:d = c}}] = a, e = void 0 == d ? void 0 : d;
a = W("type", b).map(({content:h, B:k}) => {
const l = new Y;
X(l, h, k, e);
Ka(l, h, k, e);
return l;
});
const f = V("import", b).map(({w:h}) => {
const f = W("import", b).map(({B:h}) => {
const k = new Ya;
Wa(k, h);
return k;
}), g = f.map(({name:h, from:k, B:l, link:m, o:n}) => {
}), g = f.map(({name:h, from:k, D:l, link:m, u:n}) => {
const p = new Y;
X(p, "", {name:h, type:`import('${k}').${h}`, H:!0, import:!0, B:l, link:m}, void 0 == n ? void 0 : n);
Ka(p, "", {name:h, type:`import('${k}').${h}`, J:!0, import:!0, D:l, link:m}, void 0 == n ? void 0 : n);
return p;
});
return {i:d, types:a, imports:f, O:g};
return {l:d, types:a, imports:f, R:g};
};

@@ -893,7 +888,7 @@ const bb = (a, b, c) => {

let f;
e.b ? f = ` * @typedef {${e.b}}` : e.M || (f = ` * @typedef {${Pa(e.f, !0)}}`);
e.f ? f = ` * @typedef {${e.f}}` : e.O || (f = ` * @typedef {${Pa(e.h, !0)}}`);
f ? (e.description && (f = ` * ${e.description}\n${f}`), f = `/**
${f}
*/
`, e = f += T(e.i, e.name)) : e = La(e);
`, e = f += T(e.l, e.name)) : e = La(e);
}

@@ -910,18 +905,18 @@ return e;

l = l ? l.replace("ignore:", "").split(",") : [];
let {u:m, C:n} = this.m;
let {w:m, F:n} = this.s;
f && (m = !0);
g && (n = !0);
try {
this.h("Detected type marker: %s", c);
this.j("Detected type marker: %s", c);
const p = await J(d);
let {i:q = null, types:r, imports:t} = ab(p);
r = r.filter(({c:x}) => l.includes(x) ? !1 : !0);
t = t.filter(({c:x}) => l.includes(x) ? !1 : !0);
let {l:q = null, types:r, imports:t} = ab(p);
r = r.filter(({g:x}) => l.includes(x) ? !1 : !0);
t = t.filter(({g:x}) => l.includes(x) ? !1 : !0);
this.emit("types", r);
this.emit("types", t);
let w;
m ? w = bb(t, r, h) : n ? (w = cb(r, q, this.g, k) + "\n", q && this.emit("namespace", q)) : w = db(t, r);
m ? w = bb(t, r, h) : n ? (w = cb(r, q, this.i, k) + "\n", q && this.emit("namespace", q)) : w = db(t, r);
return `/* ${b} ${c} */\n${w}`;
} catch (p) {
return this.h("(%s) Could not process typedef-js: %s", c, p.message), a;
return this.j("(%s) Could not process typedef-js: %s", c, p.message), a;
}

@@ -936,3 +931,3 @@ }}, db = (a, b) => {

function gb(a, b, c, d, e, f, g) {
const {u:h} = this.m;
const {w:h} = this.s;
let k;

@@ -947,22 +942,22 @@ f = () => {

}
m = {line:m, J:b.length + 11};
m = {line:m, L:b.length + 11};
}
const {line:n, J:p} = m;
this.h("%s:%s:%s", this.file, n, p);
const {line:n, L:p} = m;
this.j("%s:%s:%s", this.file, n, p);
}
};
try {
k = Ha(c);
k = Ga(c);
} catch (m) {
return this.h("Error while parsing the type %s", c), this.h(process.env.DEBUG ? m.stack : m.message), f(), a;
return this.j("Error while parsing the type %s", c), this.j(process.env.DEBUG ? m.stack : m.message), f(), a;
}
if (!k) {
return this.h("Could not parse the type %s", c), f(), a;
return this.j("Could not parse the type %s", c), f(), a;
}
const l = Object.values(this.types).map(({name:m, c:n}) => h ? n : m);
if (!Z(k, l, this.h, c, f)) {
const l = Object.values(this.types).map(({name:m, g:n}) => h ? n : m);
if (!Z(k, l, this.j, c, f)) {
return a;
}
c = Object.values(this.types).find(({name:m, c:n}) => h ? n == k.name : m == k.name);
return c instanceof $a.a ? a : c.F(e, d, b, k.nullable, h);
c = Object.values(this.types).find(({name:m, g:n}) => h ? n == k.name : m == k.name);
return c instanceof $a.b ? a : c.H(e, d, b, k.nullable, h);
}

@@ -994,3 +989,3 @@ const Z = (a, b, c, d, e) => {

var jb = async() => {
const {u:a = !1, C:b = !1, D:c, types:d} = {u:da, C:ea, D:A, types:fa};
const {w:a = !1, F:b = !1, G:c, types:d} = {w:da, F:ea, G:A, types:fa};
await Promise.all(z.map(async e => {

@@ -1012,6 +1007,6 @@ var f = await M(B, e);

var h = await J(g);
const k = new $a([eb, hb], {u:b, C:c});
const k = new $a([eb, hb], {w:b, F:c});
f.forEach(l => k.emit("types", l));
k.file = g;
k.h = console.error;
k.j = console.error;
k.lines = h.split("\n");

@@ -1023,23 +1018,7 @@ k.end(h);

};
function kb(a) {
var b = lb;
const c = [];
a.replace(mb, (d, ...e) => {
d = e.slice(0, e.length - 2).reduce((f, g, h) => {
h = b[h];
if (!h || void 0 === g) {
return f;
}
f[h] = g;
return f;
}, {});
c.push(d);
});
return c;
}
;const nb = a => {
const kb = a => {
let b;
"true" == a ? b = !0 : "false" == a ? b = !1 : /^\d+$/.test(a) && (b = parseInt(a, 10));
return void 0 !== b ? b : a;
}, mb = /^ \* @prop {(.+?)} (\[)?(.+?)(?:=(["'])?(.+?)\4)?(?:])?(?: (.+?))?(?: Default `(.+?)`.)?$/gm, lb = "type opt name quote defaultValue description Default".split(" "), Va = new RegExp(`^ \\* @typedef {(.+?)} (.+?)(?: (.+))?\\n((?:${/ \* @prop(?:erty)? .+\n/.source})*)`, "gm"), ob = (a, b, c, d) => {
}, lb = /^ \* @prop {(.+?)} (\[)?(.+?)(?:=(["'])?(.+?)\4)?(?:])?(?: (.+?))?(?: Default `(.+?)`.)?$/gm, mb = "type opt name quote defaultValue description Default".split(" "), Va = new RegExp(`^ \\* @typedef {(.+?)} (.+?)(?: (.+))?\\n((?:${/ \* @prop(?:erty)? .+\n/.source})*)`, "gm"), nb = (a, b, c, d) => {
d = d.length;

@@ -1050,3 +1029,3 @@ a = a && "Object" != a ? ` type="${a}"` : "";

};
class pb extends C {
class ob extends C {
constructor() {

@@ -1056,4 +1035,4 @@ super({writableObjectMode:!0});

_transform(a, b, c) {
var {type:d, name:e, description:f, f:g} = a;
a = d && d.startsWith("import") ? qb(d, e) : ob(d, e, f, g);
var {type:d, name:e, description:f, h:g} = a;
a = d && d.startsWith("import") ? pb(d, e) : nb(d, e, f, g);
this.push(a);

@@ -1076,3 +1055,3 @@ g.forEach(h => {

}
const qb = (a, b) => {
const pb = (a, b) => {
const c = /import\((['"])(.+?)\1\)/.exec(a);

@@ -1085,3 +1064,3 @@ if (!c) {

};
class rb extends C {
class qb extends C {
constructor() {

@@ -1092,3 +1071,3 @@ super({objectMode:!0});

var [, d, e, f, g] = a;
a = kb(g).map(h => {
a = U(lb, g, mb).map(h => {
var k = Object.assign({}, h), l = h.defaultValue;

@@ -1100,14 +1079,14 @@ const m = h.Default;

k = (delete k.defaultValue, delete k.Default, delete k.opt, delete k.name, delete k.type, k);
n = Object.assign({}, k, {name:p, type:h}, l ? {defaultValue:nb(l)} : {}, m ? {s:nb(m)} : {}, n ? {optional:!0} : {});
n = Object.assign({}, k, {name:p, type:h}, l ? {defaultValue:kb(l)} : {}, m ? {v:kb(m)} : {}, n ? {optional:!0} : {});
if (l || m) {
l ? l !== m && void 0 !== n.s && (l = Q(p, m, h), console.error("%s[%s] does not match Default `%s`.", e, l, n.s)) : (l = Q(p, m, h), console.error("%s[%s] got from Default.", e, l)), n.default = "defaultValue" in n ? n.defaultValue : n.s, delete n.defaultValue, delete n.s;
l ? l !== m && void 0 !== n.v && (l = Q(p, m, h), console.error("%s[%s] does not match Default `%s`.", e, l, n.v)) : (l = Q(p, m, h), console.error("%s[%s] got from Default.", e, l)), n.default = "defaultValue" in n ? n.defaultValue : n.v, delete n.defaultValue, delete n.v;
}
return n;
});
this.push({type:d, name:e, description:f, f:a});
this.push({type:d, name:e, description:f, h:a});
c();
}
}
async function sb(a) {
const b = Ua(), c = new rb, d = new pb;
async function rb(a) {
const b = Ua(), c = new qb, d = new ob;
b.pipe(c).pipe(d);

@@ -1131,7 +1110,7 @@ b.end(a);

}
;var tb = async() => {
const {D:a} = {D:A};
;var sb = async() => {
const {G:a} = {G:A};
await Promise.all(z.map(async b => {
b = await J(b);
b = await sb(b);
b = await rb(b);
a ? await K(a, b) : console.log(b);

@@ -1149,3 +1128,3 @@ }));

try {
return ha ? await tb() : await jb();
return ha ? await sb() : await jb();
} catch (a) {

@@ -1152,0 +1131,0 @@ process.env.DEBUG ? console.log(a.stack) : console.log(a.message);

{
"name": "typal",
"version": "1.13.1",
"version": "1.14.0",
"description": "Organises TypeDefs By Placing Them Into Types.Xml File To Be Embedded Into Source Code Compatible With VSCode And Google Closure Compiler, Generates Externs And Allows To Place Documentation In README Markdown.",

@@ -71,6 +71,6 @@ "main": "build/index.js",

"@zoroaster/mask": "^2.2.0",
"alamode": "^2.2.0",
"alamode": "^2.3.4",
"argufy": "^1.7.0",
"catchment": "^3.3.0",
"documentary": "^1.27.2",
"documentary": "^1.27.3",
"erotic": "^2.1.1",

@@ -89,4 +89,4 @@ "eslint-config-artdeco": "1.0.1",

"mismatch": "^1.2.0",
"rexml": "^1.4.0"
"rexml": "^2.0.2"
}
}

@@ -146,3 +146,3 @@ import extractTags from 'rexml'

const d = this.description ? ` ${this.description}` : ''
const t = this.tag ? ` \`@${this.tag}\`` : ''
const t = this.tag ? ` \`@${this.tag}\`` : ''
return `${t}${d}`

@@ -149,0 +149,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc