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

Allow customizing restrictWidth and paddingSize of TableListView #7691

Merged
merged 2 commits into from
Aug 13, 2024
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
2 changes: 2 additions & 0 deletions changelogs/fragments/7691.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
feat:
- Allow customizing `restrictWidth` and `paddingSize` of `TableListView` ([#7691](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/7691))
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ import {
EuiCallOut,
EuiBasicTableColumn,
EuiText,
EuiPageProps,
} from '@elastic/eui';
import { HttpFetchError, ToastsStart } from 'opensearch-dashboards/public';
import { toMountPoint } from '../util';
Expand Down Expand Up @@ -81,6 +82,8 @@ export interface TableListViewProps {
* If the table is not empty, this component renders its own h1 element using the same id.
*/
headingId?: string;
restrictWidth?: boolean;
paddingSize?: EuiPageProps['paddingSize'];
}

export interface TableListViewState {
Expand Down Expand Up @@ -559,7 +562,8 @@ class TableListView extends React.Component<TableListViewProps, TableListViewSta
<EuiPage
data-test-subj={this.props.entityName + 'LandingPage'}
className="itemListing__page"
restrictWidth
restrictWidth={this.props.restrictWidth}
paddingSize={this.props.paddingSize}
>
<EuiPageBody
component="main"
Expand Down
Loading