form_bloc 0.20.2 form_bloc: ^0.20.2 copied to clipboard
Easy Form State Management using BLoC pattern. Separate the Form State and Business Logic from the User Interface. Async Validation, Progress, Dynamic fields, and more.
0.20.2 #
- Update packages
- Add bool on form checking field blocs are initial
- Fixing type error with updated suggestion function
0.20.1 #
- code improvements
0.19.1 #
- Fix add
FormBloc
of items inListFieldBloc
.
0.18.0 #
Bad version, you should use >=0.19.0
or <= 0.15.0
0.17.0 #
Bad version, you should use >=0.19.0
or <= 0.15.0
0.16.0 #
Bad version, you should use >=0.19.0
or <= 0.15.0
0.15.0 #
Breaking changes #
- Updated to
bloc: ^5.0.1
. - Change
Bloc.addError
toBloc.addFieldError
. - Change
FormBlocDelegate
toFormBlocObserver
.
0.14.0 #
- Updated to
bloc: ^4.0.0
0.13.1 #
- Fixed pedantic version.
0.13.0 #
- Now the value of all field blocs are updated when call
updateValue
andupdateInitialValue
when theFormBlocState
isFormBlocSubmitting
.
0.11.1 #
- Deprecated
isRequired
parameter in all field blocs, in form_bloc^0.12.0
will be removed, if you want a field to be required, please use the validatorFieldBlocValidators.required
.
0.11.0 #
Breaking changes #
- Add support for forms with steps.
- Use
AddFieldBloc({int step, List<FieldBloc> fieldBlocs})
.
- Use
- All
SingleFieldBloc
s now haveExtraData
type. - Changes
FieldBlocList
toListFieldBloc
. - Add
GroupFieldBloc
as base class for create typed groups of field blocs. - Add
toJson
method toFormBlocState
. - Remove
FormBlocState.getFieldBlocFromPath
. - Add
valueOf
method toFormBlocState
. - Add
fieldBlocOf
method toFormBlocState
. - Remove
onReload
ofFormBloc
, now when you callFormBloc.reload
,onLoading
will be called. - Add
onValueChanges
StreamSubscription toSingleFieldBloc
. - Add
FormBlocUpdatingFields
state. - Add
isRequired
parameter toFieldBloc
, and the error isFieldBlocValidatorsError.required
, so the follow validators are removed:FieldBlocValidators.requiredInputFieldBloc
FieldBlocValidators.requiredBooleanFieldBloc
FieldBlocValidators.requiredTextFieldBloc
FieldBlocValidators.requiredSelectFieldBloc
FieldBlocValidators.requiredMultiSelectFieldBloc
- Add
FormBlocUpdatingFields
state. - Add
progress
property toFormBlocLoading
andFormBlocDeleting
. - Change
Stream<State> onSubmitting()
tovoid onSubmitting()
. - Change
Stream<State> onLoading()
tovoid onLoading()
. - Change
Stream<State> onDeleting()
tovoid onDeleting()
. - Add methods for emit new states:
- emitSuccess
- emitFailure
- emitSubmitting
- emitLoading
- emitLoadFailed
- emitLoaded
- emitSubmissionCancelled
- emitDeleteFailed
- emitDeleteSuccessful
- emitUpdatingFields
0.10.4 #
- Fixed minor bug.
0.10.3 #
- Fixed
hasFailureResponse
property ofFormBlocLoadFailed
,FormBlocFailure
andFormBlocDeleteFailed
.
0.10.2 #
- Changes
FieldBloc.addError(String error)
toFieldBloc.addError(String error, {bool isPermanent = false})
. - Documentation Updates.
0.10.1 #
clear
method ofFieldBloc
now callupdateInitialValue
instead ofupdateValue
.- Fixed
clear
method ofFormBloc
. - Documentation Updates.
0.10.0 #
Breaking changes #
- Removed
fieldBlocs
getter ofFormBloc
. now you must useaddFieldBloc
method. - Renamed
onDelete
method ofFormBloc
toonDeleting
. - Added
canSubmitAgain
parameter totoSuccess
method ofFormBlocState
. - Now
FieldBloc
can be dynamically added to aFormBloc
withaddFieldBloc
. - Now
FieldBloc
can be dynamically removed from aFormBloc
withremoveFieldBloc
. - Added
fieldBlocs
property toFormBlocState
. FieldBloc
is now implemented by 3 classes:SingleFieldBloc
which is the Interface of:InputFieldBloc
.TextFieldBloc
.BooleanFieldBloc
.SelectFieldBloc
.MultiSelectFieldBloc
.
GroupFieldBloc
.FieldBlocList
.
- Documentation Updates.
0.8.0 #
- Added
isEditing
property toFormBlocState
(#9). - Added
delete
event toFormBloc
(#9). - Added
toDeleteFailed
andtoDeleteSuccessful
methods toFormBlocState
(#9). - If the
initialValue
ofTextFieldBloc
isnull
is will be an empty String''
. - If the
initialValue
ofBooleanFieldBloc
isnull
it will befalse
. - If the
initialValue
ofMultiSelectFieldBloc
isnull
it will be an empty list[]
.
0.7.0 #
- Updated to
bloc: ^3.0.0
0.6.0 #
- Updated to
bloc: ^1.0.0
bloc.state.listen
->bloc.listen
bloc.currentState
->bloc.state
dispatch
->add
dispose
->close
- Documentation Updates.
Validators
->FieldBlocValidators
ValidatorsError
->FieldBlocValidatorsErrors
- Removed
isRequired
property fromFieldBloc
andFieldBlocState
.
0.5.2 #
- Documentation Updates.
- Fixed a bug in
isValid
property offieldBlocState
. - Prevented to update
FieldBloc.value
if is the same value and is validated. - Improved
requiredTextFieldBloc
validator.
0.5.1 #
- Fixed a bug in
MultiSelectFieldBloc
.
0.5.0 #
- Dependency and Documentation Updates.
- Added
isValidating
property toFieldBlocState
. - Added
asyncValidators
property toFieldBloc
. - Added
asyncValidatorDebounceTime
property toFieldBloc
. - Added
addAsyncValidators
method toFieldBloc
. - Added
updateAsyncValidators
method toFieldBloc
. - Added
addError
method toFieldBloc
. - Added
subscribeToFieldBlocs
method toFieldBloc
.
0.4.1 #
- Documentation Updates.
0.4.0 #
- Documentation Updates.
- Added Tests.
- Added
autoValidate
property toFormBloc
. - Added
InputFieldBloc<Value>
. - Removed
FileFieldBloc
, now you can useInputFieldBloc<File>
. - Added
MultiSelectFieldBloc<Value>
. - Added
error
property toFieldBlocState
. - Added
canShowError
property toFieldBlocState
. - Added
canShowProgress
property toFieldBlocState
. - Added
suggestions
property toFieldBlocState
. - Added
isRequired
property toFieldBlocState
. - Changes
TextFieldBloc<Error>
toTextFieldBloc
. - Added
valueToInt
property toTextFieldBlocState
. - Added
valueToDouble
property toTextFieldBlocState
. - Added
FormBlocDelegate
.
0.3.1 #
- Added
isCanceling
property toFormBlocSubmitting
.
0.3.0 #
- Dependency and Documentation Updates.
- Added
submissionProgress
property toFormBlocState
. - Added
canSubmit
property toFormBlocState
. - Added
FormBlocSubmissionFailed
state toFormBloc
. - Added
FormBlocSubmissionCancelled
state toFormBloc
. - Added
cancelSubmission
event toFormBloc
. - Added
updateState
event toFormBloc
. - Added
onCancelSubmission
method toFormBloc
. - Added
FileFieldBloc
.
0.2.0 #
- Documentation Updates
0.1.0 #
- Initial Version of the library.