adjustment
This commit is contained in:
@ -29,7 +29,7 @@ function fillCheckbox(container, type = 'fa-regular', label, tabindex = -1, char
|
||||
}
|
||||
}
|
||||
|
||||
function createRadiobox(opts = {}) {
|
||||
export function createRadiobox(opts = {}) {
|
||||
const container = createElement('label', 'ui-check-wrapper ui-radio-wrapper',
|
||||
createElement('input', input => {
|
||||
input.setAttribute('type', 'radio');
|
||||
@ -56,7 +56,7 @@ function createRadiobox(opts = {}) {
|
||||
return container;
|
||||
}
|
||||
|
||||
function createCheckbox(opts = {}) {
|
||||
export function createCheckbox(opts = {}) {
|
||||
const container = createElement('label', 'ui-check-wrapper',
|
||||
createElement('input', input => {
|
||||
input.setAttribute('type', 'checkbox');
|
||||
@ -97,7 +97,7 @@ function createCheckbox(opts = {}) {
|
||||
return container;
|
||||
}
|
||||
|
||||
function resolveCheckbox(container = document.body, legacy) {
|
||||
export function resolveCheckbox(container = document.body, legacy) {
|
||||
if (legacy) {
|
||||
const checks = container.querySelectorAll('input[type="checkbox"]');
|
||||
for (let chk of checks) {
|
||||
@ -177,10 +177,4 @@ function resolveCheckbox(container = document.body, legacy) {
|
||||
box.insertBefore(input, box.firstChild);
|
||||
}
|
||||
return container;
|
||||
}
|
||||
|
||||
export {
|
||||
createCheckbox,
|
||||
resolveCheckbox,
|
||||
createRadiobox
|
||||
}
|
Reference in New Issue
Block a user