feat: update quick search ui

This commit is contained in:
JimmFly
2022-12-09 19:44:30 +08:00
parent c522eea4d6
commit 5899450c9d
8 changed files with 128 additions and 70 deletions
@@ -1,17 +1,20 @@
import React from 'react';
import React, { Dispatch, SetStateAction } from 'react';
import { MiddleSearchIcon } from '@blocksuite/icons';
import { StyledInput, StyledInputContent, StyledLabel } from './style';
const Input = () => {
import { StyledInputContent, StyledLabel } from './style';
import { Command } from 'cmdk';
const Input = (props: {
search: string;
setSearch: Dispatch<SetStateAction<string>>;
}) => {
return (
<StyledInputContent>
<StyledLabel htmlFor="quickSearchInput">
<StyledLabel htmlFor=":r5:">
<MiddleSearchIcon />
</StyledLabel>
<StyledInput
id="quickSearchInput"
type="text"
placeholder="Quick search..."
<Command.Input
value={props.search}
onValueChange={props.setSearch}
placeholder="Quick Search..."
/>
</StyledInputContent>
);