visualization-tools

Home > @visualization-tools/core > IInteractionGroup

IInteractionGroup interface

Entities in this group have the same requirements as IHitTestableGroup. Allows up to 32 IInteractionGroups per plot for click / hover handlers etc.

Signature:

export interface IInteractionGroup<TUpdateArg, TStore, TTraits extends IHitTestableTrait> extends IEntityGroup<IHitTestableGroupOptions<TUpdateArg, TTraits, TStore>, IHitTestableTrait> 

Extends: IEntityGroup<IHitTestableGroupOptions<TUpdateArg, TTraits, TStore>, IHitTestableTrait>

Remarks

IInteractionGroups should share IHitTestableGroups to avoid duplicate work. Each entity is allowed a single IHitTestableGroup shared between all IInteractionGroups but may have a unique IHitAllowedComponent per group.

Properties

Property Type Description
groupMask number Must be unique to identify the group.
hitAllowedComponentStore IEntityComponentStore<TEntityTrait<TUpdateArg, IHitTestableTrait>, IHitAllowedComponent<TUpdateArg, IHitTestableTrait>>  
hitTestableGroup HitTestableGroup<IPlotRange, TUpdateArg, TStore>  

Methods

Method Description
addToGroup(entity, options) Use this over addToGroup on plot to get better typing.