Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(NOJIRA-123): fix Action.condition type #50

Merged
merged 2 commits into from
Oct 3, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion src/typeform-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export namespace Typeform {
* Conditions for executing the Logic Jump. Conditions answer the question, "Under what circumstances?"
* The condition object is the IF statement in your Logic Jump.
*/
condition?: Condition
condition?: Condition | AndOrOperator
}
/**
* Properties that further specify how the Logic Jump will behave.
Expand Down Expand Up @@ -198,6 +198,19 @@ export namespace Typeform {
value?: any
}[]
}
/**
* Conditions for a logic jump can be combined using the `and` and `or` operators
*/
export interface AndOrOperator {
/**
* Operator for the condition.
*/
op?: 'and' | 'or'
/**
* Object that defines the field type and value to evaluate with the operator.
*/
vars: Array<AndOrOperator | Condition>
}
/**
* Generic document.
*/
Expand Down
Loading