g6/packages/site/examples/tool/legend/index.en.md
2023-02-02 10:31:36 +08:00

441 B

title order
Legend 9

Using contextMenu in G6.

Usage

The demo below show how to use contextMenu on a graph. Menu's style can be defined by the CSS:

/* Define the CSS with the id of your menu */
  #contextMenu {
    position: absolute;
    /* ... Other styles */
  }
  #contextMenu li {
    cursor: pointer;
		/* ... Other styles */
  }
  #contextMenu li:hover {
    color: #aaa;
    /* ... Other styles */
  }
`);