Skip to content

Commit

Permalink
Update frontend_deploy.yml to include npm install step
Browse files Browse the repository at this point in the history
  • Loading branch information
Diegogtz03 committed Jun 12, 2024
1 parent 3c3ed48 commit 1d092a7
Show file tree
Hide file tree
Showing 14 changed files with 11,404 additions and 10,373 deletions.
21,442 changes: 11,208 additions & 10,234 deletions knowx/package-lock.json

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions knowx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"@neondatabase/serverless": "^0.9.1",
"@next-auth/prisma-adapter": "^1.0.7",
"@nextui-org/dropdown": "^2.1.23",
"@nextui-org/react": "^2.3.6",
"@nextui-org/react": "^2.4.1",
"@nextui-org/table": "^2.0.33",
"@panva/hkdf": "^1.1.1",
"@react-stately/data": "^3.11.3",
Expand All @@ -48,9 +48,10 @@
"msw": "^2.3.1",
"neon": "^2.0.0",
"net": "^1.0.2",
"next": "^13.4.10",
"next": "^13.5.4",
"next-auth": "^4.24.7",
"next-themes": "^0.3.0",
"nextjs-toploader": "^1.6.12",
"nodemailer": "^6.9.13",
"open-next": "^2.3.9",
"perf_hooks": "^0.0.1",
Expand Down
4 changes: 3 additions & 1 deletion knowx/src/app/dashboard/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ export default async function RootLayout({
}>) {
return (
<html lang="en">
<OverflowHiddenBody>{children}</OverflowHiddenBody>
<body>
<OverflowHiddenBody>{children}</OverflowHiddenBody>
</body>
</html>
)
}
98 changes: 50 additions & 48 deletions knowx/src/app/history/[...historyId]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,62 +38,64 @@ export default async function Home({
}

return (
<Suspense fallback={<Loading />}>
<main className="bg-backgroundLight dark:bg-backgroundDark">
<Header
isDashboard={false}
userMenuShowBoth={true}
title="Search History"
>
<HistoryOverview history={history} />
<main className="bg-backgroundLight dark:bg-backgroundDark">
<Header
isDashboard={false}
userMenuShowBoth={true}
title="Search History"
>
<Suspense fallback={<Loading />}>
<div className="flex flex-col items-center">
<HistoryOverview history={history} />

{tableResults != undefined ? (
<div className="mb-9 flex flex-col items-center">
<P3_ResultsTable incoming_results={tableResults} />
<P3_CompareButton
isHistory={true}
history={history.searchResults || ""}
/>
</div>
) : (
<Chip color="danger" className="m-5">
Error loading results
</Chip>
)}
</Header>
{tableResults != undefined ? (
<div className="mb-9 flex flex-col items-center">
<P3_ResultsTable incoming_results={tableResults} />
<P3_CompareButton
isHistory={true}
history={history.searchResults || ""}
/>
</div>
) : (
<Chip color="danger" className="m-5">
Error loading results
</Chip>
)}
</div>
</Suspense>
</Header>

<InfoComponent title="History" icon={2}>
<>
<p>The results above show the detailed history of your search.</p>
<InfoComponent title="History" icon={2}>
<>
<p>The results above show the detailed history of your search.</p>

<br />
<br />

<p>
These include the information generated by our system and the ones
selected by you for this specific search.
</p>
<p>
These include the information generated by our system and the ones
selected by you for this specific search.
</p>

<br />
<br />

<p>
The{" "}
<Chip variant="dot" color="secondary">
purple
</Chip>{" "}
chips represent those categories created by you.
</p>
<p>
The{" "}
<Chip variant="dot" color="secondary">
purple
</Chip>{" "}
chips represent those categories created by you.
</p>

<br />
<br />

<p>
Use the action buttons to provide feedback on the generated topics
or delete the search from your history.
</p>
<p>
Use the action buttons to provide feedback on the generated topics
or delete the search from your history.
</p>

<br />
</>
</InfoComponent>
</main>
</Suspense>
<br />
</>
</InfoComponent>
</main>
)
}
6 changes: 5 additions & 1 deletion knowx/src/app/history/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import EllipsisVerticalIcon from "@heroicons/react/20/solid/EllipsisVerticalIcon
import TrashIcon from "@heroicons/react/20/solid/TrashIcon"
import { checkSession } from "@/actions/redirect"
import { redirect } from "next/navigation"
import { Suspense } from "react"
import Loading from "./loading"

export default async function Home() {
let history: SimpleHistoryType[] = []
Expand All @@ -28,7 +30,9 @@ export default async function Home() {
<main className="bg-backgroundLight dark:bg-backgroundDark">
<Header isDashboard={false} title="Search History">
<div className="flex w-2/3">
<SearchHistoryList history={history || []} />
<Suspense fallback={<Loading />}>
<SearchHistoryList history={history || []} />
</Suspense>
</div>
</Header>
<InfoComponent title="History" icon={2}>
Expand Down
2 changes: 1 addition & 1 deletion knowx/src/components/Compare/Compare_Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export const Compare_Button = ({
return (
<Button
variant="flat"
color="success"
color="primary"
className="mx-auto my-5 w-[200px] rounded-xl p-5"
onClick={() => {
!isHistory ? backToPhase3() : router.back()
Expand Down
18 changes: 11 additions & 7 deletions knowx/src/components/Compare/Compare_Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@

import React from "react"
import { Menu } from "@headlessui/react"
import { CheckCircleIcon, ChevronDownIcon } from "@heroicons/react/20/solid"
import { ChevronDownIcon } from "@heroicons/react/20/solid"
import { useState } from "react"
import { Results, ServiceCategories } from "@/interfaces/Phase3"
import { Chip } from "@nextui-org/react"

interface CardProps {
initialTitle: string
Expand Down Expand Up @@ -61,10 +62,11 @@ export const Compare_Card = ({
))}
</Menu.Items>
</Menu>
<hr className="my-8 h-px border-2 bg-gray-600 dark:bg-gray-700" />
<p className="mb-8 text-center text-backgroundDark dark:text-backgroundLight">
<hr className="my-8 h-px rounded-lg border-2 bg-gray-600 dark:bg-gray-700" />
<p className="mb-8 text-center text-lg text-backgroundDark dark:text-backgroundLight">
{description}
</p>

<ul className="space-y-4 text-backgroundDark dark:text-backgroundLight">
{data.map(
(category, index) =>
Expand All @@ -74,13 +76,15 @@ export const Compare_Card = ({
className="flex flex-row items-center"
key={`${category.Name}: ${category.Value}`}
>
<CheckCircleIcon className="mr-3 h-5 w-5" />
{/* <CheckCircleIcon className="mr-3 h-5 w-5" /> */}
<li
key={index}
className="flex items-center text-backgroundDark dark:text-backgroundLight"
className="mb-2 flex w-full flex-col justify-between text-backgroundDark dark:text-backgroundLight"
>
{" "}
{`${category.Name}: ${category.Value}`}
<Chip color="secondary" variant="flat">
<p className="font-bold">{category.Name}</p>
</Chip>
<div className="ml-4 mt-2 opacity-90">{category.Value}</div>
</li>
</div>
),
Expand Down
Loading

0 comments on commit 1d092a7

Please sign in to comment.