(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-dadba682"],{"0790":function(t,i,e){"use strict";var a=function(){var t=this,i=t.$createElement,e=t._self._c||i;return e("van-nav-bar",{attrs:{title:t.title,"left-text":"","left-arrow":""},on:{"click-left":t.back}},[e("van-icon",{attrs:{slot:"left",name:t.backHome?"wap-home":"arrow-left"},slot:"left"})],1)},o=[],s={name:"NavBar",data:function(){return{backHome:!1}},props:{title:{type:String,required:!0,default:""}},created:function(){this.$util.sessionStorage.fetch("backHome")&&(this.backHome=!0)},mounted:function(){},methods:{back:function(){this.backHome?(this.$util.sessionStorage.remove("backHome"),this.$router.push("/")):window.history.length>1?window.history.go(-1):this.$router.push("/")}}},n=s,r=(e("ba46"),e("2877")),l=Object(r["a"])(n,a,o,!1,null,"530892b0",null);l.options.__file="NavBar.vue";i["a"]=l.exports},3074:function(t,i,e){"use strict";var a=e("a4b0"),o=e.n(a);o.a},3562:function(t,i,e){t.exports=e.p+"img/loading.c2fcdc24.gif"},"8d1f":function(t,i,e){},a4b0:function(t,i,e){},ac6a:function(t,i,e){for(var a=e("cadf"),o=e("0d58"),s=e("2aba"),n=e("7726"),r=e("32e9"),l=e("84f2"),c=e("2b4c"),d=c("iterator"),u=c("toStringTag"),h=l.Array,p={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},f=o(p),m=0;m<f.length;m++){var v,g=f[m],L=p[g],S=n[g],k=S&&S.prototype;if(k&&(k[d]||r(k,d,h),k[u]||r(k,u,g),l[g]=h,L))for(v in a)k[v]||s(k,v,a[v],!0)}},ba46:function(t,i,e){"use strict";var a=e("8d1f"),o=e.n(a);o.a},d31b:function(t,i,e){"use strict";e.r(i);var a=function(){var t=this,i=t.$createElement,a=t._self._c||i;return a("div",{staticClass:"page-article"},[t.isInHooliApp?t._e():a("nav-bar",{attrs:{title:"文章详情"}}),t.isLoading?a("div",{attrs:{id:"loading"}},[a("img",{attrs:{src:e("3562"),alt:""}})]):t._e(),t.articleDetail&&!t.isLoading?a("div",{staticClass:"article-wrap"},[a("p",{staticClass:"title"},[t._v(t._s(t.articleDetail.title))]),a("p",{staticClass:"time"},[t._v(t._s(t.articleDetail.createTime))]),a("ul",{staticClass:"tags"},t._l(t.articleDetail.sign,function(i,e){return a("li",{key:e,staticClass:"item"},[t._v(t._s(i))])})),a("div",{staticClass:"ql-container"},[a("div",{staticClass:"content ql-editor",domProps:{innerHTML:t._s(t.articleDetail.content)}})])]):t._e(),t.articleDetail||t.isLoading?t._e():a("div",{staticClass:"noneData"},[a("img",{attrs:{src:"https://static.hoolihome.com/m/images/serviceError.png",alt:""}}),a("p",[t._v("哎呀，文章不存在了")])])],1)},o=[],s=(e("ac6a"),e("0790")),n={components:{NavBar:s["a"]},data:function(){return{isInHooliApp:!1,isLoading:!0,articleDetail:null}},created:function(){(this.$util.checkIsHooliAndroid()||this.$util.checkIsHooliIos())&&(this.isInHooliApp=!0),this.$util.checkIsHooliAndroid()?this.env="android":this.$util.checkIsHooliIos()&&(this.env="ios");var t=this.$route.params.articleId;t&&this.loadDetail(t)},mounted:function(){},methods:{loadDetail:function(t){var i=this,e={};e.url=this.$apis.api_v3_find_details,e.data={id:t},this.$net.req(e,this).then(function(t){if(i.isLoading=!1,t){var e=t.data;if(e){i.articleDetail=e,i.dealImgs(),i.handleAppButton();var a={title:e.share.shareTitle||"hoolihome",desc:e.share.shareContent||"",link:e.share.shareUrl||"http://m.hoolihome.com",img_url:e.share.shareImgUrl||""};i.$util.checkIsWeixin()?i.$net.wxShare(a):(i.$util.checkIsHooliAndroid()||i.$util.checkIsHooliIos())&&(i.handleAppLogic(),i.$net.doHooliShare(a))}}},function(t){i.isLoading=!1,i.$Toast(t.msg),i.$router.push({path:"/"})})},dealImgs:function(){this.$nextTick(function(){var t=document.querySelectorAll(".page-article .content img");t&&t.length>0&&t.forEach(function(t){t.style.width="100%",t.style.height="auto"})})},handleAppButton:function(){if(this.isInHooliApp){var t={type:9,data:{title:"文章详情"}};t=encodeURIComponent(JSON.stringify(t)),"android"===this.env?window.Android.javaScriptToNative(t):"ios"===this.env&&window.webkit.messageHandlers.javaScriptToNative.postMessage(t)}},handleAppLogic:function(){var t=this;window.AppCallback={},window.nativeToJavaScript=function(i){try{if(i){i=JSON.parse(decodeURIComponent(i));var e=parseInt(i.type),a=i.data;t.$util.checkIsHooliAndroid()&&(a=JSON.parse(a)),window.AppCallback[e]=a}}catch(o){}}}}},r=n,l=(e("3074"),e("2877")),c=Object(l["a"])(r,a,o,!1,null,"831df69c",null);c.options.__file="article.vue";i["default"]=c.exports}}]);
//# sourceMappingURL=chunk-dadba682.d00a0f06.js.map