Going over the Blueprint documentation and I’m not sure if its possible but lets say I have a page with 9 pictures/divs and I would like the user to be able to login into the admin and be able to enable or disable those images/elements from being displayed with a toggle button on the form. Is that possible with a blueprint for a theme/page? Basically the page is kind of like something being in stock or out of stock and I would want the user to easily update the page with a form within the admin.
I would use a list of images paired with a toggle (if that is possible)
Something like this
header.products:
name: products
type: list
style: vertical
label: Products
fields:
.inStock:
type: toggle
label: Product In Stock
highlight: 1
default: 1
options:
1: PLUGIN_ADMIN.YES
0: PLUGIN_ADMIN.NO
validate:
type: bool
.image:
type: file
label: Product Image
multiple: false
destination: 'path/to/folder'
accept:
- image/*
and the template
{% for product in page.header.products %}
{% if product.inStock %}
<div class='product'>
{% for image in product.image %}
<img src='{{ image.path }}' />
{% endfor %}
</div>
{% endif %}
{% endfor %}
Hope that helps!
Something like this should work, I would think. Have you tried it?