@umituz/react-native-design-system 4.26.5 → 4.26.7

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": "4.26.5",
3
+ "version": "4.26.7",
4
4
  "description": "Universal design system for React Native apps - Consolidated package with atoms, molecules, organisms, theme, typography, responsive, safe area, exception, infinite scroll, UUID, image, timezone, offline, onboarding, and loading utilities - TanStack persistence and expo-image-manipulator now lazy loaded",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./dist/index.d.ts",
@@ -5,6 +5,12 @@ import { AtomicText, AtomicIcon } from '../atoms';
5
5
  import { ListItemProps } from './listitem/types';
6
6
  import { getListItemStyles } from './listitem/styles/listItemStyles';
7
7
 
8
+ // SVG paths for common icons (work without external icon library)
9
+ const ICON_PATHS: Record<string, string> = {
10
+ 'globe': "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z",
11
+ 'chevron-forward': "M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z",
12
+ };
13
+
8
14
  export type { ListItemProps };
9
15
 
10
16
  export const ListItem: React.FC<ListItemProps> = ({
@@ -31,11 +37,12 @@ export const ListItem: React.FC<ListItemProps> = ({
31
37
  {...accessibilityProps}
32
38
  >
33
39
  {leftIcon && (
34
- <AtomicIcon
35
- name={leftIcon}
36
- color={disabled ? 'surfaceVariant' : 'primary'}
37
- size="md"
38
- style={listItemStyles.iconContainer}
40
+ <AtomicIcon
41
+ svgPath={ICON_PATHS[leftIcon] || undefined}
42
+ name={!ICON_PATHS[leftIcon] ? leftIcon : undefined}
43
+ color={disabled ? 'surfaceVariant' : 'primary'}
44
+ size="md"
45
+ style={listItemStyles.iconContainer}
39
46
  />
40
47
  )}
41
48
  <View style={listItemStyles.content}>
@@ -43,11 +50,12 @@ export const ListItem: React.FC<ListItemProps> = ({
43
50
  {subtitle && <AtomicText type="bodySmall" color="surfaceVariant" numberOfLines={2} style={listItemStyles.subtitle}>{subtitle}</AtomicText>}
44
51
  </View>
45
52
  {rightIcon && onPress && (
46
- <AtomicIcon
47
- name={rightIcon}
48
- color="surfaceVariant"
49
- size="sm"
50
- style={{ marginLeft: tokens.spacing.md }}
53
+ <AtomicIcon
54
+ svgPath={ICON_PATHS[rightIcon] || undefined}
55
+ name={!ICON_PATHS[rightIcon] ? rightIcon : undefined}
56
+ color="surfaceVariant"
57
+ size="sm"
58
+ style={{ marginLeft: tokens.spacing.md }}
51
59
  />
52
60
  )}
53
61
  </Component>