"""Custom `BaseForm` and `BaseModelForm` plus Django form-class re-exports.
`BaseForm` and `BaseModelForm` extend Django with `get_initial`, which
lets `@action` resolve initial data from the request and URL kwargs
before binding the form. `Form` and `ModelForm` apply the right
metaclass so declarative field syntax continues to work. The Django
form classes re-exported below are a convenience so user code can do
`from next.forms import CharField, EmailField` without reaching into
Django directly.
"""
from __future__ import annotations
from typing import Any
from django import forms as django_forms
from django.forms.forms import BaseForm as DjangoBaseForm, DeclarativeFieldsMetaclass
from django.forms.models import BaseModelForm as DjangoBaseModelForm, ModelFormMetaclass
CharField = django_forms.CharField
EmailField = django_forms.EmailField
IntegerField = django_forms.IntegerField
BooleanField = django_forms.BooleanField
ChoiceField = django_forms.ChoiceField
TypedChoiceField = django_forms.TypedChoiceField
MultipleChoiceField = django_forms.MultipleChoiceField
DateField = django_forms.DateField
DateTimeField = django_forms.DateTimeField
DecimalField = django_forms.DecimalField
FloatField = django_forms.FloatField
URLField = django_forms.URLField
RegexField = django_forms.RegexField
FileField = django_forms.FileField
ImageField = django_forms.ImageField
ValidationError = django_forms.ValidationError
PasswordInput = django_forms.PasswordInput
TextInput = django_forms.TextInput
Textarea = django_forms.Textarea
Select = django_forms.Select
CheckboxInput = django_forms.CheckboxInput
SelectMultiple = django_forms.SelectMultiple
DateInput = django_forms.DateInput
DateTimeInput = django_forms.DateTimeInput
TimeInput = django_forms.TimeInput
NumberInput = django_forms.NumberInput
EmailInput = django_forms.EmailInput
URLInput = django_forms.URLInput
HiddenInput = django_forms.HiddenInput
Widget = django_forms.Widget
__all__ = [
"BaseForm",
"BaseModelForm",
"BooleanField",
"CharField",
"CheckboxInput",
"ChoiceField",
"DateField",
"DateInput",
"DateTimeField",
"DateTimeInput",
"DecimalField",
"EmailField",
"EmailInput",
"FileField",
"FloatField",
"Form",
"HiddenInput",
"ImageField",
"IntegerField",
"ModelForm",
"MultipleChoiceField",
"NumberInput",
"PasswordInput",
"RegexField",
"Select",
"SelectMultiple",
"TextInput",
"Textarea",
"TimeInput",
"TypedChoiceField",
"URLField",
"URLInput",
"ValidationError",
"Widget",
]