mirror of
https://github.com/movie-web/movie-web.git
synced 2024-12-26 04:51:48 +01:00
Fix remaining time for mobile + smaller heading sizes
This commit is contained in:
parent
bc22c323a0
commit
761884ee01
@ -111,9 +111,10 @@
|
|||||||
"short": "Back"
|
"short": "Back"
|
||||||
},
|
},
|
||||||
"time": {
|
"time": {
|
||||||
"short": "-{{timeLeft}}",
|
|
||||||
"regular": "{{timeWatched}} / {{duration}}",
|
"regular": "{{timeWatched}} / {{duration}}",
|
||||||
"remaining": "{{timeLeft}} left • Finish at {{timeFinished, datetime}}"
|
"shortRegular": "{{timeWatched}}",
|
||||||
|
"remaining": "{{timeLeft}} left • Finish at {{timeFinished, datetime}}",
|
||||||
|
"shortRemaining": "-{{timeLeft}}"
|
||||||
},
|
},
|
||||||
"nextEpisode": {
|
"nextEpisode": {
|
||||||
"next": "Next episode",
|
"next": "Next episode",
|
||||||
@ -203,15 +204,9 @@
|
|||||||
"stopEditing": "Stop editing"
|
"stopEditing": "Stop editing"
|
||||||
},
|
},
|
||||||
"titles": {
|
"titles": {
|
||||||
"morning": [
|
"morning": ["Morning title"],
|
||||||
"Morning title"
|
"day": ["Day title"],
|
||||||
],
|
"night": ["Night title"]
|
||||||
"day": [
|
|
||||||
"Day title"
|
|
||||||
],
|
|
||||||
"night": [
|
|
||||||
"Night title"
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"search": {
|
"search": {
|
||||||
"loading": "Loading...",
|
"loading": "Loading...",
|
||||||
|
@ -40,10 +40,14 @@ export function Time(props: { short?: boolean }) {
|
|||||||
const timeFinished = new Date(Date.now() + secondsRemaining * 1e3);
|
const timeFinished = new Date(Date.now() + secondsRemaining * 1e3);
|
||||||
const duration = formatSeconds(timeDuration, hasHours);
|
const duration = formatSeconds(timeDuration, hasHours);
|
||||||
|
|
||||||
let localizationKey = "regular";
|
let localizationKey =
|
||||||
if (props.short) localizationKey = "short";
|
timeFormat === VideoPlayerTimeFormat.REGULAR ? "regular" : "remaining";
|
||||||
else if (timeFormat === VideoPlayerTimeFormat.REMAINING)
|
if (props.short) {
|
||||||
localizationKey = "remaining";
|
localizationKey =
|
||||||
|
timeFormat === VideoPlayerTimeFormat.REGULAR
|
||||||
|
? "shortRegular"
|
||||||
|
: "shortRemaining";
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<VideoPlayerButton onClick={() => toggleMode()}>
|
<VideoPlayerButton onClick={() => toggleMode()}>
|
||||||
|
@ -24,7 +24,7 @@ export function Heading2(props: TextProps) {
|
|||||||
return (
|
return (
|
||||||
<h2
|
<h2
|
||||||
className={[
|
className={[
|
||||||
"text-xl lg:text-3xl font-bold text-white mt-20 mb-9",
|
"text-xl lg:text-2xl font-bold text-white mt-20 mb-9",
|
||||||
props.border ? borderClass : null,
|
props.border ? borderClass : null,
|
||||||
props.className ?? "",
|
props.className ?? "",
|
||||||
].join(" ")}
|
].join(" ")}
|
||||||
|
Loading…
Reference in New Issue
Block a user