Skip to content

Grid ​

Demo ​

Grid 跨端示例与演示

H5 LiveInteractive browser runtime
Quick servicesAccount shortcuts
8
2Orders
Delivery
3Coupons
Favorites
Addresses
Support
Invoices
Settings

Basic Usage ​

vue
<template>
  <VGrid>
    <VGridItem icon="◎" text="Text" />
    <VGridItem icon="◎" text="Logistics" />
    <VGridItem icon="◎" text="Favorites" />
    <VGridItem icon="◎" text="Settings" />
  </VGrid>
</template>

Columns and Gutter ​

vue
<template>
  <VGrid :column-num="3" :gutter="8">
    <VGridItem text="Entry" />
    <VGridItem text="Entry" />
    <VGridItem text="Entry" />
  </VGrid>
</template>

Badge and Clickable ​

vue
<template>
  <VGrid clickable>
    <VGridItem icon="◎" text="Messages" badge="3" />
    <VGridItem icon="◎" text="Notice" dot />
  </VGrid>
</template>

Grid Props ​

PropTypeDefaultDescription
columnNumnumber | string4Column count
gutternumber | stringundefinedGrid gutter
borderbooleantrueBorder marker
squarebooleanfalseSquare item marker
centerbooleantrueCenter content
clickablebooleanfalseClickable state
direction'vertical' | 'horizontal''vertical'Content direction

GridItem Props ​

PropTypeDefaultDescription
textstringundefinedText
iconstringundefinedIcon content
badgenumber | stringundefinedBadge content
dotbooleanfalseRed dot
urlstringundefinedLink URL
tostringundefinedRoute link
spannumber | string1Column span
clickableboolean | undefinedundefinedOverride parent clickable state