Browse Source

Merge remote-tracking branch 'origin/master'

feature-1.0
Penny 3 years ago
parent
commit
bdb4a3a0cf
  1. 2
      main.js
  2. 10
      pages.json
  3. 138
      pages/login/login.vue
  4. 2
      uni.scss

2
main.js

@ -6,7 +6,7 @@ import common from './utils/common.js'
// const baseURL = 'http://localhost:7010'
//const baseURL = 'http://81.69.47.31:7010'
// const baseURL = 'http://bnyer.vaiwan.com'
const baseURL = 'http://i5s7bh.natappfree.cc'
const baseURL = 'http://aipdbt.natappfree.cc'
Vue.prototype.$baseURL = baseURL;

10
pages.json

@ -38,8 +38,9 @@
},{
"path": "pages/login/login",
"style": {
"navigationBarTitleText": "登录",
"enablePullDownRefresh": false
"navigationBarTitleText": " ",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#22343C"
}
}, {
@ -211,7 +212,10 @@
"navigationBarTextStyle": "black",
"navigationBarTitleText": "bnyer",
"navigationBarBackgroundColor": "#F8F8F8",
"backgroundColor": "#F8F8F8"
"backgroundColor": "#F8F8F8",
"rpxCalcMaxDeviceWidth": 750, // rpx px 960
"rpxCalcBaseDeviceWidth": 375, // rpx 使 rpx px 375
"rpxCalcIncludeWidth": 750 // rpx rpx 750
},
//tab
"tabBar": {

138
pages/login/login.vue

@ -1,14 +1,40 @@
<template>
<view>
<uni-forms validate-trigger='blur' :modelValue="formData" ref="form">
<uni-forms-item label="手机号" required name="phone">
<uni-easyinput v-model="formData.phone" placeholder="请输入手机号" />
</uni-forms-item>
<uni-forms-item label="密码" required name="password">
<uni-easyinput type="password" v-model="formData.password" placeholder="请输入密码" />
</uni-forms-item>
</uni-forms>
<button type="primary" @click="$noMultipleClicks(login,formData)">登录</button>
<view class="login-body uni-bg-color">
<div class="auto-center">
<div class="logo-div"></div>
<div class="welcome-text">
<p class="welcome-title uni-white">进入次元Hub</p>
<p class="welcome-subtitle uni-secondary-color">开启你的创作之旅~</p>
</div>
<uni-forms class="login-form-ss" validate-trigger='blur' :modelValue="formData" ref="form">
<uni-forms-item required name="phone">
<template #label>
<div class="form-label l-username">
<uni-icons type="contact" size="18" color="#FFC542"></uni-icons>
</div>
</template>
<uni-easyinput
type="number"
v-model="formData.phone"
placeholder="请输入手机号"
:clearable="false"
:inputBorder="false"
/>
</uni-forms-item>
<uni-forms-item required name="password">
<template #label>
<div class="form-label l-password">
<uni-icons type="locked-filled" size="18" color="#FF575F"></uni-icons>
</div>
</template>
<uni-easyinput type="password" v-model="formData.password" placeholder="请输入密码" :inputBorder="false" />
</uni-forms-item>
</uni-forms>
<button class="login-btn" type="primary" @click="$noMultipleClicks(login,formData)">登录<uni-icons type="arrow-right" size="20" color="#fff"></uni-icons></button>
<div class="foget-password uni-secondary-color">
<span >忘记密码</span>
</div>
</div>
</view>
</template>
@ -27,7 +53,7 @@
phone: '',
password: ''
},
rules: {
password: {
rules: [{
@ -141,6 +167,94 @@
}
</script>
<style>
<style scoped lang="scss">
.login-body {
min-height: 100vh;
background-color: #22343C;
.auto-center {
width: 622rpx;
margin: 0 auto;
border-top: 1rpx solid #22343C;
border-bottom: 1rpx solid #22343C;
}
.logo-div {
width: 86rpx;
height: 86rpx;
background: linear-gradient(180.00deg, rgba(63.59,223.05,158.63,1) 0%,rgba(62,213,152,1) 100%);
box-shadow: 0 4rpx 8rpx rgba(15, 218, 137, 0.3);
border-radius: 24rpx;
margin-top: 154rpx;
}
.welcome-text {
margin-top: 72rpx;
margin-bottom: 72rpx;
.welcome-title {
font-size: 84rpx;
}
.welcome-subtitle {
font-size: 48rpx;
margin-left: 90rpx;
margin-top: 44rpx;
}
}
.uni-forms {
.form-label {
width: 76rpx;
height: 96rpx;
border-radius: 24rpx;
line-height: 96rpx;
text-align: center;
margin-right: 24rpx;
margin-bottom: 4rpx;
margin-top: 4rpx;
}
.l-username {
background: rgb(98, 91, 57);
}
.l-password {
background: rgb(98, 58, 66);
}
}
.login-btn {
background: linear-gradient(180.00deg, rgba(63.59,223.05,158.63,1) 0%,rgba(62,213,152,1) 100%);
box-shadow: 0 4rpx 8rpx rgba(15, 218, 137, 0.3);
border-radius: 24rpx;
margin-top: 52rpx;
}
.foget-password {
text-align: right;
margin-top: 26rpx;
margin-right: 24rpx;
margin-bottom: 100rpx;
}
}
.login-body {
::v-deep .uni-forms-item {
margin-bottom: 0 !important;
}
}
.login-body {
::v-deep input {
height: 100rpx;
border-bottom: 4rpx solid rgba(0, 0, 0, 0.05);
background: none !important;
font-size: 36rpx;
color: rgb(150, 167, 175);
}
}
.login-body {
::v-deep .uni-easyinput__content {
background: none !important;
}
}
</style>

2
uni.scss

@ -1 +1 @@
@import '@/uni_modules/uni-scss/variables.scss';
@import '@/uni_modules/uni-scss/variables.scss';

Loading…
Cancel
Save