-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(Filters): add record type to filter value
- Loading branch information
Showing
3 changed files
with
69 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
import React from 'react'; | ||
|
||
import { SpaceSizes } from '../../../theme'; | ||
import { Inline, Padbox, Stack } from '../../layout'; | ||
import { SelectFilter } from '../components'; | ||
import Input from '../components/Input/Input'; | ||
|
||
type MockObject = { | ||
inputValue: string; | ||
includeAssets: string[]; | ||
}; | ||
|
||
interface MockObjectFilterProps { | ||
value: MockObject; | ||
} | ||
|
||
const MockObjectFilter: React.FC<MockObjectFilterProps> = ({ value }) => { | ||
const options = [ | ||
{ | ||
label: 'Include associated subdomains', | ||
value: 'include_domains', | ||
}, | ||
{ | ||
label: 'Include associated IPs', | ||
value: 'include_ips', | ||
}, | ||
]; | ||
|
||
const handleFilterOnChange = () => { | ||
throw new Error('Not implemented'); | ||
}; | ||
|
||
return ( | ||
<Padbox> | ||
<Inline gap={SpaceSizes.sm} stretch="start"> | ||
<Stack> | ||
<Input value={value.inputValue} onChange={handleFilterOnChange} /> | ||
</Stack> | ||
<Stack style={{ width: 330 }}> | ||
<SelectFilter options={options} isMulti /> | ||
</Stack> | ||
</Inline> | ||
</Padbox> | ||
); | ||
}; | ||
export default MockObjectFilter; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters