有人可以向我解释一下,当下一个项目激活时,如何使CSS幻灯片中的x溢出的步指示器左移。我需要在小型设备上使用。在大屏幕上还可以。
/*Current CSS:*/
@media only screen and (max-width: 600px){
.test-step-indicator{
font-size: 1em;
display: flex;
overflow-x: overlay;
white-space: nowrap;
}
}
<div class="test-step-indicator">
<a class="test-step-indicator-item test-step-indicator-item-active" href="#" data-step="0">1. Device</a>
<a class="test-step-indicator-item test-step-indicator-item-active" href="#" data-step="1">2. Brand</a>
<a class="test-step-indicator-item" href="#" test-data-step="2">3. Phone</a>
<a class="test-step-indicator-item" href="#" test-data-step="3">4. Repairs</a>
<a class="test-step-indicator-item" href="#" test-data-step="4">5. Service</a>
<a class="test-step-indicator-item" href="#" test-data-step="5">6. Details</a>
</div>