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

Fix: Dropdown(#17039) Virtual Scroll Bug #17044

Closed
wants to merge 9 commits into from
Closed
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
10 changes: 5 additions & 5 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

93 changes: 0 additions & 93 deletions package.json

This file was deleted.

2 changes: 1 addition & 1 deletion src/app/components/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "primeng",
"version": "17.18.12",
"version": "17.18.13",
"repository": {
"type": "git",
"url": "https://github.com/primefaces/primeng"
Expand Down
11 changes: 3 additions & 8 deletions src/app/components/scroller/scroller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -554,12 +554,6 @@ export class Scroller implements OnInit, AfterContentInit, AfterViewChecked, OnD
}
}

if (simpleChanges.items) {
this.setSpacerSize();
this.setSize();
this.cd.detectChanges();
}

if (this.initialized) {
const isChanged = !isLoadingChanged && (simpleChanges.items?.previousValue?.length !== simpleChanges.items?.currentValue?.length || simpleChanges.itemSize || simpleChanges.scrollHeight || simpleChanges.scrollWidth);

Expand Down Expand Up @@ -834,8 +828,6 @@ export class Scroller implements OnInit, AfterContentInit, AfterViewChecked, OnD
contentHeight !== this.defaultContentHeight && ((<ElementRef>this.elementViewChild).nativeElement.style.height = '');

const [width, height] = [DomHandler.getWidth((<ElementRef>this.elementViewChild).nativeElement), DomHandler.getHeight((<ElementRef>this.elementViewChild).nativeElement)];
(this.both || this.horizontal) && ((<ElementRef>this.elementViewChild).nativeElement.style.width = width < <number>this.defaultWidth ? width + 'px' : this._scrollWidth || this.defaultWidth + 'px');
(this.both || this.vertical) && ((<ElementRef>this.elementViewChild).nativeElement.style.height = height < <number>this.defaultHeight ? height + 'px' : this._scrollHeight || this.defaultHeight + 'px');

this.contentEl.style.minHeight = this.contentEl.style.minWidth = '';
this.contentEl.style.position = '';
Expand All @@ -845,6 +837,9 @@ export class Scroller implements OnInit, AfterContentInit, AfterViewChecked, OnD
this.defaultHeight = height;
this.defaultContentWidth = contentWidth;
this.defaultContentHeight = contentHeight;

(this.both || this.horizontal) && ((<ElementRef>this.elementViewChild).nativeElement.style.width = width < <number>this.defaultWidth ? width + 'px' : this._scrollWidth || this.defaultWidth + 'px');
(this.both || this.vertical) && ((<ElementRef>this.elementViewChild).nativeElement.style.height = height < <number>this.defaultHeight ? height + 'px' : this._scrollHeight || this.defaultHeight + 'px');
}
});
}
Expand Down
60 changes: 5 additions & 55 deletions src/app/showcase/data/versions.json
Original file line number Diff line number Diff line change
@@ -1,62 +1,12 @@
[
{
"version": "v17.18.12",
"name": "v17",
"url": "https://primeng.org"
},
{
"version": "v18.0.0",
"version": "v18",
"name": "v18",
"url": "https://v18.primeng.org"
},
{
"version": "v16.9.15-lts",
"name": "v16",
"url": "https://www.primefaces.org/primeng-v16-lts/"
},
{
"version": "v15.4.26-lts",
"name": "v15",
"url": "https://www.primefaces.org/primeng-v15-lts/"
},
{
"version": "v14.2.17-lts",
"name": "v14",
"url": "https://www.primefaces.org/primeng-v14-lts"
},
{
"version": "13.4.5-lts",
"name": "v13",
"url": "https://www.primefaces.org/primeng-v13-lts"
},
{
"version": "12.2.5-lts",
"name": "v12",
"url": "https://www.primefaces.org/primeng-v12-lts"
},
{
"version": "11.4.10-lts",
"name": "v11",
"url": "https://www.primefaces.org/primeng-v11-lts"
},
{
"version": "10.1.5-lts",
"name": "v10",
"url": "https://www.primefaces.org/primeng-v10-lts"
},
{
"version": "9.2.8-lts",
"name": "v9",
"url": "https://www.primefaces.org/primeng-v9-lts"
},
{
"version": "8.2.9-lts",
"name": "v8",
"url": "https://www.primefaces.org/primeng-v8-lts"
"url": "https://primeng.org"
},
{
"version": "7.2.6-lts",
"name": "v7",
"url": "https://www.primefaces.org/primeng-v7-lts"
"version": "v17",
"name": "v17",
"url": "https://v17.primeng.org"
}
]
2 changes: 1 addition & 1 deletion src/app/showcase/layout/doc/codeeditor/templates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export interface Props {
const app_dependencies = pkg ? pkg.devDependencies : {};

const PrimeNG = {
version: '17.18.12',
version: '17.18.13',
description:
'PrimeNG is an open source UI library for Angular featuring a rich set of 80+ components, a theme designer, various theme alternatives such as Material, Bootstrap, Tailwind, premium templates and professional support. In addition, it integrates with PrimeBlock, which has 370+ ready to use UI blocks to build spectacular applications in no time.'
};
Expand Down
2 changes: 1 addition & 1 deletion src/app/showcase/layout/news/app.news.component.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<div *ngIf="isNewsActive" class="layout-news">
<div *ngIf="false" class="layout-news">
<div class="layout-news-container">
<div class="layout-news-content">
<span class="layout-news-text">{{ announcement?.content }}</span>
Expand Down
6 changes: 3 additions & 3 deletions src/app/showcase/layout/news/app.news.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ import { AppConfigService } from '@service/appconfigservice';
imports: [CommonModule, FormsModule, StyleClassModule]
})
export class AppNewsComponent {
storageKey: string = 'primeng';
storageKey: string = 'primeng-v17';

announcement: any;

constructor(
private configService: AppConfigService,
private cd: ChangeDetectorRef
) {
afterNextRender(() => {
/*afterNextRender(() => {
const itemString = localStorage.getItem(this.storageKey);

if (itemString) {
Expand All @@ -38,7 +38,7 @@ export class AppNewsComponent {
this.announcement = News;
}
this.cd.markForCheck();
});
});*/
}

get isNewsActive(): boolean {
Expand Down
Loading