fixed version control heatmap and activity
This commit is contained in:
120
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/CodeFrame/CodeFrame.js
generated
vendored
Normal file
120
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/CodeFrame/CodeFrame.js
generated
vendored
Normal file
@@ -0,0 +1,120 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "CodeFrame", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return CodeFrame;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _anser = /*#__PURE__*/ _interop_require_default._(require("next/dist/compiled/anser"));
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _stripansi = /*#__PURE__*/ _interop_require_default._(require("next/dist/compiled/strip-ansi"));
|
||||
const _stackframe = require("../../helpers/stack-frame");
|
||||
const _useopenineditor = require("../../helpers/use-open-in-editor");
|
||||
const _hotlinkedtext = require("../hot-linked-text");
|
||||
const CodeFrame = function CodeFrame(param) {
|
||||
let { stackFrame, codeFrame } = param;
|
||||
// Strip leading spaces out of the code frame:
|
||||
const formattedFrame = _react.useMemo(()=>{
|
||||
const lines = codeFrame.split(/\r?\n/g);
|
||||
// Find the minimum length of leading spaces after `|` in the code frame
|
||||
const miniLeadingSpacesLength = lines.map((line)=>/^>? +\d+ +\| [ ]+/.exec((0, _stripansi.default)(line)) === null ? null : /^>? +\d+ +\| ( *)/.exec((0, _stripansi.default)(line))).filter(Boolean).map((v)=>v.pop()).reduce((c, n)=>isNaN(c) ? n.length : Math.min(c, n.length), NaN);
|
||||
// When the minimum length of leading spaces is greater than 1, remove them
|
||||
// from the code frame to help the indentation looks better when there's a lot leading spaces.
|
||||
if (miniLeadingSpacesLength > 1) {
|
||||
return lines.map((line, a)=>~(a = line.indexOf("|")) ? line.substring(0, a) + line.substring(a).replace("^\\ {" + miniLeadingSpacesLength + "}", "") : line).join("\n");
|
||||
}
|
||||
return lines.join("\n");
|
||||
}, [
|
||||
codeFrame
|
||||
]);
|
||||
const decoded = _react.useMemo(()=>{
|
||||
return _anser.default.ansiToJson(formattedFrame, {
|
||||
json: true,
|
||||
use_classes: true,
|
||||
remove_empty: true
|
||||
});
|
||||
}, [
|
||||
formattedFrame
|
||||
]);
|
||||
const open = (0, _useopenineditor.useOpenInEditor)({
|
||||
file: stackFrame.file,
|
||||
lineNumber: stackFrame.lineNumber,
|
||||
column: stackFrame.column
|
||||
});
|
||||
// TODO: make the caret absolute
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-nextjs-codeframe": true,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)("p", {
|
||||
role: "link",
|
||||
onClick: open,
|
||||
tabIndex: 1,
|
||||
title: "Click to open in your editor",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("span", {
|
||||
children: [
|
||||
(0, _stackframe.getFrameSource)(stackFrame),
|
||||
" @",
|
||||
" ",
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_hotlinkedtext.HotlinkedText, {
|
||||
text: stackFrame.methodName
|
||||
})
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
viewBox: "0 0 24 24",
|
||||
fill: "none",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("polyline", {
|
||||
points: "15 3 21 3 21 9"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("line", {
|
||||
x1: "10",
|
||||
y1: "14",
|
||||
x2: "21",
|
||||
y2: "3"
|
||||
})
|
||||
]
|
||||
})
|
||||
]
|
||||
})
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("pre", {
|
||||
children: decoded.map((entry, index)=>/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
style: {
|
||||
color: entry.fg ? "var(--color-" + entry.fg + ")" : undefined,
|
||||
...entry.decoration === "bold" ? {
|
||||
fontWeight: 800
|
||||
} : entry.decoration === "italic" ? {
|
||||
fontStyle: "italic"
|
||||
} : undefined
|
||||
},
|
||||
children: entry.content
|
||||
}, "frame-" + index))
|
||||
})
|
||||
]
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=CodeFrame.js.map
|
||||
19
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/CodeFrame/index.js
generated
vendored
Normal file
19
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/CodeFrame/index.js
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "CodeFrame", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return _CodeFrame.CodeFrame;
|
||||
}
|
||||
});
|
||||
const _CodeFrame = require("./CodeFrame");
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/CodeFrame/styles.js
generated
vendored
Normal file
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/CodeFrame/styles.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "styles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n [data-nextjs-codeframe] {\n overflow: auto;\n border-radius: var(--size-gap-half);\n background-color: var(--color-ansi-bg);\n color: var(--color-ansi-fg);\n }\n [data-nextjs-codeframe]::selection,\n [data-nextjs-codeframe] *::selection {\n background-color: var(--color-ansi-selection);\n }\n [data-nextjs-codeframe] * {\n color: inherit;\n background-color: transparent;\n font-family: var(--font-stack-monospace);\n }\n\n [data-nextjs-codeframe] > * {\n margin: 0;\n padding: calc(var(--size-gap) + var(--size-gap-half))\n calc(var(--size-gap-double) + var(--size-gap-half));\n }\n [data-nextjs-codeframe] > div {\n display: inline-block;\n width: auto;\n min-width: 100%;\n border-bottom: 1px solid var(--color-ansi-bright-black);\n }\n [data-nextjs-codeframe] > div > p {\n display: flex;\n align-items: center;\n justify-content: space-between;\n cursor: pointer;\n margin: 0;\n }\n [data-nextjs-codeframe] > div > p:hover {\n text-decoration: underline dotted;\n }\n [data-nextjs-codeframe] div > p > svg {\n width: auto;\n height: 1em;\n margin-left: 8px;\n }\n [data-nextjs-codeframe] div > pre {\n overflow: hidden;\n display: inline-block;\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=styles.js.map
|
||||
86
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/Dialog.js
generated
vendored
Normal file
86
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/Dialog.js
generated
vendored
Normal file
@@ -0,0 +1,86 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "Dialog", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return Dialog;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _useonclickoutside = require("../../hooks/use-on-click-outside");
|
||||
const Dialog = function Dialog(param) {
|
||||
let { children, type, onClose, ...props } = param;
|
||||
const [dialog, setDialog] = _react.useState(null);
|
||||
const [role, setRole] = _react.useState(typeof document !== "undefined" && document.hasFocus() ? "dialog" : undefined);
|
||||
const onDialog = _react.useCallback((node)=>{
|
||||
setDialog(node);
|
||||
}, []);
|
||||
(0, _useonclickoutside.useOnClickOutside)(dialog, (e)=>{
|
||||
e.preventDefault();
|
||||
return onClose == null ? void 0 : onClose();
|
||||
});
|
||||
// Make HTMLElements with `role=link` accessible to be triggered by the
|
||||
// keyboard, i.e. [Enter].
|
||||
_react.useEffect(()=>{
|
||||
if (dialog == null) {
|
||||
return;
|
||||
}
|
||||
const root = dialog.getRootNode();
|
||||
// Always true, but we do this for TypeScript:
|
||||
if (!(root instanceof ShadowRoot)) {
|
||||
return;
|
||||
}
|
||||
const shadowRoot = root;
|
||||
function handler(e) {
|
||||
const el = shadowRoot.activeElement;
|
||||
if (e.key === "Enter" && el instanceof HTMLElement && el.getAttribute("role") === "link") {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
el.click();
|
||||
}
|
||||
}
|
||||
function handleFocus() {
|
||||
// safari will force itself as the active application when a background page triggers any sort of autofocus
|
||||
// this is a workaround to only set the dialog role if the document has focus
|
||||
setRole(document.hasFocus() ? "dialog" : undefined);
|
||||
}
|
||||
shadowRoot.addEventListener("keydown", handler);
|
||||
window.addEventListener("focus", handleFocus);
|
||||
window.addEventListener("blur", handleFocus);
|
||||
return ()=>{
|
||||
shadowRoot.removeEventListener("keydown", handler);
|
||||
window.removeEventListener("focus", handleFocus);
|
||||
window.removeEventListener("blur", handleFocus);
|
||||
};
|
||||
}, [
|
||||
dialog
|
||||
]);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
ref: onDialog,
|
||||
"data-nextjs-dialog": true,
|
||||
tabIndex: -1,
|
||||
role: role,
|
||||
"aria-labelledby": props["aria-labelledby"],
|
||||
"aria-describedby": props["aria-describedby"],
|
||||
"aria-modal": "true",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
"data-nextjs-dialog-banner": true,
|
||||
className: "banner-" + type
|
||||
}),
|
||||
children
|
||||
]
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=Dialog.js.map
|
||||
29
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/DialogBody.js
generated
vendored
Normal file
29
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/DialogBody.js
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "DialogBody", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return DialogBody;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const DialogBody = function DialogBody(param) {
|
||||
let { children, className } = param;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
"data-nextjs-dialog-body": true,
|
||||
className: className,
|
||||
children: children
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=DialogBody.js.map
|
||||
29
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/DialogContent.js
generated
vendored
Normal file
29
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/DialogContent.js
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "DialogContent", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return DialogContent;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const DialogContent = function DialogContent(param) {
|
||||
let { children, className } = param;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
"data-nextjs-dialog-content": true,
|
||||
className: className,
|
||||
children: children
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=DialogContent.js.map
|
||||
29
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/DialogHeader.js
generated
vendored
Normal file
29
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/DialogHeader.js
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "DialogHeader", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return DialogHeader;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const DialogHeader = function DialogHeader(param) {
|
||||
let { children, className } = param;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
"data-nextjs-dialog-header": true,
|
||||
className: className,
|
||||
children: children
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=DialogHeader.js.map
|
||||
47
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/index.js
generated
vendored
Normal file
47
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/index.js
generated
vendored
Normal file
@@ -0,0 +1,47 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
Dialog: null,
|
||||
DialogBody: null,
|
||||
DialogContent: null,
|
||||
DialogHeader: null,
|
||||
styles: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
Dialog: function() {
|
||||
return _Dialog.Dialog;
|
||||
},
|
||||
DialogBody: function() {
|
||||
return _DialogBody.DialogBody;
|
||||
},
|
||||
DialogContent: function() {
|
||||
return _DialogContent.DialogContent;
|
||||
},
|
||||
DialogHeader: function() {
|
||||
return _DialogHeader.DialogHeader;
|
||||
},
|
||||
styles: function() {
|
||||
return _styles.styles;
|
||||
}
|
||||
});
|
||||
const _Dialog = require("./Dialog");
|
||||
const _DialogBody = require("./DialogBody");
|
||||
const _DialogContent = require("./DialogContent");
|
||||
const _DialogHeader = require("./DialogHeader");
|
||||
const _styles = require("./styles");
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/styles.js
generated
vendored
Normal file
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Dialog/styles.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "styles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n [data-nextjs-dialog] {\n display: flex;\n flex-direction: column;\n width: 100%;\n margin-right: auto;\n margin-left: auto;\n outline: none;\n background: var(--color-background);\n border-radius: var(--size-gap);\n box-shadow: 0 var(--size-gap-half) var(--size-gap-double)\n rgba(0, 0, 0, 0.25);\n max-height: calc(100% - 56px);\n overflow-y: hidden;\n }\n\n @media (max-height: 812px) {\n [data-nextjs-dialog-overlay] {\n max-height: calc(100% - 15px);\n }\n }\n\n @media (min-width: 576px) {\n [data-nextjs-dialog] {\n max-width: 540px;\n box-shadow: 0 var(--size-gap) var(--size-gap-quad) rgba(0, 0, 0, 0.25);\n }\n }\n\n @media (min-width: 768px) {\n [data-nextjs-dialog] {\n max-width: 720px;\n }\n }\n\n @media (min-width: 992px) {\n [data-nextjs-dialog] {\n max-width: 960px;\n }\n }\n\n [data-nextjs-dialog-banner] {\n position: relative;\n }\n [data-nextjs-dialog-banner].banner-warning {\n border-color: var(--color-ansi-yellow);\n }\n [data-nextjs-dialog-banner].banner-error {\n border-color: var(--color-ansi-red);\n }\n\n [data-nextjs-dialog-banner]::after {\n z-index: 2;\n content: '';\n position: absolute;\n top: 0;\n right: 0;\n width: 100%;\n /* banner width: */\n border-top-width: var(--size-gap-half);\n border-bottom-width: 0;\n border-top-style: solid;\n border-bottom-style: solid;\n border-top-color: inherit;\n border-bottom-color: transparent;\n }\n\n [data-nextjs-dialog-content] {\n overflow-y: auto;\n border: none;\n margin: 0;\n /* calc(padding + banner width offset) */\n padding: calc(var(--size-gap-double) + var(--size-gap-half))\n var(--size-gap-double);\n height: 100%;\n display: flex;\n flex-direction: column;\n }\n [data-nextjs-dialog-content] > [data-nextjs-dialog-header] {\n flex-shrink: 0;\n margin-bottom: var(--size-gap-double);\n }\n [data-nextjs-dialog-content] > [data-nextjs-dialog-body] {\n position: relative;\n flex: 1 1 auto;\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=styles.js.map
|
||||
@@ -0,0 +1,178 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "LeftRightDialogHeader", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return LeftRightDialogHeader;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _CloseIcon = require("../../icons/CloseIcon");
|
||||
const LeftRightDialogHeader = function LeftRightDialogHeader(param) {
|
||||
let { children, className, previous, next, close } = param;
|
||||
const buttonLeft = _react.useRef(null);
|
||||
const buttonRight = _react.useRef(null);
|
||||
const buttonClose = _react.useRef(null);
|
||||
const [nav, setNav] = _react.useState(null);
|
||||
const onNav = _react.useCallback((el)=>{
|
||||
setNav(el);
|
||||
}, []);
|
||||
_react.useEffect(()=>{
|
||||
if (nav == null) {
|
||||
return;
|
||||
}
|
||||
const root = nav.getRootNode();
|
||||
const d = self.document;
|
||||
function handler(e) {
|
||||
if (e.key === "ArrowLeft") {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
if (buttonLeft.current) {
|
||||
buttonLeft.current.focus();
|
||||
}
|
||||
previous && previous();
|
||||
} else if (e.key === "ArrowRight") {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
if (buttonRight.current) {
|
||||
buttonRight.current.focus();
|
||||
}
|
||||
next && next();
|
||||
} else if (e.key === "Escape") {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
if (root instanceof ShadowRoot) {
|
||||
const a = root.activeElement;
|
||||
if (a && a !== buttonClose.current && a instanceof HTMLElement) {
|
||||
a.blur();
|
||||
return;
|
||||
}
|
||||
}
|
||||
close == null ? void 0 : close();
|
||||
}
|
||||
}
|
||||
root.addEventListener("keydown", handler);
|
||||
if (root !== d) {
|
||||
d.addEventListener("keydown", handler);
|
||||
}
|
||||
return function() {
|
||||
root.removeEventListener("keydown", handler);
|
||||
if (root !== d) {
|
||||
d.removeEventListener("keydown", handler);
|
||||
}
|
||||
};
|
||||
}, [
|
||||
close,
|
||||
nav,
|
||||
next,
|
||||
previous
|
||||
]);
|
||||
// Unlock focus for browsers like Firefox, that break all user focus if the
|
||||
// currently focused item becomes disabled.
|
||||
_react.useEffect(()=>{
|
||||
if (nav == null) {
|
||||
return;
|
||||
}
|
||||
const root = nav.getRootNode();
|
||||
// Always true, but we do this for TypeScript:
|
||||
if (root instanceof ShadowRoot) {
|
||||
const a = root.activeElement;
|
||||
if (previous == null) {
|
||||
if (buttonLeft.current && a === buttonLeft.current) {
|
||||
buttonLeft.current.blur();
|
||||
}
|
||||
} else if (next == null) {
|
||||
if (buttonRight.current && a === buttonRight.current) {
|
||||
buttonRight.current.blur();
|
||||
}
|
||||
}
|
||||
}
|
||||
}, [
|
||||
nav,
|
||||
next,
|
||||
previous
|
||||
]);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-nextjs-dialog-left-right": true,
|
||||
className: className,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("nav", {
|
||||
ref: onNav,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("button", {
|
||||
ref: buttonLeft,
|
||||
type: "button",
|
||||
disabled: previous == null ? true : undefined,
|
||||
"aria-disabled": previous == null ? true : undefined,
|
||||
onClick: previous != null ? previous : undefined,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
viewBox: "0 0 14 14",
|
||||
fill: "none",
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("title", {
|
||||
children: "previous"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M6.99996 1.16666L1.16663 6.99999L6.99996 12.8333M12.8333 6.99999H1.99996H12.8333Z",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round"
|
||||
})
|
||||
]
|
||||
})
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("button", {
|
||||
ref: buttonRight,
|
||||
type: "button",
|
||||
disabled: next == null ? true : undefined,
|
||||
"aria-disabled": next == null ? true : undefined,
|
||||
onClick: next != null ? next : undefined,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
viewBox: "0 0 14 14",
|
||||
fill: "none",
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("title", {
|
||||
children: "next"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M6.99996 1.16666L12.8333 6.99999L6.99996 12.8333M1.16663 6.99999H12H1.16663Z",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round"
|
||||
})
|
||||
]
|
||||
})
|
||||
}),
|
||||
children
|
||||
]
|
||||
}),
|
||||
close ? /*#__PURE__*/ (0, _jsxruntime.jsx)("button", {
|
||||
"data-nextjs-errors-dialog-left-right-close-button": true,
|
||||
ref: buttonClose,
|
||||
type: "button",
|
||||
onClick: close,
|
||||
"aria-label": "Close",
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
"aria-hidden": "true",
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_CloseIcon.CloseIcon, {})
|
||||
})
|
||||
}) : null
|
||||
]
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=LeftRightDialogHeader.js.map
|
||||
32
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/LeftRightDialogHeader/index.js
generated
vendored
Normal file
32
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/LeftRightDialogHeader/index.js
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
LeftRightDialogHeader: null,
|
||||
styles: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
LeftRightDialogHeader: function() {
|
||||
return _LeftRightDialogHeader.LeftRightDialogHeader;
|
||||
},
|
||||
styles: function() {
|
||||
return _styles.styles;
|
||||
}
|
||||
});
|
||||
const _LeftRightDialogHeader = require("./LeftRightDialogHeader");
|
||||
const _styles = require("./styles");
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/LeftRightDialogHeader/styles.js
generated
vendored
Normal file
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/LeftRightDialogHeader/styles.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "styles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n [data-nextjs-dialog-left-right] {\n display: flex;\n flex-direction: row;\n align-content: center;\n align-items: center;\n justify-content: space-between;\n }\n [data-nextjs-dialog-left-right] > nav {\n flex: 1;\n display: flex;\n align-items: center;\n margin-right: var(--size-gap);\n }\n [data-nextjs-dialog-left-right] > nav > button {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n\n width: calc(var(--size-gap-double) + var(--size-gap));\n height: calc(var(--size-gap-double) + var(--size-gap));\n font-size: 0;\n border: none;\n background-color: rgba(255, 85, 85, 0.1);\n color: var(--color-ansi-red);\n cursor: pointer;\n transition: background-color 0.25s ease;\n }\n [data-nextjs-dialog-left-right] > nav > button > svg {\n width: auto;\n height: calc(var(--size-gap) + var(--size-gap-half));\n }\n [data-nextjs-dialog-left-right] > nav > button:hover {\n background-color: rgba(255, 85, 85, 0.2);\n }\n [data-nextjs-dialog-left-right] > nav > button:disabled {\n background-color: rgba(255, 85, 85, 0.1);\n color: rgba(255, 85, 85, 0.4);\n cursor: not-allowed;\n }\n\n [data-nextjs-dialog-left-right] > nav > button:first-of-type {\n border-radius: var(--size-gap-half) 0 0 var(--size-gap-half);\n margin-right: 1px;\n }\n [data-nextjs-dialog-left-right] > nav > button:last-of-type {\n border-radius: 0 var(--size-gap-half) var(--size-gap-half) 0;\n }\n\n [data-nextjs-dialog-left-right] > button:last-of-type {\n border: 0;\n padding: 0;\n\n background-color: transparent;\n appearance: none;\n\n opacity: 0.4;\n transition: opacity 0.25s ease;\n\n color: var(--color-font);\n }\n [data-nextjs-dialog-left-right] > button:last-of-type:hover {\n opacity: 0.7;\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=styles.js.map
|
||||
62
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/Overlay.js
generated
vendored
Normal file
62
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/Overlay.js
generated
vendored
Normal file
@@ -0,0 +1,62 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "Overlay", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return Overlay;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _maintaintabfocus = /*#__PURE__*/ _interop_require_default._(require("./maintain--tab-focus"));
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _bodylocker = require("./body-locker");
|
||||
const Overlay = function Overlay(param) {
|
||||
let { className, children, fixed } = param;
|
||||
_react.useEffect(()=>{
|
||||
(0, _bodylocker.lock)();
|
||||
return ()=>{
|
||||
(0, _bodylocker.unlock)();
|
||||
};
|
||||
}, []);
|
||||
const [overlay, setOverlay] = _react.useState(null);
|
||||
const onOverlay = _react.useCallback((el)=>{
|
||||
setOverlay(el);
|
||||
}, []);
|
||||
_react.useEffect(()=>{
|
||||
if (overlay == null) {
|
||||
return;
|
||||
}
|
||||
const handle2 = (0, _maintaintabfocus.default)({
|
||||
context: overlay
|
||||
});
|
||||
return ()=>{
|
||||
handle2.disengage();
|
||||
};
|
||||
}, [
|
||||
overlay
|
||||
]);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-nextjs-dialog-overlay": true,
|
||||
className: className,
|
||||
ref: onOverlay,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
"data-nextjs-dialog-backdrop": true,
|
||||
"data-nextjs-dialog-backdrop-fixed": fixed ? true : undefined
|
||||
}),
|
||||
children
|
||||
]
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=Overlay.js.map
|
||||
62
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/body-locker.js
generated
vendored
Normal file
62
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/body-locker.js
generated
vendored
Normal file
@@ -0,0 +1,62 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
lock: null,
|
||||
unlock: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
lock: function() {
|
||||
return lock;
|
||||
},
|
||||
unlock: function() {
|
||||
return unlock;
|
||||
}
|
||||
});
|
||||
let previousBodyPaddingRight;
|
||||
let previousBodyOverflowSetting;
|
||||
let activeLocks = 0;
|
||||
function lock() {
|
||||
setTimeout(()=>{
|
||||
if (activeLocks++ > 0) {
|
||||
return;
|
||||
}
|
||||
const scrollBarGap = window.innerWidth - document.documentElement.clientWidth;
|
||||
if (scrollBarGap > 0) {
|
||||
previousBodyPaddingRight = document.body.style.paddingRight;
|
||||
document.body.style.paddingRight = "" + scrollBarGap + "px";
|
||||
}
|
||||
previousBodyOverflowSetting = document.body.style.overflow;
|
||||
document.body.style.overflow = "hidden";
|
||||
});
|
||||
}
|
||||
function unlock() {
|
||||
setTimeout(()=>{
|
||||
if (activeLocks === 0 || --activeLocks !== 0) {
|
||||
return;
|
||||
}
|
||||
if (previousBodyPaddingRight !== undefined) {
|
||||
document.body.style.paddingRight = previousBodyPaddingRight;
|
||||
previousBodyPaddingRight = undefined;
|
||||
}
|
||||
if (previousBodyOverflowSetting !== undefined) {
|
||||
document.body.style.overflow = previousBodyOverflowSetting;
|
||||
previousBodyOverflowSetting = undefined;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=body-locker.js.map
|
||||
19
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/index.js
generated
vendored
Normal file
19
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/index.js
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "Overlay", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return _Overlay.Overlay;
|
||||
}
|
||||
});
|
||||
const _Overlay = require("./Overlay");
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
2716
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/maintain--tab-focus.js
generated
vendored
Normal file
2716
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/maintain--tab-focus.js
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/styles.js
generated
vendored
Normal file
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Overlay/styles.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "styles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n [data-nextjs-dialog-overlay] {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n overflow: auto;\n z-index: 9000;\n\n display: flex;\n align-content: center;\n align-items: center;\n flex-direction: column;\n padding: 10vh 15px 0;\n }\n\n @media (max-height: 812px) {\n [data-nextjs-dialog-overlay] {\n padding: 15px 15px 0;\n }\n }\n\n [data-nextjs-dialog-backdrop] {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n background-color: var(--color-backdrop);\n pointer-events: all;\n z-index: -1;\n }\n\n [data-nextjs-dialog-backdrop-fixed] {\n cursor: not-allowed;\n -webkit-backdrop-filter: blur(8px);\n backdrop-filter: blur(8px);\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=styles.js.map
|
||||
42
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/ShadowPortal.js
generated
vendored
Normal file
42
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/ShadowPortal.js
generated
vendored
Normal file
@@ -0,0 +1,42 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "ShadowPortal", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return ShadowPortal;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _reactdom = require("react-dom");
|
||||
function ShadowPortal(param) {
|
||||
let { children } = param;
|
||||
let portalNode = _react.useRef(null);
|
||||
let shadowNode = _react.useRef(null);
|
||||
let [, forceUpdate] = _react.useState();
|
||||
_react.useLayoutEffect(()=>{
|
||||
const ownerDocument = document;
|
||||
portalNode.current = ownerDocument.createElement("nextjs-portal");
|
||||
shadowNode.current = portalNode.current.attachShadow({
|
||||
mode: "open"
|
||||
});
|
||||
ownerDocument.body.appendChild(portalNode.current);
|
||||
forceUpdate({});
|
||||
return ()=>{
|
||||
if (portalNode.current && portalNode.current.ownerDocument) {
|
||||
portalNode.current.ownerDocument.body.removeChild(portalNode.current);
|
||||
}
|
||||
};
|
||||
}, []);
|
||||
return shadowNode.current ? /*#__PURE__*/ (0, _reactdom.createPortal)(children, shadowNode.current) : null;
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=ShadowPortal.js.map
|
||||
67
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/EditorLink.js
generated
vendored
Normal file
67
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/EditorLink.js
generated
vendored
Normal file
@@ -0,0 +1,67 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "EditorLink", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return EditorLink;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_default._(require("react"));
|
||||
const _useopenineditor = require("../../helpers/use-open-in-editor");
|
||||
function EditorLink(param) {
|
||||
let { file, isSourceFile, location } = param;
|
||||
var _location_line, _location_column;
|
||||
const open = (0, _useopenineditor.useOpenInEditor)({
|
||||
file,
|
||||
lineNumber: (_location_line = location == null ? void 0 : location.line) != null ? _location_line : 1,
|
||||
column: (_location_column = location == null ? void 0 : location.column) != null ? _location_column : 0
|
||||
});
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-with-open-in-editor-link": true,
|
||||
"data-with-open-in-editor-link-source-file": isSourceFile ? true : undefined,
|
||||
"data-with-open-in-editor-link-import-trace": isSourceFile ? undefined : true,
|
||||
tabIndex: 10,
|
||||
role: "link",
|
||||
onClick: open,
|
||||
title: "Click to open in your editor",
|
||||
children: [
|
||||
file,
|
||||
location ? ":" + location.line + ":" + location.column : null,
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
viewBox: "0 0 24 24",
|
||||
fill: "none",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("polyline", {
|
||||
points: "15 3 21 3 21 9"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("line", {
|
||||
x1: "10",
|
||||
y1: "14",
|
||||
x2: "21",
|
||||
y2: "3"
|
||||
})
|
||||
]
|
||||
})
|
||||
]
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=EditorLink.js.map
|
||||
108
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/Terminal.js
generated
vendored
Normal file
108
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/Terminal.js
generated
vendored
Normal file
@@ -0,0 +1,108 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "Terminal", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return Terminal;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _anser = /*#__PURE__*/ _interop_require_default._(require("next/dist/compiled/anser"));
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _hotlinkedtext = require("../hot-linked-text");
|
||||
const _EditorLink = require("./EditorLink");
|
||||
function getFile(lines) {
|
||||
const contentFileName = lines.shift();
|
||||
if (!contentFileName) return null;
|
||||
const [fileName, line, column] = contentFileName.split(":", 3);
|
||||
const parsedLine = Number(line);
|
||||
const parsedColumn = Number(column);
|
||||
const hasLocation = !Number.isNaN(parsedLine) && !Number.isNaN(parsedColumn);
|
||||
return {
|
||||
fileName: hasLocation ? fileName : contentFileName,
|
||||
location: hasLocation ? {
|
||||
line: parsedLine,
|
||||
column: parsedColumn
|
||||
} : undefined
|
||||
};
|
||||
}
|
||||
function getImportTraceFiles(lines) {
|
||||
if (lines.some((line)=>/ReactServerComponentsError:/.test(line)) || lines.some((line)=>/Import trace for requested module:/.test(line))) {
|
||||
// Grab the lines at the end containing the files
|
||||
const files = [];
|
||||
while(/.+\..+/.test(lines[lines.length - 1]) && !lines[lines.length - 1].includes(":")){
|
||||
const file = lines.pop().trim();
|
||||
files.unshift(file);
|
||||
}
|
||||
return files;
|
||||
}
|
||||
return [];
|
||||
}
|
||||
function getEditorLinks(content) {
|
||||
const lines = content.split("\n");
|
||||
const file = getFile(lines);
|
||||
const importTraceFiles = getImportTraceFiles(lines);
|
||||
return {
|
||||
file,
|
||||
source: lines.join("\n"),
|
||||
importTraceFiles
|
||||
};
|
||||
}
|
||||
const Terminal = function Terminal(param) {
|
||||
let { content } = param;
|
||||
const { file, source, importTraceFiles } = _react.useMemo(()=>getEditorLinks(content), [
|
||||
content
|
||||
]);
|
||||
const decoded = _react.useMemo(()=>{
|
||||
return _anser.default.ansiToJson(source, {
|
||||
json: true,
|
||||
use_classes: true,
|
||||
remove_empty: true
|
||||
});
|
||||
}, [
|
||||
source
|
||||
]);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-nextjs-terminal": true,
|
||||
children: [
|
||||
file && /*#__PURE__*/ (0, _jsxruntime.jsx)(_EditorLink.EditorLink, {
|
||||
isSourceFile: true,
|
||||
file: file.fileName,
|
||||
location: file.location
|
||||
}, file.fileName),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("pre", {
|
||||
children: [
|
||||
decoded.map((entry, index)=>/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
style: {
|
||||
color: entry.fg ? "var(--color-" + entry.fg + ")" : undefined,
|
||||
...entry.decoration === "bold" ? {
|
||||
fontWeight: 800
|
||||
} : entry.decoration === "italic" ? {
|
||||
fontStyle: "italic"
|
||||
} : undefined
|
||||
},
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_hotlinkedtext.HotlinkedText, {
|
||||
text: entry.content
|
||||
})
|
||||
}, "terminal-entry-" + index)),
|
||||
importTraceFiles.map((importTraceFile)=>/*#__PURE__*/ (0, _jsxruntime.jsx)(_EditorLink.EditorLink, {
|
||||
isSourceFile: false,
|
||||
file: importTraceFile
|
||||
}, importTraceFile))
|
||||
]
|
||||
})
|
||||
]
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=Terminal.js.map
|
||||
19
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/index.js
generated
vendored
Normal file
19
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/index.js
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "Terminal", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return _Terminal.Terminal;
|
||||
}
|
||||
});
|
||||
const _Terminal = require("./Terminal");
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/styles.js
generated
vendored
Normal file
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Terminal/styles.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "styles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n [data-nextjs-terminal] {\n border-radius: var(--size-gap-half);\n background-color: var(--color-ansi-bg);\n color: var(--color-ansi-fg);\n }\n [data-nextjs-terminal]::selection,\n [data-nextjs-terminal] *::selection {\n background-color: var(--color-ansi-selection);\n }\n [data-nextjs-terminal] * {\n color: inherit;\n background-color: transparent;\n font-family: var(--font-stack-monospace);\n }\n [data-nextjs-terminal] > * {\n margin: 0;\n padding: calc(var(--size-gap) + var(--size-gap-half))\n calc(var(--size-gap-double) + var(--size-gap-half));\n }\n\n [data-nextjs-terminal] pre {\n white-space: pre-wrap;\n word-break: break-word;\n }\n\n [data-with-open-in-editor-link] svg {\n width: auto;\n height: var(--size-font-small);\n margin-left: var(--size-gap);\n }\n [data-with-open-in-editor-link] {\n cursor: pointer;\n }\n [data-with-open-in-editor-link]:hover {\n text-decoration: underline dotted;\n }\n [data-with-open-in-editor-link-source-file] {\n border-bottom: 1px solid var(--color-ansi-bright-black);\n display: flex;\n align-items: center;\n justify-content: space-between;\n }\n [data-with-open-in-editor-link-import-trace] {\n margin-left: var(--size-gap-double);\n }\n [data-nextjs-terminal] a {\n color: inherit;\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=styles.js.map
|
||||
36
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Toast/Toast.js
generated
vendored
Normal file
36
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Toast/Toast.js
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "Toast", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return Toast;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const Toast = function Toast(param) {
|
||||
let { onClick, children, className } = param;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
"data-nextjs-toast": true,
|
||||
onClick: (e)=>{
|
||||
e.preventDefault();
|
||||
return onClick == null ? void 0 : onClick();
|
||||
},
|
||||
className: className,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
"data-nextjs-toast-wrapper": true,
|
||||
children: children
|
||||
})
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=Toast.js.map
|
||||
32
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Toast/index.js
generated
vendored
Normal file
32
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Toast/index.js
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
Toast: null,
|
||||
styles: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
Toast: function() {
|
||||
return _Toast.Toast;
|
||||
},
|
||||
styles: function() {
|
||||
return _styles.styles;
|
||||
}
|
||||
});
|
||||
const _styles = require("./styles");
|
||||
const _Toast = require("./Toast");
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Toast/styles.js
generated
vendored
Normal file
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/Toast/styles.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "styles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n [data-nextjs-toast] {\n position: fixed;\n bottom: var(--size-gap-double);\n left: var(--size-gap-double);\n max-width: 420px;\n z-index: 9000;\n }\n\n @media (max-width: 440px) {\n [data-nextjs-toast] {\n max-width: 90vw;\n left: 5vw;\n }\n }\n\n [data-nextjs-toast-wrapper] {\n padding: 16px;\n border-radius: var(--size-gap-half);\n font-weight: 500;\n color: var(--color-ansi-bright-white);\n background-color: var(--color-ansi-red);\n box-shadow: 0px var(--size-gap-double) var(--size-gap-quad)\n rgba(0, 0, 0, 0.25);\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=styles.js.map
|
||||
104
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/VersionStalenessInfo/VersionStalenessInfo.js
generated
vendored
Normal file
104
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/VersionStalenessInfo/VersionStalenessInfo.js
generated
vendored
Normal file
@@ -0,0 +1,104 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
VersionStalenessInfo: null,
|
||||
getStaleness: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
VersionStalenessInfo: function() {
|
||||
return VersionStalenessInfo;
|
||||
},
|
||||
getStaleness: function() {
|
||||
return getStaleness;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_default._(require("react"));
|
||||
function VersionStalenessInfo(props) {
|
||||
if (!props) return null;
|
||||
const { staleness } = props;
|
||||
let { text, indicatorClass, title } = getStaleness(props);
|
||||
if (!text) return null;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("small", {
|
||||
className: "nextjs-container-build-error-version-status",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
className: indicatorClass
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("small", {
|
||||
"data-nextjs-version-checker": true,
|
||||
title: title,
|
||||
children: text
|
||||
}),
|
||||
" ",
|
||||
staleness === "fresh" || staleness === "newer-than-npm" || staleness === "unknown" ? null : /*#__PURE__*/ (0, _jsxruntime.jsx)("a", {
|
||||
target: "_blank",
|
||||
rel: "noopener noreferrer",
|
||||
href: "https://nextjs.org/docs/messages/version-staleness",
|
||||
children: "(learn more)"
|
||||
}),
|
||||
process.env.TURBOPACK ? " (turbo)" : ""
|
||||
]
|
||||
});
|
||||
}
|
||||
function getStaleness(param) {
|
||||
let { installed, staleness, expected } = param;
|
||||
let text = "";
|
||||
let title = "";
|
||||
let indicatorClass = "";
|
||||
const versionLabel = "Next.js (" + installed + ")";
|
||||
switch(staleness){
|
||||
case "newer-than-npm":
|
||||
case "fresh":
|
||||
text = versionLabel;
|
||||
title = "Latest available version is detected (" + installed + ").";
|
||||
indicatorClass = "fresh";
|
||||
break;
|
||||
case "stale-patch":
|
||||
case "stale-minor":
|
||||
text = "" + versionLabel + " out of date";
|
||||
title = "There is a newer version (" + expected + ") available, upgrade recommended! ";
|
||||
indicatorClass = "stale";
|
||||
break;
|
||||
case "stale-major":
|
||||
{
|
||||
text = "" + versionLabel + " is outdated";
|
||||
title = "An outdated version detected (latest is " + expected + "), upgrade is highly recommended!";
|
||||
indicatorClass = "outdated";
|
||||
break;
|
||||
}
|
||||
case "stale-prerelease":
|
||||
{
|
||||
text = "" + versionLabel + " is outdated";
|
||||
title = "There is a newer canary version (" + expected + ") available, please upgrade! ";
|
||||
indicatorClass = "stale";
|
||||
break;
|
||||
}
|
||||
case "unknown":
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return {
|
||||
text,
|
||||
indicatorClass,
|
||||
title
|
||||
};
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=VersionStalenessInfo.js.map
|
||||
32
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/VersionStalenessInfo/index.js
generated
vendored
Normal file
32
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/VersionStalenessInfo/index.js
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
VersionStalenessInfo: null,
|
||||
styles: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
VersionStalenessInfo: function() {
|
||||
return _VersionStalenessInfo.VersionStalenessInfo;
|
||||
},
|
||||
styles: function() {
|
||||
return _styles.styles;
|
||||
}
|
||||
});
|
||||
const _styles = require("./styles");
|
||||
const _VersionStalenessInfo = require("./VersionStalenessInfo");
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/VersionStalenessInfo/styles.js
generated
vendored
Normal file
30
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/VersionStalenessInfo/styles.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "styles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n .nextjs-container-build-error-version-status {\n flex: 1;\n text-align: right;\n }\n .nextjs-container-build-error-version-status small {\n margin-left: var(--size-gap);\n font-size: var(--size-font-small);\n }\n .nextjs-container-build-error-version-status a {\n font-size: var(--size-font-small);\n }\n .nextjs-container-build-error-version-status span {\n display: inline-block;\n width: 10px;\n height: 10px;\n border-radius: 5px;\n background: var(--color-ansi-bright-black);\n }\n .nextjs-container-build-error-version-status span.fresh {\n background: var(--color-ansi-green);\n }\n .nextjs-container-build-error-version-status span.stale {\n background: var(--color-ansi-yellow);\n }\n .nextjs-container-build-error-version-status span.outdated {\n background: var(--color-ansi-red);\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=styles.js.map
|
||||
74
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/hot-linked-text/index.js
generated
vendored
Normal file
74
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/components/hot-linked-text/index.js
generated
vendored
Normal file
@@ -0,0 +1,74 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "HotlinkedText", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return HotlinkedText;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_default._(require("react"));
|
||||
const _magicidentifier = require("../../../../../../shared/lib/magic-identifier");
|
||||
const linkRegex = /https?:\/\/[^\s/$.?#].[^\s)'"]*/i;
|
||||
const splitRegexp = new RegExp("(" + _magicidentifier.MAGIC_IDENTIFIER_REGEX.source + "|\\s+)");
|
||||
const HotlinkedText = function HotlinkedText(props) {
|
||||
const { text, matcher } = props;
|
||||
const wordsAndWhitespaces = text.split(splitRegexp);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_jsxruntime.Fragment, {
|
||||
children: wordsAndWhitespaces.map((word, index)=>{
|
||||
if (linkRegex.test(word)) {
|
||||
const link = linkRegex.exec(word);
|
||||
const href = link[0];
|
||||
// If link matcher is present but the link doesn't match, don't turn it into a link
|
||||
if (typeof matcher === "function" && !matcher(href)) {
|
||||
return word;
|
||||
}
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_react.default.Fragment, {
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("a", {
|
||||
href: href,
|
||||
target: "_blank",
|
||||
rel: "noreferrer noopener",
|
||||
children: word
|
||||
})
|
||||
}, "link-" + index);
|
||||
}
|
||||
try {
|
||||
const decodedWord = (0, _magicidentifier.decodeMagicIdentifier)(word);
|
||||
if (decodedWord !== word) {
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("i", {
|
||||
children: [
|
||||
"{",
|
||||
decodedWord,
|
||||
"}"
|
||||
]
|
||||
}, "ident-" + index);
|
||||
}
|
||||
} catch (e) {
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("i", {
|
||||
children: [
|
||||
"{",
|
||||
word,
|
||||
" (decoding failed: ",
|
||||
"" + e,
|
||||
")",
|
||||
"}"
|
||||
]
|
||||
}, "ident-" + index);
|
||||
}
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_react.default.Fragment, {
|
||||
children: word
|
||||
}, "text-" + index);
|
||||
})
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
99
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/BuildError.js
generated
vendored
Normal file
99
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/BuildError.js
generated
vendored
Normal file
@@ -0,0 +1,99 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
BuildError: null,
|
||||
styles: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
BuildError: function() {
|
||||
return BuildError;
|
||||
},
|
||||
styles: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _Dialog = require("../components/Dialog");
|
||||
const _Overlay = require("../components/Overlay");
|
||||
const _Terminal = require("../components/Terminal");
|
||||
const _VersionStalenessInfo = require("../components/VersionStalenessInfo");
|
||||
const _nooptemplate = require("../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n .nextjs-container-errors-header > h1 {\n font-size: var(--size-font-big);\n line-height: var(--size-font-bigger);\n font-weight: bold;\n margin: var(--size-gap-double) 0;\n }\n .nextjs-container-errors-header p {\n font-size: var(--size-font-small);\n line-height: var(--size-font-big);\n white-space: pre-wrap;\n }\n .nextjs-container-errors-body footer {\n margin-top: var(--size-gap);\n }\n .nextjs-container-errors-body footer p {\n margin: 0;\n }\n\n .nextjs-container-errors-body small {\n color: var(--color-font);\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
const BuildError = function BuildError(param) {
|
||||
let { message, versionInfo } = param;
|
||||
const noop = _react.useCallback(()=>{}, []);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_Overlay.Overlay, {
|
||||
fixed: true,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_Dialog.Dialog, {
|
||||
type: "error",
|
||||
"aria-labelledby": "nextjs__container_error_label",
|
||||
"aria-describedby": "nextjs__container_error_desc",
|
||||
onClose: noop,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)(_Dialog.DialogContent, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_Dialog.DialogHeader, {
|
||||
className: "nextjs-container-errors-header",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("h1", {
|
||||
id: "nextjs__container_errors_label",
|
||||
children: "Build Error"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("p", {
|
||||
id: "nextjs__container_errors_desc",
|
||||
className: "nextjs__container_errors_desc",
|
||||
children: "Failed to compile"
|
||||
}),
|
||||
versionInfo ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_VersionStalenessInfo.VersionStalenessInfo, {
|
||||
...versionInfo
|
||||
}) : null
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_Dialog.DialogBody, {
|
||||
className: "nextjs-container-errors-body",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Terminal.Terminal, {
|
||||
content: message
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("footer", {
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("p", {
|
||||
id: "nextjs__container_build_error_desc",
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("small", {
|
||||
children: "This error occurred during the build process and can only be dismissed by fixing the error."
|
||||
})
|
||||
})
|
||||
})
|
||||
]
|
||||
})
|
||||
]
|
||||
})
|
||||
})
|
||||
});
|
||||
};
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=BuildError.js.map
|
||||
339
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/Errors.js
generated
vendored
Normal file
339
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/Errors.js
generated
vendored
Normal file
@@ -0,0 +1,339 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
Errors: null,
|
||||
styles: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
Errors: function() {
|
||||
return Errors;
|
||||
},
|
||||
styles: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = require("react");
|
||||
const _shared = require("../../shared");
|
||||
const _Dialog = require("../components/Dialog");
|
||||
const _LeftRightDialogHeader = require("../components/LeftRightDialogHeader");
|
||||
const _Overlay = require("../components/Overlay");
|
||||
const _Toast = require("../components/Toast");
|
||||
const _getErrorByType = require("../helpers/getErrorByType");
|
||||
const _nooptemplate = require("../helpers/noop-template");
|
||||
const _CloseIcon = require("../icons/CloseIcon");
|
||||
const _RuntimeError = require("./RuntimeError");
|
||||
const _VersionStalenessInfo = require("../components/VersionStalenessInfo");
|
||||
const _errorsource = require("../../../../../shared/lib/error-source");
|
||||
const _hotlinkedtext = require("../components/hot-linked-text");
|
||||
const _componentstackpseudohtml = require("./RuntimeError/component-stack-pseudo-html");
|
||||
const _hydrationerrorinfo = require("../helpers/hydration-error-info");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n .nextjs-container-errors-header > h1 {\n font-size: var(--size-font-big);\n line-height: var(--size-font-bigger);\n font-weight: bold;\n margin: calc(var(--size-gap-double) * 1.5) 0;\n color: var(--color-title-h1);\n }\n .nextjs-container-errors-header small {\n font-size: var(--size-font-small);\n color: var(--color-accents-1);\n margin-left: var(--size-gap-double);\n }\n .nextjs-container-errors-header small > span {\n font-family: var(--font-stack-monospace);\n }\n .nextjs-container-errors-header p {\n font-size: var(--size-font-small);\n line-height: var(--size-font-big);\n white-space: pre-wrap;\n }\n .nextjs__container_errors_desc {\n font-family: var(--font-stack-monospace);\n padding: var(--size-gap) var(--size-gap-double);\n border-left: 2px solid var(--color-text-color-red-1);\n margin-top: var(--size-gap);\n font-weight: bold;\n color: var(--color-text-color-red-1);\n background-color: var(--color-text-background-red-1);\n }\n p.nextjs__container_errors__notes {\n margin: var(--size-gap-double) auto;\n color: var(--color-stack-notes);\n font-weight: 600;\n font-size: 15px;\n }\n .nextjs-container-errors-header > div > small {\n margin: 0;\n margin-top: var(--size-gap-half);\n }\n .nextjs-container-errors-header > p > a {\n color: inherit;\n font-weight: bold;\n }\n .nextjs-container-errors-body > h2:not(:first-child) {\n margin-top: calc(var(--size-gap-double) + var(--size-gap));\n }\n .nextjs-container-errors-body > h2 {\n color: var(--color-title-color);\n margin-bottom: var(--size-gap);\n font-size: var(--size-font-big);\n }\n .nextjs__container_errors__component-stack {\n padding: 12px 32px;\n color: var(--color-ansi-fg);\n background: var(--color-ansi-bg);\n }\n .nextjs-toast-errors-parent {\n cursor: pointer;\n transition: transform 0.2s ease;\n }\n .nextjs-toast-errors-parent:hover {\n transform: scale(1.1);\n }\n .nextjs-toast-errors {\n display: flex;\n align-items: center;\n justify-content: flex-start;\n }\n .nextjs-toast-errors > svg {\n margin-right: var(--size-gap);\n }\n .nextjs-toast-errors-hide-button {\n margin-left: var(--size-gap-triple);\n border: none;\n background: none;\n color: var(--color-ansi-bright-white);\n padding: 0;\n transition: opacity 0.25s ease;\n opacity: 0.7;\n }\n .nextjs-toast-errors-hide-button:hover {\n opacity: 1;\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function isNextjsLink(text) {
|
||||
return text.startsWith("https://nextjs.org");
|
||||
}
|
||||
function getErrorSignature(ev) {
|
||||
const { event } = ev;
|
||||
switch(event.type){
|
||||
case _shared.ACTION_UNHANDLED_ERROR:
|
||||
case _shared.ACTION_UNHANDLED_REJECTION:
|
||||
{
|
||||
return event.reason.name + "::" + event.reason.message + "::" + event.reason.stack;
|
||||
}
|
||||
default:
|
||||
{}
|
||||
}
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
const _ = event;
|
||||
return "";
|
||||
}
|
||||
function Errors(param) {
|
||||
let { isAppDir, errors, initialDisplayState, versionInfo } = param;
|
||||
var _activeError_componentStackFrames;
|
||||
const [lookups, setLookups] = (0, _react.useState)({});
|
||||
const [readyErrors, nextError] = (0, _react.useMemo)(()=>{
|
||||
let ready = [];
|
||||
let next = null;
|
||||
// Ensure errors are displayed in the order they occurred in:
|
||||
for(let idx = 0; idx < errors.length; ++idx){
|
||||
const e = errors[idx];
|
||||
const { id } = e;
|
||||
if (id in lookups) {
|
||||
ready.push(lookups[id]);
|
||||
continue;
|
||||
}
|
||||
// Check for duplicate errors
|
||||
if (idx > 0) {
|
||||
const prev = errors[idx - 1];
|
||||
if (getErrorSignature(prev) === getErrorSignature(e)) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
next = e;
|
||||
break;
|
||||
}
|
||||
return [
|
||||
ready,
|
||||
next
|
||||
];
|
||||
}, [
|
||||
errors,
|
||||
lookups
|
||||
]);
|
||||
const isLoading = (0, _react.useMemo)(()=>{
|
||||
return readyErrors.length < 1 && Boolean(errors.length);
|
||||
}, [
|
||||
errors.length,
|
||||
readyErrors.length
|
||||
]);
|
||||
(0, _react.useEffect)(()=>{
|
||||
if (nextError == null) {
|
||||
return;
|
||||
}
|
||||
let mounted = true;
|
||||
(0, _getErrorByType.getErrorByType)(nextError, isAppDir).then((resolved)=>{
|
||||
// We don't care if the desired error changed while we were resolving,
|
||||
// thus we're not tracking it using a ref. Once the work has been done,
|
||||
// we'll store it.
|
||||
if (mounted) {
|
||||
setLookups((m)=>({
|
||||
...m,
|
||||
[resolved.id]: resolved
|
||||
}));
|
||||
}
|
||||
}, ()=>{
|
||||
// TODO: handle this, though an edge case
|
||||
});
|
||||
return ()=>{
|
||||
mounted = false;
|
||||
};
|
||||
}, [
|
||||
nextError,
|
||||
isAppDir
|
||||
]);
|
||||
const [displayState, setDisplayState] = (0, _react.useState)(initialDisplayState);
|
||||
const [activeIdx, setActiveIndex] = (0, _react.useState)(0);
|
||||
const previous = (0, _react.useCallback)(()=>setActiveIndex((v)=>Math.max(0, v - 1)), []);
|
||||
const next = (0, _react.useCallback)(()=>setActiveIndex((v)=>Math.max(0, Math.min(readyErrors.length - 1, v + 1))), [
|
||||
readyErrors.length
|
||||
]);
|
||||
const activeError = (0, _react.useMemo)(()=>{
|
||||
var _readyErrors_activeIdx;
|
||||
return (_readyErrors_activeIdx = readyErrors[activeIdx]) != null ? _readyErrors_activeIdx : null;
|
||||
}, [
|
||||
activeIdx,
|
||||
readyErrors
|
||||
]);
|
||||
// Reset component state when there are no errors to be displayed.
|
||||
// This should never happen, but lets handle it.
|
||||
(0, _react.useEffect)(()=>{
|
||||
if (errors.length < 1) {
|
||||
setLookups({});
|
||||
setDisplayState("hidden");
|
||||
setActiveIndex(0);
|
||||
}
|
||||
}, [
|
||||
errors.length
|
||||
]);
|
||||
const minimize = (0, _react.useCallback)(()=>setDisplayState("minimized"), []);
|
||||
const hide = (0, _react.useCallback)(()=>setDisplayState("hidden"), []);
|
||||
const fullscreen = (0, _react.useCallback)(()=>setDisplayState("fullscreen"), []);
|
||||
// This component shouldn't be rendered with no errors, but if it is, let's
|
||||
// handle it gracefully by rendering nothing.
|
||||
if (errors.length < 1 || activeError == null) {
|
||||
return null;
|
||||
}
|
||||
if (isLoading) {
|
||||
// TODO: better loading state
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_Overlay.Overlay, {});
|
||||
}
|
||||
if (displayState === "hidden") {
|
||||
return null;
|
||||
}
|
||||
if (displayState === "minimized") {
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_Toast.Toast, {
|
||||
className: "nextjs-toast-errors-parent",
|
||||
onClick: fullscreen,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
className: "nextjs-toast-errors",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
width: "24",
|
||||
height: "24",
|
||||
viewBox: "0 0 24 24",
|
||||
fill: "none",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("circle", {
|
||||
cx: "12",
|
||||
cy: "12",
|
||||
r: "10"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("line", {
|
||||
x1: "12",
|
||||
y1: "8",
|
||||
x2: "12",
|
||||
y2: "12"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("line", {
|
||||
x1: "12",
|
||||
y1: "16",
|
||||
x2: "12.01",
|
||||
y2: "16"
|
||||
})
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("span", {
|
||||
children: [
|
||||
readyErrors.length,
|
||||
" error",
|
||||
readyErrors.length > 1 ? "s" : ""
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("button", {
|
||||
"data-nextjs-toast-errors-hide-button": true,
|
||||
className: "nextjs-toast-errors-hide-button",
|
||||
type: "button",
|
||||
onClick: (e)=>{
|
||||
e.stopPropagation();
|
||||
hide();
|
||||
},
|
||||
"aria-label": "Hide Errors",
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_CloseIcon.CloseIcon, {})
|
||||
})
|
||||
]
|
||||
})
|
||||
});
|
||||
}
|
||||
const error = activeError.error;
|
||||
const isServerError = [
|
||||
"server",
|
||||
"edge-server"
|
||||
].includes((0, _errorsource.getErrorSource)(error) || "");
|
||||
const errorDetails = error.details || {};
|
||||
const [warningTemplate, serverContent, clientContent] = errorDetails.warning || [
|
||||
null,
|
||||
"",
|
||||
""
|
||||
];
|
||||
const hydrationErrorType = (0, _hydrationerrorinfo.getHydrationWarningType)(warningTemplate);
|
||||
const hydrationWarning = warningTemplate ? warningTemplate.replace("%s", serverContent).replace("%s", clientContent).replace("%s", "") // remove the %s for stack
|
||||
.replace(/%s$/, "") // If there's still a %s at the end, remove it
|
||||
.replace(/^Warning: /, "") : null;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_Overlay.Overlay, {
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_Dialog.Dialog, {
|
||||
type: "error",
|
||||
"aria-labelledby": "nextjs__container_errors_label",
|
||||
"aria-describedby": "nextjs__container_errors_desc",
|
||||
onClose: isServerError ? undefined : minimize,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)(_Dialog.DialogContent, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_Dialog.DialogHeader, {
|
||||
className: "nextjs-container-errors-header",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_LeftRightDialogHeader.LeftRightDialogHeader, {
|
||||
previous: activeIdx > 0 ? previous : null,
|
||||
next: activeIdx < readyErrors.length - 1 ? next : null,
|
||||
close: isServerError ? undefined : minimize,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("small", {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
children: activeIdx + 1
|
||||
}),
|
||||
" of",
|
||||
" ",
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
"data-nextjs-dialog-header-total-count": true,
|
||||
children: readyErrors.length
|
||||
}),
|
||||
" error",
|
||||
readyErrors.length < 2 ? "" : "s"
|
||||
]
|
||||
}),
|
||||
versionInfo ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_VersionStalenessInfo.VersionStalenessInfo, {
|
||||
...versionInfo
|
||||
}) : null
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("h1", {
|
||||
id: "nextjs__container_errors_label",
|
||||
children: isServerError ? "Server Error" : "Unhandled Runtime Error"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("p", {
|
||||
id: "nextjs__container_errors_desc",
|
||||
className: "nextjs__container_errors_desc",
|
||||
children: [
|
||||
error.name,
|
||||
":",
|
||||
" ",
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_hotlinkedtext.HotlinkedText, {
|
||||
text: error.message,
|
||||
matcher: isNextjsLink
|
||||
})
|
||||
]
|
||||
}),
|
||||
hydrationWarning && /*#__PURE__*/ (0, _jsxruntime.jsxs)(_jsxruntime.Fragment, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("p", {
|
||||
id: "nextjs__container_errors__notes",
|
||||
className: "nextjs__container_errors__notes",
|
||||
children: hydrationWarning
|
||||
}),
|
||||
((_activeError_componentStackFrames = activeError.componentStackFrames) == null ? void 0 : _activeError_componentStackFrames.length) ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_componentstackpseudohtml.PseudoHtmlDiff, {
|
||||
className: "nextjs__container_errors__component-stack",
|
||||
hydrationMismatchType: hydrationErrorType,
|
||||
componentStackFrames: activeError.componentStackFrames,
|
||||
firstContent: serverContent,
|
||||
secondContent: clientContent
|
||||
}) : null
|
||||
]
|
||||
}),
|
||||
isServerError ? /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("small", {
|
||||
children: "This error happened while generating the page. Any console logs will be displayed in the terminal window."
|
||||
})
|
||||
}) : undefined
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Dialog.DialogBody, {
|
||||
className: "nextjs-container-errors-body",
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_RuntimeError.RuntimeError, {
|
||||
error: activeError
|
||||
}, activeError.id.toString())
|
||||
})
|
||||
]
|
||||
})
|
||||
})
|
||||
});
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=Errors.js.map
|
||||
81
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/CallStackFrame.js
generated
vendored
Normal file
81
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/CallStackFrame.js
generated
vendored
Normal file
@@ -0,0 +1,81 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "CallStackFrame", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return CallStackFrame;
|
||||
}
|
||||
});
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _stackframe = require("../../helpers/stack-frame");
|
||||
const _useopenineditor = require("../../helpers/use-open-in-editor");
|
||||
const _hotlinkedtext = require("../../components/hot-linked-text");
|
||||
const CallStackFrame = function CallStackFrame(param) {
|
||||
let { frame } = param;
|
||||
var _frame_originalStackFrame;
|
||||
// TODO: ability to expand resolved frames
|
||||
// TODO: render error or external indicator
|
||||
const f = (_frame_originalStackFrame = frame.originalStackFrame) != null ? _frame_originalStackFrame : frame.sourceStackFrame;
|
||||
const hasSource = Boolean(frame.originalCodeFrame);
|
||||
const open = (0, _useopenineditor.useOpenInEditor)(hasSource ? {
|
||||
file: f.file,
|
||||
lineNumber: f.lineNumber,
|
||||
column: f.column
|
||||
} : undefined);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-nextjs-call-stack-frame": true,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("h3", {
|
||||
"data-nextjs-frame-expanded": Boolean(frame.expanded),
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_hotlinkedtext.HotlinkedText, {
|
||||
text: f.methodName
|
||||
})
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-has-source": hasSource ? "true" : undefined,
|
||||
tabIndex: hasSource ? 10 : undefined,
|
||||
role: hasSource ? "link" : undefined,
|
||||
onClick: open,
|
||||
title: hasSource ? "Click to open in your editor" : undefined,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
children: (0, _stackframe.getFrameSource)(f)
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
viewBox: "0 0 24 24",
|
||||
fill: "none",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("polyline", {
|
||||
points: "15 3 21 3 21 9"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("line", {
|
||||
x1: "10",
|
||||
y1: "14",
|
||||
x2: "21",
|
||||
y2: "3"
|
||||
})
|
||||
]
|
||||
})
|
||||
]
|
||||
})
|
||||
]
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=CallStackFrame.js.map
|
||||
62
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/GroupedStackFrames.js
generated
vendored
Normal file
62
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/GroupedStackFrames.js
generated
vendored
Normal file
@@ -0,0 +1,62 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "GroupedStackFrames", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return GroupedStackFrames;
|
||||
}
|
||||
});
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _CallStackFrame = require("./CallStackFrame");
|
||||
const _CollapseIcon = require("../../icons/CollapseIcon");
|
||||
const _FrameworkIcon = require("../../icons/FrameworkIcon");
|
||||
function FrameworkGroup(param) {
|
||||
let { framework, stackFrames } = param;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("details", {
|
||||
"data-nextjs-collapsed-call-stack-details": true,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("summary", {
|
||||
tabIndex: 10,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_CollapseIcon.CollapseIcon, {}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_FrameworkIcon.FrameworkIcon, {
|
||||
framework: framework
|
||||
}),
|
||||
framework === "react" ? "React" : "Next.js"
|
||||
]
|
||||
}),
|
||||
stackFrames.map((frame, index)=>/*#__PURE__*/ (0, _jsxruntime.jsx)(_CallStackFrame.CallStackFrame, {
|
||||
frame: frame
|
||||
}, "call-stack-" + index))
|
||||
]
|
||||
});
|
||||
}
|
||||
function GroupedStackFrames(param) {
|
||||
let { groupedStackFrames, show } = param;
|
||||
if (!show) return;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_jsxruntime.Fragment, {
|
||||
children: groupedStackFrames.map((stackFramesGroup, groupIndex)=>{
|
||||
// Collapse React and Next.js frames
|
||||
if (stackFramesGroup.framework) {
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)(FrameworkGroup, {
|
||||
framework: stackFramesGroup.framework,
|
||||
stackFrames: stackFramesGroup.stackFrames
|
||||
}, "call-stack-framework-group-" + groupIndex);
|
||||
}
|
||||
return(// Don't group non React and Next.js frames
|
||||
stackFramesGroup.stackFrames.map((frame, frameIndex)=>/*#__PURE__*/ (0, _jsxruntime.jsx)(_CallStackFrame.CallStackFrame, {
|
||||
frame: frame
|
||||
}, "call-stack-" + groupIndex + "-" + frameIndex)));
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=GroupedStackFrames.js.map
|
||||
186
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/component-stack-pseudo-html.js
generated
vendored
Normal file
186
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/component-stack-pseudo-html.js
generated
vendored
Normal file
@@ -0,0 +1,186 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "PseudoHtmlDiff", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return PseudoHtmlDiff;
|
||||
}
|
||||
});
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = require("react");
|
||||
const _CollapseIcon = require("../../icons/CollapseIcon");
|
||||
function getAdjacentProps(isAdj) {
|
||||
return {
|
||||
"data-nextjs-container-errors-pseudo-html--tag-adjacent": isAdj
|
||||
};
|
||||
}
|
||||
function PseudoHtmlDiff(param) {
|
||||
let { componentStackFrames, firstContent, secondContent, hydrationMismatchType, ...props } = param;
|
||||
const isHtmlTagsWarning = hydrationMismatchType === "tag";
|
||||
// For text mismatch, mismatched text will take 2 rows, so we display 4 rows of component stack
|
||||
const MAX_NON_COLLAPSED_FRAMES = isHtmlTagsWarning ? 6 : 4;
|
||||
const shouldCollapse = componentStackFrames.length > MAX_NON_COLLAPSED_FRAMES;
|
||||
const [isHtmlCollapsed, toggleCollapseHtml] = (0, _react.useState)(shouldCollapse);
|
||||
const htmlComponents = (0, _react.useMemo)(()=>{
|
||||
const tagNames = isHtmlTagsWarning ? [
|
||||
firstContent.replace(/<|>/g, ""),
|
||||
secondContent.replace(/<|>/g, "")
|
||||
] : [];
|
||||
const nestedHtmlStack = [];
|
||||
let lastText = "";
|
||||
const componentStack = componentStackFrames.map((frame)=>frame.component).reverse();
|
||||
// [child index, parent index]
|
||||
const matchedIndex = [
|
||||
-1,
|
||||
-1
|
||||
];
|
||||
if (isHtmlTagsWarning) {
|
||||
// Reverse search for the child tag
|
||||
for(let i = componentStack.length - 1; i >= 0; i--){
|
||||
if (componentStack[i] === tagNames[0]) {
|
||||
matchedIndex[0] = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
// Start searching parent tag from child tag above
|
||||
for(let i = matchedIndex[0] - 1; i >= 0; i--){
|
||||
if (componentStack[i] === tagNames[1]) {
|
||||
matchedIndex[1] = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
componentStack.forEach((component, index, componentList)=>{
|
||||
const spaces = " ".repeat(nestedHtmlStack.length * 2);
|
||||
// const prevComponent = componentList[index - 1]
|
||||
// const nextComponent = componentList[index + 1]
|
||||
// When component is the server or client tag name, highlight it
|
||||
const isHighlightedTag = isHtmlTagsWarning ? index === matchedIndex[0] || index === matchedIndex[1] : tagNames.includes(component);
|
||||
const isAdjacentTag = isHighlightedTag || Math.abs(index - matchedIndex[0]) <= 1 || Math.abs(index - matchedIndex[1]) <= 1;
|
||||
const isLastFewFrames = !isHtmlTagsWarning && index >= componentList.length - 6;
|
||||
const adjProps = getAdjacentProps(isAdjacentTag);
|
||||
if (isHtmlTagsWarning && isAdjacentTag || isLastFewFrames) {
|
||||
const codeLine = /*#__PURE__*/ (0, _jsxruntime.jsxs)("span", {
|
||||
children: [
|
||||
spaces,
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
...adjProps,
|
||||
...isHighlightedTag ? {
|
||||
"data-nextjs-container-errors-pseudo-html--tag-error": true
|
||||
} : undefined,
|
||||
children: "<" + component + ">\n"
|
||||
})
|
||||
]
|
||||
});
|
||||
lastText = component;
|
||||
const wrappedCodeLine = /*#__PURE__*/ (0, _jsxruntime.jsxs)(_react.Fragment, {
|
||||
children: [
|
||||
codeLine,
|
||||
isHighlightedTag && /*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
"data-nextjs-container-errors-pseudo-html--hint": true,
|
||||
children: spaces + "^".repeat(component.length + 2) + "\n"
|
||||
})
|
||||
]
|
||||
}, nestedHtmlStack.length);
|
||||
nestedHtmlStack.push(wrappedCodeLine);
|
||||
} else {
|
||||
if (nestedHtmlStack.length >= MAX_NON_COLLAPSED_FRAMES && isHtmlCollapsed) {
|
||||
return;
|
||||
}
|
||||
if (!isHtmlCollapsed || isLastFewFrames) {
|
||||
nestedHtmlStack.push(/*#__PURE__*/ (0, _react.createElement)("span", {
|
||||
...adjProps,
|
||||
key: nestedHtmlStack.length,
|
||||
children: [
|
||||
spaces,
|
||||
"<" + component + ">\n"
|
||||
]
|
||||
}));
|
||||
} else if (isHtmlCollapsed && lastText !== "...") {
|
||||
lastText = "...";
|
||||
nestedHtmlStack.push(/*#__PURE__*/ (0, _react.createElement)("span", {
|
||||
...adjProps,
|
||||
key: nestedHtmlStack.length,
|
||||
children: [
|
||||
spaces,
|
||||
"...\n"
|
||||
]
|
||||
}));
|
||||
}
|
||||
}
|
||||
});
|
||||
// Hydration mismatch: text or text-tag
|
||||
if (!isHtmlTagsWarning) {
|
||||
const spaces = " ".repeat(nestedHtmlStack.length * 2);
|
||||
let wrappedCodeLine;
|
||||
if (hydrationMismatchType === "text") {
|
||||
// hydration type is "text", represent [server content, client content]
|
||||
wrappedCodeLine = /*#__PURE__*/ (0, _jsxruntime.jsxs)(_react.Fragment, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
"data-nextjs-container-errors-pseudo-html--diff-remove": true,
|
||||
children: spaces + ('"' + firstContent + '"\n')
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
"data-nextjs-container-errors-pseudo-html--diff-add": true,
|
||||
children: spaces + ('"' + secondContent + '"\n')
|
||||
})
|
||||
]
|
||||
}, nestedHtmlStack.length);
|
||||
} else {
|
||||
// hydration type is "text-in-tag", represent [parent tag, mismatch content]
|
||||
wrappedCodeLine = /*#__PURE__*/ (0, _jsxruntime.jsxs)(_react.Fragment, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
"data-nextjs-container-errors-pseudo-html--tag-adjacent": true,
|
||||
children: spaces + ("<" + secondContent + ">\n")
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
||||
"data-nextjs-container-errors-pseudo-html--diff-remove": true,
|
||||
children: spaces + (' "' + firstContent + '"\n')
|
||||
})
|
||||
]
|
||||
}, nestedHtmlStack.length);
|
||||
}
|
||||
nestedHtmlStack.push(wrappedCodeLine);
|
||||
}
|
||||
return nestedHtmlStack;
|
||||
}, [
|
||||
componentStackFrames,
|
||||
isHtmlCollapsed,
|
||||
firstContent,
|
||||
secondContent,
|
||||
isHtmlTagsWarning,
|
||||
hydrationMismatchType,
|
||||
MAX_NON_COLLAPSED_FRAMES
|
||||
]);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
||||
"data-nextjs-container-errors-pseudo-html": true,
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("button", {
|
||||
tabIndex: 10,
|
||||
"data-nextjs-container-errors-pseudo-html-collapse": true,
|
||||
onClick: ()=>toggleCollapseHtml(!isHtmlCollapsed),
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_CollapseIcon.CollapseIcon, {
|
||||
collapsed: isHtmlCollapsed
|
||||
})
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("pre", {
|
||||
...props,
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("code", {
|
||||
children: htmlComponents
|
||||
})
|
||||
})
|
||||
]
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=component-stack-pseudo-html.js.map
|
||||
126
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/index.js
generated
vendored
Normal file
126
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/container/RuntimeError/index.js
generated
vendored
Normal file
@@ -0,0 +1,126 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
RuntimeError: null,
|
||||
styles: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
RuntimeError: function() {
|
||||
return RuntimeError;
|
||||
},
|
||||
styles: function() {
|
||||
return styles;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _CodeFrame = require("../../components/CodeFrame");
|
||||
const _nooptemplate = require("../../helpers/noop-template");
|
||||
const _groupstackframesbyframework = require("../../helpers/group-stack-frames-by-framework");
|
||||
const _GroupedStackFrames = require("./GroupedStackFrames");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n button[data-nextjs-data-runtime-error-collapsed-action] {\n background: none;\n border: none;\n padding: 0;\n font-size: var(--size-font-small);\n line-height: var(--size-font-bigger);\n color: var(--color-accents-3);\n }\n\n [data-nextjs-call-stack-frame]:not(:last-child),\n [data-nextjs-component-stack-frame]:not(:last-child) {\n margin-bottom: var(--size-gap-double);\n }\n\n [data-nextjs-call-stack-frame] > h3,\n [data-nextjs-component-stack-frame] > h3 {\n margin-top: 0;\n margin-bottom: var(--size-gap);\n font-family: var(--font-stack-monospace);\n font-size: var(--size-font);\n color: #222;\n }\n [data-nextjs-call-stack-frame] > h3[data-nextjs-frame-expanded='false'] {\n color: #666;\n }\n [data-nextjs-call-stack-frame] > div,\n [data-nextjs-component-stack-frame] > div {\n display: flex;\n align-items: center;\n padding-left: calc(var(--size-gap) + var(--size-gap-half));\n font-size: var(--size-font-small);\n color: #999;\n }\n [data-nextjs-call-stack-frame] > div > svg,\n [data-nextjs-component-stack-frame] > [role='link'] > svg {\n width: auto;\n height: var(--size-font-small);\n margin-left: var(--size-gap);\n flex-shrink: 0;\n\n display: none;\n }\n\n [data-nextjs-call-stack-frame] > div[data-has-source],\n [data-nextjs-component-stack-frame] > [role='link'] {\n cursor: pointer;\n }\n [data-nextjs-call-stack-frame] > div[data-has-source]:hover,\n [data-nextjs-component-stack-frame] > [role='link']:hover {\n text-decoration: underline dotted;\n }\n [data-nextjs-call-stack-frame] > div[data-has-source] > svg,\n [data-nextjs-component-stack-frame] > [role='link'] > svg {\n display: unset;\n }\n\n [data-nextjs-call-stack-framework-icon] {\n margin-right: var(--size-gap);\n }\n [data-nextjs-call-stack-framework-icon='next'] > mask {\n mask-type: alpha;\n }\n [data-nextjs-call-stack-framework-icon='react'] {\n color: rgb(20, 158, 202);\n }\n [data-nextjs-collapsed-call-stack-details][open]\n [data-nextjs-call-stack-chevron-icon] {\n transform: rotate(90deg);\n }\n [data-nextjs-collapsed-call-stack-details] summary {\n display: flex;\n align-items: center;\n margin-bottom: var(--size-gap);\n list-style: none;\n }\n [data-nextjs-collapsed-call-stack-details] summary::-webkit-details-marker {\n display: none;\n }\n\n [data-nextjs-collapsed-call-stack-details] h3 {\n color: #666;\n }\n [data-nextjs-collapsed-call-stack-details] [data-nextjs-call-stack-frame] {\n margin-bottom: var(--size-gap-double);\n }\n\n [data-nextjs-container-errors-pseudo-html] {\n position: relative;\n }\n [data-nextjs-container-errors-pseudo-html-collapse] {\n position: absolute;\n left: 10px;\n top: 10px;\n color: inherit;\n background: none;\n border: none;\n padding: 0;\n }\n [data-nextjs-container-errors-pseudo-html--diff-add] {\n color: var(--color-ansi-green);\n }\n [data-nextjs-container-errors-pseudo-html--diff-remove] {\n color: var(--color-ansi-red);\n }\n [data-nextjs-container-errors-pseudo-html--tag-error] {\n color: var(--color-ansi-red);\n font-weight: bold;\n }\n /* hide but text are still accessible in DOM */\n [data-nextjs-container-errors-pseudo-html--hint] {\n display: inline-block;\n font-size: 0;\n }\n [data-nextjs-container-errors-pseudo-html--tag-adjacent='false'] {\n color: var(--color-accents-1);\n }\n"
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function RuntimeError(param) {
|
||||
let { error } = param;
|
||||
const { firstFrame, allLeadingFrames, allCallStackFrames } = _react.useMemo(()=>{
|
||||
const filteredFrames = error.frames.filter((f)=>{
|
||||
var _f_sourceStackFrame_file;
|
||||
return !(f.sourceStackFrame.file === "<anonymous>" && [
|
||||
"stringify",
|
||||
"<unknown>"
|
||||
].includes(f.sourceStackFrame.methodName)) && !((_f_sourceStackFrame_file = f.sourceStackFrame.file) == null ? void 0 : _f_sourceStackFrame_file.startsWith("node:internal"));
|
||||
});
|
||||
const firstFirstPartyFrameIndex = filteredFrames.findIndex((entry)=>entry.expanded && Boolean(entry.originalCodeFrame) && Boolean(entry.originalStackFrame));
|
||||
var _filteredFrames_firstFirstPartyFrameIndex;
|
||||
return {
|
||||
firstFrame: (_filteredFrames_firstFirstPartyFrameIndex = filteredFrames[firstFirstPartyFrameIndex]) != null ? _filteredFrames_firstFirstPartyFrameIndex : null,
|
||||
allLeadingFrames: firstFirstPartyFrameIndex < 0 ? [] : filteredFrames.slice(0, firstFirstPartyFrameIndex),
|
||||
allCallStackFrames: filteredFrames.slice(firstFirstPartyFrameIndex + 1)
|
||||
};
|
||||
}, [
|
||||
error.frames
|
||||
]);
|
||||
const [all, setAll] = _react.useState(firstFrame == null);
|
||||
const { canShowMore, leadingFramesGroupedByFramework, stackFramesGroupedByFramework } = _react.useMemo(()=>{
|
||||
const leadingFrames = allLeadingFrames.filter((f)=>f.expanded || all);
|
||||
const visibleCallStackFrames = allCallStackFrames.filter((f)=>f.expanded || all);
|
||||
return {
|
||||
canShowMore: allCallStackFrames.length !== visibleCallStackFrames.length || all && firstFrame != null,
|
||||
stackFramesGroupedByFramework: (0, _groupstackframesbyframework.groupStackFramesByFramework)(allCallStackFrames),
|
||||
leadingFramesGroupedByFramework: (0, _groupstackframesbyframework.groupStackFramesByFramework)(leadingFrames)
|
||||
};
|
||||
}, [
|
||||
all,
|
||||
allCallStackFrames,
|
||||
allLeadingFrames,
|
||||
firstFrame
|
||||
]);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(_react.Fragment, {
|
||||
children: [
|
||||
firstFrame ? /*#__PURE__*/ (0, _jsxruntime.jsxs)(_react.Fragment, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("h2", {
|
||||
children: "Source"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_GroupedStackFrames.GroupedStackFrames, {
|
||||
groupedStackFrames: leadingFramesGroupedByFramework,
|
||||
show: all
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_CodeFrame.CodeFrame, {
|
||||
stackFrame: firstFrame.originalStackFrame,
|
||||
codeFrame: firstFrame.originalCodeFrame
|
||||
})
|
||||
]
|
||||
}) : undefined,
|
||||
stackFramesGroupedByFramework.length ? /*#__PURE__*/ (0, _jsxruntime.jsxs)(_react.Fragment, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("h2", {
|
||||
children: "Call Stack"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_GroupedStackFrames.GroupedStackFrames, {
|
||||
groupedStackFrames: stackFramesGroupedByFramework,
|
||||
show: all
|
||||
})
|
||||
]
|
||||
}) : undefined,
|
||||
canShowMore ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_react.Fragment, {
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)("button", {
|
||||
tabIndex: 10,
|
||||
"data-nextjs-data-runtime-error-collapsed-action": true,
|
||||
type: "button",
|
||||
onClick: ()=>setAll(!all),
|
||||
children: [
|
||||
all ? "Hide" : "Show",
|
||||
" collapsed frames"
|
||||
]
|
||||
})
|
||||
}) : undefined
|
||||
]
|
||||
});
|
||||
}
|
||||
const styles = (0, _nooptemplate.noop)(_templateObject());
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
||||
164
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/format-webpack-messages.js
generated
vendored
Normal file
164
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/format-webpack-messages.js
generated
vendored
Normal file
@@ -0,0 +1,164 @@
|
||||
/**
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2015-present, Facebook, Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
*/ "use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "default", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return formatWebpackMessages;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _stripansi = /*#__PURE__*/ _interop_require_default._(require("next/dist/compiled/strip-ansi"));
|
||||
// This file is based on https://github.com/facebook/create-react-app/blob/7b1a32be6ec9f99a6c9a3c66813f3ac09c4736b9/packages/react-dev-utils/formatWebpackMessages.js
|
||||
// It's been edited to remove chalk and CRA-specific logic
|
||||
const friendlySyntaxErrorLabel = "Syntax error:";
|
||||
const WEBPACK_BREAKING_CHANGE_POLYFILLS = "\n\nBREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.";
|
||||
function isLikelyASyntaxError(message) {
|
||||
return (0, _stripansi.default)(message).includes(friendlySyntaxErrorLabel);
|
||||
}
|
||||
let hadMissingSassError = false;
|
||||
// Cleans up webpack error messages.
|
||||
function formatMessage(message, verbose, importTraceNote) {
|
||||
// TODO: Replace this once webpack 5 is stable
|
||||
if (typeof message === "object" && message.message) {
|
||||
const filteredModuleTrace = message.moduleTrace && message.moduleTrace.filter((trace)=>!/next-(middleware|client-pages|route|edge-function)-loader\.js/.test(trace.originName));
|
||||
let body = message.message;
|
||||
const breakingChangeIndex = body.indexOf(WEBPACK_BREAKING_CHANGE_POLYFILLS);
|
||||
if (breakingChangeIndex >= 0) {
|
||||
body = body.slice(0, breakingChangeIndex);
|
||||
}
|
||||
message = (message.moduleName ? (0, _stripansi.default)(message.moduleName) + "\n" : "") + (message.file ? (0, _stripansi.default)(message.file) + "\n" : "") + body + (message.details && verbose ? "\n" + message.details : "") + (filteredModuleTrace && filteredModuleTrace.length ? (importTraceNote || "\n\nImport trace for requested module:") + filteredModuleTrace.map((trace)=>"\n" + trace.moduleName).join("") : "") + (message.stack && verbose ? "\n" + message.stack : "");
|
||||
}
|
||||
let lines = message.split("\n");
|
||||
// Strip Webpack-added headers off errors/warnings
|
||||
// https://github.com/webpack/webpack/blob/master/lib/ModuleError.js
|
||||
lines = lines.filter((line)=>!/Module [A-z ]+\(from/.test(line));
|
||||
// Transform parsing error into syntax error
|
||||
// TODO: move this to our ESLint formatter?
|
||||
lines = lines.map((line)=>{
|
||||
const parsingError = /Line (\d+):(?:(\d+):)?\s*Parsing error: (.+)$/.exec(line);
|
||||
if (!parsingError) {
|
||||
return line;
|
||||
}
|
||||
const [, errorLine, errorColumn, errorMessage] = parsingError;
|
||||
return friendlySyntaxErrorLabel + " " + errorMessage + " (" + errorLine + ":" + errorColumn + ")";
|
||||
});
|
||||
message = lines.join("\n");
|
||||
// Smoosh syntax errors (commonly found in CSS)
|
||||
message = message.replace(/SyntaxError\s+\((\d+):(\d+)\)\s*(.+?)\n/g, "" + friendlySyntaxErrorLabel + " $3 ($1:$2)\n");
|
||||
// Clean up export errors
|
||||
message = message.replace(/^.*export '(.+?)' was not found in '(.+?)'.*$/gm, "Attempted import error: '$1' is not exported from '$2'.");
|
||||
message = message.replace(/^.*export 'default' \(imported as '(.+?)'\) was not found in '(.+?)'.*$/gm, "Attempted import error: '$2' does not contain a default export (imported as '$1').");
|
||||
message = message.replace(/^.*export '(.+?)' \(imported as '(.+?)'\) was not found in '(.+?)'.*$/gm, "Attempted import error: '$1' is not exported from '$3' (imported as '$2').");
|
||||
lines = message.split("\n");
|
||||
// Remove leading newline
|
||||
if (lines.length > 2 && lines[1].trim() === "") {
|
||||
lines.splice(1, 1);
|
||||
}
|
||||
// Cleans up verbose "module not found" messages for files and packages.
|
||||
if (lines[1] && lines[1].indexOf("Module not found: ") === 0) {
|
||||
lines = [
|
||||
lines[0],
|
||||
lines[1].replace("Error: ", "").replace("Module not found: Cannot find file:", "Cannot find file:"),
|
||||
...lines.slice(2)
|
||||
];
|
||||
}
|
||||
// Add helpful message for users trying to use Sass for the first time
|
||||
if (lines[1] && lines[1].match(/Cannot find module.+sass/)) {
|
||||
// ./file.module.scss (<<loader info>>) => ./file.module.scss
|
||||
const firstLine = lines[0].split("!");
|
||||
lines[0] = firstLine[firstLine.length - 1];
|
||||
lines[1] = "To use Next.js' built-in Sass support, you first need to install `sass`.\n";
|
||||
lines[1] += "Run `npm i sass` or `yarn add sass` inside your workspace.\n";
|
||||
lines[1] += "\nLearn more: https://nextjs.org/docs/messages/install-sass";
|
||||
// dispose of unhelpful stack trace
|
||||
lines = lines.slice(0, 2);
|
||||
hadMissingSassError = true;
|
||||
} else if (hadMissingSassError && message.match(/(sass-loader|resolve-url-loader: CSS error)/)) {
|
||||
// dispose of unhelpful stack trace following missing sass module
|
||||
lines = [];
|
||||
}
|
||||
if (!verbose) {
|
||||
message = lines.join("\n");
|
||||
// Internal stacks are generally useless so we strip them... with the
|
||||
// exception of stacks containing `webpack:` because they're normally
|
||||
// from user code generated by Webpack. For more information see
|
||||
// https://github.com/facebook/create-react-app/pull/1050
|
||||
message = message.replace(/^\s*at\s((?!webpack:).)*:\d+:\d+[\s)]*(\n|$)/gm, "") // at ... ...:x:y
|
||||
;
|
||||
message = message.replace(/^\s*at\s<anonymous>(\n|$)/gm, "") // at <anonymous>
|
||||
;
|
||||
message = message.replace(/File was processed with these loaders:\n(.+[\\/](next[\\/]dist[\\/].+|@next[\\/]react-refresh-utils[\\/]loader)\.js\n)*You may need an additional loader to handle the result of these loaders.\n/g, "");
|
||||
lines = message.split("\n");
|
||||
}
|
||||
// Remove duplicated newlines
|
||||
lines = lines.filter((line, index, arr)=>index === 0 || line.trim() !== "" || line.trim() !== arr[index - 1].trim());
|
||||
// Reassemble the message
|
||||
message = lines.join("\n");
|
||||
return message.trim();
|
||||
}
|
||||
function formatWebpackMessages(json, verbose) {
|
||||
const formattedErrors = json.errors.map((message)=>{
|
||||
const isUnknownNextFontError = message.message.includes("An error occurred in `next/font`.");
|
||||
return formatMessage(message, isUnknownNextFontError || verbose);
|
||||
});
|
||||
const formattedWarnings = json.warnings.map((message)=>{
|
||||
return formatMessage(message, verbose);
|
||||
});
|
||||
// Reorder errors to put the most relevant ones first.
|
||||
let reactServerComponentsError = -1;
|
||||
for(let i = 0; i < formattedErrors.length; i++){
|
||||
const error = formattedErrors[i];
|
||||
if (error.includes("ReactServerComponentsError")) {
|
||||
reactServerComponentsError = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
// Move the reactServerComponentsError to the top if it exists
|
||||
if (reactServerComponentsError !== -1) {
|
||||
const error = formattedErrors.splice(reactServerComponentsError, 1);
|
||||
formattedErrors.unshift(error[0]);
|
||||
}
|
||||
const result = {
|
||||
...json,
|
||||
errors: formattedErrors,
|
||||
warnings: formattedWarnings
|
||||
};
|
||||
if (!verbose && result.errors.some(isLikelyASyntaxError)) {
|
||||
// If there are any syntax errors, show just them.
|
||||
result.errors = result.errors.filter(isLikelyASyntaxError);
|
||||
result.warnings = [];
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=format-webpack-messages.js.map
|
||||
47
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/getErrorByType.js
generated
vendored
Normal file
47
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/getErrorByType.js
generated
vendored
Normal file
@@ -0,0 +1,47 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "getErrorByType", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return getErrorByType;
|
||||
}
|
||||
});
|
||||
const _shared = require("../../shared");
|
||||
const _stackframe = require("./stack-frame");
|
||||
const _errorsource = require("../../../../../shared/lib/error-source");
|
||||
async function getErrorByType(ev, isAppDir) {
|
||||
const { id, event } = ev;
|
||||
switch(event.type){
|
||||
case _shared.ACTION_UNHANDLED_ERROR:
|
||||
case _shared.ACTION_UNHANDLED_REJECTION:
|
||||
{
|
||||
const readyRuntimeError = {
|
||||
id,
|
||||
runtime: true,
|
||||
error: event.reason,
|
||||
frames: await (0, _stackframe.getOriginalStackFrames)(event.frames, (0, _errorsource.getErrorSource)(event.reason), isAppDir, event.reason.toString())
|
||||
};
|
||||
if (event.type === _shared.ACTION_UNHANDLED_ERROR) {
|
||||
readyRuntimeError.componentStackFrames = event.componentStackFrames;
|
||||
}
|
||||
return readyRuntimeError;
|
||||
}
|
||||
default:
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
const _ = event;
|
||||
throw new Error("type system invariant violation");
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=getErrorByType.js.map
|
||||
44
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/getRawSourceMap.js
generated
vendored
Normal file
44
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/getRawSourceMap.js
generated
vendored
Normal file
@@ -0,0 +1,44 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "getRawSourceMap", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return getRawSourceMap;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _datauritobuffer = /*#__PURE__*/ _interop_require_default._(require("next/dist/compiled/data-uri-to-buffer"));
|
||||
const _getSourceMapUrl = require("./getSourceMapUrl");
|
||||
function getRawSourceMap(fileContents) {
|
||||
const sourceUrl = (0, _getSourceMapUrl.getSourceMapUrl)(fileContents);
|
||||
if (!(sourceUrl == null ? void 0 : sourceUrl.startsWith("data:"))) {
|
||||
return null;
|
||||
}
|
||||
let buffer;
|
||||
try {
|
||||
buffer = (0, _datauritobuffer.default)(sourceUrl);
|
||||
} catch (err) {
|
||||
console.error("Failed to parse source map URL:", err);
|
||||
return null;
|
||||
}
|
||||
if (buffer.type !== "application/json") {
|
||||
console.error("Unknown source map type: " + buffer.typeFull + ".");
|
||||
return null;
|
||||
}
|
||||
try {
|
||||
return JSON.parse(buffer.toString());
|
||||
} catch (e) {
|
||||
console.error("Failed to parse source map.");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=getRawSourceMap.js.map
|
||||
33
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/getSourceMapUrl.js
generated
vendored
Normal file
33
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/getSourceMapUrl.js
generated
vendored
Normal file
@@ -0,0 +1,33 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "getSourceMapUrl", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return getSourceMapUrl;
|
||||
}
|
||||
});
|
||||
function getSourceMapUrl(fileContents) {
|
||||
const regex = /\/\/[#@] ?sourceMappingURL=([^\s'"]+)\s*$/gm;
|
||||
let match = null;
|
||||
for(;;){
|
||||
let next = regex.exec(fileContents);
|
||||
if (next == null) {
|
||||
break;
|
||||
}
|
||||
match = next;
|
||||
}
|
||||
if (!(match && match[1])) {
|
||||
return null;
|
||||
}
|
||||
return match[1].toString();
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=getSourceMapUrl.js.map
|
||||
36
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/group-stack-frames-by-framework.js
generated
vendored
Normal file
36
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/group-stack-frames-by-framework.js
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "groupStackFramesByFramework", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return groupStackFramesByFramework;
|
||||
}
|
||||
});
|
||||
function groupStackFramesByFramework(stackFrames) {
|
||||
const stackFramesGroupedByFramework = [];
|
||||
for (const stackFrame of stackFrames){
|
||||
const currentGroup = stackFramesGroupedByFramework[stackFramesGroupedByFramework.length - 1];
|
||||
const framework = stackFrame.sourcePackage;
|
||||
if (currentGroup && currentGroup.framework === framework) {
|
||||
currentGroup.stackFrames.push(stackFrame);
|
||||
} else {
|
||||
stackFramesGroupedByFramework.push({
|
||||
framework: framework,
|
||||
stackFrames: [
|
||||
stackFrame
|
||||
]
|
||||
});
|
||||
}
|
||||
}
|
||||
return stackFramesGroupedByFramework;
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=group-stack-frames-by-framework.js.map
|
||||
77
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/hydration-error-info.js
generated
vendored
Normal file
77
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/hydration-error-info.js
generated
vendored
Normal file
@@ -0,0 +1,77 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
getHydrationWarningType: null,
|
||||
hydrationErrorState: null,
|
||||
patchConsoleError: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
getHydrationWarningType: function() {
|
||||
return getHydrationWarningType;
|
||||
},
|
||||
hydrationErrorState: function() {
|
||||
return hydrationErrorState;
|
||||
},
|
||||
patchConsoleError: function() {
|
||||
return patchConsoleError;
|
||||
}
|
||||
});
|
||||
const getHydrationWarningType = (msg)=>{
|
||||
if (isHtmlTagsWarning(msg)) return "tag";
|
||||
if (isTextInTagsMismatchWarning(msg)) return "text-in-tag";
|
||||
return "text";
|
||||
};
|
||||
const isHtmlTagsWarning = (msg)=>Boolean(msg && htmlTagsWarnings.has(msg));
|
||||
const isTextMismatchWarning = (msg)=>textMismatchWarning === msg;
|
||||
const isTextInTagsMismatchWarning = (msg)=>Boolean(msg && textAndTagsMismatchWarnings.has(msg));
|
||||
const isKnownHydrationWarning = (msg)=>isHtmlTagsWarning(msg) || isTextInTagsMismatchWarning(msg) || isTextMismatchWarning(msg);
|
||||
const hydrationErrorState = {};
|
||||
// https://github.com/facebook/react/blob/main/packages/react-dom/src/__tests__/ReactDOMHydrationDiff-test.js used as a reference
|
||||
const htmlTagsWarnings = new Set([
|
||||
'Warning: Cannot render a sync or defer <script> outside the main document without knowing its order. Try adding async="" or moving it into the root <head> tag.%s',
|
||||
"Warning: In HTML, %s cannot be a child of <%s>.%s\nThis will cause a hydration error.%s",
|
||||
"Warning: In HTML, %s cannot be a descendant of <%s>.\nThis will cause a hydration error.%s",
|
||||
"Warning: In HTML, text nodes cannot be a child of <%s>.\nThis will cause a hydration error.",
|
||||
"Warning: In HTML, whitespace text nodes cannot be a child of <%s>. Make sure you don't have any extra whitespace between tags on each line of your source code.\nThis will cause a hydration error.",
|
||||
"Warning: Expected server HTML to contain a matching <%s> in <%s>.%s",
|
||||
"Warning: Did not expect server HTML to contain a <%s> in <%s>.%s"
|
||||
]);
|
||||
const textAndTagsMismatchWarnings = new Set([
|
||||
'Warning: Expected server HTML to contain a matching text node for "%s" in <%s>.%s',
|
||||
'Warning: Did not expect server HTML to contain the text node "%s" in <%s>.%s'
|
||||
]);
|
||||
const textMismatchWarning = 'Warning: Text content did not match. Server: "%s" Client: "%s"%s';
|
||||
function patchConsoleError() {
|
||||
const prev = console.error;
|
||||
console.error = function(msg, serverContent, clientContent, componentStack) {
|
||||
if (isKnownHydrationWarning(msg)) {
|
||||
hydrationErrorState.warning = [
|
||||
// remove the last %s from the message
|
||||
msg,
|
||||
serverContent,
|
||||
clientContent
|
||||
];
|
||||
hydrationErrorState.componentStack = componentStack;
|
||||
hydrationErrorState.serverContent = serverContent;
|
||||
hydrationErrorState.clientContent = clientContent;
|
||||
}
|
||||
// @ts-expect-error argument is defined
|
||||
prev.apply(console, arguments);
|
||||
};
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=hydration-error-info.js.map
|
||||
404
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/launchEditor.js
generated
vendored
Normal file
404
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/launchEditor.js
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
75
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/nodeStackFrames.js
generated
vendored
Normal file
75
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/nodeStackFrames.js
generated
vendored
Normal file
@@ -0,0 +1,75 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
getFilesystemFrame: null,
|
||||
getServerError: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
getFilesystemFrame: function() {
|
||||
return getFilesystemFrame;
|
||||
},
|
||||
getServerError: function() {
|
||||
return getServerError;
|
||||
}
|
||||
});
|
||||
const _stacktraceparser = require("next/dist/compiled/stacktrace-parser");
|
||||
const _errorsource = require("../../../../../shared/lib/error-source");
|
||||
function getFilesystemFrame(frame) {
|
||||
const f = {
|
||||
...frame
|
||||
};
|
||||
if (typeof f.file === "string") {
|
||||
if (// Posix:
|
||||
f.file.startsWith("/") || // Win32:
|
||||
/^[a-z]:\\/i.test(f.file) || // Win32 UNC:
|
||||
f.file.startsWith("\\\\")) {
|
||||
f.file = "file://" + f.file;
|
||||
}
|
||||
}
|
||||
return f;
|
||||
}
|
||||
function getServerError(error, type) {
|
||||
let n;
|
||||
try {
|
||||
throw new Error(error.message);
|
||||
} catch (e) {
|
||||
n = e;
|
||||
}
|
||||
n.name = error.name;
|
||||
try {
|
||||
n.stack = n.toString() + "\n" + (0, _stacktraceparser.parse)(error.stack).map(getFilesystemFrame).map((f)=>{
|
||||
let str = " at " + f.methodName;
|
||||
if (f.file) {
|
||||
let loc = f.file;
|
||||
if (f.lineNumber) {
|
||||
loc += ":" + f.lineNumber;
|
||||
if (f.column) {
|
||||
loc += ":" + f.column;
|
||||
}
|
||||
}
|
||||
str += " (" + loc + ")";
|
||||
}
|
||||
return str;
|
||||
}).join("\n");
|
||||
} catch (e) {
|
||||
n.stack = error.stack;
|
||||
}
|
||||
(0, _errorsource.decorateServerError)(n, type);
|
||||
return n;
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=nodeStackFrames.js.map
|
||||
25
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/noop-template.js
generated
vendored
Normal file
25
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/noop-template.js
generated
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "noop", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return noop;
|
||||
}
|
||||
});
|
||||
function noop(strings) {
|
||||
for(var _len = arguments.length, keys = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++){
|
||||
keys[_key - 1] = arguments[_key];
|
||||
}
|
||||
const lastIndex = strings.length - 1;
|
||||
return strings.slice(0, lastIndex).reduce((p, s, i)=>p + s + keys[i], "") + strings[lastIndex];
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=noop-template.js.map
|
||||
98
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/parse-component-stack.js
generated
vendored
Normal file
98
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/parse-component-stack.js
generated
vendored
Normal file
@@ -0,0 +1,98 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "parseComponentStack", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return parseComponentStack;
|
||||
}
|
||||
});
|
||||
var LocationType;
|
||||
(function(LocationType) {
|
||||
LocationType["FILE"] = "file";
|
||||
LocationType["WEBPACK_INTERNAL"] = "webpack-internal";
|
||||
LocationType["HTTP"] = "http";
|
||||
LocationType["PROTOCOL_RELATIVE"] = "protocol-relative";
|
||||
LocationType["UNKNOWN"] = "unknown";
|
||||
})(LocationType || (LocationType = {}));
|
||||
/**
|
||||
* Get the type of frame line based on the location
|
||||
*/ function getLocationType(location) {
|
||||
if (location.startsWith("file://")) {
|
||||
return "file";
|
||||
}
|
||||
if (location.startsWith("webpack-internal://")) {
|
||||
return "webpack-internal";
|
||||
}
|
||||
if (location.startsWith("http://") || location.startsWith("https://")) {
|
||||
return "http";
|
||||
}
|
||||
if (location.startsWith("//")) {
|
||||
return "protocol-relative";
|
||||
}
|
||||
return "unknown";
|
||||
}
|
||||
function parseStackFrameLocation(location) {
|
||||
const locationType = getLocationType(location);
|
||||
const modulePath = location == null ? void 0 : location.replace(/^(webpack-internal:\/\/\/|file:\/\/)(\(.*\)\/)?/, "");
|
||||
var _modulePath_match;
|
||||
const [, file, lineNumber, column] = (_modulePath_match = modulePath == null ? void 0 : modulePath.match(/^(.+):(\d+):(\d+)/)) != null ? _modulePath_match : [];
|
||||
switch(locationType){
|
||||
case "file":
|
||||
case "webpack-internal":
|
||||
return {
|
||||
canOpenInEditor: true,
|
||||
file,
|
||||
lineNumber: lineNumber ? Number(lineNumber) : undefined,
|
||||
column: column ? Number(column) : undefined
|
||||
};
|
||||
// When the location is a URL we only show the file
|
||||
// TODO: Resolve http(s) URLs through sourcemaps
|
||||
case "http":
|
||||
case "protocol-relative":
|
||||
case "unknown":
|
||||
default:
|
||||
{
|
||||
return {
|
||||
canOpenInEditor: false
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
function parseComponentStack(componentStack) {
|
||||
const componentStackFrames = [];
|
||||
for (const line of componentStack.trim().split("\n")){
|
||||
// Get component and file from the component stack line
|
||||
const match = /at ([^ ]+)( \((.*)\))?/.exec(line);
|
||||
if (match == null ? void 0 : match[1]) {
|
||||
const component = match[1];
|
||||
const location = match[3];
|
||||
if (!location) {
|
||||
componentStackFrames.push({
|
||||
canOpenInEditor: false,
|
||||
component
|
||||
});
|
||||
continue;
|
||||
}
|
||||
// Stop parsing the component stack if we reach a Next.js component
|
||||
if (location == null ? void 0 : location.includes("next/dist")) {
|
||||
break;
|
||||
}
|
||||
const frameLocation = parseStackFrameLocation(location);
|
||||
componentStackFrames.push({
|
||||
component,
|
||||
...frameLocation
|
||||
});
|
||||
}
|
||||
}
|
||||
return componentStackFrames;
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=parse-component-stack.js.map
|
||||
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/parseStack.js
generated
vendored
Normal file
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/parseStack.js
generated
vendored
Normal file
@@ -0,0 +1,37 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "parseStack", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return parseStack;
|
||||
}
|
||||
});
|
||||
const _stacktraceparser = require("next/dist/compiled/stacktrace-parser");
|
||||
const regexNextStatic = /\/_next(\/static\/.+)/;
|
||||
function parseStack(stack) {
|
||||
const frames = (0, _stacktraceparser.parse)(stack);
|
||||
return frames.map((frame)=>{
|
||||
try {
|
||||
const url = new URL(frame.file);
|
||||
const res = regexNextStatic.exec(url.pathname);
|
||||
if (res) {
|
||||
var _process_env___NEXT_DIST_DIR_replace, _process_env___NEXT_DIST_DIR;
|
||||
const distDir = (_process_env___NEXT_DIST_DIR = process.env.__NEXT_DIST_DIR) == null ? void 0 : (_process_env___NEXT_DIST_DIR_replace = _process_env___NEXT_DIST_DIR.replace(/\\/g, "/")) == null ? void 0 : _process_env___NEXT_DIST_DIR_replace.replace(/\/$/, "");
|
||||
if (distDir) {
|
||||
frame.file = "file://" + distDir.concat(res.pop()) + url.search;
|
||||
}
|
||||
}
|
||||
} catch (e) {}
|
||||
return frame;
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=parseStack.js.map
|
||||
145
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/stack-frame.js
generated
vendored
Normal file
145
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/stack-frame.js
generated
vendored
Normal file
@@ -0,0 +1,145 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
getFrameSource: null,
|
||||
getOriginalStackFrames: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
getFrameSource: function() {
|
||||
return getFrameSource;
|
||||
},
|
||||
getOriginalStackFrames: function() {
|
||||
return getOriginalStackFrames;
|
||||
}
|
||||
});
|
||||
function getOriginalStackFrame(source, type, isAppDir, errorMessage) {
|
||||
var _source_file, _source_file1;
|
||||
async function _getOriginalStackFrame() {
|
||||
var /* collapsed */ _source_file, _body_originalStackFrame_file, _body_originalStackFrame, _body_originalStackFrame_file1, _body_originalStackFrame1;
|
||||
const params = new URLSearchParams();
|
||||
params.append("isServer", String(type === "server"));
|
||||
params.append("isEdgeServer", String(type === "edge-server"));
|
||||
params.append("isAppDirectory", String(isAppDir));
|
||||
params.append("errorMessage", errorMessage);
|
||||
for(const key in source){
|
||||
var _source_key;
|
||||
params.append(key, ((_source_key = source[key]) != null ? _source_key : "").toString());
|
||||
}
|
||||
const controller = new AbortController();
|
||||
const tm = setTimeout(()=>controller.abort(), 3000);
|
||||
const res = await self.fetch((process.env.__NEXT_ROUTER_BASEPATH || "") + "/__nextjs_original-stack-frame?" + params.toString(), {
|
||||
signal: controller.signal
|
||||
}).finally(()=>{
|
||||
clearTimeout(tm);
|
||||
});
|
||||
if (!res.ok || res.status === 204) {
|
||||
return Promise.reject(new Error(await res.text()));
|
||||
}
|
||||
const body = await res.json();
|
||||
var _ref;
|
||||
return {
|
||||
error: false,
|
||||
reason: null,
|
||||
external: false,
|
||||
expanded: !Boolean((_ref = ((_source_file = source.file) == null ? void 0 : _source_file.includes("node_modules")) || ((_body_originalStackFrame = body.originalStackFrame) == null ? void 0 : (_body_originalStackFrame_file = _body_originalStackFrame.file) == null ? void 0 : _body_originalStackFrame_file.includes("node_modules")) || ((_body_originalStackFrame1 = body.originalStackFrame) == null ? void 0 : (_body_originalStackFrame_file1 = _body_originalStackFrame1.file) == null ? void 0 : _body_originalStackFrame_file1.startsWith("[turbopack]/"))) != null ? _ref : true),
|
||||
sourceStackFrame: source,
|
||||
originalStackFrame: body.originalStackFrame,
|
||||
originalCodeFrame: body.originalCodeFrame || null,
|
||||
sourcePackage: body.sourcePackage
|
||||
};
|
||||
}
|
||||
if (source.file === "<anonymous>" || ((_source_file = source.file) == null ? void 0 : _source_file.match(/^node:/)) || ((_source_file1 = source.file) == null ? void 0 : _source_file1.match(/https?:\/\//))) {
|
||||
return Promise.resolve({
|
||||
error: false,
|
||||
reason: null,
|
||||
external: true,
|
||||
expanded: false,
|
||||
sourceStackFrame: source,
|
||||
originalStackFrame: null,
|
||||
originalCodeFrame: null,
|
||||
sourcePackage: null
|
||||
});
|
||||
}
|
||||
return _getOriginalStackFrame().catch((err)=>{
|
||||
var _err_message, _ref;
|
||||
return {
|
||||
error: true,
|
||||
reason: (_ref = (_err_message = err == null ? void 0 : err.message) != null ? _err_message : err == null ? void 0 : err.toString()) != null ? _ref : "Unknown Error",
|
||||
external: false,
|
||||
expanded: false,
|
||||
sourceStackFrame: source,
|
||||
originalStackFrame: null,
|
||||
originalCodeFrame: null,
|
||||
sourcePackage: null
|
||||
};
|
||||
});
|
||||
}
|
||||
function getOriginalStackFrames(frames, type, isAppDir, errorMessage) {
|
||||
return Promise.all(frames.map((frame)=>getOriginalStackFrame(frame, type, isAppDir, errorMessage)));
|
||||
}
|
||||
const webpackRegExes = [
|
||||
/^webpack-internal:\/\/\/(\.)?(\((\w+)\))?/,
|
||||
/^(webpack:\/\/\/(\.)?|webpack:\/\/(_N_E\/)?)(\((\w+)\))?/
|
||||
];
|
||||
function isWebpackBundled(file) {
|
||||
return webpackRegExes.some((regEx)=>regEx.test(file));
|
||||
}
|
||||
/**
|
||||
* Format the webpack internal id to original file path
|
||||
* webpack-internal:///./src/hello.tsx => ./src/hello.tsx
|
||||
* webpack://_N_E/./src/hello.tsx => ./src/hello.tsx
|
||||
* webpack://./src/hello.tsx => ./src/hello.tsx
|
||||
* webpack:///./src/hello.tsx => ./src/hello.tsx
|
||||
*/ function formatFrameSourceFile(file) {
|
||||
for (const regex of webpackRegExes)file = file.replace(regex, "");
|
||||
return file;
|
||||
}
|
||||
function getFrameSource(frame) {
|
||||
if (!frame.file) return "";
|
||||
let str = "";
|
||||
try {
|
||||
var _globalThis_location;
|
||||
const u = new URL(frame.file);
|
||||
// Strip the origin for same-origin scripts.
|
||||
if (((_globalThis_location = globalThis.location) == null ? void 0 : _globalThis_location.origin) !== u.origin) {
|
||||
// URLs can be valid without an `origin`, so long as they have a
|
||||
// `protocol`. However, `origin` is preferred.
|
||||
if (u.origin === "null") {
|
||||
str += u.protocol;
|
||||
} else {
|
||||
str += u.origin;
|
||||
}
|
||||
}
|
||||
// Strip query string information as it's typically too verbose to be
|
||||
// meaningful.
|
||||
str += u.pathname;
|
||||
str += " ";
|
||||
str = formatFrameSourceFile(str);
|
||||
} catch (e) {
|
||||
str += formatFrameSourceFile(frame.file || "(unknown)") + " ";
|
||||
}
|
||||
if (!isWebpackBundled(frame.file) && frame.lineNumber != null) {
|
||||
if (frame.column != null) {
|
||||
str += "(" + frame.lineNumber + ":" + frame.column + ") ";
|
||||
} else {
|
||||
str += "(" + frame.lineNumber + ") ";
|
||||
}
|
||||
}
|
||||
return str.slice(0, -1);
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=stack-frame.js.map
|
||||
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/use-open-in-editor.js
generated
vendored
Normal file
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/helpers/use-open-in-editor.js
generated
vendored
Normal file
@@ -0,0 +1,37 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "useOpenInEditor", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return useOpenInEditor;
|
||||
}
|
||||
});
|
||||
const _react = require("react");
|
||||
function useOpenInEditor(param) {
|
||||
let { file, lineNumber, column } = param === void 0 ? {} : param;
|
||||
const openInEditor = (0, _react.useCallback)(()=>{
|
||||
if (file == null || lineNumber == null || column == null) return;
|
||||
const params = new URLSearchParams();
|
||||
params.append("file", file);
|
||||
params.append("lineNumber", String(lineNumber));
|
||||
params.append("column", String(column));
|
||||
self.fetch((process.env.__NEXT_ROUTER_BASEPATH || "") + "/__nextjs_launch-editor?" + params.toString()).then(()=>{}, ()=>{
|
||||
console.error("There was an issue opening this code in your editor.");
|
||||
});
|
||||
}, [
|
||||
file,
|
||||
lineNumber,
|
||||
column
|
||||
]);
|
||||
return openInEditor;
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=use-open-in-editor.js.map
|
||||
44
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/hooks/use-on-click-outside.js
generated
vendored
Normal file
44
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/hooks/use-on-click-outside.js
generated
vendored
Normal file
@@ -0,0 +1,44 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "useOnClickOutside", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return useOnClickOutside;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
function useOnClickOutside(el, handler) {
|
||||
_react.useEffect(()=>{
|
||||
if (el == null || handler == null) {
|
||||
return;
|
||||
}
|
||||
const listener = (e)=>{
|
||||
// Do nothing if clicking ref's element or descendent elements
|
||||
if (!el || el.contains(e.target)) {
|
||||
return;
|
||||
}
|
||||
handler(e);
|
||||
};
|
||||
const root = el.getRootNode();
|
||||
root.addEventListener("mousedown", listener);
|
||||
root.addEventListener("touchstart", listener);
|
||||
return function() {
|
||||
root.removeEventListener("mousedown", listener);
|
||||
root.removeEventListener("touchstart", listener);
|
||||
};
|
||||
}, [
|
||||
handler,
|
||||
el
|
||||
]);
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=use-on-click-outside.js.map
|
||||
46
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/icons/CloseIcon.js
generated
vendored
Normal file
46
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/icons/CloseIcon.js
generated
vendored
Normal file
@@ -0,0 +1,46 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "CloseIcon", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return CloseIcon;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const CloseIcon = ()=>{
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
width: "24",
|
||||
height: "24",
|
||||
viewBox: "0 0 24 24",
|
||||
fill: "none",
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M18 6L6 18",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M6 6L18 18",
|
||||
stroke: "currentColor",
|
||||
strokeWidth: "2",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round"
|
||||
})
|
||||
]
|
||||
});
|
||||
};
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=CloseIcon.js.map
|
||||
43
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/icons/CollapseIcon.js
generated
vendored
Normal file
43
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/icons/CollapseIcon.js
generated
vendored
Normal file
@@ -0,0 +1,43 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "CollapseIcon", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return CollapseIcon;
|
||||
}
|
||||
});
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
function CollapseIcon(param) {
|
||||
let { collapsed } = param === void 0 ? {} : param;
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)("svg", {
|
||||
"data-nextjs-call-stack-chevron-icon": true,
|
||||
"data-collapsed": collapsed,
|
||||
fill: "none",
|
||||
height: "20",
|
||||
width: "20",
|
||||
shapeRendering: "geometricPrecision",
|
||||
stroke: "currentColor",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round",
|
||||
strokeWidth: "2",
|
||||
viewBox: "0 0 24 24",
|
||||
...typeof collapsed === "boolean" ? {
|
||||
style: {
|
||||
transform: collapsed ? undefined : "rotate(90deg)"
|
||||
}
|
||||
} : {},
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M9 18l6-6-6-6"
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=CollapseIcon.js.map
|
||||
135
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/icons/FrameworkIcon.js
generated
vendored
Normal file
135
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/icons/FrameworkIcon.js
generated
vendored
Normal file
@@ -0,0 +1,135 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "FrameworkIcon", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return FrameworkIcon;
|
||||
}
|
||||
});
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
function FrameworkIcon(param) {
|
||||
let { framework } = param;
|
||||
if (framework === "react") {
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
"data-nextjs-call-stack-framework-icon": "react",
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
width: "20",
|
||||
height: "20",
|
||||
viewBox: "0 0 410 369",
|
||||
fill: "none",
|
||||
shapeRendering: "geometricPrecision",
|
||||
stroke: "currentColor",
|
||||
strokeLinecap: "round",
|
||||
strokeLinejoin: "round",
|
||||
strokeWidth: "5",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M204.995 224.552C226.56 224.552 244.042 207.07 244.042 185.506C244.042 163.941 226.56 146.459 204.995 146.459C183.43 146.459 165.948 163.941 165.948 185.506C165.948 207.07 183.43 224.552 204.995 224.552Z",
|
||||
fill: "currentColor"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M409.99 184.505C409.99 153.707 381.437 126.667 335.996 108.925C343.342 60.6535 334.19 22.3878 307.492 6.98883C283.649 -6.77511 250.631 -0.0395641 214.512 25.9753C211.316 28.2692 208.143 30.7097 204.97 33.2477C201.822 30.7097 198.65 28.2692 195.477 25.9753C159.359 -0.0395641 126.34 -6.79951 102.497 6.98883C75.8237 22.3878 66.6721 60.6291 74.0422 108.852C28.5529 126.618 0 153.682 0 184.505C0 215.303 28.5528 242.342 73.9934 260.084C66.6477 308.356 75.7993 346.621 102.497 362.02C110.575 366.682 119.727 369 129.684 369C149.085 369 171.61 360.215 195.477 343.034C198.674 340.74 201.847 338.3 205.019 335.762C208.167 338.3 211.34 340.74 214.512 343.034C238.38 360.239 260.905 369 280.306 369C290.263 369 299.415 366.682 307.492 362.02C331.335 348.256 342 316.287 337.534 271.993C337.143 268.089 336.631 264.135 335.996 260.109C381.461 242.367 409.99 215.327 409.99 184.505ZM225.934 41.8136C246.238 27.1955 265.127 19.5814 280.306 19.5814C286.871 19.5814 292.728 20.9968 297.731 23.8765C315.204 33.9798 322.672 62.9475 317.327 102.433C299.756 97.0401 280.306 92.9158 259.392 90.2802C246.872 73.8074 233.597 58.9453 220.003 46.2551C221.98 44.7421 223.957 43.229 225.934 41.8136ZM112.259 23.8765C117.262 20.9968 123.119 19.5814 129.684 19.5814C144.863 19.5814 163.752 27.1711 184.056 41.8136C186.033 43.229 188.01 44.7176 189.986 46.2551C176.393 58.9453 163.142 73.783 150.622 90.2558C129.732 92.8914 110.258 97.0401 92.687 102.409C87.3424 62.9475 94.7857 33.9798 112.259 23.8765ZM19.5233 184.505C19.5233 164.322 40.9014 143.359 77.776 128.253C81.9003 146.141 88.0502 165.054 96.1768 184.456C88.0014 203.881 81.8515 222.819 77.7272 240.732C40.9014 225.626 19.5233 204.687 19.5233 184.505ZM184.056 327.196C154.966 348.134 128.805 354.675 112.259 345.133C94.7857 335.029 87.3181 306.062 92.6626 266.576C110.234 271.969 129.684 276.093 150.598 278.729C163.117 295.202 176.393 310.064 189.986 322.754C188.01 324.292 186.033 325.78 184.056 327.196ZM204.995 310.04C180.591 287.685 157.138 257.815 137.347 223.551C132.051 214.4 121.344 191.396 117 182.489C113.535 190.786 110.112 198.398 107.427 206.5C109.623 210.575 118.092 229.213 120.434 233.288C125.071 241.317 129.928 249.127 134.931 256.692C120.898 254.227 107.915 251.055 96.1035 247.321C102.815 217.011 116.213 182.064 137.347 145.458C142.545 136.453 153.838 116.346 159.5 108C150.568 109.147 143.395 108.767 135 110.5C132.56 114.453 122.777 131.645 120.434 135.721C115.749 143.823 111.454 151.925 107.427 159.978C102.546 146.581 98.8124 133.744 96.1524 121.64C125.755 112.293 162.727 106.411 204.995 106.411C215.562 106.411 237.63 106.197 247.49 106.905C242.048 99.7544 237.38 93.2819 231.694 86.888C227.082 86.7416 209.705 86.888 204.995 86.888C195.672 86.888 186.545 87.2053 177.589 87.7422C186.472 77.1752 195.672 67.5111 204.995 58.9697C229.375 81.3239 252.851 111.195 272.643 145.458C277.841 154.463 289.073 175.426 293.49 184.505C296.98 176.207 300.281 168.64 302.99 160.489C300.793 156.389 291.898 139.747 289.555 135.696C284.918 127.667 280.062 119.858 275.059 112.317C289.092 114.782 302.075 117.954 313.886 121.688C307.175 151.998 293.777 186.945 272.643 223.551C267.445 232.556 252.651 253.178 246.99 261.524C255.922 260.377 265.595 258.663 273.99 256.93C276.43 252.976 287.212 237.364 289.555 233.288C294.216 225.235 298.512 217.182 302.489 209.153C307.224 222.185 310.982 234.997 313.715 247.394C284.138 256.741 247.214 262.598 204.995 262.598C194.428 262.598 169.859 261.208 160 260.5C165.442 267.65 171.304 275.095 176.99 281.489C181.602 281.635 200.285 282.121 204.995 282.121C214.317 282.121 223.444 281.804 232.401 281.267C223.493 291.834 214.317 301.498 204.995 310.04ZM297.731 345.133C281.185 354.699 254.999 348.159 225.934 327.196C223.957 325.78 221.98 324.292 220.003 322.754C233.597 310.064 246.848 295.226 259.367 278.753C280.233 276.118 299.659 271.993 317.205 266.625C317.547 269.089 317.888 271.554 318.132 273.97C321.72 309.649 314.277 335.566 297.731 345.133ZM332.262 240.756C328.065 222.599 321.842 203.686 313.813 184.578C321.988 165.152 328.138 146.215 332.262 128.302C369.088 143.408 390.466 164.322 390.466 184.505C390.466 204.687 369.113 225.626 332.262 240.756Z",
|
||||
fill: "currentColor"
|
||||
})
|
||||
]
|
||||
});
|
||||
}
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("svg", {
|
||||
"data-nextjs-call-stack-framework-icon": "next",
|
||||
xmlns: "http://www.w3.org/2000/svg",
|
||||
width: "20",
|
||||
height: "20",
|
||||
viewBox: "0 0 180 180",
|
||||
fill: "none",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("mask", {
|
||||
id: "mask0_408_139",
|
||||
maskUnits: "userSpaceOnUse",
|
||||
x: "0",
|
||||
y: "0",
|
||||
width: "180",
|
||||
height: "180",
|
||||
children: /*#__PURE__*/ (0, _jsxruntime.jsx)("circle", {
|
||||
cx: "90",
|
||||
cy: "90",
|
||||
r: "90",
|
||||
fill: "black"
|
||||
})
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("g", {
|
||||
mask: "url(#mask0_408_139)",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("circle", {
|
||||
cx: "90",
|
||||
cy: "90",
|
||||
r: "87",
|
||||
fill: "black",
|
||||
stroke: "white",
|
||||
strokeWidth: "6"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("path", {
|
||||
d: "M149.508 157.52L69.142 54H54V125.97H66.1136V69.3836L139.999 164.845C143.333 162.614 146.509 160.165 149.508 157.52Z",
|
||||
fill: "url(#paint0_linear_408_139)"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("rect", {
|
||||
x: "115",
|
||||
y: "54",
|
||||
width: "12",
|
||||
height: "72",
|
||||
fill: "url(#paint1_linear_408_139)"
|
||||
})
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("defs", {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("linearGradient", {
|
||||
id: "paint0_linear_408_139",
|
||||
x1: "109",
|
||||
y1: "116.5",
|
||||
x2: "144.5",
|
||||
y2: "160.5",
|
||||
gradientUnits: "userSpaceOnUse",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("stop", {
|
||||
stopColor: "white"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("stop", {
|
||||
offset: "1",
|
||||
stopColor: "white",
|
||||
stopOpacity: "0"
|
||||
})
|
||||
]
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsxs)("linearGradient", {
|
||||
id: "paint1_linear_408_139",
|
||||
x1: "121",
|
||||
y1: "54",
|
||||
x2: "120.799",
|
||||
y2: "106.875",
|
||||
gradientUnits: "userSpaceOnUse",
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("stop", {
|
||||
stopColor: "white"
|
||||
}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("stop", {
|
||||
offset: "1",
|
||||
stopColor: "white",
|
||||
stopOpacity: "0"
|
||||
})
|
||||
]
|
||||
})
|
||||
]
|
||||
})
|
||||
]
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=FrameworkIcon.js.map
|
||||
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/styles/Base.js
generated
vendored
Normal file
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/styles/Base.js
generated
vendored
Normal file
@@ -0,0 +1,37 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "Base", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return Base;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _nooptemplate = require("../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n :host {\n --size-gap-half: 4px;\n --size-gap: 8px;\n --size-gap-double: 16px;\n --size-gap-triple: 24px;\n --size-gap-quad: 32px;\n\n --size-font-small: 14px;\n --size-font: 16px;\n --size-font-big: 20px;\n --size-font-bigger: 24px;\n\n --color-background: white;\n --color-font: #757575;\n --color-backdrop: rgba(17, 17, 17, 0.2);\n\n --color-title-color: #1f1f1f;\n --color-stack-h6: #222;\n --color-stack-headline: #666;\n --color-stack-subline: #999;\n --color-stack-notes: #777;\n\n --color-accents-1: #808080;\n --color-accents-2: #222222;\n --color-accents-3: #404040;\n\n --color-text-color-red-1: #ff5555;\n --color-text-background-red-1: #fff9f9;\n\n --font-stack-monospace: 'SFMono-Regular', Consolas, 'Liberation Mono',\n Menlo, Courier, monospace;\n --font-stack-sans: -apple-system, 'Source Sans Pro', sans-serif;\n\n --color-ansi-selection: rgba(95, 126, 151, 0.48);\n --color-ansi-bg: #111111;\n --color-ansi-fg: #cccccc;\n\n --color-ansi-white: #777777;\n --color-ansi-black: #141414;\n --color-ansi-blue: #00aaff;\n --color-ansi-cyan: #88ddff;\n --color-ansi-green: #98ec65;\n --color-ansi-magenta: #aa88ff;\n --color-ansi-red: #ff5555;\n --color-ansi-yellow: #ffcc33;\n --color-ansi-bright-white: #ffffff;\n --color-ansi-bright-black: #777777;\n --color-ansi-bright-blue: #33bbff;\n --color-ansi-bright-cyan: #bbecff;\n --color-ansi-bright-green: #b6f292;\n --color-ansi-bright-magenta: #cebbff;\n --color-ansi-bright-red: #ff8888;\n --color-ansi-bright-yellow: #ffd966;\n }\n\n @media (prefers-color-scheme: dark) {\n :host {\n --color-background: rgb(28, 28, 30);\n --color-font: white;\n --color-backdrop: rgb(44, 44, 46);\n\n --color-title-color: #fafafa;\n --color-stack-h6: rgb(200, 200, 204);\n --color-stack-headline: rgb(99, 99, 102);\n --color-stack-notes: #a9a9a9;\n --color-stack-subline: rgb(121, 121, 121);\n\n --color-accents-3: rgb(118, 118, 118);\n\n --color-text-background-red-1: #2a1e1e;\n }\n }\n\n .mono {\n font-family: var(--font-stack-monospace);\n }\n\n h1,\n h2,\n h3,\n h4,\n h5,\n h6 {\n margin-bottom: var(--size-gap);\n font-weight: 500;\n line-height: 1.5;\n }\n "
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function Base() {
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)("style", {
|
||||
children: (0, _nooptemplate.noop)(_templateObject())
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=Base.js.map
|
||||
55
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/styles/ComponentStyles.js
generated
vendored
Normal file
55
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/styles/ComponentStyles.js
generated
vendored
Normal file
@@ -0,0 +1,55 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "ComponentStyles", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return ComponentStyles;
|
||||
}
|
||||
});
|
||||
const _tagged_template_literal_loose = require("@swc/helpers/_/_tagged_template_literal_loose");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _styles = require("../components/CodeFrame/styles");
|
||||
const _Dialog = require("../components/Dialog");
|
||||
const _styles1 = require("../components/LeftRightDialogHeader/styles");
|
||||
const _styles2 = require("../components/Overlay/styles");
|
||||
const _styles3 = require("../components/Terminal/styles");
|
||||
const _Toast = require("../components/Toast");
|
||||
const _VersionStalenessInfo = require("../components/VersionStalenessInfo");
|
||||
const _BuildError = require("../container/BuildError");
|
||||
const _Errors = require("../container/Errors");
|
||||
const _RuntimeError = require("../container/RuntimeError");
|
||||
const _nooptemplate = require("../helpers/noop-template");
|
||||
function _templateObject() {
|
||||
const data = _tagged_template_literal_loose._([
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n ",
|
||||
"\n "
|
||||
]);
|
||||
_templateObject = function() {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function ComponentStyles() {
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsx)("style", {
|
||||
children: (0, _nooptemplate.noop)(_templateObject(), _styles2.styles, _Toast.styles, _Dialog.styles, _styles1.styles, _styles.styles, _styles3.styles, _BuildError.styles, _Errors.styles, _RuntimeError.styles, _VersionStalenessInfo.styles)
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=ComponentStyles.js.map
|
||||
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/styles/CssReset.js
generated
vendored
Normal file
37
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/internal/styles/CssReset.js
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
56
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/ErrorBoundary.js
generated
vendored
Normal file
56
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/ErrorBoundary.js
generated
vendored
Normal file
@@ -0,0 +1,56 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "ErrorBoundary", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return ErrorBoundary;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
class ErrorBoundary extends _react.PureComponent {
|
||||
static getDerivedStateFromError(error) {
|
||||
return {
|
||||
error
|
||||
};
|
||||
}
|
||||
componentDidCatch(error, // Loosely typed because it depends on the React version and was
|
||||
// accidentally excluded in some versions.
|
||||
errorInfo) {
|
||||
this.props.onError(error, (errorInfo == null ? void 0 : errorInfo.componentStack) || null);
|
||||
if (!this.props.globalOverlay) {
|
||||
this.setState({
|
||||
error
|
||||
});
|
||||
}
|
||||
}
|
||||
// Explicit type is needed to avoid the generated `.d.ts` having a wide return type that could be specific the the `@types/react` version.
|
||||
render() {
|
||||
// The component has to be unmounted or else it would continue to error
|
||||
return this.state.error || this.props.globalOverlay && this.props.isMounted ? // When the overlay is global for the application and it wraps a component rendering `<html>`
|
||||
// we have to render the html shell otherwise the shadow root will not be able to attach
|
||||
this.props.globalOverlay ? /*#__PURE__*/ (0, _jsxruntime.jsxs)("html", {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("head", {}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)("body", {})
|
||||
]
|
||||
}) : null : this.props.children;
|
||||
}
|
||||
constructor(...args){
|
||||
super(...args);
|
||||
this.state = {
|
||||
error: null
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=ErrorBoundary.js.map
|
||||
82
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/ReactDevOverlay.js
generated
vendored
Normal file
82
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/ReactDevOverlay.js
generated
vendored
Normal file
@@ -0,0 +1,82 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
Object.defineProperty(exports, "default", {
|
||||
enumerable: true,
|
||||
get: function() {
|
||||
return ReactDevOverlay;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _jsxruntime = require("react/jsx-runtime");
|
||||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
||||
const _bus = /*#__PURE__*/ _interop_require_wildcard._(require("./bus"));
|
||||
const _ShadowPortal = require("../internal/components/ShadowPortal");
|
||||
const _BuildError = require("../internal/container/BuildError");
|
||||
const _Errors = require("../internal/container/Errors");
|
||||
const _ErrorBoundary = require("./ErrorBoundary");
|
||||
const _Base = require("../internal/styles/Base");
|
||||
const _ComponentStyles = require("../internal/styles/ComponentStyles");
|
||||
const _CssReset = require("../internal/styles/CssReset");
|
||||
const _shared = require("../shared");
|
||||
const shouldPreventDisplay = (errorType, preventType)=>{
|
||||
if (!preventType || !errorType) {
|
||||
return false;
|
||||
}
|
||||
return preventType.includes(errorType);
|
||||
};
|
||||
function ReactDevOverlay(param) {
|
||||
let { children, preventDisplay, globalOverlay } = param;
|
||||
const [state, dispatch] = (0, _shared.useErrorOverlayReducer)();
|
||||
_react.useEffect(()=>{
|
||||
_bus.on(dispatch);
|
||||
return function() {
|
||||
_bus.off(dispatch);
|
||||
};
|
||||
}, [
|
||||
dispatch
|
||||
]);
|
||||
const onComponentError = _react.useCallback((_error, _componentStack)=>{
|
||||
// TODO: special handling
|
||||
}, []);
|
||||
const hasBuildError = state.buildError != null;
|
||||
const hasRuntimeErrors = Boolean(state.errors.length);
|
||||
const errorType = hasBuildError ? "build" : hasRuntimeErrors ? "runtime" : null;
|
||||
const isMounted = errorType !== null;
|
||||
const displayPrevented = shouldPreventDisplay(errorType, preventDisplay);
|
||||
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(_jsxruntime.Fragment, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_ErrorBoundary.ErrorBoundary, {
|
||||
globalOverlay: globalOverlay,
|
||||
isMounted: isMounted,
|
||||
onError: onComponentError,
|
||||
children: children != null ? children : null
|
||||
}),
|
||||
isMounted ? /*#__PURE__*/ (0, _jsxruntime.jsxs)(_ShadowPortal.ShadowPortal, {
|
||||
children: [
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_CssReset.CssReset, {}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Base.Base, {}),
|
||||
/*#__PURE__*/ (0, _jsxruntime.jsx)(_ComponentStyles.ComponentStyles, {}),
|
||||
displayPrevented ? null : hasBuildError ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_BuildError.BuildError, {
|
||||
message: state.buildError,
|
||||
versionInfo: state.versionInfo
|
||||
}) : hasRuntimeErrors ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_Errors.Errors, {
|
||||
isAppDir: false,
|
||||
errors: state.errors,
|
||||
versionInfo: state.versionInfo,
|
||||
initialDisplayState: "fullscreen"
|
||||
}) : undefined
|
||||
]
|
||||
}) : undefined
|
||||
]
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=ReactDevOverlay.js.map
|
||||
70
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/bus.js
generated
vendored
Normal file
70
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/bus.js
generated
vendored
Normal file
@@ -0,0 +1,70 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
emit: null,
|
||||
off: null,
|
||||
on: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
emit: function() {
|
||||
return emit;
|
||||
},
|
||||
off: function() {
|
||||
return off;
|
||||
},
|
||||
on: function() {
|
||||
return on;
|
||||
}
|
||||
});
|
||||
let handlers = new Set();
|
||||
let queue = [];
|
||||
function drain() {
|
||||
// Draining should never happen synchronously in case multiple handlers are
|
||||
// registered.
|
||||
setTimeout(function() {
|
||||
while(// Until we are out of events:
|
||||
Boolean(queue.length) && // Or, if all handlers removed themselves as a result of handling the
|
||||
// event(s)
|
||||
Boolean(handlers.size)){
|
||||
const ev = queue.shift();
|
||||
handlers.forEach((handler)=>handler(ev));
|
||||
}
|
||||
}, 1);
|
||||
}
|
||||
function emit(ev) {
|
||||
queue.push(Object.freeze({
|
||||
...ev
|
||||
}));
|
||||
drain();
|
||||
}
|
||||
function on(fn) {
|
||||
if (handlers.has(fn)) {
|
||||
return false;
|
||||
}
|
||||
handlers.add(fn);
|
||||
drain();
|
||||
return true;
|
||||
}
|
||||
function off(fn) {
|
||||
if (handlers.has(fn)) {
|
||||
handlers.delete(fn);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=bus.js.map
|
||||
172
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/client.js
generated
vendored
Normal file
172
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/pages/client.js
generated
vendored
Normal file
@@ -0,0 +1,172 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
ReactDevOverlay: null,
|
||||
getErrorByType: null,
|
||||
getServerError: null,
|
||||
onBeforeRefresh: null,
|
||||
onBuildError: null,
|
||||
onBuildOk: null,
|
||||
onRefresh: null,
|
||||
onVersionInfo: null,
|
||||
register: null,
|
||||
unregister: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
ReactDevOverlay: function() {
|
||||
return _ReactDevOverlay.default;
|
||||
},
|
||||
getErrorByType: function() {
|
||||
return _getErrorByType.getErrorByType;
|
||||
},
|
||||
getServerError: function() {
|
||||
return _nodeStackFrames.getServerError;
|
||||
},
|
||||
onBeforeRefresh: function() {
|
||||
return onBeforeRefresh;
|
||||
},
|
||||
onBuildError: function() {
|
||||
return onBuildError;
|
||||
},
|
||||
onBuildOk: function() {
|
||||
return onBuildOk;
|
||||
},
|
||||
onRefresh: function() {
|
||||
return onRefresh;
|
||||
},
|
||||
onVersionInfo: function() {
|
||||
return onVersionInfo;
|
||||
},
|
||||
register: function() {
|
||||
return register;
|
||||
},
|
||||
unregister: function() {
|
||||
return unregister;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _bus = /*#__PURE__*/ _interop_require_wildcard._(require("./bus"));
|
||||
const _parseStack = require("../internal/helpers/parseStack");
|
||||
const _parsecomponentstack = require("../internal/helpers/parse-component-stack");
|
||||
const _hydrationerrorinfo = require("../internal/helpers/hydration-error-info");
|
||||
const _shared = require("../shared");
|
||||
const _getErrorByType = require("../internal/helpers/getErrorByType");
|
||||
const _nodeStackFrames = require("../internal/helpers/nodeStackFrames");
|
||||
const _ReactDevOverlay = /*#__PURE__*/ _interop_require_default._(require("./ReactDevOverlay"));
|
||||
// Patch console.error to collect information about hydration errors
|
||||
(0, _hydrationerrorinfo.patchConsoleError)();
|
||||
let isRegistered = false;
|
||||
let stackTraceLimit = undefined;
|
||||
function onUnhandledError(ev) {
|
||||
const error = ev == null ? void 0 : ev.error;
|
||||
if (!error || !(error instanceof Error) || typeof error.stack !== "string") {
|
||||
// A non-error was thrown, we don't have anything to show. :-(
|
||||
return;
|
||||
}
|
||||
if (error.message.match(/(hydration|content does not match|did not match)/i)) {
|
||||
if (_hydrationerrorinfo.hydrationErrorState.warning) {
|
||||
error.details = {
|
||||
...error.details,
|
||||
// It contains the warning, component stack, server and client tag names
|
||||
..._hydrationerrorinfo.hydrationErrorState
|
||||
};
|
||||
}
|
||||
error.message += "\nSee more info here: https://nextjs.org/docs/messages/react-hydration-error";
|
||||
}
|
||||
const e = error;
|
||||
const componentStackFrames = typeof _hydrationerrorinfo.hydrationErrorState.componentStack === "string" ? (0, _parsecomponentstack.parseComponentStack)(_hydrationerrorinfo.hydrationErrorState.componentStack) : undefined;
|
||||
// Skip ModuleBuildError and ModuleNotFoundError, as it will be sent through onBuildError callback.
|
||||
// This is to avoid same error as different type showing up on client to cause flashing.
|
||||
if (e.name !== "ModuleBuildError" && e.name !== "ModuleNotFoundError") {
|
||||
_bus.emit({
|
||||
type: _shared.ACTION_UNHANDLED_ERROR,
|
||||
reason: error,
|
||||
frames: (0, _parseStack.parseStack)(e.stack),
|
||||
componentStackFrames
|
||||
});
|
||||
}
|
||||
}
|
||||
function onUnhandledRejection(ev) {
|
||||
const reason = ev == null ? void 0 : ev.reason;
|
||||
if (!reason || !(reason instanceof Error) || typeof reason.stack !== "string") {
|
||||
// A non-error was thrown, we don't have anything to show. :-(
|
||||
return;
|
||||
}
|
||||
const e = reason;
|
||||
_bus.emit({
|
||||
type: _shared.ACTION_UNHANDLED_REJECTION,
|
||||
reason: reason,
|
||||
frames: (0, _parseStack.parseStack)(e.stack)
|
||||
});
|
||||
}
|
||||
function register() {
|
||||
if (isRegistered) {
|
||||
return;
|
||||
}
|
||||
isRegistered = true;
|
||||
try {
|
||||
const limit = Error.stackTraceLimit;
|
||||
Error.stackTraceLimit = 50;
|
||||
stackTraceLimit = limit;
|
||||
} catch (e) {}
|
||||
window.addEventListener("error", onUnhandledError);
|
||||
window.addEventListener("unhandledrejection", onUnhandledRejection);
|
||||
}
|
||||
function unregister() {
|
||||
if (!isRegistered) {
|
||||
return;
|
||||
}
|
||||
isRegistered = false;
|
||||
if (stackTraceLimit !== undefined) {
|
||||
try {
|
||||
Error.stackTraceLimit = stackTraceLimit;
|
||||
} catch (e) {}
|
||||
stackTraceLimit = undefined;
|
||||
}
|
||||
window.removeEventListener("error", onUnhandledError);
|
||||
window.removeEventListener("unhandledrejection", onUnhandledRejection);
|
||||
}
|
||||
function onBuildOk() {
|
||||
_bus.emit({
|
||||
type: _shared.ACTION_BUILD_OK
|
||||
});
|
||||
}
|
||||
function onBuildError(message) {
|
||||
_bus.emit({
|
||||
type: _shared.ACTION_BUILD_ERROR,
|
||||
message
|
||||
});
|
||||
}
|
||||
function onRefresh() {
|
||||
_bus.emit({
|
||||
type: _shared.ACTION_REFRESH
|
||||
});
|
||||
}
|
||||
function onBeforeRefresh() {
|
||||
_bus.emit({
|
||||
type: _shared.ACTION_BEFORE_REFRESH
|
||||
});
|
||||
}
|
||||
function onVersionInfo(versionInfo) {
|
||||
_bus.emit({
|
||||
type: _shared.ACTION_VERSION_INFO,
|
||||
versionInfo
|
||||
});
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=client.js.map
|
||||
124
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/server/middleware-turbopack.js
generated
vendored
Normal file
124
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/server/middleware-turbopack.js
generated
vendored
Normal file
@@ -0,0 +1,124 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
batchedTraceSource: null,
|
||||
createOriginalStackFrame: null,
|
||||
getOverlayMiddleware: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
batchedTraceSource: function() {
|
||||
return batchedTraceSource;
|
||||
},
|
||||
createOriginalStackFrame: function() {
|
||||
return createOriginalStackFrame;
|
||||
},
|
||||
getOverlayMiddleware: function() {
|
||||
return getOverlayMiddleware;
|
||||
}
|
||||
});
|
||||
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
||||
const _shared = require("./shared");
|
||||
const _promises = /*#__PURE__*/ _interop_require_wildcard._(require("fs/promises"));
|
||||
const _launchEditor = require("../internal/helpers/launchEditor");
|
||||
const currentSourcesByFile = new Map();
|
||||
async function batchedTraceSource(project, frame) {
|
||||
const file = frame.file ? decodeURIComponent(frame.file) : undefined;
|
||||
if (!file) return;
|
||||
const sourceFrame = await project.traceSource(frame);
|
||||
if (!sourceFrame) return;
|
||||
let source = null;
|
||||
// Don't look up source for node_modules or internals. These can often be large bundled files.
|
||||
if (sourceFrame.file && !(sourceFrame.file.includes("node_modules") || sourceFrame.isInternal)) {
|
||||
let sourcePromise = currentSourcesByFile.get(sourceFrame.file);
|
||||
if (!sourcePromise) {
|
||||
sourcePromise = project.getSourceForAsset(sourceFrame.file);
|
||||
currentSourcesByFile.set(sourceFrame.file, sourcePromise);
|
||||
setTimeout(()=>{
|
||||
// Cache file reads for 100ms, as frames will often reference the same
|
||||
// files and can be large.
|
||||
currentSourcesByFile.delete(sourceFrame.file);
|
||||
}, 100);
|
||||
}
|
||||
source = await sourcePromise;
|
||||
}
|
||||
var _sourceFrame_line, _sourceFrame_column, _sourceFrame_methodName, _ref;
|
||||
return {
|
||||
frame: {
|
||||
file: sourceFrame.file,
|
||||
lineNumber: (_sourceFrame_line = sourceFrame.line) != null ? _sourceFrame_line : 0,
|
||||
column: (_sourceFrame_column = sourceFrame.column) != null ? _sourceFrame_column : 0,
|
||||
methodName: (_ref = (_sourceFrame_methodName = sourceFrame.methodName) != null ? _sourceFrame_methodName : frame.methodName) != null ? _ref : "<unknown>",
|
||||
arguments: []
|
||||
},
|
||||
source
|
||||
};
|
||||
}
|
||||
async function createOriginalStackFrame(project, frame) {
|
||||
const traced = await batchedTraceSource(project, frame);
|
||||
if (!traced) {
|
||||
const sourcePackage = (0, _shared.findSourcePackage)(frame);
|
||||
if (sourcePackage) return {
|
||||
sourcePackage
|
||||
};
|
||||
return null;
|
||||
}
|
||||
return {
|
||||
originalStackFrame: traced.frame,
|
||||
originalCodeFrame: (0, _shared.getOriginalCodeFrame)(traced.frame, traced.source),
|
||||
sourcePackage: (0, _shared.findSourcePackage)(traced.frame)
|
||||
};
|
||||
}
|
||||
function getOverlayMiddleware(project) {
|
||||
return async function(req, res) {
|
||||
const { pathname, searchParams } = new URL(req.url, "http://n");
|
||||
var _searchParams_get, _searchParams_get1, _searchParams_get2;
|
||||
const frame = {
|
||||
file: searchParams.get("file"),
|
||||
methodName: (_searchParams_get = searchParams.get("methodName")) != null ? _searchParams_get : "<unknown>",
|
||||
line: parseInt((_searchParams_get1 = searchParams.get("lineNumber")) != null ? _searchParams_get1 : "0", 10) || 0,
|
||||
column: parseInt((_searchParams_get2 = searchParams.get("column")) != null ? _searchParams_get2 : "0", 10) || 0,
|
||||
isServer: searchParams.get("isServer") === "true"
|
||||
};
|
||||
if (pathname === "/__nextjs_original-stack-frame") {
|
||||
let originalStackFrame;
|
||||
try {
|
||||
originalStackFrame = await createOriginalStackFrame(project, frame);
|
||||
} catch (e) {
|
||||
return (0, _shared.internalServerError)(res, e.message);
|
||||
}
|
||||
if (!originalStackFrame) {
|
||||
res.statusCode = 404;
|
||||
return res.end("Unable to resolve sourcemap");
|
||||
}
|
||||
return (0, _shared.json)(res, originalStackFrame);
|
||||
} else if (pathname === "/__nextjs_launch-editor") {
|
||||
if (!frame.file) return (0, _shared.badRequest)(res);
|
||||
const fileExists = await _promises.default.access(frame.file, _promises.constants.F_OK).then(()=>true, ()=>false);
|
||||
if (!fileExists) return (0, _shared.noContent)(res);
|
||||
try {
|
||||
var _frame_line, _frame_column;
|
||||
(0, _launchEditor.launchEditor)(frame.file, (_frame_line = frame.line) != null ? _frame_line : 1, (_frame_column = frame.column) != null ? _frame_column : 1);
|
||||
} catch (err) {
|
||||
console.log("Failed to launch editor:", err);
|
||||
return (0, _shared.internalServerError)(res);
|
||||
}
|
||||
(0, _shared.noContent)(res);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=middleware-turbopack.js.map
|
||||
263
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/server/middleware.js
generated
vendored
Normal file
263
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/server/middleware.js
generated
vendored
Normal file
@@ -0,0 +1,263 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
createOriginalStackFrame: null,
|
||||
getOverlayMiddleware: null,
|
||||
getServerError: null,
|
||||
getSourceById: null,
|
||||
parseStack: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
createOriginalStackFrame: function() {
|
||||
return createOriginalStackFrame;
|
||||
},
|
||||
getOverlayMiddleware: function() {
|
||||
return getOverlayMiddleware;
|
||||
},
|
||||
getServerError: function() {
|
||||
return _nodeStackFrames.getServerError;
|
||||
},
|
||||
getSourceById: function() {
|
||||
return getSourceById;
|
||||
},
|
||||
parseStack: function() {
|
||||
return _parseStack.parseStack;
|
||||
}
|
||||
});
|
||||
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
||||
const _fs = require("fs");
|
||||
const _path = /*#__PURE__*/ _interop_require_default._(require("path"));
|
||||
const _sourcemap08 = require("next/dist/compiled/source-map08");
|
||||
const _getRawSourceMap = require("../internal/helpers/getRawSourceMap");
|
||||
const _launchEditor = require("../internal/helpers/launchEditor");
|
||||
const _shared = require("./shared");
|
||||
const _nodeStackFrames = require("../internal/helpers/nodeStackFrames");
|
||||
const _parseStack = require("../internal/helpers/parseStack");
|
||||
function getModuleId(compilation, module1) {
|
||||
return compilation.chunkGraph.getModuleId(module1);
|
||||
}
|
||||
function getModuleById(id, compilation) {
|
||||
return [
|
||||
...compilation.modules
|
||||
].find((searchModule)=>getModuleId(compilation, searchModule) === id);
|
||||
}
|
||||
function findModuleNotFoundFromError(errorMessage) {
|
||||
var _errorMessage_match;
|
||||
return errorMessage == null ? void 0 : (_errorMessage_match = errorMessage.match(/'([^']+)' module/)) == null ? void 0 : _errorMessage_match[1];
|
||||
}
|
||||
function getModuleSource(compilation, module1) {
|
||||
var _compilation_codeGenerationResults_get;
|
||||
if (!module1) return null;
|
||||
var _compilation_codeGenerationResults_get_sources_get;
|
||||
return (_compilation_codeGenerationResults_get_sources_get = (_compilation_codeGenerationResults_get = compilation.codeGenerationResults.get(module1)) == null ? void 0 : _compilation_codeGenerationResults_get.sources.get("javascript")) != null ? _compilation_codeGenerationResults_get_sources_get : null;
|
||||
}
|
||||
function getSourcePath(source) {
|
||||
return source.replace(/^(webpack:\/\/\/|webpack:\/\/|webpack:\/\/_N_E\/)/, "");
|
||||
}
|
||||
async function findOriginalSourcePositionAndContent(webpackSource, position) {
|
||||
const consumer = await new _sourcemap08.SourceMapConsumer(webpackSource.map());
|
||||
try {
|
||||
var _position_column;
|
||||
const sourcePosition = consumer.originalPositionFor({
|
||||
line: position.line,
|
||||
column: (_position_column = position.column) != null ? _position_column : 0
|
||||
});
|
||||
if (!sourcePosition.source) {
|
||||
return null;
|
||||
}
|
||||
var _consumer_sourceContentFor;
|
||||
const sourceContent = (_consumer_sourceContentFor = consumer.sourceContentFor(sourcePosition.source, /* returnNullOnMissing */ true)) != null ? _consumer_sourceContentFor : null;
|
||||
return {
|
||||
sourcePosition,
|
||||
sourceContent
|
||||
};
|
||||
} finally{
|
||||
consumer.destroy();
|
||||
}
|
||||
}
|
||||
function findOriginalSourcePositionAndContentFromCompilation(moduleId, importedModule, compilation) {
|
||||
var _module_buildInfo_importLocByPath, _module_buildInfo;
|
||||
const module1 = getModuleById(moduleId, compilation);
|
||||
var _module_buildInfo_importLocByPath_get;
|
||||
return (_module_buildInfo_importLocByPath_get = module1 == null ? void 0 : (_module_buildInfo = module1.buildInfo) == null ? void 0 : (_module_buildInfo_importLocByPath = _module_buildInfo.importLocByPath) == null ? void 0 : _module_buildInfo_importLocByPath.get(importedModule)) != null ? _module_buildInfo_importLocByPath_get : null;
|
||||
}
|
||||
async function createOriginalStackFrame(param) {
|
||||
let { source, moduleId, modulePath, rootDirectory, frame, errorMessage, compilation } = param;
|
||||
var // default is not a valid identifier in JS so webpack uses a custom variable when it's an unnamed default export
|
||||
// Resolve it back to `default` for the method name if the source position didn't have the method.
|
||||
_frame_methodName_replace, _frame_methodName;
|
||||
const { lineNumber, column } = frame;
|
||||
const moduleNotFound = findModuleNotFoundFromError(errorMessage);
|
||||
const result = await (async ()=>{
|
||||
if (moduleNotFound) {
|
||||
if (!compilation) return null;
|
||||
return findOriginalSourcePositionAndContentFromCompilation(moduleId, moduleNotFound, compilation);
|
||||
}
|
||||
// This returns 1-based lines and 0-based columns
|
||||
return await findOriginalSourcePositionAndContent(source, {
|
||||
line: lineNumber != null ? lineNumber : 1,
|
||||
column
|
||||
});
|
||||
})();
|
||||
if (!(result == null ? void 0 : result.sourcePosition.source)) return null;
|
||||
const { sourcePosition, sourceContent } = result;
|
||||
const filePath = _path.default.resolve(rootDirectory, getSourcePath(// When sourcePosition.source is the loader path the modulePath is generally better.
|
||||
(sourcePosition.source.includes("|") ? modulePath : sourcePosition.source) || modulePath));
|
||||
var _sourcePosition_column;
|
||||
const traced = {
|
||||
file: sourceContent ? _path.default.relative(rootDirectory, filePath) : sourcePosition.source,
|
||||
lineNumber: sourcePosition.line,
|
||||
column: ((_sourcePosition_column = sourcePosition.column) != null ? _sourcePosition_column : 0) + 1,
|
||||
methodName: sourcePosition.name || ((_frame_methodName = frame.methodName) == null ? void 0 : (_frame_methodName_replace = _frame_methodName.replace("__WEBPACK_DEFAULT_EXPORT__", "default")) == null ? void 0 : _frame_methodName_replace.replace("__webpack_exports__.", "")),
|
||||
arguments: []
|
||||
};
|
||||
return {
|
||||
originalStackFrame: traced,
|
||||
originalCodeFrame: (0, _shared.getOriginalCodeFrame)(traced, sourceContent),
|
||||
sourcePackage: (0, _shared.findSourcePackage)(traced)
|
||||
};
|
||||
}
|
||||
async function getSourceById(isFile, id, compilation) {
|
||||
if (isFile) {
|
||||
const fileContent = await _fs.promises.readFile(id, "utf-8").catch(()=>null);
|
||||
if (fileContent == null) {
|
||||
return null;
|
||||
}
|
||||
const map = (0, _getRawSourceMap.getRawSourceMap)(fileContent);
|
||||
if (map == null) {
|
||||
return null;
|
||||
}
|
||||
return {
|
||||
map () {
|
||||
return map;
|
||||
}
|
||||
};
|
||||
}
|
||||
try {
|
||||
if (!compilation) {
|
||||
return null;
|
||||
}
|
||||
const module1 = getModuleById(id, compilation);
|
||||
const moduleSource = getModuleSource(compilation, module1);
|
||||
return moduleSource;
|
||||
} catch (err) {
|
||||
console.error('Failed to lookup module by ID ("' + id + '"):', err);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
function getOverlayMiddleware(options) {
|
||||
return async function(req, res, next) {
|
||||
const { pathname, searchParams } = new URL("http://n" + req.url);
|
||||
var _searchParams_get, _searchParams_get1;
|
||||
const frame = {
|
||||
file: searchParams.get("file"),
|
||||
methodName: searchParams.get("methodName"),
|
||||
lineNumber: parseInt((_searchParams_get = searchParams.get("lineNumber")) != null ? _searchParams_get : "0", 10) || 0,
|
||||
column: parseInt((_searchParams_get1 = searchParams.get("column")) != null ? _searchParams_get1 : "0", 10) || 0,
|
||||
arguments: searchParams.getAll("arguments").filter(Boolean)
|
||||
};
|
||||
const isServer = searchParams.get("isServer") === "true";
|
||||
const isEdgeServer = searchParams.get("isEdgeServer") === "true";
|
||||
const isAppDirectory = searchParams.get("isAppDirectory") === "true";
|
||||
if (pathname === "/__nextjs_original-stack-frame") {
|
||||
const isClient = !isServer && !isEdgeServer;
|
||||
let sourcePackage = (0, _shared.findSourcePackage)(frame);
|
||||
if (!(/^(webpack-internal:\/\/\/|(file|webpack):\/\/)/.test(frame.file) && frame.lineNumber)) {
|
||||
if (sourcePackage) return (0, _shared.json)(res, {
|
||||
sourcePackage
|
||||
});
|
||||
return (0, _shared.badRequest)(res);
|
||||
}
|
||||
const moduleId = frame.file.replace(/^(webpack-internal:\/\/\/|file:\/\/|webpack:\/\/(_N_E\/)?)/, "");
|
||||
const modulePath = frame.file.replace(/^(webpack-internal:\/\/\/|file:\/\/|webpack:\/\/(_N_E\/)?)(\(.*\)\/?)/, "");
|
||||
let source = null;
|
||||
let compilation;
|
||||
const isFile = frame.file.startsWith("file:");
|
||||
try {
|
||||
if (isClient || isAppDirectory) {
|
||||
var _options_stats;
|
||||
compilation = (_options_stats = options.stats()) == null ? void 0 : _options_stats.compilation;
|
||||
// Try Client Compilation first
|
||||
// In `pages` we leverage `isClientError` to check
|
||||
// In `app` it depends on if it's a server / client component and when the code throws. E.g. during HTML rendering it's the server/edge compilation.
|
||||
source = await getSourceById(isFile, moduleId, compilation);
|
||||
}
|
||||
// Try Server Compilation
|
||||
// In `pages` this could be something imported in getServerSideProps/getStaticProps as the code for those is tree-shaken.
|
||||
// In `app` this finds server components and code that was imported from a server component. It also covers when client component code throws during HTML rendering.
|
||||
if ((isServer || isAppDirectory) && source === null) {
|
||||
var _options_serverStats;
|
||||
compilation = (_options_serverStats = options.serverStats()) == null ? void 0 : _options_serverStats.compilation;
|
||||
source = await getSourceById(isFile, moduleId, compilation);
|
||||
}
|
||||
// Try Edge Server Compilation
|
||||
// Both cases are the same as Server Compilation, main difference is that it covers `runtime: 'edge'` pages/app routes.
|
||||
if ((isEdgeServer || isAppDirectory) && source === null) {
|
||||
var _options_edgeServerStats;
|
||||
compilation = (_options_edgeServerStats = options.edgeServerStats()) == null ? void 0 : _options_edgeServerStats.compilation;
|
||||
source = await getSourceById(isFile, moduleId, compilation);
|
||||
}
|
||||
} catch (err) {
|
||||
console.log("Failed to get source map:", err);
|
||||
return (0, _shared.internalServerError)(res);
|
||||
}
|
||||
if (!source) {
|
||||
if (sourcePackage) return (0, _shared.json)(res, {
|
||||
sourcePackage
|
||||
});
|
||||
return (0, _shared.noContent)(res);
|
||||
}
|
||||
try {
|
||||
const originalStackFrameResponse = await createOriginalStackFrame({
|
||||
frame,
|
||||
source,
|
||||
moduleId,
|
||||
modulePath,
|
||||
rootDirectory: options.rootDirectory,
|
||||
compilation
|
||||
});
|
||||
if (originalStackFrameResponse === null) {
|
||||
if (sourcePackage) return (0, _shared.json)(res, {
|
||||
sourcePackage
|
||||
});
|
||||
return (0, _shared.noContent)(res);
|
||||
}
|
||||
return (0, _shared.json)(res, originalStackFrameResponse);
|
||||
} catch (err) {
|
||||
console.log("Failed to parse source map:", err);
|
||||
return (0, _shared.internalServerError)(res);
|
||||
}
|
||||
} else if (pathname === "/__nextjs_launch-editor") {
|
||||
if (!frame.file) return (0, _shared.badRequest)(res);
|
||||
// frame files may start with their webpack layer, like (middleware)/middleware.js
|
||||
const filePath = _path.default.resolve(options.rootDirectory, frame.file.replace(/^\([^)]+\)\//, ""));
|
||||
const fileExists = await _fs.promises.access(filePath, _fs.constants.F_OK).then(()=>true, ()=>false);
|
||||
if (!fileExists) return (0, _shared.noContent)(res);
|
||||
try {
|
||||
var _frame_column;
|
||||
await (0, _launchEditor.launchEditor)(filePath, frame.lineNumber, (_frame_column = frame.column) != null ? _frame_column : 1);
|
||||
} catch (err) {
|
||||
console.log("Failed to launch editor:", err);
|
||||
return (0, _shared.internalServerError)(res);
|
||||
}
|
||||
return (0, _shared.noContent)(res);
|
||||
}
|
||||
return next();
|
||||
};
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=middleware.js.map
|
||||
103
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/server/shared.js
generated
vendored
Normal file
103
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/server/shared.js
generated
vendored
Normal file
@@ -0,0 +1,103 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
badRequest: null,
|
||||
findSourcePackage: null,
|
||||
getOriginalCodeFrame: null,
|
||||
internalServerError: null,
|
||||
json: null,
|
||||
noContent: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
badRequest: function() {
|
||||
return badRequest;
|
||||
},
|
||||
findSourcePackage: function() {
|
||||
return findSourcePackage;
|
||||
},
|
||||
getOriginalCodeFrame: function() {
|
||||
return getOriginalCodeFrame;
|
||||
},
|
||||
internalServerError: function() {
|
||||
return internalServerError;
|
||||
},
|
||||
json: function() {
|
||||
return json;
|
||||
},
|
||||
noContent: function() {
|
||||
return noContent;
|
||||
}
|
||||
});
|
||||
const _codeframe = require("next/dist/compiled/babel/code-frame");
|
||||
/** React that's compiled with `next`. Used by App Router. */ const reactVendoredRe = /[\\/]next[\\/]dist[\\/]compiled[\\/](react|react-dom|react-server-dom-(webpack|turbopack)|scheduler)[\\/]/;
|
||||
/** React the user installed. Used by Pages Router, or user imports in App Router. */ const reactNodeModulesRe = /node_modules[\\/](react|react-dom|scheduler)[\\/]/;
|
||||
const nextInternalsRe = /(node_modules[\\/]next[\\/]|[\\/].next[\\/]static[\\/]chunks[\\/]webpack\.js$|(edge-runtime-webpack|webpack-runtime)\.js$)/;
|
||||
const nextMethodRe = /(^__webpack_.*|node_modules[\\/]next[\\/])/;
|
||||
function isInternal(file) {
|
||||
if (!file) return false;
|
||||
return nextInternalsRe.test(file) || reactVendoredRe.test(file) || reactNodeModulesRe.test(file);
|
||||
}
|
||||
function findSourcePackage(param) {
|
||||
let { file, methodName } = param;
|
||||
if (file) {
|
||||
// matching React first since vendored would match under `next` too
|
||||
if (reactVendoredRe.test(file) || reactNodeModulesRe.test(file)) {
|
||||
return "react";
|
||||
} else if (nextInternalsRe.test(file)) {
|
||||
return "next";
|
||||
}
|
||||
}
|
||||
if (methodName) {
|
||||
if (nextMethodRe.test(methodName)) {
|
||||
return "next";
|
||||
}
|
||||
}
|
||||
}
|
||||
function getOriginalCodeFrame(frame, source) {
|
||||
var _frame_file;
|
||||
if (!source || ((_frame_file = frame.file) == null ? void 0 : _frame_file.includes("node_modules")) || isInternal(frame.file)) {
|
||||
return null;
|
||||
}
|
||||
var _frame_lineNumber, _frame_column;
|
||||
return (0, _codeframe.codeFrameColumns)(source, {
|
||||
start: {
|
||||
// 1-based, but -1 means start line without highlighting
|
||||
line: (_frame_lineNumber = frame.lineNumber) != null ? _frame_lineNumber : -1,
|
||||
// 1-based, but 0 means whole line without column highlighting
|
||||
column: (_frame_column = frame.column) != null ? _frame_column : 0
|
||||
}
|
||||
}, {
|
||||
forceColor: true
|
||||
});
|
||||
}
|
||||
function noContent(res) {
|
||||
res.statusCode = 204;
|
||||
res.end("No Content");
|
||||
}
|
||||
function badRequest(res) {
|
||||
res.statusCode = 400;
|
||||
res.end("Bad Request");
|
||||
}
|
||||
function internalServerError(res, e) {
|
||||
res.statusCode = 500;
|
||||
res.end(e != null ? e : "Internal Server Error");
|
||||
}
|
||||
function json(res, data) {
|
||||
res.setHeader("Content-Type", "application/json").end(Buffer.from(JSON.stringify(data)));
|
||||
}
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=shared.js.map
|
||||
187
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/shared.js
generated
vendored
Normal file
187
.next/standalone/node_modules/next/dist/client/components/react-dev-overlay/shared.js
generated
vendored
Normal file
@@ -0,0 +1,187 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
0 && (module.exports = {
|
||||
ACTION_BEFORE_REFRESH: null,
|
||||
ACTION_BUILD_ERROR: null,
|
||||
ACTION_BUILD_OK: null,
|
||||
ACTION_REFRESH: null,
|
||||
ACTION_UNHANDLED_ERROR: null,
|
||||
ACTION_UNHANDLED_REJECTION: null,
|
||||
ACTION_VERSION_INFO: null,
|
||||
INITIAL_OVERLAY_STATE: null,
|
||||
REACT_REFRESH_FULL_RELOAD_FROM_ERROR: null,
|
||||
useErrorOverlayReducer: null
|
||||
});
|
||||
function _export(target, all) {
|
||||
for(var name in all)Object.defineProperty(target, name, {
|
||||
enumerable: true,
|
||||
get: all[name]
|
||||
});
|
||||
}
|
||||
_export(exports, {
|
||||
ACTION_BEFORE_REFRESH: function() {
|
||||
return ACTION_BEFORE_REFRESH;
|
||||
},
|
||||
ACTION_BUILD_ERROR: function() {
|
||||
return ACTION_BUILD_ERROR;
|
||||
},
|
||||
ACTION_BUILD_OK: function() {
|
||||
return ACTION_BUILD_OK;
|
||||
},
|
||||
ACTION_REFRESH: function() {
|
||||
return ACTION_REFRESH;
|
||||
},
|
||||
ACTION_UNHANDLED_ERROR: function() {
|
||||
return ACTION_UNHANDLED_ERROR;
|
||||
},
|
||||
ACTION_UNHANDLED_REJECTION: function() {
|
||||
return ACTION_UNHANDLED_REJECTION;
|
||||
},
|
||||
ACTION_VERSION_INFO: function() {
|
||||
return ACTION_VERSION_INFO;
|
||||
},
|
||||
INITIAL_OVERLAY_STATE: function() {
|
||||
return INITIAL_OVERLAY_STATE;
|
||||
},
|
||||
REACT_REFRESH_FULL_RELOAD_FROM_ERROR: function() {
|
||||
return REACT_REFRESH_FULL_RELOAD_FROM_ERROR;
|
||||
},
|
||||
useErrorOverlayReducer: function() {
|
||||
return useErrorOverlayReducer;
|
||||
}
|
||||
});
|
||||
const _react = require("react");
|
||||
const ACTION_BUILD_OK = "build-ok";
|
||||
const ACTION_BUILD_ERROR = "build-error";
|
||||
const ACTION_BEFORE_REFRESH = "before-fast-refresh";
|
||||
const ACTION_REFRESH = "fast-refresh";
|
||||
const ACTION_VERSION_INFO = "version-info";
|
||||
const ACTION_UNHANDLED_ERROR = "unhandled-error";
|
||||
const ACTION_UNHANDLED_REJECTION = "unhandled-rejection";
|
||||
function pushErrorFilterDuplicates(errors, err) {
|
||||
return [
|
||||
...errors.filter((e)=>{
|
||||
// Filter out duplicate errors
|
||||
return e.event.reason !== err.event.reason;
|
||||
}),
|
||||
err
|
||||
];
|
||||
}
|
||||
const INITIAL_OVERLAY_STATE = {
|
||||
nextId: 1,
|
||||
buildError: null,
|
||||
errors: [],
|
||||
notFound: false,
|
||||
refreshState: {
|
||||
type: "idle"
|
||||
},
|
||||
rootLayoutMissingTags: [],
|
||||
versionInfo: {
|
||||
installed: "0.0.0",
|
||||
staleness: "unknown"
|
||||
}
|
||||
};
|
||||
function useErrorOverlayReducer() {
|
||||
return (0, _react.useReducer)((_state, action)=>{
|
||||
switch(action.type){
|
||||
case ACTION_BUILD_OK:
|
||||
{
|
||||
return {
|
||||
..._state,
|
||||
buildError: null
|
||||
};
|
||||
}
|
||||
case ACTION_BUILD_ERROR:
|
||||
{
|
||||
return {
|
||||
..._state,
|
||||
buildError: action.message
|
||||
};
|
||||
}
|
||||
case ACTION_BEFORE_REFRESH:
|
||||
{
|
||||
return {
|
||||
..._state,
|
||||
refreshState: {
|
||||
type: "pending",
|
||||
errors: []
|
||||
}
|
||||
};
|
||||
}
|
||||
case ACTION_REFRESH:
|
||||
{
|
||||
return {
|
||||
..._state,
|
||||
buildError: null,
|
||||
errors: // Errors can come in during updates. In this case, UNHANDLED_ERROR
|
||||
// and UNHANDLED_REJECTION events might be dispatched between the
|
||||
// BEFORE_REFRESH and the REFRESH event. We want to keep those errors
|
||||
// around until the next refresh. Otherwise we run into a race
|
||||
// condition where those errors would be cleared on refresh completion
|
||||
// before they can be displayed.
|
||||
_state.refreshState.type === "pending" ? _state.refreshState.errors : [],
|
||||
refreshState: {
|
||||
type: "idle"
|
||||
}
|
||||
};
|
||||
}
|
||||
case ACTION_UNHANDLED_ERROR:
|
||||
case ACTION_UNHANDLED_REJECTION:
|
||||
{
|
||||
switch(_state.refreshState.type){
|
||||
case "idle":
|
||||
{
|
||||
return {
|
||||
..._state,
|
||||
nextId: _state.nextId + 1,
|
||||
errors: pushErrorFilterDuplicates(_state.errors, {
|
||||
id: _state.nextId,
|
||||
event: action
|
||||
})
|
||||
};
|
||||
}
|
||||
case "pending":
|
||||
{
|
||||
return {
|
||||
..._state,
|
||||
nextId: _state.nextId + 1,
|
||||
refreshState: {
|
||||
..._state.refreshState,
|
||||
errors: pushErrorFilterDuplicates(_state.refreshState.errors, {
|
||||
id: _state.nextId,
|
||||
event: action
|
||||
})
|
||||
}
|
||||
};
|
||||
}
|
||||
default:
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
const _ = _state.refreshState;
|
||||
return _state;
|
||||
}
|
||||
}
|
||||
case ACTION_VERSION_INFO:
|
||||
{
|
||||
return {
|
||||
..._state,
|
||||
versionInfo: action.versionInfo
|
||||
};
|
||||
}
|
||||
default:
|
||||
{
|
||||
return _state;
|
||||
}
|
||||
}
|
||||
}, INITIAL_OVERLAY_STATE);
|
||||
}
|
||||
const REACT_REFRESH_FULL_RELOAD_FROM_ERROR = "[Fast Refresh] performing full reload because your application had an unrecoverable error";
|
||||
|
||||
if ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {
|
||||
Object.defineProperty(exports.default, '__esModule', { value: true });
|
||||
Object.assign(exports.default, exports);
|
||||
module.exports = exports.default;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=shared.js.map
|
||||
Reference in New Issue
Block a user