adding some market elements
This commit is contained in:
@@ -487,6 +487,13 @@ HTMLElement.prototype.positionType = function (value) {
|
||||
return this
|
||||
}
|
||||
|
||||
HTMLElement.prototype.gap = function(value, unit = "px") {
|
||||
if (typeof value !== 'number' || Number.isNaN(value))
|
||||
throw new Error(`Invalid value: ${value}. Expected a number.`);
|
||||
this.style.gap = value + unit
|
||||
return this
|
||||
}
|
||||
|
||||
/* Elements */
|
||||
|
||||
quill.setChildren = function(el, innerContent) {
|
||||
@@ -617,6 +624,13 @@ window.input = function(placeholder, width, height) {
|
||||
return el
|
||||
}
|
||||
|
||||
window.label = function(text) {
|
||||
let el = document.createElement("label")
|
||||
el.innerText = text
|
||||
quill.render(el)
|
||||
return el
|
||||
}
|
||||
|
||||
window.textarea = function(placeholder) {
|
||||
let el = document.createElement("textarea")
|
||||
el.placeholder = placeholder
|
||||
|
||||
Reference in New Issue
Block a user