aboutsummaryrefslogtreecommitdiffstats
path: root/webui/src/components/CloseBugButton/CloseBugButton.tsx
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2021-03-07 22:09:41 +0100
committerGitHub <noreply@github.com>2021-03-07 22:09:41 +0100
commit501e1678b2af280300a4c35d762c54379e3142e4 (patch)
tree8577cf83b4d661184b9e38b17fee9652daf4b153 /webui/src/components/CloseBugButton/CloseBugButton.tsx
parent2a21b02af157275e20c4ce6d308b45f9a3d7ebaf (diff)
parentc2c5c40e752663e238bdd29c54d3a5634ba9615c (diff)
downloadgit-bug-501e1678b2af280300a4c35d762c54379e3142e4.tar.gz
Merge pull request #588 from GlancingMind/upstream-dark-colorscheme
Dark Colorscheme
Diffstat (limited to 'webui/src/components/CloseBugButton/CloseBugButton.tsx')
-rw-r--r--webui/src/components/CloseBugButton/CloseBugButton.tsx11
1 files changed, 11 insertions, 0 deletions
diff --git a/webui/src/components/CloseBugButton/CloseBugButton.tsx b/webui/src/components/CloseBugButton/CloseBugButton.tsx
index 19f56cab..8d397c23 100644
--- a/webui/src/components/CloseBugButton/CloseBugButton.tsx
+++ b/webui/src/components/CloseBugButton/CloseBugButton.tsx
@@ -1,12 +1,21 @@
import React from 'react';
import Button from '@material-ui/core/Button';
+import { makeStyles, Theme } from '@material-ui/core/styles';
+import ErrorOutlineIcon from '@material-ui/icons/ErrorOutline';
import { BugFragment } from 'src/pages/bug/Bug.generated';
import { TimelineDocument } from 'src/pages/bug/TimelineQuery.generated';
import { useCloseBugMutation } from './CloseBug.generated';
+const useStyles = makeStyles((theme: Theme) => ({
+ closeIssueIcon: {
+ color: theme.palette.secondary.dark,
+ paddingTop: '0.1rem',
+ },
+}));
+
interface Props {
bug: BugFragment;
disabled: boolean;
@@ -14,6 +23,7 @@ interface Props {
function CloseBugButton({ bug, disabled }: Props) {
const [closeBug, { loading, error }] = useCloseBugMutation();
+ const classes = useStyles();
function closeBugAction() {
closeBug({
@@ -45,6 +55,7 @@ function CloseBugButton({ bug, disabled }: Props) {
variant="contained"
onClick={() => closeBugAction()}
disabled={bug.status === 'CLOSED' || disabled}
+ startIcon={<ErrorOutlineIcon className={classes.closeIssueIcon} />}
>
Close issue
</Button>