变更结构
This commit is contained in:
@@ -16,6 +16,17 @@ const start = () => {
|
|||||||
{root: "mods/", pages: []},
|
{root: "mods/", pages: []},
|
||||||
{root: "components/pages/", pages: []},
|
{root: "components/pages/", pages: []},
|
||||||
],
|
],
|
||||||
|
tabBar: {
|
||||||
|
// position: "top",
|
||||||
|
color: "#ddd",
|
||||||
|
selectedColor: "#92ACD1",
|
||||||
|
fontSize: "12px",
|
||||||
|
list: [
|
||||||
|
{text: "店铺", pagePath: "pages/home", iconPath: "static/tabbar/home.png", selectedIconPath: "static/tabbar/home-s.png"},
|
||||||
|
{text: "购物车", pagePath: "pages/AppCart", iconPath: "static/tabbar/cart.png", selectedIconPath: "static/tabbar/cart-s.png"},
|
||||||
|
{text: "我的", pagePath: "pages/AppMine", iconPath: "static/tabbar/mine.png", selectedIconPath: "static/tabbar/mine-s.png"},
|
||||||
|
]
|
||||||
|
},
|
||||||
globalStyle: {
|
globalStyle: {
|
||||||
pageOrientation: "auto",
|
pageOrientation: "auto",
|
||||||
navigationBarTextStyle: "white",
|
navigationBarTextStyle: "white",
|
||||||
@@ -35,6 +46,12 @@ const start = () => {
|
|||||||
return json.subPackages[0].pages.push(app)
|
return json.subPackages[0].pages.push(app)
|
||||||
}
|
}
|
||||||
}),
|
}),
|
||||||
|
findPages('src/pages', file => {
|
||||||
|
if (/.+\\App[^\\]+\.vue/g.test(file)) {
|
||||||
|
const app = new PageBase(file.replace(/^src\\pages\\(.*).vue/g, 'pages/$1').replace(/\\/g, '/'), fs.readFileSync(file).toString())
|
||||||
|
return json.pages.push(app)
|
||||||
|
}
|
||||||
|
}),
|
||||||
]).then(() => {
|
]).then(() => {
|
||||||
fsExtra.outputJson('src/pages.json', json, () => {
|
fsExtra.outputJson('src/pages.json', json, () => {
|
||||||
chalkTag.done('生成pages.json')
|
chalkTag.done('生成pages.json')
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ export default {
|
|||||||
/*每个页面公共css */
|
/*每个页面公共css */
|
||||||
|
|
||||||
@each $padMar, $pm in (mar:margin, pad:padding) {
|
@each $padMar, $pm in (mar:margin, pad:padding) {
|
||||||
@each $v in (8, 10, 16, 20, 32, 48, 64, 80) {
|
@each $v in (8, 10, 16, 20, 32, 48, 56, 64, 80) {
|
||||||
@each $pos, $p in (l:left, r:right, t:top, b:bottom) {
|
@each $pos, $p in (l:left, r:right, t:top, b:bottom) {
|
||||||
.#{$padMar}-#{$pos+$v} {
|
.#{$padMar}-#{$pos+$v} {
|
||||||
#{$pm}-#{$p}: #{$v}px
|
#{$pm}-#{$p}: #{$v}px
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
<section class="home">
|
<section class="home">
|
||||||
<uni-search-bar class="sticky-t" placeholder="搜索商品" cancelText="更多" @cancel="" radius="100" @input="handleSearch"/>
|
<uni-search-bar class="sticky-t" placeholder="搜索商品" cancelText="更多" @cancel="" radius="100" @input="handleSearch"/>
|
||||||
<ai-tabs class="fixedTabs" :tabs="indexList" vertical v-model="currentType" @click="handleType"/>
|
<ai-tabs class="fixedTabs" :tabs="indexList" vertical v-model="currentType" @click="handleType"/>
|
||||||
<div class="pad-l80 pad-t64">
|
<div class="pad-l80 pad-t56">
|
||||||
<!-- <uni-card isFull :border="false" title="示例产品" subTitle="规格:8mmX10mm" extra="查看详情"-->
|
<!-- <uni-card isFull :border="false" title="示例产品" subTitle="规格:8mmX10mm" extra="查看详情"-->
|
||||||
<!-- thumbnail="https://web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png"/>-->
|
<!-- thumbnail="https://web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png"/>-->
|
||||||
<uni-list-item title="示例产品" note="规格:8mmX10mm" thumbSize="lg" thumb="https://web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png" :showArrow="false">
|
<uni-list-item title="示例产品" note="规格:8mmX10mm" thumbSize="lg" thumb="https://web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png" :showArrow="false">
|
||||||
@@ -19,7 +19,6 @@
|
|||||||
<uni-list-item title="示例产品" note="规格:8mmX10mm" thumbSize="lg" thumb="https://web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png" rightText="¥2.60"/>
|
<uni-list-item title="示例产品" note="规格:8mmX10mm" thumbSize="lg" thumb="https://web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png" rightText="¥2.60"/>
|
||||||
</div>
|
</div>
|
||||||
<ai-gap h="50"/>
|
<ai-gap h="50"/>
|
||||||
<uni-goods-nav class="fixed-b" @click="handleGoodNav"/>
|
|
||||||
</section>
|
</section>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -52,6 +51,7 @@ export default {
|
|||||||
|
|
||||||
},
|
},
|
||||||
handleAdd2Cart() {
|
handleAdd2Cart() {
|
||||||
|
uni.setTabBarBadge({index: 1, text: "4"})
|
||||||
this.$toast("加入购物车")
|
this.$toast("加入购物车")
|
||||||
},
|
},
|
||||||
handleDetail() {
|
handleDetail() {
|
||||||
|
|||||||
BIN
wxmp/src/static/tabbar/cart-s.png
Normal file
BIN
wxmp/src/static/tabbar/cart-s.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 962 B |
BIN
wxmp/src/static/tabbar/cart.png
Normal file
BIN
wxmp/src/static/tabbar/cart.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 964 B |
BIN
wxmp/src/static/tabbar/home-s.png
Normal file
BIN
wxmp/src/static/tabbar/home-s.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
BIN
wxmp/src/static/tabbar/home.png
Normal file
BIN
wxmp/src/static/tabbar/home.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
BIN
wxmp/src/static/tabbar/mine-s.png
Normal file
BIN
wxmp/src/static/tabbar/mine-s.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.0 KiB |
BIN
wxmp/src/static/tabbar/mine.png
Normal file
BIN
wxmp/src/static/tabbar/mine.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1002 B |
Reference in New Issue
Block a user