Column widths? #63

Closed
jamsi opened this Issue May 19, 2011 · 4 comments

Projects

None yet

5 participants

@jamsi
jamsi commented May 19, 2011

Any idea how to achieve this in Index as a table?

@gregbell
Collaborator

With the current implementation, changing widths is not possible. For this to work, the ActiveAdmin::Views::TableFor#column method should allow you to pass in the html attributes just like a DOM element.

https://github.com/gregbell/active_admin/blob/master/lib/active_admin/views/components/table_for.rb

@gregbell gregbell closed this May 19, 2011
@chrisval

Any news on the possibility to apply a particular class to a column? Or at least apply a width?

The class or with could be set like:

show_table 'table' do
column(:id, :class => 'my_class')
column(:date, :width => 123)
end

@follmann

I was also wondering about this. The documentation is here for reference: http://rubydoc.info/github/gregbell/active_admin/master/ActiveAdmin/Views/Columns

@MikeRogers0

I found an easier way is to target the column in the CSS like:

app/assets/stylesheets/active_admin.css

#index_table_users .col-misc {
  min-width: 85px;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment