Simplify config
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU Reviewed By: lblasa Differential Revision: D48600255 fbshipit-source-id: a57504519000fce4544f6875b2933cd5bcaedba3
This commit is contained in:
committed by
Facebook GitHub Bot
parent
e87ec62552
commit
380e99400f
@@ -7,11 +7,14 @@
|
||||
* @format
|
||||
*/
|
||||
|
||||
// Mostly mateches https://www.internalfb.com/code/www/html/intern/js/ui/PowerSearch/PowerSearchExampleConfig.js
|
||||
// Mostly matches https://www.internalfb.com/code/www/html/intern/js/ui/PowerSearch/PowerSearchExampleConfig.js
|
||||
|
||||
export type SimpleFilterValueType = 'NESTED' | 'NO_VALUE' | 'INTEGER' | 'FLOAT';
|
||||
|
||||
export type StringFilterValueType = 'STRING_SET' | 'STRING';
|
||||
export type SimpleFilterValueType =
|
||||
| 'NO_VALUE'
|
||||
| 'INTEGER'
|
||||
| 'FLOAT'
|
||||
| 'STRING_SET'
|
||||
| 'STRING';
|
||||
|
||||
export type EnumFilterValueType = 'ENUM_SET' | 'ENUM';
|
||||
|
||||
@@ -27,13 +30,6 @@ export type SimpleOperatorConfig = {
|
||||
label: string;
|
||||
};
|
||||
|
||||
export type StringOperatorConfig = {
|
||||
valueType: StringFilterValueType;
|
||||
key: string;
|
||||
label: string;
|
||||
allowArbitraryEntries?: boolean;
|
||||
};
|
||||
|
||||
export type EnumOperatorConfig = {
|
||||
valueType: EnumFilterValueType;
|
||||
key: string;
|
||||
@@ -75,7 +71,6 @@ export type TimeOperatorConfig = {
|
||||
|
||||
export type OperatorConfig =
|
||||
| SimpleOperatorConfig
|
||||
| StringOperatorConfig
|
||||
| EnumOperatorConfig
|
||||
| AbsoluteDateOperatorConfig
|
||||
| RelativeDateOperatorConfig
|
||||
|
||||
Reference in New Issue
Block a user