WordPress.org

Make WordPress Core

Opened 9 months ago

Last modified 6 months ago

#47964 new defect (bug)

jQuery Syntax Error when using a colon character in the widget class

Reported by: taskotr Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: Customize Keywords: reporter-feedback
Focuses: javascript, administration Cc:

Description

Some CSS frameworks uses a colon character when defining CSS classes. For example, tailwindcss uses it for Media Queries.

When such class is added to the widget, the Customizer shows a jQuery error:

Uncaught Error: Syntax error, unrecognized expression: unsupported pseudo: w-full

Steps to reproduce:

  1. Activate a default WordPress theme, Twenty Nineteen;
  2. Add md:w-full class to site widgets;
  3. Go to the Customizer;

Attachments (1)

colon_char_in_widget_class.jpg (195.2 KB) - added by taskotr 9 months ago.

Download all attachments as: .zip

Change History (2)

#1 @dlh
6 months ago

  • Keywords reporter-feedback added
  • Version 5.2.2 deleted

Hey @taskotr — are you still able to replicate this issue? If so, can you provide a code sample that causes it with a fresh installation?

Note: See TracTickets for help on using tickets.