Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

issue #38825

Closed
minsekim1 opened this issue Sep 6, 2023 · 1 comment
Closed

issue #38825

minsekim1 opened this issue Sep 6, 2023 · 1 comment

Comments

@minsekim1
Copy link

Hi! 👋

Firstly, thanks for your work on this project! 🙂

Today I used patch-package to patch @mui/[email protected] for the project I'm working on.

Here is the diff that solved my problem:

diff --git a/node_modules/@mui/material/Avatar/Avatar.d.ts b/node_modules/@mui/material/Avatar/Avatar.d.ts
index 2b19c9c..a54362b 100644
--- a/node_modules/@mui/material/Avatar/Avatar.d.ts
+++ b/node_modules/@mui/material/Avatar/Avatar.d.ts
@@ -5,7 +5,9 @@ import { Theme } from '../styles';
 import { OverridableComponent, OverrideProps } from '../OverridableComponent';
 import { AvatarClasses } from './avatarClasses';
 
-export interface AvatarPropsVariantOverrides {}
+export interface AvatarPropsVariantOverrides {
+  moreProfile: true;
+}
 
 export interface AvatarTypeMap<
   AdditionalProps = {},
diff --git a/node_modules/@mui/material/Button/Button.d.ts b/node_modules/@mui/material/Button/Button.d.ts
index 1bd7dd1..6a8299e 100644
--- a/node_modules/@mui/material/Button/Button.d.ts
+++ b/node_modules/@mui/material/Button/Button.d.ts
@@ -6,7 +6,15 @@ import { ExtendButtonBase, ExtendButtonBaseTypeMap } from '../ButtonBase';
 import { OverrideProps, OverridableComponent, OverridableTypeMap } from '../OverridableComponent';
 import { ButtonClasses } from './buttonClasses';
 
-export interface ButtonPropsVariantOverrides {}
+export interface ButtonPropsVariantOverrides {
+  more: true;
+  default: true;
+  like: true;
+  mainButton: true;
+  cardButton: true;
+  select: true;
+  submit: true;
+}
 
 export interface ButtonPropsColorOverrides {}
 
diff --git a/node_modules/@mui/material/Chip/Chip.d.ts b/node_modules/@mui/material/Chip/Chip.d.ts
index 686b395..81dfb9c 100644
--- a/node_modules/@mui/material/Chip/Chip.d.ts
+++ b/node_modules/@mui/material/Chip/Chip.d.ts
@@ -5,7 +5,15 @@ import { Theme } from '..';
 import { OverridableComponent, OverrideProps } from '../OverridableComponent';
 import { ChipClasses } from './chipClasses';
 
-export interface ChipPropsVariantOverrides {}
+export interface ChipPropsVariantOverrides {
+  default: true;
+btn: true;
+none: true;
+danger: true;
+gray: true;
+menu: true;
+rect: true;
+}
 
 export interface ChipPropsSizeOverrides {}
 
diff --git a/node_modules/@mui/material/Typography/Typography.d.ts b/node_modules/@mui/material/Typography/Typography.d.ts
index 646847c..356a4ce 100644
--- a/node_modules/@mui/material/Typography/Typography.d.ts
+++ b/node_modules/@mui/material/Typography/Typography.d.ts
@@ -6,7 +6,24 @@ import { OverrideProps, OverridableComponent } from '../OverridableComponent';
 import { Variant } from '../styles/createTypography';
 import { TypographyClasses } from './typographyClasses';
 
-export interface TypographyPropsVariantOverrides {}
+export interface TypographyPropsVariantOverrides {
+  default: true;
+  profileTitle: true;
+  tableHeader: true;
+  tableContent: true;
+  subTitle: true;
+  title: true;
+  medium: true;
+  em: true;
+  desc: true;
+  large: true;
+  content: true;
+  rankGraph: true;
+  rankGraphCaption: true;
+  rating: true;
+  ratingDesc: true;
+  ratingSelect: true;
+}
 
 export interface TypographyOwnProps extends SystemProps<Theme> {
   /**

This issue body was partially generated by patch-package.

@github-actions github-actions bot added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Sep 6, 2023
@brijeshb42
Copy link
Contributor

This diff seems specific for your application. You can use typescript module augmentation as shown here to extend the types from material-ui instead of patching from node_modules.

@zannager zannager removed the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Sep 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants