UNPKG

@farris/ui-vue

Version:

Farris Vue, a Farris Design based Vue3 component library.

1,449 lines 167 kB
var Kt = Object.defineProperty; var en = (e, t, n) => t in e ? Kt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n; var Ae = (e, t, n) => en(e, typeof t != "symbol" ? t + "" : t, n); import { ref as k, computed as z, defineComponent as de, watch as $e, onUnmounted as tn, createVNode as d, withDirectives as nn, createTextVNode as q, resolveDirective as on, resolveComponent as rn, onMounted as je, mergeProps as sn, inject as Ne } from "vue"; import { isPlainObject as Ge, cloneDeep as Se, debounce as an } from "lodash-es"; import { getSchemaByType as ln, createPropsResolver as cn } from "../dynamic-resolver/index.esm.js"; import { DgControl as un, useDesignerComponent as dn } from "../designer-canvas/index.esm.js"; import { useGuid as mn, getCustomClass as re, getCustomStyle as se, useDateFormat as fn, EVENT_PROPERTY_TAB_IDS as pn, withInstall as gn } from "../common/index.esm.js"; import { FNotifyService as hn } from "../notify/index.esm.js"; import { createI18n as yn, useI18n as bn } from "vue-i18n"; import vn from "../popover/index.esm.js"; import Cn from "../input-group/index.esm.js"; import Sn from "../pagination/index.esm.js"; import { BaseControlProperty as xn } from "../property-panel/index.esm.js"; const Tn = "https://json-schema.org/draft/2020-12/schema", wn = "https://farris-design.gitee.io/comment.schema.json", En = "comment", On = "A Farris Component", Dn = "object", Pn = { id: { description: "The unique identifier for comment", type: "string" }, type: { description: "The type string of comment", type: "string", default: "comment" }, appearance: { description: "", type: "object", properties: { class: { type: "string" }, style: { type: "string" } }, default: {} }, personSearchUrl: { description: "", type: "string" }, replyUser: { description: "", type: "object" }, personnels: { description: "", type: "object", default: [] }, editorHeight: { description: "", type: "number" }, editorClass: { description: "", type: "string" }, editorStyle: { description: "", type: "string" }, editorVisible: { description: "", type: "boolean", default: !0 }, listClass: { description: "", type: "string" }, listStyle: { description: "", type: "string" }, listVisible: { description: "", type: "boolean", default: !0 } }, kn = [ "id", "type" ], An = { onValueChange: "提交评论事件", onQueryFrequentAtUsers: "加载常用@人员事件", onQueryComments: "获取评论" }, pt = { $schema: Tn, $id: wn, title: En, description: On, type: Dn, properties: Pn, required: kn, events: An }; function gt(e, t) { let n; function o(u) { const { properties: h, title: b, ignore: a } = u, g = a && Array.isArray(a), p = Object.keys(h).reduce((C, x) => ((!g || !a.find((w) => w === x)) && (C[x] = h[x].type === "object" && h[x].properties ? o(h[x]) : Se(h[x].default)), C), {}); if (b && (!g || !a.find((C) => C === "id"))) { const C = b.toLowerCase().replace(/-/g, "_"); p.id = `${C}_${Math.random().toString().slice(2, 6)}`; } return p; } function r(u) { const { properties: h, title: b, required: a } = u; if (a && Array.isArray(a)) { const g = a.reduce((p, C) => (p[C] = h[C].type === "object" && h[C].properties ? o(h[C]) : Se(h[C].default), p), {}); if (b && a.find((p) => p === "id")) { const p = b.toLowerCase().replace(/-/g, "_"); g.id = `${p}_${Math.random().toString().slice(2, 6)}`; } return g; } return { type: b }; } function i(u, h = {}, b) { const a = e[u]; if (a) { let g = r(a); const p = t[u]; return g = p ? p({ getSchemaByType: i }, g, h, b) : g, n != null && n.appendIdentifyForNewControl && n.appendIdentifyForNewControl(g), g; } return null; } function s(u, h) { const b = o(h); return Object.keys(b).reduce((a, g) => (Object.prototype.hasOwnProperty.call(u, g) && (a[g] && Ge(a[g]) && Ge(u[g] || !u[g]) ? Object.assign(a[g], u[g] || {}) : a[g] = u[g]), a), b), b; } function c(u, h) { return Object.keys(u).filter((a) => u[a] != null).reduce((a, g) => { if (h.has(g)) { const p = h.get(g); if (typeof p == "string") a[p] = u[g]; else { const C = p(g, u[g], u); Object.assign(a, C); } } else a[g] = u[g]; return a; }, {}); } function y(u, h, b = /* @__PURE__ */ new Map()) { const a = s(u, h); return c(a, b); } function f(u) { var b; const h = u.type; if (h) { const a = e[h]; if (!a) return u; const g = s(u, a), p = ((b = u.editor) == null ? void 0 : b.type) || ""; if (p) { const C = e[p], x = s(u.editor, C); g.editor = x; } return g; } return u; } function l(u) { n = u; } return { getSchemaByType: i, resolveSchemaWithDefaultValue: f, resolveSchemaToProps: y, mappingSchemaToProps: c, setDesignerContext: l }; } const ht = {}, yt = {}, { resolveSchemaWithDefaultValue: Fn, resolveSchemaToProps: Ln, mappingSchemaToProps: Rn } = gt(ht, yt); function Nn(e = {}) { function t(f, l, u, h) { if (typeof u == "number") return h[f].length === u; if (typeof u == "object") { const b = Object.keys(u)[0], a = u[b]; if (b === "not") return Number(h[f].length) !== Number(a); if (b === "moreThan") return Number(h[f].length) >= Number(a); if (b === "lessThan") return Number(h[f].length) <= Number(a); } return !1; } function n(f, l, u, h) { return h[f] && h[f].propertyValue && String(h[f].propertyValue.value) === String(u); } const o = /* @__PURE__ */ new Map([ ["length", t], ["getProperty", n] ]); Object.keys(e).reduce((f, l) => (f.set(l, e[l]), f), o); function r(f, l) { const u = f; return typeof l == "number" ? [{ target: u, operator: "length", param: null, value: Number(l) }] : typeof l == "boolean" ? [{ target: u, operator: "getProperty", param: f, value: !!l }] : typeof l == "object" ? Object.keys(l).map((h) => { if (h === "length") return { target: u, operator: "length", param: null, value: l[h] }; const b = h, a = l[h]; return { target: u, operator: "getProperty", param: b, value: a }; }) : []; } function i(f) { return Object.keys(f).reduce((u, h) => { const b = r(h, f[h]); return u.push(...b), u; }, []); } function s(f, l) { if (o.has(f.operator)) { const u = o.get(f.operator); return u && u(f.target, f.param, f.value, l) || !1; } return !1; } function c(f, l) { return i(f).reduce((b, a) => b && s(a, l), !0); } function y(f, l) { const u = Object.keys(f), h = u.includes("allOf"), b = u.includes("anyOf"), a = h || b, C = (a ? f[a ? h ? "allOf" : "anyOf" : "allOf"] : [f]).map((w) => c(w, l)); return h ? !C.includes(!1) : C.includes(!0); } return { parseValueSchema: y }; } const Mn = { convertTo: (e, t, n, o) => { e.appearance || (e.appearance = {}), e.appearance[t] = n; }, convertFrom: (e, t, n) => e.appearance ? e.appearance[t] : e[t] }, Bn = { convertFrom: (e, t, n) => e.buttons && e.buttons.length ? `共 ${e.buttons.length} 项` : "无" }, In = { convertTo: (e, t, n, o) => { e.editor && (e.editor[t] = n); }, convertFrom: (e, t, n) => e.editor && Object.prototype.hasOwnProperty.call(e.editor, t) ? e.editor[t] : e[t] }, Un = { button: { type: "button", name: "按钮" }, "response-toolbar": { type: "response-toolbar", name: "工具栏" }, "response-toolbar-item": { type: "response-toolbar-item", name: "按钮" }, "content-container": { type: "content-container", name: "容器" }, "input-group": { type: "input-group", name: "文本" }, textarea: { type: "textarea", name: "多行文本" }, lookup: { type: "lookup", name: "帮助" }, "number-spinner": { type: "number-spinner", name: "数值" }, "date-picker": { type: "date-picker", name: "日期" }, switch: { type: "switch", name: "开关" }, "radio-group": { type: "radio-group", name: "单选组" }, "check-box": { type: "check-box", name: "复选框" }, "check-group": { type: "check-group", name: "复选框组" }, "combo-list": { type: "combo-list", name: "下拉列表" }, "response-form": { type: "response-form", name: "卡片面板" }, "response-layout": { type: "response-layout", name: "布局容器", icon: "response-layout-3" }, "response-layout-item": { type: "response-layout-item", name: "布局", icon: "response-layout-1" }, "tree-grid": { type: "tree-grid", name: "树表格" }, "tree-grid-column": { type: "tree-grid-column", name: "树表格列" }, "data-grid": { type: "data-grid", name: "表格" }, "data-grid-column": { type: "data-grid-column", name: "表格列" }, module: { type: "Module", name: "模块" }, component: { type: "component", name: "组件" }, tabs: { type: "tabs", name: "标签页" }, "tab-page": { type: "tab-page", name: "标签页项", dependentParentControl: "Tab" }, "tab-toolbar-item": { type: "tab-toolbar-item", name: "标签页工具栏按钮" }, "drawer-toolbar-item": { type: "drawer-toolbar-item", name: "抽屉工具栏按钮" }, "html-template": { type: "html-template", name: "模板容器" }, "time-picker": { type: "time-picker", name: "时间选择" }, section: { type: "section", name: "分组面板" }, "section-toolbar": { type: "section-toolbar", name: "分组面板工具栏" }, "section-toolbar-item": { type: "section-toolbar-item", name: "分组面板按钮" }, splitter: { type: "splitter", name: "分栏面板" }, "splitter-pane": { type: "splitter-pane", name: "分栏面板项", dependentParentControl: "Splitter" }, "component-ref": { type: "component-ref", name: "组件引用节点" }, uploader: { type: "uploader", name: "附件上传" }, "page-header": { type: "page-header", name: "页头" }, "page-footer": { type: "page-footer", name: "页脚" }, "tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏" }, "drawer-toolbar": { type: "drawer-toolbar", name: "抽屉工具栏" }, fieldset: { type: "fieldset", name: "分组" }, "query-solution": { type: "query-solution", name: "筛选方案" }, drawer: { type: "drawer", name: "抽屉" }, "external-container": { type: "external-container", name: "外部容器", icon: "content-container" }, "list-nav": { type: "list-nav", name: "列表导航" }, nav: { type: "nav", name: "标签类导航" }, "list-view": { type: "list-view", name: "列表" }, "filter-bar": { type: "filter-bar", name: "筛选条" }, "language-textbox": { type: "language-textbox", name: "多语输入框" }, image: { type: "image", name: "图像" }, avatar: { type: "avatar", name: "头像" }, "discussion-editor": { type: "discussion-editor", name: "评论编辑区" }, "discussion-list": { type: "discussion-list", name: "评论列表" }, comment: { type: "comment", name: "评论区" }, "approval-logs": { type: "approval-logs", name: "审批记录" }, "rich-text-editor": { type: "rich-text-editor", name: "富文本", icon: "rich-text-box" }, calendar: { type: "calendar", name: "日历", icon: "date-picker" }, wizard: { type: "wizard", name: "向导", icon: "wizard" }, "wizard-page": { type: "wizard-page", name: "向导页", icon: "wizard" }, "wizard-page-detail": { type: "wizard-page-detail", name: "向导详情", icon: "wizard" }, step: { type: "step", name: "步骤条", icon: "step" }, "dynamic-form": { type: "dynamic-form", name: "动态表单" } }, qn = { convertFrom: (e, t, n) => { var r; const o = e.editor && e.editor[t] ? e.editor[t] : e[t]; return ((r = Un[o]) == null ? void 0 : r.name) || o; } }, $n = { convertTo: (e, t, n, o) => { e[t] = e[t]; }, convertFrom: (e, t, n) => e.editor ? n.getRealEditorType(e.editor.type) : "" }, jn = { convertTo: (e, t, n, o) => { (e.type === "data-grid-column" || e.type === "tree-grid-column") && (e.formatter ? e.formatter[t] = n : e.formatter = { [t]: n }); }, convertFrom: (e, t, n) => { if (e.formatter) { if (t === "trueText") return e.formatter.trueText; if (t === "falseText") return e.formatter.falseText; if (t === "prefix") return e.formatter.prefix; if (t === "suffix") return e.formatter.suffix; if (t === "precision") return e.formatter.precision; if (t === "decimal") return e.formatter.decimal; if (t === "thousand") return e.formatter.thousand; if (t === "dateFormat") return e.formatter.dateFormat || "yyyy-MM-dd"; if (t === "customFormat") return e.formatter.customFormat; if (t === "type") return e.formatter.type || "none"; } return "none"; } }, Vn = { convertTo: (e, t, n, o) => { e.command ? e.command[t] = n : e.command = { [t]: n }, t === "enableType" && n === "default" && (e.command.enable = !0, e.command.formatter = "", e.command.commands = [ { text: "编辑", type: "primary", command: "edit" }, { text: "删除", type: "danger", command: "remove" } ]), t === "enableType" && n === "custom" && (e.command.enable = !0, e.command.commands = [ { value: "add", text: "增加", type: "link" }, { value: "edit", text: "编辑", type: "link" }, { value: "remove", text: "删除", type: "link" } ]), t === "enableType" && n === "unable" && (e.command.enable = !1, e.command.formatter = ""); }, convertFrom: (e, t, n) => { var o, r; if (e.command) { if (t === "enableType") { if (e.command.enableType) return e.command.enableType; const i = (r = (o = e.command) == null ? void 0 : o.commands) == null ? void 0 : r.find((s) => s.command === "edit" && s.type === "primary"); return e.command.enable ? i ? "default" : "custom" : "unable"; } if (t === "commands") return e.command.enableType === "custom" ? e.command.commands : []; if (t === "formatter") return e.command.formatter; if (t === "count") return e.command.count; if (t === "columnWidth") return e.command.columnWidth || 200; } return ""; } }, zn = { convertTo: (e, t, n, o) => { e.column ? e.column[t] = n : e.column = { [t]: n }, t === "fitColumns" && n && (e.column.fitMode || (e.column.fitMode = "average")); }, convertFrom: (e, t, n) => { if (e.column) { if (t === "fitColumns") return e.column.fitColumns; if (t === "fitMode") return e.column.fitMode; } return ""; } }, Hn = { convertTo: (e, t, n, o) => { e.summary ? e.summary[t] = n : e.summary = { [t]: n }, t === "enable" && n && (e.summary ? e.summary.groupFields || (e.summary.groupFields = []) : e.summary = { enable: n, groupFields: [] }); }, convertFrom: (e, t, n) => { var o, r; return t === "customSummaryStyle" ? e.summary.customSummaryStyle : t === "position" ? ((o = e.summary) == null ? void 0 : o[t]) || "bottom" : t === "customRender" ? ((r = e.summary) == null ? void 0 : r[t]) || "" : e.summary && t === "enable" ? e.summary.enable : e.type === "data-grid-column" ? e.enableSummary === void 0 ? !1 : e.enableSummary : ""; } }, Wn = { convertTo: (e, t, n, o) => { e.group ? e.group[t] = n : e.group = { [t]: n }, t === "enable" && n && (e.group ? e.group.groupFields || (e.group.groupFields = []) : e.group = { enable: n, groupFields: [], showSummary: !1, customRender: "" }); }, convertFrom: (e, t, n) => { if (e.group) { if (t === "enable") return e.group.enable; if (t === "showSummary") return e.group.showSummary; if (t === "customRender") return e.group.customRender; if (t === "groupFields") return e.group.groupFields; } } }, _n = { convertFrom: (e, t) => e.binding ? e.binding.path : "", convertTo: (e, t, n) => { if (n && n.length > 0) { const o = n[0]; e.binding || (e.binding = {}), e.binding.type = "Form", e.binding.path = o.bindingField, e.binding.field = o.id, e.binding.fullPath = o.path, e.path = o.bindingPath; } } }, Jn = { convertTo: (e, t, n, o) => { e.pagination || (e.pagination = {}), t === "sizeLimits" ? e.pagination.sizeLimits = n.split(",") : e.pagination[t] = n; }, convertFrom: (e, t, n) => { var o; return e.pagination ? t === "sizeLimits" ? (o = e.pagination.sizeLimits) == null ? void 0 : o.join(",") : e.pagination[t] : e[t]; } }, Yn = { convertTo: (e, t, n, o) => { e.rowNumber || (e.rowNumber = {}), e.rowNumber[t] = n; }, convertFrom: (e, t, n) => e.rowNumber ? e.rowNumber[t] : e[t] }, Gn = { convertTo: (e, t, n, o) => { e.selection || (e.selection = {}), e.selection[t] = n; }, convertFrom: (e, t, n) => { if (!e.selection) return !!e[t]; const o = !!e.selection[t]; return t === "showCheckbox" && o == null && e.selection.multiSelect === !0 ? !0 : o; } }, Qn = { convertFrom: (e, t, n) => e[t] && e[t].length ? `共 ${e[t].length} 项` : "" }, Xn = { convertFrom: (e, t) => e[t] || "", convertTo: (e, t, n) => { e[t] = n; } }, Zn = { convertTo: (e, t, n, o) => { e.size || (e.size = {}), e.size[t] = n; }, convertFrom: (e, t, n) => e.size ? e.size[t] : e[t] }, Kn = { convertFrom: (e, t, n) => { var o, r; return (o = e.formatter) != null && o.data && t === "formatterEnumData" && !e.formatterEnumData ? (r = e.formatter) == null ? void 0 : r.data : e.formatterEnumData; } }, eo = { convertTo: (e, t, n, o) => { e.sort || (e.sort = {}), e.sort[t] = n; }, convertFrom: (e, t, n) => { var o, r; if (t === "mode") return ((o = e.sort) == null ? void 0 : o.mode) || "client"; if (t === "multiSort") return !!((r = e.sort) != null && r.multiSort); } }, to = { convertTo: (e, t, n, o) => { e.filter || (e.filter = {}), e.filter[t] = n, t === "enable" && (e.enableFilter = !1); }, convertFrom: (e, t, n) => { var o, r, i, s; return t === "mode" ? ((o = e.filter) == null ? void 0 : o.mode) || "server" : t === "filterStyle" ? ((r = e.filter) == null ? void 0 : r.filterStyle) || "filter-column" : t === "enable" ? ((i = e.filter) == null ? void 0 : i.enable) !== void 0 ? !!e.filter.enable : !!e.enableFilter : ((s = e.filter) == null ? void 0 : s[t]) || void 0; } }, no = { convertTo: (e, t, n, o) => { e.rowOption ? e.rowOption[t] = n : e.rowOption = { [t]: n }; }, convertFrom: (e, t, n) => { if (e.rowOption) { if (t === "customRowStyle") return e.rowOption.customRowStyle; if (t === "customCellStyle") return e.rowOption.customCellStyle; if (t === "height") return e.rowOption.height; } return ""; } }, oo = { convertTo: (e, t, n, o) => { (e.type === "data-grid-column" || e.type === "tree-grid-column") && (e[t] = n, t === "columnTemplateType" && n === "hyperlink" && (e.onClickLinkCommand ? e.columnTemplate = ` <span class="f-pretend-link f-cursor-pointer" @click="(ctx)=>viewModel.current.${e.onClickLinkCommand || ""}({id: rowData.id,context: ctx})"> {{rowData.${e.field}}} </span>` : e.columnTemplate = ` <span class="f-pretend-link f-cursor-pointer"> {{rowData.${e.field}}} </span>`), t === "columnTemplateType" && n === "default" && (e.columnTemplate = ""), t === "columnTemplateType" && n === "custom" && (e.columnTemplate = "")); }, convertFrom: (e, t, n) => t === "columnTemplate" ? e.columnTemplate : t === "columnTemplateType" ? e.columnTemplateType ? e.columnTemplateType || "default" : e.columnTemplate && !e.onClickLinkCommand ? "custom" : e.columnTemplate && e.onClickLinkCommand ? "hyperlink" : "default" : "" }, ro = { convertTo: (e, t, n, o) => { e.hierarchy || (e.hierarchy = { cascadeOption: {} }), e.hierarchy.cascadeOption || (e.hierarchy.cascadeOption = {}), e.hierarchy.cascadeOption[t] = n; }, convertFrom: (e, t, n) => { var o, r; return !!((r = (o = e.hierarchy) == null ? void 0 : o.cascadeOption) != null && r[t]); } }; function bt(e, t, n) { const o = /* @__PURE__ */ new Map([ ["/converter/appearance.converter", Mn], ["/converter/buttons.converter", Bn], ["/converter/property-editor.converter", In], ["/converter/items-count.converter", Qn], ["/converter/type.converter", qn], ["/converter/change-editor.converter", $n], ["/converter/change-formatter.converter", jn], ["/converter/column-command.converter", Vn], ["/converter/column-option.converter", zn], ["/converter/summary.converter", Hn], ["/converter/group.converter", Wn], ["/converter/form-group-label.converter", Xn], ["/converter/field-selector.converter", _n], ["/converter/pagination.converter", Jn], ["/converter/row-number.converter", Yn], ["/converter/grid-selection.converter", Gn], ["/converter/size.converter", Zn], ["/converter/change-formatter-enum.converter", Kn], ["/converter/grid-sort.converter", eo], ["/converter/grid-filter.converter", to], ["/converter/row-option.converter", no], ["/converter/change-formatter-type.converter", oo], ["/converter/tree-auto-check.converter", ro] ]), r = /* @__PURE__ */ new Map([ ["string", { type: "input-group", enableClear: !1 }], ["boolean", { type: "combo-list", textField: "name", valueField: "value", idField: "value", enableClear: !1, editable: !1, data: [ { value: !0, name: "是" }, { value: !1, name: "否" } ] }], ["enum", { type: "combo-list", maxHeight: 128, enableClear: !1, editable: !1 }], ["array", { type: "button-edit" }], ["number", { type: "number-spinner", placeholder: "" }], ["events-editor", { type: "events-editor", hide: !0 }], ["multiLanguage", { type: "language-textbox" }] ]), i = Nn(); function s(a, g) { return () => i.parseValueSchema(a, g); } function c(a, g, p) { return a.includes("visible") && g.visible !== void 0 ? typeof g.visible == "boolean" ? () => !!g.visible : g.visible === void 0 ? !0 : s(g.visible, p) : () => !0; } function y(a, g, p) { return a.includes("readonly") && g.readonly !== void 0 ? typeof g.readonly == "boolean" ? () => !!g.readonly : s(g.readonly, p) : () => !1; } function f(a, g) { const p = a.$converter || g; return typeof p == "string" && p && o.has(p) ? o.get(p) || null : p || null; } function l(a, g, p, C, x, w = "", P = "") { return Object.keys(a).map((O) => { const A = k(1), U = O, D = a[O], v = Object.keys(D), L = D.title, M = D.type, B = r.get(M) || { type: "input-group", enableClear: !1 }, N = D.editor ? Object.assign({}, B, D.editor) : Object.assign({}, B), Y = c(v, D, g), I = y(v, D, g); N.readonly = N.readonly === void 0 ? I() : N.readonly; const X = D.type === "cascade" ? l(D.properties, g, p, C, x, w, P) : [], $ = !0; let H = f(D, P); const ce = z({ get() { if (A.value) { if (["class", "style"].find((he) => he === U) && !H && (H = o.get("/converter/appearance.converter") || null), H && H.convertFrom) { const he = H.convertFrom(p, O, x, w); return he === void 0 && Object.prototype.hasOwnProperty.call(D, "defaultValue") ? D.type === "boolean" ? D.defaultValue : D.defaultValue || "" : he; } const K = p[O]; return Object.prototype.hasOwnProperty.call(D, "defaultValue") && (K === void 0 || typeof K == "string" && K === "") ? D.type === "boolean" ? D.defaultValue : D.defaultValue || "" : K; } return null; }, set(K) { A.value += 1, H && H.convertTo ? (H.convertTo(C, O, K, x, w), H.convertTo(p, O, K, x, w)) : (C[O] = K, p[O] = K); } }), { refreshPanelAfterChanged: T, description: j, isExpand: W, parentPropertyID: G } = D, oe = { propertyID: U, propertyName: L, propertyType: M, propertyValue: ce, editor: N, visible: Y, readonly: I, cascadeConfig: X, hideCascadeTitle: $, refreshPanelAfterChanged: T, description: j, isExpand: W, parentPropertyID: G }; return g[U] = oe, oe; }); } function u(a, g, p = {}) { const C = {}, x = e[a]; return x && x.categories ? Object.keys(x.categories).map((P) => { const S = x.categories[P], O = S == null ? void 0 : S.title, A = l(S.properties || {}, C, {}, p, g); return { categoryId: P, categoryName: O, properties: A }; }) : []; } function h(a, g, p, C, x = "") { const w = g.$ref.schema, P = g.$ref.converter, S = p[w], O = S.type, A = n(S), U = {}, D = e[O]; if (D && D.categories) { const v = D.categories[a], L = v == null ? void 0 : v.title; P && Object.keys(v.properties).forEach((N) => { v.properties[N].$converter = P; }); const M = (v == null ? void 0 : v.properties) || {}, B = l(M, U, A, S, C, x); return { categoryId: a, categoryName: L, properties: B }; } return { categoryId: a, categoryName: "", properties: [] }; } function b(a, g, p, C, x) { const w = a.type, P = n(a), S = {}; let O = x || e[w]; if (!(O && Object.keys(O).length > 0) && p && p.getPropConfig && (O = p.getPropConfig(C)), O && O.categories) { const U = []; return Object.keys(O.categories).map((D) => { const v = O.categories[D]; if (v.$ref) { U.push(h(D, v, a, g, C)); return; } const L = v == null ? void 0 : v.title, M = v == null ? void 0 : v.tabId, B = v == null ? void 0 : v.tabName, N = v == null ? void 0 : v.hide, Y = v == null ? void 0 : v.hideTitle, I = l(v.properties || {}, S, P, a, g, C, v.$converter), { setPropertyRelates: X } = v, $ = v == null ? void 0 : v.parentPropertyID; U.push({ categoryId: D, categoryName: L, tabId: M, tabName: B, hide: N, properties: I, hideTitle: Y, setPropertyRelates: X, parentPropertyID: $ }); }), U; } return []; } return { getPropertyConfigBySchema: b, getPropertyConfigByType: u, propertyConverterMap: o }; } const vt = {}, Ct = {}; bt(vt, Ct, Fn); const St = {}, xt = {}, { resolveSchemaWithDefaultValue: so } = gt(St, xt), Tt = {}, wt = {}; bt(Tt, wt, so); function io(e, t, n = /* @__PURE__ */ new Map(), o = (s, c, y, f) => c, r = {}, i = (s) => s) { return ht[t.title] = t, yt[t.title] = o, vt[t.title] = r, Ct[t.title] = i, St[t.title] = t, xt[t.title] = o, Tt[t.title] = r, wt[t.title] = i, (s = {}, c = !0) => { if (!c) return Rn(s, n); const y = Ln(s, t, n), f = Object.keys(e).reduce((l, u) => (l[u] = e[u].default, l), {}); return Object.assign(f, y); }; } function ao(e, t) { return { customClass: t.class, customStyle: t.style }; } const Et = /* @__PURE__ */ new Map([ ["appearance", ao] ]); function lo(e, t) { const n = t == null ? void 0 : t.formSchemaUtils, o = e.parentComponentInstance, r = "7690ac62-f2fd-43aa-96a2-973f0d450f82"; function i() { const l = ln(un.comment.type); if (!l) return; const u = Math.random().toString(36).substr(2, 4); return Object.assign(l, { id: "comment-" + u, personSearchUrl: "/api/runtime/comment/v1.0/bill-comment/atUser" }), { comment: l }; } function s(l, u) { let h; if (l && l.commands) { let b = l.commands.find((a) => a.handlerName === u.handlerName && a.cmpId === r); return b ? b.params && b.params.length && b.params.forEach((a) => a.value = "") : (h = mn().guid(), b = { id: h, code: `${l.id.replace(/-/g, "").replace("component", "").replace("viewmodel", "")}${u.handlerName}1`, name: u.name, params: u.params, handlerName: u.handlerName, cmpId: r }, l.commands.push(b)), { commandId: h, commandCode: b.code }; } return { commandId: "", commandCode: "" }; } function c(l, u) { const h = n.getCommands(); if (h) { let b = h.find((a) => a.id === r); b || (b = { id: r, path: "Gsp/Web/WebCmp/bo-webcmp/metadata/webcmd-vue", name: "DiscussionController.webcmd", refedHandlers: [] }, n.getCommands().push(b)), l && b.refedHandlers.push( { host: l, handler: u } ); } } function y(l) { const u = o.belongedComponentId, h = n.getViewModelIdByComponentId(u), b = n.getViewModelById(h); [ { handlerName: "createComment", name: "提交评论", params: [ { name: "id", shownName: "数据ID", value: "", defaultValue: null }, { name: "summary", shownName: "备注", value: "", defaultValue: null }, { name: "configID", shownName: "配置ID", value: "", defaultValue: null } ], emitEvent: "onValueChange" }, { handlerName: "queryFrequentMentionUsers", name: "加载常用@人员", params: [], emitEvent: "onQueryFrequentAtUsers" }, { handlerName: "queryComments", name: "查询评论", params: [ { name: "id", shownName: "数据ID", value: "", defaultValue: null }, { name: "configID", shownName: "配置ID", value: "", defaultValue: null } ], emitEvent: "onQueryComments" } ].forEach((g) => { const { commandId: p, commandCode: C } = s(b, g); C && (l[g.emitEvent] = C), p && c(p, g.handlerName); }); } function f() { const { comment: l } = i(); y(l); const u = t == null ? void 0 : t.useFormCommand; return u && u.checkCommands(), l; } return { createComment: f }; } function Ot(e, t, n, o) { if (n.parentComponentInstance && o) { const s = lo(n, o).createComment(); if (s) return s; } return t; } const Ve = { /** 发表评论的取消按钮是否可见 */ cancelVisible: { Type: Boolean, default: !0 }, /** @人员时,区分人员的标识 */ personnelsPrimaryKey: { Type: String, default: "id" }, /** @人员时,展示的人员信息字段 */ personnelsDisplayKey: { Type: String, default: "name" }, /** 回复人员时,展示的回复人员信息字段 */ replyPersonnelsDisplayKey: { Type: String, default: "userName" }, /** 编辑区高度 */ editorHeight: { Type: Number, default: 130 }, type: { Type: String, default: "user" }, /** 组织查询链接,应用在组织人员窗口 */ orgUrl: { Type: String, default: "" }, /** 人员查询链接,根据组织查询对应的人员 */ personSearchUrl: { Type: String, default: "" }, /** 查询所有部门数据 */ sectionData: { Type: Object, default: [] }, /** 回复人员数据信息 */ replyUser: { Type: Object }, /** 获取@用户|获取常用@用户 */ personnels: { Type: Object, default: [] }, /** 评论附加的组件 */ attachFiles: { Type: Object, default: [] }, /** 弹出窗口的样式 */ popupClass: { Type: String, default: "" }, /** 控制是否可见 */ visible: { type: Boolean, default: !0 }, /** 组件自定义样式 */ customClass: { type: String, default: "" }, customStyle: { type: String, default: "" }, /** 回复评论是所有人可见还是只被回复人可见 */ permissionType: { type: String, default: "ALL" }, /** 组件id */ id: { Type: String, default: "" } }, Dt = { pagerOnServer: { Type: Boolean, default: !0 }, /** 是否支持分页 */ supportPaging: { Type: Boolean, default: !0 }, /** 当前页码 */ pageIndex: { Type: Number, default: 1 }, /** 总条数 */ total: { Type: Number, default: 0 }, /** 每页显示个数 */ pageSize: { Type: Number, default: 10 }, /** 评论数据 */ discussionData: { Type: Object, default: [] }, replyPersonnelsDisplayKey: { Type: String, default: "userName" }, id: { Type: String, default: "" }, /** 组件自定义样式 */ customClass: { type: String, default: "" }, customStyle: { type: String, default: "" }, /** 控制是否可见 */ visible: { type: Boolean, default: !0 } }, ze = Object.assign({}, Ve, Dt, { customClass: { type: String, default: "" }, /** 讨论区编辑器样式 */ editorClass: { type: String, default: "" }, editorStyle: { type: String, default: "" }, editorVisible: { type: Boolean, default: !0 }, /** 讨论区列表样式 */ listClass: { type: String, default: "" }, listStyle: { type: String, default: "" }, listVisible: { type: Boolean, default: !0 }, visible: { type: Boolean, default: !0 } }), co = cn(ze, pt, Et, Ot); var Me = /* @__PURE__ */ ((e) => (e[e.Cancel = 0] = "Cancel", e[e.Confirm = 1] = "Confirm", e))(Me || {}); const uo = "F_COMMENT_LIST_SERVICE_TOKEN", Qe = "zh-CHS", mo = { locale: Qe, fallbackLocale: Qe, uri: "" }; function Pt(e, t) { return function() { return e.apply(t, arguments); }; } const { toString: fo } = Object.prototype, { getPrototypeOf: He } = Object, { iterator: Ee, toStringTag: kt } = Symbol, Oe = /* @__PURE__ */ ((e) => (t) => { const n = fo.call(t); return e[n] || (e[n] = n.slice(8, -1).toLowerCase()); })(/* @__PURE__ */ Object.create(null)), Q = (e) => (e = e.toLowerCase(), (t) => Oe(t) === e), De = (e) => (t) => typeof t === e, { isArray: ae } = Array, ie = De("undefined"); function me(e) { return e !== null && !ie(e) && e.constructor !== null && !ie(e.constructor) && _(e.constructor.isBuffer) && e.constructor.isBuffer(e); } const At = Q("ArrayBuffer"); function po(e) { let t; return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && At(e.buffer), t; } const go = De("string"), _ = De("function"), Ft = De("number"), fe = (e) => e !== null && typeof e == "object", ho = (e) => e === !0 || e === !1, be = (e) => { if (Oe(e) !== "object") return !1; const t = He(e); return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(kt in e) && !(Ee in e); }, yo = (e) => { if (!fe(e) || me(e)) return !1; try { return Object.keys(e).length === 0 && Object.getPrototypeOf(e) === Object.prototype; } catch { return !1; } }, bo = Q("Date"), vo = Q("File"), Co = Q("Blob"), So = Q("FileList"), xo = (e) => fe(e) && _(e.pipe), To = (e) => { let t; return e && (typeof FormData == "function" && e instanceof FormData || _(e.append) && ((t = Oe(e)) === "formdata" || // detect form-data instance t === "object" && _(e.toString) && e.toString() === "[object FormData]")); }, wo = Q("URLSearchParams"), [Eo, Oo, Do, Po] = ["ReadableStream", "Request", "Response", "Headers"].map(Q), ko = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, ""); function pe(e, t, { allOwnKeys: n = !1 } = {}) { if (e === null || typeof e > "u") return; let o, r; if (typeof e != "object" && (e = [e]), ae(e)) for (o = 0, r = e.length; o < r; o++) t.call(null, e[o], o, e); else { if (me(e)) return; const i = n ? Object.getOwnPropertyNames(e) : Object.keys(e), s = i.length; let c; for (o = 0; o < s; o++) c = i[o], t.call(null, e[c], c, e); } } function Lt(e, t) { if (me(e)) return null; t = t.toLowerCase(); const n = Object.keys(e); let o = n.length, r; for (; o-- > 0; ) if (r = n[o], t === r.toLowerCase()) return r; return null; } const ee = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Rt = (e) => !ie(e) && e !== ee; function Be() { const { caseless: e, skipUndefined: t } = Rt(this) && this || {}, n = {}, o = (r, i) => { const s = e && Lt(n, i) || i; be(n[s]) && be(r) ? n[s] = Be(n[s], r) : be(r) ? n[s] = Be({}, r) : ae(r) ? n[s] = r.slice() : (!t || !ie(r)) && (n[s] = r); }; for (let r = 0, i = arguments.length; r < i; r++) arguments[r] && pe(arguments[r], o); return n; } const Ao = (e, t, n, { allOwnKeys: o } = {}) => (pe(t, (r, i) => { n && _(r) ? e[i] = Pt(r, n) : e[i] = r; }, { allOwnKeys: o }), e), Fo = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), Lo = (e, t, n, o) => { e.prototype = Object.create(t.prototype, o), e.prototype.constructor = e, Object.defineProperty(e, "super", { value: t.prototype }), n && Object.assign(e.prototype, n); }, Ro = (e, t, n, o) => { let r, i, s; const c = {}; if (t = t || {}, e == null) return t; do { for (r = Object.getOwnPropertyNames(e), i = r.length; i-- > 0; ) s = r[i], (!o || o(s, e, t)) && !c[s] && (t[s] = e[s], c[s] = !0); e = n !== !1 && He(e); } while (e && (!n || n(e, t)) && e !== Object.prototype); return t; }, No = (e, t, n) => { e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length; const o = e.indexOf(t, n); return o !== -1 && o === n; }, Mo = (e) => { if (!e) return null; if (ae(e)) return e; let t = e.length; if (!Ft(t)) return null; const n = new Array(t); for (; t-- > 0; ) n[t] = e[t]; return n; }, Bo = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && He(Uint8Array)), Io = (e, t) => { const o = (e && e[Ee]).call(e); let r; for (; (r = o.next()) && !r.done; ) { const i = r.value; t.call(e, i[0], i[1]); } }, Uo = (e, t) => { let n; const o = []; for (; (n = e.exec(t)) !== null; ) o.push(n); return o; }, qo = Q("HTMLFormElement"), $o = (e) => e.toLowerCase().replace( /[-_\s]([a-z\d])(\w*)/g, function(n, o, r) { return o.toUpperCase() + r; } ), Xe = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), jo = Q("RegExp"), Nt = (e, t) => { const n = Object.getOwnPropertyDescriptors(e), o = {}; pe(n, (r, i) => { let s; (s = t(r, i, e)) !== !1 && (o[i] = s || r); }), Object.defineProperties(e, o); }, Vo = (e) => { Nt(e, (t, n) => { if (_(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1) return !1; const o = e[n]; if (_(o)) { if (t.enumerable = !1, "writable" in t) { t.writable = !1; return; } t.set || (t.set = () => { throw Error("Can not rewrite read-only method '" + n + "'"); }); } }); }, zo = (e, t) => { const n = {}, o = (r) => { r.forEach((i) => { n[i] = !0; }); }; return ae(e) ? o(e) : o(String(e).split(t)), n; }, Ho = () => { }, Wo = (e, t) => e != null && Number.isFinite(e = +e) ? e : t; function _o(e) { return !!(e && _(e.append) && e[kt] === "FormData" && e[Ee]); } const Jo = (e) => { const t = new Array(10), n = (o, r) => { if (fe(o)) { if (t.indexOf(o) >= 0) return; if (me(o)) return o; if (!("toJSON" in o)) { t[r] = o; const i = ae(o) ? [] : {}; return pe(o, (s, c) => { const y = n(s, r + 1); !ie(y) && (i[c] = y); }), t[r] = void 0, i; } } return o; }; return n(e, 0); }, Yo = Q("AsyncFunction"), Go = (e) => e && (fe(e) || _(e)) && _(e.then) && _(e.catch), Mt = ((e, t) => e ? setImmediate : t ? ((n, o) => (ee.addEventListener("message", ({ source: r, data: i }) => { r === ee && i === n && o.length && o.shift()(); }, !1), (r) => { o.push(r), ee.postMessage(n, "*"); }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))( typeof setImmediate == "function", _(ee.postMessage) ), Qo = typeof queueMicrotask < "u" ? queueMicrotask.bind(ee) : typeof process < "u" && process.nextTick || Mt, Xo = (e) => e != null && _(e[Ee]), m = { isArray: ae, isArrayBuffer: At, isBuffer: me, isFormData: To, isArrayBufferView: po, isString: go, isNumber: Ft, isBoolean: ho, isObject: fe, isPlainObject: be, isEmptyObject: yo, isReadableStream: Eo, isRequest: Oo, isResponse: Do, isHeaders: Po, isUndefined: ie, isDate: bo, isFile: vo, isBlob: Co, isRegExp: jo, isFunction: _, isStream: xo, isURLSearchParams: wo, isTypedArray: Bo, isFileList: So, forEach: pe, merge: Be, extend: Ao, trim: ko, stripBOM: Fo, inherits: Lo, toFlatObject: Ro, kindOf: Oe, kindOfTest: Q, endsWith: No, toArray: Mo, forEachEntry: Io, matchAll: Uo, isHTMLForm: qo, hasOwnProperty: Xe, hasOwnProp: Xe, // an alias to avoid ESLint no-prototype-builtins detection reduceDescriptors: Nt, freezeMethods: Vo, toObjectSet: zo, toCamelCase: $o, noop: Ho, toFiniteNumber: Wo, findKey: Lt, global: ee, isContextDefined: Rt, isSpecCompliantForm: _o, toJSONObject: Jo, isAsyncFn: Yo, isThenable: Go, setImmediate: Mt, asap: Qo, isIterable: Xo }; function E(e, t, n, o, r) { Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), o && (this.request = o), r && (this.response = r, this.status = r.status ? r.status : null); } m.inherits(E, Error, { toJSON: function() { return { // Standard message: this.message, name: this.name, // Microsoft description: this.description, number: this.number, // Mozilla fileName: this.fileName, lineNumber: this.lineNumber, columnNumber: this.columnNumber, stack: this.stack, // Axios config: m.toJSONObject(this.config), code: this.code, status: this.status }; } }); const Bt = E.prototype, It = {}; [ "ERR_BAD_OPTION_VALUE", "ERR_BAD_OPTION", "ECONNABORTED", "ETIMEDOUT", "ERR_NETWORK", "ERR_FR_TOO_MANY_REDIRECTS", "ERR_DEPRECATED", "ERR_BAD_RESPONSE", "ERR_BAD_REQUEST", "ERR_CANCELED", "ERR_NOT_SUPPORT", "ERR_INVALID_URL" // eslint-disable-next-line func-names ].forEach((e) => { It[e] = { value: e }; }); Object.defineProperties(E, It); Object.defineProperty(Bt, "isAxiosError", { value: !0 }); E.from = (e, t, n, o, r, i) => { const s = Object.create(Bt); m.toFlatObject(e, s, function(l) { return l !== Error.prototype; }, (f) => f !== "isAxiosError"); const c = e && e.message ? e.message : "Error", y = t == null && e ? e.code : t; return E.call(s, c, y, n, o, r), e && s.cause == null && Object.defineProperty(s, "cause", { value: e, configurable: !0 }), s.name = e && e.name || "Error", i && Object.assign(s, i), s; }; const Zo = null; function Ie(e) { return m.isPlainObject(e) || m.isArray(e); } function Ut(e) { return m.endsWith(e, "[]") ? e.slice(0, -2) : e; } function Ze(e, t, n) { return e ? e.concat(t).map(function(r, i) { return r = Ut(r), !n && i ? "[" + r + "]" : r; }).join(n ? "." : "") : t; } function Ko(e) { return m.isArray(e) && !e.some(Ie); } const er = m.toFlatObject(m, {}, null, function(t) { return /^is[A-Z]/.test(t); }); function Pe(e, t, n) { if (!m.isObject(e)) throw new TypeError("target must be an object"); t = t || new FormData(), n = m.toFlatObject(n, { metaTokens: !0, dots: !1, indexes: !1 }, !1, function(g, p) { return !m.isUndefined(p[g]); }); const o = n.metaTokens, r = n.visitor || l, i = n.dots, s = n.indexes, y = (n.Blob || typeof Blob < "u" && Blob) && m.isSpecCompliantForm(t); if (!m.isFunction(r)) throw new TypeError("visitor must be a function"); function f(a) { if (a === null) return ""; if (m.isDate(a)) return a.toISOString(); if (m.isBoolean(a)) return a.toString(); if (!y && m.isBlob(a)) throw new E("Blob is not supported. Use a Buffer instead."); return m.isArrayBuffer(a) || m.isTypedArray(a) ? y && typeof Blob == "function" ? new Blob([a]) : Buffer.from(a) : a; } function l(a, g, p) { let C = a; if (a && !p && typeof a == "object") { if (m.endsWith(g, "{}")) g = o ? g : g.slice(0, -2), a = JSON.stringify(a); else if (m.isArray(a) && Ko(a) || (m.isFileList(a) || m.endsWith(g, "[]")) && (C = m.toArray(a))) return g = Ut(g), C.forEach(function(w, P) { !(m.isUndefined(w) || w === null) && t.append( // eslint-disable-next-line no-nested-ternary s === !0 ? Ze([g], P, i) : s === null ? g : g + "[]", f(w) ); }), !1; } return Ie(a) ? !0 : (t.append(Ze(p, g, i), f(a)), !1); } const u = [], h = Object.assign(er, { defaultVisitor: l, convertValue: f, isVisitable: Ie }); function b(a, g) { if (!m.isUndefined(a)) { if (u.indexOf(a) !== -1) throw Error("Circular reference detected in " + g.join(".")); u.push(a), m.forEach(a, function(C, x) { (!(m.isUndefined(C) || C === null) && r.call( t, C, m.isString(x) ? x.trim() : x, g, h )) === !0 && b(C, g ? g.concat(x) : [x]); }), u.pop(); } } if (!m.isObject(e)) throw new TypeError("data must be an object"); return b(e), t; } function Ke(e) { const t = { "!": "%21", "'": "%27", "(": "%28", ")": "%29", "~": "%7E", "%20": "+", "%00": "\0" }; return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(o) { return t[o]; }); } function We(e, t) { this._pairs = [], e && Pe(e, this, t); } const qt = We.prototype; qt.append = function(t, n) { this._pairs.push([t, n]); }; qt.toString = function(t) { const n = t ? function(o) { return t.call(this, o, Ke); } : Ke; return this._pairs.map(function(r) { return n(r[0]) + "=" + n(r[1]); }, "").join("&"); }; function tr(e) { return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+"); } function $t(e, t, n) { if (!t) return e; const o = n && n.encode || tr; m.isFunction(n) && (n = { serialize: n }); const r = n && n.serialize; let i; if (r ? i = r(t, n) : i = m.isURLSearchParams(t) ? t.toString() : new We(t, n).toString(o), i) { const s = e.indexOf("#"); s !== -1 && (e = e.slice(0, s)), e += (e.indexOf("?") === -1 ? "?" : "&") + i; } return e; } class et { constructor() { this.handlers = []; } /** * Add a new interceptor to the stack * * @param {Function} fulfilled The function to handle `then` for a `Promise` * @param {Function} rejected The function to handle `reject` for a `Promise` * * @return {Number} An ID used to remove interceptor later */ use(t, n, o) { return this.handlers.push({ fulfilled: t, rejected: n, synchronous: o ? o.synchronous : !1, runWhen: o ? o.runWhen : null }), this.handlers.length - 1; } /** * Remove an interceptor from the stack * * @param {Number} id The ID that was returned by `use` * * @returns {void} */ eject(t) { this.handlers[t] && (this.handlers[t] = null); } /** * Clear all interceptors from the stack * * @returns {void} */ clear() { this.handlers && (this.handlers = []); } /** * Iterate over all the registered interceptors * * This method is particularly useful for skipping over any * interceptors that may have become `null` calling `eject`. * * @param {Function} fn The function to call for each interceptor * * @returns {void} */ forEach(t) { m.forEach(this.handlers, function(o) { o !== null && t(o); }); } } const jt = { silentJSONParsing: !0, forcedJSONParsing: !0, clarifyTimeoutError: !1 }, nr = typeof URLSearchParams < "u" ? URLSearchParams : We, or = typeof FormData < "u" ? FormData : null, rr = typeof Blob < "u" ? Blob : null, sr = { isBrowser: !0, classes: { URLSearchParams: nr, FormData: or, Blob: rr }, protocols: ["http", "https", "file", "blob", "url", "data"] }, _e = typeof window < "u" && typeof document < "u", Ue = typeof navigator == "object" && navigator || void 0, ir = _e && (!Ue || ["ReactNative", "NativeScript", "NS"].indexOf(Ue.product) < 0), ar = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef self instanceof WorkerGlobalScope && typeof self.importScripts == "function", lr = _e && window.location.href || "http://localhost", cr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, hasBrowserEnv: _e, hasStandardBrowserEnv: ir, hasStandardBrowserWebWorkerEnv: ar, navigator: Ue, origin: lr }, Symbol.toStringTag, { value: "Module" })), V = { ...cr, ...sr }; function ur(e, t) { return Pe(e, new V.classes.URLSearchParams(), { visitor: function(n, o, r, i) { return V.isNode && m.isBuffer(n) ? (this.append(o, n.toString("base64")), !1) : i.defaultVisitor.apply(this, arguments); }, ...t }); } function dr(e) { return m.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]); } function mr(e) { const t = {}, n = Object.keys(e); let o; const r = n.length; let i; for (o = 0; o < r; o++) i = n[o], t[i] = e[i]; return t; } function Vt(e) { function t(n, o, r, i) { let s = n[i++]; if (s === "__proto__") return !0; const c = Number.isFinite(+s), y = i >= n.length; return s = !s && m.isArray(r) ? r.length : s, y ? (m.hasOwnProp(r, s) ? r[s] = [r[s], o] : r[s] = o, !c) : ((!r[s] || !m.isObject(r[s])) && (r[s] = []), t(n, o, r[s], i) && m.isArray(r[s]) && (r[s] = mr(r[s])), !c); } if (m.isFormData(e) && m.isFunction(e.entries)) { const n = {}; return m.forEachEntry(e, (o, r) => { t(dr(o), r, n, 0); }), n; } return null; } function fr(e, t, n) { if (m.isString(e)) try { return (t || JSON.parse)(e), m.trim(e); } catch (o) { if (o.name !== "SyntaxError") throw o; } return (n || JSON.stringify)(e); } const ge = { transitional: jt, adapter: ["xhr", "http", "fetch"], transformRequest: [function(t, n) { const o = n.getContentType() || "", r = o.indexOf("application/json") > -1, i = m.isObject(t); if (i && m.isHTMLForm(t) && (t = new FormData(t)), m.isFormData(t)) return r ? JSON.stringify(Vt(t)) : t; if (m.isArrayBuffer(t) || m.isBuffer(t) || m.isStream(t) || m.isFile(t) || m.isBlob(t) || m.isReadableStream(t)) return t; if (m.isArrayBufferView(t)) return t.buffer; if (m.isURLSe