@rotorjs/react 0.10.0 → 0.10.2

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.
@@ -21,3 +21,6 @@ export type DashboardProps = {
21
21
  children?: ReactNode;
22
22
  };
23
23
  export declare function Dashboard({ target, initialVars, initialFacts, layouts, defaultLayout, tiles, layout, content, onAction, allowedNavigateOrigins: rawAllowedNavigateOrigins, children, }: DashboardProps): import("react").JSX.Element;
24
+ export declare namespace Dashboard {
25
+ var displayName: string;
26
+ }
@@ -1,2 +1,5 @@
1
1
  import { ErrorDashboardNode } from '@rotorjs/dashboard';
2
2
  export declare function DashboardError({ error }: ErrorDashboardNode): void;
3
+ export declare namespace DashboardError {
4
+ var displayName: string;
5
+ }
@@ -5,3 +5,6 @@ export type DashboardLayoutProps = {
5
5
  children: ReactNode;
6
6
  };
7
7
  export declare function DashboardLayout({ layout, children }: DashboardLayoutProps): import("react").JSX.Element | null;
8
+ export declare namespace DashboardLayout {
9
+ var displayName: string;
10
+ }
@@ -4,3 +4,6 @@ export declare function DashboardLayoutError({ id, error, children, }: PropsWith
4
4
  id?: string;
5
5
  error: unknown;
6
6
  }>): import("react").JSX.Element;
7
+ export declare namespace DashboardLayoutError {
8
+ var displayName: string;
9
+ }
@@ -8,3 +8,6 @@ export type DashboardTileContainerProps = {
8
8
  }) => ReactNode;
9
9
  };
10
10
  export declare function DashboardTileContainer({ layout, children, }: DashboardTileContainerProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import('react').ReactPortal | import('react').ReactElement<unknown, string | import('react').JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
11
+ export declare namespace DashboardTileContainer {
12
+ var displayName: string;
13
+ }
@@ -3,3 +3,6 @@ export declare function DashboardTileError({ id, error, }: {
3
3
  id?: string;
4
4
  error: unknown;
5
5
  }): import("react").JSX.Element;
6
+ export declare namespace DashboardTileError {
7
+ var displayName: string;
8
+ }
@@ -3,3 +3,6 @@ export type DashboardTilesProps = {
3
3
  content: DashboardTileNode[];
4
4
  };
5
5
  export declare function DashboardTiles({ content }: DashboardTilesProps): import("react").JSX.Element;
6
+ export declare namespace DashboardTiles {
7
+ var displayName: string;
8
+ }
package/dist/main.js CHANGED
@@ -4,14 +4,17 @@ import { createContext as a, createElement as o, useCallback as s, useContext as
4
4
  import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
5
5
  //#region lib/DashboardContext.ts
6
6
  var h = a(void 0);
7
+ h.displayName = "DashboardContext";
7
8
  //#endregion
8
9
  //#region lib/DashboardError.tsx
9
10
  function g({ error: e }) {
10
11
  throw e;
11
12
  }
13
+ g.displayName = "DashboardError";
12
14
  //#endregion
13
15
  //#region lib/DashboardLayoutContext.ts
14
16
  var _ = a(void 0);
17
+ _.displayName = "DashboardLayoutContext";
15
18
  //#endregion
16
19
  //#region lib/getNodeKey.ts
17
20
  function v(e, t = 0) {
@@ -34,6 +37,7 @@ function b({ id: e, error: t, children: n }) {
34
37
  }, n)
35
38
  });
36
39
  }
40
+ b.displayName = "DashboardLayoutError";
37
41
  //#endregion
38
42
  //#region lib/DashboardLayout.tsx
39
43
  function x({ layout: e, children: t }) {
@@ -54,6 +58,7 @@ function x({ layout: e, children: t }) {
54
58
  children: t
55
59
  });
56
60
  }
61
+ x.displayName = "DashboardLayout";
57
62
  //#endregion
58
63
  //#region lib/DashboardTileError.tsx
59
64
  function S({ id: e, error: t }) {
@@ -67,6 +72,7 @@ function S({ id: e, error: t }) {
67
72
  key: v(i)
68
73
  });
69
74
  }
75
+ S.displayName = "DashboardTileError";
70
76
  //#endregion
71
77
  //#region lib/DashboardTiles.tsx
72
78
  function C({ content: e }) {
@@ -83,6 +89,7 @@ function C({ content: e }) {
83
89
  }) : /* @__PURE__ */ p(S, { error: `Invalid tile type "${e.type}"` }, v({ type: "error" }, t));
84
90
  }) });
85
91
  }
92
+ C.displayName = "DashboardTiles";
86
93
  //#endregion
87
94
  //#region lib/Dashboard.tsx
88
95
  var w = { [window.location.origin]: !0 };
@@ -161,6 +168,7 @@ function T({ target: t, initialVars: n, initialFacts: r, layouts: a, defaultLayo
161
168
  })
162
169
  });
163
170
  }
171
+ T.displayName = "Dashboard";
164
172
  //#endregion
165
173
  //#region lib/DashboardTileContainer.tsx
166
174
  function E({ layout: e, children: t }) {
@@ -170,6 +178,7 @@ function E({ layout: e, children: t }) {
170
178
  children: t
171
179
  }) : t({});
172
180
  }
181
+ E.displayName = "DashboardTileContainer";
173
182
  //#endregion
174
183
  //#region lib/useDashboardState.ts
175
184
  function D(e, n = []) {
@@ -186,7 +195,7 @@ function D(e, n = []) {
186
195
  //#endregion
187
196
  //#region lib/useNumberFormatter.ts
188
197
  function O(e) {
189
- let { facts: t } = c(h), i = t[r], a = e?.locale || (typeof i == "string" && i ? i : void 0), o = u(() => new n({ locale: a }), [a]);
198
+ let { facts: t } = c(h), i = t[r]?.value, a = e?.locale || (typeof i == "string" && i ? i : void 0), o = u(() => new n({ locale: a }), [a]);
190
199
  return s((e, t) => o.format(e, t), [o]);
191
200
  }
192
201
  //#endregion
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rotorjs/react",
3
- "version": "0.10.0",
3
+ "version": "0.10.2",
4
4
  "description": "Rotor",
5
5
  "author": {
6
6
  "name": "Aaron Burmeister"
@@ -48,13 +48,13 @@
48
48
  "@types/react": "^19.2.17",
49
49
  "@types/react-dom": "^19.1.9",
50
50
  "@vitejs/plugin-react": "^6.0.2",
51
- "eslint": "^10.4.1",
51
+ "eslint": "^10.5.0",
52
52
  "eslint-config-prettier": "^10.1.8",
53
53
  "eslint-import-resolver-typescript": "^4.4.5",
54
54
  "eslint-plugin-import-x": "^4.16.2",
55
55
  "eslint-plugin-prettier": "^5.5.6",
56
56
  "eslint-plugin-react-hooks": "^7.1.1",
57
- "eslint-plugin-react-refresh": "^0.5.2",
57
+ "eslint-plugin-react-refresh": "^0.5.3",
58
58
  "globals": "^17.6.0",
59
59
  "prettier": "^3.8.4",
60
60
  "react": "^19.2.7",