Skip to content

Commit

Permalink
KAD-2926 height/width removed from kadence-info-box-image-intrisic
Browse files Browse the repository at this point in the history
  • Loading branch information
gilbert-hernandez committed Jun 28, 2024
1 parent 8ee6579 commit cb3350c
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions includes/blocks/class-kadence-blocks-infobox-block.php
Original file line number Diff line number Diff line change
Expand Up @@ -276,12 +276,6 @@ public function build_css( $attributes, $css, $unique_id, $unique_style_id ) {
} elseif ( isset( $media_image['height'] ) && is_numeric( $media_image['height'] ) && isset( $media_image['width'] ) && is_numeric( $media_image['width'] ) ) {
$css->add_property( 'padding-bottom', round( ( absint( $media_image['height'] ) / absint( $media_image['width'] ) ) * 100, 4 ) . '%' );
}
if ( isset( $media_image['width'] ) && ! empty( $media_image['width'] ) ) {
$css->add_property( 'width', $media_image['width'] . 'px' );
}
if ( isset( $media_image['height'] ) && ! empty( $media_image['height'] ) ) {
$css->add_property( 'height', '0px' );
}
$css->add_property( 'max-width', '100%' );
}
if ( isset( $media_image['subtype'] ) && 'svg+xml' === $media_image['subtype'] ) {
Expand Down

0 comments on commit cb3350c

Please sign in to comment.