From 0912fb736d435b132779828376cd10cf7ad8e56e Mon Sep 17 00:00:00 2001 From: Claire Date: Thu, 15 Dec 2022 18:50:11 +0100 Subject: [Glitch] Add follow request banner on account header Port 70415714f14e067aba518a105c96475db31fa124 to glitch-soc Signed-off-by: Claire --- .../account/containers/follow_request_note_container.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 app/javascript/flavours/glitch/features/account/containers/follow_request_note_container.js (limited to 'app/javascript/flavours/glitch/features/account/containers') diff --git a/app/javascript/flavours/glitch/features/account/containers/follow_request_note_container.js b/app/javascript/flavours/glitch/features/account/containers/follow_request_note_container.js new file mode 100644 index 000000000..c6a3afb7e --- /dev/null +++ b/app/javascript/flavours/glitch/features/account/containers/follow_request_note_container.js @@ -0,0 +1,15 @@ +import { connect } from 'react-redux'; +import FollowRequestNote from '../components/follow_request_note'; +import { authorizeFollowRequest, rejectFollowRequest } from 'flavours/glitch/actions/accounts'; + +const mapDispatchToProps = (dispatch, { account }) => ({ + onAuthorize () { + dispatch(authorizeFollowRequest(account.get('id'))); + }, + + onReject () { + dispatch(rejectFollowRequest(account.get('id'))); + }, +}); + +export default connect(null, mapDispatchToProps)(FollowRequestNote); -- cgit