add wallet address to user

This commit is contained in:
João Geonizeli
2021-08-18 15:58:04 -03:00
parent 00337665bd
commit d21bd33436
14 changed files with 125 additions and 86 deletions

View File

@@ -8,6 +8,7 @@ import type { UserProvider_user$key } from "./__generated__/UserProvider_user.gr
type CurrentUserContext = {
user: {
firstName: string;
walletAddress: string | null;
} | null;
isAuthenticated: boolean;
};
@@ -32,6 +33,7 @@ export const UserProvider: FC<Props> = ({ userRef, children }) => {
graphql`
fragment UserProvider_user on User {
firstName
walletAddress
}
`,
userRef
@@ -40,6 +42,7 @@ export const UserProvider: FC<Props> = ({ userRef, children }) => {
const user = userData
? {
firstName: userData.firstName,
walletAddress: userData.walletAddress,
}
: null;

View File

@@ -6,6 +6,7 @@ import { ReaderFragment } from "relay-runtime";
import { FragmentRefs } from "relay-runtime";
export type UserProvider_user = {
readonly firstName: string;
readonly walletAddress: string | null;
readonly " $refType": "UserProvider_user";
};
export type UserProvider_user$data = UserProvider_user;
@@ -28,10 +29,17 @@ const node: ReaderFragment = {
"kind": "ScalarField",
"name": "firstName",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "walletAddress",
"storageKey": null
}
],
"type": "User",
"abstractKey": null
};
(node as any).hash = '352cdd208485d062f3f7c2e22e287a99';
(node as any).hash = 'ef997d2646b4d39178c6f3318509a7cb';
export default node;