@absolutejs/absolute 0.20.0-beta.107 → 0.20.0-beta.109

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/build.js CHANGED
@@ -12329,9 +12329,33 @@ var init_islandRegistryTransform = __esm(() => {
12329
12329
  ];
12330
12330
  });
12331
12331
 
12332
+ // src/build/vueModuleOutputPath.ts
12333
+ import { isAbsolute as isAbsolute4, join as join23, parse as parse2, relative as relative9, resolve as resolve17, sep as sep2 } from "path";
12334
+ var vueModuleOutputPath = (outputDir, sourcePath) => {
12335
+ const absolutePath = resolve17(sourcePath);
12336
+ const { root } = parse2(absolutePath);
12337
+ return join23(outputDir, "sources", encodeURIComponent(root), relative9(root, absolutePath).replace(/\.(vue|ts)$/, ".js"));
12338
+ }, vueModuleSourcePath = (outputDir, outputPath) => {
12339
+ const within = relative9(outputDir, outputPath);
12340
+ if (isAbsolute4(within) || within === ".." || within.startsWith(`..${sep2}`))
12341
+ return null;
12342
+ const [namespace, encodedRoot, ...parts] = within.split(sep2);
12343
+ if (namespace !== "sources" || !encodedRoot || !parts.length)
12344
+ return null;
12345
+ try {
12346
+ const root = decodeURIComponent(encodedRoot);
12347
+ if (parse2(root).root !== root || !isAbsolute4(root))
12348
+ return null;
12349
+ return join23(root, ...parts);
12350
+ } catch {
12351
+ return null;
12352
+ }
12353
+ };
12354
+ var init_vueModuleOutputPath = () => {};
12355
+
12332
12356
  // src/build/injectVueComposableTracking.ts
12333
12357
  import { existsSync as existsSync22, readFileSync as readFileSync13, writeFileSync as writeFileSync6 } from "fs";
12334
- import { basename as basename9, isAbsolute as isAbsolute4, relative as relative9, resolve as resolve17 } from "path";
12358
+ import { basename as basename9, isAbsolute as isAbsolute5, relative as relative10, resolve as resolve18 } from "path";
12335
12359
  var VUE_HMR_RUNTIME, USE_DECLARATION, MODULE_COMMENT, LINE_TERMINATOR, STATEMENT_OPENER, SOURCE_EXTENSIONS2, CHUNK_REFERENCE, isSharedChunkFile = (fileName) => fileName.startsWith("chunk-") && fileName.endsWith(".js"), collectModuleComments = (content) => Array.from(content.matchAll(MODULE_COMMENT), (match) => ({
12336
12360
  index: match.index,
12337
12361
  path: match[1] ?? ""
@@ -12433,20 +12457,23 @@ var VUE_HMR_RUNTIME, USE_DECLARATION, MODULE_COMMENT, LINE_TERMINATOR, STATEMENT
12433
12457
  return restore(`${wrapped.slice(0, insertAt)}${VUE_HMR_RUNTIME}
12434
12458
  ${wrapped.slice(insertAt)}`);
12435
12459
  }, isSharedChunkPath = (path) => isSharedChunkFile(basename9(path)), resolveVueComposableModuleId = (commentPath, options) => {
12436
- const absolutePath = resolve17(options.projectRoot, commentPath);
12460
+ const absolutePath = resolve18(options.projectRoot, commentPath);
12437
12461
  const { vueDir, generatedVueDir } = options;
12438
12462
  if (!vueDir || !generatedVueDir)
12439
12463
  return absolutePath;
12440
- const withinGenerated = relative9(generatedVueDir, absolutePath);
12441
- if (withinGenerated === "" || withinGenerated.startsWith("..") || isAbsolute4(withinGenerated)) {
12464
+ const withinGenerated = relative10(generatedVueDir, absolutePath);
12465
+ if (withinGenerated === "" || withinGenerated.startsWith("..") || isAbsolute5(withinGenerated)) {
12442
12466
  return absolutePath;
12443
12467
  }
12444
- const fromClientDir = relative9(resolve17(generatedVueDir, "client"), absolutePath);
12445
- const stem = resolve17(vueDir, fromClientDir).replace(/\.[cm]?js$/, "");
12468
+ const sourcePath = vueModuleSourcePath(resolve18(generatedVueDir, "client"), absolutePath);
12469
+ if (!sourcePath)
12470
+ return absolutePath;
12471
+ const stem = sourcePath.replace(/\.[cm]?js$/, "");
12446
12472
  const existing = SOURCE_EXTENSIONS2.map((extension) => `${stem}${extension}`).find((candidate) => existsSync22(candidate));
12447
12473
  return existing ?? `${stem}.ts`;
12448
12474
  };
12449
12475
  var init_injectVueComposableTracking = __esm(() => {
12476
+ init_vueModuleOutputPath();
12450
12477
  init_constants();
12451
12478
  init_maskLiterals();
12452
12479
  VUE_HMR_RUNTIME = [
@@ -12484,7 +12511,7 @@ __export(exports_hmrInjectionPlugin, {
12484
12511
  createAngularHmrInjectionPlugin: () => createAngularHmrInjectionPlugin
12485
12512
  });
12486
12513
  import { readFile as readFile5 } from "fs/promises";
12487
- import { relative as relative10, resolve as resolve18 } from "path";
12514
+ import { relative as relative11, resolve as resolve19 } from "path";
12488
12515
  var ENTITY_DECORATOR_RE, IMPORT_RE, TOP_LEVEL_DECL_RE, extractAllTopLevelNames = (jsSource) => {
12489
12516
  const names = new Set;
12490
12517
  IMPORT_RE.lastIndex = 0;
@@ -12663,7 +12690,7 @@ var ENTITY_DECORATOR_RE, IMPORT_RE, TOP_LEVEL_DECL_RE, extractAllTopLevelNames =
12663
12690
  }
12664
12691
  `, applyAngularHmrInjection = (jsSource, componentJsAbsPath, params) => {
12665
12692
  const { generatedAngularRoot, userAngularRoot, projectRoot } = params;
12666
- const normalizedGenRoot = resolve18(generatedAngularRoot).replace(/\\/g, "/");
12693
+ const normalizedGenRoot = resolve19(generatedAngularRoot).replace(/\\/g, "/");
12667
12694
  const normalizedPath = componentJsAbsPath.replace(/\\/g, "/");
12668
12695
  if (!normalizedPath.startsWith(`${normalizedGenRoot}/`))
12669
12696
  return;
@@ -12680,9 +12707,9 @@ var ENTITY_DECORATOR_RE, IMPORT_RE, TOP_LEVEL_DECL_RE, extractAllTopLevelNames =
12680
12707
  }
12681
12708
  if (classNames.length === 0)
12682
12709
  return;
12683
- const relFromGenRoot = relative10(generatedAngularRoot, componentJsAbsPath).replace(/\\/g, "/");
12684
- const userTsPath = resolve18(userAngularRoot, relFromGenRoot.replace(/\.js$/, ".ts"));
12685
- const projectRel = relative10(projectRoot, userTsPath).replace(/\\/g, "/");
12710
+ const relFromGenRoot = relative11(generatedAngularRoot, componentJsAbsPath).replace(/\\/g, "/");
12711
+ const userTsPath = resolve19(userAngularRoot, relFromGenRoot.replace(/\.js$/, ".ts"));
12712
+ const projectRel = relative11(projectRoot, userTsPath).replace(/\\/g, "/");
12686
12713
  const tail = classNames.map((className) => {
12687
12714
  const id = `${projectRel}@${className}`;
12688
12715
  return buildHmrTail(className, JSON.stringify(id));
@@ -12716,17 +12743,17 @@ var init_hmrInjectionPlugin = __esm(() => {
12716
12743
 
12717
12744
  // src/utils/cleanStaleOutputs.ts
12718
12745
  import { rm as rm2 } from "fs/promises";
12719
- import { resolve as resolve19 } from "path";
12746
+ import { resolve as resolve20 } from "path";
12720
12747
  var {Glob: Glob5 } = globalThis.Bun;
12721
12748
  var HASHED_FILE_PATTERN, ROOT_CHUNK_PATTERN, isContentAddressedOutput = (relativePath) => HASHED_FILE_PATTERN.test(relativePath) || ROOT_CHUNK_PATTERN.test(relativePath), cleanStaleOutputs = async (buildPath, currentOutputPaths) => {
12722
- const currentPaths = new Set(currentOutputPaths.map((path) => resolve19(path)));
12749
+ const currentPaths = new Set(currentOutputPaths.map((path) => resolve20(path)));
12723
12750
  const glob = new Glob5("**/*");
12724
12751
  const removals = [];
12725
- for (const relative11 of glob.scanSync({ cwd: buildPath })) {
12726
- const absolute = resolve19(buildPath, relative11);
12752
+ for (const relative12 of glob.scanSync({ cwd: buildPath })) {
12753
+ const absolute = resolve20(buildPath, relative12);
12727
12754
  if (currentPaths.has(absolute))
12728
12755
  continue;
12729
- if (!isContentAddressedOutput(relative11))
12756
+ if (!isContentAddressedOutput(relative12))
12730
12757
  continue;
12731
12758
  removals.push(rm2(absolute, { force: true }));
12732
12759
  }
@@ -12743,13 +12770,13 @@ __export(exports_generatedDir, {
12743
12770
  getFrameworkGeneratedDir: () => getFrameworkGeneratedDir,
12744
12771
  getGeneratedRoot: () => getGeneratedRoot
12745
12772
  });
12746
- import { join as join23 } from "path";
12747
- var GENERATED_DIR_NAME = "generated", ABSOLUTE_CACHE_DIR_NAME = ".absolutejs", getFrameworkGeneratedDir = (framework, projectRoot = process.cwd()) => join23(getGeneratedRoot(projectRoot), framework), getGeneratedRoot = (projectRoot = process.cwd()) => join23(projectRoot, ABSOLUTE_CACHE_DIR_NAME, GENERATED_DIR_NAME);
12773
+ import { join as join24 } from "path";
12774
+ var GENERATED_DIR_NAME = "generated", ABSOLUTE_CACHE_DIR_NAME = ".absolutejs", getFrameworkGeneratedDir = (framework, projectRoot = process.cwd()) => join24(getGeneratedRoot(projectRoot), framework), getGeneratedRoot = (projectRoot = process.cwd()) => join24(projectRoot, ABSOLUTE_CACHE_DIR_NAME, GENERATED_DIR_NAME);
12748
12775
  var init_generatedDir = () => {};
12749
12776
 
12750
12777
  // src/utils/cleanup.ts
12751
12778
  import { lstat, rm as rm3 } from "fs/promises";
12752
- import { join as join24 } from "path";
12779
+ import { join as join25 } from "path";
12753
12780
  var isNotFoundError = (error) => error instanceof Error && ("code" in error) && Reflect.get(error, "code") === "ENOENT", removeIfExists = async (path) => {
12754
12781
  try {
12755
12782
  await lstat(path);
@@ -12766,9 +12793,9 @@ var isNotFoundError = (error) => error instanceof Error && ("code" in error) &&
12766
12793
  }
12767
12794
  if (!frameworkDir)
12768
12795
  return Promise.all(tasks);
12769
- tasks.push(removeIfExists(join24(frameworkDir, "generated")));
12796
+ tasks.push(removeIfExists(join25(frameworkDir, "generated")));
12770
12797
  if (framework === "angular") {
12771
- tasks.push(removeIfExists(join24(frameworkDir, "compiled")), removeIfExists(join24(frameworkDir, "indexes")));
12798
+ tasks.push(removeIfExists(join25(frameworkDir, "compiled")), removeIfExists(join25(frameworkDir, "indexes")));
12772
12799
  }
12773
12800
  return Promise.all(tasks);
12774
12801
  }, cleanup = async ({
@@ -12836,7 +12863,7 @@ var init_commonAncestor = () => {};
12836
12863
 
12837
12864
  // src/utils/buildDirectoryLock.ts
12838
12865
  import { mkdirSync as mkdirSync7, unlinkSync, writeFileSync as writeFileSync7, readFileSync as readFileSync14 } from "fs";
12839
- import { dirname as dirname13, join as join25 } from "path";
12866
+ import { dirname as dirname13, join as join26 } from "path";
12840
12867
  var heldLocks, HELD_LOCKS_ENV = "ABSOLUTE_HELD_BUILD_DIRECTORY_LOCKS", exitHandlersRegistered = false, registerExitHandlersOnce = () => {
12841
12868
  if (exitHandlersRegistered)
12842
12869
  return;
@@ -12863,7 +12890,7 @@ var heldLocks, HELD_LOCKS_ENV = "ABSOLUTE_HELD_BUILD_DIRECTORY_LOCKS", exitHandl
12863
12890
  console.error(err);
12864
12891
  process.exit(1);
12865
12892
  });
12866
- }, isAlreadyExistsError = (error) => error instanceof Error && ("code" in error) && Reflect.get(error, "code") === "EEXIST", lockPathForBuildDirectory = (buildDirectory) => join25(dirname13(buildDirectory), ".absolutejs", "build.lock"), readHeldLockEnv = () => new Set((process.env[HELD_LOCKS_ENV] ?? "").split(`
12893
+ }, isAlreadyExistsError = (error) => error instanceof Error && ("code" in error) && Reflect.get(error, "code") === "EEXIST", lockPathForBuildDirectory = (buildDirectory) => join26(dirname13(buildDirectory), ".absolutejs", "build.lock"), readHeldLockEnv = () => new Set((process.env[HELD_LOCKS_ENV] ?? "").split(`
12867
12894
  `).filter((entry) => entry.length > 0)), writeHeldLockEnv = (locks) => {
12868
12895
  if (locks.size === 0) {
12869
12896
  delete process.env[HELD_LOCKS_ENV];
@@ -13000,11 +13027,11 @@ var init_buildDirectoryLock = __esm(() => {
13000
13027
  });
13001
13028
 
13002
13029
  // src/utils/validateSafePath.ts
13003
- import { resolve as resolve20, relative as relative11 } from "path";
13030
+ import { resolve as resolve21, relative as relative12 } from "path";
13004
13031
  var validateSafePath = (targetPath, baseDirectory) => {
13005
- const absoluteBase = resolve20(baseDirectory);
13006
- const absoluteTarget = resolve20(baseDirectory, targetPath);
13007
- const relativePath = normalizePath(relative11(absoluteBase, absoluteTarget));
13032
+ const absoluteBase = resolve21(baseDirectory);
13033
+ const absoluteTarget = resolve21(baseDirectory, targetPath);
13034
+ const relativePath = normalizePath(relative12(absoluteBase, absoluteTarget));
13008
13035
  if (relativePath.startsWith("../") || relativePath === "..") {
13009
13036
  throw new Error(`Unsafe path: ${targetPath}`);
13010
13037
  }
@@ -13357,7 +13384,7 @@ var isTestSourcePath = (file) => {
13357
13384
 
13358
13385
  // src/mobile/deviceCapabilities.ts
13359
13386
  import { existsSync as existsSync23, readFileSync as readFileSync15 } from "fs";
13360
- import { extname as extname9, join as join26, relative as relative12, resolve as resolve21 } from "path";
13387
+ import { extname as extname9, join as join27, relative as relative13, resolve as resolve22 } from "path";
13361
13388
  import { fileURLToPath as fileURLToPath2 } from "url";
13362
13389
  import ts8 from "typescript";
13363
13390
  var DEVICES_PACKAGE = "@absolutejs/devices", ABSOLUTE_MOBILE_SHELL_DEVICE_CAPABILITIES, ADAPTERS, SOURCE_GLOB, IGNORED_DIRECTORIES, IDENTIFIER_PATTERN, providerModulePattern = (provider) => new RegExp(`^@absolutejs/devices-${provider}/[a-z][a-z0-9-]*$`, "u"), providerPackagePattern = (provider) => provider === "capacitor" ? /^@capacitor\/[a-z][a-z0-9-]*@\d+\.\d+\.\d+$/u : /^(?:expo-[a-z][a-z0-9-]*|@react-native-[a-z0-9-]+\/[a-z][a-z0-9-]*)@\d+\.\d+\.\d+$/u, providerLabel = (provider) => provider === "capacitor" ? "Capacitor" : "Expo", ANDROID_PERMISSION_PATTERN, IOS_USAGE_DESCRIPTIONS, IOS_PRIVACY_ACCESSED_API_REASONS, IOS_PRIVACY_ACCESSED_APIS, object = (value) => typeof value === "object" && value !== null && !Array.isArray(value), readJson = (path) => {
@@ -13485,7 +13512,7 @@ var DEVICES_PACKAGE = "@absolutejs/devices", ABSOLUTE_MOBILE_SHELL_DEVICE_CAPABI
13485
13512
  };
13486
13513
  }, loadAbsoluteDeviceCapabilityProviders = (projectRoot, provider = "capacitor") => {
13487
13514
  const adapter = ADAPTERS[provider];
13488
- let path = join26(resolve21(projectRoot), "node_modules", adapter, "package.json");
13515
+ let path = join27(resolve22(projectRoot), "node_modules", adapter, "package.json");
13489
13516
  try {
13490
13517
  readFileSync15(path, "utf8");
13491
13518
  } catch {
@@ -13540,7 +13567,7 @@ var DEVICES_PACKAGE = "@absolutejs/devices", ABSOLUTE_MOBILE_SHELL_DEVICE_CAPABI
13540
13567
  if (missing.includes(spec))
13541
13568
  return false;
13542
13569
  try {
13543
- return readJson(join26(resolve21(projectRoot), "node_modules", packageName, "package.json")).version !== spec.slice(separator + 1);
13570
+ return readJson(join27(resolve22(projectRoot), "node_modules", packageName, "package.json")).version !== spec.slice(separator + 1);
13544
13571
  } catch {
13545
13572
  return true;
13546
13573
  }
@@ -13549,7 +13576,7 @@ var DEVICES_PACKAGE = "@absolutejs/devices", ABSOLUTE_MOBILE_SHELL_DEVICE_CAPABI
13549
13576
  if (unmet.length > 0)
13550
13577
  throw new TypeError(`Device capabilities ${plan.capabilities.join(", ")} require ${unmet.join(", ")}. Run absolute mobile sync and approve the detected capability plugins.`);
13551
13578
  }, directAbsoluteProjectPackages = (projectRoot) => {
13552
- const manifest = readJson(join26(resolve21(projectRoot), "package.json"));
13579
+ const manifest = readJson(join27(resolve22(projectRoot), "package.json"));
13553
13580
  const packages = new Set;
13554
13581
  for (const field of ["dependencies", "devDependencies"]) {
13555
13582
  const dependencies = manifest[field];
@@ -13559,16 +13586,16 @@ var DEVICES_PACKAGE = "@absolutejs/devices", ABSOLUTE_MOBILE_SHELL_DEVICE_CAPABI
13559
13586
  }
13560
13587
  return packages;
13561
13588
  }, discoverAbsoluteDeviceCapabilities = (projectRoot, providers = loadAbsoluteDeviceCapabilityProviders(projectRoot)) => {
13562
- const root = resolve21(projectRoot);
13589
+ const root = resolve22(projectRoot);
13563
13590
  if (!existsSync23(root))
13564
13591
  return [];
13565
13592
  const known = new Set(Object.keys(providers));
13566
13593
  const capabilities = new Set;
13567
13594
  for (const path of SOURCE_GLOB.scanSync({ cwd: root })) {
13568
- const portable = relative12(root, resolve21(root, path)).replaceAll("\\", "/");
13595
+ const portable = relative13(root, resolve22(root, path)).replaceAll("\\", "/");
13569
13596
  if (isIgnored(portable))
13570
13597
  continue;
13571
- const source = readFileSync15(resolve21(root, portable), "utf8");
13598
+ const source = readFileSync15(resolve22(root, portable), "utf8");
13572
13599
  for (const name of importedCapabilities(source, portable))
13573
13600
  if (known.has(name))
13574
13601
  capabilities.add(name);
@@ -13578,12 +13605,12 @@ var DEVICES_PACKAGE = "@absolutejs/devices", ABSOLUTE_MOBILE_SHELL_DEVICE_CAPABI
13578
13605
  const packageName = spec.slice(0, spec.lastIndexOf("@"));
13579
13606
  return !directPackages.has(packageName);
13580
13607
  }), projectImportsAbsoluteDeviceCapability = (projectRoot, capability) => {
13581
- const root = resolve21(projectRoot);
13608
+ const root = resolve22(projectRoot);
13582
13609
  for (const path of SOURCE_GLOB.scanSync({ cwd: root })) {
13583
- const portable = relative12(root, resolve21(root, path)).replaceAll("\\", "/");
13610
+ const portable = relative13(root, resolve22(root, path)).replaceAll("\\", "/");
13584
13611
  if (isIgnored(portable))
13585
13612
  continue;
13586
- const source = readFileSync15(resolve21(root, portable), "utf8");
13613
+ const source = readFileSync15(resolve22(root, portable), "utf8");
13587
13614
  if (importedCapabilities(source, portable).has(capability))
13588
13615
  return true;
13589
13616
  }
@@ -13779,7 +13806,7 @@ var init_client = __esm(() => {
13779
13806
 
13780
13807
  // src/mobile/syncSchema.ts
13781
13808
  import { readFileSync as readFileSync16 } from "fs";
13782
- import { dirname as dirname14, join as join27, resolve as resolve22 } from "path";
13809
+ import { dirname as dirname14, join as join28, resolve as resolve23 } from "path";
13783
13810
  var object2 = (value) => typeof value === "object" && value !== null && !Array.isArray(value), manifestAt = (path) => {
13784
13811
  try {
13785
13812
  const value = JSON.parse(readFileSync16(path, "utf8"));
@@ -13796,9 +13823,9 @@ var object2 = (value) => typeof value === "object" && value !== null && !Array.i
13796
13823
  return;
13797
13824
  return Reflect.get(sync, "localSchema");
13798
13825
  }, packageManifestPath = (projectRoot, packageName) => {
13799
- let directory = resolve22(projectRoot);
13826
+ let directory = resolve23(projectRoot);
13800
13827
  while (true) {
13801
- const candidate = join27(directory, "node_modules", packageName, "package.json");
13828
+ const candidate = join28(directory, "node_modules", packageName, "package.json");
13802
13829
  const manifest = manifestAt(candidate);
13803
13830
  if (manifest && Reflect.get(manifest, "name") === packageName)
13804
13831
  return candidate;
@@ -14029,7 +14056,7 @@ var object2 = (value) => typeof value === "object" && value !== null && !Array.i
14029
14056
  Reflect.get(manifest, "devDependencies"),
14030
14057
  Reflect.get(manifest, "peerDependencies")
14031
14058
  ].flatMap((dependencies) => object2(dependencies) ? Object.keys(dependencies) : []).filter((name, index, names) => names.indexOf(name) === index).sort(), discoverAbsoluteSyncSchema = (projectRoot) => {
14032
- const appManifestPath = join27(resolve22(projectRoot), "package.json");
14059
+ const appManifestPath = join28(resolve23(projectRoot), "package.json");
14033
14060
  const appManifest = manifestAt(appManifestPath);
14034
14061
  if (!appManifest)
14035
14062
  return {
@@ -14073,7 +14100,7 @@ var init_syncSchema = __esm(() => {
14073
14100
 
14074
14101
  // src/build/pwa.ts
14075
14102
  import { mkdir as mkdir5, rm as rm4, writeFile as writeFile5 } from "fs/promises";
14076
- import { dirname as dirname15, join as join28 } from "path";
14103
+ import { dirname as dirname15, join as join29 } from "path";
14077
14104
  var BOOTSTRAP_PUBLIC_PATH = "/__absolute/pwa/bootstrap.js", BOOTSTRAP_MARKER = "data-absolute-pwa", publicFilePath = (value, fallback, field) => {
14078
14105
  const input = value ?? fallback;
14079
14106
  if (!input.startsWith("/") || input.startsWith("//")) {
@@ -14100,7 +14127,7 @@ var BOOTSTRAP_PUBLIC_PATH = "/__absolute/pwa/bootstrap.js", BOOTSTRAP_MARKER = "
14100
14127
  }
14101
14128
  }
14102
14129
  return url.pathname;
14103
- }, destinationFor = (buildPath, publicPath) => join28(buildPath, ...publicPath.split("/").filter(Boolean)), bootstrapEntrySource = ({
14130
+ }, destinationFor = (buildPath, publicPath) => join29(buildPath, ...publicPath.split("/").filter(Boolean)), bootstrapEntrySource = ({
14104
14131
  clientModule,
14105
14132
  manifestPath,
14106
14133
  push,
@@ -14177,8 +14204,8 @@ ${push ? `,
14177
14204
  await writeFile5(manifestDestination, `${JSON.stringify(createWebAppManifest(manifestConfig), null, "\t")}
14178
14205
  `);
14179
14206
  }
14180
- const generatedDirectory = join28(generatedRoot, "pwa");
14181
- const bootstrapEntry = join28(generatedDirectory, "bootstrap.ts");
14207
+ const generatedDirectory = join29(generatedRoot, "pwa");
14208
+ const bootstrapEntry = join29(generatedDirectory, "bootstrap.ts");
14182
14209
  const clientModule = Bun.resolveSync("@absolutejs/pwa/client", import.meta.dir);
14183
14210
  await mkdir5(generatedDirectory, { recursive: true });
14184
14211
  await writeFile5(bootstrapEntry, bootstrapEntrySource({
@@ -14933,7 +14960,7 @@ __export(exports_fastHmrCompiler, {
14933
14960
  tryFastHmr: () => tryFastHmr
14934
14961
  });
14935
14962
  import { existsSync as existsSync24, readFileSync as readFileSync17, statSync as statSync3 } from "fs";
14936
- import { dirname as dirname16, extname as extname10, relative as relative13, resolve as resolve23 } from "path";
14963
+ import { dirname as dirname16, extname as extname10, relative as relative14, resolve as resolve24 } from "path";
14937
14964
  import ts12 from "typescript";
14938
14965
  var fail = (reason, detail, location) => ({
14939
14966
  detail,
@@ -15045,7 +15072,7 @@ var fail = (reason, detail, location) => ({
15045
15072
  const decoratorName = findAngularDecoratorName(decorators);
15046
15073
  if (!decoratorName)
15047
15074
  continue;
15048
- const projectRel = relative13(process.cwd(), componentFilePath).replace(/\\/g, "/");
15075
+ const projectRel = relative14(process.cwd(), componentFilePath).replace(/\\/g, "/");
15049
15076
  const id = encodeURIComponent(`${projectRel}@${className}`);
15050
15077
  if (decoratorName === "Component") {
15051
15078
  const componentDecorator = decorators.find((d2) => {
@@ -15248,7 +15275,7 @@ var fail = (reason, detail, location) => ({
15248
15275
  if (!spec.startsWith(".") && !spec.startsWith("/")) {
15249
15276
  return true;
15250
15277
  }
15251
- const base = resolve23(componentDir, spec);
15278
+ const base = resolve24(componentDir, spec);
15252
15279
  const candidates = [
15253
15280
  `${base}.ts`,
15254
15281
  `${base}.tsx`,
@@ -16064,7 +16091,7 @@ var fail = (reason, detail, location) => ({
16064
16091
  return null;
16065
16092
  }, resolveDtsFromSpec = (spec, fromDir) => {
16066
16093
  const stripped = spec.replace(/\.[mc]?js$/, "");
16067
- const base = resolve23(fromDir, stripped);
16094
+ const base = resolve24(fromDir, stripped);
16068
16095
  const candidates = [
16069
16096
  `${base}.d.ts`,
16070
16097
  `${base}.d.mts`,
@@ -16088,7 +16115,7 @@ var fail = (reason, detail, location) => ({
16088
16115
  return null;
16089
16116
  }, resolveChildComponentInfo = (className, spec, componentDir, projectRoot) => {
16090
16117
  if (spec.startsWith(".") || spec.startsWith("/")) {
16091
- const base = resolve23(componentDir, spec);
16118
+ const base = resolve24(componentDir, spec);
16092
16119
  const candidates = [
16093
16120
  `${base}.ts`,
16094
16121
  `${base}.tsx`,
@@ -16307,13 +16334,13 @@ var fail = (reason, detail, location) => ({
16307
16334
  }
16308
16335
  if (!matches)
16309
16336
  continue;
16310
- const resolved = resolve23(componentDir, spec);
16337
+ const resolved = resolve24(componentDir, spec);
16311
16338
  for (const ext of TS_EXTENSIONS) {
16312
16339
  const candidate = resolved + ext;
16313
16340
  if (existsSync24(candidate))
16314
16341
  return candidate;
16315
16342
  }
16316
- const indexCandidate = resolve23(resolved, "index.ts");
16343
+ const indexCandidate = resolve24(resolved, "index.ts");
16317
16344
  if (existsSync24(indexCandidate))
16318
16345
  return indexCandidate;
16319
16346
  }
@@ -16551,7 +16578,7 @@ ${transpiled}
16551
16578
  }
16552
16579
  }${staticPatch}`;
16553
16580
  }, STYLE_PREPROCESSED_EXT, resolveAndReadStyleResource = (componentDir, url) => {
16554
- const abs = resolve23(componentDir, url);
16581
+ const abs = resolve24(componentDir, url);
16555
16582
  if (!existsSync24(abs))
16556
16583
  return null;
16557
16584
  const ext = extname10(abs).toLowerCase();
@@ -16590,7 +16617,7 @@ ${block}
16590
16617
  const cached = projectOptionsCache.get(projectRoot);
16591
16618
  if (cached !== undefined)
16592
16619
  return cached;
16593
- const tsconfigPath = resolve23(projectRoot, "tsconfig.json");
16620
+ const tsconfigPath = resolve24(projectRoot, "tsconfig.json");
16594
16621
  const opts = {};
16595
16622
  if (existsSync24(tsconfigPath)) {
16596
16623
  try {
@@ -16636,7 +16663,7 @@ ${block}
16636
16663
  }
16637
16664
  const kind = params.kind ?? "component";
16638
16665
  if (kind !== "component") {
16639
- const entityId = encodeURIComponent(`${relative13(projectRoot, componentFilePath).replace(/\\/g, "/")}@${className}`);
16666
+ const entityId = encodeURIComponent(`${relative14(projectRoot, componentFilePath).replace(/\\/g, "/")}@${className}`);
16640
16667
  const currentEntityFingerprint = extractEntityFingerprint(classNode, className, sourceFile);
16641
16668
  const cachedEntityFingerprint = entityFingerprintCache.get(entityId);
16642
16669
  if (cachedEntityFingerprint !== undefined && !entityFingerprintsEqual(cachedEntityFingerprint, currentEntityFingerprint)) {
@@ -16674,7 +16701,7 @@ ${block}
16674
16701
  templateText = decoratorMeta.template;
16675
16702
  templatePath = componentFilePath;
16676
16703
  } else if (decoratorMeta.templateUrl) {
16677
- const tplAbs = resolve23(componentDir, decoratorMeta.templateUrl);
16704
+ const tplAbs = resolve24(componentDir, decoratorMeta.templateUrl);
16678
16705
  if (!existsSync24(tplAbs)) {
16679
16706
  return fail("template-resource-not-found", `Template file not found: ${tplAbs}`, { file: componentFilePath });
16680
16707
  }
@@ -16720,7 +16747,7 @@ ${block}
16720
16747
  return fail("class-not-found", "anonymous class");
16721
16748
  const wrappedClass = new compiler.WrappedNodeExpr(className_);
16722
16749
  const { inputs, outputs, hasDecoratorIO, hasSignalIO } = extractInputsAndOutputs(classNode, compiler);
16723
- const projectRelPath = relative13(projectRoot, componentFilePath).replace(/\\/g, "/");
16750
+ const projectRelPath = relative14(projectRoot, componentFilePath).replace(/\\/g, "/");
16724
16751
  const fingerprintId = encodeURIComponent(`${projectRelPath}@${className}`);
16725
16752
  const currentFingerprint = extractFingerprint(classNode, className, decoratorMeta, inputs, outputs, sourceFile, componentDir);
16726
16753
  const cachedFingerprint = fingerprintCache.get(fingerprintId);
@@ -17003,7 +17030,7 @@ __export(exports_scanVueSsrOnlyPages, {
17003
17030
  scanVueSsrOnlyPages: () => scanVueSsrOnlyPages
17004
17031
  });
17005
17032
  import { readdirSync as readdirSync3, readFileSync as readFileSync18 } from "fs";
17006
- import { join as join29 } from "path";
17033
+ import { join as join30 } from "path";
17007
17034
  import ts13 from "typescript";
17008
17035
  var SKIP_DIRS2, SOURCE_EXTENSIONS3, getScriptKind3 = (filePath) => {
17009
17036
  if (filePath.endsWith(".tsx"))
@@ -17036,9 +17063,9 @@ var SKIP_DIRS2, SOURCE_EXTENSIONS3, getScriptKind3 = (filePath) => {
17036
17063
  continue;
17037
17064
  if (entry.name.startsWith("."))
17038
17065
  continue;
17039
- stack.push(join29(dir, entry.name));
17066
+ stack.push(join30(dir, entry.name));
17040
17067
  } else if (entry.isFile() && hasSourceExtension2(entry.name)) {
17041
- out.push(join29(dir, entry.name));
17068
+ out.push(join30(dir, entry.name));
17042
17069
  }
17043
17070
  }
17044
17071
  }
@@ -17158,7 +17185,7 @@ var init_scanVueSsrOnlyPages = __esm(() => {
17158
17185
 
17159
17186
  // src/build/scanAngularHandlerCalls.ts
17160
17187
  import { readdirSync as readdirSync4, readFileSync as readFileSync19 } from "fs";
17161
- import { join as join30 } from "path";
17188
+ import { join as join31 } from "path";
17162
17189
  import ts14 from "typescript";
17163
17190
  var ELYSIA_ROUTE_METHODS2, SKIP_DIRS3, SOURCE_EXTENSIONS4, SERVER_ENTRY_COPY_PREFIX = ".absolutejs-hmr-", getScriptKind4 = (filePath) => {
17164
17191
  if (filePath.endsWith(".tsx"))
@@ -17191,9 +17218,9 @@ var ELYSIA_ROUTE_METHODS2, SKIP_DIRS3, SOURCE_EXTENSIONS4, SERVER_ENTRY_COPY_PRE
17191
17218
  continue;
17192
17219
  if (entry.name.startsWith("."))
17193
17220
  continue;
17194
- stack.push(join30(dir, entry.name));
17221
+ stack.push(join31(dir, entry.name));
17195
17222
  } else if (entry.isFile() && !entry.name.startsWith(SERVER_ENTRY_COPY_PREFIX) && hasSourceExtension3(entry.name)) {
17196
- out.push(join30(dir, entry.name));
17223
+ out.push(join31(dir, entry.name));
17197
17224
  }
17198
17225
  }
17199
17226
  }
@@ -17308,7 +17335,7 @@ var init_scanAngularHandlerCalls = __esm(() => {
17308
17335
 
17309
17336
  // src/build/scanAngularPageRoutes.ts
17310
17337
  import { readdirSync as readdirSync5, readFileSync as readFileSync20 } from "fs";
17311
- import { basename as basename12, join as join31 } from "path";
17338
+ import { basename as basename12, join as join32 } from "path";
17312
17339
  import ts15 from "typescript";
17313
17340
  var SOURCE_EXTENSIONS5, SKIP_DIRS4, hasSourceExtension4 = (filePath) => {
17314
17341
  const idx = filePath.lastIndexOf(".");
@@ -17348,9 +17375,9 @@ var SOURCE_EXTENSIONS5, SKIP_DIRS4, hasSourceExtension4 = (filePath) => {
17348
17375
  continue;
17349
17376
  if (entry.name.startsWith("."))
17350
17377
  continue;
17351
- stack.push(join31(dir, entry.name));
17378
+ stack.push(join32(dir, entry.name));
17352
17379
  } else if (entry.isFile() && isPageFile(entry.name)) {
17353
- out.push(join31(dir, entry.name));
17380
+ out.push(join32(dir, entry.name));
17354
17381
  }
17355
17382
  }
17356
17383
  }
@@ -17427,7 +17454,7 @@ __export(exports_parseAngularConfigImports, {
17427
17454
  parseAngularProvidersImport: () => parseAngularProvidersImport
17428
17455
  });
17429
17456
  import { existsSync as existsSync25, readFileSync as readFileSync21 } from "fs";
17430
- import { dirname as dirname17, isAbsolute as isAbsolute5, join as join32 } from "path";
17457
+ import { dirname as dirname17, isAbsolute as isAbsolute6, join as join33 } from "path";
17431
17458
  import ts16 from "typescript";
17432
17459
  var findDefineConfigCall = (sf) => {
17433
17460
  let result = null;
@@ -17482,15 +17509,15 @@ var findDefineConfigCall = (sf) => {
17482
17509
  }, resolveConfigPath = (projectRoot) => {
17483
17510
  const envOverride = process.env.ABSOLUTE_CONFIG;
17484
17511
  if (envOverride) {
17485
- const resolved = isAbsolute5(envOverride) ? envOverride : join32(projectRoot, envOverride);
17512
+ const resolved = isAbsolute6(envOverride) ? envOverride : join33(projectRoot, envOverride);
17486
17513
  if (existsSync25(resolved))
17487
17514
  return resolved;
17488
17515
  }
17489
17516
  const candidates = [
17490
- join32(projectRoot, "absolute.config.ts"),
17491
- join32(projectRoot, "absolute.config.mts"),
17492
- join32(projectRoot, "absolute.config.js"),
17493
- join32(projectRoot, "absolute.config.mjs")
17517
+ join33(projectRoot, "absolute.config.ts"),
17518
+ join33(projectRoot, "absolute.config.mts"),
17519
+ join33(projectRoot, "absolute.config.js"),
17520
+ join33(projectRoot, "absolute.config.mjs")
17494
17521
  ];
17495
17522
  for (const candidate of candidates) {
17496
17523
  if (existsSync25(candidate))
@@ -17523,7 +17550,7 @@ var findDefineConfigCall = (sf) => {
17523
17550
  if (!importInfo)
17524
17551
  return null;
17525
17552
  const configDir2 = dirname17(configPath2);
17526
- const absolutePath = importInfo.source.startsWith(".") ? join32(configDir2, importInfo.source).replace(/\.[cm]?[tj]sx?$/, "") : isAbsolute5(importInfo.source) ? importInfo.source.replace(/\.[cm]?[tj]sx?$/, "") : importInfo.source;
17553
+ const absolutePath = importInfo.source.startsWith(".") ? join33(configDir2, importInfo.source).replace(/\.[cm]?[tj]sx?$/, "") : isAbsolute6(importInfo.source) ? importInfo.source.replace(/\.[cm]?[tj]sx?$/, "") : importInfo.source;
17527
17554
  return {
17528
17555
  absolutePath,
17529
17556
  bindingName: binding,
@@ -17675,25 +17702,25 @@ import { existsSync as existsSync26 } from "fs";
17675
17702
  import { mkdir as mkdir6, stat as stat2 } from "fs/promises";
17676
17703
  import {
17677
17704
  dirname as dirname18,
17678
- join as join33,
17705
+ join as join34,
17679
17706
  basename as basename13,
17680
17707
  extname as extname11,
17681
- resolve as resolve24,
17682
- relative as relative14,
17683
- sep as sep2
17708
+ resolve as resolve25,
17709
+ relative as relative15,
17710
+ sep as sep3
17684
17711
  } from "path";
17685
17712
  import { env } from "process";
17686
17713
  var {write: write2, file, Transpiler: Transpiler2 } = globalThis.Bun;
17687
17714
  var resolveDevClientDir2 = () => {
17688
17715
  const projectRoot = process.cwd();
17689
- const fromSource = resolve24(import.meta.dir, "../dev/client");
17716
+ const fromSource = resolve25(import.meta.dir, "../dev/client");
17690
17717
  if (existsSync26(fromSource) && fromSource.startsWith(projectRoot)) {
17691
17718
  return fromSource;
17692
17719
  }
17693
- const fromNodeModules = resolve24(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
17720
+ const fromNodeModules = resolve25(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
17694
17721
  if (existsSync26(fromNodeModules))
17695
17722
  return fromNodeModules;
17696
- return resolve24(import.meta.dir, "./dev/client");
17723
+ return resolve25(import.meta.dir, "./dev/client");
17697
17724
  }, devClientDir2, hmrClientPath3, persistentCache, sourceHashCache, clearSvelteCompilerCache = () => {
17698
17725
  persistentCache.clear();
17699
17726
  sourceHashCache.clear();
@@ -17723,7 +17750,7 @@ var resolveDevClientDir2 = () => {
17723
17750
  }, resolveRelativeModule2 = async (spec, from) => {
17724
17751
  if (!spec.startsWith("."))
17725
17752
  return null;
17726
- const basePath = resolve24(dirname18(from), spec);
17753
+ const basePath = resolve25(dirname18(from), spec);
17727
17754
  const candidates = [
17728
17755
  basePath,
17729
17756
  `${basePath}.ts`,
@@ -17734,14 +17761,14 @@ var resolveDevClientDir2 = () => {
17734
17761
  `${basePath}.svelte`,
17735
17762
  `${basePath}.svelte.ts`,
17736
17763
  `${basePath}.svelte.js`,
17737
- join33(basePath, "index.ts"),
17738
- join33(basePath, "index.js"),
17739
- join33(basePath, "index.mjs"),
17740
- join33(basePath, "index.cjs"),
17741
- join33(basePath, "index.json"),
17742
- join33(basePath, "index.svelte"),
17743
- join33(basePath, "index.svelte.ts"),
17744
- join33(basePath, "index.svelte.js")
17764
+ join34(basePath, "index.ts"),
17765
+ join34(basePath, "index.js"),
17766
+ join34(basePath, "index.mjs"),
17767
+ join34(basePath, "index.cjs"),
17768
+ join34(basePath, "index.json"),
17769
+ join34(basePath, "index.svelte"),
17770
+ join34(basePath, "index.svelte.ts"),
17771
+ join34(basePath, "index.svelte.js")
17745
17772
  ];
17746
17773
  const checks = await Promise.all(candidates.map(exists));
17747
17774
  return candidates.find((_2, index) => checks[index]) ?? null;
@@ -17750,7 +17777,7 @@ var resolveDevClientDir2 = () => {
17750
17777
  const resolved = resolvePackageImport(spec);
17751
17778
  return resolved && /\.svelte(\.(?:ts|js))?$/.test(resolved) ? resolved : null;
17752
17779
  }
17753
- const basePath = resolve24(dirname18(from), spec);
17780
+ const basePath = resolve25(dirname18(from), spec);
17754
17781
  const explicit = /\.(svelte|svelte\.(?:ts|js))$/.test(basePath);
17755
17782
  if (!explicit) {
17756
17783
  const extensions = [".svelte", ".svelte.ts", ".svelte.js"];
@@ -17771,8 +17798,8 @@ var resolveDevClientDir2 = () => {
17771
17798
  return jsPath;
17772
17799
  return null;
17773
17800
  }, addModuleRewrite = (rewrites, rawSpec, resolvedModule, ssrOutputDir, clientOutputDir) => {
17774
- const toServer = relative14(ssrOutputDir, resolvedModule).replace(/\\/g, "/");
17775
- const toClient = relative14(clientOutputDir, resolvedModule).replace(/\\/g, "/");
17801
+ const toServer = relative15(ssrOutputDir, resolvedModule).replace(/\\/g, "/");
17802
+ const toClient = relative15(clientOutputDir, resolvedModule).replace(/\\/g, "/");
17776
17803
  rewrites.set(rawSpec, {
17777
17804
  client: toClient.startsWith(".") || toClient.startsWith("/") ? toClient : `./${toClient}`,
17778
17805
  server: toServer.startsWith(".") ? toServer : `./${toServer}`
@@ -17780,9 +17807,9 @@ var resolveDevClientDir2 = () => {
17780
17807
  }, compileSvelte = async (entryPoints, svelteRoot, cache = new Map, isDev2 = false, stylePreprocessors) => {
17781
17808
  const { compile, compileModule, preprocess } = await import("svelte/compiler");
17782
17809
  const generatedDir = getFrameworkGeneratedDir("svelte");
17783
- const clientDir = join33(generatedDir, "client");
17784
- const indexDir = join33(generatedDir, "indexes");
17785
- const serverDir = join33(generatedDir, "server");
17810
+ const clientDir = join34(generatedDir, "client");
17811
+ const indexDir = join34(generatedDir, "indexes");
17812
+ const serverDir = join34(generatedDir, "server");
17786
17813
  await Promise.all([clientDir, indexDir, serverDir].map((dir) => mkdir6(dir, { recursive: true })));
17787
17814
  const dev = env.NODE_ENV !== "production";
17788
17815
  const build = async (src) => {
@@ -17810,8 +17837,8 @@ var resolveDevClientDir2 = () => {
17810
17837
  const preprocessedClient = isModule ? loweredClientSource.code : (await preprocess(loweredClientSource.code, svelteStylePreprocessor)).code;
17811
17838
  const transpiledServer = src.endsWith(".ts") || src.endsWith(".svelte.ts") ? transpiler3.transformSync(preprocessedServer) : preprocessedServer;
17812
17839
  const transpiledClient = src.endsWith(".ts") || src.endsWith(".svelte.ts") ? transpiler3.transformSync(preprocessedClient) : preprocessedClient;
17813
- const rawRel = dirname18(relative14(svelteRoot, src)).replace(/\\/g, "/");
17814
- const relDir = rawRel.startsWith("..") ? `_ext/${relative14(process.cwd(), dirname18(src)).replace(/\\/g, "/")}` : rawRel;
17840
+ const rawRel = dirname18(relative15(svelteRoot, src)).replace(/\\/g, "/");
17841
+ const relDir = rawRel.startsWith("..") ? `_ext/${relative15(process.cwd(), dirname18(src)).replace(/\\/g, "/")}` : rawRel;
17815
17842
  const baseName = basename13(src).replace(/\.svelte(\.(ts|js))?$/, "");
17816
17843
  const importPaths = Array.from(transpiledServer.matchAll(/from\s+['"]([^'"]+)['"]/g)).map((match) => match[1]).filter((path) => path !== undefined);
17817
17844
  const resolvedModuleImports = await Promise.all(importPaths.map((importPath) => resolveRelativeModule2(importPath, src)));
@@ -17820,8 +17847,8 @@ var resolveDevClientDir2 = () => {
17820
17847
  const childBuilt = await Promise.all(childSources.map((child) => build(child)));
17821
17848
  const hasAwaitSlotFromChildren = childBuilt.some((child) => child.hasAwaitSlot);
17822
17849
  const externalRewrites = new Map;
17823
- const ssrOutputDir = dirname18(join33(serverDir, relDir, `${baseName}.js`));
17824
- const clientOutputDir = dirname18(join33(clientDir, relDir, `${baseName}.js`));
17850
+ const ssrOutputDir = dirname18(join34(serverDir, relDir, `${baseName}.js`));
17851
+ const clientOutputDir = dirname18(join34(clientDir, relDir, `${baseName}.js`));
17825
17852
  for (let idx = 0;idx < importPaths.length; idx++) {
17826
17853
  const rawSpec = importPaths[idx];
17827
17854
  if (!rawSpec)
@@ -17832,15 +17859,15 @@ var resolveDevClientDir2 = () => {
17832
17859
  addModuleRewrite(externalRewrites, rawSpec, resolvedModule, ssrOutputDir, clientOutputDir);
17833
17860
  if (!resolved)
17834
17861
  continue;
17835
- const childRel = relative14(svelteRoot, resolved).replace(/\\/g, "/");
17862
+ const childRel = relative15(svelteRoot, resolved).replace(/\\/g, "/");
17836
17863
  if (!childRel.startsWith(".."))
17837
17864
  continue;
17838
17865
  const childBuilt2 = cache.get(resolved);
17839
17866
  if (!childBuilt2)
17840
17867
  continue;
17841
17868
  const origSpec = rawSpec.replace(/\.svelte(?:\.(?:ts|js))?$/, ".js");
17842
- const toServer = relative14(ssrOutputDir, childBuilt2.ssr).replace(/\\/g, "/");
17843
- const toClient = relative14(clientOutputDir, childBuilt2.client).replace(/\\/g, "/");
17869
+ const toServer = relative15(ssrOutputDir, childBuilt2.ssr).replace(/\\/g, "/");
17870
+ const toClient = relative15(clientOutputDir, childBuilt2.client).replace(/\\/g, "/");
17844
17871
  externalRewrites.set(origSpec, {
17845
17872
  client: toClient.startsWith(".") ? toClient : `./${toClient}`,
17846
17873
  server: toServer.startsWith(".") ? toServer : `./${toServer}`
@@ -17874,7 +17901,7 @@ var resolveDevClientDir2 = () => {
17874
17901
  }).js;
17875
17902
  let code2 = compiledJs.code.replace(/\.svelte(?:\.(?:ts|js))?(['"])/g, ".js$1");
17876
17903
  if (mode === "client" && isDev2) {
17877
- const moduleKey = `/@src/${relative14(process.cwd(), src).replace(/\\/g, "/")}`;
17904
+ const moduleKey = `/@src/${relative15(process.cwd(), src).replace(/\\/g, "/")}`;
17878
17905
  code2 = code2.replace(/if\s*\(import\.meta\.hot\)\s*\{/, `if (typeof window !== "undefined") {
17879
17906
  if (!window.__SVELTE_HMR_ACCEPT__) window.__SVELTE_HMR_ACCEPT__ = {};
17880
17907
  var __hmr_accept = function(cb) { window.__SVELTE_HMR_ACCEPT__[${JSON.stringify(moduleKey)}] = cb; };`);
@@ -17886,8 +17913,8 @@ var resolveDevClientDir2 = () => {
17886
17913
  code2 += islandMetadataExports;
17887
17914
  return { code: code2, map: compiledJs.map };
17888
17915
  };
17889
- const ssrPath = join33(serverDir, relDir, `${baseName}.js`);
17890
- const clientPath = join33(clientDir, relDir, `${baseName}.js`);
17916
+ const ssrPath = join34(serverDir, relDir, `${baseName}.js`);
17917
+ const clientPath = join34(clientDir, relDir, `${baseName}.js`);
17891
17918
  await Promise.all([
17892
17919
  mkdir6(dirname18(ssrPath), { recursive: true }),
17893
17920
  mkdir6(dirname18(clientPath), { recursive: true })
@@ -17925,10 +17952,10 @@ var resolveDevClientDir2 = () => {
17925
17952
  const roots = await Promise.all(entryPoints.map(build));
17926
17953
  const componentRoots = roots.filter((root) => !root.isModule);
17927
17954
  await Promise.all(componentRoots.map(async ({ client, hasAwaitSlot }) => {
17928
- const relClientDir = dirname18(relative14(clientDir, client));
17955
+ const relClientDir = dirname18(relative15(clientDir, client));
17929
17956
  const name = basename13(client, extname11(client));
17930
- const indexPath = join33(indexDir, relClientDir, `${name}.js`);
17931
- const importRaw = relative14(dirname18(indexPath), client).split(sep2).join("/");
17957
+ const indexPath = join34(indexDir, relClientDir, `${name}.js`);
17958
+ const importRaw = relative15(dirname18(indexPath), client).split(sep3).join("/");
17932
17959
  const importPath = importRaw.startsWith(".") || importRaw.startsWith("/") ? importRaw : `./${importRaw}`;
17933
17960
  const hmrImports = isDev2 ? `window.__HMR_FRAMEWORK__ = "svelte";
17934
17961
  import "${hmrClientPath3}";
@@ -18029,8 +18056,8 @@ if (typeof window !== "undefined") {
18029
18056
  return {
18030
18057
  svelteClientPaths: roots.map(({ client }) => client),
18031
18058
  svelteIndexPaths: componentRoots.map(({ client }) => {
18032
- const rel = dirname18(relative14(clientDir, client));
18033
- return join33(indexDir, rel, basename13(client));
18059
+ const rel = dirname18(relative15(clientDir, client));
18060
+ return join34(indexDir, rel, basename13(client));
18034
18061
  }),
18035
18062
  svelteServerPaths: roots.map(({ ssr }) => ssr)
18036
18063
  };
@@ -18045,7 +18072,7 @@ var init_compileSvelte = __esm(() => {
18045
18072
  init_lowerAwaitSlotSyntax();
18046
18073
  init_renderToReadableStream();
18047
18074
  devClientDir2 = resolveDevClientDir2();
18048
- hmrClientPath3 = join33(devClientDir2, "hmrClient.ts").replace(/\\/g, "/");
18075
+ hmrClientPath3 = join34(devClientDir2, "hmrClient.ts").replace(/\\/g, "/");
18049
18076
  persistentCache = new Map;
18050
18077
  sourceHashCache = new Map;
18051
18078
  transpiler3 = new Transpiler2({ loader: "ts", target: "browser" });
@@ -18536,8 +18563,8 @@ var init_chainInlineSourcemaps = __esm(() => {
18536
18563
  import { createHash as createHash4 } from "crypto";
18537
18564
  import { existsSync as existsSync27, readFileSync as readFileSync23 } from "fs";
18538
18565
  import { mkdir as mkdir7, rename, writeFile as writeFile6 } from "fs/promises";
18539
- import { join as join34, resolve as resolve25 } from "path";
18540
- var CACHE_DIR_NAME = "compile-cache", ABSOLUTE_CACHE_DIR_NAME2 = ".absolutejs", CACHE_FORMAT_VERSION = 1, FILE_NAME_HASH_LENGTH = 32, vueCompileCacheEnabled = () => process.env.ABSOLUTE_COMPILE_CACHE !== "0", hashContent = (content) => createHash4("sha256").update(content).digest("hex"), hashParts = (parts) => {
18566
+ import { join as join35, resolve as resolve26 } from "path";
18567
+ var CACHE_DIR_NAME = "compile-cache", ABSOLUTE_CACHE_DIR_NAME2 = ".absolutejs", CACHE_FORMAT_VERSION = 2, FILE_NAME_HASH_LENGTH = 32, vueCompileCacheEnabled = () => process.env.ABSOLUTE_COMPILE_CACHE !== "0", hashContent = (content) => createHash4("sha256").update(content).digest("hex"), hashParts = (parts) => {
18541
18568
  const hash = createHash4("sha256");
18542
18569
  for (const part of parts) {
18543
18570
  hash.update(part);
@@ -18546,8 +18573,8 @@ var CACHE_DIR_NAME = "compile-cache", ABSOLUTE_CACHE_DIR_NAME2 = ".absolutejs",
18546
18573
  return hash.digest("hex");
18547
18574
  }, readOwnPackageVersion = () => {
18548
18575
  const candidates = [
18549
- resolve25(import.meta.dir, "..", "..", "package.json"),
18550
- resolve25(import.meta.dir, "..", "package.json")
18576
+ resolve26(import.meta.dir, "..", "..", "package.json"),
18577
+ resolve26(import.meta.dir, "..", "package.json")
18551
18578
  ];
18552
18579
  for (const candidate of candidates) {
18553
18580
  try {
@@ -18562,7 +18589,7 @@ var CACHE_DIR_NAME = "compile-cache", ABSOLUTE_CACHE_DIR_NAME2 = ".absolutejs",
18562
18589
  }, cachedFrameworkVersion, frameworkVersionForCache = () => {
18563
18590
  cachedFrameworkVersion ??= readOwnPackageVersion();
18564
18591
  return cachedFrameworkVersion;
18565
- }, vueCompileCacheDir = (projectRoot = process.cwd()) => join34(projectRoot, ABSOLUTE_CACHE_DIR_NAME2, CACHE_DIR_NAME, "vue"), entryFileFor = (sourceFilePath, projectRoot) => join34(vueCompileCacheDir(projectRoot), `${hashContent(sourceFilePath).slice(0, FILE_NAME_HASH_LENGTH)}.json`), vueCompileCacheFingerprint = (parts) => {
18592
+ }, vueCompileCacheDir = (projectRoot = process.cwd()) => join35(projectRoot, ABSOLUTE_CACHE_DIR_NAME2, CACHE_DIR_NAME, "vue"), entryFileFor = (sourceFilePath, projectRoot) => join35(vueCompileCacheDir(projectRoot), `${hashContent(sourceFilePath).slice(0, FILE_NAME_HASH_LENGTH)}.json`), vueCompileCacheFingerprint = (parts) => {
18566
18593
  const frameworkVersion = frameworkVersionForCache();
18567
18594
  if (!frameworkVersion)
18568
18595
  return null;
@@ -18628,8 +18655,8 @@ __export(exports_emitTsHelpers, {
18628
18655
  var {file: file2, Transpiler: Transpiler3, write: write3 } = globalThis.Bun;
18629
18656
  import { copyFileSync as copyFileSync2, existsSync as existsSync28, readdirSync as readdirSync6 } from "fs";
18630
18657
  import { mkdir as mkdir8, rename as rename2, writeFile as writeFile7 } from "fs/promises";
18631
- import { dirname as dirname19, join as join35 } from "path";
18632
- var CACHE_DIR_NAME2 = "vue-helpers", CACHE_FORMAT_VERSION2 = 1, HASH_LENGTH = 24, transpiler4, cacheDir = () => join35(process.cwd(), ".absolutejs", "compile-cache", CACHE_DIR_NAME2), cacheKey2 = (sourcePath, sourceCode) => {
18658
+ import { dirname as dirname19, join as join36 } from "path";
18659
+ var CACHE_DIR_NAME2 = "vue-helpers", CACHE_FORMAT_VERSION2 = 1, HASH_LENGTH = 24, transpiler4, cacheDir = () => join36(process.cwd(), ".absolutejs", "compile-cache", CACHE_DIR_NAME2), cacheKey2 = (sourcePath, sourceCode) => {
18633
18660
  const frameworkVersion = frameworkVersionForCache();
18634
18661
  if (!frameworkVersion || !vueCompileCacheEnabled())
18635
18662
  return null;
@@ -18662,13 +18689,13 @@ var CACHE_DIR_NAME2 = "vue-helpers", CACHE_FORMAT_VERSION2 = 1, HASH_LENGTH = 24
18662
18689
  }, publishCacheEntry = async (directory, fileName, pathHash, content) => {
18663
18690
  try {
18664
18691
  await mkdir8(directory, { recursive: true });
18665
- const target = join35(directory, fileName);
18692
+ const target = join36(directory, fileName);
18666
18693
  const temporary = `${target}.${process.pid}.tmp`;
18667
18694
  await writeFile7(temporary, content);
18668
18695
  await rename2(temporary, target);
18669
18696
  const superseded = entriesForPath(directory, pathHash).filter((name) => name !== fileName);
18670
18697
  existingEntries?.set(pathHash, [fileName]);
18671
- await Promise.all(superseded.map((name) => Bun.file(join35(directory, name)).delete().catch(() => {
18698
+ await Promise.all(superseded.map((name) => Bun.file(join36(directory, name)).delete().catch(() => {
18672
18699
  return;
18673
18700
  })));
18674
18701
  } catch {}
@@ -18697,7 +18724,7 @@ var CACHE_DIR_NAME2 = "vue-helpers", CACHE_FORMAT_VERSION2 = 1, HASH_LENGTH = 24
18697
18724
  const key = cacheKey2(sourcePath, sourceCode);
18698
18725
  const directory = cacheDir();
18699
18726
  const fileName = key ? `${key.path}-${key.content}.js` : null;
18700
- const cachedPath = fileName ? join35(directory, fileName) : null;
18727
+ const cachedPath = fileName ? join36(directory, fileName) : null;
18701
18728
  if (cachedPath && existsSync28(cachedPath)) {
18702
18729
  await copyBoth(clientOutputPath, serverOutputPath, cachedPath);
18703
18730
  return;
@@ -18726,7 +18753,7 @@ __export(exports_compileVueSfc, {
18726
18753
  compileVueSfc: () => compileVueSfc
18727
18754
  });
18728
18755
  import { existsSync as existsSync29, readFileSync as readFileSync24, realpathSync as realpathSync2 } from "fs";
18729
- import { dirname as dirname20, relative as relative15, resolve as resolve26 } from "path";
18756
+ import { dirname as dirname20, relative as relative16, resolve as resolve27 } from "path";
18730
18757
  var {Transpiler: Transpiler4 } = globalThis.Bun;
18731
18758
  var transpiler5, inlineCssImports = (cssContent, cssFilePath, visited = new Set) => {
18732
18759
  const resolved = realpathSync2(cssFilePath);
@@ -18735,7 +18762,7 @@ var transpiler5, inlineCssImports = (cssContent, cssFilePath, visited = new Set)
18735
18762
  visited.add(resolved);
18736
18763
  const importRegex = /@import\s+(?:url\(\s*)?(['"])(\.{1,2}\/[^'"]+)\1\s*\)?\s*;?/g;
18737
18764
  return cssContent.replace(importRegex, (match, _quote, relPath) => {
18738
- const importedPath = resolve26(dirname20(cssFilePath), relPath);
18765
+ const importedPath = resolve27(dirname20(cssFilePath), relPath);
18739
18766
  if (!existsSync29(importedPath))
18740
18767
  return match;
18741
18768
  const importedContent = readFileSync24(importedPath, "utf-8");
@@ -18748,15 +18775,15 @@ var transpiler5, inlineCssImports = (cssContent, cssFilePath, visited = new Set)
18748
18775
  return filePath.replace(/\.ts$/, ".js");
18749
18776
  if (isStylePath(filePath)) {
18750
18777
  if (sourceDir && (filePath.startsWith("./") || filePath.startsWith("../"))) {
18751
- return resolve26(sourceDir, filePath);
18778
+ return resolve27(sourceDir, filePath);
18752
18779
  }
18753
18780
  return filePath;
18754
18781
  }
18755
18782
  if (sourceDir && (filePath.startsWith("./") || filePath.startsWith("../"))) {
18756
- const directTs = resolve26(sourceDir, `${filePath}.ts`);
18783
+ const directTs = resolve27(sourceDir, `${filePath}.ts`);
18757
18784
  if (existsSync29(directTs))
18758
18785
  return `${filePath}.js`;
18759
- const indexedTs = resolve26(sourceDir, filePath, "index.ts");
18786
+ const indexedTs = resolve27(sourceDir, filePath, "index.ts");
18760
18787
  if (existsSync29(indexedTs))
18761
18788
  return `${filePath}/index.js`;
18762
18789
  }
@@ -18899,7 +18926,7 @@ if (typeof __VUE_HMR_RUNTIME__ !== 'undefined') {
18899
18926
  let result = code2;
18900
18927
  for (const [bareImport, paths] of packageImportRewrites) {
18901
18928
  const targetPath = mode === "server" ? paths.server : paths.client;
18902
- let rel = relative15(dirname20(outputPath), targetPath).replace(/\\/g, "/");
18929
+ let rel = relative16(dirname20(outputPath), targetPath).replace(/\\/g, "/");
18903
18930
  if (!rel.startsWith("."))
18904
18931
  rel = `./${rel}`;
18905
18932
  result = result.replaceAll(bareImport, rel);
@@ -19005,7 +19032,7 @@ __export(exports_workerPool, {
19005
19032
  });
19006
19033
  import { existsSync as existsSync30, readFileSync as readFileSync25 } from "fs";
19007
19034
  import { availableParallelism, freemem } from "os";
19008
- import { dirname as dirname21, join as join36 } from "path";
19035
+ import { dirname as dirname21, join as join37 } from "path";
19009
19036
  import { pathToFileURL as pathToFileURL2 } from "url";
19010
19037
  var MIN_WORKERS = 2, MAX_DEFAULT_WORKERS = 8, MAX_OVERRIDE_WORKERS = 64, WORKER_MEMORY_BUDGET_BYTES, DEFAULT_IDLE_TIMEOUT_MS = 2000, DEFAULT_MIN_BATCH = 4, PACKAGE_WALK_DEPTH = 6, PERCENT = 100, OWN_PACKAGE_NAME = "@absolutejs/absolute", parseWorkerOverride = (raw) => {
19011
19038
  if (raw === undefined || raw.trim() === "")
@@ -19022,7 +19049,7 @@ var MIN_WORKERS = 2, MAX_DEFAULT_WORKERS = 8, MAX_OVERRIDE_WORKERS = 64, WORKER_
19022
19049
  const byMemory = Math.floor(freemem() / WORKER_MEMORY_BUDGET_BYTES);
19023
19050
  return Math.max(MIN_WORKERS, Math.min(byCpu, byMemory));
19024
19051
  }, isOwnPackageRoot = (dir) => {
19025
- const packageFile = join36(dir, "package.json");
19052
+ const packageFile = join37(dir, "package.json");
19026
19053
  if (!existsSync30(packageFile))
19027
19054
  return false;
19028
19055
  try {
@@ -19046,9 +19073,9 @@ var MIN_WORKERS = 2, MAX_DEFAULT_WORKERS = 8, MAX_OVERRIDE_WORKERS = 64, WORKER_
19046
19073
  const root = findOwnPackageRoot(fromDir);
19047
19074
  if (!root)
19048
19075
  return null;
19049
- const distEntry = join36(root, "dist", "build", "buildWorker.js");
19050
- const sourceEntry = join36(root, "src", "build", "buildWorker.ts");
19051
- const runningFromDist = fromDir.startsWith(join36(root, "dist"));
19076
+ const distEntry = join37(root, "dist", "build", "buildWorker.js");
19077
+ const sourceEntry = join37(root, "src", "build", "buildWorker.ts");
19078
+ const runningFromDist = fromDir.startsWith(join37(root, "dist"));
19052
19079
  const ordered = runningFromDist ? [distEntry, sourceEntry] : [sourceEntry, distEntry];
19053
19080
  return ordered.find((candidate) => existsSync30(candidate)) ?? null;
19054
19081
  }, formatPercent = (ratio) => `${Math.round(ratio * PERCENT)}%`, createBuildWorkerPool = (options = {}) => {
@@ -19243,7 +19270,7 @@ var MIN_WORKERS = 2, MAX_DEFAULT_WORKERS = 8, MAX_OVERRIDE_WORKERS = 64, WORKER_
19243
19270
  };
19244
19271
  const isWarm = () => slots.length > 0;
19245
19272
  const shouldUse = (jobCount) => enabled && !broken && !draining && (isWarm() || jobCount >= minBatch);
19246
- const enqueue = (kind, payload, affinity) => new Promise((resolve27, reject) => {
19273
+ const enqueue = (kind, payload, affinity) => new Promise((resolve28, reject) => {
19247
19274
  onBurstStart();
19248
19275
  inFlight += 1;
19249
19276
  queue.push({
@@ -19252,7 +19279,7 @@ var MIN_WORKERS = 2, MAX_DEFAULT_WORKERS = 8, MAX_OVERRIDE_WORKERS = 64, WORKER_
19252
19279
  payload,
19253
19280
  reject,
19254
19281
  resolve: (result) => {
19255
- resolve27(result);
19282
+ resolve28(result);
19256
19283
  }
19257
19284
  });
19258
19285
  ensureWorkers();
@@ -19295,10 +19322,10 @@ var MIN_WORKERS = 2, MAX_DEFAULT_WORKERS = 8, MAX_OVERRIDE_WORKERS = 64, WORKER_
19295
19322
  const activeJobsSettled = () => {
19296
19323
  if (inFlight === 0)
19297
19324
  return Promise.resolve();
19298
- return new Promise((resolve27) => {
19325
+ return new Promise((resolve28) => {
19299
19326
  const poll = () => {
19300
19327
  if (inFlight === 0) {
19301
- resolve27();
19328
+ resolve28();
19302
19329
  return;
19303
19330
  }
19304
19331
  setTimeout(poll, 10);
@@ -19346,22 +19373,22 @@ import { mkdir as mkdir9 } from "fs/promises";
19346
19373
  import {
19347
19374
  basename as basename14,
19348
19375
  dirname as dirname22,
19349
- isAbsolute as isAbsolute6,
19350
- join as join37,
19351
- relative as relative16,
19352
- resolve as resolve27
19376
+ isAbsolute as isAbsolute7,
19377
+ join as join38,
19378
+ relative as relative17,
19379
+ resolve as resolve28
19353
19380
  } from "path";
19354
19381
  var {file: file3, write: write4 } = globalThis.Bun;
19355
19382
  var resolveDevClientDir3 = () => {
19356
19383
  const projectRoot = process.cwd();
19357
- const fromSource = resolve27(import.meta.dir, "../dev/client");
19384
+ const fromSource = resolve28(import.meta.dir, "../dev/client");
19358
19385
  if (existsSync31(fromSource) && fromSource.startsWith(projectRoot)) {
19359
19386
  return fromSource;
19360
19387
  }
19361
- const fromNodeModules = resolve27(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
19388
+ const fromNodeModules = resolve28(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
19362
19389
  if (existsSync31(fromNodeModules))
19363
19390
  return fromNodeModules;
19364
- return resolve27(import.meta.dir, "./dev/client");
19391
+ return resolve28(import.meta.dir, "./dev/client");
19365
19392
  }, devClientDir3, hmrClientPath4, scriptCache, scriptSetupCache, templateCache, styleCache, persistentBuildCache, vueSourceHashCache, vueHmrMetadata, clearVueHmrCaches = () => {
19366
19393
  scriptCache.clear();
19367
19394
  scriptSetupCache.clear();
@@ -19400,17 +19427,17 @@ var resolveDevClientDir3 = () => {
19400
19427
  return "template-only";
19401
19428
  }
19402
19429
  return "full";
19403
- }, generateVueHmrId = (sourceFilePath, vueRootDir) => relative16(vueRootDir, sourceFilePath).replace(/\\/g, "/").replace(/\.vue$/, ""), extractImports = (sourceCode) => {
19430
+ }, generateVueHmrId = (sourceFilePath, vueRootDir) => relative17(vueRootDir, sourceFilePath).replace(/\\/g, "/").replace(/\.vue$/, ""), extractImports = (sourceCode) => {
19404
19431
  const staticImports = Array.from(sourceCode.matchAll(/import\s+[\s\S]+?['"]([^'"]+)['"]/g));
19405
19432
  const dynamicImports = Array.from(sourceCode.matchAll(/\bimport\s*\(\s*['"]([^'"]+)['"]\s*\)/g));
19406
19433
  return Array.from(new Set([...staticImports, ...dynamicImports].map((match) => match[1]).filter((importPath) => importPath !== undefined)));
19407
19434
  }, resolveHelperTsPath = (sourceDir, helper) => {
19408
19435
  if (helper.endsWith(".ts"))
19409
- return resolve27(sourceDir, helper);
19410
- const direct = resolve27(sourceDir, `${helper}.ts`);
19436
+ return resolve28(sourceDir, helper);
19437
+ const direct = resolve28(sourceDir, `${helper}.ts`);
19411
19438
  if (existsSync31(direct))
19412
19439
  return direct;
19413
- const indexed = resolve27(sourceDir, helper, "index.ts");
19440
+ const indexed = resolve28(sourceDir, helper, "index.ts");
19414
19441
  if (existsSync31(indexed))
19415
19442
  return indexed;
19416
19443
  return direct;
@@ -19478,7 +19505,7 @@ var resolveDevClientDir3 = () => {
19478
19505
  ]);
19479
19506
  }, materialiseVueCompileCacheEntry = async (entry, cacheKey3, isEntryPoint, outputDirs, fileBaseName) => {
19480
19507
  const { result } = entry;
19481
- const cssOutputFile = isEntryPoint && result.cssCodes.length > 0 ? join37(outputDirs.css, `${toKebab(fileBaseName)}-compiled.css`) : null;
19508
+ const cssOutputFile = isEntryPoint && result.cssCodes.length > 0 ? join38(outputDirs.css, `${toKebab(fileBaseName)}-compiled.css`) : null;
19482
19509
  trackWrite(writeVueOutputs({
19483
19510
  clientCode: entry.clientCode,
19484
19511
  clientPath: result.clientPath,
@@ -19533,8 +19560,6 @@ var resolveDevClientDir3 = () => {
19533
19560
  throw error;
19534
19561
  }
19535
19562
  }, compileVueFileUncached = async (sourceFilePath, outputDirs, cacheMap, isEntryPoint, vueRootDir, compiler, runSfc, stylePreprocessors) => {
19536
- const relativeFilePath = relative16(vueRootDir, sourceFilePath).replace(/\\/g, "/");
19537
- const relativeWithoutExtension = relativeFilePath.replace(/\.vue$/, "");
19538
19563
  const fileBaseName = basename14(sourceFilePath, ".vue");
19539
19564
  const componentId = toKebab(fileBaseName);
19540
19565
  vueCompileProfile.files += 1;
@@ -19572,12 +19597,12 @@ var resolveDevClientDir3 = () => {
19572
19597
  const childComponentPaths = importPaths.filter((path) => path.startsWith(".") && path.endsWith(".vue"));
19573
19598
  const packageComponentPaths = Array.from(resolvedPackageVueImports.entries());
19574
19599
  const helperModulePaths = importPaths.filter((path) => path.startsWith(".") && !path.endsWith(".vue") && !isStylePath(path));
19575
- const stylePathsImported = importPaths.filter((path) => (path.startsWith(".") || isAbsolute6(path)) && isStylePath(path)).map((path) => isAbsolute6(path) ? path : resolve27(dirname22(sourceFilePath), path));
19600
+ const stylePathsImported = importPaths.filter((path) => (path.startsWith(".") || isAbsolute7(path)) && isStylePath(path)).map((path) => isAbsolute7(path) ? path : resolve28(dirname22(sourceFilePath), path));
19576
19601
  for (const stylePath of stylePathsImported) {
19577
19602
  addStyleImporter(sourceFilePath, stylePath);
19578
19603
  }
19579
19604
  const childBuildResults = await Promise.all([
19580
- ...childComponentPaths.map((relativeChildPath) => compileVueFile(resolve27(dirname22(sourceFilePath), relativeChildPath), outputDirs, cacheMap, false, vueRootDir, compiler, runSfc, stylePreprocessors)),
19605
+ ...childComponentPaths.map((relativeChildPath) => compileVueFile(resolve28(dirname22(sourceFilePath), relativeChildPath), outputDirs, cacheMap, false, vueRootDir, compiler, runSfc, stylePreprocessors)),
19581
19606
  ...packageComponentPaths.map(([, absolutePath]) => compileVueFile(absolutePath, outputDirs, cacheMap, false, vueRootDir, compiler, runSfc, stylePreprocessors))
19582
19607
  ]);
19583
19608
  const cacheKeyStartedAt = performance.now();
@@ -19587,7 +19612,7 @@ var resolveDevClientDir3 = () => {
19587
19612
  descriptor,
19588
19613
  fingerprint: currentVueCompileFingerprint(compiler, outputDirs, vueRootDir, stylePreprocessors),
19589
19614
  isEntryPoint,
19590
- relativeWithoutExtension
19615
+ relativeWithoutExtension: vueModuleOutputPath("", sourceFilePath).replace(/\.js$/, "")
19591
19616
  });
19592
19617
  const restored = cacheKey3 ? readVueCompileCacheEntry(sourceFilePath, cacheKey3) : undefined;
19593
19618
  vueCompileProfile.keyMs += performance.now() - cacheKeyStartedAt;
@@ -19600,8 +19625,8 @@ var resolveDevClientDir3 = () => {
19600
19625
  return result2;
19601
19626
  }
19602
19627
  }
19603
- const clientOutputPath = join37(outputDirs.client, `${relativeWithoutExtension}.js`);
19604
- const serverOutputPath = join37(outputDirs.server, `${relativeWithoutExtension}.js`);
19628
+ const clientOutputPath = vueModuleOutputPath(outputDirs.client, sourceFilePath);
19629
+ const serverOutputPath = vueModuleOutputPath(outputDirs.server, sourceFilePath);
19605
19630
  const styleSources = await Promise.all(descriptor.styles.map((styleBlock) => styleBlock.lang ? compileStyleSource(sourceFilePath, styleBlock.content, styleBlock.lang, stylePreprocessors) : Promise.resolve(styleBlock.content)));
19606
19631
  const packageImportRewrites = [];
19607
19632
  packageComponentPaths.forEach(([bareImport], index) => {
@@ -19628,7 +19653,7 @@ var resolveDevClientDir3 = () => {
19628
19653
  ...localCss,
19629
19654
  ...childBuildResults.flatMap((result2) => result2.cssCodes)
19630
19655
  ];
19631
- const cssOutputFile = isEntryPoint && allCss.length ? join37(outputDirs.css, `${toKebab(fileBaseName)}-compiled.css`) : null;
19656
+ const cssOutputFile = isEntryPoint && allCss.length ? join38(outputDirs.css, `${toKebab(fileBaseName)}-compiled.css`) : null;
19632
19657
  const cssOutputPaths = cssOutputFile ? [cssOutputFile] : [];
19633
19658
  trackWrite(writeVueOutputs({
19634
19659
  clientCode: clientOutput,
@@ -19672,10 +19697,10 @@ var resolveDevClientDir3 = () => {
19672
19697
  const compilerLoadMs = performance.now() - compilerLoadStartedAt;
19673
19698
  vueCompileProfile.stageCompilerMs = compilerLoadMs;
19674
19699
  const generatedDir = getFrameworkGeneratedDir("vue");
19675
- const clientOutputDir = join37(generatedDir, "client");
19676
- const indexOutputDir = join37(generatedDir, "indexes");
19677
- const serverOutputDir = join37(generatedDir, "server");
19678
- const cssOutputDir = join37(generatedDir, "compiled");
19700
+ const clientOutputDir = join38(generatedDir, "client");
19701
+ const indexOutputDir = join38(generatedDir, "indexes");
19702
+ const serverOutputDir = join38(generatedDir, "server");
19703
+ const cssOutputDir = join38(generatedDir, "compiled");
19679
19704
  await Promise.all([
19680
19705
  mkdir9(clientOutputDir, { recursive: true }),
19681
19706
  mkdir9(indexOutputDir, { recursive: true }),
@@ -19685,7 +19710,7 @@ var resolveDevClientDir3 = () => {
19685
19710
  const buildCache = new Map;
19686
19711
  const allTsHelperPaths = new Set;
19687
19712
  const expandSpaRouteChildren = async (entries) => {
19688
- const expanded = new Set(entries.map((entry) => resolve27(entry)));
19713
+ const expanded = new Set(entries.map((entry) => resolve28(entry)));
19689
19714
  const queue = [...expanded];
19690
19715
  while (queue.length > 0) {
19691
19716
  const entryPath = queue.pop();
@@ -19702,7 +19727,7 @@ var resolveDevClientDir3 = () => {
19702
19727
  });
19703
19728
  const routes = parseVueSpaRoutes(descriptor.script?.content ?? "");
19704
19729
  for (const { importPath } of routes) {
19705
- const childPath = resolve27(dirname22(entryPath), importPath);
19730
+ const childPath = resolve28(dirname22(entryPath), importPath);
19706
19731
  if (expanded.has(childPath) || !existsSync31(childPath)) {
19707
19732
  continue;
19708
19733
  }
@@ -19717,7 +19742,7 @@ var resolveDevClientDir3 = () => {
19717
19742
  vueCompileProfile.stageExpandMs = performance.now() - stageStartedAt;
19718
19743
  stageStartedAt = performance.now();
19719
19744
  const compiledPages = await Promise.all(expandedEntryPoints.map(async (entryPath) => {
19720
- const resolvedEntryPath = resolve27(entryPath);
19745
+ const resolvedEntryPath = resolve28(entryPath);
19721
19746
  const result = await compileVueFile(resolvedEntryPath, {
19722
19747
  client: clientOutputDir,
19723
19748
  css: cssOutputDir,
@@ -19735,8 +19760,8 @@ var resolveDevClientDir3 = () => {
19735
19760
  };
19736
19761
  }
19737
19762
  const entryBaseName = basename14(entryPath, ".vue");
19738
- const indexOutputFile = join37(indexOutputDir, `${entryBaseName}.js`);
19739
- const clientOutputFile = join37(clientOutputDir, relative16(vueRootDir, entryPath).replace(/\\/g, "/").replace(/\.vue$/, ".js"));
19763
+ const indexOutputFile = join38(indexOutputDir, `${entryBaseName}.js`);
19764
+ const clientOutputFile = result.clientPath;
19740
19765
  await mkdir9(dirname22(indexOutputFile), { recursive: true });
19741
19766
  const vueHmrImports = isDev2 ? [
19742
19767
  `window.__HMR_FRAMEWORK__ = "vue";`,
@@ -19744,7 +19769,7 @@ var resolveDevClientDir3 = () => {
19744
19769
  ] : [];
19745
19770
  await write4(indexOutputFile, [
19746
19771
  ...vueHmrImports,
19747
- `import Comp, * as PageModule from "${relative16(dirname22(indexOutputFile), clientOutputFile).replace(/\\/g, "/")}";`,
19772
+ `import Comp, * as PageModule from "${relative17(dirname22(indexOutputFile), clientOutputFile).replace(/\\/g, "/")}";`,
19748
19773
  'import { createSSRApp, createApp } from "vue";',
19749
19774
  'import { prepareBrowserTranslationHydration } from "@absolutejs/absolute/vue";',
19750
19775
  "",
@@ -19930,14 +19955,11 @@ var resolveDevClientDir3 = () => {
19930
19955
  vueCompileProfile.stageHelperScanMs = performance.now() - stageStartedAt;
19931
19956
  vueCompileProfile.helpers = allTsHelperPaths.size;
19932
19957
  stageStartedAt = performance.now();
19933
- const helperFiles = Array.from(allTsHelperPaths).map((tsPath) => {
19934
- const relativeJsPath = relative16(vueRootDir, tsPath).replace(/\.ts$/, ".js");
19935
- return {
19936
- clientOutputPath: join37(clientOutputDir, relativeJsPath),
19937
- serverOutputPath: join37(serverOutputDir, relativeJsPath),
19938
- sourcePath: tsPath
19939
- };
19940
- });
19958
+ const helperFiles = Array.from(allTsHelperPaths).map((tsPath) => ({
19959
+ clientOutputPath: vueModuleOutputPath(clientOutputDir, tsPath),
19960
+ serverOutputPath: vueModuleOutputPath(serverOutputDir, tsPath),
19961
+ sourcePath: tsPath
19962
+ }));
19941
19963
  await runHelperEmit(helperFiles);
19942
19964
  vueCompileProfile.stageHelperEmitMs = performance.now() - stageStartedAt;
19943
19965
  stageStartedAt = performance.now();
@@ -19964,6 +19986,7 @@ var resolveDevClientDir3 = () => {
19964
19986
  };
19965
19987
  };
19966
19988
  var init_compileVue = __esm(() => {
19989
+ init_vueModuleOutputPath();
19967
19990
  init_constants();
19968
19991
  init_generatedDir();
19969
19992
  init_resolvePackageImport();
@@ -19974,7 +19997,7 @@ var init_compileVue = __esm(() => {
19974
19997
  init_stylePreprocessor();
19975
19998
  init_vueCompileCache();
19976
19999
  devClientDir3 = resolveDevClientDir3();
19977
- hmrClientPath4 = join37(devClientDir3, "hmrClient.ts").replace(/\\/g, "/");
20000
+ hmrClientPath4 = join38(devClientDir3, "hmrClient.ts").replace(/\\/g, "/");
19978
20001
  scriptCache = new Map;
19979
20002
  scriptSetupCache = new Map;
19980
20003
  templateCache = new Map;
@@ -20479,7 +20502,7 @@ __export(exports_compileAngular, {
20479
20502
  invalidateAngularJitCache: () => invalidateAngularJitCache
20480
20503
  });
20481
20504
  import { existsSync as existsSync32, readFileSync as readFileSync26, promises as fs5 } from "fs";
20482
- import { join as join38, basename as basename15, sep as sep3, dirname as dirname23, resolve as resolve28, relative as relative17 } from "path";
20505
+ import { join as join39, basename as basename15, sep as sep4, dirname as dirname23, resolve as resolve29, relative as relative18 } from "path";
20483
20506
  var {Glob: Glob6 } = globalThis.Bun;
20484
20507
  import ts18 from "typescript";
20485
20508
  var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) => {
@@ -20495,10 +20518,10 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20495
20518
  return tracePhase ? tracePhase(`compile/angular/${name}`, fn2, metadata) : await fn2();
20496
20519
  }, readTsconfigPathAliases = () => {
20497
20520
  try {
20498
- const configPath2 = resolve28(process.cwd(), "tsconfig.json");
20521
+ const configPath2 = resolve29(process.cwd(), "tsconfig.json");
20499
20522
  const config = ts18.readConfigFile(configPath2, ts18.sys.readFile).config;
20500
20523
  const compilerOptions = config?.compilerOptions ?? {};
20501
- const baseUrl = resolve28(process.cwd(), compilerOptions.baseUrl ?? ".");
20524
+ const baseUrl = resolve29(process.cwd(), compilerOptions.baseUrl ?? ".");
20502
20525
  const aliases = Object.entries(compilerOptions.paths ?? {}).map(([pattern, replacements]) => ({ pattern, replacements }));
20503
20526
  return { aliases, baseUrl };
20504
20527
  } catch {
@@ -20518,7 +20541,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20518
20541
  const wildcardValue = exactMatch ? "" : specifier.slice(prefix.length, specifier.length - suffix.length);
20519
20542
  for (const replacement of alias.replacements) {
20520
20543
  const candidate = replacement.replace("*", wildcardValue);
20521
- const resolved = resolveSourceFile(resolve28(baseUrl, candidate));
20544
+ const resolved = resolveSourceFile(resolve29(baseUrl, candidate));
20522
20545
  if (resolved)
20523
20546
  return resolved;
20524
20547
  }
@@ -20530,20 +20553,20 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20530
20553
  `${candidate}.tsx`,
20531
20554
  `${candidate}.js`,
20532
20555
  `${candidate}.jsx`,
20533
- join38(candidate, "index.ts"),
20534
- join38(candidate, "index.tsx"),
20535
- join38(candidate, "index.js"),
20536
- join38(candidate, "index.jsx")
20556
+ join39(candidate, "index.ts"),
20557
+ join39(candidate, "index.tsx"),
20558
+ join39(candidate, "index.js"),
20559
+ join39(candidate, "index.jsx")
20537
20560
  ];
20538
20561
  return candidates.find((file4) => existsSync32(file4));
20539
20562
  }, createLegacyAngularAnimationUsageResolver = (rootDir) => {
20540
- const baseDir = resolve28(rootDir);
20563
+ const baseDir = resolve29(rootDir);
20541
20564
  const tsconfigAliases = readTsconfigPathAliases();
20542
20565
  const transpiler6 = new Bun.Transpiler({ loader: "tsx" });
20543
20566
  const scanCache = new Map;
20544
20567
  const resolveLocalImport = (specifier, fromDir) => {
20545
20568
  if (specifier.startsWith(".") || specifier.startsWith("/")) {
20546
- return resolveSourceFile(resolve28(fromDir, specifier));
20569
+ return resolveSourceFile(resolve29(fromDir, specifier));
20547
20570
  }
20548
20571
  const aliased = matchTsconfigAlias(specifier, tsconfigAliases.aliases, tsconfigAliases.baseUrl, resolveSourceFile);
20549
20572
  if (aliased)
@@ -20552,7 +20575,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20552
20575
  const resolved = Bun.resolveSync(specifier, fromDir);
20553
20576
  if (resolved.includes("/node_modules/"))
20554
20577
  return;
20555
- const absolute = resolve28(resolved);
20578
+ const absolute = resolve29(resolved);
20556
20579
  if (!absolute.startsWith(baseDir))
20557
20580
  return;
20558
20581
  return resolveSourceFile(absolute);
@@ -20568,7 +20591,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20568
20591
  usesLegacyAnimations: false
20569
20592
  });
20570
20593
  }
20571
- const resolved = resolve28(actualPath);
20594
+ const resolved = resolve29(actualPath);
20572
20595
  const cached = scanCache.get(resolved);
20573
20596
  if (cached)
20574
20597
  return cached;
@@ -20597,7 +20620,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20597
20620
  const actualPath = resolveSourceFile(filePath);
20598
20621
  if (!actualPath)
20599
20622
  return false;
20600
- const resolved = resolve28(actualPath);
20623
+ const resolved = resolve29(actualPath);
20601
20624
  if (visited.has(resolved))
20602
20625
  return false;
20603
20626
  visited.add(resolved);
@@ -20615,14 +20638,14 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20615
20638
  return (entryPath) => visit(entryPath);
20616
20639
  }, resolveDevClientDir4 = () => {
20617
20640
  const projectRoot = process.cwd();
20618
- const fromSource = resolve28(import.meta.dir, "../dev/client");
20641
+ const fromSource = resolve29(import.meta.dir, "../dev/client");
20619
20642
  if (existsSync32(fromSource) && fromSource.startsWith(projectRoot)) {
20620
20643
  return fromSource;
20621
20644
  }
20622
- const fromNodeModules = resolve28(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
20645
+ const fromNodeModules = resolve29(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
20623
20646
  if (existsSync32(fromNodeModules))
20624
20647
  return fromNodeModules;
20625
- return resolve28(import.meta.dir, "./dev/client");
20648
+ return resolve29(import.meta.dir, "./dev/client");
20626
20649
  }, devClientDir4, hmrClientPath5, formatDiagnosticMessage = (diagnostic) => {
20627
20650
  try {
20628
20651
  return ts18.flattenDiagnosticMessageText(diagnostic.messageText, `
@@ -20665,11 +20688,11 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20665
20688
  if (hasJsLikeExtension(path))
20666
20689
  return `${path}${query}`;
20667
20690
  const importerDir = dirname23(importerOutputPath);
20668
- const fileCandidate = resolve28(importerDir, `${path}.js`);
20691
+ const fileCandidate = resolve29(importerDir, `${path}.js`);
20669
20692
  if (outputFiles?.has(fileCandidate) || existsSync32(fileCandidate)) {
20670
20693
  return `${path}.js${query}`;
20671
20694
  }
20672
- const indexCandidate = resolve28(importerDir, path, "index.js");
20695
+ const indexCandidate = resolve29(importerDir, path, "index.js");
20673
20696
  if (outputFiles?.has(indexCandidate) || existsSync32(indexCandidate)) {
20674
20697
  return `${path}/index.js${query}`;
20675
20698
  }
@@ -20697,18 +20720,18 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20697
20720
  }, resolveLocalTsImport = (fromFile, specifier) => {
20698
20721
  if (!isRelativeModuleSpecifier(specifier))
20699
20722
  return null;
20700
- const basePath = resolve28(dirname23(fromFile), specifier);
20723
+ const basePath = resolve29(dirname23(fromFile), specifier);
20701
20724
  const candidates = /\.[cm]?[tj]sx?$/.test(basePath) ? [basePath] : [
20702
20725
  `${basePath}.ts`,
20703
20726
  `${basePath}.tsx`,
20704
20727
  `${basePath}.mts`,
20705
20728
  `${basePath}.cts`,
20706
- join38(basePath, "index.ts"),
20707
- join38(basePath, "index.tsx"),
20708
- join38(basePath, "index.mts"),
20709
- join38(basePath, "index.cts")
20729
+ join39(basePath, "index.ts"),
20730
+ join39(basePath, "index.tsx"),
20731
+ join39(basePath, "index.mts"),
20732
+ join39(basePath, "index.cts")
20710
20733
  ];
20711
- return candidates.map((candidate) => resolve28(candidate)).find((candidate) => existsSync32(candidate) && !candidate.endsWith(".d.ts")) ?? null;
20734
+ return candidates.map((candidate) => resolve29(candidate)).find((candidate) => existsSync32(candidate) && !candidate.endsWith(".d.ts")) ?? null;
20712
20735
  }, readFileForAotTransform = async (fileName, readFile6) => {
20713
20736
  const hostSource = readFile6?.(fileName);
20714
20737
  if (typeof hostSource === "string")
@@ -20732,18 +20755,18 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20732
20755
  const paths = [];
20733
20756
  const templateUrlMatch = findUncommentedMatch(source, /templateUrl\s*:\s*['"]([^'"]+)['"]/);
20734
20757
  if (templateUrlMatch?.[1])
20735
- paths.push(join38(fileDir, templateUrlMatch[1]));
20758
+ paths.push(join39(fileDir, templateUrlMatch[1]));
20736
20759
  const styleUrlMatch = findUncommentedMatch(source, /styleUrl\s*:\s*['"]([^'"]+)['"]/);
20737
20760
  if (styleUrlMatch?.[1])
20738
- paths.push(join38(fileDir, styleUrlMatch[1]));
20761
+ paths.push(join39(fileDir, styleUrlMatch[1]));
20739
20762
  const styleUrlsMatch = findUncommentedMatch(source, /styleUrls\s*:\s*\[([^\]]+)\]/);
20740
20763
  const urlMatches = styleUrlsMatch?.[1]?.match(/['"]([^'"]+)['"]/g);
20741
20764
  if (urlMatches) {
20742
20765
  for (const urlMatch of urlMatches) {
20743
- paths.push(join38(fileDir, urlMatch.replace(/['"]/g, "")));
20766
+ paths.push(join39(fileDir, urlMatch.replace(/['"]/g, "")));
20744
20767
  }
20745
20768
  }
20746
- return paths.map((path) => resolve28(path));
20769
+ return paths.map((path) => resolve29(path));
20747
20770
  }, readResourceCacheFile = async (cachePath) => {
20748
20771
  try {
20749
20772
  const entry = JSON.parse(await fs5.readFile(cachePath, "utf-8"));
@@ -20774,7 +20797,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20774
20797
  safeStableStringify(stylePreprocessors ?? null)
20775
20798
  ].join("\x00");
20776
20799
  const cacheKey3 = Bun.hash(cacheInput).toString(BASE_36_RADIX);
20777
- return join38(process.cwd(), ".absolutejs", "cache", "angular-resources", `${cacheKey3}.json`);
20800
+ return join39(process.cwd(), ".absolutejs", "cache", "angular-resources", `${cacheKey3}.json`);
20778
20801
  }, precomputeAotResourceTransforms = async (inputPaths, readFile6, stylePreprocessors) => {
20779
20802
  const transformedSources = new Map;
20780
20803
  const visited = new Set;
@@ -20785,7 +20808,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20785
20808
  transformedFiles: 0
20786
20809
  };
20787
20810
  const transformFile = async (filePath) => {
20788
- const resolvedPath = resolve28(filePath);
20811
+ const resolvedPath = resolve29(filePath);
20789
20812
  if (visited.has(resolvedPath))
20790
20813
  return;
20791
20814
  visited.add(resolvedPath);
@@ -20820,7 +20843,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20820
20843
  return { stats, transformedSources };
20821
20844
  }, compileAngularFiles = async (inputPaths, outDir, stylePreprocessors) => {
20822
20845
  const islandMetadataByOutputPath = await traceAngularPhase("aot/island-metadata", () => new Map(inputPaths.map((inputPath) => {
20823
- const outputPath = resolve28(join38(outDir, relative17(process.cwd(), resolve28(inputPath)).replace(/\.[cm]?[tj]sx?$/, ".js")));
20846
+ const outputPath = resolve29(join39(outDir, relative18(process.cwd(), resolve29(inputPath)).replace(/\.[cm]?[tj]sx?$/, ".js")));
20824
20847
  return [
20825
20848
  outputPath,
20826
20849
  buildIslandMetadataExports(readFileSync26(inputPath, "utf-8"))
@@ -20831,7 +20854,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20831
20854
  const tsLibDir = await traceAngularPhase("aot/resolve-typescript-lib", () => {
20832
20855
  const tsPath = __require.resolve("typescript");
20833
20856
  const tsRootDir = dirname23(tsPath);
20834
- return tsRootDir.endsWith("lib") ? tsRootDir : resolve28(tsRootDir, "lib");
20857
+ return tsRootDir.endsWith("lib") ? tsRootDir : resolve29(tsRootDir, "lib");
20835
20858
  });
20836
20859
  const config = await traceAngularPhase("aot/read-configuration", () => readConfiguration("./tsconfig.json"));
20837
20860
  const options = {
@@ -20867,13 +20890,13 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20867
20890
  const originalGetSourceFile = host2.getSourceFile;
20868
20891
  host2.getSourceFile = (fileName, languageVersion, onError) => {
20869
20892
  if (fileName.startsWith("lib.") && fileName.endsWith(".d.ts") && tsLibDir) {
20870
- const resolvedPath = join38(tsLibDir, fileName);
20893
+ const resolvedPath = join39(tsLibDir, fileName);
20871
20894
  return originalGetSourceFile?.call(host2, resolvedPath, languageVersion, onError);
20872
20895
  }
20873
20896
  return originalGetSourceFile?.call(host2, fileName, languageVersion, onError);
20874
20897
  };
20875
20898
  const emitted = {};
20876
- const resolvedOutDir = resolve28(outDir);
20899
+ const resolvedOutDir = resolve29(outDir);
20877
20900
  host2.writeFile = (fileName, text2) => {
20878
20901
  const relativePath = resolveRelativePath(fileName, resolvedOutDir, outDir);
20879
20902
  emitted[relativePath] = text2;
@@ -20895,12 +20918,12 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20895
20918
  if (!fileName.endsWith(".ts") || fileName.endsWith(".d.ts")) {
20896
20919
  return source;
20897
20920
  }
20898
- const resolvedPath = resolve28(fileName);
20921
+ const resolvedPath = resolve29(fileName);
20899
20922
  return transformedSources.get(resolvedPath) ?? source;
20900
20923
  };
20901
20924
  const originalGetSourceFileForCompile = host2.getSourceFile;
20902
20925
  host2.getSourceFile = (fileName, languageVersion, onError) => {
20903
- const source = transformedSources.get(resolve28(fileName));
20926
+ const source = transformedSources.get(resolve29(fileName));
20904
20927
  if (source) {
20905
20928
  return ts18.createSourceFile(fileName, source, languageVersion, true);
20906
20929
  }
@@ -20922,9 +20945,9 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20922
20945
  const entries = await traceAngularPhase("aot/postprocess-emitted-js", () => {
20923
20946
  const rawEntries = Object.entries(emitted).filter(([fileName]) => fileName.endsWith(".js")).map(([fileName, content]) => ({
20924
20947
  content,
20925
- target: join38(outDir, fileName)
20948
+ target: join39(outDir, fileName)
20926
20949
  }));
20927
- const outputFiles = new Set(rawEntries.map(({ target }) => resolve28(target)));
20950
+ const outputFiles = new Set(rawEntries.map(({ target }) => resolve29(target)));
20928
20951
  return rawEntries.map(({ content, target }) => {
20929
20952
  let processedContent = content.replace(/from\s+(['"])(\.\.?\/[^'"]+)(\1)/g, (match, quote, path) => {
20930
20953
  const rewritten = rewriteRelativeJsSpecifier(target, path, outputFiles);
@@ -20939,7 +20962,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20939
20962
  return cleaned ? `import { ${cleaned}, InternalInjectFlags } from '@angular/core'` : `import { InternalInjectFlags } from '@angular/core'`;
20940
20963
  });
20941
20964
  processedContent = processedContent.replace(/\b(?<!Internal)InjectFlags\b/g, "InternalInjectFlags");
20942
- processedContent += islandMetadataByOutputPath.get(resolve28(target)) ?? "";
20965
+ processedContent += islandMetadataByOutputPath.get(resolve29(target)) ?? "";
20943
20966
  return { content: processedContent, target };
20944
20967
  });
20945
20968
  });
@@ -20949,7 +20972,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20949
20972
  })), { outputs: entries.length });
20950
20973
  return await traceAngularPhase("aot/collect-output-paths", () => entries.map(({ target }) => target), { outputs: entries.length });
20951
20974
  }, compileAngularFile = async (inputPath, outDir, stylePreprocessors) => compileAngularFiles([inputPath], outDir, stylePreprocessors), jitContentCache, invalidateAngularJitCache = (filePath) => {
20952
- jitContentCache.delete(resolve28(filePath));
20975
+ jitContentCache.delete(resolve29(filePath));
20953
20976
  }, wrapperOutputCache, escapeTemplateContent = (content) => content.replace(/\\/g, "\\\\").replace(/`/g, "\\`").replace(/\$\{/g, "\\${"), findUncommentedMatch = (source, pattern) => {
20954
20977
  const re2 = new RegExp(pattern.source, pattern.flags.includes("g") ? pattern.flags : pattern.flags + "g");
20955
20978
  let match;
@@ -20962,7 +20985,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
20962
20985
  }
20963
20986
  return null;
20964
20987
  }, resolveAngularDeferImportSpecifier = () => {
20965
- const sourceEntry = resolve28(import.meta.dir, "../angular/components/index.ts");
20988
+ const sourceEntry = resolve29(import.meta.dir, "../angular/components/index.ts");
20966
20989
  if (existsSync32(sourceEntry)) {
20967
20990
  return sourceEntry.replace(/\\/g, "/");
20968
20991
  }
@@ -21099,7 +21122,7 @@ ${fields}
21099
21122
  }, inlineTemplateAndLowerDefer = async (source, fileDir) => {
21100
21123
  const templateUrlMatch = findUncommentedMatch(source, /templateUrl\s*:\s*['"]([^'"]+)['"]/);
21101
21124
  if (templateUrlMatch?.[1]) {
21102
- const templatePath = join38(fileDir, templateUrlMatch[1]);
21125
+ const templatePath = join39(fileDir, templateUrlMatch[1]);
21103
21126
  if (!existsSync32(templatePath)) {
21104
21127
  throw new Error(`Unable to inline Angular templateUrl "${templateUrlMatch[1]}": file not found at ${templatePath}`);
21105
21128
  }
@@ -21130,7 +21153,7 @@ ${fields}
21130
21153
  }, inlineTemplateAndLowerDeferSync = (source, fileDir) => {
21131
21154
  const templateUrlMatch = findUncommentedMatch(source, /templateUrl\s*:\s*['"]([^'"]+)['"]/);
21132
21155
  if (templateUrlMatch?.[1]) {
21133
- const templatePath = join38(fileDir, templateUrlMatch[1]);
21156
+ const templatePath = join39(fileDir, templateUrlMatch[1]);
21134
21157
  if (!existsSync32(templatePath)) {
21135
21158
  throw new Error(`Unable to inline Angular templateUrl "${templateUrlMatch[1]}": file not found at ${templatePath}`);
21136
21159
  }
@@ -21167,7 +21190,7 @@ ${fields}
21167
21190
  return source;
21168
21191
  const stylePromises = urlMatches.map((urlMatch) => {
21169
21192
  const styleUrl = urlMatch.replace(/['"]/g, "");
21170
- return readAndEscapeFile(join38(fileDir, styleUrl), stylePreprocessors);
21193
+ return readAndEscapeFile(join39(fileDir, styleUrl), stylePreprocessors);
21171
21194
  });
21172
21195
  const results = await Promise.all(stylePromises);
21173
21196
  const inlinedStyles = results.filter(Boolean).map((escaped) => `\`${escaped}\``);
@@ -21178,7 +21201,7 @@ ${fields}
21178
21201
  const styleUrlMatch = findUncommentedMatch(source, /styleUrl\s*:\s*['"]([^'"]+)['"]/);
21179
21202
  if (!styleUrlMatch?.[1])
21180
21203
  return source;
21181
- const escaped = await readAndEscapeFile(join38(fileDir, styleUrlMatch[1]), stylePreprocessors);
21204
+ const escaped = await readAndEscapeFile(join39(fileDir, styleUrlMatch[1]), stylePreprocessors);
21182
21205
  if (!escaped)
21183
21206
  return source;
21184
21207
  return source.slice(0, styleUrlMatch.index) + `styles: [\`${escaped}\`]` + source.slice(styleUrlMatch.index + styleUrlMatch[0].length);
@@ -21252,10 +21275,10 @@ ${fields}
21252
21275
  return "";
21253
21276
  }
21254
21277
  }, compileAngularFileJIT = async (inputPath, outDir, rootDir, stylePreprocessors, cacheBuster) => {
21255
- const entryPath = resolve28(inputPath);
21278
+ const entryPath = resolve29(inputPath);
21256
21279
  const allOutputs = [];
21257
21280
  const visited = new Set;
21258
- const baseDir = resolve28(rootDir ?? process.cwd());
21281
+ const baseDir = resolve29(rootDir ?? process.cwd());
21259
21282
  let usesLegacyAnimations = false;
21260
21283
  const angularTranspiler = new Bun.Transpiler({
21261
21284
  loader: "ts",
@@ -21274,16 +21297,16 @@ ${fields}
21274
21297
  `${candidate}.js`,
21275
21298
  `${candidate}.jsx`,
21276
21299
  `${candidate}.json`,
21277
- join38(candidate, "index.ts"),
21278
- join38(candidate, "index.tsx"),
21279
- join38(candidate, "index.js"),
21280
- join38(candidate, "index.jsx")
21300
+ join39(candidate, "index.ts"),
21301
+ join39(candidate, "index.tsx"),
21302
+ join39(candidate, "index.js"),
21303
+ join39(candidate, "index.jsx")
21281
21304
  ];
21282
21305
  return candidates.find((file4) => existsSync32(file4));
21283
21306
  };
21284
21307
  const resolveLocalImport = (specifier, fromDir) => {
21285
21308
  if (specifier.startsWith(".") || specifier.startsWith("/")) {
21286
- return resolveSourceFile2(resolve28(fromDir, specifier));
21309
+ return resolveSourceFile2(resolve29(fromDir, specifier));
21287
21310
  }
21288
21311
  const aliased = matchTsconfigAlias(specifier, tsconfigAliases.aliases, tsconfigAliases.baseUrl, resolveSourceFile2);
21289
21312
  if (aliased)
@@ -21292,7 +21315,7 @@ ${fields}
21292
21315
  const resolved = Bun.resolveSync(specifier, fromDir);
21293
21316
  if (resolved.includes("/node_modules/"))
21294
21317
  return;
21295
- const absolute = resolve28(resolved);
21318
+ const absolute = resolve29(resolved);
21296
21319
  if (!absolute.startsWith(baseDir))
21297
21320
  return;
21298
21321
  return resolveSourceFile2(absolute);
@@ -21303,11 +21326,11 @@ ${fields}
21303
21326
  const toOutputPath = (sourcePath) => {
21304
21327
  const inputDir = dirname23(sourcePath);
21305
21328
  const fileBase = basename15(sourcePath).replace(/\.[cm]?[tj]sx?$/, ".js");
21306
- if (inputDir === outDir || inputDir.startsWith(`${outDir}${sep3}`)) {
21307
- return join38(inputDir, fileBase);
21329
+ if (inputDir === outDir || inputDir.startsWith(`${outDir}${sep4}`)) {
21330
+ return join39(inputDir, fileBase);
21308
21331
  }
21309
21332
  const relativeDir = inputDir.startsWith(baseDir) ? inputDir.substring(baseDir.length + 1) : inputDir;
21310
- return join38(outDir, relativeDir, fileBase);
21333
+ return join39(outDir, relativeDir, fileBase);
21311
21334
  };
21312
21335
  const withCacheBuster = (specifier) => {
21313
21336
  if (!cacheBuster)
@@ -21344,21 +21367,21 @@ ${fields}
21344
21367
  return `${prefix}${dots}`;
21345
21368
  return `${prefix}../${dots}`;
21346
21369
  });
21347
- if (resolve28(actualPath) === entryPath) {
21370
+ if (resolve29(actualPath) === entryPath) {
21348
21371
  processedContent += buildIslandMetadataExports(sourceCode);
21349
21372
  }
21350
21373
  return processedContent;
21351
21374
  };
21352
21375
  const transpileFile = async (filePath) => {
21353
- const resolved = resolve28(filePath);
21376
+ const resolved = resolve29(filePath);
21354
21377
  if (visited.has(resolved))
21355
21378
  return;
21356
21379
  visited.add(resolved);
21357
21380
  if (resolved.endsWith(".json") && existsSync32(resolved)) {
21358
21381
  const inputDir2 = dirname23(resolved);
21359
21382
  const relativeDir2 = inputDir2.startsWith(baseDir) ? inputDir2.substring(baseDir.length + 1) : inputDir2;
21360
- const targetDir2 = join38(outDir, relativeDir2);
21361
- const targetPath2 = join38(targetDir2, basename15(resolved));
21383
+ const targetDir2 = join39(outDir, relativeDir2);
21384
+ const targetPath2 = join39(targetDir2, basename15(resolved));
21362
21385
  await fs5.mkdir(targetDir2, { recursive: true });
21363
21386
  await fs5.copyFile(resolved, targetPath2);
21364
21387
  allOutputs.push(targetPath2);
@@ -21376,7 +21399,7 @@ ${fields}
21376
21399
  const fileBase = basename15(actualPath).replace(/\.[cm]?[tj]sx?$/, ".js");
21377
21400
  const targetPath = toOutputPath(actualPath);
21378
21401
  const targetDir = dirname23(targetPath);
21379
- const relativeDir = relative17(outDir, targetDir).replace(/\\/g, "/");
21402
+ const relativeDir = relative18(outDir, targetDir).replace(/\\/g, "/");
21380
21403
  const localImports = [];
21381
21404
  const importRewrites = new Map;
21382
21405
  const fromRegex = /(?:from|import)\s+['"]([^'".][^'"]*|\.\.?\/[^'"]+)['"]/g;
@@ -21397,12 +21420,12 @@ ${fields}
21397
21420
  const resolved2 = resolveLocalImport(specifier, inputDir);
21398
21421
  if (!resolved2)
21399
21422
  return null;
21400
- const relativeImport = relative17(targetDir, toOutputPath(resolved2)).replace(/\\/g, "/").replace(/\.js$/, "");
21423
+ const relativeImport = relative18(targetDir, toOutputPath(resolved2)).replace(/\\/g, "/").replace(/\.js$/, "");
21401
21424
  const relativeRewrite = relativeImport.startsWith(".") ? relativeImport : `./${relativeImport}`;
21402
21425
  importRewrites.set(specifier, relativeRewrite);
21403
21426
  return resolved2;
21404
21427
  }).filter((path) => Boolean(path));
21405
- const isEntry = resolve28(actualPath) === resolve28(entryPath);
21428
+ const isEntry = resolve29(actualPath) === resolve29(entryPath);
21406
21429
  const contentHash = Bun.hash(sourceCode).toString(BASE_36_RADIX);
21407
21430
  const cacheKey3 = actualPath;
21408
21431
  const shouldWriteFile = cacheBuster && isEntry ? true : jitContentCache.get(cacheKey3) !== contentHash || !existsSync32(targetPath);
@@ -21437,13 +21460,13 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
21437
21460
  return { clientPaths: [...emptyPaths], serverPaths: [...emptyPaths] };
21438
21461
  }
21439
21462
  const compiledRoot = compiledParent;
21440
- const indexesDir = join38(compiledParent, "indexes");
21463
+ const indexesDir = join39(compiledParent, "indexes");
21441
21464
  await traceAngularPhase("setup/create-indexes-dir", () => fs5.mkdir(indexesDir, { recursive: true }));
21442
- const aotOutputs = hmr ? [] : await traceAngularPhase("aot/compile-files", () => compileAngularFiles(entryPoints.map((entry) => resolve28(entry)), compiledRoot, stylePreprocessors), { entries: entryPoints.length });
21465
+ const aotOutputs = hmr ? [] : await traceAngularPhase("aot/compile-files", () => compileAngularFiles(entryPoints.map((entry) => resolve29(entry)), compiledRoot, stylePreprocessors), { entries: entryPoints.length });
21443
21466
  if (!hmr) {
21444
21467
  await traceAngularPhase("aot/copy-json-resources", async () => {
21445
21468
  const cwd = process.cwd();
21446
- const angularSrcDir = resolve28(outRoot);
21469
+ const angularSrcDir = resolve29(outRoot);
21447
21470
  if (!existsSync32(angularSrcDir))
21448
21471
  return;
21449
21472
  const jsonGlob = new Glob6("**/*.json");
@@ -21451,9 +21474,9 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
21451
21474
  absolute: false,
21452
21475
  cwd: angularSrcDir
21453
21476
  })) {
21454
- const sourcePath = join38(angularSrcDir, rel);
21455
- const cwdRel = relative17(cwd, sourcePath);
21456
- const targetPath = join38(compiledRoot, cwdRel);
21477
+ const sourcePath = join39(angularSrcDir, rel);
21478
+ const cwdRel = relative18(cwd, sourcePath);
21479
+ const targetPath = join39(compiledRoot, cwdRel);
21457
21480
  await fs5.mkdir(dirname23(targetPath), { recursive: true });
21458
21481
  await fs5.copyFile(sourcePath, targetPath);
21459
21482
  }
@@ -21461,8 +21484,8 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
21461
21484
  }
21462
21485
  const usesLegacyAngularAnimations = await traceAngularPhase("setup/legacy-animation-resolver", () => createLegacyAngularAnimationUsageResolver(outRoot));
21463
21486
  const compileTasks = entryPoints.map(async (entry) => {
21464
- const resolvedEntry = resolve28(entry);
21465
- const relativeEntry = relative17(outRoot, resolvedEntry).replace(/\.[tj]s$/, ".js");
21487
+ const resolvedEntry = resolve29(entry);
21488
+ const relativeEntry = relative18(outRoot, resolvedEntry).replace(/\.[tj]s$/, ".js");
21466
21489
  const compileEntry = () => compileAngularFileJIT(resolvedEntry, compiledRoot, outRoot, stylePreprocessors);
21467
21490
  let outputs = hmr ? await traceAngularPhase("jit/compile-entry", compileEntry, {
21468
21491
  entry: resolvedEntry
@@ -21470,21 +21493,21 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
21470
21493
  const fileBase = basename15(resolvedEntry).replace(/\.[tj]s$/, "");
21471
21494
  const jsName = `${fileBase}.js`;
21472
21495
  const compiledFallbackPaths = [
21473
- join38(compiledRoot, relativeEntry),
21474
- join38(compiledRoot, "pages", jsName),
21475
- join38(compiledRoot, jsName)
21476
- ].map((file4) => resolve28(file4));
21496
+ join39(compiledRoot, relativeEntry),
21497
+ join39(compiledRoot, "pages", jsName),
21498
+ join39(compiledRoot, jsName)
21499
+ ].map((file4) => resolve29(file4));
21477
21500
  const resolveRawServerFile = (candidatePaths) => {
21478
21501
  const normalizedCandidates = [
21479
- ...candidatePaths.map((file4) => resolve28(file4)),
21502
+ ...candidatePaths.map((file4) => resolve29(file4)),
21480
21503
  ...compiledFallbackPaths
21481
21504
  ];
21482
- let candidate = normalizedCandidates.find((file4) => existsSync32(file4) && file4.endsWith(`${sep3}${relativeEntry}`));
21505
+ let candidate = normalizedCandidates.find((file4) => existsSync32(file4) && file4.endsWith(`${sep4}${relativeEntry}`));
21483
21506
  if (!candidate) {
21484
- candidate = normalizedCandidates.find((file4) => existsSync32(file4) && file4.endsWith(`${sep3}pages${sep3}${jsName}`));
21507
+ candidate = normalizedCandidates.find((file4) => existsSync32(file4) && file4.endsWith(`${sep4}pages${sep4}${jsName}`));
21485
21508
  }
21486
21509
  if (!candidate) {
21487
- candidate = normalizedCandidates.find((file4) => existsSync32(file4) && file4.endsWith(`${sep3}${jsName}`));
21510
+ candidate = normalizedCandidates.find((file4) => existsSync32(file4) && file4.endsWith(`${sep4}${jsName}`));
21488
21511
  }
21489
21512
  if (!candidate) {
21490
21513
  candidate = normalizedCandidates.find((file4) => existsSync32(file4));
@@ -21534,7 +21557,7 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
21534
21557
  })() : "no-providers";
21535
21558
  const serverContentHash = `${Bun.hash(original).toString(BASE_36_RADIX)}.${Bun.hash(providersHashInput).toString(BASE_36_RADIX)}`;
21536
21559
  const cachedWrapper = wrapperOutputCache.get(resolvedEntry);
21537
- const clientFile = join38(indexesDir, jsName);
21560
+ const clientFile = join39(indexesDir, jsName);
21538
21561
  if (hmr && cachedWrapper && cachedWrapper.serverHash === serverContentHash && existsSync32(clientFile) && (usesLegacyAnimations || !original.includes("__ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__")) && (!usesLegacyAnimations || original.includes("__ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__"))) {
21539
21562
  return {
21540
21563
  clientPath: clientFile,
@@ -21566,13 +21589,13 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
21566
21589
  const fragments = [];
21567
21590
  if (providersInjection.appProvidersSource) {
21568
21591
  const compiledAppProvidersPath = (() => {
21569
- const angularDirAbs = resolve28(outRoot);
21570
- const appSourceAbs = resolve28(providersInjection.appProvidersSource);
21571
- const rel = relative17(angularDirAbs, appSourceAbs).replace(/\\/g, "/");
21572
- return join38(compiledParent, rel).replace(/\.[cm]?[tj]sx?$/, ".js");
21592
+ const angularDirAbs = resolve29(outRoot);
21593
+ const appSourceAbs = resolve29(providersInjection.appProvidersSource);
21594
+ const rel = relative18(angularDirAbs, appSourceAbs).replace(/\\/g, "/");
21595
+ return join39(compiledParent, rel).replace(/\.[cm]?[tj]sx?$/, ".js");
21573
21596
  })();
21574
21597
  const appProvidersSpec = (() => {
21575
- const rel = relative17(dirname23(rawServerFile), compiledAppProvidersPath).replace(/\\/g, "/");
21598
+ const rel = relative18(dirname23(rawServerFile), compiledAppProvidersPath).replace(/\\/g, "/");
21576
21599
  return rel.startsWith(".") ? rel : `./${rel}`;
21577
21600
  })();
21578
21601
  importLines.push(`import { appProviders as __abs_globalProviders } from "${appProvidersSpec}";`);
@@ -21597,7 +21620,7 @@ export const providers = [${fragments.join(", ")}];
21597
21620
  }
21598
21621
  }
21599
21622
  await traceAngularPhase("wrapper/write-server-output", () => writeTextFileAtomically(rawServerFile, rewritten), { entry: resolvedEntry });
21600
- const relativePath = relative17(indexesDir, rawServerFile).replace(/\\/g, "/");
21623
+ const relativePath = relative18(indexesDir, rawServerFile).replace(/\\/g, "/");
21601
21624
  const normalizedImportPath = relativePath.startsWith(".") ? relativePath : `./${relativePath}`;
21602
21625
  const hmrPreamble = hmr ? `window.__HMR_FRAMEWORK__ = "angular";
21603
21626
  import "${hmrClientPath5}";
@@ -21830,7 +21853,7 @@ var init_compileAngular = __esm(() => {
21830
21853
  init_stylePreprocessor();
21831
21854
  init_generatedDir();
21832
21855
  devClientDir4 = resolveDevClientDir4();
21833
- hmrClientPath5 = join38(devClientDir4, "hmrClient.ts").replace(/\\/g, "/");
21856
+ hmrClientPath5 = join39(devClientDir4, "hmrClient.ts").replace(/\\/g, "/");
21834
21857
  jitContentCache = new Map;
21835
21858
  wrapperOutputCache = new Map;
21836
21859
  PROVIDERS_INJECTION_BLOCK_RE = /\n\/\* __ABS_PROVIDERS_INJECTION_START \*\/[\s\S]*?\/\* __ABS_PROVIDERS_INJECTION_END \*\/\n?/;
@@ -22285,7 +22308,7 @@ __export(exports_compileEmber, {
22285
22308
  });
22286
22309
  import { existsSync as existsSync33 } from "fs";
22287
22310
  import { mkdir as mkdir10, rm as rm5 } from "fs/promises";
22288
- import { basename as basename16, dirname as dirname24, extname as extname12, join as join39, resolve as resolve29 } from "path";
22311
+ import { basename as basename16, dirname as dirname24, extname as extname12, join as join40, resolve as resolve30 } from "path";
22289
22312
  var {build: bunBuild2, Transpiler: Transpiler5, write: write5, file: file4 } = globalThis.Bun;
22290
22313
  var cachedPreprocessor = null, getPreprocessor = async () => {
22291
22314
  if (cachedPreprocessor)
@@ -22381,7 +22404,7 @@ export const importSync = (specifier) => {
22381
22404
  const originalImporter = stagedSourceMap.get(args.importer);
22382
22405
  if (!originalImporter)
22383
22406
  return;
22384
- const candidateBase = resolve29(dirname24(originalImporter), args.path);
22407
+ const candidateBase = resolve30(dirname24(originalImporter), args.path);
22385
22408
  const extensionsToTry = ["", ".gts", ".gjs", ".ts", ".js"];
22386
22409
  for (const ext of extensionsToTry) {
22387
22410
  const candidate = candidateBase + ext;
@@ -22404,7 +22427,7 @@ export const importSync = (specifier) => {
22404
22427
  build.onResolve({ filter: /^@(?:ember|glimmer|simple-dom)\// }, (args) => {
22405
22428
  if (standalonePackages.has(args.path))
22406
22429
  return;
22407
- const internal = join39(cwd, "node_modules/ember-source/dist/packages", args.path, "index.js");
22430
+ const internal = join40(cwd, "node_modules/ember-source/dist/packages", args.path, "index.js");
22408
22431
  if (existsSync33(internal))
22409
22432
  return { path: internal };
22410
22433
  return;
@@ -22440,7 +22463,7 @@ export const renderToHTML = (props = {}) => {
22440
22463
  export { PageComponent };
22441
22464
  export default PageComponent;
22442
22465
  `, compileEmberFile = async (entry, compiledRoot, cwd = process.cwd()) => {
22443
- const resolvedEntry = resolve29(entry);
22466
+ const resolvedEntry = resolve30(entry);
22444
22467
  const source = await file4(resolvedEntry).text();
22445
22468
  let preprocessed = source;
22446
22469
  if (isTemplateTagFile(resolvedEntry)) {
@@ -22452,16 +22475,16 @@ export default PageComponent;
22452
22475
  }
22453
22476
  const transpiled = transpiler6.transformSync(preprocessed);
22454
22477
  const baseName = basename16(resolvedEntry).replace(/\.(gjs|gts|ts|js)$/, "");
22455
- const tmpDir = join39(compiledRoot, "_tmp");
22456
- const serverDir = join39(compiledRoot, "server");
22457
- const clientDir = join39(compiledRoot, "client");
22478
+ const tmpDir = join40(compiledRoot, "_tmp");
22479
+ const serverDir = join40(compiledRoot, "server");
22480
+ const clientDir = join40(compiledRoot, "client");
22458
22481
  await Promise.all([
22459
22482
  mkdir10(tmpDir, { recursive: true }),
22460
22483
  mkdir10(serverDir, { recursive: true }),
22461
22484
  mkdir10(clientDir, { recursive: true })
22462
22485
  ]);
22463
- const tmpPagePath = resolve29(join39(tmpDir, `${baseName}.module.js`));
22464
- const tmpHarnessPath = resolve29(join39(tmpDir, `${baseName}.harness.js`));
22486
+ const tmpPagePath = resolve30(join40(tmpDir, `${baseName}.module.js`));
22487
+ const tmpHarnessPath = resolve30(join40(tmpDir, `${baseName}.harness.js`));
22465
22488
  await Promise.all([
22466
22489
  write5(tmpPagePath, transpiled),
22467
22490
  write5(tmpHarnessPath, generateServerHarness(tmpPagePath))
@@ -22469,7 +22492,7 @@ export default PageComponent;
22469
22492
  const stagedSourceMap = new Map([
22470
22493
  [tmpPagePath, resolvedEntry]
22471
22494
  ]);
22472
- const serverPath = join39(serverDir, `${baseName}.js`);
22495
+ const serverPath = join40(serverDir, `${baseName}.js`);
22473
22496
  const buildResult = await bunBuild2({
22474
22497
  entrypoints: [tmpHarnessPath],
22475
22498
  format: "esm",
@@ -22486,7 +22509,7 @@ export default PageComponent;
22486
22509
  console.warn(`\u26A0\uFE0F Ember server build for ${baseName} had errors:`, buildResult.logs);
22487
22510
  }
22488
22511
  await rm5(tmpDir, { force: true, recursive: true });
22489
- const clientPath = join39(clientDir, `${baseName}.js`);
22512
+ const clientPath = join40(clientDir, `${baseName}.js`);
22490
22513
  await write5(clientPath, transpiled);
22491
22514
  return { clientPath, serverPath };
22492
22515
  }, compileEmber = async (entries, emberDir, cwd = process.cwd(), _hmr = false) => {
@@ -22503,7 +22526,7 @@ export default PageComponent;
22503
22526
  serverPaths: outputs.map((o3) => o3.serverPath)
22504
22527
  };
22505
22528
  }, compileEmberFileSource = async (entry) => {
22506
- const resolvedEntry = resolve29(entry);
22529
+ const resolvedEntry = resolve30(entry);
22507
22530
  const source = await file4(resolvedEntry).text();
22508
22531
  let preprocessed = source;
22509
22532
  if (isTemplateTagFile(resolvedEntry)) {
@@ -22514,7 +22537,7 @@ export default PageComponent;
22514
22537
  preprocessed = rewriteTemplateEvalToScope(result.code);
22515
22538
  }
22516
22539
  return transpiler6.transformSync(preprocessed);
22517
- }, clearEmberCompilerCache = () => {}, getEmberCompiledRoot = (_emberDir) => getFrameworkGeneratedDir("ember"), getEmberServerCompiledDir = (emberDir) => join39(getEmberCompiledRoot(emberDir), "server"), getEmberClientCompiledDir = (emberDir) => join39(getEmberCompiledRoot(emberDir), "client");
22540
+ }, clearEmberCompilerCache = () => {}, getEmberCompiledRoot = (_emberDir) => getFrameworkGeneratedDir("ember"), getEmberServerCompiledDir = (emberDir) => join40(getEmberCompiledRoot(emberDir), "server"), getEmberClientCompiledDir = (emberDir) => join40(getEmberCompiledRoot(emberDir), "client");
22518
22541
  var init_compileEmber = __esm(() => {
22519
22542
  init_generatedDir();
22520
22543
  transpiler6 = new Transpiler5({
@@ -22536,24 +22559,24 @@ __export(exports_buildReactVendor, {
22536
22559
  computeVendorPaths: () => computeVendorPaths
22537
22560
  });
22538
22561
  import { existsSync as existsSync34, mkdirSync as mkdirSync8 } from "fs";
22539
- import { join as join40, resolve as resolve30 } from "path";
22562
+ import { join as join41, resolve as resolve31 } from "path";
22540
22563
  import { rm as rm6 } from "fs/promises";
22541
22564
  var {build: bunBuild3 } = globalThis.Bun;
22542
22565
  var resolveJsxDevRuntimeCompatPath = () => {
22543
22566
  const candidates = [
22544
- resolve30(import.meta.dir, "react", "jsxDevRuntimeCompat.js"),
22545
- resolve30(import.meta.dir, "src", "react", "jsxDevRuntimeCompat.ts"),
22546
- resolve30(import.meta.dir, "..", "react", "jsxDevRuntimeCompat.js"),
22547
- resolve30(import.meta.dir, "..", "src", "react", "jsxDevRuntimeCompat.ts"),
22548
- resolve30(import.meta.dir, "..", "..", "dist", "react", "jsxDevRuntimeCompat.js"),
22549
- resolve30(import.meta.dir, "..", "..", "src", "react", "jsxDevRuntimeCompat.ts")
22567
+ resolve31(import.meta.dir, "react", "jsxDevRuntimeCompat.js"),
22568
+ resolve31(import.meta.dir, "src", "react", "jsxDevRuntimeCompat.ts"),
22569
+ resolve31(import.meta.dir, "..", "react", "jsxDevRuntimeCompat.js"),
22570
+ resolve31(import.meta.dir, "..", "src", "react", "jsxDevRuntimeCompat.ts"),
22571
+ resolve31(import.meta.dir, "..", "..", "dist", "react", "jsxDevRuntimeCompat.js"),
22572
+ resolve31(import.meta.dir, "..", "..", "src", "react", "jsxDevRuntimeCompat.ts")
22550
22573
  ];
22551
22574
  for (const candidate of candidates) {
22552
22575
  if (existsSync34(candidate)) {
22553
22576
  return candidate.replace(/\\/g, "/");
22554
22577
  }
22555
22578
  }
22556
- return (candidates[0] ?? resolve30(import.meta.dir, "react", "jsxDevRuntimeCompat.js")).replace(/\\/g, "/");
22579
+ return (candidates[0] ?? resolve31(import.meta.dir, "react", "jsxDevRuntimeCompat.js")).replace(/\\/g, "/");
22557
22580
  }, jsxDevRuntimeCompatPath, jsxRuntimeCompatPath, reactSpecifiers, toSafeFileName = (specifier) => specifier.replace(/\//g, "_"), computeVendorPaths = () => {
22558
22581
  const paths = {};
22559
22582
  for (const specifier of reactSpecifiers) {
@@ -22586,14 +22609,14 @@ var resolveJsxDevRuntimeCompatPath = () => {
22586
22609
  `)}
22587
22610
  `;
22588
22611
  }, buildReactVendor = async (buildDir) => {
22589
- const vendorDir = join40(buildDir, "react", "vendor");
22612
+ const vendorDir = join41(buildDir, "react", "vendor");
22590
22613
  mkdirSync8(vendorDir, { recursive: true });
22591
- const tmpDir = join40(buildDir, "_vendor_tmp");
22614
+ const tmpDir = join41(buildDir, "_vendor_tmp");
22592
22615
  mkdirSync8(tmpDir, { recursive: true });
22593
22616
  const specifiers = reactSpecifiers;
22594
22617
  const entrypoints = await Promise.all(specifiers.map(async (specifier) => {
22595
22618
  const safeName = toSafeFileName(specifier);
22596
- const entryPath = join40(tmpDir, `${safeName}.ts`);
22619
+ const entryPath = join41(tmpDir, `${safeName}.ts`);
22597
22620
  const source = await generateEntrySource(specifier);
22598
22621
  await Bun.write(entryPath, source);
22599
22622
  return entryPath;
@@ -22661,7 +22684,7 @@ __export(exports_buildAngularVendor, {
22661
22684
  computeAngularVendorPathsAsync: () => computeAngularVendorPathsAsync
22662
22685
  });
22663
22686
  import { mkdirSync as mkdirSync9 } from "fs";
22664
- import { join as join41 } from "path";
22687
+ import { join as join42 } from "path";
22665
22688
  import { rm as rm7 } from "fs/promises";
22666
22689
  var {build: bunBuild4, Glob: Glob7 } = globalThis.Bun;
22667
22690
  var REQUIRED_ANGULAR_SPECIFIERS_BASE, requiredAngularSpecifiers = (jitMode) => jitMode ? [...REQUIRED_ANGULAR_SPECIFIERS_BASE, "@angular/compiler"] : REQUIRED_ANGULAR_SPECIFIERS_BASE, SERVER_ONLY_ANGULAR_SPECIFIERS, BUILD_ONLY_ANGULAR_SPECIFIER_PREFIXES, isBuildOnlyAngularSpecifier = (spec) => BUILD_ONLY_ANGULAR_SPECIFIER_PREFIXES.some((prefix) => spec === prefix || spec.startsWith(`${prefix}/`)), SCAN_SKIP_DIRS, isResolvable = (specifier) => {
@@ -22758,14 +22781,14 @@ var REQUIRED_ANGULAR_SPECIFIERS_BASE, requiredAngularSpecifiers = (jitMode) => j
22758
22781
  await collectTransitiveAngularSpecs([...angular, ...transitiveRoots], angular);
22759
22782
  return Array.from(angular).filter(isResolvable);
22760
22783
  }, buildAngularVendor = async (buildDir, directories = [], linkerJitMode = false, depVendorSpecifiers = []) => {
22761
- const vendorDir = join41(buildDir, "angular", "vendor");
22784
+ const vendorDir = join42(buildDir, "angular", "vendor");
22762
22785
  mkdirSync9(vendorDir, { recursive: true });
22763
- const tmpDir = join41(buildDir, "_angular_vendor_tmp");
22786
+ const tmpDir = join42(buildDir, "_angular_vendor_tmp");
22764
22787
  mkdirSync9(tmpDir, { recursive: true });
22765
22788
  const specifiers = await resolveAngularSpecifiers(directories, linkerJitMode);
22766
22789
  const entrypoints = await Promise.all(specifiers.map(async (specifier) => {
22767
22790
  const safeName = toSafeFileName2(specifier);
22768
- const entryPath = join41(tmpDir, `${safeName}.ts`);
22791
+ const entryPath = join42(tmpDir, `${safeName}.ts`);
22769
22792
  await Bun.write(entryPath, await generateVendorEntrySource(specifier));
22770
22793
  return entryPath;
22771
22794
  }));
@@ -22796,9 +22819,9 @@ var REQUIRED_ANGULAR_SPECIFIERS_BASE, requiredAngularSpecifiers = (jitMode) => j
22796
22819
  const specifiers = await resolveAngularSpecifiers(directories, linkerJitMode);
22797
22820
  return computeAngularVendorPaths(specifiers);
22798
22821
  }, buildAngularServerVendor = async (buildDir, directories = [], linkerJitMode = false) => {
22799
- const vendorDir = join41(buildDir, "angular", "vendor", "server");
22822
+ const vendorDir = join42(buildDir, "angular", "vendor", "server");
22800
22823
  mkdirSync9(vendorDir, { recursive: true });
22801
- const tmpDir = join41(buildDir, "_angular_server_vendor_tmp");
22824
+ const tmpDir = join42(buildDir, "_angular_server_vendor_tmp");
22802
22825
  mkdirSync9(tmpDir, { recursive: true });
22803
22826
  const browserSpecs = await resolveAngularSpecifiers(directories, linkerJitMode);
22804
22827
  const allSpecs = new Set(browserSpecs);
@@ -22809,7 +22832,7 @@ var REQUIRED_ANGULAR_SPECIFIERS_BASE, requiredAngularSpecifiers = (jitMode) => j
22809
22832
  const specifiers = Array.from(allSpecs);
22810
22833
  const entrypoints = await Promise.all(specifiers.map(async (specifier) => {
22811
22834
  const safeName = toSafeFileName2(specifier);
22812
- const entryPath = join41(tmpDir, `${safeName}.ts`);
22835
+ const entryPath = join42(tmpDir, `${safeName}.ts`);
22813
22836
  await Bun.write(entryPath, await generateVendorEntrySource(specifier));
22814
22837
  return entryPath;
22815
22838
  }));
@@ -22831,9 +22854,9 @@ var REQUIRED_ANGULAR_SPECIFIERS_BASE, requiredAngularSpecifiers = (jitMode) => j
22831
22854
  return specifiers;
22832
22855
  }, computeAngularServerVendorPaths = (buildDir, specifiers) => {
22833
22856
  const paths = {};
22834
- const vendorDir = join41(buildDir, "angular", "vendor", "server");
22857
+ const vendorDir = join42(buildDir, "angular", "vendor", "server");
22835
22858
  for (const specifier of specifiers) {
22836
- paths[specifier] = join41(vendorDir, `${toSafeFileName2(specifier)}.js`);
22859
+ paths[specifier] = join42(vendorDir, `${toSafeFileName2(specifier)}.js`);
22837
22860
  }
22838
22861
  return paths;
22839
22862
  }, computeAngularServerVendorPathsAsync = async (buildDir, directories = [], linkerJitMode = true) => {
@@ -22889,17 +22912,17 @@ __export(exports_buildVueVendor, {
22889
22912
  computeVueVendorPaths: () => computeVueVendorPaths
22890
22913
  });
22891
22914
  import { mkdirSync as mkdirSync10 } from "fs";
22892
- import { join as join42 } from "path";
22915
+ import { join as join43 } from "path";
22893
22916
  import { rm as rm8 } from "fs/promises";
22894
22917
  var {build: bunBuild5 } = globalThis.Bun;
22895
22918
  var vueSpecifiers, toSafeFileName3 = (specifier) => specifier.replace(/\//g, "_"), buildVueVendor = async (buildDir) => {
22896
- const vendorDir = join42(buildDir, "vue", "vendor");
22919
+ const vendorDir = join43(buildDir, "vue", "vendor");
22897
22920
  mkdirSync10(vendorDir, { recursive: true });
22898
- const tmpDir = join42(buildDir, "_vue_vendor_tmp");
22921
+ const tmpDir = join43(buildDir, "_vue_vendor_tmp");
22899
22922
  mkdirSync10(tmpDir, { recursive: true });
22900
22923
  const entrypoints = await Promise.all(vueSpecifiers.map(async (specifier) => {
22901
22924
  const safeName = toSafeFileName3(specifier);
22902
- const entryPath = join42(tmpDir, `${safeName}.ts`);
22925
+ const entryPath = join43(tmpDir, `${safeName}.ts`);
22903
22926
  await Bun.write(entryPath, `export * from '${specifier}';
22904
22927
  `);
22905
22928
  return entryPath;
@@ -22927,7 +22950,7 @@ var vueSpecifiers, toSafeFileName3 = (specifier) => specifier.replace(/\//g, "_"
22927
22950
  const { readFileSync: readFileSync27, writeFileSync: writeFileSync9, readdirSync: readdirSync7 } = await import("fs");
22928
22951
  const files = readdirSync7(vendorDir).filter((f2) => f2.endsWith(".js"));
22929
22952
  for (const file5 of files) {
22930
- const filePath = join42(vendorDir, file5);
22953
+ const filePath = join43(vendorDir, file5);
22931
22954
  const content = readFileSync27(filePath, "utf-8");
22932
22955
  if (!content.includes("__VUE_HMR_RUNTIME__"))
22933
22956
  continue;
@@ -22954,7 +22977,7 @@ __export(exports_buildSvelteVendor, {
22954
22977
  computeSvelteVendorPaths: () => computeSvelteVendorPaths
22955
22978
  });
22956
22979
  import { mkdirSync as mkdirSync11 } from "fs";
22957
- import { join as join43 } from "path";
22980
+ import { join as join44 } from "path";
22958
22981
  import { rm as rm9 } from "fs/promises";
22959
22982
  var {build: bunBuild6 } = globalThis.Bun;
22960
22983
  var svelteSpecifiers, isResolvable2 = (specifier) => {
@@ -22968,13 +22991,13 @@ var svelteSpecifiers, isResolvable2 = (specifier) => {
22968
22991
  const specifiers = resolveVendorSpecifiers();
22969
22992
  if (specifiers.length === 0)
22970
22993
  return;
22971
- const vendorDir = join43(buildDir, "svelte", "vendor");
22994
+ const vendorDir = join44(buildDir, "svelte", "vendor");
22972
22995
  mkdirSync11(vendorDir, { recursive: true });
22973
- const tmpDir = join43(buildDir, "_svelte_vendor_tmp");
22996
+ const tmpDir = join44(buildDir, "_svelte_vendor_tmp");
22974
22997
  mkdirSync11(tmpDir, { recursive: true });
22975
22998
  const entrypoints = await Promise.all(specifiers.map(async (specifier) => {
22976
22999
  const safeName = toSafeFileName4(specifier);
22977
- const entryPath = join43(tmpDir, `${safeName}.ts`);
23000
+ const entryPath = join44(tmpDir, `${safeName}.ts`);
22978
23001
  await Bun.write(entryPath, `export * from '${specifier}';
22979
23002
  `);
22980
23003
  return entryPath;
@@ -23025,7 +23048,7 @@ import {
23025
23048
  statSync as statSync4,
23026
23049
  writeFileSync as writeFileSync9
23027
23050
  } from "fs";
23028
- import { basename as basename17, dirname as dirname25, extname as extname13, join as join44, relative as relative18, resolve as resolve31 } from "path";
23051
+ import { basename as basename17, dirname as dirname25, extname as extname13, join as join45, relative as relative19, resolve as resolve32 } from "path";
23029
23052
  import { cwd, env as env2, exit } from "process";
23030
23053
  var {build: bunBuild7, Glob: Glob8 } = globalThis.Bun;
23031
23054
  var isBuildTraceEnabled = () => {
@@ -23159,8 +23182,8 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23159
23182
  mkdirSync12(htmxDestDir, { recursive: true });
23160
23183
  const glob = new Glob8("htmx*.min.js");
23161
23184
  for (const relPath of glob.scanSync({ cwd: htmxDir })) {
23162
- const src = join44(htmxDir, relPath);
23163
- const dest = join44(htmxDestDir, "htmx.min.js");
23185
+ const src = join45(htmxDir, relPath);
23186
+ const dest = join45(htmxDestDir, "htmx.min.js");
23164
23187
  copyFileSync3(src, dest);
23165
23188
  return;
23166
23189
  }
@@ -23174,8 +23197,8 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23174
23197
  if (globalThis.__absoluteVersion)
23175
23198
  return;
23176
23199
  const candidates = [
23177
- resolve31(import.meta.dir, "..", "..", "package.json"),
23178
- resolve31(import.meta.dir, "..", "package.json")
23200
+ resolve32(import.meta.dir, "..", "..", "package.json"),
23201
+ resolve32(import.meta.dir, "..", "package.json")
23179
23202
  ];
23180
23203
  const resolveCandidate = async (remaining) => {
23181
23204
  const [candidate, ...rest] = remaining;
@@ -23191,7 +23214,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23191
23214
  };
23192
23215
  await resolveCandidate(candidates);
23193
23216
  }, SKIP_DIRS5, addWorkerPathIfExists = (file5, relPath, workerPaths) => {
23194
- const absPath = resolve31(file5, "..", relPath);
23217
+ const absPath = resolve32(file5, "..", relPath);
23195
23218
  try {
23196
23219
  statSync4(absPath);
23197
23220
  workerPaths.add(absPath);
@@ -23244,7 +23267,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23244
23267
  const out = [];
23245
23268
  const directories = [];
23246
23269
  for (const entry of entries) {
23247
- const full = join44(dir, entry.name);
23270
+ const full = join45(dir, entry.name);
23248
23271
  if (entry.isDirectory()) {
23249
23272
  directories.push(full);
23250
23273
  } else if (entry.isFile() && entry.name.endsWith(".ts") && !entry.name.endsWith(".d.ts")) {
@@ -23270,7 +23293,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23270
23293
  vuePagesPath
23271
23294
  }) => {
23272
23295
  const { readdirSync: readDir } = await import("fs");
23273
- const devIndexDir = join44(buildPath, "_src_indexes");
23296
+ const devIndexDir = join45(buildPath, "_src_indexes");
23274
23297
  mkdirSync12(devIndexDir, { recursive: true });
23275
23298
  if (reactIndexesPath && reactPagesPath) {
23276
23299
  copyReactDevIndexes(reactIndexesPath, reactPagesPath, devIndexDir, readDir);
@@ -23286,42 +23309,42 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23286
23309
  return;
23287
23310
  }
23288
23311
  const indexFiles = readDir(reactIndexesPath).filter((file5) => file5.endsWith(".tsx"));
23289
- const pagesRel = relative18(process.cwd(), resolve31(reactPagesPath)).replace(/\\/g, "/");
23312
+ const pagesRel = relative19(process.cwd(), resolve32(reactPagesPath)).replace(/\\/g, "/");
23290
23313
  for (const file5 of indexFiles) {
23291
- let content = readFileSync27(join44(reactIndexesPath, file5), "utf-8");
23314
+ let content = readFileSync27(join45(reactIndexesPath, file5), "utf-8");
23292
23315
  content = content.replace(/from\s*['"]([^'"]*\/pages\/([^'"]+))['"]/g, (_match, _fullPath, componentName) => `from '/@src/${pagesRel}/${componentName}'`);
23293
- writeFileSync9(join44(devIndexDir, file5), content);
23316
+ writeFileSync9(join45(devIndexDir, file5), content);
23294
23317
  }
23295
23318
  }, copySvelteDevIndexes = (svelteDir, sveltePagesPath, svelteEntries, devIndexDir) => {
23296
- const svelteIndexDir = join44(getFrameworkGeneratedDir("svelte"), "indexes");
23297
- const sveltePageEntries = svelteEntries.filter((file5) => resolve31(file5).startsWith(resolve31(sveltePagesPath)));
23319
+ const svelteIndexDir = join45(getFrameworkGeneratedDir("svelte"), "indexes");
23320
+ const sveltePageEntries = svelteEntries.filter((file5) => resolve32(file5).startsWith(resolve32(sveltePagesPath)));
23298
23321
  for (const entry of sveltePageEntries) {
23299
23322
  const name = basename17(entry).replace(/\.svelte(\.(ts|js))?$/, "");
23300
- const indexFile = join44(svelteIndexDir, "pages", `${name}.js`);
23323
+ const indexFile = join45(svelteIndexDir, "pages", `${name}.js`);
23301
23324
  if (!existsSync35(indexFile))
23302
23325
  continue;
23303
23326
  let content = readFileSync27(indexFile, "utf-8");
23304
- const srcRel = relative18(process.cwd(), resolve31(entry)).replace(/\\/g, "/");
23327
+ const srcRel = relative19(process.cwd(), resolve32(entry)).replace(/\\/g, "/");
23305
23328
  content = content.replace(/import\s+Component\s+from\s+['"]([^'"]+)['"]/, `import Component from "/@src/${srcRel}"`);
23306
- writeFileSync9(join44(devIndexDir, `${name}.svelte.js`), content);
23329
+ writeFileSync9(join45(devIndexDir, `${name}.svelte.js`), content);
23307
23330
  }
23308
23331
  }, copyVueDevIndexes = (vueDir, vuePagesPath, vueEntries, devIndexDir) => {
23309
- const vueIndexDir = join44(getFrameworkGeneratedDir("vue"), "indexes");
23310
- const vuePageEntries = vueEntries.filter((file5) => resolve31(file5).startsWith(resolve31(vuePagesPath)));
23332
+ const vueIndexDir = join45(getFrameworkGeneratedDir("vue"), "indexes");
23333
+ const vuePageEntries = vueEntries.filter((file5) => resolve32(file5).startsWith(resolve32(vuePagesPath)));
23311
23334
  for (const entry of vuePageEntries) {
23312
23335
  const name = basename17(entry, ".vue");
23313
- const indexFile = join44(vueIndexDir, `${name}.js`);
23336
+ const indexFile = join45(vueIndexDir, `${name}.js`);
23314
23337
  if (!existsSync35(indexFile))
23315
23338
  continue;
23316
23339
  let content = readFileSync27(indexFile, "utf-8");
23317
- const srcRel = relative18(process.cwd(), resolve31(entry)).replace(/\\/g, "/");
23340
+ const srcRel = relative19(process.cwd(), resolve32(entry)).replace(/\\/g, "/");
23318
23341
  content = content.replace(/import\s+Comp(?:\s*,\s*\*\s+as\s+\w+)?\s+from\s+['"]([^'"]+)['"]/, (match) => match.replace(/from\s+['"][^'"]+['"]/, `from "/@src/${srcRel}"`));
23319
- writeFileSync9(join44(devIndexDir, `${name}.vue.js`), content);
23342
+ writeFileSync9(join45(devIndexDir, `${name}.vue.js`), content);
23320
23343
  }
23321
23344
  }, buildDevUrlFileMap = (urlReferencedFiles, projectRoot) => {
23322
23345
  const urlFileMap = new Map;
23323
23346
  for (const srcPath of urlReferencedFiles) {
23324
- const rel = relative18(projectRoot, srcPath).replace(/\\/g, "/");
23347
+ const rel = relative19(projectRoot, srcPath).replace(/\\/g, "/");
23325
23348
  const name = basename17(srcPath);
23326
23349
  const mtime = Math.round(statSync4(srcPath).mtimeMs);
23327
23350
  const url = `/@src/${rel}?v=${mtime}`;
@@ -23336,7 +23359,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23336
23359
  const output = nonReactClientOutputs.find((artifact) => basename17(artifact.path).startsWith(`${srcBase}.`));
23337
23360
  if (!output)
23338
23361
  continue;
23339
- urlFileMap.set(basename17(srcPath), `/${relative18(buildPath, output.path).replace(/\\/g, "/")}`);
23362
+ urlFileMap.set(basename17(srcPath), `/${relative19(buildPath, output.path).replace(/\\/g, "/")}`);
23340
23363
  }
23341
23364
  return urlFileMap;
23342
23365
  }, buildUrlFileMap = (urlReferencedFiles, hmr, projectRoot, buildPath, nonReactClientOutputs) => {
@@ -23477,10 +23500,10 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23477
23500
  restoreTracePhase();
23478
23501
  return;
23479
23502
  }
23480
- const traceDir = join44(buildPath2, ".absolute-trace");
23503
+ const traceDir = join45(buildPath2, ".absolute-trace");
23481
23504
  const timestamp = new Date().toISOString().replace(/[:.]/g, "-");
23482
23505
  mkdirSync12(traceDir, { recursive: true });
23483
- writeFileSync9(join44(traceDir, `build-trace-${timestamp}.json`), JSON.stringify({
23506
+ writeFileSync9(join45(traceDir, `build-trace-${timestamp}.json`), JSON.stringify({
23484
23507
  events: traceEvents,
23485
23508
  frameworks: traceFrameworkNames,
23486
23509
  generatedAt: new Date().toISOString(),
@@ -23511,16 +23534,16 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23511
23534
  const stylesPath = typeof stylesConfig === "string" ? stylesConfig : stylesConfig?.path;
23512
23535
  const stylesIgnore = typeof stylesConfig === "object" ? stylesConfig.ignore : undefined;
23513
23536
  const stylesDir = stylesPath && validateSafePath(stylesPath, projectRoot);
23514
- const reactIndexesPath = reactDir && join44(getFrameworkGeneratedDir("react"), "indexes");
23515
- const reactPagesPath = reactDir && join44(reactDir, "pages");
23516
- const htmlPagesPath = htmlDir && join44(htmlDir, "pages");
23517
- const htmlScriptsPath = htmlDir && join44(htmlDir, "scripts");
23518
- const sveltePagesPath = svelteDir && join44(svelteDir, "pages");
23519
- const vuePagesPath = vueDir && join44(vueDir, "pages");
23520
- const htmxPagesPath = htmxDir && join44(htmxDir, "pages");
23521
- const htmxScriptsPath = htmxDir && join44(htmxDir, "scripts");
23522
- const angularPagesPath = angularDir && join44(angularDir, "pages");
23523
- const emberPagesPath = emberDir && join44(emberDir, "pages");
23537
+ const reactIndexesPath = reactDir && join45(getFrameworkGeneratedDir("react"), "indexes");
23538
+ const reactPagesPath = reactDir && join45(reactDir, "pages");
23539
+ const htmlPagesPath = htmlDir && join45(htmlDir, "pages");
23540
+ const htmlScriptsPath = htmlDir && join45(htmlDir, "scripts");
23541
+ const sveltePagesPath = svelteDir && join45(svelteDir, "pages");
23542
+ const vuePagesPath = vueDir && join45(vueDir, "pages");
23543
+ const htmxPagesPath = htmxDir && join45(htmxDir, "pages");
23544
+ const htmxScriptsPath = htmxDir && join45(htmxDir, "scripts");
23545
+ const angularPagesPath = angularDir && join45(angularDir, "pages");
23546
+ const emberPagesPath = emberDir && join45(emberDir, "pages");
23524
23547
  const frontends = [
23525
23548
  reactDir,
23526
23549
  htmlDir,
@@ -23581,8 +23604,8 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23581
23604
  const [firstEntry] = serverDirMap;
23582
23605
  if (!firstEntry)
23583
23606
  throw new Error("Expected at least one server directory entry");
23584
- serverRoot = join44(firstEntry.dir, firstEntry.subdir);
23585
- serverOutDir = join44(buildPath, basename17(firstEntry.dir));
23607
+ serverRoot = join45(firstEntry.dir, firstEntry.subdir);
23608
+ serverOutDir = join45(buildPath, basename17(firstEntry.dir));
23586
23609
  } else if (serverDirMap.length > 1) {
23587
23610
  serverRoot = commonAncestor(serverDirMap.map((entry) => entry.dir), projectRoot);
23588
23611
  serverOutDir = buildPath;
@@ -23601,13 +23624,13 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23601
23624
  const filterToIncrementalEntries = (entryPoints, mapToSource) => {
23602
23625
  if (!isIncremental || !incrementalFiles)
23603
23626
  return entryPoints;
23604
- const normalizedIncremental = new Set(incrementalFiles.map((f2) => resolve31(f2)));
23627
+ const normalizedIncremental = new Set(incrementalFiles.map((f2) => resolve32(f2)));
23605
23628
  const matchingEntries = [];
23606
23629
  for (const entry of entryPoints) {
23607
23630
  const sourceFile = mapToSource(entry);
23608
23631
  if (!sourceFile)
23609
23632
  continue;
23610
- if (!normalizedIncremental.has(resolve31(sourceFile)))
23633
+ if (!normalizedIncremental.has(resolve32(sourceFile)))
23611
23634
  continue;
23612
23635
  matchingEntries.push(entry);
23613
23636
  }
@@ -23617,7 +23640,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23617
23640
  await tracePhase("react/index-generation", () => generateReactIndexFiles(reactPagesPath, reactIndexesPath, hmr));
23618
23641
  }
23619
23642
  if (assetsPath && (!isIncremental || normalizedIncrementalFiles?.some((f2) => f2.includes("/assets/")))) {
23620
- await tracePhase("assets/copy", () => cpSync(assetsPath, join44(buildPath, "assets"), {
23643
+ await tracePhase("assets/copy", () => cpSync(assetsPath, join45(buildPath, "assets"), {
23621
23644
  force: true,
23622
23645
  recursive: true
23623
23646
  }));
@@ -23731,11 +23754,11 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23731
23754
  }
23732
23755
  }
23733
23756
  if (htmlDefaults.error || htmlDefaults.notFound || htmlDefaults.loading || Object.keys(htmlPages).length > 0) {
23734
- const htmlConventionsOutDir = join44(buildPath, "conventions", "html");
23757
+ const htmlConventionsOutDir = join45(buildPath, "conventions", "html");
23735
23758
  mkdirSync12(htmlConventionsOutDir, { recursive: true });
23736
23759
  const htmlPathRemap = new Map;
23737
23760
  for (const sourcePath of htmlConventionSources) {
23738
- const dest = join44(htmlConventionsOutDir, basename17(sourcePath));
23761
+ const dest = join45(htmlConventionsOutDir, basename17(sourcePath));
23739
23762
  cpSync(sourcePath, dest, { force: true });
23740
23763
  htmlPathRemap.set(sourcePath, dest);
23741
23764
  }
@@ -23783,13 +23806,13 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23783
23806
  return scoped;
23784
23807
  return scoped.filter((entry) => {
23785
23808
  const source = mapToSource(entry);
23786
- return source !== null && deferPageEntries.except.has(resolve31(source));
23809
+ return source !== null && deferPageEntries.except.has(resolve32(source));
23787
23810
  });
23788
23811
  };
23789
23812
  const mapReactIndexToPage = (entry) => {
23790
- if (reactIndexesPath && reactPagesPath && entry.startsWith(resolve31(reactIndexesPath))) {
23813
+ if (reactIndexesPath && reactPagesPath && entry.startsWith(resolve32(reactIndexesPath))) {
23791
23814
  const pageName = basename17(entry, ".tsx");
23792
- return join44(reactPagesPath, `${pageName}.tsx`);
23815
+ return join45(reactPagesPath, `${pageName}.tsx`);
23793
23816
  }
23794
23817
  return null;
23795
23818
  };
@@ -23829,7 +23852,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23829
23852
  for (const entry of vueEntries) {
23830
23853
  const name = basename17(entry, ".vue");
23831
23854
  if (ssrOnlyPageNames.has(name)) {
23832
- resolved.add(resolve31(entry));
23855
+ resolved.add(resolve32(entry));
23833
23856
  }
23834
23857
  }
23835
23858
  return resolved;
@@ -23944,7 +23967,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23944
23967
  const clientPath = islandSvelteClientPaths[idx];
23945
23968
  if (!sourcePath || !clientPath)
23946
23969
  continue;
23947
- islandSvelteClientPathMap.set(resolve31(sourcePath), clientPath);
23970
+ islandSvelteClientPathMap.set(resolve32(sourcePath), clientPath);
23948
23971
  }
23949
23972
  const islandVueClientPathMap = new Map;
23950
23973
  for (let idx = 0;idx < islandVueSources.length; idx++) {
@@ -23952,7 +23975,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23952
23975
  const clientPath = islandVueClientPaths[idx];
23953
23976
  if (!sourcePath || !clientPath)
23954
23977
  continue;
23955
- islandVueClientPathMap.set(resolve31(sourcePath), clientPath);
23978
+ islandVueClientPathMap.set(resolve32(sourcePath), clientPath);
23956
23979
  }
23957
23980
  const islandAngularClientPathMap = new Map;
23958
23981
  for (let idx = 0;idx < islandAngularSources.length; idx++) {
@@ -23960,7 +23983,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23960
23983
  const clientPath = islandAngularClientPaths[idx];
23961
23984
  if (!sourcePath || !clientPath)
23962
23985
  continue;
23963
- islandAngularClientPathMap.set(resolve31(sourcePath), clientPath);
23986
+ islandAngularClientPathMap.set(resolve32(sourcePath), clientPath);
23964
23987
  }
23965
23988
  const reactConventionSources = collectConventionSourceFiles(conventionsMap.react);
23966
23989
  const svelteConventionSources = collectConventionSourceFiles(conventionsMap.svelte);
@@ -23971,7 +23994,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
23971
23994
  const compileReactConventions = async () => {
23972
23995
  if (reactConventionSources.length === 0)
23973
23996
  return emptyStringArray;
23974
- const destDir = join44(buildPath, "conventions", "react");
23997
+ const destDir = join45(buildPath, "conventions", "react");
23975
23998
  rmSync2(destDir, { force: true, recursive: true });
23976
23999
  mkdirSync12(destDir, { recursive: true });
23977
24000
  const destPaths = await Promise.all(reactConventionSources.map(async (source, idx) => {
@@ -24015,7 +24038,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24015
24038
  angularConventionSources.length > 0 && angularDir ? tracePhase("compile/convention-angular", () => Promise.resolve().then(() => (init_compileAngular(), exports_compileAngular)).then((mod) => mod.compileAngular(angularConventionSources, angularDir, hmr, styleTransformConfig))) : { serverPaths: emptyStringArray }
24016
24039
  ]);
24017
24040
  const bundleConventionFiles = async (framework, compiledPaths) => {
24018
- const destDir = join44(buildPath, "conventions", framework);
24041
+ const destDir = join45(buildPath, "conventions", framework);
24019
24042
  rmSync2(destDir, { force: true, recursive: true });
24020
24043
  mkdirSync12(destDir, { recursive: true });
24021
24044
  const destPaths = await Promise.all(compiledPaths.map(async (compiledPath, idx) => {
@@ -24090,7 +24113,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24090
24113
  }
24091
24114
  })) : {
24092
24115
  entries: [],
24093
- generatedRoot: join44(buildPath, "_island_entries")
24116
+ generatedRoot: join45(buildPath, "_island_entries")
24094
24117
  };
24095
24118
  const islandClientEntryPoints = islandEntryResult.entries.map((entry) => entry.entryPath);
24096
24119
  if (!deferPageEntries && serverEntryPoints.length === 0 && reactClientEntryPoints.length === 0 && nonReactClientEntryPoints.length === 0 && urlReferencedFiles.length === 0 && islandClientEntryPoints.length === 0 && htmxDir === undefined && htmlDir === undefined) {
@@ -24126,7 +24149,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24126
24149
  return {};
24127
24150
  }
24128
24151
  if (hmr && reactIndexesPath && reactClientEntryPoints.length > 0) {
24129
- const refreshEntry = join44(reactIndexesPath, "_refresh.tsx");
24152
+ const refreshEntry = join45(reactIndexesPath, "_refresh.tsx");
24130
24153
  if (!reactClientEntryPoints.includes(refreshEntry))
24131
24154
  reactClientEntryPoints.push(refreshEntry);
24132
24155
  }
@@ -24243,19 +24266,19 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24243
24266
  throw: false
24244
24267
  }, resolveBunBuildOverride(bunBuildConfig, "reactClient")) : undefined;
24245
24268
  if (reactDir && reactClientEntryPoints.length > 0) {
24246
- rmSync2(join44(buildPath, "react", "generated", "indexes"), {
24269
+ rmSync2(join45(buildPath, "react", "generated", "indexes"), {
24247
24270
  force: true,
24248
24271
  recursive: true
24249
24272
  });
24250
24273
  }
24251
24274
  if (angularDir && angularClientPaths.length > 0) {
24252
- rmSync2(join44(buildPath, "angular", "indexes"), {
24275
+ rmSync2(join45(buildPath, "angular", "indexes"), {
24253
24276
  force: true,
24254
24277
  recursive: true
24255
24278
  });
24256
24279
  }
24257
24280
  if (islandClientEntryPoints.length > 0) {
24258
- rmSync2(join44(buildPath, "islands"), {
24281
+ rmSync2(join45(buildPath, "islands"), {
24259
24282
  force: true,
24260
24283
  recursive: true
24261
24284
  });
@@ -24370,7 +24393,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24370
24393
  globalCssEntries.length > 0 ? tracePhase("bun/global-css", () => bunBuild7(mergeBunBuildConfig({
24371
24394
  entrypoints: globalCssEntries,
24372
24395
  naming: `[dir]/[name].[hash].[ext]`,
24373
- outdir: stylesDir ? join44(buildPath, basename17(stylesDir)) : buildPath,
24396
+ outdir: stylesDir ? join45(buildPath, basename17(stylesDir)) : buildPath,
24374
24397
  plugins: [stylePreprocessorPlugin2],
24375
24398
  root: stylesDir || clientRoot,
24376
24399
  target: "browser",
@@ -24379,7 +24402,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24379
24402
  vueCssPaths.length > 0 ? tracePhase("bun/vue-css", () => bunBuild7(mergeBunBuildConfig({
24380
24403
  entrypoints: vueCssPaths,
24381
24404
  naming: `[name].[hash].[ext]`,
24382
- outdir: join44(buildPath, assetsPath ? basename17(assetsPath) : "assets", "css"),
24405
+ outdir: join45(buildPath, assetsPath ? basename17(assetsPath) : "assets", "css"),
24383
24406
  target: "browser",
24384
24407
  throw: false
24385
24408
  }, resolveBunBuildOverride(bunBuildConfig, "vueCss")))) : undefined
@@ -24401,15 +24424,15 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24401
24424
  }
24402
24425
  if (!isDev2 && resolveClientSourcemap(sourcemaps, isDev2) === "external") {
24403
24426
  const { chainExternalSourcemap: chainExternalSourcemap2 } = await Promise.resolve().then(() => (init_chainInlineSourcemaps(), exports_chainInlineSourcemaps));
24404
- const sourcemapDir = join44(projectRoot, "sourcemaps");
24427
+ const sourcemapDir = join45(projectRoot, "sourcemaps");
24405
24428
  mkdirSync12(sourcemapDir, { recursive: true });
24406
24429
  const mapFiles = readdirSync7(buildPath, {
24407
24430
  encoding: "utf8",
24408
24431
  recursive: true
24409
- }).filter((entry) => entry.endsWith(".js.map") && !entry.includes("node_modules")).map((entry) => join44(buildPath, entry));
24432
+ }).filter((entry) => entry.endsWith(".js.map") && !entry.includes("node_modules")).map((entry) => join45(buildPath, entry));
24410
24433
  for (const mapPath of mapFiles) {
24411
24434
  chainExternalSourcemap2(mapPath);
24412
- renameSync(mapPath, join44(sourcemapDir, basename17(mapPath)));
24435
+ renameSync(mapPath, join45(sourcemapDir, basename17(mapPath)));
24413
24436
  const jsPath = mapPath.slice(0, -4);
24414
24437
  try {
24415
24438
  const javascript = readFileSync27(jsPath, "utf-8").replace(/\n?\/\/# sourceMappingURL=[^\n]*\s*$/, `
@@ -24417,7 +24440,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24417
24440
  writeFileSync9(jsPath, javascript);
24418
24441
  } catch {}
24419
24442
  }
24420
- console.info(`[absolute] sourcemaps: chained + privatized ${mapFiles.length} client maps \u2192 ${relative18(projectRoot, sourcemapDir)}/`);
24443
+ console.info(`[absolute] sourcemaps: chained + privatized ${mapFiles.length} client maps \u2192 ${relative19(projectRoot, sourcemapDir)}/`);
24421
24444
  }
24422
24445
  if (serverResult && !serverResult.success && serverLogs.length > 0) {
24423
24446
  handlePassFailure(serverLogs, "server", "Server");
@@ -24474,7 +24497,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24474
24497
  };
24475
24498
  await tracePhase("postprocess/client-rewrite", rewriteClientGroups, clientRewriteStats);
24476
24499
  if (!hmr) {
24477
- const reactVendorDir = join44(buildPath, "react", "vendor");
24500
+ const reactVendorDir = join45(buildPath, "react", "vendor");
24478
24501
  const vendorChunkPaths = existsSync35(reactVendorDir) ? [
24479
24502
  ...new Glob8("**/*.js").scanSync({
24480
24503
  absolute: true,
@@ -24494,7 +24517,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24494
24517
  const fileDir = dirname25(artifact.path);
24495
24518
  const relativePaths = {};
24496
24519
  for (const [specifier, absolute] of Object.entries(angularServerVendorPaths2)) {
24497
- const rel = relative18(fileDir, absolute);
24520
+ const rel = relative19(fileDir, absolute);
24498
24521
  relativePaths[specifier] = rel.startsWith(".") ? rel : `./${rel}`;
24499
24522
  }
24500
24523
  return relativePaths;
@@ -24607,7 +24630,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24607
24630
  if (skipAngularClientBundle) {
24608
24631
  for (const clientPath of angularClientPaths) {
24609
24632
  const fileBase = basename17(clientPath, ".js");
24610
- const relFromCwd = relative18(projectRoot, clientPath).replace(/\\/g, "/");
24633
+ const relFromCwd = relative19(projectRoot, clientPath).replace(/\\/g, "/");
24611
24634
  manifest[`${toPascal(fileBase)}Index`] = `/@src/${relFromCwd}`;
24612
24635
  }
24613
24636
  }
@@ -24632,7 +24655,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24632
24655
  const processHtmlPages = async () => {
24633
24656
  if (!(htmlDir && htmlPagesPath))
24634
24657
  return;
24635
- const outputHtmlPages = isSingle ? join44(buildPath, "pages") : join44(buildPath, basename17(htmlDir), "pages");
24658
+ const outputHtmlPages = isSingle ? join45(buildPath, "pages") : join45(buildPath, basename17(htmlDir), "pages");
24636
24659
  mkdirSync12(outputHtmlPages, { recursive: true });
24637
24660
  cpSync(htmlPagesPath, outputHtmlPages, {
24638
24661
  force: true,
@@ -24661,14 +24684,14 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24661
24684
  const processHtmxPages = async () => {
24662
24685
  if (!(htmxDir && htmxPagesPath))
24663
24686
  return;
24664
- const outputHtmxPages = isSingle ? join44(buildPath, "pages") : join44(buildPath, basename17(htmxDir), "pages");
24687
+ const outputHtmxPages = isSingle ? join45(buildPath, "pages") : join45(buildPath, basename17(htmxDir), "pages");
24665
24688
  mkdirSync12(outputHtmxPages, { recursive: true });
24666
24689
  cpSync(htmxPagesPath, outputHtmxPages, {
24667
24690
  force: true,
24668
24691
  recursive: true
24669
24692
  });
24670
24693
  if (shouldCopyHtmx) {
24671
- const htmxDestDir = isSingle ? buildPath : join44(buildPath, basename17(htmxDir));
24694
+ const htmxDestDir = isSingle ? buildPath : join45(buildPath, basename17(htmxDir));
24672
24695
  copyHtmxVendor(htmxDir, htmxDestDir);
24673
24696
  }
24674
24697
  if (shouldUpdateHtmxAssetPaths) {
@@ -24759,7 +24782,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24759
24782
  }))
24760
24783
  ];
24761
24784
  setSpaRouteManifest(spaRouteHosts);
24762
- writeFileSync9(join44(buildPath, "spa-routes.json"), JSON.stringify(spaRouteHosts, null, "\t"));
24785
+ writeFileSync9(join45(buildPath, "spa-routes.json"), JSON.stringify(spaRouteHosts, null, "\t"));
24763
24786
  if (isIncremental) {
24764
24787
  writeBuildTrace(buildPath);
24765
24788
  return {
@@ -24769,9 +24792,9 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
24769
24792
  pageEntries
24770
24793
  };
24771
24794
  }
24772
- writeFileSync9(join44(buildPath, "manifest.json"), JSON.stringify(manifest, null, "\t"));
24795
+ writeFileSync9(join45(buildPath, "manifest.json"), JSON.stringify(manifest, null, "\t"));
24773
24796
  if (Object.keys(conventionsMap).length > 0) {
24774
- writeFileSync9(join44(buildPath, "conventions.json"), JSON.stringify(conventionsMap, null, "\t"));
24797
+ writeFileSync9(join45(buildPath, "conventions.json"), JSON.stringify(conventionsMap, null, "\t"));
24775
24798
  }
24776
24799
  writeBuildTrace(buildPath);
24777
24800
  if (mode === "production") {
@@ -24890,7 +24913,7 @@ var init_build = __esm(() => {
24890
24913
 
24891
24914
  // src/build/buildEmberVendor.ts
24892
24915
  import { mkdirSync as mkdirSync13, existsSync as existsSync36 } from "fs";
24893
- import { join as join45 } from "path";
24916
+ import { join as join46 } from "path";
24894
24917
  import { rm as rm10 } from "fs/promises";
24895
24918
  var {build: bunBuild8 } = globalThis.Bun;
24896
24919
  var toSafeFileName5 = (specifier) => specifier.replace(/^@/, "").replace(/\//g, "_"), generateMacrosShim = () => `// Generated shim for @embroider/macros \u2014 provides minimal runtime
@@ -24942,7 +24965,7 @@ export const importSync = (specifier) => {
24942
24965
  if (standaloneSpecifiers.has(specifier)) {
24943
24966
  return { resolveTo: specifier, specifier };
24944
24967
  }
24945
- const emberInternalPath = join45(cwd2, "node_modules/ember-source/dist/packages", specifier, "index.js");
24968
+ const emberInternalPath = join46(cwd2, "node_modules/ember-source/dist/packages", specifier, "index.js");
24946
24969
  if (!existsSync36(emberInternalPath)) {
24947
24970
  throw new Error(`Ember vendor build: cannot find ${specifier} at ${emberInternalPath}. ` + `Is ember-source installed and at least 6.12?`);
24948
24971
  }
@@ -24974,7 +24997,7 @@ export const importSync = (specifier) => {
24974
24997
  if (standalonePackages.has(args.path)) {
24975
24998
  return;
24976
24999
  }
24977
- const internal = join45(cwd2, "node_modules/ember-source/dist/packages", args.path, "index.js");
25000
+ const internal = join46(cwd2, "node_modules/ember-source/dist/packages", args.path, "index.js");
24978
25001
  if (existsSync36(internal)) {
24979
25002
  return { path: internal };
24980
25003
  }
@@ -24982,16 +25005,16 @@ export const importSync = (specifier) => {
24982
25005
  });
24983
25006
  }
24984
25007
  }), buildEmberVendor = async (buildDir, cwd2 = process.cwd()) => {
24985
- const vendorDir = join45(buildDir, "ember", "vendor");
25008
+ const vendorDir = join46(buildDir, "ember", "vendor");
24986
25009
  mkdirSync13(vendorDir, { recursive: true });
24987
- const tmpDir = join45(buildDir, "_ember_vendor_tmp");
25010
+ const tmpDir = join46(buildDir, "_ember_vendor_tmp");
24988
25011
  mkdirSync13(tmpDir, { recursive: true });
24989
- const macrosShimPath = join45(tmpDir, "embroider_macros_shim.js");
25012
+ const macrosShimPath = join46(tmpDir, "embroider_macros_shim.js");
24990
25013
  await Bun.write(macrosShimPath, generateMacrosShim());
24991
25014
  const resolutions = REQUIRED_EMBER_SPECIFIERS.map((specifier) => resolveEmberSpecifier(specifier, cwd2));
24992
25015
  const entrypoints = await Promise.all(resolutions.map(async (resolution) => {
24993
25016
  const safeName = toSafeFileName5(resolution.specifier);
24994
- const entryPath = join45(tmpDir, `${safeName}.js`);
25017
+ const entryPath = join46(tmpDir, `${safeName}.js`);
24995
25018
  const source = resolution.specifier === "@embroider/macros" ? `export * from ${JSON.stringify(macrosShimPath)};
24996
25019
  ` : generateVendorEntrySource2(resolution);
24997
25020
  await Bun.write(entryPath, source);
@@ -25149,7 +25172,7 @@ __export(exports_dependencyGraph, {
25149
25172
  });
25150
25173
  import { existsSync as existsSync37, readFileSync as readFileSync28 } from "fs";
25151
25174
  var {Glob: Glob9 } = globalThis.Bun;
25152
- import { resolve as resolve32 } from "path";
25175
+ import { resolve as resolve33 } from "path";
25153
25176
  var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath) => {
25154
25177
  const lower = filePath.toLowerCase();
25155
25178
  if (lower.endsWith(".ts") || lower.endsWith(".tsx") || lower.endsWith(".jsx"))
@@ -25163,8 +25186,8 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
25163
25186
  if (!importPath.startsWith(".") && !importPath.startsWith("/")) {
25164
25187
  return null;
25165
25188
  }
25166
- const fromDir = resolve32(fromFile, "..");
25167
- const normalized = resolve32(fromDir, importPath);
25189
+ const fromDir = resolve33(fromFile, "..");
25190
+ const normalized = resolve33(fromDir, importPath);
25168
25191
  const extensions = [
25169
25192
  ".ts",
25170
25193
  ".tsx",
@@ -25194,7 +25217,7 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
25194
25217
  dependents.delete(normalizedPath);
25195
25218
  }
25196
25219
  }, addFileToGraph = (graph, filePath) => {
25197
- const normalizedPath = resolve32(filePath);
25220
+ const normalizedPath = resolve33(filePath);
25198
25221
  if (!existsSync37(normalizedPath))
25199
25222
  return;
25200
25223
  const dependencies = extractDependencies(normalizedPath);
@@ -25221,10 +25244,10 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
25221
25244
  }, IGNORED_SEGMENTS, buildInitialDependencyGraph = (graph, directories) => {
25222
25245
  const processedFiles = new Set;
25223
25246
  const glob = new Glob9("**/*.{ts,tsx,js,jsx,vue,svelte,html,htm}");
25224
- const resolvedDirs = directories.map((dir) => resolve32(dir)).filter((dir) => existsSync37(dir));
25247
+ const resolvedDirs = directories.map((dir) => resolve33(dir)).filter((dir) => existsSync37(dir));
25225
25248
  const allFiles = resolvedDirs.flatMap((dir) => Array.from(glob.scanSync({ absolute: true, cwd: dir })));
25226
25249
  for (const file5 of allFiles) {
25227
- const fullPath = resolve32(file5);
25250
+ const fullPath = resolve33(file5);
25228
25251
  if (IGNORED_SEGMENTS.some((seg) => fullPath.includes(seg)))
25229
25252
  continue;
25230
25253
  if (processedFiles.has(fullPath))
@@ -25337,7 +25360,7 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
25337
25360
  return [];
25338
25361
  }
25339
25362
  }, getAffectedFiles = (graph, changedFile) => {
25340
- const normalizedPath = resolve32(changedFile);
25363
+ const normalizedPath = resolve33(changedFile);
25341
25364
  const affected = new Set;
25342
25365
  const toProcess = [normalizedPath];
25343
25366
  const processNode = (current) => {
@@ -25368,7 +25391,7 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
25368
25391
  }, removeDependentsForFile = (graph, normalizedPath) => {
25369
25392
  graph.dependents.delete(normalizedPath);
25370
25393
  }, removeFileFromGraph = (graph, filePath) => {
25371
- const normalizedPath = resolve32(filePath);
25394
+ const normalizedPath = resolve33(filePath);
25372
25395
  removeDepsForFile(graph, normalizedPath);
25373
25396
  removeDependentsForFile(graph, normalizedPath);
25374
25397
  };
@@ -25411,12 +25434,12 @@ var globalVersionCounter = 0, createModuleVersionTracker = () => new Map, getNex
25411
25434
  };
25412
25435
 
25413
25436
  // src/dev/configResolver.ts
25414
- import { resolve as resolve33 } from "path";
25437
+ import { resolve as resolve34 } from "path";
25415
25438
  var resolveBuildPaths = (config) => {
25416
25439
  const cwd2 = process.cwd();
25417
25440
  const normalize = (path) => path.replace(/\\/g, "/");
25418
- const withDefault = (value, fallback) => normalize(resolve33(cwd2, value ?? fallback));
25419
- const optional = (value) => value ? normalize(resolve33(cwd2, value)) : undefined;
25441
+ const withDefault = (value, fallback) => normalize(resolve34(cwd2, value ?? fallback));
25442
+ const optional = (value) => value ? normalize(resolve34(cwd2, value)) : undefined;
25420
25443
  return {
25421
25444
  angularDir: optional(config.angularDirectory),
25422
25445
  assetsDir: optional(config.assetsDirectory),
@@ -25476,7 +25499,7 @@ var init_clientManager = __esm(() => {
25476
25499
 
25477
25500
  // src/dev/pathUtils.ts
25478
25501
  import { existsSync as existsSync38, readdirSync as readdirSync8, readFileSync as readFileSync29 } from "fs";
25479
- import { dirname as dirname26, resolve as resolve34 } from "path";
25502
+ import { dirname as dirname26, resolve as resolve35 } from "path";
25480
25503
  var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
25481
25504
  if (shouldIgnorePath(filePath, resolved)) {
25482
25505
  return "ignored";
@@ -25552,7 +25575,7 @@ var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
25552
25575
  return "unknown";
25553
25576
  }, collectAngularResourceDirs = (angularDir) => {
25554
25577
  const out = new Set;
25555
- const angularRoot = resolve34(angularDir);
25578
+ const angularRoot = resolve35(angularDir);
25556
25579
  const angularRootNormalized = normalizePath(angularRoot);
25557
25580
  const walk = (dir) => {
25558
25581
  let entries;
@@ -25565,7 +25588,7 @@ var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
25565
25588
  if (entry.name.startsWith(".") || entry.name === "node_modules") {
25566
25589
  continue;
25567
25590
  }
25568
- const full = resolve34(dir, entry.name);
25591
+ const full = resolve35(dir, entry.name);
25569
25592
  if (entry.isDirectory()) {
25570
25593
  walk(full);
25571
25594
  continue;
@@ -25606,7 +25629,7 @@ var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
25606
25629
  }
25607
25630
  const componentDir = dirname26(full);
25608
25631
  for (const ref of refs) {
25609
- const refAbs = normalizePath(resolve34(componentDir, ref));
25632
+ const refAbs = normalizePath(resolve35(componentDir, ref));
25610
25633
  const refDir = normalizePath(dirname26(refAbs));
25611
25634
  if (refDir === angularRootNormalized || refDir.startsWith(`${angularRootNormalized}/`)) {
25612
25635
  continue;
@@ -25623,7 +25646,7 @@ var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
25623
25646
  const push = (path) => {
25624
25647
  if (!path)
25625
25648
  return;
25626
- const abs = normalizePath(resolve34(cwd2, path));
25649
+ const abs = normalizePath(resolve35(cwd2, path));
25627
25650
  if (!roots.includes(abs))
25628
25651
  roots.push(abs);
25629
25652
  };
@@ -25648,7 +25671,7 @@ var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
25648
25671
  push(cfg.assetsDir);
25649
25672
  push(cfg.stylesDir);
25650
25673
  for (const candidate of ["src", "db", "assets", "styles"]) {
25651
- const abs = normalizePath(resolve34(cwd2, candidate));
25674
+ const abs = normalizePath(resolve35(cwd2, candidate));
25652
25675
  if (existsSync38(abs) && !roots.includes(abs))
25653
25676
  roots.push(abs);
25654
25677
  }
@@ -25659,7 +25682,7 @@ var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
25659
25682
  continue;
25660
25683
  if (entry.name.startsWith("."))
25661
25684
  continue;
25662
- const abs = normalizePath(resolve34(cwd2, entry.name));
25685
+ const abs = normalizePath(resolve35(cwd2, entry.name));
25663
25686
  if (roots.includes(abs))
25664
25687
  continue;
25665
25688
  if (shouldIgnorePath(abs, resolved))
@@ -25743,7 +25766,7 @@ var init_pathUtils = __esm(() => {
25743
25766
  // src/dev/devPrescan.ts
25744
25767
  import { existsSync as existsSync39, readdirSync as readdirSync9, rmSync as rmSync3 } from "fs";
25745
25768
  import { mkdir as mkdir11, readFile as readFile6, rename as rename3, writeFile as writeFile8 } from "fs/promises";
25746
- import { join as join46 } from "path";
25769
+ import { join as join47 } from "path";
25747
25770
  var PRESCAN_DIR, PAYLOAD_VERSION = 1, POLL_INTERVAL_MS = 10, DEFAULT_WAIT_MS = 2000, collectConfigVendorSourceDirs = (config) => Array.from(new Set([
25748
25771
  config.reactDirectory,
25749
25772
  config.svelteDirectory,
@@ -25751,8 +25774,8 @@ var PRESCAN_DIR, PAYLOAD_VERSION = 1, POLL_INTERVAL_MS = 10, DEFAULT_WAIT_MS = 2
25751
25774
  config.angularDirectory,
25752
25775
  config.htmlDirectory,
25753
25776
  config.htmxDirectory
25754
- ].filter((dir) => Boolean(dir)))), devPrescanEnabled = () => process.env.ABSOLUTE_DEV_PRESCAN === "1", sleep = (delayMs) => new Promise((resolve35) => {
25755
- setTimeout(resolve35, delayMs);
25777
+ ].filter((dir) => Boolean(dir)))), devPrescanEnabled = () => process.env.ABSOLUTE_DEV_PRESCAN === "1", sleep = (delayMs) => new Promise((resolve36) => {
25778
+ setTimeout(resolve36, delayMs);
25756
25779
  }), isPayload = (value) => typeof value === "object" && value !== null && ("version" in value) && value.version === PAYLOAD_VERSION, tryReadPrescan = async (path) => {
25757
25780
  if (!existsSync39(path))
25758
25781
  return;
@@ -25801,13 +25824,13 @@ var init_devPrescan = __esm(() => {
25801
25824
  init_configResolver();
25802
25825
  init_dependencyGraph();
25803
25826
  init_pathUtils();
25804
- PRESCAN_DIR = join46(".absolutejs", "dev-prescan");
25827
+ PRESCAN_DIR = join47(".absolutejs", "dev-prescan");
25805
25828
  });
25806
25829
 
25807
25830
  // src/dev/fileWatcher.ts
25808
25831
  import { watch } from "fs";
25809
25832
  import { existsSync as existsSync40, readdirSync as readdirSync10, statSync as statSync5 } from "fs";
25810
- import { dirname as dirname27, join as join47, resolve as resolve35 } from "path";
25833
+ import { dirname as dirname27, join as join48, resolve as resolve36 } from "path";
25811
25834
  var safeRemoveFromGraph = (graph, fullPath) => {
25812
25835
  try {
25813
25836
  removeFileFromGraph(graph, fullPath);
@@ -25839,7 +25862,7 @@ var safeRemoveFromGraph = (graph, fullPath) => {
25839
25862
  for (const name of entries) {
25840
25863
  if (shouldSkipFilename(name, isStylesDir))
25841
25864
  continue;
25842
- const child = join47(eventDir, name).replace(/\\/g, "/");
25865
+ const child = join48(eventDir, name).replace(/\\/g, "/");
25843
25866
  let st2;
25844
25867
  try {
25845
25868
  st2 = statSync5(child);
@@ -25860,7 +25883,7 @@ var safeRemoveFromGraph = (graph, fullPath) => {
25860
25883
  return;
25861
25884
  if (shouldSkipFilename(filename, isStylesDir)) {
25862
25885
  if (event === "rename") {
25863
- const eventDir = dirname27(join47(absolutePath, filename)).replace(/\\/g, "/");
25886
+ const eventDir = dirname27(join48(absolutePath, filename)).replace(/\\/g, "/");
25864
25887
  atomicRecoveryScan(eventDir);
25865
25888
  for (const delay of [25, 100]) {
25866
25889
  const timer = setTimeout(() => atomicRecoveryScan(eventDir), delay);
@@ -25869,7 +25892,7 @@ var safeRemoveFromGraph = (graph, fullPath) => {
25869
25892
  }
25870
25893
  return;
25871
25894
  }
25872
- const fullPath = join47(absolutePath, filename).replace(/\\/g, "/");
25895
+ const fullPath = join48(absolutePath, filename).replace(/\\/g, "/");
25873
25896
  if (shouldIgnorePath(fullPath, state.resolvedPaths)) {
25874
25897
  return;
25875
25898
  }
@@ -25887,7 +25910,7 @@ var safeRemoveFromGraph = (graph, fullPath) => {
25887
25910
  }, addFileWatchers = (state, paths, onFileChange) => {
25888
25911
  const stylesDir = state.resolvedPaths?.stylesDir;
25889
25912
  paths.forEach((path) => {
25890
- const absolutePath = resolve35(path).replace(/\\/g, "/");
25913
+ const absolutePath = resolve36(path).replace(/\\/g, "/");
25891
25914
  if (!existsSync40(absolutePath)) {
25892
25915
  return;
25893
25916
  }
@@ -25898,7 +25921,7 @@ var safeRemoveFromGraph = (graph, fullPath) => {
25898
25921
  const watchPaths = getWatchPaths(config, state.resolvedPaths);
25899
25922
  const stylesDir = state.resolvedPaths?.stylesDir;
25900
25923
  watchPaths.forEach((path) => {
25901
- const absolutePath = resolve35(path).replace(/\\/g, "/");
25924
+ const absolutePath = resolve36(path).replace(/\\/g, "/");
25902
25925
  if (!existsSync40(absolutePath)) {
25903
25926
  return;
25904
25927
  }
@@ -25917,13 +25940,13 @@ var init_fileWatcher = __esm(() => {
25917
25940
  });
25918
25941
 
25919
25942
  // src/dev/assetStore.ts
25920
- import { resolve as resolve36 } from "path";
25943
+ import { resolve as resolve37 } from "path";
25921
25944
  import { readdir as readdir4, unlink } from "fs/promises";
25922
25945
  var mimeTypes, getMimeType = (filePath) => {
25923
25946
  const ext = filePath.slice(filePath.lastIndexOf("."));
25924
25947
  return mimeTypes[ext] ?? "application/octet-stream";
25925
25948
  }, HASHED_FILE_RE, stripHash = (webPath) => webPath.replace(/\.[a-z0-9]{8}(\.(js|css|mjs))$/, "$1"), processWalkEntry = (entry, dir, liveByIdentity, walkAndClean) => {
25926
- const fullPath = resolve36(dir, entry.name);
25949
+ const fullPath = resolve37(dir, entry.name);
25927
25950
  if (entry.isDirectory()) {
25928
25951
  return walkAndClean(fullPath);
25929
25952
  }
@@ -25939,10 +25962,10 @@ var mimeTypes, getMimeType = (filePath) => {
25939
25962
  }, cleanStaleAssets = async (store, manifest, buildDir) => {
25940
25963
  const liveByIdentity = new Map;
25941
25964
  for (const webPath of store.keys()) {
25942
- const diskPath = resolve36(buildDir, webPath.slice(1));
25965
+ const diskPath = resolve37(buildDir, webPath.slice(1));
25943
25966
  liveByIdentity.set(stripHash(diskPath), diskPath);
25944
25967
  }
25945
- const absBuildDir = resolve36(buildDir);
25968
+ const absBuildDir = resolve37(buildDir);
25946
25969
  Object.values(manifest).forEach((val) => {
25947
25970
  if (!HASHED_FILE_RE.test(val))
25948
25971
  return;
@@ -25962,13 +25985,13 @@ var mimeTypes, getMimeType = (filePath) => {
25962
25985
  }, evictMissingChunks = async (store, buildDir) => {
25963
25986
  const chunkKeys = [...store.keys()].filter((webPath) => webPath.includes("/chunk-"));
25964
25987
  await Promise.all(chunkKeys.map(async (webPath) => {
25965
- const onDisk = await Bun.file(resolve36(buildDir, webPath.slice(1))).exists().catch(() => false);
25988
+ const onDisk = await Bun.file(resolve37(buildDir, webPath.slice(1))).exists().catch(() => false);
25966
25989
  if (!onDisk)
25967
25990
  store.delete(webPath);
25968
25991
  }));
25969
25992
  }, lookupAsset = (store, path) => store.get(path), processScanEntry = (entry, dir, prefix, store, scanDir) => {
25970
25993
  if (entry.isDirectory()) {
25971
- return scanDir(resolve36(dir, entry.name), `${prefix}${entry.name}/`);
25994
+ return scanDir(resolve37(dir, entry.name), `${prefix}${entry.name}/`);
25972
25995
  }
25973
25996
  if (!entry.name.startsWith("chunk-")) {
25974
25997
  return null;
@@ -25977,7 +26000,7 @@ var mimeTypes, getMimeType = (filePath) => {
25977
26000
  if (store.has(webPath)) {
25978
26001
  return null;
25979
26002
  }
25980
- return Bun.file(resolve36(dir, entry.name)).bytes().then((bytes) => {
26003
+ return Bun.file(resolve37(dir, entry.name)).bytes().then((bytes) => {
25981
26004
  store.set(webPath, bytes);
25982
26005
  return;
25983
26006
  }).catch(() => {});
@@ -25999,7 +26022,7 @@ var mimeTypes, getMimeType = (filePath) => {
25999
26022
  for (const webPath of newIdentities.values()) {
26000
26023
  if (store.has(webPath))
26001
26024
  continue;
26002
- loadPromises.push(Bun.file(resolve36(buildDir, webPath.slice(1))).bytes().then((bytes) => {
26025
+ loadPromises.push(Bun.file(resolve37(buildDir, webPath.slice(1))).bytes().then((bytes) => {
26003
26026
  store.set(webPath, bytes);
26004
26027
  return;
26005
26028
  }).catch(() => {}));
@@ -26045,7 +26068,7 @@ var init_assetStore = __esm(() => {
26045
26068
 
26046
26069
  // src/islands/pageMetadata.ts
26047
26070
  import { readFileSync as readFileSync30 } from "fs";
26048
- import { dirname as dirname28, resolve as resolve37 } from "path";
26071
+ import { dirname as dirname28, resolve as resolve38 } from "path";
26049
26072
  var pagePatterns, getPageDirs = (config) => [
26050
26073
  { dir: config.angularDirectory, framework: "angular" },
26051
26074
  { dir: config.emberDirectory, framework: "ember" },
@@ -26065,15 +26088,15 @@ var pagePatterns, getPageDirs = (config) => [
26065
26088
  const source = definition.buildReference?.source;
26066
26089
  if (!source)
26067
26090
  continue;
26068
- const resolvedSource = source.startsWith("file://") ? new URL(source).pathname : resolve37(dirname28(buildInfo.resolvedRegistryPath), source);
26069
- lookup.set(`${definition.framework}:${definition.component}`, resolve37(resolvedSource));
26091
+ const resolvedSource = source.startsWith("file://") ? new URL(source).pathname : resolve38(dirname28(buildInfo.resolvedRegistryPath), source);
26092
+ lookup.set(`${definition.framework}:${definition.component}`, resolve38(resolvedSource));
26070
26093
  }
26071
26094
  return lookup;
26072
26095
  }, getCurrentPageIslandMetadata = () => globalThis.__absolutePageIslandMetadata ?? new Map, metadataUsesSource = (metadata, target) => metadata.islands.some((usage) => {
26073
26096
  const candidate = usage.source;
26074
- return candidate ? resolve37(candidate) === target : false;
26097
+ return candidate ? resolve38(candidate) === target : false;
26075
26098
  }), getPagesUsingIslandSource = (sourcePath) => {
26076
- const target = resolve37(sourcePath);
26099
+ const target = resolve38(sourcePath);
26077
26100
  return [...getCurrentPageIslandMetadata().values()].filter((metadata) => metadataUsesSource(metadata, target)).map((metadata) => metadata.pagePath);
26078
26101
  }, resolveIslandUsages = (islands, islandSourceLookup) => islands.map((usage) => {
26079
26102
  const sourcePath = islandSourceLookup.get(`${usage.framework}:${usage.component}`);
@@ -26085,13 +26108,13 @@ var pagePatterns, getPageDirs = (config) => [
26085
26108
  const pattern = pagePatterns[entry.framework];
26086
26109
  if (!pattern)
26087
26110
  return;
26088
- const files = await scanEntryPoints(resolve37(entry.dir), pattern);
26111
+ const files = await scanEntryPoints(resolve38(entry.dir), pattern);
26089
26112
  for (const filePath of files) {
26090
26113
  const source = readFileSync30(filePath, "utf-8");
26091
26114
  const islands = extractIslandUsagesFromSource(source);
26092
- pageMetadata.set(resolve37(filePath), {
26115
+ pageMetadata.set(resolve38(filePath), {
26093
26116
  islands: resolveIslandUsages(islands, islandSourceLookup),
26094
- pagePath: resolve37(filePath)
26117
+ pagePath: resolve38(filePath)
26095
26118
  });
26096
26119
  }
26097
26120
  }, loadPageIslandMetadata = async (config) => {
@@ -26214,9 +26237,9 @@ var init_transformCache = __esm(() => {
26214
26237
  });
26215
26238
 
26216
26239
  // src/dev/reactComponentClassifier.ts
26217
- import { resolve as resolve38 } from "path";
26240
+ import { resolve as resolve39 } from "path";
26218
26241
  var classifyComponent = (filePath) => {
26219
- const normalizedPath = resolve38(filePath);
26242
+ const normalizedPath = resolve39(filePath);
26220
26243
  if (normalizedPath.includes("/react/pages/")) {
26221
26244
  return "server";
26222
26245
  }
@@ -26228,7 +26251,7 @@ var classifyComponent = (filePath) => {
26228
26251
  var init_reactComponentClassifier = () => {};
26229
26252
 
26230
26253
  // src/dev/moduleMapper.ts
26231
- import { basename as basename18, resolve as resolve39 } from "path";
26254
+ import { basename as basename18, resolve as resolve40 } from "path";
26232
26255
  var buildModulePaths = (moduleKeys, manifest) => {
26233
26256
  const modulePaths = {};
26234
26257
  moduleKeys.forEach((key) => {
@@ -26238,7 +26261,7 @@ var buildModulePaths = (moduleKeys, manifest) => {
26238
26261
  });
26239
26262
  return modulePaths;
26240
26263
  }, processChangedFile = (sourceFile, framework, manifest, resolvedPaths, processedFiles) => {
26241
- const normalizedFile = resolve39(sourceFile);
26264
+ const normalizedFile = resolve40(sourceFile);
26242
26265
  const normalizedPath = normalizedFile.replace(/\\/g, "/");
26243
26266
  if (processedFiles.has(normalizedFile)) {
26244
26267
  return null;
@@ -26274,7 +26297,7 @@ var buildModulePaths = (moduleKeys, manifest) => {
26274
26297
  });
26275
26298
  return grouped;
26276
26299
  }, mapSourceFileToManifestKeys = (sourceFile, framework, resolvedPaths) => {
26277
- const normalizedFile = resolve39(sourceFile);
26300
+ const normalizedFile = resolve40(sourceFile);
26278
26301
  const fileName = basename18(normalizedFile);
26279
26302
  const baseName = fileName.replace(/\.(tsx?|jsx?|vue|svelte|css|html)$/, "");
26280
26303
  const pascalName = toPascal(baseName);
@@ -26330,7 +26353,7 @@ var init_moduleMapper = __esm(() => {
26330
26353
 
26331
26354
  // src/utils/spaRouteCss.ts
26332
26355
  import { readFile as readFile7 } from "fs/promises";
26333
- import { dirname as dirname29, isAbsolute as isAbsolute7, resolve as resolve40 } from "path";
26356
+ import { dirname as dirname29, isAbsolute as isAbsolute8, resolve as resolve41 } from "path";
26334
26357
  var sideManifestCache, readSideManifest = async (sideManifestPath) => {
26335
26358
  const cached = sideManifestCache.get(sideManifestPath);
26336
26359
  if (cached !== undefined)
@@ -26368,7 +26391,7 @@ var sideManifestCache, readSideManifest = async (sideManifestPath) => {
26368
26391
  }, readChildCss = async (cssPath, sideManifestPath) => {
26369
26392
  if (!cssPath)
26370
26393
  return "";
26371
- const resolvedCssPath = isAbsolute7(cssPath) ? cssPath : resolve40(dirname29(sideManifestPath), cssPath);
26394
+ const resolvedCssPath = isAbsolute8(cssPath) ? cssPath : resolve41(dirname29(sideManifestPath), cssPath);
26372
26395
  const cached = childCssCache.get(resolvedCssPath);
26373
26396
  if (cached !== undefined)
26374
26397
  return cached;
@@ -26452,7 +26475,7 @@ __export(exports_resolveOwningComponents, {
26452
26475
  resolveOwningComponents: () => resolveOwningComponents
26453
26476
  });
26454
26477
  import { readdirSync as readdirSync11, readFileSync as readFileSync32, statSync as statSync6 } from "fs";
26455
- import { dirname as dirname30, extname as extname14, join as join48, resolve as resolve41 } from "path";
26478
+ import { dirname as dirname30, extname as extname14, join as join49, resolve as resolve42 } from "path";
26456
26479
  import ts19 from "typescript";
26457
26480
  var ENTITY_DECORATORS, isAngularSourceFile = (file5) => file5.endsWith(".ts") || file5.endsWith(".tsx"), walkAngularSourceFiles = (root) => {
26458
26481
  const out = [];
@@ -26467,7 +26490,7 @@ var ENTITY_DECORATORS, isAngularSourceFile = (file5) => file5.endsWith(".ts") ||
26467
26490
  if (entry.name.startsWith(".") || entry.name === "node_modules") {
26468
26491
  continue;
26469
26492
  }
26470
- const full = join48(dir, entry.name);
26493
+ const full = join49(dir, entry.name);
26471
26494
  if (entry.isDirectory()) {
26472
26495
  visit(full);
26473
26496
  } else if (entry.isFile() && isAngularSourceFile(entry.name)) {
@@ -26565,7 +26588,7 @@ var ENTITY_DECORATORS, isAngularSourceFile = (file5) => file5.endsWith(".ts") ||
26565
26588
  };
26566
26589
  visit(sourceFile);
26567
26590
  return out;
26568
- }, safeNormalize = (path) => resolve41(path).replace(/\\/g, "/"), resolveOwningComponents = (params) => {
26591
+ }, safeNormalize = (path) => resolve42(path).replace(/\\/g, "/"), resolveOwningComponents = (params) => {
26569
26592
  const { changedFilePath, userAngularRoot } = params;
26570
26593
  const changedAbs = safeNormalize(changedFilePath);
26571
26594
  const out = [];
@@ -26634,7 +26657,7 @@ var ENTITY_DECORATORS, isAngularSourceFile = (file5) => file5.endsWith(".ts") ||
26634
26657
  if (!spec.startsWith(".") && !spec.startsWith("/")) {
26635
26658
  return null;
26636
26659
  }
26637
- const base = resolve41(childDir, spec);
26660
+ const base = resolve42(childDir, spec);
26638
26661
  const candidates = [
26639
26662
  `${base}.ts`,
26640
26663
  `${base}.tsx`,
@@ -26672,7 +26695,7 @@ var ENTITY_DECORATORS, isAngularSourceFile = (file5) => file5.endsWith(".ts") ||
26672
26695
  };
26673
26696
  if (cls.kind === "component") {
26674
26697
  for (const url of [...cls.templateUrls, ...cls.styleUrls]) {
26675
- const abs = safeNormalize(resolve41(componentDir, url));
26698
+ const abs = safeNormalize(resolve42(componentDir, url));
26676
26699
  const existing = resource.get(abs);
26677
26700
  if (existing)
26678
26701
  existing.push(entity);
@@ -26938,7 +26961,7 @@ __export(exports_loadConfig, {
26938
26961
  loadConfig: () => loadConfig,
26939
26962
  loadRawConfig: () => loadRawConfig
26940
26963
  });
26941
- import { resolve as resolve42 } from "path";
26964
+ import { resolve as resolve43 } from "path";
26942
26965
  var RESERVED_TOP_LEVEL_KEYS, isObject2 = (value) => typeof value === "object" && value !== null, isCommandService = (service) => service.kind === "command" || Array.isArray(service.command), isServiceCandidate = (value) => isObject2(value) && (typeof value.entry === "string" || Array.isArray(value.command)), isWorkspaceConfig = (config) => {
26943
26966
  if (!isObject2(config)) {
26944
26967
  return false;
@@ -26989,7 +27012,7 @@ var RESERVED_TOP_LEVEL_KEYS, isObject2 = (value) => typeof value === "object" &&
26989
27012
  }
26990
27013
  return config;
26991
27014
  }, loadRawConfig = async (configPath2) => {
26992
- const resolved = resolve42(configPath2 ?? process.env.ABSOLUTE_CONFIG ?? "absolute.config.ts");
27015
+ const resolved = resolve43(configPath2 ?? process.env.ABSOLUTE_CONFIG ?? "absolute.config.ts");
26993
27016
  const mod = await import(resolved);
26994
27017
  const config = mod.default ?? mod.config;
26995
27018
  if (!config) {
@@ -27041,9 +27064,9 @@ var init_loadConfig = __esm(() => {
27041
27064
 
27042
27065
  // src/plugins/openApiPlugin.ts
27043
27066
  import { existsSync as existsSync41, readFileSync as readFileSync33 } from "fs";
27044
- import { join as join49 } from "path";
27067
+ import { join as join50 } from "path";
27045
27068
  var FALLBACK_NAME = "AbsoluteJS API", FALLBACK_VERSION = "1.0.0", projectInfo = (cwd2) => {
27046
- const path = join49(cwd2, "package.json");
27069
+ const path = join50(cwd2, "package.json");
27047
27070
  if (!existsSync41(path)) {
27048
27071
  return { name: FALLBACK_NAME, version: FALLBACK_VERSION };
27049
27072
  }
@@ -27098,9 +27121,9 @@ var init_openApiPlugin = () => {};
27098
27121
 
27099
27122
  // src/plugins/telemetryPlugin.ts
27100
27123
  import { existsSync as existsSync42, readFileSync as readFileSync34 } from "fs";
27101
- import { join as join50 } from "path";
27124
+ import { join as join51 } from "path";
27102
27125
  var OTEL_PACKAGE = "@elysia/opentelemetry", readPackageName = (cwd2) => {
27103
- const path = join50(cwd2, "package.json");
27126
+ const path = join51(cwd2, "package.json");
27104
27127
  if (!existsSync42(path))
27105
27128
  return null;
27106
27129
  try {
@@ -27415,7 +27438,7 @@ var init_requestContext = __esm(() => {
27415
27438
  });
27416
27439
 
27417
27440
  // src/core/loadIslandRegistry.ts
27418
- import { resolve as resolve43 } from "path";
27441
+ import { resolve as resolve44 } from "path";
27419
27442
  var isRecord6 = (value) => typeof value === "object" && value !== null, resolveRegistryExport2 = (mod) => {
27420
27443
  if (isRecord6(mod.islandRegistry))
27421
27444
  return mod.islandRegistry;
@@ -27423,7 +27446,7 @@ var isRecord6 = (value) => typeof value === "object" && value !== null, resolveR
27423
27446
  return mod.default;
27424
27447
  throw new Error("Island registry module must export `islandRegistry` or a default registry object.");
27425
27448
  }, isRegistryModuleExport = (value) => isRecord6(value), isIslandRegistryInput = (value) => isRecord6(value), loadIslandRegistry = async (registryPath) => {
27426
- const resolvedRegistryPath = resolve43(registryPath);
27449
+ const resolvedRegistryPath = resolve44(registryPath);
27427
27450
  const buildInfo = await loadIslandRegistryBuildInfo(resolvedRegistryPath);
27428
27451
  if (buildInfo.definitions.length > 0) {
27429
27452
  return buildInfo.registry;
@@ -27540,8 +27563,8 @@ var DEFAULT_BATCH_SIZE = 12, DEFAULT_POLL_MS = 25, DEFAULT_MAX_PAUSE_MS = 2000,
27540
27563
  batch.push(next.value);
27541
27564
  }
27542
27565
  return batch;
27543
- }, defaultSleep = (delayMs) => new Promise((resolve44) => {
27544
- const timer = setTimeout(resolve44, delayMs);
27566
+ }, defaultSleep = (delayMs) => new Promise((resolve45) => {
27567
+ const timer = setTimeout(resolve45, delayMs);
27545
27568
  unrefTimer(timer);
27546
27569
  }), dependencyOrderedSequence = function* (files, getEntrySources, getDependencies) {
27547
27570
  const remaining = new Set(files);
@@ -27631,11 +27654,11 @@ __export(exports_config, {
27631
27654
  normalizeAbsoluteMobileConfig: () => normalizeAbsoluteMobileConfig
27632
27655
  });
27633
27656
  import { readFileSync as readFileSync35 } from "fs";
27634
- import { resolve as resolve44 } from "path";
27657
+ import { resolve as resolve45 } from "path";
27635
27658
  import { createHash as createHash5, createPublicKey, X509Certificate } from "crypto";
27636
- var APP_ID_PATTERN, SCHEME_PATTERN, APPLE_APP_ID_PREFIX_PATTERN, CERTIFICATE_FINGERPRINT_PATTERN, UPDATE_NAME_PATTERN, UPDATE_PUBLIC_KEY_PATTERN, ENVIRONMENT_NAME_PATTERN, DEFAULT_UPDATE_BOOT_TIMEOUT_MS = 20000, DEFAULT_UPDATE_HEALTH_FAILURE_RATE = 0.2, DEFAULT_UPDATE_HEALTH_MINIMUM_REPORTS = 20, DEFAULT_UPDATE_ROLLOUT_FAILURE_RATE = 0.05, DEFAULT_UPDATE_ROLLOUT_OBSERVATION_MINUTES = 60, MINUTE_MS, DEFAULT_UPDATE_ROLLOUT_STAGES, MINIMUM_UPDATE_BOOT_TIMEOUT_MS = 5000, MAXIMUM_UPDATE_BOOT_TIMEOUT_MS = 120000, HOSTNAME_PATTERN, EXPO_RESERVED_ROUTE_PREFIXES, resolveProjectPath = (projectRoot, value, field) => {
27637
- const root = resolve44(projectRoot);
27638
- const path = resolve44(root, value);
27659
+ var APP_ID_PATTERN, SCHEME_PATTERN, APPLE_APP_ID_PREFIX_PATTERN, CERTIFICATE_FINGERPRINT_PATTERN, UPDATE_NAME_PATTERN, RELEASE_TARGET_PATTERN, UPDATE_PUBLIC_KEY_PATTERN, ENVIRONMENT_NAME_PATTERN, DEFAULT_UPDATE_BOOT_TIMEOUT_MS = 20000, DEFAULT_UPDATE_HEALTH_FAILURE_RATE = 0.2, DEFAULT_UPDATE_HEALTH_MINIMUM_REPORTS = 20, DEFAULT_UPDATE_ROLLOUT_FAILURE_RATE = 0.05, DEFAULT_UPDATE_ROLLOUT_OBSERVATION_MINUTES = 60, MINUTE_MS, DEFAULT_UPDATE_ROLLOUT_STAGES, MINIMUM_UPDATE_BOOT_TIMEOUT_MS = 5000, MAXIMUM_UPDATE_BOOT_TIMEOUT_MS = 120000, HOSTNAME_PATTERN, EXPO_RESERVED_ROUTE_PREFIXES, resolveProjectPath = (projectRoot, value, field) => {
27660
+ const root = resolve45(projectRoot);
27661
+ const path = resolve45(root, value);
27639
27662
  if (path !== root && !path.startsWith(`${root}/`)) {
27640
27663
  throw new TypeError(`${field} must remain inside the project root.`);
27641
27664
  }
@@ -27669,6 +27692,54 @@ var APP_ID_PATTERN, SCHEME_PATTERN, APPLE_APP_ID_PREFIX_PATTERN, CERTIFICATE_FIN
27669
27692
  throw new TypeError("mobile.platforms must contain at least one platform.");
27670
27693
  }
27671
27694
  return normalized;
27695
+ }, normalizeAndroidCertificationPolicy = (value) => {
27696
+ if (value === false || value === undefined)
27697
+ return;
27698
+ if (value !== "installed")
27699
+ throw new TypeError("mobile.release.certification channel Android policy must be installed or false.");
27700
+ return value;
27701
+ }, normalizeIosCertificationPolicy = (value) => {
27702
+ if (value === false || value === undefined)
27703
+ return;
27704
+ if (!["simulator", "device", "store"].includes(value))
27705
+ throw new TypeError("mobile.release.certification channel iOS policy must be simulator, device, store, or false.");
27706
+ return value;
27707
+ }, normalizeReleaseCertification = (config) => {
27708
+ const configured = config.release?.certification;
27709
+ if (configured === false)
27710
+ return { channels: {}, googlePlayTracks: {} };
27711
+ const channels = {
27712
+ production: { android: "installed", ios: "store" }
27713
+ };
27714
+ const googlePlayTracks = {
27715
+ production: "installed"
27716
+ };
27717
+ for (const [name, policy] of Object.entries(configured?.channels ?? {})) {
27718
+ if (!RELEASE_TARGET_PATTERN.test(name))
27719
+ throw new TypeError("mobile.release.certification.channels contains an invalid channel.");
27720
+ const normalized = {};
27721
+ const android = normalizeAndroidCertificationPolicy(policy.android);
27722
+ const ios = normalizeIosCertificationPolicy(policy.ios);
27723
+ if (android)
27724
+ normalized.android = android;
27725
+ if (ios)
27726
+ normalized.ios = ios;
27727
+ channels[name] = normalized;
27728
+ }
27729
+ for (const [name, requirement] of Object.entries(configured?.googlePlayTracks ?? {})) {
27730
+ if (!RELEASE_TARGET_PATTERN.test(name))
27731
+ throw new TypeError("mobile.release.certification.googlePlayTracks contains an invalid track.");
27732
+ if (requirement === false)
27733
+ delete googlePlayTracks[name];
27734
+ else if (requirement === "installed")
27735
+ googlePlayTracks[name] = requirement;
27736
+ else
27737
+ throw new TypeError("mobile.release.certification Google Play policy must be installed or false.");
27738
+ }
27739
+ return {
27740
+ channels: Object.fromEntries(Object.entries(channels).sort(([left], [right]) => left.localeCompare(right))),
27741
+ googlePlayTracks: Object.fromEntries(Object.entries(googlePlayTracks).sort(([left], [right]) => left.localeCompare(right)))
27742
+ };
27672
27743
  }, normalizeHosts = (hosts, productionOrigin) => {
27673
27744
  const normalizeHostname = (host2) => {
27674
27745
  const value = requireText(host2, "mobile.deepLinks.hosts").toLowerCase();
@@ -27995,6 +28066,7 @@ var APP_ID_PATTERN, SCHEME_PATTERN, APPLE_APP_ID_PREFIX_PATTERN, CERTIFICATE_FIN
27995
28066
  platforms: normalizePlatforms(config.platforms),
27996
28067
  productionOrigin,
27997
28068
  pushAndroidGoogleServicesFile: resolveProjectPath(projectRoot, config.pushNotifications?.android?.googleServicesFile ?? "google-services.json", "mobile.pushNotifications.android.googleServicesFile"),
28069
+ releaseCertification: normalizeReleaseCertification(config),
27998
28070
  ...updates ? { updates } : {},
27999
28071
  ...updateServer ? { updateServer } : {}
28000
28072
  };
@@ -28005,6 +28077,7 @@ var init_config = __esm(() => {
28005
28077
  APPLE_APP_ID_PREFIX_PATTERN = /^[A-Z0-9]{10}$/;
28006
28078
  CERTIFICATE_FINGERPRINT_PATTERN = /^[0-9A-F]{64}$/;
28007
28079
  UPDATE_NAME_PATTERN = /^[A-Za-z0-9][A-Za-z0-9._-]{0,63}$/u;
28080
+ RELEASE_TARGET_PATTERN = /^[a-z0-9][a-z0-9._-]{0,63}$/u;
28008
28081
  UPDATE_PUBLIC_KEY_PATTERN = /^[A-Za-z0-9+/]+={0,2}$/u;
28009
28082
  ENVIRONMENT_NAME_PATTERN = /^[A-Za-z_][A-Za-z0-9_]*$/u;
28010
28083
  MINUTE_MS = 60 * 1000;
@@ -28044,7 +28117,7 @@ import {
28044
28117
  rm as rm11,
28045
28118
  writeFile as writeFile9
28046
28119
  } from "fs/promises";
28047
- import { resolve as resolve45 } from "path";
28120
+ import { resolve as resolve46 } from "path";
28048
28121
  import { Elysia as Elysia3 } from "elysia";
28049
28122
  var JSON_HEADERS, OWNERSHIP_FILE = ".absolutejs-mobile-associations.json", HTTP_OK = 200, VERIFY_TIMEOUT_MS = 1e4, ANDROID_ASSOCIATION_PATH = "/.well-known/assetlinks.json", APPLE_ASSOCIATION_PATH = "/.well-known/apple-app-site-association", missingIdentity = (field, platform2) => new TypeError(`${field} is required to publish ${platform2} deep-link association files.`), createAppleDocument = (config, requireAll) => {
28050
28123
  if (!config.platforms.includes("ios"))
@@ -28131,7 +28204,7 @@ var JSON_HEADERS, OWNERSHIP_FILE = ".absolutejs-mobile-associations.json", HTTP_
28131
28204
  return false;
28132
28205
  }
28133
28206
  }, assertOwnedOutput = async (root) => {
28134
- const path = resolve45(root, OWNERSHIP_FILE);
28207
+ const path = resolve46(root, OWNERSHIP_FILE);
28135
28208
  let ownership;
28136
28209
  try {
28137
28210
  ownership = JSON.parse(await readFile8(path, "utf8"));
@@ -28158,10 +28231,10 @@ var JSON_HEADERS, OWNERSHIP_FILE = ".absolutejs-mobile-associations.json", HTTP_
28158
28231
  if (hasCurrent)
28159
28232
  await rm11(backup, { force: true, recursive: true });
28160
28233
  }, materializeHost = async (root, host2, files) => {
28161
- const directory = resolve45(root, host2, ".well-known");
28234
+ const directory = resolve46(root, host2, ".well-known");
28162
28235
  await mkdir12(directory, { recursive: true });
28163
28236
  return Promise.all(files.map(async ([name, document2]) => {
28164
- const path = resolve45(directory, name);
28237
+ const path = resolve46(directory, name);
28165
28238
  await writeAtomic(path, `${JSON.stringify(document2, null, 2)}
28166
28239
  `);
28167
28240
  return path;
@@ -28184,7 +28257,7 @@ var JSON_HEADERS, OWNERSHIP_FILE = ".absolutejs-mobile-associations.json", HTTP_
28184
28257
  });
28185
28258
  return endpoints;
28186
28259
  }), materializeAbsoluteMobileAssociationFiles = async (config, outputDirectory) => {
28187
- const root = resolve45(outputDirectory);
28260
+ const root = resolve46(outputDirectory);
28188
28261
  const temporary = `${root}.${crypto.randomUUID()}.tmp`;
28189
28262
  const documents = createAbsoluteMobileAssociationDocuments(config, {
28190
28263
  requireAll: true
@@ -28198,10 +28271,10 @@ var JSON_HEADERS, OWNERSHIP_FILE = ".absolutejs-mobile-associations.json", HTTP_
28198
28271
  await mkdir12(temporary, { recursive: true });
28199
28272
  try {
28200
28273
  const temporaryPaths = (await Promise.all(config.deepLinkHosts.map((host2) => materializeHost(temporary, host2, files)))).flat();
28201
- await writeAtomic(resolve45(temporary, OWNERSHIP_FILE), `${JSON.stringify({ format: 1, hosts: config.deepLinkHosts }, null, 2)}
28274
+ await writeAtomic(resolve46(temporary, OWNERSHIP_FILE), `${JSON.stringify({ format: 1, hosts: config.deepLinkHosts }, null, 2)}
28202
28275
  `);
28203
28276
  await publishGeneratedDirectory(temporary, root);
28204
- const written = temporaryPaths.map((path) => resolve45(root, path.slice(temporary.length + 1)));
28277
+ const written = temporaryPaths.map((path) => resolve46(root, path.slice(temporary.length + 1)));
28205
28278
  return { root, written };
28206
28279
  } catch (error) {
28207
28280
  await rm11(temporary, { force: true, recursive: true });
@@ -28322,10 +28395,10 @@ var init_mobilePreview = __esm(() => {
28322
28395
 
28323
28396
  // src/mobile/nativeAuth.ts
28324
28397
  import { readFileSync as readFileSync36 } from "fs";
28325
- import { join as join51 } from "path";
28398
+ import { join as join52 } from "path";
28326
28399
  var ABSOLUTE_AUTH_PACKAGE = "@absolutejs/auth", ABSOLUTE_EXPO_AUTH_CORE_VERSION = "0.76.3", ABSOLUTE_EXPO_AUTH_PACKAGE = "@absolutejs/auth-expo", ABSOLUTE_EXPO_AUTH_VERSION = "0.0.6", ABSOLUTE_EXPO_SYNC_CORE_VERSION = "2.31.0", ABSOLUTE_EXPO_SYNC_PACKAGE = "@absolutejs/sync-expo", ABSOLUTE_EXPO_SYNC_VERSION = "0.0.4", ABSOLUTE_NATIVE_AUTH_CLIENTS_ENV = "ABSOLUTE_AUTH_NATIVE_CLIENTS", ABSOLUTE_NATIVE_AUTH_SCOPES, ABSOLUTE_SYNC_PACKAGE = "@absolutejs/sync", readPackageManifest = (projectRoot) => {
28327
28400
  try {
28328
- return JSON.parse(readFileSync36(join51(projectRoot, "package.json"), "utf8"));
28401
+ return JSON.parse(readFileSync36(join52(projectRoot, "package.json"), "utf8"));
28329
28402
  } catch {
28330
28403
  return;
28331
28404
  }
@@ -28371,7 +28444,7 @@ __export(exports_devDeviceAdapter, {
28371
28444
  buildAbsoluteNativeDevAdapter: () => buildAbsoluteNativeDevAdapter
28372
28445
  });
28373
28446
  import { access as access2, mkdtemp, rm as rm12, writeFile as writeFile10 } from "fs/promises";
28374
- import { join as join52 } from "path";
28447
+ import { join as join53 } from "path";
28375
28448
  import { tmpdir } from "os";
28376
28449
  var absoluteNativeDevAdapterSource = (projectRoot, mobile, resolveModule = (specifier) => specifier, expoAdapterModule = "@absolutejs/absolute/mobile/expo-devices", expoAuthModule = "@absolutejs/absolute/mobile/expo-auth", expoSyncModule = "@absolutejs/absolute/mobile/expo-sync") => {
28377
28450
  if ((mobile.engine ?? "capacitor") === "expo") {
@@ -28409,7 +28482,7 @@ ${auth ? `void createAbsoluteExpoShellAuth(${JSON.stringify(auth)}).then(auth =>
28409
28482
  `);
28410
28483
  }, expoAdapterPath = async () => {
28411
28484
  const candidates = await Promise.all(["ts", "js"].map(async (extension) => {
28412
- const path2 = join52(import.meta.dir, `shellExpoDevices.${extension}`);
28485
+ const path2 = join53(import.meta.dir, `shellExpoDevices.${extension}`);
28413
28486
  try {
28414
28487
  await access2(path2);
28415
28488
  return path2;
@@ -28423,7 +28496,7 @@ ${auth ? `void createAbsoluteExpoShellAuth(${JSON.stringify(auth)}).then(auth =>
28423
28496
  throw new TypeError("The AbsoluteJS Expo development adapter is missing.");
28424
28497
  }, expoAuthPath = async () => {
28425
28498
  const candidates = await Promise.all(["ts", "js"].map(async (extension) => {
28426
- const path2 = join52(import.meta.dir, `shellExpoAuth.${extension}`);
28499
+ const path2 = join53(import.meta.dir, `shellExpoAuth.${extension}`);
28427
28500
  try {
28428
28501
  await access2(path2);
28429
28502
  return path2;
@@ -28437,7 +28510,7 @@ ${auth ? `void createAbsoluteExpoShellAuth(${JSON.stringify(auth)}).then(auth =>
28437
28510
  throw new TypeError("The AbsoluteJS Expo Auth development adapter is missing.");
28438
28511
  }, expoSyncPath = async () => {
28439
28512
  const candidates = await Promise.all(["ts", "js"].map(async (extension) => {
28440
- const path2 = join52(import.meta.dir, `shellExpoSync.${extension}`);
28513
+ const path2 = join53(import.meta.dir, `shellExpoSync.${extension}`);
28441
28514
  try {
28442
28515
  await access2(path2);
28443
28516
  return path2;
@@ -28450,8 +28523,8 @@ ${auth ? `void createAbsoluteExpoShellAuth(${JSON.stringify(auth)}).then(auth =>
28450
28523
  return path;
28451
28524
  throw new TypeError("The AbsoluteJS Expo Sync development adapter is missing.");
28452
28525
  }, buildAbsoluteNativeDevAdapter = async (projectRoot, mobile) => {
28453
- const temporaryDirectory = await mkdtemp(join52(tmpdir(), "absolutejs-native-dev-adapter-"));
28454
- const entry = join52(temporaryDirectory, "entry.ts");
28526
+ const temporaryDirectory = await mkdtemp(join53(tmpdir(), "absolutejs-native-dev-adapter-"));
28527
+ const entry = join53(temporaryDirectory, "entry.ts");
28455
28528
  try {
28456
28529
  await writeFile10(entry, absoluteNativeDevAdapterSource(projectRoot, mobile, (specifier) => Bun.resolveSync(specifier, projectRoot), await expoAdapterPath(), await expoAuthPath(), await expoSyncPath()));
28457
28530
  const result = await Bun.build({
@@ -28483,11 +28556,11 @@ __export(exports_mobilePreviewClientBundle, {
28483
28556
  resolveAbsoluteMobilePreviewClientEntry: () => resolveAbsoluteMobilePreviewClientEntry
28484
28557
  });
28485
28558
  import { access as access3 } from "fs/promises";
28486
- import { join as join53 } from "path";
28559
+ import { join as join54 } from "path";
28487
28560
  var PREVIEW_CLIENT_FILE = "mobilePreviewClient.ts", fileExists = (path) => access3(path).then(() => true, () => false), resolveAbsoluteMobilePreviewClientEntry = async () => {
28488
28561
  const candidates = [
28489
- join53(import.meta.dir, PREVIEW_CLIENT_FILE),
28490
- join53(import.meta.dir, "mobile", PREVIEW_CLIENT_FILE)
28562
+ join54(import.meta.dir, PREVIEW_CLIENT_FILE),
28563
+ join54(import.meta.dir, "mobile", PREVIEW_CLIENT_FILE)
28491
28564
  ];
28492
28565
  const present = await Promise.all(candidates.map(fileExists));
28493
28566
  const entry = candidates.find((_candidate, index) => present[index]);
@@ -29870,8 +29943,8 @@ var MOBILE_UPDATE_REGISTRY_FORMAT = 1, DEFAULT_PREFIX = "absolutejs/mobile-updat
29870
29943
  });
29871
29944
  }
29872
29945
  const pathname = new URL(request.url).pathname.replace(/^\/+/, "");
29873
- const relative19 = pathname.startsWith(`${route}/`) ? pathname.slice(route.length + 1) : "";
29874
- if (request.method === "POST" && relative19 === "health") {
29946
+ const relative20 = pathname.startsWith(`${route}/`) ? pathname.slice(route.length + 1) : "";
29947
+ if (request.method === "POST" && relative20 === "health") {
29875
29948
  if (!options.registry.recordUpdateHealth)
29876
29949
  return new Response(null, { status: 404 });
29877
29950
  const appId = request.headers.get("x-absolute-mobile-app");
@@ -29914,7 +29987,7 @@ var MOBILE_UPDATE_REGISTRY_FORMAT = 1, DEFAULT_PREFIX = "absolutejs/mobile-updat
29914
29987
  }
29915
29988
  if (request.method !== "GET")
29916
29989
  return new Response(null, { status: 405 });
29917
- if (relative19 === "update.json") {
29990
+ if (relative20 === "update.json") {
29918
29991
  const expoProtocolVersion = request.headers.get("expo-protocol-version");
29919
29992
  const expoProtocol = expoProtocolVersion !== null;
29920
29993
  if (expoProtocol && expoProtocolVersion !== "1")
@@ -30032,7 +30105,7 @@ var MOBILE_UPDATE_REGISTRY_FORMAT = 1, DEFAULT_PREFIX = "absolutejs/mobile-updat
30032
30105
  }
30033
30106
  });
30034
30107
  }
30035
- const match = /^(amu_[a-f0-9]{64})\/files\/(.+)$/.exec(relative19);
30108
+ const match = /^(amu_[a-f0-9]{64})\/files\/(.+)$/.exec(relative20);
30036
30109
  if (!match?.[1] || !match[2])
30037
30110
  return new Response(null, { status: 404 });
30038
30111
  const file5 = await options.registry.readUpdateFile({
@@ -30126,14 +30199,14 @@ import {
30126
30199
  X509Certificate as X509Certificate3
30127
30200
  } from "crypto";
30128
30201
  import { access as access4, mkdir as mkdir13 } from "fs/promises";
30129
- import { dirname as dirname31, isAbsolute as isAbsolute8, relative as relative19, resolve as resolve46, sep as sep4 } from "path";
30202
+ import { dirname as dirname31, isAbsolute as isAbsolute9, relative as relative20, resolve as resolve47, sep as sep5 } from "path";
30130
30203
  import { pathToFileURL as pathToFileURL3 } from "url";
30131
30204
  import { Elysia as Elysia5 } from "elysia";
30132
30205
  var ABSOLUTE_MOBILE_UPDATE_SERVER_FORMAT = 1, DEFAULT_MOBILE_UPDATE_REGISTRY_MODULE = "mobile.update.ts", object4 = (value) => typeof value === "object" && value !== null && !Array.isArray(value), projectPath = (projectRoot, requested) => {
30133
- const root = resolve46(projectRoot);
30134
- const path2 = resolve46(root, requested);
30135
- const projectRelative = relative19(root, path2);
30136
- if (projectRelative === ".." || projectRelative.startsWith(`..${sep4}`) || isAbsolute8(projectRelative))
30206
+ const root = resolve47(projectRoot);
30207
+ const path2 = resolve47(root, requested);
30208
+ const projectRelative = relative20(root, path2);
30209
+ if (projectRelative === ".." || projectRelative.startsWith(`..${sep5}`) || isAbsolute9(projectRelative))
30137
30210
  throw new TypeError("mobile.updates.server.registry must remain inside the project.");
30138
30211
  return path2;
30139
30212
  }, isRegistry2 = (value) => object4(value) && [
@@ -30407,10 +30480,10 @@ __export(exports_hmrCompiler, {
30407
30480
  encodeHmrComponentId: () => encodeHmrComponentId,
30408
30481
  getApplyMetadataModule: () => getApplyMetadataModule
30409
30482
  });
30410
- import { dirname as dirname32, relative as relative20, resolve as resolve47 } from "path";
30483
+ import { dirname as dirname32, relative as relative21, resolve as resolve48 } from "path";
30411
30484
  import { performance as performance2 } from "perf_hooks";
30412
30485
  var encodeHmrComponentId = (absoluteFilePath, className) => {
30413
- const projectRel = relative20(process.cwd(), absoluteFilePath).replace(/\\/g, "/");
30486
+ const projectRel = relative21(process.cwd(), absoluteFilePath).replace(/\\/g, "/");
30414
30487
  return `${projectRel}@${className}`;
30415
30488
  }, getApplyMetadataModule = async (encodedId) => {
30416
30489
  const decoded = decodeURIComponent(encodedId);
@@ -30419,8 +30492,8 @@ var encodeHmrComponentId = (absoluteFilePath, className) => {
30419
30492
  return null;
30420
30493
  const filePathRel = decoded.slice(0, separatorIndex);
30421
30494
  const className = decoded.slice(separatorIndex + 1);
30422
- const componentFilePath = resolve47(process.cwd(), filePathRel);
30423
- const projectRelPath = relative20(process.cwd(), componentFilePath).replace(/\\/g, "/");
30495
+ const componentFilePath = resolve48(process.cwd(), filePathRel);
30496
+ const projectRelPath = relative21(process.cwd(), componentFilePath).replace(/\\/g, "/");
30424
30497
  const cacheKey3 = encodeURIComponent(`${projectRelPath}@${className}`);
30425
30498
  const { takePendingModule: takePendingModule2 } = await Promise.resolve().then(() => (init_fastHmrCompiler(), exports_fastHmrCompiler));
30426
30499
  const cached = takePendingModule2(cacheKey3);
@@ -30528,8 +30601,8 @@ var STORE_KEY = "__elysiaStore", restoredStores, getGlobalValue = (key) => Refle
30528
30601
  return null;
30529
30602
  if (!pathname.startsWith("/"))
30530
30603
  return null;
30531
- const { resolve: resolve48, normalize } = await import("path");
30532
- const candidate = resolve48(buildDir, pathname.slice(1));
30604
+ const { resolve: resolve49, normalize } = await import("path");
30605
+ const candidate = resolve49(buildDir, pathname.slice(1));
30533
30606
  const normalizedBuild = normalize(buildDir);
30534
30607
  if (!candidate.startsWith(normalizedBuild))
30535
30608
  return null;
@@ -30635,12 +30708,12 @@ __export(exports_devtoolsJson, {
30635
30708
  resolveDevtoolsUuidCachePath: () => resolveDevtoolsUuidCachePath
30636
30709
  });
30637
30710
  import { existsSync as existsSync43, mkdirSync as mkdirSync14, readFileSync as readFileSync37, writeFileSync as writeFileSync10 } from "fs";
30638
- import { dirname as dirname33, join as join54, resolve as resolve48 } from "path";
30711
+ import { dirname as dirname33, join as join55, resolve as resolve49 } from "path";
30639
30712
  import { Elysia as Elysia7 } from "elysia";
30640
30713
  var ENDPOINT = "/.well-known/appspecific/com.chrome.devtools.json", UUID_CACHE_KEY = "__absoluteDevtoolsWorkspaceUuid", getGlobalUuid = () => Reflect.get(globalThis, UUID_CACHE_KEY), setGlobalUuid = (uuid) => {
30641
30714
  Reflect.set(globalThis, UUID_CACHE_KEY, uuid);
30642
30715
  return uuid;
30643
- }, isUuidV4 = (value) => /^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(value), resolveDevtoolsUuidCachePath = (buildDir, uuidCachePath) => resolve48(uuidCachePath ?? join54(buildDir, ".absolute", "chrome-devtools-workspace-uuid")), readCachedUuid = (cachePath) => {
30716
+ }, isUuidV4 = (value) => /^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(value), resolveDevtoolsUuidCachePath = (buildDir, uuidCachePath) => resolve49(uuidCachePath ?? join55(buildDir, ".absolute", "chrome-devtools-workspace-uuid")), readCachedUuid = (cachePath) => {
30644
30717
  if (!existsSync43(cachePath))
30645
30718
  return null;
30646
30719
  try {
@@ -30666,7 +30739,7 @@ var ENDPOINT = "/.well-known/appspecific/com.chrome.devtools.json", UUID_CACHE_K
30666
30739
  writeFileSync10(cachePath, uuid, "utf-8");
30667
30740
  return setGlobalUuid(uuid);
30668
30741
  }, devtoolsJson = (buildDir, options = {}) => {
30669
- const rootPath = resolve48(options.projectRoot ?? process.cwd());
30742
+ const rootPath = resolve49(options.projectRoot ?? process.cwd());
30670
30743
  const root = options.normalizeForWindowsContainer === false ? rootPath : normalizeDevtoolsWorkspaceRoot(rootPath);
30671
30744
  const uuid = getOrCreateUuid(buildDir, options);
30672
30745
  return new Elysia7({ name: "absolute-devtools-json" }).get(ENDPOINT, () => ({
@@ -30679,11 +30752,11 @@ var ENDPOINT = "/.well-known/appspecific/com.chrome.devtools.json", UUID_CACHE_K
30679
30752
  if (process.env.WSL_DISTRO_NAME) {
30680
30753
  const distro = process.env.WSL_DISTRO_NAME;
30681
30754
  const withoutLeadingSlash = root.replace(/^\//, "");
30682
- return join54("\\\\wsl.localhost", distro, withoutLeadingSlash).replace(/\//g, "\\");
30755
+ return join55("\\\\wsl.localhost", distro, withoutLeadingSlash).replace(/\//g, "\\");
30683
30756
  }
30684
30757
  if (process.env.DOCKER_DESKTOP && !root.startsWith("\\\\")) {
30685
30758
  const withoutLeadingSlash = root.replace(/^\//, "");
30686
- return join54("\\\\wsl.localhost", "docker-desktop-data", withoutLeadingSlash).replace(/\//g, "\\");
30759
+ return join55("\\\\wsl.localhost", "docker-desktop-data", withoutLeadingSlash).replace(/\//g, "\\");
30687
30760
  }
30688
30761
  return root;
30689
30762
  };
@@ -30695,7 +30768,7 @@ __export(exports_imageOptimizer, {
30695
30768
  imageOptimizer: () => imageOptimizer
30696
30769
  });
30697
30770
  import { existsSync as existsSync44 } from "fs";
30698
- import { resolve as resolve49 } from "path";
30771
+ import { resolve as resolve50 } from "path";
30699
30772
  import { Elysia as Elysia8 } from "elysia";
30700
30773
  var DEFAULT_CACHE_TTL_SECONDS = 60, MS_PER_SECOND = 1000, MAX_QUALITY = 100, avifInProgress, safeResolve = (path2, baseDir) => {
30701
30774
  try {
@@ -30708,7 +30781,7 @@ var DEFAULT_CACHE_TTL_SECONDS = 60, MS_PER_SECOND = 1000, MAX_QUALITY = 100, avi
30708
30781
  }
30709
30782
  }, resolveLocalImage = (url, buildDir) => {
30710
30783
  const cleanPath = url.startsWith("/") ? url.slice(1) : url;
30711
- return safeResolve(cleanPath, buildDir) ?? safeResolve(cleanPath, resolve49(process.cwd()));
30784
+ return safeResolve(cleanPath, buildDir) ?? safeResolve(cleanPath, resolve50(process.cwd()));
30712
30785
  }, parseQueryParams = (query, allowedSizes, defaultQuality) => {
30713
30786
  const url = typeof query["url"] === "string" ? query["url"] : undefined;
30714
30787
  const wParam = typeof query["w"] === "string" ? query["w"] : undefined;
@@ -31215,7 +31288,7 @@ import {
31215
31288
  rm as rm13,
31216
31289
  writeFile as writeFile11
31217
31290
  } from "fs/promises";
31218
- import { join as join55, resolve as resolvePath } from "path";
31291
+ import { join as join56, resolve as resolvePath } from "path";
31219
31292
  var DEFAULT_MAX_PRODUCER_BYTES = 134217728, SHA_2562 = "sha256", ARTIFACT_FILE = "artifact.json", RELEASE_ID_PATTERN, DEFAULT_BLOB_PREFIX = "absolutejs/mobile-compatibility", hashBlob = async (blob) => {
31220
31293
  const bytes = new Uint8Array(await blob.arrayBuffer());
31221
31294
  return createHash8(SHA_2562).update(bytes).digest("hex");
@@ -31229,7 +31302,7 @@ var DEFAULT_MAX_PRODUCER_BYTES = 134217728, SHA_2562 = "sha256", ARTIFACT_FILE =
31229
31302
  }
31230
31303
  return releaseId;
31231
31304
  }, readStoredArtifact = async (releaseDirectory) => {
31232
- const serialized = await readFile10(join55(releaseDirectory, ARTIFACT_FILE), "utf8");
31305
+ const serialized = await readFile10(join56(releaseDirectory, ARTIFACT_FILE), "utf8");
31233
31306
  const parsed = JSON.parse(serialized);
31234
31307
  return parseAbsoluteMobileCompatibilityArtifact(parsed);
31235
31308
  }, validateStoredIdentity = (artifact, appId, releaseId) => {
@@ -31324,8 +31397,8 @@ var DEFAULT_MAX_PRODUCER_BYTES = 134217728, SHA_2562 = "sha256", ARTIFACT_FILE =
31324
31397
  }, createAbsoluteMobileFileArtifactStore = (options) => {
31325
31398
  const root = resolvePath(options.root);
31326
31399
  const maxProducerBytes = options.maxProducerBytes ?? DEFAULT_MAX_PRODUCER_BYTES;
31327
- const appDirectory = (appId) => join55(root, appDirectoryName(appId));
31328
- const releaseDirectory = (appId, releaseId) => join55(appDirectory(appId), requireReleaseId(releaseId));
31400
+ const appDirectory = (appId) => join56(root, appDirectoryName(appId));
31401
+ const releaseDirectory = (appId, releaseId) => join56(appDirectory(appId), requireReleaseId(releaseId));
31329
31402
  const acceptExistingRelease = async (error, artifact) => {
31330
31403
  if (!errorHasCode(error, "EEXIST") && !errorHasCode(error, "ENOTEMPTY")) {
31331
31404
  return false;
@@ -31366,7 +31439,7 @@ var DEFAULT_MAX_PRODUCER_BYTES = 134217728, SHA_2562 = "sha256", ARTIFACT_FILE =
31366
31439
  }
31367
31440
  return {
31368
31441
  artifact,
31369
- producer: Bun.file(join55(directory, artifact.producer.module))
31442
+ producer: Bun.file(join56(directory, artifact.producer.module))
31370
31443
  };
31371
31444
  },
31372
31445
  write: async (release) => {
@@ -31374,14 +31447,14 @@ var DEFAULT_MAX_PRODUCER_BYTES = 134217728, SHA_2562 = "sha256", ARTIFACT_FILE =
31374
31447
  const validated = await verifyAbsoluteMobileCompatibilityProducer({ artifact: validatedArtifact, producer: release.producer }, maxProducerBytes);
31375
31448
  const parent = appDirectory(validated.artifact.appId);
31376
31449
  await mkdir14(parent, { recursive: true });
31377
- const staging = await mkdtemp2(join55(parent, ".stage-"));
31378
- const producerPath = join55(staging, validated.artifact.producer.module);
31450
+ const staging = await mkdtemp2(join56(parent, ".stage-"));
31451
+ const producerPath = join56(staging, validated.artifact.producer.module);
31379
31452
  try {
31380
31453
  await mkdir14(resolvePath(producerPath, ".."), {
31381
31454
  recursive: true
31382
31455
  });
31383
31456
  await Promise.all([
31384
- writeFile11(join55(staging, ARTIFACT_FILE), `${JSON.stringify(validated.artifact, null, "\t")}
31457
+ writeFile11(join56(staging, ARTIFACT_FILE), `${JSON.stringify(validated.artifact, null, "\t")}
31385
31458
  `),
31386
31459
  writeFile11(producerPath, new Uint8Array(await validated.producer.arrayBuffer()))
31387
31460
  ]);
@@ -31427,7 +31500,7 @@ import {
31427
31500
  rm as rm14,
31428
31501
  writeFile as writeFile12
31429
31502
  } from "fs/promises";
31430
- import { dirname as dirname34, join as join56, resolve as resolvePath2 } from "path";
31503
+ import { dirname as dirname34, join as join57, resolve as resolvePath2 } from "path";
31431
31504
  import { pathToFileURL as pathToFileURL4 } from "url";
31432
31505
  var ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT = 1, CURRENT_BUNDLE_FILE = "current.json", BUNDLES_DIRECTORY = "bundles", ARTIFACT_FILE2 = "artifact.json", BUNDLE_ID_PATTERN, isRecord9 = (value) => typeof value === "object" && value !== null && !Array.isArray(value), errorHasCode2 = (error, code2) => typeof error === "object" && error !== null && Reflect.get(error, "code") === code2, bundleIdFor = (currentReleaseId, releases) => {
31433
31506
  const identity = JSON.stringify({
@@ -31458,16 +31531,16 @@ var ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT = 1, CURRENT_BUNDLE_FILE = "curre
31458
31531
  releases
31459
31532
  };
31460
31533
  }, writeRelease = async (root, release) => {
31461
- const directory = join56(root, release.artifact.releaseId);
31462
- const producerPath = join56(directory, release.artifact.producer.module);
31534
+ const directory = join57(root, release.artifact.releaseId);
31535
+ const producerPath = join57(directory, release.artifact.producer.module);
31463
31536
  await mkdir15(dirname34(producerPath), { recursive: true });
31464
31537
  await Promise.all([
31465
- writeFile12(join56(directory, ARTIFACT_FILE2), `${JSON.stringify(release.artifact, null, "\t")}
31538
+ writeFile12(join57(directory, ARTIFACT_FILE2), `${JSON.stringify(release.artifact, null, "\t")}
31466
31539
  `),
31467
31540
  writeFile12(producerPath, new Uint8Array(await release.producer.arrayBuffer()))
31468
31541
  ]);
31469
31542
  }, installImmutableBundle = async (bundlesRoot, bundleId, releases) => {
31470
- const destination = join56(bundlesRoot, bundleId);
31543
+ const destination = join57(bundlesRoot, bundleId);
31471
31544
  try {
31472
31545
  await access5(destination);
31473
31546
  return destination;
@@ -31475,7 +31548,7 @@ var ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT = 1, CURRENT_BUNDLE_FILE = "curre
31475
31548
  if (!errorHasCode2(error, "ENOENT"))
31476
31549
  throw error;
31477
31550
  }
31478
- const staging = await mkdtemp3(join56(bundlesRoot, ".stage-"));
31551
+ const staging = await mkdtemp3(join57(bundlesRoot, ".stage-"));
31479
31552
  try {
31480
31553
  await Promise.all(releases.map((release) => writeRelease(staging, release)));
31481
31554
  await rename6(staging, destination);
@@ -31506,15 +31579,15 @@ var ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT = 1, CURRENT_BUNDLE_FILE = "curre
31506
31579
  };
31507
31580
  }, loadAbsoluteMobileMaterializedBundle = async (root) => {
31508
31581
  const resolvedRoot = resolvePath2(root);
31509
- const serialized = await readFile11(join56(resolvedRoot, CURRENT_BUNDLE_FILE), "utf8");
31582
+ const serialized = await readFile11(join57(resolvedRoot, CURRENT_BUNDLE_FILE), "utf8");
31510
31583
  const parsed = JSON.parse(serialized);
31511
31584
  const index = parseBundleIndex(parsed);
31512
- const bundleRoot = join56(resolvedRoot, BUNDLES_DIRECTORY, index.bundleId);
31585
+ const bundleRoot = join57(resolvedRoot, BUNDLES_DIRECTORY, index.bundleId);
31513
31586
  return {
31514
31587
  artifacts: index.releases,
31515
31588
  currentReleaseId: index.currentReleaseId,
31516
31589
  loadProducer: async (artifact) => {
31517
- const modulePath = join56(bundleRoot, artifact.releaseId, artifact.producer.module);
31590
+ const modulePath = join57(bundleRoot, artifact.releaseId, artifact.producer.module);
31518
31591
  await verifyAbsoluteMobileCompatibilityProducer({
31519
31592
  artifact,
31520
31593
  producer: Bun.file(modulePath)
@@ -31540,7 +31613,7 @@ var ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT = 1, CURRENT_BUNDLE_FILE = "curre
31540
31613
  return release;
31541
31614
  });
31542
31615
  const root = resolvePath2(input.root);
31543
- const bundlesRoot = join56(root, BUNDLES_DIRECTORY);
31616
+ const bundlesRoot = join57(root, BUNDLES_DIRECTORY);
31544
31617
  await mkdir15(bundlesRoot, { recursive: true });
31545
31618
  const bundleId = bundleIdFor(input.currentReleaseId, artifacts);
31546
31619
  await installImmutableBundle(bundlesRoot, bundleId, orderedReleases);
@@ -31550,8 +31623,8 @@ var ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT = 1, CURRENT_BUNDLE_FILE = "curre
31550
31623
  format: ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT,
31551
31624
  releases: artifacts
31552
31625
  };
31553
- const pointerPath = join56(root, CURRENT_BUNDLE_FILE);
31554
- const temporaryPointerPath = join56(root, `.current-${crypto.randomUUID()}.json`);
31626
+ const pointerPath = join57(root, CURRENT_BUNDLE_FILE);
31627
+ const temporaryPointerPath = join57(root, `.current-${crypto.randomUUID()}.json`);
31555
31628
  await writeFile12(temporaryPointerPath, `${JSON.stringify(index, null, "\t")}
31556
31629
  `, { flag: "wx" });
31557
31630
  await rename6(temporaryPointerPath, pointerPath);
@@ -31559,12 +31632,12 @@ var ABSOLUTE_MOBILE_MATERIALIZED_BUNDLE_FORMAT = 1, CURRENT_BUNDLE_FILE = "curre
31559
31632
  }, readAbsoluteMobileMaterializedReleases = async (root) => {
31560
31633
  const resolvedRoot = resolvePath2(root);
31561
31634
  try {
31562
- const serialized = await readFile11(join56(resolvedRoot, CURRENT_BUNDLE_FILE), "utf8");
31635
+ const serialized = await readFile11(join57(resolvedRoot, CURRENT_BUNDLE_FILE), "utf8");
31563
31636
  const parsed = JSON.parse(serialized);
31564
31637
  const index = parseBundleIndex(parsed);
31565
- const bundleRoot = join56(resolvedRoot, BUNDLES_DIRECTORY, index.bundleId);
31638
+ const bundleRoot = join57(resolvedRoot, BUNDLES_DIRECTORY, index.bundleId);
31566
31639
  return Promise.all(index.releases.map(async (artifact) => {
31567
- const producer = Bun.file(join56(bundleRoot, artifact.releaseId, artifact.producer.module));
31640
+ const producer = Bun.file(join57(bundleRoot, artifact.releaseId, artifact.producer.module));
31568
31641
  await verifyAbsoluteMobileCompatibilityProducer({
31569
31642
  artifact,
31570
31643
  producer
@@ -32164,7 +32237,7 @@ __export(exports_prerender, {
32164
32237
  routeToFilename: () => routeToFilename
32165
32238
  });
32166
32239
  import { mkdirSync as mkdirSync15, readFileSync as readFileSync38 } from "fs";
32167
- import { join as join57 } from "path";
32240
+ import { join as join58 } from "path";
32168
32241
  var SERVER_OUTPUT_LIMIT = 4000, STARTUP_POLL_INTERVAL_MS = 100, DEFAULT_STARTUP_TIMEOUT_MS = 30000, DEFAULT_FETCH_TIMEOUT_MS = 1e4, PRERENDER_BYPASS_HEADER = "X-Absolute-Prerender-Bypass", routeToFilename = (route) => route === "/" ? "index.html" : `${route.slice(1).replace(/\//g, "-")}.html`, writeTimestamp = async (htmlPath) => {
32169
32242
  const metaPath = htmlPath.replace(/\.html$/, ".meta");
32170
32243
  await Bun.write(metaPath, String(Date.now()));
@@ -32234,7 +32307,7 @@ var SERVER_OUTPUT_LIMIT = 4000, STARTUP_POLL_INTERVAL_MS = 100, DEFAULT_STARTUP_
32234
32307
  if (!isCompleteHtml(html))
32235
32308
  return false;
32236
32309
  const fileName = routeToFilename(route);
32237
- const filePath = join57(prerenderDir, fileName);
32310
+ const filePath = join58(prerenderDir, fileName);
32238
32311
  await Bun.write(filePath, html);
32239
32312
  await writeTimestamp(filePath);
32240
32313
  return true;
@@ -32264,13 +32337,13 @@ var SERVER_OUTPUT_LIMIT = 4000, STARTUP_POLL_INTERVAL_MS = 100, DEFAULT_STARTUP_
32264
32337
  return;
32265
32338
  }
32266
32339
  const fileName = routeToFilename(route);
32267
- const filePath = join57(prerenderDir, fileName);
32340
+ const filePath = join58(prerenderDir, fileName);
32268
32341
  await Bun.write(filePath, html);
32269
32342
  await writeTimestamp(filePath);
32270
32343
  result.routes.set(route, filePath);
32271
32344
  log2?.(` Pre-rendered ${route} \u2192 ${fileName} (${html.length} bytes)`);
32272
32345
  }, prerender = async (port, outDir, staticConfig, log2) => {
32273
- const prerenderDir = join57(outDir, "_prerendered");
32346
+ const prerenderDir = join58(outDir, "_prerendered");
32274
32347
  mkdirSync15(prerenderDir, { recursive: true });
32275
32348
  const baseUrl = `http://localhost:${port}`;
32276
32349
  let routes;
@@ -32389,10 +32462,10 @@ __export(exports_prepare, {
32389
32462
  });
32390
32463
  import { createHash as createHash10 } from "crypto";
32391
32464
  import { existsSync as existsSync45, readdirSync as readdirSync12, readFileSync as readFileSync39 } from "fs";
32392
- import { basename as basename19, join as join58, relative as relative21, resolve as resolvePath3 } from "path";
32465
+ import { basename as basename19, join as join59, relative as relative22, resolve as resolvePath3 } from "path";
32393
32466
  import { Elysia as Elysia11, NotFound } from "elysia";
32394
- var MS_PER_SECOND2 = 1000, DEFAULT_PORT2 = 3000, MAX_STATIC_ROUTE_COUNT, STATIC_PLUGIN_RETRY_DELAY_MS = 50, waitForStaticPluginRetry = () => new Promise((resolve50) => {
32395
- setTimeout(resolve50, STATIC_PLUGIN_RETRY_DELAY_MS);
32467
+ var MS_PER_SECOND2 = 1000, DEFAULT_PORT2 = 3000, MAX_STATIC_ROUTE_COUNT, STATIC_PLUGIN_RETRY_DELAY_MS = 50, waitForStaticPluginRetry = () => new Promise((resolve51) => {
32468
+ setTimeout(resolve51, STATIC_PLUGIN_RETRY_DELAY_MS);
32396
32469
  }), retryStaticPlugin = async (createStaticPlugin, options) => {
32397
32470
  try {
32398
32471
  return await createStaticPlugin(options);
@@ -32478,7 +32551,7 @@ var MS_PER_SECOND2 = 1000, DEFAULT_PORT2 = 3000, MAX_STATIC_ROUTE_COUNT, STATIC_
32478
32551
  return files;
32479
32552
  }, PREWARM_MAX_PAUSE_MS = 60000, toWarmTasks = function* (files, warmCache, srcUrlPrefix) {
32480
32553
  for (const file5 of files) {
32481
- const rel = relative21(process.cwd(), file5).replace(/\\/g, "/");
32554
+ const rel = relative22(process.cwd(), file5).replace(/\\/g, "/");
32482
32555
  yield () => warmCache(`${srcUrlPrefix}${rel}`);
32483
32556
  }
32484
32557
  }, builtPageSources = () => {
@@ -32519,7 +32592,7 @@ var MS_PER_SECOND2 = 1000, DEFAULT_PORT2 = 3000, MAX_STATIC_ROUTE_COUNT, STATIC_
32519
32592
  const srcPath = resolvePath3(devIndexDir, fileName);
32520
32593
  if (!existsSync45(srcPath))
32521
32594
  continue;
32522
- const rel = relative21(process.cwd(), srcPath).replace(/\\/g, "/");
32595
+ const rel = relative22(process.cwd(), srcPath).replace(/\\/g, "/");
32523
32596
  manifest[key] = `${SRC_URL_PREFIX2}${rel}`;
32524
32597
  }
32525
32598
  }, ICON_HASH_LENGTH = 8, registerIconVersioning = (buildDir) => {
@@ -32531,7 +32604,7 @@ var MS_PER_SECOND2 = 1000, DEFAULT_PORT2 = 3000, MAX_STATIC_ROUTE_COUNT, STATIC_
32531
32604
  if (cached !== undefined)
32532
32605
  return cached;
32533
32606
  const path2 = href.split("?")[0] ?? href;
32534
- const filePath = join58(buildDir, path2);
32607
+ const filePath = join59(buildDir, path2);
32535
32608
  let versioned = href;
32536
32609
  if (existsSync45(filePath)) {
32537
32610
  const hash = createHash10("sha256").update(readFileSync39(filePath)).digest("hex").slice(0, ICON_HASH_LENGTH);
@@ -32678,12 +32751,12 @@ var MS_PER_SECOND2 = 1000, DEFAULT_PORT2 = 3000, MAX_STATIC_ROUTE_COUNT, STATIC_
32678
32751
  continue;
32679
32752
  const name = basename19(entry, ".html");
32680
32753
  const route = name === "index" ? "/" : `/${name}`;
32681
- map.set(route, join58(prerenderDir, entry));
32754
+ map.set(route, join59(prerenderDir, entry));
32682
32755
  }
32683
32756
  return map;
32684
32757
  }, loadMobileCompatibilityPlugin = async (buildDir) => {
32685
- const root = join58(buildDir, ".absolutejs", "mobile-compatibility");
32686
- if (!existsSync45(join58(root, "current.json"))) {
32758
+ const root = join59(buildDir, ".absolutejs", "mobile-compatibility");
32759
+ if (!existsSync45(join59(root, "current.json"))) {
32687
32760
  return new Elysia11({ name: "absolutejs-mobile-compatibility-empty" });
32688
32761
  }
32689
32762
  const [
@@ -32748,12 +32821,12 @@ This usually means a build-time error in a source file. Check the dev-server ter
32748
32821
  setCurrentPageIslandMetadata(await loadPageIslandMetadata(config));
32749
32822
  recordStep("load production manifest and island metadata", stepStartedAt);
32750
32823
  stepStartedAt = performance.now();
32751
- const conventionsPath = join58(buildDir, "conventions.json");
32824
+ const conventionsPath = join59(buildDir, "conventions.json");
32752
32825
  if (existsSync45(conventionsPath)) {
32753
32826
  const conventions = JSON.parse(readFileSync39(conventionsPath, "utf-8"));
32754
32827
  setConventions(conventions);
32755
32828
  }
32756
- const spaRoutesPath = join58(buildDir, "spa-routes.json");
32829
+ const spaRoutesPath = join59(buildDir, "spa-routes.json");
32757
32830
  if (existsSync45(spaRoutesPath)) {
32758
32831
  setSpaRouteManifest(JSON.parse(readFileSync39(spaRoutesPath, "utf-8")));
32759
32832
  }
@@ -32766,12 +32839,12 @@ This usually means a build-time error in a source file. Check the dev-server ter
32766
32839
  prefix: "",
32767
32840
  staticLimit: MAX_STATIC_ROUTE_COUNT
32768
32841
  });
32769
- const generatedAssetsRoot = join58(buildDir, ".absolutejs");
32842
+ const generatedAssetsRoot = join59(buildDir, ".absolutejs");
32770
32843
  const generatedAssetsPlugin = new Elysia11({
32771
32844
  name: "absolutejs-generated-assets"
32772
32845
  }).get("/.absolutejs/*", async ({ params, set }) => {
32773
32846
  const requestedPath = resolvePath3(generatedAssetsRoot, params["*"]);
32774
- if (relative21(generatedAssetsRoot, requestedPath).startsWith("..")) {
32847
+ if (relative22(generatedAssetsRoot, requestedPath).startsWith("..")) {
32775
32848
  set.status = 404;
32776
32849
  return "Not Found";
32777
32850
  }
@@ -32804,7 +32877,7 @@ This usually means a build-time error in a source file. Check the dev-server ter
32804
32877
  responseValue.headers.set("cache-control", isFingerprintedAsset(pathname) ? "public, max-age=31536000, immutable" : "public, max-age=0, must-revalidate");
32805
32878
  });
32806
32879
  stepStartedAt = performance.now();
32807
- const prerenderDir = join58(buildDir, "_prerendered");
32880
+ const prerenderDir = join59(buildDir, "_prerendered");
32808
32881
  const prerenderMap = loadPrerenderMap(prerenderDir);
32809
32882
  const mobileCompatibilityPlugin = await loadMobileCompatibilityPlugin(buildDir);
32810
32883
  const mobileAssociationPlugin = await loadMobileAssociationPlugin(config.mobile);
@@ -32928,7 +33001,7 @@ __export(exports_moduleServer, {
32928
33001
  warnIfReactFastRefreshUnsupported: () => warnIfReactFastRefreshUnsupported
32929
33002
  });
32930
33003
  import { existsSync as existsSync46, readFileSync as readFileSync40, realpathSync as realpathSync3, statSync as statSync7 } from "fs";
32931
- import { basename as basename20, dirname as dirname35, extname as extname15, join as join59, resolve as resolve50, relative as relative22 } from "path";
33004
+ import { basename as basename20, dirname as dirname35, extname as extname15, join as join60, resolve as resolve51, relative as relative23 } from "path";
32932
33005
  var SRC_PREFIX = "/@src/", BROWSER_DEFINE, jsTranspiler2, legacyDecoratorTsconfig, tsTranspiler2, tsxTranspiler, TRANSPILABLE, ALL_EXPORTS_RE, STRING_CONTENTS_RE, preserveTypeExports = (originalSource, transpiled, valueExports) => {
32933
33006
  const codeOnly = originalSource.replace(STRING_CONTENTS_RE, '""');
32934
33007
  const allExports = [];
@@ -32948,10 +33021,10 @@ var SRC_PREFIX = "/@src/", BROWSER_DEFINE, jsTranspiler2, legacyDecoratorTsconfi
32948
33021
  ${stubs}
32949
33022
  `;
32950
33023
  }, resolveRelativeExtension = (srcPath, projectRoot, extensions) => {
32951
- const directHit = extensions.find((ext) => existsSync46(resolve50(projectRoot, srcPath + ext)));
33024
+ const directHit = extensions.find((ext) => existsSync46(resolve51(projectRoot, srcPath + ext)));
32952
33025
  if (directHit)
32953
33026
  return srcPath + directHit;
32954
- const indexHit = extensions.find((ext) => existsSync46(resolve50(projectRoot, srcPath, `index${ext}`)));
33027
+ const indexHit = extensions.find((ext) => existsSync46(resolve51(projectRoot, srcPath, `index${ext}`)));
32955
33028
  if (indexHit)
32956
33029
  return `${srcPath}/index${indexHit}`;
32957
33030
  return srcPath;
@@ -32980,7 +33053,7 @@ ${stubs}
32980
33053
  return invalidationVersion > 0 ? `${mtime}.${invalidationVersion}` : `${mtime}`;
32981
33054
  }, srcUrl = (relPath, projectRoot) => {
32982
33055
  const base = `${SRC_PREFIX}${relPath.replace(/\\/g, "/")}`;
32983
- const absPath = resolve50(projectRoot, relPath);
33056
+ const absPath = resolve51(projectRoot, relPath);
32984
33057
  const cached = mtimeCache.get(absPath);
32985
33058
  if (cached !== undefined)
32986
33059
  return `${base}?v=${buildVersion(cached, absPath)}`;
@@ -32992,12 +33065,12 @@ ${stubs}
32992
33065
  return base;
32993
33066
  }
32994
33067
  }, resolveRelativeImport = (relPath, fileDir, projectRoot, extensions) => {
32995
- const absPath = resolve50(fileDir, relPath);
32996
- const rel = relative22(projectRoot, absPath);
33068
+ const absPath = resolve51(fileDir, relPath);
33069
+ const rel = relative23(projectRoot, absPath);
32997
33070
  const extension = extname15(rel);
32998
33071
  let srcPath = RESOLVED_MODULE_EXTENSIONS.has(extension) ? rel : resolveRelativeExtension(rel, projectRoot, extensions);
32999
33072
  if (extname15(srcPath) === ".svelte") {
33000
- srcPath = relative22(projectRoot, resolveSvelteModulePath(resolve50(projectRoot, srcPath)));
33073
+ srcPath = relative23(projectRoot, resolveSvelteModulePath(resolve51(projectRoot, srcPath)));
33001
33074
  }
33002
33075
  return srcUrl(srcPath, projectRoot);
33003
33076
  }, NODE_BUILTIN_RE, resolveAbsoluteSpecifier = (specifier, projectRoot) => {
@@ -33009,27 +33082,27 @@ ${stubs}
33009
33082
  "import"
33010
33083
  ]);
33011
33084
  if (fromExports)
33012
- return relative22(projectRoot, fromExports);
33085
+ return relative23(projectRoot, fromExports);
33013
33086
  try {
33014
33087
  const isScoped = specifier.startsWith("@");
33015
33088
  const parts = specifier.split("/");
33016
33089
  const packageName = isScoped ? `${parts[0]}/${parts[1]}` : parts[0];
33017
33090
  const subpath = isScoped ? parts.slice(2).join("/") : parts.slice(1).join("/");
33018
33091
  if (!subpath) {
33019
- const pkgDir = resolve50(projectRoot, "node_modules", packageName ?? "");
33020
- const pkgJsonPath = join59(pkgDir, "package.json");
33092
+ const pkgDir = resolve51(projectRoot, "node_modules", packageName ?? "");
33093
+ const pkgJsonPath = join60(pkgDir, "package.json");
33021
33094
  if (existsSync46(pkgJsonPath)) {
33022
33095
  const pkg = JSON.parse(readFileSync40(pkgJsonPath, "utf-8"));
33023
33096
  const esmEntry = typeof pkg.module === "string" && pkg.module || typeof pkg.browser === "string" && pkg.browser;
33024
33097
  if (esmEntry) {
33025
- const resolved = resolve50(pkgDir, esmEntry);
33098
+ const resolved = resolve51(pkgDir, esmEntry);
33026
33099
  if (existsSync46(resolved))
33027
- return relative22(projectRoot, resolved);
33100
+ return relative23(projectRoot, resolved);
33028
33101
  }
33029
33102
  }
33030
33103
  }
33031
33104
  } catch {}
33032
- return relative22(projectRoot, Bun.resolveSync(specifier, projectRoot));
33105
+ return relative23(projectRoot, Bun.resolveSync(specifier, projectRoot));
33033
33106
  } catch {
33034
33107
  return;
33035
33108
  }
@@ -33068,22 +33141,22 @@ ${stubs}
33068
33141
  result = result.replace(/(import\s*["'])(\.\.?\/[^"']+)(["']\s*;?)/g, (_match, prefix, relPath, suffix) => isRealImport(relPath) ? `${prefix}${resolveRelativeImport(relPath, fileDir, projectRoot, SIDE_EFFECT_EXTENSIONS)}${suffix}` : _match);
33069
33142
  const rewriteAbsoluteToSrc = (_match, prefix, absPath, _ext, suffix) => {
33070
33143
  if (absPath.startsWith(projectRoot)) {
33071
- const rel2 = relative22(projectRoot, absPath).replace(/\\/g, "/");
33144
+ const rel2 = relative23(projectRoot, absPath).replace(/\\/g, "/");
33072
33145
  return `${prefix}${srcUrl(rel2, projectRoot)}${suffix}`;
33073
33146
  }
33074
- const rel = relative22(projectRoot, absPath).replace(/\\/g, "/");
33147
+ const rel = relative23(projectRoot, absPath).replace(/\\/g, "/");
33075
33148
  return `${prefix}${srcUrl(rel, projectRoot)}${suffix}`;
33076
33149
  };
33077
33150
  result = result.replace(/((?:from|import)\s*["'])(\/[^"']+\.(tsx?|jsx?|ts))(["'])/g, rewriteAbsoluteToSrc);
33078
33151
  result = result.replace(/(import\s*\(\s*["'])(\/[^"']+\.(tsx?|jsx?|ts))(["']\s*\))/g, rewriteAbsoluteToSrc);
33079
33152
  result = result.replace(/new\s+URL\(\s*["'](\.\.?\/[^"']+)["']\s*,\s*import\.meta\.url\s*\)/g, (_match, relPath) => {
33080
- const absPath = resolve50(fileDir, relPath);
33081
- const rel = relative22(projectRoot, absPath);
33153
+ const absPath = resolve51(fileDir, relPath);
33154
+ const rel = relative23(projectRoot, absPath);
33082
33155
  return `new URL('${srcUrl(rel, projectRoot)}', import.meta.url)`;
33083
33156
  });
33084
33157
  result = result.replace(/import\.meta\.resolve\(\s*["'](\.\.?\/[^"']+)["']\s*\)/g, (_match, relPath) => {
33085
- const absPath = resolve50(fileDir, relPath);
33086
- const rel = relative22(projectRoot, absPath);
33158
+ const absPath = resolve51(fileDir, relPath);
33159
+ const rel = relative23(projectRoot, absPath);
33087
33160
  return `'${srcUrl(rel, projectRoot)}'`;
33088
33161
  });
33089
33162
  return result;
@@ -33139,7 +33212,7 @@ ${code2}`;
33139
33212
  transpiled = `var $RefreshReg$ = window.$RefreshReg$ || function(){};
33140
33213
  ` + `var $RefreshSig$ = window.$RefreshSig$ || function(){ return function(t){ return t; }; };
33141
33214
  ${transpiled}`;
33142
- const relPath = relative22(projectRoot, filePath).replace(/\\/g, "/");
33215
+ const relPath = relative23(projectRoot, filePath).replace(/\\/g, "/");
33143
33216
  transpiled = transpiled.replace(/\binput\.tsx:/g, `${relPath}:`);
33144
33217
  transpiled += buildIslandMetadataExports(raw);
33145
33218
  return rewriteImports(transpiled, filePath, projectRoot, rewriter);
@@ -33300,11 +33373,11 @@ ${code2}`;
33300
33373
  if (compiled.css?.code) {
33301
33374
  const cssPath = `${filePath}.css`;
33302
33375
  svelteExternalCss.set(cssPath, compiled.css.code);
33303
- const cssUrl = srcUrl(relative22(projectRoot, cssPath), projectRoot);
33376
+ const cssUrl = srcUrl(relative23(projectRoot, cssPath), projectRoot);
33304
33377
  code2 = `import "${cssUrl}";
33305
33378
  ${code2}`;
33306
33379
  }
33307
- const moduleUrl = `${SRC_PREFIX}${relative22(projectRoot, filePath).replace(/\\/g, "/")}`;
33380
+ const moduleUrl = `${SRC_PREFIX}${relative23(projectRoot, filePath).replace(/\\/g, "/")}`;
33308
33381
  code2 = code2.replace(/if\s*\(import\.meta\.hot\)\s*\{/, `if (typeof window !== "undefined") {
33309
33382
  ` + ` if (!window.__SVELTE_HMR_ACCEPT__) window.__SVELTE_HMR_ACCEPT__ = {};
33310
33383
  ` + ` var __hmr_accept = function(cb) { window.__SVELTE_HMR_ACCEPT__[${JSON.stringify(moduleUrl)}] = cb; };`);
@@ -33404,8 +33477,8 @@ ${code2}`;
33404
33477
  code2 = injectVueHmr(code2, filePath, projectRoot, vueDir);
33405
33478
  return rewriteImports(code2, filePath, projectRoot, rewriter);
33406
33479
  }, injectVueHmr = (code2, filePath, projectRoot, vueDir) => {
33407
- const hmrBase = vueDir ? resolve50(vueDir) : projectRoot;
33408
- const hmrId = relative22(hmrBase, filePath).replace(/\\/g, "/").replace(/\.vue$/, "");
33480
+ const hmrBase = vueDir ? resolve51(vueDir) : projectRoot;
33481
+ const hmrId = relative23(hmrBase, filePath).replace(/\\/g, "/").replace(/\.vue$/, "");
33409
33482
  let result = code2.replace(/export\s+default\s+/, "var __hmr_comp__ = ");
33410
33483
  result += [
33411
33484
  "",
@@ -33565,7 +33638,7 @@ export default {};
33565
33638
  const escaped = virtualCss.replace(/\\/g, "\\\\").replace(/`/g, "\\`").replace(/\$/g, "\\$");
33566
33639
  return jsResponse(`var s=document.createElement('style');s.textContent=\`${escaped}\`;s.dataset.svelteHmr=${JSON.stringify(cssCheckPath)};var p=document.querySelector('style[data-svelte-hmr="${cssCheckPath}"]');if(p)p.remove();document.head.appendChild(s);`);
33567
33640
  }, resolveSourcePath2 = (relPath, projectRoot) => {
33568
- const filePath = resolve50(projectRoot, relPath);
33641
+ const filePath = resolve51(projectRoot, relPath);
33569
33642
  const ext = extname15(filePath);
33570
33643
  if (ext === ".svelte")
33571
33644
  return { ext, filePath: resolveSvelteModulePath(filePath) };
@@ -33602,14 +33675,14 @@ export default {};
33602
33675
  const absoluteCandidate = `/${tail.replace(/^\/+/, "")}`;
33603
33676
  const candidates = [
33604
33677
  absoluteCandidate,
33605
- resolve50(projectRoot, tail)
33678
+ resolve51(projectRoot, tail)
33606
33679
  ];
33607
33680
  try {
33608
33681
  const { loadConfig: loadConfig2 } = await Promise.resolve().then(() => (init_loadConfig(), exports_loadConfig));
33609
33682
  const cfg = await loadConfig2();
33610
- const angularDir = cfg.angularDirectory && resolve50(projectRoot, cfg.angularDirectory);
33683
+ const angularDir = cfg.angularDirectory && resolve51(projectRoot, cfg.angularDirectory);
33611
33684
  if (angularDir)
33612
- candidates.push(resolve50(angularDir, tail));
33685
+ candidates.push(resolve51(angularDir, tail));
33613
33686
  } catch {}
33614
33687
  for (const candidate of candidates) {
33615
33688
  if (await fileExists2(candidate)) {
@@ -33640,7 +33713,7 @@ export default {};
33640
33713
  if (!TRANSPILABLE.has(ext))
33641
33714
  return;
33642
33715
  const stat4 = statSync7(filePath);
33643
- const resolvedVueDir = vueDir ? resolve50(vueDir) : undefined;
33716
+ const resolvedVueDir = vueDir ? resolve51(vueDir) : undefined;
33644
33717
  let content = REACT_EXTENSIONS.has(ext) ? transformReactFile(filePath, projectRoot, rewriter) : transformPlainFile(filePath, projectRoot, rewriter, resolvedVueDir);
33645
33718
  const isAngularGeneratedJs = ext === ".js" && filePath.replace(/\\/g, "/").includes("/.absolutejs/generated/angular/");
33646
33719
  if (isAngularGeneratedJs) {
@@ -33699,7 +33772,7 @@ export default {};
33699
33772
  const relPath = pathname.slice(SRC_PREFIX.length);
33700
33773
  if (relPath === "bun:wrap" || relPath.startsWith("bun:wrap?"))
33701
33774
  return handleBunWrapRequest();
33702
- const virtualCssResponse = handleVirtualSvelteCss(resolve50(projectRoot, relPath));
33775
+ const virtualCssResponse = handleVirtualSvelteCss(resolve51(projectRoot, relPath));
33703
33776
  if (virtualCssResponse)
33704
33777
  return virtualCssResponse;
33705
33778
  const { filePath, ext } = resolveSourcePath2(relPath, projectRoot);
@@ -33715,11 +33788,11 @@ export default {};
33715
33788
  SRC_IMPORT_RE.lastIndex = 0;
33716
33789
  while ((match = SRC_IMPORT_RE.exec(content)) !== null) {
33717
33790
  if (match[1])
33718
- files.push(resolve50(projectRoot, match[1]));
33791
+ files.push(resolve51(projectRoot, match[1]));
33719
33792
  }
33720
33793
  return files;
33721
33794
  }, invalidateModule = (filePath) => {
33722
- const resolved = resolve50(filePath);
33795
+ const resolved = resolve51(filePath);
33723
33796
  invalidate(filePath);
33724
33797
  if (resolved !== filePath)
33725
33798
  invalidate(resolved);
@@ -33782,7 +33855,7 @@ export default {};
33782
33855
  return false;
33783
33856
  }
33784
33857
  const { patchManifestIndexes: patchManifestIndexes2 } = await Promise.resolve().then(() => (init_prepare(), exports_prepare));
33785
- patchManifestIndexes2(cached.manifest, resolve50(state.resolvedPaths.buildDir, "_src_indexes"), SRC_PREFIX);
33858
+ patchManifestIndexes2(cached.manifest, resolve51(state.resolvedPaths.buildDir, "_src_indexes"), SRC_PREFIX);
33786
33859
  logPageBuild(entry.source, entry.framework, Math.round(durationMs));
33787
33860
  logStartupTimingBlock("AbsoluteJS on-demand page build", [
33788
33861
  { durationMs, label: entry.name }
@@ -34145,11 +34218,11 @@ var exports_simpleHTMLHMR = {};
34145
34218
  __export(exports_simpleHTMLHMR, {
34146
34219
  handleHTMLUpdate: () => handleHTMLUpdate
34147
34220
  });
34148
- import { resolve as resolve51 } from "path";
34221
+ import { resolve as resolve52 } from "path";
34149
34222
  var handleHTMLUpdate = async (htmlFilePath) => {
34150
34223
  let htmlContent;
34151
34224
  try {
34152
- const resolvedPath = resolve51(htmlFilePath);
34225
+ const resolvedPath = resolve52(htmlFilePath);
34153
34226
  const file5 = Bun.file(resolvedPath);
34154
34227
  if (!await file5.exists()) {
34155
34228
  return null;
@@ -34175,11 +34248,11 @@ var exports_simpleHTMXHMR = {};
34175
34248
  __export(exports_simpleHTMXHMR, {
34176
34249
  handleHTMXUpdate: () => handleHTMXUpdate
34177
34250
  });
34178
- import { resolve as resolve52 } from "path";
34251
+ import { resolve as resolve53 } from "path";
34179
34252
  var handleHTMXUpdate = async (htmxFilePath) => {
34180
34253
  let htmlContent;
34181
34254
  try {
34182
- const resolvedPath = resolve52(htmxFilePath);
34255
+ const resolvedPath = resolve53(htmxFilePath);
34183
34256
  const file5 = Bun.file(resolvedPath);
34184
34257
  if (!await file5.exists()) {
34185
34258
  return null;
@@ -34211,11 +34284,11 @@ import { existsSync as existsSync47, readdirSync as readdirSync13, rmSync as rmS
34211
34284
  import {
34212
34285
  basename as basename21,
34213
34286
  dirname as dirname36,
34214
- isAbsolute as isAbsolute9,
34215
- join as join60,
34216
- relative as relative23,
34287
+ isAbsolute as isAbsolute10,
34288
+ join as join61,
34289
+ relative as relative24,
34217
34290
  resolve as resolvePath4,
34218
- sep as sep5
34291
+ sep as sep6
34219
34292
  } from "path";
34220
34293
  var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSsrCssCaches = () => {
34221
34294
  clearSpaRouteCssCaches();
@@ -34339,8 +34412,8 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
34339
34412
  const relJs = `${rel.slice(0, -ext[0].length)}.js`;
34340
34413
  const generatedDir = getFrameworkGeneratedDir(framework, cwd2);
34341
34414
  for (const candidate of [
34342
- join60(generatedDir, relJs),
34343
- `${join60(generatedDir, relJs)}.map`
34415
+ join61(generatedDir, relJs),
34416
+ `${join61(generatedDir, relJs)}.map`
34344
34417
  ]) {
34345
34418
  try {
34346
34419
  rmSync4(candidate, { force: true });
@@ -34581,7 +34654,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
34581
34654
  const webPath = urlPrefix ? `/${urlPrefix}/${relFromDir}` : `/${relFromDir}`;
34582
34655
  state.assetStore.set(webPath, new Uint8Array(bytes));
34583
34656
  state.fileHashes.set(absSource, currentHash);
34584
- logHmrUpdate(relative23(process.cwd(), filePath));
34657
+ logHmrUpdate(relative24(process.cwd(), filePath));
34585
34658
  broadcastToClients(state, {
34586
34659
  data: {
34587
34660
  framework: urlPrefix || "public",
@@ -34601,7 +34674,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
34601
34674
  return;
34602
34675
  if (framework === "unknown") {
34603
34676
  invalidate(resolvePath4(filePath));
34604
- const relPath = relative23(process.cwd(), filePath);
34677
+ const relPath = relative24(process.cwd(), filePath);
34605
34678
  logHmrUpdate(relPath);
34606
34679
  const { angularDir } = state.resolvedPaths;
34607
34680
  let hasAngularDependent = false;
@@ -35123,8 +35196,8 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35123
35196
  };
35124
35197
  return ({ immediate = false } = {}) => {
35125
35198
  if (!ctx.debouncedPromise) {
35126
- ctx.debouncedPromise = new Promise((resolve53) => {
35127
- ctx.debouncedResolve = resolve53;
35199
+ ctx.debouncedPromise = new Promise((resolve54) => {
35200
+ ctx.debouncedResolve = resolve54;
35128
35201
  });
35129
35202
  }
35130
35203
  const scheduled = ctx.debouncedPromise;
@@ -35150,7 +35223,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35150
35223
  const angularDirAbs = resolvePath4(angularDir);
35151
35224
  const filesUnderAngular = Array.from(editedFiles).filter((file5) => {
35152
35225
  const abs = resolvePath4(file5);
35153
- return abs === angularDirAbs || abs.startsWith(angularDirAbs + sep5);
35226
+ return abs === angularDirAbs || abs.startsWith(angularDirAbs + sep6);
35154
35227
  });
35155
35228
  if (filesUnderAngular.length === 0)
35156
35229
  return;
@@ -35193,7 +35266,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35193
35266
  try {
35194
35267
  const { invalidateModule: invalidateModule2 } = await Promise.resolve().then(() => (init_moduleServer(), exports_moduleServer));
35195
35268
  for (const tsFile of tsFilesToRefresh) {
35196
- const rel = relative23(angularDirAbs, tsFile).replace(/\\/g, "/").replace(/\.[tj]sx?$/, ".js");
35269
+ const rel = relative24(angularDirAbs, tsFile).replace(/\\/g, "/").replace(/\.[tj]sx?$/, ".js");
35197
35270
  const compiledFile = resolvePath4(compiledRoot, rel);
35198
35271
  invalidateModule2(compiledFile);
35199
35272
  }
@@ -35246,7 +35319,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35246
35319
  const entries = await readdir6(dir, { withFileTypes: true });
35247
35320
  const files = [];
35248
35321
  for (const entry of entries) {
35249
- const full = join60(dir, entry.name);
35322
+ const full = join61(dir, entry.name);
35250
35323
  if (entry.isDirectory()) {
35251
35324
  files.push(...await walk(full));
35252
35325
  } else if (entry.isFile() && entry.name.endsWith(".ts") && !entry.name.endsWith(".d.ts")) {
@@ -35348,7 +35421,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35348
35421
  }, getModuleUrl = async (pageFile) => {
35349
35422
  const { invalidateModule: invalidateModule2, warmCache: warmCache2, SRC_URL_PREFIX: SRC_URL_PREFIX3 } = await Promise.resolve().then(() => (init_moduleServer(), exports_moduleServer));
35350
35423
  invalidateModule2(pageFile);
35351
- const rel = relative23(process.cwd(), pageFile).replace(/\\/g, "/");
35424
+ const rel = relative24(process.cwd(), pageFile).replace(/\\/g, "/");
35352
35425
  const url = `${SRC_URL_PREFIX3}${rel}`;
35353
35426
  await warmCache2(url);
35354
35427
  return url;
@@ -35376,7 +35449,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35376
35449
  const pageModuleUrl = await getReactModuleUrl(broadcastTarget);
35377
35450
  if (pageModuleUrl) {
35378
35451
  const serverDuration = Date.now() - startTime;
35379
- state.lastHmrPath = relative23(process.cwd(), primaryFile).replace(/\\/g, "/");
35452
+ state.lastHmrPath = relative24(process.cwd(), primaryFile).replace(/\\/g, "/");
35380
35453
  state.lastHmrFramework = "react";
35381
35454
  broadcastToClients(state, {
35382
35455
  data: {
@@ -35669,8 +35742,8 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35669
35742
  };
35670
35743
  return () => {
35671
35744
  if (!ctx.debouncedPromise) {
35672
- ctx.debouncedPromise = new Promise((resolve53) => {
35673
- ctx.debouncedResolve = resolve53;
35745
+ ctx.debouncedPromise = new Promise((resolve54) => {
35746
+ ctx.debouncedResolve = resolve54;
35674
35747
  });
35675
35748
  }
35676
35749
  if (ctx.debounceTimer)
@@ -35821,7 +35894,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35821
35894
  } = await compileVue2(vueFiles, vueDir, true, getStyleTransformConfig(state.config));
35822
35895
  const serverEntries = [...vueServerPaths];
35823
35896
  const clientEntries = [...vueIndexPaths, ...vueClientPaths];
35824
- const cssOutDir = join60(buildDir, state.resolvedPaths.assetsDir ? basename21(state.resolvedPaths.assetsDir) : "assets", "css");
35897
+ const cssOutDir = join61(buildDir, state.resolvedPaths.assetsDir ? basename21(state.resolvedPaths.assetsDir) : "assets", "css");
35825
35898
  const { serverRoot, serverOutDir } = await computeServerOutPaths(state.resolvedPaths, "vue");
35826
35899
  const serverExternals = await getServerBundleExternals();
35827
35900
  const serverExternalsPlugins = await getServerBundleExternalsPlugins(state.config);
@@ -35881,7 +35954,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35881
35954
  if (vueSpaRoutesBySource.size > 0) {
35882
35955
  const spaManifestEntries = await writeSpaSideManifests(vueSpaRoutesBySource, (pascalName) => {
35883
35956
  const fromManifest = state.manifest[pascalName];
35884
- return typeof fromManifest === "string" && isAbsolute9(fromManifest) && fromManifest.endsWith(".js") ? fromManifest : undefined;
35957
+ return typeof fromManifest === "string" && isAbsolute10(fromManifest) && fromManifest.endsWith(".js") ? fromManifest : undefined;
35885
35958
  });
35886
35959
  Object.assign(state.manifest, spaManifestEntries);
35887
35960
  }
@@ -35951,8 +36024,8 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
35951
36024
  };
35952
36025
  return () => {
35953
36026
  if (!ctx.debouncedPromise) {
35954
- ctx.debouncedPromise = new Promise((resolve53) => {
35955
- ctx.debouncedResolve = resolve53;
36027
+ ctx.debouncedPromise = new Promise((resolve54) => {
36028
+ ctx.debouncedResolve = resolve54;
35956
36029
  });
35957
36030
  }
35958
36031
  if (ctx.debounceTimer)
@@ -36005,7 +36078,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
36005
36078
  const duration = Date.now() - startTime;
36006
36079
  const [primary] = emberFiles;
36007
36080
  if (primary) {
36008
- state.lastHmrPath = relative23(process.cwd(), primary).replace(/\\/g, "/");
36081
+ state.lastHmrPath = relative24(process.cwd(), primary).replace(/\\/g, "/");
36009
36082
  state.lastHmrFramework = "ember";
36010
36083
  logHmrUpdate(primary, "ember", duration);
36011
36084
  }
@@ -36274,7 +36347,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
36274
36347
  const baseName = fileName.replace(/\.vue$/, "");
36275
36348
  const pascalName = toPascal(baseName);
36276
36349
  const vueRoot = config.vueDirectory;
36277
- const hmrId = vueRoot ? relative23(vueRoot, vuePagePath).replace(/\\/g, "/").replace(/\.vue$/, "") : baseName;
36350
+ const hmrId = vueRoot ? relative24(vueRoot, vuePagePath).replace(/\\/g, "/").replace(/\.vue$/, "") : baseName;
36278
36351
  const cssKey = `${pascalName}CSS`;
36279
36352
  const cssUrl = manifest[cssKey] || null;
36280
36353
  const { vueHmrMetadata: vueHmrMetadata2 } = await Promise.resolve().then(() => (init_compileVue(), exports_compileVue));
@@ -36935,7 +37008,7 @@ __export(exports_buildDepVendor, {
36935
37008
  });
36936
37009
  import { mkdirSync as mkdirSync16 } from "fs";
36937
37010
  import { isBuiltin as isBuiltin2 } from "module";
36938
- import { join as join61 } from "path";
37011
+ import { join as join62 } from "path";
36939
37012
  import { rm as rm15 } from "fs/promises";
36940
37013
  var {build: bunBuild9, Glob: Glob10 } = globalThis.Bun;
36941
37014
  var toSafeFileName6 = (specifier) => {
@@ -37093,7 +37166,7 @@ var toSafeFileName6 = (specifier) => {
37093
37166
  }), buildDepVendorPass = async (specifiers, vendorDir, tmpDir) => {
37094
37167
  const entries = await Promise.all(specifiers.map(async (specifier) => {
37095
37168
  const safeName = toSafeFileName6(specifier);
37096
- const entryPath = join61(tmpDir, `${safeName}.ts`);
37169
+ const entryPath = join62(tmpDir, `${safeName}.ts`);
37097
37170
  await Bun.write(entryPath, await generateVendorEntrySource(specifier));
37098
37171
  return { entryPath, specifier };
37099
37172
  }));
@@ -37184,9 +37257,9 @@ var toSafeFileName6 = (specifier) => {
37184
37257
  const { dep: initialSpecs, framework: frameworkRoots } = await scanBareImports(directories, files);
37185
37258
  if (initialSpecs.length === 0 && frameworkRoots.length === 0)
37186
37259
  return {};
37187
- const vendorDir = join61(buildDir, "vendor");
37260
+ const vendorDir = join62(buildDir, "vendor");
37188
37261
  mkdirSync16(vendorDir, { recursive: true });
37189
- const tmpDir = join61(buildDir, "_dep_vendor_tmp");
37262
+ const tmpDir = join62(buildDir, "_dep_vendor_tmp");
37190
37263
  mkdirSync16(tmpDir, { recursive: true });
37191
37264
  const allSpecs = new Set(initialSpecs);
37192
37265
  const alreadyScanned = new Set;
@@ -37286,7 +37359,7 @@ import {
37286
37359
  readFileSync as readFileSync41
37287
37360
  } from "fs";
37288
37361
  import { mkdir as mkdir16, readFile as readFile12, rename as rename7, rm as rm16, writeFile as writeFile13 } from "fs/promises";
37289
- import { basename as basename22, join as join62, resolve as resolve53 } from "path";
37362
+ import { basename as basename22, join as join63, resolve as resolve54 } from "path";
37290
37363
  var CACHE_ROOT2, CACHE_FORMAT_VERSION3 = 1, KEY_LENGTH = 32, LOCKFILES, computeVendorCacheKey = (inputs) => {
37291
37364
  const hash = createHash12("sha256");
37292
37365
  hash.update(String(CACHE_FORMAT_VERSION3));
@@ -37306,14 +37379,14 @@ var CACHE_ROOT2, CACHE_FORMAT_VERSION3 = 1, KEY_LENGTH = 32, LOCKFILES, computeV
37306
37379
  }
37307
37380
  for (const dir of inputs.vendorDirs) {
37308
37381
  hash.update("\x00v");
37309
- hash.update(basename22(resolve53(dir, "..")));
37382
+ hash.update(basename22(resolve54(dir, "..")));
37310
37383
  }
37311
37384
  return hash.digest("hex").slice(0, KEY_LENGTH);
37312
37385
  }, readLockfileHash = (projectRoot = process.cwd()) => {
37313
37386
  const hash = createHash12("sha256");
37314
37387
  let found = false;
37315
37388
  for (const name of LOCKFILES) {
37316
- const path2 = join62(projectRoot, name);
37389
+ const path2 = join63(projectRoot, name);
37317
37390
  if (!existsSync48(path2))
37318
37391
  continue;
37319
37392
  found = true;
@@ -37324,8 +37397,8 @@ var CACHE_ROOT2, CACHE_FORMAT_VERSION3 = 1, KEY_LENGTH = 32, LOCKFILES, computeV
37324
37397
  }, vendorCacheEnabled = () => process.env.ABSOLUTE_DEV_VENDOR_CACHE !== "0", copyTree = (fromDir, toDir) => {
37325
37398
  mkdirSync17(toDir, { recursive: true });
37326
37399
  for (const entry of readdirSync14(fromDir, { withFileTypes: true })) {
37327
- const source = join62(fromDir, entry.name);
37328
- const destination = join62(toDir, entry.name);
37400
+ const source = join63(fromDir, entry.name);
37401
+ const destination = join63(toDir, entry.name);
37329
37402
  if (entry.isDirectory())
37330
37403
  copyTree(source, destination);
37331
37404
  else
@@ -37333,7 +37406,7 @@ var CACHE_ROOT2, CACHE_FORMAT_VERSION3 = 1, KEY_LENGTH = 32, LOCKFILES, computeV
37333
37406
  }
37334
37407
  }, copySlotsInto = (cacheDir2, vendorDirs) => {
37335
37408
  for (const [index, dir] of vendorDirs.entries()) {
37336
- const source = join62(cacheDir2, slotName(index, dir));
37409
+ const source = join63(cacheDir2, slotName(index, dir));
37337
37410
  if (!existsSync48(source)) {
37338
37411
  throw new Error(`missing cached vendor dir ${source}`);
37339
37412
  }
@@ -37343,11 +37416,11 @@ var CACHE_ROOT2, CACHE_FORMAT_VERSION3 = 1, KEY_LENGTH = 32, LOCKFILES, computeV
37343
37416
  for (const [index, dir] of vendorDirs.entries()) {
37344
37417
  if (!existsSync48(dir))
37345
37418
  continue;
37346
- copyTree(dir, join62(stagingDir, slotName(index, dir)));
37419
+ copyTree(dir, join63(stagingDir, slotName(index, dir)));
37347
37420
  }
37348
- }, isVendorCachePayload = (value) => typeof value === "object" && value !== null && typeof Reflect.get(value, "depPaths") === "object", cacheDirFor = (key, projectRoot) => resolve53(projectRoot, CACHE_ROOT2, key), slotName = (index, dir) => `${index}-${basename22(resolve53(dir, ".."))}`, restoreVendorCache = async (key, vendorDirs, projectRoot = process.cwd()) => {
37421
+ }, isVendorCachePayload = (value) => typeof value === "object" && value !== null && typeof Reflect.get(value, "depPaths") === "object", cacheDirFor = (key, projectRoot) => resolve54(projectRoot, CACHE_ROOT2, key), slotName = (index, dir) => `${index}-${basename22(resolve54(dir, ".."))}`, restoreVendorCache = async (key, vendorDirs, projectRoot = process.cwd()) => {
37349
37422
  const cacheDir2 = cacheDirFor(key, projectRoot);
37350
- const payloadPath = join62(cacheDir2, "payload.json");
37423
+ const payloadPath = join63(cacheDir2, "payload.json");
37351
37424
  if (!existsSync48(payloadPath))
37352
37425
  return null;
37353
37426
  try {
@@ -37361,14 +37434,14 @@ var CACHE_ROOT2, CACHE_FORMAT_VERSION3 = 1, KEY_LENGTH = 32, LOCKFILES, computeV
37361
37434
  }
37362
37435
  }, saveVendorCache = async (key, vendorDirs, payload, projectRoot = process.cwd()) => {
37363
37436
  const cacheDir2 = cacheDirFor(key, projectRoot);
37364
- if (existsSync48(join62(cacheDir2, "payload.json")))
37437
+ if (existsSync48(join63(cacheDir2, "payload.json")))
37365
37438
  return;
37366
37439
  const stagingDir = `${cacheDir2}.${process.pid}.tmp`;
37367
37440
  try {
37368
37441
  await rm16(stagingDir, { force: true, recursive: true });
37369
37442
  await mkdir16(stagingDir, { recursive: true });
37370
37443
  copySlotsFrom(stagingDir, vendorDirs);
37371
- await writeFile13(join62(stagingDir, "payload.json"), JSON.stringify(payload));
37444
+ await writeFile13(join63(stagingDir, "payload.json"), JSON.stringify(payload));
37372
37445
  await rm16(cacheDir2, { force: true, recursive: true });
37373
37446
  await rename7(stagingDir, cacheDir2);
37374
37447
  } catch {
@@ -37378,7 +37451,7 @@ var CACHE_ROOT2, CACHE_FORMAT_VERSION3 = 1, KEY_LENGTH = 32, LOCKFILES, computeV
37378
37451
  }
37379
37452
  };
37380
37453
  var init_vendorCache = __esm(() => {
37381
- CACHE_ROOT2 = join62(".absolutejs", "vendor-cache");
37454
+ CACHE_ROOT2 = join63(".absolutejs", "vendor-cache");
37382
37455
  LOCKFILES = [
37383
37456
  "bun.lock",
37384
37457
  "bun.lockb",
@@ -37397,8 +37470,8 @@ __export(exports_devBuild, {
37397
37470
  });
37398
37471
  import { readdir as readdir6 } from "fs/promises";
37399
37472
  import { existsSync as existsSync49, statSync as statSync8 } from "fs";
37400
- import { resolve as resolve54 } from "path";
37401
- var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve54(import.meta.dir, "../dev/client"), collectDepVendorSourceDirs = (config) => {
37473
+ import { resolve as resolve55 } from "path";
37474
+ var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve55(import.meta.dir, "../dev/client"), collectDepVendorSourceDirs = (config) => {
37402
37475
  const configuredDirs = [
37403
37476
  ...collectConfigVendorSourceDirs(config),
37404
37477
  devClientVendorSourceDir()
@@ -37421,7 +37494,7 @@ var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve54(import.meta.d
37421
37494
  return Object.keys(config).length > 0 ? config : null;
37422
37495
  }, reloadConfig = async () => {
37423
37496
  try {
37424
- const configPath2 = resolve54(process.env.ABSOLUTE_CONFIG ?? "absolute.config.ts");
37497
+ const configPath2 = resolve55(process.env.ABSOLUTE_CONFIG ?? "absolute.config.ts");
37425
37498
  const source = await Bun.file(configPath2).text();
37426
37499
  return parseDirectoryConfig(source);
37427
37500
  } catch {
@@ -37536,7 +37609,7 @@ var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve54(import.meta.d
37536
37609
  });
37537
37610
  }
37538
37611
  }, handleCachedReload = async () => {
37539
- const serverMtime = statSync8(resolve54(Bun.main)).mtimeMs;
37612
+ const serverMtime = statSync8(resolve55(Bun.main)).mtimeMs;
37540
37613
  const lastMtime = globalThis.__hmrServerMtime;
37541
37614
  globalThis.__hmrServerMtime = serverMtime;
37542
37615
  const cached = globalThis.__hmrDevResult;
@@ -37577,8 +37650,8 @@ var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve54(import.meta.d
37577
37650
  return true;
37578
37651
  }, resolveAbsoluteVersion2 = async () => {
37579
37652
  const candidates = [
37580
- resolve54(import.meta.dir, "..", "..", "package.json"),
37581
- resolve54(import.meta.dir, "..", "package.json")
37653
+ resolve55(import.meta.dir, "..", "..", "package.json"),
37654
+ resolve55(import.meta.dir, "..", "package.json")
37582
37655
  ];
37583
37656
  const [candidate, ...remaining] = candidates;
37584
37657
  if (!candidate) {
@@ -37604,7 +37677,7 @@ var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve54(import.meta.d
37604
37677
  const entries = await readdir6(vendorDir).catch(() => emptyStringArray);
37605
37678
  await Promise.all(entries.filter((entry) => entry.endsWith(".js")).map(async (entry) => {
37606
37679
  const webPath = `/${framework}/vendor/${entry}`;
37607
- const bytes = await Bun.file(resolve54(vendorDir, entry)).bytes();
37680
+ const bytes = await Bun.file(resolve55(vendorDir, entry)).bytes();
37608
37681
  assetStore.set(webPath, bytes);
37609
37682
  }));
37610
37683
  }, devBuild = async (config) => {
@@ -37790,11 +37863,11 @@ var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve54(import.meta.d
37790
37863
  }
37791
37864
  stepStartedAt = performance.now();
37792
37865
  setBootPhase("build vendor bundles");
37793
- const reactVendorDir = resolve54(state.resolvedPaths.buildDir, "react", "vendor");
37794
- const angularVendorDir = resolve54(state.resolvedPaths.buildDir, "angular", "vendor");
37795
- const svelteVendorDir = resolve54(state.resolvedPaths.buildDir, "svelte", "vendor");
37796
- const vueVendorDir = resolve54(state.resolvedPaths.buildDir, "vue", "vendor");
37797
- const depVendorDir = resolve54(state.resolvedPaths.buildDir, "vendor");
37866
+ const reactVendorDir = resolve55(state.resolvedPaths.buildDir, "react", "vendor");
37867
+ const angularVendorDir = resolve55(state.resolvedPaths.buildDir, "angular", "vendor");
37868
+ const svelteVendorDir = resolve55(state.resolvedPaths.buildDir, "svelte", "vendor");
37869
+ const vueVendorDir = resolve55(state.resolvedPaths.buildDir, "vue", "vendor");
37870
+ const depVendorDir = resolve55(state.resolvedPaths.buildDir, "vendor");
37798
37871
  const { buildDepVendor: buildDepVendor2 } = await Promise.resolve().then(() => (init_buildDepVendor(), exports_buildDepVendor));
37799
37872
  const activeVendorDirs = [
37800
37873
  config.reactDirectory ? reactVendorDir : null,
@@ -37917,7 +37990,7 @@ var FRAMEWORK_DIR_KEYS, devClientVendorSourceDir = () => resolve54(import.meta.d
37917
37990
  manifest
37918
37991
  };
37919
37992
  globalThis.__hmrDevResult = result;
37920
- globalThis.__hmrServerMtime = statSync8(resolve54(Bun.main)).mtimeMs;
37993
+ globalThis.__hmrServerMtime = statSync8(resolve55(Bun.main)).mtimeMs;
37921
37994
  return result;
37922
37995
  };
37923
37996
  var init_devBuild = __esm(() => {
@@ -37958,5 +38031,5 @@ export {
37958
38031
  devBuild
37959
38032
  };
37960
38033
 
37961
- //# debugId=B3A32B3F6443979364756E2164756E21
38034
+ //# debugId=0E877E48913E5F9364756E2164756E21
37962
38035
  //# sourceMappingURL=build.js.map