Yes, this is what happens.
That toggle of CSS is essentially what I am doing on the plugin element itself using the dynamic expression to set the unique name/id of the instance. So now, my dynamic expression is ‘reusable element is visible: formatted as text’ with the NO value blank and the YES value set to the correct unique name/id.
Yes, this would be an approach to alter the plugin code to toggle the CSS via the plugin code. I opted to not touch the code and use the dynamic expression approach. Maybe that comes back to bite me and I’ll have to alter the code, but for now it is working.
Its Data Jedi which works fine for multiple instances on the same page visible at the same time.
What I experienced is this:
- If the plugin element instance is not initialized or doesn’t have the unique name set for it, and the workflow actions target the unique plugin instance with the unique name, there is an error reported as expected that the plugin instance is not defined, because there is no matching unique name on any plugin instance that matches the unique name used in the action.
- If the plugin instance is visible on the page and has the unique name set, and action runs to target it, it works fine and targets the correct instance, even if there are multiple instances of the plugin element on the same page also visible.
- If the plugin instance is visible on page and targeted with unique name, it works. Then the plugin element is made not visible via conditions, and a second plugin instance is made visible via conditions, and that second plugin instance is targeted with its unique name via actions, it works. BUT, if I then make plugin instance 2 not visible by condition, making plugin instance 1 visible again by conditional, and I run actions using the unique name of plugin instance 1, it works, HOWEVER, it actual triggers the plugin instance 2 that is no longer visible. And that occurs even when the unique names of the plugin instances are completely different from each other.
The strange thing is that these plugin elements are from a reusable element. So I do not experience the same issue in #3 when the plugin elements are on the page directly (ie: 2 elements different unique names). Instead I only experience when I have two instances of a reusable element that has the ONE plugin element that uses a dynamic expression to dynamically set the unique name of the plugin element ‘instance’ (I say instance of the plugin element since it is the same plugin element but inside a reusable whose reusable is on the page twice - so two instances of the reusable that holds a single plugin element, making it so there are two instances of the plugin element, but have dynamically set unique names).
With that issue from #3 when the plugin instance 1 is made visible again, but action end up running on the now not visible plugin instance 2, the values obtained from the actions running, are designed to take the property values from the reusable element. The property values of the not visible reusable element instance were getting returned, as for some reason, the plugin instance 2 was triggering the event triggers.