Adding functional IVANS widget with dialog popup view of summary and pdfs

This commit is contained in:
2026-08-05 18:58:47 +00:00
parent 14a4af623d
commit 0861ca2b94
2 changed files with 16 additions and 14 deletions
+16 -13
View File
@@ -203,19 +203,22 @@ function SummaryDialog({ open, onOpenChange, item }) {
<br /> <br />
{item?.files?.map((file, index) => { {item?.files?.map((file, index) => {
return ( return (
<object data={`${file?.url}#view=FitH&toolbar=1`} <>
type="application/pdf" <object data={`${file?.url}#view=FitH&toolbar=1`}
style={{ width: '100%', height: '100%', display: 'block' }} type="application/pdf"
> style={{ width: '100%', height: '100%', display: 'block' }}
<Flex w="100%" h="100%" color="gray.400" p={4}> >
<Text mb={2} color="fg.muted"> <Flex w="100%" h="100%" color="gray.400" p={4}>
Your browser cannot display this PDF directly. <Text mb={2} color="fg.muted">
</Text> Your browser cannot display this PDF directly.
<a href={file?.url} target="_blank"> </Text>
Download PDF <a href={file?.url} target="_blank">
</a> Download PDF
</Flex> </a>
</object> </Flex>
</object>
<br />
</>
)})} )})}
</Dialog.Body> </Dialog.Body>
-1
View File
@@ -55,7 +55,6 @@ export const WIDGET_REGISTRY = {
medium: { w: 3, h: 9 }, medium: { w: 3, h: 9 },
large: { w: 3, h: 12 }, large: { w: 3, h: 12 },
gargantuan: { w: 6, h: 12 }, gargantuan: { w: 6, h: 12 },
} }
}, },