]> git.mxchange.org Git - friendica.git/commitdiff
some more work on private messages mail_display.tpl & mail_conv.tpl
authorrabuzarus <>
Thu, 12 May 2016 00:49:55 +0000 (02:49 +0200)
committerrabuzarus <>
Thu, 12 May 2016 00:49:55 +0000 (02:49 +0200)
css/style.css
templates/mail_conv.tpl [new file with mode: 0644]
templates/mail_display.tpl [new file with mode: 0644]
templates/mail_list.tpl [new file with mode: 0644]
templates/msg-header.tpl
templates/prv_message.tpl

index 834e7505cb6264246b994d71f9be2348dc78a56b..9fa182ded47066a621fa54f2fe8e1974042c87ec 100644 (file)
@@ -1701,6 +1701,42 @@ ul.viewcontact_wrapper > li {
 }
 
 /* private mail */
+.mail-thread {
+    max-height: calc(100vh - 200px);
+}
+#mail-conversation {
+    overflow-y: auto;
+    max-height: calc(100vh - 400px);
+    max-height: auto;
+    /*height: 500px;*/
+    margin-bottom: 0px;
+}
+#mail-conversation.can-reply {
+    border-bottom-left-radius: 0px;
+    border-bottom-right-radius: 0px;
+}
+.mail-conv-wrapper .media .contact-photo-wrapper {
+    height: 48px;
+    width: 48px;
+}
+.mail-thread #prvmail-to-label,
+.mail-thread #prvmail-subject-label {
+    display: none;
+}
+.mail-thread #prvmail-message-label > label {
+    display:none;
+}
+.mail-thread #prvmail-message-label textarea {
+    border-top: none;
+    margin-top: -10px;
+    border-top-left-radius: 0px;
+    border-top-right-radius: 0px;
+    max-height: 120px;
+}
+.mail-conv-wrapper {
+    padding: 15px;
+    border-bottom: 1px solid rgba(238, 238, 238, 0.95)
+}
 #prvmail-end {
     clear:both;
 }
diff --git a/templates/mail_conv.tpl b/templates/mail_conv.tpl
new file mode 100644 (file)
index 0000000..dd09124
--- /dev/null
@@ -0,0 +1,21 @@
+<div id="mail_conv-{{$mail.id}}" class="mail-conv-wrapper message-{{$mail.id}}">
+       <div class="media">
+               <div class="pull-left contact-photo-wrapper">
+                       <a href="{{$mail.from_url}}">
+                               <img class="media-object" src="{{$mail.from_photo}}" alt="{{$mail.from_name}}" />
+                       </a>
+               </div>
+               <div class="media-body">
+                       <div class="text-muted time mail-ago pull-right" title="{{$mail.date}}" data-toggle="tooltip">{{$mail.date}}</div>
+                       <div class="mail-conv-delete-end"></div>
+                       <h4 class="media-heading"><a href="{{$mail.from_url}}">{{$mail.from_name}}</a></h4>
+
+                       <div class="mail-body">
+                               {{$mail.body}}
+                       </div>
+                       {{*<a href="message/dropconv/{{$mail.id}}" onclick="return confirmDelete();" title="{{$delete}}" class="close pull-right" onmouseover="imgbright(this);" onmouseout="imgdull(this);" >&times;</a> *}}
+               </div>
+       </div>
+       <div class="mail-conv-wrapper-end"></div>
+</div>
+
diff --git a/templates/mail_display.tpl b/templates/mail_display.tpl
new file mode 100644 (file)
index 0000000..fc8817d
--- /dev/null
@@ -0,0 +1,19 @@
+
+<div id="mail-thread-{{$thread_id}}" class="mail-thread">
+       {{$brauchenwas}}
+       <h4 class="headding">{{$thread_subject}}</h3>
+
+       <div id="mail-conversation" class="panel panel-default {{if $canreply }}can-reply{{/if}}">
+       {{foreach $mails as $mail}}
+               {{include file="mail_conv.tpl"}}
+       {{/foreach}}
+       </div>
+
+       <div id="mail-reply">
+       {{if $canreply}}
+               {{include file="prv_message.tpl"}}
+       {{else}}
+               {{$unknown_text}}
+       {{/if}}
+       </div>
+</div>
diff --git a/templates/mail_list.tpl b/templates/mail_list.tpl
new file mode 100644 (file)
index 0000000..18a2acc
--- /dev/null
@@ -0,0 +1,30 @@
+<div class="mail-list-outside-wrapper">
+       
+
+               
+       <div class="media">
+               <div class="media-left">
+                       <a href="{{$from_url}}">
+                               <img class="media-object" src="{{$from_photo}}" alt="{{$from_name}}" style="min-width:80px; min-height:80px; width:80px; height:80px; max-width:80px; max-height:80px;" />
+                       </a>
+               </div>
+               <div class="media-body">
+                       <div class="text-muted time ago pull-right" title="{{$date}}">{{$ago}}</div>
+                       
+                       <h5 class="media-heading">{{$from_name}}</h5>
+                       <a href="message/{{$id}}">
+                               <h4>{{$subject}}</h4>
+                       </a>
+                       <a href="message/dropconv/{{$id}}" onclick="return confirmDelete();"  title="{{$delete}}" class="close pull-right" onmouseover="imgbright(this);" onmouseout="imgdull(this);" >&times;</a>
+                       <p class="text-muted">{{$count}}</p>
+               </div>
+
+       </div>
+
+
+       
+</div>
+<div class="mail-list-delete-end"></div>
+
+<div class="mail-list-outside-wrapper-end"></div>
+
index 304b2ec17b6f4f1eebf9eb02b7815e3060f89821..6645a4a74f10725c8b9959ea17e4a305edc26987 100644 (file)
@@ -55,6 +55,11 @@ else
                $("#comment-edit-text-input").bbco_autocomplete('bbcode');
                {{/if}}
 
+               //var objDiv = document.getElementById("mail-conversation");
+               //objDiv.scrollTop = objDiv.scrollHeight;
+               $('#mail-conversation').perfectScrollbar();
+               $('#mail-conversation').scrollTop($('#mail-conversation')[0].scrollHeight);
+
 
        });
 </script>
index 82031291bd2fa68cbba64006b60e4d6c1a4bd0b5..23f9dab2cad95dfd11939ed8882234c8edee3f66 100644 (file)
@@ -31,7 +31,7 @@
                <textarea rows="8" cols="72" class="prvmail-text form-control" id="comment-edit-text-input" name="body" tabindex="12">{{$text}}</textarea>
        </div>
 
-       <ul id="prvmail-text-edit-bb" class="comment-edit-bb comment-icon-list nav nav-pills pull-left">
+       <ul id="prvmail-text-edit-bb" class="comment-edit-bb comment-icon-list nav nav-pills hidden-xs pull-left">
                                <li>
                                        <a class="icon" style="cursor: pointer;" title="{{$edimg|escape:'html'}}" data-role="insert-formatting" data-comment=" " data-bbcode="img" data-id="input">
                                                <i class="fa fa-picture-o"></i>