Skip to content

Commit 730d84b

Browse files
committed
style: overhaul print label to prioritize QR code as requested
1 parent 17e7d5a commit 730d84b

File tree

3 files changed

+30
-22
lines changed

3 files changed

+30
-22
lines changed

whereisit/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ COPY frontend/package.json frontend/package-lock.json ./
66
RUN npm ci
77

88
# Force cache invalidation for source code
9-
ARG CACHEBUST=202602202600
9+
ARG CACHEBUST=202602202610
1010
RUN echo "Cache bust: $CACHEBUST"
1111

1212
COPY frontend/ ./

whereisit/config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: "WhereIsIt"
2-
version: "0.4.26"
2+
version: "0.4.27"
33
slug: "whereisit"
44
description: "Physical storage management for Home Assistant"
55
url: "https://github.com/D3L05/whereisit"

whereisit/frontend/src/views/box-view.js

Lines changed: 28 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -268,43 +268,51 @@ export class BoxView extends LitElement {
268268
}
269269
.label-container {
270270
border: 2px solid #000;
271-
padding: 20px;
271+
padding: 24px 16px;
272272
border-radius: 12px;
273-
width: 300px;
273+
width: 320px;
274+
display: flex;
275+
flex-direction: column;
276+
align-items: center;
274277
}
275-
.unit-name {
276-
font-size: 14px;
277-
color: #666;
278-
margin-bottom: 4px;
279-
text-transform: uppercase;
280-
letter-spacing: 1px;
278+
.qr-img {
279+
width: 240px;
280+
height: 240px;
281+
margin-bottom: 16px;
281282
}
282283
.box-name {
283-
font-size: 28px;
284-
font-weight: bold;
285-
margin-bottom: 16px;
284+
font-size: 32px;
285+
font-weight: 900;
286+
line-height: 1.1;
287+
margin-bottom: 8px;
288+
color: #000;
286289
}
287-
.qr-img {
288-
width: 150px;
289-
height: 150px;
290+
.unit-name {
291+
font-size: 16px;
292+
font-weight: 500;
293+
color: #444;
294+
margin-bottom: 8px;
290295
}
291296
.slug {
292-
margin-top: 12px;
297+
margin-top: 8px;
293298
font-family: monospace;
294-
font-size: 12px;
295-
color: #888;
299+
font-size: 14px;
300+
color: #666;
301+
background: #f5f5f5;
302+
padding: 4px 8px;
303+
border-radius: 4px;
296304
}
297305
@media print {
298306
body { width: 100%; height: auto; }
299-
.label-container { border: none; }
307+
.label-container { border: none; padding: 0; }
300308
}
301309
</style>
302310
</head>
303311
<body>
304312
<div class="label-container">
305-
<div class="unit-name">${unitName}</div>
306-
<div class="box-name">${this.box.name}</div>
307313
<img src="${qrUrl}" class="qr-img" />
314+
<div class="box-name">${this.box.name}</div>
315+
<div class="unit-name">${unitName}</div>
308316
<div class="slug">ID: ${this.box.slug}</div>
309317
</div>
310318
<script>

0 commit comments

Comments
 (0)