-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
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
[List] extract button from ListItem to ListItemButton #26446
Merged
Merged
Changes from 30 commits
Commits
Show all changes
44 commits
Select commit
Hold shift + click to select a range
e4f684d
add wip ListItemButton
siriwatknp a0d6928
update lists docs to use ListItemButton
siriwatknp 41b248b
run proptypes and docs
siriwatknp ae4db46
fix typo name
siriwatknp f047a2c
minor fix
siriwatknp 8fb85ca
mark button related prop as deprecated
siriwatknp 3f46f02
fix description
siriwatknp 4f385a9
add usage guide to docs
siriwatknp 83eadf9
add dense note
siriwatknp 1678d53
Update docs/src/pages/components/lists/lists.md
siriwatknp 8941802
Merge branch 'next' of https://github.com/mui-org/material-ui into fe…
siriwatknp 43a0f75
add `action` prop and update demos
siriwatknp aeb3eb3
run proptypes, docs:api, docs:typescript
siriwatknp 4edef7d
add customized demo and theme component props
siriwatknp 4f931d0
update demo
siriwatknp 9c49711
refactor ListItem.d.ts
siriwatknp 6b1e037
add disablePadding prop
siriwatknp 7040bcc
update demo to use disablePadding
siriwatknp 0884aa6
follow disablePadding in List
siriwatknp 36ff3d1
rename `action` to `secondaryAction` due to type conflict with Button…
siriwatknp fce2d50
minor fix
siriwatknp 7613961
Merge branch 'next' of https://github.com/mui-org/material-ui into fe…
siriwatknp eb95812
cleanup
siriwatknp c26f233
Merge branch 'next' of https://github.com/mui-org/material-ui into fe…
siriwatknp 3ee7f40
fix types
siriwatknp 2584c80
fix
siriwatknp ba68a1b
fix markdown contrast color
siriwatknp cbf07f6
Update docs/src/pages/components/lists/CustomizedList.tsx
siriwatknp adda4fe
Update packages/material-ui/src/ListItemButton/listItemButtonClasses.ts
siriwatknp 5cbbb72
Update packages/material-ui/src/ListItemButton/ListItemButton.js
siriwatknp 5c6928f
Update packages/material-ui/src/ListItem/ListItem.js
siriwatknp b151863
revert the code
siriwatknp e7cad0a
sort props
siriwatknp 01b7c69
fix li semantic error
siriwatknp 9bf7c49
Merge branch 'feat/list-item-improvement' of github.com:siriwatknp/ma…
siriwatknp d76b830
run prettier
siriwatknp 002dd5f
run docs:formatted
siriwatknp c8f8990
run docs:api
siriwatknp 84c3766
fix Inset demo
siriwatknp 0f13f5f
Update packages/material-ui/src/ListItemButton/ListItemButton.js
siriwatknp 6e8431a
Update packages/material-ui/src/ListItemButton/listItemButtonClasses.ts
siriwatknp 4ba8d1c
move role undefined to ListItemButton
siriwatknp e0bffb4
run docs:api
siriwatknp 0195818
fix as suggested
siriwatknp File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import * as React from 'react'; | ||
import ApiPage from 'docs/src/modules/components/ApiPage'; | ||
import mapApiPageTranslations from 'docs/src/modules/utils/mapApiPageTranslations'; | ||
import jsonPageContent from './list-item-button.json'; | ||
|
||
export default function Page(props) { | ||
const { descriptions, pageContent } = props; | ||
return <ApiPage descriptions={descriptions} pageContent={pageContent} />; | ||
} | ||
|
||
Page.getInitialProps = () => { | ||
const req = require.context( | ||
'docs/translations/api-docs/list-item-button', | ||
false, | ||
/list-item-button.*.json$/, | ||
); | ||
const descriptions = mapApiPageTranslations(req); | ||
|
||
return { | ||
descriptions, | ||
pageContent: jsonPageContent, | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
{ | ||
"props": { | ||
"alignItems": { | ||
"type": { "name": "enum", "description": "'center'<br>| 'flex-start'" }, | ||
"default": "'center'" | ||
}, | ||
"autoFocus": { "type": { "name": "bool" } }, | ||
"children": { "type": { "name": "node" } }, | ||
"classes": { "type": { "name": "object" } }, | ||
"component": { "type": { "name": "elementType" } }, | ||
"dense": { "type": { "name": "bool" } }, | ||
"disabled": { "type": { "name": "bool" } }, | ||
"disableGutters": { "type": { "name": "bool" } }, | ||
"divider": { "type": { "name": "bool" } }, | ||
"focusVisibleClassName": { "type": { "name": "string" } }, | ||
"selected": { "type": { "name": "bool" } }, | ||
"sx": { "type": { "name": "object" } } | ||
}, | ||
"name": "ListItemButton", | ||
"styles": { | ||
"classes": [ | ||
"root", | ||
"focusVisible", | ||
"dense", | ||
"alignItemsFlexStart", | ||
"disabled", | ||
"divider", | ||
"gutters", | ||
"selected" | ||
], | ||
"globalClasses": { | ||
"focusVisible": "Mui-focusVisible", | ||
"disabled": "Mui-disabled", | ||
"selected": "Mui-selected" | ||
}, | ||
"name": "MuiListItemButton" | ||
}, | ||
"spread": true, | ||
"forwardsRefTo": "HTMLDivElement", | ||
"filename": "/packages/material-ui/src/ListItemButton/ListItemButton.js", | ||
"inheritance": null, | ||
"demos": "<ul><li><a href=\"/components/lists/\">Lists</a></li></ul>", | ||
"styledComponent": true, | ||
"cssComponent": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Its correct place is on the
ListItemButton
https://validator.w3.org/nu/?doc=https%3A%2F%2Fdeploy-preview-26446--material-ui.netlify.app%2Fcomponents%2Flists%2F