Feat/open input not focus (#811)
* Fixed click outside * Finished * Fixed tests
This commit is contained in:
@ -1,7 +1,6 @@
|
||||
import { PropsWithChildren } from 'react';
|
||||
|
||||
import { useScopedHotkeys } from '@/ui/hotkey/hooks/useScopedHotkeys';
|
||||
import { HotkeyScope } from '@/ui/hotkey/types/HotkeyScope';
|
||||
import { isNonTextWritingKey } from '@/ui/hotkey/utils/isNonTextWritingKey';
|
||||
|
||||
import { TableHotkeyScope } from '../../types/TableHotkeyScope';
|
||||
@ -9,22 +8,13 @@ import { useEditableCell } from '../hooks/useEditableCell';
|
||||
|
||||
import { EditableCellDisplayContainer } from './EditableCellContainer';
|
||||
|
||||
type OwnProps = PropsWithChildren<{
|
||||
editHotkeyScope?: HotkeyScope;
|
||||
}>;
|
||||
type OwnProps = PropsWithChildren<unknown>;
|
||||
|
||||
export function EditableCellSoftFocusMode({
|
||||
children,
|
||||
editHotkeyScope,
|
||||
}: OwnProps) {
|
||||
export function EditableCellSoftFocusMode({ children }: OwnProps) {
|
||||
const { openEditableCell } = useEditableCell();
|
||||
|
||||
function openEditMode() {
|
||||
openEditableCell(
|
||||
editHotkeyScope ?? {
|
||||
scope: TableHotkeyScope.CellEditMode,
|
||||
},
|
||||
);
|
||||
openEditableCell();
|
||||
}
|
||||
|
||||
useScopedHotkeys(
|
||||
|
||||
Reference in New Issue
Block a user