2014-10-17 15:28:22 +00:00
|
|
|
.container
|
|
|
|
.row
|
|
|
|
.col-md-12
|
|
|
|
h1 Choose your username
|
|
|
|
|
|
|
|
br
|
|
|
|
|
|
|
|
p
|
2015-05-13 10:49:36 +00:00
|
|
|
' Every asciinema user gets a profile page at
|
2014-10-17 15:28:22 +00:00
|
|
|
a href="#"
|
|
|
|
| #{root_url}~
|
|
|
|
strong username
|
|
|
|
' .
|
|
|
|
|
|
|
|
= form_for @user, url: username_path, method: :post, html: { class: "username-form" } do |f|
|
|
|
|
.form-group
|
|
|
|
= f.label :username, 'Your username:'
|
|
|
|
= f.text_field :username, class: 'form-control', 'data-behavior' => 'focus'
|
2015-11-02 07:52:59 +00:00
|
|
|
- if @error == :username_invalid
|
2014-10-17 15:28:22 +00:00
|
|
|
br
|
|
|
|
p.text-danger
|
|
|
|
' Use only letters, digits and "-" character.
|
|
|
|
' Examples:
|
|
|
|
em johnny-knoxville, destroyer666
|
2015-11-02 07:52:59 +00:00
|
|
|
- if @error == :username_taken
|
|
|
|
br
|
|
|
|
p.text-danger
|
|
|
|
' This username was already taken.
|
2014-10-17 15:28:22 +00:00
|
|
|
.form-group
|
|
|
|
= f.submit 'Continue', class: 'btn btn-primary'
|
|
|
|
a.btn href=skip_username_path I'll do it later
|
|
|
|
|