react-semaphor 0.1.19 → 0.1.21

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 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/index-WGPrKoOC.js"),r=require("../types/index.cjs");exports.Dashboard=e.Dashboard;exports.EMPTY_SELECTION=r.EMPTY_SELECTION;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/index-BXyn0KuU.js"),r=require("../types/index.cjs");exports.Dashboard=e.Dashboard;exports.EMPTY_SELECTION=r.EMPTY_SELECTION;
@@ -1,4 +1,4 @@
1
- import { D as a } from "../chunks/index-BCkptgcw.js";
1
+ import { D as a } from "../chunks/index-C3YhLxkw.js";
2
2
  import { EMPTY_SELECTION as e } from "../types/index.js";
3
3
  export {
4
4
  a as Dashboard,
package/dist/index.cjs CHANGED
@@ -1,6 +1,6 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/index-WGPrKoOC.js"),v=require("./types/index.cjs"),u=require("./chunks/dashboard-plus-_lhN-s45.js"),a=require("react/jsx-runtime"),x=require("react");require("react-dom");function j(r){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const s in r)if(s!=="default"){const i=Object.getOwnPropertyDescriptor(r,s);Object.defineProperty(t,s,i.get?i:{enumerable:!0,get:()=>r[s]})}}return t.default=r,Object.freeze(t)}const p=j(x);/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/index-BXyn0KuU.js"),v=require("./types/index.cjs"),u=require("./chunks/dashboard-plus-CxeKQLr6.js"),a=require("react/jsx-runtime"),x=require("react");require("react-dom");function j(r){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const s in r)if(s!=="default"){const i=Object.getOwnPropertyDescriptor(r,s);Object.defineProperty(t,s,i.get?i:{enumerable:!0,get:()=>r[s]})}}return t.default=r,Object.freeze(t)}const p=j(x);/**
2
2
  * @license lucide-react v0.453.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
5
5
  * See the LICENSE file in the root directory of this source tree.
6
- */const N=e.createLucideIcon("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);function P(r){const{displayPreferences:t,...s}=r,i={...s,id:r.dashboardId};return a.jsx(e.ErrorBoundary,{FallbackComponent:e.Fallback,children:a.jsx(e.SemaphorContextProvider,{dashboardProps:i,children:a.jsx(e.UXProvider,{children:a.jsx(e.DisplayPreferencesProvider,{displayPreferences:t,children:a.jsx(e.Container,{type:"visual",...i,children:a.jsx(E,{cardId:r.cardId})})})})})})}function E({cardId:r}){const t=e.useDashboardStore(n=>{var l;return(l=n.dashboard)==null?void 0:l.sheets}),{card:s,frame:i}=x.useMemo(()=>{const n=t==null?void 0:t.flatMap(o=>o.frames),l=n==null?void 0:n.flatMap(o=>o==null?void 0:o.cards),f=l==null?void 0:l.find(o=>(o==null?void 0:o.id)===r),D=n==null?void 0:n.find(o=>{var h;return(h=o==null?void 0:o.cards)==null?void 0:h.find(c=>(c==null?void 0:c.id)===r)});return{card:f,frame:D}},[t,r]);return!s||!i?a.jsx(e.FallbackVisual,{error:new Error("Card not found"),resetErrorBoundary:()=>{},customerFacingMessage:`Card not found with ID: ${r}`}):a.jsx("main",{className:"flex h-full grow flex-col",children:a.jsx(e.ErrorBoundary,{FallbackComponent:({error:n,resetErrorBoundary:l})=>a.jsx(e.FallbackVisual,{error:n,resetErrorBoundary:l,customerFacingMessage:"Error creating visual. Please try again."}),children:a.jsx(e.DashboardCard,{card:s,frame:i})})})}const A=["MM-DD-YYYY","YYYY-MM-DD","MM/DD/YYYY","DD/MM/YYYY","MMMM DD, YYYY","MMM DD, YYYY","DD MMM YYYY","Week of MMM DD, YYYY","Week of MMMM DD, YYYY","YYYY-WW","MMM YYYY","MMMM YYYY","YYYY-MM","MM/YYYY","YYYY MMM","Q1 YYYY","YYYY Q1","1st Quarter YYYY","YYYY-Q1","Quarter 1, YYYY","YYYY","YY","custom"];var b=(r=>(r.SUBTOTAL="__SUBTOTAL__",r.TOTAL="__TOTAL__",r.ALL="__ALL__",r))(b||{});function _({name:r,items:t,value:s,onChange:i,isLoading:n,isError:l,refetch:f,className:D,icon:o,showNone:h=!1}){const c=p.useRef(null),[m,M]=p.useState(!1),[g,y]=p.useState("100%"),C=h?[...t||[],{id:"none",name:"None"}]:t;p.useLayoutEffect(()=>{c.current&&y(c.current.offsetWidth)},[]);function T(){var d;return n?"Loading...":l?"Error":s?(d=t==null?void 0:t.find(Y=>Y.id===s))==null?void 0:d.name:`Select ${r}`}function S(d,Y){i(Y),M(!1)}return a.jsxs(e.Popover,{open:m,onOpenChange:M,children:[a.jsx(e.PopoverTrigger,{asChild:!0,children:a.jsxs(e.Button,{ref:c,variant:"outline",role:"combobox","aria-expanded":m,className:e.cn("flex h-9 w-full justify-between",D),children:[a.jsxs("div",{className:"flex items-center gap-2",children:[o&&a.jsx("div",{className:"mr-2",children:o}),a.jsx("span",{className:"max-w-[150px] overflow-hidden truncate text-ellipsis whitespace-nowrap",children:T()})]}),a.jsx(e.ChevronDown,{className:"size-4 opacity-50"})]})}),a.jsx(e.PopoverContent,{className:"w-full p-0",style:{minWidth:g},children:a.jsxs(e.Command,{children:[a.jsxs("div",{className:"flex h-9 items-center justify-between border-b pr-1",children:[a.jsx(e.CommandInput,{className:"h-9",placeholder:"Search..."}),a.jsx(e.IconButton,{className:"h-7",onClick:f,children:a.jsx(N,{className:e.cn("size-3.5 opacity-50",n&&"animate-spin")})})]}),a.jsxs(e.CommandList,{children:[a.jsxs(e.CommandEmpty,{children:["No ",r==null?void 0:r.toLowerCase()," found."]}),a.jsx(e.CommandGroup,{children:C==null?void 0:C.map(d=>a.jsx(e.CommandItem,{className:"overflow-x-auto",value:d.name,onSelect:Y=>S(Y,d.id),children:a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(e.Check,{className:e.cn("size-4",s===d.id?"opacity-100":"opacity-0")}),a.jsx("div",{title:d.name,children:d.name})]})},d.id))})]})]})})]})}exports.Dashboard=e.Dashboard;exports.DashboardWC=e.DashboardWC;exports.ResourceType=e.ResourceType;exports.SemaphorContextProvider=e.SemaphorContextProvider;exports.SemaphorDataProvider=e.SemaphorQueryClient;exports.SemaphorQueryClient=e.SemaphorQueryClient;exports.createSqlGenConfig=e.createSqlGenConfig;exports.downloadPdf=e.downloadPdf;exports.fmt=e.fmt;exports.getColumnDataType=e.getColumnDataType;exports.getFilterValueType=e.getFilterValueType;exports.getFormattedTableNameForQuery=e.getFormattedTableNameForQuery;exports.getQualifiedTableName=e.getQualifiedTableName;exports.getSql=e.getSql;exports.invalidateToken=e.invalidateToken;exports.isBooleanDataType=e.isBooleanDataType;exports.isColumnInSqlGen=e.isColumnInSqlGen;exports.isDateDataType=e.isDateDataType;exports.isNumberDataType=e.isNumberDataType;exports.isTextDataType=e.isTextDataType;exports.resolveDataType=e.resolveDataType;exports.resolveDatamodelName=e.resolveDatamodelName;exports.useCard=e.useCard;exports.useCurrentActiveCard=e.useCurrentActiveCard;exports.useCurrentCardConfig=e.useCurrentCardConfig;exports.useCurrentSheetActiveCards=e.useCurrentSheetActiveCards;exports.useDashboardActions=e.useDashboardActions;exports.useDashboardStore=e.useDashboardStore;exports.useDataColumns=e.useDataColumns;exports.useDateFilterHook=e.useDateFilterHook;exports.useEditorActions=e.useEditorActions;exports.useEditorAside=e.useEditorAside;exports.useEditorStore=e.useEditorStore;exports.useTextFilterHook=e.useTextFilterHook;exports.EMPTY_SELECTION=v.EMPTY_SELECTION;exports.AdvancedModeToggle=u.AdvancedModeToggle;exports.ResourceManagementPanel=u.ResourceManagementPanel;exports.ScheduleDashboard=u.ScheduleDashboard;exports.ShareDialog=u.ShareDialog;exports.Surfboard=u.DashboardPlus;exports.VisualBadge=u.VisualBadge;exports.VisualEditingControls=u.VisualEditingControls;exports.cleanCard=u.cleanCard;exports.getDashbaordStateWithoutData=u.getDashbaordStateWithoutData;exports.Combobox=_;exports.DATE_FORMAT_VALUES=A;exports.PivotMarkerEnum=b;exports.Visual=P;
6
+ */const E=e.createLucideIcon("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);function N(r){const{displayPreferences:t,...s}=r,i={...s,id:r.dashboardId};return a.jsx(e.ErrorBoundary,{FallbackComponent:e.Fallback,children:a.jsx(e.SemaphorContextProvider,{dashboardProps:i,children:a.jsx(e.UXProvider,{children:a.jsx(e.DisplayPreferencesProvider,{displayPreferences:t,children:a.jsx(e.Container,{type:"visual",...i,children:a.jsx(P,{cardId:r.cardId})})})})})})}function P({cardId:r}){const t=e.useDashboardStore(n=>{var l;return(l=n.dashboard)==null?void 0:l.sheets}),{card:s,frame:i}=x.useMemo(()=>{const n=t==null?void 0:t.flatMap(o=>o.frames),l=n==null?void 0:n.flatMap(o=>o==null?void 0:o.cards),f=l==null?void 0:l.find(o=>(o==null?void 0:o.id)===r),C=n==null?void 0:n.find(o=>{var h;return(h=o==null?void 0:o.cards)==null?void 0:h.find(c=>(c==null?void 0:c.id)===r)});return{card:f,frame:C}},[t,r]);return!s||!i?a.jsx(e.FallbackVisual,{error:new Error("Card not found"),resetErrorBoundary:()=>{},customerFacingMessage:`Card not found with ID: ${r}`}):a.jsx("main",{className:"flex h-full grow flex-col",children:a.jsx(e.ErrorBoundary,{FallbackComponent:({error:n,resetErrorBoundary:l})=>a.jsx(e.FallbackVisual,{error:n,resetErrorBoundary:l,customerFacingMessage:"Error creating visual. Please try again."}),children:a.jsx(e.DashboardCard,{card:s,frame:i})})})}const A=["MM-DD-YYYY","YYYY-MM-DD","MM/DD/YYYY","DD/MM/YYYY","MMMM DD, YYYY","MMM DD, YYYY","DD MMM YYYY","Week of MMM DD, YYYY","Week of MMMM DD, YYYY","YYYY-WW","MMM YYYY","MMMM YYYY","YYYY-MM","MM/YYYY","YYYY MMM","Q1 YYYY","YYYY Q1","1st Quarter YYYY","YYYY-Q1","Quarter 1, YYYY","YYYY","YY","custom"];var b=(r=>(r.SUBTOTAL="__SUBTOTAL__",r.TOTAL="__TOTAL__",r.ALL="__ALL__",r))(b||{});function _({name:r,items:t,value:s,onChange:i,isLoading:n,isError:l,refetch:f,className:C,icon:o,showNone:h=!1}){const c=p.useRef(null),[m,M]=p.useState(!1),[g,y]=p.useState("100%"),D=h?[...t||[],{id:"none",name:"None"}]:t;p.useLayoutEffect(()=>{c.current&&y(c.current.offsetWidth)},[]);function T(){var d;return n?"Loading...":l?"Error":s?(d=t==null?void 0:t.find(Y=>Y.id===s))==null?void 0:d.name:`Select ${r}`}function S(d,Y){i(Y),M(!1)}return a.jsxs(e.Popover,{open:m,onOpenChange:M,children:[a.jsx(e.PopoverTrigger,{asChild:!0,children:a.jsxs(e.Button,{ref:c,variant:"outline",role:"combobox","aria-expanded":m,className:e.cn("flex h-9 w-full justify-between",C),children:[a.jsxs("div",{className:"flex items-center gap-2",children:[o&&a.jsx("div",{className:"mr-2",children:o}),a.jsx("span",{className:"max-w-[150px] overflow-hidden truncate text-ellipsis whitespace-nowrap",children:T()})]}),a.jsx(e.ChevronDown,{className:"size-4 opacity-50"})]})}),a.jsx(e.PopoverContent,{className:"w-full p-0",style:{minWidth:g},children:a.jsxs(e.Command,{children:[a.jsxs("div",{className:"flex h-9 items-center justify-between border-b pr-1",children:[a.jsx(e.CommandInput,{className:"h-9",placeholder:"Search..."}),a.jsx(e.IconButton,{className:"h-7",onClick:f,children:a.jsx(E,{className:e.cn("size-3.5 opacity-50",n&&"animate-spin")})})]}),a.jsxs(e.CommandList,{children:[a.jsxs(e.CommandEmpty,{children:["No ",r==null?void 0:r.toLowerCase()," found."]}),a.jsx(e.CommandGroup,{children:D==null?void 0:D.map(d=>a.jsx(e.CommandItem,{className:"overflow-x-auto",value:d.name,onSelect:Y=>S(Y,d.id),children:a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(e.Check,{className:e.cn("size-4",s===d.id?"opacity-100":"opacity-0")}),a.jsx("div",{title:d.name,children:d.name})]})},d.id))})]})]})})]})}exports.Dashboard=e.Dashboard;exports.DashboardWC=e.DashboardWC;exports.ResourceType=e.ResourceType;exports.SemaphorContextProvider=e.SemaphorContextProvider;exports.SemaphorDataProvider=e.SemaphorQueryClient;exports.SemaphorQueryClient=e.SemaphorQueryClient;exports.createEmptyKpiConfig=e.createEmptyKpiConfig;exports.createSqlGenConfig=e.createSqlGenConfig;exports.downloadPdf=e.downloadPdf;exports.fmt=e.fmt;exports.getColumnDataType=e.getColumnDataType;exports.getFilterValueType=e.getFilterValueType;exports.getFormattedTableNameForQuery=e.getFormattedTableNameForQuery;exports.getQualifiedTableName=e.getQualifiedTableName;exports.getSql=e.getSql;exports.invalidateToken=e.invalidateToken;exports.isBooleanDataType=e.isBooleanDataType;exports.isColumnInSqlGen=e.isColumnInSqlGen;exports.isDateDataType=e.isDateDataType;exports.isNumberDataType=e.isNumberDataType;exports.isTextDataType=e.isTextDataType;exports.resolveDataType=e.resolveDataType;exports.resolveDatamodelName=e.resolveDatamodelName;exports.useCard=e.useCard;exports.useCurrentActiveCard=e.useCurrentActiveCard;exports.useCurrentCardConfig=e.useCurrentCardConfig;exports.useCurrentSheetActiveCards=e.useCurrentSheetActiveCards;exports.useDashboardActions=e.useDashboardActions;exports.useDashboardStore=e.useDashboardStore;exports.useDataColumns=e.useDataColumns;exports.useDateFilterHook=e.useDateFilterHook;exports.useEditorActions=e.useEditorActions;exports.useEditorAside=e.useEditorAside;exports.useEditorStore=e.useEditorStore;exports.useTextFilterHook=e.useTextFilterHook;exports.EMPTY_SELECTION=v.EMPTY_SELECTION;exports.AdvancedModeToggle=u.AdvancedModeToggle;exports.ResourceManagementPanel=u.ResourceManagementPanel;exports.ScheduleDashboard=u.ScheduleDashboard;exports.ShareDialog=u.ShareDialog;exports.Surfboard=u.DashboardPlus;exports.VisualBadge=u.VisualBadge;exports.VisualEditingControls=u.VisualEditingControls;exports.cleanCard=u.cleanCard;exports.getDashbaordStateWithoutData=u.getDashbaordStateWithoutData;exports.Combobox=_;exports.DATE_FORMAT_VALUES=A;exports.PivotMarkerEnum=b;exports.Visual=N;
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
- import { c as x, E as b, F as N, S as w, U as A, a as L, C as _, u as P, b as v, d as E, P as k, e as W, B as F, f as m, g as R, h as V, i as B, j as O, I as Q, k as I, l as j, m as q, n as U, o as z } from "./chunks/index-BCkptgcw.js";
2
- import { D as ne, t as ie, R as de, r as le, r as ce, K as Ye, w as ue, y as he, M as fe, L as pe, Q as Me, T as me, J as De, v as Ce, H as ve, N as be, G as ge, A as ye, z as Te, V as Se, O as xe, s as Ne, X as we, Z as Ae, Y as Le, _ as _e, x as Pe, p as Ee, a0 as ke, W as We, $ as Fe, q as Re } from "./chunks/index-BCkptgcw.js";
3
- import { EMPTY_SELECTION as Be } from "./types/index.js";
4
- import { A as Qe, R as Ie, b as je, S as qe, D as Ue, a as ze, V as Ge, c as He, g as $e } from "./chunks/dashboard-plus-XEKMZ7Lk.js";
1
+ import { c as x, E as v, F as N, S as w, U as A, a as L, C as _, u as E, b as g, d as P, P as k, e as W, B as F, f as M, g as R, h as V, i as B, j as O, I as Q, k as I, l as j, m as q, n as U, o as z } from "./chunks/index-C3YhLxkw.js";
2
+ import { D as ne, t as ie, R as de, r as le, r as ce, $ as Ye, K as ue, w as he, y as pe, M as fe, L as me, Q as Me, T as Ce, J as De, v as ge, H as ve, N as ye, G as be, A as Te, z as Se, V as xe, O as Ne, s as we, X as Ae, Z as Le, Y as _e, _ as Ee, x as Pe, p as ke, a1 as We, W as Fe, a0 as Re, q as Ve } from "./chunks/index-C3YhLxkw.js";
3
+ import { EMPTY_SELECTION as Oe } from "./types/index.js";
4
+ import { A as Ie, R as je, b as qe, S as Ue, D as ze, a as Ge, V as He, c as $e, g as Ke } from "./chunks/dashboard-plus-DNG6HyXE.js";
5
5
  import { jsx as e, jsxs as d } from "react/jsx-runtime";
6
6
  import * as h from "react";
7
7
  import { useMemo as G } from "react";
@@ -24,23 +24,23 @@ function ae(a) {
24
24
  id: a.dashboardId
25
25
  // override the id to the dashboard id so that the dashboard is not loaded
26
26
  };
27
- return /* @__PURE__ */ e(b, { FallbackComponent: N, children: /* @__PURE__ */ e(w, { dashboardProps: l, children: /* @__PURE__ */ e(A, { children: /* @__PURE__ */ e(L, { displayPreferences: o, children: /* @__PURE__ */ e(_, { type: "visual", ...l, children: /* @__PURE__ */ e($, { cardId: a.cardId }) }) }) }) }) });
27
+ return /* @__PURE__ */ e(v, { FallbackComponent: N, children: /* @__PURE__ */ e(w, { dashboardProps: l, children: /* @__PURE__ */ e(A, { children: /* @__PURE__ */ e(L, { displayPreferences: o, children: /* @__PURE__ */ e(_, { type: "visual", ...l, children: /* @__PURE__ */ e($, { cardId: a.cardId }) }) }) }) }) });
28
28
  }
29
29
  function $({ cardId: a }) {
30
- const o = P((r) => {
30
+ const o = E((r) => {
31
31
  var t;
32
32
  return (t = r.dashboard) == null ? void 0 : t.sheets;
33
33
  }), { card: i, frame: l } = G(() => {
34
- const r = o == null ? void 0 : o.flatMap((s) => s.frames), t = r == null ? void 0 : r.flatMap((s) => s == null ? void 0 : s.cards), f = t == null ? void 0 : t.find((s) => (s == null ? void 0 : s.id) === a), p = r == null ? void 0 : r.find(
34
+ const r = o == null ? void 0 : o.flatMap((s) => s.frames), t = r == null ? void 0 : r.flatMap((s) => s == null ? void 0 : s.cards), p = t == null ? void 0 : t.find((s) => (s == null ? void 0 : s.id) === a), f = r == null ? void 0 : r.find(
35
35
  (s) => {
36
36
  var u;
37
37
  return (u = s == null ? void 0 : s.cards) == null ? void 0 : u.find((c) => (c == null ? void 0 : c.id) === a);
38
38
  }
39
39
  );
40
- return { card: f, frame: p };
40
+ return { card: p, frame: f };
41
41
  }, [o, a]);
42
42
  return !i || !l ? /* @__PURE__ */ e(
43
- v,
43
+ g,
44
44
  {
45
45
  error: new Error("Card not found"),
46
46
  resetErrorBoundary: () => {
@@ -48,20 +48,20 @@ function $({ cardId: a }) {
48
48
  customerFacingMessage: `Card not found with ID: ${a}`
49
49
  }
50
50
  ) : /* @__PURE__ */ e("main", { className: "flex h-full grow flex-col", children: /* @__PURE__ */ e(
51
- b,
51
+ v,
52
52
  {
53
53
  FallbackComponent: ({
54
54
  error: r,
55
55
  resetErrorBoundary: t
56
56
  }) => /* @__PURE__ */ e(
57
- v,
57
+ g,
58
58
  {
59
59
  error: r,
60
60
  resetErrorBoundary: t,
61
61
  customerFacingMessage: "Error creating visual. Please try again."
62
62
  }
63
63
  ),
64
- children: /* @__PURE__ */ e(E, { card: i, frame: l })
64
+ children: /* @__PURE__ */ e(P, { card: i, frame: l })
65
65
  }
66
66
  ) });
67
67
  }
@@ -96,7 +96,7 @@ const se = [
96
96
  // Custom format
97
97
  "custom"
98
98
  ];
99
- var X = /* @__PURE__ */ ((a) => (a.SUBTOTAL = "__SUBTOTAL__", a.TOTAL = "__TOTAL__", a.ALL = "__ALL__", a))(X || {});
99
+ var K = /* @__PURE__ */ ((a) => (a.SUBTOTAL = "__SUBTOTAL__", a.TOTAL = "__TOTAL__", a.ALL = "__ALL__", a))(K || {});
100
100
  function re({
101
101
  name: a,
102
102
  items: o,
@@ -104,31 +104,31 @@ function re({
104
104
  onChange: l,
105
105
  isLoading: r,
106
106
  isError: t,
107
- refetch: f,
108
- className: p,
107
+ refetch: p,
108
+ className: f,
109
109
  icon: s,
110
110
  showNone: u = !1
111
111
  }) {
112
- const c = h.useRef(null), [D, C] = h.useState(!1), [g, y] = h.useState("100%"), M = u ? [...o || [], { id: "none", name: "None" }] : o;
112
+ const c = h.useRef(null), [C, D] = h.useState(!1), [y, b] = h.useState("100%"), m = u ? [...o || [], { id: "none", name: "None" }] : o;
113
113
  h.useLayoutEffect(() => {
114
- c.current && y(c.current.offsetWidth);
114
+ c.current && b(c.current.offsetWidth);
115
115
  }, []);
116
116
  function T() {
117
117
  var n;
118
118
  return r ? "Loading..." : t ? "Error" : i ? (n = o == null ? void 0 : o.find((Y) => Y.id === i)) == null ? void 0 : n.name : `Select ${a}`;
119
119
  }
120
120
  function S(n, Y) {
121
- l(Y), C(!1);
121
+ l(Y), D(!1);
122
122
  }
123
- return /* @__PURE__ */ d(k, { open: D, onOpenChange: C, children: [
123
+ return /* @__PURE__ */ d(k, { open: C, onOpenChange: D, children: [
124
124
  /* @__PURE__ */ e(W, { asChild: !0, children: /* @__PURE__ */ d(
125
125
  F,
126
126
  {
127
127
  ref: c,
128
128
  variant: "outline",
129
129
  role: "combobox",
130
- "aria-expanded": D,
131
- className: m("flex h-9 w-full justify-between", p),
130
+ "aria-expanded": C,
131
+ className: M("flex h-9 w-full justify-between", f),
132
132
  children: [
133
133
  /* @__PURE__ */ d("div", { className: "flex items-center gap-2", children: [
134
134
  s && /* @__PURE__ */ e("div", { className: "mr-2", children: s }),
@@ -142,14 +142,14 @@ function re({
142
142
  V,
143
143
  {
144
144
  className: "w-full p-0",
145
- style: { minWidth: g },
145
+ style: { minWidth: y },
146
146
  children: /* @__PURE__ */ d(B, { children: [
147
147
  /* @__PURE__ */ d("div", { className: "flex h-9 items-center justify-between border-b pr-1", children: [
148
148
  /* @__PURE__ */ e(O, { className: "h-9", placeholder: "Search..." }),
149
- /* @__PURE__ */ e(Q, { className: "h-7", onClick: f, children: /* @__PURE__ */ e(
149
+ /* @__PURE__ */ e(Q, { className: "h-7", onClick: p, children: /* @__PURE__ */ e(
150
150
  H,
151
151
  {
152
- className: m(
152
+ className: M(
153
153
  "size-3.5 opacity-50",
154
154
  r && "animate-spin"
155
155
  )
@@ -162,7 +162,7 @@ function re({
162
162
  a == null ? void 0 : a.toLowerCase(),
163
163
  " found."
164
164
  ] }),
165
- /* @__PURE__ */ e(q, { children: M == null ? void 0 : M.map((n) => /* @__PURE__ */ e(
165
+ /* @__PURE__ */ e(q, { children: m == null ? void 0 : m.map((n) => /* @__PURE__ */ e(
166
166
  U,
167
167
  {
168
168
  className: "overflow-x-auto",
@@ -172,7 +172,7 @@ function re({
172
172
  /* @__PURE__ */ e(
173
173
  z,
174
174
  {
175
- className: m(
175
+ className: M(
176
176
  "size-4",
177
177
  i === n.id ? "opacity-100" : "opacity-0"
178
178
  )
@@ -190,52 +190,53 @@ function re({
190
190
  ] });
191
191
  }
192
192
  export {
193
- Qe as AdvancedModeToggle,
193
+ Ie as AdvancedModeToggle,
194
194
  re as Combobox,
195
195
  se as DATE_FORMAT_VALUES,
196
196
  ne as Dashboard,
197
197
  ie as DashboardWC,
198
- Be as EMPTY_SELECTION,
199
- X as PivotMarkerEnum,
200
- Ie as ResourceManagementPanel,
198
+ Oe as EMPTY_SELECTION,
199
+ K as PivotMarkerEnum,
200
+ je as ResourceManagementPanel,
201
201
  de as ResourceType,
202
- je as ScheduleDashboard,
202
+ qe as ScheduleDashboard,
203
203
  w as SemaphorContextProvider,
204
204
  le as SemaphorDataProvider,
205
205
  ce as SemaphorQueryClient,
206
- qe as ShareDialog,
207
- Ue as Surfboard,
206
+ Ue as ShareDialog,
207
+ ze as Surfboard,
208
208
  ae as Visual,
209
- ze as VisualBadge,
210
- Ge as VisualEditingControls,
211
- He as cleanCard,
212
- Ye as createSqlGenConfig,
213
- ue as downloadPdf,
214
- he as fmt,
209
+ Ge as VisualBadge,
210
+ He as VisualEditingControls,
211
+ $e as cleanCard,
212
+ Ye as createEmptyKpiConfig,
213
+ ue as createSqlGenConfig,
214
+ he as downloadPdf,
215
+ pe as fmt,
215
216
  fe as getColumnDataType,
216
- $e as getDashbaordStateWithoutData,
217
- pe as getFilterValueType,
217
+ Ke as getDashbaordStateWithoutData,
218
+ me as getFilterValueType,
218
219
  Me as getFormattedTableNameForQuery,
219
- me as getQualifiedTableName,
220
+ Ce as getQualifiedTableName,
220
221
  De as getSql,
221
- Ce as invalidateToken,
222
+ ge as invalidateToken,
222
223
  ve as isBooleanDataType,
223
- be as isColumnInSqlGen,
224
- ge as isDateDataType,
225
- ye as isNumberDataType,
226
- Te as isTextDataType,
227
- Se as resolveDataType,
228
- xe as resolveDatamodelName,
229
- Ne as useCard,
230
- we as useCurrentActiveCard,
231
- Ae as useCurrentCardConfig,
232
- Le as useCurrentSheetActiveCards,
233
- _e as useDashboardActions,
234
- P as useDashboardStore,
224
+ ye as isColumnInSqlGen,
225
+ be as isDateDataType,
226
+ Te as isNumberDataType,
227
+ Se as isTextDataType,
228
+ xe as resolveDataType,
229
+ Ne as resolveDatamodelName,
230
+ we as useCard,
231
+ Ae as useCurrentActiveCard,
232
+ Le as useCurrentCardConfig,
233
+ _e as useCurrentSheetActiveCards,
234
+ Ee as useDashboardActions,
235
+ E as useDashboardStore,
235
236
  Pe as useDataColumns,
236
- Ee as useDateFilterHook,
237
- ke as useEditorActions,
238
- We as useEditorAside,
239
- Fe as useEditorStore,
240
- Re as useTextFilterHook
237
+ ke as useDateFilterHook,
238
+ We as useEditorActions,
239
+ Fe as useEditorAside,
240
+ Re as useEditorStore,
241
+ Ve as useTextFilterHook
241
242
  };