Reorganize context/states/selectors in dedicated folders (#1205)
* Reorganize context/states/selectors in dedicated folders * linter
This commit is contained in:
@ -1,5 +0,0 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
import { HotkeyScope } from '@/ui/utilities/hotkey/types/HotkeyScope';
|
||||
|
||||
export const CellHotkeyScopeContext = createContext<HotkeyScope | null>(null);
|
||||
@ -1,3 +0,0 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
export const ColumnIndexContext = createContext<number>(0);
|
||||
@ -1,3 +0,0 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
export const EntityUpdateMutationContext = createContext<any | null>(null);
|
||||
@ -1,3 +0,0 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
export const RowIdContext = createContext<string | null>(null);
|
||||
@ -1,3 +0,0 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
export const RowIndexContext = createContext<number>(0);
|
||||
@ -1,3 +0,0 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
export const TableContext = createContext<string | null>(null);
|
||||
@ -1,9 +0,0 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
import {
|
||||
ViewFieldDefinition,
|
||||
ViewFieldMetadata,
|
||||
} from '../../editable-field/types/ViewField';
|
||||
|
||||
export const ViewFieldContext =
|
||||
createContext<ViewFieldDefinition<ViewFieldMetadata> | null>(null);
|
||||
@ -0,0 +1,3 @@
|
||||
import { createContext } from 'react';
|
||||
|
||||
export const TableRecoilScopeContext = createContext<string | null>(null);
|
||||
@ -1,8 +1,8 @@
|
||||
import { selector } from 'recoil';
|
||||
|
||||
import { AllRowsSelectedStatus } from '../types/AllRowSelectedStatus';
|
||||
import { AllRowsSelectedStatus } from '../../types/AllRowSelectedStatus';
|
||||
import { numberOfTableRowsState } from '../numberOfTableRowsState';
|
||||
|
||||
import { numberOfTableRowsState } from './numberOfTableRowsState';
|
||||
import { selectedRowIdsSelector } from './selectedRowIdsSelector';
|
||||
|
||||
export const allRowsSelectedStatusSelector = selector<AllRowsSelectedStatus>({
|
||||
@ -1,7 +1,7 @@
|
||||
import { selector } from 'recoil';
|
||||
|
||||
import { isRowSelectedFamilyState } from './isRowSelectedFamilyState';
|
||||
import { tableRowIdsState } from './tableRowIdsState';
|
||||
import { isRowSelectedFamilyState } from '../isRowSelectedFamilyState';
|
||||
import { tableRowIdsState } from '../tableRowIdsState';
|
||||
|
||||
export const selectedRowIdsSelector = selector<string[]>({
|
||||
key: 'selectedRowIdsSelector',
|
||||
@ -1,6 +1,6 @@
|
||||
import { selectorFamily } from 'recoil';
|
||||
|
||||
import { tableEntitiesFamilyState } from './tableEntitiesFamilyState';
|
||||
import { tableEntitiesFamilyState } from '../tableEntitiesFamilyState';
|
||||
|
||||
export const tableEntityFieldFamilySelector = selectorFamily({
|
||||
key: 'tableEntityFieldFamilySelector',
|
||||
Reference in New Issue
Block a user