Skip to content

Commit

Permalink
Merge pull request #327 from xcube-dev/ruchi_324_adaptv4theme
Browse files Browse the repository at this point in the history
Removed deprecated adaptV4theme from mui/material
  • Loading branch information
ruchimotwaniBC authored Apr 25, 2024
2 parents 5e92511 + 93e5325 commit 8ec152f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 17 deletions.
8 changes: 5 additions & 3 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,14 @@
- Project CI now also runs [ESlint](https://eslint.org/).
- Updated copyright headers of source files.
- Removed all usages of explicit `any` type in TypeScript files.
- No longer using deprecated `adaptV4Theme()` function from `@mui/material`.



TODO:

* Allow running `run: npm run coverage` in `.github/workflows/ci.yaml`:
* No longer use deprecated `adaptV4Theme` from `@mui/material`; use MUI v5
styling alternatives.
* Allow running `run: npm run coverage` in `.github/workflows/ci.yaml`:
* Use MUI v5 styling alternatives.

## Changes in version 1.1.1

Expand Down
25 changes: 11 additions & 14 deletions src/connected/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
import * as React from "react";
import { connect } from "react-redux";
import {
adaptV4Theme,
createTheme,
CssBaseline,
StyledEngineProvider,
Expand Down Expand Up @@ -60,19 +59,17 @@ const mapStateToProps = (_state: AppState) => {
const mapDispatchToProps = {};

const newTheme = () =>
createTheme(
adaptV4Theme({
typography: {
fontSize: 12,
htmlFontSize: 14,
},
palette: {
mode: Config.instance.branding.themeName,
primary: Config.instance.branding.primaryColor,
secondary: Config.instance.branding.secondaryColor,
},
}),
);
createTheme({
typography: {
fontSize: 12,
htmlFontSize: 14,
},
palette: {
mode: Config.instance.branding.themeName,
primary: Config.instance.branding.primaryColor,
secondary: Config.instance.branding.secondaryColor,
},
});

const _App: React.FC<AppProps> = ({ compact }) => {
return (
Expand Down

0 comments on commit 8ec152f

Please sign in to comment.