Replies: 3 comments 2 replies
-
Defaults are not a widget thing, but a "variable" thing. Most times the default is automatically read from the HTML/CSS value, but in your case you use an expression so Mosaico is not able to guess it and you have to make it explicit in the block definition, e.g:
You can hava a look at versafix template: the "bigSocialBlock" defines the default value for "bigSocialIconType". |
Beta Was this translation helpful? Give feedback.
-
I have tried this but it doesn't seem to work since, when I add a block, which uses the colorStyle attribute, it still seems to default the theme to Red instead of the set Neutral |
Beta Was this translation helpful? Give feedback.
-
I have found the solution to my problem. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Heya! I have a select widget for a color theme that i use in many templates of mine:
Tho i would like a different theme to be the default on different templates.
Is there any way to define a default value on a select widget?
The selections reffere back to a list of hexcodes that are used in an element's css that uses the theme like this:
-ko-background-color: @[colorStyle == 'Green' ? '#ebf1eb' : colorStyle == 'Blue' ? '#e9f0f5' : colorStyle == 'DarkBlue' ? '#e5ecf0' : colorStyle == 'Oliv' ? '#edeeec' : colorStyle == 'Neutral' ? '#f3eeea' : '#f5e6e9']
Beta Was this translation helpful? Give feedback.
All reactions