import React from 'react'; import { useDispatch } from 'react-redux'; import { refreshView } from 'prophet-core'; import { Button } from 'antd'; export default props => { const { label, onClick, ...other } = props; const dispatch = useDispatch(); const handleClick = () => { dispatch(refreshView()); onClick && onClick(); }; return ( ); };