Handles boolean 'selected' attribute w/ html_attributes.
Enqueues media scripts when needed.