Astra_Customizer::logo_image_sizes( array $sizes, array $metadata )

Add logo image sizes in filter.


Description


Parameters

$sizes

(array) (Required) Sizes.

$metadata

(array) (Required) attachment data.


Return

(array)


Source

File: inc/customizer/class-astra-customizer.php

		public static function logo_image_sizes( $sizes, $metadata ) {

			$logo_width = astra_get_option( 'ast-header-responsive-logo-width' );

			if ( is_array( $sizes ) && '' != $logo_width['desktop'] ) {
				$max_value              = max( $logo_width );
				$sizes['ast-logo-size'] = array(
					'width'  => (int) $max_value,
					'height' => 0,
					'crop'   => false,
				);
			}

			return $sizes;
		}

Changelog

Changelog
Version Description
1.0.0 Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.