diff --git a/frontend/components/Sponsors.tsx b/frontend/components/Sponsors.tsx
index 432982d..e8ecce2 100644
--- a/frontend/components/Sponsors.tsx
+++ b/frontend/components/Sponsors.tsx
@@ -1,19 +1,14 @@
"use client";
-import Image from "next/image";
+import { imagePrefix } from "@/app/config";
import {
Box,
- Button,
+ Card,
Container,
- Flex,
Heading,
- Icon,
- Stack,
- Text,
- Card,
- useColorModeValue,
SimpleGrid,
+ Stack,
} from "@chakra-ui/react";
-import { imagePrefix } from "@/app/config";
+import Image from "next/image";
export default function Sponsors() {
return (
@@ -27,51 +22,51 @@ export default function Sponsors() {
-
-
-
+
+
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
);
}
diff --git a/frontend/src/app/areas/model/[area]/[title]/page.tsx b/frontend/src/app/areas/model/[area]/[title]/page.tsx
index ce1ea4c..d2c9a37 100644
--- a/frontend/src/app/areas/model/[area]/[title]/page.tsx
+++ b/frontend/src/app/areas/model/[area]/[title]/page.tsx
@@ -1,4 +1,3 @@
-import { title } from "process";
import ModelView from "../../../../../../components/Models";
export const dynamic = "force-dynamic";
diff --git a/frontend/src/app/careers/page.tsx b/frontend/src/app/careers/page.tsx
index 077695e..201074d 100644
--- a/frontend/src/app/careers/page.tsx
+++ b/frontend/src/app/careers/page.tsx
@@ -6,19 +6,11 @@ import {
Container,
Flex,
Heading,
- Icon,
Stack,
Text,
useColorModeValue,
} from "@chakra-ui/react";
import { ReactElement } from "react";
-import {
- FcAbout,
- FcAssistant,
- FcCollaboration,
- FcDonate,
- FcManager,
-} from "react-icons/fc";
import CareerContactBanner from "../../../components/CareerContactBanner";
import Jobs from "../../../components/CareerJobList";
diff --git a/frontend/src/app/config.tsx b/frontend/src/app/config.tsx
index dc79586..ed2c389 100644
--- a/frontend/src/app/config.tsx
+++ b/frontend/src/app/config.tsx
@@ -24,6 +24,7 @@ export const LANGUAGE_CODE_NAMES = {
mr: "Marathi",
mni: "Meitei (Manipuri)",
raj: "Rajasthani",
+ si: "Sinhala",
};
export const imagePrefix = process.env.BASE_PATH || "";
diff --git a/frontend/src/app/publications/page.tsx b/frontend/src/app/publications/page.tsx
index d594999..5dc06d0 100644
--- a/frontend/src/app/publications/page.tsx
+++ b/frontend/src/app/publications/page.tsx
@@ -9,13 +9,14 @@ import {
VStack,
Flex,
Link,
- Select,
useColorModeValue,
Button,
Stack,
+ Wrap,
useBreakpointValue,
Divider,
- SimpleGrid,
+ useRadio,
+ useRadioGroup,
} from "@chakra-ui/react";
import { FaPaperclip, FaGithub, FaCode } from "react-icons/fa";
import { useQuery } from "react-query";
@@ -24,6 +25,38 @@ import { API_URL } from "../config";
import Image from "next/image";
import { imagePrefix } from "../config";
+// 1. Create a component that consumes the `useRadio` hook
+function RadioCard(props: any) {
+ const { getInputProps, getRadioProps } = useRadio(props);
+
+ const input = getInputProps();
+ const checkbox = getRadioProps();
+
+ return (
+
+
+
+ {props.children}
+
+
+ );
+}
+
const ExpandableText = ({
text,
noOfLines = 2,
@@ -133,72 +166,90 @@ const Publications = () => {
setFilteredPublications(filtered);
}, [filterArea, filterYear, filterConference, publications]);
+ const { getRootProps: areaRootProps, getRadioProps: areaRadioProps } =
+ useRadioGroup({
+ name: "areaGroup",
+ defaultValue: filterArea,
+ value: filterArea,
+ onChange: setFilterArea,
+ });
+
+ const areaGroup = areaRootProps();
+
+ const { getRootProps: yearRootProps, getRadioProps: yearRadioProps } =
+ useRadioGroup({
+ name: "yearGroup",
+ defaultValue: filterYear,
+ value: filterYear,
+ onChange: setFilterYear,
+ });
+
+ const yearGroup = yearRootProps();
+
+ const { getRootProps: confRootProps, getRadioProps: confRadioProps } =
+ useRadioGroup({
+ name: "confGroup",
+ defaultValue: filterConference,
+ value: filterConference,
+ onChange: setFilterConference,
+ });
+
+ const confGroup = confRootProps();
+
return (
Publications
-
-
+
+
Area:{" "}
- {filters.areas.map((area) => (
-
- ))}
+
+ {filters.areas.map((value) => {
+ const radio = areaRadioProps({ value });
+ return (
+
+ {value}
+
+ );
+ })}
+
- Conference:{" "}
+ Year:{" "}
-
- {filters.conferences.map((conference) => (
-
- ))}
-
+
+ {filters.years.map((value) => {
+ const radio = yearRadioProps({ value });
+ return (
+
+ {value}
+
+ );
+ })}
+
-
+
- Year:{" "}
+ Conference:{" "}
- {filters.years.map((year) => (
-
- ))}
+
+ {filters.conferences.map((value) => {
+ const radio = confRadioProps({ value });
+ return (
+
+ {value}
+
+ );
+ })}
+