@kubb/plugin-ts 3.0.0-alpha.11 → 3.0.0-alpha.12

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.
@@ -2544,9 +2544,9 @@ var SchemaGenerator2 = class extends pluginOas.SchemaGenerator {
2544
2544
  logger: pluginManager.logger
2545
2545
  });
2546
2546
  const tree = this.parse({ schema, name });
2547
- root.render(
2548
- /* @__PURE__ */ jsxRuntime.jsx(react.App, { pluginManager, plugin: { ...plugin, options }, mode, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas, { oas, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas.Schema, { name, value: schema, tree, children: /* @__PURE__ */ jsxRuntime.jsx(Schema.File, {}) }) }) })
2549
- );
2547
+ const Component = () => /* @__PURE__ */ jsxRuntime.jsx(react.App, { pluginManager, plugin: { ...plugin, options }, mode, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas, { oas, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas.Schema, { name, value: schema, tree, children: /* @__PURE__ */ jsxRuntime.jsx(Schema.File, {}) }) }) });
2548
+ Component.displayName = transformers2.pascalCase(name);
2549
+ root.render(/* @__PURE__ */ jsxRuntime.jsx(Component, {}));
2550
2550
  return root.files;
2551
2551
  }
2552
2552
  };
@@ -2665,9 +2665,9 @@ var OperationGenerator = class extends pluginOas.OperationGenerator {
2665
2665
  const root = react.createRoot({
2666
2666
  logger: pluginManager.logger
2667
2667
  });
2668
- root.render(
2669
- /* @__PURE__ */ jsxRuntime.jsx(react.App, { pluginManager, plugin, mode, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas, { oas, operations, generator: this, children: plugin.options.oasType && /* @__PURE__ */ jsxRuntime.jsx(OasType.File, { name: "oas", typeName: "Oas" }) }) })
2670
- );
2668
+ const Component = () => /* @__PURE__ */ jsxRuntime.jsx(react.App, { pluginManager, plugin, mode, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas, { oas, operations, generator: this, children: plugin.options.oasType && /* @__PURE__ */ jsxRuntime.jsx(OasType.File, { name: "oas", typeName: "Oas" }) }) });
2669
+ Component.displayName = transformers2.pascalCase("operations");
2670
+ root.render(/* @__PURE__ */ jsxRuntime.jsx(Component, {}));
2671
2671
  return root.files;
2672
2672
  }
2673
2673
  async operation(operation, options) {
@@ -2675,9 +2675,9 @@ var OperationGenerator = class extends pluginOas.OperationGenerator {
2675
2675
  const root = react.createRoot({
2676
2676
  logger: pluginManager.logger
2677
2677
  });
2678
- root.render(
2679
- /* @__PURE__ */ jsxRuntime.jsx(react.App, { pluginManager, plugin: { ...plugin, options }, mode, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas, { oas, operations: [operation], generator: this, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas.Operation, { operation, children: /* @__PURE__ */ jsxRuntime.jsx(OperationSchema.File, {}) }) }) })
2680
- );
2678
+ const Component = () => /* @__PURE__ */ jsxRuntime.jsx(react.App, { pluginManager, plugin: { ...plugin, options }, mode, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas, { oas, operations: [operation], generator: this, children: /* @__PURE__ */ jsxRuntime.jsx(components.Oas.Operation, { operation, children: /* @__PURE__ */ jsxRuntime.jsx(OperationSchema.File, {}) }) }) });
2679
+ Component.displayName = transformers2.pascalCase(operation.getOperationId());
2680
+ root.render(/* @__PURE__ */ jsxRuntime.jsx(Component, {}));
2681
2681
  return root.files;
2682
2682
  }
2683
2683
  };
@@ -2815,5 +2815,5 @@ exports.OperationSchema = OperationSchema;
2815
2815
  exports.Schema = Schema;
2816
2816
  exports.pluginTs = pluginTs;
2817
2817
  exports.pluginTsName = pluginTsName;
2818
- //# sourceMappingURL=chunk-ZGKAXNFT.cjs.map
2819
- //# sourceMappingURL=chunk-ZGKAXNFT.cjs.map
2818
+ //# sourceMappingURL=chunk-YQK6XG55.cjs.map
2819
+ //# sourceMappingURL=chunk-YQK6XG55.cjs.map