mirror of
https://gitee.com/ant-design-blazor/ant-design-blazor.git
synced 2024-12-12 11:55:24 +08:00
fix(module: input-number): where automatic increase/decrease does not have to be stopped in rare cases. (#2317)
This commit is contained in:
parent
a6e44b7dbc
commit
ad5a58dac4
@ -311,6 +311,7 @@ namespace AntDesign
|
||||
var num = _increaseFunc(Value, _step);
|
||||
await ChangeValueAsync(num);
|
||||
|
||||
_increaseTokenSource?.Cancel();
|
||||
_increaseTokenSource = new CancellationTokenSource();
|
||||
_ = Increase(_increaseTokenSource.Token).ConfigureAwait(false);
|
||||
}
|
||||
@ -347,6 +348,7 @@ namespace AntDesign
|
||||
var num = _decreaseFunc(Value, _step);
|
||||
await ChangeValueAsync(num);
|
||||
|
||||
_decreaseTokenSource?.Cancel();
|
||||
_decreaseTokenSource = new CancellationTokenSource();
|
||||
_ = Decrease(_decreaseTokenSource.Token).ConfigureAwait(false);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user