-
-
Notifications
You must be signed in to change notification settings - Fork 49.2k
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
style: adjust upload error icon #24160
Conversation
是否需要调整这个 icon ,如果要改,我再更新 snap |
双色改单色应该不是预期的,如果要调整颜色。应该也是双色变成红色才对。 |
这样? |
这个颜色是 less 中使用了 |
Two 看起来更饱满一些,可以试下把 less 中的变量 共享出来用,大佬你觉得呢? |
ci failed |
components/style/themes/export.ts
Outdated
@@ -0,0 +1,3 @@ | |||
import defaultLess from './default.less'; | |||
|
|||
export default defaultLess; |
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.
这样可能有坑,用户没有 less-loader 就挂了。
components/upload/UploadList.tsx
Outdated
@@ -87,7 +89,9 @@ export default class UploadList extends React.Component<UploadListProps, any> { | |||
return iconRender(file, listType); | |||
} | |||
const isLoading = file.status === 'uploading'; | |||
const fileIcon = isImgUrl && isImgUrl(file) ? <PictureOutlined /> : <FileTwoTone />; | |||
const { errorColor } = defaultLess; |
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.
errorColor 直接用 @ant-design/colors
里的 red 好了。
/rebase |
4ce7ec1
to
d4662ed
Compare
Codecov Report
@@ Coverage Diff @@
## master #24160 +/- ##
=======================================
Coverage 98.81% 98.81%
=======================================
Files 363 363
Lines 7280 7280
Branches 2006 2016 +10
=======================================
Hits 7194 7194
Misses 86 86 Continue to review full report at Codecov.
|
下面 4 个 path ,中间 2 个 fill 是 |
这些也是算出来。 |
🥺🥺 找不到 公式 |
|
components/style/themes/default.less
Outdated
@@ -15,6 +15,7 @@ | |||
@success-color: @green-6; | |||
@processing-color: @blue-6; | |||
@error-color: @red-5; | |||
@error-hover-color: color(~`colorPalette('@{error-color}', 1) `); |
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.
这个变量 名字 是不是 不太好
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.
不用起变量名,直接用就好了。
components/upload/style/index.less
Outdated
svg path[fill="#e6f7ff"] { | ||
fill: color(~`colorPalette('@{error-color}', 1) `); | ||
&:first-child, | ||
&:last-child[fill="#1890ff"] { |
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.
不要加 first-child,last-child
/rebase |
ci 挂了 |
Co-authored-by: 偏右 <afc163@gmail.com>
[中文版模板 / Chinese template]
🤔 This is a ...
🔗 Related issue link
💡 Background and solution
Before
After
📝 Changelog
☑️ Self Check before Merge