Description
If I use dependsOn with an $and or $or (or anything other than key>value) on a wysiwyg field tiny will not be refreshed on hide/show of the field.
Imagine my dependsOn looks like the below, which it needs to in order for $and to actually work:
dependsOn: {
$and: { lang: 'en', type: 'layout1' }
}
// I use $and as per the docs for expression-match as the below does not seem to work properly when hiding/showing
dependsOn: {
lang: lang, type: 'layout1'
}
This seems to be caused by the updated to expression-match and the inconsistency in it's use here.
Steps to reproduce the behavior
Add two selects and two wysiwyg editors (wysiwyg set to true). Make one dependant on one combination of select values and the other on the another using a similar expression to mine above.
The wysiwyg editor is visible for the first state however if you switch the value of the select the wysiwyg editor will disappear and not come back. This seems to be because the callbacks are not getting called as it picks the keys from the wrong place. Not sure of a quick way to fix myself looking at the formats allowed for expression-match.
Expected behavior
Wysiwyg editor should stay.
Actual behavior
It doesnt ;)