|
@@ -6,23 +6,23 @@ const ThreeStrandedButton = (props) => {
|
|
|
|
|
|
|
|
const { t } = props;
|
|
const { t } = props;
|
|
|
|
|
|
|
|
- function threeStrandedButtonClickedHandler() {
|
|
|
|
|
|
|
+ function threeStrandedButtonClickedHandler(clickedButton) {
|
|
|
if (props.onThreeStrandedButtonClicked != null) {
|
|
if (props.onThreeStrandedButtonClicked != null) {
|
|
|
- props.onThreeStrandedButtonClicked();
|
|
|
|
|
|
|
+ props.onThreeStrandedButtonClicked(clickedButton);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
return (
|
|
return (
|
|
|
<div className="btn-group grw-three-stranded-button" role="group " aria-label="three-stranded-button">
|
|
<div className="btn-group grw-three-stranded-button" role="group " aria-label="three-stranded-button">
|
|
|
- <button type="button" className="btn btn-outline-primary view-button" onClick={() => { threeStrandedButtonClickedHandler() }}>
|
|
|
|
|
|
|
+ <button type="button" className="btn btn-outline-primary view-button" onClick={() => { threeStrandedButtonClickedHandler('view') }}>
|
|
|
<i className="icon-control-play icon-fw" />
|
|
<i className="icon-control-play icon-fw" />
|
|
|
{ t('view') }
|
|
{ t('view') }
|
|
|
</button>
|
|
</button>
|
|
|
- <button type="button" className="btn btn-outline-primary edit-button" onClick={() => { threeStrandedButtonClickedHandler() }}>
|
|
|
|
|
|
|
+ <button type="button" className="btn btn-outline-primary edit-button" onClick={() => { threeStrandedButtonClickedHandler('edit') }}>
|
|
|
<i className="icon-note icon-fw" />
|
|
<i className="icon-note icon-fw" />
|
|
|
{ t('Edit') }
|
|
{ t('Edit') }
|
|
|
</button>
|
|
</button>
|
|
|
- <button type="button" className="btn btn-outline-primary hackmd-button" onClick={() => { threeStrandedButtonClickedHandler() }}>
|
|
|
|
|
|
|
+ <button type="button" className="btn btn-outline-primary hackmd-button" onClick={() => { threeStrandedButtonClickedHandler('hackmd') }}>
|
|
|
<i className="fa fa-fw fa-file-text-o" />
|
|
<i className="fa fa-fw fa-file-text-o" />
|
|
|
{ t('hackmd.hack_md') }
|
|
{ t('hackmd.hack_md') }
|
|
|
</button>
|
|
</button>
|