123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437 |
- (global["webpackJsonp"] = global["webpackJsonp"] || []).push([["uview-ui/components/u-image/u-image"],{
- /***/ 302:
- /*!*******************************************************************************!*\
- !*** D:/星火篮球维护/代码/小程序教练端/spark-coach/uview-ui/components/u-image/u-image.vue ***!
- \*******************************************************************************/
- /*! no static exports found */
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
- "use strict";
- __webpack_require__.r(__webpack_exports__);
- /* harmony import */ var _u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./u-image.vue?vue&type=template&id=32babe48&scoped=true& */ 303);
- /* harmony import */ var _u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./u-image.vue?vue&type=script&lang=js& */ 305);
- /* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__) if(__WEBPACK_IMPORT_KEY__ !== 'default') (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__[key]; }) }(__WEBPACK_IMPORT_KEY__));
- /* harmony import */ var _u_image_vue_vue_type_style_index_0_id_32babe48_scoped_true_lang_scss___WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./u-image.vue?vue&type=style&index=0&id=32babe48&scoped=true&lang=scss& */ 307);
- /* harmony import */ var _E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/runtime/componentNormalizer.js */ 10);
- var renderjs
- /* normalize component */
- var component = Object(_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_3__["default"])(
- _u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"],
- _u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__["render"],
- _u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"],
- false,
- null,
- "32babe48",
- null,
- false,
- _u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__["components"],
- renderjs
- )
- component.options.__file = "uview-ui/components/u-image/u-image.vue"
- /* harmony default export */ __webpack_exports__["default"] = (component.exports);
- /***/ }),
- /***/ 303:
- /*!**************************************************************************************************************************!*\
- !*** D:/星火篮球维护/代码/小程序教练端/spark-coach/uview-ui/components/u-image/u-image.vue?vue&type=template&id=32babe48&scoped=true& ***!
- \**************************************************************************************************************************/
- /*! exports provided: render, staticRenderFns, recyclableRender, components */
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
- "use strict";
- __webpack_require__.r(__webpack_exports__);
- /* harmony import */ var _E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_16_0_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--16-0!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/template.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-uni-app-loader/page-meta.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./u-image.vue?vue&type=template&id=32babe48&scoped=true& */ 304);
- /* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "render", function() { return _E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_16_0_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__["render"]; });
- /* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return _E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_16_0_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"]; });
- /* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return _E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_16_0_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__["recyclableRender"]; });
- /* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "components", function() { return _E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_16_0_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_template_id_32babe48_scoped_true___WEBPACK_IMPORTED_MODULE_0__["components"]; });
- /***/ }),
- /***/ 304:
- /*!**************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
- !*** ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--16-0!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/template.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-uni-app-loader/page-meta.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!D:/星火篮球维护/代码/小程序教练端/spark-coach/uview-ui/components/u-image/u-image.vue?vue&type=template&id=32babe48&scoped=true& ***!
- \**************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
- /*! exports provided: render, staticRenderFns, recyclableRender, components */
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
- "use strict";
- __webpack_require__.r(__webpack_exports__);
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "render", function() { return render; });
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return staticRenderFns; });
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
- var components
- try {
- components = {
- uIcon: function() {
- return __webpack_require__.e(/*! import() | uview-ui/components/u-icon/u-icon */ "uview-ui/components/u-icon/u-icon").then(__webpack_require__.bind(null, /*! @/uview-ui/components/u-icon/u-icon.vue */ 309))
- }
- }
- } catch (e) {
- if (
- e.message.indexOf("Cannot find module") !== -1 &&
- e.message.indexOf(".vue") !== -1
- ) {
- console.error(e.message)
- console.error("1. 排查组件名称拼写是否正确")
- console.error(
- "2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"
- )
- console.error(
- "3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件"
- )
- } else {
- throw e
- }
- }
- var render = function() {
- var _vm = this
- var _h = _vm.$createElement
- var _c = _vm._self._c || _h
- var s0 = _vm.__get_style([_vm.wrapStyle, _vm.backgroundStyle])
- var g0 =
- !_vm.isError && !(_vm.shape == "circle")
- ? _vm.$u.addUnit(_vm.borderRadius)
- : null
- var g1 =
- _vm.showLoading && _vm.loading && !(_vm.shape == "circle")
- ? _vm.$u.addUnit(_vm.borderRadius)
- : null
- var g2 =
- _vm.showError && _vm.isError && !_vm.loading && !(_vm.shape == "circle")
- ? _vm.$u.addUnit(_vm.borderRadius)
- : null
- _vm.$mp.data = Object.assign(
- {},
- {
- $root: {
- s0: s0,
- g0: g0,
- g1: g1,
- g2: g2
- }
- }
- )
- }
- var recyclableRender = false
- var staticRenderFns = []
- render._withStripped = true
- /***/ }),
- /***/ 305:
- /*!********************************************************************************************************!*\
- !*** D:/星火篮球维护/代码/小程序教练端/spark-coach/uview-ui/components/u-image/u-image.vue?vue&type=script&lang=js& ***!
- \********************************************************************************************************/
- /*! no static exports found */
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
- "use strict";
- __webpack_require__.r(__webpack_exports__);
- /* harmony import */ var _E_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_12_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!./node_modules/babel-loader/lib!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--12-1!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./u-image.vue?vue&type=script&lang=js& */ 306);
- /* harmony import */ var _E_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_12_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_E_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_12_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__);
- /* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _E_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_12_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__) if(__WEBPACK_IMPORT_KEY__ !== 'default') (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _E_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_12_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
- /* harmony default export */ __webpack_exports__["default"] = (_E_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_12_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default.a);
- /***/ }),
- /***/ 306:
- /*!***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
- !*** ./node_modules/babel-loader/lib!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--12-1!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!D:/星火篮球维护/代码/小程序教练端/spark-coach/uview-ui/components/u-image/u-image.vue?vue&type=script&lang=js& ***!
- \***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
- /*! no static exports found */
- /***/ (function(module, exports, __webpack_require__) {
- "use strict";
- Object.defineProperty(exports, "__esModule", { value: true });exports.default = void 0; //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- //
- /**
- * Image 图片
- * @description 此组件为uni-app的image组件的加强版,在继承了原有功能外,还支持淡入动画、加载中、加载失败提示、圆角值和形状等。
- * @tutorial https://uviewui.com/components/image.html
- * @property {String} src 图片地址
- * @property {String} mode 裁剪模式,见官网说明
- * @property {String | Number} width 宽度,单位任意,如果为数值,则为rpx单位(默认100%)
- * @property {String | Number} height 高度,单位任意,如果为数值,则为rpx单位(默认 auto)
- * @property {String} shape 图片形状,circle-圆形,square-方形(默认square)
- * @property {String | Number} border-radius 圆角值,单位任意,如果为数值,则为rpx单位(默认 0)
- * @property {Boolean} lazy-load 是否懒加载,仅微信小程序、App、百度小程序、字节跳动小程序有效(默认 true)
- * @property {Boolean} show-menu-by-longpress 是否开启长按图片显示识别小程序码菜单,仅微信小程序有效(默认 false)
- * @property {String} loading-icon 加载中的图标,或者小图片(默认 photo)
- * @property {String} error-icon 加载失败的图标,或者小图片(默认 error-circle)
- * @property {Boolean} show-loading 是否显示加载中的图标或者自定义的slot(默认 true)
- * @property {Boolean} show-error 是否显示加载错误的图标或者自定义的slot(默认 true)
- * @property {Boolean} fade 是否需要淡入效果(默认 true)
- * @property {String Number} width 传入图片路径时图片的宽度
- * @property {String Number} height 传入图片路径时图片的高度
- * @property {Boolean} webp 只支持网络资源,只对微信小程序有效(默认 false)
- * @property {String | Number} duration 搭配fade参数的过渡时间,单位ms(默认 500)
- * @event {Function} click 点击图片时触发
- * @event {Function} error 图片加载失败时触发
- * @event {Function} load 图片加载成功时触发
- * @example <u-image width="100%" height="300rpx" :src="src"></u-image>
- */var _default =
- {
- name: 'u-image',
- props: {
- // 图片地址
- src: {
- type: String,
- default: '' },
- // 裁剪模式
- mode: {
- type: String,
- default: 'aspectFill' },
- // 宽度,单位任意
- width: {
- type: [String, Number],
- default: '100%' },
- // 高度,单位任意
- height: {
- type: [String, Number],
- default: 'auto' },
- // 图片形状,circle-圆形,square-方形
- shape: {
- type: String,
- default: 'square' },
- // 圆角,单位任意
- borderRadius: {
- type: [String, Number],
- default: 0 },
- // 是否懒加载,微信小程序、App、百度小程序、字节跳动小程序
- lazyLoad: {
- type: Boolean,
- default: true },
- // 开启长按图片显示识别微信小程序码菜单
- showMenuByLongpress: {
- type: Boolean,
- default: true },
- // 加载中的图标,或者小图片
- loadingIcon: {
- type: String,
- default: 'photo' },
- // 加载失败的图标,或者小图片
- errorIcon: {
- type: String,
- default: 'error-circle' },
- // 是否显示加载中的图标或者自定义的slot
- showLoading: {
- type: Boolean,
- default: true },
- // 是否显示加载错误的图标或者自定义的slot
- showError: {
- type: Boolean,
- default: true },
- // 是否需要淡入效果
- fade: {
- type: Boolean,
- default: true },
- // 只支持网络资源,只对微信小程序有效
- webp: {
- type: Boolean,
- default: false },
- // 过渡时间,单位ms
- duration: {
- type: [String, Number],
- default: 500 },
- // 背景颜色,用于深色页面加载图片时,为了和背景色融合
- bgColor: {
- type: String,
- default: '#f3f4f6' } },
- data: function data() {
- return {
- // 图片是否加载错误,如果是,则显示错误占位图
- isError: false,
- // 初始化组件时,默认为加载中状态
- loading: true,
- // 不透明度,为了实现淡入淡出的效果
- opacity: 1,
- // 过渡时间,因为props的值无法修改,故需要一个中间值
- durationTime: this.duration,
- // 图片加载完成时,去掉背景颜色,因为如果是png图片,就会显示灰色的背景
- backgroundStyle: {} };
- },
- watch: {
- src: function src(n) {
- if (!n) {
- // 如果传入null或者'',或者false,或者undefined,标记为错误状态
- this.isError = true;
- } else {
- this.isError = false;
- }
- } },
- computed: {
- wrapStyle: function wrapStyle() {
- var style = {};
- // 通过调用addUnit()方法,如果有单位,如百分比,px单位等,直接返回,如果是纯粹的数值,则加上rpx单位
- style.width = this.$u.addUnit(this.width);
- style.height = this.$u.addUnit(this.height);
- // 如果是配置了圆形,设置50%的圆角,否则按照默认的配置值
- style.borderRadius = this.shape == 'circle' ? '50%' : this.$u.addUnit(this.borderRadius);
- // 如果设置圆角,必须要有hidden,否则可能圆角无效
- style.overflow = this.borderRadius > 0 ? 'hidden' : 'visible';
- if (this.fade) {
- style.opacity = this.opacity;
- style.transition = "opacity ".concat(Number(this.durationTime) / 1000, "s ease-in-out");
- }
- return style;
- } },
- methods: {
- // 点击图片
- onClick: function onClick() {
- this.$emit('click');
- },
- // 图片加载失败
- onErrorHandler: function onErrorHandler() {
- this.loading = false;
- this.isError = true;
- this.$emit('error');
- },
- // 图片加载完成,标记loading结束
- onLoadHandler: function onLoadHandler() {var _this = this;
- this.loading = false;
- this.isError = false;
- this.$emit('load');
- // 如果不需要动画效果,就不执行下方代码,同时移除加载时的背景颜色
- // 否则无需fade效果时,png图片依然能看到下方的背景色
- if (!this.fade) return this.removeBgColor();
- // 原来opacity为1(不透明,是为了显示占位图),改成0(透明,意味着该元素显示的是背景颜色,默认的灰色),再改成1,是为了获得过渡效果
- this.opacity = 0;
- // 这里设置为0,是为了图片展示到背景全透明这个过程时间为0,延时之后延时之后重新设置为duration,是为了获得背景透明(灰色)
- // 到图片展示的过程中的淡入效果
- this.durationTime = 0;
- // 延时50ms,否则在浏览器H5,过渡效果无效
- setTimeout(function () {
- _this.durationTime = _this.duration;
- _this.opacity = 1;
- setTimeout(function () {
- _this.removeBgColor();
- }, _this.durationTime);
- }, 50);
- },
- // 移除图片的背景色
- removeBgColor: function removeBgColor() {
- // 淡入动画过渡完成后,将背景设置为透明色,否则png图片会看到灰色的背景
- this.backgroundStyle = {
- backgroundColor: 'transparent' };
- } } };exports.default = _default;
- /***/ }),
- /***/ 307:
- /*!*****************************************************************************************************************************************!*\
- !*** D:/星火篮球维护/代码/小程序教练端/spark-coach/uview-ui/components/u-image/u-image.vue?vue&type=style&index=0&id=32babe48&scoped=true&lang=scss& ***!
- \*****************************************************************************************************************************************/
- /*! no static exports found */
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
- "use strict";
- __webpack_require__.r(__webpack_exports__);
- /* harmony import */ var _E_HBuilderX_plugins_uniapp_cli_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_E_HBuilderX_plugins_uniapp_cli_node_modules_css_loader_dist_cjs_js_ref_8_oneOf_1_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_stylePostLoader_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_2_E_HBuilderX_plugins_uniapp_cli_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_E_HBuilderX_plugins_uniapp_cli_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_4_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_5_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_style_index_0_id_32babe48_scoped_true_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!./node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!./node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--8-oneOf-1-2!./node_modules/postcss-loader/src??ref--8-oneOf-1-3!./node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-4!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--8-oneOf-1-5!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./u-image.vue?vue&type=style&index=0&id=32babe48&scoped=true&lang=scss& */ 308);
- /* harmony import */ var _E_HBuilderX_plugins_uniapp_cli_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_E_HBuilderX_plugins_uniapp_cli_node_modules_css_loader_dist_cjs_js_ref_8_oneOf_1_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_stylePostLoader_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_2_E_HBuilderX_plugins_uniapp_cli_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_E_HBuilderX_plugins_uniapp_cli_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_4_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_5_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_style_index_0_id_32babe48_scoped_true_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_E_HBuilderX_plugins_uniapp_cli_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_E_HBuilderX_plugins_uniapp_cli_node_modules_css_loader_dist_cjs_js_ref_8_oneOf_1_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_stylePostLoader_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_2_E_HBuilderX_plugins_uniapp_cli_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_E_HBuilderX_plugins_uniapp_cli_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_4_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_5_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_style_index_0_id_32babe48_scoped_true_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
- /* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _E_HBuilderX_plugins_uniapp_cli_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_E_HBuilderX_plugins_uniapp_cli_node_modules_css_loader_dist_cjs_js_ref_8_oneOf_1_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_stylePostLoader_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_2_E_HBuilderX_plugins_uniapp_cli_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_E_HBuilderX_plugins_uniapp_cli_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_4_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_5_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_style_index_0_id_32babe48_scoped_true_lang_scss___WEBPACK_IMPORTED_MODULE_0__) if(__WEBPACK_IMPORT_KEY__ !== 'default') (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _E_HBuilderX_plugins_uniapp_cli_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_E_HBuilderX_plugins_uniapp_cli_node_modules_css_loader_dist_cjs_js_ref_8_oneOf_1_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_stylePostLoader_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_2_E_HBuilderX_plugins_uniapp_cli_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_E_HBuilderX_plugins_uniapp_cli_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_4_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_5_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_style_index_0_id_32babe48_scoped_true_lang_scss___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
- /* harmony default export */ __webpack_exports__["default"] = (_E_HBuilderX_plugins_uniapp_cli_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_E_HBuilderX_plugins_uniapp_cli_node_modules_css_loader_dist_cjs_js_ref_8_oneOf_1_1_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_stylePostLoader_js_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_2_E_HBuilderX_plugins_uniapp_cli_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_E_HBuilderX_plugins_uniapp_cli_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_4_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_8_oneOf_1_5_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_E_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_u_image_vue_vue_type_style_index_0_id_32babe48_scoped_true_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
- /***/ }),
- /***/ 308:
- /*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
- !*** ./node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!./node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--8-oneOf-1-2!./node_modules/postcss-loader/src??ref--8-oneOf-1-3!./node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-4!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--8-oneOf-1-5!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!D:/星火篮球维护/代码/小程序教练端/spark-coach/uview-ui/components/u-image/u-image.vue?vue&type=style&index=0&id=32babe48&scoped=true&lang=scss& ***!
- \*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
- /*! no static exports found */
- /***/ (function(module, exports, __webpack_require__) {
- // extracted by mini-css-extract-plugin
- if(false) { var cssReload; }
-
- /***/ })
- }]);
- //# sourceMappingURL=../../../../.sourcemap/mp-weixin/uview-ui/components/u-image/u-image.js.map
- ;(global["webpackJsonp"] = global["webpackJsonp"] || []).push([
- 'uview-ui/components/u-image/u-image-create-component',
- {
- 'uview-ui/components/u-image/u-image-create-component':(function(module, exports, __webpack_require__){
- __webpack_require__('1')['createComponent'](__webpack_require__(302))
- })
- },
- [['uview-ui/components/u-image/u-image-create-component']]
- ]);
|