Merge branch 'main' into 1.4.0
This commit is contained in:
@@ -119,14 +119,18 @@ import {
|
||||
Polyline as PolylineIcon,
|
||||
QueryStats as QueryStatsIcon,
|
||||
AutoAwesome as AutoAwesomeIcon,
|
||||
|
||||
Add as AddIcon,
|
||||
ErrorOutline as ErrorOutlineIcon,
|
||||
|
||||
} from "@mui/icons-material";
|
||||
|
||||
//import * as cytoscape from "cytoscape";
|
||||
import cytoscape from "cytoscape";
|
||||
|
||||
|
||||
import edgehandles from "cytoscape-edgehandles";
|
||||
|
||||
import CytoscapeComponent from "react-cytoscapejs";
|
||||
|
||||
import Draggable from "react-draggable";
|
||||
@@ -9325,6 +9329,7 @@ const AngularWorkflow = (defaultprops) => {
|
||||
newSelectedAction.example = newaction.returns.example;
|
||||
}
|
||||
|
||||
|
||||
if (
|
||||
newaction.description !== undefined &&
|
||||
newaction.description !== null &&
|
||||
@@ -15210,6 +15215,8 @@ const AngularWorkflow = (defaultprops) => {
|
||||
</div>
|
||||
: null
|
||||
|
||||
|
||||
|
||||
const RightsideBar = () => {
|
||||
const [hovered, setHovered] = useState(false)
|
||||
|
||||
@@ -15270,6 +15277,59 @@ const AngularWorkflow = (defaultprops) => {
|
||||
return null
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
const handleKeyDown = (event) => {
|
||||
if ((event.metaKey || event.ctrlKey) && event.key === '/') {
|
||||
event.preventDefault(); // Prevent default browser behavior (like opening search bar)
|
||||
if (!workflow.public && !executionRequestStarted) {
|
||||
executeWorkflow(executionText, workflow.start, lastSaved);
|
||||
}
|
||||
}
|
||||
if ((event.ctrlKey || event.metaKey) && event.key === "'") {
|
||||
// Check if Ctrl (Windows/Linux) or Command (Mac) key is pressed along with '/'
|
||||
if (!workflow.public && !executionModalOpen) {
|
||||
setExecutionModalOpen(true);
|
||||
getWorkflowExecution(props.match.params.key, "");
|
||||
} else if (!workflow.public && executionModalOpen) {
|
||||
setExecutionModalOpen(false);
|
||||
}
|
||||
}
|
||||
|
||||
if ((event.ctrlKey || event.metaKey) && event.key === "]") {
|
||||
console.log("Show workflow revisions key pressed")
|
||||
if (!workflow.public) {
|
||||
setShowWorkflowRevisions(true)
|
||||
setSelectedRevision(workflow)
|
||||
//setOriginalWorkflow(workflow)
|
||||
}
|
||||
}
|
||||
|
||||
if (( event.ctrlKey || event.metaKey ) && event.key === ";") {
|
||||
if (!workflow.public && executionModalOpen) {
|
||||
getWorkflowExecution(props.match.params.key, "");
|
||||
}
|
||||
}
|
||||
|
||||
if (( event.ctrlKey || event.metaKey ) && event.shiftKey) {
|
||||
console.log("Shift key pressed")
|
||||
if (!workflow.public && executionModalOpen) {
|
||||
setExecutionRunning(false);
|
||||
stop()
|
||||
const cursearch = typeof window === "undefined" || window.location === undefined ? "" : window.location.search;
|
||||
const newitem = removeParam("execution_id", cursearch);
|
||||
navigate(curpath + newitem)
|
||||
setExecutionModalView(0);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
document.addEventListener('keydown', handleKeyDown);
|
||||
|
||||
return () => {
|
||||
document.removeEventListener('keydown', handleKeyDown);
|
||||
};
|
||||
}, [executeWorkflow, executionText, workflow, lastSaved, executionRequestStarted]);
|
||||
|
||||
return (
|
||||
<div
|
||||
style={{
|
||||
@@ -17037,6 +17097,7 @@ const AngularWorkflow = (defaultprops) => {
|
||||
</div>
|
||||
) : (
|
||||
<div style={{ padding: isMobile ? "0px 10px 25px 10px" : "25px 15px 25px 15px", maxWidth: isMobile ? "100%" : "100%", overflowX: "hidden" }}>
|
||||
|
||||
|
||||
<Breadcrumbs
|
||||
aria-label="breadcrumb"
|
||||
|
||||
Reference in New Issue
Block a user