diff --git a/package.json b/package.json index 853215e0..e4e4538a 100644 --- a/package.json +++ b/package.json @@ -78,6 +78,7 @@ "remark-breaks": "^4.0.0", "remark-gfm": "^4.0.1", "remark-math": "^6.0.0", + "semver": "^7.7.3", "simplebar-react": "^3.2.6", "styled-components": "^6.1.15", "tinycolor2": "^1.6.0", @@ -88,6 +89,7 @@ "devDependencies": { "@types/react": "^18.3.1", "@types/react-dom": "^18.3.0", + "@types/semver": "^7.7.1", "@umijs/case-sensitive-paths-webpack-plugin": "^1.0.1", "@umijs/plugins": "^4.4.11", "babel-plugin-named-asset-import": "^0.3.8", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2eec9ffa..843c4d90 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -195,6 +195,9 @@ dependencies: remark-math: specifier: ^6.0.0 version: 6.0.0 + semver: + specifier: ^7.7.3 + version: 7.7.3 simplebar-react: specifier: ^3.2.6 version: 3.3.2(react@18.3.1) @@ -221,6 +224,9 @@ devDependencies: '@types/react-dom': specifier: ^18.3.0 version: 18.3.7(@types/react@18.3.27) + '@types/semver': + specifier: ^7.7.1 + version: 7.7.1 '@umijs/case-sensitive-paths-webpack-plugin': specifier: ^1.0.1 version: 1.0.1 @@ -4110,7 +4116,7 @@ packages: resolution: {integrity: sha512-hy8b7Y1J8OGe6LbAjj3xniQrj3v6lsivCcrmf4TzSgPzLkhIeKgc5IZnT7ReIqmEuodjfO8EYAuoFvIrHi/+jQ==, tarball: https://registry.npmjs.org/@types/history/-/history-5.0.0.tgz} deprecated: This is a stub types definition. history provides its own type definitions, so you do not need this installed. dependencies: - history: 4.10.1 + history: 5.3.0 /@types/hoist-non-react-statics@3.3.7(@types/react@18.3.27): resolution: {integrity: sha512-PQTyIulDkIDro8P+IHbKCsw7U2xxBYflVzW/FgWdCAePD9xGSidgA76/GeJ6lBKoblyhf9pBY763gbrN+1dI8g==, tarball: https://registry.npmjs.org/@types/hoist-non-react-statics/-/hoist-non-react-statics-3.3.7.tgz} @@ -4234,7 +4240,7 @@ packages: '@types/history': 4.7.11 '@types/react': 18.3.27 '@types/react-router': 5.1.20 - redux: 3.7.2 + redux: 4.2.1 /@types/react-router@5.1.20: resolution: {integrity: sha512-jGjmu/ZqS7FjSH6owMcD5qpq19+1RS9DeVRqfl1FeBMxTDQAGwlMWOcs52NDoXaNKyG3d1cYQFMs9rCrb88o9Q==, tarball: https://registry.npmjs.org/@types/react-router/-/react-router-5.1.20.tgz} @@ -4254,7 +4260,6 @@ packages: /@types/semver@7.7.1: resolution: {integrity: sha512-FmgJfu+MOcQ370SD0ev7EI8TlCAfKYU+B4m5T3yXc1CiRN94g/SZPtsCkk506aUDtlMnFZvasDwHHUcZUEaYuA==, tarball: https://registry.npmjs.org/@types/semver/-/semver-7.7.1.tgz} - dev: false /@types/stylis@4.2.5: resolution: {integrity: sha512-1Xve+NMN7FWjY14vLoY5tL3BVEQ/n42YLwaqJIPYhotZ9uBHt87VceMwWQpzmdEt2TNXIorIFG+YeCUUW7RInw==, tarball: https://registry.npmjs.org/@types/stylis/-/stylis-4.2.5.tgz} @@ -9400,7 +9405,6 @@ packages: resolution: {integrity: sha512-ZqaKwjjrAYUYfLG+htGaIIZ4nioX2L70ZUMIFysS3xvBsSG4x/n1V6TXV3N8ZYNuFGlDirFg32T7B6WOUPDYcQ==, tarball: https://registry.npmjs.org/history/-/history-5.3.0.tgz} dependencies: '@babel/runtime': 7.28.4 - dev: false /hmac-drbg@1.0.1: resolution: {integrity: sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==, tarball: https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz} diff --git a/src/components/seal-form/seal-slider.tsx b/src/components/seal-form/seal-slider.tsx index c605e6b0..99161f8c 100644 --- a/src/components/seal-form/seal-slider.tsx +++ b/src/components/seal-form/seal-slider.tsx @@ -48,7 +48,7 @@ const SealSlider: React.FC = (props) => { props.onChange?.(newValue); }; - const renderLabel = React.useMemo(() => { + const renderLabel = () => { return ( = (props) => { )} ); - }, [label, labelWidth, description, value, max, min, step, defaultValue]); + }; return ( diff --git a/src/components/seal-form/simple-select.tsx b/src/components/seal-form/simple-select.tsx index 55425b5f..5c9e73f4 100644 --- a/src/components/seal-form/simple-select.tsx +++ b/src/components/seal-form/simple-select.tsx @@ -175,7 +175,7 @@ const SimpleSelect: React.FC = return ( = ({ onClick={onClick} > {label && ( -