PageSourceSearch

https://www.dutying.ai/assets/confirmed-shifts-JhDOd-hn.js

js dutying.ai collected 2026-10-05 15:15:10 UTC 19,998 bytes, 3 lines download raw bytes

1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/exceljs.min-DbBw0wFx.js","assets/index-BENu7BMa.js","assets/index-Bu_rrwIg.css","assets/_commonjs-dynamic-modules-TDtrdbi3.js"])))=>i.map(i=>d[i]);
2import{t as v,u as U,r as y,i as me,j as s}from"./index-BENu7BMa.js";import{u as X}from"./useQuery-D56p6FyV.js";import{z as B,u as fe,s as Q,q as V}from"./store-CJDE6Ye6.js";import{w as Z}from"./queries-B16SrjaC.js";import{g as ue,a as he}from"./display-BXyIq9kj.js";import{g as pe}from"./queries-P3_b7Cj5.js";import{u as ge,a as xe,c as we,S as ye,M as Se}from"./schedule-display-menu-DIzBmQhj.js";import{s as Ee}from"./draft-status-store-8jcDFVQr.js";import{_ as te}from"./index-D7qR0rFq.js";import"./index-OAabqcBU.js";import"./store-BaNmgh8g.js";import{B as ae,P as z}from"./index-DeUO8gHu.js";import"./index-CDCYQ2ls.js";import"./index-BCtCSYwa.js";import"./shift-workflow-status-CDGE7s5N.js";import"./switch-B3M0Zfrm.js";import"./input-DkI0Mxqw.js";import{u as be}from"./rest-leave-policy-CjqIxr-V.js";import{a as ie,b as re,c as oe,T as se}from"./tooltip-DlYd4HIK.js";import{W as ve}from"./index-YDMqcXHK.js";import{u as D,i as Te}from"./make-shift-events-CoTs_ldJ.js";import{u as ke,d as Ie}from"./index-5N8obcsV.js";import{s as Ae}from"./format-nurse-display-name-CFBup1Zj.js";import{u as _e,a as Ne}from"./rest-leave-policy-summary-card-auY923Ve.js";import{M as je}from"./make-shift-calendar-C8HheUcv.js";import{e as Ce,D as Le}from"./excel-CU5f4nSS.js";import{a as Me,d as Y}from"./dropdown-styles-qiBEjeB4.js";import{I as De}from"./info-D3qKnnWW.js";import"./useBaseQuery-BlZB6-wt.js";import"./exports-CtrTWOsN.js";import"./skeleton-BIh8rb_4.js";import"./shift-short-name-Cd_nX2tv.js";import"./app-client-Dt3Xnylu.js";import"./initializeApp-DSgj0sv4.js";import"./index-C4fpX3vj.js";import"./index-CAc79DlG.js";import"./useMutation-BaIR7oQe.js";import"./index-DOk0eE7W.js";import"./x-i3F6v2ld.js";import"./ui-D4b6FORF.js";import"./index-BRKyniKP.js";import"./index-wi1jRNlr.js";import"./feedback-ntePx0j0.js";import"./loader-circle-B5zroF3E.js";import"./check-C0Hhwgra.js";import"./calendar-plus-Dcv_0i0H.js";import"./TutorialPortal-CrUghUoc.js";import"./minus-1eZxsTbj.js";import"./plus-DHorVSK5.js";import"./settings-BOUFew9j.js";import"./dnd.esm-D04mqKaW.js";import"./index-CbL6zi-s.js";import"./PersonIcon-pV7KOCH_.js";import"./pin-m2sh4RzM.js";import"./chevron-down-Dv4mWvDu.js";const Re="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";function Fe(t){return v.t("feature.shiftEditor.export.excel.fileName",{month:t})}function Oe(t){return v.t("feature.shiftEditor.export.excel.sheetName",{month:t})}function We(t){return v.t("feature.shiftEditor.export.excel.title",{month:t})}function Be(t,e){const o=new Blob([t],{type:Re}),r=window.URL.createObjectURL(o),a=document.createElement("a");a.href=r,a.download=e,a.click(),window.URL.revokeObjectURL(r)}const Pe=async(t,e)=>{const o=await te(()=>import("./exceljs.min-DbBw0wFx.js").then(d=>
2d.e),__vite__mapDeps([0,1,2,3])),r=e.divisionShiftNurses.flatMap(d=>d),a=new o.Workbook,i=a.addWorksheet(Oe(t)),c=Math.max(12,...r.map(({shiftNurse:d})=>Array.from(d.name).reduce((l,f)=>l+(f.charCodeAt(0)>255?2:1),2)));i.columns=[{key:"name",width:c,style:{alignment:{horizontal:"center",vertical:"middle"}}},{key:"lastShift",width:10,style:{alignment:{horizontal:"center",vertical:"middle"}}},...e.days.map(d=>({key:d.day.toString(),width:3,style:{alignment:{horizontal:"center",vertical:"middle"}}})),...e.wardShiftTypes.map(d=>({key:d.shortName,width:8,style:{alignment:{horizontal:"center",vertical:"middle"}}})),{key:"WO",width:8,style:{alignment:{horizontal:"center",vertical:"middle"}}}];const n=i.addRow({name:We(t)});n.font={bold:!0,size:16},n.alignment={horizontal:"left"},n.height=30,i.mergeCells(1,1,1,i.columnCount),i.views=[{state:"frozen",xSplit:2,ySplit:2}];const p=i.addRow({name:v.t("feature.shiftEditor.export.excel.nameHeader"),lastShift:v.t("feature.shiftEditor.export.excel.previousShiftHeader"),...e.days.reduce((d,l,f)=>(d[f+1]=l.day,d),{}),...e.wardShiftTypes.reduce((d,l)=>(d[l.shortName]=l.shortName,d),{}),O:"O",WO:"WO"});e.days.map(d=>{p.getCell(d.day.toString()).font={color:{argb:d.dayType==="workday"?"FF000000":d.dayType==="saturday"?"FF2029FA":"FFFA2D12"}}}),r.map(d=>i.addRow({name:d.shiftNurse.name,lastShift:d.lastWardShiftList.map(l=>l!==null?e.wardShiftTypes.find(f=>f.wardShiftTypeId===l).shortName:"").join(""),...d.wardShiftList.reduce((l,f,x)=>(l[x+1]=f!=null?e.wardShiftTypes.find(w=>w.wardShiftTypeId===f).shortName:"",l),{}),...e.wardShiftTypes.reduce((l,f)=>(l[f.shortName]=d.wardShiftList.filter(x=>x===f.wardShiftTypeId).length,l),{}),WO:d.wardShiftList.filter((l,f)=>e.wardShiftTypes.find(x=>x.wardShiftTypeId===l)?.isOff===!0&&e.days.find(x=>x.day===f+1)?.dayType!="workday").length})),e.wardShiftTypes.map(d=>{i.addRow({lastShift:d.name,...e.days.reduce((l,f,x)=>(l[x+1]=r.filter(w=>w.wardShiftList[x]===d.wardShiftTypeId).length,l),{})})});const m=await a.xlsx.writeBuffer();return Be(m,Fe(t)),a};function ze(t){const e=Array.from(t.querySelectorAll(".make-shift-calendar__row-name[title]"));if(e.length===0)return{element:t,dispose:()=>{}};const o=Math.max(t.scrollWidth,t.clientWidth),r=Math.max(...e.map(i=>i.getBoundingClientRect().width)),a=t.cloneNode(!0);a.setAttribute("aria-hidden","true"),a.style.position="fixed",a.style.left="-100000px",a.style.top="0",a.style.width=`${o}px`,a.style.maxWidth="none",a.style.pointerEvents="none",(t.parentElement??document.body).appendChild(a);try{let i=r;return a.querySelectorAll(".make-shift-calendar__row-name[title]").forEach(c=>{const n=document.createElement("span");n.textContent=c.title,n.style.flexShrink="0",n.style.whiteSpace="pre",c.replaceChildren(n),c.style.overflow="visible",c.style.textOverflow="clip",c.style.fontSize=window.getComputedStyle(c).fontSize,i=Math.max(i,n.getBoundingClientRect().width+16)}),i=Math.ceil(i),a.style.setProperty("--make-shift-name-column-width",`${i}px`),a.style.width=`${Math.ceil(o+i-r)}px`,a.querySelectorAll('[data-sticky-header="true"]').forEach(c=>{c.style.position="static"}),{element:a,dispose:()=>a.remove()}}catch(i){throw a.remove(),i}}const R=3508,q=2480,H=172,ne=140,He=132,Ge=68,Ue=42,G=252,le="#FFFFFF",$e="/img/group-19.png";function Ke(t){return t.replace(/[\\/:*?"<>|]/g," ").replace(/\s+/g," ").trim()}function J(t){return t?.replace(/\s+/g," ").trim()??""}function qe({year:t,month:e,teamName:o}){const r=o?Ke(o):"",a=v.t("feature.shiftEditor.export.image.fileName",{year:t,month:e});return r?v.t("feature.shiftEditor.export.image.teamFileName",{year:t,month:e,teamName:r}):a}function Xe({year:t,month:e,hospitalName:o,wardName:r}){const a=[J(o),J(r)].filter(Boolean).join(" ");return a?v.t("feature.shiftEditor.export.image.titleWithWard",{year:t,month:e,wardLabel:a}):v.t("feature.shiftEditor.export.image.title",{year:t,month:e})}function Qe(t,e){const o=window.URL.createObjectURL(t),r=document.createElement("a");r.href=o,r.download=e,r.click(),window.URL.revokeObjectURL(o)}function ce(t){return new Promise((e,o)=>{const r=new Image;r.onload=()=>e(r),r.onerror=()=>o(new Error("SHIFT_IMAGE_EXPORT_IMAGE_LOAD_FAILED")),r.src=t})}async function Ve(t){const e=window.URL.createObjectURL(t);try{return await ce(e)}finally{window.URL.revokeObjectURL(e)}}function Ze(t){return new Promise((e,o)=>{t.toBlob(r=>{if(!r){o(new Error("SHIFT_IMAGE_EXPORT_FAILED"));return}e(r)},"image/png")})}function ee(t,e){t.font=`700 ${e}px "Apple SD Gothic Neo", "Noto Sans KR", Arial, sans-serif`}function Ye(t,e){const o=R-H*2;let r=Ge;for(ee(t,r);r>Ue&&t.measureText(e).width>o;)r-=2,ee(t,r);
2t.fillStyle="#17142F",t.textBaseline="top",t.fillText(e,H,He,o)}function Je(t,e){const o=R-H*2,r=q-G-ne,a=e.naturalWidth||e.width,i=e.naturalHeight||e.height,c=Math.min(o/a,r/i,1),n=Math.round(a*c),p=Math.round(i*c),m=Math.round((R-n)/2);t.drawImage(e,m,G,n,p)}function et(t,e){const o=e.naturalWidth||e.width,r=e.naturalHeight||e.height,a=o/r,i=Math.round(Math.min(R*.58,R-H*2)),c=Math.round(i/a),n=Math.round((R-i)/2),p=Math.round(G+(q-G-ne-c)/2);t.save(),t.globalAlpha=.055,t.filter="blur(7px)",t.drawImage(e,n,p,i,c),t.restore()}async function tt({sourceBlob:t,title:e}){const[o,r]=await Promise.all([Ve(t),ce($e).catch(()=>null)]),a=document.createElement("canvas"),i=a.getContext("2d");if(!i)throw new Error("SHIFT_IMAGE_EXPORT_FAILED");return a.width=R,a.height=q,i.fillStyle=le,i.fillRect(0,0,a.width,a.height),i.imageSmoothingEnabled=!0,i.imageSmoothingQuality="high",Je(i,o),r&&et(i,r),Ye(i,e),Ze(a)}async function at({element:t,year:e,month:o,teamName:r,hospitalName:a,wardName:i}){const{toBlob:c}=await te(async()=>{const{toBlob:l}=await import("./index-0pJihu0A.js");return{toBlob:l}},[]);await document.fonts?.ready;const n=ze(t);let p;try{p=await c(n.element,{backgroundColor:le,filter:l=>!(l instanceof Element&&l.hasAttribute("data-private-annual-leave")),cacheBust:!0,pixelRatio:2,width:Math.max(n.element.scrollWidth,n.element.clientWidth),height:Math.max(n.element.scrollHeight,n.element.clientHeight),style:{position:"static",left:"auto",top:"auto"}})}finally{n.dispose()}if(!p)throw new Error("SHIFT_IMAGE_EXPORT_FAILED");const m=qe({year:e,month:o,teamName:r}),d=await tt({sourceBlob:p,title:Xe({year:e,month:o,hospitalName:a,wardName:i})});return Qe(d,m),m}function it({month:t,shift:e,disabled:o=!1}){const{t:r}=U(),[a,i]=y.useState(!1),c=y.useCallback(async()=>{if(!(o||a||!e)){i(!0);try{await Pe(t,e),B.success(r("feature.shiftEditor.export.excel.success"))}catch(n){console.error(n),B.error(r("feature.shiftEditor.export.excel.failure"))}finally{i(!1)}}},[o,a,t,e,r]);return{isExporting:a,exportExcel:c}}function rt(){return new Promise(t=>{window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>t())})})}function ot({targetRef:t,year:e,month:o,teamName:r,hospitalName:a,wardName:i,disabled:c=!1}){const{t:n}=U(),[p,m]=y.useState(!1),d=y.useCallback(async()=>{if(c||p)return;const l=t.current;if(!l){B.error(n("feature.shiftEditor.export.image.targetMissing"));return}m(!0);try{await rt(),await at({element:l,year:e,month:o,teamName:r,hospitalName:a,wardName:i}),B.success(n("feature.shiftEditor.export.image.success"))}catch(f){console.error(f),B.error(n("feature.shiftEditor.export.image.failure"))}finally{m(!1)}},[c,a,p,o,t,r,n,i,e]);return{isExporting:p,downloadImage:d}}function st(t){const e=me.c(35),{disabled:o,isExporting:r,label:a,onDownloadImage:i,onDownloadExcel:c}=t,{t:n}=U(),[p,m]=y.useState(!1),d=y.useRef(null),l=y.useRef(null),f=y.useRef(null),x=y.useId(),w=p&&!o;let b,I;e[0]!==w?(b=()=>{if(!w)return;f.current?.querySelector("button")?.focus();const u=_=>{d.current?.contains(_.target)||m(!1)};return document.addEventListener("pointerdown",u),()=>document.removeEventListener("pointerdown",u)},I=[w],e[0]=w,e[1]=b,e[2]=I):(b=e[1],I=e[2]),y.useEffect(b,I);let C;e[3]!==o?(C=u=>{o||(m(!1),l.current?.focus(),u())},e[3]=o,e[4]=C):C=e[4];const F=C;let L;e[5]===Symbol.for("react.memo_cache_sentinel")?(L=u=>{u.currentTarget.contains(u.relatedTarget)||m(!1)},e[5]=L):L=e[5];const O=w?x:void 0,g=r||void 0;let A;e[6]!==p?(A=()=>m(!p),e[6]=p,e[7]=A):A=e[7];let M;e[8]===Symbol.for("react.memo_cache_sentinel")?(M=u=>{u.key==="ArrowDown"&&(u.preventDefault(),m(!0))},e[8]=M):M=e[8];const S=`size-5 ${r?"animate-pulse":""}`;let E;e[9]!==S?(E=s.jsx(Le,{className:S,strokeWidth:1.8,"aria-hidden":"true"}),e[9]=S,e[10]=E):E=e[10];let T;e[11]!==o||e[12]!==a||e[13]!==w||e[14]!==E||e[15]!==O||e[16]!==g||e[17]!==A?(T=s.jsx(ie,{asChild:!0,children:s.jsx(ae,{ref:l,variant:"secondary",size:"md",type:"button","aria-label":a,title:a,"aria-haspopup":"menu","aria-expanded":w,"aria-controls":O,"aria-busy":g,className:"size-10 cursor-pointer rounded-[12px] border border-gray-6 bg-white p-0 text-gray-3 shadow-none hover:bg-gray-7 hover:text-sub-1 focus-visible:ring-1 focus-visible:ring-main-1 focus-visible:ring-offset-0 disabled:bg-gray-7 disabled:text-gray-4",onClick:A,onKeyDown:M,disabled:o,children:E})}),e[11]=o,e[12]=a,e[13]=w,e[14]=E,e[15]=O,e[16]=g,e[17]=A,e[18]=T):T=e[18];let N;e[19]!==a?(N=s.jsx(re,{side:"top",className:"rounded-full bg-[#1C2331] px-3 py-1.5 text-[12px] font-semibold text-white",children:a}),e[19]=a,e[20]=N):N=e[20];let j;e[21]!==T||e[22]!==N?(j=s.jsx(oe,{delayDuration:120,children:s.jsxs(se,{children:[T,N]})}),e[21]=T,e[22]=N,e[23]=j):j=e[23];let k;e[24]!==F||e[25]!==x||e[26]!==a||e[27]!==w||e[28]!==c||e[29]!==i||e[30]!==n?(k=w&&s.jsxs("div",{ref:f,id:x,role:"menu","aria-label":a,className:`${Me} absolute top-full right-0 mt-2 min-w-48`,onKeyDown:u=>{if(u.stopPropagation(),u.key==="Escape"&&(u.preventDefault(),m(!1),l.current?.focus()),["ArrowDown","ArrowUp","Home","End"].includes(u.key)){u.preventDefault();const _=Array.from(f.current?.querySelectorAll('[role="menuitem"]')??[]),P=_.indexOf(document.activeElement),$=u.key==="Home"?0:u.key==="End"?_.length-1:(P+(u.key==="ArrowDown"?1:-1)+_.length)%_.length;_[$]?.focus()}},children:[s.jsxs("button",{type:"button",role:"menuitem",className:`${Y} justify-start gap-2.5 text-left text-sub-1`,onClick:()=>F(i),children:[s.jsx("span",{className:"flex size-8 shrink-0 items-center justify-center","aria-hidden":"true",children:s.jsxs("svg",{viewBox:"0 0 24 24",className:"size-6",focusable:"false",children:[s.jsx("rect",{x:"1",y:"3",width:"22",height:"18",rx:"3",fill:"#DCEBFF"}),s.jsx("circle",{cx:"17",cy:"8",r:"2",fill:"#F5B544"}),s.jsx("path",{d:"m11 21 7-9 5 6v0a3 3 0 0 1-3 3Z",fill:"#73A9EF"}),s.jsx("path",{d:"M4 21a3 3 0 0 1-3-3v-1l6-7 10 11Z",fill:"#3979CF"})]})}),s.jsx("span",{className:"flex-1",children:n("page.makeShift.confirmedShifts.imageAction")})]}),s.jsxs("button",{type:"button",role:"menuitem",className:`${Y} justify-start gap-2.5 text-left text-sub-1`,onClick:()=>F(c),children:[s.jsx("span",{className:"flex size-8 shrink-0 items-center justify-center","aria-hidden":"true",children:s.jsx("img",{src:Ce,alt:"",className:"size-8 object-contain"})}),s.jsx("span",{className:"flex-1",children:n("page.makeShift.confirmedShifts.excelAction")})]})]}),e[24]=F,e[25]=x,e[26]=a,e[27]=w,e[28]=c,e[29]=i,e[30]=n,e[31]=k):k=e[31];let W;return e[32]!==j||e[33]!==k?(W=s.jsxs("div",{ref:d,className:"relative shrink-0",onBlur:L,children:[j,k]}),e[32]=j,e[33]=k,e[34]=W):W=e[34],W}const nt=new Map;function lt(t,e,o){if(!t)return null;try{return Ee(t,e,o)}catch{return null}}function ma(){const{t}=U(),e=v.resolvedLanguage??v.language,o=y.useRef(null),[r,a]=y.useState(!1),{state:{wardId:i}}=fe(),c=D(h=>h.year),n=D(h=>h.month),p=D(h=>h.wardId),m=D(h=>h.shiftTeams),d=D(h=>h.shiftTeamsStatus),l=D(h=>h.currentShiftTeamId),f=D(h=>
2h.confirmedShiftSnapshot),x=ke(),w=Te({wardId:p,shiftTeams:m,shiftTeamsStatus:d},i,l),b=X({...Z.duty(i??-1,l??-1,c,n),enabled:w}),I=X({...Z.id(i??-1),enabled:i!==null,staleTime:1e3*60*5}),C=m.find(h=>h.shiftTeamId===l)?.name??t("page.makeShift.confirmedShifts.fallbackTeamName"),F=y.useMemo(()=>new Map((m.find(h=>h.shiftTeamId===l)?.divisions??[]).map(h=>[h.divisionNum,h.name])),[l,m]),L=b.data??f,O=m.find(h=>h.shiftTeamId===l)?.nurses??[],g=y.useMemo(()=>Ae(L,O),[O,L]),{policy:A}=be(i),{adjustmentDays:M}=_e({wardId:i,shiftTeamId:l,year:c,month:n}),S=y.useMemo(()=>lt(g,c,n),[n,g,c]),E=pe(i,l,c,n,g,S,!0),T=ge(i),N=xe(E,T.value.annualLeave),j=y.useMemo(()=>g&&S?we({shift:g,doc:S,policy:A,year:c,month:n,adjustmentDays:M,annualLeaveDays:E.data?.days??E.overview.data?.days}):void 0,[E.data?.days,E.overview.data?.days,M,S,e,n,g,A,c]),{isExporting:k,downloadImage:W}=ot({targetRef:o,year:c,month:n,teamName:C,hospitalName:I.data?.hospitalName??null,wardName:I.data?.name??null,disabled:!g||!S}),{isExporting:u,exportExcel:_}=it({month:n,shift:g??null,disabled:!S||k}),P=k||u,$=`${i??"none"}:${l??"none"}:${c}:${n}:${g?"ready":"empty"}`,de=t(k?"page.makeShift.confirmedShifts.imageActionLoading":u?"feature.shiftEditor.toolbar.savingExcel":"page.makeShift.confirmedShifts.downloadAction"),K=t("page.makeShift.confirmedShifts.wardCodeGuideAction");return s.jsxs(s.Fragment,{children:[s.jsx(ve,{open:r,wardCode:he(I.data,t("entity.ward.codeChecking")),wardTitle:ue(I.data),onClose:()=>a(!1)}),s.jsxs("div",{id:"make_confirmed_shifts_step",className:"confirmed-shifts-root flex w-full min-w-0 flex-col gap-3 pt-3 outline-none",children:[s.jsxs("div",{className:"confirmed-shifts-toolbar flex w-full min-w-0 flex-nowrap items-center justify-between gap-3",children:[s.jsxs("div",{className:"min-w-0 flex-1 pl-8 min-[1600px]:pl-10",children:[s.jsx("h1",{className:"confirmed-shifts-toolbar__title truncate font-apple text-[26px] leading-tight font-bold text-sub-1 min-[1600px]:text-[28px]",children:t("page.makeShift.confirmedShifts.title",{teamName:C,month:n})}),s.jsxs("div",{className:"mt-3 flex min-w-0 items-center gap-1.5 min-[1600px]:mt-4",children:[s.jsx("p",{className:"confirmed-shifts-toolbar__hint truncate font-apple text-[15px] leading-[26px] font-medium text-gray-3 min-[1600px]:text-[16px] min-[1600px]:leading-[28px]",children:t("page.makeShift.confirmedShifts.hint")}),s.jsx(oe,{delayDuration:120,children:s.jsxs(se,{children:[s.jsx(ie,{asChild:!0,children:s.jsx("button",{type:"button","aria-label":K,title:K,className:"inline-flex size-6 shrink-0 items-center justify-center rounded-full text-main-1 transition-colors hover:bg-main-light hover:text-main-2 focus-visible:ring-2 focus-visible:ring-main-3 focus-visible:ring-offset-2 focus-visible:outline-none",onClick:()=>a(!0),children:s.jsx(De,{className:"size-4",strokeWidth:2.2,"aria-hidden":"true"})})}),s.jsx(re,{side:"top",className:"rounded-full bg-[#1C2331] px-3 py-1.5 text-[12px] font-semibold text-white",children:K})]})})]})]}),s.jsxs("div",{className:"confirmed-shifts-toolbar__actions ml-auto flex shrink-0 flex-nowrap items-center justify-end gap-2",children:[s.jsx(ye,{display:T,settings:s.jsx(Ne,{wardId:i,shiftTeamId:l,year:c,month:n,variant:"menu"})}),s.jsx(st,{label:de,disabled:!g||!S||P,isExporting:P,onDownloadImage:()=>{W(),Q(V.makePage.toolbar.downloadImage)},onDownloadExcel:()=>{_(),Q(V.makePage.toolbar.downloadExcel)}}),s.jsx(ae,{variant:"secondary",size:"md",type:"button",className:`min-w-[112px] cursor-pointer border-0 px-5 shadow-none focus-visible:ring-0 focus-visible:ring-offset-0 ${Ie}`,onClick:x.editConfirmed,children:t("page.makeShift.confirmedShifts.editAction")})]})]}),!g&&b.isLoading&&s.jsx(Se,{className:"confirmed-shifts-calendar-wrap",ariaLabel:t("page.makeShift.confirmedShifts.loading")}),!g&&b.isError&&s.jsx(z,{tone:"error",title:t("page.makeShift.confirmedShifts.error"),description:t("page.state.errorDescription"),action:{label:t("page.state.retry"),onClick:()=>void b.refetch()}}),g&&!S&&s.jsx(z,{tone:"error",title:t("page.makeShift.confirmedShifts.error"),description:t("page.state.errorDescription"),action:{label:t("page.state.retry"),onClick:()=>void b.refetch()}}),g&&S&&s.jsx("div",{ref:o,className:"confirmed-shifts-calendar-wrap w-full min-w-0",children:s.jsx(ct,{resetKey:$,fallback:s.jsx(z,{tone:"error",title:t("page.makeShift.confirmedShifts.error"),description:t("page.state.errorDescription"),action:{label:t("page.state.retry"),onClick:()=>void b.refetch()}}),children:s.jsx(je,{shift:g,doc:S,annualLeaveDays:E.data?.days??E.overview.data?.days,annualLeaveColumns:N.columns,showRestCheck:T.value.rest,violationMap:nt,showFaults:!1,readonly:!0,disableInitialSelection:!0,restCheckByShiftNurseId:j,showDivisionHeaders:!0,showDivisionStatistics:!0,divisionLabelByNum:F,stickyHeader:!0})})}),!b.isLoading&&!b.isError&&!g&&s.jsx(z,{tone:"empty",title:t("page.makeShift.confirmedShifts.empty"),description:t("page.state.emptyDescription")})]})]})}class ct extends y.Component{constructor(){super(...arguments),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}componentDidUpdate(e){e.resetKey!==this.props.resetKey&&this.state.hasError&&this.setState({hasError:!1})}render(){return this.state.hasError?this.props.fallback:this.props.children}}export{ma as ConfirmedShifts};
3//# sourceMappingURL=confirmed-shifts-JhDOd-hn.js.map

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.