@thestatic-tv/dcl-sdk 2.2.3 → 2.2.5

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/index.js CHANGED
@@ -900,12 +900,15 @@ var GuideUIModule = class {
900
900
  if (data.videoMap) {
901
901
  for (const [slug, video] of Object.entries(data.videoMap)) {
902
902
  const v = video;
903
+ const src = v.src || v.liveStreamUrl || "";
903
904
  const mapped = {
904
905
  id: v.id || slug,
905
906
  name: v.name || v.title || "Unknown",
906
- src: v.src || v.liveStreamUrl || "",
907
- isLive: v.isLive === true || v.type === "live",
908
- isCreator: v.isCreator || v.type === "live",
907
+ src,
908
+ // isLive = ONLY true if backend says isLive:true (actually streaming)
909
+ isLive: v.isLive === true,
910
+ // isCreator = creator channel (type === 'live' means creator, not actually live)
911
+ isCreator: v.isCreator === true || v.type === "live",
909
912
  channelId: v.channelId || slug,
910
913
  duration: v.duration,
911
914
  requiresAuth: v.requiresAuth
@@ -919,6 +922,7 @@ var GuideUIModule = class {
919
922
  const playlists = [];
920
923
  if (data.featuredPlaylists) {
921
924
  for (const pl of data.featuredPlaylists) {
925
+ if (pl.name === "NODES") continue;
922
926
  playlists.push({
923
927
  name: pl.name,
924
928
  videos: (pl.videos || []).map((v) => ({
@@ -934,6 +938,10 @@ var GuideUIModule = class {
934
938
  });
935
939
  }
936
940
  }
941
+ const nodeVideos = videos.filter((v) => v.isCreator);
942
+ if (nodeVideos.length > 0) {
943
+ playlists.push({ name: "NODES", videos: nodeVideos });
944
+ }
937
945
  this.videos = videos;
938
946
  this.liveVideos = liveVideos;
939
947
  this.featuredPlaylists = playlists;
@@ -1444,6 +1452,7 @@ var ChatUIModule = class {
1444
1452
  this.config = config;
1445
1453
  this.position = config.position || "right";
1446
1454
  this.fontScale = config.fontScale || 1;
1455
+ console.log("[StaticTV Chat] Initialized with position:", this.position);
1447
1456
  }
1448
1457
  /**
1449
1458
  * Initialize the chat system
@@ -1736,14 +1745,15 @@ var ChatUIModule = class {
1736
1745
  }
1737
1746
  }
1738
1747
  getPositionStyle() {
1748
+ console.log("[StaticTV Chat] getPositionStyle called, position:", this.position);
1739
1749
  switch (this.position) {
1740
1750
  case "left":
1741
- return { top: 50, left: 10 };
1751
+ return { bottom: 55, left: 20 };
1742
1752
  case "center":
1743
- return { top: 50, left: 400 };
1753
+ return { bottom: 55, left: 400 };
1744
1754
  case "right":
1745
1755
  default:
1746
- return { top: 50, right: 10 };
1756
+ return { bottom: 55, right: 20 };
1747
1757
  }
1748
1758
  }
1749
1759
  renderHeader() {
package/dist/index.mjs CHANGED
@@ -860,12 +860,15 @@ var GuideUIModule = class {
860
860
  if (data.videoMap) {
861
861
  for (const [slug, video] of Object.entries(data.videoMap)) {
862
862
  const v = video;
863
+ const src = v.src || v.liveStreamUrl || "";
863
864
  const mapped = {
864
865
  id: v.id || slug,
865
866
  name: v.name || v.title || "Unknown",
866
- src: v.src || v.liveStreamUrl || "",
867
- isLive: v.isLive === true || v.type === "live",
868
- isCreator: v.isCreator || v.type === "live",
867
+ src,
868
+ // isLive = ONLY true if backend says isLive:true (actually streaming)
869
+ isLive: v.isLive === true,
870
+ // isCreator = creator channel (type === 'live' means creator, not actually live)
871
+ isCreator: v.isCreator === true || v.type === "live",
869
872
  channelId: v.channelId || slug,
870
873
  duration: v.duration,
871
874
  requiresAuth: v.requiresAuth
@@ -879,6 +882,7 @@ var GuideUIModule = class {
879
882
  const playlists = [];
880
883
  if (data.featuredPlaylists) {
881
884
  for (const pl of data.featuredPlaylists) {
885
+ if (pl.name === "NODES") continue;
882
886
  playlists.push({
883
887
  name: pl.name,
884
888
  videos: (pl.videos || []).map((v) => ({
@@ -894,6 +898,10 @@ var GuideUIModule = class {
894
898
  });
895
899
  }
896
900
  }
901
+ const nodeVideos = videos.filter((v) => v.isCreator);
902
+ if (nodeVideos.length > 0) {
903
+ playlists.push({ name: "NODES", videos: nodeVideos });
904
+ }
897
905
  this.videos = videos;
898
906
  this.liveVideos = liveVideos;
899
907
  this.featuredPlaylists = playlists;
@@ -1404,6 +1412,7 @@ var ChatUIModule = class {
1404
1412
  this.config = config;
1405
1413
  this.position = config.position || "right";
1406
1414
  this.fontScale = config.fontScale || 1;
1415
+ console.log("[StaticTV Chat] Initialized with position:", this.position);
1407
1416
  }
1408
1417
  /**
1409
1418
  * Initialize the chat system
@@ -1696,14 +1705,15 @@ var ChatUIModule = class {
1696
1705
  }
1697
1706
  }
1698
1707
  getPositionStyle() {
1708
+ console.log("[StaticTV Chat] getPositionStyle called, position:", this.position);
1699
1709
  switch (this.position) {
1700
1710
  case "left":
1701
- return { top: 50, left: 10 };
1711
+ return { bottom: 55, left: 20 };
1702
1712
  case "center":
1703
- return { top: 50, left: 400 };
1713
+ return { bottom: 55, left: 400 };
1704
1714
  case "right":
1705
1715
  default:
1706
- return { top: 50, right: 10 };
1716
+ return { bottom: 55, right: 20 };
1707
1717
  }
1708
1718
  }
1709
1719
  renderHeader() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thestatic-tv/dcl-sdk",
3
- "version": "2.2.3",
3
+ "version": "2.2.5",
4
4
  "description": "Connect your Decentraland scene to thestatic.tv - full channel lineup, metrics tracking, and interactions",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",