@wix/design-system
Version:
@wix/design-system
29 lines • 791 B
JavaScript
import { baseUniDriverFactory } from '../utils/test-utils/unidriver';
export const badgeUniDriverFactory = (base) => ({
...baseUniDriverFactory(base),
/**
* Gets badge text
*/
text: () => base.text(),
/**
* Gets badge type
*/
getType: () => base.attr('data-type'),
/**
* Gets badge type
*/
getSkin: () => base.attr('data-skin'),
/**
* Gets badge size
*/
getSize: () => base.attr('data-size'),
/**
* Checks whether the text is uppercase
*/
isUppercase: async () => (await base.attr('data-uppercase')) === 'true',
/**
* Checks whether badge is clickable
*/
hasClickCursor: async () => (await base.attr('data-clickable')) === 'true',
});
//# sourceMappingURL=Badge.uni.driver.js.map