On this page, "radio" is listed as an option for a skinr type. It should be "radios".

http://skinr.org/skin-property-reference

(Also, please turn off the auto-rotation on the home tab, if that's an easy change! It's hard to follow the instructions with the pages turning.)

If an invalid type is used (such as radio), then skin options will duplicate.

For example, the definition below has one error: an invalid type for the second skin, "asdfasdf". The effect of the faulty code is General Styles will display twice. See screenshot.

  $skins['acquia_marina_general_styles'] = array(
    'title' => t('General Styles'),
    'type' => 'select',
    'attached' => array('css' => array('css/skins.css')),
    'default status' => TRUE,
    'group' => 'general',
    'options' => array(
      'rounded_corner' => array(
          'title' => t('Rounded Corner'), 
          'class' => array('marina-rounded-corners')
      ),
    ),
  );
  
  $skins['acquia_marina_my_lists'] = array(
    'title' => t('Lists Styles'),
    'type' => 'asdfsadf',
    'attached' => array('css' => array('css/skins.css')),
    'default status' => TRUE,
    'group' => 'general',
    'options' => array(
      'option_1' => array(
         'title' => t('Apply equal heights'),
         'class' => array('equal-heights'),
       ),
    ),
  );

Comments

moonray’s picture

Title: Change skin type "radio" to "radios" in documentation » If skin #type is invalid in skin plugin, last widget gets displayed twice
Component: Documentation » Code
Category: task » bug

Docs fixed, but the behavior you describe above sounds like a bug.

vrajak@gmail.com’s picture

I tested this also using Acquia Marina, and can confirm the behavior reported. "General Styles" does appear twice.
I didn't try using another theme yet but I can if you think that's necessary.

It would seem kind of moot since proper skin 'type' needs to be used for things to really work anyway, but the bug or whatever it is does exist.

moonray’s picture

Status: Active » Needs review
StatusFileSize
new4.91 KB

And here's a patch with tests and a fix.

moonray’s picture

Status: Needs review » Fixed

Committed the patch with some slight modifications to the test output text to make it more brief.

Status: Fixed » Closed (fixed)

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