Skip to content
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

fix: auto margin in flexbox #667

Merged
merged 4 commits into from Sep 13, 2021
Merged

fix: auto margin in flexbox #667

merged 4 commits into from Sep 13, 2021

Conversation

temper357
Copy link
Contributor

Closes #666

修复当 flex item 配置 margin auto 且 flex 容器上存在 align-items 或者 justify-content 属性时 margin auto 未生效。

fix:规范中有写 flex item 的 margin auto 优先级高于 flex 容器上的对齐类属性(align-items/align-self/justify-content) https://www.w3.org/TR/css-flexbox-1/#auto-margins , 这种 case 下应该跳过对齐类属性的对齐逻辑。

@temper357 temper357 added this to In Progress in Browser Features via automation Sep 9, 2021
@temper357 temper357 added this to the 0.9 milestone Sep 9, 2021
@wssgcg1213 wssgcg1213 merged commit 53e5535 into main Sep 13, 2021
@wssgcg1213 wssgcg1213 deleted the fix/flex-auto-margin branch September 13, 2021 06:13
Browser Features automation moved this from In Progress to Done Sep 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

Flex 布局中 align-item 设置时 child 设置 margin auto 未居中
3 participants