"fix" BulkDeleteProvisionedResource tests
This commit is contained in:
+5
-1
@@ -1,4 +1,5 @@
|
||||
import { useCallback, useState } from 'react';
|
||||
import { flushSync } from 'react-dom';
|
||||
import { FormProvider, useForm } from 'react-hook-form';
|
||||
|
||||
import { AppEvents } from '@grafana/data';
|
||||
@@ -43,7 +44,10 @@ function FormContent({ initialValues, selectedItems, repository, workflowOptions
|
||||
const workflow = watch('workflow');
|
||||
|
||||
const handleSubmitForm = async (data: BulkActionFormData) => {
|
||||
setHasSubmitted(true);
|
||||
// TODO why?
|
||||
flushSync(() => {
|
||||
setHasSubmitted(true);
|
||||
});
|
||||
|
||||
const resources = collectSelectedItems(selectedItems);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user