When I was looking for a simple animated two sided horizontal bar graph, I couldn’t find one on the internet so I made it.
How it works:
1.You pass in the left score, right score and the description of the score in the middle.
2.Then the CSS will expand the bars outward proportional to the value pass in.
For example if left score is 5 and right score is 10, then the left side will be half the width of the right side.
HTML:
1 | <horizontalbargraph leftscore="leftScore" rightscore="rightScore" |
Angular:
1 | var app = angular.module('home', [ 'ui-tpl']) |
CSS:
1 | .horizontal-bar-graph{ |
hope this helps you out