@bluemarble/bm-components 1.11.4 → 1.12.0

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.d.mts CHANGED
@@ -237,7 +237,6 @@ interface UseGridProps$1<T> {
237
237
  }
238
238
  declare function useGrid<T extends Record<string, any>>({ columns, filters, search, rowsPerPageOptions, defaultData: externalDefaultData, defaultCurrentPage, defaultSortedBy }: UseGridProps$1<T>): {
239
239
  data: T[];
240
- updatedTimes: number;
241
240
  set: (data: T[]) => void;
242
241
  onSortBy: (prop: string) => void;
243
242
  sortedBy: SortedByProps$1[];
package/dist/index.d.ts CHANGED
@@ -237,7 +237,6 @@ interface UseGridProps$1<T> {
237
237
  }
238
238
  declare function useGrid<T extends Record<string, any>>({ columns, filters, search, rowsPerPageOptions, defaultData: externalDefaultData, defaultCurrentPage, defaultSortedBy }: UseGridProps$1<T>): {
239
239
  data: T[];
240
- updatedTimes: number;
241
240
  set: (data: T[]) => void;
242
241
  onSortBy: (prop: string) => void;
243
242
  sortedBy: SortedByProps$1[];
package/dist/index.js CHANGED
@@ -4094,7 +4094,7 @@ var ApiHelper = class _ApiHelper {
4094
4094
  return __async(this, null, function* () {
4095
4095
  });
4096
4096
  }
4097
- onError(req, res) {
4097
+ onError(req, res, error) {
4098
4098
  return __async(this, null, function* () {
4099
4099
  });
4100
4100
  }
@@ -4135,9 +4135,9 @@ var ApiHelper = class _ApiHelper {
4135
4135
  error: "Erro interno do servidor",
4136
4136
  details: error
4137
4137
  });
4138
- return this.onError(req, res);
4138
+ return this.onError(req, res, error);
4139
4139
  }
4140
- this.onError(req, res);
4140
+ this.onError(req, res, error);
4141
4141
  throw new Error(error);
4142
4142
  } finally {
4143
4143
  yield this.onFinally(req, res);
@@ -4788,7 +4788,6 @@ function useGrid({
4788
4788
  );
4789
4789
  const [currentPage, setCurrentPage] = _react.useState.call(void 0, defaultCurrentPage || 0);
4790
4790
  const [rowsPerPage, setRowsPerPage] = _react.useState.call(void 0, rowsPerPageOptions[0]);
4791
- const [updatedTimes, setUpdatedTimes] = _react.useState.call(void 0, 0);
4792
4791
  const toggleSortedDirection = _react.useCallback.call(void 0,
4793
4792
  (direction) => {
4794
4793
  if (direction === "asc")
@@ -4885,12 +4884,8 @@ function useGrid({
4885
4884
  if (externalDefaultData)
4886
4885
  setDefaultData(externalDefaultData);
4887
4886
  }, [externalDefaultData]);
4888
- _react.useEffect.call(void 0, () => {
4889
- setUpdatedTimes((prev) => prev + 1);
4890
- }, [displayData]);
4891
4887
  return {
4892
4888
  data: displayData,
4893
- updatedTimes,
4894
4889
  set,
4895
4890
  onSortBy,
4896
4891
  sortedBy,