fix: snackbar 导致界面不可点击的问题

This commit is contained in:
Ivan Li 2021-10-04 11:05:59 +08:00
parent 320506af68
commit e8620c2818
5 changed files with 5889 additions and 2344 deletions

8180
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -35,7 +35,7 @@
"graphql": "^15.5.0", "graphql": "^15.5.0",
"graphql-scalars": "^1.10.0", "graphql-scalars": "^1.10.0",
"material-ui-confirm": "^2.1.2", "material-ui-confirm": "^2.1.2",
"notistack": "^1.0.6", "notistack": "^2.0.2",
"ramda": "^0.27.1", "ramda": "^0.27.1",
"react": "^17.0.2", "react": "^17.0.2",
"react-ace": "^9.4.4", "react-ace": "^9.4.4",

View File

@ -2021,13 +2021,9 @@
} }
], ],
"type": { "type": {
"kind": "NON_NULL", "kind": "OBJECT",
"name": null, "name": "Configuration",
"ofType": { "ofType": null
"kind": "OBJECT",
"name": "Configuration",
"ofType": null
}
}, },
"isDeprecated": false, "isDeprecated": false,
"deprecationReason": null "deprecationReason": null
@ -2044,6 +2040,18 @@
"description": null, "description": null,
"fields": null, "fields": null,
"inputFields": [ "inputFields": [
{
"name": "id",
"description": null,
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
},
{ {
"name": "pipelineId", "name": "pipelineId",
"description": null, "description": null,
@ -2107,6 +2115,18 @@
"defaultValue": null, "defaultValue": null,
"isDeprecated": false, "isDeprecated": false,
"deprecationReason": null "deprecationReason": null
},
{
"name": "name",
"description": null,
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"defaultValue": "\"Default Configuration\"",
"isDeprecated": false,
"deprecationReason": null
} }
], ],
"interfaces": null, "interfaces": null,

View File

@ -214,7 +214,7 @@ export type Query = {
commits?: Maybe<Array<Commit>>; commits?: Maybe<Array<Commit>>;
listPipelineTaskByPipelineId: Array<PipelineTask>; listPipelineTaskByPipelineId: Array<PipelineTask>;
pipelineTask: PipelineTask; pipelineTask: PipelineTask;
getConfiguration: Configuration; getConfiguration?: Maybe<Configuration>;
}; };
@ -255,10 +255,12 @@ export type QueryGetConfigurationArgs = {
}; };
export type SetConfigurationInput = { export type SetConfigurationInput = {
id?: Maybe<Scalars['String']>;
pipelineId: Scalars['String']; pipelineId: Scalars['String'];
projectId: Scalars['String']; projectId: Scalars['String'];
content: Scalars['String']; content: Scalars['String'];
language: ConfigurationLanguage; language: ConfigurationLanguage;
name?: Maybe<Scalars['String']>;
}; };
export type Subscription = { export type Subscription = {

View File

@ -9,8 +9,7 @@ import { ConfirmProvider } from "material-ui-confirm";
import { SnackbarProvider } from "notistack"; import { SnackbarProvider } from "notistack";
import Router from "./commons/route/router"; import Router from "./commons/route/router";
import { AuthProvider } from "./commons/auth/auth.provider"; import { AuthProvider } from "./commons/auth/auth.provider";
import { LocalizationProvider } from "@mui/lab"; import { zhCN } from "@mui/material/locale";
import AdapterDateFns from "@mui/lab/AdapterDateFns";
import { import {
ThemeProvider, ThemeProvider,
Theme, Theme,
@ -23,7 +22,7 @@ declare module "@mui/styles/defaultTheme" {
interface DefaultTheme extends Theme {} interface DefaultTheme extends Theme {}
} }
const theme = createTheme(); const theme = createTheme({}, zhCN);
ReactDOM.render( ReactDOM.render(
<React.StrictMode> <React.StrictMode>
@ -33,11 +32,9 @@ ReactDOM.render(
<SnackbarProvider maxSnack={5}> <SnackbarProvider maxSnack={5}>
<AuthProvider> <AuthProvider>
<AppApolloClientProvider> <AppApolloClientProvider>
<LocalizationProvider dateAdapter={AdapterDateFns}> <Router>
<Router> <App />
<App /> </Router>
</Router>
</LocalizationProvider>
</AppApolloClientProvider> </AppApolloClientProvider>
</AuthProvider> </AuthProvider>
</SnackbarProvider> </SnackbarProvider>