pxt-core 8.5.7 → 8.5.9

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/built/pxt.js CHANGED
@@ -103491,7 +103491,7 @@ var pxt;
103491
103491
  const DEV_BACKEND_PROD = "https://www.makecode.com";
103492
103492
  const DEV_BACKEND_STAGING = "https://staging.pxt.io";
103493
103493
  const DEV_BACKEND_LOCALHOST = "http://localhost:8080";
103494
- cloud.DEV_BACKEND = DEV_BACKEND_PROD;
103494
+ cloud.DEV_BACKEND = DEV_BACKEND_STAGING;
103495
103495
  function devBackendType() {
103496
103496
  if (cloud.DEV_BACKEND === DEV_BACKEND_PROD)
103497
103497
  return "prod";
@@ -111404,6 +111404,13 @@ var pxt;
111404
111404
  (function (pxt) {
111405
111405
  var multiplayer;
111406
111406
  (function (multiplayer) {
111407
+ let MultiplayerDevBackendType;
111408
+ (function (MultiplayerDevBackendType) {
111409
+ MultiplayerDevBackendType[MultiplayerDevBackendType["PROD"] = 0] = "PROD";
111410
+ MultiplayerDevBackendType[MultiplayerDevBackendType["STAGING"] = 1] = "STAGING";
111411
+ MultiplayerDevBackendType[MultiplayerDevBackendType["LOCAL"] = 2] = "LOCAL";
111412
+ })(MultiplayerDevBackendType || (MultiplayerDevBackendType = {}));
111413
+ let MULTIPLAYER_DEV_BACKEND_TYPE = MultiplayerDevBackendType.STAGING;
111407
111414
  multiplayer.SHORT_LINKS = {
111408
111415
  PROD: "https://aka.ms/a9",
111409
111416
  PROD_BETA: "https://aka.ms/a9b",
@@ -111413,12 +111420,12 @@ var pxt;
111413
111420
  };
111414
111421
  multiplayer.SHORT_LINK = () => {
111415
111422
  if (pxt.BrowserUtils.isLocalHostDev()) {
111416
- switch (pxt.cloud.devBackendType()) {
111417
- case "prod":
111423
+ switch (MULTIPLAYER_DEV_BACKEND_TYPE) {
111424
+ case MultiplayerDevBackendType.PROD:
111418
111425
  return multiplayer.SHORT_LINKS.PROD_BETA;
111419
- case "staging":
111426
+ case MultiplayerDevBackendType.STAGING:
111420
111427
  return multiplayer.SHORT_LINKS.STAGING_BETA;
111421
- case "localhost":
111428
+ case MultiplayerDevBackendType.LOCAL:
111422
111429
  return multiplayer.SHORT_LINKS.LOCAL;
111423
111430
  }
111424
111431
  }
@@ -117267,6 +117274,7 @@ var pxt;
117267
117274
  const isProject = dep.id === "this";
117268
117275
  const images = this.readImages(dep.parseJRes(), isProject);
117269
117276
  for (const image of images) {
117277
+ image.meta.package = dep.id;
117270
117278
  if (image.type === "tile" /* AssetType.Tile */) {
117271
117279
  if (isProject) {
117272
117280
  this.state.tiles.add(image);
@@ -117308,7 +117316,8 @@ var pxt;
117308
117316
  id: tm.id,
117309
117317
  meta: {
117310
117318
  // For tilemaps, use the id as the display name for backwards compat
117311
- displayName: tm.displayName || tm.id
117319
+ displayName: tm.displayName || tm.id,
117320
+ package: pack.id
117312
117321
  },
117313
117322
  data: decodeTilemap(tm, id => this.resolveTile(id))
117314
117323
  });
package/built/pxtlib.d.ts CHANGED
@@ -2713,6 +2713,7 @@ declare namespace pxt {
2713
2713
  tags?: string[];
2714
2714
  blockIDs?: string[];
2715
2715
  temporaryInfo?: TemporaryAssetInfo;
2716
+ package?: string;
2716
2717
  }
2717
2718
  export interface TemporaryAssetInfo {
2718
2719
  blockId: string;
package/built/pxtlib.js CHANGED
@@ -5805,7 +5805,7 @@ var pxt;
5805
5805
  const DEV_BACKEND_PROD = "https://www.makecode.com";
5806
5806
  const DEV_BACKEND_STAGING = "https://staging.pxt.io";
5807
5807
  const DEV_BACKEND_LOCALHOST = "http://localhost:8080";
5808
- cloud.DEV_BACKEND = DEV_BACKEND_PROD;
5808
+ cloud.DEV_BACKEND = DEV_BACKEND_STAGING;
5809
5809
  function devBackendType() {
5810
5810
  if (cloud.DEV_BACKEND === DEV_BACKEND_PROD)
5811
5811
  return "prod";
@@ -13718,6 +13718,13 @@ var pxt;
13718
13718
  (function (pxt) {
13719
13719
  var multiplayer;
13720
13720
  (function (multiplayer) {
13721
+ let MultiplayerDevBackendType;
13722
+ (function (MultiplayerDevBackendType) {
13723
+ MultiplayerDevBackendType[MultiplayerDevBackendType["PROD"] = 0] = "PROD";
13724
+ MultiplayerDevBackendType[MultiplayerDevBackendType["STAGING"] = 1] = "STAGING";
13725
+ MultiplayerDevBackendType[MultiplayerDevBackendType["LOCAL"] = 2] = "LOCAL";
13726
+ })(MultiplayerDevBackendType || (MultiplayerDevBackendType = {}));
13727
+ let MULTIPLAYER_DEV_BACKEND_TYPE = MultiplayerDevBackendType.STAGING;
13721
13728
  multiplayer.SHORT_LINKS = {
13722
13729
  PROD: "https://aka.ms/a9",
13723
13730
  PROD_BETA: "https://aka.ms/a9b",
@@ -13727,12 +13734,12 @@ var pxt;
13727
13734
  };
13728
13735
  multiplayer.SHORT_LINK = () => {
13729
13736
  if (pxt.BrowserUtils.isLocalHostDev()) {
13730
- switch (pxt.cloud.devBackendType()) {
13731
- case "prod":
13737
+ switch (MULTIPLAYER_DEV_BACKEND_TYPE) {
13738
+ case MultiplayerDevBackendType.PROD:
13732
13739
  return multiplayer.SHORT_LINKS.PROD_BETA;
13733
- case "staging":
13740
+ case MultiplayerDevBackendType.STAGING:
13734
13741
  return multiplayer.SHORT_LINKS.STAGING_BETA;
13735
- case "localhost":
13742
+ case MultiplayerDevBackendType.LOCAL:
13736
13743
  return multiplayer.SHORT_LINKS.LOCAL;
13737
13744
  }
13738
13745
  }
@@ -19581,6 +19588,7 @@ var pxt;
19581
19588
  const isProject = dep.id === "this";
19582
19589
  const images = this.readImages(dep.parseJRes(), isProject);
19583
19590
  for (const image of images) {
19591
+ image.meta.package = dep.id;
19584
19592
  if (image.type === "tile" /* AssetType.Tile */) {
19585
19593
  if (isProject) {
19586
19594
  this.state.tiles.add(image);
@@ -19622,7 +19630,8 @@ var pxt;
19622
19630
  id: tm.id,
19623
19631
  meta: {
19624
19632
  // For tilemaps, use the id as the display name for backwards compat
19625
- displayName: tm.displayName || tm.id
19633
+ displayName: tm.displayName || tm.id,
19634
+ package: pack.id
19626
19635
  },
19627
19636
  data: decodeTilemap(tm, id => this.resolveTile(id))
19628
19637
  });