Skip to content

Commit 718fc3c

Browse files
committed
Increase various column widths with text that are now cut off due to new sortable icon
+ use first custom `responsiveBreakpoint` to handle table with lots of columns!! 🎉
1 parent fa99ad8 commit 718fc3c

3 files changed

Lines changed: 6 additions & 4 deletions

File tree

  • src/plugins/saved_objects_management/public/management_section/objects_table/components
  • x-pack/plugins/observability_solution/infra/public/pages/metrics/hosts

src/plugins/saved_objects_management/public/management_section/objects_table/components/table.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ export class Table extends PureComponent<TableProps, TableState> {
234234
name: i18n.translate('savedObjectsManagement.objectsTable.table.columnTypeName', {
235235
defaultMessage: 'Type',
236236
}),
237-
width: '50px',
237+
width: '65px',
238238
align: 'center',
239239
description: i18n.translate(
240240
'savedObjectsManagement.objectsTable.table.columnTypeDescription',

x-pack/plugins/observability_solution/infra/public/pages/metrics/hosts/components/hosts_table.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ export const HostsTable = () => {
4141
/>
4242
<EuiBasicTable
4343
data-test-subj={`hostsView-table-${loading ? 'loading' : 'loaded'}`}
44+
// This table has a lot of columns, so break down into mobile view sooner
45+
responsiveBreakpoint="xl"
4446
itemId="id"
4547
selection={selection}
4648
pagination={{

x-pack/plugins/observability_solution/infra/public/pages/metrics/hosts/hooks/use_hosts_table.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ export const useHostsTable = () => {
203203
return items.sort(sortTableData(sorting)).slice(startIndex, endIndex);
204204
}, [items, pagination, sorting]);
205205

206-
const metricColumnsWidth = displayAlerts ? '11%' : '15%';
206+
const metricColumnsWidth = displayAlerts ? '12%' : '16%';
207207

208208
const columns: Array<EuiBasicTableColumn<HostNodeRow>> = useMemo(
209209
() => [
@@ -360,7 +360,7 @@ export const useHostsTable = () => {
360360
formula={formulas?.rx.value}
361361
/>
362362
),
363-
width: '10%',
363+
width: '12%',
364364
field: 'rx',
365365
sortable: true,
366366
'data-test-subj': 'hostsView-tableRow-rx',
@@ -375,7 +375,7 @@ export const useHostsTable = () => {
375375
formula={formulas?.tx.value}
376376
/>
377377
),
378-
width: '10%',
378+
width: '12%',
379379
field: 'tx',
380380
sortable: true,
381381
'data-test-subj': 'hostsView-tableRow-tx',

0 commit comments

Comments
 (0)