Skip to content

Commit

Permalink
faq links changed
Browse files Browse the repository at this point in the history
  • Loading branch information
fabiolalombardim committed Jul 16, 2023
1 parent ef49efd commit df3dea4
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 13 deletions.
15 changes: 11 additions & 4 deletions src/modules/common/TitleBlock.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Grid, Paper, styled, Tooltip, Typography } from "@material-ui/core"
import { Grid, Link, Paper, styled, Tooltip, Typography } from "@material-ui/core"
import React from "react"
import { ReactElement } from "react-markdown/lib/react-markdown"
import { InfoRounded } from "@material-ui/icons"
Expand Down Expand Up @@ -45,9 +45,16 @@ interface Props {
description: ReactElement | string
tooltip?: boolean
tooltipText?: string
tooltipLink?: string
}

export const TitleBlock: React.FC<Props> = ({ title = "", description, tooltip = false, tooltipText = "" }) => {
export const TitleBlock: React.FC<Props> = ({
title = "",
description,
tooltip = false,
tooltipText = "",
tooltipLink = ""
}) => {
return (
<StyledGrid container direction="row" justifyContent="space-between">
<Grid item xs={12} container direction="row" alignItems="flex-end">
Expand All @@ -61,9 +68,9 @@ export const TitleBlock: React.FC<Props> = ({ title = "", description, tooltip =
<CustomTooltip placement="bottom" title={description}>
<InfoIconInput />
</CustomTooltip>
<HashLink smooth to="/faq#how-to-create-a-dao-on-homebase" target={"_blank"}>
<Link target="_blank" href={`https://faq.tezos-homebase.io/homebase-faq/${tooltipLink}`} color="secondary">
<CustomTooltipText color="secondary">{tooltipText} </CustomTooltipText>
</HashLink>
</Link>
</CustomTextContainer>
) : null}
</Grid>
Expand Down
15 changes: 6 additions & 9 deletions src/modules/creator/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ import {
styled,
useMediaQuery,
useTheme,
Theme
Theme,
Link
} from "@material-ui/core"
import ProgressBar from "react-customizable-progressbar"
import { useHistory } from "react-router"
Expand Down Expand Up @@ -125,10 +126,6 @@ export const DAOCreate: React.FC = () => {
const theme = useTheme()
const isMobile = useMediaQuery(theme.breakpoints.down("sm"))

const goToFAQ = (): void => {
history.push("/faq")
}

useEffect(() => {
mixpanel.unregister("daoAddress")
mixpanel.unregister("daoType")
Expand Down Expand Up @@ -156,10 +153,10 @@ export const DAOCreate: React.FC = () => {
</Box>
</ProgressBar>
<Box>
<FAQClickToAction onClick={goToFAQ}>New to DAOs?</FAQClickToAction>
<FAQClickToAction style={{ textDecoration: "underline" }} onClick={goToFAQ}>
Read our FAQ
</FAQClickToAction>
<FAQClickToAction>New to DAOs?</FAQClickToAction>
<Link target="_blank" href="https://faq.tezos-homebase.io" color="secondary">
<FAQClickToAction style={{ textDecoration: "underline" }}>Read our FAQ</FAQClickToAction>
</Link>
</Box>
<StyledStepper activeStep={step} orientation="vertical">
{STEPS.map(({ title, path }: StepInfo, index: number) => (
Expand Down
1 change: 1 addition & 0 deletions src/modules/creator/steps/Governance.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -897,6 +897,7 @@ export const Governance: React.FC = () => {
title={"Proposals & Voting"}
tooltipText={"Proposals and Voting"}
tooltip={true}
tooltipLink={"how-to-configure-your-dao-in-homebase/configure-proposal-and-voting"}
description={"These settings will define the duration, support and approval required for proposals."}
></TitleBlock>

Expand Down
1 change: 1 addition & 0 deletions src/modules/creator/steps/Quorum.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,7 @@ export const Quorum: React.FC = () => {
}
tooltipText={"Quorum"}
tooltip={true}
tooltipLink={"how-to-configure-your-dao-in-homebase/configure-proposal-and-voting"}
></TitleBlock>

<Formik
Expand Down

0 comments on commit df3dea4

Please sign in to comment.