New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

vue3-flop-card

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vue3-flop-card

用于抽奖翻卡,使用 vue3 编写

latest
npmnpm
Version
1.0.6
Version published
Weekly downloads
1
-80%
Maintainers
1
Weekly downloads
 
Created
Source

flop-card

用于抽奖翻卡,使用 vue3 编写

安装

npm install vue3-flop-card

全局引入

import Vue3FlopCard from "vue3-flop-card";
import "vue3-flop-card/lib/style.css";

app.use(Vue3FlopCard);

基础使用

<vue3-flop-card v-model="cardArr" :cardData="data"></vue3-flop-card>

props

1. cardWidth:卡片宽度    (String '100px')
2. cardHeight:卡片高度    (String  '100px')
3. frontColor:答案面背景颜色  (String   '#000')
4. backColor:背面背景颜色  (String  '#fff')
5. canChoiceCount:可抽卡次数  (Number  3)
6. textSize:抽卡文字大小  (String  '16px')
7. modelValue:抽中的卡片数组双向绑定 (Array)
8. cardData:卡片内容数组 (必须有title属性用于显示抽奖结果)
[
    {
        id:0,
        title:'一等奖'
    }
]

Slot

<slot name="result"></slot> 翻牌结果进行自定义
<slot name="front"></slot> 翻牌正面进行自定义
<slot name="tip"></slot> 提示剩几次抽奖机会自定义

Keywords

flop

FAQs

Package last updated on 26 Mar 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts