refactor: remove field.f.PrepareView

This commit is contained in:
Simon Vieille 2025-07-27 12:34:49 +02:00
commit e48e850fa3
Signed by: deblan
GPG key ID: 579388D585F70417

View file

@ -61,7 +61,6 @@ type Field struct {
Children []*Field
Constraints []validation.Constraint
Errors []validation.Error
PrepareView func() map[string]any
BeforeMount func(data any) (any, error)
BeforeBind func(data any) (any, error)
Validate func(f *Field) bool
@ -81,12 +80,6 @@ func NewField(name, widget string) *Field {
Data: nil,
}
f.PrepareView = func() map[string]any {
m := make(map[string]any)
return m
}
f.BeforeMount = func(data any) (any, error) {
return data, nil
}