I need to make a simple indicator of the progress of the country's population bar.
I need a bar with a green progress bar for a good amount and another colored part for a bad amount, and a percentage in the middle of the bar.
Suppose the strip is 50 pixels wide and 15 pixels high. Think of a static progress bar as shown below.
I did this before using jquery and a background div with two additional div placed on top of it for good and bad indicators, and then a positioned div above it to display text.
However, I wonder if there is an even simpler solution with HTML5-canvas , SVG or CSS . Since this time control will be displayed in each row of a long table, the goal is to reduce the DOM , increase readability and reuse.
I know that there are libraries that do this, but I wanted to use it as a learning experience. The solution should be either not a script, or only JS, or JS with jquery.
My layout

