themes icon indicating copy to clipboard operation
themes copied to clipboard

Contact form block dropdown arrow wrapping under field in Assembler theme

Open marissaexplores opened this issue 1 year ago • 3 comments

Quick summary

The dropdown arrow is under the dropdown field. It should be inline on the right side of the field.

contact-form-dropdown

Steps to reproduce

  1. Install and activate Assembler theme
  2. Add a contact form to any page.
  3. Add a dropdown field to the form
  4. View the arrow under the form.

A clear and concise description of what you expected to happen.

The arrow should be displayed on the right side of the field, inline with the text.

What actually happened

The arrow is displayed under the dropdown field.

Impact

Some (< 50%)

Available workarounds?

Yes, easy to implement

If the above answer is "Yes...", outline the workaround.

Using this CSS as a workaround:

.contact-form .contact-form__select-wrapper::after {
  right: 15px;
  top: 50%;
}

Platform (Simple and/or Atomic)

Simple, Atomic

Logs or notes

I have tested the dropdown field on other themes like Twenty Twenty-Four, Annalee, and Outland. The issue does not occur on those themes. So it seems to only be an issue when using the Assembler theme.

marissaexplores avatar Aug 23 '24 16:08 marissaexplores

I have tested the dropdown field on other themes like Twenty Twenty-Four, Annalee, and Outland. The issue does not occur on those themes. So it seems to only be an issue when using the Assembler theme.

Ideally there's a solution that resolves this as other themes does.

richtabor avatar Aug 26 '24 21:08 richtabor

8694098-zd

Recent build where the customer specifically requested for a dropdown field in their form. I used the CSS workaround for now.

pauloeaquino avatar Sep 10 '24 06:09 pauloeaquino

Support References

This comment is automatically generated. Please do not edit it.

  • [ ] 8694098-zen

github-actions[bot] avatar Sep 10 '24 06:09 github-actions[bot]

@MaggieCabrera are you still planning on working on this?

richtabor avatar Nov 08 '24 15:11 richtabor

@MaggieCabrera are you still planning on working on this?

Sorry, I think you assigned me to this and it got lost into a sea of notifications, I'm looking at it

MaggieCabrera avatar Nov 14 '24 10:11 MaggieCabrera

I'm investigating this. So far I know that the culprit is this line:

https://github.com/Automattic/themes/blob/fb9d983e465d378324498bc59d90bc1c0a4a6526/assembler/style.css#L75

It looks like grunion (I thought that was deprecated, but some of the code lives in jetpack apparently) is doing some weird class swapping around, and if we modify the padding of the input element it preaks the arrow for the select. It's really hard to debug because the plugin is doing something with class swapping and rewriting the CSS, so it's not as simple as overriding the class. It was a matter of trial and error to actually verify that the selector apparently causing this problem is in fact input:not([type="submit"]):not([type="radio"]) when the element we are targeting is a select!!!

My suggestion is to remove the padding altogether or to target only the specific types that we want to modify and not try and target the general input element for this.

MaggieCabrera avatar Nov 14 '24 10:11 MaggieCabrera

https://github.com/Automattic/jetpack/pull/40206 should fix this, https://github.com/Automattic/themes/pull/8418 is a last resort in case that didn't get merged

MaggieCabrera avatar Nov 15 '24 09:11 MaggieCabrera