XF 2.0 How to Hide unselectable styles

Currently reading:
XF 2.0 How to Hide unselectable styles

Nirjonadda

Well-Known Member
Dec 27, 2017
73
7
Please let me know that How to Hide unselectable styles from admin? Back in XF1, there was a css code to hide the unselectables styles like this:

Code:
.unselectable
{
    display: none;
}
Is there a way to do this in XF2 via extra.less?
 

Nirjonadda

Well-Known Member
Dec 27, 2017
73
7
I'll see what I can do...
Do you get that how to work?

Adding class in The template: style_chooser

Code:
                    <xf:foreach loop="$styles" value="$style">
                        <li>
                            <a href="{{ link('misc/style', null, {
Add in the class on the <li>

Code:
                    <xf:foreach loop="$styles" value="$style">
                        <li class="{{ !$style.user_selectable ? 'unselectable' : 'selectable' }}">
                            <a href="{{ link('misc/style', null, {
But I need work without manually template edit. So need add-on for automatic apply the template.
 

Create an account or login to comment

You must be a member in order to leave a comment

Create account

Create an account on our community. It's easy!

Log in

Already have an account? Log in here.

Welcome to customizeXF

We are running default XenForo style customized by cXF
Registration is free!

Search forums

Similar threads

Sticky sidebar

You'd like to have sticky sidebar on your forum? Click below.

Top