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: 修复scss更新 https://sass-lang.com/documentation/breaking-changes/mi… #61

Merged
merged 1 commit into from
Jan 14, 2025

Conversation

PdxLook
Copy link
Contributor

@PdxLook PdxLook commented Jan 14, 2025

@Ru1ers
Copy link
Member

Ru1ers commented Jan 14, 2025

修改似乎是无意义的。src主包在lint:styles时并没有出现警告及错误。(如果出现警告或报错,可提供复现场景)。

关于@at-root@at-root button#{&} 的位置不需要放在那些通用样式后面。
选择把 @at-root 放在前面的原因主要是为了:
代码组织的逻辑性(按功能分组)
提高代码可读性
遵循"特殊规则在前,通用规则在后"的惯例
但这完全是代码风格的选择,不会影响最终的功能。

@PdxLook
Copy link
Contributor Author

PdxLook commented Jan 14, 2025

@Ru1ers 新的scss为了兼容css的嵌套属性,会报错提示。

参考文档https://sass-lang.com/documentation/breaking-changes/mixed-decls/

@PdxLook
Copy link
Contributor Author

PdxLook commented Jan 14, 2025

image
image

@Ru1ers
Copy link
Member

Ru1ers commented Jan 14, 2025

非常感谢你的建议

经过测试,这个警告会发生在1.79.0之前。也就是说,sass 1.79.0之后不会再出现该警告。(具体原因不清楚。也有可能这个规则被弃用了)
相关pr:#2342
zebra-swiper开发版本使用的sass版本为1.83.0,所以未出现该警告。

但是出于规范性考虑,可能你的建议是对的。合并前需要做出以下更改:
1.在src主包中修改文件
2.运行async-module命令将主包同步至uni_modules发行目录。

@Ru1ers Ru1ers merged commit 3b11f5f into zebra-ui:master Jan 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants