mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-02-12 08:43:38 +01:00
extract wide modal styles
This commit is contained in:
parent
6fa0cfc53a
commit
f67fbd1978
4 changed files with 11 additions and 9 deletions
|
@ -27,7 +27,6 @@ import {
|
|||
getFileNameExt,
|
||||
mimeTypeToExt,
|
||||
} from '../../../utils/mimeTypes';
|
||||
import * as css from './style.css';
|
||||
import { stopPropagation } from '../../../utils/keyboard';
|
||||
import {
|
||||
decryptFile,
|
||||
|
@ -36,6 +35,7 @@ import {
|
|||
mxcUrlToHttp,
|
||||
} from '../../../utils/matrix';
|
||||
import { useMediaAuthentication } from '../../../hooks/useMediaAuthentication';
|
||||
import { ModalWide } from '../../../styles/Modal.css';
|
||||
|
||||
const renderErrorButton = (retry: () => void, text: string) => (
|
||||
<TooltipProvider
|
||||
|
@ -111,7 +111,7 @@ export function ReadTextFile({ body, mimeType, url, encInfo, renderViewer }: Rea
|
|||
}}
|
||||
>
|
||||
<Modal
|
||||
className={css.ModalWide}
|
||||
className={ModalWide}
|
||||
size="500"
|
||||
onContextMenu={(evt: any) => evt.stopPropagation()}
|
||||
>
|
||||
|
@ -199,7 +199,7 @@ export function ReadPdfFile({ body, mimeType, url, encInfo, renderViewer }: Read
|
|||
}}
|
||||
>
|
||||
<Modal
|
||||
className={css.ModalWide}
|
||||
className={ModalWide}
|
||||
size="500"
|
||||
onContextMenu={(evt: any) => evt.stopPropagation()}
|
||||
>
|
||||
|
|
|
@ -28,6 +28,7 @@ import { FALLBACK_MIMETYPE } from '../../../utils/mimeTypes';
|
|||
import { stopPropagation } from '../../../utils/keyboard';
|
||||
import { decryptFile, downloadEncryptedMedia, mxcUrlToHttp } from '../../../utils/matrix';
|
||||
import { useMediaAuthentication } from '../../../hooks/useMediaAuthentication';
|
||||
import { ModalWide } from '../../../styles/Modal.css';
|
||||
|
||||
type RenderViewerProps = {
|
||||
src: string;
|
||||
|
@ -121,7 +122,7 @@ export const ImageContent = as<'div', ImageContentProps>(
|
|||
}}
|
||||
>
|
||||
<Modal
|
||||
className={css.ModalWide}
|
||||
className={ModalWide}
|
||||
size="500"
|
||||
onContextMenu={(evt: any) => evt.stopPropagation()}
|
||||
>
|
||||
|
|
|
@ -30,8 +30,3 @@ export const AbsoluteFooter = style([
|
|||
right: config.space.S100,
|
||||
},
|
||||
]);
|
||||
|
||||
export const ModalWide = style({
|
||||
minWidth: '85vw',
|
||||
minHeight: '90vh',
|
||||
});
|
||||
|
|
6
src/app/styles/Modal.css.ts
Normal file
6
src/app/styles/Modal.css.ts
Normal file
|
@ -0,0 +1,6 @@
|
|||
import { style } from '@vanilla-extract/css';
|
||||
|
||||
export const ModalWide = style({
|
||||
minWidth: '85vw',
|
||||
minHeight: '90vh',
|
||||
});
|
Loading…
Reference in a new issue