@aether-baas/react-native 3.1.6 → 3.2.0
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/dist/index.d.ts +76 -9
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +124 -13
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,58 @@
|
|
|
1
|
-
import { type ReactNode } from 'react';
|
|
2
|
-
import { type ClientConfig, type StorageAdapter, type TenantUser, type AuthChangeEvent } from '@aether-baas/core';
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
import { PlataformaClient, type ClientConfig, type StorageAdapter, type TenantUser, type AuthChangeEvent } from '@aether-baas/core';
|
|
3
|
+
/**
|
|
4
|
+
* Retorna o client Aether global.
|
|
5
|
+
*
|
|
6
|
+
* IMPORTANTE: Só funciona após o AetherProvider ser montado.
|
|
7
|
+
* Use dentro de callbacks, event handlers, ou stores Zustand.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```typescript
|
|
11
|
+
* // Em um store Zustand
|
|
12
|
+
* import { getAetherClient } from '@aether-baas/react-native';
|
|
13
|
+
*
|
|
14
|
+
* const useStore = create((set) => ({
|
|
15
|
+
* fetchData: async () => {
|
|
16
|
+
* const aether = getAetherClient();
|
|
17
|
+
* const data = await aether.db.collection('items').list();
|
|
18
|
+
* set({ data });
|
|
19
|
+
* }
|
|
20
|
+
* }));
|
|
21
|
+
* ```
|
|
22
|
+
*
|
|
23
|
+
* @throws Se chamado antes do AetherProvider ser montado
|
|
24
|
+
*/
|
|
25
|
+
export declare function getAetherClient(): PlataformaClient;
|
|
26
|
+
/**
|
|
27
|
+
* Verifica se o client global está disponível.
|
|
28
|
+
* Útil para verificar antes de chamar getAetherClient().
|
|
29
|
+
*/
|
|
30
|
+
export declare function isAetherClientReady(): boolean;
|
|
31
|
+
/**
|
|
32
|
+
* Retorna o módulo de Database com token.
|
|
33
|
+
* Atalho para getAetherClient().db
|
|
34
|
+
*/
|
|
35
|
+
export declare function getDb(): import("@aether-baas/core").DatabaseModule;
|
|
36
|
+
/**
|
|
37
|
+
* Retorna o módulo de Auth com token.
|
|
38
|
+
* Atalho para getAetherClient().tenantAuth
|
|
39
|
+
*/
|
|
40
|
+
export declare function getAuth(): import("@aether-baas/core").TenantAuthModule;
|
|
41
|
+
/**
|
|
42
|
+
* Retorna o módulo de Storage com token.
|
|
43
|
+
* Atalho para getAetherClient().storage
|
|
44
|
+
*/
|
|
45
|
+
export declare function getStorage(): import("@aether-baas/core").StorageModule;
|
|
46
|
+
/**
|
|
47
|
+
* Retorna o módulo de Functions com token.
|
|
48
|
+
* Atalho para getAetherClient().functions
|
|
49
|
+
*/
|
|
50
|
+
export declare function getFunctions(): import("@aether-baas/core").FunctionsModule;
|
|
51
|
+
/**
|
|
52
|
+
* Retorna o módulo de AI com token.
|
|
53
|
+
* Atalho para getAetherClient().ai
|
|
54
|
+
*/
|
|
55
|
+
export declare function getAI(): import("@aether-baas/core").AIModule;
|
|
3
56
|
/**
|
|
4
57
|
* Adapter para @react-native-async-storage/async-storage.
|
|
5
58
|
*/
|
|
@@ -19,7 +72,7 @@ export declare function createSecureStoreAdapter(secureStore: {
|
|
|
19
72
|
deleteItemAsync: (key: string) => Promise<void>;
|
|
20
73
|
}): StorageAdapter;
|
|
21
74
|
/**
|
|
22
|
-
* Adapter para react-native-mmkv (storage
|
|
75
|
+
* Adapter para react-native-mmkv (storage de alta performance).
|
|
23
76
|
*/
|
|
24
77
|
export declare function createMMKVAdapter(mmkv: {
|
|
25
78
|
getString: (key: string) => string | undefined;
|
|
@@ -34,23 +87,37 @@ export interface AetherProviderProps {
|
|
|
34
87
|
secureStorage?: StorageAdapter;
|
|
35
88
|
children: ReactNode;
|
|
36
89
|
onAuthStateChange?: (event: AuthChangeEvent, user: TenantUser | null) => void;
|
|
90
|
+
/**
|
|
91
|
+
* Se true, mostra loading enquanto restaura sessão.
|
|
92
|
+
* Se false ou função, renderiza children imediatamente.
|
|
93
|
+
* Se função, renderiza o retorno como loading indicator.
|
|
94
|
+
*/
|
|
95
|
+
loadingComponent?: ReactNode | (() => ReactNode);
|
|
37
96
|
}
|
|
38
97
|
/**
|
|
39
98
|
* Provider do Aether para React Native.
|
|
40
99
|
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
100
|
+
* FEATURES:
|
|
101
|
+
* - Aguarda restauração assíncrona do token antes de renderizar
|
|
102
|
+
* - Define client global automaticamente (getAetherClient())
|
|
103
|
+
* - Suporta SecureStore para tokens sensíveis
|
|
43
104
|
*
|
|
44
105
|
* @example
|
|
45
106
|
* ```tsx
|
|
46
107
|
* import AsyncStorage from '@react-native-async-storage/async-storage';
|
|
47
|
-
* import
|
|
108
|
+
* import * as SecureStore from 'expo-secure-store';
|
|
109
|
+
* import {
|
|
110
|
+
* AetherProvider,
|
|
111
|
+
* createAsyncStorageAdapter,
|
|
112
|
+
* createSecureStoreAdapter
|
|
113
|
+
* } from '@aether-baas/react-native';
|
|
48
114
|
*
|
|
49
115
|
* export default function App() {
|
|
50
116
|
* return (
|
|
51
117
|
* <AetherProvider
|
|
52
118
|
* config={{ baseUrl: '...', apiKey: '...' }}
|
|
53
119
|
* storage={createAsyncStorageAdapter(AsyncStorage)}
|
|
120
|
+
* secureStorage={createSecureStoreAdapter(SecureStore)}
|
|
54
121
|
* >
|
|
55
122
|
* <Navigation />
|
|
56
123
|
* </AetherProvider>
|
|
@@ -58,8 +125,8 @@ export interface AetherProviderProps {
|
|
|
58
125
|
* }
|
|
59
126
|
* ```
|
|
60
127
|
*/
|
|
61
|
-
export declare function AetherProvider({ config, storage, secureStorage, children, onAuthStateChange, }: AetherProviderProps): import("react/jsx-runtime").JSX.Element | null;
|
|
128
|
+
export declare function AetherProvider({ config, storage, secureStorage, children, onAuthStateChange, loadingComponent, }: AetherProviderProps): string | number | boolean | Iterable<React.ReactNode> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
62
129
|
export { useAetherContext, useAetherClient, useAuth, useCollection, useDocument, useStorage, useFunctions, useFunction, useAI, useAIAsk, useAISearch, AuthGuard, GuestGuard, RoleGuard, ShowIfAuthenticated, ShowIfGuest, ShowIfRole, } from '@aether-baas/react';
|
|
63
|
-
export type { StorageAdapter } from '@aether-baas/core';
|
|
64
|
-
export declare const VERSION = "3.
|
|
130
|
+
export type { StorageAdapter, ClientConfig, TenantUser, AuthChangeEvent, PlataformaClient, } from '@aether-baas/core';
|
|
131
|
+
export declare const VERSION = "3.2.0";
|
|
65
132
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":"AAWA,OAAO,KAAK,EAAE,EAAsB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAClE,OAAO,EACL,gBAAgB,EAChB,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,eAAe,EACrB,MAAM,mBAAmB,CAAC;AAe3B;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,eAAe,IAAI,gBAAgB,CASlD;AAED;;;GAGG;AACH,wBAAgB,mBAAmB,IAAI,OAAO,CAE7C;AAED;;;GAGG;AACH,wBAAgB,KAAK,+CAEpB;AAED;;;GAGG;AACH,wBAAgB,OAAO,iDAEtB;AAED;;;GAGG;AACH,wBAAgB,UAAU,8CAEzB;AAED;;;GAGG;AACH,wBAAgB,YAAY,gDAE3B;AAED;;;GAGG;AACH,wBAAgB,KAAK,yCAEpB;AAMD;;GAEG;AACH,wBAAgB,yBAAyB,CAAC,YAAY,EAAE;IACtD,OAAO,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC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,SAAS,CAAC;IACpB,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,eAAe,EAAE,IAAI,EAAE,UAAU,GAAG,IAAI,KAAK,IAAI,CAAC;IAC9E;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,SAAS,GAAG,CAAC,MAAM,SAAS,CAAC,CAAC;CAClD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,wBAAgB,cAAc,CAAC,EAC7B,MAAM,EACN,OAAO,EACP,aAAa,EACb,QAAQ,EACR,iBAAiB,EACjB,gBAAgB,GACjB,EAAE,mBAAmB,sHAsErB;AAMD,OAAO,EACL,gBAAgB,EAChB,eAAe,EACf,OAAO,EACP,aAAa,EACb,WAAW,EACX,UAAU,EACV,YAAY,EACZ,WAAW,EACX,KAAK,EACL,QAAQ,EACR,WAAW,EACX,SAAS,EACT,UAAU,EACV,SAAS,EACT,mBAAmB,EACnB,WAAW,EACX,UAAU,GACX,MAAM,oBAAoB,CAAC;AAG5B,YAAY,EACV,cAAc,EACd,YAAY,EACZ,UAAU,EACV,eAAe,EACf,gBAAgB,GACjB,MAAM,mBAAmB,CAAC;AAG3B,eAAO,MAAM,OAAO,UAAU,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -3,11 +3,96 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
3
3
|
// @aether/react-native
|
|
4
4
|
// =============================================================================
|
|
5
5
|
// SDK para React Native com adapters específicos para mobile.
|
|
6
|
+
//
|
|
7
|
+
// ARQUITETURA PRODUCTION-READY:
|
|
8
|
+
// - AetherProvider: Gerencia client, storage e auth state
|
|
9
|
+
// - getAetherClient(): Acesso global ao client (para stores Zustand, etc)
|
|
10
|
+
// - Hooks: useAuth, useCollection, etc (para componentes React)
|
|
6
11
|
// =============================================================================
|
|
7
|
-
import React, { useMemo } from 'react';
|
|
12
|
+
import React, { useMemo, useEffect } from 'react';
|
|
8
13
|
import { PlataformaClient, } from '@aether-baas/core';
|
|
9
14
|
import { AetherProvider as BaseAetherProvider, } from '@aether-baas/react';
|
|
10
15
|
// =============================================================================
|
|
16
|
+
// SINGLETON GLOBAL (para acesso fora de componentes React)
|
|
17
|
+
// =============================================================================
|
|
18
|
+
/**
|
|
19
|
+
* Referência global ao client do AetherProvider.
|
|
20
|
+
* Permite que stores Zustand e outros módulos não-React acessem o client.
|
|
21
|
+
*/
|
|
22
|
+
let _globalClient = null;
|
|
23
|
+
/**
|
|
24
|
+
* Retorna o client Aether global.
|
|
25
|
+
*
|
|
26
|
+
* IMPORTANTE: Só funciona após o AetherProvider ser montado.
|
|
27
|
+
* Use dentro de callbacks, event handlers, ou stores Zustand.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```typescript
|
|
31
|
+
* // Em um store Zustand
|
|
32
|
+
* import { getAetherClient } from '@aether-baas/react-native';
|
|
33
|
+
*
|
|
34
|
+
* const useStore = create((set) => ({
|
|
35
|
+
* fetchData: async () => {
|
|
36
|
+
* const aether = getAetherClient();
|
|
37
|
+
* const data = await aether.db.collection('items').list();
|
|
38
|
+
* set({ data });
|
|
39
|
+
* }
|
|
40
|
+
* }));
|
|
41
|
+
* ```
|
|
42
|
+
*
|
|
43
|
+
* @throws Se chamado antes do AetherProvider ser montado
|
|
44
|
+
*/
|
|
45
|
+
export function getAetherClient() {
|
|
46
|
+
if (!_globalClient) {
|
|
47
|
+
throw new Error('[Aether] Client não inicializado. ' +
|
|
48
|
+
'Certifique-se de que o AetherProvider está montado antes de chamar getAetherClient(). ' +
|
|
49
|
+
'Se estiver usando em um store Zustand, chame dentro das actions, não no nível do módulo.');
|
|
50
|
+
}
|
|
51
|
+
return _globalClient;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Verifica se o client global está disponível.
|
|
55
|
+
* Útil para verificar antes de chamar getAetherClient().
|
|
56
|
+
*/
|
|
57
|
+
export function isAetherClientReady() {
|
|
58
|
+
return _globalClient !== null;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Retorna o módulo de Database com token.
|
|
62
|
+
* Atalho para getAetherClient().db
|
|
63
|
+
*/
|
|
64
|
+
export function getDb() {
|
|
65
|
+
return getAetherClient().db;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Retorna o módulo de Auth com token.
|
|
69
|
+
* Atalho para getAetherClient().tenantAuth
|
|
70
|
+
*/
|
|
71
|
+
export function getAuth() {
|
|
72
|
+
return getAetherClient().tenantAuth;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Retorna o módulo de Storage com token.
|
|
76
|
+
* Atalho para getAetherClient().storage
|
|
77
|
+
*/
|
|
78
|
+
export function getStorage() {
|
|
79
|
+
return getAetherClient().storage;
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* Retorna o módulo de Functions com token.
|
|
83
|
+
* Atalho para getAetherClient().functions
|
|
84
|
+
*/
|
|
85
|
+
export function getFunctions() {
|
|
86
|
+
return getAetherClient().functions;
|
|
87
|
+
}
|
|
88
|
+
/**
|
|
89
|
+
* Retorna o módulo de AI com token.
|
|
90
|
+
* Atalho para getAetherClient().ai
|
|
91
|
+
*/
|
|
92
|
+
export function getAI() {
|
|
93
|
+
return getAetherClient().ai;
|
|
94
|
+
}
|
|
95
|
+
// =============================================================================
|
|
11
96
|
// ASYNC STORAGE ADAPTER
|
|
12
97
|
// =============================================================================
|
|
13
98
|
/**
|
|
@@ -38,10 +123,10 @@ export function createSecureStoreAdapter(secureStore) {
|
|
|
38
123
|
};
|
|
39
124
|
}
|
|
40
125
|
// =============================================================================
|
|
41
|
-
// MMKV ADAPTER
|
|
126
|
+
// MMKV ADAPTER (PERFORMANCE)
|
|
42
127
|
// =============================================================================
|
|
43
128
|
/**
|
|
44
|
-
* Adapter para react-native-mmkv (storage
|
|
129
|
+
* Adapter para react-native-mmkv (storage de alta performance).
|
|
45
130
|
*/
|
|
46
131
|
export function createMMKVAdapter(mmkv) {
|
|
47
132
|
return {
|
|
@@ -55,19 +140,27 @@ export function createMMKVAdapter(mmkv) {
|
|
|
55
140
|
/**
|
|
56
141
|
* Provider do Aether para React Native.
|
|
57
142
|
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
143
|
+
* FEATURES:
|
|
144
|
+
* - Aguarda restauração assíncrona do token antes de renderizar
|
|
145
|
+
* - Define client global automaticamente (getAetherClient())
|
|
146
|
+
* - Suporta SecureStore para tokens sensíveis
|
|
60
147
|
*
|
|
61
148
|
* @example
|
|
62
149
|
* ```tsx
|
|
63
150
|
* import AsyncStorage from '@react-native-async-storage/async-storage';
|
|
64
|
-
* import
|
|
151
|
+
* import * as SecureStore from 'expo-secure-store';
|
|
152
|
+
* import {
|
|
153
|
+
* AetherProvider,
|
|
154
|
+
* createAsyncStorageAdapter,
|
|
155
|
+
* createSecureStoreAdapter
|
|
156
|
+
* } from '@aether-baas/react-native';
|
|
65
157
|
*
|
|
66
158
|
* export default function App() {
|
|
67
159
|
* return (
|
|
68
160
|
* <AetherProvider
|
|
69
161
|
* config={{ baseUrl: '...', apiKey: '...' }}
|
|
70
162
|
* storage={createAsyncStorageAdapter(AsyncStorage)}
|
|
163
|
+
* secureStorage={createSecureStoreAdapter(SecureStore)}
|
|
71
164
|
* >
|
|
72
165
|
* <Navigation />
|
|
73
166
|
* </AetherProvider>
|
|
@@ -75,23 +168,27 @@ export function createMMKVAdapter(mmkv) {
|
|
|
75
168
|
* }
|
|
76
169
|
* ```
|
|
77
170
|
*/
|
|
78
|
-
export function AetherProvider({ config, storage, secureStorage, children, onAuthStateChange, }) {
|
|
171
|
+
export function AetherProvider({ config, storage, secureStorage, children, onAuthStateChange, loadingComponent, }) {
|
|
79
172
|
const [isReady, setIsReady] = React.useState(false);
|
|
173
|
+
// Cria client uma única vez
|
|
80
174
|
const client = useMemo(() => {
|
|
81
175
|
const aether = new PlataformaClient({ ...config, persistSession: true });
|
|
82
176
|
aether.setStorageAdapter(secureStorage ?? storage);
|
|
177
|
+
// ✅ Define client global automaticamente
|
|
178
|
+
_globalClient = aether;
|
|
83
179
|
return aether;
|
|
84
180
|
}, [config, storage, secureStorage]);
|
|
85
|
-
//
|
|
86
|
-
|
|
181
|
+
// Restaura sessão assíncrona
|
|
182
|
+
useEffect(() => {
|
|
87
183
|
const restoreSession = async () => {
|
|
88
184
|
try {
|
|
89
185
|
const storageAdapter = secureStorage ?? storage;
|
|
186
|
+
// Restaura token
|
|
90
187
|
const token = await storageAdapter.getItem('aether_token');
|
|
91
188
|
if (token) {
|
|
92
189
|
client.setToken(token);
|
|
93
190
|
}
|
|
94
|
-
//
|
|
191
|
+
// Restaura user data
|
|
95
192
|
const userData = await storageAdapter.getItem('aether_user');
|
|
96
193
|
if (userData) {
|
|
97
194
|
try {
|
|
@@ -112,9 +209,22 @@ export function AetherProvider({ config, storage, secureStorage, children, onAut
|
|
|
112
209
|
};
|
|
113
210
|
restoreSession();
|
|
114
211
|
}, [client, storage, secureStorage]);
|
|
115
|
-
//
|
|
212
|
+
// Limpa referência global quando desmonta
|
|
213
|
+
useEffect(() => {
|
|
214
|
+
return () => {
|
|
215
|
+
if (_globalClient === client) {
|
|
216
|
+
_globalClient = null;
|
|
217
|
+
}
|
|
218
|
+
};
|
|
219
|
+
}, [client]);
|
|
220
|
+
// Loading state
|
|
116
221
|
if (!isReady) {
|
|
117
|
-
|
|
222
|
+
if (loadingComponent) {
|
|
223
|
+
return typeof loadingComponent === 'function'
|
|
224
|
+
? loadingComponent()
|
|
225
|
+
: loadingComponent;
|
|
226
|
+
}
|
|
227
|
+
return null;
|
|
118
228
|
}
|
|
119
229
|
return (_jsx(BaseAetherProvider, { client: client, onAuthStateChange: onAuthStateChange, children: children }));
|
|
120
230
|
}
|
|
@@ -122,5 +232,6 @@ export function AetherProvider({ config, storage, secureStorage, children, onAut
|
|
|
122
232
|
// RE-EXPORTS
|
|
123
233
|
// =============================================================================
|
|
124
234
|
export { useAetherContext, useAetherClient, useAuth, useCollection, useDocument, useStorage, useFunctions, useFunction, useAI, useAIAsk, useAISearch, AuthGuard, GuestGuard, RoleGuard, ShowIfAuthenticated, ShowIfGuest, ShowIfRole, } from '@aether-baas/react';
|
|
125
|
-
|
|
235
|
+
// Version
|
|
236
|
+
export const VERSION = '3.2.0';
|
|
126
237
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,uBAAuB;AACvB,gFAAgF;AAChF,8DAA8D;AAC9D,gFAAgF;AAEhF,OAAO,KAAK,EAAE,EAAE,OAAO,EAAkB,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,uBAAuB;AACvB,gFAAgF;AAChF,8DAA8D;AAC9D,GAAG;AACH,gCAAgC;AAChC,0DAA0D;AAC1D,0EAA0E;AAC1E,gEAAgE;AAChE,gFAAgF;AAEhF,OAAO,KAAK,EAAE,EAAE,OAAO,EAAE,SAAS,EAAkB,MAAM,OAAO,CAAC;AAClE,OAAO,EACL,gBAAgB,GAKjB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,cAAc,IAAI,kBAAkB,GACrC,MAAM,oBAAoB,CAAC;AAE5B,gFAAgF;AAChF,2DAA2D;AAC3D,gFAAgF;AAEhF;;;GAGG;AACH,IAAI,aAAa,GAA4B,IAAI,CAAC;AAElD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,UAAU,eAAe;IAC7B,IAAI,CAAC,aAAa,EAAE,CAAC;QACnB,MAAM,IAAI,KAAK,CACb,oCAAoC;YACpC,wFAAwF;YACxF,0FAA0F,CAC3F,CAAC;IACJ,CAAC;IACD,OAAO,aAAa,CAAC;AACvB,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,mBAAmB;IACjC,OAAO,aAAa,KAAK,IAAI,CAAC;AAChC,C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AAO,EAAE,aAAa,CAAC,CAAC,CAAC;IAErC,0CAA0C;IAC1C,SAAS,CAAC,GAAG,EAAE;QACb,OAAO,GAAG,EAAE;YACV,IAAI,aAAa,KAAK,MAAM,EAAE,CAAC;gBAC7B,aAAa,GAAG,IAAI,CAAC;YACvB,CAAC;QACH,CAAC,CAAC;IACJ,CAAC,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;IAEb,gBAAgB;IAChB,IAAI,CAAC,OAAO,EAAE,CAAC;QACb,IAAI,gBAAgB,EAAE,CAAC;YACrB,OAAO,OAAO,gBAAgB,KAAK,UAAU;gBAC3C,CAAC,CAAC,gBAAgB,EAAE;gBACpB,CAAC,CAAC,gBAAgB,CAAC;QACvB,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,CACL,KAAC,kBAAkB,IAAC,MAAM,EAAE,MAAM,EAAE,iBAAiB,EAAE,iBAAiB,YACrE,QAAQ,GACU,CACtB,CAAC;AACJ,CAAC;AAED,gFAAgF;AAChF,aAAa;AACb,gFAAgF;AAEhF,OAAO,EACL,gBAAgB,EAChB,eAAe,EACf,OAAO,EACP,aAAa,EACb,WAAW,EACX,UAAU,EACV,YAAY,EACZ,WAAW,EACX,KAAK,EACL,QAAQ,EACR,WAAW,EACX,SAAS,EACT,UAAU,EACV,SAAS,EACT,mBAAmB,EACnB,WAAW,EACX,UAAU,GACX,MAAM,oBAAoB,CAAC;AAW5B,UAAU;AACV,MAAM,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aether-baas/react-native",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.2.0",
|
|
4
4
|
"description": "Aether SDK para React Native - Adapters e componentes para mobile",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"prepublishOnly": "pnpm build"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@aether-baas/core": "^3.1.
|
|
27
|
+
"@aether-baas/core": "^3.1.6",
|
|
28
28
|
"@aether-baas/react": "^3.1.3"
|
|
29
29
|
},
|
|
30
30
|
"peerDependencies": {
|