feat: add combobox component

This commit is contained in:
talksik
2025-04-11 14:09:38 -07:00
parent c9a05a3c45
commit 10d3f77d94
4 changed files with 25 additions and 0 deletions
+13
View File
@@ -80,5 +80,18 @@ AppWindow {
buttons: MessageDialog.Ok
text: "The document has been modified."
}
AppComboBox {
model: ListModel {
id: model
ListElement { text: "Banana" }
ListElement { text: "Apple" }
ListElement { text: "Coconut" }
}
onAccepted: {
if (find(editText) === -1)
model.append({text: editText})
}
}
}
}