freetube/src
Aiz c784841b22
Display time remaining until video goes live (#2501)
* display time left until video premiers:

* video premiere display time left with time units

Displays time left in seconds, minutes, hours, and days.

This depends on how much time is left.

* premiere time left, display time in singular if needed

also simplified the big if block

* premiere time left, display time unit in lowercase

* Add Starting Soon string to locale file

* apply fixes reported by linter

* premiere time left, add suggested changes

Better temp variable scoping, flatten nested code, rename temp variables, use string intepolation

Co-authored-by: PikachuEXE <pikachuexe@gmail.com>

* replace tabs with spaces

tabs where used in some places in the suggested code

* display time left, remove "starting soon" string

Since upcomingTimeStamp will be null when the time has passed the scheduled timestamp
it doesn't make sense to use something that will rarely be displayed.
e.g. a user has to click on the video with less than a second remaing until it goes live for it to be displayed

it would also be displayed as "Premieres in Starting soon" which doesn't make sense

* display 'less than a minute' instead of exactly how many seconds remain

Looks better and works for values less than 0

Co-authored-by: PikachuEXE <pikachuexe@gmail.com>
2022-09-05 23:45:45 +02:00
..
data Push Latest Code to Repository 2020-02-16 13:30:00 -05:00
datastores System theme preference (#1800) 2022-05-11 10:30:40 -04:00
main Added Catppuccin Mocha Theme (#2395) 2022-07-20 09:44:47 +08:00
renderer Display time remaining until video goes live (#2501) 2022-09-05 23:45:45 +02:00
utilities Remove unused dependencies (#2278) 2022-05-31 16:15:44 -04:00
constants.js Feature: Screenshot of video (#2221) 2022-05-30 15:24:34 +02:00
index.ejs System theme preference (#1800) 2022-05-11 10:30:40 -04:00