diff --git a/perler-lab/src/components/BeadSettlementModal.tsx b/perler-lab/src/components/BeadSettlementModal.tsx index e320f7f..76a8552 100644 --- a/perler-lab/src/components/BeadSettlementModal.tsx +++ b/perler-lab/src/components/BeadSettlementModal.tsx @@ -184,7 +184,9 @@ export default function BeadSettlementModal({ onClick={onClose} aria-label={t('modal.close')} > - ✕ + diff --git a/perler-lab/src/pages/MyBeadsPage.tsx b/perler-lab/src/pages/MyBeadsPage.tsx index dbacd4f..ea96e35 100644 --- a/perler-lab/src/pages/MyBeadsPage.tsx +++ b/perler-lab/src/pages/MyBeadsPage.tsx @@ -333,7 +333,9 @@ function AddBeadsModal({ open, onClose, onAdd }: AddBeadsModalProps) {
{t('beads.add.title')}
diff --git a/perler-lab/src/pages/beads.css b/perler-lab/src/pages/beads.css index 085c4ae..37f44ae 100644 --- a/perler-lab/src/pages/beads.css +++ b/perler-lab/src/pages/beads.css @@ -441,9 +441,10 @@ display: flex; align-items: center; justify-content: center; - background: rgba(23, 23, 19, .5); + background: rgba(31, 29, 23, 0.45); backdrop-filter: blur(2px); padding: var(--space-4); + animation: mask-in var(--dur-med) ease both; } .bd-modal { @@ -455,8 +456,10 @@ background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); - box-shadow: 0 8px 32px rgba(23, 23, 19, .16); + box-shadow: var(--shadow-modal); overflow: hidden; + transform-origin: center; + animation: modal-in var(--dur-med) var(--ease-out) both; } .bd-modal-header { @@ -905,4 +908,48 @@ .bd-replace-grid { grid-template-columns: repeat(5, 1fr); } -} \ No newline at end of file +} +/* ============================================================ + v2.0 八态补齐 (DESIGN.md §3.0/§3.1) + ============================================================ */ +.bd-empty-btn, +.bd-modal-btn, +.bd-add-popup-btn, +.bd-bottle-add, +.bd-settings-btn, +.bd-modal-replace-btn { + transition: background var(--dur-fast) ease, border-color var(--dur-fast) ease, + color var(--dur-fast) ease, transform var(--dur-fast) var(--ease-out); +} + +.bd-empty-btn:active, +.bd-modal-btn:active, +.bd-add-popup-btn:active, +.bd-bottle-add:active, +.bd-settings-btn:active, +.bd-modal-replace-btn:active { + transform: scale(0.97); +} + +.bd-empty-btn:focus-visible, +.bd-modal-btn:focus-visible, +.bd-add-popup-btn:focus-visible, +.bd-bottle-add:focus-visible, +.bd-settings-btn:focus-visible, +.bd-modal-replace-btn:focus-visible, +.bd-modal-close:focus-visible { + outline: none; + box-shadow: var(--focus-ring); +} + +.bd-add-input:focus, +.bd-add-popup-input:focus { + outline: none; + border-color: var(--accent); + box-shadow: var(--focus-ring); +} + +.bd-add-input::placeholder, +.bd-add-popup-input::placeholder { + color: var(--text-disabled); +} diff --git a/perler-lab/src/styles.css b/perler-lab/src/styles.css index e1e529f..fa3fca6 100644 --- a/perler-lab/src/styles.css +++ b/perler-lab/src/styles.css @@ -1787,3 +1787,32 @@ a:focus-visible { scroll-behavior: auto !important; } } + +/* ============================================================ + 列表进场 stagger (DESIGN.md v2.0 §3.8) + 仅元素首次挂载播放;翻页/筛选保留挂载的不重播 + ============================================================ */ +@keyframes stagger-in { + to { + opacity: 1; + transform: translateY(0); + } +} + +.sw-grid > *, +.lib-list > *, +.bd-grid > * { + opacity: 0; + transform: translateY(8px); + animation: stagger-in var(--dur-slow) var(--ease-out) forwards; +} + +.sw-grid > *:nth-child(1), .lib-list > *:nth-child(1), .bd-grid > *:nth-child(1) { animation-delay: 0ms; } +.sw-grid > *:nth-child(2), .lib-list > *:nth-child(2), .bd-grid > *:nth-child(2) { animation-delay: 40ms; } +.sw-grid > *:nth-child(3), .lib-list > *:nth-child(3), .bd-grid > *:nth-child(3) { animation-delay: 80ms; } +.sw-grid > *:nth-child(4), .lib-list > *:nth-child(4), .bd-grid > *:nth-child(4) { animation-delay: 120ms; } +.sw-grid > *:nth-child(5), .lib-list > *:nth-child(5), .bd-grid > *:nth-child(5) { animation-delay: 160ms; } +.sw-grid > *:nth-child(6), .lib-list > *:nth-child(6), .bd-grid > *:nth-child(6) { animation-delay: 200ms; } +.sw-grid > *:nth-child(7), .lib-list > *:nth-child(7), .bd-grid > *:nth-child(7) { animation-delay: 240ms; } +.sw-grid > *:nth-child(8), .lib-list > *:nth-child(8), .bd-grid > *:nth-child(8) { animation-delay: 280ms; } +.sw-grid > *:nth-child(n+9), .lib-list > *:nth-child(n+9), .bd-grid > *:nth-child(n+9) { animation-delay: 320ms; }