1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-06-30 22:26:38 -04:00

refactor component imports/exports

This commit is contained in:
2022-03-16 11:22:56 -04:00
parent 83bb83804f
commit 4ea5b15db0
71 changed files with 224 additions and 139 deletions

View File

@ -0,0 +1,2 @@
export * from "./Blockquote";
export { default } from "./Blockquote";

View File

@ -0,0 +1,2 @@
export * from "./Captcha";
export { default } from "./Captcha";

View File

@ -1,4 +1,4 @@
import CopyButton from "../CopyButton/CopyButton";
import CopyButton from "../CopyButton";
import { styled } from "../../lib/styles/stitches.config";
import type { ComponentProps } from "react";

View File

@ -0,0 +1,2 @@
export * from "./CodeBlock";
export { default } from "./CodeBlock";

View File

@ -0,0 +1,2 @@
export * from "./Comments";
export { default } from "./Comments";

View File

@ -1,8 +1,8 @@
import { useState } from "react";
import { Formik, Form, Field } from "formik";
import TextareaAutosize from "react-textarea-autosize";
import Link from "../Link/Link";
import Captcha from "../Captcha/Captcha";
import Link from "../Link";
import Captcha from "../Captcha";
import { SendIcon, CheckOcticon, XOcticon } from "../Icons";
import { styled, css } from "../../lib/styles/stitches.config";
import type { FormikHelpers } from "formik";

View File

@ -0,0 +1,2 @@
export * from "./ContactForm";
export { default } from "./ContactForm";

View File

@ -0,0 +1,2 @@
export * from "./Content";
export { default } from "./Content";

View File

@ -0,0 +1,2 @@
export * from "./CopyButton";
export { default } from "./CopyButton";

View File

@ -1,4 +1,4 @@
import Image from "../Image/Image";
import Image from "../Image";
import innerText from "react-innertext";
import { styled } from "../../lib/styles/stitches.config";
import type { PropsWithChildren } from "react";

View File

@ -0,0 +1,2 @@
export * from "./Figure";
export { default } from "./Figure";

View File

@ -0,0 +1,2 @@
export * from "./Footer";
export { default } from "./Footer";

View File

@ -0,0 +1,2 @@
export * from "./GistEmbed";
export { default } from "./GistEmbed";

View File

@ -1,6 +1,6 @@
import { memo } from "react";
import Selfie from "../Selfie/Selfie";
import Menu from "../Menu/Menu";
import Selfie from "../Selfie";
import Menu from "../Menu";
import { styled } from "../../lib/styles/stitches.config";
import type { ComponentProps } from "react";

View File

@ -0,0 +1,2 @@
export * from "./Header";
export { default } from "./Header";

View File

@ -1,5 +1,5 @@
import innerText from "react-innertext";
import HeadingAnchor from "../HeadingAnchor/HeadingAnchor";
import HeadingAnchor from "../HeadingAnchor";
import { styled } from "../../lib/styles/stitches.config";
import type { ComponentProps } from "react";

View File

@ -0,0 +1,2 @@
export * from "./Heading";
export { default } from "./Heading";

View File

@ -0,0 +1,2 @@
export * from "./HeadingAnchor";
export { default } from "./HeadingAnchor";

View File

@ -1,5 +1,5 @@
import useSWR from "swr";
import Loading from "../Loading/Loading";
import Loading from "../Loading";
import { fetcher } from "../../lib/helpers/fetcher";
export type HitCounterProps = {

View File

@ -0,0 +1,2 @@
export * from "./HitCounter";
export { default } from "./HitCounter";

View File

@ -0,0 +1,2 @@
export * from "./HorizontalRule";
export { default } from "./HorizontalRule";

View File

@ -0,0 +1,2 @@
export * from "./IFrame";
export { default } from "./IFrame";

View File

@ -0,0 +1,2 @@
export * from "./Image";
export { default } from "./Image";

View File

@ -1,6 +1,6 @@
import Head from "next/head";
import Header from "../Header/Header";
import Footer from "../Footer/Footer";
import Header from "../Header";
import Footer from "../Footer";
import { useTheme } from "../../hooks/use-theme";
import { styled, theme, darkTheme } from "../../lib/styles/stitches.config";
import type { ComponentProps } from "react";

View File

@ -0,0 +1,2 @@
export * from "./Layout";
export { default } from "./Layout";

2
components/Link/index.ts Normal file
View File

@ -0,0 +1,2 @@
export * from "./Link";
export { default } from "./Link";

View File

@ -11,3 +11,5 @@ export const OrderedList = styled("ol", ListStyles);
export const ListItem = styled("li", {
paddingLeft: "0.25em",
});
export default UnorderedList;

2
components/List/index.ts Normal file
View File

@ -0,0 +1,2 @@
export * from "./List";
export { default } from "./List";

View File

@ -0,0 +1,2 @@
export * from "./Loading";
export { default } from "./Loading";

View File

@ -1,6 +1,6 @@
import { memo } from "react";
import { useRouter } from "next/router";
import MenuItem from "../MenuItem/MenuItem";
import MenuItem from "../MenuItem";
import { styled } from "../../lib/styles/stitches.config";
import { menuItems } from "../../lib/config/menu";
import type { ComponentProps } from "react";

2
components/Menu/index.ts Normal file
View File

@ -0,0 +1,2 @@
export * from "./Menu";
export { default } from "./Menu";

View File

@ -0,0 +1,2 @@
export * from "./MenuItem";
export { default } from "./MenuItem";

View File

@ -1,7 +1,7 @@
import Link from "next/link";
import { format } from "date-fns";
import HitCounter from "../HitCounter/HitCounter";
import NoteTitle from "../NoteTitle/NoteTitle";
import HitCounter from "../HitCounter";
import NoteTitle from "../NoteTitle";
import { DateIcon, TagIcon, EditIcon, ViewsIcon } from "../Icons";
import { styled } from "../../lib/styles/stitches.config";
import * as config from "../../lib/config";

View File

@ -0,0 +1,2 @@
export * from "./NoteMeta";
export { default } from "./NoteMeta";

View File

@ -0,0 +1,2 @@
export * from "./NoteTitle";
export { default } from "./NoteTitle";

View File

@ -1,5 +1,5 @@
import { format } from "date-fns";
import Link from "../Link/Link";
import Link from "../Link";
import { styled } from "../../lib/styles/stitches.config";
import type { NoteType } from "../../types";

View File

@ -0,0 +1,2 @@
export * from "./NotesList";
export { default } from "./NotesList";

View File

@ -0,0 +1,2 @@
export * from "./OctocatLink";
export { default } from "./OctocatLink";

View File

@ -0,0 +1,2 @@
export * from "./PageTitle";
export { default } from "./PageTitle";

View File

@ -1,5 +1,5 @@
import { intlFormat, formatDistanceToNowStrict } from "date-fns";
import Link from "../Link/Link";
import Link from "../Link";
import { StarOcticon, ForkOcticon } from "../Icons";
import { styled } from "../../lib/styles/stitches.config";
import type { RepositoryType } from "../../types";

View File

@ -0,0 +1,2 @@
export * from "./RepositoryCard";
export { default } from "./RepositoryCard";

View File

@ -0,0 +1,2 @@
export * from "./Selfie";
export { default } from "./Selfie";

View File

@ -0,0 +1,2 @@
export * from "./Terminal";
export { default } from "./Terminal";

View File

@ -0,0 +1,2 @@
export * from "./ThemeToggle";
export { default } from "./ThemeToggle";

View File

@ -0,0 +1,2 @@
export * from "./TweetEmbed";
export { default } from "./TweetEmbed";

View File

@ -1,7 +1,7 @@
import { useRef, useEffect, useState, memo } from "react";
import { useRouter } from "next/router";
import RFB from "@novnc/novnc/core/rfb.js";
import Terminal from "../Terminal/Terminal";
import Terminal from "../Terminal";
import { styled } from "../../lib/styles/stitches.config";
const Display = styled(

2
components/VNC/index.ts Normal file
View File

@ -0,0 +1,2 @@
export * from "./VNC";
export { default } from "./VNC";

View File

@ -0,0 +1,2 @@
export * from "./Video";
export { default } from "./Video";

View File

@ -0,0 +1,2 @@
export * from "./Wallpaper";
export { default } from "./Wallpaper";

View File

@ -0,0 +1,2 @@
export * from "./YouTubeEmbed";
export { default } from "./YouTubeEmbed";