1"use strict";(self.webpackChunktalent_web=self.webpackChunktalent_web||[]).push([[5933],{29743(e,t,s){s.d(t,{h:()=>o});var a,n=s(65043);function i(){return i=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var s=arguments[t];for(var a in s)Object.prototype.hasOwnProperty.call(s,a)&&(e[a]=s[a])}return e},i.apply(this,arguments)}function r(e,t){let{title:s,titleId:r,...o}=e;return n.createElement("svg",i({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),s?n.createElement("title",{id:r},s):null,a||(a=n.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9 2C9 2.55228 8.55228 3 8 3C7.44772 3 7 2.55228 7 2C7 1.44772 7.44772 1 8 1C8.55228 1 9 1.44772 9 2ZM9 8C9 8.55228 8.55228 9 8 9C7.44772 9 7 8.55228 7 8C7 7.44772 7.44772 7 8 7C8.55228 7 9 7.44772 9 8ZM8 15C8.55228 15 9 14.5523 9 14C9 13.4477 8.55228 13 8 13C7.44772 13 7 13.4477 7 14C7 14.5523 7.44772 15 8 15Z",fill:"#37323E"})))}const o=n.forwardRef(r);s.p},16240(e,t,s){s.d(t,{h:()=>o});var a,n=s(65043);function i(){return i=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var s=arguments[t];for(var a in s)Object.prototype.hasOwnProperty.call(s,a)&&(e[a]=s[a])}return e},i.apply(this,arguments)}function r(e,t){let{title:s,titleId:r,...o}=e;return n.createElement("svg",i({width:20,height:21,viewBox:"0 0 20 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),s?n.createElement("title",{id:r},s):null,a||(a=n.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.375 17.0825C9.375 17.4277 9.65482 17.7075 10 17.7075C10.3452 17.7075 10.625 17.4277 10.625 17.0825V11.2075H16.5C16.8452 11.2075 17.125 10.9277 17.125 10.5825C17.125 10.2373 16.8452 9.95752 16.5 9.95752H10.625V4.08252C10.625 3.73734 10.3452 3.45752 10 3.45752C9.65482 3.45752 9.375 3.73734 9.375 4.08252V9.95752H3.5C3.15482 9.95752 2.875 10.2373 2.875 10.5825C2.875 10.9277 3.15482 11.2075 3.5 11.2075H9.375V17.0825Z",fill:"currentColor"})))}const o=n.forwardRef(r);s.p},54448(e,t,s){s.d(t,{h:()=>o});var a,n=s(65043);function i(){return i=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var s=arguments[t];for(var a in s)Object.prototype.hasOwnProperty.call(s,a)&&(e[a]=s[a])}return e},i.apply(this,arguments)}function r(e,t){let{title:s,titleId:r,...o}=e;return n.createElement("svg",i({width:25,height:25,viewBox:"0 0 25 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),s?n.createElement("title",{id:r},s):null,a||(a=n.createElement("g",{id:"warning"},n.createElement("path",{id:"Subtract",fillRule:"evenodd",clipRule:"evenodd",d:"M3.71148 21.5327H21.2884C22.4461 21.5327 23.1674 20.2769 22.584 19.2769L13.7956 4.21105C13.2168 3.21871 11.7831 3.21871 11.2043 4.21105L2.41582 19.2769C1.8325 20.2769 2.5538 21.5327 3.71148 21.5327ZM12.4999 14.945C12.9142 14.945 13.2499 14.6092 13.2499 14.195V10.4955C13.2499 10.0813 12.9142 9.74551 12.4999 9.74551C12.0857 9.74551 11.7499 10.0813 11.7499 10.4955V14.195C11.7499 14.6092 12.0857 14.945 12.4999 14.945ZM11.7499 17.3805C11.7499 16.9663 12.0857 16.6305 12.4999 16.6305C12.9142 16.6305 13.2499 16.9663 13.2499 17.3805C13.2499 17.7947 12.9142 18.1305 12.4999 18.1305C12.0857 18.1305 11.7499 17.7947 11.7499 17.3805Z",fill:"currentColor"}))))}const o=n.forwardRef(r);s.p},83308(e,t,s){s.d(t,{A:()=>u});var a=s(64600),n=s.n(a),i=s(25284),r=s(54448),o=s(16299),l=s(94229),c=s(2837),d=s(70579);function u(e){let{className:t="",fullScreen:s=!1,title:a="Are you sure you want to delete this entry?",subtitle:u="This action cannot be undone.",cancelBtnText:h="Cancel",deleteBtnText:m="Delete",deleteVariant:p="danger",extra:v=null,show:f,onCancel:g,onDelete:_}=e;const{isMobile:b}=(0,l.l)();return(0,d.jsxs)(i.A,{className:n()("__koi-confirmation-modal",{"full-screen":s},t),centered:!0,backdrop:"static",keyboard:!1,backdropClassName:"__koi-confirmation-backdrop",show:f,onHide:g,children:[(0,d.jsx)(i.A.Header,{closeButton:b}),(0,d.jsxs)(i.A.Body,{children:[(0,d.jsxs)("div",{className:"koi-confirmation-title-container","data-cy":"confirmation-container",children:[(0,d.jsx)(r.h,{className:"warning-icon"}),(0,d.jsxs)("div",{className:"right",children:[(0,d.jsx)(c.Ay,{as:"h2",children:a}),(0,d.jsx)("div",{className:"koi-confirmation-subtitle",children:u}),v&&(0,d.jsx)("div",{className:"koi-confirmation-extra",children:v})]})]}),(0,d.jsxs)("div",{className:"koi-confirmation-buttons-container",children:[(0,d.jsx)(o.A,{variant:"secondary",onClick:g,children:h}),(0,d.jsx)(o.A,{variant:p,className:"delete-btn","data-cy":"delete-btn",onClick:_,children:m})]})]})]})}}
1,82429(e,t,s){s.d(t,{A:()=>d});var a=s(65043),n=s(35475),i=s(11294),r=s(14070),o=s(94229),l=s(16299),c=s(70579);function d(e){let{classNameButton:t,classNameDrawer:s,items:d,icon:u,title:h}=e;const{isMobile:m}=(0,o.l)(),[p,v]=(0,a.useState)(!1);return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(i.A,{className:t,variant:"secondary",items:m?[]:d,icon:u,onClick:e=>{e.preventDefault(),v(!0)}}),m&&(0,c.jsx)(r.A,{className:s,title:h,show:p,onHide:()=>{v(!1)},children:(0,c.jsx)("div",{className:"__main-content-dropdown-v2",children:d.map((e=>(0,c.jsx)(l.A,{as:e.to?n.N_:void 0,to:e.to,variant:"secondary",className:e.className,onClick:()=>{var t;null===(t=e.onClick)||void 0===t||t.call(e),v(!1)},children:e.label},e.label)))})})]})}},45486(e,t,s){s.d(t,{A:()=>c});var a=s(65043),n=s(64600),i=s.n(n),r=s(41089),o=s(4524),l=s(70579);function c(e){let{position:t="top-center",delay:s=3e3,className:n,type:c,show:d,onShow:u,message:h,onClose:m,...p}=e;return(0,a.useEffect)((()=>{u&&u()}),[]),(0,l.jsx)(o.A,{position:t,children:(0,l.jsx)(r.A,{autohide:!0,className:i()("__koi-toast",n),delay:s,show:d,bg:c,onClose:m,...p,children:(0,l.jsx)(r.A.Body,{children:h})})})}},39363(e,t,s){s.d(t,{Ay:()=>d,b6:()=>u,yz:()=>h});var a=s(93747),n=s(63248),i=s(47097),r=s(93862);const o=async()=>{const{data:e}=await r.FH.get("/organizations");return Array.isArray(e)&&e.length>0?e[0]:null},l=async e=>{let{name:t}=e;const{data:s}=await r.FH.post("/organizations",{organization:{name:t}});return s},c=async e=>{let{id:t,name:s}=e;const{data:a}=await r.FH.put("/organizations/".concat(t),{organization:{name:s}});return a};function d(){const{data:e,isLoading:t,error:s}=(0,a.I)({queryKey:["organization"],queryFn:o});return{data:e,isLoading:t,error:s}}function u(){const e=(0,n.jE)();return(0,i.n)({mutationFn:l,onSuccess:()=>{e.invalidateQueries({queryKey:["organization"]})}})}function h(){const e=(0,n.jE)();return(0,i.n)({mutationFn:c,onSuccess:()=>{e.invalidateQueries({queryKey:["organization"]})}})}},65933(e,t,s){s.r(t),s.d(t,{default:()=>k});var a=s(35475),n=s(16240),i=s(16299),r=s(2837),o=s(93747),l=s(93862),c=s(39363);const d=[];function u(){const{data:e,isLoading:t}=(0,c.Ay)(),s=null===e||void 0===e?void 0:e.id,{data:a,isLoading:n,error:i}=(0,o.I)({queryKey:["matchReports",s],queryFn:()=>(async e=>{const{data:t}=await l.FH.get("/match_reports",{params:{organization_id:e}});return Array.isArray(t)?t:[]})(s),enabled:Boolean(s)});return{matchReports:null!==a&&void 0!==a?a:d,isLoading:n||t,error:i}}var h=s(74800),m=s.n(h),p=s(65043),v=s(29743),f=s(83308),g=s(82429),_=s(45486),b=s(63248),y=s(47097);const x=async e=>{await l.FH.delete("/match_reports/".concat(e))};var A=s(55438),w=s(70579);const j="/admin/enterprise/people-compatibility-reports";function C(e){var t,s;let{report:n}=e;const[i,r]=(0,p.useState)(!1),[o,l]=(0,p.useState)(!1),c=function(){const e=(0,b.jE)();return(0,y.n)({mutationFn:x,onSuccess:(t,s)=>{e.invalidateQueries({queryKey:["matchReports"]}),e.removeQueries({queryKey:["matchReport"],predicate:e=>e.queryKey.includes(s)})}})}(),d=n.org_member,u=(null===d||void 0===d||null===(t=d.user)||void 0===t?void 0:t.name)||(0,A.M)(null===d||void 0===d?void 0:d.email)||"Unknown member",h=null!==(s=n.managers)&&void 0!==s?s:[],C=[{label:"View report",to:"".concat(j,"/").concat(n.id)},{label:"Delete report",onClick:()=>r(!0),className:"__match-reports-list-page__delete-item"}];return(0,w.jsxs)(w.Fragment,{children:[(0,w.jsxs)("li",{className:"__match-reports-list-page__item",children:[(0,w.jsxs)(a.N_,{to:"".concat(j,"/").concat(n.id),className:"__match-reports-list-page__item-content",children:[(0,w.jsx)("p",{className:"__match-reports-list-page__item-ea",children:u}),h.length>0&&(0,w.jsx)("div",{className:"__match-reports-list-page__item-managers",children:h.map((e=>{var t;const s=(null===(t=e.user)||void 0===t?void 0:t.name)||(0,A.M)(e.email);return(0,w.jsx)("span",{className:"__match-reports-list-page__manager-pill",children:s},e.id)}))})]}),(0,w.jsx)("div",{className:"__match-reports-list-page__item-actions",children:(0,w.jsx)(g.A,{classNameButton:"__match-reports-list-page__menu-btn",t
1itle:"Report actions",icon:(0,w.jsx)(v.h,{"aria-hidden":"true"}),items:C})})]}),(0,w.jsx)(f.A,{show:i,title:"Are you sure you want to delete this report?",subtitle:"This action cannot be undone.",deleteBtnText:"Delete",onCancel:()=>r(!1),onDelete:async()=>{if(!c.isPending){r(!1);try{await c.mutateAsync(n.id)}catch(e){m().notify(e),l(!0)}}}}),(0,w.jsx)(_.A,{show:o,type:"danger",message:"Failed to delete the report. Please try again.",onClose:()=>l(!1)})]})}function N(){return(0,w.jsxs)("header",{className:"__match-reports-list-page__header",children:[(0,w.jsx)(r.Ay,{as:"h2",className:"__match-reports-list-page__title",children:"People compatibility"}),(0,w.jsx)(i.A,{as:a.N_,to:"/admin/enterprise/people-compatibility-reports/generate",variant:"primary",icon:(0,w.jsx)(n.h,{className:"__match-reports-list-page__btn-icon"}),className:"__match-reports-list-page__generate-btn",children:"Generate report"})]})}function k(){const{matchReports:e,isLoading:t,error:s}=u();if(t)return(0,w.jsxs)("div",{className:"__match-reports-list-page","aria-busy":"true",children:[(0,w.jsx)(N,{}),[0,1,2].map((e=>(0,w.jsx)("div",{className:"__match-reports-list-page__skeleton"},e)))]});if(s)return(0,w.jsxs)("div",{className:"__match-reports-list-page",children:[(0,w.jsx)(N,{}),(0,w.jsx)("div",{className:"__match-reports-list-page__empty",children:(0,w.jsx)("p",{className:"__match-reports-list-page__empty-message",children:"Something went wrong loading reports."})})]});const a=e.filter((e=>"processed"===e.status));return(0,w.jsxs)("div",{className:"__match-reports-list-page",children:[(0,w.jsx)(N,{}),0===a.length?(0,w.jsx)("div",{className:"__match-reports-list-page__empty",children:(0,w.jsx)("p",{className:"__match-reports-list-page__empty-message",children:"No reports yet. Generate one to get started."})}):(0,w.jsx)("ul",{className:"__match-reports-list-page__list",children:a.map((e=>(0,w.jsx)(C,{report:e},e.id)))})]})}},55438(e,t,s){function a(e){return function(e){return e?e.split("@")[0].replace(/[._-]+/g," ").trim():""}(e).split(" ").filter(Boolean).map((e=>e[0].toUpperCase()+e.slice(1))).join(" ")}s.d(t,{M:()=>a})},23240(e,t,s){s.d(t,{A:()=>l});var a=s(65043),n=s(36723),i=s(59109),r=Math.pow(2,31)-1;function o(e,t,s){var a=s-Date.now();e.current=a<=r?setTimeout(t,a):setTimeout((function(){return o(e,t,s)}),r)}function l(){var e=(0,n.A)(),t=(0,a.useRef)();return(0,i.A)((function(){return clearTimeout(t.current)})),(0,a.useMemo)((function(){var s=function(){return clearTimeout(t.current)};return{set:function(a,n){void 0===n&&(n=0),e()&&(s(),n<=r?t.current=setTimeout(a,n):o(t,a,Date.now()+n))},clear:s}}),[])}},41089(e,t,s){s.d(t,{A:()=>x});var a=s(65043),n=s(64600),i=s.n(n),r=s(23240),o=s(28062),l=s(18072),c=s(70579);const d={[o.ns]:"showing",[o.ze]:"showing show"},u=a.forwardRef(((e,t)=>(0,c.jsx)(l.A,{...e,ref:t,transitionClasses:d})));u.displayName="ToastFade";const h=u;var m=s(71456),p=s(67852),v=s(85632);const f=a.createContext({onClose(){}}),g=a.forwardRef(((e,t)=>{let{bsPrefix:s,closeLabel:n,closeVariant:r,closeButton:o,className:l,children:d,...u}=e;s=(0,p.oU)(s,"toast-header");const h=(0,a.useContext)(f),g=(0,m.A)((e=>{null==h||null==h.onClose||h.onClose(e)}));return(0,c.jsxs)("div",{ref:t,...u,className:i()(s,l),children:[d,o&&(0,c.jsx)(v.A,{"aria-label":n,variant:r,onClick:g,"data-dismiss":"toast"})]})}));g.displayName="ToastHeader",g.defaultProps={closeLabel:"Close",closeButton:!0};const _=g;const b=(0,s(80700).A)("toast-body"),y=a.forwardRef(((e,t)=>{let{bsPrefix:s,className:n,transition:o=h,show:l=!0,animation:d=!0,delay:u=5e3,autohide:m=!1,onClose:v,bg:g,..._}=e;s=(0,p.oU)(s,"toast");const b=(0,a.useRef)(u),y=(0,a.useRef)(v);(0,a.useEffect)((()=>{b.current=u,y.current=v}),[u,v]);const x=(0,r.A)(),A=!(!m||!l),w=(0,a.useCallback)((()=>{A&&(null==y.current||y.current())}),[A]);(0,a.useEffect)((()=>{x.set(w,b.current)}),[x,w]);const j=(0,a.useMemo)((()=>({onClose:v})),[v]),C=!(!o||!d),N=(0,c.jsx)("div",{..._,ref:t,className:i()(s,n,g&&"bg-".concat(g),!C&&(l?"show":"hide")),role:"alert","aria-live":"assertive","aria-atomic":"true"});return(0,c.jsx)(f.Provider,{value:j,children:C&&o?(0,c.jsx)(o,{in:l,unmountOnExit:!0,children:N}):N})}));y.displayName="Toast";const x=Object.assign(y,{Body:b,Header:_})},4524(e,t,s){s.d(t,{A:()=>d});
1var a=s(64600),n=s.n(a),i=s(65043),r=s(67852),o=s(70579);const l={"top-start":"top-0 start-0","top-center":"top-0 start-50 translate-middle-x","top-end":"top-0 end-0","middle-start":"top-50 start-0 translate-middle-y","middle-center":"top-50 start-50 translate-middle","middle-end":"top-50 end-0 translate-middle-y","bottom-start":"bottom-0 start-0","bottom-center":"bottom-0 start-50 translate-middle-x","bottom-end":"bottom-0 end-0"},c=i.forwardRef(((e,t)=>{let{bsPrefix:s,position:a,containerPosition:i="absolute",className:c,as:d="div",...u}=e;return s=(0,r.oU)(s,"toast-container"),(0,o.jsx)(d,{ref:t,...u,className:n()(s,a&&[i?"position-".concat(i):null,l[a]],c)})}));c.displayName="ToastContainer";const d=c},47097(e,t,s){s.d(t,{n:()=>j});var a,n,i,r,o,l,c=s(65043),d=s(39790),u=s(55149),h=s(21114),m=s(61187),p=s(806),v=s(25239),f=s(11454),g=s(60329),_=s(99723),b=(a=new WeakMap,n=new WeakMap,i=new WeakMap,r=new WeakMap,o=new WeakSet,l=new WeakSet,class extends g.Q{constructor(e,t){super(),(0,d.A)(this,l),(0,d.A)(this,o),(0,u.A)(this,a,{writable:!0,value:void 0}),(0,u.A)(this,n,{writable:!0,value:void 0}),(0,u.A)(this,i,{writable:!0,value:void 0}),(0,u.A)(this,r,{writable:!0,value:void 0}),(0,p.A)(this,a,e),this.setOptions(t),this.bindMethods(),(0,m.A)(this,o,y).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){var t;const s=this.options;this.options=(0,h.A)(this,a).defaultMutationOptions(e),(0,_.f8)(this.options,s)||(0,h.A)(this,a).getMutationCache().notify({type:"observerOptionsUpdated",mutation:(0,h.A)(this,i),observer:this}),null!==s&&void 0!==s&&s.mutationKey&&this.options.mutationKey&&(0,_.EN)(s.mutationKey)!==(0,_.EN)(this.options.mutationKey)?this.reset():"pending"===(null===(t=(0,h.A)(this,i))||void 0===t?void 0:t.state.status)&&(0,h.A)(this,i).setOptions(this.options)}onUnsubscribe(){var e;this.hasListeners()||(null===(e=(0,h.A)(this,i))||void 0===e||e.removeObserver(this))}onMutationUpdate(e){(0,m.A)(this,o,y).call(this),(0,m.A)(this,l,x).call(this,e)}getCurrentResult(){return(0,h.A)(this,n)}reset(){var e;null===(e=(0,h.A)(this,i))||void 0===e||e.removeObserver(this),(0,p.A)(this,i,void 0),(0,m.A)(this,o,y).call(this),(0,m.A)(this,l,x).call(this)}mutate(e,t){var s;return(0,p.A)(this,r,t),null===(s=(0,h.A)(this,i))||void 0===s||s.removeObserver(this),(0,p.A)(this,i,(0,h.A)(this,a).getMutationCache().build((0,h.A)(this,a),this.options)),(0,h.A)(this,i).addObserver(this),(0,h.A)(this,i).execute(e)}});function y(){var e,t;const s=null!==(e=null===(t=(0,h.A)(this,i))||void 0===t?void 0:t.state)&&void 0!==e?e:(0,v.$)();(0,p.A)(this,n,{...s,isPending:"pending"===s.status,isSuccess:"success"===s.status,isError:"error"===s.status,isIdle:"idle"===s.status,mutate:this.mutate,reset:this.reset})}function x(e){f.j.batch((()=>{if((0,h.A)(this,r)&&this.hasListeners()){const u=(0,h.A)(this,n).variables,m=(0,h.A)(this,n).context;var t,s,a,i;if("success"===(null===e||void 0===e?void 0:e.type))null===(t=(s=(0,h.A)(this,r)).onSuccess)||void 0===t||t.call(s,e.data,u,m),null===(a=(i=(0,h.A)(this,r)).onSettled)||void 0===a||a.call(i,e.data,null,u,m);else if("error"===(null===e||void 0===e?void 0:e.type)){var o,l,c,d;null===(o=(l=(0,h.A)(this,r)).onError)||void 0===o||o.call(l,e.error,u,m),null===(c=(d=(0,h.A)(this,r)).onSettled)||void 0===c||c.call(d,void 0,e.error,u,m)}}this.listeners.forEach((e=>{e((0,h.A)(this,n))}))}))}var A=s(63248),w=s(13247);function j(e,t){const s=(0,A.jE)(t),[a]=c.useState((()=>new b(s,e)));c.useEffect((()=>{a.setOptions(e)}),[a,e]);const n=c.useSyncExternalStore(c.useCallback((e=>a.subscribe(f.j.batchCalls(e))),[a]),(()=>a.getCurrentResult()),(()=>a.getCurrentResult())),i=c.useCallback(((e,t)=>{a.mutate(e,t).catch(w.l)}),[a]);if(n.error&&(0,w.G)(a.options.throwOnError,[n.error]))throw n.error;return{...n,mutate:i,mutateAsync:n.mutate}}}}]); 2//# sourceMappingURL=5933.0998a185.chunk.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.