Skip to content

Commit 42b4395

Browse files
fix(docs): update VariantItem link implementation and separate CLI version docs Closes npm/cli#8414
1 parent b1878b0 commit 42b4395

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

src/components/variant-select.js

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,16 @@ const StyledOverlay = styled(ActionMenu.Overlay)`
1414
box-shadow: var(--shadow-resting-medium, 0 3px 6px rgba(140, 149, 159, 0.15));
1515
`
1616

17-
const VariantItem = ({title, shortName, url, active}) => (
18-
<ActionList.Item as={LinkNoUnderline} to={url} state={{scrollUpdate: false}} id={shortName} active={active}>
19-
{title}
20-
</ActionList.Item>
21-
)
17+
const VariantItem = ({title, shortName, url, active}) => {
18+
return (
19+
<ActionList.Item state= {{scrollUpdate: false}} id={shortName} active={active}>
20+
<LinkNoUnderline
21+
to={url}
22+
>
23+
{title}
24+
</LinkNoUnderline>
25+
</ActionList.Item>)
26+
}
2227

2328
const useVariantFocus = () => {
2429
const locationChange = useLocationChange()

0 commit comments

Comments
 (0)