How can I show a warning pop-up only when data is filled while navigating back and if data is not filled it should allow the user to navigate back without warning pop-up, pl