@wordpress/scripts
Version:
Collection of reusable scripts for WordPress development.
51 lines (50 loc) • 1.01 kB
JSON
{
"$schema": "https://schemas.wp.org/trunk/block.json",
"apiVersion": 2,
"name": "my-plugin/image-gallery",
"title": "Image Gallery",
"category": "media",
"icon": "format-gallery",
"description": "An image gallery block with customizable layout.",
"attributes": {
"images": {
"type": "array",
"default": [],
"source": "query",
"selector": "img",
"query": {
"url": {
"type": "string",
"source": "attribute",
"attribute": "src"
},
"alt": {
"type": "string",
"source": "attribute",
"attribute": "alt",
"default": ""
},
"id": {
"type": "number",
"source": "attribute",
"attribute": "data-id"
}
}
},
"columns": {
"type": "number",
"default": 3
},
"imageCrop": {
"type": "boolean",
"default": true
}
},
"supports": {
"align": [ "wide", "full" ]
},
"textdomain": "my-plugin",
"editorScript": "file:./index.js",
"editorStyle": "file:./index.css",
"style": "file:./style-index.css"
}