Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade PF and get rid of custom CSS on settings page #952

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
395 changes: 201 additions & 194 deletions frontend/package-lock.json

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@
"dependencies": {
"@openshift/dynamic-plugin-sdk": "^1.0.0-alpha12",
"@openshift/dynamic-plugin-sdk-utils": "^1.0.0-alpha17",
"@patternfly/patternfly": "4.222.4",
"@patternfly/patternfly": "4.224.2",
"@patternfly/quickstarts": "^2.3.1",
"@patternfly/react-catalog-view-extension": "4.93.15",
"@patternfly/react-charts": "^6.94.15",
"@patternfly/react-core": "4.267.6",
"@patternfly/react-icons": "4.93.3",
"@patternfly/react-styles": "4.92.3",
"@patternfly/react-table": "4.112.6",
"@patternfly/react-virtualized-extension": "4.88.82",
"@patternfly/react-catalog-view-extension": "4.95.1",
"@patternfly/react-charts": "6.94.18",
"@patternfly/react-core": "4.276.6",
"@patternfly/react-icons": "4.93.6",
"@patternfly/react-styles": "4.92.6",
"@patternfly/react-table": "4.112.39",
"@patternfly/react-virtualized-extension": "4.88.113",
"@types/classnames": "^2.3.1",
"axios": "^0.21.1",
"classnames": "^2.2.6",
Expand Down
29 changes: 29 additions & 0 deletions frontend/src/components/SettingSection.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import * as React from 'react';
import { Card, CardBody, CardFooter, CardTitle, Stack, StackItem } from '@patternfly/react-core';

type SettingSectionProps = {
children: React.ReactNode;
title: string;
description?: string;
footer?: React.ReactNode;
};

const SettingSection: React.FC<SettingSectionProps> = ({
title,
children,
footer,
description,
}) => (
<Card isFlat>
<CardTitle>{title}</CardTitle>
<CardBody>
<Stack hasGutter>
{description && <StackItem>{description}</StackItem>}
<StackItem>{children}</StackItem>
</Stack>
</CardBody>
{footer && <CardFooter>{footer}</CardFooter>}
</Card>
);

export default SettingSection;
20 changes: 8 additions & 12 deletions frontend/src/pages/BYONImages/BYONImages.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,18 +64,14 @@ const BYONImages: React.FC = () => {
errorMessage="Unable to load notebook images."
emptyStatePage={noImagesPageSection}
>
{!isEmpty ? (
<div className="odh-cluster-settings">
<PageSection variant={PageSectionVariants.light} padding={{ default: 'noPadding' }}>
<Flex direction={{ default: 'column' }}>
<FlexItem>
{' '}
<BYONImagesTable images={images} forceUpdate={forceUpdate} />
</FlexItem>
</Flex>
</PageSection>
</div>
) : null}
<PageSection variant={PageSectionVariants.light} padding={{ default: 'noPadding' }}>
<Flex direction={{ default: 'column' }}>
<FlexItem>
{' '}
<BYONImagesTable images={images} forceUpdate={forceUpdate} />
</FlexItem>
</Flex>
</PageSection>
</ApplicationsPage>
);
};
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/pages/BYONImages/BYONImagesTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ export const BYONImagesTable: React.FC<BYONImagesTableProps> = ({ images, forceU
className="filter-search"
aria-label="search input for image images table"
value={tableFilter.filter}
onChange={(value) => {
onChange={(_, value) => {
const newCount = getFilterCount(value, tableFilter.option);
setTableFilter({
filter: value,
Expand Down Expand Up @@ -310,7 +310,7 @@ export const BYONImagesTable: React.FC<BYONImagesTableProps> = ({ images, forceU
packages.push(<p>{`${nbpackage.name} ${nbpackage.version}`}</p>);
});
return (
<Tbody key={image.name} isExpanded={isBYONImageExpanded(image)}>
<Tbody key={image.id} isExpanded={isBYONImageExpanded(image)}>
<Tr isHidden={applyTableFilter(image)}>
<Td
expand={{
Expand Down
48 changes: 0 additions & 48 deletions frontend/src/pages/clusterSettings/ClusterSettings.scss

This file was deleted.

Loading