Update public/styles.css
This commit is contained in:
parent
4c744f23b0
commit
038b404a8c
@ -1,22 +1,44 @@
|
|||||||
/* styles.css */
|
/* ================= CSS VARIABLES ================= */
|
||||||
|
:root {
|
||||||
/* ─── Global & Layout ───────────────────────────────────────────────────────── */
|
--square-size: 60px;
|
||||||
|
--gap: 8px;
|
||||||
/* Reset & body */
|
--v-gap: 24px;
|
||||||
* { box-sizing: border-box; }
|
--warehouse-height: 200px;
|
||||||
body {
|
|
||||||
margin: 0;
|
|
||||||
font-family: Arial, sans-serif;
|
|
||||||
background-color: #eeeeee;
|
|
||||||
color: #333;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Fixed header */
|
/* ================= GLOBAL & LAYOUT ================= */
|
||||||
|
html, body {
|
||||||
|
height: 100%;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
background: #f4f4f4;
|
||||||
|
font-family: Arial, sans-serif;
|
||||||
|
}
|
||||||
|
h1 {
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 1rem;
|
||||||
|
}
|
||||||
|
.page-container {
|
||||||
|
margin-top: 70px; /* under fixed header */
|
||||||
|
width: 95%;
|
||||||
|
max-width: 1200px;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
padding: 1rem;
|
||||||
|
background: #fff;
|
||||||
|
border-radius: 6px;
|
||||||
|
box-sizing: border-box;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
min-height: calc(100vh - 70px);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ================= BINS HEADER & NAV BUTTONS ================= */
|
||||||
.main-header {
|
.main-header {
|
||||||
background-color: #232F3E;
|
background-color: #232F3E;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
padding: 0.5rem 1rem;
|
padding: 0.5rem 2rem;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0; left: 0; right: 0;
|
top: 0; left: 0; right: 0;
|
||||||
z-index: 1000;
|
z-index: 1000;
|
||||||
@ -45,52 +67,17 @@ body {
|
|||||||
background-color: #e48f00;
|
background-color: #e48f00;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Main page container (offset under header) */
|
/* ================= FORM STYLES ================= */
|
||||||
.page-container {
|
.form-input {
|
||||||
margin-top: 70px; /* height of header */
|
width: 80%;
|
||||||
width: 95%;
|
max-width: 400px;
|
||||||
max-width: 1200px;
|
margin: 1rem auto;
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
padding: 1rem;
|
|
||||||
background-color: #fff;
|
|
||||||
border-radius: 6px;
|
|
||||||
box-shadow: 0 2px 6px rgba(0,0,0,0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Utility */
|
|
||||||
.hidden {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* ─── Forms & Buttons ───────────────────────────────────────────────────────── */
|
|
||||||
|
|
||||||
/* Text inputs & dropdowns */
|
|
||||||
.form-input,
|
|
||||||
.form-textarea,
|
|
||||||
select {
|
|
||||||
width: 90%;
|
|
||||||
margin: 0.5rem auto;
|
|
||||||
display: block;
|
display: block;
|
||||||
padding: 0.75rem;
|
|
||||||
border: 1px solid #ccc;
|
|
||||||
border-radius: 6px;
|
|
||||||
font-size: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Fieldset & legend spacing */
|
|
||||||
fieldset {
|
|
||||||
border: 1px solid #ccc;
|
|
||||||
border-radius: 6px;
|
|
||||||
margin: 1rem 0;
|
|
||||||
padding: 1rem;
|
padding: 1rem;
|
||||||
|
font-size: 1rem;
|
||||||
|
border: 1px solid #ccc;
|
||||||
|
border-radius: 6px;
|
||||||
}
|
}
|
||||||
legend {
|
|
||||||
padding: 0 0.5rem;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Large submit button */
|
|
||||||
.big-button {
|
.big-button {
|
||||||
background-color: #28a745;
|
background-color: #28a745;
|
||||||
color: white;
|
color: white;
|
||||||
@ -105,133 +92,124 @@ legend {
|
|||||||
.big-button:hover {
|
.big-button:hover {
|
||||||
background-color: #218838;
|
background-color: #218838;
|
||||||
}
|
}
|
||||||
|
fieldset {
|
||||||
/* ─── Heat Map Page ────────────────────────────────────────────────────────── */
|
border: 1px solid #ccc;
|
||||||
|
|
||||||
/* Scrollable/zoomable container */
|
|
||||||
#heatmap-container {
|
|
||||||
margin-top: 70px;
|
|
||||||
width: 95%;
|
|
||||||
height: calc(100vh - 70px);
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
position: relative;
|
|
||||||
overflow: auto;
|
|
||||||
background-color: #f9f9f9;
|
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
box-shadow: 0 2px 6px rgba(0,0,0,0.1);
|
padding: 1rem;
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
}
|
}
|
||||||
|
legend {
|
||||||
/* SVG wrapper */
|
|
||||||
.map-svg-container {
|
|
||||||
width: 2000px; /* adjust to your full map width */
|
|
||||||
height: 400px; /* adjust to your map height */
|
|
||||||
transform-origin: 0 0;
|
|
||||||
cursor: grab;
|
|
||||||
}
|
|
||||||
.map-svg-container:active {
|
|
||||||
cursor: grabbing;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Dock door squares */
|
|
||||||
.dock-door {
|
|
||||||
fill: #ccc;
|
|
||||||
stroke: #999;
|
|
||||||
stroke-width: 1;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
.dock-door:hover {
|
|
||||||
stroke: #FF9900;
|
|
||||||
stroke-width: 2;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Area rectangles (A-Mod, AFE-1, etc) */
|
|
||||||
.area-rect {
|
|
||||||
fill: rgba(200,200,200,0.3);
|
|
||||||
stroke: #999;
|
|
||||||
stroke-width: 1;
|
|
||||||
}
|
|
||||||
.area-rect label {
|
|
||||||
font-size: 0.85rem;
|
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Floor selector */
|
/* ================= TRENDS PAGE ================= */
|
||||||
.floor-selector {
|
/* Controls */
|
||||||
position: absolute;
|
#trend-controls {
|
||||||
top: 1rem;
|
flex: 0 0 auto;
|
||||||
right: 1rem;
|
text-align: center;
|
||||||
background: rgba(255,255,255,0.9);
|
|
||||||
padding: 0.5rem;
|
|
||||||
border-radius: 6px;
|
|
||||||
box-shadow: 0 1px 4px rgba(0,0,0,0.2);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* ─── Trends Page ──────────────────────────────────────────────────────────── */
|
|
||||||
|
|
||||||
/* Chart container */
|
|
||||||
#chart-container {
|
|
||||||
height: 50vh;
|
|
||||||
width: 100%;
|
|
||||||
margin-bottom: 2rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Spreadsheet-style table wrapper */
|
|
||||||
#trends-table-container {
|
|
||||||
max-height: 40vh;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #ddd;
|
|
||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
}
|
}
|
||||||
|
/* Chart */
|
||||||
/* Table styling */
|
.chart-container {
|
||||||
#trends-table {
|
flex: 1 1 auto;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border-collapse: collapse;
|
position: relative;
|
||||||
table-layout: fixed;
|
|
||||||
}
|
}
|
||||||
#trends-table th,
|
.chart-container canvas {
|
||||||
#trends-table td {
|
width: 100% !important;
|
||||||
padding: 8px;
|
height: 100% !important;
|
||||||
text-align: center;
|
|
||||||
border-bottom: 1px solid #ddd;
|
|
||||||
font-size: 0.95rem;
|
|
||||||
}
|
}
|
||||||
#trends-table thead th {
|
/* Table */
|
||||||
position: sticky;
|
.table-container {
|
||||||
top: 0;
|
margin-top: 2rem;
|
||||||
background: #f2f2f2;
|
overflow-x: auto;
|
||||||
border-bottom: 2px solid #ccc;
|
}
|
||||||
|
table.dataTable {
|
||||||
|
width: 100% !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ================= HEATMAP STYLES ================= */
|
||||||
|
/* Scroll & pan wrapper */
|
||||||
|
.heatmap-wrapper {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
overflow-x: auto;
|
||||||
|
overflow-y: hidden;
|
||||||
|
display: flex;
|
||||||
|
justify-content: flex-start;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
/* Entire diagram */
|
||||||
|
.diagram-container {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
gap: var(--v-gap);
|
||||||
|
}
|
||||||
|
/* Dock-door row */
|
||||||
|
.dock-row {
|
||||||
|
display: flex;
|
||||||
|
gap: var(--gap);
|
||||||
|
}
|
||||||
|
/* Each dock square */
|
||||||
|
.dock-square {
|
||||||
|
width: var(--square-size);
|
||||||
|
height: var(--square-size);
|
||||||
|
background: #ddd;
|
||||||
|
border-radius: 4px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.75rem;
|
||||||
|
color: #333;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
user-select: none;
|
user-select: none;
|
||||||
}
|
}
|
||||||
/* Zebra striping */
|
/* Regions below dock row */
|
||||||
#trends-table tbody tr:nth-child(even) {
|
.regions-container {
|
||||||
background: #fafafa;
|
display: flex;
|
||||||
|
width: 100%;
|
||||||
|
gap: var(--gap);
|
||||||
}
|
}
|
||||||
/* Sort arrow indicators */
|
.region {
|
||||||
.sortable::after {
|
flex: 1;
|
||||||
content: '▲▼';
|
height: 120px;
|
||||||
font-size: 0.6em;
|
border: 2px solid #666;
|
||||||
margin-left: 4px;
|
border-radius: 4px;
|
||||||
color: #888;
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-weight: bold;
|
||||||
|
user-select: none;
|
||||||
}
|
}
|
||||||
.sortable.asc::after {
|
.region-amod { background: #eef; }
|
||||||
content: '▲';
|
.region-preslam { background: #efe; }
|
||||||
|
.region-bmod { background: #fee; }
|
||||||
|
/* Warehouse rectangle */
|
||||||
|
.warehouse {
|
||||||
|
width: calc(
|
||||||
|
(var(--square-size) * 83) + /* adjust door count if needed */
|
||||||
|
(var(--gap) * 82)
|
||||||
|
);
|
||||||
|
height: var(--warehouse-height);
|
||||||
|
background: #ccc;
|
||||||
|
border-radius: 6px;
|
||||||
}
|
}
|
||||||
.sortable.desc::after {
|
/* Hover tooltip */
|
||||||
content: '▼';
|
.tooltip {
|
||||||
|
position: absolute;
|
||||||
|
pointer-events: none;
|
||||||
|
background: rgba(0,0,0,0.75);
|
||||||
|
color: #fff;
|
||||||
|
padding: 8px;
|
||||||
|
border-radius: 4px;
|
||||||
|
font-size: 0.9rem;
|
||||||
|
line-height: 1.2;
|
||||||
|
display: none;
|
||||||
|
z-index: 2000;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ─── Responsive Tweaks ─────────────────────────────────────────────────────── */
|
/* ================= UTILITY ================= */
|
||||||
|
.hidden {
|
||||||
@media (max-width: 768px) {
|
display: none;
|
||||||
.form-input, .form-textarea, select {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.nav-btn {
|
|
||||||
padding: 0.5rem;
|
|
||||||
margin-left: 0.25rem;
|
|
||||||
font-size: 0.9rem;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user