Skip to content
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

[website] Make beta chip consistent for Toolpad #43392

Merged
merged 2 commits into from
Aug 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 33 additions & 7 deletions docs/src/components/header/HeaderNavBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,15 +111,24 @@ const ProductSubMenu = React.forwardRef<HTMLAnchorElement, ProductSubMenuProps>(
{...props}
>
<Box sx={{ px: 2 }}>{icon}</Box>
<Box sx={{ flexGrow: 1 }}>
<Typography variant="body2" sx={{ color: 'text.primary', fontWeight: 'bold' }}>
{name}
</Typography>
<div style={{ flexGrow: 1 }}>
<div
style={{
display: 'flex',
flexDirection: 'row',
alignItems: 'center',
gap: '0.5rem',
}}
>
<Typography variant="body2" sx={{ color: 'text.primary', fontWeight: 'bold' }}>
{name}
</Typography>
{chip}
</div>
<Typography variant="body2" sx={{ color: 'text.secondary' }}>
{description}
</Typography>
</Box>
{chip}
</div>
</Box>
);
},
Expand Down Expand Up @@ -303,7 +312,24 @@ export default function HeaderNavBar() {
href={ROUTES.productToolpad}
icon={<IconImage name="product-toolpad" />}
name="Toolpad"
chip={<Chip label="Beta" size="small" color="primary" variant="outlined" />}
chip={
<Chip
label="Beta"
size="small"
color="primary"
variant="outlined"
sx={{
fontSize: '.625rem',
fontWeight: 'semiBold',
textTransform: 'uppercase',
letterSpacing: '.04rem',
height: '16px',
'& .MuiChip-label': {
px: '4px',
},
}}
/>
}
description="Components and tools for dashboards and internal apps."
/>
</li>
Expand Down
20 changes: 20 additions & 0 deletions docs/src/components/header/HeaderNavDropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,16 @@ export default function HeaderNavDropdown() {
label={item.chip}
color="primary"
variant="outlined"
sx={{
fontSize: '.625rem',
fontWeight: 'semiBold',
textTransform: 'uppercase',
letterSpacing: '.04rem',
height: '16px',
'& .MuiChip-label': {
px: '4px',
},
}}
/>
) : null}
</Box>
Expand Down Expand Up @@ -280,6 +290,16 @@ export default function HeaderNavDropdown() {
label={item.chip}
color="primary"
variant="outlined"
sx={{
fontSize: '.625rem',
fontWeight: 'semiBold',
textTransform: 'uppercase',
letterSpacing: '.04rem',
height: '16px',
'& .MuiChip-label': {
px: '4px',
},
}}
/>
) : null}
</Box>
Expand Down