File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -462,6 +462,8 @@ import { LocationMessage } from 'react-chat-elements'
462462 data= {{
463463 latitude: ' 37.773972' ,
464464 longitude: ' -122.431297' ,
465+ // staticURL: '<optional>',
466+ // mapURL: '<optional>'
465467 }}/ >
466468```
467469
Original file line number Diff line number Diff line change 11{
22 "name" : " react-chat-elements" ,
3- "version" : " 10.4.3 " ,
3+ "version" : " 10.5.0 " ,
44 "description" : " Reactjs chat components" ,
55 "author" : " Avare Kodcu <abdurrahmaneker58@gmail.com>" ,
66 "main" : " dist/main.js" ,
Original file line number Diff line number Diff line change @@ -34,19 +34,21 @@ export class LocationMessage extends Component {
3434 }
3535
3636 render ( ) {
37+ const data = this . props . data || { } ;
38+
3739 return (
3840 < div className = 'rce-container-lmsg' >
3941 < a
4042 onClick = { this . props . onOpen }
4143 target = { this . props . target }
42- href = { this . props . href || this . props . src || this . buildURL ( MAP_URL ) }
44+ href = { this . props . href || this . props . src || this . buildURL ( data . mapURL || MAP_URL ) }
4345 className = { this . className ( ) } >
4446 < img
4547 onError = { this . props . onError }
4648 className = 'rce-mbox-location-img'
4749 src = {
4850 this . props . src ||
49- this . buildURL ( STATIC_URL )
51+ this . buildURL ( data . staticURL || STATIC_URL )
5052 } />
5153 </ a >
5254 {
You can’t perform that action at this time.
0 commit comments