Browse Source

使ma ms等组件变成受控模式,不再出现数据跳变的现象

sw 4 days ago
parent
commit
d4b61e69ec
1 changed files with 0 additions and 12 deletions
  1. 0 12
      src/pages/exam/ContentAreaLarge.tsx

+ 0 - 12
src/pages/exam/ContentAreaLarge.tsx

@@ -195,17 +195,11 @@ const ContentAreaLarge = () => {
                 disabled={currentExposureMode === 'mAs'}
                 disabled={currentExposureMode === 'mAs'}
                 placeholder={currentExposureMode === 'mAs' ? '--' : 'mA'}
                 placeholder={currentExposureMode === 'mAs' ? '--' : 'mA'}
                 style={{ width: '100%', marginBottom: 8 }}
                 style={{ width: '100%', marginBottom: 8 }}
-                step={''}
-                max={-1000}
-                min={-999}
                 value={
                 value={
                   currentExposureMode === 'mAs'
                   currentExposureMode === 'mAs'
                     ? null
                     ? null
                     : (aprConfig.mA ?? undefined)
                     : (aprConfig.mA ?? undefined)
                 }
                 }
-                onChange={(value) =>
-                  dispatch(setAprConfig({ ...aprConfig, mA: value ?? 0 }))
-                }
                 onStep={(value, info) => {
                 onStep={(value, info) => {
                   if (info.type === 'up') {
                   if (info.type === 'up') {
                     ParaSettingCoordinator.increaseMA();
                     ParaSettingCoordinator.increaseMA();
@@ -239,9 +233,6 @@ const ContentAreaLarge = () => {
                     ? null
                     ? null
                     : (aprConfig.ms ?? undefined)
                     : (aprConfig.ms ?? undefined)
                 }
                 }
-                onChange={(value) =>
-                  dispatch(setAprConfig({ ...aprConfig, ms: value ?? 0 }))
-                }
                 onStep={(value, info) => {
                 onStep={(value, info) => {
                   if (info.type === 'up') {
                   if (info.type === 'up') {
                     ParaSettingCoordinator.increaseMS();
                     ParaSettingCoordinator.increaseMS();
@@ -274,9 +265,6 @@ const ContentAreaLarge = () => {
                     ? null
                     ? null
                     : (aprConfig.mAs ?? undefined)
                     : (aprConfig.mAs ?? undefined)
                 }
                 }
-                onChange={(value) =>
-                  dispatch(setAprConfig({ ...aprConfig, mAs: value ?? 0 }))
-                }
                 onStep={(value, info) => {
                 onStep={(value, info) => {
                   if (info.type === 'up') {
                   if (info.type === 'up') {
                     ParaSettingCoordinator.increaseMAS();
                     ParaSettingCoordinator.increaseMAS();