Fix update button persistence with more robust implementation
- Completely redesigned update notification system with dedicated functions - Added showUpdateAlert and hideUpdateAlert functions for better control - Improved update status persistence with namespaced localStorage keys - Added custom CSS styles with \!important to prevent style overrides - Modified toggle test functionality to directly show/hide the update alert - Prevented update notifications from being cleared on errors - Added forced display styles and higher z-index for visibility - Added debugging logs to verify update detection 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
+22
-2
@@ -137,8 +137,8 @@
|
||||
<div class="mt-2 testing-controls">
|
||||
<small><a href="#" id="toggle-test-update-button">Toggle Test Update</a></small>
|
||||
</div>
|
||||
<div id="update-available" class="mt-3 d-none">
|
||||
<div class="alert alert-info">
|
||||
<div id="update-available" class="mt-3">
|
||||
<div class="alert alert-info update-alert" style="display: none;">
|
||||
<i class="fas fa-arrow-circle-up"></i>
|
||||
<span>A new version is available!</span>
|
||||
<button id="btn-update-now" class="btn btn-sm btn-primary ml-2">
|
||||
@@ -669,6 +669,26 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Update Alert Custom Styles -->
|
||||
<style>
|
||||
/* Custom styles for update alert to ensure it's visible */
|
||||
.update-alert {
|
||||
display: none;
|
||||
margin-top: 10px !important;
|
||||
border: 2px solid #007bff !important;
|
||||
background-color: #cce5ff !important;
|
||||
color: #004085 !important;
|
||||
font-weight: bold !important;
|
||||
box-shadow: 0 2px 5px rgba(0,0,0,0.2) !important;
|
||||
position: relative !important;
|
||||
z-index: 100 !important;
|
||||
}
|
||||
.update-alert span {
|
||||
color: #004085 !important;
|
||||
font-weight: bold !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<!-- JavaScript Files -->
|
||||
<script src="/js/system-status.js"></script>
|
||||
<script src="/js/app.js"></script>
|
||||
|
||||
Reference in New Issue
Block a user