Skip to content

Commit 7485e42

Browse files
authored
Merge pull request #977 from mapswipe/fix/typing-issue-username-change
Update typings
2 parents bdceb72 + 90f0996 commit 7485e42

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

community-dashboard/app/components/ContributionHeatMap/index.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,9 @@ function HeatmapComponent(props: HeatmapComponentProps) {
5050
const map = useMap();
5151

5252
useEffect(() => {
53-
map.gestureHandling.enable();
53+
// NOTE: We need to cast type of map here because of how gesture handle plugin works
54+
type MapWithGestureHandle = typeof map & { gestureHandling: { enable: () => void }};
55+
(map as MapWithGestureHandle).gestureHandling.enable();
5456
}, [map]);
5557

5658
useEffect(() => {

community-dashboard/app/components/MemberItem/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ interface Props {
1313
totalMappingProjects: number;
1414
totalSwipeTime: number;
1515
totalSwipes: number;
16-
username: string;
16+
username?: string | null;
1717
userId: string;
1818
isActive: boolean;
1919
};

community-dashboard/app/components/SelectInput/SearchSelectInput.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ function SearchSelectInput<
231231
);
232232

233233
const optionRendererParamsDefault = useCallback(
234-
(key: T, option: O) => {
234+
(key: T, option: O): P => {
235235
const isActive = key === value;
236236

237237
return {

0 commit comments

Comments
 (0)