[Glitch] Convert dropdown_menu state to Typescript

Port 4b7bc1f07c to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
Renaud Chaput
2023-09-22 18:18:46 +02:00
committed by Claire
parent b2d67fbe33
commit 919ed0e469
9 changed files with 69 additions and 41 deletions

View File

@@ -23,9 +23,14 @@ const MOUSE_IDLE_DELAY = 300;
const listenerOptions = supportsPassiveEvents ? { passive: true } : false;
/**
*
* @param {import('flavours/glitch/store').RootState} state
* @param {*} props
*/
const mapStateToProps = (state, { scrollKey }) => {
return {
preventScroll: scrollKey === state.getIn(['dropdown_menu', 'scroll_key']),
preventScroll: scrollKey === state.dropdownMenu.scrollKey,
};
};