0
Completed

Customize labels in community stats module

Shaun A Kranish 3 years ago in New features • updated by Ryann 3 years ago 4

In the Community stats side module, is it possible to change the wording "Community stats" and "Support agents" ? I've looked around but can't find it - apologies if I am overlooking it. For now, I would love it if we could change Support agents to "IEHA Staff"

Might be a nice feature to have those customizable in the module's settings.

Answer

Answer
Completed

Hello Shaun,

This module has no this type of customization, because very few clients want to customize this part.

But it is still possible to change this label via CSS or JS.

Here is an example of JS code:

<script>
    initqueue.push(
        function(){$('.module-stats .staff h3').text('IEHA Staff');}
    )
</script>

We've applied it in your Project settings->Custom CSS->External.

Here is the result:

Answer
Completed

Hello Shaun,

This module has no this type of customization, because very few clients want to customize this part.

But it is still possible to change this label via CSS or JS.

Here is an example of JS code:

<script>
    initqueue.push(
        function(){$('.module-stats .staff h3').text('IEHA Staff');}
    )
</script>

We've applied it in your Project settings->Custom CSS->External.

Here is the result:

Hello,

Very nice trick :-)

Is there a way to customize this customization to have different texts that (automatically) follow the current language of the user?

Sure, here it is:

<script>
    initqueue.push(
        function(){
           var label = 'My default label';            
           if ($('html').attr('lang') == 'fr'){
               label = 'My Fr label';
           }
            $('.module-stats .staff h3').text(label);
        }
    )
</script>