UNPKG

@rnwonder/solid-date-picker

Version:

A responsive, highly-customizable datepicker component for SolidJS.

32 lines (31 loc) 1.2 kB
import { insert as r, createComponent as i, effect as s, className as l, template as c } from "solid-js/web"; import { Button as o } from "../Button/index.js"; import { cn as a } from "../../utils/class.js"; var d = c("<div>"); const f = (n) => { const t = (m) => a(` time-picker-meridiem-btn rn-aspect-square rn-w-[2.3rem] rn-flex-shrink-0 rn-rounded-full dark:rn-text-white `, { "\n dark:rn-bg-dark-time\n dark:hover:rn-bg-dark-time\n rn-bg-dark-time\n rn-text-white\n hover:rn-bg-dark-time\n ": n.meridiem() === m }, n.timePickerMeridiemBtnClass); return e = d(), r(e, i(o, { get class() { return t("AM"); }, onClick: () => n.setMeridiem("AM"), get noButtonAnimation() { return n.noButtonAnimation; }, children: "AM" }), null), r(e, i(o, { get class() { return t("PM"); }, onClick: () => n.setMeridiem("PM"), get noButtonAnimation() { return n.noButtonAnimation; }, children: "PM" }), null), s(() => l(e, a(` time-picker-analog-bottom rn-flex rn-justify-between `, n.timePickerBottomAreaClass))), e; var e; }; export { f as TimeAnalogBottom };