-
Notifications
You must be signed in to change notification settings - Fork 264
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
feat(toast): v14 #2795
Open
irisSong
wants to merge
5
commits into
jdf2e:feat_v3.x
Choose a base branch
from
irisSong:3.0-toast
base: feat_v3.x
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+79
−62
Open
feat(toast): v14 #2795
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -882,6 +882,7 @@ | |
"sort": 1, | ||
"show": true, | ||
"taro": true, | ||
"v14": true, | ||
"author": "VickyYe" | ||
} | ||
] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -52,8 +52,9 @@ | |
flex-direction: column; | ||
justify-content: center; | ||
align-items: center; | ||
min-width: 30%; | ||
max-width: 95.7%; | ||
min-width: 96px; | ||
max-width: 60%; | ||
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. 根据什么换算为百分比?视觉规范区分了带Icon 和不带 Icon 的最大宽度。 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. 根据视觉给的宽度除以375计算的 带描述的有设置最大宽度 |
||
// max-width: 224px; | ||
font-size: $toast-text-font-size; | ||
text-align: $toast-inner-text-align; | ||
padding: $toast-inner-padding; | ||
|
@@ -62,6 +63,11 @@ | |
border-radius: $toast-inner-border-radius; | ||
color: $toast-font-color; | ||
|
||
&-descrption { | ||
max-width: 68.2%; | ||
// max-width: 256px; | ||
} | ||
|
||
&-normal { | ||
word-break: normal; | ||
word-wrap: normal; | ||
|
@@ -101,19 +107,18 @@ | |
&-text { | ||
color: #ffffff; | ||
text-align: $toast-inner-text-align; | ||
&-empty { | ||
margin-bottom: -8px; | ||
} | ||
line-height: 20px; | ||
} | ||
|
||
&-title { | ||
color: #ffffff; | ||
font-size: $toast-title-font-size; | ||
font-weight: 500; | ||
text-align: $toast-inner-text-align; | ||
line-height: 22px; | ||
} | ||
|
||
&-icon { | ||
.nut-icon { | ||
width: 24px; | ||
height: 24px; | ||
color: #ffffff; | ||
|
@@ -124,7 +129,7 @@ | |
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
margin-bottom: 8px; | ||
margin: 3px 0 5px; | ||
color: #ffffff; | ||
|
||
&-icon { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
💡 Codebase verification
发现参数顺序不一致问题
在示例代码中发现了
openToast
函数存在参数顺序不一致的问题:type, title?, duration?, icon?, content?
type, content, duration?, icon?, title?
这些示例代码中的调用方式也与各自的函数定义不匹配,需要统一参数顺序以避免混淆。
🔗 Analysis chain
验证参数顺序变更的影响范围
openToast
函数的参数顺序发生了变化,将title
移到第二位,content
移到最后。这种变更可能会影响其他组件的调用。🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 57
Script:
Length of output: 1354
Script:
Length of output: 4289