diff --git a/src/components/Table.styled.ts b/src/components/Table.styled.ts new file mode 100644 index 00000000..919467d1 --- /dev/null +++ b/src/components/Table.styled.ts @@ -0,0 +1,18 @@ +import styled from 'styled-components' +import { spacings } from '../tokens/spacings' + +export const StyledDiv = styled.div` + overflow-x: auto; + padding-bottom: ${spacings.MEDIUM}; + + > .table-wrapper { + > table { + width: auto !important; + margin: 0px !important; + } + + > div { + max-width: none !important; + } + } +` diff --git a/src/components/Table.tsx b/src/components/Table.tsx index 99d10f92..aaba63da 100644 --- a/src/components/Table.tsx +++ b/src/components/Table.tsx @@ -1,6 +1,7 @@ import { Chip } from '@equinor/eds-core-react' import { EdsDataGrid } from '@equinor/eds-data-grid-react' import { useGetAnalogueModels } from '../hooks/useGetAnalogueModels' +import * as Styled from './Table.styled' export const Table = () => { const { data: models } = useGetAnalogueModels() @@ -8,54 +9,56 @@ export const Table = () => { if (!models) return

Loading...

return ( - {'Approved'}, - }, - { - accessorKey: 'modified', - header: 'Last Modified', - cell: () =>
{''}
, - }, - { - accessorKey: 'analogue', - header: 'Analogue', - cell: () =>
{''}
, - }, - { - accessorKey: 'formation', - header: 'Formation', - cell: () =>
{''}
, - }, - { - accessorKey: 'field', - header: 'Field', - cell: () =>
{''}
, - }, - { - accessorKey: 'isProcessed', - header: 'Status', - id: 'isProcessed', - }, - ]} - /> + + {'Approved'}, + }, + { + accessorKey: 'modified', + header: 'Last Modified', + cell: () =>
{''}
, + }, + { + accessorKey: 'analogue', + header: 'Analogue', + cell: () =>
{''}
, + }, + { + accessorKey: 'formation', + header: 'Formation', + cell: () =>
{''}
, + }, + { + accessorKey: 'field', + header: 'Field', + cell: () =>
{''}
, + }, + { + accessorKey: 'isProcessed', + header: 'Status', + id: 'isProcessed', + }, + ]} + /> +
) }