bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/actions-bar/interactions-button/container.jsx
Max Franke fbcc611bd9 feat(interactions): add new interactions button
Interactions button is a button that stays in action bar.
Integrates several features in just one place: user-reaction, raise hand,
user-status (away/not away), toggle question panel.
2023-04-27 13:57:40 -03:00

28 lines
1016 B
JavaScript

import React, { useContext } from 'react';
import { withTracker } from 'meteor/react-meteor-data';
import { withModalMounter } from '/imports/ui/components/modal/service';
import LayoutContext from '/imports/ui/components/layout/context';
import { injectIntl } from 'react-intl';
import InteractionsButton from './component';
import actionsBarService from '../service';
const InteractionsButtonContainer = ({ ...props }) => {
const layoutContext = useContext(LayoutContext);
const { layoutContextState, layoutContextDispatch } = layoutContext;
const { input } = layoutContextState;
const { sidebarContent } = input;
const { sidebarContentPanel } = sidebarContent;
return (
<InteractionsButton {...{ layoutContextDispatch, sidebarContentPanel, ...props }} />
);
};
export default injectIntl(withModalMounter(withTracker(() => {
const currentUser = actionsBarService.currentUser();
return {
userId: currentUser.userId,
emoji: currentUser.emoji,
};
})(InteractionsButtonContainer)));