"use strict";const e=require("../../../common/vendor.js"),r=require("../../index.js");if(require("../../url/index.js"),require("../../store/index.js"),require("../../store/app.js"),require("../../api/promotion/diy.js"),require("../../request/index.js"),require("../../config/index.js"),require("../../platform/index.js"),require("../../platform/provider/wechat/index.js"),require("../../platform/provider/wechat/miniProgram.js"),require("../../api/member/auth.js"),require("../../api/member/social.js"),require("../../api/member/user.js"),require("../../platform/provider/apple/index.js"),require("../../platform/share.js"),require("../../router/index.js"),require("../../hooks/useModal.js"),require("../../helper/index.js"),require("../../helper/test.js"),require("../../helper/digit.js"),require("../../api/member/signin.js"),require("../../helper/throttle.js"),require("../../platform/pay.js"),require("../../api/pay/order.js"),require("../../store/user.js"),require("../../store/cart.js"),require("../../api/trade/cart.js"),require("../../api/pay/wallet.js"),require("../../api/trade/order.js"),require("../../api/promotion/coupon.js"),require("../../store/sys.js"),require("../../store/modal.js"),require("../../config/zIndex.js"),!Array){e.resolveComponent("s-live-card")()}Math;const i={__name:"s-live-block",props:{data:{type:Object,default(){}},styles:{type:Object,default(){}}},setup(i){const o=e.reactive({liveList:[],mpLink:""}),a=i,{mode:s,goodsFields:t,mpliveIds:d}=a.data??{};function u(r){e.index.navigateTo({url:`plugin-private://wx2b03c6e691cd7370/pages/live-player-plugin?room_id=${r}`})}return a.styles,e.onMounted((async()=>{o.liveList=await async function(e){const{data:i}=await r.sheep.$api.app.mplive.getRoomList(e);return i}(d)})),(r,a)=>e.e({a:2===e.unref(s)&&o.liveList.length},2===e.unref(s)&&o.liveList.length?{b:e.f(o.liveList,((r,o,a)=>{var s,d;return{a:e.o((e=>u(r.roomid)),r.id),b:"6e9c3a73-0-"+a,c:e.p({size:"md",goodsFields:e.unref(t),data:r,titleColor:null==(s=e.unref(t).name)?void 0:s.color,subTitleColor:null==(d=e.unref(t).anchor_name)?void 0:d.color,topRadius:i.data.borderRadiusTop,bottomRadius:i.data.borderRadiusBottom}),d:r.id}})),c:e.s({padding:i.data.space+"rpx"}),d:e.s({margin:"-"+i.data.space+"rpx"})}:{},{e:1===e.unref(s)&&o.liveList.length},1===e.unref(s)&&o.liveList.length?{f:e.f(o.liveList,((r,o,a)=>{var s;return{a:e.o((e=>u(r.roomid)),r.id),b:"6e9c3a73-1-"+a,c:e.p({size:"sl",goodsFields:e.unref(t),data:r,titleColor:null==(s=e.unref(t).name)?void 0:s.color,subTitleColor:e.unref(t).anchor_name.color,topRadius:i.data.borderRadiusTop,bottomRadius:i.data.borderRadiusBottom}),d:r.id}})),g:e.s({marginBottom:i.data.space+"px"})}:{})}},o=e._export_sfc(i,[["__scopeId","data-v-6e9c3a73"]]);wx.createComponent(o);
