windmill-components 1.35.42 → 1.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/AppConnect.svelte +85 -59
- package/components/ArgInput.svelte +50 -33
- package/components/ArgInput.svelte.d.ts +1 -1
- package/components/Button.svelte +15 -48
- package/components/Button.svelte.d.ts +1 -1
- package/components/CronInput.svelte +1 -1
- package/components/DisplayResult.svelte +75 -67
- package/components/Dropdown.svelte +9 -7
- package/components/Editor.svelte +187 -178
- package/components/Editor.svelte.d.ts +4 -2
- package/components/EditorBar.svelte +135 -98
- package/components/EditorBar.svelte.d.ts +2 -1
- package/components/FlowBuilder.svelte +115 -134
- package/components/FlowJobResult.svelte +4 -5
- package/components/FlowModulesViewer.svelte +89 -7
- package/components/FlowModulesViewer.svelte.d.ts +1 -0
- package/components/FlowPreviewContent.svelte +88 -27
- package/components/FlowPreviewContent.svelte.d.ts +1 -1
- package/components/FlowStatusViewer.svelte +39 -24
- package/components/FlowStatusViewer.svelte.d.ts +0 -1
- package/components/FlowViewer.svelte +17 -11
- package/components/GroupModal.svelte +10 -1
- package/components/HighlightCode.svelte +22 -0
- package/components/HighlightCode.svelte.d.ts +17 -0
- package/components/IconedPath.svelte +9 -7
- package/components/InputTransformForm.svelte +97 -115
- package/components/InputTransformForm.svelte.d.ts +0 -1
- package/components/InputTransformsViewer.svelte +1 -1
- package/components/InviteGlobalUser.svelte +8 -8
- package/components/InviteUser.svelte +9 -9
- package/components/ItemPicker.svelte +37 -30
- package/components/ItemPicker.svelte.d.ts +2 -1
- package/components/JobStatus.svelte +2 -1
- package/components/LogViewer.svelte +23 -0
- package/components/LogViewer.svelte.d.ts +19 -0
- package/components/ModulePreview.svelte +107 -0
- package/components/ModulePreview.svelte.d.ts +24 -0
- package/components/Path.svelte +1 -1
- package/components/RadioButton.svelte +3 -2
- package/components/ResourceEditor.svelte +22 -34
- package/components/ResourceTypePicker.svelte +23 -34
- package/components/RunForm.svelte +34 -31
- package/components/RunForm.svelte.d.ts +6 -2
- package/components/SchemaEditor.svelte +19 -11
- package/components/SchemaForm.svelte +3 -3
- package/components/SchemaForm.svelte.d.ts +1 -1
- package/components/SchemaModal.svelte +18 -7
- package/components/ScriptBuilder.svelte +99 -83
- package/components/ScriptBuilder.svelte.d.ts +2 -4
- package/components/ScriptEditor.svelte +71 -143
- package/components/ScriptEditor.svelte.d.ts +0 -5
- package/components/ScriptPicker.svelte +24 -14
- package/components/ScriptPicker.svelte.d.ts +2 -1
- package/components/ScriptSchema.svelte +8 -11
- package/components/ScriptSchema.svelte.d.ts +0 -1
- package/components/ShareModal.svelte +6 -6
- package/components/SharedBadge.svelte +5 -13
- package/components/SimpleEditor.svelte +14 -10
- package/components/StringTypeNarrowing.svelte +24 -30
- package/components/TestJobLoader.svelte +106 -0
- package/components/TestJobLoader.svelte.d.ts +26 -0
- package/components/Tooltip.svelte +3 -2
- package/components/VariableEditor.svelte +15 -24
- package/components/common/actionRow/ActionRow.svelte +31 -0
- package/components/common/actionRow/ActionRow.svelte.d.ts +22 -0
- package/components/common/alert/Alert.svelte +53 -0
- package/components/common/alert/Alert.svelte.d.ts +20 -0
- package/components/common/alert/model.d.ts +1 -0
- package/components/common/alert/model.js +1 -0
- package/components/common/badge/Badge.svelte +76 -0
- package/components/common/badge/Badge.svelte.d.ts +28 -0
- package/components/common/badge/model.d.ts +8 -0
- package/components/common/badge/model.js +1 -0
- package/components/common/button/Button.svelte +110 -0
- package/components/common/button/Button.svelte.d.ts +39 -0
- package/components/common/button/model.d.ts +6 -0
- package/components/common/button/model.js +1 -0
- package/components/common/confirmationModal/ConfirmationModal.svelte +72 -0
- package/components/common/confirmationModal/ConfirmationModal.svelte.d.ts +23 -0
- package/components/common/confirmationModal/UnsavedConfirmationModal.svelte +41 -0
- package/components/common/confirmationModal/UnsavedConfirmationModal.svelte.d.ts +14 -0
- package/components/common/confirmationModal/dirtyStore.d.ts +1 -0
- package/components/common/confirmationModal/dirtyStore.js +2 -0
- package/components/common/drawer/Drawer.svelte +3 -0
- package/components/common/drawer/Drawer.svelte.d.ts +2 -0
- package/components/common/index.d.ts +14 -0
- package/components/common/index.js +14 -0
- package/components/common/tabs/TabContent.svelte +3 -2
- package/components/common/tabs/TabContent.svelte.d.ts +1 -0
- package/components/common/tabs/Tabs.svelte +8 -1
- package/components/common/tabs/Tabs.svelte.d.ts +2 -0
- package/components/common/toggleButton/ToggleButton.svelte +20 -0
- package/components/common/toggleButton/ToggleButton.svelte.d.ts +19 -0
- package/components/common/toggleButton/ToggleButtonGroup.svelte +33 -0
- package/components/common/toggleButton/ToggleButtonGroup.svelte.d.ts +24 -0
- package/components/flows/FlowEditor.svelte +30 -0
- package/components/{FlowEditor.svelte.d.ts → flows/FlowEditor.svelte.d.ts} +1 -6
- package/components/flows/common/FlowCard.svelte +9 -0
- package/components/flows/common/FlowCard.svelte.d.ts +21 -0
- package/components/flows/common/FlowCardHeader.svelte +39 -0
- package/components/flows/common/FlowCardHeader.svelte.d.ts +20 -0
- package/components/flows/content/CopyFirstStepSchema.svelte +13 -0
- package/components/flows/{CopyFirstStepSchema.svelte.d.ts → content/CopyFirstStepSchema.svelte.d.ts} +0 -0
- package/components/flows/{DynamicInputHelpBox.svelte → content/DynamicInputHelpBox.svelte} +0 -0
- package/components/flows/{DynamicInputHelpBox.svelte.d.ts → content/DynamicInputHelpBox.svelte.d.ts} +0 -0
- package/components/flows/content/FlowEditorPanel.svelte +25 -0
- package/components/flows/content/FlowEditorPanel.svelte.d.ts +16 -0
- package/components/flows/content/FlowFailureModule.svelte +15 -0
- package/components/flows/content/FlowFailureModule.svelte.d.ts +14 -0
- package/components/flows/content/FlowInput.svelte +26 -0
- package/components/flows/{FlowInput.svelte.d.ts → content/FlowInput.svelte.d.ts} +0 -0
- package/components/flows/content/FlowInputs.svelte +91 -0
- package/components/flows/{FlowInputs.svelte.d.ts → content/FlowInputs.svelte.d.ts} +1 -0
- package/components/flows/content/FlowLoop.svelte +168 -0
- package/components/flows/content/FlowLoop.svelte.d.ts +18 -0
- package/components/flows/content/FlowLoopWrapper.svelte +9 -0
- package/components/flows/content/FlowLoopWrapper.svelte.d.ts +14 -0
- package/components/flows/content/FlowModule.svelte +211 -0
- package/components/flows/content/FlowModule.svelte.d.ts +29 -0
- package/components/flows/content/FlowModuleEarlyStop.svelte +76 -0
- package/components/flows/content/FlowModuleEarlyStop.svelte.d.ts +17 -0
- package/components/flows/content/FlowModuleHeader.svelte +157 -0
- package/components/flows/{FlowModuleHeader.svelte.d.ts → content/FlowModuleHeader.svelte.d.ts} +5 -3
- package/components/flows/content/FlowModuleScript.svelte +21 -0
- package/components/flows/content/FlowModuleScript.svelte.d.ts +17 -0
- package/components/flows/content/FlowModuleSuspend.svelte +27 -0
- package/components/flows/content/FlowModuleSuspend.svelte.d.ts +17 -0
- package/components/flows/content/FlowModuleWrapper.svelte +45 -0
- package/components/flows/content/FlowModuleWrapper.svelte.d.ts +14 -0
- package/components/flows/content/FlowRetries.svelte +80 -0
- package/components/flows/content/FlowRetries.svelte.d.ts +17 -0
- package/components/flows/content/FlowSchedules.svelte +18 -0
- package/components/flows/content/FlowSchedules.svelte.d.ts +14 -0
- package/components/flows/content/FlowSettings.svelte +78 -0
- package/components/flows/{FlowSettings.svelte.d.ts → content/FlowSettings.svelte.d.ts} +2 -6
- package/components/flows/content/RemoveStepConfirmationModal.svelte +32 -0
- package/components/flows/content/RemoveStepConfirmationModal.svelte.d.ts +19 -0
- package/components/flows/flowState.d.ts +8 -7
- package/components/flows/flowState.js +25 -46
- package/components/flows/flowStateUtils.d.ts +16 -14
- package/components/flows/flowStateUtils.js +81 -73
- package/components/flows/flowStore.js +7 -4
- package/components/flows/header/FlowImportExportMenu.svelte +55 -0
- package/components/flows/header/FlowImportExportMenu.svelte.d.ts +14 -0
- package/components/flows/header/FlowPreviewButtons.svelte +57 -0
- package/components/flows/header/FlowPreviewButtons.svelte.d.ts +14 -0
- package/components/flows/map/FlowErrorHandlerItem.svelte +60 -0
- package/components/flows/map/FlowErrorHandlerItem.svelte.d.ts +14 -0
- package/components/flows/map/FlowModuleSchemaItem.svelte +80 -0
- package/components/flows/map/FlowModuleSchemaItem.svelte.d.ts +32 -0
- package/components/flows/map/FlowModuleSchemaMap.svelte +241 -0
- package/components/flows/map/FlowModuleSchemaMap.svelte.d.ts +20 -0
- package/components/flows/pickers/PickHubScript.svelte +5 -3
- package/components/flows/pickers/PickHubScript.svelte.d.ts +2 -1
- package/components/flows/pickers/PickScript.svelte +4 -12
- package/components/flows/pickers/PickScript.svelte.d.ts +1 -1
- package/components/flows/propPicker/PropPickerWrapper.svelte +44 -0
- package/components/flows/propPicker/PropPickerWrapper.svelte.d.ts +33 -0
- package/components/flows/scheduleUtils.d.ts +0 -1
- package/components/flows/scheduleUtils.js +0 -1
- package/components/flows/types.d.ts +8 -0
- package/components/flows/types.js +1 -0
- package/components/flows/utils.d.ts +3 -1
- package/components/flows/utils.js +26 -10
- package/components/icons/AirtableIcon.svelte +1 -1
- package/components/icons/DiscordIcon.svelte +1 -1
- package/components/icons/GCloudIcon.svelte +1 -1
- package/components/icons/GItlabIcon.svelte +1 -1
- package/components/icons/GSheetsIcon.svelte +1 -1
- package/components/icons/GcalIcon.svelte +1 -1
- package/components/icons/GdriveIcon.svelte +1 -1
- package/components/icons/GithubIcon.svelte +1 -1
- package/components/icons/GmailIcon.svelte +1 -1
- package/components/icons/HatIcon.svelte +19 -0
- package/components/icons/HatIcon.svelte.d.ts +16 -0
- package/components/icons/MastodonIcon.svelte +1 -1
- package/components/icons/MatrixIcon.svelte +1 -1
- package/components/icons/PostgresIcon.svelte +1 -1
- package/components/icons/S3Icon.svelte +1 -1
- package/components/icons/Slack.svelte +1 -1
- package/components/icons/TogglIcon.svelte +8 -46
- package/components/jobs/JobDetail.svelte +1 -1
- package/components/landing/FlowGettingStarted.svelte +22 -68
- package/components/landing/FlowLandingBox.svelte +1 -1
- package/components/landing/RessourceGettingStarted.svelte +7 -37
- package/components/landing/ScriptBox.svelte +33 -60
- package/components/landing/ScriptGettingStarted.svelte +23 -69
- package/components/propertyPicker/ObjectViewer.svelte +18 -12
- package/components/propertyPicker/ObjectViewer.svelte.d.ts +1 -0
- package/components/propertyPicker/PropPicker.svelte +108 -11
- package/components/propertyPicker/WarningMessage.svelte +2 -15
- package/components/script_editor/LogPanel.svelte +108 -119
- package/components/script_editor/LogPanel.svelte.d.ts +2 -0
- package/components/sidebar/SidebarContent.svelte +2 -2
- package/editorUtils.d.ts +3 -0
- package/editorUtils.js +1 -0
- package/gen/core/OpenAPI.js +1 -1
- package/gen/index.d.ts +1 -0
- package/gen/models/CompletedJob.d.ts +2 -1
- package/gen/models/CompletedJob.js +1 -0
- package/gen/models/FlowModule.d.ts +3 -0
- package/gen/models/FlowStatus.d.ts +3 -0
- package/gen/models/FlowStatusModule.d.ts +1 -1
- package/gen/models/Preview.d.ts +2 -1
- package/gen/models/Preview.js +1 -0
- package/gen/models/QueuedJob.d.ts +2 -1
- package/gen/models/QueuedJob.js +1 -0
- package/gen/models/RawScript.d.ts +2 -1
- package/gen/models/RawScript.js +1 -0
- package/gen/models/Retry.d.ts +11 -0
- package/gen/models/Retry.js +4 -0
- package/gen/models/Script.d.ts +9 -2
- package/gen/models/Script.js +8 -0
- package/gen/services/JobService.d.ts +40 -0
- package/gen/services/JobService.js +70 -0
- package/gen/services/ScriptService.d.ts +14 -3
- package/gen/services/ScriptService.js +13 -0
- package/infer.d.ts +1 -1
- package/infer.js +6 -1
- package/package.json +71 -38
- package/script_helpers.d.ts +8 -2
- package/script_helpers.js +88 -16
- package/stores.d.ts +1 -1
- package/utils.d.ts +8 -6
- package/utils.js +57 -21
- package/components/FlowEditor.svelte +0 -55
- package/components/FlowPreview.svelte +0 -107
- package/components/FlowPreview.svelte.d.ts +0 -23
- package/components/ModuleStep.svelte +0 -131
- package/components/ModuleStep.svelte.d.ts +0 -25
- package/components/flows/CopyFirstStepSchema.svelte +0 -13
- package/components/flows/FlowBox.svelte +0 -16
- package/components/flows/FlowBox.svelte.d.ts +0 -23
- package/components/flows/FlowBoxHeader.svelte +0 -16
- package/components/flows/FlowBoxHeader.svelte.d.ts +0 -21
- package/components/flows/FlowInput.svelte +0 -22
- package/components/flows/FlowInputs.svelte +0 -65
- package/components/flows/FlowModuleHeader.svelte +0 -109
- package/components/flows/FlowSettings.svelte +0 -165
- package/components/flows/FlowTimeline.svelte +0 -169
- package/components/flows/FlowTimeline.svelte.d.ts +0 -21
- package/components/flows/stepOpenedStore.d.ts +0 -1
- package/components/flows/stepOpenedStore.js +0 -6
- package/components/propertyPicker/OverlayPropertyPicker.svelte +0 -69
- package/components/propertyPicker/OverlayPropertyPicker.svelte.d.ts +0 -24
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
value: string;
|
|
5
|
+
position: 'left' | 'center' | 'right';
|
|
6
|
+
};
|
|
7
|
+
events: {
|
|
8
|
+
[evt: string]: CustomEvent<any>;
|
|
9
|
+
};
|
|
10
|
+
slots: {
|
|
11
|
+
default: {};
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
export declare type ToggleButtonProps = typeof __propDef.props;
|
|
15
|
+
export declare type ToggleButtonEvents = typeof __propDef.events;
|
|
16
|
+
export declare type ToggleButtonSlots = typeof __propDef.slots;
|
|
17
|
+
export default class ToggleButton extends SvelteComponentTyped<ToggleButtonProps, ToggleButtonEvents, ToggleButtonSlots> {
|
|
18
|
+
}
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
<script context="module">export {};
|
|
2
|
+
</script>
|
|
3
|
+
|
|
4
|
+
<script>import { setContext } from 'svelte';
|
|
5
|
+
import { writable } from 'svelte/store';
|
|
6
|
+
export let exclusive = true;
|
|
7
|
+
export let selected = [];
|
|
8
|
+
const selectedContent = writable(selected);
|
|
9
|
+
setContext('ToggleButtonGroup', {
|
|
10
|
+
selected: selectedContent,
|
|
11
|
+
select: (value) => {
|
|
12
|
+
if (exclusive) {
|
|
13
|
+
selectedContent.set([value]);
|
|
14
|
+
}
|
|
15
|
+
else {
|
|
16
|
+
selectedContent.update((selected) => {
|
|
17
|
+
const index = selected.findIndex((val) => val === value);
|
|
18
|
+
if (index !== -1) {
|
|
19
|
+
selected.splice(index, 1);
|
|
20
|
+
return selected;
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
return [value, ...selected];
|
|
24
|
+
}
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
</script>
|
|
30
|
+
|
|
31
|
+
<div class="inline-flex rounded-md shadow-sm" role="group">
|
|
32
|
+
<slot />
|
|
33
|
+
</div>
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
export declare type ToggleButtonContext = {
|
|
3
|
+
selected: Writable<string[]>;
|
|
4
|
+
select: (value: string) => void;
|
|
5
|
+
};
|
|
6
|
+
import { type Writable } from 'svelte/store';
|
|
7
|
+
declare const __propDef: {
|
|
8
|
+
props: {
|
|
9
|
+
exclusive?: boolean | undefined;
|
|
10
|
+
selected?: string[] | undefined;
|
|
11
|
+
};
|
|
12
|
+
events: {
|
|
13
|
+
[evt: string]: CustomEvent<any>;
|
|
14
|
+
};
|
|
15
|
+
slots: {
|
|
16
|
+
default: {};
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
export declare type ToggleButtonGroupProps = typeof __propDef.props;
|
|
20
|
+
export declare type ToggleButtonGroupEvents = typeof __propDef.events;
|
|
21
|
+
export declare type ToggleButtonGroupSlots = typeof __propDef.slots;
|
|
22
|
+
export default class ToggleButtonGroup extends SvelteComponentTyped<ToggleButtonGroupProps, ToggleButtonGroupEvents, ToggleButtonGroupSlots> {
|
|
23
|
+
}
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<!-- Flow Editor: Top level component -->
|
|
2
|
+
<script>import { HSplitPane } from 'svelte-split-pane';
|
|
3
|
+
import FlowEditorPanel from './content/FlowEditorPanel.svelte';
|
|
4
|
+
import FlowModuleSchemaMap from './map/FlowModuleSchemaMap.svelte';
|
|
5
|
+
import { flowStore } from './flowStore';
|
|
6
|
+
import { flowStateStore } from './flowState';
|
|
7
|
+
import FlowPreviewButtons from './header/FlowPreviewButtons.svelte';
|
|
8
|
+
export let initialPath;
|
|
9
|
+
</script>
|
|
10
|
+
|
|
11
|
+
<div class="h-full overflow-hidden border-t">
|
|
12
|
+
<HSplitPane leftPaneSize="25%" rightPaneSize="75%" minLeftPaneSize="20%" minRightPaneSize="40%">
|
|
13
|
+
<left slot="left" class="h-full flex flex-col ">
|
|
14
|
+
<FlowPreviewButtons />
|
|
15
|
+
<div class="grow overflow-auto p-4 bg-gray-50">
|
|
16
|
+
{#if $flowStore.value.modules && $flowStateStore.modules}
|
|
17
|
+
<FlowModuleSchemaMap
|
|
18
|
+
bind:modules={$flowStore.value.modules}
|
|
19
|
+
bind:moduleStates={$flowStateStore.modules}
|
|
20
|
+
/>
|
|
21
|
+
{/if}
|
|
22
|
+
</div>
|
|
23
|
+
</left>
|
|
24
|
+
<right slot="right" class="h-full">
|
|
25
|
+
<div class="h-full overflow-auto bg-white ">
|
|
26
|
+
<FlowEditorPanel {initialPath} />
|
|
27
|
+
</div>
|
|
28
|
+
</right>
|
|
29
|
+
</HSplitPane>
|
|
30
|
+
</div>
|
|
@@ -1,12 +1,7 @@
|
|
|
1
1
|
import { SvelteComponentTyped } from "svelte";
|
|
2
2
|
declare const __propDef: {
|
|
3
3
|
props: {
|
|
4
|
-
|
|
5
|
-
initialPath?: string | undefined;
|
|
6
|
-
scheduleArgs?: Record<string, any> | undefined;
|
|
7
|
-
scheduleEnabled?: boolean | undefined;
|
|
8
|
-
scheduleCron?: string | undefined;
|
|
9
|
-
previewArgs?: Record<string, any> | undefined;
|
|
4
|
+
initialPath: string;
|
|
10
5
|
};
|
|
11
6
|
events: {
|
|
12
7
|
[evt: string]: CustomEvent<any>;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
import type { FlowModule } from '../../../gen';
|
|
3
|
+
declare const __propDef: {
|
|
4
|
+
props: {
|
|
5
|
+
title?: string | undefined;
|
|
6
|
+
flowModule?: FlowModule | undefined;
|
|
7
|
+
};
|
|
8
|
+
events: {
|
|
9
|
+
[evt: string]: CustomEvent<any>;
|
|
10
|
+
};
|
|
11
|
+
slots: {
|
|
12
|
+
header: {};
|
|
13
|
+
default: {};
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
export declare type FlowCardProps = typeof __propDef.props;
|
|
17
|
+
export declare type FlowCardEvents = typeof __propDef.events;
|
|
18
|
+
export declare type FlowCardSlots = typeof __propDef.slots;
|
|
19
|
+
export default class FlowCard extends SvelteComponentTyped<FlowCardProps, FlowCardEvents, FlowCardSlots> {
|
|
20
|
+
}
|
|
21
|
+
export {};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
<script>import Badge from '../../common/badge/Badge.svelte';
|
|
2
|
+
import IconedPath from '../../IconedPath.svelte';
|
|
3
|
+
import { RawScript } from '../../../gen';
|
|
4
|
+
import { isEmptyFlowModule } from '../flowStateUtils';
|
|
5
|
+
export let flowModule = undefined;
|
|
6
|
+
export let title = undefined;
|
|
7
|
+
$: shouldPick = flowModule && isEmptyFlowModule(flowModule);
|
|
8
|
+
const languageColors = {
|
|
9
|
+
[RawScript.language.GO]: 'dark-indigo',
|
|
10
|
+
[RawScript.language.DENO]: 'dark-blue',
|
|
11
|
+
[RawScript.language.PYTHON3]: 'dark-green'
|
|
12
|
+
};
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<div
|
|
16
|
+
class="flex items-center justify-between py-2 px-4 border-b bg-gray-50 shadow-sm space-x-2 h-12 flex-nowrap"
|
|
17
|
+
>
|
|
18
|
+
{#if flowModule}
|
|
19
|
+
<span class="text-sm w-full">
|
|
20
|
+
<div class="flex items-center space-x-2">
|
|
21
|
+
{#if shouldPick}
|
|
22
|
+
<span class="font-bold text-xs">Select a script</span>
|
|
23
|
+
{:else if flowModule?.value.type === 'rawscript'}
|
|
24
|
+
<Badge color={languageColors[flowModule?.value.language] ?? 'gray'} capitalize>
|
|
25
|
+
{flowModule?.value.language}
|
|
26
|
+
</Badge>
|
|
27
|
+
<input bind:value={flowModule.summary} placeholder={'Summary'} />
|
|
28
|
+
{:else if flowModule?.value.type === 'script' && 'path' in flowModule.value && flowModule.value.path}
|
|
29
|
+
<IconedPath path={flowModule.value.path} />
|
|
30
|
+
<input bind:value={flowModule.summary} placeholder="Summary" class="ml-2" />
|
|
31
|
+
{/if}
|
|
32
|
+
</div>
|
|
33
|
+
</span>
|
|
34
|
+
{/if}
|
|
35
|
+
{#if title}
|
|
36
|
+
<div class="text-sm font-bold text-gray-900">{title}</div>
|
|
37
|
+
{/if}
|
|
38
|
+
<slot />
|
|
39
|
+
</div>
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
import { type FlowModule } from '../../../gen';
|
|
3
|
+
declare const __propDef: {
|
|
4
|
+
props: {
|
|
5
|
+
flowModule?: FlowModule | undefined;
|
|
6
|
+
title?: string | undefined;
|
|
7
|
+
};
|
|
8
|
+
events: {
|
|
9
|
+
[evt: string]: CustomEvent<any>;
|
|
10
|
+
};
|
|
11
|
+
slots: {
|
|
12
|
+
default: {};
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export declare type FlowCardHeaderProps = typeof __propDef.props;
|
|
16
|
+
export declare type FlowCardHeaderEvents = typeof __propDef.events;
|
|
17
|
+
export declare type FlowCardHeaderSlots = typeof __propDef.slots;
|
|
18
|
+
export default class FlowCardHeader extends SvelteComponentTyped<FlowCardHeaderProps, FlowCardHeaderEvents, FlowCardHeaderSlots> {
|
|
19
|
+
}
|
|
20
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<script>import { Button } from 'flowbite-svelte';
|
|
2
|
+
import { isEmptyFlowModule } from '../flowStateUtils';
|
|
3
|
+
import { copyFirstStepSchema, flowStore } from '../flowStore';
|
|
4
|
+
</script>
|
|
5
|
+
|
|
6
|
+
<Button
|
|
7
|
+
color="light"
|
|
8
|
+
size="xs"
|
|
9
|
+
disabled={$flowStore.value.modules.length === 0 || isEmptyFlowModule($flowStore.value.modules[0])}
|
|
10
|
+
on:click={copyFirstStepSchema}
|
|
11
|
+
>
|
|
12
|
+
Copy from first step schema
|
|
13
|
+
</Button>
|
package/components/flows/{CopyFirstStepSchema.svelte.d.ts → content/CopyFirstStepSchema.svelte.d.ts}
RENAMED
|
File without changes
|
|
File without changes
|
package/components/flows/{DynamicInputHelpBox.svelte.d.ts → content/DynamicInputHelpBox.svelte.d.ts}
RENAMED
|
File without changes
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<script>import { getContext } from 'svelte';
|
|
2
|
+
import FlowModuleWrapper from './FlowModuleWrapper.svelte';
|
|
3
|
+
import FlowSettings from './FlowSettings.svelte';
|
|
4
|
+
import FlowInput from './FlowInput.svelte';
|
|
5
|
+
import FlowFailureModule from './FlowFailureModule.svelte';
|
|
6
|
+
import FlowLoopWrapper from './FlowLoopWrapper.svelte';
|
|
7
|
+
export let initialPath;
|
|
8
|
+
const { selectedId } = getContext('FlowEditorContext');
|
|
9
|
+
</script>
|
|
10
|
+
|
|
11
|
+
{#key $selectedId}
|
|
12
|
+
{#if $selectedId === 'settings'}
|
|
13
|
+
<FlowSettings {initialPath} />
|
|
14
|
+
{:else if $selectedId === 'settings-schedule'}
|
|
15
|
+
<FlowSettings {initialPath} defaultTab="schedule" />
|
|
16
|
+
{:else if $selectedId.includes('loop')}
|
|
17
|
+
<FlowLoopWrapper />
|
|
18
|
+
{:else if $selectedId === 'inputs'}
|
|
19
|
+
<FlowInput />
|
|
20
|
+
{:else if $selectedId === 'failure'}
|
|
21
|
+
<FlowFailureModule />
|
|
22
|
+
{:else}
|
|
23
|
+
<FlowModuleWrapper />
|
|
24
|
+
{/if}
|
|
25
|
+
{/key}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
initialPath: string;
|
|
5
|
+
};
|
|
6
|
+
events: {
|
|
7
|
+
[evt: string]: CustomEvent<any>;
|
|
8
|
+
};
|
|
9
|
+
slots: {};
|
|
10
|
+
};
|
|
11
|
+
export declare type FlowEditorPanelProps = typeof __propDef.props;
|
|
12
|
+
export declare type FlowEditorPanelEvents = typeof __propDef.events;
|
|
13
|
+
export declare type FlowEditorPanelSlots = typeof __propDef.slots;
|
|
14
|
+
export default class FlowEditorPanel extends SvelteComponentTyped<FlowEditorPanelProps, FlowEditorPanelEvents, FlowEditorPanelSlots> {
|
|
15
|
+
}
|
|
16
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<script>import { flowStateStore } from '../flowState';
|
|
2
|
+
import { flowStore } from '../flowStore';
|
|
3
|
+
import FlowModule from './FlowModule.svelte';
|
|
4
|
+
</script>
|
|
5
|
+
|
|
6
|
+
{#if $flowStore.value.failure_module}
|
|
7
|
+
<FlowModule
|
|
8
|
+
bind:flowModule={$flowStore.value.failure_module}
|
|
9
|
+
bind:flowModuleState={$flowStateStore.failureModule}
|
|
10
|
+
on:delete={() => {
|
|
11
|
+
$flowStore.value.failure_module = undefined
|
|
12
|
+
}}
|
|
13
|
+
failureModule={true}
|
|
14
|
+
/>
|
|
15
|
+
{/if}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {};
|
|
4
|
+
events: {
|
|
5
|
+
[evt: string]: CustomEvent<any>;
|
|
6
|
+
};
|
|
7
|
+
slots: {};
|
|
8
|
+
};
|
|
9
|
+
export declare type FlowFailureModuleProps = typeof __propDef.props;
|
|
10
|
+
export declare type FlowFailureModuleEvents = typeof __propDef.events;
|
|
11
|
+
export declare type FlowFailureModuleSlots = typeof __propDef.slots;
|
|
12
|
+
export default class FlowFailureModule extends SvelteComponentTyped<FlowFailureModuleProps, FlowFailureModuleEvents, FlowFailureModuleSlots> {
|
|
13
|
+
}
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<script>import { flowStore } from '../flowStore';
|
|
2
|
+
import SchemaEditor from '../../SchemaEditor.svelte';
|
|
3
|
+
import SchemaForm from '../../SchemaForm.svelte';
|
|
4
|
+
import { emptySchema } from '../../../utils';
|
|
5
|
+
import FlowCard from '../common/FlowCard.svelte';
|
|
6
|
+
import CopyFirstStepSchema from './CopyFirstStepSchema.svelte';
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<FlowCard title="Flow Inputs">
|
|
10
|
+
<div slot="header">
|
|
11
|
+
<CopyFirstStepSchema />
|
|
12
|
+
</div>
|
|
13
|
+
<div>
|
|
14
|
+
<div class="p-6">
|
|
15
|
+
<SchemaEditor
|
|
16
|
+
on:change={() => {
|
|
17
|
+
$flowStore = $flowStore
|
|
18
|
+
}}
|
|
19
|
+
bind:schema={$flowStore.schema}
|
|
20
|
+
/>
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
<div class="p-6">
|
|
24
|
+
<SchemaForm bind:schema={$flowStore.schema} editableSchema={true} />
|
|
25
|
+
</div>
|
|
26
|
+
</FlowCard>
|
|
File without changes
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
<script>import { RawScript, Script } from '../../../gen';
|
|
2
|
+
import { faCode, faRepeat } from '@fortawesome/free-solid-svg-icons';
|
|
3
|
+
import { createEventDispatcher } from 'svelte';
|
|
4
|
+
import FlowScriptPicker from '../pickers/FlowScriptPicker.svelte';
|
|
5
|
+
import PickHubScript from '../pickers/PickHubScript.svelte';
|
|
6
|
+
import PickScript from '../pickers/PickScript.svelte';
|
|
7
|
+
export let shouldDisableLoopCreation = false;
|
|
8
|
+
export let shouldDisableTriggerScripts = false;
|
|
9
|
+
export let failureModule;
|
|
10
|
+
const dispatch = createEventDispatcher();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<div class="space-y-4 p-4">
|
|
14
|
+
{#if !shouldDisableTriggerScripts}
|
|
15
|
+
<div class="text-sm font-bold">Scripts</div>
|
|
16
|
+
{/if}
|
|
17
|
+
|
|
18
|
+
<div class="grid sm:grid-col-2 lg:grid-cols-3 gap-4">
|
|
19
|
+
<PickScript kind={failureModule ? Script.kind.FAILURE : Script.kind.SCRIPT} on:pick />
|
|
20
|
+
<PickHubScript kind={failureModule ? Script.kind.FAILURE : Script.kind.SCRIPT} on:pick />
|
|
21
|
+
|
|
22
|
+
<FlowScriptPicker
|
|
23
|
+
label={`Create a for-loop here`}
|
|
24
|
+
disabled={shouldDisableLoopCreation}
|
|
25
|
+
icon={faRepeat}
|
|
26
|
+
iconColor="text-blue-500"
|
|
27
|
+
on:click={() => dispatch('loop')}
|
|
28
|
+
/>
|
|
29
|
+
|
|
30
|
+
{#if !failureModule}
|
|
31
|
+
<FlowScriptPicker
|
|
32
|
+
label={`New PostgreSQL query`}
|
|
33
|
+
icon={faCode}
|
|
34
|
+
iconColor="text-blue-800"
|
|
35
|
+
on:click={() =>
|
|
36
|
+
dispatch('new', { language: RawScript.language.DENO, kind: 'script', subkind: 'pgsql' })}
|
|
37
|
+
/>
|
|
38
|
+
{/if}
|
|
39
|
+
|
|
40
|
+
<FlowScriptPicker
|
|
41
|
+
label="New Python script (3.10)"
|
|
42
|
+
icon={faCode}
|
|
43
|
+
iconColor="text-green-500"
|
|
44
|
+
on:click={() =>
|
|
45
|
+
dispatch('new', {
|
|
46
|
+
language: RawScript.language.PYTHON3,
|
|
47
|
+
kind: 'script',
|
|
48
|
+
subkind: failureModule ? 'failure' : 'flow'
|
|
49
|
+
})}
|
|
50
|
+
/>
|
|
51
|
+
|
|
52
|
+
<FlowScriptPicker
|
|
53
|
+
label="New Typescript script (Deno)"
|
|
54
|
+
icon={faCode}
|
|
55
|
+
iconColor="text-blue-800"
|
|
56
|
+
on:click={() =>
|
|
57
|
+
dispatch('new', {
|
|
58
|
+
language: RawScript.language.DENO,
|
|
59
|
+
kind: 'script',
|
|
60
|
+
subkind: failureModule ? 'failure' : 'flow'
|
|
61
|
+
})}
|
|
62
|
+
/>
|
|
63
|
+
|
|
64
|
+
<FlowScriptPicker
|
|
65
|
+
label="New Go script"
|
|
66
|
+
icon={faCode}
|
|
67
|
+
iconColor="text-blue-700"
|
|
68
|
+
on:click={() =>
|
|
69
|
+
dispatch('new', {
|
|
70
|
+
language: RawScript.language.GO,
|
|
71
|
+
kind: 'script',
|
|
72
|
+
subkind: failureModule ? 'failure' : 'flow'
|
|
73
|
+
})}
|
|
74
|
+
/>
|
|
75
|
+
</div>
|
|
76
|
+
|
|
77
|
+
{#if !shouldDisableTriggerScripts}
|
|
78
|
+
<div class="text-sm font-bold">Trigger scripts</div>
|
|
79
|
+
|
|
80
|
+
<div class="grid sm:grid-col-1 md:grid-col-2 lg:grid-cols-3 gap-4">
|
|
81
|
+
<PickScript kind={Script.kind.TRIGGER} on:pick />
|
|
82
|
+
<PickHubScript kind={Script.kind.TRIGGER} on:pick />
|
|
83
|
+
<FlowScriptPicker
|
|
84
|
+
label="New Typescript script (Deno)"
|
|
85
|
+
icon={faCode}
|
|
86
|
+
iconColor="text-blue-800"
|
|
87
|
+
on:click={() => dispatch('new', { language: RawScript.language.DENO, kind: 'trigger' })}
|
|
88
|
+
/>
|
|
89
|
+
</div>
|
|
90
|
+
{/if}
|
|
91
|
+
</div>
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
<script>import { getContext } from 'svelte';
|
|
2
|
+
import FlowCard from '../common/FlowCard.svelte';
|
|
3
|
+
import Toggle from '../../Toggle.svelte';
|
|
4
|
+
import SimpleEditor from '../../SimpleEditor.svelte';
|
|
5
|
+
import Tooltip from '../../Tooltip.svelte';
|
|
6
|
+
import { flowStore } from '../flowStore';
|
|
7
|
+
import { getStepPropPicker } from '../flowStateUtils';
|
|
8
|
+
import { flowStateStore } from '../flowState';
|
|
9
|
+
import PropPickerWrapper from '../propPicker/PropPickerWrapper.svelte';
|
|
10
|
+
import { VSplitPane } from 'svelte-split-pane';
|
|
11
|
+
import FlowModuleEarlyStop from './FlowModuleEarlyStop.svelte';
|
|
12
|
+
import FlowModuleSuspend from './FlowModuleSuspend.svelte';
|
|
13
|
+
import FlowRetries from './FlowRetries.svelte';
|
|
14
|
+
import { Button, Tab, TabContent, Tabs } from '../../common';
|
|
15
|
+
const { previewArgs } = getContext('FlowEditorContext');
|
|
16
|
+
export let mod;
|
|
17
|
+
export let index;
|
|
18
|
+
let editor = undefined;
|
|
19
|
+
let monacos = {};
|
|
20
|
+
let selected = 'retries';
|
|
21
|
+
let inputTransformName = '';
|
|
22
|
+
$: mod = $flowStore.value.modules[index];
|
|
23
|
+
$: pickableProperties = getStepPropPicker([Number(index)], $flowStore.schema, $flowStateStore, $previewArgs).pickableProperties;
|
|
24
|
+
</script>
|
|
25
|
+
|
|
26
|
+
<FlowCard title="For loop">
|
|
27
|
+
<div slot="header" class="grow">
|
|
28
|
+
<input bind:value={mod.summary} placeholder={'Summary'} />
|
|
29
|
+
</div>
|
|
30
|
+
<div>
|
|
31
|
+
<div class="overflow-hidden flex-grow">
|
|
32
|
+
<VSplitPane topPanelSize="50%" downPanelSize="40%" minTopPaneSize="20%" minDownPaneSize="20%">
|
|
33
|
+
<top slot="top">
|
|
34
|
+
<div class="p-6 flex flex-col">
|
|
35
|
+
{#if mod.value.type === 'forloopflow'}
|
|
36
|
+
<span class="mb-2 text-sm font-bold"
|
|
37
|
+
>Iterator expression
|
|
38
|
+
<Tooltip>
|
|
39
|
+
List to iterate over. For more information see the
|
|
40
|
+
<a href="https://docs.windmill.dev/docs/getting_started/flows#for-loops">docs.</a>
|
|
41
|
+
</Tooltip>
|
|
42
|
+
</span>
|
|
43
|
+
|
|
44
|
+
{#if mod.value.iterator.type == 'javascript'}
|
|
45
|
+
<div class="border w-full">
|
|
46
|
+
<PropPickerWrapper
|
|
47
|
+
{pickableProperties}
|
|
48
|
+
on:select={({ detail }) => {
|
|
49
|
+
editor?.insertAtCursor(detail)
|
|
50
|
+
}}
|
|
51
|
+
>
|
|
52
|
+
<SimpleEditor
|
|
53
|
+
bind:this={editor}
|
|
54
|
+
lang="javascript"
|
|
55
|
+
bind:code={mod.value.iterator.expr}
|
|
56
|
+
class="small-editor"
|
|
57
|
+
shouldBindKey={false}
|
|
58
|
+
/>
|
|
59
|
+
</PropPickerWrapper>
|
|
60
|
+
</div>
|
|
61
|
+
{:else}
|
|
62
|
+
<Button
|
|
63
|
+
on:click={() => {
|
|
64
|
+
if (mod.value.type === 'forloopflow') mod.value.iterator.type = 'javascript'
|
|
65
|
+
}}
|
|
66
|
+
/>
|
|
67
|
+
{/if}
|
|
68
|
+
|
|
69
|
+
<span class="my-2 text-sm font-bold">Skip failures</span>
|
|
70
|
+
|
|
71
|
+
<Toggle
|
|
72
|
+
bind:checked={mod.value.skip_failures}
|
|
73
|
+
options={{
|
|
74
|
+
right: 'Skip failures'
|
|
75
|
+
}}
|
|
76
|
+
/>
|
|
77
|
+
<span class="my-2 text-sm font-bold"
|
|
78
|
+
>Pass specific flow context as loop flow input</span
|
|
79
|
+
>
|
|
80
|
+
<div class="flex flex-row mt-4 w-80 max-w-full"
|
|
81
|
+
><input
|
|
82
|
+
bind:value={inputTransformName}
|
|
83
|
+
placeholder="Argument name"
|
|
84
|
+
type="text"
|
|
85
|
+
class="w-20"
|
|
86
|
+
/><Button
|
|
87
|
+
disabled={inputTransformName == ''}
|
|
88
|
+
btnClasses="ml-2"
|
|
89
|
+
on:click={() =>
|
|
90
|
+
(mod.input_transforms[inputTransformName] = { type: 'javascript', expr: '' })}
|
|
91
|
+
>+</Button
|
|
92
|
+
></div
|
|
93
|
+
>
|
|
94
|
+
|
|
95
|
+
{#each Object.keys(mod.input_transforms) as key}
|
|
96
|
+
<div class="flex flex-row my-2">
|
|
97
|
+
<span class="my-2 text-sm font-bold">{key}</span>
|
|
98
|
+
|
|
99
|
+
<Button
|
|
100
|
+
btnClasses="ml-4"
|
|
101
|
+
on:click={() => {
|
|
102
|
+
delete mod.input_transforms[key]
|
|
103
|
+
mod.input_transforms = mod.input_transforms
|
|
104
|
+
}}>-</Button
|
|
105
|
+
>
|
|
106
|
+
</div>
|
|
107
|
+
<div class="border w-full">
|
|
108
|
+
{#if mod.input_transforms[key].type == 'javascript'}
|
|
109
|
+
<PropPickerWrapper
|
|
110
|
+
{pickableProperties}
|
|
111
|
+
on:select={({ detail }) => {
|
|
112
|
+
monacos[key]?.insertAtCursor(detail)
|
|
113
|
+
}}
|
|
114
|
+
>
|
|
115
|
+
<SimpleEditor
|
|
116
|
+
bind:this={monacos[key]}
|
|
117
|
+
lang="javascript"
|
|
118
|
+
bind:code={mod.input_transforms[key]['expr']}
|
|
119
|
+
class="small-editor"
|
|
120
|
+
shouldBindKey={false}
|
|
121
|
+
/>
|
|
122
|
+
</PropPickerWrapper>
|
|
123
|
+
{:else}
|
|
124
|
+
<Button
|
|
125
|
+
on:click={() => {
|
|
126
|
+
mod.input_transforms[key].type = 'javascript'
|
|
127
|
+
mod.input_transforms[key]['expr'] = ''
|
|
128
|
+
}}
|
|
129
|
+
/>
|
|
130
|
+
{/if}
|
|
131
|
+
</div>
|
|
132
|
+
{/each}
|
|
133
|
+
{/if}
|
|
134
|
+
</div></top
|
|
135
|
+
>
|
|
136
|
+
<down slot="down" class="flex flex-col flex-1 h-full">
|
|
137
|
+
<Tabs bind:selected>
|
|
138
|
+
<Tab value="retries">Retries</Tab>
|
|
139
|
+
<Tab value="early-stop">Early Stop</Tab>
|
|
140
|
+
<Tab value="suspend">Suspend</Tab>
|
|
141
|
+
|
|
142
|
+
<svelte:fragment slot="content">
|
|
143
|
+
<div class="overflow-hidden bg-white" style="height:calc(100% - 32px);">
|
|
144
|
+
<TabContent value="retries" class="flex flex-col flex-1 h-full">
|
|
145
|
+
<div class="p-4 overflow-y-auto">
|
|
146
|
+
<FlowRetries bind:flowModule={mod} />
|
|
147
|
+
</div>
|
|
148
|
+
</TabContent>
|
|
149
|
+
|
|
150
|
+
<TabContent value="early-stop" class="flex flex-col flex-1 h-full">
|
|
151
|
+
<div class="p-4 overflow-y-auto">
|
|
152
|
+
<FlowModuleEarlyStop bind:flowModule={mod} />
|
|
153
|
+
</div>
|
|
154
|
+
</TabContent>
|
|
155
|
+
|
|
156
|
+
<TabContent value="suspend" class="flex flex-col flex-1 h-full">
|
|
157
|
+
<div class="p-4 overflow-y-auto">
|
|
158
|
+
<FlowModuleSuspend bind:flowModule={mod} />
|
|
159
|
+
</div>
|
|
160
|
+
</TabContent>
|
|
161
|
+
</div>
|
|
162
|
+
</svelte:fragment>
|
|
163
|
+
</Tabs>
|
|
164
|
+
</down>
|
|
165
|
+
</VSplitPane>
|
|
166
|
+
</div>
|
|
167
|
+
</div>
|
|
168
|
+
</FlowCard>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
import type { FlowModule } from '../../../gen/models/FlowModule';
|
|
3
|
+
declare const __propDef: {
|
|
4
|
+
props: {
|
|
5
|
+
mod: FlowModule;
|
|
6
|
+
index: number;
|
|
7
|
+
};
|
|
8
|
+
events: {
|
|
9
|
+
[evt: string]: CustomEvent<any>;
|
|
10
|
+
};
|
|
11
|
+
slots: {};
|
|
12
|
+
};
|
|
13
|
+
export declare type FlowLoopProps = typeof __propDef.props;
|
|
14
|
+
export declare type FlowLoopEvents = typeof __propDef.events;
|
|
15
|
+
export declare type FlowLoopSlots = typeof __propDef.slots;
|
|
16
|
+
export default class FlowLoop extends SvelteComponentTyped<FlowLoopProps, FlowLoopEvents, FlowLoopSlots> {
|
|
17
|
+
}
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<script>import { getContext } from 'svelte';
|
|
2
|
+
import { flowStore } from '../flowStore';
|
|
3
|
+
import { selectedIdToIndexes } from '../utils';
|
|
4
|
+
import FlowLoop from './FlowLoop.svelte';
|
|
5
|
+
const { selectedId } = getContext('FlowEditorContext');
|
|
6
|
+
$: index = selectedIdToIndexes($selectedId)[0];
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<FlowLoop bind:mod={$flowStore.value.modules[index]} {index} />
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {};
|
|
4
|
+
events: {
|
|
5
|
+
[evt: string]: CustomEvent<any>;
|
|
6
|
+
};
|
|
7
|
+
slots: {};
|
|
8
|
+
};
|
|
9
|
+
export declare type FlowLoopWrapperProps = typeof __propDef.props;
|
|
10
|
+
export declare type FlowLoopWrapperEvents = typeof __propDef.events;
|
|
11
|
+
export declare type FlowLoopWrapperSlots = typeof __propDef.slots;
|
|
12
|
+
export default class FlowLoopWrapper extends SvelteComponentTyped<FlowLoopWrapperProps, FlowLoopWrapperEvents, FlowLoopWrapperSlots> {
|
|
13
|
+
}
|
|
14
|
+
export {};
|