—— 快應用組件庫H-UI" type="hidden"/>

"宮格導航"組件: —— 快應用組件庫H-UI


<import name="grid" src="../Common/ui/h-ui/navigation/c_grid"></import>
<template>
    <div class="container">
        <grid data="{{data}}"></grid>
    </div>
</template>

<style lang="less">
    @import '../Common/styles/container.less';
</style>

<script>
    export default {
        private: {
            data:[
                {
                    icon: 'female',
                    bgColor: 'bg-success',
                    text: '美妝'
                },
                {
                    icon: 'bag',
                    bgColor: 'bg-danger',
                    text: '包包'
                },
                {
                    icon: 'ring',
                    bgColor: 'bg-indigo',
                    text: '戒指'
                },
                {
                    icon: 'necklace',
                    bgColor: 'bg-pink',
                    text: '項鏈'
                },
                {
                    icon: 'skirt',
                    bgColor: 'bg-orange',
                    text: '連衣裙'
                },
                {
                    icon: 'shoe',
                    bgColor: 'bg-teal',
                    text: '高跟鞋'
                },
                {
                    icon: 't-shirt',
                    bgColor: 'bg-purple',
                    text: 'T恤'
                },
                {
                    icon: 'pants',
                    bgColor: 'bg-cyan',
                    text: '褲子'
                },
                {
                    icon: 'coat',
                    bgColor: 'bg-warning',
                    text: '外套'
                }
            ]
        }
    }
</script>

<import name="grid" src="../Common/ui/h-ui/navigation/c_grid"></import>
<template>
    <div class="container">
        <grid data="{{data}}" mode="rect"></grid>
    </div>
</template>

<style lang="less">
    @import '../Common/styles/container.less';
</style>

<script>
    export default {
        private: {
            data:[
                {
                    icon: 'female',
                    bgColor: 'bg-success',
                    text: '美妝'
                },
                {
                    icon: 'bag',
                    bgColor: 'bg-danger',
                    text: '包包'
                },
                {
                    icon: 'ring',
                    bgColor: 'bg-indigo',
                    text: '戒指'
                },
                {
                    icon: 'necklace',
                    bgColor: 'bg-pink',
                    text: '項鏈'
                },
                {
                    icon: 'skirt',
                    bgColor: 'bg-orange',
                    text: '連衣裙'
                },
                {
                    icon: 'shoe',
                    bgColor: 'bg-teal',
                    text: '高跟鞋'
                },
                {
                    icon: 't-shirt',
                    bgColor: 'bg-purple',
                    text: 'T恤'
                },
                {
                    icon: 'pants',
                    bgColor: 'bg-cyan',
                    text: '褲子'
                },
                {
                    icon: 'coat',
                    bgColor: 'bg-warning',
                    text: '外套'
                }
            ]
        }
    }
</script>

<import name="grid" src="../Common/ui/h-ui/navigation/c_grid"></import>
<template>
    <div class="container">
        <grid data="{{data}}" column-num="4"></grid>
    </div>
</template>

<style lang="less">
    @import '../Common/styles/container.less';
</style>

<script>
    export default {
        private: {
            data:[
                {
                    icon: 'female',
                    bgColor: 'bg-success',
                    text: '美妝'
                },
                {
                    icon: 'bag',
                    bgColor: 'bg-danger',
                    text: '包包'
                },
                {
                    icon: 'ring',
                    bgColor: 'bg-indigo',
                    text: '戒指'
                },
                {
                    icon: 'necklace',
                    bgColor: 'bg-pink',
                    text: '項鏈'
                },
                {
                    icon: 'skirt',
                    bgColor: 'bg-orange',
                    text: '連衣裙'
                },
                {
                    icon: 'shoe',
                    bgColor: 'bg-teal',
                    text: '高跟鞋'
                },
                {
                    icon: 't-shirt',
                    bgColor: 'bg-purple',
                    text: 'T恤'
                },
                {
                    icon: 'pants',
                    bgColor: 'bg-cyan',
                    text: '褲子'
                },
                {
                    icon: 'coat',
                    bgColor: 'bg-warning',
                    text: '外套'
                }
            ]
        }
    }
</script>

<import name="grid" src="../Common/ui/h-ui/navigation/c_grid"></import>
<template>
    <div class="container">
        <grid data="{{data}}" no-border="true"></grid>
    </div>
</template>

<style lang="less">
    @import '../Common/styles/container.less';
</style>

<script>
    export default {
        private: {
            data:[
                {
                    icon: 'female',
                    bgColor: 'bg-success',
                    text: '美妝'
                },
                {
                    icon: 'bag',
                    bgColor: 'bg-danger',
                    text: '包包'
                },
                {
                    icon: 'ring',
                    bgColor: 'bg-indigo',
                    text: '戒指'
                },
                {
                    icon: 'necklace',
                    bgColor: 'bg-pink',
                    text: '項鏈'
                },
                {
                    icon: 'skirt',
                    bgColor: 'bg-orange',
                    text: '連衣裙'
                },
                {
                    icon: 'shoe',
                    bgColor: 'bg-teal',
                    text: '高跟鞋'
                },
                {
                    icon: 't-shirt',
                    bgColor: 'bg-purple',
                    text: 'T恤'
                },
                {
                    icon: 'pants',
                    bgColor: 'bg-cyan',
                    text: '褲子'
                },
                {
                    icon: 'coat',
                    bgColor: 'bg-warning',
                    text: '外套'
                }
            ]
        }
    }
</script>

<import name="grid" src="../Common/ui/h-ui/navigation/c_grid"></import>
<template>
    <div class="container">
        <grid data="{{data}}"></grid>
    </div>
</template>

<style lang="less">
    @import '../Common/styles/container.less';
</style>

<script>
    export default {
        private: {
            data:[
                {
                    image: '/Common/icons/logo.png',
                    text: '快應用',
                },
                {
                    icon: 'bag',
                    bgColor: 'bg-danger',
                    text: '包包'
                },
                {
                    icon: 'ring',
                    bgColor: 'bg-indigo',
                    text: '戒指'
                },
                {
                    icon: 'necklace',
                    bgColor: 'bg-pink',
                    text: '項鏈'
                },
                {
                    icon: 'skirt',
                    bgColor: 'bg-orange',
                    text: '連衣裙'
                },
                {
                    icon: 'shoe',
                    bgColor: 'bg-teal',
                    text: '高跟鞋'
                },
                {
                    icon: 't-shirt',
                    bgColor: 'bg-purple',
                    text: 'T恤'
                },
                {
                    icon: 'pants',
                    bgColor: 'bg-cyan',
                    text: '褲子'
                },
                {
                    icon: 'coat',
                    bgColor: 'bg-warning',
                    text: '外套'
                }
            ]
        }
    }
</script>

點擊“導航”,頁面轉向:

<import name="grid" src="../Common/ui/h-ui/navigation/c_grid"></import>
<template>
    <div class="container">
        <grid data="{{data}}"></grid>
    </div>
</template>

<style lang="less">
    @import '../Common/styles/container.less';
</style>

<script>
    export default {
        private: {
            data:[
                {
                    image: '/Common/icons/logo.png',
                    text: '導航',
                    uri: 'About'
                },
                {
                    icon: 'bag',
                    bgColor: 'bg-danger',
                    text: '包包',
                    uri: 'About'
                },
                {
                    icon: 'ring',
                    bgColor: 'bg-indigo',
                    text: '戒指'
                },
                {
                    icon: 'necklace',
                    bgColor: 'bg-pink',
                    text: '項鏈'
                },
                {
                    icon: 'skirt',
                    bgColor: 'bg-orange',
                    text: '連衣裙'
                },
                {
                    icon: 'shoe',
                    bgColor: 'bg-teal',
                    text: '高跟鞋'
                },
                {
                    icon: 't-shirt',
                    bgColor: 'bg-purple',
                    text: 'T恤'
                },
                {
                    icon: 'pants',
                    bgColor: 'bg-cyan',
                    text: '褲子'
                },
                {
                    icon: 'coat',
                    bgColor: 'bg-warning',
                    text: '外套'
                }
            ]
        }
    }
</script>

掃碼體驗


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM