Commit 9ce5d9c0 authored by Sven Franck's avatar Sven Franck

app: fixed text of radio group label/legend

parent 9c8233d3
...@@ -997,6 +997,7 @@ ...@@ -997,6 +997,7 @@
direction = spec.direction || "vertical"; direction = spec.direction || "vertical";
// NOTE: will only be used for dynamic element creation // NOTE: will only be used for dynamic element creation
// TODO: what does this do here?
generator = function (generator_spec) { generator = function (generator_spec) {
var element = generator_spec.item; var element = generator_spec.item;
// TODO: no! // TODO: no!
...@@ -1013,6 +1014,7 @@ ...@@ -1013,6 +1014,7 @@
// controlgroup label // controlgroup label
if (spec.label) { if (spec.label) {
// TODO: how to get required on the legend? or off?
// NOTE: this will always wrap controlgroups!!! // NOTE: this will always wrap controlgroups!!!
i18n = spec.label.title_i18n || spec.label.text_i18n; i18n = spec.label.title_i18n || spec.label.text_i18n;
contain = factory.element({ contain = factory.element({
...@@ -1030,9 +1032,11 @@ ...@@ -1030,9 +1032,11 @@
}); });
label.appendChild(factory.element({ label.appendChild(factory.element({
"type": "legend", "type": "legend",
"logic": { "direct": {
"text": spec.label.text, "className": "translate required_label"
"data-i18n": i18n ? (spec.label.text_i18n) : null },
"attributes": {
"data-i18n": spec.label.text_i18n
} }
})); }));
contain.appendChild(label); contain.appendChild(label);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment