Skip to content

Commit

Permalink
feat: update vue virtual scroll version and add virtual scroll props …
Browse files Browse the repository at this point in the history
…and function

build: build package

test: fix scroll test

build: build dist
  • Loading branch information
vip30 committed Apr 23, 2021
1 parent 6c6c842 commit 42c097b
Show file tree
Hide file tree
Showing 28 changed files with 13,345 additions and 1,044 deletions.
78 changes: 78 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
# vue-draggable-virtual-scroll-list

[![](https://github.com/p-baleine/vue-draggable-virtual-scroll-list/workflows/CI/badge.svg)]()


# Description

🔌 [SortableJS/Vue.Draggable][] + ⚡ [tangbc/vue-virtual-scroll-list][] =
💡✨

Vue component who put [SortableJS/Vue.Draggable][] and
[tangbc/vue-virtual-scroll-list][] together and allow drag-and-drop and
big amount data list with high scroll performance.

![](images/screenshot.gif)

# Usage

``` html
<div id="main">
<draggable-virtual-list
class="phrase-list"
v-model="items"
:size="50"
:keeps="20"
:data-key="'id'"
:data-sources="items"
:data-component="Item"
>
</draggable-virtual-list>
</div>

<script>
const Item = {
props: {
source: {
type: Object,
default () {
return {}
},
},
},
template: `
<div class="phrase" :key="source.id">
{{ source.content }}
</div>
`
}
new Vue({
el: '#main',
components: {
DraggableVirtualList,
},
data() {
return {
items: [
{ source: { id: 1, content: 'hello' } },
{ source: { id: 2, content: world' } },
// ...
],
Item
}
},
})
</script>
```
Please see [./example/index.html][].
# License
<span class="spurious-link" target="LICENSE">*MIT License.*</span>
[1]: https://github.com/p-baleine/vue-draggable-virtual-scroll-list/workflows/CI/badge.svg
[SortableJS/Vue.Draggable]: https://github.com/SortableJS/Vue.Draggable
[tangbc/vue-virtual-scroll-list]: https://github.com/tangbc/vue-virtual-scroll-list
[./example/index.html]: ./example/index.html
70 changes: 0 additions & 70 deletions README.org

This file was deleted.

114 changes: 57 additions & 57 deletions dist/broker/draggable-policy.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/broker/draggable-policy.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 42c097b

Please sign in to comment.