| | |
| | | <?php |
| | | namespace JVBase\admin; |
| | | |
| | | use JVBase\managers\IconsManager; |
| | | use JVBase\registrar\Registrar; |
| | | |
| | | if (!defined('ABSPATH')) { |
| | | exit; |
| | | } |
| | |
| | | // Hook into WordPress admin |
| | | add_action('admin_menu', [$this, 'registerAdminPages']); |
| | | add_action('admin_enqueue_scripts', [$this, 'enqueueAdminAssets']); |
| | | add_action(BASE.'dashboard_page_integrations', [$this, 'renderDashPage'], 10); |
| | | } |
| | | |
| | | /** |
| | |
| | | true |
| | | ); |
| | | |
| | | IconsManager::for()->enqueueIconStyles(); |
| | | IconsManager::for('dash')->enqueueIconStyles(); |
| | | IconsManager::for('forms')->enqueueIconStyles(); |
| | | |
| | | $queue = [ |
| | | 'api' => rest_url('jvb/v1/'), |
| | | 'redirect' => wp_login_url(home_url(add_query_arg(null, null))), |
| | | 'labels' => jvbGetLabels(), |
| | | 'labels' => Registrar::getLabels(), |
| | | ]; |
| | | |
| | | wp_localize_script('jvb-auth', 'jvbSettings', $queue); |
| | |
| | | // ); |
| | | } |
| | | |
| | | public function renderDashPage():void |
| | | { |
| | | $this->renderPage(); |
| | | } |
| | | /** |
| | | * Render the main integrations page |
| | | */ |
| | |
| | | <div class="jvb-admin-content"> |
| | | <?php |
| | | // Display any admin notices from form submissions |
| | | settings_errors('jvb_integrations'); |
| | | if (is_admin()) { |
| | | settings_errors('jvb_integrations'); |
| | | } |
| | | |
| | | $this->displayNotices(); |
| | | ?> |
| | | |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <?php $this->renderStyles(); ?> |
| | | <?php if (is_admin()) { |
| | | $this->renderStyles(); |
| | | } ?> |
| | | <?php |
| | | } |
| | | |
| | |
| | | |
| | | |
| | | --scrollbar-width: 8px; |
| | | --scrollbar-track-color: var(--base-100); |
| | | --scrollbar-thumb-color: var(--action-0); |
| | | --scrollbar-thumb-hover-color: var(--action-50); |
| | | --scrollbar-thumb-border: 2px solid var(--base-50); |
| | | --scrollbar-track-color: rgb(var(--base-100)); |
| | | --scrollbar-thumb-color: rgb(var(--action-0)); |
| | | --scrollbar-thumb-hover-color: rgb(var(--action-50)); |
| | | --scrollbar-thumb-border: 2px solid rgb(var(--base-50)); |
| | | --scrollbar-border-radius: 4px; |
| | | } |
| | | .item-grid.integrations { |