github
147 of 214 branches covered (0.0%)
Branch coverage included in aggregate %.
12 of 27 new or added lines in 2 files covered. (44.44%)
3865 of 4354 relevant lines covered (88.77%)
4.17 hits per line
|
import { SearchChip } from '@deriv-com/components'; |
1✔ |
|
import { ReactNode } from 'react'; |
1✔ |
|
|
1✔ |
|
export type SearchBlockProps = {
|
1✔ |
|
showSearchresults: (e: string) => void; |
1✔ |
|
content: ReactNode;
|
1✔ |
|
}; |
1✔ |
|
|
1✔ |
|
export const SearchBlock = ({ |
1✔ |
NEW
|
showSearchresults, |
× |
NEW
|
content, |
× |
NEW
|
}: SearchBlockProps) => { |
× |
NEW
|
return (
|
× |
NEW
|
<section className="flex w-full max-w-[1024px] flex-col gap-general-xl py-general-xl ">
|
× |
NEW
|
<SearchChip |
× |
NEW
|
placeholder='Try "Trade"' |
× |
NEW
|
onChange={(value) => showSearchresults(value)} |
× |
NEW
|
className="w-full "
|
× |
NEW
|
inputClassName="!bg-gradient-slate-110"
|
× |
NEW
|
/> |
× |
NEW
|
{content && content} |
× |
NEW
|
</section> |
× |
NEW
|
); |
× |
NEW
|
}; |
× |
|
|
1✔ |
|
export default SearchBlock; |
1✔ |