diff --git a/connect/communityGuard/connectAdminLoginGuard.guard.ts b/connect/communityGuard/connectAdminLoginGuard.guard.ts
index 2b55ede5..86359230 100644
--- a/connect/communityGuard/connectAdminLoginGuard.guard.ts
+++ b/connect/communityGuard/connectAdminLoginGuard.guard.ts
@@ -1,20 +1,13 @@
import {filter, map, mergeMap, take} from 'rxjs/operators';
import {Injectable} from '@angular/core';
-import {
- ActivatedRouteSnapshot,
- CanActivate,
- CanActivateChild,
- Router,
- RouterStateSnapshot,
- UrlTree
-} from '@angular/router';
+import { ActivatedRouteSnapshot, Router, RouterStateSnapshot, UrlTree } from '@angular/router';
import {Observable, of} from 'rxjs';
import {Session} from '../../login/utils/helper.class';
import {LoginErrorCodes} from '../../login/utils/guardHelper.class';
import {UserManagementService} from "../../services/user-management.service";
@Injectable()
-export class ConnectAdminLoginGuard implements CanActivate, CanActivateChild {
+export class ConnectAdminLoginGuard {
constructor(private router: Router,
private userManagementService: UserManagementService) {
diff --git a/connect/communityGuard/isCommunity.guard.ts b/connect/communityGuard/isCommunity.guard.ts
index 41b737c2..9dd04798 100644
--- a/connect/communityGuard/isCommunity.guard.ts
+++ b/connect/communityGuard/isCommunity.guard.ts
@@ -1,11 +1,5 @@
-import { Injectable } from '@angular/core';
-import {
- Router,
- CanActivate,
- ActivatedRouteSnapshot,
- RouterStateSnapshot,
- CanLoad, Route, UrlSegment, CanActivateChild, UrlTree
-} from '@angular/router';
+import {Injectable} from '@angular/core';
+import {ActivatedRouteSnapshot, Router, RouterStateSnapshot, UrlTree} from '@angular/router';
import {Observable} from 'rxjs';
import {ConnectHelper} from '../connectHelper';
@@ -14,7 +8,7 @@ import {CommunityService} from "../community/community.service";
import {map} from "rxjs/operators";
@Injectable()
-export class IsCommunity implements CanActivate, CanActivateChild {
+export class IsCommunity {
constructor(private router: Router,
private communityService: CommunityService) {
diff --git a/dashboard/divId/divIds.module.ts b/dashboard/divId/divIds.module.ts
index e379ded4..eca996e6 100644
--- a/dashboard/divId/divIds.module.ts
+++ b/dashboard/divId/divIds.module.ts
@@ -6,14 +6,6 @@ import {AlertModalModule} from '../../utils/modal/alertModal.module';
import {DivIdsComponent} from './divIds.component';
import {AdminToolServiceModule} from "../../services/adminToolService.module";
import {InputModule} from "../../sharedComponents/input/input.module";
-
-
-import {MatAutocompleteModule} from '@angular/material/autocomplete';
-import { MatCheckboxModule } from "@angular/material/checkbox";
-import { MatFormFieldModule } from "@angular/material/form-field";
-
-
-import {MatChipsModule} from '@angular/material/chips';
import {AdminTabsModule} from "../sharedComponents/admin-tabs/admin-tabs.module";
import {PageContentModule} from "../sharedComponents/page-content/page-content.module";
import {ClassesRoutingModule} from "./classes-routing.module";
@@ -24,8 +16,8 @@ import {LoadingModule} from "../../utils/loading/loading.module";
@NgModule({
imports: [
CommonModule, RouterModule, FormsModule,
- AlertModalModule, ReactiveFormsModule, AdminToolServiceModule, InputModule, MatAutocompleteModule, MatFormFieldModule, MatChipsModule,
- MatCheckboxModule, AdminTabsModule, PageContentModule, ClassesRoutingModule, SearchInputModule, IconsModule, LoadingModule
+ AlertModalModule, ReactiveFormsModule, AdminToolServiceModule, InputModule,
+ AdminTabsModule, PageContentModule, ClassesRoutingModule, SearchInputModule, IconsModule, LoadingModule
],
declarations: [DivIdsComponent],
exports: [DivIdsComponent]
diff --git a/dashboard/helpTexts/page-help-content-form.module.ts b/dashboard/helpTexts/page-help-content-form.module.ts
index 243a11d7..27e34ae4 100644
--- a/dashboard/helpTexts/page-help-content-form.module.ts
+++ b/dashboard/helpTexts/page-help-content-form.module.ts
@@ -8,21 +8,20 @@ import {PageContentFormComponent} from './page-help-content-form.component';
import {PageHelpContentFormRoutingModule} from './page-help-content-form-routing.module';
import {AdminToolServiceModule} from '../../services/adminToolService.module';
import {InputModule} from '../../sharedComponents/input/input.module';
-import {MatSlideToggleModule} from '@angular/material/slide-toggle';
import {IconsModule} from '../../utils/icons/icons.module';
import {PageContentModule} from '../sharedComponents/page-content/page-content.module';
import {RouterModule} from '@angular/router';
import {LoadingModule} from '../../utils/loading/loading.module';
+import {MatSlideToggleModule} from "@angular/material/slide-toggle";
@NgModule({
imports: [
CommonModule, FormsModule, RouterModule,
SafeHtmlPipeModule, CKEditorModule,
- AlertModalModule, ReactiveFormsModule, PageHelpContentFormRoutingModule, AdminToolServiceModule, InputModule, MatSlideToggleModule, IconsModule, PageContentModule, LoadingModule
+ AlertModalModule, ReactiveFormsModule, PageHelpContentFormRoutingModule, AdminToolServiceModule, InputModule, IconsModule, PageContentModule, LoadingModule, MatSlideToggleModule
],
- declarations: [
- PageContentFormComponent
- ],
- exports: [PageContentFormComponent]
+ declarations: [PageContentFormComponent],
+ exports: [PageContentFormComponent]
})
-export class PageHelpContentFormModule {}
+export class PageHelpContentFormModule {
+}
diff --git a/dashboard/sharedComponents/page-content/page-content.component.ts b/dashboard/sharedComponents/page-content/page-content.component.ts
index 54261153..654f82e6 100644
--- a/dashboard/sharedComponents/page-content/page-content.component.ts
+++ b/dashboard/sharedComponents/page-content/page-content.component.ts
@@ -80,9 +80,6 @@ export class PageContentComponent implements OnInit, AfterViewInit, OnDestroy {
}
ngOnInit() {
- if(this.isBrowser) {
- this.stickyBugWorkaround();
- }
this.subscriptions.push(this.layoutService.isMobile.subscribe(isMobile => {
this.isMobile = isMobile;
if(this.isBrowser) {
@@ -132,41 +129,7 @@ export class PageContentComponent implements OnInit, AfterViewInit, OnDestroy {
initFooter() {
let footer_offset = this.calcStickyFooterOffset(this.sticky_footer.nativeElement);
- this.sticky.footer = UIkit.sticky(this.sticky_footer.nativeElement, {bottom: true, offset: footer_offset});
- }
-
- /**
- * Workaround for sticky not update bug when sidebar is toggled.
- * TODO when UIKit will be updated => remove
- *
- * */
- stickyBugWorkaround() {
- let sidebarOffset = Number.parseInt(getComputedStyle(document.documentElement).getPropertyValue('--dashboard-sidebar-width')) -
- Number.parseInt(getComputedStyle(document.documentElement).getPropertyValue('--dashboard-sidebar-mini-width'));
- let transitionDelay = Number.parseFloat(getComputedStyle(document.documentElement).getPropertyValue('--dashboard-transition-delay')) * 1000;
- this.subscriptions.push(this.layoutService.isOpen.subscribe(isOpen => {
- if (this.sticky.header) {
- if (isOpen) {
- this.sticky.header.$el.style.width = Number.parseInt(this.sticky.header.$el.style.width) - sidebarOffset + 'px';
- } else {
- this.sticky.header.$el.style.width = Number.parseInt(this.sticky.header.$el.style.width) + sidebarOffset + 'px';
- }
- setTimeout(() => {
- this.sticky.header.$emit();
- }, transitionDelay);
- }
- if (this.sticky.footer) {
- if (isOpen) {
- this.sticky.footer.$el.style.width = Number.parseInt(this.sticky.footer.$el.style.width) - sidebarOffset + 'px';
- } else {
- this.sticky.footer.$el.style.width = Number.parseInt(this.sticky.footer.$el.style.width) + sidebarOffset + 'px';
- }
- setTimeout(() => {
- this.sticky.footer.$emit();
- }, transitionDelay);
- }
- this.cdr.detectChanges();
- }));
+ this.sticky.footer = UIkit.sticky(this.sticky_footer.nativeElement, {end: true, offset: footer_offset});
}
/**
diff --git a/dashboard/sharedComponents/sidebar/layout.service.ts b/dashboard/sharedComponents/sidebar/layout.service.ts
index 39a2eaa8..38ae65c7 100644
--- a/dashboard/sharedComponents/sidebar/layout.service.ts
+++ b/dashboard/sharedComponents/sidebar/layout.service.ts
@@ -79,6 +79,10 @@ export class LayoutService {
* Add hasMenuSearchBar: false/ nothing on data of route config, if the search bar in the menu should not appear, otherwise true.
*/
private hasMenuSearchBarSubject: BehaviorSubject = new BehaviorSubject(false);
+ /**
+ * Add hasStickyHeaderOnMobile: true in order to activate uk-sticky in header of mobile/tablet devices.
+ * */
+ private hasStickyHeaderOnMobileSubject: BehaviorSubject = new BehaviorSubject(false);
private subscriptions: any[] = [];
@@ -177,6 +181,12 @@ export class LayoutService {
} else {
this.setHasMenuSearchBar(false);
}
+ if (data['hasStickyHeaderOnMobile'] !== undefined &&
+ data['hasStickyHeaderOnMobile'] === true) {
+ this.setHasStickyHeaderOnMobile(true);
+ } else {
+ this.setHasStickyHeaderOnMobile(false);
+ }
}
}));
this.setObserver();
@@ -311,4 +321,12 @@ export class LayoutService {
setHasMenuSearchBar(value: boolean) {
this.hasMenuSearchBarSubject.next(value);
}
+
+ get hasStickyHeaderOnMobile(): Observable {
+ return this.hasStickyHeaderOnMobileSubject.asObservable();
+ }
+
+ setHasStickyHeaderOnMobile(value: boolean) {
+ this.hasStickyHeaderOnMobileSubject.next(value);
+ }
}
diff --git a/dashboard/sharedComponents/sidebar/sideBar.component.html b/dashboard/sharedComponents/sidebar/sideBar.component.html
index 9bba0b18..35e20996 100644
--- a/dashboard/sharedComponents/sidebar/sideBar.component.html
+++ b/dashboard/sharedComponents/sidebar/sideBar.component.html
@@ -29,7 +29,7 @@
0" class="menu_section uk-margin-large-top" [class.mobile]="mobile" style="min-height: 30vh">
-
{{item.title}}
+
0" class="uk-nav-parent-icon hide-on-close">
0 && (isBrowser || item.isActive)" class="uk-nav-sub">
- | boolean {
+ canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable | Promise | boolean | UrlTree{
if(properties.environment == 'development') {
return true;
} else {
this.router.navigate([properties.errorLink]);
}
}
-
- canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable | Promise | boolean | UrlTree{
- return this.check();
- }
-
- canLoad(route: Route, segments: UrlSegment[]): Observable | Promise | boolean | UrlTree {
- return this.check()
- }
-}
\ No newline at end of file
+}
diff --git a/error/isRouteEnabled.guard.ts b/error/isRouteEnabled.guard.ts
index 2c8d704c..2dca90fb 100644
--- a/error/isRouteEnabled.guard.ts
+++ b/error/isRouteEnabled.guard.ts
@@ -1,13 +1,13 @@
import {Observable} from 'rxjs';
import {take, tap} from 'rxjs/operators';
import {Injectable} from '@angular/core';
-import {ActivatedRouteSnapshot, CanActivate, Data, Router, RouterStateSnapshot, UrlTree} from '@angular/router';
+import { ActivatedRouteSnapshot, Data, Router, RouterStateSnapshot, UrlTree } from '@angular/router';
import {ConfigurationService} from '../utils/configuration/configuration.service';
import {ConnectHelper} from '../connect/connectHelper';
import {properties} from "../../../environments/environment";
@Injectable()
-export class IsRouteEnabled implements CanActivate {
+export class IsRouteEnabled {
constructor(private router: Router,
private config: ConfigurationService) {
diff --git a/fos/fos.component.html b/fos/fos.component.html
index e29cc133..d4c076cf 100644
--- a/fos/fos.component.html
+++ b/fos/fos.component.html
@@ -49,7 +49,7 @@
-
+
-
diff --git a/http-interceptor.service.ts b/http-interceptor.service.ts
index 7b0a4104..03b66510 100644
--- a/http-interceptor.service.ts
+++ b/http-interceptor.service.ts
@@ -2,7 +2,7 @@ import {Injectable, Inject, PLATFORM_ID, Optional} from '@angular/core';
import {HttpInterceptor, HttpRequest, HttpHandler, HttpEvent, HttpResponse, HttpHeaders} from '@angular/common/http';
import {Observable, of} from 'rxjs';
import {tap} from 'rxjs/operators';
-import {TransferState, makeStateKey, StateKey} from '@angular/platform-browser';
+import {TransferState, makeStateKey, StateKey} from '@angular/core';
import {isPlatformServer} from '@angular/common';
import {properties} from "../../environments/environment";
import {REQUEST} from "./utils/tokens";
diff --git a/landingPages/dataProvider/dataProvider.component.html b/landingPages/dataProvider/dataProvider.component.html
index 04e842e5..569bc81f 100644
--- a/landingPages/dataProvider/dataProvider.component.html
+++ b/landingPages/dataProvider/dataProvider.component.html
@@ -17,7 +17,7 @@
@@ -63,10 +64,11 @@
Give us feedback
+
+ uk-sticky="end: true;" [attr.offset]="graph_offset">
@@ -229,7 +231,7 @@
+ uk-sticky="end: true; media: @m" [attr.offset]="offset">
-
-
+
diff --git a/landingPages/landing-utils/citeThis/citeThis.component.ts b/landingPages/landing-utils/citeThis/citeThis.component.ts
index 0334d387..660a4b0d 100644
--- a/landingPages/landing-utils/citeThis/citeThis.component.ts
+++ b/landingPages/landing-utils/citeThis/citeThis.component.ts
@@ -1,19 +1,9 @@
-import {
- Component,
- Inject,
- Input,
- OnDestroy,
- OnInit,
- RendererFactory2,
- ViewEncapsulation
-} from '@angular/core';
+import {Component, Inject, Input, OnDestroy, OnInit, RendererFactory2, ViewEncapsulation} from '@angular/core';
import {Citation, CitationData} from './citation.class';
-import {ResultLandingInfo} from "../../../utils/entities/resultLandingInfo";
import {DOCUMENT} from "@angular/common";
import {EnvProperties} from "../../../utils/properties/env-properties";
import {properties} from "../../../../../environments/environment";
import {PiwikService} from "../../../utils/piwik/piwik.service";
-import {ResultPreview} from "../../../utils/result-preview/result-preview";
declare var Cite: any;
// Based on https://citation.js.org/api/tutorial-getting_started.html browser release
diff --git a/landingPages/landing-utils/citeThis/citeThis.module.ts b/landingPages/landing-utils/citeThis/citeThis.module.ts
index 53583b5f..8de1bdbc 100644
--- a/landingPages/landing-utils/citeThis/citeThis.module.ts
+++ b/landingPages/landing-utils/citeThis/citeThis.module.ts
@@ -3,13 +3,12 @@ import {CommonModule} from '@angular/common';
import {FormsModule} from '@angular/forms';
import {CiteThisComponent} from './citeThis.component';
-import { MatSelectModule } from "@angular/material/select";
import {InputModule} from "../../../sharedComponents/input/input.module";
@NgModule({
imports: [
- CommonModule, FormsModule, MatSelectModule, InputModule
+ CommonModule, FormsModule, InputModule
],
declarations: [
CiteThisComponent
diff --git a/landingPages/organization/organization.component.html b/landingPages/organization/organization.component.html
index 1332322f..dbcb6cca 100644
--- a/landingPages/organization/organization.component.html
+++ b/landingPages/organization/organization.component.html
@@ -16,7 +16,7 @@
-
-
-
-
-
-
+
+
+
+
+
+
+
Last update of records in OpenAIRE: {{indexUpdateDate | date: 'MMM dd, yyyy'}}
-
-
-
+
+
+
+
+ uk-sticky="end: true;" [attr.offset]="graph_offset">
@@ -171,7 +173,7 @@
+ uk-sticky="end: true; media: @m" [attr.offset]="offset">
+
+ uk-sticky="end: true;" [attr.offset]="graph_offset">
@@ -363,7 +365,7 @@
+ uk-sticky="end: true; media: @m" [attr.offset]="offset">
+
+ uk-sticky="end: true;" [attr.offset]="graph_offset">