     @items.splice(index, 0, item)
     @emit 'item-added', item, index
     @emitter.emit 'did-add-item', {item, index}
-    @activeItem ?= item
+    @setActiveItem(item) unless @getActiveItem()?
     item
 
   # Public: Adds the given items to the pane.

    @emitter = new Emitter

    @items = Sequence.fromArray(compact(params?.items ? []))
    @activeItem ?= @items[0]

    @subscribe @items.onEach (item) =>
      if typeof item.on is 'function'

    return if index is -1
    if item is @activeItem
      if @items.length is 1
        @setActiveItem(undefined)
      else if index is 0
        @activateNextItem()
      else
