2020-06-19 05:07:51 +00:00
|
|
|
import {
|
|
|
|
attribute,
|
|
|
|
blurrable,
|
|
|
|
clickable,
|
|
|
|
fillable,
|
|
|
|
focusable,
|
|
|
|
isPresent,
|
|
|
|
text,
|
|
|
|
triggerable,
|
|
|
|
value,
|
|
|
|
} from 'ember-cli-page-object';
|
|
|
|
|
|
|
|
export default scope => ({
|
|
|
|
scope,
|
|
|
|
|
|
|
|
label: text('[data-test-stepper-label]'),
|
|
|
|
|
|
|
|
input: {
|
|
|
|
scope: '[data-test-stepper-input]',
|
|
|
|
fill: fillable(),
|
|
|
|
focus: focusable(),
|
|
|
|
blur: blurrable(),
|
|
|
|
value: value(),
|
|
|
|
esc: triggerable('keydown', '', { eventProperties: { keyCode: 27 } }),
|
2020-06-19 06:20:24 +00:00
|
|
|
isDisabled: attribute('disabled'),
|
2020-06-19 05:07:51 +00:00
|
|
|
},
|
|
|
|
|
|
|
|
decrement: {
|
|
|
|
scope: '[data-test-stepper-decrement]',
|
|
|
|
click: clickable(),
|
|
|
|
isPresent: isPresent(),
|
|
|
|
isDisabled: attribute('disabled'),
|
|
|
|
classNames: attribute('class'),
|
|
|
|
},
|
|
|
|
|
|
|
|
increment: {
|
|
|
|
scope: '[data-test-stepper-increment]',
|
|
|
|
click: clickable(),
|
|
|
|
isPresent: isPresent(),
|
|
|
|
isDisabled: attribute('disabled'),
|
|
|
|
classNames: attribute('class'),
|
|
|
|
},
|
|
|
|
});
|