Releases: wix/react-native-ui-lib
5.22.1
5.22.0
What's New?
Check out our Colors.loadSchemes
API for dark mode support, you can read more about how to use it here
https://wix.github.io/react-native-ui-lib/foundation/colors
🎁 Features
• Support dark mode using Colors.loadSchemes
method. (#1147)
• Support onCollapseChanged
& onCollapseWillChanged
props for StackAggregator component (#1210)
• Add notes in our docs for component that has dependency on an optional dependency (#1220)
• Support passing containerStyle
to Modal.TopBar component (#1222)
• Colors - add transparent
. (#1234)
• Update prop-value-shape-deprecation
lint rule to support props path (#1227)
🔧 Fixes
• Fix Badge's size default prop and make it optional (#1212)
• Picker - fix not responding to external value change when renderPicker is used (without useNativePicker) (#1211)
• Fix broken UI for Galaxy S20 in expandableSection screen (#1230)
• Fix TS issues (#1215)
• Fix floatingButton duration prop (#1228)
• Carousel - replace children.length
with Reacts children count helper. (#1219)
• Fixing docs extends links (#1237)
⚙️ Maintenance & Infra
• Big refactor in our eslint rules - Support more import\require types (for instance importing *), handling renamed components, improve fix logic. (#1193)
• Begin transition to reanimated v2 in our components, at the moment our components should work on both versions. (#1224)
• Migrate our demo project to reanimatedv2 (#1223)
5.21.0
🚀 What's New
Our peer dependencies are now optional as long you don't use specific components.
What does it mean?
For instance, when using the Card component with enableBlur prop on it uses @react-native-community/blur package
Till now, this package was mandatory even when not using the Card component at all.
With a recent feature in react native metro packager, we can now optionally require dependencies only when they are really needed.
(This exclude two dependencies: react-native-reanimated
and react-native-gesture-handler
)
🎁 Features
• Add vertical mode to Carousel component (horizontal prop) (#1175)
• Support passing Animate.ValueXY to attach to Carousel's onScroll event (#1207)
• Support passing custom element to LoaderScreen
• Card's enableBlur is won't crash the app if missing @react-native-community/blur dependency (#1179)
• Peer dependencies (except for reanimated and gesture-handler) will not be mandatory unless using specific components (#1198)
🔧 Fixes
• TabController - Android with RTL - fix scroll to and Fader (#1178)
• TabController.TabBar - fix items not being updated (#1204)
• Avoid passing overlayContent to Card.Section's Image when not needed (#1187)
• Catch undefined StatusBarManager (#1189)
• FloatingButton - change gradient overlay (and change screen) (#1203)
• Fix bold typography for Android (#1200)
• Mobile responsive fixes for our docs site (#1174)
• Expo App fixes and improvements (#1166)
• Fix missing props in components docs (#1206)
• Update docs for Incubator.TextField link to example code so it opens the correct url and doesn't 404. (#1190)
• Fix missing docs info and remove irrelevant components (#1195)
• Fix logic for undocumented groups (docs) (#1167)
⚙️ Maintenance & Infra
• no-direct-import eslint rule - adding applyAutofix
flag to control autofix option (#1183)
• Remove usage of animatable in LoadingScreen (#1152)
• ImageScreen - Adding demo for Image's 'errorSource' prop. (#1173)
• Set new lint rule for deprecation of prop value shape (#1094)
• Button - refactor into smaller files (#1168)
• DialogDismissibleView - refactor to function (#1170)
• Migrate from @react-native-community/picker to @react-native-picker/picker (#1063)
5.20.0
🎁 Features
• We updated our docs site with new design and an amazing landing page! (#1091)
• DateTimePicker - adding 'headerStyle' prop to adjust iOS dialog header style. (#1117)
• Image - Adding 'errorSource' prop for image source in case of an error. (#1116)
• Support passing customElement
to Badge component. (#1153)
• Incubator.TextField now supports onChangeValidity
callback for when field valid state has changed. (#1121)
• Wizard.Step - add circleBackgroundColor
prop
• TabController - Change and refactor centerSelected
logic (#1103)
• Added Shadows presets: Shadows.sh10
, Shadows.sh20
, Shadows.sh30
(#1157)
• Introduce new useDidUpdate hook, that will skip update on initial value. (#1119)
• Support passing custom renderInput
to DateTimePicker (#1127)
• Update our default primary color to Colors.violet30 (#1135)
🔧 Fixes
• Fix various broken example screen links in our docs (#1146) (#1154)
• Dialog - fix swiping to dismiss does not trigger onDialogDismissed (#1093)
• Fixed ChipsInput backspace tag removal issue on Android. (#1151)
• Fix issue with FeatureHighlight component not using useNativeDriver flag (#1136)
• useScrollToItem hook - add offsetType to statics + fix dynamic focusing when there's inner/outer spacing (#1144)
• Fix ChipsInput
prop typings (#1139)
• RadioGroup - add typing for testID prop (#1143)
• Fix accessibility typings to Avatar
component (#1155)
• Fix our typography-deprecation
eslint rule from catching non truthy props (#1137)
• Add support for responsive layout for mobile in our docs site (#1164)
⚙️ Maintenance & Infra
• CustomKeyboardView - remove unsafe methods (#1160)
• SettingsScreen - rename componentWillMount to UNSAFE (#1118)
• CardsScreen - fix backgrounds and remove obsolete examples (#1124)
• Deprecate usage of react-native-animatable
in our Hint component with our own implementation (#1125)
• Remove dependency of react-native-animatable
in our FloatingButton component (#1134)
5.19.0
🎁 Features
• Support rendering badge with icon and label (#1081)
• Added containerStyle
prop to RadioButton to allow passing different styles to the container and the button (#1092)
• Incubator.TextField now supports a "default" UI preset (#1111)
• Introduce new useDidUpdate hook, that will skip update on initial value. (#1112)
• TabController - move to typescript (#1079)
• ScrollBar - migrate to typescript. (#1078)
• Fix RTL for TabController.TabBar horizontal fader effects (#1098)
🔧 Fixes
• Fix Avatar's label alignment (#1082)
• Fix Toast icon prop type to accepts both number and object. (#1086)
• Update @types/react-native to version 63.4 and fix relevant typing issues (#1100)
💡 Deprecations & Migrations
• Fix CardSection and StateScreen imageSource deprecation (#1115)
⚙️ Maintenance & Infra
• Fix icon size in the badges example screen (#1104)
• TabBar - fix refactor bugs (#1106)
• Upgraded the expo sdk in the demo app to v40 from v36
• TabBar - Refactor. (#1076)
5.18.0
🎁 Features
• Added optional boolean outline
prop (#1067)
• Support ErrorBoundary in asBaseComponent (#1041)
• Add testID prop to Drawer & FloatingButton (#1073)
🔧 Fixes
• Fix issue with Picker.Item
ignores renderItem
prop (#1054)
• Fix issue for Android on rn63 - when passing null as tintColor to an Image, the image is not displayed (#1055)
• Fix TS issue in chip component by using Partial typings. (#1047)
• Fix issue with missing selected indicator in Picker items (#1065)
• Fixed getLabel
property issue on Picker
's multi-select mode. (#1059)
• Drawer - Removing Drawer's manual typings and fixing generated types. Adding 'customValue' prop to pass along from user to component and back on component's events. Declaring missing props. (#1069)
• Fix wheePicker swipe conflicts with dialog panning by disabling the dialog panning (#1071)
• Docs - make some groups (i.e. Incubator) not clickable (not links) since they have no docs (fixes #1042) (#1064)
⚙️ Maintenance & Infra
• Typings - remove unused typings files. (#1077)
5.17.2
5.17.1
5.17.0
🎁 Features
- Add
dateFormatter
prop to dateTimePicker (#1027) - Introducing
useToggleValue
hook to toggle between any two values with ease! (#1019)
import {Hooks} from 'react-native-ui-lib;
const {useToggleValue} = Hooks;
const YourComponent = () => {
const [value, toggle, setValue] = useToggleValue(initialValue) // will use booleans
const [value, toggle, setValue] = useToggleValue(initialValue, alternateValue) // will toggle between initial and alternate value
}
🔧 Fixes
- Dialog - RN63 broke Modal's onDismiss method, this fixes our API (#1026)
- Fix issue with modifiers support based on context (#1035)
- DateTimePicker - turn to a controlled component (changing value in runtime will take effect). (#989)
- Fix Checkbox alignment bug (#1039)
- Fix FloatingButton visibility bug when visible is initialized to false (#1021)
- Fix typings for FloatingButton props (#1032)
- Fire onLoad event for AnimatedImage (#1033)
💡 Deprecations & Migrations
- Picker API migration
- From now on pass value as a primitive (string/number) instead of an object
- Picker.Item should accept both value and label props separately (instead of only value prop that contains the value and label together)
- CardImage, CardSection, StateScreen - Adding props deprecation warnings. (#1023)
- Fix issue with missing component in our docs site (Fix #1022) (#1024)
- Migration - Name change - ComponentPropTypes to ComponentProps (e.b ButtonPropTypes changed to ButtonProps) (#1030)
- Add a migrate prop to allow migrating manually to the new Picker API (#1048)
⚙️ Maintenance & Infra