-
-
Notifications
You must be signed in to change notification settings - Fork 51.6k
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: resolve the style not taking effect error #52210
Conversation
…icity (ant-design#51936)" This reverts commit a5dc406.
|
👁 Visual Regression Report for PR #52210 Failed ❌
Important There are 4 diffs found in this PR: 🔄 4 changed.
|
WalkthroughThis pull request addresses a bug fix related to style issues in the Layout Sider component. It reverts a previous commit to resolve the problem of styles not taking effect by adjusting the CSS selectors and style hooks. Changes
|
@@ -69,7 +69,7 @@ const genSiderStyle: GenerateStyle<LayoutToken, CSSObject> = (token) => { | |||
transition: `all ${motionDurationMid}`, | |||
}, | |||
|
|||
[`${antCls}-layout &-zero-width`]: { | |||
'&-zero-width': { |
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.
Ensure that the removal of ${antCls}-layout
from the selector does not affect other components relying on this style. Verify that the new selector &-zero-width
is scoped correctly.
@@ -139,7 +139,9 @@ const genSiderStyle: GenerateStyle<LayoutToken, CSSObject> = (token) => { | |||
|
|||
export default genStyleHooks( | |||
['Layout', 'Sider'], | |||
(token) => [genSiderStyle(token)], | |||
(token) => ({ |
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.
Ensure that the new structure of genStyleHooks
with the updated token mapping does not introduce any regressions in the style application.
More templates
commit: |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #52210 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 763 763
Lines 13643 13643
Branches 3560 3560
=========================================
Hits 13643 13643 ☔ View full report in Codecov by Sentry. |
看下 visual diff 对不对 |
同步一下 master 再看看,前面快照有问题的 |
相当于回滚了 #51936 , @aojunhao123 看看是否符合预期 |
嗯,看着没问题 |
…icity (#51936)"
This reverts commit a5dc406.
中文版模板 / Chinese template
🤔 This is a ...
🔗 Related Issues
💡 Background and Solution
如上,整个 sider 都加权重就好了。 一开始就是多一个选择器的,看这里:https://github.com/ant-design/ant-design/pull/50780/files#diff-2dfadcf4cb6e7f95c8edf70cc3750abd37a1f8996c4301a40eefb94dd78c118e
📝 Change Log