First of all, the Brewers have access to the doctors treating Yelich and his medical records, fans don't. Second, the Brewers have access to Yelich in the off-season and could observe how he looks in whatever rehabilitation he had to do, running, hitting, etc., fans don't. Third, the Brewers coaching staff, doctors, and front office personnel saw him in spring training before he signed the extension, I think its logical to believe they were confident in Yelich's long-term health when he signed his extension and with nearly two hundred million dollars of the owner's money at stake, were simply not taking a guess that he'd be fully recovered from a knee cap fracture.
As to any complaints about the timing of the extension given Yelich had years remaining on his contract when the extension was signed, keep in mind it takes two to tango. For all we know as fans, Yelich told the Brewers "it's now or never" on a contract extension. Who knows? I can tell you if Yelich had continued to crush as a Brewer and walked as a free agent, there would be a percentage of fans calling the GM an idiot for letting him walk that is equal to the percentage that are critical of the extension. Damned if you do, damned if you don't.