@onehat/ui 0.2.2 → 0.2.4

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onehat/ui",
3
- "version": "0.2.2",
3
+ "version": "0.2.4",
4
4
  "description": "Base UI for OneHat apps",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
@@ -1,23 +1,22 @@
1
1
  import React from 'react';
2
2
  import {
3
3
  Column,
4
+ Icon,
4
5
  Row,
5
6
  Text,
6
7
  } from 'native-base';
7
- import {
8
- FaTimes,
9
- FaMinus,
10
- FaPlus,
11
- } from 'react-icons/fa';
12
8
  import {
13
9
  HORIZONTAL,
14
10
  VERTICAL,
15
- } from '../../Constants/Directions';
11
+ } from '../../Constants/Directions.js';
16
12
  import {
17
13
  UI_MODE_WEB,
18
14
  UI_MODE_REACT_NATIVE,
19
15
  } from '../../Constants/UiModes.js';
20
16
  import UiConfig from '../../UiConfig.js';
17
+ import Minus from '../Icons/Minus.js';
18
+ import Plus from '../Icons/Plus.js';
19
+ import Xmark from '../Icons/Xmark.js';
21
20
  import styles from '../../Constants/Styles.js';
22
21
  import emptyFn from '../../Functions/emptyFn.js';
23
22
  import IconButton from '../Buttons/IconButton.js';
@@ -43,7 +42,7 @@ export default function Header(props) {
43
42
  collapseBtn = null;
44
43
  if (isClosable) {
45
44
  closeBtn = <IconButton
46
- icon={<FaTimes size={styles.PANEL_HEADER_ICON_SIZE} color={styles.HEADER_ICON_COLOR} />}
45
+ icon={<Icon as={Xmark} size={styles.PANEL_HEADER_ICON_SIZE} color={styles.HEADER_ICON_COLOR} />}
47
46
  onPress={onClose}
48
47
  testID="closeBtn"
49
48
  alignSelf="center"
@@ -52,7 +51,7 @@ export default function Header(props) {
52
51
  }
53
52
  if (isCollapsible) {
54
53
  collapseBtn = <IconButton
55
- icon={isCollapsed ? <FaPlus size={styles.PANEL_HEADER_ICON_SIZE} color={styles.HEADER_ICON_COLOR} /> : <FaMinus size={styles.PANEL_HEADER_ICON_SIZE} color={styles.HEADER_ICON_COLOR} />}
54
+ icon={isCollapsed ? <Icon as={Plus} size={styles.PANEL_HEADER_ICON_SIZE} color={styles.HEADER_ICON_COLOR} /> : <Icon as={Minus} size={styles.PANEL_HEADER_ICON_SIZE} color={styles.HEADER_ICON_COLOR} />}
56
55
  onPress={onToggleCollapse}
57
56
  testID="collapseBtn"
58
57
  alignSelf="center"
@@ -1,4 +1,4 @@
1
- import * as appStyles from '../../Constants/Styles';
1
+ // import * as appStyles from '../../Constants/Styles.js';
2
2
  import _ from 'lodash';
3
3
 
4
4
  const
@@ -82,5 +82,5 @@ const defaults = {
82
82
  TEXT_FONTSIZE: DEFAULT_FONTSIZE,
83
83
  };
84
84
 
85
- export default _.merge(defaults, appStyles);
85
+ export default defaults; //_.merge(defaults, appStyles);
86
86