windmill-components 1.35.1 → 1.35.43
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/ArgInput.svelte +21 -21
- package/components/ArgInput.svelte.d.ts +3 -3
- package/components/DisplayResult.svelte +73 -67
- package/components/Editor.svelte +184 -246
- package/components/Editor.svelte.d.ts +4 -4
- package/components/EditorBar.svelte +58 -45
- package/components/EditorBar.svelte.d.ts +2 -1
- package/components/FlowBuilder.svelte +113 -121
- package/components/FlowJobResult.svelte +4 -5
- package/components/FlowModulesViewer.svelte +89 -7
- package/components/FlowModulesViewer.svelte.d.ts +1 -0
- package/components/FlowPreviewContent.svelte +56 -15
- package/components/FlowPreviewContent.svelte.d.ts +1 -1
- package/components/FlowStatusViewer.svelte +42 -24
- package/components/FlowStatusViewer.svelte.d.ts +0 -1
- package/components/FlowViewer.svelte +7 -3
- package/components/HighlightCode.svelte +21 -0
- package/components/HighlightCode.svelte.d.ts +17 -0
- package/components/IconedPath.svelte +9 -7
- package/components/IconedResourceType.svelte +1 -1
- package/components/InputTransformForm.svelte +88 -107
- package/components/InputTransformForm.svelte.d.ts +0 -1
- package/components/ItemPicker.svelte +2 -2
- package/components/LogViewer.svelte +23 -0
- package/components/LogViewer.svelte.d.ts +19 -0
- package/components/ModulePreview.svelte +108 -0
- package/components/ModulePreview.svelte.d.ts +24 -0
- package/components/RunForm.svelte +29 -18
- package/components/RunForm.svelte.d.ts +6 -2
- package/components/SchemaEditor.svelte +5 -3
- package/components/SchemaForm.svelte +0 -2
- package/components/SchemaForm.svelte.d.ts +0 -1
- package/components/ScriptBuilder.svelte +77 -66
- package/components/ScriptBuilder.svelte.d.ts +2 -4
- package/components/ScriptEditor.svelte +69 -142
- package/components/ScriptEditor.svelte.d.ts +0 -5
- package/components/ScriptPicker.svelte +3 -3
- package/components/ScriptPicker.svelte.d.ts +2 -1
- package/components/SharedBadge.svelte +5 -13
- package/components/SimpleEditor.svelte +147 -0
- package/components/SimpleEditor.svelte.d.ts +35 -0
- package/components/TestJobLoader.svelte +98 -0
- package/components/TestJobLoader.svelte.d.ts +26 -0
- package/components/Tooltip.svelte +2 -1
- package/components/common/actionRow/ActionRow.svelte +26 -0
- package/components/common/actionRow/ActionRow.svelte.d.ts +21 -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 +82 -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 +107 -0
- package/components/common/button/Button.svelte.d.ts +37 -0
- package/components/common/button/model.d.ts +6 -0
- package/components/common/button/model.js +1 -0
- package/components/common/confirmationModal/ConfirmationModal.svelte +55 -0
- package/components/common/confirmationModal/ConfirmationModal.svelte.d.ts +23 -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 -8
- 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 +26 -0
- package/components/flows/content/FlowEditorPanel.svelte.d.ts +14 -0
- package/components/flows/content/FlowFailureModule.svelte +17 -0
- package/components/flows/content/FlowFailureModule.svelte.d.ts +14 -0
- package/components/flows/content/FlowInput.svelte +22 -0
- package/components/flows/{FlowInput.svelte.d.ts → content/FlowInput.svelte.d.ts} +0 -0
- package/components/flows/{FlowInputs.svelte → content/FlowInputs.svelte} +24 -13
- package/components/flows/{FlowInputs.svelte.d.ts → content/FlowInputs.svelte.d.ts} +0 -0
- package/components/flows/content/FlowLoop.svelte +38 -0
- package/components/flows/content/FlowLoop.svelte.d.ts +14 -0
- package/components/flows/content/FlowModule.svelte +190 -0
- package/components/flows/content/FlowModule.svelte.d.ts +29 -0
- package/components/flows/content/FlowModuleAdvancedSettings.svelte +64 -0
- package/components/flows/content/FlowModuleAdvancedSettings.svelte.d.ts +17 -0
- package/components/flows/content/FlowModuleHeader.svelte +68 -0
- package/components/flows/{FlowModuleHeader.svelte.d.ts → content/FlowModuleHeader.svelte.d.ts} +2 -3
- package/components/flows/content/FlowModuleScript.svelte +21 -0
- package/components/flows/content/FlowModuleScript.svelte.d.ts +17 -0
- package/components/flows/content/FlowModuleWrapper.svelte +47 -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 +14 -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 +51 -0
- package/components/flows/{FlowSettings.svelte.d.ts → content/FlowSettings.svelte.d.ts} +1 -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 +15 -13
- package/components/flows/flowStateUtils.js +80 -72
- package/components/flows/flowStore.js +7 -4
- package/components/flows/header/FlowEditorHeader.svelte +23 -0
- package/components/flows/header/FlowEditorHeader.svelte.d.ts +14 -0
- package/components/flows/header/FlowImportExportMenu.svelte +56 -0
- package/components/flows/header/FlowImportExportMenu.svelte.d.ts +14 -0
- package/components/flows/header/FlowPreviewButtons.svelte +49 -0
- package/components/flows/header/FlowPreviewButtons.svelte.d.ts +14 -0
- package/components/flows/header/FlowStatus.svelte +36 -0
- package/components/flows/header/FlowStatus.svelte.d.ts +14 -0
- package/components/flows/map/FlowErrorHandlerItem.svelte +54 -0
- package/components/flows/map/FlowErrorHandlerItem.svelte.d.ts +14 -0
- package/components/flows/map/FlowModuleSchemaItem.svelte +58 -0
- package/components/flows/map/FlowModuleSchemaItem.svelte.d.ts +27 -0
- package/components/flows/map/FlowModuleSchemaMap.svelte +161 -0
- package/components/flows/map/FlowModuleSchemaMap.svelte.d.ts +20 -0
- package/components/flows/pickers/PickHubScript.svelte +4 -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 +42 -0
- package/components/flows/propPicker/PropPickerWrapper.svelte.d.ts +31 -0
- package/components/flows/scheduleUtils.d.ts +0 -1
- package/components/flows/scheduleUtils.js +0 -1
- package/components/flows/types.d.ts +9 -0
- package/components/flows/types.js +1 -0
- package/components/flows/utils.d.ts +1 -1
- package/components/flows/utils.js +8 -11
- package/components/icons/HatIcon.svelte +19 -0
- package/components/icons/HatIcon.svelte.d.ts +16 -0
- 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 +16 -7
- package/components/propertyPicker/PropPicker.svelte +38 -12
- 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 +25 -0
- package/editorUtils.js +43 -0
- package/gen/models/CompletedJob.d.ts +2 -1
- package/gen/models/CompletedJob.js +1 -0
- package/gen/models/FlowModule.d.ts +1 -0
- package/gen/models/FlowStatus.d.ts +3 -0
- package/gen/models/FlowStatusModule.d.ts +1 -1
- package/gen/models/FlowValue.d.ts +11 -0
- 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/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 +67 -35
- package/script_helpers.d.ts +5 -2
- package/script_helpers.js +41 -13
- package/stores.d.ts +1 -1
- package/utils.d.ts +6 -4
- package/utils.js +27 -4
- 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/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
|
@@ -1,25 +1,14 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { goto } from '$app/navigation'
|
|
3
|
+
import { faExternalLink, faFile, faPlus } from '@fortawesome/free-solid-svg-icons'
|
|
4
|
+
import Button from '../common/button/Button.svelte'
|
|
5
|
+
import HatIcon from '../icons/HatIcon.svelte'
|
|
3
6
|
</script>
|
|
4
7
|
|
|
5
8
|
<div class="p-4 border border-gray-300 rounded-md bg-gray-50 ">
|
|
6
9
|
<div class="flex items-center">
|
|
7
10
|
<h3 class="inline-flex items-center text-lg font-medium text-gray-700 ">
|
|
8
|
-
<
|
|
9
|
-
class="w-6 h-6 mr-2"
|
|
10
|
-
fill="none"
|
|
11
|
-
stroke="currentColor"
|
|
12
|
-
viewBox="0 0 24 24"
|
|
13
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
14
|
-
><path d="M12 14l9-5-9-5-9 5 9 5z" /><path
|
|
15
|
-
d="M12 14l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14z"
|
|
16
|
-
/><path
|
|
17
|
-
stroke-linecap="round"
|
|
18
|
-
stroke-linejoin="round"
|
|
19
|
-
stroke-width="2"
|
|
20
|
-
d="M12 14l9-5-9-5-9 5 9 5zm0 0l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14zm-4 6v-7.5l4-2.222"
|
|
21
|
-
/>
|
|
22
|
-
</svg>
|
|
11
|
+
<HatIcon class="w-6 h-6 mr-2" />
|
|
23
12
|
Getting started
|
|
24
13
|
</h3>
|
|
25
14
|
</div>
|
|
@@ -29,67 +18,32 @@
|
|
|
29
18
|
the Hub!
|
|
30
19
|
</div>
|
|
31
20
|
<div class="inline-flex flex-wrap gap-y-2">
|
|
32
|
-
<
|
|
33
|
-
type="button"
|
|
21
|
+
<Button
|
|
34
22
|
on:click={() => goto('flows/add')}
|
|
35
|
-
|
|
23
|
+
color="dark"
|
|
24
|
+
size="xs"
|
|
25
|
+
btnClasses="mr-2"
|
|
26
|
+
startIcon={{ icon: faPlus }}
|
|
36
27
|
>
|
|
37
|
-
<svg
|
|
38
|
-
class="w-4 h-4 mr-2"
|
|
39
|
-
fill="none"
|
|
40
|
-
stroke="currentColor"
|
|
41
|
-
viewBox="0 0 24 24"
|
|
42
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
43
|
-
><path
|
|
44
|
-
stroke-linecap="round"
|
|
45
|
-
stroke-linejoin="round"
|
|
46
|
-
stroke-width="2"
|
|
47
|
-
d="M12 6v6m0 0v6m0-6h6m-6 0H6"
|
|
48
|
-
/></svg
|
|
49
|
-
>
|
|
50
28
|
Create flow
|
|
51
|
-
</
|
|
52
|
-
<
|
|
29
|
+
</Button>
|
|
30
|
+
<Button
|
|
53
31
|
on:click={() => goto('https://docs.windmill.dev/docs/getting_started/flows')}
|
|
54
|
-
|
|
55
|
-
|
|
32
|
+
color="blue"
|
|
33
|
+
size="xs"
|
|
34
|
+
btnClasses="mr-2"
|
|
35
|
+
startIcon={{ icon: faFile }}
|
|
56
36
|
>
|
|
57
|
-
<svg
|
|
58
|
-
class="w-4 h-4 mr-2"
|
|
59
|
-
fill="none"
|
|
60
|
-
stroke="currentColor"
|
|
61
|
-
viewBox="0 0 24 24"
|
|
62
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
63
|
-
><path
|
|
64
|
-
stroke-linecap="round"
|
|
65
|
-
stroke-linejoin="round"
|
|
66
|
-
stroke-width="2"
|
|
67
|
-
d="M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"
|
|
68
|
-
/>
|
|
69
|
-
</svg>
|
|
70
37
|
Flow documentation
|
|
71
|
-
</
|
|
72
|
-
<
|
|
73
|
-
type="button"
|
|
74
|
-
class="inline-flex items-center text-gray-700 bg-transparent border border-gray-700 hover:bg-gray-800 hover:text-white focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded-lg text-xs px-3 py-1.5 text-center "
|
|
75
|
-
data-dismiss-target="#alert-additional-content-5"
|
|
76
|
-
aria-label="Close"
|
|
38
|
+
</Button>
|
|
39
|
+
<Button
|
|
77
40
|
on:click={() => goto('https://hub.windmill.dev/')}
|
|
41
|
+
color="light"
|
|
42
|
+
variant="border"
|
|
43
|
+
size="xs"
|
|
44
|
+
startIcon={{ icon: faExternalLink }}
|
|
78
45
|
>
|
|
79
|
-
<svg
|
|
80
|
-
class="w-4 h-4 mr-2"
|
|
81
|
-
fill="none"
|
|
82
|
-
stroke="currentColor"
|
|
83
|
-
viewBox="0 0 24 24"
|
|
84
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
85
|
-
><path
|
|
86
|
-
stroke-linecap="round"
|
|
87
|
-
stroke-linejoin="round"
|
|
88
|
-
stroke-width="2"
|
|
89
|
-
d="M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"
|
|
90
|
-
/>
|
|
91
|
-
</svg>
|
|
92
46
|
Explore community flows on WindmillHub
|
|
93
|
-
</
|
|
47
|
+
</Button>
|
|
94
48
|
</div>
|
|
95
49
|
</div>
|
|
@@ -16,7 +16,7 @@ export let flow;
|
|
|
16
16
|
class="inline-flex space-x-2 space-x-reverse flex-row-reverse w-full bottom-4 right-4 flex-wrap"
|
|
17
17
|
>
|
|
18
18
|
<button
|
|
19
|
-
on:click|stopPropagation={() => goto(`/flows/edit/${flow.path}
|
|
19
|
+
on:click|stopPropagation={() => goto(`/flows/edit/${flow.path}`)}
|
|
20
20
|
type="button"
|
|
21
21
|
class="inline-flex items-center text-gray-700 bg-transparent border border-gray-700 hover:bg-gray-800 hover:text-white focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded-lg text-xs px-3 py-1.5 text-center"
|
|
22
22
|
data-dismiss-target="#alert-additional-content-5"
|
|
@@ -1,51 +1,21 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { goto } from '$app/navigation'
|
|
3
|
+
import { faLink } from '@fortawesome/free-solid-svg-icons'
|
|
4
|
+
import Button from '../common/button/Button.svelte'
|
|
5
|
+
import HatIcon from '../icons/HatIcon.svelte'
|
|
3
6
|
</script>
|
|
4
7
|
|
|
5
8
|
<div class="p-4 border border-gray-300 rounded-md bg-gray-50 dark:border-gray-600 dark:bg-gray-700">
|
|
6
9
|
<div class="flex items-center">
|
|
7
10
|
<h3 class="inline-flex items-center text-lg font-medium text-gray-700 ">
|
|
8
|
-
<
|
|
9
|
-
class="w-6 h-6 mr-2"
|
|
10
|
-
fill="none"
|
|
11
|
-
stroke="currentColor"
|
|
12
|
-
viewBox="0 0 24 24"
|
|
13
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
14
|
-
><path d="M12 14l9-5-9-5-9 5 9 5z" /><path
|
|
15
|
-
d="M12 14l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14z"
|
|
16
|
-
/><path
|
|
17
|
-
stroke-linecap="round"
|
|
18
|
-
stroke-linejoin="round"
|
|
19
|
-
stroke-width="2"
|
|
20
|
-
d="M12 14l9-5-9-5-9 5 9 5zm0 0l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14zm-4 6v-7.5l4-2.222"
|
|
21
|
-
/>
|
|
22
|
-
</svg>
|
|
11
|
+
<HatIcon class="w-6 h-6 mr-2" />
|
|
23
12
|
Getting started
|
|
24
13
|
</h3>
|
|
25
14
|
</div>
|
|
26
15
|
<div class="mt-2 mb-4 text-sm text-gray-700 dark:text-gray-300">
|
|
27
16
|
Connect to apps like Slack, Google Drive or Airtable using OAuth.
|
|
28
17
|
</div>
|
|
29
|
-
<
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
type="button"
|
|
33
|
-
class="inline-flex items-center text-white bg-gray-700 hover:bg-gray-800 focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded-lg text-xs px-3 py-1.5 mr-2 text-center dark:bg-gray-600 dark:hover:bg-gray-500 dark:focus:ring-gray-600"
|
|
34
|
-
>
|
|
35
|
-
<svg
|
|
36
|
-
class="w-4 h-4 mr-2"
|
|
37
|
-
fill="none"
|
|
38
|
-
stroke="currentColor"
|
|
39
|
-
viewBox="0 0 24 24"
|
|
40
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
41
|
-
><path
|
|
42
|
-
stroke-linecap="round"
|
|
43
|
-
stroke-linejoin="round"
|
|
44
|
-
stroke-width="2"
|
|
45
|
-
d="M13.828 10.172a4 4 0 00-5.656 0l-4 4a4 4 0 105.656 5.656l1.102-1.101m-.758-4.899a4 4 0 005.656 0l4-4a4 4 0 00-5.656-5.656l-1.1 1.1"
|
|
46
|
-
/>
|
|
47
|
-
</svg>
|
|
48
|
-
Connect an API
|
|
49
|
-
</button>
|
|
50
|
-
</div>
|
|
18
|
+
<Button on:click={() => goto('resources')} color="dark" startIcon={{ icon: faLink }} size="xs">
|
|
19
|
+
Connect an API
|
|
20
|
+
</Button>
|
|
51
21
|
</div>
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
<script>import { goto } from '$app/navigation';
|
|
2
2
|
import { truncateHash } from '../../utils';
|
|
3
|
+
import { faPencil, faPlay } from '@fortawesome/free-solid-svg-icons';
|
|
4
|
+
import { Button, Badge, ActionRow } from '../common';
|
|
3
5
|
export let script;
|
|
4
6
|
</script>
|
|
5
7
|
|
|
@@ -12,70 +14,41 @@ export let script;
|
|
|
12
14
|
<div class="inline-flex justify-between w-full">
|
|
13
15
|
<div class="text-xs">{script.path}</div>
|
|
14
16
|
|
|
15
|
-
<
|
|
17
|
+
<Badge color="gray">
|
|
16
18
|
{truncateHash(script.hash)}
|
|
17
|
-
</
|
|
19
|
+
</Badge>
|
|
18
20
|
</div>
|
|
19
21
|
<div class="inline-flex space-x-1 w-full">
|
|
20
|
-
<
|
|
21
|
-
{
|
|
22
|
-
</
|
|
23
|
-
{#if script.
|
|
24
|
-
<
|
|
25
|
-
|
|
26
|
-
</
|
|
22
|
+
<Badge color="blue" capitalize>
|
|
23
|
+
{script.language}
|
|
24
|
+
</Badge>
|
|
25
|
+
{#if script.kind !== 'script'}
|
|
26
|
+
<Badge color="green" capitalize>
|
|
27
|
+
{script.kind}
|
|
28
|
+
</Badge>
|
|
27
29
|
{/if}
|
|
28
30
|
</div>
|
|
29
|
-
<
|
|
30
|
-
<
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
stroke="currentColor"
|
|
41
|
-
viewBox="0 0 24 24"
|
|
42
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
43
|
-
><path
|
|
44
|
-
stroke-linecap="round"
|
|
45
|
-
stroke-linejoin="round"
|
|
46
|
-
stroke-width="2"
|
|
47
|
-
d="M15.232 5.232l3.536 3.536m-2.036-5.036a2.5 2.5 0 113.536 3.536L6.5 21.036H3v-3.572L16.732 3.732z"
|
|
48
|
-
/>
|
|
49
|
-
</svg>
|
|
50
|
-
Edit
|
|
51
|
-
</button>
|
|
31
|
+
<ActionRow>
|
|
32
|
+
<svelte:fragment slot="right">
|
|
33
|
+
<Button
|
|
34
|
+
on:click={() => goto(`/scripts/edit/${script.hash}?step=2`)}
|
|
35
|
+
color="dark"
|
|
36
|
+
size="xs"
|
|
37
|
+
variant="border"
|
|
38
|
+
startIcon={{ icon: faPencil }}
|
|
39
|
+
>
|
|
40
|
+
Edit
|
|
41
|
+
</Button>
|
|
52
42
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
viewBox="0 0 24 24"
|
|
65
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
66
|
-
><path
|
|
67
|
-
stroke-linecap="round"
|
|
68
|
-
stroke-linejoin="round"
|
|
69
|
-
stroke-width="2"
|
|
70
|
-
d="M14.752 11.168l-3.197-2.132A1 1 0 0010 9.87v4.263a1 1 0 001.555.832l3.197-2.132a1 1 0 000-1.664z"
|
|
71
|
-
/><path
|
|
72
|
-
stroke-linecap="round"
|
|
73
|
-
stroke-linejoin="round"
|
|
74
|
-
stroke-width="2"
|
|
75
|
-
d="M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
76
|
-
/>
|
|
77
|
-
</svg>
|
|
78
|
-
Run
|
|
79
|
-
</button>
|
|
80
|
-
</div>
|
|
43
|
+
<Button
|
|
44
|
+
on:click={() => goto(`/scripts/run/${script.hash}`)}
|
|
45
|
+
color="dark"
|
|
46
|
+
size="xs"
|
|
47
|
+
variant="border"
|
|
48
|
+
startIcon={{ icon: faPlay }}
|
|
49
|
+
>
|
|
50
|
+
Run
|
|
51
|
+
</Button>
|
|
52
|
+
</svelte:fragment>
|
|
53
|
+
</ActionRow>
|
|
81
54
|
</div>
|
|
@@ -1,93 +1,47 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { goto } from '$app/navigation'
|
|
3
|
+
import { faExternalLink, faFile, faPlus } from '@fortawesome/free-solid-svg-icons'
|
|
4
|
+
import Button from '../common/button/Button.svelte'
|
|
5
|
+
import HatIcon from '../icons/HatIcon.svelte'
|
|
3
6
|
</script>
|
|
4
7
|
|
|
5
8
|
<div class="p-4 border border-gray-300 rounded-md bg-gray-50 ">
|
|
6
9
|
<div class="flex items-center">
|
|
7
10
|
<h3 class="inline-flex items-center text-lg font-medium text-gray-700 ">
|
|
8
|
-
<
|
|
9
|
-
class="w-6 h-6 mr-2"
|
|
10
|
-
fill="none"
|
|
11
|
-
stroke="currentColor"
|
|
12
|
-
viewBox="0 0 24 24"
|
|
13
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
14
|
-
><path d="M12 14l9-5-9-5-9 5 9 5z" /><path
|
|
15
|
-
d="M12 14l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14z"
|
|
16
|
-
/><path
|
|
17
|
-
stroke-linecap="round"
|
|
18
|
-
stroke-linejoin="round"
|
|
19
|
-
stroke-width="2"
|
|
20
|
-
d="M12 14l9-5-9-5-9 5 9 5zm0 0l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14zm-4 6v-7.5l4-2.222"
|
|
21
|
-
/>
|
|
22
|
-
</svg>
|
|
11
|
+
<HatIcon class="w-6 h-6 mr-2" />
|
|
23
12
|
Getting started
|
|
24
13
|
</h3>
|
|
25
14
|
</div>
|
|
26
15
|
<div class="mt-2 mb-4 text-sm text-gray-700 ">
|
|
27
16
|
Create a new script or find inspiration on the Hub!
|
|
28
17
|
</div>
|
|
29
|
-
<div class="inline-flex flex-wrap gap-y-2">
|
|
30
|
-
<
|
|
18
|
+
<div class="inline-flex flex-wrap gap-y-2 ">
|
|
19
|
+
<Button
|
|
31
20
|
on:click={() => goto('scripts/add')}
|
|
32
|
-
|
|
33
|
-
|
|
21
|
+
color="dark"
|
|
22
|
+
size="xs"
|
|
23
|
+
btnClasses="mr-2"
|
|
24
|
+
startIcon={{ icon: faPlus }}
|
|
34
25
|
>
|
|
35
|
-
<svg
|
|
36
|
-
class="w-4 h-4 mr-2"
|
|
37
|
-
fill="none"
|
|
38
|
-
stroke="currentColor"
|
|
39
|
-
viewBox="0 0 24 24"
|
|
40
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
41
|
-
><path
|
|
42
|
-
stroke-linecap="round"
|
|
43
|
-
stroke-linejoin="round"
|
|
44
|
-
stroke-width="2"
|
|
45
|
-
d="M12 6v6m0 0v6m0-6h6m-6 0H6"
|
|
46
|
-
/></svg
|
|
47
|
-
>
|
|
48
26
|
Create script
|
|
49
|
-
</
|
|
50
|
-
<
|
|
27
|
+
</Button>
|
|
28
|
+
<Button
|
|
51
29
|
on:click={() => goto('https://docs.windmill.dev/docs/getting_started/scripts')}
|
|
52
|
-
|
|
53
|
-
|
|
30
|
+
color="blue"
|
|
31
|
+
size="xs"
|
|
32
|
+
btnClasses="mr-2"
|
|
33
|
+
startIcon={{ icon: faFile }}
|
|
54
34
|
>
|
|
55
|
-
<svg
|
|
56
|
-
class="w-4 h-4 mr-2"
|
|
57
|
-
fill="none"
|
|
58
|
-
stroke="currentColor"
|
|
59
|
-
viewBox="0 0 24 24"
|
|
60
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
61
|
-
><path
|
|
62
|
-
stroke-linecap="round"
|
|
63
|
-
stroke-linejoin="round"
|
|
64
|
-
stroke-width="2"
|
|
65
|
-
d="M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"
|
|
66
|
-
/>
|
|
67
|
-
</svg>
|
|
68
35
|
Script documentation
|
|
69
|
-
</
|
|
70
|
-
<
|
|
36
|
+
</Button>
|
|
37
|
+
<Button
|
|
71
38
|
on:click={() => goto('https://hub.windmill.dev/')}
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
39
|
+
color="light"
|
|
40
|
+
variant="border"
|
|
41
|
+
size="xs"
|
|
42
|
+
startIcon={{ icon: faExternalLink }}
|
|
76
43
|
>
|
|
77
|
-
<svg
|
|
78
|
-
class="w-4 h-4 mr-2"
|
|
79
|
-
fill="none"
|
|
80
|
-
stroke="currentColor"
|
|
81
|
-
viewBox="0 0 24 24"
|
|
82
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
83
|
-
><path
|
|
84
|
-
stroke-linecap="round"
|
|
85
|
-
stroke-linejoin="round"
|
|
86
|
-
stroke-width="2"
|
|
87
|
-
d="M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"
|
|
88
|
-
/>
|
|
89
|
-
</svg>
|
|
90
44
|
Explore community scripts on WindmillHub
|
|
91
|
-
</
|
|
45
|
+
</Button>
|
|
92
46
|
</div>
|
|
93
47
|
</div>
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
<script>import { truncate } from '../../utils';
|
|
2
2
|
import { createEventDispatcher } from 'svelte';
|
|
3
|
+
import { NEVER_TESTED_THIS_FAR } from '../flows/flowStateUtils';
|
|
3
4
|
import { getTypeAsString } from '../flows/utils';
|
|
4
5
|
import { computeKey } from './utils';
|
|
5
6
|
import WarningMessage from './WarningMessage.svelte';
|
|
@@ -31,15 +32,19 @@ function selectProp(key) {
|
|
|
31
32
|
|
|
32
33
|
{#if keys.length > 0}
|
|
33
34
|
<span class:hidden={collapsed}>
|
|
34
|
-
{#if level != 0}<span
|
|
35
|
-
|
|
36
|
-
|
|
35
|
+
{#if level != 0}<span
|
|
36
|
+
class="cursor-pointer hover:bg-slate-200 px-1 rounded"
|
|
37
|
+
on:click={collapse}
|
|
38
|
+
>
|
|
39
|
+
(-)
|
|
40
|
+
</span>
|
|
41
|
+
{/if}
|
|
37
42
|
<ul class="w-full">
|
|
38
43
|
{#each keys as key, index}
|
|
39
44
|
<li class="pt-1">
|
|
40
|
-
<button on:click={() => selectProp(key)} class="key rounded px-1 hover:bg-sky-100"
|
|
41
|
-
|
|
42
|
-
>
|
|
45
|
+
<button on:click={() => selectProp(key)} class="key rounded px-1 hover:bg-sky-100">
|
|
46
|
+
{!isArray ? key : index}:
|
|
47
|
+
</button>
|
|
43
48
|
|
|
44
49
|
{#if getTypeAsString(json[key]) === 'object'}
|
|
45
50
|
<svelte:self
|
|
@@ -55,8 +60,10 @@ function selectProp(key) {
|
|
|
55
60
|
class="val rounded px-1 hover:bg-sky-100 {getTypeAsString(json[key])}"
|
|
56
61
|
on:click={() => selectProp(key)}
|
|
57
62
|
>
|
|
58
|
-
{#if json[key] ===
|
|
63
|
+
{#if json[key] === NEVER_TESTED_THIS_FAR}
|
|
59
64
|
<WarningMessage />
|
|
65
|
+
{:else if json[key] == undefined}
|
|
66
|
+
<span>undefined</span>
|
|
60
67
|
{:else}
|
|
61
68
|
<span>{truncate(JSON.stringify(json[key]), 40)}</span>
|
|
62
69
|
{/if}
|
|
@@ -83,6 +90,8 @@ function selectProp(key) {
|
|
|
83
90
|
border-left: 1px dotted lightgray;
|
|
84
91
|
--tw-text-opacity: 1;
|
|
85
92
|
color: rgb(0 0 0 / var(--tw-text-opacity));
|
|
93
|
+
font-size: 0.875rem;
|
|
94
|
+
line-height: 1.25rem;
|
|
86
95
|
}
|
|
87
96
|
|
|
88
97
|
.val {
|
|
@@ -1,22 +1,48 @@
|
|
|
1
|
-
<script>import
|
|
1
|
+
<script>import { faClose } from '@fortawesome/free-solid-svg-icons';
|
|
2
|
+
import { getContext } from 'svelte';
|
|
3
|
+
import Icon from 'svelte-awesome';
|
|
4
|
+
import ObjectViewer from './ObjectViewer.svelte';
|
|
2
5
|
import { keepByKey } from './utils';
|
|
3
6
|
export let pickableProperties = {};
|
|
4
7
|
const EMPTY_STRING = '';
|
|
5
8
|
let search = '';
|
|
9
|
+
const { propPickerConfig, clearFocus } = getContext('PropPickerWrapper');
|
|
6
10
|
$: propsFiltered =
|
|
7
11
|
search === EMPTY_STRING ? pickableProperties : keepByKey(pickableProperties, search);
|
|
8
12
|
</script>
|
|
9
13
|
|
|
10
|
-
<div
|
|
11
|
-
class="
|
|
12
|
-
>
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
14
|
+
<div class="px-4 pt-4">
|
|
15
|
+
<div class="flex justify-between items-center h-8">
|
|
16
|
+
<span class="font-bold text-sm">Context</span>
|
|
17
|
+
<div class="flex space-x-2 items-center">
|
|
18
|
+
{#if $propPickerConfig}
|
|
19
|
+
<span
|
|
20
|
+
class="flex items-center bg-blue-100 text-blue-800 text-xs font-semibold px-2 py-1 rounded dark:bg-green-200 dark:text-green-900"
|
|
21
|
+
>
|
|
22
|
+
{`Selected input: ${$propPickerConfig?.propName}`}
|
|
23
|
+
</span>
|
|
24
|
+
<span
|
|
25
|
+
class="flex items-center bg-blue-100 text-blue-800 text-xs font-semibold px-2 py-1 rounded dark:bg-green-200 dark:text-green-900"
|
|
26
|
+
>
|
|
27
|
+
{`Mode: ${$propPickerConfig?.insertionMode}`}
|
|
28
|
+
</span>
|
|
29
|
+
<button
|
|
30
|
+
class="border px-2 py-1 text-xs rounded-md flex items-center hover:bg-gray-50 hover:text-gray-900"
|
|
31
|
+
on:click={() => clearFocus()}
|
|
32
|
+
>
|
|
33
|
+
<Icon data={faClose} class="mr-2" scale={0.8} />
|
|
34
|
+
Deselect
|
|
35
|
+
</button>
|
|
36
|
+
{/if}
|
|
37
|
+
</div>
|
|
21
38
|
</div>
|
|
39
|
+
<input
|
|
40
|
+
type="text"
|
|
41
|
+
bind:value={search}
|
|
42
|
+
class="bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg block p-2 mb-2"
|
|
43
|
+
placeholder="Search prop..."
|
|
44
|
+
/>
|
|
45
|
+
</div>
|
|
46
|
+
<div class="overflow-y-auto mb-8">
|
|
47
|
+
<ObjectViewer json={propsFiltered} on:select />
|
|
22
48
|
</div>
|
|
@@ -1,16 +1,3 @@
|
|
|
1
|
-
<div class="flex px-
|
|
2
|
-
<
|
|
3
|
-
class="flex-shrink-0 w-5 h-5 text-yellow-700 dark:text-yellow-800"
|
|
4
|
-
fill="currentColor"
|
|
5
|
-
viewBox="0 0 20 20"
|
|
6
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
7
|
-
><path
|
|
8
|
-
fill-rule="evenodd"
|
|
9
|
-
d="M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z"
|
|
10
|
-
clip-rule="evenodd"
|
|
11
|
-
/></svg
|
|
12
|
-
>
|
|
13
|
-
<div class="ml-3 text-sm font-medium text-yellow-700 dark:text-yellow-800">
|
|
14
|
-
Previous results are not available unless a preview is run on the previous step.
|
|
15
|
-
</div>
|
|
1
|
+
<div class="flex px-2 bg-yellow-100 rounded-lg dark:bg-yellow-200" role="alert">
|
|
2
|
+
<div class="text-sm font-medium text-yellow-700 dark:text-yellow-800">Require testing flow</div>
|
|
16
3
|
</div>
|