Permalink
Browse files

Style changes

  • Loading branch information...
1 parent 554f2fb commit 61fc870c810cdc38d55c93cfe1a62391cc77fdf7 @holywarez holywarez committed Jul 8, 2009
@@ -34,7 +34,7 @@
<div style="clear:both;"></div>
</div>
-<%#= render :partial => 'partials/footer' %>
+<%= render :partial => 'partials/footer' %>
</body>
</html>
@@ -1,25 +1,7 @@
<div class="footer">
- <div style="padding-left:30px; padding-right:30px;">
- <table cellpadding="0" cellspacing="0" border="0" width="100%">
- <tr>
- <td valign="top" align="left" width="30%">
- <div>
- © 2008—2009 «<%= link_to "Главная", root_url %>»
- </div>
-
-
- </td>
- <td valign="top" align="center" width="30%">
- </td>
- <td valign="top" align="right" width="30%">
-
-
- <div>
- <!--<a href="http://www.gionet.ru/"><%#= image_tag "common/footer-logo.png" %></a>-->
- </div>
- </td>
- </tr>
- </table>
-
+ <div style="text-align: right;">
+ <a href="http://github.com/strikeroff/blogflow/tree/master">
+ <img id="code" src="http://livc.ru/storage/livecodes/0000/4267/file4267.gif" alt="Project live code">
+ </a>
</div>
</div>
@@ -1,44 +1,13 @@
-<div class="header" style="background-image:url(/images/common/gradient.png);background-repeat:repeat;height:94px;">
+<div class="header">
<div class="login-state">
- <% if user_logged_in? %>
- <%= image_tag "login/ico-user.png",:alt=>""%>
- <%= current_user.login %>
- <%= image_tag "login/log.png",:alt=>""%>
- <%= link_to "Выйти", user_session_url, :class=>"logout", :method=>:delete %>
- <% else %>
- <%#= image_tag "top_menu/login.gif" %>
+ <% if user_logged_in? %>
+ <%= image_tag "login/ico-user.png",:alt=>""%>
+ <%= current_user.login %>
<%= image_tag "login/log.png",:alt=>""%>
- <%= link_to "Войти", new_user_session_url, :id=>"login-link", :class=>"logout" %>
- <% end %>
- </div>
- <table cellpadding="0" cellspacing="0" border="0" width="100%">
-
- <tr>
- <td valign="middle" align="left" width="33%">
-
-
- <table cellpadding="0" cellspacing="0" border="0">
- <tr>
-
- </tr>
- </table>
-
- </td>
- <td valign="middle" align="center" width="33%">
- <table cellpadding="0" cellspacing="0" border="0">
- <tr>
-
- </tr>
- </table>
- </td>
- <td valign="middle" align="right">
-
- <table cellpadding="0" cellspacing="0" border="0">
- <tr>
-
- </tr>
- </table>
- </td>
- </tr>
- </table>
+ <%= link_to "Выйти", user_session_url, :class=>"logout", :method=>:delete %>
+ <% else %>
+ <%= image_tag "login/log.png",:alt=>""%>
+ <%= link_to "Войти", new_user_session_url, :id=>"login-link", :class=>"logout" %>
+ <% end %>
+ </div>
</div>
@@ -3,50 +3,35 @@
<div class="post-show ">
<%= flash_messages %>
+
+ <div class="post-attribute author">
+ <%="Автор: #{@object.author.login }" %>
+ </div>
+
<div class="post-attribute post-title">
<%= @object.title %>
</div>
- <div class="post-attribute">
- <%="Автор: #{@object.author.login }" %>
+
+ <div class="post-attribute attached-files">
+ <%= render :partial=>"assets/assets_list", :locals=>{:assets=>@object.assets} %>
</div>
- <div class="post-attribute">
+ <div class="post-attribute body">
<%= @object.body %>
</div>
- <div class="post-attribute">
+ <div class="post-attribute tags">
<% tag_list = @object.tag_list %>
<%= "Теги: "unless tag_list.blank? %>
<% tag_list.each do |tag| %>
<%= link_to tag, { :action => :tag, :id => tag } %>
<% end %>
</div>
- <div class="post-attribute">
-
- <%= render :partial=>"assets/assets_list", :locals=>{:assets=>@object.assets} %>
- </div>
-
- <div class="post-attribute">
- <%= link_to "Редактировать", edit_post_url(@object) %>
- </div>
- <div class="post-attribute">
- <%= link_to "Удалить", post_url(@object), :method => :delete, :confirm => "Вы действительно хотите удалить пост?" %>
- </div>
-
- <div class="add-comment">
- <% form_for :comment, :url=>post_comments_url(:post_id=> @object.id) do |f| %>
- <!--<div class="post-attribute">-->
- <!--<%#= f.text_field :title %>-->
- <!--</div>-->
- <div class="comment-body">
- <%= f.text_area :body %>
- <div class="submit">
- <%= submit_tag "Комментировать" %>
- </div>
- </div>
-
- <% end %>
+ <div class="post-tools">
+ Вы можете
+ <%= link_to "отредактировать", edit_post_url(@object) %> это сообщение или же вообще
+ <%= link_to "удалить", post_url(@object), :method => :delete, :confirm => "Вы действительно хотите удалить пост?" %> его.
</div>
<div class="comment-list">
@@ -58,6 +43,32 @@
<% end %>
<% end %>
</div>
+ <div class="comment-tools">
+ Вы хотите принять участие в обсуждении этого сообщения, но не можете? <a href="#add-comment">Можете</a>!
+ </div>
+ <div class="add-comment">
+ <a name="add-comment"></a>
+ <% form_for :comment, :url=>post_comments_url(:post_id=> @object.id) do |f| %>
+ <div class="comment-body">
+ <%= f.text_area :body %>
+ <div class="submit">
+ <%= submit_tag "Комментировать" %> или <a href="#add-comment">нет</a> — вот в чем вопрос!
+ </div>
+ </div>
+ <% end %>
+ </div>
+
+ <script language="javascript">
+ function toggle_comments() {
+ $(".comment-tools").toggle();
+ $(".add-comment").toggle();
+ }
+ $(function(){
+ $(".comment-tools a").click(toggle_comments);
+ $(".add-comment a").click(toggle_comments);
+ });
+ </script>
+
</div>
@@ -1,16 +1,11 @@
-.comment-list {
- padding-top: 30px;
- padding-left: 60px;
-}
-
.comment {
width: 650px;
border: 1px groove black;
margin-bottom:20px;
}
.comment-head {
- background-color: #EFEFEF;
+ background-color: #FFF0F0;
height: 30px;
}
@@ -27,6 +22,7 @@
.add-comment{
width:500px;
+ display: none;
}
.submit{
float:right;
@@ -1,8 +1,5 @@
#content {
- padding-bottom: 86px; /*padding-top: 60px;*/
-/*padding-left:30px;*/
-/*padding-right:30px;*/
-/*border: 1px solid darkolivegreen; */
+ padding-bottom: 220px;
}
.inside {
@@ -16,10 +13,22 @@
margin-top: 5px;
}
+.header {
+ text-align: right;
+ height: 3.5em;
+ border-bottom: 1px solid gray;
+ background-color: #FFF0F0;
+}
+
.login-state {
- float: right;
+ text-align: right;
padding-right: 30px;
padding-top: 10px;
- color:white;
+}
+
+.login-state img {
+ position: relative;
+ top: 3px;
+ margin-left: 20px;
}
@@ -1,7 +1,7 @@
.post-show {
/*padding-top: 30px;*/
padding-left: 50px;
- padding-right: 50px;
+ padding-right: 15em;
}
#content{
padding-top: 30px;
@@ -12,8 +12,49 @@
}
.post-attribute {
+/*
padding-top: 20px;
padding-left: 20px;
+*/
+}
+
+.post-attribute.author {
+ color: gray;
+ float: right;
+ position: relative;
+ top: 1.2em;
+}
+
+.post-attribute.attached-files {
+ width: 20em;
+ clear: both;
+ float: right;
+ text-align: right;
+ padding: 0em 0.5em;
+ margin: 2em 0em 2em 2em;
+ background-color: #F0F0F0;
+}
+
+.post-attribute.attached-files p {
+ margin-bottom: 0px;
+ font-weight: bold;
+}
+
+.post-attribute.body {
+ font-size: 130%;
+ padding: 2em 0;
+ clear: left;
+}
+
+.post-attribute.tags {
+ clear: right;
+ padding-top: 1em;
+}
+
+.post-tools {
+ color: #666;
+ font-style: italic;
+
}
.post-attribute input {
@@ -25,7 +66,10 @@
}
.post-title {
- font-size: 18px;
+ font-size: 250%;
+ float: left;
+ font-family: "Times New Roman";
+ border-bottom: 1px dotted gray;
}
.post-list tr td {
@@ -67,7 +111,10 @@ padding-bottom:2px;
.assets_list{
list-style-image: none;
list-style-position: inside;
- list-style-type: decimal;
+ /*list-style-type: decimal; */
+ list-style-type: none;
+ padding-left: 0px;
+ margin-top: 0px;
}
.post-upload-form{
padding-top: 20px;
@@ -84,10 +131,15 @@ padding-bottom:2px;
#upload-form{
padding-bottom:20px;
}
-.comment-body{
- padding-top:20px;
- padding-left:20px;
+
+.comment-list {
+ margin-top: 2em;
+}
+
+.comment-list p {
+ font-weight: bold;
}
+
.comment-body textarea{
width: 500px;
height: 150px;
@@ -135,11 +135,11 @@ a{
position: absolute;
bottom: 0;
- height: 85px;
+ height: 190px;
width: 100%;
border-top: 1px solid #e0dee1;
- padding-top: 20px;
+ padding-top: 10px;
/*border: 1px solid lightsalmon;*/
}

0 comments on commit 61fc870

Please sign in to comment.