Hey @logins! I’m afraid there is no simple workaround at the moment. We could use the Static to Collection List Attribute but there is a current bug where we need to set the item to interactive as not doing so drops some items.
If these items do not change much, we could write some code with the API to add these elements always
/**
* Adds a static item to the Collection Instance.
* @param itemsData An array of static items data.
* @param itemsData.itemElement The new item to store.
* @param itemsData.targetIndex The index where to place the new item.
* @param itemsData.interactive Defines if the item will be interactive or not.
*/
addStaticItems(
itemsData: Array<{ itemElement: HTMLDivElement; targetIndex: number; interactive: boolean }>
): Promise<void>;
Let me know if you want to go this route! If so please share a link!
Thanks @Support-Luis for getting back to me. actually I implemented what I wanted with a simple trick using the value of the switch field from my CMS.
<div class="resource-category">
<div class="tag-label">Country</div>
<div class="global-resource">
<div class="text-size-small">Global</div>
</div>
<div class="w-embed w-script">
<script>
// Add the countries list to the global resource
if (true) { // replace true by the CMS switch field ^^
document.currentScript.parentNode.appendChild(document.querySelector('.countries-list-for-global'));
}
</script>
</div>
</div>