Tags:
- [New Feature]
- [Bug Fix]
- [Breaking Change]
- [Documentation]
- [Internal]
- [Polish]
Note: Gaps between patch versions are faulty/broken releases.
- New Feature
- allow disabling datepicker by passing disabled prop to touchableopacity we can disable the datepicker (@koenpunt)
- Bug fix
- Add proper border color to select.ios when there is an error, fix #342 (@javiercr)
- Bug fix
- fix #301, PR gcanti#329 (@danilvalov)
- Polish
- Solves scroll view issues with text fields in Android, fix #301 (@alvaromb)
- New Feature
- Added
onContentSizeChange
as an option for TextBox (@nemo)
- Added
- New Feature
- Wrap TextInput in a View for More Customizable Styling, e.g. Material Design Style Underlines (@kenleezle)
- New Feature
- Ability to style picker container (@dbonner1987)
- New Feature
- Make
underlineColorAndroid
transparent by default, fix #239 (@adamrainsby)
- Make
- New Feature
- Added support for minDate and maxDate in Android TimePickerAndroid (@alvaromb)
- Breaking Change
- Added collapsable iOS DatePicker (@alvaromb)
- Added collapsable iOS Picker (@alvaromb)
- Bug Fix
_nativeContainerInfo
no longer exists in React v15.2.0, use_hostContainerInfo
instead, fix #195 (@gcanti)
- New Feature
- add support for unions, fix #118 (@gcanti)
- add support for lists, fix #80 (@gcanti)
- Bug Fix
- allow to set a default value in Android date picker template, fix #187
- New Feature
- Add onChange handler to TextInput, fix #168 (@gcanti)
- Breaking Change
- upgrade to
tcomb-validation
^3.0.0 (@gcanti) - React API must be now required from
react
package (@jebschiefer)
- upgrade to
- New Feature
- Updated support for TextInput props for RN>=0.25 (@alvaromb)
- Bug Fix
- Revert to export method from 869dd50 (gcanti#160)
- New Feature
- support hot reload, fix #132 (thanks @justim, @alvaromb)
- add
hidden
option docs (thanks @miqmago)
- Bug Fix
- Textbox component displays extra characters after
getValue()
, fix #142 (thanks @alvaromb)
- Textbox component displays extra characters after
- New Feature
- Set
accessibilityLabel
andaccessibilityLiveRegion
attributes on form controls, fix #137 (thanks @ndarilek)
- Set
- Breaking Change
- required react-native version >= 0.20.0
- New Feature
- add support for Switch (Android), fix #60 (thanks @alvaromb)
- Support for Android date and time pickers, fix #67 (thanks @alvaromb)
- add support for webpack, fix #23
- Documentation
- How to clear form after submit (thanks @shashi-dokania)
- Dynamic forms example: how to change a form based on selection
- Stylesheet guide (docs/STYLESHEETS.md)
- Polish
- add travis CI
- add ISSUE_TEMPLATE.md (new GitHub feature)
- Bug Fix
- v0.16.0 Warning: Form(...): React component classes must extend React.Component, fix #83
- Polish
- Map value to enum, fix #56
-
New Feature
- default templates are now split in standalone files, so you can cherry pick which ones to load
- ability to customize templates, stylesheets and i18n without loading the default ones (improved docs)
- porting of tcomb-form
getValidationErrorMessage
feature
var Age = t.refinement(t.Number, function (n) { return n >= 18; }); // if you define a getValidationErrorMessage function, it will be called on validation errors Age.getValidationErrorMessage = function (value) { return 'bad age ' + value; }; var Schema = t.struct({ age: Age });
-
add support for nested forms, fix #43
- add proper support for struct refinements
- add support for struct label (bootstrap templates)
Example
var Account = t.struct({ email: t.String, profile: t.struct({ name: t.String, surname: t.String }) }); var options = { label: <Text style={{fontSize: 30}}>Account</Text>, fields: { profile: { label: <Text style={{fontSize: 20}}>Profile</Text> } } };
- add support for struct error (bootstrap templates)
-
Experimental
- add support for maybe structs
Example
var Account = t.struct({ email: t.String, profile: t.maybe(t.struct({ name: t.String, surname: t.String })) }); // user enters email: 'aaa', => result { email: 'aaa', profile: null } // user enters email: 'aaa', name: 'bbb' => validation error for surname // user enters email: 'aaa', name: 'bbb', surname: 'ccc' => result { email: 'aaa', profile: { name: 'bbb', surname: 'ccc' } }
-
Breaking Change
-
Upgrade tcomb-validation to v2, fix #68
Do not worry: the migration path should be seamless since the major version bump was caused by dropping the support for bower (i.e. types and combinators are the same). Just notice that the short type alias (
t.Str
,t.Num
, ...) are deprecated in favour of the long ones (t.String
,t.Number
, ...) and thesubtype
combinator has now a more descriptive aliasrefinement
.
-
-
Bug Fix
- amend struct onChange, fix #70
the previous code would lead to bugs regarding error messages when the type is a subtype of a struct, gcanti/tcomb-form#235
-
Internal
- move peer dependencies to dependencies
- New Feature
- Pass in config options to custom template through options, fix #63
- Internal
- support react-native versions greater than 0.9
- Internal
- pin react-native version to 0.9
- New Feature
- Add
required
field to i18n, fix #46
- Add
- Internal
- upgrade to react-native v0.9
- Bug Fix
- the default date for DatePicker is reflected in the UI but not in the
getValue()
API #42
- the default date for DatePicker is reflected in the UI but not in the
- New Feature
- add auto option override for specific field #41
- Internal
- Recommend making peerDependencies more flexible #30
- Internal
- less padding to textboxes, #31
- New Feature
- getComponent API fix #19
- get access to the native input contained in tcomb-form-native's component fix #24
- Breaking Change
- Inputs refactoring, this affects how to build custom inputs #12
- Internal
- Textbox is no more a controlled input #26
- Add eslint
- Internal
- upgrade to react-native v0.5.0 fix #22
- Internal
- upgrade to react-native v0.4.3
- upgrade to tcomb-validation v1.0.4
- Internal
- upgrade to react-native v0.4.0
- Internal
- upgrade to react-native v0.3.4
- added tests
- New Feature
- add path field to contexts in order to provide correct error paths for validations, fix #5
- added a path argument to onChange in order to know what field changed
- added support for transformers (all components)
- Password field type, fix #4
- Bug Fix
- Error with decimal mark in numeric field, fix #7