@coolon/angular-ui-powerups 14.14.2 → 14.16.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/esm2020/lib/components/exports.mjs +2 -2
- package/esm2020/lib/components/tables/abstract-table-model.mjs +4 -4
- package/esm2020/lib/components/tables/abstract-table.component.mjs +1 -1
- package/esm2020/lib/components/tables/filter/default-table-filter-model.mjs +55 -0
- package/esm2020/lib/components/tables/filter/table-filter-model.mjs +10 -77
- package/esm2020/lib/components/tables/tree-table/tree-label-column-model.mjs +7 -4
- package/esm2020/lib/components/tables/tree-table/tree-table-model.mjs +1 -1
- package/fesm2015/coolon-angular-ui-powerups.mjs +21 -40
- package/fesm2015/coolon-angular-ui-powerups.mjs.map +1 -1
- package/fesm2020/coolon-angular-ui-powerups.mjs +21 -40
- package/fesm2020/coolon-angular-ui-powerups.mjs.map +1 -1
- package/lib/components/exports.d.ts +1 -1
- package/lib/components/tables/abstract-table-model.d.ts +2 -2
- package/lib/components/tables/filter/default-table-filter-model.d.ts +19 -0
- package/lib/components/tables/filter/table-filter-model.d.ts +7 -21
- package/lib/components/tables/tree-table/tree-label-column-model.d.ts +3 -2
- package/lib/components/tables/tree-table/tree-table-model.d.ts +1 -0
- package/package.json +2 -2
- package/esm2020/lib/components/tables/filter/abstract-table-filter-model.mjs +0 -11
- package/lib/components/tables/filter/abstract-table-filter-model.d.ts +0 -11
|
@@ -3387,9 +3387,9 @@ class SelectionColumnModel extends ColumnModel {
|
|
|
3387
3387
|
}
|
|
3388
3388
|
|
|
3389
3389
|
// TODO: Merge MarsUi FilterRegistry into this.
|
|
3390
|
-
class
|
|
3390
|
+
class TableFilterModel extends GarbageCollector {
|
|
3391
3391
|
}
|
|
3392
|
-
TrackExternal.useDelegate(
|
|
3392
|
+
TrackExternal.useDelegate(TableFilterModel, options => {
|
|
3393
3393
|
return DelegateProxyHandler.create("AbstractTableFilterModel", b => {
|
|
3394
3394
|
b.forProperty("rowFilter$", () => new DelegatingValueModel());
|
|
3395
3395
|
b.forProperty("highlightText$", () => new DelegatingValueModel());
|
|
@@ -3603,9 +3603,9 @@ class AbstractTableModel extends GarbageCollector {
|
|
|
3603
3603
|
}
|
|
3604
3604
|
}
|
|
3605
3605
|
__decorate([
|
|
3606
|
-
TrackExternal() // hack instead of creating a delegating one from scratch.
|
|
3606
|
+
TrackExternal() // hack instead of creating a delegating one from scratch.
|
|
3607
3607
|
,
|
|
3608
|
-
__metadata("design:type",
|
|
3608
|
+
__metadata("design:type", TableFilterModel)
|
|
3609
3609
|
], AbstractTableModel.prototype, "filterModel", void 0);
|
|
3610
3610
|
TrackExternal.oneTimeBinding(AbstractTableModel);
|
|
3611
3611
|
|
|
@@ -4529,10 +4529,14 @@ class TreeLabelColumnModel extends ColumnModel {
|
|
|
4529
4529
|
constructor(columnId, textPropertiesProvider, expansionModel) {
|
|
4530
4530
|
super(columnId, textPropertiesProvider);
|
|
4531
4531
|
this.expansionModel = expansionModel;
|
|
4532
|
+
this.labelFactory = () => undefined;
|
|
4532
4533
|
this.cellRenderer(TreeLabelCellRendererComponent);
|
|
4533
4534
|
}
|
|
4534
4535
|
pluck(property) {
|
|
4535
|
-
this.
|
|
4536
|
+
this.useLabel(row => row[property]);
|
|
4537
|
+
}
|
|
4538
|
+
useLabel(factory) {
|
|
4539
|
+
this.labelFactory = factory;
|
|
4536
4540
|
}
|
|
4537
4541
|
/**
|
|
4538
4542
|
* @deprecated use #useIcon instead.
|
|
@@ -4550,7 +4554,7 @@ class TreeLabelColumnModel extends ColumnModel {
|
|
|
4550
4554
|
component.treeTableModel = this.expansionModel;
|
|
4551
4555
|
}
|
|
4552
4556
|
component.value = rowData.row;
|
|
4553
|
-
component.label =
|
|
4557
|
+
component.label = this.labelFactory(rowData.row);
|
|
4554
4558
|
component.iconFactory = this.iconFactory;
|
|
4555
4559
|
}));
|
|
4556
4560
|
return this;
|
|
@@ -8441,15 +8445,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.2", ngImpor
|
|
|
8441
8445
|
}]
|
|
8442
8446
|
}] });
|
|
8443
8447
|
|
|
8444
|
-
class
|
|
8445
|
-
constructor(
|
|
8448
|
+
class DefaultTableFilterModel extends TableFilterModel {
|
|
8449
|
+
constructor(configuration) {
|
|
8446
8450
|
super();
|
|
8447
8451
|
this._rowPredicate$ = this.registerDisposable(new DelegatingValueModel());
|
|
8448
8452
|
this._searchText$ = this.registerDisposable(new DelegatingValueModel());
|
|
8449
8453
|
this.inUpdate = new Guard();
|
|
8450
8454
|
const { chain } = Dsl.disposeWith(this);
|
|
8451
|
-
if (
|
|
8452
|
-
this.
|
|
8455
|
+
if (configuration) {
|
|
8456
|
+
this.configure({ ...configuration, disposedWith: this });
|
|
8453
8457
|
}
|
|
8454
8458
|
const textSearchRegex$ = chain(this._searchText$).map(text => {
|
|
8455
8459
|
return isEmpty$1(text) ? undefined : new RegExp(escapeStringRegexp(text), "i");
|
|
@@ -8474,25 +8478,15 @@ class TableFilterModel extends AbstractTableFilterModel {
|
|
|
8474
8478
|
get highlightText$() {
|
|
8475
8479
|
return this._searchText$.readonly;
|
|
8476
8480
|
}
|
|
8477
|
-
|
|
8478
|
-
// TODO: calling this twice without disposing woudl result in confusion... I should probably
|
|
8479
|
-
// change how this works...
|
|
8480
|
-
const self = this;
|
|
8481
|
+
configure(configuration) {
|
|
8481
8482
|
this.inUpdate.whileTrue(() => {
|
|
8482
|
-
|
|
8483
|
-
|
|
8484
|
-
self._rowPredicate$.setDelegate(predicate$);
|
|
8485
|
-
return this;
|
|
8486
|
-
},
|
|
8487
|
-
useSearchText(searchText$) {
|
|
8488
|
-
self._searchText$.setDelegate(searchText$);
|
|
8489
|
-
return this;
|
|
8490
|
-
}
|
|
8491
|
-
});
|
|
8483
|
+
this._rowPredicate$.setDelegate(configuration.predicate$);
|
|
8484
|
+
this._searchText$.setDelegate(configuration.searchText$);
|
|
8492
8485
|
});
|
|
8493
|
-
|
|
8486
|
+
const self = this;
|
|
8487
|
+
configuration.disposedWith.registerDisposable({
|
|
8494
8488
|
dispose: () => self.clear()
|
|
8495
|
-
};
|
|
8489
|
+
});
|
|
8496
8490
|
}
|
|
8497
8491
|
clear() {
|
|
8498
8492
|
this.inUpdate.whileTrue(() => {
|
|
@@ -8501,19 +8495,6 @@ class TableFilterModel extends AbstractTableFilterModel {
|
|
|
8501
8495
|
});
|
|
8502
8496
|
}
|
|
8503
8497
|
}
|
|
8504
|
-
(function (TableFilterModel) {
|
|
8505
|
-
class BuilderImp {
|
|
8506
|
-
usePredicate(predicate$) {
|
|
8507
|
-
this.rowPredicate$ = predicate$;
|
|
8508
|
-
return this;
|
|
8509
|
-
}
|
|
8510
|
-
useSearchText(searchText$) {
|
|
8511
|
-
this.searchText$ = searchText$;
|
|
8512
|
-
return this;
|
|
8513
|
-
}
|
|
8514
|
-
}
|
|
8515
|
-
TableFilterModel.BuilderImp = BuilderImp;
|
|
8516
|
-
})(TableFilterModel || (TableFilterModel = {}));
|
|
8517
8498
|
|
|
8518
8499
|
/**
|
|
8519
8500
|
* @file Automatically generated by barrelsby.
|
|
@@ -10462,5 +10443,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.2", ngImpor
|
|
|
10462
10443
|
* Generated bundle index. Do not edit.
|
|
10463
10444
|
*/
|
|
10464
10445
|
|
|
10465
|
-
export { ACTIVITY_DATA, ALERT_CONFIG, AUP_PLACE_CONFIG, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent, AbstractCardContainerComponent, AbstractConfirmDialogComponent, AbstractDialogComponent, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableComponent,
|
|
10446
|
+
export { ACTIVITY_DATA, ALERT_CONFIG, AUP_PLACE_CONFIG, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent, AbstractCardContainerComponent, AbstractConfirmDialogComponent, AbstractDialogComponent, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableComponent, AbstractTableModel, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityBodyComponent, ActivityContainerComponent, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddCardActivityComponent, AddItemInteractionContextComponent, Alert, AlertDialogComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CardStackComponent, CellEditorPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnListModel, ColumnModel, ColumnTemplateDirective, ColumnTextSearchFormatter, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, ConfirmThenDialogComponent, ConfirmThenExecuteDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DecoratedTreeNode, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DefaultTableFilterModel, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControls, EditSession, EditorControlColumnModel, EmptyStateComponent, EnableCellTextSearch, EventCleanUpSession, FlattenedTreeListModel, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, Formatter, GarbageCollectorDirective, HEADER_CELL_RENDERER_PORTAL, HighlightPipe, HighlightTextModelDirective, HorizontalAlignment, IconComponent, InPlaceInteractionContextComponent, InlineActivityTriggerComponent, InlineEditorModel, InlineStringEditorComponent, InputActivity, InteractionContextTriggerFor, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, Keys, LEFT_RIGHT_PLACE_ANIMATION, LabelledValueComponent, ListPlaceNavComponent, ListPropertyColumnModel, LoadingContainerComponent, MarkdownComponent, MarkdownService, ModalActivityTriggerComponent, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NotAuthorisedNoticeComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, PaginatorComponent, ParameterDefinition, PasswordInputComponent, Place, PlaceAccessGuard, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupActivityTriggerComponent, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, RouteId, ScrollContainerComponent, SectionHeaderComponent, SelectInputActivity, SelectInputComponent, SelectionCellComponent, SelectionColumnModel, SelectionHeaderCellComponent, SeparatorComponent, SidePlaceNavigationComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableBodyComponent, TableCellComponent, TableComponent, TableFilterModel, TableHeaderCellComponent, TableModel, TableRowMenuComponent, TemplateCellRendererPortalRef, TextInputComponent, ToolBarComponent, TrackBy, TreeExpansionModel, TreeInheritanceIconComponent, TreeLabelCellRendererComponent, TreeLabelColumnModel, TreeTableComponent, TreeTableModel, UrlService, UrlSnapshot, VerticalFocusContainerComponent, VisibilityService, Visit, VisitParameter, VisitParameterList, VisitSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, markdownPillExtension, slideDownOnEnterAnimation, slideRightOnEnterAnimation, treeNodeDecorator };
|
|
10466
10447
|
//# sourceMappingURL=coolon-angular-ui-powerups.mjs.map
|