modal docs: handle modals via javascript