-
Notifications
You must be signed in to change notification settings - Fork 4
No Styles Output in Response on Custom Image Component #15
Comments
Hey @mortensassi , it should be working now, please confirm. |
Downloaded the new code but no changes. Edit: Played around and found out that if you create an asset/image field in a collection and extend its options, you get an correct output. Seems to be an issue with custom components i guess @pauloamgomes |
Yeah, I did some changes to handle better the components but forgot to handle a previous check where I dig into the collection fields to avoid being running code when is not required. Think now it should be working well. |
Great it works – Thank you for your work! Only thing i've noticed that you don't need to pass the options in order to get the styles output – Not sure if this is intendend? |
You mean, "options" inside the component field definition? The options are only required on nested fields, for example when you are defining an asset field inside a set: {
"fields": [
{
"type": "asset",
"name": "myasset",
"options": {
"styles": ["style1", "style2"]
}
}
]
} |
Yes i meant that, okay now i do understand how it works – I'll close this issue since it's fixed |
Like mentioned in LayoutComponents the styles won't get output in the response:
components.js
Response
The text was updated successfully, but these errors were encountered: