-
Notifications
You must be signed in to change notification settings - Fork 287
fix: 已适配组件, demo不在环境判断+demo优化 #2388
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
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
0bd4ccb
fix(price): demo优化
irisSong 9f247c6
fix(countdown): demo中已适配组件不在环境判断
irisSong 8747782
fix: demo增加header
irisSong b67661d
fix(divider): demo优化
irisSong 93088cb
fix(switch): demo 优化
irisSong ebe6906
fix: 合并线上分支
irisSong 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 was deleted.
Oops, something went wrong.
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
| @@ -1,11 +1,11 @@ | ||
| import React from 'react' | ||
| import { Divider } from '@nutui/nutui-react' | ||
| import { Cell, Divider } from '@nutui/nutui-react' | ||
|
|
||
| const Demo1 = () => { | ||
| return ( | ||
| <> | ||
| <Cell> | ||
| <Divider /> | ||
| </> | ||
| </Cell> | ||
| ) | ||
| } | ||
| export default Demo1 |
This file contains hidden or 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 |
|---|---|---|
| @@ -1,11 +1,11 @@ | ||
| import React from 'react' | ||
| import { Divider } from '@nutui/nutui-react' | ||
| import { Cell, Divider } from '@nutui/nutui-react' | ||
|
|
||
| const Demo2 = () => { | ||
| return ( | ||
| <> | ||
| <Cell> | ||
| <Divider>文本</Divider> | ||
| </> | ||
| </Cell> | ||
| ) | ||
| } | ||
| export default Demo2 |
This file contains hidden or 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 |
|---|---|---|
| @@ -1,11 +1,11 @@ | ||
| import React from 'react' | ||
| import { Divider } from '@nutui/nutui-react' | ||
| import { Cell, Divider } from '@nutui/nutui-react' | ||
|
|
||
| const Demo4 = () => { | ||
| return ( | ||
| <> | ||
| <Cell> | ||
| <Divider style={{ borderStyle: 'dashed' }}>文本</Divider> | ||
| </> | ||
| </Cell> | ||
| ) | ||
| } | ||
| export default Demo4 |
This file contains hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
| @@ -1,11 +1,11 @@ | ||
| import React from 'react' | ||
| import { Divider } from '@nutui/nutui-react-taro' | ||
| import { Cell, Divider } from '@nutui/nutui-react-taro' | ||
|
|
||
| const Demo1 = () => { | ||
| return ( | ||
| <> | ||
| <Cell> | ||
| <Divider /> | ||
| </> | ||
| </Cell> | ||
| ) | ||
| } | ||
| export default Demo1 |
This file contains hidden or 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 |
|---|---|---|
| @@ -1,11 +1,11 @@ | ||
| import React from 'react' | ||
| import { Divider } from '@nutui/nutui-react-taro' | ||
| import { Cell, Divider } from '@nutui/nutui-react-taro' | ||
|
|
||
| const Demo2 = () => { | ||
| return ( | ||
| <> | ||
| <Cell> | ||
| <Divider>文本</Divider> | ||
| </> | ||
| </Cell> | ||
| ) | ||
| } | ||
| export default Demo2 |
This file contains hidden or 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 |
|---|---|---|
| @@ -1,7 +1,11 @@ | ||
| import React from 'react' | ||
| import { Divider } from '@nutui/nutui-react-taro' | ||
| import { Cell, Divider } from '@nutui/nutui-react-taro' | ||
|
|
||
| const Demo4 = () => { | ||
| return <Divider style={{ borderStyle: 'dashed' }}>文本</Divider> | ||
| return ( | ||
| <Cell> | ||
| <Divider style={{ borderStyle: 'dashed' }}>文本</Divider> | ||
| </Cell> | ||
| ) | ||
| } | ||
| export default Demo4 |
This file contains hidden or 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 hidden or 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 |
|---|---|---|
| @@ -1,16 +1,16 @@ | ||
| import React from 'react' | ||
| import { Divider } from '@nutui/nutui-react-taro' | ||
| import { Cell, Divider } from '@nutui/nutui-react-taro' | ||
| import { Text } from '@tarojs/components' | ||
|
|
||
| const Demo6 = () => { | ||
| return ( | ||
| <> | ||
| <Cell align="center"> | ||
| <Text>文本</Text> | ||
| <Divider direction="vertical" /> | ||
| <Text style={{ color: '#1989fa' }}>链接</Text> | ||
| <Divider direction="vertical" /> | ||
| <Text style={{ color: '#1989fa' }}>链接</Text> | ||
| </> | ||
| </Cell> | ||
| ) | ||
| } | ||
| export default Demo6 |
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.
组件结构优化建议。
代码使用了
Grid和Grid.Item来布局按钮,这是一个良好的实践。不过,可以考虑将按钮的事件处理函数抽象出来,减少代码重复。Committable suggestion