react-semaphor 0.1.149 → 0.1.150

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.
Files changed (28) hide show
  1. package/dist/chunks/{dashboard-controls-DE_wHkIK.js → dashboard-controls-CrWp_eW0.js} +3 -3
  2. package/dist/chunks/{dashboard-controls-BTd2GP5a.js → dashboard-controls-Hw3sWZQd.js} +1 -1
  3. package/dist/chunks/{dashboard-export-dialog-DvMsFXpk.js → dashboard-export-dialog-Bdt-TnlL.js} +1 -1
  4. package/dist/chunks/{dashboard-export-dialog-CrxAp9yB.js → dashboard-export-dialog-CTDWnL2v.js} +3 -3
  5. package/dist/chunks/{dashboard-json-xnqDLMfc.js → dashboard-json-BvV_dByo.js} +1 -1
  6. package/dist/chunks/{dashboard-json-B1RDTwhR.js → dashboard-json-CKQPyk-T.js} +1 -1
  7. package/dist/chunks/{edit-dashboard-visual-DEgGCKtt.js → edit-dashboard-visual-DKx_Fd1g.js} +2 -2
  8. package/dist/chunks/{edit-dashboard-visual-B9NwuwjE.js → edit-dashboard-visual-JmSJtVAb.js} +3 -3
  9. package/dist/chunks/{editor-action-buttons-DiV0FffF.js → editor-action-buttons-BrlrQ2Xg.js} +2 -2
  10. package/dist/chunks/{editor-action-buttons-Be2gqSdc.js → editor-action-buttons-D98KnvrV.js} +1 -1
  11. package/dist/chunks/{index-BISErscW.js → index-DHIYxVk4.js} +80575 -51326
  12. package/dist/chunks/index-zUMoYWue.js +1339 -0
  13. package/dist/chunks/{resource-management-panel-CBrnB1xs.js → resource-management-panel-B5efhyg2.js} +1 -1
  14. package/dist/chunks/{resource-management-panel-B8oEtLaB.js → resource-management-panel-QHQGFqsL.js} +2 -2
  15. package/dist/chunks/{use-visual-utils-DF-sQ-ZN.js → use-visual-utils-B8vSKgmQ.js} +1 -1
  16. package/dist/chunks/{use-visual-utils-DgOik-Ul.js → use-visual-utils-CuQz3wl2.js} +1 -1
  17. package/dist/dashboard/index.cjs +1 -1
  18. package/dist/dashboard/index.js +1 -1
  19. package/dist/index.cjs +1 -1
  20. package/dist/index.js +4 -4
  21. package/dist/surfboard/index.cjs +1 -1
  22. package/dist/surfboard/index.js +1 -1
  23. package/dist/types/dashboard.d.ts +4 -3
  24. package/dist/types/main.d.ts +17 -16
  25. package/dist/types/surfboard.d.ts +4 -3
  26. package/dist/types/types.d.ts +1 -0
  27. package/package.json +5 -5
  28. package/dist/chunks/index-Cz1fGuVl.js +0 -1086
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("./index-Cz1fGuVl.js"),c=require("react"),oe=require("./use-visual-utils-DF-sQ-ZN.js");/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("./index-zUMoYWue.js"),c=require("react"),oe=require("./use-visual-utils-B8vSKgmQ.js");/**
2
2
  * @license lucide-react v0.453.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,7 +1,7 @@
1
1
  import { jsx as e, jsxs as a, Fragment as me } from "react/jsx-runtime";
2
- import { b as We, u as ce, f as qe, ap as ie, b5 as Je, b6 as Qe, c as ee, b7 as Ye, aG as Xe, aH as Ze, B as G, aI as $e, aJ as ke, aK as Q, b8 as ue, L as re, b9 as et, ba as tt, bb as st, bc as Ne, bd as pe, be as at, bf as nt, I as it, bg as we, bh as oe, bi as ve, bj as Ce, bk as rt, M as ye, R as Se, bl as Ee, aO as Ve, aP as Le, aQ as Ae, aS as Te, aT as Oe, aU as Re, aV as Pe, aW as Ie, bm as ot, bn as lt, bo as Ue, bp as Me, bq as je, br as dt, bs as Fe, bt as ct, A as ae, ao as ut, bu as ht, bv as ze, bw as mt, bx as pt, at as ft, au as gt, av as Dt, aw as xt, ax as Nt, ay as be, az as he, aC as bt, by as wt, bz as vt, bA as Ct, bB as yt } from "./index-BISErscW.js";
2
+ import { b as We, u as ce, f as qe, ap as ie, b5 as Je, b6 as Qe, c as ee, b7 as Ye, aG as Xe, aH as Ze, B as G, aI as $e, aJ as ke, aK as Q, b8 as ue, L as re, b9 as et, ba as tt, bb as st, bc as Ne, bd as pe, be as at, bf as nt, I as it, bg as we, bh as oe, bi as ve, bj as Ce, bk as rt, M as ye, R as Se, bl as Ee, aO as Ve, aP as Le, aQ as Ae, aS as Te, aT as Oe, aU as Re, aV as Pe, aW as Ie, bm as ot, bn as lt, bo as Ue, bp as Me, bq as je, br as dt, bs as Fe, bt as ct, A as ae, ao as ut, bu as ht, bv as ze, bw as mt, bx as pt, at as ft, au as gt, av as Dt, aw as xt, ax as Nt, ay as be, az as he, aC as bt, by as wt, bz as vt, bA as Ct, bB as yt } from "./index-DHIYxVk4.js";
3
3
  import St, { useRef as Et, useEffect as ne, useState as x } from "react";
4
- import { a as Be } from "./use-visual-utils-DgOik-Ul.js";
4
+ import { a as Be } from "./use-visual-utils-CuQz3wl2.js";
5
5
  /**
6
6
  * @license lucide-react v0.453.0 - ISC
7
7
  *
@@ -1 +1 @@
1
- "use strict";const o=require("./index-Cz1fGuVl.js"),b=require("react");function _(e){const a=e.toUpperCase().indexOf("WHERE"),r=e.toUpperCase().indexOf("GROUP BY"),t=e.toUpperCase().indexOf("LIMIT"),d=e.toUpperCase().indexOf("ORDER BY");let c=e.length;if(d!==-1&&(c=d),t!==-1&&t<c&&(c=t),a!==-1){const n=e.substring(0,a),s=e.substring(a);return`${n} {{ filters | where }} AND ${s.substring(6)}`}else if(r!==-1){const n=e.substring(0,r),s=e.substring(r);return`${n} {{ filters | where }} ${s}`}else{const n=e.substring(0,c),s=e.substring(c);return console.log("beforeClause",n),console.log("afterClause",s),s?`${n} {{ filters | where }} ${s}`:`${n.replace(/;$/,"")} {{ filters | where }}`}}function B(e){const[a,r]=b.useState(null),[t,d]=b.useState(null),c=o.useEnsureReactGlobals();return b.useEffect(()=>{if(!e||e.trim()===""){r(null),d(null);return}if(!c)return;(async()=>{try{if(!e.startsWith("http://")&&!e.startsWith("https://"))throw new Error(`Invalid URL format: ${e}`);try{new URL(e)}catch{throw new Error(`Invalid URL: ${e}`)}const l=`${e.endsWith("/")?e:`${e}/`}index.js`;try{if(!(await fetch(l,{method:"HEAD"})).ok)throw new Error(`Module not found at ${l}`)}catch{}const m=await import(l);if(typeof m.useChartStore!="function")throw new Error("useChartStore is not a function");r(()=>m.useChartStore),d(null)}catch(s){const l=s instanceof Error?s.message:"Unknown error";console.error("Failed to load remote chart store:",l),d(l),r(null)}})()},[e,c]),a}function H(e,a){if(e.length===0)return"";if(a){const r=e.find(t=>t.id===a);if(r){const t=r.tabTitle;if(t=="All__Header")return e[0].id;if(t&&t.endsWith("__Header")){const c=t.split("__")[0],n=e.find(s=>s.tabTitle===c);return n?n.id:e[0].id}return a}}return e[0].id}async function j(e,a,r,t){if(!a||!r)throw new Error("Missing auth token or visual ID");const d=["resource-by-id","visual",r],c=t.getQueryData(d);if(c)return console.log("Using cached visual data for:",r),{data:c,fromCache:!0};console.log("Fetching visual data from network for:",r);const n=o.ue.loading("Loading visual...",{position:"top-center"});try{const s=await fetch(`${e}/management/v1/visuals/${r}`,{headers:{Authorization:`Bearer ${a}`}});if(!s.ok)throw new Error("Failed to load visual");const l=await s.json();return t.setQueryData(d,l),o.ue.dismiss(n),{data:l,fromCache:!1}}catch(s){throw o.ue.dismiss(n),s}}function T(e){if(typeof e=="string")return JSON.parse(e);if(typeof e=="object")return e;throw new Error("Invalid frame object format")}function Q(e,a){var c,n;const r=(e==null?void 0:e.frameObject)??((c=e==null?void 0:e.visual)==null?void 0:c.frameObject);if(!r)return!1;const t=T(r);if(!(t!=null&&t.cards)||t.cards.length===0)return!1;const d=(n=t.cards)==null?void 0:n.find(s=>s.id===t.activeCardId);return d?(o.setupEditorWithCard({...a,frame:t,card:d,visualId:(e==null?void 0:e.id)||t.visualId}),!0):!1}function G(){var g;const{setCardSql:e}=o.useEditorActions(),a=o.useEditorStore(i=>i.frame),r=o.useEditorStore(i=>i.card),t=B(((g=r.customCardPreferences)==null?void 0:g.url)||""),d=o.useEditorStore(i=>i.selectedSchemaName),c=o.useEditorStore(i=>i.selectedDatamodelId),n=o.useEditorStore(i=>i.selectedDatabaseName),s=o.useEditorStore(i=>i.selectedTableName),l=o.useEditorStore(i=>i.selectedConnectionId),m=o.useEditorStore(i=>i.isShowingVisual),f=r.sql;return{getUpdatedFrame:b.useCallback(()=>{var E;let i=f;f&&!f.includes("{{")&&(i=_(f),e(i));const C=(E=t==null?void 0:t.getState())==null?void 0:E.settings,U={...r,dataSource:r.dataSource||{mode:"directSource"},lastSelectedSchema:d,lastSelectedDatamodelId:c,lastSelectedDatabase:n,lastSelectedTable:s,connectionId:l,sql:i,customCfg:m?r.customCfg:null,preferences:r.preferences,...C&&{customCardPreferences:{...r.customCardPreferences,settings:C}}},w=a.cards.map(S=>S.id===r.id?U:S);return{...a,cards:w,activeCardId:H(w,a.activeCardId)}},[r,a,m,d,c,n,s,l,e,t,f])}}function z(){const{authToken:e,tokenProps:a}=o.useSemaphorContext(),r=o.useQueryClient(),t=o.useSelectedVisual(),{selectVisual:d}=o.useManagementActions(),{setFrame:c,setCard:n,setIsDevMode:s,setActiveTabCardId:l,updateDataSource:m,setQueryResultColumns:f,setSelectedConnectionId:V,setSelectedDatabaseName:g,setSelectedSchemaName:i,setSelectedTableName:C,setSelectedDatamodelId:U,setFilterValues:w,setApplyFilters:E}=o.useEditorActions(),{setIsDashboardEditing:S,setIsVisualEditing:$,setSelectedFrameId:v,clearSelectedFrameId:A,addFrame:N,setIsDashboardPanelOpen:R}=o.useDashboardActions(),I=o.useDashboardStore(u=>u.selectedSheetId),D=o.useDashboardStore(u=>u.selectedFrameId),O=o.useDashboardStore(u=>u.dashboard),x=o.useDashboardStore(u=>u.filterValues),y=o.useVisualById((t==null?void 0:t.id)||"",{enabled:!!(t!=null&&t.id)&&!!(e!=null&&e.accessToken)}),M=b.useCallback(async u=>{try{d(u),A();const{data:p,fromCache:h}=await j(a.apiServiceUrl,(e==null?void 0:e.accessToken)||"",u.id,r);if(!Q(p,{setFrame:c,setCard:n,setIsDevMode:s,setActiveTabCardId:l,updateDataSource:m,setQueryResultColumns:f,setSelectedConnectionId:V,setSelectedDatabaseName:g,setSelectedSchemaName:i,setSelectedTableName:C,setSelectedDatamodelId:U,setFilterValues:w,setApplyFilters:E,setIsDashboardEditing:S,setIsVisualEditing:$,dashboard:O,selectedSheetId:I,selectedFrameId:D,filterValues:x}))throw new Error("Failed to setup editor with visual data");return{success:!0,fromCache:h}}catch(p){return console.error("Error editing visual:",p),{success:!1,error:"Failed to load visual for editing"}}},[e==null?void 0:e.accessToken,a.apiServiceUrl,r,d,c,n,S,$,s,l,m,f,V,g,i,C,U,w,E,A,O,I,D,x]),k=b.useCallback(async u=>{var p;try{if(d(u),!I)return{success:!1,error:"No sheet selected. Please select a sheet first."};const{data:h,fromCache:W}=await j(a.apiServiceUrl,(e==null?void 0:e.accessToken)||"",u.id,r),L=(h==null?void 0:h.frameObject)??((p=h==null?void 0:h.visual)==null?void 0:p.frameObject);if(!L)return{success:!1,error:"Visual has no frame data"};const F=T(L);if(!(F!=null&&F.cards)||F.cards.length===0)return{success:!1,error:"Visual frame is malformed"};const P={...o.cloneFrameWithNewIds(F),visualId:u.id};return N(I,P,"end"),S(!0),v(P.id),R(!1),{success:!0,fromCache:W}}catch(h){return console.error("Error adding visual:",h),{success:!1,error:"Failed to add visual to dashboard"}}},[e==null?void 0:e.accessToken,a.apiServiceUrl,r,d,I,N,S,v,R]);return{visual:y.data,isLoading:y.isLoading,isError:y.isError,error:y.error,handleEditLibraryVisual:M,handleAddLibraryVisual:k,getUpdatedFrame:G().getUpdatedFrame,refetch:y.refetch}}exports.useRemoteChartStore=B;exports.useVisualUtils=z;
1
+ "use strict";const o=require("./index-zUMoYWue.js"),b=require("react");function _(e){const a=e.toUpperCase().indexOf("WHERE"),r=e.toUpperCase().indexOf("GROUP BY"),t=e.toUpperCase().indexOf("LIMIT"),d=e.toUpperCase().indexOf("ORDER BY");let c=e.length;if(d!==-1&&(c=d),t!==-1&&t<c&&(c=t),a!==-1){const n=e.substring(0,a),s=e.substring(a);return`${n} {{ filters | where }} AND ${s.substring(6)}`}else if(r!==-1){const n=e.substring(0,r),s=e.substring(r);return`${n} {{ filters | where }} ${s}`}else{const n=e.substring(0,c),s=e.substring(c);return console.log("beforeClause",n),console.log("afterClause",s),s?`${n} {{ filters | where }} ${s}`:`${n.replace(/;$/,"")} {{ filters | where }}`}}function B(e){const[a,r]=b.useState(null),[t,d]=b.useState(null),c=o.useEnsureReactGlobals();return b.useEffect(()=>{if(!e||e.trim()===""){r(null),d(null);return}if(!c)return;(async()=>{try{if(!e.startsWith("http://")&&!e.startsWith("https://"))throw new Error(`Invalid URL format: ${e}`);try{new URL(e)}catch{throw new Error(`Invalid URL: ${e}`)}const l=`${e.endsWith("/")?e:`${e}/`}index.js`;try{if(!(await fetch(l,{method:"HEAD"})).ok)throw new Error(`Module not found at ${l}`)}catch{}const m=await import(l);if(typeof m.useChartStore!="function")throw new Error("useChartStore is not a function");r(()=>m.useChartStore),d(null)}catch(s){const l=s instanceof Error?s.message:"Unknown error";console.error("Failed to load remote chart store:",l),d(l),r(null)}})()},[e,c]),a}function H(e,a){if(e.length===0)return"";if(a){const r=e.find(t=>t.id===a);if(r){const t=r.tabTitle;if(t=="All__Header")return e[0].id;if(t&&t.endsWith("__Header")){const c=t.split("__")[0],n=e.find(s=>s.tabTitle===c);return n?n.id:e[0].id}return a}}return e[0].id}async function j(e,a,r,t){if(!a||!r)throw new Error("Missing auth token or visual ID");const d=["resource-by-id","visual",r],c=t.getQueryData(d);if(c)return console.log("Using cached visual data for:",r),{data:c,fromCache:!0};console.log("Fetching visual data from network for:",r);const n=o.ue.loading("Loading visual...",{position:"top-center"});try{const s=await fetch(`${e}/management/v1/visuals/${r}`,{headers:{Authorization:`Bearer ${a}`}});if(!s.ok)throw new Error("Failed to load visual");const l=await s.json();return t.setQueryData(d,l),o.ue.dismiss(n),{data:l,fromCache:!1}}catch(s){throw o.ue.dismiss(n),s}}function T(e){if(typeof e=="string")return JSON.parse(e);if(typeof e=="object")return e;throw new Error("Invalid frame object format")}function Q(e,a){var c,n;const r=(e==null?void 0:e.frameObject)??((c=e==null?void 0:e.visual)==null?void 0:c.frameObject);if(!r)return!1;const t=T(r);if(!(t!=null&&t.cards)||t.cards.length===0)return!1;const d=(n=t.cards)==null?void 0:n.find(s=>s.id===t.activeCardId);return d?(o.setupEditorWithCard({...a,frame:t,card:d,visualId:(e==null?void 0:e.id)||t.visualId}),!0):!1}function G(){var g;const{setCardSql:e}=o.useEditorActions(),a=o.useEditorStore(i=>i.frame),r=o.useEditorStore(i=>i.card),t=B(((g=r.customCardPreferences)==null?void 0:g.url)||""),d=o.useEditorStore(i=>i.selectedSchemaName),c=o.useEditorStore(i=>i.selectedDatamodelId),n=o.useEditorStore(i=>i.selectedDatabaseName),s=o.useEditorStore(i=>i.selectedTableName),l=o.useEditorStore(i=>i.selectedConnectionId),m=o.useEditorStore(i=>i.isShowingVisual),f=r.sql;return{getUpdatedFrame:b.useCallback(()=>{var E;let i=f;f&&!f.includes("{{")&&(i=_(f),e(i));const C=(E=t==null?void 0:t.getState())==null?void 0:E.settings,U={...r,dataSource:r.dataSource||{mode:"directSource"},lastSelectedSchema:d,lastSelectedDatamodelId:c,lastSelectedDatabase:n,lastSelectedTable:s,connectionId:l,sql:i,customCfg:m?r.customCfg:null,preferences:r.preferences,...C&&{customCardPreferences:{...r.customCardPreferences,settings:C}}},w=a.cards.map(S=>S.id===r.id?U:S);return{...a,cards:w,activeCardId:H(w,a.activeCardId)}},[r,a,m,d,c,n,s,l,e,t,f])}}function z(){const{authToken:e,tokenProps:a}=o.useSemaphorContext(),r=o.useQueryClient(),t=o.useSelectedVisual(),{selectVisual:d}=o.useManagementActions(),{setFrame:c,setCard:n,setIsDevMode:s,setActiveTabCardId:l,updateDataSource:m,setQueryResultColumns:f,setSelectedConnectionId:V,setSelectedDatabaseName:g,setSelectedSchemaName:i,setSelectedTableName:C,setSelectedDatamodelId:U,setFilterValues:w,setApplyFilters:E}=o.useEditorActions(),{setIsDashboardEditing:S,setIsVisualEditing:$,setSelectedFrameId:v,clearSelectedFrameId:A,addFrame:N,setIsDashboardPanelOpen:R}=o.useDashboardActions(),I=o.useDashboardStore(u=>u.selectedSheetId),D=o.useDashboardStore(u=>u.selectedFrameId),O=o.useDashboardStore(u=>u.dashboard),x=o.useDashboardStore(u=>u.filterValues),y=o.useVisualById((t==null?void 0:t.id)||"",{enabled:!!(t!=null&&t.id)&&!!(e!=null&&e.accessToken)}),M=b.useCallback(async u=>{try{d(u),A();const{data:p,fromCache:h}=await j(a.apiServiceUrl,(e==null?void 0:e.accessToken)||"",u.id,r);if(!Q(p,{setFrame:c,setCard:n,setIsDevMode:s,setActiveTabCardId:l,updateDataSource:m,setQueryResultColumns:f,setSelectedConnectionId:V,setSelectedDatabaseName:g,setSelectedSchemaName:i,setSelectedTableName:C,setSelectedDatamodelId:U,setFilterValues:w,setApplyFilters:E,setIsDashboardEditing:S,setIsVisualEditing:$,dashboard:O,selectedSheetId:I,selectedFrameId:D,filterValues:x}))throw new Error("Failed to setup editor with visual data");return{success:!0,fromCache:h}}catch(p){return console.error("Error editing visual:",p),{success:!1,error:"Failed to load visual for editing"}}},[e==null?void 0:e.accessToken,a.apiServiceUrl,r,d,c,n,S,$,s,l,m,f,V,g,i,C,U,w,E,A,O,I,D,x]),k=b.useCallback(async u=>{var p;try{if(d(u),!I)return{success:!1,error:"No sheet selected. Please select a sheet first."};const{data:h,fromCache:W}=await j(a.apiServiceUrl,(e==null?void 0:e.accessToken)||"",u.id,r),L=(h==null?void 0:h.frameObject)??((p=h==null?void 0:h.visual)==null?void 0:p.frameObject);if(!L)return{success:!1,error:"Visual has no frame data"};const F=T(L);if(!(F!=null&&F.cards)||F.cards.length===0)return{success:!1,error:"Visual frame is malformed"};const P={...o.cloneFrameWithNewIds(F),visualId:u.id};return N(I,P,"end"),S(!0),v(P.id),R(!1),{success:!0,fromCache:W}}catch(h){return console.error("Error adding visual:",h),{success:!1,error:"Failed to add visual to dashboard"}}},[e==null?void 0:e.accessToken,a.apiServiceUrl,r,d,I,N,S,v,R]);return{visual:y.data,isLoading:y.isLoading,isError:y.isError,error:y.error,handleEditLibraryVisual:M,handleAddLibraryVisual:k,getUpdatedFrame:G().getUpdatedFrame,refetch:y.refetch}}exports.useRemoteChartStore=B;exports.useVisualUtils=z;
@@ -1,4 +1,4 @@
1
- import { an as G, ao as z, h as Y, i as J, ap as K, e as _, g as X, u as U, aq as Z, ar as q, l as v, as as ee, f as h } from "./index-BISErscW.js";
1
+ import { an as G, ao as z, h as Y, i as J, ap as K, e as _, g as X, u as U, aq as Z, ar as q, l as v, as as ee, f as h } from "./index-DHIYxVk4.js";
2
2
  import { useState as T, useEffect as te, useCallback as V } from "react";
3
3
  function re(e) {
4
4
  const o = e.toUpperCase().indexOf("WHERE"), r = e.toUpperCase().indexOf("GROUP BY"), t = e.toUpperCase().indexOf("LIMIT"), i = e.toUpperCase().indexOf("ORDER BY");
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/index-Cz1fGuVl.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-zUMoYWue.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-BISErscW.js";
1
+ import { D as a } from "../chunks/index-DHIYxVk4.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,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/index-Cz1fGuVl.js"),E=require("./types/index.cjs"),a=require("react/jsx-runtime"),g=require("react"),j=require("./chunks/resource-management-panel-CBrnB1xs.js"),c=require("./chunks/dashboard-export-dialog-DvMsFXpk.js");require("react-dom");function P(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 C=P(g);/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/index-zUMoYWue.js"),E=require("./types/index.cjs"),a=require("react/jsx-runtime"),g=require("react"),j=require("./chunks/resource-management-panel-B5efhyg2.js"),c=require("./chunks/dashboard-export-dialog-Bdt-TnlL.js");require("react-dom");function P(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 C=P(g);/**
2
2
  * @license lucide-react v0.453.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
- import { b as T, E as y, F as P, S as w, U as M, m as k, n as A, u as F, o as g, p as L, P as R, q as I, B as V, c as v, r as _, s as U, t as B, v as W, I as j, w as q, x as z, y as O, z as Q, C as G } from "./chunks/index-BISErscW.js";
2
- import { _ as oa, $ as na, D as ta, O as ia, a3 as la, R as da, K as ca, K as ua, M as ha, a as pa, V as fa, am as ma, aa as Ca, Y as va, Q as ba, T as Da, a4 as ga, ac as ya, ab as xa, af as Ea, ag as Na, a9 as Sa, W as Ta, a8 as Pa, a1 as wa, a2 as Ma, a0 as ka, ad as Aa, a7 as Fa, a6 as La, a5 as Ra, ah as Ia, ae as Va, N as _a, aj as Ua, al as Ba, ak as Wa, g as ja, G as qa, Z as za, H as Oa, e as Qa, ai as Ga, f as Ha, A as Ka, J as Ya } from "./chunks/index-BISErscW.js";
1
+ import { b as T, E as y, F as P, S as w, U as M, m as k, n as A, u as F, o as g, p as L, P as R, q as I, B as V, c as v, r as _, s as U, t as B, v as W, I as j, w as q, x as z, y as O, z as Q, C as G } from "./chunks/index-DHIYxVk4.js";
2
+ import { _ as oa, $ as na, D as ta, O as ia, a3 as la, R as da, K as ca, K as ua, M as ha, a as pa, V as fa, am as ma, aa as Ca, Y as va, Q as ba, T as Da, a4 as ga, ac as ya, ab as xa, af as Ea, ag as Na, a9 as Sa, W as Ta, a8 as Pa, a1 as wa, a2 as Ma, a0 as ka, ad as Aa, a7 as Fa, a6 as La, a5 as Ra, ah as Ia, ae as Va, N as _a, aj as Ua, al as Ba, ak as Wa, g as ja, G as qa, Z as za, H as Oa, e as Qa, ai as Ga, f as Ha, A as Ka, J as Ya } from "./chunks/index-DHIYxVk4.js";
3
3
  import { EMPTY_SELECTION as Ja } from "./types/index.js";
4
4
  import { jsx as a, jsxs as l } from "react/jsx-runtime";
5
5
  import * as p from "react";
6
6
  import { useMemo as H } from "react";
7
- import { ResourceManagementPanel as Za } from "./chunks/resource-management-panel-B8oEtLaB.js";
8
- import { A as ee, D as se, S as re, U as oe, V as ne, u as te } from "./chunks/dashboard-export-dialog-CrxAp9yB.js";
7
+ import { ResourceManagementPanel as Za } from "./chunks/resource-management-panel-QHQGFqsL.js";
8
+ import { A as ee, D as se, S as re, U as oe, V as ne, u as te } from "./chunks/dashboard-export-dialog-CTDWnL2v.js";
9
9
  import "react-dom";
10
10
  /**
11
11
  * @license lucide-react v0.453.0 - ISC
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/index-Cz1fGuVl.js"),r=require("../types/index.cjs");exports.Surfboard=e.DashboardPlus;exports.EMPTY_SELECTION=r.EMPTY_SELECTION;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/index-zUMoYWue.js"),r=require("../types/index.cjs");exports.Surfboard=e.DashboardPlus;exports.EMPTY_SELECTION=r.EMPTY_SELECTION;
@@ -1,4 +1,4 @@
1
- import { a } from "../chunks/index-BISErscW.js";
1
+ import { a } from "../chunks/index-DHIYxVk4.js";
2
2
  import { EMPTY_SELECTION as E } from "../types/index.js";
3
3
  export {
4
4
  E as EMPTY_SELECTION,
@@ -1,6 +1,7 @@
1
1
  import { ColumnSizingState } from '@tanstack/react-table';
2
2
  import { FontSpec } from 'chart.js';
3
- import { JSX as JSX_2 } from 'react/jsx-runtime';
3
+ import { JSX } from 'react/jsx-runtime';
4
+ import { JSX as JSX_2 } from 'react';
4
5
 
5
6
  export declare type AggregateCalc = 'AVG' | 'MIN' | 'MAX' | 'SUM' | 'COUNT' | 'COUNT_DISTINCT';
6
7
 
@@ -289,7 +290,7 @@ declare type ConnectionType = 'GoogleSheets' | 'MySQL' | 'MSSQL' | 'PostgreSQL'
289
290
 
290
291
  export declare type CustomCard = CardWithContent | CardWithFooter;
291
292
 
292
- export declare function Dashboard(props: DashboardProps): JSX_2.Element | null;
293
+ export declare function Dashboard(props: DashboardProps): JSX.Element | null;
293
294
 
294
295
  export declare type DashboardEventHandlers = {
295
296
  onExportData?: (payload: ExportDataPayload) => void;
@@ -831,7 +832,7 @@ declare interface JoinPlan {
831
832
  export declare type KPICardProps = {
832
833
  card: TCard;
833
834
  isLoading?: boolean;
834
- renderFilterInfo?: () => JSX.Element | null;
835
+ renderFilterInfo?: () => JSX_2.Element | null;
835
836
  };
836
837
 
837
838
  export declare type Level = 'database' | 'schema' | 'table';
@@ -10,7 +10,8 @@ import { DropdownItem as DropdownItem_2 } from '../types/dropdown-types';
10
10
  import { FontSpec } from 'chart.js';
11
11
  import { GetDashboardResponse as GetDashboardResponse_2 } from '../types';
12
12
  import { GroupByField as GroupByField_2 } from '../types/explorer-types';
13
- import { JSX as JSX_2 } from 'react/jsx-runtime';
13
+ import { JSX } from 'react/jsx-runtime';
14
+ import { JSX as JSX_2 } from 'react';
14
15
  import { MetricField as MetricField_2 } from '../types/explorer-types';
15
16
  import { PaginationMetadata as PaginationMetadata_2 } from '../types/explorer-types';
16
17
  import { PivotByField as PivotByField_2 } from '../types/explorer-types';
@@ -229,7 +230,7 @@ declare type Actions_3 = TableActions & ExplorerActions & DrillActions & {
229
230
  setOnClose: (onClose: () => void) => void;
230
231
  };
231
232
 
232
- export declare function AdvancedModeToggle({ className, switchClassName, }: AdvancedModeToggleProps): JSX_2.Element | null;
233
+ export declare function AdvancedModeToggle({ className, switchClassName, }: AdvancedModeToggleProps): JSX.Element | null;
233
234
 
234
235
  declare interface AdvancedModeToggleProps {
235
236
  className?: string;
@@ -617,7 +618,7 @@ export declare function Combobox({ name, items, value, onChange, isLoading, isEr
617
618
  refetch: () => void;
618
619
  className?: string;
619
620
  showNone?: boolean;
620
- }): JSX_2.Element;
621
+ }): JSX.Element;
621
622
 
622
623
  declare type ComboBoxOption = {
623
624
  id: number | string;
@@ -677,13 +678,13 @@ export declare function createSqlGenConfig(column: TDataColumn, preSqlGen: SqlGe
677
678
 
678
679
  export declare type CustomCard = CardWithContent | CardWithFooter;
679
680
 
680
- export declare function Dashboard(props: DashboardProps): JSX_2.Element | null;
681
+ export declare function Dashboard(props: DashboardProps): JSX.Element | null;
681
682
 
682
683
  export declare type DashboardEventHandlers = {
683
684
  onExportData?: (payload: ExportDataPayload) => void;
684
685
  };
685
686
 
686
- export declare function DashboardExportDialog({ open, onOpenChange, }: DashboardExportDialogProps): JSX_2.Element;
687
+ export declare function DashboardExportDialog({ open, onOpenChange, }: DashboardExportDialogProps): JSX.Element;
687
688
 
688
689
  declare interface DashboardExportDialogProps {
689
690
  open: boolean;
@@ -1661,7 +1662,7 @@ export declare interface JoinPlan {
1661
1662
  export declare type KPICardProps = {
1662
1663
  card: TCard;
1663
1664
  isLoading?: boolean;
1664
- renderFilterInfo?: () => JSX.Element | null;
1665
+ renderFilterInfo?: () => JSX_2.Element | null;
1665
1666
  };
1666
1667
 
1667
1668
  export declare type Level = 'database' | 'schema' | 'table';
@@ -1932,7 +1933,7 @@ declare interface ResourceListItem {
1932
1933
  };
1933
1934
  }
1934
1935
 
1935
- export declare function ResourceManagementPanel({ isOpen, onClose, className, onDashboardItemClick, variant, }: ResourceManagementPanelProps): JSX_2.Element;
1936
+ export declare function ResourceManagementPanel({ isOpen, onClose, className, onDashboardItemClick, variant, }: ResourceManagementPanelProps): JSX.Element;
1936
1937
 
1937
1938
  declare interface ResourceManagementPanelProps {
1938
1939
  isOpen: boolean;
@@ -1949,7 +1950,7 @@ export declare enum ResourceType {
1949
1950
 
1950
1951
  export declare function ScheduleDashboard({ triggerButtonClassName, }: {
1951
1952
  triggerButtonClassName?: string;
1952
- }): JSX_2.Element | null;
1953
+ }): JSX.Element | null;
1953
1954
 
1954
1955
  export declare type SchemaItem = DropdownItem;
1955
1956
 
@@ -1960,15 +1961,15 @@ export declare type SelectionState = Record<Level, string | null>;
1960
1961
  export declare const SemaphorContextProvider: ({ children, dashboardProps, }: {
1961
1962
  children: React.ReactNode;
1962
1963
  dashboardProps: DashboardProps;
1963
- }) => JSX_2.Element;
1964
+ }) => JSX.Element;
1964
1965
 
1965
1966
  declare function SemaphorQueryClient({ children, }: {
1966
1967
  children: React.ReactNode;
1967
- }): JSX_2.Element;
1968
+ }): JSX.Element;
1968
1969
  export { SemaphorQueryClient as SemaphorDataProvider }
1969
1970
  export { SemaphorQueryClient }
1970
1971
 
1971
- export declare function ShareDialog({ resource, resourceType, onClose, onShareSuccess, onRemoveSuccess, }: ShareDialogProps): JSX_2.Element;
1972
+ export declare function ShareDialog({ resource, resourceType, onClose, onShareSuccess, onRemoveSuccess, }: ShareDialogProps): JSX.Element;
1972
1973
 
1973
1974
  declare interface ShareDialogProps {
1974
1975
  resource: MinimalResourceForSharing;
@@ -2046,7 +2047,7 @@ export declare interface SubtotalConfig {
2046
2047
  pivotBy?: AggregateConfig;
2047
2048
  }
2048
2049
 
2049
- export declare function Surfboard({ showControls, showFooter, ...rest }: DashboardPlusProps): JSX_2.Element;
2050
+ export declare function Surfboard({ showControls, showFooter, ...rest }: DashboardPlusProps): JSX.Element;
2050
2051
 
2051
2052
  declare interface TableActions {
2052
2053
  updateColumnSettingsMap: (columnSettings: ColumnSettingsMap) => void;
@@ -2882,7 +2883,7 @@ export declare type UIConfig = {
2882
2883
  showDashboardAssistant?: boolean;
2883
2884
  };
2884
2885
 
2885
- export declare function UnsavedChangesAlert({ open, onOpenChange, onSave, onDiscard, isSaving, }: UnsavedChangesAlertProps): JSX_2.Element;
2886
+ export declare function UnsavedChangesAlert({ open, onOpenChange, onSave, onDiscard, isSaving, }: UnsavedChangesAlertProps): JSX.Element;
2886
2887
 
2887
2888
  declare type UnsavedChangesAlertProps = {
2888
2889
  open: boolean;
@@ -3081,10 +3082,10 @@ export declare function useTextFilterHook(filterId: string): {
3081
3082
  activeFilterValue: TFilterValue | undefined;
3082
3083
  isSearching: boolean;
3083
3084
  searchError: boolean;
3084
- resultSource: "server" | "local" | "both";
3085
+ resultSource: "server" | "both" | "local";
3085
3086
  };
3086
3087
 
3087
- export declare function Visual(props: VisualProps): JSX_2.Element;
3088
+ export declare function Visual(props: VisualProps): JSX.Element;
3088
3089
 
3089
3090
  /**
3090
3091
  * Display mode for visual components - controls which UI elements are shown
@@ -3122,7 +3123,7 @@ export declare type VisualDisplayPreferences = {
3122
3123
  };
3123
3124
  };
3124
3125
 
3125
- export declare function VisualEditingControls({ className, }: VisualEditingControlsProps): JSX_2.Element;
3126
+ export declare function VisualEditingControls({ className, }: VisualEditingControlsProps): JSX.Element;
3126
3127
 
3127
3128
  declare interface VisualEditingControlsProps {
3128
3129
  className?: string;
@@ -1,6 +1,7 @@
1
1
  import { ColumnSizingState } from '@tanstack/react-table';
2
2
  import { FontSpec } from 'chart.js';
3
- import { JSX as JSX_2 } from 'react/jsx-runtime';
3
+ import { JSX } from 'react/jsx-runtime';
4
+ import { JSX as JSX_2 } from 'react';
4
5
 
5
6
  export declare type AggregateCalc = 'AVG' | 'MIN' | 'MAX' | 'SUM' | 'COUNT' | 'COUNT_DISTINCT';
6
7
 
@@ -834,7 +835,7 @@ declare interface JoinPlan {
834
835
  export declare type KPICardProps = {
835
836
  card: TCard;
836
837
  isLoading?: boolean;
837
- renderFilterInfo?: () => JSX.Element | null;
838
+ renderFilterInfo?: () => JSX_2.Element | null;
838
839
  };
839
840
 
840
841
  export declare type Level = 'database' | 'schema' | 'table';
@@ -1069,7 +1070,7 @@ export declare type StyleProps = {
1069
1070
  };
1070
1071
  };
1071
1072
 
1072
- export declare function Surfboard({ showControls, showFooter, ...rest }: DashboardPlusProps): JSX_2.Element;
1073
+ export declare function Surfboard({ showControls, showFooter, ...rest }: DashboardPlusProps): JSX.Element;
1073
1074
 
1074
1075
  declare type TablePreferences = {
1075
1076
  columnSettingsMap?: ColumnSettingsMap;
@@ -1,5 +1,6 @@
1
1
  import { ColumnSizingState } from '@tanstack/react-table';
2
2
  import { FontSpec } from 'chart.js';
3
+ import { JSX } from 'react';
3
4
 
4
5
  export declare type AggregateCalc = 'AVG' | 'MIN' | 'MAX' | 'SUM' | 'COUNT' | 'COUNT_DISTINCT';
5
6
 
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "email": "support@semaphor.cloud"
6
6
  },
7
7
  "license": "MIT",
8
- "version": "0.1.149",
8
+ "version": "0.1.150",
9
9
  "description": "Fully interactive and customizable dashboards for your apps.",
10
10
  "keywords": [
11
11
  "react",
@@ -149,8 +149,8 @@
149
149
  "@types/node": "^20.14.2",
150
150
  "@types/postcss-prefix-selector": "^1.16.3",
151
151
  "@types/prismjs": "^1.26.3",
152
- "@types/react": "^18.2.43",
153
- "@types/react-dom": "^18.2.17",
152
+ "@types/react": "^19.2.7",
153
+ "@types/react-dom": "^19.2.3",
154
154
  "@types/react-grid-layout": "^1.3.5",
155
155
  "@types/uuid": "^9.0.7",
156
156
  "@typescript-eslint/eslint-plugin": "^6.14.0",
@@ -170,8 +170,8 @@
170
170
  "postcss-prefix-selector": "^2.1.0",
171
171
  "postcss-preset-env": "^10.0.9",
172
172
  "prettier-plugin-tailwindcss": "^0.6.1",
173
- "react": "^18.2.0",
174
- "react-dom": "^18.2.0",
173
+ "react": "^19.2.1",
174
+ "react-dom": "^19.2.1",
175
175
  "rollup-plugin-visualizer": "^5.12.0",
176
176
  "simple-zustand-devtools": "^1.1.0",
177
177
  "tailwindcss": "^3.4.1",