我有一个带有下拉菜单的页面,它与Bootstrap 4.3.1主导航分开,用于链接到页面上的各个部分。下拉HTML为:
<a class="dropdown-item" href="#map-section">Map</a> linking to <section id="map-section"> or <target id="map-section">
页面HTML为:
<section id="map-section">
我尝试过可以想到或发现的各种CSS版本,>]
#target:before { content:""; display:block; height: 100px; /* fixed header height*/ margin: -100px 0 0; /* negative fixed header height */ }
也尝试在CSS中代替目标。链接指向该区域,但100px的高度无效。
有什么建议吗?
我有一个带有下拉菜单的页面,它与Bootstrap 4.3.1主导航分开,用于链接到页面上的各个部分。下拉HTML为:Map&...
发生两件事: