Clarify use of non-standard "align" attribute for mat-dialog-actions
See original GitHub issueDocumentation Feedback
Documentation suggests using the align
attribute to align the content of mat-dialog-actions
directives to the middle or right. However, align
is an obsolete HTML attribute and not valid HTML5, and my IDE’s static code analysis tools rightfully complain about using it. If using align
really is the right way of doing this regardless of W3C standards, this should be clarified in the docs (and possibly be explicitly declared as a property of the MatDialogActions
directive to make IDEs stop complaining).
Affected documentation page: https://material.angular.io/components/dialog/overview
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:6 (5 by maintainers)
Top Results From Across the Web
How to align button right inside Dialog angular material?
You can use the align HTML attribute: <div mat-dialog-content> <p>What's your favorite animal?</p> <mat-form-field> <input matInput ...
Read more >@angular/material | Yarn - Package Manager
This aligns with @angular/cdk , makes clear where symbols originate, and helps safeguard against including unused code. The deprecated style will be removed...
Read more >mat-dialog-actions align right/left/center
Learn how to align mat-dialog-actions buttons in Angular material dialog component.
Read more >@angular/material: Versions | Openbase
schematics: add clarification about directory path format for MDC migration schematic (#25969) ... dialog: Use align as @Input() in MatDialogActions (#24328).
Read more >How To align mat-dialog-actions buttons to the right,center or left
To align mat dialog actions buttons to the right center or left we can make use of `align` attribute.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I would agree that this is confusing. Given that
align
is not standard forHTMLDivElement
, I think it would make sense to turn this into an input w/ documentation (that would also help w/ type-checking; IDE’s and bindings).https://developer.mozilla.org/en-US/docs/Web/API/HTMLDivElement
I could take this as my first issue I think. A fun christmas activity 😁🎅