You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
841 lines
36 KiB
841 lines
36 KiB
"use strict";
|
|
(self["webpackChunk"] = self["webpackChunk"] || []).push([[27200],{
|
|
|
|
/***/ 30055:
|
|
/*!**********************************************!*\
|
|
!*** ./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_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/objectSpread2.js */ 82242);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/regeneratorRuntime.js */ 7557);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/asyncToGenerator.js */ 41498);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/slicedToArray.js */ 79800);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/objectWithoutProperties.js */ 39647);
|
|
/* harmony import */ var _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_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_test4_node_modules_babel_runtime_7_23_6_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_test4_node_modules_babel_runtime_7_23_6_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_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()(_root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({}, props), {}, {
|
|
loading: btnLoading,
|
|
onClick: ( /*#__PURE__*/function () {
|
|
var _ref2 = _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_2___default()( /*#__PURE__*/_root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_1___default()().mark(function _callee(e) {
|
|
return _root_workspace_ppte5yg23_local_v9_test4_node_modules_babel_runtime_7_23_6_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
|
|
}));
|
|
};
|
|
|
|
/***/ }),
|
|
|
|
/***/ 99374:
|
|
/*!*****************************************************************************!*\
|
|
!*** ./src/pages/Shixuns/Edit/body/Environment/Label/index.tsx + 1 modules ***!
|
|
\*****************************************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
// EXPORTS
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
Z: function() { return /* binding */ Environment_Label; }
|
|
});
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/index.js
|
|
var _react_17_0_2_react = __webpack_require__(59301);
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Edit/body/Environment/Label/index.less?modules
|
|
// extracted by mini-css-extract-plugin
|
|
/* harmony default export */ var Labelmodules = ({"label":"label___CZ1_z","left":"left___ZKFRV","right":"right___zVTRn","error":"error___oNJNo"});
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/tooltip/index.js + 3 modules
|
|
var tooltip = __webpack_require__(6848);
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/jsx-runtime.js
|
|
var jsx_runtime = __webpack_require__(37712);
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Edit/body/Environment/Label/index.tsx
|
|
|
|
|
|
|
|
|
|
|
|
var Label = function Label(_ref) {
|
|
var name = _ref.name,
|
|
tooltipTitle = _ref.tooltipTitle,
|
|
children = _ref.children,
|
|
required = _ref.required,
|
|
errorKey = _ref.errorKey,
|
|
errorValue = _ref.errorValue,
|
|
errorName = _ref.errorName,
|
|
_ref$errorStyle = _ref.errorStyle,
|
|
errorStyle = _ref$errorStyle === void 0 ? {} : _ref$errorStyle,
|
|
_ref$nameWidth = _ref.nameWidth,
|
|
nameWidth = _ref$nameWidth === void 0 ? 112 : _ref$nameWidth,
|
|
_ref$align = _ref.align,
|
|
align = _ref$align === void 0 ? 'center' : _ref$align,
|
|
_ref$contentStyle = _ref.contentStyle,
|
|
contentStyle = _ref$contentStyle === void 0 ? {} : _ref$contentStyle;
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(_react_17_0_2_react.Fragment, {
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
className: Labelmodules.label,
|
|
style: {
|
|
alignItems: align
|
|
},
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
className: Labelmodules.left,
|
|
style: {
|
|
width: nameWidth
|
|
},
|
|
children: [required && /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
children: "*"
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
children: name
|
|
}), !!tooltipTitle && /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
title: tooltipTitle,
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("i", {
|
|
className: "iconfont icon-xiaowenhao2"
|
|
})
|
|
})]
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
className: Labelmodules.right,
|
|
style: contentStyle,
|
|
children: [children, errorName && errorValue === errorKey && /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
className: Labelmodules.error,
|
|
style: errorStyle,
|
|
children: errorName
|
|
})]
|
|
})]
|
|
})
|
|
});
|
|
};
|
|
/* harmony default export */ var Environment_Label = (Label);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 24220:
|
|
/*!************************************************************************************************!*\
|
|
!*** ./src/pages/User/Detail/ExperImentImg/components/ModifyMirrorModal/index.tsx + 1 modules ***!
|
|
\************************************************************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
// EXPORTS
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
Z: function() { return /* binding */ components_ModifyMirrorModal; }
|
|
});
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/regeneratorRuntime.js
|
|
var regeneratorRuntime = __webpack_require__(7557);
|
|
var regeneratorRuntime_default = /*#__PURE__*/__webpack_require__.n(regeneratorRuntime);
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/objectSpread2.js
|
|
var objectSpread2 = __webpack_require__(82242);
|
|
var objectSpread2_default = /*#__PURE__*/__webpack_require__.n(objectSpread2);
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/asyncToGenerator.js
|
|
var asyncToGenerator = __webpack_require__(41498);
|
|
var asyncToGenerator_default = /*#__PURE__*/__webpack_require__.n(asyncToGenerator);
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.6@@babel/runtime/helpers/slicedToArray.js
|
|
var slicedToArray = __webpack_require__(79800);
|
|
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/_antd@5.9.0@antd/es/form/index.js + 19 modules
|
|
var es_form = __webpack_require__(78241);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/message/index.js + 4 modules
|
|
var message = __webpack_require__(8591);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/modal/index.js + 16 modules
|
|
var modal = __webpack_require__(43418);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/input/index.js + 5 modules
|
|
var input = __webpack_require__(10249);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/button/index.js
|
|
var es_button = __webpack_require__(3113);
|
|
// EXTERNAL MODULE: ./src/utils/fetch.ts
|
|
var fetch = __webpack_require__(1833);
|
|
// EXTERNAL MODULE: ./src/components/markdown-editor/index.tsx + 10 modules
|
|
var markdown_editor = __webpack_require__(47043);
|
|
;// CONCATENATED MODULE: ./src/pages/User/Detail/ExperImentImg/components/ModifyMirrorModal/index.less?modules
|
|
// extracted by mini-css-extract-plugin
|
|
/* harmony default export */ var ModifyMirrorModalmodules = ({"errorTip":"errorTip___yZItq","btns":"btns___kcUDL","confirm":"confirm___EXVbh","cancel":"cancel___vQdUc","formWrap":"formWrap___diWab"});
|
|
// EXTERNAL MODULE: ./src/components/AsyncButton/index.tsx
|
|
var AsyncButton = __webpack_require__(30055);
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/jsx-runtime.js
|
|
var jsx_runtime = __webpack_require__(37712);
|
|
;// CONCATENATED MODULE: ./src/pages/User/Detail/ExperImentImg/components/ModifyMirrorModal/index.tsx
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var ModifyMirrorModal = function ModifyMirrorModal(_ref) {
|
|
var visible = _ref.visible,
|
|
mirrorId = _ref.mirrorId,
|
|
setVisible = _ref.setVisible,
|
|
getData = _ref.getData;
|
|
var _Form$useForm = es_form/* default */.Z.useForm(),
|
|
_Form$useForm2 = slicedToArray_default()(_Form$useForm, 1),
|
|
form = _Form$useForm2[0];
|
|
var _useState = (0,_react_17_0_2_react.useState)({}),
|
|
_useState2 = slicedToArray_default()(_useState, 2),
|
|
formValue = _useState2[0],
|
|
setFormValue = _useState2[1];
|
|
var _useState3 = (0,_react_17_0_2_react.useState)(''),
|
|
_useState4 = slicedToArray_default()(_useState3, 2),
|
|
errorMsg = _useState4[0],
|
|
setErrorMsg = _useState4[1];
|
|
var _useState5 = (0,_react_17_0_2_react.useState)(false),
|
|
_useState6 = slicedToArray_default()(_useState5, 2),
|
|
btnLoading = _useState6[0],
|
|
setBtnLoading = _useState6[1];
|
|
(0,_react_17_0_2_react.useEffect)(function () {
|
|
if (mirrorId != undefined && visible) {
|
|
getMirrorInfo();
|
|
}
|
|
}, [mirrorId, visible]);
|
|
var getMirrorInfo = /*#__PURE__*/function () {
|
|
var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee() {
|
|
var res;
|
|
return regeneratorRuntime_default()().wrap(function _callee$(_context) {
|
|
while (1) switch (_context.prev = _context.next) {
|
|
case 0:
|
|
_context.next = 2;
|
|
return (0,fetch/* default */.ZP)("/api/user_mirrors/".concat(mirrorId, ".json"), {
|
|
method: 'get'
|
|
});
|
|
case 2:
|
|
res = _context.sent;
|
|
if ((res === null || res === void 0 ? void 0 : res.status) === 0) {
|
|
form.setFieldsValue(objectSpread2_default()({}, res === null || res === void 0 ? void 0 : res.data));
|
|
setFormValue(objectSpread2_default()({}, res === null || res === void 0 ? void 0 : res.data));
|
|
}
|
|
case 4:
|
|
case "end":
|
|
return _context.stop();
|
|
}
|
|
}, _callee);
|
|
}));
|
|
return function getMirrorInfo() {
|
|
return _ref2.apply(this, arguments);
|
|
};
|
|
}();
|
|
var onCancel = function onCancel() {
|
|
setVisible(false);
|
|
setFormValue({});
|
|
form.setFieldsValue({});
|
|
};
|
|
var onOk = /*#__PURE__*/function () {
|
|
var _ref3 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee2() {
|
|
var formValue, res;
|
|
return regeneratorRuntime_default()().wrap(function _callee2$(_context2) {
|
|
while (1) switch (_context2.prev = _context2.next) {
|
|
case 0:
|
|
setBtnLoading(true);
|
|
_context2.t0 = (objectSpread2_default());
|
|
_context2.t1 = {};
|
|
_context2.next = 5;
|
|
return form.validateFields();
|
|
case 5:
|
|
_context2.t2 = _context2.sent;
|
|
formValue = (0, _context2.t0)(_context2.t1, _context2.t2);
|
|
_context2.next = 9;
|
|
return (0,fetch/* default */.ZP)("/api/user_mirrors/".concat(mirrorId, ".json"), {
|
|
method: 'put',
|
|
body: {
|
|
type_name: formValue === null || formValue === void 0 ? void 0 : formValue.type_name,
|
|
description: formValue === null || formValue === void 0 ? void 0 : formValue.description
|
|
}
|
|
});
|
|
case 9:
|
|
res = _context2.sent;
|
|
if (res.status === 0) {
|
|
message/* default */.ZP.success('修改成功');
|
|
getData();
|
|
}
|
|
setBtnLoading(false);
|
|
setVisible(false);
|
|
case 13:
|
|
case "end":
|
|
return _context2.stop();
|
|
}
|
|
}, _callee2);
|
|
}));
|
|
return function onOk() {
|
|
return _ref3.apply(this, arguments);
|
|
};
|
|
}();
|
|
var checkMirrornameExist = /*#__PURE__*/function () {
|
|
var _ref4 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee3(value) {
|
|
var res;
|
|
return regeneratorRuntime_default()().wrap(function _callee3$(_context3) {
|
|
while (1) switch (_context3.prev = _context3.next) {
|
|
case 0:
|
|
_context3.next = 2;
|
|
return (0,fetch/* default */.ZP)("/api/user_mirrors/check_mirror_name.json", {
|
|
method: 'post',
|
|
body: {
|
|
type_name: value,
|
|
id: mirrorId
|
|
}
|
|
});
|
|
case 2:
|
|
res = _context3.sent;
|
|
if (!((res === null || res === void 0 ? void 0 : res.status) === 0)) {
|
|
_context3.next = 7;
|
|
break;
|
|
}
|
|
return _context3.abrupt("return", {
|
|
state: false
|
|
});
|
|
case 7:
|
|
return _context3.abrupt("return", {
|
|
state: true,
|
|
msg: res === null || res === void 0 ? void 0 : res.message
|
|
});
|
|
case 8:
|
|
case "end":
|
|
return _context3.stop();
|
|
}
|
|
}, _callee3);
|
|
}));
|
|
return function checkMirrornameExist(_x) {
|
|
return _ref4.apply(this, arguments);
|
|
};
|
|
}();
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)(modal/* default */.Z, {
|
|
centered: true,
|
|
width: 1200,
|
|
title: "\u4FEE\u6539\u955C\u50CF\u4FE1\u606F",
|
|
maskClosable: false,
|
|
open: visible,
|
|
destroyOnClose: true,
|
|
footer: null,
|
|
onCancel: onCancel,
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)(es_form/* default */.Z, {
|
|
style: {
|
|
marginTop: 20
|
|
},
|
|
form: form,
|
|
scrollToFirstError: true,
|
|
layout: "horizontal",
|
|
className: ModifyMirrorModalmodules.formWrap,
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default */.Z.Item, {
|
|
label: "\u955C\u50CF\u540D\u79F0",
|
|
name: "type_name",
|
|
colon: false,
|
|
className: ModifyMirrorModalmodules.errorTip,
|
|
rules: [{
|
|
required: true,
|
|
message: ''
|
|
},
|
|
// { required: true,message: '镜像名称不能为空'},
|
|
// { max: 60, message: '最多输入60个字符' },
|
|
// { pattern: /^[a-zA-Z][a-zA-Z0-9#+.\-/_:]*$/, message: '只能以字母开头,仅支持字母、数字和特殊字符#+.-/_:' },
|
|
{
|
|
validator: function () {
|
|
var _validator = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee4(rule, value) {
|
|
var res;
|
|
return regeneratorRuntime_default()().wrap(function _callee4$(_context4) {
|
|
while (1) switch (_context4.prev = _context4.next) {
|
|
case 0:
|
|
_context4.next = 2;
|
|
return checkMirrornameExist(value);
|
|
case 2:
|
|
res = _context4.sent;
|
|
return _context4.abrupt("return", (res === null || res === void 0 ? void 0 : res.state) === true ? Promise.reject(res === null || res === void 0 ? void 0 : res.msg) : Promise.resolve());
|
|
case 4:
|
|
case "end":
|
|
return _context4.stop();
|
|
}
|
|
}, _callee4);
|
|
}));
|
|
function validator(_x2, _x3) {
|
|
return _validator.apply(this, arguments);
|
|
}
|
|
return validator;
|
|
}()
|
|
}],
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(input/* default */.Z, {
|
|
size: "large",
|
|
maxLength: 60,
|
|
placeholder: "\u8BF7\u8F93\u5165\u955C\u50CF\u540D\u79F0"
|
|
})
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default */.Z.Item, {
|
|
label: "\u955C\u50CF\u63CF\u8FF0",
|
|
name: "description",
|
|
colon: false,
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(markdown_editor/* default */.Z, {
|
|
watch: true,
|
|
height: 300,
|
|
placeholder: '',
|
|
defaultValue: formValue === null || formValue === void 0 ? void 0 : formValue.description,
|
|
onChange: function onChange(value) {
|
|
form.setFieldsValue(objectSpread2_default()(objectSpread2_default()({}, form.getFieldsValue()), {}, {
|
|
description: value
|
|
}));
|
|
setFormValue(objectSpread2_default()(objectSpread2_default()({}, formValue), {}, {
|
|
description: value
|
|
}));
|
|
},
|
|
onBlur: function onBlur(value) {
|
|
form.setFieldsValue(objectSpread2_default()(objectSpread2_default()({}, form.getFieldsValue()), {}, {
|
|
description: value
|
|
}));
|
|
setFormValue(objectSpread2_default()(objectSpread2_default()({}, formValue), {}, {
|
|
description: value
|
|
}));
|
|
}
|
|
})
|
|
})]
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
className: ModifyMirrorModalmodules.btns,
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(es_button/* default */.ZP, {
|
|
onClick: onCancel,
|
|
className: ModifyMirrorModalmodules.cancel,
|
|
children: "\u53D6\u6D88 "
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(AsyncButton/* AsyncButton */.Z, {
|
|
type: "primary",
|
|
className: ModifyMirrorModalmodules.confirm,
|
|
onClick: /*#__PURE__*/asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee5() {
|
|
return regeneratorRuntime_default()().wrap(function _callee5$(_context5) {
|
|
while (1) switch (_context5.prev = _context5.next) {
|
|
case 0:
|
|
_context5.next = 2;
|
|
return onOk();
|
|
case 2:
|
|
case "end":
|
|
return _context5.stop();
|
|
}
|
|
}, _callee5);
|
|
})),
|
|
children: "\u786E\u5B9A"
|
|
})]
|
|
})]
|
|
});
|
|
};
|
|
/* harmony default export */ var components_ModifyMirrorModal = (ModifyMirrorModal);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 90547:
|
|
/*!*********************************************!*\
|
|
!*** ./src/pages/tasks/vnc-view/index.less ***!
|
|
\*********************************************/
|
|
/***/ (function() {
|
|
|
|
// extracted by mini-css-extract-plugin
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 77578:
|
|
/*!**********************************************************************!*\
|
|
!*** ./node_modules/_antd@5.9.0@antd/es/_util/getRenderPropValue.js ***!
|
|
\**********************************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ Z: function() { return /* binding */ getRenderPropValue; }
|
|
/* harmony export */ });
|
|
const getRenderPropValue = propValue => {
|
|
if (!propValue) {
|
|
return null;
|
|
}
|
|
if (typeof propValue === 'function') {
|
|
return propValue();
|
|
}
|
|
return propValue;
|
|
};
|
|
|
|
/***/ }),
|
|
|
|
/***/ 39722:
|
|
/*!***************************************************************!*\
|
|
!*** ./node_modules/_antd@5.9.0@antd/es/popover/PurePanel.js ***!
|
|
\***************************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ t5: function() { return /* binding */ RawPurePanel; }
|
|
/* harmony export */ });
|
|
/* unused harmony export getOverlay */
|
|
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! classnames */ 92310);
|
|
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(classnames__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var rc_tooltip__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! rc-tooltip */ 55477);
|
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react */ 59301);
|
|
/* harmony import */ var _config_provider__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../config-provider */ 36355);
|
|
/* harmony import */ var _util_getRenderPropValue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../_util/getRenderPropValue */ 77578);
|
|
/* harmony import */ var _style__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./style */ 17356);
|
|
"use client";
|
|
|
|
var __rest = undefined && undefined.__rest || function (s, e) {
|
|
var t = {};
|
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
}
|
|
return t;
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const getOverlay = (prefixCls, title, content) => {
|
|
if (!title && !content) return undefined;
|
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2__.createElement(react__WEBPACK_IMPORTED_MODULE_2__.Fragment, null, title && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2__.createElement("div", {
|
|
className: `${prefixCls}-title`
|
|
}, (0,_util_getRenderPropValue__WEBPACK_IMPORTED_MODULE_3__/* .getRenderPropValue */ .Z)(title)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2__.createElement("div", {
|
|
className: `${prefixCls}-inner-content`
|
|
}, (0,_util_getRenderPropValue__WEBPACK_IMPORTED_MODULE_3__/* .getRenderPropValue */ .Z)(content)));
|
|
};
|
|
const RawPurePanel = props => {
|
|
const {
|
|
hashId,
|
|
prefixCls,
|
|
className,
|
|
style,
|
|
placement = 'top',
|
|
title,
|
|
content,
|
|
children
|
|
} = props;
|
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2__.createElement("div", {
|
|
className: classnames__WEBPACK_IMPORTED_MODULE_0___default()(hashId, prefixCls, `${prefixCls}-pure`, `${prefixCls}-placement-${placement}`, className),
|
|
style: style
|
|
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2__.createElement("div", {
|
|
className: `${prefixCls}-arrow`
|
|
}), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2__.createElement(rc_tooltip__WEBPACK_IMPORTED_MODULE_1__/* .Popup */ .G, Object.assign({}, props, {
|
|
className: hashId,
|
|
prefixCls: prefixCls
|
|
}), children || getOverlay(prefixCls, title, content)));
|
|
};
|
|
const PurePanel = props => {
|
|
const {
|
|
prefixCls: customizePrefixCls
|
|
} = props,
|
|
restProps = __rest(props, ["prefixCls"]);
|
|
const {
|
|
getPrefixCls
|
|
} = react__WEBPACK_IMPORTED_MODULE_2__.useContext(_config_provider__WEBPACK_IMPORTED_MODULE_4__/* .ConfigContext */ .E_);
|
|
const prefixCls = getPrefixCls('popover', customizePrefixCls);
|
|
const [wrapSSR, hashId] = (0,_style__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)(prefixCls);
|
|
return wrapSSR( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2__.createElement(RawPurePanel, Object.assign({}, restProps, {
|
|
prefixCls: prefixCls,
|
|
hashId: hashId
|
|
})));
|
|
};
|
|
/* harmony default export */ __webpack_exports__.ZP = (PurePanel);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 60324:
|
|
/*!***********************************************************!*\
|
|
!*** ./node_modules/_antd@5.9.0@antd/es/popover/index.js ***!
|
|
\***********************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! classnames */ 92310);
|
|
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(classnames__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react */ 59301);
|
|
/* harmony import */ var _util_getRenderPropValue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../_util/getRenderPropValue */ 77578);
|
|
/* harmony import */ var _util_motion__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../_util/motion */ 62892);
|
|
/* harmony import */ var _config_provider__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../config-provider */ 36355);
|
|
/* harmony import */ var _tooltip__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../tooltip */ 6848);
|
|
/* harmony import */ var _PurePanel__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./PurePanel */ 39722);
|
|
/* harmony import */ var _style__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./style */ 17356);
|
|
"use client";
|
|
|
|
var __rest = undefined && undefined.__rest || function (s, e) {
|
|
var t = {};
|
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
}
|
|
return t;
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// CSSINJS
|
|
|
|
const Overlay = _ref => {
|
|
let {
|
|
title,
|
|
content,
|
|
prefixCls
|
|
} = _ref;
|
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1__.createElement(react__WEBPACK_IMPORTED_MODULE_1__.Fragment, null, title && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1__.createElement("div", {
|
|
className: `${prefixCls}-title`
|
|
}, (0,_util_getRenderPropValue__WEBPACK_IMPORTED_MODULE_2__/* .getRenderPropValue */ .Z)(title)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1__.createElement("div", {
|
|
className: `${prefixCls}-inner-content`
|
|
}, (0,_util_getRenderPropValue__WEBPACK_IMPORTED_MODULE_2__/* .getRenderPropValue */ .Z)(content)));
|
|
};
|
|
const Popover = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1__.forwardRef((props, ref) => {
|
|
const {
|
|
prefixCls: customizePrefixCls,
|
|
title,
|
|
content,
|
|
overlayClassName,
|
|
placement = 'top',
|
|
trigger = 'hover',
|
|
mouseEnterDelay = 0.1,
|
|
mouseLeaveDelay = 0.1,
|
|
overlayStyle = {}
|
|
} = props,
|
|
otherProps = __rest(props, ["prefixCls", "title", "content", "overlayClassName", "placement", "trigger", "mouseEnterDelay", "mouseLeaveDelay", "overlayStyle"]);
|
|
const {
|
|
getPrefixCls
|
|
} = react__WEBPACK_IMPORTED_MODULE_1__.useContext(_config_provider__WEBPACK_IMPORTED_MODULE_3__/* .ConfigContext */ .E_);
|
|
const prefixCls = getPrefixCls('popover', customizePrefixCls);
|
|
const [wrapSSR, hashId] = (0,_style__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)(prefixCls);
|
|
const rootPrefixCls = getPrefixCls();
|
|
const overlayCls = classnames__WEBPACK_IMPORTED_MODULE_0___default()(overlayClassName, hashId);
|
|
return wrapSSR( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1__.createElement(_tooltip__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, Object.assign({
|
|
placement: placement,
|
|
trigger: trigger,
|
|
mouseEnterDelay: mouseEnterDelay,
|
|
mouseLeaveDelay: mouseLeaveDelay,
|
|
overlayStyle: overlayStyle
|
|
}, otherProps, {
|
|
prefixCls: prefixCls,
|
|
overlayClassName: overlayCls,
|
|
ref: ref,
|
|
overlay: title || content ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1__.createElement(Overlay, {
|
|
prefixCls: prefixCls,
|
|
title: title,
|
|
content: content
|
|
}) : null,
|
|
transitionName: (0,_util_motion__WEBPACK_IMPORTED_MODULE_6__/* .getTransitionName */ .m)(rootPrefixCls, 'zoom-big', otherProps.transitionName),
|
|
"data-popover-inject": true
|
|
})));
|
|
});
|
|
if (false) {}
|
|
Popover._InternalPanelDoNotUseOrYouWillBeFired = _PurePanel__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .ZP;
|
|
/* harmony default export */ __webpack_exports__.Z = (Popover);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 17356:
|
|
/*!*****************************************************************!*\
|
|
!*** ./node_modules/_antd@5.9.0@antd/es/popover/style/index.js ***!
|
|
\*****************************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
/* harmony import */ var _style__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../style */ 17313);
|
|
/* harmony import */ var _style_motion__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../style/motion */ 29878);
|
|
/* harmony import */ var _style_placementArrow__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../style/placementArrow */ 19447);
|
|
/* harmony import */ var _theme_internal__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../theme/internal */ 33166);
|
|
/* harmony import */ var _theme_internal__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../theme/internal */ 83116);
|
|
/* harmony import */ var _theme_internal__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../theme/internal */ 37613);
|
|
"use client";
|
|
|
|
|
|
|
|
|
|
|
|
const genBaseStyle = token => {
|
|
const {
|
|
componentCls,
|
|
popoverColor,
|
|
minWidth,
|
|
fontWeightStrong,
|
|
popoverPadding,
|
|
boxShadowSecondary,
|
|
colorTextHeading,
|
|
borderRadiusLG: borderRadius,
|
|
zIndexPopup,
|
|
marginXS,
|
|
colorBgElevated,
|
|
popoverBg
|
|
} = token;
|
|
return [{
|
|
[componentCls]: Object.assign(Object.assign({}, (0,_style__WEBPACK_IMPORTED_MODULE_0__/* .resetComponent */ .Wf)(token)), {
|
|
position: 'absolute',
|
|
top: 0,
|
|
// use `left` to fix https://github.com/ant-design/ant-design/issues/39195
|
|
left: {
|
|
_skip_check_: true,
|
|
value: 0
|
|
},
|
|
zIndex: zIndexPopup,
|
|
fontWeight: 'normal',
|
|
whiteSpace: 'normal',
|
|
textAlign: 'start',
|
|
cursor: 'auto',
|
|
userSelect: 'text',
|
|
transformOrigin: `var(--arrow-x, 50%) var(--arrow-y, 50%)`,
|
|
'--antd-arrow-background-color': colorBgElevated,
|
|
'&-rtl': {
|
|
direction: 'rtl'
|
|
},
|
|
'&-hidden': {
|
|
display: 'none'
|
|
},
|
|
[`${componentCls}-content`]: {
|
|
position: 'relative'
|
|
},
|
|
[`${componentCls}-inner`]: {
|
|
backgroundColor: popoverBg,
|
|
backgroundClip: 'padding-box',
|
|
borderRadius,
|
|
boxShadow: boxShadowSecondary,
|
|
padding: popoverPadding
|
|
},
|
|
[`${componentCls}-title`]: {
|
|
minWidth,
|
|
marginBottom: marginXS,
|
|
color: colorTextHeading,
|
|
fontWeight: fontWeightStrong
|
|
},
|
|
[`${componentCls}-inner-content`]: {
|
|
color: popoverColor
|
|
}
|
|
})
|
|
},
|
|
// Arrow Style
|
|
(0,_style_placementArrow__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .ZP)(token, {
|
|
colorBg: 'var(--antd-arrow-background-color)'
|
|
}),
|
|
// Pure Render
|
|
{
|
|
[`${componentCls}-pure`]: {
|
|
position: 'relative',
|
|
maxWidth: 'none',
|
|
margin: token.sizePopupArrow,
|
|
display: 'inline-block',
|
|
[`${componentCls}-content`]: {
|
|
display: 'inline-block'
|
|
}
|
|
}
|
|
}];
|
|
};
|
|
const genColorStyle = token => {
|
|
const {
|
|
componentCls
|
|
} = token;
|
|
return {
|
|
[componentCls]: _theme_internal__WEBPACK_IMPORTED_MODULE_2__/* .PresetColors */ .i.map(colorKey => {
|
|
const lightColor = token[`${colorKey}6`];
|
|
return {
|
|
[`&${componentCls}-${colorKey}`]: {
|
|
'--antd-arrow-background-color': lightColor,
|
|
[`${componentCls}-inner`]: {
|
|
backgroundColor: lightColor
|
|
},
|
|
[`${componentCls}-arrow`]: {
|
|
background: 'transparent'
|
|
}
|
|
}
|
|
};
|
|
})
|
|
};
|
|
};
|
|
const genWireframeStyle = token => {
|
|
const {
|
|
componentCls,
|
|
lineWidth,
|
|
lineType,
|
|
colorSplit,
|
|
paddingSM,
|
|
controlHeight,
|
|
fontSize,
|
|
lineHeight,
|
|
padding
|
|
} = token;
|
|
const titlePaddingBlockDist = controlHeight - Math.round(fontSize * lineHeight);
|
|
const popoverTitlePaddingBlockTop = titlePaddingBlockDist / 2;
|
|
const popoverTitlePaddingBlockBottom = titlePaddingBlockDist / 2 - lineWidth;
|
|
const popoverPaddingHorizontal = padding;
|
|
return {
|
|
[componentCls]: {
|
|
[`${componentCls}-inner`]: {
|
|
padding: 0
|
|
},
|
|
[`${componentCls}-title`]: {
|
|
margin: 0,
|
|
padding: `${popoverTitlePaddingBlockTop}px ${popoverPaddingHorizontal}px ${popoverTitlePaddingBlockBottom}px`,
|
|
borderBottom: `${lineWidth}px ${lineType} ${colorSplit}`
|
|
},
|
|
[`${componentCls}-inner-content`]: {
|
|
padding: `${paddingSM}px ${popoverPaddingHorizontal}px`
|
|
}
|
|
}
|
|
};
|
|
};
|
|
/* harmony default export */ __webpack_exports__.Z = ((0,_theme_internal__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)('Popover', token => {
|
|
const {
|
|
colorBgElevated,
|
|
colorText,
|
|
wireframe
|
|
} = token;
|
|
const popoverToken = (0,_theme_internal__WEBPACK_IMPORTED_MODULE_4__/* .merge */ .TS)(token, {
|
|
popoverPadding: 12,
|
|
popoverBg: colorBgElevated,
|
|
popoverColor: colorText
|
|
});
|
|
return [genBaseStyle(popoverToken), genColorStyle(popoverToken), wireframe && genWireframeStyle(popoverToken), (0,_style_motion__WEBPACK_IMPORTED_MODULE_5__/* .initZoomMotion */ ._y)(popoverToken, 'zoom-big')];
|
|
}, token => ({
|
|
width: 177,
|
|
minWidth: 177,
|
|
zIndexPopup: token.zIndexPopupBase + 30
|
|
}), {
|
|
resetStyle: false,
|
|
deprecatedTokens: [['width', 'minWidth']]
|
|
}));
|
|
|
|
/***/ })
|
|
|
|
}]); |