11 lines
5.2 KiB
JavaScript
11 lines
5.2 KiB
JavaScript
|
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["tuniao-ui/components/tn-nav-bar/tn-nav-bar"],{"0455":function(t,e,a){},"10ce":function(t,e,a){"use strict";a.r(e);var n=a("c9c2"),i=a.n(n);for(var r in n)["default"].indexOf(r)<0&&function(t){a.d(e,t,(function(){return n[t]}))}(r);e["default"]=i.a},"4bcb":function(t,e,a){"use strict";var n=a("0455"),i=a.n(n);i.a},"5d27":function(t,e,a){"use strict";a.r(e);var n=a("a223"),i=a("10ce");for(var r in i)["default"].indexOf(r)<0&&function(t){a.d(e,t,(function(){return i[t]}))}(r);a("4bcb");var s=a("f0c5"),u=Object(s["a"])(i["default"],n["b"],n["c"],!1,null,"ddf0c952",null,!1,n["a"],void 0);e["default"]=u.exports},a223:function(t,e,a){"use strict";a.d(e,"b",(function(){return n})),a.d(e,"c",(function(){return i})),a.d(e,"a",(function(){}));var n=function(){var t=this.$createElement,e=(this._self._c,this.__get_style([this.navBarStyle])),a=this.__get_style([this.barStyle]),n=this.__get_style([this.contentStyle]);this.$mp.data=Object.assign({},{$root:{s0:e,s1:a,s2:n}})},i=[]},c9c2:function(t,e,a){"use strict";(function(t,n){var i=a("4ea4");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=i(a("2eee")),s=i(a("c973")),u=i(a("16ca")),o={name:"tn-nav-bar",mixins:[u.default],props:{zIndex:{type:Number,default:0},height:{type:Number,default:0},unit:{type:String,default:"px"},isBack:{type:Boolean,default:!0},backIcon:{type:String,default:"left"},backTitle:{type:String,default:"返回"},alpha:{type:Boolean,default:!1},fixed:{type:Boolean,default:!0},bottomShadow:{type:Boolean,default:!0},customBack:{type:Boolean,default:!1},beforeBack:{type:Function,default:null}},computed:{navBarStyle:function(){var t={};return t.height=0===this.height?this.customBarHeight+this.unit:this.height+this.unit,this.fixed&&(t.position="fixed"),t.zIndex=this.elZIndex,t},barClass:function(){var t="";return this.backgroundColorClass&&(t+=" ".concat(this.backgroundColorClass)),this.fontColorClass&&(t+="".concat(this.fontColorClass)),this.fixed&&(t+=" tn-custom-nav-bar__bar--fixed"),this.alpha&&(t+=" tn-custom-nav-bar__bar--alpha"),this.bottomShadow&&(t+=" tn-custom-nav-bar__bar--bottom-shadow"),t},barStyle:function(){var t={};return t.height=0===this.height?this.customBarHeight+this.unit:this.height+this.unit,this.fixed&&(t.paddingTop=this.statusBarHeight+"px"),this.backgroundColorClass||(t.backgroundColor=""!==this.backgroundColor?this.backgroundColor:"#FFFFFF"),!this.fontColorClass&&this.fontColor&&(t.color=this.fontColor),t.zIndex=this.elZIndex,t},contentStyle:function(){var t={};if(t.top=this.fixed?this.statusBarHeight+"px":"0px",t.height=0===this.height?this.customBarHeight-this.statusBarHeight+this.unit:this.height+this.unit,t.lineHeight=t.height,this.isBack)if(this.customBack){var e=2*(this.customBackStyleInfo.width+this.customBackStyleInfo.left);t.width="calc(100% - ".concat(e,"px)")}else t.width="calc(100% - 340rpx)";else t.width="100%";return t},elZIndex:function(){return this.zIndex?this.zIndex:this.$tn.zIndex.navbar}},data:function(){return{statusBarHeight:0,customBarHeight:0,customBackStyleInfo:{width:86,height:32,left:15}}},mounted:function(){this.updateNavBarInfo()},created:function(){var e=t.getMenuButtonBoundingClientRect();this.customBackStyleInfo.width=e.width,this.customBackStyleInfo.height=e.height,this.customBackStyleInfo.left=n.upx2px(750)-e.right},methods:{updateNavBarInfo:function(){var t=this;return(0,s.default)(r.default.mark((function e(){var a,n,i;return r.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(a=t.vuex_custom_bar_height,n=t.vuex_status_bar_height,a){e.next=15;break}return e.prev=3,e.next=6,t.$tn.updateCustomBar();case 6:i=e.sent,a=i.customBarHeight,n=i.statusBarHeight,e.next=15;break;case 11:return e.prev=11,e.t0=e["catch"](3),setTimeout((function(){t.updateNavBarInfo()}),10),e.abrupt("return");case 15:t&&t.$tn.vuex("vuex_status_bar_height",n),t&&t.$tn.vuex("vuex_custom_bar_height",a),t.customBarHeight=a,t.statusBarHeight=n;case 19:case"end":return e.stop()}}),e,null,[[3,11]])})))()},handlerBack:function(){var t=this;return(0,s.
|
||
|
;(global["webpackJsonp"] = global["webpackJsonp"] || []).push([
|
||
|
'tuniao-ui/components/tn-nav-bar/tn-nav-bar-create-component',
|
||
|
{
|
||
|
'tuniao-ui/components/tn-nav-bar/tn-nav-bar-create-component':(function(module, exports, __webpack_require__){
|
||
|
__webpack_require__('543d')['createComponent'](__webpack_require__("5d27"))
|
||
|
})
|
||
|
},
|
||
|
[['tuniao-ui/components/tn-nav-bar/tn-nav-bar-create-component']]
|
||
|
]);
|