diff --git a/extensions/azurePublish/src/components/azureProvisionDialog.tsx b/extensions/azurePublish/src/components/azureProvisionDialog.tsx index 02c75b317a..b3c1150153 100644 --- a/extensions/azurePublish/src/components/azureProvisionDialog.tsx +++ b/extensions/azurePublish/src/components/azureProvisionDialog.tsx @@ -74,11 +74,20 @@ type ProvisionFormData = { }; // ---------- Styles ---------- // +type ProvisonActionsStylingProps = { + showSignout: boolean; +}; const AddResourcesSectionName = styled(Text)` font-size: ${FluentTheme.fonts.mediumPlus.fontSize}; `; +const ProvisonActions = styled.div((props) => ({ + display: 'flex', + flexFlow: 'row nowrap', + justifyContent: props.showSignout ? 'space-between' : 'flex-end', +})); + const ConfigureResourcesSectionName = styled(Text)` font-size: ${FluentTheme.fonts.mediumPlus.fontSize}; font-weight: ${FontWeights.semibold}; @@ -993,28 +1002,18 @@ export const AzureProvisionDialog: React.FC = () => { ); const PageFooter = useMemo(() => { + const isSignedInAndCreateCreationType = currentUser && formData.creationType === 'create'; if (page === PageTypes.ChooseAction) { return ( -
- {currentUser ? ( + + {isSignedInAndCreateCreationType ? ( - ) : ( -
{ - clearAll(); - closeDialog(); - logOut(); - }} - > - Sign out -
- )} + ) : null}
{ }} />
-
+ ); } else if (page === PageTypes.ConfigProvision) { return ( -
+ {currentUser ? ( { text={currentUser.name} onRenderSecondaryText={onRenderSecondaryText} /> - ) : ( -
{ - clearAll(); - closeDialog(); - logOut(); - }} - > - {formatMessage('Sign out')} -
- )} + ) : null}
{ }} />
-
+ ); } else if (page === PageTypes.AddResources) { return ( -
- {currentUser ? ( + + {isSignedInAndCreateCreationType ? ( { }} />
- + ); } else if (page === PageTypes.ReviewResource) { return ( -
+ {currentUser ? ( { }} />
- + ); } else { return (