Skip to content

Commit

Permalink
docs: add security policy (#1911)
Browse files Browse the repository at this point in the history
* fix: 🐛 change the order of statement (#1910)

* chore: update AUTHORS [skip ci]

* docs: add security policy

add security policy

Co-authored-by: x6-bot[bot] <71382382+x6-bot[bot]@users.noreply.github.com>
  • Loading branch information
NewByVector and x6-bot[bot] authored Mar 21, 2022
1 parent d060d34 commit 9e19ab9
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ lopn <[email protected]>
luchunwei <[email protected]>
luzhuang <[email protected]>
lvhuiyang <[email protected]>
newbyvector <[email protected]>
niexq <[email protected]>
niexq <[email protected]>
pengxingjian.pxj <[email protected]>
Expand Down
21 changes: 21 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Security Policy

## Supported Versions

Use this section to tell people about which versions of your project are
currently being supported with security updates.

| Version | Supported |
| ------- | ------------------ |
| 5.1.x | :white_check_mark: |
| 5.0.x | :x: |
| 4.0.x | :white_check_mark: |
| < 4.0 | :x: |

## Reporting a Vulnerability

Use this section to tell people how to report a vulnerability.

Tell them where to go, how often they can expect to get an update on a
reported vulnerability, what to expect if the vulnerability is accepted or
declined, etc.
3 changes: 1 addition & 2 deletions packages/x6/src/registry/tool/editor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ export class CellEditor extends ToolsView.ToolItem<
const parent = target.parentElement
const isEdgeLabel =
parent && Dom.hasClass(parent, this.prefixClassName('edge-label'))
const labelAddable = this.options.labelAddable
if (isEdgeLabel) {
const index = parent.getAttribute('data-index') || '0'
this.labelIndex = parseInt(index, 10)
Expand All @@ -58,7 +57,7 @@ export class CellEditor extends ToolsView.ToolItem<
pos = new Point(translation.tx, translation.ty)
minWidth = Dom.getBBox(target).width
} else {
if (!labelAddable) {
if (!this.options.labelAddable) {
return this
}
pos = graph.clientToLocal(Point.create(e.clientX, e.clientY))
Expand Down

0 comments on commit 9e19ab9

Please sign in to comment.