0

With some coding and getting the ratyrate to work into chartkick.js - there are very minimal tutorials regarding styling changes.

The data is working into the bar graph as shown below;

HTML Setup for display:

        <div class="col-md-4">
                <%= bar_chart Review.group(:rating).count(:rating), colors: ["blue"],  discrete: true %>
                <p>Sum of each Review</p>
                <%=@review_total_each%>
                <p><%=@review_count%> Total Review count</p>

        </div>

chartkick.js with data from ratyrate

Main objective is to get it to look like this;

  • have different colours per each rating number
  • reverse order with 5 being at the top
  • remove the bottom legend (only keep the left)
  • remove the lines between the bars
  • done need to worry about the average etc, only focussing on the colour changes to the bars

expected design outcome

I have read some tutorials although each review needs to become a unique data set and then you can complete colours. (Chartkick column charts multiple colors)

But still having no success.

Any help or guidance will be appreciated. (I can always update the question with requests)

Community
  • 1
  • 1
Biggztyle
  • 111
  • 1
  • 16

0 Answers0