* Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the *
(lines)
| 17 | */ |
| 18 | |
| 19 | function tooltipElement(lines) { |
| 20 | var container = document.createElement("div"); |
| 21 | lines.forEach(function(line, i) { |
| 22 | if (line.bold) { |
| 23 | var b = document.createElement("b"); |
| 24 | b.textContent = line.text; |
| 25 | container.appendChild(b); |
| 26 | } else { |
| 27 | container.appendChild(document.createTextNode(line.text)); |
| 28 | } |
| 29 | if (i < lines.length - 1) { |
| 30 | container.appendChild(document.createElement("br")); |
| 31 | } |
| 32 | }); |
| 33 | return container; |
| 34 | } |
| 35 | |
| 36 | var visNS = { |
| 37 | // Update / refresh setting |