@coolon/angular-ui-powerups 16.1.0-aplpha.79 → 16.1.0-aplpha.8
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/assets/activities/input-activities.scss +2 -10
- package/assets/form.scss +27 -62
- package/assets/table.scss +18 -15
- package/assets/tabs.scss +6 -2
- package/esm2022/lib/angular-ui-powerups.module.mjs +1 -1
- package/esm2022/lib/animations/slide-animations.mjs +1 -6
- package/esm2022/lib/components/alignment.mjs +1 -1
- package/esm2022/lib/components/busy-overlay/busy-overlay.component.mjs +9 -4
- package/esm2022/lib/components/cards/abstract-card-container.component.mjs +1 -1
- package/esm2022/lib/components/cards/card-container/card-container.component.mjs +2 -2
- package/esm2022/lib/components/commands/command/command.component.mjs +13 -24
- package/esm2022/lib/components/commands/command-face/command-face.component.mjs +3 -11
- package/esm2022/lib/components/commands/command-face.mjs +11 -11
- package/esm2022/lib/components/commands/flex.component.mjs +1 -1
- package/esm2022/lib/components/commands/group/command-container.mjs +1 -1
- package/esm2022/lib/components/commands/group/popup-aware.component.mjs +1 -1
- package/esm2022/lib/components/commands/group/popup-container.mjs +1 -1
- package/esm2022/lib/components/commands/group/popup-menu/abstract-popup-menu.component.mjs +11 -11
- package/esm2022/lib/components/commands/group/popup-menu/more-menu.component.mjs +1 -1
- package/esm2022/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.mjs +1 -1
- package/esm2022/lib/components/commands/group/popup-menu/popup-menu.component.mjs +2 -2
- package/esm2022/lib/components/commands/group/tool-bar/tool-bar.component.mjs +16 -9
- package/esm2022/lib/components/commands/separator.component.mjs +1 -1
- package/esm2022/lib/components/components.module.mjs +17 -31
- package/esm2022/lib/components/disposable-component.mjs +37 -8
- package/esm2022/lib/components/empty-state/empty-state.component.mjs +6 -2
- package/esm2022/lib/components/exports.mjs +2 -6
- package/esm2022/lib/components/focus-container/focus-container.component.mjs +1 -1
- package/esm2022/lib/components/focusable.component.mjs +2 -2
- package/esm2022/lib/components/forms/abstract-input.component.mjs +15 -62
- package/esm2022/lib/components/forms/abstract-list-input.component.mjs +1 -1
- package/esm2022/lib/components/forms/abstract-value-input.component.mjs +1 -1
- package/esm2022/lib/components/forms/autocomplete-input/autocomplete-input.component.mjs +4 -3
- package/esm2022/lib/components/forms/checkbox-input/checkbox-input.component.mjs +1 -1
- package/esm2022/lib/components/forms/multiple-select-input/multiple-select-input.component.mjs +3 -3
- package/esm2022/lib/components/forms/number-input/number-input.component.mjs +10 -49
- package/esm2022/lib/components/forms/password-input/password-input.component.mjs +3 -40
- package/esm2022/lib/components/forms/select-input/select-input.component.mjs +11 -12
- package/esm2022/lib/components/forms/string-input/string-input.component.mjs +10 -22
- package/esm2022/lib/components/forms/text-input/text-input.component.mjs +1 -1
- package/esm2022/lib/components/icon/icon.component.mjs +3 -6
- package/esm2022/lib/components/labelled-value/labelled-value.component.mjs +1 -1
- package/esm2022/lib/components/loading-container/loading-container.component.mjs +9 -4
- package/esm2022/lib/components/noop/noop.component.mjs +4 -2
- package/esm2022/lib/components/resize-aware.component.mjs +24 -61
- package/esm2022/lib/components/scroll-container/scroll-container.component.mjs +2 -2
- package/esm2022/lib/components/section-header/section-header.component.mjs +1 -1
- package/esm2022/lib/components/switch-case/switch-case.component.mjs +2 -2
- package/esm2022/lib/components/tables/abstract-table-model.mjs +23 -40
- package/esm2022/lib/components/tables/abstract-table.component.mjs +5 -19
- package/esm2022/lib/components/tables/column/column-list-model.mjs +44 -0
- package/esm2022/lib/components/tables/column/column-model.mjs +7 -18
- package/esm2022/lib/components/tables/column/column-template/column-template.directive.mjs +1 -1
- package/esm2022/lib/components/tables/column/custom-template-column-model.mjs +3 -3
- package/esm2022/lib/components/tables/column/custom-value-column-model.mjs +5 -5
- package/esm2022/lib/components/tables/column/editor-controls-column-model.mjs +5 -5
- package/esm2022/lib/components/tables/column/list-propery-column-model.mjs +5 -6
- package/esm2022/lib/components/tables/column/property-column-model.mjs +5 -5
- package/esm2022/lib/components/tables/column/selection-column-model.mjs +3 -3
- package/esm2022/lib/components/tables/editor/edit-row-controls/edit-row-controls.component.mjs +6 -6
- package/esm2022/lib/components/tables/editor/edit-session.mjs +2 -4
- package/esm2022/lib/components/tables/editor/editable-cell-renderer.mjs +1 -1
- package/esm2022/lib/components/tables/filter/column-text-search-formatter.mjs +1 -1
- package/esm2022/lib/components/tables/filter/enable-cell-text-search.decorator.mjs +2 -3
- package/esm2022/lib/components/tables/filter/table-filter-model.mjs +2 -4
- package/esm2022/lib/components/tables/filter/text-search-predicate.mjs +2 -16
- package/esm2022/lib/components/tables/paginator/paginator.component.mjs +1 -1
- package/esm2022/lib/components/tables/renderer/cell-editors.mjs +1 -1
- package/esm2022/lib/components/tables/renderer/cell-portal-ref.mjs +3 -1
- package/esm2022/lib/components/tables/renderer/default-cell-renderer/default-cell-renderer.component.mjs +6 -4
- package/esm2022/lib/components/tables/renderer/default-header-cell-renderer/default-header-cell-renderer.component.mjs +4 -2
- package/esm2022/lib/components/tables/renderer/select-header-cell/selection-header-cell.component.mjs +1 -1
- package/esm2022/lib/components/tables/renderer/table-body/table-body.component.mjs +38 -213
- package/esm2022/lib/components/tables/renderer/table-cell/table-cell.component.mjs +1 -1
- package/esm2022/lib/components/tables/renderer/table-header-cell/table-header-cell.component.mjs +4 -2
- package/esm2022/lib/components/tables/renderer/table-more-menu/table-more-menu-popup/table-more-menu-popup.component.mjs +1 -1
- package/esm2022/lib/components/tables/renderer/table-more-menu/table-more-menu.component.mjs +2 -7
- package/esm2022/lib/components/tables/table/table-model.mjs +1 -1
- package/esm2022/lib/components/tables/table/table.component.mjs +67 -12
- package/esm2022/lib/components/tables/table-row-menu/table-row-menu.component.mjs +1 -1
- package/esm2022/lib/components/tables/tree-table/decorated-tree-node.mjs +4 -5
- package/esm2022/lib/components/tables/tree-table/flattened-tree-list-model.mjs +1 -1
- package/esm2022/lib/components/tables/tree-table/tree-expansion-model.mjs +1 -1
- package/esm2022/lib/components/tables/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.mjs +4 -2
- package/esm2022/lib/components/tables/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.mjs +1 -1
- package/esm2022/lib/components/tables/tree-table/tree-label-column-model.mjs +4 -4
- package/esm2022/lib/components/tables/tree-table/tree-table-component.mjs +4 -7
- package/esm2022/lib/components/tables/tree-table/tree-table-model.mjs +3 -3
- package/esm2022/lib/components/text/markdown/markdown.component.mjs +3 -3
- package/esm2022/lib/components/track.mjs +1 -1
- package/esm2022/lib/components/types/bounds.class.mjs +1 -1
- package/esm2022/lib/components/vertical-focus-container/vertical-focus-container.component.mjs +1 -1
- package/esm2022/lib/directives/command.directive.mjs +2 -2
- package/esm2022/lib/directives/directives.module.mjs +2 -2
- package/esm2022/lib/directives/exports.mjs +1 -2
- package/esm2022/lib/directives/focus-binding-factory.mjs +1 -1
- package/esm2022/lib/directives/focus-binding.directive.mjs +2 -2
- package/esm2022/lib/directives/focus-binding.mjs +1 -1
- package/esm2022/lib/directives/garbage-collector.directive.mjs +1 -2
- package/esm2022/lib/directives/highlight-text-model.directive.mjs +1 -1
- package/esm2022/lib/directives/highlight.pipe.mjs +2 -2
- package/esm2022/lib/interaction/abstract-interaction-context.mjs +1 -1
- package/esm2022/lib/interaction/activity-ref.mjs +2 -2
- package/esm2022/lib/interaction/activity.mjs +4 -4
- package/esm2022/lib/interaction/alert.mjs +2 -2
- package/esm2022/lib/interaction/components/abstract-confirm-dialog.component.mjs +4 -8
- package/esm2022/lib/interaction/components/abstract-dialog.component.mjs +3 -2
- package/esm2022/lib/interaction/components/activity-actions/activity-actions.component.mjs +3 -3
- package/esm2022/lib/interaction/components/activity-body/activity-body.component.mjs +1 -1
- package/esm2022/lib/interaction/components/activity-container/activity-container.component.mjs +11 -28
- package/esm2022/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.mjs +3 -1
- package/esm2022/lib/interaction/components/activity-title/activity-title.component.mjs +2 -2
- package/esm2022/lib/interaction/components/activity-triggers/inline-activity-trigger/inline-activity-trigger.component.mjs +1 -1
- package/esm2022/lib/interaction/components/activity-triggers/modal-activity-trigger/modal-activity-trigger.component.mjs +1 -1
- package/esm2022/lib/interaction/components/activity-triggers/popup-activity-trigger/popup-activity-trigger.component.mjs +1 -1
- package/esm2022/lib/interaction/components/add-card-activity/add-card-activity.component.mjs +1 -1
- package/esm2022/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.mjs +1 -1
- package/esm2022/lib/interaction/components/alert-dialog/alert-dialog.component.mjs +1 -1
- package/esm2022/lib/interaction/components/confirm-then-dialog/confirm-then-dialog.component.mjs +1 -1
- package/esm2022/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.mjs +1 -1
- package/esm2022/lib/interaction/components/confirmation-dialog/confirmation-dialog.component.mjs +1 -1
- package/esm2022/lib/interaction/components/editors/edit-context.mjs +1 -1
- package/esm2022/lib/interaction/components/editors/inline-string-editor/inline-editor-model.mjs +2 -2
- package/esm2022/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.mjs +3 -3
- package/esm2022/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.mjs +3 -3
- package/esm2022/lib/interaction/components/input-activities/input-activity.mjs +2 -3
- package/esm2022/lib/interaction/components/input-activities/select-input-activity.mjs +1 -4
- package/esm2022/lib/interaction/components/input-activities/string-input-activity.mjs +4 -9
- package/esm2022/lib/interaction/components/popup-interaction-context/popup-interaction-context.component.mjs +2 -3
- package/esm2022/lib/interaction/confirm.mjs +1 -1
- package/esm2022/lib/interaction/directives/interaction-context-trigger-for.directive.mjs +6 -6
- package/esm2022/lib/interaction/exports.mjs +1 -2
- package/esm2022/lib/interaction/in-place-interaction-context.mjs +1 -1
- package/esm2022/lib/interaction/interaction-context.mjs +1 -1
- package/esm2022/lib/interaction/interaction.module.mjs +23 -21
- package/esm2022/lib/interaction/route-synchronisation-adapter.mjs +1 -1
- package/esm2022/lib/interaction/services/interaction-service-routing-adapter.mjs +1 -1
- package/esm2022/lib/interaction/services/interaction.service.mjs +3 -3
- package/esm2022/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context-factory.mjs +3 -2
- package/esm2022/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context.mjs +2 -1
- package/esm2022/lib/interaction/services/modal-interaction-context.factory.mjs +1 -1
- package/esm2022/lib/place/components/abstract-place-navigation.component.mjs +1 -1
- package/esm2022/lib/place/components/list-place-nav/list-place-nav.component.mjs +4 -3
- package/esm2022/lib/place/components/not-authorised-notice/not-authorised-notice.component.mjs +4 -2
- package/esm2022/lib/place/components/place-outlet/place-outlet.component.mjs +4 -4
- package/esm2022/lib/place/components/place-outlet/route-animations.mjs +1 -1
- package/esm2022/lib/place/components/side-place-navigation/side-place-navigation.component.mjs +4 -4
- package/esm2022/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.mjs +1 -1
- package/esm2022/lib/place/guards/consolidated-param-map.mjs +4 -4
- package/esm2022/lib/place/guards/noop-auth-guard.service.mjs +4 -2
- package/esm2022/lib/place/guards/place.guard.mjs +2 -2
- package/esm2022/lib/place/navigation/place-component-deactivation-handler.mjs +2 -2
- package/esm2022/lib/place/navigation/session/abstract-pop-state-navigation.mjs +1 -1
- package/esm2022/lib/place/navigation/session/event-cleanup/event-clean-up-session.mjs +1 -1
- package/esm2022/lib/place/navigation/session/event-cleanup/wait-until-leaving-interaction-transition-cancelled.mjs +1 -1
- package/esm2022/lib/place/navigation/session/event-cleanup/wait-until-link-triggered-navigation-interaction-cancelation-type-determined.mjs +1 -1
- package/esm2022/lib/place/navigation/session/event-cleanup/wait-until-popstate-during-can-deactivate-transition-finishes.mjs +1 -1
- package/esm2022/lib/place/navigation/session/interactions/navigating-during-interaction.mjs +2 -2
- package/esm2022/lib/place/navigation/session/interactions/pop-state-during-interaction-navigation.mjs +1 -1
- package/esm2022/lib/place/navigation/session/interactions/remove-last-interaction-from-url-navigation-session.mjs +3 -3
- package/esm2022/lib/place/navigation/session/interactions/synchronise-interaction-context-ids-with-route.mjs +6 -3
- package/esm2022/lib/place/navigation/session/navigating.mjs +2 -2
- package/esm2022/lib/place/navigation/session/navigation-context.mjs +1 -1
- package/esm2022/lib/place/navigation/session/navigation-session.mjs +1 -1
- package/esm2022/lib/place/navigation/session/pop-state-navigation.mjs +1 -1
- package/esm2022/lib/place/place-access-guard.mjs +1 -1
- package/esm2022/lib/place/place-component.mjs +30 -29
- package/esm2022/lib/place/place-config.mjs +1 -1
- package/esm2022/lib/place/place-definition.mjs +3 -3
- package/esm2022/lib/place/place-history.mjs +5 -3
- package/esm2022/lib/place/place-router.mjs +15 -17
- package/esm2022/lib/place/place.decorator.mjs +2 -2
- package/esm2022/lib/place/place.module.mjs +5 -1
- package/esm2022/lib/place/route/formatter.mjs +2 -2
- package/esm2022/lib/place/route/json-types.mjs +1 -1
- package/esm2022/lib/place/route/parameter-decorators.mjs +50 -54
- package/esm2022/lib/place/route/parameter-definition.mjs +2 -2
- package/esm2022/lib/place/route/parameter-sanitiser.mjs +1 -1
- package/esm2022/lib/place/route/parameter-snapshot.mjs +1 -1
- package/esm2022/lib/place/route/visit-segment-sanitiser.mjs +1 -1
- package/esm2022/lib/place/url-service.mjs +1 -1
- package/esm2022/lib/place/url-snapshot.mjs +3 -3
- package/esm2022/lib/place/visit-segment.mjs +2 -2
- package/esm2022/lib/place/visit.mjs +2 -2
- package/esm2022/lib/services/markdown/markdown.service.mjs +4 -2
- package/esm2022/lib/services/markdown/pill-plugin.mjs +3 -1
- package/esm2022/lib/services/visibility-service.mjs +4 -4
- package/fesm2022/coolon-angular-ui-powerups.mjs +1769 -2395
- package/fesm2022/coolon-angular-ui-powerups.mjs.map +1 -1
- package/lib/animations/slide-animations.d.ts +0 -1
- package/lib/components/busy-overlay/busy-overlay.component.d.ts +4 -1
- package/lib/components/commands/command/command.component.d.ts +4 -4
- package/lib/components/commands/command-face/command-face.component.d.ts +0 -2
- package/lib/components/commands/command-face.d.ts +7 -5
- package/lib/components/commands/group/popup-menu/abstract-popup-menu.component.d.ts +2 -2
- package/lib/components/commands/group/tool-bar/tool-bar.component.d.ts +7 -3
- package/lib/components/components.module.d.ts +53 -55
- package/lib/components/disposable-component.d.ts +6 -1
- package/lib/components/empty-state/empty-state.component.d.ts +4 -1
- package/lib/components/exports.d.ts +1 -5
- package/lib/components/forms/abstract-input.component.d.ts +5 -13
- package/lib/components/forms/number-input/number-input.component.d.ts +4 -8
- package/lib/components/forms/password-input/password-input.component.d.ts +1 -7
- package/lib/components/forms/select-input/select-input.component.d.ts +3 -4
- package/lib/components/forms/string-input/string-input.component.d.ts +1 -3
- package/lib/components/loading-container/loading-container.component.d.ts +4 -1
- package/lib/components/noop/noop.component.d.ts +1 -0
- package/lib/components/resize-aware.component.d.ts +5 -24
- package/lib/components/switch-case/switch-case.component.d.ts +4 -4
- package/lib/components/tables/abstract-table-model.d.ts +5 -10
- package/lib/components/tables/abstract-table.component.d.ts +4 -5
- package/lib/components/tables/column/column-list-model.d.ts +13 -0
- package/lib/components/tables/column/column-model.d.ts +2 -6
- package/lib/components/tables/column/custom-template-column-model.d.ts +1 -2
- package/lib/components/tables/column/custom-value-column-model.d.ts +1 -2
- package/lib/components/tables/column/editor-controls-column-model.d.ts +1 -2
- package/lib/components/tables/column/list-propery-column-model.d.ts +1 -2
- package/lib/components/tables/column/property-column-model.d.ts +1 -2
- package/lib/components/tables/column/selection-column-model.d.ts +1 -2
- package/lib/components/tables/editor/edit-row-controls/edit-row-controls.component.d.ts +3 -3
- package/lib/components/tables/editor/editable-cell-renderer.d.ts +1 -1
- package/lib/components/tables/filter/enable-cell-text-search.decorator.d.ts +1 -1
- package/lib/components/tables/filter/text-search-predicate.d.ts +0 -9
- package/lib/components/tables/renderer/cell-portal-ref.d.ts +3 -2
- package/lib/components/tables/renderer/default-cell-renderer/default-cell-renderer.component.d.ts +1 -0
- package/lib/components/tables/renderer/default-header-cell-renderer/default-header-cell-renderer.component.d.ts +1 -0
- package/lib/components/tables/renderer/table-body/table-body.component.d.ts +15 -25
- package/lib/components/tables/renderer/table-header-cell/table-header-cell.component.d.ts +1 -0
- package/lib/components/tables/renderer/table-more-menu/table-more-menu.component.d.ts +1 -2
- package/lib/components/tables/table/table.component.d.ts +12 -6
- package/lib/components/tables/tree-table/tree-expansion-model.d.ts +2 -2
- package/lib/components/tables/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.d.ts +1 -0
- package/lib/components/tables/tree-table/tree-label-column-model.d.ts +1 -2
- package/lib/components/tables/tree-table/tree-table-component.d.ts +2 -5
- package/lib/components/text/markdown/markdown.component.d.ts +1 -1
- package/lib/directives/exports.d.ts +0 -1
- package/lib/interaction/activity-ref.d.ts +2 -2
- package/lib/interaction/activity.d.ts +2 -2
- package/lib/interaction/components/abstract-confirm-dialog.component.d.ts +0 -1
- package/lib/interaction/components/activity-container/activity-container.component.d.ts +3 -7
- package/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.d.ts +3 -2
- package/lib/interaction/components/editors/edit-context.d.ts +1 -1
- package/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.d.ts +1 -1
- package/lib/interaction/components/input-activities/string-input-activity.d.ts +1 -1
- package/lib/interaction/directives/interaction-context-trigger-for.directive.d.ts +3 -3
- package/lib/interaction/exports.d.ts +0 -1
- package/lib/interaction/interaction.module.d.ts +28 -28
- package/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context-factory.d.ts +2 -1
- package/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context.d.ts +2 -1
- package/lib/place/components/not-authorised-notice/not-authorised-notice.component.d.ts +1 -0
- package/lib/place/guards/noop-auth-guard.service.d.ts +1 -0
- package/lib/place/navigation/session/interactions/remove-last-interaction-from-url-navigation-session.d.ts +1 -0
- package/lib/place/place-component.d.ts +10 -4
- package/lib/place/place-history.d.ts +1 -0
- package/lib/place/place-router.d.ts +2 -2
- package/lib/place/place.decorator.d.ts +1 -1
- package/lib/place/place.module.d.ts +5 -4
- package/lib/place/route/json-types.d.ts +3 -1
- package/lib/place/visit-segment.d.ts +4 -4
- package/lib/place/visit.d.ts +2 -2
- package/lib/services/markdown/markdown.service.d.ts +1 -0
- package/lib/services/visibility-service.d.ts +1 -1
- package/package.json +7 -8
- package/esm2022/lib/components/forms/form-field.mjs +0 -2
- package/esm2022/lib/components/forms/search-input/search-input.component.mjs +0 -33
- package/esm2022/lib/components/loadable-component.mjs +0 -49
- package/esm2022/lib/components/tables/column/column-manager.mjs +0 -81
- package/esm2022/lib/components/tables/column/column-order-manager.mjs +0 -19
- package/esm2022/lib/directives/resize-observer.directive.mjs +0 -40
- package/esm2022/lib/interaction/components/slide-down-interaction-context/slide-down-interaction-context.component.mjs +0 -129
- package/lib/components/forms/form-field.d.ts +0 -5
- package/lib/components/forms/search-input/search-input.component.d.ts +0 -10
- package/lib/components/loadable-component.d.ts +0 -17
- package/lib/components/tables/column/column-manager.d.ts +0 -19
- package/lib/components/tables/column/column-order-manager.d.ts +0 -20
- package/lib/directives/resize-observer.directive.d.ts +0 -16
- package/lib/interaction/components/slide-down-interaction-context/slide-down-interaction-context.component.d.ts +0 -53
|
@@ -16,7 +16,7 @@ import * as i0 from "@angular/core";
|
|
|
16
16
|
* </aup-in-place-interaction-context>
|
|
17
17
|
*
|
|
18
18
|
* in your component
|
|
19
|
-
* @ViewChild(
|
|
19
|
+
* @ViewChild('inPlaceInteractionContext', { static: true })
|
|
20
20
|
* interactionContext: InteractionContext;
|
|
21
21
|
*
|
|
22
22
|
*
|
|
@@ -5,6 +5,6 @@ export declare class StringInputActivity extends InputActivity<string> {
|
|
|
5
5
|
static ɵcmp: i0.ɵɵComponentDeclaration<StringInputActivity, "aup-string-input-activity", never, {}, {}, never, never, false, never>;
|
|
6
6
|
}
|
|
7
7
|
export declare namespace StringInputActivity {
|
|
8
|
-
interface Data extends InputActivity.Data<
|
|
8
|
+
interface Data extends InputActivity.Data<String> {
|
|
9
9
|
}
|
|
10
10
|
}
|
|
@@ -3,7 +3,7 @@ import { Constructable, GarbageCollector } from '@coolon/pectin';
|
|
|
3
3
|
import { Activity } from '../activity';
|
|
4
4
|
import { InteractionContext } from '../interaction-context';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
-
export declare class
|
|
6
|
+
export declare class InteractionContextTriggerFor<D, R, E> extends GarbageCollector {
|
|
7
7
|
aupInteractionContextTriggerFor: Pick<InteractionContext, 'startActivity' | 'isActive' | 'cancelActiveActivity'>;
|
|
8
8
|
activityClass: Constructable<Activity<D, R, E>>;
|
|
9
9
|
activityData?: D;
|
|
@@ -15,6 +15,6 @@ export declare class InteractionContextTriggerForDirective<D, R, E> extends Garb
|
|
|
15
15
|
onClick(event: MouseEvent): void;
|
|
16
16
|
protected startActivity(): void;
|
|
17
17
|
prepareActivityData(): D;
|
|
18
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<
|
|
19
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<
|
|
18
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<InteractionContextTriggerFor<any, any, any>, never>;
|
|
19
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<InteractionContextTriggerFor<any, any, any>, "[aupInteractionContextTriggerFor]", never, { "aupInteractionContextTriggerFor": { "alias": "aupInteractionContextTriggerFor"; "required": false; }; "activityClass": { "alias": "activityClass"; "required": false; }; "activityData": { "alias": "activityData"; "required": false; }; "activityDataFactory": { "alias": "activityDataFactory"; "required": false; }; }, { "activityDone": "activityDone"; "activityCancelled": "activityCancelled"; }, never, never, false, never>;
|
|
20
20
|
}
|
|
@@ -35,7 +35,6 @@ export * from "./components/input-activities/input-activity";
|
|
|
35
35
|
export * from "./components/input-activities/select-input-activity";
|
|
36
36
|
export * from "./components/input-activities/string-input-activity";
|
|
37
37
|
export * from "./components/popup-interaction-context/popup-interaction-context.component";
|
|
38
|
-
export * from "./components/slide-down-interaction-context/slide-down-interaction-context.component";
|
|
39
38
|
export * from "./directives/interaction-context-trigger-for.directive";
|
|
40
39
|
export * from "./services/interaction-service-routing-adapter";
|
|
41
40
|
export * from "./services/interaction.service";
|
|
@@ -6,33 +6,33 @@ import * as i4 from "./components/confirm-then-execute-dialog/confirm-then-execu
|
|
|
6
6
|
import * as i5 from "./components/alert-dialog/alert-dialog.component";
|
|
7
7
|
import * as i6 from "./components/activity-container/activity-outlet/activity-outlet.component";
|
|
8
8
|
import * as i7 from "./components/inplace-interaction-context/in-place-interaction-context.component";
|
|
9
|
-
import * as i8 from "./components/
|
|
10
|
-
import * as i9 from "./components/
|
|
11
|
-
import * as i10 from "./components/
|
|
12
|
-
import * as i11 from "./components/
|
|
13
|
-
import * as i12 from "./components/input-activities/
|
|
14
|
-
import * as i13 from "./components/input-activities/
|
|
15
|
-
import * as i14 from "./
|
|
16
|
-
import * as i15 from "./
|
|
17
|
-
import * as i16 from "./activity";
|
|
18
|
-
import * as i17 from "./components/activity-
|
|
19
|
-
import * as i18 from "./components/activity-
|
|
20
|
-
import * as i19 from "./components/activity-triggers/
|
|
21
|
-
import * as i20 from "./components/activity-triggers/
|
|
22
|
-
import * as i21 from "./components/activity-triggers/
|
|
23
|
-
import * as i22 from "./components/
|
|
24
|
-
import * as i23 from "./components/
|
|
25
|
-
import * as i24 from "./components/
|
|
26
|
-
import * as i25 from "./components/abstract-dialog.component";
|
|
27
|
-
import * as i26 from "
|
|
28
|
-
import * as i27 from "@angular/
|
|
29
|
-
import * as i28 from "@angular/material/
|
|
30
|
-
import * as i29 from "@angular/material/
|
|
31
|
-
import * as i30 from "@angular/
|
|
32
|
-
import * as i31 from "@angular/
|
|
33
|
-
import * as i32 from "@angular/
|
|
34
|
-
import * as i33 from "
|
|
35
|
-
import * as i34 from "
|
|
9
|
+
import * as i8 from "./components/add-item-interaction-context/add-item-interaction-context.component";
|
|
10
|
+
import * as i9 from "./components/activity-actions/activity-actions.component";
|
|
11
|
+
import * as i10 from "./components/popup-interaction-context/popup-interaction-context.component";
|
|
12
|
+
import * as i11 from "./components/input-activities/string-input-activity";
|
|
13
|
+
import * as i12 from "./components/input-activities/select-input-activity";
|
|
14
|
+
import * as i13 from "./components/input-activities/input-activity";
|
|
15
|
+
import * as i14 from "./directives/interaction-context-trigger-for.directive";
|
|
16
|
+
import * as i15 from "./activity";
|
|
17
|
+
import * as i16 from "./components/activity-title/activity-title.component";
|
|
18
|
+
import * as i17 from "./components/activity-body/activity-body.component";
|
|
19
|
+
import * as i18 from "./components/activity-triggers/abstract-activity-trigger.component";
|
|
20
|
+
import * as i19 from "./components/activity-triggers/popup-activity-trigger/popup-activity-trigger.component";
|
|
21
|
+
import * as i20 from "./components/activity-triggers/inline-activity-trigger/inline-activity-trigger.component";
|
|
22
|
+
import * as i21 from "./components/activity-triggers/modal-activity-trigger/modal-activity-trigger.component";
|
|
23
|
+
import * as i22 from "./components/add-card-activity/add-card-activity.component";
|
|
24
|
+
import * as i23 from "./components/editors/inline-string-editor/inline-string-editor.component";
|
|
25
|
+
import * as i24 from "./components/abstract-dialog.component";
|
|
26
|
+
import * as i25 from "./components/abstract-confirm-dialog.component";
|
|
27
|
+
import * as i26 from "@angular/common";
|
|
28
|
+
import * as i27 from "@angular/material/button";
|
|
29
|
+
import * as i28 from "@angular/material/dialog";
|
|
30
|
+
import * as i29 from "@angular/material/tabs";
|
|
31
|
+
import * as i30 from "@angular/cdk/portal";
|
|
32
|
+
import * as i31 from "@angular/router";
|
|
33
|
+
import * as i32 from "@angular/material/icon";
|
|
34
|
+
import * as i33 from "../directives/directives.module";
|
|
35
|
+
import * as i34 from "@angular/flex-layout";
|
|
36
36
|
import * as i35 from "../components/components.module";
|
|
37
37
|
import * as i36 from "@angular/forms";
|
|
38
38
|
import * as i37 from "@angular/material/input";
|
|
@@ -40,6 +40,6 @@ import * as i38 from "@angular/material/form-field";
|
|
|
40
40
|
import * as i39 from "@angular/cdk/a11y";
|
|
41
41
|
export declare class InteractionModule {
|
|
42
42
|
static ɵfac: i0.ɵɵFactoryDeclaration<InteractionModule, never>;
|
|
43
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<InteractionModule, [typeof i1.ActivityContainerComponent, typeof i2.ConfirmationDialogComponent, typeof i3.ConfirmThenDialogComponent, typeof i4.ConfirmThenExecuteDialogComponent, typeof i5.AlertDialogComponent, typeof i6.ActivityOutletComponent, typeof i7.InPlaceInteractionContextComponent, typeof i8.
|
|
43
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<InteractionModule, [typeof i1.ActivityContainerComponent, typeof i2.ConfirmationDialogComponent, typeof i3.ConfirmThenDialogComponent, typeof i4.ConfirmThenExecuteDialogComponent, typeof i5.AlertDialogComponent, typeof i6.ActivityOutletComponent, typeof i7.InPlaceInteractionContextComponent, typeof i8.AddItemInteractionContextComponent, typeof i9.ActivityActionsComponent, typeof i10.PopupInteractionContextComponent, typeof i11.StringInputActivity, typeof i12.SelectInputActivity, typeof i13.InputActivity, typeof i14.InteractionContextTriggerFor, typeof i15.Activity, typeof i16.ActivityTitleComponent, typeof i17.ActivityBodyComponent, typeof i9.ActivityActionsComponent, typeof i18.AbstractActivityTriggerComponent, typeof i19.PopupActivityTriggerComponent, typeof i20.InlineActivityTriggerComponent, typeof i21.ModalActivityTriggerComponent, typeof i22.AddCardActivityComponent, typeof i23.InlineStringEditorComponent, typeof i24.AbstractDialogComponent, typeof i25.AbstractConfirmDialogComponent], [typeof i26.CommonModule, typeof i27.MatButtonModule, typeof i28.MatDialogModule, typeof i29.MatTabsModule, typeof i30.PortalModule, typeof i31.RouterModule, typeof i32.MatIconModule, typeof i33.DirectivesModule, typeof i34.FlexModule, typeof i34.GridModule, typeof i35.ComponentsModule, typeof i36.FormsModule, typeof i37.MatInputModule, typeof i38.MatFormFieldModule, typeof i39.A11yModule], [typeof i1.ActivityContainerComponent, typeof i6.ActivityOutletComponent, typeof i16.ActivityTitleComponent, typeof i7.InPlaceInteractionContextComponent, typeof i8.AddItemInteractionContextComponent, typeof i9.ActivityActionsComponent, typeof i10.PopupInteractionContextComponent, typeof i14.InteractionContextTriggerFor, typeof i11.StringInputActivity, typeof i12.SelectInputActivity, typeof i17.ActivityBodyComponent, typeof i19.PopupActivityTriggerComponent, typeof i20.InlineActivityTriggerComponent, typeof i21.ModalActivityTriggerComponent, typeof i22.AddCardActivityComponent, typeof i23.InlineStringEditorComponent]>;
|
|
44
44
|
static ɵinj: i0.ɵɵInjectorDeclaration<InteractionModule>;
|
|
45
45
|
}
|
package/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context-factory.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { InjectionToken } from '@angular/core';
|
|
2
|
-
import { MatDialog
|
|
2
|
+
import { MatDialog } from '@angular/material/dialog';
|
|
3
|
+
import { MatDialogConfig } from '@angular/material/dialog';
|
|
3
4
|
import { BooleanValueModelChain } from '@coolon/pectin';
|
|
4
5
|
import { InteractionContext } from '../../interaction-context';
|
|
5
6
|
import { InteractionService } from '../interaction.service';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { MatDialog
|
|
1
|
+
import { MatDialog } from '@angular/material/dialog';
|
|
2
|
+
import { MatDialogConfig } from '@angular/material/dialog';
|
|
2
3
|
import { Constructable, Disposable } from '@coolon/pectin';
|
|
3
4
|
import { AbstractInteractionContext } from '../../abstract-interaction-context';
|
|
4
5
|
import { Activity } from '../../activity';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class NotAuthorisedNoticeComponent {
|
|
3
|
+
constructor();
|
|
3
4
|
static ɵfac: i0.ɵɵFactoryDeclaration<NotAuthorisedNoticeComponent, never>;
|
|
4
5
|
static ɵcmp: i0.ɵɵComponentDeclaration<NotAuthorisedNoticeComponent, "aup-not-authorised-notice", never, {}, {}, never, never, false, never>;
|
|
5
6
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ActivatedRouteSnapshot, RouterStateSnapshot, UrlTree } from '@angular/router';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class NoopAuthGuard {
|
|
4
|
+
constructor();
|
|
4
5
|
canActivate(activatedRoute: ActivatedRouteSnapshot, state: RouterStateSnapshot): Promise<boolean | UrlTree>;
|
|
5
6
|
static ɵfac: i0.ɵɵFactoryDeclaration<NoopAuthGuard, never>;
|
|
6
7
|
static ɵprov: i0.ɵɵInjectableDeclaration<NoopAuthGuard>;
|
|
@@ -17,6 +17,7 @@ export declare class RemoveLastInteractionFromUrlNavigationSession extends Navig
|
|
|
17
17
|
onPopState(event: NavigationStart): void;
|
|
18
18
|
onRouterStarted(event: NavigationStart): void;
|
|
19
19
|
onRouterCancelled(event: NavigationCancel): void;
|
|
20
|
+
onUrlChange(url: string): void;
|
|
20
21
|
private finishUp;
|
|
21
22
|
onRouterEnd(event: NavigationEnd): void;
|
|
22
23
|
handleCanDeactivateCancelledEventScenario(locationTriggerUrl: string): void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ActivatedRouteSnapshot } from '@angular/router';
|
|
2
|
-
import { Constructable, ListModel } from '@coolon/pectin';
|
|
2
|
+
import { Constructable, ListModel, ValueModel } from '@coolon/pectin';
|
|
3
3
|
import 'reflect-metadata';
|
|
4
|
-
import {
|
|
4
|
+
import { DisposableComponent } from '../components/disposable-component';
|
|
5
5
|
import { InteractionContext } from '../interaction/interaction-context';
|
|
6
6
|
import { PlaceDefinition } from './place-definition';
|
|
7
7
|
import { PlaceRouter } from "./place-router";
|
|
@@ -11,13 +11,14 @@ import { VisitSegment } from './visit-segment';
|
|
|
11
11
|
import * as i0 from "@angular/core";
|
|
12
12
|
export declare const DEFINITION_META_DATA_KEY = "PLACE_DEFINITION_OPTIONS";
|
|
13
13
|
export declare const ROUTE_PARAMETER_LIST_KEY: unique symbol;
|
|
14
|
-
export declare class PlaceComponent extends
|
|
14
|
+
export declare class PlaceComponent extends DisposableComponent {
|
|
15
15
|
private readonly _placeReadyCallbacks;
|
|
16
16
|
private visitModel;
|
|
17
17
|
private _inVisitUpdate;
|
|
18
18
|
private _active;
|
|
19
19
|
interactionContext?: InteractionContext;
|
|
20
20
|
readonly childPlaces$: ListModel<Constructable<PlaceComponent>>;
|
|
21
|
+
private readonly _parameterChangeInterceptors;
|
|
21
22
|
canDeactivate?(interactionContext: InteractionContext): boolean | Promise<boolean>;
|
|
22
23
|
protected readonly placeRouter: PlaceRouter;
|
|
23
24
|
constructor();
|
|
@@ -32,7 +33,7 @@ export declare class PlaceComponent extends LoadableComponent {
|
|
|
32
33
|
*/
|
|
33
34
|
private installAndInitialiseBinding;
|
|
34
35
|
get placeDefinition(): PlaceDefinition;
|
|
35
|
-
get active():
|
|
36
|
+
get active(): ValueModel<boolean>;
|
|
36
37
|
/**
|
|
37
38
|
* Called by the router to see if this component can deactivate. This isn't called for route parameter changes.
|
|
38
39
|
* @param interactionContext
|
|
@@ -53,6 +54,7 @@ export declare class PlaceComponent extends LoadableComponent {
|
|
|
53
54
|
*/
|
|
54
55
|
_notifyPlaceReady(): void;
|
|
55
56
|
onPlaceReady(callback: () => void): void;
|
|
57
|
+
interceptVisitParameterChange<T>(model: ValueModel<T>, callback: PlaceComponent.InterceptCallback<T>, options?: PlaceComponent.InterceptOptions): void;
|
|
56
58
|
static ɵfac: i0.ɵɵFactoryDeclaration<PlaceComponent, never>;
|
|
57
59
|
static ɵdir: i0.ɵɵDirectiveDeclaration<PlaceComponent, never, never, {}, {}, never, never, false, never>;
|
|
58
60
|
}
|
|
@@ -61,4 +63,8 @@ export declare namespace PlaceComponent {
|
|
|
61
63
|
function getRouteParameters(klass: Constructable<PlaceComponent>): ParameterDefinition<any>[];
|
|
62
64
|
function getDefinition(snapshotOrConstructor: ActivatedRouteSnapshot | Constructable<PlaceComponent>): PlaceDefinition;
|
|
63
65
|
function injectDefinition(klass: Constructable<PlaceComponent>, definition: PlaceDefinition): void;
|
|
66
|
+
type InterceptCallback<T> = (is: T, was: T, interactionContext: InteractionContext) => boolean | Promise<boolean>;
|
|
67
|
+
interface InterceptOptions {
|
|
68
|
+
initialValue: 'evaluationUnlessNil' | 'evaluate';
|
|
69
|
+
}
|
|
64
70
|
}
|
|
@@ -12,6 +12,7 @@ export declare class PlaceHistory {
|
|
|
12
12
|
private _previousVisits;
|
|
13
13
|
private _archive;
|
|
14
14
|
private readonly placeHistoryDepth;
|
|
15
|
+
constructor();
|
|
15
16
|
notifyNavigationStarted(): void;
|
|
16
17
|
notifyNavigationFinished(visits: Visit): void;
|
|
17
18
|
updateVisitSegment(visit: VisitSegment): void;
|
|
@@ -3,8 +3,8 @@ import { ActivatedRouteSnapshot, NavigationCancel, NavigationEnd, NavigationErro
|
|
|
3
3
|
import { GarbageCollector, MutableValueModel, ValueModel, ValueModelChain } from "@coolon/pectin";
|
|
4
4
|
import { Constructable } from "@coolon/typescript-utilities";
|
|
5
5
|
import { InteractionService } from "../interaction/services/interaction.service";
|
|
6
|
-
import { NavigationSession } from "./navigation/session/navigation-session";
|
|
7
6
|
import { PlaceAuthService } from "./place-auth-service";
|
|
7
|
+
import { NavigationSession } from "./navigation/session/navigation-session";
|
|
8
8
|
import { PlaceComponent } from "./place-component";
|
|
9
9
|
import { PlaceHistory } from "./place-history";
|
|
10
10
|
import { UrlService } from "./url-service";
|
|
@@ -42,7 +42,7 @@ export declare class PlaceRouter extends GarbageCollector {
|
|
|
42
42
|
onRouterError(event: NavigationError): void;
|
|
43
43
|
onRouterEnd(event: NavigationEnd): void;
|
|
44
44
|
navigate(visit: Visit): any;
|
|
45
|
-
navigate(placeComponent: Constructable<PlaceComponent>, params?: Record<string,
|
|
45
|
+
navigate(placeComponent: Constructable<PlaceComponent>, params?: Record<string, any>): any;
|
|
46
46
|
doNavigation(visit: Visit, runNavigationCommands: (router: Router) => any): Promise<void>;
|
|
47
47
|
navigateByUrl(urlSnapshot: UrlSnapshot, navigationExtras?: NavigationExtras): Promise<boolean>;
|
|
48
48
|
get activeVisit$(): ValueModel<Visit>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Constructable } from '@coolon/pectin';
|
|
2
2
|
import { PlaceComponent } from './place-component';
|
|
3
|
-
export declare function Place(options: Place.Options): (target:
|
|
3
|
+
export declare function Place(options: Place.Options): (target: Function) => void;
|
|
4
4
|
export declare namespace Place {
|
|
5
5
|
interface Options {
|
|
6
6
|
path: string;
|
|
@@ -14,11 +14,12 @@ import * as i12 from "@angular/material/list";
|
|
|
14
14
|
import * as i13 from "@angular/material/tooltip";
|
|
15
15
|
import * as i14 from "@angular/material/icon";
|
|
16
16
|
import * as i15 from "../directives/directives.module";
|
|
17
|
-
import * as i16 from "
|
|
18
|
-
import * as i17 from "
|
|
19
|
-
import * as i18 from "@angular/
|
|
17
|
+
import * as i16 from "@angular/flex-layout";
|
|
18
|
+
import * as i17 from "../components/components.module";
|
|
19
|
+
import * as i18 from "@angular/cdk/portal";
|
|
20
|
+
import * as i19 from "@angular/material/card";
|
|
20
21
|
export declare class PlaceModule {
|
|
21
22
|
static ɵfac: i0.ɵɵFactoryDeclaration<PlaceModule, never>;
|
|
22
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<PlaceModule, [typeof i1.PlaceOutletComponent, typeof i2.TabbedPlaceNavigationComponent, typeof i3.ListPlaceNavComponent, typeof i4.SidePlaceNavigationComponent, typeof i5.AbstractPlaceNavigationComponent, typeof i6.NotAuthorisedNoticeComponent], [typeof i7.CommonModule, typeof i8.BrowserAnimationsModule, typeof i9.MatProgressSpinnerModule, typeof i10.RouterModule, typeof i11.MatTabsModule, typeof i12.MatListModule, typeof i13.MatTooltipModule, typeof i14.MatIconModule, typeof i15.DirectivesModule, typeof i16.
|
|
23
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<PlaceModule, [typeof i1.PlaceOutletComponent, typeof i2.TabbedPlaceNavigationComponent, typeof i3.ListPlaceNavComponent, typeof i4.SidePlaceNavigationComponent, typeof i5.AbstractPlaceNavigationComponent, typeof i6.NotAuthorisedNoticeComponent], [typeof i7.CommonModule, typeof i8.BrowserAnimationsModule, typeof i9.MatProgressSpinnerModule, typeof i10.RouterModule, typeof i11.MatTabsModule, typeof i12.MatListModule, typeof i13.MatTooltipModule, typeof i14.MatIconModule, typeof i15.DirectivesModule, typeof i16.FlexModule, typeof i17.ComponentsModule, typeof i18.PortalModule, typeof i19.MatCardModule], [typeof i1.PlaceOutletComponent, typeof i2.TabbedPlaceNavigationComponent, typeof i3.ListPlaceNavComponent, typeof i4.SidePlaceNavigationComponent, typeof i5.AbstractPlaceNavigationComponent]>;
|
|
23
24
|
static ɵinj: i0.ɵɵInjectorDeclaration<PlaceModule>;
|
|
24
25
|
}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
export type JsonPrimitive = boolean | number | string;
|
|
2
|
-
export type AnyJson = JsonPrimitive | null |
|
|
2
|
+
export type AnyJson = JsonPrimitive | null | JsonArray | JsonMap;
|
|
3
|
+
export interface JsonArray extends Array<AnyJson> {
|
|
4
|
+
}
|
|
3
5
|
export interface JsonMap {
|
|
4
6
|
[key: string]: AnyJson;
|
|
5
7
|
}
|
|
@@ -4,7 +4,7 @@ export declare class VisitSegment {
|
|
|
4
4
|
readonly placeDefinition: PlaceDefinition;
|
|
5
5
|
readonly visitParameters: Record<string, any>;
|
|
6
6
|
constructor(placeDefinition: PlaceDefinition, visitParameters?: Record<string, any>);
|
|
7
|
-
getRouteId():
|
|
7
|
+
getRouteId(): any;
|
|
8
8
|
hasRouteId(): boolean;
|
|
9
9
|
/**
|
|
10
10
|
* Returns the value of the place parameter with the specified name. The parameter
|
|
@@ -13,9 +13,9 @@ export declare class VisitSegment {
|
|
|
13
13
|
* @param parameter the visit parameter definition
|
|
14
14
|
*/
|
|
15
15
|
getParameterValue<T, S>(parameter: ParameterDefinition<T, S> | string): T;
|
|
16
|
-
hasParameter(parameterDef: ParameterDefinition<
|
|
17
|
-
replace<T>(parameter: ParameterDefinition<T,
|
|
18
|
-
mergeRouteParameters(routeParams: Record<string,
|
|
16
|
+
hasParameter(parameterDef: ParameterDefinition<any>): boolean;
|
|
17
|
+
replace<T>(parameter: ParameterDefinition<T, any>, value: T): VisitSegment;
|
|
18
|
+
mergeRouteParameters<S>(routeParams: Record<string, any>): VisitSegment;
|
|
19
19
|
hasRoutingChangedFrom(other: VisitSegment): boolean;
|
|
20
20
|
hasChangedFrom(other: VisitSegment): boolean;
|
|
21
21
|
createRouterCommands(): string[];
|
package/lib/place/visit.d.ts
CHANGED
|
@@ -7,11 +7,11 @@ export declare class Visit {
|
|
|
7
7
|
protected segmentsByPlaceComponent: Map<Constructable<PlaceComponent>, VisitSegment>;
|
|
8
8
|
protected readonly destinationSegment: VisitSegment;
|
|
9
9
|
protected readonly destinationPlaceDef: PlaceDefinition;
|
|
10
|
-
static goto(placeComponent: Constructable<PlaceComponent>, visitParameters?: Record<string,
|
|
10
|
+
static goto(placeComponent: Constructable<PlaceComponent>, visitParameters?: Record<string, any>): Visit;
|
|
11
11
|
static fromSegments(segments: VisitSegment[]): Visit;
|
|
12
12
|
protected constructor(segments: VisitSegment[]);
|
|
13
13
|
protected get definedSegments(): Map<Constructable<PlaceComponent>, VisitSegment>;
|
|
14
|
-
withAncestorParameters(placeComponent: Constructable<PlaceComponent>, parameters: Record<string,
|
|
14
|
+
withAncestorParameters(placeComponent: Constructable<PlaceComponent>, parameters: Record<string, any>): this;
|
|
15
15
|
get segments(): VisitSegment[];
|
|
16
16
|
private resolveSegments;
|
|
17
17
|
copyWithDefaultsFrom(other: Visit | undefined): Visit;
|
|
@@ -5,7 +5,7 @@ export declare class VisibilityService extends GarbageCollector {
|
|
|
5
5
|
private readonly attributeName;
|
|
6
6
|
private readonly eventName;
|
|
7
7
|
private _visible$;
|
|
8
|
-
constructor(document:
|
|
8
|
+
constructor(document: any);
|
|
9
9
|
protected updateVisibilityState(): void;
|
|
10
10
|
/**
|
|
11
11
|
* @deprecated use visible$ instead.
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coolon/angular-ui-powerups",
|
|
3
|
-
"version": "16.1.0-aplpha.
|
|
3
|
+
"version": "16.1.0-aplpha.8",
|
|
4
|
+
"schematics": "./schematics/collection.json",
|
|
4
5
|
"peerDependencies": {
|
|
5
6
|
"@angular/animations": "^16.2.9",
|
|
6
7
|
"@angular/common": "^16.2.9",
|
|
@@ -10,21 +11,19 @@
|
|
|
10
11
|
"@angular/material": "^16.2.10",
|
|
11
12
|
"@angular/platform-browser": "^16.2.9",
|
|
12
13
|
"@angular/platform-browser-dynamic": "^16.2.9",
|
|
13
|
-
"@angular/material-moment-adapter": "^16.2.
|
|
14
|
+
"@angular/material-moment-adapter": "^16.2.1",
|
|
14
15
|
"@angular/router": "^16.2.9",
|
|
15
|
-
"@coolon/pectin": "^5.0.0-alpha.
|
|
16
|
-
"fast-
|
|
16
|
+
"@coolon/pectin": "^5.0.0-alpha.0",
|
|
17
|
+
"@typescript-plus/fast-memoize-decorator": "^0.2.1",
|
|
17
18
|
"lodash-es": "^4.17.21",
|
|
18
19
|
"marked": "4.0.10",
|
|
19
20
|
"reflect-metadata": "^0.1.13",
|
|
20
21
|
"resize-observer-polyfill": "^1.5.1",
|
|
21
22
|
"typescript-string-enums": "^1.0.0",
|
|
22
23
|
"json5": "^2.1.0",
|
|
23
|
-
"immer": ">=
|
|
24
|
+
"immer": ">=7.0.15",
|
|
24
25
|
"escape-string-regexp": "^5.0.0",
|
|
25
|
-
"@coolon/typescript-utilities": "^5.0.0-alpha.
|
|
26
|
-
"fractional-indexing": "^3.2.0",
|
|
27
|
-
"ng-table-virtual-scroll": "^1.6.0"
|
|
26
|
+
"@coolon/typescript-utilities": "^5.0.0-alpha.3"
|
|
28
27
|
},
|
|
29
28
|
"optionalDependencies": {
|
|
30
29
|
"@fortawesome/fontawesome-free": "^6.0.0"
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
export {};
|
|
2
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZm9ybS1maWVsZC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uL2xpYnMvYW5ndWxhci11aS1wb3dlcnVwcy9zcmMvbGliL2NvbXBvbmVudHMvZm9ybXMvZm9ybS1maWVsZC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0IGludGVyZmFjZSBGb3JtRmllbGQge1xuICBsYWJlbCgpOnN0cmluZztcbiAgaGludD8oKTpzdHJpbmc7XG4gIHBsYWNlaG9sZGVyPygpOnN0cmluZztcbn1cbiJdfQ==
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { Component, Input } from '@angular/core';
|
|
2
|
-
import { Command, Dsl } from '@coolon/pectin';
|
|
3
|
-
import { AbstractValueInputComponent } from '../abstract-value-input.component';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
import * as i1 from "@angular/forms";
|
|
6
|
-
import * as i2 from "@angular/material/input";
|
|
7
|
-
import * as i3 from "@angular/material/form-field";
|
|
8
|
-
import * as i4 from "../../../directives/command.directive";
|
|
9
|
-
import * as i5 from "../../../directives/focus-binding.directive";
|
|
10
|
-
import * as i6 from "@angular/material/button";
|
|
11
|
-
import * as i7 from "../../icon/icon.component";
|
|
12
|
-
export class SearchInputComponent extends AbstractValueInputComponent {
|
|
13
|
-
autocomplete;
|
|
14
|
-
clearCommand;
|
|
15
|
-
constructor() {
|
|
16
|
-
super();
|
|
17
|
-
this.dense = true;
|
|
18
|
-
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
19
|
-
this.clearCommand = Command.create(() => {
|
|
20
|
-
this.componentValue$.value = "";
|
|
21
|
-
});
|
|
22
|
-
this.clearCommand.disableWhile(chain.stringValue(this.componentValue$).isBlank());
|
|
23
|
-
}
|
|
24
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: SearchInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
25
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: SearchInputComponent, selector: "aup-search-input", inputs: { autocomplete: "autocomplete" }, usesInheritance: true, ngImport: i0, template: "<mat-form-field [floatLabel]=\"floatLabel\">\n\n <input matInput\n placeholder=\"{{placeholder}}\"\n [attr.autocomplete]=\"autocomplete\"\n [(ngModel)]=\"componentValue$.value\"\n [disabled]=\"!enabled$.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <aup-icon matPrefix icon=\"mat:search\"></aup-icon>\n <button mat-icon-button matSuffix [pectinCommand]=\"clearCommand\">\n <aup-icon icon=\"mat:close\"></aup-icon>\n </button>\n</mat-form-field>\n\n", styles: ["button[disabled]{visibility:hidden}\n"], dependencies: [{ kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "component", type: i3.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3.MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: i3.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: i4.CommandDirective, selector: "[pectinCommand]", inputs: ["pectinCommand", "commandParameter"] }, { kind: "directive", type: i5.FocusBindingDirective, selector: "[pectinFocusBinding]", inputs: ["pectinFocusBinding", "focusBindingTarget"] }, { kind: "component", type: i6.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i7.IconComponent, selector: "aup-icon", inputs: ["icon"] }] });
|
|
26
|
-
}
|
|
27
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: SearchInputComponent, decorators: [{
|
|
28
|
-
type: Component,
|
|
29
|
-
args: [{ selector: 'aup-search-input', template: "<mat-form-field [floatLabel]=\"floatLabel\">\n\n <input matInput\n placeholder=\"{{placeholder}}\"\n [attr.autocomplete]=\"autocomplete\"\n [(ngModel)]=\"componentValue$.value\"\n [disabled]=\"!enabled$.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <aup-icon matPrefix icon=\"mat:search\"></aup-icon>\n <button mat-icon-button matSuffix [pectinCommand]=\"clearCommand\">\n <aup-icon icon=\"mat:close\"></aup-icon>\n </button>\n</mat-form-field>\n\n", styles: ["button[disabled]{visibility:hidden}\n"] }]
|
|
30
|
-
}], ctorParameters: function () { return []; }, propDecorators: { autocomplete: [{
|
|
31
|
-
type: Input
|
|
32
|
-
}] } });
|
|
33
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2VhcmNoLWlucHV0LmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uL2xpYnMvYW5ndWxhci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XggW3BlY3RpbkNvbW1hbmRdPVwiY2xlYXJDb21tYW5kXCI+XG4gICAgPGF1cC1pY29uIGljb249XCJtYXQ6Y2xvc2VcIj48L2F1cC1pY29uPlxuICA8L2J1dHRvbj5cbjwvbWF0LWZvcm0tZmllbGQ+XG5cbiJdfQ==
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { Directive, inject } from '@angular/core';
|
|
2
|
-
import { MutableValueModel } from '@coolon/pectin';
|
|
3
|
-
import { DisposableComponent } from "./disposable-component";
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
export class LoadableComponent extends DisposableComponent {
|
|
6
|
-
#_loaded$ = new MutableValueModel();
|
|
7
|
-
#asyncLoadables = [];
|
|
8
|
-
#awaitedLoadables = [];
|
|
9
|
-
get loaded$() {
|
|
10
|
-
return this.#_loaded$.readonly$;
|
|
11
|
-
}
|
|
12
|
-
ngOnInit() {
|
|
13
|
-
super.ngOnInit();
|
|
14
|
-
this.#asyncLoadables.forEach(it => it.ensureLoaded());
|
|
15
|
-
if (this.#awaitedLoadables.length > 0) {
|
|
16
|
-
Promise.all(this.#awaitedLoadables.map(it => {
|
|
17
|
-
return it.ensureLoaded(); //.then(() => console.log(`${it.constructor.name} loaded`));
|
|
18
|
-
})).then(() => {
|
|
19
|
-
this.#_loaded$.value = true;
|
|
20
|
-
});
|
|
21
|
-
}
|
|
22
|
-
else {
|
|
23
|
-
this.#_loaded$.value = true;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
injectLoadable(token, options) {
|
|
27
|
-
return this.registerLoadable(inject(token), options);
|
|
28
|
-
}
|
|
29
|
-
registerLoadable(loadable, options) {
|
|
30
|
-
if (this.loaded$.value) {
|
|
31
|
-
loadable.ensureLoaded();
|
|
32
|
-
}
|
|
33
|
-
else {
|
|
34
|
-
if (!options || options.wait === true) {
|
|
35
|
-
this.#awaitedLoadables.push(loadable);
|
|
36
|
-
}
|
|
37
|
-
else {
|
|
38
|
-
this.#asyncLoadables.push(loadable);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
return loadable;
|
|
42
|
-
}
|
|
43
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: LoadableComponent, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
44
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.9", type: LoadableComponent, usesInheritance: true, ngImport: i0 });
|
|
45
|
-
}
|
|
46
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: LoadableComponent, decorators: [{
|
|
47
|
-
type: Directive
|
|
48
|
-
}] });
|
|
49
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9hZGFibGUtY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9hbmd1bGFyLXVpLXBvd2VydXBzL3NyYy9saWIvY29tcG9uZW50cy9sb2FkYWJsZS1jb21wb25lbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFDLFNBQVMsRUFBRSxNQUFNLEVBQWdCLE1BQU0sZUFBZSxDQUFDO0FBQy9ELE9BQU8sRUFBQyxpQkFBaUIsRUFBQyxNQUFNLGdCQUFnQixDQUFDO0FBQ2pELE9BQU8sRUFBQyxtQkFBbUIsRUFBQyxNQUFNLHdCQUF3QixDQUFDOztBQUkzRCxNQUFNLE9BQU8saUJBQWtCLFNBQVEsbUJBQW1CO0lBRXhELFNBQVMsR0FBRyxJQUFJLGlCQUFpQixFQUFXLENBQUM7SUFDN0MsZUFBZSxHQUFlLEVBQUUsQ0FBQztJQUNqQyxpQkFBaUIsR0FBZSxFQUFFLENBQUM7SUFFbkMsSUFBSSxPQUFPO1FBQ1QsT0FBTyxJQUFJLENBQUMsU0F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2F3YWl0ZWRMb2FkYWJsZXMucHVzaChsb2FkYWJsZSlcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIHRoaXMuI2FzeW5jTG9hZGFibGVzLnB1c2gobG9hZGFibGUpXG4gICAgICB9XG4gICAgfVxuICAgIHJldHVybiBsb2FkYWJsZTtcbiAgfVxufVxuIl19
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import { Dsl, GarbageCollector, lang, MutableListModel, WatchList } from '@coolon/pectin';
|
|
2
|
-
import { generateKeyBetween } from "fractional-indexing";
|
|
3
|
-
import { ColumnOrderManager } from "./column-order-manager";
|
|
4
|
-
class ColumnRef {
|
|
5
|
-
column;
|
|
6
|
-
position;
|
|
7
|
-
constructor(column, position) {
|
|
8
|
-
this.column = column;
|
|
9
|
-
this.position = position;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
export class ColumnManager extends GarbageCollector {
|
|
13
|
-
_columnRefs$ = new MutableListModel();
|
|
14
|
-
orderedColumnRefs$;
|
|
15
|
-
_columnsById$;
|
|
16
|
-
allColumns$;
|
|
17
|
-
columnVisibilities$ = new WatchList();
|
|
18
|
-
visibleColumns$;
|
|
19
|
-
constructor() {
|
|
20
|
-
super();
|
|
21
|
-
const { chain } = Dsl.disposeWith(this);
|
|
22
|
-
this.orderedColumnRefs$ = chain(this._columnRefs$).orderBy("position", "asc");
|
|
23
|
-
this.allColumns$ = this.orderedColumnRefs$.pluck("column");
|
|
24
|
-
this._columnsById$ = chain(this.allColumns$).indexBy('columnId');
|
|
25
|
-
this.visibleColumns$ = chain(this.allColumns$).select(it => it.visible$.value, {
|
|
26
|
-
dependsOn: this.columnVisibilities$
|
|
27
|
-
});
|
|
28
|
-
}
|
|
29
|
-
position(column, newPosition) {
|
|
30
|
-
const target = this._columnRefs$.query().findMatching(it => it.column === column);
|
|
31
|
-
const position = this.computePosition(newPosition);
|
|
32
|
-
this._columnRefs$.replace(target, { with: new ColumnRef(target.column, position) });
|
|
33
|
-
}
|
|
34
|
-
getColumn(id) {
|
|
35
|
-
return this._columnsById$.get(id);
|
|
36
|
-
}
|
|
37
|
-
hasColumn(id) {
|
|
38
|
-
return !!this._columnsById$.get(id);
|
|
39
|
-
}
|
|
40
|
-
hasMatchingColumn(row, regex) {
|
|
41
|
-
// only search the visible columns
|
|
42
|
-
return !!this.visibleColumns$.value.find(c => regex.test(c.getSearchTextFor(row)));
|
|
43
|
-
}
|
|
44
|
-
addColumn(column, position) {
|
|
45
|
-
if (this.hasColumn(column.columnId)) {
|
|
46
|
-
lang.illegalState(`Column with id=${column.columnId} already exists`);
|
|
47
|
-
}
|
|
48
|
-
this.registerDisposable(column);
|
|
49
|
-
this._columnRefs$.push(new ColumnRef(column, this.computePosition(position)));
|
|
50
|
-
this.columnVisibilities$.add(column.visible$);
|
|
51
|
-
return column;
|
|
52
|
-
}
|
|
53
|
-
computePosition(position) {
|
|
54
|
-
const q = this.orderedColumnRefs$.query();
|
|
55
|
-
return ColumnOrderManager.processPosition(position, {
|
|
56
|
-
before(col) {
|
|
57
|
-
const index = q.findIndex(ref => ref.column === col);
|
|
58
|
-
const beforeCol = q.value[index];
|
|
59
|
-
const afterCol = index - 1 >= 0 ? q.value[index - 1] : undefined;
|
|
60
|
-
return generateKeyBetween(afterCol?.position, beforeCol.position);
|
|
61
|
-
},
|
|
62
|
-
after(col) {
|
|
63
|
-
const index = q.findIndex(ref => ref.column === col);
|
|
64
|
-
const afterCol = q.value[index];
|
|
65
|
-
const beforeCol = index + 1 < q.length ? q.value[index + 1] : undefined;
|
|
66
|
-
return generateKeyBetween(afterCol.position, beforeCol?.position);
|
|
67
|
-
},
|
|
68
|
-
first() {
|
|
69
|
-
return generateKeyBetween(null, q.first()?.position);
|
|
70
|
-
},
|
|
71
|
-
last() {
|
|
72
|
-
// add it to the end of the list
|
|
73
|
-
return generateKeyBetween(q.last()?.position, null);
|
|
74
|
-
}
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
doComputeValue() {
|
|
78
|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