'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

const index = require('./index-7cdf1df1.js');

const dvnTimePickerCss = "dvn-time-picker{display:block}";

function formatTwoDigits(value) {
  return value < 10 ? '0' + value : '' + value;
}
const DvnTimePicker = class {
  constructor(hostRef) {
    index.registerInstance(this, hostRef);
    this.hour = 9;
    this.minute = 0;
  }
  componentWillLoad() {
    this.hours = Array.apply(null, Array(24)).map((_, i) => i);
  }
  render() {
    const { hour, minute } = this;
    return (index.h(index.Host, null, index.h("dvn-input-group", { leaned: true }, index.h("dvn-select", { width: "50px", hideCaret: true, hideCheck: true, hideScrollbar: true, value: `${hour}` }, index.h("dvn-select-option", null, "HH"), this.hours.map(hour => (index.h("dvn-select-option", { value: `${hour}` }, formatTwoDigits(hour))))), index.h("dvn-select", { width: "50px", hideCaret: true, hideCheck: true, hideScrollbar: true, value: `${minute}` }, index.h("dvn-select-option", null, "mm"), index.h("dvn-select-option", { value: "0" }, "00"), index.h("dvn-select-option", { value: "15" }, "15"), index.h("dvn-select-option", { value: "30" }, "30"), index.h("dvn-select-option", { value: "45" }, "45")))));
  }
};
DvnTimePicker.style = dvnTimePickerCss;

exports.dvn_time_picker = DvnTimePicker;
