Releases: kettanaito/react-advanced-form
Releases · kettanaito/react-advanced-form
1.7.0
- Updates the library's dev and save dependencies
Features
- (Internal) Introduces various helper methods to shorten Form methods
- (Internal) Introduces patched state update (#354) to make state operations faster and support concurrent state updates
Bugfixes
- Fixes a bug that resulted into debounced
onChangehandlers to be invoked with the obsolete value (#341) - Fixes a bug that resulted into obsolete validity state on fields with reactive
requiredprop (#344) - Fixes a bug that resulted some fields to unmount if they don't match the predicate of
form.reset()(#347) - Fixes a bug that resulted into some optional empty fields blocking form submit (#350)
- Fixes a bug that resulted into custom
initialValueof a checkbox not being set (#380)
1.6.0
- Decreases final bundle size by 50Kb by tree-shaking Ramda methods with
babel-plugin-ramda
Features
- Adds grouped fields selector in validation schema (#307, docs)
- Adds
touchedproperty to thefieldState(#289) - Supports
assertValueoption oncreateField(docs) - Supports
mapValueoption oncreateField(docs) - Supports
serializeoption oncreateField(#303, docs) - Supports
exactprop forField.Group(#321, docs)
Bugfixes
- Fixes a bug that resulted into name-specific
missingmessage not being set on a field (#306) - Fixes a bug that retained the last state of field's
errorsafter a field becomes valid (#301) - Fixes a bug that resulted into exception being thrown for delegated reactive props subscriptions (#304)
- Fixes
window is not definedexception during server-side rendering (#322) - Fixes a bug that didn't remove conditionally rendered fields from the form's state (#331)
- Fixes a bug that removed fields that don't match a predicate in
Form.clear()(#333) - Fixes a bug that propagated
type: "text"to all fields by default (#335)
1.5.0
Migration
- Please see the guidelines on migrating from 1.4.x to 1.5.x
Package
- Removes
immutablepeer dependency. React is the only peer dependency now.
API
- Supports
initialValuesfor a form (#271) - Supports transformation of serialized
fields(#245) - Supports setting targeted error messages to fields using form reference (#209)
Field.props.rulenow behaves as a reactive prop (#249)- Adds
validatedfield prop intofieldState(#151)
Internals
- Introduces huge architectural rewrite. Field update and validation are now functional compositions.
- Prepared a thorough update of the Official documentation. Browse through new sections that cover the functionality in a more approachable way. Examples, examples everywhere!
1.4.0
API
- Adds
Form.clear()method for clearing the form's fields
Internals
- Makes
fieldUtils.resetField()a high order function that accepts agetNextValuefunction and returns an applicator function that expects afieldProps. Changes utilized for bothresetandclearfunctionality.
1.3.0
API
- Introduces new Reactive props API. To reference and subscribe to another field's props use explicit
getfunction exposed through the method arguments.
Internals
- Removes the usage of
Proxy, thus improving the browser support for IE.
1.2.0
API
- Adds
beforeRegistermethod tocreateFieldoptions. This method allows to apply additional transformations to thefieldPropsimmediately before the registration. It also allows to completely prevent the registration of the field in casefalseis returned. (#233) - Adds
allowMultipleflag tocreateFieldoptions. This flag controls whether the multiple fields with the same name are allowed. (#233) - Allows to reference custom
valuePropNameprops in validation rules resolvers functions. (#238) - Allows to control the field-wide
initialValuein thecreateFieldoptions. (#240)
Bugfixes
- References
valuePropNamein thefieldPropscomposition increateField.Fieldrender method
Internals
- Refines
updateFieldmethod to use pureupdatefunction as a parameter (#182)
1.1.0
API
- Adds support for nested field groups (#223)
Bugfixes
- Fixes broken deep references using
fieldProps(and additional sync rule resolver args, instead offields). Changes the method call influshFieldRefs, usingdispatchto be aligned withform.context.withImmutable - Sets
validon expected Checkbox properly (#213) - Sets
debounceValidatemethod on field record withinField.register()instead ofForm.registerField()to prevent field record diversion (#221)
Internals
- Decreases the bundle size by ~9 Kb
- Uses
regenerator-runtimeinstead ofbabel-polyfill - Adds support for environment-specific builds (#214)
1.0
Stable release that contains aligned API and the list of following features:
- Creating custom fields / third-party fields integration
- Form native callback methods
- Reactive props
- Field grouping
- Multi-level validation logic
- Validation messages with smart fallback algorithm