From c2c86928c535221dc7c4a074331edb7f75b9ef20 Mon Sep 17 00:00:00 2001 From: Zyy Date: Sun, 30 Aug 2026 05:40:31 +0800 Subject: [PATCH] fix(frontend): refine responsive interface states Co-authored-by: Codex --- frontend/src/components/base/BaseInput.vue | 27 ++++++++++++++++--- .../components/FloatingSidebarToggle.vue | 4 +-- .../accounts/components/AccountFilters.vue | 24 +++++++++-------- .../src/views/login/components/LoginPanel.vue | 9 +++---- .../views/usage/components/UsageCostCard.vue | 2 +- .../usage/components/UsageDetailFieldGrid.vue | 2 +- .../usage/components/UsageHealthCard.vue | 2 +- .../usage/components/UsagePerformanceCard.vue | 2 +- .../components/UsageRecordDetailModal.vue | 14 +++++----- 9 files changed, 54 insertions(+), 32 deletions(-) diff --git a/frontend/src/components/base/BaseInput.vue b/frontend/src/components/base/BaseInput.vue index 7d8e74d5b..403c86ab4 100644 --- a/frontend/src/components/base/BaseInput.vue +++ b/frontend/src/components/base/BaseInput.vue @@ -52,7 +52,7 @@ const sizeClasses: Record = { } const containerClasses = computed(() => [ - 'relative inline-flex w-full min-w-0 items-center overflow-visible rounded-cp border-0 text-cp-text shadow-cp-input transition-[background-color,box-shadow,color] duration-[160ms] [--base-input-autofill-bg:var(--cp-input-bg)] hover:[--base-input-autofill-bg:var(--cp-input-hover-bg)] focus-within:[--base-input-autofill-bg:var(--cp-input-active-bg)] motion-reduce:transition-none', + 'relative inline-flex w-full min-w-0 items-center overflow-visible rounded-cp border-0 text-cp-text shadow-cp-input transition-[background-color,box-shadow,color] duration-[160ms] motion-reduce:transition-none', sizeClasses[props.size], props.disabled ? 'cursor-not-allowed bg-cp-bg-container-disabled text-cp-text-disabled shadow-none' @@ -73,6 +73,11 @@ const iconClasses = computed(() => [ function updateModel(event: Event) { model.value = (event.target as HTMLInputElement).value } + +function syncAutofill(event: AnimationEvent) { + if (event.animationName === 'base-input-autofill-sync') + updateModel(event) +}