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

Fixes #36858 - Table index page design changes #9873

Merged
merged 1 commit into from
Oct 31, 2023
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
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ export const Table = ({
url={url}
refreshData={refreshData}
/>
<TableComposable variant="compact" ouiaId="table">
<TableComposable variant="compact" ouiaId="table" isStriped>
<Thead>
<Tr ouiaId="table-header">
{showCheckboxes && <Th key="checkbox-th" />}
Expand Down Expand Up @@ -127,7 +127,7 @@ export const Table = ({
</Tr>
)}
{results.map((result, rowIndex) => (
<Tr key={rowIndex} ouiaId={`table-row-${rowIndex}`}>
<Tr key={rowIndex} ouiaId={`table-row-${rowIndex}`} isHoverable>
{showCheckboxes && <RowSelectTd rowData={result} />}
{columnNamesKeys.map(k => (
<Td key={k} dataLabel={columnNames[k]}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,15 +193,21 @@ const TableIndexPage = ({
<BreadcrumbBar {...breadcrumbOptions} />
</PageSection>
)}
<PageSection variant={PageSectionVariants.light}>
<PageSection
variant={PageSectionVariants.light}
className="table-title-section"
>
<TextContent>
<Text ouiaId="header-text" component="h1">
{header}
</Text>
</TextContent>
</PageSection>
{beforeToolbarComponent}
<PageSection variant={PageSectionVariants.light}>
<PageSection
variant={PageSectionVariants.light}
className="table-toolbar-section"
>
<Toolbar ouiaId="table-toolbar" className="table-toolbar">
<ToolbarContent>
{searchable && (
Expand Down Expand Up @@ -245,7 +251,10 @@ const TableIndexPage = ({
</ToolbarContent>
</Toolbar>
</PageSection>
<PageSection variant={PageSectionVariants.light}>
<PageSection
variant={PageSectionVariants.light}
className="table-section"
>
{children || (
<Table
params={params}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,32 @@
#foreman-page {
.table-toolbar {
padding: 0;
.pf-c-toolbar__content {
.table-title-section {
padding-bottom: 0;
}
.table-toolbar-section {
padding-top: 16px;
padding-bottom: 16px;
.table-toolbar {
padding: 0;
.pf-c-toolbar__content {
padding: 0;
}
.toolbar-search {
flex-grow: 1;
}
.autocomplete-search {
max-width: 600px;
}
}
.toolbar-search {
.pf-c-toolbar__group {
flex-grow: 1;
}
.autocomplete-search {
max-width: 600px;
&.pf-m-align-right {
justify-content: flex-end;
}
}
}
.pf-c-toolbar__group {
flex-grow: 1;
&.pf-m-align-right{
justify-content: flex-end;
}
.table-section {
padding-top: 0;
padding-left: 0;
ekohl marked this conversation as resolved.
Show resolved Hide resolved
padding-right: 0;
}
}