updates on customization/ using built css and preview css
This commit is contained in:
parent
c431ff60fd
commit
27f20e1918
60
server.ts
60
server.ts
|
@ -21,8 +21,11 @@ const axios = require('axios');
|
|||
|
||||
const browser = process.cwd() + '/dist/connect/browser/';
|
||||
const node_modules = process.cwd() + '/node_modules';
|
||||
var bodyParser = require('body-parser')
|
||||
|
||||
function buildCss(portal: string, variables: {} = null) {
|
||||
var jsonParser = bodyParser.json()
|
||||
|
||||
function buildCss(portal: string, suffix =null, variables: {} = null) {
|
||||
let lessFile = 'community.less'
|
||||
if(portal === 'connect') {
|
||||
lessFile = 'connect.less'
|
||||
|
@ -48,7 +51,7 @@ function buildCss(portal: string, variables: {} = null) {
|
|||
if(error) {
|
||||
console.log(error);
|
||||
} else {
|
||||
fs.writeFile(browser + portal + '.css', result.css, function (error) {
|
||||
fs.writeFile(browser + portal + (suffix?("-" + suffix):"") + '.css', result.css, function (error) {
|
||||
if(error) {
|
||||
console.error(error);
|
||||
} else {
|
||||
|
@ -68,9 +71,25 @@ function buildCss(portal: string, variables: {} = null) {
|
|||
}
|
||||
});
|
||||
}
|
||||
|
||||
function buildAll(){
|
||||
let layoutsURL = properties.adminToolsAPIURL + '/community/layouts';
|
||||
axios.get(layoutsURL).then(response => {
|
||||
if(response.data && Array.isArray(response.data) && response.data.length > 0) {
|
||||
response.data.forEach((layout: Layout) => {
|
||||
let variables = Layout.getVariables(layout.layoutOptions);
|
||||
if(variables) {
|
||||
buildCss(layout.portalPid,layout.date?layout.date:null, variables);
|
||||
}
|
||||
});
|
||||
return ('CSS build for all available layouts was successful');
|
||||
} else {
|
||||
return ('No available layouts found');
|
||||
}
|
||||
});
|
||||
}
|
||||
buildCss('connect');
|
||||
buildCss('default');
|
||||
buildAll();
|
||||
|
||||
// The Express app is exported so that it can be used by serverless Functions.
|
||||
export function app() {
|
||||
|
@ -155,38 +174,35 @@ export function app() {
|
|||
});
|
||||
|
||||
server.post('/build-css/all', (req, res) => {
|
||||
let layoutsURL = properties.adminToolsAPIURL + '/community/layouts';
|
||||
axios.get(layoutsURL).then(response => {
|
||||
if(response.data && Array.isArray(response.data) && response.data.length > 0) {
|
||||
response.data.forEach((layout: Layout) => {
|
||||
let variables = Layout.getVariables(layout);
|
||||
if(variables) {
|
||||
buildCss(layout.portalPid, variables);
|
||||
}
|
||||
});
|
||||
res.send('CSS build for all available layouts was successful');
|
||||
} else {
|
||||
res.send('No available layouts found');
|
||||
}
|
||||
});
|
||||
res.send(buildAll())
|
||||
});
|
||||
|
||||
server.post('/build-css/:id', (req, res) => {
|
||||
server.post('/build-css/:id/:suffix', (req, res) => {
|
||||
let layoutURL = properties.adminToolsAPIURL + '/community/' + req.params.id + '/layout';
|
||||
axios.get(layoutURL).then(response => {
|
||||
if(response.data) {
|
||||
let variables = Layout.getVariables(response.data);
|
||||
if(variables) {
|
||||
buildCss(response.data.portalPid, variables);
|
||||
buildCss(response.data.portalPid,req.params.suffix, variables);
|
||||
}
|
||||
res.send('CSS build for ' + response.data.portalPid + 'layouts was successful');
|
||||
res.status(200).send({code:200, message: 'CSS build for ' + response.data.portalPid + ' layouts was successful'});
|
||||
} else {
|
||||
res.send('No layout found');
|
||||
res.status(500).send({code:500, message:'No layout found'});
|
||||
}
|
||||
}).catch(function (error) {
|
||||
res.send('No layout found');
|
||||
res.status(500).send({code:500, message:'No layout found'});
|
||||
});
|
||||
});
|
||||
server.post('/build-css/preview/:id/:suffix', jsonParser, (req, res) => {
|
||||
let layoutURL = properties.adminToolsAPIURL + '/community/' + req.params.id + '/layout';
|
||||
let variables = Layout.getVariables(req.body);
|
||||
if(variables) {
|
||||
buildCss(req.params.id,req.params.suffix, variables);
|
||||
res.status(200).send({code:200, message: 'CSS build for ' + req.params.id + ' layouts was successful'});
|
||||
} else {
|
||||
res.status(500).send({code: 500, message: 'No layout found'});
|
||||
}
|
||||
});
|
||||
// Example Express Rest API endpoints
|
||||
// server.get('/api/**', (req, res) => { });
|
||||
// Serve static files from /browser
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import {Component, OnDestroy, OnInit, ViewChild} from '@angular/core';
|
||||
import {Component, Inject, OnDestroy, OnInit, RendererFactory2, ViewChild, ViewEncapsulation} from '@angular/core';
|
||||
import {ActivatedRoute, NavigationEnd, Router} from '@angular/router';
|
||||
|
||||
import {EnvProperties} from './openaireLibrary/utils/properties/env-properties';
|
||||
|
@ -15,7 +15,7 @@ import {Subscriber} from "rxjs";
|
|||
import {CommunityService} from "./openaireLibrary/connect/community/community.service";
|
||||
import {StringUtils} from "./openaireLibrary/utils/string-utils.class";
|
||||
import {LoginErrorCodes} from "./openaireLibrary/login/utils/guardHelper.class";
|
||||
import {CustomizationOptions} from "./openaireLibrary/connect/community/CustomizationOptions";
|
||||
import {CustomizationOptions, Layout} from "./openaireLibrary/connect/community/CustomizationOptions";
|
||||
import {LayoutService} from "./openaireLibrary/services/layout.service";
|
||||
import {SmoothScroll} from "./openaireLibrary/utils/smooth-scroll";
|
||||
import {Meta} from "@angular/platform-browser";
|
||||
|
@ -29,6 +29,7 @@ import {QuickContactComponent} from "./openaireLibrary/sharedComponents/quick-co
|
|||
import {Composer} from "./openaireLibrary/utils/email/composer";
|
||||
import {NotificationHandler} from "./openaireLibrary/utils/notification-handler";
|
||||
import {OpenaireEntities} from "./openaireLibrary/utils/properties/searchFields";
|
||||
import {DOCUMENT} from "@angular/common";
|
||||
|
||||
@Component({
|
||||
selector: 'app-root',
|
||||
|
@ -52,8 +53,8 @@ import {OpenaireEntities} from "./openaireLibrary/utils/properties/searchFields"
|
|||
searchRoute="/search/find/research-outcomes"
|
||||
[showHomeMenuItem]="false">
|
||||
</navbar>
|
||||
<customization *ngIf="properties && showMenu && communityId && communityId.length > 0 && layout" [properties]="properties"
|
||||
[communityId]="communityId" [layout]="layout" ></customization>
|
||||
<!--<customization *ngIf="properties && showMenu && communityId && communityId.length > 0 && layout" [properties]="properties"
|
||||
[communityId]="communityId" [layout]="layout" ></customization>-->
|
||||
<schema2jsonld *ngIf="properties && showMenu && !community" [URL]="properties.domain + properties.baseLink"
|
||||
[logoURL]="properties.domain + properties.baseLink + logoPath + 'main.svg'"
|
||||
type="home"
|
||||
|
@ -125,7 +126,8 @@ export class AppComponent implements OnInit, OnDestroy {
|
|||
@ViewChild('modal') modal: AlertModal;
|
||||
@ViewChild('quickContact') quickContact: QuickContactComponent;
|
||||
private subscriptions = [];
|
||||
layout: CustomizationOptions = null;
|
||||
layout: Layout = null;
|
||||
previewLayout = null;
|
||||
constructor(private route: ActivatedRoute, private propertiesService: EnvironmentSpecificService,
|
||||
private _communitiesService: CommunitiesService, private smoothScroll: SmoothScroll,
|
||||
private router: Router, private userManagementService: UserManagementService,
|
||||
|
@ -133,7 +135,9 @@ export class AppComponent implements OnInit, OnDestroy {
|
|||
private _layoutService: LayoutService, private _meta: Meta, private seoService: SEOService,
|
||||
private quickContactService: QuickContactService,
|
||||
private fb: FormBuilder,
|
||||
private emailService: EmailService) {
|
||||
private emailService: EmailService,
|
||||
@Inject(DOCUMENT) private document, private rendererFactory: RendererFactory2
|
||||
) {
|
||||
this.subscriptions.push(router.events.forEach((event) => {
|
||||
if (event instanceof NavigationEnd) {
|
||||
if (event.url === '/contact-us') {
|
||||
|
@ -149,6 +153,10 @@ export class AppComponent implements OnInit, OnDestroy {
|
|||
ngOnInit() {
|
||||
if (this.properties.environment == "production" || this.properties.environment == "development") {
|
||||
this.subscriptions.push(this.route.queryParams.subscribe(data => {
|
||||
this.previewLayout = (data['previewLayout'] && data['previewLayout'].length >0 ? data['previewLayout']: null);
|
||||
if(this.previewLayout){
|
||||
// this.initCss(this.previewLayout);
|
||||
}
|
||||
this._meta.updateTag({content: 'all', name: 'robots'});
|
||||
this.seoService.removeLinkForPrevURL();
|
||||
this.seoService.removeLinkForNextURL();
|
||||
|
@ -205,6 +213,35 @@ export class AppComponent implements OnInit, OnDestroy {
|
|||
this.userManagementService.fixRedirectURL = null;
|
||||
}
|
||||
}
|
||||
initCss(communityId, suffix=null) {
|
||||
try {
|
||||
|
||||
const renderer = this.rendererFactory.createRenderer(this.document, {
|
||||
id: '-1',
|
||||
encapsulation: ViewEncapsulation.None,
|
||||
styles: [],
|
||||
data: {}
|
||||
});
|
||||
const head = this.document.getElementsByTagName('head')[0];
|
||||
if (head === null) {
|
||||
throw new Error('<head> not found within DOCUMENT.');
|
||||
}
|
||||
if(!this.document.getElementById("dashboardStyle")) {
|
||||
const script = renderer.createElement('link');
|
||||
renderer.setAttribute(script, "id", "dashboardStyle");
|
||||
renderer.setAttribute(script, "href", ((communityId) ? communityId : this.properties.adminToolsPortalType) + (suffix?"-"+suffix:"") + ".css");
|
||||
renderer.setAttribute(script, "rel", "stylesheet");
|
||||
renderer.appendChild(head, script);
|
||||
}else if(!this.previewLayout){
|
||||
this.document.getElementById("dashboardStyle").href = ((communityId) ? communityId : this.properties.adminToolsPortalType)+ (suffix?"-"+suffix:"") + ".css";
|
||||
console.log(this.document.getElementById("dashboardStyle"));
|
||||
}
|
||||
|
||||
} catch (e) {
|
||||
console.error('Renderrer Error to append style ', e);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
initAdminToolCommunity(communityId) {
|
||||
if (communityId) {
|
||||
|
@ -212,24 +249,35 @@ export class AppComponent implements OnInit, OnDestroy {
|
|||
this.initLayout(communityId);
|
||||
}else{
|
||||
this.properties.adminToolsPortalType = "connect";
|
||||
this.initCss("connect");
|
||||
}
|
||||
this.configurationService.initCommunityInformation(this.properties, (communityId) ? communityId : this.properties.adminToolsPortalType);
|
||||
|
||||
}
|
||||
initLayout(communityId){
|
||||
if(!this.layout && (typeof location == 'undefined' || (typeof location !== 'undefined' && location.pathname.indexOf("/preview") == -1))) {
|
||||
if(!this.layout && (typeof location == 'undefined' || (typeof location !== 'undefined' && location.pathname.indexOf("/preview") == -1)) && !this.previewLayout) {
|
||||
this._layoutService.getLayout(this.properties, communityId).subscribe(
|
||||
layout => {
|
||||
this.layout = layout;
|
||||
if (layout) {
|
||||
this.layout = CustomizationOptions.checkForObsoleteVersion(layout.layoutOptions,this.communityId);
|
||||
this.layout.layoutOptions = CustomizationOptions.checkForObsoleteVersion(layout.layoutOptions,this.communityId);
|
||||
console.log(this.layout.date);
|
||||
console.log(this.layout.date?(new Date(this.layout.date)).toISOString():null);
|
||||
this.initCss(communityId, this.layout.date?this.layout.date:null)
|
||||
// this.initCss("default");
|
||||
} else {
|
||||
this.layout = new CustomizationOptions(CustomizationOptions.getIdentity(communityId).mainColor, CustomizationOptions.getIdentity(communityId).secondaryColor);
|
||||
// this.layout.layoutOptions = new CustomizationOptions(CustomizationOptions.getIdentity(communityId).mainColor, CustomizationOptions.getIdentity(communityId).secondaryColor);
|
||||
this.initCss("default");
|
||||
}
|
||||
|
||||
},
|
||||
error => {
|
||||
this.layout = new CustomizationOptions(CustomizationOptions.getIdentity(communityId).mainColor, CustomizationOptions.getIdentity(communityId).secondaryColor);
|
||||
this.layout.layoutOptions = new CustomizationOptions(CustomizationOptions.getIdentity(communityId).mainColor, CustomizationOptions.getIdentity(communityId).secondaryColor);
|
||||
this.initCss("default");
|
||||
}
|
||||
);
|
||||
}else if(this.previewLayout && this.previewLayout.split("-preview-")[0] == communityId){
|
||||
this.initCss(communityId, this.previewLayout.split(communityId)[1]);
|
||||
}
|
||||
}
|
||||
public buildMenu(communityId: string) {
|
||||
|
|
|
@ -22,105 +22,6 @@ export class CustomizationComponent {
|
|||
|
||||
public ngOnInit() {
|
||||
|
||||
this.buildCss();
|
||||
try {
|
||||
const head = this.document.getElementsByTagName('head')[0];
|
||||
|
||||
let customizationCssFile = this.document.getElementById('customCssfile' ) as HTMLLinkElement;
|
||||
if (customizationCssFile) {
|
||||
customizationCssFile.href = "/assets/customization.css";
|
||||
} else {
|
||||
const style = this.document.createElement('link');
|
||||
style.id = 'customCssfile';
|
||||
style.rel = 'stylesheet';
|
||||
style.href = "/assets/customization.css";
|
||||
head.appendChild(style);
|
||||
}
|
||||
let customCss = this.document.getElementById('customStyle' ) as HTMLLinkElement;
|
||||
if (customCss) {
|
||||
customCss.append(this.customizationCss);
|
||||
} else {
|
||||
const style = this.document.createElement('style');
|
||||
style.id = 'customStyle';
|
||||
head.appendChild(style);
|
||||
const renderer = this.rendererFactory.createRenderer(this.document, {
|
||||
id: '-1',
|
||||
encapsulation: ViewEncapsulation.None,
|
||||
styles: [],
|
||||
data: {}
|
||||
});
|
||||
let CSSElement = renderer.createText(this.customizationCss);
|
||||
renderer.appendChild(style,CSSElement);
|
||||
}
|
||||
} catch (e) {
|
||||
console.error('Renderrer Error to append style ', e);
|
||||
}
|
||||
}
|
||||
private buildCss() {
|
||||
|
||||
this.customizationCss = `
|
||||
:root {
|
||||
--portal-main-color: ` + this.layout.identity.mainColor+`;
|
||||
--portal-dark-color: ` + this.layout.identity.secondaryColor+`;
|
||||
--background-light-color:` + this.layout.backgrounds.light.color+`;
|
||||
}
|
||||
`;
|
||||
return;
|
||||
//Search SVG
|
||||
let search = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2000 532"><defs><style>.cls-1{isolation:isolate;}.cls-2{fill:{{color}};mix-blend-mode:multiply;}</style></defs><title>Asset 3</title><g class="cls-1"><g id="Layer_2" data-name="Layer 2"><g id="Layer_1-2" data-name="Layer 1"><path class="cls-2" d="M0,431s362,109,841,62,632,68,1159-9V0H0Z"/><path class="cls-2" d="M0,514s1401,71,2000-69V0H0Z"/></g></g></g></svg>`;
|
||||
;
|
||||
let svg = 'data:image/svg+xml,' + encodeURIComponent(search.replace('{{color}}', this.layout.backgrounds.form.color));
|
||||
this.customizationCss = this.customizationCss.concat('.generalSearchForm,.publicationsSearchForm,.projectsSearchForm, .projectsTableSearchForm,.organizationsSearchForm,.datasourcesSearchForm {');
|
||||
this.customizationCss = this.customizationCss.concat(' background: '
|
||||
+ "url('" + (this.layout.backgrounds.form.imageFile?(this.properties.utilsService + '/download/' +this.layout.backgrounds.form.imageFile): svg) + "') transparent no-repeat "+this.layout.backgrounds.form.position+" ;");
|
||||
this.customizationCss = this.customizationCss.concat(" background-size: cover !important; ");
|
||||
this.customizationCss = this.customizationCss.concat(" height: inherit; }");
|
||||
|
||||
//Button link SVG
|
||||
let arrow = `<svg width="23" height="11" viewBox="0 0 23 11" xmlns="http://www.w3.org/2000/svg"><polyline fill="none" stroke="{{color}}" points="17 1 22 5.5 17 10 " /><line fill="none" stroke="{{color}}" x1="0" y1="5.5" x2="22.4" y2="5.5" /></svg>`;;
|
||||
let svg_arrow = 'data:image/svg+xml,' + encodeURIComponent(arrow.split('{{color}}').join(this.layout.identity.mainColor));
|
||||
this.customizationCss = this.customizationCss.concat('.uk-button-text::before {');
|
||||
this.customizationCss = this.customizationCss.concat(' background-image: ' + "url('" + svg_arrow + "') !important}");
|
||||
|
||||
this.customizationCss = this.customizationCss.concat(' .communityPanelBackground, .communityPanelBackground .uk-section-primary {');
|
||||
this.customizationCss = this.customizationCss.concat(' background-color: ' + this.layout.backgrounds.dark.color + ';}');
|
||||
this.customizationCss = this.customizationCss.concat(' .uk-button:not(.uk-button-text){');
|
||||
this.customizationCss = this.customizationCss.concat(' border-radius:' + (this.layout.buttons.lightBackground.borderRadius != null ? this.layout.buttons.lightBackground.borderRadius : '4') + 'px;');
|
||||
this.customizationCss = this.customizationCss.concat(' }');
|
||||
/*
|
||||
|
||||
this.customizationCss = this.customizationCss.concat(' .uk-button:not(.uk-button-text):not(.uk-button-default):not(.uk-button-primary):not(.uk-disabled), .portal-button:not(.uk-disabled) {');
|
||||
this.customizationCss = this.customizationCss.concat(' background-color:' + (this.layout.buttons.lightBackground.backgroundColor != null ? this.layout.buttons.lightBackground.backgroundColor : `#003052`) + ';');
|
||||
this.customizationCss = this.customizationCss.concat(' color: ' + (this.layout.buttons.lightBackground.color != null ? this.layout.buttons.lightBackground.color : `white`) + ';');
|
||||
this.customizationCss = this.customizationCss.concat('border-color: ' + (this.layout.buttons.lightBackground.borderColor != null ? this.layout.buttons.lightBackground.borderColor : `transparent`) + ';');
|
||||
this.customizationCss = this.customizationCss.concat(' border-style: ' + (this.layout.buttons.lightBackground.borderStyle != null ? this.layout.buttons.lightBackground.borderStyle : `solid`) + ';');
|
||||
this.customizationCss = this.customizationCss.concat(' border-width: ' + (this.layout.buttons.lightBackground.borderWidth != null ? this.layout.buttons.lightBackground.borderWidth : `1`) + 'px;');
|
||||
this.customizationCss = this.customizationCss.concat(' }');
|
||||
|
||||
|
||||
this.customizationCss = this.customizationCss.concat(' .uk-button:not(.uk-button-text):not(.uk-button-default):not(.uk-button-primary):hover, .portal-button:hover {');
|
||||
this.customizationCss = this.customizationCss.concat(' background-color:' + (this.layout.buttons.lightBackground.onHover.backgroundColor != null ? this.layout.buttons.lightBackground.onHover.backgroundColor : '#154B71') + ';');
|
||||
this.customizationCss = this.customizationCss.concat(' color: '+ (this.layout.buttons.lightBackground.onHover.color != null ? this.layout.buttons.lightBackground.onHover.color : 'white') + ';');
|
||||
this.customizationCss = this.customizationCss.concat(' border-color: ' + (this.layout.buttons.lightBackground.onHover.borderColor != null ? this.layout.buttons.lightBackground.onHover.borderColor : 'transparent') + ';');
|
||||
this.customizationCss = this.customizationCss.concat(' }');*/
|
||||
/*Buttons*/
|
||||
this.customizationCss = this.customizationCss.concat(' .communityPanelBackground .uk-button:not(.ignoreCommunityPanelBackground) {');
|
||||
this.customizationCss = this.customizationCss.concat( 'background-color: ' + this.layout.buttons.darkBackground.backgroundColor + ' !important;');
|
||||
this.customizationCss = this.customizationCss.concat(' color: ' + this.layout.buttons.darkBackground.color + ' !important;');
|
||||
this.customizationCss = this.customizationCss.concat(' border-color: ' + this.layout.buttons.darkBackground.borderColor + ' !important;');
|
||||
this.customizationCss = this.customizationCss.concat(' border-style: ' + this.layout.buttons.darkBackground.borderStyle + ' !important;');
|
||||
this.customizationCss = this.customizationCss.concat( 'border-width: ' + this.layout.buttons.darkBackground.borderWidth + 'px !important;');
|
||||
this.customizationCss = this.customizationCss.concat( 'border-radius:' + this.layout.buttons.darkBackground.borderRadius + 'px !important;');
|
||||
|
||||
this.customizationCss = this.customizationCss.concat(' }');
|
||||
|
||||
|
||||
this.customizationCss = this.customizationCss.concat(' .communityPanelBackground .uk-button:not(.ignoreCommunityPanelBackground):hover {');
|
||||
this.customizationCss = this.customizationCss.concat(' background-color: ' + this.layout.buttons.darkBackground.onHover.backgroundColor + ' !important;');
|
||||
this.customizationCss = this.customizationCss.concat( 'color: ' + this.layout.buttons.darkBackground.onHover.color + ' !important;');
|
||||
this.customizationCss = this.customizationCss.concat( 'border-color:' + this.layout.buttons.darkBackground.onHover.borderColor + ' !important;');
|
||||
this.customizationCss = this.customizationCss.concat(' }');
|
||||
// console.debug(this.customizationCss)
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,171 +0,0 @@
|
|||
:root {
|
||||
/*Buttons*/
|
||||
|
||||
--primary-color: var(--portal-main-color);
|
||||
--secondary-color: var(--portal-dark-color);
|
||||
--button-primary-background: var(--portal-main-color);
|
||||
--button-primary-background-image: none;
|
||||
--button-secondary-background: var(--portal-dark-color);
|
||||
--button-secondary-background-image: none;
|
||||
--button-primary-color: var(--font-default-color);
|
||||
|
||||
/* Primary */
|
||||
--button-primary-background: var(--portal-main-color);
|
||||
--button-primary-background-image: none;
|
||||
--button-primary-color: var(--light-color);
|
||||
--button-primary-border-color: transparent;
|
||||
--button-primary-background-hover: var(--portal-dark-color);
|
||||
--button-primary-background-image-hover: none;
|
||||
--button-primary-color-hover: var(--light-color);
|
||||
--button-primary-border-color-hover: transparent;
|
||||
|
||||
/* Secondary */
|
||||
--button-secondary-background: var(--light-color);
|
||||
--button-secondary-background-image: none;
|
||||
--button-secondary-color: var(--primary-color);
|
||||
--button-secondary-border-color: transparent;
|
||||
--button-secondary-background-hover: var(--primary-color);
|
||||
--button-secondary-background-image-hover: none;
|
||||
--button-secondary-color-hover: var(--light-color);
|
||||
--button-secondary-border-color-hover: transparent;
|
||||
|
||||
/*backgrounds*/
|
||||
--primary-background: #2C2C2C;
|
||||
--primary-background-image:none;
|
||||
--secondary-background-image:none;
|
||||
|
||||
/*fonts*/
|
||||
--font-primary-color:var(--portal-main-color);
|
||||
/*--secondary-background: var(--secondary-color);*/
|
||||
}
|
||||
/*.communityPanelBackground {*/
|
||||
/* color: #ffffff !important;*/
|
||||
|
||||
/*}*/
|
||||
|
||||
/*.communityPanelBackground svg .stroke_line {*/
|
||||
/* stroke: #ffffff !important;*/
|
||||
/*}*/
|
||||
|
||||
/*.communityPanelBackground svg .fill_text {*/
|
||||
/* fill: #ffffff !important;*/
|
||||
/*}*/
|
||||
|
||||
|
||||
/*.communityPanelBackground .uk-h6:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground .uk-h5:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground .uk-h4:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground .uk-h3:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground .uk-h2:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground .uk-h1:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground h6:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground h5:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground h4:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground h3:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground h2:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground h1:not(.ignoreCommunityPanelBackground){*/
|
||||
/* color: #ffffff !important;*/
|
||||
/*}*/
|
||||
|
||||
|
||||
/*.communityPanelBackground .uk-h5:not(.ignoreCommunityPanelBackground) {*/
|
||||
/* font-weight: 700!important;*/
|
||||
/*}*/
|
||||
|
||||
/*.communityPanelBackground .uk-link:not(.ignoreCommunityPanelBackground),*/
|
||||
/*.communityPanelBackground a:not(.uk-button):not(.uk-button-text):not(.ignoreCommunityPanelBackground),*/
|
||||
/*.portal-card a {*/
|
||||
/* color: rgba(255, 255, 255, 0.98) !important;*/
|
||||
/* font-family: 'Open Sans', sans-serif !important;*/
|
||||
/* font-size: 14px !important;*/
|
||||
/*}*/
|
||||
|
||||
/*.communityPanelBackground .uk-link:not(.ignoreCommunityPanelBackground):hover,*/
|
||||
/*.communityPanelBackground a:not(.uk-button):not(.uk-button-text):not(.ignoreCommunityPanelBackground):hover,*/
|
||||
/*.portal-card a:hover {*/
|
||||
/* color: rgba(255, 255, 255, 0.5) !important;*/
|
||||
/*}*/
|
||||
|
||||
/*.uk-link,*/
|
||||
/*a:not(.uk-button),*/
|
||||
/*.uk-navbar-dropdown-nav>li>a,*/
|
||||
/*!*.uk-navbar-nav>li>a,*!*/
|
||||
/*.loginLink,*/
|
||||
/*.uk-tab>.uk-active>a,*/
|
||||
/*.uk-tab>*>a:focus,*/
|
||||
/*.uk-tab>*>a:hover {*/
|
||||
/* color: var(--portal-main-color);*/
|
||||
/*}*/
|
||||
/* */
|
||||
/*.uk-navbar-dropdown-nav>li>a:focus,*/
|
||||
/*.uk-navbar-dropdown-nav>li>a:hover,*/
|
||||
/*.uk-navbar-dropdown-nav>li>a:active,*/
|
||||
/*.uk-navbar-nav>li>a:hover,*/
|
||||
/*.uk-navbar-nav>li>a:focus,*/
|
||||
/*.uk-navbar-nav>li>a:active,*/
|
||||
|
||||
/*.uk-navbar-dropdown-nav>li.uk-active>a,*/
|
||||
/*.uk-tab>.uk-active>a,*/
|
||||
/*.uk-navbar-nav>li.uk-active>a,*/
|
||||
/*.uk-navbar-container:not(.uk-navbar-transparent) .uk-navbar-nav>li.uk-active>a,*/
|
||||
/*.uk-navbar-container:not(.uk-navbar-transparent) .uk-navbar-nav > li:hover > a,*/
|
||||
/*.uk-navbar-container:not(.uk-navbar-transparent) .uk-navbar-nav > li:active > a,*/
|
||||
/*.uk-navbar-container:not(.uk-navbar-transparent) .uk-navbar-nav > li:focus > a,*/
|
||||
/*.uk-navbar-container:not(.uk-navbar-transparent) .uk-navbar-nav > li > a.uk-open,*/
|
||||
/*.uk-navbar-nav > li > a.uk-open,*/
|
||||
/*.uk-button-text*/
|
||||
/*{*/
|
||||
/* color: var(--portal-main-color) !important;*/
|
||||
/*}*/
|
||||
/*.uk-link:hover, a:not(.uk-button):hover{*/
|
||||
/* color: var(--portal-dark-color) ;*/
|
||||
/*}*/
|
||||
/*.navbar .nav > li > .dropdown-menu, .uk-navbar-dropdown {*/
|
||||
/* background-color: white !important;*/
|
||||
/* color: #666;*/
|
||||
/* box-shadow: 0 5px 12px rgba(0, 0, 0, .15);*/
|
||||
|
||||
/* !*border:var(--portal-main-color) 1px solid;*!*/
|
||||
/*}*/
|
||||
/*.uk-navbar-dropdown-nav > li > a{*/
|
||||
/* color: #666 !important;*/
|
||||
/*}*/
|
||||
/*.customTabs .uk-tab>.uk-active>a {*/
|
||||
/* border-color: var(--portal-main-color);*/
|
||||
/*}*/
|
||||
|
||||
/*.customTabs .uk-tab>.uk-active>a {*/
|
||||
/* border-color: var(--portal-main-color);*/
|
||||
/*}*/
|
||||
|
||||
/*.uk-tab>*>a:focus,*/
|
||||
/*.uk-tab>*>a:hover {*/
|
||||
/* border-color: var(--portal-dark-color);*/
|
||||
/*}*/
|
||||
|
||||
/*.portal-link:hover {*/
|
||||
/* !*text-decoration: none !important;*!*/
|
||||
/* color: var(--portal-dark-color) !important;*/
|
||||
/*}*/
|
||||
|
||||
/*#stickyNavbar{*/
|
||||
/* box-shadow: 0 1px 1px #0000004D;*/
|
||||
/*}*/
|
||||
/*.uk-button-primary, .uk-button-secondary, .uk-button-default{*/
|
||||
/* color: white !important;*/
|
||||
/* background-color: var(--portal-main-color) !important;*/
|
||||
/* border-color: var(--portal-main-color) !important;*/
|
||||
/*}*/
|
||||
/*.uk-button-primary:hover, .uk-button-secondary:hover, .uk-button-default:hover{*/
|
||||
/* background-color: var(--portal-dark-color) !important;*/
|
||||
/* border-color: var(--portal-dark-color) !important;*/
|
||||
/*}*/
|
||||
/*.uk-alert-primary{*/
|
||||
/* color: var(--portal-main-color);*/
|
||||
/* border-color: var(--portal-main-color);*/
|
||||
/*}*/
|
||||
|
||||
/*.uk-text-primary, .landing .download-from a:hover{*/
|
||||
/* color: var(--portal-main-color) !important;*/
|
||||
/*}*/
|
||||
|
|
@ -67,29 +67,6 @@
|
|||
var d="createElement",c="getElementsByTagName",m="setAttribute",n=document.getElementById(e);
|
||||
return n&&n.parentNode&&n.parentNode.removeChild(n),n=document[d+"NS"]&&document.documentElement.namespaceURI,n=n?document[d+"NS"](n,"script"):document[d]("script"),n[m]("id",e),n[m]("src",t),(document[c]("head")[0]||document[c]("body")[0]).appendChild(n),n=new Image,void n[m]("src","https://d1uo4w7k31k5mn.cloudfront.net/donut/0.png")
|
||||
}
|
||||
|
||||
function appendCss(customData) {
|
||||
if (typeof customData != "undefined")
|
||||
$(document).ready(function () {
|
||||
/* var link = $("<style>");
|
||||
link.attr({
|
||||
type: 'text/css',
|
||||
rel: 'stylesheet',
|
||||
id: "customCss",
|
||||
});
|
||||
$("head").append(link);
|
||||
$("#customCss").append(customData);*/
|
||||
//TODO uncomment above and remove the following once customization is up to date
|
||||
var link = $("<link>");
|
||||
link.attr({
|
||||
rel: 'stylesheet',
|
||||
id: "customCss",
|
||||
href:"/assets/customization.css"
|
||||
});
|
||||
$("head").append(link);
|
||||
$("#customCss").append(customData);
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<script src="https://unpkg.com/smoothscroll-polyfill@0.4.3/dist/smoothscroll.min.js"></script>
|
||||
</html>
|
||||
|
|
|
@ -21,7 +21,7 @@ export let properties: EnvProperties = {
|
|||
useNewStatistisTool: true,
|
||||
enermapsURL:"https://lab.idiap.ch/enermaps",
|
||||
impactFactorsAPIURL: 'https://bip-api.imsi.athenarc.gr/paper/scores/batch/',
|
||||
claimsAPIURL: 'http://dl170.madgik.di.uoa.gr:8180/dnet-claims-service-2.0.0-SNAPSHOT/rest/claimsService/',
|
||||
claimsAPIURL: 'http://scoobydoo.di.uoa.gr:8080/dnet-claims-service-2.0.0-SNAPSHOT/rest/claimsService/',
|
||||
searchAPIURLLAst: 'https://beta.services.openaire.eu/search/v2/api/',
|
||||
searchResourcesAPIURL: 'https://beta.services.openaire.eu/search/v2/api/resources',
|
||||
openCitationsAPIURL: 'https://services.openaire.eu/opencitations/getCitations?id=',
|
||||
|
|
|
@ -57,28 +57,6 @@
|
|||
return n&&n.parentNode&&n.parentNode.removeChild(n),n=document[d+"NS"]&&document.documentElement.namespaceURI,n=n?document[d+"NS"](n,"script"):document[d]("script"),n[m]("id",e),n[m]("src",t),(document[c]("head")[0]||document[c]("body")[0]).appendChild(n),n=new Image,void n[m]("src","https://d1uo4w7k31k5mn.cloudfront.net/donut/0.png")
|
||||
}
|
||||
|
||||
function appendCss(customData) {
|
||||
if (typeof customData != "undefined")
|
||||
$(document).ready(function () {
|
||||
/* var link = $("<style>");
|
||||
link.attr({
|
||||
type: 'text/css',
|
||||
rel: 'stylesheet',
|
||||
id: "customCss",
|
||||
});
|
||||
$("head").append(link);
|
||||
$("#customCss").append(customData);*/
|
||||
//TODO uncomment above and remove the following once customization is up to date
|
||||
var link = $("<link>");
|
||||
link.attr({
|
||||
rel: 'stylesheet',
|
||||
id: "customCss",
|
||||
href:"/assets/customization.css"
|
||||
});
|
||||
$("head").append(link);
|
||||
$("#customCss").append(customData);
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<script src="https://unpkg.com/smoothscroll-polyfill@0.4.3/dist/smoothscroll.min.js"></script>
|
||||
</html>
|
||||
|
|
Loading…
Reference in New Issue