{"version":3,"file":"expressions.cjs","sources":["../../src/expressions.ts"],"sourcesContent":["export enum QueryEditorPropertyType {\n  String = 'string',\n}\n\nexport interface QueryEditorProperty {\n  type: QueryEditorPropertyType;\n  name?: string;\n}\n\nexport type QueryEditorOperatorType = string | boolean | number;\ntype QueryEditorOperatorValueType = QueryEditorOperatorType | QueryEditorOperatorType[];\n\nexport interface QueryEditorOperator<T extends QueryEditorOperatorValueType> {\n  name?: string;\n  value?: T;\n}\n\nexport interface QueryEditorOperatorExpression {\n  type: QueryEditorExpressionType.Operator;\n  property: QueryEditorProperty;\n  operator: QueryEditorOperator<QueryEditorOperatorValueType>;\n}\n\nexport interface QueryEditorArrayExpression {\n  type: QueryEditorExpressionType.And | QueryEditorExpressionType.Or;\n  expressions: QueryEditorExpression[] | QueryEditorArrayExpression[];\n}\n\nexport interface QueryEditorPropertyExpression {\n  type: QueryEditorExpressionType.Property;\n  property: QueryEditorProperty;\n}\n\nexport enum QueryEditorExpressionType {\n  Property = 'property',\n  Operator = 'operator',\n  Or = 'or',\n  And = 'and',\n  GroupBy = 'groupBy',\n  Function = 'function',\n  FunctionParameter = 'functionParameter',\n}\n\nexport type QueryEditorExpression =\n  | QueryEditorArrayExpression\n  | QueryEditorPropertyExpression\n  | QueryEditorGroupByExpression\n  | QueryEditorFunctionExpression\n  | QueryEditorFunctionParameterExpression\n  | QueryEditorOperatorExpression;\n\nexport interface QueryEditorGroupByExpression {\n  type: QueryEditorExpressionType.GroupBy;\n  property: QueryEditorProperty;\n}\n\nexport interface QueryEditorFunctionExpression {\n  type: QueryEditorExpressionType.Function;\n  name?: string;\n  alias?: string;\n  parameters?: QueryEditorFunctionParameterExpression[];\n}\n\nexport interface QueryEditorFunctionParameterExpression {\n  type: QueryEditorExpressionType.FunctionParameter;\n  name?: string;\n}\n"],"names":["QueryEditorPropertyType","QueryEditorExpressionType"],"mappings":";;;;;AAAO,IAAK,uBAAA,qBAAAA,wBAAAA,KAAL;AACL,EAAAA,yBAAA,QAAA,CAAA,GAAS,QAAA;AADC,EAAA,OAAAA,wBAAAA;AAAA,CAAA,EAAA,uBAAA,IAAA,EAAA;AAiCL,IAAK,yBAAA,qBAAAC,0BAAAA,KAAL;AACL,EAAAA,2BAAA,UAAA,CAAA,GAAW,UAAA;AACX,EAAAA,2BAAA,UAAA,CAAA,GAAW,UAAA;AACX,EAAAA,2BAAA,IAAA,CAAA,GAAK,IAAA;AACL,EAAAA,2BAAA,KAAA,CAAA,GAAM,KAAA;AACN,EAAAA,2BAAA,SAAA,CAAA,GAAU,SAAA;AACV,EAAAA,2BAAA,UAAA,CAAA,GAAW,UAAA;AACX,EAAAA,2BAAA,mBAAA,CAAA,GAAoB,mBAAA;AAPV,EAAA,OAAAA,0BAAAA;AAAA,CAAA,EAAA,yBAAA,IAAA,EAAA;;;;;"}