fix: 进度条方向 + 宽度

- 进度条缺少 width:100%,导致 absolute 元素宽度为 0 不可见
- keyframes 改为 scaleX(0→1),从空到满增长(符合进度直觉)
This commit is contained in:
崮生(子虚) 2026-07-30 19:53:57 +08:00
parent 3af1a19dce
commit d064e9bc8f

View File

@ -122,14 +122,14 @@ onUnmounted(() => {
<span><b style="color: #333">{{ t('cacheHit') }}</b> {{ data.subsetRequests > 0 ? ((data.subsetCacheHits / data.subsetRequests) * 100).toFixed(1) : '0.0' }}%</span>
</div>
<!-- 底部进度条每轮询周期走一轮走完触发下次刷新 -->
<div :key="progressKey" style="position: absolute; bottom: 0; left: 0; height: 2px; background: #1677ff; transform-origin: left; animation: stats-progress 10s linear" />
<div :key="progressKey" style="position: absolute; bottom: 0; left: 0; width: 100%; height: 2px; background: #1677ff; transform-origin: left; animation: stats-progress 10s linear" />
</section>
</div>
</template>
<style>
@keyframes stats-progress {
from { transform: scaleX(1); }
to { transform: scaleX(0); }
from { transform: scaleX(0); }
to { transform: scaleX(1); }
}
</style>