Skip to content

Conversation

@msynk
Copy link
Member

@msynk msynk commented Dec 1, 2025

closes #11783

Summary by CodeRabbit

  • New Features

    • ActionButton component now supports explicit icon positioning via IconPosition parameter with Start (before content) or End (after content) options.
  • Breaking Changes

    • ReversedIcon boolean parameter replaced with IconPosition enum for improved icon placement control and clarity.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link

coderabbitai bot commented Dec 1, 2025

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Walkthrough

The ReversedIcon boolean parameter in BitActionButton is being replaced with a new BitIconPosition enum containing Start and End values. This refactoring applies consistently across the component class, styles, and demo pages to improve API clarity and provide explicit icon positioning control.

Changes

Cohort / File(s) Summary
New enum type
src/BlazorUI/Bit.BlazorUI/Components/BitIconPosition.cs
Adds BitIconPosition enum with Start (default) and End values for icon placement specification.
Component parameter update
src/BlazorUI/Bit.BlazorUI/Components/Buttons/ActionButton/BitActionButton.razor.cs
Replaces ReversedIcon bool parameter with IconPosition enum parameter; updates CSS class mapping from bit-acb-rvi to bit-acb-eni for End position.
Stylesheet
src/BlazorUI/Bit.BlazorUI/Components/Buttons/ActionButton/BitActionButton.scss
Renames CSS class selector from .bit-acb-rvi to .bit-acb-eni while preserving flex-direction: row-reverse styling.
Demo markup and descriptors
src/BlazorUI/Demo/Client/Bit.BlazorUI.Demo.Client.Core/Pages/Components/Buttons/ActionButton/BitActionButtonDemo.razor*
Updates demo instances and parameter/enum descriptors to use IconPosition instead of ReversedIcon; adds BitIconPosition enum descriptor with Start/End documentation.
Demo samples
src/BlazorUI/Demo/Client/Bit.BlazorUI.Demo.Client.Core/Pages/Components/Buttons/ActionButton/BitActionButtonDemo.razor.samples.cs
Replaces ReversedIcon usage with IconPosition="BitIconPosition.End" in sample code snippets.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

  • Verify all ReversedIcon references are completely replaced with IconPosition across codebase
  • Confirm CSS class rename bit-acb-rvibit-acb-eni is consistent and no orphaned selectors remain
  • Check that enum values (Start, End) are correctly applied in all demo and sample usages

Poem

🐰 A boolean's name caused quite the fuss,
So we replaced it, no further discuss!
Now IconPosition makes it clear—
Start or End, the choice is dear.
Refactoring hops along just right, ✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: renaming a parameter from ReversedIcon to IconPosition in the BitActionButton component, which is directly supported by the changeset across multiple files.
Linked Issues check ✅ Passed The PR successfully addresses the objective from issue #11783 by renaming the ReversedIcon parameter to IconPosition, improving clarity and appropriateness of the parameter name throughout the component.
Out of Scope Changes check ✅ Passed All changes are directly related to the rename objective: new BitIconPosition enum, parameter replacement in BitActionButton, CSS class updates, and demo updates reflect the intended refactoring with no extraneous modifications.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@msynk msynk merged commit f131c6f into bitfoundation:develop Dec 1, 2025
3 checks passed
@msynk msynk deleted the 11783-blazorui-actionbutton-reversedicon-rename branch December 1, 2025 12:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The ReversedIcon parameter name is not appropriate in the BitActionButton component

1 participant