mirror of
https://github.com/maputnik/editor.git
synced 2025-12-08 07:10:00 +00:00
Improve tests (#854)
Recover commented out tests, Improve usage of helper in driver, Added data-wd-key for test to use instead of classes Moved all non tsx file to a single folder (lib) instead of lib and utils --------- Co-authored-by: Yuri Astrakhan <yuriastrakhan@gmail.com>
This commit is contained in:
@@ -9,7 +9,7 @@ export type InputNumberProps = {
|
||||
onChange?(value: number | undefined): unknown
|
||||
allowRange?: boolean
|
||||
rangeStep?: number
|
||||
wdKey?: string
|
||||
"data-wd-key"?: string
|
||||
required?: boolean
|
||||
"aria-label"?: string
|
||||
};
|
||||
@@ -197,6 +197,7 @@ export default class InputNumber extends React.Component<InputNumberProps, Input
|
||||
dirtyValue: this.state.value,
|
||||
});
|
||||
}}
|
||||
data-wd-key={this.props["data-wd-key"] + "-range"}
|
||||
/>
|
||||
<input
|
||||
key="text"
|
||||
@@ -215,6 +216,8 @@ export default class InputNumber extends React.Component<InputNumberProps, Input
|
||||
this.setState({editing: false});
|
||||
this.resetValue()
|
||||
}}
|
||||
data-wd-key={this.props["data-wd-key"] + "-text"}
|
||||
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
@@ -233,6 +236,7 @@ export default class InputNumber extends React.Component<InputNumberProps, Input
|
||||
}}
|
||||
onBlur={this.resetValue}
|
||||
required={this.props.required}
|
||||
data-wd-key={this.props["data-wd-key"]}
|
||||
/>
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user