fix: build lint error

This commit is contained in:
DiamondThree 2023-01-08 19:37:15 +08:00
parent 231615b134
commit 090890a94d

View File

@ -4,6 +4,7 @@ import { Button } from '@/ui/button';
import { useState } from 'react';
import Input from '@/ui/input';
import { useTemporaryHelper } from '@/providers/temporary-helper-provider';
import { KeyboardEvent } from 'react';
interface ICloseParams {
workspaceId?: string;
}
@ -20,7 +21,7 @@ export const CreateWorkspaceModal = ({ open, onClose }: ModalProps) => {
onClose({ workspaceId: workspace.id });
setActiveWorkspace(workspace);
};
const handleKeyDown = (event: KeyboardEvent) => {
const handleKeyDown = (event: KeyboardEvent<HTMLInputElement>) => {
if (event.key === 'Enter') {
// 👇 Get input value
handleCreateWorkspace();