import{j as o,E as x,B as n,d as u,T as d}from"./index-aa586041.js";import{T as g}from"./Tooltip-cc71425a.js";import{Z as E}from"./Zoom-e8e7722c.js";const F=({authorized_status:e,authorized_status_name:i})=>{const s=(()=>{let t="default";switch(e){case 1:t="warning";break;case 2:t="success";break;case 3:t="error";break;case 4:t="primary";break;default:t="primary"}return t})();return o.jsx(x,{variant:"outlined",disableRipple:!0,color:s,startIcon:o.jsx(n,{sx:t=>({width:"10px",height:"10px",bgcolor:t.palette[s].main,borderRadius:"50%"})}),sx:{width:100,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:i})},h=({priority:e,priority_name:i})=>{const t=(r=>{switch(r){case 1:return{bg:"#DEEEFE",text:"#0073EA"};case 2:return{bg:"#E5FCE2",text:"#138808"};case 3:return{bg:"#FFE9E9",text:"#E43B3B"};case 4:return{bg:"#E43B3B",text:"#FFFFFF"};default:return{bg:"#FFEEEE",text:"#EB2424"}}})(Number(e));return o.jsx(n,{sx:{borderRadius:"5px",backgroundColor:t.bg,color:t.text,width:"100px",height:"32px",padding:"0 8px",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"0.875rem",fontWeight:"500",textAlign:"center"},children:i})},w=({code:e,onClick:i,navigateUrl:s,tooltipTitle:t})=>o.jsx(g,{TransitionComponent:E,title:t,children:o.jsx(n,{sx:r=>{var a,l,c,p;return{color:r.palette.mode=="dark"?(l=(a=r==null?void 0:r.palette)==null?void 0:a.common)==null?void 0:l.white:(p=(c=r==null?void 0:r.palette)==null?void 0:c.primary)==null?void 0:p.main}},children:s?o.jsx(u,{to:s,style:{color:"inherit"},children:e}):o.jsx(d,{sx:{cursor:"pointer"},onClick:i,children:e})})});export{w as C,h as P,F as S};
