@umituz/react-native-design-system 2.5.2 → 2.5.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": "@umituz/react-native-design-system",
3
- "version": "2.5.2",
3
+ "version": "2.5.4",
4
4
  "description": "Universal design system for React Native apps - Consolidated package with atoms, molecules, organisms, theme, typography, responsive and safe area utilities",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./src/index.ts",
@@ -10,7 +10,6 @@ import { View, StyleSheet, StyleProp, ViewStyle } from "react-native";
10
10
  import { Ionicons } from "@expo/vector-icons";
11
11
  import { useAppDesignTokens } from '../theme';
12
12
  import {
13
- getIconSize,
14
13
  type IconSize as BaseIconSize
15
14
  } from "./AtomicIcon.types";
16
15
 
@@ -18,7 +18,7 @@ export const ListItem: React.FC<ListItemProps> = ({
18
18
  <Component style={[listItemStyles.container, disabled ? listItemStyles.disabled : undefined, style]} onPress={onPress} disabled={disabled} activeOpacity={0.7}>
19
19
  {leftIcon && (
20
20
  <View style={listItemStyles.iconContainer}>
21
- <AtomicIcon name={leftIcon} color={disabled ? 'surfaceVariant' : 'primary'} />
21
+ <AtomicIcon name={leftIcon} color={disabled ? 'surfaceVariant' : 'primary'} size="md" />
22
22
  </View>
23
23
  )}
24
24
  <View style={listItemStyles.content}>
@@ -27,7 +27,7 @@ export const ListItem: React.FC<ListItemProps> = ({
27
27
  </View>
28
28
  {rightIcon && onPress && (
29
29
  <View style={listItemStyles.iconContainer}>
30
- <AtomicIcon name={rightIcon} color="surfaceVariant" />
30
+ <AtomicIcon name={rightIcon} color="surfaceVariant" size="sm" />
31
31
  </View>
32
32
  )}
33
33
  </Component>
@@ -1,4 +1,4 @@
1
- import React, { forwardRef } from 'react';
1
+ import React, { forwardRef, type Ref } from 'react';
2
2
  import {
3
3
  View,
4
4
  TextInput,
@@ -10,7 +10,9 @@ import { useAppDesignTokens } from '../../theme';
10
10
  import { AtomicIcon } from '../../atoms/AtomicIcon';
11
11
  import type { SearchBarProps } from './types';
12
12
 
13
- export const SearchBar = forwardRef<React.ComponentRef<typeof TextInput>, SearchBarProps>(({
13
+ type TextInputRef = React.ComponentRef<typeof TextInput>;
14
+
15
+ export const SearchBar = forwardRef<TextInputRef, SearchBarProps>(({
14
16
  value,
15
17
  onChangeText,
16
18
  onSubmit,
@@ -41,6 +43,9 @@ export const SearchBar = forwardRef<React.ComponentRef<typeof TextInput>, Search
41
43
  {
42
44
  backgroundColor: tokens.colors.surfaceVariant,
43
45
  borderColor: tokens.colors.border,
46
+ height: 48 * tokens.spacingMultiplier,
47
+ paddingHorizontal: 12 * tokens.spacingMultiplier,
48
+ borderRadius: 24 * tokens.spacingMultiplier,
44
49
  },
45
50
  containerStyle,
46
51
  ]}
@@ -72,7 +77,7 @@ export const SearchBar = forwardRef<React.ComponentRef<typeof TextInput>, Search
72
77
  styles.input,
73
78
  {
74
79
  color: tokens.colors.textPrimary,
75
- fontSize: 16, // Body medium usually
80
+ fontSize: tokens.typography.bodyMedium.responsiveFontSize,
76
81
  },
77
82
  inputStyle,
78
83
  ]}
@@ -115,9 +120,9 @@ const styles = StyleSheet.create({
115
120
  container: {
116
121
  flexDirection: 'row',
117
122
  alignItems: 'center',
118
- paddingHorizontal: 12,
119
- height: 48,
120
- borderRadius: 24, // Pill shape
123
+ paddingHorizontal: 12, // Will be scaled by parent if needed, or we rely on token usage elsewhere
124
+ height: 48, // Should be dynamic ideally, but keeping simple for now
125
+ borderRadius: 24,
121
126
  borderWidth: 1,
122
127
  },
123
128
  iconContainer: {
@@ -126,7 +131,7 @@ const styles = StyleSheet.create({
126
131
  input: {
127
132
  flex: 1,
128
133
  height: '100%',
129
- paddingVertical: 0, // Reset default padding
134
+ paddingVertical: 0,
130
135
  },
131
136
  rightActions: {
132
137
  flexDirection: 'row',