@shoutem/ui 4.7.0 → 4.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +1 -2
  3. package/components/ActionSheet/ActionSheet.js +6 -6
  4. package/components/DateTimePicker.js +2 -2
  5. package/components/DropDownMenu/DropDownMenu.js +1 -1
  6. package/components/DropDownMenu/DropDownModal.js +2 -2
  7. package/components/EmptyListImage.js +9 -5
  8. package/components/FormGroup.js +0 -1
  9. package/components/GridRow.js +2 -2
  10. package/components/HorizontalPager/HorizontalPager.js +2 -2
  11. package/components/Icon/services/icons.js +0 -2
  12. package/components/Icon/services/index.js +1 -1
  13. package/components/Image.js +1 -1
  14. package/components/ImageBackground.js +1 -1
  15. package/components/ImageGallery/ImageGallery.android.js +1 -0
  16. package/components/ImageGallery/ImageGallery.ios.js +2 -1
  17. package/components/ImageGalleryOverlay.js +1 -1
  18. package/components/ImagePreview.js +2 -2
  19. package/components/InlineDropDownMenu/InlineDropDownMenu.js +24 -27
  20. package/components/InlineDropDownMenu/InlineDropDownMenuItem.js +13 -14
  21. package/components/ListView.js +71 -32
  22. package/components/LoadingIndicator.js +1 -1
  23. package/components/NavigationBar/NavigationBar.js +3 -7
  24. package/components/NavigationBar/NavigationBarAnimations.js +1 -1
  25. package/components/ScrollView/ScrollDriverProvider.js +1 -1
  26. package/components/ScrollView/ScrollView.js +3 -3
  27. package/components/ShareButton.js +1 -1
  28. package/components/Spinner.js +1 -1
  29. package/components/Switch.js +2 -2
  30. package/components/TabMenu/TabMenu.js +2 -2
  31. package/components/TabMenu/TabMenuItem.js +7 -4
  32. package/components/Text.js +2 -2
  33. package/components/TextInput.js +2 -2
  34. package/components/Tile.js +1 -1
  35. package/components/Touchable.js +2 -2
  36. package/components/TouchableNativeFeedback.js +2 -2
  37. package/components/TouchableOpacity.js +1 -1
  38. package/components/Video/Video.js +1 -1
  39. package/components/Video/VideoSourceReader.js +2 -1
  40. package/components/View.js +1 -1
  41. package/components/YearRangePicker/YearRangePicker.js +2 -2
  42. package/components/YearRangePicker/YearRangePickerButton.js +2 -2
  43. package/components/YearRangePicker/YearRangePickerModal.js +11 -11
  44. package/examples/components/Cards.js +1 -1
  45. package/examples/components/DropDownMenus.js +8 -8
  46. package/examples/components/Examples.js +1 -1
  47. package/examples/components/FormComponents.js +1 -1
  48. package/examples/components/Headers.js +1 -1
  49. package/examples/components/NavigationBars.js +4 -4
  50. package/examples/components/Rows.js +1 -1
  51. package/examples/components/Stage.js +1 -1
  52. package/examples/components/Tiles.js +1 -1
  53. package/examples/components/Typography.js +1 -1
  54. package/examples/components/Videos.js +3 -3
  55. package/helpers/device-selector.js +3 -3
  56. package/html/Html.js +3 -3
  57. package/html/components/Image.js +1 -1
  58. package/html/components/SimpleHtml.js +9 -9
  59. package/html/elements/A.js +3 -3
  60. package/html/elements/Block.js +2 -2
  61. package/html/elements/Img.js +1 -1
  62. package/html/elements/Inline.js +5 -5
  63. package/html/elements/Text.js +2 -2
  64. package/html/elements/list/Ol.js +1 -1
  65. package/html/elements/list/Ul.js +1 -1
  66. package/html/elements/list/index.js +4 -4
  67. package/html/index.js +33 -33
  68. package/html/services/ElementRegistry.js +1 -1
  69. package/html/services/HtmlParser.js +2 -1
  70. package/package.json +18 -9
  71. package/scripts/add-native-deps.js +0 -1
  72. package/theme.js +7 -7
@@ -1,8 +1,8 @@
1
1
  import React, { PureComponent } from 'react';
2
- import PropTypes from 'prop-types';
2
+ import { LayoutAnimation, ScrollView } from 'react-native';
3
3
  import autoBindReact from 'auto-bind/react';
4
4
  import _ from 'lodash';
5
- import { ScrollView, LayoutAnimation } from 'react-native';
5
+ import PropTypes from 'prop-types';
6
6
  import { connectStyle } from '@shoutem/theme';
7
7
  import { optionShape } from './const';
8
8
  import { TabMenuItem } from './TabMenuItem';
@@ -1,12 +1,12 @@
1
1
  import React, { PureComponent } from 'react';
2
2
  import { LayoutAnimation } from 'react-native';
3
- import PropTypes from 'prop-types';
4
3
  import autoBindReact from 'auto-bind/react';
5
4
  import _ from 'lodash';
5
+ import PropTypes from 'prop-types';
6
6
  import { connectStyle } from '@shoutem/theme';
7
7
  import { Text } from '../Text';
8
- import { View } from '../View';
9
8
  import { TouchableOpacity } from '../TouchableOpacity';
9
+ import { View } from '../View';
10
10
  import { optionShape } from './const';
11
11
 
12
12
  class TabMenuItem extends PureComponent {
@@ -33,8 +33,11 @@ class TabMenuItem extends PureComponent {
33
33
  onItemPressed(item);
34
34
  }
35
35
 
36
- handleLayout({ nativeEvent: { layout: { width } } }) {
37
-
36
+ handleLayout({
37
+ nativeEvent: {
38
+ layout: { width },
39
+ },
40
+ }) {
38
41
  LayoutAnimation.easeInEaseOut();
39
42
  this.setState({ baseWidth: width });
40
43
  }
@@ -1,7 +1,7 @@
1
1
  import React, { PureComponent } from 'react';
2
2
  import { Text as RNText } from 'react-native';
3
- import { connectStyle } from '@shoutem/theme';
4
3
  import { connectAnimation } from '@shoutem/animation';
4
+ import { connectStyle } from '@shoutem/theme';
5
5
 
6
6
  class Text extends PureComponent {
7
7
  render() {
@@ -20,4 +20,4 @@ const Title = connectStyle('shoutem.ui.Title')(AnimatedText);
20
20
  const Subtitle = connectStyle('shoutem.ui.Subtitle')(AnimatedText);
21
21
  const Caption = connectStyle('shoutem.ui.Caption')(AnimatedText);
22
22
 
23
- export { StyledText as Text, Heading, Title, Subtitle, Caption };
23
+ export { Caption, Heading, Subtitle, StyledText as Text, Title };
@@ -1,7 +1,7 @@
1
1
  import React, { PureComponent } from 'react';
2
+ import { TextInput as RNTextInput } from 'react-native';
2
3
  import autoBindReact from 'auto-bind/react';
3
4
  import PropTypes from 'prop-types';
4
- import { TextInput as RNTextInput } from 'react-native';
5
5
  import { connectAnimation, Wiggle } from '@shoutem/animation';
6
6
  import { connectStyle } from '@shoutem/theme';
7
7
  import { Caption } from './Text';
@@ -63,7 +63,7 @@ class TextInput extends PureComponent {
63
63
  style={{
64
64
  ...otherStyle,
65
65
  ...(hasBorder ? withBorder : withoutBorder),
66
- ...(!!errorMessage ? errorBorderColor : {}),
66
+ ...(errorMessage ? errorBorderColor : {}),
67
67
  }}
68
68
  />
69
69
  </Wiggle>
@@ -1,6 +1,6 @@
1
1
  import { View } from 'react-native';
2
- import { connectStyle } from '@shoutem/theme';
3
2
  import { connectAnimation } from '@shoutem/animation';
3
+ import { connectStyle } from '@shoutem/theme';
4
4
 
5
5
  const AnimatedTile = connectAnimation(View);
6
6
  const Tile = connectStyle('shoutem.ui.Tile')(AnimatedTile);
@@ -1,6 +1,6 @@
1
1
  import React, { PureComponent } from 'react';
2
- import PropTypes from 'prop-types';
3
2
  import { Platform } from 'react-native';
3
+ import PropTypes from 'prop-types';
4
4
  import { connectStyle } from '@shoutem/theme';
5
5
  import { TouchableNativeFeedback } from './TouchableNativeFeedback';
6
6
  import { TouchableOpacity } from './TouchableOpacity';
@@ -21,7 +21,7 @@ class Touchable extends PureComponent {
21
21
  };
22
22
 
23
23
  render() {
24
- const props = this.props;
24
+ const { props } = this;
25
25
  const style = { ...props.style };
26
26
  delete style.touchableOpacity;
27
27
  delete style.touchableNativeFeedback;
@@ -1,6 +1,6 @@
1
1
  import React, { PureComponent } from 'react';
2
- import PropTypes from 'prop-types';
3
2
  import { TouchableNativeFeedback as RNTouchableNativeFeedback } from 'react-native';
3
+ import PropTypes from 'prop-types';
4
4
  import { connectStyle } from '@shoutem/theme';
5
5
 
6
6
  class TouchableNativeFeedback extends PureComponent {
@@ -13,7 +13,7 @@ class TouchableNativeFeedback extends PureComponent {
13
13
  };
14
14
 
15
15
  render() {
16
- const props = this.props;
16
+ const { props } = this;
17
17
  // Remove the props that are not valid
18
18
  // style keys.
19
19
  const style = {
@@ -4,7 +4,7 @@ import { connectStyle } from '@shoutem/theme';
4
4
 
5
5
  class TouchableOpacity extends PureComponent {
6
6
  render() {
7
- const props = this.props;
7
+ const { props } = this;
8
8
 
9
9
  // The activeOpacity is not a valid RN style
10
10
  // property, so we have to unset it here.
@@ -1,7 +1,7 @@
1
1
  import React, { PureComponent } from 'react';
2
- import PropTypes from 'prop-types';
3
2
  import { View } from 'react-native';
4
3
  import { WebView } from 'react-native-webview';
4
+ import PropTypes from 'prop-types';
5
5
  import { connectAnimation } from '@shoutem/animation';
6
6
  import { connectStyle } from '@shoutem/theme';
7
7
  import VideoSourceReader from './VideoSourceReader';
@@ -58,7 +58,8 @@ export default class VideoSourceReader {
58
58
  getYouTubeVideoId(this.source),
59
59
  this.playerParams,
60
60
  );
61
- } else if (this.isVimeo) {
61
+ }
62
+ if (this.isVimeo) {
62
63
  return getVimeoEmbedUrl(getVimeoVideoId(this.source));
63
64
  }
64
65
 
@@ -1,6 +1,6 @@
1
1
  import React, { PureComponent } from 'react';
2
- import PropTypes from 'prop-types';
3
2
  import { View as RNView, ViewPropTypes } from 'react-native';
3
+ import PropTypes from 'prop-types';
4
4
  import { connectAnimation } from '@shoutem/animation';
5
5
  import { connectStyle } from '@shoutem/theme';
6
6
  import { LinearGradient } from './LinearGradient';
@@ -1,7 +1,7 @@
1
1
  import React, { PureComponent } from 'react';
2
- import PropTypes from 'prop-types';
3
- import _ from 'lodash';
4
2
  import autoBindReact from 'auto-bind/react';
3
+ import _ from 'lodash';
4
+ import PropTypes from 'prop-types';
5
5
  import { connectStyle } from '@shoutem/theme';
6
6
  import { View } from '../View';
7
7
  import YearPickerButton from './YearRangePickerButton';
@@ -1,11 +1,11 @@
1
1
  import React, { PureComponent } from 'react';
2
2
  import { Animated } from 'react-native';
3
- import PropTypes from 'prop-types';
4
3
  import autoBindReact from 'auto-bind/react';
4
+ import PropTypes from 'prop-types';
5
5
  import { connectStyle } from '@shoutem/theme';
6
- import { TouchableOpacity } from '../TouchableOpacity';
7
6
  import { Icon } from '../Icon';
8
7
  import { Text } from '../Text';
8
+ import { TouchableOpacity } from '../TouchableOpacity';
9
9
 
10
10
  const AnimatedIcon = Animated.createAnimatedComponent(Icon);
11
11
 
@@ -1,15 +1,15 @@
1
1
  import React, { PureComponent } from 'react';
2
2
  import { LayoutAnimation, Platform } from 'react-native';
3
- import PropTypes from 'prop-types';
4
- import _ from 'lodash';
5
3
  import Modal from 'react-native-modal';
6
4
  import autoBindReact from 'auto-bind/react';
5
+ import _ from 'lodash';
6
+ import PropTypes from 'prop-types';
7
7
  import { connectStyle } from '@shoutem/theme';
8
- import { View } from '../View';
9
- import { Text } from '../Text';
10
- import { Icon } from '../Icon';
11
8
  import { Button } from '../Button';
9
+ import { Icon } from '../Icon';
10
+ import { Text } from '../Text';
12
11
  import { TouchableOpacity } from '../TouchableOpacity';
12
+ import { View } from '../View';
13
13
 
14
14
  const NUMBER_OF_ROWS = 4;
15
15
  const YEARS_IN_ROW = 5;
@@ -160,13 +160,13 @@ class YearRangePickerModal extends PureComponent {
160
160
 
161
161
  const newYears = addToEnd
162
162
  ? [
163
- ...selectedYears,
164
- ..._.times(yearsToAdd, index => _.last(selectedYears) + index + 1),
165
- ]
163
+ ...selectedYears,
164
+ ..._.times(yearsToAdd, index => _.last(selectedYears) + index + 1),
165
+ ]
166
166
  : [
167
- ...selectedYears,
168
- ..._.times(yearsToAdd, index => _.head(selectedYears) - index + -1),
169
- ];
167
+ ...selectedYears,
168
+ ..._.times(yearsToAdd, index => _.head(selectedYears) - index + -1),
169
+ ];
170
170
  const sortedYears = _.sortBy(newYears, item => item);
171
171
 
172
172
  this.setState({ selectedYears: sortedYears });
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
- import { Card } from '../../components/Card';
3
2
  import { Button } from '../../components/Button';
3
+ import { Card } from '../../components/Card';
4
4
  import { Icon } from '../../components/Icon';
5
5
  import { Image } from '../../components/Image';
6
6
  import { Caption, Subtitle } from '../../components/Text';
@@ -44,8 +44,8 @@ export class DropDownMenus extends PureComponent {
44
44
  onOptionSelected={option =>
45
45
  this.setState({ selectedOption: option })
46
46
  }
47
- titleProperty={'name'}
48
- valueProperty={'id'}
47
+ titleProperty="name"
48
+ valueProperty="id"
49
49
  />
50
50
  </Stage>
51
51
  <Stage title="Dropdown (horizontal)">
@@ -56,8 +56,8 @@ export class DropDownMenus extends PureComponent {
56
56
  onOptionSelected={option =>
57
57
  this.setState({ selectedOption: option })
58
58
  }
59
- titleProperty={'name'}
60
- valueProperty={'id'}
59
+ titleProperty="name"
60
+ valueProperty="id"
61
61
  />
62
62
  </Stage>
63
63
  <Stage title="Dropdown (large)">
@@ -68,8 +68,8 @@ export class DropDownMenus extends PureComponent {
68
68
  onOptionSelected={option =>
69
69
  this.setState({ selectedOption: option })
70
70
  }
71
- titleProperty={'name'}
72
- valueProperty={'id'}
71
+ titleProperty="name"
72
+ valueProperty="id"
73
73
  />
74
74
  </Stage>
75
75
  <Stage title="Dropdown (inside a form group)">
@@ -82,8 +82,8 @@ export class DropDownMenus extends PureComponent {
82
82
  onOptionSelected={option =>
83
83
  this.setState({ selectedOptionForFormGroupDropdown: option })
84
84
  }
85
- titleProperty={'name'}
86
- valueProperty={'id'}
85
+ titleProperty="name"
86
+ valueProperty="id"
87
87
  />
88
88
  </FormGroup>
89
89
  </Stage>
@@ -1,6 +1,6 @@
1
1
  import React, { PureComponent } from 'react';
2
- import { DropDownMenu } from '../../components/DropDownMenu';
3
2
  import { Divider } from '../../components/Divider';
3
+ import { DropDownMenu } from '../../components/DropDownMenu';
4
4
  import { Screen } from '../../components/Screen';
5
5
  import { ScrollView } from '../../components/ScrollView';
6
6
  import { Buttons } from './Buttons';
@@ -1,6 +1,6 @@
1
1
  import React, { PureComponent } from 'react';
2
- import { Switch } from '../../components/Switch';
3
2
  import { FormGroup } from '../../components/FormGroup';
3
+ import { Switch } from '../../components/Switch';
4
4
  import { Caption } from '../../components/Text';
5
5
  import { TextInput } from '../../components/TextInput';
6
6
  import { View } from '../../components/View';
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- import { Text, Caption, Subtitle, Title, Heading } from '../../components/Text';
3
2
  import { Button } from '../../components/Button';
4
3
  import { Icon } from '../../components/Icon';
5
4
  import { Overlay } from '../../components/Overlay';
5
+ import { Caption, Heading, Subtitle, Text, Title } from '../../components/Text';
6
6
  import { Tile } from '../../components/Tile';
7
7
  import { View } from '../../components/View';
8
8
  import { Stage } from './Stage';
@@ -1,19 +1,19 @@
1
1
  import React, { PureComponent } from 'react';
2
- import PropTypes from 'prop-types';
3
2
  import { Dimensions } from 'react-native';
4
- import { Device } from '../../helpers/device-selector';
3
+ import PropTypes from 'prop-types';
5
4
  import { Button } from '../../components/Button';
6
5
  import { DropDownMenu } from '../../components/DropDownMenu';
7
6
  import { Icon } from '../../components/Icon';
8
7
  import { ImageBackground } from '../../components/ImageBackground';
9
8
  import { NavigationBar } from '../../components/NavigationBar';
10
- import { Text, Title, Heading } from '../../components/Text';
9
+ import { Heading, Text, Title } from '../../components/Text';
11
10
  import { View } from '../../components/View';
12
11
  import {
13
- NAVIGATION_HEADER_HEIGHT,
14
12
  IPHONE_X_NOTCH_PADDING,
15
13
  IPHONE_XR_NOTCH_PADDING,
14
+ NAVIGATION_HEADER_HEIGHT,
16
15
  } from '../../const';
16
+ import { Device } from '../../helpers/device-selector';
17
17
  import { Stage } from './Stage';
18
18
 
19
19
  const window = Dimensions.get('window');
@@ -3,7 +3,7 @@ import { Button } from '../../components/Button';
3
3
  import { Icon } from '../../components/Icon';
4
4
  import { Image } from '../../components/Image';
5
5
  import { Row } from '../../components/Row';
6
- import { Text, Caption, Subtitle } from '../../components/Text';
6
+ import { Caption, Subtitle, Text } from '../../components/Text';
7
7
  import { View } from '../../components/View';
8
8
  import { Stage } from './Stage';
9
9
 
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
+ import { Text, View } from 'react-native';
2
3
  import PropTypes from 'prop-types';
3
- import { View, Text } from 'react-native';
4
4
 
5
5
  function Stage({ title, children }) {
6
6
  // eslint-disable-next-line no-use-before-define
@@ -4,7 +4,7 @@ import { Icon } from '../../components/Icon';
4
4
  import { Image } from '../../components/Image';
5
5
  import { ImageBackground } from '../../components/ImageBackground';
6
6
  import { Overlay } from '../../components/Overlay';
7
- import { Text, Caption, Subtitle, Title, Heading } from '../../components/Text';
7
+ import { Caption, Heading, Subtitle, Text, Title } from '../../components/Text';
8
8
  import { Tile } from '../../components/Tile';
9
9
  import { View } from '../../components/View';
10
10
  import { Stage } from './Stage';
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { Text, Caption, Subtitle, Title, Heading } from '../../components/Text';
2
+ import { Caption, Heading, Subtitle, Text, Title } from '../../components/Text';
3
3
  import { View } from '../../components/View';
4
4
  import { Stage } from './Stage';
5
5
 
@@ -6,21 +6,21 @@ import { Stage } from './Stage';
6
6
  export function Videos() {
7
7
  return (
8
8
  <View styleName="vertical collapsed">
9
- <Stage title={'YouTube video'}>
9
+ <Stage title="YouTube video">
10
10
  <Video
11
11
  source={{ uri: 'https://www.youtube.com/embed/2zuisMXzyaI' }}
12
12
  width={320}
13
13
  height={180}
14
14
  />
15
15
  </Stage>
16
- <Stage title={'Vimeo video'}>
16
+ <Stage title="Vimeo video">
17
17
  <Video
18
18
  source={{ uri: 'https://vimeo.com/182267614' }}
19
19
  width={320}
20
20
  height={180}
21
21
  />
22
22
  </Stage>
23
- <Stage title={'Stream video'}>
23
+ <Stage title="Stream video">
24
24
  <Video
25
25
  source={{
26
26
  uri:
@@ -1,11 +1,11 @@
1
- import { Platform, Dimensions } from 'react-native';
1
+ import { Dimensions, Platform } from 'react-native';
2
2
  import { hasNotch } from 'react-native-device-info';
3
3
  import _ from 'lodash';
4
4
  import {
5
- IPHONE_X_LONG_SIDE,
6
- IPHONE_XR_LONG_SIDE,
7
5
  IPHONE_12_LONG_SIDE,
8
6
  IPHONE_12_MAX_LONG_SIDE,
7
+ IPHONE_X_LONG_SIDE,
8
+ IPHONE_XR_LONG_SIDE,
9
9
  } from '../const';
10
10
 
11
11
  const { OS, isPad, isTVOS } = Platform;
package/html/Html.js CHANGED
@@ -5,14 +5,14 @@ import PropTypes from 'prop-types';
5
5
  import { connectStyle } from '@shoutem/theme';
6
6
  import { Spinner } from '../components/Spinner';
7
7
  import { View } from '../components/View';
8
- import { parseHtml } from './services/HtmlParser';
9
8
  import {
10
- registerElement,
9
+ Display,
11
10
  getElement,
12
11
  getElementDisplay,
13
12
  getElementProperty,
14
- Display,
13
+ registerElement,
15
14
  } from './services/ElementRegistry';
15
+ import { parseHtml } from './services/HtmlParser';
16
16
 
17
17
  const defaultElementSettings = {
18
18
  display: Display.BLOCK,
@@ -1,8 +1,8 @@
1
1
  import React, { PureComponent } from 'react';
2
+ import { Image as RNImage } from 'react-native';
2
3
  import autoBindReact from 'auto-bind/react';
3
4
  import _ from 'lodash';
4
5
  import PropTypes from 'prop-types';
5
- import { Image as RNImage } from 'react-native';
6
6
  import { Image } from '../../components/Image';
7
7
  import { ImageBackground } from '../../components/ImageBackground';
8
8
  import { Lightbox } from '../../components/Lightbox';
@@ -1,26 +1,26 @@
1
- import { Dimensions, Linking } from 'react-native';
2
- import autoBindReact from 'auto-bind/react';
3
- import _ from 'lodash';
4
- import PropTypes from 'prop-types';
5
1
  import React, { PureComponent } from 'react';
2
+ import { Dimensions, Linking } from 'react-native';
6
3
  import Html from 'react-native-render-html';
4
+ import { iframe } from 'react-native-render-html/src/HTMLRenderers';
7
5
  import {
8
- cssStringToObject,
9
6
  cssObjectToString,
7
+ cssStringToObject,
10
8
  } from 'react-native-render-html/src/HTMLStyles';
11
- import WebView from 'react-native-webview';
12
9
  import {
13
- makeTableRenderer,
14
10
  alterNode as tableAlterNode,
15
11
  cssRulesFromSpecs,
16
12
  defaultTableStylesSpecs,
17
13
  IGNORED_TAGS,
14
+ makeTableRenderer,
18
15
  } from 'react-native-render-html-table-bridge';
19
- import { iframe } from 'react-native-render-html/src/HTMLRenderers';
16
+ import WebView from 'react-native-webview';
20
17
  import YoutubePlayer from 'react-native-youtube-iframe';
18
+ import autoBindReact from 'auto-bind/react';
19
+ import _ from 'lodash';
20
+ import PropTypes from 'prop-types';
21
21
  import { connectStyle } from '@shoutem/theme';
22
- import { View } from '../../components/View';
23
22
  import { Text } from '../../components/Text';
23
+ import { View } from '../../components/View';
24
24
  import getEmptyObjectKeys from '../services/getEmptyObjectKeys';
25
25
  import isValidVideoFormat from '../services/isValidVideoFormat';
26
26
  import Image from './Image';
@@ -1,11 +1,11 @@
1
1
  import React, { PureComponent } from 'react';
2
+ import { Linking } from 'react-native';
2
3
  import autoBindReact from 'auto-bind/react';
3
4
  import _ from 'lodash';
4
5
  import PropTypes from 'prop-types';
5
- import { Linking } from 'react-native';
6
6
  import { connectStyle } from '@shoutem/theme';
7
- import { isImg } from '../elements/Img';
8
- import { ElementPropTypes, combineMappers, mapElementProps } from '../Html';
7
+ import { combineMappers, ElementPropTypes, mapElementProps } from '../Html';
8
+ import { isImg } from './Img';
9
9
  import { Inline } from './Inline';
10
10
 
11
11
  class A extends PureComponent {
@@ -1,10 +1,10 @@
1
1
  import React from 'react';
2
2
  import _ from 'lodash';
3
3
  import {
4
- ElementPropTypes,
5
4
  combineMappers,
6
- mapElementProps,
5
+ ElementPropTypes,
7
6
  isBlockElement,
7
+ mapElementProps,
8
8
  } from '../Html';
9
9
  import { Inline } from './Inline';
10
10
 
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import _ from 'lodash';
3
3
  import Image from '../components/Image';
4
- import { ElementPropTypes, combineMappers, mapElementProps } from '../Html';
4
+ import { combineMappers, ElementPropTypes, mapElementProps } from '../Html';
5
5
 
6
6
  export function isImg(element) {
7
7
  return _.get(element, 'tag') === 'img';
@@ -4,17 +4,17 @@ import PropTypes from 'prop-types';
4
4
  import { Text } from '../../components/Text';
5
5
  import { TouchableOpacity } from '../../components/TouchableOpacity';
6
6
  import { View } from '../../components/View';
7
- import { Display } from '../services/ElementRegistry';
8
7
  import {
9
- isBlockElement,
10
- hasBlockElement,
11
- ElementPropTypes,
12
8
  combineMappers,
9
+ ElementPropTypes,
10
+ hasBlockElement,
11
+ isBlockElement,
13
12
  mapElementProps,
14
13
  renderChildElements,
15
14
  } from '../Html';
15
+ import { Display } from '../services/ElementRegistry';
16
16
  import { isImg } from './Img';
17
- import { removeWhiteSpace, isText } from './Text';
17
+ import { isText, removeWhiteSpace } from './Text';
18
18
 
19
19
  export const blockDisplayIfAnyChildIsBlock = function(element) {
20
20
  return hasBlockElement(element.childElements)
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
+ import { Text } from 'react-native';
2
3
  import { AllHtmlEntities as Entities } from 'html-entities';
3
4
  import _ from 'lodash';
4
- import { Text } from 'react-native';
5
- import { ElementPropTypes, combineMappers, mapElementProps } from '../Html';
5
+ import { combineMappers, ElementPropTypes, mapElementProps } from '../Html';
6
6
 
7
7
  const html = new Entities();
8
8
 
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import { View } from '../../../components/View';
4
- import { ElementPropTypes, combineMappers, mapElementProps } from '../../Html';
4
+ import { combineMappers, ElementPropTypes, mapElementProps } from '../../Html';
5
5
  import pickLiChildElements from './helpers/pickLiChildElements';
6
6
  import renderItems from './helpers/renderItems';
7
7
 
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import { View } from '../../../components/View';
4
- import { ElementPropTypes, combineMappers, mapElementProps } from '../../Html';
4
+ import { combineMappers, ElementPropTypes, mapElementProps } from '../../Html';
5
5
  import pickLiChildElements from './helpers/pickLiChildElements';
6
6
  import renderItems from './helpers/renderItems';
7
7
 
@@ -1,7 +1,7 @@
1
- import Ul from './Ul';
2
- import Li from './Li';
3
- import Ol from './Ol';
4
1
  import Bullet from './prefix/Bullet';
5
2
  import Number from './prefix/Number';
3
+ import Li from './Li';
4
+ import Ol from './Ol';
5
+ import Ul from './Ul';
6
6
 
7
- export { Ul, Ol, Li, Bullet, Number };
7
+ export { Bullet, Li, Number, Ol, Ul };