From 9f3dd29f2b69445a1d438d42d916821af1be2821 Mon Sep 17 00:00:00 2001 From: ZeeshanTamboli Date: Wed, 6 Sep 2023 19:18:49 +0530 Subject: [PATCH] rename method name and type --- packages/mui-material/src/ButtonGroup/ButtonGroup.js | 4 ++-- .../src/ButtonGroup/ButtonGroupButtonContext.ts | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/mui-material/src/ButtonGroup/ButtonGroup.js b/packages/mui-material/src/ButtonGroup/ButtonGroup.js index 4e63d0accda3a2..bed6b946a25d5e 100644 --- a/packages/mui-material/src/ButtonGroup/ButtonGroup.js +++ b/packages/mui-material/src/ButtonGroup/ButtonGroup.js @@ -256,7 +256,7 @@ const ButtonGroup = React.forwardRef(function ButtonGroup(inProps, ref) { ], ); - const addButtonGroupButtonContextPositionClassName = (index, childrenParam) => { + const getButtonPositionClassName = (index, childrenParam) => { const isFirstButton = index === 0; const isLastButton = index === React.Children.count(childrenParam) - 1; @@ -289,7 +289,7 @@ const ButtonGroup = React.forwardRef(function ButtonGroup(inProps, ref) { return ( {child} diff --git a/packages/mui-material/src/ButtonGroup/ButtonGroupButtonContext.ts b/packages/mui-material/src/ButtonGroup/ButtonGroupButtonContext.ts index 18f4c4c7e13407..8a93fe171954ef 100644 --- a/packages/mui-material/src/ButtonGroup/ButtonGroupButtonContext.ts +++ b/packages/mui-material/src/ButtonGroup/ButtonGroupButtonContext.ts @@ -1,13 +1,13 @@ import * as React from 'react'; -type ButtonGroupButtonContextClassNameValue = string; +type ButtonPositionClassName = string; /** * @ignore - internal component. */ -const ButtonGroupButtonContext = React.createContext< - ButtonGroupButtonContextClassNameValue | undefined ->(undefined); +const ButtonGroupButtonContext = React.createContext( + undefined, +); if (process.env.NODE_ENV !== 'production') { ButtonGroupButtonContext.displayName = 'ButtonGroupButtonContext';