Skip to content

[Bug]: sp-button label still appears when visibility is set to hidden #5121

Open
@adixon-adobe

Description

@adixon-adobe

Code of conduct

  • I agree to follow this project's code of conduct.

Impacted component(s)

sp-button

Expected behavior

If I set the css visibility: hidden on a component, it should hide. We sometimes use this technique when controls that can be hidden/shown would affect layout if they were removed. We noticed a regression when updating from 0.40.3 to 1.1.1 due to this change.

Actual behavior

The label still appears on Chrome/Safari (on Firefox it's still hidden). It looks like the label has an explicit visibility: visible css directive.

Screenshots

Image

What browsers are you seeing the problem in?

Chrome, Safari

How can we reproduce this issue?

  1. Go to the sp-button doc page
  2. Override the css for a button to add visibility: hidden;

Sample code or abstract reproduction which illustrates the problem

No response

Severity

None

Logs taken while reproducing problem

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions