codeplant / simple-navigation

A ruby gem for creating navigations (with multiple levels) for your Rails, Sinatra or Padrino applications. Render your navigation as html list, link list or breadcrumbs.
http://simple-navigation-demo.codeplant.ch/
MIT License
885 stars 136 forks source link

Add #dom_attributes option to ItemContainer. #142

Closed jtomaszewski closed 10 years ago

jtomaszewski commented 10 years ago

This allows you to define other html attributes than :id and :class on menu container. I needed this in order to define some 'ng-...' attributes on <ul> element, which was impossible for me without this change.

This includes backward compability for item_container.dom_id= and item_container.dom_class=, so the old way of setting it is still okay and won't be broken.

jtomaszewski commented 10 years ago

Thanks! =)

andi commented 10 years ago

Thanks for this change. Could you change the corresponding FAQ in the wiki? That would be awesome. https://github.com/andi/simple-navigation/wiki/FAQ#wiki-q4

jtomaszewski commented 10 years ago

Done.

andi commented 10 years ago

Specs are failing for me. Can you try yourself and fix?

jtomaszewski commented 10 years ago

I'll try it in a second.