summaryrefslogtreecommitdiff
path: root/django/forms/widgets.py
diff options
context:
space:
mode:
authorJeremy Thompson <jeremythompson.918@gmail.com>2024-07-17 16:50:01 +0100
committerSarah Boyce <42296566+sarahboyce@users.noreply.github.com>2024-07-31 13:11:45 +0200
commit30a60e84923c18f3b2c725f7a31e521a833b8057 (patch)
tree80224aef71d105ed92a6517ce82da70939cdf59e /django/forms/widgets.py
parent3f880890699d4412cf23b59dba425111f62afb3a (diff)
Fixed #35598 -- Added SearchInput widget.
Diffstat (limited to 'django/forms/widgets.py')
-rw-r--r--django/forms/widgets.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/django/forms/widgets.py b/django/forms/widgets.py
index 4fae110d5e..e7717c2ff6 100644
--- a/django/forms/widgets.py
+++ b/django/forms/widgets.py
@@ -30,6 +30,7 @@ __all__ = (
"NumberInput",
"EmailInput",
"URLInput",
+ "SearchInput",
"PasswordInput",
"HiddenInput",
"MultipleHiddenInput",
@@ -353,6 +354,11 @@ class URLInput(Input):
template_name = "django/forms/widgets/url.html"
+class SearchInput(Input):
+ input_type = "search"
+ template_name = "django/forms/widgets/search.html"
+
+
class PasswordInput(Input):
input_type = "password"
template_name = "django/forms/widgets/password.html"