@absolutejs/absolute 0.19.0-beta.1045 → 0.19.0-beta.1047

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.
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  var __require = import.meta.require;
3
3
 
4
- // .angular-partial-tmp-uw7ILL/src/core/streamingSlotRegistrar.ts
4
+ // .angular-partial-tmp-ldY0NI/src/core/streamingSlotRegistrar.ts
5
5
  var STREAMING_SLOT_REGISTRAR_KEY = Symbol.for("absolutejs.streamingSlotRegistrar");
6
6
  var STREAMING_SLOT_WARNING_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotWarningController");
7
7
  var STREAMING_SLOT_COLLECTION_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotCollectionController");
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  var __require = import.meta.require;
3
3
 
4
- // .angular-partial-tmp-uw7ILL/src/core/streamingSlotRegistrar.ts
4
+ // .angular-partial-tmp-ldY0NI/src/core/streamingSlotRegistrar.ts
5
5
  var STREAMING_SLOT_REGISTRAR_KEY = Symbol.for("absolutejs.streamingSlotRegistrar");
6
6
  var STREAMING_SLOT_WARNING_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotWarningController");
7
7
  var STREAMING_SLOT_COLLECTION_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotCollectionController");
@@ -48,7 +48,7 @@ var warnMissingStreamingSlotCollector = (primitiveName) => {
48
48
  getWarningController()?.maybeWarn(primitiveName);
49
49
  };
50
50
 
51
- // .angular-partial-tmp-uw7ILL/src/core/streamingSlotRegistry.ts
51
+ // .angular-partial-tmp-ldY0NI/src/core/streamingSlotRegistry.ts
52
52
  var STREAMING_SLOT_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotAsyncLocalStorage");
53
53
  var isObjectRecord2 = (value) => Boolean(value) && typeof value === "object";
54
54
  var isAsyncLocalStorage = (value) => isObjectRecord2(value) && ("getStore" in value) && typeof value.getStore === "function" && ("run" in value) && typeof value.run === "function";
package/dist/cli/index.js CHANGED
@@ -173829,13 +173829,30 @@ var SLOW_MS = 100, VERY_SLOW_MS = 500, HTTP_SERVER_ERROR = 500, HTTP_CLIENT_ERRO
173829
173829
  const fixed = TIME_WIDTH + METHOD_WIDTH + STATUS_WIDTH + MS_WIDTH + SIZE_WIDTH2;
173830
173830
  const gaps = COLUMN_GAP.length * (COLUMN_COUNT - 1);
173831
173831
  return Math.max(MIN_PATH_WIDTH, totalWidth - fixed - gaps);
173832
+ }, parseTiming = (headers) => {
173833
+ const key = Object.keys(headers).find((name) => name.toLowerCase() === "server-timing");
173834
+ const value = key === undefined ? undefined : headers[key];
173835
+ if (value === undefined)
173836
+ return [];
173837
+ return value.split(",").map((part) => {
173838
+ const [name] = part.trim().split(";");
173839
+ const match = part.match(/dur=([0-9.]+)/);
173840
+ return {
173841
+ dur: match ? Number(match[1]) : null,
173842
+ name: (name ?? "").trim()
173843
+ };
173844
+ }).filter((phase) => phase.dur !== null && Number.isFinite(phase.dur));
173832
173845
  }, requestDetail = (record) => {
173833
173846
  const size = record.size === null ? "\u2014" : formatBytes(record.size);
173834
173847
  const lines = [
173835
173848
  `${colors.bold}${record.method} ${record.path}${record.query}${colors.reset}`,
173836
- `${colors.dim}status${colors.reset} ${statusColor3(record.status)}${record.status}${colors.reset} ${colors.dim}took${colors.reset} ${Math.round(record.durationMs)}ms ${colors.dim}size${colors.reset} ${size} ${colors.dim}kind${colors.reset} ${record.kind}`,
173837
- `${colors.dim}request headers${colors.reset}`
173849
+ `${colors.dim}status${colors.reset} ${statusColor3(record.status)}${record.status}${colors.reset} ${colors.dim}took${colors.reset} ${Math.round(record.durationMs)}ms ${colors.dim}size${colors.reset} ${size} ${colors.dim}kind${colors.reset} ${record.kind}`
173838
173850
  ];
173851
+ const timing = parseTiming(record.responseHeaders);
173852
+ if (timing.length > 0) {
173853
+ lines.push(`${colors.dim}phases${colors.reset} ${timing.map((phase) => `${phase.name} ${phase.dur.toFixed(1)}ms`).join(" \xB7 ")}`);
173854
+ }
173855
+ lines.push(`${colors.dim}request headers${colors.reset}`);
173839
173856
  for (const [key, value] of Object.entries(record.requestHeaders)) {
173840
173857
  lines.push(` ${colors.cyan}${key}${colors.reset} ${value}`);
173841
173858
  }
@@ -173872,7 +173889,7 @@ __export(exports_api, {
173872
173889
  runApi: () => runApi
173873
173890
  });
173874
173891
  var METHOD_COLOR2, HTTP_METHODS, printDim2 = (message) => process.stdout.write(`${colors.dim}${message}${colors.reset}
173875
- `), isInternal = (path) => path.startsWith("/__absolute") || path.startsWith("/openapi") || path.startsWith("/hmr"), fetchSpec = async (url) => {
173892
+ `), isInternal = (path) => path.startsWith("/__absolute") || path.startsWith("/openapi") || path.startsWith("/hmr") || path.startsWith("/_") || path.startsWith("/@") || path.startsWith("/.") || path.startsWith("/chunk-") || path.startsWith("/node_modules"), fetchSpec = async (url) => {
173876
173893
  try {
173877
173894
  const response = await fetch(`${url}openapi/json`);
173878
173895
  if (!response.ok)
@@ -175382,7 +175399,7 @@ var cliTag4 = (color, message) => `\x1B[2m${formatTimestamp()}\x1B[0m ${color}[c
175382
175399
  if (!entry)
175383
175400
  return null;
175384
175401
  return join27(packageDir, entry);
175385
- }, collectRuntimeRewriteRoots = (distDir) => collectFiles2(distDir).filter((filePath) => isRuntimeJsFile(filePath) && !isNodeModulesPath(filePath)), toTopLevelPackage = (specifier) => specifier.split("/").slice(0, specifier.startsWith("@") ? 2 : 1).join("/"), copyChunkReferencedPackages = (distDir, seen) => {
175402
+ }, collectRuntimeRewriteRoots = (distDir) => collectFiles2(distDir).filter((filePath) => isRuntimeJsFile(filePath) && !isNodeModulesPath(filePath)), toTopLevelPackage = (specifier) => specifier.split("/").slice(0, specifier.startsWith("@") ? 2 : 1).join("/"), FRAMEWORK_PACKAGE_NAME = "@absolutejs/absolute", copyChunkReferencedPackages = (distDir, seen) => {
175386
175403
  for (const filePath of collectRuntimeRewriteRoots(distDir)) {
175387
175404
  const source = readFileSync28(filePath, "utf-8");
175388
175405
  for (const match of source.matchAll(MODULE_SPECIFIER_RE)) {
@@ -175390,7 +175407,10 @@ var cliTag4 = (color, message) => `\x1B[2m${formatTimestamp()}\x1B[0m ${color}[c
175390
175407
  if (!specifier || specifier.startsWith(".") || specifier.startsWith("/") || specifier.startsWith("#") || specifier.startsWith("node:") || specifier.startsWith("bun:")) {
175391
175408
  continue;
175392
175409
  }
175393
- copyPackageToBuild(toTopLevelPackage(specifier), distDir, seen);
175410
+ const packageName = toTopLevelPackage(specifier);
175411
+ if (packageName === FRAMEWORK_PACKAGE_NAME)
175412
+ continue;
175413
+ copyPackageToBuild(packageName, distDir, seen);
175394
175414
  }
175395
175415
  }
175396
175416
  }, rewriteRuntimeModuleSpecifiers = (distDir) => {