Rename button parameter
This commit is contained in:
@@ -145,7 +145,6 @@
|
||||
$: if (containerElem) {
|
||||
const canvas = containerElem.querySelector<HTMLDivElement>("#graph-canvas")
|
||||
if (canvas) {
|
||||
console.warn("reg!");
|
||||
const paneNode = canvas.closest(".splitpanes__pane")
|
||||
if (paneNode) {
|
||||
(paneNode as HTMLElement).ontransitionstart = () => {
|
||||
|
||||
@@ -99,6 +99,13 @@
|
||||
if (spec.canShow)
|
||||
return spec.canShow(widget);
|
||||
|
||||
if (widget.type === "widget" && spec.validNodeTypes) {
|
||||
const node = (widget as WidgetLayout).node
|
||||
if (!node)
|
||||
return false;
|
||||
return spec.validNodeTypes.indexOf(node.type) !== -1;
|
||||
}
|
||||
|
||||
return spec.name in widget.attrs
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user