PluginProbe
Meow Gallery / 4.2.2
Meow Gallery v4.2.2
5.5.5 5.5.4 5.5.3 5.5.2 5.5.1 5.5.0 5.4.9 5.4.8 5.4.7 4.1.5 4.1.6 4.1.7 4.1.8 4.1.9 4.2.0 4.2.1 4.2.2 4.2.3 4.2.4 4.2.5 4.2.6 4.2.7 4.2.8 4.2.9 4.3.0 All 157 releases
← All changes | classes/builders/masonry.php +3 -4 5.5.2 → 4.2.2 View file →
@@ -7,12 +7,11 @@
7 7 $this->layout = 'masonry';
8 8 }
9 9
10 10 function inline_css() {
11 - $options = get_option( Meow_MGL_Core::get_plugin_option_name(), null );
12 11 $class_id = '#' . $this->class_id;
13 - $gutter = isset( $this->atts['gutter'] ) ? $this->atts['gutter'] : ( $options['masonry_gutter'] ?? 10 );
14 - $columns = isset( $this->atts['columns'] ) ? $this->atts['columns'] : ( $options['masonry_columns'] ?? 3 );
12 + $gutter = isset( $this->atts['gutter'] ) ? $this->atts['gutter'] : get_option( 'mgl_masonry_gutter', 10 );
13 + $columns = isset( $this->atts['columns'] ) ? $this->atts['columns'] : get_option( 'mgl_masonry_columns', 3 );
15 14 $isPreview = $this->isPreview;
16 15 ob_start();
17 16 include dirname( __FILE__ ) . '/masonry.css.php';
18 17 $html = ob_get_clean();
@@ -20,9 +19,9 @@
20 19 }
21 20
22 21 function build_next_cell( $id, $data ) {
23 22 $html = parent::build_next_cell( $id, $data );
24 - $columns = ( isset( $this->atts['columns'] ) ? $this->atts['columns'] : Meow_MGL_Core::get_plugin_option( 'masonry_columns', 3 ) ) + 1;
23 + $columns = ( isset( $this->atts['columns'] ) ? $this->atts['columns'] : get_option( 'mgl_masonry_columns', 3 ) ) + 1;
25 24 $html = str_replace( '100vw', 100 / $columns . 'vw', $html );
26 25 return $html;
27 26 }
28 27