Skip to content
Snippets Groups Projects
Commit b34e7fe2 authored by Steinwender, Tamara's avatar Steinwender, Tamara
Browse files

Merge branch 'master' of gitlab.tugraz.at:dbp/web-components/toolkit

parents 368bd90c 3bf45bb6
No related branches found
No related tags found
No related merge requests found
Pipeline #13207 passed
...@@ -55,6 +55,7 @@ export class AppShell extends ScopedElementsMixin(LitElement) { ...@@ -55,6 +55,7 @@ export class AppShell extends ScopedElementsMixin(LitElement) {
this.topic = {}; this.topic = {};
this.basePath = '/'; this.basePath = '/';
this.keycloakConfig = null; this.keycloakConfig = null;
this.noWelcomePage = false;
this._updateAuth = this._updateAuth.bind(this); this._updateAuth = this._updateAuth.bind(this);
this._loginStatus = 'unknown'; this._loginStatus = 'unknown';
...@@ -138,12 +139,14 @@ export class AppShell extends ScopedElementsMixin(LitElement) { ...@@ -138,12 +139,14 @@ export class AppShell extends ScopedElementsMixin(LitElement) {
} }
} }
// Inject the welcome activity if (!this.noWelcomePage) {
routes.unshift("welcome"); // Inject the welcome activity
metadata = Object.assign(metadata, { routes.unshift("welcome");
"welcome": appWelcomeMeta, metadata = Object.assign(metadata, {
}); "welcome": appWelcomeMeta,
customElements.get("dbp-app-shell-welcome").app = this; });
customElements.get("dbp-app-shell-welcome").app = this;
}
// this also triggers a rebuilding of the menu // this also triggers a rebuilding of the menu
this.metadata = metadata; this.metadata = metadata;
...@@ -230,6 +233,7 @@ export class AppShell extends ScopedElementsMixin(LitElement) { ...@@ -230,6 +233,7 @@ export class AppShell extends ScopedElementsMixin(LitElement) {
_loginStatus: { type: Boolean, attribute: false }, _loginStatus: { type: Boolean, attribute: false },
matomoUrl: { type: String, attribute: "matomo-url" }, matomoUrl: { type: String, attribute: "matomo-url" },
matomoSiteId: { type: Number, attribute: "matomo-site-id" }, matomoSiteId: { type: Number, attribute: "matomo-site-id" },
noWelcomePage: { type: Boolean, attribute: "no-welcome-page" }
}; };
} }
...@@ -732,7 +736,7 @@ export class AppShell extends ScopedElementsMixin(LitElement) { ...@@ -732,7 +736,7 @@ export class AppShell extends ScopedElementsMixin(LitElement) {
return html` return html`
<slot class="${slotClassMap}"></slot> <slot class="${slotClassMap}"></slot>
<dbp-auth-keycloak lang="${this.lang}" url="${kc.url}" realm="${kc.realm}" client-id="${kc.clientId}" silent-check-sso-redirect-uri="${kc.silentCheckSsoRedirectUri || ''}" scope="${kc.scope || ''}" idp-hint="${kc.idpHint || ''}" load-person try-login></dbp-auth-keycloak> <dbp-auth-keycloak lang="${this.lang}" url="${kc.url}" realm="${kc.realm}" client-id="${kc.clientId}" silent-check-sso-redirect-uri="${kc.silentCheckSsoRedirectUri || ''}" scope="${kc.scope || ''}" idp-hint="${kc.idpHint || ''}" load-person ?force-login="${kc.forceLogin}" ?try-login="${!kc.forceLogin}"></dbp-auth-keycloak>
<dbp-matomo endpoint="${this.matomoUrl}" site-id="${this.matomoSiteId}"></dbp-matomo> <dbp-matomo endpoint="${this.matomoUrl}" site-id="${this.matomoSiteId}"></dbp-matomo>
<div class="${mainClassMap}"> <div class="${mainClassMap}">
<div id="main"> <div id="main">
......
...@@ -64,7 +64,7 @@ export default (async () => { ...@@ -64,7 +64,7 @@ export default (async () => {
}), }),
consts({ consts({
environment: build, environment: build,
buildInfo: getBuildInfo(), buildinfo: getBuildInfo(),
}), }),
emitEJS({ emitEJS({
src: 'assets', src: 'assets',
...@@ -105,4 +105,4 @@ export default (async () => { ...@@ -105,4 +105,4 @@ export default (async () => {
(process.env.ROLLUP_WATCH === 'true') ? serve({contentBase: 'dist', host: '127.0.0.1', port: 8002}) : false (process.env.ROLLUP_WATCH === 'true') ? serve({contentBase: 'dist', host: '127.0.0.1', port: 8002}) : false
] ]
}; };
})(); })();
\ No newline at end of file
...@@ -2,7 +2,7 @@ import {i18n} from './i18n.js'; ...@@ -2,7 +2,7 @@ import {i18n} from './i18n.js';
import {LitElement} from "lit-element"; import {LitElement} from "lit-element";
import DBPLitElement from 'dbp-common/dbp-lit-element'; import DBPLitElement from 'dbp-common/dbp-lit-element';
import {EventBus} from 'dbp-common'; import {EventBus} from 'dbp-common';
import buildInfo from 'consts:buildInfo'; import buildInfo from 'consts:buildinfo';
export class MatomoElement extends DBPLitElement { export class MatomoElement extends DBPLitElement {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment