Browse Source

chore: misc

Signed-off-by: Muthu Kumar <muthukumar@thefeathers.in>
pull/1/head
Muthu Kumar 2 years ago
parent
commit
d5c99fe05e
Signed by: mkrhere GPG Key ID: 3FD688398897097E
  1. 2
      src/components/Container.tsx
  2. 2
      src/components/Menu.tsx
  3. 2
      src/components/RevealChildren.tsx
  4. 4
      src/components/Timeline.tsx
  5. 2
      src/pages/main/Contact.tsx
  6. 6
      src/pages/main/Exp.tsx
  7. 2
      src/pages/main/Home.tsx
  8. 2
      src/pages/main/Live.tsx
  9. 4
      src/pages/main/Projects.tsx
  10. 2
      svg.d.ts

2
src/components/Container.tsx

@ -10,7 +10,7 @@ import useMediaQuery from "../util/useMediaQuery";
const [timer, clear] = getTimeout(); const [timer, clear] = getTimeout();
const Container: React.FunctionComponent<{ const Container: React.FC<{
children: (string | React.DetailedReactHTMLElement<any, HTMLElement> | React.ReactElement)[]; children: (string | React.DetailedReactHTMLElement<any, HTMLElement> | React.ReactElement)[];
hideNav?: boolean; hideNav?: boolean;
arrowReversed?: boolean; arrowReversed?: boolean;

2
src/components/Menu.tsx

@ -61,7 +61,7 @@ const mobileMenu = css`
} }
`; `;
const Menu: React.FunctionComponent<{ show?: boolean; setShowMenu: (show: boolean) => void }> = ({ const Menu: React.FC<{ show?: boolean; setShowMenu: (show: boolean) => void }> = ({
show = false, show = false,
setShowMenu, setShowMenu,
}) => { }) => {

2
src/components/RevealChildren.tsx

@ -1,7 +1,7 @@
import React from "react"; import React from "react";
import { motion } from "framer-motion"; import { motion } from "framer-motion";
const RevealChildren: React.FunctionComponent<{ const RevealChildren: React.FC<{
type: "div" | "span" | "li"; type: "div" | "span" | "li";
children: React.ReactChild[]; children: React.ReactChild[];
show: boolean; show: boolean;

4
src/components/Timeline.tsx

@ -86,7 +86,7 @@ const tlcontainer = css`
} }
`; `;
const Unit: React.FunctionComponent<{ contents: TimelineUnit }> = ({ contents }) => { const Unit: React.FC<{ contents: TimelineUnit }> = ({ contents }) => {
const date = useMemo(() => new Date(contents.date), [contents.date]); const date = useMemo(() => new Date(contents.date), [contents.date]);
return ( return (
@ -116,7 +116,7 @@ const Unit: React.FunctionComponent<{ contents: TimelineUnit }> = ({ contents })
); );
}; };
const Timeline: React.FunctionComponent<{ contents: TimelineUnits }> = ({ contents }) => { const Timeline: React.FC<{ contents: TimelineUnits }> = ({ contents }) => {
const current = useMemo(() => new Date(), []); const current = useMemo(() => new Date(), []);
return ( return (

2
src/pages/main/Contact.tsx

@ -34,7 +34,7 @@ const CONTACT: Contact = {
}, },
}; };
const Home: React.FunctionComponent = () => { const Home: React.FC = () => {
const [contact, setContact] = useState<Contact>(CONTACT); const [contact, setContact] = useState<Contact>(CONTACT);
useEffect(() => { useEffect(() => {

6
src/pages/main/Exp.tsx

@ -27,7 +27,7 @@ const exp = [
}, },
]; ];
const Circle: React.FunctionComponent = () => ( const Circle: React.FC = () => (
<div> <div>
<div <div
className={css` className={css`
@ -60,7 +60,7 @@ type Experience = {
year: string; year: string;
}; };
const ExpUnit: React.FunctionComponent<Experience> = ({ title, location, position, year }) => { const ExpUnit: React.FC<Experience> = ({ title, location, position, year }) => {
return ( return (
<div <div
className={css` className={css`
@ -96,7 +96,7 @@ const getAge = (date: string) => {
const age = getAge("27 May 1995"); const age = getAge("27 May 1995");
const Exp: React.FunctionComponent = () => { const Exp: React.FC = () => {
return ( return (
<Container next="/projects"> <Container next="/projects">
<h2>Im a {age} year old developer from Chennai, India.</h2> <h2>Im a {age} year old developer from Chennai, India.</h2>

2
src/pages/main/Home.tsx

@ -2,7 +2,7 @@ import React from "react";
import Container from "../../components/Container"; import Container from "../../components/Container";
import Dashed from "../../components/Dashed"; import Dashed from "../../components/Dashed";
const Home: React.FunctionComponent = () => { const Home: React.FC = () => {
return ( return (
<Container next="/experience"> <Container next="/experience">
<h1>MKRhere</h1> <h1>MKRhere</h1>

2
src/pages/main/Live.tsx

@ -11,7 +11,7 @@ type LiveInfo =
videoID: string; videoID: string;
}; };
const Live: React.FunctionComponent = () => { const Live: React.FC = () => {
const [tl, setTl] = useState<TimelineUnits>([]); const [tl, setTl] = useState<TimelineUnits>([]);
const [liveInfo, setLiveInfo] = useState<LiveInfo>({ live: false }); const [liveInfo, setLiveInfo] = useState<LiveInfo>({ live: false });

4
src/pages/main/Projects.tsx

@ -55,7 +55,7 @@ type Project = {
tags: string[]; tags: string[];
}; };
const ProjectUnit: React.FunctionComponent<Project> = ({ title, url, description, cat, tags }) => { const ProjectUnit: React.FC<Project> = ({ title, url, description, cat, tags }) => {
return ( return (
<div <div
className={css` className={css`
@ -136,7 +136,7 @@ const ProjectUnit: React.FunctionComponent<Project> = ({ title, url, description
); );
}; };
const Exp: React.FunctionComponent = () => { const Exp: React.FC = () => {
return ( return (
<Container next="/contact"> <Container next="/contact">
<h2>What else have I built?</h2> <h2>What else have I built?</h2>

2
svg.d.ts

@ -1,7 +1,7 @@
declare module "*.svg" { declare module "*.svg" {
import * as React from "react"; import * as React from "react";
export const ReactComponent: React.FunctionComponent< export const ReactComponent: React.FC<
React.SVGProps<SVGSVGElement> & { title?: string; ref?: React.Ref<SVGSVGElement> | undefined } React.SVGProps<SVGSVGElement> & { title?: string; ref?: React.Ref<SVGSVGElement> | undefined }
>; >;
} }

Loading…
Cancel
Save