Skip to content

[Bug] Elementor color control does not allow more than 7 characters #2737

@ddenev

Description

@ddenev

Hi,

Not allowing more than 7 characters in the color control brings the problem where when I want to manually enter a transparency value for the rgba function, the whole value is rewritten.

I have to say this is NOT a issue with the native WordPress color picker as stated in #1547 .

The following Elementor files have a color control input element with the 'maxlength' attribute set to 7:

  • includes/controls/box-shadow.php
  • includes/controls/color.php
  • includes/controls/text-shadow.php

When I manually set the maxlength to 25 (to accommodate an rgba value, e.g. 'rgba(255,255,255,0.85)') then everything works fine - i.e. I am able to manually set the transparency within the control. When it is set to 7 then all the above problems happen. The problem is every update of Elementor removes my fix.

So, it is not a problem with WordPress. Please set the maxlength to at least 25.

Thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIndicates a bug with one or multiple components.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions