Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LinkControl: remove unused CSS flex properties #58931

Closed
afercia opened this issue Feb 12, 2024 · 1 comment · Fixed by #58934
Closed

LinkControl: remove unused CSS flex properties #58931

afercia opened this issue Feb 12, 2024 · 1 comment · Fixed by #58934
Assignees
Labels
CSS Styling Related to editor and front end styles, CSS-specific issues. [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Package] Block editor /packages/block-editor [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended

Comments

@afercia
Copy link
Contributor

afercia commented Feb 12, 2024

Description

While reviewing all the CSS order and *-reverse properties used in the editor I spotted a couple CSS declarations for the LinkControl that don't do anything and seem a leftover.

.block-editor-link-control__drawer {
display: flex; // allow for ordering.
order: 30;
flex-direction: column;
flex-basis: 100%; // occupy full width.
}

Both order: 30; and flex-basis: 100%; would take effect if this element was a flex item. However, the parend isn't a flexbox congtainer, it is display: block;;.

The browser dev tools shows these two properties have no effect:

Screenshot 2024-02-12 at 12 45 12

Introduced in d142cb0
See related discussion on #47328 (comment)

I thik the whole ruleset is now a leftover of a previous implementation in the original PR and can be safely removed.

Step-by-step reproduction instructions

  • Add a link.
  • Open the link settings UI.
  • In the browser dev tools, select the element with CSS class block-editor-link-control__drawer
  • Observe the flex and flex item properties set on the element don't do anything.

Screenshots, screen recording, code snippet

No response

Environment info

No response

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

@afercia afercia added [Type] Bug An existing feature does not function as intended [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Package] Block editor /packages/block-editor CSS Styling Related to editor and front end styles, CSS-specific issues. labels Feb 12, 2024
@afercia
Copy link
Contributor Author

afercia commented Feb 12, 2024

Re:
display: flex; // allow for ordering.

Nothing that display: flex; allows for ordering of the childen.

@afercia afercia self-assigned this Feb 12, 2024
@github-actions github-actions bot added the [Status] In Progress Tracking issues with work in progress label Feb 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CSS Styling Related to editor and front end styles, CSS-specific issues. [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Package] Block editor /packages/block-editor [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant