@ballistix.digital/react-components 0.5.10 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -15,8 +15,8 @@ var react = require('@headlessui/react');
15
15
  var mask = require('@react-input/mask');
16
16
  var outline$2 = require('@heroicons/react/24/outline');
17
17
  var reactTable = require('@tanstack/react-table');
18
- var set = require('lodash/set');
19
18
  var Select = require('react-tailwindcss-select');
19
+ var set = require('lodash/set');
20
20
  var Datepicker = require('react-tailwindcss-datepicker');
21
21
  var formik = require('formik');
22
22
 
@@ -1187,19 +1187,194 @@ var useExcel = function () {
1187
1187
  };
1188
1188
  };
1189
1189
 
1190
+ var base$e = {
1191
+ container: '',
1192
+ head: 'flex justify-between',
1193
+ body: 'relative rounded-md',
1194
+ foot: '',
1195
+ label: 'block font-medium text-gray-900',
1196
+ hint: 'text-xs text-gray-500',
1197
+ leading: 'pointer-events-none absolute inset-y-0 left-0 flex items-center',
1198
+ input: 'block w-full flex border',
1199
+ menuButton: '',
1200
+ menu: 'z-10 !px-0 !py-0 !w-full rounded-md overflow-hidden border !mt-1 absolute bg-white',
1201
+ tagItem: 'bg-gray-200 px-2 py-1 flex flex-row gap-x-1 items-center justify-between rounded-sm',
1202
+ tagItemText: 'text-xs',
1203
+ tagItemIconContainer: '!p-0 rounded-full hover:bg-gray-400 text-sm hover:text-white aspect-square w-4 flex items-center justify-center cursor-pointer',
1204
+ tagItemIcon: '',
1205
+ list: '!px-0 !w-full [&>*]:px-0 max-h-56 overflow-scroll !py-1',
1206
+ listGroupLabel: '',
1207
+ listItem: '!w-full !list-none hover:bg-primary-500 hover:text-white !py-2 !px-2',
1208
+ listDisabledItem: '',
1209
+ searchContainer: '!w-full !px-2 !py-2 border-b',
1210
+ searchBox: '',
1211
+ searchIcon: '',
1212
+ closeIcon: '',
1213
+ emptyState: 'w-full inline-flex items-start justify-start px-4',
1214
+ trailing: 'pointer-events-none absolute inset-y-0 right-0 flex items-center',
1215
+ description: 'text-gray-400 text-xs mt-1',
1216
+ error: 'text-red-500 text-xs ml-5 mt-1',
1217
+ };
1218
+ var leading$4 = {
1219
+ input: 'pl-10',
1220
+ };
1221
+ var trailing$4 = {};
1222
+ var normal$5 = {
1223
+ label: 'leading-6 text-sm mb-2',
1224
+ hint: 'leading-6',
1225
+ leading: 'pl-3',
1226
+ input: 'rounded-md border-gray-200 shadow-sm focus:border-primary-500 focus:ring-primary-500 sm:text-sm placeholder-gray-300',
1227
+ trailing: '',
1228
+ description: 'mt-2 text-sm',
1229
+ };
1230
+ var inset$4 = {
1231
+ container: 'rounded-md px-3 pt-2.5 pb-1.5 shadow-sm ring-1 ring-inset ring-gray-300 focus-within:ring-2 focus-within:ring-primary-600',
1232
+ label: 'text-xs',
1233
+ hint: 'text-xs',
1234
+ input: 'border-0 !ring-0 p-0 text-gray-900 placeholder:text-gray-400 focus:ring-0 sm:text-sm pl-0',
1235
+ description: 'hidden',
1236
+ };
1237
+ var overlapping$4 = {
1238
+ container: 'relative',
1239
+ head: ' absolute flex justify-between items-center left-0 -top-2 right-0 mx-2 z-10 w-full',
1240
+ label: 'inline-block bg-white px-1 text-xs font-medium text-gray-900 ',
1241
+ hint: 'text-xs mr-4 bg-white px-1',
1242
+ input: 'block w-full rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-primary-600 sm:text-sm sm:leading-6',
1243
+ description: 'hidden',
1244
+ };
1245
+ var pill$4 = {
1246
+ head: 'mx-px block px-4 text-sm font-medium leading-6 text-gray-900 mb-1 pr-6',
1247
+ foot: 'mx-px block px-4 text-sm font-medium leading-6 text-gray-900 mt-1 pr-6',
1248
+ input: 'block w-full rounded-full border-0 px-4 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-primary-600 sm:text-sm sm:leading-6',
1249
+ trailing: 'pr-2',
1250
+ description: 'text-xs',
1251
+ };
1252
+ var floored$4 = {
1253
+ body: 'relative mt-2',
1254
+ label: 'block text-sm font-medium leading-6 text-gray-900',
1255
+ input: 'peer block w-full border-0 bg-gray-50 py-1.5 text-gray-900 focus:ring-0 sm:text-sm sm:leading-6 ring-0',
1256
+ description: 'text-xs mt-2',
1257
+ };
1258
+ var invalid$4 = {
1259
+ container: 'ring-red-500',
1260
+ input:
1261
+ // 'block w-full border border-transparent text-red-900 ring-1 ring-inset ring-red-300 placeholder:text-red-300 focus:ring-2 focus:ring-inset focus:ring-red-500 sm:leading-6 pr-10',
1262
+ 'block w-full border border-transparent text-red-900 ring-1 ring-inset ring-red-300 placeholder:text-red-300 focus:ring-2 focus:ring-inset focus:ring-red-500',
1263
+ description: 'text-sm text-red-600',
1264
+ };
1265
+ var disabled$5 = {
1266
+ input: 'block w-full rounded-md border-0 text-gray-900 shadow-sm ring-1 ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-primary-600 cursor-not-allowed bg-gray-50 text-gray-500 ring-gray-200',
1267
+ };
1268
+ var styles$h = {
1269
+ base: base$e,
1270
+ leading: leading$4,
1271
+ trailing: trailing$4,
1272
+ normal: normal$5,
1273
+ inset: inset$4,
1274
+ overlapping: overlapping$4,
1275
+ pill: pill$4,
1276
+ floored: floored$4,
1277
+ invalid: invalid$4,
1278
+ disabled: disabled$5,
1279
+ };
1280
+
1281
+ var SelectMenuForm = function (props) {
1282
+ var _a;
1283
+ var _b = props.name, name = _b === void 0 ? 'select-menu-form' : _b, label = props.label, description = props.description, placeholder = props.placeholder, options = props.options, required = props.required, value = props.value, error = props.error, _c = props.isRequired, isRequired = _c === void 0 ? false : _c, isLoading = props.isLoading, _d = props.isTouched, isTouched = _d === void 0 ? false : _d, isDisabled = props.isDisabled, _e = props.isClearable, isClearable = _e === void 0 ? true : _e, _f = props.isMultiple, isMultiple = _f === void 0 ? false : _f, _g = props.isSearchable, isSearchable = _g === void 0 ? true : _g, _h = props.isSolo, isSolo = _h === void 0 ? false : _h, onChange = props.onChange, onSearchInputChange = props.onSearchInputChange, onClear = props.onClear, onBlur = props.onBlur, stylesOverrides = props.styles;
1284
+ var _j = React.useState(true), isFocus = _j[0], setIsFocus = _j[1];
1285
+ var _k = React.useState(value !== null && value !== void 0 ? value : null), state = _k[0], setState = _k[1];
1286
+ var isValid = error === undefined;
1287
+ var handleGenerateStyle = function () {
1288
+ var result = deepCopyObject(styles$h.base);
1289
+ var keys = calculateNestedKeys(styles$h.base);
1290
+ keys.forEach(function (key) {
1291
+ lodash.set(result, key, toClassName(lodash.get(styles$h.base, key), lodash.get(styles$h['normal'], key), isTouched === true && !isValid && lodash.get(styles$h.invalid, key), isDisabled && lodash.get(styles$h.disabled, key), lodash.get(stylesOverrides, key)));
1292
+ });
1293
+ return result;
1294
+ };
1295
+ var handleChange = function (selectValue) {
1296
+ setState(selectValue);
1297
+ onChange && onChange(selectValue);
1298
+ setIsFocus(false);
1299
+ };
1300
+ var styles = handleGenerateStyle();
1301
+ // Simulate onClear event.
1302
+ React.useEffect(function () {
1303
+ if (state === null && !isFocus) {
1304
+ onClear && onClear(name);
1305
+ }
1306
+ // eslint-disable-next-line react-hooks/exhaustive-deps
1307
+ }, [state]);
1308
+ // Simulate onBlur event.
1309
+ React.useEffect(function () {
1310
+ if (!isFocus) {
1311
+ onBlur && onBlur();
1312
+ }
1313
+ // eslint-disable-next-line react-hooks/exhaustive-deps
1314
+ }, [isFocus]);
1315
+ // listen to value changes.
1316
+ React.useEffect(function () {
1317
+ setState(value);
1318
+ }, [value]);
1319
+ return (jsxRuntime.jsxs("div", { className: styles.container, children: [jsxRuntime.jsxs("div", { className: styles.head, children: [label && (jsxRuntime.jsx("label", { htmlFor: name, className: styles.label, children: label })), !required && !isRequired && typeof label === 'string' && (jsxRuntime.jsx("span", { className: styles.hint, children: "Optional" })), required && required({ isRequired: isRequired })] }), jsxRuntime.jsxs("div", { className: styles.container, children: [jsxRuntime.jsx(Select, { primaryColor: "primary",
1320
+ //
1321
+ placeholder: placeholder === null || placeholder === void 0 ? void 0 : placeholder.select, noOptionsMessage: (jsxRuntime.jsx("p", { className: styles.emptyState, children: (_a = placeholder === null || placeholder === void 0 ? void 0 : placeholder.emptyState) !== null && _a !== void 0 ? _a : 'No results found' })), searchInputPlaceholder: placeholder === null || placeholder === void 0 ? void 0 : placeholder.searchInput,
1322
+ //
1323
+ loading: isLoading, isDisabled: isDisabled, isClearable: isClearable, isMultiple: isMultiple, isSearchable: isSearchable,
1324
+ //
1325
+ options: options,
1326
+ //
1327
+ value: state, onChange: handleChange, onSearchInputChange: onSearchInputChange,
1328
+ //
1329
+ classNames: {
1330
+ menuButton: function () {
1331
+ return toClassName(styles.input, state === null && '[&>*]:!text-gray-300 ', state === null &&
1332
+ !isValid &&
1333
+ isTouched &&
1334
+ '[&>*]:!text-red-300');
1335
+ },
1336
+ menu: styles.menu,
1337
+ tagItem: function () { return styles.tagItem; },
1338
+ tagItemText: styles.tagItemText,
1339
+ tagItemIconContainer: styles.tagItemIconContainer,
1340
+ tagItemIcon: styles.tagItemIcon,
1341
+ list: styles.list,
1342
+ listItem: function () { return styles.listItem; },
1343
+ listDisabledItem: styles.listDisabledItem,
1344
+ listGroupLabel: styles.listGroupLabel,
1345
+ searchContainer: styles.searchContainer,
1346
+ searchBox: styles.searchBox,
1347
+ searchIcon: styles.searchIcon,
1348
+ closeIcon: styles.closeIcon,
1349
+ } }), !isSolo && (jsxRuntime.jsxs("div", { className: styles.foot, children: [description && !(error && isTouched) && (jsxRuntime.jsx("p", { className: styles.description, children: description })), error && isTouched && (jsxRuntime.jsx("p", { className: styles.error, children: JSON.stringify(error).replaceAll('"', '') }))] }))] })] }));
1350
+ };
1351
+
1190
1352
  var PanelPaginationNavigation = function (props) {
1191
- var defaultValue = props.current, _a = props.min, min = _a === void 0 ? 1 : _a, _b = props.max, max = _b === void 0 ? 20 : _b, stylesOverrides = props.styles, children = props.children, onChange = props.onChange;
1192
- var _c = React.useState(1), current = _c[0], setCurrent = _c[1];
1353
+ var defaultValue = props.current, _a = props.min, min = _a === void 0 ? 1 : _a, _b = props.max, max = _b === void 0 ? 20 : _b, stylesOverrides = props.styles, pageSizeOptions = props.pageSizeOptions, defaultPageSize = props.defaultPageSize, _c = props.onChangePageSize, onChangePageSize = _c === void 0 ? lodash.noop : _c, children = props.children, onChange = props.onChange;
1354
+ var _d = React.useState(1), current = _d[0], setCurrent = _d[1];
1355
+ var _e = React.useState({
1356
+ value: "".concat(defaultPageSize),
1357
+ label: "".concat(defaultPageSize),
1358
+ }), pageSize = _e[0], setPageSize = _e[1];
1193
1359
  React.useEffect(function () {
1194
1360
  if (defaultValue) {
1195
1361
  setCurrent(defaultValue);
1196
1362
  }
1197
1363
  }, [defaultValue]);
1364
+ var hasCustomizablePageSize = React.useMemo(function () { return !!pageSizeOptions; }, [pageSizeOptions]);
1365
+ var pageSizeMenuOptions = React.useMemo(function () {
1366
+ var options = lodash.map(pageSizeOptions, function (option) { return ({
1367
+ value: "".concat(option),
1368
+ label: "".concat(option),
1369
+ }); });
1370
+ !pageSize && setPageSize(options[0]);
1371
+ return options;
1372
+ }, [pageSize, pageSizeOptions]);
1198
1373
  var handleGenerateStyle = function () {
1199
- var result = deepCopyObject(styles$h.base);
1200
- var keys = calculateNestedKeys(styles$h.base);
1374
+ var result = deepCopyObject(styles$g.base);
1375
+ var keys = calculateNestedKeys(styles$g.base);
1201
1376
  keys.forEach(function (key) {
1202
- lodash.set(result, key, toClassName(lodash.get(styles$h.base, key), lodash.get(stylesOverrides, key)));
1377
+ lodash.set(result, key, toClassName(lodash.get(styles$g.base, key), lodash.get(stylesOverrides, key)));
1203
1378
  });
1204
1379
  return result;
1205
1380
  };
@@ -1236,10 +1411,18 @@ var PanelPaginationNavigation = function (props) {
1236
1411
  component = (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx("button", { className: toClassName(styles.button.default, current === min && styles.button.active), onClick: function () { return handleChangeCurrent(min); }, children: min }), max >= min + 1 && (jsxRuntime.jsx("button", { className: toClassName(styles.button.default, current === min + 1 && styles.button.active), onClick: function () { return handleChangeCurrent(min + 1); }, children: min + 1 })), max >= min + 2 && (jsxRuntime.jsx("button", { className: toClassName(styles.button.default, current === min + 2 && styles.button.active), onClick: function () { return handleChangeCurrent(min + 2); }, children: min + 2 })), max >= min + 3 && (jsxRuntime.jsx("button", { className: toClassName(styles.button.default, current === min + 3 && styles.button.active), onClick: function () { return handleChangeCurrent(min + 3); }, children: min + 3 }))] }));
1237
1412
  break;
1238
1413
  }
1239
- return (jsxRuntime.jsxs("div", { className: styles.container, children: [jsxRuntime.jsxs("div", { className: "flex flex-1 justify-between sm:hidden", children: [jsxRuntime.jsx("button", { className: toClassName(styles.mobile.button, current === min && styles.button.disabled), disabled: current === min, onClick: function () { return handleChangeCurrent(current - 1); }, children: "Previous" }), jsxRuntime.jsx("button", { className: toClassName(styles.mobile.button, current === max && styles.button.disabled), disabled: current === max, onClick: function () { return handleChangeCurrent(current + 1); }, children: "Next" })] }), jsxRuntime.jsxs("div", { className: styles.desktop.container, children: [jsxRuntime.jsx("div", { children: jsxRuntime.jsx("div", { className: "text-sm text-gray-700", children: children && children({ min: min, max: max, current: current }) }) }), jsxRuntime.jsx("div", { children: jsxRuntime.jsxs("nav", { className: styles.desktop.navigation, "aria-label": "Pagination", children: [jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.outerLeftButton, current === min && styles.button.disabled), disabled: current === min, onClick: function () { return handleChangeCurrent(1); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "First" }), jsxRuntime.jsx(solid.ChevronDoubleLeftIcon, { className: styles.icon, "aria-hidden": "true" })] }), jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.innerButton, current === min && styles.button.disabled), disabled: current === min, onClick: function () { return handleChangeCurrent(current - 1); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "Previous" }), jsxRuntime.jsx(solid.ChevronLeftIcon, { className: styles.icon, "aria-hidden": "true" })] }), component, jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.innerButton, current === max && styles.button.disabled), disabled: current === max, onClick: function () { return handleChangeCurrent(current + 1); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "Next" }), jsxRuntime.jsx(solid.ChevronRightIcon, { className: styles.icon, "aria-hidden": "true" })] }), jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.outerRightButton, current === max && styles.button.disabled), disabled: current === max, onClick: function () { return handleChangeCurrent(max); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "Last" }), jsxRuntime.jsx(solid.ChevronDoubleRightIcon, { className: styles.icon, "aria-hidden": "true" })] })] }) })] })] }));
1414
+ return (jsxRuntime.jsxs("div", { className: styles.container, children: [jsxRuntime.jsxs("div", { className: "flex flex-1 justify-between sm:hidden", children: [jsxRuntime.jsx("button", { className: toClassName(styles.mobile.button, current === min && styles.button.disabled), disabled: current === min, onClick: function () { return handleChangeCurrent(current - 1); }, children: "Previous" }), hasCustomizablePageSize && (jsxRuntime.jsx(SelectMenuForm, { name: "pageSize", isClearable: false, isSearchable: false, isMultiple: false, isSolo: true, options: pageSizeMenuOptions, value: pageSize, styles: { list: styles.pageSizeList }, onClear: lodash.noop, onChange: function (value) {
1415
+ if (onChangePageSize) {
1416
+ onChangePageSize(lodash.toSafeInteger(value === null || value === void 0 ? void 0 : value.value));
1417
+ }
1418
+ } })), jsxRuntime.jsx("button", { className: toClassName(styles.mobile.button, current === max && styles.button.disabled), disabled: current === max, onClick: function () { return handleChangeCurrent(current + 1); }, children: "Next" })] }), jsxRuntime.jsxs("div", { className: styles.desktop.container, children: [jsxRuntime.jsx("div", { children: jsxRuntime.jsx("div", { className: "text-sm text-gray-700", children: children && children({ min: min, max: max, current: current }) }) }), hasCustomizablePageSize && (jsxRuntime.jsx(SelectMenuForm, { name: "pageSize", isClearable: false, isSearchable: false, isMultiple: false, isSolo: true, options: pageSizeMenuOptions, value: pageSize, styles: { list: styles.pageSizeList }, onClear: lodash.noop, onChange: function (value) {
1419
+ if (onChangePageSize) {
1420
+ onChangePageSize(lodash.toSafeInteger(value === null || value === void 0 ? void 0 : value.value));
1421
+ }
1422
+ } })), jsxRuntime.jsx("div", { children: jsxRuntime.jsxs("nav", { className: styles.desktop.navigation, "aria-label": "Pagination", children: [jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.outerLeftButton, current === min && styles.button.disabled), disabled: current === min, onClick: function () { return handleChangeCurrent(1); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "First" }), jsxRuntime.jsx(solid.ChevronDoubleLeftIcon, { className: styles.icon, "aria-hidden": "true" })] }), jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.innerButton, current === min && styles.button.disabled), disabled: current === min, onClick: function () { return handleChangeCurrent(current - 1); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "Previous" }), jsxRuntime.jsx(solid.ChevronLeftIcon, { className: styles.icon, "aria-hidden": "true" })] }), component, jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.innerButton, current === max && styles.button.disabled), disabled: current === max, onClick: function () { return handleChangeCurrent(current + 1); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "Next" }), jsxRuntime.jsx(solid.ChevronRightIcon, { className: styles.icon, "aria-hidden": "true" })] }), jsxRuntime.jsxs("button", { className: toClassName(styles.desktop.outerRightButton, current === max && styles.button.disabled), disabled: current === max, onClick: function () { return handleChangeCurrent(max); }, children: [jsxRuntime.jsx("span", { className: styles.label, children: "Last" }), jsxRuntime.jsx(solid.ChevronDoubleRightIcon, { className: styles.icon, "aria-hidden": "true" })] })] }) })] })] }));
1240
1423
  };
1241
1424
 
1242
- var base$e = {
1425
+ var base$d = {
1243
1426
  container: 'flex items-center justify-between border-t border-gray-200 bg-white py-3',
1244
1427
  mobile: {
1245
1428
  container: '',
@@ -1260,9 +1443,10 @@ var base$e = {
1260
1443
  divider: 'relative inline-flex items-center border border-gray-300 bg-white px-4 py-2 text-sm font-medium text-gray-500',
1261
1444
  label: 'sr-only',
1262
1445
  icon: 'w-5 h-5',
1446
+ pageSizeList: '!overflow-hidden',
1263
1447
  };
1264
- var styles$h = {
1265
- base: base$e,
1448
+ var styles$g = {
1449
+ base: base$d,
1266
1450
  };
1267
1451
 
1268
1452
  var TableList = function (props) {
@@ -1270,10 +1454,10 @@ var TableList = function (props) {
1270
1454
  var id = props.id, columns = props.columns, data = props.data, page = props.page, children = props.children, defaultOrder = props.defaultOrder, defaultVisibility = props.defaultVisibility, _f = props.type, type = _f === void 0 ? 'normal' : _f, isLoading = props.isLoading, _g = props.isStriped, isStriped = _g === void 0 ? false : _g, _h = props.hasStickyHeader, hasStickyHeader = _h === void 0 ? false : _h, _j = props.hasVerticalSeparators, hasVerticalSeparators = _j === void 0 ? false : _j, _k = props.areControlsVisible, areControlsVisible = _k === void 0 ? true : _k, customControls = props.customControls, _l = props.exportFileName, exportFileName = _l === void 0 ? 'table-export' : _l, stylesOverrides = props.styles, onChange = props.onChange, onPaginate = props.onPaginate;
1271
1455
  var _m = useExcel(), generate = _m.generate, write = _m.write;
1272
1456
  var handleGenerateStyle = function () {
1273
- var result = deepCopyObject(styles$g.base);
1274
- var keys = calculateNestedKeys(styles$g.base);
1457
+ var result = deepCopyObject(styles$f.base);
1458
+ var keys = calculateNestedKeys(styles$f.base);
1275
1459
  keys.forEach(function (key) {
1276
- lodash.set(result, key, toClassName(lodash.get(styles$g.base, key), type && lodash.get(styles$g[type], key), hasStickyHeader && lodash.get(styles$g.sticky, key), hasVerticalSeparators && lodash.get(styles$g.separated, key), areControlsVisible && lodash.get(styles$g.controlled, key), lodash.get(stylesOverrides, key)));
1460
+ lodash.set(result, key, toClassName(lodash.get(styles$f.base, key), type && lodash.get(styles$f[type], key), hasStickyHeader && lodash.get(styles$f.sticky, key), hasVerticalSeparators && lodash.get(styles$f.separated, key), areControlsVisible && lodash.get(styles$f.controlled, key), lodash.get(stylesOverrides, key)));
1277
1461
  });
1278
1462
  return result;
1279
1463
  };
@@ -1398,7 +1582,7 @@ var TableList = function (props) {
1398
1582
  : { container: 'mt-4' }, onChange: onPaginate, children: children })] }) }));
1399
1583
  };
1400
1584
 
1401
- var base$d = {
1585
+ var base$c = {
1402
1586
  container: 'px-4 sm:px-6 lg:px-8',
1403
1587
  head: {
1404
1588
  container: 'sm:flex sm:items-center',
@@ -1452,7 +1636,7 @@ var base$d = {
1452
1636
  },
1453
1637
  },
1454
1638
  };
1455
- var normal$5 = {
1639
+ var normal$4 = {
1456
1640
  body: {
1457
1641
  content: 'inline-block min-w-full py-2 align-middle sm:px-6 lg:px-8',
1458
1642
  styleWrapper: 'relative',
@@ -1510,9 +1694,9 @@ var controlled = {
1510
1694
  container: '!flex',
1511
1695
  },
1512
1696
  };
1513
- var styles$g = {
1514
- base: base$d,
1515
- normal: normal$5,
1697
+ var styles$f = {
1698
+ base: base$c,
1699
+ normal: normal$4,
1516
1700
  panel: panel$1,
1517
1701
  full: full,
1518
1702
  sticky: sticky,
@@ -1564,10 +1748,10 @@ var TableList2 = function (props) {
1564
1748
  var _h = React.useState({}), columnVisibility = _h[0], setColumnVisibility = _h[1];
1565
1749
  var _j = React.useState([]), columnOrder = _j[0], setColumnOrder = _j[1];
1566
1750
  var handleGenerateStyle = function () {
1567
- var result = deepCopyObject(styles$f.base);
1568
- var keys = calculateNestedKeys(styles$f.base);
1751
+ var result = deepCopyObject(styles$e.base);
1752
+ var keys = calculateNestedKeys(styles$e.base);
1569
1753
  keys.forEach(function (key) {
1570
- lodash.set(result, key, toClassName(lodash.get(styles$f.base, key),
1754
+ lodash.set(result, key, toClassName(lodash.get(styles$e.base, key),
1571
1755
  // type && get(defaultStyles[type], key),
1572
1756
  // hasStickyHeader && get(defaultStyles.sticky, key),
1573
1757
  // hasVerticalSeparators && get(defaultStyles.separated, key),
@@ -1691,7 +1875,7 @@ var TableList2 = function (props) {
1691
1875
  }) }))] }), lodash.isEmpty(table === null || table === void 0 ? void 0 : table.getRowModel().rows) && !isLoading && (jsxRuntime.jsx(jsxRuntime.Fragment, { children: ((_e = config === null || config === void 0 ? void 0 : config.options) === null || _e === void 0 ? void 0 : _e.emptyComponent) ? ((_f = config === null || config === void 0 ? void 0 : config.options) === null || _f === void 0 ? void 0 : _f.emptyComponent) : (jsxRuntime.jsx("div", { className: "w-full flex justify-center my-2", children: "There is no data to show..." })) })), isLoading && (jsxRuntime.jsx("div", { className: "flex flex-col gap-y-2 w-full pt-5", children: new Array(8).fill(undefined).map(function (index) { return (jsxRuntime.jsxs("div", { className: "flex gap-2", children: [jsxRuntime.jsx("div", { className: "w-20 h-12 rounded-md bg-gray-100 animate-pulse" }), jsxRuntime.jsx("div", { className: "w-full h-12 rounded-md bg-gray-100 animate-pulse" })] }, index)); }) }))] }) }) }) }), jsxRuntime.jsx("div", { className: styles.foot, children: foot && foot(state) })] }));
1692
1876
  };
1693
1877
 
1694
- var base$c = {
1878
+ var base$b = {
1695
1879
  container: '',
1696
1880
  head: '',
1697
1881
  body: {
@@ -1730,8 +1914,8 @@ var base$c = {
1730
1914
  },
1731
1915
  foot: '',
1732
1916
  };
1733
- var styles$f = {
1734
- base: base$c,
1917
+ var styles$e = {
1918
+ base: base$b,
1735
1919
  };
1736
1920
 
1737
1921
  var createColumnHelper = function () {
@@ -1741,10 +1925,10 @@ var createColumnHelper = function () {
1741
1925
  var BreadcrumbsNavigation = function (props) {
1742
1926
  var _a = props.href, href = _a === void 0 ? '/' : _a, pages = props.pages, _b = props.type, type = _b === void 0 ? 'slashes' : _b, customSeparator = props.separator, stylesOverrides = props.styles;
1743
1927
  var handleGenerateStyle = function () {
1744
- var result = deepCopyObject(styles$e.base);
1745
- var keys = calculateNestedKeys(styles$e.base);
1928
+ var result = deepCopyObject(styles$d.base);
1929
+ var keys = calculateNestedKeys(styles$d.base);
1746
1930
  keys.forEach(function (key) {
1747
- set(result, key, toClassName(get(styles$e.base, key), type && get(styles$e[type], key), get(stylesOverrides, key)));
1931
+ set(result, key, toClassName(get(styles$d.base, key), type && get(styles$d[type], key), get(stylesOverrides, key)));
1748
1932
  });
1749
1933
  return result;
1750
1934
  };
@@ -1780,7 +1964,7 @@ var BreadcrumbsNavigation = function (props) {
1780
1964
  return (jsxRuntime.jsx("nav", { className: styles.container, "aria-label": "Breadcrumb", children: jsxRuntime.jsxs("ol", { className: styles.list, children: [jsxRuntime.jsx(HomeLink, {}), pages === null || pages === void 0 ? void 0 : pages.map(function (page) { return jsxRuntime.jsx(PageLink, { page: page }, page.name); })] }) }));
1781
1965
  };
1782
1966
 
1783
- var base$b = {
1967
+ var base$a = {
1784
1968
  container: 'flex',
1785
1969
  list: 'flex',
1786
1970
  separator: '',
@@ -1865,8 +2049,8 @@ var bar = {
1865
2049
  link: '',
1866
2050
  },
1867
2051
  };
1868
- var styles$e = {
1869
- base: base$b,
2052
+ var styles$d = {
2053
+ base: base$a,
1870
2054
  slashes: slashes,
1871
2055
  chevrons: chevrons,
1872
2056
  panel: panel,
@@ -1877,10 +2061,10 @@ var PagePaginationNavigation = function (props) {
1877
2061
  var _a = props.min, min = _a === void 0 ? 1 : _a, _b = props.max, max = _b === void 0 ? 20 : _b, stylesOverrides = props.styles, onChange = props.onChange;
1878
2062
  var _c = React.useState(2), current = _c[0], setCurrent = _c[1];
1879
2063
  var handleGenerateStyle = function () {
1880
- var result = deepCopyObject(styles$d.base);
1881
- var keys = calculateNestedKeys(styles$d.base);
2064
+ var result = deepCopyObject(styles$c.base);
2065
+ var keys = calculateNestedKeys(styles$c.base);
1882
2066
  keys.forEach(function (key) {
1883
- lodash.set(result, key, toClassName(lodash.get(styles$d.base, key), lodash.get(stylesOverrides, key)));
2067
+ lodash.set(result, key, toClassName(lodash.get(styles$c.base, key), lodash.get(stylesOverrides, key)));
1884
2068
  });
1885
2069
  return result;
1886
2070
  };
@@ -1921,7 +2105,7 @@ var PagePaginationNavigation = function (props) {
1921
2105
  return (jsxRuntime.jsxs("nav", { className: styles.container, children: [jsxRuntime.jsx("div", { className: styles.left.container, children: jsxRuntime.jsxs("button", { className: toClassName(styles.left.button, current === min && styles.button.disabled), disabled: current === min, onClick: function () { return setCurrent(current - 1); }, children: [jsxRuntime.jsx(solid.ArrowLongLeftIcon, { className: styles.left.icon }), "Previous"] }) }), jsxRuntime.jsx("div", { className: styles.center.container, children: component }), jsxRuntime.jsx("div", { className: styles.right.container, children: jsxRuntime.jsxs("button", { className: toClassName(styles.right.button, current === max && styles.button.disabled), disabled: current === max, onClick: function () { return setCurrent(current + 1); }, children: ["Next", jsxRuntime.jsx(solid.ArrowLongRightIcon, { className: styles.right.icon })] }) })] }));
1922
2106
  };
1923
2107
 
1924
- var base$a = {
2108
+ var base$9 = {
1925
2109
  container: 'flex items-center justify-between border-t border-gray-200 px-4 sm:px-0',
1926
2110
  left: {
1927
2111
  container: '-mt-px flex w-0 flex-1',
@@ -1943,18 +2127,18 @@ var base$a = {
1943
2127
  },
1944
2128
  divider: 'inline-flex items-center border-t-2 border-transparent px-4 pt-4 text-sm font-medium text-gray-500',
1945
2129
  };
1946
- var styles$d = {
1947
- base: base$a,
2130
+ var styles$c = {
2131
+ base: base$9,
1948
2132
  };
1949
2133
 
1950
2134
  var Container$1 = function (props) {
1951
2135
  var children = props.children, stylesOverrides = props.styles;
1952
2136
  var _a = React.useState(''), active = _a[0], setActive = _a[1];
1953
2137
  var handleGenerateStyle = function () {
1954
- var result = deepCopyObject(styles$c.base);
1955
- var keys = calculateNestedKeys(styles$c.base);
2138
+ var result = deepCopyObject(styles$b.base);
2139
+ var keys = calculateNestedKeys(styles$b.base);
1956
2140
  keys.forEach(function (key) {
1957
- lodash.set(result, key, toClassName(lodash.get(styles$c.base, key), lodash.get(stylesOverrides, key)));
2141
+ lodash.set(result, key, toClassName(lodash.get(styles$b.base, key), lodash.get(stylesOverrides, key)));
1958
2142
  });
1959
2143
  return result;
1960
2144
  };
@@ -1964,10 +2148,10 @@ var Container$1 = function (props) {
1964
2148
  var List$1 = function (props) {
1965
2149
  var name = props.name, children = props.children, active = props.active, setActive = props.setActive, stylesOverrides = props.styles;
1966
2150
  var handleGenerateStyle = function () {
1967
- var result = deepCopyObject(styles$c.base);
1968
- var keys = calculateNestedKeys(styles$c.base);
2151
+ var result = deepCopyObject(styles$b.base);
2152
+ var keys = calculateNestedKeys(styles$b.base);
1969
2153
  keys.forEach(function (key) {
1970
- lodash.set(result, key, toClassName(lodash.get(styles$c.base, key), lodash.get(stylesOverrides, key)));
2154
+ lodash.set(result, key, toClassName(lodash.get(styles$b.base, key), lodash.get(stylesOverrides, key)));
1971
2155
  });
1972
2156
  return result;
1973
2157
  };
@@ -2013,10 +2197,10 @@ var List$1 = function (props) {
2013
2197
  var Item$1 = function (props) {
2014
2198
  var children = props.children, _a = props.as, LinkComponent = _a === void 0 ? 'a' : _a, _b = props.type, type = _b === void 0 ? 'underline' : _b, href = props.href, isCurrent = props.isCurrent, onClick = props.onClick, stylesOverrides = props.styles, isLoading = props.isLoading;
2015
2199
  var handleGenerateStyle = function () {
2016
- var result = deepCopyObject(styles$c.base);
2017
- var keys = calculateNestedKeys(styles$c.base);
2200
+ var result = deepCopyObject(styles$b.base);
2201
+ var keys = calculateNestedKeys(styles$b.base);
2018
2202
  keys.forEach(function (key) {
2019
- lodash.set(result, key, toClassName(lodash.get(styles$c.base, key), type && lodash.get(styles$c[type], key), lodash.get(stylesOverrides, key)));
2203
+ lodash.set(result, key, toClassName(lodash.get(styles$b.base, key), type && lodash.get(styles$b[type], key), lodash.get(stylesOverrides, key)));
2020
2204
  });
2021
2205
  return result;
2022
2206
  };
@@ -2037,7 +2221,7 @@ var TabNavigation = {
2037
2221
  View: View$1,
2038
2222
  };
2039
2223
 
2040
- var base$9 = {
2224
+ var base$8 = {
2041
2225
  container: '',
2042
2226
  list: {
2043
2227
  container: '',
@@ -2074,8 +2258,8 @@ var buttons = {
2074
2258
  inactive: 'border-transparent text-gray-500 hover:text-gray-700 hover:border-gray-300',
2075
2259
  },
2076
2260
  };
2077
- var styles$c = {
2078
- base: base$9,
2261
+ var styles$b = {
2262
+ base: base$8,
2079
2263
  underline: underline,
2080
2264
  pills: pills,
2081
2265
  buttons: buttons,
@@ -2102,11 +2286,11 @@ var List = function (props) {
2102
2286
  setActive && setActive(tab === null || tab === void 0 ? void 0 : tab.props.accessor);
2103
2287
  // eslint-disable-next-line react-hooks/exhaustive-deps
2104
2288
  }, []);
2105
- return (jsxRuntime.jsx("nav", { className: toClassName(styles$b.list, stylesOverrides === null || stylesOverrides === void 0 ? void 0 : stylesOverrides.list), children: children }));
2289
+ return (jsxRuntime.jsx("nav", { className: toClassName(styles$a.list, stylesOverrides === null || stylesOverrides === void 0 ? void 0 : stylesOverrides.list), children: children }));
2106
2290
  };
2107
2291
  var Item = function (props) {
2108
2292
  var children = props.children, href = props.href, isCurrent = props.isCurrent, _a = props.linkComponent, LinkComponent = _a === void 0 ? 'a' : _a, onClick = props.onClick;
2109
- return (jsxRuntime.jsx(LinkComponent, { href: href, className: toClassName(styles$b.item[isCurrent ? 'active' : 'notActive'], styles$b.item.base), onClick: onClick, children: children }));
2293
+ return (jsxRuntime.jsx(LinkComponent, { href: href, className: toClassName(styles$a.item[isCurrent ? 'active' : 'notActive'], styles$a.item.base), onClick: onClick, children: children }));
2110
2294
  };
2111
2295
  var View = function (props) {
2112
2296
  var children = props.children;
@@ -2119,7 +2303,7 @@ var VerticalNavigation = {
2119
2303
  View: View,
2120
2304
  };
2121
2305
 
2122
- var styles$b = {
2306
+ var styles$a = {
2123
2307
  container: '',
2124
2308
  list: 'space-y-1',
2125
2309
  item: {
@@ -2137,10 +2321,10 @@ var ModalOverlay = function (props) {
2137
2321
  handleClose: function () { return setIsOpen(false); },
2138
2322
  }); }, []);
2139
2323
  var handleGenerateStyle = function () {
2140
- var result = deepCopyObject(styles$a.base);
2141
- var keys = calculateNestedKeys(styles$a.base);
2324
+ var result = deepCopyObject(styles$9.base);
2325
+ var keys = calculateNestedKeys(styles$9.base);
2142
2326
  keys.forEach(function (key) {
2143
- lodash.set(result, key, toClassName(lodash.get(styles$a.base, key), size && lodash.get(styles$a[size], key), lodash.get(stylesOverrides, key)));
2327
+ lodash.set(result, key, toClassName(lodash.get(styles$9.base, key), size && lodash.get(styles$9[size], key), lodash.get(stylesOverrides, key)));
2144
2328
  });
2145
2329
  return result;
2146
2330
  };
@@ -2158,7 +2342,7 @@ var ModalOverlay = function (props) {
2158
2342
  return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(react.Transition.Root, { show: isOpen, as: React.Fragment, children: jsxRuntime.jsxs(react.Dialog, { as: "div", className: styles.container, onClose: setIsOpen, children: [jsxRuntime.jsx(react.Transition.Child, { as: React.Fragment, enter: styles.background.transition.enter, enterFrom: styles.background.transition.enterFrom, enterTo: styles.background.transition.enterTo, leave: styles.background.transition.leave, leaveFrom: styles.background.transition.leaveFrom, leaveTo: styles.background.transition.leaveTo, children: jsxRuntime.jsx("div", { className: styles.background.container }) }), jsxRuntime.jsx("div", { className: styles.layout.container, children: jsxRuntime.jsx("div", { className: styles.layout.content, children: jsxRuntime.jsx(react.Transition.Child, { as: React.Fragment, enter: styles.panel.transition.enter, enterFrom: styles.panel.transition.enterFrom, enterTo: styles.panel.transition.enterTo, leave: styles.panel.transition.leave, leaveFrom: styles.panel.transition.leaveFrom, leaveTo: styles.panel.transition.leaveTo, children: jsxRuntime.jsx(react.Dialog.Panel, { className: styles.panel.container, children: children(options) }) }) }) })] }) }), trigger && trigger(options)] }));
2159
2343
  };
2160
2344
 
2161
- var base$8 = {
2345
+ var base$7 = {
2162
2346
  container: 'relative z-20',
2163
2347
  background: {
2164
2348
  container: 'fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity',
@@ -2212,8 +2396,8 @@ var xl$2 = {
2212
2396
  container: 'sm:max-w-4xl',
2213
2397
  },
2214
2398
  };
2215
- var styles$a = {
2216
- base: base$8,
2399
+ var styles$9 = {
2400
+ base: base$7,
2217
2401
  xs: xs$2,
2218
2402
  sm: sm$2,
2219
2403
  md: md$2,
@@ -2224,10 +2408,10 @@ var styles$a = {
2224
2408
  var NotificationOverlayContainer = function (_a) {
2225
2409
  var children = _a.children, stylesOverrides = _a.styles;
2226
2410
  var handleGenerateStyle = function () {
2227
- var result = deepCopyObject(styles$9.base);
2228
- var keys = calculateNestedKeys(styles$9.base);
2411
+ var result = deepCopyObject(styles$8.base);
2412
+ var keys = calculateNestedKeys(styles$8.base);
2229
2413
  keys.forEach(function (key) {
2230
- lodash.set(result, key, toClassName(lodash.get(styles$9.base, key), lodash.get(stylesOverrides, key)));
2414
+ lodash.set(result, key, toClassName(lodash.get(styles$8.base, key), lodash.get(stylesOverrides, key)));
2231
2415
  });
2232
2416
  return result;
2233
2417
  };
@@ -2242,10 +2426,10 @@ var NotificationOverlayItem = function (props) {
2242
2426
  onClose: function () { return setIsOpen(false); },
2243
2427
  }); }, []);
2244
2428
  var handleGenerateStyle = function () {
2245
- var result = deepCopyObject(styles$9.base);
2246
- var keys = calculateNestedKeys(styles$9.base);
2429
+ var result = deepCopyObject(styles$8.base);
2430
+ var keys = calculateNestedKeys(styles$8.base);
2247
2431
  keys.forEach(function (key) {
2248
- lodash.set(result, key, toClassName(lodash.get(styles$9.base, key), size && lodash.get(styles$9[size], key), lodash.get(stylesOverrides, key)));
2432
+ lodash.set(result, key, toClassName(lodash.get(styles$8.base, key), size && lodash.get(styles$8[size], key), lodash.get(stylesOverrides, key)));
2249
2433
  });
2250
2434
  return result;
2251
2435
  };
@@ -2257,7 +2441,7 @@ var NotificationOverlay = {
2257
2441
  Item: NotificationOverlayItem,
2258
2442
  };
2259
2443
 
2260
- var base$7 = {
2444
+ var base$6 = {
2261
2445
  container: {
2262
2446
  outer: 'pointer-events-none fixed inset-0 flex items-end px-4 py-6 sm:items-start sm:p-6 z-30',
2263
2447
  inner: 'flex w-full flex-col items-center space-y-4 sm:items-end',
@@ -2317,8 +2501,8 @@ var xl$1 = {
2317
2501
  },
2318
2502
  },
2319
2503
  };
2320
- var styles$9 = {
2321
- base: base$7,
2504
+ var styles$8 = {
2505
+ base: base$6,
2322
2506
  xs: xs$1,
2323
2507
  sm: sm$1,
2324
2508
  md: md$1,
@@ -2334,10 +2518,10 @@ var SlideOverOverlay = function (props) {
2334
2518
  handleClose: function () { return setIsOpen(false); },
2335
2519
  }); }, []);
2336
2520
  var handleGenerateStyle = function () {
2337
- var result = deepCopyObject(styles$8.base);
2338
- var keys = calculateNestedKeys(styles$8.base);
2521
+ var result = deepCopyObject(styles$7.base);
2522
+ var keys = calculateNestedKeys(styles$7.base);
2339
2523
  keys.forEach(function (key) {
2340
- lodash.set(result, key, toClassName(lodash.get(styles$8.base, key), size && lodash.get(styles$8[size], key), lodash.get(stylesOverrides, key)));
2524
+ lodash.set(result, key, toClassName(lodash.get(styles$7.base, key), size && lodash.get(styles$7[size], key), lodash.get(stylesOverrides, key)));
2341
2525
  });
2342
2526
  return result;
2343
2527
  };
@@ -2345,7 +2529,7 @@ var SlideOverOverlay = function (props) {
2345
2529
  return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(react.Transition.Root, { show: isOpen, as: React.Fragment, children: jsxRuntime.jsxs(react.Dialog, { as: "div", className: styles.container, onClose: setIsOpen, children: [jsxRuntime.jsx(react.Transition.Child, { as: React.Fragment, enter: styles.background.transition.enter, enterFrom: styles.background.transition.enterFrom, enterTo: styles.background.transition.enterTo, leave: styles.background.transition.leave, leaveFrom: styles.background.transition.leaveFrom, leaveTo: styles.background.transition.leaveTo, children: jsxRuntime.jsx("div", { className: styles.background.container }) }), jsxRuntime.jsx("div", { className: styles.layout.container, children: jsxRuntime.jsx("div", { className: styles.layout.content, children: jsxRuntime.jsx("div", { className: styles.layout.inner, children: jsxRuntime.jsx(react.Transition.Child, { as: React.Fragment, enter: styles.panel.transition.enter, enterFrom: styles.panel.transition.enterFrom, enterTo: styles.panel.transition.enterTo, leave: styles.panel.transition.leave, leaveFrom: styles.panel.transition.leaveFrom, leaveTo: styles.panel.transition.leaveTo, children: jsxRuntime.jsx(react.Dialog.Panel, { className: styles.panel.container, children: children(options) }) }) }) }) })] }) }), trigger && trigger(options)] }));
2346
2530
  };
2347
2531
 
2348
- var base$6 = {
2532
+ var base$5 = {
2349
2533
  container: 'relative z-20',
2350
2534
  background: {
2351
2535
  container: 'fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity',
@@ -2400,8 +2584,8 @@ var xl = {
2400
2584
  container: 'sm:max-w-4xl',
2401
2585
  },
2402
2586
  };
2403
- var styles$8 = {
2404
- base: base$6,
2587
+ var styles$7 = {
2588
+ base: base$5,
2405
2589
  xs: xs,
2406
2590
  sm: sm,
2407
2591
  md: md,
@@ -2422,19 +2606,19 @@ var TableColumnOptionsCustom = function (props) {
2422
2606
  ids.splice(location, 0, column.id);
2423
2607
  setColumnOrder(ids);
2424
2608
  }, []);
2425
- return (jsxRuntime.jsxs(react.Popover, { children: [jsxRuntime.jsx(react.Popover.Button, { children: trigger }), jsxRuntime.jsx(react.Popover.Panel, { className: styles$7.controls.content, children: table
2609
+ return (jsxRuntime.jsxs(react.Popover, { children: [jsxRuntime.jsx(react.Popover.Button, { children: trigger }), jsxRuntime.jsx(react.Popover.Panel, { className: styles$6.controls.content, children: table
2426
2610
  .getAllLeafColumns()
2427
2611
  .map(function (column, index) {
2428
2612
  var isAccessorColumn = !!(column === null || column === void 0 ? void 0 : column.accessorFn);
2429
- return (jsxRuntime.jsxs("div", { className: toClassName(styles$7.controls.dropdown.container, !isAccessorColumn && 'hidden'), children: [jsxRuntime.jsx("input", { className: styles$7.controls.dropdown.input, type: "checkbox", checked: column.getIsVisible(), onChange: column.getToggleVisibilityHandler() }), jsxRuntime.jsx("label", { className: styles$7.controls.dropdown.label, children: column.columnDef.header }), jsxRuntime.jsxs("div", { className: styles$7.controls.dropdown.actions, children: [jsxRuntime.jsx(outline$2.ChevronDownIcon, { className: styles$7.controls.dropdown.upIcon, onClick: function () {
2613
+ return (jsxRuntime.jsxs("div", { className: toClassName(styles$6.controls.dropdown.container, !isAccessorColumn && 'hidden'), children: [jsxRuntime.jsx("input", { className: styles$6.controls.dropdown.input, type: "checkbox", checked: column.getIsVisible(), onChange: column.getToggleVisibilityHandler() }), jsxRuntime.jsx("label", { className: styles$6.controls.dropdown.label, children: column.columnDef.header }), jsxRuntime.jsxs("div", { className: styles$6.controls.dropdown.actions, children: [jsxRuntime.jsx(outline$2.ChevronDownIcon, { className: styles$6.controls.dropdown.upIcon, onClick: function () {
2430
2614
  return handleUpdateColumnOrder(table, column, index - 1, setColumnOrder);
2431
- } }), jsxRuntime.jsx(outline$2.ChevronDownIcon, { className: styles$7.controls.dropdown.downIcon, onClick: function () {
2615
+ } }), jsxRuntime.jsx(outline$2.ChevronDownIcon, { className: styles$6.controls.dropdown.downIcon, onClick: function () {
2432
2616
  return handleUpdateColumnOrder(table, column, index + 1, setColumnOrder);
2433
2617
  } })] })] }, column.id));
2434
2618
  }) })] }));
2435
2619
  };
2436
2620
 
2437
- var styles$7 = {
2621
+ var styles$6 = {
2438
2622
  container: '',
2439
2623
  controls: {
2440
2624
  container: 'flex-row justify-between z-10 relative mb-4 gap-2 hidden',
@@ -2464,168 +2648,6 @@ var TableExcelExportCustom = function (props) {
2464
2648
  return jsxRuntime.jsx("div", { children: children({ handleExport: handleExport }) });
2465
2649
  };
2466
2650
 
2467
- var SelectMenuForm = function (props) {
2468
- var _a;
2469
- var _b = props.name, name = _b === void 0 ? 'select-menu-form' : _b, label = props.label, description = props.description, placeholder = props.placeholder, options = props.options, required = props.required, value = props.value, error = props.error, _c = props.isRequired, isRequired = _c === void 0 ? false : _c, isLoading = props.isLoading, _d = props.isTouched, isTouched = _d === void 0 ? false : _d, isDisabled = props.isDisabled, _e = props.isClearable, isClearable = _e === void 0 ? true : _e, _f = props.isMultiple, isMultiple = _f === void 0 ? false : _f, _g = props.isSearchable, isSearchable = _g === void 0 ? true : _g, _h = props.isSolo, isSolo = _h === void 0 ? false : _h, onChange = props.onChange, onSearchInputChange = props.onSearchInputChange, onClear = props.onClear, onBlur = props.onBlur, stylesOverrides = props.styles;
2470
- var _j = React.useState(true), isFocus = _j[0], setIsFocus = _j[1];
2471
- var _k = React.useState(value !== null && value !== void 0 ? value : null), state = _k[0], setState = _k[1];
2472
- var isValid = error === undefined;
2473
- var handleGenerateStyle = function () {
2474
- var result = deepCopyObject(styles$6.base);
2475
- var keys = calculateNestedKeys(styles$6.base);
2476
- keys.forEach(function (key) {
2477
- lodash.set(result, key, toClassName(lodash.get(styles$6.base, key), lodash.get(styles$6['normal'], key), isTouched === true && !isValid && lodash.get(styles$6.invalid, key), isDisabled && lodash.get(styles$6.disabled, key), lodash.get(stylesOverrides, key)));
2478
- });
2479
- return result;
2480
- };
2481
- var handleChange = function (selectValue) {
2482
- setState(selectValue);
2483
- onChange && onChange(selectValue);
2484
- setIsFocus(false);
2485
- };
2486
- var styles = handleGenerateStyle();
2487
- // Simulate onClear event.
2488
- React.useEffect(function () {
2489
- if (state === null && !isFocus) {
2490
- onClear && onClear(name);
2491
- }
2492
- // eslint-disable-next-line react-hooks/exhaustive-deps
2493
- }, [state]);
2494
- // Simulate onBlur event.
2495
- React.useEffect(function () {
2496
- if (!isFocus) {
2497
- onBlur && onBlur();
2498
- }
2499
- // eslint-disable-next-line react-hooks/exhaustive-deps
2500
- }, [isFocus]);
2501
- // listen to value changes.
2502
- React.useEffect(function () {
2503
- setState(value);
2504
- }, [value]);
2505
- return (jsxRuntime.jsxs("div", { className: styles.container, children: [jsxRuntime.jsxs("div", { className: styles.head, children: [label && (jsxRuntime.jsx("label", { htmlFor: name, className: styles.label, children: label })), !required && !isRequired && typeof label === 'string' && (jsxRuntime.jsx("span", { className: styles.hint, children: "Optional" })), required && required({ isRequired: isRequired })] }), jsxRuntime.jsxs("div", { className: styles.container, children: [jsxRuntime.jsx(Select, { primaryColor: "primary",
2506
- //
2507
- placeholder: placeholder === null || placeholder === void 0 ? void 0 : placeholder.select, noOptionsMessage: (jsxRuntime.jsx("p", { className: styles.emptyState, children: (_a = placeholder === null || placeholder === void 0 ? void 0 : placeholder.emptyState) !== null && _a !== void 0 ? _a : 'No results found' })), searchInputPlaceholder: placeholder === null || placeholder === void 0 ? void 0 : placeholder.searchInput,
2508
- //
2509
- loading: isLoading, isDisabled: isDisabled, isClearable: isClearable, isMultiple: isMultiple, isSearchable: isSearchable,
2510
- //
2511
- options: options,
2512
- //
2513
- value: state, onChange: handleChange, onSearchInputChange: onSearchInputChange,
2514
- //
2515
- classNames: {
2516
- menuButton: function () {
2517
- return toClassName(styles.input, state === null && '[&>*]:!text-gray-300 ', state === null &&
2518
- !isValid &&
2519
- isTouched &&
2520
- '[&>*]:!text-red-300');
2521
- },
2522
- menu: styles.menu,
2523
- tagItem: function () { return styles.tagItem; },
2524
- tagItemText: styles.tagItemText,
2525
- tagItemIconContainer: styles.tagItemIconContainer,
2526
- tagItemIcon: styles.tagItemIcon,
2527
- list: styles.list,
2528
- listItem: function () { return styles.listItem; },
2529
- listDisabledItem: styles.listDisabledItem,
2530
- listGroupLabel: styles.listGroupLabel,
2531
- searchContainer: styles.searchContainer,
2532
- searchBox: styles.searchBox,
2533
- searchIcon: styles.searchIcon,
2534
- closeIcon: styles.closeIcon,
2535
- } }), !isSolo && (jsxRuntime.jsxs("div", { className: styles.foot, children: [description && !(error && isTouched) && (jsxRuntime.jsx("p", { className: styles.description, children: description })), error && isTouched && (jsxRuntime.jsx("p", { className: styles.error, children: JSON.stringify(error).replaceAll('"', '') }))] }))] })] }));
2536
- };
2537
-
2538
- var base$5 = {
2539
- container: '',
2540
- head: 'flex justify-between',
2541
- body: 'relative rounded-md',
2542
- foot: '',
2543
- label: 'block font-medium text-gray-900',
2544
- hint: 'text-xs text-gray-500',
2545
- leading: 'pointer-events-none absolute inset-y-0 left-0 flex items-center',
2546
- input: 'block w-full flex border',
2547
- menuButton: '',
2548
- menu: 'z-10 !px-0 !py-0 !w-full rounded-md overflow-hidden border !mt-1 absolute bg-white',
2549
- tagItem: 'bg-gray-200 px-2 py-1 flex flex-row gap-x-1 items-center justify-between rounded-sm',
2550
- tagItemText: 'text-xs',
2551
- tagItemIconContainer: '!p-0 rounded-full hover:bg-gray-400 text-sm hover:text-white aspect-square w-4 flex items-center justify-center cursor-pointer',
2552
- tagItemIcon: '',
2553
- list: '!px-0 !w-full [&>*]:px-0 max-h-56 overflow-scroll !py-1',
2554
- listGroupLabel: '',
2555
- listItem: '!w-full !list-none hover:bg-primary-500 hover:text-white !py-2 !px-2',
2556
- listDisabledItem: '',
2557
- searchContainer: '!w-full !px-2 !py-2 border-b',
2558
- searchBox: '',
2559
- searchIcon: '',
2560
- closeIcon: '',
2561
- emptyState: 'w-full inline-flex items-start justify-start px-4',
2562
- trailing: 'pointer-events-none absolute inset-y-0 right-0 flex items-center',
2563
- description: 'text-gray-400 text-xs mt-1',
2564
- error: 'text-red-500 text-xs ml-5 mt-1',
2565
- };
2566
- var leading$4 = {
2567
- input: 'pl-10',
2568
- };
2569
- var trailing$4 = {};
2570
- var normal$4 = {
2571
- label: 'leading-6 text-sm mb-2',
2572
- hint: 'leading-6',
2573
- leading: 'pl-3',
2574
- input: 'rounded-md border-gray-200 shadow-sm focus:border-primary-500 focus:ring-primary-500 sm:text-sm placeholder-gray-300',
2575
- trailing: '',
2576
- description: 'mt-2 text-sm',
2577
- };
2578
- var inset$4 = {
2579
- container: 'rounded-md px-3 pt-2.5 pb-1.5 shadow-sm ring-1 ring-inset ring-gray-300 focus-within:ring-2 focus-within:ring-primary-600',
2580
- label: 'text-xs',
2581
- hint: 'text-xs',
2582
- input: 'border-0 !ring-0 p-0 text-gray-900 placeholder:text-gray-400 focus:ring-0 sm:text-sm pl-0',
2583
- description: 'hidden',
2584
- };
2585
- var overlapping$4 = {
2586
- container: 'relative',
2587
- head: ' absolute flex justify-between items-center left-0 -top-2 right-0 mx-2 z-10 w-full',
2588
- label: 'inline-block bg-white px-1 text-xs font-medium text-gray-900 ',
2589
- hint: 'text-xs mr-4 bg-white px-1',
2590
- input: 'block w-full rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-primary-600 sm:text-sm sm:leading-6',
2591
- description: 'hidden',
2592
- };
2593
- var pill$4 = {
2594
- head: 'mx-px block px-4 text-sm font-medium leading-6 text-gray-900 mb-1 pr-6',
2595
- foot: 'mx-px block px-4 text-sm font-medium leading-6 text-gray-900 mt-1 pr-6',
2596
- input: 'block w-full rounded-full border-0 px-4 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-primary-600 sm:text-sm sm:leading-6',
2597
- trailing: 'pr-2',
2598
- description: 'text-xs',
2599
- };
2600
- var floored$4 = {
2601
- body: 'relative mt-2',
2602
- label: 'block text-sm font-medium leading-6 text-gray-900',
2603
- input: 'peer block w-full border-0 bg-gray-50 py-1.5 text-gray-900 focus:ring-0 sm:text-sm sm:leading-6 ring-0',
2604
- description: 'text-xs mt-2',
2605
- };
2606
- var invalid$4 = {
2607
- container: 'ring-red-500',
2608
- input:
2609
- // 'block w-full border border-transparent text-red-900 ring-1 ring-inset ring-red-300 placeholder:text-red-300 focus:ring-2 focus:ring-inset focus:ring-red-500 sm:leading-6 pr-10',
2610
- 'block w-full border border-transparent text-red-900 ring-1 ring-inset ring-red-300 placeholder:text-red-300 focus:ring-2 focus:ring-inset focus:ring-red-500',
2611
- description: 'text-sm text-red-600',
2612
- };
2613
- var disabled$5 = {
2614
- input: 'block w-full rounded-md border-0 text-gray-900 shadow-sm ring-1 ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-primary-600 cursor-not-allowed bg-gray-50 text-gray-500 ring-gray-200',
2615
- };
2616
- var styles$6 = {
2617
- base: base$5,
2618
- leading: leading$4,
2619
- trailing: trailing$4,
2620
- normal: normal$4,
2621
- inset: inset$4,
2622
- overlapping: overlapping$4,
2623
- pill: pill$4,
2624
- floored: floored$4,
2625
- invalid: invalid$4,
2626
- disabled: disabled$5,
2627
- };
2628
-
2629
2651
  var DateMenuForm = function (props) {
2630
2652
  var _a;
2631
2653
  var _b = props.name, name = _b === void 0 ? 'date-menu-form' : _b, _c = props.size, size = _c === void 0 ? 'compact' : _c, label = props.label, _d = props.i18n, i18n = _d === void 0 ? 'en' : _d, description = props.description, placeholder = props.placeholder, separator = props.separator, startFrom = props.startFrom, _e = props.displayFormat, displayFormat = _e === void 0 ? 'DD.MM.YYYY' : _e, _f = props.direction, direction = _f === void 0 ? 'down' : _f, minDate = props.minDate, maxDate = props.maxDate, _g = props.startWeekOn, startWeekOn = _g === void 0 ? 'mon' : _g, _h = props.icon, icon = _h === void 0 ? function (isEmpty) {