Hi,
A client needed additional styles for a multi-themed site. I've added about 5 additional styles my copy of the module. You can see the first in action on the dev site at http://fhfvp.illuminateweb.org.uk - the others vary by colour only and use the colours in the logo.
I'd be happy to contribute these to the module. If you're interested, let me know.
Matthew

Comments

mehrpadin’s picture

Hey Matt,

If your clients don't mind this, well it's great! but since we're not going to see - I hope so - any new version any time soon - we actually don't need as the current release is very mature - I think you should upload them here, and I'll put a link back to it at the project page.

Thanks!

mshepherd’s picture

They're very pro-open source, so I think they'll be excited about it actually! I'll do that as soon as I can. Cheers for now.

mshepherd’s picture

Here's a patch against v1.6 to add in a few additional styles.

If you're not confident applying patches, you do the following. Find this code in superfish.module:

    $form['sf-settings']['superfish_style_'. $delta] = array(
      '#type' => 'select',
      '#title' => t('Style'),
      '#default_value' => variable_get('superfish_style_'. $delta, 'default'),
      '#options' => array(
        'default' => t('Default'),
        'blue' => t('Blue'),
        'coffee' => t('Coffee'),
        'light-blue' => t('Light blue'),
        'pomegranate' => t('Pomegranate'),
        'space' => t('Space [Blue]'),
        'space-orange' => t('Space [Orange]'),
        'space-teal' => t('Space [Teal]'),
        'spring' => t('Spring'),
        'white' => t('White')),

Remove one of the closing brackets and add a few lines so that 'white' => t('White')), becomes:

        'white' => t('White'),
        'vision-blue' => t('Vision Blue'),
        'vision-purple' => t('Vision Purple'),
        'vision-red' => t('Vision Red'),
        'vision-yellow' => t('Vision Yellow'),
        'vision-green' => t('Vision Green')),

Then unzip the attached superfish-more-styles-css.tar_.gz file into superfish/css/extra/

mshepherd’s picture

Status: Active » Fixed
mehrpadin’s picture

Status: Fixed » Active

Thank you so much!

mshepherd’s picture

No, thank you so much for a great module!
Matthew

mehrpadin’s picture

Status: Active » Closed (fixed)

:) you're welcome

janji’s picture

I added the code as above. And downloaded the css file. The new styles appear in the configuration but, when chosen, only the light blue standard style appears in the menu. Thanks for any suggestions!

mehrpadin’s picture

Hey there,

Basically, I don't recommend that patch, the best practice for this is to have the style in a CSS file outside of the modules directory, probably somewhere in your theme folder, and attaching the required classes to the main UL via your Superfish block config > Advanced CSS settings > Extra classes.

erok415’s picture

I tried modifying the module as shown in the example above. The new style showed up in the appearance panel option but it didn't apply the new style. It defaulted to the default style.

However, I did try @Mehrpadin's (comment #9) recommendation by adding the stylesheet in the /admin/structure/block "configure" "advanced settings" and it worked perfectly.

E.

erok415’s picture

Check this out.

It took me a few days to get this right while testing the the best styles to achieve this goal. See this post I created which gives a step-by-step instruction how to create rounded Bartik style tabs to the top nav position.
E.

See post: http://drupal.org/node/1073298

nancydru’s picture

Status: Closed (fixed) » Active

I'm building a church site where I wish to change the site colors based on the liturgical colors. Since your selections don't cover the whole set of seasons, I can create a the ones I need. It would be nice, however, if you could read the style directory and include them in the list. Is that possible?

nancydru’s picture

Version: 6.x-1.6 » 7.x-1.8

Setting to my release

nancydru’s picture

Sorry, I don't have have patching capabilities at the moment.

    $lib_base = 'sites/all/libraries/superfish';  // This is probably provided by Libraries API.
    $dir = $lib_base . '/style';
    $files = file_scan_directory($dir, '/.*\.css$/', array('recurse' => FALSE));
    $list = array('default' => t('Default'));
    foreach ($files as $path => $info) {
      $list[$info->name] = t(ucwords(str_replace(array('_', '-'), ' ', $info->name)));
    }

    $form['sf-settings']['superfish_style_'. $delta] = array(
      '#type' => 'select',
      '#title' => t('Style'),
      '#default_value' => variable_get('superfish_style_'. $delta, 'default'),
      '#options' => $list,
ckng’s picture

ysgrace’s picture

Version: 7.x-1.8 » 6.x-1.x-dev
Category: feature » support

Can't get the new Superfish styles to load after one is selected in block config. It's not recognizing the new css, perhaps. I put these new css files in libraries/superfish/css/extra/ ... is that correct name for folder? Thanx for helping a newbie.

tanitani’s picture

Actually the path s/b
sites/all/libraries/superfish/style

HTH,

Gábor

mehrpadin’s picture

Status: Active » Fixed

Nancy, Matt, everybody! thank you all :) added a similar functionality, try v1.9-beta3, thanks again!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.