protected function activateFirstVisibleTab()
    {
        foreach ($this->items as $i => $item) {
            $active = ArrayHelper::getValue($item, 'active', null);
            $visible = ArrayHelper::getValue($item, 'visible', true);
            if ($visible && $active !== false) {
                $this->items[$i]['active'] = true;
                return;
            }
        }
    }
protected function activateFirstVisibleTab()
    {
        foreach ($this->items as $i => $item) {
            $active = ArrayHelper::getValue($item, 'active', null);
            $visible = ArrayHelper::getValue($item, 'visible', true);
            if ($visible && $active !== false) {
                $this->items[$i]['active'] = true;
                return;
            }
        }
    }
protected function activateFirstVisibleTab ( ) { foreach ( $ this -> items as $ i => $ item ) { $ active = ArrayHelper :: getValue ( $ item , 'active' , null ) ; $ visible = ArrayHelper :: getValue ( $ item , 'visible' , true ) ; if ( $ visible && $ active !== false ) { $ this -> items [ $ i ] [ 'active' ] = true ; return ; } } }
Sets the first visible tab as active.

This method activates the first tab that is visible and
not explicitly set to inactive (`'active' => false`).
Sets the first visible tab as active .