Skip to content

Commit

Permalink
fix: fix bug with InputSection mobile UI
Browse files Browse the repository at this point in the history
  • Loading branch information
jinhojang6 committed Dec 11, 2024
1 parent 8c292b8 commit 20bea9e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@

.mdx-input-cta-section__message {
display: block;
margin-top: 12px;
position: absolute;
bottom: -32px;
}

form .mdx-input-cta-section__cta {
Expand All @@ -64,6 +65,8 @@ form .mdx-input-cta-section__cta {

@include utils.responsive('sm', 'down') {
.mdx-input-cta-section__container {
position: relative;

.mdx-input-cta-section__form {
margin-bottom: -24px;
flex-direction: column;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,16 @@ export const InputCTASection: React.FC<InputCTASectionProps & Props> = ({
const [formState, setFormState] = React.useState({ email: '', name: '' })
const [message, setMessage] = React.useState('')

const errorMessage =
'There was an error submitting the form. Please try again.'
const errorMessage = 'There was an error submitting the form.'

const handleSubmit = async (e: any) => {
e.preventDefault()

if (!formState?.email) {
setMessage('Please enter an email address')
return
}

try {
const res = await fetch(
`https://odoo.logos.co/website_mass_mailing/subscribe_ghost`,
Expand Down

0 comments on commit 20bea9e

Please sign in to comment.