Skip to content

Commit

Permalink
graphqlのimport修正
Browse files Browse the repository at this point in the history
  • Loading branch information
hikahana committed Nov 7, 2024
1 parent ce49169 commit 42b52f1
Show file tree
Hide file tree
Showing 11 changed files with 37 additions and 45 deletions.
12 changes: 6 additions & 6 deletions view-admin/src/components/common/PrizeResult/PrizeResult.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import React, { useState } from "react";
import styles from "./PrizeResult.module.css";
import { useMutation } from "@apollo/client";
import { UpdateOnePrizeIsWonDocument } from "@/type/graphql";
import Image from "next/image";
import type {
UpdateOnePrizeIsWonMutation,
UpdateOnePrizeIsWonMutationVariables,
GetListPrizesQuery,
import {
UpdateOnePrizeIsWonDocument,
type UpdateOnePrizeIsWonMutation,
type UpdateOnePrizeIsWonMutationVariables,
type GetListPrizesQuery,
} from "@/type/graphql";
import Image from "next/image";

interface PrizeResultProps {
prizeResult: GetListPrizesQuery["prizes"];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ import React, { useState } from "react";
import styles from "./UpdateNumberModal.module.css";
import { RxCrossCircled } from "react-icons/rx";
import { useMutation } from "@apollo/client";
import { UpdateOneNumberDocument } from "@/type/graphql";
import type {
UpdateOneNumberMutation,
UpdateOneNumberMutationVariables,
import {
UpdateOneNumberDocument,
type UpdateOneNumberMutation,
type UpdateOneNumberMutationVariables,
} from "@/type/graphql";

interface UpdateNumberModalProps {
Expand Down
16 changes: 7 additions & 9 deletions view-admin/src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,9 @@ import {
SubscribeListNumbersDocument,
IncrementReachNumDocument,
DecrementReachNumDocument,
} from "@/type/graphql";
import type {
SubscribeListNumbersSubscription,
IncrementReachNumMutation,
DecrementReachNumMutation,
type SubscribeListNumbersSubscription,
type IncrementReachNumMutation,
type DecrementReachNumMutation,
} from "@/type/graphql";

interface formDataCreate {
Expand All @@ -43,7 +41,7 @@ const Page: NextPage = () => {
SubscribeListNumbersSubscription["numbers"]
>([]);
const [isOpened, setIsOpened] = useState<boolean>(false);
const isopenBool = () => setIsOpened(!isOpened);
const isOpenBool = () => setIsOpened(!isOpened);
const [isOpenUpdateNumberModal, setIsOpenUpdateNumberModal] =
useState<boolean>(false);

Expand Down Expand Up @@ -143,7 +141,7 @@ const Page: NextPage = () => {
>
<p>景品管理</p>
</Button>
<Button size="m" shape="circle" onClick={isopenBool}>
<Button size="m" shape="circle" onClick={isOpenBool}>
<p>ビンゴ正誤判定</p>
</Button>
<Button
Expand All @@ -161,7 +159,7 @@ const Page: NextPage = () => {
<p>抽選した番号を入力</p>
<form onSubmit={handleSubmitCreate(onSubmitCreate)}>
<div className={styles.item}>
<div className={styles.flexerror}>
<div className={styles.flexError}>
<input
type="number"
placeholder="番号を入力"
Expand Down Expand Up @@ -195,7 +193,7 @@ const Page: NextPage = () => {
<div className={styles.frame}>
<p className={styles.centerText}>抽選した番号を削除</p>
<div className={styles.item}>
<div className={styles.flexerror}>
<div className={styles.flexError}>
<input
type="number"
placeholder="番号を入力"
Expand Down
13 changes: 5 additions & 8 deletions view-admin/src/pages/postPrizes/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,12 @@ import {
GetListPrizesDocument,
CreateOnePrizeDocument,
CreateOneImageDocument,
type GetListPrizesQuery,
type CreateOneImageMutation,
type CreateOnePrizeMutation,
type CreateOneImageMutationVariables,
type CreateOnePrizeMutationVariables,
} from "@/type/graphql";
import type {
GetListPrizesQuery,
CreateOneImageMutation,
CreateOnePrizeMutation,
CreateOneImageMutationVariables,
CreateOnePrizeMutationVariables,
} from "@/type/graphql";

import { useRouter } from "next/router";

const Page: NextPage = () => {
Expand Down
3 changes: 1 addition & 2 deletions view-admin/src/pages/prizes/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ import { Header, Button, PrizeResult } from "@/components/common";
import { useRouter } from "next/router";
import { useState, useEffect, useRef } from "react";
import { useQuery } from "@apollo/client";
import { GetListPrizesDocument } from "@/type/graphql";
import type { GetListPrizesQuery } from "@/type/graphql";
import { GetListPrizesDocument, type GetListPrizesQuery } from "@/type/graphql";

const Page: NextPage = () => {
const router = useRouter();
Expand Down
12 changes: 5 additions & 7 deletions view-user/src/components/Layout/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,11 @@ import {
CreateOneStampTriggerDocument,
CreateOneReachRecordDocument,
GetOneLatestReachLogDocument,
} from "@/types/graphql";
import type {
CreateOneStampTriggerMutation,
CreateOneStampTriggerMutationVariables,
CreateOneReachRecordMutation,
CreateOneReachRecordMutationVariables,
GetOneLatestReachLogQuery,
type CreateOneStampTriggerMutation,
type CreateOneStampTriggerMutationVariables,
type CreateOneReachRecordMutation,
type CreateOneReachRecordMutationVariables,
type GetOneLatestReachLogQuery,
} from "@/types/graphql";
import { ja, en } from "@/locales";
import { TwitterPicker } from "react-color";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from "react";
import type { SubscribeListNumbersSubscription } from "@/types/graphql";
import { type SubscribeListNumbersSubscription } from "@/types/graphql";
import styles from "./NumberCardList.module.css";
import NumberCardSmall from "../NumberCardSmall";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from "react";
import styles from "./NumberCardSmall.module.css";
import type { SubscribeListNumbersSubscription } from "@/types/graphql";
import { type SubscribeListNumbersSubscription } from "@/types/graphql";

interface NumberCardSmallProps {
BingoNumber: SubscribeListNumbersSubscription["numbers"][number];
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from "react";
import styles from "./PrizeCard.module.css";
import type { GetListPrizesQuery } from "@/types/graphql";
import { type GetListPrizesQuery } from "@/types/graphql";
import { useRouter } from "next/router";
import classNames from "classnames";
import { en, ja } from "@/locales";
Expand Down
6 changes: 4 additions & 2 deletions view-user/src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,10 @@ import { useRouter } from "next/router";
import React, { useEffect, useState, useCallback } from "react";
import styles from "@/styles/Home.module.css";
import { useSubscription } from "@apollo/client";
import { SubscribeListNumbersDocument } from "@/types/graphql";
import type { SubscribeListNumbersSubscription } from "@/types/graphql";
import {
SubscribeListNumbersDocument,
type SubscribeListNumbersSubscription,
} from "@/types/graphql";
import { Layout, Loading, NumberCardLarge, NumberCardList } from "@/components";
import { ja, en } from "@/locales";

Expand Down
6 changes: 2 additions & 4 deletions view-user/src/pages/prizes/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,8 @@ import { useQuery, useSubscription } from "@apollo/client";
import {
GetListPrizesDocument,
SubscribeListPrizesIsWonDocument,
} from "@/types/graphql";
import type {
GetListPrizesQuery,
SubscribeListPrizesIsWonSubscription,
type GetListPrizesQuery,
type SubscribeListPrizesIsWonSubscription,
} from "@/types/graphql";
import { useRecoilState } from "recoil";
import { bingoPrizeState } from "../../Atom/atom";
Expand Down

0 comments on commit 42b52f1

Please sign in to comment.