Lint forms
This commit is contained in:
parent
43072a357f
commit
4d93545d88
|
@ -219,18 +219,12 @@ class EditionForm(CustomForm):
|
||||||
"search_vector",
|
"search_vector",
|
||||||
]
|
]
|
||||||
widgets = {
|
widgets = {
|
||||||
"title": forms.TextInput(
|
"title": forms.TextInput(attrs={"aria-describedby": "desc_title"}),
|
||||||
attrs={"aria-describedby": "desc_title"}
|
"subtitle": forms.TextInput(attrs={"aria-describedby": "desc_subtitle"}),
|
||||||
),
|
|
||||||
"subtitle": forms.TextInput(
|
|
||||||
attrs={"aria-describedby": "desc_subtitle"}
|
|
||||||
),
|
|
||||||
"description": forms.Textarea(
|
"description": forms.Textarea(
|
||||||
attrs={"aria-describedby": "desc_description"}
|
attrs={"aria-describedby": "desc_description"}
|
||||||
),
|
),
|
||||||
"series": forms.TextInput(
|
"series": forms.TextInput(attrs={"aria-describedby": "desc_series"}),
|
||||||
attrs={"aria-describedby": "desc_series"}
|
|
||||||
),
|
|
||||||
"series_number": forms.TextInput(
|
"series_number": forms.TextInput(
|
||||||
attrs={"aria-describedby": "desc_series_number"}
|
attrs={"aria-describedby": "desc_series_number"}
|
||||||
),
|
),
|
||||||
|
@ -255,15 +249,9 @@ class EditionForm(CustomForm):
|
||||||
"physical_format_detail": forms.TextInput(
|
"physical_format_detail": forms.TextInput(
|
||||||
attrs={"aria-describedby": "desc_physical_format_detail"}
|
attrs={"aria-describedby": "desc_physical_format_detail"}
|
||||||
),
|
),
|
||||||
"pages": forms.NumberInput(
|
"pages": forms.NumberInput(attrs={"aria-describedby": "desc_pages"}),
|
||||||
attrs={"aria-describedby": "desc_pages"}
|
"isbn_13": forms.TextInput(attrs={"aria-describedby": "desc_isbn_13"}),
|
||||||
),
|
"isbn_10": forms.TextInput(attrs={"aria-describedby": "desc_isbn_10"}),
|
||||||
"isbn_13": forms.TextInput(
|
|
||||||
attrs={"aria-describedby": "desc_isbn_13"}
|
|
||||||
),
|
|
||||||
"isbn_10": forms.TextInput(
|
|
||||||
attrs={"aria-describedby": "desc_isbn_10"}
|
|
||||||
),
|
|
||||||
"openlibrary_key": forms.TextInput(
|
"openlibrary_key": forms.TextInput(
|
||||||
attrs={"aria-describedby": "desc_openlibrary_key"}
|
attrs={"aria-describedby": "desc_openlibrary_key"}
|
||||||
),
|
),
|
||||||
|
@ -273,9 +261,7 @@ class EditionForm(CustomForm):
|
||||||
"oclc_number": forms.TextInput(
|
"oclc_number": forms.TextInput(
|
||||||
attrs={"aria-describedby": "desc_oclc_number"}
|
attrs={"aria-describedby": "desc_oclc_number"}
|
||||||
),
|
),
|
||||||
"ASIN": forms.TextInput(
|
"ASIN": forms.TextInput(attrs={"aria-describedby": "desc_ASIN"}),
|
||||||
attrs={"aria-describedby": "desc_ASIN"}
|
|
||||||
),
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -296,24 +282,14 @@ class AuthorForm(CustomForm):
|
||||||
"goodreads_key",
|
"goodreads_key",
|
||||||
]
|
]
|
||||||
widgets = {
|
widgets = {
|
||||||
"name": forms.TextInput(
|
"name": forms.TextInput(attrs={"aria-describedby": "desc_name"}),
|
||||||
attrs={"aria-describedby": "desc_name"}
|
"aliases": forms.TextInput(attrs={"aria-describedby": "desc_aliases"}),
|
||||||
),
|
"bio": forms.Textarea(attrs={"aria-describedby": "desc_bio"}),
|
||||||
"aliases": forms.TextInput(
|
|
||||||
attrs={"aria-describedby": "desc_aliases"}
|
|
||||||
),
|
|
||||||
"bio": forms.Textarea(
|
|
||||||
attrs={"aria-describedby": "desc_bio"}
|
|
||||||
),
|
|
||||||
"wikipedia_link": forms.TextInput(
|
"wikipedia_link": forms.TextInput(
|
||||||
attrs={"aria-describedby": "desc_wikipedia_link"}
|
attrs={"aria-describedby": "desc_wikipedia_link"}
|
||||||
),
|
),
|
||||||
"born": forms.SelectDateWidget(
|
"born": forms.SelectDateWidget(attrs={"aria-describedby": "desc_born"}),
|
||||||
attrs={"aria-describedby": "desc_born"}
|
"died": forms.SelectDateWidget(attrs={"aria-describedby": "desc_died"}),
|
||||||
),
|
|
||||||
"died": forms.SelectDateWidget(
|
|
||||||
attrs={"aria-describedby": "desc_died"}
|
|
||||||
),
|
|
||||||
"oepnlibrary_key": forms.TextInput(
|
"oepnlibrary_key": forms.TextInput(
|
||||||
attrs={"aria-describedby": "desc_oepnlibrary_key"}
|
attrs={"aria-describedby": "desc_oepnlibrary_key"}
|
||||||
),
|
),
|
||||||
|
@ -419,12 +395,8 @@ class AnnouncementForm(CustomForm):
|
||||||
model = models.Announcement
|
model = models.Announcement
|
||||||
exclude = ["remote_id"]
|
exclude = ["remote_id"]
|
||||||
widgets = {
|
widgets = {
|
||||||
"preview": forms.TextInput(
|
"preview": forms.TextInput(attrs={"aria-describedby": "desc_preview"}),
|
||||||
attrs={"aria-describedby": "desc_preview"}
|
"content": forms.Textarea(attrs={"aria-describedby": "desc_content"}),
|
||||||
),
|
|
||||||
"content": forms.Textarea(
|
|
||||||
attrs={"aria-describedby": "desc_content"}
|
|
||||||
),
|
|
||||||
"event_date": forms.SelectDateWidget(
|
"event_date": forms.SelectDateWidget(
|
||||||
attrs={"aria-describedby": "desc_event_date"}
|
attrs={"aria-describedby": "desc_event_date"}
|
||||||
),
|
),
|
||||||
|
@ -434,9 +406,7 @@ class AnnouncementForm(CustomForm):
|
||||||
"end_date": forms.SelectDateWidget(
|
"end_date": forms.SelectDateWidget(
|
||||||
attrs={"aria-describedby": "desc_end_date"}
|
attrs={"aria-describedby": "desc_end_date"}
|
||||||
),
|
),
|
||||||
"active": forms.CheckboxInput(
|
"active": forms.CheckboxInput(attrs={"aria-describedby": "desc_active"}),
|
||||||
attrs={"aria-describedby": "desc_active"}
|
|
||||||
),
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -463,9 +433,7 @@ class EmailBlocklistForm(CustomForm):
|
||||||
model = models.EmailBlocklist
|
model = models.EmailBlocklist
|
||||||
fields = ["domain"]
|
fields = ["domain"]
|
||||||
widgets = {
|
widgets = {
|
||||||
"avatar": forms.TextInput(
|
"avatar": forms.TextInput(attrs={"aria-describedby": "desc_domain"}),
|
||||||
attrs={'aria-describedby': "desc_domain"}
|
|
||||||
),
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue