Fix: Rename class files and apply coding standard fixes

This commit is contained in:
2025-04-18 18:08:51 +01:00
parent 3fa42ae1c7
commit 058ae4b64e
8 changed files with 2233 additions and 9 deletions

View File

@@ -1 +1,7 @@
<?php
/**
* Admin area specific functions.
*
* @package WPALLSTARS\PluginStarterTemplate\Admin\Lib
* @file
*/

View File

@@ -1 +1,14 @@
<?php
/**
* Modal related functions for the admin area.
*
* @package WPALLSTARS\PluginStarterTemplate\Admin\Lib
*/
/**
* File: modal.php
* Description: Modal related functions for the admin area.
* Version: 1.0
* Author: Your Name
* Author URI: https://yourwebsite.com
*/

View File

@@ -2,11 +2,11 @@
/**
* Modal Template
*
* @package WPALLSTARS\PluginStarterTemplate
* @package WPALLSTARS\PluginStarterTemplate\Admin\Templates
*/
// If this file is called directly, abort.
if ( ! defined( 'WPINC' ) ) {
// Ensure this file is loaded within WordPress.
if ( ! defined( 'ABSPATH' ) ) {
die;
}
?>
@@ -30,7 +30,7 @@ if ( ! defined( 'WPINC' ) ) {
$current_source = get_option( 'wpst_update_source', 'wordpress.org' );
?>
<label class="wpst-source-option <?php echo $current_source === 'wordpress.org' ? 'selected' : ''; ?>">
<label class="wpst-source-option <?php echo 'wordpress.org' === $current_source ? 'selected' : ''; ?>">
<input type="radio" name="update_source" value="wordpress.org" <?php checked( $current_source, 'wordpress.org' ); ?>>
<span class="wpst-source-option-label"><?php esc_html_e( 'WordPress.org', 'wp-plugin-starter-template' ); ?></span>
<div class="wpst-source-option-description">
@@ -38,7 +38,7 @@ if ( ! defined( 'WPINC' ) ) {
</div>
</label>
<label class="wpst-source-option <?php echo $current_source === 'github' ? 'selected' : ''; ?>">
<label class="wpst-source-option <?php echo 'github' === $current_source ? 'selected' : ''; ?>">
<input type="radio" name="update_source" value="github" <?php checked( $current_source, 'github' ); ?>>
<span class="wpst-source-option-label"><?php esc_html_e( 'GitHub', 'wp-plugin-starter-template' ); ?></span>
<div class="wpst-source-option-description">
@@ -46,7 +46,7 @@ if ( ! defined( 'WPINC' ) ) {
</div>
</label>
<label class="wpst-source-option <?php echo $current_source === 'gitea' ? 'selected' : ''; ?>">
<label class="wpst-source-option <?php echo 'gitea' === $current_source ? 'selected' : ''; ?>">
<input type="radio" name="update_source" value="gitea" <?php checked( $current_source, 'gitea' ); ?>>
<span class="wpst-source-option-label"><?php esc_html_e( 'Gitea', 'wp-plugin-starter-template' ); ?></span>
<div class="wpst-source-option-description">

2199
composer.lock generated Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -49,6 +49,6 @@ class Plugin {
* Initialize the plugin
*/
public function init() {
// Initialize plugin
// Initialization logic goes here
}
}

View File

@@ -1 +1,7 @@
<?php
/**
* File: updater.php
* Description: Placeholder for potential updater logic.
*
* @package WPALLSTARS\PluginStarterTemplate
*/

View File

@@ -31,8 +31,8 @@ if ( ! defined( 'WPINC' ) ) {
die;
}
// Load the main plugin class
// Load the main plugin class.
require_once plugin_dir_path( __FILE__ ) . 'includes/class-plugin.php';
// Initialize the plugin
// Initialize the plugin.
new WPALLSTARS\PluginStarterTemplate\Plugin( __FILE__, '0.1.7' );