mirror of
https://github.com/GNS3/gns3-web-ui.git
synced 2025-01-03 11:34:12 +00:00
Update ethernet-link.ts
This commit is contained in:
parent
44e1b3d656
commit
ac265a90bf
@ -46,24 +46,15 @@ export class EthernetLinkWidget implements Widget {
|
|||||||
let link: MapLink = (datum as unknown) as MapLink;
|
let link: MapLink = (datum as unknown) as MapLink;
|
||||||
const evt = event;
|
const evt = event;
|
||||||
this.onContextMenu.emit(new LinkContextMenu(evt, link));
|
this.onContextMenu.emit(new LinkContextMenu(evt, link));
|
||||||
});
|
})
|
||||||
|
|
||||||
link_enter
|
|
||||||
.attr('stroke', (datum) => {
|
.attr('stroke', (datum) => {
|
||||||
let link: MapLink = (datum as unknown) as MapLink;
|
|
||||||
return datum.style.color;
|
return datum.style.color;
|
||||||
})
|
})
|
||||||
.attr('stroke-width', (datum) => {
|
.attr('stroke-width', (datum) => {
|
||||||
let link: MapLink = (datum as unknown) as MapLink;
|
|
||||||
return datum.style.width;
|
return datum.style.width;
|
||||||
})
|
})
|
||||||
.attr('stroke-dasharray', (datum) => {
|
.attr('stroke-dasharray', (datum) => {
|
||||||
return StyleTranslator.getLinkStyle(datum.style);
|
return StyleTranslator.getLinkStyle(datum.style);
|
||||||
})
|
|
||||||
.on('contextmenu', (datum) => {
|
|
||||||
let link: MapLink = (datum as unknown) as MapLink;
|
|
||||||
const evt = event;
|
|
||||||
this.onContextMenu.emit(new LinkContextMenu(evt, link));
|
|
||||||
});
|
});
|
||||||
|
|
||||||
const link_merge = link.merge(link_enter);
|
const link_merge = link.merge(link_enter);
|
||||||
|
Loading…
Reference in New Issue
Block a user