Preview: add UI V2 mode with grid, filters, sort, and toasts
This commit is contained in:
201
styles.css
201
styles.css
@@ -8,6 +8,9 @@
|
||||
--danger: #bf2f47;
|
||||
--border: #d6dde6;
|
||||
--shadow: 0 10px 24px rgba(17, 36, 57, 0.08);
|
||||
--v2-primary: #6c5ce7;
|
||||
--v2-success: #00b894;
|
||||
--v2-bg: #f8f9fa;
|
||||
}
|
||||
|
||||
* {
|
||||
@@ -519,7 +522,201 @@ button {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.v2-sticky {
|
||||
position: sticky;
|
||||
top: 0.55rem;
|
||||
z-index: 20;
|
||||
background: linear-gradient(130deg, #f2eeff, #edf7f4);
|
||||
border: 1px solid #d8d8ea;
|
||||
border-radius: 14px;
|
||||
padding: 0.55rem 0.7rem;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.7rem;
|
||||
}
|
||||
|
||||
.v2-sticky-title {
|
||||
font-weight: 700;
|
||||
color: #2f2a66;
|
||||
}
|
||||
|
||||
.v2-sticky-count {
|
||||
font-size: 0.88rem;
|
||||
color: #3c4e61;
|
||||
}
|
||||
|
||||
.v2-sticky-actions {
|
||||
margin-left: auto;
|
||||
display: flex;
|
||||
gap: 0.45rem;
|
||||
}
|
||||
|
||||
.v2-toolbar {
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 12px;
|
||||
background: #f8fbff;
|
||||
padding: 0.7rem;
|
||||
margin-bottom: 0.8rem;
|
||||
display: grid;
|
||||
gap: 0.55rem;
|
||||
grid-template-columns: repeat(4, minmax(0, 1fr));
|
||||
}
|
||||
|
||||
.v2-toolbar select {
|
||||
width: 100%;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 10px;
|
||||
padding: 0.62rem 0.65rem;
|
||||
font-family: inherit;
|
||||
font-size: 0.95rem;
|
||||
}
|
||||
|
||||
.game-badges {
|
||||
margin: 0.4rem 0 0;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 0.33rem;
|
||||
}
|
||||
|
||||
.genre-badge {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
padding: 0.2rem 0.5rem;
|
||||
border-radius: 999px;
|
||||
font-size: 0.73rem;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.01em;
|
||||
border: 1px solid transparent;
|
||||
}
|
||||
|
||||
.genre-badge.default {
|
||||
background: #e8eef8;
|
||||
color: #234361;
|
||||
border-color: #d4dfed;
|
||||
}
|
||||
|
||||
.genre-badge.rpg {
|
||||
background: #efe7ff;
|
||||
color: #4f2f9a;
|
||||
border-color: #ddccff;
|
||||
}
|
||||
|
||||
.genre-badge.action {
|
||||
background: #ffe9ec;
|
||||
color: #a23649;
|
||||
border-color: #ffd2d9;
|
||||
}
|
||||
|
||||
.genre-badge.sport {
|
||||
background: #e6fbf4;
|
||||
color: #146c57;
|
||||
border-color: #c7f2e4;
|
||||
}
|
||||
|
||||
.genre-badge.racing {
|
||||
background: #fff4df;
|
||||
color: #9c6515;
|
||||
border-color: #ffe6b9;
|
||||
}
|
||||
|
||||
.toast-container {
|
||||
position: fixed;
|
||||
right: 1rem;
|
||||
bottom: 1rem;
|
||||
z-index: 80;
|
||||
display: grid;
|
||||
gap: 0.45rem;
|
||||
}
|
||||
|
||||
.toast {
|
||||
min-width: 220px;
|
||||
max-width: 360px;
|
||||
border-radius: 10px;
|
||||
border: 1px solid #d7e0ec;
|
||||
background: #ffffff;
|
||||
color: #1d2f44;
|
||||
padding: 0.58rem 0.7rem;
|
||||
box-shadow: var(--shadow);
|
||||
font-size: 0.88rem;
|
||||
}
|
||||
|
||||
.toast.success {
|
||||
border-color: #bdecd8;
|
||||
background: #eefbf5;
|
||||
}
|
||||
|
||||
.toast.error {
|
||||
border-color: #ffd1da;
|
||||
background: #fff1f4;
|
||||
}
|
||||
|
||||
body.ui-v2 {
|
||||
background: radial-gradient(circle at top right, #efeaff 0, transparent 34%), var(--v2-bg);
|
||||
}
|
||||
|
||||
body.ui-v2 .games-list {
|
||||
grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
|
||||
}
|
||||
|
||||
body.ui-v2 .game-card {
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
gap: 0.55rem;
|
||||
transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
|
||||
}
|
||||
|
||||
body.ui-v2 .game-card:hover {
|
||||
transform: translateY(-2px);
|
||||
border-color: #d3cef9;
|
||||
box-shadow: 0 12px 24px rgba(50, 50, 93, 0.14);
|
||||
}
|
||||
|
||||
body.ui-v2 .game-cover {
|
||||
width: 72px;
|
||||
height: 98px;
|
||||
}
|
||||
|
||||
body.ui-v2 .game-actions {
|
||||
width: 100%;
|
||||
grid-template-columns: repeat(3, minmax(0, 1fr));
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
body.ui-v2 {
|
||||
background: #10141a;
|
||||
color: #e8edf6;
|
||||
}
|
||||
|
||||
body.ui-v2 .panel,
|
||||
body.ui-v2 .hero,
|
||||
body.ui-v2 .v2-toolbar,
|
||||
body.ui-v2 .v2-sticky,
|
||||
body.ui-v2 .game-card,
|
||||
body.ui-v2 .search-zone,
|
||||
body.ui-v2 .scanner-zone {
|
||||
background: #161d26;
|
||||
border-color: #2b3747;
|
||||
}
|
||||
|
||||
body.ui-v2 .btn-secondary,
|
||||
body.ui-v2 .btn-inline {
|
||||
background: #2a3647;
|
||||
color: #dbe5f2;
|
||||
}
|
||||
|
||||
body.ui-v2 input,
|
||||
body.ui-v2 select {
|
||||
background: #10161f;
|
||||
border-color: #314157;
|
||||
color: #e7eef8;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 900px) {
|
||||
.v2-toolbar {
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
}
|
||||
|
||||
.grid-form,
|
||||
.game-form {
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
@@ -532,6 +729,10 @@ button {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
|
||||
.v2-toolbar {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
|
||||
.tools-toggle-btn {
|
||||
top: auto;
|
||||
bottom: 1rem;
|
||||
|
||||
Reference in New Issue
Block a user