Same penultimo fixed for blog_view as in stable-81x, but based on the slightly more...
authorthe_mgt <themgt@uncensored.citadel.org>
Thu, 19 Jul 2012 21:42:42 +0000 (23:42 +0200)
committerthe_mgt <themgt@uncensored.citadel.org>
Thu, 19 Jul 2012 21:42:42 +0000 (23:42 +0200)
this will move the "x comments | permalink" into the blog_post div, add a horizontal ruler, indent post.html and comment.html, move the blog_post_header under the blog_content (maybe we should rename it to footer if it we decide to keep it this way) and indents the comment.html, too.
Some text was added to both html file which should become translatable in the future.
And of course it is styled as in stable-81x now

webcit/blogview_renderer.c
webcit/static/styles/blog.css
webcit/static/styles/webcit.css
webcit/static/t/view_blog/comment.html
webcit/static/t/view_blog/post.html

index 3e05a377cb0b93c1d893bf69347f32c4e401f2c2..fa2c64752db2dd0d83ba3c4f217c147055788df0 100644 (file)
@@ -54,12 +54,12 @@ void blogpost_render(struct blogpost *bp, int with_comments)
 
        if (with_comments) {
                /* Show any existing comments, then offer the comment box */
-               wc_printf("<a name=\"comments\"></a>\n");
+               wc_printf("<a class=\"blog_show_comments_link\" name=\"comments\"></a>\n");
                wc_printf(_("%d comments"), bp->num_msgs - 1);
-               wc_printf(" | <a href=\"");
+               wc_printf(" | <a class=\"blog_permalink_link\" href=\"");
                tmplput_blog_permalink(NULL, NULL);
                wc_printf("\">%s</a>", _("permalink"));
-               wc_printf("<br>\n");
+               wc_printf("</div>\n");
                for (i=1; i<bp->num_msgs; ++i) {
                        read_message(WC->WBuf, HKEY("view_blog_comment"), bp->msgs[i], NULL, &Mime);
                }
@@ -68,14 +68,14 @@ void blogpost_render(struct blogpost *bp, int with_comments)
 
        else {
                /* Show only the number of comments */
-               wc_printf("<a href=\"readfwd?p=%d?go=", bp->top_level_id);
+               wc_printf("<a class=\"blog_show_comments_link\" href=\"readfwd?p=%d?go=", bp->top_level_id);
                urlescputs(ChrPtr(WC->CurRoom.name));
                wc_printf("#comments\">");
                wc_printf(_("%d comments"), bp->num_msgs - 1);
-               wc_printf("</a> | <a href=\"");
+               wc_printf("</a> | <a class=\"blog_permalink_link\" href=\"");
                tmplput_blog_permalink(NULL, NULL);
                wc_printf("\">%s</a>", _("permalink"));
-               wc_printf("<br><br><br>\n");
+               wc_printf("<hr>\n</div>\n");
        }
 }
 
index e0d85dd5c4ed0dc5150dc4e6e5e9921643f2e270..9242b55f6c55afa6927c5da05aa1c566dc10b833 100644 (file)
@@ -1,33 +1,69 @@
 .blog_post {
-       padding-top: 0.5em;
         margin: 0.5em;
         width: 38em;
-       border-top: 1px solid #5C646B;
 }
 
+.blog_post hr {
+       margin: 1em 0.25em;
+       padding: 0 0.25em;
+       border: 1px dotted #5C646B;
+}
 
-.blog_post_title a {
-       font-size: large;
-       color: #5C646B;
+.blog_post_title a:link, .blog_post_title a:visited, .blog_post_title a:active {
+       font-size: 150%;
+       font-weight: bold;
+       color: #000;
 }
+
+.blog_post_title a:hover {
+        color: #0E73E3;
+}
+
        
-.blog_post_header a, .blog_comment_header a { 
+.blog_post_header a:link, .blog_comment_header a:link { 
        font-style: italic;
        color: #000;
  }
 
-.blog_post_header, .blog_comment_header {
-       margin: 0.3em 0.5em;
+.blog_post_header {
+       margin: 0 1em; /* adjust with .blog_show_comments_link */
        font-size: smaller;
 }
 
-.blog_post_content {
+.blog_post_content, .blog_comment_content {
        font-family: serif;
-       font-size: small;
+       font-size: 90%;
+}
+
+a.blog_show_comments_link:link, a.blog_show_comments_link:active, a.blog_show_comments_link:visited {
+       margin-left: 1em;
+       color: #000;
+       font-size: smaller;
+}
+
+.blog_permalink_link {
+       font-size: smaller;
 }
 
 .blog_comment {
-        margin: 0.5em;
-        width: 30em;
+       margin: 0.5em;
+       padding: 0.5em 0.25em 0.25em;
+       width: 35em;
+       border-top: 1px dotted grey;
+       background-color: #EDEDE0;
+}
+
+.blog_comment_header {
+       font-size: smaller;
+}
+
+.blog_comment_date {float:right}
+
+.blog_comment_content {
+       margin: 0.25em;
+}
+                     
+.post_a_comment_title {
+        font-size: 120%;
 }
 
index cd723a6b76795d5727695b84e1de5d4df63c1244..9d90675582e913856673630bde1ea0fe8288f213 100644 (file)
@@ -15,7 +15,7 @@
 @import url("message.css");
 @import url("modal.css");
 @import url("service.css");
-@import url("blog.css")
+@import url("blog.css");
 
 @media print {
        input#toggler, .toolbar { display: none }
@@ -1167,53 +1167,6 @@ a.event_title:hover span.bttbottom, a.event_unread:hover span.bttbottom, a.event
        background: url(/static/webcit_icons/bubble.gif) no-repeat bottom;
 }
 
-
-/*---------- styles for the blog view -----------*/
-
-.blog_post {
-}
-
-.blog_post_title {
-       font-size: 150%;
-       font-weight: bold;
-}
-
-.blog_post_title a:link, .blog_post_title a:visited, .blog_post_title a:active {
-       color: #000000;
-}
-
-.blog_post_title a:hover {
-       color: #0000FF;
-}
-
-
-.blog_post_header {
-       font-size: 100%;
-       font-style: italic;
-}
-
-.blog_post_content {
-}
-
-.blog_comment {
-       border: 1px solid grey;
-       margin-top: 5px;
-       margin-bottom: 5px;
-       margin-left: 5%;
-       margin-right: 5%;
-       padding: 5px;
-}
-
-.blog_comment_header {
-       margin-bottom: 1em;
-       font-size: 100%;
-       font-style: italic;
-}
-
-.post_a_comment_title {
-       font-size: 120%;
-}
-
 /*---------- styles for the attachments form -----------*/
 
 #attachments_form {
@@ -1311,15 +1264,3 @@ a.event_title:hover span.bttbottom, a.event_unread:hover span.bttbottom, a.event
         background: url('../webcit_icons/openid-small.gif') no-repeat scroll 0pt 50%;
         padding-left: 18px;
 }
-
-.older_blog_posts, .newer_blog_posts {
-       font-size: 110%;
-}
-
-.older_blog_posts {
-       text-align: left;
-}
-
-.newer_blog_posts {
-       text-align: right;
-}
index 8c118f97777530ddd465c8903c81d0081cec5c63..08ad90aff7d3fedd99ce4cc5eb55321c386b89f4 100644 (file)
@@ -1,24 +1,28 @@
 <div class="blog_comment" id="blog_comment_<?MAIL:SUMM:N>">
-<div class="blog_comment_header">
-<span>
- <??("COND:MAIL:ANON",1)>
-   <?!("COND:MAIL:SUMM:RFCA", 2)><a href="do_template?temlpate=user_show?who=<?MAIL:SUMM:FROM("Q")>">"<?MAIL:SUMM:FROM("X")>" &lt;<?MAIL:SUMM:RFCA>&gt;</a><?!("X", 2)>
-   <??("COND:MAIL:SUMM:RFCA", 3)><a href="do_template?temlpate=user_show?who=<?MAIL:SUMM:FROM("Q")>"><?MAIL:SUMM:FROM("X")></a> 
-      <??("X", 3)><?!("COND:MAIL:SUMM:OTHERNODE",4)> @ <?MAIL:SUMM:H_NODE><??("X",4)>
- <??("X", 1)>
-</span>
- <span><?MAIL:SUMM:DATEFULL></span>
-<?!("COND:ROOM:EDITACCESS", 16)>
-   <a href="#" onclick="if (confirm('<?_("Delete this message?")>')) { DeleteBlogComment(<?MAIL:SUMM:N>); }"><span>[</span><?_("Delete")><span>]</span> </a> 
-<??("X", 16)>
-</div>
-<div class="blog_comment_content">
-<?MAIL:BODY>
-<?!("COND:MAIL:MIME:ATTACH:SUBMESSAGES", 10)>
-<?ITERATE("MAIL:MIME:ATTACH:SUBMESSAGES", ="view_message_inline_attach")>
-<?!("X", 10)>
-<?!("COND:MAIL:MIME:ATTACH:LINKS", 11)>
-<?ITERATE("MAIL:MIME:ATTACH:LINKS", ="view_message_list_attach")>
-<?!("X", 11)>
-</div>
+       <div class="blog_comment_header">
+               <span class="blog_commenter_name">
+               <??("COND:MAIL:ANON",1)>
+                       <?!("COND:MAIL:SUMM:RFCA", 2)>
+                               <a href="do_template?temlpate=user_show?who=<?MAIL:SUMM:FROM("Q")>">"<?MAIL:SUMM:FROM("X")>" &lt;<?MAIL:SUMM:RFCA>&gt;</a>
+                       <?!("X", 2)>
+                       <??("COND:MAIL:SUMM:RFCA", 3)>
+                               <a href="do_template?temlpate=user_show?who=<?MAIL:SUMM:FROM("Q")>"><?MAIL:SUMM:FROM("X")></a> 
+                       <??("X", 3)>
+                       <?!("COND:MAIL:SUMM:OTHERNODE",4)> @ <?MAIL:SUMM:H_NODE><??("X",4)>
+               <??("X", 1)>
+               &nbsp;says:&nbsp;</span>
+               <span class="blog_comment_date"><?MAIL:SUMM:DATEFULL></span>
+               <?!("COND:ROOM:EDITACCESS", 16)>
+                       <a href="#" onclick="if (confirm('<?_("Delete this message?")>')) { DeleteBlogComment(<?MAIL:SUMM:N>); }"><span>[</span><?_("Delete")><span>]</span> </a> 
+               <??("X", 16)>
+       </div>
+       <div class="blog_comment_content">
+               <?MAIL:BODY>
+               <?!("COND:MAIL:MIME:ATTACH:SUBMESSAGES", 10)>
+                       <?ITERATE("MAIL:MIME:ATTACH:SUBMESSAGES", ="view_message_inline_attach")>
+               <?!("X", 10)>
+               <?!("COND:MAIL:MIME:ATTACH:LINKS", 11)>
+                       <?ITERATE("MAIL:MIME:ATTACH:LINKS", ="view_message_list_attach")>
+               <?!("X", 11)>
+       </div>
 </div>
index 0dfee3de41602c9ff56174f4deca7b829c34562a..daab42cabf97cc88e9bf07cba9214ad4d177ad12 100755 (executable)
@@ -2,8 +2,19 @@
        <div class="blog_post_title">
                <?!("COND:MAIL:SUBJ", 7)><a href="<?BLOG:PERMALINK>"><?MAIL:SUMM:SUBJECT("X")></a><??("X", 7)>
        </div>
+       <div class="blog_post_content">
+               <div>   
+                       <?MAIL:BODY>
+                       <?!("COND:MAIL:MIME:ATTACH:SUBMESSAGES", 10)>
+                               <?ITERATE("MAIL:MIME:ATTACH:SUBMESSAGES", ="view_message_inline_attach")>
+                       <?!("X", 10)>
+                       <?!("COND:MAIL:MIME:ATTACH:LINKS", 11)>
+                               <?ITERATE("MAIL:MIME:ATTACH:LINKS", ="view_message_list_attach")>
+                       <?!("X", 11)>
+               </div>
+       </div>
        <div class="blog_post_header">
-               <span><??("COND:MAIL:ANON",1)>
+               <span>Posted by <??("COND:MAIL:ANON",1)>
                        <?!("COND:MAIL:SUMM:RFCA", 2)>
                        <a href="showuser?who=<?MAIL:SUMM:FROM("Q")>">
                                "<?MAIL:SUMM:FROM("X")>" &lt;<?MAIL:SUMM:RFCA>&gt;
                        <??("X", 3)>
                        <?!("COND:MAIL:SUMM:OTHERNODE",4)> @ <?MAIL:SUMM:H_NODE><??("X",4)>
                <??("X", 1)></span>
-               <span><?MAIL:SUMM:DATEFULL></span>
+               <span>on <?MAIL:SUMM:DATEFULL></span>
                <?!("COND:ROOM:EDITACCESS", 16)>
                        <a href="delete_msg?msgid=<?MAIL:SUMM:N>" onclick="return confirm('<?_("Delete this message?")>');">
                                <span>[</span><?_("Delete")><span>]</span>
                        </a> 
                <??("X", 16)>
        </div>
-       <div class="blog_post_content">
-               <div>
-                       <?MAIL:BODY>
-                       <?!("COND:MAIL:MIME:ATTACH:SUBMESSAGES", 10)>
-                               <?ITERATE("MAIL:MIME:ATTACH:SUBMESSAGES", ="view_message_inline_attach")>
-                       <?!("X", 10)>
-                       <?!("COND:MAIL:MIME:ATTACH:LINKS", 11)>
-                               <?ITERATE("MAIL:MIME:ATTACH:LINKS", ="view_message_list_attach")>
-                       <?!("X", 11)>
-               </div>
-       </div>
        <div id="comment_replyto" style="display:none"><?MAIL:SUMM:INREPLYTO("X")></div>
-</div>
+<!-- closing /div provided by blogview_render.c -->