As many on here will say, "How long is a piece of string?"
Such a low weight may indicate she hasn't possibly got much resilience should she get an infection, but I've known people at that weight and stage hang on for months and months.
If she's still eating and drinking, although at what is considered 'end-of-life' stage, that doesn't mean that her demise is actually imminent.
My mother was 'technically' at end-of-life stage for around 18 months and was certainly in the most severe, advanced stages of dementia by that time. During those months we had many emergencies, which could have proved fatal, but in fact didn't.
I recommend you don't put your life 'on hold' as it may be a while off yet. Then there are others who are nowhere near obviously at end-of-life, who die suddenly. It really is so variable, but from personal observations with my own relatives and others in those advanced stages , is that the dementia almost seems to make that last stage last much longer than those not obviously so severe.