@samitouri / QOSami-HFS / commits / 61326fea

fix: admin/plugins/search: preview images not visible in safari

Massimo Melina committed Sep 21, 2025 at 12:15 UTC 61326feab61e9c9a792c875281c6ea55f98c69e0
2 files changed +2 -3
admin/src/OnlinePlugins.ts
+1 -2
@@ -87,7 +87,6 @@ export default function OnlinePlugins() {
87 disabled: !row.preview,
88 onClick: () => newDialog({
89 title: id,
90 - dialogProps: { sx: { minHeight: '50vh', minWidth: '50vw' } }, // the image will use available space, so we must reserve it (while mobile is going full-screen)
90 Content: () => h(ShowImages, { imgs: wantArray(row.preview) })
91 })
92 }),
@@ -99,7 +98,7 @@ export default function OnlinePlugins() {
98 function ShowImages({ imgs }: { imgs: string[] }) {
99 const [cur, setCur] = useState(0)
100 return h(Flex, { vert: true, flex: 1 },
102 - h(Flex, { vert: true, center: true, height: 0, flex: 'auto' },
101 + h(Flex, { vert: true, center: true, height: 0, flex: 'auto', minHeight: '50vh', minWidth: '50vw' },
102 h('img', { src: imgs[cur], style: { margin: 'auto', /*center*/ maxWidth: '100%', maxHeight: '100%' /*limit*/ } }),
103 ),
104 imgs.length > 1 && h(Flex, { center: true },
admin/src/dialog.ts
+1 -1
@@ -37,7 +37,7 @@ dialogsDefaults.Container = function Container(d: DialogOptions) {
37 return h(Modal, { open: true, children: h(Center, {}, h(d.Content)) })
38 return h(MuiDialog, {
39 open: true,
40 - maxWidth: 'lg',
40 + maxWidth: false,
41 fullScreen: mobile,
42 ...rest,
43 ...root,