Repository URL to install this package:
|
Version:
2.7.11 ▾
|
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
const tslib_1 = require("tslib");
const react_1 = tslib_1.__importDefault(require("react"));
const styleh_components_1 = require("styleh-components"); // import Calendar from 'react-calendar'
const Text_1 = require("../../atoms/Text");
const Calendar = props => react_1.default.createElement("div", Object.assign({}, props), "fixme");
const calendarAlignment = item => {
switch (item) {
case 'tl':
case 'lt':
return 'bottom: 100%; left: 0;';
case 'tr':
case 'rt':
return 'bottom: 100%; right: 0;';
case 'rb':
case 'br':
return 'top: 100%; right: 0;';
case 'bl':
case 'lb':
default:
return 'top: 100%; left: 0;';
}
};
const PickerLabel = styleh_components_1.styled.withComponent(Text_1.Label)`text-transform:capitalize;cursor:pointer;color:blue;`;
exports.PickerLabel = PickerLabel;
const DatePickerLabel = styleh_components_1.styled.withComponent(Text_1.Label)``;
exports.DatePickerLabel = DatePickerLabel;
const StyledCalendar = styleh_components_1.styled.withComponent(Calendar)`display:${props => props.isShowCalendar ? 'block' : 'none'} ${props => props.align && styleh_components_1.styled.css`position:absolute;z-index:9;`} ${props => props.align && calendarAlignment(props.align)};`;
exports.StyledCalendar = StyledCalendar;
const Wrapper = styleh_components_1.styled.section`position:relative;`;
exports.Wrapper = Wrapper; //# sourceMappingURL=styled.js.map