Skip to content

Commit ff18976

Browse files
Merge pull request #12 from SolidDigital/feature/2025-sep
Feature/2025 sep
2 parents de2db2a + 201e21c commit ff18976

3 files changed

Lines changed: 18 additions & 40 deletions

File tree

assets/solid-dynamics-icon.svg

Lines changed: 11 additions & 0 deletions
Loading

settings/settings-fields.php

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -45,20 +45,6 @@ function wpsf_register_settings( $wpsf_settings ) {
4545
'type' => 'checkbox',
4646
'default' => 0,
4747
),
48-
array(
49-
'id' => 'hide_hello_elementor_page_title',
50-
'title' => 'Hello Elementor Page Title',
51-
'desc' => 'Hide the page title from the Hello Elementor theme.',
52-
'type' => 'checkbox',
53-
'default' => 0,
54-
),
55-
array(
56-
'id' => 'wrap_content',
57-
'title' => 'Wrap Elementor Content',
58-
'desc' => 'Wrap Elementor content with `main#content`.',
59-
'type' => 'checkbox',
60-
'default' => 0,
61-
),
6248
array(
6349
'id' => 'subtle_fade_in_entrance_animations',
6450
'title' => 'Fade in Entrance Animations',

settings/settings.php

Lines changed: 7 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ public function __construct() {
1212

1313
// Add admin menu.
1414
add_action( 'admin_menu', array( $this, 'add_settings_page' ) );
15+
add_filter( 'wpsf_menu_icon_url_solid_dynamics', array( $this, 'menu_icon_url' ) );
1516

1617
// Add an optional settings validation filter (recommended).
1718
add_filter( $this->wpsf->get_option_group() . '_settings_validate', array( &$this, 'validate_settings' ) );
@@ -30,6 +31,10 @@ public function add_settings_page() {
3031
);
3132
}
3233

34+
public function menu_icon_url() {
35+
return plugin_dir_url(__DIR__) . 'assets/solid-dynamics-icon.svg';
36+
}
37+
3338
public function validate_settings( $input ) {
3439
// Do your settings validation here
3540
// Same as $sanitize_callback from http://codex.wordpress.org/Function_Reference/register_setting.
@@ -60,20 +65,8 @@ function init() {
6065
add_action( 'admin_head', [$this, 'elementor_hide_back_to_wp_editor_button'] );
6166
}
6267

63-
if ($settings['elementor_hide_hello_elementor_page_title']) {
64-
add_filter( 'hello_elementor_page_title', '__return_false');
65-
}
66-
67-
if ($settings['elementor_wrap_content']) {
68-
add_action( 'elementor/theme/before_do_single', [$this, 'main_open'] );
69-
add_action( 'elementor/theme/after_do_single', [$this, 'main_close'] );
70-
71-
add_action( 'elementor/theme/before_do_archive', [$this, 'main_open'] );
72-
add_action( 'elementor/theme/after_do_archive', [$this, 'main_close'] );
73-
}
74-
7568
if ($settings['elementor_subtle_fade_in_entrance_animations']) {
76-
add_action( 'wp_enqueue_scripts', [$this, 'elementor_subtle_fade_in_entrance_animations'] );
69+
add_action( 'wp_enqueue_scripts', [$this, 'elementor_subtle_fade_in_entrance_animations'], 9999 );
7770
}
7871
}
7972

@@ -105,20 +98,8 @@ function disable_user_endpoint( $endpoints ) {
10598
return $endpoints;
10699
}
107100

108-
function main_open() {
109-
?>
110-
<main id="content">
111-
<?php
112-
}
113-
114-
function main_close() {
115-
?>
116-
</main>
117-
<?php
118-
}
119-
120101
function elementor_subtle_fade_in_entrance_animations() {
121-
wp_enqueue_style('sd-elementor-subtle-fade-in-entrance-animations', plugin_dir_url(__DIR__) . 'assets/elementor-subtle-fade-in-entrance-animations.css', ['e-animations'], '1.0.0');
102+
wp_enqueue_style('sd-elementor-subtle-fade-in-entrance-animations', plugin_dir_url(__DIR__) . 'assets/elementor-subtle-fade-in-entrance-animations.css', null, '1.0.0');
122103
}
123104

124105
function add_registration_date_column( $columns ) {

0 commit comments

Comments
 (0)