I'm placing a menu proxy into a MasterPage (Template Page), and I want to apply my own CSS to the list the menu proxy creates.
I'm unable to find the element/class reference for the menu proxy. I have the CSS for an unordered list, but I'm having trouble finding how to apply that CSS to a menu proxy element.
I appreciate any advice.
Jim
Styling a Menu Proxy
-
- Propeller Head
- Posts: 84
- Joined: Tue Jun 04, 2013 9:49 am
- Location: Arkansas, U.S.A.
Re: Styling a Menu Proxy
Hi Jim,
I have a few different menu proxies that I style with my own CSS. I create a skin file and in the menu proxy's settings, assign it that skin file. On the build, Flare assigns a class name of _Skins_ plus whatever you named the skin to the <ul> created by the menu proxy.
For example, if I have a menu proxy assigned with a skin called mymenuskin Flare applies a class called _Skins_mymenuskin to the <ul>.
Flare also always assigns a class called menu and mc-component to these, so to make sure any styles I'm applying in a CSS file overwrite a conflicting style from the skin file, I'll usually target the menu with something like this:
From there, depending on which part you want to style and how many levels your menu proxy shows, you might need a complex selector to reach them, such as:
I hope this helps.
I have a few different menu proxies that I style with my own CSS. I create a skin file and in the menu proxy's settings, assign it that skin file. On the build, Flare assigns a class name of _Skins_ plus whatever you named the skin to the <ul> created by the menu proxy.
For example, if I have a menu proxy assigned with a skin called mymenuskin Flare applies a class called _Skins_mymenuskin to the <ul>.
Flare also always assigns a class called menu and mc-component to these, so to make sure any styles I'm applying in a CSS file overwrite a conflicting style from the skin file, I'll usually target the menu with something like this:
Code: Select all
ul.menu._Skins_mymenuskin.mc-component
Code: Select all
ul.menu._Skins_mymenuskin.mc-component > li > a
I hope this helps.
-
- Propeller Head
- Posts: 84
- Joined: Tue Jun 04, 2013 9:49 am
- Location: Arkansas, U.S.A.
Re: Styling a Menu Proxy
Dave, thank you so much for this advice. I don't like the fact that Flare will dictate a skin (if there's one in my project) if I don't specify one. This leaves my project open to someone modifying the dictated skin for this menu... when in fact, that skin might be used for a menu in another part of my project.... thus potentially changing all other menus that ARE associated to a skin.
Thank you for your advice!
Jim
Thank you for your advice!
Jim