Enabling and disabling tabs is really rather more difficult than it should be. Is there any chance of adding these as methods to RED.tabs?
As Steve pointed out in the other thread, a tab can be disabled/enabled using CSS pointer-events. That doesn't disable all of the contents of course, only being able to access them. But I think that is generally enough.
To disable:
$(`#red-ui-tab-${tab.id}`).css('pointer-events', 'none')
$(`#red-ui-tab-${tab.id} > a`).css('color', 'var(--nr-db-disabled-text)')
and enable with:
$(`#red-ui-tab-${tab.id}`).css('pointer-events', 'auto')
$(`#red-ui-tab-${tab.id} > a`).css('color', 'var(--nr-db-dark-text)')
So not terribly difficult to do - once you've discovered the trick! But it took me far too long to get there.
