@umituz/react-native-design-system 4.25.4 → 4.25.6

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.25.4",
3
+ "version": "4.25.6",
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",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./src/index.ts",
@@ -75,9 +75,9 @@ export async function downloadFileWithProgress(
75
75
  }
76
76
 
77
77
  const totalBytes = parseInt(response.headers.get("content-length") || "0", 10);
78
- if (!response.body) return { ...(await downloadFile(url, destUri)), fromCache: false };
78
+ if (!(response as any).body) return { ...(await downloadFile(url, destUri)), fromCache: false };
79
79
 
80
- const reader = response.body.getReader();
80
+ const reader = (response as any).body.getReader();
81
81
  const chunks: Uint8Array[] = [];
82
82
  let received = 0;
83
83
 
@@ -5,6 +5,8 @@
5
5
 
6
6
  import { File, Paths } from "expo-file-system";
7
7
 
8
+ declare function atob(data: string): string;
9
+
8
10
  /**
9
11
  * Extract raw base64 from data URI
10
12
  */
@@ -5,6 +5,8 @@
5
5
 
6
6
  import { File as ExpoFile, Paths } from "expo-file-system/next";
7
7
 
8
+ declare function atob(data: string): string;
9
+
8
10
  interface FileWithType {
9
11
  readonly type: string;
10
12
  }
@@ -101,7 +101,7 @@ export async function retryWithBackoff<T>(
101
101
  }
102
102
 
103
103
  // Wait before retrying
104
- await new Promise((resolve) => setTimeout(resolve, delay));
104
+ await new Promise<void>((resolve) => setTimeout(() => resolve(), delay));
105
105
  }
106
106
  }
107
107
 
@@ -60,8 +60,8 @@ export class DesignSystemError extends Error {
60
60
  this.retryable = metadata?.retryable ?? false;
61
61
 
62
62
  // Maintains proper stack trace for where our error was thrown (only available on V8)
63
- if (Error.captureStackTrace) {
64
- Error.captureStackTrace(this, DesignSystemError);
63
+ if (typeof (Error as any).captureStackTrace === 'function') {
64
+ (Error as any).captureStackTrace(this, DesignSystemError);
65
65
  }
66
66
  }
67
67
 
@@ -100,8 +100,8 @@ class Logger {
100
100
  * Use for performance measurements
101
101
  */
102
102
  time(label: string): void {
103
- if (this.isDev && console.time) {
104
- console.time(label);
103
+ if (this.isDev && (console as any).time) {
104
+ (console as any).time(label);
105
105
  }
106
106
  }
107
107
 
@@ -109,8 +109,8 @@ class Logger {
109
109
  * End time measurement - only in development
110
110
  */
111
111
  timeEnd(label: string): void {
112
- if (this.isDev && console.timeEnd) {
113
- console.timeEnd(label);
112
+ if (this.isDev && (console as any).timeEnd) {
113
+ (console as any).timeEnd(label);
114
114
  }
115
115
  }
116
116
 
@@ -119,8 +119,8 @@ class Logger {
119
119
  * Use for assertions
120
120
  */
121
121
  assert(condition: boolean, ...args: unknown[]): void {
122
- if (this.isDev && console.assert) {
123
- console.assert(condition, ...args);
122
+ if (this.isDev && (console as any).assert) {
123
+ (console as any).assert(condition, ...args);
124
124
  }
125
125
  }
126
126