UNPKG

@frontify/fondue

Version:
28 lines (27 loc) 1.1 kB
import { CHECKBOX_SPAN_CLASSES as c } from "../../Plugins/CheckboxListPlugin/CheckboxListElement.es.js"; import { merge as a } from "../../../../utilities/merge.es.js"; import { reactCssPropsToCss as l } from "../utils/reactCssPropsToCss.es.js"; const w = (t, r, i, s) => { const e = window.crypto.randomUUID(); return `<div dir="auto" disabled class="tw-flex tw-flex-row tw-pb-2 first-of-type:tw-ml-0 ${i}" style="margin-left:${(t.indent ?? 0) * 24}px;"> <div dir="auto" class="tw-flex tw-items-center tw-justify-center tw-select-none tw-mr-1.5"> <input aria-labelledby="${e}" aria-label="checkbox" class="tw-w-4 tw-h-4 tw-m-0 tw-pointer-events-none" type="checkbox" tabindex="-1" aria-disabled="true" ${t.checked ? "checked" : ""} /> </div> <span id="${e}" dir="auto" class="${a([ "tw-flex-1", t.checked ? "!tw-line-through" : "", c ])}" style="${l(s[t.children[0].textStyle])}">${r}</span> </div>`; }; export { w as checkItemNode }; //# sourceMappingURL=checkItem.es.js.map