| @@ -426,8 +426,10 @@ | ||
| 426 | 426 | 'timeticsPro' => class_exists('TimeticsPro') ? true : false, |
| 427 | 427 | 'demo_url' => $this->demo_url(), |
| 428 | 428 | 'current_user' => timetics_get_current_user(), |
| 429 | 429 | 'aisentic' => $this->get_aisentic_state(), |
| 430 | + 'theme_mode' => Core\Admin\Theme_Mode::get_for_localize(), | |
| 431 | + 'dark_mode_enabled' => Core\Admin\Theme_Mode::is_enabled(), | |
| 430 | 432 | ); |
| 431 | 433 | |
| 432 | 434 | $localize_obj = apply_filters( 'timetics_admin_localize_data', $localize_obj ); |
| 433 | 435 | |
| @@ -457,8 +459,10 @@ | ||
| 457 | 459 | * the UI hides the offer instead of promising something dead. |
| 458 | 460 | */ |
| 459 | 461 | 'supports_registration' => class_exists( 'Aisentic\Api\Services\Registration_Service' ), |
| 460 | 462 | 'terms_url' => 'https://arraytics.com/terms-of-service/', |
| 463 | + // Only people who could install Aisentic by hand get the setup dialog. | |
| 464 | + 'can_setup' => current_user_can( 'manage_options' ) && current_user_can( 'install_plugins' ), | |
| 461 | 465 | ]; |
| 462 | 466 | } |
| 463 | 467 | |
| 464 | 468 | /** |