fixed how button sets are displayed and removed test date range picker from secret list w/ burnettk (#397)

Co-authored-by: jasquat <jasquat@users.noreply.github.com>
This commit is contained in:
jasquat 2023-07-17 12:44:10 -04:00 committed by GitHub
parent 29678bcd88
commit 9a1c23f22b
7 changed files with 14 additions and 38 deletions

View File

@ -40,7 +40,7 @@ export default function Filters({
<Grid fullWidth>
{reportSearchSection}
<Column
className="filterIcon"
className="filter-icon"
sm={{ span: 1, offset: 3 }}
md={{ span: 1, offset: 7 }}
lg={{ span: 1, offset: 15 }}

View File

@ -1,7 +1,7 @@
import { useState } from 'react';
import { useNavigate } from 'react-router-dom';
// @ts-ignore
import { Button, ButtonSet, Form, Stack, TextInput } from '@carbon/react';
import { Button, Form, Stack, TextInput } from '@carbon/react';
import { modifyProcessIdentifierForPathParam, slugifyString } from '../helpers';
import HttpService from '../services/HttpService';
import { ProcessGroup } from '../interfaces';
@ -155,8 +155,7 @@ export default function ProcessGroupForm({
};
const formButtons = () => {
const buttons = [<Button type="submit">Submit</Button>];
return <ButtonSet>{buttons}</ButtonSet>;
return <Button type="submit">Submit</Button>;
};
return (

View File

@ -2,7 +2,6 @@ import { useState } from 'react';
import { useNavigate } from 'react-router-dom';
import {
Button,
ButtonSet,
Form,
Stack,
TextInput,
@ -382,12 +381,11 @@ export default function ProcessModelForm({
};
const formButtons = () => {
const buttons = [
return (
<Button kind="secondary" type="submit">
Submit
</Button>,
];
return <ButtonSet>{buttons}</ButtonSet>;
</Button>
);
};
return (
<Form onSubmit={handleFormSubmission}>

View File

@ -444,7 +444,7 @@ td.actions-cell {
margin: 2rem 0;
}
.filterIcon {
.filter-icon {
text-align: right;
padding-bottom: 10px;
}
@ -474,6 +474,7 @@ svg.notification-icon {
.filter-tag {
justify-content: left;
width: 100%;
height: 2rem;
}
.filter-tag > span {
display: flex;
@ -488,14 +489,14 @@ svg.notification-icon {
.cds--btn--ghost.cds--btn--sm.button-tag {
padding-left: 0;
padding-right: 0;
padding-top: 0;
padding-top: 0px;
flex-grow: 1;
}
.cds--btn--ghost.cds--btn--sm.button-tag-icon {
padding-left: 0;
padding-right: 0;
padding-top: 0;
padding-top: 0px;
}
/* .no-wrap cds--label cds--label--inline cds--label--inline--md{ */

View File

@ -1,7 +1,6 @@
import { useEffect, useState } from 'react';
import { useNavigate } from 'react-router-dom';
// @ts-ignore
import { Button, ButtonSet, Form, Stack, TextInput } from '@carbon/react';
import { Button, Form, Stack, TextInput } from '@carbon/react';
import { isInteger, modifyProcessIdentifierForPathParam } from '../helpers';
import HttpService from '../services/HttpService';
import ProcessInstanceListTabs from '../components/ProcessInstanceListTabs';
@ -65,8 +64,7 @@ export default function ProcessInstanceFindById() {
};
const formButtons = () => {
const buttons = [<Button type="submit">Submit</Button>];
return <ButtonSet>{buttons}</ButtonSet>;
return <Button type="submit">Submit</Button>;
};
return (

View File

@ -21,10 +21,8 @@ import {
StopOutline,
TrashCan,
Warning,
// @ts-ignore
} from '@carbon/icons-react';
import {
ButtonSet,
Grid,
Column,
Button,
@ -38,7 +36,6 @@ import {
TabList,
TabPanels,
TabPanel,
// @ts-ignore
} from '@carbon/react';
import ProcessBreadcrumb from '../components/ProcessBreadcrumb';
import HttpService from '../services/HttpService';
@ -1106,7 +1103,7 @@ export default function ProcessInstanceShow({ variant }: OwnProps) {
</Stack>
</div>
</div>
<ButtonSet>{taskDisplayButtons(taskToUse)}</ButtonSet>
{taskDisplayButtons(taskToUse)}
{taskToUse.state === 'COMPLETED' ? (
<div>
<Stack orientation="horizontal" gap={2}>

View File

@ -1,7 +1,7 @@
import { useEffect, useState } from 'react';
import { Link, useSearchParams } from 'react-router-dom';
// @ts-ignore
import { Button, Table, DatePicker, DatePickerInput } from '@carbon/react';
import { Button, Table } from '@carbon/react';
import { MdDelete } from 'react-icons/md';
import PaginationForTable from '../components/PaginationForTable';
import HttpService from '../services/HttpService';
@ -10,8 +10,6 @@ import { getPageInfoFromSearchParams } from '../helpers';
export default function SecretList() {
const [searchParams] = useSearchParams();
const [dateRange, setDateRange] = useState([]);
const [secrets, setSecrets] = useState([]);
const [pagination, setPagination] = useState(null);
@ -97,21 +95,6 @@ export default function SecretList() {
return (
<div>
<h1>Secrets</h1>
<DatePicker
onChange={(selectedDates: any) => {
setDateRange(selectedDates);
}}
value={dateRange}
dateFormat="Y-m-d"
datePickerType="range"
>
<DatePickerInput
id="from"
placeholder="yyyy-mm-dd"
labelText="from"
/>
<DatePickerInput id="to" placeholder="yyyy-mm-dd" labelText="to" />
</DatePicker>
{SecretsDisplayArea()}
<Button href="/admin/configuration/secrets/new">Add a secret</Button>
</div>