Refactor: Rename "Oscar Pool" to "Pool Oscars" in titles
Co-authored-by: mathieumoran1 <[email protected]>
This commit is contained in:
co-authored by
mathieumoran1
parent
76e9a934d6
commit
0c488319f6
@@ -8,7 +8,7 @@ function isTokenExpired(decoded) {
|
||||
}
|
||||
|
||||
async function applyActiveOscarYearToTitle() {
|
||||
const base = 'Oscar Pool';
|
||||
const base = 'Pool Oscars';
|
||||
const current = String(document.title || base);
|
||||
const sep = ' - ';
|
||||
const idx = current.indexOf(sep);
|
||||
|
||||
@@ -254,7 +254,7 @@ window.addEventListener('DOMContentLoaded', async function () {
|
||||
}
|
||||
|
||||
const activeYear = await fetchActiveYear();
|
||||
document.title = `Oscar Pool (${activeYear}) - Checklist`;
|
||||
document.title = `Pool Oscars (${activeYear}) - Checklist`;
|
||||
const oscarYearEl = document.getElementById('oscar-year');
|
||||
if (oscarYearEl) oscarYearEl.textContent = String(activeYear);
|
||||
|
||||
|
||||
@@ -2332,7 +2332,7 @@ window.onload = async function () {
|
||||
// Initial load
|
||||
activeYear = await fetchActiveYear();
|
||||
if (activeYear) {
|
||||
document.title = `Oscar Pool (${activeYear}) - Admin`;
|
||||
document.title = `Pool Oscars (${activeYear}) - Admin`;
|
||||
}
|
||||
|
||||
hookModal100Inputs();
|
||||
@@ -2352,7 +2352,7 @@ window.onload = async function () {
|
||||
activeYear = await setActiveYear(y);
|
||||
activeYearInput.value = String(activeYear);
|
||||
yearInput.value = String(activeYear);
|
||||
document.title = `Oscar Pool (${activeYear}) - Admin`;
|
||||
document.title = `Pool Oscars (${activeYear}) - Admin`;
|
||||
showResponse('success', `Année active appliquée: ${activeYear}`);
|
||||
await refreshYears();
|
||||
await loadMoviesForManagement();
|
||||
|
||||
@@ -3,7 +3,7 @@ function decodeJwt(token) {
|
||||
}
|
||||
|
||||
async function applyActiveOscarYearToTitle() {
|
||||
const base = 'Oscar Pool';
|
||||
const base = 'Pool Oscars';
|
||||
const current = String(document.title || base);
|
||||
const sep = ' - ';
|
||||
const idx = current.indexOf(sep);
|
||||
|
||||
@@ -224,7 +224,7 @@ window.addEventListener('DOMContentLoaded', async function () {
|
||||
}
|
||||
|
||||
const activeYear = await fetchActiveYear();
|
||||
document.title = `Oscar Pool (${activeYear}) - Films`;
|
||||
document.title = `Pool Oscars (${activeYear}) - Films`;
|
||||
const oscarYearEl = document.getElementById('oscar-year');
|
||||
if (oscarYearEl) oscarYearEl.textContent = String(activeYear);
|
||||
|
||||
|
||||
@@ -359,7 +359,7 @@ function setHeader(movie, { activeYear } = {}) {
|
||||
const ratingEl = document.getElementById('movie-rating');
|
||||
|
||||
const year = Number.isInteger(activeYear) ? activeYear : null;
|
||||
const titlePrefix = year ? `Oscar Pool (${year})` : 'Oscar Pool';
|
||||
const titlePrefix = year ? `Pool Oscars (${year})` : 'Pool Oscars';
|
||||
|
||||
if (titleEl) titleEl.textContent = movie?.title || titlePrefix;
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ function decodeJwt(token) {
|
||||
}
|
||||
|
||||
async function applyActiveOscarYearToTitle() {
|
||||
const base = 'Oscar Pool';
|
||||
const base = 'Pool Oscars';
|
||||
const current = String(document.title || base);
|
||||
const sep = ' - ';
|
||||
const idx = current.indexOf(sep);
|
||||
|
||||
@@ -365,7 +365,7 @@ window.addEventListener('DOMContentLoaded', async function () {
|
||||
pageLoader.setProgress(20);
|
||||
const activeYear = await fetchActiveYear();
|
||||
if (activeYear) {
|
||||
document.title = `Oscar Pool (${activeYear}) - Statistiques des utilisateurs`;
|
||||
document.title = `Pool Oscars (${activeYear}) - Statistiques des utilisateurs`;
|
||||
const h2 = document.querySelector('h2');
|
||||
if (h2) h2.textContent = `Statistiques des utilisateurs (${activeYear})`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user