Sabers playoff picture is a little clearer after Saturday

Sabers playoff picture is a little clearer after Saturday


{‘audience_id’: None, ‘byline’: ”, ‘event_cta_link’: None, ‘event_cta_title’: None, ‘hide_author’: None, ‘multiday_event’: None, ‘pdfruleslink’: None, ‘pdfupload’: None, ‘post_type’: None, ‘rules_body_text’: None, ‘timezone’: None, ‘venue_address’: None, ‘original_station’: [{‘station’: ‘wgr550’, ‘path’: ‘wgr550/sports/sabres/sabres-playoff-picture-is-a-little-clearer-after-saturday’}]’syndicated_items’: [{‘station’: ‘wcmf’, ‘path’: ‘wcmf/sports/buffalo-sabres/sabres-playoff-picture-is-a-little-clearer-after-saturday’}, {‘station’: ‘thefanrochester’, ‘path’: ‘thefanrochester/sports/buffalo-sabres/sabres-playoff-picture-is-a-little-clearer-after-saturday’}]}

Skip to content

Condition: Post with Page_List

${localTime}

`; return row; } perform constructScheduleRow(present, stationTimezone) { const row = doc.createElement(“a”); row.href = `https://www.audacy.com/stations/${stationSlug}`; row.className = “player-item”; const startIso = present.beginDateTime; const endIso = present.finishDateTime; const startDayLocal = getLocalDateInTimezone(startIso, stationTimezone); const endDayLocal = getLocalDateInTimezone(endIso, stationTimezone); const todayLocal = getTodayInTimezone(stationTimezone); let label = formatTime(startIso, stationTimezone); if (present.isOnNow) { label = “On Air Now”; } else if (startDayLocal !== todayLocal && endDayLocal === todayLocal) { label = `Until ${formatTime(endIso, stationTimezone)}`; } row.innerHTML = `
$

${formatTime(startIso, stationTimezone)}

`; return row; } const isNumericValue = (worth) => { return typeof worth === “string” ? worth.trim() !== “” && !isNaN(Number(worth.trim())) : typeof worth === “number” && !isNaN(worth); }; async perform loadMusicBar() { let apiUrl = `https://api.audacy.com/experience/v2/stations/${a2Id}/nowplaying?count=${song_count}`; if(isNumericValue(awId)){ apiUrl=`https://api-nowplaying.amperwave.net/api/v1/prtplus/nowplaying/${song_count}/${awId}/nowplaying.json` console.log(apiUrl); } attempt { const res = await fetch(apiUrl); const information = await res.json(); window.performances = information?.performances || []; doc.dispatchEvent(new Event(‘performances:prepared’)); if (!window.performances.size) return; const first = window.performances[0]; currentTrackEl.textContent = `${first.artist} – ${first.title}`; if (dropdownTitleEl) dropdownTitleEl.textContent = “Recently Played”; listEl.innerHTML = “”; window.performances.slice(0, 20).forEach(merchandise => { listEl.appendChild(buildMusicRow(merchandise)); }); playerBar.classList.take away(“hidden”); } catch (err) { console.error(“Now Playing API error:”, err); } } async perform loadScheduleBar() { const baseDate = new Date(); const startWindow = new Date(baseDate); const endWindow = new Date(baseDate); startWindow.setDate(baseDate.getDate() – 1); endWindow.setDate(baseDate.getDate() + 2); const beginDateStr = formatDate(startWindow); const finishDateStr = formatDate(endWindow); const apiUrl = `https://api.audacy.com/experience/v2/stations/${stationId}/schedules?startDate=${startDateStr}&endDate=${endDateStr}&timezone=UTC`; attempt { const res = await fetch(apiUrl); const information = await res.json(); const occurrences = information?.occurrences || []; if (!occurrences.size) return; const stationTimezone = occurrences[0].timezone || timezone || “UTC”; const todayLocal = getTodayInTimezone(stationTimezone); const todaysShows = occurrences .filter(present => endDayLocal === todayLocal; ) .kind((a, b) => new Date(a.beginDateTime) – new Date(b.beginDateTime)); if (!todaysShows.size) return; const currentShow = todaysShows.discover(present => present.isOnNow) || todaysShows.discover(present => { const now = Date.now(); return new Date(present.beginDateTime).getTime() <= now && new Date(show.endDateTime).getTime() > now; }) || todaysShows[0]; currentTrackEl.textContent = currentShow.showTitle || “”; if (dropdownTitleEl) dropdownTitleEl.textContent = “Today’s Schedule”; listEl.innerHTML = “”; todaysShows.slice(0, 20).forEach(present => { listEl.appendChild(constructScheduleRow(present, stationTimezone)); }); playerBar.classList.take away(“hidden”); } catch (err) { console.error(“Schedule API error:”, err); } } if (stationType === “music”) { loadMusicBar(); } else if (stationType === “sports” || stationType === “news”) { loadScheduleBar(); } const playerContent = doc.querySelector(“.player-content”); if (playerContent) { playerContent.addEventListener(“click”, perform () { playerContent.classList.toggle(“visible”); }); } });

Leave a Reply

Your email address will not be published. Required fields are marked *