Uniformize folder structure (#693)
* Uniformize folder structure * Fix icons * Fix icons * Fix tests * Fix tests
This commit is contained in:
15
front/src/modules/ui/table/states/selectedRowIdsSelector.ts
Normal file
15
front/src/modules/ui/table/states/selectedRowIdsSelector.ts
Normal file
@ -0,0 +1,15 @@
|
||||
import { selector } from 'recoil';
|
||||
|
||||
import { isRowSelectedFamilyState } from './isRowSelectedFamilyState';
|
||||
import { tableRowIdsState } from './tableRowIdsState';
|
||||
|
||||
export const selectedRowIdsSelector = selector<string[]>({
|
||||
key: 'selectedRowIdsSelector',
|
||||
get: ({ get }) => {
|
||||
const rowIds = get(tableRowIdsState);
|
||||
|
||||
return rowIds.filter(
|
||||
(rowId) => get(isRowSelectedFamilyState(rowId)) === true,
|
||||
);
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user