@thestatic-tv/dcl-sdk 2.11.2 → 2.12.0

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
@@ -1323,7 +1323,7 @@ async function signedRequest(url, init = {}) {
1323
1323
  }
1324
1324
 
1325
1325
  // src/ui/guide-ui.tsx
1326
- var import_react_ecs2 = __toESM(require("@dcl/sdk/react-ecs"));
1326
+ var import_react_ecs3 = __toESM(require("@dcl/sdk/react-ecs"));
1327
1327
  var import_math3 = require("@dcl/sdk/math");
1328
1328
  var import_RestrictedActions2 = require("~system/RestrictedActions");
1329
1329
 
@@ -1566,6 +1566,106 @@ function truncateText(text, maxLength) {
1566
1566
  return text.substring(0, maxLength - 3) + "...";
1567
1567
  }
1568
1568
 
1569
+ // src/ui/toolbar-button.ts
1570
+ var import_react_ecs2 = __toESM(require("@dcl/sdk/react-ecs"));
1571
+
1572
+ // src/ui/toolbar.ts
1573
+ var TOOLBAR = { edge: 20, gap: 10, buttonWidth: 100, buttonHeight: 45, bottom: 10 };
1574
+ var COLUMN_SLOTS = 5;
1575
+ function platformOf(answer) {
1576
+ const raw = answer?.platform;
1577
+ if (typeof raw !== "string") return "unknown";
1578
+ const p = raw.trim().toLowerCase();
1579
+ return p === "desktop" || p === "mobile" || p === "vr" || p === "web" ? p : "unknown";
1580
+ }
1581
+ function isPhonePlatform(platform) {
1582
+ return platform === "mobile";
1583
+ }
1584
+ var scaled = (value, uiScale) => Math.round(value * uiScale);
1585
+ function rowRight(slot, uiScale = 1) {
1586
+ return TOOLBAR.edge + slot * (scaled(TOOLBAR.buttonWidth, uiScale) + TOOLBAR.gap);
1587
+ }
1588
+ function columnSlot(slot, uiScale = 1) {
1589
+ const h = scaled(TOOLBAR.buttonHeight, uiScale);
1590
+ return {
1591
+ right: TOOLBAR.edge,
1592
+ boxHeight: COLUMN_SLOTS * h + (COLUMN_SLOTS - 1) * TOOLBAR.gap,
1593
+ above: Math.max(0, slot) * (h + TOOLBAR.gap)
1594
+ };
1595
+ }
1596
+ function panelRight(phone, desktopRight, uiScale = 1) {
1597
+ return phone ? TOOLBAR.edge + scaled(TOOLBAR.buttonWidth, uiScale) + TOOLBAR.gap : desktopRight;
1598
+ }
1599
+ var DESKTOP_CLOSES = { guide: ["admin"], admin: ["guide"] };
1600
+ function panelsToClose(opened, registered, phone) {
1601
+ if (phone) return registered.filter((name) => name !== opened);
1602
+ const closes = DESKTOP_CLOSES[opened] ?? [];
1603
+ return registered.filter((name) => closes.includes(name));
1604
+ }
1605
+ var PanelRules = class {
1606
+ constructor(phone) {
1607
+ this.hides = /* @__PURE__ */ new Map();
1608
+ this.phone = phone;
1609
+ }
1610
+ /** Register (or replace) a panel; its hide runs when another panel opens and the rule says so */
1611
+ register(name, hide) {
1612
+ this.hides.set(name, hide);
1613
+ }
1614
+ /** A panel opened: close the ones the rule names. One failing hide does not stop the rest. */
1615
+ opened(name) {
1616
+ for (const other of panelsToClose(name, [...this.hides.keys()], this.phone())) {
1617
+ try {
1618
+ this.hides.get(other)?.();
1619
+ } catch {
1620
+ }
1621
+ }
1622
+ }
1623
+ get names() {
1624
+ return [...this.hides.keys()];
1625
+ }
1626
+ };
1627
+
1628
+ // src/ui/toolbar-button.ts
1629
+ function toolbarButton(slot, props, phone, uiScale = 1) {
1630
+ const width = Math.round(TOOLBAR.buttonWidth * uiScale);
1631
+ const height = Math.round(TOOLBAR.buttonHeight * uiScale);
1632
+ if (!phone) {
1633
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1634
+ ...props,
1635
+ uiTransform: {
1636
+ positionType: "absolute",
1637
+ position: { right: rowRight(slot, uiScale), bottom: TOOLBAR.bottom },
1638
+ width,
1639
+ height,
1640
+ ...props.uiTransform
1641
+ }
1642
+ });
1643
+ }
1644
+ const place = columnSlot(slot, uiScale);
1645
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1646
+ uiTransform: {
1647
+ positionType: "absolute",
1648
+ position: { right: place.right, top: 0 },
1649
+ width,
1650
+ height: "100%",
1651
+ flexDirection: "column",
1652
+ justifyContent: "center"
1653
+ },
1654
+ children: [
1655
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1656
+ uiTransform: { width, height: place.boxHeight, flexDirection: "column", flexShrink: 0 },
1657
+ children: [
1658
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, { uiTransform: { width, height: place.above, flexShrink: 0 } }),
1659
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1660
+ ...props,
1661
+ uiTransform: { width, height, flexShrink: 0, ...props.uiTransform }
1662
+ })
1663
+ ]
1664
+ })
1665
+ ]
1666
+ });
1667
+ }
1668
+
1569
1669
  // src/ui/guide-ui.tsx
1570
1670
  function withLock(mapped, v, fallback) {
1571
1671
  if (v.locked !== true) return mapped;
@@ -1601,7 +1701,7 @@ var GuideUIModule = class {
1601
1701
  if (this.client.isVisitorBlocked) return null;
1602
1702
  const windowW = UI_DIMENSIONS.guide.width;
1603
1703
  const windowH = UI_DIMENSIONS.guide.height;
1604
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1704
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1605
1705
  key: `guide-root-${this.client.uiScale}`,
1606
1706
  uiTransform: {
1607
1707
  width: "100%",
@@ -1613,13 +1713,14 @@ var GuideUIModule = class {
1613
1713
  this.renderToggleButton(),
1614
1714
  // Render panel when visible - Guide positioned relative to Chat's scaled width
1615
1715
  // Guide.right = Chat.right + Chat.scaledWidth + gap (10px)
1616
- this._isVisible ? import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1716
+ this._isVisible ? import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1617
1717
  key: `guide-panel-${this.client.uiScale}`,
1618
1718
  uiTransform: {
1619
1719
  width: windowW,
1620
1720
  height: windowH,
1621
1721
  positionType: "absolute",
1622
- position: { bottom: UI_DIMENSIONS.guide.bottom, right: UI_DIMENSIONS.chat.right + this.s(UI_DIMENSIONS.chat.width) + 10 },
1722
+ // On a phone, left of the toolbar's column (2.12.0); elsewhere left of the chat panel, as before
1723
+ position: { bottom: UI_DIMENSIONS.guide.bottom, right: this.client.panelRight(UI_DIMENSIONS.chat.right + this.s(UI_DIMENSIONS.chat.width) + 10) },
1623
1724
  flexDirection: "row",
1624
1725
  border: { top: 2, bottom: 2, left: 2, right: 2 },
1625
1726
  borderColor: THEME.colors.panelBorder
@@ -1651,7 +1752,7 @@ var GuideUIModule = class {
1651
1752
  */
1652
1753
  show() {
1653
1754
  if (this._isVisible) return;
1654
- this.client.closeOtherPanels("guide");
1755
+ this.client.panelOpened("guide");
1655
1756
  this._isVisible = true;
1656
1757
  this.fetchGuideData().catch(() => {
1657
1758
  });
@@ -1829,7 +1930,7 @@ var GuideUIModule = class {
1829
1930
  const nodesPlaylist = this.featuredPlaylists.find((p) => p.name === "NODES");
1830
1931
  const nodesCount = nodesPlaylist ? nodesPlaylist.videos.filter((v) => v.isCreator).length : 0;
1831
1932
  const displayedPlaylists = this.featuredPlaylists.filter((p) => p.name !== "NODES").slice(0, 6);
1832
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1933
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1833
1934
  uiTransform: {
1834
1935
  width: sidebarW,
1835
1936
  minWidth: sidebarW,
@@ -1843,11 +1944,11 @@ var GuideUIModule = class {
1843
1944
  uiBackground: { color: import_math3.Color4.create(0, 0, 0, 0.4) },
1844
1945
  children: [
1845
1946
  // Header & Search
1846
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1947
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1847
1948
  uiTransform: { width: "100%", flexDirection: "column", padding: 10 },
1848
1949
  children: [
1849
1950
  // Title row
1850
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1951
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1851
1952
  uiTransform: {
1852
1953
  width: "100%",
1853
1954
  height: this.s(40),
@@ -1857,7 +1958,7 @@ var GuideUIModule = class {
1857
1958
  },
1858
1959
  children: [
1859
1960
  // Title
1860
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1961
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1861
1962
  uiText: {
1862
1963
  value: "THE STATIC TV",
1863
1964
  fontSize: this.s(UI_DIMENSIONS.guide.sidebar.headerSize),
@@ -1868,7 +1969,7 @@ var GuideUIModule = class {
1868
1969
  ]
1869
1970
  }),
1870
1971
  // Random Signal button
1871
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1972
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1872
1973
  uiTransform: {
1873
1974
  width: "100%",
1874
1975
  height: this.s(40),
@@ -1886,13 +1987,13 @@ var GuideUIModule = class {
1886
1987
  }
1887
1988
  },
1888
1989
  children: [
1889
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1990
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1890
1991
  uiText: { value: ">> RANDOM SIGNAL <<", fontSize: this.s(14), color: THEME.colors.cyan }
1891
1992
  })
1892
1993
  ]
1893
1994
  }),
1894
1995
  // Search input
1895
- import_react_ecs2.default.createElement(import_react_ecs2.Input, {
1996
+ import_react_ecs3.default.createElement(import_react_ecs3.Input, {
1896
1997
  placeholder: "SCAN FREQ...",
1897
1998
  fontSize: this.s(UI_DIMENSIONS.guide.sidebar.fontSize),
1898
1999
  uiTransform: {
@@ -1912,11 +2013,11 @@ var GuideUIModule = class {
1912
2013
  ]
1913
2014
  }),
1914
2015
  // Menu items
1915
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2016
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1916
2017
  uiTransform: { flexGrow: 1, flexDirection: "column", width: "100%", padding: { top: 5 } },
1917
2018
  children: [
1918
2019
  // Section header
1919
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2020
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1920
2021
  uiTransform: { padding: { left: 10, bottom: 8, top: 5 } },
1921
2022
  uiText: { value: "GLOBAL NETWORK", fontSize: this.s(12), color: THEME.colors.cyan }
1922
2023
  }),
@@ -1925,12 +2026,12 @@ var GuideUIModule = class {
1925
2026
  this.renderMenuButton("SIGNALS", signalCount, THEME.colors.white, void 0, "VODS & RECORDINGS"),
1926
2027
  this.renderMenuButton("NODES", nodesCount, THEME.colors.magenta, void 0, "CHANNELS & CREATORS"),
1927
2028
  // Divider
1928
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2029
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1929
2030
  uiTransform: { height: 1, width: "90%", margin: { top: 12, bottom: 8, left: 5 } },
1930
2031
  uiBackground: { color: THEME.colors.panelBorder }
1931
2032
  }),
1932
2033
  // Archives section
1933
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2034
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1934
2035
  uiTransform: { padding: { left: 10, bottom: 8 } },
1935
2036
  uiText: { value: "ARCHIVES", fontSize: this.s(12), color: THEME.colors.cyan }
1936
2037
  }),
@@ -1946,7 +2047,7 @@ var GuideUIModule = class {
1946
2047
  renderMenuButton(label, count, color, badge, subtitle) {
1947
2048
  const isActive = this.activeTab === label;
1948
2049
  const buttonHeight = this.s(UI_DIMENSIONS.guide.sidebar.buttonHeight);
1949
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2050
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1950
2051
  key: label,
1951
2052
  uiTransform: {
1952
2053
  width: "100%",
@@ -1965,10 +2066,10 @@ var GuideUIModule = class {
1965
2066
  this.currentPage = 0;
1966
2067
  },
1967
2068
  children: [
1968
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2069
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1969
2070
  uiTransform: { flexDirection: "column", alignItems: "flex-start", justifyContent: "center", gap: 0 },
1970
2071
  children: [
1971
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2072
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1972
2073
  uiTransform: { height: this.s(18) },
1973
2074
  uiText: {
1974
2075
  value: `${label} [${count}]`,
@@ -1978,7 +2079,7 @@ var GuideUIModule = class {
1978
2079
  }
1979
2080
  }),
1980
2081
  ...subtitle ? [
1981
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2082
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1982
2083
  key: "subtitle",
1983
2084
  uiTransform: { height: this.s(12), marginTop: -2 },
1984
2085
  uiText: {
@@ -1992,7 +2093,7 @@ var GuideUIModule = class {
1992
2093
  ]
1993
2094
  }),
1994
2095
  ...badge ? [
1995
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2096
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1996
2097
  key: "badge",
1997
2098
  uiText: { value: badge, fontSize: this.s(UI_DIMENSIONS.guide.sidebar.fontSize), color: THEME.colors.red }
1998
2099
  })
@@ -2021,7 +2122,7 @@ var GuideUIModule = class {
2021
2122
  const start = this.currentPage * this.itemsPerPage;
2022
2123
  const paged = videosToShow.slice(start, start + this.itemsPerPage);
2023
2124
  const totalPages = Math.ceil(videosToShow.length / this.itemsPerPage);
2024
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2125
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2025
2126
  uiTransform: {
2026
2127
  flexGrow: 1,
2027
2128
  flexDirection: "column",
@@ -2032,7 +2133,7 @@ var GuideUIModule = class {
2032
2133
  this.renderCardGrid(paged),
2033
2134
  // Pagination
2034
2135
  ...totalPages > 1 ? [
2035
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2136
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2036
2137
  key: "pagination",
2037
2138
  uiTransform: {
2038
2139
  width: "100%",
@@ -2045,7 +2146,7 @@ var GuideUIModule = class {
2045
2146
  },
2046
2147
  children: [
2047
2148
  ...this.currentPage > 0 ? [
2048
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2149
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2049
2150
  key: "prev",
2050
2151
  uiText: {
2051
2152
  value: "< PREV",
@@ -2055,7 +2156,7 @@ var GuideUIModule = class {
2055
2156
  onMouseDown: () => this.currentPage--
2056
2157
  })
2057
2158
  ] : [],
2058
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2159
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2059
2160
  uiText: {
2060
2161
  value: `${this.currentPage + 1}/${totalPages}`,
2061
2162
  fontSize: this.s(UI_DIMENSIONS.guide.content.bodySize),
@@ -2063,7 +2164,7 @@ var GuideUIModule = class {
2063
2164
  }
2064
2165
  }),
2065
2166
  ...this.currentPage < totalPages - 1 ? [
2066
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2167
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2067
2168
  key: "next",
2068
2169
  uiText: {
2069
2170
  value: "NEXT >",
@@ -2081,7 +2182,7 @@ var GuideUIModule = class {
2081
2182
  }
2082
2183
  renderCardGrid(videos) {
2083
2184
  if (videos.length === 0) {
2084
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2185
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2085
2186
  uiTransform: { width: "100%", flexGrow: 1, justifyContent: "center", alignItems: "center" },
2086
2187
  uiText: { value: "NO SIGNAL", fontSize: this.s(UI_DIMENSIONS.guide.content.bodySize), color: THEME.colors.gray }
2087
2188
  });
@@ -2091,7 +2192,7 @@ var GuideUIModule = class {
2091
2192
  rows.push(videos.slice(i, i + 2));
2092
2193
  }
2093
2194
  const cardH = this.s(UI_DIMENSIONS.guide.content.cardHeight);
2094
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2195
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2095
2196
  uiTransform: {
2096
2197
  width: "100%",
2097
2198
  flexGrow: 1,
@@ -2100,7 +2201,7 @@ var GuideUIModule = class {
2100
2201
  gap: 8
2101
2202
  },
2102
2203
  children: rows.map(
2103
- (row, rowIndex) => import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2204
+ (row, rowIndex) => import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2104
2205
  key: `row-${rowIndex}`,
2105
2206
  uiTransform: {
2106
2207
  width: "100%",
@@ -2127,7 +2228,7 @@ var GuideUIModule = class {
2127
2228
  } else if (isActive) {
2128
2229
  cardBgColor = import_math3.Color4.create(0, 0.4, 0, 0.5);
2129
2230
  }
2130
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2231
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2131
2232
  key: video.id,
2132
2233
  uiTransform: {
2133
2234
  width: cardW,
@@ -2142,7 +2243,7 @@ var GuideUIModule = class {
2142
2243
  uiBackground: { color: cardBgColor },
2143
2244
  children: [
2144
2245
  // Main click area
2145
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2246
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2146
2247
  uiTransform: {
2147
2248
  width: "100%",
2148
2249
  height: "70%",
@@ -2152,7 +2253,7 @@ var GuideUIModule = class {
2152
2253
  },
2153
2254
  onMouseDown: () => this.handleVideoSelect(video),
2154
2255
  children: [
2155
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2256
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2156
2257
  uiText: {
2157
2258
  value: truncateText(video.name || "Unknown", 22),
2158
2259
  fontSize: this.s(UI_DIMENSIONS.guide.content.headerSize),
@@ -2161,7 +2262,7 @@ var GuideUIModule = class {
2161
2262
  }),
2162
2263
  // Status indicator: OFFLINE > CONNECTING > PLAYING > LIVE
2163
2264
  ...isOffline ? [
2164
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2265
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2165
2266
  key: "offline",
2166
2267
  uiText: {
2167
2268
  value: "OFFLINE",
@@ -2170,7 +2271,7 @@ var GuideUIModule = class {
2170
2271
  }
2171
2272
  })
2172
2273
  ] : isConnecting ? [
2173
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2274
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2174
2275
  key: "connecting",
2175
2276
  uiText: {
2176
2277
  value: "CONNECTING...",
@@ -2179,7 +2280,7 @@ var GuideUIModule = class {
2179
2280
  }
2180
2281
  })
2181
2282
  ] : isActive ? [
2182
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2283
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2183
2284
  key: "playing",
2184
2285
  uiText: {
2185
2286
  value: "PLAYING",
@@ -2188,18 +2289,18 @@ var GuideUIModule = class {
2188
2289
  }
2189
2290
  })
2190
2291
  ] : video.isLive ? [
2191
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2292
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2192
2293
  key: "live",
2193
2294
  uiTransform: { padding: { left: 4, right: 4, top: 2, bottom: 2 }, marginTop: 4 },
2194
2295
  uiBackground: { color: THEME.colors.red },
2195
2296
  children: [
2196
- import_react_ecs2.default.createElement(import_react_ecs2.Label, { value: "LIVE", fontSize: this.s(10), color: THEME.colors.white })
2297
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, { value: "LIVE", fontSize: this.s(10), color: THEME.colors.white })
2197
2298
  ]
2198
2299
  })
2199
2300
  ] : [],
2200
2301
  // A locked channel (2026-11-20): its badge, the words a refused pick shows - one line, 12px in the 260px card
2201
2302
  ...video.locked === true ? [
2202
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2303
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2203
2304
  key: "locked",
2204
2305
  uiTransform: { height: this.s(16), marginTop: 4 },
2205
2306
  uiText: { value: LOCKED_LINE, fontSize: this.s(12), color: THEME.colors.yellow }
@@ -2208,7 +2309,7 @@ var GuideUIModule = class {
2208
2309
  ]
2209
2310
  }),
2210
2311
  // Channel link
2211
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2312
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2212
2313
  uiTransform: {
2213
2314
  width: "100%",
2214
2315
  height: "30%",
@@ -2219,7 +2320,7 @@ var GuideUIModule = class {
2219
2320
  uiBackground: { color: import_math3.Color4.create(0, 0, 0, 0.3) },
2220
2321
  onMouseDown: () => this.handleChannelClick(video),
2221
2322
  children: [
2222
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2323
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2223
2324
  uiText: {
2224
2325
  value: "CHANNEL",
2225
2326
  fontSize: this.s(UI_DIMENSIONS.guide.content.bodySize),
@@ -2236,7 +2337,7 @@ var GuideUIModule = class {
2236
2337
  const buttonW = this.s(170);
2237
2338
  const buttonH = this.s(44);
2238
2339
  const bodyH = this.s(UI_DIMENSIONS.guide.content.bodySize * 1.5 * 2);
2239
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2340
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2240
2341
  key: "age-choice",
2241
2342
  uiTransform: {
2242
2343
  positionType: "absolute",
@@ -2250,7 +2351,7 @@ var GuideUIModule = class {
2250
2351
  },
2251
2352
  uiBackground: { color: import_math3.Color4.create(0, 0, 0, 0.85) },
2252
2353
  children: [
2253
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2354
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2254
2355
  uiTransform: {
2255
2356
  width: this.s(480),
2256
2357
  flexDirection: "column",
@@ -2261,15 +2362,15 @@ var GuideUIModule = class {
2261
2362
  },
2262
2363
  uiBackground: { color: THEME.colors.panel },
2263
2364
  children: [
2264
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2365
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2265
2366
  uiTransform: { marginBottom: this.s(8) },
2266
2367
  uiText: { value: "MATURE CONTENT", fontSize: this.s(24), color: THEME.colors.red }
2267
2368
  }),
2268
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2369
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2269
2370
  uiTransform: { marginBottom: this.s(12) },
2270
2371
  uiText: { value: truncateText(video.name || "Unknown", 40), fontSize: this.s(16), color: THEME.colors.cyan }
2271
2372
  }),
2272
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2373
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2273
2374
  uiTransform: { width: "100%", minHeight: bodyH, marginBottom: this.s(20) },
2274
2375
  uiText: {
2275
2376
  value: "This channel is for viewers aged 18 and older. Are you 18 or older?",
@@ -2279,21 +2380,21 @@ var GuideUIModule = class {
2279
2380
  textWrap: "wrap"
2280
2381
  }
2281
2382
  }),
2282
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2383
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2283
2384
  uiTransform: { flexDirection: "row", justifyContent: "center", gap: this.s(16) },
2284
2385
  children: [
2285
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2386
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2286
2387
  key: "age-yes",
2287
2388
  uiTransform: { width: buttonW, height: buttonH, justifyContent: "center", alignItems: "center" },
2288
2389
  uiBackground: { color: THEME.colors.red },
2289
2390
  onMouseDown: () => this.answerAge(true),
2290
2391
  children: [
2291
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2392
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2292
2393
  uiText: { value: "YES, I AM 18+", fontSize: this.s(14), color: THEME.colors.white }
2293
2394
  })
2294
2395
  ]
2295
2396
  }),
2296
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2397
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2297
2398
  key: "age-no",
2298
2399
  uiTransform: {
2299
2400
  width: buttonW,
@@ -2306,7 +2407,7 @@ var GuideUIModule = class {
2306
2407
  uiBackground: { color: THEME.colors.buttonBackground },
2307
2408
  onMouseDown: () => this.answerAge(false),
2308
2409
  children: [
2309
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2410
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2310
2411
  uiText: { value: "NO", fontSize: this.s(14), color: THEME.colors.white }
2311
2412
  })
2312
2413
  ]
@@ -2320,7 +2421,7 @@ var GuideUIModule = class {
2320
2421
  }
2321
2422
  renderCloseButton() {
2322
2423
  const closeSize = this.s(UI_DIMENSIONS.closeButton.size);
2323
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2424
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2324
2425
  uiTransform: {
2325
2426
  positionType: "absolute",
2326
2427
  position: { top: -5, right: -5 },
@@ -2332,7 +2433,7 @@ var GuideUIModule = class {
2332
2433
  uiBackground: { color: THEME.colors.panel },
2333
2434
  onMouseDown: () => this.hide(),
2334
2435
  children: [
2335
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2436
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2336
2437
  uiText: { value: "X", fontSize: this.s(UI_DIMENSIONS.closeButton.fontSize), color: THEME.colors.red }
2337
2438
  })
2338
2439
  ]
@@ -2341,8 +2442,25 @@ var GuideUIModule = class {
2341
2442
  renderToggleButton() {
2342
2443
  const buttonText = this._isVisible ? "CLOSE" : "GUIDE";
2343
2444
  const buttonColor = this._isVisible ? import_math3.Color4.create(0.2, 0.2, 0.28, 0.9) : import_math3.Color4.create(0, 0.5, 0.5, 0.9);
2445
+ const label = import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2446
+ uiText: {
2447
+ value: buttonText,
2448
+ fontSize: this.s(14),
2449
+ color: THEME.colors.white,
2450
+ textAlign: "middle-center"
2451
+ }
2452
+ });
2453
+ const press = () => this._isVisible ? this.hide() : this.show();
2454
+ if (this.client.isPhone) {
2455
+ return toolbarButton(1, {
2456
+ uiTransform: { justifyContent: "center", alignItems: "center" },
2457
+ uiBackground: { color: buttonColor },
2458
+ onMouseDown: press,
2459
+ children: [label]
2460
+ }, true, this.client.uiScale);
2461
+ }
2344
2462
  const buttonPos = 20 + this.s(100) + 10;
2345
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2463
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2346
2464
  uiTransform: {
2347
2465
  positionType: "absolute",
2348
2466
  position: { right: buttonPos, bottom: 10 },
@@ -2352,23 +2470,14 @@ var GuideUIModule = class {
2352
2470
  alignItems: "center"
2353
2471
  },
2354
2472
  uiBackground: { color: buttonColor },
2355
- onMouseDown: () => this._isVisible ? this.hide() : this.show(),
2356
- children: [
2357
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2358
- uiText: {
2359
- value: buttonText,
2360
- fontSize: this.s(14),
2361
- color: THEME.colors.white,
2362
- textAlign: "middle-center"
2363
- }
2364
- })
2365
- ]
2473
+ onMouseDown: press,
2474
+ children: [label]
2366
2475
  });
2367
2476
  }
2368
2477
  };
2369
2478
 
2370
2479
  // src/ui/chat-ui.tsx
2371
- var import_react_ecs3 = __toESM(require("@dcl/sdk/react-ecs"));
2480
+ var import_react_ecs4 = __toESM(require("@dcl/sdk/react-ecs"));
2372
2481
  var import_math4 = require("@dcl/sdk/math");
2373
2482
  var import_SignedFetch3 = require("~system/SignedFetch");
2374
2483
  var import_players = require("@dcl/sdk/players");
@@ -2419,7 +2528,7 @@ var ChatUIModule = class {
2419
2528
  if (this.client.isVisitorBlocked) return null;
2420
2529
  const scaledTheme = scaleChatTheme(DEFAULT_CHAT_THEME, this.client.uiScale);
2421
2530
  const positionStyle = this.getPositionStyle();
2422
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2531
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2423
2532
  uiTransform: {
2424
2533
  width: "100%",
2425
2534
  height: "100%",
@@ -2430,13 +2539,14 @@ var ChatUIModule = class {
2430
2539
  this.renderToggleButton(),
2431
2540
  // Render panel when visible - scaled sizes, fixed position
2432
2541
  // Key includes uiScale to force re-render when scale changes from other panels
2433
- this._isVisible ? import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2542
+ this._isVisible ? import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2434
2543
  key: `chat-panel-${this.client.uiScale}`,
2435
2544
  uiTransform: {
2436
2545
  width: this.s(UI_DIMENSIONS.chat.width),
2437
2546
  height: this.s(UI_DIMENSIONS.chat.height),
2438
2547
  positionType: "absolute",
2439
- position: { bottom: UI_DIMENSIONS.chat.bottom, right: UI_DIMENSIONS.chat.right },
2548
+ // On a phone, left of the toolbar's column (2.12.0); elsewhere at the right edge, as before
2549
+ position: { bottom: UI_DIMENSIONS.chat.bottom, right: this.client.panelRight(UI_DIMENSIONS.chat.right) },
2440
2550
  flexDirection: "column",
2441
2551
  border: { top: 2, bottom: 2, left: 2, right: 2 },
2442
2552
  borderColor: THEME.colors.panelBorder
@@ -2446,7 +2556,7 @@ var ChatUIModule = class {
2446
2556
  this.renderHeader(),
2447
2557
  this.renderChannelButton(scaledTheme),
2448
2558
  this.renderMessagesArea(scaledTheme),
2449
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2559
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2450
2560
  uiTransform: { width: "100%", height: 1, flexShrink: 0 },
2451
2561
  uiBackground: { color: THEME.colors.panelBorder }
2452
2562
  }),
@@ -2479,6 +2589,7 @@ var ChatUIModule = class {
2479
2589
  */
2480
2590
  show() {
2481
2591
  if (this._isVisible) return;
2592
+ this.client.panelOpened("chat");
2482
2593
  this._isVisible = true;
2483
2594
  this._unreadCount = 0;
2484
2595
  this.chatScrollOffset = 0;
@@ -2787,7 +2898,7 @@ var ChatUIModule = class {
2787
2898
  renderChannelButton(theme) {
2788
2899
  const currentChannel = this.channels.find((c) => c.id === this.currentChannelId);
2789
2900
  const displayName = currentChannel?.name || this.currentChannelId;
2790
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2901
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2791
2902
  uiTransform: {
2792
2903
  height: 40,
2793
2904
  width: "100%",
@@ -2802,12 +2913,12 @@ var ChatUIModule = class {
2802
2913
  this.showChannelDropdown = !this.showChannelDropdown;
2803
2914
  },
2804
2915
  children: [
2805
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
2916
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
2806
2917
  value: `// ${truncateText(displayName, 24)}`,
2807
2918
  fontSize: theme.channelButton,
2808
2919
  color: THEME.colors.white
2809
2920
  }),
2810
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
2921
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
2811
2922
  value: this.showChannelDropdown ? "\u25B2" : "\u25BC",
2812
2923
  fontSize: 10,
2813
2924
  color: THEME.colors.cyan
@@ -2836,7 +2947,7 @@ var ChatUIModule = class {
2836
2947
  const visibleMessages = allMessages.slice(startIdx, endIdx);
2837
2948
  const canScrollUp = this.chatScrollOffset < maxOffset;
2838
2949
  const canScrollDown = this.chatScrollOffset > 0;
2839
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2950
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2840
2951
  uiTransform: { flexGrow: 1, width: "100%", flexDirection: "row", overflow: "hidden" },
2841
2952
  children: [
2842
2953
  // Messages - anchored at the bottom, so the newest stays in view now that a row grows with its text
@@ -2844,7 +2955,7 @@ var ChatUIModule = class {
2844
2955
  // past it; now its oldest clips at the top, one scroll up away. The rows keep their height
2845
2956
  // (flexShrink 0 - the protocol's default of 1 squeezes them onto each other) in one column
2846
2957
  // (nowrap - the protocol documents wrap as its default).
2847
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2958
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2848
2959
  uiTransform: {
2849
2960
  flexGrow: 1,
2850
2961
  flexDirection: "column",
@@ -2858,7 +2969,7 @@ var ChatUIModule = class {
2858
2969
  )
2859
2970
  }),
2860
2971
  // Scroll controls
2861
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2972
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2862
2973
  uiTransform: {
2863
2974
  width: 28,
2864
2975
  height: "100%",
@@ -2868,22 +2979,22 @@ var ChatUIModule = class {
2868
2979
  gap: 8
2869
2980
  },
2870
2981
  children: [
2871
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2982
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2872
2983
  uiTransform: { width: 26, height: 36, justifyContent: "center", alignItems: "center" },
2873
2984
  uiBackground: { color: canScrollUp ? THEME.colors.buttonBackground : import_math4.Color4.create(0.1, 0.1, 0.1, 0.3) },
2874
2985
  onMouseDown: () => {
2875
2986
  if (canScrollUp) this.chatScrollOffset += 1;
2876
2987
  },
2877
2988
  children: [
2878
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2989
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2879
2990
  uiText: { value: "\u25B2", fontSize: 14, color: canScrollUp ? THEME.colors.cyan : THEME.colors.gray }
2880
2991
  })
2881
2992
  ]
2882
2993
  }),
2883
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2994
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2884
2995
  uiTransform: { width: 26, height: 24, justifyContent: "center", alignItems: "center" },
2885
2996
  children: [
2886
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2997
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2887
2998
  uiText: {
2888
2999
  value: totalMessages > UI_DIMENSIONS.chat.messagesPerPage ? `${this.chatScrollOffset}` : "-",
2889
3000
  fontSize: 10,
@@ -2892,14 +3003,14 @@ var ChatUIModule = class {
2892
3003
  })
2893
3004
  ]
2894
3005
  }),
2895
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3006
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2896
3007
  uiTransform: { width: 26, height: 36, justifyContent: "center", alignItems: "center" },
2897
3008
  uiBackground: { color: canScrollDown ? THEME.colors.buttonBackground : import_math4.Color4.create(0.1, 0.1, 0.1, 0.3) },
2898
3009
  onMouseDown: () => {
2899
3010
  if (canScrollDown) this.chatScrollOffset -= 1;
2900
3011
  },
2901
3012
  children: [
2902
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3013
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2903
3014
  uiText: { value: "\u25BC", fontSize: 14, color: canScrollDown ? THEME.colors.cyan : THEME.colors.gray }
2904
3015
  })
2905
3016
  ]
@@ -2910,7 +3021,7 @@ var ChatUIModule = class {
2910
3021
  });
2911
3022
  }
2912
3023
  renderSystemMessage(msg, theme) {
2913
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3024
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2914
3025
  key: msg.id,
2915
3026
  uiTransform: { width: "100%", height: 24, marginBottom: 4, flexShrink: 0 },
2916
3027
  uiText: {
@@ -2930,12 +3041,12 @@ var ChatUIModule = class {
2930
3041
  if (displayName.toLowerCase().includes("admin")) accentColor = THEME.colors.magenta;
2931
3042
  else if (isCurrentUser) accentColor = THEME.colors.green;
2932
3043
  const textRoom = this.messageTextRoom(msg.text, theme.chatMessage);
2933
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3044
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2934
3045
  key: msg.id,
2935
3046
  uiTransform: { width: "100%", flexDirection: "column", marginBottom: 16, flexShrink: 0 },
2936
3047
  children: [
2937
3048
  // Header row
2938
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3049
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2939
3050
  uiTransform: {
2940
3051
  width: "100%",
2941
3052
  height: 24,
@@ -2945,23 +3056,23 @@ var ChatUIModule = class {
2945
3056
  marginBottom: 4
2946
3057
  },
2947
3058
  children: [
2948
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3059
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2949
3060
  uiText: { value: displayName, fontSize: theme.chatUsername, color: accentColor, textAlign: "middle-left" }
2950
3061
  }),
2951
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3062
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2952
3063
  uiText: { value: time, fontSize: theme.chatTimestamp, color: THEME.colors.gray, textAlign: "middle-right" }
2953
3064
  })
2954
3065
  ]
2955
3066
  }),
2956
3067
  // Message content
2957
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3068
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2958
3069
  uiTransform: { width: "100%", flexDirection: "row", alignItems: "stretch", paddingLeft: 8 },
2959
3070
  children: [
2960
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3071
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2961
3072
  uiTransform: { width: 3, minHeight: textRoom },
2962
3073
  uiBackground: { color: accentColor }
2963
3074
  }),
2964
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3075
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2965
3076
  uiTransform: { flexGrow: 1, minHeight: textRoom, paddingLeft: 12, paddingTop: 4, paddingBottom: 4 },
2966
3077
  uiText: {
2967
3078
  value: msg.text,
@@ -2977,7 +3088,7 @@ var ChatUIModule = class {
2977
3088
  });
2978
3089
  }
2979
3090
  renderUserInfoBar(theme) {
2980
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3091
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2981
3092
  uiTransform: {
2982
3093
  width: "100%",
2983
3094
  height: 34,
@@ -2989,12 +3100,12 @@ var ChatUIModule = class {
2989
3100
  },
2990
3101
  uiBackground: { color: import_math4.Color4.create(0.03, 0.03, 0.05, 1) },
2991
3102
  children: [
2992
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3103
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
2993
3104
  value: `// ${this.currentUsername || "Guest"}`,
2994
3105
  fontSize: theme.userInfo,
2995
3106
  color: THEME.colors.yellow
2996
3107
  }),
2997
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3108
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
2998
3109
  value: this.isRegisteredUser ? "\u25CF CITIZEN" : "\u25CB GUEST",
2999
3110
  fontSize: theme.authStatus,
3000
3111
  color: this.isRegisteredUser ? THEME.colors.green : THEME.colors.gray
@@ -3005,7 +3116,7 @@ var ChatUIModule = class {
3005
3116
  renderInputArea(theme) {
3006
3117
  const baseUrl = this.getBaseUrl();
3007
3118
  if (!this.isRegisteredUser) {
3008
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3119
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3009
3120
  uiTransform: {
3010
3121
  height: 75,
3011
3122
  minHeight: 75,
@@ -3019,14 +3130,14 @@ var ChatUIModule = class {
3019
3130
  },
3020
3131
  uiBackground: { color: import_math4.Color4.create(0.08, 0.08, 0.1, 1) },
3021
3132
  children: [
3022
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3133
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3023
3134
  value: "ACCESS RESTRICTED: CITIZENS ONLY",
3024
3135
  fontSize: 12,
3025
3136
  color: THEME.colors.red,
3026
3137
  textAlign: "middle-center",
3027
3138
  uiTransform: { marginBottom: 5 }
3028
3139
  }),
3029
- import_react_ecs3.default.createElement(import_react_ecs3.Button, {
3140
+ import_react_ecs4.default.createElement(import_react_ecs4.Button, {
3030
3141
  value: "REGISTER IDENTITY",
3031
3142
  fontSize: 14,
3032
3143
  uiTransform: { width: 200, height: 30 },
@@ -3039,7 +3150,7 @@ var ChatUIModule = class {
3039
3150
  ]
3040
3151
  });
3041
3152
  }
3042
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3153
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3043
3154
  uiTransform: {
3044
3155
  height: 75,
3045
3156
  minHeight: 75,
@@ -3051,7 +3162,7 @@ var ChatUIModule = class {
3051
3162
  },
3052
3163
  uiBackground: { color: import_math4.Color4.create(0.08, 0.08, 0.1, 1) },
3053
3164
  children: [
3054
- import_react_ecs3.default.createElement(import_react_ecs3.Input, {
3165
+ import_react_ecs4.default.createElement(import_react_ecs4.Input, {
3055
3166
  onChange: (v) => {
3056
3167
  this.inputText = v;
3057
3168
  },
@@ -3064,7 +3175,7 @@ var ChatUIModule = class {
3064
3175
  uiBackground: { color: import_math4.Color4.create(0.12, 0.12, 0.14, 1) },
3065
3176
  uiTransform: { flexGrow: 1, height: "100%", margin: { right: 10 } }
3066
3177
  }),
3067
- import_react_ecs3.default.createElement(import_react_ecs3.Button, {
3178
+ import_react_ecs4.default.createElement(import_react_ecs4.Button, {
3068
3179
  value: this.isSigningIn ? "..." : "SEND",
3069
3180
  onMouseDown: () => this.handleSend(),
3070
3181
  uiTransform: { width: 80, height: "100%" },
@@ -3081,7 +3192,7 @@ var ChatUIModule = class {
3081
3192
  const endIdx = startIdx + UI_DIMENSIONS.chat.channelsPerPage;
3082
3193
  const visibleChannels = this.channels.slice(startIdx, endIdx);
3083
3194
  const totalPages = Math.ceil(this.channels.length / UI_DIMENSIONS.chat.channelsPerPage);
3084
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3195
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3085
3196
  uiTransform: {
3086
3197
  width: "100%",
3087
3198
  height: 260,
@@ -3092,13 +3203,13 @@ var ChatUIModule = class {
3092
3203
  uiBackground: { color: import_math4.Color4.create(0.08, 0.1, 0.14, 1) },
3093
3204
  children: [
3094
3205
  // Top border
3095
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3206
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3096
3207
  uiTransform: { width: "100%", height: 2, flexShrink: 0 },
3097
3208
  uiBackground: { color: THEME.colors.cyan }
3098
3209
  }),
3099
3210
  // Channel list
3100
3211
  ...visibleChannels.map(
3101
- (channel) => import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3212
+ (channel) => import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3102
3213
  key: channel.id,
3103
3214
  uiTransform: {
3104
3215
  height: 38,
@@ -3111,7 +3222,7 @@ var ChatUIModule = class {
3111
3222
  },
3112
3223
  onMouseDown: () => this.switchChannel(channel.id),
3113
3224
  children: [
3114
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3225
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3115
3226
  value: channel.id === this.currentChannelId ? `\u25B8 ${channel.name}` : channel.name,
3116
3227
  fontSize: theme.channelDropdown,
3117
3228
  color: channel.id === this.currentChannelId ? THEME.colors.cyan : THEME.colors.gray
@@ -3121,7 +3232,7 @@ var ChatUIModule = class {
3121
3232
  ),
3122
3233
  // Pagination
3123
3234
  ...totalPages > 1 ? [
3124
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3235
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3125
3236
  key: "pagination",
3126
3237
  uiTransform: {
3127
3238
  width: "100%",
@@ -3134,11 +3245,11 @@ var ChatUIModule = class {
3134
3245
  },
3135
3246
  children: [
3136
3247
  ...this.channelPage > 0 ? [
3137
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3248
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3138
3249
  key: "prev",
3139
3250
  onMouseDown: () => this.channelPage--,
3140
3251
  children: [
3141
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3252
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3142
3253
  value: "<< PREV",
3143
3254
  fontSize: 10,
3144
3255
  color: THEME.colors.cyan
@@ -3146,17 +3257,17 @@ var ChatUIModule = class {
3146
3257
  ]
3147
3258
  })
3148
3259
  ] : [],
3149
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3260
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3150
3261
  value: `${this.channelPage + 1}/${totalPages}`,
3151
3262
  fontSize: 10,
3152
3263
  color: THEME.colors.gray
3153
3264
  }),
3154
3265
  ...this.channelPage < totalPages - 1 ? [
3155
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3266
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3156
3267
  key: "next",
3157
3268
  onMouseDown: () => this.channelPage++,
3158
3269
  children: [
3159
- import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3270
+ import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3160
3271
  value: "NEXT >>",
3161
3272
  fontSize: 10,
3162
3273
  color: THEME.colors.cyan
@@ -3168,7 +3279,7 @@ var ChatUIModule = class {
3168
3279
  })
3169
3280
  ] : [],
3170
3281
  // Bottom border
3171
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3282
+ import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3172
3283
  uiTransform: { width: "100%", height: 1, flexShrink: 0 },
3173
3284
  uiBackground: { color: THEME.colors.panelBorder }
3174
3285
  })
@@ -3179,7 +3290,24 @@ var ChatUIModule = class {
3179
3290
  const unreadBadge = this._unreadCount > 0 ? ` (${this._unreadCount})` : "";
3180
3291
  const buttonText = this._isVisible ? "CLOSE" : `CHAT${unreadBadge}`;
3181
3292
  const buttonColor = this._isVisible ? import_math4.Color4.create(0.2, 0.2, 0.28, 0.9) : import_math4.Color4.create(0.6, 0, 0.5, 0.9);
3182
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3293
+ const label = import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3294
+ uiText: {
3295
+ value: buttonText,
3296
+ fontSize: this.s(14),
3297
+ color: THEME.colors.white,
3298
+ textAlign: "middle-center"
3299
+ }
3300
+ });
3301
+ const press = () => this._isVisible ? this.hide() : this.show();
3302
+ if (this.client.isPhone) {
3303
+ return toolbarButton(0, {
3304
+ uiTransform: { justifyContent: "center", alignItems: "center" },
3305
+ uiBackground: { color: buttonColor },
3306
+ onMouseDown: press,
3307
+ children: [label]
3308
+ }, true, this.client.uiScale);
3309
+ }
3310
+ return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3183
3311
  uiTransform: {
3184
3312
  positionType: "absolute",
3185
3313
  position: { right: 20, bottom: 10 },
@@ -3189,29 +3317,20 @@ var ChatUIModule = class {
3189
3317
  alignItems: "center"
3190
3318
  },
3191
3319
  uiBackground: { color: buttonColor },
3192
- onMouseDown: () => this._isVisible ? this.hide() : this.show(),
3193
- children: [
3194
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3195
- uiText: {
3196
- value: buttonText,
3197
- fontSize: this.s(14),
3198
- color: THEME.colors.white,
3199
- textAlign: "middle-center"
3200
- }
3201
- })
3202
- ]
3320
+ onMouseDown: press,
3321
+ children: [label]
3203
3322
  });
3204
3323
  }
3205
3324
  };
3206
3325
 
3207
3326
  // src/ui/admin-panel-ui.tsx
3208
- var import_react_ecs6 = __toESM(require("@dcl/sdk/react-ecs"));
3327
+ var import_react_ecs7 = __toESM(require("@dcl/sdk/react-ecs"));
3209
3328
  var import_math7 = require("@dcl/sdk/math");
3210
3329
  var import_players2 = require("@dcl/sdk/players");
3211
3330
  var import_RestrictedActions6 = require("~system/RestrictedActions");
3212
3331
 
3213
3332
  // src/ui/ui-renderer.tsx
3214
- var import_react_ecs4 = __toESM(require("@dcl/sdk/react-ecs"));
3333
+ var import_react_ecs5 = __toESM(require("@dcl/sdk/react-ecs"));
3215
3334
  var import_ecs3 = require("@dcl/sdk/ecs");
3216
3335
  var notificationText = "";
3217
3336
  var notificationVisible = false;
@@ -3244,8 +3363,8 @@ function NotificationBanner() {
3244
3363
  if (!notificationVisible) return null;
3245
3364
  return (
3246
3365
  // Full-width container to center the notification
3247
- /* @__PURE__ */ import_react_ecs4.default.createElement(
3248
- import_react_ecs4.UiEntity,
3366
+ /* @__PURE__ */ import_react_ecs5.default.createElement(
3367
+ import_react_ecs5.UiEntity,
3249
3368
  {
3250
3369
  uiTransform: {
3251
3370
  positionType: "absolute",
@@ -3255,8 +3374,8 @@ function NotificationBanner() {
3255
3374
  alignItems: "center"
3256
3375
  }
3257
3376
  },
3258
- /* @__PURE__ */ import_react_ecs4.default.createElement(
3259
- import_react_ecs4.UiEntity,
3377
+ /* @__PURE__ */ import_react_ecs5.default.createElement(
3378
+ import_react_ecs5.UiEntity,
3260
3379
  {
3261
3380
  uiTransform: {
3262
3381
  width: N.width,
@@ -3266,8 +3385,8 @@ function NotificationBanner() {
3266
3385
  },
3267
3386
  uiBackground: { color: C.panel }
3268
3387
  },
3269
- /* @__PURE__ */ import_react_ecs4.default.createElement(
3270
- import_react_ecs4.UiEntity,
3388
+ /* @__PURE__ */ import_react_ecs5.default.createElement(
3389
+ import_react_ecs5.UiEntity,
3271
3390
  {
3272
3391
  uiTransform: {
3273
3392
  width: N.borderWidth,
@@ -3276,8 +3395,8 @@ function NotificationBanner() {
3276
3395
  uiBackground: { color: C.cyan }
3277
3396
  }
3278
3397
  ),
3279
- /* @__PURE__ */ import_react_ecs4.default.createElement(
3280
- import_react_ecs4.UiEntity,
3398
+ /* @__PURE__ */ import_react_ecs5.default.createElement(
3399
+ import_react_ecs5.UiEntity,
3281
3400
  {
3282
3401
  uiTransform: {
3283
3402
  flexGrow: 1,
@@ -3287,8 +3406,8 @@ function NotificationBanner() {
3287
3406
  alignItems: "flex-start"
3288
3407
  }
3289
3408
  },
3290
- /* @__PURE__ */ import_react_ecs4.default.createElement(
3291
- import_react_ecs4.Label,
3409
+ /* @__PURE__ */ import_react_ecs5.default.createElement(
3410
+ import_react_ecs5.Label,
3292
3411
  {
3293
3412
  value: notificationText,
3294
3413
  fontSize: N.fontSize,
@@ -3297,8 +3416,8 @@ function NotificationBanner() {
3297
3416
  }
3298
3417
  )
3299
3418
  ),
3300
- /* @__PURE__ */ import_react_ecs4.default.createElement(
3301
- import_react_ecs4.UiEntity,
3419
+ /* @__PURE__ */ import_react_ecs5.default.createElement(
3420
+ import_react_ecs5.UiEntity,
3302
3421
  {
3303
3422
  uiTransform: {
3304
3423
  width: 5,
@@ -3320,8 +3439,8 @@ function createStaticUI(client) {
3320
3439
  const guideComponent = client.guideUI?.getComponent() ?? null;
3321
3440
  const chatComponent = client.chatUI?.getComponent() ?? null;
3322
3441
  const adminComponent = client.adminPanel?.getComponent() ?? null;
3323
- return /* @__PURE__ */ import_react_ecs4.default.createElement(
3324
- import_react_ecs4.UiEntity,
3442
+ return /* @__PURE__ */ import_react_ecs5.default.createElement(
3443
+ import_react_ecs5.UiEntity,
3325
3444
  {
3326
3445
  key: `static-ui-root-${currentScale}`,
3327
3446
  uiTransform: {
@@ -3332,7 +3451,7 @@ function createStaticUI(client) {
3332
3451
  alignItems: "center"
3333
3452
  }
3334
3453
  },
3335
- blocked ? null : /* @__PURE__ */ import_react_ecs4.default.createElement(NotificationBanner, null),
3454
+ blocked ? null : /* @__PURE__ */ import_react_ecs5.default.createElement(NotificationBanner, null),
3336
3455
  guideComponent,
3337
3456
  chatComponent,
3338
3457
  adminComponent
@@ -3341,11 +3460,11 @@ function createStaticUI(client) {
3341
3460
  }
3342
3461
  function setupStaticUI(client) {
3343
3462
  const StaticUI = createStaticUI(client);
3344
- import_react_ecs4.ReactEcsRenderer.setUiRenderer(StaticUI);
3463
+ import_react_ecs5.ReactEcsRenderer.setUiRenderer(StaticUI);
3345
3464
  }
3346
3465
 
3347
3466
  // src/ui/blocked-notice.tsx
3348
- var import_react_ecs5 = __toESM(require("@dcl/sdk/react-ecs"));
3467
+ var import_react_ecs6 = __toESM(require("@dcl/sdk/react-ecs"));
3349
3468
  var import_math5 = require("@dcl/sdk/math");
3350
3469
  var import_RestrictedActions4 = require("~system/RestrictedActions");
3351
3470
  var DEFAULT_SITE_URL = "https://thestatic.tv";
@@ -3372,8 +3491,8 @@ function BlockedNotice(props) {
3372
3491
  const s = (v) => Math.round(v * props.scale);
3373
3492
  const [title, ...body] = lines;
3374
3493
  const action = blockedNoticeAction(props.standing, props.siteUrl || DEFAULT_SITE_URL);
3375
- return /* @__PURE__ */ import_react_ecs5.default.createElement(
3376
- import_react_ecs5.UiEntity,
3494
+ return /* @__PURE__ */ import_react_ecs6.default.createElement(
3495
+ import_react_ecs6.UiEntity,
3377
3496
  {
3378
3497
  uiTransform: {
3379
3498
  width: "100%",
@@ -3383,16 +3502,16 @@ function BlockedNotice(props) {
3383
3502
  alignItems: "center"
3384
3503
  }
3385
3504
  },
3386
- /* @__PURE__ */ import_react_ecs5.default.createElement(
3387
- import_react_ecs5.UiEntity,
3505
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
3506
+ import_react_ecs6.UiEntity,
3388
3507
  {
3389
3508
  uiTransform: { width: s(460), flexDirection: "column", alignItems: "center", padding: s(20) },
3390
3509
  uiBackground: { color: import_math5.Color4.create(0.05, 0.05, 0.08, 0.95) }
3391
3510
  },
3392
- /* @__PURE__ */ import_react_ecs5.default.createElement(import_react_ecs5.Label, { value: title, fontSize: s(22), color: import_math5.Color4.create(0.9, 0.2, 0.2, 1), uiTransform: { height: s(34) } }),
3393
- body.map((line, i) => /* @__PURE__ */ import_react_ecs5.default.createElement(import_react_ecs5.Label, { key: `blocked-line-${i}`, value: line, fontSize: s(16), color: import_math5.Color4.White(), uiTransform: { height: s(26) } })),
3394
- action && /* @__PURE__ */ import_react_ecs5.default.createElement(
3395
- import_react_ecs5.Button,
3511
+ /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: title, fontSize: s(22), color: import_math5.Color4.create(0.9, 0.2, 0.2, 1), uiTransform: { height: s(34) } }),
3512
+ body.map((line, i) => /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { key: `blocked-line-${i}`, value: line, fontSize: s(16), color: import_math5.Color4.White(), uiTransform: { height: s(26) } })),
3513
+ action && /* @__PURE__ */ import_react_ecs6.default.createElement(
3514
+ import_react_ecs6.Button,
3396
3515
  {
3397
3516
  uiTransform: { width: s(220), height: s(36), margin: { top: s(12) } },
3398
3517
  uiBackground: { color: import_math5.Color4.create(0, 0.8, 0.8, 1) },
@@ -3882,16 +4001,16 @@ var AdminPanelUIModule = class {
3882
4001
  this.privateStatus = line;
3883
4002
  } };
3884
4003
  // --- UI Components ---
3885
- this.SectionHead = ({ label, color }) => /* @__PURE__ */ import_react_ecs6.default.createElement(
3886
- import_react_ecs6.UiEntity,
4004
+ this.SectionHead = ({ label, color }) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4005
+ import_react_ecs7.UiEntity,
3887
4006
  {
3888
4007
  uiTransform: { width: "100%", height: this.s(UI_DIMENSIONS.admin.sectionHeadHeight), margin: { bottom: 8 }, padding: { left: 10 }, alignItems: "center" },
3889
4008
  uiBackground: { color: import_math7.Color4.create(color.r * 0.3, color.g * 0.3, color.b * 0.3, 0.5) }
3890
4009
  },
3891
- /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: label, fontSize: this.theme.sectionHead, color })
4010
+ /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: label, fontSize: this.theme.sectionHead, color })
3892
4011
  );
3893
- this.TabBtn = ({ label, tab }) => /* @__PURE__ */ import_react_ecs6.default.createElement(
3894
- import_react_ecs6.Button,
4012
+ this.TabBtn = ({ label, tab }) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4013
+ import_react_ecs7.Button,
3895
4014
  {
3896
4015
  uiTransform: { flexGrow: 1, height: this.s(UI_DIMENSIONS.admin.tabHeight), justifyContent: "center", alignItems: "center" },
3897
4016
  uiBackground: { color: this.activeTab === tab ? C2.tabActive : C2.tabInactive },
@@ -3909,8 +4028,8 @@ var AdminPanelUIModule = class {
3909
4028
  */
3910
4029
  this.ControlsTab = () => {
3911
4030
  const t = this.theme;
3912
- return /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", width: "100%", padding: 10 } }, this.controls.map((control) => /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { key: `control-${control.id}`, uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: control.label, color: C2.cyan }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap" } }, control.options.map((option) => this.controlButton(control, option.id, option.label)), control.off === true && this.controlButton(control, "off", "OFF")))), this.controlStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
3913
- import_react_ecs6.Label,
4031
+ return /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", width: "100%", padding: 10 } }, this.controls.map((control) => /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { key: `control-${control.id}`, uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: control.label, color: C2.cyan }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap" } }, control.options.map((option) => this.controlButton(control, option.id, option.label)), control.off === true && this.controlButton(control, "off", "OFF")))), this.controlStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4032
+ import_react_ecs7.Label,
3914
4033
  {
3915
4034
  value: this.controlStatus,
3916
4035
  fontSize: t.status,
@@ -3924,8 +4043,8 @@ var AdminPanelUIModule = class {
3924
4043
  this.fetchStreamData();
3925
4044
  }
3926
4045
  const t = this.theme;
3927
- return /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", width: "100%", padding: 10 } }, !this.streamData?.hasChannel && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "LIVE STREAM", color: C2.btn }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "No streaming channel linked", fontSize: t.labelSmall, color: C2.textDim, uiTransform: { margin: { bottom: 8 } } }), this.isOwner && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column" } }, this.streamData?.trialAvailable && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
3928
- import_react_ecs6.Button,
4046
+ return /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", width: "100%", padding: 10 } }, !this.streamData?.hasChannel && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "LIVE STREAM", color: C2.btn }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "No streaming channel linked", fontSize: t.labelSmall, color: C2.textDim, uiTransform: { margin: { bottom: 8 } } }), this.isOwner && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column" } }, this.streamData?.trialAvailable && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4047
+ import_react_ecs7.Button,
3929
4048
  {
3930
4049
  uiTransform: { width: this.s(200), height: this.s(UI_DIMENSIONS.admin.buttonHeight), margin: { bottom: 6 } },
3931
4050
  uiBackground: { color: this.trialClaiming ? C2.btn : C2.green },
@@ -3934,8 +4053,8 @@ var AdminPanelUIModule = class {
3934
4053
  color: C2.text,
3935
4054
  onMouseDown: () => this.claimTrial()
3936
4055
  }
3937
- ), this.trialClaimError && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: this.trialClaimError, fontSize: t.status, color: C2.red }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: trialNoteText(this.streamData?.trialSparks), fontSize: t.labelSmall, color: C2.textDim, uiTransform: { margin: { top: 4 } } })), !this.streamData?.trialAvailable && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column" } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
3938
- import_react_ecs6.Button,
4056
+ ), this.trialClaimError && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: this.trialClaimError, fontSize: t.status, color: C2.red }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: trialNoteText(this.streamData?.trialSparks), fontSize: t.labelSmall, color: C2.textDim, uiTransform: { margin: { top: 4 } } })), !this.streamData?.trialAvailable && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column" } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4057
+ import_react_ecs7.Button,
3939
4058
  {
3940
4059
  uiTransform: { width: this.s(170), height: this.s(UI_DIMENSIONS.admin.buttonHeight), margin: { bottom: 6 } },
3941
4060
  uiBackground: { color: this.channelCreating ? C2.btn : C2.cyan },
@@ -3944,47 +4063,47 @@ var AdminPanelUIModule = class {
3944
4063
  color: C2.text,
3945
4064
  onMouseDown: () => this.createChannel()
3946
4065
  }
3947
- ), this.channelCreateError && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: this.channelCreateError, fontSize: t.status, color: C2.red }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Relay tier \u2022 $25/mo \u2022 8 hours streaming", fontSize: t.labelSmall, color: C2.textDim, uiTransform: { margin: { top: 4 } } })))), this.streamData?.hasChannel && this.isOwner && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: this.streamData.isLive ? "LIVE STREAM" : "STREAM SETTINGS", color: this.streamData.isLive ? C2.red : C2.yellow }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 8 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
3948
- import_react_ecs6.Label,
4066
+ ), this.channelCreateError && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: this.channelCreateError, fontSize: t.status, color: C2.red }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Relay tier \u2022 $25/mo \u2022 8 hours streaming", fontSize: t.labelSmall, color: C2.textDim, uiTransform: { margin: { top: 4 } } })))), this.streamData?.hasChannel && this.isOwner && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: this.streamData.isLive ? "LIVE STREAM" : "STREAM SETTINGS", color: this.streamData.isLive ? C2.red : C2.yellow }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 8 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4067
+ import_react_ecs7.Label,
3949
4068
  {
3950
4069
  value: this.streamData.isLive ? `LIVE \u2022 ${this.streamData.currentViewers || 0} viewers` : "OFFLINE",
3951
4070
  fontSize: t.label,
3952
4071
  color: this.streamData.isLive ? C2.red : C2.textDim
3953
4072
  }
3954
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: ` \u2022 ${this.streamData.tier?.toUpperCase() || "RELAY"}`, fontSize: t.labelSmall, color: C2.cyan }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: ` \u2022 ${this.streamData.sparksBalance || 0} Sparks`, fontSize: t.labelSmall, color: C2.textDim })), /* @__PURE__ */ import_react_ecs6.default.createElement(
3955
- import_react_ecs6.Label,
4073
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: ` \u2022 ${this.streamData.tier?.toUpperCase() || "RELAY"}`, fontSize: t.labelSmall, color: C2.cyan }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: ` \u2022 ${this.streamData.sparksBalance || 0} Sparks`, fontSize: t.labelSmall, color: C2.textDim })), /* @__PURE__ */ import_react_ecs7.default.createElement(
4074
+ import_react_ecs7.Label,
3956
4075
  {
3957
4076
  value: `Channel: ${this.streamData.channelName || this.streamData.channelId}`,
3958
4077
  fontSize: t.labelSmall,
3959
4078
  color: C2.textDim,
3960
4079
  uiTransform: { margin: { bottom: 10 } }
3961
4080
  }
3962
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "RTMP Server:", fontSize: t.labelSmall, color: C2.textDim }), /* @__PURE__ */ import_react_ecs6.default.createElement(
3963
- import_react_ecs6.Label,
4081
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "RTMP Server:", fontSize: t.labelSmall, color: C2.textDim }), /* @__PURE__ */ import_react_ecs7.default.createElement(
4082
+ import_react_ecs7.Label,
3964
4083
  {
3965
4084
  value: this.streamData.rtmpUrl || "Loading...",
3966
4085
  fontSize: t.label,
3967
4086
  color: this.streamData.rtmpUrl ? C2.text : C2.textDim,
3968
4087
  uiTransform: { margin: { left: 6 } }
3969
4088
  }
3970
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Stream Key:", fontSize: t.labelSmall, color: C2.textDim }), /* @__PURE__ */ import_react_ecs6.default.createElement(
3971
- import_react_ecs6.Label,
4089
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Stream Key:", fontSize: t.labelSmall, color: C2.textDim }), /* @__PURE__ */ import_react_ecs7.default.createElement(
4090
+ import_react_ecs7.Label,
3972
4091
  {
3973
4092
  value: this.streamData.streamKey || "Loading...",
3974
4093
  fontSize: t.label,
3975
4094
  color: this.streamData.streamKey ? C2.cyan : C2.textDim,
3976
4095
  uiTransform: { margin: { left: 6 } }
3977
4096
  }
3978
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "HLS Playback:", fontSize: t.labelSmall, color: C2.textDim }), /* @__PURE__ */ import_react_ecs6.default.createElement(
3979
- import_react_ecs6.Label,
4097
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "HLS Playback:", fontSize: t.labelSmall, color: C2.textDim }), /* @__PURE__ */ import_react_ecs7.default.createElement(
4098
+ import_react_ecs7.Label,
3980
4099
  {
3981
4100
  value: this.streamData.locked === true ? LOCKED_LINE : this.streamData.hlsUrl || "Not available",
3982
4101
  fontSize: t.label,
3983
4102
  color: this.streamData.locked === true ? C2.yellow : this.streamData.hlsUrl ? C2.green : C2.textDim,
3984
4103
  uiTransform: { margin: { left: 6 } }
3985
4104
  }
3986
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 6 } } }, !this.streamData.isLive && /* @__PURE__ */ import_react_ecs6.default.createElement(
3987
- import_react_ecs6.Button,
4105
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 6 } } }, !this.streamData.isLive && /* @__PURE__ */ import_react_ecs7.default.createElement(
4106
+ import_react_ecs7.Button,
3988
4107
  {
3989
4108
  uiTransform: { width: this.s(110), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
3990
4109
  uiBackground: { color: this.streamControlling ? C2.btn : C2.green },
@@ -3993,8 +4112,8 @@ var AdminPanelUIModule = class {
3993
4112
  color: C2.text,
3994
4113
  onMouseDown: () => this.startStream()
3995
4114
  }
3996
- ), this.streamData.isLive && /* @__PURE__ */ import_react_ecs6.default.createElement(
3997
- import_react_ecs6.Button,
4115
+ ), this.streamData.isLive && /* @__PURE__ */ import_react_ecs7.default.createElement(
4116
+ import_react_ecs7.Button,
3998
4117
  {
3999
4118
  uiTransform: { width: this.s(110), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4000
4119
  uiBackground: { color: this.streamControlling ? C2.btn : C2.red },
@@ -4003,8 +4122,8 @@ var AdminPanelUIModule = class {
4003
4122
  color: C2.text,
4004
4123
  onMouseDown: () => this.stopStream()
4005
4124
  }
4006
- ), this.streamData.isLive && (this.streamData.hlsUrl || this.streamData.locked === true) && /* @__PURE__ */ import_react_ecs6.default.createElement(
4007
- import_react_ecs6.Button,
4125
+ ), this.streamData.isLive && (this.streamData.hlsUrl || this.streamData.locked === true) && /* @__PURE__ */ import_react_ecs7.default.createElement(
4126
+ import_react_ecs7.Button,
4008
4127
  {
4009
4128
  uiTransform: { width: this.s(100), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4010
4129
  uiBackground: { color: C2.cyan },
@@ -4013,8 +4132,8 @@ var AdminPanelUIModule = class {
4013
4132
  color: C2.text,
4014
4133
  onMouseDown: () => this.playStreamOnScreen()
4015
4134
  }
4016
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4017
- import_react_ecs6.Button,
4135
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4136
+ import_react_ecs7.Button,
4018
4137
  {
4019
4138
  uiTransform: { width: this.s(80), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4020
4139
  uiBackground: { color: C2.btn },
@@ -4023,8 +4142,8 @@ var AdminPanelUIModule = class {
4023
4142
  color: C2.text,
4024
4143
  onMouseDown: () => this.refreshStreamStatus()
4025
4144
  }
4026
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4027
- import_react_ecs6.Button,
4145
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4146
+ import_react_ecs7.Button,
4028
4147
  {
4029
4148
  uiTransform: { width: this.s(95), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4030
4149
  uiBackground: { color: this.keyRotating ? C2.btn : C2.yellow },
@@ -4033,8 +4152,8 @@ var AdminPanelUIModule = class {
4033
4152
  color: C2.text,
4034
4153
  onMouseDown: () => this.rotateStreamKey()
4035
4154
  }
4036
- ), !this.streamData.isLive && !this.channelDeleteLook && /* @__PURE__ */ import_react_ecs6.default.createElement(
4037
- import_react_ecs6.Button,
4155
+ ), !this.streamData.isLive && !this.channelDeleteLook && /* @__PURE__ */ import_react_ecs7.default.createElement(
4156
+ import_react_ecs7.Button,
4038
4157
  {
4039
4158
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4040
4159
  uiBackground: { color: this.channelDeleting ? C2.btn : C2.red },
@@ -4043,8 +4162,8 @@ var AdminPanelUIModule = class {
4043
4162
  color: C2.text,
4044
4163
  onMouseDown: () => this.deleteChannel()
4045
4164
  }
4046
- )), !this.streamData.isLive && this.channelDeleteLook && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 }, padding: 6 }, uiBackground: { color: C2.section } }, /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "DELETE THIS CHANNEL?", fontSize: t.labelSmall, color: C2.red, uiTransform: { height: this.s(18) } }), channelDeleteLines(this.channelDeleteLook, this.channelDeleteChanged).map((line, i) => /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { key: `delete-line-${i}`, value: line, fontSize: t.status, color: line.startsWith("WHAT") ? C2.yellow : C2.text, uiTransform: { height: this.s(18) } })), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", margin: { top: 4 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4047
- import_react_ecs6.Button,
4165
+ )), !this.streamData.isLive && this.channelDeleteLook && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 }, padding: 6 }, uiBackground: { color: C2.section } }, /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "DELETE THIS CHANNEL?", fontSize: t.labelSmall, color: C2.red, uiTransform: { height: this.s(18) } }), channelDeleteLines(this.channelDeleteLook, this.channelDeleteChanged).map((line, i) => /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { key: `delete-line-${i}`, value: line, fontSize: t.status, color: line.startsWith("WHAT") ? C2.yellow : C2.text, uiTransform: { height: this.s(18) } })), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", margin: { top: 4 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4166
+ import_react_ecs7.Button,
4048
4167
  {
4049
4168
  uiTransform: { width: this.s(120), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4050
4169
  uiBackground: { color: this.channelDeleting ? C2.btn : C2.red },
@@ -4053,8 +4172,8 @@ var AdminPanelUIModule = class {
4053
4172
  color: C2.text,
4054
4173
  onMouseDown: () => this.confirmDeleteChannel()
4055
4174
  }
4056
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4057
- import_react_ecs6.Button,
4175
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4176
+ import_react_ecs7.Button,
4058
4177
  {
4059
4178
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4060
4179
  uiBackground: { color: C2.btn },
@@ -4063,8 +4182,8 @@ var AdminPanelUIModule = class {
4063
4182
  color: C2.text,
4064
4183
  onMouseDown: () => this.cancelDeleteChannel()
4065
4184
  }
4066
- ))), this.streamControlStatus === "started" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Stream started - begin broadcasting in OBS", fontSize: t.status, color: C2.green }), this.streamControlStatus === "stopped" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Stream stopped", fontSize: t.status, color: C2.textDim }), this.keyRotateStatus === "success" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Key rotated! Update OBS", fontSize: t.status, color: C2.green }), this.keyRotateStatus === "error" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Failed to rotate key", fontSize: t.status, color: C2.red }), this.channelDeleteError && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: this.channelDeleteError, fontSize: t.status, color: C2.red }), this.streamControlStatus === "error" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Stream control failed", fontSize: t.status, color: C2.red })), /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "PLAY NOW", color: C2.orange }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4067
- import_react_ecs6.Input,
4185
+ ))), this.streamControlStatus === "started" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Stream started - begin broadcasting in OBS", fontSize: t.status, color: C2.green }), this.streamControlStatus === "stopped" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Stream stopped", fontSize: t.status, color: C2.textDim }), this.keyRotateStatus === "success" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Key rotated! Update OBS", fontSize: t.status, color: C2.green }), this.keyRotateStatus === "error" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Failed to rotate key", fontSize: t.status, color: C2.red }), this.channelDeleteError && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: this.channelDeleteError, fontSize: t.status, color: C2.red }), this.streamControlStatus === "error" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Stream control failed", fontSize: t.status, color: C2.red })), /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "PLAY NOW", color: C2.orange }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4186
+ import_react_ecs7.Input,
4068
4187
  {
4069
4188
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4070
4189
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4077,8 +4196,8 @@ var AdminPanelUIModule = class {
4077
4196
  this.customVideoUrl = val;
4078
4197
  }
4079
4198
  }
4080
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4081
- import_react_ecs6.Button,
4199
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4200
+ import_react_ecs7.Button,
4082
4201
  {
4083
4202
  uiTransform: { width: this.s(75), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4084
4203
  uiBackground: { color: C2.green },
@@ -4087,8 +4206,8 @@ var AdminPanelUIModule = class {
4087
4206
  color: C2.text,
4088
4207
  onMouseDown: () => this.playNow()
4089
4208
  }
4090
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4091
- import_react_ecs6.Button,
4209
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4210
+ import_react_ecs7.Button,
4092
4211
  {
4093
4212
  uiTransform: { width: this.s(65), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 6 } },
4094
4213
  uiBackground: { color: C2.btn },
@@ -4099,16 +4218,16 @@ var AdminPanelUIModule = class {
4099
4218
  this.customVideoUrl = "";
4100
4219
  }
4101
4220
  }
4102
- )), this.videoStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
4103
- import_react_ecs6.Label,
4221
+ )), this.videoStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4222
+ import_react_ecs7.Label,
4104
4223
  {
4105
4224
  value: this.videoStatus,
4106
4225
  fontSize: t.status,
4107
4226
  color: this.videoStatus.startsWith("Not sent") || this.videoStatus === LOCKED_LINE || this.videoStatus === UNAVAILABLE_LINE ? C2.red : C2.green,
4108
4227
  uiTransform: { height: this.s(18), margin: { bottom: 6 } }
4109
4228
  }
4110
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "PLAYBACK", color: C2.green }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4111
- import_react_ecs6.Button,
4229
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "PLAYBACK", color: C2.green }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4230
+ import_react_ecs7.Button,
4112
4231
  {
4113
4232
  uiTransform: { width: this.s(75), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4114
4233
  uiBackground: { color: C2.green },
@@ -4117,8 +4236,8 @@ var AdminPanelUIModule = class {
4117
4236
  color: C2.text,
4118
4237
  onMouseDown: () => this.playbackPlay()
4119
4238
  }
4120
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4121
- import_react_ecs6.Button,
4239
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4240
+ import_react_ecs7.Button,
4122
4241
  {
4123
4242
  uiTransform: { width: this.s(75), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4124
4243
  uiBackground: { color: C2.red },
@@ -4127,8 +4246,8 @@ var AdminPanelUIModule = class {
4127
4246
  color: C2.text,
4128
4247
  onMouseDown: () => this.playbackStop()
4129
4248
  }
4130
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4131
- import_react_ecs6.Button,
4249
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4250
+ import_react_ecs7.Button,
4132
4251
  {
4133
4252
  uiTransform: { width: this.s(100), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4134
4253
  uiBackground: { color: C2.btn },
@@ -4137,8 +4256,8 @@ var AdminPanelUIModule = class {
4137
4256
  color: C2.text,
4138
4257
  onMouseDown: () => this.resetDefault()
4139
4258
  }
4140
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "VIDEO SLOTS", color: C2.cyan }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 10 } } }, ["slot1", "slot2", "slot3", "slot4", "slot5"].map((slot, i) => /* @__PURE__ */ import_react_ecs6.default.createElement(
4141
- import_react_ecs6.Button,
4259
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "VIDEO SLOTS", color: C2.cyan }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 10 } } }, ["slot1", "slot2", "slot3", "slot4", "slot5"].map((slot, i) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4260
+ import_react_ecs7.Button,
4142
4261
  {
4143
4262
  key: `play-${slot}`,
4144
4263
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
@@ -4148,8 +4267,8 @@ var AdminPanelUIModule = class {
4148
4267
  color: C2.text,
4149
4268
  onMouseDown: () => this.pressSlot(slot)
4150
4269
  }
4151
- ))), /* @__PURE__ */ import_react_ecs6.default.createElement(
4152
- import_react_ecs6.Button,
4270
+ ))), /* @__PURE__ */ import_react_ecs7.default.createElement(
4271
+ import_react_ecs7.Button,
4153
4272
  {
4154
4273
  uiTransform: { height: this.s(24) },
4155
4274
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0) },
@@ -4162,16 +4281,16 @@ var AdminPanelUIModule = class {
4162
4281
  };
4163
4282
  this.ModTab = () => {
4164
4283
  const t = this.theme;
4165
- return /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", width: "100%", padding: 10 } }, this.modStatus === "loading" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Loading...", fontSize: t.status, color: C2.yellow }), this.modStatus === "saved" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Saved!", fontSize: t.status, color: C2.green }), this.modStatus === "error" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "Error - check input", fontSize: t.status, color: C2.red }), this.kickStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
4166
- import_react_ecs6.Label,
4284
+ return /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", width: "100%", padding: 10 } }, this.modStatus === "loading" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Loading...", fontSize: t.status, color: C2.yellow }), this.modStatus === "saved" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Saved!", fontSize: t.status, color: C2.green }), this.modStatus === "error" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "Error - check input", fontSize: t.status, color: C2.red }), this.kickStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4285
+ import_react_ecs7.Label,
4167
4286
  {
4168
4287
  value: this.kickStatus,
4169
4288
  fontSize: t.status,
4170
4289
  color: this.kickStatus.startsWith("Kick not sent") ? C2.red : C2.green,
4171
4290
  uiTransform: { height: this.s(18) }
4172
4291
  }
4173
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "BROADCAST", color: C2.orange }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4174
- import_react_ecs6.Input,
4292
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "BROADCAST", color: C2.orange }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4293
+ import_react_ecs7.Input,
4175
4294
  {
4176
4295
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4177
4296
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4184,8 +4303,8 @@ var AdminPanelUIModule = class {
4184
4303
  this.broadcastText = val;
4185
4304
  }
4186
4305
  }
4187
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4188
- import_react_ecs6.Button,
4306
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4307
+ import_react_ecs7.Button,
4189
4308
  {
4190
4309
  uiTransform: { width: this.s(65), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4191
4310
  uiBackground: { color: C2.orange },
@@ -4194,16 +4313,16 @@ var AdminPanelUIModule = class {
4194
4313
  color: C2.text,
4195
4314
  onMouseDown: () => this.sendBroadcast()
4196
4315
  }
4197
- )), this.broadcastStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
4198
- import_react_ecs6.Label,
4316
+ )), this.broadcastStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4317
+ import_react_ecs7.Label,
4199
4318
  {
4200
4319
  value: this.broadcastStatus,
4201
4320
  fontSize: t.status,
4202
4321
  color: this.broadcastStatus.startsWith("Not sent") ? C2.red : C2.green,
4203
4322
  uiTransform: { height: this.s(18), margin: { bottom: 6 } }
4204
4323
  }
4205
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "CHAOS MODE", color: C2.red }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4206
- import_react_ecs6.Button,
4324
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "CHAOS MODE", color: C2.red }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4325
+ import_react_ecs7.Button,
4207
4326
  {
4208
4327
  uiTransform: { width: this.s(130), height: this.s(UI_DIMENSIONS.admin.buttonHeight), margin: 4 },
4209
4328
  uiBackground: { color: C2.red },
@@ -4212,8 +4331,8 @@ var AdminPanelUIModule = class {
4212
4331
  color: C2.text,
4213
4332
  onMouseDown: () => this.kickAll()
4214
4333
  }
4215
- )), this.venue && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "PRIVATE MODE", color: C2.yellow }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "While ON, only citizens get in", fontSize: t.labelSmall, color: C2.textDim, uiTransform: { height: this.s(18), margin: { bottom: 4 } } }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap" } }, [true, false].map((on) => /* @__PURE__ */ import_react_ecs6.default.createElement(
4216
- import_react_ecs6.Button,
4334
+ )), this.venue && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "PRIVATE MODE", color: C2.yellow }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "While ON, only citizens get in", fontSize: t.labelSmall, color: C2.textDim, uiTransform: { height: this.s(18), margin: { bottom: 4 } } }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap" } }, [true, false].map((on) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4335
+ import_react_ecs7.Button,
4217
4336
  {
4218
4337
  key: `private-${on ? "on" : "off"}`,
4219
4338
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
@@ -4223,22 +4342,22 @@ var AdminPanelUIModule = class {
4223
4342
  color: this.privateModeOn === on ? import_math7.Color4.Black() : C2.text,
4224
4343
  onMouseDown: () => this.setPrivateMode(on)
4225
4344
  }
4226
- ))), this.privateStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
4227
- import_react_ecs6.Label,
4345
+ ))), this.privateStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4346
+ import_react_ecs7.Label,
4228
4347
  {
4229
4348
  value: this.privateStatus,
4230
4349
  fontSize: t.status,
4231
4350
  color: this.privateStatus.startsWith("Not sent") ? C2.red : C2.green,
4232
4351
  uiTransform: { height: this.s(18) }
4233
4352
  }
4234
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "SCENE ADMINS", color: C2.purple }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, this.sceneAdmins.length === 0 && this.modStatus !== "loading" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "No scene admins", fontSize: t.labelSmall, color: C2.textDim }), this.sceneAdmins.map((wallet, i) => /* @__PURE__ */ import_react_ecs6.default.createElement(
4235
- import_react_ecs6.UiEntity,
4353
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "SCENE ADMINS", color: C2.purple }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, this.sceneAdmins.length === 0 && this.modStatus !== "loading" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "No scene admins", fontSize: t.labelSmall, color: C2.textDim }), this.sceneAdmins.map((wallet, i) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4354
+ import_react_ecs7.UiEntity,
4236
4355
  {
4237
4356
  key: `admin-${i}`,
4238
4357
  uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 5 }, width: "100%" }
4239
4358
  },
4240
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4241
- import_react_ecs6.Label,
4359
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4360
+ import_react_ecs7.Label,
4242
4361
  {
4243
4362
  value: `${wallet.slice(0, 6)}...${wallet.slice(-4)}`,
4244
4363
  fontSize: t.label,
@@ -4246,8 +4365,8 @@ var AdminPanelUIModule = class {
4246
4365
  uiTransform: { width: this.s(130) }
4247
4366
  }
4248
4367
  ),
4249
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4250
- import_react_ecs6.Button,
4368
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4369
+ import_react_ecs7.Button,
4251
4370
  {
4252
4371
  uiTransform: { width: this.s(70), height: this.s(28), margin: { left: 8 } },
4253
4372
  uiBackground: { color: C2.btn },
@@ -4257,8 +4376,8 @@ var AdminPanelUIModule = class {
4257
4376
  onMouseDown: () => this.removeSceneAdmin(wallet)
4258
4377
  }
4259
4378
  )
4260
- ))), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4261
- import_react_ecs6.Input,
4379
+ ))), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4380
+ import_react_ecs7.Input,
4262
4381
  {
4263
4382
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4264
4383
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4271,8 +4390,8 @@ var AdminPanelUIModule = class {
4271
4390
  this.newAdminWallet = val;
4272
4391
  }
4273
4392
  }
4274
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4275
- import_react_ecs6.Button,
4393
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4394
+ import_react_ecs7.Button,
4276
4395
  {
4277
4396
  uiTransform: { width: this.s(60), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4278
4397
  uiBackground: { color: C2.purple },
@@ -4283,14 +4402,14 @@ var AdminPanelUIModule = class {
4283
4402
  if (this.newAdminWallet) this.addSceneAdmin(this.newAdminWallet);
4284
4403
  }
4285
4404
  }
4286
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(this.SectionHead, { label: "BANNED WALLETS", color: C2.red }), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, this.bannedWallets.length === 0 && this.modStatus !== "loading" && /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: "No banned wallets", fontSize: t.labelSmall, color: C2.textDim }), this.bannedWallets.map((wallet, i) => /* @__PURE__ */ import_react_ecs6.default.createElement(
4287
- import_react_ecs6.UiEntity,
4405
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(this.SectionHead, { label: "BANNED WALLETS", color: C2.red }), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "column", margin: { bottom: 6 } } }, this.bannedWallets.length === 0 && this.modStatus !== "loading" && /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: "No banned wallets", fontSize: t.labelSmall, color: C2.textDim }), this.bannedWallets.map((wallet, i) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4406
+ import_react_ecs7.UiEntity,
4288
4407
  {
4289
4408
  key: `ban-${i}`,
4290
4409
  uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 5 }, width: "100%" }
4291
4410
  },
4292
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4293
- import_react_ecs6.Label,
4411
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4412
+ import_react_ecs7.Label,
4294
4413
  {
4295
4414
  value: `${wallet.slice(0, 6)}...${wallet.slice(-4)}`,
4296
4415
  fontSize: t.label,
@@ -4298,8 +4417,8 @@ var AdminPanelUIModule = class {
4298
4417
  uiTransform: { width: this.s(130) }
4299
4418
  }
4300
4419
  ),
4301
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4302
- import_react_ecs6.Button,
4420
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4421
+ import_react_ecs7.Button,
4303
4422
  {
4304
4423
  uiTransform: { width: this.s(70), height: this.s(28), margin: { left: 8 } },
4305
4424
  uiBackground: { color: C2.green },
@@ -4309,8 +4428,8 @@ var AdminPanelUIModule = class {
4309
4428
  onMouseDown: () => this.unbanWallet(wallet)
4310
4429
  }
4311
4430
  )
4312
- ))), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4313
- import_react_ecs6.Input,
4431
+ ))), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4432
+ import_react_ecs7.Input,
4314
4433
  {
4315
4434
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4316
4435
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4323,8 +4442,8 @@ var AdminPanelUIModule = class {
4323
4442
  this.newBanWallet = val;
4324
4443
  }
4325
4444
  }
4326
- ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4327
- import_react_ecs6.Button,
4445
+ ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4446
+ import_react_ecs7.Button,
4328
4447
  {
4329
4448
  uiTransform: { width: this.s(60), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4330
4449
  uiBackground: { color: C2.red },
@@ -4335,8 +4454,8 @@ var AdminPanelUIModule = class {
4335
4454
  if (this.newBanWallet) this.banWallet(this.newBanWallet);
4336
4455
  }
4337
4456
  }
4338
- )), /* @__PURE__ */ import_react_ecs6.default.createElement(
4339
- import_react_ecs6.Button,
4457
+ )), /* @__PURE__ */ import_react_ecs7.default.createElement(
4458
+ import_react_ecs7.Button,
4340
4459
  {
4341
4460
  uiTransform: { height: this.s(24) },
4342
4461
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0) },
@@ -4382,8 +4501,8 @@ var AdminPanelUIModule = class {
4382
4501
  if (!tabs.find((tab) => tab.id === this.activeTab) && tabs.length > 0) {
4383
4502
  this.activeTab = tabs[0].id;
4384
4503
  }
4385
- return /* @__PURE__ */ import_react_ecs6.default.createElement(
4386
- import_react_ecs6.UiEntity,
4504
+ return /* @__PURE__ */ import_react_ecs7.default.createElement(
4505
+ import_react_ecs7.UiEntity,
4387
4506
  {
4388
4507
  uiTransform: {
4389
4508
  width: "100%",
@@ -4392,42 +4511,33 @@ var AdminPanelUIModule = class {
4392
4511
  }
4393
4512
  },
4394
4513
  this.renderScaledNotification(),
4395
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4396
- import_react_ecs6.UiEntity,
4514
+ this.client.isPhone ? toolbarButton(2, { children: [this.renderToggleFace()] }, true, this.client.uiScale) : /* @__PURE__ */ import_react_ecs7.default.createElement(
4515
+ import_react_ecs7.UiEntity,
4397
4516
  {
4398
4517
  uiTransform: {
4399
4518
  position: { right: 20 + this.s(100) + 10 + this.s(100) + 10, bottom: 10 },
4400
4519
  positionType: "absolute"
4401
4520
  }
4402
4521
  },
4403
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4404
- import_react_ecs6.Button,
4405
- {
4406
- uiTransform: { width: this.s(100), height: this.s(45) },
4407
- uiBackground: { color: this.panelOpen ? C2.btn : C2.header },
4408
- value: this.panelOpen ? "CLOSE" : "ADMIN",
4409
- fontSize: this.s(14),
4410
- color: C2.text,
4411
- onMouseDown: () => this.toggle()
4412
- }
4413
- )
4522
+ this.renderToggleFace()
4414
4523
  ),
4415
- this.panelOpen && /* @__PURE__ */ import_react_ecs6.default.createElement(
4416
- import_react_ecs6.UiEntity,
4524
+ this.panelOpen && /* @__PURE__ */ import_react_ecs7.default.createElement(
4525
+ import_react_ecs7.UiEntity,
4417
4526
  {
4418
4527
  key: `admin-panel-${this.client.uiScale}`,
4419
4528
  uiTransform: {
4420
4529
  width: this.s(UI_DIMENSIONS.admin.width),
4421
4530
  height: this.s(UI_DIMENSIONS.admin.height),
4422
4531
  maxHeight: this.s(UI_DIMENSIONS.admin.maxHeight),
4423
- position: { right: UI_DIMENSIONS.chat.right + this.s(UI_DIMENSIONS.chat.width) + 10, bottom: UI_DIMENSIONS.admin.bottom },
4532
+ // On a phone, left of the toolbar's column (2.12.0); elsewhere left of the chat panel, as before
4533
+ position: { right: this.client.panelRight(UI_DIMENSIONS.chat.right + this.s(UI_DIMENSIONS.chat.width) + 10), bottom: UI_DIMENSIONS.admin.bottom },
4424
4534
  positionType: "absolute",
4425
4535
  flexDirection: "column"
4426
4536
  },
4427
4537
  uiBackground: { color: C2.bg }
4428
4538
  },
4429
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4430
- import_react_ecs6.UiEntity,
4539
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4540
+ import_react_ecs7.UiEntity,
4431
4541
  {
4432
4542
  uiTransform: {
4433
4543
  width: "100%",
@@ -4439,9 +4549,9 @@ var AdminPanelUIModule = class {
4439
4549
  },
4440
4550
  uiBackground: { color: C2.header }
4441
4551
  },
4442
- /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: this.config.title || "ADMIN PANEL", fontSize: t.header, color: C2.text }),
4443
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4444
- import_react_ecs6.Button,
4552
+ /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: this.config.title || "ADMIN PANEL", fontSize: t.header, color: C2.text }),
4553
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4554
+ import_react_ecs7.Button,
4445
4555
  {
4446
4556
  uiTransform: { width: this.s(28), height: this.s(28) },
4447
4557
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0.3) },
@@ -4452,9 +4562,9 @@ var AdminPanelUIModule = class {
4452
4562
  }
4453
4563
  )
4454
4564
  ),
4455
- /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { width: "100%", height: this.s(UI_DIMENSIONS.admin.tabHeight), flexDirection: "row" } }, tabs.map((tab) => /* @__PURE__ */ import_react_ecs6.default.createElement(this.TabBtn, { label: tab.label, tab: tab.id }))),
4456
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4457
- import_react_ecs6.UiEntity,
4565
+ /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { width: "100%", height: this.s(UI_DIMENSIONS.admin.tabHeight), flexDirection: "row" } }, tabs.map((tab) => /* @__PURE__ */ import_react_ecs7.default.createElement(this.TabBtn, { label: tab.label, tab: tab.id }))),
4566
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4567
+ import_react_ecs7.UiEntity,
4458
4568
  {
4459
4569
  uiTransform: {
4460
4570
  width: "100%",
@@ -4463,13 +4573,13 @@ var AdminPanelUIModule = class {
4463
4573
  flexDirection: "column"
4464
4574
  }
4465
4575
  },
4466
- this.activeTab === "controls" && this.venue && this.controls.length > 0 && /* @__PURE__ */ import_react_ecs6.default.createElement(this.ControlsTab, null),
4467
- this.activeTab === "video" && /* @__PURE__ */ import_react_ecs6.default.createElement(this.VideoTab, null),
4468
- this.activeTab === "mod" && this.isOwner && /* @__PURE__ */ import_react_ecs6.default.createElement(this.ModTab, null),
4576
+ this.activeTab === "controls" && this.venue && this.controls.length > 0 && /* @__PURE__ */ import_react_ecs7.default.createElement(this.ControlsTab, null),
4577
+ this.activeTab === "video" && /* @__PURE__ */ import_react_ecs7.default.createElement(this.VideoTab, null),
4578
+ this.activeTab === "mod" && this.isOwner && /* @__PURE__ */ import_react_ecs7.default.createElement(this.ModTab, null),
4469
4579
  this.config.sceneTabs?.map((tab) => this.activeTab === tab.id && tab.render())
4470
4580
  ),
4471
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4472
- import_react_ecs6.UiEntity,
4581
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4582
+ import_react_ecs7.UiEntity,
4473
4583
  {
4474
4584
  uiTransform: {
4475
4585
  width: "100%",
@@ -4479,8 +4589,8 @@ var AdminPanelUIModule = class {
4479
4589
  },
4480
4590
  uiBackground: { color: C2.section }
4481
4591
  },
4482
- /* @__PURE__ */ import_react_ecs6.default.createElement(
4483
- import_react_ecs6.Button,
4592
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
4593
+ import_react_ecs7.Button,
4484
4594
  {
4485
4595
  uiTransform: { height: this.s(24) },
4486
4596
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0) },
@@ -4693,7 +4803,7 @@ var AdminPanelUIModule = class {
4693
4803
  */
4694
4804
  show() {
4695
4805
  if (this.panelOpen) return;
4696
- this.client.closeOtherPanels("admin");
4806
+ this.client.panelOpened("admin");
4697
4807
  this.panelOpen = true;
4698
4808
  if (this.activeTab === "video") {
4699
4809
  this.startStreamPolling();
@@ -5647,8 +5757,8 @@ var AdminPanelUIModule = class {
5647
5757
  /** A control's button (2026-11-18): the option's label, highlighted while that option is current on this copy */
5648
5758
  controlButton(control, option, label) {
5649
5759
  const current = this.currentOption[control.id] === option;
5650
- return /* @__PURE__ */ import_react_ecs6.default.createElement(
5651
- import_react_ecs6.Button,
5760
+ return /* @__PURE__ */ import_react_ecs7.default.createElement(
5761
+ import_react_ecs7.Button,
5652
5762
  {
5653
5763
  key: `control-${control.id}-${option}`,
5654
5764
  uiTransform: { minWidth: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4, padding: { left: 10, right: 10 } },
@@ -5670,8 +5780,8 @@ var AdminPanelUIModule = class {
5670
5780
  if (!state.visible) return null;
5671
5781
  const N2 = UI_DIMENSIONS.notification;
5672
5782
  const colors = THEME.colors;
5673
- return /* @__PURE__ */ import_react_ecs6.default.createElement(
5674
- import_react_ecs6.UiEntity,
5783
+ return /* @__PURE__ */ import_react_ecs7.default.createElement(
5784
+ import_react_ecs7.UiEntity,
5675
5785
  {
5676
5786
  uiTransform: {
5677
5787
  positionType: "absolute",
@@ -5681,8 +5791,8 @@ var AdminPanelUIModule = class {
5681
5791
  alignItems: "center"
5682
5792
  }
5683
5793
  },
5684
- /* @__PURE__ */ import_react_ecs6.default.createElement(
5685
- import_react_ecs6.UiEntity,
5794
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
5795
+ import_react_ecs7.UiEntity,
5686
5796
  {
5687
5797
  uiTransform: {
5688
5798
  minWidth: this.s(200),
@@ -5694,15 +5804,15 @@ var AdminPanelUIModule = class {
5694
5804
  },
5695
5805
  uiBackground: { color: colors.panel }
5696
5806
  },
5697
- /* @__PURE__ */ import_react_ecs6.default.createElement(
5698
- import_react_ecs6.UiEntity,
5807
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
5808
+ import_react_ecs7.UiEntity,
5699
5809
  {
5700
5810
  uiTransform: { width: N2.borderWidth, height: "100%" },
5701
5811
  uiBackground: { color: colors.cyan }
5702
5812
  }
5703
5813
  ),
5704
- /* @__PURE__ */ import_react_ecs6.default.createElement(
5705
- import_react_ecs6.UiEntity,
5814
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
5815
+ import_react_ecs7.UiEntity,
5706
5816
  {
5707
5817
  uiTransform: {
5708
5818
  flexGrow: 1,
@@ -5712,8 +5822,8 @@ var AdminPanelUIModule = class {
5712
5822
  alignItems: "center"
5713
5823
  }
5714
5824
  },
5715
- /* @__PURE__ */ import_react_ecs6.default.createElement(
5716
- import_react_ecs6.Label,
5825
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
5826
+ import_react_ecs7.Label,
5717
5827
  {
5718
5828
  value: state.text,
5719
5829
  fontSize: this.s(N2.fontSize),
@@ -5722,8 +5832,8 @@ var AdminPanelUIModule = class {
5722
5832
  }
5723
5833
  )
5724
5834
  ),
5725
- /* @__PURE__ */ import_react_ecs6.default.createElement(
5726
- import_react_ecs6.UiEntity,
5835
+ /* @__PURE__ */ import_react_ecs7.default.createElement(
5836
+ import_react_ecs7.UiEntity,
5727
5837
  {
5728
5838
  uiTransform: { width: 5, height: 5, margin: { right: 10 } },
5729
5839
  uiBackground: { color: colors.cyan }
@@ -5732,16 +5842,31 @@ var AdminPanelUIModule = class {
5732
5842
  )
5733
5843
  );
5734
5844
  }
5845
+ /** The ADMIN / CLOSE button itself; its place is the row's or, on a phone, the column's (2.12.0) */
5846
+ renderToggleFace() {
5847
+ return /* @__PURE__ */ import_react_ecs7.default.createElement(
5848
+ import_react_ecs7.Button,
5849
+ {
5850
+ uiTransform: { width: this.s(100), height: this.s(45) },
5851
+ uiBackground: { color: this.panelOpen ? C2.btn : C2.header },
5852
+ value: this.panelOpen ? "CLOSE" : "ADMIN",
5853
+ fontSize: this.s(14),
5854
+ color: C2.text,
5855
+ onMouseDown: () => this.toggle()
5856
+ }
5857
+ );
5858
+ }
5735
5859
  };
5736
5860
 
5737
5861
  // src/StaticTVClient.ts
5862
+ var import_Runtime2 = require("~system/Runtime");
5738
5863
  var import_ecs5 = require("@dcl/sdk/ecs");
5739
5864
  var utils = __toESM(require("@dcl-sdk/utils"));
5740
5865
  var DEFAULT_BASE_URL = "https://thestatic.tv/api/v1/dcl";
5741
5866
  var DEFAULT_FALLBACK_VIDEO = "https://media.thestatic.tv/fallback-loop.mp4";
5742
5867
  var KEY_TYPE_CHANNEL = "channel";
5743
5868
  var KEY_TYPE_SCENE = "scene";
5744
- var StaticTVClient = class {
5869
+ var _StaticTVClient = class _StaticTVClient {
5745
5870
  /**
5746
5871
  * Create a new StaticTVClient
5747
5872
  *
@@ -5801,6 +5926,13 @@ var StaticTVClient = class {
5801
5926
  this.adminPanel = null;
5802
5927
  /** UI scale - fixed at 1.0. DCL's UI system auto-scales based on viewport. */
5803
5928
  this.uiScale = 1;
5929
+ /** The explorer's platform, read once at construction (2.12.0); unknown until it answers, and if it cannot */
5930
+ this._platform = "unknown";
5931
+ /**
5932
+ * Which panels close when one opens (2.12.0, src/ui/toolbar.ts): on a phone every other one, the SDK's and a
5933
+ * scene's (registerPanel); elsewhere the guide and the admin panel close each other, as before.
5934
+ */
5935
+ this.panelRules = new PanelRules(() => this.isPhone);
5804
5936
  // =============================================================================
5805
5937
  // --- VIDEO PLAYBACK (Internal handler for videoScreen) ---
5806
5938
  // =============================================================================
@@ -5841,6 +5973,16 @@ var StaticTVClient = class {
5841
5973
  clearInterval: dclClearInterval,
5842
5974
  log: (msg, ...args) => this.log(msg, ...args)
5843
5975
  });
5976
+ this.readPlatform();
5977
+ this.panelRules.register("guide", () => {
5978
+ if (this.guideUI?.isVisible) this.guideUI.hide();
5979
+ });
5980
+ this.panelRules.register("chat", () => {
5981
+ if (this.chatUI?.isVisible) this.chatUI.hide();
5982
+ });
5983
+ this.panelRules.register("admin", () => {
5984
+ if (this.adminPanel?.isOpen) this.adminPanel.hide();
5985
+ });
5844
5986
  if (!config.apiKey) {
5845
5987
  this._disabled = true;
5846
5988
  this._keyType = null;
@@ -6691,16 +6833,75 @@ var StaticTVClient = class {
6691
6833
  }
6692
6834
  /**
6693
6835
  * Close Admin/Guide panels (they share the same screen space)
6694
- * Chat is independent and stays open.
6836
+ * Chat is independent and stays open. On a phone (2.12.0) every other panel closes: the same as panelOpened().
6695
6837
  * @param except The panel that should stay open: 'admin' | 'guide'
6696
6838
  */
6697
6839
  closeOtherPanels(except) {
6698
- if (except !== "guide" && this.guideUI?.isVisible) {
6699
- this.guideUI.hide();
6840
+ this.panelRules.opened(except);
6841
+ }
6842
+ // ===========================================================================
6843
+ // The toolbar on a phone (2.12.0, 2026-12-01; src/ui/toolbar.ts)
6844
+ // ===========================================================================
6845
+ /** Ask the explorer which platform this is, once; a failed or missing call leaves it unknown (the desktop layout) */
6846
+ readPlatform() {
6847
+ try {
6848
+ (0, import_Runtime2.getExplorerInformation)({}).then((answer) => {
6849
+ this._platform = platformOf(answer);
6850
+ this.log(`Platform: ${this._platform}`);
6851
+ }).catch(() => {
6852
+ });
6853
+ } catch {
6700
6854
  }
6701
- if (except !== "admin" && this.adminPanel?.isOpen) {
6702
- this.adminPanel.hide();
6855
+ }
6856
+ /** The explorer's platform: 'desktop', 'mobile', 'vr', 'web', or 'unknown' until it answers (and if it cannot) */
6857
+ get platform() {
6858
+ return this._platform;
6859
+ }
6860
+ /** A phone: the toolbar stands in a column on the right edge, panels open to its left, one at a time */
6861
+ get isPhone() {
6862
+ return isPhonePlatform(this._platform);
6863
+ }
6864
+ /**
6865
+ * Draw one of the scene's own toolbar buttons in its slot: the row along the bottom right on desktop (where a scene
6866
+ * placed its own by hand before), the column on a phone. Slots count from the right (the row) or the top (the
6867
+ * column): 0 is CHAT's, 1 GUIDE's, 2 ADMIN's (for a non-admin the scene's first button may take it), then the
6868
+ * scene's. `props` is the button's face - its uiBackground, onMouseDown and children - the slot gives its place and
6869
+ * size (a width or height in props.uiTransform wins).
6870
+ *
6871
+ * @example
6872
+ * ```typescript
6873
+ * staticTV.toolbarButton(3, {
6874
+ * uiTransform: { justifyContent: 'center', alignItems: 'center' },
6875
+ * uiBackground: { color: Color4.create(0.2, 0.4, 0.2, 0.9) },
6876
+ * onMouseDown: () => myPanel.toggle(),
6877
+ * children: [ReactEcs.createElement(UiEntity, { uiText: { value: 'MAP', fontSize: 14 } })],
6878
+ * })
6879
+ * ```
6880
+ */
6881
+ toolbarButton(slot, props) {
6882
+ return toolbarButton(slot, props, this.isPhone, this.uiScale);
6883
+ }
6884
+ /** Where a scene's own panel's right edge goes: on a phone just left of the column; elsewhere `desktopRight` */
6885
+ panelRight(desktopRight) {
6886
+ return panelRight(this.isPhone, desktopRight, this.uiScale);
6887
+ }
6888
+ /**
6889
+ * Put one of the scene's own panels under the one-panel rule: on a phone, when another panel opens (the SDK's or the
6890
+ * scene's), `hide` runs. The SDK's own names (guide, chat, admin) are taken. Call panelOpened(name) when it opens.
6891
+ */
6892
+ registerPanel(name, hide) {
6893
+ if (_StaticTVClient.OWN_PANELS.includes(name)) {
6894
+ this.log(`registerPanel: '${name}' is one of the SDK's own panels - pick another name`);
6895
+ return;
6703
6896
  }
6897
+ this.panelRules.register(name, hide);
6898
+ }
6899
+ /**
6900
+ * A panel opened: on a phone every other one closes, the SDK's and the scene's registered ones; elsewhere the guide
6901
+ * and the admin panel close each other, as before, and a scene's own panel closes nothing here.
6902
+ */
6903
+ panelOpened(name) {
6904
+ this.panelRules.opened(name);
6704
6905
  }
6705
6906
  /**
6706
6907
  * Set up the UI renderer for all SDK panels
@@ -6758,6 +6959,9 @@ var StaticTVClient = class {
6758
6959
  this.log("StaticTVClient destroyed");
6759
6960
  }
6760
6961
  };
6962
+ /** The SDK's own panels, which a scene cannot register over */
6963
+ _StaticTVClient.OWN_PANELS = ["guide", "chat", "admin"];
6964
+ var StaticTVClient = _StaticTVClient;
6761
6965
  // Annotate the CommonJS export names for ESM import in node:
6762
6966
  0 && (module.exports = {
6763
6967
  AdminPanelUIModule,