1.2.6 • Published 2 years ago

vue-custom-pages v1.2.6

Weekly downloads
1
License
MIT
Repository
-
Last release
2 years ago

vue-custom-pages

基于vue2.0实现的自定义分页

实现效果如下: npm.io

支持功能

- [x] 自定义分页条数
- [x] 跳转某一页

联系方式

- 微信:18888320271

快速上手

1. npm安装  `npm i --save vue-custom-pages`
2. main.js中引入 ` 
            import customPages from 'vue-custom-pages';
            Vue.use(customPages)
             `
3. 使用
  `
  <template>
      <div id="app">
        <vue-custom-pages :total="1000" active-color="red" page-size="20" show-count v-model="page" @change="search"          show-elevator :size='[10,20,30,40]'   ></vue-custom-pages>
  </div>
</template>

<script>
export default {
  name: 'app',
  methods:{
    search(page,pageSzie){
        console.log("当前页:",page)
        console.log("当前页大小:",pageSzie)
    }
  },
  data () {
    return {
      page:1
      
    }
  }
}
</script>
`

参数说明

参数说明类型默认值可选值
total总条数NumberString0
page-size页大小NumberString10
show-elevator是否显示快速跳转到某一页Booleanfalsetrue
v-model当前页NumberString1
size可以切换每页显示的数量Array[]
show-count是否显示总页数Booleanfalsetrue
active-color选中页背景色String#2979ff
next-name下一页按钮名称String>
pre-name上一页按钮名称String<
font-size字体大小String12px
show-current-page是否只展示当前页码 (1.1.2版本新增+)Booleanfalse
1.2.6

2 years ago

1.2.5

2 years ago

1.2.4

3 years ago

1.2.3

3 years ago

1.2.2

3 years ago

1.2.0

3 years ago

1.2.1

3 years ago

1.1.9

3 years ago

1.1.8

3 years ago

1.1.7

3 years ago

1.1.6

3 years ago

1.1.5

3 years ago

1.1.4

3 years ago

1.1.3

3 years ago

1.1.2

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.9

4 years ago

1.0.8

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago