Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix design of subscription form in chrome and safari #196

Merged
merged 3 commits into from
Jan 18, 2022

Conversation

apeatling
Copy link
Collaborator

@apeatling apeatling commented Jan 13, 2022

Fixes #169

Fix up the subscription button so it aligns correctly in safari and chrome. Also fix the placeholder text size.

Before After
Screen Shot 2022-01-13 at 10 25 45 AM Screen Shot 2022-01-13 at 10 18 45 AM

Testing Instructions

Because you need a Jetpack connection to test, you will instead need to manually add the following subscription form HTML to source/wp-content/themes/wporg-news-2021/block-template-parts/footer-archive.html in place of the shortcode:

<div class="jetpack_subscription_widget">
                <form action="#" method="post" accept-charset="utf-8" id="subscribe-blog-474">
                    <div class="jetpack-subscribe-count">
                        <p>
                            Join 1 other subscriber </p>
                    </div>
                    <p id="subscribe-email">
                        <label id="jetpack-subscribe-label" class="screen-reader-text" for="subscribe-field-474">
                            Email Address </label>
                        <input type="email" name="email" required="required" value="" id="subscribe-field-474"
                            placeholder="Email Address">
                    </p>

                    <p id="subscribe-submit">
                        <input type="hidden" name="action" value="subscribe">
                        <input type="hidden" name="source" value="https://wordpress.org/news-test/">
                        <input type="hidden" name="sub-type" value="widget">
                        <input type="hidden" name="redirect_fragment" value="474">
                        <button type="submit" class="wp-block-button__link" style="margin-left: 0px;"
                            name="jetpack_subscriptions_widget">
                            Subscribe </button>
                    </p>
                </form>
</div>
@apeatling apeatling self-assigned this Jan 13, 2022
@apeatling
Copy link
Collaborator Author

apeatling commented Jan 13, 2022

Dark version has also been updated:

Before After
Screen Shot 2022-01-13 at 10 40 01 AM Screen Shot 2022-01-13 at 10 38 22 AM
@ryelle
Copy link
Contributor

ryelle commented Jan 13, 2022

Cool, hit cmd-enter without meaning to— words coming soon :)

The sizing is fixed on both footer variations 🎉

On smaller screens (when it hits the single col breakpoint), the block isn't full-width. I don't think your changes introduced this, but it could be fixed here.
small-screen-width

On the dark footer: in firefox, I don't see the placeholder, and in both FF & Chrome, text I type in is invisible (white).
white-text

According to the design, the input text should be 16px, but seems to be 13.333px.

@apeatling
Copy link
Collaborator Author

Will get these changes done on Monday 👍

@apeatling
Copy link
Collaborator Author

Fixed the width and white text, ready for another review @ryelle.

Copy link
Contributor

@ryelle ryelle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good now, thanks for fixing it!

@ryelle ryelle merged commit 65d39ab into trunk Jan 18, 2022
@ryelle ryelle deleted the fix/subscription-form branch January 18, 2022 20:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants