Several fields in a cluster
Since v3.18.0INFO
To fully understand this section, you should be familiar with the stacked
field option and resource panels
. These concepts will help you structure and customize your fields effectively.
The cluster
DSL allows you to group multiple fields horizontally within a panel
. This is useful for organizing related fields in a structured layout.
To enhance readability and maintain a well-organized UI, it is recommended to use the stacked
option for fields inside clusters.

ruby
# app/avo/resources/user.rb
class Avo::Resources::Person < Avo::BaseResource
def fields
panel "Address" do
cluster do
field :street_address, stacked: true do
"1234 Elm Street"
end
field :city, stacked: true do
"Los Angeles"
end
field :zip_code, stacked: true do
"15234"
end
end
end
end
end