mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Merge pull request #2377 from omnivore-app/fix/recent-emails-frame
Put recent emails in an iframe
This commit is contained in:
commit
fc42800a9e
2 changed files with 11 additions and 4 deletions
|
|
@ -6,7 +6,7 @@ const ContentSecurityPolicy = `
|
||||||
font-src 'self' data: cdn.jsdelivr.net;
|
font-src 'self' data: cdn.jsdelivr.net;
|
||||||
form-action 'self' ${process.env.NEXT_PUBLIC_SERVER_BASE_URL};
|
form-action 'self' ${process.env.NEXT_PUBLIC_SERVER_BASE_URL};
|
||||||
frame-ancestors 'none';
|
frame-ancestors 'none';
|
||||||
frame-src accounts.google.com platform.twitter.com www.youtube-nocookie.com;
|
frame-src self accounts.google.com platform.twitter.com www.youtube.com www.youtube-nocookie.com;
|
||||||
manifest-src 'self';
|
manifest-src 'self';
|
||||||
script-src 'self' 'unsafe-inline' 'unsafe-eval' accounts.google.com widget.intercom.io js.intercomcdn.com platform.twitter.com cdnjs.cloudflare.com cdn.jsdelivr.net cdn.segment.com;
|
script-src 'self' 'unsafe-inline' 'unsafe-eval' accounts.google.com widget.intercom.io js.intercomcdn.com platform.twitter.com cdnjs.cloudflare.com cdn.jsdelivr.net cdn.segment.com;
|
||||||
style-src 'self' 'unsafe-inline' accounts.google.com cdnjs.cloudflare.com;
|
style-src 'self' 'unsafe-inline' accounts.google.com cdnjs.cloudflare.com;
|
||||||
|
|
|
||||||
|
|
@ -113,7 +113,7 @@ const ViewRecentEmailModal = (
|
||||||
;(document.activeElement as HTMLElement).blur()
|
;(document.activeElement as HTMLElement).blur()
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<VStack distribution="start">
|
<VStack distribution="start" css={{ height: '100%' }}>
|
||||||
<ModalTitleBar title="View Email" onOpenChange={props.onOpenChange} />
|
<ModalTitleBar title="View Email" onOpenChange={props.onOpenChange} />
|
||||||
{props.display == 'text' ? (
|
{props.display == 'text' ? (
|
||||||
<Box
|
<Box
|
||||||
|
|
@ -133,9 +133,16 @@ const ViewRecentEmailModal = (
|
||||||
height: '100%',
|
height: '100%',
|
||||||
fontSize: '12px',
|
fontSize: '12px',
|
||||||
overflowY: 'scroll',
|
overflowY: 'scroll',
|
||||||
|
iframe: {
|
||||||
|
width: '100%',
|
||||||
|
height: '100%',
|
||||||
|
display: 'block',
|
||||||
|
border: 'none',
|
||||||
|
},
|
||||||
}}
|
}}
|
||||||
dangerouslySetInnerHTML={{ __html: props.recentEmail.html }}
|
>
|
||||||
></Box>
|
<iframe srcDoc={props.recentEmail.html}></iframe>
|
||||||
|
</Box>
|
||||||
)}
|
)}
|
||||||
</VStack>
|
</VStack>
|
||||||
</ModalContent>
|
</ModalContent>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue