Skip to content

Commit

Permalink
fix: 优化组件在React-H5内的显示异常
Browse files Browse the repository at this point in the history
  • Loading branch information
三少 committed Nov 2, 2021
1 parent 46cb090 commit 4f50708
Show file tree
Hide file tree
Showing 13 changed files with 82 additions and 255 deletions.
16 changes: 8 additions & 8 deletions packages/vantui-demo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,10 @@
"@antmjs/mini-fix": "^1.12.0",
"@antmjs/vantui": "^1.0.0",
"@babel/runtime-corejs3": "^7.14.7",
"@tarojs/components": "3.3.7",
"@tarojs/react": "3.3.7",
"@tarojs/runtime": "3.3.7",
"@tarojs/taro": "3.3.7",
"@tarojs/components": "3.3.11",
"@tarojs/react": "3.3.11",
"@tarojs/runtime": "3.3.11",
"@tarojs/taro": "3.3.11",
"@vant/area-data": "^1.1.3",
"@vant/icons": "^1.7.1",
"core-js": "^3.15.2",
Expand All @@ -122,12 +122,12 @@
"@antmjs/iconfont": "^1.12.0",
"@antmjs/plugin-mini-fix": "^1.12.0",
"@babel/core": "^7.8.0",
"@tarojs/cli": "^3.3.7",
"@tarojs/mini-runner": "3.3.7",
"@tarojs/webpack-runner": "3.3.7",
"@tarojs/cli": "3.3.11",
"@tarojs/mini-runner": "3.3.11",
"@tarojs/webpack-runner": "3.3.11",
"@types/react": "^17.0.2",
"@types/webpack-env": "^1.13.6",
"babel-plugin-transform-taroapi": "^3.3.7",
"babel-plugin-transform-taroapi": "^3.3.11",
"cross-env": "^7.0.3",
"eslint": "^7.30.0",
"prettier": "^2.3.2",
Expand Down
3 changes: 0 additions & 3 deletions packages/vantui-demo/src/pages/circle/index.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
.van-circle {
margin: 10px 20px 40px;
}
.van-button{
margin-left: 20px;
}
1 change: 1 addition & 0 deletions packages/vantui-demo/src/pages/goods-action/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ export default class Index extends Component {
type="warning"
></GoodsActionButton>
<GoodsActionButton
type="primary"
plain
color="#7232dd"
text="立即购买"
Expand Down
1 change: 0 additions & 1 deletion packages/vantui-demo/src/pages/picker/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { Component } from 'react'
import Taro from '@tarojs/taro'
import { Picker, Toast, toast } from '@antmjs/vantui'
import DemoPage from '../../components/demo-page/index'
import DemoBlock from '../../components/demo-block/index'
Expand Down
12 changes: 8 additions & 4 deletions packages/vantui-demo/src/pages/sidebar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,31 +31,35 @@ export default class Index extends Component {
<Grid columnNum={2} border={false}>
<GridItem>
<h3 className="demo-sidebar-title">基础用法</h3>
<Sidebar className="custom-sidebar">
<Sidebar className="custom-sidebar" activeKey={0}>
<SidebarItem title="标签名"></SidebarItem>
<SidebarItem title="标签名"></SidebarItem>
<SidebarItem title="标签名"></SidebarItem>
</Sidebar>
</GridItem>
<GridItem>
<h3 className="demo-sidebar-title">徽标提示</h3>
<Sidebar className="custom-sidebar">
<Sidebar className="custom-sidebar" activeKey={0}>
<SidebarItem title="标签名" dot></SidebarItem>
<SidebarItem title="标签名" badge="5"></SidebarItem>
<SidebarItem title="标签名" badge="99+"></SidebarItem>
</Sidebar>
</GridItem>
<GridItem>
<h3 className="demo-sidebar-title">禁用选项</h3>
<Sidebar className="custom-sidebar">
<Sidebar className="custom-sidebar" activeKey={0}>
<SidebarItem title="标签名"></SidebarItem>
<SidebarItem title="标签名" disabled></SidebarItem>
<SidebarItem title="标签名"></SidebarItem>
</Sidebar>
</GridItem>
<GridItem>
<h3 className="demo-sidebar-title">监听切换事件</h3>
<Sidebar className="custom-sidebar" onChange={this.onChange}>
<Sidebar
className="custom-sidebar"
onChange={this.onChange}
activeKey={0}
>
<SidebarItem title="标签名 1"></SidebarItem>
<SidebarItem title="标签名 2"></SidebarItem>
<SidebarItem title="标签名 3"></SidebarItem>
Expand Down
4 changes: 0 additions & 4 deletions packages/vantui-demo/src/pages/sticky/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@
height: 200vh;
}

.van-button {
margin-left: 32px;
}

.sticky-container {
position: relative;
z-index: -1;
Expand Down
2 changes: 1 addition & 1 deletion packages/vantui-demo/src/pages/switch/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export default class Index extends Component {
message: '是否切换开关?',
})
.then(() => {
// this.setState({ checked2: detail })
this.setState({ checked2: detail })
})
.catch((e) => {
console.log(e)
Expand Down
Loading

0 comments on commit 4f50708

Please sign in to comment.