Code Monkey home page Code Monkey logo

erabbit-ui's Introduction

小兔鲜组件库

小兔鲜UI组件库,基于Vue3开发,服务于电商平台小兔鲜儿。

Installation

基于:vue3 @vueuse/core axios vue-router less less-loader

yarn add erabbit-ui

Usage

<!-- index.html -->
<link rel="stylesheet" href="https://at.alicdn.com/t/font_2143783_iq6z4ey5vu.css">
import { createApp } from 'vue'
import App from './App.vue'

import ErabbitUI from 'erabbit-ui'
import 'erabbit-ui/packages/theme/index.less'

createApp(App).use(ErabbitUI).mount('#app')

Docs

面包屑

xtx-bread

xtx-bread-item

props

名称 类型 默认值
to String, Object

与router-link的to属性一致

按钮

xtx-button

名称 类型 可选值 默认值
size String large/middle/small/mini middle
type String default/primary/plain/gray default

轮播图

xtx-carousel

props

名称 类型 默认值
sliders Array []
autoPlay Boolean false
duration Number 3000毫秒

:sliders="[{imgUrl:'图片地址'}]"

复选框

xtx-checkbox

props

名称 类型 默认值
v-model Boolean false

地区选择

xtx-city

props

名称 类型 默认值
placeholder String ''
fullLocaton String ''

events

名称 触发时机 默认参
change 选择完成 { fullLocaton, provinceCode, provinceName, cityCode, cityName, countyCode, countyName }

对话框

xtx-dialog

props

名称 类型 默认值
v-model:visible Boolean false

图片预览组件

组件名称:xtx-image-view

props

名称 类型 默认值
images Array []

[] 图片数组

无限加载组件

xtx-infinite-loading

props

名称 类型 默认值
loading 加载中 Boolean false
finished 全部数据加载完成 Boolean false

events

名称 触发时机 默认参
infinite 进入可视区

更多组件

xtx-more

props

名称 类型 默认值
to String, Object

与router-link的to属性一致

数字选择

xtx-numbox

props

名称 类型 默认值
label String ''
v-model Number 0
min Number 0
max Number 10

分页组件

xtx-pagination

props

名称 类型 默认值
total 总条数 Number 100
pageSize 每页条数 Number 10
currentPage 当前第几页 Number 1

events

名称 触发时机 默认参
current-change 改变分页页码 点击的页码

骨架组件

xtx-skeleton

props

名称 类型 默认值
bg 背景 Number #efefef
width 宽 String 100px
height 高 String 100px
animated 闪动画 Boolean false

sku组件

props

名称 类型 默认值
goods Object { specs: [], skus: [] }
skuId String ''

events

名称 回调参数
change 完整的sku对象数据 (不完整时为空对象{})

{skuId,price,oldPrice,inventory,specsText}

步骤条

xtx-steps

props

名称 类型 默认值
active 当前到第几步 Number 1

xtx-steps-item

props

名称 类型 默认值
title 标题 String ''
desc 说明 String ''

tab栏

xtx-tabs

props

名称 类型 默认值
v-model String,Number ''

events

名称 触发时机 默认值
tab-click 点击选项卡 { name, index }

{name:'选项卡名称',index:'选项卡索引'}

xtx-tabs-item

props

名称 类型 默认值
label 选项卡标题 String ''
name 选项卡名称 String ''

about

email: [email protected] github: https://github.com/zhousg

erabbit-ui's People

Contributors

zhousg avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.