@trops/dash-core 0.1.219 → 0.1.220

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.
@@ -32193,23 +32193,24 @@ async function installThemeFromRegistry$1(win, appId, packageName) {
32193
32193
  `${TAG} [1/5 Package Lookup] resolved scope="${pkg.scope}" name="${pkg.name}" version="${pkg.version || "1.0.0"}"`,
32194
32194
  );
32195
32195
 
32196
- // Stage 2: URL construction — strip @ from scope for URL path
32196
+ // Stage 2: URL construction — keep scope as-is (encodeURIComponent handles @)
32197
32197
  const registryBaseUrl =
32198
32198
  process.env.DASH_REGISTRY_API_URL ||
32199
32199
  "https://main.d919rwhuzp7rj.amplifyapp.com";
32200
- const urlScope = (pkg.scope || "").replace(/^@/, "");
32200
+ const urlScope = pkg.scope || "";
32201
32201
  const urlName = pkg.name || "";
32202
32202
  const urlVersion = pkg.version || "1.0.0";
32203
- if (!urlScope || !urlName) {
32203
+ if (!urlName) {
32204
32204
  console.log(
32205
- `${TAG} [2/5 URL Construction] FAIL — missing scope="${urlScope}" or name="${urlName}"`,
32205
+ `${TAG} [2/5 URL Construction] FAIL — missing name="${urlName}"`,
32206
32206
  );
32207
32207
  return {
32208
32208
  success: false,
32209
- error: `Download failed: package is missing required fields (scope: "${pkg.scope || ""}", name: "${pkg.name || ""}"). The registry entry may be corrupt.`,
32209
+ error: `Download failed: package is missing a name field. The registry entry may be corrupt.`,
32210
32210
  };
32211
32211
  }
32212
- const downloadUrl = `${registryBaseUrl}/api/packages/${encodeURIComponent(urlScope)}/${encodeURIComponent(urlName)}/download?version=${encodeURIComponent(urlVersion)}`;
32212
+ const scopePath = urlScope ? `${encodeURIComponent(urlScope)}/` : "";
32213
+ const downloadUrl = `${registryBaseUrl}/api/packages/${scopePath}${encodeURIComponent(urlName)}/download?version=${encodeURIComponent(urlVersion)}`;
32213
32214
  console.log(`${TAG} [2/5 URL Construction] url="${downloadUrl}"`);
32214
32215
 
32215
32216
  // Stage 3: Download