Paulus Schoutsen 912969111f
Move all of hassUtil to JS (#1153)
* Move all of hassUtil to JS

* Fix tests
2018-05-09 21:33:31 -04:00

29 lines
619 B
JavaScript

import { h, Component } from 'preact';
import { onChangeEvent } from '../../common/preact/event.js';
export default class DelayAction extends Component {
constructor() {
super();
this.onChange = onChangeEvent.bind(this, 'action');
}
render({ action, localize }) {
const { delay } = action;
return (
<div>
<paper-input
label={localize('ui.panel.config.automation.editor.actions.type.delay.delay')}
name="delay"
value={delay}
onvalue-changed={this.onChange}
/>
</div>
);
}
}
DelayAction.defaultConfig = {
delay: '',
};