Accidents after being potty trained

I need advice what to do with my 2.5 year old who started to poop and pee her pants after being accident free for about 5 months. First I stayed calm and told her she is a big girl and she knows how to use a potty and if she needs help she can just tell me (she likes to go by herself but sometime she is too slow I thought but recently she doesn’t even go to the toilet, just plays with her toys and does it in her pants like when she used to have a diaper 6 months ago. I kept asking her if she has to go and she said no and then did it. She did it in her pants while she was in a bathroom with my husband who was taking a shower with the toilet right in a front of her. Today, I made her to clean herself and she didn’t care. She picked up the poop like it was a toy. Last month I was diagnosed with the breast cancer and I realize it can effect her more then I think but except this she is happy normal toddler. What would u do? She didn’t wear diapers for almost 6 months and I don’t want to put it back on her but do u think I should? She even stayed dry in daycare for multiple weeks🤦🏼‍♀️ I am not a lazy parent but with chemo and feeling so tired all the time I don’t want to make this traumatizing for her and I know being upset at her won’t help anything.