@valbuild/next 0.64.0 → 0.65.1
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/README.md +36 -91
- package/client/dist/valbuild-next-client.cjs.d.ts +2 -2
- package/client/dist/valbuild-next-client.cjs.dev.js +19 -31
- package/client/dist/valbuild-next-client.cjs.prod.js +19 -31
- package/client/dist/valbuild-next-client.esm.js +19 -31
- package/dist/ValApp-50ec1e10.esm.js +53 -0
- package/dist/ValApp-9eefeefd.cjs.js +7 -0
- package/dist/ValApp-9eefeefd.cjs.prod.js +61 -0
- package/dist/ValApp-de156df4.cjs.dev.js +61 -0
- package/dist/ValNextProvider-0b711372.esm.js +430 -0
- package/dist/ValNextProvider-313af7bb.cjs.js +7 -0
- package/dist/ValNextProvider-313af7bb.cjs.prod.js +439 -0
- package/dist/ValNextProvider-abfbfdb5.cjs.dev.js +439 -0
- package/dist/{ValContext-06fe6f7e.cjs.dev.js → ValOverlayContext-55dae3ea.cjs.dev.js} +62 -71
- package/dist/ValOverlayContext-811e9be9.cjs.js +7 -0
- package/dist/{ValContext-12a3eca2.cjs.prod.js → ValOverlayContext-811e9be9.cjs.prod.js} +62 -71
- package/dist/{ValContext-8a8d9183.esm.js → ValOverlayContext-a2fdbce0.esm.js} +59 -69
- package/dist/{asyncToGenerator-0859ab5c.esm.js → asyncToGenerator-5f8c02f3.esm.js} +19 -24
- package/dist/{asyncToGenerator-ba66657c.cjs.dev.js → asyncToGenerator-67a5ff70.cjs.prod.js} +19 -24
- package/dist/{asyncToGenerator-3551d940.cjs.prod.js → asyncToGenerator-6ba61221.cjs.dev.js} +19 -24
- package/dist/declarations/src/ValApp.d.ts +1 -1
- package/dist/declarations/src/ValImage.d.ts +0 -1
- package/dist/declarations/src/ValProvider.d.ts +3 -5
- package/dist/declarations/src/external_exempt_from_val_quickjs.d.ts +31 -2
- package/dist/declarations/src/rsc/initValRsc.d.ts +4 -2
- package/dist/declarations/src/server/initValServer.d.ts +1 -1
- package/dist/{objectSpread2-bb9509e8.cjs.dev.js → objectSpread2-3c87fb4f.cjs.prod.js} +12 -18
- package/dist/{objectSpread2-24e737a6.cjs.prod.js → objectSpread2-792eb2c2.cjs.dev.js} +12 -18
- package/dist/{objectSpread2-439bdcdd.esm.js → objectSpread2-c1340c1c.esm.js} +12 -18
- package/dist/{slicedToArray-c03b6356.cjs.dev.js → slicedToArray-44036a76.cjs.dev.js} +5 -5
- package/dist/{slicedToArray-1ff80c5e.esm.js → slicedToArray-aa291011.esm.js} +5 -5
- package/dist/{slicedToArray-1d91551a.cjs.prod.js → slicedToArray-ce613de6.cjs.prod.js} +5 -5
- package/dist/unsupportedIterableToArray-0d2087a2.cjs.prod.js +17 -0
- package/dist/unsupportedIterableToArray-5baabfdc.esm.js +15 -0
- package/dist/unsupportedIterableToArray-c8ab77c9.cjs.dev.js +17 -0
- package/dist/valbuild-next.cjs.d.ts +2 -2
- package/dist/valbuild-next.cjs.dev.js +23 -28
- package/dist/valbuild-next.cjs.prod.js +23 -28
- package/dist/valbuild-next.esm.js +23 -28
- package/package.json +6 -6
- package/rsc/dist/valbuild-next-rsc.cjs.d.ts +2 -2
- package/rsc/dist/valbuild-next-rsc.cjs.dev.js +202 -134
- package/rsc/dist/valbuild-next-rsc.cjs.prod.js +203 -132
- package/rsc/dist/valbuild-next-rsc.esm.js +203 -135
- package/server/dist/valbuild-next-server.cjs.d.ts +2 -2
- package/server/dist/valbuild-next-server.cjs.dev.js +23 -14
- package/server/dist/valbuild-next-server.cjs.prod.js +23 -14
- package/server/dist/valbuild-next-server.esm.js +23 -14
- package/client/dist/valbuild-next-client.cjs.d.ts.map +0 -1
- package/dist/ValApp-0ec0c7f3.cjs.js +0 -7
- package/dist/ValApp-0ec0c7f3.cjs.prod.js +0 -34
- package/dist/ValApp-61103149.esm.js +0 -26
- package/dist/ValApp-aff60572.cjs.dev.js +0 -34
- package/dist/ValContext-12a3eca2.cjs.js +0 -7
- package/dist/ValNextProvider-5226c452.cjs.js +0 -7
- package/dist/ValNextProvider-5226c452.cjs.prod.js +0 -101
- package/dist/ValNextProvider-ccbea1bd.cjs.dev.js +0 -101
- package/dist/ValNextProvider-d94cd904.esm.js +0 -92
- package/dist/unsupportedIterableToArray-51bb61c2.esm.js +0 -16
- package/dist/unsupportedIterableToArray-9e97e24a.cjs.dev.js +0 -18
- package/dist/unsupportedIterableToArray-afbea1dd.cjs.prod.js +0 -18
- package/dist/valbuild-next.cjs.d.ts.map +0 -1
- package/rsc/dist/valbuild-next-rsc.cjs.d.ts.map +0 -1
- package/server/dist/valbuild-next-server.cjs.d.ts.map +0 -1
package/package.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"next",
|
|
9
9
|
"react"
|
|
10
10
|
],
|
|
11
|
-
"version": "0.
|
|
11
|
+
"version": "0.65.1",
|
|
12
12
|
"scripts": {
|
|
13
13
|
"typecheck": "tsc --noEmit",
|
|
14
14
|
"test": "jest"
|
|
@@ -45,11 +45,11 @@
|
|
|
45
45
|
"exports": true
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@valbuild/core": "~0.
|
|
49
|
-
"@valbuild/react": "~0.
|
|
50
|
-
"@valbuild/server": "~0.
|
|
51
|
-
"@valbuild/shared": "~0.
|
|
52
|
-
"@valbuild/ui": "~0.
|
|
48
|
+
"@valbuild/core": "~0.65.0",
|
|
49
|
+
"@valbuild/react": "~0.65.0",
|
|
50
|
+
"@valbuild/server": "~0.65.0",
|
|
51
|
+
"@valbuild/shared": "~0.65.0",
|
|
52
|
+
"@valbuild/ui": "~0.65.0",
|
|
53
53
|
"client-only": "^0.0.1",
|
|
54
54
|
"server-only": "^0.0.1"
|
|
55
55
|
},
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from "../../dist/declarations/src/rsc/index";
|
|
2
|
-
//# sourceMappingURL=
|
|
1
|
+
export * from "../../dist/declarations/src/rsc/index.js";
|
|
2
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidmFsYnVpbGQtbmV4dC1yc2MuY2pzLmQudHMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9kaXN0L2RlY2xhcmF0aW9ucy9zcmMvcnNjL2luZGV4LmQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEifQ==
|
|
@@ -3,142 +3,168 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
require('server-only');
|
|
6
|
-
var objectSpread2 = require('../../dist/objectSpread2-
|
|
7
|
-
var asyncToGenerator = require('../../dist/asyncToGenerator-
|
|
6
|
+
var objectSpread2 = require('../../dist/objectSpread2-792eb2c2.cjs.dev.js');
|
|
7
|
+
var asyncToGenerator = require('../../dist/asyncToGenerator-6ba61221.cjs.dev.js');
|
|
8
8
|
var stega = require('@valbuild/react/stega');
|
|
9
9
|
var core = require('@valbuild/core');
|
|
10
10
|
var internal = require('@valbuild/shared/internal');
|
|
11
11
|
var server = require('@valbuild/server');
|
|
12
12
|
var version = require('../../dist/version-82faa1d0.cjs.dev.js');
|
|
13
13
|
|
|
14
|
+
stega.SET_RSC(true);
|
|
14
15
|
var initFetchValStega = function initFetchValStega(config, valApiEndpoints, valServerPromise, isEnabled, getHeaders, getCookies) {
|
|
15
16
|
return function (selector) {
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
17
|
+
var exec = /*#__PURE__*/function () {
|
|
18
|
+
var _ref = asyncToGenerator._asyncToGenerator(/*#__PURE__*/asyncToGenerator._regeneratorRuntime().mark(function _callee() {
|
|
19
|
+
var enabled, headers, cookies, host, _cookies, _cookies3, valServer, patchesRes, allPatches, treeRes, modules;
|
|
20
|
+
return asyncToGenerator._regeneratorRuntime().wrap(function _callee$(_context) {
|
|
21
|
+
while (1) switch (_context.prev = _context.next) {
|
|
22
|
+
case 0:
|
|
23
|
+
enabled = false;
|
|
24
|
+
_context.prev = 1;
|
|
25
|
+
_context.next = 4;
|
|
26
|
+
return isEnabled();
|
|
27
|
+
case 4:
|
|
28
|
+
enabled = _context.sent;
|
|
29
|
+
_context.next = 10;
|
|
30
|
+
break;
|
|
31
|
+
case 7:
|
|
32
|
+
_context.prev = 7;
|
|
33
|
+
_context.t0 = _context["catch"](1);
|
|
34
|
+
console.error("Val: could not check if Val is enabled! This might be due to an error to check draftMode. fetchVal can only be used server-side. Use useVal on clients.", _context.t0);
|
|
35
|
+
case 10:
|
|
36
|
+
if (!enabled) {
|
|
37
|
+
_context.next = 58;
|
|
38
|
+
break;
|
|
39
|
+
}
|
|
40
|
+
stega.SET_AUTO_TAG_JSX_ENABLED(true);
|
|
41
|
+
_context.prev = 12;
|
|
42
|
+
_context.next = 15;
|
|
43
|
+
return getHeaders();
|
|
44
|
+
case 15:
|
|
45
|
+
headers = _context.sent;
|
|
46
|
+
if (!(typeof headers.get !== "function")) {
|
|
47
|
+
_context.next = 18;
|
|
48
|
+
break;
|
|
49
|
+
}
|
|
50
|
+
throw new Error("Invalid headers");
|
|
51
|
+
case 18:
|
|
52
|
+
_context.next = 24;
|
|
53
|
+
break;
|
|
54
|
+
case 20:
|
|
55
|
+
_context.prev = 20;
|
|
56
|
+
_context.t1 = _context["catch"](12);
|
|
57
|
+
console.error("Val: could not read headers! fetchVal can only be used server-side. Use useVal on clients.", _context.t1);
|
|
58
|
+
headers = null;
|
|
59
|
+
case 24:
|
|
60
|
+
_context.prev = 24;
|
|
61
|
+
_context.next = 27;
|
|
62
|
+
return getCookies();
|
|
63
|
+
case 27:
|
|
64
|
+
cookies = _context.sent;
|
|
65
|
+
_context.next = 34;
|
|
66
|
+
break;
|
|
67
|
+
case 30:
|
|
68
|
+
_context.prev = 30;
|
|
69
|
+
_context.t2 = _context["catch"](24);
|
|
70
|
+
console.error("Val: could not read cookies! fetchVal can only be used server-side. Use useVal on clients.", _context.t2);
|
|
71
|
+
cookies = null;
|
|
72
|
+
case 34:
|
|
73
|
+
host = headers && getHost(headers);
|
|
74
|
+
if (!(host && cookies)) {
|
|
75
|
+
_context.next = 58;
|
|
76
|
+
break;
|
|
77
|
+
}
|
|
78
|
+
_context.next = 38;
|
|
79
|
+
return valServerPromise;
|
|
80
|
+
case 38:
|
|
81
|
+
valServer = _context.sent;
|
|
82
|
+
_context.next = 41;
|
|
83
|
+
return valServer["/patches/~"]["GET"]({
|
|
84
|
+
query: {
|
|
85
|
+
omit_patch: true,
|
|
86
|
+
author: undefined,
|
|
87
|
+
patch_id: undefined,
|
|
88
|
+
module_file_path: undefined
|
|
89
|
+
},
|
|
90
|
+
cookies: objectSpread2._defineProperty({}, internal.VAL_SESSION_COOKIE, (_cookies = cookies) === null || _cookies === void 0 || (_cookies = _cookies.get(internal.VAL_SESSION_COOKIE)) === null || _cookies === void 0 ? void 0 : _cookies.value)
|
|
91
|
+
});
|
|
92
|
+
case 41:
|
|
93
|
+
patchesRes = _context.sent;
|
|
94
|
+
if (!(patchesRes.status !== 200)) {
|
|
95
|
+
_context.next = 44;
|
|
96
|
+
break;
|
|
97
|
+
}
|
|
98
|
+
throw Error(JSON.stringify(patchesRes.json, null, 2));
|
|
99
|
+
case 44:
|
|
100
|
+
allPatches = Object.keys(patchesRes.json.patches);
|
|
101
|
+
_context.next = 47;
|
|
102
|
+
return valServer["/sources"]["PUT"]({
|
|
103
|
+
path: "/",
|
|
104
|
+
query: {
|
|
105
|
+
validate_sources: true,
|
|
106
|
+
validate_all: false,
|
|
107
|
+
validate_binary_files: false
|
|
108
|
+
},
|
|
109
|
+
body: {
|
|
110
|
+
patchIds: allPatches
|
|
111
|
+
},
|
|
112
|
+
cookies: objectSpread2._defineProperty({}, internal.VAL_SESSION_COOKIE, (_cookies3 = cookies) === null || _cookies3 === void 0 || (_cookies3 = _cookies3.get(internal.VAL_SESSION_COOKIE)) === null || _cookies3 === void 0 ? void 0 : _cookies3.value)
|
|
113
|
+
});
|
|
114
|
+
case 47:
|
|
115
|
+
treeRes = _context.sent;
|
|
116
|
+
if (!(treeRes.status === 200)) {
|
|
117
|
+
_context.next = 53;
|
|
118
|
+
break;
|
|
119
|
+
}
|
|
120
|
+
modules = treeRes.json.modules;
|
|
121
|
+
return _context.abrupt("return", stega.stegaEncode(selector, {
|
|
122
|
+
disabled: !enabled,
|
|
123
|
+
getModule: function getModule(path) {
|
|
124
|
+
var module = modules[path];
|
|
125
|
+
if (module) {
|
|
126
|
+
return module.source;
|
|
104
127
|
}
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
case 21:
|
|
112
|
-
case "end":
|
|
113
|
-
return _context.stop();
|
|
128
|
+
}
|
|
129
|
+
}));
|
|
130
|
+
case 53:
|
|
131
|
+
if (!(treeRes.status === 401)) {
|
|
132
|
+
_context.next = 57;
|
|
133
|
+
break;
|
|
114
134
|
}
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
135
|
+
console.warn("Val: authentication error: ", treeRes.json.message);
|
|
136
|
+
_context.next = 58;
|
|
137
|
+
break;
|
|
138
|
+
case 57:
|
|
139
|
+
throw Error(JSON.stringify(treeRes.json, null, 2));
|
|
140
|
+
case 58:
|
|
141
|
+
return _context.abrupt("return", stega.stegaEncode(selector, {
|
|
142
|
+
disabled: !enabled
|
|
143
|
+
}));
|
|
144
|
+
case 59:
|
|
145
|
+
case "end":
|
|
146
|
+
return _context.stop();
|
|
124
147
|
}
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
148
|
+
}, _callee, null, [[1, 7], [12, 20], [24, 30]]);
|
|
149
|
+
}));
|
|
150
|
+
return function exec() {
|
|
151
|
+
return _ref.apply(this, arguments);
|
|
152
|
+
};
|
|
153
|
+
}();
|
|
154
|
+
return exec()["catch"](function (err) {
|
|
155
|
+
console.error("Val: failed to fetch ", err);
|
|
156
|
+
return stega.stegaEncode(selector, {});
|
|
131
157
|
});
|
|
132
158
|
};
|
|
133
159
|
};
|
|
134
160
|
function getHost(headers) {
|
|
135
161
|
var _headers$get;
|
|
136
162
|
// TODO: does NextJs have a way to determine this?
|
|
137
|
-
var host = headers.get("host");
|
|
163
|
+
var host = headers === null || headers === void 0 ? void 0 : headers.get("host");
|
|
138
164
|
var proto = "https";
|
|
139
|
-
if (headers.get("x-forwarded-proto") === "http") {
|
|
165
|
+
if ((headers === null || headers === void 0 ? void 0 : headers.get("x-forwarded-proto")) === "http") {
|
|
140
166
|
proto = "http";
|
|
141
|
-
} else if ((_headers$get = headers.get("referer")) !== null && _headers$get !== void 0 && _headers$get.startsWith("http://")) {
|
|
167
|
+
} else if (headers !== null && headers !== void 0 && (_headers$get = headers.get("referer")) !== null && _headers$get !== void 0 && _headers$get.startsWith("http://")) {
|
|
142
168
|
proto = "http";
|
|
143
169
|
} else if (host !== null && host !== void 0 && host.startsWith("localhost")) {
|
|
144
170
|
proto = "http";
|
|
@@ -188,14 +214,17 @@ function initValRsc(config, valModules, rscNextConfig) {
|
|
|
188
214
|
next: nextVersion,
|
|
189
215
|
core: coreVersion
|
|
190
216
|
}
|
|
191
|
-
}, config), {
|
|
217
|
+
}, config), config, {
|
|
192
218
|
isEnabled: function isEnabled() {
|
|
193
|
-
return asyncToGenerator._asyncToGenerator(
|
|
219
|
+
return asyncToGenerator._asyncToGenerator(/*#__PURE__*/asyncToGenerator._regeneratorRuntime().mark(function _callee2() {
|
|
194
220
|
return asyncToGenerator._regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
195
221
|
while (1) switch (_context2.prev = _context2.next) {
|
|
196
222
|
case 0:
|
|
197
|
-
|
|
198
|
-
|
|
223
|
+
_context2.next = 2;
|
|
224
|
+
return rscNextConfig.draftMode();
|
|
225
|
+
case 2:
|
|
226
|
+
return _context2.abrupt("return", _context2.sent.isEnabled);
|
|
227
|
+
case 3:
|
|
199
228
|
case "end":
|
|
200
229
|
return _context2.stop();
|
|
201
230
|
}
|
|
@@ -203,12 +232,15 @@ function initValRsc(config, valModules, rscNextConfig) {
|
|
|
203
232
|
}))();
|
|
204
233
|
},
|
|
205
234
|
onEnable: function onEnable() {
|
|
206
|
-
return asyncToGenerator._asyncToGenerator(
|
|
235
|
+
return asyncToGenerator._asyncToGenerator(/*#__PURE__*/asyncToGenerator._regeneratorRuntime().mark(function _callee3() {
|
|
207
236
|
return asyncToGenerator._regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
208
237
|
while (1) switch (_context3.prev = _context3.next) {
|
|
209
238
|
case 0:
|
|
210
|
-
|
|
211
|
-
|
|
239
|
+
_context3.next = 2;
|
|
240
|
+
return rscNextConfig.draftMode();
|
|
241
|
+
case 2:
|
|
242
|
+
_context3.sent.enable();
|
|
243
|
+
case 3:
|
|
212
244
|
case "end":
|
|
213
245
|
return _context3.stop();
|
|
214
246
|
}
|
|
@@ -216,12 +248,15 @@ function initValRsc(config, valModules, rscNextConfig) {
|
|
|
216
248
|
}))();
|
|
217
249
|
},
|
|
218
250
|
onDisable: function onDisable() {
|
|
219
|
-
return asyncToGenerator._asyncToGenerator(
|
|
251
|
+
return asyncToGenerator._asyncToGenerator(/*#__PURE__*/asyncToGenerator._regeneratorRuntime().mark(function _callee4() {
|
|
220
252
|
return asyncToGenerator._regeneratorRuntime().wrap(function _callee4$(_context4) {
|
|
221
253
|
while (1) switch (_context4.prev = _context4.next) {
|
|
222
254
|
case 0:
|
|
223
|
-
|
|
224
|
-
|
|
255
|
+
_context4.next = 2;
|
|
256
|
+
return rscNextConfig.draftMode();
|
|
257
|
+
case 2:
|
|
258
|
+
_context4.sent.disable();
|
|
259
|
+
case 3:
|
|
225
260
|
case "end":
|
|
226
261
|
return _context4.stop();
|
|
227
262
|
}
|
|
@@ -232,13 +267,46 @@ function initValRsc(config, valModules, rscNextConfig) {
|
|
|
232
267
|
return {
|
|
233
268
|
fetchValStega: initFetchValStega(config, valApiEndpoints,
|
|
234
269
|
// TODO: get from config
|
|
235
|
-
valServerPromise, function () {
|
|
236
|
-
return
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
270
|
+
valServerPromise, /*#__PURE__*/asyncToGenerator._asyncToGenerator(/*#__PURE__*/asyncToGenerator._regeneratorRuntime().mark(function _callee5() {
|
|
271
|
+
return asyncToGenerator._regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
272
|
+
while (1) switch (_context5.prev = _context5.next) {
|
|
273
|
+
case 0:
|
|
274
|
+
_context5.next = 2;
|
|
275
|
+
return rscNextConfig.draftMode();
|
|
276
|
+
case 2:
|
|
277
|
+
return _context5.abrupt("return", _context5.sent.isEnabled);
|
|
278
|
+
case 3:
|
|
279
|
+
case "end":
|
|
280
|
+
return _context5.stop();
|
|
281
|
+
}
|
|
282
|
+
}, _callee5);
|
|
283
|
+
})), /*#__PURE__*/asyncToGenerator._asyncToGenerator(/*#__PURE__*/asyncToGenerator._regeneratorRuntime().mark(function _callee6() {
|
|
284
|
+
return asyncToGenerator._regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
285
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
286
|
+
case 0:
|
|
287
|
+
_context6.next = 2;
|
|
288
|
+
return rscNextConfig.headers();
|
|
289
|
+
case 2:
|
|
290
|
+
return _context6.abrupt("return", _context6.sent);
|
|
291
|
+
case 3:
|
|
292
|
+
case "end":
|
|
293
|
+
return _context6.stop();
|
|
294
|
+
}
|
|
295
|
+
}, _callee6);
|
|
296
|
+
})), /*#__PURE__*/asyncToGenerator._asyncToGenerator(/*#__PURE__*/asyncToGenerator._regeneratorRuntime().mark(function _callee7() {
|
|
297
|
+
return asyncToGenerator._regeneratorRuntime().wrap(function _callee7$(_context7) {
|
|
298
|
+
while (1) switch (_context7.prev = _context7.next) {
|
|
299
|
+
case 0:
|
|
300
|
+
_context7.next = 2;
|
|
301
|
+
return rscNextConfig.cookies();
|
|
302
|
+
case 2:
|
|
303
|
+
return _context7.abrupt("return", _context7.sent);
|
|
304
|
+
case 3:
|
|
305
|
+
case "end":
|
|
306
|
+
return _context7.stop();
|
|
307
|
+
}
|
|
308
|
+
}, _callee7);
|
|
309
|
+
})))
|
|
242
310
|
};
|
|
243
311
|
}
|
|
244
312
|
|