@ Jon
If your parent categories are empty, may you could use the option grouping feature. This would make the root parent categories non-selectable and visually different.
You would have to edit the slim-plus.php
file found here:
../wp-content/plugins/connections-slim-plus/
Look for this:
$atts = array(
'default' => self::$atts['str_select'] ,
'select_all' => self::$atts['str_select_all'],
'type' => self::$atts['enable_category_multi_select'] ? 'multiselect' : 'select',
'group' => self::$atts['enable_category_group_by_parent'],
'show_count' => self::$atts['show_category_count'],
'show_empty' => self::$atts['show_empty_categories'],
'parent_id' => self::$atts['enable_category_by_root_parent'] ? self::$atts['category'] : array(),
'exclude' => self::$atts['exclude_category'],
);
And change it to this:
$atts = array(
'default' => self::$atts['str_select'] ,
'select_all' => self::$atts['str_select_all'],
'type' => self::$atts['enable_category_multi_select'] ? 'multiselect' : 'select',
'group' => self::$atts['enable_category_group_by_parent'],
'show_count' => self::$atts['show_category_count'],
'show_empty' => self::$atts['show_empty_categories'],
'parent_id' => self::$atts['enable_category_by_root_parent'] ? self::$atts['category'] : array(),
'exclude' => self::$atts['exclude_category'],
'group' => TRUE,
);
If that is not an option, then you have to edit the class.template-parts.php
file found here:
../wp-content/plugins/connections/includes/template/
Look for this function. You have to apply an inline style or maybe add a class that you can use CSS to select and style to the option value when $level
is equal to 1
. Adding to the inline style will probably be a little easier because there would be less code to modify.
Hope that points you in the right direction.