Skip to content

Commit

Permalink
Merge branch 'release/2.31.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
JiveDig committed Jan 8, 2024
2 parents 727c31a + 1471102 commit f940723
Show file tree
Hide file tree
Showing 3 changed files with 59 additions and 1 deletion.
3 changes: 3 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog

## 2.31.3 (1/8/24)
* Fixed: Added back updater icon functions.

## 2.31.2 (1/8/24)
* Changed: Now Load core getter functions immediately instead of `after_setup_theme`.
* Fixed: Cover block overlay was not rendering correctly when using Link as the overlay color.
Expand Down
55 changes: 55 additions & 0 deletions lib/init.php
Original file line number Diff line number Diff line change
Expand Up @@ -851,6 +851,61 @@ function mai_get_full_config() {
return $config;
}

/**
* Gets the plugin updater icons.
* This may be used in additiona Mai Plugins.
*
* @since 2.11.0
*
* @return array
*/
function mai_get_updater_icons() {
$icons = [];
$standard = mai_get_logo_icon_1x();
$retina = mai_get_logo_icon_2x();
if ( $standard && $retina ) {
$icons = [
'1x' => $standard,
'2x' => $retina,
];
}
return $icons;
}

/**
* Gets the Mai Theme logo icon @1x for plugin updater.
*
* @since 2.11.0
*
* @return string
*/
function mai_get_logo_icon_1x() {
static $icon = null;
if ( ! is_null( $icon ) ) {
return $icon;
}
$file = 'assets/img/icon-128x128.png';
$icon = file_exists( mai_get_dir() . $file ) ? mai_get_url() . $file : '';
return $icon;
}

/**
* Gets the Mai Theme logo icon @1x for plugin updater.
*
* @since 2.11.0
*
* @return string
*/
function mai_get_logo_icon_2x() {
static $icon = null;
if ( ! is_null( $icon ) ) {
return $icon;
}
$file = 'assets/img/icon-256x256.png';
$icon = file_exists( mai_get_dir() . $file ) ? mai_get_url() . $file : '';
return $icon;
}

/**
* Checks if Mai needs to load ACF Pro.
*
Expand Down
2 changes: 1 addition & 1 deletion mai-engine.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Plugin URI: https://bizbudding.com/mai-theme/
* GitHub Plugin URI: https://github.com/maithemewp/mai-engine/
* Description: The required plugin to power Mai child themes.
* Version: 2.31.2
* Version: 2.31.3
* Requires at least: 6.4
* Requires PHP: 7.4
* Author: BizBudding
Expand Down

0 comments on commit f940723

Please sign in to comment.