react-native-my-uploader-android 1.0.21 → 1.0.23

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/src/types.ts CHANGED
@@ -1,48 +1,26 @@
1
- // Dosya: src/types.ts
2
-
3
- /**
4
- * Native modülden dönen tek bir dosyanın yapısını tanımlar.
5
- */
6
- export interface FileInfo {
7
- fileName: string;
8
- fileSize: number; // in bytes
9
- fileType: string | null;
10
- fileUri: string;
11
- base64: string;
12
- }
13
-
14
- /**
15
- * `pickFile` fonksiyonuna gönderilebilecek tüm opsiyonları tanımlar.
16
- */
17
- export interface DocumentPickerOptions {
18
- /**
19
- * Birden fazla dosya seçimine izin ver.
20
- * @default false
21
- */
22
- multipleFiles?: boolean;
23
-
24
- /**
25
- * Filtrelenecek dosya tipleri (MIME types).
26
- * @default ['* / *'] (tüm dosyalar)
27
- * @example ['image/jpeg', 'application/pdf']
28
- */
29
- fileTypes?: string[];
30
-
31
- /**
32
- * MB cinsinden maksimum dosya boyutu.
33
- * @default 0 (limitsiz)
34
- */
35
- maxSize?: number;
36
-
37
- /**
38
- * Seçilebilecek maksimum dosya sayısı. `multipleFiles: true` olmalıdır.
39
- * Belirtilmezse ve `multipleFiles: true` ise varsayılan olarak 3'tür.
40
- * @default 0 (limitsiz, ama varsayılan mantığı uygulanır)
41
- */
42
- maxFiles?: number;
43
-
44
- /**
45
- * Zaten seçilmiş olduğu için tekrar seçilmesi engellenecek dosyaların URI listesi.
46
- */
47
- excludedUris?: string[];
1
+ import type { StyleProp, TextStyle, ViewStyle } from 'react-native';
2
+
3
+ export interface FileInfo {
4
+ fileName: string;
5
+ fileSize: number; // in bytes
6
+ fileType: string | null;
7
+ fileUri: string;
8
+ base64: string;
9
+ }
10
+
11
+ export interface DocumentPickerOptions {
12
+ multipleFiles?: boolean;
13
+ fileTypes?: string[];
14
+ maxSize?: number;
15
+ maxFiles?: number;
16
+ excludedUris?: string[];
17
+ }
18
+ export interface MyUploaderProps extends DocumentPickerOptions {
19
+ // Geri bildirim (callback) fonksiyonları
20
+ onSelect: (files: FileInfo[]) => void;
21
+ onError?: (error: Error) => void;
22
+ buttonPlaceHolder?: string;
23
+ ButtonStyle?: StyleProp<ViewStyle>;
24
+ ButtonTextStyle?: StyleProp<TextStyle>;
25
+ disabled?: boolean;
48
26
  }