{ComponentRegistry, WorkspaceStore, Actions} = require "inbox-exports" {RetinaImg} = require 'ui-components' React = require "react" _ = require "underscore-plus" class ModeToggle extends React.Component @displayName: 'ModeToggle' constructor: (@props) -> @state = @_getStateFromStores() componentDidMount: => @unsubscribe = WorkspaceStore.listen(@_onStateChanged, @) componentWillUnmount: => @unsubscribe?() render: => return
unless @state.visible