mirror of
https://github.com/OCA/knowledge.git
synced 2025-12-27 15:17:44 -06:00
72 lines
3.4 KiB
XML
72 lines
3.4 KiB
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<templates>
|
|
<t
|
|
t-name="Attachment"
|
|
t-inherit="mail.AttachmentCard"
|
|
t-inherit-mode="extension"
|
|
owl="1"
|
|
>
|
|
<xpath expr="//div[hasclass('o_AttachmentCard_aside')]" position="before">
|
|
<div
|
|
class="o_AttachmentCard_aside position-relative overflow-hidden"
|
|
t-att-class="{ 'o-has-multiple-action d-flex flex-column': !attachmentCard.attachmentList.composerView and attachmentCard.attachment.isEditable }"
|
|
>
|
|
<div
|
|
t-if="attachmentCard.attachment.downloadUrl"
|
|
class="o_AttachmentCard_asideItem d-flex justify-content-center align-items-center ml4 o_attachment_preview"
|
|
t-att-data-id="attachmentCard.attachment.id"
|
|
t-att-data-url="attachmentCard.attachment.defaultSource"
|
|
t-on-click="attachmentCard._onPreviewAttachment"
|
|
t-att-data-original-title="attachmentCard.attachment.name"
|
|
t-attf-title="Preview {{attachmentCard.attachment.displayName}} in side panel"
|
|
tabindex="0"
|
|
role="menuitem"
|
|
aria-label="Preview"
|
|
>
|
|
<i class="fa fa-search" />
|
|
</div>
|
|
<div
|
|
t-if="attachmentCard.attachment.downloadUrl"
|
|
class="o_AttachmentCard_asideItem d-flex justify-content-center align-items-center ml4 o_attachment_preview o_attachment_preview_new_tab"
|
|
data-target="new"
|
|
t-att-data-id="attachmentCard.attachment.id"
|
|
t-att-data-url="attachmentCard.attachment.defaultSource"
|
|
t-on-click="attachmentCard._onPreviewAttachment"
|
|
t-att-data-original-title="attachmentCard.attachment.name"
|
|
t-attf-title="Open preview {{attachmentCard.attachment.name}} in a new tab"
|
|
tabindex="0"
|
|
role="menuitem"
|
|
aria-label="Open in new page"
|
|
>
|
|
<i class="fa fa-external-link" />
|
|
</div>
|
|
</div>
|
|
</xpath>
|
|
</t>
|
|
|
|
<t t-name="attachment_preview.AttachmentPreviewWidget">
|
|
<div class="attachment_preview_widget d-none">
|
|
<div class="attachment_preview_buttons">
|
|
<div class="button-group pull-left">
|
|
<button
|
|
class="btn btn-sm btn-secondary attachment_preview_previous"
|
|
><i class="fa fa-chevron-left" /></button>
|
|
<button
|
|
class="btn btn-sm btn-secondary disabled attachment_preview_current"
|
|
>1 / 5</button>
|
|
<button class="btn btn-sm btn-secondary attachment_preview_next"><i
|
|
class="fa fa-chevron-right"
|
|
/></button>
|
|
</div>
|
|
<button
|
|
class="btn btn-sm btn-secondary pull-left ml8 attachment_preview_popout"
|
|
><i class="fa fa-external-link" /></button>
|
|
<button
|
|
class="btn btn-sm btn-secondary pull-right attachment_preview_close"
|
|
><i class="fa fa-times" /></button>
|
|
</div>
|
|
<iframe class="attachment_preview_iframe" />
|
|
</div>
|
|
</t>
|
|
</templates>
|