Skip to content

Commit 8e93922

Browse files
committed
all inline styles
1 parent 1e49e3d commit 8e93922

File tree

1 file changed

+31
-149
lines changed

1 file changed

+31
-149
lines changed

src/routes/[room]/trmnl/+page.svelte

Lines changed: 31 additions & 149 deletions
Original file line numberDiff line numberDiff line change
@@ -31,193 +31,75 @@
3131
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
3232
</svelte:head>
3333

34-
<div class="header">
34+
<div
35+
style="display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; border-bottom: 2px solid #000; padding-bottom: 10px;"
36+
>
3537
<div>
36-
<h1 class="title">SLN Office - {room?.room || roomParam}</h1>
37-
<p class="time">{now.toLocaleTimeString('de', { hour: '2-digit', minute: '2-digit', second: '2-digit' })} Uhr</p>
38+
<h1 style="font-size: 24px; font-weight: bold; color: #000; margin: 0;">
39+
SLN Office - {room?.room || roomParam}
40+
</h1>
41+
<p style="font-size: 14px; color: #666; margin: 0;">
42+
{now.toLocaleTimeString('de', { hour: '2-digit', minute: '2-digit', second: '2-digit' })} Uhr
43+
</p>
44+
</div>
45+
<div
46+
style="font-size: 18px; font-weight: bold; color: #000; padding: 4px 8px; text-align: center;"
47+
>
48+
<img
49+
class="logo"
50+
style="text-align: right; width:50px;"
51+
src="{baseUrl}/logo.png"
52+
alt="SLN Logo"
53+
/>
3854
</div>
39-
<!-- Logo für TRMNL problematisch - verwende Text stattdessen -->
40-
<div class="logo-text">SLN</div>
4155
</div>
4256

4357
{#if !room}
44-
<div class="error">
58+
<div style="text-align: center; padding: 20px; border: 2px solid #000; background: #f0f0f0;">
4559
<p>Raum "{roomParam}" nicht gefunden.</p>
4660
</div>
4761
{:else if currentItems.length === 0 && futureItems.length === 0}
48-
<div class="no-bookings">
62+
<div style="text-align: center; color: #666; font-style: italic; padding: 20px;">
4963
<p>Keine Buchungen für heute</p>
5064
</div>
5165
{:else}
5266
<!-- Erstes aktuelles Item als Hero -->
5367
{#if currentItems.length > 0}
5468
{@const firstItem = currentItems[0]}
55-
<div class="hero-item">
56-
<div class="hero-time">
69+
<div style="background: #000; color: #fff; padding: 20px; margin: 20px 0; text-align: center;">
70+
<div style="font-size: 36px; font-weight: bold; margin-bottom: 10px;">
5771
{calculateRemainingTime(firstItem.to, now)}
5872
</div>
59-
<div class="hero-details">
73+
<div style="font-size: 14px; margin-bottom: 8px;">
6074
{formatTime(firstItem.from)} - {formatTime(firstItem.to)} Uhr
6175
</div>
62-
<div class="hero-title">
76+
<div style="font-size: 16px; font-weight: bold; margin-bottom: 4px;">
6377
{firstItem.title || 'Buchung'}
6478
</div>
65-
<div class="hero-user">
79+
<div style="font-size: 18px; font-weight: bold;">
6680
{firstItem.user.join(', ')}
6781
</div>
6882
</div>
6983
{/if}
7084

7185
<!-- Weitere Buchungen als Liste -->
72-
<div class="booking-list">
86+
<div style="margin: 20px 0;">
7387
<!-- Weitere aktuelle Buchungen -->
7488
{#each currentItems.slice(1) as item}
75-
<div class="booking-item current">
76-
<div class="booking-label">■ AKTIV: {item.user.join(', ')}</div>
89+
<div style="background: #000; color: #fff; padding: 8px; margin-bottom: 4px;">
90+
<div style="font-weight: bold; font-size: 14px;">■ AKTIV: {item.user.join(', ')}</div>
7791
<div>VON {formatTime(item.from)} Uhr BIS {formatTime(item.to)} Uhr</div>
7892
<div>NOCH {calculateRemainingTime(item.to, now)}</div>
7993
</div>
8094
{/each}
8195

8296
<!-- Zukünftige Buchungen -->
8397
{#each futureItems as item}
84-
<div class="booking-item future">
85-
<div class="booking-label">□ GEPLANT: {item.user.join(', ')}</div>
98+
<div style="color: #333; padding: 8px 0; border-bottom: 1px solid #ccc;">
99+
<div style="font-weight: bold; font-size: 14px;">□ GEPLANT: {item.user.join(', ')}</div>
86100
<div>VON {formatTime(item.from)} Uhr BIS {formatTime(item.to)} Uhr</div>
87101
<div>DAUER {item.duration}</div>
88102
</div>
89103
{/each}
90104
</div>
91105
{/if}
92-
93-
<style>
94-
/* TRMNL-optimiertes CSS - komplett inline */
95-
:global(body) {
96-
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
97-
line-height: 1.4;
98-
color: #000;
99-
background-color: #fff;
100-
font-size: 16px;
101-
padding: 15px;
102-
margin: 0;
103-
}
104-
105-
.header {
106-
display: flex;
107-
justify-content: space-between;
108-
align-items: center;
109-
margin-bottom: 20px;
110-
border-bottom: 2px solid #000;
111-
padding-bottom: 10px;
112-
}
113-
114-
.title {
115-
font-size: 24px;
116-
font-weight: bold;
117-
color: #000;
118-
margin: 0;
119-
}
120-
121-
.time {
122-
font-size: 14px;
123-
color: #666;
124-
margin: 0;
125-
}
126-
127-
.logo-text {
128-
font-size: 18px;
129-
font-weight: bold;
130-
color: #000;
131-
border: 2px solid #000;
132-
padding: 4px 8px;
133-
text-align: center;
134-
}
135-
136-
/* Hero-Item für TRMNL */
137-
.hero-item {
138-
background: #000;
139-
color: #fff;
140-
padding: 20px;
141-
margin: 20px 0;
142-
text-align: center;
143-
}
144-
145-
.hero-time {
146-
font-size: 36px;
147-
font-weight: bold;
148-
margin-bottom: 10px;
149-
}
150-
151-
.hero-details {
152-
font-size: 14px;
153-
margin-bottom: 8px;
154-
}
155-
156-
.hero-title {
157-
font-size: 16px;
158-
font-weight: bold;
159-
margin-bottom: 4px;
160-
}
161-
162-
.hero-user {
163-
font-size: 18px;
164-
font-weight: bold;
165-
}
166-
167-
/* Listen-Layout statt Tabellen */
168-
.booking-list {
169-
margin: 20px 0;
170-
}
171-
172-
.booking-item {
173-
padding: 8px 0;
174-
border-bottom: 1px solid #ccc;
175-
}
176-
177-
.booking-item.current {
178-
background: #000;
179-
color: #fff;
180-
padding: 8px;
181-
margin-bottom: 4px;
182-
border: none;
183-
}
184-
185-
.booking-item.future {
186-
color: #333;
187-
}
188-
189-
.booking-label {
190-
font-weight: bold;
191-
font-size: 14px;
192-
}
193-
194-
.no-bookings {
195-
text-align: center;
196-
color: #666;
197-
font-style: italic;
198-
padding: 20px;
199-
}
200-
201-
.error {
202-
text-align: center;
203-
padding: 20px;
204-
border: 2px solid #000;
205-
background: #f0f0f0;
206-
}
207-
208-
/* Kompakte Darstellung */
209-
@media (max-width: 600px) {
210-
:global(body) {
211-
padding: 10px;
212-
font-size: 14px;
213-
}
214-
215-
.title {
216-
font-size: 20px;
217-
}
218-
219-
.hero-time {
220-
font-size: 28px;
221-
}
222-
}
223-
</style>

0 commit comments

Comments
 (0)