Skip to content
Snippets Groups Projects

feat: add reactions details on map + interactive layer improvements

41 files
+ 1149
29
Compare changes
  • Side-by-side
  • Inline
Files
41
import { PinType } from '@/components/Map/Drawer/SearchDrawerWrapper/ResultsList/PinsList/PinsList.types';
import { ONE } from '@/constants/common';
import { BioEntity } from '@/types/models';
import { UsePointToProjectionResult } from '@/utils/map/usePointToProjection';
import { Feature } from 'ol';
import { getBioEntitySingleFeature } from './getBioEntitySingleFeature';
export const getBioEntitiesFeatures = (
bioEntites: BioEntity[],
{
pointToProjection,
type,
}: {
pointToProjection: UsePointToProjectionResult;
type: PinType;
},
): Feature[] => {
return bioEntites.map((bioEntity, index) =>
getBioEntitySingleFeature(bioEntity, {
pointToProjection,
type,
value: index + ONE,
}),
);
};
Loading