@exhaustive-ui/core 3.0.0-alpha.0 → 3.0.0-alpha.1
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/exhaustive-ui-core-accordion.mjs +51 -78
- package/fesm2022/exhaustive-ui-core-accordion.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-animateonscroll.mjs +72 -73
- package/fesm2022/exhaustive-ui-core-animateonscroll.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-api.mjs +6 -13
- package/fesm2022/exhaustive-ui-core-api.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-autocomplete.mjs +485 -683
- package/fesm2022/exhaustive-ui-core-autocomplete.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-autofocus.mjs +21 -31
- package/fesm2022/exhaustive-ui-core-autofocus.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-avatar.mjs +47 -63
- package/fesm2022/exhaustive-ui-core-avatar.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-badge.mjs +88 -115
- package/fesm2022/exhaustive-ui-core-badge.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-blockui.mjs +58 -91
- package/fesm2022/exhaustive-ui-core-blockui.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-breadcrumb.mjs +155 -169
- package/fesm2022/exhaustive-ui-core-breadcrumb.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-button.mjs +280 -385
- package/fesm2022/exhaustive-ui-core-button.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-carousel.mjs +379 -451
- package/fesm2022/exhaustive-ui-core-carousel.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-cascadeselect.mjs +388 -507
- package/fesm2022/exhaustive-ui-core-cascadeselect.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-chart.mjs +75 -91
- package/fesm2022/exhaustive-ui-core-chart.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-checkbox.mjs +109 -160
- package/fesm2022/exhaustive-ui-core-checkbox.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-chip.mjs +98 -137
- package/fesm2022/exhaustive-ui-core-chip.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-colorpicker.mjs +123 -190
- package/fesm2022/exhaustive-ui-core-colorpicker.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-confirmdialog.mjs +157 -332
- package/fesm2022/exhaustive-ui-core-confirmdialog.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-confirmpopup.mjs +187 -210
- package/fesm2022/exhaustive-ui-core-confirmpopup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-contextmenu.mjs +315 -361
- package/fesm2022/exhaustive-ui-core-contextmenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-dataview.mjs +225 -272
- package/fesm2022/exhaustive-ui-core-dataview.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-datepicker.mjs +1012 -1157
- package/fesm2022/exhaustive-ui-core-datepicker.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-dialog.mjs +370 -507
- package/fesm2022/exhaustive-ui-core-dialog.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-dock.mjs +87 -115
- package/fesm2022/exhaustive-ui-core-dock.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-dragdrop.mjs +98 -105
- package/fesm2022/exhaustive-ui-core-dragdrop.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-drawer.mjs +174 -235
- package/fesm2022/exhaustive-ui-core-drawer.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-dynamicdialog.mjs +42 -280
- package/fesm2022/exhaustive-ui-core-dynamicdialog.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-editor.mjs +109 -121
- package/fesm2022/exhaustive-ui-core-editor.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-fieldset.mjs +90 -132
- package/fesm2022/exhaustive-ui-core-fieldset.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-fileupload.mjs +486 -541
- package/fesm2022/exhaustive-ui-core-fileupload.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-floatlabel.mjs +13 -16
- package/fesm2022/exhaustive-ui-core-floatlabel.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-focustrap.mjs +44 -40
- package/fesm2022/exhaustive-ui-core-focustrap.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-galleria.mjs +642 -853
- package/fesm2022/exhaustive-ui-core-galleria.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-iconfield.mjs +15 -27
- package/fesm2022/exhaustive-ui-core-iconfield.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-baseicon.mjs +8 -13
- package/fesm2022/exhaustive-ui-core-icons-baseicon.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-image.mjs +209 -251
- package/fesm2022/exhaustive-ui-core-image.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-imagecompare.mjs +39 -48
- package/fesm2022/exhaustive-ui-core-imagecompare.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inplace.mjs +64 -98
- package/fesm2022/exhaustive-ui-core-inplace.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inputgroup.mjs +10 -20
- package/fesm2022/exhaustive-ui-core-inputgroup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inputgroupaddon.mjs +15 -24
- package/fesm2022/exhaustive-ui-core-inputgroupaddon.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inputicon.mjs +11 -22
- package/fesm2022/exhaustive-ui-core-inputicon.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inputmask.mjs +423 -392
- package/fesm2022/exhaustive-ui-core-inputmask.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inputnumber.mjs +397 -469
- package/fesm2022/exhaustive-ui-core-inputnumber.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inputotp.mjs +75 -95
- package/fesm2022/exhaustive-ui-core-inputotp.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inputtext.mjs +27 -36
- package/fesm2022/exhaustive-ui-core-inputtext.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-keyfilter.mjs +29 -46
- package/fesm2022/exhaustive-ui-core-keyfilter.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-knob.mjs +140 -187
- package/fesm2022/exhaustive-ui-core-knob.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-listbox.mjs +365 -546
- package/fesm2022/exhaustive-ui-core-listbox.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-megamenu.mjs +320 -371
- package/fesm2022/exhaustive-ui-core-megamenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-menu.mjs +298 -348
- package/fesm2022/exhaustive-ui-core-menu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-menubar.mjs +277 -372
- package/fesm2022/exhaustive-ui-core-menubar.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-metergroup.mjs +138 -166
- package/fesm2022/exhaustive-ui-core-metergroup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-multiselect.mjs +647 -835
- package/fesm2022/exhaustive-ui-core-multiselect.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-orderlist.mjs +337 -409
- package/fesm2022/exhaustive-ui-core-orderlist.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-organizationchart.mjs +114 -175
- package/fesm2022/exhaustive-ui-core-organizationchart.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-overlaybadge.mjs +22 -47
- package/fesm2022/exhaustive-ui-core-overlaybadge.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-paginator.mjs +232 -320
- package/fesm2022/exhaustive-ui-core-paginator.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-panel.mjs +114 -174
- package/fesm2022/exhaustive-ui-core-panel.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-panelmenu.mjs +171 -282
- package/fesm2022/exhaustive-ui-core-panelmenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-password.mjs +317 -377
- package/fesm2022/exhaustive-ui-core-password.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-picklist.mjs +557 -655
- package/fesm2022/exhaustive-ui-core-picklist.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-popover.mjs +154 -181
- package/fesm2022/exhaustive-ui-core-popover.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-rating.mjs +87 -119
- package/fesm2022/exhaustive-ui-core-rating.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-scroller.mjs +465 -596
- package/fesm2022/exhaustive-ui-core-scroller.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-scrollpanel.mjs +147 -155
- package/fesm2022/exhaustive-ui-core-scrollpanel.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-scrolltop.mjs +81 -115
- package/fesm2022/exhaustive-ui-core-scrolltop.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-select.mjs +581 -784
- package/fesm2022/exhaustive-ui-core-select.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-selectbutton.mjs +84 -120
- package/fesm2022/exhaustive-ui-core-selectbutton.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-slider.mjs +322 -352
- package/fesm2022/exhaustive-ui-core-slider.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-speeddial.mjs +209 -268
- package/fesm2022/exhaustive-ui-core-speeddial.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-splitbutton.mjs +153 -249
- package/fesm2022/exhaustive-ui-core-splitbutton.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-splitter.mjs +221 -237
- package/fesm2022/exhaustive-ui-core-splitter.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-steps.mjs +56 -72
- package/fesm2022/exhaustive-ui-core-steps.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-styleclass.mjs +145 -146
- package/fesm2022/exhaustive-ui-core-styleclass.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-table.mjs +2213 -2543
- package/fesm2022/exhaustive-ui-core-table.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-terminal.mjs +50 -67
- package/fesm2022/exhaustive-ui-core-terminal.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-textarea.mjs +23 -36
- package/fesm2022/exhaustive-ui-core-textarea.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-tieredmenu.mjs +318 -394
- package/fesm2022/exhaustive-ui-core-tieredmenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-timeline.mjs +56 -74
- package/fesm2022/exhaustive-ui-core-timeline.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-togglebutton.mjs +86 -129
- package/fesm2022/exhaustive-ui-core-togglebutton.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-toggleswitch.mjs +57 -94
- package/fesm2022/exhaustive-ui-core-toggleswitch.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-toolbar.mjs +36 -55
- package/fesm2022/exhaustive-ui-core-toolbar.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-tooltip.mjs +264 -343
- package/fesm2022/exhaustive-ui-core-tooltip.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-tree.mjs +508 -639
- package/fesm2022/exhaustive-ui-core-tree.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-treeselect.mjs +327 -421
- package/fesm2022/exhaustive-ui-core-treeselect.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-treetable.mjs +1267 -1473
- package/fesm2022/exhaustive-ui-core-treetable.mjs.map +1 -1
- package/package.json +5 -5
- package/schematics/migrations/remove-dead-inputs/migration.js +213 -7
- package/schematics/migrations/renamed-inputs/migration.js +97 -0
- package/schematics/migrations/styleclass-to-class/migration.js +92 -1
- package/schematics/migrations.json +7 -2
- package/schematics/utils/removed-inputs.js +0 -0
- package/schematics/utils/renamed-inputs.js +175 -0
- package/schematics/utils/styleclass.js +24 -8
- package/schematics/utils/versions.json +8 -8
- package/types/exhaustive-ui-core-accordion.d.ts +8 -24
- package/types/exhaustive-ui-core-animateonscroll.d.ts +19 -21
- package/types/exhaustive-ui-core-api.d.ts +2 -3
- package/types/exhaustive-ui-core-autocomplete.d.ts +103 -176
- package/types/exhaustive-ui-core-autofocus.d.ts +4 -7
- package/types/exhaustive-ui-core-avatar.d.ts +18 -25
- package/types/exhaustive-ui-core-badge.d.ts +13 -27
- package/types/exhaustive-ui-core-blockui.d.ts +18 -30
- package/types/exhaustive-ui-core-breadcrumb.d.ts +21 -22
- package/types/exhaustive-ui-core-button.d.ts +57 -89
- package/types/exhaustive-ui-core-carousel.d.ts +56 -82
- package/types/exhaustive-ui-core-cascadeselect.d.ts +77 -111
- package/types/exhaustive-ui-core-chart.d.ts +21 -29
- package/types/exhaustive-ui-core-checkbox.d.ts +25 -39
- package/types/exhaustive-ui-core-chip.d.ts +31 -38
- package/types/exhaustive-ui-core-colorpicker.d.ts +23 -57
- package/types/exhaustive-ui-core-confirmdialog.d.ts +39 -109
- package/types/exhaustive-ui-core-confirmpopup.d.ts +24 -43
- package/types/exhaustive-ui-core-contextmenu.d.ts +54 -71
- package/types/exhaustive-ui-core-dataview.d.ts +42 -65
- package/types/exhaustive-ui-core-datepicker.d.ts +109 -191
- package/types/exhaustive-ui-core-dialog.d.ts +73 -123
- package/types/exhaustive-ui-core-dock.d.ts +16 -25
- package/types/exhaustive-ui-core-dragdrop.d.ts +32 -36
- package/types/exhaustive-ui-core-drawer.d.ts +32 -64
- package/types/exhaustive-ui-core-dynamicdialog.d.ts +9 -54
- package/types/exhaustive-ui-core-editor.d.ts +15 -25
- package/types/exhaustive-ui-core-fieldset.d.ts +15 -35
- package/types/exhaustive-ui-core-fileupload.d.ts +69 -95
- package/types/exhaustive-ui-core-floatlabel.d.ts +4 -6
- package/types/exhaustive-ui-core-focustrap.d.ts +5 -10
- package/types/exhaustive-ui-core-galleria.d.ts +124 -194
- package/types/exhaustive-ui-core-iconfield.d.ts +5 -13
- package/types/exhaustive-ui-core-icons-baseicon.d.ts +4 -5
- package/types/exhaustive-ui-core-image.d.ts +35 -68
- package/types/exhaustive-ui-core-imagecompare.d.ts +19 -20
- package/types/exhaustive-ui-core-inplace.d.ts +30 -42
- package/types/exhaustive-ui-core-inputgroup.d.ts +2 -9
- package/types/exhaustive-ui-core-inputgroupaddon.d.ts +6 -10
- package/types/exhaustive-ui-core-inputicon.d.ts +4 -11
- package/types/exhaustive-ui-core-inputmask.d.ts +53 -66
- package/types/exhaustive-ui-core-inputnumber.d.ts +62 -84
- package/types/exhaustive-ui-core-inputotp.d.ts +16 -20
- package/types/exhaustive-ui-core-inputtext.d.ts +5 -8
- package/types/exhaustive-ui-core-keyfilter.d.ts +11 -15
- package/types/exhaustive-ui-core-knob.d.ts +45 -60
- package/types/exhaustive-ui-core-listbox.d.ts +90 -126
- package/types/exhaustive-ui-core-megamenu.d.ts +45 -66
- package/types/exhaustive-ui-core-menu.d.ts +33 -53
- package/types/exhaustive-ui-core-menubar.d.ts +38 -85
- package/types/exhaustive-ui-core-metergroup.d.ts +39 -48
- package/types/exhaustive-ui-core-multiselect.d.ts +166 -219
- package/types/exhaustive-ui-core-orderlist.d.ts +58 -81
- package/types/exhaustive-ui-core-organizationchart.d.ts +32 -67
- package/types/exhaustive-ui-core-overlaybadge.d.ts +10 -20
- package/types/exhaustive-ui-core-paginator.d.ts +41 -69
- package/types/exhaustive-ui-core-panel.d.ts +18 -45
- package/types/exhaustive-ui-core-panelmenu.d.ts +31 -76
- package/types/exhaustive-ui-core-password.d.ts +56 -93
- package/types/exhaustive-ui-core-picklist.d.ts +107 -121
- package/types/exhaustive-ui-core-popover.d.ts +23 -47
- package/types/exhaustive-ui-core-rating.d.ts +18 -26
- package/types/exhaustive-ui-core-scroller.d.ts +90 -120
- package/types/exhaustive-ui-core-scrollpanel.d.ts +35 -46
- package/types/exhaustive-ui-core-scrolltop.d.ts +28 -45
- package/types/exhaustive-ui-core-select.d.ts +137 -188
- package/types/exhaustive-ui-core-selectbutton.d.ts +35 -44
- package/types/exhaustive-ui-core-slider.d.ts +52 -67
- package/types/exhaustive-ui-core-speeddial.d.ts +40 -56
- package/types/exhaustive-ui-core-splitbutton.d.ts +31 -71
- package/types/exhaustive-ui-core-splitter.d.ts +47 -59
- package/types/exhaustive-ui-core-steps.d.ts +24 -31
- package/types/exhaustive-ui-core-styleclass.d.ts +27 -33
- package/types/exhaustive-ui-core-table.d.ts +349 -453
- package/types/exhaustive-ui-core-terminal.d.ts +10 -22
- package/types/exhaustive-ui-core-textarea.d.ts +7 -10
- package/types/exhaustive-ui-core-tieredmenu.d.ts +49 -84
- package/types/exhaustive-ui-core-timeline.d.ts +20 -28
- package/types/exhaustive-ui-core-togglebutton.d.ts +32 -48
- package/types/exhaustive-ui-core-toggleswitch.d.ts +26 -37
- package/types/exhaustive-ui-core-toolbar.d.ts +17 -25
- package/types/exhaustive-ui-core-tooltip.d.ts +53 -88
- package/types/exhaustive-ui-core-tree.d.ts +82 -119
- package/types/exhaustive-ui-core-treeselect.d.ts +63 -92
- package/types/exhaustive-ui-core-treetable.d.ts +203 -280
- package/types/exhaustive-ui-core-types-chip.d.ts +1 -1
|
@@ -3,7 +3,8 @@ import { moveItemInArray, DragDropModule } from '@angular/cdk/drag-drop';
|
|
|
3
3
|
import * as i2 from '@angular/common';
|
|
4
4
|
import { isPlatformBrowser, CommonModule } from '@angular/common';
|
|
5
5
|
import * as i0 from '@angular/core';
|
|
6
|
-
import { Injectable, InjectionToken, inject, output, viewChild, contentChild,
|
|
6
|
+
import { Injectable, InjectionToken, inject, afterEveryRender, input, numberAttribute, booleanAttribute, model, output, viewChild, contentChild, computed, signal, linkedSignal, untracked, contentChildren, ViewEncapsulation, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
|
|
7
|
+
import { toSignal } from '@angular/core/rxjs-interop';
|
|
7
8
|
import * as i4 from '@angular/forms';
|
|
8
9
|
import { FormsModule } from '@angular/forms';
|
|
9
10
|
import { uuid, findIndexInList, setAttribute } from '@exhaustive-ui/utils';
|
|
@@ -28,7 +29,7 @@ const theme = /*css*/ `
|
|
|
28
29
|
}
|
|
29
30
|
`;
|
|
30
31
|
const classes = {
|
|
31
|
-
root: ({ instance }) => ['p-orderlist p-component', { 'p-orderlist-controls-left': instance.controlsPosition === 'left', 'p-orderlist-controls-right': instance.controlsPosition === 'right' }],
|
|
32
|
+
root: ({ instance }) => ['p-orderlist p-component', { 'p-orderlist-controls-left': instance.controlsPosition() === 'left', 'p-orderlist-controls-right': instance.controlsPosition() === 'right' }],
|
|
32
33
|
controls: 'p-orderlist-controls'
|
|
33
34
|
};
|
|
34
35
|
class OrderListStyle extends BaseStyle {
|
|
@@ -71,179 +72,172 @@ class OrderList extends BaseComponent {
|
|
|
71
72
|
componentName = 'OrderList';
|
|
72
73
|
bindDirectiveInstance = inject(Bind, { self: true });
|
|
73
74
|
$pcOrderList = inject(ORDERLIST_INSTANCE, { optional: true, skipSelf: true }) ?? undefined;
|
|
74
|
-
|
|
75
|
-
|
|
75
|
+
constructor() {
|
|
76
|
+
super();
|
|
77
|
+
afterEveryRender(() => this.bindDirectiveInstance.setAttrs(this.ptms(['host', 'root'])));
|
|
76
78
|
}
|
|
77
79
|
/**
|
|
78
80
|
* Text for the caption.
|
|
79
81
|
* @group Props
|
|
80
82
|
*/
|
|
81
|
-
header
|
|
82
|
-
|
|
83
|
-
* Style class of the component.
|
|
84
|
-
* @deprecated since v20.0.0, use `class` instead.
|
|
85
|
-
* @group Props
|
|
86
|
-
*/
|
|
87
|
-
styleClass;
|
|
83
|
+
header = input(/* @ts-ignore */
|
|
84
|
+
...(ngDevMode ? [undefined, { debugName: "header" }] : /* istanbul ignore next */ []));
|
|
88
85
|
/**
|
|
89
86
|
* Index of the element in tabbing order.
|
|
90
87
|
* @group Props
|
|
91
88
|
*/
|
|
92
|
-
tabindex;
|
|
89
|
+
tabindex = input(undefined, { ...(ngDevMode ? { debugName: "tabindex" } : /* istanbul ignore next */ {}), transform: numberAttribute });
|
|
93
90
|
/**
|
|
94
91
|
* Defines a string that labels the input for accessibility.
|
|
95
92
|
* @group Props
|
|
96
93
|
*/
|
|
97
|
-
ariaLabel
|
|
94
|
+
ariaLabel = input(/* @ts-ignore */
|
|
95
|
+
...(ngDevMode ? [undefined, { debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
98
96
|
/**
|
|
99
97
|
* Specifies one or more IDs in the DOM that labels the input field.
|
|
100
98
|
* @group Props
|
|
101
99
|
*/
|
|
102
|
-
ariaLabelledBy
|
|
100
|
+
ariaLabelledBy = input(/* @ts-ignore */
|
|
101
|
+
...(ngDevMode ? [undefined, { debugName: "ariaLabelledBy" }] : /* istanbul ignore next */ []));
|
|
103
102
|
/**
|
|
104
103
|
* Inline style of the list element.
|
|
105
104
|
* @group Props
|
|
106
105
|
*/
|
|
107
|
-
listStyle
|
|
106
|
+
listStyle = input(/* @ts-ignore */
|
|
107
|
+
...(ngDevMode ? [undefined, { debugName: "listStyle" }] : /* istanbul ignore next */ []));
|
|
108
108
|
/**
|
|
109
109
|
* A boolean value that indicates whether the component should be responsive.
|
|
110
110
|
* @group Props
|
|
111
111
|
*/
|
|
112
|
-
responsive;
|
|
112
|
+
responsive = input(undefined, { ...(ngDevMode ? { debugName: "responsive" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
113
113
|
/**
|
|
114
114
|
* When specified displays an input field to filter the items on keyup and decides which fields to search against.
|
|
115
115
|
* @group Props
|
|
116
116
|
*/
|
|
117
|
-
filterBy
|
|
117
|
+
filterBy = input(/* @ts-ignore */
|
|
118
|
+
...(ngDevMode ? [undefined, { debugName: "filterBy" }] : /* istanbul ignore next */ []));
|
|
118
119
|
/**
|
|
119
120
|
* Placeholder of the filter input.
|
|
120
121
|
* @group Props
|
|
121
122
|
*/
|
|
122
|
-
filterPlaceholder
|
|
123
|
+
filterPlaceholder = input(/* @ts-ignore */
|
|
124
|
+
...(ngDevMode ? [undefined, { debugName: "filterPlaceholder" }] : /* istanbul ignore next */ []));
|
|
123
125
|
/**
|
|
124
126
|
* Locale to use in filtering. The default locale is the host environment's current locale.
|
|
125
127
|
* @group Props
|
|
126
128
|
*/
|
|
127
|
-
filterLocale
|
|
129
|
+
filterLocale = input(/* @ts-ignore */
|
|
130
|
+
...(ngDevMode ? [undefined, { debugName: "filterLocale" }] : /* istanbul ignore next */ []));
|
|
128
131
|
/**
|
|
129
132
|
* When true metaKey needs to be pressed to select or unselect an item and when set to false selection of each item can be toggled individually. On touch enabled devices, metaKeySelection is turned off automatically.
|
|
130
133
|
* @group Props
|
|
131
134
|
*/
|
|
132
|
-
metaKeySelection = false;
|
|
135
|
+
metaKeySelection = input(false, { ...(ngDevMode ? { debugName: "metaKeySelection" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
133
136
|
/**
|
|
134
137
|
* Whether to enable dragdrop based reordering.
|
|
135
138
|
* @group Props
|
|
136
139
|
*/
|
|
137
|
-
dragdrop = false;
|
|
140
|
+
dragdrop = input(false, { ...(ngDevMode ? { debugName: "dragdrop" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
138
141
|
/**
|
|
139
142
|
* Defines the location of the buttons with respect to the list.
|
|
140
143
|
* @group Props
|
|
141
144
|
*/
|
|
142
|
-
controlsPosition = 'left'
|
|
145
|
+
controlsPosition = input('left', /* @ts-ignore */
|
|
146
|
+
...(ngDevMode ? [{ debugName: "controlsPosition" }] : /* istanbul ignore next */ []));
|
|
143
147
|
/**
|
|
144
148
|
* Defines a string that labels the filter input.
|
|
145
149
|
* @group Props
|
|
146
150
|
*/
|
|
147
|
-
ariaFilterLabel
|
|
151
|
+
ariaFilterLabel = input(/* @ts-ignore */
|
|
152
|
+
...(ngDevMode ? [undefined, { debugName: "ariaFilterLabel" }] : /* istanbul ignore next */ []));
|
|
148
153
|
/**
|
|
149
154
|
* Defines how the items are filtered.
|
|
150
155
|
* @group Props
|
|
151
156
|
*/
|
|
152
|
-
filterMatchMode = 'contains'
|
|
157
|
+
filterMatchMode = input('contains', /* @ts-ignore */
|
|
158
|
+
...(ngDevMode ? [{ debugName: "filterMatchMode" }] : /* istanbul ignore next */ []));
|
|
153
159
|
/**
|
|
154
160
|
* Indicates the width of the screen at which the component should change its behavior.
|
|
155
161
|
* @group Props
|
|
156
162
|
*/
|
|
157
|
-
breakpoint = '960px'
|
|
163
|
+
breakpoint = input('960px', /* @ts-ignore */
|
|
164
|
+
...(ngDevMode ? [{ debugName: "breakpoint" }] : /* istanbul ignore next */ []));
|
|
158
165
|
/**
|
|
159
166
|
* Whether to displays rows with alternating colors.
|
|
160
167
|
* @group Props
|
|
161
168
|
*/
|
|
162
|
-
stripedRows;
|
|
169
|
+
stripedRows = input(undefined, { ...(ngDevMode ? { debugName: "stripedRows" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
163
170
|
/**
|
|
164
171
|
* When present, it specifies that the component should be disabled.
|
|
165
172
|
* @group Props
|
|
166
173
|
*/
|
|
167
|
-
disabled;
|
|
174
|
+
disabled = input(undefined, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
168
175
|
/**
|
|
169
176
|
* Function to optimize the dom operations by delegating to ngForTrackBy, default algorithm checks for object identity.
|
|
170
177
|
* @group Props
|
|
171
178
|
*/
|
|
172
|
-
trackBy = (index, item) => item
|
|
179
|
+
trackBy = input((index, item) => item, /* @ts-ignore */
|
|
180
|
+
...(ngDevMode ? [{ debugName: "trackBy" }] : /* istanbul ignore next */ []));
|
|
173
181
|
/**
|
|
174
182
|
* Height of the viewport, a scrollbar is defined if height of list exceeds this value.
|
|
175
183
|
* @group Props
|
|
176
184
|
*/
|
|
177
|
-
scrollHeight = '14rem'
|
|
185
|
+
scrollHeight = input('14rem', /* @ts-ignore */
|
|
186
|
+
...(ngDevMode ? [{ debugName: "scrollHeight" }] : /* istanbul ignore next */ []));
|
|
178
187
|
/**
|
|
179
188
|
* Whether to focus on the first visible or selected element.
|
|
180
189
|
* @group Props
|
|
181
190
|
*/
|
|
182
|
-
autoOptionFocus = true;
|
|
191
|
+
autoOptionFocus = input(true, { ...(ngDevMode ? { debugName: "autoOptionFocus" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
183
192
|
/**
|
|
184
193
|
* Name of the field that uniquely identifies the record in the data.
|
|
185
194
|
* @group Props
|
|
186
195
|
*/
|
|
187
|
-
dataKey
|
|
196
|
+
dataKey = input(/* @ts-ignore */
|
|
197
|
+
...(ngDevMode ? [undefined, { debugName: "dataKey" }] : /* istanbul ignore next */ []));
|
|
188
198
|
/**
|
|
189
|
-
* A list of values that are currently selected.
|
|
199
|
+
* A list of values that are currently selected. Two-way bindable with `[(selection)]`: `selectionChange` is emitted with the new selection when it changes.
|
|
190
200
|
* @group Props
|
|
191
201
|
*/
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
}
|
|
195
|
-
get selection() {
|
|
196
|
-
return this.d_selection;
|
|
197
|
-
}
|
|
202
|
+
selection = model([], /* @ts-ignore */
|
|
203
|
+
...(ngDevMode ? [{ debugName: "selection" }] : /* istanbul ignore next */ []));
|
|
198
204
|
/**
|
|
199
205
|
* Array of values to be displayed in the component.
|
|
200
206
|
* It represents the data source for the list of items.
|
|
201
207
|
* @group Props
|
|
202
208
|
*/
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
if (this.filterValue) {
|
|
206
|
-
this.filter();
|
|
207
|
-
}
|
|
208
|
-
else if (this.dragdrop) {
|
|
209
|
-
// Initialize visibleOptions for drag&drop even when no filtering is active
|
|
210
|
-
this.visibleOptions = [...(val || [])];
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
|
-
get value() {
|
|
214
|
-
return this._value;
|
|
215
|
-
}
|
|
209
|
+
value = input(/* @ts-ignore */
|
|
210
|
+
...(ngDevMode ? [undefined, { debugName: "value" }] : /* istanbul ignore next */ []));
|
|
216
211
|
/**
|
|
217
212
|
* Used to pass all properties of the ButtonProps to the Button component.
|
|
218
213
|
* @group Props
|
|
219
214
|
*/
|
|
220
|
-
buttonProps = { severity: 'secondary' }
|
|
215
|
+
buttonProps = input({ severity: 'secondary' }, /* @ts-ignore */
|
|
216
|
+
...(ngDevMode ? [{ debugName: "buttonProps" }] : /* istanbul ignore next */ []));
|
|
221
217
|
/**
|
|
222
218
|
* Used to pass all properties of the ButtonProps to the move up button inside the component.
|
|
223
219
|
* @group Props
|
|
224
220
|
*/
|
|
225
|
-
moveUpButtonProps
|
|
221
|
+
moveUpButtonProps = input(/* @ts-ignore */
|
|
222
|
+
...(ngDevMode ? [undefined, { debugName: "moveUpButtonProps" }] : /* istanbul ignore next */ []));
|
|
226
223
|
/**
|
|
227
224
|
* Used to pass all properties of the ButtonProps to the move top button inside the component.
|
|
228
225
|
* @group Props
|
|
229
226
|
*/
|
|
230
|
-
moveTopButtonProps
|
|
227
|
+
moveTopButtonProps = input(/* @ts-ignore */
|
|
228
|
+
...(ngDevMode ? [undefined, { debugName: "moveTopButtonProps" }] : /* istanbul ignore next */ []));
|
|
231
229
|
/**
|
|
232
230
|
* Used to pass all properties of the ButtonProps to the move down button inside the component.
|
|
233
231
|
* @group Props
|
|
234
232
|
*/
|
|
235
|
-
moveDownButtonProps
|
|
233
|
+
moveDownButtonProps = input(/* @ts-ignore */
|
|
234
|
+
...(ngDevMode ? [undefined, { debugName: "moveDownButtonProps" }] : /* istanbul ignore next */ []));
|
|
236
235
|
/**
|
|
237
236
|
* Used to pass all properties of the ButtonProps to the move bottom button inside the component.
|
|
238
237
|
* @group Props
|
|
239
238
|
*/
|
|
240
|
-
moveBottomButtonProps
|
|
241
|
-
|
|
242
|
-
* Callback to invoke on selection change.
|
|
243
|
-
* @param {*} any - selection instance.
|
|
244
|
-
* @group Emits
|
|
245
|
-
*/
|
|
246
|
-
selectionChange = output();
|
|
239
|
+
moveBottomButtonProps = input(/* @ts-ignore */
|
|
240
|
+
...(ngDevMode ? [undefined, { debugName: "moveBottomButtonProps" }] : /* istanbul ignore next */ []));
|
|
247
241
|
/**
|
|
248
242
|
* Callback to invoke when list is reordered.
|
|
249
243
|
* @param {*} any - list instance.
|
|
@@ -332,142 +326,124 @@ class OrderList extends BaseComponent {
|
|
|
332
326
|
* @group Templates
|
|
333
327
|
*/
|
|
334
328
|
filterIconTemplate = contentChild('filtericon', { ...(ngDevMode ? { debugName: "filterIconTemplate" } : /* istanbul ignore next */ {}), descendants: false });
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
}
|
|
344
|
-
get moveBottomAriaLabel() {
|
|
345
|
-
return this.config.translation.aria ? this.config.translation.aria.moveBottom : undefined;
|
|
346
|
-
}
|
|
329
|
+
translation = toSignal(this.config.translationObserver, { initialValue: this.config.translation });
|
|
330
|
+
moveUpAriaLabel = computed(() => (this.translation().aria ? this.translation().aria.moveUp : undefined), /* @ts-ignore */
|
|
331
|
+
...(ngDevMode ? [{ debugName: "moveUpAriaLabel" }] : /* istanbul ignore next */ []));
|
|
332
|
+
moveTopAriaLabel = computed(() => (this.translation().aria ? this.translation().aria.moveTop : undefined), /* @ts-ignore */
|
|
333
|
+
...(ngDevMode ? [{ debugName: "moveTopAriaLabel" }] : /* istanbul ignore next */ []));
|
|
334
|
+
moveDownAriaLabel = computed(() => (this.translation().aria ? this.translation().aria.moveDown : undefined), /* @ts-ignore */
|
|
335
|
+
...(ngDevMode ? [{ debugName: "moveDownAriaLabel" }] : /* istanbul ignore next */ []));
|
|
336
|
+
moveBottomAriaLabel = computed(() => (this.translation().aria ? this.translation().aria.moveBottom : undefined), /* @ts-ignore */
|
|
337
|
+
...(ngDevMode ? [{ debugName: "moveBottomAriaLabel" }] : /* istanbul ignore next */ []));
|
|
347
338
|
_componentStyle = inject(OrderListStyle);
|
|
348
|
-
filterOptions
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
339
|
+
filterOptions = computed(() => this.filterBy()
|
|
340
|
+
? {
|
|
341
|
+
filter: (value) => this.onFilterKeyup(value),
|
|
342
|
+
reset: () => this.resetFilter()
|
|
343
|
+
}
|
|
344
|
+
: undefined, /* @ts-ignore */
|
|
345
|
+
...(ngDevMode ? [{ debugName: "filterOptions" }] : /* istanbul ignore next */ []));
|
|
346
|
+
movedUp = signal(undefined, /* @ts-ignore */
|
|
347
|
+
...(ngDevMode ? [{ debugName: "movedUp" }] : /* istanbul ignore next */ []));
|
|
348
|
+
movedDown = signal(undefined, /* @ts-ignore */
|
|
349
|
+
...(ngDevMode ? [{ debugName: "movedDown" }] : /* istanbul ignore next */ []));
|
|
350
|
+
styleElement = signal(undefined, /* @ts-ignore */
|
|
351
|
+
...(ngDevMode ? [{ debugName: "styleElement" }] : /* istanbul ignore next */ []));
|
|
354
352
|
id = uuid('pn_id_');
|
|
355
|
-
filterValue
|
|
356
|
-
|
|
357
|
-
|
|
353
|
+
filterValue = signal(undefined, /* @ts-ignore */
|
|
354
|
+
...(ngDevMode ? [{ debugName: "filterValue" }] : /* istanbul ignore next */ []));
|
|
355
|
+
visibleOptions = linkedSignal({ ...(ngDevMode ? { debugName: "visibleOptions" } : /* istanbul ignore next */ {}), source: this.value,
|
|
356
|
+
computation: (value, previous) => untracked(() => {
|
|
357
|
+
if (this.filterValue()) {
|
|
358
|
+
return this.filterService.filter(value, this.filterBy().split(','), this.filterValue(), this.filterMatchMode(), this.filterLocale());
|
|
359
|
+
}
|
|
360
|
+
else if (this.dragdrop()) {
|
|
361
|
+
// Initialize visibleOptions for drag&drop even when no filtering is active
|
|
362
|
+
return [...(value || [])];
|
|
363
|
+
}
|
|
364
|
+
return previous?.value;
|
|
365
|
+
}) });
|
|
358
366
|
filterService = inject(FilterService);
|
|
359
367
|
getButtonProps(direction) {
|
|
360
368
|
switch (direction) {
|
|
361
369
|
case 'up':
|
|
362
|
-
return { ...this.buttonProps, ...this.moveUpButtonProps };
|
|
370
|
+
return { ...this.buttonProps(), ...this.moveUpButtonProps() };
|
|
363
371
|
case 'top':
|
|
364
|
-
return { ...this.buttonProps, ...this.moveTopButtonProps };
|
|
372
|
+
return { ...this.buttonProps(), ...this.moveTopButtonProps() };
|
|
365
373
|
case 'down':
|
|
366
|
-
return { ...this.buttonProps, ...this.moveDownButtonProps };
|
|
374
|
+
return { ...this.buttonProps(), ...this.moveDownButtonProps() };
|
|
367
375
|
case 'bottom':
|
|
368
|
-
return { ...this.buttonProps, ...this.moveBottomButtonProps };
|
|
376
|
+
return { ...this.buttonProps(), ...this.moveBottomButtonProps() };
|
|
369
377
|
default:
|
|
370
|
-
return this.buttonProps;
|
|
378
|
+
return this.buttonProps();
|
|
371
379
|
}
|
|
372
380
|
}
|
|
373
381
|
onInit() {
|
|
374
|
-
if (this.responsive) {
|
|
382
|
+
if (this.responsive()) {
|
|
375
383
|
this.createStyle();
|
|
376
384
|
}
|
|
377
|
-
if (this.filterBy) {
|
|
378
|
-
this.filterOptions = {
|
|
379
|
-
filter: (value) => this.onFilterKeyup(value),
|
|
380
|
-
reset: () => this.resetFilter()
|
|
381
|
-
};
|
|
382
|
-
}
|
|
383
|
-
// Initialize visibleOptions for drag&drop if enabled and value exists
|
|
384
|
-
if (this.dragdrop && this.value && !this.visibleOptions) {
|
|
385
|
-
this.visibleOptions = [...this.value];
|
|
386
|
-
}
|
|
387
385
|
}
|
|
388
386
|
templates = contentChildren(PrimeTemplate, /* @ts-ignore */
|
|
389
387
|
...(ngDevMode ? [{ debugName: "templates" }] : /* istanbul ignore next */ []));
|
|
390
|
-
_itemTemplate
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
this._headerTemplate = item.template;
|
|
417
|
-
break;
|
|
418
|
-
case 'moveupicon':
|
|
419
|
-
this._moveUpIconTemplate = item.template;
|
|
420
|
-
break;
|
|
421
|
-
case 'movetopicon':
|
|
422
|
-
this._moveTopIconTemplate = item.template;
|
|
423
|
-
break;
|
|
424
|
-
case 'movedownicon':
|
|
425
|
-
this._moveDownIconTemplate = item.template;
|
|
426
|
-
break;
|
|
427
|
-
case 'movebottomicon':
|
|
428
|
-
this._moveBottomIconTemplate = item.template;
|
|
429
|
-
break;
|
|
430
|
-
case 'filtericon':
|
|
431
|
-
this._filterIconTemplate = item.template;
|
|
432
|
-
break;
|
|
433
|
-
default:
|
|
434
|
-
this._itemTemplate = item.template;
|
|
435
|
-
break;
|
|
436
|
-
}
|
|
437
|
-
});
|
|
388
|
+
_itemTemplate = computed(() => this.templates()
|
|
389
|
+
.filter((item) => !['empty', 'emptyfilter', 'filter', 'header', 'moveupicon', 'movetopicon', 'movedownicon', 'movebottomicon', 'filtericon'].includes(item.getType()))
|
|
390
|
+
.at(-1)?.template, /* @ts-ignore */
|
|
391
|
+
...(ngDevMode ? [{ debugName: "_itemTemplate" }] : /* istanbul ignore next */ []));
|
|
392
|
+
_emptyMessageTemplate = computed(() => this.findTemplate('empty'), /* @ts-ignore */
|
|
393
|
+
...(ngDevMode ? [{ debugName: "_emptyMessageTemplate" }] : /* istanbul ignore next */ []));
|
|
394
|
+
_emptyFilterMessageTemplate = computed(() => this.findTemplate('emptyfilter'), /* @ts-ignore */
|
|
395
|
+
...(ngDevMode ? [{ debugName: "_emptyFilterMessageTemplate" }] : /* istanbul ignore next */ []));
|
|
396
|
+
_filterTemplate = computed(() => this.findTemplate('filter'), /* @ts-ignore */
|
|
397
|
+
...(ngDevMode ? [{ debugName: "_filterTemplate" }] : /* istanbul ignore next */ []));
|
|
398
|
+
_headerTemplate = computed(() => this.findTemplate('header'), /* @ts-ignore */
|
|
399
|
+
...(ngDevMode ? [{ debugName: "_headerTemplate" }] : /* istanbul ignore next */ []));
|
|
400
|
+
_moveUpIconTemplate = computed(() => this.findTemplate('moveupicon'), /* @ts-ignore */
|
|
401
|
+
...(ngDevMode ? [{ debugName: "_moveUpIconTemplate" }] : /* istanbul ignore next */ []));
|
|
402
|
+
_moveTopIconTemplate = computed(() => this.findTemplate('movetopicon'), /* @ts-ignore */
|
|
403
|
+
...(ngDevMode ? [{ debugName: "_moveTopIconTemplate" }] : /* istanbul ignore next */ []));
|
|
404
|
+
_moveDownIconTemplate = computed(() => this.findTemplate('movedownicon'), /* @ts-ignore */
|
|
405
|
+
...(ngDevMode ? [{ debugName: "_moveDownIconTemplate" }] : /* istanbul ignore next */ []));
|
|
406
|
+
_moveBottomIconTemplate = computed(() => this.findTemplate('movebottomicon'), /* @ts-ignore */
|
|
407
|
+
...(ngDevMode ? [{ debugName: "_moveBottomIconTemplate" }] : /* istanbul ignore next */ []));
|
|
408
|
+
_filterIconTemplate = computed(() => this.findTemplate('filtericon'), /* @ts-ignore */
|
|
409
|
+
...(ngDevMode ? [{ debugName: "_filterIconTemplate" }] : /* istanbul ignore next */ []));
|
|
410
|
+
findTemplate(type) {
|
|
411
|
+
return this.templates()
|
|
412
|
+
.filter((item) => item.getType() === type)
|
|
413
|
+
.at(-1)?.template;
|
|
438
414
|
}
|
|
439
415
|
onChangeSelection(e) {
|
|
440
|
-
this.d_selection = e.value;
|
|
441
416
|
//binding
|
|
442
|
-
this.
|
|
417
|
+
this.selection.set(e.value);
|
|
443
418
|
//event
|
|
444
419
|
this.onSelectionChange.emit({ originalEvent: e.originalEvent, value: e.value });
|
|
445
420
|
}
|
|
446
421
|
onFilterKeyup(event) {
|
|
447
|
-
this.filterValue
|
|
422
|
+
this.filterValue.set(event.target.value.trim().toLocaleLowerCase(this.filterLocale()));
|
|
448
423
|
this.filter();
|
|
449
424
|
this.onFilterEvent.emit({
|
|
450
425
|
originalEvent: event,
|
|
451
|
-
value: this.visibleOptions
|
|
426
|
+
value: this.visibleOptions()
|
|
452
427
|
});
|
|
453
428
|
}
|
|
454
429
|
filter() {
|
|
455
|
-
let searchFields = this.filterBy.split(',');
|
|
456
|
-
this.visibleOptions
|
|
430
|
+
let searchFields = this.filterBy().split(',');
|
|
431
|
+
this.visibleOptions.set(this.filterService.filter(this.value(), searchFields, this.filterValue(), this.filterMatchMode(), this.filterLocale()));
|
|
457
432
|
}
|
|
458
433
|
/**
|
|
459
434
|
* Callback to invoke on filter reset.
|
|
460
435
|
* @group Method
|
|
461
436
|
*/
|
|
462
437
|
resetFilter() {
|
|
463
|
-
this.filterValue
|
|
464
|
-
|
|
465
|
-
filterViewChild && (filterViewChild.nativeElement.value = '');
|
|
438
|
+
this.filterValue.set('');
|
|
439
|
+
this.listViewChild().resetFilter();
|
|
466
440
|
}
|
|
467
441
|
isItemVisible(item) {
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
442
|
+
const filterValue = this.filterValue();
|
|
443
|
+
if (filterValue && filterValue.trim().length) {
|
|
444
|
+
const visibleOptions = this.visibleOptions();
|
|
445
|
+
for (let i = 0; i < visibleOptions.length; i++) {
|
|
446
|
+
if (item == visibleOptions[i]) {
|
|
471
447
|
return true;
|
|
472
448
|
}
|
|
473
449
|
}
|
|
@@ -477,63 +453,68 @@ class OrderList extends BaseComponent {
|
|
|
477
453
|
}
|
|
478
454
|
}
|
|
479
455
|
isSelected(item) {
|
|
480
|
-
return findIndexInList(item, this.
|
|
481
|
-
}
|
|
482
|
-
isEmpty() {
|
|
483
|
-
|
|
484
|
-
|
|
456
|
+
return findIndexInList(item, this.selection()) !== -1;
|
|
457
|
+
}
|
|
458
|
+
isEmpty = computed(() => {
|
|
459
|
+
const visibleOptions = this.visibleOptions();
|
|
460
|
+
const value = this.value();
|
|
461
|
+
return this.filterValue() ? !visibleOptions || visibleOptions.length === 0 : !value || value.length === 0;
|
|
462
|
+
}, /* @ts-ignore */
|
|
463
|
+
...(ngDevMode ? [{ debugName: "isEmpty" }] : /* istanbul ignore next */ []));
|
|
485
464
|
moveUp() {
|
|
486
|
-
|
|
465
|
+
const value = this.value();
|
|
466
|
+
if (this.selection() && value instanceof Array) {
|
|
487
467
|
// Sort selection by their current index to process them from top to bottom
|
|
488
|
-
const sortedSelection = this.sortByIndexInList(this.selection,
|
|
468
|
+
const sortedSelection = this.sortByIndexInList(this.selection(), value);
|
|
489
469
|
for (let selectedItem of sortedSelection) {
|
|
490
|
-
let selectedItemIndex = findIndexInList(selectedItem,
|
|
470
|
+
let selectedItemIndex = findIndexInList(selectedItem, value);
|
|
491
471
|
// Only move if not at top and there's a valid position above
|
|
492
472
|
if (selectedItemIndex > 0) {
|
|
493
|
-
let movedItem =
|
|
494
|
-
let temp =
|
|
495
|
-
|
|
496
|
-
|
|
473
|
+
let movedItem = value[selectedItemIndex];
|
|
474
|
+
let temp = value[selectedItemIndex - 1];
|
|
475
|
+
value[selectedItemIndex - 1] = movedItem;
|
|
476
|
+
value[selectedItemIndex] = temp;
|
|
497
477
|
}
|
|
498
478
|
// Don't break - continue with other items even if one can't move
|
|
499
479
|
}
|
|
500
|
-
if (this.dragdrop) {
|
|
501
|
-
if (this.filterValue) {
|
|
480
|
+
if (this.dragdrop()) {
|
|
481
|
+
if (this.filterValue()) {
|
|
502
482
|
this.filter();
|
|
503
483
|
}
|
|
504
|
-
else if (this.visibleOptions) {
|
|
484
|
+
else if (this.visibleOptions()) {
|
|
505
485
|
// Update visibleOptions to match value when no filtering
|
|
506
|
-
this.visibleOptions
|
|
486
|
+
this.visibleOptions.set([...value]);
|
|
507
487
|
}
|
|
508
488
|
}
|
|
509
|
-
this.movedUp
|
|
510
|
-
this.onReorder.emit(this.selection);
|
|
489
|
+
this.movedUp.set(true);
|
|
490
|
+
this.onReorder.emit(this.selection());
|
|
511
491
|
}
|
|
512
492
|
this.listViewChild().cd?.markForCheck();
|
|
513
493
|
}
|
|
514
494
|
moveTop() {
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
let
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
495
|
+
const value = this.value();
|
|
496
|
+
if (this.selection()) {
|
|
497
|
+
for (let i = this.selection().length - 1; i >= 0; i--) {
|
|
498
|
+
let selectedItem = this.selection()[i];
|
|
499
|
+
let selectedItemIndex = findIndexInList(selectedItem, value || []);
|
|
500
|
+
if (selectedItemIndex != 0 && value instanceof Array) {
|
|
501
|
+
let movedItem = value.splice(selectedItemIndex, 1)[0];
|
|
502
|
+
value.unshift(movedItem);
|
|
522
503
|
}
|
|
523
504
|
else {
|
|
524
505
|
break;
|
|
525
506
|
}
|
|
526
507
|
}
|
|
527
|
-
if (this.dragdrop) {
|
|
528
|
-
if (this.filterValue) {
|
|
508
|
+
if (this.dragdrop()) {
|
|
509
|
+
if (this.filterValue()) {
|
|
529
510
|
this.filter();
|
|
530
511
|
}
|
|
531
|
-
else if (this.visibleOptions) {
|
|
512
|
+
else if (this.visibleOptions()) {
|
|
532
513
|
// Update visibleOptions to match value when no filtering
|
|
533
|
-
this.visibleOptions
|
|
514
|
+
this.visibleOptions.set([...(value || [])]);
|
|
534
515
|
}
|
|
535
516
|
}
|
|
536
|
-
this.onReorder.emit(this.selection);
|
|
517
|
+
this.onReorder.emit(this.selection());
|
|
537
518
|
setTimeout(() => {
|
|
538
519
|
this.listViewChild().scrollInView(0);
|
|
539
520
|
});
|
|
@@ -541,93 +522,96 @@ class OrderList extends BaseComponent {
|
|
|
541
522
|
this.listViewChild().cd?.markForCheck();
|
|
542
523
|
}
|
|
543
524
|
moveDown() {
|
|
544
|
-
|
|
545
|
-
|
|
525
|
+
const value = this.value();
|
|
526
|
+
if (this.selection() && value instanceof Array) {
|
|
527
|
+
const sortedSelection = this.sortByIndexInList(this.selection(), value).reverse();
|
|
546
528
|
for (let selectedItem of sortedSelection) {
|
|
547
|
-
let selectedItemIndex = findIndexInList(selectedItem,
|
|
548
|
-
if (selectedItemIndex <
|
|
549
|
-
let movedItem =
|
|
550
|
-
let temp =
|
|
551
|
-
|
|
552
|
-
|
|
529
|
+
let selectedItemIndex = findIndexInList(selectedItem, value);
|
|
530
|
+
if (selectedItemIndex < value.length - 1) {
|
|
531
|
+
let movedItem = value[selectedItemIndex];
|
|
532
|
+
let temp = value[selectedItemIndex + 1];
|
|
533
|
+
value[selectedItemIndex + 1] = movedItem;
|
|
534
|
+
value[selectedItemIndex] = temp;
|
|
553
535
|
}
|
|
554
536
|
}
|
|
555
|
-
if (this.dragdrop) {
|
|
556
|
-
if (this.filterValue) {
|
|
537
|
+
if (this.dragdrop()) {
|
|
538
|
+
if (this.filterValue()) {
|
|
557
539
|
this.filter();
|
|
558
540
|
}
|
|
559
|
-
else if (this.visibleOptions) {
|
|
560
|
-
this.visibleOptions
|
|
541
|
+
else if (this.visibleOptions()) {
|
|
542
|
+
this.visibleOptions.set([...value]);
|
|
561
543
|
}
|
|
562
544
|
}
|
|
563
|
-
this.movedDown
|
|
564
|
-
this.onReorder.emit(this.selection);
|
|
545
|
+
this.movedDown.set(true);
|
|
546
|
+
this.onReorder.emit(this.selection());
|
|
565
547
|
}
|
|
566
548
|
this.listViewChild().cd?.markForCheck();
|
|
567
549
|
}
|
|
568
550
|
moveBottom() {
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
let
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
551
|
+
const value = this.value();
|
|
552
|
+
if (this.selection()) {
|
|
553
|
+
for (let i = 0; i < this.selection().length; i++) {
|
|
554
|
+
let selectedItem = this.selection()[i];
|
|
555
|
+
let selectedItemIndex = findIndexInList(selectedItem, value || []);
|
|
556
|
+
if (value instanceof Array && selectedItemIndex != value.length - 1) {
|
|
557
|
+
let movedItem = value.splice(selectedItemIndex, 1)[0];
|
|
558
|
+
value.push(movedItem);
|
|
576
559
|
}
|
|
577
560
|
else {
|
|
578
561
|
break;
|
|
579
562
|
}
|
|
580
563
|
}
|
|
581
|
-
if (this.dragdrop) {
|
|
582
|
-
if (this.filterValue) {
|
|
564
|
+
if (this.dragdrop()) {
|
|
565
|
+
if (this.filterValue()) {
|
|
583
566
|
this.filter();
|
|
584
567
|
}
|
|
585
|
-
else if (this.visibleOptions) {
|
|
586
|
-
this.visibleOptions
|
|
568
|
+
else if (this.visibleOptions()) {
|
|
569
|
+
this.visibleOptions.set([...(value || [])]);
|
|
587
570
|
}
|
|
588
571
|
}
|
|
589
|
-
this.onReorder.emit(this.selection);
|
|
590
|
-
this.listViewChild().scrollInView(
|
|
572
|
+
this.onReorder.emit(this.selection());
|
|
573
|
+
this.listViewChild().scrollInView(value?.length ? value.length - 1 : 0);
|
|
591
574
|
}
|
|
592
575
|
this.listViewChild().cd?.markForCheck();
|
|
593
576
|
}
|
|
594
577
|
onDrop(event) {
|
|
595
578
|
let previousIndex = event.previousIndex;
|
|
596
579
|
let currentIndex = event.currentIndex;
|
|
580
|
+
const value = this.value();
|
|
597
581
|
// Store the original state before any modifications
|
|
598
|
-
const originalValue = [...(
|
|
599
|
-
const
|
|
582
|
+
const originalValue = [...(value || [])];
|
|
583
|
+
const visibleOptions = this.visibleOptions();
|
|
584
|
+
const originalVisibleOptions = visibleOptions ? [...visibleOptions] : null;
|
|
600
585
|
if (previousIndex !== currentIndex) {
|
|
601
586
|
// Determine items to move
|
|
602
587
|
let itemsToMove = [];
|
|
603
588
|
// Check if dragged item is in selected items AND we have multiple selections
|
|
604
|
-
if (this.selection && this.selection.length > 1 && findIndexInList(event.item.data, this.selection) !== -1) {
|
|
589
|
+
if (this.selection() && this.selection().length > 1 && findIndexInList(event.item.data, this.selection()) !== -1) {
|
|
605
590
|
// Multi-selection: Move all selected items
|
|
606
|
-
itemsToMove = [...this.selection];
|
|
591
|
+
itemsToMove = [...this.selection()];
|
|
607
592
|
// For multi-selection, restore original state to undo Listbox's automatic reordering
|
|
608
|
-
if (
|
|
609
|
-
|
|
610
|
-
|
|
593
|
+
if (value) {
|
|
594
|
+
value.length = 0;
|
|
595
|
+
value.push(...originalValue);
|
|
611
596
|
}
|
|
612
|
-
if (originalVisibleOptions && this.visibleOptions) {
|
|
613
|
-
this.visibleOptions.
|
|
614
|
-
this.visibleOptions.push(...originalVisibleOptions);
|
|
597
|
+
if (originalVisibleOptions && this.visibleOptions()) {
|
|
598
|
+
this.visibleOptions.set([...originalVisibleOptions]);
|
|
615
599
|
}
|
|
616
600
|
// Sort items by their index in the array to maintain relative order
|
|
617
|
-
itemsToMove = this.sortByIndexInList(itemsToMove,
|
|
601
|
+
itemsToMove = this.sortByIndexInList(itemsToMove, value || []);
|
|
618
602
|
// Calculate how many selected items are before the drop position
|
|
619
603
|
let itemsBefore = 0;
|
|
620
604
|
for (const item of itemsToMove) {
|
|
621
|
-
const itemIndex = findIndexInList(item,
|
|
605
|
+
const itemIndex = findIndexInList(item, value || []);
|
|
622
606
|
if (itemIndex !== -1 && itemIndex < currentIndex) {
|
|
623
607
|
itemsBefore++;
|
|
624
608
|
}
|
|
625
609
|
}
|
|
626
610
|
// Remove all selected items (in reverse order to avoid index shifting)
|
|
627
611
|
for (let i = itemsToMove.length - 1; i >= 0; i--) {
|
|
628
|
-
const itemIndex = findIndexInList(itemsToMove[i],
|
|
612
|
+
const itemIndex = findIndexInList(itemsToMove[i], value || []);
|
|
629
613
|
if (itemIndex !== -1) {
|
|
630
|
-
|
|
614
|
+
value?.splice(itemIndex, 1);
|
|
631
615
|
}
|
|
632
616
|
}
|
|
633
617
|
// Calculate the final target index
|
|
@@ -635,15 +619,15 @@ class OrderList extends BaseComponent {
|
|
|
635
619
|
const targetIndex = Math.max(0, currentIndex - itemsBefore);
|
|
636
620
|
// Insert all selected items at the target position
|
|
637
621
|
for (let i = 0; i < itemsToMove.length; i++) {
|
|
638
|
-
|
|
622
|
+
value?.splice(targetIndex + i, 0, itemsToMove[i]);
|
|
639
623
|
}
|
|
640
624
|
// Update visibleOptions to match value
|
|
641
|
-
if (this.dragdrop) {
|
|
642
|
-
if (this.filterValue) {
|
|
625
|
+
if (this.dragdrop()) {
|
|
626
|
+
if (this.filterValue()) {
|
|
643
627
|
this.filter();
|
|
644
628
|
}
|
|
645
|
-
else if (this.visibleOptions) {
|
|
646
|
-
this.visibleOptions
|
|
629
|
+
else if (this.visibleOptions()) {
|
|
630
|
+
this.visibleOptions.set([...(value || [])]);
|
|
647
631
|
}
|
|
648
632
|
}
|
|
649
633
|
// Ensure change detection runs
|
|
@@ -653,14 +637,14 @@ class OrderList extends BaseComponent {
|
|
|
653
637
|
else {
|
|
654
638
|
// Single item: Move only the dragged item (let Listbox handle it)
|
|
655
639
|
itemsToMove = [event.item.data];
|
|
656
|
-
if (this.filterValue) {
|
|
657
|
-
previousIndex = findIndexInList(event.item.data,
|
|
658
|
-
currentIndex = findIndexInList(this.visibleOptions?.[currentIndex],
|
|
640
|
+
if (this.filterValue()) {
|
|
641
|
+
previousIndex = findIndexInList(event.item.data, value || []);
|
|
642
|
+
currentIndex = findIndexInList(this.visibleOptions()?.[currentIndex], value || []);
|
|
659
643
|
}
|
|
660
|
-
moveItemInArray(
|
|
644
|
+
moveItemInArray(value, previousIndex, currentIndex);
|
|
661
645
|
// Sync visibleOptions for non-filtered case
|
|
662
|
-
if (this.dragdrop && this.visibleOptions && !this.filterValue) {
|
|
663
|
-
this.visibleOptions
|
|
646
|
+
if (this.dragdrop() && this.visibleOptions() && !this.filterValue()) {
|
|
647
|
+
this.visibleOptions.set([...(value || [])]);
|
|
664
648
|
}
|
|
665
649
|
this.onReorder.emit([event.item.data]);
|
|
666
650
|
}
|
|
@@ -680,24 +664,28 @@ class OrderList extends BaseComponent {
|
|
|
680
664
|
onListBlur(event) {
|
|
681
665
|
this.onBlur.emit(event);
|
|
682
666
|
}
|
|
683
|
-
getVisibleOptions() {
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
667
|
+
getVisibleOptions = computed(() => {
|
|
668
|
+
const visibleOptions = this.visibleOptions();
|
|
669
|
+
const value = this.value();
|
|
670
|
+
return visibleOptions && visibleOptions.length > 0 ? visibleOptions : value && value.length > 0 ? value : null;
|
|
671
|
+
}, /* @ts-ignore */
|
|
672
|
+
...(ngDevMode ? [{ debugName: "getVisibleOptions" }] : /* istanbul ignore next */ []));
|
|
673
|
+
moveDisabled = computed(() => {
|
|
674
|
+
if (this.disabled() || !this.selection().length) {
|
|
688
675
|
return true;
|
|
689
676
|
}
|
|
690
|
-
}
|
|
677
|
+
}, /* @ts-ignore */
|
|
678
|
+
...(ngDevMode ? [{ debugName: "moveDisabled" }] : /* istanbul ignore next */ []));
|
|
691
679
|
createStyle() {
|
|
692
680
|
if (isPlatformBrowser(this.platformId)) {
|
|
693
|
-
if (!this.styleElement) {
|
|
681
|
+
if (!this.styleElement()) {
|
|
694
682
|
this.renderer.setAttribute(this.el.nativeElement.children[0], this.id, '');
|
|
695
|
-
this.styleElement
|
|
696
|
-
this.renderer.setAttribute(this.styleElement, 'type', 'text/css');
|
|
697
|
-
setAttribute(this.styleElement, 'nonce', this.config?.csp()?.nonce);
|
|
698
|
-
this.renderer.appendChild(this.document.head, this.styleElement);
|
|
683
|
+
this.styleElement.set(this.renderer.createElement('style'));
|
|
684
|
+
this.renderer.setAttribute(this.styleElement(), 'type', 'text/css');
|
|
685
|
+
setAttribute(this.styleElement(), 'nonce', this.config?.csp()?.nonce);
|
|
686
|
+
this.renderer.appendChild(this.document.head, this.styleElement());
|
|
699
687
|
let innerHTML = `
|
|
700
|
-
@media screen and (max-width: ${this.breakpoint}) {
|
|
688
|
+
@media screen and (max-width: ${this.breakpoint()}) {
|
|
701
689
|
.p-orderlist[${this.$attrSelector}] {
|
|
702
690
|
flex-direction: column;
|
|
703
691
|
}
|
|
@@ -717,16 +705,16 @@ class OrderList extends BaseComponent {
|
|
|
717
705
|
}
|
|
718
706
|
}
|
|
719
707
|
`;
|
|
720
|
-
this.renderer.setProperty(this.styleElement, 'innerHTML', innerHTML);
|
|
721
|
-
setAttribute(this.styleElement, 'nonce', this.config?.csp()?.nonce);
|
|
708
|
+
this.renderer.setProperty(this.styleElement(), 'innerHTML', innerHTML);
|
|
709
|
+
setAttribute(this.styleElement(), 'nonce', this.config?.csp()?.nonce);
|
|
722
710
|
}
|
|
723
711
|
}
|
|
724
712
|
}
|
|
725
713
|
destroyStyle() {
|
|
726
714
|
if (isPlatformBrowser(this.platformId)) {
|
|
727
|
-
if (this.styleElement) {
|
|
728
|
-
this.renderer.removeChild(this.document, this.styleElement);
|
|
729
|
-
this.styleElement
|
|
715
|
+
if (this.styleElement()) {
|
|
716
|
+
this.renderer.removeChild(this.document, this.styleElement());
|
|
717
|
+
this.styleElement.set(null);
|
|
730
718
|
``;
|
|
731
719
|
}
|
|
732
720
|
}
|
|
@@ -734,20 +722,20 @@ class OrderList extends BaseComponent {
|
|
|
734
722
|
onDestroy() {
|
|
735
723
|
this.destroyStyle();
|
|
736
724
|
}
|
|
737
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: OrderList, deps:
|
|
738
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.2.1", type: OrderList, isStandalone: true, selector: "p-orderList, p-orderlist, p-order-list", inputs: { header: "header",
|
|
725
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: OrderList, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
726
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.2.1", type: OrderList, isStandalone: true, selector: "p-orderList, p-orderlist, p-order-list", inputs: { header: { classPropertyName: "header", publicName: "header", isSignal: true, isRequired: false, transformFunction: null }, tabindex: { classPropertyName: "tabindex", publicName: "tabindex", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledBy: { classPropertyName: "ariaLabelledBy", publicName: "ariaLabelledBy", isSignal: true, isRequired: false, transformFunction: null }, listStyle: { classPropertyName: "listStyle", publicName: "listStyle", isSignal: true, isRequired: false, transformFunction: null }, responsive: { classPropertyName: "responsive", publicName: "responsive", isSignal: true, isRequired: false, transformFunction: null }, filterBy: { classPropertyName: "filterBy", publicName: "filterBy", isSignal: true, isRequired: false, transformFunction: null }, filterPlaceholder: { classPropertyName: "filterPlaceholder", publicName: "filterPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, filterLocale: { classPropertyName: "filterLocale", publicName: "filterLocale", isSignal: true, isRequired: false, transformFunction: null }, metaKeySelection: { classPropertyName: "metaKeySelection", publicName: "metaKeySelection", isSignal: true, isRequired: false, transformFunction: null }, dragdrop: { classPropertyName: "dragdrop", publicName: "dragdrop", isSignal: true, isRequired: false, transformFunction: null }, controlsPosition: { classPropertyName: "controlsPosition", publicName: "controlsPosition", isSignal: true, isRequired: false, transformFunction: null }, ariaFilterLabel: { classPropertyName: "ariaFilterLabel", publicName: "ariaFilterLabel", isSignal: true, isRequired: false, transformFunction: null }, filterMatchMode: { classPropertyName: "filterMatchMode", publicName: "filterMatchMode", isSignal: true, isRequired: false, transformFunction: null }, breakpoint: { classPropertyName: "breakpoint", publicName: "breakpoint", isSignal: true, isRequired: false, transformFunction: null }, stripedRows: { classPropertyName: "stripedRows", publicName: "stripedRows", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, trackBy: { classPropertyName: "trackBy", publicName: "trackBy", isSignal: true, isRequired: false, transformFunction: null }, scrollHeight: { classPropertyName: "scrollHeight", publicName: "scrollHeight", isSignal: true, isRequired: false, transformFunction: null }, autoOptionFocus: { classPropertyName: "autoOptionFocus", publicName: "autoOptionFocus", isSignal: true, isRequired: false, transformFunction: null }, dataKey: { classPropertyName: "dataKey", publicName: "dataKey", isSignal: true, isRequired: false, transformFunction: null }, selection: { classPropertyName: "selection", publicName: "selection", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, buttonProps: { classPropertyName: "buttonProps", publicName: "buttonProps", isSignal: true, isRequired: false, transformFunction: null }, moveUpButtonProps: { classPropertyName: "moveUpButtonProps", publicName: "moveUpButtonProps", isSignal: true, isRequired: false, transformFunction: null }, moveTopButtonProps: { classPropertyName: "moveTopButtonProps", publicName: "moveTopButtonProps", isSignal: true, isRequired: false, transformFunction: null }, moveDownButtonProps: { classPropertyName: "moveDownButtonProps", publicName: "moveDownButtonProps", isSignal: true, isRequired: false, transformFunction: null }, moveBottomButtonProps: { classPropertyName: "moveBottomButtonProps", publicName: "moveBottomButtonProps", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selection: "selectionChange", onReorder: "onReorder", onSelectionChange: "onSelectionChange", onFilterEvent: "onFilterEvent", onFocus: "onFocus", onBlur: "onBlur" }, host: { properties: { "class": "cx('root')" } }, providers: [OrderListStyle, { provide: ORDERLIST_INSTANCE, useExisting: OrderList }, { provide: PARENT_INSTANCE, useExisting: OrderList }], queries: [{ propertyName: "itemTemplate", first: true, predicate: ["item"], isSignal: true }, { propertyName: "emptyMessageTemplate", first: true, predicate: ["empty"], isSignal: true }, { propertyName: "emptyFilterMessageTemplate", first: true, predicate: ["emptyfilter"], isSignal: true }, { propertyName: "filterTemplate", first: true, predicate: ["filter"], isSignal: true }, { propertyName: "headerTemplate", first: true, predicate: ["header"], isSignal: true }, { propertyName: "moveUpIconTemplate", first: true, predicate: ["moveupicon"], isSignal: true }, { propertyName: "moveTopIconTemplate", first: true, predicate: ["movetopicon"], isSignal: true }, { propertyName: "moveDownIconTemplate", first: true, predicate: ["movedownicon"], isSignal: true }, { propertyName: "moveBottomIconTemplate", first: true, predicate: ["movebottomicon"], isSignal: true }, { propertyName: "filterIconTemplate", first: true, predicate: ["filtericon"], isSignal: true }, { propertyName: "templates", predicate: PrimeTemplate, isSignal: true }], viewQueries: [{ propertyName: "listViewChild", first: true, predicate: ["listelement"], descendants: true, isSignal: true }, { propertyName: "filterViewChild", first: true, predicate: ["filter"], descendants: true, isSignal: true }], usesInheritance: true, hostDirectives: [{ directive: i1.Bind }], ngImport: i0, template: `
|
|
739
727
|
<div [pBind]="ptm('controls')" [class]="cx('controls')">
|
|
740
|
-
<button [pt]="ptm('pcMoveUpButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveUp()" [attr.aria-label]="moveUpAriaLabel" [buttonProps]="getButtonProps('up')" hostName="orderlist" [unstyled]="unstyled()">
|
|
741
|
-
@if (!moveUpIconTemplate() && !_moveUpIconTemplate) {
|
|
728
|
+
<button [pt]="ptm('pcMoveUpButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveUp()" [attr.aria-label]="moveUpAriaLabel()" [buttonProps]="getButtonProps('up')" hostName="orderlist" [unstyled]="unstyled()">
|
|
729
|
+
@if (!moveUpIconTemplate() && !_moveUpIconTemplate()) {
|
|
742
730
|
<svg data-p-icon="angle-up" pButtonIcon [pt]="ptm('pcMoveUpButton')['icon']" />
|
|
743
731
|
}
|
|
744
|
-
<ng-template *ngTemplateOutlet="moveUpIconTemplate() || _moveUpIconTemplate"></ng-template>
|
|
732
|
+
<ng-template *ngTemplateOutlet="moveUpIconTemplate() || _moveUpIconTemplate()"></ng-template>
|
|
745
733
|
</button>
|
|
746
|
-
<button [pt]="ptm('pcMoveTopButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveTop()" [attr.aria-label]="moveTopAriaLabel" [buttonProps]="getButtonProps('top')" hostName="orderlist" [unstyled]="unstyled()">
|
|
747
|
-
@if (!moveTopIconTemplate() && !_moveTopIconTemplate) {
|
|
734
|
+
<button [pt]="ptm('pcMoveTopButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveTop()" [attr.aria-label]="moveTopAriaLabel()" [buttonProps]="getButtonProps('top')" hostName="orderlist" [unstyled]="unstyled()">
|
|
735
|
+
@if (!moveTopIconTemplate() && !_moveTopIconTemplate()) {
|
|
748
736
|
<svg data-p-icon="angle-double-up" pButtonIcon [pt]="ptm('pcMoveTopButton')['icon']" />
|
|
749
737
|
}
|
|
750
|
-
<ng-template *ngTemplateOutlet="moveTopIconTemplate() || _moveTopIconTemplate"></ng-template>
|
|
738
|
+
<ng-template *ngTemplateOutlet="moveTopIconTemplate() || _moveTopIconTemplate()"></ng-template>
|
|
751
739
|
</button>
|
|
752
740
|
<button
|
|
753
741
|
[pt]="ptm('pcMoveDownButton')"
|
|
@@ -756,15 +744,15 @@ class OrderList extends BaseComponent {
|
|
|
756
744
|
pButton
|
|
757
745
|
pRipple
|
|
758
746
|
(click)="moveDown()"
|
|
759
|
-
[attr.aria-label]="moveDownAriaLabel"
|
|
747
|
+
[attr.aria-label]="moveDownAriaLabel()"
|
|
760
748
|
[buttonProps]="getButtonProps('down')"
|
|
761
749
|
hostName="orderlist"
|
|
762
750
|
[unstyled]="unstyled()"
|
|
763
751
|
>
|
|
764
|
-
@if (!moveDownIconTemplate() && !_moveDownIconTemplate) {
|
|
752
|
+
@if (!moveDownIconTemplate() && !_moveDownIconTemplate()) {
|
|
765
753
|
<svg data-p-icon="angle-down" pButtonIcon [pt]="ptm('pcMoveDownButton')['icon']" />
|
|
766
754
|
}
|
|
767
|
-
<ng-template *ngTemplateOutlet="moveDownIconTemplate() || _moveDownIconTemplate"></ng-template>
|
|
755
|
+
<ng-template *ngTemplateOutlet="moveDownIconTemplate() || _moveDownIconTemplate()"></ng-template>
|
|
768
756
|
</button>
|
|
769
757
|
<button
|
|
770
758
|
[pt]="ptm('pcMoveBottomButton')"
|
|
@@ -773,98 +761,100 @@ class OrderList extends BaseComponent {
|
|
|
773
761
|
pButton
|
|
774
762
|
pRipple
|
|
775
763
|
(click)="moveBottom()"
|
|
776
|
-
[attr.aria-label]="moveBottomAriaLabel"
|
|
764
|
+
[attr.aria-label]="moveBottomAriaLabel()"
|
|
777
765
|
[buttonProps]="getButtonProps('bottom')"
|
|
778
766
|
hostName="orderlist"
|
|
779
767
|
[unstyled]="unstyled()"
|
|
780
768
|
>
|
|
781
|
-
@if (!moveBottomIconTemplate() && !_moveBottomIconTemplate) {
|
|
769
|
+
@if (!moveBottomIconTemplate() && !_moveBottomIconTemplate()) {
|
|
782
770
|
<svg data-p-icon="angle-double-down" pButtonIcon [pt]="ptm('pcMoveBottomButton')['icon']" />
|
|
783
771
|
}
|
|
784
|
-
<ng-template *ngTemplateOutlet="moveBottomIconTemplate() || _moveBottomIconTemplate"></ng-template>
|
|
772
|
+
<ng-template *ngTemplateOutlet="moveBottomIconTemplate() || _moveBottomIconTemplate()"></ng-template>
|
|
785
773
|
</button>
|
|
786
774
|
</div>
|
|
787
775
|
<p-listbox
|
|
788
776
|
[pt]="ptm('pcListbox')"
|
|
789
777
|
#listelement
|
|
790
778
|
[multiple]="true"
|
|
791
|
-
[options]="value"
|
|
792
|
-
[
|
|
779
|
+
[options]="value()"
|
|
780
|
+
[ngModel]="selection()"
|
|
793
781
|
[ngModelOptions]="{ standalone: true }"
|
|
794
|
-
[optionLabel]="dataKey ?? 'name'"
|
|
782
|
+
[optionLabel]="dataKey() ?? 'name'"
|
|
795
783
|
[id]="id + '_list'"
|
|
796
|
-
[listStyle]="listStyle"
|
|
797
|
-
[striped]="stripedRows"
|
|
798
|
-
[tabindex]="tabindex"
|
|
784
|
+
[listStyle]="listStyle()"
|
|
785
|
+
[striped]="stripedRows()"
|
|
786
|
+
[tabindex]="tabindex()"
|
|
799
787
|
(onFocus)="onListFocus($event)"
|
|
800
788
|
(onBlur)="onListBlur($event)"
|
|
801
789
|
(onChange)="onChangeSelection($event)"
|
|
802
|
-
[ariaLabel]="ariaLabel"
|
|
803
|
-
[disabled]="disabled"
|
|
804
|
-
[metaKeySelection]="metaKeySelection"
|
|
805
|
-
[scrollHeight]="scrollHeight"
|
|
806
|
-
[autoOptionFocus]="autoOptionFocus"
|
|
807
|
-
[filter]="filterBy"
|
|
808
|
-
[filterBy]="filterBy"
|
|
809
|
-
[filterLocale]="filterLocale"
|
|
810
|
-
[
|
|
811
|
-
[
|
|
790
|
+
[ariaLabel]="ariaLabel()"
|
|
791
|
+
[disabled]="disabled()"
|
|
792
|
+
[metaKeySelection]="metaKeySelection()"
|
|
793
|
+
[scrollHeight]="scrollHeight()"
|
|
794
|
+
[autoOptionFocus]="autoOptionFocus()"
|
|
795
|
+
[filter]="filterBy()"
|
|
796
|
+
[filterBy]="filterBy()"
|
|
797
|
+
[filterLocale]="filterLocale()"
|
|
798
|
+
[filterMatchMode]="filterMatchMode()"
|
|
799
|
+
[filterPlaceHolder]="filterPlaceholder()"
|
|
800
|
+
[ariaFilterLabel]="ariaFilterLabel()"
|
|
801
|
+
(onFilter)="onFilterKeyup($event.originalEvent)"
|
|
802
|
+
[dragdrop]="dragdrop()"
|
|
812
803
|
(onDrop)="onDrop($event)"
|
|
813
804
|
hostName="orderlist"
|
|
814
805
|
[unstyled]="unstyled()"
|
|
815
806
|
>
|
|
816
|
-
@if (headerTemplate() || _headerTemplate) {
|
|
807
|
+
@if (headerTemplate() || _headerTemplate()) {
|
|
817
808
|
<ng-template #header>
|
|
818
|
-
<ng-template *ngTemplateOutlet="headerTemplate() || _headerTemplate"></ng-template>
|
|
809
|
+
<ng-template *ngTemplateOutlet="headerTemplate() || _headerTemplate()"></ng-template>
|
|
819
810
|
</ng-template>
|
|
820
811
|
}
|
|
821
|
-
@if (itemTemplate() || _itemTemplate) {
|
|
812
|
+
@if (itemTemplate() || _itemTemplate()) {
|
|
822
813
|
<ng-template #item let-option let-selected="selected" let-index="index">
|
|
823
|
-
<ng-template *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: option, selected: selected, index: index }"></ng-template>
|
|
814
|
+
<ng-template *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: option, selected: selected, index: index }"></ng-template>
|
|
824
815
|
</ng-template>
|
|
825
816
|
}
|
|
826
|
-
@if (emptyMessageTemplate() || _emptyMessageTemplate) {
|
|
817
|
+
@if (emptyMessageTemplate() || _emptyMessageTemplate()) {
|
|
827
818
|
<ng-template #empty>
|
|
828
|
-
<ng-template *ngTemplateOutlet="emptyMessageTemplate() || _emptyMessageTemplate"></ng-template>
|
|
819
|
+
<ng-template *ngTemplateOutlet="emptyMessageTemplate() || _emptyMessageTemplate()"></ng-template>
|
|
829
820
|
</ng-template>
|
|
830
821
|
}
|
|
831
|
-
@if (emptyFilterMessageTemplate() || _emptyFilterMessageTemplate) {
|
|
822
|
+
@if (emptyFilterMessageTemplate() || _emptyFilterMessageTemplate()) {
|
|
832
823
|
<ng-template #emptyfilter>
|
|
833
|
-
<ng-template *ngTemplateOutlet="emptyFilterMessageTemplate() || _emptyFilterMessageTemplate"></ng-template>
|
|
824
|
+
<ng-template *ngTemplateOutlet="emptyFilterMessageTemplate() || _emptyFilterMessageTemplate()"></ng-template>
|
|
834
825
|
</ng-template>
|
|
835
826
|
}
|
|
836
|
-
@if (filterIconTemplate() || _filterIconTemplate) {
|
|
827
|
+
@if (filterIconTemplate() || _filterIconTemplate()) {
|
|
837
828
|
<ng-template #filtericon>
|
|
838
|
-
<ng-template *ngTemplateOutlet="filterIconTemplate() || _filterIconTemplate"></ng-template>
|
|
829
|
+
<ng-template *ngTemplateOutlet="filterIconTemplate() || _filterIconTemplate()"></ng-template>
|
|
839
830
|
</ng-template>
|
|
840
831
|
}
|
|
841
|
-
@if (filterTemplate() || _filterTemplate) {
|
|
832
|
+
@if (filterTemplate() || _filterTemplate()) {
|
|
842
833
|
<ng-template #filter let-options="options">
|
|
843
|
-
<ng-template *ngTemplateOutlet="filterTemplate() || _filterTemplate; context: { options: options }"></ng-template>
|
|
834
|
+
<ng-template *ngTemplateOutlet="filterTemplate() || _filterTemplate(); context: { options: options }"></ng-template>
|
|
844
835
|
</ng-template>
|
|
845
836
|
}
|
|
846
837
|
</p-listbox>
|
|
847
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["ptButtonDirective", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "rounded", "iconPos", "loadingIcon", "fluid", "label", "icon", "loading", "buttonProps", "severity"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["ptButtonIcon", "pButtonIconPT", "pButtonUnstyled"] }, { kind: "directive", type: Ripple, selector: "[pRipple]" }, { kind: "ngmodule", type: DragDropModule }, { kind: "component", type: AngleDoubleDownIcon, selector: "[data-p-icon=\"angle-double-down\"]" }, { kind: "component", type: AngleDoubleUpIcon, selector: "[data-p-icon=\"angle-double-up\"]" }, { kind: "component", type: AngleUpIcon, selector: "[data-p-icon=\"angle-up\"]" }, { kind: "component", type: AngleDownIcon, selector: "[data-p-icon=\"angle-down\"]" }, { kind: "component", type: Listbox, selector: "p-listbox, p-listBox, p-list-box", inputs: ["hostName", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "ariaLabel", "selectOnFocus", "searchLocale", "focusOnHover", "filterMessage", "filterFields", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "scrollHeight", "tabindex", "multiple", "
|
|
838
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["ptButtonDirective", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "rounded", "iconPos", "loadingIcon", "fluid", "label", "icon", "loading", "buttonProps", "severity"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["ptButtonIcon", "pButtonIconPT", "pButtonUnstyled"] }, { kind: "directive", type: Ripple, selector: "[pRipple]" }, { kind: "ngmodule", type: DragDropModule }, { kind: "component", type: AngleDoubleDownIcon, selector: "[data-p-icon=\"angle-double-down\"]" }, { kind: "component", type: AngleDoubleUpIcon, selector: "[data-p-icon=\"angle-double-up\"]" }, { kind: "component", type: AngleUpIcon, selector: "[data-p-icon=\"angle-up\"]" }, { kind: "component", type: AngleDownIcon, selector: "[data-p-icon=\"angle-down\"]" }, { kind: "component", type: Listbox, selector: "p-listbox, p-listBox, p-list-box", inputs: ["hostName", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "ariaLabel", "selectOnFocus", "searchLocale", "focusOnHover", "filterMessage", "filterFields", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "scrollHeight", "tabindex", "multiple", "listStyle", "listStyleClass", "readonly", "checkbox", "filter", "filterBy", "filterMatchMode", "filterLocale", "metaKeySelection", "dataKey", "showToggleAll", "optionLabel", "optionValue", "optionGroupChildren", "optionGroupLabel", "optionDisabled", "ariaFilterLabel", "filterPlaceHolder", "emptyFilterMessage", "emptyMessage", "group", "options", "filterValue", "selectAll", "striped", "highlightOnSelect", "checkmark", "dragdrop", "dropListData", "fluid"], outputs: ["onChange", "onClick", "onDblClick", "onFilter", "onFocus", "onBlur", "onSelectAllChange", "onLazyLoad", "onDrop"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: SharedModule }, { kind: "directive", type: Bind, selector: "[pBind]", inputs: ["pBind"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
848
839
|
}
|
|
849
840
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: OrderList, decorators: [{
|
|
850
841
|
type: Component,
|
|
851
842
|
args: [{
|
|
852
843
|
selector: 'p-orderList, p-orderlist, p-order-list',
|
|
853
|
-
standalone: true,
|
|
854
844
|
imports: [CommonModule, ButtonModule, Ripple, DragDropModule, AngleDoubleDownIcon, AngleDoubleUpIcon, AngleUpIcon, AngleDownIcon, Listbox, FormsModule, SharedModule, Bind],
|
|
855
845
|
template: `
|
|
856
846
|
<div [pBind]="ptm('controls')" [class]="cx('controls')">
|
|
857
|
-
<button [pt]="ptm('pcMoveUpButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveUp()" [attr.aria-label]="moveUpAriaLabel" [buttonProps]="getButtonProps('up')" hostName="orderlist" [unstyled]="unstyled()">
|
|
858
|
-
@if (!moveUpIconTemplate() && !_moveUpIconTemplate) {
|
|
847
|
+
<button [pt]="ptm('pcMoveUpButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveUp()" [attr.aria-label]="moveUpAriaLabel()" [buttonProps]="getButtonProps('up')" hostName="orderlist" [unstyled]="unstyled()">
|
|
848
|
+
@if (!moveUpIconTemplate() && !_moveUpIconTemplate()) {
|
|
859
849
|
<svg data-p-icon="angle-up" pButtonIcon [pt]="ptm('pcMoveUpButton')['icon']" />
|
|
860
850
|
}
|
|
861
|
-
<ng-template *ngTemplateOutlet="moveUpIconTemplate() || _moveUpIconTemplate"></ng-template>
|
|
851
|
+
<ng-template *ngTemplateOutlet="moveUpIconTemplate() || _moveUpIconTemplate()"></ng-template>
|
|
862
852
|
</button>
|
|
863
|
-
<button [pt]="ptm('pcMoveTopButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveTop()" [attr.aria-label]="moveTopAriaLabel" [buttonProps]="getButtonProps('top')" hostName="orderlist" [unstyled]="unstyled()">
|
|
864
|
-
@if (!moveTopIconTemplate() && !_moveTopIconTemplate) {
|
|
853
|
+
<button [pt]="ptm('pcMoveTopButton')" type="button" [disabled]="moveDisabled()" pButton pRipple (click)="moveTop()" [attr.aria-label]="moveTopAriaLabel()" [buttonProps]="getButtonProps('top')" hostName="orderlist" [unstyled]="unstyled()">
|
|
854
|
+
@if (!moveTopIconTemplate() && !_moveTopIconTemplate()) {
|
|
865
855
|
<svg data-p-icon="angle-double-up" pButtonIcon [pt]="ptm('pcMoveTopButton')['icon']" />
|
|
866
856
|
}
|
|
867
|
-
<ng-template *ngTemplateOutlet="moveTopIconTemplate() || _moveTopIconTemplate"></ng-template>
|
|
857
|
+
<ng-template *ngTemplateOutlet="moveTopIconTemplate() || _moveTopIconTemplate()"></ng-template>
|
|
868
858
|
</button>
|
|
869
859
|
<button
|
|
870
860
|
[pt]="ptm('pcMoveDownButton')"
|
|
@@ -873,15 +863,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImpor
|
|
|
873
863
|
pButton
|
|
874
864
|
pRipple
|
|
875
865
|
(click)="moveDown()"
|
|
876
|
-
[attr.aria-label]="moveDownAriaLabel"
|
|
866
|
+
[attr.aria-label]="moveDownAriaLabel()"
|
|
877
867
|
[buttonProps]="getButtonProps('down')"
|
|
878
868
|
hostName="orderlist"
|
|
879
869
|
[unstyled]="unstyled()"
|
|
880
870
|
>
|
|
881
|
-
@if (!moveDownIconTemplate() && !_moveDownIconTemplate) {
|
|
871
|
+
@if (!moveDownIconTemplate() && !_moveDownIconTemplate()) {
|
|
882
872
|
<svg data-p-icon="angle-down" pButtonIcon [pt]="ptm('pcMoveDownButton')['icon']" />
|
|
883
873
|
}
|
|
884
|
-
<ng-template *ngTemplateOutlet="moveDownIconTemplate() || _moveDownIconTemplate"></ng-template>
|
|
874
|
+
<ng-template *ngTemplateOutlet="moveDownIconTemplate() || _moveDownIconTemplate()"></ng-template>
|
|
885
875
|
</button>
|
|
886
876
|
<button
|
|
887
877
|
[pt]="ptm('pcMoveBottomButton')"
|
|
@@ -890,74 +880,77 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImpor
|
|
|
890
880
|
pButton
|
|
891
881
|
pRipple
|
|
892
882
|
(click)="moveBottom()"
|
|
893
|
-
[attr.aria-label]="moveBottomAriaLabel"
|
|
883
|
+
[attr.aria-label]="moveBottomAriaLabel()"
|
|
894
884
|
[buttonProps]="getButtonProps('bottom')"
|
|
895
885
|
hostName="orderlist"
|
|
896
886
|
[unstyled]="unstyled()"
|
|
897
887
|
>
|
|
898
|
-
@if (!moveBottomIconTemplate() && !_moveBottomIconTemplate) {
|
|
888
|
+
@if (!moveBottomIconTemplate() && !_moveBottomIconTemplate()) {
|
|
899
889
|
<svg data-p-icon="angle-double-down" pButtonIcon [pt]="ptm('pcMoveBottomButton')['icon']" />
|
|
900
890
|
}
|
|
901
|
-
<ng-template *ngTemplateOutlet="moveBottomIconTemplate() || _moveBottomIconTemplate"></ng-template>
|
|
891
|
+
<ng-template *ngTemplateOutlet="moveBottomIconTemplate() || _moveBottomIconTemplate()"></ng-template>
|
|
902
892
|
</button>
|
|
903
893
|
</div>
|
|
904
894
|
<p-listbox
|
|
905
895
|
[pt]="ptm('pcListbox')"
|
|
906
896
|
#listelement
|
|
907
897
|
[multiple]="true"
|
|
908
|
-
[options]="value"
|
|
909
|
-
[
|
|
898
|
+
[options]="value()"
|
|
899
|
+
[ngModel]="selection()"
|
|
910
900
|
[ngModelOptions]="{ standalone: true }"
|
|
911
|
-
[optionLabel]="dataKey ?? 'name'"
|
|
901
|
+
[optionLabel]="dataKey() ?? 'name'"
|
|
912
902
|
[id]="id + '_list'"
|
|
913
|
-
[listStyle]="listStyle"
|
|
914
|
-
[striped]="stripedRows"
|
|
915
|
-
[tabindex]="tabindex"
|
|
903
|
+
[listStyle]="listStyle()"
|
|
904
|
+
[striped]="stripedRows()"
|
|
905
|
+
[tabindex]="tabindex()"
|
|
916
906
|
(onFocus)="onListFocus($event)"
|
|
917
907
|
(onBlur)="onListBlur($event)"
|
|
918
908
|
(onChange)="onChangeSelection($event)"
|
|
919
|
-
[ariaLabel]="ariaLabel"
|
|
920
|
-
[disabled]="disabled"
|
|
921
|
-
[metaKeySelection]="metaKeySelection"
|
|
922
|
-
[scrollHeight]="scrollHeight"
|
|
923
|
-
[autoOptionFocus]="autoOptionFocus"
|
|
924
|
-
[filter]="filterBy"
|
|
925
|
-
[filterBy]="filterBy"
|
|
926
|
-
[filterLocale]="filterLocale"
|
|
927
|
-
[
|
|
928
|
-
[
|
|
909
|
+
[ariaLabel]="ariaLabel()"
|
|
910
|
+
[disabled]="disabled()"
|
|
911
|
+
[metaKeySelection]="metaKeySelection()"
|
|
912
|
+
[scrollHeight]="scrollHeight()"
|
|
913
|
+
[autoOptionFocus]="autoOptionFocus()"
|
|
914
|
+
[filter]="filterBy()"
|
|
915
|
+
[filterBy]="filterBy()"
|
|
916
|
+
[filterLocale]="filterLocale()"
|
|
917
|
+
[filterMatchMode]="filterMatchMode()"
|
|
918
|
+
[filterPlaceHolder]="filterPlaceholder()"
|
|
919
|
+
[ariaFilterLabel]="ariaFilterLabel()"
|
|
920
|
+
(onFilter)="onFilterKeyup($event.originalEvent)"
|
|
921
|
+
[dragdrop]="dragdrop()"
|
|
929
922
|
(onDrop)="onDrop($event)"
|
|
930
923
|
hostName="orderlist"
|
|
931
924
|
[unstyled]="unstyled()"
|
|
932
925
|
>
|
|
933
|
-
@if (headerTemplate() || _headerTemplate) {
|
|
926
|
+
@if (headerTemplate() || _headerTemplate()) {
|
|
934
927
|
<ng-template #header>
|
|
935
|
-
<ng-template *ngTemplateOutlet="headerTemplate() || _headerTemplate"></ng-template>
|
|
928
|
+
<ng-template *ngTemplateOutlet="headerTemplate() || _headerTemplate()"></ng-template>
|
|
936
929
|
</ng-template>
|
|
937
930
|
}
|
|
938
|
-
@if (itemTemplate() || _itemTemplate) {
|
|
931
|
+
@if (itemTemplate() || _itemTemplate()) {
|
|
939
932
|
<ng-template #item let-option let-selected="selected" let-index="index">
|
|
940
|
-
<ng-template *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: option, selected: selected, index: index }"></ng-template>
|
|
933
|
+
<ng-template *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: option, selected: selected, index: index }"></ng-template>
|
|
941
934
|
</ng-template>
|
|
942
935
|
}
|
|
943
|
-
@if (emptyMessageTemplate() || _emptyMessageTemplate) {
|
|
936
|
+
@if (emptyMessageTemplate() || _emptyMessageTemplate()) {
|
|
944
937
|
<ng-template #empty>
|
|
945
|
-
<ng-template *ngTemplateOutlet="emptyMessageTemplate() || _emptyMessageTemplate"></ng-template>
|
|
938
|
+
<ng-template *ngTemplateOutlet="emptyMessageTemplate() || _emptyMessageTemplate()"></ng-template>
|
|
946
939
|
</ng-template>
|
|
947
940
|
}
|
|
948
|
-
@if (emptyFilterMessageTemplate() || _emptyFilterMessageTemplate) {
|
|
941
|
+
@if (emptyFilterMessageTemplate() || _emptyFilterMessageTemplate()) {
|
|
949
942
|
<ng-template #emptyfilter>
|
|
950
|
-
<ng-template *ngTemplateOutlet="emptyFilterMessageTemplate() || _emptyFilterMessageTemplate"></ng-template>
|
|
943
|
+
<ng-template *ngTemplateOutlet="emptyFilterMessageTemplate() || _emptyFilterMessageTemplate()"></ng-template>
|
|
951
944
|
</ng-template>
|
|
952
945
|
}
|
|
953
|
-
@if (filterIconTemplate() || _filterIconTemplate) {
|
|
946
|
+
@if (filterIconTemplate() || _filterIconTemplate()) {
|
|
954
947
|
<ng-template #filtericon>
|
|
955
|
-
<ng-template *ngTemplateOutlet="filterIconTemplate() || _filterIconTemplate"></ng-template>
|
|
948
|
+
<ng-template *ngTemplateOutlet="filterIconTemplate() || _filterIconTemplate()"></ng-template>
|
|
956
949
|
</ng-template>
|
|
957
950
|
}
|
|
958
|
-
@if (filterTemplate() || _filterTemplate) {
|
|
951
|
+
@if (filterTemplate() || _filterTemplate()) {
|
|
959
952
|
<ng-template #filter let-options="options">
|
|
960
|
-
<ng-template *ngTemplateOutlet="filterTemplate() || _filterTemplate; context: { options: options }"></ng-template>
|
|
953
|
+
<ng-template *ngTemplateOutlet="filterTemplate() || _filterTemplate(); context: { options: options }"></ng-template>
|
|
961
954
|
</ng-template>
|
|
962
955
|
}
|
|
963
956
|
</p-listbox>
|
|
@@ -966,76 +959,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImpor
|
|
|
966
959
|
encapsulation: ViewEncapsulation.None,
|
|
967
960
|
providers: [OrderListStyle, { provide: ORDERLIST_INSTANCE, useExisting: OrderList }, { provide: PARENT_INSTANCE, useExisting: OrderList }],
|
|
968
961
|
host: {
|
|
969
|
-
'[class]': "
|
|
962
|
+
'[class]': "cx('root')"
|
|
970
963
|
},
|
|
971
964
|
hostDirectives: [Bind]
|
|
972
965
|
}]
|
|
973
|
-
}], propDecorators: { header: [{
|
|
974
|
-
type: Input
|
|
975
|
-
}], styleClass: [{
|
|
976
|
-
type: Input
|
|
977
|
-
}], tabindex: [{
|
|
978
|
-
type: Input,
|
|
979
|
-
args: [{ transform: numberAttribute }]
|
|
980
|
-
}], ariaLabel: [{
|
|
981
|
-
type: Input
|
|
982
|
-
}], ariaLabelledBy: [{
|
|
983
|
-
type: Input
|
|
984
|
-
}], listStyle: [{
|
|
985
|
-
type: Input
|
|
986
|
-
}], responsive: [{
|
|
987
|
-
type: Input,
|
|
988
|
-
args: [{ transform: booleanAttribute }]
|
|
989
|
-
}], filterBy: [{
|
|
990
|
-
type: Input
|
|
991
|
-
}], filterPlaceholder: [{
|
|
992
|
-
type: Input
|
|
993
|
-
}], filterLocale: [{
|
|
994
|
-
type: Input
|
|
995
|
-
}], metaKeySelection: [{
|
|
996
|
-
type: Input,
|
|
997
|
-
args: [{ transform: booleanAttribute }]
|
|
998
|
-
}], dragdrop: [{
|
|
999
|
-
type: Input,
|
|
1000
|
-
args: [{ transform: booleanAttribute }]
|
|
1001
|
-
}], controlsPosition: [{
|
|
1002
|
-
type: Input
|
|
1003
|
-
}], ariaFilterLabel: [{
|
|
1004
|
-
type: Input
|
|
1005
|
-
}], filterMatchMode: [{
|
|
1006
|
-
type: Input
|
|
1007
|
-
}], breakpoint: [{
|
|
1008
|
-
type: Input
|
|
1009
|
-
}], stripedRows: [{
|
|
1010
|
-
type: Input,
|
|
1011
|
-
args: [{ transform: booleanAttribute }]
|
|
1012
|
-
}], disabled: [{
|
|
1013
|
-
type: Input,
|
|
1014
|
-
args: [{ transform: booleanAttribute }]
|
|
1015
|
-
}], trackBy: [{
|
|
1016
|
-
type: Input
|
|
1017
|
-
}], scrollHeight: [{
|
|
1018
|
-
type: Input
|
|
1019
|
-
}], autoOptionFocus: [{
|
|
1020
|
-
type: Input,
|
|
1021
|
-
args: [{ transform: booleanAttribute }]
|
|
1022
|
-
}], dataKey: [{
|
|
1023
|
-
type: Input
|
|
1024
|
-
}], selection: [{
|
|
1025
|
-
type: Input
|
|
1026
|
-
}], value: [{
|
|
1027
|
-
type: Input
|
|
1028
|
-
}], buttonProps: [{
|
|
1029
|
-
type: Input
|
|
1030
|
-
}], moveUpButtonProps: [{
|
|
1031
|
-
type: Input
|
|
1032
|
-
}], moveTopButtonProps: [{
|
|
1033
|
-
type: Input
|
|
1034
|
-
}], moveDownButtonProps: [{
|
|
1035
|
-
type: Input
|
|
1036
|
-
}], moveBottomButtonProps: [{
|
|
1037
|
-
type: Input
|
|
1038
|
-
}], selectionChange: [{ type: i0.Output, args: ["selectionChange"] }], onReorder: [{ type: i0.Output, args: ["onReorder"] }], onSelectionChange: [{ type: i0.Output, args: ["onSelectionChange"] }], onFilterEvent: [{ type: i0.Output, args: ["onFilterEvent"] }], onFocus: [{ type: i0.Output, args: ["onFocus"] }], onBlur: [{ type: i0.Output, args: ["onBlur"] }], listViewChild: [{ type: i0.ViewChild, args: ['listelement', { isSignal: true }] }], filterViewChild: [{ type: i0.ViewChild, args: ['filter', { isSignal: true }] }], itemTemplate: [{ type: i0.ContentChild, args: ['item', { ...{ descendants: false }, isSignal: true }] }], emptyMessageTemplate: [{ type: i0.ContentChild, args: ['empty', { ...{ descendants: false }, isSignal: true }] }], emptyFilterMessageTemplate: [{ type: i0.ContentChild, args: ['emptyfilter', { ...{ descendants: false }, isSignal: true }] }], filterTemplate: [{ type: i0.ContentChild, args: ['filter', { ...{ descendants: false }, isSignal: true }] }], headerTemplate: [{ type: i0.ContentChild, args: ['header', { ...{ descendants: false }, isSignal: true }] }], moveUpIconTemplate: [{ type: i0.ContentChild, args: ['moveupicon', { ...{ descendants: false }, isSignal: true }] }], moveTopIconTemplate: [{ type: i0.ContentChild, args: ['movetopicon', { ...{ descendants: false }, isSignal: true }] }], moveDownIconTemplate: [{ type: i0.ContentChild, args: ['movedownicon', { ...{ descendants: false }, isSignal: true }] }], moveBottomIconTemplate: [{ type: i0.ContentChild, args: ['movebottomicon', { ...{ descendants: false }, isSignal: true }] }], filterIconTemplate: [{ type: i0.ContentChild, args: ['filtericon', { ...{ descendants: false }, isSignal: true }] }], templates: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => PrimeTemplate), { isSignal: true }] }] } });
|
|
966
|
+
}], ctorParameters: () => [], propDecorators: { header: [{ type: i0.Input, args: [{ isSignal: true, alias: "header", required: false }] }], tabindex: [{ type: i0.Input, args: [{ isSignal: true, alias: "tabindex", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], ariaLabelledBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelledBy", required: false }] }], listStyle: [{ type: i0.Input, args: [{ isSignal: true, alias: "listStyle", required: false }] }], responsive: [{ type: i0.Input, args: [{ isSignal: true, alias: "responsive", required: false }] }], filterBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterBy", required: false }] }], filterPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterPlaceholder", required: false }] }], filterLocale: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterLocale", required: false }] }], metaKeySelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "metaKeySelection", required: false }] }], dragdrop: [{ type: i0.Input, args: [{ isSignal: true, alias: "dragdrop", required: false }] }], controlsPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "controlsPosition", required: false }] }], ariaFilterLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaFilterLabel", required: false }] }], filterMatchMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterMatchMode", required: false }] }], breakpoint: [{ type: i0.Input, args: [{ isSignal: true, alias: "breakpoint", required: false }] }], stripedRows: [{ type: i0.Input, args: [{ isSignal: true, alias: "stripedRows", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], trackBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "trackBy", required: false }] }], scrollHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "scrollHeight", required: false }] }], autoOptionFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoOptionFocus", required: false }] }], dataKey: [{ type: i0.Input, args: [{ isSignal: true, alias: "dataKey", required: false }] }], selection: [{ type: i0.Input, args: [{ isSignal: true, alias: "selection", required: false }] }, { type: i0.Output, args: ["selectionChange"] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }], buttonProps: [{ type: i0.Input, args: [{ isSignal: true, alias: "buttonProps", required: false }] }], moveUpButtonProps: [{ type: i0.Input, args: [{ isSignal: true, alias: "moveUpButtonProps", required: false }] }], moveTopButtonProps: [{ type: i0.Input, args: [{ isSignal: true, alias: "moveTopButtonProps", required: false }] }], moveDownButtonProps: [{ type: i0.Input, args: [{ isSignal: true, alias: "moveDownButtonProps", required: false }] }], moveBottomButtonProps: [{ type: i0.Input, args: [{ isSignal: true, alias: "moveBottomButtonProps", required: false }] }], onReorder: [{ type: i0.Output, args: ["onReorder"] }], onSelectionChange: [{ type: i0.Output, args: ["onSelectionChange"] }], onFilterEvent: [{ type: i0.Output, args: ["onFilterEvent"] }], onFocus: [{ type: i0.Output, args: ["onFocus"] }], onBlur: [{ type: i0.Output, args: ["onBlur"] }], listViewChild: [{ type: i0.ViewChild, args: ['listelement', { isSignal: true }] }], filterViewChild: [{ type: i0.ViewChild, args: ['filter', { isSignal: true }] }], itemTemplate: [{ type: i0.ContentChild, args: ['item', { ...{ descendants: false }, isSignal: true }] }], emptyMessageTemplate: [{ type: i0.ContentChild, args: ['empty', { ...{ descendants: false }, isSignal: true }] }], emptyFilterMessageTemplate: [{ type: i0.ContentChild, args: ['emptyfilter', { ...{ descendants: false }, isSignal: true }] }], filterTemplate: [{ type: i0.ContentChild, args: ['filter', { ...{ descendants: false }, isSignal: true }] }], headerTemplate: [{ type: i0.ContentChild, args: ['header', { ...{ descendants: false }, isSignal: true }] }], moveUpIconTemplate: [{ type: i0.ContentChild, args: ['moveupicon', { ...{ descendants: false }, isSignal: true }] }], moveTopIconTemplate: [{ type: i0.ContentChild, args: ['movetopicon', { ...{ descendants: false }, isSignal: true }] }], moveDownIconTemplate: [{ type: i0.ContentChild, args: ['movedownicon', { ...{ descendants: false }, isSignal: true }] }], moveBottomIconTemplate: [{ type: i0.ContentChild, args: ['movebottomicon', { ...{ descendants: false }, isSignal: true }] }], filterIconTemplate: [{ type: i0.ContentChild, args: ['filtericon', { ...{ descendants: false }, isSignal: true }] }], templates: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => PrimeTemplate), { isSignal: true }] }] } });
|
|
1039
967
|
class OrderListModule {
|
|
1040
968
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: OrderListModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1041
969
|
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "22.2.1", ngImport: i0, type: OrderListModule, imports: [OrderList, SharedModule], exports: [OrderList, SharedModule] });
|