bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/actions-bar/presentation-options/component.jsx

40 lines
1.2 KiB
React
Raw Normal View History

import React from 'react';
import PropTypes from 'prop-types';
import { defineMessages, injectIntl, intlShape } from 'react-intl';
import Button from '/imports/ui/components/button/component';
import { styles } from '../styles';
const propTypes = {
intl: intlShape.isRequired,
toggleSwapLayout: PropTypes.func.isRequired,
};
const intlMessages = defineMessages({
restorePresentationLabel: {
id: 'app.actionsBar.actionsDropdown.restorePresentationLabel',
description: 'Restore Presentation option label',
},
restorePresentationDesc: {
id: 'app.actionsBar.actionsDropdown.restorePresentationDesc',
description: 'button to restore presentation after it has been closed',
},
});
const PresentationOptionsContainer = ({ intl, toggleSwapLayout }) => (
2019-01-15 21:13:55 +08:00
<Button
className={styles.button}
2019-01-15 21:13:55 +08:00
icon="presentation"
label={intl.formatMessage(intlMessages.restorePresentationLabel)}
2019-01-15 21:13:55 +08:00
description={intl.formatMessage(intlMessages.restorePresentationDesc)}
color="primary"
hideLabel
circle
size="lg"
onClick={toggleSwapLayout}
2019-01-15 21:13:55 +08:00
id="restore-presentation"
/>
2019-01-15 21:13:55 +08:00
);
PresentationOptionsContainer.propTypes = propTypes;
export default injectIntl(PresentationOptionsContainer);