Rename ItemContents prop to Item

This commit is contained in:
Tom Southall
2022-03-04 15:10:02 +00:00
parent 7432818a22
commit ca39af8cc0
3 changed files with 3 additions and 3 deletions

View File

@@ -86,7 +86,7 @@ const App = () => {
Cancel={CancelButton} Cancel={CancelButton}
Clear={ClearButton} Clear={ClearButton}
GroupName={GroupName} GroupName={GroupName}
ItemContents={ItemContents} Item={ItemContents}
/> />
</div> </div>
</main> </main>

View File

@@ -13,7 +13,7 @@ export default function Item(props) {
} = useContext(StateContext) } = useContext(StateContext)
const { customStyles, highlighted, query } = state const { customStyles, highlighted, query } = state
const ItemContents = state.props.ItemContents const ItemContents = state.props.Item
const globalMatch = item.searchType === 'contains' const globalMatch = item.searchType === 'contains'
const isHighlighted = highlighted && index === highlighted.index const isHighlighted = highlighted && index === highlighted.index

View File

@@ -114,7 +114,7 @@ Turnstone.propTypes = {
text: PropTypes.string, text: PropTypes.string,
Cancel: PropTypes.elementType, Cancel: PropTypes.elementType,
Clear: PropTypes.elementType, Clear: PropTypes.elementType,
ItemContents: PropTypes.elementType, Item: PropTypes.elementType,
GroupName: PropTypes.elementType GroupName: PropTypes.elementType
} }