ebuilds-shared 0.2.9 → 0.3.1

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.
@@ -133,7 +133,7 @@ var require_supports_color = __commonJS({
133
133
  // src/vite-config/index.ts
134
134
  import { defineConfig, loadEnv } from "vite";
135
135
 
136
- // ../node_modules/.pnpm/@vitejs+plugin-vue@5.2.4_vite@6.4.1_@types+node@22.19.3_jiti@2.6.1_less@4.5.1_sass-embedded@1_s4xy5zaghyb6yswdann26222ty/node_modules/@vitejs/plugin-vue/dist/index.mjs
136
+ // ../node_modules/.pnpm/@vitejs+plugin-vue@5.2.4_vite@6.4.1_@types+node@22.19.7_jiti@2.6.1_less@4.5.1_sass-embedded@1_gleyv4jjxuxzkop3burc7rdxhq/node_modules/@vitejs/plugin-vue/dist/index.mjs
137
137
  import fs from "fs";
138
138
  import { normalizePath as normalizePath$1, isCSSRequest, transformWithEsbuild, formatPostcssSourceMap, createFilter } from "vite";
139
139
  import { shallowRef, computed } from "vue";
@@ -2679,31 +2679,20 @@ import AutoImport from "unplugin-auto-import/vite";
2679
2679
  import Components from "unplugin-vue-components/vite";
2680
2680
  import { AntDesignVueResolver, ElementPlusResolver } from "unplugin-vue-components/resolvers";
2681
2681
  var AutoImportDeps = (isDev) => {
2682
+ console.log("isDev", isDev);
2682
2683
  return [
2683
2684
  /* 自动导入配置
2684
2685
  - imports: 声明需要自动导入的模块(vue核心API和路由API)
2685
2686
  - dts: 生成的类型声明文件路径 */
2686
2687
  AutoImport({
2687
- resolvers: [ElementPlusResolver()],
2688
+ resolvers: isDev ? [] : [ElementPlusResolver()],
2688
2689
  imports: ["vue", "vue-router", "pinia"],
2689
2690
  dts: "types/auto-imports.d.ts",
2690
2691
  eslintrc: {
2691
2692
  enabled: true,
2692
2693
  filepath: "./.eslintrc-auto-import.json",
2693
2694
  globalsPropValue: true
2694
- },
2695
- // 排除某些文件
2696
- exclude: ["**/node_modules/**", "**/dist/**"],
2697
- // 包含模式
2698
- include: [
2699
- /\.[tj]sx?$/,
2700
- // .ts, .tsx, .js, .jsx
2701
- /\.vue$/,
2702
- /\.vue\?vue/,
2703
- // .vue
2704
- /\.md$/
2705
- // .md
2706
- ]
2695
+ }
2707
2696
  }),
2708
2697
  /* 组件自动注册配置
2709
2698
  - globs: 组件文件匹配模式
@@ -2749,10 +2738,10 @@ dayjs.locale('zh-cn');
2749
2738
  import ElementPlus from 'element-plus';
2750
2739
  import 'element-plus/dist/index.css';
2751
2740
  import zhCn from 'element-plus/es/locale/lang/zh-cn';
2752
- import Antd from 'ant-design-vue';
2753
- import 'ant-design-vue/dist/reset.css';
2741
+ // import Antd from 'ant-design-vue';
2742
+ // import 'ant-design-vue/dist/reset.css';
2754
2743
  app.use(ElementPlus, { locale: zhCn });
2755
- app.use(Antd);
2744
+ // app.use(Antd);
2756
2745
  `,
2757
2746
  map: null
2758
2747
  };
@@ -3,12 +3,12 @@ import {
3
3
  __toESM
4
4
  } from "./chunk-6DZX6EAA.mjs";
5
5
 
6
- // ../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js
6
+ // ../node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/lodash.js
7
7
  var require_lodash = __commonJS({
8
- "../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js"(exports, module) {
8
+ "../node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/lodash.js"(exports, module) {
9
9
  (function() {
10
10
  var undefined2;
11
- var VERSION = "4.17.21";
11
+ var VERSION = "4.17.23";
12
12
  var LARGE_ARRAY_SIZE = 200;
13
13
  var CORE_ERROR_TEXT = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", FUNC_ERROR_TEXT = "Expected a function", INVALID_TEMPL_VAR_ERROR_TEXT = "Invalid `variable` option passed into `_.template`";
14
14
  var HASH_UNDEFINED = "__lodash_hash_undefined__";
@@ -1936,8 +1936,28 @@ var require_lodash = __commonJS({
1936
1936
  }
1937
1937
  function baseUnset(object, path) {
1938
1938
  path = castPath(path, object);
1939
- object = parent(object, path);
1940
- return object == null || delete object[toKey(last(path))];
1939
+ var index = -1, length = path.length;
1940
+ if (!length) {
1941
+ return true;
1942
+ }
1943
+ var isRootPrimitive = object == null || typeof object !== "object" && typeof object !== "function";
1944
+ while (++index < length) {
1945
+ var key = path[index];
1946
+ if (typeof key !== "string") {
1947
+ continue;
1948
+ }
1949
+ if (key === "__proto__" && !hasOwnProperty.call(object, "__proto__")) {
1950
+ return false;
1951
+ }
1952
+ if (key === "constructor" && index + 1 < length && typeof path[index + 1] === "string" && path[index + 1] === "prototype") {
1953
+ if (isRootPrimitive && index === 0) {
1954
+ continue;
1955
+ }
1956
+ return false;
1957
+ }
1958
+ }
1959
+ var obj = parent(object, path);
1960
+ return obj == null || delete obj[toKey(last(path))];
1941
1961
  }
1942
1962
  function baseUpdate(object, path, updater, customizer) {
1943
1963
  return baseSet(object, path, updater(baseGet(object, path)), customizer);
@@ -6551,28 +6571,6 @@ async function addVersion({ to, next, version }) {
6551
6571
  }
6552
6572
 
6553
6573
  // src/utils/dateUtils.ts
6554
- function listSort(arr, key = "no", callback) {
6555
- return arr.sort((a, b) => {
6556
- if (callback && typeof callback === "function") {
6557
- callback(a);
6558
- callback(b);
6559
- }
6560
- const aParts = a[key].toString().split(/(\d+)/).filter(Boolean);
6561
- const bParts = b[key].toString().split(/(\d+)/).filter(Boolean);
6562
- for (let i = 0; i < Math.min(aParts.length, bParts.length); i++) {
6563
- if (aParts[i] !== bParts[i]) {
6564
- const aIsNum = /^\d+$/.test(aParts[i]);
6565
- const bIsNum = /^\d+$/.test(bParts[i]);
6566
- if (aIsNum && bIsNum) {
6567
- return parseInt(aParts[i], 10) - parseInt(bParts[i], 10);
6568
- } else {
6569
- return aParts[i].localeCompare(bParts[i]);
6570
- }
6571
- }
6572
- }
6573
- return aParts.length - bParts.length;
6574
- });
6575
- }
6576
6574
  function duplicateRemovalCompleteSort(months) {
6577
6575
  if (months.length === 0) {
6578
6576
  return [];
@@ -6597,6 +6595,28 @@ function duplicateRemovalCompleteSort(months) {
6597
6595
  }
6598
6596
  return allMonths;
6599
6597
  }
6598
+ function listSort(arr, key = "no", callback) {
6599
+ return arr.sort((a, b) => {
6600
+ if (callback && typeof callback === "function") {
6601
+ callback(a);
6602
+ callback(b);
6603
+ }
6604
+ const aParts = a[key].toString().split(/(\d+)/).filter(Boolean);
6605
+ const bParts = b[key].toString().split(/(\d+)/).filter(Boolean);
6606
+ for (let i = 0; i < Math.min(aParts.length, bParts.length); i++) {
6607
+ if (aParts[i] !== bParts[i]) {
6608
+ const aIsNum = /^\d+$/.test(aParts[i]);
6609
+ const bIsNum = /^\d+$/.test(bParts[i]);
6610
+ if (aIsNum && bIsNum) {
6611
+ return parseInt(aParts[i], 10) - parseInt(bParts[i], 10);
6612
+ } else {
6613
+ return aParts[i].localeCompare(bParts[i]);
6614
+ }
6615
+ }
6616
+ }
6617
+ return aParts.length - bParts.length;
6618
+ });
6619
+ }
6600
6620
 
6601
6621
  // src/utils/numUtils.ts
6602
6622
  var roundOrTruncate = (num, fixed = 2, round = false) => {
@@ -6777,16 +6797,12 @@ var jsonp = (url, params = {}, options = {}) => {
6777
6797
 
6778
6798
  // src/utils/functionalComponent.ts
6779
6799
  import { createVNode, render } from "vue";
6780
- function createFunctionalComponent(component, options) {
6800
+ function createFunctionalComponent(component, options, appendTo = document.body) {
6781
6801
  const { slots, ...props } = options;
6782
6802
  const container = document.createElement("div");
6783
6803
  const vnode = createVNode(component, props, slots);
6784
6804
  render(vnode, container);
6785
- let fehterDom = document.body;
6786
- if (window.microApp && window.rawDocument) {
6787
- fehterDom = window.rawDocument.body;
6788
- }
6789
- fehterDom.appendChild(container.firstElementChild);
6805
+ appendTo.appendChild(container.firstElementChild);
6790
6806
  const instance = vnode.component?.exposed || {};
6791
6807
  instance.destroy = (delay = 300) => {
6792
6808
  setTimeout(() => {
@@ -6893,8 +6909,8 @@ export {
6893
6909
  updateDocumentTitle,
6894
6910
  filterMenu,
6895
6911
  setupPermission,
6896
- listSort,
6897
6912
  duplicateRemovalCompleteSort,
6913
+ listSort,
6898
6914
  roundOrTruncate,
6899
6915
  formatNumber,
6900
6916
  parseFormattedNumber,
@@ -133,7 +133,7 @@ var require_supports_color = _chunkQGM4M3NIjs.__commonJS.call(void 0, {
133
133
  // src/vite-config/index.ts
134
134
  var _vite = require('vite');
135
135
 
136
- // ../node_modules/.pnpm/@vitejs+plugin-vue@5.2.4_vite@6.4.1_@types+node@22.19.3_jiti@2.6.1_less@4.5.1_sass-embedded@1_s4xy5zaghyb6yswdann26222ty/node_modules/@vitejs/plugin-vue/dist/index.mjs
136
+ // ../node_modules/.pnpm/@vitejs+plugin-vue@5.2.4_vite@6.4.1_@types+node@22.19.7_jiti@2.6.1_less@4.5.1_sass-embedded@1_gleyv4jjxuxzkop3burc7rdxhq/node_modules/@vitejs/plugin-vue/dist/index.mjs
137
137
  var _fs = require('fs'); var _fs2 = _interopRequireDefault(_fs);
138
138
 
139
139
  var _vue = require('vue');
@@ -2679,31 +2679,20 @@ var _vite3 = require('unplugin-auto-import/vite'); var _vite4 = _interopRequireD
2679
2679
  var _vite5 = require('unplugin-vue-components/vite'); var _vite6 = _interopRequireDefault(_vite5);
2680
2680
  var _resolvers = require('unplugin-vue-components/resolvers');
2681
2681
  var AutoImportDeps = (isDev) => {
2682
+ console.log("isDev", isDev);
2682
2683
  return [
2683
2684
  /* 自动导入配置
2684
2685
  - imports: 声明需要自动导入的模块(vue核心API和路由API)
2685
2686
  - dts: 生成的类型声明文件路径 */
2686
2687
  _vite4.default.call(void 0, {
2687
- resolvers: [_resolvers.ElementPlusResolver.call(void 0, )],
2688
+ resolvers: isDev ? [] : [_resolvers.ElementPlusResolver.call(void 0, )],
2688
2689
  imports: ["vue", "vue-router", "pinia"],
2689
2690
  dts: "types/auto-imports.d.ts",
2690
2691
  eslintrc: {
2691
2692
  enabled: true,
2692
2693
  filepath: "./.eslintrc-auto-import.json",
2693
2694
  globalsPropValue: true
2694
- },
2695
- // 排除某些文件
2696
- exclude: ["**/node_modules/**", "**/dist/**"],
2697
- // 包含模式
2698
- include: [
2699
- /\.[tj]sx?$/,
2700
- // .ts, .tsx, .js, .jsx
2701
- /\.vue$/,
2702
- /\.vue\?vue/,
2703
- // .vue
2704
- /\.md$/
2705
- // .md
2706
- ]
2695
+ }
2707
2696
  }),
2708
2697
  /* 组件自动注册配置
2709
2698
  - globs: 组件文件匹配模式
@@ -2749,10 +2738,10 @@ dayjs.locale('zh-cn');
2749
2738
  import ElementPlus from 'element-plus';
2750
2739
  import 'element-plus/dist/index.css';
2751
2740
  import zhCn from 'element-plus/es/locale/lang/zh-cn';
2752
- import Antd from 'ant-design-vue';
2753
- import 'ant-design-vue/dist/reset.css';
2741
+ // import Antd from 'ant-design-vue';
2742
+ // import 'ant-design-vue/dist/reset.css';
2754
2743
  app.use(ElementPlus, { locale: zhCn });
2755
- app.use(Antd);
2744
+ // app.use(Antd);
2756
2745
  `,
2757
2746
  map: null
2758
2747
  };
@@ -3,12 +3,12 @@
3
3
 
4
4
  var _chunkQGM4M3NIjs = require('./chunk-QGM4M3NI.js');
5
5
 
6
- // ../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js
6
+ // ../node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/lodash.js
7
7
  var require_lodash = _chunkQGM4M3NIjs.__commonJS.call(void 0, {
8
- "../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js"(exports, module) {
8
+ "../node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/lodash.js"(exports, module) {
9
9
  (function() {
10
10
  var undefined2;
11
- var VERSION = "4.17.21";
11
+ var VERSION = "4.17.23";
12
12
  var LARGE_ARRAY_SIZE = 200;
13
13
  var CORE_ERROR_TEXT = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", FUNC_ERROR_TEXT = "Expected a function", INVALID_TEMPL_VAR_ERROR_TEXT = "Invalid `variable` option passed into `_.template`";
14
14
  var HASH_UNDEFINED = "__lodash_hash_undefined__";
@@ -1936,8 +1936,28 @@ var require_lodash = _chunkQGM4M3NIjs.__commonJS.call(void 0, {
1936
1936
  }
1937
1937
  function baseUnset(object, path) {
1938
1938
  path = castPath(path, object);
1939
- object = parent(object, path);
1940
- return object == null || delete object[toKey(last(path))];
1939
+ var index = -1, length = path.length;
1940
+ if (!length) {
1941
+ return true;
1942
+ }
1943
+ var isRootPrimitive = object == null || typeof object !== "object" && typeof object !== "function";
1944
+ while (++index < length) {
1945
+ var key = path[index];
1946
+ if (typeof key !== "string") {
1947
+ continue;
1948
+ }
1949
+ if (key === "__proto__" && !hasOwnProperty.call(object, "__proto__")) {
1950
+ return false;
1951
+ }
1952
+ if (key === "constructor" && index + 1 < length && typeof path[index + 1] === "string" && path[index + 1] === "prototype") {
1953
+ if (isRootPrimitive && index === 0) {
1954
+ continue;
1955
+ }
1956
+ return false;
1957
+ }
1958
+ }
1959
+ var obj = parent(object, path);
1960
+ return obj == null || delete obj[toKey(last(path))];
1941
1961
  }
1942
1962
  function baseUpdate(object, path, updater, customizer) {
1943
1963
  return baseSet(object, path, updater(baseGet(object, path)), customizer);
@@ -6551,28 +6571,6 @@ async function addVersion({ to, next, version }) {
6551
6571
  }
6552
6572
 
6553
6573
  // src/utils/dateUtils.ts
6554
- function listSort(arr, key = "no", callback) {
6555
- return arr.sort((a, b) => {
6556
- if (callback && typeof callback === "function") {
6557
- callback(a);
6558
- callback(b);
6559
- }
6560
- const aParts = a[key].toString().split(/(\d+)/).filter(Boolean);
6561
- const bParts = b[key].toString().split(/(\d+)/).filter(Boolean);
6562
- for (let i = 0; i < Math.min(aParts.length, bParts.length); i++) {
6563
- if (aParts[i] !== bParts[i]) {
6564
- const aIsNum = /^\d+$/.test(aParts[i]);
6565
- const bIsNum = /^\d+$/.test(bParts[i]);
6566
- if (aIsNum && bIsNum) {
6567
- return parseInt(aParts[i], 10) - parseInt(bParts[i], 10);
6568
- } else {
6569
- return aParts[i].localeCompare(bParts[i]);
6570
- }
6571
- }
6572
- }
6573
- return aParts.length - bParts.length;
6574
- });
6575
- }
6576
6574
  function duplicateRemovalCompleteSort(months) {
6577
6575
  if (months.length === 0) {
6578
6576
  return [];
@@ -6597,6 +6595,28 @@ function duplicateRemovalCompleteSort(months) {
6597
6595
  }
6598
6596
  return allMonths;
6599
6597
  }
6598
+ function listSort(arr, key = "no", callback) {
6599
+ return arr.sort((a, b) => {
6600
+ if (callback && typeof callback === "function") {
6601
+ callback(a);
6602
+ callback(b);
6603
+ }
6604
+ const aParts = a[key].toString().split(/(\d+)/).filter(Boolean);
6605
+ const bParts = b[key].toString().split(/(\d+)/).filter(Boolean);
6606
+ for (let i = 0; i < Math.min(aParts.length, bParts.length); i++) {
6607
+ if (aParts[i] !== bParts[i]) {
6608
+ const aIsNum = /^\d+$/.test(aParts[i]);
6609
+ const bIsNum = /^\d+$/.test(bParts[i]);
6610
+ if (aIsNum && bIsNum) {
6611
+ return parseInt(aParts[i], 10) - parseInt(bParts[i], 10);
6612
+ } else {
6613
+ return aParts[i].localeCompare(bParts[i]);
6614
+ }
6615
+ }
6616
+ }
6617
+ return aParts.length - bParts.length;
6618
+ });
6619
+ }
6600
6620
 
6601
6621
  // src/utils/numUtils.ts
6602
6622
  var roundOrTruncate = (num, fixed = 2, round = false) => {
@@ -6777,16 +6797,12 @@ var jsonp = (url, params = {}, options = {}) => {
6777
6797
 
6778
6798
  // src/utils/functionalComponent.ts
6779
6799
 
6780
- function createFunctionalComponent(component, options) {
6800
+ function createFunctionalComponent(component, options, appendTo = document.body) {
6781
6801
  const { slots, ...props } = options;
6782
6802
  const container = document.createElement("div");
6783
6803
  const vnode = _vue.createVNode.call(void 0, component, props, slots);
6784
6804
  _vue.render.call(void 0, vnode, container);
6785
- let fehterDom = document.body;
6786
- if (window.microApp && window.rawDocument) {
6787
- fehterDom = window.rawDocument.body;
6788
- }
6789
- fehterDom.appendChild(container.firstElementChild);
6805
+ appendTo.appendChild(container.firstElementChild);
6790
6806
  const instance = _optionalChain([vnode, 'access', _12 => _12.component, 'optionalAccess', _13 => _13.exposed]) || {};
6791
6807
  instance.destroy = (delay = 300) => {
6792
6808
  setTimeout(() => {
@@ -6911,7 +6927,7 @@ function store(app, option = {}) {
6911
6927
 
6912
6928
 
6913
6929
 
6914
- exports.useDbStore = useDbStore; exports.useCommonStore = useCommonStore; exports.useMenuStore = useMenuStore; exports.store = store; exports.request = request; exports.useLoginHook = useLoginHook; exports.updateDocumentTitle = updateDocumentTitle; exports.filterMenu = filterMenu; exports.setupPermission = setupPermission; exports.listSort = listSort; exports.duplicateRemovalCompleteSort = duplicateRemovalCompleteSort; exports.roundOrTruncate = roundOrTruncate; exports.formatNumber = formatNumber; exports.parseFormattedNumber = parseFormattedNumber; exports.padZero = padZero; exports.getIntegerPart = getIntegerPart; exports.getDecimalPart = getDecimalPart; exports.numberToChinese = numberToChinese; exports.clamp = clamp; exports.isInteger = isInteger; exports.isNumber = isNumber; exports.prototypeInterceptor = prototypeInterceptor; exports.timeFix = timeFix; exports.welcome = welcome; exports.encryptPwd = encryptPwd; exports.jsonp = jsonp; exports.createFunctionalComponent = createFunctionalComponent;
6930
+ exports.useDbStore = useDbStore; exports.useCommonStore = useCommonStore; exports.useMenuStore = useMenuStore; exports.store = store; exports.request = request; exports.useLoginHook = useLoginHook; exports.updateDocumentTitle = updateDocumentTitle; exports.filterMenu = filterMenu; exports.setupPermission = setupPermission; exports.duplicateRemovalCompleteSort = duplicateRemovalCompleteSort; exports.listSort = listSort; exports.roundOrTruncate = roundOrTruncate; exports.formatNumber = formatNumber; exports.parseFormattedNumber = parseFormattedNumber; exports.padZero = padZero; exports.getIntegerPart = getIntegerPart; exports.getDecimalPart = getDecimalPart; exports.numberToChinese = numberToChinese; exports.clamp = clamp; exports.isInteger = isInteger; exports.isNumber = isNumber; exports.prototypeInterceptor = prototypeInterceptor; exports.timeFix = timeFix; exports.welcome = welcome; exports.encryptPwd = encryptPwd; exports.jsonp = jsonp; exports.createFunctionalComponent = createFunctionalComponent;
6915
6931
  /*! Bundled license information:
6916
6932
 
6917
6933
  lodash/lodash.js:
package/dist/index.d.mts CHANGED
@@ -2,7 +2,7 @@ export { FormState, clamp, createFunctionalComponent, curlParams, duplicateRemov
2
2
  export { M as MenuItem, f as filterMenu, u as updateDocumentTitle } from './index-CVmrbYyU.mjs';
3
3
  export { createBaseViteConfig } from './vite-config/index.mjs';
4
4
  export { MenuState, store, useCommonStore, useDbStore, useMenuStore } from './stores/index.mjs';
5
- export { default as createUnoConfig } from './uno-config/index.mjs';
5
+ export { createUnoConfig } from './uno-config/index.mjs';
6
6
  export { AxiosResponse } from 'axios';
7
7
  import 'vue';
8
8
  import 'vue-router';
package/dist/index.d.ts CHANGED
@@ -2,7 +2,7 @@ export { FormState, clamp, createFunctionalComponent, curlParams, duplicateRemov
2
2
  export { M as MenuItem, f as filterMenu, u as updateDocumentTitle } from './index-CVmrbYyU.js';
3
3
  export { createBaseViteConfig } from './vite-config/index.js';
4
4
  export { MenuState, store, useCommonStore, useDbStore, useMenuStore } from './stores/index.js';
5
- export { default as createUnoConfig } from './uno-config/index.js';
5
+ export { createUnoConfig } from './uno-config/index.js';
6
6
  export { AxiosResponse } from 'axios';
7
7
  import 'vue';
8
8
  import 'vue-router';
package/dist/index.js CHANGED
@@ -1,6 +1,5 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunk3YUIFF3Jjs = require('./chunk-3YUIFF3J.js');
4
3
 
5
4
 
6
5
 
@@ -27,12 +26,13 @@ var _chunk3YUIFF3Jjs = require('./chunk-3YUIFF3J.js');
27
26
 
28
27
 
29
28
 
29
+ var _chunkXG4QH5XRjs = require('./chunk-XG4QH5XR.js');
30
30
 
31
31
 
32
- var _chunkCJEP5MIFjs = require('./chunk-CJEP5MIF.js');
32
+ var _chunk3YUIFF3Jjs = require('./chunk-3YUIFF3J.js');
33
33
 
34
34
 
35
- var _chunkMK3PQX5Cjs = require('./chunk-MK3PQX5C.js');
35
+ var _chunkE2NL4CGMjs = require('./chunk-E2NL4CGM.js');
36
36
  require('./chunk-QGM4M3NI.js');
37
37
 
38
38
 
@@ -64,4 +64,4 @@ require('./chunk-QGM4M3NI.js');
64
64
 
65
65
 
66
66
 
67
- exports.clamp = _chunkCJEP5MIFjs.clamp; exports.createBaseViteConfig = _chunkMK3PQX5Cjs.createBaseViteConfig; exports.createFunctionalComponent = _chunkCJEP5MIFjs.createFunctionalComponent; exports.createUnoConfig = _chunk3YUIFF3Jjs.createUnoConfig; exports.duplicateRemovalCompleteSort = _chunkCJEP5MIFjs.duplicateRemovalCompleteSort; exports.encryptPwd = _chunkCJEP5MIFjs.encryptPwd; exports.filterMenu = _chunkCJEP5MIFjs.filterMenu; exports.formatNumber = _chunkCJEP5MIFjs.formatNumber; exports.getDecimalPart = _chunkCJEP5MIFjs.getDecimalPart; exports.getIntegerPart = _chunkCJEP5MIFjs.getIntegerPart; exports.isInteger = _chunkCJEP5MIFjs.isInteger; exports.isNumber = _chunkCJEP5MIFjs.isNumber; exports.jsonp = _chunkCJEP5MIFjs.jsonp; exports.listSort = _chunkCJEP5MIFjs.listSort; exports.numberToChinese = _chunkCJEP5MIFjs.numberToChinese; exports.padZero = _chunkCJEP5MIFjs.padZero; exports.parseFormattedNumber = _chunkCJEP5MIFjs.parseFormattedNumber; exports.prototypeInterceptor = _chunkCJEP5MIFjs.prototypeInterceptor; exports.request = _chunkCJEP5MIFjs.request; exports.roundOrTruncate = _chunkCJEP5MIFjs.roundOrTruncate; exports.setupPermission = _chunkCJEP5MIFjs.setupPermission; exports.store = _chunkCJEP5MIFjs.store; exports.timeFix = _chunkCJEP5MIFjs.timeFix; exports.updateDocumentTitle = _chunkCJEP5MIFjs.updateDocumentTitle; exports.useCommonStore = _chunkCJEP5MIFjs.useCommonStore; exports.useDbStore = _chunkCJEP5MIFjs.useDbStore; exports.useLoginHook = _chunkCJEP5MIFjs.useLoginHook; exports.useMenuStore = _chunkCJEP5MIFjs.useMenuStore; exports.welcome = _chunkCJEP5MIFjs.welcome;
67
+ exports.clamp = _chunkXG4QH5XRjs.clamp; exports.createBaseViteConfig = _chunkE2NL4CGMjs.createBaseViteConfig; exports.createFunctionalComponent = _chunkXG4QH5XRjs.createFunctionalComponent; exports.createUnoConfig = _chunk3YUIFF3Jjs.createUnoConfig; exports.duplicateRemovalCompleteSort = _chunkXG4QH5XRjs.duplicateRemovalCompleteSort; exports.encryptPwd = _chunkXG4QH5XRjs.encryptPwd; exports.filterMenu = _chunkXG4QH5XRjs.filterMenu; exports.formatNumber = _chunkXG4QH5XRjs.formatNumber; exports.getDecimalPart = _chunkXG4QH5XRjs.getDecimalPart; exports.getIntegerPart = _chunkXG4QH5XRjs.getIntegerPart; exports.isInteger = _chunkXG4QH5XRjs.isInteger; exports.isNumber = _chunkXG4QH5XRjs.isNumber; exports.jsonp = _chunkXG4QH5XRjs.jsonp; exports.listSort = _chunkXG4QH5XRjs.listSort; exports.numberToChinese = _chunkXG4QH5XRjs.numberToChinese; exports.padZero = _chunkXG4QH5XRjs.padZero; exports.parseFormattedNumber = _chunkXG4QH5XRjs.parseFormattedNumber; exports.prototypeInterceptor = _chunkXG4QH5XRjs.prototypeInterceptor; exports.request = _chunkXG4QH5XRjs.request; exports.roundOrTruncate = _chunkXG4QH5XRjs.roundOrTruncate; exports.setupPermission = _chunkXG4QH5XRjs.setupPermission; exports.store = _chunkXG4QH5XRjs.store; exports.timeFix = _chunkXG4QH5XRjs.timeFix; exports.updateDocumentTitle = _chunkXG4QH5XRjs.updateDocumentTitle; exports.useCommonStore = _chunkXG4QH5XRjs.useCommonStore; exports.useDbStore = _chunkXG4QH5XRjs.useDbStore; exports.useLoginHook = _chunkXG4QH5XRjs.useLoginHook; exports.useMenuStore = _chunkXG4QH5XRjs.useMenuStore; exports.welcome = _chunkXG4QH5XRjs.welcome;
package/dist/index.mjs CHANGED
@@ -1,6 +1,3 @@
1
- import {
2
- createUnoConfig
3
- } from "./chunk-H523LVQA.mjs";
4
1
  import {
5
2
  clamp,
6
3
  createFunctionalComponent,
@@ -29,10 +26,13 @@ import {
29
26
  useLoginHook,
30
27
  useMenuStore,
31
28
  welcome
32
- } from "./chunk-O3ACFTLV.mjs";
29
+ } from "./chunk-4GJAFMU3.mjs";
30
+ import {
31
+ createUnoConfig
32
+ } from "./chunk-H523LVQA.mjs";
33
33
  import {
34
34
  createBaseViteConfig
35
- } from "./chunk-U32ANOUZ.mjs";
35
+ } from "./chunk-3RKXPRXY.mjs";
36
36
  import "./chunk-6DZX6EAA.mjs";
37
37
  export {
38
38
  clamp,
@@ -3,11 +3,11 @@
3
3
 
4
4
 
5
5
 
6
- var _chunkCJEP5MIFjs = require('../chunk-CJEP5MIF.js');
6
+ var _chunkXG4QH5XRjs = require('../chunk-XG4QH5XR.js');
7
7
  require('../chunk-QGM4M3NI.js');
8
8
 
9
9
 
10
10
 
11
11
 
12
12
 
13
- exports.store = _chunkCJEP5MIFjs.store; exports.useCommonStore = _chunkCJEP5MIFjs.useCommonStore; exports.useDbStore = _chunkCJEP5MIFjs.useDbStore; exports.useMenuStore = _chunkCJEP5MIFjs.useMenuStore;
13
+ exports.store = _chunkXG4QH5XRjs.store; exports.useCommonStore = _chunkXG4QH5XRjs.useCommonStore; exports.useDbStore = _chunkXG4QH5XRjs.useDbStore; exports.useMenuStore = _chunkXG4QH5XRjs.useMenuStore;
@@ -3,7 +3,7 @@ import {
3
3
  useCommonStore,
4
4
  useDbStore,
5
5
  useMenuStore
6
- } from "../chunk-O3ACFTLV.mjs";
6
+ } from "../chunk-4GJAFMU3.mjs";
7
7
  import "../chunk-6DZX6EAA.mjs";
8
8
  export {
9
9
  store,
@@ -49,14 +49,6 @@ declare const useLoginHook: (curl: Function, params: {
49
49
  */
50
50
  declare function setupPermission(router: Router, useMenuStore: any, pages: any, useUserStore: any): void;
51
51
 
52
- /**
53
- * 清单排序函数,支持按指定字段进行自然排序
54
- * @param arr 需要排序的数组
55
- * @param key 排序依据的字段名,默认为'no'
56
- * @param callback 排序前对每个元素执行的回调函数
57
- * @returns 排序后的数组
58
- */
59
- declare function listSort<T extends Record<string, any>>(arr: T[], key?: string, callback?: (item: T) => void): T[];
60
52
  /**
61
53
  * 月份去重、补齐、排序
62
54
  * @param months - 包含月份信息的数组,每个元素应包含key属性,格式为'YYYY-MM'
@@ -69,6 +61,14 @@ declare function duplicateRemovalCompleteSort(months: Array<{
69
61
  label: string;
70
62
  align: string;
71
63
  }>;
64
+ /**
65
+ * 清单排序函数,支持按指定字段进行自然排序
66
+ * @param arr 需要排序的数组
67
+ * @param key 排序依据的字段名,默认为'no'
68
+ * @param callback 排序前对每个元素执行的回调函数
69
+ * @returns 排序后的数组
70
+ */
71
+ declare function listSort<T extends Record<string, any>>(arr: T[], key?: string, callback?: (item: T) => void): T[];
72
72
 
73
73
  /**
74
74
  * 截断或四舍五入数字到指定小数位数
@@ -160,8 +160,9 @@ declare const jsonp: <T = any>(url: string, params?: Record<string, any>, option
160
160
  * @description 创建函数式组件实例,支持动态挂载和销毁
161
161
  * @param component 需要创建的Vue组件
162
162
  * @param options 组件的配置项,包含props、provide和slots
163
+ * @param appendTo 指定组件挂载的父元素,默认为document.body
163
164
  * @returns 返回组件实例,包含destroy方法用于销毁组件
164
165
  */
165
- declare function createFunctionalComponent(component: any, options: Record<string, any>): Record<string, any>;
166
+ declare function createFunctionalComponent(component: any, options: Record<string, any>, appendTo?: HTMLElement): Record<string, any>;
166
167
 
167
168
  export { type FormState, clamp, createFunctionalComponent, type curlParams, duplicateRemovalCompleteSort, encryptPwd, formatNumber, getDecimalPart, getIntegerPart, isInteger, isNumber, jsonp, listSort, numberToChinese, padZero, parseFormattedNumber, prototypeInterceptor, request, roundOrTruncate, setupPermission, timeFix, useLoginHook, welcome };
@@ -49,14 +49,6 @@ declare const useLoginHook: (curl: Function, params: {
49
49
  */
50
50
  declare function setupPermission(router: Router, useMenuStore: any, pages: any, useUserStore: any): void;
51
51
 
52
- /**
53
- * 清单排序函数,支持按指定字段进行自然排序
54
- * @param arr 需要排序的数组
55
- * @param key 排序依据的字段名,默认为'no'
56
- * @param callback 排序前对每个元素执行的回调函数
57
- * @returns 排序后的数组
58
- */
59
- declare function listSort<T extends Record<string, any>>(arr: T[], key?: string, callback?: (item: T) => void): T[];
60
52
  /**
61
53
  * 月份去重、补齐、排序
62
54
  * @param months - 包含月份信息的数组,每个元素应包含key属性,格式为'YYYY-MM'
@@ -69,6 +61,14 @@ declare function duplicateRemovalCompleteSort(months: Array<{
69
61
  label: string;
70
62
  align: string;
71
63
  }>;
64
+ /**
65
+ * 清单排序函数,支持按指定字段进行自然排序
66
+ * @param arr 需要排序的数组
67
+ * @param key 排序依据的字段名,默认为'no'
68
+ * @param callback 排序前对每个元素执行的回调函数
69
+ * @returns 排序后的数组
70
+ */
71
+ declare function listSort<T extends Record<string, any>>(arr: T[], key?: string, callback?: (item: T) => void): T[];
72
72
 
73
73
  /**
74
74
  * 截断或四舍五入数字到指定小数位数
@@ -160,8 +160,9 @@ declare const jsonp: <T = any>(url: string, params?: Record<string, any>, option
160
160
  * @description 创建函数式组件实例,支持动态挂载和销毁
161
161
  * @param component 需要创建的Vue组件
162
162
  * @param options 组件的配置项,包含props、provide和slots
163
+ * @param appendTo 指定组件挂载的父元素,默认为document.body
163
164
  * @returns 返回组件实例,包含destroy方法用于销毁组件
164
165
  */
165
- declare function createFunctionalComponent(component: any, options: Record<string, any>): Record<string, any>;
166
+ declare function createFunctionalComponent(component: any, options: Record<string, any>, appendTo?: HTMLElement): Record<string, any>;
166
167
 
167
168
  export { type FormState, clamp, createFunctionalComponent, type curlParams, duplicateRemovalCompleteSort, encryptPwd, formatNumber, getDecimalPart, getIntegerPart, isInteger, isNumber, jsonp, listSort, numberToChinese, padZero, parseFormattedNumber, prototypeInterceptor, request, roundOrTruncate, setupPermission, timeFix, useLoginHook, welcome };
@@ -22,7 +22,7 @@
22
22
 
23
23
 
24
24
 
25
- var _chunkCJEP5MIFjs = require('../chunk-CJEP5MIF.js');
25
+ var _chunkXG4QH5XRjs = require('../chunk-XG4QH5XR.js');
26
26
  require('../chunk-QGM4M3NI.js');
27
27
 
28
28
 
@@ -48,4 +48,4 @@ require('../chunk-QGM4M3NI.js');
48
48
 
49
49
 
50
50
 
51
- exports.clamp = _chunkCJEP5MIFjs.clamp; exports.createFunctionalComponent = _chunkCJEP5MIFjs.createFunctionalComponent; exports.duplicateRemovalCompleteSort = _chunkCJEP5MIFjs.duplicateRemovalCompleteSort; exports.encryptPwd = _chunkCJEP5MIFjs.encryptPwd; exports.filterMenu = _chunkCJEP5MIFjs.filterMenu; exports.formatNumber = _chunkCJEP5MIFjs.formatNumber; exports.getDecimalPart = _chunkCJEP5MIFjs.getDecimalPart; exports.getIntegerPart = _chunkCJEP5MIFjs.getIntegerPart; exports.isInteger = _chunkCJEP5MIFjs.isInteger; exports.isNumber = _chunkCJEP5MIFjs.isNumber; exports.jsonp = _chunkCJEP5MIFjs.jsonp; exports.listSort = _chunkCJEP5MIFjs.listSort; exports.numberToChinese = _chunkCJEP5MIFjs.numberToChinese; exports.padZero = _chunkCJEP5MIFjs.padZero; exports.parseFormattedNumber = _chunkCJEP5MIFjs.parseFormattedNumber; exports.prototypeInterceptor = _chunkCJEP5MIFjs.prototypeInterceptor; exports.request = _chunkCJEP5MIFjs.request; exports.roundOrTruncate = _chunkCJEP5MIFjs.roundOrTruncate; exports.setupPermission = _chunkCJEP5MIFjs.setupPermission; exports.timeFix = _chunkCJEP5MIFjs.timeFix; exports.updateDocumentTitle = _chunkCJEP5MIFjs.updateDocumentTitle; exports.useLoginHook = _chunkCJEP5MIFjs.useLoginHook; exports.welcome = _chunkCJEP5MIFjs.welcome;
51
+ exports.clamp = _chunkXG4QH5XRjs.clamp; exports.createFunctionalComponent = _chunkXG4QH5XRjs.createFunctionalComponent; exports.duplicateRemovalCompleteSort = _chunkXG4QH5XRjs.duplicateRemovalCompleteSort; exports.encryptPwd = _chunkXG4QH5XRjs.encryptPwd; exports.filterMenu = _chunkXG4QH5XRjs.filterMenu; exports.formatNumber = _chunkXG4QH5XRjs.formatNumber; exports.getDecimalPart = _chunkXG4QH5XRjs.getDecimalPart; exports.getIntegerPart = _chunkXG4QH5XRjs.getIntegerPart; exports.isInteger = _chunkXG4QH5XRjs.isInteger; exports.isNumber = _chunkXG4QH5XRjs.isNumber; exports.jsonp = _chunkXG4QH5XRjs.jsonp; exports.listSort = _chunkXG4QH5XRjs.listSort; exports.numberToChinese = _chunkXG4QH5XRjs.numberToChinese; exports.padZero = _chunkXG4QH5XRjs.padZero; exports.parseFormattedNumber = _chunkXG4QH5XRjs.parseFormattedNumber; exports.prototypeInterceptor = _chunkXG4QH5XRjs.prototypeInterceptor; exports.request = _chunkXG4QH5XRjs.request; exports.roundOrTruncate = _chunkXG4QH5XRjs.roundOrTruncate; exports.setupPermission = _chunkXG4QH5XRjs.setupPermission; exports.timeFix = _chunkXG4QH5XRjs.timeFix; exports.updateDocumentTitle = _chunkXG4QH5XRjs.updateDocumentTitle; exports.useLoginHook = _chunkXG4QH5XRjs.useLoginHook; exports.welcome = _chunkXG4QH5XRjs.welcome;
@@ -22,7 +22,7 @@ import {
22
22
  updateDocumentTitle,
23
23
  useLoginHook,
24
24
  welcome
25
- } from "../chunk-O3ACFTLV.mjs";
25
+ } from "../chunk-4GJAFMU3.mjs";
26
26
  import "../chunk-6DZX6EAA.mjs";
27
27
  export {
28
28
  clamp,
@@ -1,7 +1,7 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkMK3PQX5Cjs = require('../chunk-MK3PQX5C.js');
3
+ var _chunkE2NL4CGMjs = require('../chunk-E2NL4CGM.js');
4
4
  require('../chunk-QGM4M3NI.js');
5
5
 
6
6
 
7
- exports.createBaseViteConfig = _chunkMK3PQX5Cjs.createBaseViteConfig;
7
+ exports.createBaseViteConfig = _chunkE2NL4CGMjs.createBaseViteConfig;
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  createBaseViteConfig
3
- } from "../chunk-U32ANOUZ.mjs";
3
+ } from "../chunk-3RKXPRXY.mjs";
4
4
  import "../chunk-6DZX6EAA.mjs";
5
5
  export {
6
6
  createBaseViteConfig
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "0.2.9",
6
+ "version": "0.3.1",
7
7
  "description": "共享工具库和类型定义",
8
8
  "author": "ebuilds",
9
9
  "license": "MIT",