Background
The setting field type Css Background
Arguments
Code example
@schema
{
"name" : "CSS Background",
"author" : "LayoutHub",
"website" : "https://www.LayoutHub.com"
}
@endschema
<div class="sample-demo" style="background: @attr(section.settings.my_bg); padding: 100px;">
<h1>Sample Text</h1>
</div>[
{
name: 'my_bg',
label: 'Set background',
type: 'css_background',
value: {
color: '#14C39B',
image: '%URL%thumbnail.jpg',
position: 'center center',
repeat: 'no-repeat',
size: 'contain'
}
}
]How it works

Last updated