bugfix-layered-links #9
							
								
								
									
										10
									
								
								main.js
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								main.js
									
									
									
									
									
								
							| @ -103,11 +103,13 @@ function setBackground(c) { | |||||||
| } | } | ||||||
| 
 | 
 | ||||||
| function setLinkOpacity(o, primary) { | function setLinkOpacity(o, primary) { | ||||||
| 	if( primary ) { | 	if( structure.nolink2opacity ) { | ||||||
| 		link_ms[0].opacity = o; | 		link_ms.map((lm) => lm.opacity = o); | ||||||
| 	} else { | 	} else { | ||||||
| 		for( const lm of link_ms.slice(1) ) { | 		if( primary ) { | ||||||
| 			lm.opacity = o; | 			link_ms[0].opacity = o; | ||||||
|  | 		} else { | ||||||
|  | 			link_ms.slice(1).map((lm) => lm.opacity = o); | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|  | |||||||
| @ -397,6 +397,7 @@ export const cell120_layered = (max) => { | |||||||
| 			node_size: 0.02, | 			node_size: 0.02, | ||||||
| 			link_size: 0.02 | 			link_size: 0.02 | ||||||
| 		}, | 		}, | ||||||
|  | 		nolink2opacity: true, | ||||||
| 		options: options | 		options: options | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
| @ -598,7 +599,6 @@ function get_node(nodes, id) { | |||||||
| } | } | ||||||
| 
 | 
 | ||||||
| function audit_link_labels(nodes, links) { | function audit_link_labels(nodes, links) { | ||||||
| 	console.log("Link audit"); |  | ||||||
| 	for( const l of links ) { | 	for( const l of links ) { | ||||||
| 		const n1 = get_node(nodes, l.source); | 		const n1 = get_node(nodes, l.source); | ||||||
| 		const n2 = get_node(nodes, l.target); | 		const n2 = get_node(nodes, l.target); | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user