| @@ -40,9 +40,9 @@ | ||
| 40 | 40 | $this->get_image_container_css( $attributes, 'Mobile' ), |
| 41 | 41 | ); |
| 42 | 42 | // Image css |
| 43 | 43 | $css_generator->add_class_styles( |
| 44 | - '{{WRAPPER}} .ablocks-block--featured-image img', | |
| 44 | + '{{WRAPPER}} .ablocks-image-figure img', | |
| 45 | 45 | $this->get_image_css( $attributes ), |
| 46 | 46 | $this->get_image_css( $attributes, 'Tablet' ), |
| 47 | 47 | $this->get_image_css( $attributes, 'Mobile' ), |
| 48 | 48 | ); |
| @@ -48,9 +48,9 @@ | ||
| 48 | 48 | ); |
| 49 | 49 | |
| 50 | 50 | // Image hover css |
| 51 | 51 | $css_generator->add_class_styles( |
| 52 | - '{{WRAPPER}} .ablocks-block--featured-image img:hover', | |
| 52 | + '{{WRAPPER}} .ablocks-image-figure img:hover', | |
| 53 | 53 | $this->get_image_hover_css( $attributes ), |
| 54 | 54 | $this->get_image_hover_css( $attributes, 'Tablet' ), |
| 55 | 55 | $this->get_image_hover_css( $attributes, 'Mobile' ), |
| 56 | 56 | ); |
| @@ -66,8 +66,9 @@ | ||
| 66 | 66 | '{{WRAPPER}}', |
| 67 | 67 | $this->get_wrapper_css( $attributes ), |
| 68 | 68 | $this->get_wrapper_css( $attributes, 'Tablet' ), |
| 69 | 69 | $this->get_wrapper_css( $attributes, 'Mobile' ), |
| 70 | + $css_generator->custom_device_map( function ( $device ) use ( $attributes ) { return $this->get_wrapper_css( $attributes, $device ); } ) | |
| 70 | 71 | ); |
| 71 | 72 | |
| 72 | 73 | // Image container css |
| 73 | 74 | $css_generator->add_class_styles( |
| @@ -74,8 +75,9 @@ | ||
| 74 | 75 | '{{WRAPPER}}', |
| 75 | 76 | $this->get_image_container_css( $attributes ), |
| 76 | 77 | $this->get_image_container_css( $attributes, 'Tablet' ), |
| 77 | 78 | $this->get_image_container_css( $attributes, 'Mobile' ), |
| 79 | + $css_generator->custom_device_map( function ( $device ) use ( $attributes ) { return $this->get_image_container_css( $attributes, $device ); } ) | |
| 78 | 80 | ); |
| 79 | 81 | // Image css |
| 80 | 82 | $css_generator->add_class_styles( |
| 81 | 83 | '{{WRAPPER}} .ablocks-image-figure img', |
| @@ -81,8 +83,9 @@ | ||
| 81 | 83 | '{{WRAPPER}} .ablocks-image-figure img', |
| 82 | 84 | $this->get_image_css( $attributes ), |
| 83 | 85 | $this->get_image_css( $attributes, 'Tablet' ), |
| 84 | 86 | $this->get_image_css( $attributes, 'Mobile' ), |
| 87 | + $css_generator->custom_device_map( function ( $device ) use ( $attributes ) { return $this->get_image_css( $attributes, $device ); } ) | |
| 85 | 88 | ); |
| 86 | 89 | |
| 87 | 90 | // Image hover css |
| 88 | 91 | $css_generator->add_class_styles( |
| @@ -89,8 +92,9 @@ | ||
| 89 | 92 | '{{WRAPPER}} .ablocks-image-figure img:hover', |
| 90 | 93 | $this->get_image_hover_css( $attributes ), |
| 91 | 94 | $this->get_image_hover_css( $attributes, 'Tablet' ), |
| 92 | 95 | $this->get_image_hover_css( $attributes, 'Mobile' ), |
| 96 | + $css_generator->custom_device_map( function ( $device ) use ( $attributes ) { return $this->get_image_hover_css( $attributes, $device ); } ) | |
| 93 | 97 | ); |
| 94 | 98 | // Image caption css |
| 95 | 99 | $css_generator->add_class_styles( |
| 96 | 100 | '{{WRAPPER}} .ablocks-image-figure .ablocks-image-caption', |
| @@ -96,8 +100,9 @@ | ||
| 96 | 100 | '{{WRAPPER}} .ablocks-image-figure .ablocks-image-caption', |
| 97 | 101 | $this->get_image_caption_css( $attributes ), |
| 98 | 102 | $this->get_image_caption_css( $attributes, 'Tablet' ), |
| 99 | 103 | $this->get_image_caption_css( $attributes, 'Mobile' ), |
| 104 | + $css_generator->custom_device_map( function ( $device ) use ( $attributes ) { return $this->get_image_caption_css( $attributes, $device ); } ) | |
| 100 | 105 | ); |
| 101 | 106 | |
| 102 | 107 | // Image caption hover css |
| 103 | 108 | $css_generator->add_class_styles( |
| @@ -103,9 +108,10 @@ | ||
| 103 | 108 | $css_generator->add_class_styles( |
| 104 | 109 | '{{WRAPPER}} .ablocks-image-figure .ablocks-image-caption:hover', |
| 105 | 110 | $this->get_image_caption_hover_css( $attributes ), |
| 106 | 111 | $this->get_image_caption_hover_css( $attributes, 'Tablet' ), |
| 107 | - $this->get_image_caption_hover_css( $attributes, 'Mobile' ) | |
| 112 | + $this->get_image_caption_hover_css( $attributes, 'Mobile' ), | |
| 113 | + $css_generator->custom_device_map( function ( $device ) use ( $attributes ) { return $this->get_image_caption_hover_css( $attributes, $device ); } ) | |
| 108 | 114 | ); |
| 109 | 115 | |
| 110 | 116 | return $css_generator->generate_css(); |
| 111 | 117 | } |