From 81af4d277f52114e5498a9cb4dd300a7e26344d7 Mon Sep 17 00:00:00 2001 From: Hugo Graf Date: Tue, 7 Nov 2023 17:37:42 +0100 Subject: [PATCH 1/5] Update contextmenu.ts --- src/app/components/contextmenu/contextmenu.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/components/contextmenu/contextmenu.ts b/src/app/components/contextmenu/contextmenu.ts index 0b593c9e55a..761b7f0870c 100755 --- a/src/app/components/contextmenu/contextmenu.ts +++ b/src/app/components/contextmenu/contextmenu.ts @@ -1150,7 +1150,7 @@ export class ContextMenu implements OnInit, AfterContentInit, OnDestroy { removeAppendedElements() { if (this.appendTo) { - if (this.appendTo === 'body') this.renderer.removeChild(this.document.body, this.containerViewChild.nativeElement); + if (this.appendTo === 'body') this.renderer.removeChild(this.document.body, this.containerViewChild?.nativeElement); else DomHandler.removeChild(this.containerViewChild.nativeElement, this.appendTo); } } From 9343b4131eb76ec81be88a3044a8b7a135a9e17c Mon Sep 17 00:00:00 2001 From: Hugo Graf Date: Mon, 13 Nov 2023 19:22:41 +0100 Subject: [PATCH 2/5] Update contextmenu.ts --- src/app/components/contextmenu/contextmenu.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/app/components/contextmenu/contextmenu.ts b/src/app/components/contextmenu/contextmenu.ts index 761b7f0870c..2891bbf3341 100755 --- a/src/app/components/contextmenu/contextmenu.ts +++ b/src/app/components/contextmenu/contextmenu.ts @@ -1150,8 +1150,11 @@ export class ContextMenu implements OnInit, AfterContentInit, OnDestroy { removeAppendedElements() { if (this.appendTo) { - if (this.appendTo === 'body') this.renderer.removeChild(this.document.body, this.containerViewChild?.nativeElement); - else DomHandler.removeChild(this.containerViewChild.nativeElement, this.appendTo); + if (this.appendTo === 'body') { + if(this.containerViewChild.nativeElement) + this.renderer.removeChild(this.document.body, this.containerViewChild.nativeElement); + } + else DomHandler.removeChild(this.containerViewChild.nativeElement, this.appendTo); } } From 2c9050a2d6d48e2f32a7e8604c1df854c1c036ba Mon Sep 17 00:00:00 2001 From: Hugo Graf Date: Mon, 13 Nov 2023 20:00:43 +0100 Subject: [PATCH 3/5] Fix when nested context menu in nested context is not shown --- src/app/components/contextmenu/contextmenu.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/app/components/contextmenu/contextmenu.ts b/src/app/components/contextmenu/contextmenu.ts index 2891bbf3341..591a98b66bf 100755 --- a/src/app/components/contextmenu/contextmenu.ts +++ b/src/app/components/contextmenu/contextmenu.ts @@ -1151,10 +1151,12 @@ export class ContextMenu implements OnInit, AfterContentInit, OnDestroy { removeAppendedElements() { if (this.appendTo) { if (this.appendTo === 'body') { - if(this.containerViewChild.nativeElement) + if(this.containerViewChild) { this.renderer.removeChild(this.document.body, this.containerViewChild.nativeElement); - } - else DomHandler.removeChild(this.containerViewChild.nativeElement, this.appendTo); + } + } else { + DomHandler.removeChild(this.containerViewChild.nativeElement, this.appendTo); + } } } From 4f03bbfac24b14cb189f1c3dbe51cd596a447fa3 Mon Sep 17 00:00:00 2001 From: Hugo Graf Date: Mon, 13 Nov 2023 20:13:04 +0100 Subject: [PATCH 4/5] Fix: #14006 - 16.7.0: Context Menu with appendTo="body" throws Type Error in a nested Table --- src/app/components/contextmenu/contextmenu.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/app/components/contextmenu/contextmenu.ts b/src/app/components/contextmenu/contextmenu.ts index 591a98b66bf..445e60d9240 100755 --- a/src/app/components/contextmenu/contextmenu.ts +++ b/src/app/components/contextmenu/contextmenu.ts @@ -1150,13 +1150,13 @@ export class ContextMenu implements OnInit, AfterContentInit, OnDestroy { removeAppendedElements() { if (this.appendTo) { - if (this.appendTo === 'body') { - if(this.containerViewChild) { + if (this.appendTo === 'body') { + if(this.containerViewChild) { this.renderer.removeChild(this.document.body, this.containerViewChild.nativeElement); - } - } else { - DomHandler.removeChild(this.containerViewChild.nativeElement, this.appendTo); - } + } + } else { + DomHandler.removeChild(this.containerViewChild.nativeElement, this.appendTo); + } } } From e4f675483eaf8e542c0a0deb170522d7b95bad8f Mon Sep 17 00:00:00 2001 From: Hugo Graf Date: Tue, 14 Nov 2023 08:33:02 +0100 Subject: [PATCH 5/5] Fix template of rowexpanddoc.ts --- src/app/showcase/doc/table/rowexpanddoc.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/showcase/doc/table/rowexpanddoc.ts b/src/app/showcase/doc/table/rowexpanddoc.ts index 8d05367add7..364d69d53f9 100644 --- a/src/app/showcase/doc/table/rowexpanddoc.ts +++ b/src/app/showcase/doc/table/rowexpanddoc.ts @@ -60,7 +60,7 @@ import { ProductService } from '../../service/productservice'; {{ order.id }} {{ order.customer }} - {{ order.id }} + {{ order.date }} {{ order.amount | currency : 'USD' }}