block.json
3 weeks ago
controller.php
10 months ago
empty.php
1 year ago
image.php
10 months ago
index.asset.php
4 months ago
index.js
4 months ago
slideshow.php
10 months ago
style-index-rtl.css
1 week ago
style-index.css
1 week ago
video.php
8 months ago
block.json
108 lines
| 1 | { |
| 2 | "$schema": "https://schemas.wp.org/trunk/block.json", |
| 3 | "apiVersion": 3, |
| 4 | "name": "surecart/product-media", |
| 5 | "title": "Product Media", |
| 6 | "description": "A container to display the product media", |
| 7 | "category": "surecart-product-page", |
| 8 | "keywords": [ |
| 9 | "image", |
| 10 | "media" |
| 11 | ], |
| 12 | "textdomain": "surecart", |
| 13 | "ancestor": [ |
| 14 | "surecart/product-page", |
| 15 | "surecart/product-template", |
| 16 | "surecart/upsell" |
| 17 | ], |
| 18 | "usesContext": [ |
| 19 | "postId" |
| 20 | ], |
| 21 | "supports": { |
| 22 | "interactivity": true, |
| 23 | "reusable": false, |
| 24 | "html": false, |
| 25 | "anchor": true |
| 26 | }, |
| 27 | "attributes": { |
| 28 | "auto_height": { |
| 29 | "type": "boolean", |
| 30 | "default": true |
| 31 | }, |
| 32 | "desktop_gallery": { |
| 33 | "type": "boolean", |
| 34 | "default": false |
| 35 | }, |
| 36 | "height": { |
| 37 | "type": "string", |
| 38 | "default": "310px" |
| 39 | }, |
| 40 | "width": { |
| 41 | "type": "string" |
| 42 | }, |
| 43 | "show_thumbnails": { |
| 44 | "type": "boolean", |
| 45 | "default": true |
| 46 | }, |
| 47 | "thumbnails_per_page": { |
| 48 | "type": "number", |
| 49 | "default": 5 |
| 50 | }, |
| 51 | "hide_empty": { |
| 52 | "type": "boolean", |
| 53 | "default": false |
| 54 | }, |
| 55 | "lightbox": { |
| 56 | "type": "boolean", |
| 57 | "default": true |
| 58 | }, |
| 59 | "id": { |
| 60 | "type": "string" |
| 61 | } |
| 62 | }, |
| 63 | "variations": [ |
| 64 | { |
| 65 | "name": "slider", |
| 66 | "title": "Product Media Slider", |
| 67 | "icon": "image-flip-horizontal", |
| 68 | "description": "Display the product media in a slider.", |
| 69 | "isDefault": true, |
| 70 | "attributes": { |
| 71 | "desktop_gallery": false |
| 72 | }, |
| 73 | "isActive": [ |
| 74 | "desktop_gallery" |
| 75 | ], |
| 76 | "scope": [ |
| 77 | "inserter", |
| 78 | "block", |
| 79 | "transform" |
| 80 | ] |
| 81 | }, |
| 82 | { |
| 83 | "name": "gallery", |
| 84 | "title": "Product Media Gallery", |
| 85 | "icon": "screenoptions", |
| 86 | "description": "Display the product media in a gallery on desktop devices.", |
| 87 | "attributes": { |
| 88 | "desktop_gallery": true |
| 89 | }, |
| 90 | "isActive": [ |
| 91 | "desktop_gallery" |
| 92 | ], |
| 93 | "scope": [ |
| 94 | "inserter", |
| 95 | "block", |
| 96 | "transform" |
| 97 | ] |
| 98 | } |
| 99 | ], |
| 100 | "render": "file:./view.php", |
| 101 | "editorScript": "file:./index.js", |
| 102 | "editorStyle": [ |
| 103 | "surecart-image-slider" |
| 104 | ], |
| 105 | "style": [ |
| 106 | "file:./style-index.css" |
| 107 | ] |
| 108 | } |