mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-20 23:32:14 +00:00
fix: attachment actions icon and image size (#6710)
Signed-off-by: Alexander Onnikov <Alexander.Onnikov@xored.com>
This commit is contained in:
parent
822731c23c
commit
b24027b2ea
@ -23,7 +23,7 @@
|
|||||||
getPreviewAlignment,
|
getPreviewAlignment,
|
||||||
previewTypes
|
previewTypes
|
||||||
} from '@hcengineering/presentation'
|
} from '@hcengineering/presentation'
|
||||||
import { IconMoreH, IconOpen, Menu, Action as UIAction, closeTooltip, showPopup, tooltip } from '@hcengineering/ui'
|
import { IconMoreH, Menu, Action as UIAction, closeTooltip, showPopup, tooltip } from '@hcengineering/ui'
|
||||||
import view, { Action } from '@hcengineering/view'
|
import view, { Action } from '@hcengineering/view'
|
||||||
|
|
||||||
import AttachmentAction from './AttachmentAction.svelte'
|
import AttachmentAction from './AttachmentAction.svelte'
|
||||||
@ -84,7 +84,7 @@
|
|||||||
|
|
||||||
const openAction: UIAction = {
|
const openAction: UIAction = {
|
||||||
label: view.string.Open,
|
label: view.string.Open,
|
||||||
icon: IconOpen,
|
icon: view.icon.Open,
|
||||||
action: async (props: any, evt: Event) => {
|
action: async (props: any, evt: Event) => {
|
||||||
showPreview(evt as MouseEvent)
|
showPreview(evt as MouseEvent)
|
||||||
}
|
}
|
||||||
@ -126,7 +126,7 @@
|
|||||||
{#if canPreview}
|
{#if canPreview}
|
||||||
<AttachmentAction
|
<AttachmentAction
|
||||||
label={view.string.Open}
|
label={view.string.Open}
|
||||||
icon={IconOpen}
|
icon={view.icon.Open}
|
||||||
size="small"
|
size="small"
|
||||||
dataId="open-in-sidebar"
|
dataId="open-in-sidebar"
|
||||||
action={showPreview}
|
action={showPreview}
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
if (listProvider !== undefined) listProvider.updateFocus(value)
|
if (listProvider !== undefined) listProvider.updateFocus(value)
|
||||||
const popupInfo = showPopup(
|
const popupInfo = showPopup(
|
||||||
FilePreviewPopup,
|
FilePreviewPopup,
|
||||||
{ file: value.file, name: value.name, contentType: value.type },
|
{ file: value.file, name: value.name, contentType: value.type, metadata: value.metadata },
|
||||||
value.type.startsWith('image/') ? 'centered' : 'float'
|
value.type.startsWith('image/') ? 'centered' : 'float'
|
||||||
)
|
)
|
||||||
dispatch('open', popupInfo.id)
|
dispatch('open', popupInfo.id)
|
||||||
|
@ -92,7 +92,7 @@
|
|||||||
if (item !== undefined) {
|
if (item !== undefined) {
|
||||||
showPopup(
|
showPopup(
|
||||||
FilePreviewPopup,
|
FilePreviewPopup,
|
||||||
{ file: item.file, name: item.name, contentType: item.type },
|
{ file: item.file, name: item.name, contentType: item.type, metadata: item.metadata },
|
||||||
item.type.startsWith('image/') ? 'centered' : 'float'
|
item.type.startsWith('image/') ? 'centered' : 'float'
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user