@valbuild/next 0.83.0 → 0.84.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 (29) hide show
  1. package/client/dist/valbuild-next-client.cjs.dev.js +1 -1
  2. package/client/dist/valbuild-next-client.cjs.prod.js +1 -1
  3. package/client/dist/valbuild-next-client.esm.js +1 -1
  4. package/dist/{ValNextProvider-5f8b7338.esm.js → ValNextProvider-25f1f5c9.esm.js} +2 -2
  5. package/dist/ValNextProvider-a618d775.cjs.js +7 -0
  6. package/dist/{ValNextProvider-9ff1bb92.cjs.prod.js → ValNextProvider-a618d775.cjs.prod.js} +2 -2
  7. package/dist/{ValNextProvider-99b4552f.cjs.dev.js → ValNextProvider-c7952bdc.cjs.dev.js} +2 -2
  8. package/dist/{ValOverlayContext-a2fdbce0.esm.js → ValOverlayContext-6635a4d7.esm.js} +2 -50
  9. package/dist/ValOverlayContext-942f1294.cjs.js +7 -0
  10. package/dist/{ValOverlayContext-811e9be9.cjs.prod.js → ValOverlayContext-942f1294.cjs.prod.js} +3 -51
  11. package/dist/{ValOverlayContext-55dae3ea.cjs.dev.js → ValOverlayContext-c82a4507.cjs.dev.js} +3 -51
  12. package/dist/createForOfIteratorHelper-0445603c.cjs.dev.js +54 -0
  13. package/dist/createForOfIteratorHelper-5758a730.esm.js +52 -0
  14. package/dist/createForOfIteratorHelper-d4afcad8.cjs.prod.js +54 -0
  15. package/dist/declarations/src/external_exempt_from_val_quickjs.d.ts +1 -0
  16. package/dist/declarations/src/initVal.d.ts +3 -1
  17. package/dist/declarations/src/rsc/initValRsc.d.ts +11 -1
  18. package/dist/typeof-16428c61.cjs.prod.js +13 -0
  19. package/dist/typeof-a1531d8f.esm.js +11 -0
  20. package/dist/typeof-b568f48f.cjs.dev.js +13 -0
  21. package/dist/valbuild-next.cjs.dev.js +6 -13
  22. package/dist/valbuild-next.cjs.prod.js +6 -13
  23. package/dist/valbuild-next.esm.js +5 -12
  24. package/package.json +6 -6
  25. package/rsc/dist/valbuild-next-rsc.cjs.dev.js +248 -36
  26. package/rsc/dist/valbuild-next-rsc.cjs.prod.js +248 -36
  27. package/rsc/dist/valbuild-next-rsc.esm.js +250 -38
  28. package/dist/ValNextProvider-9ff1bb92.cjs.js +0 -7
  29. package/dist/ValOverlayContext-811e9be9.cjs.js +0 -7
@@ -5,7 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
5
5
  require('client-only');
6
6
  var stega = require('@valbuild/react/stega');
7
7
  var React = require('react');
8
- var ValOverlayContext = require('../../dist/ValOverlayContext-55dae3ea.cjs.dev.js');
8
+ var ValOverlayContext = require('../../dist/ValOverlayContext-c82a4507.cjs.dev.js');
9
9
 
10
10
  function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
11
11
 
@@ -5,7 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
5
5
  require('client-only');
6
6
  var stega = require('@valbuild/react/stega');
7
7
  var React = require('react');
8
- var ValOverlayContext = require('../../dist/ValOverlayContext-811e9be9.cjs.prod.js');
8
+ var ValOverlayContext = require('../../dist/ValOverlayContext-942f1294.cjs.prod.js');
9
9
 
10
10
  function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
11
11
 
@@ -1,7 +1,7 @@
1
1
  import 'client-only';
2
2
  import { getModuleIds, stegaEncode } from '@valbuild/react/stega';
3
3
  import React from 'react';
4
- import { useValOverlayContext } from '../../dist/ValOverlayContext-a2fdbce0.esm.js';
4
+ import { useValOverlayContext } from '../../dist/ValOverlayContext-6635a4d7.esm.js';
5
5
 
6
6
  function useValStega(selector) {
7
7
  var valOverlayContext = useValOverlayContext();
@@ -6,7 +6,7 @@ import { VERSION, VAL_APP_PATH, VAL_OVERLAY_ID } from '@valbuild/ui';
6
6
  import { useRouter } from 'next/navigation';
7
7
  import Script from 'next/script';
8
8
  import React from 'react';
9
- import { ValExternalStore, ValOverlayProvider } from './ValOverlayContext-a2fdbce0.esm.js';
9
+ import { ValExternalStore, ValOverlayProvider } from './ValOverlayContext-6635a4d7.esm.js';
10
10
  import { SET_AUTO_TAG_JSX_ENABLED } from '@valbuild/react/stega';
11
11
  import { createValClient } from '@valbuild/shared/internal';
12
12
  import { u as useRemoteConfigSender } from './useRemoteConfigSender-02451801.esm.js';
@@ -256,7 +256,7 @@ var ValNextProvider = function ValNextProvider(props) {
256
256
  }), /*#__PURE__*/jsx("div", {
257
257
  className: getPositionClassName(dropZone) + " p-4",
258
258
  children: /*#__PURE__*/jsx("div", {
259
- className: "flex items-center justify-center p-2 text-white bg-black rounded backdrop-blur",
259
+ className: "flex justify-center items-center p-2 text-white bg-black rounded backdrop-blur",
260
260
  children: /*#__PURE__*/jsx(Clock, {
261
261
  className: "animate-spin",
262
262
  size: 16
@@ -0,0 +1,7 @@
1
+ 'use strict';
2
+
3
+ if (process.env.NODE_ENV === "production") {
4
+ module.exports = require("./ValNextProvider-a618d775.cjs.prod.js");
5
+ } else {
6
+ module.exports = require("./ValNextProvider-a618d775.cjs.dev.js");
7
+ }
@@ -10,7 +10,7 @@ var ui = require('@valbuild/ui');
10
10
  var navigation = require('next/navigation');
11
11
  var Script = require('next/script');
12
12
  var React = require('react');
13
- var ValOverlayContext = require('./ValOverlayContext-811e9be9.cjs.prod.js');
13
+ var ValOverlayContext = require('./ValOverlayContext-942f1294.cjs.prod.js');
14
14
  var stega = require('@valbuild/react/stega');
15
15
  var internal = require('@valbuild/shared/internal');
16
16
  var useRemoteConfigSender = require('./useRemoteConfigSender-3ea2fe91.cjs.prod.js');
@@ -265,7 +265,7 @@ var ValNextProvider = function ValNextProvider(props) {
265
265
  }), /*#__PURE__*/jsxRuntime.jsx("div", {
266
266
  className: getPositionClassName(dropZone) + " p-4",
267
267
  children: /*#__PURE__*/jsxRuntime.jsx("div", {
268
- className: "flex items-center justify-center p-2 text-white bg-black rounded backdrop-blur",
268
+ className: "flex justify-center items-center p-2 text-white bg-black rounded backdrop-blur",
269
269
  children: /*#__PURE__*/jsxRuntime.jsx(Clock, {
270
270
  className: "animate-spin",
271
271
  size: 16
@@ -10,7 +10,7 @@ var ui = require('@valbuild/ui');
10
10
  var navigation = require('next/navigation');
11
11
  var Script = require('next/script');
12
12
  var React = require('react');
13
- var ValOverlayContext = require('./ValOverlayContext-55dae3ea.cjs.dev.js');
13
+ var ValOverlayContext = require('./ValOverlayContext-c82a4507.cjs.dev.js');
14
14
  var stega = require('@valbuild/react/stega');
15
15
  var internal = require('@valbuild/shared/internal');
16
16
  var useRemoteConfigSender = require('./useRemoteConfigSender-c78b81c5.cjs.dev.js');
@@ -265,7 +265,7 @@ var ValNextProvider = function ValNextProvider(props) {
265
265
  }), /*#__PURE__*/jsxRuntime.jsx("div", {
266
266
  className: getPositionClassName(dropZone) + " p-4",
267
267
  children: /*#__PURE__*/jsxRuntime.jsx("div", {
268
- className: "flex items-center justify-center p-2 text-white bg-black rounded backdrop-blur",
268
+ className: "flex justify-center items-center p-2 text-white bg-black rounded backdrop-blur",
269
269
  children: /*#__PURE__*/jsxRuntime.jsx(Clock, {
270
270
  className: "animate-spin",
271
271
  size: 16
@@ -1,57 +1,9 @@
1
1
  'use client';
2
- import { _ as _unsupportedIterableToArray } from './unsupportedIterableToArray-5baabfdc.esm.js';
2
+ import { _ as _createForOfIteratorHelper } from './createForOfIteratorHelper-5758a730.esm.js';
3
3
  import { b as _toPropertyKey, _ as _objectSpread2, a as _defineProperty } from './objectSpread2-c1340c1c.esm.js';
4
4
  import React from 'react';
5
5
  import { jsx } from 'react/jsx-runtime';
6
-
7
- function _createForOfIteratorHelper(r, e) {
8
- var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
9
- if (!t) {
10
- if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
11
- t && (r = t);
12
- var n = 0,
13
- F = function () {};
14
- return {
15
- s: F,
16
- n: function () {
17
- return n >= r.length ? {
18
- done: !0
19
- } : {
20
- done: !1,
21
- value: r[n++]
22
- };
23
- },
24
- e: function (r) {
25
- throw r;
26
- },
27
- f: F
28
- };
29
- }
30
- throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
31
- }
32
- var o,
33
- a = !0,
34
- u = !1;
35
- return {
36
- s: function () {
37
- t = t.call(r);
38
- },
39
- n: function () {
40
- var r = t.next();
41
- return a = r.done, r;
42
- },
43
- e: function (r) {
44
- u = !0, o = r;
45
- },
46
- f: function () {
47
- try {
48
- a || null == t.return || t.return();
49
- } finally {
50
- if (u) throw o;
51
- }
52
- }
53
- };
54
- }
6
+ import './unsupportedIterableToArray-5baabfdc.esm.js';
55
7
 
56
8
  function _classCallCheck(a, n) {
57
9
  if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
@@ -0,0 +1,7 @@
1
+ 'use strict';
2
+
3
+ if (process.env.NODE_ENV === "production") {
4
+ module.exports = require("./ValOverlayContext-942f1294.cjs.prod.js");
5
+ } else {
6
+ module.exports = require("./ValOverlayContext-942f1294.cjs.dev.js");
7
+ }
@@ -3,64 +3,16 @@
3
3
 
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
- var unsupportedIterableToArray = require('./unsupportedIterableToArray-0d2087a2.cjs.prod.js');
6
+ var createForOfIteratorHelper = require('./createForOfIteratorHelper-d4afcad8.cjs.prod.js');
7
7
  var objectSpread2 = require('./objectSpread2-3c87fb4f.cjs.prod.js');
8
8
  var React = require('react');
9
9
  var jsxRuntime = require('react/jsx-runtime');
10
+ require('./unsupportedIterableToArray-0d2087a2.cjs.prod.js');
10
11
 
11
12
  function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
12
13
 
13
14
  var React__default = /*#__PURE__*/_interopDefault(React);
14
15
 
15
- function _createForOfIteratorHelper(r, e) {
16
- var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
17
- if (!t) {
18
- if (Array.isArray(r) || (t = unsupportedIterableToArray._unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
19
- t && (r = t);
20
- var n = 0,
21
- F = function () {};
22
- return {
23
- s: F,
24
- n: function () {
25
- return n >= r.length ? {
26
- done: !0
27
- } : {
28
- done: !1,
29
- value: r[n++]
30
- };
31
- },
32
- e: function (r) {
33
- throw r;
34
- },
35
- f: F
36
- };
37
- }
38
- throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
39
- }
40
- var o,
41
- a = !0,
42
- u = !1;
43
- return {
44
- s: function () {
45
- t = t.call(r);
46
- },
47
- n: function () {
48
- var r = t.next();
49
- return a = r.done, r;
50
- },
51
- e: function (r) {
52
- u = !0, o = r;
53
- },
54
- f: function () {
55
- try {
56
- a || null == t.return || t.return();
57
- } finally {
58
- if (u) throw o;
59
- }
60
- }
61
- };
62
- }
63
-
64
16
  function _classCallCheck(a, n) {
65
17
  if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
66
18
  }
@@ -129,7 +81,7 @@ var ValExternalStore = /*#__PURE__*/function () {
129
81
  }, {
130
82
  key: "emitChange",
131
83
  value: function emitChange(subscriberId) {
132
- var _iterator = _createForOfIteratorHelper(this.listeners[subscriberId]),
84
+ var _iterator = createForOfIteratorHelper._createForOfIteratorHelper(this.listeners[subscriberId]),
133
85
  _step;
134
86
  try {
135
87
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -3,64 +3,16 @@
3
3
 
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
- var unsupportedIterableToArray = require('./unsupportedIterableToArray-c8ab77c9.cjs.dev.js');
6
+ var createForOfIteratorHelper = require('./createForOfIteratorHelper-0445603c.cjs.dev.js');
7
7
  var objectSpread2 = require('./objectSpread2-792eb2c2.cjs.dev.js');
8
8
  var React = require('react');
9
9
  var jsxRuntime = require('react/jsx-runtime');
10
+ require('./unsupportedIterableToArray-c8ab77c9.cjs.dev.js');
10
11
 
11
12
  function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
12
13
 
13
14
  var React__default = /*#__PURE__*/_interopDefault(React);
14
15
 
15
- function _createForOfIteratorHelper(r, e) {
16
- var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
17
- if (!t) {
18
- if (Array.isArray(r) || (t = unsupportedIterableToArray._unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
19
- t && (r = t);
20
- var n = 0,
21
- F = function () {};
22
- return {
23
- s: F,
24
- n: function () {
25
- return n >= r.length ? {
26
- done: !0
27
- } : {
28
- done: !1,
29
- value: r[n++]
30
- };
31
- },
32
- e: function (r) {
33
- throw r;
34
- },
35
- f: F
36
- };
37
- }
38
- throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
39
- }
40
- var o,
41
- a = !0,
42
- u = !1;
43
- return {
44
- s: function () {
45
- t = t.call(r);
46
- },
47
- n: function () {
48
- var r = t.next();
49
- return a = r.done, r;
50
- },
51
- e: function (r) {
52
- u = !0, o = r;
53
- },
54
- f: function () {
55
- try {
56
- a || null == t.return || t.return();
57
- } finally {
58
- if (u) throw o;
59
- }
60
- }
61
- };
62
- }
63
-
64
16
  function _classCallCheck(a, n) {
65
17
  if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
66
18
  }
@@ -129,7 +81,7 @@ var ValExternalStore = /*#__PURE__*/function () {
129
81
  }, {
130
82
  key: "emitChange",
131
83
  value: function emitChange(subscriberId) {
132
- var _iterator = _createForOfIteratorHelper(this.listeners[subscriberId]),
84
+ var _iterator = createForOfIteratorHelper._createForOfIteratorHelper(this.listeners[subscriberId]),
133
85
  _step;
134
86
  try {
135
87
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -0,0 +1,54 @@
1
+ 'use strict';
2
+
3
+ var unsupportedIterableToArray = require('./unsupportedIterableToArray-c8ab77c9.cjs.dev.js');
4
+
5
+ function _createForOfIteratorHelper(r, e) {
6
+ var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
7
+ if (!t) {
8
+ if (Array.isArray(r) || (t = unsupportedIterableToArray._unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
9
+ t && (r = t);
10
+ var n = 0,
11
+ F = function () {};
12
+ return {
13
+ s: F,
14
+ n: function () {
15
+ return n >= r.length ? {
16
+ done: !0
17
+ } : {
18
+ done: !1,
19
+ value: r[n++]
20
+ };
21
+ },
22
+ e: function (r) {
23
+ throw r;
24
+ },
25
+ f: F
26
+ };
27
+ }
28
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
29
+ }
30
+ var o,
31
+ a = !0,
32
+ u = !1;
33
+ return {
34
+ s: function () {
35
+ t = t.call(r);
36
+ },
37
+ n: function () {
38
+ var r = t.next();
39
+ return a = r.done, r;
40
+ },
41
+ e: function (r) {
42
+ u = !0, o = r;
43
+ },
44
+ f: function () {
45
+ try {
46
+ a || null == t.return || t.return();
47
+ } finally {
48
+ if (u) throw o;
49
+ }
50
+ }
51
+ };
52
+ }
53
+
54
+ exports._createForOfIteratorHelper = _createForOfIteratorHelper;
@@ -0,0 +1,52 @@
1
+ import { _ as _unsupportedIterableToArray } from './unsupportedIterableToArray-5baabfdc.esm.js';
2
+
3
+ function _createForOfIteratorHelper(r, e) {
4
+ var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
5
+ if (!t) {
6
+ if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
7
+ t && (r = t);
8
+ var n = 0,
9
+ F = function () {};
10
+ return {
11
+ s: F,
12
+ n: function () {
13
+ return n >= r.length ? {
14
+ done: !0
15
+ } : {
16
+ done: !1,
17
+ value: r[n++]
18
+ };
19
+ },
20
+ e: function (r) {
21
+ throw r;
22
+ },
23
+ f: F
24
+ };
25
+ }
26
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
27
+ }
28
+ var o,
29
+ a = !0,
30
+ u = !1;
31
+ return {
32
+ s: function () {
33
+ t = t.call(r);
34
+ },
35
+ n: function () {
36
+ var r = t.next();
37
+ return a = r.done, r;
38
+ },
39
+ e: function (r) {
40
+ u = !0, o = r;
41
+ },
42
+ f: function () {
43
+ try {
44
+ a || null == t.return || t.return();
45
+ } finally {
46
+ if (u) throw o;
47
+ }
48
+ }
49
+ };
50
+ }
51
+
52
+ export { _createForOfIteratorHelper as _ };
@@ -0,0 +1,54 @@
1
+ 'use strict';
2
+
3
+ var unsupportedIterableToArray = require('./unsupportedIterableToArray-0d2087a2.cjs.prod.js');
4
+
5
+ function _createForOfIteratorHelper(r, e) {
6
+ var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
7
+ if (!t) {
8
+ if (Array.isArray(r) || (t = unsupportedIterableToArray._unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
9
+ t && (r = t);
10
+ var n = 0,
11
+ F = function () {};
12
+ return {
13
+ s: F,
14
+ n: function () {
15
+ return n >= r.length ? {
16
+ done: !0
17
+ } : {
18
+ done: !1,
19
+ value: r[n++]
20
+ };
21
+ },
22
+ e: function (r) {
23
+ throw r;
24
+ },
25
+ f: F
26
+ };
27
+ }
28
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
29
+ }
30
+ var o,
31
+ a = !0,
32
+ u = !1;
33
+ return {
34
+ s: function () {
35
+ t = t.call(r);
36
+ },
37
+ n: function () {
38
+ var r = t.next();
39
+ return a = r.done, r;
40
+ },
41
+ e: function (r) {
42
+ u = !0, o = r;
43
+ },
44
+ f: function () {
45
+ try {
46
+ a || null == t.return || t.return();
47
+ } finally {
48
+ if (u) throw o;
49
+ }
50
+ }
51
+ };
52
+ }
53
+
54
+ exports._createForOfIteratorHelper = _createForOfIteratorHelper;
@@ -34,6 +34,7 @@ export declare const Internal: {
34
34
  safeResolvePath: typeof import("@valbuild/core/dist/declarations/src/module").safeResolvePath;
35
35
  splitModuleFilePathAndModulePath: typeof import("@valbuild/core/dist/declarations/src/module").splitModuleFilePathAndModulePath;
36
36
  joinModuleFilePathAndModulePath: typeof import("@valbuild/core/dist/declarations/src/module").joinModuleFilePathAndModulePath;
37
+ nextAppRouter: import("@valbuild/core").ValRouter;
37
38
  remote: {
38
39
  createRemoteRef: typeof import("@valbuild/core/dist/declarations/src/source/remote").createRemoteRef;
39
40
  getValidationBasis: typeof import("@valbuild/core/dist/declarations/src/remote/validationBasis").getValidationBasis;
@@ -1,10 +1,11 @@
1
- import { type ValConfig, type InitVal, type ValConstructor, ValModule, SelectorSource, Json } from "@valbuild/core";
1
+ import { type ValConfig, type InitVal, type ValConstructor, ValModule, SelectorSource, Json, ValRouter } from "@valbuild/core";
2
2
  import { raw } from "./raw.js";
3
3
  import { getUnpatchedUnencodedVal } from "./getUnpatchedUnencodedVal.js";
4
4
  import { decodeValPathOfString } from "./decodeValPathOfString.js";
5
5
  type ValAttrs = {
6
6
  "data-val-path"?: string;
7
7
  };
8
+ declare const nextAppRouter: ValRouter;
8
9
  export declare const initVal: (config?: ValConfig) => InitVal & {
9
10
  val: ValConstructor & {
10
11
  /**
@@ -24,5 +25,6 @@ export declare const initVal: (config?: ValConfig) => InitVal & {
24
25
  attrs: <T extends ValModule<SelectorSource> | Json>(target: T) => ValAttrs;
25
26
  unstable_decodeValPathOfString: typeof decodeValPathOfString;
26
27
  };
28
+ nextAppRouter: ValRouter;
27
29
  };
28
30
  export {};
@@ -1,5 +1,5 @@
1
1
  import { type StegaOfSource } from "@valbuild/react/stega";
2
- import { SelectorSource, SelectorOf, GenericSelector, ValConfig, ValModules } from "@valbuild/core";
2
+ import { SelectorSource, SelectorOf, GenericSelector, ValConfig, ValModules, ValModule, SourceObject } from "@valbuild/core";
3
3
  import { cookies, draftMode, headers } from "next/headers";
4
4
  import { ValServer } from "@valbuild/server";
5
5
  declare const initFetchValStega: (config: ValConfig, valApiEndpoints: string, valServerPromise: Promise<ValServer>, isEnabled: () => Promise<boolean>, getHeaders: () => Promise<{
@@ -10,6 +10,15 @@ declare const initFetchValStega: (config: ValConfig, valApiEndpoints: string, va
10
10
  value: string;
11
11
  } | undefined;
12
12
  }>) => <T extends SelectorSource>(selector: T) => Promise<SelectorOf<T> extends GenericSelector<infer S extends import("@valbuild/core").Source, undefined> ? StegaOfSource<S> : never>;
13
+ type FetchValRouteReturnType<T extends ValModule<GenericSelector<SourceObject>>> = T extends ValModule<infer S> ? S extends SourceObject ? StegaOfSource<NonNullable<S>[string]> | null : never : never;
14
+ declare const initFetchValRouteStega: (config: ValConfig, valApiEndpoints: string, valServerPromise: Promise<ValServer>, isEnabled: () => Promise<boolean>, getHeaders: () => Promise<{
15
+ get(name: string): string | null;
16
+ }>, getCookies: () => Promise<{
17
+ get(name: string): {
18
+ name: string;
19
+ value: string;
20
+ } | undefined;
21
+ }>) => <T extends ValModule<GenericSelector<SourceObject, undefined>>>(selector: T, params: Promise<Record<string, string | string[]>> | Record<string, string | string[]>) => Promise<FetchValRouteReturnType<T>>;
13
22
  type ValNextRscConfig = {
14
23
  draftMode: typeof draftMode;
15
24
  headers: typeof headers;
@@ -17,5 +26,6 @@ type ValNextRscConfig = {
17
26
  };
18
27
  export declare function initValRsc(config: ValConfig, valModules: ValModules, rscNextConfig: ValNextRscConfig): {
19
28
  fetchValStega: ReturnType<typeof initFetchValStega>;
29
+ fetchValRouteStega: ReturnType<typeof initFetchValRouteStega>;
20
30
  };
21
31
  export {};
@@ -0,0 +1,13 @@
1
+ 'use strict';
2
+
3
+ function _typeof(o) {
4
+ "@babel/helpers - typeof";
5
+
6
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
7
+ return typeof o;
8
+ } : function (o) {
9
+ return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
10
+ }, _typeof(o);
11
+ }
12
+
13
+ exports._typeof = _typeof;
@@ -0,0 +1,11 @@
1
+ function _typeof(o) {
2
+ "@babel/helpers - typeof";
3
+
4
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
5
+ return typeof o;
6
+ } : function (o) {
7
+ return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
8
+ }, _typeof(o);
9
+ }
10
+
11
+ export { _typeof as _ };
@@ -0,0 +1,13 @@
1
+ 'use strict';
2
+
3
+ function _typeof(o) {
4
+ "@babel/helpers - typeof";
5
+
6
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
7
+ return typeof o;
8
+ } : function (o) {
9
+ return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
10
+ }, _typeof(o);
11
+ }
12
+
13
+ exports._typeof = _typeof;
@@ -2,11 +2,12 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
+ var _typeof = require('./typeof-b568f48f.cjs.dev.js');
5
6
  var objectSpread2 = require('./objectSpread2-792eb2c2.cjs.dev.js');
6
7
  var core = require('@valbuild/core');
7
8
  var stega = require('@valbuild/react/stega');
8
9
  var internal = require('@valbuild/react/internal');
9
- var ValNextProvider = require('./ValNextProvider-99b4552f.cjs.dev.js');
10
+ var ValNextProvider = require('./ValNextProvider-c7952bdc.cjs.dev.js');
10
11
  var NextImage = require('next/image');
11
12
  var jsxRuntime = require('react/jsx-runtime');
12
13
  var ValApp = require('./ValApp-0efa0e5d.cjs.dev.js');
@@ -35,16 +36,6 @@ function _interopNamespace(e) {
35
36
  var core__namespace = /*#__PURE__*/_interopNamespace(core);
36
37
  var NextImage__default = /*#__PURE__*/_interopDefault(NextImage);
37
38
 
38
- function _typeof(o) {
39
- "@babel/helpers - typeof";
40
-
41
- return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
42
- return typeof o;
43
- } : function (o) {
44
- return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
45
- }, _typeof(o);
46
- }
47
-
48
39
  function raw(val) {
49
40
  if (typeof val === "string") {
50
41
  return stega.stegaClean(val);
@@ -54,7 +45,7 @@ function raw(val) {
54
45
  return raw(item);
55
46
  });
56
47
  }
57
- if (_typeof(val) === "object" && val !== null) {
48
+ if (_typeof._typeof(val) === "object" && val !== null) {
58
49
  var result = {};
59
50
  for (var _key in val) {
60
51
  if (Object.prototype.hasOwnProperty.call(val, _key)) {
@@ -78,6 +69,7 @@ function decodeValPathOfString(encodedString) {
78
69
  return stega.stegaDecodeString(encodedString);
79
70
  }
80
71
 
72
+ var nextAppRouter = core.Internal.nextAppRouter;
81
73
  var initVal = function initVal(config) {
82
74
  var _createValSystem = core.initVal(config),
83
75
  s = _createValSystem.s,
@@ -88,6 +80,7 @@ var initVal = function initVal(config) {
88
80
  return {
89
81
  s: s,
90
82
  c: c,
83
+ nextAppRouter: nextAppRouter,
91
84
  val: objectSpread2._objectSpread2(objectSpread2._objectSpread2({}, val), {}, {
92
85
  attrs: function attrs(target) {
93
86
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -97,7 +90,7 @@ var initVal = function initVal(config) {
97
90
  return {};
98
91
  }
99
92
  path = core.Internal.getValPath(anyTarget);
100
- if (!path && _typeof(anyTarget) === "object") {
93
+ if (!path && _typeof._typeof(anyTarget) === "object") {
101
94
  path = anyTarget["valPath"];
102
95
  }
103
96
  if (typeof anyTarget === "string") {