import{B as R,ab as S}from"./MoreFeedback.7a64cae1.js";import{N as x,o,c as n,a as s,V as C,X as h,a0 as V,ab as w,l,A as F,aW as L,y as N,dN as E,B as I,m as D,R as H,ak as f,W as T,a1 as $,Y as v,Z as z,a7 as A,a8 as j}from"./index.2e2ba873.js";import{_ as O,e as W}from"./index.f1458219.js";import{u as Z,N as G}from"./App.4a38a252.js";import{_ as M}from"./plugin-vue_export-helper.21dcd24c.js";import"./style.488e5a30.js";import"./modulepreload-polyfill.b7f2da20.js";import"./ico_max_exit.795e9ef8.js";import"./index.36d4c5c3.js";import"./isUdf.1a76b9f4.js";import"./btn_devtools.210a42a8.js";import"./ico_pin.548219aa.js";/* empty css               */import"./theme-map.83df99de.js";import"./index.53c6cc19.js";const X={class:"precious_video_card"},Y={class:"precious_video_card--view"},q=["title"],J=x({__name:"PreciousVideoCard",props:{idx:Number,info:{type:Object,default:()=>({})},mediaList:{type:Object,default:null},rootRef:{type:Object}},setup(e){const c=e,t=()=>{c.info.bvid&&w({type:"ugc",bvid:c.info.bvid})};return(a,u)=>(o(),n("div",X,[s("div",Y,[C(h(R),{info:e.info.info,"img-lazy":"eager","is-rcmd":"","disable-frame":"","disable-scale":"",rootRef:e.rootRef,iid:"pc_app_hots_precious","scroll-wrap":".home_hots",isFirstCard:e.idx===0},null,8,["info","rootRef","isFirstCard"])]),s("div",{class:"precious_video_card--achievement bd_radius_sm flex_row cs_pointer text_ellipsis",onClick:t,title:e.info.achievement},V(e.info.achievement),9,q)]))}});const d=e=>(A("data-v-899edf0e"),e=e(),j(),e),K={class:"home_hots_precious"},Q={class:"home_hots--tabs--shim flex_end mb_lg"},U=d(()=>s("svg",{width:"10",height:"14",viewBox:"0 0 10 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[s("path",{d:"M9.3315 5.69705C10.2228 6.359 10.2228 7.641 9.33151 8.30294L2.80945 13.1465C1.66772 13.9945 0 13.221 0 11.8436V2.1564C0 0.77899 1.66772 0.00554585 2.80945 0.853451L9.3315 5.69705Z",fill:"currentColor"})],-1)),ee=d(()=>s("span",null,"\u64AD\u653E\u5168\u90E8",-1)),te=d(()=>s("span",{class:"gamepad-cursor"},null,-1)),oe={class:"row gutter_md"},se=d(()=>s("div",{class:"flex_center text3 lh_md fs_5 pb_xl"},"\u9646\u7EED\u66F4\u65B0\u4E2D\uFF0C\u656C\u8BF7\u671F\u5F85",-1)),ae=x({__name:"Precious",setup(e){const c=l(0),t=F([]),a=l(!1),u=l(0),g=l(""),k=L(),{homeHotsRef:B}=N(E());async function y(){var _;if(!a.value){a.value=!0;try{const i=await W();if(!((_=i.list)!=null&&_.length)){a.value=!1;return}u.value=i.media_id,g.value=i.title;const m=i.list.map((r,p)=>({info:S(r,p),bvid:r.bvid,achievement:r.achievement}));t.push(...m),a.value=!1,k.flashPageCursors(100)}catch(i){console.log(i),a.value=!1}}}Z("HomeHotsPrecious",()=>{c.value===1&&a.value||(t.splice(0,t.length),c.value=0,y())});const b=I(()=>({bizType:4,bizId:String(u.value),bizTitle:g.value})),P=()=>{w({type:"ugc",fromSpmid:"main.home-page-hot.0.0.pv",mediaList:b.value})};return D(()=>{t.length||y()}),(_,i)=>{const m=H("v-button");return o(),n("div",K,[s("div",Q,[t.length?(o(),f(m,{key:0,class:"play-all p_relative",type:"pink",onClick:P},{default:T(()=>[U,ee,te]),_:1})):$("",!0)]),t.length?(o(),n(v,{key:1},[s("div",oe,[(o(!0),n(v,null,z(t,(r,p)=>(o(),n("div",{class:"home_hots_preciousl--video col_3 col_sm_1_5 mb_xxl",key:r.bvid},[C(J,{info:r,idx:p,mediaList:h(b),rootRef:h(B)},null,8,["info","idx","mediaList","rootRef"])]))),128))]),se],64)):(o(),n(v,{key:0},[a.value?(o(),f(O,{key:0})):(o(),f(G,{key:1}))],64))])}}});var be=M(ae,[["__scopeId","data-v-899edf0e"]]);export{be as default};
