Skip to content

Add inheritance and variant options for button groups and individual buttons#18886

Open
NDCallahan wants to merge 3 commits into
Budibase:masterfrom
NDCallahan:feat/button-group-conditions-and-sizing
Open

Add inheritance and variant options for button groups and individual buttons#18886
NDCallahan wants to merge 3 commits into
Budibase:masterfrom
NDCallahan:feat/button-group-conditions-and-sizing

Conversation

@NDCallahan

@NDCallahan NDCallahan commented May 31, 2026

Copy link
Copy Markdown
Contributor

Description

This pull request introduces a full inheritance system for button style and size within Button Groups, along with group-level conditions, collapsed-button improvements, and several UI/UX enhancements. These changes make Button Groups more flexible, reduce duplication, and provide a clearer editing experience.

Addresses

Overview

Added inheritance and conditional styling support to Button Groups, allowing individual buttons to inherit style properties from the group level and enabling dynamic updates via conditions.

Key Changes

Button Style Inheritance

Button Groups now act as a styling parent:

  • Added Variant, Size, Disabled, and Quiet controls to the group-level "Button style" section.
  • Individual buttons can now set their type and size to "Inherit", following the group's buttonType and buttonSize.
  • Buttons with explicit values override the group settings.
  • Newly created buttons default to "Inherit".
  • Added contextual InfoDisplay explaining inheritance behavior.

Group-Level Conditions

Button Groups now support their own Conditions section:

  • Group-level conditions can update any button style property.
  • All buttons set to "Inherit" automatically respond to these conditional changes.
  • Enables responsive, state-driven styling.

UI/UX Improvements

Enhancements to make editing clearer and more intuitive:

  • Button settings UI now injects "Inherit" options for variant and size.
  • Added an informational message explaining inheritance behavior.
  • Improved nested settings handling and edge-case logic.

Collapsed Button Support

The collapsed button now participates fully in the inheritance system:

  • Collapsed button uses the group's Variant setting.
  • Updated CollapsedButton to respond to group-level buttonType.

How Has This Been Tested?

Manual testing in the builder — verified inheritance, overrides, and conditions on both individual buttons and the collapsed button.

Checklist

  • I have self-reviewed my own code
  • I have commented my code where necessary
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing tests pass locally with my changes

Summary by cubic

Adds style/size inheritance and group-level conditions to Button Groups so buttons follow group settings or override when needed. Collapsed buttons now use the group Variant. Also adds optional transparent app backgrounds. Fixes #18016.

  • New Features
    • Group-level style: Variant/Size/Quiet/Disabled controls; conditions can change them; buttons set to “Inherit” update automatically.
    • Per-button overrides: “Inherit” option for Variant/Size on individual buttons; new buttons default to “inherit” for both; added an info tip explaining inheritance.
    • Collapsed button: applies the group Variant (cta/primary/secondary/warning/overBackground).
    • Transparent backgrounds: transparentBackground makes the primary app background transparent across themes.

Written for commit a80d5e1. Summary will update on new commits.

Review in cubic

@NDCallahan NDCallahan force-pushed the feat/button-group-conditions-and-sizing branch from 4a42530 to f393dbd Compare May 31, 2026 03:56
…he individual button level. added variant to collapsed button as well as sizing in conditions
@NDCallahan NDCallahan force-pushed the feat/button-group-conditions-and-sizing branch from f393dbd to 44c7436 Compare May 31, 2026 03:57
@NDCallahan NDCallahan marked this pull request as ready for review May 31, 2026 04:59
Comment thread packages/bbui/src/ButtonGroup/CollapsedButtonGroup.svelte Outdated
@github-actions github-actions Bot added the stale label Jun 8, 2026
@NDCallahan

Copy link
Copy Markdown
Contributor Author

No no. Not stale! 👍🏼

@github-actions github-actions Bot removed the stale label Jun 9, 2026
@github-actions github-actions Bot added the stale label Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ Button Group Component ] - Allow Conditions to Change Size of Existing Buttons in a Button Group

2 participants