import './demo4.css';
import Calendar2 from '..';
import React from 'react';
import ReactDOM from 'react-dom';
import dayjs from 'dayjs';
import solarLunar from 'solarlunar';
function onDateChange(value) {
    console.log(value.format());
}
function dateCellRender(value) {
    const solar2lunarData = solarLunar.solar2lunar(value.year(), value.month(), value.date());
    return (React.createElement("div", { className: "custom-cell" },
        React.createElement("span", null, solar2lunarData.lDay === 1 ? solar2lunarData.monthCn : solar2lunarData.dayCn),
        value.date()));
}
ReactDOM.render(React.createElement("div", null,
    React.createElement(Calendar2, { onSelect: onDateChange, dateCellRender: dateCellRender, defaultValue: dayjs().add(1, 'days') })), document.getElementById('calendar2-demo-4'));
