Skip to content

Timezone controls (optional, default turned on)#1327

Open
cwant wants to merge 9 commits into
ElixirTeSS:masterfrom
cwant:cwant/timezone-controls
Open

Timezone controls (optional, default turned on)#1327
cwant wants to merge 9 commits into
ElixirTeSS:masterfrom
cwant:cwant/timezone-controls

Conversation

@cwant

@cwant cwant commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

Summary of changes

This ports over the timezone controls from Explora to Elixir/TeSS.

Motivation and context

It's helpful to see events in your own timezone. This PR gives a toggle between showing times in the timezone of each event, and showing times in the timezone detected by the webbrowser.

The timezone control widget shows up on any page where there is an event listed (e.g. events#index, events#show, upcoming events, etc.).

The timezone controls can be opened and closed for visibility.

An added feature: the event edit page allows you to enter times in the timezone of the event (rather than having to do the mental math of entering it in GMT and hoping you've done that correctly).

Note : this uses the ffi-icu gem. For our TeSS we use this so that the timezone names appear in the language that is selected in our user interface. E.g. heure d’été du Pacifique nord-américain when French is selected instead of Pacific Daylight Time.

Screenshots

Here is the initial hit on event#index, with option "event timezones" selected by default. Two events with different timezones are shown.

timezones1

Here is the same page, with the timezones controls displayed via the Change... link. (Clicking the x hides the controls again.)

timezones2

Here is the page with my timezone (detected by the browser) is clicked:

timezones3

Here is the editing link for start/end times, done in the timezone selected for the event (converted to GMT when saved to the database):

timezones4

Checklist

  • I have read and followed the CONTRIBUTING guide.
  • I confirm that I have the authority necessary to make this contribution on behalf of its copyright owner and agree to license it to the TeSS codebase under the BSD license.

@kennethrioja

Copy link
Copy Markdown
Contributor

Many thanks @cwant for taking the time to do this PR – really appreciated and really helpful!

Before this PR, I tried on my side to cherry-pick some of your commits from your forked TeSS, so far I picked up almost the same one :

I'll test on my side if everything seems ok for me and if I don't need the last I've added on my side.

I can definitely help review this PR @fbacall – if you want to throw a copilot, please do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants