@mastra/react 1.13.0-alpha.4 → 1.13.0-alpha.5

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,17 @@
1
+ import type { AggregateTracesArgs, AggregateTracesResponse } from '@mastra/client-js';
2
+ import type { UseQueryResult } from '@tanstack/react-query';
3
+ import type { MastraQueryOptions } from '../shared/query-options.js';
4
+ export interface UseTraceAggregateArgs<TData = AggregateTracesResponse> {
5
+ request: AggregateTracesArgs;
6
+ enabled?: boolean;
7
+ queryOptions?: MastraQueryOptions<AggregateTracesResponse, TData>;
8
+ }
9
+ /**
10
+ * Runs `aggregateTraces()` for `request`. Check `useTraceAggregateAvailable()` before enabling it.
11
+ *
12
+ * It doesn't poll: grouped requests over large tenants take seconds, so it refetches only when the
13
+ * request changes or the caller calls `refetch()`. The client already retries server errors, so
14
+ * React Query doesn't retry on top of it, and a rejected request (4xx) fails once.
15
+ */
16
+ export declare function useTraceAggregate<TData = AggregateTracesResponse>({ request, enabled, queryOptions, }: UseTraceAggregateArgs<TData>): UseQueryResult<TData, Error>;
17
+ //# sourceMappingURL=use-trace-aggregate.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-trace-aggregate.d.ts","sourceRoot":"","sources":["../../../src/hooks/traces/use-trace-aggregate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,uBAAuB,EAAE,MAAM,mBAAmB,CAAC;AAEtF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAElE,MAAM,WAAW,qBAAqB,CAAC,KAAK,GAAG,uBAAuB;IACpE,OAAO,EAAE,mBAAmB,CAAC;IAC7B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,YAAY,CAAC,EAAE,kBAAkB,CAAC,uBAAuB,EAAE,KAAK,CAAC,CAAC;CACnE;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,GAAG,uBAAuB,EAAE,EACjE,OAAO,EACP,OAAc,EACd,YAAY,GACb,EAAE,qBAAqB,CAAC,KAAK,CAAC,GAAG,cAAc,CAAC,KAAK,EAAE,KAAK,CAAC,CAU7D"}
@@ -1,6 +1,8 @@
1
+ export type TraceColumnPreferencesScope = 'traces' | 'spans';
1
2
  /**
2
3
  * Storage key for the trace list column preferences, scoped to the Mastra server the client
3
- * talks to so each project keeps its own column layout.
4
+ * talks to so each project keeps its own column layout, and to the list (traces or spans)
5
+ * so each list keeps its own selection.
4
6
  */
5
- export declare function useTraceColumnPreferencesStorageKey(): string;
7
+ export declare function useTraceColumnPreferencesStorageKey(scope?: TraceColumnPreferencesScope): string;
6
8
  //# sourceMappingURL=use-trace-column-preferences-storage-key.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"use-trace-column-preferences-storage-key.d.ts","sourceRoot":"","sources":["../../../src/hooks/traces/use-trace-column-preferences-storage-key.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,wBAAgB,mCAAmC,IAAI,MAAM,CAM5D"}
1
+ {"version":3,"file":"use-trace-column-preferences-storage-key.d.ts","sourceRoot":"","sources":["../../../src/hooks/traces/use-trace-column-preferences-storage-key.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,2BAA2B,GAAG,QAAQ,GAAG,OAAO,CAAC;AAE7D;;;;GAIG;AACH,wBAAgB,mCAAmC,CAAC,KAAK,GAAE,2BAAsC,GAAG,MAAM,CAMzG"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mastra/react",
3
- "version": "1.13.0-alpha.4",
3
+ "version": "1.13.0-alpha.5",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/mastra-ai/mastra.git",
@@ -69,7 +69,7 @@
69
69
  "lucide-react": "^1.61.0",
70
70
  "shiki": "^1.29.2",
71
71
  "tailwind-merge": "^3.7.0",
72
- "@mastra/client-js": "1.57.0-alpha.4"
72
+ "@mastra/client-js": "1.57.0-alpha.5"
73
73
  },
74
74
  "peerDependencies": {
75
75
  "@mastra/core": ">=1.67.0-0 <2.0.0-0",
@@ -100,9 +100,9 @@
100
100
  "vite": "^8.3.5",
101
101
  "vitest": "4.1.12",
102
102
  "zod": "^3.25.76",
103
+ "@mastra/core": "1.80.0-alpha.5",
103
104
  "@internal/lint": "0.0.145",
104
- "@internal/types-builder": "0.0.120",
105
- "@mastra/core": "1.80.0-alpha.4"
105
+ "@internal/types-builder": "0.0.120"
106
106
  },
107
107
  "engines": {
108
108
  "node": ">=22.13.0"