@momo-kits/foundation 0.81.8-beta.2 → 0.81.9

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.
@@ -3,11 +3,13 @@ import {ScreenParams} from './types';
3
3
  import Navigation from './Navigation';
4
4
  import {ApplicationContext} from './index';
5
5
  import {GridSystem} from '../Layout';
6
+ import {useHeaderHeight} from '@react-navigation/stack';
6
7
 
7
8
  const StackScreen: React.FC<ScreenParams> = props => {
8
9
  const {screen: Component, options}: ScreenParams = props.route.params;
9
10
  const {theme, showGrid, navigator} = useContext(ApplicationContext);
10
11
  const navigation = new Navigation(props.navigation, theme);
12
+ const heightHeader = useHeaderHeight();
11
13
 
12
14
  const params = {
13
15
  ...props.route.params,
@@ -50,7 +52,7 @@ const StackScreen: React.FC<ScreenParams> = props => {
50
52
 
51
53
  return (
52
54
  <>
53
- <Component {...params} />
55
+ <Component heightHeader={heightHeader} {...params} />
54
56
  {showGrid && <GridSystem />}
55
57
  </>
56
58
  );
package/Input/Input.tsx CHANGED
@@ -35,6 +35,7 @@ const Input = forwardRef(
35
35
  loading,
36
36
  leadingIcon,
37
37
  leadingIconColor,
38
+ fontWeight = 'normal',
38
39
  style,
39
40
  ...props
40
41
  }: InputProps,
@@ -80,6 +81,7 @@ const Input = forwardRef(
80
81
  let textColor = theme.colors.text.default;
81
82
  let placeholderColor = theme.colors.text.hint;
82
83
  let iconTintColor = iconColor;
84
+ const inputTextWeight = fontWeight === 'bold' ? 'Bold' : 'Regular';
83
85
 
84
86
  if (disabled) {
85
87
  textColor = disabledColor;
@@ -122,7 +124,7 @@ const Input = forwardRef(
122
124
  styles.input,
123
125
  {
124
126
  color: textColor,
125
- fontFamily: `${theme.font}-Regular`,
127
+ fontFamily: `${theme.font}-${inputTextWeight}`,
126
128
  },
127
129
  ]}
128
130
  textBreakStrategy="highQuality"
package/Input/index.tsx CHANGED
@@ -76,6 +76,8 @@ export interface InputProps extends TextInputProps {
76
76
  * Optional. Represents the color of the leading icon in the Input component.
77
77
  */
78
78
  leadingIconColor?: string;
79
+
80
+ fontWeight?: 'normal' | 'bold';
79
81
  }
80
82
 
81
83
  type InputPropsWithoutSizeAndIcon = Omit<
package/Layout/Screen.tsx CHANGED
@@ -275,7 +275,6 @@ const Screen = forwardRef(
275
275
  <Component
276
276
  {...scrollViewProps}
277
277
  ref={ref}
278
- heightHeader={heightHeader}
279
278
  showsVerticalScrollIndicator={false}
280
279
  onScroll={handleScroll}
281
280
  style={Styles.flex}>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@momo-kits/foundation",
3
- "version": "0.81.8-beta.2",
3
+ "version": "0.81.9",
4
4
  "description": "React Native Component Kits",
5
5
  "main": "index.ts",
6
6
  "scripts": {