calculate public directories in the context of the view