@coolon/angular-ui-powerups 16.0.2 → 16.1.0-alpha.190
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/activities.scss +8 -6
- package/assets/activities/input-activities.scss +14 -6
- package/assets/draw.scss +20 -0
- package/assets/form.scss +77 -23
- package/assets/icons.scss +2 -1
- package/assets/interaction/editor/inline-string-editor.scss +4 -0
- package/assets/interaction.scss +1 -1
- package/assets/layout.scss +3 -0
- package/assets/place.scss +31 -0
- package/assets/styles.scss +4 -0
- package/assets/table.scss +60 -18
- package/assets/tabs.scss +15 -2
- package/esm2022/lib/angular-ui-powerups.module.mjs +9 -9
- package/esm2022/lib/animations/slide-animations.mjs +15 -10
- package/esm2022/lib/components/alignment.mjs +1 -1
- package/esm2022/lib/components/busy-overlay/busy-overlay.component.mjs +19 -20
- package/esm2022/lib/components/cards/abstract-card-container.component.mjs +36 -13
- package/esm2022/lib/components/cards/card-container/card-container.component.mjs +7 -10
- package/esm2022/lib/components/commands/button-renderer/button-renderer.component.mjs +115 -0
- package/esm2022/lib/components/commands/command/command.component.mjs +66 -56
- package/esm2022/lib/components/commands/command-face/command-face.component.mjs +21 -13
- package/esm2022/lib/components/commands/command-face.mjs +12 -11
- package/esm2022/lib/components/commands/flex.component.mjs +4 -6
- package/esm2022/lib/components/commands/group/command-container.mjs +1 -1
- package/esm2022/lib/components/commands/group/popup-aware.component.mjs +31 -8
- package/esm2022/lib/components/commands/group/popup-container.mjs +1 -1
- package/esm2022/lib/components/commands/group/popup-menu/abstract-popup-menu.component.mjs +37 -31
- package/esm2022/lib/components/commands/group/popup-menu/more-menu.component.mjs +20 -27
- package/esm2022/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.mjs +19 -14
- package/esm2022/lib/components/commands/group/popup-menu/popup-menu.component.mjs +24 -29
- package/esm2022/lib/components/commands/group/tool-bar/tool-bar.component.mjs +12 -19
- package/esm2022/lib/components/commands/separator.component.mjs +8 -16
- package/esm2022/lib/components/components.module.mjs +83 -53
- package/esm2022/lib/components/disposable-component.mjs +54 -7
- package/esm2022/lib/components/empty-state/empty-state.component.mjs +7 -11
- package/esm2022/lib/components/exports.mjs +16 -5
- package/esm2022/lib/components/file/file-download/file-download.component.mjs +89 -0
- package/esm2022/lib/components/focus-container/focus-container.component.mjs +4 -6
- package/esm2022/lib/components/focusable.component.mjs +5 -5
- package/esm2022/lib/components/forms/abstract-input.component.mjs +70 -24
- package/esm2022/lib/components/forms/abstract-list-input.component.mjs +11 -19
- package/esm2022/lib/components/forms/abstract-value-input.component.mjs +11 -19
- package/esm2022/lib/components/forms/autocomplete-input/autocomplete-input.component.mjs +29 -37
- package/esm2022/lib/components/forms/checkbox-input/checkbox-input.component.mjs +10 -10
- package/esm2022/lib/components/forms/form-field.mjs +2 -0
- package/esm2022/lib/components/forms/multiple-select-input/multiple-select-input.component.mjs +22 -28
- package/esm2022/lib/components/forms/number-input/number-input.component.mjs +89 -14
- package/esm2022/lib/components/forms/password-input/password-input.component.mjs +43 -8
- package/esm2022/lib/components/forms/search-input/search-input.component.mjs +33 -0
- package/esm2022/lib/components/forms/select-input/select-input.component.mjs +44 -45
- package/esm2022/lib/components/forms/string-input/string-input.component.mjs +46 -25
- package/esm2022/lib/components/forms/text-input/text-input.component.mjs +12 -10
- package/esm2022/lib/components/icon/icon.component.mjs +10 -7
- package/esm2022/lib/components/labelled-value/labelled-value.component.mjs +4 -6
- package/esm2022/lib/components/loadable-component.mjs +69 -0
- package/esm2022/lib/components/loading-container/loading-container.component.mjs +32 -29
- package/esm2022/lib/components/noop/noop.component.mjs +5 -7
- package/esm2022/lib/components/resize-aware.component.mjs +64 -27
- package/esm2022/lib/components/scroll-container/scroll-container.component.mjs +17 -15
- package/esm2022/lib/components/section-header/section-header.component.mjs +4 -6
- package/esm2022/lib/components/switch-case/switch-case.component.mjs +28 -28
- package/esm2022/lib/components/tables/abstract-table-model.mjs +123 -64
- package/esm2022/lib/components/tables/abstract-table.component.mjs +34 -15
- package/esm2022/lib/components/tables/column/column-manager.mjs +81 -0
- package/esm2022/lib/components/tables/column/column-model.mjs +23 -12
- package/esm2022/lib/components/tables/column/column-order-manager.mjs +19 -0
- package/esm2022/lib/components/tables/column/column-template/column-template.directive.mjs +4 -4
- 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 +7 -6
- package/esm2022/lib/components/tables/column/property-column-model.mjs +6 -6
- package/esm2022/lib/components/tables/column/selection-column-model.mjs +35 -13
- package/esm2022/lib/components/tables/editor/edit-row-controls/edit-row-controls.component.mjs +13 -13
- package/esm2022/lib/components/tables/editor/edit-session.mjs +5 -3
- 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 +3 -2
- package/esm2022/lib/components/tables/filter/table-filter-model.mjs +16 -11
- package/esm2022/lib/components/tables/filter/text-search-predicate.mjs +16 -2
- package/esm2022/lib/components/tables/footer/footer-row-model.mjs +38 -0
- package/esm2022/lib/components/tables/paginator/paginator.component.mjs +12 -12
- package/esm2022/lib/components/tables/renderer/abstract-cell-renderer.mjs +7 -0
- package/esm2022/lib/components/tables/renderer/cell-editors.mjs +1 -1
- package/esm2022/lib/components/tables/renderer/cell-portal-ref.mjs +23 -7
- package/esm2022/lib/components/tables/renderer/default-cell-renderer/default-cell-renderer.component.mjs +6 -8
- package/esm2022/lib/components/tables/renderer/default-header-cell-renderer/default-header-cell-renderer.component.mjs +5 -7
- package/esm2022/lib/components/tables/renderer/select-header-cell/selection-header-cell.component.mjs +26 -14
- package/esm2022/lib/components/tables/renderer/selection-cell/selection-cell.component.mjs +11 -8
- package/esm2022/lib/components/tables/renderer/table-action-column/menu-builder.mjs +2 -0
- package/esm2022/lib/components/tables/renderer/table-action-column/table-action-column.component.mjs +153 -0
- package/esm2022/lib/components/tables/renderer/table-body/table-body.component.mjs +180 -63
- package/esm2022/lib/components/tables/renderer/table-cell/table-cell.component.mjs +12 -12
- package/esm2022/lib/components/tables/renderer/table-custom-more-menu/table-custom-more-menu-popup.component.mjs +45 -0
- package/esm2022/lib/components/tables/renderer/table-custom-more-menu/table-custom-more-menu.component.mjs +71 -0
- package/esm2022/lib/components/tables/renderer/table-footer-row/table-footer-row.component.mjs +30 -0
- package/esm2022/lib/components/tables/renderer/table-header-cell/table-header-cell.component.mjs +5 -7
- package/esm2022/lib/components/tables/table/table-model.mjs +12 -3
- package/esm2022/lib/components/tables/table/table.component.mjs +54 -68
- package/esm2022/lib/components/tables/tree-table/decorated-tree-node.mjs +5 -4
- 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 +5 -5
- package/esm2022/lib/components/tables/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.mjs +5 -7
- package/esm2022/lib/components/tables/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.mjs +16 -13
- package/esm2022/lib/components/tables/tree-table/tree-label-column-model.mjs +4 -7
- package/esm2022/lib/components/tables/tree-table/tree-table-component.mjs +27 -16
- package/esm2022/lib/components/tables/tree-table/tree-table-model.mjs +5 -8
- package/esm2022/lib/components/text/markdown/markdown.component.mjs +25 -22
- package/esm2022/lib/components/track.mjs +24 -0
- package/esm2022/lib/components/types/bounds.class.mjs +1 -5
- package/esm2022/lib/components/vertical-focus-container/vertical-focus-container.component.mjs +17 -17
- package/esm2022/lib/directives/command.directive.mjs +25 -14
- package/esm2022/lib/directives/directives.module.mjs +10 -10
- package/esm2022/lib/directives/exports.mjs +2 -1
- package/esm2022/lib/directives/focus-binding-factory.mjs +4 -4
- package/esm2022/lib/directives/focus-binding.directive.mjs +6 -8
- package/esm2022/lib/directives/focus-binding.mjs +4 -5
- package/esm2022/lib/directives/garbage-collector.directive.mjs +5 -4
- package/esm2022/lib/directives/highlight-text-model.directive.mjs +11 -9
- package/esm2022/lib/directives/highlight.pipe.mjs +12 -11
- package/esm2022/lib/directives/resize-observer.directive.mjs +40 -0
- package/esm2022/lib/interaction/abstract-interaction-context.mjs +6 -7
- package/esm2022/lib/interaction/activity-context.mjs +4 -0
- package/esm2022/lib/interaction/activity-ref.mjs +4 -4
- package/esm2022/lib/interaction/activity.mjs +39 -35
- package/esm2022/lib/interaction/alert.mjs +2 -2
- package/esm2022/lib/interaction/components/abstract-confirm-dialog.component.mjs +13 -10
- package/esm2022/lib/interaction/components/abstract-dialog.component.mjs +4 -45
- package/esm2022/lib/interaction/components/activity-actions/activity-actions.component.mjs +42 -28
- package/esm2022/lib/interaction/components/activity-body/activity-body.component.mjs +10 -6
- package/esm2022/lib/interaction/components/activity-container/activity-container.component.mjs +53 -22
- package/esm2022/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.mjs +55 -19
- package/esm2022/lib/interaction/components/activity-title/activity-title.component.mjs +6 -8
- package/esm2022/lib/interaction/components/activity-triggers/abstract-activity-trigger.component.mjs +41 -31
- package/esm2022/lib/interaction/components/activity-triggers/inline-activity-trigger/inline-activity-trigger.component.mjs +5 -5
- package/esm2022/lib/interaction/components/activity-triggers/modal-activity-trigger/modal-activity-trigger.component.mjs +5 -5
- package/esm2022/lib/interaction/components/activity-triggers/popup-activity-trigger/popup-activity-trigger.component.mjs +5 -5
- package/esm2022/lib/interaction/components/add-card-activity/add-card-activity.component.mjs +6 -8
- package/esm2022/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.mjs +11 -11
- package/esm2022/lib/interaction/components/alert-dialog/alert-dialog.component.mjs +12 -12
- package/esm2022/lib/interaction/components/alert-renderer/alert-renderer.component.mjs +55 -0
- package/esm2022/lib/interaction/components/confirm-renderer/confirm-renderer.component.mjs +54 -0
- package/esm2022/lib/interaction/components/confirm-then-dialog/confirm-then-dialog.component.mjs +6 -10
- package/esm2022/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.mjs +6 -10
- package/esm2022/lib/interaction/components/confirmation-dialog/confirmation-dialog.component.mjs +9 -11
- package/esm2022/lib/interaction/components/editors/edit-context.mjs +1 -1
- package/esm2022/lib/interaction/components/editors/inline-string-editor/inline-editor-model.mjs +5 -5
- package/esm2022/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.mjs +55 -48
- package/esm2022/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.mjs +32 -25
- package/esm2022/lib/interaction/components/input-activities/input-activity.mjs +21 -16
- package/esm2022/lib/interaction/components/input-activities/select-input-activity.mjs +49 -33
- package/esm2022/lib/interaction/components/input-activities/string-input-activity.mjs +30 -28
- package/esm2022/lib/interaction/components/popup-interaction-context/popup-interaction-context.component.mjs +18 -15
- package/esm2022/lib/interaction/components/slide-down-interaction-context/slide-down-interaction-context.component.mjs +134 -0
- package/esm2022/lib/interaction/confirm.mjs +26 -2
- package/esm2022/lib/interaction/directives/interaction-context-trigger-for.directive.mjs +6 -6
- package/esm2022/lib/interaction/exports.mjs +6 -1
- package/esm2022/lib/interaction/in-place-interaction-context.mjs +1 -1
- package/esm2022/lib/interaction/interaction-context-provider.mjs +17 -0
- package/esm2022/lib/interaction/interaction-context.mjs +3 -2
- package/esm2022/lib/interaction/interaction.module.mjs +44 -29
- package/esm2022/lib/interaction/route-synchronisation-adapter.mjs +1 -1
- package/esm2022/lib/interaction/services/interaction-service-routing-adapter.mjs +4 -4
- package/esm2022/lib/interaction/services/interaction.service.mjs +23 -11
- package/esm2022/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context-factory.mjs +9 -10
- package/esm2022/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context.mjs +23 -5
- package/esm2022/lib/interaction/services/modal-interaction-context.factory.mjs +1 -1
- package/esm2022/lib/place/components/abstract-place-navigation.component.mjs +39 -31
- package/esm2022/lib/place/components/list-place-nav/list-place-nav.component.mjs +7 -7
- package/esm2022/lib/place/components/not-authorised-notice/not-authorised-notice.component.mjs +5 -7
- package/esm2022/lib/place/components/place-outlet/place-outlet.component.mjs +49 -44
- 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 +25 -16
- package/esm2022/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.mjs +7 -7
- package/esm2022/lib/place/exports.mjs +2 -1
- package/esm2022/lib/place/guards/consolidated-param-map.mjs +4 -4
- package/esm2022/lib/place/guards/noop-auth-guard.service.mjs +5 -7
- package/esm2022/lib/place/guards/place.guard.mjs +19 -16
- 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 +3 -6
- 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 +2 -2
- 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-auth-service.mjs +152 -0
- package/esm2022/lib/place/place-component.mjs +62 -48
- package/esm2022/lib/place/place-config.mjs +1 -1
- package/esm2022/lib/place/place-definition.mjs +15 -4
- package/esm2022/lib/place/place-history.mjs +6 -8
- package/esm2022/lib/place/place-router.mjs +87 -94
- package/esm2022/lib/place/place.decorator.mjs +2 -2
- package/esm2022/lib/place/place.module.mjs +16 -12
- 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 +54 -50
- package/esm2022/lib/place/route/parameter-definition.mjs +6 -2
- package/esm2022/lib/place/route/parameter-sanitiser.mjs +7 -2
- 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 +4 -4
- 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 +5 -7
- package/esm2022/lib/services/markdown/pill-plugin.mjs +1 -3
- package/esm2022/lib/services/visibility-service.mjs +9 -9
- package/fesm2022/coolon-angular-ui-powerups.mjs +4720 -3041
- package/fesm2022/coolon-angular-ui-powerups.mjs.map +1 -1
- package/lib/angular-ui-powerups.module.d.ts +5 -5
- package/lib/animations/slide-animations.d.ts +1 -0
- package/lib/components/busy-overlay/busy-overlay.component.d.ts +4 -7
- package/lib/components/cards/abstract-card-container.component.d.ts +9 -7
- package/lib/components/cards/card-container/card-container.component.d.ts +3 -4
- package/lib/components/commands/button-renderer/button-renderer.component.d.ts +30 -0
- package/lib/components/commands/command/command.component.d.ts +15 -17
- package/lib/components/commands/command-face/command-face.component.d.ts +5 -5
- package/lib/components/commands/command-face.d.ts +8 -9
- package/lib/components/commands/flex.component.d.ts +1 -3
- package/lib/components/commands/group/popup-aware.component.d.ts +9 -4
- package/lib/components/commands/group/popup-menu/abstract-popup-menu.component.d.ts +7 -7
- package/lib/components/commands/group/popup-menu/more-menu.component.d.ts +4 -6
- package/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.d.ts +7 -5
- package/lib/components/commands/group/popup-menu/popup-menu.component.d.ts +5 -7
- package/lib/components/commands/group/tool-bar/tool-bar.component.d.ts +3 -7
- package/lib/components/commands/separator.component.d.ts +3 -6
- package/lib/components/components.module.d.ts +57 -51
- package/lib/components/disposable-component.d.ts +21 -3
- package/lib/components/empty-state/empty-state.component.d.ts +1 -4
- package/lib/components/exports.d.ts +15 -4
- package/lib/components/file/file-download/file-download.component.d.ts +45 -0
- package/lib/components/focus-container/focus-container.component.d.ts +1 -3
- package/lib/components/forms/abstract-input.component.d.ts +21 -13
- package/lib/components/forms/abstract-list-input.component.d.ts +4 -8
- package/lib/components/forms/abstract-value-input.component.d.ts +3 -7
- package/lib/components/forms/autocomplete-input/autocomplete-input.component.d.ts +8 -14
- package/lib/components/forms/checkbox-input/checkbox-input.component.d.ts +3 -3
- package/lib/components/forms/form-field.d.ts +5 -0
- package/lib/components/forms/multiple-select-input/multiple-select-input.component.d.ts +3 -8
- package/lib/components/forms/number-input/number-input.component.d.ts +17 -7
- package/lib/components/forms/password-input/password-input.component.d.ts +8 -4
- package/lib/components/forms/search-input/search-input.component.d.ts +10 -0
- package/lib/components/forms/select-input/select-input.component.d.ts +7 -10
- package/lib/components/forms/string-input/string-input.component.d.ts +10 -6
- package/lib/components/forms/text-input/text-input.component.d.ts +4 -3
- package/lib/components/labelled-value/labelled-value.component.d.ts +1 -3
- package/lib/components/loadable-component.d.ts +20 -0
- package/lib/components/loading-container/loading-container.component.d.ts +6 -9
- package/lib/components/noop/noop.component.d.ts +0 -1
- package/lib/components/resize-aware.component.d.ts +25 -6
- package/lib/components/scroll-container/scroll-container.component.d.ts +2 -3
- package/lib/components/section-header/section-header.component.d.ts +1 -3
- package/lib/components/switch-case/switch-case.component.d.ts +10 -12
- package/lib/components/tables/abstract-table-model.d.ts +50 -23
- package/lib/components/tables/abstract-table.component.d.ts +8 -7
- package/lib/components/tables/column/column-manager.d.ts +19 -0
- package/lib/components/tables/column/column-model.d.ts +8 -4
- package/lib/components/tables/column/column-order-manager.d.ts +20 -0
- package/lib/components/tables/column/custom-template-column-model.d.ts +3 -2
- package/lib/components/tables/column/custom-value-column-model.d.ts +3 -2
- package/lib/components/tables/column/editor-controls-column-model.d.ts +3 -2
- package/lib/components/tables/column/list-propery-column-model.d.ts +3 -2
- package/lib/components/tables/column/property-column-model.d.ts +3 -2
- package/lib/components/tables/column/selection-column-model.d.ts +10 -4
- package/lib/components/tables/editor/edit-row-controls/edit-row-controls.component.d.ts +4 -6
- package/lib/components/tables/editor/edit-session.d.ts +1 -1
- 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 +9 -0
- package/lib/components/tables/footer/footer-row-model.d.ts +22 -0
- package/lib/components/tables/paginator/paginator.component.d.ts +2 -4
- package/lib/components/tables/renderer/abstract-cell-renderer.d.ts +6 -0
- package/lib/components/tables/renderer/cell-editors.d.ts +5 -5
- package/lib/components/tables/renderer/cell-portal-ref.d.ts +21 -14
- package/lib/components/tables/renderer/default-cell-renderer/default-cell-renderer.component.d.ts +0 -1
- package/lib/components/tables/renderer/default-header-cell-renderer/default-header-cell-renderer.component.d.ts +0 -1
- package/lib/components/tables/renderer/select-header-cell/selection-header-cell.component.d.ts +3 -2
- package/lib/components/tables/renderer/table-action-column/menu-builder.d.ts +7 -0
- package/lib/components/tables/renderer/table-action-column/table-action-column.component.d.ts +42 -0
- package/lib/components/tables/renderer/table-body/table-body.component.d.ts +47 -24
- package/lib/components/tables/renderer/table-cell/table-cell.component.d.ts +3 -5
- package/lib/components/tables/renderer/table-custom-more-menu/table-custom-more-menu-popup.component.d.ts +19 -0
- package/lib/components/tables/renderer/table-custom-more-menu/table-custom-more-menu.component.d.ts +24 -0
- package/lib/components/tables/renderer/table-footer-row/table-footer-row.component.d.ts +11 -0
- package/lib/components/tables/renderer/table-header-cell/table-header-cell.component.d.ts +0 -1
- package/lib/components/tables/table/table-model.d.ts +4 -4
- package/lib/components/tables/table/table.component.d.ts +18 -14
- package/lib/components/tables/tree-table/flattened-tree-list-model.d.ts +1 -1
- 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 +0 -1
- package/lib/components/tables/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.d.ts +3 -3
- package/lib/components/tables/tree-table/tree-label-column-model.d.ts +3 -3
- package/lib/components/tables/tree-table/tree-table-component.d.ts +7 -4
- package/lib/components/tables/tree-table/tree-table-model.d.ts +4 -5
- package/lib/components/text/markdown/markdown.component.d.ts +3 -4
- package/lib/components/{track-by.d.ts → track.d.ts} +4 -7
- package/lib/components/types/bounds.class.d.ts +0 -2
- package/lib/components/vertical-focus-container/vertical-focus-container.component.d.ts +3 -6
- package/lib/directives/command.directive.d.ts +7 -5
- package/lib/directives/directives.module.d.ts +5 -5
- package/lib/directives/exports.d.ts +1 -0
- package/lib/directives/focus-binding.directive.d.ts +2 -3
- package/lib/directives/highlight-text-model.directive.d.ts +1 -1
- package/lib/directives/resize-observer.directive.d.ts +16 -0
- package/lib/interaction/abstract-interaction-context.d.ts +1 -1
- package/lib/interaction/activity-context.d.ts +9 -0
- package/lib/interaction/activity-ref.d.ts +2 -2
- package/lib/interaction/activity.d.ts +9 -9
- package/lib/interaction/components/abstract-confirm-dialog.component.d.ts +2 -1
- package/lib/interaction/components/abstract-dialog.component.d.ts +5 -14
- package/lib/interaction/components/activity-actions/activity-actions.component.d.ts +15 -13
- package/lib/interaction/components/activity-body/activity-body.component.d.ts +3 -4
- package/lib/interaction/components/activity-container/activity-container.component.d.ts +11 -5
- package/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.d.ts +4 -5
- package/lib/interaction/components/activity-title/activity-title.component.d.ts +2 -4
- package/lib/interaction/components/activity-triggers/abstract-activity-trigger.component.d.ts +7 -8
- package/lib/interaction/components/add-card-activity/add-card-activity.component.d.ts +1 -3
- package/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.d.ts +2 -4
- package/lib/interaction/components/alert-dialog/alert-dialog.component.d.ts +6 -1
- package/lib/interaction/components/alert-renderer/alert-renderer.component.d.ts +17 -0
- package/lib/interaction/components/confirm-renderer/confirm-renderer.component.d.ts +15 -0
- package/lib/interaction/components/confirm-then-dialog/confirm-then-dialog.component.d.ts +1 -1
- package/lib/interaction/components/editors/edit-context.d.ts +1 -1
- package/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.d.ts +7 -9
- package/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.d.ts +9 -7
- package/lib/interaction/components/input-activities/input-activity.d.ts +5 -3
- package/lib/interaction/components/input-activities/select-input-activity.d.ts +4 -2
- package/lib/interaction/components/input-activities/string-input-activity.d.ts +1 -1
- package/lib/interaction/components/popup-interaction-context/popup-interaction-context.component.d.ts +4 -5
- package/lib/interaction/components/slide-down-interaction-context/slide-down-interaction-context.component.d.ts +53 -0
- package/lib/interaction/confirm.d.ts +4 -0
- package/lib/interaction/directives/interaction-context-trigger-for.directive.d.ts +3 -3
- package/lib/interaction/exports.d.ts +5 -0
- package/lib/interaction/interaction-context-provider.d.ts +11 -0
- package/lib/interaction/interaction-context.d.ts +7 -1
- package/lib/interaction/interaction.module.d.ts +35 -32
- package/lib/interaction/services/interaction-service-routing-adapter.d.ts +3 -3
- package/lib/interaction/services/interaction.service.d.ts +2 -1
- package/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context-factory.d.ts +2 -3
- package/lib/interaction/services/mat-dialog-interaction/dialog-interaction-context.d.ts +4 -3
- package/lib/place/components/abstract-place-navigation.component.d.ts +8 -8
- package/lib/place/components/not-authorised-notice/not-authorised-notice.component.d.ts +0 -1
- package/lib/place/components/place-outlet/place-outlet.component.d.ts +9 -11
- package/lib/place/components/side-place-navigation/side-place-navigation.component.d.ts +4 -3
- package/lib/place/exports.d.ts +1 -0
- package/lib/place/guards/noop-auth-guard.service.d.ts +0 -1
- package/lib/place/guards/place.guard.d.ts +2 -2
- package/lib/place/navigation/session/interactions/remove-last-interaction-from-url-navigation-session.d.ts +0 -1
- package/lib/place/navigation/session/interactions/synchronise-interaction-context-ids-with-route.d.ts +2 -2
- package/lib/place/place-access-guard.d.ts +2 -2
- package/lib/place/place-auth-service.d.ts +49 -0
- package/lib/place/place-component.d.ts +11 -12
- package/lib/place/place-definition.d.ts +2 -0
- package/lib/place/place-history.d.ts +0 -1
- package/lib/place/place-router.d.ts +11 -13
- package/lib/place/place.decorator.d.ts +1 -1
- package/lib/place/place.module.d.ts +6 -5
- package/lib/place/route/json-types.d.ts +1 -3
- package/lib/place/route/parameter-decorators.d.ts +3 -4
- package/lib/place/route/parameter-definition.d.ts +3 -3
- package/lib/place/route/parameter-sanitiser.d.ts +7 -0
- package/lib/place/url-snapshot.d.ts +3 -3
- 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 +0 -1
- package/lib/services/visibility-service.d.ts +1 -1
- package/package.json +20 -19
- package/esm2022/lib/components/cards/card-stack/card-stack.component.mjs +0 -81
- package/esm2022/lib/components/tables/column/column-list-model.mjs +0 -44
- package/esm2022/lib/components/tables/table-row-menu/table-row-menu.component.mjs +0 -84
- package/esm2022/lib/components/track-by.mjs +0 -24
- package/lib/components/cards/card-stack/card-stack.component.d.ts +0 -68
- package/lib/components/tables/column/column-list-model.d.ts +0 -13
- package/lib/components/tables/table-row-menu/table-row-menu.component.d.ts +0 -28
- package/schematics/activity/index.d.ts +0 -3
- package/schematics/activity/index.js +0 -32
- package/schematics/activity/index.js.map +0 -1
- package/schematics/activity/index.spec.d.ts +0 -1
- package/schematics/activity/index.spec.js +0 -364
- package/schematics/activity/index.spec.js.map +0 -1
- package/schematics/activity/schema.d.ts +0 -4
- package/schematics/activity/schema.js +0 -3
- package/schematics/activity/schema.js.map +0 -1
- package/schematics/activity/schema.json +0 -27
- package/schematics/activity/templates/component/__name@dasherize__.component.html.template +0 -5
- package/schematics/activity/templates/component/__name@dasherize__.component.scss.template +0 -4
- package/schematics/activity/templates/component/__name@dasherize__.component.spec.ts.template +0 -25
- package/schematics/activity/templates/component/__name@dasherize__.component.ts.template +0 -40
- package/schematics/activity/templates/component/__name@dasherize__.i18n.yml.template +0 -9
- package/schematics/aup-i18n/index.d.ts +0 -4
- package/schematics/aup-i18n/index.js +0 -86
- package/schematics/aup-i18n/index.js.map +0 -1
- package/schematics/aup-i18n/schema.d.ts +0 -3
- package/schematics/aup-i18n/schema.js +0 -3
- package/schematics/aup-i18n/schema.js.map +0 -1
- package/schematics/aup-i18n/schema.json +0 -18
- package/schematics/aup-i18n/templates/app/aup.i18n.yml.template +0 -80
- package/schematics/bootstrap-app/index.d.ts +0 -4
- package/schematics/bootstrap-app/index.js +0 -109
- package/schematics/bootstrap-app/index.js.map +0 -1
- package/schematics/bootstrap-app/schema.d.ts +0 -3
- package/schematics/bootstrap-app/schema.js +0 -3
- package/schematics/bootstrap-app/schema.js.map +0 -1
- package/schematics/bootstrap-app/schema.json +0 -18
- package/schematics/bootstrap-app/templates/i18n.config.json.template +0 -11
- package/schematics/bootstrap-app/templates/src/app/app-routing.module.ts.template +0 -23
- package/schematics/bootstrap-app/templates/src/app/app.component.html.template +0 -7
- package/schematics/bootstrap-app/templates/src/app/app.component.scss.template +0 -12
- package/schematics/bootstrap-app/templates/src/app/app.component.ts.template +0 -19
- package/schematics/bootstrap-app/templates/src/app/app.module.ts.template +0 -74
- package/schematics/bootstrap-app/templates/src/app/components/components.module.ts.template +0 -16
- package/schematics/bootstrap-app/templates/src/app/i18n.ts.template +0 -9
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/MaterialIcons-Regular.eot +0 -0
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/MaterialIcons-Regular.ijmap +0 -1
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/MaterialIcons-Regular.svg +0 -2373
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/MaterialIcons-Regular.ttf +0 -0
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/MaterialIcons-Regular.woff +0 -0
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/MaterialIcons-Regular.woff2 +0 -0
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/README.md +0 -9
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/codepoints +0 -932
- package/schematics/bootstrap-app/templates/src/assets/fonts/material-design-icons/material-icons.css +0 -36
- package/schematics/bootstrap-app/templates/src/index.html.template +0 -13
- package/schematics/bootstrap-app/templates/src/styles/global-variables.scss.template +0 -13
- package/schematics/bootstrap-app/templates/src/styles.scss.template +0 -85
- package/schematics/collection.json +0 -48
- package/schematics/component/index.d.ts +0 -3
- package/schematics/component/index.js +0 -36
- package/schematics/component/index.js.map +0 -1
- package/schematics/component/index.spec.d.ts +0 -1
- package/schematics/component/index.spec.js +0 -364
- package/schematics/component/index.spec.js.map +0 -1
- package/schematics/component/schema.d.ts +0 -5
- package/schematics/component/schema.js +0 -3
- package/schematics/component/schema.js.map +0 -1
- package/schematics/component/schema.json +0 -39
- package/schematics/component/templates/component/__name@dasherize__.component.html.template +0 -1
- package/schematics/component/templates/component/__name@dasherize__.component.scss.template +0 -4
- package/schematics/component/templates/component/__name@dasherize__.component.spec.ts.template +0 -25
- package/schematics/component/templates/component/__name@dasherize__.component.ts.template +0 -24
- package/schematics/component/templates/component/__name@dasherize__.i18n.yml.template +0 -1
- package/schematics/ng-add/index.d.ts +0 -3
- package/schematics/ng-add/index.js +0 -37
- package/schematics/ng-add/index.js.map +0 -1
- package/schematics/package-util.d.ts +0 -13
- package/schematics/package-util.js +0 -61
- package/schematics/package-util.js.map +0 -1
- package/schematics/place-add/index.d.ts +0 -3
- package/schematics/place-add/index.js +0 -45
- package/schematics/place-add/index.js.map +0 -1
- package/schematics/place-add/index.spec.d.ts +0 -1
- package/schematics/place-add/index.spec.js +0 -364
- package/schematics/place-add/index.spec.js.map +0 -1
- package/schematics/place-add/schema.d.ts +0 -4
- package/schematics/place-add/schema.js +0 -3
- package/schematics/place-add/schema.js.map +0 -1
- package/schematics/place-add/schema.json +0 -27
- package/schematics/place-add/templates/component/__name@dasherize__.component.html.template +0 -1
- package/schematics/place-add/templates/component/__name@dasherize__.component.scss.template +0 -4
- package/schematics/place-add/templates/component/__name@dasherize__.component.spec.ts.template +0 -25
- package/schematics/place-add/templates/component/__name@dasherize__.component.ts.template +0 -35
- package/schematics/place-add/templates/component/__name@dasherize__.i18n.yml.template +0 -5
- package/schematics/place-bootstrap/index.d.ts +0 -3
- package/schematics/place-bootstrap/index.js +0 -21
- package/schematics/place-bootstrap/index.js.map +0 -1
- package/schematics/place-bootstrap/schema.d.ts +0 -4
- package/schematics/place-bootstrap/schema.js +0 -3
- package/schematics/place-bootstrap/schema.js.map +0 -1
- package/schematics/place-bootstrap/schema.json +0 -28
- package/schematics/place-bootstrap/templates/__name@dasherize__/place-routes.ts.template +0 -3
- package/schematics/place-bootstrap/templates/__name@dasherize__/places.module.ts.template +0 -16
- package/schematics/place-routes/index.d.ts +0 -3
- package/schematics/place-routes/index.js +0 -24
- package/schematics/place-routes/index.js.map +0 -1
- package/schematics/place-routes/place-builder.d.ts +0 -18
- package/schematics/place-routes/place-builder.js +0 -123
- package/schematics/place-routes/place-builder.js.map +0 -1
- package/schematics/place-routes/place-class-scanner.d.ts +0 -47
- package/schematics/place-routes/place-class-scanner.js +0 -223
- package/schematics/place-routes/place-class-scanner.js.map +0 -1
- package/schematics/place-routes/place-def.d.ts +0 -62
- package/schematics/place-routes/place-def.js +0 -195
- package/schematics/place-routes/place-def.js.map +0 -1
- package/schematics/place-routes/schema.d.ts +0 -4
- package/schematics/place-routes/schema.js +0 -3
- package/schematics/place-routes/schema.js.map +0 -1
- package/schematics/place-routes/schema.json +0 -26
- package/schematics/place-routes/templates/place-routes.ts.template +0 -15
- package/schematics/utils/build-context.d.ts +0 -74
- package/schematics/utils/build-context.js +0 -189
- package/schematics/utils/build-context.js.map +0 -1
- package/schematics/utils/decorators/decorated-class.d.ts +0 -13
- package/schematics/utils/decorators/decorated-class.js +0 -28
- package/schematics/utils/decorators/decorated-class.js.map +0 -1
- package/schematics/utils/decorators/decorated-source-file.d.ts +0 -15
- package/schematics/utils/decorators/decorated-source-file.js +0 -27
- package/schematics/utils/decorators/decorated-source-file.js.map +0 -1
- package/schematics/utils/import-def.d.ts +0 -30
- package/schematics/utils/import-def.js +0 -97
- package/schematics/utils/import-def.js.map +0 -1
- package/schematics/utils/method-scanner.d.ts +0 -16
- package/schematics/utils/method-scanner.js +0 -70
- package/schematics/utils/method-scanner.js.map +0 -1
- package/schematics/utils/mixin.d.ts +0 -11
- package/schematics/utils/mixin.js +0 -27
- package/schematics/utils/mixin.js.map +0 -1
- package/schematics/utils/parameter-def.d.ts +0 -5
- package/schematics/utils/parameter-def.js +0 -3
- package/schematics/utils/parameter-def.js.map +0 -1
- package/schematics/utils/path-helper.d.ts +0 -14
- package/schematics/utils/path-helper.js +0 -30
- package/schematics/utils/path-helper.js.map +0 -1
- package/schematics/utils/schematic-tree-file-system.d.ts +0 -30
- package/schematics/utils/schematic-tree-file-system.js +0 -113
- package/schematics/utils/schematic-tree-file-system.js.map +0 -1
- package/schematics/utils/source-file-scanner.d.ts +0 -14
- package/schematics/utils/source-file-scanner.js +0 -89
- package/schematics/utils/source-file-scanner.js.map +0 -1
- package/schematics/utils/source-file-utilities.d.ts +0 -6
- package/schematics/utils/source-file-utilities.js +0 -36
- package/schematics/utils/source-file-utilities.js.map +0 -1
- package/schematics/utils/stringy.d.ts +0 -15
- package/schematics/utils/stringy.js +0 -50
- package/schematics/utils/stringy.js.map +0 -1
- package/schematics/utils/template-utilities.d.ts +0 -2
- package/schematics/utils/template-utilities.js +0 -24
- package/schematics/utils/template-utilities.js.map +0 -1
- package/schematics/utils/workspace.d.ts +0 -15
- package/schematics/utils/workspace.js +0 -59
- package/schematics/utils/workspace.js.map +0 -1
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Rule, SchematicContext, Tree } from '@angular-devkit/schematics';
|
|
2
|
-
import { BuildContext } from '../utils/build-context';
|
|
3
|
-
import { Schema } from './schema';
|
|
4
|
-
export declare class PlaceBuilder {
|
|
5
|
-
readonly options: Schema;
|
|
6
|
-
readonly buildContext: BuildContext.App;
|
|
7
|
-
readonly context: SchematicContext;
|
|
8
|
-
private projectName;
|
|
9
|
-
private projectType;
|
|
10
|
-
private sourceRoot;
|
|
11
|
-
private typescriptProject;
|
|
12
|
-
private tsConfigPath;
|
|
13
|
-
constructor(options: Schema, buildContext: BuildContext.App, context: SchematicContext);
|
|
14
|
-
process(tree: Tree): Rule;
|
|
15
|
-
private renderTemplates;
|
|
16
|
-
private extractPlaceDefinitions;
|
|
17
|
-
private buildPlaceHierarchy;
|
|
18
|
-
}
|
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PlaceBuilder = void 0;
|
|
4
|
-
const core_1 = require("@angular-devkit/core");
|
|
5
|
-
const schematics_1 = require("@angular-devkit/schematics");
|
|
6
|
-
const _ = require("lodash");
|
|
7
|
-
const place_def_1 = require("./place-def");
|
|
8
|
-
// interface Config {
|
|
9
|
-
// authGuard: ClassImport;
|
|
10
|
-
// }
|
|
11
|
-
// interface PlaceRoot {
|
|
12
|
-
// dir: string,
|
|
13
|
-
// }
|
|
14
|
-
const noopRule = (tree, context) => tree;
|
|
15
|
-
class PlaceBuilder {
|
|
16
|
-
constructor(options, buildContext, context) {
|
|
17
|
-
this.options = options;
|
|
18
|
-
this.buildContext = buildContext;
|
|
19
|
-
this.context = context;
|
|
20
|
-
this.projectName = options.project;
|
|
21
|
-
this.sourceRoot = buildContext.sourceCodeRootDir;
|
|
22
|
-
this.context.logger.info(`sourceRoot=${this.sourceRoot}`);
|
|
23
|
-
this.context.logger.info(`projectName=${this.projectName}`);
|
|
24
|
-
}
|
|
25
|
-
process(tree) {
|
|
26
|
-
const placeRoots = [];
|
|
27
|
-
placeRoots.push(this.options.dir); // todo support multiple place roots on a single run.
|
|
28
|
-
const rules = placeRoots.map(r => this.sourceRoot.relativeDir(r)).map(placeRoot => {
|
|
29
|
-
const placeDefs = this.extractPlaceDefinitions(tree, placeRoot);
|
|
30
|
-
if (placeDefs.length < 1) {
|
|
31
|
-
this.context.logger.info(`No places found in ${placeRoot.treePath}`);
|
|
32
|
-
return noopRule;
|
|
33
|
-
}
|
|
34
|
-
else {
|
|
35
|
-
// TODO: doesn't handle namespaces
|
|
36
|
-
const visitParameterImports = _.uniqBy(_.flatMap(placeDefs, def => def.getVisitParameterImports()), "typeName")
|
|
37
|
-
.map(def => {
|
|
38
|
-
return {
|
|
39
|
-
typeName: def.typeName,
|
|
40
|
-
importPath: def.importPathFor(placeRoot)
|
|
41
|
-
};
|
|
42
|
-
});
|
|
43
|
-
return this.renderTemplates(placeRoot, placeDefs, visitParameterImports, tree);
|
|
44
|
-
}
|
|
45
|
-
});
|
|
46
|
-
return (0, schematics_1.chain)(rules);
|
|
47
|
-
}
|
|
48
|
-
renderTemplates(placeRoot, placeDefs, visitParameterImports, tree) {
|
|
49
|
-
// this.context.logger.info(`${this.workspaceProject.sourceRoot}/${this.projectType}`);
|
|
50
|
-
// this.context.logger.info(placeRoot.dir);
|
|
51
|
-
const files = (0, schematics_1.apply)((0, schematics_1.url)('./templates'), [
|
|
52
|
-
(0, schematics_1.applyTemplates)(Object.assign(Object.assign(Object.assign({}, this.options), { placeDefs,
|
|
53
|
-
visitParameterImports }), core_1.strings)),
|
|
54
|
-
(0, schematics_1.move)(`${placeRoot.treePath}`),
|
|
55
|
-
// @see https://github.com/angular/angular-cli/issues/11337#issuecomment-448259549
|
|
56
|
-
(0, schematics_1.forEach)((fileEntry) => {
|
|
57
|
-
this.context.logger.info(fileEntry.path);
|
|
58
|
-
if (tree.exists(fileEntry.path)) {
|
|
59
|
-
tree.overwrite(fileEntry.path, fileEntry.content);
|
|
60
|
-
}
|
|
61
|
-
return fileEntry;
|
|
62
|
-
})
|
|
63
|
-
]);
|
|
64
|
-
return (0, schematics_1.mergeWith)(files);
|
|
65
|
-
}
|
|
66
|
-
// private parseConfig(configString: string): Config {
|
|
67
|
-
// const rawConfig = JSON5.parse(configString);
|
|
68
|
-
// const config:Config = {
|
|
69
|
-
// authGuard: {
|
|
70
|
-
// className: 'NoopAuthGuard', importPath: '@coolon/angular-ui-powerups', ...rawConfig.authGuard
|
|
71
|
-
// }
|
|
72
|
-
// };
|
|
73
|
-
// this.context.logger.info(`config: ${JSON5.stringify(config)}`);
|
|
74
|
-
// return config;
|
|
75
|
-
// }
|
|
76
|
-
extractPlaceDefinitions(tree, placeRootPath) {
|
|
77
|
-
const placeDefs = [];
|
|
78
|
-
this.context.logger.info(`Scanning sources in -> ${placeRootPath.treePath}`);
|
|
79
|
-
const placeRootDir = tree.getDir(placeRootPath.treePath);
|
|
80
|
-
placeRootDir.visit(filePath => {
|
|
81
|
-
if (!filePath.endsWith('.ts') || filePath.endsWith('.spec.ts')) {
|
|
82
|
-
return;
|
|
83
|
-
}
|
|
84
|
-
const content = tree.read(filePath);
|
|
85
|
-
if (!content) {
|
|
86
|
-
return;
|
|
87
|
-
}
|
|
88
|
-
const sourceFile = this.buildContext.getSourceFile(`./${filePath}`);
|
|
89
|
-
if (!sourceFile) {
|
|
90
|
-
throw new Error(`${filePath} is not included by ${this.tsConfigPath}. Until I fix this properly you can add an '"include": ["src/app/**/*.ts", "src/app/**/*.d.ts"], "exclude":["**/*.spec.*"]' `);
|
|
91
|
-
}
|
|
92
|
-
else {
|
|
93
|
-
const imports = sourceFile.getImportDeclarations();
|
|
94
|
-
sourceFile.getClasses().forEach((classDecl) => {
|
|
95
|
-
place_def_1.PlaceDef.scan(sourceFile, classDecl, this.context).onMatch(result => {
|
|
96
|
-
const moduleImportPath = `.${filePath.substr(placeRootDir.path.length, filePath.length - placeRootDir.path.length - '.ts'.length)}`;
|
|
97
|
-
const definition = result.createDefinition(moduleImportPath);
|
|
98
|
-
this.context.logger.info(`${classDecl.getName()}(route: /${definition.fullPath}) -> ${moduleImportPath}`);
|
|
99
|
-
placeDefs.push(definition);
|
|
100
|
-
});
|
|
101
|
-
});
|
|
102
|
-
}
|
|
103
|
-
});
|
|
104
|
-
const rootPlaces = this.buildPlaceHierarchy(placeDefs);
|
|
105
|
-
return placeDefs;
|
|
106
|
-
}
|
|
107
|
-
buildPlaceHierarchy(placeDefs) {
|
|
108
|
-
const parentPlaces = placeDefs.filter(d => d.childRefs.length > 0);
|
|
109
|
-
const childPlaces = [];
|
|
110
|
-
parentPlaces.forEach(p => {
|
|
111
|
-
p.childRefs.forEach(c => {
|
|
112
|
-
const childPlaceDef = c.resolve(placeDefs);
|
|
113
|
-
if (!childPlaceDef) {
|
|
114
|
-
throw new Error(`${p.componentClass} references child ${c.componentClass} which isn't a @Place`);
|
|
115
|
-
}
|
|
116
|
-
childPlaces.push(childPlaceDef);
|
|
117
|
-
childPlaceDef.setParent(p);
|
|
118
|
-
});
|
|
119
|
-
});
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
exports.PlaceBuilder = PlaceBuilder;
|
|
123
|
-
//# sourceMappingURL=place-builder.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"place-builder.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/schematics/place-routes/place-builder.ts"],"names":[],"mappings":";;;AAAA,+CAA6C;AAC7C,2DAYoC;AACpC,4BAA4B;AAG5B,2CAAqC;AAQrC,qBAAqB;AACrB,4BAA4B;AAC5B,IAAI;AAEJ,wBAAwB;AACxB,iBAA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CACF;AAjID,oCAiIC"}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { SchematicContext } from '@angular-devkit/schematics';
|
|
2
|
-
import { ClassDeclaration, Decorator, ObjectLiteralExpression, PropertyDeclaration } from 'ts-morph';
|
|
3
|
-
import { DecoratedSourceFile } from '../utils/decorators/decorated-source-file';
|
|
4
|
-
import { ImportDef } from "../utils/import-def";
|
|
5
|
-
import { PlaceDef } from './place-def';
|
|
6
|
-
export declare class PlaceClassScanner {
|
|
7
|
-
private readonly sourceFile;
|
|
8
|
-
private readonly classDecl;
|
|
9
|
-
readonly context: SchematicContext;
|
|
10
|
-
private placeAnnotation;
|
|
11
|
-
constructor(sourceFile: DecoratedSourceFile, classDecl: ClassDeclaration, context: SchematicContext);
|
|
12
|
-
isPlace(): boolean;
|
|
13
|
-
onMatch(callback: (scan: PlaceClassScanner) => void): void;
|
|
14
|
-
createDefinition(moduleImportPath: string): PlaceDef;
|
|
15
|
-
protected getPlaceOptions(): PlaceDef.Options;
|
|
16
|
-
protected getChildren(): PlaceDef.ChildRef[];
|
|
17
|
-
protected getDefaultChild(): string;
|
|
18
|
-
protected getRedirectToFirstChild(): boolean;
|
|
19
|
-
getChildRefFor(componentClassName: string): PlaceDef.ChildRef;
|
|
20
|
-
private extractChildComponentClassNames;
|
|
21
|
-
protected getRouteIdParameter(): PlaceClassScanner.RouteParameterInfo;
|
|
22
|
-
protected getRouteParameters(): PlaceDef.Parameter[];
|
|
23
|
-
private getVisitValueParameters;
|
|
24
|
-
private getVisitListParameters;
|
|
25
|
-
protected getDecoratedProperties(annotation: string): {
|
|
26
|
-
decorator: Decorator;
|
|
27
|
-
property: PropertyDeclaration;
|
|
28
|
-
}[];
|
|
29
|
-
}
|
|
30
|
-
export declare namespace PlaceClassScanner {
|
|
31
|
-
function getObjectLiteralArgument(annotation: Decorator, position: number): ObjectLiteralExpression;
|
|
32
|
-
function getOptionsArg<T extends {}>(annotation: Decorator, defaults: T, options?: {
|
|
33
|
-
position: number;
|
|
34
|
-
required: boolean;
|
|
35
|
-
}): T;
|
|
36
|
-
class RouteParameterInfo implements PlaceDef.Parameter {
|
|
37
|
-
private readonly as;
|
|
38
|
-
readonly optional: boolean;
|
|
39
|
-
readonly property: PropertyDeclaration;
|
|
40
|
-
readonly array: boolean;
|
|
41
|
-
readonly parameterType: string;
|
|
42
|
-
readonly importDef: ImportDef | undefined;
|
|
43
|
-
constructor(as: string, optional: boolean, property: PropertyDeclaration, sourceFile: DecoratedSourceFile);
|
|
44
|
-
get parameterName(): string;
|
|
45
|
-
get modelName(): string;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
@@ -1,223 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.PlaceClassScanner = void 0;
|
|
13
|
-
const fast_memoize_decorator_1 = require("@typescript-plus/fast-memoize-decorator");
|
|
14
|
-
const lodash_1 = require("lodash");
|
|
15
|
-
const ts_morph_1 = require("ts-morph");
|
|
16
|
-
const import_def_1 = require("../utils/import-def");
|
|
17
|
-
const place_def_1 = require("./place-def");
|
|
18
|
-
function isDecoratorNode(node, name) {
|
|
19
|
-
return node.getKind() === ts_morph_1.SyntaxKind.Decorator && node.getText().startsWith(`${name}(`); // NOTE: I'm only supporting the @Decorator(...) style of usage (i.e. decorator factories).
|
|
20
|
-
}
|
|
21
|
-
const ROUTE_PROPERTY_REGEX = /.*(ListModel|ValueModel)<(.*)>/;
|
|
22
|
-
// @See https://astexplorer.net/
|
|
23
|
-
class PlaceClassScanner {
|
|
24
|
-
constructor(sourceFile, classDecl, context) {
|
|
25
|
-
this.sourceFile = sourceFile;
|
|
26
|
-
this.classDecl = classDecl;
|
|
27
|
-
this.context = context;
|
|
28
|
-
// @ts-ignore
|
|
29
|
-
classDecl.forEachChild((node) => {
|
|
30
|
-
if (isDecoratorNode(node, '@Place')) {
|
|
31
|
-
this.placeAnnotation = node;
|
|
32
|
-
// stop iterating when the node is a class declaration
|
|
33
|
-
return true;
|
|
34
|
-
}
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
isPlace() {
|
|
38
|
-
return !!this.placeAnnotation;
|
|
39
|
-
}
|
|
40
|
-
onMatch(callback) {
|
|
41
|
-
if (this.isPlace()) {
|
|
42
|
-
callback(this);
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
createDefinition(moduleImportPath) {
|
|
46
|
-
return new place_def_1.PlaceDef(this.sourceFile.getFilePath(), moduleImportPath, this.classDecl.getName(), this.getPlaceOptions(), this.getRouteIdParameter(), this.getRouteParameters(), this.getChildren(), this.getDefaultChild(), this.getRedirectToFirstChild());
|
|
47
|
-
}
|
|
48
|
-
getPlaceOptions() {
|
|
49
|
-
// const args = this.placeAnnotation.getArguments();
|
|
50
|
-
// if (args.length !== 1) {
|
|
51
|
-
// console.error('@Place() accepts a single Options argument. got', args);
|
|
52
|
-
// }
|
|
53
|
-
return PlaceClassScanner.getOptionsArg(this.placeAnnotation, {
|
|
54
|
-
title: '',
|
|
55
|
-
path: '',
|
|
56
|
-
data: null,
|
|
57
|
-
authenticate: 'true',
|
|
58
|
-
roles: [],
|
|
59
|
-
redirectToFirstChild: false
|
|
60
|
-
}, {
|
|
61
|
-
position: 0,
|
|
62
|
-
required: true
|
|
63
|
-
});
|
|
64
|
-
}
|
|
65
|
-
getChildren() {
|
|
66
|
-
const literal = PlaceClassScanner.getObjectLiteralArgument(this.placeAnnotation, 0);
|
|
67
|
-
const children = literal.getProperty('children');
|
|
68
|
-
if (children) {
|
|
69
|
-
const initialiser = children.getStructure().initializer;
|
|
70
|
-
const componentClassNames = this.extractChildComponentClassNames(initialiser);
|
|
71
|
-
// FIXME: Check for duplicates
|
|
72
|
-
return componentClassNames.map(componentClassName => this.getChildRefFor(componentClassName));
|
|
73
|
-
}
|
|
74
|
-
else {
|
|
75
|
-
return [];
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
getDefaultChild() {
|
|
79
|
-
const literal = PlaceClassScanner.getObjectLiteralArgument(this.placeAnnotation, 0);
|
|
80
|
-
const defaultChild = literal.getProperty('defaultChild');
|
|
81
|
-
return defaultChild ? defaultChild.getStructure().initializer : null;
|
|
82
|
-
}
|
|
83
|
-
getRedirectToFirstChild() {
|
|
84
|
-
const literal = PlaceClassScanner.getObjectLiteralArgument(this.placeAnnotation, 0);
|
|
85
|
-
const redirect = literal.getProperty('redirectToFirstChild');
|
|
86
|
-
return redirect ? redirect.getStructure().initializer === 'true' : false;
|
|
87
|
-
}
|
|
88
|
-
getChildRefFor(componentClassName) {
|
|
89
|
-
const importDecl = this.sourceFile.getImportDeclarations().find(d => {
|
|
90
|
-
return d.getNamedImports().map(i => i.getText()).includes(componentClassName);
|
|
91
|
-
});
|
|
92
|
-
return new place_def_1.PlaceDef.ChildRef(importDecl.getModuleSpecifierSourceFile().getFilePath(), componentClassName);
|
|
93
|
-
}
|
|
94
|
-
extractChildComponentClassNames(initialiser) {
|
|
95
|
-
return initialiser.replace('[', '')
|
|
96
|
-
.replace(']', '')
|
|
97
|
-
.trim()
|
|
98
|
-
.split(',')
|
|
99
|
-
.map(s => s.trim())
|
|
100
|
-
.filter(s => !(0, lodash_1.isEmpty)(s)); // trailing commas on the last place in the list give us an empty string.
|
|
101
|
-
}
|
|
102
|
-
getRouteIdParameter() {
|
|
103
|
-
const routeProperties = this.getDecoratedProperties('@RouteId');
|
|
104
|
-
if (routeProperties.length === 1) {
|
|
105
|
-
const route = routeProperties[0];
|
|
106
|
-
const routeOptions = PlaceClassScanner.getOptionsArg(route.decorator, { as: '', optional: false }, {
|
|
107
|
-
position: 1,
|
|
108
|
-
required: false
|
|
109
|
-
});
|
|
110
|
-
return new PlaceClassScanner.RouteParameterInfo(routeOptions.as, routeOptions.optional, route.property, this.sourceFile);
|
|
111
|
-
}
|
|
112
|
-
else if (routeProperties.length > 1) {
|
|
113
|
-
this.context.logger.error(`There an only be one @RouteId(), got ${routeProperties.length}`);
|
|
114
|
-
}
|
|
115
|
-
return null;
|
|
116
|
-
}
|
|
117
|
-
getRouteParameters() {
|
|
118
|
-
return this.getVisitValueParameters().concat(this.getVisitListParameters());
|
|
119
|
-
}
|
|
120
|
-
getVisitValueParameters() {
|
|
121
|
-
return this.getDecoratedProperties('@VisitParameter')
|
|
122
|
-
.map(p => {
|
|
123
|
-
const routeOptions = PlaceClassScanner.getOptionsArg(p.decorator, { as: p.property.getName() }, {
|
|
124
|
-
position: 0,
|
|
125
|
-
required: false
|
|
126
|
-
});
|
|
127
|
-
return new PlaceClassScanner.RouteParameterInfo(routeOptions.as, true, p.property, this.sourceFile);
|
|
128
|
-
});
|
|
129
|
-
}
|
|
130
|
-
getVisitListParameters() {
|
|
131
|
-
return this.getDecoratedProperties('@VisitParameterList')
|
|
132
|
-
.map(p => {
|
|
133
|
-
const routeOptions = PlaceClassScanner.getOptionsArg(p.decorator, { as: p.property.getName() }, {
|
|
134
|
-
position: 0,
|
|
135
|
-
required: false
|
|
136
|
-
});
|
|
137
|
-
return new PlaceClassScanner.RouteParameterInfo(routeOptions.as, true, p.property, this.sourceFile);
|
|
138
|
-
});
|
|
139
|
-
}
|
|
140
|
-
getDecoratedProperties(annotation) {
|
|
141
|
-
return this.classDecl.getProperties().map(p => {
|
|
142
|
-
let result = null;
|
|
143
|
-
// @ts-ignore
|
|
144
|
-
p.forEachChild((child) => {
|
|
145
|
-
if (isDecoratorNode(child, annotation)) {
|
|
146
|
-
result = {
|
|
147
|
-
decorator: child,
|
|
148
|
-
property: p
|
|
149
|
-
};
|
|
150
|
-
// stop traversal
|
|
151
|
-
return true;
|
|
152
|
-
}
|
|
153
|
-
});
|
|
154
|
-
return result;
|
|
155
|
-
}).filter(r => !!r);
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
exports.PlaceClassScanner = PlaceClassScanner;
|
|
159
|
-
(function (PlaceClassScanner) {
|
|
160
|
-
function getObjectLiteralArgument(annotation, position) {
|
|
161
|
-
const args = annotation.getArguments();
|
|
162
|
-
if (args.length > position && args[position] instanceof ts_morph_1.ObjectLiteralExpression) {
|
|
163
|
-
return args[position];
|
|
164
|
-
}
|
|
165
|
-
return null;
|
|
166
|
-
}
|
|
167
|
-
PlaceClassScanner.getObjectLiteralArgument = getObjectLiteralArgument;
|
|
168
|
-
function getOptionsArg(annotation, defaults, options = {
|
|
169
|
-
position: 0,
|
|
170
|
-
required: true
|
|
171
|
-
}) {
|
|
172
|
-
const objectLiteralArgument = getObjectLiteralArgument(annotation, options.position);
|
|
173
|
-
if (!objectLiteralArgument) {
|
|
174
|
-
if (options.required) {
|
|
175
|
-
console.error(`expected object literal arg at position ${options.position}`, { expectedType: defaults });
|
|
176
|
-
}
|
|
177
|
-
return defaults;
|
|
178
|
-
}
|
|
179
|
-
else {
|
|
180
|
-
return objectLiteralArgument.getProperties().reduce((result, p) => {
|
|
181
|
-
const structure = p.getStructure();
|
|
182
|
-
return Object.assign(Object.assign({}, result), { [structure.name]: structure.initializer });
|
|
183
|
-
}, Object.assign({}, defaults));
|
|
184
|
-
}
|
|
185
|
-
}
|
|
186
|
-
PlaceClassScanner.getOptionsArg = getOptionsArg;
|
|
187
|
-
class RouteParameterInfo {
|
|
188
|
-
constructor(as, optional, property, sourceFile) {
|
|
189
|
-
this.as = as;
|
|
190
|
-
this.optional = optional;
|
|
191
|
-
this.property = property;
|
|
192
|
-
const type = property.getStructure().type;
|
|
193
|
-
const match = ROUTE_PROPERTY_REGEX.exec(type);
|
|
194
|
-
if (!match) {
|
|
195
|
-
throw new Error(`expected ${property.getName()} to be a ListModel or ValueModel, got: ${type}`);
|
|
196
|
-
}
|
|
197
|
-
this.array = match[1] === 'ListModel';
|
|
198
|
-
this.parameterType = match[2];
|
|
199
|
-
const importDec = sourceFile.getImportDeclarations().find(d => {
|
|
200
|
-
return d.getNamedImports().map(i => i.getText()).includes(this.parameterType);
|
|
201
|
-
});
|
|
202
|
-
this.importDef = importDec ? import_def_1.ImportDef.create(this.parameterType, importDec) : undefined;
|
|
203
|
-
}
|
|
204
|
-
get parameterName() {
|
|
205
|
-
return this.as.length > 0 ? place_def_1.PlaceDef.stripEnclosingQuotes(this.as) : this.modelName;
|
|
206
|
-
}
|
|
207
|
-
get modelName() {
|
|
208
|
-
return place_def_1.PlaceDef.stripEnclosingQuotes(this.property.getName());
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
__decorate([
|
|
212
|
-
(0, fast_memoize_decorator_1.Memoize)(),
|
|
213
|
-
__metadata("design:type", String),
|
|
214
|
-
__metadata("design:paramtypes", [])
|
|
215
|
-
], RouteParameterInfo.prototype, "parameterName", null);
|
|
216
|
-
__decorate([
|
|
217
|
-
(0, fast_memoize_decorator_1.Memoize)(),
|
|
218
|
-
__metadata("design:type", String),
|
|
219
|
-
__metadata("design:paramtypes", [])
|
|
220
|
-
], RouteParameterInfo.prototype, "modelName", null);
|
|
221
|
-
PlaceClassScanner.RouteParameterInfo = RouteParameterInfo;
|
|
222
|
-
})(PlaceClassScanner = exports.PlaceClassScanner || (exports.PlaceClassScanner = {}));
|
|
223
|
-
//# sourceMappingURL=place-class-scanner.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"place-class-scanner.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/schematics/place-routes/place-class-scanner.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,oFAAgE;AAChE,mCAA+B;AAC/B,uCAQkB;AAElB,oDAA8C;AAC9C,2CAAqC;AAGrC,SAAS,eAAe,CAAC,IAAU,EAAE,IAAY;IAC/C,OAAO,IAAI,CAAC,OAAO,EAAE,KAAK,qBAAU,CAAC,SAAS,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC,UAAU,CAAC,GAAG,IAAI,GAAG,CAAC,CAAC,CAAC,2FAA2F;AACtL,CAAC;AAED,MAAM,oBAAoB,GAAG,gCAAgC,CAAC;AAE9D,gCAAgC;AAChC,MAAa,iBAAiB;IAI5B,YAA6B,UAA+B,EAAmB,SAA2B,EAAW,OAAyB;QAAjH,eAAU,GAAV,UAAU,CAAqB;QAAmB,cAAS,GAAT,SAAS,CAAkB;QAAW,YAAO,GAAP,OAAO,CAAkB;QAC5I,aAAa;QACb,SAAS,CAAC,YAAY,CAAC,CAAC,IAAI,EAAE,EAAE;YAC9B,IAAI,eAAe,CAAC,IAAI,EAAE,QAAQ,CAAC,EAAE;gBACnC,IAAI,CAAC,eAAe,GAAG,IAAiB,CAAC;gBACzC,sDAAsD;gBACtD,OAAO,IAAI,CAAC;aACb;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IAED,OAAO;QACL,OAAO,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC;IAChC,CAAC;IAED,OAAO,CAAC,QAA2C;QACjD,IAAI,IAAI,CAAC,OAAO,EAAE,EAAE;YAClB,QAAQ,CAAC,IAAI,CAAC,CAAC;SAChB;IACH,CAAC;IAED,gBAAgB,CAAC,gBAAwB;QACvC,OAAO,IAAI,oBAAQ,CACjB,IAAI,CAAC,UAAU,CAAC,WAAW,EAAE,EAC7B,gBAAgB,EAChB,IAAI,CAAC,SAAS,CAAC,OAAO,EAAE,EACxB,IAAI,CAAC,eAAe,EAAE,EACtB,IAAI,CAA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AAjB,yBAAiB,KAAjB,yBAAiB,QA2DjC"}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import { SchematicContext } from '@angular-devkit/schematics';
|
|
2
|
-
import { ClassDeclaration } from 'ts-morph';
|
|
3
|
-
import { DecoratedSourceFile } from '../utils/decorators/decorated-source-file';
|
|
4
|
-
import { ImportDef } from "../utils/import-def";
|
|
5
|
-
import { PlaceClassScanner } from './place-class-scanner';
|
|
6
|
-
export declare class PlaceDef {
|
|
7
|
-
readonly sourceFilePath: string;
|
|
8
|
-
readonly importPath: string;
|
|
9
|
-
readonly componentClass: string;
|
|
10
|
-
readonly properties: PlaceDef.Options;
|
|
11
|
-
readonly routeDef: PlaceDef.Parameter;
|
|
12
|
-
readonly routeParameters: PlaceDef.Parameter[];
|
|
13
|
-
readonly childRefs: PlaceDef.ChildRef[];
|
|
14
|
-
readonly defaultChildComponentClass: string;
|
|
15
|
-
readonly redirectToFirstChild: boolean;
|
|
16
|
-
private parent;
|
|
17
|
-
constructor(sourceFilePath: string, importPath: string, componentClass: string, properties: PlaceDef.Options, routeDef: PlaceDef.Parameter, routeParameters: PlaceDef.Parameter[], childRefs: PlaceDef.ChildRef[], defaultChildComponentClass: string, redirectToFirstChild: boolean);
|
|
18
|
-
get path(): string;
|
|
19
|
-
get routeIdentifier(): PlaceDef.Parameter;
|
|
20
|
-
get fullPath(): string;
|
|
21
|
-
getVisitParameterImports(): ImportDef[];
|
|
22
|
-
getPlaceDestinationParameterArg(name: string): string;
|
|
23
|
-
getPlaceDestinationCreateVisitMethod(): string;
|
|
24
|
-
getPlaceDestinationVisitConstructor(): string;
|
|
25
|
-
get placeName(): string;
|
|
26
|
-
setParent(placeDef: PlaceDef): void;
|
|
27
|
-
isChild(): boolean;
|
|
28
|
-
private requiresRouteGuard;
|
|
29
|
-
get routeModelName(): string;
|
|
30
|
-
get authenticate(): boolean;
|
|
31
|
-
get children(): PlaceDef[];
|
|
32
|
-
getRouteTemplate(): string;
|
|
33
|
-
getChildRouteTemplates(): string[];
|
|
34
|
-
get defaultChildRef(): PlaceDef;
|
|
35
|
-
}
|
|
36
|
-
export declare namespace PlaceDef {
|
|
37
|
-
interface Options {
|
|
38
|
-
path: string;
|
|
39
|
-
data: object;
|
|
40
|
-
authenticate: string;
|
|
41
|
-
roles: string[];
|
|
42
|
-
redirectToFirstChild: boolean;
|
|
43
|
-
}
|
|
44
|
-
interface Parameter {
|
|
45
|
-
parameterName: string;
|
|
46
|
-
modelName: string;
|
|
47
|
-
parameterType: string;
|
|
48
|
-
optional: boolean;
|
|
49
|
-
array: boolean;
|
|
50
|
-
importDef: ImportDef | undefined;
|
|
51
|
-
}
|
|
52
|
-
function scan(sourceFile: DecoratedSourceFile, classDecl: ClassDeclaration, context: SchematicContext): PlaceClassScanner;
|
|
53
|
-
function stripEnclosingQuotes(value: string): string;
|
|
54
|
-
class ChildRef {
|
|
55
|
-
readonly filePath: string;
|
|
56
|
-
readonly componentClass: string;
|
|
57
|
-
private _placeDef;
|
|
58
|
-
constructor(filePath: string, componentClass: string);
|
|
59
|
-
get placeDef(): PlaceDef;
|
|
60
|
-
resolve(placeDefs: PlaceDef[]): PlaceDef;
|
|
61
|
-
}
|
|
62
|
-
}
|