修复:修复小程序文章图片不显示BUG

This commit is contained in:
小莫唐尼 2022-12-06 18:36:06 +08:00
parent acc9070134
commit 3ba10fa105
2 changed files with 161 additions and 158 deletions

View File

@ -1,5 +1,5 @@
<template> <template>
<view class=""> <view class="cache-image">
<view v-if="loadStatus == 'loading'" class="img-loading" :style="[imgStyle, loadStyle]"> <view v-if="loadStatus == 'loading'" class="img-loading" :style="[imgStyle, loadStyle]">
<!-- <text class="img-load-icon iconfont icon-loading"></text> <!-- <text class="img-load-icon iconfont icon-loading"></text>
<text class="img-load-text">{{ loadText }}</text> --> <text class="img-load-text">{{ loadText }}</text> -->
@ -108,6 +108,7 @@ export default {
} }
}, },
created() { created() {
console.log('cache-image', this.url);
this.imgStyle = { this.imgStyle = {
width: this.width, width: this.width,
height: this.height, height: this.height,
@ -144,6 +145,10 @@ export default {
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
.cache-image {
width: 100%;
height: 100%;
}
.img-loading, .img-loading,
.img-error { .img-error {
display: flex; display: flex;

View File

@ -1,31 +1,31 @@
{ {
"name": "uni-halo", "name" : "uni-halo",
"appid": "__UNI__5748B6E", "appid" : "__UNI__5748B6E",
"description": "uni-halo博客基于halo开源博客系统API开发的多端博客。", "description" : "uni-halo博客基于halo开源博客系统API开发的多端博客。",
"versionName": "1.0.0", "versionName" : "1.0.0",
"versionCode": 100, "versionCode" : 100,
"transformPx": false, "transformPx" : false,
/* 5+App */ /* 5+App */
"app-plus": { "app-plus" : {
"usingComponents": true, "usingComponents" : true,
"nvueStyleCompiler": "uni-app", "nvueStyleCompiler" : "uni-app",
"compilerVersion": 3, "compilerVersion" : 3,
"splashscreen": { "splashscreen" : {
"alwaysShowBeforeRender": true, "alwaysShowBeforeRender" : true,
"waiting": true, "waiting" : true,
"autoclose": true, "autoclose" : true,
"delay": 0 "delay" : 0
}, },
/* */ /* */
"modules": { "modules" : {
"OAuth": {}, "OAuth" : {},
"Share": {} "Share" : {}
}, },
/* */ /* */
"distribute": { "distribute" : {
/* android */ /* android */
"android": { "android" : {
"permissions": [ "permissions" : [
"<uses-feature android:name=\"android.hardware.camera\"/>", "<uses-feature android:name=\"android.hardware.camera\"/>",
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>", "<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>", "<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
@ -46,114 +46,112 @@
] ]
}, },
/* ios */ /* ios */
"ios": { "ios" : {
"dSYMs": false, "dSYMs" : false,
"capabilities": { "capabilities" : {
"entitlements": { "entitlements" : {
"com.apple.developer.associated-domains": [ "com.apple.developer.associated-domains" : [ "applinks:static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com" ]
"applinks:static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com"
]
} }
} }
}, },
/* SDK */ /* SDK */
"sdkConfigs": { "sdkConfigs" : {
"ad": { "ad" : {
"gdt": {}, "gdt" : {},
"csj": {}, "csj" : {},
"360": {}, "360" : {},
"ks": {}, "ks" : {},
"sigmob": {}, "sigmob" : {},
"hw": {}, "hw" : {},
"bd": {} "bd" : {}
}, },
"oauth": { "oauth" : {
"weixin": { "weixin" : {
"appid": "wxd971954762ec4744", "appid" : "wxd971954762ec4744",
"UniversalLinks": "https://static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com/uni-universallinks/__UNI__5748B6E/" "UniversalLinks" : "https://static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com/uni-universallinks/__UNI__5748B6E/"
} }
}, },
"share": { "share" : {
"weixin": { "weixin" : {
"appid": "wxd971954762ec4744", "appid" : "wxd971954762ec4744",
"UniversalLinks": "https://static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com/uni-universallinks/__UNI__5748B6E/" "UniversalLinks" : "https://static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com/uni-universallinks/__UNI__5748B6E/"
} }
} }
}, },
"icons": { "icons" : {
"android": { "android" : {
"hdpi": "unpackage/res/icons/72x72.png", "hdpi" : "unpackage/res/icons/72x72.png",
"xhdpi": "unpackage/res/icons/96x96.png", "xhdpi" : "unpackage/res/icons/96x96.png",
"xxhdpi": "unpackage/res/icons/144x144.png", "xxhdpi" : "unpackage/res/icons/144x144.png",
"xxxhdpi": "unpackage/res/icons/192x192.png" "xxxhdpi" : "unpackage/res/icons/192x192.png"
}, },
"ios": { "ios" : {
"appstore": "unpackage/res/icons/1024x1024.png", "appstore" : "unpackage/res/icons/1024x1024.png",
"ipad": { "ipad" : {
"app": "unpackage/res/icons/76x76.png", "app" : "unpackage/res/icons/76x76.png",
"app@2x": "unpackage/res/icons/152x152.png", "app@2x" : "unpackage/res/icons/152x152.png",
"notification": "unpackage/res/icons/20x20.png", "notification" : "unpackage/res/icons/20x20.png",
"notification@2x": "unpackage/res/icons/40x40.png", "notification@2x" : "unpackage/res/icons/40x40.png",
"proapp@2x": "unpackage/res/icons/167x167.png", "proapp@2x" : "unpackage/res/icons/167x167.png",
"settings": "unpackage/res/icons/29x29.png", "settings" : "unpackage/res/icons/29x29.png",
"settings@2x": "unpackage/res/icons/58x58.png", "settings@2x" : "unpackage/res/icons/58x58.png",
"spotlight": "unpackage/res/icons/40x40.png", "spotlight" : "unpackage/res/icons/40x40.png",
"spotlight@2x": "unpackage/res/icons/80x80.png" "spotlight@2x" : "unpackage/res/icons/80x80.png"
}, },
"iphone": { "iphone" : {
"app@2x": "unpackage/res/icons/120x120.png", "app@2x" : "unpackage/res/icons/120x120.png",
"app@3x": "unpackage/res/icons/180x180.png", "app@3x" : "unpackage/res/icons/180x180.png",
"notification@2x": "unpackage/res/icons/40x40.png", "notification@2x" : "unpackage/res/icons/40x40.png",
"notification@3x": "unpackage/res/icons/60x60.png", "notification@3x" : "unpackage/res/icons/60x60.png",
"settings@2x": "unpackage/res/icons/58x58.png", "settings@2x" : "unpackage/res/icons/58x58.png",
"settings@3x": "unpackage/res/icons/87x87.png", "settings@3x" : "unpackage/res/icons/87x87.png",
"spotlight@2x": "unpackage/res/icons/80x80.png", "spotlight@2x" : "unpackage/res/icons/80x80.png",
"spotlight@3x": "unpackage/res/icons/120x120.png" "spotlight@3x" : "unpackage/res/icons/120x120.png"
} }
} }
} }
} }
}, },
/* */ /* */
"quickapp": {}, "quickapp" : {},
/* */ /* */
"mp-weixin": { "mp-weixin" : {
"appid": "wx1bb161867082c72f", "appid" : "wx1bb161867082c72f",
"setting": { "setting" : {
"urlCheck": false, "urlCheck" : false,
"minified": true "minified" : true
}, },
"usingComponents": true "usingComponents" : true
}, },
"mp-alipay": { "mp-alipay" : {
"usingComponents": true "usingComponents" : true
}, },
"mp-baidu": { "mp-baidu" : {
"usingComponents": true "usingComponents" : true
}, },
"mp-toutiao": { "mp-toutiao" : {
"usingComponents": true "usingComponents" : true
}, },
"uniStatistics": { "uniStatistics" : {
"enable": false "enable" : false
}, },
"vueVersion": "2", "vueVersion" : "2",
"h5": { "h5" : {
"title": "uni-halo", "title" : "uni-halo",
"devServer": { "devServer" : {
"https": false, "https" : false,
"disableHostCheck": true, "disableHostCheck" : true,
"proxy": { "proxy" : {
"/api": { "/api" : {
"target": "https://b.925i.cn", "target" : "https://b.925i.cn",
"changeOrigin": true, "changeOrigin" : true,
"secure": false, "secure" : false,
"pathRewrite": { "pathRewrite" : {
"^/api": "" "^/api" : ""
} }
} }
} }
} }
}, },
"_spaceID": "699a26a5-a6cd-4b54-b603-5155b312a5f5" "_spaceID" : "699a26a5-a6cd-4b54-b603-5155b312a5f5"
} }