1import{_ as m,e as f}from"./_plugin-vue_export-helper-CZPp-EVN.js";import{P as u,j as s,q as o,x as e,K as c,L as g,M as d}from"./vendor-vue-n3skSn-P.js";const b={props:{rotateUrl:{type:String,required:!0},csrfToken:{type:String,required:!0},hasVideo2:{type:Boolean,default:!1}},data(){return{showingModal:!1,rotating:!1}},methods:{openModal(){this.showingModal=!0},closeModal(){this.showingModal=!1},submitRotation(){this.rotating=!0,axios.post(this.rotateUrl,{_token:this.csrfToken}).then(i=>{this.closeModal(),window.location.reload()}).catch(i=>{var t,l;this.rotating=!1,f.emit("alert",{success:!1,message:((l=(t=i.response)==null?void 0:t.data)==null?void 0:l.message)||"An error occurred while rotating videos."})})}}},y={class:"px-6 text-center p-2"},x={class:"text-gray-600 mb-4"},w={key:0},V={key:1},M={class:"mt-6 space-y-3"},h=["disabled"],k={key:0},v={key:1},_=["disabled"];function C(i,t,l,R,n,a){const p=u("modal-overlay");return s(),o("div",null,[e("button",{type:"button",class:"btn-primary px-4 py-2 text-sm flex items-center space-x-2",onClick:t[0]||(t[0]=r=>a.openModal())},[...t[4]||(t[4]=[e("i",{class:"fas fa-sync-alt"},null,-1),e("span",null,"Rotate Videos",-1)])]),c(p,{onModalClosed:t[3]||(t[3]=r=>a.closeModal()),showingModal:n.showingModal},{default:g(()=>[e("div",y,[t[8]||(t[8]=e("i",{class:"fas fa-sync-alt text-blue-500 mb-2 text-6xl"},null,-1)),t[9]||(t[9]=e("h5",{class:"text-lg font-semibold text-gray-900 mb-2"},"Rotate Latest Videos?",-1)),e("p",x,[t[5]||(t[5]=d(" This will swap Video 1 and Video 2 positions. ",-1)),l.hasVideo2?(s(),o("span",w,"Video 1 will become Video 2, and Video 2 will become Video 1.")):(s(),o("span",V,"Video 1 will be moved to position 2."))]),e("div",M,[e("button",{onClick:t[1]||(t[1]=r=>a.submitRotation()),disabled:n.rotating,class:"btn-primary w-full"},[n.rotating?(s(),o("span",k,[...t[6]||(t[6]=[e("i",{class:"fas fa-spin fa-spinner mr-2"},null,-1),d(" Rotating... ",-1)])])):(s(),o("span",v,[...t[7]||(t[7]=[e("i",{class:"fas fa-sync-alt mr-2"},null,-1),d(" Yes, Rotate Videos ",-1)])]))],8,h),e("button",{onClick:t[2]||(t[2]=r=>a.closeModal()),disabled:n.rotating,class:"btn-gray w-full"}," Cancel ",8,_)])])]),_:1},8,["showingModal"])])}const q=m(b,[["render",C]]);export{q as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.