CMS update coming next week…

Hey All,

I just wanted to let you know that we’re working hard on fixing up all the reported CMS issues, and we plan to push out an update sometime next week.

Keep the CMS feedback coming, it’s all been really helpful and encouraging so far :blush:

Can’t wait to show you all what we got cookin’

Cheers,
Dan

2 Likes

Is the following on your roadmap for an upcoming update?

  1. Automatic Placeholder Images
    Ability to use a default/placeholder image—e.g.:
    {{ item.image.src | default: '/images/placeholder.webp' }}
    …when item.image.src is not set in the Markdown frontmatter.

  2. Count Items in a Collection
    Ability to output the number of, for example, events within a collection, like:
    {{ collections.events|length }}

Okay, here we go…

  1. No, this is not on our list right now… and I’m not sure why this would be helpful as you’d need to replace before you publish anyway? Unless I’ve got the wrong end of the stick :laughing:
  2. You want to the return the number of items in a collection? So if I had 5 markdown files in a collection, you’d want to return that as a number?

Let me know your thoughts :slight_smile:

1. Store Images / Placeholder Logic

Let’s say I’m building a website for a business that has multiple locations across the country. For each location, I want to display a photo. However, sometimes I might not have an up-to-date photo for a particular branch.

In that case, I’ll leave the image: field empty in the corresponding Markdown file for that location.

If the field is empty, the site should display a default placeholder image that I’ve chosen.

Or let’s say I have a blog, but I’m too lazy right now to find or create an image. Still, I want to publish my blog post right away…

In that case, I just leave the image: field blank, and a placeholder image will be displayed automatically.


2. Counting Stores by Tags

Still talking about those business locations: I use tags for each branch like “very friendly”, “very clean”, or “fast service”.

If I create, say, 50 Markdown files (one per branch), not every location will have all the same tags.

Now, I want to automatically display the number of branches that are tagged as “very friendly”, and how many are tagged as “very clean”.

For example: “There are (number) of stores that are ‘very friendly’ and (number) that are ‘very clean’.”

And, if I later add a 51st, 52nd, or 53rd branch, this count should automatically update to reflect the new data.

We could add support for that… or you could just add your own placeholder to the project: image: image/placeholder.jpg

I’m pretty sure whatever placeholder we added, wouldn’t be good for everyone. Now, I’m not saying we won’t add this, but it feels like something that’s not required (yet). Will give it some more thought. :thinking:

I think you want a tag cloud… with the number of times they are used in the tag? so they display something like this: Friendly (23), Clean (52), Fast Service (38)

Or were you after a computed value based on the number of tags selected. So if I selected “Friendly (5)” and Clean (10)” you would show just the stores that matched those tags (along with the number)?

If I’m still wrong, perhaps you have an example site, or an image of what you’re tying to do?

No, I think we’re misunderstanding each other on this point.

What I mean is the function in the current Image Component ({{ item.image.src | default: ‘/images/placeholder.webp’ }}) isn’t working.

I’ve already placed my own placeholder image in the Resources folder.
Now, I’d like to use the function {{ item.image.src | default: ‘/images/placeholder.webp’ }} to point to my own placeholder image.

yes. in this case, i’m interested in both options ^^

Ah no, that’s not going to work or be supported. However, you’d probably be able to do it with the “Conditional” Component @ben has built :wink:

Essentially, you’ll be able to do things like “If no image exists, display this instead”.

We’ll be releasing this component later once we have the basics of the CMS rock solid!

Don’t forget the other parts of Elements …

Don’t worry, the main app is also getting updates. We’re working on ALL the things, ALL the time :laughing:

2 Likes

@dan Any news on a fix for the “Load More” feature not working on pages other than the home page?

This is the one thing holding me back from publishing updates to a couple of sites.

I started looking at the issue yesterday, hoping to have it fixed this week (no promises as the fix is more complicated than I had hoped!).

I’ll keep my fingers crossed!

this one is fixed in today’s 1.1.2 update :slight_smile:

And it is working great, thank you so much for getting this operational.

1 Like