mantine-datatable 2.5.9 → 2.6.0
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/dist/DataTable.d.ts +1 -1
- package/dist/DataTable.d.ts.map +1 -1
- package/dist/DataTableColumnGroupHeaderCell.d.ts +7 -0
- package/dist/DataTableColumnGroupHeaderCell.d.ts.map +1 -0
- package/dist/DataTableHeader.d.ts +2 -0
- package/dist/DataTableHeader.d.ts.map +1 -1
- package/dist/DataTableHeaderSelectorCell.d.ts +2 -1
- package/dist/DataTableHeaderSelectorCell.d.ts.map +1 -1
- package/dist/DataTableScrollArea.d.ts +3 -1
- package/dist/DataTableScrollArea.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +4 -4
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +4 -4
- package/dist/types/DataTableColumnGroup.d.ts +21 -0
- package/dist/types/DataTableColumnGroup.d.ts.map +1 -0
- package/dist/types/DataTableColumnProps.d.ts +16 -0
- package/dist/types/DataTableColumnProps.d.ts.map +1 -0
- package/dist/types/DataTableProps.d.ts +7 -7
- package/dist/types/DataTableProps.d.ts.map +1 -1
- package/dist/useMediaQueries.d.ts +5 -0
- package/dist/useMediaQueries.d.ts.map +1 -0
- package/dist/utils.d.ts +3 -2
- package/dist/utils.d.ts.map +1 -1
- package/package.json +3 -3
package/dist/DataTable.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { DataTableProps } from './types';
|
|
2
|
-
export default function DataTable<T>({ withBorder, borderRadius, borderColor, rowBorderColor, withColumnBorders, textSelectionDisabled, height, minHeight, shadow, verticalAlignment, fetching, columns, defaultColumnRender, idAccessor, records, selectedRecords, onSelectedRecordsChange, isRecordSelectable, allRecordsSelectionCheckboxProps, getRecordSelectionCheckboxProps, sortStatus, sortIcons, onSortStatusChange, horizontalSpacing, page, onPageChange, totalRecords, recordsPerPage, onRecordsPerPageChange, recordsPerPageOptions, recordsPerPageLabel, paginationColor, paginationSize, paginationText, paginationWrapBreakpoint, getPaginationControlProps, loaderBackgroundBlur, customLoader, loaderSize, loaderVariant, loaderColor, loadingText, emptyState, noRecordsText, noRecordsIcon, striped, noHeader: withoutHeader, onRowClick, onCellClick, onScrollToTop, onScrollToBottom, onScrollToLeft, onScrollToRight, rowContextMenu, rowExpansion, rowClassName, rowStyle, rowSx, customRowAttributes, scrollViewportRef: scrollViewportRefProp, bodyRef, m, my, mx, mt, mb, ml, mr, sx, className, classNames, style, styles, ...otherProps }: DataTableProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export default function DataTable<T>({ withBorder, borderRadius, borderColor, rowBorderColor, withColumnBorders, textSelectionDisabled, height, minHeight, shadow, verticalAlignment, fetching, columns, groups, defaultColumnRender, idAccessor, records, selectedRecords, onSelectedRecordsChange, isRecordSelectable, allRecordsSelectionCheckboxProps, getRecordSelectionCheckboxProps, sortStatus, sortIcons, onSortStatusChange, horizontalSpacing, page, onPageChange, totalRecords, recordsPerPage, onRecordsPerPageChange, recordsPerPageOptions, recordsPerPageLabel, paginationColor, paginationSize, paginationText, paginationWrapBreakpoint, getPaginationControlProps, loaderBackgroundBlur, customLoader, loaderSize, loaderVariant, loaderColor, loadingText, emptyState, noRecordsText, noRecordsIcon, striped, noHeader: withoutHeader, onRowClick, onCellClick, onScrollToTop, onScrollToBottom, onScrollToLeft, onScrollToRight, rowContextMenu, rowExpansion, rowClassName, rowStyle, rowSx, customRowAttributes, scrollViewportRef: scrollViewportRefProp, scrollAreaProps, bodyRef, m, my, mx, mt, mb, ml, mr, sx, className, classNames, style, styles, ...otherProps }: DataTableProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
//# sourceMappingURL=DataTable.d.ts.map
|
package/dist/DataTable.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataTable.d.ts","sourceRoot":"","sources":["../DataTable.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DataTable.d.ts","sourceRoot":"","sources":["../DataTable.tsx"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAoF9C,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,CAAC,EAAE,EACnC,UAAU,EACV,YAAY,EACZ,WAAqG,EACrG,cACiG,EACjG,iBAAiB,EACjB,qBAAqB,EACrB,MAAe,EACf,SAAS,EACT,MAAM,EACN,iBAA4B,EAC5B,QAAQ,EACR,OAAO,EACP,MAAM,EACN,mBAAmB,EACnB,UAAiB,EACjB,OAAO,EACP,eAAe,EACf,uBAAuB,EACvB,kBAAkB,EAClB,gCAAyE,EACzE,+BAAgG,EAChG,UAAU,EACV,SAAS,EACT,kBAAkB,EAClB,iBAAiB,EACjB,IAAI,EACJ,YAAY,EACZ,YAAY,EACZ,cAAc,EACd,sBAAsB,EACtB,qBAAqB,EACrB,mBAAwC,EACxC,eAAe,EACf,cAAqB,EACrB,cAAoF,EACpF,wBAA+B,EAC/B,yBAOC,EACD,oBAAoB,EACpB,YAAY,EACZ,UAAU,EACV,aAAa,EACb,WAAW,EACX,WAAmB,EACnB,UAAU,EACV,aAA4B,EAC5B,aAAa,EACb,OAAO,EACP,QAAQ,EAAE,aAAa,EACvB,UAAU,EACV,WAAW,EACX,aAAa,EACb,gBAAgB,EAChB,cAAc,EACd,eAAe,EACf,cAAc,EACd,YAAY,EACZ,YAAY,EACZ,QAAQ,EACR,KAAK,EACL,mBAAmB,EACnB,iBAAiB,EAAE,qBAAqB,EACxC,eAAe,EACf,OAAO,EACP,CAAC,EACD,EAAE,EACF,EAAE,EACF,EAAE,EACF,EAAE,EACF,EAAE,EACF,EAAE,EACF,EAAE,EACF,SAAS,EACT,UAAU,EACV,KAAK,EACL,MAAM,EACN,GAAG,UAAU,EACd,EAAE,cAAc,CAAC,CAAC,CAAC,2CAiXnB"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { DataTableColumnGroup } from './types/DataTableColumnGroup';
|
|
2
|
+
type DataTableColumnGroupHeaderCellProps<T> = {
|
|
3
|
+
group: DataTableColumnGroup<T>;
|
|
4
|
+
};
|
|
5
|
+
export default function DataTableColumnGroupHeaderCell<T>({ group: { id, columns, title, className, style, sx }, }: DataTableColumnGroupHeaderCellProps<T>): import("react/jsx-runtime").JSX.Element | null;
|
|
6
|
+
export {};
|
|
7
|
+
//# sourceMappingURL=DataTableColumnGroupHeaderCell.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableColumnGroupHeaderCell.d.ts","sourceRoot":"","sources":["../DataTableColumnGroupHeaderCell.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAGzE,KAAK,mCAAmC,CAAC,CAAC,IAAI;IAC5C,KAAK,EAAE,oBAAoB,CAAC,CAAC,CAAC,CAAC;CAChC,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,8BAA8B,CAAC,CAAC,EAAE,EACxD,KAAK,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,EAAE,EAAE,GACpD,EAAE,mCAAmC,CAAC,CAAC,CAAC,kDAaxC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type CSSObject } from '@mantine/core';
|
|
2
2
|
import { type ForwardedRef } from 'react';
|
|
3
3
|
import type { DataTableColumn, DataTableSortProps } from './types';
|
|
4
|
+
import { DataTableColumnGroup } from './types/DataTableColumnGroup';
|
|
4
5
|
type DataTableHeaderProps<T> = {
|
|
5
6
|
className?: string;
|
|
6
7
|
style?: CSSObject;
|
|
@@ -8,6 +9,7 @@ type DataTableHeaderProps<T> = {
|
|
|
8
9
|
sortIcons: DataTableSortProps['sortIcons'];
|
|
9
10
|
onSortStatusChange: DataTableSortProps['onSortStatusChange'];
|
|
10
11
|
columns: DataTableColumn<T>[];
|
|
12
|
+
groups: readonly DataTableColumnGroup<T>[] | undefined;
|
|
11
13
|
selectionVisible: boolean;
|
|
12
14
|
selectionChecked: boolean;
|
|
13
15
|
selectionIndeterminate: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataTableHeader.d.ts","sourceRoot":"","sources":["../DataTableHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAgB,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AAC7D,OAAO,EAAkC,KAAK,YAAY,EAAE,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"DataTableHeader.d.ts","sourceRoot":"","sources":["../DataTableHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAgB,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AAC7D,OAAO,EAAkC,KAAK,YAAY,EAAE,MAAM,OAAO,CAAC;AAI1E,OAAO,KAAK,EAAE,eAAe,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AACnE,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAcpE,KAAK,oBAAoB,CAAC,CAAC,IAAI;IAC7B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,UAAU,EAAE,kBAAkB,CAAC,YAAY,CAAC,CAAC;IAC7C,SAAS,EAAE,kBAAkB,CAAC,WAAW,CAAC,CAAC;IAC3C,kBAAkB,EAAE,kBAAkB,CAAC,oBAAoB,CAAC,CAAC;IAC7D,OAAO,EAAE,eAAe,CAAC,CAAC,CAAC,EAAE,CAAC;IAC9B,MAAM,EAAE,SAAS,oBAAoB,CAAC,CAAC,CAAC,EAAE,GAAG,SAAS,CAAC;IACvD,gBAAgB,EAAE,OAAO,CAAC;IAC1B,gBAAgB,EAAE,OAAO,CAAC;IAC1B,sBAAsB,EAAE,OAAO,CAAC;IAChC,iBAAiB,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAC;IAC5C,sBAAsB,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAChD,iBAAiB,EAAE,OAAO,CAAC;CAC5B,CAAC;;SAmFgD,aAAa,uBAAuB,CAAC;MAAO,WAAW;AAjFzG,wBAiF0G"}
|
|
@@ -4,7 +4,8 @@ type DataTableHeaderSelectorCellProps = {
|
|
|
4
4
|
indeterminate: boolean;
|
|
5
5
|
checkboxProps: Record<string, unknown>;
|
|
6
6
|
onChange: (() => void) | undefined;
|
|
7
|
+
rowSpan?: number;
|
|
7
8
|
};
|
|
8
|
-
export default function DataTableHeaderSelectorCell({ shadowVisible, checked, indeterminate, checkboxProps, onChange, }: DataTableHeaderSelectorCellProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export default function DataTableHeaderSelectorCell({ shadowVisible, checked, indeterminate, checkboxProps, onChange, rowSpan, }: DataTableHeaderSelectorCellProps): import("react/jsx-runtime").JSX.Element;
|
|
9
10
|
export {};
|
|
10
11
|
//# sourceMappingURL=DataTableHeaderSelectorCell.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataTableHeaderSelectorCell.d.ts","sourceRoot":"","sources":["../DataTableHeaderSelectorCell.tsx"],"names":[],"mappings":"AAyCA,KAAK,gCAAgC,GAAG;IACtC,aAAa,EAAE,OAAO,CAAC;IACvB,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,EAAE,OAAO,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACvC,QAAQ,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"DataTableHeaderSelectorCell.d.ts","sourceRoot":"","sources":["../DataTableHeaderSelectorCell.tsx"],"names":[],"mappings":"AAyCA,KAAK,gCAAgC,GAAG;IACtC,aAAa,EAAE,OAAO,CAAC;IACvB,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,EAAE,OAAO,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACvC,QAAQ,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAC;IACnC,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,2BAA2B,CAAC,EAClD,aAAa,EACb,OAAO,EACP,aAAa,EACb,aAAa,EACb,QAAQ,EACR,OAAO,GACR,EAAE,gCAAgC,2CAclC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ScrollAreaProps } from '@mantine/core';
|
|
1
2
|
import { Ref, type ReactNode } from 'react';
|
|
2
3
|
type DataTableScrollAreaProps = {
|
|
3
4
|
topShadowVisible: boolean;
|
|
@@ -8,8 +9,9 @@ type DataTableScrollAreaProps = {
|
|
|
8
9
|
footerHeight: number;
|
|
9
10
|
onScrollPositionChange: () => void;
|
|
10
11
|
viewportRef: Ref<HTMLDivElement>;
|
|
12
|
+
scrollAreaProps?: Omit<ScrollAreaProps, 'classNames' | 'styles' | 'onScrollPositionChange'>;
|
|
11
13
|
children: ReactNode;
|
|
12
14
|
};
|
|
13
|
-
export default function DataTableScrollArea({ topShadowVisible, leftShadowVisible, rightShadowVisible, bottomShadowVisible, headerHeight, footerHeight, onScrollPositionChange, children, viewportRef, }: DataTableScrollAreaProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export default function DataTableScrollArea({ topShadowVisible, leftShadowVisible, rightShadowVisible, bottomShadowVisible, headerHeight, footerHeight, onScrollPositionChange, children, viewportRef, scrollAreaProps, }: DataTableScrollAreaProps): import("react/jsx-runtime").JSX.Element;
|
|
14
16
|
export {};
|
|
15
17
|
//# sourceMappingURL=DataTableScrollArea.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataTableScrollArea.d.ts","sourceRoot":"","sources":["../DataTableScrollArea.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DataTableScrollArea.d.ts","sourceRoot":"","sources":["../DataTableScrollArea.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiC,eAAe,EAAE,MAAM,eAAe,CAAC;AAC/E,OAAO,EAAE,GAAG,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AA4E5C,KAAK,wBAAwB,GAAG;IAC9B,gBAAgB,EAAE,OAAO,CAAC;IAC1B,iBAAiB,EAAE,OAAO,CAAC;IAC3B,kBAAkB,EAAE,OAAO,CAAC;IAC5B,mBAAmB,EAAE,OAAO,CAAC;IAC7B,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,sBAAsB,EAAE,MAAM,IAAI,CAAC;IACnC,WAAW,EAAE,GAAG,CAAC,cAAc,CAAC,CAAC;IACjC,eAAe,CAAC,EAAE,IAAI,CAAC,eAAe,EAAE,YAAY,GAAG,QAAQ,GAAG,wBAAwB,CAAC,CAAC;IAC5F,QAAQ,EAAE,SAAS,CAAC;CACrB,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAC,EAC1C,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,YAAY,EACZ,YAAY,EACZ,sBAAsB,EACtB,QAAQ,EACR,WAAW,EACX,eAAe,GAChB,EAAE,wBAAwB,2CAwB1B"}
|
package/dist/index.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var Pa=Object.create;var Vo=Object.defineProperty;var Ra=Object.getOwnPropertyDescriptor;var ka=Object.getOwnPropertyNames;var Fa=Object.getPrototypeOf,Ma=Object.prototype.hasOwnProperty;var Oa=(o,e)=>()=>(o&&(e=o(o=0)),e);var Ie=(o,e)=>()=>(e||o((e={exports:{}}).exports,e),e.exports),va=(o,e)=>{for(var r in e)Vo(o,r,{get:e[r],enumerable:!0})},rr=(o,e,r,t)=>{if(e&&typeof e=="object"||typeof e=="function")for(let f of ka(e))!Ma.call(o,f)&&f!==r&&Vo(o,f,{get:()=>e[f],enumerable:!(t=Ra(e,f))||t.enumerable});return o};var ar=(o,e,r)=>(r=o!=null?Pa(Fa(o)):{},rr(e||!o||!o.__esModule?Vo(r,"default",{value:o,enumerable:!0}):r,o)),Aa=o=>rr(Vo({},"__esModule",{value:!0}),o);var d,a=Oa(()=>{"use strict";d=ar(require("react"),1)});var nr=Ie((mt,fr)=>{"use strict";a();var Ha="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";fr.exports=Ha});var cr=Ie((It,sr)=>{"use strict";a();var Ea=nr();function lr(){}function dr(){}dr.resetWarningCache=lr;sr.exports=function(){function o(t,f,l,n,s,p){if(p!==Ea){var x=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 x.name="Invariant Violation",x}}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:dr,resetWarningCache:lr};return r.PropTypes=r,r}});var pr=Ie((St,ur)=>{a();ur.exports=cr()();var gt,Ct});var dt={};va(dt,{DataTable:()=>ze,differenceBy:()=>Qo,getValueAtPath:()=>ko,humanize:()=>po,uniqBy:()=>mo});module.exports=Aa(dt);a();a();var j=require("@mantine/core"),_=require("@mantine/hooks"),Q=require("react");a();var tr=require("@mantine/core"),ie=require("react/jsx-runtime"),La=(0,tr.createStyles)({root:{"&&":{background:"transparent",":last-of-type td":{borderBottom:"none"}}}});function ge(){let{classes:o}=La();return(0,ie.jsx)("tr",{className:o.root,children:(0,ie.jsx)("td",{})})}a();var co=require("@mantine/core");a();a();var Ro=require("react"),K=ar(pr());a();var mr={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 Na=Object.defineProperty,qa=Object.defineProperties,Wa=Object.getOwnPropertyDescriptors,Go=Object.getOwnPropertySymbols,ir=Object.prototype.hasOwnProperty,gr=Object.prototype.propertyIsEnumerable,xr=(o,e,r)=>e in o?Na(o,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):o[e]=r,Ir=(o,e)=>{for(var r in e||(e={}))ir.call(e,r)&&xr(o,r,e[r]);if(Go)for(var r of Go(e))gr.call(e,r)&&xr(o,r,e[r]);return o},za=(o,e)=>qa(o,Wa(e)),Ua=(o,e)=>{var r={};for(var t in o)ir.call(o,t)&&e.indexOf(t)<0&&(r[t]=o[t]);if(o!=null&&Go)for(var t of Go(o))e.indexOf(t)<0&&gr.call(o,t)&&(r[t]=o[t]);return r},$=(o,e,r)=>{let t=(0,Ro.forwardRef)((f,l)=>{var n=f,{color:s="currentColor",size:p=24,stroke:x=2,children:c}=n,u=Ua(n,["color","size","stroke","children"]);return(0,Ro.createElement)("svg",Ir(za(Ir({ref:l},mr),{width:p,height:p,stroke:s,strokeWidth:x,className:`tabler-icon tabler-icon-${o}`}),u),[...r.map(([I,m])=>(0,Ro.createElement)(I,m)),...c||[]])});return t.propTypes={color:K.default.string,size:K.default.oneOfType([K.default.string,K.default.number]),stroke:K.default.oneOfType([K.default.string,K.default.number])},t.displayName=`${e}`,t};a();var Ce=$("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 Se=$("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 he=$("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 be=$("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 U=require("react/jsx-runtime"),Va=(0,co.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 Be({icon:o,text:e,pt:r,pb:t,active:f,children:l}){let{classes:n,cx:s}=Va();return(0,U.jsx)(co.Center,{pt:r,pb:t,className:s(n.root,{[n.active]:f}),children:l||(0,U.jsxs)(U.Fragment,{children:[o||(0,U.jsx)("div",{className:n.standardIcon,children:(0,U.jsx)(he,{})}),(0,U.jsx)(co.Text,{size:"sm",color:"dimmed",children:e})]})})}a();var $o=require("@mantine/core"),Dr=require("react");a();var Zo=require("@mantine/core");a();var Cr=require("@mantine/core"),Sr=require("@mantine/hooks"),Xo=require("react"),hr=typeof window<"u"?Xo.useLayoutEffect:Xo.useEffect;function uo(o){let e=(0,Cr.useMantineTheme)(),r=typeof o=="function"?o(e):o;return(0,Sr.useMediaQuery)(r||"",!0)}function po(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 Qo(o,e,r){return o.filter(t=>!e.map(r).includes(r(t)))}function mo(o,e){return o.filter((r,t,f)=>t===f.findIndex(l=>e(r)===e(l)))}function ko(o,e){return e?e.match(/([^[.\]])+/g).reduce((t,f)=>t&&t[f],o):void 0}function D(o,e){return typeof e=="string"?ko(o,e):e(o)}var br=require("react/jsx-runtime"),Ga=(0,Zo.createStyles)({noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function De({className:o,sx:e,style:r,visibleMediaQuery:t,title:f,noWrap:l,ellipsis:n,textAlignment:s,width:p}){let{cx:x,classes:c}=Ga();return uo(t)?(0,br.jsx)(Zo.Box,{component:"th",className:x({[c.noWrap]:l||n,[c.ellipsis]:n},o),sx:[{"&&":{textAlign:s},width:p,minWidth:p,maxWidth:p},e],style:r,children:f}):null}a();var Ko=require("@mantine/core"),Br=require("react/jsx-runtime"),Xa=(0,Ko.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,Ko.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 ye({shadowVisible:o}){let{cx:e,classes:r}=Xa();return(0,Br.jsx)("th",{className:e(r.root,{[r.shadowVisible]:o})})}var xo=require("react/jsx-runtime"),Qa=(0,$o.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"}}}),yr=(0,Dr.forwardRef)(function({className:e,style:r,borderColor:t,columns:f,selectionVisible:l,leftShadowVisible:n,scrollDiff:s},p){let{cx:x,classes:c}=Qa({scrollDiff:s,borderColor:t});return(0,xo.jsx)($o.Box,{component:"tfoot",ref:p,className:x(c.root,e),style:r,children:(0,xo.jsxs)("tr",{children:[l&&(0,xo.jsx)(ye,{shadowVisible:n}),f.map(({accessor:u,hidden:I,visibleMediaQuery:m,textAlignment:S,width:g,footer:h,footerClassName:C,footerStyle:O,footerSx:M,noWrap:L,ellipsis:R})=>I?null:(0,xo.jsx)(De,{className:C,style:O,sx:M,visibleMediaQuery:m,textAlignment:S,width:g,title:h,noWrap:L,ellipsis:R},u))]})})});a();var wr=require("@mantine/core"),Pr=require("react");a();var w=require("@mantine/core"),Tr=require("@mantine/hooks");var y=require("react/jsx-runtime"),Za=(0,w.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 Ka({children:o,isActive:e}){let[r,{close:t,toggle:f}]=(0,Tr.useDisclosure)(!1);return(0,y.jsxs)(w.Popover,{withArrow:!0,withinPortal:!0,shadow:"md",opened:r,onClose:t,trapFocus:!0,children:[(0,y.jsx)(w.Popover.Target,{children:(0,y.jsx)(w.ActionIcon,{onClick:l=>{l.preventDefault(),f()},variant:e?"default":"subtle",children:(0,y.jsx)(be,{size:14})})}),(0,y.jsx)(w.Popover.Dropdown,{children:typeof o=="function"?o({close:t}):o})]})}function Te({className:o,sx:e,style:r,accessor:t,visibleMediaQuery:f,title:l,sortable:n,sortIcons:s,textAlignment:p,width:x,sortStatus:c,onSortStatusChange:u,filter:I,filtering:m}){let{cx:S,classes:g}=Za();if(!uo(f))return null;let h=l??po(t),C=typeof h=="string"?h:void 0,O=n&&u?M=>{M?.defaultPrevented||u({columnAccessor:t,direction:c?.columnAccessor===t?c.direction==="asc"?"desc":"asc":c?.direction??"asc"})}:void 0;return(0,y.jsx)(w.Box,{component:"th",className:S({[g.sortableColumnHeader]:n},o),sx:[{"&&":{textAlign:p},width:x,minWidth:x,maxWidth:x},e],style:r,role:n?"button":void 0,tabIndex:n?0:void 0,onClick:O,onKeyDown:M=>M.key==="Enter"&&O?.(),children:(0,y.jsxs)(w.Group,{className:g.sortableColumnHeaderGroup,position:"apart",noWrap:!0,children:[(0,y.jsx)(w.Box,{className:S(g.columnHeaderText,g.sortableColumnHeaderText),title:C,children:h}),n||c?.columnAccessor===t?(0,y.jsx)(y.Fragment,{children:c?.columnAccessor===t?(0,y.jsx)(w.Center,{className:S(g.sortableColumnHeaderIcon,{[g.sortableColumnHeaderIconRotated]:c.direction==="desc"}),role:"img","aria-label":`Sorted ${c.direction==="desc"?"descending":"ascending"}`,children:s?.sorted||(0,y.jsx)(Ce,{size:14})}):(0,y.jsx)(w.Center,{className:g.sortableColumnHeaderUnsortedIcon,role:"img","aria-label":"Not sorted",children:s?.unsorted||(0,y.jsx)(Se,{size:14})})}):null,I?(0,y.jsx)(Ka,{isActive:!!m,children:I}):null]})})}a();var Io=require("@mantine/core"),we=require("react/jsx-runtime"),$a=(0,Io.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,Io.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 Pe({shadowVisible:o,checked:e,indeterminate:r,checkboxProps:t,onChange:f}){let{cx:l,classes:n}=$a();return(0,we.jsx)("th",{className:l(n.root,{[n.shadowVisible]:o}),children:(0,we.jsx)(Io.Checkbox,{classNames:{input:n.checkboxInput},checked:e,indeterminate:r,disabled:!f,onChange:f,...t})})}var io=require("react/jsx-runtime"),Ya=(0,wr.createStyles)(o=>({root:{zIndex:2,position:"sticky",top:0,background:o.colorScheme==="dark"?o.colors.dark[7]:o.white},textSelectionDisabled:{userSelect:"none"}})),Rr=(0,Pr.forwardRef)(function({className:e,style:r,sortStatus:t,sortIcons:f,onSortStatusChange:l,columns:n,selectionVisible:s,selectionChecked:p,selectionIndeterminate:x,onSelectionChange:c,selectionCheckboxProps:u,leftShadowVisible:I},m){let{classes:S,cx:g}=Ya();return(0,io.jsx)("thead",{className:g(S.root,e),style:r,ref:m,children:(0,io.jsxs)("tr",{children:[s&&(0,io.jsx)(Pe,{shadowVisible:I,checked:p,indeterminate:x,checkboxProps:u,onChange:c}),n.map(({accessor:h,hidden:C,visibleMediaQuery:O,textAlignment:M,width:L,title:R,sortable:v,titleClassName:k,titleStyle:H,titleSx:E,filter:J,filtering:bo})=>C?null:(0,io.jsx)(Te,{className:k,style:H,sx:E,accessor:h,visibleMediaQuery:O,textAlignment:M,width:L,title:R,sortable:v,sortStatus:t,sortIcons:f,onSortStatusChange:l,filter:J,filtering:bo},h))]})})});a();var go=require("@mantine/core"),Re=require("react/jsx-runtime"),_a=(0,go.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 ke({pt:o,pb:e,fetching:r,customContent:t,backgroundBlur:f,size:l,variant:n,color:s}){let{classes:p,cx:x}=_a();return(0,Re.jsx)(go.Center,{pt:o,pb:e,className:x(p.root,{[p.fetching]:r}),sx:f?{backdropFilter:`blur(${f}px)`}:void 0,children:r&&(t||(0,Re.jsx)(go.Loader,{size:l,variant:n,color:s}))})}a();var Y=require("@mantine/core"),Fr=require("react");a();var A=require("@mantine/core"),q=require("react/jsx-runtime"),kr={xs:22,sm:26,md:32,lg:38,xl:44};function Fe({size:o,label:e,values:r,value:t,onChange:f,color:l}){return(0,q.jsxs)(A.Group,{spacing:"xs",children:[(0,q.jsx)(A.Text,{size:o,children:e}),(0,q.jsxs)(A.Menu,{withinPortal:!0,withArrow:!0,children:[(0,q.jsx)(A.Menu.Target,{children:(0,q.jsx)(A.Button,{size:o,variant:"default",sx:[{fontWeight:"normal"},n=>({height:kr[o],paddingLeft:n.spacing[o],paddingRight:n.spacing[o]})],children:t})}),(0,q.jsx)(A.Menu.Dropdown,{children:r.map(n=>{let s=n===t;return(0,q.jsx)(A.Menu.Item,{sx:[{height:kr[o]},p=>({"&&":{color:s?p.white:void 0},background:s?p.colors[l||p.primaryColor][6]:void 0})],disabled:s,onClick:()=>f(n),children:(0,q.jsx)(A.Text,{size:o,children:n})},n)})})]})]})}var Co=require("react/jsx-runtime"),ja=(0,Y.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}})),Mr=(0,Fr.forwardRef)(function({className:e,style:r,topBorderColor:t,fetching:f,page:l,onPageChange:n,paginationColor:s,paginationSize:p,loadingText:x,noRecordsText:c,paginationText:u,totalRecords:I,recordsPerPage:m,onRecordsPerPageChange:S,recordsPerPageLabel:g,recordsPerPageOptions:h,recordsLength:C,horizontalSpacing:O,paginationWrapBreakpoint:M,getPaginationControlProps:L},R){let v;if(f)v=x;else if(!I)v=c;else{let E=(l-1)*m+1,J=E+C-1;v=u({from:E,to:J,totalRecords:I})}let{classes:k,cx:H}=ja({topBorderColor:t,paginationWrapBreakpoint:M});return(0,Co.jsxs)(Y.Box,{ref:R,px:O??"xs",py:"xs",className:H(k.root,e),style:r,children:[(0,Co.jsx)(Y.Text,{className:k.text,size:p,children:v}),h&&(0,Co.jsx)(Fe,{size:p,label:g,values:h,color:s,value:m,onChange:S}),(0,Co.jsx)(Y.Pagination,{color:s,className:H(k.pagination,{[k.paginationFetching]:f||!C}),value:l,onChange:n,size:p,total:Math.ceil(I/m),getControlProps:L})]})});a();var jo=require("@mantine/core");a();var Yo=require("@mantine/core");var Or=require("react/jsx-runtime"),Ja=(0,Yo.createStyles)({withPointerCursor:{cursor:"pointer"},noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function Me({className:o,sx:e,style:r,visibleMediaQuery:t,record:f,recordIndex:l,onClick:n,noWrap:s,ellipsis:p,textAlignment:x,width:c,accessor:u,render:I,defaultRender:m,customCellAttributes:S}){let{cx:g,classes:h}=Ja();return uo(t)?(0,Or.jsx)(Yo.Box,{component:"td",className:g({[h.noWrap]:s||p,[h.ellipsis]:p,[h.withPointerCursor]:n},o),sx:[{width:c,minWidth:c,maxWidth:c,textAlign:x},e],style:r,onClick:n,...S?.(f,l),children:I?I(f,l):m?m(f,l,u):ko(f,u)}):null}a();var _o=require("@mantine/core");a();var Oe=require("@mantine/hooks"),W=require("react");function vr(o){let[e,r]=(0,W.useState)(null),t=o?.join(":")||"";return(0,W.useEffect)(()=>{r(null)},[t]),{lastSelectionChangeIndex:e,setLastSelectionChangeIndex:r}}function Ar(o){let[e,r]=(0,W.useState)(null);return(0,W.useEffect)(()=>{o&&r(null)},[o]),{rowContextMenuInfo:e,setRowContextMenuInfo:r}}function Lr({rowExpansion:o,records:e,idAccessor:r}){let t=[];if(o&&e){let{trigger:s,allowMultiple:p,initiallyExpanded:x}=o;e&&s==="always"?t=e.map(c=>D(c,r)):x&&(t=e.filter(x).map(c=>D(c,r)),p||(t=[t[0]]))}let f,l,n=(0,W.useState)(t);if(o){let{trigger:s,allowMultiple:p,collapseProps:x,content:c}=o;o.expanded?{recordIds:f,onRecordIdsChange:l}=o.expanded:[f,l]=n;let u=I=>l?.(f.filter(m=>m!==D(I,r)));return{expandOnClick:s!=="always"&&s!=="never",isRowExpanded:I=>s==="always"?!0:f.includes(D(I,r)),expandRow:I=>{let m=D(I,r);l?.(p?[...f,m]:[m])},collapseRow:u,collapseProps:x,content:(I,m)=>()=>c({record:I,recordIndex:m,collapse:()=>u(I)})}}}function Hr(o,e){let[r,t]=(0,W.useState)(o),[f,l]=(0,W.useState)(o),n=(0,Oe.useTimeout)(()=>t(!0),0),s=(0,Oe.useTimeout)(()=>l(!1),e||200);return(0,W.useEffect)(()=>{o?(s.clear(),l(!0),n.start()):(n.clear(),t(!1),s.start())},[n,s,o]),{expanded:r,visible:f}}var V=require("react/jsx-runtime"),ot=(0,_o.createStyles)({cell:{"&&":{borderBottomWidth:0,padding:0}},expandedCell:{"&&":{borderBottomWidth:1}}});function ve({open:o,colSpan:e,content:r,collapseProps:t}){let{expanded:f,visible:l}=Hr(o,t?.transitionDuration),{cx:n,classes:s}=ot();return l?(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)("tr",{}),(0,V.jsx)("tr",{children:(0,V.jsx)("td",{className:n(s.cell,{[s.expandedCell]:f}),colSpan:e,children:(0,V.jsx)(_o.Collapse,{in:f,...t,children:r()})})})]}):null}a();var So=require("@mantine/core"),Ae=require("react/jsx-runtime"),et=(0,So.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",zIndex:1,left:0,background:"inherit","&::after":{content:'""',position:"absolute",top:0,right:-(0,So.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 Le({record:o,recordIndex:e,withRightShadow:r,getCheckboxProps:t,...f}){let{cx:l,classes:n}=et();return(0,Ae.jsx)("td",{className:l(n.root,{[n.withRightShadow]:r}),onClick:s=>s.stopPropagation(),children:(0,Ae.jsx)(So.Checkbox,{classNames:{input:n.checkbox},...f,...t(o,e)})})}var G=require("react/jsx-runtime"),rt=(0,jo.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 He({record:o,recordIndex:e,columns:r,defaultColumnRender:t,selectionVisible:f,selectionChecked:l,onSelectionChange:n,isRecordSelectable:s,getSelectionCheckboxProps:p,onClick:x,onCellClick:c,onContextMenu:u,expansion:I,customRowAttributes:m,className:S,style:g,sx:h,contextMenuVisible:C,leftShadowVisible:O}){let{cx:M,classes:L}=rt();return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsxs)(jo.Box,{component:"tr",className:M({[L.withPointerCursor]:x||I?.expandOnClick,[L.selected]:l,[L.contextMenuVisible]:C},typeof S=="function"?S(o,e):S),onClick:R=>{if(I){let{isRowExpanded:v,expandOnClick:k,expandRow:H,collapseRow:E}=I;k&&(v(o)?E(o):H(o))}x?.(R)},style:typeof g=="function"?g(o,e):g,sx:h,...m?.(o,e),onContextMenu:u,children:[f&&(0,G.jsx)(Le,{record:o,recordIndex:e,withRightShadow:O,checked:l,disabled:!n||(s?!s(o,e):!1),onChange:n,getCheckboxProps:p}),r.map((R,v)=>{let{accessor:k,hidden:H,visibleMediaQuery:E,textAlignment:J,noWrap:bo,ellipsis:Jo,width:oe,render:ee,cellsClassName:Bo,cellsStyle:Do,cellsSx:re,customCellAttributes:ae}=R,Mo;return c&&(Mo=te=>c({event:te,record:o,recordIndex:e,column:R,columnIndex:v})),H?null:(0,G.jsx)(Me,{className:typeof Bo=="function"?Bo(o,e):Bo,style:typeof Do=="function"?Do(o,e):Do,sx:re,visibleMediaQuery:E,record:o,recordIndex:e,onClick:Mo,accessor:k,textAlignment:J,noWrap:bo,ellipsis:Jo,width:oe,render:ee,defaultRender:t,customCellAttributes:ae},k)})]}),I&&(0,G.jsx)(ve,{colSpan:r.filter(R=>!R.hidden).length+(f?1:0),open:I.isRowExpanded(o),content:I.content(o,e),collapseProps:I.collapseProps})]})}a();var ho=require("@mantine/core"),X=require("@mantine/hooks"),Er=require("react/jsx-runtime"),at=(0,ho.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 Ee({borderRadius:o="xs",shadow:e="sm",zIndex:r=3,y:t,x:f,onDestroy:l,children:n}){(0,X.useWindowEvent)("resize",l),(0,X.useWindowEvent)("scroll",l);let s=(0,X.useClickOutside)(l),{ref:p,width:x,height:c}=(0,X.useElementSize)(),u=(0,X.useMergedRef)(s,p),{innerWidth:I,innerHeight:m}=window,{classes:S,theme:{dir:g,spacing:h}}=at(),C=(0,ho.px)(h.md);return(0,Er.jsx)(ho.Paper,{ref:u,shadow:e,radius:o,className:S.root,sx:{zIndex:r,top:t+c+C>m?m-c-C:t,left:g==="ltr"?f+x+C>I?I-x-C:f:I-C-(f-x-C<0?x+C:f)},children:n})}a();var Nr=require("@mantine/core"),qr=require("react/jsx-runtime"),tt=(0,Nr.createStyles)(o=>({root:{height:1,background:o.colorScheme==="dark"?o.colors.dark[5]:o.colors.gray[1]}}));function Ne(){let{classes:o}=tt();return(0,qr.jsx)("div",{className:o.root})}a();var z=require("@mantine/core"),Fo=require("react/jsx-runtime"),ft=(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 qe({icon:o,title:e,color:r,disabled:t,onClick:f}){let{classes:l}=ft({color:r});return(0,Fo.jsxs)(z.UnstyledButton,{className:l.root,disabled:t,onClick:f,children:[o&&(0,Fo.jsx)(z.Box,{className:l.icon,children:o}),(0,Fo.jsx)(z.Text,{className:l.title,size:"sm",children:e})]})}a();var no=require("@mantine/core"),fo=require("react/jsx-runtime"),nt=(0,no.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 We({topShadowVisible:o,leftShadowVisible:e,rightShadowVisible:r,bottomShadowVisible:t,headerHeight:f,footerHeight:l,onScrollPositionChange:n,children:s,viewportRef:p}){let x=l?l-1:0,{cx:c,classes:u}=nt();return(0,fo.jsxs)(no.ScrollArea,{viewportRef:p,classNames:{root:u.root,scrollbar:u.scrollbar,thumb:u.thumb,corner:u.corner},styles:{scrollbar:{marginTop:f,marginBottom:x}},onScrollPositionChange:n,children:[s,(0,fo.jsx)(no.Box,{className:c(u.shadow,u.topShadow,{[u.shadowVisible]:o}),sx:{top:f}}),(0,fo.jsx)("div",{className:c(u.shadow,u.leftShadow,{[u.shadowVisible]:e})}),(0,fo.jsx)("div",{className:c(u.shadow,u.rightShadow,{[u.shadowVisible]:r})}),(0,fo.jsx)(no.Box,{className:c(u.shadow,u.bottomShadow,{[u.shadowVisible]:t}),sx:{bottom:x}})]})}var P=require("react/jsx-runtime"),Wr={},lt=(0,j.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}`}}}},verticalAlignmentTop:{td:{verticalAlign:"top"}},verticalAlignmentBottom:{td:{verticalAlign:"bottom"}}}});function ze({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:p,verticalAlignment:x="center",fetching:c,columns:u,defaultColumnRender:I,idAccessor:m="id",records:S,selectedRecords:g,onSelectedRecordsChange:h,isRecordSelectable:C,allRecordsSelectionCheckboxProps:O={"aria-label":"Select all records"},getRecordSelectionCheckboxProps:M=(B,oo)=>({"aria-label":`Select record ${oo+1}`}),sortStatus:L,sortIcons:R,onSortStatusChange:v,horizontalSpacing:k,page:H,onPageChange:E,totalRecords:J,recordsPerPage:bo,onRecordsPerPageChange:Jo,recordsPerPageOptions:oe,recordsPerPageLabel:ee="Records per page",paginationColor:Bo,paginationSize:Do="sm",paginationText:re=({from:B,to:oo,totalRecords:eo})=>`${B} - ${oo} / ${eo}`,paginationWrapBreakpoint:ae="sm",getPaginationControlProps:Mo=B=>B==="previous"?{"aria-label":"Previous page"}:B==="next"?{"aria-label":"Next page"}:{},loaderBackgroundBlur:te,customLoader:zr,loaderSize:Ur,loaderVariant:Vr,loaderColor:Gr,loadingText:Xr="...",emptyState:Qr,noRecordsText:Ue="No records",noRecordsIcon:Zr,striped:Kr,noHeader:$r,onRowClick:fe,onCellClick:Yr,onScrollToTop:Ve,onScrollToBottom:Ge,onScrollToLeft:Xe,onScrollToRight:Qe,rowContextMenu:N,rowExpansion:_r,rowClassName:jr,rowStyle:Jr,rowSx:oa,customRowAttributes:ea,scrollViewportRef:ra,bodyRef:aa,m:ta,my:fa,mx:na,mt:la,mb:da,ml:sa,mr:ca,sx:ua,className:pa,classNames:Oo,style:ma,styles:ne,...xa}){let{ref:B,width:oo,height:eo}=(0,_.useElementSize)(),{ref:Ia,height:le}=(0,_.useElementSize)(),{ref:ia,width:de,height:yo}=(0,_.useElementSize)(),{ref:ga,height:Ca}=(0,_.useElementSize)(),{ref:Sa,height:Ze}=(0,_.useElementSize)(),[se,Ke]=(0,Q.useState)(!0),[ce,$e]=(0,Q.useState)(!0),[vo,Ye]=(0,Q.useState)(!0),[ue,_e]=(0,Q.useState)(!0),{rowContextMenuInfo:ro,setRowContextMenuInfo:lo}=Ar(c),ha=Lr({rowExpansion:_r,records:S,idAccessor:m}),pe=(0,Q.useCallback)(()=>{if(!c&&N&&lo(null),c||yo<=eo)Ke(!0),$e(!0);else{let i=B.current.scrollTop,b=i===0,F=yo-i-eo<1;Ke(b),$e(F),b&&b!==se&&Ve?.(),F&&F!==ce&&Ge?.()}if(c||de===oo)Ye(!0),_e(!0);else{let i=B.current.scrollLeft,b=i===0,F=de-i-oo<1;Ye(b),_e(F),b&&b!==vo&&Xe?.(),F&&F!==ue&&Qe?.()}},[c,Ge,Xe,Qe,Ve,N,eo,B,oo,ce,vo,ue,se,lo,yo,de]);hr(pe,[pe]);let ba=(0,Q.useCallback)(i=>{B.current.scrollTo({top:0,left:0}),E(i)},[E,B]),Ao=S?.length,je=S?.map(i=>D(i,m)),Lo=!!g,To=g?.map(i=>D(i,m)),Je=je!==void 0&&To!==void 0&&To.length>0,me=C?S?.filter(C):S,Ho=me?.map(i=>D(i,m)),Eo=Je&&Ho.every(i=>To.includes(i)),Ba=Je&&Ho.some(i=>To.includes(i)),Da=(0,Q.useCallback)(()=>{h?.(Eo?g.filter(i=>!Ho.includes(D(i,m))):mo([...g,...me],i=>D(i,m)))},[Eo,m,h,Ho,me,g]),{lastSelectionChangeIndex:No,setLastSelectionChangeIndex:ya}=vr(je),xe=Lo&&!vo,{cx:or,classes:Z,theme:Ta}=lt({borderColor:r,rowBorderColor:t}),wa={m:ta,my:fa,mx:na,mt:la,mb:da,ml:sa,mr:ca},qo=typeof ne=="function"?ne(Ta,Wr,Wr):ne;return(0,P.jsxs)(j.Box,{...wa,className:or(Z.root,{[Z.tableWithBorder]:o},pa,Oo?.root),sx:[i=>({borderRadius:i.radius[e]||e,boxShadow:i.shadows[p]||p,height:n,minHeight:s}),...(0,j.packSx)(ua)],style:{...qo?.root,...ma},children:[(0,P.jsx)(We,{viewportRef:(0,_.useMergedRef)(B,ra||null),topShadowVisible:!se,leftShadowVisible:!(g||vo),rightShadowVisible:!ue,bottomShadowVisible:!ce,headerHeight:le,footerHeight:Ca,onScrollPositionChange:pe,children:(0,P.jsxs)(j.Table,{ref:ia,horizontalSpacing:k,className:or(Z.table,{[Z.tableWithColumnBorders]:f,[Z.lastRowBorderBottomVisible]:yo<eo,[Z.textSelectionDisabled]:l,[Z.verticalAlignmentTop]:x==="top",[Z.verticalAlignmentBottom]:x==="bottom"}),striped:Ao?Kr:!1,...xa,children:[$r?null:(0,P.jsx)(Rr,{ref:Ia,className:Oo?.header,style:qo?.header,columns:u,sortStatus:L,sortIcons:R,onSortStatusChange:v,selectionVisible:Lo,selectionChecked:Eo,selectionIndeterminate:Ba&&!Eo,onSelectionChange:Da,selectionCheckboxProps:O,leftShadowVisible:xe}),(0,P.jsx)("tbody",{ref:aa,children:Ao?S.map((i,b)=>{let F=D(i,m),wo=To?.includes(F)||!1,Wo=!1,zo=!1;if(N){let{hidden:T}=N;(!T||!(typeof T=="function"?T(i,b):T))&&(N.trigger==="click"?Wo=!0:zo=!0)}let Uo;h&&(Uo=T=>{if(T.nativeEvent.shiftKey&&No!==null){let so=S.filter(b>No?(ao,to)=>to>=No&&to<=b&&(C?C(ao,to):!0):(ao,to)=>to>=b&&to<=No&&(C?C(ao,to):!0));h(wo?Qo(g,so,ao=>D(ao,m)):mo([...g,...so],ao=>D(ao,m)))}else h(wo?g.filter(so=>D(so,m)!==F):mo([...g,i],so=>D(so,m)));ya(b)});let Po;Wo?Po=T=>{lo({y:T.clientY,x:T.clientX,record:i,recordIndex:b}),fe?.(i,b,T)}:fe&&(Po=T=>{fe(i,b,T)});let er;return zo&&(er=T=>{T.preventDefault(),lo({y:T.clientY,x:T.clientX,record:i,recordIndex:b})}),(0,P.jsx)(He,{record:i,recordIndex:b,columns:u,defaultColumnRender:I,selectionVisible:Lo,selectionChecked:wo,onSelectionChange:Uo,isRecordSelectable:C,getSelectionCheckboxProps:M,onClick:Po,onCellClick:Yr,onContextMenu:er,contextMenuVisible:ro?D(ro.record,m)===F:!1,expansion:ha,className:jr,style:Jr,sx:oa,customRowAttributes:ea,leftShadowVisible:xe},F)}):(0,P.jsx)(ge,{})}),u.some(i=>i.footer)&&(0,P.jsx)(yr,{ref:ga,className:Oo?.footer,style:qo?.footer,borderColor:r,columns:u,selectionVisible:Lo,leftShadowVisible:xe,scrollDiff:yo-eo})]})}),H&&(0,P.jsx)(Mr,{ref:Sa,className:Oo?.pagination,style:qo?.pagination,topBorderColor:r,horizontalSpacing:k,fetching:c,page:H,onPageChange:ba,totalRecords:J,recordsPerPage:bo,onRecordsPerPageChange:Jo,recordsPerPageOptions:oe,recordsPerPageLabel:ee,paginationColor:Bo,paginationSize:Do,paginationText:re,paginationWrapBreakpoint:ae,getPaginationControlProps:Mo,noRecordsText:Ue,loadingText:Xr,recordsLength:Ao}),(0,P.jsx)(ke,{pt:le,pb:Ze,fetching:c,backgroundBlur:te,customContent:zr,size:Ur,variant:Vr,color:Gr}),(0,P.jsx)(Be,{pt:le,pb:Ze,icon:Zr,text:Ue,active:!c&&!Ao,children:Qr}),N&&ro&&(0,P.jsx)(Ee,{zIndex:N.zIndex,borderRadius:N.borderRadius,shadow:N.shadow,y:ro.y,x:ro.x,onDestroy:()=>lo(null),children:N.items(ro.record,ro.recordIndex).map(({divider:i,key:b,title:F,icon:wo,color:Wo,hidden:zo,disabled:Uo,onClick:Po})=>i?(0,P.jsx)(Ne,{},b):zo?null:(0,P.jsx)(qe,{title:F??po(b),icon:wo,color:Wo,disabled:Uo,onClick:()=>{lo(null),Po()}},b))})]})}a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();
|
|
1
|
+
"use strict";var Ea=Object.create;var Ko=Object.defineProperty;var Na=Object.getOwnPropertyDescriptor;var qa=Object.getOwnPropertyNames;var Wa=Object.getPrototypeOf,za=Object.prototype.hasOwnProperty;var Ua=(o,e)=>()=>(o&&(e=o(o=0)),e);var ge=(o,e)=>()=>(e||o((e={exports:{}}).exports,e),e.exports),Va=(o,e)=>{for(var r in e)Ko(o,r,{get:e[r],enumerable:!0})},lr=(o,e,r,f)=>{if(e&&typeof e=="object"||typeof e=="function")for(let t of qa(e))!za.call(o,t)&&t!==r&&Ko(o,t,{get:()=>e[t],enumerable:!(f=Na(e,t))||f.enumerable});return o};var sr=(o,e,r)=>(r=o!=null?Ea(Wa(o)):{},lr(e||!o||!o.__esModule?Ko(r,"default",{value:o,enumerable:!0}):r,o)),Ga=o=>lr(Ko({},"__esModule",{value:!0}),o);var c,a=Ua(()=>{"use strict";c=sr(require("react"),1)});var ur=ge((Tt,cr)=>{"use strict";a();var Qa="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";cr.exports=Qa});var Ir=ge((Pt,xr)=>{"use strict";a();var Za=ur();function pr(){}function mr(){}mr.resetWarningCache=pr;xr.exports=function(){function o(f,t,l,n,s,p){if(p!==Za){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:mr,resetWarningCache:pr};return r.PropTypes=r,r}});var gr=ge((Ft,ir)=>{a();ir.exports=Ir()();var kt,Mt});var St={};Va(St,{DataTable:()=>Qe,differenceBy:()=>Yo,getValueAtPath:()=>Ao,humanize:()=>_,uniqBy:()=>io});module.exports=Ga(St);a();a();var eo=require("@mantine/core"),oo=require("@mantine/hooks"),N=require("react");a();var dr=require("@mantine/core"),Ce=require("react/jsx-runtime"),Xa=(0,dr.createStyles)({root:{"&&":{background:"transparent",":last-of-type td":{borderBottom:"none"}}}});function he(){let{classes:o}=Xa();return(0,Ce.jsx)("tr",{className:o.root,children:(0,Ce.jsx)("td",{})})}a();var mo=require("@mantine/core");a();a();var vo=require("react"),$=sr(gr());a();var Cr={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 Ka=Object.defineProperty,$a=Object.defineProperties,Ya=Object.getOwnPropertyDescriptors,$o=Object.getOwnPropertySymbols,br=Object.prototype.hasOwnProperty,Br=Object.prototype.propertyIsEnumerable,hr=(o,e,r)=>e in o?Ka(o,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):o[e]=r,Sr=(o,e)=>{for(var r in e||(e={}))br.call(e,r)&&hr(o,r,e[r]);if($o)for(var r of $o(e))Br.call(e,r)&&hr(o,r,e[r]);return o},_a=(o,e)=>$a(o,Ya(e)),ja=(o,e)=>{var r={};for(var f in o)br.call(o,f)&&e.indexOf(f)<0&&(r[f]=o[f]);if(o!=null&&$o)for(var f of $o(o))e.indexOf(f)<0&&Br.call(o,f)&&(r[f]=o[f]);return r},Y=(o,e,r)=>{let f=(0,vo.forwardRef)((t,l)=>{var n=t,{color:s="currentColor",size:p=24,stroke:m=2,children:u}=n,C=ja(n,["color","size","stroke","children"]);return(0,vo.createElement)("svg",Sr(_a(Sr({ref:l},Cr),{width:p,height:p,stroke:s,strokeWidth:m,className:`tabler-icon tabler-icon-${o}`}),C),[...r.map(([d,h])=>(0,vo.createElement)(d,h)),...u||[]])});return f.propTypes={color:$.default.string,size:$.default.oneOfType([$.default.string,$.default.number]),stroke:$.default.oneOfType([$.default.string,$.default.number])},f.displayName=`${e}`,f};a();var Se=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 be=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 Be=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 De=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 G=require("react/jsx-runtime"),Ja=(0,mo.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 ye({icon:o,text:e,pt:r,pb:f,active:t,children:l}){let{classes:n,cx:s}=Ja();return(0,G.jsx)(mo.Center,{pt:r,pb:f,className:s(n.root,{[n.active]:t}),children:l||(0,G.jsxs)(G.Fragment,{children:[o||(0,G.jsx)("div",{className:n.standardIcon,children:(0,G.jsx)(Be,{})}),(0,G.jsx)(mo.Text,{size:"sm",color:"dimmed",children:e})]})})}a();var Jo=require("@mantine/core"),kr=require("react");a();var _o=require("@mantine/core");a();var Te=require("@mantine/core"),yr=require("@mantine/hooks"),lo=require("react");a();var xo=require("react");function ot(o,e){let r=()=>{e(o.map(t=>t.matches))},f=o.map(t=>{try{return t.addEventListener("change",r),()=>t.removeEventListener("change",r)}catch{return t.addListener(r),()=>t.removeListener(r)}});return()=>{f.forEach(t=>t())}}function et(o,e){return e||(typeof window<"u"&&"matchMedia"in window?o.map(r=>window.matchMedia(r).matches):o.map(()=>!1))}function Dr(o,e,{getInitialValueInEffect:r}={getInitialValueInEffect:!0}){let[f,t]=(0,xo.useState)(r?e:et(o,e)),l=(0,xo.useRef)();return(0,xo.useEffect)(()=>{if("matchMedia"in window)return l.current=o.map(n=>window.matchMedia(n)),t(l.current.map(n=>n.matches)),ot(l.current,n=>{t(n)})},[o]),f}var Tr=typeof window<"u"?lo.useLayoutEffect:lo.useEffect;function Io(o){let e=(0,Te.useMantineTheme)(),r=typeof o=="function"?o(e):o;return(0,yr.useMediaQuery)(r||"",!0)}function wr(o){let e=(0,Te.useMantineTheme)(),r=(0,lo.useMemo)(()=>o.map(t=>(typeof t=="function"?t(e):t)??""),[o,e]),f=(0,lo.useMemo)(()=>o.map(()=>!0),[o]);return Dr(r,f)}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 Yo(o,e,r){return o.filter(f=>!e.map(r).includes(r(f)))}function io(o,e){return o.filter((r,f,t)=>f===t.findIndex(l=>e(r)===e(l)))}function Ao(o,e){return e?e.match(/([^[.\]])+/g).reduce((f,t)=>f&&f[t],o):void 0}function y(o,e){return typeof e=="string"?Ao(o,e):e(o)}var Pr=require("react/jsx-runtime"),rt=(0,_o.createStyles)({noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function we({className:o,sx:e,style:r,visibleMediaQuery:f,title:t,noWrap:l,ellipsis:n,textAlignment:s,width:p}){let{cx:m,classes:u}=rt();return Io(f)?(0,Pr.jsx)(_o.Box,{component:"th",className:m({[u.noWrap]:l||n,[u.ellipsis]:n},o),sx:[{"&&":{textAlign:s},width:p,minWidth:p,maxWidth:p},e],style:r,children:t}):null}a();var jo=require("@mantine/core"),Rr=require("react/jsx-runtime"),at=(0,jo.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,jo.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 Pe({shadowVisible:o}){let{cx:e,classes:r}=at();return(0,Rr.jsx)("th",{className:e(r.root,{[r.shadowVisible]:o})})}var go=require("react/jsx-runtime"),tt=(0,Jo.createStyles)((o,{scrollDiff:e,borderColor:r})=>{let f=e<0,t=typeof r=="function"?r(o):r;return{root:{zIndex:2,position:f?"relative":"sticky",bottom:f?e:-1,background:o.colorScheme==="dark"?o.colors.dark[7]:o.white,"&& tr th":{borderTopColor:t}},relative:{position:"relative"},textSelectionDisabled:{userSelect:"none"}}}),Mr=(0,kr.forwardRef)(function({className:e,style:r,borderColor:f,columns:t,selectionVisible:l,leftShadowVisible:n,scrollDiff:s},p){let{cx:m,classes:u}=tt({scrollDiff:s,borderColor:f});return(0,go.jsx)(Jo.Box,{component:"tfoot",ref:p,className:m(u.root,e),style:r,children:(0,go.jsxs)("tr",{children:[l&&(0,go.jsx)(Pe,{shadowVisible:n}),t.map(({accessor:C,hidden:d,visibleMediaQuery:h,textAlignment:I,width:i,footer:g,footerClassName:S,footerStyle:b,footerSx:F,noWrap:L,ellipsis:k})=>d?null:(0,go.jsx)(we,{className:S,style:b,sx:F,visibleMediaQuery:h,textAlignment:I,width:i,title:g,noWrap:L,ellipsis:k},C))]})})});a();var Ar=require("@mantine/core"),Lr=require("react");a();var Fr=require("@mantine/core"),Re=require("react");var Or=require("react/jsx-runtime");function ke({group:{id:o,columns:e,title:r,className:f,style:t,sx:l}}){let n=(0,Re.useMemo)(()=>e.map(m=>m.visibleMediaQuery),[e]),s=wr(n),p=(0,Re.useMemo)(()=>e.filter((m,u)=>!m.hidden&&s?.[u]).length,[e,s]);return p>0?(0,Or.jsx)(Fr.Box,{component:"th",colSpan:p,className:f,sx:l,style:t,children:r??_(o)}):null}a();var P=require("@mantine/core"),vr=require("@mantine/hooks");var T=require("react/jsx-runtime"),ft=(0,P.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 nt({children:o,isActive:e}){let[r,{close:f,toggle:t}]=(0,vr.useDisclosure)(!1);return(0,T.jsxs)(P.Popover,{withArrow:!0,withinPortal:!0,shadow:"md",opened:r,onClose:f,trapFocus:!0,children:[(0,T.jsx)(P.Popover.Target,{children:(0,T.jsx)(P.ActionIcon,{onClick:l=>{l.preventDefault(),t()},variant:e?"default":"subtle",children:(0,T.jsx)(De,{size:14})})}),(0,T.jsx)(P.Popover.Dropdown,{children:typeof o=="function"?o({close:f}):o})]})}function Me({className:o,sx:e,style:r,accessor:f,visibleMediaQuery:t,title:l,sortable:n,sortIcons:s,textAlignment:p,width:m,sortStatus:u,onSortStatusChange:C,filter:d,filtering:h}){let{cx:I,classes:i}=ft();if(!Io(t))return null;let g=l??_(f),S=typeof g=="string"?g:void 0,b=n&&C?F=>{F?.defaultPrevented||C({columnAccessor:f,direction:u?.columnAccessor===f?u.direction==="asc"?"desc":"asc":u?.direction??"asc"})}:void 0;return(0,T.jsx)(P.Box,{component:"th",className:I({[i.sortableColumnHeader]:n},o),sx:[{"&&":{textAlign:p},width:m,minWidth:m,maxWidth:m},e],style:r,role:n?"button":void 0,tabIndex:n?0:void 0,onClick:b,onKeyDown:F=>F.key==="Enter"&&b?.(),children:(0,T.jsxs)(P.Group,{className:i.sortableColumnHeaderGroup,position:"apart",noWrap:!0,children:[(0,T.jsx)(P.Box,{className:I(i.columnHeaderText,i.sortableColumnHeaderText),title:S,children:g}),n||u?.columnAccessor===f?(0,T.jsx)(T.Fragment,{children:u?.columnAccessor===f?(0,T.jsx)(P.Center,{className:I(i.sortableColumnHeaderIcon,{[i.sortableColumnHeaderIconRotated]:u.direction==="desc"}),role:"img","aria-label":`Sorted ${u.direction==="desc"?"descending":"ascending"}`,children:s?.sorted||(0,T.jsx)(Se,{size:14})}):(0,T.jsx)(P.Center,{className:i.sortableColumnHeaderUnsortedIcon,role:"img","aria-label":"Not sorted",children:s?.unsorted||(0,T.jsx)(be,{size:14})})}):null,d?(0,T.jsx)(nt,{isActive:!!h,children:d}):null]})})}a();var Co=require("@mantine/core"),Fe=require("react/jsx-runtime"),lt=(0,Co.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,Co.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 Oe({shadowVisible:o,checked:e,indeterminate:r,checkboxProps:f,onChange:t,rowSpan:l}){let{cx:n,classes:s}=lt();return(0,Fe.jsx)("th",{className:n(s.root,{[s.shadowVisible]:o}),rowSpan:l,children:(0,Fe.jsx)(Co.Checkbox,{classNames:{input:s.checkboxInput},checked:e,indeterminate:r,disabled:!t,onChange:t,...f})})}var j=require("react/jsx-runtime"),st=(0,Ar.createStyles)(o=>({root:{zIndex:2,position:"sticky",top:0,background:o.colorScheme==="dark"?o.colors.dark[7]:o.white},textSelectionDisabled:{userSelect:"none"}})),Hr=(0,Lr.forwardRef)(function({className:e,style:r,sortStatus:f,sortIcons:t,onSortStatusChange:l,columns:n,groups:s,selectionVisible:p,selectionChecked:m,selectionIndeterminate:u,onSelectionChange:C,selectionCheckboxProps:d,leftShadowVisible:h},I){let{classes:i,cx:g}=st(),S=p?(0,j.jsx)(Oe,{shadowVisible:h,checked:m,indeterminate:u,checkboxProps:d,onChange:C,rowSpan:s?2:void 0}):null;return(0,j.jsxs)("thead",{className:g(i.root,e),style:r,ref:I,children:[s&&(0,j.jsxs)("tr",{children:[S,s.map(b=>(0,j.jsx)(ke,{group:b},b.id))]}),(0,j.jsxs)("tr",{children:[!s&&S,n.map(({accessor:b,hidden:F,visibleMediaQuery:L,textAlignment:k,width:v,title:O,sortable:H,titleClassName:E,titleStyle:K,titleSx:Do,filter:yo,filtering:To})=>F?null:(0,j.jsx)(Me,{className:E,style:K,sx:Do,accessor:b,visibleMediaQuery:L,textAlignment:k,width:v,title:O,sortable:H,sortStatus:f,sortIcons:t,onSortStatusChange:l,filter:yo,filtering:To},b))]})]})});a();var ho=require("@mantine/core"),ve=require("react/jsx-runtime"),dt=(0,ho.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 Ae({pt:o,pb:e,fetching:r,customContent:f,backgroundBlur:t,size:l,variant:n,color:s}){let{classes:p,cx:m}=dt();return(0,ve.jsx)(ho.Center,{pt:o,pb:e,className:m(p.root,{[p.fetching]:r}),sx:t?{backdropFilter:`blur(${t}px)`}:void 0,children:r&&(f||(0,ve.jsx)(ho.Loader,{size:l,variant:n,color:s}))})}a();var J=require("@mantine/core"),Nr=require("react");a();var A=require("@mantine/core"),W=require("react/jsx-runtime"),Er={xs:22,sm:26,md:32,lg:38,xl:44};function Le({size:o,label:e,values:r,value:f,onChange:t,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:Er[o],paddingLeft:n.spacing[o],paddingRight:n.spacing[o]})],children:f})}),(0,W.jsx)(A.Menu.Dropdown,{children:r.map(n=>{let s=n===f;return(0,W.jsx)(A.Menu.Item,{sx:[{height:Er[o]},p=>({"&&":{color:s?p.white:void 0},background:s?p.colors[l||p.primaryColor][6]:void 0})],disabled:s,onClick:()=>t(n),children:(0,W.jsx)(A.Text,{size:o,children:n})},n)})})]})]})}var So=require("react/jsx-runtime"),ct=(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}})),qr=(0,Nr.forwardRef)(function({className:e,style:r,topBorderColor:f,fetching:t,page:l,onPageChange:n,paginationColor:s,paginationSize:p,loadingText:m,noRecordsText:u,paginationText:C,totalRecords:d,recordsPerPage:h,onRecordsPerPageChange:I,recordsPerPageLabel:i,recordsPerPageOptions:g,recordsLength:S,horizontalSpacing:b,paginationWrapBreakpoint:F,getPaginationControlProps:L},k){let v;if(t)v=m;else if(!d)v=u;else{let E=(l-1)*h+1,K=E+S-1;v=C({from:E,to:K,totalRecords:d})}let{classes:O,cx:H}=ct({topBorderColor:f,paginationWrapBreakpoint:F});return(0,So.jsxs)(J.Box,{ref:k,px:b??"xs",py:"xs",className:H(O.root,e),style:r,children:[(0,So.jsx)(J.Text,{className:O.text,size:p,children:v}),g&&(0,So.jsx)(Le,{size:p,label:i,values:g,color:s,value:h,onChange:I}),(0,So.jsx)(J.Pagination,{color:s,className:H(O.pagination,{[O.paginationFetching]:t||!S}),value:l,onChange:n,size:p,total:Math.ceil(d/h),getControlProps:L})]})});a();var re=require("@mantine/core");a();var oe=require("@mantine/core");var Wr=require("react/jsx-runtime"),ut=(0,oe.createStyles)({withPointerCursor:{cursor:"pointer"},noWrap:{whiteSpace:"nowrap"},ellipsis:{overflow:"hidden",textOverflow:"ellipsis"}});function He({className:o,sx:e,style:r,visibleMediaQuery:f,record:t,recordIndex:l,onClick:n,noWrap:s,ellipsis:p,textAlignment:m,width:u,accessor:C,render:d,defaultRender:h,customCellAttributes:I}){let{cx:i,classes:g}=ut();return Io(f)?(0,Wr.jsx)(oe.Box,{component:"td",className:i({[g.noWrap]:s||p,[g.ellipsis]:p,[g.withPointerCursor]:n},o),sx:[{width:u,minWidth:u,maxWidth:u,textAlign:m},e],style:r,onClick:n,...I?.(t,l),children:d?d(t,l):h?h(t,l,C):Ao(t,C)}):null}a();var ee=require("@mantine/core");a();var Ee=require("@mantine/hooks"),z=require("react");function zr(o){let[e,r]=(0,z.useState)(null),f=o?.join(":")||"";return(0,z.useEffect)(()=>{r(null)},[f]),{lastSelectionChangeIndex:e,setLastSelectionChangeIndex:r}}function Ur(o){let[e,r]=(0,z.useState)(null);return(0,z.useEffect)(()=>{o&&r(null)},[o]),{rowContextMenuInfo:e,setRowContextMenuInfo:r}}function Vr({rowExpansion:o,records:e,idAccessor:r}){let f=[];if(o&&e){let{trigger:s,allowMultiple:p,initiallyExpanded:m}=o;e&&s==="always"?f=e.map(u=>y(u,r)):m&&(f=e.filter(m).map(u=>y(u,r)),p||(f=[f[0]]))}let t,l,n=(0,z.useState)(f);if(o){let{trigger:s,allowMultiple:p,collapseProps:m,content:u}=o;o.expanded?{recordIds:t,onRecordIdsChange:l}=o.expanded:[t,l]=n;let C=d=>l?.(t.filter(h=>h!==y(d,r)));return{expandOnClick:s!=="always"&&s!=="never",isRowExpanded:d=>s==="always"?!0:t.includes(y(d,r)),expandRow:d=>{let h=y(d,r);l?.(p?[...t,h]:[h])},collapseRow:C,collapseProps:m,content:(d,h)=>()=>u({record:d,recordIndex:h,collapse:()=>C(d)})}}}function Gr(o,e){let[r,f]=(0,z.useState)(o),[t,l]=(0,z.useState)(o),n=(0,Ee.useTimeout)(()=>f(!0),0),s=(0,Ee.useTimeout)(()=>l(!1),e||200);return(0,z.useEffect)(()=>{o?(s.clear(),l(!0),n.start()):(n.clear(),f(!1),s.start())},[n,s,o]),{expanded:r,visible:t}}var X=require("react/jsx-runtime"),pt=(0,ee.createStyles)({cell:{"&&":{borderBottomWidth:0,padding:0}},expandedCell:{"&&":{borderBottomWidth:1}}});function Ne({open:o,colSpan:e,content:r,collapseProps:f}){let{expanded:t,visible:l}=Gr(o,f?.transitionDuration),{cx:n,classes:s}=pt();return l?(0,X.jsxs)(X.Fragment,{children:[(0,X.jsx)("tr",{}),(0,X.jsx)("tr",{children:(0,X.jsx)("td",{className:n(s.cell,{[s.expandedCell]:t}),colSpan:e,children:(0,X.jsx)(ee.Collapse,{in:t,...f,children:r()})})})]}):null}a();var bo=require("@mantine/core"),qe=require("react/jsx-runtime"),mt=(0,bo.createStyles)(o=>{let e=o.colorScheme==="dark"?.5:.05;return{root:{position:"sticky",zIndex:1,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"}},withRightShadow:{"&::after":{opacity:1}},checkbox:{cursor:"pointer"}}});function We({record:o,recordIndex:e,withRightShadow:r,getCheckboxProps:f,...t}){let{cx:l,classes:n}=mt();return(0,qe.jsx)("td",{className:l(n.root,{[n.withRightShadow]:r}),onClick:s=>s.stopPropagation(),children:(0,qe.jsx)(bo.Checkbox,{classNames:{input:n.checkbox},...t,...f(o,e)})})}var Q=require("react/jsx-runtime"),xt=(0,re.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 ze({record:o,recordIndex:e,columns:r,defaultColumnRender:f,selectionVisible:t,selectionChecked:l,onSelectionChange:n,isRecordSelectable:s,getSelectionCheckboxProps:p,onClick:m,onCellClick:u,onContextMenu:C,expansion:d,customRowAttributes:h,className:I,style:i,sx:g,contextMenuVisible:S,leftShadowVisible:b}){let{cx:F,classes:L}=xt();return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsxs)(re.Box,{component:"tr",className:F({[L.withPointerCursor]:m||d?.expandOnClick,[L.selected]:l,[L.contextMenuVisible]:S},typeof I=="function"?I(o,e):I),onClick:k=>{if(d){let{isRowExpanded:v,expandOnClick:O,expandRow:H,collapseRow:E}=d;O&&(v(o)?E(o):H(o))}m?.(k)},style:typeof i=="function"?i(o,e):i,sx:g,...h?.(o,e),onContextMenu:C,children:[t&&(0,Q.jsx)(We,{record:o,recordIndex:e,withRightShadow:b,checked:l,disabled:!n||(s?!s(o,e):!1),onChange:n,getCheckboxProps:p}),r.map((k,v)=>{let{accessor:O,hidden:H,visibleMediaQuery:E,textAlignment:K,noWrap:Do,ellipsis:yo,width:To,render:ae,cellsClassName:wo,cellsStyle:Po,cellsSx:te,customCellAttributes:fe}=k,Ho;return u&&(Ho=ne=>u({event:ne,record:o,recordIndex:e,column:k,columnIndex:v})),H?null:(0,Q.jsx)(He,{className:typeof wo=="function"?wo(o,e):wo,style:typeof Po=="function"?Po(o,e):Po,sx:te,visibleMediaQuery:E,record:o,recordIndex:e,onClick:Ho,accessor:O,textAlignment:K,noWrap:Do,ellipsis:yo,width:To,render:ae,defaultRender:f,customCellAttributes:fe},O)})]}),d&&(0,Q.jsx)(Ne,{colSpan:r.filter(k=>!k.hidden).length+(t?1:0),open:d.isRowExpanded(o),content:d.content(o,e),collapseProps:d.collapseProps})]})}a();var Bo=require("@mantine/core"),Z=require("@mantine/hooks"),Xr=require("react/jsx-runtime"),It=(0,Bo.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 Ue({borderRadius:o="xs",shadow:e="sm",zIndex:r=3,y:f,x:t,onDestroy:l,children:n}){(0,Z.useWindowEvent)("resize",l),(0,Z.useWindowEvent)("scroll",l);let s=(0,Z.useClickOutside)(l),{ref:p,width:m,height:u}=(0,Z.useElementSize)(),C=(0,Z.useMergedRef)(s,p),{innerWidth:d,innerHeight:h}=window,{classes:I,theme:{dir:i,spacing:g}}=It(),S=(0,Bo.px)(g.md);return(0,Xr.jsx)(Bo.Paper,{ref:C,shadow:e,radius:o,className:I.root,sx:{zIndex:r,top:f+u+S>h?h-u-S:f,left:i==="ltr"?t+m+S>d?d-m-S:t:d-S-(t-m-S<0?m+S:t)},children:n})}a();var Qr=require("@mantine/core"),Zr=require("react/jsx-runtime"),it=(0,Qr.createStyles)(o=>({root:{height:1,background:o.colorScheme==="dark"?o.colors.dark[5]:o.colors.gray[1]}}));function Ve(){let{classes:o}=it();return(0,Zr.jsx)("div",{className:o.root})}a();var U=require("@mantine/core"),Lo=require("react/jsx-runtime"),gt=(0,U.createStyles)((o,{color:e})=>{let r=(0,U.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 Ge({icon:o,title:e,color:r,disabled:f,onClick:t}){let{classes:l}=gt({color:r});return(0,Lo.jsxs)(U.UnstyledButton,{className:l.root,disabled:f,onClick:t,children:[o&&(0,Lo.jsx)(U.Box,{className:l.icon,children:o}),(0,Lo.jsx)(U.Text,{className:l.title,size:"sm",children:e})]})}a();var co=require("@mantine/core"),so=require("react/jsx-runtime"),Ct=(0,co.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 Xe({topShadowVisible:o,leftShadowVisible:e,rightShadowVisible:r,bottomShadowVisible:f,headerHeight:t,footerHeight:l,onScrollPositionChange:n,children:s,viewportRef:p,scrollAreaProps:m}){let u=l?l-1:0,{cx:C,classes:d}=Ct();return(0,so.jsxs)(co.ScrollArea,{...m,viewportRef:p,classNames:{root:d.root,scrollbar:d.scrollbar,thumb:d.thumb,corner:d.corner},styles:{scrollbar:{marginTop:t,marginBottom:u}},onScrollPositionChange:n,children:[s,(0,so.jsx)(co.Box,{className:C(d.shadow,d.topShadow,{[d.shadowVisible]:o}),sx:{top:t}}),(0,so.jsx)("div",{className:C(d.shadow,d.leftShadow,{[d.shadowVisible]:e})}),(0,so.jsx)("div",{className:C(d.shadow,d.rightShadow,{[d.shadowVisible]:r})}),(0,so.jsx)(co.Box,{className:C(d.shadow,d.bottomShadow,{[d.shadowVisible]:f}),sx:{bottom:u}})]})}var R=require("react/jsx-runtime"),Kr={},ht=(0,eo.createStyles)((o,{borderColor:e,rowBorderColor:r})=>{let f=typeof e=="function"?e(o):e,t=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:f},"tbody tr td":{borderTopColor:t}}},lastRowBorderBottomVisible:{"tbody tr:last-of-type td":{borderBottom:`1px solid ${t}`}},textSelectionDisabled:{userSelect:"none"},table:{borderCollapse:"separate",borderSpacing:0},tableWithBorder:{border:`1px solid ${f}`},tableWithColumnBorders:{"&&":{"th, td":{":not(:first-of-type)":{borderLeft:`1px solid ${t}`}}}},tableWithColumnBordersAndSelectableRecords:{thead:{"tr + tr":{th:{borderLeft:`1px solid ${t}`}}}},verticalAlignmentTop:{td:{verticalAlign:"top"}},verticalAlignmentBottom:{td:{verticalAlign:"bottom"}}}});function Qe({withBorder:o,borderRadius:e,borderColor:r=D=>D.colorScheme==="dark"?D.colors.dark[4]:D.colors.gray[3],rowBorderColor:f=D=>D.fn.rgba(D.colorScheme==="dark"?D.colors.dark[4]:D.colors.gray[3],.65),withColumnBorders:t,textSelectionDisabled:l,height:n="100%",minHeight:s,shadow:p,verticalAlignment:m="center",fetching:u,columns:C,groups:d,defaultColumnRender:h,idAccessor:I="id",records:i,selectedRecords:g,onSelectedRecordsChange:S,isRecordSelectable:b,allRecordsSelectionCheckboxProps:F={"aria-label":"Select all records"},getRecordSelectionCheckboxProps:L=(D,ro)=>({"aria-label":`Select record ${ro+1}`}),sortStatus:k,sortIcons:v,onSortStatusChange:O,horizontalSpacing:H,page:E,onPageChange:K,totalRecords:Do,recordsPerPage:yo,onRecordsPerPageChange:To,recordsPerPageOptions:ae,recordsPerPageLabel:wo="Records per page",paginationColor:Po,paginationSize:te="sm",paginationText:fe=({from:D,to:ro,totalRecords:ao})=>`${D} - ${ro} / ${ao}`,paginationWrapBreakpoint:Ho="sm",getPaginationControlProps:ne=D=>D==="previous"?{"aria-label":"Previous page"}:D==="next"?{"aria-label":"Next page"}:{},loaderBackgroundBlur:$r,customLoader:Yr,loaderSize:_r,loaderVariant:jr,loaderColor:Jr,loadingText:oa="...",emptyState:ea,noRecordsText:Ze="No records",noRecordsIcon:ra,striped:aa,noHeader:ta,onRowClick:le,onCellClick:fa,onScrollToTop:Ke,onScrollToBottom:$e,onScrollToLeft:Ye,onScrollToRight:_e,rowContextMenu:q,rowExpansion:na,rowClassName:la,rowStyle:sa,rowSx:da,customRowAttributes:ca,scrollViewportRef:ua,scrollAreaProps:pa,bodyRef:ma,m:xa,my:Ia,mx:ia,mt:ga,mb:Ca,ml:ha,mr:Sa,sx:ba,className:Ba,classNames:Eo,style:Da,styles:se,...ya}){let{ref:D,width:ro,height:ao}=(0,oo.useElementSize)(),No=(0,N.useMemo)(()=>d?.flatMap(x=>x.columns)??C,[C,d]),{ref:Ta,height:de}=(0,oo.useElementSize)(),{ref:wa,width:ce,height:Ro}=(0,oo.useElementSize)(),{ref:Pa,height:Ra}=(0,oo.useElementSize)(),{ref:ka,height:je}=(0,oo.useElementSize)(),[ue,Je]=(0,N.useState)(!0),[pe,or]=(0,N.useState)(!0),[qo,er]=(0,N.useState)(!0),[me,rr]=(0,N.useState)(!0),{rowContextMenuInfo:to,setRowContextMenuInfo:uo}=Ur(u),Ma=Vr({rowExpansion:na,records:i,idAccessor:I}),xe=(0,N.useCallback)(()=>{if(!u&&q&&uo(null),u||Ro<=ao)Je(!0),or(!0);else{let x=D.current.scrollTop,B=x===0,M=Ro-x-ao<1;Je(B),or(M),B&&B!==ue&&Ke?.(),M&&M!==pe&&$e?.()}if(u||ce===ro)er(!0),rr(!0);else{let x=D.current.scrollLeft,B=x===0,M=ce-x-ro<1;er(B),rr(M),B&&B!==qo&&Ye?.(),M&&M!==me&&_e?.()}},[u,$e,Ye,_e,Ke,q,ao,D,ro,pe,qo,me,ue,uo,Ro,ce]);Tr(xe,[xe]);let Fa=(0,N.useCallback)(x=>{D.current.scrollTo({top:0,left:0}),K(x)},[K,D]),Wo=i?.length,ar=i?.map(x=>y(x,I)),ko=!!g,Mo=g?.map(x=>y(x,I)),tr=ar!==void 0&&Mo!==void 0&&Mo.length>0,Ie=b?i?.filter(b):i,zo=Ie?.map(x=>y(x,I)),Uo=tr&&zo.every(x=>Mo.includes(x)),Oa=tr&&zo.some(x=>Mo.includes(x)),va=(0,N.useCallback)(()=>{S?.(Uo?g.filter(x=>!zo.includes(y(x,I))):io([...g,...Ie],x=>y(x,I)))},[Uo,I,S,zo,Ie,g]),{lastSelectionChangeIndex:Vo,setLastSelectionChangeIndex:Aa}=zr(ar),ie=ko&&!qo,{cx:fr,classes:V,theme:La}=ht({borderColor:r,rowBorderColor:f}),Ha={m:xa,my:Ia,mx:ia,mt:ga,mb:Ca,ml:ha,mr:Sa},Go=typeof se=="function"?se(La,Kr,Kr):se;return(0,R.jsxs)(eo.Box,{...Ha,className:fr(V.root,{[V.tableWithBorder]:o},Ba,Eo?.root),sx:[x=>({borderRadius:x.radius[e]||e,boxShadow:x.shadows[p]||p,height:n,minHeight:s}),...(0,eo.packSx)(ba)],style:{...Go?.root,...Da},children:[(0,R.jsx)(Xe,{viewportRef:(0,oo.useMergedRef)(D,ua||null),topShadowVisible:!ue,leftShadowVisible:!(g||qo),rightShadowVisible:!me,bottomShadowVisible:!pe,headerHeight:de,footerHeight:Ra,onScrollPositionChange:xe,scrollAreaProps:pa,children:(0,R.jsxs)(eo.Table,{ref:wa,horizontalSpacing:H,className:fr(V.table,{[V.tableWithColumnBorders]:t,[V.lastRowBorderBottomVisible]:Ro<ao,[V.textSelectionDisabled]:l,[V.verticalAlignmentTop]:m==="top",[V.verticalAlignmentBottom]:m==="bottom",[V.tableWithColumnBordersAndSelectableRecords]:ko&&t}),striped:Wo?aa:!1,...ya,children:[ta?null:(0,R.jsx)(Hr,{ref:Ta,className:Eo?.header,style:Go?.header,columns:No,groups:d,sortStatus:k,sortIcons:v,onSortStatusChange:O,selectionVisible:ko,selectionChecked:Uo,selectionIndeterminate:Oa&&!Uo,onSelectionChange:va,selectionCheckboxProps:F,leftShadowVisible:ie}),(0,R.jsx)("tbody",{ref:ma,children:Wo?i.map((x,B)=>{let M=y(x,I),Fo=Mo?.includes(M)||!1,Xo=!1,Qo=!1;if(q){let{hidden:w}=q;(!w||!(typeof w=="function"?w(x,B):w))&&(q.trigger==="click"?Xo=!0:Qo=!0)}let Zo;S&&(Zo=w=>{if(w.nativeEvent.shiftKey&&Vo!==null){let po=i.filter(B>Vo?(fo,no)=>no>=Vo&&no<=B&&(b?b(fo,no):!0):(fo,no)=>no>=B&&no<=Vo&&(b?b(fo,no):!0));S(Fo?Yo(g,po,fo=>y(fo,I)):io([...g,...po],fo=>y(fo,I)))}else S(Fo?g.filter(po=>y(po,I)!==M):io([...g,x],po=>y(po,I)));Aa(B)});let Oo;Xo?Oo=w=>{uo({y:w.clientY,x:w.clientX,record:x,recordIndex:B}),le?.(x,B,w)}:le&&(Oo=w=>{le(x,B,w)});let nr;return Qo&&(nr=w=>{w.preventDefault(),uo({y:w.clientY,x:w.clientX,record:x,recordIndex:B})}),(0,R.jsx)(ze,{record:x,recordIndex:B,columns:No,defaultColumnRender:h,selectionVisible:ko,selectionChecked:Fo,onSelectionChange:Zo,isRecordSelectable:b,getSelectionCheckboxProps:L,onClick:Oo,onCellClick:fa,onContextMenu:nr,contextMenuVisible:to?y(to.record,I)===M:!1,expansion:Ma,className:la,style:sa,sx:da,customRowAttributes:ca,leftShadowVisible:ie},M)}):(0,R.jsx)(he,{})}),No.some(x=>x.footer)&&(0,R.jsx)(Mr,{ref:Pa,className:Eo?.footer,style:Go?.footer,borderColor:r,columns:No,selectionVisible:ko,leftShadowVisible:ie,scrollDiff:Ro-ao})]})}),E&&(0,R.jsx)(qr,{ref:ka,className:Eo?.pagination,style:Go?.pagination,topBorderColor:r,horizontalSpacing:H,fetching:u,page:E,onPageChange:Fa,totalRecords:Do,recordsPerPage:yo,onRecordsPerPageChange:To,recordsPerPageOptions:ae,recordsPerPageLabel:wo,paginationColor:Po,paginationSize:te,paginationText:fe,paginationWrapBreakpoint:Ho,getPaginationControlProps:ne,noRecordsText:Ze,loadingText:oa,recordsLength:Wo}),(0,R.jsx)(Ae,{pt:de,pb:je,fetching:u,backgroundBlur:$r,customContent:Yr,size:_r,variant:jr,color:Jr}),(0,R.jsx)(ye,{pt:de,pb:je,icon:ra,text:Ze,active:!u&&!Wo,children:ea}),q&&to&&(0,R.jsx)(Ue,{zIndex:q.zIndex,borderRadius:q.borderRadius,shadow:q.shadow,y:to.y,x:to.x,onDestroy:()=>uo(null),children:q.items(to.record,to.recordIndex).map(({divider:x,key:B,title:M,icon:Fo,color:Xo,hidden:Qo,disabled:Zo,onClick:Oo})=>x?(0,R.jsx)(Ve,{},B):Qo?null:(0,R.jsx)(Ge,{title:M??_(B),icon:Fo,color:Xo,disabled:Zo,onClick:()=>{uo(null),Oo()}},B))})]})}a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();a();
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|