mirror of
https://github.com/headporter81/specialsource-homepage-frontend.git
synced 2026-12-06 07:11:02 +09:00
This commit is contained in:
1 parent
2f9091ed70
commit
ded7e6e6f9
2 files changed
+61
-6
No files matched your search
+29
-1
@@ -55,6 +55,25 @@
|
||||
<pre class="ascii-art" v-html="formattedAscii"></pre>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="dash-grid">
|
||||
<div v-if="isLoggedIn" class="dash-panel">
|
||||
<h4>LIVE SESSION</h4>
|
||||
<div class="dash-stat"><span>LIVE</span><b class="pulse-text">{{ activeNow }}</b></div>
|
||||
<div class="dash-stat"><span>TODAY</span><b>{{ todayUnique }}</b></div>
|
||||
</div>
|
||||
|
||||
<div class="dash-panel">
|
||||
<h4>SERVER SOURCE</h4>
|
||||
<span :class="['dash-chip', currentServerSource]">[{{ currentServerSourceDisplay }}]</span>
|
||||
</div>
|
||||
|
||||
<div class="dash-panel">
|
||||
<h4>SESSION</h4>
|
||||
<div class="dash-stat"><span>USER</span><b>{{ isLoggedIn ? currentUsername : 'anonymous' }}</b></div>
|
||||
<div class="dash-stat"><span>DISPLAY</span><b>{{ activeThemeLabel }}</b></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-else-if="activeMenu === 'youtube'" id="videos-container" key="youtube">
|
||||
@@ -177,9 +196,18 @@ const loginPw = ref('');
|
||||
const activeMenu = ref('main');
|
||||
const authToken = ref(localStorage.getItem('token'));
|
||||
const currentUsername = ref(localStorage.getItem('username') || '');
|
||||
const VALID_THEMES = ['green', 'amber', 'vga', 'ega', 'white', 'plasma'];
|
||||
const THEME_LABELS = {
|
||||
green: 'IBM 5151 (그린)',
|
||||
amber: 'ZVM-1240 (호박)',
|
||||
vga: 'IBM 8503 (회색)',
|
||||
ega: 'IBM 5154 (청록)',
|
||||
white: 'VT220 (백색)',
|
||||
plasma: 'GRiD COMPASS (플라즈마)'
|
||||
};
|
||||
const VALID_THEMES = Object.keys(THEME_LABELS);
|
||||
const storedTheme = localStorage.getItem('theme');
|
||||
const activeTheme = ref(VALID_THEMES.includes(storedTheme) ? storedTheme : 'green');
|
||||
const activeThemeLabel = computed(() => THEME_LABELS[activeTheme.value]);
|
||||
|
||||
watch(activeTheme, (theme) => {
|
||||
localStorage.setItem('theme', theme);
|
||||
|
||||
Reference in new issue
Block a user