(Click here if you are unable to view this photo gallery or video on your mobile device.)

SAN FRANCISCO — Edwin Mah Lee, San Francisco’s first Asian-American mayor and the man who helped transform the City by the Bay into a tech capital, died early Tuesday morning. He was 65.

Lee suffered a heart attack while shopping for groceries Monday night, according to former Mayor Willie Brown, and was rushed to Zuckerberg San Francisco General Hospital. He was declared dead at 1:11 a.m. on Tuesday morning.

San Francisco Board of Supervisors President London Breed immediately became the city’s acting mayor. Breed and other city officials are expected to speak at 10 a.m. at San Francisco City Hall.

Lee was born in Seattle to immigrant parents, the fourth of six children. He grew up in a public housing project, and helped make deliveries for the family restaurant. His father also died of a heart attack while he was driving to work when he was 49 and the younger Lee was 15.

After getting his undergraduate degree at Bowdoin College in Maine, Lee came to the Bay Area to study at UC Berkeley Law School. As a civil rights lawyer and affordable housing activist, he represented low-income tenants and sued San Francisco agencies in several cases. He then turned to public service, working in city government under four mayors.

Lee was appointed mayor in January 2011, filling the remainder of Gavin Newsom’s term when he was elected lieutenant governor. Lee won election in his own right in November 2011 and was re-elected in 2015.

He was originally reluctant to take the mayor’s job and run for election, but decided to do so after urging from Brown.

“I don’t know San Francisco without Ed Lee,” Brown told CBS on Tuesday morning. “He had been the best qualified person to ever hold the job.”

As mayor, Lee helped attract tech companies to San Francisco, and gave tax credits to startups like Twitter and Zendesk in a bid to revitalize the somewhat-seedy Mid-Market neighborhood. He opened new shelters around the city to help address San Francisco’s visible and intractable homeless problem. But even as he championed funding for affordable housing, he faced criticism from activists for not doing enough to halt skyrocketing home prices.

The low-key, self-deprecating Lee had never held any elected office before becoming mayor, and he was always more comfortable as a technocrat than a campaigner.

“He truly loved the city, the nuts and bolts of how cities work, even though he never loved the politics,” Tony Winnicker, a senior adviser in Lee’s office for six years, said in an interview. “He was happiest with the people who cleaned the streets or tended to the parks… he wasn’t a politician, that wasn’t in his DNA.”

Lee is survived by his wife Anita — who he met in a language exchange program in her native Hong Kong — and his two daughters, Brianna and Tania.

“I will work with each and every one of you to see that constituents are well-served, that the doors of diversity and opportunity are open,” he told supervisors, staff and family members in the City Hall rotunda as he was sworn in in January 2011.

Breed, 43, who grew up in San Francisco public housing half a mile from City Hall and worked for the city and ran a nonprofit before being elected supervisor, becomes the city’s second woman, second African-American and first African-American woman to become mayor.

Tributes to Lee poured in from California leaders.

“All who knew Mayor Lee understood him as a true gentleman of great warmth, positivity and kindness,” said House Minority Leader Nancy Pelosi, who represents San Francisco. “He knew the rhythms and the workings of San Francisco at the most granular level, and dedicated decades to improving the lives of all San Franciscans.”

Related Articles Social media reaction to sudden death of San Francisco Mayor Ed Lee

In wake of Ed Lee’s death, researchers note that heart attacks often incorrectly blamed “I know what this is like and wish I could give Anita a hug and express my sorrow,” said Dianne Feinstein, California’s senator and a former San Francisco mayor, who was elevated to the mayor’s office after the murder of Mayor George Moscone. “Ed was an excellent mayor of a great but sometimes challenging city.”

“Ed was a good and incredibly gracious man,” said San Jose Mayor Sam Liccardo, “at a time when goodness, graciousness, and civility are not sufficiently appreciated in public life.”

Check back for updates.