{"version":3,"file":"chunks/gui.js","sources":["webpack://GUI/./src/playground/index.css","webpack://GUI/./src/playground/index.css?5c54","webpack://GUI/./src/playground/index.jsx","webpack://GUI/./src/playground/render-gui.jsx","webpack://GUI/./locale-data/complete.js (ignored)"],"sourcesContent":["exports = module.exports = require(\"../../node_modules/css-loader/lib/css-base.js\")(false);\n// imports\n\n\n// module\nexports.push([module.id, \"html,\\nbody,\\n.index_app_2mqDO {\\n /* probably unecessary, transitional until layout is refactored */\\n width: 100%; \\n height: 100%;\\n margin: 0;\\n\\n /* Setting min height/width makes the UI scroll below those sizes */\\n min-width: 1024px;\\n min-height: 640px; /* Min height to fit sprite/backdrop button */\\n}\\n\\n/* @todo: move globally? Safe / side FX, for blocks particularly? */\\n\\n* { -webkit-box-sizing: border-box; box-sizing: border-box; }\\n\", \"\"]);\n\n// exports\nexports.locals = {\n\t\"app\": \"index_app_2mqDO\"\n};","\nvar content = require(\"!!../../node_modules/css-loader/index.js??ref--5-1!../../node_modules/postcss-loader/src/index.js??postcss!./index.css\");\n\nif(typeof content === 'string') content = [[module.id, content, '']];\n\nvar transform;\nvar insertInto;\n\n\n\nvar options = {\"hmr\":true}\n\noptions.transform = transform\noptions.insertInto = undefined;\n\nvar update = require(\"!../../node_modules/style-loader/lib/addStyles.js\")(content, options);\n\nif(content.locals) module.exports = content.locals;\n\nif(module.hot) {\n\tmodule.hot.accept(\"!!../../node_modules/css-loader/index.js??ref--5-1!../../node_modules/postcss-loader/src/index.js??postcss!./index.css\", function() {\n\t\tvar newContent = require(\"!!../../node_modules/css-loader/index.js??ref--5-1!../../node_modules/postcss-loader/src/index.js??postcss!./index.css\");\n\n\t\tif(typeof newContent === 'string') newContent = [[module.id, newContent, '']];\n\n\t\tvar locals = (function(a, b) {\n\t\t\tvar key, idx = 0;\n\n\t\t\tfor(key in a) {\n\t\t\t\tif(!b || a[key] !== b[key]) return false;\n\t\t\t\tidx++;\n\t\t\t}\n\n\t\t\tfor(key in b) idx--;\n\n\t\t\treturn idx === 0;\n\t\t}(content.locals, newContent.locals));\n\n\t\tif(!locals) throw new Error('Aborting CSS HMR due to changed css-modules locals.');\n\n\t\tupdate(newContent);\n\t});\n\n\tmodule.hot.dispose(function() { update(); });\n}","// Polyfills\nimport 'es6-object-assign/auto';\nimport 'core-js/fn/array/includes';\nimport 'core-js/fn/promise/finally';\nimport 'intl'; // For Safari 9\n\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n\nimport analytics from '../lib/analytics';\nimport AppStateHOC from '../lib/app-state-hoc.jsx';\nimport BrowserModalComponent from '../components/browser-modal/browser-modal.jsx';\nimport supportedBrowser from '../lib/supported-browser';\n\nimport styles from './index.css';\n\n// Register \"base\" page view\nanalytics.pageview('/');\n\nconst appTarget = document.createElement('div');\nappTarget.className = styles.app;\ndocument.body.appendChild(appTarget);\n\n// 因为我们的浏览器是支持的,所以直接走render-gui.jsx的流程\nif (supportedBrowser()) {\n // require needed here to avoid importing unsupported browser-crashing code\n // at the top level\n require('./render-gui.jsx').default(appTarget);\n\n} else {\n BrowserModalComponent.setAppElement(appTarget);\n const WrappedBrowserModalComponent = AppStateHOC(BrowserModalComponent, true /* localesOnly */);\n const handleBack = () => {};\n // eslint-disable-next-line react/jsx-no-bind\n ReactDOM.render(, appTarget);\n}\n","import React from 'react';\nimport ReactDOM from 'react-dom';\nimport {compose} from 'redux';\n\nimport AppStateHOC from '../lib/app-state-hoc.jsx';\nimport GUI from '../containers/gui.jsx';\nimport HashParserHOC from '../lib/hash-parser-hoc.jsx';\nimport log from '../lib/log.js';\n\n//这里预留我们的官网\nconst onClickLogo = () => {\n window.location = 'https://www.ihaniel.cn/';\n};\n\n// 这下面都是为了给模拟桌面预留的,忽略\nconst handleTelemetryModalCancel = () => {\n log('User canceled telemetry modal');\n};\n\nconst handleTelemetryModalOptIn = () => {\n log('User opted into telemetry');\n};\n\nconst handleTelemetryModalOptOut = () => {\n log('User opted out of telemetry');\n};\n\n/*\n * Render the GUI playground. This is a separate function because importing anything\n * that instantiates the VM causes unsupported browsers to crash\n * {object} appTarget - the DOM element to render to\n */\nexport default appTarget => {\n GUI.setAppElement(appTarget);\n\n // note that redux's 'compose' function is just being used as a general utility to make\n // the hierarchy of HOC constructor calls clearer here; it has nothing to do with redux's\n // ability to compose reducers.\n \n const WrappedGui = compose(\n AppStateHOC,//这个封装整个项目state的\n HashParserHOC//这个是刷新页面新建项目的\n )(GUI);//这个是整个页面的布局\n\n // 忽略\n // TODO a hack for testing the backpack, allow backpack host to be set by url param\n const backpackHostMatches = window.location.href.match(/[?&]backpack_host=([^&]*)&?/);\n const backpackHost = backpackHostMatches ? backpackHostMatches[1] : null;\n\n // 根据链接匹配,因为我们没有这个scratch桌面匹配,所以这边肯定是false,忽略\n const scratchDesktopMatches = window.location.href.match(/[?&]isScratchDesktop=([^&]+)/);\n let simulateScratchDesktop;\n // 因为是null,这边忽略\n if (scratchDesktopMatches) {\n try {\n // parse 'true' into `true`, 'false' into `false`, etc.\n simulateScratchDesktop = JSON.parse(scratchDesktopMatches[1]);\n } catch {\n // it's not JSON so just use the string\n // note that a typo like \"falsy\" will be treated as true\n simulateScratchDesktop = scratchDesktopMatches[1];\n }\n }\n\n // window.onbeforeunload\n // 即将离开当前页面(刷新或关闭)时触发。\n // 该事件可用于弹出对话框,提示用户是继续浏览页面还是离开当前页面\n\n // 在node中,有全局变量process表示的是当前的node进程。process.env包含着关于系统环境的信息。但是process.env中并不存在NODE_ENV这个东西。NODE_ENV是用户一个自定义的变量,在webpack中它的用途是判断生产环境或开发环境的依据的。\n if (process.env.NODE_ENV === 'production' && typeof window === 'object') {\n // Warn before navigating away\n window.onbeforeunload = () => true;\n }\n\n ReactDOM.render(\n //这是一个检查是否是模拟桌面的变量,不仅仅只是定义。\n // important: this is checking whether `simulateScratchDesktop` is truthy, not just defined!\n simulateScratchDesktop ?\n :\n // 那么我就要走下面的这些东西\n ,\n //

你好啊

,\n appTarget);\n};\n","/* (ignored) */"],"mappings":";;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;ACVA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;ACnBA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEA;AACA;AACA;AACA;AAEA;AACA;AAEA;AAEA;AACA;AACA;AACA;AAEA;AACA;AACA;AACA;AAEA;AACA;AACA;AAAA;AAAA;AACA;AAAA;AACA;AACA;AAAA;AAAA;AAAA;AACA;;;;;;;;;;;;;;;;;;;;;;;;ACnCA;AACA;AACA;AAEA;AACA;AACA;AACA;AACA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEA;;;;;;;AAKA;AACA;AAGA;AACA;AACA;AACA;AAEA;AAFA;AAKA;AACA;AACA;AAAA;AACA;AACA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAGA;AACA;AAEA;AACA;AACA;AADA,eAGA;AACA;AACA;AAEA;AACA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AAPA;AAUA;AACA;AACA;AACA;AAHA;AAKA;AACA;AANA;AASA;AACA;;;;;;;;;;;AClGA;;;;A","sourceRoot":""}