@pretty-chitty/core 2.3.5 → 2.3.7

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.
Files changed (151) hide show
  1. package/dist/1ea77c9e193d437b9bfa.woff +0 -0
  2. package/dist/2282b9ff81c2cd7cf5b4.mp3 +0 -0
  3. package/dist/22a445dd65cce94defdd.woff2 +0 -0
  4. package/dist/2b94f846c05846d73536.mp3 +0 -0
  5. package/dist/32d6296b80e676d66bda.woff +0 -0
  6. package/dist/36e7e033bfef7b32bf3c.mp3 +0 -0
  7. package/dist/37f3b2ddcbe588b2aaa5.jpg +0 -0
  8. package/dist/3f0fb9058a03e14ad2fa.jpg +0 -0
  9. package/dist/412050b824afb24fef88.mp3 +0 -0
  10. package/dist/468cf705a21091e5f755.mp3 +0 -0
  11. package/dist/47a823ae095f5f4cfd82.woff +0 -0
  12. package/dist/5062c95fb3c68af2ee2e.woff2 +0 -0
  13. package/dist/5aecd40f51b84ffb6efa.woff2 +0 -0
  14. package/dist/5d184fc5808150d51726.mp3 +0 -0
  15. package/dist/60b937eec087d648c831.woff2 +0 -0
  16. package/dist/63da6d06ce0ff84b8b2c.mp3 +0 -0
  17. package/dist/63f3d4f28784375801ac.woff +0 -0
  18. package/dist/669804475e1d5e52a4f5.mp3 +0 -0
  19. package/dist/6a6d042ba2a9290aba9c.woff2 +0 -0
  20. package/dist/72e60d1c7f7c603f31d6.woff +0 -0
  21. package/dist/788c3dfe27f9734edff5.mp3 +0 -0
  22. package/dist/7e339dfbea59fe54f2e3.png +0 -0
  23. package/dist/7ecd698217d211cad841.mp3 +0 -0
  24. package/dist/8c8f3dcefaec6a40d787.mp3 +0 -0
  25. package/dist/8d29c92c7f9ca79d8a5c.mp3 +0 -0
  26. package/dist/8ea5f16c95238d2ff902.mp3 +0 -0
  27. package/dist/97e19a7d82ab67080019.mp3 +0 -0
  28. package/dist/98373f88bbc3b8237b09.mp3 +0 -0
  29. package/dist/98c71bee993adc81d5be.mp3 +0 -0
  30. package/dist/a09db3cc936e581f320a.mp3 +0 -0
  31. package/dist/a51c64560480e6fdae0d.mp3 +0 -0
  32. package/dist/ad2392bc6cdf9bb1b5fd.mp3 +0 -0
  33. package/dist/b3708bfbeff0d340bdef.mp3 +0 -0
  34. package/dist/b81893c113e684d9eec4.woff +0 -0
  35. package/dist/bc6bc3d7802469910f83.mp3 +0 -0
  36. package/dist/bde37bf538e175149c3b.mp3 +0 -0
  37. package/dist/d6b5a560b17d31cd3c7c.mp3 +0 -0
  38. package/dist/dd3231a4b15c4f8f2b94.mp3 +0 -0
  39. package/dist/f63358bf5b9e4f8d7f79.mp3 +0 -0
  40. package/dist/fc02be176de567378fa4.woff2 +0 -0
  41. package/dist/fe1535c25dc5d879c085.mp3 +0 -0
  42. package/dist/index.html +12 -0
  43. package/dist/main.034dfcc6b83fdd218994.hot-update.js +265 -0
  44. package/dist/main.034dfcc6b83fdd218994.hot-update.js.map +1 -0
  45. package/dist/main.034dfcc6b83fdd218994.hot-update.json +1 -0
  46. package/dist/main.0c0a98b3b3e1e004beb2.hot-update.js +265 -0
  47. package/dist/main.0c0a98b3b3e1e004beb2.hot-update.js.map +1 -0
  48. package/dist/main.0c0a98b3b3e1e004beb2.hot-update.json +1 -0
  49. package/dist/main.13daf8cac0f0a3231f6a.hot-update.js +190 -0
  50. package/dist/main.13daf8cac0f0a3231f6a.hot-update.js.map +1 -0
  51. package/dist/main.13daf8cac0f0a3231f6a.hot-update.json +1 -0
  52. package/dist/main.14e055541f09be93a122.hot-update.js +321 -0
  53. package/dist/main.14e055541f09be93a122.hot-update.js.map +1 -0
  54. package/dist/main.14e055541f09be93a122.hot-update.json +1 -0
  55. package/dist/main.26499c88c63113e7a3f8.hot-update.js +190 -0
  56. package/dist/main.26499c88c63113e7a3f8.hot-update.js.map +1 -0
  57. package/dist/main.26499c88c63113e7a3f8.hot-update.json +1 -0
  58. package/dist/main.2c3a3f1928ea25c4b79a.hot-update.js +11 -0
  59. package/dist/main.2c3a3f1928ea25c4b79a.hot-update.js.map +1 -0
  60. package/dist/main.2c3a3f1928ea25c4b79a.hot-update.json +1 -0
  61. package/dist/main.324b63996b3b36daf5af.hot-update.js +603 -0
  62. package/dist/main.324b63996b3b36daf5af.hot-update.js.map +1 -0
  63. package/dist/main.324b63996b3b36daf5af.hot-update.json +1 -0
  64. package/dist/main.4b0f7799388b5de9908d.hot-update.js +265 -0
  65. package/dist/main.4b0f7799388b5de9908d.hot-update.js.map +1 -0
  66. package/dist/main.4b0f7799388b5de9908d.hot-update.json +1 -0
  67. package/dist/main.6424291443afea7eb7ac.hot-update.js +187 -0
  68. package/dist/main.6424291443afea7eb7ac.hot-update.js.map +1 -0
  69. package/dist/main.6424291443afea7eb7ac.hot-update.json +1 -0
  70. package/dist/main.69127e32a0c76b421f15.hot-update.js +392 -0
  71. package/dist/main.69127e32a0c76b421f15.hot-update.js.map +1 -0
  72. package/dist/main.69127e32a0c76b421f15.hot-update.json +1 -0
  73. package/dist/main.755d91e1a6c7e6bd6702.hot-update.js +265 -0
  74. package/dist/main.755d91e1a6c7e6bd6702.hot-update.js.map +1 -0
  75. package/dist/main.755d91e1a6c7e6bd6702.hot-update.json +1 -0
  76. package/dist/main.75a666c9d30baa58c5ec.hot-update.js +265 -0
  77. package/dist/main.75a666c9d30baa58c5ec.hot-update.js.map +1 -0
  78. package/dist/main.75a666c9d30baa58c5ec.hot-update.json +1 -0
  79. package/dist/main.828f4c348446c6c3640d.hot-update.js +11 -0
  80. package/dist/main.828f4c348446c6c3640d.hot-update.js.map +1 -0
  81. package/dist/main.828f4c348446c6c3640d.hot-update.json +1 -0
  82. package/dist/main.8459249b2915a8823bd3.hot-update.js +321 -0
  83. package/dist/main.8459249b2915a8823bd3.hot-update.js.map +1 -0
  84. package/dist/main.8459249b2915a8823bd3.hot-update.json +1 -0
  85. package/dist/main.87f757c2602cac7001cb.hot-update.js +382 -0
  86. package/dist/main.87f757c2602cac7001cb.hot-update.js.map +1 -0
  87. package/dist/main.87f757c2602cac7001cb.hot-update.json +1 -0
  88. package/dist/main.8aa248086ab27072c348.hot-update.js +265 -0
  89. package/dist/main.8aa248086ab27072c348.hot-update.js.map +1 -0
  90. package/dist/main.8aa248086ab27072c348.hot-update.json +1 -0
  91. package/dist/main.8ce461bf769f3943b7ed.hot-update.js +265 -0
  92. package/dist/main.8ce461bf769f3943b7ed.hot-update.js.map +1 -0
  93. package/dist/main.8ce461bf769f3943b7ed.hot-update.json +1 -0
  94. package/dist/main.9fdbde5beb7c70940250.hot-update.js +392 -0
  95. package/dist/main.9fdbde5beb7c70940250.hot-update.js.map +1 -0
  96. package/dist/main.9fdbde5beb7c70940250.hot-update.json +1 -0
  97. package/dist/main.af59faaae348c919e033.hot-update.js +11 -0
  98. package/dist/main.af59faaae348c919e033.hot-update.js.map +1 -0
  99. package/dist/main.af59faaae348c919e033.hot-update.json +1 -0
  100. package/dist/main.b11900976593b0e609ee.hot-update.js +187 -0
  101. package/dist/main.b11900976593b0e609ee.hot-update.js.map +1 -0
  102. package/dist/main.b11900976593b0e609ee.hot-update.json +1 -0
  103. package/dist/main.b57518d376449c846971.hot-update.js +265 -0
  104. package/dist/main.b57518d376449c846971.hot-update.js.map +1 -0
  105. package/dist/main.b57518d376449c846971.hot-update.json +1 -0
  106. package/dist/main.b5fa8b91f66c4a67740b.hot-update.js +265 -0
  107. package/dist/main.b5fa8b91f66c4a67740b.hot-update.js.map +1 -0
  108. package/dist/main.b5fa8b91f66c4a67740b.hot-update.json +1 -0
  109. package/dist/main.bdb9e6ab1d13cf4250e8.hot-update.js +265 -0
  110. package/dist/main.bdb9e6ab1d13cf4250e8.hot-update.js.map +1 -0
  111. package/dist/main.bdb9e6ab1d13cf4250e8.hot-update.json +1 -0
  112. package/dist/main.c9b051fce9f983306d51.hot-update.js +265 -0
  113. package/dist/main.c9b051fce9f983306d51.hot-update.js.map +1 -0
  114. package/dist/main.c9b051fce9f983306d51.hot-update.json +1 -0
  115. package/dist/main.d03d8e0bfcbd86932c58.hot-update.js +638 -0
  116. package/dist/main.d03d8e0bfcbd86932c58.hot-update.js.map +1 -0
  117. package/dist/main.d03d8e0bfcbd86932c58.hot-update.json +1 -0
  118. package/dist/main.d3b74a9a35325f35373d.hot-update.js +265 -0
  119. package/dist/main.d3b74a9a35325f35373d.hot-update.js.map +1 -0
  120. package/dist/main.d3b74a9a35325f35373d.hot-update.json +1 -0
  121. package/dist/main.d61b231278a9c69df2f8.hot-update.js +265 -0
  122. package/dist/main.d61b231278a9c69df2f8.hot-update.js.map +1 -0
  123. package/dist/main.d61b231278a9c69df2f8.hot-update.json +1 -0
  124. package/dist/pretty-chitty.js +243813 -0
  125. package/dist/pretty-chitty.js.map +1 -0
  126. package/package.json +1 -1
  127. package/src/library/components/ActionLogDisplay.tsx +1 -1
  128. package/src/library/components/ActionLogSidebar.tsx +1 -1
  129. package/src/library/components/BottomBar.tsx +2 -0
  130. package/src/library/components/BottomBarButton.tsx +3 -3
  131. package/src/library/components/MatchViewer.tsx +23 -9
  132. package/src/library/components/Panel/MultiPanel.tsx +7 -6
  133. package/src/library/components/Panel/PanelContents.tsx +4 -2
  134. package/src/library/components/Panel/SinglePanel.tsx +7 -6
  135. package/src/library/components/SettingsDisplay.tsx +152 -90
  136. package/src/library/components/TopBar.tsx +2 -0
  137. package/src/library/components/TopBarPlayers.tsx +4 -2
  138. package/src/library/game/Chit.ts +3 -2
  139. package/src/library/game/DisplaySettings.test.ts +80 -0
  140. package/src/library/game/DisplaySettings.ts +153 -0
  141. package/src/library/game/GameButton.ts +2 -0
  142. package/src/library/game/GameTheme.ts +10 -0
  143. package/src/library/game/Pick.ts +3 -2
  144. package/src/library/game/PlayerPromptStatusChit.ts +2 -0
  145. package/src/library/game/SparkChit.ts +2 -0
  146. package/src/library/game/typeName.test.ts +51 -0
  147. package/src/library/game/typeName.ts +40 -0
  148. package/src/library/hooks/useDisplaySettings.tsx +58 -0
  149. package/src/library/index.ts +1 -0
  150. package/src/library/utilities/CanvasStack/CanvasStack.ts +40 -3
  151. package/src/library/hooks/usePanelScale.tsx +0 -23
@@ -0,0 +1,603 @@
1
+ "use strict";
2
+ self["webpackHotUpdate_pretty_chitty_core"]("main",{
3
+
4
+ /***/ "./src/library/components/Panel/PanelContents.tsx":
5
+ /*!********************************************************!*\
6
+ !*** ./src/library/components/Panel/PanelContents.tsx ***!
7
+ \********************************************************/
8
+ /***/ ((module, __webpack_exports__, __webpack_require__) => {
9
+
10
+ __webpack_require__.r(__webpack_exports__);
11
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
12
+ /* harmony export */ PanelContents: () => (/* binding */ PanelContents),
13
+ /* harmony export */ useGestureContext: () => (/* binding */ useGestureContext)
14
+ /* harmony export */ });
15
+ /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "./node_modules/react/index.js");
16
+ /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
17
+ /* harmony import */ var _mui_material__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @mui/material */ "./node_modules/@mui/material/Box/Box.js");
18
+ /* harmony import */ var _react_hook_size__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @react-hook/size */ "./node_modules/@react-hook/size/dist/module/index.js");
19
+ /* harmony import */ var _hooks_useGameTheme__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../hooks/useGameTheme */ "./src/library/hooks/useGameTheme.tsx");
20
+ /* harmony import */ var _hooks_useDisplaySettings__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../hooks/useDisplaySettings */ "./src/library/hooks/useDisplaySettings.tsx");
21
+ /* harmony import */ var _hooks_usePlayer__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../hooks/usePlayer */ "./src/library/hooks/usePlayer.tsx");
22
+ /* harmony import */ var _SinglePanel__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./SinglePanel */ "./src/library/components/Panel/SinglePanel.tsx");
23
+ /* harmony import */ var _MultiPanel__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./MultiPanel */ "./src/library/components/Panel/MultiPanel.tsx");
24
+ /* harmony import */ var _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @egjs/hammerjs */ "./node_modules/@egjs/hammerjs/dist/hammer.esm.js");
25
+ /* harmony import */ var _hooks_usePanelPositioning__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../hooks/usePanelPositioning */ "./src/library/hooks/usePanelPositioning.tsx");
26
+ /* harmony import */ var _ViewerWrapper__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./ViewerWrapper */ "./src/library/components/Panel/ViewerWrapper.tsx");
27
+ /* harmony import */ var _hooks_usePanelNavigation__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../hooks/usePanelNavigation */ "./src/library/hooks/usePanelNavigation.tsx");
28
+ /* harmony import */ var _hooks_useModalState__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../hooks/useModalState */ "./src/library/hooks/useModalState.tsx");
29
+ /* harmony import */ var _ExternalDrag__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./ExternalDrag */ "./src/library/components/Panel/ExternalDrag.ts");
30
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__(/*! ./node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js */ "./node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
31
+ /* provided dependency */ var __react_refresh_error_overlay__ = __webpack_require__(/*! ./node_modules/@pmmmwh/react-refresh-webpack-plugin/overlay/index.js */ "./node_modules/@pmmmwh/react-refresh-webpack-plugin/overlay/index.js");
32
+ __webpack_require__.$Refresh$.runtime = __webpack_require__(/*! ./node_modules/react-refresh/runtime.js */ "./node_modules/react-refresh/runtime.js");
33
+
34
+ var _s = __webpack_require__.$Refresh$.signature(),
35
+ _s2 = __webpack_require__.$Refresh$.signature();
36
+ function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = "function" == typeof Symbol ? Symbol : {}, n = r.iterator || "@@iterator", o = r.toStringTag || "@@toStringTag"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, "_invoke", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError("Generator is already running"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = "next"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i["return"]) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine2(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, "Generator"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, "toString", function () { return "[object Generator]"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }
37
+ function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { if (r) i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n;else { var o = function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); }; o("next", 0), o("throw", 1), o("return", 2); } }, _regeneratorDefine2(e, r, n, t); }
38
+ function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }
39
+ function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; }
40
+ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
41
+ function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
42
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
43
+ function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
44
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
45
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
46
+ function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
47
+
48
+
49
+
50
+
51
+
52
+
53
+
54
+
55
+
56
+
57
+
58
+
59
+
60
+
61
+
62
+ // Types for gesture handling
63
+
64
+ var GestureContext = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.createContext)(null);
65
+ function useGestureContext() {
66
+ _s();
67
+ return (0,react__WEBPACK_IMPORTED_MODULE_0__.useContext)(GestureContext);
68
+ }
69
+ _s(useGestureContext, "gDsCjeeItUuvgOWf1v4qoK9RF6k=");
70
+ function PanelContents(_ref) {
71
+ _s2();
72
+ var rootChit = _ref.rootChit,
73
+ scaleWidth = _ref.scaleWidth,
74
+ scaleHeight = _ref.scaleHeight;
75
+ var theme = (0,_hooks_useGameTheme__WEBPACK_IMPORTED_MODULE_1__.useGameTheme)();
76
+ var ref = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(null);
77
+ var _useSize = (0,_react_hook_size__WEBPACK_IMPORTED_MODULE_2__["default"])(ref),
78
+ _useSize2 = _slicedToArray(_useSize, 2),
79
+ width = _useSize2[0],
80
+ height = _useSize2[1];
81
+ var _useState = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(),
82
+ _useState2 = _slicedToArray(_useState, 2),
83
+ focusedPanel = _useState2[0],
84
+ setFocusedPanel = _useState2[1];
85
+ var scale = (0,_hooks_useDisplaySettings__WEBPACK_IMPORTED_MODULE_3__.usePanelScale)();
86
+ var playerId = (0,_hooks_usePlayer__WEBPACK_IMPORTED_MODULE_4__.usePlayerId)();
87
+ var layout = rootChit.getFlatLayout(width, height, scaleWidth / width * scale, scaleHeight / height * scale, playerId);
88
+ var hasRootChitInLayout = layout.find(function (item) {
89
+ return item.chit === rootChit;
90
+ }) !== undefined;
91
+
92
+ // Viewer registration system
93
+ var viewerRegistrationsRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(new Map());
94
+ var registerViewer = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (registration) {
95
+ viewerRegistrationsRef.current.set(registration.id, registration);
96
+ return function () {
97
+ viewerRegistrationsRef.current["delete"](registration.id);
98
+ };
99
+ }, []);
100
+
101
+ // A drag from the inline gallery lands on the viewer that renders the chit's drop targets.
102
+ var modalState = (0,_hooks_useModalState__WEBPACK_IMPORTED_MODULE_5__.useModalState)();
103
+ (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
104
+ modalState.externalDragHost = {
105
+ begin: function begin(chit, item, clientX, clientY) {
106
+ var _chit$dropTargets, _chit$dropTargets$fin;
107
+ if (!chit.onDrag || !((_chit$dropTargets = chit.dropTargets) !== null && _chit$dropTargets !== void 0 && _chit$dropTargets.length)) return undefined;
108
+ var root = (_chit$dropTargets$fin = chit.dropTargets.find(function (t) {
109
+ return t.renderInstance;
110
+ })) === null || _chit$dropTargets$fin === void 0 || (_chit$dropTargets$fin = _chit$dropTargets$fin.renderInstance) === null || _chit$dropTargets$fin === void 0 ? void 0 : _chit$dropTargets$fin.rootRenderInstance;
111
+ if (!root) return undefined;
112
+ var _iterator = _createForOfIteratorHelper(viewerRegistrationsRef.current.values()),
113
+ _step;
114
+ try {
115
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
116
+ var registration = _step.value;
117
+ if (registration.renderInstance === root && registration.getBounds()) {
118
+ return (0,_ExternalDrag__WEBPACK_IMPORTED_MODULE_6__.startExternalDrag)(chit, item, {
119
+ getBounds: registration.getBounds,
120
+ renderInstance: root
121
+ }, clientX, clientY);
122
+ }
123
+ }
124
+ } catch (err) {
125
+ _iterator.e(err);
126
+ } finally {
127
+ _iterator.f();
128
+ }
129
+ return undefined;
130
+ }
131
+ };
132
+ return function () {
133
+ modalState.externalDragHost = undefined;
134
+ };
135
+ }, [modalState]);
136
+
137
+ // Panel positioning system
138
+ var positionsRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(new Map([["root", {
139
+ chitId: "root",
140
+ x: -40,
141
+ y: 0,
142
+ w: 30,
143
+ h: 30,
144
+ front: true,
145
+ visible: true,
146
+ paused: true
147
+ }]]));
148
+ var _useState3 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)({}),
149
+ _useState4 = _slicedToArray(_useState3, 2),
150
+ forceUpdate = _useState4[1];
151
+ var registerPosition = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (chitId, position) {
152
+ positionsRef.current.set(chitId, position);
153
+ forceUpdate({});
154
+ }, []);
155
+ var unregisterPosition = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (chitId) {
156
+ positionsRef.current["delete"](chitId);
157
+ forceUpdate({});
158
+ }, []);
159
+
160
+ // Find which viewer contains a point
161
+ var findViewerAtPoint = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (x, y) {
162
+ var _iterator2 = _createForOfIteratorHelper(viewerRegistrationsRef.current.values()),
163
+ _step2;
164
+ try {
165
+ for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
166
+ var registration = _step2.value;
167
+ var bounds = registration.getBounds();
168
+ if (bounds && x >= bounds.left && x <= bounds.right && y >= bounds.top && y <= bounds.bottom) {
169
+ return registration;
170
+ }
171
+ }
172
+ } catch (err) {
173
+ _iterator2.e(err);
174
+ } finally {
175
+ _iterator2.f();
176
+ }
177
+ return null;
178
+ }, []);
179
+
180
+ // Setup single HammerJS instance
181
+ (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
182
+ var el = ref.current;
183
+ if (!el) {
184
+ return;
185
+ }
186
+ var hammer = new _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__["default"].Manager(el);
187
+ hammer.add(new _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__["default"].Tap({
188
+ event: "doubletap",
189
+ taps: 2,
190
+ interval: 300,
191
+ threshold: 5,
192
+ posThreshold: 50
193
+ }));
194
+ hammer.add(new _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__["default"].Tap({
195
+ event: "singletap",
196
+ time: 400
197
+ }));
198
+ hammer.add(new _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__["default"].Pinch({
199
+ event: "pinch",
200
+ threshold: 0.03
201
+ }));
202
+ hammer.add(new _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__["default"].Pan({
203
+ event: "pan",
204
+ direction: _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__["default"].DIRECTION_ALL
205
+ }));
206
+ hammer.add(new _egjs_hammerjs__WEBPACK_IMPORTED_MODULE_7__["default"].Press({
207
+ event: "longtap",
208
+ time: 600
209
+ }));
210
+ hammer.get("singletap").requireFailure("doubletap");
211
+ hammer.get("longtap").recognizeWith("singletap");
212
+ hammer.get("singletap").requireFailure("longtap");
213
+ var activeViewer = null;
214
+ var lastDeltaX = 0;
215
+ var lastDeltaY = 0;
216
+ var lastScale = 1;
217
+ var panCancelled = false;
218
+ var pinchCancelled = false;
219
+
220
+ // Tap handlers
221
+ hammer.on("longtap", function (ev) {
222
+ var viewer = findViewerAtPoint(ev.center.x, ev.center.y);
223
+ if (viewer !== null && viewer !== void 0 && viewer.handlers.onLongTap) {
224
+ var bounds = viewer.getBounds();
225
+ if (bounds) {
226
+ var x = ev.center.x - bounds.left;
227
+ var y = ev.center.y - bounds.top;
228
+ var isMouse = ev.pointerType === "mouse";
229
+ viewer.handlers.onLongTap(x, y, isMouse);
230
+ }
231
+ }
232
+ });
233
+ hammer.on("singletap", function (ev) {
234
+ var viewer = findViewerAtPoint(ev.center.x, ev.center.y);
235
+ if (viewer !== null && viewer !== void 0 && viewer.handlers.onSingleTap) {
236
+ var bounds = viewer.getBounds();
237
+ if (bounds) {
238
+ var x = ev.center.x - bounds.left;
239
+ var y = ev.center.y - bounds.top;
240
+ var isMouse = ev.pointerType === "mouse";
241
+ viewer.handlers.onSingleTap(x, y, isMouse);
242
+ }
243
+ }
244
+ });
245
+ hammer.on("doubletap", function (ev) {
246
+ var viewer = findViewerAtPoint(ev.center.x, ev.center.y);
247
+ if (viewer !== null && viewer !== void 0 && viewer.handlers.onDoubleTap) {
248
+ var bounds = viewer.getBounds();
249
+ if (bounds) {
250
+ var x = ev.center.x - bounds.left;
251
+ var y = ev.center.y - bounds.top;
252
+ viewer.handlers.onDoubleTap(x, y);
253
+ }
254
+ }
255
+ });
256
+
257
+ // Pan handlers
258
+ hammer.on("panstart", function (ev) {
259
+ var _activeViewer;
260
+ var startX = ev.center.x - ev.deltaX;
261
+ var startY = ev.center.y - ev.deltaY;
262
+ activeViewer = findViewerAtPoint(startX, startY);
263
+ lastDeltaX = 0;
264
+ lastDeltaY = 0;
265
+ panCancelled = false;
266
+ var bounds = (_activeViewer = activeViewer) === null || _activeViewer === void 0 ? void 0 : _activeViewer.getBounds();
267
+ if (bounds) {
268
+ var _handlers$onPanStart, _handlers;
269
+ var x = startX - bounds.left;
270
+ var y = startY - bounds.top;
271
+ (_handlers$onPanStart = (_handlers = activeViewer.handlers).onPanStart) === null || _handlers$onPanStart === void 0 || _handlers$onPanStart.call(_handlers, x, y, ev.pointerType === "mouse");
272
+ }
273
+ });
274
+ hammer.on("pan", function (ev) {
275
+ var _activeViewer$handler, _activeViewer$handler2;
276
+ if (!activeViewer || panCancelled) {
277
+ return;
278
+ }
279
+ var dx = ev.deltaX - lastDeltaX;
280
+ var dy = ev.deltaY - lastDeltaY;
281
+ lastDeltaX = ev.deltaX;
282
+ lastDeltaY = ev.deltaY;
283
+ (_activeViewer$handler = (_activeViewer$handler2 = activeViewer.handlers).onPan) === null || _activeViewer$handler === void 0 || _activeViewer$handler.call(_activeViewer$handler2, dx, dy, ev);
284
+ });
285
+ hammer.on("panend", function () {
286
+ if (activeViewer) {
287
+ var _activeViewer$handler3, _activeViewer$handler4;
288
+ (_activeViewer$handler3 = (_activeViewer$handler4 = activeViewer.handlers).onPanEnd) === null || _activeViewer$handler3 === void 0 || _activeViewer$handler3.call(_activeViewer$handler4);
289
+ }
290
+ activeViewer = null;
291
+ });
292
+
293
+ // Pinch handlers
294
+ hammer.on("pinchstart", function (ev) {
295
+ var _activeViewer2, _activeViewer2$handle, _activeViewer2$handle2;
296
+ activeViewer = findViewerAtPoint(ev.center.x, ev.center.y);
297
+ lastScale = 1;
298
+ pinchCancelled = false;
299
+ (_activeViewer2 = activeViewer) === null || _activeViewer2 === void 0 || (_activeViewer2$handle = (_activeViewer2$handle2 = _activeViewer2.handlers).onPinchStart) === null || _activeViewer2$handle === void 0 || _activeViewer2$handle.call(_activeViewer2$handle2);
300
+ });
301
+ hammer.on("pinch", function (ev) {
302
+ if (!activeViewer || pinchCancelled) {
303
+ return;
304
+ }
305
+ var bounds = activeViewer.getBounds();
306
+ if (bounds) {
307
+ var _activeViewer$handler5, _activeViewer$handler6;
308
+ var centerX = ev.center.x - bounds.left;
309
+ var centerY = ev.center.y - bounds.top;
310
+ var deltaScale = ev.scale - lastScale;
311
+ lastScale = ev.scale;
312
+ (_activeViewer$handler5 = (_activeViewer$handler6 = activeViewer.handlers).onPinch) === null || _activeViewer$handler5 === void 0 || _activeViewer$handler5.call(_activeViewer$handler6, ev.scale, deltaScale, centerX, centerY);
313
+ }
314
+ });
315
+ hammer.on("pinchend", function () {
316
+ var _activeViewer3, _activeViewer3$handle, _activeViewer3$handle2;
317
+ (_activeViewer3 = activeViewer) === null || _activeViewer3 === void 0 || (_activeViewer3$handle = (_activeViewer3$handle2 = _activeViewer3.handlers).onPinchEnd) === null || _activeViewer3$handle === void 0 || _activeViewer3$handle.call(_activeViewer3$handle2);
318
+ activeViewer = null;
319
+ pinchCancelled = true;
320
+ });
321
+ return function () {
322
+ hammer.destroy();
323
+ };
324
+ }, [findViewerAtPoint]);
325
+ var gestureContextValue = {
326
+ registerViewer: registerViewer
327
+ };
328
+ var positioningContextValue = {
329
+ positions: positionsRef.current,
330
+ registerPosition: registerPosition,
331
+ unregisterPosition: unregisterPosition
332
+ };
333
+ var fullChitList = layout.flatMap(function (cell) {
334
+ return Array.isArray(cell.chit) ? cell.chit : [cell.chit];
335
+ });
336
+ var tabChitList = fullChitList.concat();
337
+ if (!hasRootChitInLayout) {
338
+ fullChitList.push(rootChit);
339
+ }
340
+
341
+ // Panel navigation (used by the tutorial overlay to bring a chit's panel to the front)
342
+ var selectorsRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(new Map());
343
+ var panelRootsRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(tabChitList);
344
+ panelRootsRef.current = tabChitList;
345
+ var focusedPanelRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(focusedPanel);
346
+ focusedPanelRef.current = focusedPanel;
347
+ /** The panel root (a chit with its own viewer) that shows `chit` */
348
+ var panelOf = function panelOf(chit) {
349
+ var roots = new Set(panelRootsRef.current.map(function (c) {
350
+ return c.id;
351
+ }));
352
+ var panel = chit;
353
+ while (panel && !roots.has(panel.id)) {
354
+ panel = panel.parent;
355
+ }
356
+ return panel;
357
+ };
358
+ var navigation = (0,react__WEBPACK_IMPORTED_MODULE_0__.useMemo)(function () {
359
+ return {
360
+ registerSelector: function registerSelector(chitId, select) {
361
+ selectorsRef.current.set(chitId, select);
362
+ return function () {
363
+ if (selectorsRef.current.get(chitId) === select) selectorsRef.current["delete"](chitId);
364
+ };
365
+ },
366
+ panelRoots: function panelRoots() {
367
+ return panelRootsRef.current;
368
+ },
369
+ isFront: function isFront(chitId) {
370
+ var _positionsRef$current, _positionsRef$current2;
371
+ return (_positionsRef$current = (_positionsRef$current2 = positionsRef.current.get(chitId)) === null || _positionsRef$current2 === void 0 ? void 0 : _positionsRef$current2.front) !== null && _positionsRef$current !== void 0 ? _positionsRef$current : false;
372
+ },
373
+ revealChit: function () {
374
+ var _revealChit = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(chit) {
375
+ var _positionsRef$current3, _positionsRef$current4;
376
+ var panel, select;
377
+ return _regenerator().w(function (_context) {
378
+ while (1) switch (_context.n) {
379
+ case 0:
380
+ panel = panelOf(chit);
381
+ if (panel !== null && panel !== void 0 && panel.id) {
382
+ _context.n = 1;
383
+ break;
384
+ }
385
+ return _context.a(2, false);
386
+ case 1:
387
+ // Showing a panel full screen (the player zoomed in, or a tutorial focused it): that layout
388
+ // has every panel as a tab, so switch tabs there rather than leave it
389
+ select = selectorsRef.current.get(panel.id);
390
+ if (!(select && !((_positionsRef$current3 = (_positionsRef$current4 = positionsRef.current.get(panel.id)) === null || _positionsRef$current4 === void 0 ? void 0 : _positionsRef$current4.front) !== null && _positionsRef$current3 !== void 0 ? _positionsRef$current3 : false))) {
391
+ _context.n = 2;
392
+ break;
393
+ }
394
+ select();
395
+ _context.n = 2;
396
+ return new Promise(function (resolve) {
397
+ return setTimeout(resolve, 400);
398
+ });
399
+ case 2:
400
+ return _context.a(2, true);
401
+ }
402
+ }, _callee);
403
+ }));
404
+ function revealChit(_x) {
405
+ return _revealChit.apply(this, arguments);
406
+ }
407
+ return revealChit;
408
+ }(),
409
+ keepFront: function keepFront(chit) {
410
+ var _positionsRef$current5, _positionsRef$current6, _selectorsRef$current;
411
+ // Selecting the tab already in front changes nothing but re-arms its hold against the
412
+ // automatic "show where something changed" switching
413
+ var panel = panelOf(chit);
414
+ if (panel !== null && panel !== void 0 && panel.id && ((_positionsRef$current5 = (_positionsRef$current6 = positionsRef.current.get(panel.id)) === null || _positionsRef$current6 === void 0 ? void 0 : _positionsRef$current6.front) !== null && _positionsRef$current5 !== void 0 ? _positionsRef$current5 : false)) (_selectorsRef$current = selectorsRef.current.get(panel.id)) === null || _selectorsRef$current === void 0 || _selectorsRef$current();
415
+ },
416
+ focusedPanel: function focusedPanel() {
417
+ return focusedPanelRef.current;
418
+ },
419
+ focusPanelOf: function () {
420
+ var _focusPanelOf = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2(chit) {
421
+ var panel, _selectorsRef$current2;
422
+ return _regenerator().w(function (_context2) {
423
+ while (1) switch (_context2.n) {
424
+ case 0:
425
+ panel = chit ? panelOf(chit) : undefined;
426
+ if (!(chit && !(panel !== null && panel !== void 0 && panel.id))) {
427
+ _context2.n = 1;
428
+ break;
429
+ }
430
+ return _context2.a(2, false);
431
+ case 1:
432
+ if (!(focusedPanelRef.current === panel)) {
433
+ _context2.n = 2;
434
+ break;
435
+ }
436
+ return _context2.a(2, true);
437
+ case 2:
438
+ if (!panel) {
439
+ setFocusedPanel(undefined);
440
+ } else if (focusedPanelRef.current) {
441
+ (_selectorsRef$current2 = selectorsRef.current.get(panel.id)) === null || _selectorsRef$current2 === void 0 || _selectorsRef$current2(); // already full screen: switch to its tab
442
+ } else {
443
+ setFocusedPanel(panel);
444
+ }
445
+ _context2.n = 3;
446
+ return new Promise(function (resolve) {
447
+ return setTimeout(resolve, 400);
448
+ });
449
+ case 3:
450
+ return _context2.a(2, true);
451
+ }
452
+ }, _callee2);
453
+ }));
454
+ function focusPanelOf(_x2) {
455
+ return _focusPanelOf.apply(this, arguments);
456
+ }
457
+ return focusPanelOf;
458
+ }()
459
+ };
460
+ }, []);
461
+ // The tutorial overlay is outside these panels: it reaches the navigation through the viewer
462
+ (0,_hooks_usePanelNavigation__WEBPACK_IMPORTED_MODULE_8__.usePublishPanelNavigation)(navigation);
463
+ return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(GestureContext.Provider, {
464
+ value: gestureContextValue
465
+ }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_hooks_usePanelPositioning__WEBPACK_IMPORTED_MODULE_9__.PanelPositioningContext.Provider, {
466
+ value: positioningContextValue
467
+ }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_hooks_usePanelNavigation__WEBPACK_IMPORTED_MODULE_8__.PanelNavigationContext.Provider, {
468
+ value: navigation
469
+ }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_mui_material__WEBPACK_IMPORTED_MODULE_10__["default"], {
470
+ sx: {
471
+ position: "relative",
472
+ flex: 1,
473
+ // Each panel insets itself by panelSpacing / 4 (SinglePanel, MultiPanel), so two neighbours sit
474
+ // panelSpacing / 2 apart; a quarter here gives the screen edge that same gap
475
+ p: "".concat(theme.getPanelSpacing() * 0.25, "px")
476
+ }
477
+ }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_mui_material__WEBPACK_IMPORTED_MODULE_10__["default"], {
478
+ ref: ref,
479
+ sx: {
480
+ position: "relative",
481
+ width: "100%",
482
+ height: "100%"
483
+ }
484
+ }, layout.map(function (cell) {
485
+ if (Array.isArray(cell.chit) && cell.chit.length > 1) {
486
+ return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_MultiPanel__WEBPACK_IMPORTED_MODULE_11__.MultiPanel, {
487
+ enabled: focusedPanel === undefined,
488
+ focusedPanel: focusedPanel,
489
+ setFocusedPanel: setFocusedPanel,
490
+ key: "m" + cell.id,
491
+ chits: cell.chit,
492
+ w: cell.w,
493
+ h: cell.h,
494
+ x: cell.x,
495
+ y: cell.y,
496
+ isFocusedPanel: false
497
+ });
498
+ } else {
499
+ return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_SinglePanel__WEBPACK_IMPORTED_MODULE_12__.SinglePanel, {
500
+ enabled: focusedPanel === undefined,
501
+ focusedPanel: focusedPanel,
502
+ setFocusedPanel: setFocusedPanel,
503
+ key: cell.id,
504
+ chit: Array.isArray(cell.chit) ? cell.chit[0] : cell.chit,
505
+ w: cell.w,
506
+ h: cell.h,
507
+ x: cell.x,
508
+ y: cell.y
509
+ });
510
+ }
511
+ }), !hasRootChitInLayout && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_SinglePanel__WEBPACK_IMPORTED_MODULE_12__.SinglePanel, {
512
+ focusedPanel: focusedPanel,
513
+ setFocusedPanel: setFocusedPanel,
514
+ paused: true,
515
+ chit: rootChit,
516
+ x: -5 - theme.spacing * 3,
517
+ y: 0,
518
+ w: theme.spacing * 3,
519
+ h: theme.spacing * 3,
520
+ enabled: true
521
+ }), focusedPanel && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_MultiPanel__WEBPACK_IMPORTED_MODULE_11__.MultiPanel, {
522
+ isFocusedPanel: true,
523
+ enabled: focusedPanel !== undefined,
524
+ focusedPanel: focusedPanel,
525
+ setFocusedPanel: setFocusedPanel,
526
+ chits: tabChitList,
527
+ x: 0,
528
+ y: 0,
529
+ w: width,
530
+ h: height
531
+ }), fullChitList.map(function (chit) {
532
+ var _chit$id;
533
+ var chitId = (_chit$id = chit.id) !== null && _chit$id !== void 0 ? _chit$id : "";
534
+ var position = positionsRef.current.get(chitId);
535
+ if (!position || !position.visible) {
536
+ return null;
537
+ }
538
+ return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_ViewerWrapper__WEBPACK_IMPORTED_MODULE_13__.ViewerWrapper, {
539
+ key: chitId,
540
+ focusedPanel: focusedPanel,
541
+ setFocusedPanel: setFocusedPanel,
542
+ front: position.front,
543
+ chit: chit,
544
+ w: position.w,
545
+ h: position.h,
546
+ x: position.x,
547
+ y: position.y,
548
+ paused: position.paused,
549
+ panCallback: position.panCallback,
550
+ transition: position.transition
551
+ });
552
+ }))))));
553
+ }
554
+ _s2(PanelContents, "tFEMvUfgAFVL4q4+TgqxjY8KUAU=", false, function () {
555
+ return [_hooks_useGameTheme__WEBPACK_IMPORTED_MODULE_1__.useGameTheme, _react_hook_size__WEBPACK_IMPORTED_MODULE_2__["default"], _hooks_useDisplaySettings__WEBPACK_IMPORTED_MODULE_3__.usePanelScale, _hooks_usePlayer__WEBPACK_IMPORTED_MODULE_4__.usePlayerId, _hooks_useModalState__WEBPACK_IMPORTED_MODULE_5__.useModalState, _hooks_usePanelNavigation__WEBPACK_IMPORTED_MODULE_8__.usePublishPanelNavigation];
556
+ });
557
+ _c = PanelContents;
558
+ var _c;
559
+ __webpack_require__.$Refresh$.register(_c, "PanelContents");
560
+
561
+ const $ReactRefreshModuleId$ = __webpack_require__.$Refresh$.moduleId;
562
+ const $ReactRefreshCurrentExports$ = __react_refresh_utils__.getModuleExports(
563
+ $ReactRefreshModuleId$
564
+ );
565
+
566
+ function $ReactRefreshModuleRuntime$(exports) {
567
+ if (true) {
568
+ let errorOverlay;
569
+ if (typeof __react_refresh_error_overlay__ !== 'undefined') {
570
+ errorOverlay = __react_refresh_error_overlay__;
571
+ }
572
+ let testMode;
573
+ if (typeof __react_refresh_test__ !== 'undefined') {
574
+ testMode = __react_refresh_test__;
575
+ }
576
+ return __react_refresh_utils__.executeRuntime(
577
+ exports,
578
+ $ReactRefreshModuleId$,
579
+ module.hot,
580
+ errorOverlay,
581
+ testMode
582
+ );
583
+ }
584
+ }
585
+
586
+ if (typeof Promise !== 'undefined' && $ReactRefreshCurrentExports$ instanceof Promise) {
587
+ $ReactRefreshCurrentExports$.then($ReactRefreshModuleRuntime$);
588
+ } else {
589
+ $ReactRefreshModuleRuntime$($ReactRefreshCurrentExports$);
590
+ }
591
+
592
+ /***/ })
593
+
594
+ },
595
+ /******/ function(__webpack_require__) { // webpackRuntimeModules
596
+ /******/ /* webpack/runtime/getFullHash */
597
+ /******/ (() => {
598
+ /******/ __webpack_require__.h = () => ("d03d8e0bfcbd86932c58")
599
+ /******/ })();
600
+ /******/
601
+ /******/ }
602
+ );
603
+ //# sourceMappingURL=main.324b63996b3b36daf5af.hot-update.js.map