Opening the login form with onclick in a theme component

I did it this way.

helper.attach("button", {
      label: "log_in",
      className: "css_class_name",
      action: "showLogin",
      icon: "plus"
      })