dynamic labels for content schema blocks?

Solved
tony5280
Shopify Partner
71 6 24

Hi, I've set up a "section" aka content schema for a coming soon page. The relevant section looks like this:

	"blocks": [
		{
			"type": "Item",
			"name": "Item Label in the Theme Editor",
			"settings": [


When the request came through, I didn't expect the admin to enter 50 different products.
Screen Shot 2020-10-16 at 3.51.10 PM.png
The blocks are now somewhat unmanageable in the theme editor. We know that each one of these has it's own data, how can I either get an option to label a block as it's added, or pick up one of the settings?

Accepted Solution (1)

Accepted Solutions
tony5280
Shopify Partner
71 6 24

This is an accepted solution.

Solving my own posts is becoming a pattern. I guess I'm just hoping that I help someone else alone the way.

Apparently, if one of your elements inside a block is given the id of title, it's automatic. 

"settings": [
				{
					"type": "text",
					"id": "title",
					"label": "Title",
					"info":"optional"
				},

"id":"title"
That's a pretty obscure and nuanced feature. 
Feels more like a cheat-code than a feature. I would think it would warrant more than a sentence here but whatever: 
https://shopify.dev/tutorials/develop-theme-use-sections#section-title

View solution in original post

Replies 6 (6)
tony5280
Shopify Partner
71 6 24

Is there any way to label a block as it's added? or pick up one of the values entered?

please help

tony5280
Shopify Partner
71 6 24

Is there any way to label a block as it's added? or pick up one of the values entered?

Bueller? Bueller?

tony5280
Shopify Partner
71 6 24

This is an accepted solution.

Solving my own posts is becoming a pattern. I guess I'm just hoping that I help someone else alone the way.

Apparently, if one of your elements inside a block is given the id of title, it's automatic. 

"settings": [
				{
					"type": "text",
					"id": "title",
					"label": "Title",
					"info":"optional"
				},

"id":"title"
That's a pretty obscure and nuanced feature. 
Feels more like a cheat-code than a feature. I would think it would warrant more than a sentence here but whatever: 
https://shopify.dev/tutorials/develop-theme-use-sections#section-title

View solution in original post

phil_CM
Excursionist
80 1 6

Thanks will try this was looking for this solution 

phil_CM
Excursionist
80 1 6

Just changed one to title but didn’t seem to fix it. Al still have the same name 

bigskillet
Excursionist
11 0 6

I've noticed that it works if you use id="text" to match the input type input="text". The same goes for image. Using id="image" will use the image as the block icon. I would also like to see some documentation for this!

{
  "type": "text",
  "id": "text",
  "label": "Text"
}

{
  "type": "image_picker",
  "id": "image",
  "label": "Image"
}