This commit is contained in:
User A0264400
2026-04-19 15:38:03 +03:00
parent 7b24f58aeb
commit bbfa5766ae
1669 changed files with 894 additions and 177073 deletions

View File

@@ -0,0 +1,89 @@
<?php
/**
* The page Settings.
*
* @since 1.0.0
*/
// Exit if accessed directly
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
/**
* Класс отвечает за работу страницы настроек
*
* @version 1.0
*/
class WRIO_Page extends WBCR\Factory_Templates_759\Impressive {
/**
* {@inheritdoc}
*/
public $page_parent_page = null;
/**
* {@inheritdoc}
*/
public $available_for_multisite = false;
/**
* {@inheritdoc}
*/
public $clearfy_collaboration = false;
/**
* {@inheritdoc}
*
* @var bool
*/
public $show_right_sidebar_in_options = false;
/**
* Hide bottom sidebar by default - only show on Settings page
*
* @var bool
*/
public $show_bottom_sidebar = false;
/**
* @since 1.3.0
* @var WRIO_Views
*/
protected $view;
/**
* @param WRIO_Plugin $plugin
*/
public function __construct( WRIO_Plugin $plugin ) {
$this->view = WRIO_Views::get_instance( WRIO_PLUGIN_DIR );
if ( is_multisite() && defined( 'WCL_PLUGIN_ACTIVE' ) ) {
if ( WRIO_Plugin::app()->isNetworkActive() && WCL_Plugin::app()->isNetworkActive() ) {
$this->clearfy_collaboration = true;
}
} elseif ( defined( 'WCL_PLUGIN_ACTIVE' ) ) {
$this->clearfy_collaboration = true;
}
parent::__construct( $plugin );
}
/**
* Подменяем простраинство имен для меню плагина, если активирован плагин
* Меню текущего плагина будет добавлено в общее меню
*
* @return string
*/
public function getMenuScope() {
if ( $this->clearfy_collaboration ) {
$this->page_parent_page = 'rio_general';
return 'wbcr_clearfy';
}
return 'robin-image-optimizer';
}
}