ant-design/components/_util/wave/useWave.ts
二货爱吃白萝卜 9f7b129c41
fix: Button wave follow issue (#39954)
* fix: Button wave follow issue

* test: update test case

* chore: fix lint
2023-01-02 16:34:35 +08:00

15 lines
280 B
TypeScript

import showWaveEffect from './WaveEffect';
export default function useWave(
nodeRef: React.RefObject<HTMLElement>,
className: string,
): VoidFunction {
function showWave() {
const node = nodeRef.current!;
showWaveEffect(node, className);
}
return showWave;
}