Calert Inputs
You can add many inputs as you can
calert({
text: 'Random Text:',
inputs: {
text: {
type: 'text',
placeholder: 'placeholder'
}
}
}).then(value => {
return calert(`You type ${value.inputs.text}`)
})
calert({
inputs: {
range: {
type: 'range'
},
date: {
type: 'date',
},
color: {
type: 'color',
},
number: {
type: 'number',
},
password: {
type: 'password'
}
}
}).then(val => console.log(val))
Multiple Inputs
calert({
inputs: {
text: {
type: 'text'
},
description: {
type: 'text',
},
secret: {
type: 'password',
}
}
})
Form
You can manipulate the form element via form option
You can change all the attributes of form
calert({
title: 'Login',
inputs: {
username: {
type: 'text',
placeholder: 'Username'
},
password: {
type: 'password',
placeholder: 'Password'
},
},
form: {
onSubmit: (e) => {
e.preventDefault();
},
method: 'POST',
},
confirmButton: false,
})