(global["webpackJsonp"] = global["webpackJsonp"] || []).push([["devTools/page/common/vendor"],{ /***/ 1059: /*!***************************************************************************!*\ !*** E:/git/2021项目/v3-H5/devTools/page/components/libs/getRuntimeInfo.js ***! \***************************************************************************/ /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(uni) { var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 4); Object.defineProperty(exports, "__esModule", { value: true }); exports.default = getRuntimeInfo; var _regenerator = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/regenerator */ 50)); var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/asyncToGenerator */ 52)); /** * 获取当前运行时环境信息 */ function getRuntimeInfo() { return new Promise( /*#__PURE__*/function () { var _ref = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(yes) { var data; return _regenerator.default.wrap(function _callee$(_context) { while (1) { switch (_context.prev = _context.next) { case 0: _context.t0 = uni.getSystemInfoSync(); _context.t1 = uni.getDeviceInfo ? uni.getDeviceInfo() : null; _context.t2 = uni.getWindowInfo ? uni.getWindowInfo() : null; _context.t3 = uni.getAppBaseInfo ? uni.getAppBaseInfo() : null; _context.t4 = uni.getAppAuthorizeSetting ? uni.getAppAuthorizeSetting() : null; _context.t5 = uni.getSystemSetting ? uni.getSystemSetting() : null; _context.next = 8; return getNetworkType(); case 8: _context.t6 = _context.sent; _context.t7 = uni.getLaunchOptionsSync(); data = { 系统信息: _context.t0, 设备基础信息: _context.t1, 窗口信息: _context.t2, APP基础信息: _context.t3, APP授权设置: _context.t4, 设备设置: _context.t5, 网络状态: _context.t6, 启动参数: _context.t7 }; yes(data); case 12: case "end": return _context.stop(); } } }, _callee); })); return function (_x) { return _ref.apply(this, arguments); }; }()); } /** * 获取网络状态 */ function getNetworkType() { return new Promise(function (yes, err) { if (!uni.getNetworkType) { return yes(null); } uni.getNetworkType({ success: function success(res) { yes(res.networkType); }, fail: function fail() { yes("error"); } }); }); } /** * 获取APP端设备其他信息 */ function getAppOtherInfo() { return new Promise( /*#__PURE__*/function () { var _ref2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2(yes) { var info, getDevice, getOAID, getAAID, getDeviceId; return _regenerator.default.wrap(function _callee2$(_context2) { while (1) { switch (_context2.prev = _context2.next) { case 0: info = {}; getDevice = function getDevice() { return new Promise(function (yes) { plus.device.getInfo({ success: yes, fail: function fail() { yes("plus.device.getInfo() fail"); } }); }); }; getOAID = function getOAID() { return new Promise(function (yes) { plus.device.getOAID({ success: yes, fail: function fail() { yes("plus.device.getOAID() fail"); } }); }); }; getAAID = function getAAID() { return new Promise(function (yes) { plus.device.getOAID({ success: yes, fail: function fail() { yes("plus.device.getOAID() fail"); } }); }); }; getDeviceId = function getDeviceId() { return new Promise(function (yes) { try { var id = plus.device.getDeviceId(); yes(id); } catch (error) { yes("plus.device.getDeviceId() fail"); } }); }; _context2.prev = 5; _context2.next = 8; return getDevice(); case 8: info.getDevice = _context2.sent; _context2.next = 11; return getOAID(); case 11: info.getOAID = _context2.sent; _context2.next = 14; return getAAID(); case 14: info.getAAID = _context2.sent; _context2.next = 17; return getDeviceId(); case 17: info.getDeviceId = _context2.sent; yes(info); _context2.next = 25; break; case 21: _context2.prev = 21; _context2.t0 = _context2["catch"](5); console.log("getDeviceInfoFail", _context2.t0); yes("获取设备信息失败!"); case 25: plus.device.getInfo({ success: function success(e) { info = Object.assign(info, e); plus.device.getOAID({ success: function success(e) { info = Object.assign(info, e); plus.device.getVAID({ success: function success(e) {}, fail: function fail() { yes(Object.assign(info, { errMsg: "plus.device.getVAID 获取失败!" })); } }); }, fail: function fail() { yes(Object.assign(info, { errMsg: "plus.device.getOAID 获取失败!" })); } }); }, fail: function fail() { yes({ errMsg: "plus.device.getInfo 获取失败!" }); } }); case 26: case "end": return _context2.stop(); } } }, _callee2, null, [[5, 21]]); })); return function (_x2) { return _ref2.apply(this, arguments); }; }()); } /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */ 2)["default"])) /***/ }), /***/ 1158: /*!**********************************************************************!*\ !*** E:/git/2021项目/v3-H5/devTools/page/components/libs/appDelDir.js ***! \**********************************************************************/ /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { "use strict"; var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 4); Object.defineProperty(exports, "__esModule", { value: true }); exports.default = appDelDir; var _regenerator = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/regenerator */ 50)); var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/asyncToGenerator */ 52)); var _dirReader = _interopRequireDefault(__webpack_require__(/*! ./dirReader */ 941)); /** * 遍历删除整个文件夹,以“/”结尾 */ function appDelDir(path) { var needDelSelf = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true; return new Promise( /*#__PURE__*/function () { var _ref = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(yes, err) { var dirList, i, item, info; return _regenerator.default.wrap(function _callee$(_context) { while (1) { switch (_context.prev = _context.next) { case 0: _context.next = 2; return _dirReader.default.getDirFileList(path); case 2: dirList = _context.sent; i = 0; case 4: if (!(i < dirList.length)) { _context.next = 29; break; } item = dirList[i]; _context.prev = 6; if (!(item.type == "dir")) { _context.next = 20; break; } _context.next = 10; return getMeteInfo(path + item.name + "/"); case 10: info = _context.sent; if (!(info.directoryCount > 0 || info.fileCount > 0)) { _context.next = 16; break; } _context.next = 14; return appDelDir(path + item.name + "/"); case 14: _context.next = 18; break; case 16: _context.next = 18; return delDir(path + item.name + "/"); case 18: _context.next = 22; break; case 20: _context.next = 22; return delFile(path + item.name); case 22: _context.next = 26; break; case 24: _context.prev = 24; _context.t0 = _context["catch"](6); case 26: i++; _context.next = 4; break; case 29: _context.prev = 29; if (!needDelSelf) { _context.next = 33; break; } _context.next = 33; return delDir(path); case 33: _context.next = 37; break; case 35: _context.prev = 35; _context.t1 = _context["catch"](29); case 37: yes(); case 38: case "end": return _context.stop(); } } }, _callee, null, [[6, 24], [29, 35]]); })); return function (_x, _x2) { return _ref.apply(this, arguments); }; }()); } function delFile(path) { return new Promise(function (yes, err) { plus.io.resolveLocalFileSystemURL(path, function (entry) { entry.remove(yes, err); }, err); }); } function delDir(path) { return new Promise(function (yes, err) { plus.io.resolveLocalFileSystemURL(path, function (entry) { entry.remove(yes, err); }, err); }); } /** * 获取文件夹内信息 * @returns {Promise} */ function getMeteInfo(path) { return new Promise(function (yes, err) { plus.io.resolveLocalFileSystemURL(path, function (entry) { if (entry.isDirectory) { entry.getMetadata(function (metadata) { yes(metadata); }, err); } else { err(); } }, err); }); } /***/ }), /***/ 940: /*!*******************************************************************************!*\ !*** E:/git/2021项目/v3-H5/devTools/page/components/mixins/animationControl.js ***! \*******************************************************************************/ /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(uni) { Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _default = { methods: { /** * 显示面板 */ panelShow: function panelShow() { var that = this; var sys = uni.getSystemInfoSync(); animation.transition(that.$refs.mask, { styles: { opacity: 1, height: sys.windowHeight + 'px' }, duration: 200, //ms timingFunction: 'linear', delay: 0 //ms }); var height = Math.ceil(sys.windowHeight * 0.8); animation.transition(that.$refs.panel, { styles: { opacity: 1, transform: "transform: translate(0px,".concat(height, "px)") }, duration: 1, //ms timingFunction: 'linear', delay: 0 //ms }, function (res) { animation.transition(that.$refs.panel, { styles: { transform: "transform: translate(0px,0px)" }, duration: 200, //ms timingFunction: 'linear', delay: 0 //ms }); }); }, /** * 关闭面板 */ panelHide: function panelHide() { var that = this; animation.transition(that.$refs.mask, { styles: { opacity: 0 }, duration: 200, //ms timingFunction: 'linear', delay: 0 //ms }); var height = uni.upx2px(1000); animation.transition(that.$refs.panel, { styles: { transform: "transform: translate(0px,".concat(height, "px)") }, duration: 200, //ms timingFunction: 'linear', delay: 0 //ms }, function () { uni.$emit("devTools_panelHideSuccess"); }); } } }; exports.default = _default; /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */ 2)["default"])) /***/ }), /***/ 941: /*!**********************************************************************!*\ !*** E:/git/2021项目/v3-H5/devTools/page/components/libs/dirReader.js ***! \**********************************************************************/ /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var iconConfig = [{ type: ["", undefined, null], mime: "", icon: "/devTools/page/static/fileSys/weizhiwenjian.png" }, { type: ["dwg"], mime: "dwg", icon: "/devTools/page/static/fileSys/DWG.png" }, { type: ["xls", "xlsx", "csv"], mime: "xls", icon: "/devTools/page/static/fileSys/excel.png" }, { type: ["exe"], mime: "exe", icon: "/devTools/page/static/fileSys/EXE.png" }, { type: ["gif"], mime: "gif", icon: "/devTools/page/static/fileSys/GIF.png" }, { type: ["html"], mime: "html", icon: "/devTools/page/static/fileSys/HTML.png" }, { type: ["pdf"], mime: "pdf", icon: "/devTools/page/static/fileSys/pdf.png" }, { type: ["ppt"], mime: "ppt", icon: "/devTools/page/static/fileSys/pptl.png" }, { type: ["psd"], mime: "psd", icon: "/devTools/page/static/fileSys/PSD.png" }, { type: ["rvt"], mime: "rvt", icon: "/devTools/page/static/fileSys/RVT.png" }, { type: ["mp4", "avi", "wmv", "mpg", "mpeg", "mov", "flv", "3gp", "mp3gp", "mkv", "rmvb"], mime: "mp4", icon: "/devTools/page/static/fileSys/shipin.png" }, { type: ["skp"], mime: "skp", icon: "/devTools/page/static/fileSys/SKP.png" }, { type: ["svg"], mime: "svg", icon: "/devTools/page/static/fileSys/SVG.png" }, { type: ["png", "jpeg", "jpg", "webp", "bmp"], mime: "img", icon: "/devTools/page/static/fileSys/tupian.png" }, { type: ["txt", "sql", "js", "css", "log", "json"], mime: "txt", icon: "/devTools/page/static/fileSys/txt.png" }, { type: ["word"], mime: "word", icon: "/devTools/page/static/fileSys/word.png" }, { type: ["zip", "rar", "gz", "7z"], mime: "zip", icon: "/devTools/page/static/fileSys/yasuo.png" }, { type: ["mp3", "wma", "wav", "aac", "flac"], mime: "", icon: "/devTools/page/static/fileSys/yinpin.png" }]; var _default = { /** * 获取文件和目录列表 */ getDirFileList: function getDirFileList(path) { return new Promise(function (yes) {}); }, /** * 获取文件图片 */ getFileIcon: function getFileIcon(type) { for (var i = 0; i < iconConfig.length; i++) { var item = iconConfig[i]; for (var _i = 0; _i < item.type.length; _i++) { var typeName = item.type[_i]; if (type == typeName) { return item.icon; } } } return "/devTools/page/static/fileSys/weizhiwenjian.png"; } }; /** * @param {PlusIoDirectoryEntry} entry */ exports.default = _default; function getMetaData(entry) { return new Promise(function (yes) { entry.getMetadata(function (metadata) { yes({ size: metadata.size, time: metadata.modificationTime.getTime(), fileCount: metadata.fileCount, directoryCount: metadata.directoryCount }); }, function () { yes({ size: 0, time: 0, fileCount: 0, directoryCount: 0 }); }); }); } function getFileType(name) { if (typeof name == "string") { var tList = name.split("."); if (tList.length > 1) { return tList.pop().toLocaleLowerCase(); } else { return ""; } } else { return ""; } } /***/ }), /***/ 942: /*!*********************************************************************!*\ !*** E:/git/2021项目/v3-H5/devTools/page/components/libs/fileSize.js ***! \*********************************************************************/ /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _default = { /** * 获取字节大小,b转kb mb */ getByteSize: function getByteSize(size) { if (null == size || size == '') return "0 B"; var unitArr = ["B", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB"]; var index = 0; var srcsize = parseFloat(size); index = Math.floor(Math.log(srcsize) / Math.log(1024)); var size = srcsize / Math.pow(1024, index); size = size.toFixed(2); //保留的小数位数 return size + unitArr[index]; } }; exports.default = _default; /***/ }), /***/ 943: /*!*****************************************************************!*\ !*** E:/git/2021项目/v3-H5/devTools/page/components/mixins/mp.js ***! \*****************************************************************/ /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(uni) { Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _default = { data: function data() { return { windowInfo: getWindowInfo() }; }, computed: { /** * 小程序和H5的标题 */ navbarStyle: function navbarStyle() { var windowInfo = getWindowInfo(); return { statusBarHeightPx: windowInfo.system.statusBarHeight + 'px', navbarHeightPx: windowInfo.navbar.bodyHeightPx + 'px' }; } }, methods: { back: function back() { uni.navigateBack(); } } }; /** * 获取当前窗口数据 * */ exports.default = _default; function getWindowInfo() { var systemInfo = uni.getSystemInfoSync(); systemInfo.pixelRatio = Math.round(systemInfo.pixelRatio * 100) / 100; var windowInfo = { system: systemInfo, capsule: { bottom: 78, height: 30, left: 283, right: 363, top: 48, width: 0 }, navbar: { heightPx: uni.upx2px(100) + systemInfo.statusBarHeight, bodyHeightPx: uni.upx2px(100), bodyWidthPx: systemInfo.windowWidth, capsuleWidthPx: 0, capsuleRightPx: 0 }, height: systemInfo.windowHeight * (750 / systemInfo.windowWidth), width: 750, statusBarHeight: systemInfo.statusBarHeight * (750 / systemInfo.windowWidth), safeBottom: systemInfo.windowHeight - systemInfo.safeArea.bottom, safeBottomRpx: (systemInfo.windowHeight - systemInfo.safeArea.bottom) * (750 / systemInfo.windowWidth), /** * 原生端 底部导航栏高度 */ footNavbarHeight: uni.upx2px(100) + (systemInfo.windowHeight - systemInfo.safeArea.bottom) }; var capsuleInfo = uni.getMenuButtonBoundingClientRect(); windowInfo.capsule = capsuleInfo; var capsuleToStatusBarPx = capsuleInfo.top - systemInfo.statusBarHeight; //胶囊和状态栏之间的高度 windowInfo.navbar.bodyHeightPx = capsuleInfo.height + capsuleToStatusBarPx * 2; windowInfo.navbar.heightPx = windowInfo.navbar.bodyHeightPx + systemInfo.statusBarHeight; var capsuleWidthPx = (systemInfo.windowWidth - capsuleInfo.right) * 2 + capsuleInfo.width; windowInfo.navbar.bodyWidthPx = systemInfo.windowWidth - capsuleWidthPx; windowInfo.navbar.capsuleWidthPx = capsuleWidthPx; windowInfo.navbar.capsuleRightPx = capsuleWidthPx - (systemInfo.windowWidth - capsuleInfo.right); return windowInfo; } /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */ 2)["default"])) /***/ }) }]); //# sourceMappingURL=../../../../.sourcemap/mp-weixin/devTools/page/common/vendor.js.map