-
Notifications
You must be signed in to change notification settings - Fork 0
Optimize header layout performance with flexbox mixins #6
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
base: header-layout-optimization-pre
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -92,3 +92,40 @@ | |||||
| -moz-user-select: none; | ||||||
| -ms-user-select: none; | ||||||
| } | ||||||
|
|
||||||
| // --------------------------------------------------- | ||||||
|
|
||||||
| //Flexbox | ||||||
|
|
||||||
| @mixin flexbox() { | ||||||
| display: -webkit-box; | ||||||
| display: -moz-box; | ||||||
| display: -ms-flexbox; | ||||||
| display: -webkit-flex; | ||||||
| display: flex; | ||||||
| } | ||||||
|
|
||||||
| @mixin inline-flex() { | ||||||
| display: -webkit-inline-box; | ||||||
| display: -webkit-inline-flex; | ||||||
| display: -moz-inline-box; | ||||||
| display: -ms-inline-flexbox; | ||||||
| display: inline-flex; | ||||||
| } | ||||||
|
|
||||||
|
|
||||||
| @mixin align-items($alignment) { | ||||||
| -webkit-box-align: $alignment; | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P2: The old flexbox syntax ( Prompt for AI agents |
||||||
| -webkit-align-items: $alignment; | ||||||
| -ms-flex-align: $alignment; | ||||||
| -ms-align-items: $alignment; | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P2: Prompt for AI agents |
||||||
| align-items:$alignment; | ||||||
| } | ||||||
|
|
||||||
| @mixin order($val) { | ||||||
| -webkit-box-ordinal-group: $val; | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P2: Prompt for AI agents
Suggested change
|
||||||
| -moz-box-ordinal-group: $val; | ||||||
| -ms-flex-order: $val; | ||||||
| -webkit-order: $val; | ||||||
| order: $val; | ||||||
| } | ||||||
Uh oh!
There was an error while loading. Please reload this page.
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.
P2: Adding
display: flexto.small-actionmakes thefloatdeclarations on its children (.topic-avatar,.avatar,button) dead code—per the CSS spec,floathas no effect on flex items. These should be removed to avoid confusion and ensure the layout relies solely on flexbox properties (e.g., usemargin-left: autoonbuttoninstead offloat: rightto push it to the right). Theclear: bothon.small-actionitself is also now unnecessary.Prompt for AI agents