mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-09 08:52:34 +00:00
Refactor #3965 - Refactor on DataTable
This commit is contained in:
parent
7c885411ba
commit
67e65198d2
4 changed files with 10 additions and 9 deletions
|
@ -7,10 +7,6 @@ const styles = `
|
|||
position: relative;
|
||||
}
|
||||
|
||||
.p-datatable > .p-datatable-wrapper {
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.p-datatable-table {
|
||||
border-spacing: 0px;
|
||||
width: 100%;
|
||||
|
@ -43,7 +39,6 @@ const styles = `
|
|||
}
|
||||
|
||||
.p-datatable-scrollable-table > .p-datatable-thead {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 1;
|
||||
}
|
||||
|
@ -54,7 +49,6 @@ const styles = `
|
|||
}
|
||||
|
||||
.p-datatable-scrollable-table > .p-datatable-tfoot {
|
||||
position: sticky;
|
||||
bottom: 0;
|
||||
z-index: 1;
|
||||
}
|
||||
|
@ -245,6 +239,12 @@ const styles = `
|
|||
}
|
||||
`;
|
||||
|
||||
const inlineStyles = {
|
||||
wrapper: { overflow: 'auto' },
|
||||
thead: { position: 'sticky' },
|
||||
tfoot: { position: 'sticky' }
|
||||
};
|
||||
|
||||
const classes = {
|
||||
root: ({ instance, props }) => [
|
||||
'p-datatable p-component',
|
||||
|
@ -730,6 +730,7 @@ export default {
|
|||
},
|
||||
css: {
|
||||
classes,
|
||||
inlineStyles,
|
||||
loadStyle
|
||||
},
|
||||
provide() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue