Skip to content

Commit 520ccd7

Browse files
authored
Add notes for component that has dependency on an optional dependency (#1220)
1 parent edc5614 commit 520ccd7

File tree

4 files changed

+4
-1
lines changed

4 files changed

+4
-1
lines changed

src/components/card/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ type State = {
111111
* @modifiers: margin, padding
112112
* @gif: https://media.giphy.com/media/l0HU9SKWmv0VTOYMM/giphy.gif
113113
* @example: https://github.com/wix/react-native-ui-lib/blob/master/demo/src/screens/componentScreens/CardsScreen.tsx
114+
* @notes: 'enableBlur' prop requires installing the '@react-native-community/blur' native library
114115
*/
115116
class Card extends PureComponent<PropTypes, State> {
116117
static displayName = 'Card';

src/components/connectionStatusBar/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import View from '../view';
1313
* @description: Top bar to show a "no internet" connection status. Note: Run on real device for best results
1414
* @image: https://user-images.githubusercontent.com/33805983/34683190-f3b1904c-f4a9-11e7-9d46-9a340bd35448.png, https://user-images.githubusercontent.com/33805983/34484206-edc6c6e4-efcb-11e7-88b2-cd394c19dd5e.png
1515
* @example: https://github.com/wix/react-native-ui-lib/blob/master/demo/src/screens/componentScreens/ConnectionStatusBarScreen.js
16+
* @notes: The component requires installing the '@react-native-community/netinfo' native library
1617
*/
1718
export default class ConnectionStatusBar extends PureBaseComponent {
1819
static displayName = 'ConnectionStatusBar';

src/components/picker/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ const ItemType = PropTypes.oneOfType([
3131
* @description: Picker Component, support single or multiple selection, blurModel and nativePicker
3232
* @gif: https://media.giphy.com/media/3o751SiuZZiByET2lq/giphy.gif, https://media.giphy.com/media/TgMQnyw5grJIDohzvx/giphy.gif, https://media.giphy.com/media/5hsdmVptBRskZKn787/giphy.gif
3333
* @example: https://github.com/wix/react-native-ui-lib/blob/master/demo/src/screens/componentScreens/PickerScreen.js
34+
* @notes: 'useNativePicker' prop requires installing the '@react-native-picker/picker' native library
3435
*/
3536
class Picker extends Component {
3637
static displayName = 'Picker';

uilib-docs/src/templates/component.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export default class ComponentTemplate extends Component {
2020
};
2121

2222
if (component.docblock) {
23-
const infoRaw = _.split(component.docblock, '@');
23+
const infoRaw = _.split(component.docblock, /(^@|\n@)/);
2424
_.forEach(infoRaw, statement => {
2525
const match = splitPattern.exec(statement);
2626
if (statement && match) {

0 commit comments

Comments
 (0)