mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-09-11 16:09:39 +00:00
update openapi-typescript-codegen
This commit is contained in:
Generated
+25
-25
@@ -61,7 +61,7 @@
|
||||
"eslint-plugin-svelte3": "^4.0.0",
|
||||
"monaco-editor-workers": "~0.37.0",
|
||||
"ol": "^7.2.2",
|
||||
"openapi-typescript-codegen": "^0.23.0",
|
||||
"openapi-typescript-codegen": "^0.24.0",
|
||||
"path-browserify": "^1.0.1",
|
||||
"pdfjs-dist": "^3.6.172",
|
||||
"postcss": "^8.4.23",
|
||||
@@ -1937,12 +1937,12 @@
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/commander": {
|
||||
"version": "9.5.0",
|
||||
"resolved": "https://registry.npmjs.org/commander/-/commander-9.5.0.tgz",
|
||||
"integrity": "sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==",
|
||||
"version": "10.0.1",
|
||||
"resolved": "https://registry.npmjs.org/commander/-/commander-10.0.1.tgz",
|
||||
"integrity": "sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==",
|
||||
"dev": true,
|
||||
"engines": {
|
||||
"node": "^12.20.0 || >=14"
|
||||
"node": ">=14"
|
||||
}
|
||||
},
|
||||
"node_modules/compute-scroll-into-view": {
|
||||
@@ -3025,9 +3025,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/fs-extra": {
|
||||
"version": "10.1.0",
|
||||
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",
|
||||
"integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==",
|
||||
"version": "11.1.1",
|
||||
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.1.1.tgz",
|
||||
"integrity": "sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"graceful-fs": "^4.2.0",
|
||||
@@ -3035,7 +3035,7 @@
|
||||
"universalify": "^2.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=12"
|
||||
"node": ">=14.14"
|
||||
}
|
||||
},
|
||||
"node_modules/fs-minipass": {
|
||||
@@ -4363,14 +4363,14 @@
|
||||
}
|
||||
},
|
||||
"node_modules/openapi-typescript-codegen": {
|
||||
"version": "0.23.0",
|
||||
"resolved": "https://registry.npmjs.org/openapi-typescript-codegen/-/openapi-typescript-codegen-0.23.0.tgz",
|
||||
"integrity": "sha512-gOJXy5g3H3HlLpVNN+USrNK2i2KYBmDczk9Xk34u6JorwrGiDJZUj+al4S+i9TXdfUQ/ZaLxE59Xf3wqkxGfqA==",
|
||||
"version": "0.24.0",
|
||||
"resolved": "https://registry.npmjs.org/openapi-typescript-codegen/-/openapi-typescript-codegen-0.24.0.tgz",
|
||||
"integrity": "sha512-rSt8t1XbMWhv6Db7GUI24NNli7FU5kzHLxcE8BpzgGWRdWyWt9IB2YoLyPahxNrVA7yOaVgnXPkrcTDRMQtJYg==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"camelcase": "^6.3.0",
|
||||
"commander": "^9.3.0",
|
||||
"fs-extra": "^10.1.0",
|
||||
"commander": "^10.0.0",
|
||||
"fs-extra": "^11.1.1",
|
||||
"handlebars": "^4.7.7",
|
||||
"json-schema-ref-parser": "^9.0.9"
|
||||
},
|
||||
@@ -8588,9 +8588,9 @@
|
||||
"dev": true
|
||||
},
|
||||
"commander": {
|
||||
"version": "9.5.0",
|
||||
"resolved": "https://registry.npmjs.org/commander/-/commander-9.5.0.tgz",
|
||||
"integrity": "sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==",
|
||||
"version": "10.0.1",
|
||||
"resolved": "https://registry.npmjs.org/commander/-/commander-10.0.1.tgz",
|
||||
"integrity": "sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==",
|
||||
"dev": true
|
||||
},
|
||||
"compute-scroll-into-view": {
|
||||
@@ -9405,9 +9405,9 @@
|
||||
"dev": true
|
||||
},
|
||||
"fs-extra": {
|
||||
"version": "10.1.0",
|
||||
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",
|
||||
"integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==",
|
||||
"version": "11.1.1",
|
||||
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.1.1.tgz",
|
||||
"integrity": "sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"graceful-fs": "^4.2.0",
|
||||
@@ -10428,14 +10428,14 @@
|
||||
}
|
||||
},
|
||||
"openapi-typescript-codegen": {
|
||||
"version": "0.23.0",
|
||||
"resolved": "https://registry.npmjs.org/openapi-typescript-codegen/-/openapi-typescript-codegen-0.23.0.tgz",
|
||||
"integrity": "sha512-gOJXy5g3H3HlLpVNN+USrNK2i2KYBmDczk9Xk34u6JorwrGiDJZUj+al4S+i9TXdfUQ/ZaLxE59Xf3wqkxGfqA==",
|
||||
"version": "0.24.0",
|
||||
"resolved": "https://registry.npmjs.org/openapi-typescript-codegen/-/openapi-typescript-codegen-0.24.0.tgz",
|
||||
"integrity": "sha512-rSt8t1XbMWhv6Db7GUI24NNli7FU5kzHLxcE8BpzgGWRdWyWt9IB2YoLyPahxNrVA7yOaVgnXPkrcTDRMQtJYg==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"camelcase": "^6.3.0",
|
||||
"commander": "^9.3.0",
|
||||
"fs-extra": "^10.1.0",
|
||||
"commander": "^10.0.0",
|
||||
"fs-extra": "^11.1.1",
|
||||
"handlebars": "^4.7.7",
|
||||
"json-schema-ref-parser": "^9.0.9"
|
||||
}
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
"eslint-plugin-svelte3": "^4.0.0",
|
||||
"monaco-editor-workers": "~0.37.0",
|
||||
"ol": "^7.2.2",
|
||||
"openapi-typescript-codegen": "^0.23.0",
|
||||
"openapi-typescript-codegen": "^0.24.0",
|
||||
"path-browserify": "^1.0.1",
|
||||
"pdfjs-dist": "^3.6.172",
|
||||
"postcss": "^8.4.23",
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
export let runnable:
|
||||
| {
|
||||
summary?: string
|
||||
schema?: Schema
|
||||
schema?: Schema | any
|
||||
description?: string
|
||||
path?: string
|
||||
is_template?: boolean
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
|
||||
const dispatch = createEventDispatcher()
|
||||
|
||||
const selectArgs = (selected_args: object) => {
|
||||
const selectArgs = (selected_args: any) => {
|
||||
dispatch('selected_args', selected_args)
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
const moveAnimationDuration = 300
|
||||
|
||||
export let schema: Schema = emptySchema()
|
||||
export let schema: Schema | any = emptySchema()
|
||||
if (!schema) {
|
||||
schema = emptySchema()
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
import ItemPicker from './ItemPicker.svelte'
|
||||
import VariableEditor from './VariableEditor.svelte'
|
||||
|
||||
export let schema: Schema
|
||||
export let schema: Schema | any
|
||||
export let args: Record<string, any> = {}
|
||||
export let disabledArgs: string[] = []
|
||||
export let disabled = false
|
||||
|
||||
@@ -10,7 +10,14 @@
|
||||
import Tabs from './common/tabs/Tabs.svelte'
|
||||
import { Badge } from './common'
|
||||
|
||||
export let schema: Schema | undefined = emptySchema()
|
||||
export let schema: Schema | undefined | any = emptySchema()
|
||||
|
||||
function getProperties(schema: Schema) {
|
||||
if (schema.properties) {
|
||||
return Object.entries(schema.properties)
|
||||
}
|
||||
return []
|
||||
}
|
||||
</script>
|
||||
|
||||
<div class="w-full">
|
||||
@@ -32,7 +39,7 @@
|
||||
<th>required</th>
|
||||
</tr>
|
||||
<tbody slot="body">
|
||||
{#each Object.entries(schema.properties) as [name, property] (name)}
|
||||
{#each getProperties(schema) as [name, property] (name)}
|
||||
<tr>
|
||||
<td class="font-semibold pl-1">{name}</td>
|
||||
<td
|
||||
|
||||
@@ -126,7 +126,7 @@
|
||||
|
||||
script.schema = script.schema ?? emptySchema()
|
||||
try {
|
||||
await inferArgs(script.language, script.content, script.schema)
|
||||
await inferArgs(script.language, script.content, script.schema as any)
|
||||
} catch (error) {
|
||||
sendUserToast(
|
||||
`The main signature was not parsable. This script is considered to be without main function`
|
||||
@@ -164,7 +164,7 @@
|
||||
|
||||
script.schema = script.schema ?? emptySchema()
|
||||
try {
|
||||
await inferArgs(script.language, script.content, script.schema)
|
||||
await inferArgs(script.language, script.content, script.schema as any)
|
||||
} catch (error) {
|
||||
sendUserToast(
|
||||
`The main signature was not parsable. This script is considered to be without main function`
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
import { scriptLangToEditorLang } from '$lib/scripts'
|
||||
|
||||
// Exported
|
||||
export let schema: Schema = emptySchema()
|
||||
export let schema: Schema | any = emptySchema()
|
||||
export let code: string
|
||||
export let path: string | undefined
|
||||
export let lang: Preview.language
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
import Highlight from 'svelte-highlight'
|
||||
import json from 'svelte-highlight/languages/json'
|
||||
|
||||
export let schema: Schema
|
||||
export let schema: Schema | any
|
||||
|
||||
export function setSchema(newSchema: Schema) {
|
||||
schema = newSchema
|
||||
|
||||
@@ -50,14 +50,14 @@ export async function loadSchema(
|
||||
path
|
||||
})
|
||||
|
||||
return { schema: script.schema, summary: script.summary }
|
||||
return { schema: script.schema as any, summary: script.summary }
|
||||
} else if (runType === 'flow') {
|
||||
const flow = await FlowService.getFlowByPath({
|
||||
workspace,
|
||||
path
|
||||
})
|
||||
|
||||
return { schema: flow.schema, summary: flow.summary }
|
||||
return { schema: flow.schema as any, summary: flow.summary }
|
||||
} else {
|
||||
const script = await ScriptService.getHubScriptByPath({
|
||||
path
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
$: stepPropPicker = failureModule
|
||||
? {
|
||||
pickableProperties: {
|
||||
flow_input: schemaToObject($flowStore.schema, $previewArgs),
|
||||
flow_input: schemaToObject($flowStore.schema as any, $previewArgs),
|
||||
priorIds: {},
|
||||
previousId: undefined,
|
||||
hasResume: false
|
||||
|
||||
@@ -109,7 +109,12 @@ export function getStepPropPicker(
|
||||
args: any,
|
||||
include_node: boolean
|
||||
): StepPropPicker {
|
||||
const flowInput = getFlowInput(dfs(parentModule?.id, flow), flowState, args, flow.schema)
|
||||
const flowInput = getFlowInput(
|
||||
dfs(parentModule?.id, flow),
|
||||
flowState,
|
||||
args,
|
||||
flow.schema as Schema
|
||||
)
|
||||
|
||||
const previousIds = dfs(id, flow, false)
|
||||
.map((x) => {
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
import WarningMessage from './WarningMessage.svelte'
|
||||
import { NEVER_TESTED_THIS_FAR } from '../flows/models'
|
||||
|
||||
export let json: Object
|
||||
export let json: any
|
||||
export let level = 0
|
||||
export let currentPath: string = ''
|
||||
export let pureViewer = false
|
||||
|
||||
@@ -8,7 +8,7 @@ export function scriptToHubUrl(
|
||||
description: string,
|
||||
kind: Script.kind,
|
||||
language: Script.language,
|
||||
schema: Schema | undefined,
|
||||
schema: Schema | any,
|
||||
lock: string | undefined
|
||||
): URL {
|
||||
const url = new URL('https://hub.windmill.dev/scripts/add')
|
||||
|
||||
@@ -32,13 +32,13 @@ export async function loadSchema(path: string, hash?: string): Promise<Schema> {
|
||||
workspace: get(workspaceStore)!,
|
||||
hash
|
||||
})
|
||||
return script.schema
|
||||
return script.schema as any
|
||||
} else {
|
||||
const script = await ScriptService.getScriptByPath({
|
||||
workspace: get(workspaceStore)!,
|
||||
path: path ?? ''
|
||||
})
|
||||
return script.schema
|
||||
return script.schema as any
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ export async function loadSchemaFlow(path: string): Promise<Schema> {
|
||||
workspace: get(workspaceStore)!,
|
||||
path: path ?? ''
|
||||
})
|
||||
return flow.schema
|
||||
return flow.schema as any
|
||||
}
|
||||
|
||||
export function scriptPathToHref(path: string): string {
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
import { cubicOut } from 'svelte/easing'
|
||||
import { ArrowLeftIcon, ArrowRightIcon } from 'lucide-svelte'
|
||||
import { sendUserToast } from '$lib/toast'
|
||||
import type { Schema } from '$lib/common'
|
||||
|
||||
$: hash = $page.params.hash
|
||||
let script: Script | undefined
|
||||
@@ -38,7 +39,7 @@
|
||||
|
||||
if (script.schema == undefined) {
|
||||
script.schema = emptySchema()
|
||||
await inferArgs(script.language, script.content, script.schema)
|
||||
await inferArgs(script.language, script.content, script.schema as Schema)
|
||||
script = script
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user