mirror of
https://github.com/CommunityOx/ox_lib.git
synced 2026-08-17 06:56:03 +01:00
fix(web/alert): fix images escaping container width and height
resolves #265
This commit is contained in:
@@ -49,7 +49,14 @@ const AlertDialog: React.FC = () => {
|
|||||||
title={<ReactMarkdown>{dialogData.header}</ReactMarkdown>}
|
title={<ReactMarkdown>{dialogData.header}</ReactMarkdown>}
|
||||||
>
|
>
|
||||||
<Stack>
|
<Stack>
|
||||||
<ReactMarkdown remarkPlugins={[remarkGfm]}>{dialogData.content}</ReactMarkdown>
|
<ReactMarkdown
|
||||||
|
remarkPlugins={[remarkGfm]}
|
||||||
|
components={{
|
||||||
|
img: ({ ...props }) => <img style={{ maxWidth: '100%', maxHeight: '100%' }} {...props} />,
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{dialogData.content}
|
||||||
|
</ReactMarkdown>
|
||||||
<Group position="right" spacing={10}>
|
<Group position="right" spacing={10}>
|
||||||
{dialogData.cancel && (
|
{dialogData.cancel && (
|
||||||
<Button uppercase variant="default" onClick={() => closeAlert('cancel')} mr={3}>
|
<Button uppercase variant="default" onClick={() => closeAlert('cancel')} mr={3}>
|
||||||
|
|||||||
Reference in New Issue
Block a user