Enhance dinosaur forms and templates with improved styling and layout using Bulma CSS framework
This commit is contained in:
+9
-1
@@ -10,5 +10,13 @@ class DinosaurForm(forms.ModelForm):
|
||||
'speed', 'weight', 'intelligence', 'height',
|
||||
]
|
||||
widgets = {
|
||||
'description': forms.Textarea(attrs={'rows': 3}),
|
||||
'name': forms.TextInput(attrs={'class': 'input', 'placeholder': 'T. rex'}),
|
||||
'era': forms.Select(attrs={'class': 'input'}),
|
||||
'diet': forms.Select(attrs={'class': 'input'}),
|
||||
'description': forms.Textarea(attrs={'class': 'textarea', 'rows': 3}),
|
||||
'image': forms.ClearableFileInput(attrs={'class': 'file-input'}),
|
||||
'speed': forms.NumberInput(attrs={'class': 'input', 'min': 0, 'max': 100}),
|
||||
'weight': forms.NumberInput(attrs={'class': 'input', 'min': 0, 'max': 100}),
|
||||
'intelligence': forms.NumberInput(attrs={'class': 'input', 'min': 0, 'max': 100}),
|
||||
'height': forms.NumberInput(attrs={'class': 'input', 'min': 0, 'max': 100}),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user