@qubit-ltd/json 1.2.4 → 1.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/json.mjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"json.mjs","sources":["../node_modules/json-custom-numbers/parse.mjs","../node_modules/json-custom-numbers/stringify.mjs","../src/utils/is-integer.js","../src/utils/extract-significant-digits.js","../src/utils/is-number.js","../src/utils/is-safe-number.js","../src/utils/get-unsafe-reason.js","../src/utils/lossless-number.js","../src/parse-number.js","../src/format-number.js","../src/collection-replacer.js","../src/json.js","../src/utils/is-bigint.js","../src/utils/to-safe-number-or-throw.js","../src/index.js"],"sourcesContent":["var T=Object.defineProperty;var C=(t,a)=>T(t,\"name\",{value:a,configurable:!0});/**\n * https://github.com/jawj/json-custom-numbers\n * @copyright Copyright (c) 2023 George MacKerron\n * @license MIT\n * \n * This file implements a non-recursive JSON parser that's intended to\n * precisely match native `JSON.parse` behaviour but also allow for custom\n * number parsing.\n */const v=/[^\"\\\\\\u0000-\\u001f]*/y,D=/-?(0|[1-9][0-9]*)([.][0-9]+)?([eE][-+]?[0-9]+)?|true|false|null/y,\nJ=/[ \\n\\t\\r]*$/y,X=/^.{0,32}\\n[ \\t]/,h=/[ \\n\\t\\r]*/y,j=`........................\\\n..........\"............./.............................................\\\\......\\b..\\\n..\\f........\n....\\r..\t`.split(\".\"),x=C(()=>new Uint32Array(103),\"hlArr\"),k=x(),m=x(),w=x(),$=x();\nlet i=0;for(;i<48;i++)k[i]=m[i]=w[i]=$[i]=65536;for(;i<58;i++)k[i]=(m[i]=(w[i]=($[i]=\ni-48)<<4)<<4)<<4;for(;i<65;i++)k[i]=m[i]=w[i]=$[i]=65536;for(;i<71;i++)k[i]=(m[i]=\n(w[i]=($[i]=i-55)<<4)<<4)<<4;for(;i<97;i++)k[i]=m[i]=w[i]=$[i]=65536;for(;i<103;i++)\nk[i]=(m[i]=(w[i]=($[i]=i-87)<<4)<<4)<<4;function O(t,a=\"\"){if(!(t>=0))return\"end\\\n of JSON input\";if(t>31&&t<127)return`'${a}${String.fromCharCode(t)}'`;if(t===10)\nreturn\"\\\\n\";if(t===9)return\"\\\\t\";const p=t.toString(16),y=\"0000\".slice(p.length)+\np;return(t>31?`'${a}${String.fromCharCode(t)}' or `:\"\")+`\\\\u${y}`}C(O,\"chDesc\");\nfunction R(t,a){const p=Object.keys(a),y=p.length;for(let d=0;d<y;d++){const n=p[d],\ne=t.call(a,n,a[n]);e!==void 0?a[n]=e:delete a[n]}}C(R,\"revive\");function q(t,a,p){\nconst y=p===!0?\" in array\":p===!1?\" in object\":\"\",d=t.slice(0,a),n=d.match(/[^\\n]{0,69}$/)[0],\ne=n.length<d.length?\"...\"+n:n,o=a-(d.length-e.length),u=t.slice(a),r=u.match(/[^\\n]{0,5}/)[0],\nc=r.length<u.length?r+\"...\":r,A=e+c,I=\" \".repeat(o<1?0:o-1)+\"^\";return`${y}\nAt position ${a} in JSON:\n${A}\n${I}`}C(q,\"errContext\");const N={maxDepth:1/0};function K(t,a,p,y){var U;typeof t!=\n\"string\"&&(t=String(t)),typeof a!=\"function\"&&(a=void 0);const d=y===void 0?N.maxDepth:\ntypeof y==\"number\"?y:(U=y.maxDepth)!=null?U:N.maxDepth;let n=0,e,o,u,r,c;function A(l){\nthrow new SyntaxError(l+q(t,n,u))}C(A,\"err\");function I(){A(`JSON structure too \\\ndeeply nested (current max depth: ${d})`)}C(I,\"tooDeep\");function b(l){A(`Unexpe\\\ncted ${O(e)}, expecting ${l}`)}C(b,\"expected\");function E(){const l=n-1;if(D.lastIndex=\nl,D.test(t)!==!0&&b(\"JSON value\"),n=D.lastIndex,e<102){const g=t.slice(l,n);return p?\np.call(o,r,g):+g}return e===110?null:e===116}C(E,\"word\");function S(){let l=\"\";e:\nfor(;;){v.lastIndex=n,v.test(t);const f=v.lastIndex;for(f>n&&(l+=t.slice(n,f),n=\nf),e=t.charCodeAt(n++);;){switch(e){case 34:return l;case 92:if(e=t.charCodeAt(n++),\ne===117){const s=k[t.charCodeAt(n++)]+m[t.charCodeAt(n++)]+w[t.charCodeAt(n++)]+\n$[t.charCodeAt(n++)];if(s<65536){l+=String.fromCharCode(s);break}A(\"Invalid \\\\uXX\\\nXX escape in string\")}const g=j[e];if(g!==\"\"&&g!==void 0){l+=g;break}A(`Invalid \\\nescape sequence: ${O(e,\"\\\\\")} in string`);default:e>=0||A(\"Unterminated string\"),\nA(`Invalid unescaped ${O(e)} in string`)}if(e=t.charCodeAt(n),e!==92&&e!==34)continue e;\nn++}}}C(S,\"string\");e:{do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===\n13||e===9));switch(e){case 123:d===0&&I(),o={},r=void 0,u=!1;break;case 91:d===0&&\nI(),o=[],r=0,u=!0;break;case 34:c=S();break e;default:c=E();break e}const l=d+d-\n2,f=[],g=X.test(t);let s=0;t:for(;;)if(u===!0)for(;;){g===!0&&s>2&&(h.lastIndex=\nn,h.test(t),n=h.lastIndex);do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||\ne===13||e===9));if(e===93){if(a!==void 0&&R(a,o),c=o,s===0)break e;if(o=f[--s],r=\nf[--s],u=typeof r==\"number\",u===!0){o[r++]=c;continue}else{o[r]=c;continue t}}if(r!==\n0){e!==44&&b(\"',' or ']' after value\"),g===!0&&s>2&&(h.lastIndex=n,h.test(t),n=h.\nlastIndex);do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===13||e===9))}\nswitch(e){case 34:o[r++]=S();continue;case 123:s===l&&I(),f[s++]=r,f[s++]=o,o={},\nr=void 0,u=!1;continue t;case 91:s===l&&I(),f[s++]=r,f[s++]=o,o=[],r=0;continue;default:\no[r++]=E()}}else for(;;){g===!0&&s>2&&(h.lastIndex=n,h.test(t),n=h.lastIndex);do\ne=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===13||e===9));if(e===125){if(a!==\nvoid 0&&R(a,o),c=o,s===0)break e;if(o=f[--s],r=f[--s],u=typeof r==\"number\",u===!0){\no[r++]=c;continue t}else{o[r]=c;continue}}if(r!==void 0){e!==44&&b(\"',' or '}' a\\\nfter value\"),g===!0&&s>2&&(h.lastIndex=n,h.test(t),n=h.lastIndex);do e=t.charCodeAt(\nn++);while(e<=32&&(e===32||e===10||e===13||e===9))}e!==34&&b(\"'}' or double-quot\\\ned key\"),r=S();do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===13||e===\n9));e!==58&&b(\"':' after key\");do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===\n10||e===13||e===9));switch(e){case 34:o[r]=S();continue;case 123:s===l&&I(),f[s++]=\nr,f[s++]=o,o={},r=void 0;continue;case 91:s===l&&I(),f[s++]=r,f[s++]=o,o=[],r=0,\nu=!0;continue t;default:o[r]=E()}}}return J.lastIndex=n,J.test(t)===!1&&A(\"Unexp\\\nected data after end of JSON input\"),a!==void 0&&(c={\"\":c},R(a,c),c=c[\"\"]),c}C(K,\n\"parse\");export{K as parse};\n","var E=Object.defineProperty;var T=Object.getOwnPropertySymbols;var F=Object.prototype.hasOwnProperty,V=Object.prototype.propertyIsEnumerable;var D=(t,e,i)=>e in t?E(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):\nt[e]=i,u=(t,e)=>{for(var i in e||(e={}))F.call(e,i)&&D(t,i,e[i]);if(T)for(var i of T(\ne))V.call(e,i)&&D(t,i,e[i]);return t};var K=(t,e)=>E(t,\"name\",{value:e,configurable:!0});/**\n * https://github.com/jawj/json-custom-numbers\n * @copyright Copyright (c) 2023 George MacKerron\n * @license MIT\n * \n * This file implements a non-recursive JSON stringifier that's intended to\n * precisely match native `JSON.stringify` behaviour but also allow for custom\n * stringifying of numbers.\n */const x=/[\"\\\\\\u0000-\\u001f]/,q=Object.prototype.hasOwnProperty,z={maxDepth:5e4,\nskipToJSON:!1};function C(t,e,i,j,g={}){typeof g==\"number\"&&(g={maxDepth:g}),g=u(\nu({},z),g);const{maxDepth:J,skipToJSON:L}=g;let O,S;e!==void 0&&(typeof e==\"func\\\ntion\"?O=e:Array.isArray(e)&&(S=e.map(l=>String(l)))),i!==void 0&&(i=typeof i==\"s\\\ntring\"?i.slice(0,10):typeof i==\"number\"?\" \".slice(0,i):void 0);const P=J*\n(i===void 0?5:6);let r,s={\"\":t},d=0,c=[\"\"],h=!1,k=1,f=[],n=0,y=\"\",b=`\n`,o,p=new Set([]);do{if(d===k){p.delete(s),i!==void 0&&(b=f[--n],y+=b),y+=c===void 0?\n\"]\":\"}\",k=f[--n],h=f[--n],c=f[--n],d=f[--n],s=f[--n];continue}let l,w;c===void 0?\n(r=String(d),t=s[d]):(r=c[d],t=s[r]);let a=typeof t;if(L===!1&&t&&a===\"object\"&&\ntypeof t.toJSON==\"function\"&&(t=t.toJSON(r),a=typeof t),O!==void 0&&(t=O.call(s,\nr,t),a=typeof t),j===void 0||(o=j(r,t,a))===void 0)switch(a){case\"string\":o=x.test(\nt)?JSON.stringify(t):'\"'+t+'\"';break;case\"number\":o=isFinite(t)?String(t):\"null\";\nbreak;case\"boolean\":o=t===!0?\"true\":\"false\";break;case\"object\":if(t===null){o=\"n\\\null\";break}if(Array.isArray(t)){const m=t.length;m===0?o=\"[]\":(o=\"[\",l=void 0,w=\nm);break}const N=S===void 0?Object.keys(t):S.filter(m=>q.call(t,m)),A=N.length;A===\n0?o=\"{}\":(o=\"{\",l=N,w=A);break;case\"bigint\":throw new TypeError(\"Do not know how\\\n to serialize a BigInt: please provide a custom serializer function\");default:o=\nvoid 0}if(c===void 0?(d>0&&(y+=\",\"),i!==void 0&&(y+=b),y+=o===void 0?\"null\":o):o!==\nvoid 0&&(h?y+=\",\":h=!0,n>0&&(y+=i===void 0?(x.test(r)?JSON.stringify(r):'\"'+r+'\"')+\n\":\":b+(x.test(r)?JSON.stringify(r):'\"'+r+'\"')+\": \"),y+=o),d++,w!==void 0){if(f[n++]=\ns,f[n++]=d,f[n++]=c,f[n++]=h,f[n++]=k,i!==void 0&&(f[n++]=b,b+=i),s=t,d=0,c=l,h=\n!1,k=w,n>P)throw new RangeError(`Maximum nesting depth exceeded (current maximum\\\n is ${J})`);if(p.has(s))throw new TypeError(\"Cannot stringify circular structure\");\np.add(s)}}while(n!==0);return y||void 0}K(C,\"stringify\");export{C as stringify};\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\n/**\n * A regular expression for testing whether a string represents an integer.\n *\n * @type {RegExp}\n * @private\n */\nconst INTEGER_REGEX = /^[+-]?\\d+$/;\n\n/**\n * Test whether a string represents an integer.\n *\n * @param value\n * The string to test.\n * @return {boolean}\n * true if the string contains an integer; false otherwise.\n */\nfunction isInteger(value) {\n return INTEGER_REGEX.test(value);\n}\n\nexport default isInteger;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\nconst EXPONENTIAL_PART_REGEX = /[eE][+-]?\\d+$/;\nconst LEADING_MINUS_AND_ZEROS_REGEX = /^-?(0*)?/;\nconst DOT_REGEX = /\\./;\nconst TRAILING_ZEROS_REGEX = /0+$/;\n\n/**\n * Get the significant digits of a number.\n *\n * For example:\n * - '2.34' returns '234'\n * - '-77' returns '77'\n * - '0.003400' returns '34'\n * - '120.5e+30' returns '1205'\n *\n * @param {string} value\n * The string representation of the number.\n * @return {string}\n * The significant digits of the number.\n * @private\n */\nfunction extractSignificantDigits(value) {\n return value\n .replace(EXPONENTIAL_PART_REGEX, '') // from \"-0.250e+30\" to \"-0.250\"\n .replace(DOT_REGEX, '') // from \"-0.250\" to \"-0250\"\n .replace(TRAILING_ZEROS_REGEX, '') // from \"-0250\" to \"-025\"\n .replace(LEADING_MINUS_AND_ZEROS_REGEX, ''); // from \"-025\" to \"25\"\n}\n\nexport default extractSignificantDigits;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\n/**\n * A regular expression for testing whether a string represents a number.\n *\n * @type {RegExp}\n * @see http://stackoverflow.com/questions/13340717/json-numbers-regular-expression\n * @private\n */\nconst NUMBER_REGEX = /^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?(?:[eE][+-]?\\d+)?$/;\n\n/**\n * Test whether a string represents a number\n *\n * @param {string} value\n * The string to test.\n * @return {boolean}\n * true if the string contains a number; false otherwise.\n */\nfunction isNumber(value) {\n return NUMBER_REGEX.test(value);\n}\n\nexport default isNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isInteger from './is-integer';\nimport extractSignificantDigits from './extract-significant-digits';\nimport isNumber from './is-number';\n\nconst DEFAULT_APPROX = false;\nconst DEFAULT_REQUIRED_DIGITS = 14;\n\n/**\n * Test whether a string can be safely represented with a number without\n * information loss.\n *\n * When the argument `approx` is true, floating point numbers that lose a few\n * digits but are still approximately equal in value are considered safe too.\n * Integer numbers must still be exactly equal.\n *\n * @param {string} value\n * The string to test.\n * @param {object} options\n * The options of the test. It may contain the following properties:\n * - `approx: boolean`: indicates whether to consider approximately equal\n * floating point numbers as safe. Default is `false`.\n * - `requiredDigits: number`: the number of significant digits required for\n * a floating point number to be considered approximately equal. Default\n * is `14`.\n * @return {boolean}\n * true if the string can be safely represented with a number; false\n * otherwise.\n */\nfunction isSafeNumber(value, options = undefined) {\n // handle the edge cases\n if (!isNumber(value) || value === '' || value === 'NaN') {\n return false;\n }\n\n const num = parseFloat(value);\n const str = String(num);\n if (value === str) {\n return true;\n }\n const v = extractSignificantDigits(value);\n const s = extractSignificantDigits(str);\n if (v === s) {\n return true;\n }\n\n // use the default options\n const approx = options?.approx ?? DEFAULT_APPROX;\n if (!approx) {\n return false;\n }\n\n // A value is approximately equal when:\n // 1. it is a floating point number, not an integer\n // 2. both v and s have at least requiredDigits digits\n // 3. the first requiredDigits digits are equal\n const requiredDigits = options?.requiredDigits ?? DEFAULT_REQUIRED_DIGITS;\n\n // check if the value is an integer\n const isIntegerVal = isInteger(value);\n if (isIntegerVal) {\n return true; // when the input is an integer and approx=true, return true\n }\n\n // check if s has at least requiredDigits digits\n const sLengthOk = s.length >= requiredDigits;\n if (!sLengthOk) {\n return false;\n }\n\n // check if v has at least requiredDigits digits\n const vLengthOk = v.length >= requiredDigits;\n\n if (vLengthOk) {\n // check if the first requiredDigits digits are equal\n const vPrefix = v.substring(0, requiredDigits);\n const sPrefix = s.substring(0, requiredDigits);\n return vPrefix === sPrefix;\n } else {\n // if v length is not enough, return true\n return true;\n }\n}\n\nexport {\n DEFAULT_APPROX,\n DEFAULT_REQUIRED_DIGITS,\n isSafeNumber,\n};\n\nexport default isSafeNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isInteger from './is-integer';\nimport extractSignificantDigits from './extract-significant-digits';\n\n/**\n * When the provided value is an unsafe number, describe what the reason is\n * - `'overflow'`\n * - `'underflow'`\n * - `'truncate_integer'`\n * - `'truncate_float'`\n * - `'none'` (when the value is safe)\n *\n * @param {string} value\n * The string represents a number to test.\n * @return {string}\n * The reason why the value is unsafe. Returns `'none'` when the value is safe.\n */\nfunction getUnsafeReason(value) {\n const num = parseFloat(value);\n const str = String(num);\n if (value === str) {\n return 'none';\n }\n const v = extractSignificantDigits(value);\n const s = extractSignificantDigits(str);\n if (v === s) {\n return 'none';\n }\n if (isInteger(value)) {\n return 'truncate_integer';\n }\n if (!Number.isFinite(num)) {\n return 'overflow';\n }\n if (num === 0) {\n return 'underflow';\n }\n return 'truncate_float';\n}\n\nexport default getUnsafeReason;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isNumber from './is-number';\nimport getUnsafeReason from './get-unsafe-reason';\n\n/**\n * The class of lossless numbers, which stores its numeric value as string.\n */\nclass LosslessNumber {\n /**\n * The string representation of the number.\n *\n * @type {string}\n */\n value = '';\n\n /**\n * Whether the value is a lossless number.\n *\n * @type {boolean}\n */\n isLosslessNumber = true;\n\n /**\n * Constructs a new instance of `LosslessNumber`.\n *\n * @param {string} value\n * The string representation of the number.\n */\n constructor(value) {\n if (!isNumber(value)) {\n throw new Error(`Invalid number (value: \"${value}\")`);\n }\n this.value = value;\n }\n\n /**\n * Get the value of the LosslessNumber as number or bigint.\n *\n * - a number is returned for safe numbers and decimal values that only lose\n * some insignificant digits;\n * - a bigint is returned for big integer numbers;\n * - an Error is thrown for values that will overflow or underflow;\n *\n * Note that you can implement your own strategy for conversion by just\n * getting the value as string via `.toString()`, and using util functions\n * like `isInteger`, `isSafeNumber`, `getUnsafeReason`, and `toSafeNumberOrThrow`\n * to convert it to a numeric value.\n *\n * @return {number|bigint}\n * the numeric value of the LosslessNumber, as number or bigint.\n */\n valueOf() {\n const unsafeReason = getUnsafeReason(this.value);\n switch (unsafeReason) {\n case 'none':\n return parseFloat(this.value);\n case 'truncate_float':\n return parseFloat(this.value);\n case 'truncate_integer':\n return BigInt(this.value);\n case 'overflow':\n case 'underflow':\n throw new Error('Cannot safely CONVERT TO NUMBER: '\n + `the value '${this.value}' would ${unsafeReason} `\n + `and become ${parseFloat(this.value)}`);\n default:\n throw new Error('Unknown unsafe reason');\n }\n }\n\n /**\n * Get the value of this `LosslessNumber` as string.\n *\n * @return {string}\n * the string representation of this `LosslessNumber`.\n */\n toString() {\n return this.value;\n }\n\n // Note: we do NOT implement a .toJSON() method, and you should not implement\n // or use that, it cannot safely turn the numeric value in the string into\n // stringified JSON since it has to be parsed into a number first.\n}\n\nexport default LosslessNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isInteger from './utils/is-integer';\nimport isSafeNumber from './utils/is-safe-number';\nimport LosslessNumber from './utils/lossless-number';\n\n/**\n * A custom function to parse a number from a string, which supports lossless\n * number parsing.\n *\n * @param {string} key\n * The key of the property.\n * @param {string} value\n * The value of the property.\n * @return {any}\n * The parsed value.\n * @private\n */\nfunction parseNumber(key, value) {\n // if (isBigInt(value)) {\n // return BigInt(value.slice(0, -1));\n // }\n if (isSafeNumber(value, { approx: false })) {\n return parseFloat(value);\n }\n if (isInteger(value)) {\n return BigInt(value);\n }\n return new LosslessNumber(value);\n}\n\nexport default parseNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport LosslessNumber from './utils/lossless-number';\n\n/**\n * Formats a number value.\n *\n * @param {string} key\n * The key of the property.\n * @param {string} value\n * The value of the property.\n * @param {string} type\n * The type of the value.\n * @return {undefined|string}\n * The formatted value. If the value is not a number, then return undefined.\n * @private\n */\nfunction formatNumber(key, value, type) {\n switch (type) {\n case 'bigint':\n return value.toString();\n case 'object':\n // if (value instanceof Set) {\n // return Array.from(value);\n // }\n // if (value instanceof Map) {\n // return Array.from(value);\n // }\n if (value instanceof LosslessNumber) {\n return value.toString();\n }\n return undefined;\n default:\n return undefined;\n }\n}\n\nexport default formatNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\n/**\n * A JSON replacer which serialize collections as arrays.\n *\n * @param {string} key\n * The key of the property.\n * @param {any} value\n * The value of the property.\n * @param {undefined|null|function} fallbackReplacer\n * The fallback replacer.\n * @return {any}\n * The serialized value.\n * @private\n */\nfunction collectionReplacer(key, value, fallbackReplacer) {\n if (value instanceof Set) {\n return Array.from(value);\n }\n if (value instanceof Map) {\n return Array.from(value);\n }\n if (fallbackReplacer) {\n return fallbackReplacer(key, value);\n }\n return value;\n}\n\nexport default collectionReplacer;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport { parse as parseJson, stringify as stringifyJson } from 'json-custom-numbers';\nimport parseNumber from './parse-number';\nimport formatNumber from './format-number';\nimport collectionReplacer from './collection-replacer';\n\n/**\n * A customized class for JSON object which supports lossless number parsing and\n * stringifying.\n *\n * The instance of this class is similar to the standard `JSON` object, but with\n * enhanced capabilities for handling large integers, floating-point numbers, and\n * collections like `Set` and `Map`.\n *\n * Features:\n * - Lossless parsing of large integers (converted to BigInt)\n * - Lossless parsing of large floating-point numbers (converted to LosslessNumber)\n * - Support for Set and Map serialization/deserialization\n * - Compatible with standard JSON.parse/stringify API\n *\n * @example\n * // Parse large integers without precision loss\n * const obj = json.parse('{\"bigInt\": 9007199254740993}');\n * console.log(typeof obj.bigInt); // 'bigint'\n *\n * // Parse large floats without precision loss\n * const obj2 = json.parse('{\"bigFloat\": 2.3e+500}');\n * console.log(obj2.bigFloat instanceof LosslessNumber); // true\n *\n * // Stringify collections\n * const obj3 = { set: new Set([1, 2, 3]), map: new Map([['a', 1]]) };\n * console.log(json.stringify(obj3)); // '{\"set\":[1,2,3],\"map\":[[\"a\",1]]}'\n *\n * @author Haixing Hu\n */\nclass Json {\n /**\n * The string tag used by Object.prototype.toString() to identify this object.\n *\n * This property makes instances of the Json class return '[object JSON]' when\n * converted to string via Object.prototype.toString.call(), providing better\n * debugging and inspection experience.\n *\n * @type {string}\n * @readonly\n * @example\n * const json = new Json();\n * console.log(Object.prototype.toString.call(json)); // '[object JSON]'\n */\n [Symbol.toStringTag] = 'JSON';\n\n /**\n * Parses the specified JSON string and returns the resulting object.\n *\n * This method works like the standard JSON.parse(), but with enhanced number\n * handling:\n * - Safe numbers are parsed as regular JavaScript numbers\n * - Large integers are parsed as BigInt\n * - Large floating-point numbers are parsed as LosslessNumber instances\n *\n * @param {string} text\n * The JSON string to be parsed. Must be a valid JSON string.\n * @param {Function} [reviver]\n * Optional function to transform the results. This function is called for\n * each member of the object. If a member contains nested objects, the nested\n * objects are transformed before the parent object is.\n * @returns {*}\n * The resulting JavaScript value/object. The type depends on the JSON content.\n * @throws {SyntaxError}\n * Thrown if the text is not valid JSON.\n * @example\n * // Parse regular JSON\n * const obj = json.parse('{\"name\": \"John\", \"age\": 30}');\n *\n * // Parse with large integer (becomes BigInt)\n * const obj2 = json.parse('{\"id\": 9007199254740993}');\n * console.log(typeof obj2.id); // 'bigint'\n *\n * // Parse with reviver function\n * const obj3 = json.parse('{\"date\": \"2023-01-01\"}', (key, value) => {\n * if (key === 'date') return new Date(value);\n * return value;\n * });\n */\n parse(text, reviver) {\n if (typeof text !== 'string') {\n throw new TypeError('JSON.parse requires a string argument');\n }\n if ((reviver != null) && (typeof reviver !== 'function')) {\n throw new TypeError('JSON.parse reviver argument must be a function');\n }\n try {\n return parseJson(text, reviver, parseNumber);\n } catch (error) {\n // Re-throw with more context if needed\n if (error instanceof SyntaxError) {\n throw new SyntaxError(`Invalid JSON: ${error.message}`);\n }\n throw error;\n }\n }\n\n /**\n * Stringifies the specified value and returns the resulting JSON string.\n *\n * This method works like the standard JSON.stringify(), but with enhanced\n * support for:\n * - BigInt values (converted to number strings)\n * - LosslessNumber instances (converted to their string representation)\n * - Set instances (converted to arrays)\n * - Map instances (converted to arrays of key-value pairs)\n *\n * @param {*} value\n * The value to be stringified. Can be any JavaScript value.\n * @param {Function|Array} [replacer]\n * Optional function or array to transform the results. If a function, it's\n * called for each member of the object. If an array, it specifies the\n * properties to be included in the result.\n * @param {string|number} [space]\n * Optional string or number to control spacing in the output. If a number,\n * it indicates the number of space characters to use as white space. If a\n * string, it's used as white space.\n * @returns {string|undefined}\n * The resulting JSON string, or undefined if the value cannot be serialized.\n * @example\n * // Stringify regular object\n * const str = json.stringify({name: \"John\", age: 30});\n *\n * // Stringify with BigInt (preserved as number)\n * const str2 = json.stringify({id: 9007199254740993n});\n * // Result: '{\"id\":9007199254740993}'\n *\n * // Stringify with collections\n * const str3 = json.stringify({\n * set: new Set([1, 2, 3]),\n * map: new Map([['a', 1], ['b', 2]])\n * });\n * // Result: '{\"set\":[1,2,3],\"map\":[[\"a\",1],[\"b\",2]]}'\n *\n * // Stringify with custom replacer\n * const str4 = json.stringify({a: 1, b: 2}, (key, value) => {\n * return key === 'a' ? undefined : value;\n * });\n * // Result: '{\"b\":2}'\n */\n stringify(value, replacer, space) {\n // Validate replacer parameter\n if ((replacer != null) && (typeof replacer !== 'function') && (!Array.isArray(replacer))) {\n throw new TypeError('JSON.stringify replacer argument must be a function or array');\n }\n // Validate space parameter\n if ((space != null) && (typeof space !== 'string') && (typeof space !== 'number')) {\n throw new TypeError('JSON.stringify space argument must be a string or number');\n }\n try {\n // Optimize: create combined replacer function only when needed\n const combinedReplacer = replacer\n ? (k, v) => collectionReplacer(k, v, replacer)\n : collectionReplacer;\n\n return stringifyJson(value, combinedReplacer, space, formatNumber);\n } catch (error) {\n // Handle circular reference and other stringify errors\n if ((error.message.includes('circular'))\n || (error.message.includes('Converting circular structure'))) {\n throw new TypeError('Converting circular structure to JSON');\n }\n throw error;\n }\n }\n}\n\n/**\n * A customized JSON object which supports lossless number parsing and stringifying.\n *\n * This object provides two methods: `parse` and `stringify`, which are the same as the\n * `JSON.parse` and `JSON.stringify` methods, except that they support lossless number\n * parsing and stringifying.\n *\n * Key differences from standard JSON:\n * - Large integers are preserved as BigInt instead of losing precision\n * - Large floating-point numbers are preserved as LosslessNumber instances\n * - Set and Map collections are automatically serialized as arrays\n * - Maintains full compatibility with standard JSON API\n *\n * @type {Json}\n * @example\n * import json from '@qubit-ltd/json';\n *\n * // Use exactly like standard JSON\n * const obj = json.parse('{\"value\": 9007199254740993}');\n * const str = json.stringify(obj);\n *\n * // Works with collections\n * const data = { items: new Set([1, 2, 3]) };\n * const serialized = json.stringify(data); // '{\"items\":[1,2,3]}'\n */\nconst json = new Json();\n\nexport default json;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n/**\n * A regular expression for testing whether a string represents a BigInt.\n *\n * @type {RegExp}\n * @private\n */\nconst BIG_INTEGER_REGEX = /^[+-]?\\d+n$/;\n\n/**\n * Test whether a string represents a BigInt.\n *\n * @param value\n * The string to test.\n * @return {boolean}\n * true if the string contains a BigInt; false otherwise.\n */\nfunction isBigInt(value) {\n return BIG_INTEGER_REGEX.test(value);\n}\n\nexport default isBigInt;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport getUnsafeReason from './get-unsafe-reason';\nimport { DEFAULT_APPROX } from './is-safe-number';\n\n/**\n * Convert a string into a number when it is safe to do so.\n * Throws an error otherwise, explaining the reason.\n *\n * @param {string} value\n * The string to convert into a number.\n * @param {object} options\n * The options for conversion.\n * @return {number}\n * The converted safe number.\n * @throws {Error}\n * When the value is not safe to convert.\n */\nexport function toSafeNumberOrThrow(value, options = undefined) {\n const number = parseFloat(value);\n const unsafeReason = getUnsafeReason(value);\n if (unsafeReason === 'none') {\n return number;\n }\n const approx = options?.approx ?? DEFAULT_APPROX;\n // when approx is true, we allow truncating float values\n if (approx && (unsafeReason === 'truncate_float')) {\n return number;\n }\n const unsafeReasonText = unsafeReason?.replace(/_/, ' ');\n throw new Error('Cannot safely convert to number: '\n + `the value '${value}' would ${unsafeReasonText} and become ${number}`);\n}\n\nexport default toSafeNumberOrThrow;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2024.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport Json from './json';\nimport LosslessNumber from './utils/lossless-number';\nimport isBigInt from './utils/is-bigint';\nimport isInteger from './utils/is-integer';\nimport isNumber from './utils/is-number';\nimport isSafeNumber from './utils/is-safe-number';\nimport getUnsafeReason from './utils/get-unsafe-reason';\nimport toSafeNumberOrThrow from './utils/to-safe-number-or-throw';\n\nexport {\n getUnsafeReason,\n isBigInt,\n isInteger,\n isNumber,\n isSafeNumber,\n Json,\n LosslessNumber,\n toSafeNumberOrThrow,\n};\n\nexport default Json;\n"],"names":["T","C","D","x","q","K","INTEGER_REGEX","isInteger","value","test","EXPONENTIAL_PART_REGEX","LEADING_MINUS_AND_ZEROS_REGEX","DOT_REGEX","TRAILING_ZEROS_REGEX","extractSignificantDigits","replace","NUMBER_REGEX","isNumber","DEFAULT_APPROX","DEFAULT_REQUIRED_DIGITS","isSafeNumber","_options$approx","_options$requiredDigi","options","arguments","length","undefined","num","parseFloat","str","String","v","s","approx","requiredDigits","isIntegerVal","sLengthOk","vLengthOk","vPrefix","substring","sPrefix","getUnsafeReason","Number","isFinite","LosslessNumber","_classCallCheck","_defineProperty","Error","concat","_createClass","key","valueOf","unsafeReason","BigInt","toString","parseNumber","formatNumber","type","collectionReplacer","fallbackReplacer","Set","Array","from","Map","Json","Symbol","toStringTag","parse","text","reviver","TypeError","parseJson","error","SyntaxError","message","stringify","replacer","space","isArray","combinedReplacer","k","stringifyJson","includes","json","BIG_INTEGER_REGEX","isBigInt","toSafeNumberOrThrow","number","unsafeReasonText"],"mappings":";;;;AAAA,IAAIA,GAAC,CAAC,MAAM,CAAC,cAAc,CAAC,IAAIC,GAAC,CAAC,CAAC,CAAC,C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ignoreList":[0,1]}
1
+ {"version":3,"file":"json.mjs","sources":["../node_modules/json-custom-numbers/parse.mjs","../node_modules/json-custom-numbers/stringify.mjs","../src/utils/is-integer.js","../src/utils/extract-significant-digits.js","../src/utils/is-number.js","../src/utils/is-safe-number.js","../src/utils/get-unsafe-reason.js","../src/utils/lossless-number.js","../src/parse-number.js","../src/format-number.js","../src/collection-replacer.js","../src/json.js","../src/utils/is-bigint.js","../src/utils/to-safe-number-or-throw.js","../src/index.js"],"sourcesContent":["var T=Object.defineProperty;var C=(t,a)=>T(t,\"name\",{value:a,configurable:!0});/**\n * https://github.com/jawj/json-custom-numbers\n * @copyright Copyright (c) 2023 George MacKerron\n * @license MIT\n * \n * This file implements a non-recursive JSON parser that's intended to\n * precisely match native `JSON.parse` behaviour but also allow for custom\n * number parsing.\n */const v=/[^\"\\\\\\u0000-\\u001f]*/y,D=/-?(0|[1-9][0-9]*)([.][0-9]+)?([eE][-+]?[0-9]+)?|true|false|null/y,\nJ=/[ \\n\\t\\r]*$/y,X=/^.{0,32}\\n[ \\t]/,h=/[ \\n\\t\\r]*/y,j=`........................\\\n..........\"............./.............................................\\\\......\\b..\\\n..\\f........\n....\\r..\t`.split(\".\"),x=C(()=>new Uint32Array(103),\"hlArr\"),k=x(),m=x(),w=x(),$=x();\nlet i=0;for(;i<48;i++)k[i]=m[i]=w[i]=$[i]=65536;for(;i<58;i++)k[i]=(m[i]=(w[i]=($[i]=\ni-48)<<4)<<4)<<4;for(;i<65;i++)k[i]=m[i]=w[i]=$[i]=65536;for(;i<71;i++)k[i]=(m[i]=\n(w[i]=($[i]=i-55)<<4)<<4)<<4;for(;i<97;i++)k[i]=m[i]=w[i]=$[i]=65536;for(;i<103;i++)\nk[i]=(m[i]=(w[i]=($[i]=i-87)<<4)<<4)<<4;function O(t,a=\"\"){if(!(t>=0))return\"end\\\n of JSON input\";if(t>31&&t<127)return`'${a}${String.fromCharCode(t)}'`;if(t===10)\nreturn\"\\\\n\";if(t===9)return\"\\\\t\";const p=t.toString(16),y=\"0000\".slice(p.length)+\np;return(t>31?`'${a}${String.fromCharCode(t)}' or `:\"\")+`\\\\u${y}`}C(O,\"chDesc\");\nfunction R(t,a){const p=Object.keys(a),y=p.length;for(let d=0;d<y;d++){const n=p[d],\ne=t.call(a,n,a[n]);e!==void 0?a[n]=e:delete a[n]}}C(R,\"revive\");function q(t,a,p){\nconst y=p===!0?\" in array\":p===!1?\" in object\":\"\",d=t.slice(0,a),n=d.match(/[^\\n]{0,69}$/)[0],\ne=n.length<d.length?\"...\"+n:n,o=a-(d.length-e.length),u=t.slice(a),r=u.match(/[^\\n]{0,5}/)[0],\nc=r.length<u.length?r+\"...\":r,A=e+c,I=\" \".repeat(o<1?0:o-1)+\"^\";return`${y}\nAt position ${a} in JSON:\n${A}\n${I}`}C(q,\"errContext\");const N={maxDepth:1/0};function K(t,a,p,y){var U;typeof t!=\n\"string\"&&(t=String(t)),typeof a!=\"function\"&&(a=void 0);const d=y===void 0?N.maxDepth:\ntypeof y==\"number\"?y:(U=y.maxDepth)!=null?U:N.maxDepth;let n=0,e,o,u,r,c;function A(l){\nthrow new SyntaxError(l+q(t,n,u))}C(A,\"err\");function I(){A(`JSON structure too \\\ndeeply nested (current max depth: ${d})`)}C(I,\"tooDeep\");function b(l){A(`Unexpe\\\ncted ${O(e)}, expecting ${l}`)}C(b,\"expected\");function E(){const l=n-1;if(D.lastIndex=\nl,D.test(t)!==!0&&b(\"JSON value\"),n=D.lastIndex,e<102){const g=t.slice(l,n);return p?\np.call(o,r,g):+g}return e===110?null:e===116}C(E,\"word\");function S(){let l=\"\";e:\nfor(;;){v.lastIndex=n,v.test(t);const f=v.lastIndex;for(f>n&&(l+=t.slice(n,f),n=\nf),e=t.charCodeAt(n++);;){switch(e){case 34:return l;case 92:if(e=t.charCodeAt(n++),\ne===117){const s=k[t.charCodeAt(n++)]+m[t.charCodeAt(n++)]+w[t.charCodeAt(n++)]+\n$[t.charCodeAt(n++)];if(s<65536){l+=String.fromCharCode(s);break}A(\"Invalid \\\\uXX\\\nXX escape in string\")}const g=j[e];if(g!==\"\"&&g!==void 0){l+=g;break}A(`Invalid \\\nescape sequence: ${O(e,\"\\\\\")} in string`);default:e>=0||A(\"Unterminated string\"),\nA(`Invalid unescaped ${O(e)} in string`)}if(e=t.charCodeAt(n),e!==92&&e!==34)continue e;\nn++}}}C(S,\"string\");e:{do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===\n13||e===9));switch(e){case 123:d===0&&I(),o={},r=void 0,u=!1;break;case 91:d===0&&\nI(),o=[],r=0,u=!0;break;case 34:c=S();break e;default:c=E();break e}const l=d+d-\n2,f=[],g=X.test(t);let s=0;t:for(;;)if(u===!0)for(;;){g===!0&&s>2&&(h.lastIndex=\nn,h.test(t),n=h.lastIndex);do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||\ne===13||e===9));if(e===93){if(a!==void 0&&R(a,o),c=o,s===0)break e;if(o=f[--s],r=\nf[--s],u=typeof r==\"number\",u===!0){o[r++]=c;continue}else{o[r]=c;continue t}}if(r!==\n0){e!==44&&b(\"',' or ']' after value\"),g===!0&&s>2&&(h.lastIndex=n,h.test(t),n=h.\nlastIndex);do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===13||e===9))}\nswitch(e){case 34:o[r++]=S();continue;case 123:s===l&&I(),f[s++]=r,f[s++]=o,o={},\nr=void 0,u=!1;continue t;case 91:s===l&&I(),f[s++]=r,f[s++]=o,o=[],r=0;continue;default:\no[r++]=E()}}else for(;;){g===!0&&s>2&&(h.lastIndex=n,h.test(t),n=h.lastIndex);do\ne=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===13||e===9));if(e===125){if(a!==\nvoid 0&&R(a,o),c=o,s===0)break e;if(o=f[--s],r=f[--s],u=typeof r==\"number\",u===!0){\no[r++]=c;continue t}else{o[r]=c;continue}}if(r!==void 0){e!==44&&b(\"',' or '}' a\\\nfter value\"),g===!0&&s>2&&(h.lastIndex=n,h.test(t),n=h.lastIndex);do e=t.charCodeAt(\nn++);while(e<=32&&(e===32||e===10||e===13||e===9))}e!==34&&b(\"'}' or double-quot\\\ned key\"),r=S();do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===10||e===13||e===\n9));e!==58&&b(\"':' after key\");do e=t.charCodeAt(n++);while(e<=32&&(e===32||e===\n10||e===13||e===9));switch(e){case 34:o[r]=S();continue;case 123:s===l&&I(),f[s++]=\nr,f[s++]=o,o={},r=void 0;continue;case 91:s===l&&I(),f[s++]=r,f[s++]=o,o=[],r=0,\nu=!0;continue t;default:o[r]=E()}}}return J.lastIndex=n,J.test(t)===!1&&A(\"Unexp\\\nected data after end of JSON input\"),a!==void 0&&(c={\"\":c},R(a,c),c=c[\"\"]),c}C(K,\n\"parse\");export{K as parse};\n","var E=Object.defineProperty;var T=Object.getOwnPropertySymbols;var F=Object.prototype.hasOwnProperty,V=Object.prototype.propertyIsEnumerable;var D=(t,e,i)=>e in t?E(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):\nt[e]=i,u=(t,e)=>{for(var i in e||(e={}))F.call(e,i)&&D(t,i,e[i]);if(T)for(var i of T(\ne))V.call(e,i)&&D(t,i,e[i]);return t};var K=(t,e)=>E(t,\"name\",{value:e,configurable:!0});/**\n * https://github.com/jawj/json-custom-numbers\n * @copyright Copyright (c) 2023 George MacKerron\n * @license MIT\n * \n * This file implements a non-recursive JSON stringifier that's intended to\n * precisely match native `JSON.stringify` behaviour but also allow for custom\n * stringifying of numbers.\n */const x=/[\"\\\\\\u0000-\\u001f]/,q=Object.prototype.hasOwnProperty,z={maxDepth:5e4,\nskipToJSON:!1};function C(t,e,i,j,g={}){typeof g==\"number\"&&(g={maxDepth:g}),g=u(\nu({},z),g);const{maxDepth:J,skipToJSON:L}=g;let O,S;e!==void 0&&(typeof e==\"func\\\ntion\"?O=e:Array.isArray(e)&&(S=e.map(l=>String(l)))),i!==void 0&&(i=typeof i==\"s\\\ntring\"?i.slice(0,10):typeof i==\"number\"?\" \".slice(0,i):void 0);const P=J*\n(i===void 0?5:6);let r,s={\"\":t},d=0,c=[\"\"],h=!1,k=1,f=[],n=0,y=\"\",b=`\n`,o,p=new Set([]);do{if(d===k){p.delete(s),i!==void 0&&(b=f[--n],y+=b),y+=c===void 0?\n\"]\":\"}\",k=f[--n],h=f[--n],c=f[--n],d=f[--n],s=f[--n];continue}let l,w;c===void 0?\n(r=String(d),t=s[d]):(r=c[d],t=s[r]);let a=typeof t;if(L===!1&&t&&a===\"object\"&&\ntypeof t.toJSON==\"function\"&&(t=t.toJSON(r),a=typeof t),O!==void 0&&(t=O.call(s,\nr,t),a=typeof t),j===void 0||(o=j(r,t,a))===void 0)switch(a){case\"string\":o=x.test(\nt)?JSON.stringify(t):'\"'+t+'\"';break;case\"number\":o=isFinite(t)?String(t):\"null\";\nbreak;case\"boolean\":o=t===!0?\"true\":\"false\";break;case\"object\":if(t===null){o=\"n\\\null\";break}if(Array.isArray(t)){const m=t.length;m===0?o=\"[]\":(o=\"[\",l=void 0,w=\nm);break}const N=S===void 0?Object.keys(t):S.filter(m=>q.call(t,m)),A=N.length;A===\n0?o=\"{}\":(o=\"{\",l=N,w=A);break;case\"bigint\":throw new TypeError(\"Do not know how\\\n to serialize a BigInt: please provide a custom serializer function\");default:o=\nvoid 0}if(c===void 0?(d>0&&(y+=\",\"),i!==void 0&&(y+=b),y+=o===void 0?\"null\":o):o!==\nvoid 0&&(h?y+=\",\":h=!0,n>0&&(y+=i===void 0?(x.test(r)?JSON.stringify(r):'\"'+r+'\"')+\n\":\":b+(x.test(r)?JSON.stringify(r):'\"'+r+'\"')+\": \"),y+=o),d++,w!==void 0){if(f[n++]=\ns,f[n++]=d,f[n++]=c,f[n++]=h,f[n++]=k,i!==void 0&&(f[n++]=b,b+=i),s=t,d=0,c=l,h=\n!1,k=w,n>P)throw new RangeError(`Maximum nesting depth exceeded (current maximum\\\n is ${J})`);if(p.has(s))throw new TypeError(\"Cannot stringify circular structure\");\np.add(s)}}while(n!==0);return y||void 0}K(C,\"stringify\");export{C as stringify};\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\n/**\n * A regular expression for testing whether a string represents an integer.\n *\n * @type {RegExp}\n * @private\n */\nconst INTEGER_REGEX = /^[+-]?\\d+$/;\n\n/**\n * Test whether a string represents an integer.\n *\n * @param value\n * The string to test.\n * @return {boolean}\n * true if the string contains an integer; false otherwise.\n */\nfunction isInteger(value) {\n if (typeof value !== 'string') {\n return false;\n }\n return INTEGER_REGEX.test(value);\n}\n\nexport default isInteger;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\nconst EXPONENTIAL_PART_REGEX = /[eE][+-]?\\d+$/;\nconst LEADING_MINUS_AND_ZEROS_REGEX = /^-?(0*)?/;\nconst DOT_REGEX = /\\./;\nconst TRAILING_ZEROS_REGEX = /0+$/;\n\n/**\n * Get the significant digits of a number.\n *\n * For example:\n * - '2.34' returns '234'\n * - '-77' returns '77'\n * - '0.003400' returns '34'\n * - '120.5e+30' returns '1205'\n *\n * @param {string} value\n * The string representation of the number.\n * @return {string}\n * The significant digits of the number.\n * @private\n */\nfunction extractSignificantDigits(value) {\n const result = value\n .replace(EXPONENTIAL_PART_REGEX, '') // from \"-0.250e+30\" to \"-0.250\"\n .replace(DOT_REGEX, '') // from \"-0.250\" to \"-0250\"\n .replace(TRAILING_ZEROS_REGEX, '') // from \"-0250\" to \"-025\"\n .replace(LEADING_MINUS_AND_ZEROS_REGEX, ''); // from \"-025\" to \"25\"\n return result;\n}\n\nexport default extractSignificantDigits;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\n/**\n * A regular expression for testing whether a string represents a number.\n *\n * @type {RegExp}\n * @see http://stackoverflow.com/questions/13340717/json-numbers-regular-expression\n * @private\n */\nconst NUMBER_REGEX = /^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?(?:[eE][+-]?\\d+)?$/;\n\n/**\n * Test whether a string represents a number\n *\n * @param {string} value\n * The string to test.\n * @return {boolean}\n * true if the string contains a number; false otherwise.\n */\nfunction isNumber(value) {\n if (typeof value !== 'string') {\n return false;\n }\n return NUMBER_REGEX.test(value);\n}\n\nexport default isNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isInteger from './is-integer';\nimport extractSignificantDigits from './extract-significant-digits';\nimport isNumber from './is-number';\n\nconst DEFAULT_APPROX = false;\nconst DEFAULT_REQUIRED_DIGITS = 14;\n\n/**\n * Test whether a string can be safely represented with a number without\n * information loss.\n *\n * When the argument `approx` is true, floating point numbers that lose a few\n * digits but are still approximately equal in value are considered safe too.\n * Integer numbers must still be exactly equal.\n *\n * @param {string} value\n * The string to test.\n * @param {object} options\n * The options of the test. It may contain the following properties:\n * - `approx: boolean`: indicates whether to consider approximately equal\n * floating point numbers as safe. Default is `false`.\n * - `requiredDigits: number`: the number of significant digits required for\n * a floating point number to be considered approximately equal. Default\n * is `14`.\n * @return {boolean}\n * true if the string can be safely represented with a number; false\n * otherwise.\n */\nfunction isSafeNumber(value, options = undefined) {\n // handle the edge cases\n if (!isNumber(value) || value === '' || value === 'NaN') {\n return false;\n }\n\n const num = parseFloat(value);\n const str = String(num);\n if (value === str) {\n return true;\n }\n const v = extractSignificantDigits(value);\n const s = extractSignificantDigits(str);\n if (v === s) {\n return true;\n }\n\n // use the default options\n const approx = options?.approx ?? DEFAULT_APPROX;\n if (!approx) {\n return false;\n }\n\n // A value is approximately equal when:\n // 1. it is a floating point number, not an integer\n // 2. both v and s have at least requiredDigits digits\n // 3. the first requiredDigits digits are equal\n const requiredDigits = options?.requiredDigits ?? DEFAULT_REQUIRED_DIGITS;\n\n // check if the value is an integer\n const isIntegerVal = isInteger(value);\n if (isIntegerVal) {\n return true; // when the input is an integer and approx=true, return true\n }\n\n // check if s has at least requiredDigits digits\n const sLengthOk = s.length >= requiredDigits;\n if (!sLengthOk) {\n return false;\n }\n\n // check if v has at least requiredDigits digits\n const vLengthOk = v.length >= requiredDigits;\n\n if (vLengthOk) {\n // check if the first requiredDigits digits are equal\n const vPrefix = v.substring(0, requiredDigits);\n const sPrefix = s.substring(0, requiredDigits);\n return vPrefix === sPrefix;\n } else {\n // if v length is not enough, return true\n return true;\n }\n}\n\nexport {\n DEFAULT_APPROX,\n DEFAULT_REQUIRED_DIGITS,\n isSafeNumber,\n};\n\nexport default isSafeNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isInteger from './is-integer';\nimport extractSignificantDigits from './extract-significant-digits';\nimport isNumber from './is-number';\n\n/**\n * When the provided value is an unsafe number, describe what the reason is\n * - `'overflow'`\n * - `'underflow'`\n * - `'truncate_integer'`\n * - `'truncate_float'`\n * - `'none'` (when the value is safe)\n *\n * @param {string} value\n * The string represents a number to test.\n * @return {string}\n * The reason why the value is unsafe. Returns `'none'` when the value is safe.\n */\nfunction getUnsafeReason(value) {\n if (typeof value !== 'string') {\n value = String(value);\n }\n if (!isNumber(value) || value === '' || value === 'NaN') {\n return 'none';\n }\n const num = parseFloat(value);\n const str = String(num);\n if (value === str) {\n return 'none';\n }\n const v = extractSignificantDigits(value);\n const s = extractSignificantDigits(str);\n if (v === s) {\n return 'none';\n }\n if (isInteger(value)) {\n return 'truncate_integer';\n }\n if (!Number.isFinite(num)) {\n return 'overflow';\n }\n if (num === 0) {\n return 'underflow';\n }\n return 'truncate_float';\n}\n\nexport default getUnsafeReason;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isNumber from './is-number';\nimport getUnsafeReason from './get-unsafe-reason';\n\n/**\n * The class of lossless numbers, which stores its numeric value as string.\n */\nclass LosslessNumber {\n /**\n * The string representation of the number.\n *\n * @type {string}\n */\n value = '';\n\n /**\n * Whether the value is a lossless number.\n *\n * @type {boolean}\n */\n isLosslessNumber = true;\n\n /**\n * Constructs a new instance of `LosslessNumber`.\n *\n * @param {string} value\n * The string representation of the number.\n */\n constructor(value) {\n if (!isNumber(value)) {\n throw new Error(`Invalid number (value: \"${value}\")`);\n }\n this.value = value;\n }\n\n /**\n * Get the value of the LosslessNumber as number or bigint.\n *\n * - a number is returned for safe numbers and decimal values that only lose\n * some insignificant digits;\n * - a bigint is returned for big integer numbers;\n * - an Error is thrown for values that will overflow or underflow;\n *\n * Note that you can implement your own strategy for conversion by just\n * getting the value as string via `.toString()`, and using util functions\n * like `isInteger`, `isSafeNumber`, `getUnsafeReason`, and `toSafeNumberOrThrow`\n * to convert it to a numeric value.\n *\n * @return {number|bigint}\n * the numeric value of the LosslessNumber, as number or bigint.\n */\n valueOf() {\n const unsafeReason = getUnsafeReason(this.value);\n switch (unsafeReason) {\n case 'none':\n return parseFloat(this.value);\n case 'truncate_float':\n return parseFloat(this.value);\n case 'truncate_integer':\n return BigInt(this.value);\n case 'overflow':\n case 'underflow':\n throw new Error('Cannot safely CONVERT TO NUMBER: '\n + `the value '${this.value}' would ${unsafeReason} `\n + `and become ${parseFloat(this.value)}`);\n default:\n throw new Error('Unknown unsafe reason');\n }\n }\n\n /**\n * Get the value of this `LosslessNumber` as string.\n *\n * @return {string}\n * the string representation of this `LosslessNumber`.\n */\n toString() {\n return this.value;\n }\n\n // Note: we do NOT implement a .toJSON() method, and you should not implement\n // or use that, it cannot safely turn the numeric value in the string into\n // stringified JSON since it has to be parsed into a number first.\n}\n\nexport default LosslessNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport isInteger from './utils/is-integer';\nimport isSafeNumber from './utils/is-safe-number';\nimport LosslessNumber from './utils/lossless-number';\n\n/**\n * A custom function to parse a number from a string, which supports lossless\n * number parsing.\n *\n * @param {string} key\n * The key of the property.\n * @param {string} value\n * The value of the property.\n * @return {any}\n * The parsed value.\n * @private\n */\nfunction parseNumber(key, value) {\n // if (isBigInt(value)) {\n // return BigInt(value.slice(0, -1));\n // }\n if (isSafeNumber(value, { approx: false })) {\n return parseFloat(value);\n }\n if (isInteger(value)) {\n return BigInt(value);\n }\n return new LosslessNumber(value);\n}\n\nexport default parseNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport LosslessNumber from './utils/lossless-number';\n\n/**\n * Formats a number value.\n *\n * @param {string} key\n * The key of the property.\n * @param {string} value\n * The value of the property.\n * @param {string} type\n * The type of the value.\n * @return {undefined|string}\n * The formatted value. If the value is not a number, then return undefined.\n * @private\n */\nfunction formatNumber(key, value, type) {\n switch (type) {\n case 'bigint':\n return value.toString();\n case 'object':\n // if (value instanceof Set) {\n // return Array.from(value);\n // }\n // if (value instanceof Map) {\n // return Array.from(value);\n // }\n if (value instanceof LosslessNumber) {\n return value.toString();\n }\n return undefined;\n default:\n return undefined;\n }\n}\n\nexport default formatNumber;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n\n/**\n * A JSON replacer which serialize collections as arrays.\n *\n * @param {string} key\n * The key of the property.\n * @param {any} value\n * The value of the property.\n * @param {undefined|null|function} fallbackReplacer\n * The fallback replacer.\n * @return {any}\n * The serialized value.\n * @private\n */\nfunction collectionReplacer(key, value, fallbackReplacer) {\n if (value instanceof Set) {\n return Array.from(value);\n }\n if (value instanceof Map) {\n return Array.from(value);\n }\n if (fallbackReplacer) {\n return fallbackReplacer(key, value);\n }\n return value;\n}\n\nexport default collectionReplacer;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport { parse as parseJson, stringify as stringifyJson } from 'json-custom-numbers';\nimport parseNumber from './parse-number';\nimport formatNumber from './format-number';\nimport collectionReplacer from './collection-replacer';\n\n/**\n * A customized class for JSON object which supports lossless number parsing and\n * stringifying.\n *\n * The instance of this class is similar to the standard `JSON` object, but with\n * enhanced capabilities for handling large integers, floating-point numbers, and\n * collections like `Set` and `Map`.\n *\n * Features:\n * - Lossless parsing of large integers (converted to BigInt)\n * - Lossless parsing of large floating-point numbers (converted to LosslessNumber)\n * - Support for Set and Map serialization/deserialization\n * - Compatible with standard JSON.parse/stringify API\n *\n * @example\n * // Parse large integers without precision loss\n * const obj = json.parse('{\"bigInt\": 9007199254740993}');\n * console.log(typeof obj.bigInt); // 'bigint'\n *\n * // Parse large floats without precision loss\n * const obj2 = json.parse('{\"bigFloat\": 2.3e+500}');\n * console.log(obj2.bigFloat instanceof LosslessNumber); // true\n *\n * // Stringify collections\n * const obj3 = { set: new Set([1, 2, 3]), map: new Map([['a', 1]]) };\n * console.log(json.stringify(obj3)); // '{\"set\":[1,2,3],\"map\":[[\"a\",1]]}'\n *\n * @author Haixing Hu\n */\nclass Json {\n /**\n * The string tag used by Object.prototype.toString() to identify this object.\n *\n * This property makes instances of the Json class return '[object JSON]' when\n * converted to string via Object.prototype.toString.call(), providing better\n * debugging and inspection experience.\n *\n * @type {string}\n * @readonly\n * @example\n * const json = new Json();\n * console.log(Object.prototype.toString.call(json)); // '[object JSON]'\n */\n [Symbol.toStringTag] = 'JSON';\n\n /**\n * Parses the specified JSON string and returns the resulting object.\n *\n * This method works like the standard JSON.parse(), but with enhanced number\n * handling:\n * - Safe numbers are parsed as regular JavaScript numbers\n * - Large integers are parsed as BigInt\n * - Large floating-point numbers are parsed as LosslessNumber instances\n *\n * @param {string} text\n * The JSON string to be parsed. Must be a valid JSON string.\n * @param {Function} [reviver]\n * Optional function to transform the results. This function is called for\n * each member of the object. If a member contains nested objects, the nested\n * objects are transformed before the parent object is.\n * @returns {*}\n * The resulting JavaScript value/object. The type depends on the JSON content.\n * @throws {SyntaxError}\n * Thrown if the text is not valid JSON.\n * @example\n * // Parse regular JSON\n * const obj = json.parse('{\"name\": \"John\", \"age\": 30}');\n *\n * // Parse with large integer (becomes BigInt)\n * const obj2 = json.parse('{\"id\": 9007199254740993}');\n * console.log(typeof obj2.id); // 'bigint'\n *\n * // Parse with reviver function\n * const obj3 = json.parse('{\"date\": \"2023-01-01\"}', (key, value) => {\n * if (key === 'date') return new Date(value);\n * return value;\n * });\n */\n parse(text, reviver) {\n if (typeof text !== 'string') {\n throw new TypeError('JSON.parse requires a string argument');\n }\n if ((reviver != null) && (typeof reviver !== 'function')) {\n throw new TypeError('JSON.parse reviver argument must be a function');\n }\n try {\n return parseJson(text, reviver, parseNumber);\n } catch (error) {\n // Re-throw with more context if needed\n if (error instanceof SyntaxError) {\n throw new SyntaxError(`Invalid JSON: ${error.message}`);\n }\n throw error;\n }\n }\n\n /**\n * Stringifies the specified value and returns the resulting JSON string.\n *\n * This method works like the standard JSON.stringify(), but with enhanced\n * support for:\n * - BigInt values (converted to number strings)\n * - LosslessNumber instances (converted to their string representation)\n * - Set instances (converted to arrays)\n * - Map instances (converted to arrays of key-value pairs)\n *\n * @param {*} value\n * The value to be stringified. Can be any JavaScript value.\n * @param {Function|Array} [replacer]\n * Optional function or array to transform the results. If a function, it's\n * called for each member of the object. If an array, it specifies the\n * properties to be included in the result.\n * @param {string|number} [space]\n * Optional string or number to control spacing in the output. If a number,\n * it indicates the number of space characters to use as white space. If a\n * string, it's used as white space.\n * @returns {string|undefined}\n * The resulting JSON string, or undefined if the value cannot be serialized.\n * @example\n * // Stringify regular object\n * const str = json.stringify({name: \"John\", age: 30});\n *\n * // Stringify with BigInt (preserved as number)\n * const str2 = json.stringify({id: 9007199254740993n});\n * // Result: '{\"id\":9007199254740993}'\n *\n * // Stringify with collections\n * const str3 = json.stringify({\n * set: new Set([1, 2, 3]),\n * map: new Map([['a', 1], ['b', 2]])\n * });\n * // Result: '{\"set\":[1,2,3],\"map\":[[\"a\",1],[\"b\",2]]}'\n *\n * // Stringify with custom replacer\n * const str4 = json.stringify({a: 1, b: 2}, (key, value) => {\n * return key === 'a' ? undefined : value;\n * });\n * // Result: '{\"b\":2}'\n */\n stringify(value, replacer, space) {\n // Validate replacer parameter\n if ((replacer != null) && (typeof replacer !== 'function') && (!Array.isArray(replacer))) {\n throw new TypeError('JSON.stringify replacer argument must be a function or array');\n }\n // Validate space parameter\n if ((space != null) && (typeof space !== 'string') && (typeof space !== 'number')) {\n throw new TypeError('JSON.stringify space argument must be a string or number');\n }\n try {\n // Optimize: create combined replacer function only when needed\n const combinedReplacer = replacer\n ? (k, v) => collectionReplacer(k, v, replacer)\n : collectionReplacer;\n\n return stringifyJson(value, combinedReplacer, space, formatNumber);\n } catch (error) {\n // Handle circular reference and other stringify errors\n if ((error.message.includes('circular'))\n || (error.message.includes('Converting circular structure'))) {\n throw new TypeError('Converting circular structure to JSON');\n }\n throw error;\n }\n }\n}\n\n/**\n * A customized JSON object which supports lossless number parsing and stringifying.\n *\n * This object provides two methods: `parse` and `stringify`, which are the same as the\n * `JSON.parse` and `JSON.stringify` methods, except that they support lossless number\n * parsing and stringifying.\n *\n * Key differences from standard JSON:\n * - Large integers are preserved as BigInt instead of losing precision\n * - Large floating-point numbers are preserved as LosslessNumber instances\n * - Set and Map collections are automatically serialized as arrays\n * - Maintains full compatibility with standard JSON API\n *\n * @type {Json}\n * @example\n * import json from '@qubit-ltd/json';\n *\n * // Use exactly like standard JSON\n * const obj = json.parse('{\"value\": 9007199254740993}');\n * const str = json.stringify(obj);\n *\n * // Works with collections\n * const data = { items: new Set([1, 2, 3]) };\n * const serialized = json.stringify(data); // '{\"items\":[1,2,3]}'\n */\nconst json = new Json();\n\nexport default json;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\n/**\n * A regular expression for testing whether a string represents a BigInt.\n *\n * @type {RegExp}\n * @private\n */\nconst BIG_INTEGER_REGEX = /^[+-]?\\d+n$/;\n\n/**\n * Test whether a string represents a BigInt.\n *\n * @param value\n * The string to test.\n * @return {boolean}\n * true if the string contains a BigInt; false otherwise.\n */\nfunction isBigInt(value) {\n return BIG_INTEGER_REGEX.test(value);\n}\n\nexport default isBigInt;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport getUnsafeReason from './get-unsafe-reason';\nimport { DEFAULT_APPROX } from './is-safe-number';\n\n/**\n * Convert a string into a number when it is safe to do so.\n * Throws an error otherwise, explaining the reason.\n *\n * @param {string} value\n * The string to convert into a number.\n * @param {object} options\n * The options for conversion.\n * @return {number}\n * The converted safe number.\n * @throws {Error}\n * When the value is not safe to convert.\n */\nexport function toSafeNumberOrThrow(value, options = undefined) {\n const number = parseFloat(value);\n const unsafeReason = getUnsafeReason(value);\n if (unsafeReason === 'none') {\n return number;\n }\n const approx = options?.approx ?? DEFAULT_APPROX;\n // when approx is true, we allow truncating float values\n if (approx && (unsafeReason === 'truncate_float')) {\n return number;\n }\n const unsafeReasonText = unsafeReason?.replace(/_/, ' ');\n throw new Error('Cannot safely convert to number: '\n + `the value '${value}' would ${unsafeReasonText} and become ${number}`);\n}\n\nexport default toSafeNumberOrThrow;\n","////////////////////////////////////////////////////////////////////////////////\n//\n// Copyright (c) 2022 - 2026.\n// Haixing Hu, Qubit Co. Ltd.\n//\n// All rights reserved.\n//\n////////////////////////////////////////////////////////////////////////////////\nimport Json from './json';\nimport LosslessNumber from './utils/lossless-number';\nimport isBigInt from './utils/is-bigint';\nimport isInteger from './utils/is-integer';\nimport isNumber from './utils/is-number';\nimport isSafeNumber from './utils/is-safe-number';\nimport getUnsafeReason from './utils/get-unsafe-reason';\nimport toSafeNumberOrThrow from './utils/to-safe-number-or-throw';\n\nexport {\n getUnsafeReason,\n isBigInt,\n isInteger,\n isNumber,\n isSafeNumber,\n Json,\n LosslessNumber,\n toSafeNumberOrThrow,\n};\n\nexport default Json;\n"],"names":["T","C","D","x","q","K","INTEGER_REGEX","isInteger","value","test","EXPONENTIAL_PART_REGEX","LEADING_MINUS_AND_ZEROS_REGEX","DOT_REGEX","TRAILING_ZEROS_REGEX","extractSignificantDigits","result","replace","NUMBER_REGEX","isNumber","DEFAULT_APPROX","DEFAULT_REQUIRED_DIGITS","isSafeNumber","_options$approx","_options$requiredDigi","options","arguments","length","undefined","num","parseFloat","str","String","v","s","approx","requiredDigits","isIntegerVal","sLengthOk","vLengthOk","vPrefix","substring","sPrefix","getUnsafeReason","Number","isFinite","LosslessNumber","_classCallCheck","_defineProperty","Error","concat","_createClass","key","valueOf","unsafeReason","BigInt","toString","parseNumber","formatNumber","type","collectionReplacer","fallbackReplacer","Set","Array","from","Map","Json","Symbol","toStringTag","parse","text","reviver","TypeError","parseJson","error","SyntaxError","message","stringify","replacer","space","isArray","combinedReplacer","k","stringifyJson","includes","json","BIG_INTEGER_REGEX","isBigInt","toSafeNumberOrThrow","number","unsafeReasonText"],"mappings":";;;;AAAA,IAAIA,GAAC,CAAC,MAAM,CAAC,cAAc,CAAC,IAAIC,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A,EAAA,IAAIe,MAAM,IAAKmB,YAAY,KAAK,gBAAiB,EAAE;AACjD,IAAA,OAAOmC,MAAM;AACf,EAAA;AACA,EAAA,IAAMC,gBAAgB,GAAGpC,YAAY,KAAA,IAAA,IAAZA,YAAY,KAAA,MAAA,GAAA,MAAA,GAAZA,YAAY,CAAErC,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC;AACxD,EAAA,MAAM,IAAIgC,KAAK,CAAC,mCAAmC,GAAA,aAAA,CAAAC,MAAA,CAC/BzC,KAAK,EAAA,UAAA,CAAA,CAAAyC,MAAA,CAAWwC,gBAAgB,EAAA,cAAA,CAAA,CAAAxC,MAAA,CAAeuC,MAAM,CAAE,CAAC;AAC9E;;ACtCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;","x_google_ignoreList":[0,1]}
package/doc/api/Json.html CHANGED
@@ -39,4 +39,4 @@ const str3 = json.stringify({
39
39
  const str4 = json.stringify({a: 1, b: 2}, (key, value) => {
40
40
  return key === 'a' ? undefined : value;
41
41
  });
42
- // Result: '{"b":2}'</code></pre></div></div></article></section></div></div></div><div class="search-container" id="PkfLWpAbet" style="display:none"><div class="wrapper" id="iCxFxjkHbP"><button class="icon-button search-close-button" id="VjLlGakifb" aria-label="关闭搜索"><svg><use xlink:href="#close-icon"></use></svg></button><div class="search-box-c"><svg><use xlink:href="#search-icon"></use></svg> <input type="text" id="vpcKVYIppa" class="search-input" placeholder="搜索..." autofocus></div><div class="search-result-c" id="fWwVHRuDuN"><span class="search-result-c-text">输入任何内容查看搜索结果</span></div></div></div><div class="mobile-menu-icon-container"><button class="icon-button" id="mobile-menu" data-isopen="false" aria-label="menu"><svg><use xlink:href="#menu-icon"></use></svg></button></div><div id="mobile-sidebar" class="mobile-sidebar-container"><div class="mobile-sidebar-wrapper"><div class="mobile-nav-links"></div><div class="mobile-sidebar-items-c"><div class="sidebar-section-title"><a href="index.html" class="sidebar-home-anchor">首页</a></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-类"><div>类</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="Json.html">Json</a></div><div class="sidebar-section-children"><a href="LosslessNumber.html">LosslessNumber</a></div></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-全局"><div>全局</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="global.html#getUnsafeReason">getUnsafeReason</a></div><div class="sidebar-section-children"><a href="global.html#isBigInt">isBigInt</a></div><div class="sidebar-section-children"><a href="global.html#isInteger">isInteger</a></div><div class="sidebar-section-children"><a href="global.html#isNumber">isNumber</a></div><div class="sidebar-section-children"><a href="global.html#isSafeNumber">isSafeNumber</a></div><div class="sidebar-section-children"><a href="global.html#json">json</a></div><div class="sidebar-section-children"><a href="global.html#toSafeNumberOrThrow">toSafeNumberOrThrow</a></div></div></div><div class="mobile-navbar-actions"><div class="navbar-right-item"><button class="icon-button home-button" aria-label="go-to-homepage"><svg><use xlink:href="#home-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button search-button" aria-label="open-search"><svg><use xlink:href="#search-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button theme-toggle" aria-label="toggle-theme"><svg><use class="theme-svg-use" xlink:href="#light-theme-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button font-size" aria-label="change-font-size"><svg><use xlink:href="#font-size-icon"></use></svg></button></div></div></div></div><script type="text/javascript" src="scripts/core.min.js"></script><script src="scripts/search.min.js" defer="defer"></script><script src="scripts/third-party/fuse.js" defer="defer"></script><script type="text/javascript">var tocbotInstance=tocbot.init({tocSelector:"#eed4d2a0bfd64539bb9df78095dec881",contentSelector:".main-content",headingSelector:"h1, h2, h3",hasInnerContainers:!0,scrollContainer:".main-content",headingsOffset:130,onClick:bringLinkToView})</script><script>document.addEventListener("DOMContentLoaded",(function(){"undefined"!=typeof tippy&&(tippy(".home-button",{content:"回到首页",delay:500}),tippy(".theme-toggle",{content:"切换主题",delay:500}),tippy(".search-button",{content:"搜索",delay:500}),tippy(".font-size",{content:"更改字体大小",delay:500}))}))</script></body></html>
42
+ // Result: '{"b":2}'</code></pre></div></div></article></section></div></div></div><div class="search-container" id="PkfLWpAbet" style="display:none"><div class="wrapper" id="iCxFxjkHbP"><button class="icon-button search-close-button" id="VjLlGakifb" aria-label="关闭搜索"><svg><use xlink:href="#close-icon"></use></svg></button><div class="search-box-c"><svg><use xlink:href="#search-icon"></use></svg> <input type="text" id="vpcKVYIppa" class="search-input" placeholder="搜索..." autofocus></div><div class="search-result-c" id="fWwVHRuDuN"><span class="search-result-c-text">输入任何内容查看搜索结果</span></div></div></div><div class="mobile-menu-icon-container"><button class="icon-button" id="mobile-menu" data-isopen="false" aria-label="menu"><svg><use xlink:href="#menu-icon"></use></svg></button></div><div id="mobile-sidebar" class="mobile-sidebar-container"><div class="mobile-sidebar-wrapper"><div class="mobile-nav-links"></div><div class="mobile-sidebar-items-c"><div class="sidebar-section-title"><a href="index.html" class="sidebar-home-anchor">首页</a></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-类"><div>类</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="Json.html">Json</a></div><div class="sidebar-section-children"><a href="LosslessNumber.html">LosslessNumber</a></div></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-全局"><div>全局</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="global.html#getUnsafeReason">getUnsafeReason</a></div><div class="sidebar-section-children"><a href="global.html#isBigInt">isBigInt</a></div><div class="sidebar-section-children"><a href="global.html#isInteger">isInteger</a></div><div class="sidebar-section-children"><a href="global.html#isNumber">isNumber</a></div><div class="sidebar-section-children"><a href="global.html#isSafeNumber">isSafeNumber</a></div><div class="sidebar-section-children"><a href="global.html#json">json</a></div><div class="sidebar-section-children"><a href="global.html#toSafeNumberOrThrow">toSafeNumberOrThrow</a></div></div></div><div class="mobile-navbar-actions"><div class="navbar-right-item"><button class="icon-button home-button" aria-label="go-to-homepage"><svg><use xlink:href="#home-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button search-button" aria-label="open-search"><svg><use xlink:href="#search-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button theme-toggle" aria-label="toggle-theme"><svg><use class="theme-svg-use" xlink:href="#light-theme-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button font-size" aria-label="change-font-size"><svg><use xlink:href="#font-size-icon"></use></svg></button></div></div></div></div><script type="text/javascript" src="scripts/core.min.js"></script><script src="scripts/search.min.js" defer="defer"></script><script src="scripts/third-party/fuse.js" defer="defer"></script><script type="text/javascript">var tocbotInstance=tocbot.init({tocSelector:"#eed4d2a0bfd64539bb9df78095dec881",contentSelector:".main-content",headingSelector:"h1, h2, h3",hasInnerContainers:!0,scrollContainer:".main-content",headingsOffset:130,onClick:bringLinkToView})</script><script>document.addEventListener("DOMContentLoaded",function(){"undefined"!=typeof tippy&&(tippy(".home-button",{content:"回到首页",delay:500}),tippy(".theme-toggle",{content:"切换主题",delay:500}),tippy(".search-button",{content:"搜索",delay:500}),tippy(".font-size",{content:"更改字体大小",delay:500}))})</script></body></html>
@@ -1,3 +1,3 @@
1
1
  <!DOCTYPE html><html lang="en" style="font-size:16px"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><title>Class: LosslessNumber</title><!--[if lt IE 9]>
2
2
  <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
3
- <![endif]--><script src="scripts/third-party/hljs.js" defer="defer"></script><script src="scripts/third-party/hljs-line-num.js" defer="defer"></script><script src="scripts/third-party/popper.js" defer="defer"></script><script src="scripts/third-party/tippy.js" defer="defer"></script><script src="scripts/third-party/tocbot.min.js"></script><script>var baseURL="/",locationPathname="";baseURL=(locationPathname=document.location.pathname).substr(0,locationPathname.lastIndexOf("/")+1)</script><link rel="stylesheet" href="styles/clean-jsdoc-theme.min.css"><svg aria-hidden="true" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="display:none"><defs><symbol id="home-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M19 21H5a1 1 0 0 1-1-1v-9H1l10.327-9.388a1 1 0 0 1 1.346 0L23 11h-3v9a1 1 0 0 1-1 1zM6 19h12V9.157l-6-5.454-6 5.454V19z"/></symbol><symbol id="copy-icon" viewbox="0 0 488.3 488.3"><g><path d="M314.25,85.4h-227c-21.3,0-38.6,17.3-38.6,38.6v325.7c0,21.3,17.3,38.6,38.6,38.6h227c21.3,0,38.6-17.3,38.6-38.6V124 C352.75,102.7,335.45,85.4,314.25,85.4z M325.75,449.6c0,6.4-5.2,11.6-11.6,11.6h-227c-6.4,0-11.6-5.2-11.6-11.6V124 c0-6.4,5.2-11.6,11.6-11.6h227c6.4,0,11.6,5.2,11.6,11.6V449.6z"/><path d="M401.05,0h-227c-21.3,0-38.6,17.3-38.6,38.6c0,7.5,6,13.5,13.5,13.5s13.5-6,13.5-13.5c0-6.4,5.2-11.6,11.6-11.6h227 c6.4,0,11.6,5.2,11.6,11.6v325.7c0,6.4-5.2,11.6-11.6,11.6c-7.5,0-13.5,6-13.5,13.5s6,13.5,13.5,13.5c21.3,0,38.6-17.3,38.6-38.6 V38.6C439.65,17.3,422.35,0,401.05,0z"/></g></symbol><symbol id="search-icon" viewBox="0 0 512 512"><g><g><path d="M225.474,0C101.151,0,0,101.151,0,225.474c0,124.33,101.151,225.474,225.474,225.474 c124.33,0,225.474-101.144,225.474-225.474C450.948,101.151,349.804,0,225.474,0z M225.474,409.323 c-101.373,0-183.848-82.475-183.848-183.848S124.101,41.626,225.474,41.626s183.848,82.475,183.848,183.848 S326.847,409.323,225.474,409.323z"/></g></g><g><g><path d="M505.902,476.472L386.574,357.144c-8.131-8.131-21.299-8.131-29.43,0c-8.131,8.124-8.131,21.306,0,29.43l119.328,119.328 c4.065,4.065,9.387,6.098,14.715,6.098c5.321,0,10.649-2.033,14.715-6.098C514.033,497.778,514.033,484.596,505.902,476.472z"/></g></g></symbol><symbol id="font-size-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M11.246 15H4.754l-2 5H.6L7 4h2l6.4 16h-2.154l-2-5zm-.8-2L8 6.885 5.554 13h4.892zM21 12.535V12h2v8h-2v-.535a4 4 0 1 1 0-6.93zM19 18a2 2 0 1 0 0-4 2 2 0 0 0 0 4z"/></symbol><symbol id="add-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M11 11V5h2v6h6v2h-6v6h-2v-6H5v-2z"/></symbol><symbol id="minus-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M5 11h14v2H5z"/></symbol><symbol id="dark-theme-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M10 7a7 7 0 0 0 12 4.9v.1c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2h.1A6.979 6.979 0 0 0 10 7zm-6 5a8 8 0 0 0 15.062 3.762A9 9 0 0 1 8.238 4.938 7.999 7.999 0 0 0 4 12z"/></symbol><symbol id="light-theme-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M12 18a6 6 0 1 1 0-12 6 6 0 0 1 0 12zm0-2a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM11 1h2v3h-2V1zm0 19h2v3h-2v-3zM3.515 4.929l1.414-1.414L7.05 5.636 5.636 7.05 3.515 4.93zM16.95 18.364l1.414-1.414 2.121 2.121-1.414 1.414-2.121-2.121zm2.121-14.85l1.414 1.415-2.121 2.121-1.414-1.414 2.121-2.121zM5.636 16.95l1.414 1.414-2.121 2.121-1.414-1.414 2.121-2.121zM23 11v2h-3v-2h3zM4 11v2H1v-2h3z"/></symbol><symbol id="reset-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M18.537 19.567A9.961 9.961 0 0 1 12 22C6.477 22 2 17.523 2 12S6.477 2 12 2s10 4.477 10 10c0 2.136-.67 4.116-1.81 5.74L17 12h3a8 8 0 1 0-2.46 5.772l.997 1.795z"/></symbol><symbol id="down-icon" viewBox="0 0 16 16"><path fill-rule="evenodd" clip-rule="evenodd" d="M12.7803 6.21967C13.0732 6.51256 13.0732 6.98744 12.7803 7.28033L8.53033 11.5303C8.23744 11.8232 7.76256 11.8232 7.46967 11.5303L3.21967 7.28033C2.92678 6.98744 2.92678 6.51256 3.21967 6.21967C3.51256 5.92678 3.98744 5.92678 4.28033 6.21967L8 9.93934L11.7197 6.21967C12.0126 5.92678 12.4874 5.92678 12.7803 6.21967Z"></path></symbol><symbol id="codepen-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M16.5 13.202L13 15.535v3.596L19.197 15 16.5 13.202zM14.697 12L12 10.202 9.303 12 12 13.798 14.697 12zM20 10.869L18.303 12 20 13.131V10.87zM19.197 9L13 4.869v3.596l3.5 2.333L19.197 9zM7.5 10.798L11 8.465V4.869L4.803 9 7.5 10.798zM4.803 15L11 19.131v-3.596l-3.5-2.333L4.803 15zM4 13.131L5.697 12 4 10.869v2.262zM2 9a1 1 0 0 1 .445-.832l9-6a1 1 0 0 1 1.11 0l9 6A1 1 0 0 1 22 9v6a1 1 0 0 1-.445.832l-9 6a1 1 0 0 1-1.11 0l-9-6A1 1 0 0 1 2 15V9z"/></symbol><symbol id="close-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M12 10.586l4.95-4.95 1.414 1.414-4.95 4.95 4.95 4.95-1.414 1.414-4.95-4.95-4.95 4.95-1.414-1.414 4.95-4.95-4.95-4.95L7.05 5.636z"/></symbol><symbol id="menu-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M3 4h18v2H3V4zm0 7h18v2H3v-2zm0 7h18v2H3v-2z"/></symbol></defs></svg></head><body data-theme="dark"><div class="sidebar-container"><div class="sidebar" id="sidebar"><div class="sidebar-items-container"><div class="sidebar-section-title"><a href="index.html" class="sidebar-home-anchor">首页</a></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-类"><div>类</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="Json.html">Json</a></div><div class="sidebar-section-children"><a href="LosslessNumber.html">LosslessNumber</a></div></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-全局"><div>全局</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="global.html#getUnsafeReason">getUnsafeReason</a></div><div class="sidebar-section-children"><a href="global.html#isBigInt">isBigInt</a></div><div class="sidebar-section-children"><a href="global.html#isInteger">isInteger</a></div><div class="sidebar-section-children"><a href="global.html#isNumber">isNumber</a></div><div class="sidebar-section-children"><a href="global.html#isSafeNumber">isSafeNumber</a></div><div class="sidebar-section-children"><a href="global.html#json">json</a></div><div class="sidebar-section-children"><a href="global.html#toSafeNumberOrThrow">toSafeNumberOrThrow</a></div></div></div></div></div><div class="navbar-container" id="VuAckcnZhf"><nav class="navbar"><div class="navbar-left-items"></div><div class="navbar-right-items"><div class="navbar-right-item"><button class="icon-button home-button" aria-label="go-to-homepage"><svg><use xlink:href="#home-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button search-button" aria-label="open-search"><svg><use xlink:href="#search-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button theme-toggle" aria-label="toggle-theme"><svg><use class="theme-svg-use" xlink:href="#light-theme-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button font-size" aria-label="change-font-size"><svg><use xlink:href="#font-size-icon"></use></svg></button></div></div><nav></nav></nav></div><div class="toc-container"><div class="toc-content"><span class="bold">本页内容</span><div id="eed4d2a0bfd64539bb9df78095dec881"></div></div></div><div class="body-wrapper"><div class="main-content"><div class="main-wrapper"><section><header><h1 id="LosslessNumber-title" class="has-anchor">LosslessNumber</h1><div class="class-description"><p>The class of lossless numbers, which stores its numeric value as string.</p></div></header><article><div class="container-overview"><h2 id="constructor" class="has-anchor">构造函数</h2><h3 class="name has-anchor" id="LosslessNumber"><span class="type-signature"></span>new LosslessNumber<span class="signature">(value)</span></h3><div class="description"><p>Constructs a new instance of <code>LosslessNumber</code>.</p></div><div class="method-member-container flex flex-col w-100 overflow-auto mt-20"><strong>参数:</strong><table class="params"><thead><tr><th>名称</th><th>类型</th><th class="last">描述</th></tr></thead><tbody><tr><td class="name"><code>value</code></td><td class="type"><span class="param-type">string</span></td><td class="description last"><p>The string representation of the number.</p></td></tr></tbody></table></div></div><h2 id="properties" class="subsection-title has-anchor">属性</h2><div class="allow-overflow"><table class="props"><thead><tr><th>名称</th><th>类型</th><th class="last">描述</th></tr></thead><tbody><tr><td class="name"><code>isLosslessNumber</code></td><td class="type"><span class="param-type">boolean</span></td><td class="description last"><p>Whether the value is a lossless number.</p></td></tr><tr><td class="name"><code>value</code></td><td class="type"><span class="param-type">string</span></td><td class="description last"><p>The string representation of the number.</p></td></tr></tbody></table></div><h2 id="methods" class="subsection-title has-anchor">方法</h2><h3 class="name has-anchor" id="toString"><span class="type-signature"></span>toString<span class="signature">()</span><span class="type-signature"> &rarr; {string}</span></h3><div class="description"><p>Get the value of this <code>LosslessNumber</code> as string.</p></div><div class="method-member-container mt-20"><strong>返回值:</strong><div class="param-desc"><p>the string representation of this <code>LosslessNumber</code>.</p></div><dl class="param-type"><dt>类型:&nbsp;</dt><dd><span class="param-type">string</span></dd></dl></div><h3 class="name has-anchor" id="valueOf"><span class="type-signature"></span>valueOf<span class="signature">()</span><span class="type-signature"> &rarr; {number|bigint}</span></h3><div class="description"><p>Get the value of the LosslessNumber as number or bigint.</p><ul><li>a number is returned for safe numbers and decimal values that only lose some insignificant digits;</li><li>a bigint is returned for big integer numbers;</li><li>an Error is thrown for values that will overflow or underflow;</li></ul><p>Note that you can implement your own strategy for conversion by just getting the value as string via <code>.toString()</code>, and using util functions like <code>isInteger</code>, <code>isSafeNumber</code>, <code>getUnsafeReason</code>, and <code>toSafeNumberOrThrow</code> to convert it to a numeric value.</p></div><div class="method-member-container mt-20"><strong>返回值:</strong><div class="param-desc"><p>the numeric value of the LosslessNumber, as number or bigint.</p></div><dl class="param-type"><dt>类型:&nbsp;</dt><dd><span class="param-type">number</span> |<wbr> <span class="param-type">bigint</span></dd></dl></div></article></section></div></div></div><div class="search-container" id="PkfLWpAbet" style="display:none"><div class="wrapper" id="iCxFxjkHbP"><button class="icon-button search-close-button" id="VjLlGakifb" aria-label="关闭搜索"><svg><use xlink:href="#close-icon"></use></svg></button><div class="search-box-c"><svg><use xlink:href="#search-icon"></use></svg> <input type="text" id="vpcKVYIppa" class="search-input" placeholder="搜索..." autofocus></div><div class="search-result-c" id="fWwVHRuDuN"><span class="search-result-c-text">输入任何内容查看搜索结果</span></div></div></div><div class="mobile-menu-icon-container"><button class="icon-button" id="mobile-menu" data-isopen="false" aria-label="menu"><svg><use xlink:href="#menu-icon"></use></svg></button></div><div id="mobile-sidebar" class="mobile-sidebar-container"><div class="mobile-sidebar-wrapper"><div class="mobile-nav-links"></div><div class="mobile-sidebar-items-c"><div class="sidebar-section-title"><a href="index.html" class="sidebar-home-anchor">首页</a></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-类"><div>类</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="Json.html">Json</a></div><div class="sidebar-section-children"><a href="LosslessNumber.html">LosslessNumber</a></div></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-全局"><div>全局</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="global.html#getUnsafeReason">getUnsafeReason</a></div><div class="sidebar-section-children"><a href="global.html#isBigInt">isBigInt</a></div><div class="sidebar-section-children"><a href="global.html#isInteger">isInteger</a></div><div class="sidebar-section-children"><a href="global.html#isNumber">isNumber</a></div><div class="sidebar-section-children"><a href="global.html#isSafeNumber">isSafeNumber</a></div><div class="sidebar-section-children"><a href="global.html#json">json</a></div><div class="sidebar-section-children"><a href="global.html#toSafeNumberOrThrow">toSafeNumberOrThrow</a></div></div></div><div class="mobile-navbar-actions"><div class="navbar-right-item"><button class="icon-button home-button" aria-label="go-to-homepage"><svg><use xlink:href="#home-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button search-button" aria-label="open-search"><svg><use xlink:href="#search-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button theme-toggle" aria-label="toggle-theme"><svg><use class="theme-svg-use" xlink:href="#light-theme-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button font-size" aria-label="change-font-size"><svg><use xlink:href="#font-size-icon"></use></svg></button></div></div></div></div><script type="text/javascript" src="scripts/core.min.js"></script><script src="scripts/search.min.js" defer="defer"></script><script src="scripts/third-party/fuse.js" defer="defer"></script><script type="text/javascript">var tocbotInstance=tocbot.init({tocSelector:"#eed4d2a0bfd64539bb9df78095dec881",contentSelector:".main-content",headingSelector:"h1, h2, h3",hasInnerContainers:!0,scrollContainer:".main-content",headingsOffset:130,onClick:bringLinkToView})</script><script>document.addEventListener("DOMContentLoaded",(function(){"undefined"!=typeof tippy&&(tippy(".home-button",{content:"回到首页",delay:500}),tippy(".theme-toggle",{content:"切换主题",delay:500}),tippy(".search-button",{content:"搜索",delay:500}),tippy(".font-size",{content:"更改字体大小",delay:500}))}))</script></body></html>
3
+ <![endif]--><script src="scripts/third-party/hljs.js" defer="defer"></script><script src="scripts/third-party/hljs-line-num.js" defer="defer"></script><script src="scripts/third-party/popper.js" defer="defer"></script><script src="scripts/third-party/tippy.js" defer="defer"></script><script src="scripts/third-party/tocbot.min.js"></script><script>var baseURL="/",locationPathname="";baseURL=(locationPathname=document.location.pathname).substr(0,locationPathname.lastIndexOf("/")+1)</script><link rel="stylesheet" href="styles/clean-jsdoc-theme.min.css"><svg aria-hidden="true" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="display:none"><defs><symbol id="home-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M19 21H5a1 1 0 0 1-1-1v-9H1l10.327-9.388a1 1 0 0 1 1.346 0L23 11h-3v9a1 1 0 0 1-1 1zM6 19h12V9.157l-6-5.454-6 5.454V19z"/></symbol><symbol id="copy-icon" viewbox="0 0 488.3 488.3"><g><path d="M314.25,85.4h-227c-21.3,0-38.6,17.3-38.6,38.6v325.7c0,21.3,17.3,38.6,38.6,38.6h227c21.3,0,38.6-17.3,38.6-38.6V124 C352.75,102.7,335.45,85.4,314.25,85.4z M325.75,449.6c0,6.4-5.2,11.6-11.6,11.6h-227c-6.4,0-11.6-5.2-11.6-11.6V124 c0-6.4,5.2-11.6,11.6-11.6h227c6.4,0,11.6,5.2,11.6,11.6V449.6z"/><path d="M401.05,0h-227c-21.3,0-38.6,17.3-38.6,38.6c0,7.5,6,13.5,13.5,13.5s13.5-6,13.5-13.5c0-6.4,5.2-11.6,11.6-11.6h227 c6.4,0,11.6,5.2,11.6,11.6v325.7c0,6.4-5.2,11.6-11.6,11.6c-7.5,0-13.5,6-13.5,13.5s6,13.5,13.5,13.5c21.3,0,38.6-17.3,38.6-38.6 V38.6C439.65,17.3,422.35,0,401.05,0z"/></g></symbol><symbol id="search-icon" viewBox="0 0 512 512"><g><g><path d="M225.474,0C101.151,0,0,101.151,0,225.474c0,124.33,101.151,225.474,225.474,225.474 c124.33,0,225.474-101.144,225.474-225.474C450.948,101.151,349.804,0,225.474,0z M225.474,409.323 c-101.373,0-183.848-82.475-183.848-183.848S124.101,41.626,225.474,41.626s183.848,82.475,183.848,183.848 S326.847,409.323,225.474,409.323z"/></g></g><g><g><path d="M505.902,476.472L386.574,357.144c-8.131-8.131-21.299-8.131-29.43,0c-8.131,8.124-8.131,21.306,0,29.43l119.328,119.328 c4.065,4.065,9.387,6.098,14.715,6.098c5.321,0,10.649-2.033,14.715-6.098C514.033,497.778,514.033,484.596,505.902,476.472z"/></g></g></symbol><symbol id="font-size-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M11.246 15H4.754l-2 5H.6L7 4h2l6.4 16h-2.154l-2-5zm-.8-2L8 6.885 5.554 13h4.892zM21 12.535V12h2v8h-2v-.535a4 4 0 1 1 0-6.93zM19 18a2 2 0 1 0 0-4 2 2 0 0 0 0 4z"/></symbol><symbol id="add-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M11 11V5h2v6h6v2h-6v6h-2v-6H5v-2z"/></symbol><symbol id="minus-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M5 11h14v2H5z"/></symbol><symbol id="dark-theme-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M10 7a7 7 0 0 0 12 4.9v.1c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2h.1A6.979 6.979 0 0 0 10 7zm-6 5a8 8 0 0 0 15.062 3.762A9 9 0 0 1 8.238 4.938 7.999 7.999 0 0 0 4 12z"/></symbol><symbol id="light-theme-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M12 18a6 6 0 1 1 0-12 6 6 0 0 1 0 12zm0-2a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM11 1h2v3h-2V1zm0 19h2v3h-2v-3zM3.515 4.929l1.414-1.414L7.05 5.636 5.636 7.05 3.515 4.93zM16.95 18.364l1.414-1.414 2.121 2.121-1.414 1.414-2.121-2.121zm2.121-14.85l1.414 1.415-2.121 2.121-1.414-1.414 2.121-2.121zM5.636 16.95l1.414 1.414-2.121 2.121-1.414-1.414 2.121-2.121zM23 11v2h-3v-2h3zM4 11v2H1v-2h3z"/></symbol><symbol id="reset-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M18.537 19.567A9.961 9.961 0 0 1 12 22C6.477 22 2 17.523 2 12S6.477 2 12 2s10 4.477 10 10c0 2.136-.67 4.116-1.81 5.74L17 12h3a8 8 0 1 0-2.46 5.772l.997 1.795z"/></symbol><symbol id="down-icon" viewBox="0 0 16 16"><path fill-rule="evenodd" clip-rule="evenodd" d="M12.7803 6.21967C13.0732 6.51256 13.0732 6.98744 12.7803 7.28033L8.53033 11.5303C8.23744 11.8232 7.76256 11.8232 7.46967 11.5303L3.21967 7.28033C2.92678 6.98744 2.92678 6.51256 3.21967 6.21967C3.51256 5.92678 3.98744 5.92678 4.28033 6.21967L8 9.93934L11.7197 6.21967C12.0126 5.92678 12.4874 5.92678 12.7803 6.21967Z"></path></symbol><symbol id="codepen-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M16.5 13.202L13 15.535v3.596L19.197 15 16.5 13.202zM14.697 12L12 10.202 9.303 12 12 13.798 14.697 12zM20 10.869L18.303 12 20 13.131V10.87zM19.197 9L13 4.869v3.596l3.5 2.333L19.197 9zM7.5 10.798L11 8.465V4.869L4.803 9 7.5 10.798zM4.803 15L11 19.131v-3.596l-3.5-2.333L4.803 15zM4 13.131L5.697 12 4 10.869v2.262zM2 9a1 1 0 0 1 .445-.832l9-6a1 1 0 0 1 1.11 0l9 6A1 1 0 0 1 22 9v6a1 1 0 0 1-.445.832l-9 6a1 1 0 0 1-1.11 0l-9-6A1 1 0 0 1 2 15V9z"/></symbol><symbol id="close-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M12 10.586l4.95-4.95 1.414 1.414-4.95 4.95 4.95 4.95-1.414 1.414-4.95-4.95-4.95 4.95-1.414-1.414 4.95-4.95-4.95-4.95L7.05 5.636z"/></symbol><symbol id="menu-icon" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0z"/><path d="M3 4h18v2H3V4zm0 7h18v2H3v-2zm0 7h18v2H3v-2z"/></symbol></defs></svg></head><body data-theme="dark"><div class="sidebar-container"><div class="sidebar" id="sidebar"><div class="sidebar-items-container"><div class="sidebar-section-title"><a href="index.html" class="sidebar-home-anchor">首页</a></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-类"><div>类</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="Json.html">Json</a></div><div class="sidebar-section-children"><a href="LosslessNumber.html">LosslessNumber</a></div></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-全局"><div>全局</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="global.html#getUnsafeReason">getUnsafeReason</a></div><div class="sidebar-section-children"><a href="global.html#isBigInt">isBigInt</a></div><div class="sidebar-section-children"><a href="global.html#isInteger">isInteger</a></div><div class="sidebar-section-children"><a href="global.html#isNumber">isNumber</a></div><div class="sidebar-section-children"><a href="global.html#isSafeNumber">isSafeNumber</a></div><div class="sidebar-section-children"><a href="global.html#json">json</a></div><div class="sidebar-section-children"><a href="global.html#toSafeNumberOrThrow">toSafeNumberOrThrow</a></div></div></div></div></div><div class="navbar-container" id="VuAckcnZhf"><nav class="navbar"><div class="navbar-left-items"></div><div class="navbar-right-items"><div class="navbar-right-item"><button class="icon-button home-button" aria-label="go-to-homepage"><svg><use xlink:href="#home-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button search-button" aria-label="open-search"><svg><use xlink:href="#search-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button theme-toggle" aria-label="toggle-theme"><svg><use class="theme-svg-use" xlink:href="#light-theme-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button font-size" aria-label="change-font-size"><svg><use xlink:href="#font-size-icon"></use></svg></button></div></div><nav></nav></nav></div><div class="toc-container"><div class="toc-content"><span class="bold">本页内容</span><div id="eed4d2a0bfd64539bb9df78095dec881"></div></div></div><div class="body-wrapper"><div class="main-content"><div class="main-wrapper"><section><header><h1 id="LosslessNumber-title" class="has-anchor">LosslessNumber</h1><div class="class-description"><p>The class of lossless numbers, which stores its numeric value as string.</p></div></header><article><div class="container-overview"><h2 id="constructor" class="has-anchor">构造函数</h2><h3 class="name has-anchor" id="LosslessNumber"><span class="type-signature"></span>new LosslessNumber<span class="signature">(value)</span></h3><div class="description"><p>Constructs a new instance of <code>LosslessNumber</code>.</p></div><div class="method-member-container flex flex-col w-100 overflow-auto mt-20"><strong>参数:</strong><table class="params"><thead><tr><th>名称</th><th>类型</th><th class="last">描述</th></tr></thead><tbody><tr><td class="name"><code>value</code></td><td class="type"><span class="param-type">string</span></td><td class="description last"><p>The string representation of the number.</p></td></tr></tbody></table></div></div><h2 id="properties" class="subsection-title has-anchor">属性</h2><div class="allow-overflow"><table class="props"><thead><tr><th>名称</th><th>类型</th><th class="last">描述</th></tr></thead><tbody><tr><td class="name"><code>isLosslessNumber</code></td><td class="type"><span class="param-type">boolean</span></td><td class="description last"><p>Whether the value is a lossless number.</p></td></tr><tr><td class="name"><code>value</code></td><td class="type"><span class="param-type">string</span></td><td class="description last"><p>The string representation of the number.</p></td></tr></tbody></table></div><h2 id="methods" class="subsection-title has-anchor">方法</h2><h3 class="name has-anchor" id="toString"><span class="type-signature"></span>toString<span class="signature">()</span><span class="type-signature"> &rarr; {string}</span></h3><div class="description"><p>Get the value of this <code>LosslessNumber</code> as string.</p></div><div class="method-member-container mt-20"><strong>返回值:</strong><div class="param-desc"><p>the string representation of this <code>LosslessNumber</code>.</p></div><dl class="param-type"><dt>类型:&nbsp;</dt><dd><span class="param-type">string</span></dd></dl></div><h3 class="name has-anchor" id="valueOf"><span class="type-signature"></span>valueOf<span class="signature">()</span><span class="type-signature"> &rarr; {number|bigint}</span></h3><div class="description"><p>Get the value of the LosslessNumber as number or bigint.</p><ul><li>a number is returned for safe numbers and decimal values that only lose some insignificant digits;</li><li>a bigint is returned for big integer numbers;</li><li>an Error is thrown for values that will overflow or underflow;</li></ul><p>Note that you can implement your own strategy for conversion by just getting the value as string via <code>.toString()</code>, and using util functions like <code>isInteger</code>, <code>isSafeNumber</code>, <code>getUnsafeReason</code>, and <code>toSafeNumberOrThrow</code> to convert it to a numeric value.</p></div><div class="method-member-container mt-20"><strong>返回值:</strong><div class="param-desc"><p>the numeric value of the LosslessNumber, as number or bigint.</p></div><dl class="param-type"><dt>类型:&nbsp;</dt><dd><span class="param-type">number</span> |<wbr> <span class="param-type">bigint</span></dd></dl></div></article></section></div></div></div><div class="search-container" id="PkfLWpAbet" style="display:none"><div class="wrapper" id="iCxFxjkHbP"><button class="icon-button search-close-button" id="VjLlGakifb" aria-label="关闭搜索"><svg><use xlink:href="#close-icon"></use></svg></button><div class="search-box-c"><svg><use xlink:href="#search-icon"></use></svg> <input type="text" id="vpcKVYIppa" class="search-input" placeholder="搜索..." autofocus></div><div class="search-result-c" id="fWwVHRuDuN"><span class="search-result-c-text">输入任何内容查看搜索结果</span></div></div></div><div class="mobile-menu-icon-container"><button class="icon-button" id="mobile-menu" data-isopen="false" aria-label="menu"><svg><use xlink:href="#menu-icon"></use></svg></button></div><div id="mobile-sidebar" class="mobile-sidebar-container"><div class="mobile-sidebar-wrapper"><div class="mobile-nav-links"></div><div class="mobile-sidebar-items-c"><div class="sidebar-section-title"><a href="index.html" class="sidebar-home-anchor">首页</a></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-类"><div>类</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="Json.html">Json</a></div><div class="sidebar-section-children"><a href="LosslessNumber.html">LosslessNumber</a></div></div><div class="sidebar-section-title with-arrow" data-isopen="false" id="sidebar-全局"><div>全局</div><svg><use xlink:href="#down-icon"></use></svg></div><div class="sidebar-section-children-container"><div class="sidebar-section-children"><a href="global.html#getUnsafeReason">getUnsafeReason</a></div><div class="sidebar-section-children"><a href="global.html#isBigInt">isBigInt</a></div><div class="sidebar-section-children"><a href="global.html#isInteger">isInteger</a></div><div class="sidebar-section-children"><a href="global.html#isNumber">isNumber</a></div><div class="sidebar-section-children"><a href="global.html#isSafeNumber">isSafeNumber</a></div><div class="sidebar-section-children"><a href="global.html#json">json</a></div><div class="sidebar-section-children"><a href="global.html#toSafeNumberOrThrow">toSafeNumberOrThrow</a></div></div></div><div class="mobile-navbar-actions"><div class="navbar-right-item"><button class="icon-button home-button" aria-label="go-to-homepage"><svg><use xlink:href="#home-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button search-button" aria-label="open-search"><svg><use xlink:href="#search-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button theme-toggle" aria-label="toggle-theme"><svg><use class="theme-svg-use" xlink:href="#light-theme-icon"></use></svg></button></div><div class="navbar-right-item"><button class="icon-button font-size" aria-label="change-font-size"><svg><use xlink:href="#font-size-icon"></use></svg></button></div></div></div></div><script type="text/javascript" src="scripts/core.min.js"></script><script src="scripts/search.min.js" defer="defer"></script><script src="scripts/third-party/fuse.js" defer="defer"></script><script type="text/javascript">var tocbotInstance=tocbot.init({tocSelector:"#eed4d2a0bfd64539bb9df78095dec881",contentSelector:".main-content",headingSelector:"h1, h2, h3",hasInnerContainers:!0,scrollContainer:".main-content",headingsOffset:130,onClick:bringLinkToView})</script><script>document.addEventListener("DOMContentLoaded",function(){"undefined"!=typeof tippy&&(tippy(".home-button",{content:"回到首页",delay:500}),tippy(".theme-toggle",{content:"切换主题",delay:500}),tippy(".search-button",{content:"搜索",delay:500}),tippy(".font-size",{content:"更改字体大小",delay:500}))})</script></body></html>