mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-19 02:51:14 +00:00
⚡ Improve plus endpoint string rendering
This commit is contained in:
@@ -181,6 +181,7 @@ export const nodeBase = mixins(
|
||||
hover: false,
|
||||
showOutputLabel: nodeTypeData.outputs.length === 1,
|
||||
size: nodeTypeData.outputs.length >= 3 ? 'small' : 'medium',
|
||||
hoverMessage: this.$baseText('nodesBase.clickToAddNodeOrDragToConnect'),
|
||||
},
|
||||
endpointHoverStyle: {
|
||||
fill: getStyleTokenValue('--color-primary'),
|
||||
@@ -204,14 +205,6 @@ export const nodeBase = mixins(
|
||||
index: i,
|
||||
totalEndpoints: nodeTypeData.outputs.length,
|
||||
};
|
||||
|
||||
const _plusEndpoint = this.instance.getEndpoint(
|
||||
CanvasHelpers.getOutputEndpointUUID(this.nodeIndex, index),
|
||||
);
|
||||
|
||||
const dropHoverMessageDiv = _plusEndpoint.canvas.children[1].children[1];
|
||||
|
||||
dropHoverMessageDiv.innerHTML = this.$baseText('nodesBase.clickToAddNodeOrDragToConnect');
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
@@ -461,6 +461,11 @@
|
||||
this.size = endpointStyle.size || this.size;
|
||||
this.showOutputLabel = !!endpointStyle.showOutputLabel;
|
||||
|
||||
if (this.hoverMessage !== endpointStyle.hoverMessage) {
|
||||
this.hoverMessage = endpointStyle.hoverMessage;
|
||||
message.innerHTML = endpointStyle.hoverMessage;
|
||||
}
|
||||
|
||||
if (this.size !== 'medium') {
|
||||
container.classList.add(this.size);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user