File tree Expand file tree Collapse file tree 13 files changed +138
-95
lines changed Expand file tree Collapse file tree 13 files changed +138
-95
lines changed Original file line number Diff line number Diff line change @@ -12,11 +12,17 @@ const InputBox = styled.TextInput`
1212export class AutoCompleteInput extends React . PureComponent {
1313 static propTypes = {
1414 value : PropTypes . string ,
15+ /** @see See [suggestions context](https://getstream.github.io/stream-chat-react-native/#suggestionscontext) */
1516 openSuggestions : PropTypes . func ,
17+ /** @see See [suggestions context](https://getstream.github.io/stream-chat-react-native/#suggestionscontext) */
1618 closeSuggestions : PropTypes . func ,
19+ /** @see See [suggestions context](https://getstream.github.io/stream-chat-react-native/#suggestionscontext) */
1720 updateSuggestions : PropTypes . func ,
1821 triggerSettings : PropTypes . object ,
1922 setInputBoxRef : PropTypes . func ,
23+ /**
24+ * @param text string
25+ */
2026 onChange : PropTypes . func ,
2127 /**
2228 * Additional props for underlying TextInput component. These props will be forwarded as it is to TextInput component.
Original file line number Diff line number Diff line change @@ -27,3 +27,5 @@ export const CloseButton = themed(
2727 }
2828 } ,
2929) ;
30+
31+ CloseButton . propTypes = { } ;
Original file line number Diff line number Diff line change @@ -201,9 +201,6 @@ function mimeTypeToIcon(mimeType) {
201201 return iconDOC ;
202202}
203203
204- /**
205- * @example ./examples/FileIcon.md
206- */
207204export class FileIcon extends React . Component {
208205 render ( ) {
209206 const { mimeType, size } = this . props ;
Original file line number Diff line number Diff line change @@ -53,6 +53,11 @@ const ImageContainer = styled.TouchableOpacity`
5353 length !== 3 ? theme . message . gallery . size : theme . message . gallery . halfSize } ;
5454 ${ ( { theme } ) => theme . message . gallery . imageContainer . css }
5555` ;
56+ /**
57+ * UI component for card in attachments.
58+ *
59+ * @example ./docs/Gallery.md
60+ */
5661
5762export const Gallery = withMessageContentContext (
5863 themed (
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11``` js
22const images = [
3- { image_url: ' https://placehold.it/300x200 ' },
4- { image_url: ' https://placehold.it/300x200 ' },
5- { image_url: ' https://placehold.it/300x200 ' },
6- { image_url: ' https://placehold.it/300x200 ' },
7- { image_url: ' https://placehold.it/300x200 ' },
8- { image_url: ' https://placehold.it/300x200 ' },
3+ { image_url: ' https://i.picsum.photos/id/1/200/300.jpg ' },
4+ { image_url: ' https://i.picsum.photos/id/2/200/300.jpg ' },
5+ { image_url: ' https://i.picsum.photos/id/3/200/300.jpg ' },
6+ { image_url: ' https://i.picsum.photos/id/4/200/300.jpg ' },
7+ { image_url: ' https://i.picsum.photos/id/5/200/300.jpg ' },
8+ { image_url: ' https://i.picsum.photos/id/6/200/300.jpg ' },
99];
1010< Gallery images= {images} / > ;
1111```
Original file line number Diff line number Diff line change 1+ It accepts all the props accepted by MessageTextContainer component.
2+ In addition it also accepts following props:
3+
4+ - renderText { function } Defaults to [ renderText] ( #rendertext )
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ [ src/utils/renderText.js] ( https://github.com/GetStream/stream-chat-react-native/blob/master/src/utils/renderText.js )
2+
3+ Function that handles markdown and parsing for the text of message.
4+
5+ Internally it uses [ react-native-simple-markdown] ( https://github.com/GetStream/react-native-simple-markdown#styles-1 ) to handle markdown.
6+
7+ It accepts following params:
8+
9+ - message { object } Message object
10+ - style { object } - https://github.com/GetStream/react-native-simple-markdown#styles-1
Original file line number Diff line number Diff line change @@ -13,4 +13,4 @@ export {
1313 withMessageContentContext ,
1414} from './context.js' ;
1515
16- export { MESSAGE_ACTIONS , renderText } from './utils' ;
16+ export * from './utils' ;
You can’t perform that action at this time.
0 commit comments