webogram-i2p/app/partials/desktop/message_attach_webpage.html

60 lines
3.2 KiB
HTML
Raw Normal View History

2016-04-13 21:04:09 +00:00
<div ng-show="media.webpage._ == 'webPage'" class="im_message_webpage_wrap clearfix" ng-switch="media.webpage.type">
2015-04-10 14:00:39 +00:00
<div ng-switch-when="photo" class="im_message_webpage_photo">
<div class="im_message_webpage_title">
<a href="{{media.webpage.url}}" target="_blank" rel="noopener noreferrer" ng-bind-html="media.webpage.rTitle"></a>
2015-04-10 14:00:39 +00:00
</div>
2016-04-13 21:04:09 +00:00
<div ng-if="media.webpage.description.length" class="im_message_webpage_description" ng-bind-html="media.webpage.rDescription"></div>
<a class="im_message_photo_thumb" ng-click="openPhoto(media.webpage.photo.id, {w: media.webpage.id, m: messageId})" ng-style="::{width: media.webpage.photo.thumb.width + 'px'}" ng-mouseover="preloadPhoto(media.webpage.photo.id)">
2015-04-02 16:55:28 +00:00
<img
2015-04-10 14:00:39 +00:00
class="im_message_photo_thumb"
2015-04-02 16:55:28 +00:00
my-load-thumb
2016-04-13 21:04:09 +00:00
thumb="media.webpage.photo.thumb"
alt="[{{::'conversation_media_photo' | i18n}}]"
2015-04-02 16:55:28 +00:00
/>
2015-04-10 14:00:39 +00:00
</a>
</div>
<div ng-switch-when="video" class="im_message_webpage_video">
2016-04-13 21:04:09 +00:00
<div class="im_message_webpage_site" ng-bind="media.webpage.site_name || media.webpage.display_url"></div>
2015-04-10 14:00:39 +00:00
<div class="im_message_webpage_title">
<a ng-click="openEmbed($event)" href="{{media.webpage.url}}" target="_blank" rel="noopener noreferrer" ng-bind-html="media.webpage.rTitle"></a>
2015-04-02 16:55:28 +00:00
</div>
2016-04-13 21:04:09 +00:00
<div ng-if="media.webpage.description.length" class="im_message_webpage_description" ng-bind-html="media.webpage.rDescription"></div>
<a class="im_message_video_thumb" ng-click="openEmbed($event)" ng-href="{{media.webpage.url}}" target="_blank" rel="noopener noreferrer" ng-style="::{width: video.thumb.width + 'px'}">
2016-04-13 21:04:09 +00:00
<span ng-if="media.webpage.duration > 0" class="im_message_video_duration nocopy" data-content="{{::media.webpage.duration | duration}}"></span>
2015-04-10 14:00:39 +00:00
<i class="icon icon-videoplay"></i>
<img
class="im_message_video_thumb"
my-load-thumb
2016-04-13 21:04:09 +00:00
thumb="media.webpage.photo.thumb"
alt="[{{::'conversation_media_video' | i18n}}]"
2015-04-10 14:00:39 +00:00
/>
</a>
</div>
2015-04-02 16:55:28 +00:00
2015-12-10 21:11:22 +00:00
<div ng-switch-when="document" class="im_message_webpage_document">
<div my-message-document="media.webpage" message-id="messageId"></div>
2015-12-10 21:11:22 +00:00
</div>
<div ng-switch-when="gif" class="im_message_webpage_gif">
2016-02-05 18:35:11 +00:00
<div class="im_message_webpage_title">
<a href="{{media.webpage.url}}" target="_blank" rel="noopener noreferrer" ng-bind-html="media.webpage.rTitle"></a>
2016-02-05 18:35:11 +00:00
</div>
<div my-message-document="media.webpage" message-id="messageId"></div>
2015-12-10 21:11:22 +00:00
</div>
2015-04-10 14:00:39 +00:00
<div ng-switch-default class="im_message_webpage_article">
<a ng-if="media.webpage.photo" href="{{media.webpage.url}}" target="_blank" rel="noopener noreferrer" class="im_message_webpage_article_photo pull-right">
2015-04-10 14:00:39 +00:00
<img
class="im_message_article_thumb"
my-load-thumb
2016-04-13 21:04:09 +00:00
thumb="media.webpage.photo.thumb"
2015-04-10 14:00:39 +00:00
/>
2015-04-10 16:00:43 +00:00
</a>
<div ng-if="media.webpage.site_name" class="im_message_webpage_site" ng-bind="media.webpage.site_name"></div>
2015-04-10 14:00:39 +00:00
<div class="im_message_webpage_title">
2016-04-13 21:04:09 +00:00
<a ng-click="openEmbed($event)" href="{{media.webpage.url}}" target="_blank" ng-bind-html="media.webpage.rTitle"></a>
2015-04-02 16:55:28 +00:00
</div>
2016-04-13 21:04:09 +00:00
<div ng-if="media.webpage.description.length" class="im_message_webpage_description" ng-bind-html="media.webpage.rDescription"></div>
2015-04-02 16:55:28 +00:00
</div>
2015-04-10 14:00:39 +00:00
</div>