Skip to content

Commit bfee3cd

Browse files
Stev24steven
andauthored
fix(react): add onPointerDown, onTouchEnd, add onTouchMove (#29736)
Issue number: resolves #29174 --------- ## What is the current behavior? React throws tab errors with `IonTabButton` when binding to `onPointerDown`, `onTouchEnd` and `onTouchMove` ## What is the new behavior? - Adds missing type definitions for `onPointerDown`, `onTouchEnd` and `onTouchMove` to `IonTaButton` - React does not throw type errors when binding callback functions to these events --------- ## Does this introduce a breaking change? - [ ] Yes - [x] No --------- Co-authored-by: steven <[email protected]>
1 parent 133995a commit bfee3cd

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/react/src/components/navigation/IonTabButton.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ type Props = LocalJSX.IonTabButton &
1010
routerOptions?: RouterOptions;
1111
ref?: React.Ref<HTMLIonTabButtonElement>;
1212
onClick?: (e: CustomEvent) => void;
13+
onPointerDown?: React.PointerEventHandler<HTMLIonTabButtonElement>;
14+
onTouchEnd?: React.TouchEventHandler<HTMLIonTabButtonElement>;
15+
onTouchMove?: React.TouchEventHandler<HTMLIonTabButtonElement>;
1316
};
1417

1518
export const IonTabButton = /*@__PURE__*/ (() =>

0 commit comments

Comments
 (0)