mui / mui/material-ui

Allow custom transition props in MUI transitions components

Open
#36,065 1 comment 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

scope: transitions support: question
Dominant language
JavaScript
Stars
99.1k
Forks
32.5k
Avg merge
2d 17h
Merged PRs (30d)
106

Description

Duplicates
  • I have searched the existing issues
Latest version
  • I have tested the latest version
Summary 💡

Hey folks,
How can I add custom transition styles to existing implementation of MUI Transition components (Fade, Collapse etc)

After reading the docs around the same, I inferred that the MUI Transition components are built upon react-transition-group which provide a flexibility to add styles depending upon the transition state (entering,exiting), but these are not exposed by MUI?

How can I achieve the same by adding some sort of prop in MUI Transition components?

Examples 🌈

I got a stackoverflow thread around the same but with mui v5 it complains about the ref about being null - https://stackoverflow.com/questions/49323091/create-custom-transition-in-material-ui-next

Motivation 🔦

Adding custom transition style provides a flexibility by overriding the existing style of Fade component.
(Suppose, I want to add a tansform: translate3d(x,y,z)) styles to my Fade component.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the existing Fade and Collapse APIs and compare their documented behavior with react-transition-group's transition states. A complete change would need a defined way to provide custom transition styles, address the reported ref behavior, and document the supported usage.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react
Domain
frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.