From 3f1ffd2fc2f09bd6b5909ae69ef07006750f4436 Mon Sep 17 00:00:00 2001
From: Michael Foiani <sotech117@michaels-mbp-5.devices.brown.edu>
Date: Wed, 3 Aug 2022 13:41:52 -0400
Subject: add new icon and modal for reporting.

---
 src/client/views/topbar/TopBar.tsx | 6 ++++++
 1 file changed, 6 insertions(+)

(limited to 'src/client/views/topbar/TopBar.tsx')

diff --git a/src/client/views/topbar/TopBar.tsx b/src/client/views/topbar/TopBar.tsx
index 3fc0a237e..cbcfed06f 100644
--- a/src/client/views/topbar/TopBar.tsx
+++ b/src/client/views/topbar/TopBar.tsx
@@ -1,5 +1,6 @@
 import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
 import { Tooltip } from '@material-ui/core';
+import { MdBugReport } from 'react-icons/md';
 import { action } from 'mobx';
 import { observer } from 'mobx-react';
 import * as React from 'react';
@@ -18,6 +19,7 @@ import { DashboardView } from '../DashboardView';
 import { Borders, Colors } from '../global/globalEnums';
 import { MainView } from '../MainView';
 import './TopBar.scss';
+import { ReportManager } from '../../util/ReportManager';
 
 /**
  * ABOUT: This is the topbar in Dash, which included the current Dashboard as well as access to information on the user
@@ -31,6 +33,7 @@ export class TopBar extends React.Component {
             DashboardView.closeActiveDashboard(); // bcz: if we do this, we need some other way to keep track, for user convenience, of the last dashboard in use
         });
     };
+    
     render() {
         const activeDashboard = Doc.ActiveDashboard;
         return (
@@ -92,6 +95,9 @@ export class TopBar extends React.Component {
                                 {GetEffectiveAcl(Doc.GetProto(Doc.ActiveDashboard)) === AclAdmin ? 'Share' : 'view original'}
                             </div>
                         ) : null}
+                        <div className="topbar-button-icon" onClick={() => ReportManager.Instance.open()}>
+                            <MdBugReport />
+                        </div>
                         <div className="topbar-button-icon" onClick={() => window.open('https://brown-dash.github.io/Dash-Documentation/', '_blank')}>
                             <FontAwesomeIcon icon="question-circle" />
                         </div>
-- 
cgit v1.2.3-70-g09d2

