Add explicit icon and label support for button CSS components.

Review Request #13289 — Created Sept. 26, 2023 and submitted

Information

Review Board
release-6.x

Reviewers

This updates rb-c-button to include __icon and __label parts for
defining buttons containing both icons and labels in a consistent
manner. This will be styled with an appropriate gap in-between the two,
when both are present and visible.

Buttons now use flexbox for layout to enable this, and to ensure that
everything lines up correctly.

There are two new macros for customizing icons:

  • #rb-ns-ui.buttons.set-icon-only() will hide the label on a button
    and update the padding so the button looks correct with just an icon.

  • #rb-ns-ui.buttons.set-fa-icon() takes a FontAwesome icon variable
    and set it on the __icon part.

Tested with existing buttons, button groups, and menu buttons throughout
the UI.

Tested with some in-progress icon-only and icon-enabled buttons.

Summary ID
Add explicit icon and label support for button CSS components.
This updates `rb-c-button` to include `__icon` and `__label` parts for defining buttons containing both icons and labels in a consistent manner. This will be styled with an appropriate gap in-between the two, when both are present and visible. Buttons now use flexbox for layout to enable this, and to ensure that everything lines up correctly. There are two new macros for customizing icons: * `#rb-ns-ui.buttons.set-icon-only()` will hide the label on a button and update the padding so the button looks correct with just an icon. * `#rb-ns-ui.buttons.set-fa-icon()` takes a FontAwesome icon variable and set it on the `__icon` part.
1c3c1a04c049e41f7abc654f065d481887a8bc0f
chipx86
david
  1. Ship It!
  2. 
      
maubin
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-6.x (fe7eaf7)
Loading...