I am sure one day soon Articulate will push an update that empowers us with dropdown (select) menus. But in the meantime, if you are like me you have probably avoided building them—it takes so many layers and triggers. But sometimes it really just makes sense to use a dropdown menu!
Generally speaking what I have done is:
- Created two Storyline Variables:
- One holds my list of items
- The other stores the Learner’s selection
- Then I added a shape to the slide.
- I size and position it where I want my dropdown.
- Lastly… I revel in the glory of a dropdown.
How it works; the jQuery:
- Adds my CSS to the page header (to style the dropdown).
- Adds a DIV to hold the menu.
- Adds a SELECT to the div.
- Grabs the list of values from Storyline and adds each as an OPTION.
- Looks for my shape (based on its alt-text).
- Moves the DIV/SELECT to the same position as the shape.
- Resizes them to about the same size as the shape.
- Adds a listener to detect when the Learner makes a selection.
- Updates the Storyline Variable when a selection is made.
Check out the demo:
Grab the sample Storyline file that includes the code and start playing!
Watch the video for more details:
A few notes:
If the slide changes size (player set to “scale to fit”) then the menu will not move with the other stuff. There is a way around this (watch for change and move) but I didn’t need it yet for my project.
The colors, fonts, etc. can be changed by editing the CSS. I mostly used clips from this CodePen to create mine: https://codepen.io/ericrasch/pen/zjDBx
Next week, I'll show you how I achieve this in Adobe Captivate! For more pre-built eLearning goodies, check out the eLearning Brothers Template Library.
James Kingsley has worked in the eLearning Industry for over 16 years. He has won several awards for combining technologies to produce better eLearning. He is an Articulate MVP. James is a Solver of Complex eLearning Puzzles and the Co-Founder of ReviewMyElearning.com. You can follow him on Twitter or connect with him on LinkedIn for additional tips and examples. He pots random musings on JamesKingsley.com.