Skip to content

Commit d9afefb

Browse files
Phieoluoroseyang
authored andcommitted
fix: readOnly stepper onChange not working (#275)
1 parent 51b06c4 commit d9afefb

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

components/stepper/index.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,10 @@ Component({
3232
},
3333
methods: {
3434
changeFn(ev) {
35-
const { min, max, onChange, disabled, readOnly, step } = this.props;
35+
const { min, max, onChange, disabled, step } = this.props;
3636
const evType = ev.target.dataset.type;
3737
let { opaReduce, opaAdd, value } = this.data;
38-
const enable = disabled || readOnly;
39-
if (!enable) {
38+
if (!disabled) {
4039
if (evType === 'reduce') {
4140
if (value > min) {
4241
opaAdd = 1;

0 commit comments

Comments
 (0)