MediaWiki:Common.css:修订间差异
跳转到导航
跳转到搜索
Xingwangzhe(留言 | 贡献) 无编辑摘要 |
Xingwangzhe(留言 | 贡献) 无编辑摘要 |
||
第7行: | 第7行: | ||
display: inline-block; | display: inline-block; | ||
padding-bottom: 2px; /* 为下划线留出空间 */ | padding-bottom: 2px; /* 为下划线留出空间 */ | ||
transition: all | transition: all 0.3s ease-in-out; /* 过渡效果 */ | ||
} | } | ||
第18行: | 第18行: | ||
height: 1px; /* 下划线高度 */ | height: 1px; /* 下划线高度 */ | ||
background: #D3D3D3; /* 灰白色 */ | background: #D3D3D3; /* 灰白色 */ | ||
transition: all | transition: all 0.3s ease-in-out; /* 过渡效果 */ | ||
text-decoration: none; | |||
} | } | ||
a:hover::after{ | a:hover::after{ | ||
text-decoration: none; | |||
left: 0; | left: 0; | ||
right: 0; | right: 0; | ||
} | } |
2024年12月17日 (二) 20:06的版本
/* 这里放置的CSS将应用于所有皮肤 */ a{ position: relative; cursor: pointer; text-decoration: none; /* 去除默认的下划线 */ display: inline-block; padding-bottom: 2px; /* 为下划线留出空间 */ transition: all 0.3s ease-in-out; /* 过渡效果 */ } a::after{ content: ''; position: absolute; left: 50%; right: 50%; bottom: 0; height: 1px; /* 下划线高度 */ background: #D3D3D3; /* 灰白色 */ transition: all 0.3s ease-in-out; /* 过渡效果 */ text-decoration: none; } a:hover::after{ text-decoration: none; left: 0; right: 0; }