ebuilds-shared 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-ZZ7LO5LB.mjs → chunk-AZ4N2JGX.mjs} +1 -1
- package/dist/{chunk-5UW4MJ6S.mjs → chunk-NYKVFN6V.mjs} +67 -2
- package/dist/{chunk-IF5NEXHC.js → chunk-RLGKFHYX.js} +67 -2
- package/dist/{chunk-3UKUH7Z2.js → chunk-TJ475X6H.js} +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +5 -3
- package/dist/index.mjs +4 -2
- package/dist/stores/index.js +2 -2
- package/dist/stores/index.mjs +1 -1
- package/dist/utils/index.d.mts +9 -1
- package/dist/utils/index.d.ts +9 -1
- package/dist/utils/index.js +4 -2
- package/dist/utils/index.mjs +3 -1
- package/dist/vite-config/index.js +2 -2
- package/dist/vite-config/index.mjs +1 -1
- package/package.json +79 -79
|
@@ -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.1_jiti@2.6.1_less@4.4.
|
|
136
|
+
// ../node_modules/.pnpm/@vitejs+plugin-vue@5.2.4_vite@6.4.1_@types+node@22.19.1_jiti@2.6.1_less@4.4.2_lightningcss@1._stoz2lgkbdb6m7i3rnemsxumxa/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";
|
|
@@ -6200,6 +6200,49 @@ var IndexedDBHelp = class {
|
|
|
6200
6200
|
}
|
|
6201
6201
|
};
|
|
6202
6202
|
|
|
6203
|
+
// src/utils/indexedDB/src/install.ts
|
|
6204
|
+
var install_default = {
|
|
6205
|
+
_indexedDBFlag: Symbol("indexedDB-help"),
|
|
6206
|
+
_help: {},
|
|
6207
|
+
// 数据库的 help 的集合,以便于支持多个数据库
|
|
6208
|
+
/**
|
|
6209
|
+
* 根据参数创建一个数据库的实例,初始化数据库
|
|
6210
|
+
* * 删表、建表、添加默认数据
|
|
6211
|
+
* @param {*} info 参数
|
|
6212
|
+
* @returns
|
|
6213
|
+
* * dbFlag: '数据库标识,区分多个数据库',
|
|
6214
|
+
* * dbConfig: { // 连接数据库
|
|
6215
|
+
* * * dbName: 'vite2-blog',
|
|
6216
|
+
* * * ver: 1.0
|
|
6217
|
+
* * },
|
|
6218
|
+
* * init: () => {}, // 初始化完成后的回调函数
|
|
6219
|
+
* * stores: {
|
|
6220
|
+
* * * storeName: { // 对象仓库名
|
|
6221
|
+
* * * * id: 'id', // 主键名称
|
|
6222
|
+
* * * * index: {
|
|
6223
|
+
* * * * * name: ture, // 索引:是否可以重复
|
|
6224
|
+
* * * * },
|
|
6225
|
+
* * * * isDeleteOldTable: false, // 是否删除之前的对象仓库
|
|
6226
|
+
* * * }
|
|
6227
|
+
* * }
|
|
6228
|
+
*/
|
|
6229
|
+
createHelp(info) {
|
|
6230
|
+
const indexedDBFlag = typeof info.dbFlag === "undefined" ? this._indexedDBFlag : info.dbFlag;
|
|
6231
|
+
const help = new IndexedDBHelp(info);
|
|
6232
|
+
this._help[indexedDBFlag] = help;
|
|
6233
|
+
return help;
|
|
6234
|
+
},
|
|
6235
|
+
// 获取静态对象里的数据库实例
|
|
6236
|
+
useDBHelp(_dbFlag) {
|
|
6237
|
+
const flag = typeof _dbFlag === "undefined" ? this._indexedDBFlag : _dbFlag;
|
|
6238
|
+
return this._help[flag];
|
|
6239
|
+
},
|
|
6240
|
+
useStores(_dbFlag) {
|
|
6241
|
+
const flag = typeof _dbFlag === "undefined" ? this._indexedDBFlag : _dbFlag;
|
|
6242
|
+
return this._help[flag].stores();
|
|
6243
|
+
}
|
|
6244
|
+
};
|
|
6245
|
+
|
|
6203
6246
|
// src/stores/modules/dbStore.ts
|
|
6204
6247
|
import { defineStore } from "pinia";
|
|
6205
6248
|
var dbConfig = {
|
|
@@ -6281,7 +6324,7 @@ var useCommonStore = defineStore2("common", {
|
|
|
6281
6324
|
return this.systemTitle;
|
|
6282
6325
|
},
|
|
6283
6326
|
getPublicUrl() {
|
|
6284
|
-
return
|
|
6327
|
+
return location.origin;
|
|
6285
6328
|
},
|
|
6286
6329
|
getThemeColor() {
|
|
6287
6330
|
const result = this.themeColor || "#056DB1";
|
|
@@ -6489,6 +6532,7 @@ function setupPermission(router, useMenuStore2, pages = {}, useUserStore) {
|
|
|
6489
6532
|
if (window.microApp) {
|
|
6490
6533
|
const data = window.microApp.getData();
|
|
6491
6534
|
if (data.userState) {
|
|
6535
|
+
data.userState.toPath = to.path;
|
|
6492
6536
|
userStore.setState(data.userState);
|
|
6493
6537
|
}
|
|
6494
6538
|
}
|
|
@@ -6760,6 +6804,26 @@ var jsonp = (url, params = {}, options = {}) => {
|
|
|
6760
6804
|
});
|
|
6761
6805
|
};
|
|
6762
6806
|
|
|
6807
|
+
// src/utils/functionalComponent.ts
|
|
6808
|
+
import { createVNode, render } from "vue";
|
|
6809
|
+
function createFunctionalComponent(component, options) {
|
|
6810
|
+
const { slots, ...props } = options;
|
|
6811
|
+
const container = document.createElement("div");
|
|
6812
|
+
const vnode = createVNode(component, props, slots);
|
|
6813
|
+
render(vnode, container);
|
|
6814
|
+
document.body.appendChild(container.firstElementChild);
|
|
6815
|
+
const instance = vnode.component?.exposed || {};
|
|
6816
|
+
instance.destroy = (delay = 300) => {
|
|
6817
|
+
setTimeout(() => {
|
|
6818
|
+
render(null, container);
|
|
6819
|
+
if (container.firstElementChild) {
|
|
6820
|
+
document.body.removeChild(container.firstElementChild);
|
|
6821
|
+
}
|
|
6822
|
+
}, delay);
|
|
6823
|
+
};
|
|
6824
|
+
return instance;
|
|
6825
|
+
}
|
|
6826
|
+
|
|
6763
6827
|
// src/stores/modules/menuStore.ts
|
|
6764
6828
|
var handleRoutes = (routes, pages) => {
|
|
6765
6829
|
return routes.map((route) => {
|
|
@@ -6864,7 +6928,8 @@ export {
|
|
|
6864
6928
|
timeFix,
|
|
6865
6929
|
welcome,
|
|
6866
6930
|
encryptPwd,
|
|
6867
|
-
jsonp
|
|
6931
|
+
jsonp,
|
|
6932
|
+
createFunctionalComponent
|
|
6868
6933
|
};
|
|
6869
6934
|
/*! Bundled license information:
|
|
6870
6935
|
|
|
@@ -6200,6 +6200,49 @@ var IndexedDBHelp = class {
|
|
|
6200
6200
|
}
|
|
6201
6201
|
};
|
|
6202
6202
|
|
|
6203
|
+
// src/utils/indexedDB/src/install.ts
|
|
6204
|
+
var install_default = {
|
|
6205
|
+
_indexedDBFlag: Symbol("indexedDB-help"),
|
|
6206
|
+
_help: {},
|
|
6207
|
+
// 数据库的 help 的集合,以便于支持多个数据库
|
|
6208
|
+
/**
|
|
6209
|
+
* 根据参数创建一个数据库的实例,初始化数据库
|
|
6210
|
+
* * 删表、建表、添加默认数据
|
|
6211
|
+
* @param {*} info 参数
|
|
6212
|
+
* @returns
|
|
6213
|
+
* * dbFlag: '数据库标识,区分多个数据库',
|
|
6214
|
+
* * dbConfig: { // 连接数据库
|
|
6215
|
+
* * * dbName: 'vite2-blog',
|
|
6216
|
+
* * * ver: 1.0
|
|
6217
|
+
* * },
|
|
6218
|
+
* * init: () => {}, // 初始化完成后的回调函数
|
|
6219
|
+
* * stores: {
|
|
6220
|
+
* * * storeName: { // 对象仓库名
|
|
6221
|
+
* * * * id: 'id', // 主键名称
|
|
6222
|
+
* * * * index: {
|
|
6223
|
+
* * * * * name: ture, // 索引:是否可以重复
|
|
6224
|
+
* * * * },
|
|
6225
|
+
* * * * isDeleteOldTable: false, // 是否删除之前的对象仓库
|
|
6226
|
+
* * * }
|
|
6227
|
+
* * }
|
|
6228
|
+
*/
|
|
6229
|
+
createHelp(info) {
|
|
6230
|
+
const indexedDBFlag = typeof info.dbFlag === "undefined" ? this._indexedDBFlag : info.dbFlag;
|
|
6231
|
+
const help = new IndexedDBHelp(info);
|
|
6232
|
+
this._help[indexedDBFlag] = help;
|
|
6233
|
+
return help;
|
|
6234
|
+
},
|
|
6235
|
+
// 获取静态对象里的数据库实例
|
|
6236
|
+
useDBHelp(_dbFlag) {
|
|
6237
|
+
const flag = typeof _dbFlag === "undefined" ? this._indexedDBFlag : _dbFlag;
|
|
6238
|
+
return this._help[flag];
|
|
6239
|
+
},
|
|
6240
|
+
useStores(_dbFlag) {
|
|
6241
|
+
const flag = typeof _dbFlag === "undefined" ? this._indexedDBFlag : _dbFlag;
|
|
6242
|
+
return this._help[flag].stores();
|
|
6243
|
+
}
|
|
6244
|
+
};
|
|
6245
|
+
|
|
6203
6246
|
// src/stores/modules/dbStore.ts
|
|
6204
6247
|
|
|
6205
6248
|
var dbConfig = {
|
|
@@ -6281,7 +6324,7 @@ var useCommonStore = _pinia.defineStore.call(void 0, "common", {
|
|
|
6281
6324
|
return this.systemTitle;
|
|
6282
6325
|
},
|
|
6283
6326
|
getPublicUrl() {
|
|
6284
|
-
return
|
|
6327
|
+
return location.origin;
|
|
6285
6328
|
},
|
|
6286
6329
|
getThemeColor() {
|
|
6287
6330
|
const result = this.themeColor || "#056DB1";
|
|
@@ -6489,6 +6532,7 @@ function setupPermission(router, useMenuStore2, pages = {}, useUserStore) {
|
|
|
6489
6532
|
if (window.microApp) {
|
|
6490
6533
|
const data = window.microApp.getData();
|
|
6491
6534
|
if (data.userState) {
|
|
6535
|
+
data.userState.toPath = to.path;
|
|
6492
6536
|
userStore.setState(data.userState);
|
|
6493
6537
|
}
|
|
6494
6538
|
}
|
|
@@ -6760,6 +6804,26 @@ var jsonp = (url, params = {}, options = {}) => {
|
|
|
6760
6804
|
});
|
|
6761
6805
|
};
|
|
6762
6806
|
|
|
6807
|
+
// src/utils/functionalComponent.ts
|
|
6808
|
+
|
|
6809
|
+
function createFunctionalComponent(component, options) {
|
|
6810
|
+
const { slots, ...props } = options;
|
|
6811
|
+
const container = document.createElement("div");
|
|
6812
|
+
const vnode = _vue.createVNode.call(void 0, component, props, slots);
|
|
6813
|
+
_vue.render.call(void 0, vnode, container);
|
|
6814
|
+
document.body.appendChild(container.firstElementChild);
|
|
6815
|
+
const instance = _optionalChain([vnode, 'access', _12 => _12.component, 'optionalAccess', _13 => _13.exposed]) || {};
|
|
6816
|
+
instance.destroy = (delay = 300) => {
|
|
6817
|
+
setTimeout(() => {
|
|
6818
|
+
_vue.render.call(void 0, null, container);
|
|
6819
|
+
if (container.firstElementChild) {
|
|
6820
|
+
document.body.removeChild(container.firstElementChild);
|
|
6821
|
+
}
|
|
6822
|
+
}, delay);
|
|
6823
|
+
};
|
|
6824
|
+
return instance;
|
|
6825
|
+
}
|
|
6826
|
+
|
|
6763
6827
|
// src/stores/modules/menuStore.ts
|
|
6764
6828
|
var handleRoutes = (routes, pages) => {
|
|
6765
6829
|
return routes.map((route) => {
|
|
@@ -6865,7 +6929,8 @@ function store(app, option = {}) {
|
|
|
6865
6929
|
|
|
6866
6930
|
|
|
6867
6931
|
|
|
6868
|
-
|
|
6932
|
+
|
|
6933
|
+
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;
|
|
6869
6934
|
/*! Bundled license information:
|
|
6870
6935
|
|
|
6871
6936
|
lodash/lodash.js:
|
|
@@ -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.1_jiti@2.6.1_less@4.4.
|
|
136
|
+
// ../node_modules/.pnpm/@vitejs+plugin-vue@5.2.4_vite@6.4.1_@types+node@22.19.1_jiti@2.6.1_less@4.4.2_lightningcss@1._stoz2lgkbdb6m7i3rnemsxumxa/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');
|
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { FormState, clamp, curlParams, duplicateRemovalCompleteSort, encryptPwd, formatNumber, getDecimalPart, getIntegerPart, isInteger, isNumber, jsonp, listSort, numberToChinese, padZero, parseFormattedNumber, prototypeInterceptor, request, roundOrTruncate, setupPermission, timeFix, useLoginHook, welcome } from './utils/index.mjs';
|
|
1
|
+
export { FormState, clamp, createFunctionalComponent, curlParams, duplicateRemovalCompleteSort, encryptPwd, formatNumber, getDecimalPart, getIntegerPart, isInteger, isNumber, jsonp, listSort, numberToChinese, padZero, parseFormattedNumber, prototypeInterceptor, request, roundOrTruncate, setupPermission, timeFix, useLoginHook, welcome } from './utils/index.mjs';
|
|
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';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { FormState, clamp, curlParams, duplicateRemovalCompleteSort, encryptPwd, formatNumber, getDecimalPart, getIntegerPart, isInteger, isNumber, jsonp, listSort, numberToChinese, padZero, parseFormattedNumber, prototypeInterceptor, request, roundOrTruncate, setupPermission, timeFix, useLoginHook, welcome } from './utils/index.js';
|
|
1
|
+
export { FormState, clamp, createFunctionalComponent, curlParams, duplicateRemovalCompleteSort, encryptPwd, formatNumber, getDecimalPart, getIntegerPart, isInteger, isNumber, jsonp, listSort, numberToChinese, padZero, parseFormattedNumber, prototypeInterceptor, request, roundOrTruncate, setupPermission, timeFix, useLoginHook, welcome } from './utils/index.js';
|
|
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';
|
package/dist/index.js
CHANGED
|
@@ -28,10 +28,11 @@ var _chunkCUXFXKGWjs = require('./chunk-CUXFXKGW.js');
|
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
var _chunkIF5NEXHCjs = require('./chunk-IF5NEXHC.js');
|
|
32
31
|
|
|
32
|
+
var _chunkRLGKFHYXjs = require('./chunk-RLGKFHYX.js');
|
|
33
33
|
|
|
34
|
-
|
|
34
|
+
|
|
35
|
+
var _chunkTJ475X6Hjs = require('./chunk-TJ475X6H.js');
|
|
35
36
|
require('./chunk-QGM4M3NI.js');
|
|
36
37
|
|
|
37
38
|
|
|
@@ -62,4 +63,5 @@ require('./chunk-QGM4M3NI.js');
|
|
|
62
63
|
|
|
63
64
|
|
|
64
65
|
|
|
65
|
-
|
|
66
|
+
|
|
67
|
+
exports.clamp = _chunkRLGKFHYXjs.clamp; exports.createBaseViteConfig = _chunkTJ475X6Hjs.createBaseViteConfig; exports.createFunctionalComponent = _chunkRLGKFHYXjs.createFunctionalComponent; exports.createUnoConfig = _chunkCUXFXKGWjs.createUnoConfig; exports.duplicateRemovalCompleteSort = _chunkRLGKFHYXjs.duplicateRemovalCompleteSort; exports.encryptPwd = _chunkRLGKFHYXjs.encryptPwd; exports.filterMenu = _chunkRLGKFHYXjs.filterMenu; exports.formatNumber = _chunkRLGKFHYXjs.formatNumber; exports.getDecimalPart = _chunkRLGKFHYXjs.getDecimalPart; exports.getIntegerPart = _chunkRLGKFHYXjs.getIntegerPart; exports.isInteger = _chunkRLGKFHYXjs.isInteger; exports.isNumber = _chunkRLGKFHYXjs.isNumber; exports.jsonp = _chunkRLGKFHYXjs.jsonp; exports.listSort = _chunkRLGKFHYXjs.listSort; exports.numberToChinese = _chunkRLGKFHYXjs.numberToChinese; exports.padZero = _chunkRLGKFHYXjs.padZero; exports.parseFormattedNumber = _chunkRLGKFHYXjs.parseFormattedNumber; exports.prototypeInterceptor = _chunkRLGKFHYXjs.prototypeInterceptor; exports.request = _chunkRLGKFHYXjs.request; exports.roundOrTruncate = _chunkRLGKFHYXjs.roundOrTruncate; exports.setupPermission = _chunkRLGKFHYXjs.setupPermission; exports.store = _chunkRLGKFHYXjs.store; exports.timeFix = _chunkRLGKFHYXjs.timeFix; exports.updateDocumentTitle = _chunkRLGKFHYXjs.updateDocumentTitle; exports.useCommonStore = _chunkRLGKFHYXjs.useCommonStore; exports.useDbStore = _chunkRLGKFHYXjs.useDbStore; exports.useLoginHook = _chunkRLGKFHYXjs.useLoginHook; exports.useMenuStore = _chunkRLGKFHYXjs.useMenuStore; exports.welcome = _chunkRLGKFHYXjs.welcome;
|
package/dist/index.mjs
CHANGED
|
@@ -3,6 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-ESXS2BQB.mjs";
|
|
4
4
|
import {
|
|
5
5
|
clamp,
|
|
6
|
+
createFunctionalComponent,
|
|
6
7
|
duplicateRemovalCompleteSort,
|
|
7
8
|
encryptPwd,
|
|
8
9
|
filterMenu,
|
|
@@ -28,14 +29,15 @@ import {
|
|
|
28
29
|
useLoginHook,
|
|
29
30
|
useMenuStore,
|
|
30
31
|
welcome
|
|
31
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-NYKVFN6V.mjs";
|
|
32
33
|
import {
|
|
33
34
|
createBaseViteConfig
|
|
34
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-AZ4N2JGX.mjs";
|
|
35
36
|
import "./chunk-6DZX6EAA.mjs";
|
|
36
37
|
export {
|
|
37
38
|
clamp,
|
|
38
39
|
createBaseViteConfig,
|
|
40
|
+
createFunctionalComponent,
|
|
39
41
|
createUnoConfig,
|
|
40
42
|
duplicateRemovalCompleteSort,
|
|
41
43
|
encryptPwd,
|
package/dist/stores/index.js
CHANGED
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkRLGKFHYXjs = require('../chunk-RLGKFHYX.js');
|
|
7
7
|
require('../chunk-QGM4M3NI.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
exports.store =
|
|
13
|
+
exports.store = _chunkRLGKFHYXjs.store; exports.useCommonStore = _chunkRLGKFHYXjs.useCommonStore; exports.useDbStore = _chunkRLGKFHYXjs.useDbStore; exports.useMenuStore = _chunkRLGKFHYXjs.useMenuStore;
|
package/dist/stores/index.mjs
CHANGED
package/dist/utils/index.d.mts
CHANGED
|
@@ -156,4 +156,12 @@ declare const jsonp: <T = any>(url: string, params?: Record<string, any>, option
|
|
|
156
156
|
timeout?: number;
|
|
157
157
|
}) => Promise<T>;
|
|
158
158
|
|
|
159
|
-
|
|
159
|
+
/**
|
|
160
|
+
* @description 创建函数式组件实例,支持动态挂载和销毁
|
|
161
|
+
* @param component 需要创建的Vue组件
|
|
162
|
+
* @param options 组件的配置项,包含props、provide和slots
|
|
163
|
+
* @returns 返回组件实例,包含destroy方法用于销毁组件
|
|
164
|
+
*/
|
|
165
|
+
declare function createFunctionalComponent(component: any, options: Record<string, any>): Record<string, any>;
|
|
166
|
+
|
|
167
|
+
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 };
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -156,4 +156,12 @@ declare const jsonp: <T = any>(url: string, params?: Record<string, any>, option
|
|
|
156
156
|
timeout?: number;
|
|
157
157
|
}) => Promise<T>;
|
|
158
158
|
|
|
159
|
-
|
|
159
|
+
/**
|
|
160
|
+
* @description 创建函数式组件实例,支持动态挂载和销毁
|
|
161
|
+
* @param component 需要创建的Vue组件
|
|
162
|
+
* @param options 组件的配置项,包含props、provide和slots
|
|
163
|
+
* @returns 返回组件实例,包含destroy方法用于销毁组件
|
|
164
|
+
*/
|
|
165
|
+
declare function createFunctionalComponent(component: any, options: Record<string, any>): Record<string, any>;
|
|
166
|
+
|
|
167
|
+
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 };
|
package/dist/utils/index.js
CHANGED
|
@@ -21,7 +21,8 @@
|
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
|
|
25
|
+
var _chunkRLGKFHYXjs = require('../chunk-RLGKFHYX.js');
|
|
25
26
|
require('../chunk-QGM4M3NI.js');
|
|
26
27
|
|
|
27
28
|
|
|
@@ -46,4 +47,5 @@ require('../chunk-QGM4M3NI.js');
|
|
|
46
47
|
|
|
47
48
|
|
|
48
49
|
|
|
49
|
-
|
|
50
|
+
|
|
51
|
+
exports.clamp = _chunkRLGKFHYXjs.clamp; exports.createFunctionalComponent = _chunkRLGKFHYXjs.createFunctionalComponent; exports.duplicateRemovalCompleteSort = _chunkRLGKFHYXjs.duplicateRemovalCompleteSort; exports.encryptPwd = _chunkRLGKFHYXjs.encryptPwd; exports.filterMenu = _chunkRLGKFHYXjs.filterMenu; exports.formatNumber = _chunkRLGKFHYXjs.formatNumber; exports.getDecimalPart = _chunkRLGKFHYXjs.getDecimalPart; exports.getIntegerPart = _chunkRLGKFHYXjs.getIntegerPart; exports.isInteger = _chunkRLGKFHYXjs.isInteger; exports.isNumber = _chunkRLGKFHYXjs.isNumber; exports.jsonp = _chunkRLGKFHYXjs.jsonp; exports.listSort = _chunkRLGKFHYXjs.listSort; exports.numberToChinese = _chunkRLGKFHYXjs.numberToChinese; exports.padZero = _chunkRLGKFHYXjs.padZero; exports.parseFormattedNumber = _chunkRLGKFHYXjs.parseFormattedNumber; exports.prototypeInterceptor = _chunkRLGKFHYXjs.prototypeInterceptor; exports.request = _chunkRLGKFHYXjs.request; exports.roundOrTruncate = _chunkRLGKFHYXjs.roundOrTruncate; exports.setupPermission = _chunkRLGKFHYXjs.setupPermission; exports.timeFix = _chunkRLGKFHYXjs.timeFix; exports.updateDocumentTitle = _chunkRLGKFHYXjs.updateDocumentTitle; exports.useLoginHook = _chunkRLGKFHYXjs.useLoginHook; exports.welcome = _chunkRLGKFHYXjs.welcome;
|
package/dist/utils/index.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
clamp,
|
|
3
|
+
createFunctionalComponent,
|
|
3
4
|
duplicateRemovalCompleteSort,
|
|
4
5
|
encryptPwd,
|
|
5
6
|
filterMenu,
|
|
@@ -21,10 +22,11 @@ import {
|
|
|
21
22
|
updateDocumentTitle,
|
|
22
23
|
useLoginHook,
|
|
23
24
|
welcome
|
|
24
|
-
} from "../chunk-
|
|
25
|
+
} from "../chunk-NYKVFN6V.mjs";
|
|
25
26
|
import "../chunk-6DZX6EAA.mjs";
|
|
26
27
|
export {
|
|
27
28
|
clamp,
|
|
29
|
+
createFunctionalComponent,
|
|
28
30
|
duplicateRemovalCompleteSort,
|
|
29
31
|
encryptPwd,
|
|
30
32
|
filterMenu,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkTJ475X6Hjs = require('../chunk-TJ475X6H.js');
|
|
4
4
|
require('../chunk-QGM4M3NI.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
exports.createBaseViteConfig =
|
|
7
|
+
exports.createBaseViteConfig = _chunkTJ475X6Hjs.createBaseViteConfig;
|
package/package.json
CHANGED
|
@@ -1,79 +1,79 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "ebuilds-shared",
|
|
3
|
-
"publishConfig": {
|
|
4
|
-
"access": "public"
|
|
5
|
-
},
|
|
6
|
-
"version": "0.1.
|
|
7
|
-
"description": "共享工具库和类型定义",
|
|
8
|
-
"author": "ebuilds",
|
|
9
|
-
"license": "MIT",
|
|
10
|
-
"keywords": [
|
|
11
|
-
"shared",
|
|
12
|
-
"utils",
|
|
13
|
-
"vue",
|
|
14
|
-
"pinia",
|
|
15
|
-
"vite"
|
|
16
|
-
],
|
|
17
|
-
"main": "dist/index.js",
|
|
18
|
-
"module": "dist/index.mjs",
|
|
19
|
-
"types": "dist/index.d.ts",
|
|
20
|
-
"exports": {
|
|
21
|
-
".": {
|
|
22
|
-
"default": "./dist/index.mjs",
|
|
23
|
-
"import": "./dist/index.mjs",
|
|
24
|
-
"require": "./dist/index.js",
|
|
25
|
-
"types": "./dist/index.d.ts"
|
|
26
|
-
},
|
|
27
|
-
"./utils": {
|
|
28
|
-
"default": "./dist/utils/index.mjs",
|
|
29
|
-
"import": "./dist/utils/index.mjs",
|
|
30
|
-
"require": "./dist/utils/index.js",
|
|
31
|
-
"types": "./dist/utils/index.d.ts"
|
|
32
|
-
},
|
|
33
|
-
"./stores": {
|
|
34
|
-
"default": "./dist/stores/index.mjs",
|
|
35
|
-
"import": "./dist/stores/index.mjs",
|
|
36
|
-
"require": "./dist/stores/index.js",
|
|
37
|
-
"types": "./dist/stores/index.d.ts"
|
|
38
|
-
},
|
|
39
|
-
"./vite-config": {
|
|
40
|
-
"default": "./dist/vite-config/index.mjs",
|
|
41
|
-
"import": "./dist/vite-config/index.mjs",
|
|
42
|
-
"require": "./dist/vite-config/index.js",
|
|
43
|
-
"types": "./dist/vite-config/index.d.mts"
|
|
44
|
-
},
|
|
45
|
-
"./uno-config": {
|
|
46
|
-
"default": "./dist/uno-config/index.mjs",
|
|
47
|
-
"import": "./dist/uno-config/index.mjs",
|
|
48
|
-
"require": "./dist/uno-config/index.js",
|
|
49
|
-
"types": "./dist/uno-config/index.d.ts"
|
|
50
|
-
},
|
|
51
|
-
"./functionalComponent": {
|
|
52
|
-
"default": "./dist/functionalComponent/index.mjs",
|
|
53
|
-
"import": "./dist/functionalComponent/index.mjs",
|
|
54
|
-
"require": "./dist/functionalComponent/index.js",
|
|
55
|
-
"types": "./dist/functionalComponent/index.d.ts"
|
|
56
|
-
},
|
|
57
|
-
"./styles": "./dist/styles/index.css"
|
|
58
|
-
},
|
|
59
|
-
"files": [
|
|
60
|
-
"dist"
|
|
61
|
-
],
|
|
62
|
-
"scripts": {
|
|
63
|
-
"build": "tsup --config tsup.config.ts",
|
|
64
|
-
"dev": "tsup --config tsup.config.ts --watch",
|
|
65
|
-
"lint": "eslint --quiet \"src/**/*.{ts,tsx}\"",
|
|
66
|
-
"lint:fix": "eslint --quiet \"src/**/*.{ts,tsx}\" --fix",
|
|
67
|
-
"pub": "
|
|
68
|
-
},
|
|
69
|
-
"peerDependencies": {
|
|
70
|
-
"pinia": "3.0.1"
|
|
71
|
-
},
|
|
72
|
-
"dependencies": {
|
|
73
|
-
"axios": "^1.8.4",
|
|
74
|
-
"jsencrypt": "^3.3.2"
|
|
75
|
-
},
|
|
76
|
-
"devDependencies": {
|
|
77
|
-
"tsup": "^8.0.2"
|
|
78
|
-
}
|
|
79
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "ebuilds-shared",
|
|
3
|
+
"publishConfig": {
|
|
4
|
+
"access": "public"
|
|
5
|
+
},
|
|
6
|
+
"version": "0.1.3",
|
|
7
|
+
"description": "共享工具库和类型定义",
|
|
8
|
+
"author": "ebuilds",
|
|
9
|
+
"license": "MIT",
|
|
10
|
+
"keywords": [
|
|
11
|
+
"shared",
|
|
12
|
+
"utils",
|
|
13
|
+
"vue",
|
|
14
|
+
"pinia",
|
|
15
|
+
"vite"
|
|
16
|
+
],
|
|
17
|
+
"main": "dist/index.js",
|
|
18
|
+
"module": "dist/index.mjs",
|
|
19
|
+
"types": "dist/index.d.ts",
|
|
20
|
+
"exports": {
|
|
21
|
+
".": {
|
|
22
|
+
"default": "./dist/index.mjs",
|
|
23
|
+
"import": "./dist/index.mjs",
|
|
24
|
+
"require": "./dist/index.js",
|
|
25
|
+
"types": "./dist/index.d.ts"
|
|
26
|
+
},
|
|
27
|
+
"./utils": {
|
|
28
|
+
"default": "./dist/utils/index.mjs",
|
|
29
|
+
"import": "./dist/utils/index.mjs",
|
|
30
|
+
"require": "./dist/utils/index.js",
|
|
31
|
+
"types": "./dist/utils/index.d.ts"
|
|
32
|
+
},
|
|
33
|
+
"./stores": {
|
|
34
|
+
"default": "./dist/stores/index.mjs",
|
|
35
|
+
"import": "./dist/stores/index.mjs",
|
|
36
|
+
"require": "./dist/stores/index.js",
|
|
37
|
+
"types": "./dist/stores/index.d.ts"
|
|
38
|
+
},
|
|
39
|
+
"./vite-config": {
|
|
40
|
+
"default": "./dist/vite-config/index.mjs",
|
|
41
|
+
"import": "./dist/vite-config/index.mjs",
|
|
42
|
+
"require": "./dist/vite-config/index.js",
|
|
43
|
+
"types": "./dist/vite-config/index.d.mts"
|
|
44
|
+
},
|
|
45
|
+
"./uno-config": {
|
|
46
|
+
"default": "./dist/uno-config/index.mjs",
|
|
47
|
+
"import": "./dist/uno-config/index.mjs",
|
|
48
|
+
"require": "./dist/uno-config/index.js",
|
|
49
|
+
"types": "./dist/uno-config/index.d.ts"
|
|
50
|
+
},
|
|
51
|
+
"./functionalComponent": {
|
|
52
|
+
"default": "./dist/functionalComponent/index.mjs",
|
|
53
|
+
"import": "./dist/functionalComponent/index.mjs",
|
|
54
|
+
"require": "./dist/functionalComponent/index.js",
|
|
55
|
+
"types": "./dist/functionalComponent/index.d.ts"
|
|
56
|
+
},
|
|
57
|
+
"./styles": "./dist/styles/index.css"
|
|
58
|
+
},
|
|
59
|
+
"files": [
|
|
60
|
+
"dist"
|
|
61
|
+
],
|
|
62
|
+
"scripts": {
|
|
63
|
+
"build": "tsup --config tsup.config.ts",
|
|
64
|
+
"dev": "tsup --config tsup.config.ts --watch",
|
|
65
|
+
"lint": "eslint --quiet \"src/**/*.{ts,tsx}\"",
|
|
66
|
+
"lint:fix": "eslint --quiet \"src/**/*.{ts,tsx}\" --fix",
|
|
67
|
+
"pub": "npm publish"
|
|
68
|
+
},
|
|
69
|
+
"peerDependencies": {
|
|
70
|
+
"pinia": "3.0.1"
|
|
71
|
+
},
|
|
72
|
+
"dependencies": {
|
|
73
|
+
"axios": "^1.8.4",
|
|
74
|
+
"jsencrypt": "^3.3.2"
|
|
75
|
+
},
|
|
76
|
+
"devDependencies": {
|
|
77
|
+
"tsup": "^8.0.2"
|
|
78
|
+
}
|
|
79
|
+
}
|