@thestatic-tv/dcl-sdk 2.13.0 → 2.14.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_ecs3 = __toESM(require("@dcl/sdk/react-ecs"));
1326
+ var import_react_ecs2 = __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,112 +1566,8 @@ 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
- var PHONE_EDGE = 0;
1576
- function platformOf(answer) {
1577
- const raw = answer?.platform;
1578
- if (typeof raw !== "string") return "unknown";
1579
- const p = raw.trim().toLowerCase();
1580
- return p === "desktop" || p === "mobile" || p === "vr" || p === "web" ? p : "unknown";
1581
- }
1582
- function isPhonePlatform(platform) {
1583
- return platform === "mobile";
1584
- }
1585
- var scaled = (value, uiScale) => Math.round(value * uiScale);
1586
- function rowRight(slot, uiScale = 1) {
1587
- return TOOLBAR.edge + slot * (scaled(TOOLBAR.buttonWidth, uiScale) + TOOLBAR.gap);
1588
- }
1589
- function columnSlot(slot, uiScale = 1) {
1590
- const h = scaled(TOOLBAR.buttonHeight, uiScale);
1591
- return {
1592
- right: PHONE_EDGE,
1593
- boxHeight: COLUMN_SLOTS * h + (COLUMN_SLOTS - 1) * TOOLBAR.gap,
1594
- above: Math.max(0, slot) * (h + TOOLBAR.gap)
1595
- };
1596
- }
1597
- function panelRight(phone, desktopRight, uiScale = 1) {
1598
- return phone ? PHONE_EDGE + scaled(TOOLBAR.buttonWidth, uiScale) + TOOLBAR.gap : desktopRight;
1599
- }
1600
- var DESKTOP_CLOSES = { guide: ["admin"], admin: ["guide"] };
1601
- var GUIDE_PLACE = ["guide", "admin"];
1602
- function panelsToClose(opened, registered, phone, coversGuide = []) {
1603
- if (phone) return registered.filter((name) => name !== opened);
1604
- const closes = [...DESKTOP_CLOSES[opened] ?? []];
1605
- if (GUIDE_PLACE.includes(opened)) closes.push(...coversGuide);
1606
- if (coversGuide.includes(opened)) closes.push(...GUIDE_PLACE);
1607
- return registered.filter((name) => name !== opened && closes.includes(name));
1608
- }
1609
- var PanelRules = class {
1610
- constructor(phone) {
1611
- this.hides = /* @__PURE__ */ new Map();
1612
- this.coveringGuide = /* @__PURE__ */ new Set();
1613
- this.phone = phone;
1614
- }
1615
- /** Register (or replace) a panel; its hide runs when another panel opens and the rule says so */
1616
- register(name, hide, options = {}) {
1617
- this.hides.set(name, hide);
1618
- if (options.coversGuide === true) this.coveringGuide.add(name);
1619
- else this.coveringGuide.delete(name);
1620
- }
1621
- /** A panel opened: close the ones the rule names. One failing hide does not stop the rest. */
1622
- opened(name) {
1623
- for (const other of panelsToClose(name, [...this.hides.keys()], this.phone(), [...this.coveringGuide])) {
1624
- try {
1625
- this.hides.get(other)?.();
1626
- } catch {
1627
- }
1628
- }
1629
- }
1630
- get names() {
1631
- return [...this.hides.keys()];
1632
- }
1633
- };
1634
-
1635
- // src/ui/toolbar-button.ts
1636
- function toolbarButton(slot, props, phone, uiScale = 1) {
1637
- const width = Math.round(TOOLBAR.buttonWidth * uiScale);
1638
- const height = Math.round(TOOLBAR.buttonHeight * uiScale);
1639
- if (!phone) {
1640
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1641
- ...props,
1642
- uiTransform: {
1643
- positionType: "absolute",
1644
- position: { right: rowRight(slot, uiScale), bottom: TOOLBAR.bottom },
1645
- width,
1646
- height,
1647
- ...props.uiTransform
1648
- }
1649
- });
1650
- }
1651
- const place = columnSlot(slot, uiScale);
1652
- return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1653
- uiTransform: {
1654
- positionType: "absolute",
1655
- position: { right: place.right, top: 0 },
1656
- width,
1657
- height: "100%",
1658
- flexDirection: "column",
1659
- justifyContent: "center"
1660
- },
1661
- children: [
1662
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1663
- uiTransform: { width, height: place.boxHeight, flexDirection: "column", flexShrink: 0 },
1664
- children: [
1665
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, { uiTransform: { width, height: place.above, flexShrink: 0 } }),
1666
- import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1667
- ...props,
1668
- uiTransform: { width, height, flexShrink: 0, ...props.uiTransform }
1669
- })
1670
- ]
1671
- })
1672
- ]
1673
- });
1674
- }
1569
+ // src/version.ts
1570
+ var SDK_VERSION = true ? "2.14.0" : "unknown";
1675
1571
 
1676
1572
  // src/ui/guide-ui.tsx
1677
1573
  function withLock(mapped, v, fallback) {
@@ -1708,7 +1604,7 @@ var GuideUIModule = class {
1708
1604
  if (this.client.isVisitorBlocked) return null;
1709
1605
  const windowW = UI_DIMENSIONS.guide.width;
1710
1606
  const windowH = UI_DIMENSIONS.guide.height;
1711
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1607
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1712
1608
  key: `guide-root-${this.client.uiScale}`,
1713
1609
  uiTransform: {
1714
1610
  width: "100%",
@@ -1937,7 +1833,7 @@ var GuideUIModule = class {
1937
1833
  const nodesPlaylist = this.featuredPlaylists.find((p) => p.name === "NODES");
1938
1834
  const nodesCount = nodesPlaylist ? nodesPlaylist.videos.filter((v) => v.isCreator).length : 0;
1939
1835
  const displayedPlaylists = this.featuredPlaylists.filter((p) => p.name !== "NODES").slice(0, 6);
1940
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1836
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1941
1837
  uiTransform: {
1942
1838
  width: sidebarW,
1943
1839
  minWidth: sidebarW,
@@ -1951,11 +1847,11 @@ var GuideUIModule = class {
1951
1847
  uiBackground: { color: import_math3.Color4.create(0, 0, 0, 0.4) },
1952
1848
  children: [
1953
1849
  // Header & Search
1954
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1850
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1955
1851
  uiTransform: { width: "100%", flexDirection: "column", padding: 10 },
1956
1852
  children: [
1957
1853
  // Title row
1958
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1854
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1959
1855
  uiTransform: {
1960
1856
  width: "100%",
1961
1857
  height: this.s(40),
@@ -1965,7 +1861,7 @@ var GuideUIModule = class {
1965
1861
  },
1966
1862
  children: [
1967
1863
  // Title
1968
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1864
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1969
1865
  uiText: {
1970
1866
  value: "THE STATIC TV",
1971
1867
  fontSize: this.s(UI_DIMENSIONS.guide.sidebar.headerSize),
@@ -1976,7 +1872,7 @@ var GuideUIModule = class {
1976
1872
  ]
1977
1873
  }),
1978
1874
  // Random Signal button
1979
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1875
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1980
1876
  uiTransform: {
1981
1877
  width: "100%",
1982
1878
  height: this.s(40),
@@ -1994,13 +1890,13 @@ var GuideUIModule = class {
1994
1890
  }
1995
1891
  },
1996
1892
  children: [
1997
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1893
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1998
1894
  uiText: { value: ">> RANDOM SIGNAL <<", fontSize: this.s(14), color: THEME.colors.cyan }
1999
1895
  })
2000
1896
  ]
2001
1897
  }),
2002
1898
  // Search input
2003
- import_react_ecs3.default.createElement(import_react_ecs3.Input, {
1899
+ import_react_ecs2.default.createElement(import_react_ecs2.Input, {
2004
1900
  placeholder: "SCAN FREQ...",
2005
1901
  fontSize: this.s(UI_DIMENSIONS.guide.sidebar.fontSize),
2006
1902
  uiTransform: {
@@ -2020,11 +1916,11 @@ var GuideUIModule = class {
2020
1916
  ]
2021
1917
  }),
2022
1918
  // Menu items
2023
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1919
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2024
1920
  uiTransform: { flexGrow: 1, flexDirection: "column", width: "100%", padding: { top: 5 } },
2025
1921
  children: [
2026
1922
  // Section header
2027
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1923
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2028
1924
  uiTransform: { padding: { left: 10, bottom: 8, top: 5 } },
2029
1925
  uiText: { value: "GLOBAL NETWORK", fontSize: this.s(12), color: THEME.colors.cyan }
2030
1926
  }),
@@ -2033,12 +1929,12 @@ var GuideUIModule = class {
2033
1929
  this.renderMenuButton("SIGNALS", signalCount, THEME.colors.white, void 0, "VODS & RECORDINGS"),
2034
1930
  this.renderMenuButton("NODES", nodesCount, THEME.colors.magenta, void 0, "CHANNELS & CREATORS"),
2035
1931
  // Divider
2036
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1932
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2037
1933
  uiTransform: { height: 1, width: "90%", margin: { top: 12, bottom: 8, left: 5 } },
2038
1934
  uiBackground: { color: THEME.colors.panelBorder }
2039
1935
  }),
2040
1936
  // Archives section
2041
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1937
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2042
1938
  uiTransform: { padding: { left: 10, bottom: 8 } },
2043
1939
  uiText: { value: "ARCHIVES", fontSize: this.s(12), color: THEME.colors.cyan }
2044
1940
  }),
@@ -2047,6 +1943,11 @@ var GuideUIModule = class {
2047
1943
  (pl) => this.renderMenuButton(pl.name.toUpperCase(), pl.videos.length, THEME.colors.white, void 0, "PLAYLIST")
2048
1944
  )
2049
1945
  ]
1946
+ }),
1947
+ // The SDK's version, small and dim at the bottom, for a visitor reporting a problem (2.14.0)
1948
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
1949
+ uiTransform: { width: "100%", flexShrink: 0, padding: { left: 10, bottom: 6, top: 4 } },
1950
+ uiText: { value: `TheStatic SDK ${SDK_VERSION}`, fontSize: this.s(11), color: THEME.colors.grayText, textAlign: "bottom-left" }
2050
1951
  })
2051
1952
  ]
2052
1953
  });
@@ -2054,7 +1955,7 @@ var GuideUIModule = class {
2054
1955
  renderMenuButton(label, count, color, badge, subtitle) {
2055
1956
  const isActive = this.activeTab === label;
2056
1957
  const buttonHeight = this.s(UI_DIMENSIONS.guide.sidebar.buttonHeight);
2057
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1958
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2058
1959
  key: label,
2059
1960
  uiTransform: {
2060
1961
  width: "100%",
@@ -2073,10 +1974,10 @@ var GuideUIModule = class {
2073
1974
  this.currentPage = 0;
2074
1975
  },
2075
1976
  children: [
2076
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1977
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2077
1978
  uiTransform: { flexDirection: "column", alignItems: "flex-start", justifyContent: "center", gap: 0 },
2078
1979
  children: [
2079
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1980
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2080
1981
  uiTransform: { height: this.s(18) },
2081
1982
  uiText: {
2082
1983
  value: `${label} [${count}]`,
@@ -2086,7 +1987,7 @@ var GuideUIModule = class {
2086
1987
  }
2087
1988
  }),
2088
1989
  ...subtitle ? [
2089
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
1990
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2090
1991
  key: "subtitle",
2091
1992
  uiTransform: { height: this.s(12), marginTop: -2 },
2092
1993
  uiText: {
@@ -2100,7 +2001,7 @@ var GuideUIModule = class {
2100
2001
  ]
2101
2002
  }),
2102
2003
  ...badge ? [
2103
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2004
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2104
2005
  key: "badge",
2105
2006
  uiText: { value: badge, fontSize: this.s(UI_DIMENSIONS.guide.sidebar.fontSize), color: THEME.colors.red }
2106
2007
  })
@@ -2129,7 +2030,7 @@ var GuideUIModule = class {
2129
2030
  const start = this.currentPage * this.itemsPerPage;
2130
2031
  const paged = videosToShow.slice(start, start + this.itemsPerPage);
2131
2032
  const totalPages = Math.ceil(videosToShow.length / this.itemsPerPage);
2132
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2033
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2133
2034
  uiTransform: {
2134
2035
  flexGrow: 1,
2135
2036
  flexDirection: "column",
@@ -2140,7 +2041,7 @@ var GuideUIModule = class {
2140
2041
  this.renderCardGrid(paged),
2141
2042
  // Pagination
2142
2043
  ...totalPages > 1 ? [
2143
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2044
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2144
2045
  key: "pagination",
2145
2046
  uiTransform: {
2146
2047
  width: "100%",
@@ -2153,7 +2054,7 @@ var GuideUIModule = class {
2153
2054
  },
2154
2055
  children: [
2155
2056
  ...this.currentPage > 0 ? [
2156
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2057
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2157
2058
  key: "prev",
2158
2059
  uiText: {
2159
2060
  value: "< PREV",
@@ -2163,7 +2064,7 @@ var GuideUIModule = class {
2163
2064
  onMouseDown: () => this.currentPage--
2164
2065
  })
2165
2066
  ] : [],
2166
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2067
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2167
2068
  uiText: {
2168
2069
  value: `${this.currentPage + 1}/${totalPages}`,
2169
2070
  fontSize: this.s(UI_DIMENSIONS.guide.content.bodySize),
@@ -2171,7 +2072,7 @@ var GuideUIModule = class {
2171
2072
  }
2172
2073
  }),
2173
2074
  ...this.currentPage < totalPages - 1 ? [
2174
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2075
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2175
2076
  key: "next",
2176
2077
  uiText: {
2177
2078
  value: "NEXT >",
@@ -2189,7 +2090,7 @@ var GuideUIModule = class {
2189
2090
  }
2190
2091
  renderCardGrid(videos) {
2191
2092
  if (videos.length === 0) {
2192
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2093
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2193
2094
  uiTransform: { width: "100%", flexGrow: 1, justifyContent: "center", alignItems: "center" },
2194
2095
  uiText: { value: "NO SIGNAL", fontSize: this.s(UI_DIMENSIONS.guide.content.bodySize), color: THEME.colors.gray }
2195
2096
  });
@@ -2199,7 +2100,7 @@ var GuideUIModule = class {
2199
2100
  rows.push(videos.slice(i, i + 2));
2200
2101
  }
2201
2102
  const cardH = this.s(UI_DIMENSIONS.guide.content.cardHeight);
2202
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2103
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2203
2104
  uiTransform: {
2204
2105
  width: "100%",
2205
2106
  flexGrow: 1,
@@ -2208,7 +2109,7 @@ var GuideUIModule = class {
2208
2109
  gap: 8
2209
2110
  },
2210
2111
  children: rows.map(
2211
- (row, rowIndex) => import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2112
+ (row, rowIndex) => import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2212
2113
  key: `row-${rowIndex}`,
2213
2114
  uiTransform: {
2214
2115
  width: "100%",
@@ -2235,7 +2136,7 @@ var GuideUIModule = class {
2235
2136
  } else if (isActive) {
2236
2137
  cardBgColor = import_math3.Color4.create(0, 0.4, 0, 0.5);
2237
2138
  }
2238
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2139
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2239
2140
  key: video.id,
2240
2141
  uiTransform: {
2241
2142
  width: cardW,
@@ -2250,7 +2151,7 @@ var GuideUIModule = class {
2250
2151
  uiBackground: { color: cardBgColor },
2251
2152
  children: [
2252
2153
  // Main click area
2253
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2154
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2254
2155
  uiTransform: {
2255
2156
  width: "100%",
2256
2157
  height: "70%",
@@ -2260,7 +2161,7 @@ var GuideUIModule = class {
2260
2161
  },
2261
2162
  onMouseDown: () => this.handleVideoSelect(video),
2262
2163
  children: [
2263
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2164
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2264
2165
  uiText: {
2265
2166
  value: truncateText(video.name || "Unknown", 22),
2266
2167
  fontSize: this.s(UI_DIMENSIONS.guide.content.headerSize),
@@ -2269,7 +2170,7 @@ var GuideUIModule = class {
2269
2170
  }),
2270
2171
  // Status indicator: OFFLINE > CONNECTING > PLAYING > LIVE
2271
2172
  ...isOffline ? [
2272
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2173
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2273
2174
  key: "offline",
2274
2175
  uiText: {
2275
2176
  value: "OFFLINE",
@@ -2278,7 +2179,7 @@ var GuideUIModule = class {
2278
2179
  }
2279
2180
  })
2280
2181
  ] : isConnecting ? [
2281
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2182
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2282
2183
  key: "connecting",
2283
2184
  uiText: {
2284
2185
  value: "CONNECTING...",
@@ -2287,7 +2188,7 @@ var GuideUIModule = class {
2287
2188
  }
2288
2189
  })
2289
2190
  ] : isActive ? [
2290
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2191
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2291
2192
  key: "playing",
2292
2193
  uiText: {
2293
2194
  value: "PLAYING",
@@ -2296,18 +2197,18 @@ var GuideUIModule = class {
2296
2197
  }
2297
2198
  })
2298
2199
  ] : video.isLive ? [
2299
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2200
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2300
2201
  key: "live",
2301
2202
  uiTransform: { padding: { left: 4, right: 4, top: 2, bottom: 2 }, marginTop: 4 },
2302
2203
  uiBackground: { color: THEME.colors.red },
2303
2204
  children: [
2304
- import_react_ecs3.default.createElement(import_react_ecs3.Label, { value: "LIVE", fontSize: this.s(10), color: THEME.colors.white })
2205
+ import_react_ecs2.default.createElement(import_react_ecs2.Label, { value: "LIVE", fontSize: this.s(10), color: THEME.colors.white })
2305
2206
  ]
2306
2207
  })
2307
2208
  ] : [],
2308
2209
  // A locked channel (2026-11-20): its badge, the words a refused pick shows - one line, 12px in the 260px card
2309
2210
  ...video.locked === true ? [
2310
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2211
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2311
2212
  key: "locked",
2312
2213
  uiTransform: { height: this.s(16), marginTop: 4 },
2313
2214
  uiText: { value: LOCKED_LINE, fontSize: this.s(12), color: THEME.colors.yellow }
@@ -2316,7 +2217,7 @@ var GuideUIModule = class {
2316
2217
  ]
2317
2218
  }),
2318
2219
  // Channel link
2319
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2220
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2320
2221
  uiTransform: {
2321
2222
  width: "100%",
2322
2223
  height: "30%",
@@ -2327,7 +2228,7 @@ var GuideUIModule = class {
2327
2228
  uiBackground: { color: import_math3.Color4.create(0, 0, 0, 0.3) },
2328
2229
  onMouseDown: () => this.handleChannelClick(video),
2329
2230
  children: [
2330
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2231
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2331
2232
  uiText: {
2332
2233
  value: "CHANNEL",
2333
2234
  fontSize: this.s(UI_DIMENSIONS.guide.content.bodySize),
@@ -2344,7 +2245,7 @@ var GuideUIModule = class {
2344
2245
  const buttonW = this.s(170);
2345
2246
  const buttonH = this.s(44);
2346
2247
  const bodyH = this.s(UI_DIMENSIONS.guide.content.bodySize * 1.5 * 2);
2347
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2248
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2348
2249
  key: "age-choice",
2349
2250
  uiTransform: {
2350
2251
  positionType: "absolute",
@@ -2358,7 +2259,7 @@ var GuideUIModule = class {
2358
2259
  },
2359
2260
  uiBackground: { color: import_math3.Color4.create(0, 0, 0, 0.85) },
2360
2261
  children: [
2361
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2262
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2362
2263
  uiTransform: {
2363
2264
  width: this.s(480),
2364
2265
  flexDirection: "column",
@@ -2369,15 +2270,15 @@ var GuideUIModule = class {
2369
2270
  },
2370
2271
  uiBackground: { color: THEME.colors.panel },
2371
2272
  children: [
2372
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2273
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2373
2274
  uiTransform: { marginBottom: this.s(8) },
2374
2275
  uiText: { value: "MATURE CONTENT", fontSize: this.s(24), color: THEME.colors.red }
2375
2276
  }),
2376
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2277
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2377
2278
  uiTransform: { marginBottom: this.s(12) },
2378
2279
  uiText: { value: truncateText(video.name || "Unknown", 40), fontSize: this.s(16), color: THEME.colors.cyan }
2379
2280
  }),
2380
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2281
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2381
2282
  uiTransform: { width: "100%", minHeight: bodyH, marginBottom: this.s(20) },
2382
2283
  uiText: {
2383
2284
  value: "This channel is for viewers aged 18 and older. Are you 18 or older?",
@@ -2387,21 +2288,21 @@ var GuideUIModule = class {
2387
2288
  textWrap: "wrap"
2388
2289
  }
2389
2290
  }),
2390
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2291
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2391
2292
  uiTransform: { flexDirection: "row", justifyContent: "center", gap: this.s(16) },
2392
2293
  children: [
2393
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2294
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2394
2295
  key: "age-yes",
2395
2296
  uiTransform: { width: buttonW, height: buttonH, justifyContent: "center", alignItems: "center" },
2396
2297
  uiBackground: { color: THEME.colors.red },
2397
2298
  onMouseDown: () => this.answerAge(true),
2398
2299
  children: [
2399
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2300
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2400
2301
  uiText: { value: "YES, I AM 18+", fontSize: this.s(14), color: THEME.colors.white }
2401
2302
  })
2402
2303
  ]
2403
2304
  }),
2404
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2305
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2405
2306
  key: "age-no",
2406
2307
  uiTransform: {
2407
2308
  width: buttonW,
@@ -2414,7 +2315,7 @@ var GuideUIModule = class {
2414
2315
  uiBackground: { color: THEME.colors.buttonBackground },
2415
2316
  onMouseDown: () => this.answerAge(false),
2416
2317
  children: [
2417
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2318
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2418
2319
  uiText: { value: "NO", fontSize: this.s(14), color: THEME.colors.white }
2419
2320
  })
2420
2321
  ]
@@ -2428,7 +2329,7 @@ var GuideUIModule = class {
2428
2329
  }
2429
2330
  renderCloseButton() {
2430
2331
  const closeSize = this.s(UI_DIMENSIONS.closeButton.size);
2431
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2332
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2432
2333
  uiTransform: {
2433
2334
  positionType: "absolute",
2434
2335
  position: { top: -5, right: -5 },
@@ -2440,7 +2341,7 @@ var GuideUIModule = class {
2440
2341
  uiBackground: { color: THEME.colors.panel },
2441
2342
  onMouseDown: () => this.hide(),
2442
2343
  children: [
2443
- import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2344
+ import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2444
2345
  uiText: { value: "X", fontSize: this.s(UI_DIMENSIONS.closeButton.fontSize), color: THEME.colors.red }
2445
2346
  })
2446
2347
  ]
@@ -2449,7 +2350,7 @@ var GuideUIModule = class {
2449
2350
  renderToggleButton() {
2450
2351
  const buttonText = this._isVisible ? "CLOSE" : "GUIDE";
2451
2352
  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);
2452
- const label = import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2353
+ const label = import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2453
2354
  uiText: {
2454
2355
  value: buttonText,
2455
2356
  fontSize: this.s(14),
@@ -2458,16 +2359,16 @@ var GuideUIModule = class {
2458
2359
  }
2459
2360
  });
2460
2361
  const press = () => this._isVisible ? this.hide() : this.show();
2461
- if (this.client.isPhone) {
2462
- return toolbarButton(1, {
2362
+ if (this.client.isPhone || this.client.toolbarCollapsed) {
2363
+ return this.client.toolbarButton(1, {
2463
2364
  uiTransform: { justifyContent: "center", alignItems: "center" },
2464
2365
  uiBackground: { color: buttonColor },
2465
2366
  onMouseDown: press,
2466
2367
  children: [label]
2467
- }, true, this.client.uiScale);
2368
+ });
2468
2369
  }
2469
2370
  const buttonPos = 20 + this.s(100) + 10;
2470
- return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2371
+ return import_react_ecs2.default.createElement(import_react_ecs2.UiEntity, {
2471
2372
  uiTransform: {
2472
2373
  positionType: "absolute",
2473
2374
  position: { right: buttonPos, bottom: 10 },
@@ -2484,7 +2385,7 @@ var GuideUIModule = class {
2484
2385
  };
2485
2386
 
2486
2387
  // src/ui/chat-ui.tsx
2487
- var import_react_ecs4 = __toESM(require("@dcl/sdk/react-ecs"));
2388
+ var import_react_ecs3 = __toESM(require("@dcl/sdk/react-ecs"));
2488
2389
  var import_math4 = require("@dcl/sdk/math");
2489
2390
  var import_SignedFetch3 = require("~system/SignedFetch");
2490
2391
  var import_players = require("@dcl/sdk/players");
@@ -2535,7 +2436,7 @@ var ChatUIModule = class {
2535
2436
  if (this.client.isVisitorBlocked) return null;
2536
2437
  const scaledTheme = scaleChatTheme(DEFAULT_CHAT_THEME, this.client.uiScale);
2537
2438
  const positionStyle = this.getPositionStyle();
2538
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2439
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2539
2440
  uiTransform: {
2540
2441
  width: "100%",
2541
2442
  height: "100%",
@@ -2544,6 +2445,8 @@ var ChatUIModule = class {
2544
2445
  children: [
2545
2446
  // Always render toggle button
2546
2447
  this.renderToggleButton(),
2448
+ // The toolbar's collapse handle, drawn here once for the whole toolbar (2.14.0; nothing while collapsed)
2449
+ this.client.toolbarHandle(),
2547
2450
  // Render panel when visible - scaled sizes, fixed position
2548
2451
  // Key includes uiScale to force re-render when scale changes from other panels
2549
2452
  // On a phone centered beside the toolbar's column (2.13.0, src/ui/toolbar-panel.ts); elsewhere as here
@@ -2563,7 +2466,7 @@ var ChatUIModule = class {
2563
2466
  this.renderHeader(),
2564
2467
  this.renderChannelButton(scaledTheme),
2565
2468
  this.renderMessagesArea(scaledTheme),
2566
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2469
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2567
2470
  uiTransform: { width: "100%", height: 1, flexShrink: 0 },
2568
2471
  uiBackground: { color: THEME.colors.panelBorder }
2569
2472
  }),
@@ -2905,7 +2808,7 @@ var ChatUIModule = class {
2905
2808
  renderChannelButton(theme) {
2906
2809
  const currentChannel = this.channels.find((c) => c.id === this.currentChannelId);
2907
2810
  const displayName = currentChannel?.name || this.currentChannelId;
2908
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2811
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2909
2812
  uiTransform: {
2910
2813
  height: 40,
2911
2814
  width: "100%",
@@ -2920,12 +2823,12 @@ var ChatUIModule = class {
2920
2823
  this.showChannelDropdown = !this.showChannelDropdown;
2921
2824
  },
2922
2825
  children: [
2923
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
2826
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
2924
2827
  value: `// ${truncateText(displayName, 24)}`,
2925
2828
  fontSize: theme.channelButton,
2926
2829
  color: THEME.colors.white
2927
2830
  }),
2928
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
2831
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
2929
2832
  value: this.showChannelDropdown ? "\u25B2" : "\u25BC",
2930
2833
  fontSize: 10,
2931
2834
  color: THEME.colors.cyan
@@ -2954,7 +2857,7 @@ var ChatUIModule = class {
2954
2857
  const visibleMessages = allMessages.slice(startIdx, endIdx);
2955
2858
  const canScrollUp = this.chatScrollOffset < maxOffset;
2956
2859
  const canScrollDown = this.chatScrollOffset > 0;
2957
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2860
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2958
2861
  uiTransform: { flexGrow: 1, width: "100%", flexDirection: "row", overflow: "hidden" },
2959
2862
  children: [
2960
2863
  // Messages - anchored at the bottom, so the newest stays in view now that a row grows with its text
@@ -2962,7 +2865,7 @@ var ChatUIModule = class {
2962
2865
  // past it; now its oldest clips at the top, one scroll up away. The rows keep their height
2963
2866
  // (flexShrink 0 - the protocol's default of 1 squeezes them onto each other) in one column
2964
2867
  // (nowrap - the protocol documents wrap as its default).
2965
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2868
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2966
2869
  uiTransform: {
2967
2870
  flexGrow: 1,
2968
2871
  flexDirection: "column",
@@ -2976,7 +2879,7 @@ var ChatUIModule = class {
2976
2879
  )
2977
2880
  }),
2978
2881
  // Scroll controls
2979
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2882
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2980
2883
  uiTransform: {
2981
2884
  width: 28,
2982
2885
  height: "100%",
@@ -2986,22 +2889,22 @@ var ChatUIModule = class {
2986
2889
  gap: 8
2987
2890
  },
2988
2891
  children: [
2989
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2892
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2990
2893
  uiTransform: { width: 26, height: 36, justifyContent: "center", alignItems: "center" },
2991
2894
  uiBackground: { color: canScrollUp ? THEME.colors.buttonBackground : import_math4.Color4.create(0.1, 0.1, 0.1, 0.3) },
2992
2895
  onMouseDown: () => {
2993
2896
  if (canScrollUp) this.chatScrollOffset += 1;
2994
2897
  },
2995
2898
  children: [
2996
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2899
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
2997
2900
  uiText: { value: "\u25B2", fontSize: 14, color: canScrollUp ? THEME.colors.cyan : THEME.colors.gray }
2998
2901
  })
2999
2902
  ]
3000
2903
  }),
3001
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2904
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3002
2905
  uiTransform: { width: 26, height: 24, justifyContent: "center", alignItems: "center" },
3003
2906
  children: [
3004
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2907
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3005
2908
  uiText: {
3006
2909
  value: totalMessages > UI_DIMENSIONS.chat.messagesPerPage ? `${this.chatScrollOffset}` : "-",
3007
2910
  fontSize: 10,
@@ -3010,14 +2913,14 @@ var ChatUIModule = class {
3010
2913
  })
3011
2914
  ]
3012
2915
  }),
3013
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2916
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3014
2917
  uiTransform: { width: 26, height: 36, justifyContent: "center", alignItems: "center" },
3015
2918
  uiBackground: { color: canScrollDown ? THEME.colors.buttonBackground : import_math4.Color4.create(0.1, 0.1, 0.1, 0.3) },
3016
2919
  onMouseDown: () => {
3017
2920
  if (canScrollDown) this.chatScrollOffset -= 1;
3018
2921
  },
3019
2922
  children: [
3020
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2923
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3021
2924
  uiText: { value: "\u25BC", fontSize: 14, color: canScrollDown ? THEME.colors.cyan : THEME.colors.gray }
3022
2925
  })
3023
2926
  ]
@@ -3028,7 +2931,7 @@ var ChatUIModule = class {
3028
2931
  });
3029
2932
  }
3030
2933
  renderSystemMessage(msg, theme) {
3031
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2934
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3032
2935
  key: msg.id,
3033
2936
  uiTransform: { width: "100%", height: 24, marginBottom: 4, flexShrink: 0 },
3034
2937
  uiText: {
@@ -3048,12 +2951,12 @@ var ChatUIModule = class {
3048
2951
  if (displayName.toLowerCase().includes("admin")) accentColor = THEME.colors.magenta;
3049
2952
  else if (isCurrentUser) accentColor = THEME.colors.green;
3050
2953
  const textRoom = this.messageTextRoom(msg.text, theme.chatMessage);
3051
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2954
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3052
2955
  key: msg.id,
3053
2956
  uiTransform: { width: "100%", flexDirection: "column", marginBottom: 16, flexShrink: 0 },
3054
2957
  children: [
3055
2958
  // Header row
3056
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2959
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3057
2960
  uiTransform: {
3058
2961
  width: "100%",
3059
2962
  height: 24,
@@ -3063,23 +2966,23 @@ var ChatUIModule = class {
3063
2966
  marginBottom: 4
3064
2967
  },
3065
2968
  children: [
3066
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2969
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3067
2970
  uiText: { value: displayName, fontSize: theme.chatUsername, color: accentColor, textAlign: "middle-left" }
3068
2971
  }),
3069
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2972
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3070
2973
  uiText: { value: time, fontSize: theme.chatTimestamp, color: THEME.colors.gray, textAlign: "middle-right" }
3071
2974
  })
3072
2975
  ]
3073
2976
  }),
3074
2977
  // Message content
3075
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2978
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3076
2979
  uiTransform: { width: "100%", flexDirection: "row", alignItems: "stretch", paddingLeft: 8 },
3077
2980
  children: [
3078
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2981
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3079
2982
  uiTransform: { width: 3, minHeight: textRoom },
3080
2983
  uiBackground: { color: accentColor }
3081
2984
  }),
3082
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
2985
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3083
2986
  uiTransform: { flexGrow: 1, minHeight: textRoom, paddingLeft: 12, paddingTop: 4, paddingBottom: 4 },
3084
2987
  uiText: {
3085
2988
  value: msg.text,
@@ -3095,7 +2998,7 @@ var ChatUIModule = class {
3095
2998
  });
3096
2999
  }
3097
3000
  renderUserInfoBar(theme) {
3098
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3001
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3099
3002
  uiTransform: {
3100
3003
  width: "100%",
3101
3004
  height: 34,
@@ -3107,12 +3010,12 @@ var ChatUIModule = class {
3107
3010
  },
3108
3011
  uiBackground: { color: import_math4.Color4.create(0.03, 0.03, 0.05, 1) },
3109
3012
  children: [
3110
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3013
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3111
3014
  value: `// ${this.currentUsername || "Guest"}`,
3112
3015
  fontSize: theme.userInfo,
3113
3016
  color: THEME.colors.yellow
3114
3017
  }),
3115
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3018
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3116
3019
  value: this.isRegisteredUser ? "\u25CF CITIZEN" : "\u25CB GUEST",
3117
3020
  fontSize: theme.authStatus,
3118
3021
  color: this.isRegisteredUser ? THEME.colors.green : THEME.colors.gray
@@ -3123,7 +3026,7 @@ var ChatUIModule = class {
3123
3026
  renderInputArea(theme) {
3124
3027
  const baseUrl = this.getBaseUrl();
3125
3028
  if (!this.isRegisteredUser) {
3126
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3029
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3127
3030
  uiTransform: {
3128
3031
  height: 75,
3129
3032
  minHeight: 75,
@@ -3137,14 +3040,14 @@ var ChatUIModule = class {
3137
3040
  },
3138
3041
  uiBackground: { color: import_math4.Color4.create(0.08, 0.08, 0.1, 1) },
3139
3042
  children: [
3140
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3043
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3141
3044
  value: "ACCESS RESTRICTED: CITIZENS ONLY",
3142
3045
  fontSize: 12,
3143
3046
  color: THEME.colors.red,
3144
3047
  textAlign: "middle-center",
3145
3048
  uiTransform: { marginBottom: 5 }
3146
3049
  }),
3147
- import_react_ecs4.default.createElement(import_react_ecs4.Button, {
3050
+ import_react_ecs3.default.createElement(import_react_ecs3.Button, {
3148
3051
  value: "REGISTER IDENTITY",
3149
3052
  fontSize: 14,
3150
3053
  uiTransform: { width: 200, height: 30 },
@@ -3157,7 +3060,7 @@ var ChatUIModule = class {
3157
3060
  ]
3158
3061
  });
3159
3062
  }
3160
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3063
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3161
3064
  uiTransform: {
3162
3065
  height: 75,
3163
3066
  minHeight: 75,
@@ -3169,7 +3072,7 @@ var ChatUIModule = class {
3169
3072
  },
3170
3073
  uiBackground: { color: import_math4.Color4.create(0.08, 0.08, 0.1, 1) },
3171
3074
  children: [
3172
- import_react_ecs4.default.createElement(import_react_ecs4.Input, {
3075
+ import_react_ecs3.default.createElement(import_react_ecs3.Input, {
3173
3076
  onChange: (v) => {
3174
3077
  this.inputText = v;
3175
3078
  },
@@ -3182,7 +3085,7 @@ var ChatUIModule = class {
3182
3085
  uiBackground: { color: import_math4.Color4.create(0.12, 0.12, 0.14, 1) },
3183
3086
  uiTransform: { flexGrow: 1, height: "100%", margin: { right: 10 } }
3184
3087
  }),
3185
- import_react_ecs4.default.createElement(import_react_ecs4.Button, {
3088
+ import_react_ecs3.default.createElement(import_react_ecs3.Button, {
3186
3089
  value: this.isSigningIn ? "..." : "SEND",
3187
3090
  onMouseDown: () => this.handleSend(),
3188
3091
  uiTransform: { width: 80, height: "100%" },
@@ -3199,7 +3102,7 @@ var ChatUIModule = class {
3199
3102
  const endIdx = startIdx + UI_DIMENSIONS.chat.channelsPerPage;
3200
3103
  const visibleChannels = this.channels.slice(startIdx, endIdx);
3201
3104
  const totalPages = Math.ceil(this.channels.length / UI_DIMENSIONS.chat.channelsPerPage);
3202
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3105
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3203
3106
  uiTransform: {
3204
3107
  width: "100%",
3205
3108
  height: 260,
@@ -3210,13 +3113,13 @@ var ChatUIModule = class {
3210
3113
  uiBackground: { color: import_math4.Color4.create(0.08, 0.1, 0.14, 1) },
3211
3114
  children: [
3212
3115
  // Top border
3213
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3116
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3214
3117
  uiTransform: { width: "100%", height: 2, flexShrink: 0 },
3215
3118
  uiBackground: { color: THEME.colors.cyan }
3216
3119
  }),
3217
3120
  // Channel list
3218
3121
  ...visibleChannels.map(
3219
- (channel) => import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3122
+ (channel) => import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3220
3123
  key: channel.id,
3221
3124
  uiTransform: {
3222
3125
  height: 38,
@@ -3229,7 +3132,7 @@ var ChatUIModule = class {
3229
3132
  },
3230
3133
  onMouseDown: () => this.switchChannel(channel.id),
3231
3134
  children: [
3232
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3135
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3233
3136
  value: channel.id === this.currentChannelId ? `\u25B8 ${channel.name}` : channel.name,
3234
3137
  fontSize: theme.channelDropdown,
3235
3138
  color: channel.id === this.currentChannelId ? THEME.colors.cyan : THEME.colors.gray
@@ -3239,7 +3142,7 @@ var ChatUIModule = class {
3239
3142
  ),
3240
3143
  // Pagination
3241
3144
  ...totalPages > 1 ? [
3242
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3145
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3243
3146
  key: "pagination",
3244
3147
  uiTransform: {
3245
3148
  width: "100%",
@@ -3252,11 +3155,11 @@ var ChatUIModule = class {
3252
3155
  },
3253
3156
  children: [
3254
3157
  ...this.channelPage > 0 ? [
3255
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3158
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3256
3159
  key: "prev",
3257
3160
  onMouseDown: () => this.channelPage--,
3258
3161
  children: [
3259
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3162
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3260
3163
  value: "<< PREV",
3261
3164
  fontSize: 10,
3262
3165
  color: THEME.colors.cyan
@@ -3264,17 +3167,17 @@ var ChatUIModule = class {
3264
3167
  ]
3265
3168
  })
3266
3169
  ] : [],
3267
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3170
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3268
3171
  value: `${this.channelPage + 1}/${totalPages}`,
3269
3172
  fontSize: 10,
3270
3173
  color: THEME.colors.gray
3271
3174
  }),
3272
3175
  ...this.channelPage < totalPages - 1 ? [
3273
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3176
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3274
3177
  key: "next",
3275
3178
  onMouseDown: () => this.channelPage++,
3276
3179
  children: [
3277
- import_react_ecs4.default.createElement(import_react_ecs4.Label, {
3180
+ import_react_ecs3.default.createElement(import_react_ecs3.Label, {
3278
3181
  value: "NEXT >>",
3279
3182
  fontSize: 10,
3280
3183
  color: THEME.colors.cyan
@@ -3286,7 +3189,7 @@ var ChatUIModule = class {
3286
3189
  })
3287
3190
  ] : [],
3288
3191
  // Bottom border
3289
- import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3192
+ import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3290
3193
  uiTransform: { width: "100%", height: 1, flexShrink: 0 },
3291
3194
  uiBackground: { color: THEME.colors.panelBorder }
3292
3195
  })
@@ -3297,7 +3200,7 @@ var ChatUIModule = class {
3297
3200
  const unreadBadge = this._unreadCount > 0 ? ` (${this._unreadCount})` : "";
3298
3201
  const buttonText = this._isVisible ? "CLOSE" : `CHAT${unreadBadge}`;
3299
3202
  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);
3300
- const label = import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3203
+ const label = import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3301
3204
  uiText: {
3302
3205
  value: buttonText,
3303
3206
  fontSize: this.s(14),
@@ -3306,15 +3209,15 @@ var ChatUIModule = class {
3306
3209
  }
3307
3210
  });
3308
3211
  const press = () => this._isVisible ? this.hide() : this.show();
3309
- if (this.client.isPhone) {
3310
- return toolbarButton(0, {
3212
+ if (this.client.isPhone || this.client.toolbarCollapsed) {
3213
+ return this.client.toolbarButton(0, {
3311
3214
  uiTransform: { justifyContent: "center", alignItems: "center" },
3312
3215
  uiBackground: { color: buttonColor },
3313
3216
  onMouseDown: press,
3314
3217
  children: [label]
3315
- }, true, this.client.uiScale);
3218
+ });
3316
3219
  }
3317
- return import_react_ecs4.default.createElement(import_react_ecs4.UiEntity, {
3220
+ return import_react_ecs3.default.createElement(import_react_ecs3.UiEntity, {
3318
3221
  uiTransform: {
3319
3222
  positionType: "absolute",
3320
3223
  position: { right: 20, bottom: 10 },
@@ -3331,13 +3234,13 @@ var ChatUIModule = class {
3331
3234
  };
3332
3235
 
3333
3236
  // src/ui/admin-panel-ui.tsx
3334
- var import_react_ecs7 = __toESM(require("@dcl/sdk/react-ecs"));
3237
+ var import_react_ecs6 = __toESM(require("@dcl/sdk/react-ecs"));
3335
3238
  var import_math7 = require("@dcl/sdk/math");
3336
3239
  var import_players2 = require("@dcl/sdk/players");
3337
3240
  var import_RestrictedActions6 = require("~system/RestrictedActions");
3338
3241
 
3339
3242
  // src/ui/ui-renderer.tsx
3340
- var import_react_ecs5 = __toESM(require("@dcl/sdk/react-ecs"));
3243
+ var import_react_ecs4 = __toESM(require("@dcl/sdk/react-ecs"));
3341
3244
  var import_ecs3 = require("@dcl/sdk/ecs");
3342
3245
  var notificationText = "";
3343
3246
  var notificationVisible = false;
@@ -3370,8 +3273,8 @@ function NotificationBanner() {
3370
3273
  if (!notificationVisible) return null;
3371
3274
  return (
3372
3275
  // Full-width container to center the notification
3373
- /* @__PURE__ */ import_react_ecs5.default.createElement(
3374
- import_react_ecs5.UiEntity,
3276
+ /* @__PURE__ */ import_react_ecs4.default.createElement(
3277
+ import_react_ecs4.UiEntity,
3375
3278
  {
3376
3279
  uiTransform: {
3377
3280
  positionType: "absolute",
@@ -3381,8 +3284,8 @@ function NotificationBanner() {
3381
3284
  alignItems: "center"
3382
3285
  }
3383
3286
  },
3384
- /* @__PURE__ */ import_react_ecs5.default.createElement(
3385
- import_react_ecs5.UiEntity,
3287
+ /* @__PURE__ */ import_react_ecs4.default.createElement(
3288
+ import_react_ecs4.UiEntity,
3386
3289
  {
3387
3290
  uiTransform: {
3388
3291
  width: N.width,
@@ -3392,8 +3295,8 @@ function NotificationBanner() {
3392
3295
  },
3393
3296
  uiBackground: { color: C.panel }
3394
3297
  },
3395
- /* @__PURE__ */ import_react_ecs5.default.createElement(
3396
- import_react_ecs5.UiEntity,
3298
+ /* @__PURE__ */ import_react_ecs4.default.createElement(
3299
+ import_react_ecs4.UiEntity,
3397
3300
  {
3398
3301
  uiTransform: {
3399
3302
  width: N.borderWidth,
@@ -3402,8 +3305,8 @@ function NotificationBanner() {
3402
3305
  uiBackground: { color: C.cyan }
3403
3306
  }
3404
3307
  ),
3405
- /* @__PURE__ */ import_react_ecs5.default.createElement(
3406
- import_react_ecs5.UiEntity,
3308
+ /* @__PURE__ */ import_react_ecs4.default.createElement(
3309
+ import_react_ecs4.UiEntity,
3407
3310
  {
3408
3311
  uiTransform: {
3409
3312
  flexGrow: 1,
@@ -3413,8 +3316,8 @@ function NotificationBanner() {
3413
3316
  alignItems: "flex-start"
3414
3317
  }
3415
3318
  },
3416
- /* @__PURE__ */ import_react_ecs5.default.createElement(
3417
- import_react_ecs5.Label,
3319
+ /* @__PURE__ */ import_react_ecs4.default.createElement(
3320
+ import_react_ecs4.Label,
3418
3321
  {
3419
3322
  value: notificationText,
3420
3323
  fontSize: N.fontSize,
@@ -3423,8 +3326,8 @@ function NotificationBanner() {
3423
3326
  }
3424
3327
  )
3425
3328
  ),
3426
- /* @__PURE__ */ import_react_ecs5.default.createElement(
3427
- import_react_ecs5.UiEntity,
3329
+ /* @__PURE__ */ import_react_ecs4.default.createElement(
3330
+ import_react_ecs4.UiEntity,
3428
3331
  {
3429
3332
  uiTransform: {
3430
3333
  width: 5,
@@ -3446,8 +3349,8 @@ function createStaticUI(client) {
3446
3349
  const guideComponent = client.guideUI?.getComponent() ?? null;
3447
3350
  const chatComponent = client.chatUI?.getComponent() ?? null;
3448
3351
  const adminComponent = client.adminPanel?.getComponent() ?? null;
3449
- return /* @__PURE__ */ import_react_ecs5.default.createElement(
3450
- import_react_ecs5.UiEntity,
3352
+ return /* @__PURE__ */ import_react_ecs4.default.createElement(
3353
+ import_react_ecs4.UiEntity,
3451
3354
  {
3452
3355
  key: `static-ui-root-${currentScale}`,
3453
3356
  uiTransform: {
@@ -3458,7 +3361,7 @@ function createStaticUI(client) {
3458
3361
  alignItems: "center"
3459
3362
  }
3460
3363
  },
3461
- blocked ? null : /* @__PURE__ */ import_react_ecs5.default.createElement(NotificationBanner, null),
3364
+ blocked ? null : /* @__PURE__ */ import_react_ecs4.default.createElement(NotificationBanner, null),
3462
3365
  guideComponent,
3463
3366
  chatComponent,
3464
3367
  adminComponent
@@ -3467,11 +3370,11 @@ function createStaticUI(client) {
3467
3370
  }
3468
3371
  function setupStaticUI(client) {
3469
3372
  const StaticUI = createStaticUI(client);
3470
- import_react_ecs5.ReactEcsRenderer.setUiRenderer(StaticUI);
3373
+ import_react_ecs4.ReactEcsRenderer.setUiRenderer(StaticUI);
3471
3374
  }
3472
3375
 
3473
3376
  // src/ui/blocked-notice.tsx
3474
- var import_react_ecs6 = __toESM(require("@dcl/sdk/react-ecs"));
3377
+ var import_react_ecs5 = __toESM(require("@dcl/sdk/react-ecs"));
3475
3378
  var import_math5 = require("@dcl/sdk/math");
3476
3379
  var import_RestrictedActions4 = require("~system/RestrictedActions");
3477
3380
  var DEFAULT_SITE_URL = "https://thestatic.tv";
@@ -3498,8 +3401,8 @@ function BlockedNotice(props) {
3498
3401
  const s = (v) => Math.round(v * props.scale);
3499
3402
  const [title, ...body] = lines;
3500
3403
  const action = blockedNoticeAction(props.standing, props.siteUrl || DEFAULT_SITE_URL);
3501
- return /* @__PURE__ */ import_react_ecs6.default.createElement(
3502
- import_react_ecs6.UiEntity,
3404
+ return /* @__PURE__ */ import_react_ecs5.default.createElement(
3405
+ import_react_ecs5.UiEntity,
3503
3406
  {
3504
3407
  uiTransform: {
3505
3408
  width: "100%",
@@ -3509,16 +3412,16 @@ function BlockedNotice(props) {
3509
3412
  alignItems: "center"
3510
3413
  }
3511
3414
  },
3512
- /* @__PURE__ */ import_react_ecs6.default.createElement(
3513
- import_react_ecs6.UiEntity,
3415
+ /* @__PURE__ */ import_react_ecs5.default.createElement(
3416
+ import_react_ecs5.UiEntity,
3514
3417
  {
3515
3418
  uiTransform: { width: s(460), flexDirection: "column", alignItems: "center", padding: s(20) },
3516
3419
  uiBackground: { color: import_math5.Color4.create(0.05, 0.05, 0.08, 0.95) }
3517
3420
  },
3518
- /* @__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) } }),
3519
- 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) } })),
3520
- action && /* @__PURE__ */ import_react_ecs6.default.createElement(
3521
- import_react_ecs6.Button,
3421
+ /* @__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) } }),
3422
+ 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) } })),
3423
+ action && /* @__PURE__ */ import_react_ecs5.default.createElement(
3424
+ import_react_ecs5.Button,
3522
3425
  {
3523
3426
  uiTransform: { width: s(220), height: s(36), margin: { top: s(12) } },
3524
3427
  uiBackground: { color: import_math5.Color4.create(0, 0.8, 0.8, 1) },
@@ -4008,16 +3911,16 @@ var AdminPanelUIModule = class {
4008
3911
  this.privateStatus = line;
4009
3912
  } };
4010
3913
  // --- UI Components ---
4011
- this.SectionHead = ({ label, color }) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4012
- import_react_ecs7.UiEntity,
3914
+ this.SectionHead = ({ label, color }) => /* @__PURE__ */ import_react_ecs6.default.createElement(
3915
+ import_react_ecs6.UiEntity,
4013
3916
  {
4014
3917
  uiTransform: { width: "100%", height: this.s(UI_DIMENSIONS.admin.sectionHeadHeight), margin: { bottom: 8 }, padding: { left: 10 }, alignItems: "center" },
4015
3918
  uiBackground: { color: import_math7.Color4.create(color.r * 0.3, color.g * 0.3, color.b * 0.3, 0.5) }
4016
3919
  },
4017
- /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: label, fontSize: this.theme.sectionHead, color })
3920
+ /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: label, fontSize: this.theme.sectionHead, color })
4018
3921
  );
4019
- this.TabBtn = ({ label, tab }) => /* @__PURE__ */ import_react_ecs7.default.createElement(
4020
- import_react_ecs7.Button,
3922
+ this.TabBtn = ({ label, tab }) => /* @__PURE__ */ import_react_ecs6.default.createElement(
3923
+ import_react_ecs6.Button,
4021
3924
  {
4022
3925
  uiTransform: { flexGrow: 1, height: this.s(UI_DIMENSIONS.admin.tabHeight), justifyContent: "center", alignItems: "center" },
4023
3926
  uiBackground: { color: this.activeTab === tab ? C2.tabActive : C2.tabInactive },
@@ -4035,8 +3938,8 @@ var AdminPanelUIModule = class {
4035
3938
  */
4036
3939
  this.ControlsTab = () => {
4037
3940
  const t = this.theme;
4038
- 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(
4039
- import_react_ecs7.Label,
3941
+ 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(
3942
+ import_react_ecs6.Label,
4040
3943
  {
4041
3944
  value: this.controlStatus,
4042
3945
  fontSize: t.status,
@@ -4050,8 +3953,8 @@ var AdminPanelUIModule = class {
4050
3953
  this.fetchStreamData();
4051
3954
  }
4052
3955
  const t = this.theme;
4053
- 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(
4054
- import_react_ecs7.Button,
3956
+ 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(
3957
+ import_react_ecs6.Button,
4055
3958
  {
4056
3959
  uiTransform: { width: this.s(200), height: this.s(UI_DIMENSIONS.admin.buttonHeight), margin: { bottom: 6 } },
4057
3960
  uiBackground: { color: this.trialClaiming ? C2.btn : C2.green },
@@ -4060,8 +3963,8 @@ var AdminPanelUIModule = class {
4060
3963
  color: C2.text,
4061
3964
  onMouseDown: () => this.claimTrial()
4062
3965
  }
4063
- ), 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(
4064
- import_react_ecs7.Button,
3966
+ ), 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(
3967
+ import_react_ecs6.Button,
4065
3968
  {
4066
3969
  uiTransform: { width: this.s(170), height: this.s(UI_DIMENSIONS.admin.buttonHeight), margin: { bottom: 6 } },
4067
3970
  uiBackground: { color: this.channelCreating ? C2.btn : C2.cyan },
@@ -4070,47 +3973,47 @@ var AdminPanelUIModule = class {
4070
3973
  color: C2.text,
4071
3974
  onMouseDown: () => this.createChannel()
4072
3975
  }
4073
- ), 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(
4074
- import_react_ecs7.Label,
3976
+ ), 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(
3977
+ import_react_ecs6.Label,
4075
3978
  {
4076
3979
  value: this.streamData.isLive ? `LIVE \u2022 ${this.streamData.currentViewers || 0} viewers` : "OFFLINE",
4077
3980
  fontSize: t.label,
4078
3981
  color: this.streamData.isLive ? C2.red : C2.textDim
4079
3982
  }
4080
- ), /* @__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(
4081
- import_react_ecs7.Label,
3983
+ ), /* @__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(
3984
+ import_react_ecs6.Label,
4082
3985
  {
4083
3986
  value: `Channel: ${this.streamData.channelName || this.streamData.channelId}`,
4084
3987
  fontSize: t.labelSmall,
4085
3988
  color: C2.textDim,
4086
3989
  uiTransform: { margin: { bottom: 10 } }
4087
3990
  }
4088
- ), /* @__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(
4089
- import_react_ecs7.Label,
3991
+ ), /* @__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(
3992
+ import_react_ecs6.Label,
4090
3993
  {
4091
3994
  value: this.streamData.rtmpUrl || "Loading...",
4092
3995
  fontSize: t.label,
4093
3996
  color: this.streamData.rtmpUrl ? C2.text : C2.textDim,
4094
3997
  uiTransform: { margin: { left: 6 } }
4095
3998
  }
4096
- )), /* @__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(
4097
- import_react_ecs7.Label,
3999
+ )), /* @__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(
4000
+ import_react_ecs6.Label,
4098
4001
  {
4099
4002
  value: this.streamData.streamKey || "Loading...",
4100
4003
  fontSize: t.label,
4101
4004
  color: this.streamData.streamKey ? C2.cyan : C2.textDim,
4102
4005
  uiTransform: { margin: { left: 6 } }
4103
4006
  }
4104
- )), /* @__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(
4105
- import_react_ecs7.Label,
4007
+ )), /* @__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(
4008
+ import_react_ecs6.Label,
4106
4009
  {
4107
4010
  value: this.streamData.locked === true ? LOCKED_LINE : this.streamData.hlsUrl || "Not available",
4108
4011
  fontSize: t.label,
4109
4012
  color: this.streamData.locked === true ? C2.yellow : this.streamData.hlsUrl ? C2.green : C2.textDim,
4110
4013
  uiTransform: { margin: { left: 6 } }
4111
4014
  }
4112
- )), /* @__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(
4113
- import_react_ecs7.Button,
4015
+ )), /* @__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(
4016
+ import_react_ecs6.Button,
4114
4017
  {
4115
4018
  uiTransform: { width: this.s(110), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4116
4019
  uiBackground: { color: this.streamControlling ? C2.btn : C2.green },
@@ -4119,8 +4022,8 @@ var AdminPanelUIModule = class {
4119
4022
  color: C2.text,
4120
4023
  onMouseDown: () => this.startStream()
4121
4024
  }
4122
- ), this.streamData.isLive && /* @__PURE__ */ import_react_ecs7.default.createElement(
4123
- import_react_ecs7.Button,
4025
+ ), this.streamData.isLive && /* @__PURE__ */ import_react_ecs6.default.createElement(
4026
+ import_react_ecs6.Button,
4124
4027
  {
4125
4028
  uiTransform: { width: this.s(110), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4126
4029
  uiBackground: { color: this.streamControlling ? C2.btn : C2.red },
@@ -4129,8 +4032,8 @@ var AdminPanelUIModule = class {
4129
4032
  color: C2.text,
4130
4033
  onMouseDown: () => this.stopStream()
4131
4034
  }
4132
- ), this.streamData.isLive && (this.streamData.hlsUrl || this.streamData.locked === true) && /* @__PURE__ */ import_react_ecs7.default.createElement(
4133
- import_react_ecs7.Button,
4035
+ ), this.streamData.isLive && (this.streamData.hlsUrl || this.streamData.locked === true) && /* @__PURE__ */ import_react_ecs6.default.createElement(
4036
+ import_react_ecs6.Button,
4134
4037
  {
4135
4038
  uiTransform: { width: this.s(100), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4136
4039
  uiBackground: { color: C2.cyan },
@@ -4139,8 +4042,8 @@ var AdminPanelUIModule = class {
4139
4042
  color: C2.text,
4140
4043
  onMouseDown: () => this.playStreamOnScreen()
4141
4044
  }
4142
- )), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4143
- import_react_ecs7.Button,
4045
+ )), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", flexWrap: "wrap", margin: { bottom: 6 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4046
+ import_react_ecs6.Button,
4144
4047
  {
4145
4048
  uiTransform: { width: this.s(80), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4146
4049
  uiBackground: { color: C2.btn },
@@ -4149,8 +4052,8 @@ var AdminPanelUIModule = class {
4149
4052
  color: C2.text,
4150
4053
  onMouseDown: () => this.refreshStreamStatus()
4151
4054
  }
4152
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4153
- import_react_ecs7.Button,
4055
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4056
+ import_react_ecs6.Button,
4154
4057
  {
4155
4058
  uiTransform: { width: this.s(95), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4156
4059
  uiBackground: { color: this.keyRotating ? C2.btn : C2.yellow },
@@ -4159,8 +4062,8 @@ var AdminPanelUIModule = class {
4159
4062
  color: C2.text,
4160
4063
  onMouseDown: () => this.rotateStreamKey()
4161
4064
  }
4162
- ), !this.streamData.isLive && !this.channelDeleteLook && /* @__PURE__ */ import_react_ecs7.default.createElement(
4163
- import_react_ecs7.Button,
4065
+ ), !this.streamData.isLive && !this.channelDeleteLook && /* @__PURE__ */ import_react_ecs6.default.createElement(
4066
+ import_react_ecs6.Button,
4164
4067
  {
4165
4068
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4166
4069
  uiBackground: { color: this.channelDeleting ? C2.btn : C2.red },
@@ -4169,8 +4072,8 @@ var AdminPanelUIModule = class {
4169
4072
  color: C2.text,
4170
4073
  onMouseDown: () => this.deleteChannel()
4171
4074
  }
4172
- )), !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(
4173
- import_react_ecs7.Button,
4075
+ )), !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(
4076
+ import_react_ecs6.Button,
4174
4077
  {
4175
4078
  uiTransform: { width: this.s(120), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4176
4079
  uiBackground: { color: this.channelDeleting ? C2.btn : C2.red },
@@ -4179,8 +4082,8 @@ var AdminPanelUIModule = class {
4179
4082
  color: C2.text,
4180
4083
  onMouseDown: () => this.confirmDeleteChannel()
4181
4084
  }
4182
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4183
- import_react_ecs7.Button,
4085
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4086
+ import_react_ecs6.Button,
4184
4087
  {
4185
4088
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4186
4089
  uiBackground: { color: C2.btn },
@@ -4189,8 +4092,8 @@ var AdminPanelUIModule = class {
4189
4092
  color: C2.text,
4190
4093
  onMouseDown: () => this.cancelDeleteChannel()
4191
4094
  }
4192
- ))), 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(
4193
- import_react_ecs7.Input,
4095
+ ))), 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(
4096
+ import_react_ecs6.Input,
4194
4097
  {
4195
4098
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4196
4099
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4203,8 +4106,8 @@ var AdminPanelUIModule = class {
4203
4106
  this.customVideoUrl = val;
4204
4107
  }
4205
4108
  }
4206
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4207
- import_react_ecs7.Button,
4109
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4110
+ import_react_ecs6.Button,
4208
4111
  {
4209
4112
  uiTransform: { width: this.s(75), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4210
4113
  uiBackground: { color: C2.green },
@@ -4213,8 +4116,8 @@ var AdminPanelUIModule = class {
4213
4116
  color: C2.text,
4214
4117
  onMouseDown: () => this.playNow()
4215
4118
  }
4216
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4217
- import_react_ecs7.Button,
4119
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4120
+ import_react_ecs6.Button,
4218
4121
  {
4219
4122
  uiTransform: { width: this.s(65), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 6 } },
4220
4123
  uiBackground: { color: C2.btn },
@@ -4225,16 +4128,16 @@ var AdminPanelUIModule = class {
4225
4128
  this.customVideoUrl = "";
4226
4129
  }
4227
4130
  }
4228
- )), this.videoStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4229
- import_react_ecs7.Label,
4131
+ )), this.videoStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
4132
+ import_react_ecs6.Label,
4230
4133
  {
4231
4134
  value: this.videoStatus,
4232
4135
  fontSize: t.status,
4233
4136
  color: this.videoStatus.startsWith("Not sent") || this.videoStatus === LOCKED_LINE || this.videoStatus === UNAVAILABLE_LINE ? C2.red : C2.green,
4234
4137
  uiTransform: { height: this.s(18), margin: { bottom: 6 } }
4235
4138
  }
4236
- ), /* @__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(
4237
- import_react_ecs7.Button,
4139
+ ), /* @__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(
4140
+ import_react_ecs6.Button,
4238
4141
  {
4239
4142
  uiTransform: { width: this.s(75), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4240
4143
  uiBackground: { color: C2.green },
@@ -4243,8 +4146,8 @@ var AdminPanelUIModule = class {
4243
4146
  color: C2.text,
4244
4147
  onMouseDown: () => this.playbackPlay()
4245
4148
  }
4246
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4247
- import_react_ecs7.Button,
4149
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4150
+ import_react_ecs6.Button,
4248
4151
  {
4249
4152
  uiTransform: { width: this.s(75), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4250
4153
  uiBackground: { color: C2.red },
@@ -4253,8 +4156,8 @@ var AdminPanelUIModule = class {
4253
4156
  color: C2.text,
4254
4157
  onMouseDown: () => this.playbackStop()
4255
4158
  }
4256
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4257
- import_react_ecs7.Button,
4159
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4160
+ import_react_ecs6.Button,
4258
4161
  {
4259
4162
  uiTransform: { width: this.s(100), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
4260
4163
  uiBackground: { color: C2.btn },
@@ -4263,8 +4166,8 @@ var AdminPanelUIModule = class {
4263
4166
  color: C2.text,
4264
4167
  onMouseDown: () => this.resetDefault()
4265
4168
  }
4266
- )), /* @__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(
4267
- import_react_ecs7.Button,
4169
+ )), /* @__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(
4170
+ import_react_ecs6.Button,
4268
4171
  {
4269
4172
  key: `play-${slot}`,
4270
4173
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
@@ -4274,8 +4177,8 @@ var AdminPanelUIModule = class {
4274
4177
  color: C2.text,
4275
4178
  onMouseDown: () => this.pressSlot(slot)
4276
4179
  }
4277
- ))), /* @__PURE__ */ import_react_ecs7.default.createElement(
4278
- import_react_ecs7.Button,
4180
+ ))), /* @__PURE__ */ import_react_ecs6.default.createElement(
4181
+ import_react_ecs6.Button,
4279
4182
  {
4280
4183
  uiTransform: { height: this.s(24) },
4281
4184
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0) },
@@ -4288,16 +4191,16 @@ var AdminPanelUIModule = class {
4288
4191
  };
4289
4192
  this.ModTab = () => {
4290
4193
  const t = this.theme;
4291
- 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(
4292
- import_react_ecs7.Label,
4194
+ 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(
4195
+ import_react_ecs6.Label,
4293
4196
  {
4294
4197
  value: this.kickStatus,
4295
4198
  fontSize: t.status,
4296
4199
  color: this.kickStatus.startsWith("Kick not sent") ? C2.red : C2.green,
4297
4200
  uiTransform: { height: this.s(18) }
4298
4201
  }
4299
- ), /* @__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(
4300
- import_react_ecs7.Input,
4202
+ ), /* @__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(
4203
+ import_react_ecs6.Input,
4301
4204
  {
4302
4205
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4303
4206
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4310,8 +4213,8 @@ var AdminPanelUIModule = class {
4310
4213
  this.broadcastText = val;
4311
4214
  }
4312
4215
  }
4313
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4314
- import_react_ecs7.Button,
4216
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4217
+ import_react_ecs6.Button,
4315
4218
  {
4316
4219
  uiTransform: { width: this.s(65), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4317
4220
  uiBackground: { color: C2.orange },
@@ -4320,16 +4223,16 @@ var AdminPanelUIModule = class {
4320
4223
  color: C2.text,
4321
4224
  onMouseDown: () => this.sendBroadcast()
4322
4225
  }
4323
- )), this.broadcastStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4324
- import_react_ecs7.Label,
4226
+ )), this.broadcastStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
4227
+ import_react_ecs6.Label,
4325
4228
  {
4326
4229
  value: this.broadcastStatus,
4327
4230
  fontSize: t.status,
4328
4231
  color: this.broadcastStatus.startsWith("Not sent") ? C2.red : C2.green,
4329
4232
  uiTransform: { height: this.s(18), margin: { bottom: 6 } }
4330
4233
  }
4331
- ), /* @__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(
4332
- import_react_ecs7.Button,
4234
+ ), /* @__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(
4235
+ import_react_ecs6.Button,
4333
4236
  {
4334
4237
  uiTransform: { width: this.s(130), height: this.s(UI_DIMENSIONS.admin.buttonHeight), margin: 4 },
4335
4238
  uiBackground: { color: C2.red },
@@ -4338,8 +4241,8 @@ var AdminPanelUIModule = class {
4338
4241
  color: C2.text,
4339
4242
  onMouseDown: () => this.kickAll()
4340
4243
  }
4341
- )), 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(
4342
- import_react_ecs7.Button,
4244
+ )), 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(
4245
+ import_react_ecs6.Button,
4343
4246
  {
4344
4247
  key: `private-${on ? "on" : "off"}`,
4345
4248
  uiTransform: { width: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4 },
@@ -4349,22 +4252,22 @@ var AdminPanelUIModule = class {
4349
4252
  color: this.privateModeOn === on ? import_math7.Color4.Black() : C2.text,
4350
4253
  onMouseDown: () => this.setPrivateMode(on)
4351
4254
  }
4352
- ))), this.privateStatus && /* @__PURE__ */ import_react_ecs7.default.createElement(
4353
- import_react_ecs7.Label,
4255
+ ))), this.privateStatus && /* @__PURE__ */ import_react_ecs6.default.createElement(
4256
+ import_react_ecs6.Label,
4354
4257
  {
4355
4258
  value: this.privateStatus,
4356
4259
  fontSize: t.status,
4357
4260
  color: this.privateStatus.startsWith("Not sent") ? C2.red : C2.green,
4358
4261
  uiTransform: { height: this.s(18) }
4359
4262
  }
4360
- )), /* @__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(
4361
- import_react_ecs7.UiEntity,
4263
+ )), /* @__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(
4264
+ import_react_ecs6.UiEntity,
4362
4265
  {
4363
4266
  key: `admin-${i}`,
4364
4267
  uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 5 }, width: "100%" }
4365
4268
  },
4366
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4367
- import_react_ecs7.Label,
4269
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4270
+ import_react_ecs6.Label,
4368
4271
  {
4369
4272
  value: `${wallet.slice(0, 6)}...${wallet.slice(-4)}`,
4370
4273
  fontSize: t.label,
@@ -4372,8 +4275,8 @@ var AdminPanelUIModule = class {
4372
4275
  uiTransform: { width: this.s(130) }
4373
4276
  }
4374
4277
  ),
4375
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4376
- import_react_ecs7.Button,
4278
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4279
+ import_react_ecs6.Button,
4377
4280
  {
4378
4281
  uiTransform: { width: this.s(70), height: this.s(28), margin: { left: 8 } },
4379
4282
  uiBackground: { color: C2.btn },
@@ -4383,8 +4286,8 @@ var AdminPanelUIModule = class {
4383
4286
  onMouseDown: () => this.removeSceneAdmin(wallet)
4384
4287
  }
4385
4288
  )
4386
- ))), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4387
- import_react_ecs7.Input,
4289
+ ))), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 14 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4290
+ import_react_ecs6.Input,
4388
4291
  {
4389
4292
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4390
4293
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4397,8 +4300,8 @@ var AdminPanelUIModule = class {
4397
4300
  this.newAdminWallet = val;
4398
4301
  }
4399
4302
  }
4400
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4401
- import_react_ecs7.Button,
4303
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4304
+ import_react_ecs6.Button,
4402
4305
  {
4403
4306
  uiTransform: { width: this.s(60), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4404
4307
  uiBackground: { color: C2.purple },
@@ -4409,14 +4312,14 @@ var AdminPanelUIModule = class {
4409
4312
  if (this.newAdminWallet) this.addSceneAdmin(this.newAdminWallet);
4410
4313
  }
4411
4314
  }
4412
- )), /* @__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(
4413
- import_react_ecs7.UiEntity,
4315
+ )), /* @__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(
4316
+ import_react_ecs6.UiEntity,
4414
4317
  {
4415
4318
  key: `ban-${i}`,
4416
4319
  uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 5 }, width: "100%" }
4417
4320
  },
4418
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4419
- import_react_ecs7.Label,
4321
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4322
+ import_react_ecs6.Label,
4420
4323
  {
4421
4324
  value: `${wallet.slice(0, 6)}...${wallet.slice(-4)}`,
4422
4325
  fontSize: t.label,
@@ -4424,8 +4327,8 @@ var AdminPanelUIModule = class {
4424
4327
  uiTransform: { width: this.s(130) }
4425
4328
  }
4426
4329
  ),
4427
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4428
- import_react_ecs7.Button,
4330
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4331
+ import_react_ecs6.Button,
4429
4332
  {
4430
4333
  uiTransform: { width: this.s(70), height: this.s(28), margin: { left: 8 } },
4431
4334
  uiBackground: { color: C2.green },
@@ -4435,8 +4338,8 @@ var AdminPanelUIModule = class {
4435
4338
  onMouseDown: () => this.unbanWallet(wallet)
4436
4339
  }
4437
4340
  )
4438
- ))), /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs7.default.createElement(
4439
- import_react_ecs7.Input,
4341
+ ))), /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.UiEntity, { uiTransform: { flexDirection: "row", alignItems: "center", margin: { bottom: 10 } } }, /* @__PURE__ */ import_react_ecs6.default.createElement(
4342
+ import_react_ecs6.Input,
4440
4343
  {
4441
4344
  uiTransform: { width: this.s(230), height: this.s(UI_DIMENSIONS.admin.inputHeight) },
4442
4345
  uiBackground: { color: import_math7.Color4.create(0.15, 0.15, 0.2, 1) },
@@ -4449,8 +4352,8 @@ var AdminPanelUIModule = class {
4449
4352
  this.newBanWallet = val;
4450
4353
  }
4451
4354
  }
4452
- ), /* @__PURE__ */ import_react_ecs7.default.createElement(
4453
- import_react_ecs7.Button,
4355
+ ), /* @__PURE__ */ import_react_ecs6.default.createElement(
4356
+ import_react_ecs6.Button,
4454
4357
  {
4455
4358
  uiTransform: { width: this.s(60), height: this.s(UI_DIMENSIONS.admin.inputHeight), margin: { left: 8 } },
4456
4359
  uiBackground: { color: C2.red },
@@ -4461,8 +4364,8 @@ var AdminPanelUIModule = class {
4461
4364
  if (this.newBanWallet) this.banWallet(this.newBanWallet);
4462
4365
  }
4463
4366
  }
4464
- )), /* @__PURE__ */ import_react_ecs7.default.createElement(
4465
- import_react_ecs7.Button,
4367
+ )), /* @__PURE__ */ import_react_ecs6.default.createElement(
4368
+ import_react_ecs6.Button,
4466
4369
  {
4467
4370
  uiTransform: { height: this.s(24) },
4468
4371
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0) },
@@ -4508,8 +4411,8 @@ var AdminPanelUIModule = class {
4508
4411
  if (!tabs.find((tab) => tab.id === this.activeTab) && tabs.length > 0) {
4509
4412
  this.activeTab = tabs[0].id;
4510
4413
  }
4511
- return /* @__PURE__ */ import_react_ecs7.default.createElement(
4512
- import_react_ecs7.UiEntity,
4414
+ return /* @__PURE__ */ import_react_ecs6.default.createElement(
4415
+ import_react_ecs6.UiEntity,
4513
4416
  {
4514
4417
  uiTransform: {
4515
4418
  width: "100%",
@@ -4518,8 +4421,11 @@ var AdminPanelUIModule = class {
4518
4421
  }
4519
4422
  },
4520
4423
  this.renderScaledNotification(),
4521
- this.client.isPhone ? toolbarButton(2, { children: [this.renderToggleFace()] }, true, this.client.uiScale) : /* @__PURE__ */ import_react_ecs7.default.createElement(
4522
- import_react_ecs7.UiEntity,
4424
+ this.client.isPhone || this.client.toolbarCollapsed ? this.client.toolbarButton(2, {
4425
+ uiBackground: { color: this.panelOpen ? C2.btn : C2.header },
4426
+ children: [this.renderToggleFace()]
4427
+ }) : /* @__PURE__ */ import_react_ecs6.default.createElement(
4428
+ import_react_ecs6.UiEntity,
4523
4429
  {
4524
4430
  uiTransform: {
4525
4431
  position: { right: 20 + this.s(100) + 10 + this.s(100) + 10, bottom: 10 },
@@ -4541,8 +4447,8 @@ var AdminPanelUIModule = class {
4541
4447
  uiBackground: { color: C2.bg },
4542
4448
  children: [
4543
4449
  // Header with font controls
4544
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4545
- import_react_ecs7.UiEntity,
4450
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4451
+ import_react_ecs6.UiEntity,
4546
4452
  {
4547
4453
  uiTransform: {
4548
4454
  width: "100%",
@@ -4554,9 +4460,9 @@ var AdminPanelUIModule = class {
4554
4460
  },
4555
4461
  uiBackground: { color: C2.header }
4556
4462
  },
4557
- /* @__PURE__ */ import_react_ecs7.default.createElement(import_react_ecs7.Label, { value: this.config.title || "ADMIN PANEL", fontSize: t.header, color: C2.text }),
4558
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4559
- import_react_ecs7.Button,
4463
+ /* @__PURE__ */ import_react_ecs6.default.createElement(import_react_ecs6.Label, { value: this.config.title || "ADMIN PANEL", fontSize: t.header, color: C2.text }),
4464
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4465
+ import_react_ecs6.Button,
4560
4466
  {
4561
4467
  uiTransform: { width: this.s(28), height: this.s(28) },
4562
4468
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0.3) },
@@ -4568,10 +4474,10 @@ var AdminPanelUIModule = class {
4568
4474
  )
4569
4475
  ),
4570
4476
  // Tabs
4571
- /* @__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 }))),
4477
+ /* @__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 }))),
4572
4478
  // Content
4573
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4574
- import_react_ecs7.UiEntity,
4479
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4480
+ import_react_ecs6.UiEntity,
4575
4481
  {
4576
4482
  uiTransform: {
4577
4483
  width: "100%",
@@ -4580,14 +4486,14 @@ var AdminPanelUIModule = class {
4580
4486
  flexDirection: "column"
4581
4487
  }
4582
4488
  },
4583
- this.activeTab === "controls" && this.venue && this.controls.length > 0 && /* @__PURE__ */ import_react_ecs7.default.createElement(this.ControlsTab, null),
4584
- this.activeTab === "video" && /* @__PURE__ */ import_react_ecs7.default.createElement(this.VideoTab, null),
4585
- this.activeTab === "mod" && this.isOwner && /* @__PURE__ */ import_react_ecs7.default.createElement(this.ModTab, null),
4489
+ this.activeTab === "controls" && this.venue && this.controls.length > 0 && /* @__PURE__ */ import_react_ecs6.default.createElement(this.ControlsTab, null),
4490
+ this.activeTab === "video" && /* @__PURE__ */ import_react_ecs6.default.createElement(this.VideoTab, null),
4491
+ this.activeTab === "mod" && this.isOwner && /* @__PURE__ */ import_react_ecs6.default.createElement(this.ModTab, null),
4586
4492
  this.config.sceneTabs?.map((tab) => this.activeTab === tab.id && tab.render())
4587
4493
  ),
4588
4494
  // Footer
4589
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4590
- import_react_ecs7.UiEntity,
4495
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4496
+ import_react_ecs6.UiEntity,
4591
4497
  {
4592
4498
  uiTransform: {
4593
4499
  width: "100%",
@@ -4597,8 +4503,8 @@ var AdminPanelUIModule = class {
4597
4503
  },
4598
4504
  uiBackground: { color: C2.section }
4599
4505
  },
4600
- /* @__PURE__ */ import_react_ecs7.default.createElement(
4601
- import_react_ecs7.Button,
4506
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
4507
+ import_react_ecs6.Button,
4602
4508
  {
4603
4509
  uiTransform: { height: this.s(24) },
4604
4510
  uiBackground: { color: import_math7.Color4.create(0, 0, 0, 0) },
@@ -5766,8 +5672,8 @@ var AdminPanelUIModule = class {
5766
5672
  /** A control's button (2026-11-18): the option's label, highlighted while that option is current on this copy */
5767
5673
  controlButton(control, option, label) {
5768
5674
  const current = this.currentOption[control.id] === option;
5769
- return /* @__PURE__ */ import_react_ecs7.default.createElement(
5770
- import_react_ecs7.Button,
5675
+ return /* @__PURE__ */ import_react_ecs6.default.createElement(
5676
+ import_react_ecs6.Button,
5771
5677
  {
5772
5678
  key: `control-${control.id}-${option}`,
5773
5679
  uiTransform: { minWidth: this.s(70), height: this.s(UI_DIMENSIONS.admin.buttonHeightSmall), margin: 4, padding: { left: 10, right: 10 } },
@@ -5789,8 +5695,8 @@ var AdminPanelUIModule = class {
5789
5695
  if (!state.visible) return null;
5790
5696
  const N2 = UI_DIMENSIONS.notification;
5791
5697
  const colors = THEME.colors;
5792
- return /* @__PURE__ */ import_react_ecs7.default.createElement(
5793
- import_react_ecs7.UiEntity,
5698
+ return /* @__PURE__ */ import_react_ecs6.default.createElement(
5699
+ import_react_ecs6.UiEntity,
5794
5700
  {
5795
5701
  uiTransform: {
5796
5702
  positionType: "absolute",
@@ -5800,8 +5706,8 @@ var AdminPanelUIModule = class {
5800
5706
  alignItems: "center"
5801
5707
  }
5802
5708
  },
5803
- /* @__PURE__ */ import_react_ecs7.default.createElement(
5804
- import_react_ecs7.UiEntity,
5709
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
5710
+ import_react_ecs6.UiEntity,
5805
5711
  {
5806
5712
  uiTransform: {
5807
5713
  minWidth: this.s(200),
@@ -5813,15 +5719,15 @@ var AdminPanelUIModule = class {
5813
5719
  },
5814
5720
  uiBackground: { color: colors.panel }
5815
5721
  },
5816
- /* @__PURE__ */ import_react_ecs7.default.createElement(
5817
- import_react_ecs7.UiEntity,
5722
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
5723
+ import_react_ecs6.UiEntity,
5818
5724
  {
5819
5725
  uiTransform: { width: N2.borderWidth, height: "100%" },
5820
5726
  uiBackground: { color: colors.cyan }
5821
5727
  }
5822
5728
  ),
5823
- /* @__PURE__ */ import_react_ecs7.default.createElement(
5824
- import_react_ecs7.UiEntity,
5729
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
5730
+ import_react_ecs6.UiEntity,
5825
5731
  {
5826
5732
  uiTransform: {
5827
5733
  flexGrow: 1,
@@ -5831,8 +5737,8 @@ var AdminPanelUIModule = class {
5831
5737
  alignItems: "center"
5832
5738
  }
5833
5739
  },
5834
- /* @__PURE__ */ import_react_ecs7.default.createElement(
5835
- import_react_ecs7.Label,
5740
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
5741
+ import_react_ecs6.Label,
5836
5742
  {
5837
5743
  value: state.text,
5838
5744
  fontSize: this.s(N2.fontSize),
@@ -5841,8 +5747,8 @@ var AdminPanelUIModule = class {
5841
5747
  }
5842
5748
  )
5843
5749
  ),
5844
- /* @__PURE__ */ import_react_ecs7.default.createElement(
5845
- import_react_ecs7.UiEntity,
5750
+ /* @__PURE__ */ import_react_ecs6.default.createElement(
5751
+ import_react_ecs6.UiEntity,
5846
5752
  {
5847
5753
  uiTransform: { width: 5, height: 5, margin: { right: 10 } },
5848
5754
  uiBackground: { color: colors.cyan }
@@ -5853,8 +5759,8 @@ var AdminPanelUIModule = class {
5853
5759
  }
5854
5760
  /** The ADMIN / CLOSE button itself; its place is the row's or, on a phone, the column's (2.12.0) */
5855
5761
  renderToggleFace() {
5856
- return /* @__PURE__ */ import_react_ecs7.default.createElement(
5857
- import_react_ecs7.Button,
5762
+ return /* @__PURE__ */ import_react_ecs6.default.createElement(
5763
+ import_react_ecs6.Button,
5858
5764
  {
5859
5765
  uiTransform: { width: this.s(100), height: this.s(45) },
5860
5766
  uiBackground: { color: this.panelOpen ? C2.btn : C2.header },
@@ -5870,6 +5776,222 @@ var AdminPanelUIModule = class {
5870
5776
  // src/StaticTVClient.ts
5871
5777
  var import_Runtime2 = require("~system/Runtime");
5872
5778
 
5779
+ // src/ui/toolbar.ts
5780
+ var TOOLBAR = { edge: 20, gap: 10, buttonWidth: 100, buttonHeight: 45, bottom: 10 };
5781
+ var COLUMN_SLOTS = 5;
5782
+ var PHONE_EDGE = 0;
5783
+ var HANDLE = 24;
5784
+ var STRIP = { phone: 12, desktop: 10 };
5785
+ function platformOf(answer) {
5786
+ const raw = answer?.platform;
5787
+ if (typeof raw !== "string") return "unknown";
5788
+ const p = raw.trim().toLowerCase();
5789
+ return p === "desktop" || p === "mobile" || p === "vr" || p === "web" ? p : "unknown";
5790
+ }
5791
+ function isPhonePlatform(platform) {
5792
+ return platform === "mobile";
5793
+ }
5794
+ var scaled = (value, uiScale) => Math.round(value * uiScale);
5795
+ function rowRight(slot, uiScale = 1) {
5796
+ return TOOLBAR.edge + slot * (scaled(TOOLBAR.buttonWidth, uiScale) + TOOLBAR.gap);
5797
+ }
5798
+ function columnSlot(slot, uiScale = 1) {
5799
+ const h = scaled(TOOLBAR.buttonHeight, uiScale);
5800
+ const handle = scaled(HANDLE, uiScale) + TOOLBAR.gap;
5801
+ return {
5802
+ right: PHONE_EDGE,
5803
+ boxHeight: handle + COLUMN_SLOTS * h + (COLUMN_SLOTS - 1) * TOOLBAR.gap,
5804
+ above: handle + Math.max(0, slot) * (h + TOOLBAR.gap)
5805
+ };
5806
+ }
5807
+ function handlePlace(phone, lastSlot, uiScale = 1) {
5808
+ if (phone) {
5809
+ return {
5810
+ right: PHONE_EDGE,
5811
+ width: scaled(TOOLBAR.buttonWidth, uiScale),
5812
+ height: scaled(HANDLE, uiScale),
5813
+ boxHeight: columnSlot(0, uiScale).boxHeight,
5814
+ above: 0
5815
+ };
5816
+ }
5817
+ return {
5818
+ right: rowRight(Math.max(0, lastSlot) + 1, uiScale),
5819
+ bottom: TOOLBAR.bottom,
5820
+ width: scaled(HANDLE, uiScale),
5821
+ height: scaled(TOOLBAR.buttonHeight, uiScale)
5822
+ };
5823
+ }
5824
+ function stripPlace(slot, phone, uiScale = 1) {
5825
+ if (phone) return { right: PHONE_EDGE, width: scaled(STRIP.phone, uiScale), height: scaled(TOOLBAR.buttonHeight, uiScale) };
5826
+ return { right: rowRight(slot, uiScale), bottom: 0, width: scaled(TOOLBAR.buttonWidth, uiScale), height: scaled(STRIP.desktop, uiScale) };
5827
+ }
5828
+ var ToolbarFold = class {
5829
+ constructor(closeAll) {
5830
+ this._collapsed = false;
5831
+ this._sceneLast = -1;
5832
+ this.closeAll = closeAll;
5833
+ }
5834
+ get collapsed() {
5835
+ return this._collapsed;
5836
+ }
5837
+ collapse() {
5838
+ if (this._collapsed) return;
5839
+ this.closeAll();
5840
+ this._collapsed = true;
5841
+ }
5842
+ expand() {
5843
+ this._collapsed = false;
5844
+ }
5845
+ /** A button was drawn in `slot` */
5846
+ seen(slot) {
5847
+ if (slot > this._sceneLast) this._sceneLast = slot;
5848
+ }
5849
+ /** The row's last slot: the SDK's own last (ADMIN's 2 when drawn, else GUIDE's 1) or a scene's, whichever is higher */
5850
+ lastSlot(sdkLast) {
5851
+ return Math.max(sdkLast, this._sceneLast);
5852
+ }
5853
+ };
5854
+ function panelRight(phone, desktopRight, uiScale = 1) {
5855
+ return phone ? PHONE_EDGE + scaled(TOOLBAR.buttonWidth, uiScale) + TOOLBAR.gap : desktopRight;
5856
+ }
5857
+ var DESKTOP_CLOSES = { guide: ["admin"], admin: ["guide"] };
5858
+ var GUIDE_PLACE = ["guide", "admin"];
5859
+ function panelsToClose(opened, registered, phone, coversGuide = []) {
5860
+ if (phone) return registered.filter((name) => name !== opened);
5861
+ const closes = [...DESKTOP_CLOSES[opened] ?? []];
5862
+ if (GUIDE_PLACE.includes(opened)) closes.push(...coversGuide);
5863
+ if (coversGuide.includes(opened)) closes.push(...GUIDE_PLACE);
5864
+ return registered.filter((name) => name !== opened && closes.includes(name));
5865
+ }
5866
+ var PanelRules = class {
5867
+ constructor(phone) {
5868
+ this.hides = /* @__PURE__ */ new Map();
5869
+ this.coveringGuide = /* @__PURE__ */ new Set();
5870
+ this.phone = phone;
5871
+ }
5872
+ /** Register (or replace) a panel; its hide runs when another panel opens and the rule says so */
5873
+ register(name, hide, options = {}) {
5874
+ this.hides.set(name, hide);
5875
+ if (options.coversGuide === true) this.coveringGuide.add(name);
5876
+ else this.coveringGuide.delete(name);
5877
+ }
5878
+ /** Close every registered panel (2.14.0, the toolbar collapsing). One failing hide does not stop the rest. */
5879
+ closeAll() {
5880
+ for (const hide of this.hides.values()) {
5881
+ try {
5882
+ hide();
5883
+ } catch {
5884
+ }
5885
+ }
5886
+ }
5887
+ /** A panel opened: close the ones the rule names. One failing hide does not stop the rest. */
5888
+ opened(name) {
5889
+ for (const other of panelsToClose(name, [...this.hides.keys()], this.phone(), [...this.coveringGuide])) {
5890
+ try {
5891
+ this.hides.get(other)?.();
5892
+ } catch {
5893
+ }
5894
+ }
5895
+ }
5896
+ get names() {
5897
+ return [...this.hides.keys()];
5898
+ }
5899
+ };
5900
+
5901
+ // src/ui/toolbar-button.ts
5902
+ var import_react_ecs7 = __toESM(require("@dcl/sdk/react-ecs"));
5903
+ function inColumn(width, boxHeight, above, right, entity) {
5904
+ return import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5905
+ uiTransform: {
5906
+ positionType: "absolute",
5907
+ position: { right, top: 0 },
5908
+ width,
5909
+ height: "100%",
5910
+ flexDirection: "column",
5911
+ justifyContent: "center"
5912
+ },
5913
+ children: [
5914
+ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5915
+ uiTransform: { width, height: boxHeight, flexDirection: "column", flexShrink: 0 },
5916
+ children: [
5917
+ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, { uiTransform: { width, height: above, flexShrink: 0 } }),
5918
+ entity
5919
+ ]
5920
+ })
5921
+ ]
5922
+ });
5923
+ }
5924
+ function toolbarButton(slot, props, phone, uiScale = 1, fold) {
5925
+ const width = Math.round(TOOLBAR.buttonWidth * uiScale);
5926
+ const height = Math.round(TOOLBAR.buttonHeight * uiScale);
5927
+ if (fold?.collapsed) {
5928
+ const strip = stripPlace(slot, phone, uiScale);
5929
+ const face = { uiBackground: props.uiBackground, onMouseDown: () => fold.expand() };
5930
+ if (!phone) {
5931
+ return import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5932
+ ...face,
5933
+ uiTransform: {
5934
+ positionType: "absolute",
5935
+ position: { right: strip.right, bottom: strip.bottom },
5936
+ width: strip.width,
5937
+ height: strip.height
5938
+ }
5939
+ });
5940
+ }
5941
+ const place2 = columnSlot(slot, uiScale);
5942
+ return inColumn(strip.width, place2.boxHeight, place2.above, strip.right, import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5943
+ ...face,
5944
+ uiTransform: { width: strip.width, height: strip.height, flexShrink: 0 }
5945
+ }));
5946
+ }
5947
+ if (!phone) {
5948
+ return import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5949
+ ...props,
5950
+ uiTransform: {
5951
+ positionType: "absolute",
5952
+ position: { right: rowRight(slot, uiScale), bottom: TOOLBAR.bottom },
5953
+ width,
5954
+ height,
5955
+ ...props.uiTransform
5956
+ }
5957
+ });
5958
+ }
5959
+ const place = columnSlot(slot, uiScale);
5960
+ return inColumn(width, place.boxHeight, place.above, place.right, import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5961
+ ...props,
5962
+ uiTransform: { width, height, flexShrink: 0, ...props.uiTransform }
5963
+ }));
5964
+ }
5965
+ function toolbarHandle(phone, lastSlot, collapse, uiScale = 1) {
5966
+ const place = handlePlace(phone, lastSlot, uiScale);
5967
+ const face = {
5968
+ uiBackground: { color: THEME.colors.buttonBackground },
5969
+ onMouseDown: collapse,
5970
+ children: [
5971
+ import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5972
+ uiText: { value: ">", fontSize: Math.round(14 * uiScale), color: THEME.colors.gray, textAlign: "middle-center" }
5973
+ })
5974
+ ]
5975
+ };
5976
+ if (!phone) {
5977
+ return import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5978
+ ...face,
5979
+ uiTransform: {
5980
+ positionType: "absolute",
5981
+ position: { right: place.right, bottom: place.bottom },
5982
+ width: place.width,
5983
+ height: place.height,
5984
+ justifyContent: "center",
5985
+ alignItems: "center"
5986
+ }
5987
+ });
5988
+ }
5989
+ return inColumn(place.width, place.boxHeight, place.above, place.right, import_react_ecs7.default.createElement(import_react_ecs7.UiEntity, {
5990
+ ...face,
5991
+ uiTransform: { width: place.width, height: place.height, flexShrink: 0, justifyContent: "center", alignItems: "center" }
5992
+ }));
5993
+ }
5994
+
5873
5995
  // src/ui/toolbar-panel.ts
5874
5996
  var import_react_ecs8 = __toESM(require("@dcl/sdk/react-ecs"));
5875
5997
  function toolbarPanel(props, phone, uiScale = 1) {
@@ -5967,6 +6089,8 @@ var _StaticTVClient = class _StaticTVClient {
5967
6089
  * scene's (registerPanel); elsewhere the guide and the admin panel close each other, as before.
5968
6090
  */
5969
6091
  this.panelRules = new PanelRules(() => this.isPhone);
6092
+ /** The toolbar collapsed to strips or not, for the visit (2.14.0): collapsing closes every panel first */
6093
+ this.fold = new ToolbarFold(() => this.panelRules.closeAll());
5970
6094
  // =============================================================================
5971
6095
  // --- VIDEO PLAYBACK (Internal handler for videoScreen) ---
5972
6096
  // =============================================================================
@@ -6900,7 +7024,8 @@ var _StaticTVClient = class _StaticTVClient {
6900
7024
  * placed its own by hand before), the column on a phone. Slots count from the right (the row) or the top (the
6901
7025
  * 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
6902
7026
  * scene's. `props` is the button's face - its uiBackground, onMouseDown and children - the slot gives its place and
6903
- * size (a width or height in props.uiTransform wins).
7027
+ * size (a width or height in props.uiTransform wins). Collapsed (2.14.0) it draws a strip in the face's uiBackground
7028
+ * color instead, flush on the edge, and a press on any strip expands the toolbar.
6904
7029
  *
6905
7030
  * @example
6906
7031
  * ```typescript
@@ -6913,7 +7038,29 @@ var _StaticTVClient = class _StaticTVClient {
6913
7038
  * ```
6914
7039
  */
6915
7040
  toolbarButton(slot, props) {
6916
- return toolbarButton(slot, props, this.isPhone, this.uiScale);
7041
+ this.fold.seen(slot);
7042
+ return toolbarButton(slot, props, this.isPhone, this.uiScale, {
7043
+ collapsed: this.fold.collapsed,
7044
+ expand: () => this.fold.expand()
7045
+ });
7046
+ }
7047
+ /**
7048
+ * The toolbar collapsed to strips (2.14.0, his ask: "small tabs out of users way"): the `>` handle collapses it and
7049
+ * closes every open panel, the scene's registered ones too; any strip expands it. For the visit only; it starts
7050
+ * expanded. A scene drawing its buttons through toolbarButton needs nothing more.
7051
+ */
7052
+ get toolbarCollapsed() {
7053
+ return this.fold.collapsed;
7054
+ }
7055
+ /**
7056
+ * The `>` handle, drawn by the SDK's chat (2.14.0): on a phone a bar on top of the column, on desktop a tab one slot
7057
+ * past the row's last button (ADMIN's or a scene's), so no button moves. Nothing while collapsed.
7058
+ * @internal
7059
+ */
7060
+ toolbarHandle() {
7061
+ if (this.fold.collapsed) return null;
7062
+ const sdkLast = this.adminPanel?.hasAccess === true ? 2 : 1;
7063
+ return toolbarHandle(this.isPhone, this.fold.lastSlot(sdkLast), () => this.fold.collapse(), this.uiScale);
6917
7064
  }
6918
7065
  /** Where a scene's own panel's right edge goes: on a phone one gap left of the column; elsewhere `desktopRight` */
6919
7066
  panelRight(desktopRight) {