semaphor 0.0.76 → 0.0.77
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{dashboard-plus-bg-mRdBZ.js → dashboard-plus-5B6hJeBZ.js} +1059 -1055
- package/dist/chunks/dashboard-plus-z4fkzB_M.js +240 -0
- package/dist/chunks/{index-3mJ0FTjs.js → index-L--hgWeJ.js} +54 -54
- package/dist/chunks/{index-CbTZvlIM.js → index-MEy4VWWZ.js} +2850 -2847
- package/dist/chunks/{lucide-react-QDPFc4hG.js → lucide-react-92VWJiwP.js} +1 -1
- package/dist/chunks/{lucide-react-te4lV1WE.js → lucide-react-OlWvERU9.js} +3 -3
- package/dist/dashboard/index.cjs +1 -1
- package/dist/dashboard/index.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +4 -4
- package/dist/surfboard/index.cjs +1 -1
- package/dist/surfboard/index.js +2 -2
- package/dist/types/main.d.ts +0 -2
- package/package.json +1 -1
- package/dist/chunks/dashboard-plus-AK0BZVwp.js +0 -240
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-L--hgWeJ.js"),a=require("./dashboard-plus-z4fkzB_M.js");require("react");require("react-dom");/**
|
|
2
2
|
* @license lucide-react v0.453.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { J as a, ao as e, am as t, aF as c, bT as h, bU as d, bV as o, bk as y, bW as i, bX as s, a7 as n, bY as r, bZ as k, b_ as p, b$ as l, Q as M, c0 as u, c1 as v, b1 as g, ah as m, c2 as x, bf as L } from "./index-
|
|
2
|
-
import { c3 as Pv } from "./index-
|
|
3
|
-
import { B as w, C, a as f, b as I, d as S, e as q, f as b, h as H, i as A, j as z, E as P, k as V, l as j, m as B, G as F, H as D, n as R, o as T, K as U, p as O, q as Z, r as G, L as W, M as E, N as X, P as N, s as K, t as J, v as Q, w as Y, x as _, y as $, z as a1, T as e1, A as t1, F as c1, U as h1 } from "./dashboard-plus-
|
|
1
|
+
import { J as a, ao as e, am as t, aF as c, bT as h, bU as d, bV as o, bk as y, bW as i, bX as s, a7 as n, bY as r, bZ as k, b_ as p, b$ as l, Q as M, c0 as u, c1 as v, b1 as g, ah as m, c2 as x, bf as L } from "./index-MEy4VWWZ.js";
|
|
2
|
+
import { c3 as Pv } from "./index-MEy4VWWZ.js";
|
|
3
|
+
import { B as w, C, a as f, b as I, d as S, e as q, f as b, h as H, i as A, j as z, E as P, k as V, l as j, m as B, G as F, H as D, n as R, o as T, K as U, p as O, q as Z, r as G, L as W, M as E, N as X, P as N, s as K, t as J, v as Q, w as Y, x as _, y as $, z as a1, T as e1, A as t1, F as c1, U as h1 } from "./dashboard-plus-5B6hJeBZ.js";
|
|
4
4
|
import "react";
|
|
5
5
|
import "react-dom";
|
|
6
6
|
/**
|
package/dist/dashboard/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/index-L--hgWeJ.js");require("react");require("react-dom");exports.Dashboard=e.Dashboard;
|
package/dist/dashboard/index.js
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./chunks/index-L--hgWeJ.js"),n=require("./chunks/dashboard-plus-z4fkzB_M.js"),_=require("react");require("react-dom");function v({card:t,footer:u,className:h,...m}){var c;const{customCards:o}=e.useSemaphorContext(),p=_.useRef(null),{isError:C,isLoading:i,isFetching:a,cfg:x,visualKey:f,handleDatapointClick:E}=e.useDashboardCard(t),l=e.useDashboardStore(s=>s.themeStyle),d=e.useDashboardStore(s=>s.selectedSheetId),j=e.useDashboardStore(s=>s.selectedCardId),D=e.useDashboardStore(s=>s.isDashboardEditing),g=((c=t.customCardPreferences)==null?void 0:c.showCardHeader)??!0,{setCardTitle:b,setCardDescription:S,setSelectedCardId:T}=e.useDashboardActions();function R(s){s.stopPropagation(),T(d,t.id)}function A(){if(o&&o.length>0){const s=o.find(r=>r.cardId===t.id);if(s&&s.replaceDefault){const r=s.content;if(r)return e.jsxRuntimeExports.jsx(r,{card:t})}}return t.type==="kpi"?t.data&&t.data.length>0&&e.jsxRuntimeExports.jsx(e.KPICard,{isLoading:i||a,card:t}):N}function y(){if(C)return e.jsxRuntimeExports.jsx("p",{className:"text-sm",children:"Oops! It seems like something went wrong. Please review your connection or filters."});if(t.type==="table"&&t.data&&t.data.length>0)return e.jsxRuntimeExports.jsxs(e.ScrollArea,{children:[e.jsxRuntimeExports.jsx(e.TableVisual,{card:t,data:t.data}),e.jsxRuntimeExports.jsx(e.ScrollBar,{orientation:"horizontal"})]});if(o&&o.length>0){const s=o.find(r=>r.cardId===t.id);if(s&&s.content){const r=s.content;return e.jsxRuntimeExports.jsx(r,{card:t})}}if(x)return e.jsxRuntimeExports.jsx(e.ChartJsVisual,{cfg:x,onDatapointClick:E},f)}function I(){if(o&&o.length>0){const s=o.find(r=>r.cardId===t.id);if(s&&s.footer){const r=s.footer;if(r)return e.jsxRuntimeExports.jsx(r,{card:t})}}return u||null}if(!t.id)return null;const N=e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[g&&e.jsxRuntimeExports.jsxs(e.CardHeader,{className:"pb-4",children:[e.jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxRuntimeExports.jsx(e.Editable,{text:t.title,onSave:s=>b(d,t.id,s),children:e.jsxRuntimeExports.jsx(e.CardTitle,{className:"text-base",children:t.title})}),t.refreshInterval&&e.jsxRuntimeExports.jsxs(e.Tooltip,{children:[e.jsxRuntimeExports.jsx(e.TooltipTrigger,{className:"pr-1",children:e.jsxRuntimeExports.jsx("div",{className:e.cn("h-2 w-2 rounded-full bg-green-500 transition-opacity",{"opacity-10":i||a})})}),e.jsxRuntimeExports.jsx(e.TooltipContent,{side:"right",align:"center",children:e.jsxRuntimeExports.jsx("p",{className:"text-xs",children:`Realtime (${t==null?void 0:t.refreshInterval})`})})]}),!t.refreshInterval&&(i||a)&&e.jsxRuntimeExports.jsx(n.LoaderCircle,{className:"h-4 w-4 animate-spin text-muted-foreground"})]}),e.jsxRuntimeExports.jsx(e.Editable,{text:(t==null?void 0:t.description)||"",onSave:s=>S(d,t.id,s),children:e.jsxRuntimeExports.jsxs(e.CardDescription,{children:[" ",t.description]})})]}),e.jsxRuntimeExports.jsx(e.CardContent,{className:"relative flex grow flex-col overflow-auto pb-0",children:y()}),e.jsxRuntimeExports.jsx(e.CardFooter,{children:I()})]});return e.jsxRuntimeExports.jsx(e.Card,{tabIndex:-1,ref:p,role:"dashboard-card",onClick:R,className:e.cn("relative flex h-full flex-col rounded-sm",{"border-dashed border-foreground/50":j===t.id&&D},l==null?void 0:l.dashboardCard,h),...m,children:A()})}exports.BOOLEAN_DATA_TYPES=e.BOOLEAN_DATA_TYPES;exports.DATE_DATA_TYPES=e.DATE_DATA_TYPES;exports.Dashboard=e.Dashboard;exports.DashboardWC=e.DashboardWC;exports.NUMBER_DATA_TYPES=e.NUMBER_DATA_TYPES;exports.SemaphorQueryClient=e.SemaphorQueryClient;exports.TEXT_DATA_TYPES=e.TEXT_DATA_TYPES;exports.createSqlGenConfig=e.createSqlGenConfig;exports.fmt=e.fmt;exports.getColumnDataType=e.getColumnDataType;exports.getFilterValueType=e.getFilterValueType;exports.getQualifiedTableName=e.getQualifiedTableName;exports.getSql=e.getSql;exports.isColumnInSqlGen=e.isColumnInSqlGen;exports.resolveDataType=e.resolveDataType;exports.useCard=e.useCard;exports.useDashboardActions=e.useDashboardActions;exports.useDashboardStore=e.useDashboardStore;exports.useEditorActions=e.useEditorActions;exports.useEditorStore=e.useEditorStore;exports.SelectComponent=n.SelectComponent;exports.Surfboard=n.DashboardPlus;exports.cleanCard=n.cleanCard;exports.getDashbaordStateWithoutData=n.getDashbaordStateWithoutData;exports.useEditorAside=n.useEditorAside;exports.DashboardCard=v;
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { u as P, a as F, b as o, c as k, j as s, C as R, E as h, d as L, T as q, e as B, f as C, g as H, h as Y, i as G, k as K, l as O, K as V, S as z, m as Q, n as W, o as J } from "./chunks/index-
|
|
2
|
-
import { B as re, s as oe, D as ne, q as ie, N as le, I as de, r as ue, w as ce, t as fe, y as he, x as Ce, A as me, v as xe, z as pe, F as ge, p as je, H as De, G as be } from "./chunks/index-
|
|
3
|
-
import { L as M } from "./chunks/dashboard-plus-
|
|
4
|
-
import { S as Te, D as Ee, c as Ie, g as Ae, u as ve } from "./chunks/dashboard-plus-
|
|
1
|
+
import { u as P, a as F, b as o, c as k, j as s, C as R, E as h, d as L, T as q, e as B, f as C, g as H, h as Y, i as G, k as K, l as O, K as V, S as z, m as Q, n as W, o as J } from "./chunks/index-MEy4VWWZ.js";
|
|
2
|
+
import { B as re, s as oe, D as ne, q as ie, N as le, I as de, r as ue, w as ce, t as fe, y as he, x as Ce, A as me, v as xe, z as pe, F as ge, p as je, H as De, G as be } from "./chunks/index-MEy4VWWZ.js";
|
|
3
|
+
import { L as M } from "./chunks/dashboard-plus-5B6hJeBZ.js";
|
|
4
|
+
import { S as Te, D as Ee, c as Ie, g as Ae, u as ve } from "./chunks/dashboard-plus-5B6hJeBZ.js";
|
|
5
5
|
import U from "react";
|
|
6
6
|
import "react-dom";
|
|
7
7
|
function se({
|
package/dist/surfboard/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../chunks/dashboard-plus-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../chunks/dashboard-plus-z4fkzB_M.js");require("../chunks/index-L--hgWeJ.js");require("react");require("react-dom");exports.Surfboard=r.DashboardPlus;
|
package/dist/surfboard/index.js
CHANGED
package/dist/types/main.d.ts
CHANGED
|
@@ -81,7 +81,6 @@ declare type Actions = {
|
|
|
81
81
|
getCardSheet: (cardId: string) => TSheet | undefined;
|
|
82
82
|
getSelectedSheetLayout: () => ReactGridLayout_2.Layout[] | undefined;
|
|
83
83
|
getSelectedSheetLayouts: () => ReactGridLayout_2.Layouts | undefined;
|
|
84
|
-
getSheetFilterValues: (sheetId: string) => TFilterValue[] | undefined;
|
|
85
84
|
handleDataPointClickAction: (card: TCard, dataPoint: any) => void;
|
|
86
85
|
addBaseQuery: (baseQuery: TBaseQuery) => void;
|
|
87
86
|
removeBaseQuery: (baseQueryId: string) => void;
|
|
@@ -1842,7 +1841,6 @@ export declare const useDashboardStore: UseBoundStore<Omit<StoreApi<DashboardSto
|
|
|
1842
1841
|
getCardSheet: (cardId: string) => TSheet | undefined;
|
|
1843
1842
|
getSelectedSheetLayout: () => ReactGridLayout_2.Layout[] | undefined;
|
|
1844
1843
|
getSelectedSheetLayouts: () => ReactGridLayout_2.Layouts | undefined;
|
|
1845
|
-
getSheetFilterValues: (sheetId: string) => TFilterValue[] | undefined;
|
|
1846
1844
|
handleDataPointClickAction: (card: TCard, dataPoint: any) => void;
|
|
1847
1845
|
addBaseQuery: (baseQuery: TBaseQuery) => void;
|
|
1848
1846
|
removeBaseQuery: (baseQueryId: string) => void;
|