fix: 兼容 Chrome 90 前端运行环境

- 为管理端与用户中心补齐旧浏览器运行时 API 和回归测试

- 增加现代 CSS 与选择器降级,保持现有界面效果

- 固定 Chrome 90 构建目标并补充兼容依赖
This commit is contained in:
2026-07-16 14:50:06 +08:00
parent 705e0faab6
commit 27e50a7624
34 changed files with 793 additions and 60 deletions

View File

@@ -164,7 +164,7 @@
</div>
{#snippet floating()}
<div class="tf-mixed-dropdown nopan nodrag nowheel">
<div class="tf-mixed-dropdown nopan nodrag nowheel {hoveredItem?.children?.length ? 'has-secondary' : ''}">
<div class="tf-mixed-list tf-mixed-primary-list">
{#each refOptions as item}
<button class="tf-mixed-item {hoveredItem?.value === item.value ? 'active' : ''}"
@@ -391,7 +391,7 @@
}
.tf-mixed-list { display: flex; flex-direction: column; padding: 8px; overflow-y: auto; }
.tf-mixed-primary-list { width: 100%; flex-shrink: 0; background: var(--tf-bg-surface-alt); }
.tf-mixed-dropdown:has(.tf-mixed-secondary-list) .tf-mixed-primary-list { width: auto; min-width: 180px; }
.tf-mixed-dropdown.has-secondary .tf-mixed-primary-list { width: auto; min-width: 180px; }
.tf-mixed-secondary-list { min-width: 220px; background: var(--tf-bg-surface); padding: 12px; border-left: 1px solid var(--tf-bg-muted); animation: slideIn 0.2s ease-out; box-sizing: border-box; }
@keyframes slideIn { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: translateX(0); } }

View File

@@ -296,7 +296,7 @@
</div>
</div>
{:else}
<div class="tf-select-wrapper nopan nodrag nowheel">
<div class="tf-select-wrapper nopan nodrag nowheel {hoveredItem?.children?.length ? 'has-secondary' : ''}">
<!-- 一级列表:节点/分类 -->
<div class="tf-select-list tf-select-primary-list">
{#each items as item}
@@ -580,7 +580,7 @@
}
/* When a secondary list is open, we fix the primary list to 100% of the input's width (done via absolute positioning or just keeping it wide enough) */
.tf-select-wrapper:has(.tf-select-secondary-list) &.tf-select-primary-list {
.tf-select-wrapper.has-secondary &.tf-select-primary-list {
/* Let it take the width of the input minus borders/paddings if needed, but minWidth handles it mostly */
width: auto;
min-width: 160px;