   , [message._id]
   ref = useRef()
   messageBodyRef = useRef()
+  addTagRef = useRef()
 
   ## Support dragging rendered attachment like dragging message itself
   messageFileRef = useRef()

ThreadPrivacy = React.memo ({message, tabindex}) ->
  onPrivacy = (e) ->
    e.preventDefault()
    e.stopPropagation()
    Meteor.call 'threadPrivacy', message._id,
      privacyOptionsByCode[e.target.getAttribute 'data-code'].list
    dropdownToggle e

  <div className="btn-group">
    <button className="btn btn-warning dropdown-toggle threadPrivacyToggle" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" tabIndex={tabindex}>
      {"Thread Privacy "}
      <span className="caret"/>
    </button>
    <ul className="dropdown-menu" role="menu">
      {for privacy in privacyOptions
        active = _.isEqual _.sortBy(privacy.list),
                           _.sortBy(message.threadPrivacy ? ['public'])
        <li key={privacy.code} className="threadPrivacy #{if active then 'active' else ''}">
          <a href="#" data-code={privacy.code} onClick={onPrivacy}>
            {privacy.display}
          </a>
        </li>
      }
    </ul>
  </div>

EmojiButtons = React.memo ({message, can}) ->
  emojis = useTracker ->

            }
          </span>
          <span className="btn-group">
            <Dropdown>
              <Dropdown.Toggle variant="default"
               className="label label-default" ref={addTagRef}>
                <span className="fas fa-plus"/>
                {' Tag'}
              </Dropdown.Toggle>
              <Dropdown.Menu className="tagMenu">
                <li className="disabled">
                  <a>
                    <form className="input-group input-group-sm">
                      <input className="tagAddText form-control" type="text" placeholder="New Tag..."/>
                      <div className="input-group-btn">
                        <button className="btn btn-default tagAddNew" type="submit" onClick={onTagNew}>
                          <span className="fas fa-plus"/>
                        </button>
                      </div>
                    </form>
                  </a>
                </li>
                {if absentTags.length
                  <>
                    <li className="divider" role="separator"/>
                    {for tag in absentTags
                      <li key={tag.key}>
                        <Dropdown.Item className="tagAdd" href="#" data-tag={tag.key} onClick={onTagAdd}>{tag.key}</Dropdown.Item>
                      </li>
                    }
                  </>
                }
              </Dropdown.Menu>
            </Dropdown>
          </span>
          <MessageLabels message={message}/>
          <span className="lower-strut"/>
