@kubb/react-fabric 0.13.3 → 0.14.0

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.
Files changed (52) hide show
  1. package/README.md +2 -2
  2. package/dist/{chunk-DbZtQ4qb.js → chunk-BGCRLu6H.js} +12 -21
  3. package/dist/globals.d.ts +2 -2
  4. package/dist/globals.js +1 -1
  5. package/dist/index.cjs +79 -89
  6. package/dist/index.cjs.map +1 -1
  7. package/dist/index.d.ts +27 -28
  8. package/dist/index.js +27 -35
  9. package/dist/index.js.map +1 -1
  10. package/dist/jsx-dev-runtime.cjs +6 -245
  11. package/dist/jsx-dev-runtime.cjs.map +1 -1
  12. package/dist/jsx-dev-runtime.d.ts +5 -5
  13. package/dist/jsx-dev-runtime.js +6 -245
  14. package/dist/jsx-dev-runtime.js.map +1 -1
  15. package/dist/{jsx-namespace-Bg7Kfg54.d.ts → jsx-namespace-C9N4PA8a.d.ts} +3 -3
  16. package/dist/{react-B4mAwc8c.cjs → jsx-runtime-Bl0DfUmV.js} +262 -61
  17. package/dist/jsx-runtime-Bl0DfUmV.js.map +1 -0
  18. package/dist/{react-C2cYsofv.js → jsx-runtime-Cua1md-Z.cjs} +317 -7
  19. package/dist/jsx-runtime-Cua1md-Z.cjs.map +1 -0
  20. package/dist/jsx-runtime.cjs +4 -6
  21. package/dist/jsx-runtime.cjs.map +1 -1
  22. package/dist/jsx-runtime.d.ts +3 -3
  23. package/dist/jsx-runtime.js +3 -5
  24. package/dist/jsx-runtime.js.map +1 -1
  25. package/dist/parsers.cjs +7 -7
  26. package/dist/parsers.js +2 -3
  27. package/dist/plugins.cjs +10 -10
  28. package/dist/plugins.d.ts +1 -1
  29. package/dist/plugins.js +4 -7
  30. package/dist/{reactPlugin-OUKiWH1q.d.ts → reactPlugin-CKiGUCKQ.d.ts} +11 -11
  31. package/dist/{reactPlugin-BshFnF2Y.cjs → reactPlugin-D74A1eG4.cjs} +50 -65
  32. package/dist/{reactPlugin-BshFnF2Y.cjs.map → reactPlugin-D74A1eG4.cjs.map} +1 -1
  33. package/dist/{reactPlugin-DGKBWjiR.js → reactPlugin-QQPrjNuQ.js} +13 -28
  34. package/dist/{reactPlugin-DGKBWjiR.js.map → reactPlugin-QQPrjNuQ.js.map} +1 -1
  35. package/dist/types-BJVZ7ita.d.ts +104 -0
  36. package/dist/types.cjs +7 -7
  37. package/dist/types.d.ts +2 -62
  38. package/dist/types.js +2 -3
  39. package/package.json +7 -2
  40. package/src/components/{App.tsx → Fabric.tsx} +6 -6
  41. package/src/composables/useFabric.ts +1 -0
  42. package/src/index.ts +2 -3
  43. package/src/jsx-dev-runtime.ts +2 -2
  44. package/src/plugins/reactPlugin.ts +8 -8
  45. package/dist/getFunctionParams-CINBJQGH.d.ts +0 -49
  46. package/dist/jsx-runtime-CZxrhUx8.js +0 -266
  47. package/dist/jsx-runtime-CZxrhUx8.js.map +0 -1
  48. package/dist/jsx-runtime-C_GM3QQI.cjs +0 -270
  49. package/dist/jsx-runtime-C_GM3QQI.cjs.map +0 -1
  50. package/dist/react-B4mAwc8c.cjs.map +0 -1
  51. package/dist/react-C2cYsofv.js.map +0 -1
  52. package/src/composables/useApp.ts +0 -1
@@ -1,13 +1,12 @@
1
- const require_react$1 = require('./react-B4mAwc8c.cjs');
2
- const require_jsx_runtime = require('./jsx-runtime.cjs');
1
+ const require_jsx_runtime = require("./jsx-runtime-Cua1md-Z.cjs");
2
+ const require_jsx_runtime$1 = require("./jsx-runtime.cjs");
3
3
  let _kubb_fabric_core = require("@kubb/fabric-core");
4
4
  let _kubb_fabric_core_plugins = require("@kubb/fabric-core/plugins");
5
5
  let node_process = require("node:process");
6
- node_process = require_react$1.__toESM(node_process);
6
+ node_process = require_jsx_runtime.__toESM(node_process);
7
7
  let _kubb_fabric_core_parsers_typescript = require("@kubb/fabric-core/parsers/typescript");
8
-
9
8
  //#region src/components/Root.tsx
10
- var import_react = /* @__PURE__ */ require_react$1.__toESM(require_react$1.require_react());
9
+ var import_react = /* @__PURE__ */ require_jsx_runtime.__toESM(require_jsx_runtime.require_react());
11
10
  var ErrorBoundary = class extends import_react.Component {
12
11
  state = { hasError: false };
13
12
  static displayName = "ErrorBoundary";
@@ -32,7 +31,7 @@ function Root({ onError, onExit, treeNode, fileManager, children }) {
32
31
  fileManager
33
32
  });
34
33
  (0, _kubb_fabric_core.provide)(_kubb_fabric_core.NodeTreeContext, treeNode);
35
- return /* @__PURE__ */ require_jsx_runtime.jsx(ErrorBoundary, {
34
+ return /* @__PURE__ */ require_jsx_runtime$1.jsx(ErrorBoundary, {
36
35
  onError: (error) => {
37
36
  onError(error);
38
37
  },
@@ -40,7 +39,6 @@ function Root({ onError, onExit, treeNode, fileManager, children }) {
40
39
  });
41
40
  }
42
41
  Root.displayName = "Root";
43
-
44
42
  //#endregion
45
43
  //#region ../../node_modules/.pnpm/scheduler@0.27.0/node_modules/scheduler/cjs/scheduler.production.js
46
44
  /**
@@ -52,7 +50,7 @@ Root.displayName = "Root";
52
50
  * This source code is licensed under the MIT license found in the
53
51
  * LICENSE file in the root directory of this source tree.
54
52
  */
55
- var require_scheduler_production = /* @__PURE__ */ require_react$1.__commonJSMin(((exports) => {
53
+ var require_scheduler_production = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports) => {
56
54
  function push(heap, node) {
57
55
  var index = heap.length;
58
56
  heap.push(node);
@@ -303,7 +301,6 @@ var require_scheduler_production = /* @__PURE__ */ require_react$1.__commonJSMin
303
301
  };
304
302
  };
305
303
  }));
306
-
307
304
  //#endregion
308
305
  //#region ../../node_modules/.pnpm/scheduler@0.27.0/node_modules/scheduler/cjs/scheduler.development.js
309
306
  /**
@@ -315,7 +312,7 @@ var require_scheduler_production = /* @__PURE__ */ require_react$1.__commonJSMin
315
312
  * This source code is licensed under the MIT license found in the
316
313
  * LICENSE file in the root directory of this source tree.
317
314
  */
318
- var require_scheduler_development = /* @__PURE__ */ require_react$1.__commonJSMin(((exports) => {
315
+ var require_scheduler_development = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports) => {
319
316
  "production" !== process.env.NODE_ENV && (function() {
320
317
  function performWorkUntilDeadline() {
321
318
  needsPaint = !1;
@@ -569,14 +566,12 @@ var require_scheduler_development = /* @__PURE__ */ require_react$1.__commonJSMi
569
566
  "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
570
567
  })();
571
568
  }));
572
-
573
569
  //#endregion
574
570
  //#region ../../node_modules/.pnpm/scheduler@0.27.0/node_modules/scheduler/index.js
575
- var require_scheduler = /* @__PURE__ */ require_react$1.__commonJSMin(((exports, module) => {
571
+ var require_scheduler = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports, module) => {
576
572
  if (process.env.NODE_ENV === "production") module.exports = require_scheduler_production();
577
573
  else module.exports = require_scheduler_development();
578
574
  }));
579
-
580
575
  //#endregion
581
576
  //#region ../../node_modules/.pnpm/react-reconciler@0.33.0_react@19.2.3/node_modules/react-reconciler/cjs/react-reconciler.production.js
582
577
  /**
@@ -588,7 +583,7 @@ var require_scheduler = /* @__PURE__ */ require_react$1.__commonJSMin(((exports,
588
583
  * This source code is licensed under the MIT license found in the
589
584
  * LICENSE file in the root directory of this source tree.
590
585
  */
591
- var require_react_reconciler_production = /* @__PURE__ */ require_react$1.__commonJSMin(((exports, module) => {
586
+ var require_react_reconciler_production = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports, module) => {
592
587
  module.exports = function($$$config) {
593
588
  function createFiber(tag, pendingProps, key, mode) {
594
589
  return new FiberNode(tag, pendingProps, key, mode);
@@ -6193,7 +6188,7 @@ var require_react_reconciler_production = /* @__PURE__ */ require_react$1.__comm
6193
6188
  (fiber = fiber.alternate) && markRetryLaneImpl(fiber, retryLane);
6194
6189
  }
6195
6190
  var exports$2 = {};
6196
- var React = require_react$1.require_react();
6191
+ var React = require_jsx_runtime.require_react();
6197
6192
  var Scheduler = require_scheduler();
6198
6193
  var assign = Object.assign;
6199
6194
  var REACT_LEGACY_ELEMENT_TYPE = Symbol.for("react.element");
@@ -7146,7 +7141,6 @@ var require_react_reconciler_production = /* @__PURE__ */ require_react$1.__comm
7146
7141
  module.exports.default = module.exports;
7147
7142
  Object.defineProperty(module.exports, "__esModule", { value: !0 });
7148
7143
  }));
7149
-
7150
7144
  //#endregion
7151
7145
  //#region ../../node_modules/.pnpm/react-reconciler@0.33.0_react@19.2.3/node_modules/react-reconciler/cjs/react-reconciler.development.js
7152
7146
  /**
@@ -7158,7 +7152,7 @@ var require_react_reconciler_production = /* @__PURE__ */ require_react$1.__comm
7158
7152
  * This source code is licensed under the MIT license found in the
7159
7153
  * LICENSE file in the root directory of this source tree.
7160
7154
  */
7161
- var require_react_reconciler_development = /* @__PURE__ */ require_react$1.__commonJSMin(((exports, module) => {
7155
+ var require_react_reconciler_development = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports, module) => {
7162
7156
  "production" !== process.env.NODE_ENV && (module.exports = function($$$config) {
7163
7157
  function findHook(fiber, id) {
7164
7158
  for (fiber = fiber.memoizedState; null !== fiber && 0 < id;) fiber = fiber.next, id--;
@@ -15024,7 +15018,7 @@ var require_react_reconciler_development = /* @__PURE__ */ require_react$1.__com
15024
15018
  return current;
15025
15019
  }
15026
15020
  var exports$1 = {};
15027
- var React = require_react$1.require_react();
15021
+ var React = require_jsx_runtime.require_react();
15028
15022
  var Scheduler = require_scheduler();
15029
15023
  var assign = Object.assign;
15030
15024
  var REACT_LEGACY_ELEMENT_TYPE = Symbol.for("react.element");
@@ -17246,14 +17240,12 @@ var require_react_reconciler_development = /* @__PURE__ */ require_react$1.__com
17246
17240
  return exports$1;
17247
17241
  }, module.exports.default = module.exports, Object.defineProperty(module.exports, "__esModule", { value: !0 }));
17248
17242
  }));
17249
-
17250
17243
  //#endregion
17251
17244
  //#region ../../node_modules/.pnpm/react-reconciler@0.33.0_react@19.2.3/node_modules/react-reconciler/index.js
17252
- var require_react_reconciler = /* @__PURE__ */ require_react$1.__commonJSMin(((exports, module) => {
17245
+ var require_react_reconciler = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports, module) => {
17253
17246
  if (process.env.NODE_ENV === "production") module.exports = require_react_reconciler_production();
17254
17247
  else module.exports = require_react_reconciler_development();
17255
17248
  }));
17256
-
17257
17249
  //#endregion
17258
17250
  //#region ../../node_modules/.pnpm/react-reconciler@0.33.0_react@19.2.3/node_modules/react-reconciler/cjs/react-reconciler-constants.production.js
17259
17251
  /**
@@ -17265,12 +17257,15 @@ var require_react_reconciler = /* @__PURE__ */ require_react$1.__commonJSMin(((e
17265
17257
  * This source code is licensed under the MIT license found in the
17266
17258
  * LICENSE file in the root directory of this source tree.
17267
17259
  */
17268
- var require_react_reconciler_constants_production = /* @__PURE__ */ require_react$1.__commonJSMin(((exports) => {
17260
+ var require_react_reconciler_constants_production = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports) => {
17269
17261
  exports.ConcurrentRoot = 1;
17262
+ exports.ContinuousEventPriority = 8;
17270
17263
  exports.DefaultEventPriority = 32;
17264
+ exports.DiscreteEventPriority = 2;
17265
+ exports.IdleEventPriority = 268435456;
17266
+ exports.LegacyRoot = 0;
17271
17267
  exports.NoEventPriority = 0;
17272
17268
  }));
17273
-
17274
17269
  //#endregion
17275
17270
  //#region ../../node_modules/.pnpm/react-reconciler@0.33.0_react@19.2.3/node_modules/react-reconciler/cjs/react-reconciler-constants.development.js
17276
17271
  /**
@@ -17282,17 +17277,15 @@ var require_react_reconciler_constants_production = /* @__PURE__ */ require_reac
17282
17277
  * This source code is licensed under the MIT license found in the
17283
17278
  * LICENSE file in the root directory of this source tree.
17284
17279
  */
17285
- var require_react_reconciler_constants_development = /* @__PURE__ */ require_react$1.__commonJSMin(((exports) => {
17280
+ var require_react_reconciler_constants_development = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports) => {
17286
17281
  "production" !== process.env.NODE_ENV && (exports.ConcurrentRoot = 1, exports.ContinuousEventPriority = 8, exports.DefaultEventPriority = 32, exports.DiscreteEventPriority = 2, exports.IdleEventPriority = 268435456, exports.LegacyRoot = 0, exports.NoEventPriority = 0);
17287
17282
  }));
17288
-
17289
17283
  //#endregion
17290
17284
  //#region ../../node_modules/.pnpm/react-reconciler@0.33.0_react@19.2.3/node_modules/react-reconciler/constants.js
17291
- var require_constants = /* @__PURE__ */ require_react$1.__commonJSMin(((exports, module) => {
17285
+ var require_constants = /* @__PURE__ */ require_jsx_runtime.__commonJSMin(((exports, module) => {
17292
17286
  if (process.env.NODE_ENV === "production") module.exports = require_react_reconciler_constants_production();
17293
17287
  else module.exports = require_react_reconciler_constants_development();
17294
17288
  }));
17295
-
17296
17289
  //#endregion
17297
17290
  //#region src/dom.ts
17298
17291
  const createNode = (nodeName) => {
@@ -17353,10 +17346,9 @@ const nodeNames = new Set([
17353
17346
  "indent",
17354
17347
  "dedent"
17355
17348
  ]);
17356
-
17357
17349
  //#endregion
17358
17350
  //#region src/Renderer.ts
17359
- var import_react_reconciler = /* @__PURE__ */ require_react$1.__toESM(require_react_reconciler(), 1);
17351
+ var import_react_reconciler = /* @__PURE__ */ require_jsx_runtime.__toESM(require_react_reconciler(), 1);
17360
17352
  var import_constants = require_constants();
17361
17353
  let currentUpdatePriority = import_constants.NoEventPriority;
17362
17354
  /**
@@ -17452,7 +17444,7 @@ const Renderer = (0, import_react_reconciler.default)({
17452
17444
  },
17453
17445
  getCurrentUpdatePriority: () => currentUpdatePriority,
17454
17446
  resolveUpdatePriority() {
17455
- if (currentUpdatePriority !== import_constants.NoEventPriority) return currentUpdatePriority;
17447
+ if (currentUpdatePriority !== 0) return currentUpdatePriority;
17456
17448
  return import_constants.DefaultEventPriority;
17457
17449
  },
17458
17450
  maySuspendCommit() {
@@ -17481,7 +17473,6 @@ const Renderer = (0, import_react_reconciler.default)({
17481
17473
  return null;
17482
17474
  }
17483
17475
  });
17484
-
17485
17476
  //#endregion
17486
17477
  //#region src/utils/squashExportNodes.ts
17487
17478
  function squashExportNodes(node) {
@@ -17501,7 +17492,6 @@ function squashExportNodes(node) {
17501
17492
  walk(node);
17502
17493
  return exports;
17503
17494
  }
17504
-
17505
17495
  //#endregion
17506
17496
  //#region src/utils/squashImportNodes.ts
17507
17497
  function squashImportNodes(node) {
@@ -17522,7 +17512,6 @@ function squashImportNodes(node) {
17522
17512
  walk(node);
17523
17513
  return imports;
17524
17514
  }
17525
-
17526
17515
  //#endregion
17527
17516
  //#region src/utils/squashTextNodes.ts
17528
17517
  function squashTextNodes(node, renderContext = {
@@ -17590,7 +17579,6 @@ function squashTextNodes(node, renderContext = {
17590
17579
  text = walk(node, renderContext);
17591
17580
  return text;
17592
17581
  }
17593
-
17594
17582
  //#endregion
17595
17583
  //#region src/utils/squashSourceNodes.ts
17596
17584
  function squashSourceNodes(node, ignores) {
@@ -17617,7 +17605,6 @@ function squashSourceNodes(node, ignores) {
17617
17605
  walk(node);
17618
17606
  return sources;
17619
17607
  }
17620
-
17621
17608
  //#endregion
17622
17609
  //#region src/utils/processFiles.ts
17623
17610
  async function processFiles(node) {
@@ -17646,7 +17633,6 @@ async function processFiles(node) {
17646
17633
  await walk(node);
17647
17634
  return collected;
17648
17635
  }
17649
-
17650
17636
  //#endregion
17651
17637
  //#region src/Runtime.tsx
17652
17638
  var Runtime = class {
@@ -17731,7 +17717,7 @@ var Runtime = class {
17731
17717
  onError: this.onError.bind(this)
17732
17718
  };
17733
17719
  treeNode.data.props = props;
17734
- const element = /* @__PURE__ */ require_jsx_runtime.jsx(Root, {
17720
+ const element = /* @__PURE__ */ require_jsx_runtime$1.jsx(Root, {
17735
17721
  ...props,
17736
17722
  children: node
17737
17723
  });
@@ -17756,7 +17742,7 @@ var Runtime = class {
17756
17742
  onError: this.onError.bind(this)
17757
17743
  };
17758
17744
  treeNode.data.props = props;
17759
- const element = /* @__PURE__ */ require_jsx_runtime.jsx(Root, {
17745
+ const element = /* @__PURE__ */ require_jsx_runtime$1.jsx(Root, {
17760
17746
  ...props,
17761
17747
  children: node
17762
17748
  });
@@ -17792,7 +17778,6 @@ var Runtime = class {
17792
17778
  return this.exitPromise;
17793
17779
  }
17794
17780
  };
17795
-
17796
17781
  //#endregion
17797
17782
  //#region src/plugins/reactPlugin.ts
17798
17783
  const reactPlugin = (0, _kubb_fabric_core_plugins.definePlugin)({
@@ -17804,13 +17789,13 @@ const reactPlugin = (0, _kubb_fabric_core_plugins.definePlugin)({
17804
17789
  ...options
17805
17790
  });
17806
17791
  return {
17807
- async render(App) {
17792
+ async render(Fabric) {
17808
17793
  await ctx.emit("lifecycle:start");
17809
- await runtime.render(App);
17794
+ await runtime.render(Fabric);
17810
17795
  },
17811
- async renderToString(App) {
17796
+ async renderToString(Fabric) {
17812
17797
  await ctx.emit("lifecycle:start");
17813
- return runtime.renderToString(App);
17798
+ return runtime.renderToString(Fabric);
17814
17799
  },
17815
17800
  async waitUntilExit() {
17816
17801
  await runtime.waitUntilExit();
@@ -17822,30 +17807,30 @@ const reactPlugin = (0, _kubb_fabric_core_plugins.definePlugin)({
17822
17807
  };
17823
17808
  }
17824
17809
  });
17825
-
17826
17810
  //#endregion
17827
- Object.defineProperty(exports, 'Renderer', {
17828
- enumerable: true,
17829
- get: function () {
17830
- return Renderer;
17831
- }
17811
+ Object.defineProperty(exports, "Renderer", {
17812
+ enumerable: true,
17813
+ get: function() {
17814
+ return Renderer;
17815
+ }
17832
17816
  });
17833
- Object.defineProperty(exports, 'Root', {
17834
- enumerable: true,
17835
- get: function () {
17836
- return Root;
17837
- }
17817
+ Object.defineProperty(exports, "Root", {
17818
+ enumerable: true,
17819
+ get: function() {
17820
+ return Root;
17821
+ }
17838
17822
  });
17839
- Object.defineProperty(exports, 'Runtime', {
17840
- enumerable: true,
17841
- get: function () {
17842
- return Runtime;
17843
- }
17823
+ Object.defineProperty(exports, "Runtime", {
17824
+ enumerable: true,
17825
+ get: function() {
17826
+ return Runtime;
17827
+ }
17844
17828
  });
17845
- Object.defineProperty(exports, 'reactPlugin', {
17846
- enumerable: true,
17847
- get: function () {
17848
- return reactPlugin;
17849
- }
17829
+ Object.defineProperty(exports, "reactPlugin", {
17830
+ enumerable: true,
17831
+ get: function() {
17832
+ return reactPlugin;
17833
+ }
17850
17834
  });
17851
- //# sourceMappingURL=reactPlugin-BshFnF2Y.cjs.map
17835
+
17836
+ //# sourceMappingURL=reactPlugin-D74A1eG4.cjs.map