@opentui/react 0.1.61 → 0.1.63

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.
package/index.js CHANGED
@@ -511,6 +511,7 @@ var hostConfig = {
511
511
 
512
512
  // src/reconciler/reconciler.ts
513
513
  var reconciler = ReactReconciler(hostConfig);
514
+ var flushSync = reconciler.flushSync;
514
515
  function _render(element, root) {
515
516
  const container = reconciler.createContainer(root, ConcurrentRoot, null, false, null, "", console.error, console.error, console.error, console.error, null);
516
517
  reconciler.updateContainer(element, container, null, () => {});
@@ -546,6 +547,7 @@ export {
546
547
  useKeyboard,
547
548
  useAppContext,
548
549
  getComponentCatalogue,
550
+ flushSync,
549
551
  extend,
550
552
  createRoot,
551
553
  createElement,
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "main": "index.js",
5
5
  "types": "src/index.d.ts",
6
6
  "type": "module",
7
- "version": "0.1.61",
7
+ "version": "0.1.63",
8
8
  "description": "React renderer for building terminal user interfaces using OpenTUI core",
9
9
  "license": "MIT",
10
10
  "repository": {
@@ -40,7 +40,7 @@
40
40
  }
41
41
  },
42
42
  "dependencies": {
43
- "@opentui/core": "0.1.61",
43
+ "@opentui/core": "0.1.63",
44
44
  "react-reconciler": "^0.32.0"
45
45
  },
46
46
  "devDependencies": {
@@ -2,4 +2,8 @@ import type { RootRenderable } from "@opentui/core";
2
2
  import React from "react";
3
3
  import ReactReconciler from "react-reconciler";
4
4
  export declare const reconciler: ReactReconciler.Reconciler<RootRenderable, import("@opentui/core").BaseRenderable, import("@opentui/core").TextNodeRenderable, unknown, unknown, import("@opentui/core").BaseRenderable>;
5
+ export declare const flushSync: {
6
+ (): void;
7
+ <R>(fn: () => R): R;
8
+ };
5
9
  export declare function _render(element: React.ReactNode, root: RootRenderable): any;
@@ -1,5 +1,7 @@
1
1
  import { CliRenderer } from "@opentui/core";
2
2
  import { type ReactNode } from "react";
3
+ import { flushSync } from "./reconciler";
4
+ export { flushSync };
3
5
  export type Root = {
4
6
  render: (node: ReactNode) => void;
5
7
  unmount: () => void;
@@ -422,6 +422,7 @@ var hostConfig = {
422
422
 
423
423
  // src/reconciler/reconciler.ts
424
424
  var reconciler = ReactReconciler(hostConfig);
425
+ var flushSync = reconciler.flushSync;
425
426
  function _render(element, root) {
426
427
  const container = reconciler.createContainer(root, ConcurrentRoot, null, false, null, "", console.error, console.error, console.error, console.error, null);
427
428
  reconciler.updateContainer(element, container, null, () => {});
@@ -447,5 +448,6 @@ function createRoot(renderer) {
447
448
  };
448
449
  }
449
450
  export {
451
+ flushSync,
450
452
  createRoot
451
453
  };
@@ -426,6 +426,7 @@ var hostConfig = {
426
426
 
427
427
  // src/reconciler/reconciler.ts
428
428
  var reconciler = ReactReconciler(hostConfig);
429
+ var flushSync = reconciler.flushSync;
429
430
  function _render(element, root) {
430
431
  const container = reconciler.createContainer(root, ConcurrentRoot, null, false, null, "", console.error, console.error, console.error, console.error, null);
431
432
  reconciler.updateContainer(element, container, null, () => {});