@burdenoff/microfe-bigconsole 2026.1102.1 → 2026.1103.2

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.
@@ -0,0 +1,15 @@
1
+ import { DataSink, DataSinkSetupState } from '../types';
2
+ /** What is still missing before a data sink counts as set up. */
3
+ export type DataSinkSetupGap = 'data' | 'ttl';
4
+ type SetupInput = Pick<DataSink, 'setupState' | 'ttl' | 'sizeBytes' | 'fluidGridsWorkflowId'>;
5
+ export declare function resolveSetupState(sink: SetupInput): DataSinkSetupState;
6
+ /**
7
+ * The missing pieces behind an incomplete setup; empty once the sink is set up.
8
+ * Also empty while its workflow is running: the workflow is producing the data,
9
+ * so "no data yet" would send the user to fill in what is already on its way.
10
+ */
11
+ export declare function getSetupGaps(sink: SetupInput): DataSinkSetupGap[];
12
+ type Translate = (key: string, fallback: string, params?: Record<string, string | number>) => string;
13
+ /** "Setup incomplete: no data yet, no cache TTL set", or the bare label when no gap is known. */
14
+ export declare function describeSetupGaps(gaps: readonly DataSinkSetupGap[], t: Translate): string;
15
+ export {};
@@ -0,0 +1,23 @@
1
+ import { hasDataSinkPayload as e } from "./dataSinkPayload.js";
2
+ //#region src/bigconsole/utils/dataSinkSetup.ts
3
+ var t = [
4
+ "workflow_pending",
5
+ "workflow_running",
6
+ "workflow_completed",
7
+ "configuration_pending",
8
+ "completed"
9
+ ], n = (e) => typeof e.ttl == "number" && e.ttl > 0;
10
+ function r(r) {
11
+ return t.includes(r.setupState) ? r.setupState : e(r) ? n(r) ? "completed" : "configuration_pending" : r.fluidGridsWorkflowId ? "workflow_running" : "workflow_pending";
12
+ }
13
+ function i(t) {
14
+ let i = r(t);
15
+ if (i === "completed" || i === "workflow_running") return [];
16
+ let a = [];
17
+ return e(t) || a.push("data"), n(t) || a.push("ttl"), a;
18
+ }
19
+ function a(e, t) {
20
+ return e.length === 0 ? t("bigconsole.dataSinks.setup.incomplete", "Setup incomplete") : t("bigconsole.dataSinks.setup.incompleteWithGaps", "Setup incomplete: {{gaps}}", { gaps: e.map((e) => e === "data" ? t("bigconsole.dataSinks.setup.gapData", "no data yet") : t("bigconsole.dataSinks.setup.gapTtl", "no cache TTL set")).join(", ") });
21
+ }
22
+ //#endregion
23
+ export { a as describeSetupGaps, i as getSetupGaps, r as resolveSetupState };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@burdenoff/microfe-bigconsole",
3
- "version": "2026.1102.1",
3
+ "version": "2026.1103.2",
4
4
  "description": "BigConsole - AI-powered analytics and dashboard platform",
5
5
  "type": "module",
6
6
  "files": [