Make WordPress Themes

Changeset 310691


Ignore:
Timestamp:
01/28/2026 11:01:25 AM (9 months ago)
Author:
themedropbox
Message:

New version of Museum Artifact - 0.2.2

Location:
museum-artifact/0.2.2
Files:
8 edited
1 copied

Legend:

Unmodified
Added
Removed
  • museum-artifact/0.2.2/includes/color-setting/custom-color-control.php

    r260847 r310691  
    3737                        $museum_artifact_theme_custom_setting_css .='display: none;';
    3838                $museum_artifact_theme_custom_setting_css .='}';
    39         }       
     39        }
     40   
     41    // Featured Image Hover Effect
     42    $museum_artifact_show_featured = get_theme_mod('museum_artifact_featured_image_hide_show', 1);
     43    $museum_artifact_hover_effect = get_theme_mod('museum_artifact_single_post_featured_image_hover','none');
     44
     45    if ( $museum_artifact_show_featured && $museum_artifact_hover_effect !== 'none' ) {
     46
     47    $museum_artifact_theme_custom_setting_css .= '
     48    .post-img img{
     49        transition: all 0.4s ease;
     50    }';
     51
     52    if ( $museum_artifact_hover_effect === 'zoom-in' ) {
     53        $museum_artifact_theme_custom_setting_css .= '
     54        .post-img:hover img{
     55            transform: scale(1.2);
     56        }';
     57    }
     58
     59    if ( $museum_artifact_hover_effect === 'zoom-out' ) {
     60        $museum_artifact_theme_custom_setting_css .= '
     61        .post-img img{ transform: scale(1.2); }
     62        .post-img:hover img{ transform: scale(1); }';
     63    }
     64
     65    if ( $museum_artifact_hover_effect === 'grayscale' ) {
     66        $museum_artifact_theme_custom_setting_css .= '
     67        .post-img img{ filter: grayscale(100%); }
     68        .post-img:hover img{ filter: grayscale(0); }';
     69    }
     70
     71    if ( $museum_artifact_hover_effect === 'sepia' ) {
     72        $museum_artifact_theme_custom_setting_css .= '
     73        .post-img:hover img{ filter: sepia(100%); }';
     74    }
     75
     76    if ( $museum_artifact_hover_effect === 'blur' ) {
     77        $museum_artifact_theme_custom_setting_css .= '
     78        .post-img:hover img{ filter: blur(3px); }';
     79    }
     80
     81    if ( $museum_artifact_hover_effect === 'bright' ) {
     82        $museum_artifact_theme_custom_setting_css .= '
     83        .post-img:hover img{ filter: brightness(1.3); }';
     84    }
     85
     86    if ( $museum_artifact_hover_effect === 'translate' ) {
     87        $museum_artifact_theme_custom_setting_css .= '
     88        .post-img:hover img{ transform: translateY(-10px); }';
     89    }
     90
     91    if ( $museum_artifact_hover_effect === 'scale' ) {
     92        $museum_artifact_theme_custom_setting_css .= '
     93        .post-img:hover img{ transform: scale(1.1); }';
     94    }
     95}
  • museum-artifact/0.2.2/includes/customizer.php

    r299347 r310691  
    13431343
    13441344        Kirki::add_field( 'theme_config_id', [
     1345        'type'     => 'select',
     1346        'tab'      => 'single-post',
     1347        'settings' => 'museum_artifact_single_post_featured_image_hover',
     1348        'label'    => esc_html__( 'Featured Image Hover Effect', 'museum-artifact' ),
     1349        'section'  => 'museum_artifact_blog_post',
     1350        'default'  => 'none',
     1351        'priority' => 20,
     1352        'choices'  => [
     1353                'none'      => esc_html__( 'None', 'museum-artifact' ),
     1354                'zoom-in'   => esc_html__( 'Zoom In', 'museum-artifact' ),
     1355                'zoom-out'  => esc_html__( 'Zoom Out', 'museum-artifact' ),
     1356                'scale'     => esc_html__( 'Scale', 'museum-artifact' ),
     1357                'grayscale' => esc_html__( 'Grayscale', 'museum-artifact' ),
     1358                'blur'      => esc_html__( 'Blur', 'museum-artifact' ),
     1359                'bright'    => esc_html__( 'Bright', 'museum-artifact' ),
     1360                'sepia'     => esc_html__( 'Sepia', 'museum-artifact' ),
     1361                'translate' => esc_html__( 'Translate', 'museum-artifact' ),
     1362        ],
     1363    ] );
     1364
     1365        Kirki::add_field( 'theme_config_id', [
    13451366                'type'        => 'custom',
    13461367                'tab'      => 'single-post',
  • museum-artifact/0.2.2/includes/product-create.php

    r299347 r310691  
    3434                )
    3535        ));
    36 }
    3736
     37        /* Create Menu */
     38            $museum_artifact_menuname  = 'Main Menus';
     39            $museum_artifact_location  = 'main-menu';
     40
     41            $museum_artifact_menu = wp_get_nav_menu_object( $museum_artifact_menuname );
     42
     43            if ( ! $museum_artifact_menu ) {
     44            $museum_artifact_menu_id = wp_create_nav_menu( $museum_artifact_menuname );
     45
     46           // Home Page
     47                        wp_update_nav_menu_item( $museum_artifact_menu_id, 0, array(
     48                                'menu-item-title'     => __( 'Home', 'museum-artifact' ),
     49                                'menu-item-url'       => home_url( '/' ),
     50                                'menu-item-type'      => 'custom',
     51                                'menu-item-status'    => 'publish',
     52                        ) );
     53
     54                        // About Us Page
     55                        $museum_artifact_about_id = wp_insert_post( array(
     56                        'post_type'   => 'page',
     57                        'post_content' => 'We are committed to providing reliable, professional, and result-oriented solutions tailored to meet individual needs. Our goal is to empower people with the right guidance, knowledge, and support to help them make informed decisions for a better future. <br><br> Our mission is to deliver high-quality services with honesty, transparency, and dedication. We focus on understanding client requirements and offering practical solutions that create long-term value. <br><br> With a client-centric approach, experienced professionals, and a commitment to excellence, we ensure every individual receives the attention and guidance they deserve. We believe in building trust through quality service and consistent results.',
     58                        'post_title'  => 'About Us',
     59                        'post_status' => 'publish',
     60                        ) );
     61
     62                        if ( $museum_artifact_about_id ) {
     63                        wp_update_nav_menu_item( $museum_artifact_menu_id, 0, array(
     64                        'menu-item-title'     => 'About Us',
     65                        'menu-item-object'    => 'page',
     66                        'menu-item-object-id' => $museum_artifact_about_id,
     67                        'menu-item-type'      => 'post_type',
     68                        'menu-item-status'    => 'publish',
     69                        ) );
     70                        }
     71
     72                        // Exhibition Page
     73                        $museum_artifact_about_id = wp_insert_post( array(
     74                        'post_type'   => 'page',
     75                        'post_content' => 'We are committed to providing reliable, professional, and result-oriented solutions tailored to meet individual needs. Our goal is to empower people with the right guidance, knowledge, and support to help them make informed decisions for a better future. <br><br> Our mission is to deliver high-quality services with honesty, transparency, and dedication. We focus on understanding client requirements and offering practical solutions that create long-term value. <br><br> With a client-centric approach, experienced professionals, and a commitment to excellence, we ensure every individual receives the attention and guidance they deserve. We believe in building trust through quality service and consistent results.',
     76                        'post_title'  => 'Exhibition',
     77                        'post_status' => 'publish',
     78                        ) );
     79
     80                        if ( $museum_artifact_about_id ) {
     81                        wp_update_nav_menu_item( $museum_artifact_menu_id, 0, array(
     82                        'menu-item-title'     => 'Exhibition',
     83                        'menu-item-object'    => 'page',
     84                        'menu-item-object-id' => $museum_artifact_about_id,
     85                        'menu-item-type'      => 'post_type',
     86                        'menu-item-status'    => 'publish',
     87                        ) );
     88                        }
     89
     90                        // Pages Page
     91                        $museum_artifact_about_id = wp_insert_post( array(
     92                        'post_type'   => 'page',
     93                        'post_content' => 'We are committed to providing reliable, professional, and result-oriented solutions tailored to meet individual needs. Our goal is to empower people with the right guidance, knowledge, and support to help them make informed decisions for a better future. <br><br> Our mission is to deliver high-quality services with honesty, transparency, and dedication. We focus on understanding client requirements and offering practical solutions that create long-term value. <br><br> With a client-centric approach, experienced professionals, and a commitment to excellence, we ensure every individual receives the attention and guidance they deserve. We believe in building trust through quality service and consistent results.',
     94                        'post_title'  => 'Pages',
     95                        'post_status' => 'publish',
     96                        ) );
     97
     98                        if ( $museum_artifact_about_id ) {
     99                        wp_update_nav_menu_item( $museum_artifact_menu_id, 0, array(
     100                        'menu-item-title'     => 'Pages',
     101                        'menu-item-object'    => 'page',
     102                        'menu-item-object-id' => $museum_artifact_about_id,
     103                        'menu-item-type'      => 'post_type',
     104                        'menu-item-status'    => 'publish',
     105                        ) );
     106                        }
     107
     108                        // Contact Us Page
     109                        $museum_artifact_about_id = wp_insert_post( array(
     110                        'post_type'   => 'page',
     111                        'post_content' => 'We are committed to providing reliable, professional, and result-oriented solutions tailored to meet individual needs. Our goal is to empower people with the right guidance, knowledge, and support to help them make informed decisions for a better future. <br><br> Our mission is to deliver high-quality services with honesty, transparency, and dedication. We focus on understanding client requirements and offering practical solutions that create long-term value. <br><br> With a client-centric approach, experienced professionals, and a commitment to excellence, we ensure every individual receives the attention and guidance they deserve. We believe in building trust through quality service and consistent results.',
     112                        'post_title'  => 'Contact Us',
     113                        'post_status' => 'publish',
     114                        ) );
     115
     116                        if ( $museum_artifact_about_id ) {
     117                        wp_update_nav_menu_item( $museum_artifact_menu_id, 0, array(
     118                        'menu-item-title'     => 'Contact Us',
     119                        'menu-item-object'    => 'page',
     120                        'menu-item-object-id' => $museum_artifact_about_id,
     121                        'menu-item-type'      => 'post_type',
     122                        'menu-item-status'    => 'publish',
     123                        ) );
     124                        }
     125
     126         // Create Blog Page
     127                $museum_artifact_blog_page_title = 'Blog';
     128
     129                $museum_artifact_blog_page_query = new WP_Query(array(
     130                    'post_type'      => 'page',
     131                    'name'           => sanitize_title($museum_artifact_blog_page_title),
     132                    'post_status'    => 'publish',
     133                    'posts_per_page' => 1
     134                ));
     135                if (!$museum_artifact_blog_page_query->hae_posts()) {
     136                    $museum_artifact_blog_page = array(
     137                        'post_type'   => 'page',
     138                        'post_title'  => $museum_artifact_blog_page_title,
     139                        'post_status' => 'publish',
     140                        'post_author' => 1,
     141                    );
     142                    $museum_artifact_blog_page_id = wp_insert_post($museum_artifact_blog_page);
     143                    update_option('page_for_posts', $museum_artifact_blog_page_id);
     144
     145                    wp_update_na_menu_item($museum_artifact_menu_id, 0, array(
     146                        'menu-item-title'      => __('Blog', 'museum-artifact'),
     147                        'menu-item-url'        => get_permalink($museum_artifact_blog_page_id),
     148                        'menu-item-status'     => 'publish',
     149                        'menu-item-object-id'  => $museum_artifact_blog_page_id,
     150                        'menu-item-object'     => 'page',
     151                        'menu-item-type'       => 'post_type',
     152                    ));
     153                }
     154
     155                        /* Assign Menu Location */
     156                        $museum_artifact_locations = get_theme_mod( 'nav_menu_locations', array() );
     157                        $museum_artifact_locations[ $museum_artifact_location ] = $museum_artifact_menu_id;
     158                        set_theme_mod( 'nav_menu_locations', $museum_artifact_locations );
     159                }
     160   }
    38161}
    39162 
  • museum-artifact/0.2.2/includes/tgm/class-tgm-plugin-activation.php

    r244257 r310691  
    99 *
    1010 * @package   TGM-Plugin-Activation
    11  * @version   2.6.1 for parent theme Museum Artifact for publication on WordPress.org
     11 * @version   2.6.1
    1212 * @link      http://tgmpluginactivation.com/
    1313 * @author    Thomas Griffin, Gary Jones, Juliette Reinders Folmer
    … …  
    3232        Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
    3333*/
     34
     35// Exit if accessed directly.
     36if ( ! defined( 'ABSPATH' ) ) {
     37        return;
     38}
    3439
    3540if ( ! class_exists( 'TGM_Plugin_Activation' ) ) {
    … …  
    260265                        do_action_ref_array( 'tgmpa_init', array( $this ) );
    261266
    262 
     267                        /*
     268                         * Load our text domain and allow for overloading the fall-back file.
     269                         *
     270                         * {@internal IMPORTANT! If this code changes, review the regex in the custom TGMPA
     271                         * generator on the website.}}
     272                         */
     273                        add_action( 'init', array( $this, 'load_textdomain' ), 5 );
     274                        add_filter( 'load_textdomain_mofile', array( $this, 'overload_textdomain_mofile' ), 10, 2 );
    263275
    264276                        // When the rest of WP has loaded, kick-start the rest of the class.
    … …  
    283295                 */
    284296                public function __set( $name, $value ) {
     297                        // phpcs:ignore Squiz.PHP.NonExecutableCode.ReturnNotRequired -- See explanation above.
    285298                        return;
    286299                }
    … …  
    332345                                'updating'                        => __( 'Updating Plugin: %s', 'museum-artifact' ),
    333346                                'oops'                            => __( 'Something went wrong with the plugin API.', 'museum-artifact' ),
     347                                /* translators: 1: plugin name(s). */
    334348                                'notice_can_install_required'     => _n_noop(
    335                                         /* translators: 1: plugin name(s). */
    336349                                        'This theme requires the following plugin: %1$s.',
    337350                                        'This theme requires the following plugins: %1$s.',
    338351                                        'museum-artifact'
    339352                                ),
     353                                /* translators: 1: plugin name(s). */
    340354                                'notice_can_install_recommended'  => _n_noop(
    341                                         /* translators: 1: plugin name(s). */
    342355                                        'This theme recommends the following plugin: %1$s.',
    343356                                        'This theme recommends the following plugins: %1$s.',
    344357                                        'museum-artifact'
    345358                                ),
     359                                /* translators: 1: plugin name(s). */
    346360                                'notice_ask_to_update'            => _n_noop(
    347                                         /* translators: 1: plugin name(s). */
    348361                                        'The following plugin needs to be updated to its latest version to ensure maximum compatibility with this theme: %1$s.',
    349362                                        'The following plugins need to be updated to their latest version to ensure maximum compatibility with this theme: %1$s.',
    350363                                        'museum-artifact'
    351364                                ),
     365                                /* translators: 1: plugin name(s). */
    352366                                'notice_ask_to_update_maybe'      => _n_noop(
    353                                         /* translators: 1: plugin name(s). */
    354367                                        'There is an update available for: %1$s.',
    355368                                        'There are updates available for the following plugins: %1$s.',
    356369                                        'museum-artifact'
    357370                                ),
     371                                /* translators: 1: plugin name(s). */
    358372                                'notice_can_activate_required'    => _n_noop(
    359                                         /* translators: 1: plugin name(s). */
    360373                                        'The following required plugin is currently inactive: %1$s.',
    361374                                        'The following required plugins are currently inactive: %1$s.',
    362375                                        'museum-artifact'
    363376                                ),
     377                                /* translators: 1: plugin name(s). */
    364378                                'notice_can_activate_recommended' => _n_noop(
    365                                         /* translators: 1: plugin name(s). */
    366379                                        'The following recommended plugin is currently inactive: %1$s.',
    367380                                        'The following recommended plugins are currently inactive: %1$s.',
    … …  
    445458                                add_action( 'switch_theme', array( $this, 'force_deactivation' ) );
    446459                        }
     460
     461                        // Add CSS for the TGMPA admin page.
     462                        add_action( 'admin_head', array( $this, 'admin_css' ) );
     463                }
     464
     465                /**
     466                 * Load translations.
     467                 *
     468                 * @since 2.6.0
     469                 *
     470                 * (@internal Uses `load_theme_textdomain()` rather than `load_plugin_textdomain()` to
     471                 * get round the different ways of handling the path and deprecated notices being thrown
     472                 * and such. For plugins, the actual file name will be corrected by a filter.}}
     473                 *
     474                 * {@internal IMPORTANT! If this function changes, review the regex in the custom TGMPA
     475                 * generator on the website.}}
     476                 */
     477                public function load_textdomain() {
     478                        if ( is_textdomain_loaded( 'museum-artifact' ) ) {
     479                                return;
     480                        }
     481
     482                        if ( false !== strpos( __FILE__, WP_PLUGIN_DIR ) || false !== strpos( __FILE__, WPMU_PLUGIN_DIR ) ) {
     483                                // Plugin, we'll need to adjust the file name.
     484                                add_action( 'load_textdomain_mofile', array( $this, 'correct_plugin_mofile' ), 10, 2 );
     485                                load_theme_textdomain( 'museum-artifact', dirname( __FILE__ ) . '/languages' );
     486                                remove_action( 'load_textdomain_mofile', array( $this, 'correct_plugin_mofile' ), 10 );
     487                        } else {
     488                                load_theme_textdomain( 'museum-artifact', dirname( __FILE__ ) . '/languages' );
     489                        }
     490                }
     491
     492                /**
     493                 * Correct the .mo file name for (must-use) plugins.
     494                 *
     495                 * Themese use `/path/{locale}.mo` while plugins use `/path/{text-domain}-{locale}.mo`.
     496                 *
     497                 * {@internal IMPORTANT! If this function changes, review the regex in the custom TGMPA
     498                 * generator on the website.}}
     499                 *
     500                 * @since 2.6.0
     501                 *
     502                 * @param string $mofile Full path to the target mofile.
     503                 * @param string $domain The domain for which a language file is being loaded.
     504                 * @return string $mofile
     505                 */
     506                public function correct_plugin_mofile( $mofile, $domain ) {
     507                        // Exit early if not our domain (just in case).
     508                        if ( 'museum-artifact' !== $domain ) {
     509                                return $mofile;
     510                        }
     511                        return preg_replace( '`/([a-z]{2}_[A-Z]{2}.mo)$`', '/tgmpa-$1', $mofile );
     512                }
     513
     514                /**
     515                 * Potentially overload the fall-back translation file for the current language.
     516                 *
     517                 * WP, by default since WP 3.7, will load a local translation first and if none
     518                 * can be found, will try and find a translation in the /wp-content/languages/ directory.
     519                 * As this library is theme/plugin agnostic, translation files for TGMPA can exist both
     520                 * in the WP_LANG_DIR /plugins/ subdirectory as well as in the /themes/ subdirectory.
     521                 *
     522                 * This method makes sure both directories are checked.
     523                 *
     524                 * {@internal IMPORTANT! If this function changes, review the regex in the custom TGMPA
     525                 * generator on the website.}}
     526                 *
     527                 * @since 2.6.0
     528                 *
     529                 * @param string $mofile Full path to the target mofile.
     530                 * @param string $domain The domain for which a language file is being loaded.
     531                 * @return string $mofile
     532                 */
     533                public function overload_textdomain_mofile( $mofile, $domain ) {
     534                        // Exit early if not our domain, not a WP_LANG_DIR load or if the file exists and is readable.
     535                        if ( 'museum-artifact' !== $domain || false === strpos( $mofile, WP_LANG_DIR ) || @is_readable( $mofile ) ) {
     536                                return $mofile;
     537                        }
     538
     539                        // Current fallback file is not valid, let's try the alternative option.
     540                        if ( false !== strpos( $mofile, '/themes/' ) ) {
     541                                return str_replace( '/themes/', '/plugins/', $mofile );
     542                        } elseif ( false !== strpos( $mofile, '/plugins/' ) ) {
     543                                return str_replace( '/plugins/', '/themes/', $mofile );
     544                        } else {
     545                                return $mofile;
     546                        }
    447547                }
    448548
    … …  
    556656
    557657                                global $tab, $body_id;
     658                                // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- WP requirement.
    558659                                $body_id = 'plugin-information';
    559                                 // @codingStandardsIgnoreStart
    560                                 $tab     = 'plugin-information';
    561                                 // @codingStandardsIgnoreEnd
     660
     661                                // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited -- Overriding the WP global is the point.
     662                                $tab = 'plugin-information';
    562663
    563664                                install_plugin_information();
    … …  
    631732                 */
    632733                protected function add_admin_menu( array $args ) {
    633                         $this->page_hook = add_theme_page( $args['page_title'], $args['menu_title'], $args['capability'], $args['menu_slug'], $args['function'] );
     734                        if ( has_filter( 'tgmpa_admin_menu_use_add_theme_page' ) ) {
     735                                _deprecated_function( 'The "tgmpa_admin_menu_use_add_theme_page" filter', '2.5.0', esc_html__( 'Set the parent_slug config variable instead.', 'museum-artifact' ) );
     736                        }
     737
     738                        if ( 'themes.php' === $this->parent_slug ) {
     739                                $this->page_hook = call_user_func( 'add_theme_page', $args['page_title'], $args['menu_title'], $args['capability'], $args['menu_slug'], $args['function'] );
     740                        } else {
     741                                $this->page_hook = call_user_func( 'add_submenu_page', $args['parent_slug'], $args['page_title'], $args['menu_title'], $args['capability'], $args['menu_slug'], $args['function'] );
     742                        }
    634743                }
    635744
    … …  
    647756                public function install_plugins_page() {
    648757                        // Store new instance of plugin table in object.
    649                         $plugin_table = new TGMPA_List_Table;
     758                        $plugin_table = new TGMPA_List_Table();
    650759
    651760                        // Return early if processing a plugin installation action.
    … …  
    735844                                $method = ''; // Leave blank so WP_Filesystem can populate it as necessary.
    736845
    737                                 if ( false === ( $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, array() ) ) ) {
     846                                $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, array() );
     847                                if ( false === $creds ) {
    738848                                        return true;
    739849                                }
    … …  
    792902                                if ( 'update' === $install_type ) {
    793903                                        // Inject our info into the update transient.
    794                                         $to_inject                    = array( $slug => $this->plugins[ $slug ] );
     904                                        $to_inject                    = array(
     905                                                $slug => $this->plugins[ $slug ],
     906                                        );
    795907                                        $to_inject[ $slug ]['source'] = $source;
    796908                                        $this->inject_update_info( $to_inject );
    … …  
    819931                                // Display message based on if all plugins are now active or not.
    820932                                if ( $this->is_tgmpa_complete() ) {
    821                                         echo '<p>', sprintf( esc_html( $this->strings['complete'] ), '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html__( 'Return to the Dashboard', 'museum-artifact' ) . '</a>' ), '</p>';
     933                                        echo '<p>', sprintf( esc_html( $this->strings['complete'] ), '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html( $this->strings['dashboard'] ) . '</a>' ), '</p>';
    822934                                        echo '<style type="text/css">#adminmenu .wp-submenu li.current { display: none !important; }</style>';
    823935                                } else {
    … …  
    849961
    850962                        if ( ! is_object( $repo_updates ) ) {
    851                                 $repo_updates = new stdClass;
     963                                $repo_updates = new stdClass();
    852964                        }
    853965
    … …  
    856968
    857969                                if ( empty( $repo_updates->response[ $file_path ] ) ) {
    858                                         $repo_updates->response[ $file_path ] = new stdClass;
     970                                        $repo_updates->response[ $file_path ] = new stdClass();
    859971                                }
    860972
    … …  
    9261038                                                return trailingslashit( $to_path );
    9271039                                        } else {
    928                                                 return new WP_Error( 'rename_failed', esc_html__( 'The remote plugin package does not contain a folder with the desired slug and renaming did not work.', 'museum-artifact' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'museum-artifact' ), array( 'found' => $subdir_name, 'expected' => $desired_slug ) );
     1040                                                return new WP_Error(
     1041                                                        'rename_failed',
     1042                                                        esc_html__( 'The remote plugin package does not contain a folder with the desired slug and renaming did not work.', 'museum-artifact' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'museum-artifact' ),
     1043                                                        array(
     1044                                                                'found'    => $subdir_name,
     1045                                                                'expected' => $desired_slug,
     1046                                                        )
     1047                                                );
    9291048                                        }
    9301049                                } elseif ( empty( $subdir_name ) ) {
    931                                         return new WP_Error( 'packaged_wrong', esc_html__( 'The remote plugin package consists of more than one file, but the files are not packaged in a folder.', 'museum-artifact' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'museum-artifact' ), array( 'found' => $subdir_name, 'expected' => $desired_slug ) );
     1050                                        return new WP_Error(
     1051                                                'packaged_wrong',
     1052                                                esc_html__( 'The remote plugin package consists of more than one file, but the files are not packaged in a folder.', 'museum-artifact' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'museum-artifact' ),
     1053                                                array(
     1054                                                        'found'    => $subdir_name,
     1055                                                        'expected' => $desired_slug,
     1056                                                )
     1057                                        );
    9321058                                }
    9331059                        }
    … …  
    9601086                                                // Make sure message doesn't display again if bulk activation is performed
    9611087                                                // immediately after a single activation.
    962                                                 if ( ! isset( $_POST['action'] ) ) { // WPCS: CSRF OK.
     1088                                                // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Not using the superglobal.
     1089                                                if ( ! isset( $_POST['action'] ) ) {
    9631090                                                        echo '<div id="message" class="updated"><p>', esc_html( $this->strings['activated_successfully'] ), ' <strong>', esc_html( $this->plugins[ $slug ]['name'] ), '.</strong></p></div>';
    9641091                                                }
    … …  
    9811108                                        // Make sure message doesn't display again if bulk activation is performed
    9821109                                        // immediately after a single activation.
    983                                         if ( ! isset( $_POST['action'] ) ) { // WPCS: CSRF OK.
     1110                                        // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Not using the superglobal.
     1111                                        if ( ! isset( $_POST['action'] ) ) {
    9841112                                                echo '<div id="message" class="error"><p>',
    9851113                                                        sprintf(
    … …  
    11311259
    11321260                                // Register the nag messages and prepare them to be processed.
    1133                                 add_settings_error( 'tgmpa', 'tgmpa', $rendered, $this->get_admin_notice_class() );
     1261                                add_settings_error( 'museum-artifact', 'museum-artifact', $rendered, $this->get_admin_notice_class() );
    11341262                        }
    11351263
    … …  
    12311359                        global $wp_settings_errors;
    12321360
    1233                         settings_errors( 'tgmpa' );
     1361                        settings_errors( 'museum-artifact' );
    12341362
    12351363                        foreach ( (array) $wp_settings_errors as $key => $details ) {
    1236                                 if ( 'tgmpa' === $details['setting'] ) {
     1364                                if ( 'museum-artifact' === $details['setting'] ) {
    12371365                                        unset( $wp_settings_errors[ $key ] );
    12381366                                        break;
    … …  
    12761404
    12771405                        $defaults = array(
    1278                                 'name'               => '',      // String
    1279                                 'slug'               => '',      // String
    1280                                 'source'             => 'repo',  // String
    1281                                 'required'           => false,   // Boolean
    1282                                 'version'            => '',      // String
    1283                                 'force_activation'   => false,   // Boolean
    1284                                 'force_deactivation' => false,   // Boolean
    1285                                 'external_url'       => '',      // String
    1286                                 'is_callable'        => '',      // String|Array.
     1406                                'name'               => '',      // String.
     1407                                'slug'               => '',      // String.
     1408                                'source'             => 'repo',  // String.
     1409                                'required'           => false,   // Boolean.
     1410                                'version'            => '',      // String.
     1411                                'force_activation'   => false,   // Boolean.
     1412                                'force_deactivation' => false,   // Boolean.
     1413                                'external_url'       => '',      // String.
     1414                                'is_callable'        => '',      // String or array.
    12871415                        );
    12881416
    … …  
    15501678                                }
    15511679
    1552                                 $response = plugins_api( 'plugin_information', array( 'slug' => $slug, 'fields' => array( 'sections' => false ) ) );
     1680                                $response = plugins_api(
     1681                                        'plugin_information',
     1682                                        array(
     1683                                                'slug'   => $slug,
     1684                                                'fields' => array(
     1685                                                        'sections' => false,
     1686                                                ),
     1687                                        )
     1688                                );
    15531689
    15541690                                $api[ $slug ] = false;
    … …  
    16331769                                // Core update screen.
    16341770                                return true;
    1635                         } elseif ( 'plugins' === $screen->base && ! empty( $_POST['action'] ) ) { // WPCS: CSRF ok.
     1771                        } elseif ( 'plugins' === $screen->base && ! empty( $_POST['action'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing
    16361772                                // Plugins bulk update screen.
    16371773                                return true;
    1638                         } elseif ( 'update' === $screen->base && ! empty( $_POST['action'] ) ) { // WPCS: CSRF ok.
     1774                        } elseif ( 'update' === $screen->base && ! empty( $_POST['action'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing
    16391775                                // Individual updates (ajax call).
    16401776                                return true;
    … …  
    19822118
    19832119                /**
     2120                 * Adds CSS to admin head.
     2121                 *
     2122                 * @since 2.6.2
     2123                 */
     2124                public function admin_css() {
     2125                        if ( ! $this->is_tgmpa_page() ) {
     2126                                return;
     2127                        }
     2128
     2129                        echo '
     2130                        <style>
     2131                        #tgmpa-plugins .tgmpa-type-required > th {
     2132                                border-left: 3px solid #dc3232;
     2133                        }
     2134                        </style>';
     2135                }
     2136
     2137                /**
    19842138                 * Returns the singleton instance of the class.
    19852139                 *
    … …  
    20252179         * @param array $config  Optional. An array of configuration values.
    20262180         */
    2027         function museum_artifact_tgmpa( $plugins, $config = array() ) {
     2181        function tgmpa( $plugins, $config = array() ) {
    20282182                $instance = call_user_func( array( get_class( $GLOBALS['tgmpa'] ), 'get_instance' ) );
    20292183
    … …  
    24782632                                $color = '';
    24792633                                if ( ! empty( $item['minimum_version'] ) && $this->tgmpa->does_plugin_require_update( $item['slug'] ) ) {
    2480                                         $color = ' color: #F99D43; font-weight: bold;';
     2634                                        $color = ' color: #ff0000; font-weight: bold;';
    24812635                                }
    24822636
    … …  
    25252679                 */
    25262680                public function no_items() {
    2527                         echo esc_html__( 'No plugins to install, update or activate.', 'museum-artifact' ) . ' <a href="' . esc_url( self_admin_url() ) . '"> ' . esc_html__( 'Return to the Dashboard', 'museum-artifact' ) . '</a>';
     2681                        echo esc_html__( 'No plugins to install, update or activate.', 'museum-artifact' ) . ' <a href="' . esc_url( self_admin_url() ) . '"> ' . esc_html( $this->tgmpa->strings['dashboard'] ) . '</a>';
    25282682                        echo '<style type="text/css">#adminmenu .wp-submenu li.current { display: none !important; }</style>';
    25292683                }
    … …  
    26432797                 */
    26442798                public function single_row( $item ) {
    2645                         parent::single_row( $item );
     2799                        echo '<tr class="' . esc_attr( 'tgmpa-type-' . strtolower( $item['type'] ) ) . '">';
     2800                        $this->single_row_columns( $item );
     2801                        echo '</tr>';
    26462802
    26472803                        /**
    … …  
    26882844                 * @since 2.5.0
    26892845                 *
    2690                  * @param string $which 'top' or 'bottom' table navigation.
     2846                 * @param string $which Either 'top' or 'bottom' table navigation.
    26912847                 */
    26922848                public function extra_tablenav( $which ) {
    … …  
    28142970                                $fields = array_keys( $_POST ); // Extra fields to pass to WP_Filesystem.
    28152971
    2816                                 if ( false === ( $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, $fields ) ) ) {
     2972                                $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, $fields );
     2973                                if ( false === $creds ) {
    28172974                                        return true; // Stop the normal page form from displaying, credential request form will be shown.
    28182975                                }
    … …  
    29423099                                        $imploded     = empty( $plugin_names ) ? $last_plugin : ( implode( ', ', $plugin_names ) . ' ' . esc_html_x( 'and', 'plugin A *and* plugin B', 'museum-artifact' ) . ' ' . $last_plugin );
    29433100
    2944                                         printf( // WPCS: xss ok.
     3101                                        printf(
    29453102                                                '<div id="message" class="updated"><p>%1$s %2$s.</p></div>',
    29463103                                                esc_html( _n( 'The following plugin was activated successfully:', 'The following plugins were activated successfully:', $count, 'museum-artifact' ) ),
     3104                                                // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Pre-escaped via wrap_in_strong() method above.
    29473105                                                $imploded
    29483106                                        );
    … …  
    32893447                                                                break;
    32903448                                                        }
    3291                                                 } //end foreach $plugins
     3449                                                }
    32923450
    32933451                                                $this->maintenance_mode( false );
    … …  
    33093467                                                 * }
    33103468                                                 */
    3311                                                 do_action( 'upgrader_process_complete', $this, array(
    3312                                                         'action'  => 'install', // [TGMPA + ] adjusted.
    3313                                                         'type'    => 'plugin',
    3314                                                         'bulk'    => true,
    3315                                                         'plugins' => $plugins,
    3316                                                 ) );
     3469                                                do_action(
     3470                                                        // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedHooknameFound -- Using WP core hook.
     3471                                                        'upgrader_process_complete',
     3472                                                        $this,
     3473                                                        array(
     3474                                                                'action'  => 'install', // [TGMPA + ] adjusted.
     3475                                                                'type'    => 'plugin',
     3476                                                                'bulk'    => true,
     3477                                                                'plugins' => $plugins,
     3478                                                        )
     3479                                                );
    33173480
    33183481                                                $this->skin->bulk_footer();
    … …  
    35013664                                                                $this->upgrader->strings['skin_upgrade_start'] = __( 'The installation and activation process is starting. This process may take a while on some hosts, so please be patient.', 'museum-artifact' );
    35023665                                                                /* translators: 1: plugin name. */
    3503                                                                 $this->upgrader->strings['skin_update_successful'] = __( '%1$s installed and activated successfully.', 'museum-artifact' ) . ' <a href="#" class="hide-if-no-js" onclick="%2$s"><span>' . esc_html__( 'Show Details', 'museum-artifact' ) . '</span><span class="hidden">' . esc_html__( 'Hide Details', 'museum-artifact' ) . '</span>.</a>';
     3666                                                                $this->upgrader->strings['skin_update_successful'] = __( '%1$s installed and activated successfully.', 'museum-artifact' );
    35043667                                                                $this->upgrader->strings['skin_upgrade_end']       = __( 'All installations and activations have been completed.', 'museum-artifact' );
    35053668                                                                /* translators: 1: plugin name, 2: action number 3: total number of actions. */
    … …  
    35093672                                                                $this->upgrader->strings['skin_upgrade_start'] = __( 'The installation process is starting. This process may take a while on some hosts, so please be patient.', 'museum-artifact' );
    35103673                                                                /* translators: 1: plugin name. */
    3511                                                                 $this->upgrader->strings['skin_update_successful'] = esc_html__( '%1$s installed successfully.', 'museum-artifact' ) . ' <a href="#" class="hide-if-no-js" onclick="%2$s"><span>' . esc_html__( 'Show Details', 'museum-artifact' ) . '</span><span class="hidden">' . esc_html__( 'Hide Details', 'museum-artifact' ) . '</span>.</a>';
     3674                                                                $this->upgrader->strings['skin_update_successful'] = __( '%1$s installed successfully.', 'museum-artifact' );
    35123675                                                                $this->upgrader->strings['skin_upgrade_end']       = __( 'All installations have been completed.', 'museum-artifact' );
    35133676                                                                /* translators: 1: plugin name, 2: action number 3: total number of actions. */
    35143677                                                                $this->upgrader->strings['skin_before_update_header'] = __( 'Installing Plugin %1$s (%2$d/%3$d)', 'museum-artifact' );
     3678                                                        }
     3679
     3680                                                        // Add "read more" link only for WP < 4.8.
     3681                                                        if ( version_compare( $this->tgmpa->wp_version, '4.8', '<' ) ) {
     3682                                                                $this->upgrader->strings['skin_update_successful'] .= ' <a href="#" class="hide-if-no-js" onclick="%2$s"><span>' . esc_html__( 'Show Details', 'museum-artifact' ) . '</span><span class="hidden">' . esc_html__( 'Hide Details', 'museum-artifact' ) . '</span>.</a>';
    35153683                                                        }
    35163684                                                }
    … …  
    35723740                                                        $update_actions['dashboard'] = sprintf(
    35733741                                                                esc_html( $this->tgmpa->strings['complete'] ),
    3574                                                                 '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html__( 'Return to the Dashboard', 'museum-artifact' ) . '</a>'
     3742                                                                '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html( $this->tgmpa->strings['dashboard'] ) . '</a>'
    35753743                                                        );
    35763744                                                } else {
    … …  
    37153883                 */
    37163884                protected static function emulate_filter_bool( $value ) {
    3717                         // @codingStandardsIgnoreStart
     3885                        // phpcs:disable WordPress.Arrays.ArrayDeclarationSpacing.ArrayItemNoNewLine
    37183886                        static $true  = array(
    37193887                                '1',
    … …  
    37303898                                'off', 'Off', 'OFF',
    37313899                        );
    3732                         // @codingStandardsIgnoreEnd
     3900                        // phpcs:enable
    37333901
    37343902                        if ( is_bool( $value ) ) {
    … …  
    37523920                }
    37533921        } // End of class TGMPA_Utils
    3754 } // End of class_exists wrapper
     3922}
  • museum-artifact/0.2.2/includes/tgm/tgm.php

    r244257 r310691  
    4040        );
    4141        $config = array();
    42         museum_artifact_tgmpa( $plugins, $config );
     42        tgmpa( $plugins, $config );
    4343}
    4444add_action( 'tgmpa_register', 'museum_artifact_register_recommended_plugins' );
  • museum-artifact/0.2.2/readme.txt

    r307382 r310691  
    22Contributors: wpelemento
    33Requires at least: 5.0
    4 Stable tag: 0.2.1
     4Stable tag: 0.2.2
    55Requires PHP: 5.6
    66Tested up to: 6.9
    … …  
    99Tags:  blog, photography, e-commerce, one-column, two-columns, right-sidebar, left-sidebar, grid-layout, three-columns, four-columns, custom-background, custom-colors, custom-header, custom-logo, custom-menu, featured-images, flexible-header, footer-widgets, full-width-template, editor-style, sticky-post, theme-options, threaded-comments, translation-ready,  rtl-language-support, wide-blocks
    1010
    11 
    1211== Description ==
    1312
    … …  
    2423
    2524Font Awesome Free 6.5.2 by @fontawesome - https://fontawesome.com
    26  * License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
     25* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
    2726
    2827Webfonts Loader
    … …  
    7776
    7877== Changelog ==
     78
     79= January-12-2026 :: 0.2.2
     80
     81* Updated rtl.css file.
     82* Added hover effect on single post featured image.
     83* Resolve css error.
     84* Added menu in demo import.
     85* Fetching post in blog page.   
     86* Resolve tgm plugin error.
    7987
    8088= January-1-2026 :: 0.2.1
  • museum-artifact/0.2.2/rtl.css

    r288881 r310691  
    19561956}
    19571957
    1958 /* Wide Block  */
     1958/* ===============================================
     1959   Wide Block
     1960============================================= */
    19591961 
    19601962 .alignwide {
    … …  
    19671969  max-width    : 100vw;
    19681970}
     1971
     1972/* ===============================================
     1973   Sticky Copyright
     1974============================================= */
     1975
     1976.sticky-copyright.footer-copyright{
     1977  position: fixed;
     1978  bottom:0;
     1979  right:0;
     1980  width: 100%;
     1981  z-index: 999;
     1982  transition: bottom 0.4s;
     1983  box-shadow: 0px 0px 8px #000000;
     1984}
     1985.close-sticky {
     1986  position: static;
     1987}
     1988
     1989/* ===============================================
     1990   Sticky Sidebar
     1991============================================= */
     1992
     1993.sidebar-sticky {
     1994  position: sticky;
     1995  top: 100px;
     1996  z-index: 999;
     1997}
  • museum-artifact/0.2.2/style.css

    r307382 r310691  
    55Theme URI: https://www.wpelemento.com/products/free-art-gallery-wordpress-theme
    66Author URI: https://www.wpelemento.com/
    7 Version: 0.2.1
     7Version: 0.2.2
    88Requires PHP: 5.6
    99Tested up to: 6.9
Note: See TracChangeset for help on using the changeset viewer.