mirror of
https://github.com/ansible/awx.git
synced 2026-05-23 16:47:45 -02:30
Separate prompted modal section with divider and fix user word-wrap
This commit is contained in:
@@ -2,10 +2,15 @@ import React from 'react';
|
|||||||
import { node, string } from 'prop-types';
|
import { node, string } from 'prop-types';
|
||||||
import { Trans } from '@lingui/macro';
|
import { Trans } from '@lingui/macro';
|
||||||
import { Link } from 'react-router-dom';
|
import { Link } from 'react-router-dom';
|
||||||
|
import styled from 'styled-components';
|
||||||
import { formatDateString } from '@util/dates';
|
import { formatDateString } from '@util/dates';
|
||||||
import Detail from './Detail';
|
import _Detail from './Detail';
|
||||||
import { SummaryFieldUser } from '../../types';
|
import { SummaryFieldUser } from '../../types';
|
||||||
|
|
||||||
|
const Detail = styled(_Detail)`
|
||||||
|
word-break: break-word;
|
||||||
|
`;
|
||||||
|
|
||||||
function UserDateDetail({ label, date, user, dataCy = null }) {
|
function UserDateDetail({ label, date, user, dataCy = null }) {
|
||||||
const dateStr = formatDateString(date);
|
const dateStr = formatDateString(date);
|
||||||
const username = user ? user.username : '';
|
const username = user ? user.username : '';
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import { Link } from 'react-router-dom';
|
|||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
import { toTitleCase } from '@util/strings';
|
import { toTitleCase } from '@util/strings';
|
||||||
|
|
||||||
import { Chip, ChipGroup } from '@patternfly/react-core';
|
import { Chip, ChipGroup, Divider } from '@patternfly/react-core';
|
||||||
import { VariablesDetail } from '@components/CodeMirrorInput';
|
import { VariablesDetail } from '@components/CodeMirrorInput';
|
||||||
import CredentialChip from '@components/CredentialChip';
|
import CredentialChip from '@components/CredentialChip';
|
||||||
import { DetailList, Detail, UserDateDetail } from '@components/DetailList';
|
import { DetailList, Detail, UserDateDetail } from '@components/DetailList';
|
||||||
@@ -200,6 +200,7 @@ function PromptDetail({ i18n, resource, launchConfig = {} }) {
|
|||||||
|
|
||||||
{hasPromptData(launchConfig) && hasOverrides && (
|
{hasPromptData(launchConfig) && hasOverrides && (
|
||||||
<>
|
<>
|
||||||
|
<Divider css="margin-top: var(--pf-global--spacer--lg)" />
|
||||||
<PromptHeader>{i18n._(t`Prompted Values`)}</PromptHeader>
|
<PromptHeader>{i18n._(t`Prompted Values`)}</PromptHeader>
|
||||||
<DetailList aria-label="Prompt Overrides">
|
<DetailList aria-label="Prompt Overrides">
|
||||||
{overrides?.job_type && (
|
{overrides?.job_type && (
|
||||||
|
|||||||
Reference in New Issue
Block a user