@umituz/react-native-design-system 2.5.23 → 2.5.25

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.23",
3
+ "version": "2.5.25",
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",
@@ -8,6 +8,7 @@
8
8
  import React from "react";
9
9
  import { View, StyleSheet, StyleProp, ViewStyle } from "react-native";
10
10
  import { Ionicons } from "@expo/vector-icons";
11
+ import Svg, { Path } from "react-native-svg";
11
12
  import { useAppDesignTokens } from '../theme';
12
13
  import {
13
14
  type IconSize as BaseIconSize
@@ -41,7 +42,7 @@ export type IconName = string;
41
42
 
42
43
  export interface AtomicIconProps {
43
44
  /** Icon name (Ionicons) */
44
- name: IconName;
45
+ name?: IconName;
45
46
  /** Semantic size preset */
46
47
  size?: IconSize;
47
48
  /** Custom size in pixels (overrides size) */
@@ -50,6 +51,10 @@ export interface AtomicIconProps {
50
51
  color?: IconColor;
51
52
  /** Custom color (overrides color) */
52
53
  customColor?: string;
54
+ /** Custom SVG path for generic icons */
55
+ svgPath?: string;
56
+ /** ViewBox for custom SVG (default: 0 0 24 24) */
57
+ svgViewBox?: string;
53
58
  /** Add circular background */
54
59
  withBackground?: boolean;
55
60
  /** Background color */
@@ -102,6 +107,8 @@ export const AtomicIcon: React.FC<AtomicIconProps> = React.memo(({
102
107
  customColor,
103
108
  withBackground = false,
104
109
  backgroundColor,
110
+ svgPath,
111
+ svgViewBox = "0 0 24 24",
105
112
  accessibilityLabel,
106
113
  testID,
107
114
  style,
@@ -123,10 +130,21 @@ export const AtomicIcon: React.FC<AtomicIconProps> = React.memo(({
123
130
  : tokens.colors.textPrimary;
124
131
 
125
132
  // Validate icon - use fallback silently if invalid
126
- const isValidIcon = name in Ionicons.glyphMap;
127
- const iconName = isValidIcon ? name : FALLBACK_ICON;
128
-
129
- const iconElement = (
133
+ const iconName = name && name in Ionicons.glyphMap ? name : FALLBACK_ICON;
134
+
135
+ const iconElement = svgPath ? (
136
+ <Svg
137
+ viewBox={svgViewBox}
138
+ width={sizeInPixels}
139
+ height={sizeInPixels}
140
+ key="custom-svg-icon"
141
+ >
142
+ <Path
143
+ d={svgPath}
144
+ fill={iconColor}
145
+ />
146
+ </Svg>
147
+ ) : (
130
148
  <Ionicons
131
149
  name={iconName as keyof typeof Ionicons.glyphMap}
132
150
  size={sizeInPixels}
@@ -40,11 +40,6 @@ export const CelebrationModalContent: React.FC<CelebrationModalContentProps> = (
40
40
  {
41
41
  backgroundColor: tokens.colors.surface,
42
42
  borderColor: tokens.colors.surfaceVariant,
43
- shadowColor: tokens.colors.onSurface,
44
- shadowOffset: { width: 0, height: 8 },
45
- shadowOpacity: 0.15,
46
- shadowRadius: 24,
47
- elevation: 8,
48
43
  },
49
44
  ]}
50
45
  >
@@ -25,7 +25,6 @@ export const FabButton: React.FC<FabButtonProps> = ({
25
25
  {
26
26
  backgroundColor: tokens.colors.primary,
27
27
  borderColor: tokens.colors.onPrimary,
28
- shadowColor: tokens.colors.onSurface,
29
28
  },
30
29
  style
31
30
  ]}>