@trustgraph/react-state 1.4.4 → 1.4.6

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/index.cjs CHANGED
@@ -2120,16 +2120,7 @@ const useStructuredQuery = () => {
2120
2120
  : err?.toString() || "Unknown error";
2121
2121
  notify.error(`Structured query failed: ${errorMessage}`);
2122
2122
  },
2123
- onSuccess: (data) => {
2124
- if (data.data) {
2125
- notify.success("Structured query executed successfully");
2126
- }
2127
- else if (data.errors && data.errors.length > 0) {
2128
- notify.warning("Query executed with errors");
2129
- }
2130
- else {
2131
- notify.warning("Query processed but returned no data");
2132
- }
2123
+ onSuccess: () => {
2133
2124
  },
2134
2125
  });
2135
2126
  // Show loading indicator for structured query operations
@@ -2180,14 +2171,7 @@ const useRowEmbeddingsQuery = ({ flow } = {}) => {
2180
2171
  const message = err instanceof Error ? err.message : String(err);
2181
2172
  notify.error(`Row embeddings query failed: ${message}`);
2182
2173
  },
2183
- onSuccess: (data) => {
2184
- const count = data?.length ?? 0;
2185
- if (count > 0) {
2186
- notify.success(`Found ${count} matching record${count !== 1 ? "s" : ""}`);
2187
- }
2188
- else {
2189
- notify.info("No matching records found");
2190
- }
2174
+ onSuccess: () => {
2191
2175
  },
2192
2176
  });
2193
2177
  useActivity(mutation.isPending, "Querying row embeddings");
@@ -2228,14 +2212,7 @@ const useDocumentEmbeddingsQuery = ({ flow } = {}) => {
2228
2212
  const message = err instanceof Error ? err.message : String(err);
2229
2213
  notify.error(`Document embeddings query failed: ${message}`);
2230
2214
  },
2231
- onSuccess: (data) => {
2232
- const count = Array.isArray(data) ? data.length : 0;
2233
- if (count > 0) {
2234
- notify.success(`Found ${count} matching chunk${count !== 1 ? "s" : ""}`);
2235
- }
2236
- else {
2237
- notify.info("No matching document chunks found");
2238
- }
2215
+ onSuccess: () => {
2239
2216
  },
2240
2217
  });
2241
2218
  useActivity(mutation.isPending, "Searching document chunks");
@@ -2287,7 +2264,6 @@ const useRowsQuery = ({ flow } = {}) => {
2287
2264
  notify.error(`GraphQL query failed: ${errorMessage}`);
2288
2265
  },
2289
2266
  onSuccess: () => {
2290
- notify.success("GraphQL query executed successfully");
2291
2267
  },
2292
2268
  });
2293
2269
  // Show loading indicator for query operations
@@ -2501,13 +2477,7 @@ const useNlpQuery = ({ flow } = {}) => {
2501
2477
  const errorMessage = err instanceof Error ? err.message : String(err);
2502
2478
  notify.error(`NLP query conversion failed: ${errorMessage}`);
2503
2479
  },
2504
- onSuccess: (data) => {
2505
- if (data.graphql_query) {
2506
- notify.success("Natural language converted to GraphQL successfully");
2507
- }
2508
- else {
2509
- notify.warning("Query processed but no GraphQL generated");
2510
- }
2480
+ onSuccess: () => {
2511
2481
  },
2512
2482
  });
2513
2483
  // Show loading indicator for conversion operations
@@ -3505,8 +3475,6 @@ const useKnowledgeCores = () => {
3505
3475
  notify.error(err.toString());
3506
3476
  },
3507
3477
  onSuccess: () => {
3508
- // Show success notification
3509
- notify.success("Knowledge cores loaded successfully");
3510
3478
  },
3511
3479
  });
3512
3480
  // Show loading indicators for long-running operations