 
 
   render: =>
-    createPortal @renderPortalContent(), portals[0]
+    @portal ?= document.createElement('div')
+    createPortal @renderPortalContent(), @portal
 
 
   renderPortalContent: =>



  componentDidMount: =>
    document.addEventListener 'keydown', @handleEsc


  componentDidUpdate: (prevProps) =>


  componentWillUnmount: =>
    document.removeEventListener 'keydown', @handleEsc
    $(document).off '.modal'


  handleEsc: (e) =>
