Filtering
It is possible to filter the events and actors of a Storygram in different ways.
Event value filter
Filters all events outside the range defined in the variable filterEventValue.
filterEventValue: [number | string | undefined, number | string | undefined];
Default value: [Number.MIN_SAFE_INTEGER, Number.MAX_SAFE_INTEGER]
Group size filter
Filters all events containing less or more actors than defined in the range in the variable filterGroupSize.
filterGroupSize: [number | undefined, number | undefined];
Default value: [0, Number.MAX_SAFE_INTEGER]
Grouping amount filter
Filters all actors that are grouped less or more times than defined in the range in the variable filterGroupAmt. The hidden actors are visualizable by clicking on the red number on top of the group.
filterGroupAmt: [number | undefined, number | undefined];
Default value: [0, Number.MAX_SAFE_INTEGER]
Event contains all actors filter
Filters all events that don't include all actors specified in the variable mustContain.
mustContain: string[];
Default value: []
Event contains some actors filter
// check if the event contains one of the given actors shouldContain: string[];
Filters all events that don't include at least one of the actors specified in the variable shouldContain.
shouldContain: string[];
Default value: []
Custom Event filter
Customizable filter callback that must return a boolean value, if true the event is visible, if false it is filtered.
filterEventCustom: (event: Event) => boolean;
Default value: () => true
Custom Actor filter
Customizable filter callback that must return a boolean value, if true the actor is visible, if false it is filtered.
filterActorCustom: (event: Event) => boolean;
Default value: () => true