add open pdf button in ivans widget
This commit is contained in:
@@ -183,8 +183,13 @@ export default function IvansAlerts({ settings, widgetID }) {
|
|||||||
return (
|
return (
|
||||||
<Box w="100%" h="100%" key={index} p={1}>
|
<Box w="100%" h="100%" key={index} p={1}>
|
||||||
<br />
|
<br />
|
||||||
<Flex mb={2}>
|
<Flex mb={2} justify="space-between">
|
||||||
<Text pl={1} pr={1} bg="gray.600/50" borderRadius="md" fontSize="xs" color="gray.300">{file?.name}</Text>
|
<Text pl={1} pr={1} bg="gray.600/50" borderRadius="md" fontSize="xs" color="gray.300">{file?.name}</Text>
|
||||||
|
<Box borderRadius="lg" bg="gray.700" color="gray.300" pl={1} pr={1} fontSize={13} asChild>
|
||||||
|
<a href={`${file?.url}#view=FitV&toolbar=1`} target="_blank" rel="noopener noreferrer">
|
||||||
|
Open
|
||||||
|
</a>
|
||||||
|
</Box>
|
||||||
</Flex>
|
</Flex>
|
||||||
<object
|
<object
|
||||||
data={`${file?.url}#view=FitH&toolbar=1`}
|
data={`${file?.url}#view=FitH&toolbar=1`}
|
||||||
@@ -200,6 +205,13 @@ export default function IvansAlerts({ settings, widgetID }) {
|
|||||||
</a>
|
</a>
|
||||||
</Flex>
|
</Flex>
|
||||||
</object>
|
</object>
|
||||||
|
{/*<Flex w="100%" h="100%" justify="center" pt={4} color="gray.400">*/}
|
||||||
|
{/* <Button variant="subtle" asChild>*/}
|
||||||
|
{/* <a href={`${file?.url}#view=FitV&toolbar=1`} target="_blank" rel="noopener noreferrer">*/}
|
||||||
|
{/* View in New Page*/}
|
||||||
|
{/* </a>*/}
|
||||||
|
{/* </Button>*/}
|
||||||
|
{/*</Flex>*/}
|
||||||
</Box>
|
</Box>
|
||||||
)})}
|
)})}
|
||||||
</Box>
|
</Box>
|
||||||
|
|||||||
Reference in New Issue
Block a user