import{aj as $,z as d,D as C,k as D,F as B,c as I,o as f,ab as a,p as m,m as E,f as h,a7 as L,t as N,g as r,ai as O}from"./index-DpP8vbvu.js";/* empty css                 */import"./el-tag-CjAzCWMf.js";import{E as J,a as R}from"./el-select-BvsCrs4t.js";import"./el-scrollbar-DIXSy-7M.js";import{s as U,a as M}from"./star-DxhhrwZA.js";import{e as z}from"./index-v7AaNdhX.js";import{u as A}from"./email-BqixZxSP.js";import{a as F,b as P}from"./all-email-hZpif8BK.js";import{I as u}from"./iconify-CxZjXnJf.js";import{_ as q}from"./_plugin-vue_export-helper-DlAUqK2U.js";import{E as G}from"./vnode-DPqF99Zc.js";import"./index-BMdPKuCq.js";import"./index-dQfRzLGT.js";import"./index-D7KcZu8a.js";import"./event-BB_Ol6Sd.js";import"./time-utils-B0cDvgwY.js";import"./position-5hNBDW7r.js";import"./throttle-BCwYugI2.js";import"./el-empty-BRrnteWe.js";import"./el-tooltip-l0sNRNKZ.js";import"./el-checkbox-DjYzjb3f.js";import"./index-Bm-x70H-.js";import"./day-B6NtfdPE.js";import"./dayjs.min-BjOfKEma.js";/* empty css                       *//* empty css                  */import"./index-CcAtbSPY.js";import"./index-BWeK8p2T.js";const H={class:"email-list-box"},K={class:"search-type"},Q=Object.assign({name:"all-email"},{__name:"index",setup(W){const{t:i}=$(),c=A(),p=d({}),o=d(""),y=d(),k=()=>{y.value.toggleMenu()},e=C({timeSort:0,type:"receive",userEmail:null,accountEmail:null,name:null,subject:null,searchType:"name"}),g=D(()=>{if(e.searchType==="user")return i("user");if(e.searchType==="account")return i("selectEmail");if(e.searchType==="name")return i("sender");if(e.searchType==="subject")return i("subject")}),b=localStorage.getItem("all-email-params");if(b){const l=JSON.parse(b);e.type=l.type,e.timeSort=l.timeSort,e.status=l.status,e.searchType=l.searchType}B(()=>e,()=>{localStorage.setItem("all-email-params",JSON.stringify(e))},{deep:!0});function T(){o.value=null,e.timeSort=0,e.type="receive",e.userEmail=null,e.accountEmail=null,e.name=null,e.subject=null,e.searchType="name"}function w(){e.userEmail=null,e.accountEmail=null,e.name=null,e.subject=null,e.searchType==="user"&&(e.userEmail=o.value),e.searchType==="account"&&(e.accountEmail=o.value),e.searchType==="name"&&(e.name=o.value),e.searchType==="subject"&&(e.subject=o.value),p.value.refreshList()}function v(){e.timeSort=e.timeSort?0:1,p.value.refreshList()}function _(l){c.contentData.email=l,c.contentData.delType="physics",c.contentData.showStar=!1,c.contentData.showReply=!1,O.push({name:"content"})}function j(l,s){return P({emailId:l,size:s,...e})}return(l,s)=>{const t=R,S=J,V=G;return f(),I("div",H,[a(z,{ref_key:"sysEmailScroll",ref:p,"get-emailList":j,"email-delete":r(F),"star-add":r(M),"star-cancel":r(U),"show-star":!1,"show-user-info":"","show-status":"",actionLeft:"4px","show-account-icon":!1,onJump:_,onRefreshBefore:T,type:"all-email"},{first:m(()=>[a(V,{modelValue:o.value,"onUpdate:modelValue":s[1]||(s[1]=n=>o.value=n),placeholder:l.$t("searchByContent"),class:"search-input"},{prefix:m(()=>[h("div",{onClick:L(k,["stop"])},[a(S,{ref_key:"mySelect",ref:y,modelValue:e.searchType,"onUpdate:modelValue":s[0]||(s[0]=n=>e.searchType=n),placeholder:l.$t("select"),class:"select"},{default:m(()=>[a(t,{key:"3",label:l.$t("sender"),value:"name"},null,8,["label"]),a(t,{key:"4",label:l.$t("subject"),value:"subject"},null,8,["label"]),a(t,{key:"1",label:l.$t("user"),value:"user"},null,8,["label"]),a(t,{key:"2",label:l.$t("selectEmail"),value:"account"},null,8,["label"])]),_:1},8,["modelValue","placeholder"]),h("div",K,[h("span",null,N(g.value),1),a(r(u),{class:"setting-icon",icon:"mingcute:down-small-fill",width:"20",height:"20"})])])]),_:1},8,["modelValue","placeholder"]),a(S,{modelValue:e.type,"onUpdate:modelValue":s[2]||(s[2]=n=>e.type=n),placeholder:"Select",class:"status-select"},{default:m(()=>[a(t,{key:"1",label:l.$t("all"),value:"all"},null,8,["label"]),a(t,{key:"3",label:l.$t("received"),value:"receive"},null,8,["label"]),a(t,{key:"2",label:l.$t("sent"),value:"send"},null,8,["label"]),a(t,{key:"4",label:l.$t("selectDeleted"),value:"delete"},null,8,["label"]),a(t,{key:"4",label:l.$t("noRecipientTitle"),value:"noone"},null,8,["label"])]),_:1},8,["modelValue"]),a(r(u),{class:"icon",icon:"iconoir:search",onClick:w,width:"20",height:"20"}),e.timeSort===0?(f(),E(r(u),{key:0,class:"icon",onClick:v,icon:"material-symbols-light:timer-arrow-down-outline",width:"28",height:"28"})):(f(),E(r(u),{key:1,class:"icon",onClick:v,icon:"material-symbols-light:timer-arrow-up-outline",width:"28",height:"28"}))]),_:1},8,["email-delete","star-add","star-cancel"])])}}}),_e=q(Q,[["__scopeId","data-v-18a62af2"]]);export{_e as default};
