Skip to content

Conversation

@sai6855
Copy link
Contributor

@sai6855 sai6855 commented Feb 17, 2024

@sai6855 sai6855 added package: material-ui package: codemod Specific to codemod. scope: pagination Changes related to the pagination. labels Feb 17, 2024
@mui-bot
Copy link

mui-bot commented Feb 17, 2024

@sai6855 sai6855 requested a review from DiegoAndai February 17, 2024 13:39
@sai6855 sai6855 added the docs Improvements or additions to the documentation. label Feb 17, 2024
Copy link
Member

@DiegoAndai DiegoAndai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good @sai6855!

Only have one comment.

npx @mui/codemod@latest deprecations/pagination-item-classes <path>
```

### .MuiPaginationItem-textPrimary
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should summarize all PaginationItem's composed classes deprecations into a single section. Otherwise, this file will get huge 😅. We can do:

### Composed CSS classes

The following CSS classes were deprecated:

- `.MuiPaginationItem-textPrimary` deprecated in favor of `.MuiPaginationItem-text.MuiPaginationItem-colorPrimary`
- `.MuiPaginationItem-outlinedPrimary` deprecated in favor of `.MuiPaginationItem-outlined.MuiPaginationItem-colorPrimary`
- ...

Here's an example on how to migrate:

(Example diffs for `.MuiPaginationItem-textPrimary`)

Copy link
Contributor Author

@sai6855 sai6855 Feb 20, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would remove the list to be more concise:

### Composed CSS classes

The CSS classes that composed the `variant` and `color` prop values were removed. Here's how to migrate:

(... diffs)

@sai6855 sai6855 force-pushed the pagination-item-codemode-class branch from ebfabe0 to e9656ce Compare February 20, 2024 04:26
+.MuiPaginationItem-text.MuiPaginationItem-colorSecondary
-.MuiPaginationItem-outlinedSecondary
+.MuiPaginationItem-outlined.MuiPaginationItem-colorSecondary
/>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/>

- `.MuiPaginationItem-textSecondary` deprecated in favor of `.MuiPaginationItem-text.MuiPaginationItem-colorSecondary`
- `.MuiPaginationItem-outlinedSecondary` deprecated in favor of `.MuiPaginationItem-outlined.MuiPaginationItem-colorSecondary`

Here's an example on how to migrate:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Here's an example on how to migrate:
Here's how to migrate:

@sai6855 sai6855 requested a review from DiegoAndai February 20, 2024 17:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to the documentation. package: codemod Specific to codemod. scope: pagination Changes related to the pagination.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants