{"code":"(window.webpackJsonpGUI=window.webpackJsonpGUI||[]).push([[43],{1379:function(e,t,n){\"use strict\";function s(){}n.d(t,\"a\",(function(){return s}))},1464:function(e,t,n){(e.exports=n(9)(!1)).push([e.i,'.pos-container-container {\\n display: flex;\\n align-items: center;\\n padding: 0.25rem;\\n user-select: none;\\n width: 45px;\\n justify-content: center;\\n}\\n\\n.pos-container {\\n font-size: 0.6rem;\\n font-weight: bold;\\n font-family: \"Helvetica Neue\", Helvetica, Arial, sans-serif;\\n color: #5cb1d6;\\n white-space: nowrap;\\n}\\n\\n/* Use pseudo elements to avoid firing mutation observers by just moving the cursor */\\n.pos-container > span::after {\\n content: attr(data-content);\\n}\\n\\n.sa-small-stage .pos-container-container {\\n display: none !important;\\n}\\n',\"\"])},1548:function(e,t,n){\"use strict\";n.r(t),n.d(t,\"resources\",(function(){return o}));var s=n(1379),c=n(1464);const o={\"userscript.js\":async function(e){let{addon:t,console:n}=e;var c=document.createElement(\"div\");t.tab.displayNoneWhileDisabled(c,{display:\"flex\"});var o=document.createElement(\"div\"),i=document.createElement(\"span\");c.className=\"pos-container-container\",o.className=\"pos-container\",c.appendChild(o),o.appendChild(i);const a=t.tab.traps.vm;a.runtime.ioDevices.mouse.__scratchX=a.runtime.ioDevices.mouse._scratchX,a.runtime.ioDevices.mouse.__scratchY=a.runtime.ioDevices.mouse._scratchY;var r=a.runtime.ioDevices.mouse.__scratchX?a.runtime.ioDevices.mouse.__scratchX:0,u=a.runtime.ioDevices.mouse.__scratchY?a.runtime.ioDevices.mouse.__scratchY:0;const d=()=>i.setAttribute(\"data-content\",\"\".concat(Math.round(r),\", \").concat(Math.round(u)));for(Object.defineProperty(a.runtime.ioDevices.mouse,\"_scratchX\",{get:function(){return this.__scratchX},set:function(e){r=e,d(),this.__scratchX=e}}),Object.defineProperty(a.runtime.ioDevices.mouse,\"_scratchY\",{get:function(){return this.__scratchY},set:function(e){u=e,d(),this.__scratchY=e}}),Object(s.a)();;)await t.tab.waitForElement('[class*=\"controls_controls-container\"]',{markAsSeen:!0,reduxEvents:[\"scratch-gui/mode/SET_PLAYER\",\"fontsLoaded/SET_FONTS_LOADED\",\"scratch-gui/locales/SELECT_LOCALE\"]}),\"editor\"===t.tab.editorMode&&t.tab.appendToSharedSpace({space:\"afterStopButton\",element:c,order:1})},\"style.css\":n.n(c).a}}}]);","name":"js/pentapod/addon-entry-mouse-pos.ca5f52cb19f5bcd0dedd.js","input":"(window[\"webpackJsonpGUI\"] = window[\"webpackJsonpGUI\"] || []).push([[43],{\n\n/***/ 1379:\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return addSmallStageClass; });\nfunction addSmallStageClass() {\n // TW: no-op; sa-small-stage class is handled by scratch-gui\n}\n\n/***/ }),\n\n/***/ 1464:\n/***/ (function(module, exports, __webpack_require__) {\n\nexports = module.exports = __webpack_require__(9)(false);\n// imports\n\n\n// module\nexports.push([module.i, \".pos-container-container {\\n display: flex;\\n align-items: center;\\n padding: 0.25rem;\\n user-select: none;\\n width: 45px;\\n justify-content: center;\\n}\\n\\n.pos-container {\\n font-size: 0.6rem;\\n font-weight: bold;\\n font-family: \\\"Helvetica Neue\\\", Helvetica, Arial, sans-serif;\\n color: #5cb1d6;\\n white-space: nowrap;\\n}\\n\\n/* Use pseudo elements to avoid firing mutation observers by just moving the cursor */\\n.pos-container > span::after {\\n content: attr(data-content);\\n}\\n\\n.sa-small-stage .pos-container-container {\\n display: none !important;\\n}\\n\", \"\"]);\n\n// exports\n\n\n/***/ }),\n\n/***/ 1548:\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n// ESM COMPAT FLAG\n__webpack_require__.r(__webpack_exports__);\n\n// EXPORTS\n__webpack_require__.d(__webpack_exports__, \"resources\", function() { return /* binding */ resources; });\n\n// EXTERNAL MODULE: ./src/addons/libraries/common/cs/small-stage.js\nvar small_stage = __webpack_require__(1379);\n\n// CONCATENATED MODULE: ./src/addons/addons/mouse-pos/userscript.js\n\n/* harmony default export */ var userscript = (async function (_ref) {\n let {\n addon,\n console\n } = _ref;\n var posContainerContainer = document.createElement(\"div\");\n addon.tab.displayNoneWhileDisabled(posContainerContainer, {\n display: \"flex\"\n });\n var posContainer = document.createElement(\"div\");\n var pos = document.createElement(\"span\");\n posContainerContainer.className = \"pos-container-container\";\n posContainer.className = \"pos-container\";\n posContainerContainer.appendChild(posContainer);\n posContainer.appendChild(pos);\n const vm = addon.tab.traps.vm;\n vm.runtime.ioDevices.mouse.__scratchX = vm.runtime.ioDevices.mouse._scratchX;\n vm.runtime.ioDevices.mouse.__scratchY = vm.runtime.ioDevices.mouse._scratchY;\n var x = vm.runtime.ioDevices.mouse.__scratchX ? vm.runtime.ioDevices.mouse.__scratchX : 0;\n var y = vm.runtime.ioDevices.mouse.__scratchY ? vm.runtime.ioDevices.mouse.__scratchY : 0;\n const showUpdatedValue = () => pos.setAttribute(\"data-content\", \"\".concat(Math.round(x), \", \").concat(Math.round(y)));\n Object.defineProperty(vm.runtime.ioDevices.mouse, \"_scratchX\", {\n get: function get() {\n return this.__scratchX;\n },\n set: function set(setx) {\n x = setx;\n showUpdatedValue();\n this.__scratchX = setx;\n }\n });\n Object.defineProperty(vm.runtime.ioDevices.mouse, \"_scratchY\", {\n get: function get() {\n return this.__scratchY;\n },\n set: function set(sety) {\n y = sety;\n showUpdatedValue();\n this.__scratchY = sety;\n }\n });\n Object(small_stage[\"a\" /* default */])();\n while (true) {\n await addon.tab.waitForElement('[class*=\"controls_controls-container\"]', {\n markAsSeen: true,\n reduxEvents: [\"scratch-gui/mode/SET_PLAYER\", \"fontsLoaded/SET_FONTS_LOADED\", \"scratch-gui/locales/SELECT_LOCALE\"]\n });\n if (addon.tab.editorMode === \"editor\") {\n addon.tab.appendToSharedSpace({\n space: \"afterStopButton\",\n element: posContainerContainer,\n order: 1\n });\n }\n }\n});\n// EXTERNAL MODULE: ./node_modules/css-loader!./src/addons/addons/mouse-pos/style.css\nvar style = __webpack_require__(1464);\nvar style_default = /*#__PURE__*/__webpack_require__.n(style);\n\n// CONCATENATED MODULE: ./src/addons/addons/mouse-pos/_runtime_entry.js\n/* generated by pull.js */\n\n\nconst resources = {\n \"userscript.js\": userscript,\n \"style.css\": style_default.a\n};\n\n/***/ })\n\n}]);","inputSourceMap":null}