geido commented on code in PR #32845:
URL: https://github.com/apache/superset/pull/32845#discussion_r2024569248
##########
superset-frontend/src/components/Menu/index.tsx:
##########
@@ -86,25 +86,31 @@ const StyledNav = styled(AntdMenu)`
align-items: center;
height: 100%;
gap: 0;
+ border-bottom: 0;
+ line-height: ${theme.lineHeight};
&.antd5-menu-horizontal > .antd5-menu-item {
height: 100%;
display: flex;
align-items: center;
margin: 0;
- border-bottom: 2px solid transparent;
padding: ${theme.sizeUnit * 2}px ${theme.sizeUnit * 4}px;
- &:hover {
- background-color: ${theme.colors.primary.light5};
- border-bottom: 2px solid transparent;
- & a:after {
- opacity: 1;
- width: 100%;
- }
+ ::after {
+ content: '';
+ position: absolute;
+ width: 100%;
+ height: 2px;
+ background-color: ${theme.colors.primary.base};
Review Comment:
I believe this is what we don't want right? With this approach there is no
control over this style via the theme configuration. Isn't this supposed to be
a vanilla feature? https://ant.design/components/menu#menu-demo-horizontal
##########
superset-frontend/src/components/Menu/index.tsx:
##########
@@ -61,7 +61,7 @@ const StyledMenuItem = styled(AntdMenu.Item)`
height: 3px;
opacity: 0;
transform: translateX(-50%);
- transition: all ${({ theme }) => theme.motionDurationMid}s;
+ transition: translate ${({ theme }) => theme.motionDurationMid}s;
background-color: ${({ theme }) => theme.colorPrimary};
Review Comment:
Do we need this background color here? Can't we use vanilla?
##########
superset-frontend/src/components/Menu/index.tsx:
##########
@@ -61,7 +61,7 @@ const StyledMenuItem = styled(AntdMenu.Item)`
height: 3px;
opacity: 0;
transform: translateX(-50%);
- transition: all ${({ theme }) => theme.motionDurationMid}s;
+ transition: translate ${({ theme }) => theme.motionDurationMid}s;
Review Comment:
Yeah we can move the theme top level if we use it in multiple instances
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]