diff --git a/src/components/buttonCTA.jsx b/src/components/buttonCTA.jsx new file mode 100644 index 0000000..64cfb35 --- /dev/null +++ b/src/components/buttonCTA.jsx @@ -0,0 +1,29 @@ +import React from "react" +import PropTypes from "prop-types" +import { Link } from "gatsby" + +import * as ROUTES from "../global/routes" + +const ButtonCTA = ({ text, variant }) => { + let className = "get-started-btn" + if (variant === "secondary") { + className = "btn-get-started" + } + return ( + + {text} + + ) +} + +export default ButtonCTA + +ButtonCTA.propTypes = { + text: PropTypes.string, + variant: PropTypes.string, +} + +ButtonCTA.defaultProps = { + text: "Inscription", + variant: "primary", +} diff --git a/src/components/header.jsx b/src/components/header.jsx index 551cf94..9501974 100644 --- a/src/components/header.jsx +++ b/src/components/header.jsx @@ -2,16 +2,17 @@ import React from "react" import { Link } from "gatsby" import PropTypes from "prop-types" +import ButtonCTA from "./buttonCTA" + import * as ROUTES from "../global/routes" const Header = ({ siteTitle }) => ( -