(content)
| 95 | } |
| 96 | |
| 97 | _setContent(content) { |
| 98 | if (!content) return this.hide(); |
| 99 | this.show(); |
| 100 | if (this._content === content) return; |
| 101 | this._content = content; |
| 102 | |
| 103 | if (typeof content === 'string') { |
| 104 | this.contentNode.innerHTML = content; |
| 105 | this.contentNode.className = 'textContent'; |
| 106 | } else if (content?.nodeType && content?.nodeName) { |
| 107 | this._setContentNode(content); |
| 108 | } else { |
| 109 | if (this.contentNode.firstChild?.localName == 'property-link-table') { |
| 110 | this.contentNode.firstChild.propertyDict = content; |
| 111 | } else { |
| 112 | const node = DOM.element('property-link-table'); |
| 113 | node.instanceLinkButtons = true; |
| 114 | node.propertyDict = content; |
| 115 | this._setContentNode(node); |
| 116 | } |
| 117 | } |
| 118 | } |
| 119 | |
| 120 | _setContentNode(content) { |
| 121 | const newContent = DOM.div(); |
no test coverage detected