fix(Sidebar): scroll to top once the sidebar be closed.

This commit is contained in:
a.bouhuolia
2021-03-21 13:38:10 +02:00
parent 81621020c2
commit 0f1c88cba3
5 changed files with 43 additions and 20 deletions

View File

@@ -29,7 +29,7 @@ function InvoiceFormProvider({ invoiceId, ...props }) {
// Fetches the estimate by the given id.
const {
data: estimate,
isFetching: isEstimateFetching,
isLoading: isEstimateLoading,
} = useEstimate(estimateId, { enabled: !!estimateId });
const newInvoice = !isEmpty(estimate)
@@ -97,7 +97,7 @@ function InvoiceFormProvider({ invoiceId, ...props }) {
isInvoiceLoading ||
isItemsLoading ||
isCustomersLoading ||
isEstimateFetching ||
isEstimateLoading ||
isSettingsLoading
}
name={'invoice-form'}