@kg-ui/kg-ui-plus 0.0.0
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/README.md +39 -0
- package/dist/es/KgCopilot/CopiContent/AnswerHead.vue.mjs +16 -0
- package/dist/es/KgCopilot/CopiContent/AnswerHead.vue2.mjs +4 -0
- package/dist/es/KgCopilot/CopiContent/UserHead.vue.mjs +26 -0
- package/dist/es/KgCopilot/CopiContent/UserHead.vue2.mjs +4 -0
- package/dist/es/KgCopilot/CopiFooter/components/NewTheme.vue.mjs +7 -0
- package/dist/es/KgCopilot/CopiFooter/components/NewTheme.vue2.mjs +49 -0
- package/dist/es/KgCopilot/CopiFooter/components/NewTheme.vue3.mjs +4 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/SelectPlugin.vue.mjs +7 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/SelectPlugin.vue2.mjs +94 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/SelectPlugin.vue3.mjs +4 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/SpeechControl.vue.mjs +7 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/SpeechControl.vue2.mjs +33 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/SpeechControl.vue3.mjs +4 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/Upload.vue.mjs +7 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/Upload.vue2.mjs +140 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/Upload.vue3.mjs +4 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/index.vue.mjs +7 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/index.vue2.mjs +131 -0
- package/dist/es/KgCopilot/CopiFooter/components/SearchInput/index.vue3.mjs +4 -0
- package/dist/es/KgCopilot/CopiFooter/index.vue.mjs +7 -0
- package/dist/es/KgCopilot/CopiFooter/index.vue2.mjs +21 -0
- package/dist/es/KgCopilot/CopiFooter/index.vue3.mjs +4 -0
- package/dist/es/KgCopilot/dialogue.vue.mjs +7 -0
- package/dist/es/KgCopilot/dialogue.vue2.mjs +131 -0
- package/dist/es/KgCopilot/dialogue.vue3.mjs +4 -0
- package/dist/es/KgCopilot/index.vue.mjs +7 -0
- package/dist/es/KgCopilot/index.vue2.mjs +49 -0
- package/dist/es/KgCopilot/index.vue3.mjs +4 -0
- package/dist/es/KgCopilot/mdInCode.mjs +56 -0
- package/dist/es/KgCopilot/readMd.vue.mjs +7 -0
- package/dist/es/KgCopilot/readMd.vue2.mjs +87 -0
- package/dist/es/KgCopilot/readMd.vue3.mjs +4 -0
- package/dist/es/ReIcon/index.mjs +11 -0
- package/dist/es/ReIcon/src/iconfont.mjs +46 -0
- package/dist/es/ReIcon/src/iconifyIconOffline.mjs +30 -0
- package/dist/es/ReIcon/src/iconifyIconOnline.mjs +29 -0
- package/dist/es/_virtual/___vite-browser-external.mjs +6 -0
- package/dist/es/_virtual/__vite-browser-external.mjs +4 -0
- package/dist/es/_virtual/_commonjsHelpers.mjs +34 -0
- package/dist/es/_virtual/_plugin-vue_export-helper.mjs +10 -0
- package/dist/es/_virtual/index.mjs +13 -0
- package/dist/es/api/project.mjs +51 -0
- package/dist/es/directives/heighlight/index.mjs +69 -0
- package/dist/es/directives/index.mjs +4 -0
- package/dist/es/home/LFilter/FilterArea.vue.mjs +7 -0
- package/dist/es/home/LFilter/FilterArea.vue2.mjs +507 -0
- package/dist/es/home/LFilter/FilterArea.vue3.mjs +4 -0
- package/dist/es/home/LFilter/FilterHead.vue.mjs +129 -0
- package/dist/es/home/LFilter/FilterHead.vue2.mjs +4 -0
- package/dist/es/home/LFilter/FilterItem.vue.mjs +7 -0
- package/dist/es/home/LFilter/FilterItem.vue2.mjs +114 -0
- package/dist/es/home/LFilter/FilterItem.vue3.mjs +4 -0
- package/dist/es/home/LFilter/FilterItemIcon.vue.mjs +7 -0
- package/dist/es/home/LFilter/FilterItemIcon.vue2.mjs +171 -0
- package/dist/es/home/LFilter/FilterItemIcon.vue3.mjs +4 -0
- package/dist/es/home/LFilter/index.vue.mjs +17 -0
- package/dist/es/home/LFilter/index.vue2.mjs +4 -0
- package/dist/es/home/LProject/index.vue.mjs +7 -0
- package/dist/es/home/LProject/index.vue2.mjs +70 -0
- package/dist/es/home/LProject/index.vue3.mjs +4 -0
- package/dist/es/home/index.vue.mjs +7 -0
- package/dist/es/home/index.vue2.mjs +80 -0
- package/dist/es/home/index.vue3.mjs +4 -0
- package/dist/es/index.mjs +36 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ep@1.2.7/node_modules/@iconify-icons/ep/check.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ep@1.2.7/node_modules/@iconify-icons/ep/circle-plus.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ep@1.2.7/node_modules/@iconify-icons/ep/close.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ep@1.2.7/node_modules/@iconify-icons/ep/microphone.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ep@1.2.7/node_modules/@iconify-icons/ep/paperclip.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ep@1.2.7/node_modules/@iconify-icons/ep/promotion.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ep@1.2.7/node_modules/@iconify-icons/ep/upload.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ph@1.2.5/node_modules/@iconify-icons/ph/copy-simple.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ph@1.2.5/node_modules/@iconify-icons/ph/speaker-high-light.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ph@1.2.5/node_modules/@iconify-icons/ph/thumbs-down-thin.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ph@1.2.5/node_modules/@iconify-icons/ph/thumbs-up-thin.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ph@1.2.5/node_modules/@iconify-icons/ph/warning-bold.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ri@1.2.3/node_modules/@iconify-icons/ri/add-line.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ri@1.2.3/node_modules/@iconify-icons/ri/arrow-down-s-line.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ri@1.2.3/node_modules/@iconify-icons/ri/arrow-up-s-line.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ri@1.2.3/node_modules/@iconify-icons/ri/check-fill.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ri@1.2.3/node_modules/@iconify-icons/ri/download-line.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify-icons_ri@1.2.3/node_modules/@iconify-icons/ri/more-2-fill.mjs +8 -0
- package/dist/es/node_modules/.pnpm/@iconify_vue@4.0.0_vue@3.2.45/node_modules/@iconify/vue/dist/iconify.mjs +1702 -0
- package/dist/es/node_modules/.pnpm/@iconify_vue@4.0.0_vue@3.2.45/node_modules/@iconify/vue/dist/offline.mjs +436 -0
- package/dist/es/node_modules/.pnpm/@pureadmin_utils@1.8.5_vue@3.2.45/node_modules/@pureadmin/utils/dist/index.mjs +70 -0
- package/dist/es/node_modules/.pnpm/call-bind@1.0.7/node_modules/call-bind/callBound.mjs +16 -0
- package/dist/es/node_modules/.pnpm/call-bind@1.0.7/node_modules/call-bind/index.mjs +36 -0
- package/dist/es/node_modules/.pnpm/define-data-property@1.1.4/node_modules/define-data-property/index.mjs +48 -0
- package/dist/es/node_modules/.pnpm/dompurify@3.0.10/node_modules/dompurify/dist/purify.es.mjs +949 -0
- package/dist/es/node_modules/.pnpm/es-define-property@1.0.0/node_modules/es-define-property/index.mjs +22 -0
- package/dist/es/node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/eval.mjs +4 -0
- package/dist/es/node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/index.mjs +4 -0
- package/dist/es/node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/range.mjs +4 -0
- package/dist/es/node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/ref.mjs +4 -0
- package/dist/es/node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/syntax.mjs +4 -0
- package/dist/es/node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/type.mjs +4 -0
- package/dist/es/node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/uri.mjs +4 -0
- package/dist/es/node_modules/.pnpm/function-bind@1.1.2/node_modules/function-bind/implementation.mjs +72 -0
- package/dist/es/node_modules/.pnpm/function-bind@1.1.2/node_modules/function-bind/index.mjs +6 -0
- package/dist/es/node_modules/.pnpm/get-intrinsic@1.2.4/node_modules/get-intrinsic/index.mjs +320 -0
- package/dist/es/node_modules/.pnpm/gopd@1.0.1/node_modules/gopd/index.mjs +14 -0
- package/dist/es/node_modules/.pnpm/has-property-descriptors@1.0.2/node_modules/has-property-descriptors/index.mjs +19 -0
- package/dist/es/node_modules/.pnpm/has-proto@1.0.3/node_modules/has-proto/index.mjs +11 -0
- package/dist/es/node_modules/.pnpm/has-symbols@1.0.3/node_modules/has-symbols/index.mjs +21 -0
- package/dist/es/node_modules/.pnpm/has-symbols@1.0.3/node_modules/has-symbols/shams.mjs +48 -0
- package/dist/es/node_modules/.pnpm/hasown@2.0.2/node_modules/hasown/index.mjs +8 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/core.mjs +5 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/apache.mjs +91 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/bash.mjs +377 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/basic.mjs +221 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/c.mjs +280 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/css.mjs +732 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/dart.mjs +247 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/django.mjs +47 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/dns.mjs +71 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/dos.mjs +160 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/dust.mjs +38 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/erlang.mjs +176 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/go.mjs +135 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/http.mjs +89 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/java.mjs +254 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/javascript.mjs +698 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/json.mjs +40 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/markdown.mjs +227 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/nginx.mjs +144 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/php.mjs +589 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/python.mjs +414 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/ruby.mjs +414 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/stylus.mjs +766 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/swift.mjs +832 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/typescript.mjs +788 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/es/languages/xml.mjs +227 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/lib/core.mjs +1580 -0
- package/dist/es/node_modules/.pnpm/highlight.js@11.9.0/node_modules/highlight.js/styles/paraiso-light.css.mjs +4 -0
- package/dist/es/node_modules/.pnpm/marked@12.0.1/node_modules/marked/lib/marked.esm.mjs +2045 -0
- package/dist/es/node_modules/.pnpm/object-inspect@1.13.1/node_modules/object-inspect/index.mjs +514 -0
- package/dist/es/node_modules/.pnpm/pinyin-match@1.2.4/node_modules/pinyin-match/es/main.mjs +124 -0
- package/dist/es/node_modules/.pnpm/qs@6.11.0/node_modules/qs/lib/formats.mjs +22 -0
- package/dist/es/node_modules/.pnpm/qs@6.11.0/node_modules/qs/lib/index.mjs +14 -0
- package/dist/es/node_modules/.pnpm/qs@6.11.0/node_modules/qs/lib/parse.mjs +199 -0
- package/dist/es/node_modules/.pnpm/qs@6.11.0/node_modules/qs/lib/stringify.mjs +262 -0
- package/dist/es/node_modules/.pnpm/qs@6.11.0/node_modules/qs/lib/utils.mjs +196 -0
- package/dist/es/node_modules/.pnpm/set-function-length@1.2.2/node_modules/set-function-length/index.mjs +54 -0
- package/dist/es/node_modules/.pnpm/side-channel@1.0.6/node_modules/side-channel/index.mjs +115 -0
- package/dist/es/store/index.mjs +8 -0
- package/dist/es/store/modules/copilot.mjs +108 -0
- package/dist/es/store/modules/filters.mjs +346 -0
- package/dist/es/store/modules/types.mjs +19 -0
- package/dist/es/style/index.scss.mjs +4 -0
- package/dist/es/style/tailwind.css.mjs +4 -0
- package/dist/es/style.css +1 -0
- package/dist/es/utils/home.mjs +129 -0
- package/dist/es/utils/http/index.mjs +90 -0
- package/dist/es/utils/message.mjs +42 -0
- package/package.json +124 -0
package/dist/es/node_modules/.pnpm/object-inspect@1.13.1/node_modules/object-inspect/index.mjs
ADDED
@@ -0,0 +1,514 @@
|
|
1
|
+
import { commonjsGlobal } from "../../../../../_virtual/_commonjsHelpers.mjs";
|
2
|
+
import require$$0 from "../../../../../_virtual/___vite-browser-external.mjs";
|
3
|
+
var hasMap = typeof Map === "function" && Map.prototype;
|
4
|
+
var mapSizeDescriptor = Object.getOwnPropertyDescriptor && hasMap ? Object.getOwnPropertyDescriptor(Map.prototype, "size") : null;
|
5
|
+
var mapSize = hasMap && mapSizeDescriptor && typeof mapSizeDescriptor.get === "function" ? mapSizeDescriptor.get : null;
|
6
|
+
var mapForEach = hasMap && Map.prototype.forEach;
|
7
|
+
var hasSet = typeof Set === "function" && Set.prototype;
|
8
|
+
var setSizeDescriptor = Object.getOwnPropertyDescriptor && hasSet ? Object.getOwnPropertyDescriptor(Set.prototype, "size") : null;
|
9
|
+
var setSize = hasSet && setSizeDescriptor && typeof setSizeDescriptor.get === "function" ? setSizeDescriptor.get : null;
|
10
|
+
var setForEach = hasSet && Set.prototype.forEach;
|
11
|
+
var hasWeakMap = typeof WeakMap === "function" && WeakMap.prototype;
|
12
|
+
var weakMapHas = hasWeakMap ? WeakMap.prototype.has : null;
|
13
|
+
var hasWeakSet = typeof WeakSet === "function" && WeakSet.prototype;
|
14
|
+
var weakSetHas = hasWeakSet ? WeakSet.prototype.has : null;
|
15
|
+
var hasWeakRef = typeof WeakRef === "function" && WeakRef.prototype;
|
16
|
+
var weakRefDeref = hasWeakRef ? WeakRef.prototype.deref : null;
|
17
|
+
var booleanValueOf = Boolean.prototype.valueOf;
|
18
|
+
var objectToString = Object.prototype.toString;
|
19
|
+
var functionToString = Function.prototype.toString;
|
20
|
+
var $match = String.prototype.match;
|
21
|
+
var $slice = String.prototype.slice;
|
22
|
+
var $replace = String.prototype.replace;
|
23
|
+
var $toUpperCase = String.prototype.toUpperCase;
|
24
|
+
var $toLowerCase = String.prototype.toLowerCase;
|
25
|
+
var $test = RegExp.prototype.test;
|
26
|
+
var $concat = Array.prototype.concat;
|
27
|
+
var $join = Array.prototype.join;
|
28
|
+
var $arrSlice = Array.prototype.slice;
|
29
|
+
var $floor = Math.floor;
|
30
|
+
var bigIntValueOf = typeof BigInt === "function" ? BigInt.prototype.valueOf : null;
|
31
|
+
var gOPS = Object.getOwnPropertySymbols;
|
32
|
+
var symToString = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? Symbol.prototype.toString : null;
|
33
|
+
var hasShammedSymbols = typeof Symbol === "function" && typeof Symbol.iterator === "object";
|
34
|
+
var toStringTag = typeof Symbol === "function" && Symbol.toStringTag && (typeof Symbol.toStringTag === hasShammedSymbols ? "object" : "symbol") ? Symbol.toStringTag : null;
|
35
|
+
var isEnumerable = Object.prototype.propertyIsEnumerable;
|
36
|
+
var gPO = (typeof Reflect === "function" ? Reflect.getPrototypeOf : Object.getPrototypeOf) || ([].__proto__ === Array.prototype ? function(O) {
|
37
|
+
return O.__proto__;
|
38
|
+
} : null);
|
39
|
+
function addNumericSeparator(num, str) {
|
40
|
+
if (num === Infinity || num === -Infinity || num !== num || num && num > -1e3 && num < 1e3 || $test.call(/e/, str)) {
|
41
|
+
return str;
|
42
|
+
}
|
43
|
+
var sepRegex = /[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;
|
44
|
+
if (typeof num === "number") {
|
45
|
+
var int = num < 0 ? -$floor(-num) : $floor(num);
|
46
|
+
if (int !== num) {
|
47
|
+
var intStr = String(int);
|
48
|
+
var dec = $slice.call(str, intStr.length + 1);
|
49
|
+
return $replace.call(intStr, sepRegex, "$&_") + "." + $replace.call($replace.call(dec, /([0-9]{3})/g, "$&_"), /_$/, "");
|
50
|
+
}
|
51
|
+
}
|
52
|
+
return $replace.call(str, sepRegex, "$&_");
|
53
|
+
}
|
54
|
+
var utilInspect = require$$0;
|
55
|
+
var inspectCustom = utilInspect.custom;
|
56
|
+
var inspectSymbol = isSymbol(inspectCustom) ? inspectCustom : null;
|
57
|
+
var objectInspect = function inspect_(obj, options, depth, seen) {
|
58
|
+
var opts = options || {};
|
59
|
+
if (has(opts, "quoteStyle") && (opts.quoteStyle !== "single" && opts.quoteStyle !== "double")) {
|
60
|
+
throw new TypeError('option "quoteStyle" must be "single" or "double"');
|
61
|
+
}
|
62
|
+
if (has(opts, "maxStringLength") && (typeof opts.maxStringLength === "number" ? opts.maxStringLength < 0 && opts.maxStringLength !== Infinity : opts.maxStringLength !== null)) {
|
63
|
+
throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');
|
64
|
+
}
|
65
|
+
var customInspect = has(opts, "customInspect") ? opts.customInspect : true;
|
66
|
+
if (typeof customInspect !== "boolean" && customInspect !== "symbol") {
|
67
|
+
throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");
|
68
|
+
}
|
69
|
+
if (has(opts, "indent") && opts.indent !== null && opts.indent !== " " && !(parseInt(opts.indent, 10) === opts.indent && opts.indent > 0)) {
|
70
|
+
throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');
|
71
|
+
}
|
72
|
+
if (has(opts, "numericSeparator") && typeof opts.numericSeparator !== "boolean") {
|
73
|
+
throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');
|
74
|
+
}
|
75
|
+
var numericSeparator = opts.numericSeparator;
|
76
|
+
if (typeof obj === "undefined") {
|
77
|
+
return "undefined";
|
78
|
+
}
|
79
|
+
if (obj === null) {
|
80
|
+
return "null";
|
81
|
+
}
|
82
|
+
if (typeof obj === "boolean") {
|
83
|
+
return obj ? "true" : "false";
|
84
|
+
}
|
85
|
+
if (typeof obj === "string") {
|
86
|
+
return inspectString(obj, opts);
|
87
|
+
}
|
88
|
+
if (typeof obj === "number") {
|
89
|
+
if (obj === 0) {
|
90
|
+
return Infinity / obj > 0 ? "0" : "-0";
|
91
|
+
}
|
92
|
+
var str = String(obj);
|
93
|
+
return numericSeparator ? addNumericSeparator(obj, str) : str;
|
94
|
+
}
|
95
|
+
if (typeof obj === "bigint") {
|
96
|
+
var bigIntStr = String(obj) + "n";
|
97
|
+
return numericSeparator ? addNumericSeparator(obj, bigIntStr) : bigIntStr;
|
98
|
+
}
|
99
|
+
var maxDepth = typeof opts.depth === "undefined" ? 5 : opts.depth;
|
100
|
+
if (typeof depth === "undefined") {
|
101
|
+
depth = 0;
|
102
|
+
}
|
103
|
+
if (depth >= maxDepth && maxDepth > 0 && typeof obj === "object") {
|
104
|
+
return isArray(obj) ? "[Array]" : "[Object]";
|
105
|
+
}
|
106
|
+
var indent = getIndent(opts, depth);
|
107
|
+
if (typeof seen === "undefined") {
|
108
|
+
seen = [];
|
109
|
+
} else if (indexOf(seen, obj) >= 0) {
|
110
|
+
return "[Circular]";
|
111
|
+
}
|
112
|
+
function inspect(value, from, noIndent) {
|
113
|
+
if (from) {
|
114
|
+
seen = $arrSlice.call(seen);
|
115
|
+
seen.push(from);
|
116
|
+
}
|
117
|
+
if (noIndent) {
|
118
|
+
var newOpts = {
|
119
|
+
depth: opts.depth
|
120
|
+
};
|
121
|
+
if (has(opts, "quoteStyle")) {
|
122
|
+
newOpts.quoteStyle = opts.quoteStyle;
|
123
|
+
}
|
124
|
+
return inspect_(value, newOpts, depth + 1, seen);
|
125
|
+
}
|
126
|
+
return inspect_(value, opts, depth + 1, seen);
|
127
|
+
}
|
128
|
+
if (typeof obj === "function" && !isRegExp(obj)) {
|
129
|
+
var name = nameOf(obj);
|
130
|
+
var keys = arrObjKeys(obj, inspect);
|
131
|
+
return "[Function" + (name ? ": " + name : " (anonymous)") + "]" + (keys.length > 0 ? " { " + $join.call(keys, ", ") + " }" : "");
|
132
|
+
}
|
133
|
+
if (isSymbol(obj)) {
|
134
|
+
var symString = hasShammedSymbols ? $replace.call(String(obj), /^(Symbol\(.*\))_[^)]*$/, "$1") : symToString.call(obj);
|
135
|
+
return typeof obj === "object" && !hasShammedSymbols ? markBoxed(symString) : symString;
|
136
|
+
}
|
137
|
+
if (isElement(obj)) {
|
138
|
+
var s = "<" + $toLowerCase.call(String(obj.nodeName));
|
139
|
+
var attrs = obj.attributes || [];
|
140
|
+
for (var i = 0; i < attrs.length; i++) {
|
141
|
+
s += " " + attrs[i].name + "=" + wrapQuotes(quote(attrs[i].value), "double", opts);
|
142
|
+
}
|
143
|
+
s += ">";
|
144
|
+
if (obj.childNodes && obj.childNodes.length) {
|
145
|
+
s += "...";
|
146
|
+
}
|
147
|
+
s += "</" + $toLowerCase.call(String(obj.nodeName)) + ">";
|
148
|
+
return s;
|
149
|
+
}
|
150
|
+
if (isArray(obj)) {
|
151
|
+
if (obj.length === 0) {
|
152
|
+
return "[]";
|
153
|
+
}
|
154
|
+
var xs = arrObjKeys(obj, inspect);
|
155
|
+
if (indent && !singleLineValues(xs)) {
|
156
|
+
return "[" + indentedJoin(xs, indent) + "]";
|
157
|
+
}
|
158
|
+
return "[ " + $join.call(xs, ", ") + " ]";
|
159
|
+
}
|
160
|
+
if (isError(obj)) {
|
161
|
+
var parts = arrObjKeys(obj, inspect);
|
162
|
+
if (!("cause" in Error.prototype) && "cause" in obj && !isEnumerable.call(obj, "cause")) {
|
163
|
+
return "{ [" + String(obj) + "] " + $join.call($concat.call("[cause]: " + inspect(obj.cause), parts), ", ") + " }";
|
164
|
+
}
|
165
|
+
if (parts.length === 0) {
|
166
|
+
return "[" + String(obj) + "]";
|
167
|
+
}
|
168
|
+
return "{ [" + String(obj) + "] " + $join.call(parts, ", ") + " }";
|
169
|
+
}
|
170
|
+
if (typeof obj === "object" && customInspect) {
|
171
|
+
if (inspectSymbol && typeof obj[inspectSymbol] === "function" && utilInspect) {
|
172
|
+
return utilInspect(obj, { depth: maxDepth - depth });
|
173
|
+
} else if (customInspect !== "symbol" && typeof obj.inspect === "function") {
|
174
|
+
return obj.inspect();
|
175
|
+
}
|
176
|
+
}
|
177
|
+
if (isMap(obj)) {
|
178
|
+
var mapParts = [];
|
179
|
+
if (mapForEach) {
|
180
|
+
mapForEach.call(obj, function(value, key) {
|
181
|
+
mapParts.push(inspect(key, obj, true) + " => " + inspect(value, obj));
|
182
|
+
});
|
183
|
+
}
|
184
|
+
return collectionOf("Map", mapSize.call(obj), mapParts, indent);
|
185
|
+
}
|
186
|
+
if (isSet(obj)) {
|
187
|
+
var setParts = [];
|
188
|
+
if (setForEach) {
|
189
|
+
setForEach.call(obj, function(value) {
|
190
|
+
setParts.push(inspect(value, obj));
|
191
|
+
});
|
192
|
+
}
|
193
|
+
return collectionOf("Set", setSize.call(obj), setParts, indent);
|
194
|
+
}
|
195
|
+
if (isWeakMap(obj)) {
|
196
|
+
return weakCollectionOf("WeakMap");
|
197
|
+
}
|
198
|
+
if (isWeakSet(obj)) {
|
199
|
+
return weakCollectionOf("WeakSet");
|
200
|
+
}
|
201
|
+
if (isWeakRef(obj)) {
|
202
|
+
return weakCollectionOf("WeakRef");
|
203
|
+
}
|
204
|
+
if (isNumber(obj)) {
|
205
|
+
return markBoxed(inspect(Number(obj)));
|
206
|
+
}
|
207
|
+
if (isBigInt(obj)) {
|
208
|
+
return markBoxed(inspect(bigIntValueOf.call(obj)));
|
209
|
+
}
|
210
|
+
if (isBoolean(obj)) {
|
211
|
+
return markBoxed(booleanValueOf.call(obj));
|
212
|
+
}
|
213
|
+
if (isString(obj)) {
|
214
|
+
return markBoxed(inspect(String(obj)));
|
215
|
+
}
|
216
|
+
if (typeof window !== "undefined" && obj === window) {
|
217
|
+
return "{ [object Window] }";
|
218
|
+
}
|
219
|
+
if (obj === commonjsGlobal) {
|
220
|
+
return "{ [object globalThis] }";
|
221
|
+
}
|
222
|
+
if (!isDate(obj) && !isRegExp(obj)) {
|
223
|
+
var ys = arrObjKeys(obj, inspect);
|
224
|
+
var isPlainObject = gPO ? gPO(obj) === Object.prototype : obj instanceof Object || obj.constructor === Object;
|
225
|
+
var protoTag = obj instanceof Object ? "" : "null prototype";
|
226
|
+
var stringTag = !isPlainObject && toStringTag && Object(obj) === obj && toStringTag in obj ? $slice.call(toStr(obj), 8, -1) : protoTag ? "Object" : "";
|
227
|
+
var constructorTag = isPlainObject || typeof obj.constructor !== "function" ? "" : obj.constructor.name ? obj.constructor.name + " " : "";
|
228
|
+
var tag = constructorTag + (stringTag || protoTag ? "[" + $join.call($concat.call([], stringTag || [], protoTag || []), ": ") + "] " : "");
|
229
|
+
if (ys.length === 0) {
|
230
|
+
return tag + "{}";
|
231
|
+
}
|
232
|
+
if (indent) {
|
233
|
+
return tag + "{" + indentedJoin(ys, indent) + "}";
|
234
|
+
}
|
235
|
+
return tag + "{ " + $join.call(ys, ", ") + " }";
|
236
|
+
}
|
237
|
+
return String(obj);
|
238
|
+
};
|
239
|
+
function wrapQuotes(s, defaultStyle, opts) {
|
240
|
+
var quoteChar = (opts.quoteStyle || defaultStyle) === "double" ? '"' : "'";
|
241
|
+
return quoteChar + s + quoteChar;
|
242
|
+
}
|
243
|
+
function quote(s) {
|
244
|
+
return $replace.call(String(s), /"/g, """);
|
245
|
+
}
|
246
|
+
function isArray(obj) {
|
247
|
+
return toStr(obj) === "[object Array]" && (!toStringTag || !(typeof obj === "object" && toStringTag in obj));
|
248
|
+
}
|
249
|
+
function isDate(obj) {
|
250
|
+
return toStr(obj) === "[object Date]" && (!toStringTag || !(typeof obj === "object" && toStringTag in obj));
|
251
|
+
}
|
252
|
+
function isRegExp(obj) {
|
253
|
+
return toStr(obj) === "[object RegExp]" && (!toStringTag || !(typeof obj === "object" && toStringTag in obj));
|
254
|
+
}
|
255
|
+
function isError(obj) {
|
256
|
+
return toStr(obj) === "[object Error]" && (!toStringTag || !(typeof obj === "object" && toStringTag in obj));
|
257
|
+
}
|
258
|
+
function isString(obj) {
|
259
|
+
return toStr(obj) === "[object String]" && (!toStringTag || !(typeof obj === "object" && toStringTag in obj));
|
260
|
+
}
|
261
|
+
function isNumber(obj) {
|
262
|
+
return toStr(obj) === "[object Number]" && (!toStringTag || !(typeof obj === "object" && toStringTag in obj));
|
263
|
+
}
|
264
|
+
function isBoolean(obj) {
|
265
|
+
return toStr(obj) === "[object Boolean]" && (!toStringTag || !(typeof obj === "object" && toStringTag in obj));
|
266
|
+
}
|
267
|
+
function isSymbol(obj) {
|
268
|
+
if (hasShammedSymbols) {
|
269
|
+
return obj && typeof obj === "object" && obj instanceof Symbol;
|
270
|
+
}
|
271
|
+
if (typeof obj === "symbol") {
|
272
|
+
return true;
|
273
|
+
}
|
274
|
+
if (!obj || typeof obj !== "object" || !symToString) {
|
275
|
+
return false;
|
276
|
+
}
|
277
|
+
try {
|
278
|
+
symToString.call(obj);
|
279
|
+
return true;
|
280
|
+
} catch (e) {
|
281
|
+
}
|
282
|
+
return false;
|
283
|
+
}
|
284
|
+
function isBigInt(obj) {
|
285
|
+
if (!obj || typeof obj !== "object" || !bigIntValueOf) {
|
286
|
+
return false;
|
287
|
+
}
|
288
|
+
try {
|
289
|
+
bigIntValueOf.call(obj);
|
290
|
+
return true;
|
291
|
+
} catch (e) {
|
292
|
+
}
|
293
|
+
return false;
|
294
|
+
}
|
295
|
+
var hasOwn = Object.prototype.hasOwnProperty || function(key) {
|
296
|
+
return key in this;
|
297
|
+
};
|
298
|
+
function has(obj, key) {
|
299
|
+
return hasOwn.call(obj, key);
|
300
|
+
}
|
301
|
+
function toStr(obj) {
|
302
|
+
return objectToString.call(obj);
|
303
|
+
}
|
304
|
+
function nameOf(f) {
|
305
|
+
if (f.name) {
|
306
|
+
return f.name;
|
307
|
+
}
|
308
|
+
var m = $match.call(functionToString.call(f), /^function\s*([\w$]+)/);
|
309
|
+
if (m) {
|
310
|
+
return m[1];
|
311
|
+
}
|
312
|
+
return null;
|
313
|
+
}
|
314
|
+
function indexOf(xs, x) {
|
315
|
+
if (xs.indexOf) {
|
316
|
+
return xs.indexOf(x);
|
317
|
+
}
|
318
|
+
for (var i = 0, l = xs.length; i < l; i++) {
|
319
|
+
if (xs[i] === x) {
|
320
|
+
return i;
|
321
|
+
}
|
322
|
+
}
|
323
|
+
return -1;
|
324
|
+
}
|
325
|
+
function isMap(x) {
|
326
|
+
if (!mapSize || !x || typeof x !== "object") {
|
327
|
+
return false;
|
328
|
+
}
|
329
|
+
try {
|
330
|
+
mapSize.call(x);
|
331
|
+
try {
|
332
|
+
setSize.call(x);
|
333
|
+
} catch (s) {
|
334
|
+
return true;
|
335
|
+
}
|
336
|
+
return x instanceof Map;
|
337
|
+
} catch (e) {
|
338
|
+
}
|
339
|
+
return false;
|
340
|
+
}
|
341
|
+
function isWeakMap(x) {
|
342
|
+
if (!weakMapHas || !x || typeof x !== "object") {
|
343
|
+
return false;
|
344
|
+
}
|
345
|
+
try {
|
346
|
+
weakMapHas.call(x, weakMapHas);
|
347
|
+
try {
|
348
|
+
weakSetHas.call(x, weakSetHas);
|
349
|
+
} catch (s) {
|
350
|
+
return true;
|
351
|
+
}
|
352
|
+
return x instanceof WeakMap;
|
353
|
+
} catch (e) {
|
354
|
+
}
|
355
|
+
return false;
|
356
|
+
}
|
357
|
+
function isWeakRef(x) {
|
358
|
+
if (!weakRefDeref || !x || typeof x !== "object") {
|
359
|
+
return false;
|
360
|
+
}
|
361
|
+
try {
|
362
|
+
weakRefDeref.call(x);
|
363
|
+
return true;
|
364
|
+
} catch (e) {
|
365
|
+
}
|
366
|
+
return false;
|
367
|
+
}
|
368
|
+
function isSet(x) {
|
369
|
+
if (!setSize || !x || typeof x !== "object") {
|
370
|
+
return false;
|
371
|
+
}
|
372
|
+
try {
|
373
|
+
setSize.call(x);
|
374
|
+
try {
|
375
|
+
mapSize.call(x);
|
376
|
+
} catch (m) {
|
377
|
+
return true;
|
378
|
+
}
|
379
|
+
return x instanceof Set;
|
380
|
+
} catch (e) {
|
381
|
+
}
|
382
|
+
return false;
|
383
|
+
}
|
384
|
+
function isWeakSet(x) {
|
385
|
+
if (!weakSetHas || !x || typeof x !== "object") {
|
386
|
+
return false;
|
387
|
+
}
|
388
|
+
try {
|
389
|
+
weakSetHas.call(x, weakSetHas);
|
390
|
+
try {
|
391
|
+
weakMapHas.call(x, weakMapHas);
|
392
|
+
} catch (s) {
|
393
|
+
return true;
|
394
|
+
}
|
395
|
+
return x instanceof WeakSet;
|
396
|
+
} catch (e) {
|
397
|
+
}
|
398
|
+
return false;
|
399
|
+
}
|
400
|
+
function isElement(x) {
|
401
|
+
if (!x || typeof x !== "object") {
|
402
|
+
return false;
|
403
|
+
}
|
404
|
+
if (typeof HTMLElement !== "undefined" && x instanceof HTMLElement) {
|
405
|
+
return true;
|
406
|
+
}
|
407
|
+
return typeof x.nodeName === "string" && typeof x.getAttribute === "function";
|
408
|
+
}
|
409
|
+
function inspectString(str, opts) {
|
410
|
+
if (str.length > opts.maxStringLength) {
|
411
|
+
var remaining = str.length - opts.maxStringLength;
|
412
|
+
var trailer = "... " + remaining + " more character" + (remaining > 1 ? "s" : "");
|
413
|
+
return inspectString($slice.call(str, 0, opts.maxStringLength), opts) + trailer;
|
414
|
+
}
|
415
|
+
var s = $replace.call($replace.call(str, /(['\\])/g, "\\$1"), /[\x00-\x1f]/g, lowbyte);
|
416
|
+
return wrapQuotes(s, "single", opts);
|
417
|
+
}
|
418
|
+
function lowbyte(c) {
|
419
|
+
var n = c.charCodeAt(0);
|
420
|
+
var x = {
|
421
|
+
8: "b",
|
422
|
+
9: "t",
|
423
|
+
10: "n",
|
424
|
+
12: "f",
|
425
|
+
13: "r"
|
426
|
+
}[n];
|
427
|
+
if (x) {
|
428
|
+
return "\\" + x;
|
429
|
+
}
|
430
|
+
return "\\x" + (n < 16 ? "0" : "") + $toUpperCase.call(n.toString(16));
|
431
|
+
}
|
432
|
+
function markBoxed(str) {
|
433
|
+
return "Object(" + str + ")";
|
434
|
+
}
|
435
|
+
function weakCollectionOf(type) {
|
436
|
+
return type + " { ? }";
|
437
|
+
}
|
438
|
+
function collectionOf(type, size, entries, indent) {
|
439
|
+
var joinedEntries = indent ? indentedJoin(entries, indent) : $join.call(entries, ", ");
|
440
|
+
return type + " (" + size + ") {" + joinedEntries + "}";
|
441
|
+
}
|
442
|
+
function singleLineValues(xs) {
|
443
|
+
for (var i = 0; i < xs.length; i++) {
|
444
|
+
if (indexOf(xs[i], "\n") >= 0) {
|
445
|
+
return false;
|
446
|
+
}
|
447
|
+
}
|
448
|
+
return true;
|
449
|
+
}
|
450
|
+
function getIndent(opts, depth) {
|
451
|
+
var baseIndent;
|
452
|
+
if (opts.indent === " ") {
|
453
|
+
baseIndent = " ";
|
454
|
+
} else if (typeof opts.indent === "number" && opts.indent > 0) {
|
455
|
+
baseIndent = $join.call(Array(opts.indent + 1), " ");
|
456
|
+
} else {
|
457
|
+
return null;
|
458
|
+
}
|
459
|
+
return {
|
460
|
+
base: baseIndent,
|
461
|
+
prev: $join.call(Array(depth + 1), baseIndent)
|
462
|
+
};
|
463
|
+
}
|
464
|
+
function indentedJoin(xs, indent) {
|
465
|
+
if (xs.length === 0) {
|
466
|
+
return "";
|
467
|
+
}
|
468
|
+
var lineJoiner = "\n" + indent.prev + indent.base;
|
469
|
+
return lineJoiner + $join.call(xs, "," + lineJoiner) + "\n" + indent.prev;
|
470
|
+
}
|
471
|
+
function arrObjKeys(obj, inspect) {
|
472
|
+
var isArr = isArray(obj);
|
473
|
+
var xs = [];
|
474
|
+
if (isArr) {
|
475
|
+
xs.length = obj.length;
|
476
|
+
for (var i = 0; i < obj.length; i++) {
|
477
|
+
xs[i] = has(obj, i) ? inspect(obj[i], obj) : "";
|
478
|
+
}
|
479
|
+
}
|
480
|
+
var syms = typeof gOPS === "function" ? gOPS(obj) : [];
|
481
|
+
var symMap;
|
482
|
+
if (hasShammedSymbols) {
|
483
|
+
symMap = {};
|
484
|
+
for (var k = 0; k < syms.length; k++) {
|
485
|
+
symMap["$" + syms[k]] = syms[k];
|
486
|
+
}
|
487
|
+
}
|
488
|
+
for (var key in obj) {
|
489
|
+
if (!has(obj, key)) {
|
490
|
+
continue;
|
491
|
+
}
|
492
|
+
if (isArr && String(Number(key)) === key && key < obj.length) {
|
493
|
+
continue;
|
494
|
+
}
|
495
|
+
if (hasShammedSymbols && symMap["$" + key] instanceof Symbol) {
|
496
|
+
continue;
|
497
|
+
} else if ($test.call(/[^\w$]/, key)) {
|
498
|
+
xs.push(inspect(key, obj) + ": " + inspect(obj[key], obj));
|
499
|
+
} else {
|
500
|
+
xs.push(key + ": " + inspect(obj[key], obj));
|
501
|
+
}
|
502
|
+
}
|
503
|
+
if (typeof gOPS === "function") {
|
504
|
+
for (var j = 0; j < syms.length; j++) {
|
505
|
+
if (isEnumerable.call(obj, syms[j])) {
|
506
|
+
xs.push("[" + inspect(syms[j]) + "]: " + inspect(obj[syms[j]], obj));
|
507
|
+
}
|
508
|
+
}
|
509
|
+
}
|
510
|
+
return xs;
|
511
|
+
}
|
512
|
+
export {
|
513
|
+
objectInspect as default
|
514
|
+
};
|