added options for setting legend pattern in HTML, and setting the height gap between the chart and the timeline