Fixed #6294 - VirtualScroller: Unstyled mode broke core functionality

pull/6537/head
Mert Sincan 2024-10-04 15:19:28 +01:00
parent 696806daef
commit ec6003f585
1 changed files with 14 additions and 8 deletions

View File

@ -1,6 +1,19 @@
import BaseStyle from '@primevue/core/base/style'; import BaseStyle from '@primevue/core/base/style';
const theme = ({ dt }) => ` const theme = ({ dt }) => `
.p-virtualscroller-loader {
background: ${dt('virtualscroller.loader.mask.background')};
color: ${dt('virtualscroller.loader.mask.color')};
}
.p-virtualscroller-loading-icon {
font-size: ${dt('virtualscroller.loader.icon.size')};
width: ${dt('virtualscroller.loader.icon.size')};
height: ${dt('virtualscroller.loader.icon.size')};
}
`;
const css = `
.p-virtualscroller { .p-virtualscroller {
position: relative; position: relative;
overflow: auto; overflow: auto;
@ -35,8 +48,6 @@ const theme = ({ dt }) => `
left: 0; left: 0;
width: 100%; width: 100%;
height: 100%; height: 100%;
background: ${dt('virtualscroller.loader.mask.background')};
color: ${dt('virtualscroller.loader.mask.color')};
} }
.p-virtualscroller-loader-mask { .p-virtualscroller-loader-mask {
@ -45,12 +56,6 @@ const theme = ({ dt }) => `
justify-content: center; justify-content: center;
} }
.p-virtualscroller-loading-icon {
font-size: ${dt('virtualscroller.loader.icon.size')};
width: ${dt('virtualscroller.loader.icon.size')};
height: ${dt('virtualscroller.loader.icon.size')};
}
.p-virtualscroller-horizontal > .p-virtualscroller-content { .p-virtualscroller-horizontal > .p-virtualscroller-content {
display: flex; display: flex;
} }
@ -62,5 +67,6 @@ const theme = ({ dt }) => `
export default BaseStyle.extend({ export default BaseStyle.extend({
name: 'virtualscroller', name: 'virtualscroller',
css,
theme theme
}); });