updated navigation width function