forked from MapComplete/MapComplete
Fix dynamism in questions with new VariableInputElement
This commit is contained in:
parent
b6b20ed3ca
commit
abae813606
6 changed files with 98 additions and 61 deletions
|
@ -25,6 +25,7 @@ export default class EditableTagRendering extends Toggle {
|
|||
const renderingIsShown = tags.map(tags =>
|
||||
configuration.IsKnown(tags) &&
|
||||
(configuration?.condition?.matchesProperties(tags) ?? true))
|
||||
|
||||
super(
|
||||
new Lazy(() => EditableTagRendering.CreateRendering(tags, configuration, units, editMode)),
|
||||
undefined,
|
||||
|
@ -49,8 +50,8 @@ export default class EditableTagRendering extends Toggle {
|
|||
]).SetClass("flex justify-between w-full")
|
||||
|
||||
|
||||
const question = new Lazy(() => {
|
||||
return new TagRenderingQuestion(tags, configuration,
|
||||
const question = new Lazy(() =>
|
||||
new TagRenderingQuestion(tags, configuration,
|
||||
{
|
||||
units: units,
|
||||
cancelButton: Translations.t.general.cancel.Clone()
|
||||
|
@ -61,10 +62,7 @@ export default class EditableTagRendering extends Toggle {
|
|||
afterSave: () => {
|
||||
editMode.setData(false)
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
})
|
||||
}))
|
||||
|
||||
|
||||
rendering = new Toggle(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue