2024-01-09 13:26:52 +01:00
|
|
|
import {ChangeDetectorRef, Component} from "@angular/core";
|
|
|
|
import {Meta, Title} from "@angular/platform-browser";
|
|
|
|
import {ActivatedRoute, Router} from "@angular/router";
|
|
|
|
import {SEOService} from "../../openaireLibrary/sharedComponents/SEO/SEO.service";
|
|
|
|
import {BaseComponent} from "../../openaireLibrary/sharedComponents/base/base.component";
|
|
|
|
import {PiwikService} from "../../openaireLibrary/utils/piwik/piwik.service";
|
|
|
|
import {LayoutService} from "../../openaireLibrary/dashboard/sharedComponents/sidebar/layout.service";
|
|
|
|
import {HelperService} from "../../openaireLibrary/utils/helper/helper.service";
|
2024-01-08 15:57:55 +01:00
|
|
|
|
|
|
|
@Component({
|
|
|
|
selector: 'terminology',
|
2024-01-09 13:26:52 +01:00
|
|
|
templateUrl: 'terminology.component.html',
|
|
|
|
styleUrls: ['terminology.component.less']
|
2024-01-08 15:57:55 +01:00
|
|
|
})
|
2024-01-09 13:26:52 +01:00
|
|
|
export class TerminologyComponent extends BaseComponent{
|
|
|
|
title = 'Terminology & Construction';
|
|
|
|
description = 'Terminology & Construction';
|
|
|
|
tab: 'entities' | 'attributes' = 'entities';
|
|
|
|
contentSections: string[] = ['entities', 'inherited-and-inferred-attributes', 'constructed-attributes'];
|
|
|
|
activeSection: string;
|
|
|
|
divContents: any;
|
|
|
|
|
|
|
|
isMobile: boolean = false;
|
|
|
|
isServer: boolean;
|
|
|
|
|
|
|
|
constructor(protected _route: ActivatedRoute,
|
|
|
|
protected _piwikService: PiwikService,
|
|
|
|
protected _meta: Meta,
|
|
|
|
protected seoService: SEOService,
|
|
|
|
protected _title: Title,
|
|
|
|
protected _router: Router,
|
|
|
|
private cdr: ChangeDetectorRef,
|
|
|
|
private layoutService: LayoutService,
|
|
|
|
private helper: HelperService) {
|
|
|
|
super();
|
|
|
|
}
|
|
|
|
|
|
|
|
ngOnInit() {
|
|
|
|
this.setMetadata();
|
|
|
|
this.subscriptions.push(this._route.fragment.subscribe(fragment => {
|
|
|
|
if(fragment) {
|
|
|
|
this.activeSection = fragment;
|
|
|
|
} else {
|
|
|
|
this.activeSection = 'entities';
|
|
|
|
}
|
|
|
|
}));
|
|
|
|
this.layoutService.isMobile.subscribe(isMobile => {
|
|
|
|
this.isMobile = isMobile;
|
|
|
|
this.cdr.detectChanges();
|
|
|
|
});
|
|
|
|
this.getDivContents();
|
|
|
|
}
|
|
|
|
|
|
|
|
private getDivContents() {
|
|
|
|
this.subscriptions.push(this.helper.getDivHelpContents(this.properties, 'irish', '/methodology/terminology').subscribe(contents => {
|
|
|
|
this.divContents = contents;
|
|
|
|
console.log(this.divContents);
|
|
|
|
}));
|
2024-01-08 15:57:55 +01:00
|
|
|
}
|
|
|
|
}
|