Skip to content

Commit c52eedc

Browse files
committed
update next-client mui
1 parent 068becc commit c52eedc

File tree

4 files changed

+30
-8
lines changed

4 files changed

+30
-8
lines changed

apps/next-client/README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,6 @@
33
### Features
44

55
- [Mui v6](https://mui.com/material-ui/)
6-
- Button to toggle light and dark mode by changing MUI theme.
6+
- Button to toggle light and dark mode by changing MUI theme.
7+
8+
**TODO** - [MUI - Migrating to Pigment CSS](https://mui.com/material-ui/migration/migrating-to-pigment-css/#migrating-custom-theme)

apps/next-client/next.config.js

Lines changed: 0 additions & 4 deletions
This file was deleted.

apps/next-client/next.config.mjs

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
const nextConfig = {
2+
images: {
3+
dangerouslyAllowSVG: true,
4+
contentDispositionType: 'attachment',
5+
contentSecurityPolicy: "default-src 'self'; script-src 'none'; sandbox;",
6+
remotePatterns: [
7+
{
8+
protocol: 'https',
9+
hostname: 'img.icons8.com'
10+
},
11+
{
12+
protocol: 'https',
13+
hostname: 'img.shields.io'
14+
}
15+
]
16+
}
17+
};
18+
19+
export default nextConfig;

apps/next-client/src/app/layout.tsx

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
11
import type { Metadata } from 'next';
2-
import { Inter } from 'next/font/google';
2+
import { Roboto } from 'next/font/google';
33
import { AppRouterCacheProvider } from '@mui/material-nextjs/v14-appRouter';
44
import { AppThemeProvider } from '@/theme';
55
import { LayoutProps } from '@/types';
66
import './globals.css';
77

8-
const inter = Inter({ subsets: ['latin'] });
8+
const roboto = Roboto({
9+
weight: ['300', '400', '500', '700'],
10+
subsets: ['latin'],
11+
display: 'swap',
12+
variable: '--my-font-family',
13+
});
914
const defaultTitle = 'NextJs App';
1015

1116
export const metadata: Metadata = {
@@ -19,7 +24,7 @@ export const metadata: Metadata = {
1924
const RootLayout = ({ children }: LayoutProps) => {
2025
return (
2126
<html lang="en">
22-
<body className={inter.className}>
27+
<body className={roboto.variable}>
2328
<AppRouterCacheProvider options={{ key: 'mui' }}>
2429
<AppThemeProvider>
2530
{children}

0 commit comments

Comments
 (0)