Always show Member List on the right

Good morning.
How is it possible to display the sidebar on the right by default, without a need to click on it first?
And disable users from closing it?

Example:

Currently not possible. I’ll move this to a feature request.

BTW I like the theme! Looks slick :slight_smile:

Hi Aaron,
Is that possible to create a link to the members-list from the popover list in the sidebar? I would like to open the Members List tab from the sidebar drop-down list without entering the room. membersList

You might be able to run some JavaScript to pull it off. Maybe call the same method that is called when you click the button? You’d have to dig in the code a bit

Hi Aaron,
thanks for your response.
There are quite a few files involved in the action of tab events, and I cannot find which click event is responsible for opening the appropriate tab. Do you maybe know which file I have to dig in to call the right event?
contectualBar.js
tab.js
mebersList.js or corresponding HTML files.
I have already added to the sidebarItem.js the members’ list with the condition to only shows in direct or private groups. But obviously, there is no tabs event in the sidebar items was initially created.
Any help appreciated.
Regards
Laszlo

I think something has changed because you have the Member List always visible on your own support channel?

Can you tell me how I can set this up in my own RC installation?

Thanks!

1 Like

Anyone? In order to see who is online right away all my users are now adding direct chats to their favorites which lists the usernames on the left side. I just need to be able to set a pin on the members list to keep it visible all the time.

Any idea when this will be available? As I said you have this active on your own support channel.

Is there any change? I would like to see who is online at the right side of my window without having to click on the memberlist.

any news to this feature request?

This javascript checks if the channel changed and opens the memberlist of no sidebar is open.
You can add it to Administration > Layout > User defined Scripts > Script for logged-in users.
If you find it too laggy, change the interval from 1000 ms to a lower value.

The simulate-a-trusted-mouseclick-function is stolen from here.

function simulate(element, eventName)
{
    var options = extend(defaultOptions, arguments[2] || {});
    var oEvent, eventType = null;

    for (var name in eventMatchers)
    {
        if (eventMatchers[name].test(eventName)) { eventType = name; break; }
    }

    if (!eventType)
        throw new SyntaxError('Only HTMLEvents and MouseEvents interfaces are supported');

    if (document.createEvent)
    {
        oEvent = document.createEvent(eventType);
        if (eventType == 'HTMLEvents')
        {
            oEvent.initEvent(eventName, options.bubbles, options.cancelable);
        }
        else
        {
            oEvent.initMouseEvent(eventName, options.bubbles, options.cancelable, document.defaultView,
            options.button, options.pointerX, options.pointerY, options.pointerX, options.pointerY,
            options.ctrlKey, options.altKey, options.shiftKey, options.metaKey, options.button, element);
        }
        element.dispatchEvent(oEvent);
    }
    else
    {
        options.clientX = options.pointerX;
        options.clientY = options.pointerY;
        var evt = document.createEventObject();
        oEvent = extend(evt, options);
        element.fireEvent('on' + eventName, oEvent);
    }
    return element;
}

function extend(destination, source) {
    for (var property in source)
      destination[property] = source[property];
    return destination;
}

var eventMatchers = {
    'HTMLEvents': /^(?:load|unload|abort|error|select|change|submit|reset|focus|blur|resize|scroll)$/,
    'MouseEvents': /^(?:click|dblclick|mouse(?:down|up|over|move|out))$/
}
var defaultOptions = {
    pointerX: 0,
    pointerY: 0,
    button: 0,
    ctrlKey: false,
    altKey: false,
    shiftKey: false,
    metaKey: false,
    bubbles: true,
    cancelable: true
}

function checkURLchange() {
  	if (oldurl != window.location.href) {
      oldurl = window.location.href
      openMemberList()
    }
}
function openMemberList() {
  	var exists = document.querySelector('div[class="contextual-bar"]')
  	if (!exists) { 
      simulate(document.querySelector('button[aria-label="Members"]'), "click")
  	}
}
if (!oldurl) { 
  	var oldurl = window.location.href 
  	setInterval(checkURLchange,1000)
}
1 Like