Skip to content

Commit f69d43e

Browse files
committed
fix conflix 2
1 parent 086479e commit f69d43e

File tree

2 files changed

+5
-13
lines changed

2 files changed

+5
-13
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,5 @@ database/
1010
dist
1111

1212
# pour avoir une liste des tâche a faire qui reste en local
13-
toodo.md
13+
toodo.md
14+
ingnore

frontend/src/pages/Conversations.tsx

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
import React, { useEffect, useState } from "react";
2-
import data from "../components/groups/data/data.json";
32
import Groups from "../components/groups/Groups";
43
import Messaging from "../components/groups/Messaging/Messaging";
5-
import PiggyBank from "../components/groups/PiggyBank";
6-
import Wishlist from "../components/groups/Wishlist";
74
import Button from "../components/utils/Button";
85
import type { GetAllMyGroupsQuery } from "../generated/graphql-types";
96
import { useGetAllMyGroupsQuery } from "../generated/graphql-types";
@@ -13,14 +10,10 @@ export default function Conversations() {
1310
const [_whislist, setWishlist] = React.useState(true);
1411

1512
const { data: groupData } = useGetAllMyGroupsQuery();
16-
const [groups, setGroups] = useState<GetAllMyGroupsQuery["getAllMyGroups"]>(
17-
[]
18-
);
13+
const [groups, setGroups] = useState<GetAllMyGroupsQuery["getAllMyGroups"]>([]);
1914

2015
const [activeGroupId, setActiveGroupId] = React.useState<Number | null>(null);
21-
const [activeGroup, setActiveGroup] = React.useState<
22-
GetAllMyGroupsQuery["getAllMyGroups"][0] | null
23-
>(null);
16+
const [activeGroup, setActiveGroup] = React.useState<GetAllMyGroupsQuery["getAllMyGroups"][0] | null>(null);
2417

2518
useEffect(() => {
2619
setGroups(groupData?.getAllMyGroups || []);
@@ -41,9 +34,7 @@ export default function Conversations() {
4134
{/* Left Column */}
4235
<div className="flex flex-col mx-[2vw] h-full min-h-0 justify-between">
4336
<div className="h-[calc(50%-2rem)] flex pb-2 ">
44-
{groups && (
45-
<Groups groups={groups} setActiveGroup={setActiveGroupId} />
46-
)}
37+
{groups && <Groups groups={groups} setActiveGroup={setActiveGroupId} />}
4738
</div>
4839

4940
<div className="flex flex-row gap-2 pb-2 absolute top-[calc(50%)]">

0 commit comments

Comments
 (0)