solidus_user_roles icon indicating copy to clipboard operation
solidus_user_roles copied to clipboard

Menu Item offset? Deface

Open salverde opened this issue 7 years ago • 4 comments

Is the Roles supposed to be a sub item under users?

users

Seems like its at the root level. Is this a known issue?

salverde avatar Aug 15 '17 08:08 salverde

+1 did not figure out, how to make it possible with deface, used that in the initializer:

Spree::Backend::Config.configure do |config|
  # add roles to users admin submenu
  users_menu_index = config.menu_items.index { |i| i.label == :users }
  new_users_menu = config.class::MenuItem.new(
                     config.class::USER_TABS + [:roles],
                     'user',
                     condition: -> { Spree.user_class && can?(:admin, Spree.user_class) },
                     partial: 'spree/admin/shared/user_sub_menu'
                   )
  config.menu_items[users_menu_index] = new_users_menu
end

VitaliyAdamkov avatar Dec 08 '17 07:12 VitaliyAdamkov

Hello @VitaliyAdamkov

I fixed this issue with this pull request (https://github.com/boomerdigital/solidus_user_roles/pull/8). It was merge into master. Just use master version and should be fine.

Regards

memotoro avatar Feb 13 '18 09:02 memotoro

Beg my pardon, but as i can see, this pull request does not fix the 'Menu Item offset' issue..

VitaliyAdamkov avatar Feb 13 '18 10:02 VitaliyAdamkov

Hello @VitaliyAdamkov

What I did was to put a fonts awesome icon that pushes the 'Role' word to the right, it makes it aligned with the rest of the menu elements. However, I have the 'Role' menu as an independent module, not as sub-module of the 'Users' as you pointed out (I'm not sure why, I didn't notice that before). That fix worked for me, but you are right about the offset in the sub-module, it is not fixed yet.

Regards

selection_005

memotoro avatar Feb 13 '18 10:02 memotoro