Wizard: Fix UI issues for Microsoft Azure Target environment
Fixes #772. This updates description of the step according to recent SPUR. The `Authorizing an Azure account` expandable was removed (both from the step and `ImageCreator.js`) as well as `Destination` heading. Size of the Oauth 2.0 link was changed from small to default.
This commit is contained in:
parent
2520b99ad1
commit
c9c75da7ba
4 changed files with 26 additions and 73 deletions
|
|
@ -47,14 +47,6 @@
|
|||
height: 1em;
|
||||
}
|
||||
|
||||
.azureAuthExpandable {
|
||||
--pf-c-expandable-section__toggle--Color: var(--pf-global--Color--100);
|
||||
--pf-c-expandable-section__toggle--hover--Color: var(--pf-global--Color--100);
|
||||
--pf-c-expandable-section__toggle--active--Color: var(--pf-global--Color--100);
|
||||
--pf-c-expandable-section__toggle--focus--Color: var(--pf-global--Color--100);
|
||||
--pf-c-expandable-section__toggle--m-expanded--Color: var(--pf-global--Color--100);
|
||||
}
|
||||
|
||||
.pf-c-select__menu-item.pf-m-load {
|
||||
--pf-c-select__menu-item--Color: var(--pf-global--Color--100);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@ import TargetEnvironment from './formComponents/TargetEnvironment';
|
|||
import Packages from './formComponents/Packages';
|
||||
import RadioWithPopover from './formComponents/RadioWithPopover';
|
||||
import AzureAuthButton from './formComponents/AzureAuthButton';
|
||||
import AzureAuthExpandable from './formComponents/AzureAuthExpandable';
|
||||
import ActivationKeys from './formComponents/ActivationKeys';
|
||||
import Select from '@data-driven-forms/pf4-component-mapper/select';
|
||||
import FileSystemConfiguration from './formComponents/FileSystemConfiguration';
|
||||
|
|
@ -48,7 +47,6 @@ const ImageCreator = ({
|
|||
defaultArch,
|
||||
},
|
||||
'radio-popover': RadioWithPopover,
|
||||
'azure-auth-expandable': AzureAuthExpandable,
|
||||
'azure-auth-button': AzureAuthButton,
|
||||
'activation-keys': ActivationKeys,
|
||||
'file-system-config-toggle': FileSystemConfigToggle,
|
||||
|
|
|
|||
|
|
@ -1,43 +0,0 @@
|
|||
import React, { useState } from 'react';
|
||||
import { Button, ExpandableSection, Text, Title } from '@patternfly/react-core';
|
||||
import { ExternalLinkAltIcon } from '@patternfly/react-icons';
|
||||
|
||||
const AzureAuthExpandable = () => {
|
||||
const [expanded, setExpanded] = useState(true);
|
||||
|
||||
return (
|
||||
<>
|
||||
<ExpandableSection
|
||||
className="azureAuthExpandable"
|
||||
toggleText={
|
||||
<Title headingLevel="h3">Authorizing an Azure account</Title>
|
||||
}
|
||||
onToggle={() => setExpanded(!expanded)}
|
||||
isExpanded={expanded}
|
||||
>
|
||||
<Text>
|
||||
To authorize Image Builder to push images to Microsoft Azure, the
|
||||
account owner must configure Image Builder as an authorized
|
||||
application for a specific tenant ID and give it the role of
|
||||
"Contributor" to at least one resource group.
|
||||
<br />
|
||||
</Text>
|
||||
<small>
|
||||
<Button
|
||||
component="a"
|
||||
target="_blank"
|
||||
variant="link"
|
||||
icon={<ExternalLinkAltIcon />}
|
||||
iconPosition="right"
|
||||
isInline
|
||||
href="https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow"
|
||||
>
|
||||
Learn more about OAuth 2.0
|
||||
</Button>
|
||||
</small>
|
||||
</ExpandableSection>
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
export default AzureAuthExpandable;
|
||||
|
|
@ -1,7 +1,8 @@
|
|||
import React from 'react';
|
||||
import componentTypes from '@data-driven-forms/react-form-renderer/component-types';
|
||||
import validatorTypes from '@data-driven-forms/react-form-renderer/validator-types';
|
||||
import { Title, Text } from '@patternfly/react-core';
|
||||
import { Title, Text, Button, TextContent } from '@patternfly/react-core';
|
||||
import { ExternalLinkAltIcon } from '@patternfly/react-icons';
|
||||
import nextStepMapper from './imageOutputStepMapper';
|
||||
import StepTemplate from './stepTemplate';
|
||||
|
||||
|
|
@ -27,26 +28,31 @@ export default {
|
|||
component: componentTypes.PLAIN_TEXT,
|
||||
name: 'azure-description',
|
||||
label: (
|
||||
<Text>
|
||||
Image Builder sends an image to an authorized Azure account.
|
||||
</Text>
|
||||
),
|
||||
},
|
||||
{
|
||||
component: 'azure-auth-expandable',
|
||||
name: 'azure-auth-expandable',
|
||||
},
|
||||
{
|
||||
component: componentTypes.PLAIN_TEXT,
|
||||
name: 'azure-destination',
|
||||
label: (
|
||||
<>
|
||||
<Title headingLevel="h2">Destination</Title>
|
||||
<TextContent>
|
||||
<Text>
|
||||
Your image will be uploaded to the resource group in the
|
||||
subscription you specify.
|
||||
Upon build, Image Builder sends the image to the selected authorized
|
||||
Azure account. The image will be uploaded to the resource group in
|
||||
the subscription you specify.
|
||||
</Text>
|
||||
</>
|
||||
<Text>
|
||||
To authorize Image Builder to push images to Microsoft Azure, the
|
||||
account owner must configure Image Builder as an authorized
|
||||
application for a specific tenant ID and give it the role of
|
||||
"Contributor" to at least one resource group.
|
||||
<br />
|
||||
<Button
|
||||
component="a"
|
||||
target="_blank"
|
||||
variant="link"
|
||||
icon={<ExternalLinkAltIcon />}
|
||||
iconPosition="right"
|
||||
isInline
|
||||
href="https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow"
|
||||
>
|
||||
Learn more about OAuth 2.0
|
||||
</Button>
|
||||
</Text>
|
||||
</TextContent>
|
||||
),
|
||||
},
|
||||
{
|
||||
|
|
@ -55,7 +61,7 @@ export default {
|
|||
className: 'pf-u-w-50',
|
||||
'data-testid': 'azure-tenant-id',
|
||||
type: 'text',
|
||||
label: 'Tenant ID',
|
||||
label: 'Azure Tenant GUID',
|
||||
required: true,
|
||||
isRequired: true,
|
||||
autoFocus: true,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue