Add d-contents display class, Fix missing gap between MessageBox action buttons#11391
Merged
ScarletKuro merged 1 commit intoMudBlazor:devfrom May 23, 2025
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds a new d-contents utility class to enable display: contents and replaces inline margins in dialog actions with a gap property to unify spacing.
- Introduces
.d-contentsin the display utilities - Switches from per-child margins to
gap: 8pxin dialog actions - Applies
d-contentstoMudMessageBoxaction wrapper
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| _display.scss | Adds .d-contents display utility |
| _dialog.scss | Replaces manual margins with gap: 8px |
| MudMessageBox.razor | Wraps action buttons in a div with d-contents |
Comments suppressed due to low confidence (1)
src/MudBlazor/Components/MessageBox/MudMessageBox.razor:31
- Add or update a unit or snapshot test to cover the new
d-contentswrapper inMudMessageBoxactions, verifying that the display style propagates correctly.
<div tabindex="-1" class="d-contents">
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dev #11391 +/- ##
==========================================
- Coverage 91.11% 91.10% -0.01%
==========================================
Files 465 465
Lines 14401 14407 +6
Branches 2785 2788 +3
==========================================
+ Hits 13121 13126 +5
+ Misses 643 642 -1
- Partials 637 639 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
ScarletKuro
approved these changes
May 23, 2025
This was referenced Aug 1, 2025
Closed
This was referenced Aug 14, 2025
This was referenced Aug 25, 2025
This was referenced Oct 6, 2025
This was referenced Nov 12, 2025
This was referenced Dec 12, 2025
Closed
Closed
This was referenced Dec 29, 2025
This was referenced Jan 9, 2026
Closed
This was referenced Feb 10, 2026
Closed
This was referenced Feb 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Description
We were missing a class for
display: contentsand the gap in the message box action buttons was not the same as the dialog because of the extra div in the way. Addingd-contentslets the style pass through.I also replaced the inline margin implementation with a cleaner use of
gapsince it was already a flex display. It's unlikely that many people are relying on the old behaviour.How Has This Been Tested?
visually
Type of Changes
Before
After
Checklist
dev).