minor refactor to load-on-view detection for line_chart on page load