From 4b2833aef7ed611f62c1f8eb7d185ad7890e3b14 Mon Sep 17 00:00:00 2001 From: buqiyuan <1743369777@qq.com> Date: Fri, 29 Mar 2024 01:05:45 +0800 Subject: [PATCH] fix(dynamic-table): search form schema should not be reset after table reload --- .gitignore | 1 + package.json | 10 +- packages/vite-plugin-msw/package.json | 6 +- .../vite-plugin-msw/src/browser/vitePlugin.ts | 2 +- packages/vite-plugin-msw/src/index.ts | 11 +- pnpm-lock.yaml | 400 ++++++++---------- src/components/basic/icon/src/icon-font.tsx | 3 +- .../core/dynamic-table/src/dynamic-table.vue | 3 +- .../dynamic-table/src/hooks/useTableForm.ts | 2 +- .../src/components/form-action.vue | 6 +- .../schema-form/src/hooks/useFormEvents.ts | 10 +- .../schema-form/src/hooks/useFormState.ts | 22 +- .../demos/tables/search-table/columns.tsx | 2 +- 13 files changed, 216 insertions(+), 262 deletions(-) diff --git a/.gitignore b/.gitignore index ee85ded84..56358713b 100644 --- a/.gitignore +++ b/.gitignore @@ -34,3 +34,4 @@ yarn-error.log* types/auto-imports.d.ts types/components.d.ts +packages/vite-plugin-http2-proxy \ No newline at end of file diff --git a/package.json b/package.json index 31cafa9a4..0b5a961ef 100644 --- a/package.json +++ b/package.json @@ -69,6 +69,7 @@ }, "devDependencies": { "@admin-pkg/components": "workspace:*", + "@admin-pkg/vite-plugin-http2-proxy": "workspace:^", "@admin-pkg/vite-plugin-msw": "workspace:*", "@admin-pkg/vite-plugin-tinymce-resource": "workspace:*", "@commitlint/cli": "~19.2.1", @@ -101,15 +102,14 @@ "husky": "~9.0.11", "less": "~4.2.0", "lint-staged": "~15.2.2", - "msw": "^2.2.10", + "msw": "^2.2.13", "nx": "^18.1.3", "postcss": "~8.4.38", "postcss-html": "~1.6.0", "postcss-less": "~6.0.0", "prettier": "~3.2.5", - "pretty-quick": "~4.0.0", "rimraf": "~5.0.5", - "stylelint": "~16.3.0", + "stylelint": "~16.3.1", "stylelint-config-property-sort-order-smacss": "^10.0.0", "stylelint-config-recommended": "~14.0.0", "stylelint-config-recommended-vue": "~1.5.0", @@ -117,7 +117,7 @@ "stylelint-order": "~6.0.4", "stylelint-prettier": "^5.0.0", "typescript": "~5.4.3", - "unocss": "^0.58.6", + "unocss": "^0.58.8", "unplugin-vue-components": "~0.26.0", "vite": "~5.2.6", "vite-plugin-checker": "~0.6.4", @@ -144,7 +144,7 @@ ], "license": "MIT", "target": "web", - "dependenciesMeta": { + "devDependenciesMeta": { "@admin-pkg/vite-plugin-msw": { "injected": true }, diff --git a/packages/vite-plugin-msw/package.json b/packages/vite-plugin-msw/package.json index a7c7537b8..710d1b626 100644 --- a/packages/vite-plugin-msw/package.json +++ b/packages/vite-plugin-msw/package.json @@ -42,14 +42,14 @@ "registry": "https://registry.npmjs.org/" }, "dependencies": { - "@mswjs/interceptors": "^0.26.5", - "headers-polyfill": "^4.0.2", + "@mswjs/interceptors": "^0.26.14", + "headers-polyfill": "^4.0.3", "strict-event-emitter": "^0.5.1" }, "devDependencies": { "tsup": "^8.0.2" }, "peerDependencies": { - "msw": "^2.0.0" + "msw": "^2.2.13" } } diff --git a/packages/vite-plugin-msw/src/browser/vitePlugin.ts b/packages/vite-plugin-msw/src/browser/vitePlugin.ts index ebe6bcb70..38ebd2d5a 100644 --- a/packages/vite-plugin-msw/src/browser/vitePlugin.ts +++ b/packages/vite-plugin-msw/src/browser/vitePlugin.ts @@ -10,7 +10,7 @@ const localMswDistPath = resolve(__dirname, swFileName); export const createBrowserMiddleware = (): Connect.NextHandleFunction => { return async (req, res, next) => { try { - if (req.method !== 'GET' || req.url !== `/${swFileName}`) { + if (req.method !== 'GET' || !req.url?.includes(`/${swFileName}`)) { next(); return; } diff --git a/packages/vite-plugin-msw/src/index.ts b/packages/vite-plugin-msw/src/index.ts index bdcef2c2c..76c8fd96a 100644 --- a/packages/vite-plugin-msw/src/index.ts +++ b/packages/vite-plugin-msw/src/index.ts @@ -1,7 +1,7 @@ import { createNodeMiddleware } from './node/'; import { buildMswForBrowser, createBrowserMiddleware } from './browser/vitePlugin'; import type { HttpHandler } from 'msw'; -import type { Plugin } from 'vite'; +import type { PluginOption } from 'vite'; export interface VitePluginMswOptions { mode?: 'browser' | 'node'; @@ -13,7 +13,7 @@ interface BrowserIntegrationOptions { build?: boolean; } -const browserIntegration = ({ build }: BrowserIntegrationOptions): Plugin => { +const browserIntegration = ({ build }: BrowserIntegrationOptions): PluginOption => { let outDir; return { name: 'vite-plugin-msw:browser-integration', @@ -35,7 +35,7 @@ const browserIntegration = ({ build }: BrowserIntegrationOptions): Plugin => { }; }; -const getNodeIntegration = (handlers: HttpHandler[]): Plugin => { +const getNodeIntegration = (handlers: HttpHandler[]): PluginOption => { return { name: 'vite-plugin-msw:node-integration', configureServer(devServer) { @@ -46,9 +46,8 @@ const getNodeIntegration = (handlers: HttpHandler[]): Plugin => { function vitePluginMsw( options: Omit & { mode?: 'browser' }, -): Plugin; -function vitePluginMsw(options: VitePluginMswOptions & { mode?: 'node' }): Plugin; -function vitePluginMsw(options: VitePluginMswOptions): Plugin { +): PluginOption; +function vitePluginMsw(options: VitePluginMswOptions): PluginOption { const { mode = 'browser', handlers = [], build = false } = options; if (mode === 'node') { return getNodeIntegration(handlers); diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 3353e5b63..32b7440e4 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -90,12 +90,15 @@ importers: '@admin-pkg/components': specifier: workspace:* version: link:packages/components + '@admin-pkg/vite-plugin-http2-proxy': + specifier: workspace:^ + version: link:packages/vite-plugin-http2-proxy '@admin-pkg/vite-plugin-msw': specifier: workspace:* - version: file:packages/vite-plugin-msw(msw@2.2.10) + version: link:packages/vite-plugin-msw '@admin-pkg/vite-plugin-tinymce-resource': specifier: workspace:* - version: file:packages/vite-plugin-tinymce-resource(vite@5.2.6) + version: link:packages/vite-plugin-tinymce-resource '@commitlint/cli': specifier: ~19.2.1 version: 19.2.1(@types/node@20.11.30)(typescript@5.4.3) @@ -187,8 +190,8 @@ importers: specifier: ~15.2.2 version: 15.2.2 msw: - specifier: ^2.2.10 - version: 2.2.10(typescript@5.4.3) + specifier: ^2.2.13 + version: 2.2.13(typescript@5.4.3) nx: specifier: ^18.1.3 version: 18.1.3 @@ -204,39 +207,36 @@ importers: prettier: specifier: ~3.2.5 version: 3.2.5 - pretty-quick: - specifier: ~4.0.0 - version: 4.0.0(prettier@3.2.5) rimraf: specifier: ~5.0.5 version: 5.0.5 stylelint: - specifier: ~16.3.0 - version: 16.3.0(typescript@5.4.3) + specifier: ~16.3.1 + version: 16.3.1(typescript@5.4.3) stylelint-config-property-sort-order-smacss: specifier: ^10.0.0 - version: 10.0.0(stylelint@16.3.0) + version: 10.0.0(stylelint@16.3.1) stylelint-config-recommended: specifier: ~14.0.0 - version: 14.0.0(stylelint@16.3.0) + version: 14.0.0(stylelint@16.3.1) stylelint-config-recommended-vue: specifier: ~1.5.0 - version: 1.5.0(postcss-html@1.6.0)(stylelint@16.3.0) + version: 1.5.0(postcss-html@1.6.0)(stylelint@16.3.1) stylelint-config-standard: specifier: ~36.0.0 - version: 36.0.0(stylelint@16.3.0) + version: 36.0.0(stylelint@16.3.1) stylelint-order: specifier: ~6.0.4 - version: 6.0.4(stylelint@16.3.0) + version: 6.0.4(stylelint@16.3.1) stylelint-prettier: specifier: ^5.0.0 - version: 5.0.0(prettier@3.2.5)(stylelint@16.3.0) + version: 5.0.0(prettier@3.2.5)(stylelint@16.3.1) typescript: specifier: ~5.4.3 version: 5.4.3 unocss: - specifier: ^0.58.6 - version: 0.58.6(postcss@8.4.38)(vite@5.2.6) + specifier: ^0.58.8 + version: 0.58.8(postcss@8.4.38)(vite@5.2.6) unplugin-vue-components: specifier: ~0.26.0 version: 0.26.0(vue@3.4.21) @@ -245,7 +245,7 @@ importers: version: 5.2.6(@types/node@20.11.30)(less@4.2.0) vite-plugin-checker: specifier: ~0.6.4 - version: 0.6.4(eslint@8.57.0)(stylelint@16.3.0)(typescript@5.4.3)(vite@5.2.6)(vue-tsc@1.8.27) + version: 0.6.4(eslint@8.57.0)(stylelint@16.3.1)(typescript@5.4.3)(vite@5.2.6)(vue-tsc@1.8.27) vite-plugin-inspect: specifier: ^0.8.3 version: 0.8.3(vite@5.2.6) @@ -261,11 +261,6 @@ importers: vue-tsc: specifier: ~1.8.27 version: 1.8.27(typescript@5.4.3) - dependenciesMeta: - '@admin-pkg/vite-plugin-msw': - injected: true - '@admin-pkg/vite-plugin-tinymce-resource': - injected: true packages/components: dependencies: @@ -280,17 +275,23 @@ importers: specifier: ^5.1.5 version: 5.2.6(@types/node@20.11.30)(less@4.2.0) + packages/vite-plugin-http2-proxy: + dependencies: + http2-proxy: + specifier: ^5.0.53 + version: 5.0.53 + packages/vite-plugin-msw: dependencies: '@mswjs/interceptors': - specifier: ^0.26.5 - version: 0.26.11 + specifier: ^0.26.14 + version: 0.26.14 headers-polyfill: - specifier: ^4.0.2 + specifier: ^4.0.3 version: 4.0.3 msw: - specifier: ^2.0.0 - version: 2.2.10(typescript@5.4.3) + specifier: ^2.2.13 + version: 2.2.13(typescript@5.4.3) strict-event-emitter: specifier: ^0.5.1 version: 0.5.1 @@ -2563,19 +2564,8 @@ packages: resolution: {integrity: sha512-0ZcCVQxifZmhwNBoQIrystCb+2sWBY2Zw8lpfJBPCHGCA/HWqehITeCRVIv4VMy8MPlaHo2w2pTHFV2pFfqKPw==} engines: {node: '>=18'} - /@mswjs/interceptors@0.25.16: - resolution: {integrity: sha512-8QC8JyKztvoGAdPgyZy49c9vSHHAZjHagwl4RY9E8carULk8ym3iTaiawrT1YoLF/qb449h48f71XDPgkUSOUg==} - engines: {node: '>=18'} - dependencies: - '@open-draft/deferred-promise': 2.2.0 - '@open-draft/logger': 0.3.0 - '@open-draft/until': 2.1.0 - is-node-process: 1.2.0 - outvariant: 1.4.2 - strict-event-emitter: 0.5.1 - - /@mswjs/interceptors@0.26.11: - resolution: {integrity: sha512-hSRh0Ia1br2vf+Tec++btQ402XM+IcAqqGdbka54h1HkxIZUc7s2WpJux1Cfke0ubequL2BkNg4Be3xKfvehGA==} + /@mswjs/interceptors@0.26.14: + resolution: {integrity: sha512-q4S8RGjOUzv3A3gCawuKkUEcNJXjdPaSqoRHFvuZPWQnc7yOw702iGBRDMJoBK+l0KSv9XN8YP5ek6duRzrpqw==} engines: {node: '>=18'} dependencies: '@open-draft/deferred-promise': 2.2.0 @@ -3514,32 +3504,32 @@ packages: resolution: {integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==} dev: true - /@unocss/astro@0.58.6(vite@5.2.6): - resolution: {integrity: sha512-0BvbhEp5Ln6wFNnhISusB2hcfycWkdgnjlFMcLT69efvj4G39MzB6JYT/1qiidLfpj35HcqkpBz7TfZ4bUmOAw==} + /@unocss/astro@0.58.8(vite@5.2.6): + resolution: {integrity: sha512-pAjsKuVg41dXNPWpFKx/SDxz198Miu/hqAL4lMkE2ITY+nFgqt9SH1lGS9P+VzElrHZ+Uqwmmtw8SjaT2EfCMA==} peerDependencies: vite: ^2.9.0 || ^3.0.0-0 || ^4.0.0 || ^5.0.0-0 peerDependenciesMeta: vite: optional: true dependencies: - '@unocss/core': 0.58.6 - '@unocss/reset': 0.58.6 - '@unocss/vite': 0.58.6(vite@5.2.6) + '@unocss/core': 0.58.8 + '@unocss/reset': 0.58.8 + '@unocss/vite': 0.58.8(vite@5.2.6) vite: 5.2.6(@types/node@20.11.30)(less@4.2.0) transitivePeerDependencies: - rollup dev: true - /@unocss/cli@0.58.6: - resolution: {integrity: sha512-cfJBiEAKElo9vcA4ZU1WTXeUha5qVBtn3+ZjgdgOvveSX0oY0gOheG+DD2LaEjwWzjCstFU38lblUHWzHRv0sQ==} + /@unocss/cli@0.58.8: + resolution: {integrity: sha512-TxFyrMPBuPPkyvW1oJ+f9Q0IOX7hXcuZqmFzsv7n153HXHU6fZCNxFzqbOWUR2K1eS4ScBREjIOWZYekXx7s2g==} engines: {node: '>=14'} hasBin: true dependencies: '@ampproject/remapping': 2.3.0 '@rollup/pluginutils': 5.1.0 - '@unocss/config': 0.58.6 - '@unocss/core': 0.58.6 - '@unocss/preset-uno': 0.58.6 + '@unocss/config': 0.58.8 + '@unocss/core': 0.58.8 + '@unocss/preset-uno': 0.58.8 cac: 6.7.14 chokidar: 3.6.0 colorette: 2.0.20 @@ -3552,174 +3542,174 @@ packages: - rollup dev: true - /@unocss/config@0.58.6: - resolution: {integrity: sha512-YyywfigaEzGkDJ0ztp/tvruD+0xfdCcMZUvaGH4IElAwZDdcSsuaHdR1HW3EixCETOyFHBcuFk6sJwfLPIZLTw==} + /@unocss/config@0.58.8: + resolution: {integrity: sha512-x0/FCP1vuU7z2Y1e4m5fazLEr9DyXQZ9aM8Rt72V8ElD9CmEwxGmxt6MVB+LkuXglH3srr9Btnhuir4P6jI92g==} engines: {node: '>=14'} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 unconfig: 0.3.11 dev: true - /@unocss/core@0.58.6: - resolution: {integrity: sha512-m87iuENM/PLqLKnfE2mJbpfzj7NQ99LP2go0r+x5X4kXKppyGRJNQg6RIW3AqTS22jup1YPgd62UNXvvRtHtww==} + /@unocss/core@0.58.8: + resolution: {integrity: sha512-R3KuNTzF6G+bb2Qqg4LNLTWHh4TGU8iQJ4KOlpWHrPKAhDSCZ3XY9lSXoepCPwv+JcGEwA97Msa3zZ5p+QDoFg==} dev: true - /@unocss/extractor-arbitrary-variants@0.58.6: - resolution: {integrity: sha512-iSrjLEM+dtcpCmJ8myttPZ/0Dg4HKYVYpM71rNTybrX1HB/cfRsGwIHobjsvvRnve+LAxC4Hmdi8EXRd8V1xPg==} + /@unocss/extractor-arbitrary-variants@0.58.8: + resolution: {integrity: sha512-zQ7W3wTWWbJvG9T+1b9HqJGtEzcrc3d/TG7JJqdon6vBc64xA2AMf9DNRVlNdzkrU2Kl31TRd6bLST6iMncovw==} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 dev: true - /@unocss/inspector@0.58.6: - resolution: {integrity: sha512-JCcnIwSofdIdpR/GYTZ78d4dMZP8Z2oF/g9f9MlPG96LLLwqXSmYtR83vC34fUWm1hz7FZyTLK5OqTV7VfUb+w==} + /@unocss/inspector@0.58.8: + resolution: {integrity: sha512-nLmIIwOXnoTpsUFuvlKj8t8xxBi3gMw0+osW9xrYxt5whkV05IUfMwSTFQ3yDhKpmEW8fmUEMqrmu0sdLtRRZA==} dependencies: - '@unocss/core': 0.58.6 - '@unocss/rule-utils': 0.58.6 + '@unocss/core': 0.58.8 + '@unocss/rule-utils': 0.58.8 gzip-size: 6.0.0 sirv: 2.0.4 dev: true - /@unocss/postcss@0.58.6(postcss@8.4.38): - resolution: {integrity: sha512-jTwu7llhRm7luscsk0JekCeo6RS2W98CXiCJRE1H6IDQnjGQQ/9uRAqW4wuLsv7OQ1ThF8m9NKEj0wFJv7ePNg==} + /@unocss/postcss@0.58.8(postcss@8.4.38): + resolution: {integrity: sha512-nI8Cbvc7/IFMGVeFXAHEom5X76gb0dSylBGvlVtWakq27nBwlxG4c3+58dVWg7Nyqvn1mC/sOMGpqjfk8FdJcQ==} engines: {node: '>=14'} peerDependencies: postcss: ^8.4.21 dependencies: - '@unocss/config': 0.58.6 - '@unocss/core': 0.58.6 - '@unocss/rule-utils': 0.58.6 + '@unocss/config': 0.58.8 + '@unocss/core': 0.58.8 + '@unocss/rule-utils': 0.58.8 css-tree: 2.3.1 fast-glob: 3.3.2 magic-string: 0.30.8 postcss: 8.4.38 dev: true - /@unocss/preset-attributify@0.58.6: - resolution: {integrity: sha512-IW2aIBH0RiYsP50VckgxXhMwjDk/XVZykUUklgko9aT+gNC2xDBm3936RWLVLmHdBHG1Vnnjc71BG6aUAqrtEA==} + /@unocss/preset-attributify@0.58.8: + resolution: {integrity: sha512-QEKPDfoYxU2WqqTmd1JX72PDE5UuAHh3q9GgQEP7I6DRFeQ7H2xM62t3FLms5tdNRAALJnhl/jz5+Rajxp9ZQA==} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 dev: true - /@unocss/preset-icons@0.58.6: - resolution: {integrity: sha512-20P1ISxEX2J5mhyNkMm0nKp2p0qJfmDArolC10Fjyl+GUTCsojDNFfonzQEkHeIIJwzgRcubdtNaotTgYSKSRg==} + /@unocss/preset-icons@0.58.8: + resolution: {integrity: sha512-T6xf7pE9+CiTzJgPlHUbxg27agTw/QmUp0FUt+LJr8Nvs4jwe2GDKvAiXrMfCw+s6yOqVFgxPcLpKQWoS5QhEA==} dependencies: '@iconify/utils': 2.1.22 - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 ofetch: 1.3.4 transitivePeerDependencies: - supports-color dev: true - /@unocss/preset-mini@0.58.6: - resolution: {integrity: sha512-COaM/04Z6/gawzrFcCwoyD6t0FCpuKRyljKKs3VxitoGxsN9BHKiFE3U/cPSQarpG789rmZg8D/wmLHCChSXvg==} + /@unocss/preset-mini@0.58.8: + resolution: {integrity: sha512-dCn9ny8Fpiya8qwc2dRkh8YCH5xwf+iD3MxP9YgfweO1o816onBJVqb03xEJT/MOxYkpuRFVJGU+cVSpehamiw==} dependencies: - '@unocss/core': 0.58.6 - '@unocss/extractor-arbitrary-variants': 0.58.6 - '@unocss/rule-utils': 0.58.6 + '@unocss/core': 0.58.8 + '@unocss/extractor-arbitrary-variants': 0.58.8 + '@unocss/rule-utils': 0.58.8 dev: true - /@unocss/preset-tagify@0.58.6: - resolution: {integrity: sha512-xhpHMz8KLrFlLXaOCeShu0/yVpe6J8bd2WcOTd5VuU5W1uCsplcaagpfTRkBpaH1tJt/MTTU5e4cQLa20l0JZQ==} + /@unocss/preset-tagify@0.58.8: + resolution: {integrity: sha512-Xmz1H4bMPpRlm/93RNRRBDzyjRdO5pkEKePQo+J3WXY+FfCrhE/BHopa7plNejoPd/k/4CtdFLuQCVRteHiZ+A==} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 dev: true - /@unocss/preset-typography@0.58.6: - resolution: {integrity: sha512-s4SSw3SK/JjAqYlga51XnxzPc7jF+TmkEkW09IkYYLPrmqJ76U4i5Po2N7HzyjpVGWnmIp1fQ5mCvbhj4tNyNQ==} + /@unocss/preset-typography@0.58.8: + resolution: {integrity: sha512-NX0OC3MTj3CFNkQfcHIksJbPVD1rxAbTTTK3l1x6mul7XOAolWjLXy1aVyGeOFLpCSX4Wv9YrYsa9l2fpnZKgg==} dependencies: - '@unocss/core': 0.58.6 - '@unocss/preset-mini': 0.58.6 + '@unocss/core': 0.58.8 + '@unocss/preset-mini': 0.58.8 dev: true - /@unocss/preset-uno@0.58.6: - resolution: {integrity: sha512-QFbgvxCvTFqKIA/VGcPM+XcfPGDgbmaiXKbnh7hIbkER6TRxjt4DIGapPt150w/kQT+zC/jerWditSdyn+s3xQ==} + /@unocss/preset-uno@0.58.8: + resolution: {integrity: sha512-zqIZLAX6g04B/9rVuGyVNd7/Jdng2rKfw9i9UFG6x0xYN1y+WuyV7+FN66bIJMj7EB17CusHWVMllHRKToOrmw==} dependencies: - '@unocss/core': 0.58.6 - '@unocss/preset-mini': 0.58.6 - '@unocss/preset-wind': 0.58.6 - '@unocss/rule-utils': 0.58.6 + '@unocss/core': 0.58.8 + '@unocss/preset-mini': 0.58.8 + '@unocss/preset-wind': 0.58.8 + '@unocss/rule-utils': 0.58.8 dev: true - /@unocss/preset-web-fonts@0.58.6: - resolution: {integrity: sha512-W/8102vurABwfnb9QQyp9GBKP80kpy/IADSM7hbqLNaqmgxHASELXkjhqqt+et39Zn2tnXpIHNVWoqG6QNWBwQ==} + /@unocss/preset-web-fonts@0.58.8: + resolution: {integrity: sha512-ENDdJlJF4JWu4NSuG83S8gtUhAH5ua/mFItOaTtRffAPHPHuhOqm8krVYunBgkpRMTXYJhnpO4auUsOAMkV1Fw==} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 ofetch: 1.3.4 dev: true - /@unocss/preset-wind@0.58.6: - resolution: {integrity: sha512-zs41CpFVvLB8CutroUeI1iqxzPsztiur9ei0QjRshxpYerPSsTSgdTkF+eul5D1q3BcsebLebzqtCSqnpFOuOA==} + /@unocss/preset-wind@0.58.8: + resolution: {integrity: sha512-7ktb0wJgZg9q2xlNXfgx2pRjg22WJ+B3ENIk9+DB88pty2f6dYo24l8ZyJXQbHglgCilY64NP0fNHkBlUF9olg==} dependencies: - '@unocss/core': 0.58.6 - '@unocss/preset-mini': 0.58.6 - '@unocss/rule-utils': 0.58.6 + '@unocss/core': 0.58.8 + '@unocss/preset-mini': 0.58.8 + '@unocss/rule-utils': 0.58.8 dev: true - /@unocss/reset@0.58.6: - resolution: {integrity: sha512-mYyOe5QDRHc1BBRff+G97j3SGGC8s3Vk7cCcXc/l48FvPHKtLCphMZaBS+KkGkzWqwAtxv0QRbGhTixJCVDRug==} + /@unocss/reset@0.58.8: + resolution: {integrity: sha512-6Cz92Ryer7QpFhxnOwyauwVJfDGhCNYvLHGqW8ScIicFEPK9AUXYys/zBRCIYO2489/kckZ5EG8a3NImS5h+9w==} dev: true - /@unocss/rule-utils@0.58.6: - resolution: {integrity: sha512-qbVDeyKzExFY/YeoIbMw/lu8PXEGJzSHrFXRumNHX5lvTu8ggAjH6p9xyvYa/YnuNU0+pFKuYxG8LNK2F8f1EQ==} + /@unocss/rule-utils@0.58.8: + resolution: {integrity: sha512-F7TKtTkiV9ICf8JMYO1+Eq/5zrrV7Fw966rQfHfIKrN6Vwo3tw84b5R0bLJghAFtb9UuD7q9eCfy6WBQK0d7Tw==} engines: {node: '>=14'} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 magic-string: 0.30.8 dev: true - /@unocss/scope@0.58.6: - resolution: {integrity: sha512-22BDrZPOkfEKuXY4NROhY+J25TAXN+GIxZpE4IbT1Wh+dkjnMXyC85VKGzOAuY/0v0zbaj12dYkmtndueQ/04w==} + /@unocss/scope@0.58.8: + resolution: {integrity: sha512-FpXGSWQU+XfguSPrFm9NfZYKmDikxu4KB+fvVzgHkN3e+UQ7QSHFHREbdc+E8x0HPMNkoNnYVaCr0qgIBUEKFA==} dev: true - /@unocss/transformer-attributify-jsx-babel@0.58.6: - resolution: {integrity: sha512-IVU/ZozKTFhP9z1I9ZgSKiEx3WfDFDNXbTYTqwNW2SHPmAj5Qf99kn6o7br7Kd1dnxSjKFXOmNfNGkW9AMDraA==} + /@unocss/transformer-attributify-jsx-babel@0.58.8: + resolution: {integrity: sha512-4+Ctwo57RiLcxoZtoRvS2XE6NHiVTolA8RW6dI5EQU6Z5n2XYPpkkUdSHcmXuFWuJ5ZD19FzUnCsxtBoPbr2Fw==} dependencies: '@babel/core': 7.24.3 '@babel/plugin-syntax-jsx': 7.24.1(@babel/core@7.24.3) '@babel/preset-typescript': 7.24.1(@babel/core@7.24.3) - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 transitivePeerDependencies: - supports-color dev: true - /@unocss/transformer-attributify-jsx@0.58.6: - resolution: {integrity: sha512-S+mTR5qwMsEaq8nYtqUgYdYIIRAA4oltxfGMYGj3Gxy9V0uteyo56QNp7IOjlYxAB8Dq9jQ8GLYEQe5JlffO1A==} + /@unocss/transformer-attributify-jsx@0.58.8: + resolution: {integrity: sha512-MFpbIJB9vsfKHHMJ04gObQ5EM1qySNPev3gysmvduBSQyHy6CRmUugTCWVStaZeepzYMASgOkFfx64xIyKAHpw==} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 dev: true - /@unocss/transformer-compile-class@0.58.6: - resolution: {integrity: sha512-iung3cPA+IpBHoP6dTs9gkPN/wEVujqMZYxf6FQLjRH+v70rPxqTgaeGDyuQZAYikfDhdUZF8PJ4IUMOxEFsmw==} + /@unocss/transformer-compile-class@0.58.8: + resolution: {integrity: sha512-bMC+sXeD8VjjcqRtDIflh823zpmVOWeEQecRPPvYr0EU6u41N4L4m4SPIqyichmV6nbVKfJOhw1s8kWdBfNI2g==} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 dev: true - /@unocss/transformer-directives@0.58.6: - resolution: {integrity: sha512-8/+KGRmRnlkAJCRt4VqcYK16SnEr9wf1q7D9OCM2kZhk33Sx5SlsO6vjNZ1IH4c67/WviwNV6+KeS4elnQY8bA==} + /@unocss/transformer-directives@0.58.8: + resolution: {integrity: sha512-KdNzgmL5gdls1MTRvB7DKJRbLai1t8JeKCN+0H1lygzKMAhp8zItRei/F0MaSdbWdviNnGcAXqbCkbmGR72vaA==} dependencies: - '@unocss/core': 0.58.6 - '@unocss/rule-utils': 0.58.6 + '@unocss/core': 0.58.8 + '@unocss/rule-utils': 0.58.8 css-tree: 2.3.1 dev: true - /@unocss/transformer-variant-group@0.58.6: - resolution: {integrity: sha512-6IFmfzketh4j+Mc/ik4nU+Oec0cptNR+aVfZZkGb4wd2h1lH+teAT2Y/Vz2xY8rDExOrbjY5y5FgRGd16LY2Rw==} + /@unocss/transformer-variant-group@0.58.8: + resolution: {integrity: sha512-Fa9lCHsR6scg9BuAvyltdRpSVJJxP5OCU8OJmkOhGlJnkcrV8X/9ynPvVuV82awoImn5CBoo4fyQ+f9vCdWycw==} dependencies: - '@unocss/core': 0.58.6 + '@unocss/core': 0.58.8 dev: true - /@unocss/vite@0.58.6(vite@5.2.6): - resolution: {integrity: sha512-DPXCoYU/Ozqc/Jeptd41XvtW8MSgVxmtTyhpMAsm/hJuBfwIV7Fy3TZquf4V9BpaTb4ao1LVXzgXmVUmj2HXpA==} + /@unocss/vite@0.58.8(vite@5.2.6): + resolution: {integrity: sha512-Eh0cG1I/BivvhUPdFxPi/z7Q+LMDnjHgL/dIE6/tmJK9rerdGeOBCAXxEetZfvBrOhWVnsOW/ydesyAhkzRg3w==} peerDependencies: vite: ^2.9.0 || ^3.0.0-0 || ^4.0.0 || ^5.0.0-0 dependencies: '@ampproject/remapping': 2.3.0 '@rollup/pluginutils': 5.1.0 - '@unocss/config': 0.58.6 - '@unocss/core': 0.58.6 - '@unocss/inspector': 0.58.6 - '@unocss/scope': 0.58.6 - '@unocss/transformer-directives': 0.58.6 + '@unocss/config': 0.58.8 + '@unocss/core': 0.58.8 + '@unocss/inspector': 0.58.8 + '@unocss/scope': 0.58.8 + '@unocss/transformer-directives': 0.58.8 chokidar: 3.6.0 fast-glob: 3.3.2 magic-string: 0.30.8 @@ -7135,6 +7125,10 @@ packages: resolution: {integrity: sha512-EC2utToWl4RKfs5zd36Mxq7nzHHBuomZboI0yYL6Y0RmBgT7Sgkq4rQ0ezFTYoIsSs7Tm9SJe+o2FcAg6GBhGA==} dev: true + /http2-proxy@5.0.53: + resolution: {integrity: sha512-k9OUKrPWau/YeViJGv5peEFgSGPE2n8CDyk/G3f+JfaaJzbFMPAK5PJTd99QYSUvgUwVBGNbZJCY/BEb+kUZNQ==} + dev: false + /human-signals@1.1.1: resolution: {integrity: sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==} engines: {node: '>=8.12.0'} @@ -8441,11 +8435,6 @@ packages: commander: 12.0.0 dev: true - /mri@1.2.0: - resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==} - engines: {node: '>=4'} - dev: true - /mrmime@2.0.0: resolution: {integrity: sha512-eu38+hdgojoyq63s+yTpN4XMBdt5l8HhMhc4VKLO9KM5caLIBvUm4thi7fFaxyTmCKeNnXZ5pAlBwCUnhA09uw==} engines: {node: '>=10'} @@ -8462,8 +8451,8 @@ packages: resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} dev: true - /msw@2.2.10(typescript@5.4.3): - resolution: {integrity: sha512-OQhHBocUsI8j+czCTRouGCGYE8pk6hq8HQ0HFg9mYQg7KCzqVpUSbMikmRbRXGoid28FFvYqjbxB3/UWw50VZQ==} + /msw@2.2.13(typescript@5.4.3): + resolution: {integrity: sha512-ljFf1xZsU0b4zv1l7xzEmC6OZA6yD06hcx0H+dc8V0VypaP3HGYJa1rMLjQbBWl32ptGhcfwcPCWDB1wjmsftw==} engines: {node: '>=18'} hasBin: true requiresBuild: true @@ -8477,7 +8466,7 @@ packages: '@bundled-es-modules/statuses': 1.0.1 '@inquirer/confirm': 3.1.0 '@mswjs/cookies': 1.1.0 - '@mswjs/interceptors': 0.25.16 + '@mswjs/interceptors': 0.26.14 '@open-draft/until': 2.1.0 '@types/cookie': 0.6.0 '@types/statuses': 2.0.5 @@ -9183,11 +9172,6 @@ packages: engines: {node: '>=8.6'} dev: true - /picomatch@3.0.1: - resolution: {integrity: sha512-I3EurrIQMlRc9IaAZnqRR044Phh2DXY+55o7uJ0V+hYZAcQYSuFWsc9q5PvyDHUSCe1Qxn/iBz+78s86zWnGag==} - engines: {node: '>=10'} - dev: true - /pidtree@0.6.0: resolution: {integrity: sha512-eG2dWTVw5bzqGRztnHExczNxt5VGsE6OwTeCG3fdUf9KBsZzO3R5OIIIzWR+iZA0NtZ+RDVdaoE2dK1cn6jH4g==} engines: {node: '>=0.10'} @@ -9549,23 +9533,6 @@ packages: react-is: 18.2.0 dev: true - /pretty-quick@4.0.0(prettier@3.2.5): - resolution: {integrity: sha512-M+2MmeufXb/M7Xw3Afh1gxcYpj+sK0AxEfnfF958ktFeAyi5MsKY5brymVURQLgPLV1QaF5P4pb2oFJ54H3yzQ==} - engines: {node: '>=14'} - hasBin: true - peerDependencies: - prettier: ^3.0.0 - dependencies: - execa: 5.1.1 - find-up: 5.0.0 - ignore: 5.3.1 - mri: 1.2.0 - picocolors: 1.0.0 - picomatch: 3.0.1 - prettier: 3.2.5 - tslib: 2.6.2 - dev: true - /progress@2.0.3: resolution: {integrity: sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==} engines: {node: '>=0.4.0'} @@ -10510,7 +10477,7 @@ packages: stylelint: 13.13.1 dev: true - /stylelint-config-html@1.1.0(postcss-html@1.6.0)(stylelint@16.3.0): + /stylelint-config-html@1.1.0(postcss-html@1.6.0)(stylelint@16.3.1): resolution: {integrity: sha512-IZv4IVESjKLumUGi+HWeb7skgO6/g4VMuAYrJdlqQFndgbj6WJAXPhaysvBiXefX79upBdQVumgYcdd17gCpjQ==} engines: {node: ^12 || >=14} peerDependencies: @@ -10518,7 +10485,7 @@ packages: stylelint: '>=14.0.0' dependencies: postcss-html: 1.6.0 - stylelint: 16.3.0(typescript@5.4.3) + stylelint: 16.3.1(typescript@5.4.3) dev: true /stylelint-config-prettier@8.0.2(stylelint@13.13.1): @@ -10531,18 +10498,18 @@ packages: stylelint: 13.13.1 dev: true - /stylelint-config-property-sort-order-smacss@10.0.0(stylelint@16.3.0): + /stylelint-config-property-sort-order-smacss@10.0.0(stylelint@16.3.1): resolution: {integrity: sha512-NuiTgyqD8UdYY1IpTBIodBbrWKwaib5r8sq5kGHQ52UrmT8O7Fa8ZWYGipSZw6k9tGoljl9Hng2jtH+wBTMa1Q==} engines: {node: '>=18.12.0'} peerDependencies: stylelint: ^14.0.0 || ^15.0.0 || ^16.0.0 dependencies: css-property-sort-order-smacss: 2.2.0 - stylelint: 16.3.0(typescript@5.4.3) - stylelint-order: 6.0.4(stylelint@16.3.0) + stylelint: 16.3.1(typescript@5.4.3) + stylelint-order: 6.0.4(stylelint@16.3.1) dev: true - /stylelint-config-recommended-vue@1.5.0(postcss-html@1.6.0)(stylelint@16.3.0): + /stylelint-config-recommended-vue@1.5.0(postcss-html@1.6.0)(stylelint@16.3.1): resolution: {integrity: sha512-65TAK/clUqkNtkZLcuytoxU0URQYlml+30Nhop7sRkCZ/mtWdXt7T+spPSB3KMKlb+82aEVJ4OrcstyDBdbosg==} engines: {node: ^12 || >=14} peerDependencies: @@ -10551,18 +10518,18 @@ packages: dependencies: postcss-html: 1.6.0 semver: 7.6.0 - stylelint: 16.3.0(typescript@5.4.3) - stylelint-config-html: 1.1.0(postcss-html@1.6.0)(stylelint@16.3.0) - stylelint-config-recommended: 14.0.0(stylelint@16.3.0) + stylelint: 16.3.1(typescript@5.4.3) + stylelint-config-html: 1.1.0(postcss-html@1.6.0)(stylelint@16.3.1) + stylelint-config-recommended: 14.0.0(stylelint@16.3.1) dev: true - /stylelint-config-recommended@14.0.0(stylelint@16.3.0): + /stylelint-config-recommended@14.0.0(stylelint@16.3.1): resolution: {integrity: sha512-jSkx290CglS8StmrLp2TxAppIajzIBZKYm3IxT89Kg6fGlxbPiTiyH9PS5YUuVAFwaJLl1ikiXX0QWjI0jmgZQ==} engines: {node: '>=18.12.0'} peerDependencies: stylelint: ^16.0.0 dependencies: - stylelint: 16.3.0(typescript@5.4.3) + stylelint: 16.3.1(typescript@5.4.3) dev: true /stylelint-config-recommended@3.0.0(stylelint@13.13.1): @@ -10582,14 +10549,14 @@ packages: stylelint-config-recommended: 3.0.0(stylelint@13.13.1) dev: true - /stylelint-config-standard@36.0.0(stylelint@16.3.0): + /stylelint-config-standard@36.0.0(stylelint@16.3.1): resolution: {integrity: sha512-3Kjyq4d62bYFp/Aq8PMKDwlgUyPU4nacXsjDLWJdNPRUgpuxALu1KnlAHIj36cdtxViVhXexZij65yM0uNIHug==} engines: {node: '>=18.12.0'} peerDependencies: stylelint: ^16.1.0 dependencies: - stylelint: 16.3.0(typescript@5.4.3) - stylelint-config-recommended: 14.0.0(stylelint@16.3.0) + stylelint: 16.3.1(typescript@5.4.3) + stylelint-config-recommended: 14.0.0(stylelint@16.3.1) dev: true /stylelint-declaration-block-no-ignored-properties@2.8.0(stylelint@13.13.1): @@ -10601,17 +10568,17 @@ packages: stylelint: 13.13.1 dev: true - /stylelint-order@6.0.4(stylelint@16.3.0): + /stylelint-order@6.0.4(stylelint@16.3.1): resolution: {integrity: sha512-0UuKo4+s1hgQ/uAxlYU4h0o0HS4NiQDud0NAUNI0aa8FJdmYHA5ZZTFHiV5FpmE3071e9pZx5j0QpVJW5zOCUA==} peerDependencies: stylelint: ^14.0.0 || ^15.0.0 || ^16.0.1 dependencies: postcss: 8.4.38 postcss-sorting: 8.0.2(postcss@8.4.38) - stylelint: 16.3.0(typescript@5.4.3) + stylelint: 16.3.1(typescript@5.4.3) dev: true - /stylelint-prettier@5.0.0(prettier@3.2.5)(stylelint@16.3.0): + /stylelint-prettier@5.0.0(prettier@3.2.5)(stylelint@16.3.1): resolution: {integrity: sha512-RHfSlRJIsaVg5Br94gZVdWlz/rBTyQzZflNE6dXvSxt/GthWMY3gEHsWZEBaVGg7GM+XrtVSp4RznFlB7i0oyw==} engines: {node: '>=18.12.0'} peerDependencies: @@ -10620,7 +10587,7 @@ packages: dependencies: prettier: 3.2.5 prettier-linter-helpers: 1.0.0 - stylelint: 16.3.0(typescript@5.4.3) + stylelint: 16.3.1(typescript@5.4.3) dev: true /stylelint@13.13.1: @@ -10682,8 +10649,8 @@ packages: - supports-color dev: true - /stylelint@16.3.0(typescript@5.4.3): - resolution: {integrity: sha512-hqC6xNTbQ5HRGQXfIW4HwXcx09raIFz4W4XFbraeqWqYRVVY/ibYvI0dsu0ORMQY8re2bpDdCAeIa2cm+QJ4Sw==} + /stylelint@16.3.1(typescript@5.4.3): + resolution: {integrity: sha512-/JOwQnBvxEKOT2RtNgGpBVXnCSMBgKOL2k7w0K52htwCyJls4+cHvc4YZgXlVoAZS9QJd2DgYAiRnja96pTgxw==} engines: {node: '>=18.12.0'} hasBin: true dependencies: @@ -11337,11 +11304,11 @@ packages: engines: {node: '>= 10.0.0'} dev: true - /unocss@0.58.6(postcss@8.4.38)(vite@5.2.6): - resolution: {integrity: sha512-HBstDtC6KKD5yCYh5hHpPdHGZai0B/iLlDwkOIK+xfQYrvl8tNBvKfRz3xgiaI5MJ+fLmEOxbfXQIjleU1A0iA==} + /unocss@0.58.8(postcss@8.4.38)(vite@5.2.6): + resolution: {integrity: sha512-oMWCEgwvxJcF1BZxxkbTyTd83xtArsza3DModUrJrPndnpOVVz9fZ5g6wcrDbVpv6+cvRrgMCeKMlWKt9WIIsA==} engines: {node: '>=14'} peerDependencies: - '@unocss/webpack': 0.58.6 + '@unocss/webpack': 0.58.8 vite: ^2.9.0 || ^3.0.0-0 || ^4.0.0 || ^5.0.0-0 peerDependenciesMeta: '@unocss/webpack': @@ -11349,26 +11316,26 @@ packages: vite: optional: true dependencies: - '@unocss/astro': 0.58.6(vite@5.2.6) - '@unocss/cli': 0.58.6 - '@unocss/core': 0.58.6 - '@unocss/extractor-arbitrary-variants': 0.58.6 - '@unocss/postcss': 0.58.6(postcss@8.4.38) - '@unocss/preset-attributify': 0.58.6 - '@unocss/preset-icons': 0.58.6 - '@unocss/preset-mini': 0.58.6 - '@unocss/preset-tagify': 0.58.6 - '@unocss/preset-typography': 0.58.6 - '@unocss/preset-uno': 0.58.6 - '@unocss/preset-web-fonts': 0.58.6 - '@unocss/preset-wind': 0.58.6 - '@unocss/reset': 0.58.6 - '@unocss/transformer-attributify-jsx': 0.58.6 - '@unocss/transformer-attributify-jsx-babel': 0.58.6 - '@unocss/transformer-compile-class': 0.58.6 - '@unocss/transformer-directives': 0.58.6 - '@unocss/transformer-variant-group': 0.58.6 - '@unocss/vite': 0.58.6(vite@5.2.6) + '@unocss/astro': 0.58.8(vite@5.2.6) + '@unocss/cli': 0.58.8 + '@unocss/core': 0.58.8 + '@unocss/extractor-arbitrary-variants': 0.58.8 + '@unocss/postcss': 0.58.8(postcss@8.4.38) + '@unocss/preset-attributify': 0.58.8 + '@unocss/preset-icons': 0.58.8 + '@unocss/preset-mini': 0.58.8 + '@unocss/preset-tagify': 0.58.8 + '@unocss/preset-typography': 0.58.8 + '@unocss/preset-uno': 0.58.8 + '@unocss/preset-web-fonts': 0.58.8 + '@unocss/preset-wind': 0.58.8 + '@unocss/reset': 0.58.8 + '@unocss/transformer-attributify-jsx': 0.58.8 + '@unocss/transformer-attributify-jsx-babel': 0.58.8 + '@unocss/transformer-compile-class': 0.58.8 + '@unocss/transformer-directives': 0.58.8 + '@unocss/transformer-variant-group': 0.58.8 + '@unocss/vite': 0.58.8(vite@5.2.6) vite: 5.2.6(@types/node@20.11.30)(less@4.2.0) transitivePeerDependencies: - postcss @@ -11486,7 +11453,7 @@ packages: vfile-message: 2.0.4 dev: true - /vite-plugin-checker@0.6.4(eslint@8.57.0)(stylelint@16.3.0)(typescript@5.4.3)(vite@5.2.6)(vue-tsc@1.8.27): + /vite-plugin-checker@0.6.4(eslint@8.57.0)(stylelint@16.3.1)(typescript@5.4.3)(vite@5.2.6)(vue-tsc@1.8.27): resolution: {integrity: sha512-2zKHH5oxr+ye43nReRbC2fny1nyARwhxdm0uNYp/ERy4YvU9iZpNOsueoi/luXw5gnpqRSvjcEPxXbS153O2wA==} engines: {node: '>=14.16'} peerDependencies: @@ -11528,7 +11495,7 @@ packages: npm-run-path: 4.0.1 semver: 7.6.0 strip-ansi: 6.0.1 - stylelint: 16.3.0(typescript@5.4.3) + stylelint: 16.3.1(typescript@5.4.3) tiny-invariant: 1.3.3 typescript: 5.4.3 vite: 5.2.6(@types/node@20.11.30)(less@4.2.0) @@ -12115,26 +12082,3 @@ packages: /zwitch@1.0.5: resolution: {integrity: sha512-V50KMwwzqJV0NpZIZFwfOD5/lyny3WlSzRiXgA0G7VUnRlqttta1L6UQIHzd6EuBY/cHGfwTIck7w1yH6Q5zUw==} dev: true - - file:packages/vite-plugin-msw(msw@2.2.10): - resolution: {directory: packages/vite-plugin-msw, type: directory} - id: file:packages/vite-plugin-msw - name: '@admin-pkg/vite-plugin-msw' - peerDependencies: - msw: ^2.0.0 - dependencies: - '@mswjs/interceptors': 0.26.11 - headers-polyfill: 4.0.3 - msw: 2.2.10(typescript@5.4.3) - strict-event-emitter: 0.5.1 - dev: true - - file:packages/vite-plugin-tinymce-resource(vite@5.2.6): - resolution: {directory: packages/vite-plugin-tinymce-resource, type: directory} - id: file:packages/vite-plugin-tinymce-resource - name: '@admin-pkg/vite-plugin-tinymce-resource' - peerDependencies: - vite: ^5.0.0 - dependencies: - vite: 5.2.6(@types/node@20.11.30)(less@4.2.0) - dev: true diff --git a/src/components/basic/icon/src/icon-font.tsx b/src/components/basic/icon/src/icon-font.tsx index 49082e2b0..9f6bee69d 100644 --- a/src/components/basic/icon/src/icon-font.tsx +++ b/src/components/basic/icon/src/icon-font.tsx @@ -2,8 +2,9 @@ import { defineComponent, unref, computed } from 'vue'; import { createFromIconfontCN } from '@ant-design/icons-vue'; import type { PropType } from 'vue'; import { isString } from '@/utils/is'; +import { uniqueSlash } from '@/utils/urlUtils'; -let scriptUrls = [`${import.meta.env.BASE_URL}iconfont.js`]; +let scriptUrls = [uniqueSlash(`${import.meta.env.BASE_URL}/iconfont.js`)]; // 文档:https://antdv.com/components/icon-cn#components-icon-demo-iconfont let MyIconFont = createFromIconfontCN({ diff --git a/src/components/core/dynamic-table/src/dynamic-table.vue b/src/components/core/dynamic-table/src/dynamic-table.vue index 85a975fec..a268273a4 100644 --- a/src/components/core/dynamic-table/src/dynamic-table.vue +++ b/src/components/core/dynamic-table/src/dynamic-table.vue @@ -8,6 +8,7 @@ class="bg-white dark:bg-black mb-16px !pt-24px pr-24px" submit-on-reset v-bind="getFormProps" + :schemas="formSchemas" :table-instance="tableAction" @toggle-advanced="(e) => $emit('toggle-advanced', e)" @submit="handleSubmit" @@ -125,7 +126,7 @@ tableMethods, slots, }); - const { getFormProps, replaceFormSlotKey, getFormSlotKeys } = tableForm; + const { getFormProps, replaceFormSlotKey, getFormSlotKeys, formSchemas } = tableForm; // 表单导出 const exportData2ExcelHooks = useExportData2Excel({ diff --git a/src/components/core/dynamic-table/src/hooks/useTableForm.ts b/src/components/core/dynamic-table/src/hooks/useTableForm.ts index 13ad34540..d56227166 100644 --- a/src/components/core/dynamic-table/src/hooks/useTableForm.ts +++ b/src/components/core/dynamic-table/src/hooks/useTableForm.ts @@ -26,7 +26,6 @@ export function useTableForm({ tableState, slots, tableMethods }: UseTableFormCo layout: 'horizontal', labelWidth: 100, ...formProps, - schemas: formProps?.schemas ?? unref(formSchemas), submitButtonOptions: { loading: unref(loadingRef), ...submitButtonOptions }, compact: true, }; @@ -74,5 +73,6 @@ export function useTableForm({ tableState, slots, tableMethods }: UseTableFormCo getFormProps, replaceFormSlotKey, getFormSlotKeys, + formSchemas, }; } diff --git a/src/components/core/schema-form/src/components/form-action.vue b/src/components/core/schema-form/src/components/form-action.vue index 7746e3675..ba809ecb1 100644 --- a/src/components/core/schema-form/src/components/form-action.vue +++ b/src/components/core/schema-form/src/components/form-action.vue @@ -19,7 +19,7 @@ type="primary" class="mr-2" v-bind="getSubmitBtnOptions" - @click="submit" + @click="handleSubmit($event)" > {{ getSubmitBtnOptions.text }} @@ -130,4 +130,8 @@ function toggleAdvanced() { emit('toggle-advanced', props.isAdvanced); } + + const handleSubmit = async (e: Event) => { + await submit(e).catch(() => {}); + }; diff --git a/src/components/core/schema-form/src/hooks/useFormEvents.ts b/src/components/core/schema-form/src/hooks/useFormEvents.ts index 178fa1db0..d096c2b5f 100644 --- a/src/components/core/schema-form/src/hooks/useFormEvents.ts +++ b/src/components/core/schema-form/src/hooks/useFormEvents.ts @@ -9,10 +9,10 @@ import type { SchemaFormEmitFn } from '../schema-form'; import { isArray, isFunction, isObject, isString } from '@/utils/is'; import { deepMerge } from '@/utils'; -type UseFormActionContext = FormState & { - emit: SchemaFormEmitFn; - handleFormValues: FormMethods['handleFormValues']; -}; +type UseFormActionContext = FormState & + Pick & { + emit: SchemaFormEmitFn; + }; type FormSchema = UnwrapFormSchema; @@ -281,7 +281,7 @@ export function useFormEvents(formActionContext: UseFormActionContext) { try { const values = await validate(); const res = handleFormValues(values); - emit('submit', res); + emit('submit', values); return res; } catch (error: any) { return Promise.reject(error); diff --git a/src/components/core/schema-form/src/hooks/useFormState.ts b/src/components/core/schema-form/src/hooks/useFormState.ts index 0740d1b9e..b9598f262 100644 --- a/src/components/core/schema-form/src/hooks/useFormState.ts +++ b/src/components/core/schema-form/src/hooks/useFormState.ts @@ -1,5 +1,5 @@ -import { computed, reactive, ref, unref, watchEffect } from 'vue'; -import { cloneDeep } from 'lodash-es'; +import { computed, reactive, ref, unref, watch } from 'vue'; +import { cloneDeep, set } from 'lodash-es'; import type { SetupContext, DefineComponent } from 'vue'; import type { AdvanceState } from '../types/hooks'; import type { SchemaFormProps } from '../schema-form'; @@ -61,13 +61,17 @@ export const useFormState = ({ props, attrs }: useFormStateParams) => { (): Recordable => ({ ...getFormProps.value, ...advanceState }), ); - watchEffect(() => { - formPropsRef.value.schemas?.forEach((item) => { - if (!originComponentPropsFnMap.has(item.field) && isFunction(item.componentProps)) { - originComponentPropsFnMap.set(item.field, item.componentProps); - } - }); - }); + watch( + () => formPropsRef.value.schemas, + () => { + formPropsRef.value.schemas?.forEach((item) => { + if (!originComponentPropsFnMap.has(item.field) && isFunction(item.componentProps)) { + originComponentPropsFnMap.set(item.field, item.componentProps); + } + set(defaultFormValues, item.field, item.defaultValue); + }); + }, + ); return { formModel, diff --git a/src/views/demos/tables/search-table/columns.tsx b/src/views/demos/tables/search-table/columns.tsx index 21e06693b..ed841d5b7 100644 --- a/src/views/demos/tables/search-table/columns.tsx +++ b/src/views/demos/tables/search-table/columns.tsx @@ -126,7 +126,7 @@ export const columns: TableColumn[] = [ title: '价格', dataIndex: 'price', formItemProps: { - component: 'Select', + component: 'InputNumber', }, customRender: ({ record }) => `${record.price}元`, },