/
EmptyFilteredIdentities.js
73 lines (68 loc) · 1.6 KB
/
EmptyFilteredIdentities.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
import React from 'react'
import PropTypes from 'prop-types'
import { Button, GU, textStyle, useTheme } from '@aragon/ui'
import noResultsPng from '../../../assets/no-results.png'
function EmptyFilteredIdentities({ onClear }) {
const theme = useTheme()
return (
<div
css={`
margin-top: ${4 * GU}px;
display: flex;
flex-direction: column;
align-items: center;
`}
>
<img
css={`
margin: ${4 * GU}px 0;
height: 176px;
`}
src={noResultsPng}
alt="No results"
/>
<h3
css={`
font-size: 28px;
color: ${theme.content};
margin-bottom: ${1 * GU}px;
`}
>
No results found.
</h3>
<div
css={`
max-width: 270px;
text-align: center;
margin-bottom: ${4 * GU}px;
color: ${theme.surfaceContentSecondary};
${textStyle('body2')}
`}
>
We can’t find any item matching your search query.{' '}
<Button
css={`
color: ${theme.link};
border: none;
background: none;
border-radius: 0;
box-shadow: none;
padding: 0;
min-width: unset;
&:hover {
border: none;
box-shadow: none;
}
`}
onClick={onClear}
>
Clear search
</Button>
</div>
</div>
)
}
EmptyFilteredIdentities.propTypes = {
onClear: PropTypes.func.isRequired,
}
export default React.memo(EmptyFilteredIdentities)