mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-25 11:55:03 +03:00
Disabled backdrop click for offers modals (#19194)
refs ADM-37 - backdrop click should be disabled for modals, especially when modals contain user editable fields - to make things consistent, all offers related modals are not closeable by backdrop clicking
This commit is contained in:
parent
cdfe3843c3
commit
79081686b1
@ -44,6 +44,7 @@ export interface PreviewModalProps {
|
||||
sidebarPadding?: boolean;
|
||||
sidebarContentClasses?: string;
|
||||
enableCMDS?: boolean;
|
||||
backDropClick?: boolean;
|
||||
|
||||
onCancel?: () => void;
|
||||
onOk?: () => void;
|
||||
@ -83,6 +84,7 @@ export const PreviewModalContent: React.FC<PreviewModalProps> = ({
|
||||
sidebarPadding = true,
|
||||
sidebarContentClasses,
|
||||
enableCMDS = true,
|
||||
backDropClick,
|
||||
|
||||
onCancel,
|
||||
onOk,
|
||||
@ -262,6 +264,7 @@ export const PreviewModalContent: React.FC<PreviewModalProps> = ({
|
||||
<Modal
|
||||
afterClose={afterClose}
|
||||
animate={false}
|
||||
backDropClick={backDropClick}
|
||||
footer={false}
|
||||
height={height}
|
||||
padding={false}
|
||||
|
@ -614,6 +614,7 @@ const AddOfferModal = () => {
|
||||
afterClose={() => {
|
||||
updateRoute('offers');
|
||||
}}
|
||||
backDropClick={false}
|
||||
cancelLabel='Cancel'
|
||||
deviceSelector={false}
|
||||
dirty={saveState === 'unsaved'}
|
||||
|
@ -256,6 +256,7 @@ const EditOfferModal: React.FC<{id: string}> = ({id}) => {
|
||||
afterClose={() => {
|
||||
updateRoute('offers');
|
||||
}}
|
||||
backDropClick={false}
|
||||
deviceSelector={false}
|
||||
dirty={saveState === 'unsaved'}
|
||||
height='full'
|
||||
|
@ -74,6 +74,7 @@ const OfferSuccess: React.FC<{id: string}> = ({id}) => {
|
||||
updateRoute('offers');
|
||||
}}
|
||||
animate={false}
|
||||
backDropClick={false}
|
||||
footer={false}
|
||||
height='full'
|
||||
size='lg'
|
||||
|
@ -194,6 +194,7 @@ export const OffersIndexModal = () => {
|
||||
updateRoute('offers');
|
||||
}}
|
||||
animate={false}
|
||||
backDropClick={false}
|
||||
cancelLabel=''
|
||||
header={false}
|
||||
height='full'
|
||||
|
Loading…
Reference in New Issue
Block a user