Skip to content

Commit

Permalink
CardOwnProps inherits PaperOwnProps
Browse files Browse the repository at this point in the history
  • Loading branch information
aerialist7 committed Feb 11, 2024
1 parent 9fc5ab7 commit 1424f7e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
3 changes: 3 additions & 0 deletions buildSrc/src/main/kotlin/karakum/mui/Converter.kt
Original file line number Diff line number Diff line change
Expand Up @@ -757,6 +757,9 @@ private fun MutableList<String>.tryToAddInheritanceInterfaces(
if (propsName == "CardActionAreaOwnProps")
this += "ButtonBaseProps"

if (propsName == "CardOwnProps")
this += "PaperOwnProps"

if (propsName == "CardHeaderOwnProps")
this += INTRINSIC_TYPE_MAP.getValue("div")

Expand Down
2 changes: 1 addition & 1 deletion buildSrc/src/main/kotlin/karakum/mui/KotlinType.kt
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ private val STANDARD_TYPE_MAP = mapOf(
"Any /* <ExternalProps extends Record<string, unknown> = {}>(externalProps?: ExternalProps) => UseMenuButtonRootSlotProps<ExternalProps> */",

"StateChangeCallback<State>" to "Any /* StateChangeCallback<State> */",
"PopupProps['anchorEl']" to "Any /* PopupProps['anchorEl'] */",
"PopupProps['anchor']" to "Any /* PopupProps['anchor'] */",
)

internal fun kotlinType(
Expand Down
4 changes: 3 additions & 1 deletion mui-kotlin/src/jsMain/kotlin/mui/material/Card.kt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ external interface CardProps :
react.dom.html.HTMLAttributes<web.html.HTMLDivElement>,
mui.types.PropsWithComponent

external interface CardOwnProps : mui.system.PropsWithSx {
external interface CardOwnProps :
mui.system.PropsWithSx,
PaperOwnProps {
/**
* Override or extend the styles applied to the component.
*/
Expand Down

0 comments on commit 1424f7e

Please sign in to comment.