diff options
author | 2020-10-05 13:05:06 +0100 | |
---|---|---|
committer | 2020-10-05 13:05:06 +0100 | |
commit | 986660501dd9e4c0351ef4f08a9d6832eb01a44b (patch) | |
tree | 37e9d354752871d78a667440bd799c6086c39d6f | |
parent | Add a very basic question type (diff) |
Link to the form page instead of generic form URL
-rw-r--r-- | src/components/FormListing.tsx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/components/FormListing.tsx b/src/components/FormListing.tsx index dc761b6..2493608 100644 --- a/src/components/FormListing.tsx +++ b/src/components/FormListing.tsx @@ -9,10 +9,10 @@ import Tag from "./Tag"; import colors from "../colors"; -import { Form } from "../api/forms"; +import { AllFormsForm } from "../api/forms"; interface FormListingProps { - form: Form + form: AllFormsForm } function FormListing({ form }: FormListingProps) { @@ -43,7 +43,7 @@ function FormListing({ form }: FormListingProps) { closedTag = <Tag text="CLOSED" color={colors.error}/> }; - return <Link to="/form" css={listingStyle}> + return <Link to={`/form/${form.id}`} css={listingStyle}> <div> <h3 css={{fontSize: "1.5em", marginBottom: "0"}}>{closedTag}{form.title} <FontAwesomeIcon icon={faArrowRight} css={{fontSize: "0.75em", paddingBottom: "1px"}}/></h3> <p css={{marginTop: "5px"}}>{form.description}</p> |