Adding variants and labels to entry, not yet done.

This commit is contained in:
2019-11-18 20:27:11 +01:00
parent a058a50017
commit 4bdb3bfc7f
8 changed files with 68 additions and 19 deletions

View File

@@ -22,12 +22,12 @@ def question(question, current_value):
h("input#modal-question", {"props": {"type": "text", "value": current_value}}, "")])]
def generic_list_editor(title, element_list_getter, add_click_message):
content = [h("span.list", {}, title)]
def generic_list_editor(title, element_list_getter):
content = [h("p", {}, title)]
for slabel in element_list_getter():
content.append(h("label", {}, [
h("input.list-adder-input", {"props": {"type": "text", "value": slabel}}, "")]))
content.append(h("button", {"on": {"click": add_click_message}}, "+"))
content.append(h("button", {"on": {"click": message.msg(message.AddToGenericList(element_list_getter))}}, "+"))
return content