ia-table 0.14.1 → 0.14.3

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.
@@ -1,6 +1,7 @@
1
+ (function(){"use strict";try{if(typeof document<"u"){var t=document.createElement("style");t.appendChild(document.createTextNode('button.ia-table-btn{border:none;border-radius:8px;text-decoration:none;font-size:14px;font-weight:500;font-family:Manrope,sans-serif;line-height:20px}button.ia-table-btn-url{background-color:transparent;color:#4259ee}button.ia-table-btn-url svg{padding:2px}button.ia-table-btn-url.ia-table-btn-icon{width:24px;height:24px}button.ia-table-btn-primary{background-color:#4259ee;color:#fff}button.ia-table-btn-link{color:#4259ee;background-color:transparent}button.ia-table-btn-danger{color:#fff;background-color:#e15554}button.ia-table-btn-tertiary{border:1px solid #c3c8d4;color:#1f2b4d;background-color:#fff}button.ia-table-btn-tertiary svg{padding:2px!important}button.ia-table-btn-tertiary:hover{border-color:#4259ee;color:#4259ee}button.ia-table-btn-tertiary:hover svg path{fill:#4259ee}button.ia-table-btn-icon{padding:0}button.ia-table-btn.ia-table-btn-disabled{background-color:#c3c8d4;color:#fff}button.ia-table-btn.ia-table-btn-disabled svg path{fill:#b4bac7}button.ia-table-btn-text{height:32px;max-height:32px;border-radius:8px;background-color:#f5f6fa;padding:8px;display:flex;align-items:center;justify-content:center;color:#60697d}button.ia-table-btn-text.ia-table-btn-disabled{background-color:#f8f9fb}button.ia-table-btn-text.ia-table-btn-icon{color:#60697d}button.ia-table-btn-text.ia-table-btn-icon-color{background-color:#eceefd}button.ia-table-btn-text.ia-table-btn-icon-color svg path{fill:#3649c6}button.ia-table-btn svg{height:16px;width:16px;display:flex;align-items:center;justify-content:center}button.ia-table-btn:focus svg path{fill:#3649c6}button.ia-table-btn-small{height:24px;min-width:24px;padding:2px 4px}button.ia-table-btn-small .ia-table-btn-text{padding:2px 12px}button.ia-table-btn-medium{height:28px;min-width:28px;padding:4px 6px}button.ia-table-btn-medium .ia-table-btn-text{padding:4px 12px}button.ia-table-btn-large{height:32px;min-width:32px;padding:6px 8px}button.ia-table-btn.ia-table-btn-simple{width:auto;height:auto;min-width:auto;padding:0}button.ia-table-btn.ia-table-btn-simple svg{padding:0}.tooltip-container{position:relative;display:inline-block}.tooltip{position:absolute;background-color:#1976d2;color:#fff;font-family:Manrope,sans-serif;border-radius:6px;font-size:14px;z-index:9999;box-shadow:0 2px 8px #0003;white-space:normal;max-width:400px;overflow-wrap:break-word;display:flex;align-items:center;justify-content:center;text-align:center;opacity:0;pointer-events:none;transition:opacity .2s ease-in-out}.tooltip-title{font-family:Manrope;font-weight:500;font-size:14px;line-height:20px;vertical-align:middle;padding:6px 12px}.tooltip.tooltip-visible{opacity:1;pointer-events:auto}.tooltip--primary{background:var(--Colors-Primary-Surface-Darker, rgb(54, 73, 198));color:#fff}.tooltip--secondary{background:var(--Colors-Neutrals-Surface-White, rgb(255, 255, 255));color:#000;border:1px solid #ccc}.tooltip--tertiary{background:var(--Colors-Neutrals-Text-icon-Title, rgb(13, 21, 44));color:#fff}.tooltip-arrow{position:absolute;width:10px;height:10px;background-color:inherit;transform:rotate(45deg)}.tooltip--top .tooltip-arrow{bottom:-5px}.tooltip--bottom .tooltip-arrow{top:-5px}.tooltip--left .tooltip-arrow{right:-5px}.tooltip--right .tooltip-arrow{left:-5px}.tooltip-header{padding:8px 12px}.body-text span{display:block;width:100%;text-align:justify;white-space:normal;overflow-wrap:break-word;word-break:break-word;overflow:hidden;text-overflow:ellipsis}.tooltip-btns{align-self:flex-end;gap:4px;margin-left:auto}.tooltip-btn{font-size:8px;border-radius:4px;padding:6px 12px;cursor:pointer;transition:background-color .2s ease,color .2s ease;border:none}.btn-no-bg{background:transparent;color:inherit;border:none;padding:0;min-width:auto}.btn--primary{background-color:#1976d2;color:#fff}.btn--primary:hover{background-color:#1565c0}.btn--secondary{background-color:#fff;color:#333}.btn--secondary:hover{background-color:#fff}.btn--default{background:transparent;color:inherit;border:none;padding:0;min-width:auto}.tooltip-illustration{margin:0;padding:0}.tooltip-illustration img{width:100%;max-width:100%;height:120px;object-fit:cover;border-radius:4px}.tooltip-close{background:none;position:relative;border:none;font-size:16px;cursor:pointer;color:inherit;padding:0;margin-left:auto;flex-shrink:0;width:24px;height:24px;border-radius:50%;transition:background-color .2s ease}.tooltip-close:hover{background-color:#ffffff1a}.tooltip-pagination{justify-content:flex-start;gap:5px;max-width:100%;overflow:hidden}.tooltip-pagination-bar{width:20px;height:5px;border-radius:1px;background-color:#fff;flex-shrink:0}.tooltip-pagination-bar.secondary-variant{background-color:#1976d2}.ia-table-badge{display:inline-flex;border-radius:100px;font-family:Manrope,sans-serif;font-weight:500;white-space:nowrap;padding:0 8px;max-width:-webkit-fill-available}.ia-table-badge-size-small{height:20px;font-size:10px;line-height:16px}.ia-table-badge-size-default{height:24px;font-size:12px;line-height:16px}.ia-table-badge-filled.ia-table-badge-default{background-color:#5f6673;color:#fff}.ia-table-badge-filled.ia-table-badge-success{background-color:#0f8431;color:#fff}.ia-table-badge-filled.ia-table-badge-warning{background-color:#8b6f06;color:#1f2b4d}.ia-table-badge-filled.ia-table-badge-error{background-color:#d62f4c;color:#fff}.ia-table-badge-filled.ia-table-badge-info{background-color:#4159ee;color:#fff}.ia-table-badge-stroke{background-color:#fff}.ia-table-badge-stroke.ia-table-badge-default{border:1px solid #5f6673;color:#5f6673}.ia-table-badge-stroke.ia-table-badge-success{border:1px solid #0f8431;color:#0f8431}.ia-table-badge-stroke.ia-table-badge-warning{border:1px solid #8b6f06;color:#8b6f06}.ia-table-badge-stroke.ia-table-badge-error{border:1px solid #d62f4c;color:#d62f4c}.ia-table-badge-stroke.ia-table-badge-info{border:1px solid #4159ee;color:#4159ee}.ia-table-badge-subtile.ia-table-badge-default{background:#f2f3f4;color:#5f6673}.ia-table-badge-subtile.ia-table-badge-success{background:#f4fff7;color:#0f8431}.ia-table-badge-subtile.ia-table-badge-warning{background:#fdfae9;color:#8b6f06}.ia-table-badge-subtile.ia-table-badge-error{background:#fef4f5;color:#d62f4c}.ia-table-badge-subtile.ia-table-badge-info{background:#f1f3fe;color:#4159ee}.ia-table-badge-label{display:inline-block}.ia-table-modal-overlay{position:fixed;top:0;left:0;right:0;bottom:0;background-color:#00000080;z-index:1000;animation:ia-table-modal-fade-in .2s ease-out}.ia-table-modal-overlay .ia-table-modal{background-color:#fff;border-radius:8px;box-shadow:0 4px 16px #00000029;max-height:90vh;animation:ia-table-modal-slide-in .2s ease-out;position:relative;max-width:95vw;overflow:hidden}.ia-table-modal-overlay .ia-table-modal-small{width:400px}.ia-table-modal-overlay .ia-table-modal-medium{width:600px}.ia-table-modal-overlay .ia-table-modal-large{width:800px}.ia-table-modal-overlay .ia-table-modal .ia-table-modal-header{min-height:48px;padding:12px 16px;background-color:#eceefd;flex-shrink:0}.ia-table-modal-overlay .ia-table-modal .ia-table-modal-header .ia-table-modal-title{font-family:Manrope,sans-serif;font-weight:800;font-size:16px;line-height:24px;color:#0d152c;margin:0}.ia-table-modal-overlay .ia-table-modal .ia-table-modal-content{padding:16px;flex:1;overflow-y:auto;min-height:100px}.ia-table-modal-overlay .ia-table-modal .ia-table-modal-footer{border-top:1px solid #d9dde7;padding:12px 16px;height:56px;flex-shrink:0;background-color:#fff;border-radius:0 0 8px 8px}@keyframes ia-table-modal-fade-in{0%{opacity:0}to{opacity:1}}@keyframes ia-table-modal-slide-in{0%{transform:translateY(-20px);opacity:0}to{transform:translateY(0);opacity:1}}@media(max-width:768px){.ia-table-modal-overlay .ia-table-modal-small,.ia-table-modal-overlay .ia-table-modal-medium,.ia-table-modal-overlay .ia-table-modal-large{width:95vw}}.ia-table-inputbox-container{width:100%;font-family:Manrope,sans-serif;height:32px;margin:0;padding:0}.ia-table-inputbox-container .ia-table-input-label{font-size:12px;font-weight:500;color:#60697d;line-height:16px;margin-bottom:6px}.ia-table-inputbox-container .ia-table-input-container{width:100%;height:inherit;border:1px solid #d9dde7;border-radius:8px;background-color:#fff;padding:0 12px;transition:all .2s ease-in-out;margin:0}.ia-table-inputbox-container .ia-table-input-container:hover:not(.ia-table-input-disabled,.ia-table-cellrender-input){border-color:#4259ee}.ia-table-inputbox-container .ia-table-input-container:focus-within:not(.ia-table-input-disabled,.ia-table-cellrender-input){border-color:#4259ee}.ia-table-inputbox-container .ia-table-input-container.ia-table-input-error{border-color:#ff3b30}.ia-table-inputbox-container .ia-table-input-container.ia-table-input-disabled{background-color:#f7f7f7;border-color:#e2e8f0;cursor:not-allowed}.ia-table-inputbox-container .ia-table-input-container.ia-table-cellrender-input{border:none}.ia-table-inputbox-container .ia-table-input-container.has-left-icon{padding-left:8px}.ia-table-inputbox-container .ia-table-input-container.has-right-icon{padding-right:8px}.ia-table-inputbox-container .ia-table-input-container.has-left-icon-button{padding-left:8px}.ia-table-inputbox-container .ia-table-input-container.has-right-icon-button{padding-right:8px}.ia-table-inputbox-container .ia-table-input-container .left-input-icon,.ia-table-inputbox-container .ia-table-input-container .right-input-icon,.ia-table-inputbox-container .ia-table-input-container .left-input-icon-button,.ia-table-inputbox-container .ia-table-input-container .right-input-icon-button{height:24px;color:#60697d}.ia-table-inputbox-container .ia-table-input-container .left-input-icon svg,.ia-table-inputbox-container .ia-table-input-container .right-input-icon svg,.ia-table-inputbox-container .ia-table-input-container .left-input-icon-button svg,.ia-table-inputbox-container .ia-table-input-container .right-input-icon-button svg{width:16px;height:16px}.ia-table-inputbox-container .ia-table-input-container .left-input-icon.hidden,.ia-table-inputbox-container .ia-table-input-container .right-input-icon.hidden,.ia-table-inputbox-container .ia-table-input-container .left-input-icon-button.hidden,.ia-table-inputbox-container .ia-table-input-container .right-input-icon-button.hidden{opacity:0;visibility:hidden;transition:opacity .2s ease-in-out,visibility .2s ease-in-out}.ia-table-inputbox-container .ia-table-input-container .left-input-icon.hidden.ia-table-body-cell-lock,.ia-table-inputbox-container .ia-table-input-container .right-input-icon.hidden.ia-table-body-cell-lock,.ia-table-inputbox-container .ia-table-input-container .left-input-icon-button.hidden.ia-table-body-cell-lock,.ia-table-inputbox-container .ia-table-input-container .right-input-icon-button.hidden.ia-table-body-cell-lock{opacity:1;visibility:visible}.ia-table-inputbox-container .ia-table-input-container .left-input-icon.hidden.ia-table-body-cell-lock svg path,.ia-table-inputbox-container .ia-table-input-container .right-input-icon.hidden.ia-table-body-cell-lock svg path,.ia-table-inputbox-container .ia-table-input-container .left-input-icon-button.hidden.ia-table-body-cell-lock svg path,.ia-table-inputbox-container .ia-table-input-container .right-input-icon-button.hidden.ia-table-body-cell-lock svg path{fill:#b4bac7}.ia-table-inputbox-container .ia-table-input-container .left-input-icon.visible,.ia-table-inputbox-container .ia-table-input-container .right-input-icon.visible,.ia-table-inputbox-container .ia-table-input-container .left-input-icon-button.visible,.ia-table-inputbox-container .ia-table-input-container .right-input-icon-button.visible{opacity:1;visibility:visible;transition:opacity .2s ease-in-out,visibility .2s ease-in-out}.ia-table-inputbox-container .ia-table-input-container .ia-table-input-wrapper{flex:1;height:100%;margin:0;padding:0}.ia-table-inputbox-container .ia-table-input-container .ia-table-input-wrapper .ia-table-input{width:100%;height:100%;border:none;outline:none;background:transparent;font-size:14px;font-weight:400;color:#1f2b4d;padding:0 4px;margin:0}.ia-table-inputbox-container .ia-table-input-container .ia-table-input-wrapper .ia-table-input::placeholder{color:#a0a8b1}.ia-table-inputbox-container .ia-table-input-container .ia-table-input-wrapper .ia-table-input:disabled{cursor:not-allowed;color:#a0a8b1}.ia-table-inputbox-container .ia-table-input-container .ia-table-input-wrapper .ia-table-input::-webkit-inner-spin-button,.ia-table-inputbox-container .ia-table-input-container .ia-table-input-wrapper .ia-table-input::-webkit-outer-spin-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;margin:0}.ia-table-inputbox-container .ia-table-input-container .ia-table-input-wrapper .ia-table-input[type=number]{-moz-appearance:textfield;-webkit-appearance:textfield;appearance:textfield}.ia-table-inputbox-container .ia-table-input-error-message{font-size:12px;font-weight:400;color:#ff3b30;margin-top:4px}.ia-table-cell-render-input-disabled{cursor:not-allowed;border:none!important;background-color:#fafafa!important}.ia-table-cell-render-input-disabled input{color:#b4bac7!important;font-weight:400!important}.ia-table-select-search{padding:9.5px 12px}.ia-table-select-search svg path{fill:#a0a8b1}.ia-table-select-search .ia-table-select-search-input{width:100%;border:none;border-radius:8px;padding:0 10px;font-size:14px;outline:none;background-color:inherit;color:#1f2b4d;line-height:16px}.ia-table-select-search .ia-table-select-search-input:focus{border-color:#4259ee}.ia-table-select-search .ia-table-select-search-input::placeholder{color:#b4bac7}.ia-table-select-dropdown{position:absolute;margin-top:6px;border-radius:12px;box-shadow:0 1px 6px #1a277c24;border:none;padding:8px 6px;background-color:#fff;font-family:Manrope,sans-serif;z-index:1050;min-height:135px;max-height:262px}.ia-table-select-reset{width:20px;height:20px;background:transparent;border:none;margin-left:8px}.ia-table-select-reset svg path{fill:#60697d}.ia-table-select-options{max-height:240px;overflow-y:auto;margin-top:2px}.ia-table-select-options::-webkit-scrollbar{width:6px}.ia-table-select-options::-webkit-scrollbar-track{background:transparent}.ia-table-select-options::-webkit-scrollbar-thumb{background-color:#c3c8d4;border-radius:3px}.ia-table-select-options .ia-table-select-option{padding:7.5px 12px;font-size:14px;color:#1f2b4d;line-height:20px;font-weight:500;transition:background-color .2s ease;border-radius:8px}.ia-table-select-options .ia-table-select-option:hover{background-color:#f5f6fa}.ia-table-select-options .ia-table-select-option.ia-table-select-option-selected,.ia-table-select-options .ia-table-select-option.ia-table-select-option-highlighted{background-color:#eef0ff}.ia-table-select-options .ia-table-select-option.ia-table-option-disabled{cursor:not-allowed;-webkit-user-select:none;user-select:none;color:#b4bac7}.ia-table-select-options .ia-table-select-no-options{padding:12px;text-align:center;color:#a0a8b1;font-style:italic}.ia-table-selectbox-container{width:100%;font-family:Manrope,sans-serif;position:relative;margin:0;padding:0}.ia-table-selectbox-container .ia-table-select-label{font-size:12px;font-weight:500;color:#60697d;line-height:16px;margin-bottom:6px;display:block}.ia-table-selectbox-container .ia-table-select-container{width:100%;height:32px;border:1px solid #d9dde7;border-radius:8px;background-color:#fff;padding:0 12px;cursor:pointer;transition:all .2s ease-in-out;position:relative;margin:0}.ia-table-selectbox-container .ia-table-select-container:hover:not(.ia-table-select-disabled,.ia-table-selectrenderer){border-color:#4259ee}.ia-table-selectbox-container .ia-table-select-container.ia-table-select-disabled{background-color:#f2f4fb;border-color:#e2e8f0;cursor:not-allowed;opacity:.7}.ia-table-selectbox-container .ia-table-select-container.ia-table-selectrenderer{border:none}.ia-table-selectbox-container .ia-table-select-container .ia-table-select-value{flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:14px;font-weight:400;color:#1f2b4d;line-height:19px}.ia-table-selectbox-container .ia-table-select-container .ia-table-select-value:empty:before{content:"Select an option";color:#b4bac7}.ia-table-selectbox-container .ia-table-select-container .ia-table-select-arrow{width:16px;height:16px;transition:transform .2s ease}.ia-table-selectbox-container .ia-table-select-container .ia-table-select-arrow svg{transition:transform .2s ease;fill:#404b62}.ia-table-cell-render-select-disabled .ia-table-select-disabled .ia-table-select-value{color:#b4bac7!important;font-weight:400!important}.ia-table-cell-render-select-disabled .ia-table-select-disabled{border:none!important;background-color:inherit!important;cursor:not-allowed!important}.ia-table-cell-render-select-disabled .ia-table-select-disabled svg path{fill:#d9dde7}.ia-checkbox-container{-webkit-user-select:none;user-select:none}.ia-checkbox-input,.ia-checkbox-icon{width:16px;height:16px}.ia-checkbox-input{position:absolute;opacity:0;margin:0}.ia-checkbox-custom{width:16px;height:16px;transition:all .2s ease}.ia-checkbox-label{font-family:Manrope,sans-serif;font-weight:500;font-size:14px;line-height:20px;color:#60697d}.ia-checkbox-disabled{opacity:.5;cursor:not-allowed}.ia-checkbox-disabled .ia-checkbox-input,.ia-checkbox-disabled .ia-checkbox-custom{cursor:not-allowed}.ia-checkbox-container:not(.ia-checkbox-disabled):hover .ia-checkbox-custom{opacity:.9}.ia-checkbox-input:focus-visible+.ia-checkbox-custom{outline:2px solid var(--focus-color, #4259ee);outline-offset:1px}.ia-table-radio-group-container{width:100%}.ia-table-radio-group-container.vertical{flex-direction:column}.ia-table-radio-group-container.horizontal{flex-direction:row}.ia-table-radio-option{padding:0;margin:0;-webkit-user-select:none;user-select:none;font-family:Manrope,sans-serif;font-weight:500;font-size:14px;line-height:20px;color:#60697d}.ia-table-radio-input{opacity:0;height:0;width:0}.ia-table-radio-custom{height:16px;width:16px;min-width:16px;background-color:#fff;border:1px solid #c3c8d4;border-radius:50%;transition:all .2s ease}.ia-table-radio-custom:after{content:"";position:absolute;display:none;width:8px;height:8px;border-radius:50%;background:#4259ee}.ia-table-radio-input:checked~.ia-table-radio-custom{border-color:#4259ee}.ia-table-radio-input:checked~.ia-table-radio-custom:after{display:block}.ia-table-radio-input:focus-visible~.ia-table-radio-custom{box-shadow:0 0 0 3px #4259ee33;outline:none}.ia-table-radio-input:disabled~.ia-table-radio-custom{background-color:#f4f5f7;border-color:#dfe1e6;cursor:not-allowed}.ia-table-radio-input:disabled~.ia-table-radio-custom:after{background:#a5adba}.ia-table-radio-input:disabled~.ia-table-radio-label{color:#a5adba;cursor:not-allowed}.ia-table-radio-label.ia-table-radio-label-selected{color:#1f2b4d}')),document.head.appendChild(t)}}catch(a){console.error("vite-plugin-css-injected-by-js",a)}})();
1
2
  import { jsxs as I, jsx as m } from "react/jsx-runtime";
2
3
  import * as L from "react";
3
- import { useRef as G, useEffect as F, memo as te, useCallback as U, useState as X } from "react";
4
+ import { useRef as G, useEffect as V, memo as te, useCallback as U, useState as X } from "react";
4
5
  import { createPortal as se } from "react-dom";
5
6
  const We = 200, je = 2, ve = 56, be = 48, De = {
6
7
  default: {
@@ -43,7 +44,7 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
43
44
  column: t,
44
45
  frozenColumns: n
45
46
  }) => {
46
- const s = e && t.pinned !== "right", a = e && t.pinned === "right", i = Z(t), o = s && n.positions ? n.positions[i] : null, c = s && n.indexes ? n.indexes.indexOf(i) : null, r = a && n.rightPinned && n.rightPinned.positions ? n.rightPinned.positions[i] : null;
47
+ const s = e && t.pinned !== "right", a = e && t.pinned === "right", i = F(t), o = s && n.positions ? n.positions[i] : null, c = s && n.indexes ? n.indexes.indexOf(i) : null, r = a && n.rightPinned && n.rightPinned.positions ? n.rightPinned.positions[i] : null;
47
48
  return {
48
49
  isPinnedLeft: s,
49
50
  isPinnedRight: a,
@@ -54,7 +55,7 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
54
55
  }, we = (e, t, n) => e ? t || n ? be : ve : 0, et = (e, t) => {
55
56
  let n = e;
56
57
  return t.includes(".") && !n[t] ? (t.split(".").every((a) => n[a] ? (n = n[a], !0) : !1), n) : Object.prototype.hasOwnProperty.call(n, t);
57
- }, Z = (e) => e && (e.colId || e.field || e.column_name || e.accessor || e.groupId || e.headerName) || "", Ce = (e, t = !1) => e.uniqueHierarchyId ? t && e.originalPath ? e.originalPath : e.path || [] : e.path || [], W = (e) => e.is_hidden || e.hidden || e.hide || !1, z = (e, t, n) => {
58
+ }, F = (e) => e && (e.colId || e.field || e.column_name || e.accessor || e.groupId || e.headerName) || "", Ce = (e, t = !1) => e.uniqueHierarchyId ? t && e.originalPath ? e.originalPath : e.path || [] : e.path || [], W = (e) => e.is_hidden || e.hidden || e.hide || !1, z = (e, t, n) => {
58
59
  let s = t;
59
60
  return e.length <= t && (s = e.findIndex((a) => a === n)), s >= 1 && e.length > 1 ? `${e.slice(0, s).join("/")}/${n ?? ""}` : n ?? "";
60
61
  }, re = (e, t = 0) => !e || !e.length ? t : e.every(
@@ -69,7 +70,7 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
69
70
  for (const f of e) {
70
71
  const l = f.path;
71
72
  if (!(l != null && l.length) || !l[0]) continue;
72
- Z(f) === l[0] ? r.push(`null-${l[0]}`) : c.has(l[0]) || (c.add(l[0]), r.push(l[0]));
73
+ F(f) === l[0] ? r.push(`null-${l[0]}`) : c.has(l[0]) || (c.add(l[0]), r.push(l[0]));
73
74
  }
74
75
  return r;
75
76
  }
@@ -80,7 +81,7 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
80
81
  if (!(r != null && r.length) || !r[0]) continue;
81
82
  const f = r[0];
82
83
  n[f] || (n[f] = [], a.push(f)), n[f].push(r);
83
- const l = Z(c);
84
+ const l = F(c);
84
85
  l && s.set(r, l);
85
86
  }
86
87
  for (let c = 0; c < a.length; c++) {
@@ -144,7 +145,7 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
144
145
  Array.isArray(s) && s.forEach((a) => {
145
146
  var f;
146
147
  if (typeof a != "object" || a === null) return;
147
- const i = Z(a), o = z(
148
+ const i = F(a), o = z(
148
149
  a.path || [],
149
150
  (((f = a.path) == null ? void 0 : f.length) || 1) - 1,
150
151
  i
@@ -158,7 +159,7 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
158
159
  Array.isArray(s) && s.forEach((a) => {
159
160
  if (!(typeof a != "object" || a === null))
160
161
  if (!Array.isArray(a.children) || a.children.length === 0) {
161
- const i = Z(a);
162
+ const i = F(a);
162
163
  i && (t[i.toLowerCase()] = a);
163
164
  } else
164
165
  n(a.children);
@@ -166,9 +167,9 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
166
167
  };
167
168
  return n(e), t;
168
169
  }, oe = (e, t, n = 0, s = null, a = 150, i = [], o = [], c = !1, r = null) => !e || !Array.isArray(e) ? {} : { processedColumns: e.map((l) => {
169
- var j;
170
- const p = l.autoHeight === !0 || c, d = Z(l), u = l.value ? `${d}[${l.value}]` : d, h = [...o, u], g = l.children && l.children.length > 0, w = l.children && l.children.some((B) => B.columnGroupShow !== "open") || !1, v = ((j = l.children) == null ? void 0 : j.length) && !w, C = t.isAllGroupExpanded || t[d] === !0 || i.includes(d) || v || !1, N = s ? t[s] === !0 || t.isAllGroupExpanded || i.includes(s) || v : !0, S = l.columnGroupShow === "open" && !N || !s && W(l);
171
- C && N && t[d] !== !0 && !i.includes(d) && v && i.push(d);
170
+ var k;
171
+ const p = l.autoHeight === !0 || c, d = F(l), u = l.value ? `${d}[${l.value}]` : d, h = [...o, u], g = l.children && l.children.length > 0, w = l.children && l.children.some((B) => B.columnGroupShow !== "open") || !1, v = ((k = l.children) == null ? void 0 : k.length) && !w, N = t.isAllGroupExpanded || t[d] === !0 || i.includes(d) || v || !1, $ = s ? t[s] === !0 || t.isAllGroupExpanded || i.includes(s) || v : !0, x = l.columnGroupShow === "open" && !$ || !s && W(l);
172
+ N && $ && t[d] !== !0 && !i.includes(d) && v && i.push(d);
172
173
  const _ = g ? oe(
173
174
  l.children || [],
174
175
  t,
@@ -183,13 +184,13 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
183
184
  // Pass down autoHeight to children
184
185
  r
185
186
  // Pass down column counts
186
- ) : {}, H = g ? _.processedColumns.reduce(
187
+ ) : {}, S = g ? _.processedColumns.reduce(
187
188
  (B, Y) => B + (Y.colSpan || 1),
188
189
  0
189
- ) : 1, A = s !== null, R = A ? !1 : S, V = Object.prototype.hasOwnProperty.call(
190
+ ) : 1, Z = s !== null, A = Z ? !1 : x, R = Object.prototype.hasOwnProperty.call(
190
191
  l,
191
192
  "headerName"
192
- ), $ = !g, x = {
193
+ ), j = !g, y = {
193
194
  ...l,
194
195
  level: n,
195
196
  parentField: s,
@@ -198,24 +199,24 @@ const We = 200, je = 2, ve = 56, be = 48, De = {
198
199
  path: h,
199
200
  // Track column's position in the hierarchy
200
201
  notApplyGrouping: v,
201
- headerName: l.headerName || l.label || (V ? "" : Z(l)),
202
+ headerName: l.headerName || l.label || (R ? "" : F(l)),
202
203
  hasChildren: g,
203
- isExpanded: C,
204
- hidden: R,
205
- is_hidden: S,
206
- belongsToColumnGroup: A,
204
+ isExpanded: N,
205
+ hidden: A,
206
+ is_hidden: x,
207
+ belongsToColumnGroup: Z,
207
208
  children: _.processedColumns || [],
208
- colSpan: H,
209
- field: l.field || Z(l),
209
+ colSpan: S,
210
+ field: l.field || F(l),
210
211
  is_frozen: l.is_frozen || l.pinned === "left" || l.pinned === "right",
211
212
  pinned: l.pinned ? l.pinned : l.is_frozen ? "left" : null,
212
213
  // rowSpan: 1, // Will be adjusted during header rendering
213
- isLeaf: $,
214
+ isLeaf: j,
214
215
  autoHeight: p,
215
216
  // Explicitly set autoHeight based on parent or own value
216
217
  isSearchable: l.isSearchable || l.is_searchable
217
218
  };
218
- return r && $ && !S && (x.is_frozen && x.pinned !== "right" || x.pinned === "left" ? r.left++ : x.is_frozen && x.pinned === "right" ? r.right++ : r.normal++), x;
219
+ return r && j && !x && (y.is_frozen && y.pinned !== "right" || y.pinned === "left" ? r.left++ : y.is_frozen && y.pinned === "right" ? r.right++ : r.normal++), y;
219
220
  }), initialGroupedColumns: i };
220
221
  let ae = 0;
221
222
  const Ne = (e, {
@@ -250,7 +251,7 @@ const Ne = (e, {
250
251
  (u, h) => {
251
252
  var g;
252
253
  if (u.startsWith("null")) {
253
- const w = (g = u.split("-")[1]) == null ? void 0 : g.toLowerCase(), v = f[w], C = (v == null ? void 0 : v.width) || n, N = (v == null ? void 0 : v.is_hidden) || !1;
254
+ const w = (g = u.split("-")[1]) == null ? void 0 : g.toLowerCase(), v = f[w], N = (v == null ? void 0 : v.width) || n, $ = (v == null ? void 0 : v.is_hidden) || !1;
254
255
  return {
255
256
  headerName: "",
256
257
  isPlaceholder: !0,
@@ -263,8 +264,8 @@ const Ne = (e, {
263
264
  field: `empty_${d}_${h}`,
264
265
  id: `empty_${d}_${h}`,
265
266
  accessor: `empty_${d}_${h}`,
266
- width: C,
267
- is_hidden: N,
267
+ width: N,
268
+ is_hidden: $,
268
269
  emptyCell: !0,
269
270
  is_frozen: t === "leftPinnedOnly" || t === "rightPinnedOnly",
270
271
  pinned: t === "leftPinnedOnly" ? "left" : t === "rightPinnedOnly" ? "right" : null,
@@ -288,19 +289,19 @@ const Ne = (e, {
288
289
  };
289
290
  }, ce = (e, t, n, s, a, i, o = 0, c = [], r = !1) => {
290
291
  !e || !Array.isArray(e) || e.length === 0 || e.forEach((f) => {
291
- var S, _;
292
- const l = f.field || Z(f), p = Ce(f, !0), d = f.value ? `[${f.value}]` : "", u = (p == null ? void 0 : p.length) > 1 ? `${p.slice(0, p.length - 1).join("/")}/${l}${d}` : `${l}${d}`;
292
+ var x, _;
293
+ const l = f.field || F(f), p = Ce(f, !0), d = f.value ? `[${f.value}]` : "", u = (p == null ? void 0 : p.length) > 1 ? `${p.slice(0, p.length - 1).join("/")}/${l}${d}` : `${l}${d}`;
293
294
  if (!i(f) || s.has(u))
294
295
  return;
295
296
  s.add(u);
296
- const h = f.children && f.children.some((H) => i(H)), g = h && ((_ = (S = f.children) == null ? void 0 : S.every) == null ? void 0 : _.call(
297
- S,
298
- (H) => !H.headerName && !H.columnGroupShow
297
+ const h = f.children && f.children.some((S) => i(S)), g = h && ((_ = (x = f.children) == null ? void 0 : x.every) == null ? void 0 : _.call(
298
+ x,
299
+ (S) => !S.headerName && !S.columnGroupShow
299
300
  )), w = !h || g, v = w ? a : o;
300
301
  w || ae++;
301
- const C = w ? null : ae % 2 === 0 ? "even-column-group" : "odd-column-group";
302
- f.colorClass = C || "";
303
- const N = {
302
+ const N = w ? null : ae % 2 === 0 ? "even-column-group" : "odd-column-group";
303
+ f.colorClass = N || "";
304
+ const $ = {
304
305
  ...f,
305
306
  isLastInGroup: !1,
306
307
  // Will be set later
@@ -310,9 +311,9 @@ const Ne = (e, {
310
311
  isStandalone: w || r,
311
312
  isParentWithChildEmptyHeaderName: g
312
313
  };
313
- t[v].push(N), g && f.children && (f.children.forEach((H) => {
314
- H.isLeaf = !0, H.isStandalone = !0, H.isWithEmptyHeaderName = !0;
315
- }), t[v].push(...f.children)), w && (n.push(N), g && n.push(...f.children || [])), h && !g && h && ce(
314
+ t[v].push($), g && f.children && (f.children.forEach((S) => {
315
+ S.isLeaf = !0, S.isStandalone = !0, S.isWithEmptyHeaderName = !0;
316
+ }), t[v].push(...f.children)), w && (n.push($), g && n.push(...f.children || [])), h && !g && h && ce(
316
317
  f.children || [],
317
318
  t,
318
319
  n,
@@ -620,7 +621,7 @@ const J = new Le(), dt = ({
620
621
  showPaginationAbove: f,
621
622
  pagination: l,
622
623
  justifyBodyContent: p
623
- }, F(() => () => {
624
+ }, V(() => () => {
624
625
  J.hide();
625
626
  }, []);
626
627
  const g = () => {
@@ -630,17 +631,17 @@ const J = new Le(), dt = ({
630
631
  J.show(h.current);
631
632
  return;
632
633
  }
633
- const v = a.current, C = v.querySelector("input") || // element.querySelector("div[data-tooltip-title]") ||
634
- v.querySelector(".text-overflow-ellipsis") || v.querySelector(".ia-table-header-string-title") || v.querySelector("span") || v, N = C.classList.contains("ia-table-line-clamp-2") || C.classList.contains("ia-table-line-clamp-3") || window.getComputedStyle(C).webkitLineClamp !== "none";
635
- let S = !1;
636
- if (N) {
637
- const _ = C.scrollHeight, H = C.clientHeight;
638
- S = _ > H;
634
+ const v = a.current, N = v.querySelector("input") || // element.querySelector("div[data-tooltip-title]") ||
635
+ v.querySelector(".text-overflow-ellipsis") || v.querySelector(".ia-table-header-string-title") || v.querySelector("span") || v, $ = N.classList.contains("ia-table-line-clamp-2") || N.classList.contains("ia-table-line-clamp-3") || window.getComputedStyle(N).webkitLineClamp !== "none";
636
+ let x = !1;
637
+ if ($) {
638
+ const _ = N.scrollHeight, S = N.clientHeight;
639
+ x = _ > S;
639
640
  } else {
640
- const _ = C.scrollWidth, H = C.clientWidth;
641
- S = _ > H;
641
+ const _ = N.scrollWidth, S = N.clientWidth;
642
+ x = _ > S;
642
643
  }
643
- S && J.show(h.current);
644
+ x && J.show(h.current);
644
645
  }, w = () => {
645
646
  J.hide();
646
647
  };
@@ -688,35 +689,35 @@ const J = new Le(), dt = ({
688
689
  showPrimaryButton: w = !0,
689
690
  showSecondaryButton: v = !0
690
691
  }) => {
691
- const C = G(null);
692
- F(() => {
693
- const R = (V) => {
694
- V.key === "Escape" && e && t();
692
+ const N = G(null);
693
+ V(() => {
694
+ const A = (R) => {
695
+ R.key === "Escape" && e && t();
695
696
  };
696
- return e && (document.addEventListener("keydown", R), document.body.style.overflow = "hidden"), () => {
697
- document.removeEventListener("keydown", R), document.body.style.overflow = "";
697
+ return e && (document.addEventListener("keydown", A), document.body.style.overflow = "hidden"), () => {
698
+ document.removeEventListener("keydown", A), document.body.style.overflow = "";
698
699
  };
699
700
  }, [e, t]);
700
- const N = U(
701
- (R) => {
702
- d && C.current && !C.current.contains(R.target) && t();
701
+ const $ = U(
702
+ (A) => {
703
+ d && N.current && !N.current.contains(A.target) && t();
703
704
  },
704
705
  [d, t]
705
706
  );
706
707
  if (!e) return null;
707
- const S = `ia-table-modal-${a}`, _ = {};
708
+ const x = `ia-table-modal-${a}`, _ = {};
708
709
  i && (_.width = typeof i == "number" ? `${i}px` : i), o && (_.height = typeof o == "number" ? `${o}px` : o);
709
- const H = w && f || v && p, A = /* @__PURE__ */ m(
710
+ const S = w && f || v && p, Z = /* @__PURE__ */ m(
710
711
  "div",
711
712
  {
712
713
  className: "ia-table-modal-overlay d-flex align-items-center justify-content-center",
713
- onClick: N,
714
+ onClick: $,
714
715
  children: /* @__PURE__ */ I(
715
716
  "div",
716
717
  {
717
- className: `ia-table-modal d-flex flex-column ${S} ${c}`,
718
+ className: `ia-table-modal d-flex flex-column ${x} ${c}`,
718
719
  style: _,
719
- ref: C,
720
+ ref: N,
720
721
  children: [
721
722
  /* @__PURE__ */ I("div", { className: "ia-table-modal-header d-flex justify-content-between align-items-center", children: [
722
723
  /* @__PURE__ */ m("div", { className: "ia-table-modal-header-content", children: n && /* @__PURE__ */ m("h2", { className: "ia-table-modal-title", children: n }) }),
@@ -734,7 +735,7 @@ const J = new Le(), dt = ({
734
735
  )
735
736
  ] }),
736
737
  /* @__PURE__ */ m("div", { className: "ia-table-modal-content", children: s }),
737
- H && /* @__PURE__ */ I("div", { className: "ia-table-modal-footer d-flex justify-content-end align-items-center gap-12", children: [
738
+ S && /* @__PURE__ */ I("div", { className: "ia-table-modal-footer d-flex justify-content-end align-items-center gap-12", children: [
738
739
  v && p && /* @__PURE__ */ m(
739
740
  ie,
740
741
  {
@@ -758,7 +759,7 @@ const J = new Le(), dt = ({
758
759
  )
759
760
  }
760
761
  );
761
- return se(A, document.body);
762
+ return se(Z, document.body);
762
763
  }, pt = te(He), ke = ({
763
764
  placeholder: e = "",
764
765
  label: t = "",
@@ -771,48 +772,53 @@ const J = new Le(), dt = ({
771
772
  rightIcon: r = null,
772
773
  className: f = "",
773
774
  width: l = "100%",
774
- onClick: p = (C) => C.stopPropagation(),
775
+ onClick: p = ($) => $.stopPropagation(),
775
776
  isCellRenderer: d = !1,
776
777
  inputType: u = "text",
777
778
  iconButton: h = null,
778
779
  iconButtonClassName: g = "",
779
780
  height: w,
780
- ...v
781
+ autoFocus: v = !1,
782
+ ...N
781
783
  }) => {
782
- const C = G(null), N = G(null), S = U(() => {
783
- var $;
784
- ($ = C.current) == null || $.focus();
785
- }, []), _ = U(
786
- ($) => {
787
- if (u === "int" && ($.key === "." || $.keyCode === 190 || $.keyCode === 110))
788
- return $.preventDefault(), !1;
784
+ const $ = G(null), x = G(null);
785
+ V(() => {
786
+ v && $.current && $.current.focus();
787
+ }, [v]);
788
+ const _ = U(() => {
789
+ var y;
790
+ (y = $.current) == null || y.focus();
791
+ }, []), S = U(
792
+ (y) => {
793
+ if (u === "int" && (y.key === "." || y.keyCode === 190 || y.keyCode === 110))
794
+ return y.preventDefault(), !1;
789
795
  },
790
796
  [u]
791
- ), H = U(
792
- ($) => {
793
- const x = $.target.value;
797
+ ), Z = U(
798
+ (y) => {
799
+ const k = y.target.value;
794
800
  switch (u) {
795
801
  case "int":
796
- (x === "" || /^-?\d*$/.test(x)) && s($);
802
+ (k === "" || /^-?\d*$/.test(k)) && s(y);
797
803
  break;
798
804
  case "float":
799
805
  case "decimal":
800
- (x === "" || /^-?\d*\.?\d*$/.test(x)) && s($);
806
+ (k === "" || /^-?\d*\.?\d*$/.test(k)) && s(y);
801
807
  break;
802
808
  case "percentage":
803
- (x === "" || /^\d*\.?\d*%?$/.test(x)) && s($);
809
+ (k === "" || /^\d*\.?\d*%?$/.test(k)) && s(y);
804
810
  break;
805
811
  case "dollar":
806
- (x === "" || /^\$?\d*\.?\d*$/.test(x)) && s($);
812
+ (k === "" || /^\$?\d*\.?\d*$/.test(k)) && s(y);
807
813
  break;
808
814
  case "str":
809
815
  default:
810
- s($);
816
+ s(y);
811
817
  break;
812
818
  }
813
819
  },
814
820
  [s, u]
815
- ), A = u === "str" || u === "text", R = u === "str" || u === "text" ? "left" : "right", V = `ia-table-input-container d-flex align-items-center ${i ? d ? "ia-table-cell-render-input-disabled" : "ia-table-input-disabled" : ""} ${o ? "ia-table-input-error" : ""} ${c ? "has-left-icon" : ""} ${r ? "has-right-icon" : ""} ${h && !A ? "has-left-icon-button" : ""} ${h && A ? "has-right-icon-button" : ""} ${d ? "ia-table-cellrender-input" : ""} ${f}
821
+ ), A = u === "str" || u === "text", R = u === "str" || u === "text" ? "left" : "right", j = `ia-table-input-container d-flex align-items-center ${i ? d ? "ia-table-cell-render-input-disabled" : "ia-table-input-disabled" : ""} ${o ? "ia-table-input-error" : ""} ${c ? "has-left-icon" : ""} ${r ? "has-right-icon" : ""} ${h && !A ? "has-left-icon-button" : ""} ${h && A ? "has-right-icon-button" : ""} ${d ? "ia-table-cellrender-input" : ""} ${f}
816
822
  `;
817
823
  return /* @__PURE__ */ I(
818
824
  "div",
@@ -824,20 +830,20 @@ const J = new Le(), dt = ({
824
830
  /* @__PURE__ */ I(
825
831
  "div",
826
832
  {
827
- className: V,
828
- onClick: S,
833
+ className: j,
834
+ onClick: _,
829
835
  onMouseEnter: () => {
830
- N.current && N.current.classList.add("visible");
836
+ x.current && x.current.classList.add("visible");
831
837
  },
832
838
  onMouseLeave: () => {
833
- N.current && N.current.classList.remove("visible");
839
+ x.current && x.current.classList.remove("visible");
834
840
  },
835
841
  children: [
836
842
  c && /* @__PURE__ */ m("div", { className: "left-input-icon d-flex align-items-center justify-content-center", children: c }),
837
843
  h && !A && /* @__PURE__ */ m(
838
844
  "div",
839
845
  {
840
- ref: N,
846
+ ref: x,
841
847
  className: `left-input-icon-button d-flex align-items-center justify-content-center ${g}`,
842
848
  children: h
843
849
  }
@@ -845,17 +851,17 @@ const J = new Le(), dt = ({
845
851
  /* @__PURE__ */ m("div", { className: "ia-table-input-wrapper", children: /* @__PURE__ */ m(
846
852
  "input",
847
853
  {
848
- ref: C,
854
+ ref: $,
849
855
  type: a,
850
856
  value: n,
851
- onChange: H,
857
+ onChange: Z,
852
858
  onClick: p,
853
- onKeyDown: _,
859
+ onKeyDown: S,
854
860
  placeholder: e,
855
861
  disabled: i,
856
862
  className: "ia-table-input",
857
863
  style: { textAlign: R },
858
- ...v
864
+ ...N
859
865
  }
860
866
  ) }),
861
867
  r && /* @__PURE__ */ m("div", { className: "right-input-icon d-flex align-items-center justify-content-center", children: r }),
@@ -888,7 +894,7 @@ const J = new Le(), dt = ({
888
894
  }
889
895
  )
890
896
  ] }), Me = (e, t, n) => {
891
- F(() => {
897
+ V(() => {
892
898
  var a;
893
899
  const s = (a = n == null ? void 0 : n.getTableInstance) == null ? void 0 : a.call(n);
894
900
  if (e && t && (s != null && s.current)) {
@@ -929,43 +935,43 @@ const J = new Le(), dt = ({
929
935
  lazyLoadCellRenderer: w = !1,
930
936
  isEnableResetButton: v = !0
931
937
  }) => {
932
- const C = G(null), N = G(null), S = G(null), [_, H] = X(!1), [A, R] = X(""), [V, $] = X(null), [x, j] = X(-1), [B, Y] = X(c), q = p || B || c, T = i !== void 0 ? i : _, D = o || H;
938
+ const N = G(null), $ = G(null), x = G(null), [_, S] = X(!1), [Z, A] = X(""), [R, j] = X(null), [y, k] = X(-1), [B, Y] = X(c), q = p || B || c, T = i !== void 0 ? i : _, D = o || S;
933
939
  Me(T, h, g);
934
940
  const O = U(() => {
935
- if (C.current) {
936
- const E = C.current.getBoundingClientRect();
941
+ if (N.current) {
942
+ const C = N.current.getBoundingClientRect();
937
943
  return {
938
- top: E.bottom + window.scrollY,
939
- left: E.left + window.scrollX,
940
- width: E.width
944
+ top: C.bottom + window.scrollY,
945
+ left: C.left + window.scrollX,
946
+ width: C.width
941
947
  };
942
948
  }
943
949
  return null;
944
950
  }, []);
945
- F(() => {
951
+ V(() => {
946
952
  if (w) {
947
953
  if (r) {
948
- const E = O();
949
- E && $(E);
954
+ const C = O();
955
+ C && j(C);
950
956
  }
951
957
  D(w);
952
958
  }
953
- }, [w, r, O]), F(() => {
959
+ }, [w, r, O]), V(() => {
954
960
  if (T && r) {
955
- const E = O();
956
- E && $(E);
961
+ const C = O();
962
+ C && j(C);
957
963
  }
958
- }, [T, r, O]), F(() => {
959
- const E = (b) => {
960
- C.current && !C.current.contains(b.target) && N.current && !N.current.contains(b.target) && (D(!1), u && u(), h && (g != null && g.tableId) && (window.iaTablePortalOpen || (window.iaTablePortalOpen = {}), window.iaTablePortalOpen[g.tableId] = !1));
961
- }, y = () => {
964
+ }, [T, r, O]), V(() => {
965
+ const C = (b) => {
966
+ N.current && !N.current.contains(b.target) && $.current && !$.current.contains(b.target) && (D(!1), u && u(), h && (g != null && g.tableId) && (window.iaTablePortalOpen || (window.iaTablePortalOpen = {}), window.iaTablePortalOpen[g.tableId] = !1));
967
+ }, E = () => {
962
968
  if (T && r) {
963
969
  const b = O();
964
- b && $(b);
970
+ b && j(b);
965
971
  }
966
972
  };
967
- return T && (document.addEventListener("mousedown", E), r && (window.addEventListener("scroll", y, !0), window.addEventListener("resize", y))), () => {
968
- document.removeEventListener("mousedown", E), r && (window.removeEventListener("scroll", y, !0), window.removeEventListener("resize", y));
973
+ return T && (document.addEventListener("mousedown", C), r && (window.addEventListener("scroll", E, !0), window.addEventListener("resize", E))), () => {
974
+ document.removeEventListener("mousedown", C), r && (window.removeEventListener("scroll", E, !0), window.removeEventListener("resize", E));
969
975
  };
970
976
  }, [
971
977
  T,
@@ -975,149 +981,149 @@ const J = new Le(), dt = ({
975
981
  u,
976
982
  g,
977
983
  O
978
- ]), F(() => {
979
- T && S.current && (S.current.focus(), j(-1));
980
- }, [T]), F(() => {
984
+ ]), V(() => {
985
+ T && x.current && (x.current.focus(), k(-1));
986
+ }, [T]), V(() => {
981
987
  p || c && c.length > 0 && Y(c);
982
988
  }, [c, p, d]);
983
989
  const ue = U(
984
- (E) => {
985
- if (E.stopPropagation(), !a) {
990
+ (C) => {
991
+ if (C.stopPropagation(), !a) {
986
992
  if (!T && r) {
987
- const y = O();
988
- y && $(y);
993
+ const E = O();
994
+ E && j(E);
989
995
  }
990
996
  D(!T), T && u && u();
991
997
  }
992
998
  },
993
999
  [a, T, D, r, O]
994
1000
  ), ne = U(
995
- (E) => {
1001
+ (C) => {
996
1002
  if (l)
997
- if (Array.isArray(n) && n.some((b) => b.value === E.value))
1003
+ if (Array.isArray(n) && n.some((b) => b.value === C.value))
998
1004
  s(
999
1005
  n.filter(
1000
- (b) => b.value !== E.value
1006
+ (b) => b.value !== C.value
1001
1007
  )
1002
1008
  );
1003
1009
  else {
1004
1010
  const b = Array.isArray(n) ? n : [];
1005
- s([...b, E]);
1011
+ s([...b, C]);
1006
1012
  }
1007
1013
  else
1008
- s(E), D(!1), h && (g != null && g.tableId) && (window.iaTablePortalOpen || (window.iaTablePortalOpen = {}), window.iaTablePortalOpen[g.tableId] = !1);
1014
+ s(C), D(!1), h && (g != null && g.tableId) && (window.iaTablePortalOpen || (window.iaTablePortalOpen = {}), window.iaTablePortalOpen[g.tableId] = !1);
1009
1015
  },
1010
1016
  [l, n, s, D, h]
1011
1017
  ), pe = U(
1012
- (E) => {
1013
- const y = E.target.value.toLowerCase();
1014
- R(y), j(-1);
1018
+ (C) => {
1019
+ const E = C.target.value.toLowerCase();
1020
+ A(E), k(-1);
1015
1021
  const b = p || c;
1016
- if (y) {
1017
- const P = b.filter((k) => k.label && typeof k.label == "string" ? k.label.toLowerCase().includes(y) : k.value && typeof k.value == "string" ? k.value.toLowerCase().includes(y) : k.label && typeof k.label == "number" ? k.label == Number(y) : k.value && typeof k.value == "number" ? k.value == Number(y) : !1);
1022
+ if (E) {
1023
+ const P = b.filter((H) => H.label && typeof H.label == "string" ? H.label.toLowerCase().includes(E) : H.value && typeof H.value == "string" ? H.value.toLowerCase().includes(E) : H.label && typeof H.label == "number" ? H.label == Number(E) : H.value && typeof H.value == "number" ? H.value == Number(E) : !1);
1018
1024
  d ? d(P) : Y(P);
1019
1025
  } else
1020
1026
  d ? d(c) : Y(c);
1021
1027
  },
1022
1028
  [c, p, d]
1023
1029
  );
1024
- F(() => {
1030
+ V(() => {
1025
1031
  if (!T) return;
1026
- const E = (y) => {
1032
+ const C = (E) => {
1027
1033
  const b = q.filter((P) => !P.isDisabled);
1028
- switch (y.key) {
1034
+ switch (E.key) {
1029
1035
  case "ArrowDown":
1030
- y.preventDefault(), y.stopPropagation(), j((P) => {
1031
- const k = P < b.length - 1 ? P + 1 : 0;
1036
+ E.preventDefault(), E.stopPropagation(), k((P) => {
1037
+ const H = P < b.length - 1 ? P + 1 : 0;
1032
1038
  return setTimeout(() => {
1033
1039
  var K;
1034
- const M = (K = N.current) == null ? void 0 : K.querySelector(
1035
- `[data-option-index="${k}"]`
1040
+ const M = (K = $.current) == null ? void 0 : K.querySelector(
1041
+ `[data-option-index="${H}"]`
1036
1042
  );
1037
1043
  M == null || M.scrollIntoView({ block: "nearest" });
1038
- }, 0), k;
1044
+ }, 0), H;
1039
1045
  });
1040
1046
  break;
1041
1047
  case "ArrowUp":
1042
- y.preventDefault(), y.stopPropagation(), j((P) => {
1043
- const k = P > 0 ? P - 1 : b.length - 1;
1048
+ E.preventDefault(), E.stopPropagation(), k((P) => {
1049
+ const H = P > 0 ? P - 1 : b.length - 1;
1044
1050
  return setTimeout(() => {
1045
1051
  var K;
1046
- const M = (K = N.current) == null ? void 0 : K.querySelector(
1047
- `[data-option-index="${k}"]`
1052
+ const M = (K = $.current) == null ? void 0 : K.querySelector(
1053
+ `[data-option-index="${H}"]`
1048
1054
  );
1049
1055
  M == null || M.scrollIntoView({ block: "nearest" });
1050
- }, 0), k;
1056
+ }, 0), H;
1051
1057
  });
1052
1058
  break;
1053
1059
  case "Enter":
1054
- if (y.preventDefault(), y.stopPropagation(), x >= 0 && x < b.length) {
1055
- const P = b[x];
1060
+ if (E.preventDefault(), E.stopPropagation(), y >= 0 && y < b.length) {
1061
+ const P = b[y];
1056
1062
  P && !P.isDisabled && ne(P);
1057
1063
  }
1058
1064
  break;
1059
1065
  case "Escape":
1060
- y.preventDefault(), y.stopPropagation(), D(!1), h && (g != null && g.tableId) && (window.iaTablePortalOpen || (window.iaTablePortalOpen = {}), window.iaTablePortalOpen[g.tableId] = !1);
1066
+ E.preventDefault(), E.stopPropagation(), D(!1), h && (g != null && g.tableId) && (window.iaTablePortalOpen || (window.iaTablePortalOpen = {}), window.iaTablePortalOpen[g.tableId] = !1);
1061
1067
  break;
1062
1068
  }
1063
1069
  };
1064
- return document.addEventListener("keydown", E), () => {
1065
- document.removeEventListener("keydown", E);
1070
+ return document.addEventListener("keydown", C), () => {
1071
+ document.removeEventListener("keydown", C);
1066
1072
  };
1067
1073
  }, [
1068
1074
  T,
1069
1075
  q,
1070
- x,
1076
+ y,
1071
1077
  ne,
1072
1078
  D,
1073
1079
  h,
1074
1080
  g
1075
1081
  ]);
1076
1082
  const ge = `ia-table-select-container d-flex justify-content-between align-items-center ${a ? "ia-table-select-disabled" : ""} ${T ? "ia-table-select-open" : ""} ${h ? "ia-table-selectrenderer" : ""} ${f}`, me = () => {
1077
- const E = q.filter((b) => !b.isDisabled), y = /* @__PURE__ */ I(
1083
+ const C = q.filter((b) => !b.isDisabled), E = /* @__PURE__ */ I(
1078
1084
  "div",
1079
1085
  {
1080
- ref: N,
1086
+ ref: $,
1081
1087
  className: "ia-table-select-dropdown d-flex flex-column",
1082
1088
  onClick: (b) => b.stopPropagation(),
1083
1089
  style: {
1084
- ...r && V ? {
1090
+ ...r && R ? {
1085
1091
  position: "absolute",
1086
- top: `${V.top}px`,
1087
- left: `${V.left}px`,
1088
- width: `${V.width}px`
1092
+ top: `${R.top}px`,
1093
+ left: `${R.left}px`,
1094
+ width: `${R.width}px`
1089
1095
  } : { width: t }
1090
1096
  },
1091
1097
  children: [
1092
1098
  /* @__PURE__ */ m(
1093
1099
  Te,
1094
1100
  {
1095
- inputRef: S,
1101
+ inputRef: x,
1096
1102
  type: "text",
1097
- value: A,
1103
+ value: Z,
1098
1104
  onChange: pe,
1099
1105
  placeholder: "Search here..."
1100
1106
  }
1101
1107
  ),
1102
1108
  /* @__PURE__ */ m("div", { className: "ia-table-select-options d-flex flex-column gap-2", children: q && q.length > 0 ? q.map((b) => {
1103
- const P = E.findIndex(
1109
+ const P = C.findIndex(
1104
1110
  (M) => M.value === b.value
1105
- ), k = P === x;
1111
+ ), H = P === y;
1106
1112
  return /* @__PURE__ */ I(
1107
1113
  "div",
1108
1114
  {
1109
1115
  "data-option-index": P,
1110
1116
  className: `ia-table-select-option cursor-pointer d-flex align-items-center gap-6 ${l ? Array.isArray(n) && n.some(
1111
1117
  (M) => M.value === b.value
1112
- ) ? "ia-table-select-option-selected" : "" : n && !Array.isArray(n) && n.value === b.value ? "ia-table-select-option-selected" : ""} ${b.isDisabled ? "ia-table-option-disabled" : ""} ${k ? "ia-table-select-option-highlighted" : ""}`,
1118
+ ) ? "ia-table-select-option-selected" : "" : n && !Array.isArray(n) && n.value === b.value ? "ia-table-select-option-selected" : ""} ${b.isDisabled ? "ia-table-option-disabled" : ""} ${H ? "ia-table-select-option-highlighted" : ""}`,
1113
1119
  onClick: (M) => {
1114
1120
  M.stopPropagation(), b.isDisabled || ne(b);
1115
1121
  },
1116
1122
  onMouseEnter: () => {
1117
- b.isDisabled || j(P);
1123
+ b.isDisabled || k(P);
1118
1124
  },
1119
1125
  onMouseLeave: () => {
1120
- b.isDisabled || j(-1);
1126
+ b.isDisabled || k(-1);
1121
1127
  },
1122
1128
  children: [
1123
1129
  l && Array.isArray(n) && n.some(
@@ -1132,7 +1138,7 @@ const J = new Le(), dt = ({
1132
1138
  ]
1133
1139
  }
1134
1140
  );
1135
- return r ? se(y, document.body) : y;
1141
+ return r ? se(E, document.body) : E;
1136
1142
  };
1137
1143
  return /* @__PURE__ */ I(
1138
1144
  "div",
@@ -1144,7 +1150,7 @@ const J = new Le(), dt = ({
1144
1150
  /* @__PURE__ */ I(
1145
1151
  "div",
1146
1152
  {
1147
- ref: C,
1153
+ ref: N,
1148
1154
  className: ge,
1149
1155
  onClick: ue,
1150
1156
  children: [
@@ -1153,8 +1159,8 @@ const J = new Le(), dt = ({
1153
1159
  "button",
1154
1160
  {
1155
1161
  className: "ia-table-select-reset cursor-pointer flex-shrink-0 d-flex align-items-center justify-content-center",
1156
- onClick: (E) => {
1157
- E.stopPropagation(), s([]);
1162
+ onClick: (C) => {
1163
+ C.stopPropagation(), s([]);
1158
1164
  },
1159
1165
  children: /* @__PURE__ */ m(de, { className: "icon-10" })
1160
1166
  }
@@ -1294,7 +1300,7 @@ export {
1294
1300
  tt as d,
1295
1301
  we as e,
1296
1302
  ft as f,
1297
- Z as g,
1303
+ F as g,
1298
1304
  at as h,
1299
1305
  ht as i,
1300
1306
  bt as j,