Apparently this is the aircraft to solve Ukraine's problems.
Yes, we can transfer the Hungarian Gripen to the Ukrainians
That may upset the Hungarians, the question I would have is whether Sweden could produce enough aircraft and parts to supply everyone.
This is the big advantage something like the F-16 has, they have a significant number mothballed already so parts and aircraft aren't an issue but they aren't really as well suited to Ukraine as the Grippen would be.
Sweden has a lot of Gripen C now when our air force is replacing them with the Gripen D and E, but spare parts will be a problem so it is better to give the Ukrainians F-16 instead. Finland is buying the F-35 so they will have F-18 to give if the Ukrainians want them
The other worry with giving Ukraine something like the F-18 is that it is putting a newer generation of technology at risk of falling into Russian hands.