@fattureincloud/fic-design-system 0.7.32 → 0.7.33

Sign up to get free protection for your applications and to get access to all the features.
@@ -3,11 +3,11 @@ import React from 'react';
3
3
  import { RowSize, TableProps } from '../../types';
4
4
  interface TrProps<T> extends React.DetailedHTMLProps<React.HTMLAttributes<HTMLTableRowElement>, HTMLTableRowElement> {
5
5
  row: Row<T>;
6
- rowSize?: RowSize;
6
+ defaultRowSize?: RowSize;
7
7
  isLoading?: boolean;
8
8
  onRowClick?: (row: Row<T>) => void;
9
9
  isRowHighlighted: boolean;
10
10
  rowHighlightColor?: TableProps<T>['rowHighlightColor'];
11
11
  }
12
- declare const Tr: <T>({ row, isLoading, onRowClick, isRowHighlighted, rowHighlightColor }: TrProps<T>) => JSX.Element;
12
+ declare const Tr: <T>({ row, isLoading, onRowClick, isRowHighlighted, rowHighlightColor, defaultRowSize, }: TrProps<T>) => JSX.Element;
13
13
  export default Tr;
package/dist/index.esm.js CHANGED
@@ -52,5 +52,5 @@ Qp=Jp,function(){var e={}.hasOwnProperty;function n(){for(var t=[],r=0;r<argumen
52
52
  *
53
53
  * @license MIT
54
54
  */
55
- function hE(e,n){return"function"==typeof e?e(n):e}function vE(e,n){return t=>{n.setState((n=>({...n,[e]:hE(t,n[e])})))}}function bE(e){return e instanceof Function}function yE(e,n,t){let r,o=[];return()=>{let i;t.key&&t.debug&&(i=Date.now());const a=e();if(!(a.length!==o.length||a.some(((e,n)=>o[n]!==e))))return r;let l;if(o=a,t.key&&t.debug&&(l=Date.now()),r=n(...a),null==t||null==t.onChange||t.onChange(r),t.key&&t.debug&&null!=t&&t.debug()){const e=Math.round(100*(Date.now()-i))/100,n=Math.round(100*(Date.now()-l))/100,r=n/16,o=(e,n)=>{for(e=String(e);e.length<n;)e=" "+e;return e};console.info("%c⏱ "+o(n,5)+" /"+o(e,5)+" ms","\n font-size: .6rem;\n font-weight: bold;\n color: hsl("+Math.max(0,Math.min(120-120*r,120))+"deg 100% 31%);",null==t?void 0:t.key)}return r}}function xE(e,n,t){var r;let o={id:null!=(r=t.id)?r:n.id,column:n,index:t.index,isPlaceholder:!!t.isPlaceholder,placeholderId:t.placeholderId,depth:t.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const e=[],n=t=>{t.subHeaders&&t.subHeaders.length&&t.subHeaders.map(n),e.push(t)};return n(o),e},getContext:()=>({table:e,header:o,column:n})};return e._features.forEach((n=>{Object.assign(o,null==n.createHeader?void 0:n.createHeader(o,e))})),o}const wE={createTable:e=>({getHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((n,t,r,o)=>{var i,a;const l=null!=(i=null==r?void 0:r.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?i:[],s=null!=(a=null==o?void 0:o.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?a:[];return $E(n,[...l,...t.filter((e=>!(null!=r&&r.includes(e.id)||null!=o&&o.includes(e.id)))),...s],e)}),{key:"development"===process.env.NODE_ENV&&"getHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((n,t,r,o)=>$E(n,t=t.filter((e=>!(null!=r&&r.includes(e.id)||null!=o&&o.includes(e.id)))),e,"center")),{key:"development"===process.env.NODE_ENV&&"getCenterHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left]),((n,t,r)=>{var o;const i=null!=(o=null==r?void 0:r.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?o:[];return $E(n,i,e,"left")}),{key:"development"===process.env.NODE_ENV&&"getLeftHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right]),((n,t,r)=>{var o;const i=null!=(o=null==r?void 0:r.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?o:[];return $E(n,i,e,"right")}),{key:"development"===process.env.NODE_ENV&&"getRightHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getFooterGroups:yE((()=>[e.getHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftFooterGroups:yE((()=>[e.getLeftHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getLeftFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterFooterGroups:yE((()=>[e.getCenterHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getCenterFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightFooterGroups:yE((()=>[e.getRightHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getRightFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getFlatHeaders:yE((()=>[e.getHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftFlatHeaders:yE((()=>[e.getLeftHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getLeftFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterFlatHeaders:yE((()=>[e.getCenterHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getCenterFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightFlatHeaders:yE((()=>[e.getRightHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getRightFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterLeafHeaders:yE((()=>[e.getCenterFlatHeaders()]),(e=>e.filter((e=>{var n;return!(null!=(n=e.subHeaders)&&n.length)}))),{key:"development"===process.env.NODE_ENV&&"getCenterLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftLeafHeaders:yE((()=>[e.getLeftFlatHeaders()]),(e=>e.filter((e=>{var n;return!(null!=(n=e.subHeaders)&&n.length)}))),{key:"development"===process.env.NODE_ENV&&"getLeftLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightLeafHeaders:yE((()=>[e.getRightFlatHeaders()]),(e=>e.filter((e=>{var n;return!(null!=(n=e.subHeaders)&&n.length)}))),{key:"development"===process.env.NODE_ENV&&"getRightLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeafHeaders:yE((()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()]),((e,n,t)=>{var r,o,i,a,l,s;return[...null!=(r=null==(o=e[0])?void 0:o.headers)?r:[],...null!=(i=null==(a=n[0])?void 0:a.headers)?i:[],...null!=(l=null==(s=t[0])?void 0:s.headers)?l:[]].map((e=>e.getLeafHeaders())).flat()}),{key:"development"===process.env.NODE_ENV&&"getLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}})})};function $E(e,n,t,r){var o,i;let a=0;const l=function(e,n){void 0===n&&(n=1),a=Math.max(a,n),e.filter((e=>e.getIsVisible())).forEach((e=>{var t;null!=(t=e.columns)&&t.length&&l(e.columns,n+1)}),0)};l(e);let s=[];const d=(e,n)=>{const o={depth:n,id:[r,""+n].filter(Boolean).join("_"),headers:[]},i=[];e.forEach((e=>{const a=[...i].reverse()[0];let l,s=!1;if(e.column.depth===o.depth&&e.column.parent?l=e.column.parent:(l=e.column,s=!0),a&&(null==a?void 0:a.column)===l)a.subHeaders.push(e);else{const o=xE(t,l,{id:[r,n,l.id,null==e?void 0:e.id].filter(Boolean).join("_"),isPlaceholder:s,placeholderId:s?""+i.filter((e=>e.column===l)).length:void 0,depth:n,index:i.length});o.subHeaders.push(e),i.push(o)}o.headers.push(e),e.headerGroup=o})),s.push(o),n>0&&d(i,n-1)},c=n.map(((e,n)=>xE(t,e,{depth:a,index:n})));d(c,a-1),s.reverse();const u=e=>e.filter((e=>e.column.getIsVisible())).map((e=>{let n=0,t=0,r=[0];e.subHeaders&&e.subHeaders.length?(r=[],u(e.subHeaders).forEach((e=>{let{colSpan:t,rowSpan:o}=e;n+=t,r.push(o)}))):n=1;return t+=Math.min(...r),e.colSpan=n,e.rowSpan=t,{colSpan:n,rowSpan:t}}));return u(null!=(o=null==(i=s[0])?void 0:i.headers)?o:[]),s}const CE={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},kE={getDefaultColumnDef:()=>CE,getInitialState:e=>({columnSizing:{},columnSizingInfo:{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]},...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",onColumnSizingChange:vE("columnSizing",e),onColumnSizingInfoChange:vE("columnSizingInfo",e)}),createColumn:(e,n)=>({getSize:()=>{var t,r,o;const i=n.getState().columnSizing[e.id];return Math.min(Math.max(null!=(t=e.columnDef.minSize)?t:CE.minSize,null!=(r=null!=i?i:e.columnDef.size)?r:CE.size),null!=(o=e.columnDef.maxSize)?o:CE.maxSize)},getStart:t=>{const r=t?"left"===t?n.getLeftVisibleLeafColumns():n.getRightVisibleLeafColumns():n.getVisibleLeafColumns(),o=r.findIndex((n=>n.id===e.id));if(o>0){const e=r[o-1];return e.getStart(t)+e.getSize()}return 0},resetSize:()=>{n.setColumnSizing((n=>{let{[e.id]:t,...r}=n;return r}))},getCanResize:()=>{var t,r;return(null==(t=e.columnDef.enableResizing)||t)&&(null==(r=n.options.enableColumnResizing)||r)},getIsResizing:()=>n.getState().columnSizingInfo.isResizingColumn===e.id}),createHeader:(e,n)=>({getSize:()=>{let n=0;const t=e=>{var r;e.subHeaders.length?e.subHeaders.forEach(t):n+=null!=(r=e.column.getSize())?r:0};return t(e),n},getStart:()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},getResizeHandler:()=>{const t=n.getColumn(e.column.id),r=t.getCanResize();return o=>{if(!r)return;if(null==o.persist||o.persist(),EE(o)&&o.touches&&o.touches.length>1)return;const i=e.getSize(),a=e?e.getLeafHeaders().map((e=>[e.column.id,e.column.getSize()])):[[t.id,t.getSize()]],l=EE(o)?Math.round(o.touches[0].clientX):o.clientX,s=(e,t)=>{if("number"!=typeof t)return;let r={};n.setColumnSizingInfo((e=>{var n,o;const i=t-(null!=(n=null==e?void 0:e.startOffset)?n:0),a=Math.max(i/(null!=(o=null==e?void 0:e.startSize)?o:0),-.999999);return e.columnSizingStart.forEach((e=>{let[n,t]=e;r[n]=Math.round(100*Math.max(t+t*a,0))/100})),{...e,deltaOffset:i,deltaPercentage:a}})),"onChange"!==n.options.columnResizeMode&&"end"!==e||n.setColumnSizing((e=>({...e,...r})))},d={moveHandler:e=>{return n=e.clientX,s("move",n);var n},upHandler:e=>{var t;document.removeEventListener("mousemove",d.moveHandler),document.removeEventListener("mouseup",d.upHandler),t=e.clientX,s("end",t),n.setColumnSizingInfo((e=>({...e,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]})))}},c=!!function(){if("boolean"==typeof SE)return SE;let e=!1;try{const n={get passive(){return e=!0,!1}},t=()=>{};window.addEventListener("test",t,n),window.removeEventListener("test",t)}catch(n){e=!1}return SE=e,SE}()&&{passive:!1};EE(o)||(document.addEventListener("mousemove",d.moveHandler,c),document.addEventListener("mouseup",d.upHandler,c)),n.setColumnSizingInfo((e=>({...e,startOffset:l,startSize:i,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:t.id})))}}}),createTable:e=>({setColumnSizing:n=>null==e.options.onColumnSizingChange?void 0:e.options.onColumnSizingChange(n),setColumnSizingInfo:n=>null==e.options.onColumnSizingInfoChange?void 0:e.options.onColumnSizingInfoChange(n),resetColumnSizing:n=>{var t;e.setColumnSizing(n?{}:null!=(t=e.initialState.columnSizing)?t:{})},resetHeaderSizeInfo:n=>{var t;e.setColumnSizingInfo(n?{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}:null!=(t=e.initialState.columnSizingInfo)?t:{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]})},getTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0},getLeftTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getLeftHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0},getCenterTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getCenterHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0},getRightTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getRightHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0}})};let SE=null;function EE(e){return"touchstart"===e.type}const DE={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:vE("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let n=!1,t=!1;return{_autoResetExpanded:()=>{var r,o;if(n){if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetExpanded)?r:!e.options.manualExpanding){if(t)return;t=!0,e._queue((()=>{e.resetExpanded(),t=!1}))}}else e._queue((()=>{n=!0}))},setExpanded:n=>null==e.options.onExpandedChange?void 0:e.options.onExpandedChange(n),toggleAllRowsExpanded:n=>{(null!=n?n:!e.getIsAllRowsExpanded())?e.setExpanded(!0):e.setExpanded({})},resetExpanded:n=>{var t,r;e.setExpanded(n?{}:null!=(t=null==(r=e.initialState)?void 0:r.expanded)?t:{})},getCanSomeRowsExpand:()=>e.getRowModel().flatRows.some((e=>e.getCanExpand())),getToggleAllRowsExpandedHandler:()=>n=>{null==n.persist||n.persist(),e.toggleAllRowsExpanded()},getIsSomeRowsExpanded:()=>{const n=e.getState().expanded;return!0===n||Object.values(n).some(Boolean)},getIsAllRowsExpanded:()=>{const n=e.getState().expanded;return"boolean"==typeof n?!0===n:!!Object.keys(n).length&&!e.getRowModel().flatRows.some((e=>e.getIsExpanded()))},getExpandedDepth:()=>{let n=0;return(!0===e.getState().expanded?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach((e=>{const t=e.split(".");n=Math.max(n,t.length)})),n},getPreExpandedRowModel:()=>e.getSortedRowModel(),getExpandedRowModel:()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())}},createRow:(e,n)=>({toggleExpanded:t=>{n.setExpanded((r=>{var o;const i=!0===r||!(null==r||!r[e.id]);let a={};if(!0===r?Object.keys(n.getRowModel().rowsById).forEach((e=>{a[e]=!0})):a=r,t=null!=(o=t)?o:!i,!i&&t)return{...a,[e.id]:!0};if(i&&!t){const{[e.id]:n,...t}=a;return t}return r}))},getIsExpanded:()=>{var t;const r=n.getState().expanded;return!!(null!=(t=null==n.options.getIsRowExpanded?void 0:n.options.getIsRowExpanded(e))?t:!0===r||(null==r?void 0:r[e.id]))},getCanExpand:()=>{var t,r,o;return null!=(t=null==n.options.getRowCanExpand?void 0:n.options.getRowCanExpand(e))?t:(null==(r=n.options.enableExpanding)||r)&&!(null==(o=e.subRows)||!o.length)},getToggleExpandedHandler:()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}})},TE=(e,n,t)=>{var r;const o=t.toLowerCase();return null==(r=e.getValue(n))?void 0:r.toLowerCase().includes(o)};TE.autoRemove=e=>LE(e);const _E=(e,n,t)=>{var r;return null==(r=e.getValue(n))?void 0:r.includes(t)};_E.autoRemove=e=>LE(e);const NE=(e,n,t)=>{var r;return(null==(r=e.getValue(n))?void 0:r.toLowerCase())===t.toLowerCase()};NE.autoRemove=e=>LE(e);const PE=(e,n,t)=>{var r;return null==(r=e.getValue(n))?void 0:r.includes(t)};PE.autoRemove=e=>LE(e)||!(null!=e&&e.length);const ME=(e,n,t)=>!t.some((t=>{var r;return!(null!=(r=e.getValue(n))&&r.includes(t))}));ME.autoRemove=e=>LE(e)||!(null!=e&&e.length);const OE=(e,n,t)=>t.some((t=>{var r;return null==(r=e.getValue(n))?void 0:r.includes(t)}));OE.autoRemove=e=>LE(e)||!(null!=e&&e.length);const RE=(e,n,t)=>e.getValue(n)===t;RE.autoRemove=e=>LE(e);const IE=(e,n,t)=>e.getValue(n)==t;IE.autoRemove=e=>LE(e);const AE=(e,n,t)=>{let[r,o]=t;const i=e.getValue(n);return i>=r&&i<=o};AE.resolveFilterValue=e=>{let[n,t]=e,r="number"!=typeof n?parseFloat(n):n,o="number"!=typeof t?parseFloat(t):t,i=null===n||Number.isNaN(r)?-1/0:r,a=null===t||Number.isNaN(o)?1/0:o;if(i>a){const e=i;i=a,a=e}return[i,a]},AE.autoRemove=e=>LE(e)||LE(e[0])&&LE(e[1]);const FE={includesString:TE,includesStringSensitive:_E,equalsString:NE,arrIncludes:PE,arrIncludesAll:ME,arrIncludesSome:OE,equals:RE,weakEquals:IE,inNumberRange:AE};function LE(e){return null==e||""===e}const zE={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],globalFilter:void 0,...e}),getDefaultOptions:e=>({onColumnFiltersChange:vE("columnFilters",e),onGlobalFilterChange:vE("globalFilter",e),filterFromLeafRows:!1,globalFilterFn:"auto",getColumnCanGlobalFilter:n=>{var t,r;const o=null==(t=e.getCoreRowModel().flatRows[0])||null==(r=t._getAllCellsByColumnId()[n.id])?void 0:r.getValue();return"string"==typeof o||"number"==typeof o}}),createColumn:(e,n)=>({getAutoFilterFn:()=>{const t=n.getCoreRowModel().flatRows[0],r=null==t?void 0:t.getValue(e.id);return"string"==typeof r?FE.includesString:"number"==typeof r?FE.inNumberRange:"boolean"==typeof r||null!==r&&"object"==typeof r?FE.equals:Array.isArray(r)?FE.arrIncludes:FE.weakEquals},getFilterFn:()=>{var t,r;return bE(e.columnDef.filterFn)?e.columnDef.filterFn:"auto"===e.columnDef.filterFn?e.getAutoFilterFn():null!=(t=null==(r=n.options.filterFns)?void 0:r[e.columnDef.filterFn])?t:FE[e.columnDef.filterFn]},getCanFilter:()=>{var t,r,o;return(null==(t=e.columnDef.enableColumnFilter)||t)&&(null==(r=n.options.enableColumnFilters)||r)&&(null==(o=n.options.enableFilters)||o)&&!!e.accessorFn},getCanGlobalFilter:()=>{var t,r,o,i;return(null==(t=e.columnDef.enableGlobalFilter)||t)&&(null==(r=n.options.enableGlobalFilter)||r)&&(null==(o=n.options.enableFilters)||o)&&(null==(i=null==n.options.getColumnCanGlobalFilter?void 0:n.options.getColumnCanGlobalFilter(e))||i)&&!!e.accessorFn},getIsFiltered:()=>e.getFilterIndex()>-1,getFilterValue:()=>{var t,r;return null==(t=n.getState().columnFilters)||null==(r=t.find((n=>n.id===e.id)))?void 0:r.value},getFilterIndex:()=>{var t,r;return null!=(t=null==(r=n.getState().columnFilters)?void 0:r.findIndex((n=>n.id===e.id)))?t:-1},setFilterValue:t=>{n.setColumnFilters((n=>{const r=e.getFilterFn(),o=null==n?void 0:n.find((n=>n.id===e.id)),i=hE(t,o?o.value:void 0);var a;if(HE(r,i,e))return null!=(a=null==n?void 0:n.filter((n=>n.id!==e.id)))?a:[];const l={id:e.id,value:i};var s;return o?null!=(s=null==n?void 0:n.map((n=>n.id===e.id?l:n)))?s:[]:null!=n&&n.length?[...n,l]:[l]}))},_getFacetedRowModel:n.options.getFacetedRowModel&&n.options.getFacetedRowModel(n,e.id),getFacetedRowModel:()=>e._getFacetedRowModel?e._getFacetedRowModel():n.getPreFilteredRowModel(),_getFacetedUniqueValues:n.options.getFacetedUniqueValues&&n.options.getFacetedUniqueValues(n,e.id),getFacetedUniqueValues:()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,_getFacetedMinMaxValues:n.options.getFacetedMinMaxValues&&n.options.getFacetedMinMaxValues(n,e.id),getFacetedMinMaxValues:()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}),createRow:(e,n)=>({columnFilters:{},columnFiltersMeta:{}}),createTable:e=>({getGlobalAutoFilterFn:()=>FE.includesString,getGlobalFilterFn:()=>{var n,t;const{globalFilterFn:r}=e.options;return bE(r)?r:"auto"===r?e.getGlobalAutoFilterFn():null!=(n=null==(t=e.options.filterFns)?void 0:t[r])?n:FE[r]},setColumnFilters:n=>{const t=e.getAllLeafColumns();null==e.options.onColumnFiltersChange||e.options.onColumnFiltersChange((e=>{var r;return null==(r=hE(n,e))?void 0:r.filter((e=>{const n=t.find((n=>n.id===e.id));if(n){if(HE(n.getFilterFn(),e.value,n))return!1}return!0}))}))},setGlobalFilter:n=>{null==e.options.onGlobalFilterChange||e.options.onGlobalFilterChange(n)},resetGlobalFilter:n=>{e.setGlobalFilter(n?void 0:e.initialState.globalFilter)},resetColumnFilters:n=>{var t,r;e.setColumnFilters(n?[]:null!=(t=null==(r=e.initialState)?void 0:r.columnFilters)?t:[])},getPreFilteredRowModel:()=>e.getCoreRowModel(),getFilteredRowModel:()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel()),_getGlobalFacetedRowModel:e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),getGlobalFacetedRowModel:()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),_getGlobalFacetedUniqueValues:e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),getGlobalFacetedUniqueValues:()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,_getGlobalFacetedMinMaxValues:e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),getGlobalFacetedMinMaxValues:()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}})};function HE(e,n,t){return!(!e||!e.autoRemove)&&e.autoRemove(n,t)||void 0===n||"string"==typeof n&&!n}const jE={sum:(e,n,t)=>t.reduce(((n,t)=>{const r=t.getValue(e);return n+("number"==typeof r?r:0)}),0),min:(e,n,t)=>{let r;return t.forEach((n=>{const t=n.getValue(e);null!=t&&(r>t||void 0===r&&t>=t)&&(r=t)})),r},max:(e,n,t)=>{let r;return t.forEach((n=>{const t=n.getValue(e);null!=t&&(r<t||void 0===r&&t>=t)&&(r=t)})),r},extent:(e,n,t)=>{let r,o;return t.forEach((n=>{const t=n.getValue(e);null!=t&&(void 0===r?t>=t&&(r=o=t):(r>t&&(r=t),o<t&&(o=t)))})),[r,o]},mean:(e,n)=>{let t=0,r=0;if(n.forEach((n=>{let o=n.getValue(e);null!=o&&(o=+o)>=o&&(++t,r+=o)})),t)return r/t},median:(e,n)=>{if(!n.length)return;let t=0,r=0;return n.forEach((n=>{let o=n.getValue(e);"number"==typeof o&&(t=Math.min(t,o),r=Math.max(r,o))})),(t+r)/2},unique:(e,n)=>Array.from(new Set(n.map((n=>n.getValue(e)))).values()),uniqueCount:(e,n)=>new Set(n.map((n=>n.getValue(e)))).size,count:(e,n)=>n.length},BE={getDefaultColumnDef:()=>({aggregatedCell:e=>{var n,t;return null!=(n=null==(t=e.getValue())||null==t.toString?void 0:t.toString())?n:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:vE("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,n)=>({toggleGrouping:()=>{n.setGrouping((n=>null!=n&&n.includes(e.id)?n.filter((n=>n!==e.id)):[...null!=n?n:[],e.id]))},getCanGroup:()=>{var t,r,o,i;return null!=(t=null==(r=null!=(o=null==(i=e.columnDef.enableGrouping)||i)?o:n.options.enableGrouping)||r)?t:!!e.accessorFn},getIsGrouped:()=>{var t;return null==(t=n.getState().grouping)?void 0:t.includes(e.id)},getGroupedIndex:()=>{var t;return null==(t=n.getState().grouping)?void 0:t.indexOf(e.id)},getToggleGroupingHandler:()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},getAutoAggregationFn:()=>{const t=n.getCoreRowModel().flatRows[0],r=null==t?void 0:t.getValue(e.id);return"number"==typeof r?jE.sum:"[object Date]"===Object.prototype.toString.call(r)?jE.extent:void 0},getAggregationFn:()=>{var t,r;if(!e)throw new Error;return bE(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:"auto"===e.columnDef.aggregationFn?e.getAutoAggregationFn():null!=(t=null==(r=n.options.aggregationFns)?void 0:r[e.columnDef.aggregationFn])?t:jE[e.columnDef.aggregationFn]}}),createTable:e=>({setGrouping:n=>null==e.options.onGroupingChange?void 0:e.options.onGroupingChange(n),resetGrouping:n=>{var t,r;e.setGrouping(n?[]:null!=(t=null==(r=e.initialState)?void 0:r.grouping)?t:[])},getPreGroupedRowModel:()=>e.getFilteredRowModel(),getGroupedRowModel:()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())}),createRow:e=>({getIsGrouped:()=>!!e.groupingColumnId,_groupingValuesCache:{}}),createCell:(e,n,t,r)=>({getIsGrouped:()=>n.getIsGrouped()&&n.id===t.groupingColumnId,getIsPlaceholder:()=>!e.getIsGrouped()&&n.getIsGrouped(),getIsAggregated:()=>{var n;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!(null==(n=t.subRows)||!n.length)}})};const UE={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:vE("columnOrder",e)}),createTable:e=>({setColumnOrder:n=>null==e.options.onColumnOrderChange?void 0:e.options.onColumnOrderChange(n),resetColumnOrder:n=>{var t;e.setColumnOrder(n?[]:null!=(t=e.initialState.columnOrder)?t:[])},_getOrderColumnsFn:yE((()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode]),((e,n,t)=>r=>{let o=[];if(null!=e&&e.length){const n=[...e],t=[...r];for(;t.length&&n.length;){const e=n.shift(),r=t.findIndex((n=>n.id===e));r>-1&&o.push(t.splice(r,1)[0])}o=[...o,...t]}else o=r;return function(e,n,t){if(null==n||!n.length||!t)return e;const r=e.filter((e=>!n.includes(e.id)));if("remove"===t)return r;const o=n.map((n=>e.find((e=>e.id===n)))).filter(Boolean);return[...o,...r]}(o,n,t)}),{key:"development"===process.env.NODE_ENV&&"getOrderColumnsFn"})})},YE={getInitialState:e=>({columnPinning:{left:[],right:[]},...e}),getDefaultOptions:e=>({onColumnPinningChange:vE("columnPinning",e)}),createColumn:(e,n)=>({pin:t=>{const r=e.getLeafColumns().map((e=>e.id)).filter(Boolean);n.setColumnPinning((e=>{var n,o,i,a,l,s;return"right"===t?{left:(null!=(i=null==e?void 0:e.left)?i:[]).filter((e=>!(null!=r&&r.includes(e)))),right:[...(null!=(a=null==e?void 0:e.right)?a:[]).filter((e=>!(null!=r&&r.includes(e)))),...r]}:"left"===t?{left:[...(null!=(l=null==e?void 0:e.left)?l:[]).filter((e=>!(null!=r&&r.includes(e)))),...r],right:(null!=(s=null==e?void 0:e.right)?s:[]).filter((e=>!(null!=r&&r.includes(e))))}:{left:(null!=(n=null==e?void 0:e.left)?n:[]).filter((e=>!(null!=r&&r.includes(e)))),right:(null!=(o=null==e?void 0:e.right)?o:[]).filter((e=>!(null!=r&&r.includes(e))))}}))},getCanPin:()=>e.getLeafColumns().some((e=>{var t,r;return(null==(t=e.columnDef.enablePinning)||t)&&(null==(r=n.options.enablePinning)||r)})),getIsPinned:()=>{const t=e.getLeafColumns().map((e=>e.id)),{left:r,right:o}=n.getState().columnPinning,i=t.some((e=>null==r?void 0:r.includes(e))),a=t.some((e=>null==o?void 0:o.includes(e)));return i?"left":!!a&&"right"},getPinnedIndex:()=>{var t,r,o;const i=e.getIsPinned();return i?null!=(t=null==(r=n.getState().columnPinning)||null==(o=r[i])?void 0:o.indexOf(e.id))?t:-1:0}}),createRow:(e,n)=>({getCenterVisibleCells:yE((()=>[e._getAllVisibleCells(),n.getState().columnPinning.left,n.getState().columnPinning.right]),((e,n,t)=>{const r=[...null!=n?n:[],...null!=t?t:[]];return e.filter((e=>!r.includes(e.column.id)))}),{key:"production"===process.env.NODE_ENV&&"row.getCenterVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}}),getLeftVisibleCells:yE((()=>[e._getAllVisibleCells(),n.getState().columnPinning.left,,]),((e,n)=>{const t=(null!=n?n:[]).map((n=>e.find((e=>e.column.id===n)))).filter(Boolean).map((e=>({...e,position:"left"})));return t}),{key:"production"===process.env.NODE_ENV&&"row.getLeftVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}}),getRightVisibleCells:yE((()=>[e._getAllVisibleCells(),n.getState().columnPinning.right]),((e,n)=>{const t=(null!=n?n:[]).map((n=>e.find((e=>e.column.id===n)))).filter(Boolean).map((e=>({...e,position:"right"})));return t}),{key:"production"===process.env.NODE_ENV&&"row.getRightVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}})}),createTable:e=>({setColumnPinning:n=>null==e.options.onColumnPinningChange?void 0:e.options.onColumnPinningChange(n),resetColumnPinning:n=>{var t,r;return e.setColumnPinning(n?{left:[],right:[]}:null!=(t=null==(r=e.initialState)?void 0:r.columnPinning)?t:{left:[],right:[]})},getIsSomeColumnsPinned:n=>{var t;const r=e.getState().columnPinning;var o,i;return n?Boolean(null==(t=r[n])?void 0:t.length):Boolean((null==(o=r.left)?void 0:o.length)||(null==(i=r.right)?void 0:i.length))},getLeftLeafColumns:yE((()=>[e.getAllLeafColumns(),e.getState().columnPinning.left]),((e,n)=>(null!=n?n:[]).map((n=>e.find((e=>e.id===n)))).filter(Boolean)),{key:"development"===process.env.NODE_ENV&&"getLeftLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}}),getRightLeafColumns:yE((()=>[e.getAllLeafColumns(),e.getState().columnPinning.right]),((e,n)=>(null!=n?n:[]).map((n=>e.find((e=>e.id===n)))).filter(Boolean)),{key:"development"===process.env.NODE_ENV&&"getRightLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}}),getCenterLeafColumns:yE((()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((e,n,t)=>{const r=[...null!=n?n:[],...null!=t?t:[]];return e.filter((e=>!r.includes(e.id)))}),{key:"development"===process.env.NODE_ENV&&"getCenterLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}})})},VE={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:vE("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>({setRowSelection:n=>null==e.options.onRowSelectionChange?void 0:e.options.onRowSelectionChange(n),resetRowSelection:n=>{var t;return e.setRowSelection(n?{}:null!=(t=e.initialState.rowSelection)?t:{})},toggleAllRowsSelected:n=>{e.setRowSelection((t=>{n=void 0!==n?n:!e.getIsAllRowsSelected();const r={...t},o=e.getPreGroupedRowModel().flatRows;return n?o.forEach((e=>{e.getCanSelect()&&(r[e.id]=!0)})):o.forEach((e=>{delete r[e.id]})),r}))},toggleAllPageRowsSelected:n=>e.setRowSelection((t=>{const r=void 0!==n?n:!e.getIsAllPageRowsSelected(),o={...t};return e.getRowModel().rows.forEach((n=>{WE(o,n.id,r,e)})),o})),getPreSelectedRowModel:()=>e.getCoreRowModel(),getSelectedRowModel:yE((()=>[e.getState().rowSelection,e.getCoreRowModel()]),((n,t)=>Object.keys(n).length?GE(e,t):{rows:[],flatRows:[],rowsById:{}}),{key:"development"===process.env.NODE_ENV&&"getSelectedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getFilteredSelectedRowModel:yE((()=>[e.getState().rowSelection,e.getFilteredRowModel()]),((n,t)=>Object.keys(n).length?GE(e,t):{rows:[],flatRows:[],rowsById:{}}),{key:"production"===process.env.NODE_ENV&&"getFilteredSelectedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getGroupedSelectedRowModel:yE((()=>[e.getState().rowSelection,e.getSortedRowModel()]),((n,t)=>Object.keys(n).length?GE(e,t):{rows:[],flatRows:[],rowsById:{}}),{key:"production"===process.env.NODE_ENV&&"getGroupedSelectedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getIsAllRowsSelected:()=>{const n=e.getFilteredRowModel().flatRows,{rowSelection:t}=e.getState();let r=Boolean(n.length&&Object.keys(t).length);return r&&n.some((e=>e.getCanSelect()&&!t[e.id]))&&(r=!1),r},getIsAllPageRowsSelected:()=>{const n=e.getPaginationRowModel().flatRows,{rowSelection:t}=e.getState();let r=!!n.length;return r&&n.some((e=>!t[e.id]))&&(r=!1),r},getIsSomeRowsSelected:()=>{var n;const t=Object.keys(null!=(n=e.getState().rowSelection)?n:{}).length;return t>0&&t<e.getFilteredRowModel().flatRows.length},getIsSomePageRowsSelected:()=>{const n=e.getPaginationRowModel().flatRows;return!e.getIsAllPageRowsSelected()&&n.some((e=>e.getIsSelected()||e.getIsSomeSelected()))},getToggleAllRowsSelectedHandler:()=>n=>{e.toggleAllRowsSelected(n.target.checked)},getToggleAllPageRowsSelectedHandler:()=>n=>{e.toggleAllPageRowsSelected(n.target.checked)}}),createRow:(e,n)=>({toggleSelected:t=>{const r=e.getIsSelected();n.setRowSelection((o=>{if(r===(t=void 0!==t?t:!r))return o;const i={...o};return WE(i,e.id,t,n),i}))},getIsSelected:()=>{const{rowSelection:t}=n.getState();return KE(e,t)},getIsSomeSelected:()=>{const{rowSelection:t}=n.getState();return"some"===qE(e,t)},getIsAllSubRowsSelected:()=>{const{rowSelection:t}=n.getState();return"all"===qE(e,t)},getCanSelect:()=>{var t;return"function"==typeof n.options.enableRowSelection?n.options.enableRowSelection(e):null==(t=n.options.enableRowSelection)||t},getCanSelectSubRows:()=>{var t;return"function"==typeof n.options.enableSubRowSelection?n.options.enableSubRowSelection(e):null==(t=n.options.enableSubRowSelection)||t},getCanMultiSelect:()=>{var t;return"function"==typeof n.options.enableMultiRowSelection?n.options.enableMultiRowSelection(e):null==(t=n.options.enableMultiRowSelection)||t},getToggleSelectedHandler:()=>{const n=e.getCanSelect();return t=>{var r;n&&e.toggleSelected(null==(r=t.target)?void 0:r.checked)}}})},WE=(e,n,t,r)=>{var o;const i=r.getRow(n);t?(i.getCanMultiSelect()||Object.keys(e).forEach((n=>delete e[n])),i.getCanSelect()&&(e[n]=!0)):delete e[n],null!=(o=i.subRows)&&o.length&&i.getCanSelectSubRows()&&i.subRows.forEach((n=>WE(e,n.id,t,r)))};function GE(e,n){const t=e.getState().rowSelection,r=[],o={},i=function(e,n){return e.map((e=>{var n;const a=KE(e,t);if(a&&(r.push(e),o[e.id]=e),null!=(n=e.subRows)&&n.length&&(e={...e,subRows:i(e.subRows)}),a)return e})).filter(Boolean)};return{rows:i(n.rows),flatRows:r,rowsById:o}}function KE(e,n){var t;return null!=(t=n[e.id])&&t}function qE(e,n,t){if(e.subRows&&e.subRows.length){let t=!0,r=!1;return e.subRows.forEach((e=>{r&&!t||(KE(e,n)?r=!0:t=!1)})),t?"all":!!r&&"some"}return!1}const XE=/([0-9]+)/gm;function QE(e,n){return e===n?0:e>n?1:-1}function ZE(e){return"number"==typeof e?isNaN(e)||e===1/0||e===-1/0?"":String(e):"string"==typeof e?e:""}function JE(e,n){const t=e.split(XE).filter(Boolean),r=n.split(XE).filter(Boolean);for(;t.length&&r.length;){const e=t.shift(),n=r.shift(),o=parseInt(e,10),i=parseInt(n,10),a=[o,i].sort();if(isNaN(a[0])){if(e>n)return 1;if(n>e)return-1}else{if(isNaN(a[1]))return isNaN(o)?-1:1;if(o>i)return 1;if(i>o)return-1}}return t.length-r.length}const eD={alphanumeric:(e,n,t)=>JE(ZE(e.getValue(t)).toLowerCase(),ZE(n.getValue(t)).toLowerCase()),alphanumericCaseSensitive:(e,n,t)=>JE(ZE(e.getValue(t)),ZE(n.getValue(t))),text:(e,n,t)=>QE(ZE(e.getValue(t)).toLowerCase(),ZE(n.getValue(t)).toLowerCase()),textCaseSensitive:(e,n,t)=>QE(ZE(e.getValue(t)),ZE(n.getValue(t))),datetime:(e,n,t)=>{const r=e.getValue(t),o=n.getValue(t);return r>o?1:r<o?-1:0},basic:(e,n,t)=>QE(e.getValue(t),n.getValue(t))},nD={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto"}),getDefaultOptions:e=>({onSortingChange:vE("sorting",e),isMultiSortEvent:e=>e.shiftKey}),createColumn:(e,n)=>({getAutoSortingFn:()=>{const t=n.getFilteredRowModel().flatRows.slice(10);let r=!1;for(const n of t){const t=null==n?void 0:n.getValue(e.id);if("[object Date]"===Object.prototype.toString.call(t))return eD.datetime;if("string"==typeof t&&(r=!0,t.split(XE).length>1))return eD.alphanumeric}return r?eD.text:eD.basic},getAutoSortDir:()=>{const t=n.getFilteredRowModel().flatRows[0];return"string"==typeof(null==t?void 0:t.getValue(e.id))?"asc":"desc"},getSortingFn:()=>{var t,r;if(!e)throw new Error;return bE(e.columnDef.sortingFn)?e.columnDef.sortingFn:"auto"===e.columnDef.sortingFn?e.getAutoSortingFn():null!=(t=null==(r=n.options.sortingFns)?void 0:r[e.columnDef.sortingFn])?t:eD[e.columnDef.sortingFn]},toggleSorting:(t,r)=>{const o=e.getNextSortingOrder(),i=null!=t;n.setSorting((a=>{const l=null==a?void 0:a.find((n=>n.id===e.id)),s=null==a?void 0:a.findIndex((n=>n.id===e.id));let d,c=[],u=i?t:"desc"===o;var p;(d=null!=a&&a.length&&e.getCanMultiSort()&&r?l?"toggle":"add":null!=a&&a.length&&s!==a.length-1?"replace":l?"toggle":"replace","toggle"===d&&(i||o||(d="remove")),"add"===d)?(c=[...a,{id:e.id,desc:u}],c.splice(0,c.length-(null!=(p=n.options.maxMultiSortColCount)?p:Number.MAX_SAFE_INTEGER))):c="toggle"===d?a.map((n=>n.id===e.id?{...n,desc:u}:n)):"remove"===d?a.filter((n=>n.id!==e.id)):[{id:e.id,desc:u}];return c}))},getFirstSortDir:()=>{var t,r;return(null!=(t=null!=(r=e.columnDef.sortDescFirst)?r:n.options.sortDescFirst)?t:"desc"===e.getAutoSortDir())?"desc":"asc"},getNextSortingOrder:t=>{var r,o;const i=e.getFirstSortDir(),a=e.getIsSorted();return a?!!(a===i||null!=(r=n.options.enableSortingRemoval)&&!r||t&&null!=(o=n.options.enableMultiRemove)&&!o)&&("desc"===a?"asc":"desc"):i},getCanSort:()=>{var t,r;return(null==(t=e.columnDef.enableSorting)||t)&&(null==(r=n.options.enableSorting)||r)&&!!e.accessorFn},getCanMultiSort:()=>{var t,r;return null!=(t=null!=(r=e.columnDef.enableMultiSort)?r:n.options.enableMultiSort)?t:!!e.accessorFn},getIsSorted:()=>{var t;const r=null==(t=n.getState().sorting)?void 0:t.find((n=>n.id===e.id));return!!r&&(r.desc?"desc":"asc")},getSortIndex:()=>{var t,r;return null!=(t=null==(r=n.getState().sorting)?void 0:r.findIndex((n=>n.id===e.id)))?t:-1},clearSorting:()=>{n.setSorting((n=>null!=n&&n.length?n.filter((n=>n.id!==e.id)):[]))},getToggleSortingHandler:()=>{const t=e.getCanSort();return r=>{t&&(null==r.persist||r.persist(),null==e.toggleSorting||e.toggleSorting(void 0,!!e.getCanMultiSort()&&(null==n.options.isMultiSortEvent?void 0:n.options.isMultiSortEvent(r))))}}}),createTable:e=>({setSorting:n=>null==e.options.onSortingChange?void 0:e.options.onSortingChange(n),resetSorting:n=>{var t,r;e.setSorting(n?[]:null!=(t=null==(r=e.initialState)?void 0:r.sorting)?t:[])},getPreSortedRowModel:()=>e.getGroupedRowModel(),getSortedRowModel:()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())})},tD={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:vE("columnVisibility",e)}),createColumn:(e,n)=>({toggleVisibility:t=>{e.getCanHide()&&n.setColumnVisibility((n=>({...n,[e.id]:null!=t?t:!e.getIsVisible()})))},getIsVisible:()=>{var t,r;return null==(t=null==(r=n.getState().columnVisibility)?void 0:r[e.id])||t},getCanHide:()=>{var t,r;return(null==(t=e.columnDef.enableHiding)||t)&&(null==(r=n.options.enableHiding)||r)},getToggleVisibilityHandler:()=>n=>{null==e.toggleVisibility||e.toggleVisibility(n.target.checked)}}),createRow:(e,n)=>({_getAllVisibleCells:yE((()=>[e.getAllCells(),n.getState().columnVisibility]),(e=>e.filter((e=>e.column.getIsVisible()))),{key:"production"===process.env.NODE_ENV&&"row._getAllVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}}),getVisibleCells:yE((()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()]),((e,n,t)=>[...e,...n,...t]),{key:"development"===process.env.NODE_ENV&&"row.getVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}})}),createTable:e=>{const n=(n,t)=>yE((()=>[t(),t().filter((e=>e.getIsVisible())).map((e=>e.id)).join("_")]),(e=>e.filter((e=>null==e.getIsVisible?void 0:e.getIsVisible()))),{key:n,debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}});return{getVisibleFlatColumns:n("getVisibleFlatColumns",(()=>e.getAllFlatColumns())),getVisibleLeafColumns:n("getVisibleLeafColumns",(()=>e.getAllLeafColumns())),getLeftVisibleLeafColumns:n("getLeftVisibleLeafColumns",(()=>e.getLeftLeafColumns())),getRightVisibleLeafColumns:n("getRightVisibleLeafColumns",(()=>e.getRightLeafColumns())),getCenterVisibleLeafColumns:n("getCenterVisibleLeafColumns",(()=>e.getCenterLeafColumns())),setColumnVisibility:n=>null==e.options.onColumnVisibilityChange?void 0:e.options.onColumnVisibilityChange(n),resetColumnVisibility:n=>{var t;e.setColumnVisibility(n?{}:null!=(t=e.initialState.columnVisibility)?t:{})},toggleAllColumnsVisible:n=>{var t;n=null!=(t=n)?t:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce(((e,t)=>({...e,[t.id]:n||!(null!=t.getCanHide&&t.getCanHide())})),{}))},getIsAllColumnsVisible:()=>!e.getAllLeafColumns().some((e=>!(null!=e.getIsVisible&&e.getIsVisible()))),getIsSomeColumnsVisible:()=>e.getAllLeafColumns().some((e=>null==e.getIsVisible?void 0:e.getIsVisible())),getToggleAllColumnsVisibilityHandler:()=>n=>{var t;e.toggleAllColumnsVisible(null==(t=n.target)?void 0:t.checked)}}}},rD=[wE,tD,UE,YE,zE,nD,BE,DE,{getInitialState:e=>({...e,pagination:{pageIndex:0,pageSize:10,...null==e?void 0:e.pagination}}),getDefaultOptions:e=>({onPaginationChange:vE("pagination",e)}),createTable:e=>{let n=!1,t=!1;return{_autoResetPageIndex:()=>{var r,o;if(n){if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetPageIndex)?r:!e.options.manualPagination){if(t)return;t=!0,e._queue((()=>{e.resetPageIndex(),t=!1}))}}else e._queue((()=>{n=!0}))},setPagination:n=>null==e.options.onPaginationChange?void 0:e.options.onPaginationChange((e=>hE(n,e))),resetPagination:n=>{var t;e.setPagination(n?{pageIndex:0,pageSize:10}:null!=(t=e.initialState.pagination)?t:{pageIndex:0,pageSize:10})},setPageIndex:n=>{e.setPagination((t=>{let r=hE(n,t.pageIndex);const o=void 0===e.options.pageCount||-1===e.options.pageCount?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return r=Math.min(Math.max(0,r),o),{...t,pageIndex:r}}))},resetPageIndex:n=>{var t,r,o;e.setPageIndex(n?0:null!=(t=null==(r=e.initialState)||null==(o=r.pagination)?void 0:o.pageIndex)?t:0)},resetPageSize:n=>{var t,r,o;e.setPageSize(n?10:null!=(t=null==(r=e.initialState)||null==(o=r.pagination)?void 0:o.pageSize)?t:10)},setPageSize:n=>{e.setPagination((e=>{const t=Math.max(1,hE(n,e.pageSize)),r=e.pageSize*e.pageIndex,o=Math.floor(r/t);return{...e,pageIndex:o,pageSize:t}}))},setPageCount:n=>e.setPagination((t=>{var r;let o=hE(n,null!=(r=e.options.pageCount)?r:-1);return"number"==typeof o&&(o=Math.max(-1,o)),{...t,pageCount:o}})),getPageOptions:yE((()=>[e.getPageCount()]),(e=>{let n=[];return e&&e>0&&(n=[...new Array(e)].fill(null).map(((e,n)=>n))),n}),{key:"development"===process.env.NODE_ENV&&"getPageOptions",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getCanPreviousPage:()=>e.getState().pagination.pageIndex>0,getCanNextPage:()=>{const{pageIndex:n}=e.getState().pagination,t=e.getPageCount();return-1===t||0!==t&&n<t-1},previousPage:()=>e.setPageIndex((e=>e-1)),nextPage:()=>e.setPageIndex((e=>e+1)),getPrePaginationRowModel:()=>e.getExpandedRowModel(),getPaginationRowModel:()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),getPageCount:()=>{var n;return null!=(n=e.options.pageCount)?n:Math.ceil(e.getPrePaginationRowModel().rows.length/e.getState().pagination.pageSize)}}}},VE,kE];function oD(e){var n;(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");let t={_features:rD};const r=t._features.reduce(((e,n)=>Object.assign(e,null==n.getDefaultOptions?void 0:n.getDefaultOptions(t))),{});let o={...null!=(n=e.initialState)?n:{}};t._features.forEach((e=>{var n;o=null!=(n=null==e.getInitialState?void 0:e.getInitialState(o))?n:o}));const i=[];let a=!1;const l={_features:rD,options:{...r,...e},initialState:o,_queue:e=>{i.push(e),a||(a=!0,Promise.resolve().then((()=>{for(;i.length;)i.shift()();a=!1})).catch((e=>setTimeout((()=>{throw e})))))},reset:()=>{t.setState(t.initialState)},setOptions:e=>{const n=hE(e,t.options);t.options=(e=>t.options.mergeOptions?t.options.mergeOptions(r,e):{...r,...e})(n)},getState:()=>t.options.state,setState:e=>{null==t.options.onStateChange||t.options.onStateChange(e)},_getRowId:(e,n,r)=>{var o;return null!=(o=null==t.options.getRowId?void 0:t.options.getRowId(e,n,r))?o:""+(r?[r.id,n].join("."):n)},getCoreRowModel:()=>(t._getCoreRowModel||(t._getCoreRowModel=t.options.getCoreRowModel(t)),t._getCoreRowModel()),getRowModel:()=>t.getPaginationRowModel(),getRow:e=>{const n=t.getRowModel().rowsById[e];if(!n){if("production"!==process.env.NODE_ENV)throw new Error("getRow expected an ID, but got "+e);throw new Error}return n},_getDefaultColumnDef:yE((()=>[t.options.defaultColumn]),(e=>{var n;return e=null!=(n=e)?n:{},{header:e=>{const n=e.header.column.columnDef;return n.accessorKey?n.accessorKey:n.accessorFn?n.id:null},cell:e=>{var n,t;return null!=(n=null==(t=e.renderValue())||null==t.toString?void 0:t.toString())?n:null},...t._features.reduce(((e,n)=>Object.assign(e,null==n.getDefaultColumnDef?void 0:n.getDefaultColumnDef())),{}),...e}}),{debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns},key:"development"===process.env.NODE_ENV&&"getDefaultColumnDef"}),_getColumnDefs:()=>t.options.columns,getAllColumns:yE((()=>[t._getColumnDefs()]),(e=>{const n=function(e,r,o){return void 0===o&&(o=0),e.map((e=>{const i=function(e,n,t,r){var o,i;const a={...e._getDefaultColumnDef(),...n},l=a.accessorKey;let s,d=null!=(o=null!=(i=a.id)?i:l?l.replace(".","_"):void 0)?o:"string"==typeof a.header?a.header:void 0;if(a.accessorFn?s=a.accessorFn:l&&(s=l.includes(".")?e=>{let n=e;for(const e of l.split("."))n=n[e];return n}:e=>e[a.accessorKey]),!d){if("production"!==process.env.NODE_ENV)throw new Error(a.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header");throw new Error}let c={id:""+String(d),accessorFn:s,parent:r,depth:t,columnDef:a,columns:[],getFlatColumns:yE((()=>[!0]),(()=>{var e;return[c,...null==(e=c.columns)?void 0:e.flatMap((e=>e.getFlatColumns()))]}),{key:"production"===process.env.NODE_ENV&&"column.getFlatColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}}),getLeafColumns:yE((()=>[e._getOrderColumnsFn()]),(e=>{var n;if(null!=(n=c.columns)&&n.length){let n=c.columns.flatMap((e=>e.getLeafColumns()));return e(n)}return[c]}),{key:"production"===process.env.NODE_ENV&&"column.getLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}})};return c=e._features.reduce(((n,t)=>Object.assign(n,null==t.createColumn?void 0:t.createColumn(c,e))),c),c}(t,e,o,r),a=e;return i.columns=a.columns?n(a.columns,i,o+1):[],i}))};return n(e)}),{key:"development"===process.env.NODE_ENV&&"getAllColumns",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),getAllFlatColumns:yE((()=>[t.getAllColumns()]),(e=>e.flatMap((e=>e.getFlatColumns()))),{key:"development"===process.env.NODE_ENV&&"getAllFlatColumns",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),_getAllFlatColumnsById:yE((()=>[t.getAllFlatColumns()]),(e=>e.reduce(((e,n)=>(e[n.id]=n,e)),{})),{key:"development"===process.env.NODE_ENV&&"getAllFlatColumnsById",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),getAllLeafColumns:yE((()=>[t.getAllColumns(),t._getOrderColumnsFn()]),((e,n)=>n(e.flatMap((e=>e.getLeafColumns())))),{key:"development"===process.env.NODE_ENV&&"getAllLeafColumns",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),getColumn:e=>{const n=t._getAllFlatColumnsById()[e];if(!n)throw"production"!==process.env.NODE_ENV&&console.warn("[Table] Column with id "+e+" does not exist."),new Error;return n}};return Object.assign(t,l),t._features.forEach((e=>Object.assign(t,null==e.createTable?void 0:e.createTable(t)))),t}const iD=(e,n,t,r,o,i)=>{let a={id:n,index:r,original:t,depth:o,_valuesCache:{},getValue:n=>{if(a._valuesCache.hasOwnProperty(n))return a._valuesCache[n];const t=e.getColumn(n);return t.accessorFn?(a._valuesCache[n]=t.accessorFn(a.original,r),a._valuesCache[n]):void 0},renderValue:n=>{var t;return null!=(t=a.getValue(n))?t:e.options.renderFallbackValue},subRows:null!=i?i:[],getLeafRows:()=>function(e,n){const t=[],r=e=>{e.forEach((e=>{t.push(e);const o=n(e);null!=o&&o.length&&r(o)}))};return r(e),t}(a.subRows,(e=>e.subRows)),getAllCells:yE((()=>[e.getAllLeafColumns()]),(n=>n.map((n=>function(e,n,t,r){const o={id:n.id+"_"+t.id,row:n,column:t,getValue:()=>n.getValue(r),renderValue:()=>{var n;return null!=(n=o.getValue())?n:e.options.renderFallbackValue},getContext:yE((()=>[e,t,n,o]),((e,n,t,r)=>({table:e,column:n,row:t,cell:r,getValue:r.getValue,renderValue:r.renderValue})),{key:"development"===process.env.NODE_ENV&&"cell.getContext",debug:()=>e.options.debugAll})};return e._features.forEach((r=>{Object.assign(o,null==r.createCell?void 0:r.createCell(o,t,n,e))}),{}),o}(e,a,n,n.id)))),{key:"development"===process.env.NODE_ENV&&"row.getAllCells",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugRows}}),_getAllCellsByColumnId:yE((()=>[a.getAllCells()]),(e=>e.reduce(((e,n)=>(e[n.column.id]=n,e)),{})),{key:"production"===process.env.NODE_ENV&&"row.getAllCellsByColumnId",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugRows}})};for(let n=0;n<e._features.length;n++){const t=e._features[n];Object.assign(a,null==t||null==t.createRow?void 0:t.createRow(a,e))}return a};function aD(e,n){return e?function(e){return"function"==typeof e&&(()=>{const n=Object.getPrototypeOf(e);return n.prototype&&n.prototype.isReactComponent})()}(t=e)||"function"==typeof t||function(e){return"object"==typeof e&&"symbol"==typeof e.$$typeof&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}(t)?r.createElement(e,n):e:null;var t}var lD,sD,dD;!function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.SMALL=42]="SMALL",e[e.LARGE=56]="LARGE"}(lD||(lD={})),function(e){e.ACCESSOR="accessor",e.DISPLAY="display",e.GROUP="group",e.ACTION="action"}(sD||(sD={})),function(e){e.CHECKBOX="checkbox",e.TOGGLE="toggle",e.ROW_ACTIONS="row_actions",e.SETTINGS="settings"}(dD||(dD={}));var cD,uD,pD,fD,mD,gD,hD,vD,bD,yD,xD,wD,$D,CD,kD,SD,ED,DD,TD,_D,ND,PD,MD,OD,RD,ID,AD,FD,LD,zD,HD,jD,BD,UD=y({}),YD=function(e){var n=e.children,t=e.defaultRowSize,r=o.useState(t||lD.UNSPECIFIED),i={rowSize:r[0],setRowSize:r[1]};return o.createElement(UD.Provider,{value:i},n)},VD=w.div(cD||(cD=Xe(["\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n"],["\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n"]))),WD=w.span(uD||(uD=Xe(["\n position: absolute;\n width: 24px;\n height: 16px;\n border-radius: 15px;\n opacity: ",";\n background-color: ",";\n cursor: ",";\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin: ","px;\n transition: 0.2s;\n background-color: ",";\n }\n"],["\n position: absolute;\n width: 24px;\n height: 16px;\n border-radius: 15px;\n opacity: ",";\n background-color: ",";\n cursor: ",";\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin: ","px;\n transition: 0.2s;\n background-color: ",";\n }\n"])),(function(e){return e.disabled?.3:1}),(function(e){return e.theme.palette.grey[300]}),(function(e){return e.disabled?"not-allowed":"pointer"}),12,12,2,(function(e){return e.theme.palette.white[100]})),GD=w.input(pD||(pD=Xe(["\n opacity: 0;\n z-index: 1;\n border-radius: 15px;\n width: 24px;\n &:checked + "," {\n background-color: ",";\n\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin-left: 11px;\n transition: 0.2s;\n }\n }\n"],["\n opacity: 0;\n z-index: 1;\n border-radius: 15px;\n width: 24px;\n &:checked + "," {\n background-color: ",";\n\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin-left: 11px;\n transition: 0.2s;\n }\n }\n"])),WD,(function(e){var n=e.theme.palette;return e.disabled?n.grey[300]:n.blue[500]}),12,12),KD=function(e){var n=e.checked,t=void 0!==n&&n,r=e.disabled,i=void 0!==r&&r,a=e.onChange;return o.createElement(VD,null,o.createElement(GD,{type:"checkbox",checked:t,disabled:i,onChange:function(){return null==a?void 0:a(t)}}),o.createElement(WD,{disabled:i}))},qD=function(e){var n=e.theme,t=e.isHeader,r=e.isPopoverActive,o=e.isPinned,i=t?n.palette.grey[50]:n.palette.white[100];return{position:o?"sticky":void 0,backgroundColor:o?i:void 0,left:"left"===o?"0px":void 0,right:"right"===o?"0px":void 0,boxShadow:o?"-5px 0 5px -5px rgba(51, 51, 51, 0.15)":void 0,zIndex:r?2:1}},XD=w.div(fD||(fD=Xe(["\n display: flex;\n align-items: center;\n padding: 8px;\n"],["\n display: flex;\n align-items: center;\n padding: 8px;\n"]))),QD=w(_r)(mD||(mD=Xe(["\n color: ",";\n font-size: 14px;\n &:hover {\n background-color: transparent;\n color: ",";\n }\n"],["\n color: ",";\n font-size: 14px;\n &:hover {\n background-color: transparent;\n color: ",";\n }\n"])),(function(e){return e.theme.palette.grey[500]}),(function(e){return e.theme.palette.blue[500]})),ZD=w(Nr)(gD||(gD=Xe(["\n font-size: 14px;\n color: ",";\n border-radius: 6px;\n &:hover {\n background-color: ",";\n color: ",";\n }\n &:active {\n background-color: ",";\n }\n"],["\n font-size: 14px;\n color: ",";\n border-radius: 6px;\n &:hover {\n background-color: ",";\n color: ",";\n }\n &:active {\n background-color: ",";\n }\n"])),(function(e){return e.theme.palette.grey[500]}),(function(e){return e.theme.palette.blue[100]}),(function(e){return e.theme.palette.blue[700]}),(function(e){return e.theme.palette.blue[200]})),JD=function(e){var n=e.dropdown,r=e.row,l=e.onOpen,s=e.onClose,d=a((function(){return o.createElement(ZD,{icon:{icon:t,fixedWidth:!0}})}),[]),c=i((function(){return n.map((function(e){var n=e.onClick,t=Ve(e,["onClick"]);return Ye({onClick:function(){return n(r)}},t)}))}),[n,r]);return o.createElement(zr,{placement:"right-start",renderTrigger:d,content:c,onOpen:l,onClose:s})},eT=function(e){var n,t,r=e.actionType,i=e.row,a=e.isToggled,l=e.onActionChange,d=e.rowActions,c=e.column,u=e.maxWidth,p=e.minWidth,f=$(),m=s(!1),g=m[0],h=m[1],v=null===(n=null==d?void 0:d.dropdown)||void 0===n?void 0:n.tooltip,b=null===(t=null==d?void 0:d.dropdown)||void 0===t?void 0:t.items;switch(r){case dD.CHECKBOX:return o.createElement("div",{className:"DS-rt-td DS-tour-checkbox",style:{maxWidth:u,minWidth:p}},o.createElement(XD,{style:{paddingLeft:8}},o.createElement(nT,{value:i.getIsSelected(),onChange:function(){return i.toggleSelected()}})));case dD.TOGGLE:return o.createElement("div",{style:{maxWidth:u,minWidth:p}},o.createElement(XD,null,o.createElement(KD,{checked:a,onChange:function(){return null==l?void 0:l(i.id)}})));case dD.ROW_ACTIONS:return o.createElement("div",{style:Ye({maxWidth:u,minWidth:p},qD({isHeader:!1,isPopoverActive:g,theme:f,isPinned:c.getIsPinned()}))},o.createElement(XD,null,(null==d?void 0:d.primary)&&(null==d?void 0:d.primary.map((function(e,n){var t;return o.createElement(xl,Ye({key:n},null!==(t=e.tooltip)&&void 0!==t?t:yl,{showAfterSeconds:.5}),o.createElement(tT,{primary:e,row:i}))}))),o.createElement(xl,Ye({},null!=v?v:yl,{showAfterSeconds:.5}),b&&o.createElement(JD,{dropdown:b,row:i,onOpen:function(e){h(e)}}))));default:return o.createElement(o.Fragment,null)}},nT=w(Zu)(vD||(vD=Xe(["\n ",";\n"],["\n ",";\n"])),(function(e){var n=e.value,t=e.theme;return!n&&C(hD||(hD=Xe(["\n span {\n background-color: ",";\n }\n "],["\n span {\n background-color: ",";\n }\n "])),t.palette.white[100])})),tT=function(e){var n=e.primary,t=e.row,r=n.text,i=n.icon,a=n.onClick;return o.createElement(o.Fragment,null,r&&o.createElement(QD,{type:"text",text:r,onClick:function(){return a(t)}}),i&&o.createElement(ZD,{icon:i,onClick:function(){return a(t)}}))},rT=w.div(bD||(bD=Xe(["\n position: relative;\n"],["\n position: relative;\n"]))),oT=w.div(yD||(yD=Xe(["\n position: absolute;\n z-index: 10;\n top: -16px;\n width: 100%;\n textarea {\n color: "," !important;\n width: 100%;\n min-width: 80px;\n }\n"],["\n position: absolute;\n z-index: 10;\n top: -16px;\n width: 100%;\n textarea {\n color: "," !important;\n width: 100%;\n min-width: 80px;\n }\n"])),(function(e){return e.theme.palette.black[80]})),iT=w.div(xD||(xD=Xe(["\n position: absolute;\n z-index: 2;\n bottom: 2px;\n right: 6px;\n"],["\n position: absolute;\n z-index: 2;\n bottom: 2px;\n right: 6px;\n"]))),aT=w(cn)(wD||(wD=Xe(["\n cursor: pointer;\n font-size: 12px;\n margin: 2px;\n color: ",";\n"],["\n cursor: pointer;\n font-size: 12px;\n margin: 2px;\n color: ",";\n"])),(function(e){var n=e.theme;return e.confirm?n.palette.green[900]:n.palette.red[900]})),lT=function(e){var n=e.onChange,t=e.row,r=e.content,i=e.onBlur,l=s(null==r?void 0:r.toString()),d=l[0],c=l[1],u=ve(a((function(e){e&&(null==n||n(d||"",t)),i()}),[n,t,d,i]),200);return o.createElement(oT,null,o.createElement(iT,null,o.createElement(aT,{icon:R,onClick:function(){return u(!0)},confirm:!0}),o.createElement(aT,{icon:I})),o.createElement(Bl,{value:d,onChange:function(e){return c(e.target.value)},autoFocus:!0,initialHeight:"100px",onBlur:function(){return u()},onFocus:function(e){var n=e.target.value;e.target.value="",e.target.value=n}}))},sT=function(e){var n=e.hover,t=e.onChange,r=e.row,i=e.unitSymbol,a=e.content,l=s(!1),d=l[0],c=l[1];return o.createElement(rT,null,d?o.createElement(lT,{row:r,onChange:t,onBlur:function(){return c(!1)},content:a}):o.createElement(Ol,{hasMeasureUnit:!!i},o.createElement(kl,{value:null==a?void 0:a.toString(),isTransparent:!n,actionIcon:Ye({icon:A},n?{}:{visibility:"hidden"}),onFocus:function(){return c(!0)}})))},dT=function(e){var n=e.content,t=e.isEditable,r=e.tag,i=e.unitSymbol,l=e.headline,s=e.leadingIcon,d=e.avatar,c=e.actionType,u=e.row,p=e.rowSize,f=e.onActionChange,m=e.isToggled,g=e.hover,h=e.onChange,v=e.trailingMicroTag,b=e.minWidth,y=e.rowActions,x=e.context,w=e.onRowClick,$=e.maxWidth,C=e.align,k=e.disableClick,S=x.column,E=!t&&"function"==typeof w&&!k,D=a((function(e){return E&&w(e)}),[E,w]);if(c){var T=b?b+1:void 0,_=$?$+1:void 0;return o.createElement(eT,{row:u,actionType:c,isToggled:m,onActionChange:f,rowActions:y,column:S,maxWidth:_,minWidth:T})}return o.createElement(Sl,{className:"DS-rt-td",role:"gridcell",minWidth:b,maxWidth:$,onClick:function(){return D(u)},cellHasOnClick:E,style:{overflow:t?"visible":void 0,zIndex:t?"auto":void 0},align:C},o.createElement(El,null,s&&o.createElement(Dl,null,o.createElement(cn,Ye({},s))),d&&o.createElement(Tl,null,o.createElement(or,Ye({},d))),o.createElement(_l,{hasMeasureUnit:!!i},t?o.createElement(sT,{hover:g,onChange:h,row:u,unitSymbol:i,content:n}):o.createElement(o.Fragment,null,o.createElement(Rl,null,o.createElement(Nl,{truncate:!!p,headline:l},n),i&&o.createElement(Pl,{headline:l},i)),r&&o.createElement(ck,Ye({},r)))),v&&o.createElement(Ml,null,o.createElement(vb,{type:v.type,text:v.text}))))},cT=function(e){var n,t=e.isActionCell,r=e.minWidth,i=e.maxWidth,a=e.align,l=null!==(n=t?32:null!=r?r:i)&&void 0!==n?n:50;return o.createElement("div",{className:"DS-rt-tr",style:{maxWidth:i,minWidth:r}},o.createElement(pT,{className:"DS-rt-td",align:a},o.createElement(uT,{speed:2,height:26,viewBox:"0 0 "+l+" 36",animate:!0},o.createElement("rect",{x:"0",y:"0",rx:"5",height:"36",width:l}))))},uT=w(H$)($D||($D=Xe(["\n width: auto;\n align-items: center;\n"],["\n width: auto;\n align-items: center;\n"]))),pT=w.div(kD||(kD=Xe(["\n display: flex;\n align-items: center;\n flex: 1;\n\n margin-inline: 8px;\n\n ",";\n"],["\n display: flex;\n align-items: center;\n flex: 1;\n\n margin-inline: 8px;\n\n ",";\n"])),(function(e){var n=e.align;return C(CD||(CD=Xe(["\n justify-content: ",";\n "],["\n justify-content: ",";\n "])),"center"===n?"center":"left"===n?"flex-start":"flex-end")})),fT=function(e){var n=e.cell,t=e.row,r=e.hover,i=e.rowSize,a=e.isLoading,l=e.onRowClick,s=function(e,n){var t,r=e.getValue(),o=!("string"==typeof r||"number"==typeof r),i=e.column.columnDef,a=i.actionType&&be(i.toggles,(function(e){return e===n.id})),l=i.rowActions,s=e.column.columnDef.unitSymbol;return{isEditable:!!e.column.columnDef.isEditable,isToggled:!!a,actionType:i.actionType,onActionChange:i.onActionChange,content:o?null===(t=r)||void 0===t?void 0:t.content:r,unitSymbol:o&&r&&r.unitSymbol||s,values:r,minWidth:e.column.columnDef.minWidth,maxWidth:e.column.columnDef.maxWidth,rowActions:l,align:e.column.columnDef.align||"left"}}(n,t),d=s.values,c=Ve(s,["values"]);if(a)return o.createElement(cT,{isActionCell:!!c.actionType,minWidth:c.minWidth,maxWidth:c.maxWidth,align:c.align});var u=n.column.columnDef.customCell,p=n.column.columnDef.disableClick;if(u){var f=c.maxWidth,m=c.minWidth,g=c.align;return o.createElement(mT,{className:"DS-rt-td",style:{maxWidth:f,minWidth:m},align:g,onClick:function(){return!p&&(null==l?void 0:l(t))}},aD(u(t,!!r),n.getContext()))}return o.createElement(dT,Ye({context:n.getContext(),key:n.id,row:t,hover:r,rowSize:i,onRowClick:l},d,c,{onChange:n.column.columnDef.onChange,disableClick:p}))},mT=w.div(ED||(ED=Xe(["\n height: 100%;\n display: flex;\n align-items: center;\n width: 100%;\n ",";\n /* margin-inline: 8px; */\n"],["\n height: 100%;\n display: flex;\n align-items: center;\n width: 100%;\n ",";\n /* margin-inline: 8px; */\n"])),(function(e){var n=e.align;return C(SD||(SD=Xe(["\n justify-content: ",";\n "],["\n justify-content: ",";\n "])),"center"===n?"center":"left"===n?"flex-start":"flex-end")})),gT=w.div(_D||(_D=Xe(["\n box-shadow: ",";\n transition: box-shadow 200ms ease;\n ","\n ","\n"],["\n box-shadow: ",";\n transition: box-shadow 200ms ease;\n ","\n ","\n"])),(function(e){var n=e.mouseHover,t=e.theme;return n?"0px 3px 6px rgba(51, 51, 51, 0.15), 0px 2px 4px rgba(51, 51, 51, 0.12)":"0px 1px "+t.palette.grey[100]}),(function(e){var n=e.size;return n&&C(DD||(DD=Xe(["\n height: ","px;\n "],["\n height: ","px;\n "])),n)}),(function(e){var n=e.selected,t=e.theme;return n&&C(TD||(TD=Xe(["\n background-color: ",";\n "],["\n background-color: ",";\n "])),t.palette.blue[50])})),hT=function(e){var n=e.row,t=e.isLoading,r=e.onRowClick,i=e.isRowHighlighted,a=e.rowHighlightColor,l=x(UD).rowSize,d=s(),c=d[0],u=d[1];return o.createElement(gT,{className:"DS-rt-tr-group",role:"rowgroup",mouseHover:!t&&c,onMouseEnter:function(){return u(!0)},onMouseLeave:function(){return u(!1)},size:l,selected:!t&&n.getIsSelected()},o.createElement(vT,{className:"DS-rt-tr",role:"row",style:{height:l},isRowHighlighted:i,rowHighlightColor:a},n.getVisibleCells().map((function(e,i){return o.createElement(fT,{key:i,cell:e,row:n,hover:c,rowSize:l,isLoading:t,onRowClick:r})}))))},vT=w.div(PD||(PD=Xe(["\n ",";\n font-size: 14px;\n color: ",";\n"],["\n ",";\n font-size: 14px;\n color: ",";\n"])),(function(e){var n=e.isRowHighlighted,t=e.rowHighlightColor,r=e.theme;return n&&C(ND||(ND=Xe(["\n background-color: ",";\n border-bottom: 1px solid #b0b9bd; // Grey 3\n "],["\n background-color: ",";\n border-bottom: 1px solid #b0b9bd; // Grey 3\n "])),t||r.palette.primary[100])}),(function(e){return e.theme.palette.black[80]})),bT=function(e){var n=e.rows,t=e.rowSize,r=e.isLoading,i=e.onRowClick,a=e.bodyHeight,s=e.rowIdHighlight,c=e.rowHighlightColor,u=e.pageIndex,p=d(null);return l((function(){p.current&&p.current.scrollTo({top:0})}),[u]),o.createElement("div",{ref:p,className:"DS-rt-tbody",style:{height:a}},n.map((function(e){return o.createElement(hT,{key:e.id,row:e,rowSize:t,isLoading:r,onRowClick:i,isRowHighlighted:s===+e.id,rowHighlightColor:c})})))},yT=w.div(MD||(MD=Xe(["\n max-height: ","px;\n visibility: ",";\n transition: max-height 400ms ease;\n padding-bottom: ",";\n background-color: ",";\n position: relative;\n z-index: 11;\n"],["\n max-height: ","px;\n visibility: ",";\n transition: max-height 400ms ease;\n padding-bottom: ",";\n background-color: ",";\n position: relative;\n z-index: 11;\n"])),(function(e){var n=e.shown,t=e.allSelectedShown;return n?t?94:48:0}),(function(e){return e.shown?"unset":"hidden"}),(function(e){return e.shown?"16px":"0"}),(function(e){return e.theme.palette.white[100]})),xT=w.div(OD||(OD=Xe(["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n // width: 100%;\n align-items: center;\n justify-content: space-between;\n padding: 8px 8px;\n font-size: 14px;\n line-height: 21px;\n"],["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n // width: 100%;\n align-items: center;\n justify-content: space-between;\n padding: 8px 8px;\n font-size: 14px;\n line-height: 21px;\n"])),(function(e){return e.theme.palette.black[80]})),wT=w.div(RD||(RD=Xe(["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 8px;\n font-size: 14px;\n line-height: 21px;\n gap: 8px;\n"],["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 8px;\n font-size: 14px;\n line-height: 21px;\n gap: 8px;\n"])),(function(e){return e.theme.palette.black[80]})),$T=w.div(ID||(ID=Xe(["\n display: flex;\n justify-content: flex-end;\n gap: 16px;\n"],["\n display: flex;\n justify-content: flex-end;\n gap: 16px;\n"]))),CT=w.span(AD||(AD=Xe([""],[""]))),kT=function(e){var n=e.selectedRowData,r=e.bulkBarActions,c=e.allSelectedCTA,u=e.renderBulkActions,p=n.length,f=d(null),m=d(null),g=s(),h=g[0],v=g[1],y=s(),x=y[0],w=y[1],$=s(!1),C=$[0],k=$[1];b((function(){var e,n,t,r;v(null===(n=null===(e=null==f?void 0:f.current)||void 0===e?void 0:e.getBoundingClientRect())||void 0===n?void 0:n.width),w(null===(r=null===(t=null==m?void 0:m.current)||void 0===t?void 0:t.getBoundingClientRect())||void 0===r?void 0:r.width)}),[]),l((function(){var e=ve((function(){var e,n;v(null===(n=null===(e=null==f?void 0:f.current)||void 0===e?void 0:e.getBoundingClientRect())||void 0===n?void 0:n.width),w((function(e){var n,t,r,o,i,a;return(null===(t=null===(n=null==m?void 0:m.current)||void 0===n?void 0:n.getBoundingClientRect())||void 0===t?void 0:t.width)&&(null===(o=null===(r=null==m?void 0:m.current)||void 0===r?void 0:r.getBoundingClientRect())||void 0===o?void 0:o.width)>(e||0)?null===(a=null===(i=null==m?void 0:m.current)||void 0===i?void 0:i.getBoundingClientRect())||void 0===a?void 0:a.width:e}))}),200);return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}}),[]),l((function(){k((h||0)-(x||0)<200)}),[h,x]);var S=a((function(){return o.createElement(ZD,{icon:{icon:t,fixedWidth:!0}})}),[]),E=i((function(){return(null==r?void 0:r.slice(1,-1).map((function(e){var t=e.onClick,r=e.color;return{onClick:function(){return t(n)},text:e.text,color:r,icon:e.iconLeft}})))||[]}),[r,n]);return o.createElement(yT,{ref:f,shown:!!p&&p>0,allSelectedShown:!!c,id:"DS-bulk-bar-wrapper"},o.createElement(xT,{id:"DS-checkbox-table-bulk-bar"},o.createElement(CT,null,p+" "+(1===p?"selezionato":"selezionati")),r&&r.length>0?o.createElement($T,{ref:m},!C||r.length<3?r.map((function(e,t){return o.createElement(_r,Ye({key:t},e,{onClick:function(){return e.onClick(n)}}))})):o.createElement(o.Fragment,null,o.createElement(_r,Ye({},r[0],{onClick:function(){return r[0].onClick(n)}})),o.createElement(zr,{placement:"bottom-end",renderTrigger:S,content:E}),o.createElement(_r,Ye({},r[r.length-1],{onClick:function(){return r[r.length-1].onClick(n)}})))):o.createElement($T,{ref:m},null==u?void 0:u(n))),!!c&&o.createElement(wT,null,null==c?void 0:c.description,o.createElement(_r,{text:null==c?void 0:c.text,onClick:null==c?void 0:c.onClick,type:"text"})))},ST=function(e){var n=e.footerGroup;return o.createElement("div",null,n.map((function(e){return o.createElement("div",{key:e.id},e.headers.map((function(e){return o.createElement("div",{key:e.id},e.isPlaceholder?null:aD(e.column.columnDef.footer,e.getContext()))})))})))},ET=w.div(FD||(FD=Xe(["\n width: 100%;\n height: 100%;\n overflow-x: hidden;\n"],["\n width: 100%;\n height: 100%;\n overflow-x: hidden;\n"]))),DT=w.div(LD||(LD=Xe(["\n overflow-y: auto;\n overflow-x: hidden;\n height: 100%;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n\n /* CSS relativo al body scrollable */\n .DS-ReactTable-container {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n }\n\n .DS-ReactTable {\n position: relative;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-table {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n width: 100%;\n border-collapse: collapse;\n overflow-x: auto;\n overflow-y: hidden;\n }\n\n .DS-ReactTable .DS-rt-thead {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n cursor: default;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-th {\n position: relative;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-td {\n line-height: normal;\n position: relative;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header:last-child {\n overflow: hidden;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header-content {\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .DS-ReactTable .DS-rt-thead.DS-header .DS-rt-th:after {\n content: '';\n display: block;\n position: absolute;\n }\n\n .DS-ReactTable .DS-rt-tbody {\n padding-bottom: 5px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n }\n\n .DS-ReactTable .DS-rt-tbody .DS-rt-tr-group {\n flex: none;\n }\n\n .DS-ReactTable .DS-rt-tr-group {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n cursor: pointer;\n }\n\n .DS-ReactTable .DS-rt-tr {\n flex: 1 0;\n display: inline-flex;\n flex-direction: row;\n flex-wrap: wrap;\n align-content: center;\n justify-content: center;\n align-items: center;\n }\n\n .DS-ReactTable .DS-rt-th {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: nowrap;\n vertical-align: middle;\n align-self: center;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-td {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: break-spaces;\n text-overflow: ellipsis;\n align-self: center;\n /* overflow: hidden; */\n }\n"],["\n overflow-y: auto;\n overflow-x: hidden;\n height: 100%;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n\n /* CSS relativo al body scrollable */\n .DS-ReactTable-container {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n }\n\n .DS-ReactTable {\n position: relative;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-table {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n width: 100%;\n border-collapse: collapse;\n overflow-x: auto;\n overflow-y: hidden;\n }\n\n .DS-ReactTable .DS-rt-thead {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n cursor: default;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-th {\n position: relative;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-td {\n line-height: normal;\n position: relative;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header:last-child {\n overflow: hidden;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header-content {\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .DS-ReactTable .DS-rt-thead.DS-header .DS-rt-th:after {\n content: '';\n display: block;\n position: absolute;\n }\n\n .DS-ReactTable .DS-rt-tbody {\n padding-bottom: 5px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n }\n\n .DS-ReactTable .DS-rt-tbody .DS-rt-tr-group {\n flex: none;\n }\n\n .DS-ReactTable .DS-rt-tr-group {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n cursor: pointer;\n }\n\n .DS-ReactTable .DS-rt-tr {\n flex: 1 0;\n display: inline-flex;\n flex-direction: row;\n flex-wrap: wrap;\n align-content: center;\n justify-content: center;\n align-items: center;\n }\n\n .DS-ReactTable .DS-rt-th {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: nowrap;\n vertical-align: middle;\n align-self: center;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-td {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: break-spaces;\n text-overflow: ellipsis;\n align-self: center;\n /* overflow: hidden; */\n }\n"]))),TT=w.div(zD||(zD=Xe(["\n height: 100%;\n position: relative;\n border-spacing: 0 2px;\n border: 0;\n td,\n th {\n padding: 0;\n }\n"],["\n height: 100%;\n position: relative;\n border-spacing: 0 2px;\n border: 0;\n td,\n th {\n padding: 0;\n }\n"]))),_T=w(cn)(HD||(HD=Xe(["\n transform: rotate(","deg);\n color: ",";\n height: 16px;\n width: 16px !important;\n padding: 2px;\n &:hover {\n color: ",";\n background-color: ",";\n border-radius: 100%;\n cursor: pointer;\n }\n"],["\n transform: rotate(","deg);\n color: ",";\n height: 16px;\n width: 16px !important;\n padding: 2px;\n &:hover {\n color: ",";\n background-color: ",";\n border-radius: 100%;\n cursor: pointer;\n }\n"])),(function(e){return e.isSortedDesc?180:0}),(function(e){var n=e.isSorted,t=e.theme;return n?t.palette.grey[900]:t.palette.grey[200]}),(function(e){return e.theme.palette.grey[900]}),(function(e){return e.theme.palette.grey[100]})),NT=w.div(jD||(jD=Xe(["\n display: flex;\n justify-content: center;\n text-align: center;\n width: 100%;\n margin-bottom: 18px;\n"],["\n display: flex;\n justify-content: center;\n text-align: center;\n width: 100%;\n margin-bottom: 18px;\n"]))),PT=function(e){var n,t=e.columns,r=e.isSelectable,o=e.toggles,i=e.isTogglesSortable,a=e.onTogglesChange,l=e.rowActions,s=e.enableSettings,d=e.settingsDropdownConfig,c=e.preSettedTableSettings,u={accessor:(e,n)=>"function"==typeof e?{...n,accessorFn:e}:{...n,accessorKey:e},display:e=>e,group:e=>e},p=(null==c?void 0:c.orderColumns)?qe([],t,!0).sort((function(e,n){var t,r,o=null===(t=c.orderColumns)||void 0===t?void 0:t.indexOf(String(e.key)),i=null===(r=c.orderColumns)||void 0===r?void 0:r.indexOf(String(n.key));return void 0!==o&&void 0!==i?o-i:0})):t,f=qe(qe(qe(qe([],r?[{columnDefType:sD.ACTION,key:dD.CHECKBOX,columnDef:{actionType:dD.CHECKBOX,enableSorting:!1,maxWidth:32}}]:[],!0),o?[{columnDefType:sD.ACTION,key:dD.TOGGLE,columnDef:{actionType:dD.TOGGLE,enableSorting:i,toggles:o,sortingFn:function(e,n){return function(e,n,t){var r=xe(t,e.id),o=xe(t,n.id);return r?1:o?-1:0}(e,n,o)},onActionChange:function(e){return null==a?void 0:a(m(e,o))},maxWidth:32}}]:[],!0),p,!0),l||s?[{ColumnDefType:sD.ACTION,key:dD.ROW_ACTIONS,columnDef:{actionType:dD.ROW_ACTIONS,enableSorting:!1,rowActions:l,enableSettings:s,settingsDropdownConfig:d,headerTooltip:null!==(n=null==d?void 0:d.settingsTooltip)&&void 0!==n?n:{},enablePinning:!0,maxWidth:80,minWidth:80,align:"center"}}]:[],!0),m=function(e,n){return be(n,(function(n){return n===e}))?ye(n,(function(n){return n!==e})):qe(qe([],n,!0),[e],!1)};return f.map((function(e){switch(e.columnDefType){default:case sD.DISPLAY:return u.display(Ye({id:String(e.key)},e.columnDef));case sD.ACCESSOR:return u.accessor(e.key,e.columnDef);case sD.GROUP:return u.group(Ye({},e.columnDef));case sD.ACTION:return u.accessor(e.key,e.columnDef)}}))},MT=function(e){switch(e){default:case!1:return"asc";case"asc":return"desc";case"desc":return!1}};!function(e){e[e.FIRST=0]="FIRST",e[e.SECOND=1]="SECOND",e[e.THIRD=2]="THIRD"}(BD||(BD={}));var OT,RT,IT,AT,FT,LT,zT,HT,jT,BT=w(zu)(OT||(OT=Xe(["\n margin-top: 16px;\n margin-left: 8px;\n .body {\n padding: 0 0;\n }\n .header {\n height: ",";\n }\n"],["\n margin-top: 16px;\n margin-left: 8px;\n .body {\n padding: 0 0;\n }\n .header {\n height: ",";\n }\n"])),Au.m),UT=w.h6(RT||(RT=Xe(["\n font-size: 12px;\n color: ",";\n font-weight: 500;\n line-height: 18px;\n padding: 0;\n margin: 0;\n"],["\n font-size: 12px;\n color: ",";\n font-weight: 500;\n line-height: 18px;\n padding: 0;\n margin: 0;\n"])),(function(e){return e.theme.palette.black})),YT=w.div(IT||(IT=Xe(["\n margin-top: 12px;\n margin-left: 0;\n margin-right: 0;\n"],["\n margin-top: 12px;\n margin-left: 0;\n margin-right: 0;\n"]))),VT=w.div(AT||(AT=Xe(["\n height: 1px;\n background-color: ",";\n margin-left: 24px;\n margin-right: 24px;\n"],["\n height: 1px;\n background-color: ",";\n margin-left: 24px;\n margin-right: 24px;\n"])),(function(e){return e.theme.palette.grey[100]})),WT=function(e){var n=e.table,t=e.notRemovableColumns,r=e.onChangeTableSettings,i=d(null),l=d(null),c=function(e){var n=[],t=[],r=[];return e.forEach((function(e){var o=!!e.columnDef.actionType;switch(e.id){case dD.TOGGLE:t[BD.FIRST]=e;break;case dD.CHECKBOX:t[BD.THIRD]=e;break;case dD.ROW_ACTIONS:n[BD.FIRST]=e}o||r.push(e)})),{rightActions:n,leftActions:t,accessorColumns:r}}(n.getAllColumns()),u=c.accessorColumns,p=c.rightActions,f=c.leftActions,m=s(u),g=m[0],h=m[1],v=s(!1),b=v[0],y=v[1],x=function(e){var t=f.map((function(e){return String(e.id)})),r=p.map((function(e){return String(e.id)}));n.setColumnOrder(qe(qe(qe([],t,!0),e,!0),r,!0))},w=a((function(){return g.filter((function(e){return e.getIsVisible()})).length>1}),[g]),$=a((function(e,n){var t=g.filter((function(e){return!e.getIsVisible()})).map((function(e){return e.id}));n&&t.push(e),null==r||r("notVisibleColumns",{notVisibleColumns:n?t:t.filter((function(n){return n!==e}))})}),[g,r]),C=g.map((function(e,n){return o.createElement("div",{key:n,id:e.id,onDragEnter:function(){return function(e){if(l.current=e,null!==l.current&&null!==i.current){var n=qe([],g,!0),t=n[i.current];n.splice(i.current,1),n.splice(l.current,0,t),i.current=l.current,l.current=null,h(n),x(n.map((function(e){return String(e.id)})))}}(n)}},o.createElement(QT,{isRemovable:w()&&!(null==t?void 0:t.includes(String(e.id))),draggable:!0,onDragStart:function(e,t){return function(e,n,t){y(!0),i.current=n,e.dataTransfer.setDragImage(t,0,0)}(e,n,t)},onDragOver:function(e){return e.preventDefault()},onDragEnd:function(){y(!1),null==r||r("orderColumns",{orderColumns:g.map((function(e){return String(e.id)}))})},column:e,onChangeTableSettings:$}),b&&i.current===n&&o.createElement(VT,null))}));return o.createElement(YT,null,C)},GT=function(e){var n=e.table,t=e.visibleColumnsLabel,r=e.notRemovableColumns,i=e.onChangeTableSettings;return o.createElement(BT,{renderTitle:function(){return o.createElement(UT,null,t)},renderBody:function(){return o.createElement(WT,{table:n,preSettedColumns:["subject","category"],notRemovableColumns:r,onChangeTableSettings:i})}})},KT=w.div(FT||(FT=Xe(["\n display: flex;\n justify-content: flex-start;\n align-items: center;\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -khtml-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n"],["\n display: flex;\n justify-content: flex-start;\n align-items: center;\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -khtml-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n"]))),qT=w.div(LT||(LT=Xe(["\n margin-right: 4px;\n"],["\n margin-right: 4px;\n"]))),XT=w(Nr)(zT||(zT=Xe(["\n color: ",";\n"],["\n color: ",";\n"])),(function(e){return e.theme.palette.grey[300]})),QT=function(e){var n,t=e.column,r=e.draggable,i=e.onDragStart,a=e.onDragOver,l=e.onDragEnd,s=e.isRemovable,c=e.onChangeTableSettings,u=d(null);return o.createElement(KT,{ref:u,onDragOver:a},o.createElement(qT,{draggable:r,onDragStart:function(e){u.current&&i(e,u.current)},onDragEnd:l},o.createElement(XT,{icon:{icon:de}})),o.createElement(Zu,{value:t.getIsVisible(),text:null!==(n=t.columnDef.headerTitle)&&void 0!==n?n:String(t.columnDef.header),onClick:function(){t.toggleVisibility(),null==c||c(String(t.id),t.getIsVisible())},disabled:!s&&t.getIsVisible()}))},ZT=w(Mv)(HT||(HT=Xe(["\n margin-top: 12px;\n"],["\n margin-top: 12px;\n"])));!function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.SMALL=1]="SMALL",e[e.LARGE=2]="LARGE"}(jT||(jT={}));var JT,e_,n_,t_,r_,o_,i_,a_,l_,s_,d_,c_,u_,p_,f_,m_,g_,h_,v_,b_,y_,x_,w_,$_,C_,k_=function(e){var n=e.rowHeightLabel,t=e.unspecifiedRowsLabel,r=e.smallRowsLabel,i=e.largeRowsLabel,a=e.isDisabled,l=e.dimensionRow,s=e.onChangeTableSettings,d=x(UD).setRowSize,c=function(e){switch(e){default:case jT.UNSPECIFIED:return d(lD.UNSPECIFIED),lD.UNSPECIFIED;case jT.SMALL:return d(lD.SMALL),lD.SMALL;case jT.LARGE:return d(lD.LARGE),lD.LARGE}},u=function(){switch(l){default:case lD.UNSPECIFIED:return jT.UNSPECIFIED;case lD.SMALL:return jT.SMALL;case lD.LARGE:return jT.LARGE}},p=[{text:t,large:!1,disabled:a||!1},{text:r,large:!1,disabled:a||!1},{text:i,large:!1,disabled:a||!1}];return o.createElement(BT,{renderTitle:function(){return o.createElement(UT,null,n)},renderBody:function(){return o.createElement(ZT,{spacing:"xs",initialSelection:u(),options:p,onChange:function(e){null==s||s("dimensionRow",{dimensionRow:c(e)})}})}})},S_=w(Nr)(JT||(JT=Xe(["\n color: ",";\n"],["\n color: ",";\n"])),(function(e){return e.theme.palette.blue[700]})),E_=w.div(e_||(e_=Xe(["\n padding: 16px 24px;\n margin: 0;\n max-height: 220px;\n overflow: auto;\n"],["\n padding: 16px 24px;\n margin: 0;\n max-height: 220px;\n overflow: auto;\n"]))),D_=w.div(n_||(n_=Xe(["\n display: flex;\n align-items: center;\n"],["\n display: flex;\n align-items: center;\n"]))),T_=w.div(t_||(t_=Xe(["\n font-size: 14px;\n line-height: 21px;\n font-weight: 500;\n font-style: normal;\n"],["\n font-size: 14px;\n line-height: 21px;\n font-weight: 500;\n font-style: normal;\n"]))),__=w.div(r_||(r_=Xe(["\n background-color: ",";\n height: 24px;\n width: 24px;\n border-radius: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n margin-right: 10px;\n"],["\n background-color: ",";\n height: 24px;\n width: 24px;\n border-radius: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n margin-right: 10px;\n"])),(function(e){return e.theme.palette.grey[50]})),N_=function(e){var n=e.header,t=e.notRemovableColumns,r=e.dimensionRow,i=e.onChangeTableSettings,a=function(e){var n,t,r,o,i,a,l,s,d,c,u,p,f=e.column,m=(0,e.getContext)().table,g=0===(0,m.getRowModel)().rows.length,h=f.columnDef;return{table:m,isTableEmpty:g,displaySettingsLabel:null!==(t=null===(n=h.settingsDropdownConfig)||void 0===n?void 0:n.displaySettingsLabel)&&void 0!==t?t:"Impostazioni visualizzazione",visibleColumnsLabel:null!==(o=null===(r=h.settingsDropdownConfig)||void 0===r?void 0:r.visibleColumnsLabel)&&void 0!==o?o:"Colonne visibili",rowHeightLabel:null!==(a=null===(i=h.settingsDropdownConfig)||void 0===i?void 0:i.rowHeightLabel)&&void 0!==a?a:"Densità righe",unspecifiedRowsLabel:null!==(s=null===(l=h.settingsDropdownConfig)||void 0===l?void 0:l.unspecifiedRowsLabel)&&void 0!==s?s:"Non specificata",smallRowsLabel:null!==(c=null===(d=h.settingsDropdownConfig)||void 0===d?void 0:d.smallRowsLabel)&&void 0!==c?c:"Righe strette",largeRowsLabel:null!==(p=null===(u=h.settingsDropdownConfig)||void 0===u?void 0:u.largeRowsLabel)&&void 0!==p?p:"Righe larghe"}}(n),l=a.displaySettingsLabel,s=a.isTableEmpty,d=a.largeRowsLabel,c=a.rowHeightLabel,u=a.smallRowsLabel,p=a.table,f=a.unspecifiedRowsLabel,m=a.visibleColumnsLabel;return o.createElement(E_,null,o.createElement(D_,null,o.createElement(__,null,o.createElement(S_,{icon:{icon:Ne,color:"grey",size:"sm"}})),o.createElement(T_,null,l)),o.createElement(GT,{table:p,visibleColumnsLabel:m,notRemovableColumns:t,onChangeTableSettings:i}),o.createElement(k_,{rowHeightLabel:c,unspecifiedRowsLabel:f,smallRowsLabel:u,largeRowsLabel:d,isDisabled:s,dimensionRow:r,onChangeTableSettings:i}))},P_=function(e){var n=e.header,t=e.onOpen,r=e.onClose,i=e.notRemovableColumns,l=e.dimensionRow,s=e.onChangeTableSettings,d=a((function(){return o.createElement(S_,{icon:{icon:ce,size:"sm"}})}),[]);return o.createElement(zr,{placement:"left-start",renderTrigger:d,onOpen:t,onClose:r,renderContent:function(){return o.createElement(N_,{header:n,notRemovableColumns:i,dimensionRow:l,onChangeTableSettings:s})}})},M_=w.span(o_||(o_=Xe(["\n font-size: 12px;\n line-height: 18px;\n color: ",";\n"],["\n font-size: 12px;\n line-height: 18px;\n color: ",";\n"])),(function(e){return e.theme.palette.grey[500]})),O_=w.div(s_||(s_=Xe(["\n border-width: 0px 1px 1px 0px;\n border-style: solid;\n border-color: ",";\n background-color: ",";\n height: ","px;\n ","\n ",";\n ",";\n display: flex;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"],["\n border-width: 0px 1px 1px 0px;\n border-style: solid;\n border-color: ",";\n background-color: ",";\n height: ","px;\n ","\n ",";\n ",";\n display: flex;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"])),(function(e){return e.theme.palette.grey[100]}),(function(e){return e.theme.palette.grey[50]}),(function(e){return e.size||lD.SMALL}),(function(e){return e.sortable&&C(i_||(i_=Xe(["\n cursor: pointer;\n user-select: none;\n "],["\n cursor: pointer;\n user-select: none;\n "])))}),(function(e){var n=e.minWidth;return n&&C(a_||(a_=Xe(["\n min-width: ","px;\n "],["\n min-width: ","px;\n "])),n)}),(function(e){var n=e.maxWidth;return n&&C(l_||(l_=Xe(["\n max-width: ","px;\n "],["\n max-width: ","px;\n "])),n)})),R_=w.span(d_||(d_=Xe(["\n margin: 8px;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"],["\n margin: 8px;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"]))),I_=w.div(c_||(c_=Xe(["\n display: flex;\n align-items: center;\n padding: 8px;\n"],["\n display: flex;\n align-items: center;\n padding: 8px;\n"]))),A_=function(e){var n=e.header,t=e.onOpen,r=e.forceHideSettings,i=e.rowSelection,a=e.setRowSelection,l=e.notRemovableColumns,s=e.dimensionRow,d=e.onChangeTableSettings,c=function(e){var n,t=e.column,r=(0,e.getContext)().table,o=t.columnDef,i=o.actionType,a=null===(n=o.rowActions)||void 0===n?void 0:n.headerTitle,l=!!o.enableSettings,s=t.getCanSort(),d=!!t.getIsSorted();return{actionType:i,isSortedDesc:!1===t.getIsSorted()?null:t.getIsSorted(),isSorted:d,toggleSortable:dD.TOGGLE&&s,table:r,canSort:s,headerTitle:a,allColumns:e.getContext().table.getAllColumns(),isSettingsEnabled:l}}(n),u=c.actionType,p=c.isSorted,f=c.isSortedDesc,m=c.toggleSortable,g=c.table,h=c.headerTitle,v=c.isSettingsEnabled;switch(u){case dD.TOGGLE:return o.createElement(I_,null,o.createElement(KD,{checked:p}),m&&o.createElement(_T,{isSorted:p,isSortedDesc:"desc"===f,icon:U}));case dD.CHECKBOX:return o.createElement(I_,{style:{paddingLeft:8},id:"DS-checkbox-table-header"},o.createElement(Zu,{value:g.getIsAllPageRowsSelected()||(i&&i.length>0?Ou.INDETERMINATE:Ou.UNCHECKED),onChange:function(){a&&!g.getIsAllPageRowsSelected()&&a([]),(g.getIsAllPageRowsSelected()||i&&0===i.length)&&g.toggleAllPageRowsSelected()}}));case dD.ROW_ACTIONS:return o.createElement(I_,null,h&&o.createElement(M_,null,h),v&&!r&&o.createElement(P_,{header:n,onOpen:t,notRemovableColumns:l,dimensionRow:s,onChangeTableSettings:d}));default:return o.createElement(o.Fragment,null)}},F_=function(e){var n=e.header,t=e.headerSize,r=e.onSort,i=e.customSorted,l=e.setCustomSorted,d=e.forceHideSettings,c=e.rowSelection,u=e.setRowSelection,p=e.notRemovableColumns,f=e.dimensionRow,m=e.onChangeTableSettings,g=function(e){var n=e.column,t=n.columnDef.actionType,r=n.getCanSort(),o=!!n.getIsSorted(),i=!1===n.getIsSorted()?null:n.getIsSorted();return{column:n,actionType:t,canSort:r,isSorted:o,isSortedDesc:i,minWidth:n.columnDef.minWidth,maxWidth:n.columnDef.maxWidth,tooltip:n.columnDef.headerTooltip}}(n),h=g.column,v=g.actionType,b=g.canSort,y=g.isSorted,x=g.isSortedDesc,w=g.minWidth,C=g.tooltip,k=g.maxWidth,S=$(),E=s(!1),D=E[0],T=E[1],_=a((function(e){var t,o;r?b&&(null==l||l(((t={})[n.id]=MT(i),t)),r({sortBy:n.id,direction:MT(i)}),n.getContext().table.setPageIndex(1)):null===(o=h.getToggleSortingHandler())||void 0===o||o(e)}),[r,h,n,l,i,b]);return o.createElement(O_,{className:"DS-rt-th",size:t,minWidth:w,maxWidth:k,sortable:b,onClick:_,style:Ye({maxWidth:k},qD({isHeader:!0,theme:S,isPinned:h.getIsPinned(),isPopoverActive:D}))},o.createElement(L_,Ye({},null!=C?C:yl,{showAfterSeconds:.5}),v?o.createElement(A_,{header:n,onOpen:function(e){T(e)},forceHideSettings:d,rowSelection:c,setRowSelection:u,notRemovableColumns:p,dimensionRow:f,onChangeTableSettings:m}):o.createElement(R_,null,o.createElement(M_,null,n.isPlaceholder?null:aD(n.column.columnDef.header,n.getContext())),b&&o.createElement(_T,{isSorted:y||!!i,isSortedDesc:"desc"===x||"desc"===i,icon:U}))))},L_=w(xl)(u_||(u_=Xe(["\n width: 100%;\n"],["\n width: 100%;\n"]))),z_=function(e){var n=e.headerGroup,t=e.headerSize,r=e.onSort,i=e.forceHideSettings,a=e.rowSelection,l=e.setRowSelection,d=e.preSettedTableSettings,c=e.onChangeTableSettings,u=e.notRemovableColumns,p=s(),f=p[0],m=p[1];return o.createElement(H_,{className:"DS-rt-thead DS-header"},n.map((function(e){return o.createElement("div",{key:e.id,className:"DS-rt-tr"},e.headers.map((function(e){var n=null==f?void 0:f[e.id];return o.createElement(F_,{key:e.id,header:e,headerSize:t,onSort:r,customSorted:n,setCustomSorted:m,forceHideSettings:i,rowSelection:a,setRowSelection:l,notRemovableColumns:u,dimensionRow:null==d?void 0:d.dimensionRow,onChangeTableSettings:c})})))})))},H_=w.div(p_||(p_=Xe([""],[""]))),j_=function(e){var n,t=e.data,i=e.columns,d=e.isSelectable,c=e.toggles,u=e.onTogglesChange,p=e.headerSize,f=e.isTogglesSortable,m=void 0!==f&&f,g=e.sortable,h=void 0===g||g,v=e.sortDescFirst,b=void 0===v||v,y=e.enableSettings,x=void 0===y||y,w=e.settingsDropdownConfig,$=e.rowActions,C=e.bulkActions,k=e.isLoading,S=e.allSelectedCTA,E=e.noPagination,D=void 0===E||E,T=e.pageSize,_=void 0===T?10:T,N=e.listSize,P=e.paginationPreviousText,M=void 0===P?"Indietro":P,O=e.paginationNextText,R=void 0===O?"Avanti":O,I=e.onPaginationChange,A=e.uniqueId,F=e.onSort,L=e.renderEmptyState,z=e.onRowClick,H=e.bodyHeight,j=e.totalPages,B=e.rowIdHighlight,U=e.rowHighlightColor,Y=e.rowSelection,V=e.onRowSelection,W=e.forceHideSettings,G=void 0!==W&&W,K=e.renderBulkActions,q=e.preSettedTableSettings,X=e.onChangeTableSettings,Z=e.notRemovableColumns,J=e.rowSize,ee=PT({columns:i,isSelectable:d,toggles:c,isTogglesSortable:m,onTogglesChange:u,rowActions:$,enableSettings:x,settingsDropdownConfig:w,preSettedTableSettings:q}),ne=function(e){var n=s(e||{left:[],right:[]});return{columnPinning:n[0],setColumnPinning:n[1]}}({right:[dD.ROW_ACTIONS]}),te=ne.columnPinning,re=ne.setColumnPinning,oe=function(e){var n=s({pageIndex:1,pageSize:e}),t=n[0];return{pageIndex:t.pageIndex,pageSize:t.pageSize,setPagination:n[1]}}(_),ie=oe.pageSize,ae=oe.pageIndex,le=oe.setPagination,se=o.useMemo((function(){return{pageIndex:ae,pageSize:ie}}),[ae,ie]),de=Q(I);l((function(){var e;null===(e=de.current)||void 0===e||e.call(de,se)}),[se,de]);var ce=a((function(){return null==Y?void 0:Y.reduce((function(e,n){var t;return Ye(Ye({},e),((t={})[n]=!0,t))}),{})}),[Y]),ue={columnVisibility:o.useMemo((function(){return(null==q?void 0:q.notVisibleColumns)?null==q?void 0:q.notVisibleColumns.reduce((function(e,n){return n&&(e[n]=!1),e}),{}):{}}),[null==q?void 0:q.notVisibleColumns])},pe=function(e){const n={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[t]=r.useState((()=>({current:oD(n)}))),[o,i]=r.useState((()=>t.current.initialState));return t.current.setOptions((n=>({...n,...e,state:{...o,...e.state},onStateChange:n=>{i(n),null==e.onStateChange||e.onStateChange(n)}}))),t.current}(Ye(Ye({data:t,columns:ee,enableSorting:h,sortDescFirst:b,getCoreRowModel:e=>yE((()=>[e.options.data]),(n=>{const t={rows:[],flatRows:[],rowsById:{}},r=function(n,o,i){void 0===o&&(o=0);const a=[];for(let s=0;s<n.length;s++){const d=iD(e,e._getRowId(n[s],s,i),n[s],s,o);var l;t.flatRows.push(d),t.rowsById[d.id]=d,a.push(d),e.options.getSubRows&&(d.originalSubRows=e.options.getSubRows(n[s],s),null!=(l=d.originalSubRows)&&l.length&&(d.subRows=r(d.originalSubRows,o+1,d)))}return a};return t.rows=r(n),t}),{key:"development"===process.env.NODE_ENV&&"getRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getSortedRowModel:e=>yE((()=>[e.getState().sorting,e.getPreSortedRowModel()]),((n,t)=>{if(!t.rows.length||null==n||!n.length)return t;const r=e.getState().sorting,o=[],i=r.filter((n=>e.getColumn(n.id).getCanSort())),a={};i.forEach((n=>{const t=e.getColumn(n.id);a[n.id]={sortUndefined:t.columnDef.sortUndefined,invertSorting:t.columnDef.invertSorting,sortingFn:t.getSortingFn()}}));const l=e=>{const n=e.slice();return n.sort(((e,n)=>{for(let r=0;r<i.length;r+=1){var t;const o=i[r],l=a[o.id],s=null!=(t=null==o?void 0:o.desc)&&t;if(l.sortUndefined){const t=void 0===e.getValue(o.id),r=void 0===n.getValue(o.id);if(t||r)return t&&r?0:t?l.sortUndefined:-l.sortUndefined}let d=l.sortingFn(e,n,o.id);if(0!==d)return s&&(d*=-1),l.invertSorting&&(d*=-1),d}return e.index-n.index})),n.forEach((e=>{o.push(e),!e.subRows||e.subRows.length<=1||(e.subRows=l(e.subRows))})),n};return{rows:l(t.rows),flatRows:o,rowsById:t.rowsById}}),{key:"development"===process.env.NODE_ENV&&"getSortedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getPaginationRowModel:e=>yE((()=>[e.getState().pagination,e.getPrePaginationRowModel(),e.options.paginateExpandedRows?void 0:e.getState().expanded]),((n,t)=>{if(!t.rows.length)return t;const{pageSize:r,pageIndex:o}=n;let{rows:i,flatRows:a,rowsById:l}=t;const s=r*o,d=s+r;let c;i=i.slice(s,d),c=e.options.paginateExpandedRows?{rows:i,flatRows:a,rowsById:l}:function(e){const n=[],t=e=>{var r;n.push(e),null!=(r=e.subRows)&&r.length&&e.getIsExpanded()&&e.subRows.forEach(t)};return e.rows.forEach(t),{rows:n,flatRows:e.flatRows,rowsById:e.rowsById}}({rows:i,flatRows:a,rowsById:l}),c.flatRows=[];const u=e=>{c.flatRows.push(e),e.subRows.length&&e.subRows.forEach(u)};return c.rows.forEach(u),c}),{key:"development"===process.env.NODE_ENV&&"getPaginationRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),pageCount:N,state:Ye({pagination:se,columnPinning:te},Y&&{rowSelection:ce()}),onColumnPinningChange:re,onPaginationChange:le,manualPagination:!0,getRowId:function(e){return String(e[A])},manualSorting:!!F},V&&{onRowSelectionChange:function(e){var n;"function"==typeof e&&V(Object.keys(e(null!==(n=ce())&&void 0!==n?n:{})))}}),{initialState:ue})),fe=pe.getHeaderGroups,me=pe.getRowModel,ge=pe.getFooterGroups,he=pe.previousPage,ve=pe.nextPage,be=pe.setPageIndex,ye=(0,pe.getIsAllRowsSelected)(),xe=!k&&L&&0===t.length;return o.createElement(ET,null,o.createElement(YD,{defaultRowSize:(null===(n=q)||void 0===n?void 0:n.dimensionRow)||J},o.createElement(DT,null,o.createElement(kT,{renderBulkActions:K,bulkBarActions:C,selectedRowData:null!=Y?Y:[],allSelectedCTA:ye?S:void 0}),o.createElement(TT,{className:"DS-ReactTable DS-rt-table"},o.createElement(z_,{headerGroup:fe(),headerSize:p,onSort:F,forceHideSettings:G,rowSelection:Y,setRowSelection:V,preSettedTableSettings:q,onChangeTableSettings:X,notRemovableColumns:Z}),xe?o.createElement(o.Fragment,null,L()):o.createElement(bT,{pageIndex:ae,rows:me().rows,rowSize:(null==q?void 0:q.dimensionRow)||J,isLoading:k,onRowClick:z,bodyHeight:H,rowIdHighlight:B,rowHighlightColor:U}),o.createElement(ST,{footerGroup:ge()}),!D&&!xe&&o.createElement(NT,null,o.createElement(xC,{changePageAction:function(e){return be(e)},nextPageAction:ve,prevPageAction:he,nextText:R,prevText:M,listSize:N||t.length,totalPages:j,pageSize:ie,currentPage:ae}))))))},B_=w.div(f_||(f_=Xe(["\n width: 90vw;\n margin: 0 auto;\n text-align: center;\n @media screen and (min-width: 768px) {\n width: 376px;\n }\n .icon {\n background-color: ",";\n width: 176px;\n height: 176px;\n border-radius: 50%;\n color: ",";\n margin: 0 auto;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 76px;\n }\n h5 {\n margin-top: 2rem;\n margin-bottom: 0;\n font-weight: 500;\n font-size: 20px;\n line-height: 30px;\n color: ",";\n }\n p {\n margin-top: 0.5rem;\n margin-bottom: 1.5rem;\n font-weight: 400;\n font-size: 14px;\n line-height: 21px;\n color: ",";\n }\n"],["\n width: 90vw;\n margin: 0 auto;\n text-align: center;\n @media screen and (min-width: 768px) {\n width: 376px;\n }\n .icon {\n background-color: ",";\n width: 176px;\n height: 176px;\n border-radius: 50%;\n color: ",";\n margin: 0 auto;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 76px;\n }\n h5 {\n margin-top: 2rem;\n margin-bottom: 0;\n font-weight: 500;\n font-size: 20px;\n line-height: 30px;\n color: ",";\n }\n p {\n margin-top: 0.5rem;\n margin-bottom: 1.5rem;\n font-weight: 400;\n font-size: 14px;\n line-height: 21px;\n color: ",";\n }\n"])),(function(e){return e.theme.palette.red[50]}),(function(e){return e.theme.palette.red[500]}),(function(e){return e.theme.palette.black[100]}),(function(e){return e.theme.palette.black[80]})),U_=function(e){var n=e.action,t=e.icon,r=e.text,a=e.title,l=i((function(){return n?o.createElement(_r,{onClick:function(){return n.action()},iconLeft:n.icon?n.icon:void 0,text:n.text,color:"green"}):null}),[n]);return o.createElement(B_,null,t&&o.createElement("div",{className:"icon"},o.createElement(cn,Ye({},t))),a&&o.createElement("h5",null,a),r&&o.createElement("p",null,r),l)},Y_=w.span(m_||(m_=Xe(["\n background: ",";\n width: 100%;\n height: 4px;\n margin-top: 6px;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"],["\n background: ",";\n width: 100%;\n height: 4px;\n margin-top: 6px;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"])),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:"transparent"}),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[500]}),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[900]})),V_=w.span(g_||(g_=Xe(["\n font-family: 'Inter UI', sans-serif;\n font-style: normal;\n font-size: 14px;\n font-weight: 500;\n line-height: 21px;\n\n align-items: center;\n display: flex;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"],["\n font-family: 'Inter UI', sans-serif;\n font-style: normal;\n font-size: 14px;\n font-weight: 500;\n line-height: 21px;\n\n align-items: center;\n display: flex;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"])),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[500]}),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[900]})),W_=function(e){var n=e.active,t=e.handleClick,r=e.tabRef,i=e.text,a=e.tooltip,l=e.badge,s=o.createElement(G_,{ref:null==r?void 0:r(),onClick:t},o.createElement(K_,Ye({className:"item-badge",isDisabled:!0},l),o.createElement(V_,{active:n},i)),o.createElement(Y_,{active:n}));return a?o.createElement(xl,Ye({},a),s):s},G_=w.div(h_||(h_=Xe(["\n cursor: pointer;\n flex-shrink: 0;\n position: relative;\n padding: 0;\n display: flex;\n flex-direction: column;\n"],["\n cursor: pointer;\n flex-shrink: 0;\n position: relative;\n padding: 0;\n display: flex;\n flex-direction: column;\n"]))),K_=w(sy)(v_||(v_=Xe(["\n height: 8px;\n min-width: 8px;\n"],["\n height: 8px;\n min-width: 8px;\n"]))),q_=w.div(y_||(y_=Xe(["\n box-sizing: border-box;\n height: 31px;\n alignment-baseline: baseline;\n display: flex;\n white-space: nowrap;\n margin-top: 3px;\n width: 100%;\n\n ",";\n\n & > *:first-child {\n padding-left: ","px;\n }\n\n & > *:last-child {\n padding-right: ","px;\n }\n\n & > * + * {\n margin-left: ","px;\n }\n"],["\n box-sizing: border-box;\n height: 31px;\n alignment-baseline: baseline;\n display: flex;\n white-space: nowrap;\n margin-top: 3px;\n width: 100%;\n\n ",";\n\n & > *:first-child {\n padding-left: ","px;\n }\n\n & > *:last-child {\n padding-right: ","px;\n }\n\n & > * + * {\n margin-left: ","px;\n }\n"])),(function(e){return e.hidden&&C(b_||(b_=Xe(["\n visibility: hidden;\n position: absolute;\n "],["\n visibility: hidden;\n position: absolute;\n "])))}),(function(e){return e.lateralPadding}),(function(e){return e.lateralPadding}),(function(e){return e.distance})),X_=w(q_)(x_||(x_=Xe(["\n max-width: 100%;\n overflow-x: auto;\n overflow-y: hidden;\n"],["\n max-width: 100%;\n overflow-x: auto;\n overflow-y: hidden;\n"]))),Q_=function(e){var n=e.active;return o.createElement(W_,{active:n,text:o.createElement(Z_,{icon:ue,fixedWidth:!0})})},Z_=w(cn)(w_||(w_=Xe(["\n height: 21px;\n"],["\n height: 21px;\n"]))),J_=function(e){var n=e.active,t=e.tabs,r=a((function(){return o.createElement(Q_,{active:n})}),[n]),i=a((function(e){return o.createElement(o.Fragment,null,t.map((function(n,t){var r=n.active,i=n.handleClick,a=n.text;return o.createElement(zr.Item,{key:t,text:a,active:r,onClick:function(){i&&i(),e()}})})))}),[t]);return o.createElement(eN,{placement:"bottom-end",fullWidth:!0,renderTrigger:r,renderContent:i})},eN=w(zr)($_||($_=Xe(["\n display: block;\n"],["\n display: block;\n"]))),nN=function(e){var n=e.className,t=e.distance,r=void 0===t?15:t,a=e.lateralPadding,l=void 0===a?23:a,d=e.tabs,c=function(){var e=Z(),n=e[0],t=e[1].width,r=s(0),o=r[0],i=r[1];return J((function(){return i(t)}),250,[t]),{elementsWrapperRef:n,wrapperWidth:o}}(),u=c.elementsWrapperRef,p=c.wrapperWidth,f=s(0)[1],m=d.length,g=i((function(){return Array.from(Array(m),(function(){return o.createRef()}))}),[m]),h=i((function(){return g.map((function(e){return function(){return f((function(e){return e+1})),e}}))}),[g]),v=function(e){var n=e.distance,t=e.lateralPadding,r=e.tabsLength,o=e.tabsRefs,a=e.wrapperWidth;return i((function(){for(var e,i=0,l=a-2*t;i!==r&&l>0;){var s=null===(e=o[i].current)||void 0===e?void 0:e.offsetWidth;s&&l-(s+n)>0?(i++,l-=s+n):l=-1}return{visibleCount:i}}),[n,t,r,o,a])}({distance:r,tabsLength:m,wrapperWidth:p,tabsRefs:g,lateralPadding:l}).visibleCount,b=i((function(){return d.map((function(e,n){return o.createElement(W_,Ye({key:n,tabRef:h[n]},e))}))}),[h,d]),y=i((function(){return d.slice(0,v).map((function(e,n){return o.createElement(W_,Ye({key:n},e))}))}),[d,v]),x=i((function(){return d.slice(v)}),[d,v]),w=0!==x.length,$=x.some((function(e){return e.active})),C=0===p;return o.createElement(o.Fragment,null,o.createElement(tN,{className:n,distance:r,lateralPadding:l,hidden:!C},b),o.createElement(q_,{className:n,distance:r,lateralPadding:l,hidden:C,ref:u},y,w&&o.createElement(J_,{active:$,tabs:x})))},tN=w(X_)(C_||(C_=Xe(["\n overflow-x: hidden;\n"],["\n overflow-x: hidden;\n"]))),rN=function(e){var n=e.className,t=e.distance,r=void 0===t?15:t,a=e.lateralPadding,l=void 0===a?23:a,s=e.tabs,d=i((function(){return s.map((function(e,n){return o.createElement(W_,Ye({key:n},e))}))}),[s]);return o.createElement(X_,{className:n,distance:r,lateralPadding:l},d)},oN=function(e){var n=e.children,t=e.theme;return o.createElement(S,{theme:t},o.createElement(o.Fragment,null,n))};export{zu as Accordion,ul as AsyncCreatableSelect,cl as AsyncSelect,or as Avatar,$b as Badge,Yb as BadgeSize,rb as BadgeType,Pb as Banner,xb as BannerType,gu as Body,_r as Button,ku as Caption,Fb as Card,Db as CardColor,Tb as CardElevation,Eb as CardType,Zu as Checkbox,Ou as CheckboxStatus,Xb as Chip,Ib as ChipType,sD as ColumnDefType,mE as ConfirmationModal,dl as CreatableSelect,jg as DatePicker,Uu as Drawer,zr as Dropdown,nN as DropdownTabs,Xl as EditableInput,av as FileUploader,Vb as FloatingBadgeType,Uv as GroupedList,Cu as Headline,cn as Icon,an as IconBackground,Nr as IconButton,gb as InlineMessage,Cv as InlineMessageType,Gr as InputCode,gn as InputHelper,ml as InputTelephone,kl as InputText,vb as MicroTag,VS as Modal,RS as ModalBody,WS as ModalSearchable,j_ as NewTable,ay as NotificationBadge,U_ as PageEmptySet,xC as Pagination,A$ as PaginationType,WC as ProgressBar,F$ as ProgressBarType,Tv as Radio,Mv as RadioGroup,Xh as RadioStatus,rN as ScrollableTabs,XC as SegmentButton,sl as Select,yk as ShortcutTip,Fw as SidebarBadgeConfigType,Gw as SidebarItem,fn as Spinner,ZS as StepModal,rE as StepModalBody,oE as StepModalFooter,iE as StepModalHeader,ok as Stepper,gC as Table,ck as Tag,Bl as TextArea,oN as ThemeProvider,vk as Tip,UC as TipType,vu as Title1,bu as Title2,yu as Title3,xu as Title4,wu as Title5,$u as Title6,DS as Toast,gk as ToastType,xl as Tooltip,sy as WithBadge,Dt as autocompleteYellow,tl as isSimpleValue,Bw as sidebarItemHeight,Lg as timeConversionOptions,TS as toastPalette,np as useCheckboxValue,Bg as useFormattedDate,Sv as useRadioValue,Fa as useSelectMultiValues,Ia as useSelectSimpleValue,Aa as useSelectValue,Kw as useTableValues};
55
+ function hE(e,n){return"function"==typeof e?e(n):e}function vE(e,n){return t=>{n.setState((n=>({...n,[e]:hE(t,n[e])})))}}function bE(e){return e instanceof Function}function yE(e,n,t){let r,o=[];return()=>{let i;t.key&&t.debug&&(i=Date.now());const a=e();if(!(a.length!==o.length||a.some(((e,n)=>o[n]!==e))))return r;let l;if(o=a,t.key&&t.debug&&(l=Date.now()),r=n(...a),null==t||null==t.onChange||t.onChange(r),t.key&&t.debug&&null!=t&&t.debug()){const e=Math.round(100*(Date.now()-i))/100,n=Math.round(100*(Date.now()-l))/100,r=n/16,o=(e,n)=>{for(e=String(e);e.length<n;)e=" "+e;return e};console.info("%c⏱ "+o(n,5)+" /"+o(e,5)+" ms","\n font-size: .6rem;\n font-weight: bold;\n color: hsl("+Math.max(0,Math.min(120-120*r,120))+"deg 100% 31%);",null==t?void 0:t.key)}return r}}function xE(e,n,t){var r;let o={id:null!=(r=t.id)?r:n.id,column:n,index:t.index,isPlaceholder:!!t.isPlaceholder,placeholderId:t.placeholderId,depth:t.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const e=[],n=t=>{t.subHeaders&&t.subHeaders.length&&t.subHeaders.map(n),e.push(t)};return n(o),e},getContext:()=>({table:e,header:o,column:n})};return e._features.forEach((n=>{Object.assign(o,null==n.createHeader?void 0:n.createHeader(o,e))})),o}const wE={createTable:e=>({getHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((n,t,r,o)=>{var i,a;const l=null!=(i=null==r?void 0:r.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?i:[],s=null!=(a=null==o?void 0:o.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?a:[];return $E(n,[...l,...t.filter((e=>!(null!=r&&r.includes(e.id)||null!=o&&o.includes(e.id)))),...s],e)}),{key:"development"===process.env.NODE_ENV&&"getHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((n,t,r,o)=>$E(n,t=t.filter((e=>!(null!=r&&r.includes(e.id)||null!=o&&o.includes(e.id)))),e,"center")),{key:"development"===process.env.NODE_ENV&&"getCenterHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left]),((n,t,r)=>{var o;const i=null!=(o=null==r?void 0:r.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?o:[];return $E(n,i,e,"left")}),{key:"development"===process.env.NODE_ENV&&"getLeftHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightHeaderGroups:yE((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right]),((n,t,r)=>{var o;const i=null!=(o=null==r?void 0:r.map((e=>t.find((n=>n.id===e)))).filter(Boolean))?o:[];return $E(n,i,e,"right")}),{key:"development"===process.env.NODE_ENV&&"getRightHeaderGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getFooterGroups:yE((()=>[e.getHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftFooterGroups:yE((()=>[e.getLeftHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getLeftFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterFooterGroups:yE((()=>[e.getCenterHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getCenterFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightFooterGroups:yE((()=>[e.getRightHeaderGroups()]),(e=>[...e].reverse()),{key:"development"===process.env.NODE_ENV&&"getRightFooterGroups",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getFlatHeaders:yE((()=>[e.getHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftFlatHeaders:yE((()=>[e.getLeftHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getLeftFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterFlatHeaders:yE((()=>[e.getCenterHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getCenterFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightFlatHeaders:yE((()=>[e.getRightHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),{key:"development"===process.env.NODE_ENV&&"getRightFlatHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getCenterLeafHeaders:yE((()=>[e.getCenterFlatHeaders()]),(e=>e.filter((e=>{var n;return!(null!=(n=e.subHeaders)&&n.length)}))),{key:"development"===process.env.NODE_ENV&&"getCenterLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeftLeafHeaders:yE((()=>[e.getLeftFlatHeaders()]),(e=>e.filter((e=>{var n;return!(null!=(n=e.subHeaders)&&n.length)}))),{key:"development"===process.env.NODE_ENV&&"getLeftLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getRightLeafHeaders:yE((()=>[e.getRightFlatHeaders()]),(e=>e.filter((e=>{var n;return!(null!=(n=e.subHeaders)&&n.length)}))),{key:"development"===process.env.NODE_ENV&&"getRightLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}}),getLeafHeaders:yE((()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()]),((e,n,t)=>{var r,o,i,a,l,s;return[...null!=(r=null==(o=e[0])?void 0:o.headers)?r:[],...null!=(i=null==(a=n[0])?void 0:a.headers)?i:[],...null!=(l=null==(s=t[0])?void 0:s.headers)?l:[]].map((e=>e.getLeafHeaders())).flat()}),{key:"development"===process.env.NODE_ENV&&"getLeafHeaders",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugHeaders}})})};function $E(e,n,t,r){var o,i;let a=0;const l=function(e,n){void 0===n&&(n=1),a=Math.max(a,n),e.filter((e=>e.getIsVisible())).forEach((e=>{var t;null!=(t=e.columns)&&t.length&&l(e.columns,n+1)}),0)};l(e);let s=[];const d=(e,n)=>{const o={depth:n,id:[r,""+n].filter(Boolean).join("_"),headers:[]},i=[];e.forEach((e=>{const a=[...i].reverse()[0];let l,s=!1;if(e.column.depth===o.depth&&e.column.parent?l=e.column.parent:(l=e.column,s=!0),a&&(null==a?void 0:a.column)===l)a.subHeaders.push(e);else{const o=xE(t,l,{id:[r,n,l.id,null==e?void 0:e.id].filter(Boolean).join("_"),isPlaceholder:s,placeholderId:s?""+i.filter((e=>e.column===l)).length:void 0,depth:n,index:i.length});o.subHeaders.push(e),i.push(o)}o.headers.push(e),e.headerGroup=o})),s.push(o),n>0&&d(i,n-1)},c=n.map(((e,n)=>xE(t,e,{depth:a,index:n})));d(c,a-1),s.reverse();const u=e=>e.filter((e=>e.column.getIsVisible())).map((e=>{let n=0,t=0,r=[0];e.subHeaders&&e.subHeaders.length?(r=[],u(e.subHeaders).forEach((e=>{let{colSpan:t,rowSpan:o}=e;n+=t,r.push(o)}))):n=1;return t+=Math.min(...r),e.colSpan=n,e.rowSpan=t,{colSpan:n,rowSpan:t}}));return u(null!=(o=null==(i=s[0])?void 0:i.headers)?o:[]),s}const CE={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},kE={getDefaultColumnDef:()=>CE,getInitialState:e=>({columnSizing:{},columnSizingInfo:{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]},...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",onColumnSizingChange:vE("columnSizing",e),onColumnSizingInfoChange:vE("columnSizingInfo",e)}),createColumn:(e,n)=>({getSize:()=>{var t,r,o;const i=n.getState().columnSizing[e.id];return Math.min(Math.max(null!=(t=e.columnDef.minSize)?t:CE.minSize,null!=(r=null!=i?i:e.columnDef.size)?r:CE.size),null!=(o=e.columnDef.maxSize)?o:CE.maxSize)},getStart:t=>{const r=t?"left"===t?n.getLeftVisibleLeafColumns():n.getRightVisibleLeafColumns():n.getVisibleLeafColumns(),o=r.findIndex((n=>n.id===e.id));if(o>0){const e=r[o-1];return e.getStart(t)+e.getSize()}return 0},resetSize:()=>{n.setColumnSizing((n=>{let{[e.id]:t,...r}=n;return r}))},getCanResize:()=>{var t,r;return(null==(t=e.columnDef.enableResizing)||t)&&(null==(r=n.options.enableColumnResizing)||r)},getIsResizing:()=>n.getState().columnSizingInfo.isResizingColumn===e.id}),createHeader:(e,n)=>({getSize:()=>{let n=0;const t=e=>{var r;e.subHeaders.length?e.subHeaders.forEach(t):n+=null!=(r=e.column.getSize())?r:0};return t(e),n},getStart:()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},getResizeHandler:()=>{const t=n.getColumn(e.column.id),r=t.getCanResize();return o=>{if(!r)return;if(null==o.persist||o.persist(),EE(o)&&o.touches&&o.touches.length>1)return;const i=e.getSize(),a=e?e.getLeafHeaders().map((e=>[e.column.id,e.column.getSize()])):[[t.id,t.getSize()]],l=EE(o)?Math.round(o.touches[0].clientX):o.clientX,s=(e,t)=>{if("number"!=typeof t)return;let r={};n.setColumnSizingInfo((e=>{var n,o;const i=t-(null!=(n=null==e?void 0:e.startOffset)?n:0),a=Math.max(i/(null!=(o=null==e?void 0:e.startSize)?o:0),-.999999);return e.columnSizingStart.forEach((e=>{let[n,t]=e;r[n]=Math.round(100*Math.max(t+t*a,0))/100})),{...e,deltaOffset:i,deltaPercentage:a}})),"onChange"!==n.options.columnResizeMode&&"end"!==e||n.setColumnSizing((e=>({...e,...r})))},d={moveHandler:e=>{return n=e.clientX,s("move",n);var n},upHandler:e=>{var t;document.removeEventListener("mousemove",d.moveHandler),document.removeEventListener("mouseup",d.upHandler),t=e.clientX,s("end",t),n.setColumnSizingInfo((e=>({...e,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]})))}},c=!!function(){if("boolean"==typeof SE)return SE;let e=!1;try{const n={get passive(){return e=!0,!1}},t=()=>{};window.addEventListener("test",t,n),window.removeEventListener("test",t)}catch(n){e=!1}return SE=e,SE}()&&{passive:!1};EE(o)||(document.addEventListener("mousemove",d.moveHandler,c),document.addEventListener("mouseup",d.upHandler,c)),n.setColumnSizingInfo((e=>({...e,startOffset:l,startSize:i,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:t.id})))}}}),createTable:e=>({setColumnSizing:n=>null==e.options.onColumnSizingChange?void 0:e.options.onColumnSizingChange(n),setColumnSizingInfo:n=>null==e.options.onColumnSizingInfoChange?void 0:e.options.onColumnSizingInfoChange(n),resetColumnSizing:n=>{var t;e.setColumnSizing(n?{}:null!=(t=e.initialState.columnSizing)?t:{})},resetHeaderSizeInfo:n=>{var t;e.setColumnSizingInfo(n?{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}:null!=(t=e.initialState.columnSizingInfo)?t:{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]})},getTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0},getLeftTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getLeftHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0},getCenterTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getCenterHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0},getRightTotalSize:()=>{var n,t;return null!=(n=null==(t=e.getRightHeaderGroups()[0])?void 0:t.headers.reduce(((e,n)=>e+n.getSize()),0))?n:0}})};let SE=null;function EE(e){return"touchstart"===e.type}const DE={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:vE("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let n=!1,t=!1;return{_autoResetExpanded:()=>{var r,o;if(n){if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetExpanded)?r:!e.options.manualExpanding){if(t)return;t=!0,e._queue((()=>{e.resetExpanded(),t=!1}))}}else e._queue((()=>{n=!0}))},setExpanded:n=>null==e.options.onExpandedChange?void 0:e.options.onExpandedChange(n),toggleAllRowsExpanded:n=>{(null!=n?n:!e.getIsAllRowsExpanded())?e.setExpanded(!0):e.setExpanded({})},resetExpanded:n=>{var t,r;e.setExpanded(n?{}:null!=(t=null==(r=e.initialState)?void 0:r.expanded)?t:{})},getCanSomeRowsExpand:()=>e.getRowModel().flatRows.some((e=>e.getCanExpand())),getToggleAllRowsExpandedHandler:()=>n=>{null==n.persist||n.persist(),e.toggleAllRowsExpanded()},getIsSomeRowsExpanded:()=>{const n=e.getState().expanded;return!0===n||Object.values(n).some(Boolean)},getIsAllRowsExpanded:()=>{const n=e.getState().expanded;return"boolean"==typeof n?!0===n:!!Object.keys(n).length&&!e.getRowModel().flatRows.some((e=>e.getIsExpanded()))},getExpandedDepth:()=>{let n=0;return(!0===e.getState().expanded?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach((e=>{const t=e.split(".");n=Math.max(n,t.length)})),n},getPreExpandedRowModel:()=>e.getSortedRowModel(),getExpandedRowModel:()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())}},createRow:(e,n)=>({toggleExpanded:t=>{n.setExpanded((r=>{var o;const i=!0===r||!(null==r||!r[e.id]);let a={};if(!0===r?Object.keys(n.getRowModel().rowsById).forEach((e=>{a[e]=!0})):a=r,t=null!=(o=t)?o:!i,!i&&t)return{...a,[e.id]:!0};if(i&&!t){const{[e.id]:n,...t}=a;return t}return r}))},getIsExpanded:()=>{var t;const r=n.getState().expanded;return!!(null!=(t=null==n.options.getIsRowExpanded?void 0:n.options.getIsRowExpanded(e))?t:!0===r||(null==r?void 0:r[e.id]))},getCanExpand:()=>{var t,r,o;return null!=(t=null==n.options.getRowCanExpand?void 0:n.options.getRowCanExpand(e))?t:(null==(r=n.options.enableExpanding)||r)&&!(null==(o=e.subRows)||!o.length)},getToggleExpandedHandler:()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}})},TE=(e,n,t)=>{var r;const o=t.toLowerCase();return null==(r=e.getValue(n))?void 0:r.toLowerCase().includes(o)};TE.autoRemove=e=>LE(e);const _E=(e,n,t)=>{var r;return null==(r=e.getValue(n))?void 0:r.includes(t)};_E.autoRemove=e=>LE(e);const NE=(e,n,t)=>{var r;return(null==(r=e.getValue(n))?void 0:r.toLowerCase())===t.toLowerCase()};NE.autoRemove=e=>LE(e);const PE=(e,n,t)=>{var r;return null==(r=e.getValue(n))?void 0:r.includes(t)};PE.autoRemove=e=>LE(e)||!(null!=e&&e.length);const ME=(e,n,t)=>!t.some((t=>{var r;return!(null!=(r=e.getValue(n))&&r.includes(t))}));ME.autoRemove=e=>LE(e)||!(null!=e&&e.length);const OE=(e,n,t)=>t.some((t=>{var r;return null==(r=e.getValue(n))?void 0:r.includes(t)}));OE.autoRemove=e=>LE(e)||!(null!=e&&e.length);const RE=(e,n,t)=>e.getValue(n)===t;RE.autoRemove=e=>LE(e);const IE=(e,n,t)=>e.getValue(n)==t;IE.autoRemove=e=>LE(e);const AE=(e,n,t)=>{let[r,o]=t;const i=e.getValue(n);return i>=r&&i<=o};AE.resolveFilterValue=e=>{let[n,t]=e,r="number"!=typeof n?parseFloat(n):n,o="number"!=typeof t?parseFloat(t):t,i=null===n||Number.isNaN(r)?-1/0:r,a=null===t||Number.isNaN(o)?1/0:o;if(i>a){const e=i;i=a,a=e}return[i,a]},AE.autoRemove=e=>LE(e)||LE(e[0])&&LE(e[1]);const FE={includesString:TE,includesStringSensitive:_E,equalsString:NE,arrIncludes:PE,arrIncludesAll:ME,arrIncludesSome:OE,equals:RE,weakEquals:IE,inNumberRange:AE};function LE(e){return null==e||""===e}const zE={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],globalFilter:void 0,...e}),getDefaultOptions:e=>({onColumnFiltersChange:vE("columnFilters",e),onGlobalFilterChange:vE("globalFilter",e),filterFromLeafRows:!1,globalFilterFn:"auto",getColumnCanGlobalFilter:n=>{var t,r;const o=null==(t=e.getCoreRowModel().flatRows[0])||null==(r=t._getAllCellsByColumnId()[n.id])?void 0:r.getValue();return"string"==typeof o||"number"==typeof o}}),createColumn:(e,n)=>({getAutoFilterFn:()=>{const t=n.getCoreRowModel().flatRows[0],r=null==t?void 0:t.getValue(e.id);return"string"==typeof r?FE.includesString:"number"==typeof r?FE.inNumberRange:"boolean"==typeof r||null!==r&&"object"==typeof r?FE.equals:Array.isArray(r)?FE.arrIncludes:FE.weakEquals},getFilterFn:()=>{var t,r;return bE(e.columnDef.filterFn)?e.columnDef.filterFn:"auto"===e.columnDef.filterFn?e.getAutoFilterFn():null!=(t=null==(r=n.options.filterFns)?void 0:r[e.columnDef.filterFn])?t:FE[e.columnDef.filterFn]},getCanFilter:()=>{var t,r,o;return(null==(t=e.columnDef.enableColumnFilter)||t)&&(null==(r=n.options.enableColumnFilters)||r)&&(null==(o=n.options.enableFilters)||o)&&!!e.accessorFn},getCanGlobalFilter:()=>{var t,r,o,i;return(null==(t=e.columnDef.enableGlobalFilter)||t)&&(null==(r=n.options.enableGlobalFilter)||r)&&(null==(o=n.options.enableFilters)||o)&&(null==(i=null==n.options.getColumnCanGlobalFilter?void 0:n.options.getColumnCanGlobalFilter(e))||i)&&!!e.accessorFn},getIsFiltered:()=>e.getFilterIndex()>-1,getFilterValue:()=>{var t,r;return null==(t=n.getState().columnFilters)||null==(r=t.find((n=>n.id===e.id)))?void 0:r.value},getFilterIndex:()=>{var t,r;return null!=(t=null==(r=n.getState().columnFilters)?void 0:r.findIndex((n=>n.id===e.id)))?t:-1},setFilterValue:t=>{n.setColumnFilters((n=>{const r=e.getFilterFn(),o=null==n?void 0:n.find((n=>n.id===e.id)),i=hE(t,o?o.value:void 0);var a;if(HE(r,i,e))return null!=(a=null==n?void 0:n.filter((n=>n.id!==e.id)))?a:[];const l={id:e.id,value:i};var s;return o?null!=(s=null==n?void 0:n.map((n=>n.id===e.id?l:n)))?s:[]:null!=n&&n.length?[...n,l]:[l]}))},_getFacetedRowModel:n.options.getFacetedRowModel&&n.options.getFacetedRowModel(n,e.id),getFacetedRowModel:()=>e._getFacetedRowModel?e._getFacetedRowModel():n.getPreFilteredRowModel(),_getFacetedUniqueValues:n.options.getFacetedUniqueValues&&n.options.getFacetedUniqueValues(n,e.id),getFacetedUniqueValues:()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,_getFacetedMinMaxValues:n.options.getFacetedMinMaxValues&&n.options.getFacetedMinMaxValues(n,e.id),getFacetedMinMaxValues:()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}),createRow:(e,n)=>({columnFilters:{},columnFiltersMeta:{}}),createTable:e=>({getGlobalAutoFilterFn:()=>FE.includesString,getGlobalFilterFn:()=>{var n,t;const{globalFilterFn:r}=e.options;return bE(r)?r:"auto"===r?e.getGlobalAutoFilterFn():null!=(n=null==(t=e.options.filterFns)?void 0:t[r])?n:FE[r]},setColumnFilters:n=>{const t=e.getAllLeafColumns();null==e.options.onColumnFiltersChange||e.options.onColumnFiltersChange((e=>{var r;return null==(r=hE(n,e))?void 0:r.filter((e=>{const n=t.find((n=>n.id===e.id));if(n){if(HE(n.getFilterFn(),e.value,n))return!1}return!0}))}))},setGlobalFilter:n=>{null==e.options.onGlobalFilterChange||e.options.onGlobalFilterChange(n)},resetGlobalFilter:n=>{e.setGlobalFilter(n?void 0:e.initialState.globalFilter)},resetColumnFilters:n=>{var t,r;e.setColumnFilters(n?[]:null!=(t=null==(r=e.initialState)?void 0:r.columnFilters)?t:[])},getPreFilteredRowModel:()=>e.getCoreRowModel(),getFilteredRowModel:()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel()),_getGlobalFacetedRowModel:e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),getGlobalFacetedRowModel:()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),_getGlobalFacetedUniqueValues:e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),getGlobalFacetedUniqueValues:()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,_getGlobalFacetedMinMaxValues:e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),getGlobalFacetedMinMaxValues:()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}})};function HE(e,n,t){return!(!e||!e.autoRemove)&&e.autoRemove(n,t)||void 0===n||"string"==typeof n&&!n}const jE={sum:(e,n,t)=>t.reduce(((n,t)=>{const r=t.getValue(e);return n+("number"==typeof r?r:0)}),0),min:(e,n,t)=>{let r;return t.forEach((n=>{const t=n.getValue(e);null!=t&&(r>t||void 0===r&&t>=t)&&(r=t)})),r},max:(e,n,t)=>{let r;return t.forEach((n=>{const t=n.getValue(e);null!=t&&(r<t||void 0===r&&t>=t)&&(r=t)})),r},extent:(e,n,t)=>{let r,o;return t.forEach((n=>{const t=n.getValue(e);null!=t&&(void 0===r?t>=t&&(r=o=t):(r>t&&(r=t),o<t&&(o=t)))})),[r,o]},mean:(e,n)=>{let t=0,r=0;if(n.forEach((n=>{let o=n.getValue(e);null!=o&&(o=+o)>=o&&(++t,r+=o)})),t)return r/t},median:(e,n)=>{if(!n.length)return;let t=0,r=0;return n.forEach((n=>{let o=n.getValue(e);"number"==typeof o&&(t=Math.min(t,o),r=Math.max(r,o))})),(t+r)/2},unique:(e,n)=>Array.from(new Set(n.map((n=>n.getValue(e)))).values()),uniqueCount:(e,n)=>new Set(n.map((n=>n.getValue(e)))).size,count:(e,n)=>n.length},BE={getDefaultColumnDef:()=>({aggregatedCell:e=>{var n,t;return null!=(n=null==(t=e.getValue())||null==t.toString?void 0:t.toString())?n:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:vE("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,n)=>({toggleGrouping:()=>{n.setGrouping((n=>null!=n&&n.includes(e.id)?n.filter((n=>n!==e.id)):[...null!=n?n:[],e.id]))},getCanGroup:()=>{var t,r,o,i;return null!=(t=null==(r=null!=(o=null==(i=e.columnDef.enableGrouping)||i)?o:n.options.enableGrouping)||r)?t:!!e.accessorFn},getIsGrouped:()=>{var t;return null==(t=n.getState().grouping)?void 0:t.includes(e.id)},getGroupedIndex:()=>{var t;return null==(t=n.getState().grouping)?void 0:t.indexOf(e.id)},getToggleGroupingHandler:()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},getAutoAggregationFn:()=>{const t=n.getCoreRowModel().flatRows[0],r=null==t?void 0:t.getValue(e.id);return"number"==typeof r?jE.sum:"[object Date]"===Object.prototype.toString.call(r)?jE.extent:void 0},getAggregationFn:()=>{var t,r;if(!e)throw new Error;return bE(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:"auto"===e.columnDef.aggregationFn?e.getAutoAggregationFn():null!=(t=null==(r=n.options.aggregationFns)?void 0:r[e.columnDef.aggregationFn])?t:jE[e.columnDef.aggregationFn]}}),createTable:e=>({setGrouping:n=>null==e.options.onGroupingChange?void 0:e.options.onGroupingChange(n),resetGrouping:n=>{var t,r;e.setGrouping(n?[]:null!=(t=null==(r=e.initialState)?void 0:r.grouping)?t:[])},getPreGroupedRowModel:()=>e.getFilteredRowModel(),getGroupedRowModel:()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())}),createRow:e=>({getIsGrouped:()=>!!e.groupingColumnId,_groupingValuesCache:{}}),createCell:(e,n,t,r)=>({getIsGrouped:()=>n.getIsGrouped()&&n.id===t.groupingColumnId,getIsPlaceholder:()=>!e.getIsGrouped()&&n.getIsGrouped(),getIsAggregated:()=>{var n;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!(null==(n=t.subRows)||!n.length)}})};const UE={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:vE("columnOrder",e)}),createTable:e=>({setColumnOrder:n=>null==e.options.onColumnOrderChange?void 0:e.options.onColumnOrderChange(n),resetColumnOrder:n=>{var t;e.setColumnOrder(n?[]:null!=(t=e.initialState.columnOrder)?t:[])},_getOrderColumnsFn:yE((()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode]),((e,n,t)=>r=>{let o=[];if(null!=e&&e.length){const n=[...e],t=[...r];for(;t.length&&n.length;){const e=n.shift(),r=t.findIndex((n=>n.id===e));r>-1&&o.push(t.splice(r,1)[0])}o=[...o,...t]}else o=r;return function(e,n,t){if(null==n||!n.length||!t)return e;const r=e.filter((e=>!n.includes(e.id)));if("remove"===t)return r;const o=n.map((n=>e.find((e=>e.id===n)))).filter(Boolean);return[...o,...r]}(o,n,t)}),{key:"development"===process.env.NODE_ENV&&"getOrderColumnsFn"})})},YE={getInitialState:e=>({columnPinning:{left:[],right:[]},...e}),getDefaultOptions:e=>({onColumnPinningChange:vE("columnPinning",e)}),createColumn:(e,n)=>({pin:t=>{const r=e.getLeafColumns().map((e=>e.id)).filter(Boolean);n.setColumnPinning((e=>{var n,o,i,a,l,s;return"right"===t?{left:(null!=(i=null==e?void 0:e.left)?i:[]).filter((e=>!(null!=r&&r.includes(e)))),right:[...(null!=(a=null==e?void 0:e.right)?a:[]).filter((e=>!(null!=r&&r.includes(e)))),...r]}:"left"===t?{left:[...(null!=(l=null==e?void 0:e.left)?l:[]).filter((e=>!(null!=r&&r.includes(e)))),...r],right:(null!=(s=null==e?void 0:e.right)?s:[]).filter((e=>!(null!=r&&r.includes(e))))}:{left:(null!=(n=null==e?void 0:e.left)?n:[]).filter((e=>!(null!=r&&r.includes(e)))),right:(null!=(o=null==e?void 0:e.right)?o:[]).filter((e=>!(null!=r&&r.includes(e))))}}))},getCanPin:()=>e.getLeafColumns().some((e=>{var t,r;return(null==(t=e.columnDef.enablePinning)||t)&&(null==(r=n.options.enablePinning)||r)})),getIsPinned:()=>{const t=e.getLeafColumns().map((e=>e.id)),{left:r,right:o}=n.getState().columnPinning,i=t.some((e=>null==r?void 0:r.includes(e))),a=t.some((e=>null==o?void 0:o.includes(e)));return i?"left":!!a&&"right"},getPinnedIndex:()=>{var t,r,o;const i=e.getIsPinned();return i?null!=(t=null==(r=n.getState().columnPinning)||null==(o=r[i])?void 0:o.indexOf(e.id))?t:-1:0}}),createRow:(e,n)=>({getCenterVisibleCells:yE((()=>[e._getAllVisibleCells(),n.getState().columnPinning.left,n.getState().columnPinning.right]),((e,n,t)=>{const r=[...null!=n?n:[],...null!=t?t:[]];return e.filter((e=>!r.includes(e.column.id)))}),{key:"production"===process.env.NODE_ENV&&"row.getCenterVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}}),getLeftVisibleCells:yE((()=>[e._getAllVisibleCells(),n.getState().columnPinning.left,,]),((e,n)=>{const t=(null!=n?n:[]).map((n=>e.find((e=>e.column.id===n)))).filter(Boolean).map((e=>({...e,position:"left"})));return t}),{key:"production"===process.env.NODE_ENV&&"row.getLeftVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}}),getRightVisibleCells:yE((()=>[e._getAllVisibleCells(),n.getState().columnPinning.right]),((e,n)=>{const t=(null!=n?n:[]).map((n=>e.find((e=>e.column.id===n)))).filter(Boolean).map((e=>({...e,position:"right"})));return t}),{key:"production"===process.env.NODE_ENV&&"row.getRightVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}})}),createTable:e=>({setColumnPinning:n=>null==e.options.onColumnPinningChange?void 0:e.options.onColumnPinningChange(n),resetColumnPinning:n=>{var t,r;return e.setColumnPinning(n?{left:[],right:[]}:null!=(t=null==(r=e.initialState)?void 0:r.columnPinning)?t:{left:[],right:[]})},getIsSomeColumnsPinned:n=>{var t;const r=e.getState().columnPinning;var o,i;return n?Boolean(null==(t=r[n])?void 0:t.length):Boolean((null==(o=r.left)?void 0:o.length)||(null==(i=r.right)?void 0:i.length))},getLeftLeafColumns:yE((()=>[e.getAllLeafColumns(),e.getState().columnPinning.left]),((e,n)=>(null!=n?n:[]).map((n=>e.find((e=>e.id===n)))).filter(Boolean)),{key:"development"===process.env.NODE_ENV&&"getLeftLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}}),getRightLeafColumns:yE((()=>[e.getAllLeafColumns(),e.getState().columnPinning.right]),((e,n)=>(null!=n?n:[]).map((n=>e.find((e=>e.id===n)))).filter(Boolean)),{key:"development"===process.env.NODE_ENV&&"getRightLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}}),getCenterLeafColumns:yE((()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((e,n,t)=>{const r=[...null!=n?n:[],...null!=t?t:[]];return e.filter((e=>!r.includes(e.id)))}),{key:"development"===process.env.NODE_ENV&&"getCenterLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}})})},VE={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:vE("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>({setRowSelection:n=>null==e.options.onRowSelectionChange?void 0:e.options.onRowSelectionChange(n),resetRowSelection:n=>{var t;return e.setRowSelection(n?{}:null!=(t=e.initialState.rowSelection)?t:{})},toggleAllRowsSelected:n=>{e.setRowSelection((t=>{n=void 0!==n?n:!e.getIsAllRowsSelected();const r={...t},o=e.getPreGroupedRowModel().flatRows;return n?o.forEach((e=>{e.getCanSelect()&&(r[e.id]=!0)})):o.forEach((e=>{delete r[e.id]})),r}))},toggleAllPageRowsSelected:n=>e.setRowSelection((t=>{const r=void 0!==n?n:!e.getIsAllPageRowsSelected(),o={...t};return e.getRowModel().rows.forEach((n=>{WE(o,n.id,r,e)})),o})),getPreSelectedRowModel:()=>e.getCoreRowModel(),getSelectedRowModel:yE((()=>[e.getState().rowSelection,e.getCoreRowModel()]),((n,t)=>Object.keys(n).length?GE(e,t):{rows:[],flatRows:[],rowsById:{}}),{key:"development"===process.env.NODE_ENV&&"getSelectedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getFilteredSelectedRowModel:yE((()=>[e.getState().rowSelection,e.getFilteredRowModel()]),((n,t)=>Object.keys(n).length?GE(e,t):{rows:[],flatRows:[],rowsById:{}}),{key:"production"===process.env.NODE_ENV&&"getFilteredSelectedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getGroupedSelectedRowModel:yE((()=>[e.getState().rowSelection,e.getSortedRowModel()]),((n,t)=>Object.keys(n).length?GE(e,t):{rows:[],flatRows:[],rowsById:{}}),{key:"production"===process.env.NODE_ENV&&"getGroupedSelectedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getIsAllRowsSelected:()=>{const n=e.getFilteredRowModel().flatRows,{rowSelection:t}=e.getState();let r=Boolean(n.length&&Object.keys(t).length);return r&&n.some((e=>e.getCanSelect()&&!t[e.id]))&&(r=!1),r},getIsAllPageRowsSelected:()=>{const n=e.getPaginationRowModel().flatRows,{rowSelection:t}=e.getState();let r=!!n.length;return r&&n.some((e=>!t[e.id]))&&(r=!1),r},getIsSomeRowsSelected:()=>{var n;const t=Object.keys(null!=(n=e.getState().rowSelection)?n:{}).length;return t>0&&t<e.getFilteredRowModel().flatRows.length},getIsSomePageRowsSelected:()=>{const n=e.getPaginationRowModel().flatRows;return!e.getIsAllPageRowsSelected()&&n.some((e=>e.getIsSelected()||e.getIsSomeSelected()))},getToggleAllRowsSelectedHandler:()=>n=>{e.toggleAllRowsSelected(n.target.checked)},getToggleAllPageRowsSelectedHandler:()=>n=>{e.toggleAllPageRowsSelected(n.target.checked)}}),createRow:(e,n)=>({toggleSelected:t=>{const r=e.getIsSelected();n.setRowSelection((o=>{if(r===(t=void 0!==t?t:!r))return o;const i={...o};return WE(i,e.id,t,n),i}))},getIsSelected:()=>{const{rowSelection:t}=n.getState();return KE(e,t)},getIsSomeSelected:()=>{const{rowSelection:t}=n.getState();return"some"===qE(e,t)},getIsAllSubRowsSelected:()=>{const{rowSelection:t}=n.getState();return"all"===qE(e,t)},getCanSelect:()=>{var t;return"function"==typeof n.options.enableRowSelection?n.options.enableRowSelection(e):null==(t=n.options.enableRowSelection)||t},getCanSelectSubRows:()=>{var t;return"function"==typeof n.options.enableSubRowSelection?n.options.enableSubRowSelection(e):null==(t=n.options.enableSubRowSelection)||t},getCanMultiSelect:()=>{var t;return"function"==typeof n.options.enableMultiRowSelection?n.options.enableMultiRowSelection(e):null==(t=n.options.enableMultiRowSelection)||t},getToggleSelectedHandler:()=>{const n=e.getCanSelect();return t=>{var r;n&&e.toggleSelected(null==(r=t.target)?void 0:r.checked)}}})},WE=(e,n,t,r)=>{var o;const i=r.getRow(n);t?(i.getCanMultiSelect()||Object.keys(e).forEach((n=>delete e[n])),i.getCanSelect()&&(e[n]=!0)):delete e[n],null!=(o=i.subRows)&&o.length&&i.getCanSelectSubRows()&&i.subRows.forEach((n=>WE(e,n.id,t,r)))};function GE(e,n){const t=e.getState().rowSelection,r=[],o={},i=function(e,n){return e.map((e=>{var n;const a=KE(e,t);if(a&&(r.push(e),o[e.id]=e),null!=(n=e.subRows)&&n.length&&(e={...e,subRows:i(e.subRows)}),a)return e})).filter(Boolean)};return{rows:i(n.rows),flatRows:r,rowsById:o}}function KE(e,n){var t;return null!=(t=n[e.id])&&t}function qE(e,n,t){if(e.subRows&&e.subRows.length){let t=!0,r=!1;return e.subRows.forEach((e=>{r&&!t||(KE(e,n)?r=!0:t=!1)})),t?"all":!!r&&"some"}return!1}const XE=/([0-9]+)/gm;function QE(e,n){return e===n?0:e>n?1:-1}function ZE(e){return"number"==typeof e?isNaN(e)||e===1/0||e===-1/0?"":String(e):"string"==typeof e?e:""}function JE(e,n){const t=e.split(XE).filter(Boolean),r=n.split(XE).filter(Boolean);for(;t.length&&r.length;){const e=t.shift(),n=r.shift(),o=parseInt(e,10),i=parseInt(n,10),a=[o,i].sort();if(isNaN(a[0])){if(e>n)return 1;if(n>e)return-1}else{if(isNaN(a[1]))return isNaN(o)?-1:1;if(o>i)return 1;if(i>o)return-1}}return t.length-r.length}const eD={alphanumeric:(e,n,t)=>JE(ZE(e.getValue(t)).toLowerCase(),ZE(n.getValue(t)).toLowerCase()),alphanumericCaseSensitive:(e,n,t)=>JE(ZE(e.getValue(t)),ZE(n.getValue(t))),text:(e,n,t)=>QE(ZE(e.getValue(t)).toLowerCase(),ZE(n.getValue(t)).toLowerCase()),textCaseSensitive:(e,n,t)=>QE(ZE(e.getValue(t)),ZE(n.getValue(t))),datetime:(e,n,t)=>{const r=e.getValue(t),o=n.getValue(t);return r>o?1:r<o?-1:0},basic:(e,n,t)=>QE(e.getValue(t),n.getValue(t))},nD={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto"}),getDefaultOptions:e=>({onSortingChange:vE("sorting",e),isMultiSortEvent:e=>e.shiftKey}),createColumn:(e,n)=>({getAutoSortingFn:()=>{const t=n.getFilteredRowModel().flatRows.slice(10);let r=!1;for(const n of t){const t=null==n?void 0:n.getValue(e.id);if("[object Date]"===Object.prototype.toString.call(t))return eD.datetime;if("string"==typeof t&&(r=!0,t.split(XE).length>1))return eD.alphanumeric}return r?eD.text:eD.basic},getAutoSortDir:()=>{const t=n.getFilteredRowModel().flatRows[0];return"string"==typeof(null==t?void 0:t.getValue(e.id))?"asc":"desc"},getSortingFn:()=>{var t,r;if(!e)throw new Error;return bE(e.columnDef.sortingFn)?e.columnDef.sortingFn:"auto"===e.columnDef.sortingFn?e.getAutoSortingFn():null!=(t=null==(r=n.options.sortingFns)?void 0:r[e.columnDef.sortingFn])?t:eD[e.columnDef.sortingFn]},toggleSorting:(t,r)=>{const o=e.getNextSortingOrder(),i=null!=t;n.setSorting((a=>{const l=null==a?void 0:a.find((n=>n.id===e.id)),s=null==a?void 0:a.findIndex((n=>n.id===e.id));let d,c=[],u=i?t:"desc"===o;var p;(d=null!=a&&a.length&&e.getCanMultiSort()&&r?l?"toggle":"add":null!=a&&a.length&&s!==a.length-1?"replace":l?"toggle":"replace","toggle"===d&&(i||o||(d="remove")),"add"===d)?(c=[...a,{id:e.id,desc:u}],c.splice(0,c.length-(null!=(p=n.options.maxMultiSortColCount)?p:Number.MAX_SAFE_INTEGER))):c="toggle"===d?a.map((n=>n.id===e.id?{...n,desc:u}:n)):"remove"===d?a.filter((n=>n.id!==e.id)):[{id:e.id,desc:u}];return c}))},getFirstSortDir:()=>{var t,r;return(null!=(t=null!=(r=e.columnDef.sortDescFirst)?r:n.options.sortDescFirst)?t:"desc"===e.getAutoSortDir())?"desc":"asc"},getNextSortingOrder:t=>{var r,o;const i=e.getFirstSortDir(),a=e.getIsSorted();return a?!!(a===i||null!=(r=n.options.enableSortingRemoval)&&!r||t&&null!=(o=n.options.enableMultiRemove)&&!o)&&("desc"===a?"asc":"desc"):i},getCanSort:()=>{var t,r;return(null==(t=e.columnDef.enableSorting)||t)&&(null==(r=n.options.enableSorting)||r)&&!!e.accessorFn},getCanMultiSort:()=>{var t,r;return null!=(t=null!=(r=e.columnDef.enableMultiSort)?r:n.options.enableMultiSort)?t:!!e.accessorFn},getIsSorted:()=>{var t;const r=null==(t=n.getState().sorting)?void 0:t.find((n=>n.id===e.id));return!!r&&(r.desc?"desc":"asc")},getSortIndex:()=>{var t,r;return null!=(t=null==(r=n.getState().sorting)?void 0:r.findIndex((n=>n.id===e.id)))?t:-1},clearSorting:()=>{n.setSorting((n=>null!=n&&n.length?n.filter((n=>n.id!==e.id)):[]))},getToggleSortingHandler:()=>{const t=e.getCanSort();return r=>{t&&(null==r.persist||r.persist(),null==e.toggleSorting||e.toggleSorting(void 0,!!e.getCanMultiSort()&&(null==n.options.isMultiSortEvent?void 0:n.options.isMultiSortEvent(r))))}}}),createTable:e=>({setSorting:n=>null==e.options.onSortingChange?void 0:e.options.onSortingChange(n),resetSorting:n=>{var t,r;e.setSorting(n?[]:null!=(t=null==(r=e.initialState)?void 0:r.sorting)?t:[])},getPreSortedRowModel:()=>e.getGroupedRowModel(),getSortedRowModel:()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())})},tD={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:vE("columnVisibility",e)}),createColumn:(e,n)=>({toggleVisibility:t=>{e.getCanHide()&&n.setColumnVisibility((n=>({...n,[e.id]:null!=t?t:!e.getIsVisible()})))},getIsVisible:()=>{var t,r;return null==(t=null==(r=n.getState().columnVisibility)?void 0:r[e.id])||t},getCanHide:()=>{var t,r;return(null==(t=e.columnDef.enableHiding)||t)&&(null==(r=n.options.enableHiding)||r)},getToggleVisibilityHandler:()=>n=>{null==e.toggleVisibility||e.toggleVisibility(n.target.checked)}}),createRow:(e,n)=>({_getAllVisibleCells:yE((()=>[e.getAllCells(),n.getState().columnVisibility]),(e=>e.filter((e=>e.column.getIsVisible()))),{key:"production"===process.env.NODE_ENV&&"row._getAllVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}}),getVisibleCells:yE((()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()]),((e,n,t)=>[...e,...n,...t]),{key:"development"===process.env.NODE_ENV&&"row.getVisibleCells",debug:()=>{var e;return null!=(e=n.options.debugAll)?e:n.options.debugRows}})}),createTable:e=>{const n=(n,t)=>yE((()=>[t(),t().filter((e=>e.getIsVisible())).map((e=>e.id)).join("_")]),(e=>e.filter((e=>null==e.getIsVisible?void 0:e.getIsVisible()))),{key:n,debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}});return{getVisibleFlatColumns:n("getVisibleFlatColumns",(()=>e.getAllFlatColumns())),getVisibleLeafColumns:n("getVisibleLeafColumns",(()=>e.getAllLeafColumns())),getLeftVisibleLeafColumns:n("getLeftVisibleLeafColumns",(()=>e.getLeftLeafColumns())),getRightVisibleLeafColumns:n("getRightVisibleLeafColumns",(()=>e.getRightLeafColumns())),getCenterVisibleLeafColumns:n("getCenterVisibleLeafColumns",(()=>e.getCenterLeafColumns())),setColumnVisibility:n=>null==e.options.onColumnVisibilityChange?void 0:e.options.onColumnVisibilityChange(n),resetColumnVisibility:n=>{var t;e.setColumnVisibility(n?{}:null!=(t=e.initialState.columnVisibility)?t:{})},toggleAllColumnsVisible:n=>{var t;n=null!=(t=n)?t:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce(((e,t)=>({...e,[t.id]:n||!(null!=t.getCanHide&&t.getCanHide())})),{}))},getIsAllColumnsVisible:()=>!e.getAllLeafColumns().some((e=>!(null!=e.getIsVisible&&e.getIsVisible()))),getIsSomeColumnsVisible:()=>e.getAllLeafColumns().some((e=>null==e.getIsVisible?void 0:e.getIsVisible())),getToggleAllColumnsVisibilityHandler:()=>n=>{var t;e.toggleAllColumnsVisible(null==(t=n.target)?void 0:t.checked)}}}},rD=[wE,tD,UE,YE,zE,nD,BE,DE,{getInitialState:e=>({...e,pagination:{pageIndex:0,pageSize:10,...null==e?void 0:e.pagination}}),getDefaultOptions:e=>({onPaginationChange:vE("pagination",e)}),createTable:e=>{let n=!1,t=!1;return{_autoResetPageIndex:()=>{var r,o;if(n){if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetPageIndex)?r:!e.options.manualPagination){if(t)return;t=!0,e._queue((()=>{e.resetPageIndex(),t=!1}))}}else e._queue((()=>{n=!0}))},setPagination:n=>null==e.options.onPaginationChange?void 0:e.options.onPaginationChange((e=>hE(n,e))),resetPagination:n=>{var t;e.setPagination(n?{pageIndex:0,pageSize:10}:null!=(t=e.initialState.pagination)?t:{pageIndex:0,pageSize:10})},setPageIndex:n=>{e.setPagination((t=>{let r=hE(n,t.pageIndex);const o=void 0===e.options.pageCount||-1===e.options.pageCount?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return r=Math.min(Math.max(0,r),o),{...t,pageIndex:r}}))},resetPageIndex:n=>{var t,r,o;e.setPageIndex(n?0:null!=(t=null==(r=e.initialState)||null==(o=r.pagination)?void 0:o.pageIndex)?t:0)},resetPageSize:n=>{var t,r,o;e.setPageSize(n?10:null!=(t=null==(r=e.initialState)||null==(o=r.pagination)?void 0:o.pageSize)?t:10)},setPageSize:n=>{e.setPagination((e=>{const t=Math.max(1,hE(n,e.pageSize)),r=e.pageSize*e.pageIndex,o=Math.floor(r/t);return{...e,pageIndex:o,pageSize:t}}))},setPageCount:n=>e.setPagination((t=>{var r;let o=hE(n,null!=(r=e.options.pageCount)?r:-1);return"number"==typeof o&&(o=Math.max(-1,o)),{...t,pageCount:o}})),getPageOptions:yE((()=>[e.getPageCount()]),(e=>{let n=[];return e&&e>0&&(n=[...new Array(e)].fill(null).map(((e,n)=>n))),n}),{key:"development"===process.env.NODE_ENV&&"getPageOptions",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),getCanPreviousPage:()=>e.getState().pagination.pageIndex>0,getCanNextPage:()=>{const{pageIndex:n}=e.getState().pagination,t=e.getPageCount();return-1===t||0!==t&&n<t-1},previousPage:()=>e.setPageIndex((e=>e-1)),nextPage:()=>e.setPageIndex((e=>e+1)),getPrePaginationRowModel:()=>e.getExpandedRowModel(),getPaginationRowModel:()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),getPageCount:()=>{var n;return null!=(n=e.options.pageCount)?n:Math.ceil(e.getPrePaginationRowModel().rows.length/e.getState().pagination.pageSize)}}}},VE,kE];function oD(e){var n;(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");let t={_features:rD};const r=t._features.reduce(((e,n)=>Object.assign(e,null==n.getDefaultOptions?void 0:n.getDefaultOptions(t))),{});let o={...null!=(n=e.initialState)?n:{}};t._features.forEach((e=>{var n;o=null!=(n=null==e.getInitialState?void 0:e.getInitialState(o))?n:o}));const i=[];let a=!1;const l={_features:rD,options:{...r,...e},initialState:o,_queue:e=>{i.push(e),a||(a=!0,Promise.resolve().then((()=>{for(;i.length;)i.shift()();a=!1})).catch((e=>setTimeout((()=>{throw e})))))},reset:()=>{t.setState(t.initialState)},setOptions:e=>{const n=hE(e,t.options);t.options=(e=>t.options.mergeOptions?t.options.mergeOptions(r,e):{...r,...e})(n)},getState:()=>t.options.state,setState:e=>{null==t.options.onStateChange||t.options.onStateChange(e)},_getRowId:(e,n,r)=>{var o;return null!=(o=null==t.options.getRowId?void 0:t.options.getRowId(e,n,r))?o:""+(r?[r.id,n].join("."):n)},getCoreRowModel:()=>(t._getCoreRowModel||(t._getCoreRowModel=t.options.getCoreRowModel(t)),t._getCoreRowModel()),getRowModel:()=>t.getPaginationRowModel(),getRow:e=>{const n=t.getRowModel().rowsById[e];if(!n){if("production"!==process.env.NODE_ENV)throw new Error("getRow expected an ID, but got "+e);throw new Error}return n},_getDefaultColumnDef:yE((()=>[t.options.defaultColumn]),(e=>{var n;return e=null!=(n=e)?n:{},{header:e=>{const n=e.header.column.columnDef;return n.accessorKey?n.accessorKey:n.accessorFn?n.id:null},cell:e=>{var n,t;return null!=(n=null==(t=e.renderValue())||null==t.toString?void 0:t.toString())?n:null},...t._features.reduce(((e,n)=>Object.assign(e,null==n.getDefaultColumnDef?void 0:n.getDefaultColumnDef())),{}),...e}}),{debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns},key:"development"===process.env.NODE_ENV&&"getDefaultColumnDef"}),_getColumnDefs:()=>t.options.columns,getAllColumns:yE((()=>[t._getColumnDefs()]),(e=>{const n=function(e,r,o){return void 0===o&&(o=0),e.map((e=>{const i=function(e,n,t,r){var o,i;const a={...e._getDefaultColumnDef(),...n},l=a.accessorKey;let s,d=null!=(o=null!=(i=a.id)?i:l?l.replace(".","_"):void 0)?o:"string"==typeof a.header?a.header:void 0;if(a.accessorFn?s=a.accessorFn:l&&(s=l.includes(".")?e=>{let n=e;for(const e of l.split("."))n=n[e];return n}:e=>e[a.accessorKey]),!d){if("production"!==process.env.NODE_ENV)throw new Error(a.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header");throw new Error}let c={id:""+String(d),accessorFn:s,parent:r,depth:t,columnDef:a,columns:[],getFlatColumns:yE((()=>[!0]),(()=>{var e;return[c,...null==(e=c.columns)?void 0:e.flatMap((e=>e.getFlatColumns()))]}),{key:"production"===process.env.NODE_ENV&&"column.getFlatColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}}),getLeafColumns:yE((()=>[e._getOrderColumnsFn()]),(e=>{var n;if(null!=(n=c.columns)&&n.length){let n=c.columns.flatMap((e=>e.getLeafColumns()));return e(n)}return[c]}),{key:"production"===process.env.NODE_ENV&&"column.getLeafColumns",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugColumns}})};return c=e._features.reduce(((n,t)=>Object.assign(n,null==t.createColumn?void 0:t.createColumn(c,e))),c),c}(t,e,o,r),a=e;return i.columns=a.columns?n(a.columns,i,o+1):[],i}))};return n(e)}),{key:"development"===process.env.NODE_ENV&&"getAllColumns",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),getAllFlatColumns:yE((()=>[t.getAllColumns()]),(e=>e.flatMap((e=>e.getFlatColumns()))),{key:"development"===process.env.NODE_ENV&&"getAllFlatColumns",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),_getAllFlatColumnsById:yE((()=>[t.getAllFlatColumns()]),(e=>e.reduce(((e,n)=>(e[n.id]=n,e)),{})),{key:"development"===process.env.NODE_ENV&&"getAllFlatColumnsById",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),getAllLeafColumns:yE((()=>[t.getAllColumns(),t._getOrderColumnsFn()]),((e,n)=>n(e.flatMap((e=>e.getLeafColumns())))),{key:"development"===process.env.NODE_ENV&&"getAllLeafColumns",debug:()=>{var e;return null!=(e=t.options.debugAll)?e:t.options.debugColumns}}),getColumn:e=>{const n=t._getAllFlatColumnsById()[e];if(!n)throw"production"!==process.env.NODE_ENV&&console.warn("[Table] Column with id "+e+" does not exist."),new Error;return n}};return Object.assign(t,l),t._features.forEach((e=>Object.assign(t,null==e.createTable?void 0:e.createTable(t)))),t}const iD=(e,n,t,r,o,i)=>{let a={id:n,index:r,original:t,depth:o,_valuesCache:{},getValue:n=>{if(a._valuesCache.hasOwnProperty(n))return a._valuesCache[n];const t=e.getColumn(n);return t.accessorFn?(a._valuesCache[n]=t.accessorFn(a.original,r),a._valuesCache[n]):void 0},renderValue:n=>{var t;return null!=(t=a.getValue(n))?t:e.options.renderFallbackValue},subRows:null!=i?i:[],getLeafRows:()=>function(e,n){const t=[],r=e=>{e.forEach((e=>{t.push(e);const o=n(e);null!=o&&o.length&&r(o)}))};return r(e),t}(a.subRows,(e=>e.subRows)),getAllCells:yE((()=>[e.getAllLeafColumns()]),(n=>n.map((n=>function(e,n,t,r){const o={id:n.id+"_"+t.id,row:n,column:t,getValue:()=>n.getValue(r),renderValue:()=>{var n;return null!=(n=o.getValue())?n:e.options.renderFallbackValue},getContext:yE((()=>[e,t,n,o]),((e,n,t,r)=>({table:e,column:n,row:t,cell:r,getValue:r.getValue,renderValue:r.renderValue})),{key:"development"===process.env.NODE_ENV&&"cell.getContext",debug:()=>e.options.debugAll})};return e._features.forEach((r=>{Object.assign(o,null==r.createCell?void 0:r.createCell(o,t,n,e))}),{}),o}(e,a,n,n.id)))),{key:"development"===process.env.NODE_ENV&&"row.getAllCells",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugRows}}),_getAllCellsByColumnId:yE((()=>[a.getAllCells()]),(e=>e.reduce(((e,n)=>(e[n.column.id]=n,e)),{})),{key:"production"===process.env.NODE_ENV&&"row.getAllCellsByColumnId",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugRows}})};for(let n=0;n<e._features.length;n++){const t=e._features[n];Object.assign(a,null==t||null==t.createRow?void 0:t.createRow(a,e))}return a};function aD(e,n){return e?function(e){return"function"==typeof e&&(()=>{const n=Object.getPrototypeOf(e);return n.prototype&&n.prototype.isReactComponent})()}(t=e)||"function"==typeof t||function(e){return"object"==typeof e&&"symbol"==typeof e.$$typeof&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}(t)?r.createElement(e,n):e:null;var t}var lD,sD,dD;!function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.SMALL=42]="SMALL",e[e.LARGE=56]="LARGE"}(lD||(lD={})),function(e){e.ACCESSOR="accessor",e.DISPLAY="display",e.GROUP="group",e.ACTION="action"}(sD||(sD={})),function(e){e.CHECKBOX="checkbox",e.TOGGLE="toggle",e.ROW_ACTIONS="row_actions",e.SETTINGS="settings"}(dD||(dD={}));var cD,uD,pD,fD,mD,gD,hD,vD,bD,yD,xD,wD,$D,CD,kD,SD,ED,DD,TD,_D,ND,PD,MD,OD,RD,ID,AD,FD,LD,zD,HD,jD,BD,UD=y({}),YD=function(e){var n=e.children,t=e.defaultRowSize,r=o.useState(t||lD.UNSPECIFIED),i={rowSize:r[0],setRowSize:r[1]};return o.createElement(UD.Provider,{value:i},n)},VD=w.div(cD||(cD=Xe(["\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n"],["\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n"]))),WD=w.span(uD||(uD=Xe(["\n position: absolute;\n width: 24px;\n height: 16px;\n border-radius: 15px;\n opacity: ",";\n background-color: ",";\n cursor: ",";\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin: ","px;\n transition: 0.2s;\n background-color: ",";\n }\n"],["\n position: absolute;\n width: 24px;\n height: 16px;\n border-radius: 15px;\n opacity: ",";\n background-color: ",";\n cursor: ",";\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin: ","px;\n transition: 0.2s;\n background-color: ",";\n }\n"])),(function(e){return e.disabled?.3:1}),(function(e){return e.theme.palette.grey[300]}),(function(e){return e.disabled?"not-allowed":"pointer"}),12,12,2,(function(e){return e.theme.palette.white[100]})),GD=w.input(pD||(pD=Xe(["\n opacity: 0;\n z-index: 1;\n border-radius: 15px;\n width: 24px;\n &:checked + "," {\n background-color: ",";\n\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin-left: 11px;\n transition: 0.2s;\n }\n }\n"],["\n opacity: 0;\n z-index: 1;\n border-radius: 15px;\n width: 24px;\n &:checked + "," {\n background-color: ",";\n\n &::after {\n content: '';\n display: block;\n border-radius: 50%;\n width: ","px;\n height: ","px;\n margin-left: 11px;\n transition: 0.2s;\n }\n }\n"])),WD,(function(e){var n=e.theme.palette;return e.disabled?n.grey[300]:n.blue[500]}),12,12),KD=function(e){var n=e.checked,t=void 0!==n&&n,r=e.disabled,i=void 0!==r&&r,a=e.onChange;return o.createElement(VD,null,o.createElement(GD,{type:"checkbox",checked:t,disabled:i,onChange:function(){return null==a?void 0:a(t)}}),o.createElement(WD,{disabled:i}))},qD=function(e){var n=e.theme,t=e.isHeader,r=e.isPopoverActive,o=e.isPinned,i=t?n.palette.grey[50]:n.palette.white[100];return{position:o?"sticky":void 0,backgroundColor:o?i:void 0,left:"left"===o?"0px":void 0,right:"right"===o?"0px":void 0,boxShadow:o?"-5px 0 5px -5px rgba(51, 51, 51, 0.15)":void 0,zIndex:r?2:1}},XD=w.div(fD||(fD=Xe(["\n display: flex;\n align-items: center;\n padding: 8px;\n"],["\n display: flex;\n align-items: center;\n padding: 8px;\n"]))),QD=w(_r)(mD||(mD=Xe(["\n color: ",";\n font-size: 14px;\n &:hover {\n background-color: transparent;\n color: ",";\n }\n"],["\n color: ",";\n font-size: 14px;\n &:hover {\n background-color: transparent;\n color: ",";\n }\n"])),(function(e){return e.theme.palette.grey[500]}),(function(e){return e.theme.palette.blue[500]})),ZD=w(Nr)(gD||(gD=Xe(["\n font-size: 14px;\n color: ",";\n border-radius: 6px;\n &:hover {\n background-color: ",";\n color: ",";\n }\n &:active {\n background-color: ",";\n }\n"],["\n font-size: 14px;\n color: ",";\n border-radius: 6px;\n &:hover {\n background-color: ",";\n color: ",";\n }\n &:active {\n background-color: ",";\n }\n"])),(function(e){return e.theme.palette.grey[500]}),(function(e){return e.theme.palette.blue[100]}),(function(e){return e.theme.palette.blue[700]}),(function(e){return e.theme.palette.blue[200]})),JD=function(e){var n=e.dropdown,r=e.row,l=e.onOpen,s=e.onClose,d=a((function(){return o.createElement(ZD,{icon:{icon:t,fixedWidth:!0}})}),[]),c=i((function(){return n.map((function(e){var n=e.onClick,t=Ve(e,["onClick"]);return Ye({onClick:function(){return n(r)}},t)}))}),[n,r]);return o.createElement(zr,{placement:"right-start",renderTrigger:d,content:c,onOpen:l,onClose:s})},eT=function(e){var n,t,r=e.actionType,i=e.row,a=e.isToggled,l=e.onActionChange,d=e.rowActions,c=e.column,u=e.maxWidth,p=e.minWidth,f=$(),m=s(!1),g=m[0],h=m[1],v=null===(n=null==d?void 0:d.dropdown)||void 0===n?void 0:n.tooltip,b=null===(t=null==d?void 0:d.dropdown)||void 0===t?void 0:t.items;switch(r){case dD.CHECKBOX:return o.createElement("div",{className:"DS-rt-td DS-tour-checkbox",style:{maxWidth:u,minWidth:p}},o.createElement(XD,{style:{paddingLeft:8}},o.createElement(nT,{value:i.getIsSelected(),onChange:function(){return i.toggleSelected()}})));case dD.TOGGLE:return o.createElement("div",{style:{maxWidth:u,minWidth:p}},o.createElement(XD,null,o.createElement(KD,{checked:a,onChange:function(){return null==l?void 0:l(i.id)}})));case dD.ROW_ACTIONS:return o.createElement("div",{style:Ye({maxWidth:u,minWidth:p},qD({isHeader:!1,isPopoverActive:g,theme:f,isPinned:c.getIsPinned()}))},o.createElement(XD,null,(null==d?void 0:d.primary)&&(null==d?void 0:d.primary.map((function(e,n){var t;return o.createElement(xl,Ye({key:n},null!==(t=e.tooltip)&&void 0!==t?t:yl,{showAfterSeconds:.5}),o.createElement(tT,{primary:e,row:i}))}))),o.createElement(xl,Ye({},null!=v?v:yl,{showAfterSeconds:.5}),b&&o.createElement(JD,{dropdown:b,row:i,onOpen:function(e){h(e)}}))));default:return o.createElement(o.Fragment,null)}},nT=w(Zu)(vD||(vD=Xe(["\n ",";\n"],["\n ",";\n"])),(function(e){var n=e.value,t=e.theme;return!n&&C(hD||(hD=Xe(["\n span {\n background-color: ",";\n }\n "],["\n span {\n background-color: ",";\n }\n "])),t.palette.white[100])})),tT=function(e){var n=e.primary,t=e.row,r=n.text,i=n.icon,a=n.onClick;return o.createElement(o.Fragment,null,r&&o.createElement(QD,{type:"text",text:r,onClick:function(){return a(t)}}),i&&o.createElement(ZD,{icon:i,onClick:function(){return a(t)}}))},rT=w.div(bD||(bD=Xe(["\n position: relative;\n"],["\n position: relative;\n"]))),oT=w.div(yD||(yD=Xe(["\n position: absolute;\n z-index: 10;\n top: -16px;\n width: 100%;\n textarea {\n color: "," !important;\n width: 100%;\n min-width: 80px;\n }\n"],["\n position: absolute;\n z-index: 10;\n top: -16px;\n width: 100%;\n textarea {\n color: "," !important;\n width: 100%;\n min-width: 80px;\n }\n"])),(function(e){return e.theme.palette.black[80]})),iT=w.div(xD||(xD=Xe(["\n position: absolute;\n z-index: 2;\n bottom: 2px;\n right: 6px;\n"],["\n position: absolute;\n z-index: 2;\n bottom: 2px;\n right: 6px;\n"]))),aT=w(cn)(wD||(wD=Xe(["\n cursor: pointer;\n font-size: 12px;\n margin: 2px;\n color: ",";\n"],["\n cursor: pointer;\n font-size: 12px;\n margin: 2px;\n color: ",";\n"])),(function(e){var n=e.theme;return e.confirm?n.palette.green[900]:n.palette.red[900]})),lT=function(e){var n=e.onChange,t=e.row,r=e.content,i=e.onBlur,l=s(null==r?void 0:r.toString()),d=l[0],c=l[1],u=ve(a((function(e){e&&(null==n||n(d||"",t)),i()}),[n,t,d,i]),200);return o.createElement(oT,null,o.createElement(iT,null,o.createElement(aT,{icon:R,onClick:function(){return u(!0)},confirm:!0}),o.createElement(aT,{icon:I})),o.createElement(Bl,{value:d,onChange:function(e){return c(e.target.value)},autoFocus:!0,initialHeight:"100px",onBlur:function(){return u()},onFocus:function(e){var n=e.target.value;e.target.value="",e.target.value=n}}))},sT=function(e){var n=e.hover,t=e.onChange,r=e.row,i=e.unitSymbol,a=e.content,l=s(!1),d=l[0],c=l[1];return o.createElement(rT,null,d?o.createElement(lT,{row:r,onChange:t,onBlur:function(){return c(!1)},content:a}):o.createElement(Ol,{hasMeasureUnit:!!i},o.createElement(kl,{value:null==a?void 0:a.toString(),isTransparent:!n,actionIcon:Ye({icon:A},n?{}:{visibility:"hidden"}),onFocus:function(){return c(!0)}})))},dT=function(e){var n=e.content,t=e.isEditable,r=e.tag,i=e.unitSymbol,l=e.headline,s=e.leadingIcon,d=e.avatar,c=e.actionType,u=e.row,p=e.rowSize,f=e.onActionChange,m=e.isToggled,g=e.hover,h=e.onChange,v=e.trailingMicroTag,b=e.minWidth,y=e.rowActions,x=e.context,w=e.onRowClick,$=e.maxWidth,C=e.align,k=e.disableClick,S=x.column,E=!t&&"function"==typeof w&&!k,D=a((function(e){return E&&w(e)}),[E,w]);if(c){var T=b?b+1:void 0,_=$?$+1:void 0;return o.createElement(eT,{row:u,actionType:c,isToggled:m,onActionChange:f,rowActions:y,column:S,maxWidth:_,minWidth:T})}return o.createElement(Sl,{className:"DS-rt-td",role:"gridcell",minWidth:b,maxWidth:$,onClick:function(){return D(u)},cellHasOnClick:E,style:{overflow:t?"visible":void 0,zIndex:t?"auto":void 0},align:C},o.createElement(El,null,s&&o.createElement(Dl,null,o.createElement(cn,Ye({},s))),d&&o.createElement(Tl,null,o.createElement(or,Ye({},d))),o.createElement(_l,{hasMeasureUnit:!!i},t?o.createElement(sT,{hover:g,onChange:h,row:u,unitSymbol:i,content:n}):o.createElement(o.Fragment,null,o.createElement(Rl,null,o.createElement(Nl,{truncate:!!p,headline:l},n),i&&o.createElement(Pl,{headline:l},i)),r&&o.createElement(ck,Ye({},r)))),v&&o.createElement(Ml,null,o.createElement(vb,{type:v.type,text:v.text}))))},cT=function(e){var n,t=e.isActionCell,r=e.minWidth,i=e.maxWidth,a=e.align,l=null!==(n=t?32:null!=r?r:i)&&void 0!==n?n:50;return o.createElement("div",{className:"DS-rt-tr",style:{maxWidth:i,minWidth:r}},o.createElement(pT,{className:"DS-rt-td",align:a},o.createElement(uT,{speed:2,height:26,viewBox:"0 0 "+l+" 36",animate:!0},o.createElement("rect",{x:"0",y:"0",rx:"5",height:"36",width:l}))))},uT=w(H$)($D||($D=Xe(["\n width: auto;\n align-items: center;\n"],["\n width: auto;\n align-items: center;\n"]))),pT=w.div(kD||(kD=Xe(["\n display: flex;\n align-items: center;\n flex: 1;\n\n margin-inline: 8px;\n\n ",";\n"],["\n display: flex;\n align-items: center;\n flex: 1;\n\n margin-inline: 8px;\n\n ",";\n"])),(function(e){var n=e.align;return C(CD||(CD=Xe(["\n justify-content: ",";\n "],["\n justify-content: ",";\n "])),"center"===n?"center":"left"===n?"flex-start":"flex-end")})),fT=function(e){var n=e.cell,t=e.row,r=e.hover,i=e.rowSize,a=e.isLoading,l=e.onRowClick,s=function(e,n){var t,r=e.getValue(),o=!("string"==typeof r||"number"==typeof r),i=e.column.columnDef,a=i.actionType&&be(i.toggles,(function(e){return e===n.id})),l=i.rowActions,s=e.column.columnDef.unitSymbol;return{isEditable:!!e.column.columnDef.isEditable,isToggled:!!a,actionType:i.actionType,onActionChange:i.onActionChange,content:o?null===(t=r)||void 0===t?void 0:t.content:r,unitSymbol:o&&r&&r.unitSymbol||s,values:r,minWidth:e.column.columnDef.minWidth,maxWidth:e.column.columnDef.maxWidth,rowActions:l,align:e.column.columnDef.align||"left"}}(n,t),d=s.values,c=Ve(s,["values"]);if(a)return o.createElement(cT,{isActionCell:!!c.actionType,minWidth:c.minWidth,maxWidth:c.maxWidth,align:c.align});var u=n.column.columnDef.customCell,p=n.column.columnDef.disableClick;if(u){var f=c.maxWidth,m=c.minWidth,g=c.align;return o.createElement(mT,{className:"DS-rt-td",style:{maxWidth:f,minWidth:m},align:g,onClick:function(){return!p&&(null==l?void 0:l(t))}},aD(u(t,!!r),n.getContext()))}return o.createElement(dT,Ye({context:n.getContext(),key:n.id,row:t,hover:r,rowSize:i,onRowClick:l},d,c,{onChange:n.column.columnDef.onChange,disableClick:p}))},mT=w.div(ED||(ED=Xe(["\n height: 100%;\n display: flex;\n align-items: center;\n width: 100%;\n ",";\n /* margin-inline: 8px; */\n"],["\n height: 100%;\n display: flex;\n align-items: center;\n width: 100%;\n ",";\n /* margin-inline: 8px; */\n"])),(function(e){var n=e.align;return C(SD||(SD=Xe(["\n justify-content: ",";\n "],["\n justify-content: ",";\n "])),"center"===n?"center":"left"===n?"flex-start":"flex-end")})),gT=w.div(_D||(_D=Xe(["\n box-shadow: ",";\n transition: box-shadow 200ms ease;\n ","\n ","\n"],["\n box-shadow: ",";\n transition: box-shadow 200ms ease;\n ","\n ","\n"])),(function(e){var n=e.mouseHover,t=e.theme;return n?"0px 3px 6px rgba(51, 51, 51, 0.15), 0px 2px 4px rgba(51, 51, 51, 0.12)":"0px 1px "+t.palette.grey[100]}),(function(e){var n=e.size;return n&&C(DD||(DD=Xe(["\n height: ","px;\n "],["\n height: ","px;\n "])),n)}),(function(e){var n=e.selected,t=e.theme;return n&&C(TD||(TD=Xe(["\n background-color: ",";\n "],["\n background-color: ",";\n "])),t.palette.blue[50])})),hT=function(e){var n=e.row,t=e.isLoading,r=e.onRowClick,i=e.isRowHighlighted,a=e.rowHighlightColor,l=e.defaultRowSize,d=x(UD).rowSize,c=s(),u=c[0],p=c[1];return o.createElement(gT,{className:"DS-rt-tr-group",role:"rowgroup",mouseHover:!t&&u,onMouseEnter:function(){return p(!0)},onMouseLeave:function(){return p(!1)},size:d||l,selected:!t&&n.getIsSelected()},o.createElement(vT,{className:"DS-rt-tr",role:"row",style:{height:d||l},isRowHighlighted:i,rowHighlightColor:a},n.getVisibleCells().map((function(e,i){return o.createElement(fT,{key:i,cell:e,row:n,hover:u,rowSize:d,isLoading:t,onRowClick:r})}))))},vT=w.div(PD||(PD=Xe(["\n ",";\n font-size: 14px;\n color: ",";\n"],["\n ",";\n font-size: 14px;\n color: ",";\n"])),(function(e){var n=e.isRowHighlighted,t=e.rowHighlightColor,r=e.theme;return n&&C(ND||(ND=Xe(["\n background-color: ",";\n border-bottom: 1px solid #b0b9bd; // Grey 3\n "],["\n background-color: ",";\n border-bottom: 1px solid #b0b9bd; // Grey 3\n "])),t||r.palette.primary[100])}),(function(e){return e.theme.palette.black[80]})),bT=function(e){var n=e.rows,t=e.rowSize,r=e.isLoading,i=e.onRowClick,a=e.bodyHeight,s=e.rowIdHighlight,c=e.rowHighlightColor,u=e.pageIndex,p=d(null);return l((function(){p.current&&p.current.scrollTo({top:0})}),[u]),o.createElement("div",{ref:p,className:"DS-rt-tbody",style:{height:a}},n.map((function(e){return o.createElement(hT,{key:e.id,row:e,defaultRowSize:t,isLoading:r,onRowClick:i,isRowHighlighted:s===+e.id,rowHighlightColor:c})})))},yT=w.div(MD||(MD=Xe(["\n max-height: ","px;\n visibility: ",";\n transition: max-height 400ms ease;\n padding-bottom: ",";\n background-color: ",";\n position: relative;\n z-index: 11;\n"],["\n max-height: ","px;\n visibility: ",";\n transition: max-height 400ms ease;\n padding-bottom: ",";\n background-color: ",";\n position: relative;\n z-index: 11;\n"])),(function(e){var n=e.shown,t=e.allSelectedShown;return n?t?94:48:0}),(function(e){return e.shown?"unset":"hidden"}),(function(e){return e.shown?"16px":"0"}),(function(e){return e.theme.palette.white[100]})),xT=w.div(OD||(OD=Xe(["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n // width: 100%;\n align-items: center;\n justify-content: space-between;\n padding: 8px 8px;\n font-size: 14px;\n line-height: 21px;\n"],["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n // width: 100%;\n align-items: center;\n justify-content: space-between;\n padding: 8px 8px;\n font-size: 14px;\n line-height: 21px;\n"])),(function(e){return e.theme.palette.black[80]})),wT=w.div(RD||(RD=Xe(["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 8px;\n font-size: 14px;\n line-height: 21px;\n gap: 8px;\n"],["\n //non è in palette\n background-color: #e8f7fe;\n color: ",";\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 8px;\n font-size: 14px;\n line-height: 21px;\n gap: 8px;\n"])),(function(e){return e.theme.palette.black[80]})),$T=w.div(ID||(ID=Xe(["\n display: flex;\n justify-content: flex-end;\n gap: 16px;\n"],["\n display: flex;\n justify-content: flex-end;\n gap: 16px;\n"]))),CT=w.span(AD||(AD=Xe([""],[""]))),kT=function(e){var n=e.selectedRowData,r=e.bulkBarActions,c=e.allSelectedCTA,u=e.renderBulkActions,p=n.length,f=d(null),m=d(null),g=s(),h=g[0],v=g[1],y=s(),x=y[0],w=y[1],$=s(!1),C=$[0],k=$[1];b((function(){var e,n,t,r;v(null===(n=null===(e=null==f?void 0:f.current)||void 0===e?void 0:e.getBoundingClientRect())||void 0===n?void 0:n.width),w(null===(r=null===(t=null==m?void 0:m.current)||void 0===t?void 0:t.getBoundingClientRect())||void 0===r?void 0:r.width)}),[]),l((function(){var e=ve((function(){var e,n;v(null===(n=null===(e=null==f?void 0:f.current)||void 0===e?void 0:e.getBoundingClientRect())||void 0===n?void 0:n.width),w((function(e){var n,t,r,o,i,a;return(null===(t=null===(n=null==m?void 0:m.current)||void 0===n?void 0:n.getBoundingClientRect())||void 0===t?void 0:t.width)&&(null===(o=null===(r=null==m?void 0:m.current)||void 0===r?void 0:r.getBoundingClientRect())||void 0===o?void 0:o.width)>(e||0)?null===(a=null===(i=null==m?void 0:m.current)||void 0===i?void 0:i.getBoundingClientRect())||void 0===a?void 0:a.width:e}))}),200);return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}}),[]),l((function(){k((h||0)-(x||0)<200)}),[h,x]);var S=a((function(){return o.createElement(ZD,{icon:{icon:t,fixedWidth:!0}})}),[]),E=i((function(){return(null==r?void 0:r.slice(1,-1).map((function(e){var t=e.onClick,r=e.color;return{onClick:function(){return t(n)},text:e.text,color:r,icon:e.iconLeft}})))||[]}),[r,n]);return o.createElement(yT,{ref:f,shown:!!p&&p>0,allSelectedShown:!!c,id:"DS-bulk-bar-wrapper"},o.createElement(xT,{id:"DS-checkbox-table-bulk-bar"},o.createElement(CT,null,p+" "+(1===p?"selezionato":"selezionati")),r&&r.length>0?o.createElement($T,{ref:m},!C||r.length<3?r.map((function(e,t){return o.createElement(_r,Ye({key:t},e,{onClick:function(){return e.onClick(n)}}))})):o.createElement(o.Fragment,null,o.createElement(_r,Ye({},r[0],{onClick:function(){return r[0].onClick(n)}})),o.createElement(zr,{placement:"bottom-end",renderTrigger:S,content:E}),o.createElement(_r,Ye({},r[r.length-1],{onClick:function(){return r[r.length-1].onClick(n)}})))):o.createElement($T,{ref:m},null==u?void 0:u(n))),!!c&&o.createElement(wT,null,null==c?void 0:c.description,o.createElement(_r,{text:null==c?void 0:c.text,onClick:null==c?void 0:c.onClick,type:"text"})))},ST=function(e){var n=e.footerGroup;return o.createElement("div",null,n.map((function(e){return o.createElement("div",{key:e.id},e.headers.map((function(e){return o.createElement("div",{key:e.id},e.isPlaceholder?null:aD(e.column.columnDef.footer,e.getContext()))})))})))},ET=w.div(FD||(FD=Xe(["\n width: 100%;\n height: 100%;\n overflow-x: hidden;\n"],["\n width: 100%;\n height: 100%;\n overflow-x: hidden;\n"]))),DT=w.div(LD||(LD=Xe(["\n overflow-y: auto;\n overflow-x: hidden;\n height: 100%;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n\n /* CSS relativo al body scrollable */\n .DS-ReactTable-container {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n }\n\n .DS-ReactTable {\n position: relative;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-table {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n width: 100%;\n border-collapse: collapse;\n overflow-x: auto;\n overflow-y: hidden;\n }\n\n .DS-ReactTable .DS-rt-thead {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n cursor: default;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-th {\n position: relative;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-td {\n line-height: normal;\n position: relative;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header:last-child {\n overflow: hidden;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header-content {\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .DS-ReactTable .DS-rt-thead.DS-header .DS-rt-th:after {\n content: '';\n display: block;\n position: absolute;\n }\n\n .DS-ReactTable .DS-rt-tbody {\n padding-bottom: 5px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n }\n\n .DS-ReactTable .DS-rt-tbody .DS-rt-tr-group {\n flex: none;\n }\n\n .DS-ReactTable .DS-rt-tr-group {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n cursor: pointer;\n }\n\n .DS-ReactTable .DS-rt-tr {\n flex: 1 0;\n display: inline-flex;\n flex-direction: row;\n flex-wrap: wrap;\n align-content: center;\n justify-content: center;\n align-items: center;\n }\n\n .DS-ReactTable .DS-rt-th {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: nowrap;\n vertical-align: middle;\n align-self: center;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-td {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: break-spaces;\n text-overflow: ellipsis;\n align-self: center;\n /* overflow: hidden; */\n }\n"],["\n overflow-y: auto;\n overflow-x: hidden;\n height: 100%;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n\n /* CSS relativo al body scrollable */\n .DS-ReactTable-container {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n max-height: 100%;\n }\n\n .DS-ReactTable {\n position: relative;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-table {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n width: 100%;\n border-collapse: collapse;\n overflow-x: auto;\n overflow-y: hidden;\n }\n\n .DS-ReactTable .DS-rt-thead {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n cursor: default;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-th {\n position: relative;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-td {\n line-height: normal;\n position: relative;\n }\n\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header:last-child {\n overflow: hidden;\n }\n .DS-ReactTable .DS-rt-thead .DS-rt-resizable-header-content {\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .DS-ReactTable .DS-rt-thead.DS-header .DS-rt-th:after {\n content: '';\n display: block;\n position: absolute;\n }\n\n .DS-ReactTable .DS-rt-tbody {\n padding-bottom: 5px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n }\n\n .DS-ReactTable .DS-rt-tbody .DS-rt-tr-group {\n flex: none;\n }\n\n .DS-ReactTable .DS-rt-tr-group {\n -webkit-box-flex: 1;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: stretch;\n -ms-flex-align: stretch;\n align-items: stretch;\n cursor: pointer;\n }\n\n .DS-ReactTable .DS-rt-tr {\n flex: 1 0;\n display: inline-flex;\n flex-direction: row;\n flex-wrap: wrap;\n align-content: center;\n justify-content: center;\n align-items: center;\n }\n\n .DS-ReactTable .DS-rt-th {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: nowrap;\n vertical-align: middle;\n align-self: center;\n overflow: hidden;\n }\n\n .DS-ReactTable .DS-rt-td {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n white-space: break-spaces;\n text-overflow: ellipsis;\n align-self: center;\n /* overflow: hidden; */\n }\n"]))),TT=w.div(zD||(zD=Xe(["\n height: 100%;\n position: relative;\n border-spacing: 0 2px;\n border: 0;\n td,\n th {\n padding: 0;\n }\n"],["\n height: 100%;\n position: relative;\n border-spacing: 0 2px;\n border: 0;\n td,\n th {\n padding: 0;\n }\n"]))),_T=w(cn)(HD||(HD=Xe(["\n transform: rotate(","deg);\n color: ",";\n height: 16px;\n width: 16px !important;\n padding: 2px;\n &:hover {\n color: ",";\n background-color: ",";\n border-radius: 100%;\n cursor: pointer;\n }\n"],["\n transform: rotate(","deg);\n color: ",";\n height: 16px;\n width: 16px !important;\n padding: 2px;\n &:hover {\n color: ",";\n background-color: ",";\n border-radius: 100%;\n cursor: pointer;\n }\n"])),(function(e){return e.isSortedDesc?180:0}),(function(e){var n=e.isSorted,t=e.theme;return n?t.palette.grey[900]:t.palette.grey[200]}),(function(e){return e.theme.palette.grey[900]}),(function(e){return e.theme.palette.grey[100]})),NT=w.div(jD||(jD=Xe(["\n display: flex;\n justify-content: center;\n text-align: center;\n width: 100%;\n margin-bottom: 18px;\n"],["\n display: flex;\n justify-content: center;\n text-align: center;\n width: 100%;\n margin-bottom: 18px;\n"]))),PT=function(e){var n,t=e.columns,r=e.isSelectable,o=e.toggles,i=e.isTogglesSortable,a=e.onTogglesChange,l=e.rowActions,s=e.enableSettings,d=e.settingsDropdownConfig,c=e.preSettedTableSettings,u={accessor:(e,n)=>"function"==typeof e?{...n,accessorFn:e}:{...n,accessorKey:e},display:e=>e,group:e=>e},p=(null==c?void 0:c.orderColumns)?qe([],t,!0).sort((function(e,n){var t,r,o=null===(t=c.orderColumns)||void 0===t?void 0:t.indexOf(String(e.key)),i=null===(r=c.orderColumns)||void 0===r?void 0:r.indexOf(String(n.key));return void 0!==o&&void 0!==i?o-i:0})):t,f=qe(qe(qe(qe([],r?[{columnDefType:sD.ACTION,key:dD.CHECKBOX,columnDef:{actionType:dD.CHECKBOX,enableSorting:!1,maxWidth:32}}]:[],!0),o?[{columnDefType:sD.ACTION,key:dD.TOGGLE,columnDef:{actionType:dD.TOGGLE,enableSorting:i,toggles:o,sortingFn:function(e,n){return function(e,n,t){var r=xe(t,e.id),o=xe(t,n.id);return r?1:o?-1:0}(e,n,o)},onActionChange:function(e){return null==a?void 0:a(m(e,o))},maxWidth:32}}]:[],!0),p,!0),l||s?[{ColumnDefType:sD.ACTION,key:dD.ROW_ACTIONS,columnDef:{actionType:dD.ROW_ACTIONS,enableSorting:!1,rowActions:l,enableSettings:s,settingsDropdownConfig:d,headerTooltip:null!==(n=null==d?void 0:d.settingsTooltip)&&void 0!==n?n:{},enablePinning:!0,maxWidth:80,minWidth:80,align:"center"}}]:[],!0),m=function(e,n){return be(n,(function(n){return n===e}))?ye(n,(function(n){return n!==e})):qe(qe([],n,!0),[e],!1)};return f.map((function(e){switch(e.columnDefType){default:case sD.DISPLAY:return u.display(Ye({id:String(e.key)},e.columnDef));case sD.ACCESSOR:return u.accessor(e.key,e.columnDef);case sD.GROUP:return u.group(Ye({},e.columnDef));case sD.ACTION:return u.accessor(e.key,e.columnDef)}}))},MT=function(e){switch(e){default:case!1:return"asc";case"asc":return"desc";case"desc":return!1}};!function(e){e[e.FIRST=0]="FIRST",e[e.SECOND=1]="SECOND",e[e.THIRD=2]="THIRD"}(BD||(BD={}));var OT,RT,IT,AT,FT,LT,zT,HT,jT,BT=w(zu)(OT||(OT=Xe(["\n margin-top: 16px;\n margin-left: 8px;\n .body {\n padding: 0 0;\n }\n .header {\n height: ",";\n }\n"],["\n margin-top: 16px;\n margin-left: 8px;\n .body {\n padding: 0 0;\n }\n .header {\n height: ",";\n }\n"])),Au.m),UT=w.h6(RT||(RT=Xe(["\n font-size: 12px;\n color: ",";\n font-weight: 500;\n line-height: 18px;\n padding: 0;\n margin: 0;\n"],["\n font-size: 12px;\n color: ",";\n font-weight: 500;\n line-height: 18px;\n padding: 0;\n margin: 0;\n"])),(function(e){return e.theme.palette.black})),YT=w.div(IT||(IT=Xe(["\n margin-top: 12px;\n margin-left: 0;\n margin-right: 0;\n"],["\n margin-top: 12px;\n margin-left: 0;\n margin-right: 0;\n"]))),VT=w.div(AT||(AT=Xe(["\n height: 1px;\n background-color: ",";\n margin-left: 24px;\n margin-right: 24px;\n"],["\n height: 1px;\n background-color: ",";\n margin-left: 24px;\n margin-right: 24px;\n"])),(function(e){return e.theme.palette.grey[100]})),WT=function(e){var n=e.table,t=e.notRemovableColumns,r=e.onChangeTableSettings,i=d(null),l=d(null),c=function(e){var n=[],t=[],r=[];return e.forEach((function(e){var o=!!e.columnDef.actionType;switch(e.id){case dD.TOGGLE:t[BD.FIRST]=e;break;case dD.CHECKBOX:t[BD.THIRD]=e;break;case dD.ROW_ACTIONS:n[BD.FIRST]=e}o||r.push(e)})),{rightActions:n,leftActions:t,accessorColumns:r}}(n.getAllColumns()),u=c.accessorColumns,p=c.rightActions,f=c.leftActions,m=s(u),g=m[0],h=m[1],v=s(!1),b=v[0],y=v[1],x=function(e){var t=f.map((function(e){return String(e.id)})),r=p.map((function(e){return String(e.id)}));n.setColumnOrder(qe(qe(qe([],t,!0),e,!0),r,!0))},w=a((function(){return g.filter((function(e){return e.getIsVisible()})).length>1}),[g]),$=a((function(e,n){var t=g.filter((function(e){return!e.getIsVisible()})).map((function(e){return e.id}));n&&t.push(e),null==r||r("notVisibleColumns",{notVisibleColumns:n?t:t.filter((function(n){return n!==e}))})}),[g,r]),C=g.map((function(e,n){return o.createElement("div",{key:n,id:e.id,onDragEnter:function(){return function(e){if(l.current=e,null!==l.current&&null!==i.current){var n=qe([],g,!0),t=n[i.current];n.splice(i.current,1),n.splice(l.current,0,t),i.current=l.current,l.current=null,h(n),x(n.map((function(e){return String(e.id)})))}}(n)}},o.createElement(QT,{isRemovable:w()&&!(null==t?void 0:t.includes(String(e.id))),draggable:!0,onDragStart:function(e,t){return function(e,n,t){y(!0),i.current=n,e.dataTransfer.setDragImage(t,0,0)}(e,n,t)},onDragOver:function(e){return e.preventDefault()},onDragEnd:function(){y(!1),null==r||r("orderColumns",{orderColumns:g.map((function(e){return String(e.id)}))})},column:e,onChangeTableSettings:$}),b&&i.current===n&&o.createElement(VT,null))}));return o.createElement(YT,null,C)},GT=function(e){var n=e.table,t=e.visibleColumnsLabel,r=e.notRemovableColumns,i=e.onChangeTableSettings;return o.createElement(BT,{renderTitle:function(){return o.createElement(UT,null,t)},renderBody:function(){return o.createElement(WT,{table:n,preSettedColumns:["subject","category"],notRemovableColumns:r,onChangeTableSettings:i})}})},KT=w.div(FT||(FT=Xe(["\n display: flex;\n justify-content: flex-start;\n align-items: center;\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -khtml-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n"],["\n display: flex;\n justify-content: flex-start;\n align-items: center;\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -khtml-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n"]))),qT=w.div(LT||(LT=Xe(["\n margin-right: 4px;\n"],["\n margin-right: 4px;\n"]))),XT=w(Nr)(zT||(zT=Xe(["\n color: ",";\n"],["\n color: ",";\n"])),(function(e){return e.theme.palette.grey[300]})),QT=function(e){var n,t=e.column,r=e.draggable,i=e.onDragStart,a=e.onDragOver,l=e.onDragEnd,s=e.isRemovable,c=e.onChangeTableSettings,u=d(null);return o.createElement(KT,{ref:u,onDragOver:a},o.createElement(qT,{draggable:r,onDragStart:function(e){u.current&&i(e,u.current)},onDragEnd:l},o.createElement(XT,{icon:{icon:de}})),o.createElement(Zu,{value:t.getIsVisible(),text:null!==(n=t.columnDef.headerTitle)&&void 0!==n?n:String(t.columnDef.header),onClick:function(){t.toggleVisibility(),null==c||c(String(t.id),t.getIsVisible())},disabled:!s&&t.getIsVisible()}))},ZT=w(Mv)(HT||(HT=Xe(["\n margin-top: 12px;\n"],["\n margin-top: 12px;\n"])));!function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.SMALL=1]="SMALL",e[e.LARGE=2]="LARGE"}(jT||(jT={}));var JT,e_,n_,t_,r_,o_,i_,a_,l_,s_,d_,c_,u_,p_,f_,m_,g_,h_,v_,b_,y_,x_,w_,$_,C_,k_=function(e){var n=e.rowHeightLabel,t=e.unspecifiedRowsLabel,r=e.smallRowsLabel,i=e.largeRowsLabel,a=e.isDisabled,l=e.dimensionRow,s=e.onChangeTableSettings,d=x(UD).setRowSize,c=function(e){switch(e){default:case jT.UNSPECIFIED:return d(lD.UNSPECIFIED),lD.UNSPECIFIED;case jT.SMALL:return d(lD.SMALL),lD.SMALL;case jT.LARGE:return d(lD.LARGE),lD.LARGE}},u=function(){switch(l){default:case lD.UNSPECIFIED:return jT.UNSPECIFIED;case lD.SMALL:return jT.SMALL;case lD.LARGE:return jT.LARGE}},p=[{text:t,large:!1,disabled:a||!1},{text:r,large:!1,disabled:a||!1},{text:i,large:!1,disabled:a||!1}];return o.createElement(BT,{renderTitle:function(){return o.createElement(UT,null,n)},renderBody:function(){return o.createElement(ZT,{spacing:"xs",initialSelection:u(),options:p,onChange:function(e){null==s||s("dimensionRow",{dimensionRow:c(e)})}})}})},S_=w(Nr)(JT||(JT=Xe(["\n color: ",";\n"],["\n color: ",";\n"])),(function(e){return e.theme.palette.blue[700]})),E_=w.div(e_||(e_=Xe(["\n padding: 16px 24px;\n margin: 0;\n max-height: 220px;\n overflow: auto;\n"],["\n padding: 16px 24px;\n margin: 0;\n max-height: 220px;\n overflow: auto;\n"]))),D_=w.div(n_||(n_=Xe(["\n display: flex;\n align-items: center;\n"],["\n display: flex;\n align-items: center;\n"]))),T_=w.div(t_||(t_=Xe(["\n font-size: 14px;\n line-height: 21px;\n font-weight: 500;\n font-style: normal;\n"],["\n font-size: 14px;\n line-height: 21px;\n font-weight: 500;\n font-style: normal;\n"]))),__=w.div(r_||(r_=Xe(["\n background-color: ",";\n height: 24px;\n width: 24px;\n border-radius: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n margin-right: 10px;\n"],["\n background-color: ",";\n height: 24px;\n width: 24px;\n border-radius: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n margin-right: 10px;\n"])),(function(e){return e.theme.palette.grey[50]})),N_=function(e){var n=e.header,t=e.notRemovableColumns,r=e.dimensionRow,i=e.onChangeTableSettings,a=function(e){var n,t,r,o,i,a,l,s,d,c,u,p,f=e.column,m=(0,e.getContext)().table,g=0===(0,m.getRowModel)().rows.length,h=f.columnDef;return{table:m,isTableEmpty:g,displaySettingsLabel:null!==(t=null===(n=h.settingsDropdownConfig)||void 0===n?void 0:n.displaySettingsLabel)&&void 0!==t?t:"Impostazioni visualizzazione",visibleColumnsLabel:null!==(o=null===(r=h.settingsDropdownConfig)||void 0===r?void 0:r.visibleColumnsLabel)&&void 0!==o?o:"Colonne visibili",rowHeightLabel:null!==(a=null===(i=h.settingsDropdownConfig)||void 0===i?void 0:i.rowHeightLabel)&&void 0!==a?a:"Densità righe",unspecifiedRowsLabel:null!==(s=null===(l=h.settingsDropdownConfig)||void 0===l?void 0:l.unspecifiedRowsLabel)&&void 0!==s?s:"Non specificata",smallRowsLabel:null!==(c=null===(d=h.settingsDropdownConfig)||void 0===d?void 0:d.smallRowsLabel)&&void 0!==c?c:"Righe strette",largeRowsLabel:null!==(p=null===(u=h.settingsDropdownConfig)||void 0===u?void 0:u.largeRowsLabel)&&void 0!==p?p:"Righe larghe"}}(n),l=a.displaySettingsLabel,s=a.isTableEmpty,d=a.largeRowsLabel,c=a.rowHeightLabel,u=a.smallRowsLabel,p=a.table,f=a.unspecifiedRowsLabel,m=a.visibleColumnsLabel;return o.createElement(E_,null,o.createElement(D_,null,o.createElement(__,null,o.createElement(S_,{icon:{icon:Ne,color:"grey",size:"sm"}})),o.createElement(T_,null,l)),o.createElement(GT,{table:p,visibleColumnsLabel:m,notRemovableColumns:t,onChangeTableSettings:i}),o.createElement(k_,{rowHeightLabel:c,unspecifiedRowsLabel:f,smallRowsLabel:u,largeRowsLabel:d,isDisabled:s,dimensionRow:r,onChangeTableSettings:i}))},P_=function(e){var n=e.header,t=e.onOpen,r=e.onClose,i=e.notRemovableColumns,l=e.dimensionRow,s=e.onChangeTableSettings,d=a((function(){return o.createElement(S_,{icon:{icon:ce,size:"sm"}})}),[]);return o.createElement(zr,{placement:"left-start",renderTrigger:d,onOpen:t,onClose:r,renderContent:function(){return o.createElement(N_,{header:n,notRemovableColumns:i,dimensionRow:l,onChangeTableSettings:s})}})},M_=w.span(o_||(o_=Xe(["\n font-size: 12px;\n line-height: 18px;\n color: ",";\n"],["\n font-size: 12px;\n line-height: 18px;\n color: ",";\n"])),(function(e){return e.theme.palette.grey[500]})),O_=w.div(s_||(s_=Xe(["\n border-width: 0px 1px 1px 0px;\n border-style: solid;\n border-color: ",";\n background-color: ",";\n height: ","px;\n ","\n ",";\n ",";\n display: flex;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"],["\n border-width: 0px 1px 1px 0px;\n border-style: solid;\n border-color: ",";\n background-color: ",";\n height: ","px;\n ","\n ",";\n ",";\n display: flex;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"])),(function(e){return e.theme.palette.grey[100]}),(function(e){return e.theme.palette.grey[50]}),(function(e){return e.size||lD.SMALL}),(function(e){return e.sortable&&C(i_||(i_=Xe(["\n cursor: pointer;\n user-select: none;\n "],["\n cursor: pointer;\n user-select: none;\n "])))}),(function(e){var n=e.minWidth;return n&&C(a_||(a_=Xe(["\n min-width: ","px;\n "],["\n min-width: ","px;\n "])),n)}),(function(e){var n=e.maxWidth;return n&&C(l_||(l_=Xe(["\n max-width: ","px;\n "],["\n max-width: ","px;\n "])),n)})),R_=w.span(d_||(d_=Xe(["\n margin: 8px;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"],["\n margin: 8px;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n flex-direction: row;\n flex-wrap: nowrap;\n align-items: center;\n"]))),I_=w.div(c_||(c_=Xe(["\n display: flex;\n align-items: center;\n padding: 8px;\n"],["\n display: flex;\n align-items: center;\n padding: 8px;\n"]))),A_=function(e){var n=e.header,t=e.onOpen,r=e.forceHideSettings,i=e.rowSelection,a=e.setRowSelection,l=e.notRemovableColumns,s=e.dimensionRow,d=e.onChangeTableSettings,c=function(e){var n,t=e.column,r=(0,e.getContext)().table,o=t.columnDef,i=o.actionType,a=null===(n=o.rowActions)||void 0===n?void 0:n.headerTitle,l=!!o.enableSettings,s=t.getCanSort(),d=!!t.getIsSorted();return{actionType:i,isSortedDesc:!1===t.getIsSorted()?null:t.getIsSorted(),isSorted:d,toggleSortable:dD.TOGGLE&&s,table:r,canSort:s,headerTitle:a,allColumns:e.getContext().table.getAllColumns(),isSettingsEnabled:l}}(n),u=c.actionType,p=c.isSorted,f=c.isSortedDesc,m=c.toggleSortable,g=c.table,h=c.headerTitle,v=c.isSettingsEnabled;switch(u){case dD.TOGGLE:return o.createElement(I_,null,o.createElement(KD,{checked:p}),m&&o.createElement(_T,{isSorted:p,isSortedDesc:"desc"===f,icon:U}));case dD.CHECKBOX:return o.createElement(I_,{style:{paddingLeft:8},id:"DS-checkbox-table-header"},o.createElement(Zu,{value:g.getIsAllPageRowsSelected()||(i&&i.length>0?Ou.INDETERMINATE:Ou.UNCHECKED),onChange:function(){a&&!g.getIsAllPageRowsSelected()&&a([]),(g.getIsAllPageRowsSelected()||i&&0===i.length)&&g.toggleAllPageRowsSelected()}}));case dD.ROW_ACTIONS:return o.createElement(I_,null,h&&o.createElement(M_,null,h),v&&!r&&o.createElement(P_,{header:n,onOpen:t,notRemovableColumns:l,dimensionRow:s,onChangeTableSettings:d}));default:return o.createElement(o.Fragment,null)}},F_=function(e){var n=e.header,t=e.headerSize,r=e.onSort,i=e.customSorted,l=e.setCustomSorted,d=e.forceHideSettings,c=e.rowSelection,u=e.setRowSelection,p=e.notRemovableColumns,f=e.dimensionRow,m=e.onChangeTableSettings,g=function(e){var n=e.column,t=n.columnDef.actionType,r=n.getCanSort(),o=!!n.getIsSorted(),i=!1===n.getIsSorted()?null:n.getIsSorted();return{column:n,actionType:t,canSort:r,isSorted:o,isSortedDesc:i,minWidth:n.columnDef.minWidth,maxWidth:n.columnDef.maxWidth,tooltip:n.columnDef.headerTooltip}}(n),h=g.column,v=g.actionType,b=g.canSort,y=g.isSorted,x=g.isSortedDesc,w=g.minWidth,C=g.tooltip,k=g.maxWidth,S=$(),E=s(!1),D=E[0],T=E[1],_=a((function(e){var t,o;r?b&&(null==l||l(((t={})[n.id]=MT(i),t)),r({sortBy:n.id,direction:MT(i)}),n.getContext().table.setPageIndex(1)):null===(o=h.getToggleSortingHandler())||void 0===o||o(e)}),[r,h,n,l,i,b]);return o.createElement(O_,{className:"DS-rt-th",size:t,minWidth:w,maxWidth:k,sortable:b,onClick:_,style:Ye({maxWidth:k},qD({isHeader:!0,theme:S,isPinned:h.getIsPinned(),isPopoverActive:D}))},o.createElement(L_,Ye({},null!=C?C:yl,{showAfterSeconds:.5}),v?o.createElement(A_,{header:n,onOpen:function(e){T(e)},forceHideSettings:d,rowSelection:c,setRowSelection:u,notRemovableColumns:p,dimensionRow:f,onChangeTableSettings:m}):o.createElement(R_,null,o.createElement(M_,null,n.isPlaceholder?null:aD(n.column.columnDef.header,n.getContext())),b&&o.createElement(_T,{isSorted:y||!!i,isSortedDesc:"desc"===x||"desc"===i,icon:U}))))},L_=w(xl)(u_||(u_=Xe(["\n width: 100%;\n"],["\n width: 100%;\n"]))),z_=function(e){var n=e.headerGroup,t=e.headerSize,r=e.onSort,i=e.forceHideSettings,a=e.rowSelection,l=e.setRowSelection,d=e.preSettedTableSettings,c=e.onChangeTableSettings,u=e.notRemovableColumns,p=s(),f=p[0],m=p[1];return o.createElement(H_,{className:"DS-rt-thead DS-header"},n.map((function(e){return o.createElement("div",{key:e.id,className:"DS-rt-tr"},e.headers.map((function(e){var n=null==f?void 0:f[e.id];return o.createElement(F_,{key:e.id,header:e,headerSize:t,onSort:r,customSorted:n,setCustomSorted:m,forceHideSettings:i,rowSelection:a,setRowSelection:l,notRemovableColumns:u,dimensionRow:null==d?void 0:d.dimensionRow,onChangeTableSettings:c})})))})))},H_=w.div(p_||(p_=Xe([""],[""]))),j_=function(e){var n,t,i=e.data,d=e.columns,c=e.isSelectable,u=e.toggles,p=e.onTogglesChange,f=e.headerSize,m=e.isTogglesSortable,g=void 0!==m&&m,h=e.sortable,v=void 0===h||h,b=e.sortDescFirst,y=void 0===b||b,x=e.enableSettings,w=void 0===x||x,$=e.settingsDropdownConfig,C=e.rowActions,k=e.bulkActions,S=e.isLoading,E=e.allSelectedCTA,D=e.noPagination,T=void 0===D||D,_=e.pageSize,N=void 0===_?10:_,P=e.listSize,M=e.paginationPreviousText,O=void 0===M?"Indietro":M,R=e.paginationNextText,I=void 0===R?"Avanti":R,A=e.onPaginationChange,F=e.uniqueId,L=e.onSort,z=e.renderEmptyState,H=e.onRowClick,j=e.bodyHeight,B=e.totalPages,U=e.rowIdHighlight,Y=e.rowHighlightColor,V=e.rowSelection,W=e.onRowSelection,G=e.forceHideSettings,K=void 0!==G&&G,q=e.renderBulkActions,X=e.preSettedTableSettings,Z=e.onChangeTableSettings,J=e.notRemovableColumns,ee=e.rowSize,ne=PT({columns:d,isSelectable:c,toggles:u,isTogglesSortable:g,onTogglesChange:p,rowActions:C,enableSettings:w,settingsDropdownConfig:$,preSettedTableSettings:X}),te=function(e){var n=s(e||{left:[],right:[]});return{columnPinning:n[0],setColumnPinning:n[1]}}({right:[dD.ROW_ACTIONS]}),re=te.columnPinning,oe=te.setColumnPinning,ie=function(e){var n=s({pageIndex:1,pageSize:e}),t=n[0];return{pageIndex:t.pageIndex,pageSize:t.pageSize,setPagination:n[1]}}(N),ae=ie.pageSize,le=ie.pageIndex,se=ie.setPagination,de=o.useMemo((function(){return{pageIndex:le,pageSize:ae}}),[le,ae]),ce=Q(A);l((function(){var e;null===(e=ce.current)||void 0===e||e.call(ce,de)}),[de,ce]);var ue=a((function(){return null==V?void 0:V.reduce((function(e,n){var t;return Ye(Ye({},e),((t={})[n]=!0,t))}),{})}),[V]),pe={columnVisibility:o.useMemo((function(){return(null==X?void 0:X.notVisibleColumns)?null==X?void 0:X.notVisibleColumns.reduce((function(e,n){return n&&(e[n]=!1),e}),{}):{}}),[null==X?void 0:X.notVisibleColumns])},fe=function(e){const n={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[t]=r.useState((()=>({current:oD(n)}))),[o,i]=r.useState((()=>t.current.initialState));return t.current.setOptions((n=>({...n,...e,state:{...o,...e.state},onStateChange:n=>{i(n),null==e.onStateChange||e.onStateChange(n)}}))),t.current}(Ye(Ye({data:i,columns:ne,enableSorting:v,sortDescFirst:y,getCoreRowModel:e=>yE((()=>[e.options.data]),(n=>{const t={rows:[],flatRows:[],rowsById:{}},r=function(n,o,i){void 0===o&&(o=0);const a=[];for(let s=0;s<n.length;s++){const d=iD(e,e._getRowId(n[s],s,i),n[s],s,o);var l;t.flatRows.push(d),t.rowsById[d.id]=d,a.push(d),e.options.getSubRows&&(d.originalSubRows=e.options.getSubRows(n[s],s),null!=(l=d.originalSubRows)&&l.length&&(d.subRows=r(d.originalSubRows,o+1,d)))}return a};return t.rows=r(n),t}),{key:"development"===process.env.NODE_ENV&&"getRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getSortedRowModel:e=>yE((()=>[e.getState().sorting,e.getPreSortedRowModel()]),((n,t)=>{if(!t.rows.length||null==n||!n.length)return t;const r=e.getState().sorting,o=[],i=r.filter((n=>e.getColumn(n.id).getCanSort())),a={};i.forEach((n=>{const t=e.getColumn(n.id);a[n.id]={sortUndefined:t.columnDef.sortUndefined,invertSorting:t.columnDef.invertSorting,sortingFn:t.getSortingFn()}}));const l=e=>{const n=e.slice();return n.sort(((e,n)=>{for(let r=0;r<i.length;r+=1){var t;const o=i[r],l=a[o.id],s=null!=(t=null==o?void 0:o.desc)&&t;if(l.sortUndefined){const t=void 0===e.getValue(o.id),r=void 0===n.getValue(o.id);if(t||r)return t&&r?0:t?l.sortUndefined:-l.sortUndefined}let d=l.sortingFn(e,n,o.id);if(0!==d)return s&&(d*=-1),l.invertSorting&&(d*=-1),d}return e.index-n.index})),n.forEach((e=>{o.push(e),!e.subRows||e.subRows.length<=1||(e.subRows=l(e.subRows))})),n};return{rows:l(t.rows),flatRows:o,rowsById:t.rowsById}}),{key:"development"===process.env.NODE_ENV&&"getSortedRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}}),getPaginationRowModel:e=>yE((()=>[e.getState().pagination,e.getPrePaginationRowModel(),e.options.paginateExpandedRows?void 0:e.getState().expanded]),((n,t)=>{if(!t.rows.length)return t;const{pageSize:r,pageIndex:o}=n;let{rows:i,flatRows:a,rowsById:l}=t;const s=r*o,d=s+r;let c;i=i.slice(s,d),c=e.options.paginateExpandedRows?{rows:i,flatRows:a,rowsById:l}:function(e){const n=[],t=e=>{var r;n.push(e),null!=(r=e.subRows)&&r.length&&e.getIsExpanded()&&e.subRows.forEach(t)};return e.rows.forEach(t),{rows:n,flatRows:e.flatRows,rowsById:e.rowsById}}({rows:i,flatRows:a,rowsById:l}),c.flatRows=[];const u=e=>{c.flatRows.push(e),e.subRows.length&&e.subRows.forEach(u)};return c.rows.forEach(u),c}),{key:"development"===process.env.NODE_ENV&&"getPaginationRowModel",debug:()=>{var n;return null!=(n=e.options.debugAll)?n:e.options.debugTable}}),pageCount:P,state:Ye({pagination:de,columnPinning:re},V&&{rowSelection:ue()}),onColumnPinningChange:oe,onPaginationChange:se,manualPagination:!0,getRowId:function(e){return String(e[F])},manualSorting:!!L},W&&{onRowSelectionChange:function(e){var n;"function"==typeof e&&W(Object.keys(e(null!==(n=ue())&&void 0!==n?n:{})))}}),{initialState:pe})),me=fe.getHeaderGroups,ge=fe.getRowModel,he=fe.getFooterGroups,ve=fe.previousPage,be=fe.nextPage,ye=fe.setPageIndex,xe=(0,fe.getIsAllRowsSelected)(),we=!S&&z&&0===i.length;return o.createElement(ET,null,o.createElement(YD,{defaultRowSize:(null===(n=X)||void 0===n?void 0:n.dimensionRow)||ee},o.createElement(DT,null,o.createElement(kT,{renderBulkActions:q,bulkBarActions:k,selectedRowData:null!=V?V:[],allSelectedCTA:xe?E:void 0}),o.createElement(TT,{className:"DS-ReactTable DS-rt-table"},o.createElement(z_,{headerGroup:me(),headerSize:f,onSort:L,forceHideSettings:K,rowSelection:V,setRowSelection:W,preSettedTableSettings:X,onChangeTableSettings:Z,notRemovableColumns:J}),we?o.createElement(o.Fragment,null,z()):o.createElement(bT,{pageIndex:le,rows:ge().rows,rowSize:(null===(t=X)||void 0===t?void 0:t.dimensionRow)||ee,isLoading:S,onRowClick:H,bodyHeight:j,rowIdHighlight:U,rowHighlightColor:Y}),o.createElement(ST,{footerGroup:he()}),!T&&!we&&o.createElement(NT,null,o.createElement(xC,{changePageAction:function(e){return ye(e)},nextPageAction:be,prevPageAction:ve,nextText:I,prevText:O,listSize:P||i.length,totalPages:B,pageSize:ae,currentPage:le}))))))},B_=w.div(f_||(f_=Xe(["\n width: 90vw;\n margin: 0 auto;\n text-align: center;\n @media screen and (min-width: 768px) {\n width: 376px;\n }\n .icon {\n background-color: ",";\n width: 176px;\n height: 176px;\n border-radius: 50%;\n color: ",";\n margin: 0 auto;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 76px;\n }\n h5 {\n margin-top: 2rem;\n margin-bottom: 0;\n font-weight: 500;\n font-size: 20px;\n line-height: 30px;\n color: ",";\n }\n p {\n margin-top: 0.5rem;\n margin-bottom: 1.5rem;\n font-weight: 400;\n font-size: 14px;\n line-height: 21px;\n color: ",";\n }\n"],["\n width: 90vw;\n margin: 0 auto;\n text-align: center;\n @media screen and (min-width: 768px) {\n width: 376px;\n }\n .icon {\n background-color: ",";\n width: 176px;\n height: 176px;\n border-radius: 50%;\n color: ",";\n margin: 0 auto;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 76px;\n }\n h5 {\n margin-top: 2rem;\n margin-bottom: 0;\n font-weight: 500;\n font-size: 20px;\n line-height: 30px;\n color: ",";\n }\n p {\n margin-top: 0.5rem;\n margin-bottom: 1.5rem;\n font-weight: 400;\n font-size: 14px;\n line-height: 21px;\n color: ",";\n }\n"])),(function(e){return e.theme.palette.red[50]}),(function(e){return e.theme.palette.red[500]}),(function(e){return e.theme.palette.black[100]}),(function(e){return e.theme.palette.black[80]})),U_=function(e){var n=e.action,t=e.icon,r=e.text,a=e.title,l=i((function(){return n?o.createElement(_r,{onClick:function(){return n.action()},iconLeft:n.icon?n.icon:void 0,text:n.text,color:"green"}):null}),[n]);return o.createElement(B_,null,t&&o.createElement("div",{className:"icon"},o.createElement(cn,Ye({},t))),a&&o.createElement("h5",null,a),r&&o.createElement("p",null,r),l)},Y_=w.span(m_||(m_=Xe(["\n background: ",";\n width: 100%;\n height: 4px;\n margin-top: 6px;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"],["\n background: ",";\n width: 100%;\n height: 4px;\n margin-top: 6px;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"])),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:"transparent"}),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[500]}),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[900]})),V_=w.span(g_||(g_=Xe(["\n font-family: 'Inter UI', sans-serif;\n font-style: normal;\n font-size: 14px;\n font-weight: 500;\n line-height: 21px;\n\n align-items: center;\n display: flex;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"],["\n font-family: 'Inter UI', sans-serif;\n font-style: normal;\n font-size: 14px;\n font-weight: 500;\n line-height: 21px;\n\n align-items: center;\n display: flex;\n\n color: ",";\n\n &:hover {\n color: ",";\n }\n"])),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[500]}),(function(e){var n=e.active,t=e.theme;return n?t.palette.primary[500]:t.palette.grey[900]})),W_=function(e){var n=e.active,t=e.handleClick,r=e.tabRef,i=e.text,a=e.tooltip,l=e.badge,s=o.createElement(G_,{ref:null==r?void 0:r(),onClick:t},o.createElement(K_,Ye({className:"item-badge",isDisabled:!0},l),o.createElement(V_,{active:n},i)),o.createElement(Y_,{active:n}));return a?o.createElement(xl,Ye({},a),s):s},G_=w.div(h_||(h_=Xe(["\n cursor: pointer;\n flex-shrink: 0;\n position: relative;\n padding: 0;\n display: flex;\n flex-direction: column;\n"],["\n cursor: pointer;\n flex-shrink: 0;\n position: relative;\n padding: 0;\n display: flex;\n flex-direction: column;\n"]))),K_=w(sy)(v_||(v_=Xe(["\n height: 8px;\n min-width: 8px;\n"],["\n height: 8px;\n min-width: 8px;\n"]))),q_=w.div(y_||(y_=Xe(["\n box-sizing: border-box;\n height: 31px;\n alignment-baseline: baseline;\n display: flex;\n white-space: nowrap;\n margin-top: 3px;\n width: 100%;\n\n ",";\n\n & > *:first-child {\n padding-left: ","px;\n }\n\n & > *:last-child {\n padding-right: ","px;\n }\n\n & > * + * {\n margin-left: ","px;\n }\n"],["\n box-sizing: border-box;\n height: 31px;\n alignment-baseline: baseline;\n display: flex;\n white-space: nowrap;\n margin-top: 3px;\n width: 100%;\n\n ",";\n\n & > *:first-child {\n padding-left: ","px;\n }\n\n & > *:last-child {\n padding-right: ","px;\n }\n\n & > * + * {\n margin-left: ","px;\n }\n"])),(function(e){return e.hidden&&C(b_||(b_=Xe(["\n visibility: hidden;\n position: absolute;\n "],["\n visibility: hidden;\n position: absolute;\n "])))}),(function(e){return e.lateralPadding}),(function(e){return e.lateralPadding}),(function(e){return e.distance})),X_=w(q_)(x_||(x_=Xe(["\n max-width: 100%;\n overflow-x: auto;\n overflow-y: hidden;\n"],["\n max-width: 100%;\n overflow-x: auto;\n overflow-y: hidden;\n"]))),Q_=function(e){var n=e.active;return o.createElement(W_,{active:n,text:o.createElement(Z_,{icon:ue,fixedWidth:!0})})},Z_=w(cn)(w_||(w_=Xe(["\n height: 21px;\n"],["\n height: 21px;\n"]))),J_=function(e){var n=e.active,t=e.tabs,r=a((function(){return o.createElement(Q_,{active:n})}),[n]),i=a((function(e){return o.createElement(o.Fragment,null,t.map((function(n,t){var r=n.active,i=n.handleClick,a=n.text;return o.createElement(zr.Item,{key:t,text:a,active:r,onClick:function(){i&&i(),e()}})})))}),[t]);return o.createElement(eN,{placement:"bottom-end",fullWidth:!0,renderTrigger:r,renderContent:i})},eN=w(zr)($_||($_=Xe(["\n display: block;\n"],["\n display: block;\n"]))),nN=function(e){var n=e.className,t=e.distance,r=void 0===t?15:t,a=e.lateralPadding,l=void 0===a?23:a,d=e.tabs,c=function(){var e=Z(),n=e[0],t=e[1].width,r=s(0),o=r[0],i=r[1];return J((function(){return i(t)}),250,[t]),{elementsWrapperRef:n,wrapperWidth:o}}(),u=c.elementsWrapperRef,p=c.wrapperWidth,f=s(0)[1],m=d.length,g=i((function(){return Array.from(Array(m),(function(){return o.createRef()}))}),[m]),h=i((function(){return g.map((function(e){return function(){return f((function(e){return e+1})),e}}))}),[g]),v=function(e){var n=e.distance,t=e.lateralPadding,r=e.tabsLength,o=e.tabsRefs,a=e.wrapperWidth;return i((function(){for(var e,i=0,l=a-2*t;i!==r&&l>0;){var s=null===(e=o[i].current)||void 0===e?void 0:e.offsetWidth;s&&l-(s+n)>0?(i++,l-=s+n):l=-1}return{visibleCount:i}}),[n,t,r,o,a])}({distance:r,tabsLength:m,wrapperWidth:p,tabsRefs:g,lateralPadding:l}).visibleCount,b=i((function(){return d.map((function(e,n){return o.createElement(W_,Ye({key:n,tabRef:h[n]},e))}))}),[h,d]),y=i((function(){return d.slice(0,v).map((function(e,n){return o.createElement(W_,Ye({key:n},e))}))}),[d,v]),x=i((function(){return d.slice(v)}),[d,v]),w=0!==x.length,$=x.some((function(e){return e.active})),C=0===p;return o.createElement(o.Fragment,null,o.createElement(tN,{className:n,distance:r,lateralPadding:l,hidden:!C},b),o.createElement(q_,{className:n,distance:r,lateralPadding:l,hidden:C,ref:u},y,w&&o.createElement(J_,{active:$,tabs:x})))},tN=w(X_)(C_||(C_=Xe(["\n overflow-x: hidden;\n"],["\n overflow-x: hidden;\n"]))),rN=function(e){var n=e.className,t=e.distance,r=void 0===t?15:t,a=e.lateralPadding,l=void 0===a?23:a,s=e.tabs,d=i((function(){return s.map((function(e,n){return o.createElement(W_,Ye({key:n},e))}))}),[s]);return o.createElement(X_,{className:n,distance:r,lateralPadding:l},d)},oN=function(e){var n=e.children,t=e.theme;return o.createElement(S,{theme:t},o.createElement(o.Fragment,null,n))};export{zu as Accordion,ul as AsyncCreatableSelect,cl as AsyncSelect,or as Avatar,$b as Badge,Yb as BadgeSize,rb as BadgeType,Pb as Banner,xb as BannerType,gu as Body,_r as Button,ku as Caption,Fb as Card,Db as CardColor,Tb as CardElevation,Eb as CardType,Zu as Checkbox,Ou as CheckboxStatus,Xb as Chip,Ib as ChipType,sD as ColumnDefType,mE as ConfirmationModal,dl as CreatableSelect,jg as DatePicker,Uu as Drawer,zr as Dropdown,nN as DropdownTabs,Xl as EditableInput,av as FileUploader,Vb as FloatingBadgeType,Uv as GroupedList,Cu as Headline,cn as Icon,an as IconBackground,Nr as IconButton,gb as InlineMessage,Cv as InlineMessageType,Gr as InputCode,gn as InputHelper,ml as InputTelephone,kl as InputText,vb as MicroTag,VS as Modal,RS as ModalBody,WS as ModalSearchable,j_ as NewTable,ay as NotificationBadge,U_ as PageEmptySet,xC as Pagination,A$ as PaginationType,WC as ProgressBar,F$ as ProgressBarType,Tv as Radio,Mv as RadioGroup,Xh as RadioStatus,rN as ScrollableTabs,XC as SegmentButton,sl as Select,yk as ShortcutTip,Fw as SidebarBadgeConfigType,Gw as SidebarItem,fn as Spinner,ZS as StepModal,rE as StepModalBody,oE as StepModalFooter,iE as StepModalHeader,ok as Stepper,gC as Table,ck as Tag,Bl as TextArea,oN as ThemeProvider,vk as Tip,UC as TipType,vu as Title1,bu as Title2,yu as Title3,xu as Title4,wu as Title5,$u as Title6,DS as Toast,gk as ToastType,xl as Tooltip,sy as WithBadge,Dt as autocompleteYellow,tl as isSimpleValue,Bw as sidebarItemHeight,Lg as timeConversionOptions,TS as toastPalette,np as useCheckboxValue,Bg as useFormattedDate,Sv as useRadioValue,Fa as useSelectMultiValues,Ia as useSelectSimpleValue,Aa as useSelectValue,Kw as useTableValues};
56
56
  //# sourceMappingURL=index.esm.js.map