feat: display container system time instead of browser time #809
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Replace browser-based clock with backend-driven system time display to show the Linux container's time instead of the user's browser time.
Problem
Solution
python/api/poll.py): Addedsystem_timefield to poll response with server's localized time formatted as ISO (minutes precision)python/helpers/localization.py): Modified initialization to only persist timezone to.envonce, then respect the stored valuewebui/components/system-clock/): Created dedicated Alpine.js store and component to display backend timewebui/index.js): Removed browser time updater, added one-time timezone sync flag, integrated system clock store updatesIntl.DateTimeFormatwithtimeZone: "UTC"to respect user locale (24h/12h, month names) while displaying container timeChanges
Backend
python/api/poll.py: Addsystem_timegeneration and one-time timezone sync logicpython/helpers/localization.py: Update__init__to avoid persisting default timezone until explicitly setFrontend (New)
webui/components/system-clock/system-clock.html: Clock component templatewebui/components/system-clock/system-clock-store.js: Alpine store for time state and formattingFrontend (Modified)
webui/components/chat/top-section/chat-top.html: Replace inline time div with x-componentwebui/index.js: Import system clock store, removeupdateUserTime(), update poll to sync timezone oncewebui/index.css: Remove#time-dateand#user-datestyles (moved to component)