mantine-datatable 6.0.2 → 6.0.4

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.
package/README.md CHANGED
@@ -10,8 +10,8 @@
10
10
  [![Language][language-image]][repo-url]
11
11
  [![Sponsor the author][sponsor-image]][sponsor-url]
12
12
 
13
- ⚠️ Mantine DataTable V6 supports Mantine V6.
14
- 💡 Mantine V7 support is in the works, and I could really use your help to speed things up. Please consider [sponsoring my work](https://github.com/sponsors/icflorescu) 🙏
13
+ ⚠️ Mantine DataTable V6 is compatible with [Mantine V6](https://v6.mantine.dev/).
14
+ 💡 If you're using Mantine V7, please use [Mantine DataTable V7](https://icflorescu.github.io/mantine-datatable/).
15
15
 
16
16
  The lightweight, dependency-free, "dark-theme aware" [**table component**](https://icflorescu.github.io/mantine-datatable-v6/) for your Mantine UI data-rich applications, featuring asynchronous data loading support, pagination, intuitive Gmail-style additive batch rows selection, column sorting, custom cell data rendering, row context menu, row expansion, nesting, and more.
17
17
 
@@ -40,7 +40,7 @@ Emil Sorensen @ [kapa.ai](https://kapa.ai/):
40
40
 
41
41
  > _Mantine DataTable is a great component that’s core to our web app - it saves us a ton of time and comes with great styling and features out of the box_
42
42
 
43
- [![Who's using Mantine DataTable](https://user-images.githubusercontent.com/581999/258483859-f8f46b97-5900-4871-8243-c7316fbc244f.png)](https://icflorescu.github.io/mantine-datatable/)
43
+ [![Who's using Mantine DataTable](https://user-images.githubusercontent.com/581999/258483859-f8f46b97-5900-4871-8243-c7316fbc244f.png)](https://icflorescu.github.io/mantine-datatable-v6/)
44
44
 
45
45
  [Mantine DataTable](https://icflorescu.github.io/mantine-datatable-v6/) is used by developers and startups around the world, such as: [kapa.ai](https://kapa.ai/), [exdatis.ai](https://exdatis.ai/), [teachfloor](https://www.teachfloor.com/), [MARKUP](https://www.getmarkup.com/), [BookieBase](https://bookiebase.ie/), [zipline](https://zipline.diced.tech/), [Pachtop](https://github.com/pacholoamit/pachtop), [Ganymede](https://github.com/Zibbp/ganymede), [COH3 Stats](https://coh3stats.com/), [Culver City Rental Registry](https://www.ccrentals.org/) and many more.
46
46
 
@@ -52,13 +52,13 @@ Visit [icflorescu.github.io/mantine-datatable-v6](https://icflorescu.github.io/m
52
52
 
53
53
  ## Quickstart
54
54
 
55
- Install the package and its dependencies (Mantine v7 is not currently supported, so use v6.0.21):
55
+ Install the package and its dependencies (this package supports Mantine V6; the V7 version is under development):
56
56
 
57
57
  ```sh
58
58
  npm i @mantine/core@6 @mantine/hooks@6 @emotion/react mantine-datatable@6
59
59
  ```
60
60
 
61
- If you're using Next.js, Vite, CRA, Remix or Gatsby, you might need to install additional dependencies. Please refer to Mantine's [getting started page](https://mantine.dev/pages/getting-started/) for more details.
61
+ If you're using Next.js, Vite, CRA, Remix or Gatsby, you might need to install additional dependencies. Please refer to Mantine's [getting started page](https://v6.mantine.dev/pages/getting-started/) for more details.
62
62
 
63
63
  Use it in your code:
64
64
 
package/dist/index.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";var za=Object.create;var Jo=Object.defineProperty;var Ga=Object.getOwnPropertyDescriptor;var Va=Object.getOwnPropertyNames;var Xa=Object.getPrototypeOf,Qa=Object.prototype.hasOwnProperty;var Za=(o,e)=>()=>(o&&(e=o(o=0)),e);var be=(o,e)=>()=>(e||o((e={exports:{}}).exports,e),e.exports),Ka=(o,e)=>{for(var r in e)Jo(o,r,{get:e[r],enumerable:!0})},ur=(o,e,r,t)=>{if(e&&typeof e=="object"||typeof e=="function")for(let f of Va(e))!Qa.call(o,f)&&f!==r&&Jo(o,f,{get:()=>e[f],enumerable:!(t=Ga(e,f))||t.enumerable});return o};var pr=(o,e,r)=>(r=o!=null?za(Xa(o)):{},ur(e||!o||!o.__esModule?Jo(r,"default",{value:o,enumerable:!0}):r,o)),$a=o=>ur(Jo({},"__esModule",{value:!0}),o);var d,a=Za(()=>{"use strict";d=pr(require("react"),1)});var Ir=be((Mt,xr)=>{"use strict";a();var _a="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";xr.exports=_a});var Sr=be((Rt,Cr)=>{"use strict";a();var ja=Ir();function ir(){}function gr(){}gr.resetWarningCache=ir;Cr.exports=function(){function o(t,f,n,l,s,u){if(u!==ja){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}}o.isRequired=o;function e(){return o}var r={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:e,element:o,elementType:o,instanceOf:e,node:o,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:gr,resetWarningCache:ir};return r.PropTypes=r,r}});var br=be((Lt,hr)=>{a();hr.exports=Sr()();var Ot,At});var yt={};Ka(yt,{DataTable:()=>Ye,differenceBy:()=>ee,getValueAtPath:()=>Eo,humanize:()=>_,uniqBy:()=>Co});module.exports=$a(yt);a();a();var G=require("@mantine/core"),Jr=require("@mantine/hooks"),L=require("react");a();var mr=require("@mantine/core"),Be=require("react/jsx-runtime"),Ya=(0,mr.createStyles)({root:{"&&":{background:"transparent",":last-of-type td":{borderBottom:"none"}}}});function De(){let{classes:o}=Ya();return(0,Be.jsx)("tr",{className:o.root,children:(0,Be.jsx)("td",{})})}a();var Io=require("@mantine/core");a();a();var No=require("react"),$=pr(br());a();var Br={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};var Ja=Object.defineProperty,ot=Object.defineProperties,et=Object.getOwnPropertyDescriptors,oe=Object.getOwnPropertySymbols,Pr=Object.prototype.hasOwnProperty,Tr=Object.prototype.propertyIsEnumerable,Dr=(o,e,r)=>e in o?Ja(o,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):o[e]=r,yr=(o,e)=>{for(var r in e||(e={}))Pr.call(e,r)&&Dr(o,r,e[r]);if(oe)for(var r of oe(e))Tr.call(e,r)&&Dr(o,r,e[r]);return o},rt=(o,e)=>ot(o,et(e)),at=(o,e)=>{var r={};for(var t in o)Pr.call(o,t)&&e.indexOf(t)<0&&(r[t]=o[t]);if(o!=null&&oe)for(var t of oe(o))e.indexOf(t)<0&&Tr.call(o,t)&&(r[t]=o[t]);return r},Y=(o,e,r)=>{let t=(0,No.forwardRef)((f,n)=>{var l=f,{color:s="currentColor",size:u=24,stroke:m=2,children:p}=l,C=at(l,["color","size","stroke","children"]);return(0,No.createElement)("svg",yr(rt(yr({ref:n},Br),{width:u,height:u,stroke:s,strokeWidth:m,className:`tabler-icon tabler-icon-${o}`}),C),[...r.map(([c,I])=>(0,No.createElement)(c,I)),...p||[]])});return t.propTypes={color:$.default.string,size:$.default.oneOfType([$.default.string,$.default.number]),stroke:$.default.oneOfType([$.default.string,$.default.number])},t.displayName=`${e}`,t};a();var ye=Y("arrow-up","IconArrowUp",[["path",{d:"M12 5l0 14",key:"svg-0"}],["path",{d:"M18 11l-6 -6",key:"svg-1"}],["path",{d:"M6 11l6 -6",key:"svg-2"}]]);a();var Pe=Y("arrows-vertical","IconArrowsVertical",[["path",{d:"M8 7l4 -4l4 4",key:"svg-0"}],["path",{d:"M8 17l4 4l4 -4",key:"svg-1"}],["path",{d:"M12 3l0 18",key:"svg-2"}]]);a();var Te=Y("database-off","IconDatabaseOff",[["path",{d:"M12.983 8.978c3.955 -.182 7.017 -1.446 7.017 -2.978c0 -1.657 -3.582 -3 -8 -3c-1.661 0 -3.204 .19 -4.483 .515m-2.783 1.228c-.471 .382 -.734 .808 -.734 1.257c0 1.22 1.944 2.271 4.734 2.74",key:"svg-0"}],["path",{d:"M4 6v6c0 1.657 3.582 3 8 3c.986 0 1.93 -.067 2.802 -.19m3.187 -.82c1.251 -.53 2.011 -1.228 2.011 -1.99v-6",key:"svg-1"}],["path",{d:"M4 12v6c0 1.657 3.582 3 8 3c3.217 0 5.991 -.712 7.261 -1.74m.739 -3.26v-4",key:"svg-2"}],["path",{d:"M3 3l18 18",key:"svg-3"}]]);a();var we=Y("filter","IconFilter",[["path",{d:"M4 4h16v2.172a2 2 0 0 1 -.586 1.414l-4.414 4.414v7l-6 2v-8.5l-4.48 -4.928a2 2 0 0 1 -.52 -1.345v-2.227z",key:"svg-0"}]]);var Q=require("react/jsx-runtime"),tt=(0,Io.createStyles)(o=>({root:{position:"absolute",top:0,right:0,bottom:0,left:0,flexDirection:"column",pointerEvents:"none",color:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[6],opacity:0,transition:"opacity .15s ease"},active:{opacity:1},standardIcon:{fontSize:0,borderRadius:"50%",padding:o.spacing.xs,background:o.colorScheme==="dark"?o.colors.dark[5]:o.colors.gray[2]}}));function Fe({icon:o,text:e,pt:r,pb:t,active:f,children:n}){let{classes:l,cx:s}=tt();return(0,Q.jsx)(Io.Center,{pt:r,pb:t,className:s(l.root,{[l.active]:f}),children:n||(0,Q.jsxs)(Q.Fragment,{children:[o||(0,Q.jsx)("div",{className:l.standardIcon,children:(0,Q.jsx)(Te,{})}),(0,Q.jsx)(Io.Text,{size:"sm",color:"dimmed",children:e})]})})}a();var te=require("@mantine/core"),Or=require("react");a();var re=require("@mantine/core");a();var Me=require("@mantine/core"),Fr=require("@mantine/hooks"),no=require("react");a();var io=require("react");function ft(o,e){let r=()=>{e(o.map(f=>f.matches))},t=o.map(f=>{try{return f.addEventListener("change",r),()=>f.removeEventListener("change",r)}catch{return f.addListener(r),()=>f.removeListener(r)}});return()=>{t.forEach(f=>f())}}function nt(o,e){return e||(typeof window<"u"&&"matchMedia"in window?o.map(r=>window.matchMedia(r).matches):o.map(()=>!1))}function wr(o,e,{getInitialValueInEffect:r}={getInitialValueInEffect:!0}){let[t,f]=(0,io.useState)(r?e:nt(o,e)),n=(0,io.useRef)();return(0,io.useEffect)(()=>{if("matchMedia"in window)return n.current=o.map(l=>window.matchMedia(l)),f(n.current.map(l=>l.matches)),ft(n.current,l=>{f(l)})},[o]),t}var Mr=typeof window<"u"?no.useLayoutEffect:no.useEffect;function go(o){let e=(0,Me.useMantineTheme)(),r=typeof o=="function"?o(e):o;return(0,Fr.useMediaQuery)(r||"",!0)}function kr(o){let e=(0,Me.useMantineTheme)(),r=(0,no.useMemo)(()=>o.map(f=>(typeof f=="function"?f(e):f)??""),[o,e]),t=(0,no.useMemo)(()=>o.map(()=>!0),[o]);return wr(r,t)}function _(o){let e=o.replace(/([a-z\d])([A-Z]+)/g,"$1 $2").replace(/\W|_/g," ").trim().toLowerCase();return`${e.charAt(0).toUpperCase()}${e.slice(1)}`}function ee(o,e,r){return o.filter(t=>!e.map(r).includes(r(t)))}function Co(o,e){return o.filter((r,t,f)=>t===f.findIndex(n=>e(r)===e(n)))}function Eo(o,e){return e?e.match(/([^[.\]])+/g).reduce((t,f)=>t&&t[f],o):void 0}function y(o,e){return typeof e=="string"?Eo(o,e):e(o)}var Rr=require("react/jsx-runtime"),lt=(0,re.createStyles)({noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function ke({className:o,sx:e,style:r,visibleMediaQuery:t,title:f,noWrap:n,ellipsis:l,textAlignment:s,width:u}){let{cx:m,classes:p}=lt();return go(t)?(0,Rr.jsx)(re.Box,{component:"th",className:m({[p.noWrap]:n||l,[p.ellipsis]:l},o),sx:[{"&&":{textAlign:s},width:u,minWidth:u,maxWidth:u},e],style:r,children:f}):null}a();var ae=require("@mantine/core"),vr=require("react/jsx-runtime"),st=(0,ae.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",width:0,left:0,background:"inherit","&::after":{content:'""',position:"absolute",top:0,right:-(0,ae.px)(o.spacing.sm),bottom:0,borderLeft:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`,pointerEvents:"none",opacity:0,transition:"opacity .15s ease"}},shadowVisible:{"&::after":{opacity:1}}}});function Re({shadowVisible:o}){let{cx:e,classes:r}=st();return(0,vr.jsx)("th",{className:e(r.root,{[r.shadowVisible]:o})})}var So=require("react/jsx-runtime"),dt=(0,te.createStyles)((o,{scrollDiff:e,borderColor:r})=>{let t=e<0,f=typeof r=="function"?r(o):r;return{root:{zIndex:2,position:t?"relative":"sticky",bottom:t?e:-1,background:o.colorScheme==="dark"?o.colors.dark[7]:o.white,"&& tr th":{borderTopColor:f}},relative:{position:"relative"},textSelectionDisabled:{userSelect:"none"}}}),Ar=(0,Or.forwardRef)(function({className:e,style:r,borderColor:t,columns:f,defaultColumnProps:n,selectionVisible:l,leftShadowVisible:s,scrollDiff:u},m){let{cx:p,classes:C}=dt({scrollDiff:u,borderColor:t});return(0,So.jsx)(te.Box,{component:"tfoot",ref:m,className:p(C.root,e),style:r,children:(0,So.jsxs)("tr",{children:[l&&(0,So.jsx)(Re,{shadowVisible:s}),f.map(({hidden:c,...I})=>{if(c)return null;let{accessor:P,visibleMediaQuery:i,textAlignment:S,width:g,footer:D,footerClassName:h,footerStyle:V,footerSx:v,noWrap:w,ellipsis:M}={...n,...I};return(0,So.jsx)(ke,{className:h,style:V,sx:v,visibleMediaQuery:i,textAlignment:S,width:g,title:D,noWrap:w,ellipsis:M},P)})]})})});a();var Er=require("@mantine/core"),qr=require("react");a();var Lr=require("@mantine/core"),ve=require("react");var Hr=require("react/jsx-runtime");function Oe({group:{id:o,columns:e,title:r,className:t,style:f,sx:n}}){let l=(0,ve.useMemo)(()=>e.map(({visibleMediaQuery:m})=>m),[e]),s=kr(l),u=(0,ve.useMemo)(()=>e.filter(({hidden:m},p)=>!m&&s?.[p]).length,[e,s]);return u>0?(0,Hr.jsx)(Lr.Box,{component:"th",colSpan:u,className:t,sx:n,style:f,children:r??_(o)}):null}a();var q=require("@mantine/core");a();var ho=require("@mantine/core"),Nr=require("@mantine/hooks");var lo=require("react/jsx-runtime");function Ae({children:o,isActive:e}){let[r,{close:t,toggle:f}]=(0,Nr.useDisclosure)(!1);return(0,lo.jsxs)(ho.Popover,{withArrow:!0,withinPortal:!0,shadow:"md",opened:r,onClose:t,trapFocus:!0,children:[(0,lo.jsx)(ho.Popover.Target,{children:(0,lo.jsx)(ho.ActionIcon,{onClick:n=>{n.preventDefault(),f()},variant:e?"default":"subtle",children:(0,lo.jsx)(we,{size:14})})}),(0,lo.jsx)(ho.Popover.Dropdown,{onClick:n=>n.preventDefault(),children:typeof o=="function"?o({close:t}):o})]})}var R=require("react/jsx-runtime"),ct=(0,q.createStyles)(o=>({sortableColumnHeader:{cursor:"pointer",transition:"background .15s ease","&:hover:not(:has(button:hover))":{background:o.colorScheme==="dark"?o.colors.dark[6]:o.colors.gray[0]}},sortableColumnHeaderGroup:{gap:"0.25em"},columnHeaderText:{overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},sortableColumnHeaderText:{minWidth:0,flexGrow:1},sortableColumnHeaderIcon:{transition:"transform .15s ease"},sortableColumnHeaderIconRotated:{transform:"rotate3d(0, 0, 1, 180deg)"},sortableColumnHeaderUnsortedIcon:{color:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[5],transition:"color .15s ease","th:hover &":{color:o.colorScheme==="dark"?o.colors.dark[2]:o.colors.gray[6]}}}));function Le({className:o,sx:e,style:r,accessor:t,visibleMediaQuery:f,title:n,sortable:l,sortIcons:s,textAlignment:u,width:m,sortStatus:p,onSortStatusChange:C,filter:c,filtering:I}){let{cx:P,classes:i}=ct();if(!go(f))return null;let S=n??_(t),g=typeof S=="string"?S:void 0,D=l&&C?h=>{h?.defaultPrevented||C({columnAccessor:t,direction:p?.columnAccessor===t?p.direction==="asc"?"desc":"asc":p?.direction??"asc"})}:void 0;return(0,R.jsx)(q.Box,{component:"th",className:P({[i.sortableColumnHeader]:l},o),sx:[{"&&":{textAlign:u},width:m,minWidth:m,maxWidth:m},e],style:r,role:l?"button":void 0,tabIndex:l?0:void 0,onClick:D,onKeyDown:h=>h.key==="Enter"&&D?.(),children:(0,R.jsxs)(q.Group,{className:i.sortableColumnHeaderGroup,position:"apart",noWrap:!0,children:[(0,R.jsx)(q.Box,{className:P(i.columnHeaderText,i.sortableColumnHeaderText),title:g,children:S}),l||p?.columnAccessor===t?(0,R.jsx)(R.Fragment,{children:p?.columnAccessor===t?(0,R.jsx)(q.Center,{className:P(i.sortableColumnHeaderIcon,{[i.sortableColumnHeaderIconRotated]:p.direction==="desc"}),role:"img","aria-label":`Sorted ${p.direction==="desc"?"descending":"ascending"}`,children:s?.sorted||(0,R.jsx)(ye,{size:14})}):(0,R.jsx)(q.Center,{className:i.sortableColumnHeaderUnsortedIcon,role:"img","aria-label":"Not sorted",children:s?.unsorted||(0,R.jsx)(Pe,{size:14})})}):null,c?(0,R.jsx)(Ae,{isActive:!!I,children:c}):null]})})}a();var bo=require("@mantine/core"),He=require("react/jsx-runtime"),ut=(0,bo.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",width:0,left:0,background:"inherit","&::after":{content:'""',position:"absolute",top:0,right:-(0,bo.px)(o.spacing.sm),bottom:0,borderLeft:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`,pointerEvents:"none",opacity:0,transition:"opacity .15s ease"}},shadowVisible:{"&::after":{opacity:1}},checkboxInput:{cursor:"pointer"}}});function Ne({shadowVisible:o,checked:e,indeterminate:r,checkboxProps:t,onChange:f,rowSpan:n}){let{cx:l,classes:s}=ut();return(0,He.jsx)("th",{className:l(s.root,{[s.shadowVisible]:o}),rowSpan:n,children:(0,He.jsx)(bo.Checkbox,{classNames:{input:s.checkboxInput},checked:e,indeterminate:r,disabled:!f,onChange:f,...t})})}var j=require("react/jsx-runtime"),pt=(0,Er.createStyles)(o=>({root:{zIndex:2,position:"sticky",top:0,background:o.colorScheme==="dark"?o.colors.dark[7]:o.white},textSelectionDisabled:{userSelect:"none"}})),Wr=(0,qr.forwardRef)(function({className:e,style:r,sortStatus:t,sortIcons:f,onSortStatusChange:n,columns:l,defaultColumnProps:s,groups:u,selectionVisible:m,selectionChecked:p,selectionIndeterminate:C,onSelectionChange:c,selectionCheckboxProps:I,leftShadowVisible:P},i){let{classes:S,cx:g}=pt(),D=m?(0,j.jsx)(Ne,{shadowVisible:P,checked:p,indeterminate:C,checkboxProps:I,onChange:c,rowSpan:u?2:void 0}):null;return(0,j.jsxs)("thead",{className:g(S.root,e),style:r,ref:i,children:[u&&(0,j.jsxs)("tr",{children:[D,u.map(h=>(0,j.jsx)(Oe,{group:h},h.id))]}),(0,j.jsxs)("tr",{children:[!u&&D,l.map(({hidden:h,...V})=>{if(h)return null;let{accessor:v,visibleMediaQuery:w,textAlignment:M,width:H,title:O,sortable:N,titleClassName:po,titleStyle:To,titleSx:wo,filter:Fo,filtering:Mo}={...s,...V};return(0,j.jsx)(Le,{accessor:v,className:po,style:To,sx:wo,visibleMediaQuery:w,textAlignment:M,width:H,title:O,sortable:N,sortStatus:t,sortIcons:f,onSortStatusChange:n,filter:Fo,filtering:Mo},v)})]})]})});a();var Bo=require("@mantine/core"),Ee=require("react/jsx-runtime"),mt=(0,Bo.createStyles)(o=>({root:{zIndex:3,position:"absolute",top:0,left:0,right:0,bottom:0,pointerEvents:"none",background:o.fn.rgba(o.colorScheme==="dark"?o.colors.dark[8]:o.white,.75),opacity:0,transition:"opacity .15s ease"},fetching:{pointerEvents:"all",opacity:1}}));function qe({pt:o,pb:e,fetching:r,customContent:t,backgroundBlur:f,size:n,variant:l,color:s}){let{classes:u,cx:m}=mt();return(0,Ee.jsx)(Bo.Center,{pt:o,pb:e,className:m(u.root,{[u.fetching]:r}),sx:f?{backdropFilter:`blur(${f}px)`}:void 0,children:r&&(t||(0,Ee.jsx)(Bo.Loader,{size:n,variant:l,color:s}))})}a();var J=require("@mantine/core"),zr=require("react");a();var A=require("@mantine/core"),W=require("react/jsx-runtime"),Ur={xs:22,sm:26,md:32,lg:38,xl:44};function We({size:o,label:e,values:r,value:t,onChange:f,color:n}){return(0,W.jsxs)(A.Group,{spacing:"xs",children:[(0,W.jsx)(A.Text,{size:o,children:e}),(0,W.jsxs)(A.Menu,{withinPortal:!0,withArrow:!0,children:[(0,W.jsx)(A.Menu.Target,{children:(0,W.jsx)(A.Button,{size:o,variant:"default",sx:[{fontWeight:"normal"},l=>({height:Ur[o],paddingLeft:l.spacing[o],paddingRight:l.spacing[o]})],children:t})}),(0,W.jsx)(A.Menu.Dropdown,{children:r.map(l=>{let s=l===t;return(0,W.jsx)(A.Menu.Item,{sx:[{height:Ur[o]},u=>({"&&":{color:s?u.white:void 0},background:s?u.colors[n||u.primaryColor][6]:void 0})],disabled:s,onClick:()=>f(l),children:(0,W.jsx)(A.Text,{size:o,children:l})},l)})})]})]})}var Do=require("react/jsx-runtime"),xt=(0,J.createStyles)((o,{topBorderColor:e,paginationWrapBreakpoint:r})=>({root:{background:o.colorScheme==="dark"?o.colors.dark[7]:o.white,borderTop:`1px solid ${typeof e=="function"?e(o):e}`,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"space-between",gap:o.spacing.xs,[o.fn.largerThan(r)]:{flexDirection:"row"}},text:{flex:"1 1 auto"},pagination:{opacity:1,transition:"opacity .15s ease"},paginationFetching:{opacity:0}})),Gr=(0,zr.forwardRef)(function({className:e,style:r,topBorderColor:t,fetching:f,page:n,onPageChange:l,paginationColor:s,paginationSize:u,loadingText:m,noRecordsText:p,paginationText:C,totalRecords:c,recordsPerPage:I,onRecordsPerPageChange:P,recordsPerPageLabel:i,recordsPerPageOptions:S,recordsLength:g,horizontalSpacing:D,paginationWrapBreakpoint:h,getPaginationControlProps:V},v){let w;if(f)w=m;else if(!c)w=p;else{let O=(n-1)*I+1,N=O+g-1;w=C({from:O,to:N,totalRecords:c})}let{classes:M,cx:H}=xt({topBorderColor:t,paginationWrapBreakpoint:h});return(0,Do.jsxs)(J.Box,{ref:v,px:D??"xs",py:"xs",className:H(M.root,e),style:r,children:[(0,Do.jsx)(J.Text,{className:M.text,size:u,children:w}),S&&(0,Do.jsx)(We,{size:u,label:i,values:S,color:s,value:I,onChange:P}),(0,Do.jsx)(J.Pagination,{color:s,className:H(M.pagination,{[M.paginationFetching]:f||!g}),value:n,onChange:l,size:u,total:Math.ceil(c/I),getControlProps:V})]})});a();var le=require("@mantine/core");a();var fe=require("@mantine/core");var Vr=require("react/jsx-runtime"),It=(0,fe.createStyles)({withPointerCursor:{cursor:"pointer"},noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function Ue({className:o,sx:e,style:r,visibleMediaQuery:t,record:f,recordIndex:n,onClick:l,noWrap:s,ellipsis:u,textAlignment:m,width:p,accessor:C,render:c,defaultRender:I,customCellAttributes:P}){let{cx:i,classes:S}=It();return go(t)?(0,Vr.jsx)(fe.Box,{component:"td",className:i({[S.noWrap]:s||u,[S.ellipsis]:u,[S.withPointerCursor]:l},o),sx:[{width:p,minWidth:p,maxWidth:p,textAlign:m},e],style:r,onClick:l,...P?.(f,n),children:c?c(f,n):I?I(f,n,C):Eo(f,C)}):null}a();var ne=require("@mantine/core");a();var qo=require("@mantine/hooks"),U=require("react");function Xr(o){let[e,r]=(0,U.useState)(null),t=o?.join(":")||"";return(0,U.useEffect)(()=>{r(null)},[t]),{lastSelectionChangeIndex:e,setLastSelectionChangeIndex:r}}function Qr(o){let[e,r]=(0,U.useState)(null);return(0,U.useEffect)(()=>{o&&r(null)},[o]),{rowContextMenuInfo:e,setRowContextMenuInfo:r}}function Zr({rowExpansion:o,records:e,idAccessor:r}){let t=[];if(o&&e){let{trigger:s,allowMultiple:u,initiallyExpanded:m}=o;e&&s==="always"?t=e.map(p=>y(p,r)):m&&(t=e.filter(m).map(p=>y(p,r)),u||(t=[t[0]]))}let f,n,l=(0,U.useState)(t);if(o){let{trigger:s,allowMultiple:u,collapseProps:m,content:p}=o;o.expanded?{recordIds:f,onRecordIdsChange:n}=o.expanded:[f,n]=l;let C=c=>n?.(f.filter(I=>I!==y(c,r)));return{expandOnClick:s!=="always"&&s!=="never",isRowExpanded:c=>s==="always"?!0:f.includes(y(c,r)),expandRow:c=>{let I=y(c,r);n?.(u?[...f,I]:[I])},collapseRow:C,collapseProps:m,content:(c,I)=>()=>p({record:c,recordIndex:I,collapse:()=>C(c)})}}}function Kr(o,e){let[r,t]=(0,U.useState)(o),[f,n]=(0,U.useState)(o),l=(0,qo.useTimeout)(()=>t(!0),0),s=(0,qo.useTimeout)(()=>n(!1),e||200);return(0,U.useEffect)(()=>{o?(s.clear(),n(!0),l.start()):(l.clear(),t(!1),s.start())},[l,s,o]),{expanded:r,visible:f}}function oo(){let[o]=(0,qo.useResizeObserver)(),{width:e,height:r}=o.current?.getBoundingClientRect()||{width:0,height:0};return{ref:o,width:e,height:r}}var Z=require("react/jsx-runtime"),it=(0,ne.createStyles)({cell:{"&&":{borderBottomWidth:0,padding:0}},expandedCell:{"&&":{borderBottomWidth:1}}});function ze({open:o,colSpan:e,content:r,collapseProps:t}){let{expanded:f,visible:n}=Kr(o,t?.transitionDuration),{cx:l,classes:s}=it();return n?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)("tr",{}),(0,Z.jsx)("tr",{children:(0,Z.jsx)("td",{className:l(s.cell,{[s.expandedCell]:f}),colSpan:e,children:(0,Z.jsx)(ne.Collapse,{in:f,...t,children:r()})})})]}):null}a();var yo=require("@mantine/core"),Ge=require("react/jsx-runtime"),gt=(0,yo.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",zIndex:1,width:0,left:0,background:"inherit","&::after":{content:'""',position:"absolute",top:0,right:-(0,yo.px)(o.spacing.sm),bottom:0,borderLeft:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`,pointerEvents:"none",opacity:0,transition:"opacity .15s ease"}},withRightShadow:{"&::after":{opacity:1}},checkbox:{cursor:"pointer"}}});function Ve({record:o,recordIndex:e,withRightShadow:r,getCheckboxProps:t,...f}){let{cx:n,classes:l}=gt();return(0,Ge.jsx)("td",{className:n(l.root,{[l.withRightShadow]:r}),onClick:s=>s.stopPropagation(),children:(0,Ge.jsx)(yo.Checkbox,{classNames:{input:l.checkbox},...f,...t(o,e)})})}var K=require("react/jsx-runtime"),Ct=(0,le.createStyles)(o=>{let e=o.colors[o.primaryColor][6];return{withPointerCursor:{cursor:"pointer"},selected:{"&&":{"tr&":{background:o.colorScheme==="dark"?o.fn.darken(e,.6):o.fn.lighten(e,.9)},"table[data-striped] tbody &:nth-of-type(odd)":{background:o.colorScheme==="dark"?o.fn.darken(e,.55):o.fn.lighten(e,.85)}}},contextMenuVisible:{"&&":{"tr&":{background:o.colorScheme==="dark"?o.fn.darken(e,.5):o.fn.lighten(e,.7)},"table[data-striped] tbody &:nth-of-type(odd)":{background:o.colorScheme==="dark"?o.fn.darken(e,.45):o.fn.lighten(e,.65)}}}}});function Xe({record:o,recordIndex:e,columns:r,defaultColumnProps:t,defaultColumnRender:f,selectionVisible:n,selectionChecked:l,onSelectionChange:s,isRecordSelectable:u,getSelectionCheckboxProps:m,onClick:p,onCellClick:C,onContextMenu:c,expansion:I,customAttributes:P,className:i,style:S,sx:g,contextMenuVisible:D,leftShadowVisible:h}){let{cx:V,classes:v}=Ct();return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsxs)(le.Box,{component:"tr",className:V({[v.withPointerCursor]:p||I?.expandOnClick,[v.selected]:l,[v.contextMenuVisible]:D},typeof i=="function"?i(o,e):i),onClick:w=>{if(I){let{isRowExpanded:M,expandOnClick:H,expandRow:O,collapseRow:N}=I;H&&(M(o)?N(o):O(o))}p?.(w)},style:typeof S=="function"?S(o,e):S,sx:g,...P?.(o,e),onContextMenu:c,children:[n&&(0,K.jsx)(Ve,{record:o,recordIndex:e,withRightShadow:h,checked:l,disabled:!s||(u?!u(o,e):!1),onChange:s,getCheckboxProps:m}),r.map(({hidden:w,...M},H)=>{if(w)return null;let{accessor:O,visibleMediaQuery:N,textAlignment:po,noWrap:To,ellipsis:wo,width:Fo,render:Mo,cellsClassName:ko,cellsStyle:Ro,cellsSx:se,customCellAttributes:de}={...t,...M},Uo;return C&&(Uo=ce=>C({event:ce,record:o,recordIndex:e,column:M,columnIndex:H})),(0,K.jsx)(Ue,{className:typeof ko=="function"?ko(o,e):ko,style:typeof Ro=="function"?Ro(o,e):Ro,sx:se,visibleMediaQuery:N,record:o,recordIndex:e,onClick:Uo,accessor:O,textAlignment:po,noWrap:To,ellipsis:wo,width:Fo,render:Mo,defaultRender:f,customCellAttributes:de},O)})]}),I&&(0,K.jsx)(ze,{colSpan:r.filter(({hidden:w})=>!w).length+(n?1:0),open:I.isRowExpanded(o),content:I.content(o,e),collapseProps:I.collapseProps})]})}a();var Po=require("@mantine/core"),so=require("@mantine/hooks");var $r=require("react/jsx-runtime"),St=(0,Po.createStyles)(o=>({root:{position:"fixed",border:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,overflow:"hidden",transition:"all .15s ease"}}));function Qe({borderRadius:o="xs",shadow:e="sm",zIndex:r=3,y:t,x:f,onDestroy:n,children:l}){(0,so.useWindowEvent)("resize",n),(0,so.useWindowEvent)("scroll",n);let s=(0,so.useClickOutside)(n),{ref:u,width:m,height:p}=oo(),C=(0,so.useMergedRef)(s,u),{innerWidth:c,innerHeight:I}=window,{classes:P,theme:{dir:i,spacing:S}}=St(),g=(0,Po.px)(S.md);return(0,$r.jsx)(Po.Paper,{ref:C,shadow:e,radius:o,className:P.root,sx:{zIndex:r,top:t+p+g>I?I-p-g:t,left:i==="ltr"?f+m+g>c?c-m-g:f:c-g-(f-m-g<0?m+g:f)},children:l})}a();var Yr=require("@mantine/core"),_r=require("react/jsx-runtime"),ht=(0,Yr.createStyles)(o=>({root:{height:1,background:o.colorScheme==="dark"?o.colors.dark[5]:o.colors.gray[1]}}));function Ze(){let{classes:o}=ht();return(0,_r.jsx)("div",{className:o.root})}a();var z=require("@mantine/core"),Wo=require("react/jsx-runtime"),bt=(0,z.createStyles)((o,{color:e})=>{let r=(0,z.px)(o.spacing.sm)/2;return{root:{width:"100%",display:"flex",alignItems:"center",paddingTop:r,paddingBottom:r,paddingLeft:o.spacing.sm,paddingRight:o.spacing.sm,color:e&&o.colors[e][6],transition:"background .15s ease","&[disabled]":{cursor:"not-allowed",color:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[5]},"&:hover:not([disabled])":{background:o.fn.rgba(e?o.colors[e][6]:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[4],e?o.colorScheme==="dark"?.15:.08:.25)},"&:active:not([disabled])":{background:o.fn.rgba(e?o.colors[e][6]:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[4],e?o.colorScheme==="dark"?.3:.2:.5)}},icon:{fontSize:0,marginRight:o.spacing.xs},title:{whiteSpace:"nowrap"}}});function Ke({icon:o,title:e,color:r,disabled:t,onClick:f}){let{classes:n}=bt({color:r});return(0,Wo.jsxs)(z.UnstyledButton,{className:n.root,disabled:t,onClick:f,children:[o&&(0,Wo.jsx)(z.Box,{className:n.icon,children:o}),(0,Wo.jsx)(z.Text,{className:n.title,size:"sm",children:e})]})}a();var uo=require("@mantine/core"),co=require("react/jsx-runtime"),Bt=(0,uo.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{flex:"1 1 100%"},scrollbar:{'&[data-state="visible"]':{background:"transparent"},"div::before":{pointerEvents:"none"}},corner:{background:"transparent"},thumb:{zIndex:3},shadow:{position:"absolute",pointerEvents:"none",opacity:0,transition:"opacity .15s ease"},topShadow:{zIndex:2,left:0,right:0,height:o.spacing.sm,background:`linear-gradient(${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`},leftShadow:{zIndex:3,top:0,left:0,bottom:0,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`},rightShadow:{zIndex:2,top:0,bottom:0,right:0,width:o.spacing.sm,background:`linear-gradient(to left, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to left, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`},bottomShadow:{zIndex:2,left:0,right:0,height:o.spacing.sm,background:`linear-gradient(${o.fn.rgba(o.black,0)}, ${o.fn.rgba(o.black,e)}), linear-gradient(${o.fn.rgba(o.black,0)} 30%, ${o.fn.rgba(o.black,e)})`},shadowVisible:{opacity:1}}});function $e({topShadowVisible:o,leftShadowVisible:e,rightShadowVisible:r,bottomShadowVisible:t,headerHeight:f,footerHeight:n,onScrollPositionChange:l,children:s,viewportRef:u,scrollAreaProps:m}){let p=n?n-1:0,{cx:C,classes:c}=Bt();return(0,co.jsxs)(uo.ScrollArea,{...m,viewportRef:u,classNames:{root:c.root,scrollbar:c.scrollbar,thumb:c.thumb,corner:c.corner},styles:{scrollbar:{marginTop:f,marginBottom:p}},onScrollPositionChange:l,children:[s,(0,co.jsx)(uo.Box,{className:C(c.shadow,c.topShadow,{[c.shadowVisible]:o}),sx:{top:f}}),(0,co.jsx)("div",{className:C(c.shadow,c.leftShadow,{[c.shadowVisible]:e})}),(0,co.jsx)("div",{className:C(c.shadow,c.rightShadow,{[c.shadowVisible]:r})}),(0,co.jsx)(uo.Box,{className:C(c.shadow,c.bottomShadow,{[c.shadowVisible]:t}),sx:{bottom:p}})]})}var T=require("react/jsx-runtime"),jr={},Dt=(0,G.createStyles)((o,{borderColor:e,rowBorderColor:r})=>{let t=typeof e=="function"?e(o):e,f=typeof r=="function"?r(o):r;return{root:{position:"relative",display:"flex",flexDirection:"column",overflow:"hidden",tr:{backgroundColor:o.colorScheme==="dark"?o.colors.dark[7]:o.white},"&&":{"thead tr th":{borderBottomColor:t},"tbody tr td":{borderTopColor:f}}},lastRowBorderBottomVisible:{"tbody tr:last-of-type td":{borderBottom:`1px solid ${f}`}},textSelectionDisabled:{userSelect:"none"},table:{borderCollapse:"separate",borderSpacing:0},tableWithBorder:{border:`1px solid ${t}`},tableWithColumnBorders:{"&&":{"th, td":{":not(:first-of-type)":{borderLeft:`1px solid ${f}`}}}},tableWithColumnBordersAndSelectableRecords:{thead:{"tr + tr":{th:{borderLeft:`1px solid ${f}`}}}},verticalAlignmentTop:{td:{verticalAlign:"top"}},verticalAlignmentBottom:{td:{verticalAlign:"bottom"}}}});function Ye({withBorder:o,borderRadius:e,borderColor:r=B=>B.colorScheme==="dark"?B.colors.dark[4]:B.colors.gray[3],rowBorderColor:t=B=>B.fn.rgba(B.colorScheme==="dark"?B.colors.dark[4]:B.colors.gray[3],.65),withColumnBorders:f,textSelectionDisabled:n,height:l="100%",minHeight:s,shadow:u,verticalAlignment:m="center",fetching:p,columns:C,groups:c,defaultColumnProps:I,defaultColumnRender:P,idAccessor:i="id",records:S,selectedRecords:g,onSelectedRecordsChange:D,isRecordSelectable:h,allRecordsSelectionCheckboxProps:V={"aria-label":"Select all records"},getRecordSelectionCheckboxProps:v=(B,eo)=>({"aria-label":`Select record ${eo+1}`}),sortStatus:w,sortIcons:M,onSortStatusChange:H,horizontalSpacing:O,page:N,onPageChange:po,totalRecords:To,recordsPerPage:wo,onRecordsPerPageChange:Fo,recordsPerPageOptions:Mo,recordsPerPageLabel:ko="Records per page",paginationColor:Ro,paginationSize:se="sm",paginationText:de=({from:B,to:eo,totalRecords:ro})=>`${B} - ${eo} / ${ro}`,paginationWrapBreakpoint:Uo="sm",getPaginationControlProps:ce=B=>B==="previous"?{"aria-label":"Previous page"}:B==="next"?{"aria-label":"Next page"}:{},loaderBackgroundBlur:oa,customLoader:ea,loaderSize:ra,loaderVariant:aa,loaderColor:ta,loadingText:fa="...",emptyState:na,noRecordsText:_e="No records",noRecordsIcon:la,striped:sa,noHeader:da,onRowClick:ue,onCellClick:ca,onScrollToTop:je,onScrollToBottom:Je,onScrollToLeft:or,onScrollToRight:er,rowContextMenu:E,rowExpansion:ua,rowClassName:pa,rowStyle:ma,rowSx:xa,customRowAttributes:Ia,scrollViewportRef:ia,scrollAreaProps:ga,bodyRef:Ca,m:Sa,my:ha,mx:ba,mt:Ba,mb:Da,ml:ya,mr:Pa,sx:Ta,className:wa,classNames:zo,style:Fa,styles:pe,...Ma}){let{ref:B,width:eo,height:ro}=oo(),Go=(0,L.useMemo)(()=>c?.flatMap(x=>x.columns)??C,[C,c]),{ref:ka,height:me}=oo(),{ref:Ra,width:xe,height:vo}=oo(),{ref:va,height:Oa}=oo(),{ref:Aa,height:rr}=oo(),[Ie,ar]=(0,L.useState)(!0),[ie,tr]=(0,L.useState)(!0),[Vo,fr]=(0,L.useState)(!0),[ge,nr]=(0,L.useState)(!0),{rowContextMenuInfo:ao,setRowContextMenuInfo:mo}=Qr(p),La=Zr({rowExpansion:ua,records:S,idAccessor:i}),Ce=(0,L.useCallback)(()=>{if(!p&&E&&mo(null),p||vo<=ro)ar(!0),tr(!0);else{let x=B.current.scrollTop,b=x===0,k=vo-x-ro<1;ar(b),tr(k),b&&b!==Ie&&je?.(),k&&k!==ie&&Je?.()}if(p||xe===eo)fr(!0),nr(!0);else{let x=B.current.scrollLeft,b=x===0,k=xe-x-eo<1;fr(b),nr(k),b&&b!==Vo&&or?.(),k&&k!==ge&&er?.()}},[p,Je,or,er,je,E,ro,B,eo,ie,Vo,ge,Ie,mo,vo,xe]);Mr(Ce,[Ce]);let Ha=(0,L.useCallback)(x=>{B.current.scrollTo({top:0,left:0}),po(x)},[po,B]),Xo=S?.length,lr=S?.map(x=>y(x,i)),Oo=!!g,Ao=g?.map(x=>y(x,i)),sr=lr!==void 0&&Ao!==void 0&&Ao.length>0,Se=h?S?.filter(h):S,Qo=Se?.map(x=>y(x,i)),Zo=sr&&Qo.every(x=>Ao.includes(x)),Na=sr&&Qo.some(x=>Ao.includes(x)),Ea=(0,L.useCallback)(()=>{g&&D&&D(Zo?g.filter(x=>!Qo.includes(y(x,i))):Co([...g,...Se],x=>y(x,i)))},[Zo,i,D,Qo,Se,g]),{lastSelectionChangeIndex:Ko,setLastSelectionChangeIndex:qa}=Xr(lr),he=Oo&&!Vo,{cx:dr,classes:X,theme:Wa}=Dt({borderColor:r,rowBorderColor:t}),Ua={m:Sa,my:ha,mx:ba,mt:Ba,mb:Da,ml:ya,mr:Pa},$o=typeof pe=="function"?pe(Wa,jr,jr):pe;return(0,T.jsxs)(G.Box,{...Ua,className:dr(X.root,{[X.tableWithBorder]:o},wa,zo?.root),sx:[x=>({borderRadius:x.radius[e]||e,boxShadow:x.shadows[u]||u,height:l,minHeight:s}),...(0,G.packSx)(Ta)],style:{...$o?.root,...Fa},children:[(0,T.jsx)($e,{viewportRef:(0,Jr.useMergedRef)(B,ia||null),topShadowVisible:!Ie,leftShadowVisible:!(g||Vo),rightShadowVisible:!ge,bottomShadowVisible:!ie,headerHeight:me,footerHeight:Oa,onScrollPositionChange:Ce,scrollAreaProps:ga,children:(0,T.jsxs)(G.Table,{ref:Ra,horizontalSpacing:O,className:dr(X.table,{[X.tableWithColumnBorders]:f,[X.lastRowBorderBottomVisible]:vo<ro,[X.textSelectionDisabled]:n,[X.verticalAlignmentTop]:m==="top",[X.verticalAlignmentBottom]:m==="bottom",[X.tableWithColumnBordersAndSelectableRecords]:Oo&&f}),striped:Xo?sa:!1,...Ma,children:[da?null:(0,T.jsx)(Wr,{ref:ka,className:zo?.header,style:$o?.header,columns:Go,defaultColumnProps:I,groups:c,sortStatus:w,sortIcons:M,onSortStatusChange:H,selectionVisible:Oo,selectionChecked:Zo,selectionIndeterminate:Na&&!Zo,onSelectionChange:Ea,selectionCheckboxProps:V,leftShadowVisible:he}),(0,T.jsx)("tbody",{ref:Ca,children:Xo?S.map((x,b)=>{let k=y(x,i),Lo=Ao?.includes(k)||!1,Yo=!1,_o=!1;if(E){let{hidden:F}=E;(!F||!(typeof F=="function"?F(x,b):F))&&(E.trigger==="click"?Yo=!0:_o=!0)}let jo;D&&g&&(jo=F=>{if(F.nativeEvent.shiftKey&&Ko!==null){let xo=S.filter(b>Ko?(to,fo)=>fo>=Ko&&fo<=b&&(h?h(to,fo):!0):(to,fo)=>fo>=b&&fo<=Ko&&(h?h(to,fo):!0));D(Lo?ee(g,xo,to=>y(to,i)):Co([...g,...xo],to=>y(to,i)))}else D(Lo?g.filter(xo=>y(xo,i)!==k):Co([...g,x],xo=>y(xo,i)));qa(b)});let Ho;Yo?Ho=F=>{mo({y:F.clientY,x:F.clientX,record:x,recordIndex:b}),ue?.(x,b,F)}:ue&&(Ho=F=>{ue(x,b,F)});let cr;return _o&&(cr=F=>{F.preventDefault(),mo({y:F.clientY,x:F.clientX,record:x,recordIndex:b})}),(0,T.jsx)(Xe,{record:x,recordIndex:b,columns:Go,defaultColumnProps:I,defaultColumnRender:P,selectionVisible:Oo,selectionChecked:Lo,onSelectionChange:jo,isRecordSelectable:h,getSelectionCheckboxProps:v,onClick:Ho,onCellClick:ca,onContextMenu:cr,contextMenuVisible:ao?y(ao.record,i)===k:!1,expansion:La,className:pa,style:ma,sx:xa,customAttributes:Ia,leftShadowVisible:he},k)}):(0,T.jsx)(De,{})}),Go.some(({footer:x})=>x)&&(0,T.jsx)(Ar,{ref:va,className:zo?.footer,style:$o?.footer,borderColor:r,columns:Go,defaultColumnProps:I,selectionVisible:Oo,leftShadowVisible:he,scrollDiff:vo-ro})]})}),N&&(0,T.jsx)(Gr,{ref:Aa,className:zo?.pagination,style:$o?.pagination,topBorderColor:r,horizontalSpacing:O,fetching:p,page:N,onPageChange:Ha,totalRecords:To,recordsPerPage:wo,onRecordsPerPageChange:Fo,recordsPerPageOptions:Mo,recordsPerPageLabel:ko,paginationColor:Ro,paginationSize:se,paginationText:de,paginationWrapBreakpoint:Uo,getPaginationControlProps:ce,noRecordsText:_e,loadingText:fa,recordsLength:Xo}),(0,T.jsx)(qe,{pt:me,pb:rr,fetching:p,backgroundBlur:oa,customContent:ea,size:ra,variant:aa,color:ta}),(0,T.jsx)(Fe,{pt:me,pb:rr,icon:la,text:_e,active:!p&&!Xo,children:na}),E&&ao&&(0,T.jsx)(G.Portal,{children:(0,T.jsx)(Qe,{zIndex:E.zIndex,borderRadius:E.borderRadius,shadow:E.shadow,y:ao.y,x:ao.x,onDestroy:()=>mo(null),children:E.items(ao.record,ao.recordIndex).map(({divider:x,key:b,title:k,icon:Lo,color:Yo,hidden:_o,disabled:jo,onClick:Ho})=>x?(0,T.jsx)(Ze,{},b):_o?null:(0,T.jsx)(Ke,{title:k??_(b),icon:Lo,color:Yo,disabled:jo,onClick:()=>{mo(null),Ho()}},b))})})]})}a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();
1
+ "use strict";var za=Object.create;var Jo=Object.defineProperty;var Ga=Object.getOwnPropertyDescriptor;var Va=Object.getOwnPropertyNames;var Xa=Object.getPrototypeOf,Qa=Object.prototype.hasOwnProperty;var Ka=(o,e)=>()=>(o&&(e=o(o=0)),e);var be=(o,e)=>()=>(e||o((e={exports:{}}).exports,e),e.exports),Za=(o,e)=>{for(var r in e)Jo(o,r,{get:e[r],enumerable:!0})},ur=(o,e,r,t)=>{if(e&&typeof e=="object"||typeof e=="function")for(let f of Va(e))!Qa.call(o,f)&&f!==r&&Jo(o,f,{get:()=>e[f],enumerable:!(t=Ga(e,f))||t.enumerable});return o};var pr=(o,e,r)=>(r=o!=null?za(Xa(o)):{},ur(e||!o||!o.__esModule?Jo(r,"default",{value:o,enumerable:!0}):r,o)),$a=o=>ur(Jo({},"__esModule",{value:!0}),o);var d,a=Ka(()=>{"use strict";d=pr(require("react"),1)});var Ir=be((Mt,xr)=>{"use strict";a();var _a="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";xr.exports=_a});var Sr=be((Rt,Cr)=>{"use strict";a();var ja=Ir();function ir(){}function gr(){}gr.resetWarningCache=ir;Cr.exports=function(){function o(t,f,l,n,s,u){if(u!==ja){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}}o.isRequired=o;function e(){return o}var r={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:e,element:o,elementType:o,instanceOf:e,node:o,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:gr,resetWarningCache:ir};return r.PropTypes=r,r}});var br=be((Lt,hr)=>{a();hr.exports=Sr()();var Ot,At});var yt={};Za(yt,{DataTable:()=>Ye,differenceBy:()=>ee,getValueAtPath:()=>Eo,humanize:()=>_,uniqBy:()=>Co});module.exports=$a(yt);a();a();var G=require("@mantine/core"),Jr=require("@mantine/hooks"),L=require("react");a();var mr=require("@mantine/core"),Be=require("react/jsx-runtime"),Ya=(0,mr.createStyles)({root:{"&&":{background:"transparent",":last-of-type td":{borderBottom:"none"}}}});function De(){let{classes:o}=Ya();return(0,Be.jsx)("tr",{className:o.root,children:(0,Be.jsx)("td",{})})}a();var Io=require("@mantine/core");a();a();var No=require("react"),$=pr(br());a();var Br={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};var Ja=Object.defineProperty,ot=Object.defineProperties,et=Object.getOwnPropertyDescriptors,oe=Object.getOwnPropertySymbols,Pr=Object.prototype.hasOwnProperty,Tr=Object.prototype.propertyIsEnumerable,Dr=(o,e,r)=>e in o?Ja(o,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):o[e]=r,yr=(o,e)=>{for(var r in e||(e={}))Pr.call(e,r)&&Dr(o,r,e[r]);if(oe)for(var r of oe(e))Tr.call(e,r)&&Dr(o,r,e[r]);return o},rt=(o,e)=>ot(o,et(e)),at=(o,e)=>{var r={};for(var t in o)Pr.call(o,t)&&e.indexOf(t)<0&&(r[t]=o[t]);if(o!=null&&oe)for(var t of oe(o))e.indexOf(t)<0&&Tr.call(o,t)&&(r[t]=o[t]);return r},Y=(o,e,r)=>{let t=(0,No.forwardRef)((f,l)=>{var n=f,{color:s="currentColor",size:u=24,stroke:m=2,children:p}=n,C=at(n,["color","size","stroke","children"]);return(0,No.createElement)("svg",yr(rt(yr({ref:l},Br),{width:u,height:u,stroke:s,strokeWidth:m,className:`tabler-icon tabler-icon-${o}`}),C),[...r.map(([c,I])=>(0,No.createElement)(c,I)),...p||[]])});return t.propTypes={color:$.default.string,size:$.default.oneOfType([$.default.string,$.default.number]),stroke:$.default.oneOfType([$.default.string,$.default.number])},t.displayName=`${e}`,t};a();var ye=Y("arrow-up","IconArrowUp",[["path",{d:"M12 5l0 14",key:"svg-0"}],["path",{d:"M18 11l-6 -6",key:"svg-1"}],["path",{d:"M6 11l6 -6",key:"svg-2"}]]);a();var Pe=Y("arrows-vertical","IconArrowsVertical",[["path",{d:"M8 7l4 -4l4 4",key:"svg-0"}],["path",{d:"M8 17l4 4l4 -4",key:"svg-1"}],["path",{d:"M12 3l0 18",key:"svg-2"}]]);a();var Te=Y("database-off","IconDatabaseOff",[["path",{d:"M12.983 8.978c3.955 -.182 7.017 -1.446 7.017 -2.978c0 -1.657 -3.582 -3 -8 -3c-1.661 0 -3.204 .19 -4.483 .515m-2.783 1.228c-.471 .382 -.734 .808 -.734 1.257c0 1.22 1.944 2.271 4.734 2.74",key:"svg-0"}],["path",{d:"M4 6v6c0 1.657 3.582 3 8 3c.986 0 1.93 -.067 2.802 -.19m3.187 -.82c1.251 -.53 2.011 -1.228 2.011 -1.99v-6",key:"svg-1"}],["path",{d:"M4 12v6c0 1.657 3.582 3 8 3c3.217 0 5.991 -.712 7.261 -1.74m.739 -3.26v-4",key:"svg-2"}],["path",{d:"M3 3l18 18",key:"svg-3"}]]);a();var Fe=Y("filter","IconFilter",[["path",{d:"M4 4h16v2.172a2 2 0 0 1 -.586 1.414l-4.414 4.414v7l-6 2v-8.5l-4.48 -4.928a2 2 0 0 1 -.52 -1.345v-2.227z",key:"svg-0"}]]);var Q=require("react/jsx-runtime"),tt=(0,Io.createStyles)(o=>({root:{position:"absolute",top:0,right:0,bottom:0,left:0,flexDirection:"column",pointerEvents:"none",color:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[6],opacity:0,transition:"opacity .15s ease"},active:{opacity:1},standardIcon:{fontSize:0,borderRadius:"50%",padding:o.spacing.xs,background:o.colorScheme==="dark"?o.colors.dark[5]:o.colors.gray[2]}}));function we({icon:o,text:e,pt:r,pb:t,active:f,children:l}){let{classes:n,cx:s}=tt();return(0,Q.jsx)(Io.Center,{pt:r,pb:t,className:s(n.root,{[n.active]:f}),children:l||(0,Q.jsxs)(Q.Fragment,{children:[o||(0,Q.jsx)("div",{className:n.standardIcon,children:(0,Q.jsx)(Te,{})}),(0,Q.jsx)(Io.Text,{size:"sm",color:"dimmed",children:e})]})})}a();var te=require("@mantine/core"),Or=require("react");a();var re=require("@mantine/core");a();var Me=require("@mantine/core"),wr=require("@mantine/hooks"),lo=require("react");a();var io=require("react");function ft(o,e){let r=()=>{e(o.map(f=>f.matches))},t=o.map(f=>{try{return f.addEventListener("change",r),()=>f.removeEventListener("change",r)}catch{return f.addListener(r),()=>f.removeListener(r)}});return()=>{t.forEach(f=>f())}}function lt(o,e){return e||(typeof window<"u"&&"matchMedia"in window?o.map(r=>window.matchMedia(r).matches):o.map(()=>!1))}function Fr(o,e,{getInitialValueInEffect:r}={getInitialValueInEffect:!0}){let[t,f]=(0,io.useState)(r?e:lt(o,e)),l=(0,io.useRef)();return(0,io.useEffect)(()=>{if("matchMedia"in window)return l.current=o.map(n=>window.matchMedia(n)),f(l.current.map(n=>n.matches)),ft(l.current,n=>{f(n)})},[o]),t}var Mr=typeof window<"u"?lo.useLayoutEffect:lo.useEffect;function go(o){let e=(0,Me.useMantineTheme)(),r=typeof o=="function"?o(e):o;return(0,wr.useMediaQuery)(r||"",!0)}function kr(o){let e=(0,Me.useMantineTheme)(),r=(0,lo.useMemo)(()=>o.map(f=>(typeof f=="function"?f(e):f)??""),[o,e]),t=(0,lo.useMemo)(()=>o.map(()=>!0),[o]);return Fr(r,t)}function _(o){let e=o.replace(/([a-z\d])([A-Z]+)/g,"$1 $2").replace(/\W|_/g," ").trim().toLowerCase();return`${e.charAt(0).toUpperCase()}${e.slice(1)}`}function ee(o,e,r){return o.filter(t=>!e.map(r).includes(r(t)))}function Co(o,e){return o.filter((r,t,f)=>t===f.findIndex(l=>e(r)===e(l)))}function Eo(o,e){return e?e.match(/([^[.\]])+/g).reduce((t,f)=>t&&t[f],o):void 0}function y(o,e){return typeof e=="string"?Eo(o,e):e(o)}var Rr=require("react/jsx-runtime"),nt=(0,re.createStyles)({noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function ke({className:o,sx:e,style:r,visibleMediaQuery:t,title:f,noWrap:l,ellipsis:n,textAlignment:s,width:u}){let{cx:m,classes:p}=nt();return go(t)?(0,Rr.jsx)(re.Box,{component:"th",className:m({[p.noWrap]:l||n,[p.ellipsis]:n},o),sx:[{"&&":{textAlign:s},width:u,minWidth:u,maxWidth:u},e],style:r,children:f}):null}a();var ae=require("@mantine/core"),vr=require("react/jsx-runtime"),st=(0,ae.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",width:0,left:0,background:"inherit","&::after":{content:'""',position:"absolute",top:0,right:-(0,ae.px)(o.spacing.sm),bottom:0,borderLeft:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`,pointerEvents:"none",opacity:0,transition:"opacity .15s ease"}},shadowVisible:{"&::after":{opacity:1}}}});function Re({shadowVisible:o}){let{cx:e,classes:r}=st();return(0,vr.jsx)("th",{className:e(r.root,{[r.shadowVisible]:o})})}var So=require("react/jsx-runtime"),dt=(0,te.createStyles)((o,{scrollDiff:e,borderColor:r})=>{let t=e<0,f=typeof r=="function"?r(o):r;return{root:{zIndex:2,position:t?"relative":"sticky",bottom:t?e:-1,background:o.colorScheme==="dark"?o.colors.dark[7]:o.white,"&& tr th":{borderTopColor:f}},relative:{position:"relative"},textSelectionDisabled:{userSelect:"none"}}}),Ar=(0,Or.forwardRef)(function({className:e,style:r,borderColor:t,columns:f,defaultColumnProps:l,selectionVisible:n,leftShadowVisible:s,scrollDiff:u},m){let{cx:p,classes:C}=dt({scrollDiff:u,borderColor:t});return(0,So.jsx)(te.Box,{component:"tfoot",ref:m,className:p(C.root,e),style:r,children:(0,So.jsxs)("tr",{children:[n&&(0,So.jsx)(Re,{shadowVisible:s}),f.map(({hidden:c,...I})=>{if(c)return null;let{accessor:P,visibleMediaQuery:i,textAlignment:S,width:g,footer:D,footerClassName:h,footerStyle:V,footerSx:v,noWrap:F,ellipsis:M}={...l,...I};return(0,So.jsx)(ke,{className:h,style:V,sx:v,visibleMediaQuery:i,textAlignment:S,width:g,title:D,noWrap:F,ellipsis:M},P)})]})})});a();var Er=require("@mantine/core"),qr=require("react");a();var Lr=require("@mantine/core"),ve=require("react");var Hr=require("react/jsx-runtime");function Oe({group:{id:o,columns:e,title:r,className:t,style:f,sx:l}}){let n=(0,ve.useMemo)(()=>e.map(({visibleMediaQuery:m})=>m),[e]),s=kr(n),u=(0,ve.useMemo)(()=>e.filter(({hidden:m},p)=>!m&&s?.[p]).length,[e,s]);return u>0?(0,Hr.jsx)(Lr.Box,{component:"th",colSpan:u,className:t,sx:l,style:f,children:r??_(o)}):null}a();var q=require("@mantine/core");a();var ho=require("@mantine/core"),Nr=require("@mantine/hooks");var no=require("react/jsx-runtime");function Ae({children:o,isActive:e}){let[r,{close:t,toggle:f}]=(0,Nr.useDisclosure)(!1);return(0,no.jsxs)(ho.Popover,{withArrow:!0,withinPortal:!0,shadow:"md",opened:r,onClose:t,trapFocus:!0,children:[(0,no.jsx)(ho.Popover.Target,{children:(0,no.jsx)(ho.ActionIcon,{onClick:l=>{l.preventDefault(),f()},variant:e?"default":"subtle",children:(0,no.jsx)(Fe,{size:14})})}),(0,no.jsx)(ho.Popover.Dropdown,{onClick:l=>l.preventDefault(),children:typeof o=="function"?o({close:t}):o})]})}var R=require("react/jsx-runtime"),ct=(0,q.createStyles)(o=>({sortableColumnHeader:{cursor:"pointer",transition:"background .15s ease","&:hover:not(:has(button:hover))":{background:o.colorScheme==="dark"?o.colors.dark[6]:o.colors.gray[0]}},sortableColumnHeaderGroup:{gap:"0.25em"},columnHeaderText:{overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},sortableColumnHeaderText:{minWidth:0,flexGrow:1},sortableColumnHeaderIcon:{transition:"transform .15s ease"},sortableColumnHeaderIconRotated:{transform:"rotate3d(0, 0, 1, 180deg)"},sortableColumnHeaderUnsortedIcon:{color:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[5],transition:"color .15s ease","th:hover &":{color:o.colorScheme==="dark"?o.colors.dark[2]:o.colors.gray[6]}}}));function Le({className:o,sx:e,style:r,accessor:t,visibleMediaQuery:f,title:l,sortable:n,sortIcons:s,textAlignment:u,width:m,sortStatus:p,onSortStatusChange:C,filter:c,filtering:I}){let{cx:P,classes:i}=ct();if(!go(f))return null;let S=l??_(t),g=typeof S=="string"?S:void 0,D=n&&C?h=>{h?.defaultPrevented||C({columnAccessor:t,direction:p?.columnAccessor===t?p.direction==="asc"?"desc":"asc":p?.direction??"asc"})}:void 0;return(0,R.jsx)(q.Box,{component:"th",className:P({[i.sortableColumnHeader]:n},o),sx:[{"&&":{textAlign:u},width:m,minWidth:m,maxWidth:m},e],style:r,role:n?"button":void 0,tabIndex:n?0:void 0,onClick:D,onKeyDown:h=>h.key==="Enter"&&D?.(),children:(0,R.jsxs)(q.Group,{className:i.sortableColumnHeaderGroup,position:"apart",noWrap:!0,children:[(0,R.jsx)(q.Box,{className:P(i.columnHeaderText,i.sortableColumnHeaderText),title:g,children:S}),n||p?.columnAccessor===t?(0,R.jsx)(R.Fragment,{children:p?.columnAccessor===t?(0,R.jsx)(q.Center,{className:P(i.sortableColumnHeaderIcon,{[i.sortableColumnHeaderIconRotated]:p.direction==="desc"}),role:"img","aria-label":`Sorted ${p.direction==="desc"?"descending":"ascending"}`,children:s?.sorted||(0,R.jsx)(ye,{size:14})}):(0,R.jsx)(q.Center,{className:i.sortableColumnHeaderUnsortedIcon,role:"img","aria-label":"Not sorted",children:s?.unsorted||(0,R.jsx)(Pe,{size:14})})}):null,c?(0,R.jsx)(Ae,{isActive:!!I,children:c}):null]})})}a();var bo=require("@mantine/core"),He=require("react/jsx-runtime"),ut=(0,bo.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",width:0,left:0,background:"inherit","&::after":{content:'""',position:"absolute",top:0,right:-(0,bo.px)(o.spacing.sm),bottom:0,borderLeft:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`,pointerEvents:"none",opacity:0,transition:"opacity .15s ease"}},shadowVisible:{"&::after":{opacity:1}},checkboxInput:{cursor:"pointer"}}});function Ne({shadowVisible:o,checked:e,indeterminate:r,checkboxProps:t,onChange:f,rowSpan:l}){let{cx:n,classes:s}=ut();return(0,He.jsx)("th",{className:n(s.root,{[s.shadowVisible]:o}),rowSpan:l,children:(0,He.jsx)(bo.Checkbox,{classNames:{input:s.checkboxInput},checked:e,indeterminate:r,disabled:!f,onChange:f,...t})})}var j=require("react/jsx-runtime"),pt=(0,Er.createStyles)(o=>({root:{zIndex:2,position:"sticky",top:0,background:o.colorScheme==="dark"?o.colors.dark[7]:o.white},textSelectionDisabled:{userSelect:"none"}})),Wr=(0,qr.forwardRef)(function({className:e,style:r,sortStatus:t,sortIcons:f,onSortStatusChange:l,columns:n,defaultColumnProps:s,groups:u,selectionVisible:m,selectionChecked:p,selectionIndeterminate:C,onSelectionChange:c,selectionCheckboxProps:I,leftShadowVisible:P},i){let{classes:S,cx:g}=pt(),D=m?(0,j.jsx)(Ne,{shadowVisible:P,checked:p,indeterminate:C,checkboxProps:I,onChange:c,rowSpan:u?2:void 0}):null;return(0,j.jsxs)("thead",{className:g(S.root,e),style:r,ref:i,children:[u&&(0,j.jsxs)("tr",{children:[D,u.map(h=>(0,j.jsx)(Oe,{group:h},h.id))]}),(0,j.jsxs)("tr",{children:[!u&&D,n.map(({hidden:h,...V})=>{if(h)return null;let{accessor:v,visibleMediaQuery:F,textAlignment:M,width:H,title:O,sortable:N,titleClassName:po,titleStyle:To,titleSx:Fo,filter:wo,filtering:Mo}={...s,...V};return(0,j.jsx)(Le,{accessor:v,className:po,style:To,sx:Fo,visibleMediaQuery:F,textAlignment:M,width:H,title:O,sortable:N,sortStatus:t,sortIcons:f,onSortStatusChange:l,filter:wo,filtering:Mo},v)})]})]})});a();var Bo=require("@mantine/core"),Ee=require("react/jsx-runtime"),mt=(0,Bo.createStyles)(o=>({root:{zIndex:3,position:"absolute",top:0,left:0,right:0,bottom:0,pointerEvents:"none",background:o.fn.rgba(o.colorScheme==="dark"?o.colors.dark[8]:o.white,.75),opacity:0,transition:"opacity .15s ease"},fetching:{pointerEvents:"all",opacity:1}}));function qe({pt:o,pb:e,fetching:r,customContent:t,backgroundBlur:f,size:l,variant:n,color:s}){let{classes:u,cx:m}=mt();return(0,Ee.jsx)(Bo.Center,{pt:o,pb:e,className:m(u.root,{[u.fetching]:r}),sx:f?{backdropFilter:`blur(${f}px)`}:void 0,children:r&&(t||(0,Ee.jsx)(Bo.Loader,{size:l,variant:n,color:s}))})}a();var J=require("@mantine/core"),zr=require("react");a();var A=require("@mantine/core"),W=require("react/jsx-runtime"),Ur={xs:22,sm:26,md:32,lg:38,xl:44};function We({size:o,label:e,values:r,value:t,onChange:f,color:l}){return(0,W.jsxs)(A.Group,{spacing:"xs",children:[(0,W.jsx)(A.Text,{size:o,children:e}),(0,W.jsxs)(A.Menu,{withinPortal:!0,withArrow:!0,children:[(0,W.jsx)(A.Menu.Target,{children:(0,W.jsx)(A.Button,{size:o,variant:"default",sx:[{fontWeight:"normal"},n=>({height:Ur[o],paddingLeft:n.spacing[o],paddingRight:n.spacing[o]})],children:t})}),(0,W.jsx)(A.Menu.Dropdown,{children:r.map(n=>{let s=n===t;return(0,W.jsx)(A.Menu.Item,{sx:[{height:Ur[o]},u=>({"&&":{color:s?u.white:void 0},background:s?u.colors[l||u.primaryColor][6]:void 0})],disabled:s,onClick:()=>f(n),children:(0,W.jsx)(A.Text,{size:o,children:n})},n)})})]})]})}var Do=require("react/jsx-runtime"),xt=(0,J.createStyles)((o,{topBorderColor:e,paginationWrapBreakpoint:r})=>({root:{background:o.colorScheme==="dark"?o.colors.dark[7]:o.white,borderTop:`1px solid ${typeof e=="function"?e(o):e}`,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"space-between",gap:o.spacing.xs,[o.fn.largerThan(r)]:{flexDirection:"row"}},text:{flex:"1 1 auto"},pagination:{opacity:1,transition:"opacity .15s ease"},paginationFetching:{opacity:0}})),Gr=(0,zr.forwardRef)(function({className:e,style:r,topBorderColor:t,fetching:f,page:l,onPageChange:n,paginationColor:s,paginationSize:u,loadingText:m,noRecordsText:p,paginationText:C,totalRecords:c,recordsPerPage:I,onRecordsPerPageChange:P,recordsPerPageLabel:i,recordsPerPageOptions:S,recordsLength:g,horizontalSpacing:D,paginationWrapBreakpoint:h,getPaginationControlProps:V},v){let F;if(f)F=m;else if(!c)F=p;else{let O=(l-1)*I+1,N=O+g-1;F=C({from:O,to:N,totalRecords:c})}let{classes:M,cx:H}=xt({topBorderColor:t,paginationWrapBreakpoint:h});return(0,Do.jsxs)(J.Box,{ref:v,px:D??"xs",py:"xs",className:H(M.root,e),style:r,children:[(0,Do.jsx)(J.Text,{className:M.text,size:u,children:F}),S&&(0,Do.jsx)(We,{size:u,label:i,values:S,color:s,value:I,onChange:P}),(0,Do.jsx)(J.Pagination,{color:s,className:H(M.pagination,{[M.paginationFetching]:f||!g}),value:l,onChange:n,size:u,total:Math.ceil(c/I),getControlProps:V})]})});a();var ne=require("@mantine/core");a();var fe=require("@mantine/core");var Vr=require("react/jsx-runtime"),It=(0,fe.createStyles)({withPointerCursor:{cursor:"pointer"},noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function Ue({className:o,sx:e,style:r,visibleMediaQuery:t,record:f,recordIndex:l,onClick:n,noWrap:s,ellipsis:u,textAlignment:m,width:p,accessor:C,render:c,defaultRender:I,customCellAttributes:P}){let{cx:i,classes:S}=It();return go(t)?(0,Vr.jsx)(fe.Box,{component:"td",className:i({[S.noWrap]:s||u,[S.ellipsis]:u,[S.withPointerCursor]:n},o),sx:[{width:p,minWidth:p,maxWidth:p,textAlign:m},e],style:r,onClick:n,...P?.(f,l),children:c?c(f,l):I?I(f,l,C):Eo(f,C)}):null}a();var le=require("@mantine/core");a();var qo=require("@mantine/hooks"),U=require("react");function Xr(o){let[e,r]=(0,U.useState)(null),t=o?.join(":")||"";return(0,U.useEffect)(()=>{r(null)},[t]),{lastSelectionChangeIndex:e,setLastSelectionChangeIndex:r}}function Qr(o){let[e,r]=(0,U.useState)(null);return(0,U.useEffect)(()=>{o&&r(null)},[o]),{rowContextMenuInfo:e,setRowContextMenuInfo:r}}function Kr({rowExpansion:o,records:e,idAccessor:r}){let t=[];if(o&&e){let{trigger:s,allowMultiple:u,initiallyExpanded:m}=o;e&&s==="always"?t=e.map(p=>y(p,r)):m&&(t=e.filter(m).map(p=>y(p,r)),u||(t=[t[0]]))}let f,l,n=(0,U.useState)(t);if(o){let{trigger:s,allowMultiple:u,collapseProps:m,content:p}=o;o.expanded?{recordIds:f,onRecordIdsChange:l}=o.expanded:[f,l]=n;let C=c=>l?.(f.filter(I=>I!==y(c,r)));return{expandOnClick:s!=="always"&&s!=="never",isRowExpanded:c=>s==="always"?!0:f.includes(y(c,r)),expandRow:c=>{let I=y(c,r);l?.(u?[...f,I]:[I])},collapseRow:C,collapseProps:m,content:(c,I)=>()=>p({record:c,recordIndex:I,collapse:()=>C(c)})}}}function Zr(o,e){let[r,t]=(0,U.useState)(o),[f,l]=(0,U.useState)(o),n=(0,qo.useTimeout)(()=>t(!0),0),s=(0,qo.useTimeout)(()=>l(!1),e||200);return(0,U.useEffect)(()=>{o?(s.clear(),l(!0),n.start()):(n.clear(),t(!1),s.start())},[n,s,o]),{expanded:r,visible:f}}function oo(){let[o]=(0,qo.useResizeObserver)(),{width:e,height:r}=o.current?.getBoundingClientRect()||{width:0,height:0};return{ref:o,width:e,height:r}}var K=require("react/jsx-runtime"),it=(0,le.createStyles)({cell:{"&&":{borderBottomWidth:0,padding:0}},expandedCell:{"&&":{borderBottomWidth:1}}});function ze({open:o,colSpan:e,content:r,collapseProps:t}){let{expanded:f,visible:l}=Zr(o,t?.transitionDuration),{cx:n,classes:s}=it();return l?(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)("tr",{}),(0,K.jsx)("tr",{children:(0,K.jsx)("td",{className:n(s.cell,{[s.expandedCell]:f}),colSpan:e,children:(0,K.jsx)(le.Collapse,{in:f,...t,children:r()})})})]}):null}a();var yo=require("@mantine/core"),Ge=require("react/jsx-runtime"),gt=(0,yo.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",zIndex:1,width:0,left:0,background:"inherit","&::after":{content:'""',position:"absolute",top:0,right:-(0,yo.px)(o.spacing.sm),bottom:0,borderLeft:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`,pointerEvents:"none",opacity:0,transition:"opacity .15s ease"}},withRightShadow:{"&::after":{opacity:1}},checkbox:{cursor:"pointer"}}});function Ve({record:o,recordIndex:e,withRightShadow:r,getCheckboxProps:t,...f}){let{cx:l,classes:n}=gt();return(0,Ge.jsx)("td",{className:l(n.root,{[n.withRightShadow]:r}),onClick:s=>s.stopPropagation(),children:(0,Ge.jsx)(yo.Checkbox,{classNames:{input:n.checkbox},...f,...t(o,e)})})}var Z=require("react/jsx-runtime"),Ct=(0,ne.createStyles)(o=>{let e=o.colors[o.primaryColor][6];return{withPointerCursor:{cursor:"pointer"},selected:{"&&":{"tr&":{background:o.colorScheme==="dark"?o.fn.darken(e,.6):o.fn.lighten(e,.9)},"table[data-striped] tbody &:nth-of-type(odd)":{background:o.colorScheme==="dark"?o.fn.darken(e,.55):o.fn.lighten(e,.85)}}},contextMenuVisible:{"&&":{"tr&":{background:o.colorScheme==="dark"?o.fn.darken(e,.5):o.fn.lighten(e,.7)},"table[data-striped] tbody &:nth-of-type(odd)":{background:o.colorScheme==="dark"?o.fn.darken(e,.45):o.fn.lighten(e,.65)}}}}});function Xe({record:o,recordIndex:e,columns:r,defaultColumnProps:t,defaultColumnRender:f,selectionVisible:l,selectionChecked:n,onSelectionChange:s,isRecordSelectable:u,getSelectionCheckboxProps:m,onClick:p,onCellClick:C,onContextMenu:c,expansion:I,customAttributes:P,className:i,style:S,sx:g,contextMenuVisible:D,leftShadowVisible:h}){let{cx:V,classes:v}=Ct();return(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsxs)(ne.Box,{component:"tr",className:V({[v.withPointerCursor]:p||I?.expandOnClick,[v.selected]:n,[v.contextMenuVisible]:D},typeof i=="function"?i(o,e):i),onClick:F=>{if(I){let{isRowExpanded:M,expandOnClick:H,expandRow:O,collapseRow:N}=I;H&&(M(o)?N(o):O(o))}p?.(F)},style:typeof S=="function"?S(o,e):S,sx:g,...P?.(o,e),onContextMenu:c,children:[l&&(0,Z.jsx)(Ve,{record:o,recordIndex:e,withRightShadow:h,checked:n,disabled:!s||(u?!u(o,e):!1),onChange:s,getCheckboxProps:m}),r.map(({hidden:F,...M},H)=>{if(F)return null;let{accessor:O,visibleMediaQuery:N,textAlignment:po,noWrap:To,ellipsis:Fo,width:wo,render:Mo,cellsClassName:ko,cellsStyle:Ro,cellsSx:se,customCellAttributes:de}={...t,...M},Uo;return C&&(Uo=ce=>C({event:ce,record:o,recordIndex:e,column:M,columnIndex:H})),(0,Z.jsx)(Ue,{className:typeof ko=="function"?ko(o,e):ko,style:typeof Ro=="function"?Ro(o,e):Ro,sx:se,visibleMediaQuery:N,record:o,recordIndex:e,onClick:Uo,accessor:O,textAlignment:po,noWrap:To,ellipsis:Fo,width:wo,render:Mo,defaultRender:f,customCellAttributes:de},O)})]}),I&&(0,Z.jsx)(ze,{colSpan:r.filter(({hidden:F})=>!F).length+(l?1:0),open:I.isRowExpanded(o),content:I.content(o,e),collapseProps:I.collapseProps})]})}a();var Po=require("@mantine/core"),so=require("@mantine/hooks");var $r=require("react/jsx-runtime"),St=(0,Po.createStyles)(o=>({root:{position:"fixed",border:`1px solid ${o.colorScheme==="dark"?o.colors.dark[4]:o.colors.gray[3]}`,overflow:"hidden",transition:"all .15s ease"}}));function Qe({borderRadius:o="xs",shadow:e="sm",zIndex:r=3,y:t,x:f,onDestroy:l,children:n}){(0,so.useWindowEvent)("resize",l),(0,so.useWindowEvent)("scroll",l);let s=(0,so.useClickOutside)(l),{ref:u,width:m,height:p}=oo(),C=(0,so.useMergedRef)(s,u),{innerWidth:c,innerHeight:I}=window,{classes:P,theme:{dir:i,spacing:S}}=St(),g=(0,Po.px)(S.md);return(0,$r.jsx)(Po.Paper,{ref:C,shadow:e,radius:o,className:P.root,sx:{zIndex:r,top:t+p+g>I?I-p-g:t,left:i==="ltr"?f+m+g>c?c-m-g:f:c-g-(f-m-g<0?m+g:f)},children:n})}a();var Yr=require("@mantine/core"),_r=require("react/jsx-runtime"),ht=(0,Yr.createStyles)(o=>({root:{height:1,background:o.colorScheme==="dark"?o.colors.dark[5]:o.colors.gray[1]}}));function Ke(){let{classes:o}=ht();return(0,_r.jsx)("div",{className:o.root})}a();var z=require("@mantine/core"),Wo=require("react/jsx-runtime"),bt=(0,z.createStyles)((o,{color:e})=>{let r=(0,z.px)(o.spacing.sm)/2;return{root:{width:"100%",display:"flex",alignItems:"center",paddingTop:r,paddingBottom:r,paddingLeft:o.spacing.sm,paddingRight:o.spacing.sm,color:e&&o.colors[e][6],transition:"background .15s ease","&[disabled]":{cursor:"not-allowed",color:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[5]},"&:hover:not([disabled])":{background:o.fn.rgba(e?o.colors[e][6]:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[4],e?o.colorScheme==="dark"?.15:.08:.25)},"&:active:not([disabled])":{background:o.fn.rgba(e?o.colors[e][6]:o.colorScheme==="dark"?o.colors.dark[3]:o.colors.gray[4],e?o.colorScheme==="dark"?.3:.2:.5)}},icon:{fontSize:0,marginRight:o.spacing.xs},title:{whiteSpace:"nowrap"}}});function Ze({icon:o,title:e,color:r,disabled:t,onClick:f}){let{classes:l}=bt({color:r});return(0,Wo.jsxs)(z.UnstyledButton,{className:l.root,disabled:t,onClick:f,children:[o&&(0,Wo.jsx)(z.Box,{className:l.icon,children:o}),(0,Wo.jsx)(z.Text,{className:l.title,size:"sm",children:e})]})}a();var uo=require("@mantine/core"),co=require("react/jsx-runtime"),Bt=(0,uo.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{flex:"1 1 100%"},scrollbar:{'&[data-state="visible"]':{background:"transparent"},"div::before":{pointerEvents:"none"}},corner:{background:"transparent"},thumb:{zIndex:3},shadow:{position:"absolute",pointerEvents:"none",opacity:0,transition:"opacity .15s ease"},topShadow:{zIndex:2,left:0,right:0,height:o.spacing.sm,background:`linear-gradient(${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`},leftShadow:{zIndex:3,top:0,left:0,bottom:0,width:o.spacing.sm,background:`linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to right, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`},rightShadow:{zIndex:2,top:0,bottom:0,right:0,width:o.spacing.sm,background:`linear-gradient(to left, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)}), linear-gradient(to left, ${o.fn.rgba(o.black,e)}, ${o.fn.rgba(o.black,0)} 30%)`},bottomShadow:{zIndex:2,left:0,right:0,height:o.spacing.sm,background:`linear-gradient(${o.fn.rgba(o.black,0)}, ${o.fn.rgba(o.black,e)}), linear-gradient(${o.fn.rgba(o.black,0)} 30%, ${o.fn.rgba(o.black,e)})`},shadowVisible:{opacity:1}}});function $e({topShadowVisible:o,leftShadowVisible:e,rightShadowVisible:r,bottomShadowVisible:t,headerHeight:f,footerHeight:l,onScrollPositionChange:n,children:s,viewportRef:u,scrollAreaProps:m}){let p=l?l-1:0,{cx:C,classes:c}=Bt();return(0,co.jsxs)(uo.ScrollArea,{...m,viewportRef:u,classNames:{root:c.root,scrollbar:c.scrollbar,thumb:c.thumb,corner:c.corner},styles:{scrollbar:{marginTop:f,marginBottom:p}},onScrollPositionChange:n,children:[s,(0,co.jsx)(uo.Box,{className:C(c.shadow,c.topShadow,{[c.shadowVisible]:o}),sx:{top:f}}),(0,co.jsx)("div",{className:C(c.shadow,c.leftShadow,{[c.shadowVisible]:e})}),(0,co.jsx)("div",{className:C(c.shadow,c.rightShadow,{[c.shadowVisible]:r})}),(0,co.jsx)(uo.Box,{className:C(c.shadow,c.bottomShadow,{[c.shadowVisible]:t}),sx:{bottom:p}})]})}var T=require("react/jsx-runtime"),jr={},Dt=(0,G.createStyles)((o,{borderColor:e,rowBorderColor:r})=>{let t=typeof e=="function"?e(o):e,f=typeof r=="function"?r(o):r;return{root:{position:"relative",display:"flex",flexDirection:"column",overflow:"hidden",tr:{backgroundColor:o.colorScheme==="dark"?o.colors.dark[7]:o.white},"&&":{"thead tr th":{borderBottomColor:t},"tbody tr td":{borderTopColor:f}}},lastRowBorderBottomVisible:{"tbody tr:last-of-type td":{borderBottom:`1px solid ${f}`}},textSelectionDisabled:{userSelect:"none"},table:{borderCollapse:"separate",borderSpacing:0},tableWithBorder:{border:`1px solid ${t}`},tableWithColumnBorders:{"&&":{"th, td":{":not(:first-of-type)":{borderLeft:`1px solid ${f}`}}}},tableWithColumnBordersAndSelectableRecords:{thead:{"tr + tr":{th:{borderLeft:`1px solid ${f}`}}}},verticalAlignmentTop:{td:{verticalAlign:"top"}},verticalAlignmentBottom:{td:{verticalAlign:"bottom"}}}});function Ye({withBorder:o,borderRadius:e,borderColor:r=B=>B.colorScheme==="dark"?B.colors.dark[4]:B.colors.gray[3],rowBorderColor:t=B=>B.fn.rgba(B.colorScheme==="dark"?B.colors.dark[4]:B.colors.gray[3],.65),withColumnBorders:f,textSelectionDisabled:l,height:n="100%",minHeight:s,shadow:u,verticalAlignment:m="center",fetching:p,columns:C,groups:c,defaultColumnProps:I,defaultColumnRender:P,idAccessor:i="id",records:S,selectedRecords:g,onSelectedRecordsChange:D,isRecordSelectable:h,allRecordsSelectionCheckboxProps:V={"aria-label":"Select all records"},getRecordSelectionCheckboxProps:v=(B,eo)=>({"aria-label":`Select record ${eo+1}`}),sortStatus:F,sortIcons:M,onSortStatusChange:H,horizontalSpacing:O,page:N,onPageChange:po,totalRecords:To,recordsPerPage:Fo,onRecordsPerPageChange:wo,recordsPerPageOptions:Mo,recordsPerPageLabel:ko="Records per page",paginationColor:Ro,paginationSize:se="sm",paginationText:de=({from:B,to:eo,totalRecords:ro})=>`${B} - ${eo} / ${ro}`,paginationWrapBreakpoint:Uo="sm",getPaginationControlProps:ce=B=>B==="previous"?{"aria-label":"Previous page"}:B==="next"?{"aria-label":"Next page"}:{},loaderBackgroundBlur:oa,customLoader:ea,loaderSize:ra,loaderVariant:aa,loaderColor:ta,loadingText:fa="...",emptyState:la,noRecordsText:_e="No records",noRecordsIcon:na,striped:sa,noHeader:da,onRowClick:ue,onCellClick:ca,onScrollToTop:je,onScrollToBottom:Je,onScrollToLeft:or,onScrollToRight:er,rowContextMenu:E,rowExpansion:ua,rowClassName:pa,rowStyle:ma,rowSx:xa,customRowAttributes:Ia,scrollViewportRef:ia,scrollAreaProps:ga,bodyRef:Ca,m:Sa,my:ha,mx:ba,mt:Ba,mb:Da,ml:ya,mr:Pa,sx:Ta,className:Fa,classNames:zo,style:wa,styles:pe,...Ma}){let{ref:B,width:eo,height:ro}=oo(),Go=(0,L.useMemo)(()=>c?.flatMap(x=>x.columns)??C,[C,c]),{ref:ka,height:me}=oo(),{ref:Ra,width:xe,height:vo}=oo(),{ref:va,height:Oa}=oo(),{ref:Aa,height:rr}=oo(),[Ie,ar]=(0,L.useState)(!0),[ie,tr]=(0,L.useState)(!0),[Vo,fr]=(0,L.useState)(!0),[ge,lr]=(0,L.useState)(!0),{rowContextMenuInfo:ao,setRowContextMenuInfo:mo}=Qr(p),La=Kr({rowExpansion:ua,records:S,idAccessor:i}),Ce=(0,L.useCallback)(()=>{if(!p&&E&&mo(null),p||vo<=ro)ar(!0),tr(!0);else{let x=B.current.scrollTop,b=x===0,k=vo-x-ro<1;ar(b),tr(k),b&&b!==Ie&&je?.(),k&&k!==ie&&Je?.()}if(p||xe===eo)fr(!0),lr(!0);else{let x=B.current.scrollLeft,b=x===0,k=xe-x-eo<1;fr(b),lr(k),b&&b!==Vo&&or?.(),k&&k!==ge&&er?.()}},[p,Je,or,er,je,E,ro,B,eo,ie,Vo,ge,Ie,mo,vo,xe]);Mr(Ce,[Ce]);let Ha=(0,L.useCallback)(x=>{B.current.scrollTo({top:0,left:0}),po(x)},[po,B]),Xo=S?.length,nr=S?.map(x=>y(x,i)),Oo=!!g,Ao=g?.map(x=>y(x,i)),sr=nr!==void 0&&Ao!==void 0&&Ao.length>0,Se=h?S?.filter(h):S,Qo=Se?.map(x=>y(x,i)),Ko=sr&&Qo.every(x=>Ao.includes(x)),Na=sr&&Qo.some(x=>Ao.includes(x)),Ea=(0,L.useCallback)(()=>{g&&D&&D(Ko?g.filter(x=>!Qo.includes(y(x,i))):Co([...g,...Se],x=>y(x,i)))},[Ko,i,D,Qo,Se,g]),{lastSelectionChangeIndex:Zo,setLastSelectionChangeIndex:qa}=Xr(nr),he=Oo&&!Vo,{cx:dr,classes:X,theme:Wa}=Dt({borderColor:r,rowBorderColor:t}),Ua={m:Sa,my:ha,mx:ba,mt:Ba,mb:Da,ml:ya,mr:Pa},$o=typeof pe=="function"?pe(Wa,jr,jr):pe;return(0,T.jsxs)(G.Box,{...Ua,className:dr(X.root,{[X.tableWithBorder]:o},Fa,zo?.root),sx:[x=>({borderRadius:x.radius[e]||e,boxShadow:x.shadows[u]||u,height:n,minHeight:s}),...(0,G.packSx)(Ta)],style:{...$o?.root,...wa},children:[(0,T.jsx)($e,{viewportRef:(0,Jr.useMergedRef)(B,ia||null),topShadowVisible:!Ie,leftShadowVisible:!(g||Vo),rightShadowVisible:!ge,bottomShadowVisible:!ie,headerHeight:me,footerHeight:Oa,onScrollPositionChange:Ce,scrollAreaProps:ga,children:(0,T.jsxs)(G.Table,{ref:Ra,horizontalSpacing:O,className:dr(X.table,{[X.tableWithColumnBorders]:f,[X.lastRowBorderBottomVisible]:vo<ro,[X.textSelectionDisabled]:l,[X.verticalAlignmentTop]:m==="top",[X.verticalAlignmentBottom]:m==="bottom",[X.tableWithColumnBordersAndSelectableRecords]:Oo&&f}),striped:Xo?sa:!1,...Ma,children:[da?null:(0,T.jsx)(Wr,{ref:ka,className:zo?.header,style:$o?.header,columns:Go,defaultColumnProps:I,groups:c,sortStatus:F,sortIcons:M,onSortStatusChange:H,selectionVisible:Oo,selectionChecked:Ko,selectionIndeterminate:Na&&!Ko,onSelectionChange:Ea,selectionCheckboxProps:V,leftShadowVisible:he}),(0,T.jsx)("tbody",{ref:Ca,children:Xo?S.map((x,b)=>{let k=y(x,i),Lo=Ao?.includes(k)||!1,Yo=!1,_o=!1;if(E){let{hidden:w}=E;(!w||!(typeof w=="function"?w(x,b):w))&&(E.trigger==="click"?Yo=!0:_o=!0)}let jo;D&&g&&(jo=w=>{if(w.nativeEvent.shiftKey&&Zo!==null){let xo=S.filter(b>Zo?(to,fo)=>fo>=Zo&&fo<=b&&(h?h(to,fo):!0):(to,fo)=>fo>=b&&fo<=Zo&&(h?h(to,fo):!0));D(Lo?ee(g,xo,to=>y(to,i)):Co([...g,...xo],to=>y(to,i)))}else D(Lo?g.filter(xo=>y(xo,i)!==k):Co([...g,x],xo=>y(xo,i)));qa(b)});let Ho;Yo?Ho=w=>{mo({y:w.clientY,x:w.clientX,record:x,recordIndex:b}),ue?.(x,b,w)}:ue&&(Ho=w=>{ue(x,b,w)});let cr;return _o&&(cr=w=>{w.preventDefault(),mo({y:w.clientY,x:w.clientX,record:x,recordIndex:b})}),(0,T.jsx)(Xe,{record:x,recordIndex:b,columns:Go,defaultColumnProps:I,defaultColumnRender:P,selectionVisible:Oo,selectionChecked:Lo,onSelectionChange:jo,isRecordSelectable:h,getSelectionCheckboxProps:v,onClick:Ho,onCellClick:ca,onContextMenu:cr,contextMenuVisible:ao?y(ao.record,i)===k:!1,expansion:La,className:pa,style:ma,sx:xa,customAttributes:Ia,leftShadowVisible:he},k)}):(0,T.jsx)(De,{})}),Go.some(({footer:x})=>x)&&(0,T.jsx)(Ar,{ref:va,className:zo?.footer,style:$o?.footer,borderColor:r,columns:Go,defaultColumnProps:I,selectionVisible:Oo,leftShadowVisible:he,scrollDiff:vo-ro})]})}),N&&(0,T.jsx)(Gr,{ref:Aa,className:zo?.pagination,style:$o?.pagination,topBorderColor:r,horizontalSpacing:O,fetching:p,page:N,onPageChange:Ha,totalRecords:To,recordsPerPage:Fo,onRecordsPerPageChange:wo,recordsPerPageOptions:Mo,recordsPerPageLabel:ko,paginationColor:Ro,paginationSize:se,paginationText:de,paginationWrapBreakpoint:Uo,getPaginationControlProps:ce,noRecordsText:_e,loadingText:fa,recordsLength:Xo}),(0,T.jsx)(qe,{pt:me,pb:rr,fetching:p,backgroundBlur:oa,customContent:ea,size:ra,variant:aa,color:ta}),(0,T.jsx)(we,{pt:me,pb:rr,icon:na,text:_e,active:!p&&!Xo,children:la}),E&&ao&&(0,T.jsx)(G.Portal,{children:(0,T.jsx)(Qe,{zIndex:E.zIndex,borderRadius:E.borderRadius,shadow:E.shadow,y:ao.y,x:ao.x,onDestroy:()=>mo(null),children:E.items(ao.record,ao.recordIndex).map(({divider:x,key:b,title:k,icon:Lo,color:Yo,hidden:_o,disabled:jo,onClick:Ho})=>x?(0,T.jsx)(Ke,{},b):_o?null:(0,T.jsx)(Ze,{title:k??_(b),icon:Lo,color:Yo,disabled:jo,onClick:()=>{mo(null),Ho()}},b))})})]})}a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();
2
2
  //# sourceMappingURL=index.cjs.map