aboutsummaryrefslogtreecommitdiff
path: root/src/main/resources/templates/views/partial/message.html
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2021-03-31 00:44:49 +0300
committerGravatar Vitaly Takmazov2021-03-31 00:44:49 +0300
commit93fe99d9bfc9ae00f4164ea0ba32290722dff4dd (patch)
treef0637a6ad99ae7033e2fee4d100ed1fc63e64728 /src/main/resources/templates/views/partial/message.html
parentfbe50e415fbb3da5a7fa151338b00e6a94dc8d5d (diff)
Resource filtering is handled by Spring Boot Maven plugin
Diffstat (limited to 'src/main/resources/templates/views/partial/message.html')
-rw-r--r--src/main/resources/templates/views/partial/message.html87
1 files changed, 87 insertions, 0 deletions
diff --git a/src/main/resources/templates/views/partial/message.html b/src/main/resources/templates/views/partial/message.html
new file mode 100644
index 00000000..47dfb6c5
--- /dev/null
+++ b/src/main/resources/templates/views/partial/message.html
@@ -0,0 +1,87 @@
+<article class="msg-cont" data-mid="{{ msg.mid }}">
+ <header class="h">
+ <span>
+ <a href="/{{ msg.user.name }}/"><span>{{ msg.user.name }}</span></a>
+ </span>
+ <div class="msg-avatar"><a href="/{{ msg.user.name }}/">
+ <img src="{{ msg.user.avatar }}" alt="{{ msg.user.name }}"/></a>
+ </div>
+ <div class="msg-ts">
+ {% if msg.FriendsOnly %}
+ <i data-icon="ei-lock" data-size="s"></i> &middot;
+ {% endif %}
+ <a href="/{{ msg.user.name }}/{{ msg.mid }}">
+ <time datetime="{{ msg.created | timestamp | date('yyyy-MM-dd HH:mm:ss') }}Z"
+ title="{{ msg.created | timestamp | date('yyyy-MM-dd HH:mm:ss') }} GMT">
+ {{ msg.created | prettyTime }}
+ </time>
+ </a>
+ {% if msg.created != msg.updatedAt %}
+ &middot; Edited
+ {% endif %}
+ </div>
+ </header>
+ <div class="msg-txt">
+ <span class="msg-tags">
+ {{ tags(msg.user.name, msg.tags | tagsList) }}
+ </span>
+ {{ msg | formatMessage }}
+ </div>
+ {% if msg.AttachmentType is not empty %}
+ <p class="ir"><a href="//i.juick.com/p/{{ msg.mid }}.{{ msg.AttachmentType }}" data-fname="{{ msg.mid }}.{{ msg.AttachmentType }}">
+ <img src="//i.juick.com/photos-512/{{ msg.mid }}.{{ msg.AttachmentType }}" alt=""/></a>
+ </p>
+ {% endif %}
+ <nav class="l">
+ {% if visitor.uid == msg.user.uid %}
+ <a href="/{{ msg.mid }}" class="a-like msg-button">
+ <span class="msg-button-icon">
+ <i data-icon="ei-heart" data-size="s"></i>
+ {% if msg.likes > 0 %}&nbsp;{{ msg.likes }}
+ {% else %}
+ <span>&nbsp;{{ i18n("messages","message.recommend") }}</span>
+ {% endif %}
+ </span>
+ </a>
+ {% elseif visitor.uid > 0 %}
+ <a href="/post?body=!+%23{{ msg.mid }}" class="a-like msg-button">
+ <span class="msg-button-icon">
+ <i data-icon="ei-heart" data-size="s"></i>
+ {% if msg.likes > 0 %}&nbsp;{{ msg.likes }}
+ {% else %}
+ <span>&nbsp;{{ i18n("messages","message.recommend") }}</span>
+ {% endif %}
+ </span>
+ </a>
+ {% else %}
+ <a href="/login" class="a-login msg-button">
+ <span class="msg-button-icon">
+ <i data-icon="ei-heart" data-size="s"></i>
+ {% if msg.likes > 0 %}
+ {{ msg.likes }}
+ {% else %}
+ <span>&nbsp;{{ i18n("messages","message.recommend") }}</span>
+ {% endif %}
+ </span>
+
+ </a>
+ {% endif %}
+ {% if (not msg.ReadOnly) or (visitor.uid == msg.user.uid) %}
+ <a href="/{{ msg.mid }}" class="a-comment msg-button">
+ <span class="msg-button-icon">
+ <i data-icon="ei-comment" data-size="s"></i>
+ {% if msg.Replies > 0 %}&nbsp;
+ {% if msg.unread %}
+ <span class="badge">{{ msg.Replies }}</span>
+ {% else %}
+ {{ msg.Replies }}
+ {% endif %}
+ {% else %}
+ <span>&nbsp;{{ i18n("messages","message.comment") }}</span>
+ {% endif %}
+ </span>
+
+ </a>
+ {% endif %}
+ </nav>
+</article> \ No newline at end of file