// Compiled from: Form_Field.jqhtml
(function() {
'use strict';
const template_Form_Field = {
_jqhtml_version: '2.2.185',
name: 'Form_Field',
tag: 'div',
defaultAttributes: {"class": "form-group mb-3"},
extends: 'Form_Field_Abstract',
render: function render(data, args, content, jqhtml) { let _output = []; const _cid = this._cid; const that = this;
_output.push(" ");
if (this.args.label) {
_output.push(" ");_output.push({tag: ["label", {"class": "form-label", "id": "form_label" + ":" + this._cid, "data-id": "form_label"}, false]});
_output.push(" "); (() => { const result = this.args.label ; if (Array.isArray(result)) { if (result.length === 2 && Array.isArray(result[0])) { _output.push(...result[0]); } else { _output.push(...result); } } else { _output.push(result); } })();
_output.push(" "); if (this.args.required) {
_output.push(" ");_output.push({tag: ["span", {"class": "text-danger"}, false]}); _output.push("*"); _output.push("");
_output.push(" "); }
_output.push(" "); _output.push("");
}
_output.push(" ");
_output.push({tag: ["div", {"class": (this.has_error() ? 'is-invalid' : '')}, false]});
_output.push(" "); (() => { if (this.args._inner_html) { _output.push(this.args._inner_html); } else if (typeof content === 'function') { const [contentInstructions] = content.call(this); _output.push(['_content', contentInstructions]); } })();
_output.push(" "); _output.push("");
if (this.has_error()) {
_output.push(" ");_output.push({tag: ["div", {"class": "invalid-feedback d-block"}, false]});
_output.push(" "); (() => { const result = this.get_error() ; if (Array.isArray(result)) { if (result.length === 2 && Array.isArray(result[0])) { _output.push(...result[0]); } else { _output.push(...result); } } else { _output.push(jqhtml.escape_html(result)); } })();
_output.push(" "); _output.push("");
}
_output.push(" ");
if (this.args.help) {
_output.push(" ");_output.push({tag: ["small", {"class": "form-text text-muted d-block mt-1"}, false]});
_output.push(" "); (() => { const result = this.args.help ; if (Array.isArray(result)) { if (result.length === 2 && Array.isArray(result[0])) { _output.push(...result[0]); } else { _output.push(...result); } } else { _output.push(jqhtml.escape_html(result)); } })();
_output.push(" "); _output.push("");
}
_output.push(" ");
return [_output, this]; },
dependencies: []
};
// Self-register with jqhtml runtime
// Must use window.jqhtml since we're in bundle scope
if (!window.jqhtml) {
throw new Error('FATAL: window.jqhtml is not defined. The jqhtml runtime must be loaded before registering templates.');
}
// Auto-register following standard jqhtml pattern
window.jqhtml.register_template(template_Form_Field);
})();
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImZvcm1fZmllbGQuanFodG1sIl0sInNvdXJjZXNDb250ZW50IjpbIjwhLS1cbkZvcm1fRmllbGRcblxuV3JhcHBlciBjb21wb25lbnQgdGhhdCBwcm92aWRlcyBjb25zaXN0ZW50IGxhYmVsLCBoZWxwIHRleHQsIGFuZCBlcnJvciBkaXNwbGF5IGZvciBmb3JtIHdpZGdldHMuXG5cbiRuYW1lIC0gRmllbGQgbmFtZSAocmVxdWlyZWQpIC0gdXNlZCBmb3IgZm9ybSBzZXJpYWxpemF0aW9uIGFuZCBlcnJvciBkaXNwbGF5XG4kbGFiZWwgLSBMYWJlbCB0ZXh0IHRvIGRpc3BsYXkgYWJvdmUgdGhlIGZpZWxkXG4kcmVxdWlyZWQgLSBCb29sZWFuIC0gaWYgdHJ1ZSwgc2hvd3MgcmVkIGFzdGVyaXNrIG5leHQgdG8gbGFiZWxcbiRoZWxwIC0gSGVscCB0ZXh0IHRvIGRpc3BsYXkgYmVsb3cgdGhlIGZpZWxkXG5cblVzYWdlOlxuPEZvcm1fRmllbGQgJG5hbWU9XCJlbWFpbFwiICRsYWJlbD1cIkVtYWlsIEFkZHJlc3NcIiAkcmVxdWlyZWQ9dHJ1ZSAkaGVscD1cIldlJ2xsIG5ldmVyIHNoYXJlIHlvdXIgZW1haWxcIj5cbiAgICA8VGV4dF9JbnB1dCAkcGxhY2Vob2xkZXI9XCJ1c2VyQGV4YW1wbGUuY29tXCIgLz5cbjwvRm9ybV9GaWVsZD5cbi0tPlxuPERlZmluZTpGb3JtX0ZpZWxkIGV4dGVuZHM9XCJGb3JtX0ZpZWxkX0Fic3RyYWN0XCIgdGFnPVwiZGl2XCIgY2xhc3M9XCJmb3JtLWdyb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