PluginProbe
Gutenberg / 24.1.0
Gutenberg v24.1.0
24.1.0 24.0.0 23.9.1 23.9.0 23.8.0 23.7.2 23.7.1 23.7.0 23.6.1 23.6.2 23.6.0 23.5.3 23.5.2 23.5.1 23.5.0 23.4.0 23.3.2 23.3.1 23.3.0 23.2.0 23.2.1 23.2.2 23.1.1 23.1.0 23.0.1 All 404 releases
← All changes | lib/experimental/dashboard-widgets/class-wp-rest-widget-modules-controller.php +62 -0 23.7.1 → 24.1.0 View file →
@@ -210,12 +210,20 @@
210 210 if ( rest_is_field_included( 'help', $fields ) ) {
211 211 $data['help'] = $widget_type->help;
212 212 }
213 213
214 + if ( rest_is_field_included( 'icon', $fields ) ) {
215 + $data['icon'] = $widget_type->icon;
216 + }
217 +
214 218 if ( rest_is_field_included( 'actions', $fields ) ) {
215 219 $data['actions'] = $widget_type->actions;
216 220 }
217 221
222 + if ( rest_is_field_included( 'attributes', $fields ) ) {
223 + $data['attributes'] = $widget_type->attributes;
224 + }
225 +
218 226 if ( rest_is_field_included( 'keywords', $fields ) ) {
219 227 $data['keywords'] = $widget_type->keywords;
220 228 }
221 229
@@ -314,8 +322,15 @@
314 322 'context' => array( 'view', 'edit', 'embed' ),
315 323 'readonly' => true,
316 324 ),
317 325
326 + 'icon' => array(
327 + 'description' => __( 'Registered icon name identifying the widget type visually.', 'gutenberg' ),
328 + 'type' => array( 'string', 'null' ),
329 + 'context' => array( 'view', 'edit', 'embed' ),
330 + 'readonly' => true,
331 + ),
332 +
318 333 'actions' => array(
319 334 'description' => __( 'Declarative actions the widget type exposes. Labels are translatable.', 'gutenberg' ),
320 335 'type' => array( 'array', 'null' ),
321 336 'items' => array(
@@ -322,11 +337,58 @@
322 337 'type' => 'object',
323 338 'properties' => array(
324 339 'id' => array( 'type' => 'string' ),
325 340 'label' => array( 'type' => 'string' ),
341 + 'icon' => array( 'type' => 'string' ),
342 + 'relevance' => array(
343 + 'type' => 'string',
344 + 'enum' => array( 'high', 'medium', 'low' ),
345 + ),
326 346 'href' => array( 'type' => 'string' ),
327 347 'download' => array( 'type' => array( 'string', 'boolean' ) ),
328 348 'openInNewTab' => array( 'type' => 'boolean' ),
349 + ),
350 + ),
351 + 'context' => array( 'view', 'edit', 'embed' ),
352 + 'readonly' => true,
353 + ),
354 +
355 + 'attributes' => array(
356 + 'description' => __( 'Attribute schema hosts render settings from: the JSON-expressible subset of a DataViews field per entry. User-facing strings are translatable.', 'gutenberg' ),
357 + 'type' => array( 'array', 'null' ),
358 + 'items' => array(
359 + 'type' => 'object',
360 + 'properties' => array(
361 + 'id' => array( 'type' => 'string' ),
362 + 'type' => array( 'type' => 'string' ),
363 + 'label' => array( 'type' => 'string' ),
364 + 'header' => array( 'type' => 'string' ),
365 + 'description' => array( 'type' => 'string' ),
366 + 'placeholder' => array( 'type' => 'string' ),
367 + 'readOnly' => array( 'type' => 'boolean' ),
368 + 'isDisabled' => array( 'type' => 'boolean' ),
369 + 'enableSorting' => array( 'type' => 'boolean' ),
370 + 'enableHiding' => array( 'type' => 'boolean' ),
371 + 'enableGlobalSearch' => array( 'type' => 'boolean' ),
372 + 'elements' => array(
373 + 'type' => 'array',
374 + 'items' => array(
375 + 'type' => 'object',
376 + 'properties' => array(
377 + 'value' => array( 'type' => array( 'string', 'integer', 'number', 'boolean', 'null' ) ),
378 + 'label' => array( 'type' => 'string' ),
379 + 'description' => array( 'type' => 'string' ),
380 + ),
381 + ),
382 + ),
383 + 'filterBy' => array( 'type' => array( 'object', 'boolean' ) ),
384 + 'format' => array( 'type' => 'object' ),
385 + 'isValid' => array( 'type' => 'object' ),
386 + 'Edit' => array( 'type' => array( 'string', 'object' ) ),
387 + 'relevance' => array(
388 + 'type' => 'string',
389 + 'enum' => array( 'high', 'medium', 'low' ),
390 + ),
329 391 ),
330 392 ),
331 393 'context' => array( 'view', 'edit', 'embed' ),
332 394 'readonly' => true,