增加新模块
This commit is contained in:
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"color.js","sources":["uni_modules/uview-plus/libs/config/color.js"],"sourcesContent":["// 为了让用户能够自定义主题,会逐步弃用此文件,各颜色通过css提供\r\n// 为了给某些特殊场景使用和向后兼容,无需删除此文件(2020-06-20)\r\nconst color = {\r\n primary: '#3c9cff',\r\n info: '#909399',\r\n default: '#909399',\r\n warning: '#f9ae3d',\r\n error: '#f56c6c',\r\n success: '#5ac725',\r\n mainColor: '#303133',\r\n contentColor: '#606266',\r\n tipsColor: '#909399',\r\n lightColor: '#c0c4cc',\r\n borderColor: '#e4e7ed'\r\n}\r\n\r\nexport default color\n"],"names":[],"mappings":";AAEK,MAAC,QAAQ;AAAA,EACV,SAAS;AAAA,EACT,MAAM;AAAA,EACN,SAAS;AAAA,EACT,SAAS;AAAA,EACT,OAAO;AAAA,EACP,SAAS;AAAA,EACT,WAAW;AAAA,EACX,cAAc;AAAA,EACd,WAAW;AAAA,EACX,YAAY;AAAA,EACZ,aAAa;AACjB;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"config.js","sources":["uni_modules/uview-plus/libs/config/config.js"],"sourcesContent":["const version = '3'\n\n// 开发环境才提示,生产环境不会提示\nif (process.env.NODE_ENV === 'development') {\n\tconsole.log(`\\n %c uview-plus V${version} %c https://ijry.github.io/uview-plus/ \\n\\n`, 'color: #ffffff; background: #3c9cff; padding:5px 0;', 'color: #3c9cff;background: #ffffff; padding:5px 0;');\n}\n\nexport default {\n v: version,\n version,\n // 主题名称\n type: [\n 'primary',\n 'success',\n 'info',\n 'error',\n 'warning'\n ],\n // 颜色部分,本来可以通过scss的:export导出供js使用,但是奈何nvue不支持\n color: {\n 'u-primary': '#2979ff',\n 'u-warning': '#ff9900',\n 'u-success': '#19be6b',\n 'u-error': '#fa3534',\n 'u-info': '#909399',\n 'u-main-color': '#303133',\n 'u-content-color': '#606266',\n 'u-tips-color': '#909399',\n 'u-light-color': '#c0c4cc',\n 'up-primary': '#2979ff',\n 'up-warning': '#ff9900',\n 'up-success': '#19be6b',\n 'up-error': '#fa3534',\n 'up-info': '#909399',\n 'up-main-color': '#303133',\n 'up-content-color': '#606266',\n 'up-tips-color': '#909399',\n 'up-light-color': '#c0c4cc'\n },\n\t// 默认单位,可以通过配置为rpx,那么在用于传入组件大小参数为数值时,就默认为rpx\n\tunit: 'px',\n\t// 拦截器\n\tinterceptor: {\n\t\tnavbarLeftClick: null\n\t}\n}\n"],"names":[],"mappings":";;AAAA,MAAM,UAAU;AAG4B;wFAC/B;AAAA,kBAAqB,OAAO;AAAA;AAAA,GAA+C,uDAAuD,oDAAoD;AACnM;AAEA,MAAe,SAAA;AAAA,EACX,GAAG;AAAA,EACH;AAAA;AAAA,EAEA,MAAM;AAAA,IACF;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACJ;AAAA;AAAA,EAEA,OAAO;AAAA,IACH,aAAa;AAAA,IACb,aAAa;AAAA,IACb,aAAa;AAAA,IACb,WAAW;AAAA,IACX,UAAU;AAAA,IACV,gBAAgB;AAAA,IAChB,mBAAmB;AAAA,IACnB,gBAAgB;AAAA,IAChB,iBAAiB;AAAA,IACjB,cAAc;AAAA,IACd,cAAc;AAAA,IACd,cAAc;AAAA,IACd,YAAY;AAAA,IACZ,WAAW;AAAA,IACX,iBAAiB;AAAA,IACjB,oBAAoB;AAAA,IACpB,iBAAiB;AAAA,IACjB,kBAAkB;AAAA,EACtB;AAAA;AAAA,EAEH,MAAM;AAAA;AAAA,EAEN,aAAa;AAAA,IACZ,iBAAiB;AAAA,EAClB;AACD;;"}
|
||||
+1
File diff suppressed because one or more lines are too long
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"zIndex.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;"}
|
||||
Vendored
+1
File diff suppressed because one or more lines are too long
Vendored
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"debounce.js","sources":["uni_modules/uview-plus/libs/function/debounce.js"],"sourcesContent":["let timeout = null\r\n\r\n/**\r\n * 防抖原理:一定时间内,只有最后一次操作,再过wait毫秒后才执行函数\r\n *\r\n * @param {Function} func 要执行的回调函数\r\n * @param {Number} wait 延时的时间\r\n * @param {Boolean} immediate 是否立即执行\r\n * @return null\r\n */\r\nexport function debounce(func, wait = 500, immediate = false) {\r\n // 清除定时器\r\n if (timeout !== null) clearTimeout(timeout)\r\n // 立即执行,此类情况一般用不到\r\n if (immediate) {\r\n const callNow = !timeout\r\n timeout = setTimeout(() => {\r\n timeout = null\r\n }, wait)\r\n if (callNow) typeof func === 'function' && func()\r\n } else {\r\n // 设置定时器,当最后一次操作后,timeout不会再被清除,所以在延时wait毫秒后执行func回调方法\r\n timeout = setTimeout(() => {\r\n typeof func === 'function' && func()\r\n }, wait)\r\n }\r\n}\r\n\r\nexport default debounce\r\n"],"names":[],"mappings":";AAAA,IAAI,UAAU;AAUP,SAAS,SAAS,MAAM,OAAO,KAAK,YAAY,OAAO;AAE1D,MAAI,YAAY;AAAM,iBAAa,OAAO;AAE1C,MAAI,WAAW;AACX,UAAM,UAAU,CAAC;AACjB,cAAU,WAAW,MAAM;AACvB,gBAAU;AAAA,IACb,GAAE,IAAI;AACP,QAAI;AAAS,aAAO,SAAS,cAAc,KAAM;AAAA,EACzD,OAAW;AAEH,cAAU,WAAW,MAAM;AACvB,aAAO,SAAS,cAAc,KAAM;AAAA,IACvC,GAAE,IAAI;AAAA,EACV;AACL;;"}
|
||||
+1
File diff suppressed because one or more lines are too long
+1
File diff suppressed because one or more lines are too long
Vendored
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"platform.js","sources":["uni_modules/uview-plus/libs/function/platform.js"],"sourcesContent":["/**\n * 注意:\n * 此部分内容,在vue-cli模式下,需要在vue.config.js加入如下内容才有效:\n * module.exports = {\n * transpileDependencies: ['uview-v2']\n * }\n */\n\nlet platform = 'none'\n\n// #ifdef VUE3\nplatform = 'vue3'\n// #endif\n\n// #ifdef VUE2\nplatform = 'vue2'\n// #endif\n\n// #ifdef APP-PLUS\nplatform = 'plus'\n// #endif\n\n// #ifdef APP-NVUE\nplatform = 'nvue'\n// #endif\n\n// #ifdef H5\nplatform = 'h5'\n// #endif\n\n// #ifdef MP\nplatform = 'mp'\n// #endif\n\n// #ifdef MP-WEIXIN\nplatform = 'weixin'\n// #endif\n\n// #ifdef MP-ALIPAY\nplatform = 'alipay'\n// #endif\n\n// #ifdef MP-BAIDU\nplatform = 'baidu'\n// #endif\n\n// #ifdef MP-TOUTIAO\nplatform = 'toutiao'\n// #endif\n\n// #ifdef MP-QQ\nplatform = 'qq'\n// #endif\n\n// #ifdef MP-KUAISHOU\nplatform = 'kuaishou'\n// #endif\n\n// #ifdef MP-360\nplatform = '360'\n// #endif\n\n// #ifdef QUICKAPP-WEBVIEW\nplatform = 'quickapp-webview'\n// #endif\n\n// #ifdef QUICKAPP-WEBVIEW-HUAWEI\nplatform = 'quickapp-webview-huawei'\n// #endif\n\n// #ifdef QUICKAPP-WEBVIEW-UNION\nplatform = 'quckapp-webview-union'\n// #endif\n\nexport default platform\n"],"names":[],"mappings":";AAQA,IAAI,WAAW;AAGf,WAAW;AAoBX,WAAW;AAIX,WAAW;AAuCX,MAAe,aAAA;;"}
|
||||
+1
File diff suppressed because one or more lines are too long
Vendored
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"throttle.js","sources":["uni_modules/uview-plus/libs/function/throttle.js"],"sourcesContent":["let timer;\r\nlet flag;\r\n/**\r\n * 节流原理:在一定时间内,只能触发一次\r\n *\r\n * @param {Function} func 要执行的回调函数\r\n * @param {Number} wait 延时的时间\r\n * @param {Boolean} immediate 是否立即执行\r\n * @return null\r\n */\r\nexport function throttle(func, wait = 500, immediate = true) {\r\n if (immediate) {\r\n if (!flag) {\r\n flag = true\r\n // 如果是立即执行,则在wait毫秒内开始时执行\r\n typeof func === 'function' && func()\r\n timer = setTimeout(() => {\r\n flag = false\r\n }, wait)\r\n }\r\n } else if (!flag) {\r\n flag = true\r\n // 如果是非立即执行,则在wait毫秒内的结束处执行\r\n timer = setTimeout(() => {\r\n flag = false\r\n typeof func === 'function' && func()\r\n }, wait)\r\n }\r\n}\r\nexport default throttle\r\n"],"names":[],"mappings":";AACA,IAAI;AASG,SAAS,SAAS,MAAM,OAAO,KAAK,YAAY,MAAM;AACzD,MAAI,WAAW;AACX,QAAI,CAAC,MAAM;AACP,aAAO;AAEP,aAAO,SAAS,cAAc,KAAM;AAC5B,iBAAW,MAAM;AACrB,eAAO;AAAA,MACV,GAAE,IAAI;AAAA,IACV;AAAA,EACT,WAAe,CAAC,MAAM;AACd,WAAO;AAEC,eAAW,MAAM;AACrB,aAAO;AACP,aAAO,SAAS,cAAc,KAAM;AAAA,IACvC,GAAE,IAAI;AAAA,EACV;AACL;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"index.js","sources":["uni_modules/uview-plus/libs/luch-request/adapters/index.js"],"sourcesContent":["import buildURL from '../helpers/buildURL'\r\nimport buildFullPath from '../core/buildFullPath'\r\nimport settle from '../core/settle'\r\nimport { isUndefined } from '../utils'\r\n\r\n/**\r\n * 返回可选值存在的配置\r\n * @param {Array} keys - 可选值数组\r\n * @param {Object} config2 - 配置\r\n * @return {{}} - 存在的配置项\r\n */\r\nconst mergeKeys = (keys, config2) => {\r\n const config = {}\r\n keys.forEach((prop) => {\r\n if (!isUndefined(config2[prop])) {\r\n config[prop] = config2[prop]\r\n }\r\n })\r\n return config\r\n}\r\nexport default (config) => new Promise((resolve, reject) => {\r\n const fullPath = buildURL(buildFullPath(config.baseURL, config.url), config.params)\r\n const _config = {\r\n url: fullPath,\r\n header: config.header,\r\n complete: (response) => {\r\n config.fullPath = fullPath\r\n response.config = config\r\n try {\r\n // 对可能字符串不是json 的情况容错\r\n if (typeof response.data === 'string') {\r\n response.data = JSON.parse(response.data)\r\n }\r\n // eslint-disable-next-line no-empty\r\n } catch (e) {\r\n }\r\n settle(resolve, reject, response)\r\n }\r\n }\r\n let requestTask\r\n if (config.method === 'UPLOAD') {\r\n delete _config.header['content-type']\r\n delete _config.header['Content-Type']\r\n const otherConfig = {\r\n // #ifdef MP-ALIPAY\r\n fileType: config.fileType,\r\n // #endif\r\n filePath: config.filePath,\r\n name: config.name\r\n }\r\n const optionalKeys = [\r\n // #ifdef APP-PLUS || H5\r\n 'files',\r\n // #endif\r\n // #ifdef H5\r\n 'file',\r\n // #endif\r\n // #ifdef H5 || APP-PLUS\r\n 'timeout',\r\n // #endif\r\n 'formData'\r\n ]\r\n requestTask = uni.uploadFile({ ..._config, ...otherConfig, ...mergeKeys(optionalKeys, config) })\r\n } else if (config.method === 'DOWNLOAD') {\r\n // #ifdef H5 || APP-PLUS\r\n if (!isUndefined(config.timeout)) {\r\n _config.timeout = config.timeout\r\n }\r\n // #endif\r\n requestTask = uni.downloadFile(_config)\r\n } else {\r\n const optionalKeys = [\r\n 'data',\r\n 'method',\r\n // #ifdef H5 || APP-PLUS || MP-ALIPAY || MP-WEIXIN\r\n 'timeout',\r\n // #endif\r\n 'dataType',\r\n // #ifndef MP-ALIPAY\r\n 'responseType',\r\n // #endif\r\n // #ifdef APP-PLUS\r\n 'sslVerify',\r\n // #endif\r\n // #ifdef H5\r\n 'withCredentials',\r\n // #endif\r\n // #ifdef APP-PLUS\r\n 'firstIpv4'\r\n // #endif\r\n ]\r\n requestTask = uni.request({ ..._config, ...mergeKeys(optionalKeys, config) })\r\n }\r\n if (config.getTask) {\r\n config.getTask(requestTask, config)\r\n }\r\n})\r\n"],"names":["isUndefined","buildURL","buildFullPath","settle","uni"],"mappings":";;;;;;AAWA,MAAM,YAAY,CAAC,MAAM,YAAY;AACjC,QAAM,SAAS,CAAE;AACjB,OAAK,QAAQ,CAAC,SAAS;AACnB,QAAI,CAACA,6CAAW,YAAC,QAAQ,IAAI,CAAC,GAAG;AAC7B,aAAO,IAAI,IAAI,QAAQ,IAAI;AAAA,IAC9B;AAAA,EACT,CAAK;AACD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uview-plus/libs/luch-request/core/InterceptorManager.js"],"sourcesContent":["'use strict'\r\n\r\nfunction InterceptorManager() {\r\n this.handlers = []\r\n}\r\n\r\n/**\r\n * Add a new interceptor to the stack\r\n *\r\n * @param {Function} fulfilled The function to handle `then` for a `Promise`\r\n * @param {Function} rejected The function to handle `reject` for a `Promise`\r\n *\r\n * @return {Number} An ID used to remove interceptor later\r\n */\r\nInterceptorManager.prototype.use = function use(fulfilled, rejected) {\r\n this.handlers.push({\r\n fulfilled,\r\n rejected\r\n })\r\n return this.handlers.length - 1\r\n}\r\n\r\n/**\r\n * Remove an interceptor from the stack\r\n *\r\n * @param {Number} id The ID that was returned by `use`\r\n */\r\nInterceptorManager.prototype.eject = function eject(id) {\r\n if (this.handlers[id]) {\r\n this.handlers[id] = null\r\n }\r\n}\r\n\r\n/**\r\n * Iterate over all the registered interceptors\r\n *\r\n * This method is particularly useful for skipping over any\r\n * interceptors that may have become `null` calling `eject`.\r\n *\r\n * @param {Function} fn The function to call for each interceptor\r\n */\r\nInterceptorManager.prototype.forEach = function forEach(fn) {\r\n this.handlers.forEach((h) => {\r\n if (h !== null) {\r\n fn(h)\r\n }\r\n })\r\n}\r\n\r\nexport default InterceptorManager\r\n"],"names":[],"mappings":";AAEA,SAAS,qBAAqB;AAC1B,OAAK,WAAW,CAAE;AACtB;AAUA,mBAAmB,UAAU,MAAM,SAAS,IAAI,WAAW,UAAU;AACjE,OAAK,SAAS,KAAK;AAAA,IACf;AAAA,IACA;AAAA,EACR,CAAK;AACD,SAAO,KAAK,SAAS,SAAS;AAClC;AAOA,mBAAmB,UAAU,QAAQ,SAAS,MAAM,IAAI;AACpD,MAAI,KAAK,SAAS,EAAE,GAAG;AACnB,SAAK,SAAS,EAAE,IAAI;AAAA,EACvB;AACL;AAUA,mBAAmB,UAAU,UAAU,SAAS,QAAQ,IAAI;AACxD,OAAK,SAAS,QAAQ,CAAC,MAAM;AACzB,QAAI,MAAM,MAAM;AACZ,SAAG,CAAC;AAAA,IACP;AAAA,EACT,CAAK;AACL;;"}
|
||||
unpackage/dist/dev/.sourcemap/mp-weixin/uni_modules/uview-plus/libs/luch-request/core/Request.js.map
Vendored
+1
File diff suppressed because one or more lines are too long
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"buildFullPath.js","sources":["uni_modules/uview-plus/libs/luch-request/core/buildFullPath.js"],"sourcesContent":["'use strict'\r\n\r\nimport isAbsoluteURL from '../helpers/isAbsoluteURL'\r\nimport combineURLs from '../helpers/combineURLs'\r\n\r\n/**\r\n * Creates a new URL by combining the baseURL with the requestedURL,\r\n * only when the requestedURL is not already an absolute URL.\r\n * If the requestURL is absolute, this function returns the requestedURL untouched.\r\n *\r\n * @param {string} baseURL The base URL\r\n * @param {string} requestedURL Absolute or relative URL to combine\r\n * @returns {string} The combined full path\r\n */\r\nexport default function buildFullPath(baseURL, requestedURL) {\r\n if (baseURL && !isAbsoluteURL(requestedURL)) {\r\n return combineURLs(baseURL, requestedURL)\r\n }\r\n return requestedURL\r\n}\r\n"],"names":["isAbsoluteURL","combineURLs"],"mappings":";;;AAce,SAAS,cAAc,SAAS,cAAc;AACzD,MAAI,WAAW,CAACA,2EAAc,YAAY,GAAG;AACzC,WAAOC,2DAAW,YAAC,SAAS,YAAY;AAAA,EAC3C;AACD,SAAO;AACX;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"defaults.js","sources":["uni_modules/uview-plus/libs/luch-request/core/defaults.js"],"sourcesContent":["/**\r\n * 默认的全局配置\r\n */\r\n\r\nexport default {\r\n baseURL: '',\r\n header: {},\r\n method: 'GET',\r\n dataType: 'json',\r\n // #ifndef MP-ALIPAY\r\n responseType: 'text',\r\n // #endif\r\n custom: {},\r\n // #ifdef H5 || APP-PLUS || MP-ALIPAY || MP-WEIXIN\r\n timeout: 60000,\r\n // #endif\r\n // #ifdef APP-PLUS\r\n sslVerify: true,\r\n // #endif\r\n // #ifdef H5\r\n withCredentials: false,\r\n // #endif\r\n // #ifdef APP-PLUS\r\n firstIpv4: false,\r\n // #endif\r\n validateStatus: function validateStatus(status) {\r\n return status >= 200 && status < 300\r\n }\r\n}\r\n"],"names":[],"mappings":";AAIA,MAAe,WAAA;AAAA,EACX,SAAS;AAAA,EACT,QAAQ,CAAE;AAAA,EACV,QAAQ;AAAA,EACR,UAAU;AAAA,EAEV,cAAc;AAAA,EAEd,QAAQ,CAAE;AAAA,EAEV,SAAS;AAAA,EAWT,gBAAgB,SAAS,eAAe,QAAQ;AAC5C,WAAO,UAAU,OAAO,SAAS;AAAA,EACpC;AACL;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"dispatchRequest.js","sources":["uni_modules/uview-plus/libs/luch-request/core/dispatchRequest.js"],"sourcesContent":["import adapter from '../adapters/index'\r\n\r\nexport default (config) => adapter(config)\r\n"],"names":["adapter"],"mappings":";;AAEA,MAAA,kBAAe,CAAC,WAAWA,sDAAAA,QAAQ,MAAM;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"mergeConfig.js","sources":["uni_modules/uview-plus/libs/luch-request/core/mergeConfig.js"],"sourcesContent":["import { deepMerge, isUndefined } from '../utils'\r\n\r\n/**\r\n * 合并局部配置优先的配置,如果局部有该配置项则用局部,如果全局有该配置项则用全局\r\n * @param {Array} keys - 配置项\r\n * @param {Object} globalsConfig - 当前的全局配置\r\n * @param {Object} config2 - 局部配置\r\n * @return {{}}\r\n */\r\nconst mergeKeys = (keys, globalsConfig, config2) => {\r\n const config = {}\r\n keys.forEach((prop) => {\r\n if (!isUndefined(config2[prop])) {\r\n config[prop] = config2[prop]\r\n } else if (!isUndefined(globalsConfig[prop])) {\r\n config[prop] = globalsConfig[prop]\r\n }\r\n })\r\n return config\r\n}\r\n/**\r\n *\r\n * @param globalsConfig - 当前实例的全局配置\r\n * @param config2 - 当前的局部配置\r\n * @return - 合并后的配置\r\n */\r\nexport default (globalsConfig, config2 = {}) => {\r\n const method = config2.method || globalsConfig.method || 'GET'\r\n let config = {\r\n baseURL: globalsConfig.baseURL || '',\r\n method,\r\n url: config2.url || '',\r\n params: config2.params || {},\r\n custom: { ...(globalsConfig.custom || {}), ...(config2.custom || {}) },\r\n header: deepMerge(globalsConfig.header || {}, config2.header || {})\r\n }\r\n const defaultToConfig2Keys = ['getTask', 'validateStatus']\r\n config = { ...config, ...mergeKeys(defaultToConfig2Keys, globalsConfig, config2) }\r\n\r\n // eslint-disable-next-line no-empty\r\n if (method === 'DOWNLOAD') {\r\n // #ifdef H5 || APP-PLUS\r\n if (!isUndefined(config2.timeout)) {\r\n config.timeout = config2.timeout\r\n } else if (!isUndefined(globalsConfig.timeout)) {\r\n config.timeout = globalsConfig.timeout\r\n }\r\n // #endif\r\n } else if (method === 'UPLOAD') {\r\n delete config.header['content-type']\r\n delete config.header['Content-Type']\r\n const uploadKeys = [\r\n // #ifdef APP-PLUS || H5\r\n 'files',\r\n // #endif\r\n // #ifdef MP-ALIPAY\r\n 'fileType',\r\n // #endif\r\n // #ifdef H5\r\n 'file',\r\n // #endif\r\n 'filePath',\r\n 'name',\r\n // #ifdef H5 || APP-PLUS\r\n 'timeout',\r\n // #endif\r\n 'formData'\r\n ]\r\n uploadKeys.forEach((prop) => {\r\n if (!isUndefined(config2[prop])) {\r\n config[prop] = config2[prop]\r\n }\r\n })\r\n // #ifdef H5 || APP-PLUS\r\n if (isUndefined(config.timeout) && !isUndefined(globalsConfig.timeout)) {\r\n config.timeout = globalsConfig.timeout\r\n }\r\n // #endif\r\n } else {\r\n const defaultsKeys = [\r\n 'data',\r\n // #ifdef H5 || APP-PLUS || MP-ALIPAY || MP-WEIXIN\r\n 'timeout',\r\n // #endif\r\n 'dataType',\r\n // #ifndef MP-ALIPAY\r\n 'responseType',\r\n // #endif\r\n // #ifdef APP-PLUS\r\n 'sslVerify',\r\n // #endif\r\n // #ifdef H5\r\n 'withCredentials',\r\n // #endif\r\n // #ifdef APP-PLUS\r\n 'firstIpv4'\r\n // #endif\r\n ]\r\n config = { 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,MAC9B;AAAA,IACb,CAAS;AAAA,EAMT,OAAW;AACH,UAAM,eAAe;AAAA,MACjB;AAAA,MAEA;AAAA,MAEA;AAAA,MAEA;AAAA,IAWH;AACD,aAAS,EAAE,GAAG,QAAQ,GAAG,UAAU,cAAc,eAAe,OAAO,EAAG;AAAA,EAC7E;AAED,SAAO;AACX;;"}
|
||||
Vendored
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"settle.js","sources":["uni_modules/uview-plus/libs/luch-request/core/settle.js"],"sourcesContent":["/**\r\n * Resolve or reject a Promise based on response status.\r\n *\r\n * @param {Function} resolve A function that resolves the promise.\r\n * @param {Function} reject A function that rejects the promise.\r\n * @param {object} response The response.\r\n */\r\nexport default function settle(resolve, reject, response) {\r\n const { validateStatus } = response.config\r\n const status = response.statusCode\r\n if (status && (!validateStatus || validateStatus(status))) {\r\n resolve(response)\r\n } else {\r\n reject(response)\r\n }\r\n}\r\n"],"names":[],"mappings":";AAOe,SAAS,OAAO,SAAS,QAAQ,UAAU;AACtD,QAAM,EAAE,mBAAmB,SAAS;AACpC,QAAM,SAAS,SAAS;AACxB,MAAI,WAAW,CAAC,kBAAkB,eAAe,MAAM,IAAI;AACvD,YAAQ,QAAQ;AAAA,EACxB,OAAW;AACH,WAAO,QAAQ;AAAA,EAClB;AACL;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"buildURL.js","sources":["uni_modules/uview-plus/libs/luch-request/helpers/buildURL.js"],"sourcesContent":["'use strict'\r\n\r\nimport * as utils from '../utils'\r\n\r\nfunction encode(val) {\r\n return encodeURIComponent(val)\r\n .replace(/%40/gi, '@')\r\n .replace(/%3A/gi, ':')\r\n .replace(/%24/g, '$')\r\n .replace(/%2C/gi, ',')\r\n .replace(/%20/g, '+')\r\n .replace(/%5B/gi, '[')\r\n .replace(/%5D/gi, ']')\r\n}\r\n\r\n/**\r\n * Build a URL by appending params to the end\r\n *\r\n * @param {string} url The base of the url (e.g., http://www.google.com)\r\n * @param {object} [params] The params to be appended\r\n * @returns {string} The formatted url\r\n */\r\nexport default function buildURL(url, params) {\r\n /* eslint no-param-reassign:0 */\r\n if (!params) {\r\n return url\r\n }\r\n\r\n let serializedParams\r\n if (utils.isURLSearchParams(params)) {\r\n serializedParams = params.toString()\r\n } else {\r\n const parts = []\r\n\r\n utils.forEach(params, (val, key) => {\r\n if (val === null || typeof val === 'undefined') {\r\n return\r\n }\r\n\r\n if (utils.isArray(val)) {\r\n key = `${key}[]`\r\n } else {\r\n val = [val]\r\n }\r\n\r\n utils.forEach(val, (v) => {\r\n if (utils.isDate(v)) {\r\n v = v.toISOString()\r\n } else if (utils.isObject(v)) {\r\n v = JSON.stringify(v)\r\n }\r\n parts.push(`${encode(key)}=${encode(v)}`)\r\n })\r\n })\r\n\r\n serializedParams = parts.join('&')\r\n }\r\n\r\n if (serializedParams) {\r\n const hashmarkIndex = url.indexOf('#')\r\n if (hashmarkIndex !== -1) {\r\n url = url.slice(0, hashmarkIndex)\r\n }\r\n\r\n url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams\r\n }\r\n\r\n return url\r\n}\r\n"],"names":["utils.isURLSearchParams","utils.forEach","utils.isArray","utils.isDate","utils.isObject"],"mappings":";;AAIA,SAAS,OAAO,KAAK;AACjB,SAAO,mBAAmB,GAAG,EACxB,QAAQ,SAAS,GAAG,EACpB,QAAQ,SAAS,GAAG,EACpB,QAAQ,QAAQ,GAAG,EACnB,QAAQ,SAAS,GAAG,EACpB,QAAQ,QAAQ,GAAG,EACnB,QAAQ,SAAS,GAAG,EACpB,QAAQ,SAAS,GAAG;AAC7B;AASe,SAAS,SAAS,KAAK,QAAQ;AAE1C,MAAI,CAAC,QAAQ;AACT,WAAO;AAAA,EACV;AAED,MAAI;AACJ,MAAIA,6CAAAA,kBAAwB,MAAM,GAAG;AACjC,uBAAmB,OAAO,SAAU;AAAA,EAC5C,OAAW;AACH,UAAM,QAAQ,CAAE;AAEhBC,iDAAAA,QAAc,QAAQ,CAAC,KAAK,QAAQ;AAChC,UAAI,QAAQ,QAAQ,OAAO,QAAQ,aAAa;AAC5C;AAAA,MACH;AAED,UAAIC,6CAAAA,QAAc,GAAG,GAAG;AACpB,cAAM,GAAG,GAAG;AAAA,MAC5B,OAAmB;AACH,cAAM,CAAC,GAAG;AAAA,MACb;AAEDD,2DAAc,KAAK,CAAC,MAAM;AACtB,YAAIE,6CAAAA,OAAa,CAAC,GAAG;AACjB,cAAI,EAAE,YAAa;AAAA,QACvC,WAA2BC,6CAAAA,SAAe,CAAC,GAAG;AAC1B,cAAI,KAAK,UAAU,CAAC;AAAA,QACvB;AACD,cAAM,KAAK,GAAG,OAAO,GAAG,CAAC,IAAI,OAAO,CAAC,CAAC,EAAE;AAAA,MACxD,CAAa;AAAA,IACb,CAAS;AAED,uBAAmB,MAAM,KAAK,GAAG;AAAA,EACpC;AAED,MAAI,kBAAkB;AAClB,UAAM,gBAAgB,IAAI,QAAQ,GAAG;AACrC,QAAI,kBAAkB,IAAI;AACtB,YAAM,IAAI,MAAM,GAAG,aAAa;AAAA,IACnC;AAED,YAAQ,IAAI,QAAQ,GAAG,MAAM,KAAK,MAAM,OAAO;AAAA,EAClD;AAED,SAAO;AACX;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"combineURLs.js","sources":["uni_modules/uview-plus/libs/luch-request/helpers/combineURLs.js"],"sourcesContent":["'use strict'\r\n\r\n/**\r\n * Creates a new URL by combining the specified URLs\r\n *\r\n * @param {string} baseURL The base URL\r\n * @param {string} relativeURL The relative URL\r\n * @returns {string} The combined URL\r\n */\r\nexport default function combineURLs(baseURL, relativeURL) {\r\n return relativeURL\r\n ? `${baseURL.replace(/\\/+$/, '')}/${relativeURL.replace(/^\\/+/, '')}`\r\n : baseURL\r\n}\r\n"],"names":[],"mappings":";AASe,SAAS,YAAY,SAAS,aAAa;AACtD,SAAO,cACD,GAAG,QAAQ,QAAQ,QAAQ,EAAE,CAAC,IAAI,YAAY,QAAQ,QAAQ,EAAE,CAAC,KACjE;AACV;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"isAbsoluteURL.js","sources":["uni_modules/uview-plus/libs/luch-request/helpers/isAbsoluteURL.js"],"sourcesContent":["'use strict'\r\n\r\n/**\r\n * Determines whether the specified URL is absolute\r\n *\r\n * @param {string} url The URL to test\r\n * @returns {boolean} True if the specified URL is absolute, otherwise false\r\n */\r\nexport default function isAbsoluteURL(url) {\r\n // A URL is considered absolute if it begins with \"<scheme>://\" or \"//\" (protocol-relative URL).\r\n // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed\r\n // by any combination of letters, digits, plus, period, or hyphen.\r\n return /^([a-z][a-z\\d+\\-.]*:)?\\/\\//i.test(url)\r\n}\r\n"],"names":[],"mappings":";AAQe,SAAS,cAAc,KAAK;AAIvC,SAAO,8BAA8B,KAAK,GAAG;AACjD;;"}
|
||||
Vendored
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
|
||||
Vendored
+1
File diff suppressed because one or more lines are too long
Vendored
+1
File diff suppressed because one or more lines are too long
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"button.js","sources":["uni_modules/uview-plus/libs/mixin/button.js"],"sourcesContent":["import { defineMixin } from '../vue'\r\n\r\nexport const buttonMixin = defineMixin({\r\n props: {\r\n lang: String,\r\n sessionFrom: String,\r\n sendMessageTitle: String,\r\n sendMessagePath: String,\r\n sendMessageImg: String,\r\n showMessageCard: Boolean,\r\n appParameter: String,\r\n formType: String,\r\n openType: String\r\n }\r\n})\r\n\r\nexport default buttonMixin\r\n\r\n"],"names":["defineMixin"],"mappings":";;AAEY,MAAC,cAAcA,+BAAAA,YAAY;AAAA,EACnC,OAAO;AAAA,IACH,MAAM;AAAA,IACN,aAAa;AAAA,IACb,kBAAkB;AAAA,IAClB,iBAAiB;AAAA,IACjB,gBAAgB;AAAA,IAChB,iBAAiB;AAAA,IACjB,cAAc;AAAA,IACd,UAAU;AAAA,IACV,UAAU;AAAA,EACb;AACL,CAAC;;"}
|
||||
+1
File diff suppressed because one or more lines are too long
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"mpMixin.js","sources":["uni_modules/uview-plus/libs/mixin/mpMixin.js"],"sourcesContent":["import { defineMixin } from '../vue'\n\nexport const mpMixin = defineMixin({\n // #ifdef MP-WEIXIN\n // 将自定义节点设置成虚拟的,更加接近Vue组件的表现,能更好的使用flex属性\n options: {\n virtualHost: true\n }\n // #endif\n})\n\nexport default mpMixin\n\n"],"names":["defineMixin"],"mappings":";;AAEY,MAAC,UAAUA,+BAAAA,YAAY;AAAA;AAAA,EAG/B,SAAS;AAAA,IACL,aAAa;AAAA,EAChB;AAEL,CAAC;;"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"openType.js","sources":["uni_modules/uview-plus/libs/mixin/openType.js"],"sourcesContent":["import { defineMixin } from '../vue'\r\n\r\nexport const openType = defineMixin({\r\n props: {\r\n openType: String\r\n },\r\n methods: {\r\n onGetUserInfo(event) {\r\n this.$emit('getuserinfo', event.detail)\r\n },\r\n onContact(event) {\r\n this.$emit('contact', event.detail)\r\n },\r\n onGetPhoneNumber(event) {\r\n this.$emit('getphonenumber', event.detail)\r\n },\r\n onError(event) {\r\n this.$emit('error', event.detail)\r\n },\r\n onLaunchApp(event) {\r\n this.$emit('launchapp', event.detail)\r\n },\r\n onOpenSetting(event) {\r\n this.$emit('opensetting', event.detail)\r\n }\r\n }\r\n})\r\n"],"names":["defineMixin"],"mappings":";;AAEY,MAAC,WAAWA,+BAAAA,YAAY;AAAA,EAChC,OAAO;AAAA,IACH,UAAU;AAAA,EACb;AAAA,EACD,SAAS;AAAA,IACL,cAAc,OAAO;AACjB,WAAK,MAAM,eAAe,MAAM,MAAM;AAAA,IACzC;AAAA,IACD,UAAU,OAAO;AACb,WAAK,MAAM,WAAW,MAAM,MAAM;AAAA,IACrC;AAAA,IACD,iBAAiB,OAAO;AACpB,WAAK,MAAM,kBAAkB,MAAM,MAAM;AAAA,IAC5C;AAAA,IACD,QAAQ,OAAO;AACX,WAAK,MAAM,SAAS,MAAM,MAAM;AAAA,IACnC;AAAA,IACD,YAAY,OAAO;AACf,WAAK,MAAM,aAAa,MAAM,MAAM;AAAA,IACvC;AAAA,IACD,cAAc,OAAO;AACjB,WAAK,MAAM,eAAe,MAAM,MAAM;AAAA,IACzC;AAAA,EACJ;AACL,CAAC;;"}
|
||||
+1
File diff suppressed because one or more lines are too long
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"vue.js","sources":["uni_modules/uview-plus/libs/vue.js"],"sourcesContent":["export const defineMixin = (options) => {\n return options\n}\n"],"names":[],"mappings":";AAAY,MAAC,cAAc,CAAC,YAAY;AACtC,SAAO;AACT;;"}
|
||||
Reference in New Issue
Block a user