aboutsummaryrefslogtreecommitdiff
path: root/modules/ui_components.py
diff options
context:
space:
mode:
authorAUTOMATIC1111 <16777216c@gmail.com>2023-04-29 22:13:40 +0300
committerGitHub <noreply@github.com>2023-04-29 22:13:40 +0300
commit15c4e78b44e14d70b82dcb5b563251fed7be0766 (patch)
tree6f1acaae50a49544a08384b52739df3e2d803a10 /modules/ui_components.py
parent3e5b3c79e49ec3a10174c250815dabce6efdddca (diff)
parent2e78e65a22bfa6b116ae18d12fdcb85ec8acd727 (diff)
Merge branch 'dev' into feature/restore-progress
Diffstat (limited to 'modules/ui_components.py')
-rw-r--r--modules/ui_components.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/modules/ui_components.py b/modules/ui_components.py
index 2b1da2cb..64451df7 100644
--- a/modules/ui_components.py
+++ b/modules/ui_components.py
@@ -62,3 +62,13 @@ class DropdownMulti(FormComponent, gr.Dropdown):
def get_block_name(self):
return "dropdown"
+
+
+class DropdownEditable(FormComponent, gr.Dropdown):
+ """Same as gr.Dropdown but allows editing value"""
+ def __init__(self, **kwargs):
+ super().__init__(allow_custom_value=True, **kwargs)
+
+ def get_block_name(self):
+ return "dropdown"
+