@po-ui/ng-components 21.23.1 → 21.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/po-ui-ng-components.mjs +87 -44
- package/fesm2022/po-ui-ng-components.mjs.map +1 -1
- package/lib/components/po-button-group/po-button-group.component.d.ts +5 -0
- package/lib/components/po-helper/po-helper.component.d.ts +0 -1
- package/lib/components/po-list-view/po-list-view.component.d.ts +2 -3
- package/lib/components/po-page/po-page-content/po-page-content.component.d.ts +1 -0
- package/lib/components/po-popover/po-popover-base.component.d.ts +12 -0
- package/lib/components/po-popover/po-popover.component.d.ts +1 -0
- package/lib/components/po-table/po-table.component.d.ts +1 -0
- package/package.json +8 -7
- package/po-ui-ng-components-21.25.0.tgz +0 -0
- package/schematics/ng-add/index.js +1 -1
- package/schematics/ng-update/v14/index.js +1 -1
- package/schematics/ng-update/v15/index.js +1 -1
- package/schematics/ng-update/v16/index.js +1 -1
- package/schematics/ng-update/v17/index.js +1 -1
- package/schematics/ng-update/v18/index.js +2 -2
- package/schematics/ng-update/v19/index.js +2 -2
- package/schematics/ng-update/v2/index.js +1 -1
- package/schematics/ng-update/v20/index.js +2 -2
- package/schematics/ng-update/v21/index.js +1 -1
- package/schematics/ng-update/v3/index.js +1 -1
- package/schematics/ng-update/v4/index.js +1 -1
- package/schematics/ng-update/v5/index.js +1 -1
- package/schematics/ng-update/v6/index.js +1 -1
- package/types/po-ui-ng-components.d.ts +23 -5
- package/po-ui-ng-components-21.23.1.tgz +0 -0
|
@@ -7012,6 +7012,18 @@ class PoPopoverBaseComponent {
|
|
|
7012
7012
|
appendBox = false;
|
|
7013
7013
|
// Indica se o elemento filho será alinhado nos cantos do elemento pai.
|
|
7014
7014
|
cornerAligned = false;
|
|
7015
|
+
/**
|
|
7016
|
+
* @optional
|
|
7017
|
+
*
|
|
7018
|
+
* @description
|
|
7019
|
+
*
|
|
7020
|
+
* Define o espaçamento (em pixels) entre o componente alvo (`p-target`) e o `po-popover`.
|
|
7021
|
+
* Útil para componentes com targets pequenos (como ícones) onde o espaçamento padrão é
|
|
7022
|
+
* proporcionalmente muito grande e cria desalinhamento visual.
|
|
7023
|
+
*
|
|
7024
|
+
* @default `8`
|
|
7025
|
+
*/
|
|
7026
|
+
offset = 8;
|
|
7015
7027
|
/**
|
|
7016
7028
|
* @description
|
|
7017
7029
|
*
|
|
@@ -7150,7 +7162,7 @@ class PoPopoverBaseComponent {
|
|
|
7150
7162
|
*/
|
|
7151
7163
|
customClasses = input(undefined, { ...(ngDevMode ? { debugName: "customClasses" } : /* istanbul ignore next */ {}), alias: 'p-custom-classes' });
|
|
7152
7164
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoPopoverBaseComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
7153
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.18", type: PoPopoverBaseComponent, isStandalone: false, selector: "po-popover-base", inputs: { appendBox: { classPropertyName: "appendBox", publicName: "p-append-in-body", isSignal: false, isRequired: false, transformFunction: convertToBoolean }, cornerAligned: { classPropertyName: "cornerAligned", publicName: "p-corner-aligned", isSignal: false, isRequired: false, transformFunction: null }, target: { classPropertyName: "target", publicName: "p-target", isSignal: false, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "p-title", isSignal: false, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "p-width", isSignal: false, isRequired: false, transformFunction: null }, hideArrow: { classPropertyName: "hideArrow", publicName: "p-hide-arrow", isSignal: false, isRequired: false, transformFunction: null }, position: { classPropertyName: "position", publicName: "p-position", isSignal: false, isRequired: false, transformFunction: null }, trigger: { classPropertyName: "trigger", publicName: "p-trigger", isSignal: false, isRequired: false, transformFunction: null }, customClasses: { classPropertyName: "customClasses", publicName: "p-custom-classes", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closePopover: "p-close", openPopover: "p-open" }, ngImport: i0, template: '', isInline: true });
|
|
7165
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.18", type: PoPopoverBaseComponent, isStandalone: false, selector: "po-popover-base", inputs: { appendBox: { classPropertyName: "appendBox", publicName: "p-append-in-body", isSignal: false, isRequired: false, transformFunction: convertToBoolean }, cornerAligned: { classPropertyName: "cornerAligned", publicName: "p-corner-aligned", isSignal: false, isRequired: false, transformFunction: null }, offset: { classPropertyName: "offset", publicName: "p-offset", isSignal: false, isRequired: false, transformFunction: null }, target: { classPropertyName: "target", publicName: "p-target", isSignal: false, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "p-title", isSignal: false, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "p-width", isSignal: false, isRequired: false, transformFunction: null }, hideArrow: { classPropertyName: "hideArrow", publicName: "p-hide-arrow", isSignal: false, isRequired: false, transformFunction: null }, position: { classPropertyName: "position", publicName: "p-position", isSignal: false, isRequired: false, transformFunction: null }, trigger: { classPropertyName: "trigger", publicName: "p-trigger", isSignal: false, isRequired: false, transformFunction: null }, customClasses: { classPropertyName: "customClasses", publicName: "p-custom-classes", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closePopover: "p-close", openPopover: "p-open" }, ngImport: i0, template: '', isInline: true });
|
|
7154
7166
|
}
|
|
7155
7167
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoPopoverBaseComponent, decorators: [{
|
|
7156
7168
|
type: Component,
|
|
@@ -7165,6 +7177,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
7165
7177
|
}], cornerAligned: [{
|
|
7166
7178
|
type: Input,
|
|
7167
7179
|
args: ['p-corner-aligned']
|
|
7180
|
+
}], offset: [{
|
|
7181
|
+
type: Input,
|
|
7182
|
+
args: ['p-offset']
|
|
7168
7183
|
}], target: [{
|
|
7169
7184
|
type: Input,
|
|
7170
7185
|
args: ['p-target']
|
|
@@ -7316,6 +7331,7 @@ class PoPopoverComponent extends PoPopoverBaseComponent {
|
|
|
7316
7331
|
}
|
|
7317
7332
|
showPopover() {
|
|
7318
7333
|
requestAnimationFrame(() => {
|
|
7334
|
+
this.stabilizePopoverWidth();
|
|
7319
7335
|
this.setElementsControlPosition();
|
|
7320
7336
|
this.setPopoverPosition();
|
|
7321
7337
|
this.setOpacity(1);
|
|
@@ -7324,6 +7340,40 @@ class PoPopoverComponent extends PoPopoverBaseComponent {
|
|
|
7324
7340
|
this.cd.detectChanges();
|
|
7325
7341
|
});
|
|
7326
7342
|
}
|
|
7343
|
+
stabilizePopoverWidth() {
|
|
7344
|
+
if (this.width != null || this.widthPopover != null)
|
|
7345
|
+
return;
|
|
7346
|
+
const el = this.popoverElement?.nativeElement;
|
|
7347
|
+
const target = this.targetElement;
|
|
7348
|
+
if (!el || !target)
|
|
7349
|
+
return;
|
|
7350
|
+
el.style.left = '0px';
|
|
7351
|
+
el.style.top = '0px';
|
|
7352
|
+
const natural = el.getBoundingClientRect().width;
|
|
7353
|
+
const tRect = target.getBoundingClientRect();
|
|
7354
|
+
const cx = tRect.left + tRect.width / 2;
|
|
7355
|
+
const halfTarget = tRect.width / 2;
|
|
7356
|
+
const vp = window.innerWidth;
|
|
7357
|
+
const safety = 2;
|
|
7358
|
+
const candidates = [];
|
|
7359
|
+
if (cx + 15 <= vp)
|
|
7360
|
+
candidates.push(cx + 15 - safety);
|
|
7361
|
+
if (cx - 15 >= 0)
|
|
7362
|
+
candidates.push(vp - cx + 15 - safety);
|
|
7363
|
+
const centered = 2 * Math.min(cx, vp - cx) - safety;
|
|
7364
|
+
if (centered > 0)
|
|
7365
|
+
candidates.push(centered);
|
|
7366
|
+
const leftMax = cx - halfTarget - this.offset - safety;
|
|
7367
|
+
if (leftMax > 0)
|
|
7368
|
+
candidates.push(leftMax);
|
|
7369
|
+
const rightMax = vp - cx - halfTarget - this.offset - safety;
|
|
7370
|
+
if (rightMax > 0)
|
|
7371
|
+
candidates.push(rightMax);
|
|
7372
|
+
const minWidth = 240;
|
|
7373
|
+
const maxFit = candidates.length ? Math.max(...candidates) : natural;
|
|
7374
|
+
this.widthPopover = Math.max(minWidth, Math.min(natural, maxFit));
|
|
7375
|
+
this.cd.detectChanges();
|
|
7376
|
+
}
|
|
7327
7377
|
ensurePopoverPosition() {
|
|
7328
7378
|
setTimeout(() => {
|
|
7329
7379
|
this.setElementsControlPosition();
|
|
@@ -7408,8 +7458,7 @@ class PoPopoverComponent extends PoPopoverBaseComponent {
|
|
|
7408
7458
|
this.keydownPopoverListener?.();
|
|
7409
7459
|
}
|
|
7410
7460
|
setElementsControlPosition() {
|
|
7411
|
-
|
|
7412
|
-
this.poControlPosition.setElements(this.popoverElement.nativeElement, popoverOffset, this.target, undefined, false, this.cornerAligned);
|
|
7461
|
+
this.poControlPosition.setElements(this.popoverElement.nativeElement, this.offset, this.target, undefined, false, this.cornerAligned);
|
|
7413
7462
|
}
|
|
7414
7463
|
focusOnTarget() {
|
|
7415
7464
|
const el = this.targetElement;
|
|
@@ -7518,10 +7567,10 @@ class PoPopoverComponent extends PoPopoverBaseComponent {
|
|
|
7518
7567
|
this.disconnectResizeObserver();
|
|
7519
7568
|
if (!this.popoverElement?.nativeElement)
|
|
7520
7569
|
return;
|
|
7521
|
-
let
|
|
7570
|
+
let baselineFired = false;
|
|
7522
7571
|
this.resizeObserver = new ResizeObserver(() => {
|
|
7523
|
-
if (
|
|
7524
|
-
|
|
7572
|
+
if (!baselineFired) {
|
|
7573
|
+
baselineFired = true;
|
|
7525
7574
|
return;
|
|
7526
7575
|
}
|
|
7527
7576
|
this.setElementsControlPosition();
|
|
@@ -7613,21 +7662,6 @@ class PoHelperComponent extends PoHelperBaseComponent {
|
|
|
7613
7662
|
}
|
|
7614
7663
|
ngAfterViewInit() {
|
|
7615
7664
|
PoHelperComponent.instances.push(this);
|
|
7616
|
-
queueMicrotask(() => {
|
|
7617
|
-
this.setPopoverPositionByScreen();
|
|
7618
|
-
});
|
|
7619
|
-
}
|
|
7620
|
-
setPopoverPositionByScreen() {
|
|
7621
|
-
if (!this.target?.nativeElement)
|
|
7622
|
-
return;
|
|
7623
|
-
const rect = this.target.nativeElement.getBoundingClientRect();
|
|
7624
|
-
const screenWidth = window.innerWidth || document.documentElement.clientWidth;
|
|
7625
|
-
if (rect.right + 400 > screenWidth) {
|
|
7626
|
-
this.popoverPosition = 'left';
|
|
7627
|
-
}
|
|
7628
|
-
else {
|
|
7629
|
-
this.popoverPosition = 'right';
|
|
7630
|
-
}
|
|
7631
7665
|
}
|
|
7632
7666
|
ngOnChanges(changes) {
|
|
7633
7667
|
if (changes.size) {
|
|
@@ -7748,11 +7782,11 @@ class PoHelperComponent extends PoHelperBaseComponent {
|
|
|
7748
7782
|
}
|
|
7749
7783
|
}
|
|
7750
7784
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoHelperComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
7751
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: PoHelperComponent, isStandalone: false, selector: "po-helper", viewQueries: [{ propertyName: "target", first: true, predicate: ["target"], descendants: true, read: ElementRef, static: true }, { propertyName: "popover", first: true, predicate: ["popover"], descendants: true }, { propertyName: "poButton", first: true, predicate: PoButtonComponent, descendants: true, read: ElementRef, static: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div\n class=\"po-helper-container po-helper-target\"\n #target\n [attr.tabindex]=\"disabled() ? null : 0\"\n role=\"button\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-haspopup]=\"'dialog'\"\n [attr.aria-expanded]=\"!popover.isHidden\"\n [attr.aria-controls]=\"'popover-content-' + id\"\n [attr.aria-describedby]=\"!popover.isHidden ? 'popover-content-' + id : null\"\n [class.po-helper-disabled]=\"disabled()\"\n (keydown)=\"onKeyDown($event)\"\n (click)=\"openHelperPopover(); emitClick($event)
|
|
7785
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: PoHelperComponent, isStandalone: false, selector: "po-helper", viewQueries: [{ propertyName: "target", first: true, predicate: ["target"], descendants: true, read: ElementRef, static: true }, { propertyName: "popover", first: true, predicate: ["popover"], descendants: true }, { propertyName: "poButton", first: true, predicate: PoButtonComponent, descendants: true, read: ElementRef, static: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div\n class=\"po-helper-container po-helper-target\"\n #target\n [attr.tabindex]=\"disabled() ? null : 0\"\n role=\"button\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-haspopup]=\"'dialog'\"\n [attr.aria-expanded]=\"!popover.isHidden\"\n [attr.aria-controls]=\"'popover-content-' + id\"\n [attr.aria-describedby]=\"!popover.isHidden ? 'popover-content-' + id : null\"\n [class.po-helper-disabled]=\"disabled()\"\n (keydown)=\"onKeyDown($event)\"\n (click)=\"openHelperPopover(); emitClick($event)\"\n>\n <po-icon [p-icon]=\"helper()?.type === 'info' ? 'ICON_INFO' : 'ICON_HELP'\"></po-icon>\n <po-popover\n #popover\n [p-position]=\"popoverPosition\"\n [p-target]=\"target\"\n [p-title]=\"helper()?.title\"\n [p-append-in-body]=\"appendBox()\"\n [p-offset]=\"8\"\n p-custom-classes=\"po-helper-popover\"\n p-trigger=\"function\"\n (p-close)=\"handleClose()\"\n (p-open)=\"handleOpen()\"\n >\n <div [id]=\"'popover-content-' + id\" role=\"dialog\" aria-modal=\"false\" tabindex=\"-1\">\n <span class=\"po-helper-content-text\">\n @for (fragment of contentFragments(); track $index) {\n <span\n [class.po-text-bold]=\"fragment.bold\"\n [class.po-text-italic]=\"fragment.italic\"\n [class.po-text-underline]=\"fragment.underline\"\n >{{ fragment.text }}</span\n >\n }\n </span>\n @if (helper()?.type === 'help' && helper()?.footerAction) {\n <po-divider></po-divider>\n <po-link\n class=\"po-helper-footer-action-link\"\n (keydown.enter)=\"$event.stopPropagation()\"\n (keydown.space)=\"$event.stopPropagation()\"\n (p-action)=\"helper()?.footerAction?.action()\"\n [p-label]=\"helper()?.footerAction?.label\"\n >\n </po-link>\n }\n </div>\n </po-popover>\n</div>\n", dependencies: [{ kind: "component", type: PoIconComponent, selector: "po-icon", inputs: ["p-icon"] }, { kind: "component", type: PoPopoverComponent, selector: "po-popover" }, { kind: "component", type: PoLinkComponent, selector: "po-link" }, { kind: "component", type: PoDividerComponent, selector: "po-divider" }] });
|
|
7752
7786
|
}
|
|
7753
7787
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoHelperComponent, decorators: [{
|
|
7754
7788
|
type: Component,
|
|
7755
|
-
args: [{ selector: 'po-helper', standalone: false, template: "<div\n class=\"po-helper-container po-helper-target\"\n #target\n [attr.tabindex]=\"disabled() ? null : 0\"\n role=\"button\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-haspopup]=\"'dialog'\"\n [attr.aria-expanded]=\"!popover.isHidden\"\n [attr.aria-controls]=\"'popover-content-' + id\"\n [attr.aria-describedby]=\"!popover.isHidden ? 'popover-content-' + id : null\"\n [class.po-helper-disabled]=\"disabled()\"\n (keydown)=\"onKeyDown($event)\"\n (click)=\"openHelperPopover(); emitClick($event)
|
|
7789
|
+
args: [{ selector: 'po-helper', standalone: false, template: "<div\n class=\"po-helper-container po-helper-target\"\n #target\n [attr.tabindex]=\"disabled() ? null : 0\"\n role=\"button\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-haspopup]=\"'dialog'\"\n [attr.aria-expanded]=\"!popover.isHidden\"\n [attr.aria-controls]=\"'popover-content-' + id\"\n [attr.aria-describedby]=\"!popover.isHidden ? 'popover-content-' + id : null\"\n [class.po-helper-disabled]=\"disabled()\"\n (keydown)=\"onKeyDown($event)\"\n (click)=\"openHelperPopover(); emitClick($event)\"\n>\n <po-icon [p-icon]=\"helper()?.type === 'info' ? 'ICON_INFO' : 'ICON_HELP'\"></po-icon>\n <po-popover\n #popover\n [p-position]=\"popoverPosition\"\n [p-target]=\"target\"\n [p-title]=\"helper()?.title\"\n [p-append-in-body]=\"appendBox()\"\n [p-offset]=\"8\"\n p-custom-classes=\"po-helper-popover\"\n p-trigger=\"function\"\n (p-close)=\"handleClose()\"\n (p-open)=\"handleOpen()\"\n >\n <div [id]=\"'popover-content-' + id\" role=\"dialog\" aria-modal=\"false\" tabindex=\"-1\">\n <span class=\"po-helper-content-text\">\n @for (fragment of contentFragments(); track $index) {\n <span\n [class.po-text-bold]=\"fragment.bold\"\n [class.po-text-italic]=\"fragment.italic\"\n [class.po-text-underline]=\"fragment.underline\"\n >{{ fragment.text }}</span\n >\n }\n </span>\n @if (helper()?.type === 'help' && helper()?.footerAction) {\n <po-divider></po-divider>\n <po-link\n class=\"po-helper-footer-action-link\"\n (keydown.enter)=\"$event.stopPropagation()\"\n (keydown.space)=\"$event.stopPropagation()\"\n (p-action)=\"helper()?.footerAction?.action()\"\n [p-label]=\"helper()?.footerAction?.label\"\n >\n </po-link>\n }\n </div>\n </po-popover>\n</div>\n" }]
|
|
7756
7790
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { target: [{
|
|
7757
7791
|
type: ViewChild,
|
|
7758
7792
|
args: ['target', { read: ElementRef, static: true }]
|
|
@@ -9734,6 +9768,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
9734
9768
|
* <file name="sample-po-button-group-attendance/sample-po-button-group-attendance.component.ts"> </file>
|
|
9735
9769
|
* </example>
|
|
9736
9770
|
*
|
|
9771
|
+
* <example name="po-button-group-opening-service-ticket" title="PO Button Group - Opening Service Ticket">
|
|
9772
|
+
* <file name="sample-po-button-group-opening-service-ticket/sample-po-button-group-opening-service-ticket.component.html"> </file>
|
|
9773
|
+
* <file name="sample-po-button-group-opening-service-ticket/sample-po-button-group-opening-service-ticket.component.ts"> </file>
|
|
9774
|
+
* </example>
|
|
9775
|
+
*
|
|
9737
9776
|
* <example name="po-button-group-post" title="PO Button Group - Post">
|
|
9738
9777
|
* <file name="sample-po-button-group-post/sample-po-button-group-post.component.html"> </file>
|
|
9739
9778
|
* <file name="sample-po-button-group-post/sample-po-button-group-post.component.ts"> </file>
|
|
@@ -9741,11 +9780,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
9741
9780
|
*/
|
|
9742
9781
|
class PoButtonGroupComponent extends PoButtonGroupBaseComponent {
|
|
9743
9782
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoButtonGroupComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
9744
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: PoButtonGroupComponent, isStandalone: false, selector: "po-button-group", usesInheritance: true, ngImport: i0, template: "<div class=\"po-button-group-container\">\n @for (button of buttons(); track button; let i = $index) {\n <po-button\n class=\"po-sm-12 po-button-group\"\n [class.po-button-group-button-selected]=\"button.selected\"\n [class.po-button-group-disabled]=\"button.disabled\"\n
|
|
9783
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: PoButtonGroupComponent, isStandalone: false, selector: "po-button-group", usesInheritance: true, ngImport: i0, template: "<div class=\"po-button-group-container\">\n @for (button of buttons(); track button; let i = $index) {\n <po-button\n class=\"po-sm-12 po-button-group\"\n [class.po-button-group-button-selected]=\"button.selected\"\n [class.po-button-group-disabled]=\"button.disabled\"\n [p-disabled]=\"button.disabled\"\n [p-icon]=\"button.icon\"\n [p-label]=\"button.label\"\n [p-size]=\"size\"\n [p-tooltip]=\"!button.disabled ? button.tooltip : undefined\"\n p-tooltip-position=\"bottom\"\n [p-append-in-body]=\"true\"\n (p-click)=\"onButtonClick(button, i); button.action(button)\"\n >\n </po-button>\n }\n</div>\n", dependencies: [{ kind: "component", type: PoButtonComponent, selector: "po-button" }, { kind: "directive", type: PoTooltipDirective, selector: "[p-tooltip]" }] });
|
|
9745
9784
|
}
|
|
9746
9785
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoButtonGroupComponent, decorators: [{
|
|
9747
9786
|
type: Component,
|
|
9748
|
-
args: [{ selector: 'po-button-group', standalone: false, template: "<div class=\"po-button-group-container\">\n @for (button of buttons(); track button; let i = $index) {\n <po-button\n class=\"po-sm-12 po-button-group\"\n [class.po-button-group-button-selected]=\"button.selected\"\n [class.po-button-group-disabled]=\"button.disabled\"\n
|
|
9787
|
+
args: [{ selector: 'po-button-group', standalone: false, template: "<div class=\"po-button-group-container\">\n @for (button of buttons(); track button; let i = $index) {\n <po-button\n class=\"po-sm-12 po-button-group\"\n [class.po-button-group-button-selected]=\"button.selected\"\n [class.po-button-group-disabled]=\"button.disabled\"\n [p-disabled]=\"button.disabled\"\n [p-icon]=\"button.icon\"\n [p-label]=\"button.label\"\n [p-size]=\"size\"\n [p-tooltip]=\"!button.disabled ? button.tooltip : undefined\"\n p-tooltip-position=\"bottom\"\n [p-append-in-body]=\"true\"\n (p-click)=\"onButtonClick(button, i); button.action(button)\"\n >\n </po-button>\n }\n</div>\n" }]
|
|
9749
9788
|
}] });
|
|
9750
9789
|
|
|
9751
9790
|
/**
|
|
@@ -17556,7 +17595,7 @@ class PoChartGridUtils {
|
|
|
17556
17595
|
left: this.component.options?.axis?.paddingLeft || 16,
|
|
17557
17596
|
right: this.component.options?.axis?.paddingRight || 32,
|
|
17558
17597
|
bottom: this.component.options?.axis?.paddingBottom || paddingBottom,
|
|
17559
|
-
|
|
17598
|
+
outerBoundsMode: 'same',
|
|
17560
17599
|
borderWidth: tokenBorderWidthSm
|
|
17561
17600
|
};
|
|
17562
17601
|
}
|
|
@@ -17623,7 +17662,6 @@ class PoChartGridUtils {
|
|
|
17623
17662
|
realtime: true,
|
|
17624
17663
|
bottom: this.component.options?.bottomDataZoom || 'calc(100%)',
|
|
17625
17664
|
height: 25,
|
|
17626
|
-
right: this.component.options?.axis?.paddingRight || 32,
|
|
17627
17665
|
xAxisIndex: [0]
|
|
17628
17666
|
},
|
|
17629
17667
|
{
|
|
@@ -25312,8 +25350,8 @@ class PoDialogService extends PoDialogBaseService {
|
|
|
25312
25350
|
}
|
|
25313
25351
|
openDialog(dialogType, dialogOptions) {
|
|
25314
25352
|
const componentRef = this.poComponentInjector.createComponentInApplication(PoDialogComponent);
|
|
25315
|
-
componentRef.changeDetectorRef.detectChanges();
|
|
25316
25353
|
componentRef.instance.open(dialogOptions, dialogType, componentRef);
|
|
25354
|
+
componentRef.changeDetectorRef.detectChanges();
|
|
25317
25355
|
}
|
|
25318
25356
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoDialogService, deps: [{ token: PoComponentInjectorService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
25319
25357
|
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoDialogService, providedIn: 'root' });
|
|
@@ -41802,6 +41840,7 @@ class PoTableComponent extends PoTableBaseComponent {
|
|
|
41802
41840
|
this.changeHeaderWidth();
|
|
41803
41841
|
this.changeSizeLoading();
|
|
41804
41842
|
this.applyFixedColumns();
|
|
41843
|
+
this.initializeVisibleElement();
|
|
41805
41844
|
}
|
|
41806
41845
|
showMoreInfiniteScroll({ target }) {
|
|
41807
41846
|
const scrollPosition = target.offsetHeight + target.scrollTop;
|
|
@@ -41815,10 +41854,8 @@ class PoTableComponent extends PoTableBaseComponent {
|
|
|
41815
41854
|
this.verifyCalculateHeightTableContainer();
|
|
41816
41855
|
// Permite que os cabeçalhos sejam calculados na primeira vez que o componente torna-se visível,
|
|
41817
41856
|
// evitando com isso, problemas com Tabs ou Divs que iniciem escondidas.
|
|
41818
|
-
if (this.
|
|
41819
|
-
this.
|
|
41820
|
-
this.checkInfiniteScroll();
|
|
41821
|
-
this.visibleElement = true;
|
|
41857
|
+
if (this.initialized) {
|
|
41858
|
+
this.initializeVisibleElement();
|
|
41822
41859
|
}
|
|
41823
41860
|
}
|
|
41824
41861
|
ngOnDestroy() {
|
|
@@ -42400,6 +42437,7 @@ class PoTableComponent extends PoTableBaseComponent {
|
|
|
42400
42437
|
this.timeoutResize = setTimeout(() => {
|
|
42401
42438
|
// show the table
|
|
42402
42439
|
this.setTableOpacity(1);
|
|
42440
|
+
this.changeDetector.markForCheck();
|
|
42403
42441
|
});
|
|
42404
42442
|
}
|
|
42405
42443
|
deleteItemsLocal(newItems, newItemsFiltered) {
|
|
@@ -42484,6 +42522,13 @@ class PoTableComponent extends PoTableBaseComponent {
|
|
|
42484
42522
|
});
|
|
42485
42523
|
return mergedIcons;
|
|
42486
42524
|
}
|
|
42525
|
+
initializeVisibleElement() {
|
|
42526
|
+
if (this.tableWrapperElement?.nativeElement.offsetWidth && !this.visibleElement) {
|
|
42527
|
+
this.debounceResize();
|
|
42528
|
+
this.checkInfiniteScroll();
|
|
42529
|
+
this.visibleElement = true;
|
|
42530
|
+
}
|
|
42531
|
+
}
|
|
42487
42532
|
removeListeners() {
|
|
42488
42533
|
if (this.resizeListener) {
|
|
42489
42534
|
this.resizeListener();
|
|
@@ -60143,6 +60188,7 @@ class PoListViewComponent extends PoListViewBaseComponent {
|
|
|
60143
60188
|
listViewContentTemplate;
|
|
60144
60189
|
listViewDetailTemplate;
|
|
60145
60190
|
poPopupComponent;
|
|
60191
|
+
popupActions = [];
|
|
60146
60192
|
differ;
|
|
60147
60193
|
constructor() {
|
|
60148
60194
|
const differs = inject(IterableDiffers);
|
|
@@ -60159,19 +60205,9 @@ class PoListViewComponent extends PoListViewBaseComponent {
|
|
|
60159
60205
|
get displayShowMoreButton() {
|
|
60160
60206
|
return this.items && this.items.length > 0 && this.showMore.observers.length > 0;
|
|
60161
60207
|
}
|
|
60162
|
-
get showButtonsActions() {
|
|
60163
|
-
return this.visibleActions && this.visibleActions.length > 0 && this.visibleActions.length <= 2;
|
|
60164
|
-
}
|
|
60165
|
-
get showPopupActions() {
|
|
60166
|
-
return this.visibleActions && this.visibleActions.length > 2;
|
|
60167
|
-
}
|
|
60168
60208
|
get titleHasAction() {
|
|
60169
60209
|
return this.titleAction.observers.length > 0;
|
|
60170
60210
|
}
|
|
60171
|
-
get visibleActions() {
|
|
60172
|
-
return (this.actions &&
|
|
60173
|
-
this.actions.filter(action => this.returnBooleanValue(action, action.visible, 'visible') !== false));
|
|
60174
|
-
}
|
|
60175
60211
|
ngAfterContentInit() {
|
|
60176
60212
|
this.initShowDetail();
|
|
60177
60213
|
}
|
|
@@ -60202,12 +60238,17 @@ class PoListViewComponent extends PoListViewBaseComponent {
|
|
|
60202
60238
|
}
|
|
60203
60239
|
togglePopup(item, targetRef) {
|
|
60204
60240
|
this.popupTarget = targetRef;
|
|
60241
|
+
this.popupActions = this.getVisibleActions(item);
|
|
60205
60242
|
this.changeDetector.detectChanges();
|
|
60206
60243
|
this.poPopupComponent.toggle(item);
|
|
60207
60244
|
}
|
|
60208
60245
|
onAnimationEvent(event, detail) {
|
|
60209
60246
|
this.showDetail.emit(detail);
|
|
60210
60247
|
}
|
|
60248
|
+
// Avalia a visibilidade das ações por item, passando o item corrente.
|
|
60249
|
+
getVisibleActions(item) {
|
|
60250
|
+
return this.actions?.filter(action => this.returnBooleanValue(action, item, 'visible') !== false) ?? [];
|
|
60251
|
+
}
|
|
60211
60252
|
checkItemsChange() {
|
|
60212
60253
|
const changesItems = this.differ.diff(this.items);
|
|
60213
60254
|
if (changesItems && this.selectAll) {
|
|
@@ -60223,7 +60264,7 @@ class PoListViewComponent extends PoListViewBaseComponent {
|
|
|
60223
60264
|
}
|
|
60224
60265
|
}
|
|
60225
60266
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: PoListViewComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
60226
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: PoListViewComponent, isStandalone: false, selector: "po-list-view", queries: [{ propertyName: "listViewContentTemplate", first: true, predicate: PoListViewContentTemplateDirective, descendants: true, static: true }, { propertyName: "listViewDetailTemplate", first: true, predicate: PoListViewDetailTemplateDirective, descendants: true, static: true }], viewQueries: [{ propertyName: "poPopupComponent", first: true, predicate: ["popup"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<div\n [class.po-list-view-main-container-header]=\"showHeader\"\n [class.po-list-view-main-container]=\"!showHeader\"\n [style.height.px]=\"height\"\n>\n @if (showHeader) {\n <div class=\"po-list-view-main-header\">\n <div class=\"po-checkbox-group-item\">\n <div class=\"po-list-view-main-select\">\n <po-checkbox\n name=\"selectAll\"\n [(ngModel)]=\"selectAll\"\n [p-label]=\"literals.selectAll\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectAllListItems()\"\n (click)=\"selectAllListItems()\"\n ></po-checkbox>\n </div>\n </div>\n </div>\n }\n\n <div class=\"po-list-view-main-content\">\n @if (!hasItems()) {\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container-no-data po-text-center\">\n <span> {{ literals.noData }} </span>\n </div>\n </po-container>\n }\n\n @for (item of items; track trackBy($index); let index = $index) {\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container\">\n <div class=\"po-list-view-header\">\n <div class=\"po-list-view-title\" [ngSwitch]=\"checkTitleType(item)\">\n @if (select) {\n <div class=\"po-list-view-select\">\n <po-checkbox\n [(ngModel)]=\"item.$selected\"\n name=\"checkbox\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectListItem(item)\"\n (click)=\"selectListItem(item)\"\n ></po-checkbox>\n </div>\n }\n\n <a\n *ngSwitchCase=\"'externalLink'\"\n class=\"po-list-view-title-link\"\n target=\"_blank\"\n [href]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <a\n *ngSwitchCase=\"'internalLink'\"\n class=\"po-list-view-title-link\"\n [routerLink]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <span\n *ngSwitchCase=\"'noLink'\"\n class=\"po-list-view-title-no-link\"\n [class.po-list-view-title-link]=\"titleHasAction\"\n (click)=\"titleHasAction && runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </span>\n </div>\n\n @if (
|
|
60267
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: PoListViewComponent, isStandalone: false, selector: "po-list-view", queries: [{ propertyName: "listViewContentTemplate", first: true, predicate: PoListViewContentTemplateDirective, descendants: true, static: true }, { propertyName: "listViewDetailTemplate", first: true, predicate: PoListViewDetailTemplateDirective, descendants: true, static: true }], viewQueries: [{ propertyName: "poPopupComponent", first: true, predicate: ["popup"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<div\n [class.po-list-view-main-container-header]=\"showHeader\"\n [class.po-list-view-main-container]=\"!showHeader\"\n [style.height.px]=\"height\"\n>\n @if (showHeader) {\n <div class=\"po-list-view-main-header\">\n <div class=\"po-checkbox-group-item\">\n <div class=\"po-list-view-main-select\">\n <po-checkbox\n name=\"selectAll\"\n [(ngModel)]=\"selectAll\"\n [p-label]=\"literals.selectAll\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectAllListItems()\"\n (click)=\"selectAllListItems()\"\n ></po-checkbox>\n </div>\n </div>\n </div>\n }\n\n <div class=\"po-list-view-main-content\">\n @if (!hasItems()) {\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container-no-data po-text-center\">\n <span> {{ literals.noData }} </span>\n </div>\n </po-container>\n }\n\n @for (item of items; track trackBy($index); let index = $index) {\n @let visibleActionsForItem = getVisibleActions(item);\n\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container\">\n <div class=\"po-list-view-header\">\n <div class=\"po-list-view-title\" [ngSwitch]=\"checkTitleType(item)\">\n @if (select) {\n <div class=\"po-list-view-select\">\n <po-checkbox\n [(ngModel)]=\"item.$selected\"\n name=\"checkbox\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectListItem(item)\"\n (click)=\"selectListItem(item)\"\n ></po-checkbox>\n </div>\n }\n\n <a\n *ngSwitchCase=\"'externalLink'\"\n class=\"po-list-view-title-link\"\n target=\"_blank\"\n [href]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <a\n *ngSwitchCase=\"'internalLink'\"\n class=\"po-list-view-title-link\"\n [routerLink]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <span\n *ngSwitchCase=\"'noLink'\"\n class=\"po-list-view-title-no-link\"\n [class.po-list-view-title-link]=\"titleHasAction\"\n (click)=\"titleHasAction && runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </span>\n </div>\n\n @if (visibleActionsForItem.length > 0 && visibleActionsForItem.length <= 2) {\n <div class=\"po-list-view-actions\">\n @for (action of visibleActionsForItem; track action) {\n <po-button\n [p-disabled]=\"returnBooleanValue(action, item, 'disabled')\"\n [p-icon]=\"action.icon\"\n [p-label]=\"action.label\"\n [p-danger]=\"action.type === 'danger'\"\n [p-size]=\"componentsSize\"\n (p-click)=\"onClickAction(action, item)\"\n >\n </po-button>\n }\n </div>\n }\n\n @if (visibleActionsForItem.length > 2) {\n <div class=\"po-list-view-more-actions\">\n <div #popupTarget class=\"po-list-view-more-icon po-clickable\" (click)=\"togglePopup(item, popupTarget)\">\n <po-icon p-icon=\"ICON_MORE\"></po-icon>\n </div>\n </div>\n }\n </div>\n\n @if (hasContentTemplate) {\n <div class=\"po-list-view-content\">\n <ng-template\n [ngTemplateOutlet]=\"listViewContentTemplate.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: item, index: index }\"\n >\n </ng-template>\n </div>\n }\n\n @if (hasDetailTemplate && item.$showDetail) {\n <div\n @showHideDetail\n (@showHideDetail.start)=\"item.$showDetail ? onAnimationEvent($event, item) : 'undefined'\"\n class=\"po-list-view-detail\"\n >\n <ng-template\n [ngTemplateOutlet]=\"listViewDetailTemplate.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: item, index: index }\"\n >\n </ng-template>\n </div>\n }\n </div>\n\n @if (hasDetailTemplate) {\n <div class=\"po-list-view-detail-button\">\n <po-button\n p-kind=\"tertiary\"\n [p-label]=\"item.$showDetail ? literals.hideDetails : literals.showDetails\"\n [p-size]=\"componentsSize\"\n (p-click)=\"item.$showDetail = !item.$showDetail\"\n >\n </po-button>\n </div>\n }\n </po-container>\n }\n </div>\n</div>\n\n@if (displayShowMoreButton) {\n <div class=\"po-mb-2 po-text-center\">\n <po-button\n [p-disabled]=\"showMoreDisabled\"\n [p-label]=\"literals.loadMoreData\"\n [p-size]=\"componentsSize\"\n (p-click)=\"onShowMore()\"\n >\n </po-button>\n </div>\n}\n\n<po-popup #popup [p-actions]=\"popupActions\" [p-size]=\"componentsSize\" [p-target]=\"popupTarget\"> </po-popup>\n", dependencies: [{ kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1$1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: PoButtonComponent, selector: "po-button" }, { kind: "component", type: PoIconComponent, selector: "po-icon", inputs: ["p-icon"] }, { kind: "component", type: PoPopupComponent, selector: "po-popup" }, { kind: "component", type: PoCheckboxComponent, selector: "po-checkbox" }, { kind: "component", type: PoContainerComponent, selector: "po-container" }], animations: [
|
|
60227
60268
|
trigger('showHideDetail', [
|
|
60228
60269
|
state('*', style({ 'overflow-y': 'visible' })),
|
|
60229
60270
|
state('void', style({ 'overflow-y': 'hidden' })),
|
|
@@ -60241,7 +60282,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
60241
60282
|
transition('* => void', [style({ height: '*', 'overflow-y': 'hidden' }), animate(100, style({ height: 0 }))]),
|
|
60242
60283
|
transition('void => *', [style({ height: '0' }), animate(100, style({ height: '*' }))])
|
|
60243
60284
|
])
|
|
60244
|
-
], standalone: false, template: "<div\n [class.po-list-view-main-container-header]=\"showHeader\"\n [class.po-list-view-main-container]=\"!showHeader\"\n [style.height.px]=\"height\"\n>\n @if (showHeader) {\n <div class=\"po-list-view-main-header\">\n <div class=\"po-checkbox-group-item\">\n <div class=\"po-list-view-main-select\">\n <po-checkbox\n name=\"selectAll\"\n [(ngModel)]=\"selectAll\"\n [p-label]=\"literals.selectAll\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectAllListItems()\"\n (click)=\"selectAllListItems()\"\n ></po-checkbox>\n </div>\n </div>\n </div>\n }\n\n <div class=\"po-list-view-main-content\">\n @if (!hasItems()) {\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container-no-data po-text-center\">\n <span> {{ literals.noData }} </span>\n </div>\n </po-container>\n }\n\n @for (item of items; track trackBy($index); let index = $index) {\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container\">\n <div class=\"po-list-view-header\">\n <div class=\"po-list-view-title\" [ngSwitch]=\"checkTitleType(item)\">\n @if (select) {\n <div class=\"po-list-view-select\">\n <po-checkbox\n [(ngModel)]=\"item.$selected\"\n name=\"checkbox\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectListItem(item)\"\n (click)=\"selectListItem(item)\"\n ></po-checkbox>\n </div>\n }\n\n <a\n *ngSwitchCase=\"'externalLink'\"\n class=\"po-list-view-title-link\"\n target=\"_blank\"\n [href]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <a\n *ngSwitchCase=\"'internalLink'\"\n class=\"po-list-view-title-link\"\n [routerLink]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <span\n *ngSwitchCase=\"'noLink'\"\n class=\"po-list-view-title-no-link\"\n [class.po-list-view-title-link]=\"titleHasAction\"\n (click)=\"titleHasAction && runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </span>\n </div>\n\n @if (
|
|
60285
|
+
], standalone: false, template: "<div\n [class.po-list-view-main-container-header]=\"showHeader\"\n [class.po-list-view-main-container]=\"!showHeader\"\n [style.height.px]=\"height\"\n>\n @if (showHeader) {\n <div class=\"po-list-view-main-header\">\n <div class=\"po-checkbox-group-item\">\n <div class=\"po-list-view-main-select\">\n <po-checkbox\n name=\"selectAll\"\n [(ngModel)]=\"selectAll\"\n [p-label]=\"literals.selectAll\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectAllListItems()\"\n (click)=\"selectAllListItems()\"\n ></po-checkbox>\n </div>\n </div>\n </div>\n }\n\n <div class=\"po-list-view-main-content\">\n @if (!hasItems()) {\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container-no-data po-text-center\">\n <span> {{ literals.noData }} </span>\n </div>\n </po-container>\n }\n\n @for (item of items; track trackBy($index); let index = $index) {\n @let visibleActionsForItem = getVisibleActions(item);\n\n <po-container [p-no-padding]=\"true\">\n <div class=\"po-list-view-container\">\n <div class=\"po-list-view-header\">\n <div class=\"po-list-view-title\" [ngSwitch]=\"checkTitleType(item)\">\n @if (select) {\n <div class=\"po-list-view-select\">\n <po-checkbox\n [(ngModel)]=\"item.$selected\"\n name=\"checkbox\"\n [p-size]=\"componentsSize\"\n (p-change)=\"selectListItem(item)\"\n (click)=\"selectListItem(item)\"\n ></po-checkbox>\n </div>\n }\n\n <a\n *ngSwitchCase=\"'externalLink'\"\n class=\"po-list-view-title-link\"\n target=\"_blank\"\n [href]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <a\n *ngSwitchCase=\"'internalLink'\"\n class=\"po-list-view-title-link\"\n [routerLink]=\"item[propertyLink]\"\n (click)=\"runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </a>\n <span\n *ngSwitchCase=\"'noLink'\"\n class=\"po-list-view-title-no-link\"\n [class.po-list-view-title-link]=\"titleHasAction\"\n (click)=\"titleHasAction && runTitleAction(item)\"\n >\n {{ getItemTitle(item) }}\n </span>\n </div>\n\n @if (visibleActionsForItem.length > 0 && visibleActionsForItem.length <= 2) {\n <div class=\"po-list-view-actions\">\n @for (action of visibleActionsForItem; track action) {\n <po-button\n [p-disabled]=\"returnBooleanValue(action, item, 'disabled')\"\n [p-icon]=\"action.icon\"\n [p-label]=\"action.label\"\n [p-danger]=\"action.type === 'danger'\"\n [p-size]=\"componentsSize\"\n (p-click)=\"onClickAction(action, item)\"\n >\n </po-button>\n }\n </div>\n }\n\n @if (visibleActionsForItem.length > 2) {\n <div class=\"po-list-view-more-actions\">\n <div #popupTarget class=\"po-list-view-more-icon po-clickable\" (click)=\"togglePopup(item, popupTarget)\">\n <po-icon p-icon=\"ICON_MORE\"></po-icon>\n </div>\n </div>\n }\n </div>\n\n @if (hasContentTemplate) {\n <div class=\"po-list-view-content\">\n <ng-template\n [ngTemplateOutlet]=\"listViewContentTemplate.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: item, index: index }\"\n >\n </ng-template>\n </div>\n }\n\n @if (hasDetailTemplate && item.$showDetail) {\n <div\n @showHideDetail\n (@showHideDetail.start)=\"item.$showDetail ? onAnimationEvent($event, item) : 'undefined'\"\n class=\"po-list-view-detail\"\n >\n <ng-template\n [ngTemplateOutlet]=\"listViewDetailTemplate.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: item, index: index }\"\n >\n </ng-template>\n </div>\n }\n </div>\n\n @if (hasDetailTemplate) {\n <div class=\"po-list-view-detail-button\">\n <po-button\n p-kind=\"tertiary\"\n [p-label]=\"item.$showDetail ? literals.hideDetails : literals.showDetails\"\n [p-size]=\"componentsSize\"\n (p-click)=\"item.$showDetail = !item.$showDetail\"\n >\n </po-button>\n </div>\n }\n </po-container>\n }\n </div>\n</div>\n\n@if (displayShowMoreButton) {\n <div class=\"po-mb-2 po-text-center\">\n <po-button\n [p-disabled]=\"showMoreDisabled\"\n [p-label]=\"literals.loadMoreData\"\n [p-size]=\"componentsSize\"\n (p-click)=\"onShowMore()\"\n >\n </po-button>\n </div>\n}\n\n<po-popup #popup [p-actions]=\"popupActions\" [p-size]=\"componentsSize\" [p-target]=\"popupTarget\"> </po-popup>\n" }]
|
|
60245
60286
|
}], ctorParameters: () => [], propDecorators: { listViewContentTemplate: [{
|
|
60246
60287
|
type: ContentChild,
|
|
60247
60288
|
args: [PoListViewContentTemplateDirective, { static: true }]
|
|
@@ -63063,6 +63104,7 @@ class PoPageContentComponent extends PoPageContentBaseComponent {
|
|
|
63063
63104
|
renderer = inject(Renderer2);
|
|
63064
63105
|
elementRef = inject(ElementRef);
|
|
63065
63106
|
ngZone = inject(NgZone);
|
|
63107
|
+
cd = inject(ChangeDetectorRef);
|
|
63066
63108
|
contentOpacity = 0;
|
|
63067
63109
|
height = '90%';
|
|
63068
63110
|
constructor() {
|
|
@@ -63084,6 +63126,7 @@ class PoPageContentComponent extends PoPageContentBaseComponent {
|
|
|
63084
63126
|
setTimeout(() => {
|
|
63085
63127
|
this.setHeightContent();
|
|
63086
63128
|
this.contentOpacity = 1;
|
|
63129
|
+
this.cd.markForCheck();
|
|
63087
63130
|
});
|
|
63088
63131
|
}
|
|
63089
63132
|
setHeightContent() {
|