Skip to content

Commit f901bd7

Browse files
committed
- upgrade dependencies
- improve dynamic height measurer
1 parent 2470bd4 commit f901bd7

File tree

5 files changed

+1389
-899
lines changed

5 files changed

+1389
-899
lines changed

dev/serve.vue

Lines changed: 29 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
11
<script>
22
import Vue from 'vue';
33
import ExpandingList from '@/ExpandingList';
4+
import VirtualScroll from '@/VirtualScroll';
45
56
export default Vue.extend({
67
name: 'ServeDev',
78
components: {
89
ExpandingList,
10+
VirtualScroll,
911
},
1012
data() {
1113
return {
1214
expandedGroup: -1,
15+
flatItems: [1, 2, 3, 4],
1316
items: {
1417
number: [
1518
1,
@@ -120,16 +123,31 @@ export default Vue.extend({
120123

121124
<template>
122125
<div id="app">
123-
<ExpandingList
124-
:items="items"
125-
:expanded-group="expandedGroup"
126-
@expand="onExpandGroup">
127-
<template #group="{ item }">
128-
<span v-text="item" />
129-
</template>
130-
<template #item="{ item }">
131-
<li v-text="item" />
132-
</template>
133-
</ExpandingList>
126+
<div class="horizontal-wrapper">
127+
<ExpandingList
128+
:items="items"
129+
:expanded-group="expandedGroup"
130+
@expand="onExpandGroup">
131+
<template #group="{ item }">
132+
<span v-text="item" />
133+
</template>
134+
<template #item="{ item }">
135+
<li v-text="item" />
136+
</template>
137+
</ExpandingList>
138+
<VirtualScroll :items="flatItems">
139+
<template #item="{ item }">
140+
<li v-text="item" />
141+
</template>
142+
</VirtualScroll>
143+
</div>
134144
</div>
135145
</template>
146+
147+
<style lang="scss" scoped>
148+
.horizontal-wrapper {
149+
display: grid;
150+
grid-column-gap: 24px;
151+
grid-template-columns: max-content max-content;
152+
}
153+
</style>

0 commit comments

Comments
 (0)