@kubb/plugin-solid-query 4.12.3 → 4.12.4

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.
@@ -25,29 +25,29 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
25
25
  }) : target, mod));
26
26
 
27
27
  //#endregion
28
- const require_components = require('./components-CN5aDA3t.cjs');
28
+ const require_components = require('./components-BXqP1b7p.cjs');
29
29
  let node_path = require("node:path");
30
30
  node_path = __toESM(node_path);
31
- let __kubb_plugin_client = require("@kubb/plugin-client");
32
- let __kubb_plugin_ts = require("@kubb/plugin-ts");
33
- let __kubb_plugin_zod = require("@kubb/plugin-zod");
34
- let __kubb_plugin_client_components = require("@kubb/plugin-client/components");
35
- let __kubb_plugin_oas_utils = require("@kubb/plugin-oas/utils");
36
- let __kubb_react_fabric = require("@kubb/react-fabric");
37
- let __kubb_react_fabric_jsx_runtime = require("@kubb/react-fabric/jsx-runtime");
38
- let __kubb_core_hooks = require("@kubb/core/hooks");
39
- let __kubb_plugin_oas_generators = require("@kubb/plugin-oas/generators");
40
- let __kubb_plugin_oas_hooks = require("@kubb/plugin-oas/hooks");
31
+ let _kubb_plugin_client = require("@kubb/plugin-client");
32
+ let _kubb_plugin_ts = require("@kubb/plugin-ts");
33
+ let _kubb_plugin_zod = require("@kubb/plugin-zod");
34
+ let _kubb_plugin_client_components = require("@kubb/plugin-client/components");
35
+ let _kubb_plugin_oas_utils = require("@kubb/plugin-oas/utils");
36
+ let _kubb_react_fabric = require("@kubb/react-fabric");
37
+ let _kubb_react_fabric_jsx_runtime = require("@kubb/react-fabric/jsx-runtime");
38
+ let _kubb_core_hooks = require("@kubb/core/hooks");
39
+ let _kubb_plugin_oas_generators = require("@kubb/plugin-oas/generators");
40
+ let _kubb_plugin_oas_hooks = require("@kubb/plugin-oas/hooks");
41
41
  let remeda = require("remeda");
42
42
 
43
43
  //#region src/generators/mutationGenerator.tsx
44
- const mutationGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
44
+ const mutationGenerator = (0, _kubb_plugin_oas_generators.createReactGenerator)({
45
45
  name: "solid-query",
46
46
  Operation({ config, operation, generator, plugin }) {
47
47
  const { options, options: { output } } = plugin;
48
- const pluginManager = (0, __kubb_core_hooks.usePluginManager)();
49
- const oas = (0, __kubb_plugin_oas_hooks.useOas)();
50
- const { getSchemas, getName, getFile } = (0, __kubb_plugin_oas_hooks.useOperationManager)(generator);
48
+ const pluginManager = (0, _kubb_core_hooks.usePluginManager)();
49
+ const oas = (0, _kubb_plugin_oas_hooks.useOas)();
50
+ const { getSchemas, getName, getFile } = (0, _kubb_plugin_oas_hooks.useOperationManager)(generator);
51
51
  const isQuery = !!options.query && options.query?.methods.some((method) => operation.method === method);
52
52
  const isMutation = options.mutation !== false && !isQuery && (0, remeda.difference)(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some((method) => operation.method === method);
53
53
  const importPath = options.mutation ? options.mutation.importPath : "@tanstack/solid-query";
@@ -60,26 +60,26 @@ const mutationGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)
60
60
  file: getFile(operation, { prefix: "use" })
61
61
  };
62
62
  const type = {
63
- file: getFile(operation, { pluginKey: [__kubb_plugin_ts.pluginTsName] }),
63
+ file: getFile(operation, { pluginKey: [_kubb_plugin_ts.pluginTsName] }),
64
64
  schemas: getSchemas(operation, {
65
- pluginKey: [__kubb_plugin_ts.pluginTsName],
65
+ pluginKey: [_kubb_plugin_ts.pluginTsName],
66
66
  type: "type"
67
67
  })
68
68
  };
69
69
  const zod = {
70
- file: getFile(operation, { pluginKey: [__kubb_plugin_zod.pluginZodName] }),
70
+ file: getFile(operation, { pluginKey: [_kubb_plugin_zod.pluginZodName] }),
71
71
  schemas: getSchemas(operation, {
72
- pluginKey: [__kubb_plugin_zod.pluginZodName],
72
+ pluginKey: [_kubb_plugin_zod.pluginZodName],
73
73
  type: "function"
74
74
  })
75
75
  };
76
- const shouldUseClientPlugin = !!pluginManager.getPluginByKey([__kubb_plugin_client.pluginClientName]) && options.client.clientType !== "class";
76
+ const shouldUseClientPlugin = !!pluginManager.getPluginByKey([_kubb_plugin_client.pluginClientName]) && options.client.clientType !== "class";
77
77
  const client = {
78
78
  name: shouldUseClientPlugin ? getName(operation, {
79
79
  type: "function",
80
- pluginKey: [__kubb_plugin_client.pluginClientName]
80
+ pluginKey: [_kubb_plugin_client.pluginClientName]
81
81
  }) : getName(operation, { type: "function" }),
82
- file: getFile(operation, { pluginKey: [__kubb_plugin_client.pluginClientName] })
82
+ file: getFile(operation, { pluginKey: [_kubb_plugin_client.pluginClientName] })
83
83
  };
84
84
  const mutationKey = {
85
85
  name: getName(operation, {
@@ -92,70 +92,70 @@ const mutationGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)
92
92
  })
93
93
  };
94
94
  if (!isMutation) return null;
95
- return /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric.File, {
95
+ return /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric.File, {
96
96
  baseName: mutation.file.baseName,
97
97
  path: mutation.file.path,
98
98
  meta: mutation.file.meta,
99
- banner: (0, __kubb_plugin_oas_utils.getBanner)({
99
+ banner: (0, _kubb_plugin_oas_utils.getBanner)({
100
100
  oas,
101
101
  output,
102
102
  config: pluginManager.config
103
103
  }),
104
- footer: (0, __kubb_plugin_oas_utils.getFooter)({
104
+ footer: (0, _kubb_plugin_oas_utils.getFooter)({
105
105
  oas,
106
106
  output
107
107
  }),
108
108
  children: [
109
- options.parser === "zod" && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
109
+ options.parser === "zod" && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
110
110
  name: [zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean),
111
111
  root: mutation.file.path,
112
112
  path: zod.file.path
113
113
  }),
114
- options.client.importPath ? /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric_jsx_runtime.Fragment, { children: [
115
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
114
+ options.client.importPath ? /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric_jsx_runtime.Fragment, { children: [
115
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
116
116
  name: "fetch",
117
117
  path: options.client.importPath
118
118
  }),
119
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
119
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
120
120
  name: ["RequestConfig", "ResponseErrorConfig"],
121
121
  path: options.client.importPath,
122
122
  isTypeOnly: true
123
123
  }),
124
- options.client.dataReturnType === "full" && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
124
+ options.client.dataReturnType === "full" && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
125
125
  name: ["ResponseConfig"],
126
126
  path: options.client.importPath,
127
127
  isTypeOnly: true
128
128
  })
129
- ] }) : /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric_jsx_runtime.Fragment, { children: [
130
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
129
+ ] }) : /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric_jsx_runtime.Fragment, { children: [
130
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
131
131
  name: ["fetch"],
132
132
  root: mutation.file.path,
133
133
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/fetch.ts")
134
134
  }),
135
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
135
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
136
136
  name: ["RequestConfig", "ResponseErrorConfig"],
137
137
  root: mutation.file.path,
138
138
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/fetch.ts"),
139
139
  isTypeOnly: true
140
140
  }),
141
- options.client.dataReturnType === "full" && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
141
+ options.client.dataReturnType === "full" && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
142
142
  name: ["ResponseConfig"],
143
143
  root: mutation.file.path,
144
144
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/fetch.ts"),
145
145
  isTypeOnly: true
146
146
  })
147
147
  ] }),
148
- shouldUseClientPlugin && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
148
+ shouldUseClientPlugin && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
149
149
  name: [client.name],
150
150
  root: mutation.file.path,
151
151
  path: client.file.path
152
152
  }),
153
- !shouldUseClientPlugin && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
153
+ !shouldUseClientPlugin && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
154
154
  name: ["buildFormData"],
155
155
  root: mutation.file.path,
156
156
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/config.ts")
157
157
  }),
158
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
158
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
159
159
  name: [
160
160
  type.schemas.request?.name,
161
161
  type.schemas.response.name,
@@ -168,7 +168,7 @@ const mutationGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)
168
168
  path: type.file.path,
169
169
  isTypeOnly: true
170
170
  }),
171
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(require_components.MutationKey, {
171
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(require_components.MutationKey, {
172
172
  name: mutationKey.name,
173
173
  typeName: mutationKey.typeName,
174
174
  operation,
@@ -177,7 +177,7 @@ const mutationGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)
177
177
  paramsCasing: options.paramsCasing,
178
178
  transformer: options.mutationKey
179
179
  }),
180
- !shouldUseClientPlugin && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_plugin_client_components.Client, {
180
+ !shouldUseClientPlugin && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_plugin_client_components.Client, {
181
181
  name: client.name,
182
182
  baseURL: options.client.baseURL,
183
183
  operation,
@@ -189,17 +189,17 @@ const mutationGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)
189
189
  pathParamsType: options.pathParamsType,
190
190
  parser: options.parser
191
191
  }),
192
- options.mutation && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric_jsx_runtime.Fragment, { children: [
193
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
192
+ options.mutation && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric_jsx_runtime.Fragment, { children: [
193
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
194
194
  name: ["useMutation"],
195
195
  path: importPath
196
196
  }),
197
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
197
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
198
198
  name: ["UseMutationOptions", "QueryClient"],
199
199
  path: importPath,
200
200
  isTypeOnly: true
201
201
  }),
202
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(require_components.Mutation, {
202
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(require_components.Mutation, {
203
203
  name: mutation.name,
204
204
  clientName: client.name,
205
205
  typeName: mutation.typeName,
@@ -219,13 +219,13 @@ const mutationGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)
219
219
 
220
220
  //#endregion
221
221
  //#region src/generators/queryGenerator.tsx
222
- const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
222
+ const queryGenerator = (0, _kubb_plugin_oas_generators.createReactGenerator)({
223
223
  name: "solid-query",
224
224
  Operation({ config, operation, generator, plugin }) {
225
225
  const { options, options: { output } } = plugin;
226
- const pluginManager = (0, __kubb_core_hooks.usePluginManager)();
227
- const oas = (0, __kubb_plugin_oas_hooks.useOas)();
228
- const { getSchemas, getName, getFile } = (0, __kubb_plugin_oas_hooks.useOperationManager)(generator);
226
+ const pluginManager = (0, _kubb_core_hooks.usePluginManager)();
227
+ const oas = (0, _kubb_plugin_oas_hooks.useOas)();
228
+ const { getSchemas, getName, getFile } = (0, _kubb_plugin_oas_hooks.useOperationManager)(generator);
229
229
  const isQuery = typeof options.query === "boolean" ? true : options.query?.methods.some((method) => operation.method === method);
230
230
  const isMutation = (0, remeda.difference)([
231
231
  "post",
@@ -242,13 +242,13 @@ const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
242
242
  typeName: getName(operation, { type: "type" }),
243
243
  file: getFile(operation, { prefix: "create" })
244
244
  };
245
- const shouldUseClientPlugin = !!pluginManager.getPluginByKey([__kubb_plugin_client.pluginClientName]) && options.client.clientType !== "class";
245
+ const shouldUseClientPlugin = !!pluginManager.getPluginByKey([_kubb_plugin_client.pluginClientName]) && options.client.clientType !== "class";
246
246
  const client = {
247
247
  name: shouldUseClientPlugin ? getName(operation, {
248
248
  type: "function",
249
- pluginKey: [__kubb_plugin_client.pluginClientName]
249
+ pluginKey: [_kubb_plugin_client.pluginClientName]
250
250
  }) : getName(operation, { type: "function" }),
251
- file: getFile(operation, { pluginKey: [__kubb_plugin_client.pluginClientName] })
251
+ file: getFile(operation, { pluginKey: [_kubb_plugin_client.pluginClientName] })
252
252
  };
253
253
  const queryOptions = { name: getName(operation, {
254
254
  type: "function",
@@ -265,84 +265,84 @@ const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
265
265
  })
266
266
  };
267
267
  const type = {
268
- file: getFile(operation, { pluginKey: [__kubb_plugin_ts.pluginTsName] }),
268
+ file: getFile(operation, { pluginKey: [_kubb_plugin_ts.pluginTsName] }),
269
269
  schemas: getSchemas(operation, {
270
- pluginKey: [__kubb_plugin_ts.pluginTsName],
270
+ pluginKey: [_kubb_plugin_ts.pluginTsName],
271
271
  type: "type"
272
272
  })
273
273
  };
274
274
  const zod = {
275
- file: getFile(operation, { pluginKey: [__kubb_plugin_zod.pluginZodName] }),
275
+ file: getFile(operation, { pluginKey: [_kubb_plugin_zod.pluginZodName] }),
276
276
  schemas: getSchemas(operation, {
277
- pluginKey: [__kubb_plugin_zod.pluginZodName],
277
+ pluginKey: [_kubb_plugin_zod.pluginZodName],
278
278
  type: "function"
279
279
  })
280
280
  };
281
281
  if (!isQuery || isMutation) return null;
282
- return /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric.File, {
282
+ return /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric.File, {
283
283
  baseName: query.file.baseName,
284
284
  path: query.file.path,
285
285
  meta: query.file.meta,
286
- banner: (0, __kubb_plugin_oas_utils.getBanner)({
286
+ banner: (0, _kubb_plugin_oas_utils.getBanner)({
287
287
  oas,
288
288
  output,
289
289
  config: pluginManager.config
290
290
  }),
291
- footer: (0, __kubb_plugin_oas_utils.getFooter)({
291
+ footer: (0, _kubb_plugin_oas_utils.getFooter)({
292
292
  oas,
293
293
  output
294
294
  }),
295
295
  children: [
296
- options.parser === "zod" && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
296
+ options.parser === "zod" && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
297
297
  name: [zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean),
298
298
  root: query.file.path,
299
299
  path: zod.file.path
300
300
  }),
301
- options.client.importPath ? /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric_jsx_runtime.Fragment, { children: [
302
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
301
+ options.client.importPath ? /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric_jsx_runtime.Fragment, { children: [
302
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
303
303
  name: "fetch",
304
304
  path: options.client.importPath
305
305
  }),
306
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
306
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
307
307
  name: ["RequestConfig", "ResponseErrorConfig"],
308
308
  path: options.client.importPath,
309
309
  isTypeOnly: true
310
310
  }),
311
- options.client.dataReturnType === "full" && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
311
+ options.client.dataReturnType === "full" && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
312
312
  name: ["ResponseConfig"],
313
313
  path: options.client.importPath,
314
314
  isTypeOnly: true
315
315
  })
316
- ] }) : /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric_jsx_runtime.Fragment, { children: [
317
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
316
+ ] }) : /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric_jsx_runtime.Fragment, { children: [
317
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
318
318
  name: ["fetch"],
319
319
  root: query.file.path,
320
320
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/fetch.ts")
321
321
  }),
322
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
322
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
323
323
  name: ["RequestConfig", "ResponseErrorConfig"],
324
324
  root: query.file.path,
325
325
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/fetch.ts"),
326
326
  isTypeOnly: true
327
327
  }),
328
- options.client.dataReturnType === "full" && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
328
+ options.client.dataReturnType === "full" && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
329
329
  name: ["ResponseConfig"],
330
330
  root: query.file.path,
331
331
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/fetch.ts"),
332
332
  isTypeOnly: true
333
333
  })
334
334
  ] }),
335
- shouldUseClientPlugin && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
335
+ shouldUseClientPlugin && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
336
336
  name: [client.name],
337
337
  root: query.file.path,
338
338
  path: client.file.path
339
339
  }),
340
- !shouldUseClientPlugin && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
340
+ !shouldUseClientPlugin && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
341
341
  name: ["buildFormData"],
342
342
  root: query.file.path,
343
343
  path: node_path.default.resolve(config.root, config.output.path, ".kubb/config.ts")
344
344
  }),
345
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
345
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
346
346
  name: [
347
347
  type.schemas.request?.name,
348
348
  type.schemas.response.name,
@@ -355,7 +355,7 @@ const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
355
355
  path: type.file.path,
356
356
  isTypeOnly: true
357
357
  }),
358
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(require_components.QueryKey, {
358
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(require_components.QueryKey, {
359
359
  name: queryKey.name,
360
360
  typeName: queryKey.typeName,
361
361
  operation,
@@ -364,7 +364,7 @@ const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
364
364
  typeSchemas: type.schemas,
365
365
  transformer: options.queryKey
366
366
  }),
367
- !shouldUseClientPlugin && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_plugin_client_components.Client, {
367
+ !shouldUseClientPlugin && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_plugin_client_components.Client, {
368
368
  name: client.name,
369
369
  baseURL: options.client.baseURL,
370
370
  operation,
@@ -376,11 +376,11 @@ const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
376
376
  pathParamsType: options.pathParamsType,
377
377
  parser: options.parser
378
378
  }),
379
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
379
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
380
380
  name: ["queryOptions"],
381
381
  path: importPath
382
382
  }),
383
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(require_components.QueryOptions, {
383
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(require_components.QueryOptions, {
384
384
  name: queryOptions.name,
385
385
  clientName: client.name,
386
386
  queryKeyName: queryKey.name,
@@ -390,12 +390,12 @@ const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
390
390
  pathParamsType: options.pathParamsType,
391
391
  dataReturnType: options.client.dataReturnType || "data"
392
392
  }),
393
- options.query && /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsxs)(__kubb_react_fabric_jsx_runtime.Fragment, { children: [
394
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
393
+ options.query && /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsxs)(_kubb_react_fabric_jsx_runtime.Fragment, { children: [
394
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
395
395
  name: ["useQuery"],
396
396
  path: importPath
397
397
  }),
398
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(__kubb_react_fabric.File.Import, {
398
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(_kubb_react_fabric.File.Import, {
399
399
  name: [
400
400
  "QueryKey",
401
401
  "QueryClient",
@@ -405,7 +405,7 @@ const queryGenerator = (0, __kubb_plugin_oas_generators.createReactGenerator)({
405
405
  path: importPath,
406
406
  isTypeOnly: true
407
407
  }),
408
- /* @__PURE__ */ (0, __kubb_react_fabric_jsx_runtime.jsx)(require_components.Query, {
408
+ /* @__PURE__ */ (0, _kubb_react_fabric_jsx_runtime.jsx)(require_components.Query, {
409
409
  name: query.name,
410
410
  queryOptionsName: queryOptions.name,
411
411
  typeSchemas: type.schemas,
@@ -442,4 +442,4 @@ Object.defineProperty(exports, 'queryGenerator', {
442
442
  return queryGenerator;
443
443
  }
444
444
  });
445
- //# sourceMappingURL=generators-CftpFL3x.cjs.map
445
+ //# sourceMappingURL=generators-D7P06gQr.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"generators-CftpFL3x.cjs","names":["pluginTsName","pluginZodName","pluginClientName","File","path","MutationKey","Client","Mutation","pluginClientName","pluginTsName","pluginZodName","File","path","QueryKey","Client","QueryOptions","Query"],"sources":["../src/generators/mutationGenerator.tsx","../src/generators/queryGenerator.tsx"],"sourcesContent":["import path from 'node:path'\nimport { usePluginManager } from '@kubb/core/hooks'\nimport { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas/generators'\nimport { useOas, useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { getBanner, getFooter } from '@kubb/plugin-oas/utils'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File } from '@kubb/react-fabric'\nimport { difference } from 'remeda'\nimport { Mutation, MutationKey } from '../components'\nimport type { PluginSolidQuery } from '../types'\n\nexport const mutationGenerator = createReactGenerator<PluginSolidQuery>({\n name: 'solid-query',\n Operation({ config, operation, generator, plugin }) {\n const {\n options,\n options: { output },\n } = plugin\n const pluginManager = usePluginManager()\n\n const oas = useOas()\n const { getSchemas, getName, getFile } = useOperationManager(generator)\n\n const isQuery = !!options.query && options.query?.methods.some((method) => operation.method === method)\n const isMutation =\n options.mutation !== false &&\n !isQuery &&\n difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some((method) => operation.method === method)\n\n const importPath = options.mutation ? options.mutation.importPath : '@tanstack/solid-query'\n\n const mutation = {\n name: getName(operation, { type: 'function', prefix: 'use' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, { pluginKey: [pluginTsName], type: 'type' }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, { pluginKey: [pluginZodName], type: 'function' }),\n }\n\n const hasClientPlugin = !!pluginManager.getPluginByKey([pluginClientName])\n // Class-based clients are not compatible with query hooks, so we generate inline clients\n const shouldUseClientPlugin = hasClientPlugin && options.client.clientType !== 'class'\n const client = {\n name: shouldUseClientPlugin\n ? getName(operation, {\n type: 'function',\n pluginKey: [pluginClientName],\n })\n : getName(operation, {\n type: 'function',\n }),\n file: getFile(operation, { pluginKey: [pluginClientName] }),\n }\n\n const mutationKey = {\n name: getName(operation, { type: 'const', suffix: 'MutationKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'MutationKey' }),\n }\n\n if (!isMutation) {\n return null\n }\n\n return (\n <File\n baseName={mutation.file.baseName}\n path={mutation.file.path}\n meta={mutation.file.meta}\n banner={getBanner({ oas, output, config: pluginManager.config })}\n footer={getFooter({ oas, output })}\n >\n {options.parser === 'zod' && (\n <File.Import name={[zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean)} root={mutation.file.path} path={zod.file.path} />\n )}\n {options.client.importPath ? (\n <>\n <File.Import name={'fetch'} path={options.client.importPath} />\n <File.Import name={['RequestConfig', 'ResponseErrorConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n </>\n ) : (\n <>\n <File.Import name={['fetch']} root={mutation.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} />\n <File.Import\n name={['RequestConfig', 'ResponseErrorConfig']}\n root={mutation.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n {options.client.dataReturnType === 'full' && (\n <File.Import\n name={['ResponseConfig']}\n root={mutation.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n )}\n </>\n )}\n {shouldUseClientPlugin && <File.Import name={[client.name]} root={mutation.file.path} path={client.file.path} />}\n {!shouldUseClientPlugin && (\n <File.Import name={['buildFormData']} root={mutation.file.path} path={path.resolve(config.root, config.output.path, '.kubb/config.ts')} />\n )}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={mutation.file.path}\n path={type.file.path}\n isTypeOnly\n />\n\n <MutationKey\n name={mutationKey.name}\n typeName={mutationKey.typeName}\n operation={operation}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n transformer={options.mutationKey}\n />\n\n {!shouldUseClientPlugin && (\n <Client\n name={client.name}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n )}\n {options.mutation && (\n <>\n <File.Import name={['useMutation']} path={importPath} />\n <File.Import name={['UseMutationOptions', 'QueryClient']} path={importPath} isTypeOnly />\n <Mutation\n name={mutation.name}\n clientName={client.name}\n typeName={mutation.typeName}\n typeSchemas={type.schemas}\n operation={operation}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n mutationKeyName={mutationKey.name}\n />\n </>\n )}\n </File>\n )\n },\n})\n","import path from 'node:path'\nimport { usePluginManager } from '@kubb/core/hooks'\nimport { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas/generators'\nimport { useOas, useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { getBanner, getFooter } from '@kubb/plugin-oas/utils'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File } from '@kubb/react-fabric'\nimport { difference } from 'remeda'\nimport { Query, QueryKey, QueryOptions } from '../components'\nimport type { PluginSolidQuery } from '../types'\n\nexport const queryGenerator = createReactGenerator<PluginSolidQuery>({\n name: 'solid-query',\n Operation({ config, operation, generator, plugin }) {\n const {\n options,\n options: { output },\n } = plugin\n const pluginManager = usePluginManager()\n\n const oas = useOas()\n const { getSchemas, getName, getFile } = useOperationManager(generator)\n\n const isQuery = typeof options.query === 'boolean' ? true : options.query?.methods.some((method) => operation.method === method)\n const isMutation = difference(['post', 'put', 'delete', 'patch'], options.query ? options.query.methods : []).some((method) => operation.method === method)\n const importPath = options.query ? options.query.importPath : '@tanstack/solid-query'\n\n const query = {\n name: getName(operation, { type: 'function', prefix: 'create' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'create' }),\n }\n\n const hasClientPlugin = !!pluginManager.getPluginByKey([pluginClientName])\n // Class-based clients are not compatible with query hooks, so we generate inline clients\n const shouldUseClientPlugin = hasClientPlugin && options.client.clientType !== 'class'\n const client = {\n name: shouldUseClientPlugin\n ? getName(operation, {\n type: 'function',\n pluginKey: [pluginClientName],\n })\n : getName(operation, {\n type: 'function',\n }),\n file: getFile(operation, { pluginKey: [pluginClientName] }),\n }\n\n const queryOptions = {\n name: getName(operation, { type: 'function', suffix: 'QueryOptions' }),\n }\n\n const queryKey = {\n name: getName(operation, { type: 'const', suffix: 'QueryKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'QueryKey' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, {\n pluginKey: [pluginTsName],\n type: 'type',\n }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, {\n pluginKey: [pluginZodName],\n type: 'function',\n }),\n }\n\n if (!isQuery || isMutation) {\n return null\n }\n\n return (\n <File\n baseName={query.file.baseName}\n path={query.file.path}\n meta={query.file.meta}\n banner={getBanner({ oas, output, config: pluginManager.config })}\n footer={getFooter({ oas, output })}\n >\n {options.parser === 'zod' && (\n <File.Import name={[zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean)} root={query.file.path} path={zod.file.path} />\n )}\n {options.client.importPath ? (\n <>\n <File.Import name={'fetch'} path={options.client.importPath} />\n <File.Import name={['RequestConfig', 'ResponseErrorConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n </>\n ) : (\n <>\n <File.Import name={['fetch']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} />\n <File.Import\n name={['RequestConfig', 'ResponseErrorConfig']}\n root={query.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n {options.client.dataReturnType === 'full' && (\n <File.Import name={['ResponseConfig']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} isTypeOnly />\n )}\n </>\n )}\n {shouldUseClientPlugin && <File.Import name={[client.name]} root={query.file.path} path={client.file.path} />}\n {!shouldUseClientPlugin && (\n <File.Import name={['buildFormData']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/config.ts')} />\n )}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={query.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <QueryKey\n name={queryKey.name}\n typeName={queryKey.typeName}\n operation={operation}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n transformer={options.queryKey}\n />\n {!shouldUseClientPlugin && (\n <Client\n name={client.name}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n )}\n <File.Import name={['queryOptions']} path={importPath} />\n <QueryOptions\n name={queryOptions.name}\n clientName={client.name}\n queryKeyName={queryKey.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n dataReturnType={options.client.dataReturnType || 'data'}\n />\n {options.query && (\n <>\n <File.Import name={['useQuery']} path={importPath} />\n <File.Import name={['QueryKey', 'QueryClient', 'UseBaseQueryOptions', 'UseQueryResult']} path={importPath} isTypeOnly />\n <Query\n name={query.name}\n queryOptionsName={queryOptions.name}\n typeSchemas={type.schemas}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n operation={operation}\n paramsCasing={options.paramsCasing}\n dataReturnType={options.client.dataReturnType || 'data'}\n queryKeyName={queryKey.name}\n queryKeyTypeName={queryKey.typeName}\n />\n </>\n )}\n </File>\n )\n },\n})\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAcA,MAAa,2EAA2D;CACtE,MAAM;CACN,UAAU,EAAE,QAAQ,WAAW,WAAW,UAAU;EAClD,MAAM,EACJ,SACA,SAAS,EAAE,aACT;EACJ,MAAM,yDAAkC;EAExC,MAAM,2CAAc;EACpB,MAAM,EAAE,YAAY,SAAS,6DAAgC,UAAU;EAEvE,MAAM,UAAU,CAAC,CAAC,QAAQ,SAAS,QAAQ,OAAO,QAAQ,MAA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BAAgB,QAAQ;KACxB,QAAQ,QAAQ;MAChB;IAEJ,yDAACH,yBAAK;KAAO,MAAM,CAAC,eAAe;KAAE,MAAM;MAAc;IACzD,yDAACI;KACC,MAAM,aAAa;KACnB,YAAY,OAAO;KACnB,cAAc,SAAS;KACvB,aAAa,KAAK;KAClB,cAAc,QAAQ;KACtB,YAAY,QAAQ;KACpB,gBAAgB,QAAQ;KACxB,gBAAgB,QAAQ,OAAO,kBAAkB;MACjD;IACD,QAAQ,SACP;KACE,yDAACJ,yBAAK;MAAO,MAAM,CAAC,WAAW;MAAE,MAAM;OAAc;KACrD,yDAACA,yBAAK;MAAO,MAAM;OAAC;OAAY;OAAe;OAAuB;OAAiB;MAAE,MAAM;MAAY;OAAa;KACxH,yDAACK;MACC,MAAM,MAAM;MACZ,kBAAkB,aAAa;MAC/B,aAAa,KAAK;MAClB,YAAY,QAAQ;MACpB,gBAAgB,QAAQ;MACb;MACX,cAAc,QAAQ;MACtB,gBAAgB,QAAQ,OAAO,kBAAkB;MACjD,cAAc,SAAS;MACvB,kBAAkB,SAAS;OAC3B;QACD;;IAEA;;CAGZ,CAAC"}
1
+ {"version":3,"file":"generators-D7P06gQr.cjs","names":["pluginTsName","pluginZodName","pluginClientName","File","path","MutationKey","Client","Mutation","pluginClientName","pluginTsName","pluginZodName","File","path","QueryKey","Client","QueryOptions","Query"],"sources":["../src/generators/mutationGenerator.tsx","../src/generators/queryGenerator.tsx"],"sourcesContent":["import path from 'node:path'\nimport { usePluginManager } from '@kubb/core/hooks'\nimport { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas/generators'\nimport { useOas, useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { getBanner, getFooter } from '@kubb/plugin-oas/utils'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File } from '@kubb/react-fabric'\nimport { difference } from 'remeda'\nimport { Mutation, MutationKey } from '../components'\nimport type { PluginSolidQuery } from '../types'\n\nexport const mutationGenerator = createReactGenerator<PluginSolidQuery>({\n name: 'solid-query',\n Operation({ config, operation, generator, plugin }) {\n const {\n options,\n options: { output },\n } = plugin\n const pluginManager = usePluginManager()\n\n const oas = useOas()\n const { getSchemas, getName, getFile } = useOperationManager(generator)\n\n const isQuery = !!options.query && options.query?.methods.some((method) => operation.method === method)\n const isMutation =\n options.mutation !== false &&\n !isQuery &&\n difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some((method) => operation.method === method)\n\n const importPath = options.mutation ? options.mutation.importPath : '@tanstack/solid-query'\n\n const mutation = {\n name: getName(operation, { type: 'function', prefix: 'use' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, { pluginKey: [pluginTsName], type: 'type' }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, { pluginKey: [pluginZodName], type: 'function' }),\n }\n\n const hasClientPlugin = !!pluginManager.getPluginByKey([pluginClientName])\n // Class-based clients are not compatible with query hooks, so we generate inline clients\n const shouldUseClientPlugin = hasClientPlugin && options.client.clientType !== 'class'\n const client = {\n name: shouldUseClientPlugin\n ? getName(operation, {\n type: 'function',\n pluginKey: [pluginClientName],\n })\n : getName(operation, {\n type: 'function',\n }),\n file: getFile(operation, { pluginKey: [pluginClientName] }),\n }\n\n const mutationKey = {\n name: getName(operation, { type: 'const', suffix: 'MutationKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'MutationKey' }),\n }\n\n if (!isMutation) {\n return null\n }\n\n return (\n <File\n baseName={mutation.file.baseName}\n path={mutation.file.path}\n meta={mutation.file.meta}\n banner={getBanner({ oas, output, config: pluginManager.config })}\n footer={getFooter({ oas, output })}\n >\n {options.parser === 'zod' && (\n <File.Import name={[zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean)} root={mutation.file.path} path={zod.file.path} />\n )}\n {options.client.importPath ? (\n <>\n <File.Import name={'fetch'} path={options.client.importPath} />\n <File.Import name={['RequestConfig', 'ResponseErrorConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n </>\n ) : (\n <>\n <File.Import name={['fetch']} root={mutation.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} />\n <File.Import\n name={['RequestConfig', 'ResponseErrorConfig']}\n root={mutation.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n {options.client.dataReturnType === 'full' && (\n <File.Import\n name={['ResponseConfig']}\n root={mutation.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n )}\n </>\n )}\n {shouldUseClientPlugin && <File.Import name={[client.name]} root={mutation.file.path} path={client.file.path} />}\n {!shouldUseClientPlugin && (\n <File.Import name={['buildFormData']} root={mutation.file.path} path={path.resolve(config.root, config.output.path, '.kubb/config.ts')} />\n )}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={mutation.file.path}\n path={type.file.path}\n isTypeOnly\n />\n\n <MutationKey\n name={mutationKey.name}\n typeName={mutationKey.typeName}\n operation={operation}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n transformer={options.mutationKey}\n />\n\n {!shouldUseClientPlugin && (\n <Client\n name={client.name}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n )}\n {options.mutation && (\n <>\n <File.Import name={['useMutation']} path={importPath} />\n <File.Import name={['UseMutationOptions', 'QueryClient']} path={importPath} isTypeOnly />\n <Mutation\n name={mutation.name}\n clientName={client.name}\n typeName={mutation.typeName}\n typeSchemas={type.schemas}\n operation={operation}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n mutationKeyName={mutationKey.name}\n />\n </>\n )}\n </File>\n )\n },\n})\n","import path from 'node:path'\nimport { usePluginManager } from '@kubb/core/hooks'\nimport { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas/generators'\nimport { useOas, useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { getBanner, getFooter } from '@kubb/plugin-oas/utils'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File } from '@kubb/react-fabric'\nimport { difference } from 'remeda'\nimport { Query, QueryKey, QueryOptions } from '../components'\nimport type { PluginSolidQuery } from '../types'\n\nexport const queryGenerator = createReactGenerator<PluginSolidQuery>({\n name: 'solid-query',\n Operation({ config, operation, generator, plugin }) {\n const {\n options,\n options: { output },\n } = plugin\n const pluginManager = usePluginManager()\n\n const oas = useOas()\n const { getSchemas, getName, getFile } = useOperationManager(generator)\n\n const isQuery = typeof options.query === 'boolean' ? true : options.query?.methods.some((method) => operation.method === method)\n const isMutation = difference(['post', 'put', 'delete', 'patch'], options.query ? options.query.methods : []).some((method) => operation.method === method)\n const importPath = options.query ? options.query.importPath : '@tanstack/solid-query'\n\n const query = {\n name: getName(operation, { type: 'function', prefix: 'create' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'create' }),\n }\n\n const hasClientPlugin = !!pluginManager.getPluginByKey([pluginClientName])\n // Class-based clients are not compatible with query hooks, so we generate inline clients\n const shouldUseClientPlugin = hasClientPlugin && options.client.clientType !== 'class'\n const client = {\n name: shouldUseClientPlugin\n ? getName(operation, {\n type: 'function',\n pluginKey: [pluginClientName],\n })\n : getName(operation, {\n type: 'function',\n }),\n file: getFile(operation, { pluginKey: [pluginClientName] }),\n }\n\n const queryOptions = {\n name: getName(operation, { type: 'function', suffix: 'QueryOptions' }),\n }\n\n const queryKey = {\n name: getName(operation, { type: 'const', suffix: 'QueryKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'QueryKey' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, {\n pluginKey: [pluginTsName],\n type: 'type',\n }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, {\n pluginKey: [pluginZodName],\n type: 'function',\n }),\n }\n\n if (!isQuery || isMutation) {\n return null\n }\n\n return (\n <File\n baseName={query.file.baseName}\n path={query.file.path}\n meta={query.file.meta}\n banner={getBanner({ oas, output, config: pluginManager.config })}\n footer={getFooter({ oas, output })}\n >\n {options.parser === 'zod' && (\n <File.Import name={[zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean)} root={query.file.path} path={zod.file.path} />\n )}\n {options.client.importPath ? (\n <>\n <File.Import name={'fetch'} path={options.client.importPath} />\n <File.Import name={['RequestConfig', 'ResponseErrorConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n </>\n ) : (\n <>\n <File.Import name={['fetch']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} />\n <File.Import\n name={['RequestConfig', 'ResponseErrorConfig']}\n root={query.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n {options.client.dataReturnType === 'full' && (\n <File.Import name={['ResponseConfig']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} isTypeOnly />\n )}\n </>\n )}\n {shouldUseClientPlugin && <File.Import name={[client.name]} root={query.file.path} path={client.file.path} />}\n {!shouldUseClientPlugin && (\n <File.Import name={['buildFormData']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/config.ts')} />\n )}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={query.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <QueryKey\n name={queryKey.name}\n typeName={queryKey.typeName}\n operation={operation}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n transformer={options.queryKey}\n />\n {!shouldUseClientPlugin && (\n <Client\n name={client.name}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n )}\n <File.Import name={['queryOptions']} path={importPath} />\n <QueryOptions\n name={queryOptions.name}\n clientName={client.name}\n queryKeyName={queryKey.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n dataReturnType={options.client.dataReturnType || 'data'}\n />\n {options.query && (\n <>\n <File.Import name={['useQuery']} path={importPath} />\n <File.Import name={['QueryKey', 'QueryClient', 'UseBaseQueryOptions', 'UseQueryResult']} path={importPath} isTypeOnly />\n <Query\n name={query.name}\n queryOptionsName={queryOptions.name}\n typeSchemas={type.schemas}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n operation={operation}\n paramsCasing={options.paramsCasing}\n dataReturnType={options.client.dataReturnType || 'data'}\n queryKeyName={queryKey.name}\n queryKeyTypeName={queryKey.typeName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KAAK;KACjB,MAAM,KAAK,KAAK;KAChB;MACA;IACF,wDAACE;KACC,MAAM,SAAS;KACf,UAAU,SAAS;KACR;KACX,cAAc,QAAQ;KACtB,gBAAgB,QAAQ;KACxB,aAAa,KAAK;KAClB,aAAa,QAAQ;MACrB;IACD,CAAC,yBACA,wDAACC;KACC,MAAM,OAAO;KACb,SAAS,QAAQ,OAAO;KACb;KACX,aAAa,KAAK;KAClB,YAAY,IAAI;KAChB,gBAAgB,QAAQ,OAAO,kBAAkB;KACjD,cAAc,QAAQ;KACtB,YAAY,QAAQ;KACpB,gBAAgB,QAAQ;KACxB,QAAQ,QAAQ;MAChB;IAEJ,wDAACH,wBAAK;KAAO,MAAM,CAAC,eAAe;KAAE,MAAM;MAAc;IACzD,wDAACI;KACC,MAAM,aAAa;KACnB,YAAY,OAAO;KACnB,cAAc,SAAS;KACvB,aAAa,KAAK;KAClB,cAAc,QAAQ;KACtB,YAAY,QAAQ;KACpB,gBAAgB,QAAQ;KACxB,gBAAgB,QAAQ,OAAO,kBAAkB;MACjD;IACD,QAAQ,SACP;KACE,wDAACJ,wBAAK;MAAO,MAAM,CAAC,WAAW;MAAE,MAAM;OAAc;KACrD,wDAACA,wBAAK;MAAO,MAAM;OAAC;OAAY;OAAe;OAAuB;OAAiB;MAAE,MAAM;MAAY;OAAa;KACxH,wDAACK;MACC,MAAM,MAAM;MACZ,kBAAkB,aAAa;MAC/B,aAAa,KAAK;MAClB,YAAY,QAAQ;MACpB,gBAAgB,QAAQ;MACb;MACX,cAAc,QAAQ;MACtB,gBAAgB,QAAQ,OAAO,kBAAkB;MACjD,cAAc,SAAS;MACvB,kBAAkB,SAAS;OAC3B;QACD;;IAEA;;CAGZ,CAAC"}
@@ -1,4 +1,4 @@
1
- const require_generators = require('./generators-CftpFL3x.cjs');
1
+ const require_generators = require('./generators-D7P06gQr.cjs');
2
2
 
3
3
  exports.mutationGenerator = require_generators.mutationGenerator;
4
4
  exports.queryGenerator = require_generators.queryGenerator;