Choices: review r2 fixes

This commit is contained in:
ZacharyZhang-NY committed 2026-10-05 13:31:15 -04:00
1 parent 332d38b9d8
commit 40a37dfd92
10 files changed
+300 -54

No files matched your search

+4 -1
View File
@@ -127,7 +127,10 @@ func Combobox(c *ui.Context, value *string, options []string, opts ComboboxOptio
comboboxStatus(c, f.Bounds(), opts.Loading)
}
focused := in.Focused()
if v, ok := p.Chosen(); ok {
if in.IsDisabled() {
// Input delivered as the field turned disabled commits nothing.
*query = *value
} else if v, ok := p.Chosen(); ok {
*value, *query = v, v
*gen, *refocus = *gen+1, focused
} else if in.Submitted() && opts.AllowCustom {