mirror of
https://github.com/barsdeveloper/ueblueprint.git
synced 2026-03-02 13:07:30 +08:00
Graph link work in progress
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import GraphElement from "./GraphElement"
|
||||
import PinTemplate from "../template/PinTemplate"
|
||||
import DragLink from "../input/DragLink"
|
||||
import GraphLink from "./GraphLink"
|
||||
|
||||
export default class GraphPin extends GraphElement {
|
||||
|
||||
@@ -46,6 +47,23 @@ export default class GraphPin extends GraphElement {
|
||||
getType() {
|
||||
return this.entity.getType()
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @returns {GraphLink} The link created
|
||||
*/
|
||||
dragLink() {
|
||||
let link = new GraphLink(this)
|
||||
return link
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns The exact location where the link originates from or arrives at.
|
||||
* @returns {Number[]} The location array
|
||||
*/
|
||||
getLinkLocation() {
|
||||
return [0, 0];
|
||||
}
|
||||
}
|
||||
|
||||
customElements.define("ueb-pin", GraphPin)
|
||||
|
||||
Reference in New Issue
Block a user