mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-29 02:32:18 +00:00
Formatting improvements,
The formatting of ndoes using the existing standardized tooltips has been improved. Experiemental work for assisting nodes with display of more detailed descriptions
This commit is contained in:
@@ -183,19 +183,22 @@ function updateNode(node) {
|
|||||||
'<div><b>' + outputs[i] + '</b>: ' + def.output_tooltips[i] + '</div>'
|
'<div><b>' + outputs[i] + '</b>: ' + def.output_tooltips[i] + '</div>'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (content == '') {
|
||||||
|
content = 'No documentation available'
|
||||||
|
}
|
||||||
helpDOM.innerHTML = content
|
helpDOM.innerHTML = content
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var bringToFront
|
|
||||||
app.registerExtension({
|
app.registerExtension({
|
||||||
name: 'Comfy.longformDocumentation',
|
name: 'Comfy.longformDocumentation',
|
||||||
async beforeRegisterNodeDef(nodeType, nodeData, app) {
|
async beforeRegisterNodeDef(nodeType, nodeData, app) {
|
||||||
if (typeof nodeData.description == 'Object') {
|
//TODO: Find better method. Likely require explicit opt in
|
||||||
nodeData.description = 'redirected'
|
if (nodeData.description.includes('</div>') && !nodeData.longDescription) {
|
||||||
|
nodeData.longDescription = nodeData.description
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
var bringToFront
|
||||||
let documentationSidebar = {
|
let documentationSidebar = {
|
||||||
id: 'documentationSidebar',
|
id: 'documentationSidebar',
|
||||||
title: 'Documentation',
|
title: 'Documentation',
|
||||||
|
|||||||
Reference in New Issue
Block a user