d136669a by simon

基础工程

1 parent 437c1c5a
Showing 94 changed files with 911 additions and 138 deletions
{
"pages": [
"pages/authorize/authorize",
"pages/index/index",
"pages/authorize/authorize",
"pages/register/register",
"pages/scan-result/scan-result",
"pages/integral-detail/integral-detail",
"pages/gift-shop/gift-shop",
"pages/gift-detail/gift-detail",
"pages/address-management/address-management",
"pages/address-edit/address-edit",
"pages/my-qrcode/my-qrcode",
"pages/my-order/my-order",
"pages/my-message/my-message",
"pages/contact/contact",
"pages/contact-table/contact-table",
"pages/vip-login/vip-login",
"pages/vip-verify/vip-verify",
"pages/user-center/user-center",
"pages/sign-in-record/sign-in-record",
"pages/rank/rank",
"pages/rank-gift/rank-gift",
"pages/example/example",
"pages/more/more"
],
"window": {
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "mp-gulp-framework",
"navigationBarTextStyle": "black"
"navigationBarBackgroundColor": "#3680EB",
"navigationBarTitleText": "志亮照明",
"navigationBarTextStyle": "white"
},
"tabBar": {
"color": "#7A7E83",
"selectedColor": "#CF4646",
"color": "#999999",
"selectedColor": "#3680EB",
"borderStyle": "black",
"backgroundColor": "#ffffff",
"list": [{
"pagePath": "pages/index/index",
"iconPath": "image/tabbar/home_D.png",
"selectedIconPath": "image/tabbar/home.png",
"text": "介绍"
"iconPath": "image/tabbar/scan_bar.png",
"selectedIconPath": "image/tabbar/scan_bar_selected.png",
"text": "扫码积分"
},
{
"pagePath": "pages/gift-shop/gift-shop",
"iconPath": "image/tabbar/gift_bar.png",
"selectedIconPath": "image/tabbar/gift_bar_selected.png",
"text": "礼物兑换"
},
{
"pagePath": "pages/more/more",
"iconPath": "image/tabbar/set_D.png",
"selectedIconPath": "image/tabbar/set.png",
"text": "更多"
"pagePath": "pages/user-center/user-center",
"iconPath": "image/tabbar/user_bar.png",
"selectedIconPath": "image/tabbar/user_bar_selected.png",
"text": "个人中心"
}
]
}
......
......@@ -5,187 +5,187 @@
* ------------------------------------------------------------------
*
*/
@import "support";
@import "support";
// Margin
.u-mt-smaller {
// Margin
.u-mt-smaller {
margin-top: $marginTopSmaller;
}
}
.u-mt-small {
.u-mt-small {
margin-top: $marginTopSmall;
}
}
.u-mt-medium {
.u-mt-medium {
margin-top: $marginTopMedium;
}
}
.u-mt-large {
.u-mt-large {
margin-top: $marginTopLarge;
}
}
.u-mt-larger {
.u-mt-larger {
margin-top: $marginTopLarger;
}
}
.u-mb-smaller {
.u-mb-smaller {
margin-bottom: $marginTopSmaller;
}
}
.u-mb-small {
.u-mb-small {
margin-bottom: $marginTopSmall;
}
}
.u-mb-medium {
.u-mb-medium {
margin-bottom: $marginTopMedium;
}
}
.u-mb-large {
.u-mb-large {
margin-bottom: $marginTopLarge;
}
}
.u-mb-larger {
.u-mb-larger {
margin-bottom: $marginTopLarger;
}
}
// Padding
.u-pt-smaller {
// Padding
.u-pt-smaller {
padding-top: $paddingTopSmaller;
}
}
.u-pt-small {
.u-pt-small {
padding-top: $paddingTopSmall;
}
}
.u-pt-medium {
.u-pt-medium {
padding-top: $paddingTopMedium;
}
}
.u-pt-large {
.u-pt-large {
padding-top: $paddingTopLarge;
}
}
.u-pt-larger {
.u-pt-larger {
padding-top: $paddingTopLarger;
}
}
.u-pb-smaller {
.u-pb-smaller {
padding-bottom: $paddingTopSmaller;
}
}
.u-pb-small {
.u-pb-small {
padding-bottom: $paddingTopSmall;
}
}
.u-pb-medium {
.u-pb-medium {
padding-bottom: $paddingTopMedium;
}
}
.u-pb-large {
.u-pb-large {
padding-bottom: $paddingTopLarge;
}
}
.u-pb-larger {
.u-pb-larger {
padding-bottom: $paddingTopLarger;
}
}
// 布局方位
.u-ta-c {
// 布局方位
.u-ta-c {
text-align: center !important;
}
}
.u-ta-l {
.u-ta-l {
text-align: left !important;
}
}
.u-ta-r {
.u-ta-r {
text-align: right !important;
}
}
.u-fl-l {
.u-fl-l {
float: left;
}
}
.u-fl-n {
.u-fl-n {
float: none;
}
}
.u-fl-r {
.u-fl-r {
float: right;
}
}
.u-d-b {
.u-d-b {
display: block;
}
}
.u-d-i {
.u-d-i {
display: inline !important;
}
}
.u-d-ib {
.u-d-ib {
display: inline-block !important;
}
}
.u-d-n {
.u-d-n {
display: none !important;
}
}
.u-d-t {
.u-d-t {
display: table;
table-layout: fixed;
}
}
.u-d-tc {
.u-d-tc {
display: table-cell;
}
}
.u-va-b {
.u-va-b {
vertical-align: bottom;
}
}
.u-va-m {
.u-va-m {
vertical-align: middle;
}
}
.u-va-t {
.u-va-t {
vertical-align: top;
}
}
// clearfix
.u-clearfix {
// clearfix
.u-clearfix {
@include clearfix;
}
}
// 虚拟格式
.u-cur-d {
// 虚拟格式
.u-cur-d {
cursor: default;
}
}
.u-cur-p {
.u-cur-p {
cursor: pointer;
}
}
// flex
.u-flex {
// flex
.u-flex {
display: -webkit-box;
display: -webkit-flex;
display: flex;
}
}
.u-flex-item {
.u-flex-item {
-webkit-box-flex: 1;
-webkit-flex: 1;
flex: 1;
}
}
// 小程序中模拟ul、li
.u-ul {
// 小程序中模拟ul、li
.u-ul {
padding-left: 30px;
text-align: left;
display: block;
}
}
.u-li {
.u-li {
position: relative;
font-size: $fontSizeSmall;
line-height: $fontSizeSmall + 4px;
......@@ -200,5 +200,40 @@
border-radius: 8px;
background-color: $colorBlack;
}
}
}
.bis {
background-repeat: no-repeat;
background-size: 100% 100%;
}
//flex 布局和 子元素 对其方式
.fl {
display: flex;
}
.fj {
display: flex;
justify-content: space-between;
}
//水平和垂直居中
.fcc {
display: flex;
justify-content: center;
align-items: center;
}
// 为元素设定的宽度和高度决定了元素的边框盒。
.bb {
box-sizing: border-box;
}
// 满屏
.fullp {
width: 100%;
height: 100%;
}
......
......@@ -39,3 +39,9 @@ $fontSizeSmall: 28px;
$fontSizeSmaller: 24px;
$fontSizeLarge: 36px;
$fontSizeLarger: 44px;
// 主题颜色
$colorMain:#3680EB;
$pageBottom:80px;
......
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
{
"navigationBarTitleText": "more"
"navigationBarTitleText": "demo"
}
......
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<!-- <view class="app__top-shadow"></view> -->
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
{
"navigationBarTitleText": "index"
"navigationBarTitleText": "志亮照明"
}
......
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
$contentWidth:670px;
.page {
padding-bottom: $pageBottom;
.bgc {}
.bg {}
.main {
.top {
position: absolute;
width: 750px;
&-bg {
position: absolute;
width: 750px;
height: 300px;
}
.search {
position: relative;
width: $contentWidth;
height: 100px;
background: #FFFFFF;
box-shadow: 0 6px 18px 0 rgba(0, 0, 0, 0.10);
border-radius: 8px;
margin: 222px auto 0;
display: flex;
justify-content: space-between;
align-items: center;
&-ipt-wrap {
@extend .bb;
padding: 0 30px;
width: 568px;
flex: 1;
.ipt {
font-size: 28px;
color: #999999;
}
}
&-line {
width: 2px;
height: 40px;
background-color: #d8d8d8;
}
&-scan {
@extend .fcc;
width: 100px;
.icon {
width: 40px;
height: 40px;
}
}
}
}
.top-space {
height: 0px;
height: 362px;
}
.content {
position: relative;
width: $contentWidth;
margin: 0 auto;
// banner
.banner {
width: $contentWidth;
height: 250px;
background-color: wheat;
margin: 0 auto;
}
// 产品
.product {
width: $contentWidth;
margin: 0 auto;
margin-top: 62px;
// 产品标题
&-title {
font-size: 36px;
color: #333333;
}
// 产品列表
&-list {
margin-top: 20px;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
.item {
width: 322px;
height: 440px;
background: #F8F8F8;
border-radius: 4px;
margin-bottom: 20px;
}
}
}
}
}
}
......
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<!-- <view class="app__top-shadow"></view> -->
<view class="app__content main">
<!-- Title及搜索框 -->
<view class="top">
<image class="top-bg" mode="widthFix" src="../../image/index/index_c1.png" />
<view class="search">
<view class="search-ipt-wrap">
<input class="ipt" placeholder="请输入串码" />
</view>
<view class="search-line"></view>
<view class="search-scan">
<image class="icon" mode="aspectFit" src="../../image/icon/icon_scan.png" />
</view>
</view>
</view>
<view class="top-space"></view>
<view class="content"></view>
<view class="content">
<!-- 轮播 banner -->
<!-- <swiper indicator-dots="{{true}}" autoplay="{{true}}" interval="{{5000}}" duration="{{500}}">
<block wx:for="{{imgUrls}}">
<swiper-item>
<image class="swiper-image" src="{{item}}" />
</swiper-item>
</block>
</swiper> -->
<view class="banner"></view>
<view class="product">
<view class="product-title">产品推荐</view>
<view class="product-list">
<!-- for循环 -->
<view class="item">1</view>
<view class="item">2</view>
<view class="item">3</view>
<view class="item">4</view>
</view>
</view>
</view>
</view>
</view>
......
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "demo"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<!-- <view class="app__top-shadow"></view> -->
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "demo"
}
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content">scan-result</view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "demo"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<!-- <view class="app__top-shadow"></view> -->
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
let app = getApp();
Page({
data: {},
onLoad(options) {}
})
{
"navigationBarTitleText": "more"
}
@import '../../assets/scss/mixins';
@import '../../assets/scss/utils';
.page {
.bgc {}
.bg {}
.main {
.top-space {
height: 0px;
}
.content {
position: relative;
}
}
}
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<view class="top-space"></view>
<view class="content"></view>
</view>
</view>
const routerPath = {
index: '/pages/index/index', // 首页
register: '/pages/register/register', // 注册
authorize: '/pages/authorize/authorize', // 授权
register: '/pages/register/register', // 注册
scanResult: '/pages/scan-result/scan-result', // 扫码结果 (含扫码成功和扫码失败)
integralDetail: '/pages/integral-detail/integral-detail', // 积分明细
giftShop: '/pages/gift-shop/gift-shop', // 礼品商场
giftDetail: '/pages/gift-detail/gift-detail', // 礼品详情 (含购物卡和实物)
addressManagement: '/pages/address-management/address-management', // 地址管理
addressEdit: '/pages/address-edit/address-edit', // 地址编辑
myQrcode: '/pages/my-qrcode/my-qrcode', // 我的二维码
myOrder: '/pages/my-order/my-order', // 我的订单
myMessage: '/pages/my-message/my-message', // 我的消息
contact: '/pages/contact/contact', // 联系我们
contactTable: '/pages/contact-table/contact-table', // 联系我们-提交表单
vipLogin: '/pages/vip-login/vip-login', // 会员信息验证(填表单)
vipVerify: '/pages/vip-verify/vip-verify', // 会员信息审核
userCenter: '/pages/user-center/user-center', // 个人中心 (合并签到页,很提示页)
signInRecord: '/pages/sign-in-record/sign-in-record', // 签到记录
rank: '/pages/rank/rank', // 排行榜
rankGift: '/pages/rank-gift/rank-gift', // 排行榜奖励
example: '/pages/example/example',
more: '/pages/more/more',
}
......