Connect with us

Boston, MA

Virginia Football vs. Boston College Game Preview, Score Prediction

Published

on

Virginia Football vs. Boston College Game Preview, Score Prediction


The Virginia Cavaliers and Boston College Eagles will put their undefeated ACC records to the test when the two ACC foes clash on Saturday in Charlottesville. Boston College is looking to improve to 5-1 for the first time since 2008 and 2-0 in the ACC for the first time since 2007, while UVA is looking to improve on its best start under Tony Elliott and best start since 2019.

Read on for a full preview of Virginia vs. Boston College with everything you need to know, including game details and notes, an opponent scouting report, what to watch for, and a score prediction.

Who: Virginia Cavaliers (3-1, 1-0 ACC) vs. Boston College Eagles (4-1, 1-0 ACC)

When: Saturday, October 5th at 12pm ET

Advertisement

Where: Scott Stadium (61,500) in Charlottesville, Virginia

How to watch: ACC Network

How to listen: SiriusXM 158 or 194, SXM App 956 | Virginia Sports Radio Network

All-time series: Boston College leads 7-1

Last meeting: Boston College defeated Virginia 27-24 last season in Chestnut Hill.

Advertisement

Read Virginia’s injury report for the Boston College game here: UVA Football Week 6 Injury Report: Updates on Boley, Harris, Furnish, Wilson

See below for UVA’s week 6 depth chart for the Boston College game.

Virginia Cavaliers week 6 depth chart vs. Boston College

Virginia Cavaliers week 6 depth chart vs. Boston College / Virginia Athletics

2023: 7-6, 3-5 ACC
2024: 4-1, 1-0 ACC

In year 1 under the direction of long-time NFL head coach Bill O’Brien, the Eagles have gotten off to an excellent 4-1 start, which includes blowout wins over Florida State and Duquesne followed by a competitive loss at Missouri, and then more recently, close victories over Michigan State and Western Kentucky.

The scouting report on Boston College became a lot simpler on Thursday with the news that normal starting quarterback Thomas Castellanos is expected to be available for the Eagles on Saturday at UVA after missing last week’s game with an undisclosed injury. With Castellanos leading the way, BC can hope to return to form offensively after struggling on that side of the ball in a tight 21-20 victory over Western Kentucky last week. When Castellanos is healthy, the Boston College offense was certainly capable, opening the season with a 28-13 win at Florida State, nearly upsetting a top 10 SEC team on the road at Missouri, and coming from behind to beat Michigan State in week 4.

Advertisement

Though Castellanos is a dynamic quarterback, the run game is the focus for the Eagles, who call designed runs 55% of the time and have nearly twice the rushing attempts than passing attempts. Castellanos does his fair share of running the ball, but Treshaun Ward leads the way in the ground game, averaging 6.0 yards per carry, which ranks 10th in the ACC. Seven different Eagles have scored rushing touchdowns this season and three of them are averaging at least 4.0 yards per carry.

In the passing game, Boston College’s strength is the efficiency of Thomas Castellanos, who ranks sixth in all of college football in passing efficiency and who has thrown only two interceptions as compared to 10 passing touchdowns. His top target is 5’11” redshirt junior Lewis Bond, who leads the BC receivers with 23 catches for 279 yards and two touchdowns. Only one other Eagle has double-digit receptions for the year, so the Cavaliers should consider focusing on denying Bond and make someone else beat them.

Defensively, Boston College thrives on takeaways, forcing 10 turnovers through the first five games, eight of which have been interceptions. There’s one player UVA quarterback Anthony Colandrea will have to locate before every snap and that’s defensive end Donovan Ezeiruaku, who leads the entire country with eight sacks through the first five games of the season. To emphasize that mind-boggling level of production, Ezeiruaku is averaging more than one sack per game and has more sacks than the entire UVA defense combined.

Other defensive playmakers to keep an eye on for BC are defensive backs Max Tucker and Khari Johnson, who each have two interceptions on the season and know how to turn those picks into game-changing plays, as both Tucker and Johnson have more than 50 interception return yards this year. If Colandrea makes an ill-advised throw, it’s a good bet that Tucker or Johnson will make him pay.

Overall, the BC defense ranks third in the ACC in scoring defense, though that’s boosted significantly by the Eagles shutting out FCS Duquesne in week 2.

Advertisement

Quarterback Play
Before Thursday’s news that Thomas Castellanos is likely to start at quarterback for Boston College at Virginia on Saturday, this key was going to be about what the Eagles could get from backup Grayson James. To his credit, James threw the game-winning touchdown pass against Western Kentucky, but BC’s offense with James leading the way was uninspiring. With Castellanos expected to play, the question becomes how close to 100% of his normal dynamic play he provides in his return and whether the Cavalier defense can do a better job of containing him than last season, when he threw for 183 yards and two touchdowns and rushed for 78 more to lead the Eagles to a comeback in the second half. On the other side, the quarterback facing Castellanos will be different as Anthony Colandrea looks to do what Tony Muskett couldn’t last year and lead the Hoos to a victory over the Eagles for just the second time in the history of the series.

Second and Fourth Quarter Trends
Boston College tends to get off to a slow start offensively, scoring just 21 points in the first quarter through five games. The Eagles then turn it on in the second quarter, putting 62 points on the board this season in second quarters. In the fourth quarter, the BC defense locks in, giving up just six total points in five fourth quarters this season. Virginia has outscored each of its opponents in the second quarter this season and showed much improvement in fourth quarter execution, which was perhaps the team’s greatest weakness last season, in the comeback victory at Wake Forest. How each team performs before halftime and in the closing possessions of the game will be even more important in this game than they usually are.

Battle in the Trenches
The Eagles lean heavily on their physical play at the line of scrimmage, relying on a capable run game and an effective pass rush to turn the tides in their favor. Virginia can flip the script by disrupting Boston College’s efforts to dominate the line of scrimmage on either side of the ball. The UVA defensive front must contain BC’s run game and force the Eagles into third and long situations. But perhaps mostly importantly, the Cavalier offensive line must hold up against Donovan Ezeiruaku and the BC pass rush. Keep an eye on the left tackle spot, as McKale Boley is slated to make his season debut after missing the first four games with an injury. It wouldn’t be surprising to see both Boley and Jack Witmer, who started those four games at left tackle, split reps in this game, and look for the Cavaliers to potentially double team Ezeiruaku in order to take him out of the game if possible.

Boston College has owned the series against Virginia. Though the two teams have met only eight times, it still seems almost unfathomable that the Cavaliers have prevailed over the Eagles only once in the 60-year history of the series, and that one win came with just 250 fans in attendance at Scott Stadium during the COVID-impacted 2020 season. There should be plenty of fans in the stands on Saturday for UVA’s Homecomings game to see the Hoos face their toughest challenge yet against a well-coached team that has proven to have a winning mentality. UVA is 3-1, but still unproven without a marquee victory against a quality opponent. That could change on Saturday in what should be a very competitive ACC football game. I see this one coming down to the wire, with the Cavaliers showing that their improvements in late-game execution are for real.

Score prediction: Virginia 26, Boston College 23

Advertisement

UVA Football: Players to Watch in Virginia vs. Boston College

Scouting Report: What to Expect From Boston College on Saturday at Virginia

UVA Football Week 6 Injury Report: Updates on Boley, Harris, Furnish, Wilson

Virginia Football Depth Chart vs. Boston College | Takeaways, Analysis

Virginia Football Opens as Home Favorite vs. Boston College in Week 6

Advertisement



Source link

Boston, MA

Biddeford woman runs Boston Marathon in honor of late mother

Published

on

Biddeford woman runs Boston Marathon in honor of late mother


Jessica Johnson of Biddeford will run her fourth Boston Marathon next week. (Courtesy of Jessica Johnson)

Running the storied Boston Marathon is probably every runner’s dream. But for Jessica Johnson, a Biddeford resident and Massabesic Middle School teacher, it wasn’t an overwhelming desire that prompted her. It was boredom.

“I was bored during COVID,” she said. “I was just bored, so I laced up my sneakers, and off I went.” 

The other reason, and one of her biggest motivators for running marathons, is her mother, who died of brain cancer in 2002.

Advertisement

All of Johnson’s races have been in her honor.

This year, Johnson is running in partnership with Dana Farber Cancer Institute raising money for cancer research. 

“My mom would’ve been my biggest cheerleader,” she said. “I always think of my mom.” 

Johnson’s mom often shows up in mysterious ways on marathon courses. Two years ago, Johnson got very sick on the Boston Marathon course. 

“I don’t know what happened,” she said. “I probably shouldn’t have kept going, but I did.” 

Advertisement

At Mile 15, Johnson stopped at a bus that was there to pick up runners who needed to step away from the course. 

She asked her mom for a sign to keep going. 

“Her favorite song came on the bus radio,” Johnson said. “I finished the race for her.” 

Johnson started running at the end of 2021, and by 2022, she qualified for her first half marathon. Since then, she has completed marathons across the country, including three Boston Marathons.

Johnson’s young daughters meet her at the finish line each year. (Courtesy of Jessica Johnson)

Next week, on April 20, she will run the Boston Marathon for the fourth time on its 130th anniversary, alongside 30,000 fellow runners. 

Advertisement

Founded in 1897, the Boston Marathon is one of the pinnacles of racing for marathon runners. It was one of the first to allow women to compete, and the first to feature a wheelchair division. 

Each year, over 500,000 spectators line up along the course to cheer on runners — from Hopkinton, to Natick, to Newton and finally, the finish line in Boston’s Copley Square, where Johnson’s daughters will be waiting for her. 

Johnson’s daughters have motivated her to finish the race every time, she said. 

“I’m always looking to set an example of what hard work does,” Johnson said. “But it’s also about body positivity. I work really hard to get out there, and that’s what I want to show them.” 

Each year, Johnson runs the marathon in honor of her mother, who passed away from brain cancer. (Courtesy of Jessica Johnson)

Johnson also runs to honor others who have lost their lives to cancer. Year after year, she asks her community who they would like to honor, and writes their names on her arms. 

Advertisement

“Why not find a way to honor other people’s memories too?” she said. 

While each of her marathons has been powerful and uplifting, next week’s race will be her last. 

She hopes to run a different marathon each spring, something she can’t do while running in Boston. 

“I want a personal record on this one. That will give me closure,” she said. “I’m going to go out with a bang.” 

Johnson is still fundraising for the race, and donations can be made through her Venmo, @RunForResearch. All proceeds will benefit Dana Farber Cancer Institute.

Advertisement



Source link

Continue Reading

Boston, MA

Man seriously hurt in Dorchester crash – Boston News, Weather, Sports | WHDH 7News

Published

on

Man seriously hurt in Dorchester crash – Boston News, Weather, Sports | WHDH 7News


DORCHESTER, MASS. (WHDH) – A man was rushed to the hospital after a crash between a car and a scooter in Dorchester, according to Boston police.

Police responded to Aspinwall Road at approximately 8:51 p.m. for a report of a motor vehicle accident. Officers said they found one victim hurt on scene. He was taken to the hospital with life-threatening injuries. 

People who live in the area said the intersection sees a lot of scooter traffic in the warmer months of the year.

“It’s a little bit dangerous, especially when it gets warm because people are riding mopeds and riding bikes and stuff, and they do tricks,” said one woman who lives in the area. “It’s just a big intersection where cars are coming from every different way and you never know what’s going to happen.”

Advertisement

The crash is under investigation.

This is a developing news story; stay with 7NEWS on-air and online for the latest details.

(Copyright (c) 2026 Sunbeam Television. All Rights Reserved. This material may not be published, broadcast, rewritten, or redistributed.)

Join our Newsletter for the latest news right to your inbox



Source link

Advertisement
Continue Reading

Boston, MA

One Boston Day 2026: How to volunteer, take part across Boston

Published

on

One Boston Day 2026: How to volunteer, take part across Boston


One Boston Day 2026: How to volunteer, take part across Boston

Advertisement

HE’S NOW BEING CHARGED WITH ARMED ROBBERY. WE’RE COMING UP ON 637 AND WE ARE ALMOST THERE. A WEEK FROM TODAY, THOUSANDS OF RUNNERS WILL TURN ONTO BOYLSTON STREET AND CROSS THE FINISH LINE OF THE BOSTON MARATHON AND BOSTON AND THE BAY ARE KICKING OFF A WHOLE WEEK OF EVENTS BEFORE THE BIG DAY. STARTING WEDNESDAY, THE LINES ARE PAINTED PENDING GOOD WEATHER. THE WORK ON THE STARTING LINE BEGINS THAT DAY IN HOPKINTON. WORK ON THE FINISH LINE IN BACK BAY SHOULD BEGIN ON THURSDAY. SO EXCITING. ON WEDNESDAY IT WILL MARK ONE BOSTON DAY. OF COURSE, THAT’S THE DAY WE HONOR HOW THE CITY CAME TOGETHER IN THE DAYS FOLLOWING THE BOSTON MARATHON BOMBING. YOU ARE ASKED TO SHARE ACTS OF KINDNESS ALL DAY LONG. FINALLY, EVERYTHING MARATHON RELATED COMES TOGETHER ON FRIDAY WITH THE BOSTON MARATHON FAN EXPO. LIKE PREVIOUS YEARS, THAT WILL BE AT THE HYNES CONVENTION CENTER. FOR INFORMATION ON ALL THE EVENTS THIS WEEK, YOU CAN KEEP AN EYE ON WCVB.COM AND OUR MOBILE APP. THAT IS A THRILLING MOMENT WHEN YOU GO TO PICK UP YOUR NUMBER. IT WON’T BE LONG NOW. THE 130TH BOSTON MARATHON ON MONDAY, APRIL 20TH, WCVB.

Advertisement

One Boston Day 2026: How to volunteer, take part across Boston

Updated: 2:17 PM EDT Apr 13, 2026

Editorial Standards

Advertisement

Residents and visitors are encouraged to share acts of kindness marking One Boston Day on Wednesday, honoring how the city came together in the days after the Boston Marathon bombing, 13 years ago. The day will also include the annual memorials along Boylston Street. “I hope everyone will join their neighbors today in honoring those we lost and celebrating the love that makes Boston a home for everyone,” Mayor Michelle Wu wrote in a statement. “As spring arrives in Boston each year, we are reminded of the hope and spirit of our city,” said Bill Richard, who created a foundation in honor of his son, Martin, who was killed in the bombing.How to get involvedThe city of Boston and partner organizations are offering several ways for people to participate in One Boston Day and related events, according to the city:Volunteer projects citywide: City departments will host service opportunities on April 15 and in the days leading up to Marathon Monday.Neighborhood cleanup: A youth and family cleanup is scheduled for Saturday, April 18, at 9 a.m. at Franklin Park Playstead, organized by the Mayor’s Office of Civic Organizing. Volunteers are asked to register ahead of time. Free ‘Stop the Bleed’ training: Virtual sessions will be held April 15 at noon and 6 p.m. to teach lifesaving bleeding control techniques, offered by the Stepping Strong Center at Brigham and Women’s Hospital. Acts of kindness: Residents are encouraged to perform individual acts of kindness in their neighborhoods throughout the day and week.

Residents and visitors are encouraged to share acts of kindness marking One Boston Day on Wednesday, honoring how the city came together in the days after the Boston Marathon bombing, 13 years ago.

Advertisement

The day will also include the annual memorials along Boylston Street.

“I hope everyone will join their neighbors today in honoring those we lost and celebrating the love that makes Boston a home for everyone,” Mayor Michelle Wu wrote in a statement.

“As spring arrives in Boston each year, we are reminded of the hope and spirit of our city,” said Bill Richard, who created a foundation in honor of his son, Martin, who was killed in the bombing.

Advertisement

How to get involved

The city of Boston and partner organizations are offering several ways for people to participate in One Boston Day and related events, according to the city:

  • Volunteer projects citywide: City departments will host service opportunities on April 15 and in the days leading up to Marathon Monday.
  • Neighborhood cleanup: A youth and family cleanup is scheduled for Saturday, April 18, at 9 a.m. at Franklin Park Playstead, organized by the Mayor’s Office of Civic Organizing. Volunteers are asked to register ahead of time.
  • Free ‘Stop the Bleed’ training: Virtual sessions will be held April 15 at noon and 6 p.m. to teach lifesaving bleeding control techniques, offered by the Stepping Strong Center at Brigham and Women’s Hospital.
  • Acts of kindness: Residents are encouraged to perform individual acts of kindness in their neighborhoods throughout the day and week.

`;
}

Advertisement

function refreshWeatherIframe(containerId) {
var iframeId = ‘weather-iframe-‘ + containerId;
var iframe = document.getElementById(iframeId);
if (iframe && iframe.src) {
var originalSrc = iframe.src;
iframe.src = originalSrc + (originalSrc.indexOf(‘?’) > -1 ? ‘&’ : ‘?’) + ‘t=” + Date.now();
}
}

function initializeWeatherBox(container) {
var containerId = container.getAttribute(“data-container-id’);
var isWeatherBoxV2 = containerId === ‘home-weather-v2’;

function switchWeatherTab(tabName, clickedElement) {
container.querySelectorAll(‘[data-tab-id]’).forEach(function(tab) {
tab.classList.remove(‘open’);
tab.setAttribute(‘aria-selected’, ‘false’);
});

clickedElement.classList.add(‘open’);
clickedElement.setAttribute(‘aria-selected’, ‘true’);

container.querySelectorAll(‘[data-content-id]’).forEach(function(content) {
content.style.display = ‘none’;
content.setAttribute(‘hidden’, ‘true’);
});

Advertisement

var targetContent = container.querySelector(‘[data-content-id=”‘ + tabName + ‘”]’);
if (targetContent) {
targetContent.style.display = ‘block’;
targetContent.removeAttribute(‘hidden’);
}
}

function loadWeatherData() {
// If weather data is already being loaded, wait for it
if (window.weatherDataPromise) {
window.weatherDataPromise.then(function(data) {
if (data && data.data) {
var weatherContainer = container.closest(‘.weather-box-container’);
if (weatherContainer) {
weatherContainer.style.display = ‘flex’;
updateCurrentWeather(data.data);
updateForecastTabs(data.data);
updateWeatherAlertsBar(data.data);
}
}
});
return;
}

var location = { zip: window.DEFAULT_ZIPCODE };

try {
var storedLocations = localStorage.getItem(‘hrst.zip.history’);
if (storedLocations) {
var locations = JSON.parse(storedLocations);
if (locations && locations.length > 0) {
location = locations[0];
}
}
} catch (e) {}

var apiUrl = (window.DEWY_HOSTNAME || ”) + ‘/api/v1/weather/full/’ + location.zip;

Advertisement

if (window.fetch) {
window.weatherDataPromise = fetch(apiUrl)
.then(function(response) { return response.json(); })
.then(function(data) {
if (data && data.data) {
var article = container.closest(‘.article–wrapper’);
var weatherContainer = container.closest(‘.weather-box-container’);
if (weatherContainer) {
weatherContainer.style.display = ‘flex’;
updateCurrentWeather(data.data);
updateForecastTabs(data.data);
updateWeatherAlertsBar(data.data);
}
return data;
}
})
.catch(function(error) {
console.error(‘Error loading weather:’, error);
// Reset to unknown background on error
updateWeatherBackground(‘unknown’);
});
}
}

function updateWeatherAlertsBar(weatherData) {
var weatherWatchHeader = container.querySelector(‘.weather-watch-header’);
if (!weatherWatchHeader) return;

var weatherWatchText = weatherWatchHeader.querySelector(‘.weather-watch-text’);
var weatherWatchLink = weatherWatchHeader.querySelector(‘.weather-watch-link’);

if (weatherData.alerts_count > 0) {
weatherWatchHeader.className=”weather-watch-header has-alerts”;
if (weatherWatchText) {
weatherWatchText.textContent = `Weather Alerts (${weatherData.alerts_count})`;
}
if (weatherWatchLink) {
if (!weatherWatchLink.getAttribute(‘data-initial-href’)) {
weatherWatchLink.setAttribute(‘data-initial-href’, weatherWatchLink.getAttribute(‘href’));
weatherWatchLink.setAttribute(‘data-initial-onclick’, weatherWatchLink.getAttribute(‘onclick’) || ”);
}
weatherWatchLink.setAttribute(‘href’, “https://www.wcvb.com/alerts”);
weatherWatchLink.setAttribute(‘onclick’, “return handleWeatherLinkClick(event, ‘click_alerts’, ‘click’, ‘mobile-weather’, “https://www.wcvb.com/alerts”);”);
}
} else {
weatherWatchHeader.className=”weather-watch-header”;
if (weatherWatchText) {
weatherWatchText.textContent = containerId === ‘home-weather-v2’ ? ‘Watch Latest Forecast’ : ‘Latest Forecast’;
}
if (weatherWatchLink) {
var initialHref = weatherWatchLink.getAttribute(‘data-initial-href’);
var initialOnclick = weatherWatchLink.getAttribute(‘data-initial-onclick’);
if (initialHref) {
weatherWatchLink.setAttribute(‘href’, initialHref);
}
if (initialOnclick) {
weatherWatchLink.setAttribute(‘onclick’, initialOnclick);
}
}
}
}

function updateCurrentWeather(weatherData) {
if (weatherData.current) {
var tempValue = weatherData.current.temp_f || ”;
var skyValue = weatherData.current.sky || ”;
var feelsLikeValue = weatherData.current.feels_like_f || weatherData.current.temp_f || ”;

Advertisement

var tempEl = container.querySelector(‘.weather-grid–current-temp-value’);
if (tempEl) {
tempEl.textContent = tempValue;
tempEl.setAttribute(‘aria-label’, tempValue + ‘ degrees Fahrenheit’);
}

var iconEl = container.querySelector(‘.weather-grid–current-icon’);
if (iconEl && weatherData.current.icon_name) {
iconEl.className=”weather-grid–current-icon weather-current-icon icon icon-weather-” + weatherData.current.icon_name;
}

var skyEl = container.querySelector(‘.weather-grid–sky’);
if (skyEl) {
skyEl.textContent = skyValue;
skyEl.setAttribute(‘aria-label’, ‘Current condition: ‘ + skyValue);
}

var feelsEl = container.querySelector(‘.weather-grid–feels’);
if (feelsEl) {
feelsEl.textContent = feelsLikeValue + ‘°F’;
feelsEl.setAttribute(‘aria-label’, feelsLikeValue + ‘ degrees Fahrenheit’);
}

var weatherContainer = container.querySelector(‘.weather-temp-container’);
if (weatherContainer) {
var summary = ‘Current temperature ‘ + tempValue + ‘ degrees Fahrenheit, ‘ +
skyValue + ‘, feels like ‘ + feelsLikeValue + ‘ degrees’;
weatherContainer.setAttribute(‘aria-label’, summary);
}

Advertisement

updateWeatherBackground(weatherData.current.icon_name);
}
}

function updateWeatherBackground(iconName) {
try {
var bgPath = weatherImages.backgrounds[iconName] || weatherImages.backgrounds.unknown;
container.style.backgroundImage=”url(” + bgPath + ‘)’;
} catch (e) {
console.log(‘Error updating weather background:’, e);
}
}

function updateForecastTabs(weatherData) {
var visibleItems = isWeatherBoxV2 ? 6 : 5;

if (weatherData.hourly) {
var hourlyContainer = container.querySelector(‘.weather-hourly-forecast’);
if (hourlyContainer) {
var html=””;
var maxHours = Math.min(visibleItems, weatherData.hourly.length);

for (var i = 0; i 0 ? currentIndex – 1 : tabs.length – 1;
tabs[prevIndex].focus();
break;
case ‘ArrowRight’:
e.preventDefault();
var nextIndex = currentIndex

Advertisement

`;
}

function refreshWeatherIframe(containerId) {
var iframeId = ‘weather-iframe-‘ + containerId;
var iframe = document.getElementById(iframeId);
if (iframe && iframe.src) {
var originalSrc = iframe.src;
iframe.src = originalSrc + (originalSrc.indexOf(‘?’) > -1 ? ‘&’ : ‘?’) + ‘t=” + Date.now();
}
}

function initializeWeatherBox(container) {
var containerId = container.getAttribute(“data-container-id’);
var isWeatherBoxV2 = containerId === ‘home-weather-v2’;

function switchWeatherTab(tabName, clickedElement) {
container.querySelectorAll(‘[data-tab-id]’).forEach(function(tab) {
tab.classList.remove(‘open’);
tab.setAttribute(‘aria-selected’, ‘false’);
});

clickedElement.classList.add(‘open’);
clickedElement.setAttribute(‘aria-selected’, ‘true’);

Advertisement

container.querySelectorAll(‘[data-content-id]’).forEach(function(content) {
content.style.display = ‘none’;
content.setAttribute(‘hidden’, ‘true’);
});

var targetContent = container.querySelector(‘[data-content-id=”‘ + tabName + ‘”]’);
if (targetContent) {
targetContent.style.display = ‘block’;
targetContent.removeAttribute(‘hidden’);
}
}

function loadWeatherData() {
// If weather data is already being loaded, wait for it
if (window.weatherDataPromise) {
window.weatherDataPromise.then(function(data) {
if (data && data.data) {
var weatherContainer = container.closest(‘.weather-box-container’);
if (weatherContainer) {
weatherContainer.style.display = ‘flex’;
updateCurrentWeather(data.data);
updateForecastTabs(data.data);
updateWeatherAlertsBar(data.data);
}
}
});
return;
}

var location = { zip: window.DEFAULT_ZIPCODE };

try {
var storedLocations = localStorage.getItem(‘hrst.zip.history’);
if (storedLocations) {
var locations = JSON.parse(storedLocations);
if (locations && locations.length > 0) {
location = locations[0];
}
}
} catch (e) {}

Advertisement

var apiUrl = (window.DEWY_HOSTNAME || ”) + ‘/api/v1/weather/full/’ + location.zip;

if (window.fetch) {
window.weatherDataPromise = fetch(apiUrl)
.then(function(response) { return response.json(); })
.then(function(data) {
if (data && data.data) {
var article = container.closest(‘.article–wrapper’);
var weatherContainer = container.closest(‘.weather-box-container’);
if (weatherContainer) {
weatherContainer.style.display = ‘flex’;
updateCurrentWeather(data.data);
updateForecastTabs(data.data);
updateWeatherAlertsBar(data.data);
}
return data;
}
})
.catch(function(error) {
console.error(‘Error loading weather:’, error);
// Reset to unknown background on error
updateWeatherBackground(‘unknown’);
});
}
}

function updateWeatherAlertsBar(weatherData) {
var weatherWatchHeader = container.querySelector(‘.weather-watch-header’);
if (!weatherWatchHeader) return;

var weatherWatchText = weatherWatchHeader.querySelector(‘.weather-watch-text’);
var weatherWatchLink = weatherWatchHeader.querySelector(‘.weather-watch-link’);

if (weatherData.alerts_count > 0) {
weatherWatchHeader.className=”weather-watch-header has-alerts”;
if (weatherWatchText) {
weatherWatchText.textContent = `Weather Alerts (${weatherData.alerts_count})`;
}
if (weatherWatchLink) {
if (!weatherWatchLink.getAttribute(‘data-initial-href’)) {
weatherWatchLink.setAttribute(‘data-initial-href’, weatherWatchLink.getAttribute(‘href’));
weatherWatchLink.setAttribute(‘data-initial-onclick’, weatherWatchLink.getAttribute(‘onclick’) || ”);
}
weatherWatchLink.setAttribute(‘href’, “https://www.wcvb.com/alerts”);
weatherWatchLink.setAttribute(‘onclick’, “return handleWeatherLinkClick(event, ‘click_alerts’, ‘click’, ‘sidelist-weather’, “https://www.wcvb.com/alerts”);”);
}
} else {
weatherWatchHeader.className=”weather-watch-header”;
if (weatherWatchText) {
weatherWatchText.textContent = containerId === ‘home-weather-v2’ ? ‘Watch Latest Forecast’ : ‘Latest Forecast’;
}
if (weatherWatchLink) {
var initialHref = weatherWatchLink.getAttribute(‘data-initial-href’);
var initialOnclick = weatherWatchLink.getAttribute(‘data-initial-onclick’);
if (initialHref) {
weatherWatchLink.setAttribute(‘href’, initialHref);
}
if (initialOnclick) {
weatherWatchLink.setAttribute(‘onclick’, initialOnclick);
}
}
}
}

Advertisement

function updateCurrentWeather(weatherData) {
if (weatherData.current) {
var tempValue = weatherData.current.temp_f || ”;
var skyValue = weatherData.current.sky || ”;
var feelsLikeValue = weatherData.current.feels_like_f || weatherData.current.temp_f || ”;

var tempEl = container.querySelector(‘.weather-grid–current-temp-value’);
if (tempEl) {
tempEl.textContent = tempValue;
tempEl.setAttribute(‘aria-label’, tempValue + ‘ degrees Fahrenheit’);
}

var iconEl = container.querySelector(‘.weather-grid–current-icon’);
if (iconEl && weatherData.current.icon_name) {
iconEl.className=”weather-grid–current-icon weather-current-icon icon icon-weather-” + weatherData.current.icon_name;
}

var skyEl = container.querySelector(‘.weather-grid–sky’);
if (skyEl) {
skyEl.textContent = skyValue;
skyEl.setAttribute(‘aria-label’, ‘Current condition: ‘ + skyValue);
}

var feelsEl = container.querySelector(‘.weather-grid–feels’);
if (feelsEl) {
feelsEl.textContent = feelsLikeValue + ‘°F’;
feelsEl.setAttribute(‘aria-label’, feelsLikeValue + ‘ degrees Fahrenheit’);
}

Advertisement

var weatherContainer = container.querySelector(‘.weather-temp-container’);
if (weatherContainer) {
var summary = ‘Current temperature ‘ + tempValue + ‘ degrees Fahrenheit, ‘ +
skyValue + ‘, feels like ‘ + feelsLikeValue + ‘ degrees’;
weatherContainer.setAttribute(‘aria-label’, summary);
}

updateWeatherBackground(weatherData.current.icon_name);
}
}

function updateWeatherBackground(iconName) {
try {
var bgPath = weatherImages.backgrounds[iconName] || weatherImages.backgrounds.unknown;
container.style.backgroundImage=”url(” + bgPath + ‘)’;
} catch (e) {
console.log(‘Error updating weather background:’, e);
}
}

function updateForecastTabs(weatherData) {
var visibleItems = isWeatherBoxV2 ? 6 : 5;

if (weatherData.hourly) {
var hourlyContainer = container.querySelector(‘.weather-hourly-forecast’);
if (hourlyContainer) {
var html=””;
var maxHours = Math.min(visibleItems, weatherData.hourly.length);

Advertisement

for (var i = 0; i 0 ? currentIndex – 1 : tabs.length – 1;
tabs[prevIndex].focus();
break;
case ‘ArrowRight’:
e.preventDefault();
var nextIndex = currentIndex

Loading more articles…



Source link

Continue Reading

Trending