@coolon/angular-ui-powerups 12.4.0-alpha.9 → 12.4.0-alpha.90
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 +80 -0
- package/assets/activities/input-activities.scss +36 -0
- package/assets/cards.scss +17 -0
- package/assets/form.scss +10 -2
- package/assets/forms/mixins.scss +6 -0
- package/assets/interaction/editor/inline-string-editor.scss +54 -0
- package/assets/interaction.scss +10 -7
- package/assets/markdown.scss +10 -0
- package/assets/mixins.scss +5 -7
- package/assets/pills.scss +45 -0
- package/assets/styles.scss +10 -15
- package/bundles/coolon-angular-ui-powerups-cypress.umd.js +741 -336
- package/bundles/coolon-angular-ui-powerups-cypress.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.js +1513 -473
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/cypress/component-builder.d.ts +71 -0
- package/cypress/components/aup-abstract-activity.d.ts +31 -0
- package/cypress/components/aup-abstract-table.d.ts +18 -0
- package/cypress/components/aup-activity.d.ts +9 -0
- package/cypress/components/aup-alert-dialog.d.ts +27 -0
- package/cypress/components/aup-alert.d.ts +9 -0
- package/cypress/components/aup-command-face.d.ts +2 -8
- package/cypress/components/aup-command.d.ts +2 -1
- package/cypress/components/aup-confirm-dialog.d.ts +27 -0
- package/cypress/components/aup-confirm.d.ts +11 -0
- package/cypress/components/aup-empty-state.d.ts +1 -2
- package/cypress/components/aup-input.d.ts +11 -5
- package/cypress/components/aup-modal-activity.d.ts +24 -0
- package/cypress/components/aup-modal-mixin.d.ts +23 -0
- package/cypress/components/aup-table.d.ts +5 -18
- package/cypress/components/aup-tree-table.d.ts +16 -0
- package/cypress/components/button.d.ts +11 -7
- package/cypress/components/form-element-mixin.d.ts +22 -0
- package/cypress/components/mat-checkbox.d.ts +31 -0
- package/cypress/components/popup/aup-abstract-popup-menu.d.ts +15 -0
- package/cypress/components/popup/aup-more-menu.d.ts +5 -0
- package/cypress/components/popup/aup-popup-menu-panel.d.ts +3 -0
- package/cypress/components/popup/aup-popup-menu.d.ts +7 -0
- package/cypress/components/table/aup-table-cell.d.ts +9 -0
- package/cypress/components/table/aup-table-column.d.ts +10 -0
- package/cypress/components/table/aup-table-row.d.ts +17 -0
- package/cypress/components/table/aup-table-selection-cell.d.ts +5 -0
- package/cypress/components/table/aup-table-selection-column.d.ts +5 -0
- package/cypress/coolon-angular-ui-powerups-cypress.metadata.json +1 -1
- package/cypress/element-locator.d.ts +8 -0
- package/cypress/exports.d.ts +24 -4
- package/cypress/package.json +1 -1
- package/cypress/page-builder.d.ts +9 -0
- package/cypress/page-element.d.ts +12 -12
- package/cypress/page.d.ts +8 -34
- package/esm2015/cypress/component-builder.js +92 -0
- package/esm2015/cypress/component-builder.js.map +1 -0
- package/esm2015/cypress/component-builder.metadata.json +1 -0
- package/esm2015/cypress/components/aup-abstract-activity.js +12 -0
- package/esm2015/cypress/components/aup-abstract-activity.js.map +1 -0
- package/esm2015/cypress/components/aup-abstract-activity.metadata.json +1 -0
- package/esm2015/cypress/components/aup-abstract-table.js +50 -0
- package/esm2015/cypress/components/aup-abstract-table.js.map +1 -0
- package/esm2015/cypress/components/aup-abstract-table.metadata.json +1 -0
- package/esm2015/cypress/components/aup-activity.js +13 -0
- package/esm2015/cypress/components/aup-activity.js.map +1 -0
- package/esm2015/cypress/components/aup-activity.metadata.json +1 -0
- package/esm2015/cypress/components/aup-alert-dialog.js +8 -0
- package/esm2015/cypress/components/aup-alert-dialog.js.map +1 -0
- package/esm2015/cypress/components/aup-alert-dialog.metadata.json +1 -0
- package/esm2015/cypress/components/aup-alert.js +13 -0
- package/esm2015/cypress/components/aup-alert.js.map +1 -0
- package/esm2015/cypress/components/aup-alert.metadata.json +1 -0
- package/esm2015/cypress/components/aup-command-face.js +11 -22
- package/esm2015/cypress/components/aup-command-face.js.map +1 -1
- package/esm2015/cypress/components/aup-command-face.metadata.json +1 -1
- package/esm2015/cypress/components/aup-command.js +12 -6
- package/esm2015/cypress/components/aup-command.js.map +1 -1
- package/esm2015/cypress/components/aup-command.metadata.json +1 -1
- package/esm2015/cypress/components/aup-confirm-dialog.js +8 -0
- package/esm2015/cypress/components/aup-confirm-dialog.js.map +1 -0
- package/esm2015/cypress/components/aup-confirm-dialog.metadata.json +1 -0
- package/esm2015/cypress/components/aup-confirm.js +19 -0
- package/esm2015/cypress/components/aup-confirm.js.map +1 -0
- package/esm2015/cypress/components/aup-confirm.metadata.json +1 -0
- package/esm2015/cypress/components/aup-empty-state.js +2 -2
- package/esm2015/cypress/components/aup-empty-state.js.map +1 -1
- package/esm2015/cypress/components/aup-empty-state.metadata.json +1 -1
- package/esm2015/cypress/components/aup-input.js +17 -5
- package/esm2015/cypress/components/aup-input.js.map +1 -1
- package/esm2015/cypress/components/aup-input.metadata.json +1 -1
- package/esm2015/cypress/components/aup-modal-activity.js +5 -0
- package/esm2015/cypress/components/aup-modal-activity.js.map +1 -0
- package/esm2015/cypress/components/aup-modal-activity.metadata.json +1 -0
- package/esm2015/cypress/components/aup-modal-mixin.js +18 -0
- package/esm2015/cypress/components/aup-modal-mixin.js.map +1 -0
- package/esm2015/cypress/components/aup-modal-mixin.metadata.json +1 -0
- package/esm2015/cypress/components/aup-navigation.js +1 -1
- package/esm2015/cypress/components/aup-navigation.js.map +1 -1
- package/esm2015/cypress/components/aup-table.js +5 -33
- package/esm2015/cypress/components/aup-table.js.map +1 -1
- package/esm2015/cypress/components/aup-table.metadata.json +1 -1
- package/esm2015/cypress/components/aup-tree-table.js +34 -0
- package/esm2015/cypress/components/aup-tree-table.js.map +1 -0
- package/esm2015/cypress/components/aup-tree-table.metadata.json +1 -0
- package/esm2015/cypress/components/button.js +4 -10
- package/esm2015/cypress/components/button.js.map +1 -1
- package/esm2015/cypress/components/button.metadata.json +1 -1
- package/esm2015/cypress/components/form-element-mixin.js +11 -0
- package/esm2015/cypress/components/form-element-mixin.js.map +1 -0
- package/esm2015/cypress/components/form-element-mixin.metadata.json +1 -0
- package/esm2015/cypress/components/mat-checkbox.js +34 -0
- package/esm2015/cypress/components/mat-checkbox.js.map +1 -0
- package/esm2015/cypress/components/mat-checkbox.metadata.json +1 -0
- package/esm2015/cypress/components/popup/aup-abstract-popup-menu.js +33 -0
- package/esm2015/cypress/components/popup/aup-abstract-popup-menu.js.map +1 -0
- package/esm2015/cypress/components/popup/aup-abstract-popup-menu.metadata.json +1 -0
- package/esm2015/cypress/components/popup/aup-more-menu.js +8 -0
- package/esm2015/cypress/components/popup/aup-more-menu.js.map +1 -0
- package/esm2015/cypress/components/popup/aup-more-menu.metadata.json +1 -0
- package/esm2015/cypress/components/popup/aup-popup-menu-panel.js +4 -0
- package/esm2015/cypress/components/popup/aup-popup-menu-panel.js.map +1 -0
- package/esm2015/cypress/components/popup/aup-popup-menu-panel.metadata.json +1 -0
- package/esm2015/cypress/components/popup/aup-popup-menu.js +12 -0
- package/esm2015/cypress/components/popup/aup-popup-menu.js.map +1 -0
- package/esm2015/cypress/components/popup/aup-popup-menu.metadata.json +1 -0
- package/esm2015/cypress/components/table/aup-table-cell.js +14 -0
- package/esm2015/cypress/components/table/aup-table-cell.js.map +1 -0
- package/esm2015/cypress/components/table/aup-table-cell.metadata.json +1 -0
- package/esm2015/cypress/components/table/aup-table-column.js +19 -0
- package/esm2015/cypress/components/table/aup-table-column.js.map +1 -0
- package/esm2015/cypress/components/table/aup-table-column.metadata.json +1 -0
- package/esm2015/cypress/components/table/aup-table-row.js +28 -0
- package/esm2015/cypress/components/table/aup-table-row.js.map +1 -0
- package/esm2015/cypress/components/table/aup-table-row.metadata.json +1 -0
- package/esm2015/cypress/components/table/aup-table-selection-cell.js +6 -0
- package/esm2015/cypress/components/table/aup-table-selection-cell.js.map +1 -0
- package/esm2015/cypress/components/table/aup-table-selection-cell.metadata.json +1 -0
- package/esm2015/cypress/components/table/aup-table-selection-column.js +6 -0
- package/esm2015/cypress/components/table/aup-table-selection-column.js.map +1 -0
- package/esm2015/cypress/components/table/aup-table-selection-column.metadata.json +1 -0
- package/esm2015/cypress/element-locator.js +16 -0
- package/esm2015/cypress/element-locator.js.map +1 -0
- package/esm2015/cypress/element-locator.metadata.json +1 -0
- package/esm2015/cypress/exports.js +24 -4
- package/esm2015/cypress/exports.js.map +1 -1
- package/esm2015/cypress/exports.metadata.json +1 -1
- package/esm2015/cypress/page-builder.js +16 -0
- package/esm2015/cypress/page-builder.js.map +1 -0
- package/esm2015/cypress/page-builder.metadata.json +1 -0
- package/esm2015/cypress/page-element.js +26 -19
- package/esm2015/cypress/page-element.js.map +1 -1
- package/esm2015/cypress/page-element.metadata.json +1 -1
- package/esm2015/cypress/page.js +31 -19
- package/esm2015/cypress/page.js.map +1 -1
- package/esm2015/cypress/page.metadata.json +1 -1
- package/esm2015/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/busy-overlay/busy-overlay.component.js +1 -1
- package/esm2015/lib/components/busy-overlay/busy-overlay.component.metadata.json +1 -1
- package/esm2015/lib/components/cards/abstract-card-container.component.js +29 -0
- package/esm2015/lib/components/cards/abstract-card-container.component.js.map +1 -0
- package/esm2015/lib/components/cards/abstract-card-container.component.metadata.json +1 -0
- package/esm2015/lib/components/cards/abstract-card-container.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/cards/card-container/card-container.component.js +123 -0
- package/esm2015/lib/components/cards/card-container/card-container.component.js.map +1 -0
- package/esm2015/lib/components/cards/card-container/card-container.component.metadata.json +1 -0
- package/esm2015/lib/components/cards/card-container/card-container.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/cards/card-container/card-container.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/cards/card-stack/card-stack.component.js +78 -0
- package/esm2015/lib/components/cards/card-stack/card-stack.component.js.map +1 -0
- package/esm2015/lib/components/cards/card-stack/card-stack.component.metadata.json +1 -0
- package/esm2015/lib/components/cards/card-stack/card-stack.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/cards/card-stack/card-stack.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/commands/command/command.component.js +1 -1
- package/esm2015/lib/components/commands/command/command.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/command-face/command-face.component.js +5 -1
- package/esm2015/lib/components/commands/command-face/command-face.component.js.map +1 -1
- package/esm2015/lib/components/commands/command-face/command-face.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.js +1 -1
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.js.map +1 -1
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.js +1 -1
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.js.map +1 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.js +1 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.metadata.json +1 -1
- package/esm2015/lib/components/components.module.js +43 -25
- package/esm2015/lib/components/components.module.js.map +1 -1
- package/esm2015/lib/components/components.module.metadata.json +1 -1
- package/esm2015/lib/components/components.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/empty-state/empty-state.component.js +1 -1
- package/esm2015/lib/components/empty-state/empty-state.component.metadata.json +1 -1
- package/esm2015/lib/components/exports.js +8 -4
- package/esm2015/lib/components/exports.js.map +1 -1
- package/esm2015/lib/components/exports.metadata.json +1 -1
- package/esm2015/lib/components/focus-container/focus-container.component.js +1 -1
- package/esm2015/lib/components/focus-container/focus-container.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/abstract-input.component.js +1 -0
- package/esm2015/lib/components/forms/abstract-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/autocomplete-input/autocomplete-input.component.js +2 -2
- package/esm2015/lib/components/forms/autocomplete-input/autocomplete-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/autocomplete-input/autocomplete-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/checkbox-input/checkbox-input.component.js +1 -1
- package/esm2015/lib/components/forms/checkbox-input/checkbox-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/multiple-select-input/multiple-select-input.component.js +2 -2
- package/esm2015/lib/components/forms/multiple-select-input/multiple-select-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/multiple-select-input/multiple-select-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/select-input/select-input.component.js +2 -2
- package/esm2015/lib/components/forms/select-input/select-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/select-input/select-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/string-input/string-input.component.js +1 -1
- package/esm2015/lib/components/forms/string-input/string-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/text-input/text-input.component.js +1 -1
- package/esm2015/lib/components/forms/text-input/text-input.component.metadata.json +1 -1
- package/esm2015/lib/components/icon/icon.component.js +1 -1
- package/esm2015/lib/components/icon/icon.component.metadata.json +1 -1
- package/esm2015/lib/components/labelled-value/labelled-value.component.js +22 -0
- package/esm2015/lib/components/labelled-value/labelled-value.component.js.map +1 -0
- package/esm2015/lib/components/labelled-value/labelled-value.component.metadata.json +1 -0
- package/esm2015/lib/components/labelled-value/labelled-value.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/{card-container/card-container.component.scss.shim.ngstyle.js.map → labelled-value/labelled-value.component.scss.shim.ngstyle.js.map} +1 -1
- package/esm2015/lib/components/loading-container/loading-container.component.js +45 -0
- package/esm2015/lib/components/loading-container/loading-container.component.js.map +1 -0
- package/esm2015/lib/components/loading-container/loading-container.component.metadata.json +1 -0
- package/esm2015/lib/components/loading-container/loading-container.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/loading-container/loading-container.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/noop/noop.component.js +1 -1
- package/esm2015/lib/components/noop/noop.component.metadata.json +1 -1
- package/esm2015/lib/components/scroll-container/scroll-container.component.js +1 -1
- package/esm2015/lib/components/scroll-container/scroll-container.component.metadata.json +1 -1
- package/esm2015/lib/components/section-header/section-header.component.js +12 -5
- package/esm2015/lib/components/section-header/section-header.component.js.map +1 -1
- package/esm2015/lib/components/section-header/section-header.component.metadata.json +1 -1
- package/esm2015/lib/components/switch-case/switch-case.component.js +1 -1
- package/esm2015/lib/components/switch-case/switch-case.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/abstract-table-model.js +34 -20
- package/esm2015/lib/components/tables/abstract-table-model.js.map +1 -1
- package/esm2015/lib/components/tables/abstract-table-model.metadata.json +1 -1
- package/esm2015/lib/components/tables/column-list-model.js +2 -1
- package/esm2015/lib/components/tables/column-list-model.js.map +1 -1
- package/esm2015/lib/components/tables/edit-session.js.map +1 -0
- package/esm2015/lib/components/tables/{table/edit-session.metadata.json → edit-session.metadata.json} +1 -1
- package/esm2015/lib/components/tables/table/cell-portal-ref.js.map +1 -1
- package/esm2015/lib/components/tables/table/cell-renderer.js.map +1 -1
- package/esm2015/lib/components/tables/table/column-model.js +35 -10
- package/esm2015/lib/components/tables/table/column-model.js.map +1 -1
- package/esm2015/lib/components/tables/table/column-model.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/default-cell-renderer/default-cell-renderer.component.js.map +1 -1
- package/esm2015/lib/components/tables/table/default-cell-renderer/default-cell-renderer.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/edit-row-controls/edit-row-controls.component.js +19 -12
- package/esm2015/lib/components/tables/table/edit-row-controls/edit-row-controls.component.js.map +1 -1
- package/esm2015/lib/components/tables/table/edit-row-controls/edit-row-controls.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/paginator/paginator.component.js +1 -1
- package/esm2015/lib/components/tables/table/paginator/paginator.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/table-cell-renderer/table-cell-renderer.component.js +1 -1
- package/esm2015/lib/components/tables/table/table-cell-renderer/table-cell-renderer.component.js.map +1 -1
- package/esm2015/lib/components/tables/table/table-header-cell-renderer/table-header-cell-renderer.component.js +1 -1
- package/esm2015/lib/components/tables/table/table-header-cell-renderer/table-header-cell-renderer.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/table-row-menu/table-row-menu.component.js +0 -2
- package/esm2015/lib/components/tables/table/table-row-menu/table-row-menu.component.js.map +1 -1
- package/esm2015/lib/components/tables/table/table-row-menu/table-row-menu.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/table.component.js +14 -13
- package/esm2015/lib/components/tables/table/table.component.js.map +1 -1
- package/esm2015/lib/components/tables/table/table.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/text-search-predicate.js +2 -0
- package/esm2015/lib/components/tables/table/text-search-predicate.js.map +1 -0
- package/esm2015/lib/components/tables/table/text-search-predicate.metadata.json +1 -0
- package/esm2015/lib/components/tables/tree-table/flattened-tree-list-model.js +4 -4
- package/esm2015/lib/components/tables/tree-table/flattened-tree-list-model.js.map +1 -1
- package/esm2015/lib/components/tables/tree-table/flattened-tree-list-model.metadata.json +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.js +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.js +21 -13
- package/esm2015/lib/components/tables/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.js.map +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-label-column-model.js +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-label-column-model.js.map +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-label-column-model.metadata.json +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-component.js +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-component.js.map +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-component.metadata.json +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-model.js +3 -2
- package/esm2015/lib/components/tables/tree-table/tree-table-model.js.map +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-model.metadata.json +1 -1
- package/esm2015/lib/components/text/markdown/markdown.component.js +77 -0
- package/esm2015/lib/components/text/markdown/markdown.component.js.map +1 -0
- package/esm2015/lib/components/text/markdown/markdown.component.metadata.json +1 -0
- package/esm2015/lib/components/text/markdown/markdown.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/text/markdown/markdown.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/track-by.js +12 -0
- package/esm2015/lib/components/track-by.js.map +1 -1
- package/esm2015/lib/components/vertical-focus-container/vertical-focus-container.component.js +1 -1
- package/esm2015/lib/components/vertical-focus-container/vertical-focus-container.component.metadata.json +1 -1
- package/esm2015/lib/directives/command.directive.js +1 -1
- package/esm2015/lib/directives/command.directive.js.map +1 -1
- package/esm2015/lib/directives/directives.module.ngfactory.js.map +1 -1
- package/esm2015/lib/interaction/abstract-interaction-context.js +7 -0
- package/esm2015/lib/interaction/abstract-interaction-context.js.map +1 -1
- package/esm2015/lib/interaction/abstract-interaction-context.metadata.json +1 -1
- package/esm2015/lib/interaction/activity.js +2 -1
- package/esm2015/lib/interaction/activity.js.map +1 -1
- package/esm2015/lib/interaction/alert.js +17 -1
- package/esm2015/lib/interaction/alert.js.map +1 -1
- package/esm2015/lib/interaction/components/abstract-confirm-dialog.component.js +23 -0
- package/esm2015/lib/interaction/components/abstract-confirm-dialog.component.js.map +1 -0
- package/esm2015/lib/interaction/components/abstract-confirm-dialog.component.metadata.json +1 -0
- package/esm2015/lib/interaction/components/abstract-confirm-dialog.component.ngfactory.js.map +1 -0
- package/esm2015/lib/interaction/components/abstract-dialog.component.js +52 -0
- package/esm2015/lib/interaction/components/abstract-dialog.component.js.map +1 -0
- package/esm2015/lib/interaction/components/abstract-dialog.component.metadata.json +1 -0
- package/esm2015/lib/interaction/components/abstract-dialog.component.ngfactory.js.map +1 -0
- package/esm2015/lib/interaction/components/activity-actions/activity-actions.component.js +17 -11
- package/esm2015/lib/interaction/components/activity-actions/activity-actions.component.js.map +1 -1
- package/esm2015/lib/interaction/components/activity-actions/activity-actions.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-container/activity-container.component.js +3 -3
- package/esm2015/lib/interaction/components/activity-container/activity-container.component.js.map +1 -1
- package/esm2015/lib/interaction/components/activity-container/activity-container.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.js +1 -1
- package/esm2015/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-title/activity-title.component.js +1 -1
- package/esm2015/lib/interaction/components/activity-title/activity-title.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/abstract-activity-trigger.component.js +4 -0
- package/esm2015/lib/interaction/components/activity-triggers/abstract-activity-trigger.component.js.map +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/abstract-activity-trigger.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/inline-activity-trigger/inline-activity-trigger.component.js +5 -2
- package/esm2015/lib/interaction/components/activity-triggers/inline-activity-trigger/inline-activity-trigger.component.js.map +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/inline-activity-trigger/inline-activity-trigger.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/modal-activity-trigger/modal-activity-trigger.component.js +5 -2
- package/esm2015/lib/interaction/components/activity-triggers/modal-activity-trigger/modal-activity-trigger.component.js.map +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/modal-activity-trigger/modal-activity-trigger.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/popup-activity-trigger/popup-activity-trigger.component.js +5 -2
- package/esm2015/lib/interaction/components/activity-triggers/popup-activity-trigger/popup-activity-trigger.component.js.map +1 -1
- package/esm2015/lib/interaction/components/activity-triggers/popup-activity-trigger/popup-activity-trigger.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/add-card-activity/add-card-activity.component.js +77 -0
- package/esm2015/lib/interaction/components/add-card-activity/add-card-activity.component.js.map +1 -0
- package/esm2015/lib/interaction/components/add-card-activity/add-card-activity.component.metadata.json +1 -0
- package/esm2015/lib/interaction/components/add-card-activity/add-card-activity.component.ngfactory.js.map +1 -0
- package/esm2015/lib/interaction/components/add-card-activity/add-card-activity.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.js +1 -1
- package/esm2015/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/alert-dialog/alert-dialog.component.js +8 -14
- package/esm2015/lib/interaction/components/alert-dialog/alert-dialog.component.js.map +1 -1
- package/esm2015/lib/interaction/components/alert-dialog/alert-dialog.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/confirm-then-dialog/confirm-then-dialog.component.js +8 -31
- package/esm2015/lib/interaction/components/confirm-then-dialog/confirm-then-dialog.component.js.map +1 -1
- package/esm2015/lib/interaction/components/confirm-then-dialog/confirm-then-dialog.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.js +30 -0
- package/esm2015/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.js.map +1 -0
- package/esm2015/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.metadata.json +1 -0
- package/esm2015/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.ngfactory.js.map +1 -0
- package/esm2015/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/interaction/components/confirmation-dialog/confirmation-dialog.component.js +7 -26
- package/esm2015/lib/interaction/components/confirmation-dialog/confirmation-dialog.component.js.map +1 -1
- package/esm2015/lib/interaction/components/confirmation-dialog/confirmation-dialog.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/editors/edit-context.js +2 -0
- package/esm2015/lib/interaction/components/editors/edit-context.js.map +1 -0
- package/esm2015/lib/interaction/components/editors/edit-context.metadata.json +1 -0
- package/esm2015/lib/interaction/components/editors/inline-string-editor/inline-editor-model.js +50 -0
- package/esm2015/lib/interaction/components/editors/inline-string-editor/inline-editor-model.js.map +1 -0
- package/esm2015/lib/interaction/components/editors/inline-string-editor/inline-editor-model.metadata.json +1 -0
- package/esm2015/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.js +161 -0
- package/esm2015/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.js.map +1 -0
- package/esm2015/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.metadata.json +1 -0
- package/esm2015/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.ngfactory.js.map +1 -0
- package/esm2015/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.js +10 -3
- package/esm2015/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.js.map +1 -1
- package/esm2015/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/input-activities/input-activity.js +95 -0
- package/esm2015/lib/interaction/components/input-activities/input-activity.js.map +1 -0
- package/esm2015/lib/interaction/components/input-activities/input-activity.metadata.json +1 -0
- package/esm2015/lib/interaction/components/input-activities/input-activity.ngfactory.js.map +1 -0
- package/esm2015/lib/interaction/components/input-activities/select-input-activity.js +5 -3
- package/esm2015/lib/interaction/components/input-activities/select-input-activity.js.map +1 -1
- package/esm2015/lib/interaction/components/input-activities/select-input-activity.metadata.json +1 -1
- package/esm2015/lib/interaction/components/input-activities/string-input-activity.js +6 -4
- package/esm2015/lib/interaction/components/input-activities/string-input-activity.js.map +1 -1
- package/esm2015/lib/interaction/components/input-activities/string-input-activity.metadata.json +1 -1
- package/esm2015/lib/interaction/components/popup-interaction-context/popup-interaction-context.component.js +2 -1
- package/esm2015/lib/interaction/components/popup-interaction-context/popup-interaction-context.component.js.map +1 -1
- package/esm2015/lib/interaction/components/popup-interaction-context/popup-interaction-context.component.metadata.json +1 -1
- package/esm2015/lib/interaction/exports.js +8 -4
- package/esm2015/lib/interaction/exports.js.map +1 -1
- package/esm2015/lib/interaction/exports.metadata.json +1 -1
- package/esm2015/lib/interaction/interaction-context.js.map +1 -1
- package/esm2015/lib/interaction/interaction.module.js +29 -9
- package/esm2015/lib/interaction/interaction.module.js.map +1 -1
- package/esm2015/lib/interaction/interaction.module.metadata.json +1 -1
- package/esm2015/lib/interaction/interaction.module.ngfactory.js.map +1 -1
- package/esm2015/lib/interaction/services/interaction.service.js +1 -1
- package/esm2015/lib/interaction/services/interaction.service.js.map +1 -1
- package/esm2015/lib/place/components/abstract-place-navigation.component.js +1 -1
- package/esm2015/lib/place/components/abstract-place-navigation.component.js.map +1 -1
- package/esm2015/lib/place/components/list-place-nav/list-place-nav.component.js +1 -1
- package/esm2015/lib/place/components/list-place-nav/list-place-nav.component.metadata.json +1 -1
- package/esm2015/lib/place/components/not-authorised-notice/not-authorised-notice.component.js +1 -1
- package/esm2015/lib/place/components/not-authorised-notice/not-authorised-notice.component.metadata.json +1 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.js +18 -6
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.js.map +1 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.metadata.json +1 -1
- package/esm2015/lib/place/components/side-place-navigation/side-place-navigation.component.js +1 -1
- package/esm2015/lib/place/components/side-place-navigation/side-place-navigation.component.metadata.json +1 -1
- package/esm2015/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.js +1 -1
- package/esm2015/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.metadata.json +1 -1
- package/esm2015/lib/place/guards/consolidated-param-map.js +2 -1
- package/esm2015/lib/place/guards/consolidated-param-map.js.map +1 -1
- package/esm2015/lib/place/guards/consolidated-param-map.metadata.json +1 -1
- package/esm2015/lib/place/guards/place.guard.js +2 -1
- package/esm2015/lib/place/guards/place.guard.js.map +1 -1
- package/esm2015/lib/place/place-component.js +31 -4
- package/esm2015/lib/place/place-component.js.map +1 -1
- package/esm2015/lib/place/place-component.metadata.json +1 -1
- package/esm2015/lib/place/place-router.js +11 -14
- package/esm2015/lib/place/place-router.js.map +1 -1
- package/esm2015/lib/place/place-router.metadata.json +1 -1
- package/esm2015/lib/place/place.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/route/parameter-decorators.js.map +1 -1
- package/esm2015/lib/place/route/parameter-decorators.metadata.json +1 -1
- package/esm2015/lib/place/route/parameter-definition.js +36 -13
- package/esm2015/lib/place/route/parameter-definition.js.map +1 -1
- package/esm2015/lib/place/route/parameter-definition.metadata.json +1 -1
- package/esm2015/lib/place/route/parameter-sanitiser.js.map +1 -1
- package/esm2015/lib/place/visit.js +8 -4
- package/esm2015/lib/place/visit.js.map +1 -1
- package/esm2015/lib/place/visit.metadata.json +1 -1
- package/esm2015/lib/services/exports.js +2 -0
- package/esm2015/lib/services/exports.js.map +1 -1
- package/esm2015/lib/services/exports.metadata.json +1 -1
- package/esm2015/lib/services/markdown/markdown.service.js +25 -0
- package/esm2015/lib/services/markdown/markdown.service.js.map +1 -0
- package/esm2015/lib/services/markdown/markdown.service.metadata.json +1 -0
- package/esm2015/lib/services/markdown/markdown.service.ngfactory.js.map +1 -0
- package/esm2015/lib/services/markdown/pill-plugin.js +38 -0
- package/esm2015/lib/services/markdown/pill-plugin.js.map +1 -0
- package/esm2015/lib/services/markdown/pill-plugin.metadata.json +1 -0
- package/fesm2015/coolon-angular-ui-powerups-cypress.js +546 -244
- package/fesm2015/coolon-angular-ui-powerups-cypress.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +1253 -371
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/cards/abstract-card-container.component.d.ts +11 -0
- package/lib/components/{card-container → cards/card-container}/card-container.component.d.ts +30 -9
- package/lib/components/cards/card-stack/card-stack.component.d.ts +65 -0
- package/lib/components/commands/command-face/command-face.component.d.ts +1 -0
- package/lib/components/exports.d.ts +8 -4
- package/lib/components/labelled-value/labelled-value.component.d.ts +7 -0
- package/lib/components/loading-container/loading-container.component.d.ts +11 -0
- package/lib/components/section-header/section-header.component.d.ts +5 -2
- package/lib/components/tables/abstract-table-model.d.ts +10 -7
- package/lib/components/tables/{table/edit-session.d.ts → edit-session.d.ts} +3 -3
- package/lib/components/tables/table/cell-portal-ref.d.ts +1 -1
- package/lib/components/tables/table/cell-renderer.d.ts +2 -0
- package/lib/components/tables/table/column-model.d.ts +14 -5
- package/lib/components/tables/table/default-cell-renderer/default-cell-renderer.component.d.ts +2 -1
- package/lib/components/tables/table/edit-row-controls/edit-row-controls.component.d.ts +4 -2
- package/lib/components/tables/table/table-cell-renderer/table-cell-renderer.component.d.ts +1 -1
- package/lib/components/tables/table/table-row-menu/table-row-menu.component.d.ts +2 -3
- package/lib/components/tables/table/table.component.d.ts +13 -12
- package/lib/components/tables/table/text-search-predicate.d.ts +1 -0
- package/lib/components/tables/tree-table/flattened-tree-list-model.d.ts +0 -1
- package/lib/components/tables/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.d.ts +2 -3
- package/lib/components/tables/tree-table/tree-label-column-model.d.ts +2 -3
- package/lib/components/tables/tree-table/tree-table-component.d.ts +1 -1
- package/lib/components/tables/tree-table/tree-table-model.d.ts +4 -5
- package/lib/components/text/markdown/markdown.component.d.ts +28 -0
- package/lib/components/track-by.d.ts +9 -0
- package/lib/interaction/abstract-interaction-context.d.ts +1 -0
- package/lib/interaction/alert.d.ts +7 -1
- package/lib/interaction/components/abstract-confirm-dialog.component.d.ts +7 -0
- package/lib/interaction/components/abstract-dialog.component.d.ts +17 -0
- package/lib/interaction/components/activity-actions/activity-actions.component.d.ts +14 -3
- package/lib/interaction/components/activity-triggers/abstract-activity-trigger.component.d.ts +1 -1
- package/lib/interaction/components/activity-triggers/inline-activity-trigger/inline-activity-trigger.component.d.ts +2 -1
- package/lib/interaction/components/activity-triggers/modal-activity-trigger/modal-activity-trigger.component.d.ts +2 -1
- package/lib/interaction/components/activity-triggers/popup-activity-trigger/popup-activity-trigger.component.d.ts +2 -1
- package/lib/interaction/components/add-card-activity/add-card-activity.component.d.ts +39 -0
- package/lib/interaction/components/alert-dialog/alert-dialog.component.d.ts +2 -7
- package/lib/interaction/components/confirm-then-dialog/confirm-then-dialog.component.d.ts +2 -10
- package/lib/interaction/components/confirm-then-execute-dialog/confirm-then-execute-dialog.component.d.ts +12 -0
- package/lib/interaction/components/confirmation-dialog/confirmation-dialog.component.d.ts +2 -9
- package/lib/interaction/components/editors/edit-context.d.ts +3 -0
- package/lib/interaction/components/editors/inline-string-editor/inline-editor-model.d.ts +24 -0
- package/lib/interaction/components/editors/inline-string-editor/inline-string-editor.component.d.ts +57 -0
- package/lib/interaction/components/inplace-interaction-context/in-place-interaction-context.component.d.ts +2 -0
- package/lib/interaction/components/input-activities/input-activity.d.ts +41 -0
- package/lib/interaction/components/input-activities/select-input-activity.d.ts +11 -3
- package/lib/interaction/components/input-activities/string-input-activity.d.ts +6 -2
- package/lib/interaction/exports.d.ts +8 -4
- package/lib/interaction/interaction-context.d.ts +1 -0
- package/lib/place/components/place-outlet/place-outlet.component.d.ts +1 -0
- package/lib/place/place-component.d.ts +6 -1
- package/lib/place/place-router.d.ts +2 -2
- package/lib/place/route/parameter-decorators.d.ts +5 -0
- package/lib/place/route/parameter-definition.d.ts +6 -1
- package/lib/place/route/parameter-sanitiser.d.ts +2 -3
- package/lib/place/visit.d.ts +2 -2
- package/lib/services/exports.d.ts +2 -0
- package/lib/services/markdown/markdown.service.d.ts +6 -0
- package/lib/services/markdown/pill-plugin.d.ts +15 -0
- package/package.json +17 -16
- package/schematics/activity/index.js +1 -1
- package/schematics/activity/index.js.map +1 -1
- package/schematics/activity/templates/component/__name@dasherize__.component.html.template +1 -1
- package/schematics/activity/templates/component/__name@dasherize__.component.ts.template +5 -3
- package/schematics/aup-i18n/index.js +1 -1
- package/schematics/aup-i18n/index.js.map +1 -1
- package/schematics/component/index.js +1 -1
- package/schematics/component/index.js.map +1 -1
- package/schematics/component/templates/component/__name@dasherize__.component.ts.template +1 -1
- package/schematics/place-routes/place-class-scanner.js +3 -1
- package/schematics/place-routes/place-class-scanner.js.map +1 -1
- package/schematics/utils/build-context.d.ts +6 -3
- package/schematics/utils/build-context.js +3 -3
- package/schematics/utils/build-context.js.map +1 -1
- package/schematics/utils/workspace.d.ts +1 -0
- package/schematics/utils/workspace.js +11 -3
- package/schematics/utils/workspace.js.map +1 -1
- package/assets/activities.scss +0 -70
- package/cypress/components/aup-more-menu.d.ts +0 -4
- package/cypress/components/aup-popup-menu.d.ts +0 -7
- package/cypress/components/button-mixin.d.ts +0 -19
- package/cypress/section.d.ts +0 -55
- package/esm2015/cypress/components/aup-more-menu.js +0 -7
- package/esm2015/cypress/components/aup-more-menu.js.map +0 -1
- package/esm2015/cypress/components/aup-more-menu.metadata.json +0 -1
- package/esm2015/cypress/components/aup-popup-menu.js +0 -19
- package/esm2015/cypress/components/aup-popup-menu.js.map +0 -1
- package/esm2015/cypress/components/aup-popup-menu.metadata.json +0 -1
- package/esm2015/cypress/components/button-mixin.js +0 -15
- package/esm2015/cypress/components/button-mixin.js.map +0 -1
- package/esm2015/cypress/components/button-mixin.metadata.json +0 -1
- package/esm2015/cypress/section.js +0 -76
- package/esm2015/cypress/section.js.map +0 -1
- package/esm2015/cypress/section.metadata.json +0 -1
- package/esm2015/lib/components/card-container/card-container.component.js +0 -84
- package/esm2015/lib/components/card-container/card-container.component.js.map +0 -1
- package/esm2015/lib/components/card-container/card-container.component.metadata.json +0 -1
- package/esm2015/lib/components/card-container/card-container.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/tables/table/edit-session.js.map +0 -1
- package/esm2015/lib/components/tables/tree-table/tree-node.js +0 -2
- package/esm2015/lib/components/tables/tree-table/tree-node.js.map +0 -1
- package/esm2015/lib/components/tables/tree-table/tree-node.metadata.json +0 -1
- package/esm2015/lib/components/tables/tree-table/visitable.class.js +0 -26
- package/esm2015/lib/components/tables/tree-table/visitable.class.js.map +0 -1
- package/esm2015/lib/components/tables/tree-table/visitable.class.metadata.json +0 -1
- package/esm2015/lib/interaction/components/input-activities/abstract-input-activity.js +0 -43
- package/esm2015/lib/interaction/components/input-activities/abstract-input-activity.js.map +0 -1
- package/esm2015/lib/interaction/components/input-activities/abstract-input-activity.metadata.json +0 -1
- package/esm2015/lib/interaction/components/input-activities/abstract-input-activity.ngfactory.js.map +0 -1
- package/esm2015/lib/interaction/components/input-activities/input-activity-data.js +0 -2
- package/esm2015/lib/interaction/components/input-activities/input-activity-data.js.map +0 -1
- package/esm2015/lib/interaction/components/input-activities/input-activity-data.metadata.json +0 -1
- package/esm2015/lib/interaction/components/input-activities/select-input-activity-data.js +0 -2
- package/esm2015/lib/interaction/components/input-activities/select-input-activity-data.js.map +0 -1
- package/esm2015/lib/interaction/components/input-activities/select-input-activity-data.metadata.json +0 -1
- package/esm2015/lib/interaction/result.js +0 -4
- package/esm2015/lib/interaction/result.js.map +0 -1
- package/esm2015/lib/interaction/result.metadata.json +0 -1
- package/lib/components/tables/tree-table/tree-node.d.ts +0 -3
- package/lib/components/tables/tree-table/visitable.class.d.ts +0 -22
- package/lib/interaction/components/input-activities/abstract-input-activity.d.ts +0 -12
- package/lib/interaction/components/input-activities/input-activity-data.d.ts +0 -11
- package/lib/interaction/components/input-activities/select-input-activity-data.d.ts +0 -8
- package/lib/interaction/result.d.ts +0 -8
- /package/esm2015/lib/components/tables/{table/edit-session.js → edit-session.js} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as i2 from '@angular/common';
|
|
2
2
|
import { DOCUMENT, CommonModule, Location } from '@angular/common';
|
|
3
3
|
import * as i0 from '@angular/core';
|
|
4
|
-
import { Directive, ElementRef, Inject, Host, Optional, Input, HostListener, NgZone, Injectable, Pipe, NgModule, Component, ContentChild,
|
|
4
|
+
import { Directive, ElementRef, Inject, Host, Optional, Input, HostListener, NgZone, Injectable, Pipe, NgModule, Component, ContentChild, HostBinding, ViewEncapsulation, InjectionToken, ViewChildren, SkipSelf, EventEmitter, ViewChild, Output, Self, TemplateRef, ChangeDetectorRef, ContentChildren, ViewContainerRef, PLATFORM_ID, Injector, ComponentFactoryResolver } from '@angular/core';
|
|
5
5
|
import { FormsModule } from '@angular/forms';
|
|
6
6
|
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
7
7
|
import { MatInputModule } from '@angular/material/input';
|
|
@@ -16,21 +16,24 @@ import { MatCheckboxModule } from '@angular/material/checkbox';
|
|
|
16
16
|
import { MatDividerModule } from '@angular/material/divider';
|
|
17
17
|
import { MatIconModule } from '@angular/material/icon';
|
|
18
18
|
import { MatMenuItem, MatMenuTrigger, MatMenuModule } from '@angular/material/menu';
|
|
19
|
+
import { MatProgressBarModule } from '@angular/material/progress-bar';
|
|
19
20
|
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
20
21
|
import { MatTableModule } from '@angular/material/table';
|
|
21
22
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
22
23
|
import { FontAwesomeModule, FaIconLibrary } from '@fortawesome/angular-fontawesome';
|
|
23
24
|
import { fas } from '@fortawesome/free-solid-svg-icons';
|
|
24
|
-
import { GarbageCollector, DelegatingValueModel, assert, UnaryCommand, lang, Dsl, Logger, TrackExternal, ValueModel, StoreInValueModel, Command, MutableListModel, StoreInListModel, Disposable, MutableValueModel, DelegatingListModel, FocusManager, EventListenerList, Form, Guard, Binding, DebugContext, ListModel, MultipleSelectionModel, DelegatingSelectionModel, AbstractComputedListModel, DirtyTrackingForm, ComputedListModel, PageController, Deferred,
|
|
25
|
+
import { GarbageCollector, DelegatingValueModel, assert, UnaryCommand, lang, Dsl, Logger, TrackExternal, ValueModel, StoreInValueModel, Command, MutableListModel, StoreInListModel, Disposable, MutableValueModel, DelegatingListModel, FocusManager, EventListenerList, Form, Guard, Binding, DebugContext, ListModel, MultipleSelectionModel, DelegatingSelectionModel, AbstractComputedListModel, DirtyTrackingForm, ComputedListModel, PageController, Deferred, Functions } from '@coolon/pectin';
|
|
25
26
|
import { __decorate, __metadata, __awaiter } from 'tslib';
|
|
26
27
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
27
28
|
import * as _ from 'lodash';
|
|
28
29
|
import ___default from 'lodash';
|
|
30
|
+
import { marked } from 'marked';
|
|
29
31
|
import { Memoize } from '@typescript-plus/fast-memoize-decorator/dist/src';
|
|
30
32
|
import { Enum } from 'typescript-string-enums';
|
|
31
|
-
import {
|
|
33
|
+
import { lang as lang$1, assert as assert$1, Stringy, Opts, Klass } from '@coolon/typescript-utilities';
|
|
32
34
|
import ResizeObserver from 'resize-observer-polyfill';
|
|
33
35
|
import produce from 'immer';
|
|
36
|
+
import { A11yModule } from '@angular/cdk/a11y';
|
|
34
37
|
import { FlexModule, GridModule } from '@angular/flex-layout';
|
|
35
38
|
import * as i1$1 from '@angular/material/dialog';
|
|
36
39
|
import { MatDialogModule, MatDialog, MatDialogConfig, MAT_DIALOG_DEFAULT_OPTIONS } from '@angular/material/dialog';
|
|
@@ -47,7 +50,7 @@ class CommandDirective extends GarbageCollector {
|
|
|
47
50
|
constructor(elementRef, matButton, matMenuItem) {
|
|
48
51
|
super();
|
|
49
52
|
this.elementRef = elementRef;
|
|
50
|
-
this._commandEnabled = new DelegatingValueModel().withDefault(false);
|
|
53
|
+
this._commandEnabled = this.registerDisposable(new DelegatingValueModel().withDefault(false));
|
|
51
54
|
this._commandParameterProvided = false;
|
|
52
55
|
// Material buttons and menu items don't respond to the disabled binding so we
|
|
53
56
|
// need to inject them from our host element and handle them manually.
|
|
@@ -390,6 +393,66 @@ DirectivesModule.decorators = [
|
|
|
390
393
|
},] }
|
|
391
394
|
];
|
|
392
395
|
|
|
396
|
+
const markdownPillExtension = (renderPill) => {
|
|
397
|
+
return {
|
|
398
|
+
name: 'aup-pill',
|
|
399
|
+
level: 'inline',
|
|
400
|
+
start: (src) => {
|
|
401
|
+
var _a;
|
|
402
|
+
const index = (_a = src.match(/\(\([^)]/)) === null || _a === void 0 ? void 0 : _a.index;
|
|
403
|
+
// if (index) {
|
|
404
|
+
// console.log({start:src})
|
|
405
|
+
// }
|
|
406
|
+
return index;
|
|
407
|
+
},
|
|
408
|
+
tokenizer: function (src) {
|
|
409
|
+
const rule = /^(\(\((([^)])+)\)\))/; // Regex for the complete token
|
|
410
|
+
const match = rule.exec(src);
|
|
411
|
+
if (match) {
|
|
412
|
+
const token = {
|
|
413
|
+
type: 'aup-pill',
|
|
414
|
+
raw: match[0],
|
|
415
|
+
text: match[2].trim(), // Additional custom properties
|
|
416
|
+
// tokens: [] // Array where child inline tokens will be generated
|
|
417
|
+
};
|
|
418
|
+
// console.log(token)
|
|
419
|
+
// this.lexer.inlineTokens(token.text, token.tokens); // Queue this data to be processed for inline tokens
|
|
420
|
+
return token;
|
|
421
|
+
}
|
|
422
|
+
else {
|
|
423
|
+
return undefined;
|
|
424
|
+
}
|
|
425
|
+
},
|
|
426
|
+
renderer: function (token) {
|
|
427
|
+
// @ts-ignore (until typings are up to date)
|
|
428
|
+
const url = token.text;
|
|
429
|
+
return renderPill(token.text);
|
|
430
|
+
}
|
|
431
|
+
};
|
|
432
|
+
};
|
|
433
|
+
|
|
434
|
+
class MarkdownService {
|
|
435
|
+
constructor() {
|
|
436
|
+
}
|
|
437
|
+
render(content) {
|
|
438
|
+
return marked.parse(content, {
|
|
439
|
+
smartLists: true
|
|
440
|
+
});
|
|
441
|
+
}
|
|
442
|
+
renderInline(content) {
|
|
443
|
+
return marked.parseInline(content);
|
|
444
|
+
}
|
|
445
|
+
usePillExtension(renderer) {
|
|
446
|
+
marked.use({
|
|
447
|
+
extensions: [markdownPillExtension(renderer !== null && renderer !== void 0 ? renderer : (text => `<span class='aup-pill'>${text}<span>`))]
|
|
448
|
+
});
|
|
449
|
+
}
|
|
450
|
+
}
|
|
451
|
+
MarkdownService.decorators = [
|
|
452
|
+
{ type: Injectable }
|
|
453
|
+
];
|
|
454
|
+
MarkdownService.ctorParameters = () => [];
|
|
455
|
+
|
|
393
456
|
class BusyOverlayComponent extends GarbageCollector {
|
|
394
457
|
constructor() {
|
|
395
458
|
super();
|
|
@@ -401,7 +464,7 @@ BusyOverlayComponent.decorators = [
|
|
|
401
464
|
{ type: Component, args: [{
|
|
402
465
|
selector: 'aup-busy-overlay',
|
|
403
466
|
template: "<ng-content></ng-content>\n<div class=\"busy-overlay-backdrop\" *ngIf=\"busyModel.value\">\n <mat-progress-spinner mode=\"indeterminate\" [diameter]=\"52\"></mat-progress-spinner>\n</div>\n",
|
|
404
|
-
styles: [":host{position:relative}div.busy-overlay-backdrop{
|
|
467
|
+
styles: [":host{position:relative}div.busy-overlay-backdrop{z-index:10;z-index:var(--aup-busy-overlay-z-index, 10);position:absolute;background-color:#0003;top:0;left:0;bottom:0;right:0;display:grid;grid-template-columns:auto;grid-template-rows:auto;place-content:center}\n"]
|
|
405
468
|
},] }
|
|
406
469
|
];
|
|
407
470
|
BusyOverlayComponent.ctorParameters = () => [];
|
|
@@ -526,6 +589,30 @@ var CommandFace;
|
|
|
526
589
|
CommandFace.Adapter = Adapter;
|
|
527
590
|
})(CommandFace || (CommandFace = {}));
|
|
528
591
|
|
|
592
|
+
class AbstractCardContainerComponent extends DisposableComponent {
|
|
593
|
+
constructor() {
|
|
594
|
+
super();
|
|
595
|
+
}
|
|
596
|
+
ngOnInit() {
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
AbstractCardContainerComponent.decorators = [
|
|
600
|
+
{ type: Component, args: [{
|
|
601
|
+
selector: 'aup-abstract-card-container',
|
|
602
|
+
template: ''
|
|
603
|
+
},] }
|
|
604
|
+
];
|
|
605
|
+
AbstractCardContainerComponent.ctorParameters = () => [];
|
|
606
|
+
AbstractCardContainerComponent.propDecorators = {
|
|
607
|
+
addCardCommand: [{ type: Input }],
|
|
608
|
+
addCardFace: [{ type: Input }],
|
|
609
|
+
addCardTemplate: [{ type: ContentChild, args: ['addCardTemplate',] }]
|
|
610
|
+
};
|
|
611
|
+
__decorate([
|
|
612
|
+
TrackExternal(),
|
|
613
|
+
__metadata("design:type", Command)
|
|
614
|
+
], AbstractCardContainerComponent.prototype, "addCardCommand", void 0);
|
|
615
|
+
|
|
529
616
|
/**
|
|
530
617
|
* @example
|
|
531
618
|
* // basic usage
|
|
@@ -543,6 +630,13 @@ var CommandFace;
|
|
|
543
630
|
* <my-card *ngFor="..."></my-card>
|
|
544
631
|
* </aup-card-container>
|
|
545
632
|
*
|
|
633
|
+
* // use the aup-add-card-activity to display as the new card place holder and to run
|
|
634
|
+
* // the activity inside teh card
|
|
635
|
+
* <aup-card-container [addCardCommand]="addCard" [addCardFace]="i18n.addCard" >
|
|
636
|
+
* <my-card *ngFor="..."></my-card>
|
|
637
|
+
* <aup-add-card-activity type="inline" renderAs="card" [face]="i18n.commands.addModal" [activityClass]="AddCardActivity"></aup-add-card-activity>
|
|
638
|
+
* </aup-card-container>
|
|
639
|
+
*
|
|
546
640
|
* // adds an add card component using the specified template. The template
|
|
547
641
|
* // will fill it's container in the grid.
|
|
548
642
|
* <aup-card-container>
|
|
@@ -575,35 +669,144 @@ var CommandFace;
|
|
|
575
669
|
* aup-card-container {
|
|
576
670
|
* --card-gap: var(--card-gap, 16px);
|
|
577
671
|
* --card-width: var(--card-width, 300px);
|
|
672
|
+
* --card-max-width: auto;
|
|
578
673
|
* --card-height: var(--card-height, auto);
|
|
579
674
|
* --card-min-height: var(--card-min-height, auto);
|
|
580
675
|
* --card-background: var(--card-background, #fcfcfb);
|
|
581
676
|
* }
|
|
582
677
|
*/
|
|
583
|
-
class CardContainerComponent extends
|
|
584
|
-
constructor() {
|
|
678
|
+
class CardContainerComponent extends AbstractCardContainerComponent {
|
|
679
|
+
constructor(elementRef) {
|
|
585
680
|
super();
|
|
681
|
+
this.elementRef = elementRef;
|
|
682
|
+
/**
|
|
683
|
+
* Enable scrolling. If true the container will have height==0 so you must set it's height explicitly
|
|
684
|
+
* or place in a layout that will stretch it such as a grid or flex layout.
|
|
685
|
+
*/
|
|
686
|
+
this.enabledScroll = false;
|
|
687
|
+
}
|
|
688
|
+
set columnCount(count) {
|
|
689
|
+
if (!_.isNil(count) && (!_.isInteger(count) || count < 1)) {
|
|
690
|
+
lang$1.illegalState('columnCount must be a positive integer or nil');
|
|
691
|
+
}
|
|
692
|
+
this._columnCount = count;
|
|
693
|
+
this.updateColumnCountStyles();
|
|
694
|
+
}
|
|
695
|
+
get columnCount() {
|
|
696
|
+
return this._columnCount;
|
|
586
697
|
}
|
|
587
698
|
ngOnInit() {
|
|
699
|
+
super.ngOnInit();
|
|
700
|
+
this.updateColumnCountStyles();
|
|
701
|
+
}
|
|
702
|
+
get isAutoColumns() {
|
|
703
|
+
return _.isNil(this._columnCount);
|
|
704
|
+
}
|
|
705
|
+
get isSingleColumn() {
|
|
706
|
+
return this._columnCount === 1;
|
|
707
|
+
}
|
|
708
|
+
updateColumnCountStyles() {
|
|
709
|
+
const el = this.elementRef.nativeElement;
|
|
710
|
+
if (_.isNil(this._columnCount)) {
|
|
711
|
+
el.style.setProperty('--aup-card-container-column-count', '');
|
|
712
|
+
}
|
|
713
|
+
else {
|
|
714
|
+
el.style.setProperty('--aup-card-container-column-count', this._columnCount);
|
|
715
|
+
}
|
|
588
716
|
}
|
|
589
717
|
}
|
|
590
718
|
CardContainerComponent.decorators = [
|
|
591
719
|
{ type: Component, args: [{
|
|
592
720
|
selector: 'aup-card-container',
|
|
593
|
-
template: "<div class=\"
|
|
594
|
-
styles: [":host{--resolved-card-gap:var(--card-gap,16px);--resolved-card-width:var(--card-width,300px);--resolved-card-height:var(--card-height,auto);--resolved-card-min-height:var(--card-min-height,auto);--resolved-card-background:var(--card-background
|
|
721
|
+
template: "<div class=\"header-container\">\n <ng-content select=\"[card-container-header]\"></ng-content>\n</div>\n\n<ng-template #content>\n <div class=\"card-container\">\n <ng-content></ng-content>\n\n <div class=\"add-card-container\" *ngIf=\"addCardCommand.enabled.value\" [pectinCommand]=\"addCardCommand\">\n <aup-command-face *ngIf=\"addCardFace\" [faces]=\"[addCardFace]\"></aup-command-face>\n <aup-icon *ngIf=\"!addCardFace\" icon=\"mat:add\"></aup-icon>\n </div>\n\n <div class=\"add-card-template\" *ngIf=\"addCardTemplate\">\n <ng-container [ngTemplateOutlet]=\"addCardTemplate\"></ng-container>\n </div>\n </div>\n</ng-template>\n\n<div class=\"no-scroll-container\" *ngIf=\"!enabledScroll\">\n <ng-container *ngTemplateOutlet=\"content\"></ng-container>\n</div>\n\n<aup-scroll-container *ngIf=\"enabledScroll\">\n <ng-container *ngTemplateOutlet=\"content\"></ng-container>\n</aup-scroll-container>\n\n<div class=\"footer-container\">\n <ng-content select=\"[card-container-footer]\"></ng-content>\n</div>\n\n",
|
|
722
|
+
styles: [":host{--resolved-card-gap: var(--card-gap, 16px);--resolved-card-width: var(--card-width, 300px);--resolved-card-max-width: var(--card-max-width, auto);--resolved-card-height: var(--card-height, auto);--resolved-card-min-height: var(--card-min-height, auto);--resolved-card-background: var(--card-background, var(--aup-card-container-default-background-color));flex:1;display:flex;flex-direction:column;align-items:stretch;background:var(--resolved-card-background)}:host.auto-columns .card-container{grid-template-columns:repeat(auto-fit,minmax(var(--resolved-card-width),var(--resolved-card-max-width)));min-width:calc(var(--resolved-card-width) + 2 * var(--resolved-card-gap));width:calc((var(--resolved-card-width) + var(--resolved-card-gap)) * 2 + var(--grid-gap))}:host:not(.auto-columns) .card-container{grid-template-columns:repeat(var(--aup-card-container-column-count),1fr)}.card-container{display:grid;box-sizing:border-box;padding:var(--resolved-card-gap);min-height:calc(var(--resolved-card-height) + 2 * var(--resolved-card-gap));max-width:100%;grid-auto-rows:minmax(var(--resolved-card-min-height),var(--resolved-card-height));grid-gap:var(--resolved-card-gap)}aup-scroll-container,.no-scroll-container{flex:1}.add-card-container{height:var(--resolved-card-height);min-height:var(--resolved-card-min-height);display:flex;flex-direction:column;align-items:center;justify-content:center;transition:box-shadow .28s cubic-bezier(.4,0,.2,1);box-sizing:border-box;border:2px dashed rgba(0,0,0,.1);border-radius:6px;font-weight:300;cursor:pointer;color:#0000008a;background-color:#fffc}.add-card-container mat-icon{font-size:200%}.add-card-container:hover{box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.add-card-container:hover{border-color:transparent;background-color:#fff;color:#0000008a}.add-card-template-container{height:var(--resolved-card-height);min-height:var(--resolved-card-min-height);display:flex;flex-direction:column;align-items:stretch;justify-content:stretch}\n"]
|
|
595
723
|
},] }
|
|
596
724
|
];
|
|
597
|
-
CardContainerComponent.ctorParameters = () => [
|
|
725
|
+
CardContainerComponent.ctorParameters = () => [
|
|
726
|
+
{ type: ElementRef }
|
|
727
|
+
];
|
|
598
728
|
CardContainerComponent.propDecorators = {
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
729
|
+
columnCount: [{ type: Input }],
|
|
730
|
+
enabledScroll: [{ type: Input }],
|
|
731
|
+
isAutoColumns: [{ type: HostBinding, args: ['class.auto-columns',] }],
|
|
732
|
+
isSingleColumn: [{ type: HostBinding, args: ['class.single-column',] }]
|
|
602
733
|
};
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
734
|
+
|
|
735
|
+
/**
|
|
736
|
+
* @deprecated deprecated, use `aup-card-container [columnCount]="1"` instead.
|
|
737
|
+
* @example
|
|
738
|
+
* // basic usage
|
|
739
|
+
* <aup-card-stack>
|
|
740
|
+
* <my-card *ngFor="..."></my-card>
|
|
741
|
+
* </aup-card-stack>
|
|
742
|
+
*
|
|
743
|
+
* // adds an add button with a the '+' icon to the end of the card list.
|
|
744
|
+
* <aup-card-stack [addCardCommand]="addCard">
|
|
745
|
+
* <my-card *ngFor="..."></my-card>
|
|
746
|
+
* </aup-card-stack>
|
|
747
|
+
*
|
|
748
|
+
* // adds an add button with the specified face
|
|
749
|
+
* <aup-card-stack [addCardCommand]="addCard" [addCardFace]="i18n.addCard" >
|
|
750
|
+
* <my-card *ngFor="..."></my-card>
|
|
751
|
+
* </aup-card-stack>
|
|
752
|
+
*
|
|
753
|
+
* // use the aup-add-card-activity to display as the new card place holder and to run
|
|
754
|
+
* // the activity inside teh card
|
|
755
|
+
* <aup-card-stack [addCardCommand]="addCard" [addCardFace]="i18n.addCard" >
|
|
756
|
+
* <my-card *ngFor="..."></my-card>
|
|
757
|
+
* <aup-add-card-activity type="inline" renderAs="card" [face]="i18n.commands.addModal" [activityClass]="AddCardActivity"></aup-add-card-activity>
|
|
758
|
+
* </aup-card-stack>
|
|
759
|
+
*
|
|
760
|
+
* // adds an add card component using the specified template. The template
|
|
761
|
+
* // will fill it's container in the grid.
|
|
762
|
+
* <aup-card-stack>
|
|
763
|
+
* <my-card *ngFor="..."></my-card>
|
|
764
|
+
* <ng-template #addCardTemplate>
|
|
765
|
+
* <div>This is a new card template, it will the the size of the other cards.</div>
|
|
766
|
+
* </ng-template>
|
|
767
|
+
* </aup-card-stack>
|
|
768
|
+
*
|
|
769
|
+
* // sing the default new card styles for your template
|
|
770
|
+
* @import "../../../../assets/styles";
|
|
771
|
+
* .my-new-card {
|
|
772
|
+
* @include aup-card-stack-new-card-style();
|
|
773
|
+
* // OR
|
|
774
|
+
* @include aup-card-stack-new-card-style(
|
|
775
|
+
* $color: rgba(0,0,0,0.54),
|
|
776
|
+
* $background-color: rgba(255,255,255,0.8),
|
|
777
|
+
* $hover-color: $color,
|
|
778
|
+
* $background-hover-color: white
|
|
779
|
+
* )
|
|
780
|
+
* }
|
|
781
|
+
* <aup-card-stack>
|
|
782
|
+
* <my-card *ngFor="..."></my-card>
|
|
783
|
+
* <ng-template #addCardTemplate>
|
|
784
|
+
* <div class="my-new-card" >This is a new card template, it will the the size of the other cards.</div>
|
|
785
|
+
* </ng-template>
|
|
786
|
+
* </aup-card-stack>
|
|
787
|
+
*
|
|
788
|
+
* // CSS Vars
|
|
789
|
+
* aup-card-stack {
|
|
790
|
+
* --card-gap: var(--card-gap, 16px);
|
|
791
|
+
* --card-height: var(--card-height, auto);
|
|
792
|
+
* --card-min-height: var(--card-min-height, auto);
|
|
793
|
+
* --card-background: var(--card-background, #fcfcfb);
|
|
794
|
+
* }
|
|
795
|
+
*/
|
|
796
|
+
class CardStackComponent extends AbstractCardContainerComponent {
|
|
797
|
+
constructor() {
|
|
798
|
+
super();
|
|
799
|
+
console.warn('<aup-card-stack></aup-card-stack> is deprecated. Use <aup-card-container [columnCount]="1"> instead.');
|
|
800
|
+
}
|
|
801
|
+
}
|
|
802
|
+
CardStackComponent.decorators = [
|
|
803
|
+
{ type: Component, args: [{
|
|
804
|
+
selector: 'aup-card-stack',
|
|
805
|
+
template: "<div class=\"card-container\">\n <ng-content></ng-content>\n</div>\n<div class=\"footer\">\n <div class=\"add-card-container\" *ngIf=\"addCardCommand.enabled.value\" [pectinCommand]=\"addCardCommand\">\n <aup-command-face *ngIf=\"addCardFace\" [faces]=\"[addCardFace]\"></aup-command-face>\n <aup-icon *ngIf=\"!addCardFace\" icon=\"mat:add\"></aup-icon>\n </div>\n\n <div class=\"add-card-template\" *ngIf=\"addCardTemplate\">\n <ng-container [ngTemplateOutlet]=\"addCardTemplate\"></ng-container>\n </div>\n <ng-content select=\"[aup-card-stack-footer]\"></ng-content>\n</div>\n",
|
|
806
|
+
styles: [":host{--resolved-card-gap: var(--card-gap, 16px);--resolved-card-height: var(--card-height, auto);--resolved-card-min-height: var(--card-min-height, auto);--resolved-card-background: var(--card-background, #fcfcfb);flex:1;display:block;background:var(--resolved-card-background)}.card-container{display:grid;grid-template-columns:1fr;grid-auto-rows:minmax(var(--resolved-card-min-height),var(--resolved-card-height));grid-gap:var(--resolved-card-gap);box-sizing:border-box;padding:var(--resolved-card-gap);max-width:100%}.footer{display:flex;flex-direction:column;align-items:stretch;padding:0 var(--resolved-card-gap) var(--resolved-card-gap)}.add-card-container{width:var(--resolved-card-width);height:var(--resolved-card-height);min-height:var(--resolved-card-min-height);display:flex;flex-direction:column;align-items:center;justify-content:center;transition:box-shadow .28s cubic-bezier(.4,0,.2,1);box-sizing:border-box;border:2px dashed rgba(0,0,0,.1);border-radius:6px;font-weight:300;cursor:pointer;color:#0000008a;background-color:#fffc}.add-card-container mat-icon{font-size:200%}.add-card-container:hover{box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.add-card-container:hover{border-color:transparent;background-color:#fff;color:#0000008a}.add-card-template-container{width:var(--resolved-card-width);height:var(--resolved-card-height);display:flex;flex-direction:column;align-items:stretch;justify-content:stretch}\n"]
|
|
807
|
+
},] }
|
|
808
|
+
];
|
|
809
|
+
CardStackComponent.ctorParameters = () => [];
|
|
607
810
|
|
|
608
811
|
/**
|
|
609
812
|
* Custom CSS:
|
|
@@ -628,6 +831,9 @@ class CommandFaceComponent extends DisposableComponent {
|
|
|
628
831
|
this.activeIcon = activeFace.pluck("icon");
|
|
629
832
|
this.activeColor = activeFace.pluck("color");
|
|
630
833
|
}
|
|
834
|
+
set face(face) {
|
|
835
|
+
this.facesModel.value = [face];
|
|
836
|
+
}
|
|
631
837
|
get requiresMissingIconInLayout() {
|
|
632
838
|
return this.includeMissingIconInLayout && !this.activeIcon.value;
|
|
633
839
|
}
|
|
@@ -651,12 +857,13 @@ CommandFaceComponent.decorators = [
|
|
|
651
857
|
selector: 'aup-command-face',
|
|
652
858
|
template: "<div class=\"face-container\" *ngFor=\"let face of faceAdapters.value\">\n <aup-icon *ngIf=\"hasIconStart(face)\" [icon]=\"face.icon\"></aup-icon>\n <span *ngIf=\"face.text\">{{face.text}}</span>\n <aup-icon *ngIf=\"hasIconEnd(face)\" [icon]=\"face.icon\"></aup-icon>\n</div>\n",
|
|
653
859
|
encapsulation: ViewEncapsulation.None,
|
|
654
|
-
styles: ["aup-command-face{--icon-gap:var(--aup-command-face-icon-gap);display:inline-grid}aup-command-face>.face-container{grid-column:1;grid-row:1;display:inline-flex;flex-direction:row;align-items:center}aup-command-face>.face-container:not(:first-child){visibility:hidden}aup-command-face>.face-container *+*{margin-left:var(--icon-gap)}aup-command-face.hide-icon aup-icon{visibility:hidden}aup-command-face.centered{justify-items:center}aup-command-face.start{justify-items:self-start}aup-command-face.end{justify-items:self-end}"]
|
|
860
|
+
styles: ["aup-command-face{--icon-gap: var(--aup-command-face-icon-gap);display:inline-grid}aup-command-face>.face-container{grid-column:1;grid-row:1;display:inline-flex;flex-direction:row;align-items:center}aup-command-face>.face-container:not(:first-child){visibility:hidden}aup-command-face>.face-container *+*{margin-left:var(--icon-gap)}aup-command-face.hide-icon aup-icon{visibility:hidden}aup-command-face.centered{justify-items:center}aup-command-face.start{justify-items:self-start}aup-command-face.end{justify-items:self-end}\n"]
|
|
655
861
|
},] }
|
|
656
862
|
];
|
|
657
863
|
CommandFaceComponent.ctorParameters = () => [];
|
|
658
864
|
CommandFaceComponent.propDecorators = {
|
|
659
865
|
_rawFaces: [{ type: Input, args: ['faces',] }],
|
|
866
|
+
face: [{ type: Input }],
|
|
660
867
|
ignoreIcon: [{ type: Input }],
|
|
661
868
|
ignoreText: [{ type: Input }],
|
|
662
869
|
includeMissingIconInLayout: [{ type: Input }],
|
|
@@ -740,7 +947,7 @@ CommandComponent.decorators = [
|
|
|
740
947
|
{ type: Component, args: [{
|
|
741
948
|
selector: 'aup-command',
|
|
742
949
|
template: "<ng-container *ngIf=\"iconOnly.value\">\n <button mat-icon-button [pectinCommand]=\"command\" [color]=\"colorModel.value\" [class.busy]=\"command.busy.value\"\n [matTooltip]=\"tooltipModel.value\">\n <aup-command-face [class]=\"alignFace\" [faces]=\"faces.value\"></aup-command-face>\n </button>\n</ng-container>\n<ng-container *ngIf=\"!iconOnly.value\">\n <ng-container [ngSwitch]=\"buttonStyle.value\">\n <ng-container *ngSwitchCase=\"CommandFace.Style.STROKED\">\n <button mat-stroked-button [pectinCommand]=\"command\" [color]=\"colorModel.value\" [class.busy]=\"command.busy.value\"\n [matTooltip]=\"tooltipModel.value\">\n <aup-command-face [class]=\"alignFace\" [faces]=\"faces.value\"></aup-command-face>\n </button>\n </ng-container>\n <ng-container *ngSwitchCase=\"CommandFace.Style.RAISED\">\n <button mat-raised-button [pectinCommand]=\"command\" [color]=\"colorModel.value\" [class.busy]=\"command.busy.value\"\n [matTooltip]=\"tooltipModel.value\">\n <aup-command-face [class]=\"alignFace\" [faces]=\"faces.value\"></aup-command-face>\n </button>\n </ng-container>\n <ng-container *ngSwitchDefault>\n <button mat-button [pectinCommand]=\"command\" [color]=\"colorModel.value\" [class.busy]=\"command.busy.value\"\n [matTooltip]=\"tooltipModel.value\">\n <aup-command-face [class]=\"alignFace\" [faces]=\"faces.value\"></aup-command-face>\n </button>\n </ng-container>\n </ng-container>\n</ng-container>\n",
|
|
743
|
-
styles: [":host{display:inline-flex;flex-direction:row;justify-content:stretch}:host.centered button{text-align:center}:host.start button{text-align:start}:host.end button{text-align:end}button{flex:1}"]
|
|
950
|
+
styles: [":host{display:inline-flex;flex-direction:row;justify-content:stretch}:host.centered button{text-align:center}:host.start button{text-align:start}:host.end button{text-align:end}button{flex:1}\n"]
|
|
744
951
|
},] }
|
|
745
952
|
];
|
|
746
953
|
CommandComponent.ctorParameters = () => [
|
|
@@ -801,7 +1008,7 @@ class AbstractPopupMenuComponent extends PopupAwareComponent {
|
|
|
801
1008
|
constructor(element, parent) {
|
|
802
1009
|
super(element, parent);
|
|
803
1010
|
this._unorderedChildren = new MutableListModel();
|
|
804
|
-
this.faceModelDelegate = new DelegatingValueModel();
|
|
1011
|
+
this.faceModelDelegate = this.registerDisposable(new DelegatingValueModel());
|
|
805
1012
|
this.xPosition = 'after';
|
|
806
1013
|
this.yPosition = 'below';
|
|
807
1014
|
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
@@ -912,10 +1119,22 @@ __decorate([
|
|
|
912
1119
|
var TrackBy;
|
|
913
1120
|
(function (TrackBy) {
|
|
914
1121
|
TrackBy.byIndex = (index, item) => index;
|
|
1122
|
+
/**
|
|
1123
|
+
* @deprecated use #track(MyType).by("property") instead.
|
|
1124
|
+
* @param property
|
|
1125
|
+
*/
|
|
915
1126
|
function trackByProperty(property) {
|
|
916
1127
|
return (index, item) => item[property];
|
|
917
1128
|
}
|
|
918
1129
|
TrackBy.trackByProperty = trackByProperty;
|
|
1130
|
+
function track(type) {
|
|
1131
|
+
return {
|
|
1132
|
+
by(property) {
|
|
1133
|
+
return (index, item) => item[property];
|
|
1134
|
+
}
|
|
1135
|
+
};
|
|
1136
|
+
}
|
|
1137
|
+
TrackBy.track = track;
|
|
919
1138
|
})(TrackBy || (TrackBy = {}));
|
|
920
1139
|
|
|
921
1140
|
class CommandContainer extends GarbageCollector {
|
|
@@ -963,7 +1182,7 @@ ToolBarComponent.decorators = [
|
|
|
963
1182
|
selector: 'aup-tool-bar',
|
|
964
1183
|
template: '<div class="toolbar-content"><ng-content></ng-content></div>',
|
|
965
1184
|
encapsulation: ViewEncapsulation.None,
|
|
966
|
-
styles: [":host{display:inline-block}.toolbar-content{display:inline-flex;flex-direction:row;align-items:center}.toolbar-content>aup-separator{align-self:stretch;margin:4px 0 4px 8px}.toolbar-content>aup-flex{flex:1}.toolbar-content>*+*{margin-left:8px}"]
|
|
1185
|
+
styles: [":host{display:inline-block}.toolbar-content{display:inline-flex;flex-direction:row;align-items:center}.toolbar-content>aup-separator{align-self:stretch;margin:4px 0 4px 8px}.toolbar-content>aup-flex{flex:1}.toolbar-content>*+*{margin-left:8px}\n"]
|
|
967
1186
|
},] }
|
|
968
1187
|
];
|
|
969
1188
|
ToolBarComponent.ctorParameters = () => [];
|
|
@@ -1044,7 +1263,7 @@ __decorate([
|
|
|
1044
1263
|
class PopupMenuRendererComponent extends DisposableComponent {
|
|
1045
1264
|
constructor() {
|
|
1046
1265
|
super();
|
|
1047
|
-
this._childList = new DelegatingListModel();
|
|
1266
|
+
this._childList = this.registerDisposable(new DelegatingListModel());
|
|
1048
1267
|
this.commandFired = new EventEmitter();
|
|
1049
1268
|
this.TrackBy = TrackBy;
|
|
1050
1269
|
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
@@ -1138,7 +1357,7 @@ EmptyStateComponent.decorators = [
|
|
|
1138
1357
|
<ng-content></ng-content>
|
|
1139
1358
|
</div>
|
|
1140
1359
|
`,
|
|
1141
|
-
styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:center}.container{display:flex;flex-direction:column;align-items:stretch;padding:var(--aup-default-padding);border:2px dashed rgba(0,0,0,.2);border-radius:5px;font-size:14px;font-weight:300}"]
|
|
1360
|
+
styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:center}.container{display:flex;flex-direction:column;align-items:stretch;padding:var(--aup-default-padding);border:2px dashed rgba(0,0,0,.2);border-radius:5px;font-size:14px;font-weight:300}\n"]
|
|
1142
1361
|
},] }
|
|
1143
1362
|
];
|
|
1144
1363
|
EmptyStateComponent.ctorParameters = () => [];
|
|
@@ -1166,7 +1385,7 @@ FocusContainerComponent.decorators = [
|
|
|
1166
1385
|
providers: [
|
|
1167
1386
|
{ provide: FocusManager }
|
|
1168
1387
|
],
|
|
1169
|
-
styles: [":host{display:block}"]
|
|
1388
|
+
styles: [":host{display:block}\n"]
|
|
1170
1389
|
},] }
|
|
1171
1390
|
];
|
|
1172
1391
|
FocusContainerComponent.ctorParameters = () => [
|
|
@@ -1222,6 +1441,7 @@ class AbstractInputComponent extends DisposableComponent {
|
|
|
1222
1441
|
constructor() {
|
|
1223
1442
|
super();
|
|
1224
1443
|
this.onValueEditedListeners = new EventListenerList();
|
|
1444
|
+
this.userFloatLabel = 'always'; // TODO: make this an injectable default
|
|
1225
1445
|
this.dense = false;
|
|
1226
1446
|
// TODO: fix this.
|
|
1227
1447
|
// tslint:disable-next-line:no-output-native
|
|
@@ -1481,8 +1701,8 @@ class AutocompleteInputComponent extends AbstractValueInputComponent {
|
|
|
1481
1701
|
AutocompleteInputComponent.decorators = [
|
|
1482
1702
|
{ type: Component, args: [{
|
|
1483
1703
|
selector: 'aup-autocomplete-input',
|
|
1484
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input type=\"string\"\n matInput\n [matAutocomplete]=\"autocomplete\"\n placeholder=\"{{placeholder}}\"\n [ngModel]=\"componentValueModel.value\"\n (ngModelChange)=\"updateFilter($event)\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <mat-autocomplete #autocomplete [displayWith]=\"optionLabelFormat\" [autoActiveFirstOption]=\"true\" (optionSelected)=\"onSelect($event)\">\n <mat-option *ngFor=\"let option of filteredOptions.value; let i = index\"\n [value]=\"option\"\n >{{formatOption(option)}}</mat-option>\n <mat-option *ngIf=\"allowNil\">{{placeholder}}</mat-option>\n </mat-autocomplete>\n\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n",
|
|
1485
|
-
styles: [":host{display:inline-block}mat-form-field{width:100%}"]
|
|
1704
|
+
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input type=\"string\"\n matInput\n [matAutocomplete]=\"autocomplete\"\n placeholder=\"{{placeholder}}\"\n [ngModel]=\"componentValueModel.value\"\n (ngModelChange)=\"updateFilter($event)\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <mat-autocomplete #autocomplete [displayWith]=\"optionLabelFormat\" [autoActiveFirstOption]=\"true\" (optionSelected)=\"onSelect($event)\">\n <mat-option *ngFor=\"let option of filteredOptions.value; let i = index\"\n [value]=\"option\"\n >{{formatOption(option)}}</mat-option>\n <mat-option *ngIf=\"allowNil\">{{placeholder}}</mat-option>\n </mat-autocomplete>\n\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n<div class=\"width-strut\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <div>{{placeholder}}</div>\n <div class=\"item\" *ngFor=\"let item of options\">{{optionLabelFormat(item)}}</div>\n</div>\n",
|
|
1705
|
+
styles: [":host{display:inline-block}mat-form-field{width:100%}.width-strut{display:inline-block;height:0;max-height:0;width:auto;visibility:hidden;overflow:hidden;padding-right:35px}.width-strut mat-label{font-size:75%}.width-strut>.item{font-size:16px;padding-left:0}\n"]
|
|
1486
1706
|
},] }
|
|
1487
1707
|
];
|
|
1488
1708
|
AutocompleteInputComponent.ctorParameters = () => [];
|
|
@@ -1518,7 +1738,7 @@ CheckboxInputComponent.decorators = [
|
|
|
1518
1738
|
{ type: Component, args: [{
|
|
1519
1739
|
selector: 'aup-checkbox-input',
|
|
1520
1740
|
template: "<!-- TODO: add focus binding -->\n<mat-checkbox\n [(ngModel)]=\"componentValueModel.value\"\n [color]=\"color\"\n [labelPosition]=\"labelPosition\"\n [disabled]=\"!isEnabled()\"\n>{{label}}</mat-checkbox>\n<mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n<mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n",
|
|
1521
|
-
styles: [":host{display:inline-flex;flex-direction:column;padding:24px 0 16px}:host.dense{padding:6px 0 2px}mat-
|
|
1741
|
+
styles: [":host{display:inline-flex;flex-direction:column;padding:24px 0 16px}:host.dense{padding:6px 0 2px}mat-hint,mat-error{margin-top:4px;margin-left:24px;font-size:12px;font-weight:400;line-height:13.5px}\n"]
|
|
1522
1742
|
},] }
|
|
1523
1743
|
];
|
|
1524
1744
|
CheckboxInputComponent.ctorParameters = () => [];
|
|
@@ -1545,8 +1765,8 @@ class MultipleSelectInputComponent extends AbstractListInputComponent {
|
|
|
1545
1765
|
MultipleSelectInputComponent.decorators = [
|
|
1546
1766
|
{ type: Component, args: [{
|
|
1547
1767
|
selector: 'aup-multiple-select-input',
|
|
1548
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <mat-select placeholder=\"{{placeholder}}\"\n multiple\n [(ngModel)]=\"componentListModel.value\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <mat-option *ngFor=\"let option of optionsModel.value; let i = index\" [value]=\"option\">\n <ng-container *ngIf=\"!optionTemplateRef\">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf=\"optionTemplateRef\"\n [ngTemplateOutlet]=\"optionTemplateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: option, index: i }\"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n",
|
|
1549
|
-
styles: [":host{display:inline-block}mat-form-field{width:100%}"]
|
|
1768
|
+
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <mat-select placeholder=\"{{placeholder}}\"\n multiple\n [(ngModel)]=\"componentListModel.value\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <mat-option *ngFor=\"let option of optionsModel.value; let i = index\" [value]=\"option\">\n <ng-container *ngIf=\"!optionTemplateRef\">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf=\"optionTemplateRef\"\n [ngTemplateOutlet]=\"optionTemplateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: option, index: i }\"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n<div class=\"width-strut\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <div>{{placeholder}}</div>\n <div class=\"item\" *ngFor=\"let item of options\">{{optionLabelFormat(item)}}</div>\n</div>\n",
|
|
1769
|
+
styles: [":host{display:inline-block}mat-form-field{width:100%}.width-strut{display:inline-block;height:0;max-height:0;width:auto;visibility:hidden;overflow:hidden;padding-right:35px}.width-strut mat-label{font-size:75%}.width-strut>.item{font-size:16px;padding-left:30px}\n"]
|
|
1550
1770
|
},] }
|
|
1551
1771
|
];
|
|
1552
1772
|
MultipleSelectInputComponent.ctorParameters = () => [];
|
|
@@ -1627,8 +1847,8 @@ class SelectInputComponent extends AbstractValueInputComponent {
|
|
|
1627
1847
|
SelectInputComponent.decorators = [
|
|
1628
1848
|
{ type: Component, args: [{
|
|
1629
1849
|
selector: 'aup-select-input',
|
|
1630
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <mat-select placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"componentValueModel.value\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <mat-option *ngIf=\"allowNil\">\n <ng-container *ngIf=\"!nilOptionTemplateRef\">{{placeholder}}</ng-container>\n <ng-container *ngIf=\"nilOptionTemplateRef\" [ngTemplateOutlet]=\"nilOptionTemplateRef\"></ng-container>\n </mat-option>\n <mat-option *ngFor=\"let option of optionsModel.value; let i = index\" [value]=\"option\">\n <ng-container *ngIf=\"!optionTemplateRef\">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf=\"optionTemplateRef\"\n [ngTemplateOutlet]=\"optionTemplateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: option, index: i }\"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n",
|
|
1631
|
-
styles: [":host{display:inline-block}mat-form-field{width:100%}"]
|
|
1850
|
+
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <mat-select placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"componentValueModel.value\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <mat-option *ngIf=\"allowNil\">\n <ng-container *ngIf=\"!nilOptionTemplateRef\">{{placeholder}}</ng-container>\n <ng-container *ngIf=\"nilOptionTemplateRef\" [ngTemplateOutlet]=\"nilOptionTemplateRef\"></ng-container>\n </mat-option>\n <mat-option *ngFor=\"let option of optionsModel.value; let i = index\" [value]=\"option\">\n <ng-container *ngIf=\"!optionTemplateRef\">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf=\"optionTemplateRef\"\n [ngTemplateOutlet]=\"optionTemplateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: option, index: i }\"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n<div class=\"width-strut\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <div class=\"item\" *ngFor=\"let item of options\">{{optionLabelFormat(item)}}</div>\n</div>\n",
|
|
1851
|
+
styles: [":host{display:inline-block}mat-form-field{width:100%}.width-strut{display:inline-block;height:0;max-height:0;width:auto;visibility:hidden;overflow:hidden;padding-right:35px}.width-strut mat-label{font-size:75%}.width-strut>.item{font-size:16px;padding-left:0}\n"]
|
|
1632
1852
|
},] }
|
|
1633
1853
|
];
|
|
1634
1854
|
SelectInputComponent.ctorParameters = () => [];
|
|
@@ -1666,7 +1886,7 @@ StringInputComponent.decorators = [
|
|
|
1666
1886
|
{ type: Component, args: [{
|
|
1667
1887
|
selector: 'aup-string-input',
|
|
1668
1888
|
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input matInput\n placeholder=\"{{placeholder}}\"\n [attr.autocomplete]=\"autocomplete\"\n [(ngModel)]=\"componentValueModel.value\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n >\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n <aup-icon *ngIf=\"iconPrefix\" matPrefix [icon]=\"iconPrefix\"></aup-icon>\n <button mat-button mat-icon-button matSuffix *ngIf=\"enableClear\" [pectinCommand]=\"clearCommand\">\n <aup-icon icon=\"mat:close\"></aup-icon>\n </button>\n</mat-form-field>\n\n",
|
|
1669
|
-
styles: ["button[disabled]{visibility:hidden}"]
|
|
1889
|
+
styles: ["button[disabled]{visibility:hidden}\n"]
|
|
1670
1890
|
},] }
|
|
1671
1891
|
];
|
|
1672
1892
|
StringInputComponent.ctorParameters = () => [];
|
|
@@ -1700,7 +1920,7 @@ TextInputComponent.decorators = [
|
|
|
1700
1920
|
{ type: Component, args: [{
|
|
1701
1921
|
selector: 'aup-text-input',
|
|
1702
1922
|
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <textarea matInput\n placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"componentValueModel.value\"\n [disabled]=\"!enabled.value\"\n (keydown.enter)=\"notifyEnterKey()\"\n (keydown.escape)=\"notifyEscapeKey()\"\n [pectinFocusBinding]=\"focusContext\"\n [errorStateMatcher]=\"errorStateMatcher\"\n [rows]=\"rows\"\n [cols]=\"cols\"\n >\n </textarea>\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n\n",
|
|
1703
|
-
styles: ["button[disabled]{visibility:hidden}textarea{overflow:auto}"]
|
|
1923
|
+
styles: ["button[disabled]{visibility:hidden}textarea{overflow:auto}\n"]
|
|
1704
1924
|
},] }
|
|
1705
1925
|
];
|
|
1706
1926
|
TextInputComponent.ctorParameters = () => [];
|
|
@@ -1739,7 +1959,7 @@ IconComponent.decorators = [
|
|
|
1739
1959
|
{ type: Component, args: [{
|
|
1740
1960
|
selector: 'aup-icon',
|
|
1741
1961
|
template: "<ng-container [ngSwitch]=\"prefix\">\n\n <mat-icon *ngSwitchCase=\"iconPrefix.SVG\"\n [svgIcon]=\"suffix\"\n class=\"svgIcon\">\n </mat-icon>\n\n <mat-icon *ngSwitchCase=\"iconPrefix.MATERIAL\">\n {{suffix}}\n </mat-icon>\n\n <div *ngSwitchCase=\"iconPrefix.FONT_AWESOME\"\n class=\"faIconWrapper\">\n <fa-icon [icon]=\"suffix\">\n </fa-icon>\n </div>\n\n <mat-icon *ngSwitchDefault\n [matTooltip]=\"errorMessage\">\n bug_report\n </mat-icon>\n\n</ng-container>\n\n",
|
|
1742
|
-
styles: [":host{display:inline-flex;width:24px}fa-icon{vertical-align:middle}.faIconWrapper{text-align:center}.
|
|
1962
|
+
styles: [":host{display:inline-flex;width:24px}fa-icon{vertical-align:middle}.faIconWrapper{text-align:center;width:24px;height:24px}.svgIcon{width:24px;height:24px}:host(.mat-chip-remove) mat-icon{font-size:18px}mat-icon{width:inherit;height:inherit}\n"]
|
|
1743
1963
|
},] }
|
|
1744
1964
|
];
|
|
1745
1965
|
IconComponent.propDecorators = {
|
|
@@ -1753,6 +1973,48 @@ IconComponent.propDecorators = {
|
|
|
1753
1973
|
});
|
|
1754
1974
|
})(IconComponent || (IconComponent = {}));
|
|
1755
1975
|
|
|
1976
|
+
class LoadingContainerComponent extends GarbageCollector {
|
|
1977
|
+
constructor() {
|
|
1978
|
+
super();
|
|
1979
|
+
}
|
|
1980
|
+
get state() {
|
|
1981
|
+
return this.loadingModel.value ? "loaded" : "loading";
|
|
1982
|
+
}
|
|
1983
|
+
ngOnInit() {
|
|
1984
|
+
}
|
|
1985
|
+
}
|
|
1986
|
+
LoadingContainerComponent.decorators = [
|
|
1987
|
+
{ type: Component, args: [{
|
|
1988
|
+
selector: 'aup-loading-container',
|
|
1989
|
+
template: "<ng-content *ngIf=\"!loadingModel.value\"></ng-content>\n<section *ngIf=\"loadingModel.value\" class=\"loading-indicator-overlay\">\n <div class=\"loading-message\">\n <p>{{messageModel.value}}</p>\n <mat-progress-bar mode=\"indeterminate\"></mat-progress-bar>\n </div>\n</section>\n",
|
|
1990
|
+
styles: [":host{display:block;position:relative}section.loading-indicator-overlay{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;flex-direction:column;align-items:center;justify-content:center}.loading-message{display:inline-block;text-align:center;width:10em}\n"]
|
|
1991
|
+
},] }
|
|
1992
|
+
];
|
|
1993
|
+
LoadingContainerComponent.ctorParameters = () => [];
|
|
1994
|
+
LoadingContainerComponent.propDecorators = {
|
|
1995
|
+
loadingModel: [{ type: Input }],
|
|
1996
|
+
loading: [{ type: Input }],
|
|
1997
|
+
messageModel: [{ type: Input }],
|
|
1998
|
+
message: [{ type: Input }],
|
|
1999
|
+
state: [{ type: HostBinding, args: ["class",] }]
|
|
2000
|
+
};
|
|
2001
|
+
__decorate([
|
|
2002
|
+
TrackExternal(),
|
|
2003
|
+
__metadata("design:type", ValueModel)
|
|
2004
|
+
], LoadingContainerComponent.prototype, "loadingModel", void 0);
|
|
2005
|
+
__decorate([
|
|
2006
|
+
StoreInValueModel("loadingModel"),
|
|
2007
|
+
__metadata("design:type", Boolean)
|
|
2008
|
+
], LoadingContainerComponent.prototype, "loading", void 0);
|
|
2009
|
+
__decorate([
|
|
2010
|
+
TrackExternal(),
|
|
2011
|
+
__metadata("design:type", ValueModel)
|
|
2012
|
+
], LoadingContainerComponent.prototype, "messageModel", void 0);
|
|
2013
|
+
__decorate([
|
|
2014
|
+
StoreInValueModel("messageModel"),
|
|
2015
|
+
__metadata("design:type", String)
|
|
2016
|
+
], LoadingContainerComponent.prototype, "message", void 0);
|
|
2017
|
+
|
|
1756
2018
|
class NoopComponent {
|
|
1757
2019
|
constructor() {
|
|
1758
2020
|
}
|
|
@@ -1761,7 +2023,7 @@ NoopComponent.decorators = [
|
|
|
1761
2023
|
{ type: Component, args: [{
|
|
1762
2024
|
selector: 'aup-noop',
|
|
1763
2025
|
template: "",
|
|
1764
|
-
styles: [":host{display:block}"]
|
|
2026
|
+
styles: [":host{display:block}\n"]
|
|
1765
2027
|
},] }
|
|
1766
2028
|
];
|
|
1767
2029
|
NoopComponent.ctorParameters = () => [];
|
|
@@ -1775,14 +2037,18 @@ ScrollContainerComponent.decorators = [
|
|
|
1775
2037
|
{ type: Component, args: [{
|
|
1776
2038
|
selector: 'aup-scroll-container',
|
|
1777
2039
|
template: "<div class=\"container\" cdkScrollable>\n <ng-content></ng-content>\n</div>\n",
|
|
1778
|
-
styles: [":host{display:flex;flex-direction:column;min-height:0;align-items:stretch}.container{display:flex;flex-direction:column;flex:1;flex-basis:0;overflow-y:scroll;align-items:stretch}"]
|
|
2040
|
+
styles: [":host{display:flex;flex-direction:column;min-height:0;align-items:stretch}.container{display:flex;flex-direction:column;flex:1;flex-basis:0;overflow-y:scroll;align-items:stretch}\n"]
|
|
1779
2041
|
},] }
|
|
1780
2042
|
];
|
|
1781
2043
|
ScrollContainerComponent.ctorParameters = () => [];
|
|
1782
2044
|
|
|
1783
|
-
class SectionHeaderComponent {
|
|
2045
|
+
class SectionHeaderComponent extends DisposableComponent {
|
|
1784
2046
|
constructor() {
|
|
1785
|
-
|
|
2047
|
+
super();
|
|
2048
|
+
// readonly i18n = I18nMarsUi.components.layout.header;
|
|
2049
|
+
this.size = 'medium';
|
|
2050
|
+
this.borderTop = false;
|
|
2051
|
+
this.borderBottom = false;
|
|
1786
2052
|
}
|
|
1787
2053
|
ngOnInit() {
|
|
1788
2054
|
}
|
|
@@ -1790,13 +2056,15 @@ class SectionHeaderComponent {
|
|
|
1790
2056
|
SectionHeaderComponent.decorators = [
|
|
1791
2057
|
{ type: Component, args: [{
|
|
1792
2058
|
selector: 'aup-section-header',
|
|
1793
|
-
template: "<ng-content></ng-content>\n",
|
|
1794
|
-
styles: [":host{--
|
|
2059
|
+
template: "<span class=\"container-start\"><ng-content select=\"[header-start]\"></ng-content><ng-content></ng-content></span>\n<span class=\"container-middle\"><ng-content select=\"[header-center]\"></ng-content></span>\n<span class=\"container-end\"><ng-content select=\"[header-end]\"></ng-content></span>\n",
|
|
2060
|
+
styles: [":host{display:flex;flex-direction:row;align-items:center;--resolved-padding: var(--padding, var(--default-padding));--resolved-padding-right: var(--padding-right, calc(var(--default-padding)/2));padding-left:var(--resolved-padding);padding-right:var(--resolved-padding-right);box-sizing:border-box}:host.has-back-button{padding-left:0}:host.toolbar{height:56px;min-height:56px}:host.toolbar span{font-weight:500;font-size:18px;color:#000000ab}:host.large{height:48px;min-height:48px}:host.large span{font-weight:500;font-size:14px;color:#000000ab}:host.medium{height:48px;min-height:48px}:host.medium span{font-weight:500;font-size:13px;color:#000000ab}:host.small{height:30px;min-height:30px}:host.small span{font-weight:300;font-size:12px;color:#000000ab}:host.border-top{border-top:var(--pinstripe-border)}:host.border-bottom{border-bottom:var(--pinstripe-border)}span{white-space:nowrap;display:inline-flex;flex-direction:row;align-items:center}span.container-start{justify-content:flex-start}span.container-middle{justify-content:center;flex:1;width:0;overflow:hidden}span.container-end{justify-content:flex-end}\n"]
|
|
1795
2061
|
},] }
|
|
1796
2062
|
];
|
|
1797
2063
|
SectionHeaderComponent.ctorParameters = () => [];
|
|
1798
2064
|
SectionHeaderComponent.propDecorators = {
|
|
1799
|
-
|
|
2065
|
+
size: [{ type: Input }, { type: HostBinding, args: ['class',] }],
|
|
2066
|
+
borderTop: [{ type: Input }, { type: HostBinding, args: ['class.border-top',] }],
|
|
2067
|
+
borderBottom: [{ type: Input }, { type: HostBinding, args: ['class.border-bottom',] }]
|
|
1800
2068
|
};
|
|
1801
2069
|
|
|
1802
2070
|
class SwitchCaseOption {
|
|
@@ -1901,7 +2169,7 @@ SwitchCaseComponent.decorators = [
|
|
|
1901
2169
|
{ type: Component, args: [{
|
|
1902
2170
|
selector: 'aup-switch-case',
|
|
1903
2171
|
template: "<mat-tab-group class=\"content-wrapper\" no-tab-header full-height-tabs [selectedIndex]=\"selectedIndex\">\n <mat-tab *ngFor=\"let option of switchCaseOptions\">\n <ng-template [ngTemplateOutlet]=\"option.templateRef\"></ng-template>\n </mat-tab>\n</mat-tab-group>\n\n\n",
|
|
1904
|
-
styles: [":host{display:flex;flex-direction:column;align-items:stretch}mat-tab-group{flex:1}"]
|
|
2172
|
+
styles: [":host{display:flex;flex-direction:column;align-items:stretch}mat-tab-group{flex:1}\n"]
|
|
1905
2173
|
},] }
|
|
1906
2174
|
];
|
|
1907
2175
|
SwitchCaseComponent.ctorParameters = () => [
|
|
@@ -2160,17 +2428,24 @@ class EditSession extends GarbageCollector {
|
|
|
2160
2428
|
class EditRowControls extends DisposableComponent {
|
|
2161
2429
|
constructor() {
|
|
2162
2430
|
super();
|
|
2163
|
-
this.saveCommand = Command.create(() => {
|
|
2164
|
-
this.editSession.saveCommand.execute(
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
});
|
|
2170
|
-
});
|
|
2431
|
+
this.saveCommand = Command.create(() => __awaiter(this, void 0, void 0, function* () {
|
|
2432
|
+
const finished = yield this.editSession.saveCommand.execute();
|
|
2433
|
+
if (finished) {
|
|
2434
|
+
this.editSession.dispose();
|
|
2435
|
+
}
|
|
2436
|
+
}));
|
|
2171
2437
|
this.cancelCommand = Command.create(() => {
|
|
2172
2438
|
this.editSession.dispose();
|
|
2173
|
-
});
|
|
2439
|
+
}).disableWhile(this.saveCommand.busy);
|
|
2440
|
+
}
|
|
2441
|
+
set editSession(session) {
|
|
2442
|
+
if (session) {
|
|
2443
|
+
session.form.disableWhile(this.saveCommand.busy);
|
|
2444
|
+
}
|
|
2445
|
+
this._session = session;
|
|
2446
|
+
}
|
|
2447
|
+
get editSession() {
|
|
2448
|
+
return this._session;
|
|
2174
2449
|
}
|
|
2175
2450
|
ngOnInit() {
|
|
2176
2451
|
}
|
|
@@ -2183,7 +2458,7 @@ EditRowControls.decorators = [
|
|
|
2183
2458
|
{ type: Component, args: [{
|
|
2184
2459
|
selector: 'aup-row-editor-controls',
|
|
2185
2460
|
template: "<button *ngIf=\"!editSession\" mat-icon-button [pectinCommand]=\"editRowCommand\" class=\"edit-button\"><aup-icon icon=\"mat:edit\"></aup-icon></button>\n<button *ngIf=\"editSession\" mat-icon-button [pectinCommand]=\"saveCommand\"><aup-icon icon=\"mat:done\"></aup-icon></button>\n<button *ngIf=\"editSession\" mat-icon-button [pectinCommand]=\"cancelCommand\"><aup-icon icon=\"mat:clear\"></aup-icon></button>\n",
|
|
2186
|
-
styles: [":host{display:block;width:80px}.edit-button{visibility:hidden}:host-context(tr:hover) .edit-button{visibility:visible}"]
|
|
2461
|
+
styles: [":host{display:block;width:80px}.edit-button{visibility:hidden}:host-context(tr:hover) .edit-button{visibility:visible}\n"]
|
|
2187
2462
|
},] }
|
|
2188
2463
|
];
|
|
2189
2464
|
EditRowControls.ctorParameters = () => [];
|
|
@@ -2254,14 +2529,19 @@ const noop = () => {
|
|
|
2254
2529
|
};
|
|
2255
2530
|
const ɵ0 = noop;
|
|
2256
2531
|
const CELL_RENDERER_COMPONENT_ROW_CACHE = Symbol('aup-cell-renderer:row-data-cache');
|
|
2257
|
-
|
|
2532
|
+
const DEFAULT_TEXT_SEARCH_PREDICATE = (row, text) => false;
|
|
2533
|
+
const ɵ1 = DEFAULT_TEXT_SEARCH_PREDICATE;
|
|
2534
|
+
class ColumnModel extends GarbageCollector {
|
|
2258
2535
|
constructor(columnId, textPropertiesProvider) {
|
|
2536
|
+
super();
|
|
2259
2537
|
this.columnId = columnId;
|
|
2260
2538
|
this.textPropertiesProvider = textPropertiesProvider;
|
|
2261
2539
|
this._enableRowSelection = true;
|
|
2262
2540
|
this._flex = false;
|
|
2263
|
-
this._defaultVisibility = new DelegatingValueModel().withDefault(true);
|
|
2264
|
-
this._visible = new DelegatingValueModel().withDefault(this._defaultVisibility);
|
|
2541
|
+
this._defaultVisibility = this.registerDisposable(new DelegatingValueModel().withDefault(true));
|
|
2542
|
+
this._visible = this.registerDisposable(new DelegatingValueModel().withDefault(this._defaultVisibility));
|
|
2543
|
+
this._columnModelTextSearchPredicate = undefined;
|
|
2544
|
+
this._cellRendererTextSearchPredicate = undefined;
|
|
2265
2545
|
this.installHeaderRenderer();
|
|
2266
2546
|
this.dasherisedColumnId = Stringy.from(columnId).dasherize().toString();
|
|
2267
2547
|
}
|
|
@@ -2290,6 +2570,17 @@ class ColumnModel {
|
|
|
2290
2570
|
getDefaultHeaderText() {
|
|
2291
2571
|
return this.columnId;
|
|
2292
2572
|
}
|
|
2573
|
+
get isTextMatch() {
|
|
2574
|
+
return this._columnModelTextSearchPredicate || this._cellRendererTextSearchPredicate || DEFAULT_TEXT_SEARCH_PREDICATE;
|
|
2575
|
+
}
|
|
2576
|
+
/**
|
|
2577
|
+
* Sets the predicate to use when checking if the specified row is a text match for this column.
|
|
2578
|
+
* @param predicate
|
|
2579
|
+
*/
|
|
2580
|
+
useTextSearchPredicate(predicate) {
|
|
2581
|
+
this._columnModelTextSearchPredicate = predicate;
|
|
2582
|
+
return this;
|
|
2583
|
+
}
|
|
2293
2584
|
getColumnTextProperties() {
|
|
2294
2585
|
return this._columnTextProperties || this.textPropertiesProvider();
|
|
2295
2586
|
}
|
|
@@ -2340,6 +2631,12 @@ class ColumnModel {
|
|
|
2340
2631
|
}
|
|
2341
2632
|
onRendererAttached(host, component) {
|
|
2342
2633
|
this._cellRendererPortalRef.onPortalAttached(host, component);
|
|
2634
|
+
if (___default.isFunction(component === null || component === void 0 ? void 0 : component.matches)) {
|
|
2635
|
+
this._cellRendererTextSearchPredicate = (row, text) => component.matches(row, text);
|
|
2636
|
+
}
|
|
2637
|
+
else {
|
|
2638
|
+
this._cellRendererTextSearchPredicate = undefined;
|
|
2639
|
+
}
|
|
2343
2640
|
}
|
|
2344
2641
|
// @Trace()
|
|
2345
2642
|
onEditorAttached(host, component) {
|
|
@@ -2372,8 +2669,11 @@ class PropertyColumnModel extends ColumnModel {
|
|
|
2372
2669
|
constructor(id, property, defaults) {
|
|
2373
2670
|
super(id, defaults);
|
|
2374
2671
|
this.property = property;
|
|
2375
|
-
this._format = (value) => value;
|
|
2672
|
+
this._format = (value) => value === null || value === void 0 ? void 0 : value.toString();
|
|
2376
2673
|
this.cellRenderer(DefaultCellRendererComponent);
|
|
2674
|
+
this.useTextSearchPredicate((row, regex) => {
|
|
2675
|
+
return regex.test(this._format(row[this.property]));
|
|
2676
|
+
});
|
|
2377
2677
|
}
|
|
2378
2678
|
cellRenderer(componentType, onComponentInitOrOptions) {
|
|
2379
2679
|
this.configureCellRenderer(new ComponentCellRendererPortalRef(componentType, (component, rowData, firstTime) => {
|
|
@@ -2388,9 +2688,6 @@ class PropertyColumnModel extends ColumnModel {
|
|
|
2388
2688
|
}
|
|
2389
2689
|
}
|
|
2390
2690
|
component.value = this._format(rowData.row[this.property]);
|
|
2391
|
-
if (!___default.isFunction(onComponentInitOrOptions) && ___default.isFunction(onComponentInitOrOptions === null || onComponentInitOrOptions === void 0 ? void 0 : onComponentInitOrOptions.onRowUpdate)) {
|
|
2392
|
-
onComponentInitOrOptions.onRowUpdate(component, rowData.row);
|
|
2393
|
-
}
|
|
2394
2691
|
}));
|
|
2395
2692
|
return this;
|
|
2396
2693
|
}
|
|
@@ -2460,6 +2757,9 @@ class ListPropertyColumnModel extends ColumnModel {
|
|
|
2460
2757
|
this.property = property;
|
|
2461
2758
|
this._format = (value) => value.map(v => v === null || v === void 0 ? void 0 : v.toString()).join(', ');
|
|
2462
2759
|
this.cellRenderer(DefaultCellRendererComponent);
|
|
2760
|
+
this.useTextSearchPredicate((row, regex) => {
|
|
2761
|
+
return regex.test(this._format(row[this.property]));
|
|
2762
|
+
});
|
|
2463
2763
|
}
|
|
2464
2764
|
cellRenderer(componentType) {
|
|
2465
2765
|
this.configureCellRenderer(new ComponentCellRendererPortalRef(componentType, (component, rowData) => {
|
|
@@ -2521,7 +2821,7 @@ class CustomValueColumnModel extends ColumnModel {
|
|
|
2521
2821
|
}
|
|
2522
2822
|
}
|
|
2523
2823
|
class EditorControlColumnModel extends ColumnModel {
|
|
2524
|
-
constructor(columnId,
|
|
2824
|
+
constructor(columnId, saveCommandFactory, defaults) {
|
|
2525
2825
|
super(columnId, defaults);
|
|
2526
2826
|
this.cellRenderer(EditRowControls);
|
|
2527
2827
|
}
|
|
@@ -2792,6 +3092,7 @@ class ColumnListModel extends AbstractComputedListModel {
|
|
|
2792
3092
|
if (this.hasColumn(column.columnId)) {
|
|
2793
3093
|
lang.illegalState(`Column with id=${column.columnId} already exists`);
|
|
2794
3094
|
}
|
|
3095
|
+
this.registerDisposable(column);
|
|
2795
3096
|
this.runInTransaction(() => {
|
|
2796
3097
|
if (!_.isNil(index)) {
|
|
2797
3098
|
this._allColumns.insert(index, column);
|
|
@@ -2799,7 +3100,7 @@ class ColumnListModel extends AbstractComputedListModel {
|
|
|
2799
3100
|
else {
|
|
2800
3101
|
this._allColumns.push(column);
|
|
2801
3102
|
}
|
|
2802
|
-
this.trackSource(column.visible);
|
|
3103
|
+
this.registerDisposable(this.trackSource(column.visible));
|
|
2803
3104
|
});
|
|
2804
3105
|
return column;
|
|
2805
3106
|
}
|
|
@@ -2819,7 +3120,7 @@ class RowClass {
|
|
|
2819
3120
|
class AbstractTableModel extends GarbageCollector {
|
|
2820
3121
|
constructor() {
|
|
2821
3122
|
super();
|
|
2822
|
-
this._dataSource = new DelegatingListModel();
|
|
3123
|
+
this._dataSource = this.registerDisposable(new DelegatingListModel());
|
|
2823
3124
|
this._columnList = this.registerDisposable(new ColumnListModel());
|
|
2824
3125
|
this._editorSessions = new MutableListModel();
|
|
2825
3126
|
this.rowClassNamePredicates = [];
|
|
@@ -2840,6 +3141,12 @@ class AbstractTableModel extends GarbageCollector {
|
|
|
2840
3141
|
this.lastVisibleColumn = chain(this._columnList).last();
|
|
2841
3142
|
this.rowSelectionDisabledOnAllColumns = chain(this._columnList).select(column => column.isRowSelectionEnabled()).count().equals(0);
|
|
2842
3143
|
}
|
|
3144
|
+
findMatchingColumns(row, regex) {
|
|
3145
|
+
return this.columns.value.filter(c => c.isTextMatch(row, regex));
|
|
3146
|
+
}
|
|
3147
|
+
hasMatchingColumn(row, regex) {
|
|
3148
|
+
return !!this.columns.value.find(c => c.isTextMatch(row, regex));
|
|
3149
|
+
}
|
|
2843
3150
|
setDataSource(sourceOfTruth) {
|
|
2844
3151
|
this._dataSource.setDelegate(sourceOfTruth);
|
|
2845
3152
|
}
|
|
@@ -2874,10 +3181,13 @@ class AbstractTableModel extends GarbageCollector {
|
|
|
2874
3181
|
}
|
|
2875
3182
|
return selectionColumnModel;
|
|
2876
3183
|
}
|
|
2877
|
-
addEditControls(
|
|
2878
|
-
this.
|
|
3184
|
+
addEditControls(saveCommandFactory, formFactory) {
|
|
3185
|
+
this.saveCommandFactory = saveCommandFactory;
|
|
3186
|
+
if (_.isFunction(formFactory)) {
|
|
3187
|
+
this._createForm = formFactory;
|
|
3188
|
+
}
|
|
2879
3189
|
const columnId = 'editControls';
|
|
2880
|
-
return this.addColumn(new EditorControlColumnModel(columnId,
|
|
3190
|
+
return this.addColumn(new EditorControlColumnModel(columnId, saveCommandFactory, () => this.getColumnTextProperties(columnId)));
|
|
2881
3191
|
}
|
|
2882
3192
|
addCustomColumn(columnId, dataAccessor) {
|
|
2883
3193
|
return this.addColumn(new CustomValueColumnModel(columnId, () => this.getColumnTextProperties(columnId), dataAccessor));
|
|
@@ -2921,19 +3231,20 @@ class AbstractTableModel extends GarbageCollector {
|
|
|
2921
3231
|
if (this._rowsBeingEdited.query().indexOf(row) > -1) {
|
|
2922
3232
|
return lang.illegalState(`Row with id=${rowId} already being edited`);
|
|
2923
3233
|
}
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
this.
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
}
|
|
3234
|
+
// todo: pass the factories to the edit session so we can make the whole lot pluggable?
|
|
3235
|
+
const form = this._createForm(row);
|
|
3236
|
+
const saveCommand = this.saveCommandFactory.create(form);
|
|
3237
|
+
const editSession = new EditSession(rowId, row, form, saveCommand);
|
|
3238
|
+
const { when } = Dsl.disposeWith(editSession);
|
|
3239
|
+
when(editSession.liveRowValue).changes((editedValue) => {
|
|
3240
|
+
this._rowsBeingEdited.replaceOrPush(editedValue);
|
|
3241
|
+
}, { initialValue: 'triggerChangeUnlessNil' });
|
|
3242
|
+
this._editorSessions.push(editSession);
|
|
3243
|
+
editSession.onDispose(() => {
|
|
3244
|
+
this._rowsBeingEdited.remove(editSession.liveRowValue.value);
|
|
3245
|
+
this._editorSessions.remove(editSession);
|
|
3246
|
+
});
|
|
3247
|
+
return editSession;
|
|
2937
3248
|
}
|
|
2938
3249
|
getEditSessionFor(row) {
|
|
2939
3250
|
return this._editorSessionByRowId.get(this.identityOf(row));
|
|
@@ -2949,12 +3260,16 @@ class AbstractTableModel extends GarbageCollector {
|
|
|
2949
3260
|
return this.isRowSelectionEnabled() && column.isRowSelectionEnabled();
|
|
2950
3261
|
}
|
|
2951
3262
|
isRowSelectionEnabled() {
|
|
2952
|
-
return this.
|
|
3263
|
+
return this.hasUserSelectionModel() && !this.rowSelectionDisabledOnAllColumns.value;
|
|
2953
3264
|
}
|
|
2954
|
-
|
|
3265
|
+
hasUserSelectionModel() {
|
|
2955
3266
|
var _a;
|
|
2956
3267
|
return !!((_a = this.selectionColumnModel) === null || _a === void 0 ? void 0 : _a.selectionModel.getDelegate());
|
|
2957
3268
|
}
|
|
3269
|
+
getSelectionModel() {
|
|
3270
|
+
var _a;
|
|
3271
|
+
return (_a = this.selectionColumnModel) === null || _a === void 0 ? void 0 : _a.selectionModel;
|
|
3272
|
+
}
|
|
2958
3273
|
isHoverEnabled() {
|
|
2959
3274
|
return this.isRowSelectionEnabled() || this.rowClickListeners.listenerCount > 0;
|
|
2960
3275
|
}
|
|
@@ -3070,7 +3385,7 @@ TableHeaderCellRendererComponent.decorators = [
|
|
|
3070
3385
|
{ type: Component, args: [{
|
|
3071
3386
|
selector: 'aup-table-header-cell-renderer',
|
|
3072
3387
|
template: "<ng-container [cdkPortalOutlet]=\"getPortal()\" (attached)=\"initialiseHeader($event.instance)\"></ng-container>\n",
|
|
3073
|
-
styles: [":host{display:flex;flex-direction:column;align-items:stretch;justify-content:center;height:100%}"]
|
|
3388
|
+
styles: [":host{display:flex;flex-direction:column;align-items:stretch;justify-content:center;height:100%}\n"]
|
|
3074
3389
|
},] }
|
|
3075
3390
|
];
|
|
3076
3391
|
TableHeaderCellRendererComponent.ctorParameters = () => [];
|
|
@@ -3100,8 +3415,6 @@ class TableRowMenuComponent extends DisposableComponent {
|
|
|
3100
3415
|
registerMoreAction(commandFactory, properties) {
|
|
3101
3416
|
this.moreActions.push(new MenuItemData(commandFactory, properties));
|
|
3102
3417
|
}
|
|
3103
|
-
ngOnInit() {
|
|
3104
|
-
}
|
|
3105
3418
|
createMoreMenuCommand(item, value) {
|
|
3106
3419
|
const { when } = Dsl.disposeWith(this);
|
|
3107
3420
|
const command = item.factory.create(value);
|
|
@@ -3186,18 +3499,19 @@ TableRowMenuComponent.propDecorators = {
|
|
|
3186
3499
|
* --row-selected-background-color: rebeccapurple; // defaults to transparent
|
|
3187
3500
|
* --first-column-padding-left: 18px // defaults to --column-gap
|
|
3188
3501
|
* --last-column-padding-right: 18px // defaults to --column-gap
|
|
3189
|
-
*
|
|
3190
|
-
*
|
|
3191
|
-
*
|
|
3192
|
-
*
|
|
3193
|
-
*
|
|
3194
|
-
*
|
|
3195
|
-
*
|
|
3196
|
-
*
|
|
3197
|
-
*
|
|
3198
|
-
*
|
|
3199
|
-
*
|
|
3200
|
-
*
|
|
3502
|
+
* ::ng-deep {
|
|
3503
|
+
* aup-table-header-cell-renderer,
|
|
3504
|
+
* aup-table-cell-renderer {
|
|
3505
|
+
* &.aup-col-my-dasherised-column-id {
|
|
3506
|
+
* // do stuff
|
|
3507
|
+
* }
|
|
3508
|
+
* &.first-visible-column {
|
|
3509
|
+
* // do stuff
|
|
3510
|
+
* }
|
|
3511
|
+
* &.last-visible-column {
|
|
3512
|
+
* // do stuff
|
|
3513
|
+
* }
|
|
3514
|
+
* }
|
|
3201
3515
|
* }
|
|
3202
3516
|
* }
|
|
3203
3517
|
*/
|
|
@@ -3216,7 +3530,7 @@ TableComponent.decorators = [
|
|
|
3216
3530
|
providers: [
|
|
3217
3531
|
{ provide: AbstractTableComponent, useExisting: TableComponent }
|
|
3218
3532
|
],
|
|
3219
|
-
styles: [":host{display:flex;flex-direction:column;align-items:stretch}:host table{width:100%}:host.enable-scrolling{min-height:0}:host.enable-scrolling .scroll-container{flex:1;flex-basis:0;overflow-y:auto;display:flex;flex-direction:column;align-items:stretch}"]
|
|
3533
|
+
styles: [":host{display:flex;flex-direction:column;align-items:stretch}:host table{width:100%}:host.enable-scrolling{min-height:0}:host.enable-scrolling .scroll-container{flex:1;flex-basis:0;overflow-y:auto;display:flex;flex-direction:column;align-items:stretch}\n"]
|
|
3220
3534
|
},] }
|
|
3221
3535
|
];
|
|
3222
3536
|
TableComponent.ctorParameters = () => [
|
|
@@ -3260,7 +3574,7 @@ TreeInheritanceIconComponent.decorators = [
|
|
|
3260
3574
|
{ type: Component, args: [{
|
|
3261
3575
|
selector: 'aup-tree-inheritance-icon',
|
|
3262
3576
|
template: "<svg xmlns=\"http://www.w3.org/2000/svg\" [attr.width]=\"pixelWidth\" [attr.height]=\"pixelHeight\" [attr.viewBox]=\"viewBox\">\n <g fill=\"none\" fill-rule=\"evenodd\">\n <rect *ngIf=\"hasHead()\" width=\"1\" height=\"32.5\" x=\"11.5\" fill=\"currentColor\"/>\n <rect *ngIf=\"hasTail()\" width=\"1\" height=\"32.5\" x=\"11.5\" y=\"31.5\" fill=\"currentColor\"/>\n\n <rect *ngIf=\"hasLeadIn()\" width=\"12\" height=\"1\" y=\"31.5\" fill=\"currentColor\"/>\n <rect *ngIf=\"hasTerminal()\" width=\"12\" height=\"1\" x=\"12\" y=\"31.5\" fill=\"currentColor\"/>\n </g>\n</svg>\n",
|
|
3263
|
-
styles: [":host{position:relative;color:inherit}svg{color:var(--line-color);display:block}"]
|
|
3577
|
+
styles: [":host{position:relative;color:inherit}svg{color:var(--line-color);display:block}\n"]
|
|
3264
3578
|
},] }
|
|
3265
3579
|
];
|
|
3266
3580
|
TreeInheritanceIconComponent.ctorParameters = () => [];
|
|
@@ -3465,6 +3779,33 @@ var DecoratedTreeNode;
|
|
|
3465
3779
|
DecoratedTreeNode.Decorator = Decorator;
|
|
3466
3780
|
})(DecoratedTreeNode || (DecoratedTreeNode = {}));
|
|
3467
3781
|
|
|
3782
|
+
class FlattenedTreeListModel extends ComputedListModel {
|
|
3783
|
+
constructor(source, childRef, expansionModel) {
|
|
3784
|
+
super(source, {
|
|
3785
|
+
initialValue: [],
|
|
3786
|
+
identifiedWith: row => source.identityOf(row)
|
|
3787
|
+
});
|
|
3788
|
+
this.source = source;
|
|
3789
|
+
this.childRef = childRef;
|
|
3790
|
+
this.expansionModel = expansionModel;
|
|
3791
|
+
this.trackSource(expansionModel.isExpandedPredicate);
|
|
3792
|
+
}
|
|
3793
|
+
compute(values) {
|
|
3794
|
+
const result = [];
|
|
3795
|
+
values.forEach(rootNode => {
|
|
3796
|
+
return this.addNodeAndVisibleChildren(DecoratedTreeNode.decorateRoot(rootNode, this.childRef), result);
|
|
3797
|
+
});
|
|
3798
|
+
return result;
|
|
3799
|
+
}
|
|
3800
|
+
addNodeAndVisibleChildren(node, result) {
|
|
3801
|
+
result.push(node);
|
|
3802
|
+
const decorator = node[treeNodeDecorator];
|
|
3803
|
+
if (decorator.hasChildren() && !this.expansionModel.isCollapsed(node)) {
|
|
3804
|
+
decorator.children.forEach(child => this.addNodeAndVisibleChildren(child, result));
|
|
3805
|
+
}
|
|
3806
|
+
}
|
|
3807
|
+
}
|
|
3808
|
+
|
|
3468
3809
|
class TreeExpansionModel {
|
|
3469
3810
|
constructor(identityOf) {
|
|
3470
3811
|
this.identityOf = identityOf;
|
|
@@ -3512,33 +3853,6 @@ class TreeExpansionModel {
|
|
|
3512
3853
|
}
|
|
3513
3854
|
}
|
|
3514
3855
|
|
|
3515
|
-
class FlattenedTreeListModel extends ComputedListModel {
|
|
3516
|
-
constructor(source, childRef, expansionModel) {
|
|
3517
|
-
super(source);
|
|
3518
|
-
this.source = source;
|
|
3519
|
-
this.childRef = childRef;
|
|
3520
|
-
this.expansionModel = expansionModel;
|
|
3521
|
-
this.trackSource(expansionModel.isExpandedPredicate);
|
|
3522
|
-
}
|
|
3523
|
-
getIdentityOf(item) {
|
|
3524
|
-
return this.source.identityOf(item);
|
|
3525
|
-
}
|
|
3526
|
-
compute(values) {
|
|
3527
|
-
const result = [];
|
|
3528
|
-
values.forEach(rootNode => {
|
|
3529
|
-
return this.addNodeAndVisibleChildren(DecoratedTreeNode.decorateRoot(rootNode, this.childRef), result);
|
|
3530
|
-
});
|
|
3531
|
-
return result;
|
|
3532
|
-
}
|
|
3533
|
-
addNodeAndVisibleChildren(node, result) {
|
|
3534
|
-
result.push(node);
|
|
3535
|
-
const decorator = node[treeNodeDecorator];
|
|
3536
|
-
if (decorator.hasChildren() && !this.expansionModel.isCollapsed(node)) {
|
|
3537
|
-
decorator.children.forEach(child => this.addNodeAndVisibleChildren(child, result));
|
|
3538
|
-
}
|
|
3539
|
-
}
|
|
3540
|
-
}
|
|
3541
|
-
|
|
3542
3856
|
class TreeLabelColumnModel extends ColumnModel {
|
|
3543
3857
|
constructor(columnId, textPropertiesProvider, expansionModel) {
|
|
3544
3858
|
super(columnId, textPropertiesProvider);
|
|
@@ -3561,7 +3875,7 @@ class TreeLabelColumnModel extends ColumnModel {
|
|
|
3561
3875
|
cellRenderer(componentType) {
|
|
3562
3876
|
this.configureCellRenderer(new ComponentCellRendererPortalRef(componentType, (component, rowData, firstTime) => {
|
|
3563
3877
|
if (firstTime) {
|
|
3564
|
-
component.
|
|
3878
|
+
component.treeTableModel = this.expansionModel;
|
|
3565
3879
|
}
|
|
3566
3880
|
component.value = rowData.row;
|
|
3567
3881
|
component.label = ___default.isNil(this.labelProperty) ? undefined : rowData.row[this.labelProperty];
|
|
@@ -3593,10 +3907,11 @@ class TreeTableModel extends AbstractTableModel {
|
|
|
3593
3907
|
const childExtractor = _.isFunction(childAccessor) ? childAccessor : row => row[childAccessor];
|
|
3594
3908
|
this.flattenedDataSource = this.registerDisposable(new FlattenedTreeListModel(source, childExtractor, this.treeExpansionModel));
|
|
3595
3909
|
this.setDataSource(this.flattenedDataSource);
|
|
3910
|
+
this.addRowClass('aup-node-collapsed', row => this.isCollapsed(row));
|
|
3596
3911
|
}
|
|
3597
3912
|
treeControlColumn(builder) {
|
|
3598
3913
|
const columnId = 'tree-label';
|
|
3599
|
-
const column = new TreeLabelColumnModel(columnId, () => this.getColumnTextProperties(columnId), this
|
|
3914
|
+
const column = new TreeLabelColumnModel(columnId, () => this.getColumnTextProperties(columnId), this);
|
|
3600
3915
|
builder(column);
|
|
3601
3916
|
this.addColumn(column);
|
|
3602
3917
|
}
|
|
@@ -3604,7 +3919,7 @@ class TreeTableModel extends AbstractTableModel {
|
|
|
3604
3919
|
this.treeExpansionModel.expand(node);
|
|
3605
3920
|
}
|
|
3606
3921
|
collapse(node) {
|
|
3607
|
-
this.treeExpansionModel.
|
|
3922
|
+
this.treeExpansionModel.collapse(node);
|
|
3608
3923
|
}
|
|
3609
3924
|
isCollapsed(node) {
|
|
3610
3925
|
return this.treeExpansionModel.isCollapsed(node);
|
|
@@ -3681,17 +3996,17 @@ class TreeLabelCellRendererComponent extends DisposableComponent {
|
|
|
3681
3996
|
ngOnInit() {
|
|
3682
3997
|
const { chain } = Dsl.disposeWith(this);
|
|
3683
3998
|
this.canExpand = chain(this.nodeModel).map(node => {
|
|
3684
|
-
return DecoratedTreeNode.getDecorator(node).hasChildren() && this.
|
|
3685
|
-
}, { dependsOn: this.
|
|
3999
|
+
return DecoratedTreeNode.getDecorator(node).hasChildren() && this.treeTableModel.isCollapsed(node);
|
|
4000
|
+
}, { dependsOn: this.treeTableModel.treeExpansionModel.isExpandedPredicate });
|
|
3686
4001
|
this.canCollapse = chain(this.nodeModel).map(node => {
|
|
3687
|
-
return DecoratedTreeNode.getDecorator(node).hasChildren() && !this.
|
|
3688
|
-
}, { dependsOn: this.
|
|
4002
|
+
return DecoratedTreeNode.getDecorator(node).hasChildren() && !this.treeTableModel.isCollapsed(node);
|
|
4003
|
+
}, { dependsOn: this.treeTableModel.treeExpansionModel.isExpandedPredicate });
|
|
3689
4004
|
this.iconModel = chain(this.nodeModel).map(node => {
|
|
3690
4005
|
var _a;
|
|
3691
|
-
const expanded = this.
|
|
4006
|
+
const expanded = this.treeTableModel.treeExpansionModel.isExpanded(this.node);
|
|
3692
4007
|
const iconFactory = (_a = this.iconFactory) !== null && _a !== void 0 ? _a : TreeLabelCellRendererComponent.DEFAULT_ICON_FACTORY;
|
|
3693
4008
|
return iconFactory(node, expanded, TreeLabelCellRendererComponent.DEFAULT_ICON_FACTORY(node, expanded, undefined));
|
|
3694
|
-
}, { dependsOn: this.
|
|
4009
|
+
}, { dependsOn: this.treeTableModel.treeExpansionModel.isExpandedPredicate });
|
|
3695
4010
|
}
|
|
3696
4011
|
get isRoot() {
|
|
3697
4012
|
return DecoratedTreeNode.getDecorator(this.node).isRoot();
|
|
@@ -3703,15 +4018,17 @@ class TreeLabelCellRendererComponent extends DisposableComponent {
|
|
|
3703
4018
|
return this.nodeModel.value;
|
|
3704
4019
|
}
|
|
3705
4020
|
// @Trace()
|
|
3706
|
-
expandOrCollapse(node) {
|
|
3707
|
-
|
|
4021
|
+
expandOrCollapse($event, node) {
|
|
4022
|
+
$event.preventDefault();
|
|
4023
|
+
$event.stopPropagation();
|
|
4024
|
+
this.treeTableModel.isCollapsed(node) ? this.treeTableModel.expand(node) : this.treeTableModel.collapse(node);
|
|
3708
4025
|
}
|
|
3709
4026
|
}
|
|
3710
4027
|
TreeLabelCellRendererComponent.decorators = [
|
|
3711
4028
|
{ type: Component, args: [{
|
|
3712
4029
|
selector: 'aup-tree-label-cell-renderer',
|
|
3713
|
-
template: "<div class=\"tree-icons\">\n <aup-tree-inheritance-icon *ngFor=\"let iconClass of iconList.value\" [type]=\"iconClass\"></aup-tree-inheritance-icon>\n <aup-icon *ngIf=\"iconModel.value\"\n [icon]=\"iconModel.value\"\n [class.clickable]=\"canExpand.value || canCollapse.value\"\n (click)=\"expandOrCollapse(node)\" ></aup-icon>\n</div>\n<div class=\"label\">{{label}}</div>\n",
|
|
3714
|
-
styles: [":host{--line-color
|
|
4030
|
+
template: "<div class=\"tree-icons\">\n <aup-tree-inheritance-icon *ngFor=\"let iconClass of iconList.value\" [type]=\"iconClass\"></aup-tree-inheritance-icon>\n <aup-icon *ngIf=\"iconModel.value\"\n [icon]=\"iconModel.value\"\n [class.clickable]=\"canExpand.value || canCollapse.value\"\n (click)=\"expandOrCollapse($event, node)\" ></aup-icon>\n</div>\n<div class=\"label\">{{label}}</div>\n",
|
|
4031
|
+
styles: [":host{--line-color: #ddd;--node-color: #999;display:inline-flex;flex-direction:row;align-items:stretch}:host div.label{display:flex;flex-direction:row;align-items:center;white-space:nowrap;padding-left:6px}:host div.tree-icons{display:grid;grid-auto-flow:column;grid-auto-columns:auto;grid-template-rows:1fr;align-items:stretch;justify-content:stretch}:host div.tree-icons aup-icon{align-self:center;color:var(--node-color)}:host div.tree-icons aup-icon.clickable{cursor:pointer}:host div.tree-icons aup-tree-inheritance-icon,:host div.tree-icons aup-icon{margin-left:4px}\n"]
|
|
3715
4032
|
},] }
|
|
3716
4033
|
];
|
|
3717
4034
|
TreeLabelCellRendererComponent.ctorParameters = () => [];
|
|
@@ -3719,7 +4036,7 @@ TreeLabelCellRendererComponent.propDecorators = {
|
|
|
3719
4036
|
value: [{ type: Input }],
|
|
3720
4037
|
label: [{ type: Input }],
|
|
3721
4038
|
iconFactory: [{ type: Input }],
|
|
3722
|
-
|
|
4039
|
+
treeTableModel: [{ type: Input }],
|
|
3723
4040
|
isRoot: [{ type: HostBinding, args: ['class.root',] }],
|
|
3724
4041
|
isLeaf: [{ type: HostBinding, args: ['class.leaf',] }]
|
|
3725
4042
|
};
|
|
@@ -3728,7 +4045,14 @@ __decorate([
|
|
|
3728
4045
|
__metadata("design:type", Object)
|
|
3729
4046
|
], TreeLabelCellRendererComponent.prototype, "value", void 0);
|
|
3730
4047
|
(function (TreeLabelCellRendererComponent) {
|
|
3731
|
-
TreeLabelCellRendererComponent.DEFAULT_ICON_FACTORY = (node, expanded, defaultIcon) =>
|
|
4048
|
+
TreeLabelCellRendererComponent.DEFAULT_ICON_FACTORY = (node, expanded, defaultIcon) => {
|
|
4049
|
+
const isLeaf = DecoratedTreeNode.getDecorator(node).isLeaf();
|
|
4050
|
+
return isLeaf ?
|
|
4051
|
+
undefined :
|
|
4052
|
+
expanded ?
|
|
4053
|
+
'mat:expand_more' :
|
|
4054
|
+
'mat:chevron_right';
|
|
4055
|
+
};
|
|
3732
4056
|
})(TreeLabelCellRendererComponent || (TreeLabelCellRendererComponent = {}));
|
|
3733
4057
|
|
|
3734
4058
|
/**
|
|
@@ -3806,7 +4130,7 @@ TreeTableComponent.decorators = [
|
|
|
3806
4130
|
providers: [
|
|
3807
4131
|
{ provide: AbstractTableComponent, useExisting: TreeTableComponent }
|
|
3808
4132
|
],
|
|
3809
|
-
styles: [":host{display:flex;flex-direction:column;align-items:stretch}:host table{width:100%}:host.enable-scrolling{min-height:0}:host.enable-scrolling .scroll-container{flex:1;flex-basis:0;overflow-y:auto;display:flex;flex-direction:column;align-items:stretch}", "td.mat-cell{border-top-width:0!important;border-bottom-width:0!important}td.mat-column-tree-label{width:1px}aup-table-cell-renderer[column-id=tree-label]{padding-left:8px!important}aup-tree-label-cell-renderer{flex:1}"]
|
|
4133
|
+
styles: [":host{display:flex;flex-direction:column;align-items:stretch}:host table{width:100%}:host.enable-scrolling{min-height:0}:host.enable-scrolling .scroll-container{flex:1;flex-basis:0;overflow-y:auto;display:flex;flex-direction:column;align-items:stretch}\n", "td.mat-cell{border-top-width:0!important;border-bottom-width:0!important}td.mat-column-tree-label,td.mat-column-tree-label{width:1px}aup-table-cell-renderer[column-id=tree-label]{padding-left:8px!important}aup-tree-label-cell-renderer{flex:1}\n"]
|
|
3810
4134
|
},] }
|
|
3811
4135
|
];
|
|
3812
4136
|
TreeTableComponent.ctorParameters = () => [
|
|
@@ -3860,7 +4184,7 @@ VerticalFocusContainerComponent.decorators = [
|
|
|
3860
4184
|
providers: [
|
|
3861
4185
|
{ provide: FocusManager }
|
|
3862
4186
|
],
|
|
3863
|
-
styles: [":host{display:block}"]
|
|
4187
|
+
styles: [":host{display:block}\n"]
|
|
3864
4188
|
},] }
|
|
3865
4189
|
];
|
|
3866
4190
|
VerticalFocusContainerComponent.ctorParameters = () => [
|
|
@@ -3906,7 +4230,7 @@ PaginatorComponent.decorators = [
|
|
|
3906
4230
|
{ type: Component, args: [{
|
|
3907
4231
|
selector: 'aup-paginator',
|
|
3908
4232
|
template: "<p>Page {{pageNumber}} of {{totalPages}}</p>\n<button mat-icon-button [pectinCommand]=\"previousCommand\"><aup-icon icon=\"mat:keyboard_arrow_left\"></aup-icon></button>\n<button mat-icon-button [pectinCommand]=\"nextCommand\"><aup-icon icon=\"mat:keyboard_arrow_right\"></aup-icon></button>\n\n",
|
|
3909
|
-
styles: [":host{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;font-size:12px;padding:0 8px;color
|
|
4233
|
+
styles: [":host{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;font-size:12px;padding:0 8px;color:#0009}:host p{color:inherit;margin-right:8px}:host button.md-button.md-icon-button{padding:0;margin:0;width:30px;height:30px}\n"]
|
|
3910
4234
|
},] }
|
|
3911
4235
|
];
|
|
3912
4236
|
PaginatorComponent.ctorParameters = () => [];
|
|
@@ -3918,6 +4242,97 @@ __decorate([
|
|
|
3918
4242
|
__metadata("design:type", PageController)
|
|
3919
4243
|
], PaginatorComponent.prototype, "pageController", void 0);
|
|
3920
4244
|
|
|
4245
|
+
class LabelledValueComponent extends DisposableComponent {
|
|
4246
|
+
constructor() {
|
|
4247
|
+
super();
|
|
4248
|
+
// const {chain} = Dsl.disposeWith(this);
|
|
4249
|
+
}
|
|
4250
|
+
ngOnInit() {
|
|
4251
|
+
}
|
|
4252
|
+
}
|
|
4253
|
+
LabelledValueComponent.decorators = [
|
|
4254
|
+
{ type: Component, args: [{
|
|
4255
|
+
selector: 'aup-labelled-value',
|
|
4256
|
+
template: "<label>{{label}}</label>\n<ng-content></ng-content>\n",
|
|
4257
|
+
styles: [":host{display:inline-flex;flex-direction:column;align-items:flex-start}label{font-weight:400;font-size:12px;color:#00000091;margin-bottom:6px;white-space:nowrap}\n"]
|
|
4258
|
+
},] }
|
|
4259
|
+
];
|
|
4260
|
+
LabelledValueComponent.ctorParameters = () => [];
|
|
4261
|
+
LabelledValueComponent.propDecorators = {
|
|
4262
|
+
label: [{ type: Input }]
|
|
4263
|
+
};
|
|
4264
|
+
|
|
4265
|
+
/**
|
|
4266
|
+
* @example
|
|
4267
|
+
* <aup-markdown [content]="..."></aup-markdown>
|
|
4268
|
+
* <aup-markdown [content$]="stringValueModel$"></aup-markdown>
|
|
4269
|
+
* <aup-markdown ngPreserveWhitespaces>
|
|
4270
|
+
* # This is markdown content
|
|
4271
|
+
*
|
|
4272
|
+
* With a list
|
|
4273
|
+
* - a
|
|
4274
|
+
* - b
|
|
4275
|
+
* </aup-markdown>
|
|
4276
|
+
*/
|
|
4277
|
+
class MarkdownComponent extends DisposableComponent {
|
|
4278
|
+
constructor(platform, element, markdownService) {
|
|
4279
|
+
super();
|
|
4280
|
+
this.platform = platform;
|
|
4281
|
+
this.element = element;
|
|
4282
|
+
this.markdownService = markdownService;
|
|
4283
|
+
this.inline = false;
|
|
4284
|
+
const { chain } = Dsl.disposeWith(this);
|
|
4285
|
+
}
|
|
4286
|
+
ngOnInit() {
|
|
4287
|
+
const { when } = Dsl.disposeWith(this);
|
|
4288
|
+
when(this.content$).changes(content => this.renderContent(content), { initialValue: 'triggerChangeUnlessNil' });
|
|
4289
|
+
if (_.isNil(this.content) && !_.isEmpty(this.element.nativeElement.innerHTML)) {
|
|
4290
|
+
this.renderContent(this.extractInnerContent(this.element.nativeElement.innerHTML));
|
|
4291
|
+
}
|
|
4292
|
+
}
|
|
4293
|
+
extractInnerContent(content) {
|
|
4294
|
+
const lines = content.split('\n');
|
|
4295
|
+
const prefix = lines.reduce((minPrefix, line) => {
|
|
4296
|
+
const leadingWhitespace = line.search(/\S/);
|
|
4297
|
+
return leadingWhitespace < 0 ? minPrefix : Math.min(minPrefix, leadingWhitespace);
|
|
4298
|
+
}, Number.MAX_SAFE_INTEGER);
|
|
4299
|
+
return lines.map(l => l.substr(prefix)).join('\n');
|
|
4300
|
+
}
|
|
4301
|
+
renderContent(content) {
|
|
4302
|
+
if (!_.isNil(content)) {
|
|
4303
|
+
const markdown = this.inline ?
|
|
4304
|
+
this.markdownService.renderInline(content) :
|
|
4305
|
+
this.markdownService.render(content);
|
|
4306
|
+
this.element.nativeElement.innerHTML = markdown;
|
|
4307
|
+
}
|
|
4308
|
+
}
|
|
4309
|
+
}
|
|
4310
|
+
MarkdownComponent.decorators = [
|
|
4311
|
+
{ type: Component, args: [{
|
|
4312
|
+
selector: 'aup-markdown, [aupMarkdown]',
|
|
4313
|
+
template: "<ng-content></ng-content>\n",
|
|
4314
|
+
styles: [":host{display:inline-block}\n"]
|
|
4315
|
+
},] }
|
|
4316
|
+
];
|
|
4317
|
+
MarkdownComponent.ctorParameters = () => [
|
|
4318
|
+
{ type: Object, decorators: [{ type: Inject, args: [PLATFORM_ID,] }] },
|
|
4319
|
+
{ type: ElementRef },
|
|
4320
|
+
{ type: MarkdownService }
|
|
4321
|
+
];
|
|
4322
|
+
MarkdownComponent.propDecorators = {
|
|
4323
|
+
content$: [{ type: Input }],
|
|
4324
|
+
content: [{ type: Input }],
|
|
4325
|
+
inline: [{ type: Input }]
|
|
4326
|
+
};
|
|
4327
|
+
__decorate([
|
|
4328
|
+
TrackExternal(),
|
|
4329
|
+
__metadata("design:type", ValueModel)
|
|
4330
|
+
], MarkdownComponent.prototype, "content$", void 0);
|
|
4331
|
+
__decorate([
|
|
4332
|
+
StoreInValueModel('content$'),
|
|
4333
|
+
__metadata("design:type", String)
|
|
4334
|
+
], MarkdownComponent.prototype, "content", void 0);
|
|
4335
|
+
|
|
3921
4336
|
class ComponentsModule {
|
|
3922
4337
|
constructor(faIconLibrary) {
|
|
3923
4338
|
faIconLibrary.addIconPacks(fas);
|
|
@@ -3925,6 +4340,29 @@ class ComponentsModule {
|
|
|
3925
4340
|
}
|
|
3926
4341
|
ComponentsModule.decorators = [
|
|
3927
4342
|
{ type: NgModule, args: [{
|
|
4343
|
+
imports: [
|
|
4344
|
+
CommonModule,
|
|
4345
|
+
BrowserAnimationsModule,
|
|
4346
|
+
FormsModule,
|
|
4347
|
+
MatInputModule,
|
|
4348
|
+
MatFormFieldModule,
|
|
4349
|
+
MatSelectModule,
|
|
4350
|
+
MatTabsModule,
|
|
4351
|
+
DirectivesModule,
|
|
4352
|
+
MatIconModule,
|
|
4353
|
+
MatButtonModule,
|
|
4354
|
+
MatCheckboxModule,
|
|
4355
|
+
MatTableModule,
|
|
4356
|
+
PortalModule,
|
|
4357
|
+
CdkScrollableModule,
|
|
4358
|
+
FontAwesomeModule,
|
|
4359
|
+
MatTooltipModule,
|
|
4360
|
+
MatAutocompleteModule,
|
|
4361
|
+
MatMenuModule,
|
|
4362
|
+
MatDividerModule,
|
|
4363
|
+
MatProgressSpinnerModule,
|
|
4364
|
+
MatProgressBarModule
|
|
4365
|
+
],
|
|
3928
4366
|
declarations: [
|
|
3929
4367
|
AbstractInputComponent,
|
|
3930
4368
|
AbstractValueInputComponent,
|
|
@@ -3973,29 +4411,12 @@ ComponentsModule.decorators = [
|
|
|
3973
4411
|
BusyOverlayComponent,
|
|
3974
4412
|
EmptyStateComponent,
|
|
3975
4413
|
PaginatorComponent,
|
|
3976
|
-
AbstractTableComponent
|
|
3977
|
-
|
|
3978
|
-
|
|
3979
|
-
|
|
3980
|
-
|
|
3981
|
-
|
|
3982
|
-
MatInputModule,
|
|
3983
|
-
MatFormFieldModule,
|
|
3984
|
-
MatSelectModule,
|
|
3985
|
-
MatTabsModule,
|
|
3986
|
-
DirectivesModule,
|
|
3987
|
-
MatIconModule,
|
|
3988
|
-
MatButtonModule,
|
|
3989
|
-
MatCheckboxModule,
|
|
3990
|
-
MatTableModule,
|
|
3991
|
-
PortalModule,
|
|
3992
|
-
CdkScrollableModule,
|
|
3993
|
-
FontAwesomeModule,
|
|
3994
|
-
MatTooltipModule,
|
|
3995
|
-
MatAutocompleteModule,
|
|
3996
|
-
MatMenuModule,
|
|
3997
|
-
MatDividerModule,
|
|
3998
|
-
MatProgressSpinnerModule
|
|
4414
|
+
AbstractTableComponent,
|
|
4415
|
+
AbstractCardContainerComponent,
|
|
4416
|
+
CardStackComponent,
|
|
4417
|
+
LabelledValueComponent,
|
|
4418
|
+
LoadingContainerComponent,
|
|
4419
|
+
MarkdownComponent
|
|
3999
4420
|
],
|
|
4000
4421
|
exports: [
|
|
4001
4422
|
NumberInputComponent,
|
|
@@ -4032,9 +4453,14 @@ ComponentsModule.decorators = [
|
|
|
4032
4453
|
BusyOverlayComponent,
|
|
4033
4454
|
EmptyStateComponent,
|
|
4034
4455
|
PaginatorComponent,
|
|
4456
|
+
CardStackComponent,
|
|
4457
|
+
LabelledValueComponent,
|
|
4458
|
+
LoadingContainerComponent,
|
|
4459
|
+
MarkdownComponent
|
|
4035
4460
|
],
|
|
4036
4461
|
providers: [
|
|
4037
|
-
FocusBindingFactory
|
|
4462
|
+
FocusBindingFactory,
|
|
4463
|
+
MarkdownService
|
|
4038
4464
|
]
|
|
4039
4465
|
},] }
|
|
4040
4466
|
];
|
|
@@ -4067,7 +4493,8 @@ class ActivityActionsComponent extends DisposableComponent {
|
|
|
4067
4493
|
constructor(cdr) {
|
|
4068
4494
|
super();
|
|
4069
4495
|
this.cdr = cdr;
|
|
4070
|
-
this.
|
|
4496
|
+
this.layout = ActivityActionsComponent.Layout.BLOCK;
|
|
4497
|
+
this.align = ActivityActionsComponent.Align.STRETCH;
|
|
4071
4498
|
}
|
|
4072
4499
|
set faces(faces) {
|
|
4073
4500
|
this.confirmFace = faces.confirm;
|
|
@@ -4079,12 +4506,6 @@ class ActivityActionsComponent extends DisposableComponent {
|
|
|
4079
4506
|
set style(style) {
|
|
4080
4507
|
this.faces = style;
|
|
4081
4508
|
}
|
|
4082
|
-
get alignEnd() {
|
|
4083
|
-
return this.align === 'end';
|
|
4084
|
-
}
|
|
4085
|
-
get alignStretch() {
|
|
4086
|
-
return this.align === 'stretch';
|
|
4087
|
-
}
|
|
4088
4509
|
ngOnInit() {
|
|
4089
4510
|
}
|
|
4090
4511
|
hasConfirmFace() {
|
|
@@ -4103,7 +4524,7 @@ ActivityActionsComponent.decorators = [
|
|
|
4103
4524
|
{ type: Component, args: [{
|
|
4104
4525
|
selector: 'aup-activity-actions',
|
|
4105
4526
|
template: "<div class=\"content\">\n <ng-content></ng-content>\n</div>\n<ng-container *ngIf=\"hasConfirmFace()\">\n <aup-command class=\"confirm\" [command]=\"confirmCommand\" [face]=\"confirmFace\" data-cy=\"confirm-command\"></aup-command>\n</ng-container>\n<ng-container *ngIf=\"hasCancelFace()\">\n <aup-command class=\"cancel\" [command]=\"cancelCommand\" [face]=\"cancelFace\" data-cy=\"cancel-command\"></aup-command>\n</ng-container>\n",
|
|
4106
|
-
styles: [":host{display:grid;grid-template-areas:\"cancel confirm content\";grid-template-columns:auto auto 1fr
|
|
4527
|
+
styles: [":host{display:grid;grid-template-rows:auto;align-items:center;justify-content:end;--resolved-activity-actions-gap: var(--activity-actions-gap, 8px)}:host[layout=block][align=start]{grid-template-areas:\"cancel confirm content\";grid-template-columns:auto auto 1fr}:host[layout=block][align=start] .confirm{margin-left:var(--resolved-activity-actions-gap)}:host[layout=block][align=end]{grid-template-areas:\"content cancel confirm\";grid-template-columns:1fr auto auto}:host[layout=block][align=end] .confirm{margin-left:var(--resolved-activity-actions-gap)}:host[layout=block][align=stretch]{grid-template-areas:\"cancel content confirm\";grid-template-columns:auto 1fr auto}:host[layout=inline]{grid-template-areas:\"confirm cancel content\";grid-template-columns:auto auto 1fr}:host[layout=inline] .cancel{margin-left:var(--resolved-activity-actions-gap)}.cancel{grid-area:cancel}.confirm{grid-area:confirm}.content{grid-area:content;text-align:left}\n"]
|
|
4107
4528
|
},] }
|
|
4108
4529
|
];
|
|
4109
4530
|
ActivityActionsComponent.ctorParameters = () => [
|
|
@@ -4116,9 +4537,8 @@ ActivityActionsComponent.propDecorators = {
|
|
|
4116
4537
|
confirmFace: [{ type: Input }],
|
|
4117
4538
|
cancelFace: [{ type: Input }],
|
|
4118
4539
|
style: [{ type: Input }],
|
|
4119
|
-
|
|
4120
|
-
|
|
4121
|
-
alignStretch: [{ type: HostBinding, args: ['class.align-stretch',] }]
|
|
4540
|
+
layout: [{ type: Input }, { type: HostBinding, args: ['attr.layout',] }],
|
|
4541
|
+
align: [{ type: Input }, { type: HostBinding, args: ['attr.align',] }]
|
|
4122
4542
|
};
|
|
4123
4543
|
__decorate([
|
|
4124
4544
|
TrackExternal(),
|
|
@@ -4128,14 +4548,26 @@ __decorate([
|
|
|
4128
4548
|
TrackExternal(),
|
|
4129
4549
|
__metadata("design:type", Command)
|
|
4130
4550
|
], ActivityActionsComponent.prototype, "cancelCommand", void 0);
|
|
4551
|
+
(function (ActivityActionsComponent) {
|
|
4552
|
+
ActivityActionsComponent.Layout = Enum({
|
|
4553
|
+
INLINE: 'inline',
|
|
4554
|
+
BLOCK: 'block'
|
|
4555
|
+
});
|
|
4556
|
+
ActivityActionsComponent.Align = Enum({
|
|
4557
|
+
START: 'start',
|
|
4558
|
+
END: 'end',
|
|
4559
|
+
STRETCH: 'stretch'
|
|
4560
|
+
});
|
|
4561
|
+
})(ActivityActionsComponent || (ActivityActionsComponent = {}));
|
|
4131
4562
|
|
|
4132
4563
|
const ACTIVITY_DATA = new InjectionToken('InteractionActivityData');
|
|
4133
4564
|
class Activity extends DisposableComponent {
|
|
4134
4565
|
constructor() {
|
|
4135
4566
|
super();
|
|
4136
|
-
this._busyModel = new DelegatingValueModel().withDefault(false);
|
|
4567
|
+
this._busyModel = this.registerDisposable(new DelegatingValueModel().withDefault(false));
|
|
4137
4568
|
this._focusedModel = this.registerDisposable(new DelegatingValueModel());
|
|
4138
4569
|
this.class = 'aup-activity';
|
|
4570
|
+
this.busyWhile(this.confirmCommand.busy);
|
|
4139
4571
|
}
|
|
4140
4572
|
get isFocused() {
|
|
4141
4573
|
return this._focusedModel.value;
|
|
@@ -4188,127 +4620,183 @@ Activity.decorators = [
|
|
|
4188
4620
|
template: ''
|
|
4189
4621
|
},] }
|
|
4190
4622
|
];
|
|
4191
|
-
Activity.ctorParameters = () => [];
|
|
4192
|
-
Activity.propDecorators = {
|
|
4193
|
-
activityActions: [{ type: ViewChild, args: [ActivityActionsComponent,] }],
|
|
4194
|
-
class: [{ type: HostBinding, args: ['class',] }],
|
|
4195
|
-
isFocused: [{ type: HostBinding, args: ['attr.focused',] }]
|
|
4196
|
-
};
|
|
4197
|
-
__decorate([
|
|
4198
|
-
TrackExternal(),
|
|
4199
|
-
__metadata("design:type", Command)
|
|
4200
|
-
], Activity.prototype, "confirmCommand", void 0);
|
|
4201
|
-
__decorate([
|
|
4202
|
-
TrackExternal(),
|
|
4203
|
-
__metadata("design:type", Command)
|
|
4204
|
-
], Activity.prototype, "cancelCommand", void 0);
|
|
4623
|
+
Activity.ctorParameters = () => [];
|
|
4624
|
+
Activity.propDecorators = {
|
|
4625
|
+
activityActions: [{ type: ViewChild, args: [ActivityActionsComponent,] }],
|
|
4626
|
+
class: [{ type: HostBinding, args: ['class',] }],
|
|
4627
|
+
isFocused: [{ type: HostBinding, args: ['attr.focused',] }]
|
|
4628
|
+
};
|
|
4629
|
+
__decorate([
|
|
4630
|
+
TrackExternal(),
|
|
4631
|
+
__metadata("design:type", Command)
|
|
4632
|
+
], Activity.prototype, "confirmCommand", void 0);
|
|
4633
|
+
__decorate([
|
|
4634
|
+
TrackExternal(),
|
|
4635
|
+
__metadata("design:type", Command)
|
|
4636
|
+
], Activity.prototype, "cancelCommand", void 0);
|
|
4637
|
+
|
|
4638
|
+
var Alert;
|
|
4639
|
+
(function (Alert) {
|
|
4640
|
+
function getContent(alert) {
|
|
4641
|
+
const content = alert.content();
|
|
4642
|
+
return Array.isArray(content) ? content : [content];
|
|
4643
|
+
}
|
|
4644
|
+
Alert.getContent = getContent;
|
|
4645
|
+
function getTitle(alert) {
|
|
4646
|
+
return _.isFunction(alert.title) ? alert.title() : undefined;
|
|
4647
|
+
}
|
|
4648
|
+
Alert.getTitle = getTitle;
|
|
4649
|
+
function getColor(alert) {
|
|
4650
|
+
return _.isFunction(alert.color) ? alert.color() : undefined;
|
|
4651
|
+
}
|
|
4652
|
+
Alert.getColor = getColor;
|
|
4653
|
+
})(Alert || (Alert = {}));
|
|
4654
|
+
|
|
4655
|
+
const ALERT_CONFIG = new InjectionToken('AlertConfig');
|
|
4656
|
+
class AbstractDialogComponent extends Activity {
|
|
4657
|
+
constructor(config) {
|
|
4658
|
+
super();
|
|
4659
|
+
this.config = config;
|
|
4660
|
+
assert.notNil(config);
|
|
4661
|
+
this.title = Alert.getTitle(config);
|
|
4662
|
+
this.color = this.checkColor(Alert.getColor(config));
|
|
4663
|
+
this.content = Alert.getContent(config);
|
|
4664
|
+
this.confirmFace = {
|
|
4665
|
+
text: () => config.ok(),
|
|
4666
|
+
color: () => this.color || 'primary',
|
|
4667
|
+
style: () => 'raised'
|
|
4668
|
+
};
|
|
4669
|
+
}
|
|
4670
|
+
getConfig() {
|
|
4671
|
+
return lang$1.abstractMethod(this.constructor);
|
|
4672
|
+
}
|
|
4673
|
+
checkColor(rawColor) {
|
|
4674
|
+
if (this.isDestructive()) {
|
|
4675
|
+
return 'warn';
|
|
4676
|
+
}
|
|
4677
|
+
else {
|
|
4678
|
+
if (['primary', 'accent', 'warn'].includes(rawColor)) {
|
|
4679
|
+
return rawColor;
|
|
4680
|
+
}
|
|
4681
|
+
else {
|
|
4682
|
+
console.warn(`Invalid color string ${rawColor}`);
|
|
4683
|
+
return undefined;
|
|
4684
|
+
}
|
|
4685
|
+
}
|
|
4686
|
+
}
|
|
4687
|
+
isDestructive() {
|
|
4688
|
+
// @ts-ignore
|
|
4689
|
+
return _.isFunction(this.config['destructive']) && this.config.destructive();
|
|
4690
|
+
}
|
|
4691
|
+
}
|
|
4692
|
+
AbstractDialogComponent.decorators = [
|
|
4693
|
+
{ type: Component, args: [{
|
|
4694
|
+
template: ''
|
|
4695
|
+
},] }
|
|
4696
|
+
];
|
|
4697
|
+
AbstractDialogComponent.ctorParameters = () => [
|
|
4698
|
+
{ type: undefined, decorators: [{ type: Inject, args: [ALERT_CONFIG,] }] }
|
|
4699
|
+
];
|
|
4700
|
+
|
|
4701
|
+
class AbstractConfirmDialogComponent extends AbstractDialogComponent {
|
|
4702
|
+
constructor(config) {
|
|
4703
|
+
super(config);
|
|
4704
|
+
this.cancelFace = {
|
|
4705
|
+
text: () => config.cancel()
|
|
4706
|
+
};
|
|
4707
|
+
this.cancelCommand = Command.create(() => {
|
|
4708
|
+
return this.cancel();
|
|
4709
|
+
});
|
|
4710
|
+
}
|
|
4711
|
+
}
|
|
4712
|
+
AbstractConfirmDialogComponent.decorators = [
|
|
4713
|
+
{ type: Component, args: [{
|
|
4714
|
+
template: ''
|
|
4715
|
+
},] }
|
|
4716
|
+
];
|
|
4717
|
+
AbstractConfirmDialogComponent.ctorParameters = () => [
|
|
4718
|
+
{ type: undefined, decorators: [{ type: Inject, args: [ALERT_CONFIG,] }] }
|
|
4719
|
+
];
|
|
4205
4720
|
|
|
4206
|
-
class AlertDialogComponent extends
|
|
4721
|
+
class AlertDialogComponent extends AbstractDialogComponent {
|
|
4207
4722
|
constructor(alert) {
|
|
4208
|
-
super();
|
|
4209
|
-
this.alert = alert;
|
|
4723
|
+
super(alert);
|
|
4210
4724
|
this.confirmCommand = Command.create(() => {
|
|
4211
4725
|
this.done();
|
|
4212
4726
|
});
|
|
4213
|
-
this.confirmFace = {
|
|
4214
|
-
text: () => alert.ok(),
|
|
4215
|
-
color: () => "primary",
|
|
4216
|
-
style: () => "raised"
|
|
4217
|
-
};
|
|
4218
|
-
}
|
|
4219
|
-
ngOnInit() {
|
|
4220
4727
|
}
|
|
4221
4728
|
}
|
|
4222
4729
|
AlertDialogComponent.decorators = [
|
|
4223
4730
|
{ type: Component, args: [{
|
|
4224
4731
|
selector: 'aup-alert-dialog',
|
|
4225
|
-
template: "<aup-activity-title *ngIf=\"
|
|
4226
|
-
styles: [":host{display:block}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{margin-bottom:0!important;padding:0;align-items:flex-end;justify-content:flex-end}"]
|
|
4732
|
+
template: "<aup-activity-title *ngIf=\"title\" [color]=\"color\"><aup-markdown [content]=\"title\" [inline]=\"true\"></aup-markdown></aup-activity-title>\n<aup-activity-body>\n <aup-markdown *ngFor=\"let line of content\" [content]=\"line\"></aup-markdown>\n</aup-activity-body>\n<aup-activity-actions [confirmFace]=\"confirmFace\"></aup-activity-actions>\n",
|
|
4733
|
+
styles: [":host{display:block}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{margin-bottom:0!important;padding:0;align-items:flex-end;justify-content:flex-end}\n"]
|
|
4227
4734
|
},] }
|
|
4228
4735
|
];
|
|
4229
4736
|
AlertDialogComponent.ctorParameters = () => [
|
|
4230
|
-
{ type:
|
|
4737
|
+
{ type: Alert, decorators: [{ type: Inject, args: [ACTIVITY_DATA,] }] }
|
|
4231
4738
|
];
|
|
4232
4739
|
|
|
4233
|
-
class ConfirmThenDialogComponent extends
|
|
4740
|
+
class ConfirmThenDialogComponent extends AbstractConfirmDialogComponent {
|
|
4234
4741
|
constructor(config) {
|
|
4235
|
-
super();
|
|
4236
|
-
this.config = config;
|
|
4237
|
-
assert.notNil(config);
|
|
4742
|
+
super(config.confirm);
|
|
4238
4743
|
this.confirmCommand = Command.create(() => {
|
|
4239
|
-
this.interactionContext.startActivity(
|
|
4744
|
+
this.interactionContext.startActivity(config.activityType, config.data)
|
|
4240
4745
|
.then((result) => this.done(result))
|
|
4241
4746
|
.catch(error => this.cancel(error));
|
|
4242
4747
|
});
|
|
4243
|
-
this.cancelCommand = Command.create(() => {
|
|
4244
|
-
return this.cancel();
|
|
4245
|
-
});
|
|
4246
|
-
this.confirmFace = {
|
|
4247
|
-
text: () => this.confirm.ok(),
|
|
4248
|
-
color: () => this.isDestructive() ? 'warn' : 'primary',
|
|
4249
|
-
style: () => 'raised'
|
|
4250
|
-
};
|
|
4251
|
-
this.cancelFace = {
|
|
4252
|
-
text: () => this.confirm.cancel(),
|
|
4253
|
-
};
|
|
4254
|
-
}
|
|
4255
|
-
ngOnInit() {
|
|
4256
|
-
}
|
|
4257
|
-
get confirm() {
|
|
4258
|
-
return this.config.confirm;
|
|
4259
|
-
}
|
|
4260
|
-
get titleColor() {
|
|
4261
|
-
return this.isDestructive() ? 'warn' : undefined;
|
|
4262
|
-
}
|
|
4263
|
-
isDestructive() {
|
|
4264
|
-
return this.confirm.destructive && this.confirm.destructive();
|
|
4265
4748
|
}
|
|
4266
4749
|
}
|
|
4267
4750
|
ConfirmThenDialogComponent.decorators = [
|
|
4268
4751
|
{ type: Component, args: [{
|
|
4269
4752
|
selector: 'aup-confirmation-dialog',
|
|
4270
|
-
template: "<aup-activity-title *ngIf=\"
|
|
4271
|
-
styles: [":host{display:block}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{margin-bottom:0!important;padding:0;align-items:flex-end;justify-content:flex-end}"]
|
|
4753
|
+
template: "<aup-activity-title *ngIf=\"title\" [color]=\"color\"><aup-markdown [content]=\"title\" [inline]=\"true\"></aup-markdown></aup-activity-title>\n<aup-activity-body>\n <aup-markdown *ngFor=\"let line of content\" [content]=\"line\"></aup-markdown>\n</aup-activity-body>\n<aup-activity-actions [confirmFace]=\"confirmFace\" [cancelFace]=\"cancelFace\"></aup-activity-actions>\n",
|
|
4754
|
+
styles: [":host{display:block}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{margin-bottom:0!important;padding:0;align-items:flex-end;justify-content:flex-end}\n"]
|
|
4272
4755
|
},] }
|
|
4273
4756
|
];
|
|
4274
4757
|
ConfirmThenDialogComponent.ctorParameters = () => [
|
|
4275
4758
|
{ type: undefined, decorators: [{ type: Inject, args: [ACTIVITY_DATA,] }] }
|
|
4276
4759
|
];
|
|
4277
4760
|
|
|
4278
|
-
class
|
|
4761
|
+
class ConfirmThenExecuteDialogComponent extends AbstractConfirmDialogComponent {
|
|
4762
|
+
constructor(data) {
|
|
4763
|
+
super(data.confirm);
|
|
4764
|
+
this.confirmCommand = Command.create(() => __awaiter(this, void 0, void 0, function* () {
|
|
4765
|
+
try {
|
|
4766
|
+
const result = yield data.operation(this.interactionContext);
|
|
4767
|
+
this.done(result);
|
|
4768
|
+
}
|
|
4769
|
+
catch (e) {
|
|
4770
|
+
this.cancel(e);
|
|
4771
|
+
}
|
|
4772
|
+
}));
|
|
4773
|
+
}
|
|
4774
|
+
}
|
|
4775
|
+
ConfirmThenExecuteDialogComponent.decorators = [
|
|
4776
|
+
{ type: Component, args: [{
|
|
4777
|
+
selector: 'aup-confirmation-execute-dialog',
|
|
4778
|
+
template: "<aup-activity-title *ngIf=\"title\" [color]=\"color\"><aup-markdown [content]=\"title\" [inline]=\"true\"></aup-markdown></aup-activity-title>\n<aup-activity-body>\n <aup-markdown *ngFor=\"let line of content\" [content]=\"line\"></aup-markdown>\n</aup-activity-body>\n<aup-activity-actions [confirmFace]=\"confirmFace\" [cancelFace]=\"cancelFace\"></aup-activity-actions>\n",
|
|
4779
|
+
styles: [":host{display:block}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{margin-bottom:0!important;padding:0;align-items:flex-end;justify-content:flex-end}\n"]
|
|
4780
|
+
},] }
|
|
4781
|
+
];
|
|
4782
|
+
ConfirmThenExecuteDialogComponent.ctorParameters = () => [
|
|
4783
|
+
{ type: undefined, decorators: [{ type: Inject, args: [ACTIVITY_DATA,] }] }
|
|
4784
|
+
];
|
|
4785
|
+
|
|
4786
|
+
class ConfirmationDialogComponent extends AbstractConfirmDialogComponent {
|
|
4279
4787
|
constructor(confirm) {
|
|
4280
|
-
super();
|
|
4788
|
+
super(confirm);
|
|
4281
4789
|
this.confirm = confirm;
|
|
4282
|
-
assert.notNil(confirm);
|
|
4283
4790
|
this.confirmCommand = Command.create(() => {
|
|
4284
4791
|
return this.done();
|
|
4285
4792
|
});
|
|
4286
|
-
this.cancelCommand = Command.create(() => {
|
|
4287
|
-
return this.cancel();
|
|
4288
|
-
});
|
|
4289
|
-
this.confirmFace = {
|
|
4290
|
-
text: () => confirm.ok(),
|
|
4291
|
-
color: () => this.isDestructive() ? 'warn' : 'primary',
|
|
4292
|
-
style: () => 'raised'
|
|
4293
|
-
};
|
|
4294
|
-
this.cancelFace = {
|
|
4295
|
-
text: () => confirm.cancel(),
|
|
4296
|
-
};
|
|
4297
|
-
}
|
|
4298
|
-
ngOnInit() {
|
|
4299
|
-
}
|
|
4300
|
-
get titleColor() {
|
|
4301
|
-
return this.isDestructive() ? 'warn' : undefined;
|
|
4302
|
-
}
|
|
4303
|
-
isDestructive() {
|
|
4304
|
-
return this.confirm.destructive && this.confirm.destructive();
|
|
4305
4793
|
}
|
|
4306
4794
|
}
|
|
4307
4795
|
ConfirmationDialogComponent.decorators = [
|
|
4308
4796
|
{ type: Component, args: [{
|
|
4309
4797
|
selector: 'aup-confirmation-dialog',
|
|
4310
|
-
template: "<aup-activity-title *ngIf=\"
|
|
4311
|
-
styles: [":host{display:block}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{margin-bottom:0!important;padding:0;align-items:flex-end;justify-content:flex-end}"]
|
|
4798
|
+
template: "<aup-activity-title *ngIf=\"title\" [color]=\"color\"><aup-markdown [content]=\"title\" [inline]=\"true\"></aup-markdown></aup-activity-title>\n<aup-activity-body>\n <aup-markdown *ngFor=\"let line of content\" [content]=\"line\"></aup-markdown>\n</aup-activity-body>\n<aup-activity-actions [confirmFace]=\"confirmFace\" [cancelFace]=\"cancelFace\"></aup-activity-actions>\n\n",
|
|
4799
|
+
styles: [":host{display:block}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{margin-bottom:0!important;padding:0;align-items:flex-end;justify-content:flex-end}\n"]
|
|
4312
4800
|
},] }
|
|
4313
4801
|
];
|
|
4314
4802
|
ConfirmationDialogComponent.ctorParameters = () => [
|
|
@@ -4345,6 +4833,12 @@ class AbstractInteractionContext {
|
|
|
4345
4833
|
data: data
|
|
4346
4834
|
}, true);
|
|
4347
4835
|
}
|
|
4836
|
+
confirmThenExecute(confirm, operation) {
|
|
4837
|
+
return this.createAndLaunchActivity(ConfirmThenExecuteDialogComponent, {
|
|
4838
|
+
confirm,
|
|
4839
|
+
operation: operation
|
|
4840
|
+
}, true);
|
|
4841
|
+
}
|
|
4348
4842
|
}
|
|
4349
4843
|
|
|
4350
4844
|
class ActivityRef {
|
|
@@ -4450,7 +4944,7 @@ ActivityOutletComponent.decorators = [
|
|
|
4450
4944
|
{ type: Component, args: [{
|
|
4451
4945
|
selector: 'aup-activity-outlet',
|
|
4452
4946
|
template: '',
|
|
4453
|
-
styles: [":host{display:block}"]
|
|
4947
|
+
styles: [":host{display:block}\n"]
|
|
4454
4948
|
},] }
|
|
4455
4949
|
];
|
|
4456
4950
|
ActivityOutletComponent.ctorParameters = () => [
|
|
@@ -4470,7 +4964,7 @@ class ActivityContainerComponent extends AbstractInteractionContext {
|
|
|
4470
4964
|
this.activityRefs = [];
|
|
4471
4965
|
this.garbage = new GarbageCollector();
|
|
4472
4966
|
this.inAnimation = new MutableValueModel(false);
|
|
4473
|
-
this.busy = new DelegatingValueModel().withDefault(false);
|
|
4967
|
+
this.busy = this.registerDisposable(new DelegatingValueModel().withDefault(false));
|
|
4474
4968
|
this.registerDisposable(this.busy);
|
|
4475
4969
|
}
|
|
4476
4970
|
ngOnInit() {
|
|
@@ -4646,8 +5140,8 @@ class ActivityContainerComponent extends AbstractInteractionContext {
|
|
|
4646
5140
|
ActivityContainerComponent.decorators = [
|
|
4647
5141
|
{ type: Component, args: [{
|
|
4648
5142
|
selector: 'aup-activity-container',
|
|
4649
|
-
template: "<mat-tab-group #tabs no-tab-header\n [dynamicHeight]=\"dynamicHeight\"\n [class.full-height-tabs]=\"!dynamicHeight\">\n <mat-tab *ngFor=\"let activityRef of activityRefs; let i = index; trackBy: activityIndex\">\n <aup-busy-overlay [busyModel]=\"busy\">\n <!--\n We have issues where angular is triggering a leave animation when an\n new activity is started, but is not running the enter animation\n when it is scrolled back into view. So we track the tab changes and\n disable all animations inside the tab while we're animating.\n -->\n <div class=\"activity-outlet-wrapper\" [@.disabled]=\"!activityRef.focused\">\n <aup-activity-outlet [nestedInteractionContext]=\"this\" [activityRef]=\"activityRef\"></aup-activity-outlet>\n </div>\n </aup-busy-overlay>\n </mat-tab>\n</mat-tab-group>\n",
|
|
4650
|
-
styles: [":host{display:flex;flex-direction:column}
|
|
5143
|
+
template: "<mat-tab-group #tabs no-tab-header\n [dynamicHeight]=\"dynamicHeight\"\n [class.full-height-tabs]=\"!dynamicHeight\">\n <mat-tab *ngFor=\"let activityRef of activityRefs; let i = index; trackBy: activityIndex\">\n <aup-busy-overlay [busyModel]=\"busy\" cdkTrapFocus cdkTrapFocusAutoCapture>\n <!--\n We have issues where angular is triggering a leave animation when an\n new activity is started, but is not running the enter animation\n when it is scrolled back into view. So we track the tab changes and\n disable all animations inside the tab while we're animating.\n -->\n <div class=\"activity-outlet-wrapper\" [@.disabled]=\"!activityRef.focused\">\n <aup-activity-outlet [nestedInteractionContext]=\"this\" [activityRef]=\"activityRef\"></aup-activity-outlet>\n </div>\n </aup-busy-overlay>\n </mat-tab>\n</mat-tab-group>\n",
|
|
5144
|
+
styles: [":host{display:flex;flex-direction:column}mat-tab-group{flex:1}aup-busy-overlay{flex:1}\n"]
|
|
4651
5145
|
},] }
|
|
4652
5146
|
];
|
|
4653
5147
|
ActivityContainerComponent.ctorParameters = () => [];
|
|
@@ -4700,7 +5194,7 @@ ActivityTitleComponent.decorators = [
|
|
|
4700
5194
|
{ type: Component, args: [{
|
|
4701
5195
|
selector: 'aup-activity-title',
|
|
4702
5196
|
template: "<ng-content></ng-content>\n",
|
|
4703
|
-
styles: [":host{display:block}"]
|
|
5197
|
+
styles: [":host{display:block}\n"]
|
|
4704
5198
|
},] }
|
|
4705
5199
|
];
|
|
4706
5200
|
ActivityTitleComponent.propDecorators = {
|
|
@@ -4725,6 +5219,9 @@ class AbstractActivityTriggerComponent extends DisposableComponent {
|
|
|
4725
5219
|
});
|
|
4726
5220
|
});
|
|
4727
5221
|
}
|
|
5222
|
+
get interactionContext() {
|
|
5223
|
+
return lang$1.abstractMethod(this.constructor);
|
|
5224
|
+
}
|
|
4728
5225
|
ngOnInit() {
|
|
4729
5226
|
}
|
|
4730
5227
|
get isActive() {
|
|
@@ -4890,7 +5387,7 @@ InteractionService.ctorParameters = () => [
|
|
|
4890
5387
|
constructor() {
|
|
4891
5388
|
super();
|
|
4892
5389
|
this._interactions = new MutableListModel();
|
|
4893
|
-
this._disabledDelegate = new DelegatingValueModel().withDefault(false);
|
|
5390
|
+
this._disabledDelegate = this.registerDisposable(new DelegatingValueModel().withDefault(false));
|
|
4894
5391
|
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
4895
5392
|
this.active = chain(this._interactions).isNotEmpty();
|
|
4896
5393
|
this.interactionContextIds = chain(this._interactions).pluck("identifier");
|
|
@@ -4946,14 +5443,17 @@ InteractionService.ctorParameters = () => [
|
|
|
4946
5443
|
class ModalActivityTriggerComponent extends AbstractActivityTriggerComponent {
|
|
4947
5444
|
constructor(interactionService) {
|
|
4948
5445
|
super();
|
|
4949
|
-
this.
|
|
5446
|
+
this._interactionContext = interactionService.createModalInteractionContextDisposedWith(this);
|
|
5447
|
+
}
|
|
5448
|
+
get interactionContext() {
|
|
5449
|
+
return this._interactionContext;
|
|
4950
5450
|
}
|
|
4951
5451
|
}
|
|
4952
5452
|
ModalActivityTriggerComponent.decorators = [
|
|
4953
5453
|
{ type: Component, args: [{
|
|
4954
5454
|
selector: 'aup-modal-activity-trigger',
|
|
4955
5455
|
template: "<aup-command [command]=\"startActivityCommand\" [faceModel]=\"faceModel\" [alignFace]=\"alignFace\"></aup-command>\n",
|
|
4956
|
-
styles: [":host{display:inline-block}"]
|
|
5456
|
+
styles: [":host{display:inline-block}\n"]
|
|
4957
5457
|
},] }
|
|
4958
5458
|
];
|
|
4959
5459
|
ModalActivityTriggerComponent.ctorParameters = () => [
|
|
@@ -4986,6 +5486,9 @@ class InPlaceInteractionContextComponent extends DisposableComponent {
|
|
|
4986
5486
|
var _a;
|
|
4987
5487
|
return this.animateFirstActivity ? (((_a = this.tabConfig) === null || _a === void 0 ? void 0 : _a.animationDuration) || '500ms') : '0ms';
|
|
4988
5488
|
}
|
|
5489
|
+
get active() {
|
|
5490
|
+
return this.isActive();
|
|
5491
|
+
}
|
|
4989
5492
|
ngAfterViewInit() {
|
|
4990
5493
|
this.interactionService.registerInplaceInteractionContext(this);
|
|
4991
5494
|
}
|
|
@@ -5010,6 +5513,9 @@ class InPlaceInteractionContextComponent extends DisposableComponent {
|
|
|
5010
5513
|
confirmThen(confirm, activityType, data) {
|
|
5011
5514
|
return this.activityContainerComponent.confirmThen(confirm, activityType);
|
|
5012
5515
|
}
|
|
5516
|
+
confirmThenExecute(confirm, operation) {
|
|
5517
|
+
return this.activityContainerComponent.confirmThenExecute(confirm, operation);
|
|
5518
|
+
}
|
|
5013
5519
|
isActive() {
|
|
5014
5520
|
return this.activityContainerComponent.isActive();
|
|
5015
5521
|
}
|
|
@@ -5021,7 +5527,7 @@ InPlaceInteractionContextComponent.decorators = [
|
|
|
5021
5527
|
{ type: Component, args: [{
|
|
5022
5528
|
selector: 'aup-in-place-interaction-context',
|
|
5023
5529
|
template: "<mat-tab-group no-tab-header [selectedIndex]=\"isActive() ? 1 : 0\" full-height-tabs [dynamicHeight]=\"false\" [animationDuration]=\"animationDuration\">\n <mat-tab>\n <ng-content></ng-content>\n </mat-tab>\n <mat-tab>\n <aup-activity-container #activityContainer [dynamicHeight]=\"false\"></aup-activity-container>\n </mat-tab>\n</mat-tab-group>\n\n",
|
|
5024
|
-
styles: [":host{display:flex;flex-direction:column}mat-tab-group{flex:1}"]
|
|
5530
|
+
styles: [":host{display:flex;flex-direction:column}mat-tab-group{flex:1}\n"]
|
|
5025
5531
|
},] }
|
|
5026
5532
|
];
|
|
5027
5533
|
InPlaceInteractionContextComponent.ctorParameters = () => [
|
|
@@ -5030,8 +5536,80 @@ InPlaceInteractionContextComponent.ctorParameters = () => [
|
|
|
5030
5536
|
];
|
|
5031
5537
|
InPlaceInteractionContextComponent.propDecorators = {
|
|
5032
5538
|
activityContainerComponent: [{ type: ViewChild, args: ['activityContainer', { static: true },] }],
|
|
5033
|
-
animateFirstActivity: [{ type: Input }]
|
|
5539
|
+
animateFirstActivity: [{ type: Input }],
|
|
5540
|
+
active: [{ type: HostBinding, args: ["class.active",] }]
|
|
5541
|
+
};
|
|
5542
|
+
|
|
5543
|
+
/**
|
|
5544
|
+
*
|
|
5545
|
+
*/
|
|
5546
|
+
class AddCardActivityComponent extends AbstractActivityTriggerComponent {
|
|
5547
|
+
constructor(interactionService) {
|
|
5548
|
+
super();
|
|
5549
|
+
this.interactionStyle = AddCardActivityComponent.InteractionType.MODAL;
|
|
5550
|
+
this.renderAs = AddCardActivityComponent.RenderAs.CARD;
|
|
5551
|
+
this.notCard = true;
|
|
5552
|
+
const { chain } = Dsl.disposeWith(this);
|
|
5553
|
+
this.modalInteractionContext = interactionService.createModalInteractionContextDisposedWith(this);
|
|
5554
|
+
this.faceList = chain(this.faceModel).mapToList(face => [face]);
|
|
5555
|
+
}
|
|
5556
|
+
get renderAsClass() {
|
|
5557
|
+
return `render-as-${this.renderAs}`;
|
|
5558
|
+
}
|
|
5559
|
+
get activityTypeClass() {
|
|
5560
|
+
return `${this.interactionStyle}-activity`;
|
|
5561
|
+
}
|
|
5562
|
+
isRenderAsCard() {
|
|
5563
|
+
return this.renderAs === 'card';
|
|
5564
|
+
}
|
|
5565
|
+
isRenderAsButton() {
|
|
5566
|
+
return this.renderAs === 'button';
|
|
5567
|
+
}
|
|
5568
|
+
ngOnInit() {
|
|
5569
|
+
}
|
|
5570
|
+
get interactionContext() {
|
|
5571
|
+
switch (this.interactionStyle) {
|
|
5572
|
+
case 'inline':
|
|
5573
|
+
return this.inlineInteractionContext;
|
|
5574
|
+
default:
|
|
5575
|
+
return this.modalInteractionContext;
|
|
5576
|
+
}
|
|
5577
|
+
}
|
|
5578
|
+
isModal() {
|
|
5579
|
+
return this.interactionStyle === 'modal';
|
|
5580
|
+
}
|
|
5581
|
+
isInline() {
|
|
5582
|
+
return this.interactionStyle === 'inline';
|
|
5583
|
+
}
|
|
5584
|
+
}
|
|
5585
|
+
AddCardActivityComponent.decorators = [
|
|
5586
|
+
{ type: Component, args: [{
|
|
5587
|
+
selector: 'aup-add-card-activity',
|
|
5588
|
+
template: "<aup-in-place-interaction-context [animateFirstActivity]=\"false\" [pectinCommand]=\"startActivityCommand\">\n <aup-command *ngIf=\"isRenderAsButton()\" [command]=\"startActivityCommand\" [faceModel]=\"faceModel\" [alignFace]=\"alignFace\"></aup-command>\n <section *ngIf=\"isRenderAsCard()\" class=\"face-wrapper\">\n <aup-command-face class=\"mat-button\" [faces]=\"faceList.value\"></aup-command-face>\n </section>\n</aup-in-place-interaction-context>\n",
|
|
5589
|
+
styles: [":host{display:flex;flex-direction:column;align-items:stretch;background-color:#fff}:host[interactionStyle=inline][renderas=card]:not(.active){transition:box-shadow .28s cubic-bezier(.4,0,.2,1);box-sizing:border-box;border:2px dashed rgba(0,0,0,.1);border-radius:6px;font-weight:300;cursor:pointer;color:#0000008a;background-color:#fffc}:host[interactionStyle=inline][renderas=card]:not(.active):hover{box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}:host[interactionStyle=inline][renderas=card]:not(.active):hover{border-color:transparent;background-color:#fff;color:#0000008a}:host[interactionStyle=modal][renderas=card]{transition:box-shadow .28s cubic-bezier(.4,0,.2,1);box-sizing:border-box;border:2px dashed rgba(0,0,0,.1);border-radius:6px;font-weight:300;cursor:pointer;color:#0000008a;background-color:#fffc}:host[interactionStyle=modal][renderas=card]:hover{box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}:host[interactionStyle=modal][renderas=card]:hover{border-color:transparent;background-color:#fff;color:#0000008a}:host-context(aup-card-container)[renderas=button]{align-self:start}section.face-wrapper{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center}aup-in-place-interaction-context{flex:1}aup-in-place-interaction-context.active{border:3px solid #6273c7;border-radius:4px;overflow:hidden}\n"]
|
|
5590
|
+
},] }
|
|
5591
|
+
];
|
|
5592
|
+
AddCardActivityComponent.ctorParameters = () => [
|
|
5593
|
+
{ type: InteractionService }
|
|
5594
|
+
];
|
|
5595
|
+
AddCardActivityComponent.propDecorators = {
|
|
5596
|
+
inlineInteractionContext: [{ type: ViewChild, args: [InPlaceInteractionContextComponent, { static: true },] }],
|
|
5597
|
+
interactionStyle: [{ type: Input }],
|
|
5598
|
+
renderAs: [{ type: Input }, { type: HostBinding, args: ['class',] }],
|
|
5599
|
+
notCard: [{ type: HostBinding, args: ['class.not-card',] }],
|
|
5600
|
+
renderAsClass: [{ type: HostBinding, args: ['class',] }],
|
|
5601
|
+
activityTypeClass: [{ type: HostBinding, args: ['class',] }]
|
|
5034
5602
|
};
|
|
5603
|
+
(function (AddCardActivityComponent) {
|
|
5604
|
+
AddCardActivityComponent.InteractionType = Enum({
|
|
5605
|
+
MODAL: 'modal',
|
|
5606
|
+
INLINE: 'inline'
|
|
5607
|
+
});
|
|
5608
|
+
AddCardActivityComponent.RenderAs = Enum({
|
|
5609
|
+
CARD: 'card',
|
|
5610
|
+
BUTTON: 'button'
|
|
5611
|
+
});
|
|
5612
|
+
})(AddCardActivityComponent || (AddCardActivityComponent = {}));
|
|
5035
5613
|
|
|
5036
5614
|
/**
|
|
5037
5615
|
* Css Vars.
|
|
@@ -5071,7 +5649,7 @@ AddItemInteractionContextComponent.decorators = [
|
|
|
5071
5649
|
{ type: Component, args: [{
|
|
5072
5650
|
selector: 'aup-add-item-interaction-context',
|
|
5073
5651
|
template: "<aup-in-place-interaction-context [animateFirstActivity]=\"false\">\n <a part=\"link\" class=\"link\" [pectinCommand]=\"clickCommand\"><aup-icon [icon]=\"icon\"></aup-icon> {{label}}</a>\n</aup-in-place-interaction-context>\n",
|
|
5074
|
-
styles: [":host{--def-link-color:var(--link-color,currentColor);--def-link-color-hover:var(--link-color-hover,currentColor);--def-link-background:var(--link-background,transparent);--def-link-background-hover:var(--link-background-hover,rgba(0,0,0,
|
|
5652
|
+
styles: [":host{--def-link-color: var(--link-color, currentColor);--def-link-color-hover: var(--link-color-hover, currentColor);--def-link-background: var(--link-background, transparent);--def-link-background-hover: var(--link-background-hover, rgba(0, 0, 0, .05));--def-link-border-radius: var(--link-border-radius, 4px);--def-link-padding: var(--link-padding, calc(var(--aup-default-padding) / 2));display:flex;flex-direction:column;border-radius:var(--def-link-border-radius);box-sizing:border-box;outline:none}:host:hover a.link{color:var(--def-link-color-hover);background-color:var(--def-link-background-hover)}aup-in-place-interaction-context{border-radius:var(--def-link-border-radius)}a.link{display:flex;flex-direction:row;align-items:center;border-radius:var(--def-link-border-radius);color:var(--def-link-color);background:var(--def-link-background);padding:var(--def-link-padding);cursor:pointer;text-decoration:none}a.link mat-icon{margin-right:8px}\n"]
|
|
5075
5653
|
},] }
|
|
5076
5654
|
];
|
|
5077
5655
|
AddItemInteractionContextComponent.ctorParameters = () => [];
|
|
@@ -5094,17 +5672,20 @@ class InlineActivityTriggerComponent extends AbstractActivityTriggerComponent {
|
|
|
5094
5672
|
constructor() {
|
|
5095
5673
|
super();
|
|
5096
5674
|
}
|
|
5675
|
+
get interactionContext() {
|
|
5676
|
+
return this._interactionContext;
|
|
5677
|
+
}
|
|
5097
5678
|
}
|
|
5098
5679
|
InlineActivityTriggerComponent.decorators = [
|
|
5099
5680
|
{ type: Component, args: [{
|
|
5100
5681
|
selector: 'aup-inline-activity-trigger',
|
|
5101
5682
|
template: "<aup-in-place-interaction-context #interactionContext [animateFirstActivity]=\"false\">\n <aup-command [command]=\"startActivityCommand\" [faceModel]=\"faceModel\" [alignFace]=\"alignFace\"></aup-command>\n</aup-in-place-interaction-context>\n",
|
|
5102
|
-
styles: [":host{display:inline-block}"]
|
|
5683
|
+
styles: [":host{display:inline-block}\n"]
|
|
5103
5684
|
},] }
|
|
5104
5685
|
];
|
|
5105
5686
|
InlineActivityTriggerComponent.ctorParameters = () => [];
|
|
5106
5687
|
InlineActivityTriggerComponent.propDecorators = {
|
|
5107
|
-
|
|
5688
|
+
_interactionContext: [{ type: ViewChild, args: [InPlaceInteractionContextComponent, { static: true },] }]
|
|
5108
5689
|
};
|
|
5109
5690
|
|
|
5110
5691
|
/**
|
|
@@ -5135,6 +5716,7 @@ class PopupInteractionContextComponent extends DisposableComponent {
|
|
|
5135
5716
|
const self = this;
|
|
5136
5717
|
const overlayRef = this._overlay.create({
|
|
5137
5718
|
hasBackdrop: false,
|
|
5719
|
+
disposeOnNavigation: true,
|
|
5138
5720
|
panelClass: 'aup-popup-interaction-panel',
|
|
5139
5721
|
positionStrategy: this._overlay.position()
|
|
5140
5722
|
.flexibleConnectedTo(this._element)
|
|
@@ -5189,7 +5771,7 @@ PopupInteractionContextComponent.decorators = [
|
|
|
5189
5771
|
{ type: Component, args: [{
|
|
5190
5772
|
selector: 'aup-popup-interaction-context',
|
|
5191
5773
|
template: "<ng-content></ng-content>\n",
|
|
5192
|
-
styles: [":host{display:inline-block}:host.interaction-active{background:rgba(0,0,0,.05)}"]
|
|
5774
|
+
styles: [":host{display:inline-block}:host.interaction-active{background:rgba(0,0,0,.05)}\n"]
|
|
5193
5775
|
},] }
|
|
5194
5776
|
];
|
|
5195
5777
|
PopupInteractionContextComponent.ctorParameters = () => [
|
|
@@ -5265,44 +5847,93 @@ InteractionContextTriggerFor.propDecorators = {
|
|
|
5265
5847
|
// @see https://github.com/ng-packagr/ng-packagr/issues/641 and https://github.com/angular/angular/issues/21123
|
|
5266
5848
|
// we're getting a metadata error for D for no reason that I can find and only during the build (ng serve works fine)
|
|
5267
5849
|
// @dynamic
|
|
5268
|
-
class
|
|
5850
|
+
class InputActivity extends Activity {
|
|
5269
5851
|
constructor(data) {
|
|
5852
|
+
var _a, _b;
|
|
5270
5853
|
super();
|
|
5271
5854
|
this.data = data;
|
|
5272
5855
|
this.class = 'aup-input-activity';
|
|
5273
5856
|
const form = new DirtyTrackingForm();
|
|
5274
5857
|
this.valueModel = form.valueModel(this.data.initialValue);
|
|
5275
5858
|
this.valueModel.validateUsing(data.validators || []);
|
|
5276
|
-
|
|
5859
|
+
// TODO: move to global configuration
|
|
5860
|
+
this.confirmFace = (_a = data.confirmFace) !== null && _a !== void 0 ? _a : {
|
|
5861
|
+
icon: () => 'mat:check'
|
|
5862
|
+
};
|
|
5863
|
+
this.cancelFace = (_b = data.cancelFace) !== null && _b !== void 0 ? _b : {
|
|
5864
|
+
icon: () => 'mat:clear'
|
|
5865
|
+
};
|
|
5866
|
+
this.confirmCommand = Command.create(() => __awaiter(this, void 0, void 0, function* () {
|
|
5277
5867
|
if (this.valueModel.validate()) {
|
|
5278
5868
|
if (data.save) {
|
|
5279
|
-
|
|
5280
|
-
|
|
5869
|
+
const self = this;
|
|
5870
|
+
try {
|
|
5871
|
+
let allGood = true;
|
|
5872
|
+
const result = yield data.save(this.valueModel.value, {
|
|
5873
|
+
injectError(error) {
|
|
5874
|
+
allGood = false;
|
|
5875
|
+
self.valueModel.injectErrors([error]);
|
|
5876
|
+
}
|
|
5877
|
+
});
|
|
5878
|
+
if (allGood) {
|
|
5879
|
+
this.done(this.valueModel.value);
|
|
5880
|
+
}
|
|
5881
|
+
}
|
|
5882
|
+
catch (e) {
|
|
5883
|
+
console.error(e);
|
|
5884
|
+
}
|
|
5281
5885
|
}
|
|
5282
5886
|
else {
|
|
5283
5887
|
this.done(this.valueModel.value);
|
|
5284
5888
|
}
|
|
5285
5889
|
}
|
|
5286
|
-
});
|
|
5890
|
+
}));
|
|
5287
5891
|
this.cancelCommand = Command.create(() => {
|
|
5288
5892
|
this.cancel();
|
|
5289
5893
|
});
|
|
5894
|
+
this.busyWhile(this.confirmCommand.busy);
|
|
5895
|
+
}
|
|
5896
|
+
get layout() {
|
|
5897
|
+
var _a, _b;
|
|
5898
|
+
return (_b = (_a = this.data) === null || _a === void 0 ? void 0 : _a.layout) !== null && _b !== void 0 ? _b : InputActivity.Layout.BLOCK;
|
|
5290
5899
|
}
|
|
5291
5900
|
onActivityReady() {
|
|
5292
5901
|
this.valueModel.focusContext.requestFocus();
|
|
5293
5902
|
}
|
|
5903
|
+
get additionalCssClassName() {
|
|
5904
|
+
var _a;
|
|
5905
|
+
return (_a = this.data.cssClassName) !== null && _a !== void 0 ? _a : '';
|
|
5906
|
+
}
|
|
5907
|
+
onEscape() {
|
|
5908
|
+
if (this.shouldCancelOnEscape() && this.cancelCommand.enabled.value) {
|
|
5909
|
+
this.cancelCommand.execute();
|
|
5910
|
+
}
|
|
5911
|
+
}
|
|
5912
|
+
shouldCancelOnEscape() {
|
|
5913
|
+
return _.isNil(this.data.cancelOnEscape) // we default to true..
|
|
5914
|
+
|| this.data.cancelOnEscape;
|
|
5915
|
+
}
|
|
5294
5916
|
}
|
|
5295
|
-
|
|
5917
|
+
InputActivity.decorators = [
|
|
5296
5918
|
{ type: Component, args: [{ template: `` },] }
|
|
5297
5919
|
];
|
|
5298
|
-
|
|
5920
|
+
InputActivity.ctorParameters = () => [
|
|
5299
5921
|
{ type: undefined, decorators: [{ type: Inject, args: [ACTIVITY_DATA,] }] }
|
|
5300
5922
|
];
|
|
5301
|
-
|
|
5302
|
-
class: [{ type: HostBinding, args: ['class',] }]
|
|
5923
|
+
InputActivity.propDecorators = {
|
|
5924
|
+
class: [{ type: HostBinding, args: ['class',] }],
|
|
5925
|
+
layout: [{ type: Input }, { type: HostBinding, args: ['attr.layout',] }],
|
|
5926
|
+
additionalCssClassName: [{ type: HostBinding, args: ["class",] }],
|
|
5927
|
+
onEscape: [{ type: HostListener, args: ['keydown.escape',] }]
|
|
5303
5928
|
};
|
|
5929
|
+
(function (InputActivity) {
|
|
5930
|
+
InputActivity.Layout = Enum({
|
|
5931
|
+
INLINE: 'inline',
|
|
5932
|
+
BLOCK: 'block'
|
|
5933
|
+
});
|
|
5934
|
+
})(InputActivity || (InputActivity = {}));
|
|
5304
5935
|
|
|
5305
|
-
class StringInputActivity extends
|
|
5936
|
+
class StringInputActivity extends InputActivity {
|
|
5306
5937
|
}
|
|
5307
5938
|
StringInputActivity.decorators = [
|
|
5308
5939
|
{ type: Component, args: [{
|
|
@@ -5313,13 +5944,15 @@ StringInputActivity.decorators = [
|
|
|
5313
5944
|
[placeholder]="data.placeholder"
|
|
5314
5945
|
[command.enter]="confirmCommand"
|
|
5315
5946
|
[command.escape]="cancelCommand"></aup-string-input>
|
|
5316
|
-
<aup-activity-actions align="end"
|
|
5317
|
-
[
|
|
5947
|
+
<aup-activity-actions [layout]="layout" align="end"
|
|
5948
|
+
[confirmFace]="confirmFace"
|
|
5949
|
+
[cancelFace]="cancelFace"
|
|
5950
|
+
></aup-activity-actions>
|
|
5318
5951
|
`
|
|
5319
5952
|
},] }
|
|
5320
5953
|
];
|
|
5321
5954
|
|
|
5322
|
-
class SelectInputActivity extends
|
|
5955
|
+
class SelectInputActivity extends InputActivity {
|
|
5323
5956
|
constructor() {
|
|
5324
5957
|
super(...arguments);
|
|
5325
5958
|
this.defaultOptionLabelFormat = (option) => {
|
|
@@ -5347,7 +5980,9 @@ SelectInputActivity.decorators = [
|
|
|
5347
5980
|
[options]="options"
|
|
5348
5981
|
[optionLabelFormat]="optionLabelFormat"
|
|
5349
5982
|
></aup-select-input>
|
|
5350
|
-
<aup-activity-actions
|
|
5983
|
+
<aup-activity-actions [layout]="layout" align="end"
|
|
5984
|
+
[confirmFace]="confirmFace"
|
|
5985
|
+
[cancelFace]="cancelFace"
|
|
5351
5986
|
></aup-activity-actions>
|
|
5352
5987
|
`
|
|
5353
5988
|
},] }
|
|
@@ -5453,32 +6088,6 @@ class TableModel extends AbstractTableModel {
|
|
|
5453
6088
|
}
|
|
5454
6089
|
}
|
|
5455
6090
|
|
|
5456
|
-
class SelfAndDescendantsVisitor {
|
|
5457
|
-
constructor() {
|
|
5458
|
-
}
|
|
5459
|
-
visit(it) {
|
|
5460
|
-
this.onVisit(it);
|
|
5461
|
-
if (this.shouldVisitChildrenOf(it)) {
|
|
5462
|
-
it.visitChildren(this);
|
|
5463
|
-
}
|
|
5464
|
-
}
|
|
5465
|
-
shouldVisitChildrenOf(it) {
|
|
5466
|
-
return true;
|
|
5467
|
-
}
|
|
5468
|
-
}
|
|
5469
|
-
(function (SelfAndDescendantsVisitor) {
|
|
5470
|
-
class Each extends SelfAndDescendantsVisitor {
|
|
5471
|
-
constructor(callback) {
|
|
5472
|
-
super();
|
|
5473
|
-
this.callback = callback;
|
|
5474
|
-
}
|
|
5475
|
-
onVisit(it) {
|
|
5476
|
-
this.callback(it);
|
|
5477
|
-
}
|
|
5478
|
-
}
|
|
5479
|
-
SelfAndDescendantsVisitor.Each = Each;
|
|
5480
|
-
})(SelfAndDescendantsVisitor || (SelfAndDescendantsVisitor = {}));
|
|
5481
|
-
|
|
5482
6091
|
/**
|
|
5483
6092
|
* @file Automatically generated by barrelsby.
|
|
5484
6093
|
*/
|
|
@@ -5489,20 +6098,222 @@ class PopupActivityTriggerComponent extends AbstractActivityTriggerComponent {
|
|
|
5489
6098
|
this.anchorX = 'start';
|
|
5490
6099
|
this.anchorY = 'bottom';
|
|
5491
6100
|
}
|
|
6101
|
+
get interactionContext() {
|
|
6102
|
+
return this._interactionContext;
|
|
6103
|
+
}
|
|
5492
6104
|
}
|
|
5493
6105
|
PopupActivityTriggerComponent.decorators = [
|
|
5494
6106
|
{ type: Component, args: [{
|
|
5495
6107
|
selector: 'aup-popup-activity-trigger',
|
|
5496
6108
|
template: "<aup-popup-interaction-context [anchorX]=\"anchorX\" [anchorY]=\"anchorY\">\n <aup-command [command]=\"startActivityCommand\" [faceModel]=\"faceModel\" [alignFace]=\"alignFace\"></aup-command>\n</aup-popup-interaction-context>\n",
|
|
5497
|
-
styles: [":host{display:inline-block}"]
|
|
6109
|
+
styles: [":host{display:inline-block}\n"]
|
|
5498
6110
|
},] }
|
|
5499
6111
|
];
|
|
5500
6112
|
PopupActivityTriggerComponent.ctorParameters = () => [];
|
|
5501
6113
|
PopupActivityTriggerComponent.propDecorators = {
|
|
5502
6114
|
anchorX: [{ type: Input }],
|
|
5503
6115
|
anchorY: [{ type: Input }],
|
|
5504
|
-
|
|
6116
|
+
_interactionContext: [{ type: ViewChild, args: [PopupInteractionContextComponent, { static: true },] }]
|
|
6117
|
+
};
|
|
6118
|
+
|
|
6119
|
+
class InlineEditorModel extends GarbageCollector {
|
|
6120
|
+
constructor(valueModel, saveCallback) {
|
|
6121
|
+
super();
|
|
6122
|
+
this.valueModel = valueModel;
|
|
6123
|
+
this.saveCallback = saveCallback;
|
|
6124
|
+
this.editing = new MutableValueModel(false);
|
|
6125
|
+
this._validators = new MutableListModel();
|
|
6126
|
+
this._editingEnabled = this.registerDisposable(new DelegatingValueModel().withDefault(true));
|
|
6127
|
+
assert.notNil(valueModel);
|
|
6128
|
+
const { when } = Dsl.disposeWith(this);
|
|
6129
|
+
when(this.editingEnabled).becomesFalsey(() => this.cancelEdit());
|
|
6130
|
+
}
|
|
6131
|
+
get editingEnabled() {
|
|
6132
|
+
return this._editingEnabled.readonly;
|
|
6133
|
+
}
|
|
6134
|
+
disableWhile(condition) {
|
|
6135
|
+
const { chain } = Dsl.disposeWith(this);
|
|
6136
|
+
this.enableWhile(chain(condition).isFalsey());
|
|
6137
|
+
return this;
|
|
6138
|
+
}
|
|
6139
|
+
enableWhile(condition) {
|
|
6140
|
+
this._editingEnabled.setDelegate(condition);
|
|
6141
|
+
return this;
|
|
6142
|
+
}
|
|
6143
|
+
get validators() {
|
|
6144
|
+
return this._validators.readonly;
|
|
6145
|
+
}
|
|
6146
|
+
validateUsing(validator) {
|
|
6147
|
+
this._validators.push(validator);
|
|
6148
|
+
return this;
|
|
6149
|
+
}
|
|
6150
|
+
isEditing() {
|
|
6151
|
+
return this.editing.value;
|
|
6152
|
+
}
|
|
6153
|
+
cancelEdit() {
|
|
6154
|
+
this.editing.value = false;
|
|
6155
|
+
}
|
|
6156
|
+
startEditing() {
|
|
6157
|
+
this.editing.value = true;
|
|
6158
|
+
}
|
|
6159
|
+
}
|
|
6160
|
+
(function (InlineEditorModel) {
|
|
6161
|
+
function create(valueModel, options) {
|
|
6162
|
+
return new InlineEditorModel(valueModel, options.save);
|
|
6163
|
+
}
|
|
6164
|
+
InlineEditorModel.create = create;
|
|
6165
|
+
})(InlineEditorModel || (InlineEditorModel = {}));
|
|
6166
|
+
TrackExternal.oneTimeBinding(InlineEditorModel);
|
|
6167
|
+
|
|
6168
|
+
/**
|
|
6169
|
+
* @example
|
|
6170
|
+
* const source: ValueModel<string> = ...;
|
|
6171
|
+
* const model = InlineEditorModel.create(source, {
|
|
6172
|
+
* save(updated:string, context: EditContext) => {
|
|
6173
|
+
* try {
|
|
6174
|
+
* try and save the thing...
|
|
6175
|
+
* } catch(error) {
|
|
6176
|
+
* context.injectError(error)
|
|
6177
|
+
* }
|
|
6178
|
+
* }).validateUsing(Validator.present("We'll need a value");
|
|
6179
|
+
*
|
|
6180
|
+
* # in the view
|
|
6181
|
+
* <aup-inline-string-editor
|
|
6182
|
+
* label="My field"
|
|
6183
|
+
* placeHolder="I'm ready for a string..."
|
|
6184
|
+
* [editorModel]="model"></aup-inline-string-editor>
|
|
6185
|
+
*/
|
|
6186
|
+
class InlineStringEditorComponent extends DisposableComponent {
|
|
6187
|
+
constructor(interactionService) {
|
|
6188
|
+
super();
|
|
6189
|
+
this.editingEnabled = this.registerDisposable(new DelegatingValueModel());
|
|
6190
|
+
const { chain, when, valueOf } = Dsl.disposeWith(this);
|
|
6191
|
+
const modalIC = interactionService.createModalInteractionContextDisposedWith(this);
|
|
6192
|
+
const resolvedFacesModel = chain(this.facesModel).map(userFaces => {
|
|
6193
|
+
return Object.assign(Object.assign({}, InlineStringEditorComponent.DEFAULT_FACES), userFaces);
|
|
6194
|
+
}, { allowNil: true });
|
|
6195
|
+
this.editFaceModel = resolvedFacesModel.pluck('edit');
|
|
6196
|
+
this.saveFace = resolvedFacesModel.pluck('save');
|
|
6197
|
+
this.cancelFace = resolvedFacesModel.pluck('cancel');
|
|
6198
|
+
const self = this;
|
|
6199
|
+
this.editCommand = Command.create(() => __awaiter(this, void 0, void 0, function* () {
|
|
6200
|
+
this.editorModel.editing.value = true;
|
|
6201
|
+
try {
|
|
6202
|
+
yield this.interactionContext.startActivity(StringInputActivity, this.createInputActivityData());
|
|
6203
|
+
}
|
|
6204
|
+
catch (e) {
|
|
6205
|
+
// don't care if they cancelled, just hiding the console errors
|
|
6206
|
+
}
|
|
6207
|
+
finally {
|
|
6208
|
+
this.editorModel.editing.value = false;
|
|
6209
|
+
}
|
|
6210
|
+
})).enableWhile(this.editingEnabled);
|
|
6211
|
+
this.onDispose(() => this.cancelEdit());
|
|
6212
|
+
}
|
|
6213
|
+
ngOnInit() {
|
|
6214
|
+
// our editor model is a one time binding without delegates so we can only
|
|
6215
|
+
// use it once we've been initialised
|
|
6216
|
+
const { chain, when, valueOf } = Dsl.disposeWith(this);
|
|
6217
|
+
if (!this.editorModel) {
|
|
6218
|
+
lang$1.illegalState('editorModel is required');
|
|
6219
|
+
}
|
|
6220
|
+
this.editingEnabled.setDelegate(this.editorModel.editingEnabled);
|
|
6221
|
+
when(this.editorModel.editing).becomesTruthy(() => {
|
|
6222
|
+
this.editCommand.execute();
|
|
6223
|
+
}, { asLongAs: this.editCommand.enabled });
|
|
6224
|
+
when(this.editorModel.editing).becomesFalsey(() => this.cancelEdit());
|
|
6225
|
+
this.empty = valueOf.any(chain.stringValue(this.editorModel.valueModel).isBlank()
|
|
6226
|
+
// deviceDescription.isNil()
|
|
6227
|
+
).areTruthy();
|
|
6228
|
+
this.displayValue = chain(this.editorModel.valueModel).map(v => {
|
|
6229
|
+
return _.isEmpty(v) ? this.placeHolderModel.value : v;
|
|
6230
|
+
}, { dependsOn: this.placeHolderModel, allowNil: true });
|
|
6231
|
+
}
|
|
6232
|
+
createInputActivityData() {
|
|
6233
|
+
const self = this;
|
|
6234
|
+
return {
|
|
6235
|
+
initialValue: self.editorModel.valueModel.value,
|
|
6236
|
+
confirmFace: self.saveFace.value,
|
|
6237
|
+
cancelFace: self.cancelFace.value,
|
|
6238
|
+
placeholder: self.placeHolderModel.value,
|
|
6239
|
+
label: self.label,
|
|
6240
|
+
layout: InputActivity.Layout.INLINE,
|
|
6241
|
+
validators: self.editorModel.validators.value,
|
|
6242
|
+
save(value, inputContext) {
|
|
6243
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6244
|
+
yield self.editorModel.saveCallback(value, inputContext);
|
|
6245
|
+
});
|
|
6246
|
+
}
|
|
6247
|
+
};
|
|
6248
|
+
}
|
|
6249
|
+
cancelEdit() {
|
|
6250
|
+
if (this.isEditing()) {
|
|
6251
|
+
this.interactionContext.cancelActiveActivity();
|
|
6252
|
+
}
|
|
6253
|
+
}
|
|
6254
|
+
startEdit() {
|
|
6255
|
+
if (!this.isEditing() && this.editCommand.enabled.value) {
|
|
6256
|
+
this.editCommand.execute();
|
|
6257
|
+
}
|
|
6258
|
+
}
|
|
6259
|
+
isEditing() {
|
|
6260
|
+
return this.interactionContext.isActive();
|
|
6261
|
+
}
|
|
6262
|
+
isEmpty() {
|
|
6263
|
+
return this.empty.value;
|
|
6264
|
+
}
|
|
6265
|
+
}
|
|
6266
|
+
InlineStringEditorComponent.decorators = [
|
|
6267
|
+
{ type: Component, args: [{
|
|
6268
|
+
selector: 'aup-inline-string-editor',
|
|
6269
|
+
template: "<div class=\"container\" *ngIf=\"!editorModel.isEditing()\">\n <mat-form-field appearance=\"standard\" floatLabel=\"always\" (click)=\"startEdit()\"\n [class.editable]=\"editingEnabled.value\" [class.empty]=\"isEmpty()\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input matInput\n placeholder=\"{{placeHolder}}\"\n [ngModel]=\"editorModel.valueModel.value\"\n [disabled]=\"true\"\n >\n <!-- <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>-->\n <!-- <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>-->\n <!-- <aup-icon *ngIf=\"iconPrefix\" matPrefix [icon]=\"iconPrefix\"></aup-icon>-->\n </mat-form-field>\n <aup-command *ngIf=\"editCommand.enabled.value\" [command]=\"editCommand\" [faceModel]=\"editFaceModel\"></aup-command>\n</div>\n<aup-in-place-interaction-context [animateFirstActivity]=\"false\"></aup-in-place-interaction-context>\n"
|
|
6270
|
+
},] }
|
|
6271
|
+
];
|
|
6272
|
+
InlineStringEditorComponent.ctorParameters = () => [
|
|
6273
|
+
{ type: InteractionService }
|
|
6274
|
+
];
|
|
6275
|
+
InlineStringEditorComponent.propDecorators = {
|
|
6276
|
+
editorModel: [{ type: Input }],
|
|
6277
|
+
facesModel: [{ type: Input }],
|
|
6278
|
+
faces: [{ type: Input }],
|
|
6279
|
+
interactionContext: [{ type: ViewChild, args: [InPlaceInteractionContextComponent,] }],
|
|
6280
|
+
label: [{ type: Input }],
|
|
6281
|
+
placeHolder: [{ type: Input }],
|
|
6282
|
+
placeHolderModel: [{ type: Input }]
|
|
5505
6283
|
};
|
|
6284
|
+
__decorate([
|
|
6285
|
+
TrackExternal(),
|
|
6286
|
+
__metadata("design:type", InlineEditorModel)
|
|
6287
|
+
], InlineStringEditorComponent.prototype, "editorModel", void 0);
|
|
6288
|
+
__decorate([
|
|
6289
|
+
TrackExternal(),
|
|
6290
|
+
__metadata("design:type", ValueModel)
|
|
6291
|
+
], InlineStringEditorComponent.prototype, "facesModel", void 0);
|
|
6292
|
+
__decorate([
|
|
6293
|
+
StoreInValueModel('facesModel'),
|
|
6294
|
+
__metadata("design:type", Object)
|
|
6295
|
+
], InlineStringEditorComponent.prototype, "faces", void 0);
|
|
6296
|
+
__decorate([
|
|
6297
|
+
StoreInValueModel('placeHolderModel'),
|
|
6298
|
+
__metadata("design:type", String)
|
|
6299
|
+
], InlineStringEditorComponent.prototype, "placeHolder", void 0);
|
|
6300
|
+
__decorate([
|
|
6301
|
+
TrackExternal(),
|
|
6302
|
+
__metadata("design:type", ValueModel)
|
|
6303
|
+
], InlineStringEditorComponent.prototype, "placeHolderModel", void 0);
|
|
6304
|
+
(function (InlineStringEditorComponent) {
|
|
6305
|
+
InlineStringEditorComponent.DEFAULT_FACES = {
|
|
6306
|
+
edit: {
|
|
6307
|
+
icon: () => 'mat:edit'
|
|
6308
|
+
},
|
|
6309
|
+
save: {
|
|
6310
|
+
icon: () => 'mat:check'
|
|
6311
|
+
},
|
|
6312
|
+
cancel: {
|
|
6313
|
+
icon: () => 'mat:clear'
|
|
6314
|
+
}
|
|
6315
|
+
};
|
|
6316
|
+
})(InlineStringEditorComponent || (InlineStringEditorComponent = {}));
|
|
5506
6317
|
|
|
5507
6318
|
class InteractionModule {
|
|
5508
6319
|
}
|
|
@@ -5519,12 +6330,17 @@ InteractionModule.decorators = [
|
|
|
5519
6330
|
DirectivesModule,
|
|
5520
6331
|
FlexModule,
|
|
5521
6332
|
GridModule,
|
|
5522
|
-
ComponentsModule
|
|
6333
|
+
ComponentsModule,
|
|
6334
|
+
FormsModule,
|
|
6335
|
+
MatInputModule,
|
|
6336
|
+
MatFormFieldModule,
|
|
6337
|
+
A11yModule
|
|
5523
6338
|
],
|
|
5524
6339
|
declarations: [
|
|
5525
6340
|
ActivityContainerComponent,
|
|
5526
6341
|
ConfirmationDialogComponent,
|
|
5527
6342
|
ConfirmThenDialogComponent,
|
|
6343
|
+
ConfirmThenExecuteDialogComponent,
|
|
5528
6344
|
AlertDialogComponent,
|
|
5529
6345
|
ActivityOutletComponent,
|
|
5530
6346
|
InPlaceInteractionContextComponent,
|
|
@@ -5533,7 +6349,7 @@ InteractionModule.decorators = [
|
|
|
5533
6349
|
PopupInteractionContextComponent,
|
|
5534
6350
|
StringInputActivity,
|
|
5535
6351
|
SelectInputActivity,
|
|
5536
|
-
|
|
6352
|
+
InputActivity,
|
|
5537
6353
|
InteractionContextTriggerFor,
|
|
5538
6354
|
Activity,
|
|
5539
6355
|
ActivityTitleComponent,
|
|
@@ -5542,7 +6358,11 @@ InteractionModule.decorators = [
|
|
|
5542
6358
|
AbstractActivityTriggerComponent,
|
|
5543
6359
|
PopupActivityTriggerComponent,
|
|
5544
6360
|
InlineActivityTriggerComponent,
|
|
5545
|
-
ModalActivityTriggerComponent
|
|
6361
|
+
ModalActivityTriggerComponent,
|
|
6362
|
+
AddCardActivityComponent,
|
|
6363
|
+
InlineStringEditorComponent,
|
|
6364
|
+
AbstractDialogComponent,
|
|
6365
|
+
AbstractConfirmDialogComponent,
|
|
5546
6366
|
],
|
|
5547
6367
|
exports: [
|
|
5548
6368
|
ActivityContainerComponent,
|
|
@@ -5558,13 +6378,15 @@ InteractionModule.decorators = [
|
|
|
5558
6378
|
ActivityBodyComponent,
|
|
5559
6379
|
PopupActivityTriggerComponent,
|
|
5560
6380
|
InlineActivityTriggerComponent,
|
|
5561
|
-
ModalActivityTriggerComponent
|
|
6381
|
+
ModalActivityTriggerComponent,
|
|
6382
|
+
AddCardActivityComponent,
|
|
6383
|
+
InlineStringEditorComponent,
|
|
5562
6384
|
],
|
|
5563
6385
|
entryComponents: [
|
|
5564
|
-
|
|
5565
|
-
|
|
5566
|
-
|
|
5567
|
-
|
|
6386
|
+
// ActivityContainerComponent,
|
|
6387
|
+
// ConfirmationDialogComponent,
|
|
6388
|
+
// ConfirmThenDialogComponent,
|
|
6389
|
+
// AlertDialogComponent
|
|
5568
6390
|
],
|
|
5569
6391
|
providers: [
|
|
5570
6392
|
InteractionService
|
|
@@ -5575,7 +6397,7 @@ InteractionModule.decorators = [
|
|
|
5575
6397
|
},] }
|
|
5576
6398
|
];
|
|
5577
6399
|
|
|
5578
|
-
const PARAMETER_DEFINITION_KEY = Symbol(
|
|
6400
|
+
const PARAMETER_DEFINITION_KEY = Symbol('parameterDefinition');
|
|
5579
6401
|
class ParameterDefinition {
|
|
5580
6402
|
constructor(propertyName, options, urlFormat) {
|
|
5581
6403
|
this.propertyName = propertyName;
|
|
@@ -5602,20 +6424,43 @@ class ParameterDefinition {
|
|
|
5602
6424
|
// @Trace()
|
|
5603
6425
|
sanitise(value, visit, placeHistory, injector, isPopState) {
|
|
5604
6426
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5605
|
-
|
|
5606
|
-
|
|
5607
|
-
|
|
5608
|
-
const lastKnownVisit = placeHistory.getMostRecentVisitFor(visit.placeDefinition);
|
|
5609
|
-
if (this.remember && lastKnownVisit) {
|
|
5610
|
-
value = lastKnownVisit.getParameterValue(this);
|
|
5611
|
-
}
|
|
5612
|
-
return this.isEmptyValue(value) ? this.defaultValue : value;
|
|
5613
|
-
}
|
|
5614
|
-
}
|
|
5615
|
-
// todo: add custom sanitiser
|
|
6427
|
+
// console.log(`sanitise(${this.propertyName})`)
|
|
6428
|
+
value = yield this.sanitiseMissing(visit, placeHistory, value);
|
|
6429
|
+
value = yield this.runCustomSanitiser(value, visit, placeHistory, injector, isPopState);
|
|
5616
6430
|
return value;
|
|
5617
6431
|
});
|
|
5618
6432
|
}
|
|
6433
|
+
runCustomSanitiser(value, visit, placeHistory, injector, isPopState) {
|
|
6434
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6435
|
+
const customSanitiser = this.prepareCustomSanitiser(injector);
|
|
6436
|
+
return customSanitiser ? customSanitiser.sanitise(value, visit, injector) : value;
|
|
6437
|
+
});
|
|
6438
|
+
}
|
|
6439
|
+
sanitiseMissing(visit, placeHistory, value) {
|
|
6440
|
+
if (this.isMissingFrom(visit)) {
|
|
6441
|
+
const returningFromSomewhereElse = !placeHistory.lastVisitIncluded(visit.placeDefinition);
|
|
6442
|
+
if (returningFromSomewhereElse) {
|
|
6443
|
+
const lastKnownVisit = placeHistory.getMostRecentVisitFor(visit.placeDefinition);
|
|
6444
|
+
if (this.remember && lastKnownVisit) {
|
|
6445
|
+
value = lastKnownVisit.getParameterValue(this);
|
|
6446
|
+
}
|
|
6447
|
+
value = this.isEmptyValue(value) ? this.defaultValue : value;
|
|
6448
|
+
}
|
|
6449
|
+
}
|
|
6450
|
+
return value;
|
|
6451
|
+
}
|
|
6452
|
+
prepareCustomSanitiser(injector) {
|
|
6453
|
+
const customSanitiser = this.options.getOptional('sanitiser', null);
|
|
6454
|
+
if (___default.isFunction(customSanitiser)) {
|
|
6455
|
+
return injector.get(customSanitiser);
|
|
6456
|
+
}
|
|
6457
|
+
if (___default.isObject(customSanitiser)) {
|
|
6458
|
+
return ___default.isFunction(customSanitiser['sanitise']) ?
|
|
6459
|
+
customSanitiser :
|
|
6460
|
+
lang$1.illegalState(`expected @VisitParameter({sanitiser: ...}) for ${this.propertyName} to be a constructor or instance of ParameterSanitiser, got: ` + customSanitiser);
|
|
6461
|
+
}
|
|
6462
|
+
return undefined;
|
|
6463
|
+
}
|
|
5619
6464
|
isMissingFrom(visit) {
|
|
5620
6465
|
return !visit.hasParameter(this);
|
|
5621
6466
|
}
|
|
@@ -5669,7 +6514,7 @@ class ParameterDefinition {
|
|
|
5669
6514
|
function get(model) {
|
|
5670
6515
|
const parameterDefinition = model[PARAMETER_DEFINITION_KEY];
|
|
5671
6516
|
if (!parameterDefinition) {
|
|
5672
|
-
lang$1.illegalArgument(
|
|
6517
|
+
lang$1.illegalArgument('model hasn\'t been annotated with @VisitParameter, @VisitParameterList or @RouteId');
|
|
5673
6518
|
}
|
|
5674
6519
|
return parameterDefinition;
|
|
5675
6520
|
}
|
|
@@ -5839,16 +6684,27 @@ class PlaceComponent extends DisposableComponent {
|
|
|
5839
6684
|
when(this._active).becomesTruthy(() => this._notifyPlaceReady());
|
|
5840
6685
|
this.childPlaces = this.placeDefinition.children.map(d => d.component);
|
|
5841
6686
|
}
|
|
5842
|
-
// @Trace()
|
|
5843
6687
|
initialiseVisit(visit, notifyVisitChanged) {
|
|
5844
6688
|
assert.isNil(this.visitModel.value);
|
|
5845
6689
|
const { when } = Dsl.disposeWith(this);
|
|
5846
6690
|
this.visitModel.value = visit;
|
|
5847
6691
|
DebugContext.getOrCreate(this.visitModel).tag(`${this.placeDefinition.component.name}.visitModel`);
|
|
5848
|
-
|
|
6692
|
+
// we track if the any of the bindings updated the route. If so we remember it and update the
|
|
6693
|
+
// route in one go at the end.
|
|
6694
|
+
this.placeDefinition
|
|
6695
|
+
.getVisitParameterDefs()
|
|
6696
|
+
.forEach(parameterDef => this.installAndInitialiseBinding(visit, parameterDef));
|
|
5849
6697
|
when(this.visitModel).changes((current, previous) => {
|
|
5850
6698
|
notifyVisitChanged(current, previous);
|
|
5851
6699
|
}, { unless: this._inVisitUpdate });
|
|
6700
|
+
// TODO: this needs to do a replace url option so that the new url isn't put in the history.... for
|
|
6701
|
+
// now we're not doing it as it's a fair bit of effort and will only affect people if they're
|
|
6702
|
+
// cutting and pasting urls to each other.
|
|
6703
|
+
// // the binding process can update the visit (e.g. if a selection model has already selected during
|
|
6704
|
+
// // component construction) and there was no value specified in the route
|
|
6705
|
+
// if (visit.hasRoutingChangedFrom(this.visitModel.value)) {
|
|
6706
|
+
// notifyVisitChanged(this.visitModel.value, visit)
|
|
6707
|
+
// }
|
|
5852
6708
|
}
|
|
5853
6709
|
updateVisit(visit) {
|
|
5854
6710
|
assert.isTruthy(this.isInitialised());
|
|
@@ -5861,7 +6717,12 @@ class PlaceComponent extends DisposableComponent {
|
|
|
5861
6717
|
return !!this.visitModel.value;
|
|
5862
6718
|
}
|
|
5863
6719
|
// @Trace()
|
|
5864
|
-
|
|
6720
|
+
/**
|
|
6721
|
+
* Initialised the component bindings. If any binding has an initial model value (e.g. a selection model
|
|
6722
|
+
* initialised during the constructor) and the route has nothing, then the visit will be udpated and this
|
|
6723
|
+
* method will return ture to nofiy the the visit has changed.
|
|
6724
|
+
*/
|
|
6725
|
+
installAndInitialiseBinding(initialVisit, parameterDef) {
|
|
5865
6726
|
const model = this[parameterDef.propertyName];
|
|
5866
6727
|
DebugContext.tag(model, `${this.placeDefinition.component.name}.${parameterDef.propertyName}`);
|
|
5867
6728
|
const binding = this.registerDisposable(new Binding(this.visitModel, model, {
|
|
@@ -5875,7 +6736,17 @@ class PlaceComponent extends DisposableComponent {
|
|
|
5875
6736
|
return currentVisit.replace(parameterDef, value);
|
|
5876
6737
|
}
|
|
5877
6738
|
}));
|
|
5878
|
-
binding.
|
|
6739
|
+
// Now we need to initialise the binding direction. If we have a value in the Url then we should always push
|
|
6740
|
+
// that to the view. If we don't and the view already has a value (e.g. a selection model has already initialised in the
|
|
6741
|
+
// component constructor) then we should push that to the route.
|
|
6742
|
+
const isInVisit = !_.isNil(initialVisit.getParameterValue(parameterDef));
|
|
6743
|
+
const isInModel = !_.isNil(model.value);
|
|
6744
|
+
if (!isInVisit && isInModel) {
|
|
6745
|
+
binding.writeLeft(); // push it to the route
|
|
6746
|
+
}
|
|
6747
|
+
else {
|
|
6748
|
+
binding.writeRight(); // push it to the model
|
|
6749
|
+
}
|
|
5879
6750
|
}
|
|
5880
6751
|
get placeDefinition() {
|
|
5881
6752
|
const definition = PlaceComponent.getDefinition(this.constructor);
|
|
@@ -6918,7 +7789,7 @@ class ConsolidatedParameterMap {
|
|
|
6918
7789
|
return !!this.paramMaps.find(m => m.has(name));
|
|
6919
7790
|
}
|
|
6920
7791
|
get keys() {
|
|
6921
|
-
return this.paramMaps.reduce((result, params) => result.concat(params.keys), []);
|
|
7792
|
+
return _.uniq(this.paramMaps.reduce((result, params) => result.concat(params.keys), []));
|
|
6922
7793
|
}
|
|
6923
7794
|
}
|
|
6924
7795
|
__decorate([
|
|
@@ -6962,10 +7833,10 @@ class Visit {
|
|
|
6962
7833
|
* Returns the value of the place parameter with the specified name. The parameter
|
|
6963
7834
|
* name is taken from the `as` option, e.g. {as: 'aCustomName'} otherwise it is the
|
|
6964
7835
|
* same as the the ValueModel property name.
|
|
6965
|
-
* @param
|
|
7836
|
+
* @param parameter the visit parameter definition
|
|
6966
7837
|
*/
|
|
6967
|
-
getParameterValue(
|
|
6968
|
-
return this.visitParameters[
|
|
7838
|
+
getParameterValue(parameter) {
|
|
7839
|
+
return _.isString(parameter) ? this.visitParameters[parameter] : this.visitParameters[parameter.name];
|
|
6969
7840
|
}
|
|
6970
7841
|
// @Trace()
|
|
6971
7842
|
hasParameter(parameterDef) {
|
|
@@ -6995,9 +7866,13 @@ class Visit {
|
|
|
6995
7866
|
});
|
|
6996
7867
|
return new Visit(this.placeDefinition, params);
|
|
6997
7868
|
}
|
|
7869
|
+
// @Trace()
|
|
6998
7870
|
hasRoutingChangedFrom(other) {
|
|
6999
7871
|
const samePlace = other.placeDefinition === this.placeDefinition;
|
|
7000
|
-
const
|
|
7872
|
+
const currentParams = this.placeDefinition.getFormattedRouteParameters(this, true);
|
|
7873
|
+
const otherParams = this.placeDefinition.getFormattedRouteParameters(other, true);
|
|
7874
|
+
// console.log({currentParams, otherParams});
|
|
7875
|
+
const sameRouteParameters = _.isEqual(currentParams, otherParams);
|
|
7001
7876
|
return !samePlace || !sameRouteParameters;
|
|
7002
7877
|
}
|
|
7003
7878
|
hasChangedFrom(other) {
|
|
@@ -7176,6 +8051,9 @@ UrlService.ctorParameters = () => [
|
|
|
7176
8051
|
{ type: UrlSerializer }
|
|
7177
8052
|
];
|
|
7178
8053
|
|
|
8054
|
+
function asArray(item) {
|
|
8055
|
+
return Array.isArray(item) ? item : [item];
|
|
8056
|
+
}
|
|
7179
8057
|
class PlaceRouter extends GarbageCollector {
|
|
7180
8058
|
constructor(angularRouter, angularLocation, interactionService, urlService, placeHistory) {
|
|
7181
8059
|
super();
|
|
@@ -7191,7 +8069,7 @@ class PlaceRouter extends GarbageCollector {
|
|
|
7191
8069
|
* An observable model containing the authoriser function. This allows places to react to changes
|
|
7192
8070
|
* in permissions when any underlying auth logic changes, e.g. a role being removed from a user.
|
|
7193
8071
|
*/
|
|
7194
|
-
this._accessGuard = new DelegatingValueModel().withDefault(new PlaceAccessGuard.NoAuth());
|
|
8072
|
+
this._accessGuard = this.registerDisposable(new DelegatingValueModel().withDefault(new PlaceAccessGuard.NoAuth()));
|
|
7195
8073
|
if (window['Cypress']) {
|
|
7196
8074
|
window['aup.PlaceRouter'] = this;
|
|
7197
8075
|
}
|
|
@@ -7339,11 +8217,10 @@ class PlaceRouter extends GarbageCollector {
|
|
|
7339
8217
|
this.currentSession.onRouterEnd(event);
|
|
7340
8218
|
}
|
|
7341
8219
|
navigate(visit, options) {
|
|
8220
|
+
const commands = asArray(visit).reduce((result, v) => {
|
|
8221
|
+
return [...result, v.placeDefinition.path, ...this.createRouteParameters(v)];
|
|
8222
|
+
}, []);
|
|
7342
8223
|
return this.doNavigation(visit, (router) => __awaiter(this, void 0, void 0, function* () {
|
|
7343
|
-
const commands = [
|
|
7344
|
-
visit.placeDefinition.path,
|
|
7345
|
-
...this.createRouteParameters(visit)
|
|
7346
|
-
];
|
|
7347
8224
|
yield this.angularRouter.navigate(commands, {
|
|
7348
8225
|
relativeTo: options ? options.relativeTo : null
|
|
7349
8226
|
});
|
|
@@ -7356,7 +8233,7 @@ class PlaceRouter extends GarbageCollector {
|
|
|
7356
8233
|
lang.illegalState('Navigation already in progress');
|
|
7357
8234
|
}
|
|
7358
8235
|
const navigation = this.createNavigationSession(this.urlService.getCurrentRouterUrl());
|
|
7359
|
-
navigation.storeVisit(
|
|
8236
|
+
asArray(visit).forEach(v => navigation.storeVisit(v));
|
|
7360
8237
|
this.transitionTo(navigation);
|
|
7361
8238
|
try {
|
|
7362
8239
|
yield runNavigationCommands(this.angularRouter);
|
|
@@ -7437,6 +8314,7 @@ class PlaceRouter extends GarbageCollector {
|
|
|
7437
8314
|
* to be able to capture the back button on the first page. If we don't then the back click will exit
|
|
7438
8315
|
* the app directly and we don't get to ask.
|
|
7439
8316
|
*/
|
|
8317
|
+
// @Trace()
|
|
7440
8318
|
syncInteractionContextIdsWithRouter() {
|
|
7441
8319
|
if (this.navigationSession) {
|
|
7442
8320
|
// console.log(`Navigation active -> ${this.navigationSession.toString()}, sync delayed until finished.`);
|
|
@@ -7478,12 +8356,6 @@ PlaceRouter.ctorParameters = () => [
|
|
|
7478
8356
|
{ type: UrlService },
|
|
7479
8357
|
{ type: PlaceHistory }
|
|
7480
8358
|
];
|
|
7481
|
-
__decorate([
|
|
7482
|
-
Trace(),
|
|
7483
|
-
__metadata("design:type", Function),
|
|
7484
|
-
__metadata("design:paramtypes", []),
|
|
7485
|
-
__metadata("design:returntype", Promise)
|
|
7486
|
-
], PlaceRouter.prototype, "syncInteractionContextIdsWithRouter", null);
|
|
7487
8359
|
(function (PlaceRouter) {
|
|
7488
8360
|
class State {
|
|
7489
8361
|
constructor(activeVisits) {
|
|
@@ -7509,7 +8381,7 @@ NotAuthorisedNoticeComponent.decorators = [
|
|
|
7509
8381
|
{ type: Component, args: [{
|
|
7510
8382
|
selector: 'aup-not-authorised-notice',
|
|
7511
8383
|
template: "<p>You are not authorised to access this page</p>\n",
|
|
7512
|
-
styles: [":host{display:flex;flex-direction:column;align-items:center;justify-content:center}"]
|
|
8384
|
+
styles: [":host{display:flex;flex-direction:column;align-items:center;justify-content:center}\n"]
|
|
7513
8385
|
},] }
|
|
7514
8386
|
];
|
|
7515
8387
|
NotAuthorisedNoticeComponent.ctorParameters = () => [];
|
|
@@ -7707,15 +8579,27 @@ class PlaceOutletComponent extends DisposableComponent {
|
|
|
7707
8579
|
const { when, chain, valueOf } = Dsl.disposeWith(activePlace);
|
|
7708
8580
|
when(this.routerVisitModel)
|
|
7709
8581
|
.changes(visit => {
|
|
7710
|
-
|
|
8582
|
+
this.pushVisitChangeToComponent(activePlace, visit);
|
|
7711
8583
|
}, {
|
|
7712
8584
|
unless: valueOf.any(this._isPushingVisitToRoute, this.routerVisitModel.isNil()).areTruthy()
|
|
7713
8585
|
});
|
|
7714
8586
|
}
|
|
8587
|
+
pushVisitChangeToComponent(activePlace, visit) {
|
|
8588
|
+
activePlace.updateVisit(visit);
|
|
8589
|
+
}
|
|
7715
8590
|
pushVisitChangeToRoute(previous, current) {
|
|
7716
|
-
this
|
|
7717
|
-
|
|
7718
|
-
|
|
8591
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
8592
|
+
try {
|
|
8593
|
+
this._isPushingVisitToRoute.value = true;
|
|
8594
|
+
yield this.placeRouter.pushVisitChangesToRoute(previous, current);
|
|
8595
|
+
}
|
|
8596
|
+
finally {
|
|
8597
|
+
this._isPushingVisitToRoute.value = false;
|
|
8598
|
+
}
|
|
8599
|
+
// sanitisers may have adjusted other values in the visit to we check and write it back.
|
|
8600
|
+
if (current.hasRoutingChangedFrom(this.routerVisitModel.value)) {
|
|
8601
|
+
this.pushVisitChangeToComponent(this.activePlaceModel.value, this.routerVisitModel.value);
|
|
8602
|
+
}
|
|
7719
8603
|
});
|
|
7720
8604
|
}
|
|
7721
8605
|
// @Trace()
|
|
@@ -7735,7 +8619,7 @@ PlaceOutletComponent.decorators = [
|
|
|
7735
8619
|
selector: 'aup-place-outlet',
|
|
7736
8620
|
template: "<ng-container *ngIf=\"animationEnabled.value\">\n <div class=\"router-outlet-container\"\n cdkScrollable\n [@routeAnimations]=\"{value: getAnimationOrder(), params:{duration: animationDuration}}\"\n (@routeAnimations.start)=\"animationStarted()\"\n (@routeAnimations.done)=\"animationDone()\"\n >\n <router-outlet #routerOutlet=\"outlet\"\n (activate)=\"onOutletActivated(routerOutlet, $event)\"\n (deactivate)=\"onOutletDeactivated()\">\n </router-outlet>\n </div>\n</ng-container>\n\n<ng-container *ngIf=\"!animationEnabled.value\">\n <div class=\"router-outlet-container\"\n cdkScrollable>\n <router-outlet #routerOutlet=\"outlet\"\n (activate)=\"onOutletActivated(routerOutlet, $event)\"\n (deactivate)=\"onOutletDeactivated()\">\n </router-outlet>\n </div>\n</ng-container>\n\n<div class=\"not-authorised-component-container\" *ngIf=\"!authorised.value\">\n <ng-template [cdkPortalOutlet]=\"notAuthorisedNoticePortal\"></ng-template>\n</div>\n",
|
|
7737
8621
|
animations: [LEFT_RIGHT_PLACE_ANIMATION],
|
|
7738
|
-
styles: [":host{display:flex;flex-direction:column;min-height:0}:host:not(.authorised) .router-outlet-container{display:none}.router-outlet-container{flex:1;display:block;position:relative;min-height:0;overflow-x:hidden;overflow-y:auto}router-outlet{display:none}.not-authorised-component-container{flex:1;display:grid;grid-template-columns:1fr;grid-template-rows:1fr}"]
|
|
8622
|
+
styles: [":host{display:flex;flex-direction:column;min-height:0}:host:not(.authorised) .router-outlet-container{display:none}.router-outlet-container{flex:1;display:block;position:relative;min-height:0;overflow-x:hidden;overflow-y:auto}router-outlet{display:none}.not-authorised-component-container{flex:1;display:grid;grid-template-columns:1fr;grid-template-rows:1fr}\n"]
|
|
7739
8623
|
},] }
|
|
7740
8624
|
];
|
|
7741
8625
|
PlaceOutletComponent.ctorParameters = () => [
|
|
@@ -7776,7 +8660,7 @@ class AbstractPlaceNavigationComponent extends DisposableComponent {
|
|
|
7776
8660
|
constructor(placeRouter) {
|
|
7777
8661
|
super();
|
|
7778
8662
|
this.placeRouter = placeRouter;
|
|
7779
|
-
this._activePlaceComponent = new DelegatingValueModel();
|
|
8663
|
+
this._activePlaceComponent = this.registerDisposable(new DelegatingValueModel());
|
|
7780
8664
|
this.trackByPlaceDef = (data) => data.place;
|
|
7781
8665
|
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
7782
8666
|
this.placeDefinitions = chain(this.placesModel)
|
|
@@ -7865,7 +8749,7 @@ ListPlaceNavComponent.decorators = [
|
|
|
7865
8749
|
{ type: Component, args: [{
|
|
7866
8750
|
selector: 'aup-list-place-nav',
|
|
7867
8751
|
template: "<mat-nav-list fxFlex>\n <a mat-list-item *ngFor=\"let item of menuItems.value; trackBy: trackByPlaceDef\"\n [pectinCommand]=\"commandFactory.create(item.place)\"\n [class.active]=\"item.active\"\n [matTooltip]=\"getNavigationFace(item.place).tooltip()\">\n <aup-command-face [faces]=\"[getNavigationFace(item.place)]\"></aup-command-face>\n </a>\n</mat-nav-list>\n",
|
|
7868
|
-
styles: [":host{display:flex;flex-direction:column;--selected-border-color
|
|
8752
|
+
styles: [":host{display:flex;flex-direction:column;--selected-border-color: #838383;--selected-color: inherit;--selected-background: #f1f1f1}mat-nav-list{padding-top:0}a{border-right:2px solid transparent}a.active{border-right:2px solid var(--selected-border-color);background:var(--selected-background);color:var(--selected-color)}\n"]
|
|
7869
8753
|
},] }
|
|
7870
8754
|
];
|
|
7871
8755
|
ListPlaceNavComponent.ctorParameters = () => [
|
|
@@ -7933,7 +8817,7 @@ SidePlaceNavigationComponent.decorators = [
|
|
|
7933
8817
|
{ type: Component, args: [{
|
|
7934
8818
|
selector: 'aup-side-place-navigation',
|
|
7935
8819
|
template: "<mat-nav-list>\n <a mat-list-item (click)=\"toggleMenu()\" class=\"home\">\n <aup-icon class=\"collapsed-only\" icon=\"mat:menu\"></aup-icon>\n <aup-icon class=\"expanded-only\" icon=\"mat:arrow_back\"></aup-icon>\n <span class=\"expanded-only\">Menu</span>\n </a>\n <a mat-list-item *ngFor=\"let item of menuItems.value; trackBy: trackByPlaceDef\"\n [pectinCommand]=\"commandFactory.create(item.place)\"\n [class.active]=\"item.active\"\n [matTooltip]=\"getNavigationFace(item.place).tooltip()\">\n <aup-icon *ngIf=\"getNavigationFace(item.place).icon()\" [icon]=\"getNavigationFace(item.place).icon()\"></aup-icon>\n <span class=\"expanded-only\">{{getNavigationFace(item.place).text()}}</span>\n </a>\n <span [style.flex]=\"1\"></span>\n <ng-container *ngIf=\"navEndTemplate\" [ngTemplateOutlet]=\"navEndTemplate\"></ng-container>\n</mat-nav-list>\n",
|
|
7936
|
-
styles: [":host{display:flex;flex-direction:column;--resolved-nav-item-width:var(--nav-width,56px);--resolved-nav-item-height:var(--nav-item-height,var(--resolved-nav-item-width));--resolved-expanded-width:var(--nav-expanded-width,235px);--resolved-color:var(--nav-color,
|
|
8820
|
+
styles: [":host{display:flex;flex-direction:column;--resolved-nav-item-width: var(--nav-width, 56px);--resolved-nav-item-height: var(--nav-item-height, var(--resolved-nav-item-width));--resolved-expanded-width: var(--nav-expanded-width, 235px);--resolved-color: var(--nav-color, rgba(255, 255, 255, .9));--resolved-background-color: var(--nav-background-color, #555);width:var(--resolved-nav-item-width);transition:width 125ms linear;background-color:var(--resolved-background-color);color:var(--resolved-color)}:host.expanded{width:var(--resolved-expanded-width);max-width:var(--resolved-expanded-width)}:host-context(.expanded) .expanded-only{max-width:100%}:host-context(.expanded) .collapsed-only{max-width:0}:host-context(.expanded) .mat-list-item aup-icon:not(.collapsed-only){margin-right:12px}:host-context(.expanded) .mat-list-item span{text-wrap:none;white-space:nowrap}.expanded-only{max-width:0;overflow:hidden}.collapsed-only{max-width:100%;overflow:hidden}mat-nav-list{flex:1;display:flex;flex-direction:column}.mat-list-item{width:var(--resolved-nav-item-width);height:var(--resolved-nav-item-height);color:inherit}.mat-list-item.active{background-color:#444}.mat-list-item.home{text-align:left}mat-icon{color:inherit}mat-icon.flip-horizontal{transform:scaleX(-1)}\n"]
|
|
7937
8821
|
},] }
|
|
7938
8822
|
];
|
|
7939
8823
|
SidePlaceNavigationComponent.ctorParameters = () => [
|
|
@@ -7953,7 +8837,7 @@ TabbedPlaceNavigationComponent.decorators = [
|
|
|
7953
8837
|
{ type: Component, args: [{
|
|
7954
8838
|
selector: 'aup-tabbed-place-navigation',
|
|
7955
8839
|
template: "<nav mat-tab-nav-bar>\n <ng-content select=\"[nav-start]\"></ng-content>\n <a mat-tab-link *ngFor=\"let item of menuItems.value; trackBy: trackByPlaceDef\"\n [pectinCommand]=\"commandFactory.create(item.place)\"\n [active]=\"item.active\"\n [matTooltip]=\"getNavigationFace(item.place).tooltip()\">\n <aup-command-face [faces]=\"[getNavigationFace(item.place)]\"></aup-command-face>\n </a>\n <ng-content select=\"[nav-end]\"></ng-content>\n</nav>\n",
|
|
7956
|
-
styles: [":host{display:block}div.place-holder{border:1px solid green}"]
|
|
8840
|
+
styles: [":host{display:block}div.place-holder{border:1px solid green}\n"]
|
|
7957
8841
|
},] }
|
|
7958
8842
|
];
|
|
7959
8843
|
TabbedPlaceNavigationComponent.ctorParameters = () => [
|
|
@@ -8058,9 +8942,6 @@ const slideRightOnEnterAnimation = trigger('slideRightOnEnter', [
|
|
|
8058
8942
|
* @file Automatically generated by barrelsby.
|
|
8059
8943
|
*/
|
|
8060
8944
|
|
|
8061
|
-
// const r:Result<string, number> = null;
|
|
8062
|
-
// r.catch(e => {}).then();
|
|
8063
|
-
|
|
8064
8945
|
class DialogInteractionContext extends AbstractInteractionContext {
|
|
8065
8946
|
constructor(identifier, api, dialogService, config) {
|
|
8066
8947
|
super();
|
|
@@ -8245,10 +9126,11 @@ class PlaceGuard {
|
|
|
8245
9126
|
}
|
|
8246
9127
|
}
|
|
8247
9128
|
const result = yield this.cleanInteractionState(activatedRoute, state, () => __awaiter(this, void 0, void 0, function* () {
|
|
9129
|
+
const navigationSession = this.placeRouter.navigationSession;
|
|
8248
9130
|
// Parse our route params.
|
|
8249
9131
|
const params = new ConsolidatedParameterMap(activatedRoute.url, activatedRoute.paramMap);
|
|
9132
|
+
// console.log("RouteParams", params)
|
|
8250
9133
|
const parsedParams = placeDefinition.parseRouteParams(params);
|
|
8251
|
-
const navigationSession = this.placeRouter.navigationSession;
|
|
8252
9134
|
const initialVisit = navigationSession.getVisitFor(placeDefinition) || new Visit(placeDefinition, parsedParams);
|
|
8253
9135
|
const sanitiser = new VisitSanitiser(navigationSession, activatedRoute, this.router, this.placeHistory, this.injector);
|
|
8254
9136
|
const sanitisedVisit = yield sanitiser.sanitise(initialVisit.mergeRouteParameters(parsedParams));
|
|
@@ -8500,5 +9382,5 @@ VisibilityService.ctorParameters = () => [
|
|
|
8500
9382
|
* Generated bundle index. Do not edit.
|
|
8501
9383
|
*/
|
|
8502
9384
|
|
|
8503
|
-
export { ACTIVITY_DATA, AUP_PLACE_CONFIG, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent,
|
|
9385
|
+
export { ACTIVITY_DATA, ALERT_CONFIG, AUP_PLACE_CONFIG, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent, AbstractCardContainerComponent, AbstractConfirmDialogComponent, AbstractDialogComponent, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableComponent, AbstractTableModel, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityBodyComponent, ActivityContainerComponent, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddCardActivityComponent, AddItemInteractionContextComponent, Alert, AlertDialogComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CardStackComponent, CellEditorPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnListModel, ColumnModel, ColumnTemplateDirective, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, ConfirmThenDialogComponent, ConfirmThenExecuteDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DecoratedTreeNode, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControls, EditSession, EditorControlColumnModel, EmptyStateComponent, EventCleanUpSession, FlattenedTreeListModel, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, Formatter, HEADER_CELL_RENDERER_PORTAL, HighlightPipe, HighlightTextModelDirective, HorizontalAlignment, IconComponent, InPlaceInteractionContextComponent, InlineActivityTriggerComponent, InlineEditorModel, InlineStringEditorComponent, InputActivity, InteractionContextTriggerFor, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, LEFT_RIGHT_PLACE_ANIMATION, LabelledValueComponent, ListPlaceNavComponent, ListPropertyColumnModel, LoadingContainerComponent, MarkdownComponent, MarkdownService, ModalActivityTriggerComponent, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NotAuthorisedNoticeComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, PaginatorComponent, ParameterDefinition, PasswordInputComponent, Place, PlaceAccessGuard, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupActivityTriggerComponent, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, RouteId, ScrollContainerComponent, SectionHeaderComponent, SelectCellRendererComponent, SelectHeaderCellRendererComponent, SelectInputActivity, SelectInputComponent, SelectionColumnModel, SeparatorComponent, SidePlaceNavigationComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableCellRendererComponent, TableComponent, TableHeaderCellRendererComponent, TableModel, TableRowMenuComponent, TemplateCellRendererPortalRef, TextInputComponent, ToolBarComponent, TrackBy, TreeExpansionModel, TreeInheritanceIconComponent, TreeLabelCellRendererComponent, TreeLabelColumnModel, TreeTableComponent, TreeTableModel, UrlService, UrlSnapshot, VerticalFocusContainerComponent, VisibilityService, Visit, VisitParameter, VisitParameterList, VisitSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, markdownPillExtension, slideDownOnEnterAnimation, slideRightOnEnterAnimation, treeNodeDecorator, ɵ0, ɵ1 };
|
|
8504
9386
|
//# sourceMappingURL=coolon-angular-ui-powerups.js.map
|