关于前端:antd-menu-样式修改

记录一下antd 中,table 款式批改, 不便大家疾速应用
基本上依照以下代码批改相应色彩即可

// 设置菜单款式
.ant-menu,.ant-menu-sub,.ant-menu-inline{
  color: white;
  background-color: #044d50 !important;
}
// 设置子菜单开展款式
.ant-menu-submenu > .ant-menu {
  background-color: rgb(16, 71, 83) !important;
}
.ant-menu-submenu-title{
  color: white !important;
}
// 去掉左边框
.ant-menu-inline {
  border: none;
}
// 设置 a 链接款式
.ant-menu-item a {
  color: white !important;
}
.ant-menu-item a:hover {
  color: #044d50 !important;
}
// 下拉箭头款式
.ant-menu-submenu-arrow {
  color: white;
}
// // 设置子菜单款式
// .ant-menu-submenu-active {
//   background-color: #fff !important;
//   color: #044d50 !important;
// }

// 选中菜单状态
.ant-menu-item-selected {
  background-color: rgb(4,77,92) !important;
  color: white !important;
}
// 设置未选中菜单项鼠标滑过款式
.ant-menu-item-active {
  background-color: #fff !important;
  color: #666666 !important;
}


切记:

.ant-menu-item-selected 和  .ant-menu-item-active 先后顺便不能乱, 否则点击菜单后款式错乱

评论

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

这个站点使用 Akismet 来减少垃圾评论。了解你的评论数据如何被处理