Archived
herpderp
This commit is contained in:
@@ -36,6 +36,7 @@ and (min-width: 0px) //TODO
|
|||||||
color: #F00;
|
color: #F00;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.flash {
|
.flash {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
@@ -271,7 +272,7 @@ and (min-width: 0px) //TODO
|
|||||||
margin-right: 0;
|
margin-right: 0;
|
||||||
}
|
}
|
||||||
&.author {
|
&.author {
|
||||||
border: 1px solid #633;
|
border: 3px solid #555;
|
||||||
}
|
}
|
||||||
.comment-content {
|
.comment-content {
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
@@ -404,11 +405,23 @@ and (min-width: 0px) //TODO
|
|||||||
cursor: default;
|
cursor: default;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
border: none;
|
border: none;
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: normal;
|
||||||
|
&[disabled], &[disabled]:hover {
|
||||||
|
box-shadow: 0 0 5px #ddd inset;
|
||||||
|
color: #ddd;
|
||||||
|
}
|
||||||
&.blue {
|
&.blue {
|
||||||
background: #4096ee;
|
background: #4096ee;
|
||||||
|
&[disabled] {
|
||||||
|
background: #96C1EE;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
&.red {
|
&.red {
|
||||||
background: #ee4040;
|
background: #ee4040;
|
||||||
|
&[disabled] {
|
||||||
|
background: #EE8383;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
&.right {
|
&.right {
|
||||||
float: right;
|
float: right;
|
||||||
|
|||||||
@@ -11,6 +11,7 @@
|
|||||||
<%= Sanitize.clean(GitHub::Markdown.render_gfm(@post.content), Sanitize::Config::RELAXED).html_safe %>
|
<%= Sanitize.clean(GitHub::Markdown.render_gfm(@post.content), Sanitize::Config::RELAXED).html_safe %>
|
||||||
</div>
|
</div>
|
||||||
<div id="comments">
|
<div id="comments">
|
||||||
|
<h3><%= "#{pluralize(@post.comments.length, 'comment')}." %></h3>
|
||||||
<% @post.comments.each do |c| %>
|
<% @post.comments.each do |c| %>
|
||||||
<%= render "comments/comment", :c => c %>
|
<%= render "comments/comment", :c => c %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
<% def can_edit?; (@user.is?(current_user) && confirmed?) || (mod? && current_user.role >= @user.role); end %>
|
||||||
<%= link_to (@user.is?(current_user) ? "Your profile" : @user.name), current_user %> → Edit
|
<%= link_to (@user.is?(current_user) ? "Your profile" : @user.name), current_user %> → Edit
|
||||||
<h1>Edit profile</h1>
|
<h1>Edit profile</h1>
|
||||||
|
|
||||||
@@ -11,7 +12,7 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<td>Display name</td>
|
<td>Display name</td>
|
||||||
<td>
|
<td>
|
||||||
<%= f.input :name, :label => false, disabled: !((@user.is?(current_user) && confirmed?) || (mod? && current_user.role >= @user.role)) %>
|
<%= f.input :name, :label => false, disabled: !can_edit? %>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<td>In-game name</td>
|
<td>In-game name</td>
|
||||||
@@ -35,7 +36,7 @@
|
|||||||
Skype username
|
Skype username
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<%= f.input :skype, label: false, placeholder: "Skype username", disabled: !((@user.is?(current_user) && confirmed?) || (mod? && current_user.role >= @user.role)) %>
|
<%= f.input :skype, label: false, placeholder: "Skype username", disabled: !can_edit? %>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
@@ -43,29 +44,29 @@
|
|||||||
Show Skype to
|
Show Skype to
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<%= f.input :skype_public, label: false, as: :select, collection: [["Staff only", false], ["All users", true]], include_blank: false, input_html: { disabled: !((@user.is?(current_user) && confirmed?) || (mod? && current_user.role >= @user.role)) } %>
|
<%= f.input :skype_public, label: false, as: :select, collection: [["Staff only", false], ["All users", true]], include_blank: false, input_html: { disabled: !can_edit? } %>
|
||||||
</td>
|
</td>
|
||||||
<tr>
|
<tr>
|
||||||
<td>YouTube username</td>
|
<td>YouTube username</td>
|
||||||
<td>
|
<td>
|
||||||
<%= f.input :youtube, :label => false, placeholder: "YouTube username", disabled: !((@user.is?(current_user) && confirmed?) || (mod? && current_user.role >= @user.role)) %>
|
<%= f.input :youtube, :label => false, placeholder: "YouTube username", disabled: !can_edit? %>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>Twitter username</td>
|
<td>Twitter username</td>
|
||||||
<td>
|
<td>
|
||||||
<%= f.input :twitter, :label => false, placeholder: "Twitter username", disabled: !(confirmed? || (mod? && current_user.role >= @user.role)) %>
|
<%= f.input :twitter, :label => false, placeholder: "Twitter username", disabled: !(@user.is?(current_user) && confirmed? || (mod? && current_user.role >= @user.role)) %>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>About you</td>
|
<td>About you</td>
|
||||||
<td>
|
<td>
|
||||||
<%= f.input :about, :label => false, :input_html => {:class => "vertical"}, placeholder: "Tell us something about you...", disabled: !((@user.is?(current_user) && confirmed?) || (mod? && current_user.role >= @user.role)) %>
|
<%= f.input :about, :label => false, :input_html => {:class => "vertical"}, placeholder: "Tell us something about you...", disabled: !can_edit? %>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
<%= f.submit "Save profile", class: "btn blue", disabled: @user.unconfirmed? %>
|
<%= f.submit "Save profile", class: "btn blue", disabled: (@user.unconfirmed? && @user.is?(current_user)) %>
|
||||||
<% if @user.unconfirmed? %>
|
<% if @user.unconfirmed? %>
|
||||||
<% if @user.is?(current_user) %>
|
<% if @user.is?(current_user) %>
|
||||||
<span class='red-alert'>Please confirm your email adress first!</span>
|
<span class='red-alert'>Please confirm your email adress first!</span>
|
||||||
|
|||||||
Reference in New Issue
Block a user