Skip to content

Varia: Text formatting is not working for form fields #4827

Open

Description

Quick summary

The text formatting for example bold, italic is not being applied on the field labels from the editor to preview. It works in Editor but on live site, theme CSS overrides the formatting.

Steps to reproduce

  1. Add a contact form.
  2. Change the field label styling to italic and remove the bold effect.
  3. Preview the page.

What you expected to happen

It should apply Italic and bold formatting as seen in the editor.
Screenshot of the editor:
https://d.pr/i/I8sira/CnJMpCn8i6

Screenshot of the preview:
https://d.pr/i/VGqVbT/f1l8niXJLX

What actually happened

The following theme CSS overrides the editor style/formatting.
.contact-form label {
margin-bottom: .25em;
float: none;
font-weight: 700;
display: block;
}

Context

No response

Operating System

No response

Browser

No response

Simple, Atomic or both?

No response

Theme-specific issue?

No response

Other notes

No response

Reproducibility

Consistent

Severity

Some (< 50%)

Available workarounds?

Yes, easy to implement

Workaround details

If the user is on a premium plan then we can share CSS code. For example, this one to remove the bold formatting.
.contact-form label {
font-weight: normal;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions