dees-element/test/test.browser.ts

25 lines
603 B
TypeScript
Raw Normal View History

2021-03-27 16:52:06 +00:00
import { expect, tap } from '@pushrocks/tapbundle';
import * as deesElement from '../ts/index';
tap.test('should create a static element', async () => {
@deesElement.customElement('my-button')
class MyButton extends deesElement.DeesElement {
// STATIC
public static styles = [
2021-12-10 16:01:03 +00:00
deesElement.cssManager.defaultStyles,
2021-03-27 16:52:06 +00:00
deesElement.css`
.buttonClass {
2021-03-28 20:10:51 +00:00
background: ${deesElement.cssManager.bdTheme('blue', 'black')};
2021-03-27 16:52:06 +00:00
}
`
];
// INSTANCE
render() {
return deesElement.html`<div class="buttonClass">My Button</div>`
}
}
});
tap.start();