@prefecthq/prefect-ui-library
Version:
This library is the Vue and Typescript component library for [Prefect 2](https://github.com/PrefectHQ/prefect) and [Prefect Cloud 2](https://www.prefect.io/cloud/). _The components and utilities in this project are not meant to be used independently_.
14 lines (13 loc) • 1.58 kB
TypeScript
import { AutomationTriggerMatch, AutomationTriggerEventResource, AutomationTriggerEventResourceLabel, AutomationTriggerEventResourceRole, EventResourceValue } from '../../automations/types/api/triggers';
import { AutomationTrigger } from '../../automations/types/triggers';
export declare function toResourceId(resource: AutomationTriggerEventResource, values: string[]): string | string[];
export declare function fromResourceId(resource: AutomationTriggerEventResource, value: EventResourceValue): string[];
export declare function fromResourceName(match: AutomationTriggerMatch, role: AutomationTriggerEventResourceRole): string[];
export declare function toStateNameEvents(stateTypes: string[]): string[];
export declare function fromStateNameEvents(events: string[]): string[];
export declare function toMatchRelatedId(role: AutomationTriggerEventResourceRole, id: string | string[]): AutomationTriggerMatch | undefined;
export declare function toMatchRelatedName(role: AutomationTriggerEventResourceRole, name: string | string[]): AutomationTriggerMatch | undefined;
export declare function isMatchResource(trigger: AutomationTrigger, predicate: (resourceIds: string[]) => boolean): boolean;
export declare function isForEachResource(trigger: AutomationTrigger, resource: AutomationTriggerEventResourceLabel): boolean;
export declare function isExpectResource(trigger: AutomationTrigger, predicate: (resourceIds: string[]) => boolean): boolean;
export declare function isAfterResource(trigger: AutomationTrigger, predicate: (resourceIds: string[]) => boolean): boolean;