carolinan / fullsiteediting

https://fullsiteediting.com/
282 stars 87 forks source link

Duotones on color options page #42

Open glerner opened 1 year ago

glerner commented 1 year ago

https://fullsiteediting.com/lessons/theme-json-color-options/ theme.json works as described, so I'm guessing the issue is how duotones are (not?) applied on that page.

Probably good to mention on this page that to apply a duotone, use the image block's "hover menu" circle icon. I thought my theme.json duotone section was incorrect, since doutone didn't appear in the image block settings.

I would like to see Duotone as part of the Image Block settings panel, just like background color and gradient are for paragraphs and columns. (I know that is not a theme.json question...)

Is there a way to specify duotone for featured images in theme.json, maybe with a setting per page for which duotone to use? https://wordpress.org/themes/wei/ does this.

p.s. Here's the duotones I am defining (using the hex color codes for my primary and secondary dark colors and lightened versions of them). "duotone": [ { "colors": [ "#000000", "#ffffff" ], "slug": "duotone-foreground-and-background", "name": "Foreground" }, { "colors": [ "#0068a7", "#9ddbed" ], "slug": "doutone-primary", "name": "Primary" }, { "colors": [ "#20828c", "#cfe7c7" ], "slug": "duotone-secondary", "name": "Secondary" }, { "colors": [ "#0068a7", "#cfe7c7" ], "slug": "primary-and-secondary", "name": "Primary and Secondary" } ],

carolinan commented 10 months ago

Hi I am struggling to understand what is asked here. No, theme.json does not have any per-page or per-post settings. Yes, you themes can add custom controls, you can use the Wei theme as an example and copy code from there.