@mmapp/react 0.1.0-alpha.23 → 0.1.0-alpha.25

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/dist/index.js CHANGED
@@ -7705,6 +7705,9 @@ var NodeRenderer = ({ node, fallback }) => {
7705
7705
  actionScope
7706
7706
  }), [dsResults, localState, parentScope, actionScope, playerCtx?.auth]);
7707
7707
  const enrichedScope = (0, import_react44.useMemo)(() => {
7708
+ if (!node.dataSources?.length) {
7709
+ return scope;
7710
+ }
7708
7711
  const handleCreate = () => {
7709
7712
  if (primarySlug && resolver) {
7710
7713
  const fields = {};
@@ -7754,12 +7757,11 @@ var NodeRenderer = ({ node, fallback }) => {
7754
7757
  ...scope,
7755
7758
  $action: enrichedAction,
7756
7759
  $instance: enrichedInstance,
7757
- // Also add at top-level for direct access
7758
7760
  handleCreate,
7759
7761
  handleUpdate,
7760
7762
  setSearch
7761
7763
  };
7762
- }, [scope, primarySlug, resolver, handleRefreshQuery, handleSetLocal]);
7764
+ }, [scope, primarySlug, resolver, handleRefreshQuery, handleSetLocal, node.dataSources, localState]);
7763
7765
  if (node.visible_when) {
7764
7766
  const ctx = buildEvalContext(enrichedScope);
7765
7767
  const visible = evaluateExpression2(node.visible_when, ctx);
package/dist/index.mjs CHANGED
@@ -55,7 +55,7 @@ import {
55
55
  useMutation,
56
56
  usePlayerContext,
57
57
  useQuery
58
- } from "./chunk-XWBUADY2.mjs";
58
+ } from "./chunk-AKSS3YYW.mjs";
59
59
  import {
60
60
  ScopeContext,
61
61
  buildLoopScope,
@@ -2801,6 +2801,9 @@ var NodeRenderer = ({ node, fallback }) => {
2801
2801
  actionScope
2802
2802
  }), [dsResults, localState, parentScope, actionScope, playerCtx?.auth]);
2803
2803
  const enrichedScope = (0, import_react12.useMemo)(() => {
2804
+ if (!node.dataSources?.length) {
2805
+ return scope;
2806
+ }
2804
2807
  const handleCreate = () => {
2805
2808
  if (primarySlug && resolver) {
2806
2809
  const fields = {};
@@ -2850,12 +2853,11 @@ var NodeRenderer = ({ node, fallback }) => {
2850
2853
  ...scope,
2851
2854
  $action: enrichedAction,
2852
2855
  $instance: enrichedInstance,
2853
- // Also add at top-level for direct access
2854
2856
  handleCreate,
2855
2857
  handleUpdate,
2856
2858
  setSearch
2857
2859
  };
2858
- }, [scope, primarySlug, resolver, handleRefreshQuery, handleSetLocal]);
2860
+ }, [scope, primarySlug, resolver, handleRefreshQuery, handleSetLocal, node.dataSources, localState]);
2859
2861
  if (node.visible_when) {
2860
2862
  const ctx = buildEvalContext(enrichedScope);
2861
2863
  const visible = evaluateExpression(node.visible_when, ctx);
@@ -23,7 +23,7 @@ import {
23
23
  resolveBinding,
24
24
  usePlayerContext,
25
25
  useTheme
26
- } from "../chunk-XWBUADY2.mjs";
26
+ } from "../chunk-AKSS3YYW.mjs";
27
27
  import {
28
28
  ScopeContext,
29
29
  buildLoopScope,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mmapp/react",
3
- "version": "0.1.0-alpha.23",
3
+ "version": "0.1.0-alpha.25",
4
4
  "description": "React integration for the MindMatrix Player — hooks, components, and WebSocket bridge for browser-side workflow engines",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",