 
 	showGroup: showGroup
 	getVisibleGroup: getVisibleGroup
+	addGroup: addGroup

	$tabButtons = {}

	buttons = new ReactiveVar {}

	animating = false
	open = new ReactiveVar false

	getVisibleGroup = ->
		visibleGroup.get()

	addGroup = (id, groups) ->
		Tracker.nonreactive ->
			btns = buttons.get()
			if btns[id]
				btns[id].groups ?= []
				btns[id].groups = _.union btns[id].groups, groups
				buttons.set btns
			else
				extraGroups[id] ?= []
				extraGroups[id] = _.union extraGroups[id], groups

	setTemplate: setTemplate
	setData: setData
	getTemplate: getTemplate
