PluginProbe ʕ •ᴥ•ʔ
پارسی دیت – Parsi Date / trunk
پارسی دیت – Parsi Date vtrunk
6.2.1 6.2 6.1 5.1.6 5.1.7 5.1.8 5.1.8.2 6.0 trunk 1.0 1.1 1.2 1.3 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 2.0.0-alpha 2.1 2.1.1 2.1.2 2.1.3 2.1.5 2.1.6 2.1.7 2.2.0 2.2.1 2.2.2 2.2.3 2.3.0.1 2.3.0.2 2.3.1 2.3.2 2.3.3 2.3.4 3.0.1 3.0.2 3.0.3 4.0.0 4.0.1 4.0.2 5.1.0 5.1.1 5.1.2 5.1.3 5.1.4 5.1.5
wp-parsidate / inc / Admin / AdminCore.php
wp-parsidate / inc / Admin Last commit date
Admin.php 3 months ago AdminAbout.php 1 month ago AdminAssets.php 1 month ago AdminConvert.php 3 months ago AdminCore.php 1 month ago AdminDashboard.php 1 month ago AdminIntegration.php 1 month ago AdminPages.php 1 month ago AdminSettings.php 1 month ago AdminTools.php 1 month ago
AdminCore.php
47 lines
1 <?php
2
3 namespace WPParsidate\Admin;
4
5 defined( 'ABSPATH' ) || exit;
6
7 class AdminCore {
8 public const tab = 'core';
9 public const icon = '<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><g id="SVGRepo_bgCarrier" stroke-width="0"></g><g id="SVGRepo_tracerCarrier" stroke-linecap="round" stroke-linejoin="round"></g><g id="SVGRepo_iconCarrier"> <path d="M20.9423 3.05768C23.4117 5.52701 21.4099 11.5324 16.4712 16.4711C11.5326 21.4097 5.5272 23.4115 3.05787 20.9422C0.588547 18.4728 2.59033 12.4675 7.52899 7.5288C12.4676 2.59014 18.473 0.588345 20.9423 3.05768ZM3.05768 3.05782C0.588349 5.52715 2.59013 11.5325 7.52879 16.4712C12.4674 21.4099 18.4728 23.4117 20.9421 20.9423C23.4115 18.473 21.4097 12.4676 16.471 7.52894C11.5324 2.59028 5.527 0.588485 3.05768 3.05782Z" stroke="#3c3c3c" stroke-width="1.5"></path> <path d="M14.5 12C14.5 13.3807 13.3807 14.5 12 14.5C10.6193 14.5 9.5 13.3807 9.5 12C9.5 10.6193 10.6193 9.5 12 9.5C13.3807 9.5 14.5 10.6193 14.5 12Z" stroke="#3c3c3c" stroke-width="1.5"></path> </g></svg>';
10
11 private static ?array $settings = null;
12
13 public function __construct() {
14 add_filter( 'wp_parsidate_menus', [ $this, 'addMenu' ] );
15 add_filter( 'wp_parsidate_' . self::tab . '_settings', [ $this, 'settings' ] );
16 add_filter( 'wp_parsidate_settings', [ $this, 'allSettings' ] );
17 }
18
19 public function addMenu( $menus ) {
20 $menus[ self::tab ] = array(
21 'title' => esc_html__( 'Core', 'wp-parsidate' ),
22 'icon' => self::icon
23 );
24
25 return $menus;
26 }
27
28 public function allSettings( $settings ): array {
29 $settings[ self::tab ] = $this->settings();
30
31 return $settings;
32 }
33
34 public function settings(): array {
35 if ( self::$settings === null ) {
36 self::$settings = array(
37 'title' => esc_html__( 'Core settings', 'wp-parsidate' ),
38 'desc' => esc_html__( 'Global plugin settings', 'wp-parsidate' ),
39 'sections' => apply_filters( 'wp_parsidate_' . self::tab . '_settings_sections', [] )
40 //'settings' => apply_filters( 'wp_parsidate_' . self::tab . '_settings_options', [] )
41 );
42 }
43
44 return self::$settings;
45 }
46 }
47