Файловый менеджер - Редактировать - /home/digitalm/invisalign/wp-content/themes/healthy-smiles/kits/settings/general/logo.php
Назад
<?php namespace HealthySmilesSpace\Kits\Settings\General; use HealthySmilesSpace\Kits\Controls\Controls_Manager as CmsmastersControls; use HealthySmilesSpace\Kits\Settings\Base\Settings_Tab_Base; use Elementor\Controls_Manager; use Elementor\Utils; if ( ! defined( 'ABSPATH' ) ) { exit; // Exit if accessed directly } /** * Logo settings. * * @since 1.0.0 */ class Logo extends Settings_Tab_Base { /** * Get toggle name. * * Retrieve the toggle name. * * @since 1.0.0 * * @return string Toggle name. */ public static function get_toggle_name() { return 'logo'; } /** * Get title. * * Retrieve the toggle title. * * @since 1.0.0 */ public function get_title() { return esc_html__( 'Logo', 'healthy-smiles' ); } /** * Get control ID prefix. * * Retrieve the control ID prefix. * * @return string Control ID prefix. */ protected static function get_control_id_prefix() { $toggle_name = self::get_toggle_name(); return parent::get_control_id_prefix() . "_{$toggle_name}"; } /** * Register toggle controls. * * Registers the controls of the kit settings tab toggle. * * @since 1.0.0 */ protected function register_toggle_controls() { $this->add_control( 'type', array( 'label' => esc_html__( 'Type', 'healthy-smiles' ), 'label_block' => false, 'description' => esc_html__( 'This setting will be applied after save and reload.', 'healthy-smiles' ), 'type' => CmsmastersControls::CHOOSE_TEXT, 'options' => array( 'image' => esc_html__( 'Image', 'healthy-smiles' ), 'text' => esc_html__( 'Text', 'healthy-smiles' ), ), 'default' => $this->get_default_setting( $this->get_control_name_parameter( '', 'type' ), 'image' ), 'toggle' => false, ) ); $this->add_control( 'image', array( 'description' => esc_html__( 'This setting will be applied after save and reload.', 'healthy-smiles' ), 'type' => Controls_Manager::MEDIA, 'default' => array( 'url' => Utils::get_placeholder_image_src() ), 'condition' => array( $this->get_control_id_parameter( '', 'type' ) => 'image', ), ) ); $this->add_control( 'retina_toggle', array( 'label' => esc_html__( 'Retina Image', 'healthy-smiles' ), 'type' => Controls_Manager::POPOVER_TOGGLE, 'condition' => array( $this->get_control_id_parameter( '', 'type' ) => 'image', $this->get_control_id_parameter( '', 'image[url]!' ) => '', ), ) ); $this->start_popover(); $this->add_control( 'retina_image', array( 'description' => esc_html__( 'This setting will be applied after save and reload.', 'healthy-smiles' ), 'type' => Controls_Manager::MEDIA, 'default' => array( 'url' => Utils::get_placeholder_image_src() ), 'condition' => array( $this->get_control_id_parameter( '', 'type' ) => 'image', $this->get_control_id_parameter( '', 'image[url]!' ) => '', $this->get_control_id_parameter( '', 'retina_toggle' ) => 'yes', ), ) ); $this->end_popover(); $this->start_controls_tabs( 'text_tabs', array( 'condition' => array( $this->get_control_id_parameter( '', 'type' ) => 'text', ), ) ); $this->start_controls_tab( 'text_title_tab', array( 'label' => esc_html__( 'Title', 'healthy-smiles' ), ) ); $this->add_control( 'title_text', array( 'label_block' => true, 'show_label' => false, 'description' => esc_html__( 'This setting will be applied after save and reload.', 'healthy-smiles' ), 'type' => Controls_Manager::TEXT, 'placeholder' => ( get_bloginfo( 'name' ) ? get_bloginfo( 'name' ) : esc_html__( 'Site logo', 'healthy-smiles' ) ), ) ); $this->add_var_group_control( 'title', self::VAR_TYPOGRAPHY ); $this->add_control( 'title_colors_text', array( 'label' => esc_html__( 'Color', 'healthy-smiles' ), 'type' => Controls_Manager::COLOR, 'dynamic' => array(), 'selectors' => array( ':root' => '--' . $this->get_control_prefix_parameter( '', 'title_colors_text' ) . ': {{VALUE}};', ), ) ); $this->add_control( 'title_colors_hover', array( 'label' => esc_html__( 'Hover', 'healthy-smiles' ), 'type' => Controls_Manager::COLOR, 'dynamic' => array(), 'selectors' => array( ':root' => '--' . $this->get_control_prefix_parameter( '', 'title_colors_hover' ) . ': {{VALUE}};', ), ) ); $this->end_controls_tab(); $this->start_controls_tab( 'text_subtitle_tab', array( 'label' => esc_html__( 'Subtitle', 'healthy-smiles' ), ) ); $this->add_control( 'subtitle_text', array( 'label_block' => true, 'show_label' => false, 'description' => esc_html__( 'This setting will be applied after save and reload.', 'healthy-smiles' ), 'type' => Controls_Manager::TEXT, 'placeholder' => esc_html__( 'Logo subtitle', 'healthy-smiles' ), ) ); $this->add_var_group_control( 'subtitle', self::VAR_TYPOGRAPHY ); $this->add_control( 'subtitle_colors_text', array( 'label' => esc_html__( 'Color', 'healthy-smiles' ), 'type' => Controls_Manager::COLOR, 'dynamic' => array(), 'selectors' => array( ':root' => '--' . $this->get_control_prefix_parameter( '', 'subtitle_colors_text' ) . ': {{VALUE}};', ), ) ); $this->add_control( 'subtitle_colors_hover', array( 'label' => esc_html__( 'Hover', 'healthy-smiles' ), 'type' => Controls_Manager::COLOR, 'dynamic' => array(), 'selectors' => array( ':root' => '--' . $this->get_control_prefix_parameter( '', 'subtitle_colors_hover' ) . ': {{VALUE}};', ), ) ); $this->end_controls_tab(); $this->end_controls_tabs(); $this->add_control( 'apply_settings', array( 'label_block' => true, 'show_label' => false, 'type' => Controls_Manager::BUTTON, 'text' => esc_html__( 'Save & Reload', 'healthy-smiles' ), 'event' => 'cmsmasters:theme_settings:apply_settings', 'separator' => 'before', ) ); } }
| ver. 1.4 |
Github
|
.
| PHP 8.3.23 | Генерация страницы: 0.06 |
proxy
|
phpinfo
|
Настройка