Upgrade frontend to Node 26, React 19, Vite 8, Apollo Client 4 and ESLint 10
This commit is contained in:
44 files changed
+2940
-4597
No files matched your search
@@ -1,10 +1,10 @@
|
||||
import React from "react";
|
||||
|
||||
import { UserCard } from "../users/UserCard";
|
||||
import styles from "./Deposit.module.css";
|
||||
import { useDeposit } from "./useDeposit";
|
||||
import { UserCard } from "../users/UserCard";
|
||||
|
||||
const Deposit = (): JSX.Element => {
|
||||
const Deposit = (): React.JSX.Element => {
|
||||
const {
|
||||
loading,
|
||||
selectedUser,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useMutation, useQuery } from "@apollo/client";
|
||||
import { useMutation, useQuery } from "@apollo/client/react";
|
||||
import { useState } from "react";
|
||||
|
||||
import { useToast } from "../../components/ToastProvider";
|
||||
import { useToast } from "../../hooks/useToast";
|
||||
import { AllUsersDocument, CreateDepositDocument } from "../../types";
|
||||
|
||||
export const useDeposit = () => {
|
||||
@@ -32,9 +32,9 @@ export const useDeposit = () => {
|
||||
}
|
||||
|
||||
if (res.data?.createDeposit?.__typename === "CreateDepositSuccess") {
|
||||
const { transaction } = res.data?.createDeposit;
|
||||
const { transaction } = res.data.createDeposit;
|
||||
showToast(
|
||||
`${transaction.user.firstName} har satt inn${transaction.amount}. Ny saldo er ${transaction.user.profile?.balance}.`,
|
||||
`${transaction.user.firstName} har satt inn ${transaction.amount}. Ny saldo er ${transaction.user.profile?.balance}.`,
|
||||
);
|
||||
reset();
|
||||
return;
|
||||
|
||||
Reference in new issue
Block a user