Mint UI 可滑動的單元格-Cell Swipe

2021-09-06 15:20 更新
可滑動的單元格,用法同 ?cell?。

引入

import { CellSwipe } from 'mint-ui';

Vue.component(CellSwipe.name, CellSwipe);

例子

增加右滑動按鈕

<mt-cell-swipe
  title="標題文字"
  :right="[
    {
      content: 'Delete',
      style: { background: 'red', color: '#fff' },
      handler: () => this.$messagebox('delete')
    }
  ]"></mt-cell-swipe>

?content? 可以是 ?HTML? 或者純文本。

API

參數 說明 類型 可選值 默認值
icon 圖標 String back, more
title 標題 String
to 跳轉鏈接 String
value 內容 *
label 備注信息,顯示在標題下方 String
is-link 鏈接,會顯示箭頭圖標。搭配 to 屬性使用 Boolean
left 按鈕組, { content, style, handler } Object[]
right 按鈕組, { content, style, handler } Object[]

Slot

name 描述
- 自定義顯示內容
title 自定義標題
icon 自定義圖標


實例演示

以上內容是否對您有幫助:
在線筆記
App下載
App下載

掃描二維碼

下載編程獅App

公眾號
微信公眾號

編程獅公眾號