@coolon/angular-ui-powerups 2.0.0-alpha.9 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +200 -0
- package/assets/commands.scss +3 -0
- package/assets/icons.scss +30 -0
- package/assets/interaction.scss +5 -0
- package/assets/styles.scss +2 -0
- package/assets/tabs.scss +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.js +1537 -277
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js +2 -2
- package/bundles/coolon-angular-ui-powerups.umd.min.js.map +1 -1
- package/coolon-angular-ui-powerups.d.ts +46 -34
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/esm2015/coolon-angular-ui-powerups.js +44 -32
- package/esm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/esm2015/coolon-angular-ui-powerups.metadata.json +1 -1
- package/esm2015/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/card-container/card-container.component.js +1 -1
- package/esm2015/lib/components/card-container/card-container.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/command/command.component.js +61 -0
- package/esm2015/lib/components/commands/command/command.component.js.map +1 -0
- package/esm2015/lib/components/commands/command/command.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/command/command.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/command-face/command-face.component.js +92 -0
- package/esm2015/lib/components/commands/command-face/command-face.component.js.map +1 -0
- package/esm2015/lib/components/commands/command-face/command-face.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/command-face/command-face.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/command-face/command-face.component.scss.ngstyle.js.map +1 -0
- package/esm2015/lib/components/commands/command-face.js +112 -0
- package/esm2015/lib/components/commands/command-face.js.map +1 -0
- package/esm2015/lib/components/commands/command-face.metadata.json +1 -0
- package/esm2015/lib/components/commands/flex.component.js +30 -0
- package/esm2015/lib/components/commands/flex.component.js.map +1 -0
- package/esm2015/lib/components/commands/flex.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/flex.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group/command-group.component.js +47 -0
- package/esm2015/lib/components/commands/group/command-group/command-group.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group/command-group.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/command-group/command-group.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js +55 -0
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js +39 -0
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group.js +100 -0
- package/esm2015/lib/components/commands/group/command-group.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-group.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/more-menu.component.js +55 -0
- package/esm2015/lib/components/commands/group/more-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/more-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/more-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu.component.js +65 -0
- package/esm2015/lib/components/commands/group/popup-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/registration.js +58 -0
- package/esm2015/lib/components/commands/group/registration.js.map +1 -0
- package/esm2015/lib/components/commands/group/registration.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.js +55 -0
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/commands/group/view-data.js +104 -0
- package/esm2015/lib/components/commands/group/view-data.js.map +1 -0
- package/esm2015/lib/components/commands/group/view-data.metadata.json +1 -0
- package/esm2015/lib/components/commands/separator.component.js +35 -0
- package/esm2015/lib/components/commands/separator.component.js.map +1 -0
- package/esm2015/lib/components/commands/separator.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/separator.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/components.module.js +38 -15
- 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/forms/abstract-input.component.js +12 -4
- package/esm2015/lib/components/forms/abstract-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/abstract-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/abstract-list-input.component.js +27 -14
- package/esm2015/lib/components/forms/abstract-list-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/abstract-list-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/abstract-value-input.component.js +23 -13
- package/esm2015/lib/components/forms/abstract-value-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/abstract-value-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/autocomplete-input/autocomplete-input.component.js +7 -1
- 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.js.map +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 -10
- 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/number-input/number-input.component.js +1 -1
- package/esm2015/lib/components/forms/number-input/number-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/number-input/number-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/password-input/password-input.component.js +1 -1
- package/esm2015/lib/components/forms/password-input/password-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/password-input/password-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 +3 -3
- package/esm2015/lib/components/forms/string-input/string-input.component.js.map +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.js.map +1 -1
- package/esm2015/lib/components/forms/text-input/text-input.component.metadata.json +1 -1
- package/esm2015/lib/components/icon/icon.component.js +17 -4
- package/esm2015/lib/components/icon/icon.component.js.map +1 -1
- package/esm2015/lib/components/icon/icon.component.metadata.json +1 -1
- package/esm2015/lib/components/index.js +16 -0
- package/esm2015/lib/components/index.js.map +1 -1
- package/esm2015/lib/components/index.metadata.json +1 -1
- package/esm2015/lib/components/table/column-model.js +44 -2
- package/esm2015/lib/components/table/column-model.js.map +1 -1
- package/esm2015/lib/components/table/column-model.metadata.json +1 -1
- package/esm2015/lib/components/table/mutable-cell-renderer.js +1 -0
- package/esm2015/lib/components/table/mutable-cell-renderer.js.map +1 -0
- package/esm2015/lib/components/table/mutable-cell-renderer.metadata.json +1 -0
- package/esm2015/lib/components/table/table-model.js +10 -7
- package/esm2015/lib/components/table/table-model.js.map +1 -1
- package/esm2015/lib/components/table/table-model.metadata.json +1 -1
- package/esm2015/lib/components/table/table-row-menu/table-row-menu.component.js +73 -0
- package/esm2015/lib/components/table/table-row-menu/table-row-menu.component.js.map +1 -0
- package/esm2015/lib/components/table/table-row-menu/table-row-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/table/table-row-menu/table-row-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/table/table.component.js +1 -1
- package/esm2015/lib/components/table/table.component.js.map +1 -1
- package/esm2015/lib/components/table/table.component.metadata.json +1 -1
- package/esm2015/lib/components/track-by.js +5 -0
- package/esm2015/lib/components/track-by.js.map +1 -0
- package/esm2015/lib/interaction/activity-ref.js +10 -2
- package/esm2015/lib/interaction/activity-ref.js.map +1 -1
- package/esm2015/lib/interaction/activity-ref.metadata.json +1 -1
- package/esm2015/lib/interaction/activity.js +18 -1
- package/esm2015/lib/interaction/activity.js.map +1 -1
- package/esm2015/lib/interaction/activity.metadata.json +1 -1
- package/esm2015/lib/interaction/components/activity-actions/activity-actions.component.js +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 +24 -17
- 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.js.map +1 -1
- package/esm2015/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.metadata.json +1 -1
- package/esm2015/lib/interaction/interaction.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/components/abstract-place-navigation.component.js +4 -3
- package/esm2015/lib/place/components/abstract-place-navigation.component.js.map +1 -1
- package/esm2015/lib/place/components/abstract-place-navigation.component.metadata.json +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.js.map +1 -1
- package/esm2015/lib/place/components/list-place-nav/list-place-nav.component.metadata.json +1 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.js +56 -16
- 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 +2 -2
- package/esm2015/lib/place/components/side-place-navigation/side-place-navigation.component.js.map +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.js.map +1 -1
- package/esm2015/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.metadata.json +1 -1
- package/esm2015/lib/place/place-component.js +13 -1
- 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 +2 -8
- 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.js +3 -3
- package/esm2015/lib/place/place.module.js.map +1 -1
- package/esm2015/lib/place/place.module.metadata.json +1 -1
- package/esm2015/lib/place/place.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/route/parameter-decorators.js +2 -3
- package/esm2015/lib/place/route/parameter-decorators.js.map +1 -1
- package/esm2015/lib/place/route/parameter-decorators.metadata.json +1 -1
- package/esm5/coolon-angular-ui-powerups.js +44 -32
- package/esm5/coolon-angular-ui-powerups.js.map +1 -1
- package/esm5/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
- package/esm5/lib/components/card-container/card-container.component.js +1 -1
- package/esm5/lib/components/commands/command/command.component.js +64 -0
- package/esm5/lib/components/commands/command/command.component.js.map +1 -0
- package/esm5/lib/components/commands/command/command.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/command-face/command-face.component.js +123 -0
- package/esm5/lib/components/commands/command-face/command-face.component.js.map +1 -0
- package/esm5/lib/components/commands/command-face/command-face.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/command-face/command-face.component.scss.ngstyle.js.map +1 -0
- package/esm5/lib/components/commands/command-face.js +145 -0
- package/esm5/lib/components/commands/command-face.js.map +1 -0
- package/esm5/lib/components/commands/flex.component.js +33 -0
- package/esm5/lib/components/commands/flex.component.js.map +1 -0
- package/esm5/lib/components/commands/flex.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group/command-group.component.js +51 -0
- package/esm5/lib/components/commands/group/command-group/command-group.component.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group/command-group.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js +59 -0
- package/esm5/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js +42 -0
- package/esm5/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group-renderer/command-group-renderer.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group-renderer/command-group-renderer.component.scss.shim.ngstyle.js.map +1 -0
- package/esm5/lib/components/commands/group/command-group.js +122 -0
- package/esm5/lib/components/commands/group/command-group.js.map +1 -0
- package/esm5/lib/components/commands/group/more-menu.component.js +58 -0
- package/esm5/lib/components/commands/group/more-menu.component.js.map +1 -0
- package/esm5/lib/components/commands/group/more-menu.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/group/popup-menu.component.js +68 -0
- package/esm5/lib/components/commands/group/popup-menu.component.js.map +1 -0
- package/esm5/lib/components/commands/group/popup-menu.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/group/registration.js +80 -0
- package/esm5/lib/components/commands/group/registration.js.map +1 -0
- package/esm5/lib/components/commands/group/tool-bar/tool-bar.component.js +58 -0
- package/esm5/lib/components/commands/group/tool-bar/tool-bar.component.js.map +1 -0
- package/esm5/lib/components/commands/group/tool-bar/tool-bar.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/commands/group/tool-bar/tool-bar.component.scss.shim.ngstyle.js.map +1 -0
- package/esm5/lib/components/commands/group/view-data.js +131 -0
- package/esm5/lib/components/commands/group/view-data.js.map +1 -0
- package/esm5/lib/components/commands/separator.component.js +37 -0
- package/esm5/lib/components/commands/separator.component.js.map +1 -0
- package/esm5/lib/components/commands/separator.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/components.module.js +38 -15
- package/esm5/lib/components/components.module.js.map +1 -1
- package/esm5/lib/components/components.module.ngfactory.js.map +1 -1
- package/esm5/lib/components/forms/abstract-input.component.js +12 -4
- package/esm5/lib/components/forms/abstract-input.component.js.map +1 -1
- package/esm5/lib/components/forms/abstract-list-input.component.js +27 -14
- package/esm5/lib/components/forms/abstract-list-input.component.js.map +1 -1
- package/esm5/lib/components/forms/abstract-value-input.component.js +23 -13
- package/esm5/lib/components/forms/abstract-value-input.component.js.map +1 -1
- package/esm5/lib/components/forms/autocomplete-input/autocomplete-input.component.js +7 -1
- package/esm5/lib/components/forms/autocomplete-input/autocomplete-input.component.js.map +1 -1
- package/esm5/lib/components/forms/checkbox-input/checkbox-input.component.js +1 -1
- package/esm5/lib/components/forms/checkbox-input/checkbox-input.component.js.map +1 -1
- package/esm5/lib/components/forms/multiple-select-input/multiple-select-input.component.js +2 -10
- package/esm5/lib/components/forms/multiple-select-input/multiple-select-input.component.js.map +1 -1
- package/esm5/lib/components/forms/number-input/number-input.component.js +1 -1
- package/esm5/lib/components/forms/number-input/number-input.component.js.map +1 -1
- package/esm5/lib/components/forms/password-input/password-input.component.js +1 -1
- package/esm5/lib/components/forms/password-input/password-input.component.js.map +1 -1
- package/esm5/lib/components/forms/select-input/select-input.component.js +2 -2
- package/esm5/lib/components/forms/select-input/select-input.component.js.map +1 -1
- package/esm5/lib/components/forms/string-input/string-input.component.js +3 -3
- package/esm5/lib/components/forms/string-input/string-input.component.js.map +1 -1
- package/esm5/lib/components/forms/text-input/text-input.component.js +1 -1
- package/esm5/lib/components/forms/text-input/text-input.component.js.map +1 -1
- package/esm5/lib/components/icon/icon.component.js +15 -3
- package/esm5/lib/components/icon/icon.component.js.map +1 -1
- package/esm5/lib/components/index.js +16 -0
- package/esm5/lib/components/index.js.map +1 -1
- package/esm5/lib/components/table/column-model.js +45 -2
- package/esm5/lib/components/table/column-model.js.map +1 -1
- package/esm5/lib/components/table/mutable-cell-renderer.js +1 -0
- package/esm5/lib/components/table/mutable-cell-renderer.js.map +1 -0
- package/esm5/lib/components/table/table-model.js +10 -8
- package/esm5/lib/components/table/table-model.js.map +1 -1
- package/esm5/lib/components/table/table-row-menu/table-row-menu.component.js +63 -0
- package/esm5/lib/components/table/table-row-menu/table-row-menu.component.js.map +1 -0
- package/esm5/lib/components/table/table-row-menu/table-row-menu.component.ngfactory.js.map +1 -0
- package/esm5/lib/components/table/table.component.js +1 -1
- package/esm5/lib/components/table/table.component.js.map +1 -1
- package/esm5/lib/components/track-by.js +5 -0
- package/esm5/lib/components/track-by.js.map +1 -0
- package/esm5/lib/interaction/activity-ref.js +14 -2
- package/esm5/lib/interaction/activity-ref.js.map +1 -1
- package/esm5/lib/interaction/activity.js +27 -1
- package/esm5/lib/interaction/activity.js.map +1 -1
- package/esm5/lib/interaction/components/activity-actions/activity-actions.component.js +1 -1
- package/esm5/lib/interaction/components/activity-container/activity-container.component.js +24 -17
- package/esm5/lib/interaction/components/activity-container/activity-container.component.js.map +1 -1
- package/esm5/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.js +1 -1
- package/esm5/lib/interaction/components/activity-container/activity-outlet/activity-outlet.component.js.map +1 -1
- package/esm5/lib/interaction/interaction.module.ngfactory.js.map +1 -1
- package/esm5/lib/place/components/abstract-place-navigation.component.js +4 -3
- package/esm5/lib/place/components/abstract-place-navigation.component.js.map +1 -1
- package/esm5/lib/place/components/list-place-nav/list-place-nav.component.js +1 -1
- package/esm5/lib/place/components/list-place-nav/list-place-nav.component.js.map +1 -1
- package/esm5/lib/place/components/place-outlet/place-outlet.component.js +56 -16
- package/esm5/lib/place/components/place-outlet/place-outlet.component.js.map +1 -1
- package/esm5/lib/place/components/side-place-navigation/side-place-navigation.component.js +2 -2
- package/esm5/lib/place/components/side-place-navigation/side-place-navigation.component.js.map +1 -1
- package/esm5/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.js +1 -1
- package/esm5/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.js.map +1 -1
- package/esm5/lib/place/place-component.js +17 -1
- package/esm5/lib/place/place-component.js.map +1 -1
- package/esm5/lib/place/place-router.js +2 -8
- package/esm5/lib/place/place-router.js.map +1 -1
- package/esm5/lib/place/place.module.js +3 -3
- package/esm5/lib/place/place.module.js.map +1 -1
- package/esm5/lib/place/place.module.ngfactory.js.map +1 -1
- package/esm5/lib/place/route/parameter-decorators.js +2 -3
- package/esm5/lib/place/route/parameter-decorators.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +1290 -214
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/fesm5/coolon-angular-ui-powerups.js +1468 -227
- package/fesm5/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/commands/command/command.component.d.ts +22 -0
- package/lib/components/commands/command-face/command-face.component.d.ts +34 -0
- package/lib/components/commands/command-face.d.ts +40 -0
- package/lib/components/commands/flex.component.d.ts +11 -0
- package/lib/components/commands/group/command-group/command-group.component.d.ts +11 -0
- package/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.d.ts +21 -0
- package/lib/components/commands/group/command-group-renderer/command-group-renderer.component.d.ts +13 -0
- package/lib/components/commands/group/command-group.d.ts +41 -0
- package/lib/components/commands/group/more-menu.component.d.ts +14 -0
- package/lib/components/commands/group/popup-menu.component.d.ts +17 -0
- package/lib/components/commands/group/registration.d.ts +32 -0
- package/lib/components/commands/group/tool-bar/tool-bar.component.d.ts +13 -0
- package/lib/components/commands/group/view-data.d.ts +40 -0
- package/lib/components/commands/separator.component.d.ts +12 -0
- package/lib/components/forms/abstract-input.component.d.ts +8 -2
- package/lib/components/forms/abstract-list-input.component.d.ts +4 -3
- package/lib/components/forms/abstract-value-input.component.d.ts +4 -3
- package/lib/components/forms/autocomplete-input/autocomplete-input.component.d.ts +3 -0
- package/lib/components/forms/multiple-select-input/multiple-select-input.component.d.ts +1 -3
- package/lib/components/forms/select-input/select-input.component.d.ts +1 -1
- package/lib/components/icon/icon.component.d.ts +15 -0
- package/lib/components/index.d.ts +17 -0
- package/lib/components/table/column-model.d.ts +15 -17
- package/lib/components/table/mutable-cell-renderer.d.ts +6 -0
- package/lib/components/table/table-model.d.ts +7 -3
- package/lib/components/table/table-row-menu/table-row-menu.component.d.ts +26 -0
- package/lib/components/track-by.d.ts +3 -0
- package/lib/interaction/activity-ref.d.ts +3 -0
- package/lib/interaction/activity.d.ts +6 -2
- package/lib/interaction/components/activity-container/activity-container.component.d.ts +4 -2
- package/lib/place/components/abstract-place-navigation.component.d.ts +2 -2
- package/lib/place/components/place-outlet/place-outlet.component.d.ts +8 -2
- package/lib/place/components/side-place-navigation/side-place-navigation.component.d.ts +1 -1
- package/lib/place/place-component.d.ts +6 -0
- package/package.json +7 -5
- package/schematics/bootstrap-app/index.d.ts +3 -0
- package/schematics/bootstrap-app/index.js +81 -0
- package/schematics/bootstrap-app/index.js.map +1 -0
- package/schematics/bootstrap-app/schema.d.ts +3 -0
- package/schematics/bootstrap-app/schema.js +3 -0
- package/schematics/bootstrap-app/schema.js.map +1 -0
- package/schematics/bootstrap-app/schema.json +19 -0
- package/schematics/bootstrap-app/templates/app/app-routing.module.ts +19 -0
- package/schematics/bootstrap-app/templates/app/auth/auth.guard.spec.ts +15 -0
- package/schematics/bootstrap-app/templates/app/auth/auth.guard.ts +23 -0
- package/schematics/bootstrap-app/templates/app/auth/auth.module.ts +13 -0
- package/schematics/bootstrap-app/templates/app/auth/auth.service.ts +13 -0
- package/schematics/bootstrap-app/templates/app/i18n.ts +9 -0
- package/schematics/bootstrap-app/templates/app/places/home/home.component.html +1 -0
- package/schematics/bootstrap-app/templates/app/places/home/home.component.scss +4 -0
- package/schematics/bootstrap-app/templates/app/places/home/home.component.spec.ts +25 -0
- package/schematics/bootstrap-app/templates/app/places/home/home.component.ts +25 -0
- package/schematics/bootstrap-app/templates/app/places/place-routes.ts +3 -0
- package/schematics/bootstrap-app/templates/app/places/places.json5 +3 -0
- package/schematics/bootstrap-app/templates/i18n/config.json +9 -0
- package/schematics/bootstrap-app/templates/i18n/notifications.yml +19 -0
- package/schematics/bootstrap-app/templates/i18n/places/home.yml +6 -0
- package/schematics/collection.json +10 -1
- package/schematics/ng-add/index.d.ts +1 -0
- package/schematics/ng-add/index.js +27 -4
- package/schematics/ng-add/index.js.map +1 -1
- package/schematics/package-util.d.ts +13 -0
- package/schematics/package-util.js +60 -0
- package/schematics/package-util.js.map +1 -0
- package/schematics/place-add/index.d.ts +3 -0
- package/schematics/place-add/index.js +26 -0
- package/schematics/place-add/index.js.map +1 -0
- package/schematics/place-add/schema.d.ts +2 -0
- package/schematics/place-add/schema.js +3 -0
- package/schematics/place-add/schema.js.map +1 -0
- package/schematics/place-add/schema.json +8 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __extends, __decorate, __metadata, __param, __assign, __awaiter, __generator, __spread } from 'tslib';
|
|
2
2
|
import { DOCUMENT, CommonModule, Location } from '@angular/common';
|
|
3
|
-
import { ElementRef, Inject, Input, HostListener, Directive, NgZone, ɵɵdefineInjectable, ɵɵinject, Injectable, NgModule, ContentChild, TemplateRef, Component,
|
|
3
|
+
import { ElementRef, Inject, Input, HostListener, Directive, NgZone, ɵɵdefineInjectable, ɵɵinject, Injectable, NgModule, ContentChild, TemplateRef, Component, EventEmitter, Optional, SkipSelf, ViewChild, Output, ViewChildren, QueryList, HostBinding, ViewEncapsulation, Self, ChangeDetectorRef, ContentChildren, ViewContainerRef, InjectionToken, Injector, ComponentFactoryResolver } from '@angular/core';
|
|
4
4
|
import { FormsModule } from '@angular/forms';
|
|
5
5
|
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
6
6
|
import { MatInputModule } from '@angular/material/input';
|
|
@@ -12,23 +12,26 @@ import { CdkScrollableModule } from '@angular/cdk/scrolling';
|
|
|
12
12
|
import { MatAutocompleteModule } from '@angular/material/autocomplete';
|
|
13
13
|
import { MatButtonModule } from '@angular/material/button';
|
|
14
14
|
import { MatCheckboxModule } from '@angular/material/checkbox';
|
|
15
|
+
import { MatDividerModule } from '@angular/material/divider';
|
|
15
16
|
import { MatIconModule } from '@angular/material/icon';
|
|
17
|
+
import { MatMenu, MatMenuTrigger, MatMenuModule } from '@angular/material/menu';
|
|
16
18
|
import { MatTableModule } from '@angular/material/table';
|
|
17
19
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
18
20
|
import { FaIconLibrary, FontAwesomeModule } from '@fortawesome/angular-fontawesome';
|
|
19
21
|
import { fas } from '@fortawesome/free-solid-svg-icons';
|
|
20
|
-
import { DelegatingValueModel, assert, UnaryCommand, lang, Dsl, GarbageCollector, Logger, TrackExternal, Command,
|
|
22
|
+
import { DelegatingValueModel, assert, UnaryCommand, lang, Dsl, GarbageCollector, Logger, TrackExternal, Command, MutableValueModel, StoreInValueModel, ValueModel, MutableListModel, Trace, FocusManager, EventListenerList, Form, Guard, Binding, DebugContext, ListModel, StoreInListModel, MultipleSelectionModel, DirtyTrackingForm, DelegatingCommand, Deferred, Functions } from '@coolon/pectin';
|
|
23
|
+
import { Memoize } from '@typescript-plus/fast-memoize-decorator/dist/src';
|
|
21
24
|
import ___default, { isEqual, isNil } from 'lodash';
|
|
25
|
+
import { Enum } from 'typescript-string-enums';
|
|
22
26
|
import { assert as assert$1, Opts, lang as lang$1, Klass } from '@coolon/typescript-utilities';
|
|
23
|
-
import { Memoize } from '@typescript-plus/fast-memoize-decorator/dist/src';
|
|
24
27
|
import produce from 'immer';
|
|
25
28
|
import { FlexModule, GridModule } from '@angular/flex-layout';
|
|
26
29
|
import { MatDialogModule, MatDialog, MatDialogConfig, MAT_DIALOG_DEFAULT_OPTIONS } from '@angular/material/dialog';
|
|
27
30
|
import { RouterModule, UrlSegment, Router, UrlSerializer, NavigationStart, NavigationEnd, NavigationError, NavigationCancel, RouterOutlet } from '@angular/router';
|
|
28
31
|
import { Overlay, CdkScrollable } from '@angular/cdk/overlay';
|
|
29
32
|
import ResizeObserver from 'resize-observer-polyfill';
|
|
30
|
-
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
31
33
|
import { MatListModule } from '@angular/material/list';
|
|
34
|
+
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
32
35
|
import { Memoize as Memoize$1 } from '@typescript-plus/fast-memoize-decorator';
|
|
33
36
|
import 'reflect-metadata';
|
|
34
37
|
import { style, query, group, animate, trigger, transition } from '@angular/animations';
|
|
@@ -407,13 +410,1005 @@ var CardContainerComponent = /** @class */ (function (_super) {
|
|
|
407
410
|
Component({
|
|
408
411
|
selector: 'aup-card-container',
|
|
409
412
|
template: "<div class=\"card-container\">\n <ng-content></ng-content>\n\n <div class=\"add-card-container\" *ngIf=\"addCardCommand.enabled.value\" [pectinCommand]=\"addCardCommand\">\n <aup-icon 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\n</div>\n",
|
|
410
|
-
styles: [":root{--aup-default-padding:var(--default-padding, 18px);--aup-default-background:white}.router-outlet-container>*{position:absolute;top:0;left:0;bottom:0;right:0}[no-tab-header]>mat-tab-header{display:none}[full-height-tabs] .mat-tab-body-wrapper,mat-tab-group.full-height-tabs .mat-tab-body-wrapper{flex:1}[full-height-tabs] .mat-tab-body-wrapper .mat-tab-body-content,[full-height-tabs] .mat-tab-body-wrapper mat-tab-body,mat-tab-group.full-height-tabs .mat-tab-body-wrapper .mat-tab-body-content,mat-tab-group.full-height-tabs .mat-tab-body-wrapper mat-tab-body{display:flex;flex-direction:column;justify-content:stretch}.dialog-interaction-context{max-width:95vw!important;max-height:95vh!important}.dialog-interaction-context mat-dialog-container{max-width:95vw!important;max-height:95vh!important;padding:0}.aup-popup-interaction-panel{background:var(--aup-default-background,#fff);box-shadow:0 2px 1px -1px rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 1px 3px 0 rgba(0,0,0,.12);transition:box-shadow 280ms cubic-bezier(.4,0,.2,1)}.aup-input-activity{padding:calc(var(--aup-default-padding)/2)}.aup-input-component{display:block}.aup-input-component input,.aup-input-component mat-form-field{width:100%}.aup-input-component input mat-hint.faux-error,.aup-input-component mat-form-field mat-hint.faux-error{color:#f44336}.aup-input-component.dense mat-form-field .mat-form-field-infix{border-top:none}.aup-input-component.dense mat-form-field .mat-form-field-flex{padding-top:0}.aup-input-component.dense mat-form-field .mat-form-field-wrapper{padding-bottom:0;border-bottom:0}.aup-input-component.dense mat-form-field .mat-form-field-underline{bottom:0}.aup-input-component.dense mat-form-field.mat-form-field-can-float.mat-form-field-should-float .mat-form-field-label-wrapper{display:none}.aup-input-component.dense mat-form-field.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(0)}aup-table-cell-renderer>.aup-input-component .mat-form-field-flex{padding-top:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-infix{width:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-label-wrapper{display:none}aup-table{--default-column-gap:var(--column-gap, 24px);--resolved-row-hover-background-color:var(--row-hover-background-color, rgba(0, 0, 0, 0.05))}aup-table .mat-table td.mat-cell:first-of-type,aup-table .mat-table td.mat-footer-cell:first-of-type,aup-table .mat-table th.mat-header-cell:first-of-type{padding-left:0}aup-table .mat-table tr.enable-hover:hover{background-color:var(--resolved-row-hover-background-color)}aup-table .mat-table td.enable-cursor{cursor:pointer}aup-table aup-table-cell-renderer,aup-table aup-table-header-cell-renderer{display:flex;flex-direction:column;align-items:stretch;justify-content:center;height:100%;min-height:47px}aup-table aup-table-cell-renderer.first-column,aup-table aup-table-cell-renderer:not(.first-column),aup-table aup-table-header-cell-renderer.first-column,aup-table aup-table-header-cell-renderer:not(.first-column){padding-left:var(--default-column-gap)}aup-table aup-table-cell-renderer.fillCell{justify-content:stretch;padding-left:0!important}aup-table aup-table-cell-renderer.padChild>:first-child{padding-left:var(--default-column-gap);flex:1}: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, #fcfcfb);flex:1;display:block;background:var(--resolved-card-background)}.card-container{display:-ms-grid;display:grid;grid-template-columns:repeat(auto-fill,var(--resolved-card-width));grid-template-rows:repeat(auto-fit,minmax(0,var(--resolved-card-height)));grid-gap:var(--resolved-card-gap);box-sizing:border-box;padding:var(--resolved-card-gap);min-height:calc(var(--resolved-card-height) + 2 * var(--resolved-card-gap));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));max-width:100%}.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;box-sizing:border-box;border:2px dashed rgba(0,0,0,.1);border-radius:6px;font-weight:300;cursor:pointer;color:rgba(0,0,0,.54);background-color:rgba(255,255,255,.8);transition:280ms cubic-bezier(.4,0,.2,1)}.add-card-container mat-icon{font-size:200%}.add-card-container:hover{transition:280ms cubic-bezier(.4,0,.2,1);border-color:transparent;background-color:#fff;color:rgba(0,0,0,.54)}.add-card-container:hover:hover{box-shadow:0 2px 4px -1px rgba(0,0,0,.2),0 4px 5px 0 rgba(0,0,0,.14),0 1px 10px 0 rgba(0,0,0,.12)}.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}"]
|
|
413
|
+
styles: [":root{--aup-default-padding:var(--default-padding, 18px);--aup-default-background:white;--aup-command-face-icon-gap:8px;--aup-icon-width:24px;--aup-fa-icon-width:18px}.router-outlet-container>*{position:absolute;top:0;left:0;bottom:0;right:0}[no-tab-header]>mat-tab-header{display:none}[full-height-tabs] .mat-tab-body-wrapper,mat-tab-group.full-height-tabs .mat-tab-body-wrapper{flex:1}[full-height-tabs] .mat-tab-body-wrapper .mat-tab-body-content,[full-height-tabs] .mat-tab-body-wrapper mat-tab-body,mat-tab-group.full-height-tabs .mat-tab-body-wrapper .mat-tab-body-content,mat-tab-group.full-height-tabs .mat-tab-body-wrapper mat-tab-body{display:flex;flex-direction:column;justify-content:stretch}.dialog-interaction-context{max-width:95vw!important;max-height:95vh!important}.dialog-interaction-context mat-dialog-container{max-width:95vw!important;max-height:95vh!important;padding:0}.activity-outlet-wrapper{display:flex;flex-direction:column;align-items:stretch}.aup-popup-interaction-panel{background:var(--aup-default-background,#fff);box-shadow:0 2px 1px -1px rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 1px 3px 0 rgba(0,0,0,.12);transition:box-shadow 280ms cubic-bezier(.4,0,.2,1)}.aup-input-activity{padding:calc(var(--aup-default-padding)/2)}.aup-input-component{display:block}.aup-input-component input,.aup-input-component mat-form-field{width:100%}.aup-input-component input mat-hint.faux-error,.aup-input-component mat-form-field mat-hint.faux-error{color:#f44336}.aup-input-component.dense mat-form-field .mat-form-field-infix{border-top:none}.aup-input-component.dense mat-form-field .mat-form-field-flex{padding-top:0}.aup-input-component.dense mat-form-field .mat-form-field-wrapper{padding-bottom:0;border-bottom:0}.aup-input-component.dense mat-form-field .mat-form-field-underline{bottom:0}.aup-input-component.dense mat-form-field.mat-form-field-can-float.mat-form-field-should-float .mat-form-field-label-wrapper{display:none}.aup-input-component.dense mat-form-field.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(0)}aup-table-cell-renderer>.aup-input-component .mat-form-field-flex{padding-top:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-infix{width:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-label-wrapper{display:none}aup-table{--default-column-gap:var(--column-gap, 24px);--resolved-row-hover-background-color:var(--row-hover-background-color, rgba(0, 0, 0, 0.05))}aup-table .mat-table td.mat-cell:first-of-type,aup-table .mat-table td.mat-footer-cell:first-of-type,aup-table .mat-table th.mat-header-cell:first-of-type{padding-left:0}aup-table .mat-table tr.enable-hover:hover{background-color:var(--resolved-row-hover-background-color)}aup-table .mat-table td.enable-cursor{cursor:pointer}aup-table aup-table-cell-renderer,aup-table aup-table-header-cell-renderer{display:flex;flex-direction:column;align-items:stretch;justify-content:center;height:100%;min-height:47px}aup-table aup-table-cell-renderer.first-column,aup-table aup-table-cell-renderer:not(.first-column),aup-table aup-table-header-cell-renderer.first-column,aup-table aup-table-header-cell-renderer:not(.first-column){padding-left:var(--default-column-gap)}aup-table aup-table-cell-renderer.fillCell{justify-content:stretch;padding-left:0!important}aup-table aup-table-cell-renderer.padChild>:first-child{padding-left:var(--default-column-gap);flex:1}aup-icon{--fa-icon-offset:calc((var(--aup-icon-width) - var(--aup-fa-icon-width)) / 2);position:relative}aup-icon fa-icon .svg-inline--fa{position:absolute;top:var(--fa-icon-offset);left:var(--fa-icon-offset);width:var(--aup-fa-icon-width)!important;height:var(--aup-fa-icon-width)!important}.mat-menu-panel aup-icon .svg-inline--fa{opacity:.54}: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, #fcfcfb);flex:1;display:block;background:var(--resolved-card-background)}.card-container{display:-ms-grid;display:grid;grid-template-columns:repeat(auto-fill,var(--resolved-card-width));grid-template-rows:repeat(auto-fit,minmax(0,var(--resolved-card-height)));grid-gap:var(--resolved-card-gap);box-sizing:border-box;padding:var(--resolved-card-gap);min-height:calc(var(--resolved-card-height) + 2 * var(--resolved-card-gap));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));max-width:100%}.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;box-sizing:border-box;border:2px dashed rgba(0,0,0,.1);border-radius:6px;font-weight:300;cursor:pointer;color:rgba(0,0,0,.54);background-color:rgba(255,255,255,.8);transition:280ms cubic-bezier(.4,0,.2,1)}.add-card-container mat-icon{font-size:200%}.add-card-container:hover{transition:280ms cubic-bezier(.4,0,.2,1);border-color:transparent;background-color:#fff;color:rgba(0,0,0,.54)}.add-card-container:hover:hover{box-shadow:0 2px 4px -1px rgba(0,0,0,.2),0 4px 5px 0 rgba(0,0,0,.14),0 1px 10px 0 rgba(0,0,0,.12)}.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}"]
|
|
411
414
|
}),
|
|
412
415
|
__metadata("design:paramtypes", [])
|
|
413
416
|
], CardContainerComponent);
|
|
414
417
|
return CardContainerComponent;
|
|
415
418
|
}(DisposableComponent));
|
|
416
419
|
|
|
420
|
+
var TrackBy;
|
|
421
|
+
(function (TrackBy) {
|
|
422
|
+
TrackBy.byIndex = function (data, index) { return index; };
|
|
423
|
+
})(TrackBy || (TrackBy = {}));
|
|
424
|
+
|
|
425
|
+
var CommandFace;
|
|
426
|
+
(function (CommandFace) {
|
|
427
|
+
var Position;
|
|
428
|
+
(function (Position) {
|
|
429
|
+
Position["START"] = "start";
|
|
430
|
+
Position["END"] = "end";
|
|
431
|
+
})(Position = CommandFace.Position || (CommandFace.Position = {}));
|
|
432
|
+
CommandFace.Style = Enum({
|
|
433
|
+
FLAT: 'flat',
|
|
434
|
+
STROKED: 'stroked',
|
|
435
|
+
RAISED: 'raised'
|
|
436
|
+
});
|
|
437
|
+
function getColorOf(face) {
|
|
438
|
+
return ___default.isFunction(face === null || face === void 0 ? void 0 : face.color) ? face.color() : undefined;
|
|
439
|
+
}
|
|
440
|
+
CommandFace.getColorOf = getColorOf;
|
|
441
|
+
function getStyleOf(face) {
|
|
442
|
+
return ___default.isFunction(face === null || face === void 0 ? void 0 : face.style) ? face.style() : undefined;
|
|
443
|
+
}
|
|
444
|
+
CommandFace.getStyleOf = getStyleOf;
|
|
445
|
+
function getIconOf(face) {
|
|
446
|
+
return ___default.isFunction(face === null || face === void 0 ? void 0 : face.icon) ? face.icon() : undefined;
|
|
447
|
+
}
|
|
448
|
+
CommandFace.getIconOf = getIconOf;
|
|
449
|
+
function getIconPositionOf(face) {
|
|
450
|
+
return ___default.isFunction(face === null || face === void 0 ? void 0 : face.iconPosition) ? face.iconPosition() : undefined;
|
|
451
|
+
}
|
|
452
|
+
CommandFace.getIconPositionOf = getIconPositionOf;
|
|
453
|
+
function getTooltipOf(face) {
|
|
454
|
+
return ___default.isFunction(face === null || face === void 0 ? void 0 : face.tooltip) ? face.tooltip() : undefined;
|
|
455
|
+
}
|
|
456
|
+
CommandFace.getTooltipOf = getTooltipOf;
|
|
457
|
+
function getTextOf(face) {
|
|
458
|
+
return ___default.isFunction(face === null || face === void 0 ? void 0 : face.text) ? face.text() : undefined;
|
|
459
|
+
}
|
|
460
|
+
CommandFace.getTextOf = getTextOf;
|
|
461
|
+
var Adapter = /** @class */ (function () {
|
|
462
|
+
function Adapter(face) {
|
|
463
|
+
this.face = face;
|
|
464
|
+
}
|
|
465
|
+
Object.defineProperty(Adapter.prototype, "text", {
|
|
466
|
+
get: function () {
|
|
467
|
+
return CommandFace.getTextOf(this.face);
|
|
468
|
+
},
|
|
469
|
+
enumerable: true,
|
|
470
|
+
configurable: true
|
|
471
|
+
});
|
|
472
|
+
Object.defineProperty(Adapter.prototype, "icon", {
|
|
473
|
+
get: function () {
|
|
474
|
+
return CommandFace.getIconOf(this.face);
|
|
475
|
+
},
|
|
476
|
+
enumerable: true,
|
|
477
|
+
configurable: true
|
|
478
|
+
});
|
|
479
|
+
Object.defineProperty(Adapter.prototype, "iconPosition", {
|
|
480
|
+
get: function () {
|
|
481
|
+
return CommandFace.getIconPositionOf(this.face);
|
|
482
|
+
},
|
|
483
|
+
enumerable: true,
|
|
484
|
+
configurable: true
|
|
485
|
+
});
|
|
486
|
+
Object.defineProperty(Adapter.prototype, "tooltip", {
|
|
487
|
+
get: function () {
|
|
488
|
+
return CommandFace.getTooltipOf(this.face);
|
|
489
|
+
},
|
|
490
|
+
enumerable: true,
|
|
491
|
+
configurable: true
|
|
492
|
+
});
|
|
493
|
+
Object.defineProperty(Adapter.prototype, "iconPositionStart", {
|
|
494
|
+
get: function () {
|
|
495
|
+
return this.iconPosition === CommandFace.Position.START;
|
|
496
|
+
},
|
|
497
|
+
enumerable: true,
|
|
498
|
+
configurable: true
|
|
499
|
+
});
|
|
500
|
+
Object.defineProperty(Adapter.prototype, "iconPositionEnd", {
|
|
501
|
+
get: function () {
|
|
502
|
+
return this.iconPosition === CommandFace.Position.END;
|
|
503
|
+
},
|
|
504
|
+
enumerable: true,
|
|
505
|
+
configurable: true
|
|
506
|
+
});
|
|
507
|
+
Object.defineProperty(Adapter.prototype, "color", {
|
|
508
|
+
get: function () {
|
|
509
|
+
return CommandFace.getColorOf(this.face);
|
|
510
|
+
},
|
|
511
|
+
enumerable: true,
|
|
512
|
+
configurable: true
|
|
513
|
+
});
|
|
514
|
+
Object.defineProperty(Adapter.prototype, "style", {
|
|
515
|
+
get: function () {
|
|
516
|
+
return CommandFace.getStyleOf(this.face);
|
|
517
|
+
},
|
|
518
|
+
enumerable: true,
|
|
519
|
+
configurable: true
|
|
520
|
+
});
|
|
521
|
+
__decorate([
|
|
522
|
+
Memoize(),
|
|
523
|
+
__metadata("design:type", Object),
|
|
524
|
+
__metadata("design:paramtypes", [])
|
|
525
|
+
], Adapter.prototype, "text", null);
|
|
526
|
+
__decorate([
|
|
527
|
+
Memoize(),
|
|
528
|
+
__metadata("design:type", Object),
|
|
529
|
+
__metadata("design:paramtypes", [])
|
|
530
|
+
], Adapter.prototype, "icon", null);
|
|
531
|
+
__decorate([
|
|
532
|
+
Memoize(),
|
|
533
|
+
__metadata("design:type", Object),
|
|
534
|
+
__metadata("design:paramtypes", [])
|
|
535
|
+
], Adapter.prototype, "iconPosition", null);
|
|
536
|
+
__decorate([
|
|
537
|
+
Memoize(),
|
|
538
|
+
__metadata("design:type", Object),
|
|
539
|
+
__metadata("design:paramtypes", [])
|
|
540
|
+
], Adapter.prototype, "tooltip", null);
|
|
541
|
+
__decorate([
|
|
542
|
+
Memoize(),
|
|
543
|
+
__metadata("design:type", Boolean),
|
|
544
|
+
__metadata("design:paramtypes", [])
|
|
545
|
+
], Adapter.prototype, "iconPositionStart", null);
|
|
546
|
+
__decorate([
|
|
547
|
+
Memoize(),
|
|
548
|
+
__metadata("design:type", Boolean),
|
|
549
|
+
__metadata("design:paramtypes", [])
|
|
550
|
+
], Adapter.prototype, "iconPositionEnd", null);
|
|
551
|
+
__decorate([
|
|
552
|
+
Memoize(),
|
|
553
|
+
__metadata("design:type", String),
|
|
554
|
+
__metadata("design:paramtypes", [])
|
|
555
|
+
], Adapter.prototype, "color", null);
|
|
556
|
+
__decorate([
|
|
557
|
+
Memoize(),
|
|
558
|
+
__metadata("design:type", String),
|
|
559
|
+
__metadata("design:paramtypes", [])
|
|
560
|
+
], Adapter.prototype, "style", null);
|
|
561
|
+
return Adapter;
|
|
562
|
+
}());
|
|
563
|
+
CommandFace.Adapter = Adapter;
|
|
564
|
+
})(CommandFace || (CommandFace = {}));
|
|
565
|
+
|
|
566
|
+
var ViewData = /** @class */ (function () {
|
|
567
|
+
function ViewData() {
|
|
568
|
+
}
|
|
569
|
+
return ViewData;
|
|
570
|
+
}());
|
|
571
|
+
(function (ViewData) {
|
|
572
|
+
var FaceData = /** @class */ (function (_super) {
|
|
573
|
+
__extends(FaceData, _super);
|
|
574
|
+
function FaceData(face) {
|
|
575
|
+
var _this = _super.call(this) || this;
|
|
576
|
+
_this.faceAdapter = new CommandFace.Adapter(face);
|
|
577
|
+
return _this;
|
|
578
|
+
}
|
|
579
|
+
return FaceData;
|
|
580
|
+
}(ViewData));
|
|
581
|
+
ViewData.FaceData = FaceData;
|
|
582
|
+
var GroupData = /** @class */ (function (_super) {
|
|
583
|
+
__extends(GroupData, _super);
|
|
584
|
+
function GroupData(face, xPosition, yPosition, children) {
|
|
585
|
+
var _this = _super.call(this, face) || this;
|
|
586
|
+
_this.xPosition = xPosition;
|
|
587
|
+
_this.yPosition = yPosition;
|
|
588
|
+
_this.children = children;
|
|
589
|
+
return _this;
|
|
590
|
+
}
|
|
591
|
+
Object.defineProperty(GroupData.prototype, "hasMixedIcons", {
|
|
592
|
+
get: function () {
|
|
593
|
+
var hasFaces = this.children.filter(function (c) { return ViewData.hasFace(c); });
|
|
594
|
+
var iconCount = hasFaces.filter(function (c) { return !!c.faceAdapter.icon; }).length;
|
|
595
|
+
return iconCount > 0 && hasFaces.length !== iconCount;
|
|
596
|
+
},
|
|
597
|
+
enumerable: true,
|
|
598
|
+
configurable: true
|
|
599
|
+
});
|
|
600
|
+
__decorate([
|
|
601
|
+
Memoize(),
|
|
602
|
+
__metadata("design:type", Boolean),
|
|
603
|
+
__metadata("design:paramtypes", [])
|
|
604
|
+
], GroupData.prototype, "hasMixedIcons", null);
|
|
605
|
+
return GroupData;
|
|
606
|
+
}(FaceData));
|
|
607
|
+
ViewData.GroupData = GroupData;
|
|
608
|
+
var CommandData = /** @class */ (function (_super) {
|
|
609
|
+
__extends(CommandData, _super);
|
|
610
|
+
function CommandData(face, command) {
|
|
611
|
+
var _this = _super.call(this, face) || this;
|
|
612
|
+
_this.command = command;
|
|
613
|
+
return _this;
|
|
614
|
+
}
|
|
615
|
+
return CommandData;
|
|
616
|
+
}(FaceData));
|
|
617
|
+
ViewData.CommandData = CommandData;
|
|
618
|
+
var SeparatorData = /** @class */ (function (_super) {
|
|
619
|
+
__extends(SeparatorData, _super);
|
|
620
|
+
function SeparatorData() {
|
|
621
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
622
|
+
}
|
|
623
|
+
return SeparatorData;
|
|
624
|
+
}(ViewData));
|
|
625
|
+
ViewData.SeparatorData = SeparatorData;
|
|
626
|
+
var FlexData = /** @class */ (function (_super) {
|
|
627
|
+
__extends(FlexData, _super);
|
|
628
|
+
function FlexData() {
|
|
629
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
630
|
+
}
|
|
631
|
+
return FlexData;
|
|
632
|
+
}(ViewData));
|
|
633
|
+
ViewData.FlexData = FlexData;
|
|
634
|
+
function as(type, viewData) {
|
|
635
|
+
return viewData instanceof type ? viewData : lang.illegalState("expected instance of " + type.name + ", got " + viewData.constructor.name);
|
|
636
|
+
}
|
|
637
|
+
ViewData.as = as;
|
|
638
|
+
function getCommand(data) {
|
|
639
|
+
return as(CommandData, data).command;
|
|
640
|
+
}
|
|
641
|
+
ViewData.getCommand = getCommand;
|
|
642
|
+
function getTooltip(data) {
|
|
643
|
+
return as(FaceData, data).faceAdapter.tooltip;
|
|
644
|
+
}
|
|
645
|
+
ViewData.getTooltip = getTooltip;
|
|
646
|
+
function getStyle(data) {
|
|
647
|
+
return as(FaceData, data).faceAdapter.style;
|
|
648
|
+
}
|
|
649
|
+
ViewData.getStyle = getStyle;
|
|
650
|
+
function getColor(data) {
|
|
651
|
+
return as(FaceData, data).faceAdapter.color;
|
|
652
|
+
}
|
|
653
|
+
ViewData.getColor = getColor;
|
|
654
|
+
function hasText(data) {
|
|
655
|
+
return !!as(FaceData, data).faceAdapter.text;
|
|
656
|
+
}
|
|
657
|
+
ViewData.hasText = hasText;
|
|
658
|
+
function getFace(data) {
|
|
659
|
+
return as(FaceData, data).faceAdapter.face;
|
|
660
|
+
}
|
|
661
|
+
ViewData.getFace = getFace;
|
|
662
|
+
function asGroup(viewData) {
|
|
663
|
+
return as(GroupData, viewData);
|
|
664
|
+
}
|
|
665
|
+
ViewData.asGroup = asGroup;
|
|
666
|
+
function hasMixedIcons(data) {
|
|
667
|
+
return as(GroupData, data).hasMixedIcons;
|
|
668
|
+
}
|
|
669
|
+
ViewData.hasMixedIcons = hasMixedIcons;
|
|
670
|
+
function isGroup(data) {
|
|
671
|
+
return data instanceof GroupData;
|
|
672
|
+
}
|
|
673
|
+
ViewData.isGroup = isGroup;
|
|
674
|
+
function hasFace(data) {
|
|
675
|
+
return data instanceof FaceData;
|
|
676
|
+
}
|
|
677
|
+
ViewData.hasFace = hasFace;
|
|
678
|
+
function isCommand(data) {
|
|
679
|
+
return data instanceof CommandData;
|
|
680
|
+
}
|
|
681
|
+
ViewData.isCommand = isCommand;
|
|
682
|
+
function isSeparator(data) {
|
|
683
|
+
return data instanceof SeparatorData;
|
|
684
|
+
}
|
|
685
|
+
ViewData.isSeparator = isSeparator;
|
|
686
|
+
function isFlex(data) {
|
|
687
|
+
return data instanceof FlexData;
|
|
688
|
+
}
|
|
689
|
+
ViewData.isFlex = isFlex;
|
|
690
|
+
})(ViewData || (ViewData = {}));
|
|
691
|
+
|
|
692
|
+
var CommandGroupMenuRendererComponent = /** @class */ (function (_super) {
|
|
693
|
+
__extends(CommandGroupMenuRendererComponent, _super);
|
|
694
|
+
function CommandGroupMenuRendererComponent(parent) {
|
|
695
|
+
var _this = _super.call(this) || this;
|
|
696
|
+
_this.parent = parent;
|
|
697
|
+
_this.groupViewDataModel = new MutableValueModel();
|
|
698
|
+
_this.commandFired = new EventEmitter();
|
|
699
|
+
_this.ViewData = ViewData;
|
|
700
|
+
_this.TrackBy = TrackBy;
|
|
701
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
702
|
+
_this.children = chain(_this.groupViewDataModel).pluckList('children');
|
|
703
|
+
_this.hasMixedIcons = chain(_this.groupViewDataModel).pluck('hasMixedIcons');
|
|
704
|
+
return _this;
|
|
705
|
+
}
|
|
706
|
+
CommandGroupMenuRendererComponent.prototype.getCommand = function (data) {
|
|
707
|
+
var _this = this;
|
|
708
|
+
var command = ViewData.getCommand(data);
|
|
709
|
+
var when = Dsl.disposeWith(this).when;
|
|
710
|
+
when(command.busy).becomesFalsey(function () { return _this.commandFired.emit(); });
|
|
711
|
+
return command;
|
|
712
|
+
};
|
|
713
|
+
CommandGroupMenuRendererComponent.ctorParameters = function () { return [
|
|
714
|
+
{ type: CommandGroupMenuRendererComponent, decorators: [{ type: Optional }, { type: SkipSelf }] }
|
|
715
|
+
]; };
|
|
716
|
+
__decorate([
|
|
717
|
+
ViewChild('menu', { static: true }),
|
|
718
|
+
__metadata("design:type", MatMenu)
|
|
719
|
+
], CommandGroupMenuRendererComponent.prototype, "menuComponent", void 0);
|
|
720
|
+
__decorate([
|
|
721
|
+
Input(), StoreInValueModel('groupViewDataModel'),
|
|
722
|
+
__metadata("design:type", ViewData.GroupData)
|
|
723
|
+
], CommandGroupMenuRendererComponent.prototype, "groupViewData", void 0);
|
|
724
|
+
__decorate([
|
|
725
|
+
Output(),
|
|
726
|
+
__metadata("design:type", Object)
|
|
727
|
+
], CommandGroupMenuRendererComponent.prototype, "commandFired", void 0);
|
|
728
|
+
__decorate([
|
|
729
|
+
ViewChildren(MatMenuTrigger),
|
|
730
|
+
__metadata("design:type", QueryList)
|
|
731
|
+
], CommandGroupMenuRendererComponent.prototype, "triggers", void 0);
|
|
732
|
+
CommandGroupMenuRendererComponent = __decorate([
|
|
733
|
+
Component({
|
|
734
|
+
selector: 'aup-command-group-menu',
|
|
735
|
+
template: "<mat-menu #menu [xPosition]=\"groupViewData.xPosition\" [yPosition]=\"groupViewData.yPosition\">\n <ng-container *ngFor=\"let data of children.value; trackBy: TrackBy.byIndex\" >\n <button *ngIf=\"ViewData.isCommand(data)\"\n [pectinCommand]=\"getCommand(data)\"\n [matTooltip]=\"ViewData.getTooltip(data)\"\n mat-menu-item>\n <aup-command-face [face]=\"ViewData.getFace(data)\"\n [includeMissingIconInLayout]=\"hasMixedIcons.value\"></aup-command-face>\n </button>\n\n <ng-container *ngIf=\"ViewData.isGroup(data)\">\n <button mat-menu-item\n #trigger=\"matMenuTrigger\"\n [matMenuTriggerFor]=\"innerPanel.menuComponent\"\n >\n <aup-command-face [face]=\"ViewData.getFace(data)\"\n [includeMissingIconInLayout]=\"hasMixedIcons.value\"></aup-command-face>\n </button>\n <aup-command-group-menu #innerPanel\n [groupViewData]=\"ViewData.asGroup(data)\"\n (commandFired)=\"trigger.closeMenu()\"></aup-command-group-menu>\n </ng-container>\n\n <mat-divider *ngIf=\"ViewData.isSeparator(data)\"></mat-divider>\n\n </ng-container>\n</mat-menu>\n"
|
|
736
|
+
}),
|
|
737
|
+
__param(0, Optional()), __param(0, SkipSelf()),
|
|
738
|
+
__metadata("design:paramtypes", [CommandGroupMenuRendererComponent])
|
|
739
|
+
], CommandGroupMenuRendererComponent);
|
|
740
|
+
return CommandGroupMenuRendererComponent;
|
|
741
|
+
}(DisposableComponent));
|
|
742
|
+
|
|
743
|
+
var CommandGroupRendererComponent = /** @class */ (function (_super) {
|
|
744
|
+
__extends(CommandGroupRendererComponent, _super);
|
|
745
|
+
function CommandGroupRendererComponent() {
|
|
746
|
+
var _this = _super.call(this) || this;
|
|
747
|
+
_this.renderRootNode = true;
|
|
748
|
+
_this.ViewData = ViewData;
|
|
749
|
+
_this.TrackBy = TrackBy;
|
|
750
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
751
|
+
_this.childViewDataModels = chain(_this.groupViewDataModel).pluckList('children');
|
|
752
|
+
return _this;
|
|
753
|
+
}
|
|
754
|
+
__decorate([
|
|
755
|
+
Input(), TrackExternal(),
|
|
756
|
+
__metadata("design:type", ValueModel)
|
|
757
|
+
], CommandGroupRendererComponent.prototype, "groupViewDataModel", void 0);
|
|
758
|
+
__decorate([
|
|
759
|
+
Input(), StoreInValueModel('groupViewDataModel'),
|
|
760
|
+
__metadata("design:type", ViewData.GroupData)
|
|
761
|
+
], CommandGroupRendererComponent.prototype, "groupViewData", void 0);
|
|
762
|
+
__decorate([
|
|
763
|
+
Input(),
|
|
764
|
+
HostBinding('class.render-root'),
|
|
765
|
+
__metadata("design:type", Object)
|
|
766
|
+
], CommandGroupRendererComponent.prototype, "renderRootNode", void 0);
|
|
767
|
+
CommandGroupRendererComponent = __decorate([
|
|
768
|
+
Component({
|
|
769
|
+
selector: 'aup-command-group-renderer',
|
|
770
|
+
template: "<ng-template #groupTemplate let-group>\n\n <ng-container *ngIf=\"ViewData.hasText(group)\" [ngSwitch]=\"ViewData.getStyle(group)\">\n <ng-container *ngSwitchCase=\"'stroked'\">\n <button #trigger=\"matMenuTrigger\"\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"ViewData.getTooltip(group)\"\n [color]=\"ViewData.getColor(group)\"\n mat-stroked-button>\n <aup-command-face [face]=\"ViewData.getFace(group)\"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]=\"group\" (commandFired)=\"trigger.closeMenu()\"></aup-command-group-menu>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'raised'\">\n <button #trigger=\"matMenuTrigger\"\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n\n [matTooltip]=\"ViewData.getTooltip(group)\"\n [color]=\"ViewData.getColor(group)\"\n mat-raised-button>\n <aup-command-face [face]=\"ViewData.getFace(group)\"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]=\"group\" (commandFired)=\"trigger.closeMenu()\"></aup-command-group-menu>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button #trigger=\"matMenuTrigger\"\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"ViewData.getTooltip(group)\"\n [color]=\"ViewData.getColor(group)\"\n mat-button>\n <aup-command-face [face]=\"ViewData.getFace(group)\"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]=\"group\" (commandFired)=\"trigger.closeMenu()\"></aup-command-group-menu>\n </ng-container>\n\n </ng-container>\n\n <ng-container *ngIf=\"!ViewData.hasText(group)\">\n <button #trigger=\"matMenuTrigger\"\n mat-icon-button\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n\n [matTooltip]=\"ViewData.getTooltip(group)\"\n [color]=\"ViewData.getColor(group)\"\n >\n <aup-command-face [face]=\"ViewData.getFace(group)\"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]=\"group\" (commandFired)=\"trigger.closeMenu()\"></aup-command-group-menu>\n </ng-container>\n\n</ng-template>\n\n\n<ng-template #commandTemplate let-data>\n\n <ng-container *ngIf=\"ViewData.hasText(data)\" [ngSwitch]=\"ViewData.getStyle(data)\">\n <button *ngSwitchCase=\"'raised'\"\n [pectinCommand]=\"ViewData.getCommand(data)\"\n [matTooltip]=\"ViewData.getTooltip(data)\"\n [color]=\"ViewData.getColor(data)\"\n mat-raised-button>\n <aup-command-face [face]=\"ViewData.getFace(data)\"></aup-command-face>\n </button>\n <button *ngSwitchCase=\"'stroked'\"\n [pectinCommand]=\"ViewData.getCommand(data)\"\n [matTooltip]=\"ViewData.getTooltip(data)\"\n [color]=\"ViewData.getColor(data)\"\n mat-stroked-button>\n <aup-command-face [face]=\"ViewData.getFace(data)\"></aup-command-face>\n </button>\n <button *ngSwitchDefault\n [pectinCommand]=\"ViewData.getCommand(data)\"\n [matTooltip]=\"ViewData.getTooltip(data)\"\n [color]=\"ViewData.getColor(data)\"\n mat-button>\n <aup-command-face [face]=\"ViewData.getFace(data)\"></aup-command-face>\n </button>\n </ng-container>\n\n <button *ngIf=\"!ViewData.hasText(data)\"\n [pectinCommand]=\"ViewData.getCommand(data)\"\n [matTooltip]=\"ViewData.getTooltip(data)\"\n [color]=\"ViewData.getColor(data)\"\n mat-icon-button>\n <aup-command-face [face]=\"ViewData.getFace(data)\"></aup-command-face>\n </button>\n\n</ng-template>\n\n\n<ng-template *ngIf=\"renderRootNode\"\n [ngTemplateOutlet]=\"groupTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: groupViewDataModel.value }\">\n</ng-template>\n\n<ng-container *ngIf=\"!renderRootNode\">\n <ng-container *ngFor=\"let data of this.childViewDataModels.value; trackBy: TrackBy.byIndex\">\n <ng-template *ngIf=\"ViewData.isGroup(data)\"\n [ngTemplateOutlet]=\"groupTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: data }\">\n </ng-template>\n <ng-template *ngIf=\"ViewData.isCommand(data)\"\n [ngTemplateOutlet]=\"commandTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: data }\">\n </ng-template>\n\n <mat-divider *ngIf=\"ViewData.isSeparator(data)\" [vertical]=\"true\"></mat-divider>\n </ng-container>\n\n</ng-container>\n",
|
|
771
|
+
styles: [":host{display:inline-flex;flex-direction:row;align-items:center}:host:not(.render-root) mat-divider{-ms-grid-row-align:stretch;align-self:stretch;margin:4px 0}:host:not(.render-root)>*+*{margin-left:8px}:host span.flex{flex:1}"]
|
|
772
|
+
}),
|
|
773
|
+
__metadata("design:paramtypes", [])
|
|
774
|
+
], CommandGroupRendererComponent);
|
|
775
|
+
return CommandGroupRendererComponent;
|
|
776
|
+
}(DisposableComponent));
|
|
777
|
+
|
|
778
|
+
var Registration = /** @class */ (function (_super) {
|
|
779
|
+
__extends(Registration, _super);
|
|
780
|
+
function Registration() {
|
|
781
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
782
|
+
}
|
|
783
|
+
return Registration;
|
|
784
|
+
}(GarbageCollector));
|
|
785
|
+
(function (Registration) {
|
|
786
|
+
var FaceRegistration = /** @class */ (function (_super) {
|
|
787
|
+
__extends(FaceRegistration, _super);
|
|
788
|
+
function FaceRegistration(faceModel) {
|
|
789
|
+
var _this = _super.call(this) || this;
|
|
790
|
+
_this.faceModel = faceModel;
|
|
791
|
+
return _this;
|
|
792
|
+
}
|
|
793
|
+
return FaceRegistration;
|
|
794
|
+
}(Registration));
|
|
795
|
+
Registration.FaceRegistration = FaceRegistration;
|
|
796
|
+
var CommandRegistration = /** @class */ (function (_super) {
|
|
797
|
+
__extends(CommandRegistration, _super);
|
|
798
|
+
function CommandRegistration(faceModel, command) {
|
|
799
|
+
var _this = _super.call(this, faceModel) || this;
|
|
800
|
+
_this.command = command;
|
|
801
|
+
return _this;
|
|
802
|
+
}
|
|
803
|
+
CommandRegistration.prototype.toTemplate = function () {
|
|
804
|
+
return new ViewData.CommandData(this.faceModel.value, this.command);
|
|
805
|
+
};
|
|
806
|
+
return CommandRegistration;
|
|
807
|
+
}(FaceRegistration));
|
|
808
|
+
Registration.CommandRegistration = CommandRegistration;
|
|
809
|
+
var GroupRegistration = /** @class */ (function (_super) {
|
|
810
|
+
__extends(GroupRegistration, _super);
|
|
811
|
+
function GroupRegistration(faceModel, group) {
|
|
812
|
+
var _this = _super.call(this, faceModel) || this;
|
|
813
|
+
_this.group = group;
|
|
814
|
+
return _this;
|
|
815
|
+
}
|
|
816
|
+
GroupRegistration.prototype.toTemplate = function () {
|
|
817
|
+
return new ViewData.GroupData(this.faceModel.value, this.group.xPosition, this.group.yPosition, this.group.registrations.value.map(function (r) { return r.toTemplate(); }));
|
|
818
|
+
};
|
|
819
|
+
return GroupRegistration;
|
|
820
|
+
}(FaceRegistration));
|
|
821
|
+
Registration.GroupRegistration = GroupRegistration;
|
|
822
|
+
var SeparatorRegistration = /** @class */ (function (_super) {
|
|
823
|
+
__extends(SeparatorRegistration, _super);
|
|
824
|
+
function SeparatorRegistration() {
|
|
825
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
826
|
+
_this.template = new ViewData.SeparatorData();
|
|
827
|
+
return _this;
|
|
828
|
+
}
|
|
829
|
+
SeparatorRegistration.prototype.toTemplate = function () {
|
|
830
|
+
return this.template;
|
|
831
|
+
};
|
|
832
|
+
return SeparatorRegistration;
|
|
833
|
+
}(Registration));
|
|
834
|
+
Registration.SeparatorRegistration = SeparatorRegistration;
|
|
835
|
+
var FlexRegistration = /** @class */ (function (_super) {
|
|
836
|
+
__extends(FlexRegistration, _super);
|
|
837
|
+
function FlexRegistration() {
|
|
838
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
839
|
+
_this.template = new ViewData.FlexData();
|
|
840
|
+
return _this;
|
|
841
|
+
}
|
|
842
|
+
FlexRegistration.prototype.toTemplate = function () {
|
|
843
|
+
return this.template;
|
|
844
|
+
};
|
|
845
|
+
return FlexRegistration;
|
|
846
|
+
}(Registration));
|
|
847
|
+
Registration.FlexRegistration = FlexRegistration;
|
|
848
|
+
function hasFace(entry) {
|
|
849
|
+
return entry instanceof CommandRegistration || entry instanceof GroupRegistration;
|
|
850
|
+
}
|
|
851
|
+
Registration.hasFace = hasFace;
|
|
852
|
+
})(Registration || (Registration = {}));
|
|
853
|
+
|
|
854
|
+
var CommandGroup = /** @class */ (function (_super) {
|
|
855
|
+
__extends(CommandGroup, _super);
|
|
856
|
+
function CommandGroup(parent) {
|
|
857
|
+
var _this = _super.call(this) || this;
|
|
858
|
+
_this.parent = parent;
|
|
859
|
+
_this._rootTemplate = new MutableValueModel();
|
|
860
|
+
_this._registrations = new MutableListModel();
|
|
861
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
862
|
+
_this.childTemplates = chain(_this._rootTemplate).pluckList('children');
|
|
863
|
+
_this.initialised = chain(_this._rootTemplate).isNotNil();
|
|
864
|
+
return _this;
|
|
865
|
+
}
|
|
866
|
+
CommandGroup.prototype.initialise = function () {
|
|
867
|
+
this.rebuildTemplates();
|
|
868
|
+
};
|
|
869
|
+
Object.defineProperty(CommandGroup.prototype, "rootTemplate", {
|
|
870
|
+
get: function () {
|
|
871
|
+
return this._rootTemplate.readonly;
|
|
872
|
+
},
|
|
873
|
+
enumerable: true,
|
|
874
|
+
configurable: true
|
|
875
|
+
});
|
|
876
|
+
Object.defineProperty(CommandGroup.prototype, "registrations", {
|
|
877
|
+
get: function () {
|
|
878
|
+
return this._registrations.readonly;
|
|
879
|
+
},
|
|
880
|
+
enumerable: true,
|
|
881
|
+
configurable: true
|
|
882
|
+
});
|
|
883
|
+
CommandGroup.prototype.notifyChanged = function () {
|
|
884
|
+
if (this.parent) {
|
|
885
|
+
this.parent.notifyChanged();
|
|
886
|
+
}
|
|
887
|
+
else {
|
|
888
|
+
this.rebuildTemplates();
|
|
889
|
+
}
|
|
890
|
+
};
|
|
891
|
+
CommandGroup.prototype.notifyChildFaceChanged = function (is, was) {
|
|
892
|
+
this.notifyChanged();
|
|
893
|
+
};
|
|
894
|
+
CommandGroup.prototype.rebuildTemplates = function () {
|
|
895
|
+
this._rootTemplate.value = new ViewData.GroupData(this.faceModel.value, this.xPosition, this.yPosition, this.registrations.value.map(function (r) { return r.toTemplate(); }));
|
|
896
|
+
};
|
|
897
|
+
Object.defineProperty(CommandGroup.prototype, "depth", {
|
|
898
|
+
get: function () {
|
|
899
|
+
return this.isRoot() ? 0 : this.parent.depth + 1;
|
|
900
|
+
},
|
|
901
|
+
enumerable: true,
|
|
902
|
+
configurable: true
|
|
903
|
+
});
|
|
904
|
+
CommandGroup.prototype.isRoot = function () {
|
|
905
|
+
return false;
|
|
906
|
+
};
|
|
907
|
+
CommandGroup.prototype.registerCommand = function (command, faceModel) {
|
|
908
|
+
return this.register(new Registration.CommandRegistration(faceModel, command));
|
|
909
|
+
};
|
|
910
|
+
CommandGroup.prototype.registerGroup = function (group, faceModel) {
|
|
911
|
+
return this.register(new Registration.GroupRegistration(faceModel, group));
|
|
912
|
+
};
|
|
913
|
+
CommandGroup.prototype.registerFlex = function (component) {
|
|
914
|
+
return this.register(new Registration.FlexRegistration());
|
|
915
|
+
};
|
|
916
|
+
CommandGroup.prototype.registerSeparator = function (component) {
|
|
917
|
+
return this.register(new Registration.SeparatorRegistration());
|
|
918
|
+
};
|
|
919
|
+
CommandGroup.prototype.register = function (registration) {
|
|
920
|
+
var _this = this;
|
|
921
|
+
this._registrations.push(registration);
|
|
922
|
+
if (registration instanceof Registration.FaceRegistration) {
|
|
923
|
+
var when = Dsl.disposeWith(registration).when;
|
|
924
|
+
when(registration.faceModel).changes(function (is, was) {
|
|
925
|
+
_this.notifyChildFaceChanged(is, was);
|
|
926
|
+
}, { asLongAs: this.initialised });
|
|
927
|
+
}
|
|
928
|
+
registration.onDispose(function () { return _this._registrations.remove(registration); });
|
|
929
|
+
return registration;
|
|
930
|
+
};
|
|
931
|
+
return CommandGroup;
|
|
932
|
+
}(GarbageCollector));
|
|
933
|
+
(function (CommandGroup) {
|
|
934
|
+
var Root = /** @class */ (function (_super) {
|
|
935
|
+
__extends(Root, _super);
|
|
936
|
+
function Root() {
|
|
937
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
938
|
+
}
|
|
939
|
+
Root.prototype.isRoot = function () {
|
|
940
|
+
return true;
|
|
941
|
+
};
|
|
942
|
+
__decorate([
|
|
943
|
+
TrackExternal(),
|
|
944
|
+
__metadata("design:type", ValueModel)
|
|
945
|
+
], Root.prototype, "faceModel", void 0);
|
|
946
|
+
__decorate([
|
|
947
|
+
TrackExternal({ defaultValue: 'after' }),
|
|
948
|
+
__metadata("design:type", ValueModel)
|
|
949
|
+
], Root.prototype, "xPositionModel", void 0);
|
|
950
|
+
__decorate([
|
|
951
|
+
StoreInValueModel('xPositionModel'),
|
|
952
|
+
__metadata("design:type", String)
|
|
953
|
+
], Root.prototype, "xPosition", void 0);
|
|
954
|
+
__decorate([
|
|
955
|
+
TrackExternal({ defaultValue: 'below' }),
|
|
956
|
+
__metadata("design:type", ValueModel)
|
|
957
|
+
], Root.prototype, "yPositionModel", void 0);
|
|
958
|
+
__decorate([
|
|
959
|
+
StoreInValueModel('yPositionModel'),
|
|
960
|
+
__metadata("design:type", String)
|
|
961
|
+
], Root.prototype, "yPosition", void 0);
|
|
962
|
+
return Root;
|
|
963
|
+
}(CommandGroup));
|
|
964
|
+
CommandGroup.Root = Root;
|
|
965
|
+
function factory() {
|
|
966
|
+
return new Root();
|
|
967
|
+
}
|
|
968
|
+
CommandGroup.factory = factory;
|
|
969
|
+
})(CommandGroup || (CommandGroup = {}));
|
|
970
|
+
|
|
971
|
+
var CommandGroupComponent = /** @class */ (function (_super) {
|
|
972
|
+
__extends(CommandGroupComponent, _super);
|
|
973
|
+
function CommandGroupComponent(parent) {
|
|
974
|
+
var _this = _super.call(this, parent) || this;
|
|
975
|
+
_this.parent = parent;
|
|
976
|
+
_this.xPosition = 'after';
|
|
977
|
+
_this.yPosition = 'below';
|
|
978
|
+
_this.parent.registerGroup(_this, _this.faceModel);
|
|
979
|
+
return _this;
|
|
980
|
+
}
|
|
981
|
+
CommandGroupComponent_1 = CommandGroupComponent;
|
|
982
|
+
var CommandGroupComponent_1;
|
|
983
|
+
CommandGroupComponent.ctorParameters = function () { return [
|
|
984
|
+
{ type: CommandGroup, decorators: [{ type: SkipSelf }] }
|
|
985
|
+
]; };
|
|
986
|
+
__decorate([
|
|
987
|
+
Input(), TrackExternal(),
|
|
988
|
+
__metadata("design:type", ValueModel)
|
|
989
|
+
], CommandGroupComponent.prototype, "faceModel", void 0);
|
|
990
|
+
__decorate([
|
|
991
|
+
Input(), StoreInValueModel('faceModel'),
|
|
992
|
+
__metadata("design:type", Object)
|
|
993
|
+
], CommandGroupComponent.prototype, "face", void 0);
|
|
994
|
+
__decorate([
|
|
995
|
+
Input(),
|
|
996
|
+
__metadata("design:type", String)
|
|
997
|
+
], CommandGroupComponent.prototype, "xPosition", void 0);
|
|
998
|
+
__decorate([
|
|
999
|
+
Input(),
|
|
1000
|
+
__metadata("design:type", String)
|
|
1001
|
+
], CommandGroupComponent.prototype, "yPosition", void 0);
|
|
1002
|
+
CommandGroupComponent = CommandGroupComponent_1 = __decorate([
|
|
1003
|
+
Component({
|
|
1004
|
+
selector: 'aup-command-group',
|
|
1005
|
+
template: '',
|
|
1006
|
+
providers: [
|
|
1007
|
+
{ provide: CommandGroup, useExisting: CommandGroupComponent_1 }
|
|
1008
|
+
]
|
|
1009
|
+
}),
|
|
1010
|
+
__param(0, SkipSelf()),
|
|
1011
|
+
__metadata("design:paramtypes", [CommandGroup])
|
|
1012
|
+
], CommandGroupComponent);
|
|
1013
|
+
return CommandGroupComponent;
|
|
1014
|
+
}(CommandGroup));
|
|
1015
|
+
|
|
1016
|
+
/**
|
|
1017
|
+
* Custom CSS:
|
|
1018
|
+
* @example
|
|
1019
|
+
* root: { // globally
|
|
1020
|
+
* --aup-command-face-icon-gap: 8px;
|
|
1021
|
+
* }
|
|
1022
|
+
* aup-command-face { // per instance
|
|
1023
|
+
* --icon-gap: 4px;
|
|
1024
|
+
* }
|
|
1025
|
+
*/
|
|
1026
|
+
var CommandFaceComponent = /** @class */ (function (_super) {
|
|
1027
|
+
__extends(CommandFaceComponent, _super);
|
|
1028
|
+
function CommandFaceComponent() {
|
|
1029
|
+
var _this = _super.call(this) || this;
|
|
1030
|
+
_this.faceModel = new MutableValueModel();
|
|
1031
|
+
_this.ignoreIcon = false;
|
|
1032
|
+
_this.ignoreText = false;
|
|
1033
|
+
_this.includeMissingIconInLayout = false;
|
|
1034
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
1035
|
+
// overkill /c: when all you have is a hammer...
|
|
1036
|
+
var faceAdapter = chain(_this.faceModel).map(function (face) { return new CommandFace.Adapter(face); });
|
|
1037
|
+
_this.iconModel = faceAdapter.pluck('icon');
|
|
1038
|
+
_this.textModel = faceAdapter.pluck('text');
|
|
1039
|
+
_this.positionModel = faceAdapter.pluck('iconPosition');
|
|
1040
|
+
_this.colorModel = faceAdapter.pluck('color');
|
|
1041
|
+
return _this;
|
|
1042
|
+
}
|
|
1043
|
+
Object.defineProperty(CommandFaceComponent.prototype, "requiresMissingIconInLayout", {
|
|
1044
|
+
get: function () {
|
|
1045
|
+
return this.includeMissingIconInLayout && !this.iconModel.value;
|
|
1046
|
+
},
|
|
1047
|
+
enumerable: true,
|
|
1048
|
+
configurable: true
|
|
1049
|
+
});
|
|
1050
|
+
CommandFaceComponent.prototype.ngOnInit = function () {
|
|
1051
|
+
};
|
|
1052
|
+
Object.defineProperty(CommandFaceComponent.prototype, "iconPosition", {
|
|
1053
|
+
get: function () {
|
|
1054
|
+
var _a;
|
|
1055
|
+
return (_a = this.positionModel.value) !== null && _a !== void 0 ? _a : CommandFace.Position.START;
|
|
1056
|
+
},
|
|
1057
|
+
enumerable: true,
|
|
1058
|
+
configurable: true
|
|
1059
|
+
});
|
|
1060
|
+
Object.defineProperty(CommandFaceComponent.prototype, "shouldIncludeIcon", {
|
|
1061
|
+
get: function () {
|
|
1062
|
+
return (!this.ignoreIcon && this.iconModel.value) || this.includeMissingIconInLayout;
|
|
1063
|
+
},
|
|
1064
|
+
enumerable: true,
|
|
1065
|
+
configurable: true
|
|
1066
|
+
});
|
|
1067
|
+
Object.defineProperty(CommandFaceComponent.prototype, "iconStart", {
|
|
1068
|
+
get: function () {
|
|
1069
|
+
return this.shouldIncludeIcon && this.iconPosition === CommandFace.Position.START;
|
|
1070
|
+
},
|
|
1071
|
+
enumerable: true,
|
|
1072
|
+
configurable: true
|
|
1073
|
+
});
|
|
1074
|
+
Object.defineProperty(CommandFaceComponent.prototype, "iconEnd", {
|
|
1075
|
+
get: function () {
|
|
1076
|
+
return this.shouldIncludeIcon && this.iconPosition === CommandFace.Position.END;
|
|
1077
|
+
},
|
|
1078
|
+
enumerable: true,
|
|
1079
|
+
configurable: true
|
|
1080
|
+
});
|
|
1081
|
+
Object.defineProperty(CommandFaceComponent.prototype, "text", {
|
|
1082
|
+
get: function () {
|
|
1083
|
+
return this.ignoreText ? undefined : this.textModel.value;
|
|
1084
|
+
},
|
|
1085
|
+
enumerable: true,
|
|
1086
|
+
configurable: true
|
|
1087
|
+
});
|
|
1088
|
+
Object.defineProperty(CommandFaceComponent.prototype, "color", {
|
|
1089
|
+
get: function () {
|
|
1090
|
+
return this.colorModel.value;
|
|
1091
|
+
},
|
|
1092
|
+
enumerable: true,
|
|
1093
|
+
configurable: true
|
|
1094
|
+
});
|
|
1095
|
+
__decorate([
|
|
1096
|
+
Input('face'), StoreInValueModel('faceModel'),
|
|
1097
|
+
__metadata("design:type", Object)
|
|
1098
|
+
], CommandFaceComponent.prototype, "_rawFace", void 0);
|
|
1099
|
+
__decorate([
|
|
1100
|
+
Input(),
|
|
1101
|
+
__metadata("design:type", Object)
|
|
1102
|
+
], CommandFaceComponent.prototype, "ignoreIcon", void 0);
|
|
1103
|
+
__decorate([
|
|
1104
|
+
Input(),
|
|
1105
|
+
__metadata("design:type", Object)
|
|
1106
|
+
], CommandFaceComponent.prototype, "ignoreText", void 0);
|
|
1107
|
+
__decorate([
|
|
1108
|
+
Input(),
|
|
1109
|
+
__metadata("design:type", Object)
|
|
1110
|
+
], CommandFaceComponent.prototype, "includeMissingIconInLayout", void 0);
|
|
1111
|
+
__decorate([
|
|
1112
|
+
HostBinding('class.hide-icon'),
|
|
1113
|
+
__metadata("design:type", Object),
|
|
1114
|
+
__metadata("design:paramtypes", [])
|
|
1115
|
+
], CommandFaceComponent.prototype, "requiresMissingIconInLayout", null);
|
|
1116
|
+
__decorate([
|
|
1117
|
+
HostBinding('attr.color'),
|
|
1118
|
+
__metadata("design:type", String),
|
|
1119
|
+
__metadata("design:paramtypes", [])
|
|
1120
|
+
], CommandFaceComponent.prototype, "color", null);
|
|
1121
|
+
CommandFaceComponent = __decorate([
|
|
1122
|
+
Component({
|
|
1123
|
+
selector: 'aup-command-face',
|
|
1124
|
+
template: "<aup-icon *ngIf=\"iconStart\" [icon]=\"iconModel.value\"></aup-icon>\n<span *ngIf=\"this.text\">{{this.text}}</span>\n<aup-icon *ngIf=\"iconEnd\" [icon]=\"iconModel.value\"></aup-icon>\n",
|
|
1125
|
+
encapsulation: ViewEncapsulation.None,
|
|
1126
|
+
styles: ["aup-command-face{--icon-gap:var(--aup-command-face-icon-gap);display:inline-flex;flex-direction:row;align-items:center}aup-command-face *+*{margin-left:var(--icon-gap)}aup-command-face.hide-icon aup-icon{visibility:hidden}"]
|
|
1127
|
+
}),
|
|
1128
|
+
__metadata("design:paramtypes", [])
|
|
1129
|
+
], CommandFaceComponent);
|
|
1130
|
+
return CommandFaceComponent;
|
|
1131
|
+
}(DisposableComponent));
|
|
1132
|
+
|
|
1133
|
+
/**
|
|
1134
|
+
*
|
|
1135
|
+
*/
|
|
1136
|
+
var CommandComponent = /** @class */ (function (_super) {
|
|
1137
|
+
__extends(CommandComponent, _super);
|
|
1138
|
+
function CommandComponent(parent) {
|
|
1139
|
+
var _this = _super.call(this) || this;
|
|
1140
|
+
_this.parent = parent;
|
|
1141
|
+
_this.CommandFace = CommandFace;
|
|
1142
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, switchOn = _a.switchOn;
|
|
1143
|
+
_this.activeFaceModel = switchOn(_this.command.busy).toValue(function (when) {
|
|
1144
|
+
when.equalTo(true, _this.busyFaceModel);
|
|
1145
|
+
when.otherwise(_this.faceModel);
|
|
1146
|
+
}).otherwise(_this.faceModel);
|
|
1147
|
+
_this.buttonStyle = chain(_this.activeFaceModel).map(function (f) { return CommandFace.getStyleOf(f); });
|
|
1148
|
+
_this.colorModel = chain(_this.activeFaceModel).map(function (f) { return CommandFace.getColorOf(f); });
|
|
1149
|
+
if (parent) {
|
|
1150
|
+
_this.registerDisposable(_this.parent.registerCommand(_this.command, _this.activeFaceModel));
|
|
1151
|
+
}
|
|
1152
|
+
return _this;
|
|
1153
|
+
}
|
|
1154
|
+
CommandComponent.prototype.ngOnInit = function () {
|
|
1155
|
+
};
|
|
1156
|
+
CommandComponent.ctorParameters = function () { return [
|
|
1157
|
+
{ type: CommandGroup, decorators: [{ type: Optional }] }
|
|
1158
|
+
]; };
|
|
1159
|
+
__decorate([
|
|
1160
|
+
Input(), TrackExternal(),
|
|
1161
|
+
__metadata("design:type", Command)
|
|
1162
|
+
], CommandComponent.prototype, "command", void 0);
|
|
1163
|
+
__decorate([
|
|
1164
|
+
Input(), TrackExternal(),
|
|
1165
|
+
__metadata("design:type", ValueModel)
|
|
1166
|
+
], CommandComponent.prototype, "faceModel", void 0);
|
|
1167
|
+
__decorate([
|
|
1168
|
+
Input(), StoreInValueModel('faceModel'),
|
|
1169
|
+
__metadata("design:type", Object)
|
|
1170
|
+
], CommandComponent.prototype, "face", void 0);
|
|
1171
|
+
__decorate([
|
|
1172
|
+
Input(), TrackExternal(),
|
|
1173
|
+
__metadata("design:type", ValueModel)
|
|
1174
|
+
], CommandComponent.prototype, "busyFaceModel", void 0);
|
|
1175
|
+
__decorate([
|
|
1176
|
+
Input(), StoreInValueModel('busyFaceModel'),
|
|
1177
|
+
__metadata("design:type", Object)
|
|
1178
|
+
], CommandComponent.prototype, "busyFace", void 0);
|
|
1179
|
+
CommandComponent = __decorate([
|
|
1180
|
+
Component({
|
|
1181
|
+
selector: 'aup-command',
|
|
1182
|
+
template: "<ng-container *ngIf=\"!parent\">\n <ng-container [ngSwitch]=\"buttonStyle.value\">\n <button *ngSwitchCase=\"CommandFace.Style.STROKED\" mat-stroked-button [pectinCommand]=\"command\" [color]=\"colorModel.value\">\n <aup-command-face [face]=\"activeFaceModel.value\"></aup-command-face>\n </button>\n <button *ngSwitchCase=\"CommandFace.Style.RAISED\" mat-raised-button [pectinCommand]=\"command\" [color]=\"colorModel.value\">\n <aup-command-face [face]=\"activeFaceModel.value\"></aup-command-face>\n </button>\n <button *ngSwitchDefault mat-button [pectinCommand]=\"command\" [color]=\"colorModel.value\">\n <aup-command-face [face]=\"activeFaceModel.value\"></aup-command-face>\n </button>\n </ng-container>\n</ng-container>\n"
|
|
1183
|
+
}),
|
|
1184
|
+
__param(0, Optional()),
|
|
1185
|
+
__metadata("design:paramtypes", [CommandGroup])
|
|
1186
|
+
], CommandComponent);
|
|
1187
|
+
return CommandComponent;
|
|
1188
|
+
}(DisposableComponent));
|
|
1189
|
+
|
|
1190
|
+
/**
|
|
1191
|
+
*
|
|
1192
|
+
*/
|
|
1193
|
+
var FlexComponent = /** @class */ (function (_super) {
|
|
1194
|
+
__extends(FlexComponent, _super);
|
|
1195
|
+
function FlexComponent(parent) {
|
|
1196
|
+
var _this = _super.call(this) || this;
|
|
1197
|
+
_this.parent = parent;
|
|
1198
|
+
if (parent) {
|
|
1199
|
+
parent.registerFlex(_this);
|
|
1200
|
+
}
|
|
1201
|
+
return _this;
|
|
1202
|
+
}
|
|
1203
|
+
FlexComponent.prototype.ngOnInit = function () {
|
|
1204
|
+
};
|
|
1205
|
+
FlexComponent.ctorParameters = function () { return [
|
|
1206
|
+
{ type: CommandGroup }
|
|
1207
|
+
]; };
|
|
1208
|
+
FlexComponent = __decorate([
|
|
1209
|
+
Component({
|
|
1210
|
+
selector: 'aup-flex',
|
|
1211
|
+
template: ""
|
|
1212
|
+
}),
|
|
1213
|
+
__metadata("design:paramtypes", [CommandGroup])
|
|
1214
|
+
], FlexComponent);
|
|
1215
|
+
return FlexComponent;
|
|
1216
|
+
}(DisposableComponent));
|
|
1217
|
+
|
|
1218
|
+
var ɵ0 = CommandGroup.factory;
|
|
1219
|
+
/**
|
|
1220
|
+
*
|
|
1221
|
+
*/
|
|
1222
|
+
var MoreMenuComponent = /** @class */ (function (_super) {
|
|
1223
|
+
__extends(MoreMenuComponent, _super);
|
|
1224
|
+
function MoreMenuComponent(group) {
|
|
1225
|
+
var _this = _super.call(this) || this;
|
|
1226
|
+
_this.group = group;
|
|
1227
|
+
_this.tooltipModel = new MutableValueModel();
|
|
1228
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
1229
|
+
group.xPosition = 'before'; // this should be the default unless overridden by the user.
|
|
1230
|
+
group.faceModel = chain(_this.tooltipModel).map(function (tooltip) {
|
|
1231
|
+
return {
|
|
1232
|
+
icon: function () { return 'mat:more_vert'; },
|
|
1233
|
+
tooltip: function () {
|
|
1234
|
+
return tooltip;
|
|
1235
|
+
}
|
|
1236
|
+
};
|
|
1237
|
+
}, { allowNil: true });
|
|
1238
|
+
return _this;
|
|
1239
|
+
}
|
|
1240
|
+
MoreMenuComponent.prototype.ngOnInit = function () {
|
|
1241
|
+
};
|
|
1242
|
+
MoreMenuComponent.prototype.ngAfterContentInit = function () {
|
|
1243
|
+
this.group.initialise();
|
|
1244
|
+
};
|
|
1245
|
+
MoreMenuComponent.ctorParameters = function () { return [
|
|
1246
|
+
{ type: CommandGroup }
|
|
1247
|
+
]; };
|
|
1248
|
+
__decorate([
|
|
1249
|
+
Input(), StoreInValueModel('tooltipModel'),
|
|
1250
|
+
__metadata("design:type", String)
|
|
1251
|
+
], MoreMenuComponent.prototype, "tooltip", void 0);
|
|
1252
|
+
__decorate([
|
|
1253
|
+
Trace(),
|
|
1254
|
+
__metadata("design:type", Function),
|
|
1255
|
+
__metadata("design:paramtypes", []),
|
|
1256
|
+
__metadata("design:returntype", void 0)
|
|
1257
|
+
], MoreMenuComponent.prototype, "ngAfterContentInit", null);
|
|
1258
|
+
MoreMenuComponent = __decorate([
|
|
1259
|
+
Component({
|
|
1260
|
+
selector: 'aup-more-menu',
|
|
1261
|
+
template: '<aup-command-group-renderer [renderRootNode]="true" [groupViewDataModel]="group.rootTemplate"></aup-command-group-renderer>',
|
|
1262
|
+
providers: [{ provide: CommandGroup, useFactory: ɵ0 }]
|
|
1263
|
+
}),
|
|
1264
|
+
__metadata("design:paramtypes", [CommandGroup])
|
|
1265
|
+
], MoreMenuComponent);
|
|
1266
|
+
return MoreMenuComponent;
|
|
1267
|
+
}(DisposableComponent));
|
|
1268
|
+
|
|
1269
|
+
var ɵ0$1 = CommandGroup.factory;
|
|
1270
|
+
/**
|
|
1271
|
+
*
|
|
1272
|
+
*/
|
|
1273
|
+
var PopupMenuComponent = /** @class */ (function (_super) {
|
|
1274
|
+
__extends(PopupMenuComponent, _super);
|
|
1275
|
+
function PopupMenuComponent(group) {
|
|
1276
|
+
var _this = _super.call(this) || this;
|
|
1277
|
+
_this.group = group;
|
|
1278
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
1279
|
+
group.faceModel = _this.faceModel;
|
|
1280
|
+
return _this;
|
|
1281
|
+
}
|
|
1282
|
+
PopupMenuComponent.prototype.ngOnInit = function () {
|
|
1283
|
+
};
|
|
1284
|
+
PopupMenuComponent.prototype.ngAfterContentInit = function () {
|
|
1285
|
+
this.group.initialise();
|
|
1286
|
+
};
|
|
1287
|
+
PopupMenuComponent.prototype.ngAfterViewInit = function () {
|
|
1288
|
+
};
|
|
1289
|
+
PopupMenuComponent.ctorParameters = function () { return [
|
|
1290
|
+
{ type: CommandGroup }
|
|
1291
|
+
]; };
|
|
1292
|
+
__decorate([
|
|
1293
|
+
Input(), TrackExternal(),
|
|
1294
|
+
__metadata("design:type", ValueModel)
|
|
1295
|
+
], PopupMenuComponent.prototype, "faceModel", void 0);
|
|
1296
|
+
__decorate([
|
|
1297
|
+
Input(), StoreInValueModel('faceModel'),
|
|
1298
|
+
__metadata("design:type", Object)
|
|
1299
|
+
], PopupMenuComponent.prototype, "face", void 0);
|
|
1300
|
+
__decorate([
|
|
1301
|
+
Trace(),
|
|
1302
|
+
__metadata("design:type", Function),
|
|
1303
|
+
__metadata("design:paramtypes", []),
|
|
1304
|
+
__metadata("design:returntype", void 0)
|
|
1305
|
+
], PopupMenuComponent.prototype, "ngOnInit", null);
|
|
1306
|
+
__decorate([
|
|
1307
|
+
Trace(),
|
|
1308
|
+
__metadata("design:type", Function),
|
|
1309
|
+
__metadata("design:paramtypes", []),
|
|
1310
|
+
__metadata("design:returntype", void 0)
|
|
1311
|
+
], PopupMenuComponent.prototype, "ngAfterContentInit", null);
|
|
1312
|
+
__decorate([
|
|
1313
|
+
Trace(),
|
|
1314
|
+
__metadata("design:type", Function),
|
|
1315
|
+
__metadata("design:paramtypes", []),
|
|
1316
|
+
__metadata("design:returntype", void 0)
|
|
1317
|
+
], PopupMenuComponent.prototype, "ngAfterViewInit", null);
|
|
1318
|
+
PopupMenuComponent = __decorate([
|
|
1319
|
+
Component({
|
|
1320
|
+
selector: 'aup-popup-menu',
|
|
1321
|
+
template: '<aup-command-group-renderer [renderRootNode]="true" [groupViewDataModel]="group.rootTemplate"></aup-command-group-renderer>',
|
|
1322
|
+
providers: [{ provide: CommandGroup, useFactory: ɵ0$1 }]
|
|
1323
|
+
}),
|
|
1324
|
+
__metadata("design:paramtypes", [CommandGroup])
|
|
1325
|
+
], PopupMenuComponent);
|
|
1326
|
+
return PopupMenuComponent;
|
|
1327
|
+
}(DisposableComponent));
|
|
1328
|
+
|
|
1329
|
+
/**
|
|
1330
|
+
*
|
|
1331
|
+
*/
|
|
1332
|
+
var SeparatorComponent = /** @class */ (function (_super) {
|
|
1333
|
+
__extends(SeparatorComponent, _super);
|
|
1334
|
+
function SeparatorComponent(parent) {
|
|
1335
|
+
var _this = _super.call(this) || this;
|
|
1336
|
+
_this.parent = parent;
|
|
1337
|
+
if (parent) {
|
|
1338
|
+
parent.registerSeparator(_this);
|
|
1339
|
+
}
|
|
1340
|
+
return _this;
|
|
1341
|
+
}
|
|
1342
|
+
SeparatorComponent.prototype.isVertical = function () {
|
|
1343
|
+
return this === null || this === void 0 ? void 0 : this.parent.isRoot();
|
|
1344
|
+
};
|
|
1345
|
+
SeparatorComponent.prototype.ngOnInit = function () {
|
|
1346
|
+
};
|
|
1347
|
+
SeparatorComponent.ctorParameters = function () { return [
|
|
1348
|
+
{ type: CommandGroup, decorators: [{ type: Optional }] }
|
|
1349
|
+
]; };
|
|
1350
|
+
SeparatorComponent = __decorate([
|
|
1351
|
+
Component({
|
|
1352
|
+
selector: 'aup-separator',
|
|
1353
|
+
template: "\n <mat-divider [vertical]=\"isVertical()\"></mat-divider>"
|
|
1354
|
+
}),
|
|
1355
|
+
__param(0, Optional()),
|
|
1356
|
+
__metadata("design:paramtypes", [CommandGroup])
|
|
1357
|
+
], SeparatorComponent);
|
|
1358
|
+
return SeparatorComponent;
|
|
1359
|
+
}(DisposableComponent));
|
|
1360
|
+
|
|
1361
|
+
var ɵ0$2 = CommandGroup.factory;
|
|
1362
|
+
/**
|
|
1363
|
+
*
|
|
1364
|
+
*/
|
|
1365
|
+
var ToolBarComponent = /** @class */ (function (_super) {
|
|
1366
|
+
__extends(ToolBarComponent, _super);
|
|
1367
|
+
function ToolBarComponent(group) {
|
|
1368
|
+
var _this = _super.call(this) || this;
|
|
1369
|
+
_this.group = group;
|
|
1370
|
+
return _this;
|
|
1371
|
+
}
|
|
1372
|
+
ToolBarComponent.prototype.ngOnInit = function () {
|
|
1373
|
+
};
|
|
1374
|
+
ToolBarComponent.prototype.ngAfterContentInit = function () {
|
|
1375
|
+
this.group.initialise();
|
|
1376
|
+
};
|
|
1377
|
+
ToolBarComponent.prototype.ngAfterViewInit = function () {
|
|
1378
|
+
};
|
|
1379
|
+
ToolBarComponent.ctorParameters = function () { return [
|
|
1380
|
+
{ type: CommandGroup }
|
|
1381
|
+
]; };
|
|
1382
|
+
__decorate([
|
|
1383
|
+
Trace(),
|
|
1384
|
+
__metadata("design:type", Function),
|
|
1385
|
+
__metadata("design:paramtypes", []),
|
|
1386
|
+
__metadata("design:returntype", void 0)
|
|
1387
|
+
], ToolBarComponent.prototype, "ngOnInit", null);
|
|
1388
|
+
__decorate([
|
|
1389
|
+
Trace(),
|
|
1390
|
+
__metadata("design:type", Function),
|
|
1391
|
+
__metadata("design:paramtypes", []),
|
|
1392
|
+
__metadata("design:returntype", void 0)
|
|
1393
|
+
], ToolBarComponent.prototype, "ngAfterContentInit", null);
|
|
1394
|
+
__decorate([
|
|
1395
|
+
Trace(),
|
|
1396
|
+
__metadata("design:type", Function),
|
|
1397
|
+
__metadata("design:paramtypes", []),
|
|
1398
|
+
__metadata("design:returntype", void 0)
|
|
1399
|
+
], ToolBarComponent.prototype, "ngAfterViewInit", null);
|
|
1400
|
+
ToolBarComponent = __decorate([
|
|
1401
|
+
Component({
|
|
1402
|
+
selector: 'aup-tool-bar',
|
|
1403
|
+
template: '<aup-command-group-renderer [renderRootNode]="false" [groupViewDataModel]="group.rootTemplate"></aup-command-group-renderer>',
|
|
1404
|
+
providers: [{ provide: CommandGroup, useFactory: ɵ0$2 }],
|
|
1405
|
+
styles: [":host{display:inline-flex;flex-direction:row;align-items:center}:host mat-divider{-ms-grid-row-align:stretch;align-self:stretch;margin:4px 0}:host span.flex{flex:1}:host>*+*{margin-left:8px}"]
|
|
1406
|
+
}),
|
|
1407
|
+
__metadata("design:paramtypes", [CommandGroup])
|
|
1408
|
+
], ToolBarComponent);
|
|
1409
|
+
return ToolBarComponent;
|
|
1410
|
+
}(DisposableComponent));
|
|
1411
|
+
|
|
417
1412
|
var FocusContainerComponent = /** @class */ (function (_super) {
|
|
418
1413
|
__extends(FocusContainerComponent, _super);
|
|
419
1414
|
function FocusContainerComponent(focusManager) {
|
|
@@ -522,6 +1517,7 @@ var AbstractInputComponent = /** @class */ (function (_super) {
|
|
|
522
1517
|
__extends(AbstractInputComponent, _super);
|
|
523
1518
|
function AbstractInputComponent() {
|
|
524
1519
|
var _this = _super.call(this) || this;
|
|
1520
|
+
_this.onValueEditedListeners = new EventListenerList();
|
|
525
1521
|
_this.dense = false;
|
|
526
1522
|
// TODO: fix this.
|
|
527
1523
|
// tslint:disable-next-line:no-output-native
|
|
@@ -572,7 +1568,7 @@ var AbstractInputComponent = /** @class */ (function (_super) {
|
|
|
572
1568
|
};
|
|
573
1569
|
Object.defineProperty(AbstractInputComponent.prototype, "enabled", {
|
|
574
1570
|
get: function () {
|
|
575
|
-
return this.
|
|
1571
|
+
return this.formValueModel.enabled;
|
|
576
1572
|
},
|
|
577
1573
|
enumerable: true,
|
|
578
1574
|
configurable: true
|
|
@@ -582,7 +1578,7 @@ var AbstractInputComponent = /** @class */ (function (_super) {
|
|
|
582
1578
|
};
|
|
583
1579
|
Object.defineProperty(AbstractInputComponent.prototype, "errorList", {
|
|
584
1580
|
get: function () {
|
|
585
|
-
return this.
|
|
1581
|
+
return this.formValueModel.errorList;
|
|
586
1582
|
},
|
|
587
1583
|
enumerable: true,
|
|
588
1584
|
configurable: true
|
|
@@ -596,7 +1592,7 @@ var AbstractInputComponent = /** @class */ (function (_super) {
|
|
|
596
1592
|
});
|
|
597
1593
|
Object.defineProperty(AbstractInputComponent.prototype, "focusContext", {
|
|
598
1594
|
get: function () {
|
|
599
|
-
return this.
|
|
1595
|
+
return this.formValueModel.focusContext;
|
|
600
1596
|
},
|
|
601
1597
|
enumerable: true,
|
|
602
1598
|
configurable: true
|
|
@@ -615,6 +1611,13 @@ var AbstractInputComponent = /** @class */ (function (_super) {
|
|
|
615
1611
|
enumerable: true,
|
|
616
1612
|
configurable: true
|
|
617
1613
|
});
|
|
1614
|
+
/**
|
|
1615
|
+
* Invokes the callback when this components value is changed by a user edit.
|
|
1616
|
+
* @param callback
|
|
1617
|
+
*/
|
|
1618
|
+
AbstractInputComponent.prototype.onValueEdited = function (callback) {
|
|
1619
|
+
return this.onValueEditedListeners.add(callback);
|
|
1620
|
+
};
|
|
618
1621
|
__decorate([
|
|
619
1622
|
Input(),
|
|
620
1623
|
__metadata("design:type", String)
|
|
@@ -716,34 +1719,47 @@ var AbstractListInputComponent = /** @class */ (function (_super) {
|
|
|
716
1719
|
* gets told it's an Object and can't scan for a base type annotated with @DelegateUsing(..).
|
|
717
1720
|
*/
|
|
718
1721
|
// We have to register it as a disposable so it ditches any listeners when we're disposed.
|
|
719
|
-
_this.
|
|
720
|
-
_this.
|
|
1722
|
+
_this.formValueModel = _this.registerDisposable(new Form.DelegatingListModel());
|
|
1723
|
+
_this.componentListModel = new MutableListModel();
|
|
1724
|
+
_this.setValueIsInProgress = new Guard();
|
|
721
1725
|
_this.valueChange = new EventEmitter();
|
|
722
|
-
var
|
|
723
|
-
|
|
1726
|
+
var _a = Dsl.disposeWith(_this), when = _a.when, valueOf = _a.valueOf, chain = _a.chain;
|
|
1727
|
+
var binding = new Binding.Identity(_this.formValueModel, _this.componentListModel).writeRight();
|
|
1728
|
+
var inExternalChange = valueOf.any(_this.setValueIsInProgress, chain(binding.direction).equals(Binding.Direction.RIGHT)).areTruthy();
|
|
1729
|
+
when(_this.componentListModel).changes(function (is, was) {
|
|
1730
|
+
_this.valueChange.emit(is);
|
|
1731
|
+
_this.onValueEditedListeners.fire(function (l) { return l(is, was); });
|
|
1732
|
+
}, {
|
|
724
1733
|
initialValue: 'ignore',
|
|
725
|
-
|
|
1734
|
+
// we never fire events during an external changes to the value. This allows
|
|
1735
|
+
// the component to behave when used in the conventional angular
|
|
1736
|
+
// fashion, i.e. [(value)]="..."
|
|
1737
|
+
unless: inExternalChange
|
|
726
1738
|
});
|
|
1739
|
+
DebugContext.tag(_this.formValueModel, _this.constructor.name + ".formValueModel");
|
|
727
1740
|
return _this;
|
|
728
1741
|
}
|
|
729
1742
|
Object.defineProperty(AbstractListInputComponent.prototype, "value", {
|
|
1743
|
+
// We add support for simple direct display of values by allowing components to be used
|
|
1744
|
+
// by `component.value = ...` This use of the component without a value model in tables
|
|
1745
|
+
// and the like.
|
|
730
1746
|
set: function (value) {
|
|
731
1747
|
var _this = this;
|
|
732
|
-
|
|
733
|
-
|
|
1748
|
+
this.setValueIsInProgress.whileTrue(function () {
|
|
1749
|
+
if (!_this.listHolder) {
|
|
734
1750
|
_this.listHolder = new MutableListModel(value);
|
|
735
1751
|
_this.listModel = _this.listHolder;
|
|
736
|
-
}
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
}
|
|
1752
|
+
}
|
|
1753
|
+
else {
|
|
1754
|
+
_this.listHolder.value = value;
|
|
1755
|
+
}
|
|
1756
|
+
});
|
|
741
1757
|
},
|
|
742
1758
|
enumerable: true,
|
|
743
1759
|
configurable: true
|
|
744
1760
|
});
|
|
745
1761
|
__decorate([
|
|
746
|
-
Input(), TrackExternal({ delegateTo: '
|
|
1762
|
+
Input(), TrackExternal({ delegateTo: 'formValueModel' }),
|
|
747
1763
|
__metadata("design:type", Object)
|
|
748
1764
|
], AbstractListInputComponent.prototype, "listModel", void 0);
|
|
749
1765
|
__decorate([
|
|
@@ -777,29 +1793,39 @@ var AbstractValueInputComponent = /** @class */ (function (_super) {
|
|
|
777
1793
|
* gets told it's an Object and can't scan for a base type annotated with @DelegateUsing(..).
|
|
778
1794
|
*/
|
|
779
1795
|
// We have to register it as a disposable so it ditches any listeners when we're disposed.
|
|
780
|
-
_this.
|
|
1796
|
+
_this.formValueModel = _this.registerDisposable(new Form.DelegatingValueModel());
|
|
781
1797
|
_this.setValueInProgress = new Guard();
|
|
1798
|
+
_this.componentValueModel = new MutableValueModel();
|
|
782
1799
|
_this.valueChange = new EventEmitter();
|
|
783
|
-
var
|
|
784
|
-
|
|
1800
|
+
var _a = Dsl.disposeWith(_this), when = _a.when, chain = _a.chain, valueOf = _a.valueOf;
|
|
1801
|
+
var binding = new Binding.Identity(_this.formValueModel, _this.componentValueModel).writeRight();
|
|
1802
|
+
var inExternalChange = valueOf.any(_this.setValueInProgress, chain(binding.direction).equals(Binding.Direction.RIGHT)).areTruthy();
|
|
1803
|
+
when(_this.componentValueModel).changes(function (is, was) {
|
|
1804
|
+
_this.valueChange.emit(is);
|
|
1805
|
+
_this.onValueEditedListeners.fire(function (l) { return l(is, was); });
|
|
1806
|
+
}, {
|
|
785
1807
|
initialValue: 'ignore',
|
|
786
|
-
|
|
1808
|
+
// we never fire events during an external set value operation. This allows
|
|
1809
|
+
// the component to behave when used in the conventional angular
|
|
1810
|
+
// fashion, i.e. [(value)]="..."
|
|
1811
|
+
unless: inExternalChange
|
|
787
1812
|
});
|
|
1813
|
+
DebugContext.tag(_this.formValueModel, _this.constructor.name + ".formValueModel");
|
|
788
1814
|
return _this;
|
|
789
1815
|
}
|
|
790
1816
|
Object.defineProperty(AbstractValueInputComponent.prototype, "value", {
|
|
1817
|
+
// We add support for simple direct display of values by allowing components to be used
|
|
1818
|
+
// by `component.value = ...` This use of the component without a value model in tables
|
|
1819
|
+
// and the like.
|
|
791
1820
|
set: function (value) {
|
|
792
1821
|
var _this = this;
|
|
793
|
-
// we never fire events during an external set value operation. This allows
|
|
794
|
-
// the component to behave when used in the conventional angular
|
|
795
|
-
// fashion, i.e. [(value)]="..."
|
|
796
1822
|
this.setValueInProgress.whileTrue(function () {
|
|
797
|
-
if (!_this.
|
|
798
|
-
_this.
|
|
799
|
-
_this.valueModel = _this.
|
|
1823
|
+
if (!_this.plainValueHolder) {
|
|
1824
|
+
_this.plainValueHolder = new MutableValueModel(value);
|
|
1825
|
+
_this.valueModel = _this.plainValueHolder;
|
|
800
1826
|
}
|
|
801
1827
|
else {
|
|
802
|
-
_this.
|
|
1828
|
+
_this.plainValueHolder.value = value;
|
|
803
1829
|
}
|
|
804
1830
|
});
|
|
805
1831
|
},
|
|
@@ -807,7 +1833,7 @@ var AbstractValueInputComponent = /** @class */ (function (_super) {
|
|
|
807
1833
|
configurable: true
|
|
808
1834
|
});
|
|
809
1835
|
__decorate([
|
|
810
|
-
Input(), TrackExternal({ delegateTo: '
|
|
1836
|
+
Input(), TrackExternal({ delegateTo: 'formValueModel' }),
|
|
811
1837
|
__metadata("design:type", Object)
|
|
812
1838
|
], AbstractValueInputComponent.prototype, "valueModel", void 0);
|
|
813
1839
|
__decorate([
|
|
@@ -849,9 +1875,15 @@ var AutocompleteInputComponent = /** @class */ (function (_super) {
|
|
|
849
1875
|
}
|
|
850
1876
|
AutocompleteInputComponent.prototype.ngOnInit = function () {
|
|
851
1877
|
};
|
|
1878
|
+
AutocompleteInputComponent.prototype.formatOption = function (option) {
|
|
1879
|
+
return this.optionLabelFormat(option);
|
|
1880
|
+
};
|
|
852
1881
|
AutocompleteInputComponent.prototype.updateFilter = function ($event) {
|
|
853
1882
|
this.filterValue.value = $event;
|
|
854
1883
|
};
|
|
1884
|
+
AutocompleteInputComponent.prototype.onSelect = function ($event) {
|
|
1885
|
+
this.valueModel.value = $event.option.value;
|
|
1886
|
+
};
|
|
855
1887
|
__decorate([
|
|
856
1888
|
Input(), TrackExternal(),
|
|
857
1889
|
__metadata("design:type", ListModel)
|
|
@@ -879,7 +1911,7 @@ var AutocompleteInputComponent = /** @class */ (function (_super) {
|
|
|
879
1911
|
AutocompleteInputComponent = __decorate([
|
|
880
1912
|
Component({
|
|
881
1913
|
selector: 'aup-autocomplete-input',
|
|
882
|
-
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]=\"
|
|
1914
|
+
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",
|
|
883
1915
|
styles: [":host{display:inline-block}mat-form-field{width:100%}"]
|
|
884
1916
|
}),
|
|
885
1917
|
__metadata("design:paramtypes", [])
|
|
@@ -910,7 +1942,7 @@ var CheckboxInputComponent = /** @class */ (function (_super) {
|
|
|
910
1942
|
CheckboxInputComponent = __decorate([
|
|
911
1943
|
Component({
|
|
912
1944
|
selector: 'aup-checkbox-input',
|
|
913
|
-
template: "<!-- TODO: add focus binding -->\n<mat-checkbox\n [(ngModel)]=\"
|
|
1945
|
+
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",
|
|
914
1946
|
styles: [":host{display:inline-flex;flex-direction:column;padding:24px 0 16px}:host.dense{padding:6px 0 2px}mat-error,mat-hint{margin-top:4px;margin-left:24px;font-size:12px;font-weight:400;line-height:13.5px}"]
|
|
915
1947
|
}),
|
|
916
1948
|
__metadata("design:paramtypes", [])
|
|
@@ -922,7 +1954,7 @@ var CheckboxInputComponent = /** @class */ (function (_super) {
|
|
|
922
1954
|
* Using templates:
|
|
923
1955
|
* <aup-multiple-select-input [valueModel]="myModel" [options]="myOptions">
|
|
924
1956
|
* <ng-template #optionTemplate let-option>{{option.thePropertyYouWant}}</ng-template>
|
|
925
|
-
* <ng-template #
|
|
1957
|
+
* <ng-template #nilOptionTemplate let-option>{{option.thePropertyYouWant}}</ng-template>
|
|
926
1958
|
* </aup-multiple-select_input>
|
|
927
1959
|
*/
|
|
928
1960
|
var MultipleSelectInputComponent = /** @class */ (function (_super) {
|
|
@@ -946,18 +1978,10 @@ var MultipleSelectInputComponent = /** @class */ (function (_super) {
|
|
|
946
1978
|
Input(),
|
|
947
1979
|
__metadata("design:type", Object)
|
|
948
1980
|
], MultipleSelectInputComponent.prototype, "optionLabel", void 0);
|
|
949
|
-
__decorate([
|
|
950
|
-
Input(),
|
|
951
|
-
__metadata("design:type", Boolean)
|
|
952
|
-
], MultipleSelectInputComponent.prototype, "allowNil", void 0);
|
|
953
1981
|
__decorate([
|
|
954
1982
|
ContentChild('optionTemplate'),
|
|
955
1983
|
__metadata("design:type", TemplateRef)
|
|
956
1984
|
], MultipleSelectInputComponent.prototype, "optionTemplateRef", void 0);
|
|
957
|
-
__decorate([
|
|
958
|
-
ContentChild('nilOptionTemplate'),
|
|
959
|
-
__metadata("design:type", TemplateRef)
|
|
960
|
-
], MultipleSelectInputComponent.prototype, "nilOptionTemplateRef", void 0);
|
|
961
1985
|
__decorate([
|
|
962
1986
|
Input(),
|
|
963
1987
|
__metadata("design:type", Function)
|
|
@@ -965,7 +1989,7 @@ var MultipleSelectInputComponent = /** @class */ (function (_super) {
|
|
|
965
1989
|
MultipleSelectInputComponent = __decorate([
|
|
966
1990
|
Component({
|
|
967
1991
|
selector: 'aup-multiple-select-input',
|
|
968
|
-
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)]=\"
|
|
1992
|
+
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",
|
|
969
1993
|
styles: [":host{display:inline-block}mat-form-field{width:100%}"]
|
|
970
1994
|
}),
|
|
971
1995
|
__metadata("design:paramtypes", [])
|
|
@@ -996,7 +2020,7 @@ var NumberInputComponent = /** @class */ (function (_super) {
|
|
|
996
2020
|
NumberInputComponent = __decorate([
|
|
997
2021
|
Component({
|
|
998
2022
|
selector: 'aup-number-input',
|
|
999
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input type=\"number\"\n matInput\n placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"
|
|
2023
|
+
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input type=\"number\"\n 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 [min]=\"min\"\n [max]=\"max\"\n >\n <mat-hint *ngIf=\"hint && !dense\" >{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n",
|
|
1000
2024
|
styles: [""]
|
|
1001
2025
|
}),
|
|
1002
2026
|
__metadata("design:paramtypes", [])
|
|
@@ -1016,7 +2040,7 @@ var PasswordInputComponent = /** @class */ (function (_super) {
|
|
|
1016
2040
|
PasswordInputComponent = __decorate([
|
|
1017
2041
|
Component({
|
|
1018
2042
|
selector: 'aup-password-input',
|
|
1019
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input type=\"password\"\n matInput\n placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"
|
|
2043
|
+
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input type=\"password\"\n 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 >\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\n</mat-form-field>\n\n",
|
|
1020
2044
|
styles: [""]
|
|
1021
2045
|
}),
|
|
1022
2046
|
__metadata("design:paramtypes", [])
|
|
@@ -1028,7 +2052,7 @@ var PasswordInputComponent = /** @class */ (function (_super) {
|
|
|
1028
2052
|
* Using templates:
|
|
1029
2053
|
* <aup-select-input [valueModel]="myModel" [options]="myOptions">
|
|
1030
2054
|
* <ng-template #optionTemplate let-option>{{option.thePropertyYouWant}}</ng-template>
|
|
1031
|
-
* <ng-template #
|
|
2055
|
+
* <ng-template #nilOptionTemplate let-option>{{option.thePropertyYouWant}}</ng-template>
|
|
1032
2056
|
* </aup-select_input>
|
|
1033
2057
|
*/
|
|
1034
2058
|
var SelectInputComponent = /** @class */ (function (_super) {
|
|
@@ -1071,7 +2095,7 @@ var SelectInputComponent = /** @class */ (function (_super) {
|
|
|
1071
2095
|
SelectInputComponent = __decorate([
|
|
1072
2096
|
Component({
|
|
1073
2097
|
selector: 'aup-select-input',
|
|
1074
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <mat-select placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"
|
|
2098
|
+
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",
|
|
1075
2099
|
styles: [":host{display:inline-block}mat-form-field{width:100%}"]
|
|
1076
2100
|
}),
|
|
1077
2101
|
__metadata("design:paramtypes", [])
|
|
@@ -1085,9 +2109,9 @@ var StringInputComponent = /** @class */ (function (_super) {
|
|
|
1085
2109
|
var _this = _super.call(this) || this;
|
|
1086
2110
|
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
1087
2111
|
_this.clearCommand = Command.create(function () {
|
|
1088
|
-
_this.
|
|
2112
|
+
_this.componentValueModel.value = null;
|
|
1089
2113
|
});
|
|
1090
|
-
_this.clearCommand.disableWhile(chain.stringValue(_this.
|
|
2114
|
+
_this.clearCommand.disableWhile(chain.stringValue(_this.componentValueModel).isBlank());
|
|
1091
2115
|
return _this;
|
|
1092
2116
|
}
|
|
1093
2117
|
StringInputComponent.prototype.ngOnInit = function () {
|
|
@@ -1103,7 +2127,7 @@ var StringInputComponent = /** @class */ (function (_super) {
|
|
|
1103
2127
|
StringInputComponent = __decorate([
|
|
1104
2128
|
Component({
|
|
1105
2129
|
selector: 'aup-string-input',
|
|
1106
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input matInput\n placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"
|
|
2130
|
+
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <input 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 >\n <mat-hint *ngIf=\"showHint\">{{hint}}</mat-hint>\n <mat-error *ngIf=\"hasErrors\">{{firstError}}</mat-error>\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",
|
|
1107
2131
|
styles: ["button[disabled]{visibility:hidden}"]
|
|
1108
2132
|
}),
|
|
1109
2133
|
__metadata("design:paramtypes", [])
|
|
@@ -1134,7 +2158,7 @@ var TextInputComponent = /** @class */ (function (_super) {
|
|
|
1134
2158
|
TextInputComponent = __decorate([
|
|
1135
2159
|
Component({
|
|
1136
2160
|
selector: 'aup-text-input',
|
|
1137
|
-
template: "<mat-form-field appearance=\"standard\" [floatLabel]=\"floatLabel\">\n <mat-label *ngIf=\"label\">{{label}}</mat-label>\n <textarea matInput\n placeholder=\"{{placeholder}}\"\n [(ngModel)]=\"
|
|
2161
|
+
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",
|
|
1138
2162
|
styles: ["button[disabled]{visibility:hidden}textarea{overflow:auto}"]
|
|
1139
2163
|
}),
|
|
1140
2164
|
__metadata("design:paramtypes", [])
|
|
@@ -1144,7 +2168,10 @@ var TextInputComponent = /** @class */ (function (_super) {
|
|
|
1144
2168
|
|
|
1145
2169
|
var IconComponent = /** @class */ (function () {
|
|
1146
2170
|
function IconComponent() {
|
|
2171
|
+
this.allowedPrefixes = Enum.values(IconComponent_1.IconPrefix).map(function (p) { return p + ":"; });
|
|
2172
|
+
this.iconPrefix = IconComponent_1.IconPrefix;
|
|
1147
2173
|
}
|
|
2174
|
+
IconComponent_1 = IconComponent;
|
|
1148
2175
|
Object.defineProperty(IconComponent.prototype, "icon", {
|
|
1149
2176
|
get: function () {
|
|
1150
2177
|
return this._icon;
|
|
@@ -1164,25 +2191,33 @@ var IconComponent = /** @class */ (function () {
|
|
|
1164
2191
|
if (this.prefix) {
|
|
1165
2192
|
this.errorMessage = "Unknown icon \"" + iconName + "\"";
|
|
1166
2193
|
}
|
|
1167
|
-
this.errorMessage = "Unknown icon prefix \"" + this.prefix + "
|
|
2194
|
+
this.errorMessage = "Unknown icon prefix, expected one of [" + this.allowedPrefixes.join(',') + "] got \"" + this.prefix + ":\"";
|
|
1168
2195
|
},
|
|
1169
2196
|
enumerable: true,
|
|
1170
2197
|
configurable: true
|
|
1171
2198
|
});
|
|
2199
|
+
var IconComponent_1;
|
|
1172
2200
|
__decorate([
|
|
1173
2201
|
Input(),
|
|
1174
2202
|
__metadata("design:type", String),
|
|
1175
2203
|
__metadata("design:paramtypes", [String])
|
|
1176
2204
|
], IconComponent.prototype, "icon", null);
|
|
1177
|
-
IconComponent = __decorate([
|
|
2205
|
+
IconComponent = IconComponent_1 = __decorate([
|
|
1178
2206
|
Component({
|
|
1179
2207
|
selector: 'aup-icon',
|
|
1180
|
-
template: "<ng-container [ngSwitch]=\"prefix\">\n\n <mat-icon *ngSwitchCase=\"
|
|
2208
|
+
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",
|
|
1181
2209
|
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}"]
|
|
1182
2210
|
})
|
|
1183
2211
|
], IconComponent);
|
|
1184
2212
|
return IconComponent;
|
|
1185
2213
|
}());
|
|
2214
|
+
(function (IconComponent) {
|
|
2215
|
+
IconComponent.IconPrefix = Enum({
|
|
2216
|
+
SVG: 'svg',
|
|
2217
|
+
FONT_AWESOME: 'fa',
|
|
2218
|
+
MATERIAL: 'mat'
|
|
2219
|
+
});
|
|
2220
|
+
})(IconComponent || (IconComponent = {}));
|
|
1186
2221
|
|
|
1187
2222
|
var NoopComponent = /** @class */ (function () {
|
|
1188
2223
|
function NoopComponent() {
|
|
@@ -1659,7 +2694,8 @@ var SelectHeaderCellRendererComponent = /** @class */ (function (_super) {
|
|
|
1659
2694
|
|
|
1660
2695
|
var noop = function () {
|
|
1661
2696
|
};
|
|
1662
|
-
var ɵ0 = noop;
|
|
2697
|
+
var ɵ0$3 = noop;
|
|
2698
|
+
var CELL_RENDERER_COMPONENT_ROW_CACHE = Symbol("aup-cell-renderer:row-data-cache");
|
|
1663
2699
|
var ColumnModel = /** @class */ (function () {
|
|
1664
2700
|
function ColumnModel(columnId, defaults) {
|
|
1665
2701
|
this.columnId = columnId;
|
|
@@ -1777,6 +2813,35 @@ var PropertyColumnModel = /** @class */ (function (_super) {
|
|
|
1777
2813
|
}));
|
|
1778
2814
|
return this;
|
|
1779
2815
|
};
|
|
2816
|
+
PropertyColumnModel.prototype.mutableCellRenderer = function (componentType, options) {
|
|
2817
|
+
var _this = this;
|
|
2818
|
+
this.configureCellRenderer(new ComponentCellRendererPortalRef(componentType, function (component, rowData, firstTime) {
|
|
2819
|
+
// keep a local copy most recent row value so it's available to teh
|
|
2820
|
+
// edit callback without having to add/remove subscribers all the time.
|
|
2821
|
+
component[CELL_RENDERER_COMPONENT_ROW_CACHE] = rowData.row;
|
|
2822
|
+
var disableEditCallback = false;
|
|
2823
|
+
if (firstTime) {
|
|
2824
|
+
if (___default.isFunction(options === null || options === void 0 ? void 0 : options.onComponentInit)) {
|
|
2825
|
+
options.onComponentInit(component);
|
|
2826
|
+
}
|
|
2827
|
+
// install our edit callback
|
|
2828
|
+
component.onValueEdited(function (is, was) {
|
|
2829
|
+
if (!disableEditCallback) {
|
|
2830
|
+
options.onValueEdit(component[CELL_RENDERER_COMPONENT_ROW_CACHE], is, was);
|
|
2831
|
+
}
|
|
2832
|
+
});
|
|
2833
|
+
}
|
|
2834
|
+
// now push the value the component and disable the callback just incase the component misbehaves
|
|
2835
|
+
// and fires a value change during the operation.
|
|
2836
|
+
disableEditCallback = true;
|
|
2837
|
+
component.value = rowData.row[_this.property];
|
|
2838
|
+
disableEditCallback = false;
|
|
2839
|
+
if (!___default.isFunction(options) && ___default.isFunction(options === null || options === void 0 ? void 0 : options.onRowUpdate)) {
|
|
2840
|
+
options.onRowUpdate(component, rowData.row);
|
|
2841
|
+
}
|
|
2842
|
+
}));
|
|
2843
|
+
return this;
|
|
2844
|
+
};
|
|
1780
2845
|
PropertyColumnModel.prototype.cellEditor = function (editor, validatorsOrInitialiser, onComponentInit) {
|
|
1781
2846
|
var _this = this;
|
|
1782
2847
|
var validators = Array.isArray(validatorsOrInitialiser) ? validatorsOrInitialiser : undefined;
|
|
@@ -1853,10 +2918,23 @@ var CustomValueColumnModel = /** @class */ (function (_super) {
|
|
|
1853
2918
|
_this.cellRenderer(DefaultCellRendererComponent);
|
|
1854
2919
|
return _this;
|
|
1855
2920
|
}
|
|
1856
|
-
CustomValueColumnModel.prototype.cellRenderer = function (componentType) {
|
|
2921
|
+
CustomValueColumnModel.prototype.cellRenderer = function (componentType, onComponentInitOrOptions) {
|
|
1857
2922
|
var _this = this;
|
|
1858
|
-
this.configureCellRenderer(new ComponentCellRendererPortalRef(componentType, function (component, rowData) {
|
|
2923
|
+
this.configureCellRenderer(new ComponentCellRendererPortalRef(componentType, function (component, rowData, firstTime) {
|
|
2924
|
+
if (firstTime) {
|
|
2925
|
+
if (___default.isFunction(onComponentInitOrOptions)) {
|
|
2926
|
+
onComponentInitOrOptions(component);
|
|
2927
|
+
}
|
|
2928
|
+
else {
|
|
2929
|
+
if (___default.isFunction(onComponentInitOrOptions === null || onComponentInitOrOptions === void 0 ? void 0 : onComponentInitOrOptions.onComponentInit)) {
|
|
2930
|
+
onComponentInitOrOptions.onComponentInit(component);
|
|
2931
|
+
}
|
|
2932
|
+
}
|
|
2933
|
+
}
|
|
1859
2934
|
component.value = _this.getValue(rowData.row);
|
|
2935
|
+
if (!___default.isFunction(onComponentInitOrOptions) && ___default.isFunction(onComponentInitOrOptions === null || onComponentInitOrOptions === void 0 ? void 0 : onComponentInitOrOptions.onRowUpdate)) {
|
|
2936
|
+
onComponentInitOrOptions.onRowUpdate(component, rowData.row);
|
|
2937
|
+
}
|
|
1860
2938
|
}));
|
|
1861
2939
|
return this;
|
|
1862
2940
|
};
|
|
@@ -2029,6 +3107,9 @@ var TableModel = /** @class */ (function () {
|
|
|
2029
3107
|
this._editorSessions = new MutableListModel();
|
|
2030
3108
|
this.rowClassNamePredicates = [];
|
|
2031
3109
|
this._createForm = function (row) { return new DirtyTrackingForm(); };
|
|
3110
|
+
this.trackBy = function (index, item) {
|
|
3111
|
+
return _this.identityOf ? _this.identityOf(item) : index;
|
|
3112
|
+
};
|
|
2032
3113
|
this.identityOf = sourceOfTruth.identityOf;
|
|
2033
3114
|
var _a = Dsl.disposeWith(this._garbage), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
2034
3115
|
this._columnsById = chain(this._columns).indexBy('columnId');
|
|
@@ -2055,12 +3136,6 @@ var TableModel = /** @class */ (function () {
|
|
|
2055
3136
|
enumerable: true,
|
|
2056
3137
|
configurable: true
|
|
2057
3138
|
});
|
|
2058
|
-
TableModel.prototype.getTrackByFunction = function () {
|
|
2059
|
-
var _this = this;
|
|
2060
|
-
return function (index, item) {
|
|
2061
|
-
return _this.identityOf ? _this.identityOf(item) : index;
|
|
2062
|
-
};
|
|
2063
|
-
};
|
|
2064
3139
|
Object.defineProperty(TableModel.prototype, "columns", {
|
|
2065
3140
|
get: function () {
|
|
2066
3141
|
return this._columns.readonly;
|
|
@@ -2086,6 +3161,9 @@ var TableModel = /** @class */ (function () {
|
|
|
2086
3161
|
TableModel.prototype.addCustomColumn = function (columnId, dataAccessor) {
|
|
2087
3162
|
return this.addColumn(new CustomValueColumnModel(columnId, this, dataAccessor));
|
|
2088
3163
|
};
|
|
3164
|
+
TableModel.prototype.addComponentColumn = function (columnId, component, onComponentInitOrOptions) {
|
|
3165
|
+
return this.addColumn(new CustomValueColumnModel(columnId, this, function (row) { return row; })).cellRenderer(component, onComponentInitOrOptions);
|
|
3166
|
+
};
|
|
2089
3167
|
TableModel.prototype.addTemplateColumn = function (columnId) {
|
|
2090
3168
|
return this.addColumn(new CustomTemplateColumnModel(columnId, this));
|
|
2091
3169
|
};
|
|
@@ -2114,12 +3192,14 @@ var TableModel = /** @class */ (function () {
|
|
|
2114
3192
|
}
|
|
2115
3193
|
return column;
|
|
2116
3194
|
};
|
|
3195
|
+
// removeColumn(column: ColumnModel<Row>) {
|
|
3196
|
+
//
|
|
3197
|
+
// }
|
|
2117
3198
|
TableModel.prototype.columnTextProperties = function (columnTextProperties) {
|
|
2118
3199
|
this._columnTextPropertiesLookup = columnTextProperties;
|
|
2119
3200
|
};
|
|
2120
3201
|
TableModel.prototype.getColumnTextProperties = function (column) {
|
|
2121
|
-
|
|
2122
|
-
return factory ? factory() : undefined;
|
|
3202
|
+
return this._columnTextPropertiesLookup ? this._columnTextPropertiesLookup[column.columnId] : undefined;
|
|
2123
3203
|
};
|
|
2124
3204
|
TableModel.prototype.startEditSession = function (row) {
|
|
2125
3205
|
var _this = this;
|
|
@@ -2237,7 +3317,7 @@ var TableComponent = /** @class */ (function (_super) {
|
|
|
2237
3317
|
TableComponent = __decorate([
|
|
2238
3318
|
Component({
|
|
2239
3319
|
selector: 'aup-table',
|
|
2240
|
-
template: "<table mat-table [dataSource]=\"tableModel.dataSource.value\" [trackBy]=\"tableModel.
|
|
3320
|
+
template: "<table mat-table [dataSource]=\"tableModel.dataSource.value\" [trackBy]=\"tableModel.trackBy\">\n\n <ng-container *ngFor=\"let column of columns.value; index as index; first as first; last as last\" matColumnDef=\"{{column.columnId}}\">\n <th mat-header-cell *matHeaderCellDef>\n <aup-table-header-cell-renderer [column]=\"column\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef=\"let row\" (click)=\"onCellClicked(column, row)\" [class.enable-cursor]=\"tableModel.isRowSelectionEnabledFor(column)\">\n <aup-table-cell-renderer [column]=\"column\"\n [row]=\"row\"\n [tableModel]=\"tableModel\"\n [editSession]=\"tableModel.getEditSessionFor(row)\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-cell-renderer>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"columnIds.value\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: columnIds.value; let i = index\"\n [ngClass]=\"tableModel.getRowClasses(row)\" [attr.trackBy]=\"tableModel.trackBy(i, row)\"\n ></tr>\n\n</table>\n",
|
|
2241
3321
|
styles: [":host{display:flex;flex-direction:column;align-items:stretch}:host table{flex:1}"]
|
|
2242
3322
|
}),
|
|
2243
3323
|
__metadata("design:paramtypes", [])
|
|
@@ -2411,14 +3491,71 @@ var TableHeaderCellRendererComponent = /** @class */ (function () {
|
|
|
2411
3491
|
], TableHeaderCellRendererComponent.prototype, "defaultClassNames", void 0);
|
|
2412
3492
|
TableHeaderCellRendererComponent = __decorate([
|
|
2413
3493
|
Component({
|
|
2414
|
-
selector: 'aup-table-header-cell-renderer',
|
|
2415
|
-
template: "<ng-container [cdkPortalOutlet]=\"getPortal()\" (attached)=\"initialiseHeader($event.instance)\"></ng-container>\n",
|
|
2416
|
-
styles: [":host{display:flex;flex-direction:column;align-items:stretch;justify-content:center;height:100%}"]
|
|
3494
|
+
selector: 'aup-table-header-cell-renderer',
|
|
3495
|
+
template: "<ng-container [cdkPortalOutlet]=\"getPortal()\" (attached)=\"initialiseHeader($event.instance)\"></ng-container>\n",
|
|
3496
|
+
styles: [":host{display:flex;flex-direction:column;align-items:stretch;justify-content:center;height:100%}"]
|
|
3497
|
+
}),
|
|
3498
|
+
__metadata("design:paramtypes", [])
|
|
3499
|
+
], TableHeaderCellRendererComponent);
|
|
3500
|
+
return TableHeaderCellRendererComponent;
|
|
3501
|
+
}());
|
|
3502
|
+
|
|
3503
|
+
var MenuItemData = /** @class */ (function () {
|
|
3504
|
+
function MenuItemData(factory, face) {
|
|
3505
|
+
this.factory = factory;
|
|
3506
|
+
this.face = face;
|
|
3507
|
+
}
|
|
3508
|
+
return MenuItemData;
|
|
3509
|
+
}());
|
|
3510
|
+
/**
|
|
3511
|
+
*
|
|
3512
|
+
*/
|
|
3513
|
+
var TableRowMenuComponent = /** @class */ (function (_super) {
|
|
3514
|
+
__extends(TableRowMenuComponent, _super);
|
|
3515
|
+
function TableRowMenuComponent() {
|
|
3516
|
+
var _this = _super.call(this) || this;
|
|
3517
|
+
_this.actions = [];
|
|
3518
|
+
_this.moreActions = [];
|
|
3519
|
+
return _this;
|
|
3520
|
+
}
|
|
3521
|
+
TableRowMenuComponent.prototype.registerAction = function (commandFactory, properties) {
|
|
3522
|
+
this.actions.push(new MenuItemData(commandFactory, properties));
|
|
3523
|
+
};
|
|
3524
|
+
TableRowMenuComponent.prototype.registerMoreAction = function (commandFactory, properties) {
|
|
3525
|
+
this.moreActions.push(new MenuItemData(commandFactory, properties));
|
|
3526
|
+
};
|
|
3527
|
+
TableRowMenuComponent.prototype.ngOnInit = function () {
|
|
3528
|
+
};
|
|
3529
|
+
TableRowMenuComponent.prototype.createMoreMenuCommand = function (item, value) {
|
|
3530
|
+
var _this = this;
|
|
3531
|
+
var when = Dsl.disposeWith(this).when;
|
|
3532
|
+
var command = item.factory.create(value);
|
|
3533
|
+
when(command.busy).becomesFalsey(function () {
|
|
3534
|
+
_this.closeMoreMenu();
|
|
3535
|
+
});
|
|
3536
|
+
return command;
|
|
3537
|
+
};
|
|
3538
|
+
TableRowMenuComponent.prototype.closeMoreMenu = function () {
|
|
3539
|
+
this.menu.closeMenu();
|
|
3540
|
+
};
|
|
3541
|
+
__decorate([
|
|
3542
|
+
Input(),
|
|
3543
|
+
__metadata("design:type", Object)
|
|
3544
|
+
], TableRowMenuComponent.prototype, "value", void 0);
|
|
3545
|
+
__decorate([
|
|
3546
|
+
ViewChild(MatMenuTrigger),
|
|
3547
|
+
__metadata("design:type", MatMenuTrigger)
|
|
3548
|
+
], TableRowMenuComponent.prototype, "menu", void 0);
|
|
3549
|
+
TableRowMenuComponent = __decorate([
|
|
3550
|
+
Component({
|
|
3551
|
+
selector: 'aup-table-row-menu',
|
|
3552
|
+
template: "\n <aup-tool-bar>\n <aup-command *ngFor=\"let action of actions\" [command]=\"action.factory.create(value)\"\n [face]=\"action.faceModel\"></aup-command>\n </aup-tool-bar>\n <ng-container *ngIf=\"moreActions.length > 0\">\n <aup-more-menu>\n <aup-command *ngFor=\"let action of moreActions\" [command]=\"action.factory.create(value)\"\n [face]=\"action.faceModel\"></aup-command>\n </aup-more-menu>\n </ng-container>\n ",
|
|
3553
|
+
styles: [":host {\n display: inline-flex;\n flex-direction: row;\n align-items: center;\n }"]
|
|
2417
3554
|
}),
|
|
2418
3555
|
__metadata("design:paramtypes", [])
|
|
2419
|
-
],
|
|
2420
|
-
return
|
|
2421
|
-
}());
|
|
3556
|
+
], TableRowMenuComponent);
|
|
3557
|
+
return TableRowMenuComponent;
|
|
3558
|
+
}(DisposableComponent));
|
|
2422
3559
|
|
|
2423
3560
|
var VerticalFocusContainerComponent = /** @class */ (function (_super) {
|
|
2424
3561
|
__extends(VerticalFocusContainerComponent, _super);
|
|
@@ -2545,7 +3682,18 @@ var ComponentsModule = /** @class */ (function () {
|
|
|
2545
3682
|
DefaultHeaderCellRendererComponent,
|
|
2546
3683
|
TableHeaderCellRendererComponent,
|
|
2547
3684
|
IconComponent,
|
|
2548
|
-
SectionHeaderComponent
|
|
3685
|
+
SectionHeaderComponent,
|
|
3686
|
+
TableRowMenuComponent,
|
|
3687
|
+
ToolBarComponent,
|
|
3688
|
+
CommandComponent,
|
|
3689
|
+
PopupMenuComponent,
|
|
3690
|
+
CommandGroupComponent,
|
|
3691
|
+
CommandFaceComponent,
|
|
3692
|
+
MoreMenuComponent,
|
|
3693
|
+
SeparatorComponent,
|
|
3694
|
+
FlexComponent,
|
|
3695
|
+
CommandGroupMenuRendererComponent,
|
|
3696
|
+
CommandGroupRendererComponent
|
|
2549
3697
|
],
|
|
2550
3698
|
imports: [
|
|
2551
3699
|
CommonModule,
|
|
@@ -2564,7 +3712,9 @@ var ComponentsModule = /** @class */ (function () {
|
|
|
2564
3712
|
CdkScrollableModule,
|
|
2565
3713
|
FontAwesomeModule,
|
|
2566
3714
|
MatTooltipModule,
|
|
2567
|
-
MatAutocompleteModule
|
|
3715
|
+
MatAutocompleteModule,
|
|
3716
|
+
MatMenuModule,
|
|
3717
|
+
MatDividerModule
|
|
2568
3718
|
],
|
|
2569
3719
|
exports: [
|
|
2570
3720
|
NumberInputComponent,
|
|
@@ -2588,22 +3738,19 @@ var ComponentsModule = /** @class */ (function () {
|
|
|
2588
3738
|
EditRowControls,
|
|
2589
3739
|
ColumnTemplateDirective,
|
|
2590
3740
|
IconComponent,
|
|
2591
|
-
SectionHeaderComponent
|
|
3741
|
+
SectionHeaderComponent,
|
|
3742
|
+
TableRowMenuComponent,
|
|
3743
|
+
CommandGroupComponent,
|
|
3744
|
+
ToolBarComponent,
|
|
3745
|
+
CommandComponent,
|
|
3746
|
+
PopupMenuComponent,
|
|
3747
|
+
CommandFaceComponent,
|
|
3748
|
+
MoreMenuComponent,
|
|
3749
|
+
SeparatorComponent,
|
|
3750
|
+
FlexComponent
|
|
2592
3751
|
],
|
|
2593
3752
|
providers: [
|
|
2594
3753
|
FocusBindingFactory
|
|
2595
|
-
// {
|
|
2596
|
-
// provide: CELL_EDITOR_REGISTRATION, useValue: {
|
|
2597
|
-
// type: 'string',
|
|
2598
|
-
// editorClass: StringInputComponent
|
|
2599
|
-
// }, multi: true
|
|
2600
|
-
// },
|
|
2601
|
-
// {
|
|
2602
|
-
// provide: CELL_EDITOR_REGISTRATION, useValue: {
|
|
2603
|
-
// type: 'number',
|
|
2604
|
-
// editorClass: NumberInputComponent
|
|
2605
|
-
// }, multi: true
|
|
2606
|
-
// }
|
|
2607
3754
|
]
|
|
2608
3755
|
}),
|
|
2609
3756
|
__metadata("design:paramtypes", [FaIconLibrary])
|
|
@@ -2682,7 +3829,7 @@ var ActivityActionsComponent = /** @class */ (function (_super) {
|
|
|
2682
3829
|
Component({
|
|
2683
3830
|
selector: 'aup-activity-actions',
|
|
2684
3831
|
template: "<ng-container *ngIf=\"hasCancelCommand()\">\n <button class=\"cancel\" *ngIf=\"!hasCancelText()\" mat-icon-button [pectinCommand]=\"cancelCommand\">\n <aup-icon icon=\"mat:clear\"></aup-icon>\n </button>\n <button class=\"cancel\" *ngIf=\"hasCancelText()\" mat-button [pectinCommand]=\"cancelCommand\">{{cancelText}}</button>\n</ng-container>\n<ng-container *ngIf=\"hasConfirmCommand()\">\n <button class=\"confirm\" *ngIf=\"!hasConfirmText()\" mat-icon-button [pectinCommand]=\"confirmCommand\">\n <aup-icon icon=\"mat:done\"></aup-icon>\n </button>\n <button class=\"confirm\" *ngIf=\"hasConfirmText()\" mat-button [pectinCommand]=\"confirmCommand\">{{confirmText}}</button>\n</ng-container>\n<div class=\"content\">\n <ng-content></ng-content>\n</div>\n",
|
|
2685
|
-
styles: [":host{display:-ms-grid;display:grid;grid-template-areas:\"cancel confirm content\";-ms-grid-columns:auto auto 1fr;grid-template-columns:auto auto 1fr;-ms-grid-rows:auto;grid-template-rows:auto;align-items:center;justify-content:end}:host.align-end{grid-template-areas:\"content cancel confirm\";-ms-grid-columns:1fr auto auto;grid-template-columns:1fr auto auto}:host.align-stretch{grid-template-areas:\"cancel content confirm\";-ms-grid-columns:auto 1fr auto;grid-template-columns:auto 1fr auto}.cancel{-ms-grid-row:1;-ms-grid-column:1;grid-area:cancel}:host.align-end>.cancel{-ms-grid-row:1;-ms-grid-column:2}:host.align-stretch>.cancel{-ms-grid-row:1;-ms-grid-column:1}.confirm{-ms-grid-row:1;-ms-grid-column:2;grid-area:confirm}:host.align-end>.confirm{-ms-grid-row:1;-ms-grid-column:3}:host.align-stretch>.confirm{-ms-grid-row:1;-ms-grid-column:3}.
|
|
3832
|
+
styles: [":host{display:-ms-grid;display:grid;grid-template-areas:\"cancel confirm content\";-ms-grid-columns:auto auto 1fr;grid-template-columns:auto auto 1fr;-ms-grid-rows:auto;grid-template-rows:auto;align-items:center;justify-content:end}:host.align-end{grid-template-areas:\"content cancel confirm\";-ms-grid-columns:1fr auto auto;grid-template-columns:1fr auto auto}:host.align-stretch{grid-template-areas:\"cancel content confirm\";-ms-grid-columns:auto 1fr auto;grid-template-columns:auto 1fr auto}.cancel{-ms-grid-row:1;-ms-grid-column:1;grid-area:cancel}:host.align-end>.cancel{-ms-grid-row:1;-ms-grid-column:2}:host.align-stretch>.cancel{-ms-grid-row:1;-ms-grid-column:1}.confirm{-ms-grid-row:1;-ms-grid-column:2;grid-area:confirm}:host.align-end>.confirm{-ms-grid-row:1;-ms-grid-column:3}:host.align-stretch>.confirm{-ms-grid-row:1;-ms-grid-column:3}.column{-ms-grid-row:1;-ms-grid-column:3;grid-area:content;text-align:left}:host.align-end>.column{-ms-grid-row:1;-ms-grid-column:1}:host.align-stretch>.column{-ms-grid-row:1;-ms-grid-column:2}"]
|
|
2686
3833
|
})
|
|
2687
3834
|
], ActivityActionsComponent);
|
|
2688
3835
|
return ActivityActionsComponent;
|
|
@@ -2694,13 +3841,27 @@ var Activity = /** @class */ (function (_super) {
|
|
|
2694
3841
|
function Activity() {
|
|
2695
3842
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
2696
3843
|
_this._busyModel = new DelegatingValueModel().withDefault(false);
|
|
3844
|
+
_this._focusedModel = _this.registerDisposable(new DelegatingValueModel());
|
|
2697
3845
|
_this.class = 'aup-activity';
|
|
2698
3846
|
return _this;
|
|
2699
3847
|
}
|
|
3848
|
+
Object.defineProperty(Activity.prototype, "isFocused", {
|
|
3849
|
+
get: function () {
|
|
3850
|
+
return this._focusedModel.value;
|
|
3851
|
+
},
|
|
3852
|
+
enumerable: true,
|
|
3853
|
+
configurable: true
|
|
3854
|
+
});
|
|
2700
3855
|
Activity.prototype.initialise = function (nestedInteractionContext, activityContext) {
|
|
3856
|
+
var _this = this;
|
|
3857
|
+
var _a = Dsl.disposeWith(this), chain = _a.chain, when = _a.when;
|
|
2701
3858
|
assert$1.isNil(this._activityContext);
|
|
2702
3859
|
this._activityContext = activityContext;
|
|
2703
3860
|
this._interactionContext = nestedInteractionContext;
|
|
3861
|
+
this._focusedModel.setDelegate(activityContext.focused);
|
|
3862
|
+
when(this._focusedModel).becomesTruthy(function () {
|
|
3863
|
+
_this.onActivityReady();
|
|
3864
|
+
});
|
|
2704
3865
|
};
|
|
2705
3866
|
Object.defineProperty(Activity.prototype, "interactionContext", {
|
|
2706
3867
|
get: function () {
|
|
@@ -2726,6 +3887,13 @@ var Activity = /** @class */ (function (_super) {
|
|
|
2726
3887
|
enumerable: true,
|
|
2727
3888
|
configurable: true
|
|
2728
3889
|
});
|
|
3890
|
+
Object.defineProperty(Activity.prototype, "focused", {
|
|
3891
|
+
get: function () {
|
|
3892
|
+
return this._focusedModel.readonly;
|
|
3893
|
+
},
|
|
3894
|
+
enumerable: true,
|
|
3895
|
+
configurable: true
|
|
3896
|
+
});
|
|
2729
3897
|
Activity.prototype.busyWhile = function (busyModel) {
|
|
2730
3898
|
this._busyModel.setDelegate(busyModel);
|
|
2731
3899
|
};
|
|
@@ -2739,6 +3907,11 @@ var Activity = /** @class */ (function (_super) {
|
|
|
2739
3907
|
HostBinding('class'),
|
|
2740
3908
|
__metadata("design:type", Object)
|
|
2741
3909
|
], Activity.prototype, "class", void 0);
|
|
3910
|
+
__decorate([
|
|
3911
|
+
HostBinding('attr.focused'),
|
|
3912
|
+
__metadata("design:type", Object),
|
|
3913
|
+
__metadata("design:paramtypes", [])
|
|
3914
|
+
], Activity.prototype, "isFocused", null);
|
|
2742
3915
|
return Activity;
|
|
2743
3916
|
}(DisposableComponent));
|
|
2744
3917
|
|
|
@@ -2877,6 +4050,7 @@ var ActivityRef = /** @class */ (function () {
|
|
|
2877
4050
|
this.onComplete = onComplete;
|
|
2878
4051
|
this._complete = false;
|
|
2879
4052
|
this.deferredResult = Deferred.defer();
|
|
4053
|
+
this.focusedModel = new MutableValueModel();
|
|
2880
4054
|
}
|
|
2881
4055
|
ActivityRef.prototype.isActivityRealised = function () {
|
|
2882
4056
|
return !!this._activity;
|
|
@@ -2892,6 +4066,16 @@ var ActivityRef = /** @class */ (function () {
|
|
|
2892
4066
|
enumerable: true,
|
|
2893
4067
|
configurable: true
|
|
2894
4068
|
});
|
|
4069
|
+
ActivityRef.prototype.setFocused = function (focused) {
|
|
4070
|
+
this.focusedModel.value = focused;
|
|
4071
|
+
};
|
|
4072
|
+
Object.defineProperty(ActivityRef.prototype, "focused", {
|
|
4073
|
+
get: function () {
|
|
4074
|
+
return this.focusedModel.value;
|
|
4075
|
+
},
|
|
4076
|
+
enumerable: true,
|
|
4077
|
+
configurable: true
|
|
4078
|
+
});
|
|
2895
4079
|
ActivityRef.prototype.notifyActivityCreated = function (activity, nestedInteractionContext) {
|
|
2896
4080
|
assert.isNil(this._activity);
|
|
2897
4081
|
this._activity = activity;
|
|
@@ -2902,7 +4086,8 @@ var ActivityRef = /** @class */ (function () {
|
|
|
2902
4086
|
},
|
|
2903
4087
|
onCancel: function (error) {
|
|
2904
4088
|
self.finishActivity(function (deferred) { return deferred.reject(error); });
|
|
2905
|
-
}
|
|
4089
|
+
},
|
|
4090
|
+
focused: this.focusedModel.readonly
|
|
2906
4091
|
});
|
|
2907
4092
|
};
|
|
2908
4093
|
ActivityRef.prototype.finishActivity = function (resolveOrReject) {
|
|
@@ -2940,7 +4125,7 @@ var ActivityOutletComponent = /** @class */ (function () {
|
|
|
2940
4125
|
},
|
|
2941
4126
|
set: function (activityRef) {
|
|
2942
4127
|
if (this.activityRef && !this.activityRef.isComplete()) {
|
|
2943
|
-
lang$1.illegalState(
|
|
4128
|
+
lang$1.illegalState('changing activity before previous one has completed');
|
|
2944
4129
|
}
|
|
2945
4130
|
this._activityRef = activityRef;
|
|
2946
4131
|
this.loadActivity(activityRef);
|
|
@@ -3003,8 +4188,9 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3003
4188
|
function ActivityContainerComponent() {
|
|
3004
4189
|
var _this = _super.call(this) || this;
|
|
3005
4190
|
_this.dynamicHeight = false;
|
|
3006
|
-
_this.
|
|
4191
|
+
_this.activityRefs = [];
|
|
3007
4192
|
_this.garbage = new GarbageCollector();
|
|
4193
|
+
_this.inAnimation = new MutableValueModel(false);
|
|
3008
4194
|
return _this;
|
|
3009
4195
|
}
|
|
3010
4196
|
ActivityContainerComponent.prototype.ngOnInit = function () {
|
|
@@ -3042,6 +4228,7 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3042
4228
|
ActivityContainerComponent.prototype.registerDisposable = function (disposable) {
|
|
3043
4229
|
return this.garbage.registerDisposable(disposable);
|
|
3044
4230
|
};
|
|
4231
|
+
// @Trace()
|
|
3045
4232
|
ActivityContainerComponent.prototype.dispose = function () {
|
|
3046
4233
|
// TODO: think about auto cancelling any outstanding activity on dispose.
|
|
3047
4234
|
// See NavigationState.Navigating for a use-case.
|
|
@@ -3052,7 +4239,7 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3052
4239
|
if (!this.isActive()) {
|
|
3053
4240
|
lang$1.illegalState('no activity in progress');
|
|
3054
4241
|
}
|
|
3055
|
-
return ___default.findLast(this.
|
|
4242
|
+
return ___default.findLast(this.activityRefs, function (tab) { return !tab.isComplete(); });
|
|
3056
4243
|
};
|
|
3057
4244
|
/**
|
|
3058
4245
|
* Cancels the current activity and returns true the context is no longer active, false if
|
|
@@ -3091,14 +4278,14 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3091
4278
|
});
|
|
3092
4279
|
this.launchActivity(activityRef);
|
|
3093
4280
|
// if this is the first activity let the interaction service know.
|
|
3094
|
-
if (this.
|
|
4281
|
+
if (this.activityRefs.length === 1) {
|
|
3095
4282
|
// console.log('Now active!!!');
|
|
3096
4283
|
this.interactionServiceApi.notifyActive(this);
|
|
3097
4284
|
}
|
|
3098
4285
|
return activityRef.activityResult;
|
|
3099
4286
|
};
|
|
3100
4287
|
ActivityContainerComponent.prototype.getActiveActivityCount = function () {
|
|
3101
|
-
return this.
|
|
4288
|
+
return this.activityRefs.filter(function (ref) { return !ref.isComplete(); }).length;
|
|
3102
4289
|
};
|
|
3103
4290
|
/**
|
|
3104
4291
|
* Checks if this interaction context has finished an is in the process of waiting
|
|
@@ -3125,7 +4312,7 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3125
4312
|
// Without this our animation done wasn't called when a single
|
|
3126
4313
|
// new activity followed a single tab activity (since we're tracking
|
|
3127
4314
|
// by activity index)
|
|
3128
|
-
this.
|
|
4315
|
+
this.activityRefs = [];
|
|
3129
4316
|
var promise = this.interactionServiceApi.notifyFinished(this);
|
|
3130
4317
|
this._deferredCleanUp = promise
|
|
3131
4318
|
.finally(function () {
|
|
@@ -3135,14 +4322,15 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3135
4322
|
};
|
|
3136
4323
|
// @Trace()
|
|
3137
4324
|
ActivityContainerComponent.prototype.launchActivity = function (activityRef) {
|
|
3138
|
-
var cleanedTabs = this.
|
|
3139
|
-
this.
|
|
4325
|
+
var cleanedTabs = this.activityRefs.filter(function (tab) { return !tab.isComplete(); });
|
|
4326
|
+
this.activityRefs = cleanedTabs.concat(activityRef);
|
|
3140
4327
|
this.synchroniseSelectedTabIndex();
|
|
3141
4328
|
};
|
|
3142
4329
|
ActivityContainerComponent.prototype.activityIndex = function (index, activityRef) {
|
|
3143
4330
|
return index;
|
|
3144
4331
|
};
|
|
3145
4332
|
;
|
|
4333
|
+
// @Trace()
|
|
3146
4334
|
ActivityContainerComponent.prototype.onAnimationFinished = function () {
|
|
3147
4335
|
if (this.onAnimationFinishedJob) {
|
|
3148
4336
|
this.onAnimationFinishedJob();
|
|
@@ -3152,15 +4340,21 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3152
4340
|
/**
|
|
3153
4341
|
* Synchronises the selected tab index.
|
|
3154
4342
|
*/
|
|
4343
|
+
// @Trace()
|
|
3155
4344
|
ActivityContainerComponent.prototype.synchroniseSelectedTabIndex = function () {
|
|
3156
4345
|
var _this = this;
|
|
3157
4346
|
var previousIndex = this.tabs.selectedIndex;
|
|
3158
4347
|
var newIndex = this.getActiveActivityCount() - 1;
|
|
3159
4348
|
if (previousIndex !== newIndex) {
|
|
4349
|
+
this.inAnimation.value = true;
|
|
4350
|
+
this.activityRefs[newIndex].setFocused(false);
|
|
3160
4351
|
this.tabs.selectedIndex = newIndex;
|
|
3161
4352
|
this.onAnimationFinishedJob = function () {
|
|
3162
|
-
_this.
|
|
3163
|
-
_this.
|
|
4353
|
+
_this.activityRefs = _this.activityRefs.filter(function (tab) { return !tab.isComplete(); });
|
|
4354
|
+
_this.inAnimation.value = false;
|
|
4355
|
+
_this.activityRefs.forEach(function (ref, index) {
|
|
4356
|
+
ref.setFocused(index === newIndex);
|
|
4357
|
+
});
|
|
3164
4358
|
};
|
|
3165
4359
|
}
|
|
3166
4360
|
};
|
|
@@ -3168,6 +4362,10 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3168
4362
|
return this.activityOutlets.toArray()[this.tabs.selectedIndex];
|
|
3169
4363
|
};
|
|
3170
4364
|
// @Trace()
|
|
4365
|
+
ActivityContainerComponent.prototype.getSelectedTabIndex = function () {
|
|
4366
|
+
return this.tabs.selectedIndex;
|
|
4367
|
+
};
|
|
4368
|
+
// @Trace()
|
|
3171
4369
|
ActivityContainerComponent.prototype.triggerTabSynchronisation = function () {
|
|
3172
4370
|
var _this = this;
|
|
3173
4371
|
if (this.syncSelectedTabTimeout) {
|
|
@@ -3190,16 +4388,10 @@ var ActivityContainerComponent = /** @class */ (function (_super) {
|
|
|
3190
4388
|
ViewChildren(ActivityOutletComponent),
|
|
3191
4389
|
__metadata("design:type", QueryList)
|
|
3192
4390
|
], ActivityContainerComponent.prototype, "activityOutlets", void 0);
|
|
3193
|
-
__decorate([
|
|
3194
|
-
Trace(),
|
|
3195
|
-
__metadata("design:type", Function),
|
|
3196
|
-
__metadata("design:paramtypes", []),
|
|
3197
|
-
__metadata("design:returntype", void 0)
|
|
3198
|
-
], ActivityContainerComponent.prototype, "dispose", null);
|
|
3199
4391
|
ActivityContainerComponent = __decorate([
|
|
3200
4392
|
Component({
|
|
3201
4393
|
selector: 'aup-activity-container',
|
|
3202
|
-
template: "<mat-tab-group #tabs no-tab-header\n [dynamicHeight]=\"dynamicHeight\"\n [class.full-height-tabs]=\"!dynamicHeight\">\n <mat-tab *ngFor=\"let
|
|
4394
|
+
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 <!--\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 </mat-tab>\n</mat-tab-group>\n",
|
|
3203
4395
|
styles: [":host{display:flex;flex-direction:column}mat-tab-group{flex:1}"]
|
|
3204
4396
|
}),
|
|
3205
4397
|
__metadata("design:paramtypes", [])
|
|
@@ -4270,6 +5462,9 @@ var PlaceComponent = /** @class */ (function (_super) {
|
|
|
4270
5462
|
var _this = _super.call(this) || this;
|
|
4271
5463
|
_this.visitModel = new MutableValueModel();
|
|
4272
5464
|
_this._inVisitUpdate = new Guard();
|
|
5465
|
+
_this._active = new MutableValueModel(false);
|
|
5466
|
+
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
5467
|
+
when(_this._active).becomesTruthy(function () { return _this.onPlaceReady(); });
|
|
4273
5468
|
return _this;
|
|
4274
5469
|
}
|
|
4275
5470
|
PlaceComponent_1 = PlaceComponent;
|
|
@@ -4279,7 +5474,7 @@ var PlaceComponent = /** @class */ (function (_super) {
|
|
|
4279
5474
|
assert.isNil(this.visitModel.value);
|
|
4280
5475
|
var when = Dsl.disposeWith(this).when;
|
|
4281
5476
|
this.visitModel.value = visit;
|
|
4282
|
-
DebugContext.
|
|
5477
|
+
DebugContext.getOrCreate(this.visitModel).tag(this.placeDefinition.component.name + ".visitModel");
|
|
4283
5478
|
this.placeDefinition.getVisitParameterDefs().forEach(function (parameterDef) { return _this.installBinding(parameterDef); });
|
|
4284
5479
|
when.valueOf(this.visitModel).changes(function (current, previous) {
|
|
4285
5480
|
notifyVisitChanged(current, previous);
|
|
@@ -4327,6 +5522,19 @@ var PlaceComponent = /** @class */ (function (_super) {
|
|
|
4327
5522
|
enumerable: true,
|
|
4328
5523
|
configurable: true
|
|
4329
5524
|
});
|
|
5525
|
+
Object.defineProperty(PlaceComponent.prototype, "active", {
|
|
5526
|
+
get: function () {
|
|
5527
|
+
return this._active.readonly;
|
|
5528
|
+
},
|
|
5529
|
+
enumerable: true,
|
|
5530
|
+
configurable: true
|
|
5531
|
+
});
|
|
5532
|
+
/**
|
|
5533
|
+
* Called by the router when the place is ready to interact after any animations have run.
|
|
5534
|
+
*/
|
|
5535
|
+
PlaceComponent.prototype._notifyActive = function (active) {
|
|
5536
|
+
this._active.value = active;
|
|
5537
|
+
};
|
|
4330
5538
|
PlaceComponent.prototype.onPlaceReady = function () {
|
|
4331
5539
|
};
|
|
4332
5540
|
var PlaceComponent_1;
|
|
@@ -5427,75 +6635,6 @@ var UrlService = /** @class */ (function () {
|
|
|
5427
6635
|
return UrlService;
|
|
5428
6636
|
}());
|
|
5429
6637
|
|
|
5430
|
-
var Visit = /** @class */ (function () {
|
|
5431
|
-
function Visit(placeDefinition, visitParameters) {
|
|
5432
|
-
if (visitParameters === void 0) { visitParameters = {}; }
|
|
5433
|
-
this.placeDefinition = placeDefinition;
|
|
5434
|
-
this.visitParameters = visitParameters;
|
|
5435
|
-
}
|
|
5436
|
-
// @Trace()
|
|
5437
|
-
Visit.prototype.getRouteId = function () {
|
|
5438
|
-
return this.placeDefinition.getRouteIdFrom(this);
|
|
5439
|
-
};
|
|
5440
|
-
// @Trace()
|
|
5441
|
-
Visit.prototype.hasRouteId = function () {
|
|
5442
|
-
return !isNil(this.getRouteId());
|
|
5443
|
-
};
|
|
5444
|
-
/**
|
|
5445
|
-
* Returns the value of the place parameter with the specified name. The parameter
|
|
5446
|
-
* name is taken from the `as` option, e.g. {as: 'aCustomName'} otherwise it is the
|
|
5447
|
-
* same as the the ValueModel property name.
|
|
5448
|
-
* @param parameterName the field name of the property model or the `as` option if specified.
|
|
5449
|
-
*/
|
|
5450
|
-
Visit.prototype.getParameter = function (parameterName) {
|
|
5451
|
-
return this.visitParameters[parameterName];
|
|
5452
|
-
};
|
|
5453
|
-
// @Trace()
|
|
5454
|
-
Visit.prototype.hasParameter = function (parameterName) {
|
|
5455
|
-
return Object.keys(this.visitParameters).includes(parameterName);
|
|
5456
|
-
};
|
|
5457
|
-
Visit.prototype.replace = function (parameter, value) {
|
|
5458
|
-
var _a;
|
|
5459
|
-
return new Visit(this.placeDefinition, __assign(__assign({}, this.visitParameters), (_a = {}, _a[parameter.name] = value, _a)));
|
|
5460
|
-
};
|
|
5461
|
-
Visit.prototype.mergeRouteParameters = function (routeParams) {
|
|
5462
|
-
var _this = this;
|
|
5463
|
-
// todo: whitelist parameters.
|
|
5464
|
-
var routeParameterKeys = Object.keys(routeParams);
|
|
5465
|
-
var params = {};
|
|
5466
|
-
this.placeDefinition.getVisitParameterDefs().forEach(function (def) {
|
|
5467
|
-
if (def.isRouteId || def.isRouteParameter) {
|
|
5468
|
-
if (routeParameterKeys.includes(def.name)) {
|
|
5469
|
-
params[def.name] = routeParams[def.name];
|
|
5470
|
-
}
|
|
5471
|
-
}
|
|
5472
|
-
else {
|
|
5473
|
-
// copy non route params as is, but only if they already exist otherwise we'll inject nil values and break the
|
|
5474
|
-
// defaults and remember sanitisation process.
|
|
5475
|
-
var value = _this.getParameter(def.name);
|
|
5476
|
-
if (_this.hasParameter(def.name)) {
|
|
5477
|
-
params[def.name] = value;
|
|
5478
|
-
}
|
|
5479
|
-
}
|
|
5480
|
-
});
|
|
5481
|
-
return new Visit(this.placeDefinition, params);
|
|
5482
|
-
};
|
|
5483
|
-
Visit.prototype.hasRoutingChangedFrom = function (other) {
|
|
5484
|
-
var samePlace = other.placeDefinition === this.placeDefinition;
|
|
5485
|
-
var sameRouteParameters = isEqual(this.placeDefinition.getFormattedRouteParameters(this, true), this.placeDefinition.getFormattedRouteParameters(other, true));
|
|
5486
|
-
return !samePlace || !sameRouteParameters;
|
|
5487
|
-
};
|
|
5488
|
-
Visit.prototype.hasChangedFrom = function (other) {
|
|
5489
|
-
var sameNonRouteParameters = isEqual(this.placeDefinition.getNonRouteParameters(this), this.placeDefinition.getNonRouteParameters(other));
|
|
5490
|
-
return !sameNonRouteParameters || this.hasRoutingChangedFrom(other);
|
|
5491
|
-
};
|
|
5492
|
-
Visit.prototype.toDebugString = function () {
|
|
5493
|
-
var _this = this;
|
|
5494
|
-
return Object.keys(this.visitParameters).map(function (k) { return k + "=" + _this.visitParameters[k]; }).join(",");
|
|
5495
|
-
};
|
|
5496
|
-
return Visit;
|
|
5497
|
-
}());
|
|
5498
|
-
|
|
5499
6638
|
var PlaceRouter = /** @class */ (function (_super) {
|
|
5500
6639
|
__extends(PlaceRouter, _super);
|
|
5501
6640
|
function PlaceRouter(angularRouter, angularLocation, interactionService, urlService, placeHistory) {
|
|
@@ -5691,6 +6830,7 @@ var PlaceRouter = /** @class */ (function (_super) {
|
|
|
5691
6830
|
enumerable: true,
|
|
5692
6831
|
configurable: true
|
|
5693
6832
|
});
|
|
6833
|
+
// @Trace()
|
|
5694
6834
|
PlaceRouter.prototype.pushVisitChangesToRoute = function (previous, next) {
|
|
5695
6835
|
return __awaiter(this, void 0, void 0, function () {
|
|
5696
6836
|
var _this = this;
|
|
@@ -5791,12 +6931,6 @@ var PlaceRouter = /** @class */ (function (_super) {
|
|
|
5791
6931
|
{ type: PlaceHistory }
|
|
5792
6932
|
]; };
|
|
5793
6933
|
PlaceRouter.ɵprov = ɵɵdefineInjectable({ factory: function PlaceRouter_Factory() { return new PlaceRouter(ɵɵinject(Router), ɵɵinject(Location), ɵɵinject(InteractionService), ɵɵinject(UrlService), ɵɵinject(PlaceHistory)); }, token: PlaceRouter, providedIn: "root" });
|
|
5794
|
-
__decorate([
|
|
5795
|
-
Trace(),
|
|
5796
|
-
__metadata("design:type", Function),
|
|
5797
|
-
__metadata("design:paramtypes", [Visit, Visit]),
|
|
5798
|
-
__metadata("design:returntype", Promise)
|
|
5799
|
-
], PlaceRouter.prototype, "pushVisitChangesToRoute", null);
|
|
5800
6934
|
PlaceRouter = __decorate([
|
|
5801
6935
|
Injectable({
|
|
5802
6936
|
providedIn: 'root'
|
|
@@ -5810,6 +6944,75 @@ var PlaceRouter = /** @class */ (function (_super) {
|
|
|
5810
6944
|
return PlaceRouter;
|
|
5811
6945
|
}(GarbageCollector));
|
|
5812
6946
|
|
|
6947
|
+
var Visit = /** @class */ (function () {
|
|
6948
|
+
function Visit(placeDefinition, visitParameters) {
|
|
6949
|
+
if (visitParameters === void 0) { visitParameters = {}; }
|
|
6950
|
+
this.placeDefinition = placeDefinition;
|
|
6951
|
+
this.visitParameters = visitParameters;
|
|
6952
|
+
}
|
|
6953
|
+
// @Trace()
|
|
6954
|
+
Visit.prototype.getRouteId = function () {
|
|
6955
|
+
return this.placeDefinition.getRouteIdFrom(this);
|
|
6956
|
+
};
|
|
6957
|
+
// @Trace()
|
|
6958
|
+
Visit.prototype.hasRouteId = function () {
|
|
6959
|
+
return !isNil(this.getRouteId());
|
|
6960
|
+
};
|
|
6961
|
+
/**
|
|
6962
|
+
* Returns the value of the place parameter with the specified name. The parameter
|
|
6963
|
+
* name is taken from the `as` option, e.g. {as: 'aCustomName'} otherwise it is the
|
|
6964
|
+
* same as the the ValueModel property name.
|
|
6965
|
+
* @param parameterName the field name of the property model or the `as` option if specified.
|
|
6966
|
+
*/
|
|
6967
|
+
Visit.prototype.getParameter = function (parameterName) {
|
|
6968
|
+
return this.visitParameters[parameterName];
|
|
6969
|
+
};
|
|
6970
|
+
// @Trace()
|
|
6971
|
+
Visit.prototype.hasParameter = function (parameterName) {
|
|
6972
|
+
return Object.keys(this.visitParameters).includes(parameterName);
|
|
6973
|
+
};
|
|
6974
|
+
Visit.prototype.replace = function (parameter, value) {
|
|
6975
|
+
var _a;
|
|
6976
|
+
return new Visit(this.placeDefinition, __assign(__assign({}, this.visitParameters), (_a = {}, _a[parameter.name] = value, _a)));
|
|
6977
|
+
};
|
|
6978
|
+
Visit.prototype.mergeRouteParameters = function (routeParams) {
|
|
6979
|
+
var _this = this;
|
|
6980
|
+
// todo: whitelist parameters.
|
|
6981
|
+
var routeParameterKeys = Object.keys(routeParams);
|
|
6982
|
+
var params = {};
|
|
6983
|
+
this.placeDefinition.getVisitParameterDefs().forEach(function (def) {
|
|
6984
|
+
if (def.isRouteId || def.isRouteParameter) {
|
|
6985
|
+
if (routeParameterKeys.includes(def.name)) {
|
|
6986
|
+
params[def.name] = routeParams[def.name];
|
|
6987
|
+
}
|
|
6988
|
+
}
|
|
6989
|
+
else {
|
|
6990
|
+
// copy non route params as is, but only if they already exist otherwise we'll inject nil values and break the
|
|
6991
|
+
// defaults and remember sanitisation process.
|
|
6992
|
+
var value = _this.getParameter(def.name);
|
|
6993
|
+
if (_this.hasParameter(def.name)) {
|
|
6994
|
+
params[def.name] = value;
|
|
6995
|
+
}
|
|
6996
|
+
}
|
|
6997
|
+
});
|
|
6998
|
+
return new Visit(this.placeDefinition, params);
|
|
6999
|
+
};
|
|
7000
|
+
Visit.prototype.hasRoutingChangedFrom = function (other) {
|
|
7001
|
+
var samePlace = other.placeDefinition === this.placeDefinition;
|
|
7002
|
+
var sameRouteParameters = isEqual(this.placeDefinition.getFormattedRouteParameters(this, true), this.placeDefinition.getFormattedRouteParameters(other, true));
|
|
7003
|
+
return !samePlace || !sameRouteParameters;
|
|
7004
|
+
};
|
|
7005
|
+
Visit.prototype.hasChangedFrom = function (other) {
|
|
7006
|
+
var sameNonRouteParameters = isEqual(this.placeDefinition.getNonRouteParameters(this), this.placeDefinition.getNonRouteParameters(other));
|
|
7007
|
+
return !sameNonRouteParameters || this.hasRoutingChangedFrom(other);
|
|
7008
|
+
};
|
|
7009
|
+
Visit.prototype.toDebugString = function () {
|
|
7010
|
+
var _this = this;
|
|
7011
|
+
return Object.keys(this.visitParameters).map(function (k) { return k + "=" + _this.visitParameters[k]; }).join(",");
|
|
7012
|
+
};
|
|
7013
|
+
return Visit;
|
|
7014
|
+
}());
|
|
7015
|
+
|
|
5813
7016
|
var AUP_PLACE_CONFIG = new InjectionToken('AUP_PLACE_CONFIG');
|
|
5814
7017
|
|
|
5815
7018
|
// Freezes the state of the components at the start of the animation.
|
|
@@ -5869,6 +7072,7 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5869
7072
|
_this._activePlaceModel = new MutableValueModel();
|
|
5870
7073
|
_this.initialPlaceIndex = null;
|
|
5871
7074
|
_this._isPushingVisitToRoute = new MutableValueModel(false);
|
|
7075
|
+
_this.isVeryFirstLoad = true;
|
|
5872
7076
|
var _a = Dsl.disposeWith(_this), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
5873
7077
|
_this.parentOutletModel = new MutableValueModel(parentOutlet);
|
|
5874
7078
|
var defaultPlaceAnimationOrder = chain(_this.parentOutletModel)
|
|
@@ -5877,8 +7081,9 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5877
7081
|
.pluckList('children')
|
|
5878
7082
|
.pluck('component');
|
|
5879
7083
|
var activatePlaceType = chain(_this.activePlaceModel).map(function (p) { return p.constructor; });
|
|
5880
|
-
_this.
|
|
5881
|
-
.otherwise(defaultPlaceAnimationOrder)
|
|
7084
|
+
_this.placesInAnimationOrder = chain(_this.customPlaceAnimationOrderModel)
|
|
7085
|
+
.otherwise(defaultPlaceAnimationOrder);
|
|
7086
|
+
_this.activePlaceAnimationPosition = _this.placesInAnimationOrder
|
|
5882
7087
|
.reduce(function (placesInOrder) {
|
|
5883
7088
|
var placeIndex = 0;
|
|
5884
7089
|
if (activatePlaceType.value) {
|
|
@@ -5889,14 +7094,16 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5889
7094
|
}
|
|
5890
7095
|
return isNil(_this.initialPlaceIndex) ? 0 : placeIndex - _this.initialPlaceIndex;
|
|
5891
7096
|
}, { dependsOn: activatePlaceType });
|
|
7097
|
+
_this.animationSupported = _this.placesInAnimationOrder.count().isGreaterThan(0);
|
|
7098
|
+
_this.animationEnabled = valueOf.all(_this.animateModel, _this.animationSupported).areTruthy();
|
|
5892
7099
|
// Extract our visit model from the place router.
|
|
5893
7100
|
_this._activePlaceDefinition = chain(_this._activePlaceModel).pluck('placeDefinition');
|
|
5894
7101
|
_this.routerVisitModel = _this._activePlaceDefinition.findIn(chain(placeRouter.activeVisitsByPlaceDefinition));
|
|
5895
7102
|
_this.navigationInProgress = chain(_this.placeRouter.navigationInProgress);
|
|
5896
|
-
when
|
|
7103
|
+
when(_this.navigationInProgress).becomesFalsey(function () {
|
|
5897
7104
|
_this.checkStateAndInitialise();
|
|
5898
7105
|
});
|
|
5899
|
-
when
|
|
7106
|
+
when(_this.outletActivated).becomesTruthy(function () {
|
|
5900
7107
|
_this.checkStateAndInitialise();
|
|
5901
7108
|
});
|
|
5902
7109
|
chain(_this._activePlaceModel)
|
|
@@ -5909,7 +7116,7 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5909
7116
|
};
|
|
5910
7117
|
// @Trace()
|
|
5911
7118
|
PlaceOutletComponent.prototype.getAnimationOrder = function () {
|
|
5912
|
-
return this.
|
|
7119
|
+
return this.activePlaceAnimationPosition.value;
|
|
5913
7120
|
};
|
|
5914
7121
|
Object.defineProperty(PlaceOutletComponent.prototype, "animationDuration", {
|
|
5915
7122
|
get: function () {
|
|
@@ -5920,7 +7127,10 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5920
7127
|
});
|
|
5921
7128
|
// @Trace()
|
|
5922
7129
|
PlaceOutletComponent.prototype.navigate = function (visit) {
|
|
5923
|
-
//
|
|
7130
|
+
// const place = this.placesInAnimationOrder.query().findMatching(p => visit.placeDefinition.component === p);
|
|
7131
|
+
// if (!place) {
|
|
7132
|
+
// lang.illegalState()
|
|
7133
|
+
// }
|
|
5924
7134
|
this.placeRouter.navigate(visit, {
|
|
5925
7135
|
relativeTo: this.parentOutlet ? this.parentOutlet.activatedRouteModel.value : null
|
|
5926
7136
|
});
|
|
@@ -5946,14 +7156,25 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5946
7156
|
enumerable: true,
|
|
5947
7157
|
configurable: true
|
|
5948
7158
|
});
|
|
5949
|
-
// @Trace()
|
|
5950
7159
|
PlaceOutletComponent.prototype.onOutletActivated = function (routerOutlet, place) {
|
|
5951
7160
|
this._activatedRouteModel.value = routerOutlet.activatedRoute;
|
|
5952
7161
|
this._activePlaceModel.value = place;
|
|
7162
|
+
this.validateAnimationState(place);
|
|
5953
7163
|
this.outletActivated.value = true;
|
|
5954
7164
|
this.checkStateAndInitialise();
|
|
5955
7165
|
};
|
|
5956
|
-
|
|
7166
|
+
PlaceOutletComponent.prototype.validateAnimationState = function (place) {
|
|
7167
|
+
if (this.animateModel.value) {
|
|
7168
|
+
if (this.placesInAnimationOrder.length < 1) {
|
|
7169
|
+
console.error('PlaceOutlet.animate === true but placeAnimationOrder has not been set. Animation is disabled.');
|
|
7170
|
+
}
|
|
7171
|
+
else {
|
|
7172
|
+
if (!this.placesInAnimationOrder.query().includes(place.placeDefinition.component)) {
|
|
7173
|
+
console.error("PlaceOutlet.animate === true but placeAnimationOrder doesn't contain " + place.placeDefinition.component.name + ".");
|
|
7174
|
+
}
|
|
7175
|
+
}
|
|
7176
|
+
}
|
|
7177
|
+
};
|
|
5957
7178
|
PlaceOutletComponent.prototype.onOutletDeactivated = function () {
|
|
5958
7179
|
this.outletActivated.value = false;
|
|
5959
7180
|
this._activePlaceModel.value = null;
|
|
@@ -5970,7 +7191,6 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5970
7191
|
this.initialisePlace(routerVisit, activePlace);
|
|
5971
7192
|
}
|
|
5972
7193
|
};
|
|
5973
|
-
// @Trace()
|
|
5974
7194
|
PlaceOutletComponent.prototype.initialisePlace = function (routerVisit, activePlace) {
|
|
5975
7195
|
var _this = this;
|
|
5976
7196
|
var visitModel = new MutableValueModel(routerVisit);
|
|
@@ -5978,9 +7198,18 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
5978
7198
|
activePlace.initialiseVisit(routerVisit, function (current, previous) {
|
|
5979
7199
|
_this.pushVisitChangeToRoute(previous, current);
|
|
5980
7200
|
});
|
|
5981
|
-
|
|
5982
|
-
|
|
5983
|
-
|
|
7201
|
+
var finishPlaceLoad = function () {
|
|
7202
|
+
_this._activePlaceModel.value._notifyActive(true);
|
|
7203
|
+
};
|
|
7204
|
+
if (!this.animationEnabled.value || this.isVeryFirstLoad) {
|
|
7205
|
+
// if animation is disabled or this is the very first load then
|
|
7206
|
+
// we won't get our animation done callback so we finish the
|
|
7207
|
+
// process here and now.
|
|
7208
|
+
this.isVeryFirstLoad = false;
|
|
7209
|
+
finishPlaceLoad();
|
|
7210
|
+
}
|
|
7211
|
+
else {
|
|
7212
|
+
this.onAnimationFinishedJob = finishPlaceLoad;
|
|
5984
7213
|
}
|
|
5985
7214
|
var _a = Dsl.disposeWith(activePlace), when = _a.when, chain = _a.chain, valueOf = _a.valueOf;
|
|
5986
7215
|
when.valueOf(this.routerVisitModel)
|
|
@@ -6003,8 +7232,9 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
6003
7232
|
};
|
|
6004
7233
|
// @Trace()
|
|
6005
7234
|
PlaceOutletComponent.prototype.animationDone = function () {
|
|
6006
|
-
if (this.
|
|
6007
|
-
this.
|
|
7235
|
+
if (this.onAnimationFinishedJob) {
|
|
7236
|
+
this.onAnimationFinishedJob();
|
|
7237
|
+
this.onAnimationFinishedJob = undefined;
|
|
6008
7238
|
}
|
|
6009
7239
|
};
|
|
6010
7240
|
PlaceOutletComponent.ctorParameters = function () { return [
|
|
@@ -6037,10 +7267,22 @@ var PlaceOutletComponent = /** @class */ (function (_super) {
|
|
|
6037
7267
|
ViewChild('routeOutlet', { static: true }),
|
|
6038
7268
|
__metadata("design:type", RouterOutlet)
|
|
6039
7269
|
], PlaceOutletComponent.prototype, "routerOut", void 0);
|
|
7270
|
+
__decorate([
|
|
7271
|
+
Trace(),
|
|
7272
|
+
__metadata("design:type", Function),
|
|
7273
|
+
__metadata("design:paramtypes", [RouterOutlet, PlaceComponent]),
|
|
7274
|
+
__metadata("design:returntype", void 0)
|
|
7275
|
+
], PlaceOutletComponent.prototype, "onOutletActivated", null);
|
|
7276
|
+
__decorate([
|
|
7277
|
+
Trace(),
|
|
7278
|
+
__metadata("design:type", Function),
|
|
7279
|
+
__metadata("design:paramtypes", []),
|
|
7280
|
+
__metadata("design:returntype", void 0)
|
|
7281
|
+
], PlaceOutletComponent.prototype, "onOutletDeactivated", null);
|
|
6040
7282
|
PlaceOutletComponent = __decorate([
|
|
6041
7283
|
Component({
|
|
6042
7284
|
selector: 'aup-place-outlet',
|
|
6043
|
-
template: "<ng-container *ngIf=\"
|
|
7285
|
+
template: "<ng-container *ngIf=\"animationEnabled.value\">\n <div class=\"router-outlet-container\" 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\" cdkScrollable>\n <router-outlet #routerOutlet=\"outlet\"\n (activate)=\"onOutletActivated(routerOutlet, $event)\"\n (deactivate)=\"onOutletDeactivated()\">\n </router-outlet>\n </div>\n</ng-container>\n\n",
|
|
6044
7286
|
animations: [LEFT_RIGHT_PLACE_ANIMATION],
|
|
6045
7287
|
styles: [":host{display:flex;flex-direction:column;min-height:0}.router-outlet-container{flex:1;display:block;position:relative;min-height:0;overflow-x:hidden;overflow-y:scroll}router-outlet{display:none}"]
|
|
6046
7288
|
}),
|
|
@@ -6071,10 +7313,10 @@ var AbstractPlaceNavigationComponent = /** @class */ (function (_super) {
|
|
|
6071
7313
|
_this.activePlaceDefinition = chain(_this._activePlaceComponent).pluck('placeDefinition');
|
|
6072
7314
|
return _this;
|
|
6073
7315
|
}
|
|
6074
|
-
AbstractPlaceNavigationComponent.prototype.
|
|
7316
|
+
AbstractPlaceNavigationComponent.prototype.getNavigationFace = function (placeDef) {
|
|
6075
7317
|
var navItem = placeDef.getPlaceData('nav');
|
|
6076
7318
|
return {
|
|
6077
|
-
|
|
7319
|
+
text: function () { return navItem ? navItem.title() : placeDef.searchPlaceData(['navTitle', 'title']); },
|
|
6078
7320
|
tooltip: function () { return navItem && navItem.tooltip ? navItem.tooltip() : placeDef.getPlaceData('navTooltip', null); },
|
|
6079
7321
|
icon: function () { return navItem && navItem.icon ? navItem.icon() : placeDef.getPlaceData('navIcon', null); }
|
|
6080
7322
|
};
|
|
@@ -6108,7 +7350,7 @@ var AbstractPlaceNavigationComponent = /** @class */ (function (_super) {
|
|
|
6108
7350
|
__metadata("design:type", Function),
|
|
6109
7351
|
__metadata("design:paramtypes", [PlaceDefinition]),
|
|
6110
7352
|
__metadata("design:returntype", Object)
|
|
6111
|
-
], AbstractPlaceNavigationComponent.prototype, "
|
|
7353
|
+
], AbstractPlaceNavigationComponent.prototype, "getNavigationFace", null);
|
|
6112
7354
|
AbstractPlaceNavigationComponent = __decorate([
|
|
6113
7355
|
Component({
|
|
6114
7356
|
template: ''
|
|
@@ -6169,7 +7411,7 @@ var ListPlaceNavComponent = /** @class */ (function (_super) {
|
|
|
6169
7411
|
ListPlaceNavComponent = __decorate([
|
|
6170
7412
|
Component({
|
|
6171
7413
|
selector: 'aup-list-place-nav',
|
|
6172
|
-
template: "<mat-nav-list fxFlex>\n <a mat-list-item *ngFor=\"let placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [class.active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"
|
|
7414
|
+
template: "<mat-nav-list fxFlex>\n <a mat-list-item *ngFor=\"let placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [class.active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"getNavigationFace(placeDefinition).tooltip()\">\n <aup-command-face [face]=\"getNavigationFace(placeDefinition)\"></aup-command-face>\n </a>\n</mat-nav-list>\n",
|
|
6173
7415
|
styles: [":host{display:flex;flex-direction:column;--selected-border-color:#838383;--selected-color:inherit;--selected-background:#f1f1f1}mat-nav-list{padding-top:0}a.active{border-right:2px solid var(--selected-border-color);background:var(--selected-background);color:var(--selected-color)}"]
|
|
6174
7416
|
}),
|
|
6175
7417
|
__metadata("design:paramtypes", [PlaceRouter])
|
|
@@ -6177,25 +7419,6 @@ var ListPlaceNavComponent = /** @class */ (function (_super) {
|
|
|
6177
7419
|
return ListPlaceNavComponent;
|
|
6178
7420
|
}(AbstractPlaceNavigationComponent));
|
|
6179
7421
|
|
|
6180
|
-
var TabbedPlaceNavigationComponent = /** @class */ (function (_super) {
|
|
6181
|
-
__extends(TabbedPlaceNavigationComponent, _super);
|
|
6182
|
-
function TabbedPlaceNavigationComponent(placeRouter) {
|
|
6183
|
-
return _super.call(this, placeRouter) || this;
|
|
6184
|
-
}
|
|
6185
|
-
TabbedPlaceNavigationComponent.ctorParameters = function () { return [
|
|
6186
|
-
{ type: PlaceRouter }
|
|
6187
|
-
]; };
|
|
6188
|
-
TabbedPlaceNavigationComponent = __decorate([
|
|
6189
|
-
Component({
|
|
6190
|
-
selector: 'aup-tabbed-place-navigation',
|
|
6191
|
-
template: "<nav mat-tab-nav-bar>\n <a mat-tab-link *ngFor=\"let placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"getNav(placeDefinition).tooltip()\">\n <aup-icon *ngIf=\"getNav(placeDefinition).icon()\" [icon]=\"getNav(placeDefinition).icon()\"></aup-icon>\n <span>{{getNav(placeDefinition).title()}}</span>\n </a>\n</nav>\n",
|
|
6192
|
-
styles: [""]
|
|
6193
|
-
}),
|
|
6194
|
-
__metadata("design:paramtypes", [PlaceRouter])
|
|
6195
|
-
], TabbedPlaceNavigationComponent);
|
|
6196
|
-
return TabbedPlaceNavigationComponent;
|
|
6197
|
-
}(AbstractPlaceNavigationComponent));
|
|
6198
|
-
|
|
6199
7422
|
/**
|
|
6200
7423
|
* @example
|
|
6201
7424
|
* // Usage
|
|
@@ -6234,7 +7457,7 @@ var TabbedPlaceNavigationComponent = /** @class */ (function (_super) {
|
|
|
6234
7457
|
* (at)Place({
|
|
6235
7458
|
* path: 'myPlace',
|
|
6236
7459
|
* data: {
|
|
6237
|
-
* nav: I18n.places.myPlace.nav
|
|
7460
|
+
* nav: I18n.places.myPlace.nav
|
|
6238
7461
|
* }
|
|
6239
7462
|
* })
|
|
6240
7463
|
*/
|
|
@@ -6270,7 +7493,7 @@ var SidePlaceNavigationComponent = /** @class */ (function (_super) {
|
|
|
6270
7493
|
SidePlaceNavigationComponent = __decorate([
|
|
6271
7494
|
Component({
|
|
6272
7495
|
selector: 'aup-side-place-navigation',
|
|
6273
|
-
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 placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [class.active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"
|
|
7496
|
+
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 placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [class.active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"getNavigationFace(placeDefinition).tooltip()\">\n <aup-icon *ngIf=\"getNavigationFace(placeDefinition).icon()\" [icon]=\"getNavigationFace(placeDefinition).icon()\"></aup-icon>\n <span class=\"expanded-only\">{{getNavigationFace(placeDefinition).text()}}</span>\n </a>\n <span [style.flex]=\"1\"></span>\n <ng-container *ngIf=\"navEndTemplate\" [ngTemplateOutlet]=\"navEndTemplate\"></ng-container>\n</mat-nav-list>\n",
|
|
6274
7497
|
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, 0.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)}"]
|
|
6275
7498
|
}),
|
|
6276
7499
|
__metadata("design:paramtypes", [Router, PlaceRouter])
|
|
@@ -6278,6 +7501,25 @@ var SidePlaceNavigationComponent = /** @class */ (function (_super) {
|
|
|
6278
7501
|
return SidePlaceNavigationComponent;
|
|
6279
7502
|
}(AbstractPlaceNavigationComponent));
|
|
6280
7503
|
|
|
7504
|
+
var TabbedPlaceNavigationComponent = /** @class */ (function (_super) {
|
|
7505
|
+
__extends(TabbedPlaceNavigationComponent, _super);
|
|
7506
|
+
function TabbedPlaceNavigationComponent(placeRouter) {
|
|
7507
|
+
return _super.call(this, placeRouter) || this;
|
|
7508
|
+
}
|
|
7509
|
+
TabbedPlaceNavigationComponent.ctorParameters = function () { return [
|
|
7510
|
+
{ type: PlaceRouter }
|
|
7511
|
+
]; };
|
|
7512
|
+
TabbedPlaceNavigationComponent = __decorate([
|
|
7513
|
+
Component({
|
|
7514
|
+
selector: 'aup-tabbed-place-navigation',
|
|
7515
|
+
template: "<nav mat-tab-nav-bar>\n <a mat-tab-link *ngFor=\"let placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"getNavigationFace(placeDefinition).tooltip()\">\n <aup-command-face [face]=\"getNavigationFace(placeDefinition)\"></aup-command-face>\n </a>\n</nav>\n",
|
|
7516
|
+
styles: [""]
|
|
7517
|
+
}),
|
|
7518
|
+
__metadata("design:paramtypes", [PlaceRouter])
|
|
7519
|
+
], TabbedPlaceNavigationComponent);
|
|
7520
|
+
return TabbedPlaceNavigationComponent;
|
|
7521
|
+
}(AbstractPlaceNavigationComponent));
|
|
7522
|
+
|
|
6281
7523
|
var PlaceModule = /** @class */ (function () {
|
|
6282
7524
|
function PlaceModule() {
|
|
6283
7525
|
}
|
|
@@ -6824,8 +8066,7 @@ function installMechanics(prototype, propertyKey, backingModel, tagPrefix, isEmp
|
|
|
6824
8066
|
binding: null
|
|
6825
8067
|
};
|
|
6826
8068
|
var tag = tagPrefix + "(" + prototype.constructor.name + "." + propertyKey.toString() + ")";
|
|
6827
|
-
DebugContext.
|
|
6828
|
-
Logger.get(mechanics.backingModel).tag(tag);
|
|
8069
|
+
DebugContext.getOrCreate(mechanics.backingModel).tag(tag);
|
|
6829
8070
|
Object.defineProperty(prototype, propertyKey, {
|
|
6830
8071
|
get: function () {
|
|
6831
8072
|
return mechanics.backingModel;
|
|
@@ -6887,5 +8128,5 @@ function VisitParameterList(options) {
|
|
|
6887
8128
|
* Generated bundle index. Do not edit.
|
|
6888
8129
|
*/
|
|
6889
8130
|
|
|
6890
|
-
export { ACTIVITY_DATA, AUP_PLACE_CONFIG, AbstractInputActivity, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityContainerComponent, ActivityOutletComponent, ActivityRef, AddItemInteractionContextComponent, AlertDialogComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CellEditorPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnModel, ColumnTemplateDirective, CommandDirective, ComponentCellRendererPortalRef, ComponentsModule, ConfirmThenDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControls, EditSession, EditorControlColumnModel, EmptyStateComponent, EventCleanUpSession, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, Formatter, HEADER_CELL_RENDERER_PORTAL, IconComponent, InPlaceInteractionContextComponent, InteractionContextTriggerFor, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, LEFT_RIGHT_PLACE_ANIMATION, ListPlaceNavComponent, ListPropertyColumnModel, ModalInteractionContextFactory, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NumberInputComponent, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, ParameterDefinition, PasswordInputComponent, Place, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupInteractionContextComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, RouteId, ScrollContainerComponent, SectionHeaderComponent, SelectCellRendererComponent, SelectHeaderCellRendererComponent, SelectInputActivity, SelectInputComponent, SelectionColumnModel, SidePlaceNavigationComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableCellRendererComponent, TableComponent, TableHeaderCellRendererComponent, TableModel, TemplateCellRendererPortalRef, TextInputComponent, UrlService, UrlSnapshot, VerticalFocusContainerComponent, Visit, VisitParameter, VisitParameterList, VisitSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationEventsFinish, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, slideDownOnEnterAnimation, slideRightOnEnterAnimation, ɵ0, DirectivesModule as ɵa, CommandDirective as ɵb, CardContainerComponent as ɵba, TableComponent as ɵbb, EditRowControls as ɵbc, ColumnTemplateDirective as ɵbd, DefaultCellRendererComponent as ɵbe, TableCellRendererComponent as ɵbf, SelectCellRendererComponent as ɵbg, SelectHeaderCellRendererComponent as ɵbh, DefaultHeaderCellRendererComponent as ɵbi, TableHeaderCellRendererComponent as ɵbj, IconComponent as ɵbk, SectionHeaderComponent as ɵbl,
|
|
8131
|
+
export { ACTIVITY_DATA, AUP_PLACE_CONFIG, AbstractInputActivity, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityContainerComponent, ActivityOutletComponent, ActivityRef, AddItemInteractionContextComponent, AlertDialogComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CellEditorPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnModel, ColumnTemplateDirective, CommandComponent, CommandDirective, CommandFace, CommandFaceComponent, CommandGroup, CommandGroupComponent, CommandGroupMenuRendererComponent, CommandGroupRendererComponent, ComponentCellRendererPortalRef, ComponentsModule, ConfirmThenDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControls, EditSession, EditorControlColumnModel, EmptyStateComponent, EventCleanUpSession, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, Formatter, HEADER_CELL_RENDERER_PORTAL, IconComponent, InPlaceInteractionContextComponent, InteractionContextTriggerFor, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, LEFT_RIGHT_PLACE_ANIMATION, ListPlaceNavComponent, ListPropertyColumnModel, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NumberInputComponent, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, ParameterDefinition, PasswordInputComponent, Place, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupInteractionContextComponent, PopupMenuComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, Registration, 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, UrlService, UrlSnapshot, VerticalFocusContainerComponent, ViewData, Visit, VisitParameter, VisitParameterList, VisitSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationEventsFinish, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, slideDownOnEnterAnimation, slideRightOnEnterAnimation, ɵ0, DirectivesModule as ɵa, CommandDirective as ɵb, CardContainerComponent as ɵba, TableComponent as ɵbb, EditRowControls as ɵbc, ColumnTemplateDirective as ɵbd, DefaultCellRendererComponent as ɵbe, TableCellRendererComponent as ɵbf, SelectCellRendererComponent as ɵbg, SelectHeaderCellRendererComponent as ɵbh, DefaultHeaderCellRendererComponent as ɵbi, TableHeaderCellRendererComponent as ɵbj, IconComponent as ɵbk, SectionHeaderComponent as ɵbl, TableRowMenuComponent as ɵbm, ToolBarComponent as ɵbn, CommandGroup as ɵbo, CommandComponent as ɵbp, PopupMenuComponent as ɵbq, CommandGroupComponent as ɵbr, CommandFaceComponent as ɵbs, MoreMenuComponent as ɵbt, SeparatorComponent as ɵbu, FlexComponent as ɵbv, CommandGroupMenuRendererComponent as ɵbw, CommandGroupRendererComponent as ɵbx, PlaceModule as ɵby, ComponentsModule as ɵbz, FocusBindingDirective as ɵc, EmptyStateComponent as ɵca, BusyOverlayComponent as ɵcb, PlaceOutletComponent as ɵcc, leftRightPlaceAnimation as ɵcd, LEFT_RIGHT_PLACE_ANIMATION as ɵce, AUP_PLACE_CONFIG as ɵcf, PlaceRouter as ɵch, InteractionService as ɵci, ModalInteractionContextFactory as ɵcj, UrlService as ɵck, PlaceHistory as ɵcl, TabbedPlaceNavigationComponent as ɵcm, AbstractPlaceNavigationComponent as ɵcn, ListPlaceNavComponent as ɵco, SidePlaceNavigationComponent as ɵcp, InteractionModule as ɵcq, ActivityContainerComponent as ɵcr, AbstractInteractionContext as ɵcs, ActivityOutletComponent as ɵct, ConfirmationDialogComponent as ɵcu, ACTIVITY_DATA as ɵcv, Activity as ɵcw, ConfirmThenDialogComponent as ɵcy, AlertDialogComponent as ɵcz, DisposableComponent as ɵd, InPlaceInteractionContextComponent as ɵdb, AddItemInteractionContextComponent as ɵdc, ActivityActionsComponent as ɵdd, PopupInteractionContextComponent as ɵde, StringInputActivity as ɵdf, AbstractInputActivity as ɵdg, SelectInputActivity as ɵdh, InteractionContextTriggerFor as ɵdi, FocusBindingFactory as ɵe, ComponentsModule as ɵf, AbstractInputComponent as ɵg, AbstractValueInputComponent as ɵh, AbstractListInputComponent as ɵi, NumberInputComponent as ɵj, StringInputComponent as ɵk, TextInputComponent as ɵl, PasswordInputComponent as ɵm, SelectInputComponent as ɵn, MultipleSelectInputComponent as ɵo, AutocompleteInputComponent as ɵp, CheckboxInputComponent as ɵq, ScrollContainerComponent as ɵr, NoopComponent as ɵs, SwitchCaseOption as ɵt, SwitchCaseWhenDirective as ɵu, SwitchCaseDefaultDirective as ɵv, SwitchCaseComponent as ɵw, FocusContainerComponent as ɵx, VerticalFocusContainerComponent as ɵy, FocusableComponent as ɵz };
|
|
6891
8132
|
//# sourceMappingURL=coolon-angular-ui-powerups.js.map
|