Skip to content

Commit

Permalink
Merge pull request #56792 from FitseTLT/fix-previous-category-and-key…
Browse files Browse the repository at this point in the history
…board-briefly-shown-bug

Fix - Android - Categories - Previously selected category and keypad is shown briefly
  • Loading branch information
srikarparsi authored Feb 16, 2025
2 parents d68deae + dfe9c4a commit ee29bcc
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, {useMemo, useState} from 'react';
import {View} from 'react-native';
import {InteractionManager, Keyboard, View} from 'react-native';
import {useOnyx} from 'react-native-onyx';
import CategorySelectorModal from '@components/CategorySelector/CategorySelectorModal';
import HeaderWithBackButton from '@components/HeaderWithBackButton';
Expand Down Expand Up @@ -82,7 +82,11 @@ function WorkspaceCategoriesSettingsPage({policy, route}: WorkspaceCategoriesSet
if (categoryID !== selectedCategory.keyForList) {
setWorkspaceDefaultSpendCategory(policyID, groupID, selectedCategory.keyForList);
}
setIsSelectorModalVisible(false);

Keyboard.dismiss();
InteractionManager.runAfterInteractions(() => {
setIsSelectorModalVisible(false);
});
};

return (
Expand Down

0 comments on commit ee29bcc

Please sign in to comment.