Skip to content

Commit

Permalink
Merge pull request #111 from oceanwp/rc-2.4.3
Browse files Browse the repository at this point in the history
Rc 2.4.3
  • Loading branch information
eramits authored Nov 28, 2024
2 parents 09ae33a + 54fd3fd commit 50d6fb3
Show file tree
Hide file tree
Showing 13 changed files with 290 additions and 59 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,7 @@ build/

# src folder
includes/post-settings/src/
includes/post-settings/oe-ps-src/

# vender folder
vendor/
Expand Down
1 change: 1 addition & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ module.exports = function (grunt) {
"!node_modules/**",
"!includes/post-settings/node_modules/**",
"!includes/post-settings/src/**",
"!includes/post-settings/oe-ps-src/**",
"!build/**",
"!src/**",
"!.git/**",
Expand Down
6 changes: 3 additions & 3 deletions assets/js/oceanwp-plugin-install.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
jQuery(document).ready(function($) {
$(document).on('click', '.install-now', function(e) {
// Target only the plugin list in your custom tab
$('#oceanwp-plugin-list').on('click', '.install-now', function(e) {
e.preventDefault();

var button = $(this);
Expand Down Expand Up @@ -31,7 +32,7 @@ jQuery(document).ready(function($) {
});
});

$(document).on('click', '.activate-now', function(e) {
$('#oceanwp-plugin-list').on('click', '.activate-now', function(e) {
e.preventDefault();

var button = $(this);
Expand Down Expand Up @@ -60,6 +61,5 @@ jQuery(document).ready(function($) {
alert('An error occurred. Please try again.');
}
});

});
});
7 changes: 7 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
== Changelog ==

= 2.4.3 - NOV 27 2024 =
- Added: Compatibility: WordPress: Bottom margin styles for wp.components.SelectControl is deprecated since version 6.7 and will be removed in version 7.0.
- Added: Compatibility: WordPress: Bottom margin styles for wp.components.BaseControl is deprecated since version 6.7 and will be removed in version 7.0.
- Added: Compatibility: WordPress: Bottom margin styles for wp.components.TextControl is deprecated since version 6.7 and will be removed in version 7.0.
- Fixed: Plugin installation error on some instances "Installation failed; Destination folder already exists.".
- Fixed: Customizer: Site Preloader: Typo error for "Default Text".

= 2.4.2 - OCT 29 2024 =
- Updated: Freemius SDK: version 2.9.0
- Updated: Compatibility: WordPress: version number.
Expand Down
41 changes: 22 additions & 19 deletions includes/plugins-tab.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ public function __construct() {
* Enqueues the necessary scripts for handling AJAX plugin installation.
*/
public function enqueue_scripts( $hook_suffix ) {
// Only enqueue the scripts on the plugin installation page.
if ( $hook_suffix === 'plugin-install.php' || $hook_suffix === 'plugin-information' ) {
// Only enqueue the scripts on the plugin installation page and our custom tab.
if ( 'plugin-install.php' === $hook_suffix && isset( $_GET['tab'] ) && 'oceanwp_plugins_tab' === $_GET['tab'] ) {
wp_enqueue_script( 'plugin-install' );
wp_enqueue_script( 'updates' );
wp_enqueue_script( 'oceanwp-plugin-install', plugin_dir_url( __FILE__ ) . '../assets/js/oceanwp-plugin-install.js', array( 'jquery' ), OE_VERSION, true );
Expand Down Expand Up @@ -72,29 +72,32 @@ public function display_oceanwp_plugins_tab_content() {
if ( ! current_user_can( 'install_plugins' ) ) {
wp_die( __( 'You do not have sufficient permissions to access this page.', 'ocean-extra' ) );
}

?>
<div class="wrap">
<h2><?php _e( 'For OceanWP', 'ocean-extra' ); ?></h2>
<?php
// Query Plugins by Author.
$api = plugins_api(
'query_plugins',
array(
'author' => 'oceanwp',
'per_page' => 20,
)
);

if ( is_wp_error( $api ) ) {
echo '<div class="error"><p>' . $api->get_error_message() . '</p></div>';
} else {
$this->ocean_display_plugins_table( $api->plugins );
}
?>
<div id="oceanwp-plugin-list">
<?php
// Query Plugins by Author.
$api = plugins_api(
'query_plugins',
array(
'author' => 'oceanwp',
'per_page' => 20,
)
);

if ( is_wp_error( $api ) ) {
echo '<div class="error"><p>' . $api->get_error_message() . '</p></div>';
} else {
$this->ocean_display_plugins_table( $api->plugins );
}
?>
</div>
</div>
<?php
}


/**
* Displays the plugins using the default WordPress layout.
Expand Down
2 changes: 1 addition & 1 deletion includes/post-settings/assets/index.asset.php
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?php return array('dependencies' => array('react', 'react-dom', 'wp-api-fetch', 'wp-block-editor', 'wp-components', 'wp-data', 'wp-edit-post', 'wp-element', 'wp-hooks', 'wp-i18n', 'wp-notices', 'wp-plugins', 'wp-primitives'), 'version' => '1bc0ef77bcda560111fc');
<?php return array('dependencies' => array('react', 'react-dom', 'wp-api-fetch', 'wp-block-editor', 'wp-components', 'wp-data', 'wp-editor', 'wp-element', 'wp-hooks', 'wp-i18n', 'wp-notices', 'wp-plugins', 'wp-primitives'), 'version' => '73df94afd5b3eb33ddab');
6 changes: 3 additions & 3 deletions includes/post-settings/assets/index.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions includes/post-settings/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
"version": "1.0.0",
"description": "OceanWP Post Settings",
"scripts": {
"build": "wp-scripts build src/index.js --output-path=assets",
"start": "wp-scripts start src/index.js --output-path=assets",
"build": "wp-scripts build oe-ps-src/index.js --output-path=assets",
"start": "wp-scripts start oe-ps-src/index.js --output-path=assets",
"lint:js": "wp-scripts lint-js",
"lint:pkg-json": "wp-scripts lint-pkg-json"
},
Expand Down
2 changes: 1 addition & 1 deletion includes/preloader/customizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ public function register_customize_options($options) {

'oe_title_for_preloader_default_settings' => [
'type' => 'ocean-title',
'label' => esc_html__( 'Defualt Preloader Settings', 'ocean-extra' ),
'label' => esc_html__( 'Default Preloader Settings', 'ocean-extra' ),
'section' => 'ocean_preloader',
'transport' => 'postMessage',
'priority' => 10,
Expand Down
22 changes: 0 additions & 22 deletions includes/update-message.php
Original file line number Diff line number Diff line change
Expand Up @@ -106,28 +106,6 @@ public function plugin_update_message( $plugin_data, $new_data ) {

}

/**
* Enqueue scripts
*
* @since 2.2.9
*/
public function ms_plugin_update_message( $file, $plugin ) {

if ( is_multisite() && version_compare( $plugin['Version'], $plugin['new_version'], '<') ) {

$wp_list_table = _get_list_table( 'WP_Plugins_List_Table' );

printf(
'<tr class="plugin-update-tr">
<td colspan="%s" class="plugin-update update-message notice inline notice-warning notice-alt">%s</td>
</tr>',
$wp_list_table->get_column_count(),
$this->plugin_update_content()
);
}

}

/**
* Script
*/
Expand Down
Loading

0 comments on commit 50d6fb3

Please sign in to comment.