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

vue-picflow

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

vue-picflow

一个简单的 vue 的瀑布流组件

latest
npmnpm
Version
0.1.5
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

vue-picflow

一个简单的 vue 的瀑布流组件

feature

1. 支持百分比宽度,vw
2. 支持瀑布流的惰性填充
3. 暂不支持 resize
4. 暂不支持重排序

download

yarn add vue-picflow

or

npm install vue-picflow

usage

import { Waterfall, WaterfallSlot } from 'vue-picflow'
components: {
  Waterfall,
  WaterfallSlot
}
<template>
  <waterfall
    line-width="50%"
    :line-count="2"
    :margin-bottom="10"
    :margin-right="10"
    :extra-height="40"
    :vw-viewport="375"
    :max-height="300"
  >
    <waterfall-slot
      v-for="item in items"
      :key="item.index"
      :index="item.index"
      :width="item.width"
      :height="item.height"
      transition="fade"
    >
      <div class="demo">
        <div
          :style="{
            backgroundColor: item.style.color,
            backgroundImage: `url(${item.style.image})`,
            paddingTop: `${(item.height / item.width) * 100}%`
          }"
          class="image"
        />
        <div class="panel">{{ item.index }}</div>
      </div>
    </waterfall-slot>
  </waterfall>
</template>

waterfall args

keyvaluemeaningrequired
line-widthNumber, px, %, vw每行的宽度Y
line-countNumber, >= 2瀑布流的行数Y
margin-bottomNumber, >= 0每个块的上下间距N
margin-rightNumber, >= 0每行的间距N
extra-heightNumber, >= 0出去图片外的 DOM 的高度N
vw-viewportNumber, >= 0vw 模式下的视口宽度N
max-heightNumber, >= 0每个块的最大高度N
lazy-scaleNumber, >= 1懒加载的比率N

waterfall-slot args

keyvaluemeaningrequired
widthNumber, >= 0图片的宽度Y
heightNumber, >= 0图片的高度Y
indexNumber, >=0图片的 indexY
transitionString每个块的渐变动画N

Project setup

yarn install

Compiles and hot-reloads for development

yarn run dev

Compiles and minifies for production

yarn run build

Lints and fixes files

yarn run lint

Run your unit tests(nothing)

yarn run test:unit

Customize configuration

See Configuration Reference.

Keywords

waterfall

FAQs

Package last updated on 18 Mar 2019

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