feat: stop pagination before emitting list settings

This commit is contained in:
karishmas6
2024-09-05 22:44:59 +05:30
parent 9124ca0ab0
commit 6d6b37f1b6

View File

@@ -26,7 +26,7 @@ export const RightSidePanel = () => {
const [selectedPaginationSetting, setSelectedPaginationSetting] = useState<string | null>(null);
const { lastAction, notify } = useGlobalInfoStore();
const { getText, startGetText, stopGetText, getScreenshot, startGetScreenshot, stopGetScreenshot, paginationMode, getList, startGetList, stopGetList, startPaginationMode } = useActionContext();
const { getText, startGetText, stopGetText, getScreenshot, startGetScreenshot, stopGetScreenshot, paginationMode, getList, startGetList, stopGetList, startPaginationMode, stopPaginationMode } = useActionContext();
const { browserSteps, updateBrowserTextStepLabel, deleteBrowserStep, addScreenshotStep } = useBrowserSteps();
const { socket } = useSocketStore();
@@ -132,6 +132,7 @@ export const RightSidePanel = () => {
}, [stopGetList, resetListState]);
const stopCaptureAndEmitGetListSettings = useCallback(() => {
stopPaginationMode();
stopGetList();
const settings = getListSettingsObject();
if (settings) {