aboutsummaryrefslogtreecommitdiff
path: root/src/client/util/reportManager
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/util/reportManager')
-rw-r--r--src/client/util/reportManager/ReportManager.scss7
-rw-r--r--src/client/util/reportManager/ReportManager.tsx11
-rw-r--r--src/client/util/reportManager/ReportManagerComponents.tsx2
3 files changed, 11 insertions, 9 deletions
diff --git a/src/client/util/reportManager/ReportManager.scss b/src/client/util/reportManager/ReportManager.scss
index cd6a1d934..d82d7fdeb 100644
--- a/src/client/util/reportManager/ReportManager.scss
+++ b/src/client/util/reportManager/ReportManager.scss
@@ -1,4 +1,4 @@
-@import '../../views/global/globalCssVariables';
+@import '../../views/global/globalCssVariables.module';
// header
@@ -360,5 +360,8 @@
padding: 4px 10px;
font-size: 10px;
border-radius: 32px;
- transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
+ transition:
+ background-color 0.2s ease,
+ color 0.2s ease,
+ border-color 0.2s ease;
}
diff --git a/src/client/util/reportManager/ReportManager.tsx b/src/client/util/reportManager/ReportManager.tsx
index b25d51b41..0c49aeed4 100644
--- a/src/client/util/reportManager/ReportManager.tsx
+++ b/src/client/util/reportManager/ReportManager.tsx
@@ -1,13 +1,11 @@
import * as React from 'react';
-import v4 = require('uuid/v4');
+import * as uuid from 'uuid';
import '.././SettingsManager.scss';
import './ReportManager.scss';
-import Dropzone from 'react-dropzone';
import ReactLoading from 'react-loading';
-import { action, observable } from 'mobx';
+import { action, makeObservable, observable } from 'mobx';
import { BsX, BsArrowsAngleExpand, BsArrowsAngleContract } from 'react-icons/bs';
import { CgClose } from 'react-icons/cg';
-import { AiOutlineUpload } from 'react-icons/ai';
import { HiOutlineArrowLeft } from 'react-icons/hi';
import { Issue } from './reportManagerSchema';
import { observer } from 'mobx-react';
@@ -105,6 +103,7 @@ export class ReportManager extends React.Component<{}> {
constructor(props: {}) {
super(props);
+ makeObservable(this);
ReportManager.Instance = this;
// initializing Github connection
@@ -156,7 +155,7 @@ export class ReportManager extends React.Component<{}> {
* @param files uploaded files
*/
private onDrop = (files: File[]) => {
- this.setFormData({ ...this.formData, mediaFiles: [...this.formData.mediaFiles, ...files.map(file => ({ _id: v4(), file }))] });
+ this.setFormData({ ...this.formData, mediaFiles: [...this.formData.mediaFiles, ...files.map(file => ({ _id: uuid.v4(), file }))] });
};
/**
@@ -338,7 +337,7 @@ export class ReportManager extends React.Component<{}> {
multiple
onChange={e => {
if (!e.target.files) return;
- this.setFormData({ ...this.formData, mediaFiles: [...this.formData.mediaFiles, ...Array.from(e.target.files).map(file => ({ _id: v4(), file }))] });
+ this.setFormData({ ...this.formData, mediaFiles: [...this.formData.mediaFiles, ...Array.from(e.target.files).map(file => ({ _id: uuid.v4(), file }))] });
}}
/>
{this.formData.mediaFiles.length > 0 && <ul className="file-list">{this.formData.mediaFiles.map(file => this.getMediaPreview(file))}</ul>}
diff --git a/src/client/util/reportManager/ReportManagerComponents.tsx b/src/client/util/reportManager/ReportManagerComponents.tsx
index e870c073d..1e226bf6d 100644
--- a/src/client/util/reportManager/ReportManagerComponents.tsx
+++ b/src/client/util/reportManager/ReportManagerComponents.tsx
@@ -289,7 +289,7 @@ export const IssueView = ({ issue }: IssueViewProps) => {
</div>
</div>
)}
- <ReactMarkdown children={issueBody} className="issue-content" linkTarget={'_blank'} remarkPlugins={[remarkGfm]} rehypePlugins={[rehypeRaw]} />
+ <ReactMarkdown children={issueBody} className="issue-content" remarkPlugins={[remarkGfm]} rehypePlugins={[rehypeRaw]} />
</div>
);
};