@coolon/angular-ui-powerups 1.3.7 → 1.4.1

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.
Files changed (48) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/bundles/coolon-angular-ui-powerups.umd.js +123 -46
  3. package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
  4. package/bundles/coolon-angular-ui-powerups.umd.min.js +1 -1
  5. package/bundles/coolon-angular-ui-powerups.umd.min.js.map +1 -1
  6. package/coolon-angular-ui-powerups.d.ts +27 -26
  7. package/coolon-angular-ui-powerups.metadata.json +1 -1
  8. package/esm2015/coolon-angular-ui-powerups.js +25 -24
  9. package/esm2015/coolon-angular-ui-powerups.js.map +1 -1
  10. package/esm2015/coolon-angular-ui-powerups.metadata.json +1 -1
  11. package/esm2015/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
  12. package/esm2015/lib/components/components.module.js +3 -0
  13. package/esm2015/lib/components/components.module.js.map +1 -1
  14. package/esm2015/lib/components/components.module.metadata.json +1 -1
  15. package/esm2015/lib/components/components.module.ngfactory.js.map +1 -1
  16. package/esm2015/lib/components/focus-container/focus-container.component.js +8 -10
  17. package/esm2015/lib/components/focus-container/focus-container.component.js.map +1 -1
  18. package/esm2015/lib/components/focus-container/focus-container.component.metadata.json +1 -1
  19. package/esm2015/lib/components/index.js +1 -0
  20. package/esm2015/lib/components/index.js.map +1 -1
  21. package/esm2015/lib/components/index.metadata.json +1 -1
  22. package/esm2015/lib/components/vertical-focus-container/vertical-focus-container.component.js +77 -0
  23. package/esm2015/lib/components/vertical-focus-container/vertical-focus-container.component.js.map +1 -0
  24. package/esm2015/lib/components/vertical-focus-container/vertical-focus-container.component.metadata.json +1 -0
  25. package/esm2015/lib/components/vertical-focus-container/vertical-focus-container.component.ngfactory.js.map +1 -0
  26. package/esm2015/lib/components/vertical-focus-container/vertical-focus-container.component.scss.shim.ngstyle.js.map +1 -0
  27. package/esm5/coolon-angular-ui-powerups.js +25 -24
  28. package/esm5/coolon-angular-ui-powerups.js.map +1 -1
  29. package/esm5/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
  30. package/esm5/lib/components/components.module.js +3 -0
  31. package/esm5/lib/components/components.module.js.map +1 -1
  32. package/esm5/lib/components/components.module.ngfactory.js.map +1 -1
  33. package/esm5/lib/components/focus-container/focus-container.component.js +8 -10
  34. package/esm5/lib/components/focus-container/focus-container.component.js.map +1 -1
  35. package/esm5/lib/components/index.js +1 -0
  36. package/esm5/lib/components/index.js.map +1 -1
  37. package/esm5/lib/components/vertical-focus-container/vertical-focus-container.component.js +80 -0
  38. package/esm5/lib/components/vertical-focus-container/vertical-focus-container.component.js.map +1 -0
  39. package/esm5/lib/components/vertical-focus-container/vertical-focus-container.component.ngfactory.js.map +1 -0
  40. package/esm5/lib/components/vertical-focus-container/vertical-focus-container.component.scss.shim.ngstyle.js.map +1 -0
  41. package/fesm2015/coolon-angular-ui-powerups.js +83 -11
  42. package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
  43. package/fesm5/coolon-angular-ui-powerups.js +86 -11
  44. package/fesm5/coolon-angular-ui-powerups.js.map +1 -1
  45. package/lib/components/focus-container/focus-container.component.d.ts +2 -1
  46. package/lib/components/index.d.ts +1 -0
  47. package/lib/components/vertical-focus-container/vertical-focus-container.component.d.ts +10 -0
  48. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -2,6 +2,20 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [1.4.1](https://bitbucket.org/coolon/angular-ui-powerups/compare/v1.4.0...v1.4.1) (2020-05-21)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * removed arrowLeft/Right commands as they broke manual key bindings ([4aa5227](https://bitbucket.org/coolon/angular-ui-powerups/commit/4aa52274046db45a9dbba869bc85a0e1cca72073))
11
+
12
+ ## [1.4.0](https://bitbucket.org/coolon/angular-ui-powerups/compare/v1.3.7...v1.4.0) (2020-05-21)
13
+
14
+
15
+ ### Features
16
+
17
+ * added VerticalFocusContainer component ([6fa2adc](https://bitbucket.org/coolon/angular-ui-powerups/commit/6fa2adc6365f113f7c350a681c5f57b49d21eaf2))
18
+
5
19
  ### [1.3.7](https://bitbucket.org/coolon/angular-ui-powerups/compare/v1.3.6...v1.3.7) (2020-05-20)
6
20
 
7
21
  ### [1.3.6](https://bitbucket.org/coolon/angular-ui-powerups/compare/v1.3.5...v1.3.6) (2020-05-20)
@@ -544,27 +544,25 @@
544
544
  function FocusContainerComponent(focusManager) {
545
545
  var _this = _super.call(this) || this;
546
546
  _this.focusManager = focusManager;
547
+ _this.restoreFocusCommand = pectin.Command.create(function () {
548
+ _this.restoreFocus();
549
+ });
547
550
  _this.tabIndex = -1;
548
551
  return _this;
549
552
  }
550
553
  FocusContainerComponent.prototype.ngOnInit = function () {
551
554
  };
555
+ // @Trace()
552
556
  FocusContainerComponent.prototype.restoreFocus = function () {
553
557
  this.focusManager.restoreFocus();
554
558
  };
555
559
  FocusContainerComponent.ctorParameters = function () { return [
556
- { type: pectin.FocusManager, decorators: [{ type: core.Host }] }
560
+ { type: pectin.FocusManager, decorators: [{ type: core.Self }] }
557
561
  ]; };
558
562
  __decorate([
559
563
  core.HostBinding('attr.tabindex'),
560
564
  __metadata("design:type", Object)
561
565
  ], FocusContainerComponent.prototype, "tabIndex", void 0);
562
- __decorate([
563
- pectin.Trace(),
564
- __metadata("design:type", Function),
565
- __metadata("design:paramtypes", []),
566
- __metadata("design:returntype", void 0)
567
- ], FocusContainerComponent.prototype, "restoreFocus", null);
568
566
  FocusContainerComponent = __decorate([
569
567
  core.Component({
570
568
  selector: 'aup-focus-container',
@@ -574,7 +572,7 @@
574
572
  ],
575
573
  styles: [":host{display:block}"]
576
574
  }),
577
- __param(0, core.Host()),
575
+ __param(0, core.Self()),
578
576
  __metadata("design:paramtypes", [pectin.FocusManager])
579
577
  ], FocusContainerComponent);
580
578
  return FocusContainerComponent;
@@ -1138,6 +1136,81 @@
1138
1136
  return SwitchCaseComponent;
1139
1137
  }(DisposableComponent));
1140
1138
 
1139
+ var VerticalFocusContainerComponent = /** @class */ (function (_super) {
1140
+ __extends(VerticalFocusContainerComponent, _super);
1141
+ function VerticalFocusContainerComponent(focusManager) {
1142
+ var _this = _super.call(this, focusManager) || this;
1143
+ _this.focusManager = focusManager;
1144
+ return _this;
1145
+ }
1146
+ // The key listeners seem to be preventing manual binding
1147
+ // @Input('command.arrowRight')
1148
+ // @TrackExternal()
1149
+ // rightArrowCommand: Command<void>;
1150
+ //
1151
+ // @Input('command.arrowLeft')
1152
+ // @TrackExternal()
1153
+ // leftArrowCommand: Command<void>;
1154
+ //
1155
+ // @HostListener('keyup.arrowLeft', ['$event'])
1156
+ // arrowLeft(event: KeyboardEvent) {
1157
+ // if (this.leftArrowCommand.enabled.value) {
1158
+ // event.preventDefault();
1159
+ // event.stopPropagation();
1160
+ // this.leftArrowCommand.execute();
1161
+ // }
1162
+ // }
1163
+ //
1164
+ // @HostListener('keyup.arrowRight', ['$event'])
1165
+ // arrowRight(event: KeyboardEvent) {
1166
+ // if (this.rightArrowCommand.enabled.value) {
1167
+ // event.preventDefault();
1168
+ // event.stopPropagation();
1169
+ // this.rightArrowCommand.execute();
1170
+ // }
1171
+ // }
1172
+ VerticalFocusContainerComponent.prototype.arrowDown = function (event) {
1173
+ event.preventDefault();
1174
+ event.stopPropagation();
1175
+ this.focusManager.focusNext();
1176
+ };
1177
+ VerticalFocusContainerComponent.prototype.arrowUp = function (event) {
1178
+ event.preventDefault();
1179
+ event.stopPropagation();
1180
+ this.focusManager.focusPrevious();
1181
+ };
1182
+ VerticalFocusContainerComponent.prototype.ngOnInit = function () {
1183
+ };
1184
+ VerticalFocusContainerComponent.ctorParameters = function () { return [
1185
+ { type: pectin.FocusManager, decorators: [{ type: core.Self }] }
1186
+ ]; };
1187
+ __decorate([
1188
+ core.HostListener('keyup.arrowDown', ['$event']),
1189
+ __metadata("design:type", Function),
1190
+ __metadata("design:paramtypes", [KeyboardEvent]),
1191
+ __metadata("design:returntype", void 0)
1192
+ ], VerticalFocusContainerComponent.prototype, "arrowDown", null);
1193
+ __decorate([
1194
+ core.HostListener('keyup.arrowUp', ['$event']),
1195
+ __metadata("design:type", Function),
1196
+ __metadata("design:paramtypes", [KeyboardEvent]),
1197
+ __metadata("design:returntype", void 0)
1198
+ ], VerticalFocusContainerComponent.prototype, "arrowUp", null);
1199
+ VerticalFocusContainerComponent = __decorate([
1200
+ core.Component({
1201
+ selector: 'aup-vertical-focus-container',
1202
+ template: "<ng-content></ng-content>\n",
1203
+ providers: [
1204
+ { provide: pectin.FocusManager }
1205
+ ],
1206
+ styles: [":host{display:block}"]
1207
+ }),
1208
+ __param(0, core.Self()),
1209
+ __metadata("design:paramtypes", [pectin.FocusManager])
1210
+ ], VerticalFocusContainerComponent);
1211
+ return VerticalFocusContainerComponent;
1212
+ }(FocusContainerComponent));
1213
+
1141
1214
  var ComponentsModule = /** @class */ (function () {
1142
1215
  function ComponentsModule() {
1143
1216
  }
@@ -1156,6 +1229,7 @@
1156
1229
  SwitchCaseWhenDirective,
1157
1230
  SwitchCaseDefaultDirective,
1158
1231
  FocusContainerComponent,
1232
+ VerticalFocusContainerComponent,
1159
1233
  FocusableComponent
1160
1234
  ],
1161
1235
  imports: [
@@ -1183,6 +1257,7 @@
1183
1257
  SwitchCaseWhenDirective,
1184
1258
  SwitchCaseDefaultDirective,
1185
1259
  FocusContainerComponent,
1260
+ VerticalFocusContainerComponent,
1186
1261
  FocusableComponent
1187
1262
  ],
1188
1263
  providers: [
@@ -1730,7 +1805,7 @@
1730
1805
  }());
1731
1806
 
1732
1807
  var inplaceMonitorCount = 0;
1733
- exports.ɵbd = /** @class */ (function () {
1808
+ exports.ɵbe = /** @class */ (function () {
1734
1809
  function InteractionService(modelInteractionContextFactory) {
1735
1810
  this.modelInteractionContextFactory = modelInteractionContextFactory;
1736
1811
  this.garbage = new pectin.GarbageCollector();
@@ -1890,7 +1965,7 @@
1890
1965
  return ApiAdapter;
1891
1966
  }());
1892
1967
  InteractionService.ApiAdapter = ApiAdapter;
1893
- })(exports.ɵbd || (exports.ɵbd = {}));
1968
+ })(exports.ɵbe || (exports.ɵbe = {}));
1894
1969
 
1895
1970
  var InPlaceInteractionContextComponent = /** @class */ (function (_super) {
1896
1971
  __extends(InPlaceInteractionContextComponent, _super);
@@ -1934,7 +2009,7 @@
1934
2009
  return this.activityContainerComponent.startActivity(activityType, data);
1935
2010
  };
1936
2011
  InPlaceInteractionContextComponent.ctorParameters = function () { return [
1937
- { type: exports.ɵbd }
2012
+ { type: exports.ɵbe }
1938
2013
  ]; };
1939
2014
  __decorate([
1940
2015
  core.ViewChild('activityContainer', { static: true }),
@@ -1946,7 +2021,7 @@
1946
2021
  template: "<mat-tab-group no-tab-header [selectedIndex]=\"isActive() ? 1 : 0\" full-height-tabs [dynamicHeight]=\"false\">\n <mat-tab>\n <ng-content></ng-content>\n </mat-tab>\n <mat-tab>\n <aup-activity-container #activityContainer [dynamicHeight]=\"false\"></aup-activity-container>\n </mat-tab>\n</mat-tab-group>\n\n",
1947
2022
  styles: [":host{display:flex;flex-direction:column}mat-tab-group{flex:1}"]
1948
2023
  }),
1949
- __metadata("design:paramtypes", [exports.ɵbd])
2024
+ __metadata("design:paramtypes", [exports.ɵbe])
1950
2025
  ], InPlaceInteractionContextComponent);
1951
2026
  return InPlaceInteractionContextComponent;
1952
2027
  }(DisposableComponent));
@@ -1984,7 +2059,7 @@
1984
2059
  AlertDialogComponent
1985
2060
  ],
1986
2061
  providers: [
1987
- exports.ɵbd,
2062
+ exports.ɵbe,
1988
2063
  ]
1989
2064
  })
1990
2065
  ], InteractionModule);
@@ -3103,7 +3178,7 @@
3103
3178
  return PopStateNavigation;
3104
3179
  }(AbstractPopStateNavigation));
3105
3180
 
3106
- exports.ɵbg = /** @class */ (function () {
3181
+ exports.ɵbh = /** @class */ (function () {
3107
3182
  function PlaceHistory() {
3108
3183
  this._archive = new Map();
3109
3184
  this.placeHistoryDepth = 4;
@@ -3240,7 +3315,7 @@
3240
3315
  // }
3241
3316
  //
3242
3317
  // }
3243
- })(exports.ɵbg || (exports.ɵbg = {}));
3318
+ })(exports.ɵbh || (exports.ɵbh = {}));
3244
3319
 
3245
3320
  exports.UrlSnapshot = /** @class */ (function () {
3246
3321
  // TODO: Update this accept a url Parser so it can be immutable and generate new trees on mutation using toString() are parseUrl.
@@ -3763,11 +3838,11 @@
3763
3838
  PlaceRouter.ctorParameters = function () { return [
3764
3839
  { type: router.Router },
3765
3840
  { type: common.Location },
3766
- { type: exports.ɵbd },
3841
+ { type: exports.ɵbe },
3767
3842
  { type: UrlService },
3768
- { type: exports.ɵbg }
3843
+ { type: exports.ɵbh }
3769
3844
  ]; };
3770
- PlaceRouter.ɵprov = core.ɵɵdefineInjectable({ factory: function PlaceRouter_Factory() { return new PlaceRouter(core.ɵɵinject(router.Router), core.ɵɵinject(common.Location), core.ɵɵinject(exports.ɵbd), core.ɵɵinject(UrlService), core.ɵɵinject(exports.ɵbg)); }, token: PlaceRouter, providedIn: "root" });
3845
+ PlaceRouter.ɵprov = core.ɵɵdefineInjectable({ factory: function PlaceRouter_Factory() { return new PlaceRouter(core.ɵɵinject(router.Router), core.ɵɵinject(common.Location), core.ɵɵinject(exports.ɵbe), core.ɵɵinject(UrlService), core.ɵɵinject(exports.ɵbh)); }, token: PlaceRouter, providedIn: "root" });
3771
3846
  __decorate([
3772
3847
  pectin.Trace(),
3773
3848
  __metadata("design:type", Function),
@@ -3780,9 +3855,9 @@
3780
3855
  }),
3781
3856
  __metadata("design:paramtypes", [router.Router,
3782
3857
  common.Location,
3783
- exports.ɵbd,
3858
+ exports.ɵbe,
3784
3859
  UrlService,
3785
- exports.ɵbg])
3860
+ exports.ɵbh])
3786
3861
  ], PlaceRouter);
3787
3862
  return PlaceRouter;
3788
3863
  }(pectin.GarbageCollector));
@@ -4932,7 +5007,7 @@
4932
5007
  exports.FocusableComponent = FocusableComponent;
4933
5008
  exports.InPlaceInteractionContextComponent = InPlaceInteractionContextComponent;
4934
5009
  exports.InteractionModule = InteractionModule;
4935
- exports.InteractionService = exports.ɵbd;
5010
+ exports.InteractionService = exports.ɵbe;
4936
5011
  exports.InteractionServiceRoutingAdapter = InteractionServiceRoutingAdapter;
4937
5012
  exports.LEFT_RIGHT_PLACE_ANIMATION = LEFT_RIGHT_PLACE_ANIMATION;
4938
5013
  exports.ListPlaceNavComponent = ListPlaceNavComponent;
@@ -4948,7 +5023,7 @@
4948
5023
  exports.PlaceComponentDeactivationHandler = PlaceComponentDeactivationHandler;
4949
5024
  exports.PlaceDefinition = PlaceDefinition;
4950
5025
  exports.PlaceGuard = PlaceGuard;
4951
- exports.PlaceHistory = exports.ɵbg;
5026
+ exports.PlaceHistory = exports.ɵbh;
4952
5027
  exports.PlaceModule = PlaceModule;
4953
5028
  exports.PlaceOutletComponent = PlaceOutletComponent;
4954
5029
  exports.PlaceRouter = PlaceRouter;
@@ -4969,6 +5044,7 @@
4969
5044
  exports.SynchroniseInteractionContextIdsWithRoute = SynchroniseInteractionContextIdsWithRoute;
4970
5045
  exports.TabbedPlaceNavigationComponent = TabbedPlaceNavigationComponent;
4971
5046
  exports.UrlService = UrlService;
5047
+ exports.VerticalFocusContainerComponent = VerticalFocusContainerComponent;
4972
5048
  exports.Visit = Visit;
4973
5049
  exports.VisitParameter = VisitParameter;
4974
5050
  exports.VisitParameterList = VisitParameterList;
@@ -4981,23 +5057,24 @@
4981
5057
  exports.slideRightOnEnterAnimation = slideRightOnEnterAnimation;
4982
5058
  exports.ɵa = DirectivesModule;
4983
5059
  exports.ɵb = CommandDirective;
4984
- exports.ɵba = AUP_PLACE_CONFIG;
4985
- exports.ɵbc = PlaceRouter;
4986
- exports.ɵbe = ModalInteractionContextFactory;
4987
- exports.ɵbf = UrlService;
4988
- exports.ɵbh = TabbedPlaceNavigationComponent;
4989
- exports.ɵbi = AbstractPlaceNavigationComponent;
4990
- exports.ɵbj = ListPlaceNavComponent;
4991
- exports.ɵbk = InteractionModule;
4992
- exports.ɵbl = ActivityContainerComponent;
4993
- exports.ɵbm = AbstractInteractionContext;
4994
- exports.ɵbn = ActivityOutletComponent;
4995
- exports.ɵbo = ConfirmationDialogComponent;
4996
- exports.ɵbp = ACTIVITY_DATA;
4997
- exports.ɵbq = Activity;
4998
- exports.ɵbs = ConfirmThenDialogComponent;
4999
- exports.ɵbt = AlertDialogComponent;
5000
- exports.ɵbv = InPlaceInteractionContextComponent;
5060
+ exports.ɵba = LEFT_RIGHT_PLACE_ANIMATION;
5061
+ exports.ɵbb = AUP_PLACE_CONFIG;
5062
+ exports.ɵbd = PlaceRouter;
5063
+ exports.ɵbf = ModalInteractionContextFactory;
5064
+ exports.ɵbg = UrlService;
5065
+ exports.ɵbi = TabbedPlaceNavigationComponent;
5066
+ exports.ɵbj = AbstractPlaceNavigationComponent;
5067
+ exports.ɵbk = ListPlaceNavComponent;
5068
+ exports.ɵbl = InteractionModule;
5069
+ exports.ɵbm = ActivityContainerComponent;
5070
+ exports.ɵbn = AbstractInteractionContext;
5071
+ exports.ɵbo = ActivityOutletComponent;
5072
+ exports.ɵbp = ConfirmationDialogComponent;
5073
+ exports.ɵbq = ACTIVITY_DATA;
5074
+ exports.ɵbr = Activity;
5075
+ exports.ɵbt = ConfirmThenDialogComponent;
5076
+ exports.ɵbu = AlertDialogComponent;
5077
+ exports.ɵbw = InPlaceInteractionContextComponent;
5001
5078
  exports.ɵc = FocusBindingDirective;
5002
5079
  exports.ɵd = DisposableComponent;
5003
5080
  exports.ɵe = FocusBindingFactory;
@@ -5015,13 +5092,13 @@
5015
5092
  exports.ɵq = SwitchCaseDefaultDirective;
5016
5093
  exports.ɵr = SwitchCaseComponent;
5017
5094
  exports.ɵs = FocusContainerComponent;
5018
- exports.ɵt = FocusableComponent;
5019
- exports.ɵu = PlaceModule;
5020
- exports.ɵv = EmptyStateComponent;
5021
- exports.ɵw = BusyOverlayComponent;
5022
- exports.ɵx = PlaceOutletComponent;
5023
- exports.ɵy = leftRightPlaceAnimation;
5024
- exports.ɵz = LEFT_RIGHT_PLACE_ANIMATION;
5095
+ exports.ɵt = VerticalFocusContainerComponent;
5096
+ exports.ɵu = FocusableComponent;
5097
+ exports.ɵv = PlaceModule;
5098
+ exports.ɵw = EmptyStateComponent;
5099
+ exports.ɵx = BusyOverlayComponent;
5100
+ exports.ɵy = PlaceOutletComponent;
5101
+ exports.ɵz = leftRightPlaceAnimation;
5025
5102
 
5026
5103
  Object.defineProperty(exports, '__esModule', { value: true });
5027
5104