Well, his days with the team were technically numbered and he's got some commendations which he definitely deserves. I don't know what to say about his intended replacement but all I'll say is Barcelona as a team has work to be done and I'd love to see the new Barcelona in seasons and games to come. It'll be very much important that Barcelona management tried their best to get a good replacement for Xavi and finding the best option for them would be a bit difficult. There are prospect options for them but they've got to be very careful in their choices.
Considering Emery as a choice, he's got an improved record with Villa and normally, Villa and Barcelona's level can't be compared so it's safe to say that it'd be a bit different to manage Barcelona based on their range of players and level in football. Barcelona isn't a team to be taken as an experiment. They won't be able to bear loosing their value and pride just because of them trying to make use of a manager who's not really had very much experience in a big team. Although, EPL is competitive than the La Liga, so maybe there can be a little match in strategy.
Hansi Flick will need a lot of time to build a team according to his wishes, borrowing players from other clubs or recruiting free transfer players will be one of the options available. At the same time, Hansi Flick is being asked to surpass Real Madrid consistency, so that Barcelona can win the La Liga championship trophy next season. This will be a tough task, and perhaps one of the toughest ever undertaken while being a coach. However, it is possible that Hansi Flick has many ways to overcome this difficult situation, so that he can bring Barcelona to success next season.