Prevent double minus in chart
Flatten HTML formatter and move logic to the history