1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-07-17 13:46:47 +02:00

edit project mismatch dialog and remove change button (#465)

* edit project mismatch dialog and remove change button

* add info test to solve mismatch
This commit is contained in:
Youssef Khedher 2021-10-25 11:47:15 +01:00 committed by GitHub
parent a3377fb1a2
commit 35670db919

View File

@ -54,18 +54,19 @@ const FeatureSettingsProjectConfirm = ({
}; };
return ( return (
<Dialogue <ConditionallyRender
open={open} condition={incompatibleEnvs?.length === 0}
onClose={onClose} show={
onClick={onClick} <Dialogue
title="Confirm change project" open={open}
primaryButtonText="Change project" onClose={onClose}
secondaryButtonText="Cancel" onClick={onClick}
> title="Confirm change project"
Are you sure you want to change the project for this feature toggle? primaryButtonText="Change project"
<ConditionallyRender secondaryButtonText="Cancel"
condition={incompatibleEnvs?.length === 0} >
show={ Are you sure you want to change the project for this feature
toggle?
<div className={styles.compatability}> <div className={styles.compatability}>
This feature toggle is 100% compatible with the new This feature toggle is 100% compatible with the new
project. project.
@ -73,23 +74,29 @@ const FeatureSettingsProjectConfirm = ({
<Check className={styles.check} /> <Check className={styles.check} />
</div> </div>
</div> </div>
} </Dialogue>
elseShow={ }
elseShow={
<Dialogue
open={open}
onClose={onClose}
title="Confirm change project"
secondaryButtonText="OK"
>
<div className={styles.topContent}>
<p>
{' '}
This feature toggle is not compatible with the new
project destination.
</p>
<div className={styles.iconContainer}>
<div className={styles.errorIconContainer}>
<Error className={styles.check} />
</div>
</div>
</div>
<div className={styles.compatability}> <div className={styles.compatability}>
<div> <div>
<div className={styles.topContent}>
<p>
{' '}
This feature toggle is not compatible with
the new project destination.
</p>
<div className={styles.iconContainer}>
<div className={styles.errorIconContainer}>
<Error className={styles.check} />
</div>
</div>
</div>
<p className={styles.paragraph}> <p className={styles.paragraph}>
This feature toggle has strategy configuration This feature toggle has strategy configuration
in an environment that is not activated in the in an environment that is not activated in the
@ -105,17 +112,15 @@ const FeatureSettingsProjectConfirm = ({
); );
})} })}
</List> </List>
<p className={styles.paragraph}>
You may still move the feature toggle, but the
strategies in these environment will not run
while these environments are inactive in the
target project.
</p>
</div> </div>
</div> </div>
} <p className={styles.paragraph}>
/> In order to move this feature toggle, make sure you
</Dialogue> enable the required environments in the target project.
</p>
</Dialogue>
}
/>
); );
}; };