@openuiai/next 15.6.0-bun.22 → 15.6.0-bun.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/dist/bin/next +1 -1
  2. package/dist/build/index.js +3 -3
  3. package/dist/build/swc/index.js +1 -1
  4. package/dist/build/webpack-config.js +2 -2
  5. package/dist/client/app-bootstrap.js +1 -1
  6. package/dist/client/index.js +1 -1
  7. package/dist/compiled/next-server/pages-api-turbo.runtime.prod.js +1 -1
  8. package/dist/compiled/next-server/pages-api-turbo.runtime.prod.js.map +1 -1
  9. package/dist/compiled/next-server/pages-api.runtime.prod.js +1 -1
  10. package/dist/compiled/next-server/pages-api.runtime.prod.js.map +1 -1
  11. package/dist/compiled/next-server/pages-turbo.runtime.prod.js +1 -1
  12. package/dist/compiled/next-server/pages-turbo.runtime.prod.js.map +1 -1
  13. package/dist/compiled/next-server/pages.runtime.prod.js +1 -1
  14. package/dist/compiled/next-server/pages.runtime.prod.js.map +1 -1
  15. package/dist/esm/build/index.js +3 -3
  16. package/dist/esm/build/swc/index.js +1 -1
  17. package/dist/esm/build/webpack-config.js +2 -2
  18. package/dist/esm/client/app-bootstrap.js +1 -1
  19. package/dist/esm/client/index.js +1 -1
  20. package/dist/esm/lib/typescript/writeAppTypeDeclarations.js +5 -3
  21. package/dist/esm/lib/typescript/writeAppTypeDeclarations.js.map +1 -1
  22. package/dist/esm/server/dev/hot-reloader-webpack.js +1 -1
  23. package/dist/esm/server/lib/app-info-log.js +1 -1
  24. package/dist/esm/server/lib/start-server.js +1 -1
  25. package/dist/esm/shared/lib/canary-only.js +1 -1
  26. package/dist/lib/typescript/writeAppTypeDeclarations.js +5 -3
  27. package/dist/lib/typescript/writeAppTypeDeclarations.js.map +1 -1
  28. package/dist/server/dev/hot-reloader-webpack.js +1 -1
  29. package/dist/server/lib/app-info-log.js +1 -1
  30. package/dist/server/lib/start-server.js +1 -1
  31. package/dist/shared/lib/canary-only.js +1 -1
  32. package/dist/telemetry/anonymous-meta.js +1 -1
  33. package/dist/telemetry/events/session-stopped.js +2 -2
  34. package/dist/telemetry/events/version.js +2 -2
  35. package/package.json +1 -1
@@ -301,7 +301,7 @@ export default async function build(dir, reactProductionProfiling = false, debug
301
301
  const nextBuildSpan = trace('next-build', undefined, {
302
302
  buildMode: experimentalBuildMode,
303
303
  isTurboBuild: String(isTurbopack),
304
- version: "15.6.0-bun.20"
304
+ version: "15.6.0-bun.23"
305
305
  });
306
306
  NextBuildContext.nextBuildSpan = nextBuildSpan;
307
307
  NextBuildContext.dir = dir;
@@ -780,7 +780,7 @@ export default async function build(dir, reactProductionProfiling = false, debug
780
780
  // Files outside of the distDir can be "type": "module"
781
781
  await writeFileUtf8(path.join(distDir, 'package.json'), '{"type": "commonjs"}');
782
782
  // These are written to distDir, so they need to come after creating and cleaning distDr.
783
- await recordFrameworkVersion("15.6.0-bun.20");
783
+ await recordFrameworkVersion("15.6.0-bun.23");
784
784
  await updateBuildDiagnostics({
785
785
  buildStage: 'start'
786
786
  });
@@ -2425,7 +2425,7 @@ export default async function build(dir, reactProductionProfiling = false, debug
2425
2425
  distDir,
2426
2426
  config,
2427
2427
  staticPages,
2428
- nextVersion: "15.6.0-bun.20",
2428
+ nextVersion: "15.6.0-bun.23",
2429
2429
  tracingRoot: outputFileTracingRoot,
2430
2430
  hasNodeMiddleware,
2431
2431
  hasInstrumentationHook,
@@ -11,7 +11,7 @@ import { isDeepStrictEqual } from 'util';
11
11
  import { getDefineEnv } from '../define-env';
12
12
  import { getReactCompilerLoader } from '../get-babel-loader-config';
13
13
  import { throwTurbopackInternalError } from '../../shared/lib/turbopack/internal-error';
14
- const nextVersion = "15.6.0-bun.20";
14
+ const nextVersion = "15.6.0-bun.23";
15
15
  const ArchName = arch();
16
16
  const PlatformName = platform();
17
17
  function infoLog(...args) {
@@ -1575,7 +1575,7 @@ export default async function getBaseWebpackConfig(dir, { buildId, encryptionKey
1575
1575
  isClient && new CopyFilePlugin({
1576
1576
  // file path to build output of `@next/polyfill-nomodule`
1577
1577
  filePath: require.resolve('./polyfills/polyfill-nomodule'),
1578
- cacheKey: "15.6.0-bun.20",
1578
+ cacheKey: "15.6.0-bun.23",
1579
1579
  name: `static/chunks/polyfills${dev ? '' : '-[hash]'}.js`,
1580
1580
  minimize: false,
1581
1581
  info: {
@@ -1756,7 +1756,7 @@ export default async function getBaseWebpackConfig(dir, { buildId, encryptionKey
1756
1756
  // - Next.js location on disk (some loaders use absolute paths and some resolve options depend on absolute paths)
1757
1757
  // - Next.js version
1758
1758
  // - next.config.js keys that affect compilation
1759
- version: `${__dirname}|${"15.6.0-bun.20"}|${configVars}`,
1759
+ version: `${__dirname}|${"15.6.0-bun.23"}|${configVars}`,
1760
1760
  cacheDirectory: path.join(distDir, 'cache', 'webpack'),
1761
1761
  // For production builds, it's more efficient to compress all cache files together instead of compression each one individually.
1762
1762
  // So we disable compression here and allow the build runner to take care of compressing the cache as a whole.
@@ -5,7 +5,7 @@
5
5
  * - next/script with `beforeInteractive` strategy
6
6
  */ import { getAssetPrefix } from './asset-prefix';
7
7
  import { setAttributesFromProps } from './set-attributes-from-props';
8
- const version = "15.6.0-bun.20";
8
+ const version = "15.6.0-bun.23";
9
9
  window.next = {
10
10
  version,
11
11
  appDir: true
@@ -26,7 +26,7 @@ import { SearchParamsContext, PathParamsContext } from '../shared/lib/hooks-clie
26
26
  import { onRecoverableError } from './react-client-callbacks/on-recoverable-error';
27
27
  import tracer from './tracing/tracer';
28
28
  import { isNextRouterError } from './components/is-next-router-error';
29
- export const version = "15.6.0-bun.20";
29
+ export const version = "15.6.0-bun.23";
30
30
  export let router;
31
31
  export const emitter = mitt();
32
32
  const looseToArray = (input)=>[].slice.call(input);
@@ -1,6 +1,8 @@
1
1
  import os from 'os';
2
2
  import path from 'path';
3
3
  import { promises as fs } from 'fs';
4
+ // Read package name dynamically to support forked packages
5
+ const PKG_NAME = require(path.join(__dirname, '../../package.json')).name;
4
6
  export async function writeAppTypeDeclarations({ baseDir, distDir, imageImportsEnabled, hasPagesDir, hasAppDir }) {
5
7
  // Reference `next` types
6
8
  const appTypeDeclarations = path.join(baseDir, 'next-env.d.ts');
@@ -26,13 +28,13 @@ export async function writeAppTypeDeclarations({ baseDir, distDir, imageImportsE
26
28
  * @see https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html
27
29
  */ const directives = [
28
30
  // Include the core Next.js typings.
29
- '/// <reference types="next" />'
31
+ `/// <reference types="${PKG_NAME}" />`
30
32
  ];
31
33
  if (imageImportsEnabled) {
32
- directives.push('/// <reference types="next/image-types/global" />');
34
+ directives.push(`/// <reference types="${PKG_NAME}/image-types/global" />`);
33
35
  }
34
36
  if (hasAppDir && hasPagesDir) {
35
- directives.push('/// <reference types="next/navigation-types/compat/navigation" />');
37
+ directives.push(`/// <reference types="${PKG_NAME}/navigation-types/compat/navigation" />`);
36
38
  }
37
39
  const routeTypesPath = path.posix.join(distDir.replaceAll(path.win32.sep, path.posix.sep), 'types/routes.d.ts');
38
40
  // Use ESM import instead of triple-slash reference for better ESLint compatibility
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/lib/typescript/writeAppTypeDeclarations.ts"],"sourcesContent":["import os from 'os'\nimport path from 'path'\nimport { promises as fs } from 'fs'\n\nexport async function writeAppTypeDeclarations({\n baseDir,\n distDir,\n imageImportsEnabled,\n hasPagesDir,\n hasAppDir,\n}: {\n baseDir: string\n distDir: string\n imageImportsEnabled: boolean\n hasPagesDir: boolean\n hasAppDir: boolean\n}): Promise<void> {\n // Reference `next` types\n const appTypeDeclarations = path.join(baseDir, 'next-env.d.ts')\n\n // Defaults EOL to system default\n let eol = os.EOL\n let currentContent: string | undefined\n\n try {\n currentContent = await fs.readFile(appTypeDeclarations, 'utf8')\n // If file already exists then preserve its line ending\n const lf = currentContent.indexOf('\\n', /* skip first so we can lf - 1 */ 1)\n\n if (lf !== -1) {\n if (currentContent[lf - 1] === '\\r') {\n eol = '\\r\\n'\n } else {\n eol = '\\n'\n }\n }\n } catch {}\n\n /**\n * \"Triple-slash directives\" used to create typings files for Next.js projects\n * using Typescript .\n *\n * @see https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html\n */\n const directives: string[] = [\n // Include the core Next.js typings.\n '/// <reference types=\"next\" />',\n ]\n\n if (imageImportsEnabled) {\n directives.push('/// <reference types=\"next/image-types/global\" />')\n }\n\n if (hasAppDir && hasPagesDir) {\n directives.push(\n '/// <reference types=\"next/navigation-types/compat/navigation\" />'\n )\n }\n\n const routeTypesPath = path.posix.join(\n distDir.replaceAll(path.win32.sep, path.posix.sep),\n 'types/routes.d.ts'\n )\n\n // Use ESM import instead of triple-slash reference for better ESLint compatibility\n directives.push(`import \"./${routeTypesPath}\";`)\n\n // Push the notice in.\n directives.push(\n '',\n '// NOTE: This file should not be edited',\n `// see https://nextjs.org/docs/${hasAppDir ? 'app' : 'pages'}/api-reference/config/typescript for more information.`\n )\n\n const content = directives.join(eol) + eol\n\n // Avoids an un-necessary write on read-only fs\n if (currentContent === content) {\n return\n }\n await fs.writeFile(appTypeDeclarations, content)\n}\n"],"names":["os","path","promises","fs","writeAppTypeDeclarations","baseDir","distDir","imageImportsEnabled","hasPagesDir","hasAppDir","appTypeDeclarations","join","eol","EOL","currentContent","readFile","lf","indexOf","directives","push","routeTypesPath","posix","replaceAll","win32","sep","content","writeFile"],"mappings":"AAAA,OAAOA,QAAQ,KAAI;AACnB,OAAOC,UAAU,OAAM;AACvB,SAASC,YAAYC,EAAE,QAAQ,KAAI;AAEnC,OAAO,eAAeC,yBAAyB,EAC7CC,OAAO,EACPC,OAAO,EACPC,mBAAmB,EACnBC,WAAW,EACXC,SAAS,EAOV;IACC,yBAAyB;IACzB,MAAMC,sBAAsBT,KAAKU,IAAI,CAACN,SAAS;IAE/C,iCAAiC;IACjC,IAAIO,MAAMZ,GAAGa,GAAG;IAChB,IAAIC;IAEJ,IAAI;QACFA,iBAAiB,MAAMX,GAAGY,QAAQ,CAACL,qBAAqB;QACxD,uDAAuD;QACvD,MAAMM,KAAKF,eAAeG,OAAO,CAAC,MAAM,+BAA+B,GAAG;QAE1E,IAAID,OAAO,CAAC,GAAG;YACb,IAAIF,cAAc,CAACE,KAAK,EAAE,KAAK,MAAM;gBACnCJ,MAAM;YACR,OAAO;gBACLA,MAAM;YACR;QACF;IACF,EAAE,OAAM,CAAC;IAET;;;;;GAKC,GACD,MAAMM,aAAuB;QAC3B,oCAAoC;QACpC;KACD;IAED,IAAIX,qBAAqB;QACvBW,WAAWC,IAAI,CAAC;IAClB;IAEA,IAAIV,aAAaD,aAAa;QAC5BU,WAAWC,IAAI,CACb;IAEJ;IAEA,MAAMC,iBAAiBnB,KAAKoB,KAAK,CAACV,IAAI,CACpCL,QAAQgB,UAAU,CAACrB,KAAKsB,KAAK,CAACC,GAAG,EAAEvB,KAAKoB,KAAK,CAACG,GAAG,GACjD;IAGF,mFAAmF;IACnFN,WAAWC,IAAI,CAAC,CAAC,UAAU,EAAEC,eAAe,EAAE,CAAC;IAE/C,sBAAsB;IACtBF,WAAWC,IAAI,CACb,IACA,2CACA,CAAC,+BAA+B,EAAEV,YAAY,QAAQ,QAAQ,sDAAsD,CAAC;IAGvH,MAAMgB,UAAUP,WAAWP,IAAI,CAACC,OAAOA;IAEvC,+CAA+C;IAC/C,IAAIE,mBAAmBW,SAAS;QAC9B;IACF;IACA,MAAMtB,GAAGuB,SAAS,CAAChB,qBAAqBe;AAC1C","ignoreList":[0]}
1
+ {"version":3,"sources":["../../../src/lib/typescript/writeAppTypeDeclarations.ts"],"sourcesContent":["import os from 'os'\nimport path from 'path'\nimport { promises as fs } from 'fs'\n\n// Read package name dynamically to support forked packages\nconst PKG_NAME = require(path.join(__dirname, '../../package.json')).name\n\nexport async function writeAppTypeDeclarations({\n baseDir,\n distDir,\n imageImportsEnabled,\n hasPagesDir,\n hasAppDir,\n}: {\n baseDir: string\n distDir: string\n imageImportsEnabled: boolean\n hasPagesDir: boolean\n hasAppDir: boolean\n}): Promise<void> {\n // Reference `next` types\n const appTypeDeclarations = path.join(baseDir, 'next-env.d.ts')\n\n // Defaults EOL to system default\n let eol = os.EOL\n let currentContent: string | undefined\n\n try {\n currentContent = await fs.readFile(appTypeDeclarations, 'utf8')\n // If file already exists then preserve its line ending\n const lf = currentContent.indexOf('\\n', /* skip first so we can lf - 1 */ 1)\n\n if (lf !== -1) {\n if (currentContent[lf - 1] === '\\r') {\n eol = '\\r\\n'\n } else {\n eol = '\\n'\n }\n }\n } catch {}\n\n /**\n * \"Triple-slash directives\" used to create typings files for Next.js projects\n * using Typescript .\n *\n * @see https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html\n */\n const directives: string[] = [\n // Include the core Next.js typings.\n `/// <reference types=\"${PKG_NAME}\" />`,\n ]\n\n if (imageImportsEnabled) {\n directives.push(`/// <reference types=\"${PKG_NAME}/image-types/global\" />`)\n }\n\n if (hasAppDir && hasPagesDir) {\n directives.push(\n `/// <reference types=\"${PKG_NAME}/navigation-types/compat/navigation\" />`\n )\n }\n\n const routeTypesPath = path.posix.join(\n distDir.replaceAll(path.win32.sep, path.posix.sep),\n 'types/routes.d.ts'\n )\n\n // Use ESM import instead of triple-slash reference for better ESLint compatibility\n directives.push(`import \"./${routeTypesPath}\";`)\n\n // Push the notice in.\n directives.push(\n '',\n '// NOTE: This file should not be edited',\n `// see https://nextjs.org/docs/${hasAppDir ? 'app' : 'pages'}/api-reference/config/typescript for more information.`\n )\n\n const content = directives.join(eol) + eol\n\n // Avoids an un-necessary write on read-only fs\n if (currentContent === content) {\n return\n }\n await fs.writeFile(appTypeDeclarations, content)\n}\n"],"names":["os","path","promises","fs","PKG_NAME","require","join","__dirname","name","writeAppTypeDeclarations","baseDir","distDir","imageImportsEnabled","hasPagesDir","hasAppDir","appTypeDeclarations","eol","EOL","currentContent","readFile","lf","indexOf","directives","push","routeTypesPath","posix","replaceAll","win32","sep","content","writeFile"],"mappings":"AAAA,OAAOA,QAAQ,KAAI;AACnB,OAAOC,UAAU,OAAM;AACvB,SAASC,YAAYC,EAAE,QAAQ,KAAI;AAEnC,2DAA2D;AAC3D,MAAMC,WAAWC,QAAQJ,KAAKK,IAAI,CAACC,WAAW,uBAAuBC,IAAI;AAEzE,OAAO,eAAeC,yBAAyB,EAC7CC,OAAO,EACPC,OAAO,EACPC,mBAAmB,EACnBC,WAAW,EACXC,SAAS,EAOV;IACC,yBAAyB;IACzB,MAAMC,sBAAsBd,KAAKK,IAAI,CAACI,SAAS;IAE/C,iCAAiC;IACjC,IAAIM,MAAMhB,GAAGiB,GAAG;IAChB,IAAIC;IAEJ,IAAI;QACFA,iBAAiB,MAAMf,GAAGgB,QAAQ,CAACJ,qBAAqB;QACxD,uDAAuD;QACvD,MAAMK,KAAKF,eAAeG,OAAO,CAAC,MAAM,+BAA+B,GAAG;QAE1E,IAAID,OAAO,CAAC,GAAG;YACb,IAAIF,cAAc,CAACE,KAAK,EAAE,KAAK,MAAM;gBACnCJ,MAAM;YACR,OAAO;gBACLA,MAAM;YACR;QACF;IACF,EAAE,OAAM,CAAC;IAET;;;;;GAKC,GACD,MAAMM,aAAuB;QAC3B,oCAAoC;QACpC,CAAC,sBAAsB,EAAElB,SAAS,IAAI,CAAC;KACxC;IAED,IAAIQ,qBAAqB;QACvBU,WAAWC,IAAI,CAAC,CAAC,sBAAsB,EAAEnB,SAAS,uBAAuB,CAAC;IAC5E;IAEA,IAAIU,aAAaD,aAAa;QAC5BS,WAAWC,IAAI,CACb,CAAC,sBAAsB,EAAEnB,SAAS,uCAAuC,CAAC;IAE9E;IAEA,MAAMoB,iBAAiBvB,KAAKwB,KAAK,CAACnB,IAAI,CACpCK,QAAQe,UAAU,CAACzB,KAAK0B,KAAK,CAACC,GAAG,EAAE3B,KAAKwB,KAAK,CAACG,GAAG,GACjD;IAGF,mFAAmF;IACnFN,WAAWC,IAAI,CAAC,CAAC,UAAU,EAAEC,eAAe,EAAE,CAAC;IAE/C,sBAAsB;IACtBF,WAAWC,IAAI,CACb,IACA,2CACA,CAAC,+BAA+B,EAAET,YAAY,QAAQ,QAAQ,sDAAsD,CAAC;IAGvH,MAAMe,UAAUP,WAAWhB,IAAI,CAACU,OAAOA;IAEvC,+CAA+C;IAC/C,IAAIE,mBAAmBW,SAAS;QAC9B;IACF;IACA,MAAM1B,GAAG2B,SAAS,CAACf,qBAAqBc;AAC1C","ignoreList":[0]}
@@ -158,7 +158,7 @@ export default class HotReloaderWebpack {
158
158
  this.previewProps = previewProps;
159
159
  this.rewrites = rewrites;
160
160
  this.hotReloaderSpan = trace('hot-reloader', undefined, {
161
- version: "15.6.0-bun.20"
161
+ version: "15.6.0-bun.23"
162
162
  });
163
163
  // Ensure the hotReloaderSpan is flushed immediately as it's the parentSpan for all processing
164
164
  // of the current `next dev` invocation.
@@ -14,7 +14,7 @@ export function logStartInfo({ networkUrl, appUrl, envInfo, experimentalFeatures
14
14
  bundlerSuffix = ' (webpack)';
15
15
  }
16
16
  }
17
- Log.bootstrap(`${bold(purple(`${Log.prefixes.ready} Next.js ${"15.6.0-bun.20"}`))}${bundlerSuffix}`);
17
+ Log.bootstrap(`${bold(purple(`${Log.prefixes.ready} Next.js ${"15.6.0-bun.23"}`))}${bundlerSuffix}`);
18
18
  if (appUrl) {
19
19
  Log.bootstrap(`- Local: ${appUrl}`);
20
20
  }
@@ -87,7 +87,7 @@ export async function getRequestHandlers({ dir, port, isDev, onDevServerCleanup,
87
87
  export async function startServer(serverOptions) {
88
88
  const { dir, isDev, hostname, minimalMode, allowRetry, keepAliveTimeout, selfSignedCertificate } = serverOptions;
89
89
  let { port } = serverOptions;
90
- process.title = `next-server (v${"15.6.0-bun.20"})`;
90
+ process.title = `next-server (v${"15.6.0-bun.23"})`;
91
91
  let handlersReady = ()=>{};
92
92
  let handlersError = ()=>{};
93
93
  let handlersPromise = new Promise((resolve, reject)=>{
@@ -1,6 +1,6 @@
1
1
  export function isStableBuild() {
2
2
  var _process_env___NEXT_VERSION;
3
- return !((_process_env___NEXT_VERSION = "15.6.0-bun.20") == null ? void 0 : _process_env___NEXT_VERSION.includes('canary')) && !process.env.__NEXT_TEST_MODE && !process.env.NEXT_PRIVATE_LOCAL_DEV;
3
+ return !((_process_env___NEXT_VERSION = "15.6.0-bun.23") == null ? void 0 : _process_env___NEXT_VERSION.includes('canary')) && !process.env.__NEXT_TEST_MODE && !process.env.NEXT_PRIVATE_LOCAL_DEV;
4
4
  }
5
5
  export class CanaryOnlyError extends Error {
6
6
  constructor(arg){
@@ -16,6 +16,8 @@ function _interop_require_default(obj) {
16
16
  default: obj
17
17
  };
18
18
  }
19
+ // Read package name dynamically to support forked packages
20
+ const PKG_NAME = require(_path.default.join(__dirname, '../../package.json')).name;
19
21
  async function writeAppTypeDeclarations({ baseDir, distDir, imageImportsEnabled, hasPagesDir, hasAppDir }) {
20
22
  // Reference `next` types
21
23
  const appTypeDeclarations = _path.default.join(baseDir, 'next-env.d.ts');
@@ -41,13 +43,13 @@ async function writeAppTypeDeclarations({ baseDir, distDir, imageImportsEnabled,
41
43
  * @see https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html
42
44
  */ const directives = [
43
45
  // Include the core Next.js typings.
44
- '/// <reference types="next" />'
46
+ `/// <reference types="${PKG_NAME}" />`
45
47
  ];
46
48
  if (imageImportsEnabled) {
47
- directives.push('/// <reference types="next/image-types/global" />');
49
+ directives.push(`/// <reference types="${PKG_NAME}/image-types/global" />`);
48
50
  }
49
51
  if (hasAppDir && hasPagesDir) {
50
- directives.push('/// <reference types="next/navigation-types/compat/navigation" />');
52
+ directives.push(`/// <reference types="${PKG_NAME}/navigation-types/compat/navigation" />`);
51
53
  }
52
54
  const routeTypesPath = _path.default.posix.join(distDir.replaceAll(_path.default.win32.sep, _path.default.posix.sep), 'types/routes.d.ts');
53
55
  // Use ESM import instead of triple-slash reference for better ESLint compatibility
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/lib/typescript/writeAppTypeDeclarations.ts"],"sourcesContent":["import os from 'os'\nimport path from 'path'\nimport { promises as fs } from 'fs'\n\nexport async function writeAppTypeDeclarations({\n baseDir,\n distDir,\n imageImportsEnabled,\n hasPagesDir,\n hasAppDir,\n}: {\n baseDir: string\n distDir: string\n imageImportsEnabled: boolean\n hasPagesDir: boolean\n hasAppDir: boolean\n}): Promise<void> {\n // Reference `next` types\n const appTypeDeclarations = path.join(baseDir, 'next-env.d.ts')\n\n // Defaults EOL to system default\n let eol = os.EOL\n let currentContent: string | undefined\n\n try {\n currentContent = await fs.readFile(appTypeDeclarations, 'utf8')\n // If file already exists then preserve its line ending\n const lf = currentContent.indexOf('\\n', /* skip first so we can lf - 1 */ 1)\n\n if (lf !== -1) {\n if (currentContent[lf - 1] === '\\r') {\n eol = '\\r\\n'\n } else {\n eol = '\\n'\n }\n }\n } catch {}\n\n /**\n * \"Triple-slash directives\" used to create typings files for Next.js projects\n * using Typescript .\n *\n * @see https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html\n */\n const directives: string[] = [\n // Include the core Next.js typings.\n '/// <reference types=\"next\" />',\n ]\n\n if (imageImportsEnabled) {\n directives.push('/// <reference types=\"next/image-types/global\" />')\n }\n\n if (hasAppDir && hasPagesDir) {\n directives.push(\n '/// <reference types=\"next/navigation-types/compat/navigation\" />'\n )\n }\n\n const routeTypesPath = path.posix.join(\n distDir.replaceAll(path.win32.sep, path.posix.sep),\n 'types/routes.d.ts'\n )\n\n // Use ESM import instead of triple-slash reference for better ESLint compatibility\n directives.push(`import \"./${routeTypesPath}\";`)\n\n // Push the notice in.\n directives.push(\n '',\n '// NOTE: This file should not be edited',\n `// see https://nextjs.org/docs/${hasAppDir ? 'app' : 'pages'}/api-reference/config/typescript for more information.`\n )\n\n const content = directives.join(eol) + eol\n\n // Avoids an un-necessary write on read-only fs\n if (currentContent === content) {\n return\n }\n await fs.writeFile(appTypeDeclarations, content)\n}\n"],"names":["writeAppTypeDeclarations","baseDir","distDir","imageImportsEnabled","hasPagesDir","hasAppDir","appTypeDeclarations","path","join","eol","os","EOL","currentContent","fs","readFile","lf","indexOf","directives","push","routeTypesPath","posix","replaceAll","win32","sep","content","writeFile"],"mappings":";;;;+BAIsBA;;;eAAAA;;;2DAJP;6DACE;oBACc;;;;;;AAExB,eAAeA,yBAAyB,EAC7CC,OAAO,EACPC,OAAO,EACPC,mBAAmB,EACnBC,WAAW,EACXC,SAAS,EAOV;IACC,yBAAyB;IACzB,MAAMC,sBAAsBC,aAAI,CAACC,IAAI,CAACP,SAAS;IAE/C,iCAAiC;IACjC,IAAIQ,MAAMC,WAAE,CAACC,GAAG;IAChB,IAAIC;IAEJ,IAAI;QACFA,iBAAiB,MAAMC,YAAE,CAACC,QAAQ,CAACR,qBAAqB;QACxD,uDAAuD;QACvD,MAAMS,KAAKH,eAAeI,OAAO,CAAC,MAAM,+BAA+B,GAAG;QAE1E,IAAID,OAAO,CAAC,GAAG;YACb,IAAIH,cAAc,CAACG,KAAK,EAAE,KAAK,MAAM;gBACnCN,MAAM;YACR,OAAO;gBACLA,MAAM;YACR;QACF;IACF,EAAE,OAAM,CAAC;IAET;;;;;GAKC,GACD,MAAMQ,aAAuB;QAC3B,oCAAoC;QACpC;KACD;IAED,IAAId,qBAAqB;QACvBc,WAAWC,IAAI,CAAC;IAClB;IAEA,IAAIb,aAAaD,aAAa;QAC5Ba,WAAWC,IAAI,CACb;IAEJ;IAEA,MAAMC,iBAAiBZ,aAAI,CAACa,KAAK,CAACZ,IAAI,CACpCN,QAAQmB,UAAU,CAACd,aAAI,CAACe,KAAK,CAACC,GAAG,EAAEhB,aAAI,CAACa,KAAK,CAACG,GAAG,GACjD;IAGF,mFAAmF;IACnFN,WAAWC,IAAI,CAAC,CAAC,UAAU,EAAEC,eAAe,EAAE,CAAC;IAE/C,sBAAsB;IACtBF,WAAWC,IAAI,CACb,IACA,2CACA,CAAC,+BAA+B,EAAEb,YAAY,QAAQ,QAAQ,sDAAsD,CAAC;IAGvH,MAAMmB,UAAUP,WAAWT,IAAI,CAACC,OAAOA;IAEvC,+CAA+C;IAC/C,IAAIG,mBAAmBY,SAAS;QAC9B;IACF;IACA,MAAMX,YAAE,CAACY,SAAS,CAACnB,qBAAqBkB;AAC1C","ignoreList":[0]}
1
+ {"version":3,"sources":["../../../src/lib/typescript/writeAppTypeDeclarations.ts"],"sourcesContent":["import os from 'os'\nimport path from 'path'\nimport { promises as fs } from 'fs'\n\n// Read package name dynamically to support forked packages\nconst PKG_NAME = require(path.join(__dirname, '../../package.json')).name\n\nexport async function writeAppTypeDeclarations({\n baseDir,\n distDir,\n imageImportsEnabled,\n hasPagesDir,\n hasAppDir,\n}: {\n baseDir: string\n distDir: string\n imageImportsEnabled: boolean\n hasPagesDir: boolean\n hasAppDir: boolean\n}): Promise<void> {\n // Reference `next` types\n const appTypeDeclarations = path.join(baseDir, 'next-env.d.ts')\n\n // Defaults EOL to system default\n let eol = os.EOL\n let currentContent: string | undefined\n\n try {\n currentContent = await fs.readFile(appTypeDeclarations, 'utf8')\n // If file already exists then preserve its line ending\n const lf = currentContent.indexOf('\\n', /* skip first so we can lf - 1 */ 1)\n\n if (lf !== -1) {\n if (currentContent[lf - 1] === '\\r') {\n eol = '\\r\\n'\n } else {\n eol = '\\n'\n }\n }\n } catch {}\n\n /**\n * \"Triple-slash directives\" used to create typings files for Next.js projects\n * using Typescript .\n *\n * @see https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html\n */\n const directives: string[] = [\n // Include the core Next.js typings.\n `/// <reference types=\"${PKG_NAME}\" />`,\n ]\n\n if (imageImportsEnabled) {\n directives.push(`/// <reference types=\"${PKG_NAME}/image-types/global\" />`)\n }\n\n if (hasAppDir && hasPagesDir) {\n directives.push(\n `/// <reference types=\"${PKG_NAME}/navigation-types/compat/navigation\" />`\n )\n }\n\n const routeTypesPath = path.posix.join(\n distDir.replaceAll(path.win32.sep, path.posix.sep),\n 'types/routes.d.ts'\n )\n\n // Use ESM import instead of triple-slash reference for better ESLint compatibility\n directives.push(`import \"./${routeTypesPath}\";`)\n\n // Push the notice in.\n directives.push(\n '',\n '// NOTE: This file should not be edited',\n `// see https://nextjs.org/docs/${hasAppDir ? 'app' : 'pages'}/api-reference/config/typescript for more information.`\n )\n\n const content = directives.join(eol) + eol\n\n // Avoids an un-necessary write on read-only fs\n if (currentContent === content) {\n return\n }\n await fs.writeFile(appTypeDeclarations, content)\n}\n"],"names":["writeAppTypeDeclarations","PKG_NAME","require","path","join","__dirname","name","baseDir","distDir","imageImportsEnabled","hasPagesDir","hasAppDir","appTypeDeclarations","eol","os","EOL","currentContent","fs","readFile","lf","indexOf","directives","push","routeTypesPath","posix","replaceAll","win32","sep","content","writeFile"],"mappings":";;;;+BAOsBA;;;eAAAA;;;2DAPP;6DACE;oBACc;;;;;;AAE/B,2DAA2D;AAC3D,MAAMC,WAAWC,QAAQC,aAAI,CAACC,IAAI,CAACC,WAAW,uBAAuBC,IAAI;AAElE,eAAeN,yBAAyB,EAC7CO,OAAO,EACPC,OAAO,EACPC,mBAAmB,EACnBC,WAAW,EACXC,SAAS,EAOV;IACC,yBAAyB;IACzB,MAAMC,sBAAsBT,aAAI,CAACC,IAAI,CAACG,SAAS;IAE/C,iCAAiC;IACjC,IAAIM,MAAMC,WAAE,CAACC,GAAG;IAChB,IAAIC;IAEJ,IAAI;QACFA,iBAAiB,MAAMC,YAAE,CAACC,QAAQ,CAACN,qBAAqB;QACxD,uDAAuD;QACvD,MAAMO,KAAKH,eAAeI,OAAO,CAAC,MAAM,+BAA+B,GAAG;QAE1E,IAAID,OAAO,CAAC,GAAG;YACb,IAAIH,cAAc,CAACG,KAAK,EAAE,KAAK,MAAM;gBACnCN,MAAM;YACR,OAAO;gBACLA,MAAM;YACR;QACF;IACF,EAAE,OAAM,CAAC;IAET;;;;;GAKC,GACD,MAAMQ,aAAuB;QAC3B,oCAAoC;QACpC,CAAC,sBAAsB,EAAEpB,SAAS,IAAI,CAAC;KACxC;IAED,IAAIQ,qBAAqB;QACvBY,WAAWC,IAAI,CAAC,CAAC,sBAAsB,EAAErB,SAAS,uBAAuB,CAAC;IAC5E;IAEA,IAAIU,aAAaD,aAAa;QAC5BW,WAAWC,IAAI,CACb,CAAC,sBAAsB,EAAErB,SAAS,uCAAuC,CAAC;IAE9E;IAEA,MAAMsB,iBAAiBpB,aAAI,CAACqB,KAAK,CAACpB,IAAI,CACpCI,QAAQiB,UAAU,CAACtB,aAAI,CAACuB,KAAK,CAACC,GAAG,EAAExB,aAAI,CAACqB,KAAK,CAACG,GAAG,GACjD;IAGF,mFAAmF;IACnFN,WAAWC,IAAI,CAAC,CAAC,UAAU,EAAEC,eAAe,EAAE,CAAC;IAE/C,sBAAsB;IACtBF,WAAWC,IAAI,CACb,IACA,2CACA,CAAC,+BAA+B,EAAEX,YAAY,QAAQ,QAAQ,sDAAsD,CAAC;IAGvH,MAAMiB,UAAUP,WAAWjB,IAAI,CAACS,OAAOA;IAEvC,+CAA+C;IAC/C,IAAIG,mBAAmBY,SAAS;QAC9B;IACF;IACA,MAAMX,YAAE,CAACY,SAAS,CAACjB,qBAAqBgB;AAC1C","ignoreList":[0]}
@@ -226,7 +226,7 @@ class HotReloaderWebpack {
226
226
  this.previewProps = previewProps;
227
227
  this.rewrites = rewrites;
228
228
  this.hotReloaderSpan = (0, _trace.trace)('hot-reloader', undefined, {
229
- version: "15.6.0-bun.20"
229
+ version: "15.6.0-bun.23"
230
230
  });
231
231
  // Ensure the hotReloaderSpan is flushed immediately as it's the parentSpan for all processing
232
232
  // of the current `next dev` invocation.
@@ -82,7 +82,7 @@ function logStartInfo({ networkUrl, appUrl, envInfo, experimentalFeatures, logBu
82
82
  bundlerSuffix = ' (webpack)';
83
83
  }
84
84
  }
85
- _log.bootstrap(`${(0, _picocolors.bold)((0, _picocolors.purple)(`${_log.prefixes.ready} Next.js ${"15.6.0-bun.20"}`))}${bundlerSuffix}`);
85
+ _log.bootstrap(`${(0, _picocolors.bold)((0, _picocolors.purple)(`${_log.prefixes.ready} Next.js ${"15.6.0-bun.23"}`))}${bundlerSuffix}`);
86
86
  if (appUrl) {
87
87
  _log.bootstrap(`- Local: ${appUrl}`);
88
88
  }
@@ -155,7 +155,7 @@ async function getRequestHandlers({ dir, port, isDev, onDevServerCleanup, server
155
155
  async function startServer(serverOptions) {
156
156
  const { dir, isDev, hostname, minimalMode, allowRetry, keepAliveTimeout, selfSignedCertificate } = serverOptions;
157
157
  let { port } = serverOptions;
158
- process.title = `next-server (v${"15.6.0-bun.20"})`;
158
+ process.title = `next-server (v${"15.6.0-bun.23"})`;
159
159
  let handlersReady = ()=>{};
160
160
  let handlersError = ()=>{};
161
161
  let handlersPromise = new Promise((resolve, reject)=>{
@@ -22,7 +22,7 @@ _export(exports, {
22
22
  });
23
23
  function isStableBuild() {
24
24
  var _process_env___NEXT_VERSION;
25
- return !((_process_env___NEXT_VERSION = "15.6.0-bun.20") == null ? void 0 : _process_env___NEXT_VERSION.includes('canary')) && !process.env.__NEXT_TEST_MODE && !process.env.NEXT_PRIVATE_LOCAL_DEV;
25
+ return !((_process_env___NEXT_VERSION = "15.6.0-bun.23") == null ? void 0 : _process_env___NEXT_VERSION.includes('canary')) && !process.env.__NEXT_TEST_MODE && !process.env.NEXT_PRIVATE_LOCAL_DEV;
26
26
  }
27
27
  class CanaryOnlyError extends Error {
28
28
  constructor(arg){
@@ -81,7 +81,7 @@ function getAnonymousMeta() {
81
81
  isWsl: _iswsl.default,
82
82
  isCI: _ciinfo.isCI,
83
83
  ciName: _ciinfo.isCI && _ciinfo.name || null,
84
- nextVersion: "15.6.0-bun.20"
84
+ nextVersion: "15.6.0-bun.23"
85
85
  };
86
86
  return traits;
87
87
  }
@@ -11,11 +11,11 @@ Object.defineProperty(exports, "eventCliSessionStopped", {
11
11
  const EVENT_VERSION = 'NEXT_CLI_SESSION_STOPPED';
12
12
  function eventCliSessionStopped(event) {
13
13
  // This should be an invariant, if it fails our build tooling is broken.
14
- if (typeof "15.6.0-bun.20" !== 'string') {
14
+ if (typeof "15.6.0-bun.23" !== 'string') {
15
15
  return [];
16
16
  }
17
17
  const payload = {
18
- nextVersion: "15.6.0-bun.20",
18
+ nextVersion: "15.6.0-bun.23",
19
19
  nodeVersion: process.version,
20
20
  cliCommand: event.cliCommand,
21
21
  durationMilliseconds: event.durationMilliseconds,
@@ -12,12 +12,12 @@ const EVENT_VERSION = 'NEXT_CLI_SESSION_STARTED';
12
12
  function eventCliSession(nextConfig, event) {
13
13
  var _nextConfig_experimental_staleTimes, _nextConfig_experimental_staleTimes1, _nextConfig_experimental_reactCompiler, _nextConfig_experimental_reactCompiler1;
14
14
  // This should be an invariant, if it fails our build tooling is broken.
15
- if (typeof "15.6.0-bun.20" !== 'string') {
15
+ if (typeof "15.6.0-bun.23" !== 'string') {
16
16
  return [];
17
17
  }
18
18
  const { images, i18n } = nextConfig || {};
19
19
  const payload = {
20
- nextVersion: "15.6.0-bun.20",
20
+ nextVersion: "15.6.0-bun.23",
21
21
  nodeVersion: process.version,
22
22
  cliCommand: event.cliCommand,
23
23
  isSrcDir: event.isSrcDir,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openuiai/next",
3
- "version": "15.6.0-bun.22",
3
+ "version": "15.6.0-bun.24",
4
4
  "description": "The React Framework - Self-Hosted First Fork with Full Bun Support",
5
5
  "main": "./dist/server/next.js",
6
6
  "license": "MIT",