|
|
@ -115,7 +115,7 @@ const builder = { |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
img: function (attr = {}) { return builder.genTag("img", attr); }, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
@ -129,42 +129,42 @@ const builder = { |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
table: function (attr = {}) { return builder.genTag("table", attr) }, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
tableRow: function (attr = {}) { return builder.genTag("tr", attr) }, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
tableCell: function (attr = {}) { return builder.genTag("td", attr) }, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
tableCaption: function (attr = {}) { return builder.genTag("caption", attr) }, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
tableHeadCell: function (attr = {}) { return builder.genTag("th", attr) }, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
tableBody: function (attr = {}) { return builder.genTag("tbody", attr) }, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
@ -177,19 +177,25 @@ const builder = { |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
tableFooter: function (attr = {}) { return builder.genTag("tfoot", attr) }, |
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
iframe: function (attr = {}) { return builder.genTag("iframe", attr) }, |
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* @param {Map<string,string>} attr |
|
|
|
* @returns {Component} |
|
|
|
*/ |
|
|
|
form: function (attr = {}) { |
|
|
|
form: function (attr = {}) { |
|
|
|
return builder.genTag("form", attr) |
|
|
|
.addStyleClass("flex-container-component") |
|
|
|
.chainModifier() |
|
|
|
.setStyleRule("flex-direction", "column") |
|
|
|
.ensureModifier() |
|
|
|
.toComponent() |
|
|
|
.addStyleClass("flex-container-component") |
|
|
|
.chainModifier() |
|
|
|
.setStyleRule("flex-direction", "column") |
|
|
|
.ensureModifier() |
|
|
|
.toComponent() |
|
|
|
}, |
|
|
|
|
|
|
|
/** |
|
|
@ -212,14 +218,14 @@ const builder = { |
|
|
|
*/ |
|
|
|
page: function (innerComponents) { |
|
|
|
let main = document.querySelector('main') |
|
|
|
|
|
|
|
|
|
|
|
main.parentElement.insertAdjacentElement( |
|
|
|
"afterbegin", |
|
|
|
builder.genTag("main") |
|
|
|
.alignment(Alignment.CENTER) |
|
|
|
.arrangement(Arrangement.CENTER) |
|
|
|
.childContext(innerComponents) |
|
|
|
.generate() |
|
|
|
.alignment(Alignment.CENTER) |
|
|
|
.arrangement(Arrangement.CENTER) |
|
|
|
.childContext(innerComponents) |
|
|
|
.generate() |
|
|
|
) |
|
|
|
Page.generate(); |
|
|
|
main.remove(); |
|
|
|