Language: JavaScript
Label: safe
CWE: CWE-79 \u2014 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.

Code:
"simple"==Editor.currentTheme&&this.addMenuItems(K,["zoomIn","zoomOut","-"],null,m);L.apply(this,arguments);g.isSelectionEmpty()||null==d.addSelectionToScratchpad||this.addMenuItems(K,["-","addToScratchpad"],null,m);g.isSelectionEmpty()&&"simple"==Editor.currentTheme&&this.addMenuItems(K,["-","exitGroup","home"],null,m)};var G=Menus.prototype.addPopupMenuEditItems;this.menus.addPopupMenuEditItems=function(K,R,m){if(d.editor.graph.isSelectionEmpty())G.apply(this,arguments),d.menus.addMenuItems(K,["copyAsImage"],
null,m);else if(this.isShowCellEditItems()?this.addPopupDeleteItem(K,R,m):this.addPopupMenuArrangeItems(K,R,m),this.addMenuItems(K,"- cut copy copyAsImage duplicate -".split(" "),null,m),this.isShowCellEditItems()||this.addPopupDeleteItem(K,R,m),this.addMenuItems(K,["lockUnlock","-"],null,m),!this.isShowStyleItems()){if(1==g.getSelectionCount()&&!g.isCellLocked(R)&&g.isCellEditable(R)&&(this.addSubmenu("editCell",K,null,mxResources.get("edit")),K.addSeparator(),g.getModel().isEdge(R))){this.addSubmenu("line",
K);var A=g.getModel().getGeometry(R);null!=A&&null!=A.points&&0<A.points.length&&this.addMenuItems(K,["clearWaypoints"],null,m)}1==g.getSelectionCount()&&this.addMenuItems(K,["enterGroup"],null,m);A=d.getSelectionState();null!=A.mergeCell?this.addMenuItem(K,"mergeCells"):(1<A.style.colspan||1<A.style.rowspan)&&this.addMenuItem(K,"unmergeCells")}};this.menus.isShowStyleItems=function(){return"simple"!=Editor.currentTheme&&"sketch"!=Editor.currentTheme&&"min"!=Editor.currentTheme};this.menus.isShowHistoryItems=