Have been checking out the published research on this, and it's not clear cut.
There is a paper from a few years ago fn.bmj.com/content/88/6/F472.full which says the median nadir of weight loss is 2.7 days (nadir = lowest point) - but that does not mean weight loss lasting more than this is a clinical concern. The same paper showed a wide range of timings of the nadir. There may be more recent papers, and in fact there are, but they don't all look at the same thing.
Papers discussing the whole issue of newborn weight loss and strategies to assess its clinical significance almost all stress that weight is only part of the assessment - HCPs should check for the baby being healthy, with normal wees and poos and demonstrating effective, comfortable feeding.
I have not heard of any UK protocol which automatically flags up babies who have lost 20g between day 3 and 5, when the weight loss is still within normal limits.
30g a day weight gain from day 3 is very prescriptive - again, I don't know of protocols which insist on this.
The midwife who discussed it with you can maybe share their protocol, and explain why the other aspects of your baby's well-being are not being taken into account. There may be research evidence to support their policy (though I don't think they will find any for 30g a day after 3 days and if not, the baby is flagged), but there is not a definite 'right' and 'wrong' here.