Responsive Images
JSON
{
"default": {
"src": "https://www.lean-labs.com/hubfs/sr-assets/pattern-library/sr-bling-graphic-01/sr-bling-graphic-01.jpg",
"alt": "Describe your image",
"width": "900",
"height": "600"
},
"label": "Image",
"name": "bling_image",
"type": "image",
"help_text": "Recommended size: 900x600px"
},
{
"default": true,
"label": "SR Default Image Size",
"name": "sr_default_image_size",
"type": "boolean"
}Using Images in Modules / Templates
Format: {{ var.image(src, width, alt) }} where width is the 1x image size for large screens in pixels.
Using Background Images in CSS
Format: {{ var.bg_image(src, width) }} where the first instance of width is the 1x image size for small screens in pixels and the second one for large screens.
Last updated