@umituz/react-native-auth 3.6.14 → 3.6.16

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-auth",
3
- "version": "3.6.14",
3
+ "version": "3.6.16",
4
4
  "description": "Authentication service for React Native apps - Secure, type-safe, and production-ready. Provider-agnostic design with dependency injection, configurable validation, and comprehensive error handling.",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./src/index.ts",
@@ -17,14 +17,12 @@ import {
17
17
  AtomicButton,
18
18
  AtomicText,
19
19
  useAppDesignTokens,
20
- type AtomicInputProps,
21
20
  } from "@umituz/react-native-design-system";
22
21
  import { useLocalization } from "@umituz/react-native-localization";
23
22
  import {
24
23
  updateUserPassword,
25
24
  reauthenticateWithPassword,
26
25
  getCurrentUserFromGlobal,
27
- getFirebaseAuth,
28
26
  } from "@umituz/react-native-firebase";
29
27
 
30
28
  export interface ChangePasswordScreenProps {
@@ -38,7 +36,6 @@ export const ChangePasswordScreen: React.FC<ChangePasswordScreenProps> = ({
38
36
  }) => {
39
37
  const { t } = useLocalization();
40
38
  const tokens = useAppDesignTokens();
41
- const auth = getFirebaseAuth();
42
39
 
43
40
  const [currentPassword, setCurrentPassword] = useState("");
44
41
  const [newPassword, setNewPassword] = useState("");
@@ -98,19 +95,19 @@ export const ChangePasswordScreen: React.FC<ChangePasswordScreenProps> = ({
98
95
  Alert.alert(t("common.success"), t("auth.passwordChange.success"), [
99
96
  { text: "OK", onPress: onSuccess }
100
97
  ]);
101
- if (onSuccess) onSuccess();
102
98
  } else {
103
99
  setError(updateResult.error?.message || t("auth.passwordChange.error"));
104
100
  }
105
- } catch (e: any) {
106
- setError(e.message || t("auth.passwordChange.error"));
101
+ } catch (e: unknown) {
102
+ const errorMessage = e instanceof Error ? e.message : t("auth.passwordChange.error");
103
+ setError(errorMessage);
107
104
  } finally {
108
105
  setLoading(false);
109
106
  }
110
107
  };
111
108
 
112
109
  const RequirementsList = () => (
113
- <View style={styles.requirementsContainer}>
110
+ <View style={[styles.requirementsContainer, { backgroundColor: tokens.colors.surfaceSecondary }]}>
114
111
  <AtomicText type="labelMedium" style={{ color: tokens.colors.textSecondary, marginBottom: 8 }}>
115
112
  {t("auth.passwordChange.requirements")}
116
113
  </AtomicText>
@@ -203,7 +200,7 @@ export const ChangePasswordScreen: React.FC<ChangePasswordScreenProps> = ({
203
200
  />
204
201
  <AtomicButton
205
202
  title={loading ? t("auth.passwordChange.changing") : t("auth.passwordChange.changePassword")}
206
- onPress={handleChangePassword}
203
+ onPress={() => { void handleChangePassword(); }}
207
204
  loading={loading}
208
205
  disabled={!isValid || loading}
209
206
  style={{ flex: 1 }}
@@ -226,7 +223,6 @@ const styles = StyleSheet.create({
226
223
  marginTop: 8,
227
224
  padding: 12,
228
225
  borderRadius: 8,
229
- backgroundColor: "rgba(0,0,0,0.05)",
230
226
  },
231
227
  requirementItem: {
232
228
  flexDirection: "row",