PluginProbe
Tableberg – Simple Gutenberg Table Block / 1.1.5
Tableberg – Simple Gutenberg Table Block v1.1.5
1.1.5 1.1.4 1.1.3 1.1.2 1.1.1 1.1.0 1.0.5 1.0.4 1.0.3 1.0.2 1.0.1 trunk 0.0.2 0.2.1 0.3.2 0.3.3 0.4.1 0.5.0 0.5.1 0.5.2 0.5.3 0.5.4 0.5.5 0.5.6 0.5.7 All 42 releases
← All changes | renderer/Table/InnerBlocksAttrsAdapter.php +5 -1 1.1.31.1.5 View file →
@@ -116,11 +116,15 @@
116 116
117 117 $row++;
118 118 }
119 119
120 + // When the whole object is absent Gutenberg supplies the block
121 + // schema's complete default. Starting from an empty array here would
122 + // create a partial object just to add row/column counts and would
123 + // silently lose nested defaults such as search.placeholder.
120 124 $table = isset($attrs['table']) && is_array($attrs['table'])
121 125 ? $attrs['table']
122 - : [];
126 + : TableAttrs::get_table_defaults();
123 127 $table['rows'] = $row;
124 128 $table['cols'] = $colsCount;
125 129
126 130 $adapted = $attrs;