feat: polish Mine Map UX
This commit is contained in:
1 parent
d06ee7bcc6
commit
06ed8248f5
5 files changed
+383
-90
No files matched your search
@@ -756,7 +756,7 @@ tbody tr:last-child td {
|
||||
|
||||
/* Mine Map v1 */
|
||||
.map-context {
|
||||
padding: 15px;
|
||||
padding: 10px 12px;
|
||||
border: 1px solid var(--line);
|
||||
background: var(--surface);
|
||||
}
|
||||
@@ -767,32 +767,76 @@ tbody tr:last-child td {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
gap: 16px;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.map-context h2,
|
||||
.map-inspector-v1 h2,
|
||||
.unplaced-section h2 {
|
||||
margin: 0;
|
||||
font-size: 17px;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
.map-control-grid {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(150px, .8fr) minmax(150px, .8fr)
|
||||
minmax(170px, .9fr) minmax(220px, 1.4fr);
|
||||
gap: 10px;
|
||||
margin-top: 14px;
|
||||
grid-template-columns: minmax(130px, .8fr) minmax(130px, .8fr)
|
||||
minmax(150px, .9fr) minmax(190px, 1.35fr) auto;
|
||||
align-items: end;
|
||||
gap: 7px;
|
||||
margin-top: 7px;
|
||||
}
|
||||
|
||||
.map-context .field {
|
||||
gap: 3px;
|
||||
}
|
||||
|
||||
.map-context .field label {
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
.map-context select,
|
||||
.map-context input[type="search"] {
|
||||
min-height: 36px;
|
||||
padding-top: 6px;
|
||||
padding-bottom: 6px;
|
||||
}
|
||||
|
||||
.map-problems-control {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 7px;
|
||||
min-height: 36px;
|
||||
padding: 6px 9px;
|
||||
border: 1px solid #9aa6b1;
|
||||
border-radius: 4px;
|
||||
background: #f8fafb;
|
||||
color: #263442;
|
||||
font-size: 12px;
|
||||
font-weight: 750;
|
||||
cursor: pointer;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.map-problems-control input {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
margin: 0;
|
||||
accent-color: #176b9a;
|
||||
}
|
||||
|
||||
.map-problems-control:has(input:checked) {
|
||||
border-color: #176b9a;
|
||||
background: #edf7fb;
|
||||
}
|
||||
|
||||
.map-filters {
|
||||
margin-top: 12px;
|
||||
margin-top: 7px;
|
||||
border-top: 1px solid #e3e8ed;
|
||||
padding-top: 10px;
|
||||
padding-top: 5px;
|
||||
}
|
||||
|
||||
.map-filters summary {
|
||||
min-height: 36px;
|
||||
min-height: 28px;
|
||||
cursor: pointer;
|
||||
color: #334252;
|
||||
font-size: 13px;
|
||||
@@ -803,7 +847,7 @@ tbody tr:last-child td {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, minmax(135px, 1fr)) auto;
|
||||
align-items: end;
|
||||
gap: 10px;
|
||||
gap: 7px;
|
||||
}
|
||||
|
||||
.map-filter-grid .quiet-button,
|
||||
@@ -815,7 +859,7 @@ tbody tr:last-child td {
|
||||
|
||||
.map-status-band {
|
||||
align-items: flex-start;
|
||||
margin: 12px 0;
|
||||
margin: 7px 0;
|
||||
}
|
||||
|
||||
.map-summary,
|
||||
@@ -843,7 +887,7 @@ tbody tr:last-child td {
|
||||
|
||||
.mine-map-workspace {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) 320px;
|
||||
grid-template-columns: minmax(0, 1fr) 300px;
|
||||
border: 1px solid var(--line);
|
||||
background: var(--surface);
|
||||
}
|
||||
@@ -860,8 +904,8 @@ tbody tr:last-child td {
|
||||
}
|
||||
|
||||
.map-legend {
|
||||
min-height: 50px;
|
||||
padding: 10px 14px;
|
||||
min-height: 38px;
|
||||
padding: 6px 9px;
|
||||
border-bottom: 1px solid var(--line);
|
||||
background: #f7f8fa;
|
||||
font-size: 12px;
|
||||
@@ -870,23 +914,72 @@ tbody tr:last-child td {
|
||||
.legend-item {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
gap: 4px;
|
||||
}
|
||||
|
||||
.legend-marker,
|
||||
.status-marker {
|
||||
display: inline-grid;
|
||||
place-items: center;
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
border: 1px solid #758493;
|
||||
border-radius: 4px;
|
||||
border-radius: 3px;
|
||||
color: #263442;
|
||||
background: #eef1f4;
|
||||
font-size: 10px;
|
||||
font-weight: 850;
|
||||
}
|
||||
|
||||
.legend-marker {
|
||||
min-height: 21px;
|
||||
padding: 2px 5px;
|
||||
font-size: 9px;
|
||||
}
|
||||
|
||||
.status-marker {
|
||||
flex: 0 1 auto;
|
||||
min-height: 17px;
|
||||
max-width: 100%;
|
||||
padding: 1px 4px;
|
||||
font-size: 8px;
|
||||
line-height: 1.2;
|
||||
text-align: center;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
.legend-marker[data-status="online"],
|
||||
.map-position[data-status="online"] .status-marker { border-color: #658675; color: #315c45; background: #f0f6f2; }
|
||||
.legend-marker[data-status="offline"],
|
||||
.map-position[data-status="offline"] .status-marker { border-color: #b42318; color: #8f1d14; background: #fff; }
|
||||
.legend-marker[data-status="unstable"],
|
||||
.map-position[data-status="unstable"] .status-marker { border-color: #9a5b00; color: #754600; background: #fff; }
|
||||
.legend-marker[data-status="repair"],
|
||||
.map-position[data-status="repair"] .status-marker { border-color: #6b4ca5; color: #523884; background: #fff; }
|
||||
.legend-marker[data-status="unknown"],
|
||||
.map-position[data-status="unknown"] .status-marker { border-color: #596675; color: #354351; background: #fff; }
|
||||
|
||||
.relative-scale {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
padding-right: 8px;
|
||||
border-right: 1px solid var(--line);
|
||||
color: #40505f;
|
||||
}
|
||||
|
||||
.relative-scale-label {
|
||||
font-weight: 750;
|
||||
}
|
||||
|
||||
.relative-scale-value {
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
|
||||
.relative-scale-track {
|
||||
width: 64px;
|
||||
height: 6px;
|
||||
border: 1px solid #8e9ba8;
|
||||
background: linear-gradient(90deg, #dfe9ee, #176b9a);
|
||||
}
|
||||
|
||||
.map-notice {
|
||||
margin: 14px;
|
||||
padding: 13px;
|
||||
@@ -898,11 +991,11 @@ tbody tr:last-child td {
|
||||
|
||||
.map-viewport-v1 {
|
||||
display: grid;
|
||||
gap: 14px;
|
||||
gap: 8px;
|
||||
min-height: 380px;
|
||||
max-height: calc(100vh - 330px);
|
||||
max-height: calc(100vh - 265px);
|
||||
overflow: auto;
|
||||
padding: 14px;
|
||||
padding: 8px;
|
||||
background: #e9edf0;
|
||||
}
|
||||
|
||||
@@ -914,7 +1007,7 @@ tbody tr:last-child td {
|
||||
|
||||
.rack-title {
|
||||
margin: 0;
|
||||
padding: 9px 12px;
|
||||
padding: 6px 9px;
|
||||
color: #fff;
|
||||
background: #263442;
|
||||
font-size: 14px;
|
||||
@@ -922,7 +1015,7 @@ tbody tr:last-child td {
|
||||
|
||||
.map-shelf {
|
||||
display: grid;
|
||||
grid-template-columns: 112px minmax(0, 1fr);
|
||||
grid-template-columns: 78px minmax(0, 1fr);
|
||||
border-top: 1px solid var(--line);
|
||||
}
|
||||
|
||||
@@ -932,7 +1025,7 @@ tbody tr:last-child td {
|
||||
|
||||
.shelf-title {
|
||||
margin: 0;
|
||||
padding: 12px;
|
||||
padding: 7px;
|
||||
color: #40505f;
|
||||
background: #f3f5f7;
|
||||
font-size: 12px;
|
||||
@@ -940,20 +1033,21 @@ tbody tr:last-child td {
|
||||
|
||||
.position-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fill, minmax(142px, 1fr));
|
||||
gap: 7px;
|
||||
padding: 8px;
|
||||
grid-template-columns: repeat(auto-fill, minmax(108px, 1fr));
|
||||
gap: 4px;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
.map-position {
|
||||
position: relative;
|
||||
display: grid;
|
||||
grid-template-rows: auto auto auto auto;
|
||||
gap: 5px;
|
||||
gap: 2px;
|
||||
min-width: 0;
|
||||
min-height: 118px;
|
||||
padding: 9px;
|
||||
min-height: 84px;
|
||||
padding: 6px;
|
||||
border: 1px solid #8e9ba8;
|
||||
border-left: 5px solid #758493;
|
||||
border-left: 3px solid #758493;
|
||||
border-radius: 4px;
|
||||
color: var(--ink);
|
||||
background: #fff;
|
||||
@@ -974,17 +1068,43 @@ button.map-position:hover {
|
||||
}
|
||||
|
||||
.map-position[data-filtered="true"] {
|
||||
opacity: .34;
|
||||
opacity: .28;
|
||||
filter: grayscale(1);
|
||||
}
|
||||
|
||||
.map-position[data-status="online"] { border-left-color: #177245; }
|
||||
.map-position[data-problems-muted="true"] {
|
||||
opacity: .16;
|
||||
filter: grayscale(.8);
|
||||
}
|
||||
|
||||
.map-position[data-selected="true"] {
|
||||
opacity: 1;
|
||||
filter: none;
|
||||
}
|
||||
|
||||
.map-position[data-problem="true"] {
|
||||
border-left-width: 5px;
|
||||
font-weight: 650;
|
||||
}
|
||||
|
||||
.map-position[data-measurement="true"]::after {
|
||||
position: absolute;
|
||||
right: auto;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: var(--relative-percent);
|
||||
height: 4px;
|
||||
background: #176b9a;
|
||||
content: "";
|
||||
}
|
||||
|
||||
.map-position[data-status="online"] { border-left-color: #658675; }
|
||||
.map-position[data-status="offline"] { border-left-color: #b42318; background: #fff5f4; }
|
||||
.map-position[data-status="unstable"] { border-left-color: #9a5b00; background: #fff9ed; }
|
||||
.map-position[data-status="repair"] { border-left-color: #6b4ca5; background: #f7f3fc; }
|
||||
.map-position[data-status="spare"] { border-left-color: #1677b8; background: #f1f8fc; }
|
||||
.map-position[data-status="retired"] { border-left-color: #4d5660; background: #eef0f2; }
|
||||
.map-position[data-status="empty"] { border-style: dashed; border-left-color: #8e9ba8; background: #f8fafb; }
|
||||
.map-position[data-status="empty"] { min-height: 56px; border-style: dashed; border-left-color: #aeb8c2; color: #687785; background: transparent; opacity: .62; }
|
||||
.map-position[data-status="expected"] { border-left-color: #996600; background: #fff9e8; }
|
||||
.map-position[data-status="conflict"] { border-left-color: #b42318; background: #fff0ee; }
|
||||
.map-position[data-status="blocked"] { border-left-color: #4d5660; background: #e5e8eb; }
|
||||
@@ -1005,10 +1125,10 @@ button.map-position:hover {
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
.position-label { font-size: 12px; }
|
||||
.position-miner { font-size: 13px; font-weight: 750; }
|
||||
.position-value { color: #334252; font-size: 12px; }
|
||||
.position-freshness { color: var(--muted); font-size: 10px; }
|
||||
.position-label { flex: 1 1 auto; min-width: 0; font-size: 10px; line-height: 1.2; }
|
||||
.position-miner { font-size: 11px; font-weight: 750; line-height: 1.2; }
|
||||
.position-value { color: #334252; font-size: 10px; font-variant-numeric: tabular-nums; }
|
||||
.position-freshness { color: var(--muted); font-size: 9px; }
|
||||
|
||||
.map-inspector-v1 {
|
||||
position: sticky;
|
||||
@@ -1110,14 +1230,19 @@ button.map-position:hover {
|
||||
.map-context-head,
|
||||
.map-status-band { align-items: flex-start; flex-direction: column; }
|
||||
.map-control-grid,
|
||||
.map-filter-grid { grid-template-columns: 1fr; }
|
||||
.map-filter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
.map-search { grid-column: 1 / -1; }
|
||||
.map-problems-control { min-height: 44px; }
|
||||
.map-viewport-v1 { max-height: none; padding: 9px; }
|
||||
.map-shelf { grid-template-columns: 1fr; }
|
||||
.shelf-title { position: sticky; left: 0; z-index: 1; }
|
||||
.position-grid { grid-template-columns: repeat(2, minmax(130px, 1fr)); overflow-x: auto; }
|
||||
.position-grid { grid-template-columns: repeat(2, minmax(108px, 1fr)); overflow-x: auto; }
|
||||
.map-inspector-v1 { position: fixed; inset: 0; z-index: 80; max-height: none; overflow-y: auto; }
|
||||
}
|
||||
|
||||
@media (max-width: 420px) {
|
||||
.position-grid { grid-template-columns: minmax(150px, 1fr); }
|
||||
.map-control-grid,
|
||||
.map-filter-grid { grid-template-columns: 1fr; }
|
||||
.map-search { grid-column: auto; }
|
||||
.position-grid { grid-template-columns: repeat(2, minmax(104px, 1fr)); }
|
||||
}
|
||||
Reference in new issue
Block a user