We'd need the possibility to pass the current dashboard context to the external page. This works already e.g. with the session id of the currently logged in user by using a placeholder: https://localhost/?session={!$$SESSION}
see: https://experience.workfront.com/s/article/Embedding-External-Web-Pages-into-Dashboards-1487514310
So what we would need is something similar, like https://localhost/?projectID={!$$PROJECT.ID}