From b130f0e1f4100c1797849e6003873eec36c194e5 Mon Sep 17 00:00:00 2001 From: autosubmit Date: Fri, 8 Dec 2023 16:12:05 +0800 Subject: [PATCH] Auto Submit --- 11436.async.js | 2 +- 15221.async.js | 4231 -------- 15221.chunk.css | 2626 ----- 65902.async.js => 24915.async.js | 909 +- 44894.async.js | 2 +- 47400.async.js | 2 +- 488.async.js | 9 +- 37188.async.js => 49845.async.js | 909 +- 11392.async.js => 63240.async.js | 909 +- 63510.async.js | 22 +- 66508.async.js | 238 +- 70043.async.js | 2 +- 71244.async.js | 22 +- 74237.async.js | 2 +- 76626.async.js | 22 +- 15267.async.js => 80310.async.js | 909 +- 89200.async.js | 20 +- 89493.async.js | 2 +- layouts__ShixunDetail__index.async.js | 44 +- layouts__SimpleLayouts.chunk.css | 2 +- layouts__index.async.js | 78 +- layouts__index.chunk.css | 2 +- layouts__user__index.async.js | 8 +- layouts__user__index.chunk.css | 2 +- ...assrooms__Lists__Assistant__index.async.js | 418 +- ...ssrooms__Lists__Attachment__index.async.js | 23 +- ...s__CommonHomework__Comment__index.async.js | 2 +- ...ts__CommonHomework__Detail__index.async.js | 96 +- ...oms__Lists__CommonHomework__index.async.js | 36 +- ...Lists__CourseGroup__Detail__index.async.js | 95 +- ...__Lists__CourseGroup__List__index.async.js | 4 +- ...ooms__Lists__Exercise__Add__index.async.js | 2 +- ...s__Lists__Exercise__Answer__index.async.js | 2 +- ...s__Lists__Exercise__Detail__index.async.js | 87 +- ...s__Exercise__ImitateAnswer__index.async.js | 2 +- ...s__Lists__Exercise__Review__index.async.js | 20 +- ...lassrooms__Lists__Exercise__index.async.js | 7 +- ...sts__GroupHomework__Detail__index.async.js | 62 +- ...ooms__Lists__GroupHomework__index.async.js | 16 +- ...__ProgramHomework__Comment__index.async.js | 2 +- ...s__ProgramHomework__Detail__index.async.js | 2 +- ...ms__Lists__ProgramHomework__index.async.js | 7 +- ...__ShixunHomeworks__Comment__index.async.js | 2 +- ...s__ShixunHomeworks__Detail__index.async.js | 48 +- ...ms__Lists__ShixunHomeworks__index.async.js | 40 +- ...lassrooms__Lists__Students__index.async.js | 61 +- ...lassrooms__Lists__Teachers__index.async.js | 38 +- p__Classrooms__Lists__Video__index.async.js | 6 - p__Classrooms__New__index.async.js | 174 +- p__Classrooms__New__index.chunk.css | 23 - p__Competitions__Detail__index.async.js | 2 +- p__Competitions__Edit__index.async.js | 22 +- p__Demo__index.async.js | 2 +- ...ering__Lists__CurseSetting__index.async.js | 2 +- ...gineering__Lists__Document__index.async.js | 2 +- ...ng__Lists__TrainingProgram__index.async.js | 2 +- p__Forums__Index__index.async.js | 4 +- p__Graduations__Lists__Topics__index.async.js | 22 +- p__Graduations__Review__index.async.js | 2 +- p__Innovation__Detail__index.async.js | 22 +- p__Innovation__Detail__index.chunk.css | 2 +- p__Innovation__Tasks__index.async.js | 20 +- p__Innovation__Tasks__index.chunk.css | 2 +- p__MyProblem__index.async.js | 2 +- p__Paperlibrary__Add__index.async.js | 2 +- p__Paperlibrary__Random__Edit__index.async.js | 4363 +++++++- ...aperlibrary__Random__Edit__index.chunk.css | 3358 +++++- ...om__ExchangeFromProblemSet__index.async.js | 9386 +---------------- ...m__ExchangeFromProblemSet__index.chunk.css | 1865 ---- p__Problemset__NewItem__index.async.js | 16 +- p__Problemset__index.async.js | 3619 ++++++- p__Problemset__index.chunk.css | 1557 ++- p__Question__OjProblem__index.async.js | 2 +- ...ns__Detail__Collaborators__index.chunk.css | 2 +- p__Shixuns__Detail__Discuss__index.async.js | 2 +- ...hixuns__Detail__Repository__index.async.js | 2 +- ...uns__Edit__body__Warehouse__index.async.js | 2 +- p__Shixuns__Edit__index.async.js | 22 +- p__Shixuns__Edit__index.chunk.css | 2 +- p__User__Detail__Classrooms__index.async.js | 1231 +-- p__User__Detail__Classrooms__index.chunk.css | 185 - p__User__Detail__TeachGroup__index.async.js | 20 - p__User__Login__index.async.js | 16 +- p__Video__Detail__id.async.js | 2 +- p__index.async.js | 330 +- p__index.chunk.css | 324 +- p__tasks__index.async.js | 155 +- p__tasks__index.chunk.css | 12 +- ...alSpaces__Lists__Knowledge__index.async.js | 22 +- ...paces__Lists__Plan__Detail__index.async.js | 2 +- ...__Lists__Resources__Detail__index.async.js | 2 +- ...ces__Lists__Survey__Detail__index.async.js | 2 +- umi.js | 1433 ++- 93 files changed, 16937 insertions(+), 23356 deletions(-) delete mode 100644 15221.async.js delete mode 100644 15221.chunk.css rename 65902.async.js => 24915.async.js (85%) rename 37188.async.js => 49845.async.js (68%) rename 11392.async.js => 63240.async.js (83%) rename 15267.async.js => 80310.async.js (81%) diff --git a/11436.async.js b/11436.async.js index 21abdc9820..9dc640cef6 100644 --- a/11436.async.js +++ b/11436.async.js @@ -306,7 +306,7 @@ var jsx_runtime = __webpack_require__(37712); }) : /*#__PURE__*/(0,jsx_runtime.jsxs)(es_button/* default */.ZP, { type: "primary", size: 'middle', - onClick: handleDown, + onClick: handleClick, children: [/*#__PURE__*/(0,jsx_runtime.jsx)(ArrowDownOutlined/* default */.Z, {}), "\u70B9\u51FB\u4E0B\u8F7D"] }) })] diff --git a/15221.async.js b/15221.async.js deleted file mode 100644 index 1b6f2f2dfa..0000000000 --- a/15221.async.js +++ /dev/null @@ -1,4231 +0,0 @@ -"use strict"; -(self["webpackChunk"] = self["webpackChunk"] || []).push([[15221,4977,11436,89200,59741],{ - -/***/ 80330: -/*!*********************************!*\ - !*** ./src/pages/tasks/util.js ***! - \*********************************/ -/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { - -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ Ax: function() { return /* binding */ processTreeData; }, -/* harmony export */ Ds: function() { return /* binding */ debounce; }, -/* harmony export */ KI: function() { return /* binding */ apiPref; }, -/* harmony export */ SI: function() { return /* binding */ getTreeData; }, -/* harmony export */ f1: function() { return /* binding */ isCompileOk; } -/* harmony export */ }); -/* unused harmony export isProd */ -/* harmony import */ var _utils_env__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @/utils/env */ 78130); - -function isCompileOk(rs) { - var flag = true; - if (rs.length > 0) { - for (var i = 0; i < rs.length; i++) { - if (rs[i].compile_success == 0 || !rs[i].compile_success) { - flag = false; - break; - } - } - } else { - flag = false; - } - return flag; -} -function getTreeData(data) { - var parentKey = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; - var result = []; - for (var i = 0; i < data.length; i++) { - var item = data[i]; - var key = parentKey ? "".concat(parentKey, "/").concat(item.name) : "".concat(item.name); - result.push({ - title: item.name, - isLeaf: item.type === 'tree' ? false : true, - key: key - }); - } - return result; -} -function processTreeData(repos, key, newData) { - for (var i = 0; i < repos.length; i++) { - var item = repos[i]; - if (item.key === key) { - item.children = newData; - break; - } - if (item.children) { - processTreeData(item.children, key, newData); - } - } - return repos; -} -function debounce(func, wait, immediate) { - var timeout; - return function () { - var context = this, - args = arguments; - var later = function later() { - timeout = null; - if (!immediate) func.apply(context, args); - }; - var callNow = immediate && !timeout; - clearTimeout(timeout); - timeout = setTimeout(later, wait); - if (callNow) func.apply(context, args); - }; -} -var isProd = true; -var apiPref = _utils_env__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z.API_SERVER; -// export const isProd = -// window.location.href.indexOf('test-') > 0 || -// window.location.href.indexOf('localhost') > 0 -// ? false -// : true; - -// export const apiPref = isProd -// ? 'https://www.educoder.net' -// : 'https://test-newweb.educoder.net'; - -/***/ }), - -/***/ 75816: -/*!**********************************************!*\ - !*** ./src/components/AsyncButton/index.tsx ***! - \**********************************************/ -/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { - -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ Z: function() { return /* binding */ AsyncButton; } -/* harmony export */ }); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectSpread2.js */ 26801); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/regeneratorRuntime.js */ 10574); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/asyncToGenerator.js */ 39343); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2__); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/slicedToArray.js */ 11006); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_3__); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectWithoutProperties.js */ 27161); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_4__); -/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! antd */ 3113); -/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react */ 59301); -/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! react/jsx-runtime */ 37712); - - - - - -var _excluded = ["children"]; - - - -var AsyncButton = function AsyncButton(_ref) { - var children = _ref.children, - props = _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_4___default()(_ref, _excluded); - var _useState = (0,react__WEBPACK_IMPORTED_MODULE_5__.useState)(false), - _useState2 = _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_3___default()(_useState, 2), - btnLoading = _useState2[0], - setBtnLoading = _useState2[1]; - return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__.jsx)(antd__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .ZP, _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({}, props), {}, { - loading: btnLoading, - onClick: /*#__PURE__*/function () { - var _ref2 = _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2___default()( /*#__PURE__*/_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1___default()().mark(function _callee(e) { - return _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1___default()().wrap(function _callee$(_context) { - while (1) switch (_context.prev = _context.next) { - case 0: - _context.prev = 0; - setBtnLoading(true); - _context.next = 4; - return props.onClick(e); - case 4: - setBtnLoading(false); - _context.next = 11; - break; - case 7: - _context.prev = 7; - _context.t0 = _context["catch"](0); - console.error(_context.t0); - setBtnLoading(false); - case 11: - case "end": - return _context.stop(); - } - }, _callee, null, [[0, 7]]); - })); - return function (_x) { - return _ref2.apply(this, arguments); - }; - }(), - children: children - })); -}; - -/***/ }), - -/***/ 73208: -/*!*****************************************!*\ - !*** ./src/components/NoData/index.tsx ***! - \*****************************************/ -/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { - -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectSpread2.js */ 26801); -/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react */ 59301); -/* harmony import */ var _assets_images_icons_nodata_png__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @/assets/images/icons/nodata.png */ 93314); -/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! antd */ 3113); -/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! react/jsx-runtime */ 37712); - - - - - - -var noData = function noData(_ref) { - var img = _ref.img, - _ref$buttonProps = _ref.buttonProps, - buttonProps = _ref$buttonProps === void 0 ? {} : _ref$buttonProps, - _ref$styles = _ref.styles, - styles = _ref$styles === void 0 ? {} : _ref$styles, - customText = _ref.customText, - ButtonText = _ref.ButtonText, - ButtonClick = _ref.ButtonClick, - Buttonclass = _ref.Buttonclass, - ButtonTwo = _ref.ButtonTwo, - imgStyles = _ref.imgStyles, - _ref$loading = _ref.loading, - loading = _ref$loading === void 0 ? false : _ref$loading; - return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsxs)("section", { - className: "tc animated fadeIn", - style: _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({}, { - color: '#999', - margin: '100px auto', - visibility: loading ? 'hidden' : 'visible' - }), styles), - children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)("img", { - src: img || _assets_images_icons_nodata_png__WEBPACK_IMPORTED_MODULE_2__, - style: _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({}, imgStyles) - }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)("p", { - className: "mt20 font14", - children: customText || '暂时还没有相关数据哦!' - }), ButtonText && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)(antd__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .ZP, _root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()(_root_workspace_ppte5yg23_local_v9_test1_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({ - className: Buttonclass, - onClick: ButtonClick - }, buttonProps), {}, { - children: ButtonText - })), ButtonTwo && ButtonTwo] - }); -}; -/* harmony default export */ __webpack_exports__.Z = (noData); - -/***/ }), - -/***/ 19480: -/*!*********************************************************!*\ - !*** ./src/components/PreviewAll/index.tsx + 1 modules ***! - \*********************************************************/ -/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { - - -// EXPORTS -__webpack_require__.d(__webpack_exports__, { - Z: function() { return /* binding */ PreviewAll; } -}); - -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectSpread2.js -var objectSpread2 = __webpack_require__(26801); -var objectSpread2_default = /*#__PURE__*/__webpack_require__.n(objectSpread2); -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/regeneratorRuntime.js -var regeneratorRuntime = __webpack_require__(10574); -var regeneratorRuntime_default = /*#__PURE__*/__webpack_require__.n(regeneratorRuntime); -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/asyncToGenerator.js -var asyncToGenerator = __webpack_require__(39343); -var asyncToGenerator_default = /*#__PURE__*/__webpack_require__.n(asyncToGenerator); -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/slicedToArray.js -var slicedToArray = __webpack_require__(11006); -var slicedToArray_default = /*#__PURE__*/__webpack_require__.n(slicedToArray); -// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/index.js -var _react_17_0_2_react = __webpack_require__(59301); -;// CONCATENATED MODULE: ./src/components/PreviewAll/index.less?modules -// extracted by mini-css-extract-plugin -/* harmony default export */ var PreviewAllmodules = ({"wrp":"wrp___dq7YK","bgBlack":"bgBlack___ARIUV","monaco":"monaco___VnZC3","darkBlue":"darkBlue___UprA9","close":"close___LKoWu","embed":"embed___hvpEJ"}); -// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/button/index.js -var es_button = __webpack_require__(3113); -// EXTERNAL MODULE: ./node_modules/_@ant-design_icons@5.2.6@@ant-design/icons/es/icons/ArrowDownOutlined.js + 1 modules -var ArrowDownOutlined = __webpack_require__(98915); -// EXTERNAL MODULE: ./src/components/monaco-editor/index.jsx + 3 modules -var monaco_editor = __webpack_require__(76329); -// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/tooltip/index.js + 3 modules -var tooltip = __webpack_require__(6848); -// EXTERNAL MODULE: ./src/utils/util.tsx -var util = __webpack_require__(22739); -// EXTERNAL MODULE: ./src/service/exercise.ts -var exercise = __webpack_require__(35367); -// EXTERNAL MODULE: ./src/components/NoData/index.tsx -var NoData = __webpack_require__(73208); -// EXTERNAL MODULE: ./src/utils/env.ts + 1 modules -var env = __webpack_require__(78130); -// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/jsx-runtime.js -var jsx_runtime = __webpack_require__(37712); -;// CONCATENATED MODULE: ./src/components/PreviewAll/index.tsx - - - - - - - - - - - - - - - - - -/* harmony default export */ var PreviewAll = (function (_ref) { - var _data, _data2, _data3, _data4, _data5, _data6, _data7; - var _ref$editOffice = _ref.editOffice, - editOffice = _ref$editOffice === void 0 ? 'view' : _ref$editOffice, - data = _ref.data, - theme = _ref.theme, - type = _ref.type, - filename = _ref.filename, - monacoEditor = _ref.monacoEditor, - className = _ref.className, - style = _ref.style, - close = _ref.close, - onClose = _ref.onClose, - hasMask = _ref.hasMask, - disabledDownload = _ref.disabledDownload, - onImgDimensions = _ref.onImgDimensions, - showNodata = _ref.showNodata; - var _useState = (0,_react_17_0_2_react.useState)('https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt'), - _useState2 = slicedToArray_default()(_useState, 2), - src = _useState2[0], - setSrc = _useState2[1]; - var _useState3 = (0,_react_17_0_2_react.useState)(""), - _useState4 = slicedToArray_default()(_useState3, 2), - token = _useState4[0], - setToken = _useState4[1]; - var _useState5 = (0,_react_17_0_2_react.useState)(), - _useState6 = slicedToArray_default()(_useState5, 2), - officeData = _useState6[0], - setOfficeData = _useState6[1]; - var officePath = window.ENV === "build" ? "/react/build" : ""; - var apiServer = location.host.startsWith("localhost") ? env/* default */.Z.PROXY_SERVER : env/* default */.Z.API_SERVER; - // let size; - console.log("disabledDownload---", disabledDownload); - var unit = 1024 * 1024; - var maxSize = 10 * unit; - var closeRef = (0,_react_17_0_2_react.useRef)(); - if ((_data = data) !== null && _data !== void 0 && _data.startsWith("/api") && type !== "txt") { - data = env/* default */.Z.API_SERVER + data; - } - // if (type === "office") { - // size = parseUrl(data).filesize - // if (size > maxSize) { - // type = "other" - // } - // } - if (filename) monacoEditor.filename = filename; - (0,_react_17_0_2_react.useEffect)(function () { - var _document$cookie; - var cookies = (_document$cookie = document.cookie) === null || _document$cookie === void 0 || (_document$cookie = _document$cookie.replace(/\s/g, "")) === null || _document$cookie === void 0 ? void 0 : _document$cookie.split(";"); - cookies === null || cookies === void 0 || cookies.map(function (item) { - var i = item.split("="); - if (i[0] === '_educoder_session') { - setToken(i[1]); - } - }); - }, []); - (0,_react_17_0_2_react.useEffect)(function () { - if (type === "office") getData(); - }, [type, data]); - var getData = /*#__PURE__*/function () { - var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee() { - var _url, _id, res; - return regeneratorRuntime_default()().wrap(function _callee$(_context) { - while (1) switch (_context.prev = _context.next) { - case 0: - console.log("data:", data); - _url = data; - if (!data.startsWith("http")) { - _url = location.origin + _url; - } - _id = new URL(_url).pathname.split("/").pop(); - _context.next = 6; - return (0,exercise/* setEcsAttachment */.gJ)({ - attachment_id: _id - }); - case 6: - res = _context.sent; - setOfficeData(res); - case 8: - case "end": - return _context.stop(); - } - }, _callee); - })); - return function getData() { - return _ref2.apply(this, arguments); - }; - }(); - var handleClick = function handleClick() { - if (data.startsWith("http") || data.startsWith('blob:')) { - handleDown(); - return; - } - (0,util/* downloadFile */.Sv)(filename || 'educoder', data, filename); - }; - var handleDown = function handleDown() { - (0,util/* downLoadLink */.Nd)(filename || 'educoder', decodeURIComponent(data)); - }; - console.log(data, 'data'); - return /*#__PURE__*/(0,jsx_runtime.jsxs)("div", { - style: objectSpread2_default()({}, style || {}), - className: "".concat(hasMask && PreviewAllmodules.bgBlack, " ").concat(!!type ? PreviewAllmodules.wrp : "hide"), - children: [close && /*#__PURE__*/(0,jsx_runtime.jsxs)("div", { - className: PreviewAllmodules.close, - ref: closeRef, - children: [!!onImgDimensions && /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, { - title: "\u70B9\u51FB\u5BF9\u56FE\u7247\u8FDB\u884C\u6279\u6CE8", - getPopupContainer: function getPopupContainer() { - return closeRef.current; - }, - children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", { - onClick: function onClick() { - onClose(); - onImgDimensions(); - }, - children: /*#__PURE__*/(0,jsx_runtime.jsx)("i", { - className: "icon-yulanpizhu" - }) - }) - }), !disabledDownload && /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, { - title: "\u70B9\u51FB\u4E0B\u8F7D\u6B64\u6587\u4EF6", - getPopupContainer: function getPopupContainer() { - return closeRef.current; - }, - children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", { - onClick: handleDown, - children: /*#__PURE__*/(0,jsx_runtime.jsx)("i", { - className: "icon-quxiaozhiding" - }) - }) - }), /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, { - title: "\u5173\u95ED", - getPopupContainer: function getPopupContainer() { - return closeRef.current; - }, - children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", { - className: "", - onClick: onClose, - children: /*#__PURE__*/(0,jsx_runtime.jsx)("i", { - className: "icon-guanbi1" - }) - }) - })] - }), /*#__PURE__*/(0,jsx_runtime.jsx)("div", { - className: "".concat(PreviewAllmodules[className], " ").concat(className, " ").concat(PreviewAllmodules.monaco, " ").concat(type === "txt" ? "show" : "hide"), - children: type === "txt" && /*#__PURE__*/(0,jsx_runtime.jsx)(monaco_editor/* default */.ZP, objectSpread2_default()({}, monacoEditor)) - }), type === "audio" && /*#__PURE__*/(0,jsx_runtime.jsx)("audio", { - src: ((_data2 = data) === null || _data2 === void 0 ? void 0 : _data2.indexOf("http")) > -1 || (_data3 = data) !== null && _data3 !== void 0 && _data3.startsWith("/api") ? data : "data:image/png;base64,".concat(data), - autoPlay: true - }), type === "video" && /*#__PURE__*/(0,jsx_runtime.jsx)(jsx_runtime.Fragment, { - children: ((_data4 = data) === null || _data4 === void 0 ? void 0 : _data4.indexOf("http")) > -1 || (_data5 = data) !== null && _data5 !== void 0 && _data5.startsWith("/api") ? /*#__PURE__*/(0,jsx_runtime.jsx)("video", { - controls: true, - src: "".concat(data), - autoPlay: true - }) : /*#__PURE__*/(0,jsx_runtime.jsx)("video", { - controls: true, - src: "data:video/mp4;base64,".concat(data), - autoPlay: true - }) - }), type === 'office' && officeData && /*#__PURE__*/(0,jsx_runtime.jsx)("iframe", { - src: "".concat(officePath, "/office.html?key=").concat(officeData.key, "&url=").concat(apiServer + officeData.url, "&callbackUrl=").concat(apiServer + officeData.callbackUrl, "&fileType=").concat(officeData.fileType, "&title=").concat(officeData.title, "&model=").concat(editOffice, "&officeServer=").concat(env/* default */.Z.ONLYOFFICE, "&disabledDownload=").concat(!!disabledDownload) - }), type === 'html' && /*#__PURE__*/(0,jsx_runtime.jsx)("iframe", { - src: data + '&disposition=inline' - }), type === 'pdf' && /*#__PURE__*/(0,jsx_runtime.jsx)("iframe", { - src: "".concat(officePath, "/js/pdfview/index.html?url=").concat(data, "&disabledDownload=").concat(!!disabledDownload) - }) // - , type === "image" && /*#__PURE__*/(0,jsx_runtime.jsx)("img", { - src: ((_data6 = data) === null || _data6 === void 0 ? void 0 : _data6.indexOf("http")) > -1 || (_data7 = data) !== null && _data7 !== void 0 && _data7.startsWith("/api") ? data : "data:image/png;base64,".concat(data) - }), (type === "other" || type === "download") && /*#__PURE__*/(0,jsx_runtime.jsx)(jsx_runtime.Fragment, { - children: showNodata ? /*#__PURE__*/(0,jsx_runtime.jsx)(NoData/* default */.Z, { - customText: "\u5F53\u524D\u6587\u4EF6\u4E0D\u652F\u6301\u9884\u89C8\uFF0C\u53EF\u70B9\u51FB\u4E0B\u8F7D\u67E5\u770B", - ButtonTwo: /*#__PURE__*/(0,jsx_runtime.jsx)(es_button/* default */.ZP, { - icon: /*#__PURE__*/(0,jsx_runtime.jsx)("i", { - className: "iconfont icon-xiazai4 font14" - }), - type: "primary", - size: 'middle', - onClick: handleClick, - children: "\u4E0B\u8F7D" - }) - }) : /*#__PURE__*/(0,jsx_runtime.jsxs)(es_button/* default */.ZP, { - type: "primary", - size: 'middle', - onClick: handleDown, - children: [/*#__PURE__*/(0,jsx_runtime.jsx)(ArrowDownOutlined/* default */.Z, {}), "\u70B9\u51FB\u4E0B\u8F7D"] - }) - })] - }); -}); - -/***/ }), - -/***/ 11436: -/*!*********************************************************!*\ - !*** ./src/components/RenderHtml/index.tsx + 1 modules ***! - \*********************************************************/ -/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { - - -// EXPORTS -__webpack_require__.d(__webpack_exports__, { - Z: function() { return /* binding */ RenderHtml; } -}); - -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectSpread2.js -var objectSpread2 = __webpack_require__(26801); -var objectSpread2_default = /*#__PURE__*/__webpack_require__.n(objectSpread2); -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/toConsumableArray.js -var toConsumableArray = __webpack_require__(93923); -var toConsumableArray_default = /*#__PURE__*/__webpack_require__.n(toConsumableArray); -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/createForOfIteratorHelper.js -var createForOfIteratorHelper = __webpack_require__(98190); -var createForOfIteratorHelper_default = /*#__PURE__*/__webpack_require__.n(createForOfIteratorHelper); -// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/slicedToArray.js -var slicedToArray = __webpack_require__(11006); -var slicedToArray_default = /*#__PURE__*/__webpack_require__.n(slicedToArray); -// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/index.js -var _react_17_0_2_react = __webpack_require__(59301); -// EXTERNAL MODULE: ./node_modules/_katex@0.11.1@katex/dist/katex.min.css -var katex_min = __webpack_require__(16622); -// EXTERNAL MODULE: ./node_modules/_marked@2.0.7@marked/lib/marked.js -var marked = __webpack_require__(32834); -var marked_default = /*#__PURE__*/__webpack_require__.n(marked); -// EXTERNAL MODULE: ./node_modules/_marked@2.0.7@marked/src/helpers.js -var helpers = __webpack_require__(11690); -;// CONCATENATED MODULE: ./src/utils/marked.ts - - - -function indentCodeCompensation(raw, text) { - var matchIndentToCode = raw.match(/^(\s+)(?:```)/); - if (matchIndentToCode === null) { - return text; - } - var indentToCode = matchIndentToCode[1]; - return text.split('\n').map(function (node) { - var matchIndentInNode = node.match(/^\s+/); - if (matchIndentInNode === null) { - return node; - } - var _matchIndentInNode = slicedToArray_default()(matchIndentInNode, 1), - indentInNode = _matchIndentInNode[0]; - if (indentInNode.length >= indentToCode.length) { - return node.slice(indentToCode.length); - } - return node; - }).join('\n'); -} -//兼容之前的 ##标题式写法 -var toc = []; -var ctx = ["