perf: new chat modal

This commit is contained in:
archer
2023-05-08 14:19:28 +08:00
parent d351084688
commit f20a5fe9a6
3 changed files with 22 additions and 9 deletions

View File

@@ -7,7 +7,7 @@ const ModelList = ({ models, modelId }: { models: ModelListItemType[]; modelId:
const router = useRouter();
return (
<Box w={'100%'} h={'100%'} bg={'white'} overflow={'overlay'}>
<>
{models.map((item) => (
<Box key={item._id}>
<Flex
@@ -18,6 +18,7 @@ const ModelList = ({ models, modelId }: { models: ModelListItemType[]; modelId:
cursor={'pointer'}
transition={'background-color .2s ease-in'}
borderLeft={['', '5px solid transparent']}
zIndex={0}
_hover={{
backgroundColor: ['', '#dee0e3']
}}
@@ -50,7 +51,7 @@ const ModelList = ({ models, modelId }: { models: ModelListItemType[]; modelId:
</Flex>
</Box>
))}
</Box>
</>
);
};