asma-core-ui 2.20.19 → 2.20.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -220,4 +220,4 @@ function e$(e,t){return"function"==typeof e?e(t):e}function t$(e,t){return n=>{t
220
220
  *
221
221
  * @license MIT
222
222
  */
223
- function K$(t,n){return t?function(e){return function(e){return"function"==typeof e&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}(e)||"function"==typeof e||function(e){return"object"==typeof e&&"symbol"==typeof e.$$typeof&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}(e)}(t)?e.createElement(t,n):t:null}function Y$({table:e,stickyHeader:t=!1,hideHeader:n=!1}){return Re.jsxs("thead",{className:ho("table-header-group z-50 bg-[#fcfcfd] cursor-default",n&&"h-0 opacity-0"),style:t&&{position:"sticky",top:-.2}||{},children:[Re.jsx(Z$,{}),e.getHeaderGroups().map((e=>Re.jsx("tr",{children:e.headers.map((e=>{var t;let o=e.getSize();o&&(o=`min-w-[${o}px] w-[${o}px] max-w-[${o}px]`);const r="actions"===(null==(t=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}(e.headerGroup.headers))?void 0:t.id),i=e.headerGroup.headers[e.headerGroup.headers.length-(r?2:1)];return((null==i?void 0:i.id)===e.id||!o)&&(o="w-full"),Re.jsx("th",{colSpan:e.colSpan,className:ho(o,"px-2.5 py-0","text-delta-500 bg-transparent border-none text-start text-[10px] font-semibold uppercase justify-start"),style:{maxWidth:e.column.columnDef.maxSize,minWidth:e.column.columnDef.minSize},children:e.isPlaceholder?null:Re.jsxs("div",{className:ho("flex items-center justify-left",n?"h-0":"h-[30px]",e.column.getCanSort()||"actions"===e.column.id?"cursor-pointer select-none":"",e.column.columnDef.className),onClick:e.column.getToggleSortingHandler(),children:[K$(e.column.columnDef.header,e.getContext()),{asc:Re.jsx(Il,{className:"text-delta-800"}),desc:Re.jsx(_l,{className:"text-delta-800"})}[e.column.getIsSorted()]??null]})},e.id)}))},e.id))),Re.jsx(Z$,{})]})}const Z$=()=>Re.jsx("tr",{className:"bg-[#fcfcfd] w-full relative table-row",children:Re.jsx("th",{className:"w-[calc(100%-1px)] p-0 bg-[#fcfcfd] border-b-solid border-t-transparent border-x-0 border-[0.5px] border-b-delta-300 h-full absolute-center"})});const X$=e=>Re.jsx(O,{...e});function Q$({tableData:e,actions:t}){const{anchorEl:n,open:o,handleClose:r,handleOpen:i}=NV();return Re.jsxs("div",{className:"flex justify-center items-center",children:[Re.jsx(NR,{dataTest:"test",variant:"text",size:"small",onClick:e=>{e.stopPropagation(),e.preventDefault(),i(e)},onMouseDown:e=>{e.stopPropagation(),e.preventDefault()},onMouseUp:e=>{e.stopPropagation(),e.preventDefault()},children:Re.jsx(jl,{className:"!text-delta-800",width:20,height:20})}),Re.jsx(X$,{open:o,anchorEl:n,onClose:r,onClick:r,anchorOrigin:{horizontal:"center",vertical:"bottom"},transformOrigin:{vertical:"top",horizontal:"right"},children:t(e.row).filter((e=>!e.hide)).map((t=>Re.jsx(zV,{className:t.className,disabled:t.disabled,onClick:()=>{var n;null==(n=t.onClick)||n.call(t,e.row)},onMouseDown:e=>{e.stopPropagation(),e.preventDefault()},onMouseUp:e=>{e.stopPropagation(),e.preventDefault()},children:t.label},t.label)))})]})}function J$({headerData:e}){const{anchorEl:t,open:n,handleClose:o,handleOpen:r}=NV();return Re.jsxs("div",{className:"w-full flex items-center justify-end ",children:[Re.jsx("div",{className:"px-2.5 h-[30px] flex items-center justify-center",onClick:r,children:Re.jsx(Xi,{icon:"mdi:pin",className:"text-delta-500 hover:text-delta-600 min-w-[20px] min-h-[20px]"})}),Re.jsx(X$,{anchorEl:t,anchorOrigin:{horizontal:"left",vertical:"bottom"},open:n,onClose:o,children:e.table.getAllLeafColumns().filter((e=>e.getCanHide()&&e.id!==XV)).map((e=>e.columnDef.header?Re.jsxs(zV,{onClick:()=>e.toggleVisibility(!e.getIsVisible()),children:[Re.jsx(jN,{size:"small",dataTest:"test",disableRipple:!0,className:"p-0 pr-2",checked:e.getIsVisible()}),"string"==typeof e.columnDef.header?e.columnDef.header:e.id]},e.id):null))})]})}function ez({columns:e,expandArrow:t,enableRowSelection:n,headerPin:o,actions:r,customActionsNode:i}){!e.find((e=>"actions"===e.id))&&(r||i||o)&&e.push(function(e){const{headerPin:t,actions:n,customActionsNode:o}=e;return{id:"actions",enableHiding:!1,enableSorting:!1,accessorFn:e=>e,header:e=>t?Re.jsx(J$,{headerData:e}):null,cell:e=>n||o?Re.jsxs("div",{className:"flex gap-2 items-center justify-end",children:[o&&(null==o?void 0:o(e)),n&&Re.jsx(Q$,{tableData:e,actions:n})]}):null,size:50}}({headerPin:o||!1,actions:r,customActionsNode:i})),n&&!e.find((e=>e.id===XV))&&e.unshift({id:XV,minSize:40,maxSize:40,size:40,header:({table:e})=>Re.jsx("div",{className:"w-[25px]",children:Re.jsx(jN,{size:"small",dataTest:"cell-select-all",checked:e.getIsAllRowsSelected(),indeterminate:e.getIsSomeRowsSelected(),onChange:e.getToggleAllRowsSelectedHandler()})}),cell:({cell:e})=>Re.jsx("div",{className:"w-[25px]",children:Re.jsx(jN,{size:"small",dataTest:"cell-select",checked:e.row.getIsSelected(),disabled:!e.row.getCanSelect(),onClick:e=>e.stopPropagation(),onChange:e.row.getToggleSelectedHandler()})})}),t&&!e.find((e=>e.id===QV))&&e.unshift({id:QV,minSize:40,maxSize:40,size:40,enableHiding:!1,enableSorting:!1,header:()=>null,cell:({cell:e})=>{const t=e.row.getIsExpanded();return e.row.getCanExpand()?Re.jsx("span",{className:"flex w-fit h-fit px-2 bg-transparent outline-none focus:outline-none items-center justify-center",onClick:()=>e.row.getToggleExpandedHandler()(),children:t?Re.jsx(Vl,{width:24,height:24}):Re.jsx(Ll,{width:24,height:24})}):null}})}function tz({table:e,locale:t}){const{anchorEl:n,open:o,handleClose:r,handleOpen:i}=NV(),l="no"===t,a=()=>{var e;const t=document.querySelectorAll('[data-index="0"]');null==(e=null==t?void 0:t[0])||e.scrollIntoView({behavior:"smooth",block:"end",inline:"end"})},s=e.getPageCount(),u=e.getState().pagination.pageIndex+1,c=Array.from({length:s},((e,t)=>t+1));return s>1?Re.jsxs("div",{className:"w-fit animate-opacity-in-5 justify-end flex items-center bg-transparent gap-2",children:[Re.jsx(vr,{title:l?"Nåværende side":"Current Page",children:Re.jsx("div",{children:Re.jsxs(NR,{variant:"outlined",dataTest:"list-pages",className:"w-[134px]",onClick:e=>{i(e)},endIcon:o?Re.jsx(Vl,{height:24,width:24}):Re.jsx(Ll,{height:24,width:24}),children:[l?"Side":"Page"," ",u," ",l?"av":"of"," ",s]})})}),Re.jsx(X$,{open:o,anchorEl:n,onClose:r,anchorOrigin:{vertical:-5,horizontal:"center"},transformOrigin:{vertical:"bottom",horizontal:"center"},children:Re.jsx("div",{className:"max-h-[200px] w-[134px] overflow-auto",children:c.map((t=>Re.jsxs("div",{className:ho("h-[36px] relative flex items-center pl-10 cursor-pointer hover:bg-delta-50",u===t&&"bg-gama-50"),onClick:()=>{e.setPageIndex(t-1),r(),a()},children:[u===t&&Re.jsx(zl,{className:"absolute left-2 top-1 text-gama-500",height:24,width:24}),Re.jsxs("span",{children:[l?"Side":"Page"," ",t]})]},t)))})}),Re.jsx(vr,{title:1===u?"":l?"Forrige side":"Previous Page",children:Re.jsx("div",{children:Re.jsx(NR,{variant:"outlined",dataTest:"pagination-ChevronLeftIcon",startIcon:Re.jsx(rl,{height:24,width:24}),onClick:()=>{e.previousPage(),a()},disabled:!e.getCanPreviousPage()})})}),Re.jsx(vr,{title:u===s?"":l?"Neste side":"Next Page",children:Re.jsx("div",{children:Re.jsx(NR,{variant:"outlined",dataTest:"pagination-ChevronRightIcon",startIcon:Re.jsx(ol,{height:24,width:24}),onClick:()=>{e.nextPage(),a()},disabled:!e.getCanNextPage()})})})]}):null}function nz({table:e,locale:t,children:n}){return Re.jsxs("div",{className:"w-full gap-2 bg-transparent flex flex-row py-1 my-1 items-center justify-end ",children:[n,Re.jsx(tz,{table:e,locale:t})]})}const oz=({actions:t,columns:n,data:o,customSubRowData:r,initialState:i,enableRowSelection:l,headerPin:a=!0,loading:s,noRowsOverlay:u,tableInstanceRef:c,className:d,rowHeight:p,tdClassName:f,getRowClassName:h,onRowClick:m,renderSubRows:g,customActionsNode:v,focusable:y,stickyHeader:w,expandArrow:x,height:C,locale:O="en",footer:k,hideHeader:S,hideFooter:E,...R})=>{ez({columns:n,expandArrow:x,enableRowSelection:l,headerPin:a,actions:t,customActionsNode:v});const T=function(t){const n={state:{},onStateChange:()=>{},renderFallbackValue:null,...t},[o]=e.useState((()=>({current:q$(n)}))),[r,i]=e.useState((()=>o.current.initialState));return o.current.setOptions((e=>({...e,...t,state:{...r,...t.state},onStateChange:e=>{i(e),null==t.onStateChange||t.onStateChange(e)}}))),o.current}({...R,columns:n,data:o,initialState:{pagination:{pageIndex:0,pageSize:50},columnVisibility:{...null==i?void 0:i.columnVisibility,[XV]:!1},...i},enableRowSelection:l,getCoreRowModel:e=>o$((()=>[e.options.data]),(t=>{const n={rows:[],flatRows:[],rowsById:{}},o=function(t,r,i){void 0===r&&(r=0);const l=[];for(let s=0;s<t.length;s++){const u=B$(e,e._getRowId(t[s],s,i),t[s],s,r,void 0,null==i?void 0:i.id);var a;n.flatRows.push(u),n.rowsById[u.id]=u,l.push(u),e.options.getSubRows&&(u.originalSubRows=e.options.getSubRows(t[s],s),null!=(a=u.originalSubRows)&&a.length&&(u.subRows=o(u.originalSubRows,r+1,u)))}return l};return n.rows=o(t),n}),{key:"development"===process.env.NODE_ENV&&"getRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getExpandedRowModel:e=>o$((()=>[e.getState().expanded,e.getPreExpandedRowModel(),e.options.paginateExpandedRows]),((e,t,n)=>t.rows.length&&(!0===e||Object.keys(e??{}).length)&&n?G$(t):t),{key:"development"===process.env.NODE_ENV&&"getExpandedRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable}}),getFilteredRowModel:e=>o$((()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter]),((t,n,o)=>{if(!t.rows.length||(null==n||!n.length)&&!o){for(let e=0;e<t.flatRows.length;e++)t.flatRows[e].columnFilters={},t.flatRows[e].columnFiltersMeta={};return t}const r=[],i=[];(n??[]).forEach((t=>{var n;const o=e.getColumn(t.id);if(!o)return;const i=o.getFilterFn();i?r.push({id:t.id,filterFn:i,resolvedValue:null!=(n=null==i.resolveFilterValue?void 0:i.resolveFilterValue(t.value))?n:t.value}):"production"!==process.env.NODE_ENV&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${o.id}.`)}));const l=n.map((e=>e.id)),a=e.getGlobalFilterFn(),s=e.getAllLeafColumns().filter((e=>e.getCanGlobalFilter()));let u,c;o&&a&&s.length&&(l.push("__global__"),s.forEach((e=>{var t;i.push({id:e.id,filterFn:a,resolvedValue:null!=(t=null==a.resolveFilterValue?void 0:a.resolveFilterValue(o))?t:o})})));for(let e=0;e<t.flatRows.length;e++){const n=t.flatRows[e];if(n.columnFilters={},r.length)for(let e=0;e<r.length;e++){u=r[e];const t=u.id;n.columnFilters[t]=u.filterFn(n,t,u.resolvedValue,(e=>{n.columnFiltersMeta[t]=e}))}if(i.length){for(let e=0;e<i.length;e++){c=i[e];const t=c.id;if(c.filterFn(n,t,c.resolvedValue,(e=>{n.columnFiltersMeta[t]=e}))){n.columnFilters.__global__=!0;break}}!0!==n.columnFilters.__global__&&(n.columnFilters.__global__=!1)}}return W$(t.rows,(e=>{for(let t=0;t<l.length;t++)if(!1===e.columnFilters[l[t]])return!1;return!0}),e)}),{key:"development"===process.env.NODE_ENV&&"getFilteredRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getSortedRowModel:e=>o$((()=>[e.getState().sorting,e.getPreSortedRowModel()]),((t,n)=>{if(!n.rows.length||null==t||!t.length)return n;const o=e.getState().sorting,r=[],i=o.filter((t=>{var n;return null==(n=e.getColumn(t.id))?void 0:n.getCanSort()})),l={};i.forEach((t=>{const n=e.getColumn(t.id);n&&(l[t.id]={sortUndefined:n.columnDef.sortUndefined,invertSorting:n.columnDef.invertSorting,sortingFn:n.getSortingFn()})}));const a=e=>{const t=[...e];return t.sort(((e,t)=>{for(let o=0;o<i.length;o+=1){var n;const r=i[o],a=l[r.id],s=null!=(n=null==r?void 0:r.desc)&&n;let u=0;if(a.sortUndefined){const n=void 0===e.getValue(r.id),o=void 0===t.getValue(r.id);(n||o)&&(u=n&&o?0:n?a.sortUndefined:-a.sortUndefined)}if(0===u&&(u=a.sortingFn(e,t,r.id)),0!==u)return s&&(u*=-1),a.invertSorting&&(u*=-1),u}return e.index-t.index})),t.forEach((e=>{var t;r.push(e),null!=(t=e.subRows)&&t.length&&(e.subRows=a(e.subRows))})),t};return{rows:a(n.rows),flatRows:r,rowsById:n.rowsById}}),{key:"development"===process.env.NODE_ENV&&"getSortedRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getPaginationRowModel:e=>o$((()=>[e.getState().pagination,e.getPrePaginationRowModel(),e.options.paginateExpandedRows?void 0:e.getState().expanded]),((t,n)=>{if(!n.rows.length)return n;const{pageSize:o,pageIndex:r}=t;let{rows:i,flatRows:l,rowsById:a}=n;const s=o*r,u=s+o;let c;i=i.slice(s,u),c=e.options.paginateExpandedRows?{rows:i,flatRows:l,rowsById:a}:G$({rows:i,flatRows:l,rowsById:a}),c.flatRows=[];const d=e=>{c.flatRows.push(e),e.subRows.length&&e.subRows.forEach(d)};return c.rows.forEach(d),c}),{key:"development"===process.env.NODE_ENV&&"getPaginationRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable}}),getRowId:R.getRowId||((e,t,n)=>n?[n.id,e.id].join("."):e.id.toString())});c&&(c.current=T);const N=E?T.getCoreRowModel().rows:T.getRowModel().rows;return Re.jsxs("div",{children:[Re.jsx("div",{className:ho("overflow-auto w-full",d),style:{height:C},children:Re.jsxs("table",{className:ho("table box-border border-collapse animate-opacity-appear-3 border-spacing-[1px] max-w-[inherit] m-0 w-[calc(100%-5px)]"),children:[!s&&Re.jsx(Y$,{table:T,stickyHeader:w,hideHeader:S}),Re.jsxs("tbody",{className:"table-row-group align-middle max-w-[inherit]",children:[o.length>0&&s?Re.jsx(Ml,{className:"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 text-gama-500 z-10",width:50,height:50}):null,0===o.length&&s?Re.jsx(Re.Fragment,{children:Array.from({length:5}).map(((e,t)=>Re.jsx("tr",{children:Re.jsx("td",{colSpan:n.length,children:Re.jsx(ne,{variant:"text",width:"100%",height:50},t)})},t)))}):o.length>0?N.map(((e,t)=>((e,t)=>Re.jsxs(b,{children:[Re.jsx("tr",{"data-index":t,"data-test":e.id,id:e.id,tabIndex:y?-1:void 0,className:ho("table-row align-middle border-solid border-x border-t border-b-0 last:border-b-transparent first:border-t-transparent border-x-transparent border-y-delta-300 hover:cursor-pointer hover:bg-gama-25 focus:bg-gama-50 focus:border focus:border-gama-500",(e.getIsExpanded()||e.getIsSelected())&&"bg-gama-50",s&&"opacity-50",null==h?void 0:h(e)),style:{height:p?`${p}px`:"inherit"},onMouseDown:t=>{t.target.classList.contains("MuiModal-backdrop")||"INPUT"===t.target.nodeName||"BUTTON"===t.target.nodeName||(e.getCanExpand()&&!x&&e.getToggleExpandedHandler()(),m&&m(t,e))},children:e.getVisibleCells().map((e=>Re.jsx("td",{className:ho("break-words table-cell align-middle text-sm text-delta-900 whitespace-pre-wrap","px-2.5 py-0",f),children:K$(e.column.columnDef.cell,e.getContext())},e.id)))}),e.getIsExpanded()&&Re.jsx(Re.Fragment,{children:r&&g&&g({rows:r.get(e.original.id.toString())??[],row:e.original})})]},e.id))(e,t))):Re.jsx("tr",{className:"h-28",children:Re.jsx("td",{colSpan:n.length,className:"text-center align-middle text-sm text-delta-900",children:u})})]})]})}),!E&&Re.jsx(nz,{table:T,locale:O,children:null==k?void 0:k(T)})]})},rz="_title_17oo0_1",iz=function(e){return Re.jsx("div",{className:rz,children:e.children})},lz=function(e){return Re.jsx("h1",{"data-test":e.dataTest,className:"font-roboto md:mb-2 mb-5 text-2xl font-bold leading-10 text-[#17232E]",children:e.children})},az=()=>{const[e,t]=l(null),n=()=>{t((()=>null))};return{anchorEl:e,onClose:n,onAnchorClick:o=>{e?n():(e=>{t((()=>e.currentTarget))})(o)}}},sz=({filterIsActive:e,popoverContent:t,dataTest:n,disabled:o,size:r="large",variant:i="outlined"})=>{const{onAnchorClick:l,onClose:a,anchorEl:s}=az();return Re.jsxs(Re.Fragment,{children:[Re.jsxs("div",{className:"w-fit h-fit relative",children:[Re.jsx(NR,{disabled:o,variant:i,startIcon:Re.jsx(Xl,{width:"large"===r?24:20,height:"large"===r?24:20}),onClick:l,size:r,dataTest:n,children:"Filter"}),e&&Re.jsx("div",{className:ho("h-2 w-2 bg-gama-400 rounded-full absolute","large"===r?"top-2 right-2":"top-1 right-1")})]}),Re.jsx(X$,{open:!!s,anchorEl:s,onClose:a,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},className:"my-1",children:t})]})},uz=({onCloseText:e,onMinimizeText:t,onExpandText:n,showCloseIcon:o=!0,showMinimizeIcon:r=!0,showExpandIcon:i=!0,title:a,label:s,children:u,open:c,onClose:d,className:p="",primaryButtonText:f,secondaryButtonText:h,onPrimaryButtonClick:m,onSecondaryButtonClick:g})=>{const[b,v]=l(!1),y=()=>{v(!b)};return c?b?Re.jsx("div",{className:"fixed bottom-4 right-4 z-[51] w-[387px] rounded-lg bg-white py-2 pl-4 pr-3 shadow-[0_4px_40px_0px_rgba(34,33,51,0.4)] transition-all duration-300",children:Re.jsxs("div",{className:"flex items-center justify-between",children:[Re.jsx("div",{className:"truncate text-lg font-semibold text-delta-800",children:a}),Re.jsxs("div",{className:"flex gap-x-1",children:[Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"minimize-button",variant:"text",size:"small",onClick:y,endIcon:i&&Re.jsx(ga,{height:20,width:20,color:"text-gama-500"}),children:n})}),Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"close-button",variant:"textGray",size:"small",onClick:d,endIcon:o&&Re.jsx($l,{height:20,width:20,color:"text-delta-700"}),children:e})})]})]})}):Re.jsxs("div",{className:ho("fixed bottom-4 right-4 z-[51] rounded-lg bg-white shadow-[0_4px_40px_0px_rgba(34,33,51,0.4)] transition-all duration-300",p),children:[Re.jsxs("div",{className:"fixed-top flex flex-col gap-y-2 p-4",children:[Re.jsxs("div",{className:"flex items-center justify-between",children:[s?Re.jsx("div",{className:"text-sm text-delta-700",children:s}):Re.jsx("div",{className:"text-2xl font-semibold text-delta-800",children:a}),Re.jsxs("div",{className:"flex gap-x-1",children:[Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"minimize-button",variant:"textGray",size:"small",onClick:y,endIcon:r&&Re.jsx(ma,{height:20,width:20,color:"text-delta-700"}),children:t})}),Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"close-button",variant:"textGray",size:"small",onClick:d,endIcon:Re.jsx($l,{height:20,width:20,color:"text-delta-700"}),children:e})})]})]}),s&&Re.jsx("div",{className:"text-2xl font-semibold text-delta-800",children:a})]}),Re.jsx("div",{children:u}),Re.jsxs("div",{className:"fixed-bottom flex justify-end gap-x-4 border-t-[1px] border-delta-200 p-4",children:[h&&g&&Re.jsx(NR,{dataTest:"cancel-button",variant:"outlined",onClick:g,children:h}),f&&m&&Re.jsx(NR,{dataTest:"save-button",onClick:m,children:f})]})]}):null};export{JV as ACTIONS_COLUMN_ID,Dl as ArchiveIcon,bl as AssignmentIcon,vl as AssignmentOutlineIcon,oe as Avatar,va as BadgeIcon,tl as BellIcon,el as BellOutlineIcon,na as CalendarBlankOutlineIcon,ml as CalendarIcon,gl as CalendarRangeIcon,Al as CheckBoxCheckedIcon,hl as CheckFactOutlineIcon,zl as CheckIcon,fl as CheckOutlineIcon,il as ChevronDoubleLeftIcon,ll as ChevronDoubleRightIcon,Ll as ChevronDownIcon,rl as ChevronLeftIcon,ol as ChevronRightIcon,Vl as ChevronUpIcon,re as ClickAwayListener,$l as CloseIcon,ha as ConsentsIcon,ul as DashboardViewIcon,cl as DashboardViewOutlineIcon,Zl as DeleteOutlineIcon,jl as DotsVerticalIcon,Fl as DownloadIcon,Kl as DragHorizontalIcon,_l as DropDownIcon,Il as DropUpIcon,Jl as DvrIcon,QV as EXPAND_COLUMN_ID,ua as EarthIcon,Gl as EmptyPageIcon,ea as ErrorOutlineIcon,ie as Fade,ra as FastCheckOutlineIcon,Yl as FilePdfIcon,Xl as FilterIcon,El as FindReplaceIcon,Rl as FindReplacePeopleIcon,AO as GridRow,nl as HamburgerIcon,IV as HelperText,Bl as InboxOutboxIcon,Ul as InboxOutboxOutlineIcon,ga as KeyboardCapslockIcon,oa as LinkOutlineIcon,yl as ListNumberedIcon,sa as ListSettingsLineIcon,la as ListStatusIcon,Ml as LoadingIcon,Ql as LockIcon,wl as MessageProcessingIcon,xl as MessageProcessingOutlineIcon,ba as MessageReplyIcon,uz as MinimizableDialog,ma as MinimizeIcon,fa as OutlineCalendarMonth,le as Paper,sl as PdfIcon,da as PencilOutlineIcon,pl as PeopleIcon,dl as PeopleOutlineIcon,Hl as PermMediaIcon,ql as PermMediaOutline,Tl as PersonIcon,Nl as PersonOutlineIcon,ae as Popper,al as QnrIcon,ta as ReplayIcon,Cl as ReportBoxIcon,Ol as ReportBoxOutlineIcon,I_ as RichInput,XV as SELECT_COLUMN_ID,Pl as SearchIcon,kl as SettingsIcon,ca as SettingsMenuHorizontalIcon,Sl as SettingsOutlineIcon,kN as SnackbarProvider,KV as StyledAccordion,ZV as StyledAccordionDetails,YV as StyledAccordionSummary,_R as StyledAlert,DR as StyledAlertTitle,Te as StyledBadge,NR as StyledButton,jN as StyledCheckbox,Ne as StyledChip,GV as StyledContainer,ER as StyledDataGrid,RV as StyledDatePicker,jR as StyledDialog,PR as StyledDialogActions,MR as StyledDialogContent,IR as StyledDialogTitle,VV as StyledDrawer,sz as StyledFilterMenu,vV as StyledFormControl,_V as StyledFormControlLabel,pR as StyledFormGroup,DV as StyledFormHelperText,FV as StyledFormLabel,RR as StyledGridActionsCellItem,MN as StyledInput,IN as StyledInputField,AV as StyledInputLabel,PD as StyledLabel,BV as StyledLink,$V as StyledMenu,zV as StyledMenuItem,HV as StyledMenuList,lz as StyledModuleTitle,X$ as StyledPopover,V_ as StyledRadio,$_ as StyledRadioGroup,__ as StyledSelect,F_ as StyledSelectAutocomplete,D_ as StyledSelectItem,A_ as StyledSlider,SN as StyledSnackbar,LV as StyledStack,L_ as StyledSwitch,UV as StyledTab,oz as StyledTable,WV as StyledTabs,DN as StyledTextarea,MV as StyledTimePicker,vr as StyledTooltip,ya as StyledTypography,iz as StyledWidgetTitle,aa as TextBoxCheckOutlineIcon,Wl as TopicIcon,ia as UnknownDocumentOutlineRoundedIcon,pa as WarningAmberOutlineIcon,aN as closeSnackbar,U$ as createColumnHelper,lN as enqueueSnackbar,kg as gridDateComparator,NN as message,be as omit,ve as pick,EN as processAlertSnackBar,RN as processInfoSnackbar,ye as tokenOptimizer,xN as useSnackbar};
223
+ function K$(t,n){return t?function(e){return function(e){return"function"==typeof e&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}(e)||"function"==typeof e||function(e){return"object"==typeof e&&"symbol"==typeof e.$$typeof&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}(e)}(t)?e.createElement(t,n):t:null}function Y$({table:e,stickyHeader:t=!1,hideHeader:n=!1}){return Re.jsxs("thead",{className:ho("table-header-group z-50 bg-[#fcfcfd] cursor-default",n&&"h-0 opacity-0"),style:t&&{position:"sticky",top:-.2}||{},children:[Re.jsx(Z$,{}),e.getHeaderGroups().map((e=>Re.jsx("tr",{children:e.headers.map((e=>{var t;let o=e.getSize();o&&(o=`min-w-[${o}px] w-[${o}px] max-w-[${o}px]`);const r="actions"===(null==(t=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}(e.headerGroup.headers))?void 0:t.id),i=e.headerGroup.headers[e.headerGroup.headers.length-(r?2:1)];return((null==i?void 0:i.id)===e.id||!o)&&(o="w-full"),Re.jsx("th",{colSpan:e.colSpan,className:ho(o,"px-2.5 py-0","text-delta-500 bg-transparent border-none text-start text-[10px] font-semibold uppercase justify-start"),style:{maxWidth:e.column.columnDef.maxSize,minWidth:e.column.columnDef.minSize},children:e.isPlaceholder?null:Re.jsxs("div",{className:ho("flex items-center justify-left",n?"h-0":"h-[30px]",e.column.getCanSort()||"actions"===e.column.id?"cursor-pointer select-none":"",e.column.columnDef.className),onClick:e.column.getToggleSortingHandler(),children:[K$(e.column.columnDef.header,e.getContext()),{asc:Re.jsx(Il,{className:"text-delta-800"}),desc:Re.jsx(_l,{className:"text-delta-800"})}[e.column.getIsSorted()]??null]})},e.id)}))},e.id))),Re.jsx(Z$,{})]})}const Z$=()=>Re.jsx("tr",{className:"bg-[#fcfcfd] w-full relative table-row",children:Re.jsx("th",{className:"w-[calc(100%-1px)] p-0 bg-[#fcfcfd] border-b-solid border-t-transparent border-x-0 border-[0.5px] border-b-delta-300 h-full absolute-center"})});const X$=e=>Re.jsx(O,{...e});function Q$({tableData:e,actions:t}){const{anchorEl:n,open:o,handleClose:r,handleOpen:i}=NV();return Re.jsxs("div",{className:"flex justify-center items-center",children:[Re.jsx(NR,{dataTest:"test",variant:"text",size:"small",onClick:e=>{e.stopPropagation(),e.preventDefault(),i(e)},onMouseDown:e=>{e.stopPropagation(),e.preventDefault()},onMouseUp:e=>{e.stopPropagation(),e.preventDefault()},children:Re.jsx(jl,{className:"!text-delta-800",width:20,height:20})}),Re.jsx(X$,{open:o,anchorEl:n,onClose:r,onClick:r,anchorOrigin:{horizontal:"center",vertical:"bottom"},transformOrigin:{vertical:"top",horizontal:"right"},children:t(e.row).filter((e=>!e.hide)).map((t=>Re.jsx(zV,{className:t.className,disabled:t.disabled,onClick:()=>{var n;null==(n=t.onClick)||n.call(t,e.row)},onMouseDown:e=>{e.stopPropagation(),e.preventDefault()},onMouseUp:e=>{e.stopPropagation(),e.preventDefault()},children:t.label},t.label)))})]})}function J$({headerData:e}){const{anchorEl:t,open:n,handleClose:o,handleOpen:r}=NV();return Re.jsxs("div",{className:"w-full flex items-center justify-end ",children:[Re.jsx("div",{className:"px-2.5 h-[30px] flex items-center justify-center",onClick:r,children:Re.jsx(Xi,{icon:"mdi:pin",className:"text-delta-500 hover:text-delta-600 min-w-[20px] min-h-[20px]"})}),Re.jsx(X$,{anchorEl:t,anchorOrigin:{horizontal:"left",vertical:"bottom"},open:n,onClose:o,children:e.table.getAllLeafColumns().filter((e=>e.getCanHide()&&e.id!==XV)).map((e=>e.columnDef.header?Re.jsxs(zV,{onClick:()=>e.toggleVisibility(!e.getIsVisible()),children:[Re.jsx(jN,{size:"small",dataTest:"test",disableRipple:!0,className:"p-0 pr-2",checked:e.getIsVisible()}),"string"==typeof e.columnDef.header?e.columnDef.header:e.id]},e.id):null))})]})}function ez({columns:e,expandArrow:t,enableRowSelection:n,headerPin:o,actions:r,customActionsNode:i}){!e.find((e=>"actions"===e.id))&&(r||i||o)&&e.push(function(e){const{headerPin:t,actions:n,customActionsNode:o}=e;return{id:"actions",enableHiding:!1,enableSorting:!1,accessorFn:e=>e,header:e=>t?Re.jsx(J$,{headerData:e}):null,cell:e=>n||o?Re.jsxs("div",{className:"flex gap-2 items-center justify-end",children:[o&&(null==o?void 0:o(e)),n&&Re.jsx(Q$,{tableData:e,actions:n})]}):null,size:50}}({headerPin:o||!1,actions:r,customActionsNode:i})),n&&!e.find((e=>e.id===XV))&&e.unshift({id:XV,minSize:40,maxSize:40,size:40,header:({table:e})=>Re.jsx("div",{className:"w-[25px]",children:Re.jsx(jN,{size:"small",dataTest:"cell-select-all",checked:e.getIsAllRowsSelected(),indeterminate:e.getIsSomeRowsSelected(),onChange:e.getToggleAllRowsSelectedHandler()})}),cell:({cell:e})=>Re.jsx("div",{className:"w-[25px]",children:Re.jsx(jN,{size:"small",dataTest:"cell-select",checked:e.row.getIsSelected(),disabled:!e.row.getCanSelect(),onClick:e=>e.stopPropagation(),onChange:e.row.getToggleSelectedHandler()})})}),t&&!e.find((e=>e.id===QV))&&e.unshift({id:QV,minSize:40,maxSize:40,size:40,enableHiding:!1,enableSorting:!1,header:()=>null,cell:({cell:e})=>{const t=e.row.getIsExpanded();return e.row.getCanExpand()?Re.jsx("span",{className:"flex w-fit h-fit px-2 bg-transparent outline-none focus:outline-none items-center justify-center",onClick:()=>e.row.getToggleExpandedHandler()(),children:t?Re.jsx(Vl,{width:24,height:24}):Re.jsx(Ll,{width:24,height:24})}):null}})}function tz({table:e,locale:t}){const{anchorEl:n,open:o,handleClose:r,handleOpen:i}=NV(),l="no"===t,a=()=>{var e;const t=document.querySelectorAll('[data-index="0"]');null==(e=null==t?void 0:t[0])||e.scrollIntoView({behavior:"smooth",block:"end",inline:"end"})},s=e.getPageCount(),u=e.getState().pagination.pageIndex+1,c=Array.from({length:s},((e,t)=>t+1));return s>1?Re.jsxs("div",{className:"w-fit animate-opacity-in-5 justify-end flex items-center bg-transparent gap-2",children:[Re.jsx(vr,{title:l?"Nåværende side":"Current Page",children:Re.jsx("div",{children:Re.jsxs(NR,{variant:"outlined",dataTest:"list-pages",className:"w-[134px]",onClick:e=>{i(e)},endIcon:o?Re.jsx(Vl,{height:24,width:24}):Re.jsx(Ll,{height:24,width:24}),children:[l?"Side":"Page"," ",u," ",l?"av":"of"," ",s]})})}),Re.jsx(X$,{open:o,anchorEl:n,onClose:r,anchorOrigin:{vertical:-5,horizontal:"center"},transformOrigin:{vertical:"bottom",horizontal:"center"},children:Re.jsx("div",{className:"max-h-[200px] w-[134px] overflow-auto",children:c.map((t=>Re.jsxs("div",{className:ho("h-[36px] relative flex items-center pl-10 cursor-pointer hover:bg-delta-50",u===t&&"bg-gama-50"),onClick:()=>{e.setPageIndex(t-1),r(),a()},children:[u===t&&Re.jsx(zl,{className:"absolute left-2 top-1 text-gama-500",height:24,width:24}),Re.jsxs("span",{children:[l?"Side":"Page"," ",t]})]},t)))})}),Re.jsx(vr,{title:1===u?"":l?"Forrige side":"Previous Page",children:Re.jsx("div",{children:Re.jsx(NR,{variant:"outlined",dataTest:"pagination-ChevronLeftIcon",startIcon:Re.jsx(rl,{height:24,width:24}),onClick:()=>{e.previousPage(),a()},disabled:!e.getCanPreviousPage()})})}),Re.jsx(vr,{title:u===s?"":l?"Neste side":"Next Page",children:Re.jsx("div",{children:Re.jsx(NR,{variant:"outlined",dataTest:"pagination-ChevronRightIcon",startIcon:Re.jsx(ol,{height:24,width:24}),onClick:()=>{e.nextPage(),a()},disabled:!e.getCanNextPage()})})})]}):null}function nz({table:e,locale:t,children:n}){return Re.jsxs("div",{className:"w-full gap-2 bg-transparent flex flex-row py-1 my-1 items-center justify-end ",children:[n,Re.jsx(tz,{table:e,locale:t})]})}const oz=({actions:t,columns:n,data:o,customSubRowData:r,initialState:i,enableRowSelection:l,headerPin:a=!0,loading:s,noRowsOverlay:u,tableInstanceRef:c,className:d,rowHeight:p,tdClassName:f,getRowClassName:h,onRowClick:m,renderSubRows:g,customActionsNode:v,focusable:y,stickyHeader:w,expandArrow:x,height:C,locale:O="en",footer:k,hideHeader:S,hideFooter:E,...R})=>{ez({columns:n,expandArrow:x,enableRowSelection:l,headerPin:a,actions:t,customActionsNode:v});const T=function(t){const n={state:{},onStateChange:()=>{},renderFallbackValue:null,...t},[o]=e.useState((()=>({current:q$(n)}))),[r,i]=e.useState((()=>o.current.initialState));return o.current.setOptions((e=>({...e,...t,state:{...r,...t.state},onStateChange:e=>{i(e),null==t.onStateChange||t.onStateChange(e)}}))),o.current}({...R,columns:n,data:o,initialState:{pagination:{pageIndex:0,pageSize:50},columnVisibility:{...null==i?void 0:i.columnVisibility,[XV]:!1},...i},enableRowSelection:l,getCoreRowModel:e=>o$((()=>[e.options.data]),(t=>{const n={rows:[],flatRows:[],rowsById:{}},o=function(t,r,i){void 0===r&&(r=0);const l=[];for(let s=0;s<t.length;s++){const u=B$(e,e._getRowId(t[s],s,i),t[s],s,r,void 0,null==i?void 0:i.id);var a;n.flatRows.push(u),n.rowsById[u.id]=u,l.push(u),e.options.getSubRows&&(u.originalSubRows=e.options.getSubRows(t[s],s),null!=(a=u.originalSubRows)&&a.length&&(u.subRows=o(u.originalSubRows,r+1,u)))}return l};return n.rows=o(t),n}),{key:"development"===process.env.NODE_ENV&&"getRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getExpandedRowModel:e=>o$((()=>[e.getState().expanded,e.getPreExpandedRowModel(),e.options.paginateExpandedRows]),((e,t,n)=>t.rows.length&&(!0===e||Object.keys(e??{}).length)&&n?G$(t):t),{key:"development"===process.env.NODE_ENV&&"getExpandedRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable}}),getFilteredRowModel:e=>o$((()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter]),((t,n,o)=>{if(!t.rows.length||(null==n||!n.length)&&!o){for(let e=0;e<t.flatRows.length;e++)t.flatRows[e].columnFilters={},t.flatRows[e].columnFiltersMeta={};return t}const r=[],i=[];(n??[]).forEach((t=>{var n;const o=e.getColumn(t.id);if(!o)return;const i=o.getFilterFn();i?r.push({id:t.id,filterFn:i,resolvedValue:null!=(n=null==i.resolveFilterValue?void 0:i.resolveFilterValue(t.value))?n:t.value}):"production"!==process.env.NODE_ENV&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${o.id}.`)}));const l=n.map((e=>e.id)),a=e.getGlobalFilterFn(),s=e.getAllLeafColumns().filter((e=>e.getCanGlobalFilter()));let u,c;o&&a&&s.length&&(l.push("__global__"),s.forEach((e=>{var t;i.push({id:e.id,filterFn:a,resolvedValue:null!=(t=null==a.resolveFilterValue?void 0:a.resolveFilterValue(o))?t:o})})));for(let e=0;e<t.flatRows.length;e++){const n=t.flatRows[e];if(n.columnFilters={},r.length)for(let e=0;e<r.length;e++){u=r[e];const t=u.id;n.columnFilters[t]=u.filterFn(n,t,u.resolvedValue,(e=>{n.columnFiltersMeta[t]=e}))}if(i.length){for(let e=0;e<i.length;e++){c=i[e];const t=c.id;if(c.filterFn(n,t,c.resolvedValue,(e=>{n.columnFiltersMeta[t]=e}))){n.columnFilters.__global__=!0;break}}!0!==n.columnFilters.__global__&&(n.columnFilters.__global__=!1)}}return W$(t.rows,(e=>{for(let t=0;t<l.length;t++)if(!1===e.columnFilters[l[t]])return!1;return!0}),e)}),{key:"development"===process.env.NODE_ENV&&"getFilteredRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getSortedRowModel:e=>o$((()=>[e.getState().sorting,e.getPreSortedRowModel()]),((t,n)=>{if(!n.rows.length||null==t||!t.length)return n;const o=e.getState().sorting,r=[],i=o.filter((t=>{var n;return null==(n=e.getColumn(t.id))?void 0:n.getCanSort()})),l={};i.forEach((t=>{const n=e.getColumn(t.id);n&&(l[t.id]={sortUndefined:n.columnDef.sortUndefined,invertSorting:n.columnDef.invertSorting,sortingFn:n.getSortingFn()})}));const a=e=>{const t=[...e];return t.sort(((e,t)=>{for(let o=0;o<i.length;o+=1){var n;const r=i[o],a=l[r.id],s=null!=(n=null==r?void 0:r.desc)&&n;let u=0;if(a.sortUndefined){const n=void 0===e.getValue(r.id),o=void 0===t.getValue(r.id);(n||o)&&(u=n&&o?0:n?a.sortUndefined:-a.sortUndefined)}if(0===u&&(u=a.sortingFn(e,t,r.id)),0!==u)return s&&(u*=-1),a.invertSorting&&(u*=-1),u}return e.index-t.index})),t.forEach((e=>{var t;r.push(e),null!=(t=e.subRows)&&t.length&&(e.subRows=a(e.subRows))})),t};return{rows:a(n.rows),flatRows:r,rowsById:n.rowsById}}),{key:"development"===process.env.NODE_ENV&&"getSortedRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getPaginationRowModel:e=>o$((()=>[e.getState().pagination,e.getPrePaginationRowModel(),e.options.paginateExpandedRows?void 0:e.getState().expanded]),((t,n)=>{if(!n.rows.length)return n;const{pageSize:o,pageIndex:r}=t;let{rows:i,flatRows:l,rowsById:a}=n;const s=o*r,u=s+o;let c;i=i.slice(s,u),c=e.options.paginateExpandedRows?{rows:i,flatRows:l,rowsById:a}:G$({rows:i,flatRows:l,rowsById:a}),c.flatRows=[];const d=e=>{c.flatRows.push(e),e.subRows.length&&e.subRows.forEach(d)};return c.rows.forEach(d),c}),{key:"development"===process.env.NODE_ENV&&"getPaginationRowModel",debug:()=>{var t;return null!=(t=e.options.debugAll)?t:e.options.debugTable}}),getRowId:R.getRowId||((e,t,n)=>n?[n.id,e.id].join("."):e.id.toString())});c&&(c.current=T);const N=E?T.getCoreRowModel().rows:T.getRowModel().rows;return Re.jsxs("div",{children:[Re.jsx("div",{className:ho("overflow-auto w-full",d),style:{height:C},children:Re.jsxs("table",{className:ho("table box-border border-collapse animate-opacity-appear-3 border-spacing-[1px] max-w-[inherit] m-0 w-[calc(100%-5px)]"),children:[!s&&Re.jsx(Y$,{table:T,stickyHeader:w,hideHeader:S}),Re.jsxs("tbody",{className:"table-row-group align-middle max-w-[inherit]",children:[o.length>0&&s?Re.jsx(Ml,{className:"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 text-gama-500 z-10",width:50,height:50}):null,0===o.length&&s?Re.jsx(Re.Fragment,{children:Array.from({length:5}).map(((e,t)=>Re.jsx("tr",{children:Re.jsx("td",{colSpan:n.length,children:Re.jsx(ne,{variant:"text",width:"100%",height:50},t)})},t)))}):o.length>0?N.map(((e,t)=>((e,t)=>Re.jsxs(b,{children:[Re.jsx("tr",{"data-index":t,"data-test":e.id,id:e.id,tabIndex:y?-1:void 0,className:ho("table-row align-middle border-solid border-x border-t border-b-0 last:border-b-transparent first:border-t-transparent border-x-transparent border-y-delta-300 hover:cursor-pointer hover:bg-gama-25 focus:bg-gama-50 focus:border focus:border-gama-500",(e.getIsExpanded()||e.getIsSelected())&&"bg-gama-50",s&&"opacity-50",null==h?void 0:h(e)),style:{height:p?`${p}px`:"inherit"},onMouseDown:t=>{t.target.classList.contains("MuiModal-backdrop")||"INPUT"===t.target.nodeName||"BUTTON"===t.target.nodeName||(e.getCanExpand()&&!x&&e.getToggleExpandedHandler()(),m&&m(t,e))},children:e.getVisibleCells().map((e=>Re.jsx("td",{className:ho("break-words table-cell align-middle text-sm text-delta-900 whitespace-pre-wrap","px-2.5 py-0",f),children:K$(e.column.columnDef.cell,e.getContext())},e.id)))}),e.getIsExpanded()&&Re.jsx(Re.Fragment,{children:r&&g&&g({rows:r.get(e.original.id.toString())??[],row:e.original})})]},e.id))(e,t))):Re.jsx("tr",{className:"h-28",children:Re.jsx("td",{colSpan:n.length,className:"text-center align-middle text-sm text-delta-900",children:u})})]})]})}),!E&&Re.jsx(nz,{table:T,locale:O,children:null==k?void 0:k(T)})]})},rz="_title_17oo0_1",iz=function(e){return Re.jsx("div",{className:rz,children:e.children})},lz=function(e){return Re.jsx("h1",{"data-test":e.dataTest,className:"font-roboto md:mb-2 mb-5 text-2xl font-bold leading-10 text-[#17232E]",children:e.children})},az=()=>{const[e,t]=l(null),n=()=>{t((()=>null))};return{anchorEl:e,onClose:n,onAnchorClick:o=>{e?n():(e=>{t((()=>e.currentTarget))})(o)}}},sz=({filterIsActive:e,popoverContent:t,dataTest:n,disabled:o,size:r="large",variant:i="outlined"})=>{const{onAnchorClick:l,onClose:a,anchorEl:s}=az();return Re.jsxs(Re.Fragment,{children:[Re.jsxs("div",{className:"w-fit h-fit relative",children:[Re.jsx(NR,{disabled:o,variant:i,startIcon:Re.jsx(Xl,{width:"large"===r?24:20,height:"large"===r?24:20}),onClick:l,size:r,dataTest:n,children:"Filter"}),e&&Re.jsx("div",{className:ho("h-2 w-2 bg-gama-400 rounded-full absolute","large"===r?"top-2 right-2":"top-1 right-1")})]}),Re.jsx(X$,{open:!!s,anchorEl:s,onClose:a,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},className:"my-1",children:t})]})},uz=({onCloseText:e,onMinimizeText:t,onExpandText:n,showCloseIcon:o=!0,showMinimizeIcon:r=!0,showExpandIcon:i=!0,title:a,label:s,children:u,open:c,onClose:d,className:p="",primaryButtonText:f,secondaryButtonText:h,onPrimaryButtonClick:m,onSecondaryButtonClick:g,dataTest:b})=>{const[v,y]=l(!1),w=()=>{y(!v)};return c?v?Re.jsx("div",{className:"fixed bottom-4 right-4 z-[51] w-[387px] rounded-lg bg-white py-2 pl-4 pr-3 shadow-[0_4px_40px_0px_rgba(34,33,51,0.4)] transition-all duration-300",children:Re.jsxs("div",{className:"flex items-center justify-between","data-test":b,children:[Re.jsx("div",{className:"truncate text-lg font-semibold text-delta-800",children:a}),Re.jsxs("div",{className:"flex gap-x-1",children:[Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"minimize-button",variant:"text",size:"small",onClick:w,endIcon:i&&Re.jsx(ga,{height:20,width:20,color:"text-gama-500"}),children:n})}),Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"close-button",variant:"textGray",size:"small",onClick:d,endIcon:o&&Re.jsx($l,{height:20,width:20,color:"text-delta-700"}),children:e})})]})]})}):Re.jsxs("div",{className:ho("fixed bottom-4 right-4 z-[51] rounded-lg bg-white shadow-[0_4px_40px_0px_rgba(34,33,51,0.4)] transition-all duration-300",p),"data-test":b,children:[Re.jsxs("div",{className:"fixed-top flex flex-col gap-y-2 p-4",children:[Re.jsxs("div",{className:"flex items-center justify-between",children:[s?Re.jsx("div",{className:"text-sm text-delta-700",children:s}):Re.jsx("div",{className:"text-2xl font-semibold text-delta-800",children:a}),Re.jsxs("div",{className:"flex gap-x-1",children:[Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"minimize-button",variant:"textGray",size:"small",onClick:w,endIcon:r&&Re.jsx(ma,{height:20,width:20,color:"text-delta-700"}),children:t})}),Re.jsx("div",{className:"flex items-center gap-x-2",children:Re.jsx(NR,{dataTest:"close-button",variant:"textGray",size:"small",onClick:d,endIcon:Re.jsx($l,{height:20,width:20,color:"text-delta-700"}),children:e})})]})]}),s&&Re.jsx("div",{className:"text-2xl font-semibold text-delta-800",children:a})]}),Re.jsx("div",{children:u}),Re.jsxs("div",{className:"fixed-bottom flex justify-end gap-x-4 border-t-[1px] border-delta-200 p-4",children:[h&&g&&Re.jsx(NR,{dataTest:"cancel-button",variant:"outlined",onClick:g,children:h}),f&&m&&Re.jsx(NR,{dataTest:"save-button",onClick:m,children:f})]})]}):null};export{JV as ACTIONS_COLUMN_ID,Dl as ArchiveIcon,bl as AssignmentIcon,vl as AssignmentOutlineIcon,oe as Avatar,va as BadgeIcon,tl as BellIcon,el as BellOutlineIcon,na as CalendarBlankOutlineIcon,ml as CalendarIcon,gl as CalendarRangeIcon,Al as CheckBoxCheckedIcon,hl as CheckFactOutlineIcon,zl as CheckIcon,fl as CheckOutlineIcon,il as ChevronDoubleLeftIcon,ll as ChevronDoubleRightIcon,Ll as ChevronDownIcon,rl as ChevronLeftIcon,ol as ChevronRightIcon,Vl as ChevronUpIcon,re as ClickAwayListener,$l as CloseIcon,ha as ConsentsIcon,ul as DashboardViewIcon,cl as DashboardViewOutlineIcon,Zl as DeleteOutlineIcon,jl as DotsVerticalIcon,Fl as DownloadIcon,Kl as DragHorizontalIcon,_l as DropDownIcon,Il as DropUpIcon,Jl as DvrIcon,QV as EXPAND_COLUMN_ID,ua as EarthIcon,Gl as EmptyPageIcon,ea as ErrorOutlineIcon,ie as Fade,ra as FastCheckOutlineIcon,Yl as FilePdfIcon,Xl as FilterIcon,El as FindReplaceIcon,Rl as FindReplacePeopleIcon,AO as GridRow,nl as HamburgerIcon,IV as HelperText,Bl as InboxOutboxIcon,Ul as InboxOutboxOutlineIcon,ga as KeyboardCapslockIcon,oa as LinkOutlineIcon,yl as ListNumberedIcon,sa as ListSettingsLineIcon,la as ListStatusIcon,Ml as LoadingIcon,Ql as LockIcon,wl as MessageProcessingIcon,xl as MessageProcessingOutlineIcon,ba as MessageReplyIcon,uz as MinimizableDialog,ma as MinimizeIcon,fa as OutlineCalendarMonth,le as Paper,sl as PdfIcon,da as PencilOutlineIcon,pl as PeopleIcon,dl as PeopleOutlineIcon,Hl as PermMediaIcon,ql as PermMediaOutline,Tl as PersonIcon,Nl as PersonOutlineIcon,ae as Popper,al as QnrIcon,ta as ReplayIcon,Cl as ReportBoxIcon,Ol as ReportBoxOutlineIcon,I_ as RichInput,XV as SELECT_COLUMN_ID,Pl as SearchIcon,kl as SettingsIcon,ca as SettingsMenuHorizontalIcon,Sl as SettingsOutlineIcon,kN as SnackbarProvider,KV as StyledAccordion,ZV as StyledAccordionDetails,YV as StyledAccordionSummary,_R as StyledAlert,DR as StyledAlertTitle,Te as StyledBadge,NR as StyledButton,jN as StyledCheckbox,Ne as StyledChip,GV as StyledContainer,ER as StyledDataGrid,RV as StyledDatePicker,jR as StyledDialog,PR as StyledDialogActions,MR as StyledDialogContent,IR as StyledDialogTitle,VV as StyledDrawer,sz as StyledFilterMenu,vV as StyledFormControl,_V as StyledFormControlLabel,pR as StyledFormGroup,DV as StyledFormHelperText,FV as StyledFormLabel,RR as StyledGridActionsCellItem,MN as StyledInput,IN as StyledInputField,AV as StyledInputLabel,PD as StyledLabel,BV as StyledLink,$V as StyledMenu,zV as StyledMenuItem,HV as StyledMenuList,lz as StyledModuleTitle,X$ as StyledPopover,V_ as StyledRadio,$_ as StyledRadioGroup,__ as StyledSelect,F_ as StyledSelectAutocomplete,D_ as StyledSelectItem,A_ as StyledSlider,SN as StyledSnackbar,LV as StyledStack,L_ as StyledSwitch,UV as StyledTab,oz as StyledTable,WV as StyledTabs,DN as StyledTextarea,MV as StyledTimePicker,vr as StyledTooltip,ya as StyledTypography,iz as StyledWidgetTitle,aa as TextBoxCheckOutlineIcon,Wl as TopicIcon,ia as UnknownDocumentOutlineRoundedIcon,pa as WarningAmberOutlineIcon,aN as closeSnackbar,U$ as createColumnHelper,lN as enqueueSnackbar,kg as gridDateComparator,NN as message,be as omit,ve as pick,EN as processAlertSnackBar,RN as processInfoSnackbar,ye as tokenOptimizer,xN as useSnackbar};
@@ -16,4 +16,5 @@ export declare const MinimizableDialog: React.FC<{
16
16
  secondaryButtonText?: string;
17
17
  onPrimaryButtonClick?: () => void;
18
18
  onSecondaryButtonClick?: () => void;
19
+ dataTest?: string;
19
20
  }>;
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "2.20.19",
6
+ "version": "2.20.20",
7
7
  "type": "module",
8
8
  "files": [
9
9
  "dist/**/*",