Skip to content
Looking for every option?See the full API reference →

Progress bar ​

The progress_bar field displays a number as a progress bar on Index and Show views and lets users change it with a range slider on Edit and New views.

ruby
# app/avo/resources/project.rb
field :progress, as: :progress_bar

By default, the range runs from 0 to 100 with increments of 1, and the numeric value is hidden.

An Avo index table with ID, Name and Progress columns where each row shows a progress bar with its percentage value.

Set the range and slider increments ​

If your values use a scale other than 100, set max. Use step to control the slider increments on Edit and New. The minimum is fixed at 0.

Show the value and its units ​

Enable display_value to show the number beside the bar on Index and Show and above the slider on Edit and New. Add value_suffix for units such as %; the suffix is only visible when the value is displayed and does not change the stored number.

ruby
# app/avo/resources/project.rb
field :progress,
  as: :progress_bar,
  max: 150,
  step: 10,
  display_value: true,
  value_suffix: "%"
An Avo edit-form card containing a progress_bar field showing the value above a range slider configured with max 150, step 10 and a percent suffix.

For shared settings such as visibility and read-only behavior, see Common field options.