File tree Expand file tree Collapse file tree 4 files changed +9
-3
lines changed Expand file tree Collapse file tree 4 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -78,6 +78,8 @@ export default {
78
78
79
79
## Usage:
80
80
81
+ :warning : When using virtual scrolling, ` node-key ` must be set
82
+
81
83
``` html
82
84
<template >
83
85
<div class =" ve-tree" style =" height :calc (100vh - 20px )" >
Original file line number Diff line number Diff line change @@ -78,6 +78,8 @@ export default {
78
78
79
79
## 使用:
80
80
81
+ :warning : 在使用虚拟滚动时,必须设置 ` node-key ` 。
82
+
81
83
``` html
82
84
<template >
83
85
<div class =" ve-tree" style =" height :calc (100vh - 20px )" >
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @wchbrad/vue-easy-tree" ,
3
3
"description" : " A Vue.js project" ,
4
- "version" : " 1.0.5 " ,
4
+ "version" : " 1.0.6 " ,
5
5
"author" :
" wchbrad <[email protected] >" ,
6
6
"license" : " MIT" ,
7
- "private" : false ,
7
+ "private" : true ,
8
8
"main" : " ./dist/vue-easy-tree.js" ,
9
9
"keywords" : [
10
10
" virtual" ,
Original file line number Diff line number Diff line change @@ -235,7 +235,9 @@ export default {
235
235
return treeData .reduce ((smoothArr , data ) => {
236
236
if (data .visible ) {
237
237
// Mark different types to avoid being optimized out when assembled into the same dom
238
- data .type = ` ${ data .level } -${ data .expanded } -${ data .checked } ` ;
238
+ data .type = this .showCheckbox
239
+ ? ` ${ data .level } -${ data .checked } -${ data .indeterminate } `
240
+ : ` ${ data .level } -${ data .expanded } ` ;
239
241
smoothArr .push (data);
240
242
}
241
243
if (data .expanded && data .childNodes .length ) {
You can’t perform that action at this time.
0 commit comments