@gravitee/ui-particles-angular 4.11.0 → 4.11.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.
@@ -2836,6 +2836,21 @@
2836
2836
  * limitations under the License.
2837
2837
  */
2838
2838
 
2839
+ /*
2840
+ * Copyright (C) 2015 The Gravitee team (http://gravitee.io)
2841
+ *
2842
+ * Licensed under the Apache License, Version 2.0 (the "License");
2843
+ * you may not use this file except in compliance with the License.
2844
+ * You may obtain a copy of the License at
2845
+ *
2846
+ * http://www.apache.org/licenses/LICENSE-2.0
2847
+ *
2848
+ * Unless required by applicable law or agreed to in writing, software
2849
+ * distributed under the License is distributed on an "AS IS" BASIS,
2850
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2851
+ * See the License for the specific language governing permissions and
2852
+ * limitations under the License.
2853
+ */
2839
2854
  var GioSubmenuTitleDirective = /** @class */ (function () {
2840
2855
  function GioSubmenuTitleDirective() {
2841
2856
  }
@@ -2858,25 +2873,26 @@
2858
2873
  this.hover = false;
2859
2874
  this.unsubscribe$ = new rxjs.Subject();
2860
2875
  }
2861
- GioSubmenuComponent.prototype.ngOnInit = function () {
2876
+ GioSubmenuComponent.prototype.ngAfterViewInit = function () {
2862
2877
  var _this = this;
2863
- rxjs.combineLatest([this.gioMenuService.reduce, this.gioMenuService.overlayObservable])
2864
- .pipe(operators.takeUntil(this.unsubscribe$), operators.tap(function (_a) {
2865
- var _b = __read(_a, 2), reduced = _b[0], overlayOptions = _b[1];
2866
- _this.reduced = reduced;
2878
+ this.gioMenuService.reduce
2879
+ .pipe(operators.takeUntil(this.unsubscribe$), operators.filter(function (reduced) { return reduced; }), operators.tap(function () {
2880
+ _this.reduced = true;
2867
2881
  _this.loaded = true;
2868
- if (_this.gioSubmenu) {
2869
- _this.overlayOptions = overlayOptions;
2870
- if (_this.reduced) {
2871
- var top = overlayOptions.top || 0;
2872
- _this.gioSubmenu.nativeElement.style.top = top + "px";
2873
- _this.gioSubmenu.nativeElement.style.height = 'auto';
2874
- _this.gioSubmenu.nativeElement.style.maxHeight = "calc(100vh - " + (top + 8) + "px)";
2875
- return;
2876
- }
2877
- _this.gioSubmenu.nativeElement.style.height = '100%';
2878
- _this.gioSubmenu.nativeElement.style.maxHeight = 'none';
2879
- }
2882
+ }), operators.switchMap(function () { return _this.gioMenuService.overlayObservable; }), operators.tap(function (overlayOptions) {
2883
+ var top = overlayOptions.top || 0;
2884
+ _this.overlayOptions = overlayOptions;
2885
+ _this.gioSubmenu.nativeElement.style.top = top + "px";
2886
+ _this.gioSubmenu.nativeElement.style.height = 'auto';
2887
+ _this.gioSubmenu.nativeElement.style.maxHeight = "calc(100vh - " + (top + 8) + "px)";
2888
+ }))
2889
+ .subscribe();
2890
+ this.gioMenuService.reduce
2891
+ .pipe(operators.takeUntil(this.unsubscribe$), operators.filter(function (reduced) { return !reduced; }), operators.tap(function () {
2892
+ _this.reduced = false;
2893
+ _this.loaded = true;
2894
+ _this.gioSubmenu.nativeElement.style.height = '100%';
2895
+ _this.gioSubmenu.nativeElement.style.maxHeight = 'none';
2880
2896
  }))
2881
2897
  .subscribe();
2882
2898
  };