mirror of
https://github.com/Jellify-Music/App.git
synced 2026-01-27 05:28:44 -06:00
getting animations to look correct on login flow
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import React, { useState } from "react";
|
||||
import React, { useEffect, useState } from "react";
|
||||
import _ from "lodash";
|
||||
import { useColorScheme } from "react-native";
|
||||
import AsyncStorage from "@react-native-async-storage/async-storage";
|
||||
@@ -54,6 +54,10 @@ export default function ServerAddress(): React.JSX.Element {
|
||||
}
|
||||
});
|
||||
|
||||
useEffect(() => {
|
||||
setChangeServer(false);
|
||||
})
|
||||
|
||||
return (
|
||||
<View marginHorizontal={10} flex={1} justifyContent='center'>
|
||||
<H2 marginVertical={30}>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import React from "react";
|
||||
import React, { useEffect } from "react";
|
||||
import { useMutation } from "@tanstack/react-query";
|
||||
import { useApiClientContext } from "../../jellyfin-api-provider";
|
||||
import _ from "lodash";
|
||||
@@ -11,7 +11,7 @@ export default function ServerAuthentication(): React.JSX.Element {
|
||||
const [username, setUsername] = React.useState('');
|
||||
const [password, setPassword] = React.useState('');
|
||||
|
||||
const { apiClient, setApiClient, server, setChangeServer, setUsername: setContextUsername } = useApiClientContext();
|
||||
const { apiClient, setApiClient, server, setChangeUser, setChangeServer, setUsername: setContextUsername } = useApiClientContext();
|
||||
|
||||
const useApiMutation = useMutation({
|
||||
mutationFn: async (credentials: JellyfinCredentials) => {
|
||||
@@ -49,6 +49,10 @@ export default function ServerAuthentication(): React.JSX.Element {
|
||||
}
|
||||
});
|
||||
|
||||
useEffect(() => {
|
||||
setChangeUser(false);
|
||||
})
|
||||
|
||||
return (
|
||||
<View marginHorizontal={10} flex={1} justifyContent='center'>
|
||||
<H2 marginVertical={30}>
|
||||
|
||||
Reference in New Issue
Block a user