Skip to content

Commit d12e154

Browse files
committed
fix: update runtime hooks to use ClientCreateInput/ClientUpdateInput
Update mutation hooks to reference the renamed Wails-generated input types and bump all package versions to 0.2.1.
1 parent f8042aa commit d12e154

4 files changed

Lines changed: 10 additions & 10 deletions

File tree

packages/omniviewdev-runtime/src/hooks/resource/useResource.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export const useResource = ({
6262
// === Mutations === //
6363

6464
const { mutateAsync: update } = useMutation({
65-
mutationFn: async (opts: { input?: any }) => Update(pluginID, connectionID, resourceKey, resource.UpdateInput.createFrom({
65+
mutationFn: async (opts: { input?: any }) => Update(pluginID, connectionID, resourceKey, resource.ClientUpdateInput.createFrom({
6666
input: opts.input,
6767
id: resourceID,
6868
namespace,

packages/omniviewdev-runtime/src/hooks/resource/useResourceMutations.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ export const useResourceMutations = ({ pluginID: explicitPluginID }: UseResource
6565
pluginID,
6666
opts.connectionID,
6767
opts.resourceKey,
68-
resource.CreateInput.createFrom({
68+
resource.ClientCreateInput.createFrom({
6969
input: input.input,
7070
namespace: input.namespace ?? opts.namespace ?? '',
7171
})
@@ -84,7 +84,7 @@ export const useResourceMutations = ({ pluginID: explicitPluginID }: UseResource
8484
pluginID,
8585
opts.connectionID,
8686
opts.resourceKey,
87-
resource.UpdateInput.createFrom({
87+
resource.ClientUpdateInput.createFrom({
8888
input: input.input,
8989
id: opts.resourceID,
9090
namespace: opts.namespace ?? '',

packages/omniviewdev-runtime/src/hooks/resource/useResources.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ export const useResources = ({
8282
// === Mutations === //
8383

8484
const { mutateAsync: create } = useMutation({
85-
mutationFn: async (opts: { input?: any; namespace?: string }) => Create(pluginID, connectionID, resourceKey, resourceModels.CreateInput.createFrom({
85+
mutationFn: async (opts: { input?: any; namespace?: string }) => Create(pluginID, connectionID, resourceKey, resourceModels.ClientCreateInput.createFrom({
8686
input: opts.input,
8787
namespace: opts.namespace ?? (stableNamespaces.length === 1 ? stableNamespaces[0] : ''),
8888
})),

packages/omniviewdev-runtime/src/wailsjs/go/models.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2676,6 +2676,12 @@ export namespace time {
26762676

26772677
export namespace trivy {
26782678

2679+
export enum Scanner {
2680+
VULN = "vuln",
2681+
MISCONFIG = "misconfig",
2682+
SECRET = "secret",
2683+
LICENSE = "license",
2684+
}
26792685
export enum Command {
26802686
CONFIG = "config",
26812687
FILESYSTEM = "fs",
@@ -2685,12 +2691,6 @@ export namespace trivy {
26852691
ROOTFS = "rootfs",
26862692
SBOM = "sbom",
26872693
}
2688-
export enum Scanner {
2689-
VULN = "vuln",
2690-
MISCONFIG = "misconfig",
2691-
SECRET = "secret",
2692-
LICENSE = "license",
2693-
}
26942694
export class ScanOptions {
26952695
filePatterns: string[];
26962696
skipDirs: string[];

0 commit comments

Comments
 (0)