My bc came to me with a broken leg and heartworms, so I expericenced a similar situation in that she was kenneled for 8 weeks during treatments. I don't know if it is possible for you, but I would invite the neighbors over (some I told why, others I just invited in) for short amounts of time. I would get Liberty out of her kennel and have her lay down while they were there. Some I asked if they would pet her, others I intentionally did not. I have found now that she is "free" she doesn't expect everyone who enters the house to pet her. She also knows for the most part she is supposed to lay down and be quiet while guests are over. She was about 18 months old and really did very well.
Due to a suggestion on this list, I tried to play a lot of low key games with her like guess which hand the treat is in. We also did some massage therapy which allowed her to relax and me to feel like I was doing something helpful.
I know it is difficult, especially as they heal and feel better. Good luck with the recovery process.