-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
MudText: Replace h6 with span for subtitle typos (#6059) #6061
MudText: Replace h6 with span for subtitle typos (#6059) #6061
Conversation
Codecov ReportBase: 91.52% // Head: 91.53% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## dev #6061 +/- ##
=======================================
Coverage 91.52% 91.53%
=======================================
Files 383 383
Lines 15019 15019
=======================================
+ Hits 13746 13747 +1
+ Misses 1273 1272 -1
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
Not sure about this. Because it is visually breaking. It solves a specific but is it a good idea for all scenarios? |
Seems like span used to be used too |
For me at least it's annoying every time I see the text not aligned properly. Maybe it could be included in the 7.x version with the other breaking changes? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How are you centering the text?
The text becomes vertically centered when I change it to use the |
I encountered this bug while using MudBlazor today and I came here to make sure there was a plan to address it. I want to answer @mikes-gh 's question above:
This is a very important issue to fix for accessibility purposes for all scenarios. People who use assistive technology often navigate pages by the heading elements on the page. Mobile and desktop screen readers can list and read the headings on a page to help a user find the section they want without reading the whole page top to bottom. The When developers use the At a practical level this bug could create a scenario like the example below without the developers realizing it. <h1>Main Heading</h1>
<h2>Topic 1</h2>
...Some content here
<h6>This is supposed to be text styled as a subtitle, but is now a misplaced heading</h6>
<h3>Subtopic 1</h3> This could be confusing for users, because now the I was not able to reproduce the vertical alignment issue mentioned above, but it doesn't surprise me because I hope you can find a way to fix and release this as soon as possible because of the potential impact this has on the accessibility of web apps using MudBlazor. |
I would root for replacing the |
@dennisrahmen When is version 7 going to be released? Any reason not to even try using MudBlazor is an authoring tool and as such has take accessibility seriously. It should make creating accessible web interfaces easier and avoid creating accessibility issues that developers might miss. |
@lortimer the last thing I read, from I think @henon, is that the v7 release is already overdue. Regarding:
If they are not upgrading to v7 then they also might not upgrade to v6.x, as v7 does only include minor breaking changes compared to most other libraries I use. Thats my opinion, I am just a user here. |
@henon should we add this to v7 project? |
I changed the target branch to v7. Are there any other accesibility changes that should be made in MudText or is everything else fine? |
977dcf5
to
c09f1c7
Compare
Target branch can be changed back to dev @henon |
Thank you for the patience, I know it has been a long wait. v7.0.0 is finally being actively worked on. All breaking changes are summarized in the v7.0.0 Migration Guide #8447 |
This PR broke some tests and they are not flaky, once I fetched https://github.com/MudBlazor/MudBlazor/actions/runs/8458390892/attempts/2 once I fetched this change I see locally the same picture |
Seems ScrollToTopTest is the only one |
Regression inadvertantely caused by MudBlazor#6061 because the styles in the landing page were set up to modify the html headers themselves instead of just changing the typography variables.
Instead of initializing the text with
<h6>
tag forTypo.subtitle1
andTypo.subtitle2
, initializes it with the more generic inline container:<span>
tag.Description
Resolves #6059
When using
Typo.subtitle2
onMudText
, the text is not centered vertically, causing it to look strange with all other vertically centered text.After further investigation with inspect element, it turns out that the text is being initialized using the tag
<h6>
, causing this inconsistency.How Has This Been Tested?
Visually
Types of changes
The text "The University of Somewhere" with
Typo.subtitle2
using<h6>
:The text "The University of Somewhere" with
Typo.subtitle2
using<span>
:Direct comparison.
<h6>
on the left,<span>
on the right.Checklist:
dev
).