Skip to content

Commit 6df0b05

Browse files
committed
add node class
1 parent 339246f commit 6df0b05

14 files changed

+8071
-3307
lines changed

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ createApp(App)
145145
labelWidth | node label width | `String` \| `Number` | `auto`
146146
collapsable | children node is collapsable | `Boolean` | `true`
147147
renderContent | how to render node label | `Function` | -
148+
nodeClassName | custom node class | `Function` \| `String` | -
148149
labelClassName | node label class | `Function` \| `String` | -
149150

150151

demo/demo-app.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
<h1>Basic</h1>
99
<div>
10-
<blocks-tree :props="{label: 'label', expand: 'expand', children: 'children', key:'some_id'}" :data="treeData" :horizontal="treeOrientation=='1'" :collapsable="true"></blocks-tree>
10+
<blocks-tree :props="{label: 'label', expand: 'expand', children: 'children', key:'some_id'}" node-class-name="my-node-class" label-class-name="my-label-class" :data="treeData" :horizontal="treeOrientation=='1'" :collapsable="true"></blocks-tree>
1111
</div>
1212
<h1>With slots</h1>
1313
<div>

0 commit comments

Comments
 (0)