Skip to content

Commit

Permalink
docs: remove deprecated Addon usage
Browse files Browse the repository at this point in the history
  • Loading branch information
mewcoder authored and mewcoder committed Mar 11, 2024
1 parent 4dbc5e5 commit 67acd77
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sites/x6-sites/docs/tutorial/plugins/dnd.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ const dnd = new Dnd({
3.怎么自定义放置到画布上的节点样式?

```ts
const dnd = new Addon.Dnd({
const dnd = new Dnd({
getDropNode(node) {
const { width, height } = node.size()
// 返回一个新的节点作为实际放置到画布上的节点
Expand Down
2 changes: 1 addition & 1 deletion sites/x6-sites/docs/tutorial/plugins/stencil.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ const stencil = new Stencil({
})

// 搜索 text 包含关键字的 rect 节点
const stencil = new Addon.Stencil({
const stencil = new Stencil({
search: (cell, keyword, groupName, stencil) => {
if (keyword) {
return cell.shape === 'rect' && cell.attr('text/text').includes(keyword)
Expand Down

0 comments on commit 67acd77

Please sign in to comment.