trigger state changes to toggle

Oct 15, 2020

I need to let users click on a picture and have it toggle over to a new state with explanatory text. I then want the user to be able to click on that text and get the picture (normal state) back. I can't add a trigger inside of the New State. Do I do this with variables somehow?

4 Replies
Shaun Martin

Hi Laurie - you are on the right track with variables...

Insert an image and create a state for it that replaces the image with the text you want.

Create a true/false variable and have a trigger for that variable to toggle each time your image is clicked. Set it's initial state to 'false'

Create a trigger to change the state of the image to "text" when the variable changes to to true, and change the state of the image to "normal" (the image) when the variable changes to false.

See the attached file.

Hope that helps.

-Shaun

This discussion is closed. You can start a new discussion or contact Articulate Support.