diff --git a/components/FormList.tsx b/components/FormList.tsx index 5150ecc2dc..f73b1b25cd 100644 --- a/components/FormList.tsx +++ b/components/FormList.tsx @@ -1,6 +1,3 @@ -import Link from "next/link"; -import Router from "next/router"; -import { Fragment } from "react"; import { Menu, Transition } from "@headlessui/react"; import { DocumentAddIcon, @@ -8,11 +5,13 @@ import { TerminalIcon, ViewGridAddIcon, } from "@heroicons/react/outline"; -import EmptyPageFiller from "./layout/EmptyPageFiller"; import { DotsHorizontalIcon, TrashIcon } from "@heroicons/react/solid"; -import { classNames } from "../lib/utils"; +import Link from "next/link"; +import Router from "next/router"; +import { Fragment } from "react"; import { createForm, useForms } from "../lib/forms"; -import Image from "next/image"; +import { classNames } from "../lib/utils"; +import EmptyPageFiller from "./layout/EmptyPageFiller"; export default function FormList() { const { forms, mutateForms } = useForms(); @@ -47,8 +46,7 @@ export default function FormList() { hintText="Start by creating a form." buttonText="create form" borderStyles="border-4 border-dotted border-red" - icon="BsFilePlus" - button="true" + button={true} > @@ -68,14 +66,11 @@ export default function FormList() { {forms .sort((a, b) => b.updatedAt - a.updatedAt) .map((form, formIdx) => ( -
  • +
  • +
    {form.name}
    - -
    - {form.name} -
    -
    +
    diff --git a/components/StandardButton.tsx b/components/StandardButton.tsx index a6c9e42901..ebd20e9d26 100644 --- a/components/StandardButton.tsx +++ b/components/StandardButton.tsx @@ -1,27 +1,29 @@ import React from "react"; +import { classNames } from "../lib/utils"; interface Props { children: React.ReactNode; - onClick: () => void; + onClick?: () => void; disabled?: boolean; fullwidth?: boolean; + [key: string]: any; } // button component, consuming props const StandardButton: React.FC = ({ children, - onClick, + onClick = () => {}, disabled = false, fullwidth = false, ...rest }) => { return (