MCPcopy Index your code
hub / github.com/bqplot/bqplot / clear_style

Method clear_style

js/src/Graph.ts:549–561  ·  view source on GitHub ↗
(style_dict, indices)

Source from the content-addressed store, hash-verified

547 }
548
549 clear_style(style_dict, indices) {
550 let nodes = this.d3el.selectAll('.element');
551 if (indices) {
552 nodes = nodes.filter((d, index) => {
553 return indices.indexOf(index) !== -1;
554 });
555 }
556 const clearing_style = {};
557 for (const key in style_dict) {
558 clearing_style[key] = null;
559 }
560 applyStyles(nodes, clearing_style);
561 }
562
563 set_style_on_elements(style, indices) {
564 // If the index array is undefined or of length=0, exit the

Callers 2

hovered_style_updatedMethod · 0.95

Calls 1

applyStylesFunction · 0.90

Tested by

no test coverage detected