1234567891011121314151617181920212223242526272829303132333435363738 |
- <template>
- <view class="container">
- <view :style="{height: statusBarHeight + 'px'}"></view>
- 注册
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- statusBarHeight: 0,
- navBarHeight:0
- };
- },
- onReady() {
- const that = this;
- uni.getSystemInfo({
- success(e) {
- that.statusBarHeight = e.statusBarHeight;
- let custom = uni.getMenuButtonBoundingClientRect();
- that.navBarHeight = custom.height + (custom.top - e.statusBarHeight) * 2;
- }
- })
- },
- onLoad() {
- }
- }
- </script>
- <style lang="scss" scoped>
- .container {
- height: 100vh;
- width: 100vw;
- background-color: $uni-bg-color;
- padding: 0 20rpx;
- }
- </style>
|