@trustgraph/react-state 1.4.5 → 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.esm.js CHANGED
@@ -2119,16 +2119,7 @@ const useStructuredQuery = () => {
2119
2119
  : err?.toString() || "Unknown error";
2120
2120
  notify.error(`Structured query failed: ${errorMessage}`);
2121
2121
  },
2122
- onSuccess: (data) => {
2123
- if (data.data) {
2124
- notify.success("Structured query executed successfully");
2125
- }
2126
- else if (data.errors && data.errors.length > 0) {
2127
- notify.warning("Query executed with errors");
2128
- }
2129
- else {
2130
- notify.warning("Query processed but returned no data");
2131
- }
2122
+ onSuccess: () => {
2132
2123
  },
2133
2124
  });
2134
2125
  // Show loading indicator for structured query operations
@@ -2220,14 +2211,7 @@ const useDocumentEmbeddingsQuery = ({ flow } = {}) => {
2220
2211
  const message = err instanceof Error ? err.message : String(err);
2221
2212
  notify.error(`Document embeddings query failed: ${message}`);
2222
2213
  },
2223
- onSuccess: (data) => {
2224
- const count = Array.isArray(data) ? data.length : 0;
2225
- if (count > 0) {
2226
- notify.success(`Found ${count} matching chunk${count !== 1 ? "s" : ""}`);
2227
- }
2228
- else {
2229
- notify.info("No matching document chunks found");
2230
- }
2214
+ onSuccess: () => {
2231
2215
  },
2232
2216
  });
2233
2217
  useActivity(mutation.isPending, "Searching document chunks");
@@ -2492,13 +2476,7 @@ const useNlpQuery = ({ flow } = {}) => {
2492
2476
  const errorMessage = err instanceof Error ? err.message : String(err);
2493
2477
  notify.error(`NLP query conversion failed: ${errorMessage}`);
2494
2478
  },
2495
- onSuccess: (data) => {
2496
- if (data.graphql_query) {
2497
- notify.success("Natural language converted to GraphQL successfully");
2498
- }
2499
- else {
2500
- notify.warning("Query processed but no GraphQL generated");
2501
- }
2479
+ onSuccess: () => {
2502
2480
  },
2503
2481
  });
2504
2482
  // Show loading indicator for conversion operations
@@ -3496,8 +3474,6 @@ const useKnowledgeCores = () => {
3496
3474
  notify.error(err.toString());
3497
3475
  },
3498
3476
  onSuccess: () => {
3499
- // Show success notification
3500
- notify.success("Knowledge cores loaded successfully");
3501
3477
  },
3502
3478
  });
3503
3479
  // Show loading indicators for long-running operations