🎨 style(cardComponent): format code with Prettier

This commit only formats the code with Prettier to improve code readability and consistency. No functional changes were made.
This commit is contained in:
Gabriel Luiz Freitas Almeida 2023-06-14 09:27:51 -03:00
commit d78f2a81c5

View file

@ -1,10 +1,16 @@
import { Trash2, ExternalLink, GitFork } from "lucide-react";
import { GitFork } from "lucide-react";
import { useContext } from "react";
import { Link, useNavigate } from "react-router-dom";
import { useNavigate } from "react-router-dom";
import { TabsContext } from "../../../../contexts/tabsContext";
import { FlowType } from "../../../../types/flow";
import { gradients } from "../../../../utils";
import { CardTitle, CardDescription, CardFooter, Card, CardHeader } from "../../../../components/ui/card";
import {
CardTitle,
CardDescription,
CardFooter,
Card,
CardHeader,
} from "../../../../components/ui/card";
import { Button } from "../../../../components/ui/button";
export const CardComponent = ({ flow, id }: { flow: FlowType; id: string }) => {
@ -21,13 +27,9 @@ export const CardComponent = ({ flow, id }: { flow: FlowType; id: string }) => {
"rounded-full w-8 h-8 flex items-center justify-center text-2xl " +
gradients[parseInt(flow.id.slice(0, 6), 16) % gradients.length]
}
>
</span>
<span className="flex-1 truncate-doubleline">
{flow.name}
</span>
></span>
<span className="flex-1 truncate-doubleline">{flow.name}</span>
</div>
</CardTitle>
<CardDescription className="pt-2 pb-2">
<div className="truncate-doubleline">
@ -48,19 +50,19 @@ export const CardComponent = ({ flow, id }: { flow: FlowType; id: string }) => {
<span className="text-base">&nbsp;</span>OpenAI+
</Badge> */}
</div>
<Button
variant="outline"
size="sm"
className="whitespace-nowrap "
onClick={() => {
addFlow(flow).then((id) => {
navigate("/flow/"+id);
});
}}
>
<GitFork className="w-4 mr-2" />
Fork Example
</Button>
<Button
variant="outline"
size="sm"
className="whitespace-nowrap "
onClick={() => {
addFlow(flow, true).then((id) => {
navigate("/flow/" + id);
});
}}
>
<GitFork className="w-4 mr-2" />
Fork Example
</Button>
</div>
</CardFooter>
</Card>